Payment Processing Time Estimator

Payment Processing Time Estimator

Estimate when funds will be available based on transaction details.

Awaiting Transaction Data

Click 'Next' to go to the 'Transaction Details' tab and input information to get an estimate.

${d.impact}

`).join(''); }; // --- EVENT HANDLERS --- const handleNavClick = () => { if (currentTab === 'dashboard') { showTab('config'); } else { // On Config tab, button says 'Analyze' const results = calculateEstimate(); updateDashboard(results); showTab('dashboard'); } }; const generatePDF = () => { const pdfContent = document.getElementById('pdf-content'); const pdfBtnContainer = document.getElementById('pdf-button-container'); if (!pdfContent || !pdfBtnContainer) return; pdfBtnContainer.style.display = 'none'; html2canvas(pdfContent, { scale: 2, useCORS: true }).then(canvas => { const imgData = canvas.toDataURL('image/png'); const pdf = new jsPDF({ orientation: 'p', unit: 'mm', format: 'a4' }); const pdfWidth = pdf.internal.pageSize.getWidth(); const imgWidth = pdfWidth - 20; const imgHeight = (canvas.height * imgWidth) / canvas.width; pdf.setFontSize(22); pdf.setFont('helvetica', 'bold'); pdf.text('Payment Processing Estimate', pdfWidth / 2, 15, { align: 'center' }); pdf.addImage(imgData, 'PNG', 10, 25, imgWidth, imgHeight); pdf.save('payment-processing-estimate.pdf'); pdfBtnContainer.style.display = 'block'; }).catch(err => { console.error("Error generating PDF:", err); pdfBtnContainer.style.display = 'block'; }); }; // --- ATTACH LISTENERS --- prevBtn.addEventListener('click', () => showTab('dashboard')); nextBtn.addEventListener('click', handleNavClick); tabButtons.dashboard.addEventListener('click', () => showTab('dashboard')); tabButtons.config.addEventListener('click', () => showTab('config')); document.getElementById('download-pdf-btn').addEventListener('click', generatePDF); // --- INITIALIZATION --- showTab('dashboard'); });
Scroll to Top