@zeniai/web-cockpit-ui 1.13.83-qa → 1.13.84-dev

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (249) hide show
  1. package/dist/assets/{ACHDetailsPage-_VHVuqJw-Bymc8CZ3.js → ACHDetailsPage-Bya_wRcI-Cbp0qhsx.js} +3 -3
  2. package/dist/assets/{AIPerformancePage-C89zANQm-DAbfunq3.js → AIPerformancePage-Bc2kKHSK-BgXzMS_3.js} +24 -24
  3. package/dist/assets/AccountInfoPage-d3ST-rTL-C_leII_k.js +18 -0
  4. package/dist/assets/{AccountInfoPageContent-B8SOX9i5-7d4Bt0bR.js → AccountInfoPageContent-BhU-TVmh-BdzRn56o.js} +20 -20
  5. package/dist/assets/{AccountReconDetailsDrawerPage-BVnXwxD4-DEurx_N4.js → AccountReconDetailsDrawerPage-Dp2R5isq-DTMzR1zA.js} +18 -18
  6. package/dist/assets/AccountRow-t4I1y-2K-CgC6OUhN.js +298 -0
  7. package/dist/assets/{AccountsPromoCardStack-9UqzeTvF-CzL1CjSW.js → AccountsPromoCardStack-DYUyO-ip-D1yzvIYh.js} +22 -22
  8. package/dist/assets/{AddAddressForCardDrawer-flYKIptj-CZXNkdja.js → AddAddressForCardDrawer-CNSnxc8q-xbp24EPr.js} +1 -1
  9. package/dist/assets/{AddToWalletPage-qMFXqjhm-BLIVGZdo.js → AddToWalletPage-Q8uWTckm-XMYIU9V3.js} +30 -30
  10. package/dist/assets/{AgingReportsPage-CdVOTjjc-BjXskb5q.js → AgingReportsPage-B-DOb7my-C3NgaG-U.js} +4 -4
  11. package/dist/assets/{AllUserItems-6g-IFiDP-BF7NBOrr.js → AllUserItems-B86Y2Fmg-DavCuBOs.js} +7 -7
  12. package/dist/assets/{ApAgingDetailPage-DNG6y6eT-DhHZsXHm.js → ApAgingDetailPage-CMYJgTzS-sOBU6gP5.js} +3 -3
  13. package/dist/assets/{AppBasePage-C0Sy0oae-DvEJ-ATe.js → AppBasePage-DJO-V2ox-D56HdnuV.js} +4 -4
  14. package/dist/assets/{AppDrawerContent-BAYPGtYY-CUnHM7PZ.js → AppDrawerContent-5_QaBLwS-CM4yA7GZ.js} +2 -2
  15. package/dist/assets/{ApprovalRulesSettingsPage-D52kq1hZ-BYg8vnKt.js → ApprovalRulesSettingsPage-CPbVQ97S-DsB9ftyn.js} +6 -6
  16. package/dist/assets/{ArAgingChart-Bso6mAzK-j6sfc3fv.js → ArAgingChart-l020Rk_S-DwzSqVCY.js} +5 -5
  17. package/dist/assets/{ArAgingDetailPage-BxtXGjOk-CBtuYc3L.js → ArAgingDetailPage-BeUPeHBJ-DWBF7rvM.js} +2 -2
  18. package/dist/assets/{AttachmentView-cjbbz-rh-BnkWjld0.js → AttachmentView-Afp_U4fV-ChOQ6Ub6.js} +8 -8
  19. package/dist/assets/{BankAccountSection-Cf1NyJua-CA0IxE0G.js → BankAccountSection-CNQgxgSJ-Ca43edcO.js} +4 -4
  20. package/dist/assets/{BankAccountWarningSection-hZNBR8bC-DgrV5hrK.js → BankAccountWarningSection-V0HHzW57-BXTr_4tn.js} +5 -5
  21. package/dist/assets/{BankConnectionsSettingsPage-C42Z61VJ-BjXrRucN.js → BankConnectionsSettingsPage-Bk8K0xUn-B_F9KKkf.js} +22 -22
  22. package/dist/assets/{BillDetailPage-C9ABXSip-Dyhvss4T.js → BillDetailPage-D9d6X0o4-D-GS6Om8.js} +5 -5
  23. package/dist/assets/{BillPayApprovalRuleDetailPage-C_P8uDLH-c09oNfGD.js → BillPayApprovalRuleDetailPage-CSVTc5Mn-BViwJkEX.js} +2 -2
  24. package/dist/assets/{BillPayApprovalRulesPage-B-e1bydX-37-nfPS6.js → BillPayApprovalRulesPage-DIOOCVKH-D1Pdhh1K.js} +3 -3
  25. package/dist/assets/{BillPayPromoPage-CdGuDH1_-DoTWyE5k.js → BillPayPromoPage-C44YKAlE-CyfJbYHe.js} +2 -2
  26. package/dist/assets/{BillPaySetUpPage-BJzAf5ei-BfqA1r1q.js → BillPaySetUpPage-erTIfKkS-e9d2uLlE.js} +2 -2
  27. package/dist/assets/BillingSettingsPage-CmvoTc8r-CgKVc-Hp.js +44 -0
  28. package/dist/assets/BillsBulkReviewDrawerPage-OSbHVAMk-B7pVq5dd.js +1 -0
  29. package/dist/assets/{BoxItem-BMejIo17-DfTWFZ7_.js → BoxItem-UFBGpfBB-Cl1_IwAU.js} +1 -1
  30. package/dist/assets/{BusinessVerificationPage-B4T4eKqS-Bye3WrQZ.js → BusinessVerificationPage-Cl7jz1DF-B1c4YlYQ.js} +8 -8
  31. package/dist/assets/{CardNumberSubText-DU4-NQyz-186D7nSj.js → CardNumberSubText-DyFZudV_-D11cIePr.js} +1 -1
  32. package/dist/assets/{CashbackDetailPage-gEd-o4kR-C4wVKPgt.js → CashbackDetailPage-D0_YW2Dy-BvqJCdMM.js} +21 -21
  33. package/dist/assets/{ChargeCardDetailPage-Bi0lqA56-BFxB7GLk.js → ChargeCardDetailPage-YkvyvIEk-BL54Gn2n.js} +58 -58
  34. package/dist/assets/{ChargeCardListPage-D0DuXZ7e-DlfCFnes.js → ChargeCardListPage-4vg8Q6bl-B7zHIOPp.js} +35 -35
  35. package/dist/assets/{ChargeCardListTable-C1RWnfY_-CHbl4tuS.js → ChargeCardListTable-Dl-rblE6-cI3INYu9.js} +25 -25
  36. package/dist/assets/ChargeCardPromoPage-BzcIsHeK-CL-PWL5a.js +175 -0
  37. package/dist/assets/{ChargeCardSetupPage-DNUctoFI-CLAGahbp.js → ChargeCardSetupPage-BSiJnRP_-C-GYT256.js} +2 -2
  38. package/dist/assets/{ChargeCardStatementsPage-B565dWKi-BNK7rWNj.js → ChargeCardStatementsPage-NkfA1SYG-Dm6-iBGo.js} +4 -4
  39. package/dist/assets/{ChargeCardUtils-BN7bbdUB-BbkRwxs1.js → ChargeCardUtils-CLpd-HDH-B3csze9l.js} +1 -1
  40. package/dist/assets/{ChaseOverlay-BrHcqwQQ-D5p6lw7W.js → ChaseOverlay-B1cuawle-p6HzSxTf.js} +8 -8
  41. package/dist/assets/CheckDepositDrawerPage-BwJ5tAF--CpJrHbza.js +206 -0
  42. package/dist/assets/{CollapsableReportTable-C5VV-Hqz-BgVDm2Ba.js → CollapsableReportTable-iMD5xyGN-Bi-fik_C.js} +29 -29
  43. package/dist/assets/{CompanyOfficerDetailsSection-DHqtLqa--DkQW91X6.js → CompanyOfficerDetailsSection-BA7etm2I-CmO-KOuc.js} +26 -26
  44. package/dist/assets/{CompanyPassportCard-BtC806n1-BE2Vutw3.js → CompanyPassportCard-Dks4EQDN-Dn-jW4u-.js} +2 -2
  45. package/dist/assets/{CompanyPassportPage-CZBZoHu3-CVdv1vFg.js → CompanyPassportPage-Denliwgg-BKRikNew.js} +140 -140
  46. package/dist/assets/{CompleteProfile-CwZtbTzm-B0JwwIUN.js → CompleteProfile-CCLq4pNY-y7V5PpLY.js} +10 -10
  47. package/dist/assets/ConfettiBurst-MKPxinI7-gHaE20YT.js +1 -0
  48. package/dist/assets/{CreateOrEditVendorPage-B43jo6gf-XWR76dqm.js → CreateOrEditVendorPage-BFejWQMx-BjDnDTWQ.js} +15 -15
  49. package/dist/assets/{CreditCardPaymentDrawerPage-1litLdxa-C6R9hrSu.js → CreditCardPaymentDrawerPage-B7Sesq_n-V9iiiMuJ.js} +16 -16
  50. package/dist/assets/{CreditCardPaymentPlgSection-CEjV1ee_-C66jG_cF.js → CreditCardPaymentPlgSection-D5CNl0oa-C-cdC2QZ.js} +10 -10
  51. package/dist/assets/{CurrencySelectField-DMPtPzwJ-CVyHXZxa.js → CurrencySelectField-DYvc6rwt-ByvmhvI-.js} +5 -5
  52. package/dist/assets/{CustomerOnboardingActivationPage-DUQPZIJW-C2-ZWnw3.js → CustomerOnboardingActivationPage-oUiw--hv-BRyHoZHP.js} +3 -3
  53. package/dist/assets/CustomerOnboardingContainerPage-D2xC_a0G-DLJn2o1E.js +1 -0
  54. package/dist/assets/{CustomerOnboardingDetailPageSkeleton-D-MkZIDQ-DF5QLwbE.js → CustomerOnboardingDetailPageSkeleton-BaDpU--M-CL7UtNSJ.js} +11 -11
  55. package/dist/assets/{CustomerOnboardingNoStepsPage-JnxUTXUI-92Zb-Tm2.js → CustomerOnboardingNoStepsPage-C_cxcuWE-CPcXa-uY.js} +8 -8
  56. package/dist/assets/CustomerOnboardingPage-Cuf1lJmu-BwFC9Sia.js +107 -0
  57. package/dist/assets/{CustomerOnboardingProductSuitePage-C47rlXpl-wD-8riam.js → CustomerOnboardingProductSuitePage-DEqdhh-2-wQlqTtpc.js} +4 -4
  58. package/dist/assets/Dashboard-DnR1KvYd-DzOeF_LG.js +778 -0
  59. package/dist/assets/{DashboardReportPage-B8sZBvi0-Bkka6zpc.js → DashboardReportPage-Tq4KsQuw-DPow_DwG.js} +67 -67
  60. package/dist/assets/{DepositAccTransactionItem-SBvKiZUo-DJaX4dE5.js → DepositAccTransactionItem-DWhVL-kH-YH09Nnsw.js} +2 -2
  61. package/dist/assets/{DepositAccTransactionListPage-DxyOodRG-CDy1pV7B.js → DepositAccTransactionListPage-BiaZBvV4-5ezA9uiX.js} +8 -8
  62. package/dist/assets/{DocumentSecurityBanner-2RwwRIbj-KpNSpuh7.js → DocumentSecurityBanner-eGDvEOvr-CyvEFE94.js} +1 -1
  63. package/dist/assets/DomesticWireDetailsPage-Bvmpk8LN-QDvn8074.js +21 -0
  64. package/dist/assets/{DownloadOverlay-D_7Q3gwF-BtTWiRYh.js → DownloadOverlay-C0vGOFIR-D53GsOkg.js} +20 -20
  65. package/dist/assets/{DrawerPage-D7ZExidR-CIWuPHJ5.js → DrawerPage-keu-rP1c-Ad94AagR.js} +8 -8
  66. package/dist/assets/EditPeoplePage-BTnhywM--fqULQ6DL.js +55 -0
  67. package/dist/assets/{EditReimbursementDetailPage-CZWIuR9q-DiQem3xT.js → EditReimbursementDetailPage-jqf5akyj-Dbu8QTQE.js} +74 -74
  68. package/dist/assets/{EntityDetailPage-liLBcaFa-BbblawRB.js → EntityDetailPage-D0mZIEcR-BRw589Gw.js} +2 -2
  69. package/dist/assets/{EntitySummarySection-BEubg_Ke-Bdvy7iaP.js → EntitySummarySection-bL2stKO1-B_cCEADD.js} +11 -11
  70. package/dist/assets/{ExpenseAutomationOverviewPage-De7pJxb1--Us_wwQ9.js → ExpenseAutomationOverviewPage-Cm00uGHv-CZxuB80N.js} +17 -17
  71. package/dist/assets/{ExpenseAutomationPage-JGlqvmW0-DGGQ5kes.js → ExpenseAutomationPage-BA8sRxM--BI5FDTiq.js} +84 -84
  72. package/dist/assets/{ExpressPayPage-DMuL6rjt-BbpZP04j.js → ExpressPayPage-DRNbLpuL-BqPn8Tnj.js} +8 -8
  73. package/dist/assets/{FeaturePreviewPage-eU2Fncgw-Df6t4vlN.js → FeaturePreviewPage-CeeAOF5C-B1ePxZD_.js} +2 -2
  74. package/dist/assets/{FollowStepsSection-CIOJXyXO-Ck9BhOv7.js → FollowStepsSection-DuElPK3y-BQRSekz2.js} +7 -7
  75. package/dist/assets/{GlobalReviewListPage-DbGsAMQF-DEii590Y.js → GlobalReviewListPage-DfjZMTms-CbpLeCqy.js} +10 -10
  76. package/dist/assets/HelpButton-BKCFqzW3-Ds4n43qE.js +28 -0
  77. package/dist/assets/{InformationCardStack-DBC0PIB2-ZpzVR8Pu.js → InformationCardStack-CmquAm7A-t9P9_NGQ.js} +5 -5
  78. package/dist/assets/{InsightsCardStack-BiyzY54v-DjzlYvXC.js → InsightsCardStack-D5ahtQWr-CLdQOUoS.js} +9 -9
  79. package/dist/assets/{InsightsSection-CB95rM5E-D6F0bC-C.js → InsightsSection-xgqf4arB-B8DybT5O.js} +3 -3
  80. package/dist/assets/{IntegrationsSettingsPage-IozP8XCs-Covl1ghU.js → IntegrationsSettingsPage-Cl6dfKQL-DtlX3Ccg.js} +5 -5
  81. package/dist/assets/{InternationalWireSwiftDetailsPage-CBLjT_qk-C24yuZmd.js → InternationalWireSwiftDetailsPage-D_jWoFli-DlLuf4mS.js} +11 -11
  82. package/dist/assets/{InternationalWireVerificationPage-BDHKKPIV-Kq4wZhMp.js → InternationalWireVerificationPage-it1U4OPj-CpKm_Jls.js} +17 -17
  83. package/dist/assets/{InviteFormPage-DcVcYJU0-CpPhN43t.js → InviteFormPage-DTMy8xZk-2c0kPCFn.js} +23 -23
  84. package/dist/assets/{InvitePageListView-CtGrvvWG-DUC9eyzx.js → InvitePageListView-X7W1jRxY-C4s0X98I.js} +31 -31
  85. package/dist/assets/InvitePeoplePage-fzgtceuE-B5MjB6BF.js +12 -0
  86. package/dist/assets/{InvoiceUploadSection-CzeBCw69-MIl0YoqM.js → InvoiceUploadSection-BhCDvIPX-wOQXy0Yc.js} +7 -7
  87. package/dist/assets/{IssueChargeCardPage-DywMnIW9-DZC1TtsH.js → IssueChargeCardPage-CqE8lMsX-C6vz_dxs.js} +22 -22
  88. package/dist/assets/{LabeledAddressValue-aXAfyy6x-zuxWHZ35.js → LabeledAddressValue-CCEVX0ke-C3sCHRt6.js} +1 -1
  89. package/dist/assets/{LabeledAddressValueField-BdNErK0u-BCVVhFLg.js → LabeledAddressValueField-B9iirKZj-Cw-fixky.js} +3 -3
  90. package/dist/assets/{LabeledControlledCheckBoxField-DPoSmzJi-B9fcjMs6.js → LabeledControlledCheckBoxField-Bl3-Zao6-6WoEZpzL.js} +1 -1
  91. package/dist/assets/{LabeledCreatableSingleSelectField-DsyZw9q6-BgU9LeRU.js → LabeledCreatableSingleSelectField-v86g-OZd-YeybErPj.js} +7 -7
  92. package/dist/assets/LabeledDocumentField-Dv4qzOY0-lFebzE73.js +41 -0
  93. package/dist/assets/LabeledDropDownFormattedTextField-BFMEaVfR-Dv78a583.js +59 -0
  94. package/dist/assets/{LabeledText-CcIJZUuh-CPcjfLXi.js → LabeledText-D9feJraX-padWmGRQ.js} +3 -3
  95. package/dist/assets/{LabeledUserSingleSelectWithSubtitlesField-CPJQjrJK-DWx8mI1V.js → LabeledUserSingleSelectWithSubtitlesField-BKNBvO_C-Dvjne4f2.js} +7 -7
  96. package/dist/assets/{LabeledZeniRolesDropDownField-WCoZXbuy-DHAUidGL.js → LabeledZeniRolesDropDownField-AwQaO42N-D65CRYdT.js} +26 -26
  97. package/dist/assets/{LinkJETransactionPage-jB4x6YYH-CygKAijz.js → LinkJETransactionPage-D3I2NvQw-B2_s-lzz.js} +8 -8
  98. package/dist/assets/{LowBalancePopup-c-6SC1hh-B9wQAJ9M.js → LowBalancePopup-OSUi1Alp-D-EAEgV_.js} +7 -7
  99. package/dist/assets/{MagicLinkACHDetailsPage-Cm98tK2_-7ec-cqHZ.js → MagicLinkACHDetailsPage-r3XSoJ11-ByBszh-P.js} +1 -1
  100. package/dist/assets/{MagicLinkDomesticWireDetailsPage-26S-99Ie-D3QNyjAa.js → MagicLinkDomesticWireDetailsPage-DPG9fUzZ-DLN7eK6J.js} +1 -1
  101. package/dist/assets/{MagicLinkInternationalWireDetailsPage-CY-hI3QM-D4hmDiEg.js → MagicLinkInternationalWireDetailsPage-CmXJXEaN-DSJ-KZsN.js} +1 -1
  102. package/dist/assets/{MagicLinkSuccessPage-1VMpD_t0-YoPoa1Fs.js → MagicLinkSuccessPage-CwszAuW2-CcLjVoXZ.js} +5 -5
  103. package/dist/assets/{MagicLinkTitleSection-BiZ9MGYp-Cl_WugVD.js → MagicLinkTitleSection-CvrbJ-of-eRuegy0D.js} +3 -3
  104. package/dist/assets/{MailingDetailsSection-DfxeX2uy-D2drNkzT.js → MailingDetailsSection-BJHZIZCt-CtVNeOVh.js} +1 -1
  105. package/dist/assets/{MeetingCalenderPopup-ifcJuMu9-ByO1X2Hh.js → MeetingCalenderPopup-C4r3bJ84-DJC2p-pW.js} +1 -1
  106. package/dist/assets/{Menu-B4Q04CAH-4XWj_HwH.js → Menu-MHZ6Ibt0-ClGVoJHI.js} +3 -3
  107. package/dist/assets/{MyBankConnectionsSettingsPage-rM_qhevU-DITmqjDy.js → MyBankConnectionsSettingsPage-DG1tuqAt-BJM-bRYR.js} +13 -13
  108. package/dist/assets/{MyPendingActivationChargeCardListPage-CwwpQgC6-iU-kUMq9.js → MyPendingActivationChargeCardListPage-DZyxqqyJ-gmzsoe2r.js} +1 -1
  109. package/dist/assets/{MyProfileSettingsPage-DbkgXE3d-BGJQs-jC.js → MyProfileSettingsPage-BnNbspx9-I-RR_w-w.js} +8 -8
  110. package/dist/assets/{NavBarWithPicker-CHrbDC5H-DmfI4NHq.js → NavBarWithPicker-3okDhiol-Mch2cVg7.js} +2 -2
  111. package/dist/assets/{NavigationArrow-B68QyyUR-DJ2p6cca.js → NavigationArrow-iw-yd_9S-DZPtXupp.js} +6 -9
  112. package/dist/assets/{NavigationDots-DYkUvR3H-CWQugA3e.js → NavigationDots-CB5JLuJi-yLXSzdJi.js} +1 -1
  113. package/dist/assets/{NewGlobalMerchantPage-CEZgARa1-Oq3mm2EE.js → NewGlobalMerchantPage-CcGws2R2-C4Fp7WXy.js} +33 -33
  114. package/dist/assets/NoDataChart-BsN_tNbW-BMMW2NFW.js +26 -0
  115. package/dist/assets/{NoDataTable-Z4rV9ZBK-p_2JIShf.js → NoDataTable-BbDo9Kma-CQu0CK8r.js} +1 -1
  116. package/dist/assets/{NotFoundPage-DGbe5Rh8-DP7xmEtU.js → NotFoundPage-gbtwlR8l-C5FBVYn3.js} +1 -1
  117. package/dist/assets/{NotificationSettingsPage-SovYc7X1-B3BS2dbe.js → NotificationSettingsPage-slkQwvVZ-CHC42QkE.js} +16 -16
  118. package/dist/assets/NotificationsListConfig-DtsQwW2b-qiwAhcXr.js +1 -0
  119. package/dist/assets/{NotificationsPage-D1uWQ3_a-DxSIxDxP.js → NotificationsPage-BAyRPK64-CK6wfh9r.js} +32 -32
  120. package/dist/assets/{OpExByVendorPage-bwyUuTg3-r5i2RybY.js → OpExByVendorPage-CofD6hKi-CAsz1_Xh.js} +5 -5
  121. package/dist/assets/{OverlayContainerPage-C0rUb6-5-DlNZMe2A.js → OverlayContainerPage-nhe7xtoR-BoqVZnRB.js} +1 -1
  122. package/dist/assets/{PandLWithForecastPage-C316N1hQ-aHIR4J9h.js → PandLWithForecastPage-_uOEFXiy-CCb56j7T.js} +7 -7
  123. package/dist/assets/{PaymentAccountSetupBillingAddressSection-07laMoUE-vyb_PzAc.js → PaymentAccountSetupBillingAddressSection-C0zGxU4f-CRvVxf4b.js} +8 -8
  124. package/dist/assets/{PeoplePage-nMBpp-i7-C_FzQc4I.js → PeoplePage-8GExF-Lt-BPrOO_zy.js} +19 -19
  125. package/dist/assets/{PortfolioAllocationFormPage-BNM5_3mQ-DaO3Xs0l.js → PortfolioAllocationFormPage-CMKEE7P7-CSoW27F2.js} +3 -3
  126. package/dist/assets/{PortfolioDetails-Cxr764um-DhzbvH6Q.js → PortfolioDetails-A3P3vG57-BlNZUWBn.js} +11 -11
  127. package/dist/assets/{ProductsCarousel-W3-LEsKP-DbLcA25z.js → ProductsCarousel-D9H3mUJ--BvtxFJIQ.js} +7 -7
  128. package/dist/assets/{PromoBaseCards-zZLO1ftd-CE6hJoyp.js → PromoBaseCards-CF0Bv_9G-CKYPGzvR.js} +25 -25
  129. package/dist/assets/{QBOConnectionDialog-027QZpKQ-BMM6Z1LZ.js → QBOConnectionDialog-D2zi5wKm-DM4ITFKi.js} +6 -6
  130. package/dist/assets/{QBOSetupSection-BT0OZMcW-35drr2J_.js → QBOSetupSection-B3Dj2g2k-Cs2MQ5jD.js} +11 -11
  131. package/dist/assets/{ReimbursementApprovalRuleDetailPage-DsBcRdLI-4vSu0HBp.js → ReimbursementApprovalRuleDetailPage-DgpHHy3U-MMqXWdUz.js} +1 -1
  132. package/dist/assets/{ReimbursementApprovalRulesPage-DFUfuIiJ-CI-ZWabB.js → ReimbursementApprovalRulesPage-BjFi-uJl-DaBDnL86.js} +8 -8
  133. package/dist/assets/{ReimbursementDetailPage-8b3khOnV-B2Q02bEe.js → ReimbursementDetailPage-BersvjG9-CiBW1b2M.js} +7 -7
  134. package/dist/assets/{ReimbursementPromoPage-BDuxIiMu-BQx3j8pw.js → ReimbursementPromoPage-K8dT-rtu-Dt7hPy-o.js} +16 -16
  135. package/dist/assets/{ReimbursementSetUpPage-CQnnv-Km-dR4LVsPp.js → ReimbursementSetUpPage-CfBuIpx6-al_7hXdG.js} +12 -12
  136. package/dist/assets/{ReimbursementsBulkReviewDrawerPage-B42Iy6Wl-CPgHrEv8.js → ReimbursementsBulkReviewDrawerPage-yaSD_tF5-D0BnyUB5.js} +1 -1
  137. package/dist/assets/{ReloadCard-BRfBNfTQ-BU52RUhd.js → ReloadCard-Do9Znv21-DK8BGS1A.js} +5 -5
  138. package/dist/assets/{ReportTableViewSelector-CsIuIfQF-CglQQFO3.js → ReportTableViewSelector-D1UrK7VQ-C8LWU1S2.js} +7 -7
  139. package/dist/assets/{ReportsPage-BgjHAROL-CDbPtbWw.js → ReportsPage-dER5Ukfc-SfboVh2R.js} +9 -9
  140. package/dist/assets/{RevenueChart-DSSPucUL-BpbrhJFv.js → RevenueChart-CCr_XauF-D36ZxwH2.js} +1 -1
  141. package/dist/assets/{ReviewDetailsPage-DRTS4tm7-GkJsi7Yf.js → ReviewDetailsPage-ZoXTLGfR-B_ONtomw.js} +19 -19
  142. package/dist/assets/{ReviewOverlay-fCgnrRah-tZ00a0Uu.js → ReviewOverlay-Bywh-8pJ-Bg5lskK_.js} +14 -14
  143. package/dist/assets/{RoleWithToolTip-aKLOITw0-B48eYV-X.js → RoleWithToolTip-CX9tF-BO-DG7wC_Jt.js} +6 -6
  144. package/dist/assets/{ScheduleDetailsFixedAssetsPage-ChR3tFhH-e-z1NRNI.js → ScheduleDetailsFixedAssetsPage-BEXr2qc0-3xkvpS1C.js} +8 -8
  145. package/dist/assets/{ScheduleDetailsPage-DmVZaX9M-CeCNgksq.js → ScheduleDetailsPage-CR8uJC5O-DnUdhwKF.js} +3 -3
  146. package/dist/assets/{ScheduleSequenceTable-CqrIr7OX-Cen2QelK.js → ScheduleSequenceTable-D7kDvImN-DWkMGP8Z.js} +50 -50
  147. package/dist/assets/{ScreenRoutes-ByaRWdsC.js → ScreenRoutes-erL9wWZG.js} +1 -1
  148. package/dist/assets/{SetUpAccountSection-DkqyfYdP-DWiWb20O.js → SetUpAccountSection-B0J0zCOF-oWsU5thz.js} +103 -103
  149. package/dist/assets/{SetUpDefaultSection-CEcqnqlD-BSjLZl3B.js → SetUpDefaultSection-ES6v0-xw-oKoRPhrf.js} +16 -16
  150. package/dist/assets/{SignIn-BKCeqJmF-B6GB44w2.js → SignIn-yQ-8MBRA-D6UXon_1.js} +19 -19
  151. package/dist/assets/{SignInScreen-BY-NI1BX.js → SignInScreen-DTuVG-E_.js} +1 -1
  152. package/dist/assets/{SpendManagementListViewPage-DWrIY48Y-1thafgez.js → SpendManagementListViewPage-_rUojA3M-DqnZrIvk.js} +13 -13
  153. package/dist/assets/{SpendManagementPerTabPage-BIK3QfAG-BprzbGtF.js → SpendManagementPerTabPage-Bhes-f7M-AdXufxw9.js} +47 -47
  154. package/dist/assets/{SpendManagementSection-BibcrHiQ-ojX7OXv7.js → SpendManagementSection-CQHWqht2-D_0KXsJm.js} +9 -9
  155. package/dist/assets/{SpendMgmtSetupAccountSection-BZzCEn49-xlvJK4VE.js → SpendMgmtSetupAccountSection-BHZ9nmWy-Ct-UFhaG.js} +14 -14
  156. package/dist/assets/{StatementItem-DujQ-hfS-Co0MjdA1.js → StatementItem-CKnsnb3u-CUpANIC7.js} +8 -8
  157. package/dist/assets/StatementsPage-B73U7d9e-BeHUtVc7.js +58 -0
  158. package/dist/assets/{StatusSwitcher-CmoFEW3h-B8khGWcG.js → StatusSwitcher-xR-S3KaW-DXC0VRqb.js} +4 -4
  159. package/dist/assets/{SubTabSwitcher-CZqJSgrt-BzzBfBEV.js → SubTabSwitcher-DczmDw-I-BDr0EcZn.js} +1 -1
  160. package/dist/assets/{SummaryCard-BC_pbmca-BA-2CDI2.js → SummaryCard-YTxf_JPz-Coldl1KM.js} +1 -1
  161. package/dist/assets/TaskManagementPage-LDFC29Ik-CNoI4m-y.js +508 -0
  162. package/dist/assets/{TimeRangeSwitcher-6HHMsbMu-BJeGDam3.js → TimeRangeSwitcher-C5yC8ifv-CCSUflgJ.js} +5 -5
  163. package/dist/assets/{TimeframeSwitcher-9Tl1lDvO-2gI3pMJ6.js → TimeframeSwitcher-D1xKpIjp-CW5UZCib.js} +5 -5
  164. package/dist/assets/TimeframeSwitcherWithToggle-BiHAqit5-B759eYFG.js +31 -0
  165. package/dist/assets/{TopExCard-BRR6W73W-BCkskQ6y.js → TopExCard-CJN2nSdQ-g0e-zKZy.js} +6 -6
  166. package/dist/assets/{TopExDetailPage-DzqG7MND-r9FRTnlF.js → TopExDetailPage-ClQK2WDh-DhYxPAx6.js} +11 -11
  167. package/dist/assets/{TransactionDetailPage-DD-5Uhso-5-XIEojv.js → TransactionDetailPage-CcNUBQmc-C-LCspti.js} +47 -47
  168. package/dist/assets/{TransactionList-B_1X_r62-D6FSjlP-.js → TransactionList-Dtqr5BZm--fERmRQ-.js} +13 -13
  169. package/dist/assets/{TransactionListBig-CUOjhYmg-CQ2RJ0bc.js → TransactionListBig-D5_iDOBi-D6XHrCJg.js} +18 -18
  170. package/dist/assets/{TransactionListPage-Ck8dLdRo-F9HAGy3S.js → TransactionListPage-DUCJRiyi-gKenoaPe.js} +6 -6
  171. package/dist/assets/{TransactionVendorDetailPage-C2_Yo1np-DO9ni0JA.js → TransactionVendorDetailPage-DSpchZAl-Dh-5qwdH.js} +6 -6
  172. package/dist/assets/{TransferDrawerPage-D9sHV8Dz-C3BJeiz0.js → TransferDrawerPage-BKWQEojA-hbYmgGo9.js} +28 -28
  173. package/dist/assets/{TreasuryOverviewPage-Co2mrPcn-BY4IGK6R.js → TreasuryOverviewPage-D1D2WipM-D-3r290_.js} +31 -31
  174. package/dist/assets/{TreasuryPromoPage-x3aBAAof-CzINUoky.js → TreasuryPromoPage-BKgJHnC1-CFaA1Ntn.js} +15 -15
  175. package/dist/assets/TreasurySetupPage-C2JtTOhh-RYkURx4_.js +152 -0
  176. package/dist/assets/{TreasuryStatementsPage-BIxlBphR-CLkwORFF.js → TreasuryStatementsPage-DKHWWnrU-D8FyTRXK.js} +7 -7
  177. package/dist/assets/{TreasuryTaxLetterPage-00l2eDaD-D4R_SIte.js → TreasuryTaxLetterPage-ieX9MUQd-DjUqrhOK.js} +7 -7
  178. package/dist/assets/{TreasuryTransferOrReviewPage-8kYRXJ8--BXlfWwAt.js → TreasuryTransferOrReviewPage-DebuIwR3-C0bGE1CG.js} +85 -85
  179. package/dist/assets/{TrendChart-CnawkdG8-C1f54OIB.js → TrendChart-B3VgdtYY-DKvOx-kx.js} +3 -3
  180. package/dist/assets/{TrendWithTransactions-CNNCV2hi-Lc8Mvmvx.js → TrendWithTransactions-BMorBxWJ-Bk3io0dy.js} +3 -3
  181. package/dist/assets/{UncategorizedAccountsMappingPage-6dSPWwUH-BNmql1oS.js → UncategorizedAccountsMappingPage-BtmfySl9-ChDGqLCY.js} +15 -15
  182. package/dist/assets/{UnitIntegrationPage-CQz8bAr--Be6E8wgt.js → UnitIntegrationPage-ByqJQgJ1-DOZOjWB7.js} +4 -4
  183. package/dist/assets/{UploadAdditionalDocumentOverlay-qVx1t-kK-BfnzSXgO.js → UploadAdditionalDocumentOverlay-Dwv3x7HQ-DAFruYVO.js} +1 -1
  184. package/dist/assets/{Vendor2FAPopup-BwICX5Jo-DRxdFSoT.js → Vendor2FAPopup-BVCUSOMr-DusuQd4O.js} +1 -1
  185. package/dist/assets/{VendorACHDetailsPage-U9vQ2YO1-C3wP_7rP.js → VendorACHDetailsPage-Cyp1bTJx-Bb_u0lQ9.js} +1 -1
  186. package/dist/assets/{VendorDetailPage-v3AJufvV-B6BEQrJw.js → VendorDetailPage-1_rVoehK-Exna90A5.js} +15 -15
  187. package/dist/assets/{VendorDomesticWireDetailsPage-DY5Enpxz-CMAOISi3.js → VendorDomesticWireDetailsPage-B0wv2GP--CBJnbhVR.js} +1 -1
  188. package/dist/assets/{VendorFiling1099EditablePage-BJ1K4EB2-CnqK8eQN.js → VendorFiling1099EditablePage-C5rHkQrV-BGIvQipF.js} +10 -10
  189. package/dist/assets/{VendorFirstReviewPage-Dqu2JeBh-BTSOdkvj.js → VendorFirstReviewPage-CDlmZHmw-QoRtPJE2.js} +29 -29
  190. package/dist/assets/{VendorInternationalWireDetailsPage-B3jL5IpJ-Ge2HUtcT.js → VendorInternationalWireDetailsPage-Cdy000Jx-J6b7bfbg.js} +7 -7
  191. package/dist/assets/{VendorInternationalWireSwiftDetailsPage-OyW2sXjN-BaDu_Rbp.js → VendorInternationalWireSwiftDetailsPage-DRN-5n5Y-CNM_VAVJ.js} +1 -1
  192. package/dist/assets/{VendorsAccountsSection-CnVky8J2-BnxyHrsh.js → VendorsAccountsSection-Ba7QpWAm-CKQDggOk.js} +4 -4
  193. package/dist/assets/{WarningsDrawerPage-Bc8HwhJZ-CoRSEL1r.js → WarningsDrawerPage-DCUPzxfi-BYSPfHfW.js} +4 -4
  194. package/dist/assets/{ZeniAccountDetailPage-I3Qn-mIV-D6WbzhnA.js → ZeniAccountDetailPage-DF7Tn3t3-yyv_Cgn9.js} +28 -28
  195. package/dist/assets/{ZeniAccountListViewPage-BFUoGrvu-CvFvWDHE.js → ZeniAccountListViewPage-Cz9v3TCo-D-RvbaDA.js} +18 -18
  196. package/dist/assets/ZeniAccountNavBarPieces-BSObmR0D-w7GK2i5h.js +14 -0
  197. package/dist/assets/{ZeniAccountPromoPage-B_Kt_gIx-BmUo-cHo.js → ZeniAccountPromoPage-D7veJGZk-D-YrsEI2.js} +10 -10
  198. package/dist/assets/{ZeniAccountSetupPage-BvzXgVNr-Cojq6XAe.js → ZeniAccountSetupPage-ftl559Pj-C-xIgDUh.js} +1 -1
  199. package/dist/assets/{ZeniCopyright-B5gFkT_K-Bd1To88b.js → ZeniCopyright-BScA_p2_-CnTtKSEg.js} +1 -1
  200. package/dist/assets/{ZeniTransferAmountSlider-dNQVv3xh-Dj4F9WJ8.js → ZeniTransferAmountSlider-Bu23FZCA-BlrXEMp9.js} +1 -1
  201. package/dist/assets/analytics-BSSiLa6f.js +7 -0
  202. package/dist/assets/{analyticsHelper-DaI4EFSR.js → analyticsHelper-C8rNMzIR.js} +1 -1
  203. package/dist/assets/{analyticsHelper-CiRIn2W--BxtgqDE2.js → analyticsHelper-CGq-fGOi-peFW_WyF.js} +1 -1
  204. package/dist/assets/{chartTypes-om8APqYr-BLTaCwIq.js → chartTypes-ChsIdl40-BE86tbr4.js} +1 -1
  205. package/dist/assets/{commonDimensions-CnEuBCL0-BaKrm6VO.js → commonDimensions-Dk1fkj7r-DLRSQmNd.js} +1 -1
  206. package/dist/assets/{detailCommon-B8snZE0k-CD_QEBke.js → detailCommon-BdiFpATU-WeUxnZIy.js} +6 -6
  207. package/dist/assets/{downloadPdf-UYNSbWcH-CCjYi8d_.js → downloadPdf-h21F3Bzk-CjxZKaAj.js} +1 -1
  208. package/dist/assets/{index-C5RQ_I4f.js → index-C0q2xQ43.js} +3324 -3364
  209. package/dist/assets/{liveblocks-sSQ9JElv.js → liveblocks-BUGn2yQ6.js} +1 -1
  210. package/dist/assets/{mapLoadingInProgressToTreeNode-Ct5Hw9GL-CIhY2PIH.js → mapLoadingInProgressToTreeNode-Bimz-BOL-Dlsg7XHk.js} +1 -1
  211. package/dist/assets/{mapSectionWithAcOnlyToTreeNode-DAi-q9qz-uRnsjJzp.js → mapSectionWithAcOnlyToTreeNode-Dy2RH2lH-Bxhhy_dm.js} +1 -1
  212. package/dist/assets/{mapSpacerToTreeNode-NdVrr_Rq-h2jl1W7n.js → mapSpacerToTreeNode-CadZGfr8-CsWvhMid.js} +1 -1
  213. package/dist/assets/{mapTimeframeBalancesToTreeNode-Bq1k2j24-C-EGB4JJ.js → mapTimeframeBalancesToTreeNode-BvXiirfs-D7NlfjoQ.js} +1 -1
  214. package/dist/assets/mui-BgvZYSo0.js +22 -0
  215. package/dist/assets/{play-icon-cU_HA46u-DKk-rWaT.js → play-icon-DD7TfH-R-B2AdmUNp.js} +1 -1
  216. package/dist/assets/{redux-ByjIRbhZ.js → redux-DmDqXYej.js} +1 -1
  217. package/dist/assets/{routing-Cpaypegg.js → routing-BNz5gZgX.js} +1 -1
  218. package/dist/assets/{toCOABalancesWithID-D8CsJNcd-D3oEVThj.js → toCOABalancesWithID-Dy9J_UtA-GKQFY-wL.js} +1 -1
  219. package/dist/assets/{toChartData-DUoI4wMR-BpwvMCd8.js → toChartData-BdomEAJ--DBqHs0fD.js} +1 -1
  220. package/dist/assets/{treasuryColorHelper-X9PYqjk_-B0f97nM8.js → treasuryColorHelper-D2LtJllD-BWyq3ShU.js} +1 -1
  221. package/dist/assets/{uploadAttachment-BHcSLQXP-Dd6nHf0l.js → uploadAttachment-C5PL0FaC-qWy-M3Ai.js} +29 -29
  222. package/dist/assets/{uploadReceipts-Buvz7DfG-TsfYrPiB.js → uploadReceipts-BH9fi3Vt-Bn1YAl68.js} +1 -1
  223. package/dist/index.html +1 -1
  224. package/package.json +5 -5
  225. package/dist/assets/AccountInfoPage-DygdgdmU-DOUY2WTN.js +0 -18
  226. package/dist/assets/AccountRow-CpUAoVFw-BuMEboIn.js +0 -298
  227. package/dist/assets/BillingSettingsPage-CqFQk_xm-Wzi8-Pxm.js +0 -44
  228. package/dist/assets/BillsBulkReviewDrawerPage-Bo9JcC7R-D0jNWqxU.js +0 -1
  229. package/dist/assets/ChargeCardPromoPage-CIboCUSV-y-DLxjGT.js +0 -190
  230. package/dist/assets/CheckDepositDrawerPage-K9NmaIpu-DOGNQqAq.js +0 -206
  231. package/dist/assets/ConfettiBurst-Bvvql-8k-BorMAewb.js +0 -1
  232. package/dist/assets/CustomerOnboardingContainerPage-BsErtHzd-BdcZe_io.js +0 -1
  233. package/dist/assets/CustomerOnboardingPage-C1pKcpFC-CGanCl6o.js +0 -107
  234. package/dist/assets/Dashboard-CyZG5DEY-C3KfWHk8.js +0 -1251
  235. package/dist/assets/DomesticWireDetailsPage-BbmbS2h3-Ch-Vtjq-.js +0 -21
  236. package/dist/assets/EditPeoplePage-QsjUi5_S-DkWH1BmJ.js +0 -55
  237. package/dist/assets/HelpButton-DYFzwkI3-Cel7B9gC.js +0 -28
  238. package/dist/assets/InvitePeoplePage-CV75uhrr-B1Hdsrwm.js +0 -12
  239. package/dist/assets/LabeledDocumentField-IC75UO-m-BR65Je6h.js +0 -41
  240. package/dist/assets/LabeledDropDownFormattedTextField-DRdoEEXa-ihK1IWBq.js +0 -59
  241. package/dist/assets/NoDataChart-CEPkoKCh-CJB-ycSI.js +0 -26
  242. package/dist/assets/NotificationsListConfig-8oQmiFyf-BOGk1_4Q.js +0 -1
  243. package/dist/assets/StatementsPage-BEBaWRll-Dv0qqBwe.js +0 -58
  244. package/dist/assets/TaskManagementPage-IrjSDISn-Cdu4CkH2.js +0 -508
  245. package/dist/assets/TimeframeSwitcherWithToggle-L5acx38l-CrZfZFxd.js +0 -31
  246. package/dist/assets/TreasurySetupPage-COLv35Sa-D7XzYH1g.js +0 -152
  247. package/dist/assets/ZeniAccountNavBarPieces-B6K9Q5ca-BG64SHxp.js +0 -14
  248. package/dist/assets/analytics-DThoELaW.js +0 -7
  249. package/dist/assets/mui-C5LQ0bMa.js +0 -25
@@ -1,4 +1,4 @@
1
- import{X as T,cf as B,a1 as A,cn as S,M as I,C as n,j as a,Y as z,c5 as x,c7 as w,cl as M,ag as L,o as g,eP as R,eR as V,p as t,d as C,q}from"./index-C5RQ_I4f.js";import{b as H,n as b}from"./vendor-CnQcJ2Lu.js";const E=b.div`
1
+ import{X as T,cg as B,a5 as A,co as S,M as I,C as n,j as a,Y as z,c6 as x,c8 as w,cm as M,am as L,o as g,eS as R,eU as V,p as t,d as C,s as q}from"./index-C0q2xQ43.js";import{b as H,n as b}from"./vendor-CnQcJ2Lu.js";const E=b.div`
2
2
  color: ${e=>e.theme.colors.primary};
3
3
  align-items: center;
4
4
  justify-content: flex-end;
@@ -37,7 +37,7 @@ import{X as T,cf as B,a1 as A,cn as S,M as I,C as n,j as a,Y as z,c5 as x,c7 as
37
37
  border-bottom-left-radius: inherit;
38
38
  border-bottom-right-radius: inherit;
39
39
  }
40
- `,u={largeLabelWidth:new n(120,140,220),paddingTopBottom:new n(t[2],t[2]),labelHeight:new n(t[6],t[6]),labelMarginLeft:new n(t[3],t[4]),labelMarginRight:new n(t[3],t[4]),labelMarginTop:new n(t[2],t[2]),controlHeight:new n(t[6],t[6])},U=({sectionId:e,bankAccountToCreate:i,isDisabled:o,fetchBankNameByRoutingStatus:s,style:h})=>{const m=T(),{getValues:P,setValue:N,formState:{errors:D}}=B(),v=A(s.fetchState),k=A(i?.bankRoutingNumber),$=S(D,r(e,"bankName"));H.useEffect(()=>{(v==="In-Progress"||k!=null&&k!==i?.bankRoutingNumber)&&s.fetchState==="Completed"&&i?.bankName!=null&&N(r(e,"bankName"),i?.bankName,{shouldValidate:$})},[v,k,$,s.fetchState,e,i?.bankName,i?.bankRoutingNumber,N]);const j=s.fetchState==="Completed"||s.fetchState==="Error"?o:"disabled",y=I.getLocalizedStrings().spendManagement.billPay.vendorCreation,{achDetails:l}=y,c=u.largeLabelWidth.value(m);return a.jsx(K,{style:h,"data-testid":z("bank-account-section",e),children:a.jsxs(J,{children:[a.jsx(x,{label:{label:l.bankRoutingNumber,width:c},text:{type:"text",name:r(e,"bankRoutingNumber"),placeholder:w(l.bankRoutingNumber),defaultValue:i?.bankRoutingNumber,options:{required:!0,pattern:/^\d{9}$/}},isDisabled:o,style:{width:"auto"},showAdditionalInfoLabel:!1,additionalInfoLabel:l.invalidRoutingNumber}),a.jsx(f,{}),s.fetchState==="In-Progress"?a.jsx(O,{label:{label:l.bankName,width:c},loader:{placeholder:l.fetchingBankName},style:{width:"auto"}}):a.jsx(x,{label:{label:l.bankName,width:c},text:{type:"text",name:r(e,"bankName"),placeholder:w(l.bankName),defaultValue:i?.bankName,options:{required:!0}},isDisabled:j,style:{width:"auto",opacity:j==="disabled"?.32:1},showAdditionalInfoLabel:!1,additionalInfoLabel:l.invalidBankName}),a.jsx(f,{}),a.jsxs(Q,{size:m,children:[a.jsx(M,{label:y.achDetails.accountTypeLabel,htmlFor:r(e,"bankAccountType"),style:{marginLeft:u.labelMarginLeft.value(m),marginRight:u.labelMarginRight.value(m),width:c}}),a.jsxs(X,{labelWidth:c,size:m,children:[a.jsx(L,{label:{label:y.achDetails.checkingAccountTypeLabel},style:{paddingRight:`${g.sp4}`,width:"auto"},radioField:{name:r(e,"bankAccountType"),id:"checking",value:"checking",registerOptions:{required:!0}}}),a.jsx(L,{label:{label:y.achDetails.savingsAccountTypeLabel},style:{width:"auto"},radioField:{name:r(e,"bankAccountType"),id:"savings",value:"savings",registerOptions:{required:!0}}})]})]}),a.jsx(f,{}),a.jsx(x,{label:{label:l.bankAccountNumber,width:c},text:{type:"text",name:r(e,"bankAccountNumber"),placeholder:w(l.bankAccountNumber),defaultValue:i?.bankAccountNumber,options:{required:!0,validate:p=>p!=null?V.accountNumber(p).isValid:!0,pattern:R}},isDisabled:o,style:{width:"auto"},showAdditionalInfoLabel:!1,additionalInfoLabel:l.invalidAccountNumber}),a.jsx(f,{}),a.jsx(x,{label:{label:l.confirmedBankAccountNumber,width:c},text:{type:"text",name:r(e,"confirmedBankAccountNumber"),placeholder:l.confirmedBankAccountNumberPlaceholder,defaultValue:i?.confirmedBankAccountNumber,options:{required:!0,pattern:R,validate:p=>p!=null?P(`${e}.bankAccountNumber`)===p:!1}},disableCopyPaste:!0,isDisabled:o,style:{width:"auto"},showAdditionalInfoLabel:!1,additionalInfoLabel:l.accountNumberDontMatch}),a.jsx(f,{}),a.jsx(x,{label:{label:l.accountNickName,width:c},text:{type:"text",name:r(e,"bankAccountName"),placeholder:w(l.accountNickName),defaultValue:i?.bankAccountName,options:{required:!1}},isDisabled:o,style:{width:"auto"}})]})})},r=(e,i)=>`${e}.${i}`,K=b.div`
40
+ `,u={largeLabelWidth:new n(120,140,220),paddingTopBottom:new n(t[2],t[2]),labelHeight:new n(t[6],t[6]),labelMarginLeft:new n(t[3],t[4]),labelMarginRight:new n(t[3],t[4]),labelMarginTop:new n(t[2],t[2]),controlHeight:new n(t[6],t[6])},_=({sectionId:e,bankAccountToCreate:i,isDisabled:o,fetchBankNameByRoutingStatus:s,style:h})=>{const m=T(),{getValues:D,setValue:N,formState:{errors:P}}=B(),v=A(s.fetchState),k=A(i?.bankRoutingNumber),$=S(P,r(e,"bankName"));H.useEffect(()=>{(v==="In-Progress"||k!=null&&k!==i?.bankRoutingNumber)&&s.fetchState==="Completed"&&i?.bankName!=null&&N(r(e,"bankName"),i?.bankName,{shouldValidate:$})},[v,k,$,s.fetchState,e,i?.bankName,i?.bankRoutingNumber,N]);const j=s.fetchState==="Completed"||s.fetchState==="Error"?o:"disabled",y=I.getLocalizedStrings().spendManagement.billPay.vendorCreation,{achDetails:l}=y,c=u.largeLabelWidth.value(m);return a.jsx(K,{style:h,"data-testid":z("bank-account-section",e),children:a.jsxs(J,{children:[a.jsx(x,{label:{label:l.bankRoutingNumber,width:c},text:{type:"text",name:r(e,"bankRoutingNumber"),placeholder:w(l.bankRoutingNumber),defaultValue:i?.bankRoutingNumber,options:{required:!0,pattern:/^\d{9}$/}},isDisabled:o,style:{width:"auto"},showAdditionalInfoLabel:!1,additionalInfoLabel:l.invalidRoutingNumber}),a.jsx(f,{}),s.fetchState==="In-Progress"?a.jsx(O,{label:{label:l.bankName,width:c},loader:{placeholder:l.fetchingBankName},style:{width:"auto"}}):a.jsx(x,{label:{label:l.bankName,width:c},text:{type:"text",name:r(e,"bankName"),placeholder:w(l.bankName),defaultValue:i?.bankName,options:{required:!0}},isDisabled:j,style:{width:"auto",opacity:j==="disabled"?.32:1},showAdditionalInfoLabel:!1,additionalInfoLabel:l.invalidBankName}),a.jsx(f,{}),a.jsxs(Q,{size:m,children:[a.jsx(M,{label:y.achDetails.accountTypeLabel,htmlFor:r(e,"bankAccountType"),style:{marginLeft:u.labelMarginLeft.value(m),marginRight:u.labelMarginRight.value(m),width:c}}),a.jsxs(U,{labelWidth:c,size:m,children:[a.jsx(L,{label:{label:y.achDetails.checkingAccountTypeLabel},style:{paddingRight:`${g.sp4}`,width:"auto"},radioField:{name:r(e,"bankAccountType"),id:"checking",value:"checking",registerOptions:{required:!0}}}),a.jsx(L,{label:{label:y.achDetails.savingsAccountTypeLabel},style:{width:"auto"},radioField:{name:r(e,"bankAccountType"),id:"savings",value:"savings",registerOptions:{required:!0}}})]})]}),a.jsx(f,{}),a.jsx(x,{label:{label:l.bankAccountNumber,width:c},text:{type:"text",name:r(e,"bankAccountNumber"),placeholder:w(l.bankAccountNumber),defaultValue:i?.bankAccountNumber,options:{required:!0,validate:p=>p!=null?V.accountNumber(p).isValid:!0,pattern:R}},isDisabled:o,style:{width:"auto"},showAdditionalInfoLabel:!1,additionalInfoLabel:l.invalidAccountNumber}),a.jsx(f,{}),a.jsx(x,{label:{label:l.confirmedBankAccountNumber,width:c},text:{type:"text",name:r(e,"confirmedBankAccountNumber"),placeholder:l.confirmedBankAccountNumberPlaceholder,defaultValue:i?.confirmedBankAccountNumber,options:{required:!0,pattern:R,validate:p=>p!=null?D(`${e}.bankAccountNumber`)===p:!1}},disableCopyPaste:!0,isDisabled:o,style:{width:"auto"},showAdditionalInfoLabel:!1,additionalInfoLabel:l.accountNumberDontMatch}),a.jsx(f,{}),a.jsx(x,{label:{label:l.accountNickName,width:c},text:{type:"text",name:r(e,"bankAccountName"),placeholder:w(l.accountNickName),defaultValue:i?.bankAccountName,options:{required:!1}},isDisabled:o,style:{width:"auto"}})]})})},r=(e,i)=>`${e}.${i}`,K=b.div`
41
41
  display: flex;
42
42
  flex-direction: column;
43
43
  `,J=b.div`
@@ -67,7 +67,7 @@ import{X as T,cf as B,a1 as A,cn as S,M as I,C as n,j as a,Y as z,c5 as x,c7 as
67
67
  z-index: 1;
68
68
  outline: 1px solid ${e=>e.theme.colors.primary};
69
69
  }
70
- `,X=b.div`
70
+ `,U=b.div`
71
71
  display: flex;
72
72
  flex-direction: row;
73
73
  width: ${e=>`calc(100% - ${e.labelWidth}px)`};
@@ -76,4 +76,4 @@ import{X as T,cf as B,a1 as A,cn as S,M as I,C as n,j as a,Y as z,c5 as x,c7 as
76
76
  flex-grow: 1;
77
77
  height: ${e=>u.controlHeight.valuePx(e.size)};
78
78
  align-items: center;
79
- `;export{U as e};
79
+ `;export{_ as e};
@@ -1,4 +1,4 @@
1
- import{X as u,j as o,Y as $,bs as w,M as b,o as e,C as a,bo as k,Q as f,h as v,g as l,eQ as j,q as z,p as r}from"./index-C5RQ_I4f.js";import{n}from"./vendor-CnQcJ2Lu.js";const{common:{navBar:{back:C}}}=b.getLocalizedStrings(),s={navBarContainerPadding:new a(10,r[3]),customTitleMarginBottom:new a(r[0],r[3]),customTitleMarginLeft:new a(r[3],r[6]),customTitleMarginRight:new a(r[5],r[8])},P={formTitle:new f("h6Medium","h5Medium")},G=({header:i,isDirty:d,isMagicLink:g,onBackClick:m,setShowConfirmationPopup:p})=>{const t=u();return o.jsxs(o.Fragment,{children:[t==="small"?o.jsxs(M,{windowSize:t,children:[g?null:o.jsx(x,{onClick:()=>d?p?.(!0):m?.(),"data-testid":$("bank-account-page-back-click-mobile")}),o.jsx(h,{windowSize:t,children:i})]}):o.jsx(y,{children:g?null:o.jsx(w,{title:C,enterDelay:600,placement:"bottom",children:o.jsx(x,{onClick:()=>d?p?.(!0):m?.(),"data-testid":$("bank-account-page-back-click")})})}),t!=="small"?o.jsx(h,{windowSize:t,children:i}):null]})},h=n(v)`
1
+ import{X as u,j as o,Y as $,bu as w,M as b,o as e,C as a,bq as k,Q as f,h as v,g as l,eT as j,s as z,p as r}from"./index-C0q2xQ43.js";import{n}from"./vendor-CnQcJ2Lu.js";const{common:{navBar:{back:C}}}=b.getLocalizedStrings(),s={navBarContainerPadding:new a(10,r[3]),customTitleMarginBottom:new a(r[0],r[3]),customTitleMarginLeft:new a(r[3],r[6]),customTitleMarginRight:new a(r[5],r[8])},P={formTitle:new f("h6Medium","h5Medium")},G=({header:i,isDirty:d,isMagicLink:g,onBackClick:m,setShowConfirmationPopup:p})=>{const t=u();return o.jsxs(o.Fragment,{children:[t==="small"?o.jsxs(M,{windowSize:t,children:[g?null:o.jsx(x,{onClick:()=>d?p?.(!0):m?.(),"data-testid":$("bank-account-page-back-click-mobile")}),o.jsx(h,{windowSize:t,children:i})]}):o.jsx(y,{children:g?null:o.jsx(w,{title:C,enterDelay:600,placement:"bottom",children:o.jsx(x,{onClick:()=>d?p?.(!0):m?.(),"data-testid":$("bank-account-page-back-click")})})}),t!=="small"?o.jsx(h,{windowSize:t,children:i}):null]})},h=n(v)`
2
2
  ${i=>`${P.formTitle.style(i.windowSize)}`};
3
3
  color: ${i=>i.theme.colors.primary};
4
4
  margin-bottom: ${i=>s.customTitleMarginBottom.valuePx(i.windowSize)};
@@ -26,7 +26,7 @@ import{X as u,j as o,Y as $,bs as w,M as b,o as e,C as a,bo as k,Q as f,h as v,g
26
26
  padding-left: ${e.sp0};
27
27
  z-index: 2;
28
28
  background-color: ${i=>i.theme.colors.grey4};
29
- `,c={marginBottom:new a(r[5],r[3]),marginRight:new a(r[3],r[8]),marginLeft:new a(r[3],r[6])},Q=({warningText:i})=>{const d=u();return o.jsxs(S,{size:d,children:[o.jsx(T,{children:o.jsx(D,{})}),o.jsx(B,{children:i})]})},S=n.div`
29
+ `,c={marginBottom:new a(r[5],r[3]),marginRight:new a(r[3],r[8]),marginLeft:new a(r[3],r[6])},Q=({warningText:i})=>{const d=u();return o.jsxs(S,{size:d,children:[o.jsx(B,{children:o.jsx(L,{})}),o.jsx(T,{children:i})]})},S=n.div`
30
30
  display: flex;
31
31
  background-color: ${l.alertLight};
32
32
  border: 1px solid ${l.brandColorGoldDark};
@@ -36,15 +36,15 @@ import{X as u,j as o,Y as $,bs as w,M as b,o as e,C as a,bo as k,Q as f,h as v,g
36
36
  padding: ${e.sp3} ${e.sp4} ${e.sp3} ${e.sp4};
37
37
  margin-right: ${i=>c.marginRight.valuePx(i.size)};
38
38
  margin-left: ${i=>c.marginLeft.valuePx(i.size)};
39
- `,B=n(z)`
39
+ `,T=n(z)`
40
40
  display: flex;
41
41
  flex-grow: 1;
42
42
  color: ${l.brandColorGoldDark};
43
- `,T=n.div`
43
+ `,B=n.div`
44
44
  display: flex;
45
45
  align-items: center;
46
46
  margin-right: ${e.sp2};
47
- `,D=n(j)`
47
+ `,L=n(j)`
48
48
  width: ${e.sp4};
49
49
  height: ${e.sp4};
50
50
  color: ${l.brandColorGoldDark};
@@ -1,4 +1,4 @@
1
- import{u as ae,X as we,a as He,c2 as qe,j as t,aW as Je,M as J,o as i,d as q,bJ as Ge,F as Ye,bs as Qe,C as f,f as Ze,q as A,an as Xe,v as Ie,Q as Ke,cf as et,a1 as de,a7 as K,eX as tt,l as Q,cn as nt,aQ as Le,f3 as Oe,f4 as it,f5 as ot,bB as $e,p as h,eY as ee,eZ as te,_ as ne,bU as ie,Y as at,b4 as lt,dG as Fe,g as V,w as v,f2 as ct,fg as st,fh as rt,aA as dt,fi as ut}from"./index-C5RQ_I4f.js";import{b,n}from"./vendor-CnQcJ2Lu.js";import{a as pt}from"./SetUpAccountSection-DkqyfYdP-DWiWb20O.js";import{r as ht}from"./mui-C5LQ0bMa.js";import{M as mt}from"./ChaseOverlay-BrHcqwQQ-D5p6lw7W.js";import{R as gt,z as wt}from"./SpendMgmtSetupAccountSection-BZzCEn49-xlvJK4VE.js";import"./analytics-DThoELaW.js";import"./routing-Cpaypegg.js";import"./sentry-HDxG13yk.js";import"./redux-ByjIRbhZ.js";import"./liveblocks-sSQ9JElv.js";import"./crypto-BURQLTgV.js";import"./SetUpDefaultSection-CEcqnqlD-BSjLZl3B.js";import"./ChargeCardUtils-BN7bbdUB-BbkRwxs1.js";import"./CreditCardPaymentPlgSection-CEjV1ee_-C66jG_cF.js";const{settings:{bankConnectionHeader:G}}=J.getLocalizedStrings().common,ft={value:G.productType,width:new f(100,19)},xt={value:G.primaryAccount,width:new f(100,36)},yt={value:G.linkAccount,width:new f(100,22)},St={value:G.status,width:new f(12,12)},bt={value:G.balance,width:new f(12,13)},P=[ft,xt,yt,St,bt],{common:{settings:ue,strings:{empty:vt,hyphen:$t}}}=J.getLocalizedStrings(),Z={paymentAccountIconSize:new f(h[6],h[7])},zt=()=>null,kt=({paymentAccount:e,bankAccountList:a,balanceFetchStatus:L,onRemoveConnection:O})=>{const s=ae(),d=we(),[$,z]=b.useState(!1),w=e?.providerVerificationStatus,c=s.mode==="light"?new K(s.colors.brandColorJadeLight):new K(s.colors.brandColorJadeDark),F={element:t.jsx(Bt,{windowSize:d}),color:c},M=a.find(l=>l.accountId===e.zeniAccountId),R=()=>{z(l=>!l)};return t.jsxs(jt,{onMouseEnter:R,onMouseLeave:R,children:[t.jsxs(At,{windowSize:d,wrapperWidth:P[0].width,children:[t.jsx(Ct,{children:ue.otherAccount.title}),t.jsx(Tt,{children:ue.otherAccount.subTitle})]}),t.jsxs(Pt,{windowSize:d,wrapperWidth:P[1].width,children:[pt(F,d,s.mode==="dark",e,!0),t.jsxs(Wt,{children:[t.jsx(Dt,{children:t.jsx(Vt,{windowSize:d,children:e.institutionDetails.institutionName})}),t.jsx(Mt,{windowSize:d,children:t.jsxs(Ut,{children:[t.jsx(Et,{children:e.accountSubType?.name}),t.jsx(Nt,{children:e.maskedAccountNumber})]})})]})]}),t.jsx(_t,{windowSize:d,wrapperWidth:P[2].width,children:M?.accountName??vt}),t.jsx(It,{windowSize:d,wrapperWidth:P[3].width,children:w!=null?t.jsx(ee,{style:{width:"max-content",padding:0,marginTop:i.sp2},tagTitle:w.name,textColor:te(w.code)}):$t}),t.jsxs(Lt,{windowSize:d,wrapperWidth:P[4].width,children:[t.jsx(Ot,{className:"balanceLabel",isRemoveHovered:$,children:ne("0,0.[00]",e.balances?.available)}),e.balances?.lastRefreshTime?t.jsx(Ft,{className:"balanceLabel",isRemoveHovered:$,children:ie(e.balances?.lastRefreshTime)}):L?.fetchState==="In-Progress"?t.jsx(q,{size:"Small",start:!0}):null,$&&t.jsx(Rt,{children:t.jsx(Fe,{moreIconType:"plain",options:[{label:ue.otherAccount.remove,value:"remove"}],customStyleConfig:{valueContainer:()=>({height:i.sp3,".more-icon":{width:i.sp3,height:i.sp3,color:s.colors.primary}}),container:()=>({marginLeft:i.sp0,position:"relative"}),control:()=>({background:"transparent"}),menu:()=>({position:"absolute",right:0,borderRadius:i.sp1,marginTop:i.sp2,background:s.colors.grey5,width:"162px",border:`1px solid ${s.colors.grey3}`,boxShadow:`${i.sp0} 1px 2px ${i.sp0} ${V.boxShadowElevation}`}),option:()=>({height:i.sp6,paddingLeft:i.sp3,paddingRight:i.sp3,display:"flex",alignItems:"center",color:V.important,":hover":{color:V.important,backgroundColor:s.colors.background}})},menuPlacement:"bottom",onOptionSelection:l=>{l==="remove"&&O(e.paymentAccountId)},valueToIcon:zt})})]})]})},jt=n.div`
1
+ import{u as ae,X as we,a as He,c3 as qe,j as t,aW as Je,M as J,o as i,d as q,bK as Ge,F as Ye,bu as Ze,C as f,f as Qe,s as A,as as Ke,q as Ie,Q as Xe,cg as et,a5 as de,ab as X,e_ as tt,l as Z,co as nt,aQ as Le,f6 as Oe,f7 as it,f8 as ot,bD as $e,p as h,e$ as ee,f0 as te,_ as ne,bV as ie,Y as at,b6 as lt,dI as Fe,g as V,v,f5 as ct,fj as st,fk as rt,cZ as dt,fl as ut}from"./index-C0q2xQ43.js";import{b,n}from"./vendor-CnQcJ2Lu.js";import{n as pt}from"./SetUpAccountSection-B0J0zCOF-oWsU5thz.js";import{r as ht}from"./mui-BgvZYSo0.js";import{M as mt}from"./ChaseOverlay-B1cuawle-p6HzSxTf.js";import{R as gt,z as wt}from"./SpendMgmtSetupAccountSection-BHZ9nmWy-Ct-UFhaG.js";import"./analytics-BSSiLa6f.js";import"./routing-BNz5gZgX.js";import"./sentry-HDxG13yk.js";import"./redux-DmDqXYej.js";import"./liveblocks-BUGn2yQ6.js";import"./crypto-BURQLTgV.js";import"./SetUpDefaultSection-ES6v0-xw-oKoRPhrf.js";import"./ChargeCardUtils-CLpd-HDH-B3csze9l.js";import"./CreditCardPaymentPlgSection-D5CNl0oa-C-cdC2QZ.js";const{settings:{bankConnectionHeader:G}}=J.getLocalizedStrings().common,ft={value:G.productType,width:new f(100,19)},xt={value:G.primaryAccount,width:new f(100,36)},yt={value:G.linkAccount,width:new f(100,22)},St={value:G.status,width:new f(12,12)},bt={value:G.balance,width:new f(12,13)},P=[ft,xt,yt,St,bt],{common:{settings:ue,strings:{empty:vt,hyphen:$t}}}=J.getLocalizedStrings(),Q={paymentAccountIconSize:new f(h[6],h[7])},zt=()=>null,kt=({paymentAccount:e,bankAccountList:a,balanceFetchStatus:L,onRemoveConnection:O})=>{const s=ae(),d=we(),[$,z]=b.useState(!1),w=e?.providerVerificationStatus,c=s.mode==="light"?new X(s.colors.brandColorJadeLight):new X(s.colors.brandColorJadeDark),F={element:t.jsx(Wt,{windowSize:d}),color:c},M=a.find(l=>l.accountId===e.zeniAccountId),R=()=>{z(l=>!l)};return t.jsxs(jt,{onMouseEnter:R,onMouseLeave:R,children:[t.jsxs(At,{windowSize:d,wrapperWidth:P[0].width,children:[t.jsx(Ct,{children:ue.otherAccount.title}),t.jsx(Tt,{children:ue.otherAccount.subTitle})]}),t.jsxs(Pt,{windowSize:d,wrapperWidth:P[1].width,children:[pt(F,d,s.mode==="dark",e,!0),t.jsxs(Dt,{children:[t.jsx(Bt,{children:t.jsx(Vt,{windowSize:d,children:e.institutionDetails.institutionName})}),t.jsx(Mt,{windowSize:d,children:t.jsxs(Ut,{children:[t.jsx(Et,{children:e.accountSubType?.name}),t.jsx(Nt,{children:e.maskedAccountNumber})]})})]})]}),t.jsx(_t,{windowSize:d,wrapperWidth:P[2].width,children:M?.accountName??vt}),t.jsx(It,{windowSize:d,wrapperWidth:P[3].width,children:w!=null?t.jsx(ee,{style:{width:"max-content",padding:0,marginTop:i.sp2},tagTitle:w.name,textColor:te(w.code)}):$t}),t.jsxs(Lt,{windowSize:d,wrapperWidth:P[4].width,children:[t.jsx(Ot,{className:"balanceLabel",isRemoveHovered:$,children:ne("0,0.[00]",e.balances?.available)}),e.balances?.lastRefreshTime?t.jsx(Ft,{className:"balanceLabel",isRemoveHovered:$,children:ie(e.balances?.lastRefreshTime)}):L?.fetchState==="In-Progress"?t.jsx(q,{size:"Small",start:!0}):null,$&&t.jsx(Rt,{children:t.jsx(Fe,{moreIconType:"plain",options:[{label:ue.otherAccount.remove,value:"remove"}],customStyleConfig:{valueContainer:()=>({height:i.sp3,".more-icon":{width:i.sp3,height:i.sp3,color:s.colors.primary}}),container:()=>({marginLeft:i.sp0,position:"relative"}),control:()=>({background:"transparent"}),menu:()=>({position:"absolute",right:0,borderRadius:i.sp1,marginTop:i.sp2,background:s.colors.grey5,width:"162px",border:`1px solid ${s.colors.grey3}`,boxShadow:`${i.sp0} 1px 2px ${i.sp0} ${V.boxShadowElevation}`}),option:()=>({height:i.sp6,paddingLeft:i.sp3,paddingRight:i.sp3,display:"flex",alignItems:"center",color:V.important,":hover":{color:V.important,backgroundColor:s.colors.background}})},menuPlacement:"bottom",onOptionSelection:l=>{l==="remove"&&O(e.paymentAccountId)},valueToIcon:zt})})]})]})},jt=n.div`
2
2
  display: flex;
3
3
  padding: ${i.sp4};
4
4
  padding-right: ${i.sp8};
@@ -42,17 +42,17 @@ import{u as ae,X as we,a as He,c2 as qe,j as t,aW as Je,M as J,o as i,d as q,bJ
42
42
  `,Rt=n.div`
43
43
  position: absolute;
44
44
  right: ${i.sp4};
45
- `,Bt=n(ut)`
45
+ `,Wt=n(ut)`
46
46
  margin-right: ${i.sp3};
47
- width: ${e=>Z.paymentAccountIconSize.valuePx(e.windowSize)};
48
- height: ${e=>Z.paymentAccountIconSize.valuePx(e.windowSize)};
49
- min-width: ${e=>Z.paymentAccountIconSize.valuePx(e.windowSize)};
50
- min-height: ${e=>Z.paymentAccountIconSize.valuePx(e.windowSize)};
51
- `,Wt=n.div`
47
+ width: ${e=>Q.paymentAccountIconSize.valuePx(e.windowSize)};
48
+ height: ${e=>Q.paymentAccountIconSize.valuePx(e.windowSize)};
49
+ min-width: ${e=>Q.paymentAccountIconSize.valuePx(e.windowSize)};
50
+ min-height: ${e=>Q.paymentAccountIconSize.valuePx(e.windowSize)};
51
+ `,Dt=n.div`
52
52
  white-space: nowrap;
53
53
  overflow: hidden;
54
54
  width: 100%;
55
- `,Dt=n.div`
55
+ `,Bt=n.div`
56
56
  display: flex;
57
57
  gap: ${i.sp2};
58
58
  align-items: center;
@@ -73,7 +73,7 @@ import{u as ae,X as we,a as He,c2 as qe,j as t,aW as Je,M as J,o as i,d as q,bJ
73
73
  overflow: hidden;
74
74
  `,Ut=n.div`
75
75
  display: flex;
76
- `,{common:{settings:X,strings:{empty:Ht}}}=J.getLocalizedStrings(),qt=()=>null,Jt=({paymentAccount:e,bankAccountList:a,balanceFetchStatus:L,onRemoveConnection:O})=>{const s=ae(),d=e?.providerVerificationStatus,$=a.find(z=>z.accountId===e.zeniAccountId);return t.jsxs(Gt,{children:[t.jsxs(Yt,{children:[t.jsx(Qt,{children:`${X.otherAccount.title} ${X.otherAccount.subTitleSmall}`}),t.jsx(Fe,{moreIconType:"plain",options:[{label:X.otherAccount.remove,value:"remove"}],customStyleConfig:{valueContainer:()=>({height:i.sp3,".more-icon":{width:i.sp3,height:i.sp3,color:s.colors.primary}}),container:()=>({marginLeft:i.sp0,position:"relative"}),control:()=>({background:"transparent"}),menu:()=>({position:"absolute",right:0,width:"158px",border:`1px solid ${s.colors.grey3}`,boxShadow:`${i.sp0} 1px 2px ${i.sp0} ${V.boxShadowElevation}`}),option:()=>({color:s.colors.important,":hover":{color:s.colors.important,backgroundColor:s.colors.background}})},menuPlacement:"bottom",onOptionSelection:z=>{z==="remove"&&O(e.paymentAccountId)},valueToIcon:qt})]}),t.jsxs(Zt,{children:[t.jsxs(ln,{children:[t.jsx(cn,{children:t.jsx(dn,{children:e.institutionDetails.institutionName})}),t.jsxs(un,{children:[t.jsx(sn,{children:e.accountSubType?.name}),t.jsx(rn,{children:e.maskedAccountNumber}),t.jsx(tn,{children:d!=null?t.jsx(ee,{style:{width:"max-content",padding:0},tagTitle:d.name,textColor:te(d.code)}):null})]})]}),t.jsxs(nn,{children:[t.jsx(on,{className:"balanceLabel",children:ne("0,0.[00]",e.balances?.available)}),e.balances?.lastRefreshTime?t.jsx(an,{className:"balanceLabel",children:ie(e.balances?.lastRefreshTime)}):L?.fetchState==="In-Progress"?t.jsx(q,{size:"ExtraSmall",start:!0}):null]})]}),t.jsxs(Xt,{children:[t.jsx(Kt,{children:X.bankConnectionHeader.linkAccount}),t.jsx(en,{children:$?.accountName??Ht})]})]})},Gt=n.div`
76
+ `,{common:{settings:K,strings:{empty:Ht}}}=J.getLocalizedStrings(),qt=()=>null,Jt=({paymentAccount:e,bankAccountList:a,balanceFetchStatus:L,onRemoveConnection:O})=>{const s=ae(),d=e?.providerVerificationStatus,$=a.find(z=>z.accountId===e.zeniAccountId);return t.jsxs(Gt,{children:[t.jsxs(Yt,{children:[t.jsx(Zt,{children:`${K.otherAccount.title} ${K.otherAccount.subTitleSmall}`}),t.jsx(Fe,{moreIconType:"plain",options:[{label:K.otherAccount.remove,value:"remove"}],customStyleConfig:{valueContainer:()=>({height:i.sp3,".more-icon":{width:i.sp3,height:i.sp3,color:s.colors.primary}}),container:()=>({marginLeft:i.sp0,position:"relative"}),control:()=>({background:"transparent"}),menu:()=>({position:"absolute",right:0,width:"158px",border:`1px solid ${s.colors.grey3}`,boxShadow:`${i.sp0} 1px 2px ${i.sp0} ${V.boxShadowElevation}`}),option:()=>({color:s.colors.important,":hover":{color:s.colors.important,backgroundColor:s.colors.background}})},menuPlacement:"bottom",onOptionSelection:z=>{z==="remove"&&O(e.paymentAccountId)},valueToIcon:qt})]}),t.jsxs(Qt,{children:[t.jsxs(ln,{children:[t.jsx(cn,{children:t.jsx(dn,{children:e.institutionDetails.institutionName})}),t.jsxs(un,{children:[t.jsx(sn,{children:e.accountSubType?.name}),t.jsx(rn,{children:e.maskedAccountNumber}),t.jsx(tn,{children:d!=null?t.jsx(ee,{style:{width:"max-content",padding:0},tagTitle:d.name,textColor:te(d.code)}):null})]})]}),t.jsxs(nn,{children:[t.jsx(on,{className:"balanceLabel",children:ne("0,0.[00]",e.balances?.available)}),e.balances?.lastRefreshTime?t.jsx(an,{className:"balanceLabel",children:ie(e.balances?.lastRefreshTime)}):L?.fetchState==="In-Progress"?t.jsx(q,{size:"ExtraSmall",start:!0}):null]})]}),t.jsxs(Kt,{children:[t.jsx(Xt,{children:K.bankConnectionHeader.linkAccount}),t.jsx(en,{children:$?.accountName??Ht})]})]})},Gt=n.div`
77
77
  display: flex;
78
78
  flex-direction: column;
79
79
  padding: ${i.sp3};
@@ -85,19 +85,19 @@ import{u as ae,X as we,a as He,c2 as qe,j as t,aW as Je,M as J,o as i,d as q,bJ
85
85
  width: 100%;
86
86
  margin-bottom: ${i.sp3};
87
87
  justify-content: space-between;
88
- `,Qt=n(A)`
88
+ `,Zt=n(A)`
89
89
  color: ${e=>e.theme.colors.grey1};
90
90
  display: flex;
91
91
  align-items: center;
92
- `,Zt=n.div`
92
+ `,Qt=n.div`
93
93
  display: flex;
94
94
  align-items: center;
95
95
  justify-content: space-between;
96
96
  margin-bottom: ${i.sp3};
97
- `,Xt=n.div`
97
+ `,Kt=n.div`
98
98
  display: flex;
99
99
  align-items: center;
100
- `,Kt=n(v)`
100
+ `,Xt=n(v)`
101
101
  color: ${e=>e.theme.colors.grey1};
102
102
  margin-right: ${i.sp2};
103
103
  `,en=n(v)`
@@ -132,7 +132,7 @@ import{u as ae,X as we,a as He,c2 as qe,j as t,aW as Je,M as J,o as i,d as q,bJ
132
132
  color: ${e=>e.theme.colors.hero};
133
133
  display: flex;
134
134
  align-items: center;
135
- `,{common:{settings:ze,strings:{hyphen:pe}},commonSetUp:{setUp:ke}}=J.getLocalizedStrings(),g={containerPadding:new f(h[3],h[4]),containerRightPadding:new f(h[3],h[8]),iconContainerMaxWidthHeight:new f(h[6],h[7]),iconWidthHeight:new f(20,h[4]),iconPadding:new f(h[1],12),productTypeContainerMarginBottom:new f(h[3],h[0]),linkAccountContainerMarginTop:new f(h[3],h[0]),productTypeIconSize:new f(h[3],h[4])},pn="bankConnectionsSettingsPage",hn=({productType:e,windowSize:a})=>{switch(e){case"bill_pay":return t.jsx(In,{windowSize:a});case"reimbursement":return t.jsx(Ln,{windowSize:a});case"zeni_accounts":return t.jsx(On,{windowSize:a});case"zeni_treasury":return t.jsx(Rn,{windowSize:a});case"charge_cards":default:return t.jsx(Fn,{windowSize:a})}},mn=({analytics:e,allBankAccounts:a,setupView:L,connectedAccountProvider:O,onFetchLinkTokenClick:s,onUpdatePaymentAccountStatus:d,onEstablishConnectionClick:$,onEstablishConnectionSuccess:z})=>{const w=ae(),c=we(),{trigger:F,formState:{errors:M}}=et(),{plaidConnectionDetails:R,allFundingAccounts:l,primaryFundingAccount:o,productType:r}=L,x=R.link_account,C=R.update_account,[W,N]=b.useState(void 0),[le,Y]=b.useState(!1),ce=()=>{Y(!0)},k=W==="update_account"?C:x,[m,B]=b.useState(k.linkToken??null),[j,T]=b.useState(!1),E=x.fetchStatus.fetchState==="In-Progress"||x.updateStatus.fetchState==="In-Progress";let S,_,u,y=!1;o!=null&&(o.accType==="depositAccount"?S={code:"verified",name:"Verified"}:(S=o.providerVerificationStatus,_=o?.institutionDetails,u=S?.code,y=o?.isLoginRequired??!1));const fe=de(x.updateStatus.fetchState),se=de(C.updateStatus.fetchState),Re=de(C.fetchStatus.fetchState),Be=w.mode==="light"?new K(w.colors.brandColorJadeLight):new K(w.colors.brandColorJadeDark),We=b.useCallback((p,D)=>{e.trackConnectBankSuccess(r,"Settings");const ve=D.accounts.find(Ue=>Ue.id===o?.providerAccountId)??D.accounts[0];o?.id!=null&&W==="update_account"&&ve?.verification_status!=null&&!y?d(ve?.verification_status,o.id,"update_account",I(r),r):$(p,I(r),r),N(void 0),T(!1)},[e,r,o?.id,o?.providerAccountId,W,y,d,$]),De=b.useCallback((p,D)=>{p!=null&&(e.trackConnectBankFailure(r,p.error_code+" "+p.error_message,"Settings"),p.error_code==="TOO_MANY_VERIFICATION_ATTEMPTS"&&o?.id!=null&&d("verification_failed",o.id,"update_account",I(r),r),console.log("Plaid Connection Error",p,D)),N(void 0),T(!1)},[e,r,o?.id,d]),{open:re,ready:xe}=tt({token:m,onSuccess:We,onExit:De});b.useEffect(()=>{(fe==="In-Progress"&&x.updateStatus.fetchState==="Completed"||se==="In-Progress"&&C.updateStatus.fetchState==="Completed")&&u!=="verified"&&u!=="manually_verified"&&u!=="automatically_verified"&&u!=="database_matched"&&(s("link_account",I(r)),z(I(r),r))},[x.updateStatus.fetchState,z,s,o?.providerVerificationStatus?.code,o?.id,fe,se,C.updateStatus.fetchState,u,r]),b.useEffect(()=>{(Q.isVerifiedStatusCode(u??"")||u==="verification_failed")&&!j&&W!=null&&k.linkToken===m&&k.fetchStatus.fetchState==="Completed"&&xe&&T(!0)},[xe,m,k.fetchStatus.fetchState,k.linkToken,u,W,j]);const ye=me(pn,"primaryAccountSection"),Me=nt(M,ye);b.useEffect(()=>{k.fetchStatus.fetchState==="Completed"&&k.linkToken!=null&&k.linkToken!==m&&B(k.linkToken)},[k.fetchStatus.fetchState,k.linkToken,m]),b.useEffect(()=>{j&&re()},[j,re]),b.useEffect(()=>{!o?.zeniAccountId&&!Me&&F(ye)},[o?.id]),b.useEffect(()=>{(u==null||u==="verification_failed"||u==="verification_expired"||Q.isVerifiedStatusCode(u))&&(Q.zeniDate(new Date().toISOString()).isAfter(x.expiration)||x.linkToken==null)&&s("link_account",I(r))},[]);const Ee=()=>{e.trackConnectBankGetBalance(r,"Settings"),N("update_account"),s("update_account",I(r),o?.id)},Se=`${o?.accountSubType?.name!=null?o?.accountSubType?.name.substring(0,1).toUpperCase().concat(o?.accountSubType?.name.substring(1)):""} ${o?.maskedAccountNumber??""}`.trim(),be=_?.zeniInstitutionId.toLowerCase()==="chase",Ne=l.findIndex(p=>p.id===o?.id),Ve={element:t.jsx(Le,{width:g.iconWidthHeight.valuePx(c)}),color:Be};return t.jsxs(gn,{windowSize:c,children:[le===!0?ht.createPortal(t.jsx(mt,{connectedAccountProvider:O,action:{onBackClick:()=>Y(!1)}}),document.body):null,t.jsxs(wn,{windowSize:c,wrapperWidth:P[0].width,children:[t.jsx(xn,{windowSize:c,isDarkMode:w.mode==="dark",children:t.jsx(hn,{productType:r,windowSize:c})}),t.jsx(fn,{children:ze.productNameByType[r]})]}),t.jsx(yn,{windowSize:c,wrapperWidth:P[1].width,children:t.jsxs(kn,{windowSize:c,children:[o!=null&&c!=="small"?t.jsx(zn,{isDisabled:y,children:gt(Ve,c,w.mode==="dark",o,Ne,!1)}):null,t.jsxs(jn,{windowSize:c,className:"fundingAccount",children:[t.jsx(Oe,{style:{display:c==="small"?"block":"inherit",width:"-webkit-fill-available",color:w.colors.hero},customStyleConfig:{menu:()=>({width:c==="small"?"auto":510})},controlProperty:{controlHeight:h[4],fontWeight:$e.medium,highlightOnHover:!1,leftRightMargin:!1,fieldWidth:c==="small"?240:300},customPlaceholder:{color:w.colors.hero,weight:$e.medium},name:me(r,"primaryAccountSection"),placeholder:ke.selectAccountPlaceholder,capitalizeOptions:!0,appendSublabel:!1,showLogoInSingleValue:!1,isClearable:!1,maxMenuHeight:220,valueToLogo:(p,D)=>ot(l,p,D),valueToSubLabels:(p,D)=>it(l,p,D,!1),defaultValue:{selectedOption:o?.id,allOptions:l.map(p=>({label:p.label,value:p.id,isRecommended:p.accType==="depositAccount"}))},textAlignment:"left",showDownChevronIcon:!0,showTickIcon:!1,isOptionRemovable:!1,registerOptions:{required:!1},showCreateOption:!0,showEmptyState:!1,isDisabled:E?"disabled":void 0,showLoadingIcon:E,onClickCreateOption:()=>{e.trackConnectBank(r,"Settings"),N("link_account"),x.linkToken==null||Q.zeniDate(new Date().toISOString()).isAfter(x.expiration)?s("link_account",I(r)):m!==x.linkToken?B(x.linkToken):j?re():T(!0)}}),t.jsxs(Sn,{isDisabled:y,children:[Se?t.jsxs(t.Fragment,{children:[t.jsx(bn,{children:Se}),c!=="small"&&(u!=="verification_failed"&&o?.providerVerificationStatus?.code==="pending_manual_verification"||y||be)?t.jsx($n,{}):null]}):null,c==="small"&&S!=null?t.jsx(ee,{style:{width:"max-content",padding:i.sp0,marginLeft:i.sp2},tagTitle:S.name,textColor:te(S.code)}):null,u!=="verification_failed"&&o?.providerVerificationStatus?.code==="pending_manual_verification"||y||be?t.jsx(wt,{productType:r,isUpdateLinkClicked:W==="update_account",isLoginRequired:y,isPendingVerification:u!=="verification_failed"&&o?.providerVerificationStatus?.code==="pending_manual_verification",fetchAndUpdateStatues:{fetchStatus:C.fetchStatus,updateStatus:C.updateStatus,linkFetchStatus:x.fetchStatus,linkUpdateStatus:x.updateStatus,prevFetchState:Re,prevUpdateState:se},onUpdateLinkTokenClick:Ee,onChaseInfoClick:ce}):null]})]}),c==="small"?t.jsxs(Cn,{children:[o?.accountBalance?.available?t.jsx(je,{className:"balanceLabel",children:ne("0,0[.]00",o?.accountBalance?.available)}):t.jsx(he,{children:pe}),o?.accountBalance?.lastRefreshTime?t.jsx(Ae,{className:"balanceLabel",children:ie(o?.accountBalance?.lastRefreshTime)}):o?.balanceFetchStatus.fetchState==="In-Progress"?t.jsx(q,{size:"Small",start:!0}):null]}):null]})}),t.jsxs(Pn,{windowSize:c,isDisabled:y,wrapperWidth:P[2].width,onClick:p=>p.stopPropagation(),"data-testid":at("bank-account-section",r),className:"qboLinkAcc",children:[c==="small"?t.jsx(vn,{children:ze.bankConnectionHeader.linkAccount}):null,t.jsx(_n,{isDisabled:y?"disabled":void 0,name:me(r,"bankAccountSection"),placeholder:ke.zeniCashAccountPlaceholder,defaultValue:{selectedOption:o?.zeniAccountId??"",allOptions:a.map(p=>({label:p.accountName,value:p.accountId}))},controlProperty:{highlightOnHover:!0},isOptionRemovable:!1,textAlignment:"left",registerOptions:{required:!1},style:{width:c==="small"?"calc(100% - 135px)":"100%",marginLeft:c==="small"?i.sp0:`-${i.sp3}`}})]}),c!=="small"?t.jsx(Tn,{windowSize:c,wrapperWidth:P[3].width,children:S!=null?t.jsx(ee,{style:{width:"max-content",padding:0},tagTitle:S.name,textColor:te(S.code)}):t.jsx(he,{children:pe})}):null,c!=="small"?t.jsxs(An,{windowSize:c,wrapperWidth:P[4].width,children:[o?.accountBalance?.available?t.jsx(je,{className:"balanceLabel",children:ne("0,0[.]00",o?.accountBalance?.available)}):t.jsx(he,{children:pe}),o?.accountBalance?.lastRefreshTime?t.jsx(Ae,{className:"balanceLabel",children:ie(o?.accountBalance?.lastRefreshTime)}):o?.balanceFetchStatus.fetchState==="In-Progress"?t.jsx(q,{size:"Small",start:!0}):null]}):null]})},gn=n.div`
135
+ `,{common:{settings:ze,strings:{hyphen:pe}},commonSetUp:{setUp:ke}}=J.getLocalizedStrings(),g={containerPadding:new f(h[3],h[4]),containerRightPadding:new f(h[3],h[8]),iconContainerMaxWidthHeight:new f(h[6],h[7]),iconWidthHeight:new f(20,h[4]),iconPadding:new f(h[1],12),productTypeContainerMarginBottom:new f(h[3],h[0]),linkAccountContainerMarginTop:new f(h[3],h[0]),productTypeIconSize:new f(h[3],h[4])},pn="bankConnectionsSettingsPage",hn=({productType:e,windowSize:a})=>{switch(e){case"bill_pay":return t.jsx(In,{windowSize:a});case"reimbursement":return t.jsx(Ln,{windowSize:a});case"zeni_accounts":return t.jsx(On,{windowSize:a});case"zeni_treasury":return t.jsx(Rn,{windowSize:a});case"charge_cards":default:return t.jsx(Fn,{windowSize:a})}},mn=({analytics:e,allBankAccounts:a,setupView:L,connectedAccountProvider:O,onFetchLinkTokenClick:s,onUpdatePaymentAccountStatus:d,onEstablishConnectionClick:$,onEstablishConnectionSuccess:z})=>{const w=ae(),c=we(),{trigger:F,formState:{errors:M}}=et(),{plaidConnectionDetails:R,allFundingAccounts:l,primaryFundingAccount:o,productType:r}=L,x=R.link_account,C=R.update_account,[D,N]=b.useState(void 0),[le,Y]=b.useState(!1),ce=()=>{Y(!0)},k=D==="update_account"?C:x,[m,W]=b.useState(k.linkToken??null),[j,T]=b.useState(!1),E=x.fetchStatus.fetchState==="In-Progress"||x.updateStatus.fetchState==="In-Progress";let S,_,u,y=!1;o!=null&&(o.accType==="depositAccount"?S={code:"verified",name:"Verified"}:(S=o.providerVerificationStatus,_=o?.institutionDetails,u=S?.code,y=o?.isLoginRequired??!1));const fe=de(x.updateStatus.fetchState),se=de(C.updateStatus.fetchState),Re=de(C.fetchStatus.fetchState),We=w.mode==="light"?new X(w.colors.brandColorJadeLight):new X(w.colors.brandColorJadeDark),De=b.useCallback((p,B)=>{e.trackConnectBankSuccess(r,"Settings");const ve=B.accounts.find(Ue=>Ue.id===o?.providerAccountId)??B.accounts[0];o?.id!=null&&D==="update_account"&&ve?.verification_status!=null&&!y?d(ve?.verification_status,o.id,"update_account",I(r),r):$(p,I(r),r),N(void 0),T(!1)},[e,r,o?.id,o?.providerAccountId,D,y,d,$]),Be=b.useCallback((p,B)=>{p!=null&&(e.trackConnectBankFailure(r,p.error_code+" "+p.error_message,"Settings"),p.error_code==="TOO_MANY_VERIFICATION_ATTEMPTS"&&o?.id!=null&&d("verification_failed",o.id,"update_account",I(r),r),console.log("Plaid Connection Error",p,B)),N(void 0),T(!1)},[e,r,o?.id,d]),{open:re,ready:xe}=tt({token:m,onSuccess:De,onExit:Be});b.useEffect(()=>{(fe==="In-Progress"&&x.updateStatus.fetchState==="Completed"||se==="In-Progress"&&C.updateStatus.fetchState==="Completed")&&u!=="verified"&&u!=="manually_verified"&&u!=="automatically_verified"&&u!=="database_matched"&&(s("link_account",I(r)),z(I(r),r))},[x.updateStatus.fetchState,z,s,o?.providerVerificationStatus?.code,o?.id,fe,se,C.updateStatus.fetchState,u,r]),b.useEffect(()=>{(Z.isVerifiedStatusCode(u??"")||u==="verification_failed")&&!j&&D!=null&&k.linkToken===m&&k.fetchStatus.fetchState==="Completed"&&xe&&T(!0)},[xe,m,k.fetchStatus.fetchState,k.linkToken,u,D,j]);const ye=me(pn,"primaryAccountSection"),Me=nt(M,ye);b.useEffect(()=>{k.fetchStatus.fetchState==="Completed"&&k.linkToken!=null&&k.linkToken!==m&&W(k.linkToken)},[k.fetchStatus.fetchState,k.linkToken,m]),b.useEffect(()=>{j&&re()},[j,re]),b.useEffect(()=>{!o?.zeniAccountId&&!Me&&F(ye)},[o?.id]),b.useEffect(()=>{(u==null||u==="verification_failed"||u==="verification_expired"||Z.isVerifiedStatusCode(u))&&(Z.zeniDate(new Date().toISOString()).isAfter(x.expiration)||x.linkToken==null)&&s("link_account",I(r))},[]);const Ee=()=>{e.trackConnectBankGetBalance(r,"Settings"),N("update_account"),s("update_account",I(r),o?.id)},Se=`${o?.accountSubType?.name!=null?o?.accountSubType?.name.substring(0,1).toUpperCase().concat(o?.accountSubType?.name.substring(1)):""} ${o?.maskedAccountNumber??""}`.trim(),be=_?.zeniInstitutionId.toLowerCase()==="chase",Ne=l.findIndex(p=>p.id===o?.id),Ve={element:t.jsx(Le,{width:g.iconWidthHeight.valuePx(c)}),color:We};return t.jsxs(gn,{windowSize:c,children:[le===!0?ht.createPortal(t.jsx(mt,{connectedAccountProvider:O,action:{onBackClick:()=>Y(!1)}}),document.body):null,t.jsxs(wn,{windowSize:c,wrapperWidth:P[0].width,children:[t.jsx(xn,{windowSize:c,isDarkMode:w.mode==="dark",children:t.jsx(hn,{productType:r,windowSize:c})}),t.jsx(fn,{children:ze.productNameByType[r]})]}),t.jsx(yn,{windowSize:c,wrapperWidth:P[1].width,children:t.jsxs(kn,{windowSize:c,children:[o!=null&&c!=="small"?t.jsx(zn,{isDisabled:y,children:gt(Ve,c,w.mode==="dark",o,Ne,!1)}):null,t.jsxs(jn,{windowSize:c,className:"fundingAccount",children:[t.jsx(Oe,{style:{display:c==="small"?"block":"inherit",width:"-webkit-fill-available",color:w.colors.hero},customStyleConfig:{menu:()=>({width:c==="small"?"auto":510})},controlProperty:{controlHeight:h[4],fontWeight:$e.medium,highlightOnHover:!1,leftRightMargin:!1,fieldWidth:c==="small"?240:300},customPlaceholder:{color:w.colors.hero,weight:$e.medium},name:me(r,"primaryAccountSection"),placeholder:ke.selectAccountPlaceholder,capitalizeOptions:!0,appendSublabel:!1,showLogoInSingleValue:!1,isClearable:!1,maxMenuHeight:220,valueToLogo:(p,B)=>ot(l,p,B),valueToSubLabels:(p,B)=>it(l,p,B,!1),defaultValue:{selectedOption:o?.id,allOptions:l.map(p=>({label:p.label,value:p.id,isRecommended:p.accType==="depositAccount"}))},textAlignment:"left",showDownChevronIcon:!0,showTickIcon:!1,isOptionRemovable:!1,registerOptions:{required:!1},showCreateOption:!0,showEmptyState:!1,isDisabled:E?"disabled":void 0,showLoadingIcon:E,onClickCreateOption:()=>{e.trackConnectBank(r,"Settings"),N("link_account"),x.linkToken==null||Z.zeniDate(new Date().toISOString()).isAfter(x.expiration)?s("link_account",I(r)):m!==x.linkToken?W(x.linkToken):j?re():T(!0)}}),t.jsxs(Sn,{isDisabled:y,children:[Se?t.jsxs(t.Fragment,{children:[t.jsx(bn,{children:Se}),c!=="small"&&(u!=="verification_failed"&&o?.providerVerificationStatus?.code==="pending_manual_verification"||y||be)?t.jsx($n,{}):null]}):null,c==="small"&&S!=null?t.jsx(ee,{style:{width:"max-content",padding:i.sp0,marginLeft:i.sp2},tagTitle:S.name,textColor:te(S.code)}):null,u!=="verification_failed"&&o?.providerVerificationStatus?.code==="pending_manual_verification"||y||be?t.jsx(wt,{productType:r,isUpdateLinkClicked:D==="update_account",isLoginRequired:y,isPendingVerification:u!=="verification_failed"&&o?.providerVerificationStatus?.code==="pending_manual_verification",fetchAndUpdateStatues:{fetchStatus:C.fetchStatus,updateStatus:C.updateStatus,linkFetchStatus:x.fetchStatus,linkUpdateStatus:x.updateStatus,prevFetchState:Re,prevUpdateState:se},onUpdateLinkTokenClick:Ee,onChaseInfoClick:ce}):null]})]}),c==="small"?t.jsxs(Cn,{children:[o?.accountBalance?.available?t.jsx(je,{className:"balanceLabel",children:ne("0,0[.]00",o?.accountBalance?.available)}):t.jsx(he,{children:pe}),o?.accountBalance?.lastRefreshTime?t.jsx(Ae,{className:"balanceLabel",children:ie(o?.accountBalance?.lastRefreshTime)}):o?.balanceFetchStatus.fetchState==="In-Progress"?t.jsx(q,{size:"Small",start:!0}):null]}):null]})}),t.jsxs(Pn,{windowSize:c,isDisabled:y,wrapperWidth:P[2].width,onClick:p=>p.stopPropagation(),"data-testid":at("bank-account-section",r),className:"qboLinkAcc",children:[c==="small"?t.jsx(vn,{children:ze.bankConnectionHeader.linkAccount}):null,t.jsx(_n,{isDisabled:y?"disabled":void 0,name:me(r,"bankAccountSection"),placeholder:ke.zeniCashAccountPlaceholder,defaultValue:{selectedOption:o?.zeniAccountId??"",allOptions:a.map(p=>({label:p.accountName,value:p.accountId}))},controlProperty:{highlightOnHover:!0},isOptionRemovable:!1,textAlignment:"left",registerOptions:{required:!1},style:{width:c==="small"?"calc(100% - 135px)":"100%",marginLeft:c==="small"?i.sp0:`-${i.sp3}`}})]}),c!=="small"?t.jsx(Tn,{windowSize:c,wrapperWidth:P[3].width,children:S!=null?t.jsx(ee,{style:{width:"max-content",padding:0},tagTitle:S.name,textColor:te(S.code)}):t.jsx(he,{children:pe})}):null,c!=="small"?t.jsxs(An,{windowSize:c,wrapperWidth:P[4].width,children:[o?.accountBalance?.available?t.jsx(je,{className:"balanceLabel",children:ne("0,0[.]00",o?.accountBalance?.available)}):t.jsx(he,{children:pe}),o?.accountBalance?.lastRefreshTime?t.jsx(Ae,{className:"balanceLabel",children:ie(o?.accountBalance?.lastRefreshTime)}):o?.balanceFetchStatus.fetchState==="In-Progress"?t.jsx(q,{size:"Small",start:!0}):null]}):null]})},gn=n.div`
136
136
  display: flex;
137
137
  flex-direction: ${e=>e.windowSize==="small"?"column":"row"};
138
138
  align-items: ${e=>e.windowSize==="small"?"flex-start":"center"};
@@ -245,7 +245,7 @@ import{u as ae,X as we,a as He,c2 as qe,j as t,aW as Je,M as J,o as i,d as q,bJ
245
245
  `,Rn=n(st)`
246
246
  width: ${e=>g.productTypeIconSize.valuePx(e.windowSize)};
247
247
  height: ${e=>g.productTypeIconSize.valuePx(e.windowSize)};
248
- `,me=(e,a)=>`${e}.${a}`,I=e=>{switch(e){case"zeni_accounts":return"account_setup";case"bill_pay":return"bill_pay_setup";case"charge_cards":return"charge_card_setup";case"reimbursement":return"reimbursement_setup";case"zeni_treasury":return"treasury_setup"}},{settings:{bankConnectionListHeader:ge,title:Bn,infoText:Wn}}=J.getLocalizedStrings().common,oe={pageContentPadding:new f(h[4],h[8]),subtitleSectionWidth:new f(343,580,1200),subTitleBottomMargin:new f(h[0],h[5])},Dn={qboLinkAcc:new Ke("smallRegular","standardRegular")},Mn="bankConnectionsSettingsPage",U="bankAccountSection",H="primaryAccountSection",En="bill_pay",Nn="reimbursement",Vn="zeni_accounts",Un="charge_cards",Hn="zeni_treasury",Ce=e=>t.jsx(Gn,{children:P.map(a=>t.jsx(Yn,{actualDataValue:a.value,wrapperWidth:a.width,windowSize:e,children:t.jsx(Qn,{children:a.value})},a.value))}),bi=({analytics:e,bankSetupView:a,connectedAccountProvider:L,onBackClick:O,onUpdateAccountClick:s,onFetchLinkTokenClick:d,onUpdatePaymentAccountStatus:$,onUpdatePaymentAccountLoginStatus:z,onEstablishConnectionClick:w,onEstablishConnectionSuccess:c,onClickMenuIcon:F,onUpdatePrimaryFundingAccount:M,onRemoveConnection:R})=>{const l=ae(),o=we(),{allFundingAccounts:r,primaryConnection:x}=a,C=He({mode:"all",reValidateMode:"onChange",defaultValues:_e(a),values:_e(a)}),W=C.handleSubmit(m=>{}),N=async(m,B)=>{const j=m.split("."),T=j[0],E=j[1],S=x.find(_=>_.productType===T);if(T!=null&&E!=null){const _=B[T][E];if(E==="primaryAccountSection"){const u=r.find(y=>y.id===_.selectedOption)?.accType;_.selectedOption!=null&&u!=null&&M(_.selectedOption,I(T),u)}else if(E==="bankAccountSection"&&S!=null&&S.primaryFundingAccount!=null&&_.selectedOption!=null){const u=S.primaryFundingAccount?.id,y=S.primaryFundingAccount?.accType;u!=null&&y!=null&&s(_.selectedOption,u,T,I(T),y)}}};b.useEffect(()=>{const m=C.watch((B,{name:j})=>{j!=null&&B!=null&&qe(()=>N(j,B))});return()=>{m.unsubscribe()}});const le=a.fetchState==="In-Progress"||a.fetchState==="Not-Started",Y=a.fetchState==="Completed"&&a.allFundingAccounts.length===0,ce=o==="small"?Jt:kt,k=()=>le?t.jsx(Kn,{children:t.jsx(q,{size:"ExtraLarge",start:!0})}):Y?t.jsx(Ge,{message:"No bank connections added."}):t.jsxs(qn,{windowSize:o,children:[t.jsx(Pe,{children:ge.primary}),o!=="small"?Ce(o):null,t.jsx(Ye,{...C,children:t.jsx("form",{id:ai(Mn),onSubmit:W,children:t.jsx(ei,{windowSize:o,children:a.primaryConnection.map(m=>m!=null?t.jsx(Te,{windowSize:o,children:t.jsx(mn,{analytics:e,allBankAccounts:a.allBankAccounts,setupView:m,connectedAccountProvider:L,onFetchLinkTokenClick:d,onUpdatePaymentAccountStatus:$,onUpdatePaymentAccountLoginStatus:z,onEstablishConnectionClick:w,onEstablishConnectionSuccess:c})},m.productType):null)})})}),a.otherPaymentAccounts.length>0?t.jsxs(Zn,{children:[t.jsx(Pe,{children:ge.other}),t.jsx(ii,{children:t.jsx(Qe,{display:"flex",placement:"right",maxWidth:"340px",title:ge.otherToolTip,style:{padding:`12px ${i.sp3}`},children:t.jsx(oi,{})})})]}):null,o!=="small"&&a.otherPaymentAccounts.length>0?Ce(o):null,a.otherPaymentAccounts.map(m=>{const B=r.find(j=>j.id===m.paymentAccountId)?.balanceFetchStatus;return t.jsx(Te,{windowSize:o,children:t.jsx(ce,{paymentAccount:m,bankAccountList:a.allBankAccounts,balanceFetchStatus:B,onRemoveConnection:R})},m.paymentAccountId)})]});return t.jsxs(Jn,{children:[t.jsx(Je,{source:"BankConnectionsSettingsPage",title:Bn.bankConnections,backgroundColor:l.colors.grey4,style:{zIndex:3},onBackClick:O,showBackButton:!1,showMenuIcon:o==="medium-compact"||o==="small",onClickMenuIcon:F}),t.jsxs(Xn,{windowSize:o,children:[t.jsx(ti,{windowSize:o,children:t.jsx(ni,{windowSize:o,children:Wn.bankConnections})}),k()]})]})},qn=n.div`
248
+ `,me=(e,a)=>`${e}.${a}`,I=e=>{switch(e){case"zeni_accounts":return"account_setup";case"bill_pay":return"bill_pay_setup";case"charge_cards":return"charge_card_setup";case"reimbursement":return"reimbursement_setup";case"zeni_treasury":return"treasury_setup"}},{settings:{bankConnectionListHeader:ge,title:Wn,infoText:Dn}}=J.getLocalizedStrings().common,oe={pageContentPadding:new f(h[4],h[8]),subtitleSectionWidth:new f(343,580,1200),subTitleBottomMargin:new f(h[0],h[5])},Bn={qboLinkAcc:new Xe("smallRegular","standardRegular")},Mn="bankConnectionsSettingsPage",U="bankAccountSection",H="primaryAccountSection",En="bill_pay",Nn="reimbursement",Vn="zeni_accounts",Un="charge_cards",Hn="zeni_treasury",Ce=e=>t.jsx(Gn,{children:P.map(a=>t.jsx(Yn,{actualDataValue:a.value,wrapperWidth:a.width,windowSize:e,children:t.jsx(Zn,{children:a.value})},a.value))}),bi=({analytics:e,bankSetupView:a,connectedAccountProvider:L,onBackClick:O,onUpdateAccountClick:s,onFetchLinkTokenClick:d,onUpdatePaymentAccountStatus:$,onUpdatePaymentAccountLoginStatus:z,onEstablishConnectionClick:w,onEstablishConnectionSuccess:c,onClickMenuIcon:F,onUpdatePrimaryFundingAccount:M,onRemoveConnection:R})=>{const l=ae(),o=we(),{allFundingAccounts:r,primaryConnection:x}=a,C=He({mode:"all",reValidateMode:"onChange",defaultValues:_e(a),values:_e(a)}),D=C.handleSubmit(m=>{}),N=async(m,W)=>{const j=m.split("."),T=j[0],E=j[1],S=x.find(_=>_.productType===T);if(T!=null&&E!=null){const _=W[T][E];if(E==="primaryAccountSection"){const u=r.find(y=>y.id===_.selectedOption)?.accType;_.selectedOption!=null&&u!=null&&M(_.selectedOption,I(T),u)}else if(E==="bankAccountSection"&&S!=null&&S.primaryFundingAccount!=null&&_.selectedOption!=null){const u=S.primaryFundingAccount?.id,y=S.primaryFundingAccount?.accType;u!=null&&y!=null&&s(_.selectedOption,u,T,I(T),y)}}};b.useEffect(()=>{const m=C.watch((W,{name:j})=>{j!=null&&W!=null&&qe(()=>N(j,W))});return()=>{m.unsubscribe()}});const le=a.fetchState==="In-Progress"||a.fetchState==="Not-Started",Y=a.fetchState==="Completed"&&a.allFundingAccounts.length===0,ce=o==="small"?Jt:kt,k=()=>le?t.jsx(Xn,{children:t.jsx(q,{size:"ExtraLarge",start:!0})}):Y?t.jsx(Ge,{message:"No bank connections added."}):t.jsxs(qn,{windowSize:o,children:[t.jsx(Pe,{children:ge.primary}),o!=="small"?Ce(o):null,t.jsx(Ye,{...C,children:t.jsx("form",{id:ai(Mn),onSubmit:D,children:t.jsx(ei,{windowSize:o,children:a.primaryConnection.map(m=>m!=null?t.jsx(Te,{windowSize:o,children:t.jsx(mn,{analytics:e,allBankAccounts:a.allBankAccounts,setupView:m,connectedAccountProvider:L,onFetchLinkTokenClick:d,onUpdatePaymentAccountStatus:$,onUpdatePaymentAccountLoginStatus:z,onEstablishConnectionClick:w,onEstablishConnectionSuccess:c})},m.productType):null)})})}),a.otherPaymentAccounts.length>0?t.jsxs(Qn,{children:[t.jsx(Pe,{children:ge.other}),t.jsx(ii,{children:t.jsx(Ze,{display:"flex",placement:"right",maxWidth:"340px",title:ge.otherToolTip,style:{padding:`12px ${i.sp3}`},children:t.jsx(oi,{})})})]}):null,o!=="small"&&a.otherPaymentAccounts.length>0?Ce(o):null,a.otherPaymentAccounts.map(m=>{const W=r.find(j=>j.id===m.paymentAccountId)?.balanceFetchStatus;return t.jsx(Te,{windowSize:o,children:t.jsx(ce,{paymentAccount:m,bankAccountList:a.allBankAccounts,balanceFetchStatus:W,onRemoveConnection:R})},m.paymentAccountId)})]});return t.jsxs(Jn,{children:[t.jsx(Je,{source:"BankConnectionsSettingsPage",title:Wn.bankConnections,backgroundColor:l.colors.grey4,style:{zIndex:3},onBackClick:O,showBackButton:!1,showMenuIcon:o==="medium-compact"||o==="small",onClickMenuIcon:F}),t.jsxs(Kn,{windowSize:o,children:[t.jsx(ti,{windowSize:o,children:t.jsx(ni,{windowSize:o,children:Dn.bankConnections})}),k()]})]})},qn=n.div`
249
249
  display: flex;
250
250
  flex-direction: column;
251
251
  width: 100%;
@@ -285,10 +285,10 @@ import{u as ae,X as we,a as He,c2 as qe,j as t,aW as Je,M as J,o as i,d as q,bJ
285
285
  padding-left: ${i.sp0};
286
286
  box-sizing: border-box;
287
287
  overflow: hidden;
288
- `,Qn=n(v)`
288
+ `,Zn=n(v)`
289
289
  display: flex;
290
290
  gap: 5px;
291
- `,Zn=n.div`
291
+ `,Qn=n.div`
292
292
  display: flex;
293
293
  align-items: center;
294
294
  `,Te=n.div`
@@ -317,7 +317,7 @@ import{u as ae,X as we,a as He,c2 as qe,j as t,aW as Je,M as J,o as i,d as q,bJ
317
317
  .select-value-container
318
318
  .single-select-field__single-value {
319
319
  color: ${e=>e.theme.colors.hero};
320
- ${e=>`${Dn.qboLinkAcc.style(e.windowSize)}`};
320
+ ${e=>`${Bn.qboLinkAcc.style(e.windowSize)}`};
321
321
  }
322
322
  &:hover {
323
323
  border: ${e=>`1px solid ${e.theme.colors.primary}`};
@@ -331,14 +331,14 @@ import{u as ae,X as we,a as He,c2 as qe,j as t,aW as Je,M as J,o as i,d as q,bJ
331
331
  color: ${e=>e.theme.colors.primary};
332
332
  }
333
333
  }
334
- `,Xn=n.div`
334
+ `,Kn=n.div`
335
335
  display: flex;
336
336
  justify-content: flex-start;
337
337
  height: 100%;
338
338
  overflow-y: auto;
339
339
  flex-direction: column;
340
340
  align-items: center;
341
- `,Kn=n.div`
341
+ `,Xn=n.div`
342
342
  display: flex;
343
343
  width: 100%;
344
344
  height: calc(100vh - 110px);
@@ -349,11 +349,11 @@ import{u as ae,X as we,a as He,c2 as qe,j as t,aW as Je,M as J,o as i,d as q,bJ
349
349
  `,ei=n.div`
350
350
  display: flex;
351
351
  flex-direction: column;
352
- `,Pe=n(Xe)`
352
+ `,Pe=n(Ke)`
353
353
  color: ${e=>e.theme.colors.primary};
354
354
  margin-right: ${i.sp1};
355
355
  padding: ${i.sp3} ${i.sp0} ${i.sp3} ${i.sp2};
356
- `,ti=n(Ze)`
356
+ `,ti=n(Qe)`
357
357
  display: flex;
358
358
  justify-content: center;
359
359
  align-items: center;
@@ -1,5 +1,5 @@
1
- import{X as Nn,t as On,u as Fn,fI as En,fJ as Ln,fK as Wn,fL as _n,aV as Zn,a1 as Kn,M as Vn,C as u,j as t,l as L,cE as it,cF as Un,o as a,cG as Yn,cH as Gn,Y as b,cI as Hn,_ as Ae,cJ as qn,aW as lt,aI as ot,dp as rt,bM as st,bO as dt,bP as ct,fM as Jn,fN as Qn,fO as Xn,fP as ea,cO as j,cP as I,cQ as $,fQ as A,cN as ta,v as pt,g as ie,cR as Rt,cS as na,cT as aa,cU as ia,fR as la,fS as oa,a3 as ra,m as mt,bs as Te,fT as sa,fU as O,p as r,b as da,bo as ca,fV as pa,a2 as ma,fW as ua,fX as ut,cY as yt,Q as ya,ct as ha,bF as ba,al as xa,an as ga,k as fa,eW as zt,fY as wa,w as Mt,ab as Ta,aj as va,aN as Da,eG as ja,q as Ia}from"./index-C5RQ_I4f.js";import{b as p,n as i}from"./vendor-CnQcJ2Lu.js";import{_ as $a}from"./liveblocks-sSQ9JElv.js";import{o as Aa,t as ka}from"./LowBalancePopup-c-6SC1hh-B9wQAJ9M.js";import"./mui-C5LQ0bMa.js";import"./analytics-DThoELaW.js";import"./routing-Cpaypegg.js";import"./sentry-HDxG13yk.js";import"./redux-ByjIRbhZ.js";import"./crypto-BURQLTgV.js";const Sa=e=>p.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",...e},p.createElement("g",{id:"Layer_1"},p.createElement("path",{fill:"none",stroke:"#757d7e",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round",d:"M4.4,30.6l6-5.9c1,.6,2.1.9,3.3,1,1.1.1,2.3,0,3.4-.4,1.1-.4,2.1-.9,2.9-1.7.9-.8,1.5-1.7,2-2.7,0-.1,0-.2,0-.4,0-.1,0-.2-.1-.3,0-.1-.2-.2-.3-.2-.1,0-.2,0-.4,0h-4.6c-.8,0-1.6-.3-2.1-.9-.6-.6-.9-1.3-.9-2.1s.3-1.5.9-2.1c.6-.6,1.3-.9,2.1-.9h3.8c.1,0,.3,0,.4-.1s.2-.2.3-.3c0-.1,0-.3,0-.4,0-.1,0-.3-.1-.4-1.3-1.6-3.1-2.7-5.2-3.1-2.1-.4-4.2,0-5.9,1.2-1.8,1.1-3,2.8-3.5,4.8s-.2,4.1.8,5.9l-6.1,5.7,3.3,3.3Z"})),p.createElement("g",{id:"Layer_2"},p.createElement("g",null,p.createElement("path",{fill:"#c27419",stroke:"#f3f7f7",strokeWidth:1.2,strokeLinecap:"round",strokeLinejoin:"round",d:"M31,8c0,1.9-.7,3.8-2.1,5.1-1.3,1.4-3.2,2.2-5.1,2.2-.9,0-1.9-.2-2.7-.5-.9-.3-1.7-.9-2.3-1.5-.7-.7-1.2-1.4-1.6-2.3-.4-.9-.6-1.8-.6-2.7,0-1.9.7-3.8,2.1-5.1,1.3-1.4,3.2-2.2,5.1-2.2.9,0,1.9.2,2.7.5.9.3,1.7.9,2.3,1.5.7.7,1.2,1.4,1.6,2.3.4.9.6,1.8.6,2.7Z"}),p.createElement("path",{fill:"none",stroke:"#f3f7f7",strokeWidth:1.2,strokeLinecap:"round",strokeLinejoin:"round",d:"M23.8,9.4v-4.6"}),p.createElement("path",{fill:"none",stroke:"#f3f7f7",strokeWidth:1.2,strokeLinecap:"round",strokeLinejoin:"round",d:"M23.8,11.4s0,0,0,0c0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.1,0,0,0,0,.1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0-.1,0,0,0,0-.1,0h0"})))),Ca={formTitle:new ya("h6Medium","h5Medium")},m={containerPaddingLeft:new u(r[3],r[6],r[6]),containerPaddingRight:new u(r[3],r[6],r[8]),marginBottom:new u(r[3],r[3]),labelWidth:new u(120,160,160),formTitlePaddingLeftRight:new u(30,0),marginTop:new u(r[1],0),rightIconsGap:new u(r[4],r[5]),closeContainerMarginTop:new u(r[1],0),formTitleMarginTopBottom:new u(0,0),footerButtonWidth:new u(120,120,120,165,165),right:new u(r[3],r[0]),actionsContainerRight:new u(r[0],r[3],r[3],r[6],r[6]),otherActionsIconContainerMarginLeft:new u(r[5],r[4],r[4],r[5]),otherActionsContainerBottom:new u(58,44),iconContainerMarginTop:new u(2,r[1]),recurringSchedulePaddingLeft:new u(r[2],0),paddingRight:new u(r[2],r[3]),labelMarginRight:new u(r[0],r[3]),textPadding:new u(r[0],r[3]),additionalTextMarginTop:new u(-4,0),refundPopupWidth:new u(300,420,420),drawerSectionPaddingLeftRight:new u(r[4],r[5]),infoLabelPaddingRight:new u(r[3],r[3]),infoLabelMarginTop:new u(r[1],r[0]),navBarHeight:new u(0,0,r[8]),navBarContainerWidth:new u(100,58)},{dateFormat:Pa,common:{noText:C,strings:{empty:d},currency:ht,via:Ba,more:Ra,edit:za},spendManagement:{billPay:{billDetails:n,billsByTabs:ke,bulkActions:bt,vendorCreation:xt,insufficientFunds:Nt}},collaboration:{threads:{placeholder:gt,tooltip:ft,title:{comments:Ma}}}}=Vn.getLocalizedStrings(),ve=Pa.visual.MMMDCommaYYYYformat,ji=({billDetails:e,currentTenant:g,showApproveRejectBtns:x,isShowDeletedBillsEnabled:Z,signedInUser:le,isAdmin:Ot,isRealTimeApprovalEnabled:Ft,isInternationalPaymentShaVsOurEnabled:Et,hasZeniAssistAccess:Lt,analytics:z,showMarkAsPaidButtonToCreator:K,showMarkAsPaidButtonToApprover:Wt,isBillPayCommentingEnabled:Se,isZeniUser:_t,showBackButton:Ce=!0,isDetectInsufficientFundsEnabled:Zt,redirectToEditableBillScreen:Kt,redirectToBillsScreen:H,discardBillDetailsFromLocalStore:Pe,deleteBill:Vt,cancelAndDeleteBill:Be,approveOrRejectBill:Re,onAddNewRule:Ut,onAttachmentClick:ze,saveBillDetails:Yt,discardOutsideZeniPaymentData:Gt,onBackClick:Me,updateEditRealTimeApproverClicked:Ht,onSaveRealTimeApprovals:qt,onRetryPaymentClick:Jt,onRefundPaymentClick:Qt})=>{const l=Nn(),o=On(),Ne=Fn(),[Xt,V]=p.useState(!1),[Oe,oe]=p.useState(!1),[re,se]=p.useState(!1),[Fe,de]=p.useState(!1),[en,ce]=p.useState(!1),[Ee,q]=p.useState(!1),y=e.transactionDetails?.id,tn=_t?En:Ln,{requestToOpenThread:pe,setRequestToOpenThread:Le,setOpenThread:J}=p.useContext(tn),[nn,U]=p.useState(!1),w={application:"dashboard",companyId:o.currentTenant?.companyId,tab:"bill",entityId:y,isGlobalComment:!1},{threads:Y,isLoading:P}=Wn(w,"both",!1),f=Se&&y!=null,We=p.useMemo(()=>y==null?[]:Y.filter(c=>c.resolved===!1&&!c.id.includes(_n)),[Y,y]).length,T=`dashboard_${o.currentTenant?.companyId}`,an=p.useCallback((c,h)=>{J(h),U(!1)},[J,U]);p.useEffect(()=>{pe?.threadId!=null&&Y.length>0&&!P&&(J(pe.threadId),Le(null))},[pe,Y,P,J,Le]),Zn({componentName:"bills.details"});const[N,Q]=p.useState({title:"",description:"",primaryButtonText:"",secondaryButtonText:""}),[_e,Ze]=p.useState("approved"),[ln,Ke]=p.useState(!1),[on,Ve]=p.useState(!1),[Ue,Ye]=p.useState(!1),Ge=()=>Ke(!1),rn=()=>Ke(!0),He=Kn(e.zeniAssist?.refundStatus.fetchState),X=p.useCallback(()=>{H()},[H]);p.useEffect(()=>{(e.deleteStatus.fetchState==="Completed"||e.approvalUpdateStatus.fetchState==="Completed"||e.cancelAndDeleteStatus.fetchState==="Completed"||e.billSaveStatus==="Completed")&&(Pe(),H())},[e,H,Pe]),p.useEffect(()=>{He==="In-Progress"&&(e.zeniAssist?.refundStatus.fetchState==="Completed"||e.zeniAssist?.refundStatus.fetchState==="Error")&&(se(!1),X())},[He,e.zeniAssist?.refundStatus,X]);const k=e.transactionDetails?.billPayInfo.stage,ee=e.transactionDetails?.billPayInfo.billStatus,G=e.transactionDetails?.billPayInfo.billPaymentStatus,sn=e.transactionDetails?.billPayInfo.billPaymentRefundStatus,me=k?.code==="paid",v=me?k:ee?.code=="approved"&&G?.code?G:ee,S=Na(v,e.transactionDetails),F=e.transactionDetails?.billPayInfo.isRefundInitiated===!0?sn:G?.code!=null&&(ee?.code=="approved"||G.code==="mark_as_paid")?G:ee,ue=e.transactionDetails?.vendor?.name,M=e.isRecurring,qe=()=>{e.transactionDetails?.id!=null&&Kt(e.transactionDetails?.id??"")},dn=()=>{Q({title:M?n.recurringBill.deleteRecurringTitle:n.deleteBillTitle,description:M?n.recurringBill.deleteRecurringAlertText:n.deleteAlertDescription,primaryButtonText:n.delete,secondaryButtonText:n.cancel}),V(!0)},cn=()=>{Q({title:n.cancelBillTitle,description:n.cancelAlertDescription,primaryButtonText:n.yes,secondaryButtonText:n.no}),V(!0)},pn=()=>{Q({title:M?n.recurringBill.cancelAndDeleteRecurringTitle:n.cancelAndDeleteBillTitle,description:M?n.recurringBill.cancelAndDeleteRecurringAlertText:n.cancelAndDeleteAlertDescription,primaryButtonText:n.yes,secondaryButtonText:n.no}),V(!0)},mn=()=>{z.trackRefundClick(v?.code??"",k?.code??"",F?.description??"",M?["Recurring"]:["One-Time"],e.transactionDetails?.documentId??""),Q({title:n.zeniAssist.refundTitle,description:n.zeniAssist.refundDescription,primaryButtonText:n.zeniAssist.proceed,secondaryButtonText:n.cancel}),se(!0)},un={onOkClick:()=>{V(!1),N.primaryButtonText===n.delete?Vt?.(e.isRecurring):N.title===n.cancelBillTitle?Be?.(e.isRecurring):N.title===n.cancelAndDeleteBillTitle||N.title===n.recurringBill.cancelAndDeleteRecurringTitle?Be?.(e.isRecurring,!0):N.primaryButtonText===n.zeniAssist.proceed&&(z.trackRefundConfirmClick(v?.code??"",k?.code??"",F?.description??"",M?["Recurring"]:["One-Time"],e.transactionDetails?.documentId??""),Qt())},onCancelClick:()=>{V(!1),se(!1)}},yn={onOkClick:c=>{ce(!1),Re({billId:e.transactionDetails?.id??"",type:"rejected",description:c})},onCancelClick:()=>{ce(!1)}},hn=()=>{const[c]=Ta("ZeniAssist");return c!=null?t.jsx(va,{"data-testid":b("bill-details-zeni-assist-icon",y),onClick:()=>{de(!Fe),z.trackZeniAssistClick(v?.code??"",k?.code??"",F?.description??"",M?["Recurring"]:["One-Time"],e.transactionDetails?.documentId??"")},style:{width:`${a.sp5}`,height:`${a.sp5}`,marginBottom:`${a.sp2}`},animationData:c,loop:!0,play:!0,rendererSettings:{preserveAspectRatio:"xMidYMid slice"}}):null},te={invoiceNumber:e.transactionDetails?.documentId??"",invoiceDate:e.transactionDetails?.date,billDueDate:e.transactionDetails?.dueDate,memo:e.transactionDetails?.memo,currencyCode:e.vendorCurrency??ht.currencyCode},ye=e.transactionDetails?.lines?.map((c,h)=>{const B=c;return{lineIndex:h,lineId:B.id,account:B.account,class:B.class,amount:B.amount.amount,billable:B.billable,customer:B.customer,lineDescription:B.lineDescription,recipientAmount:B.recipientAmount?.amount}})??[],bn=e.transactionDetails?.recipientTotalAmount.amount??0,he=e.transactionDetails?.recipientTotalAmount,s={paymentType:e.paymentMethodType,paymentDate:e.transactionDetails?.billPayInfo.paymentDate,internationalTransferFeeBearerPaymentMethod:e.transactionDetails?.billPayInfo.internationalTransferFeeBearerPaymentMethod,paymentToBankAccount:e.bankAccount,paymentToPI:e.paymentInstrument},D=m.labelWidth.value(l),xn=c=>c==="billable"||c==="has_been_billed"?n.yes:n.no,gn=s.paymentToBankAccount?.bankAccountNumber?s.paymentToBankAccount?.bankAccountNumber?.slice(s.paymentToBankAccount?.bankAccountNumber?.length-4):s.paymentType?.method?.includes("international")&&s.paymentToBankAccount?.bankAccountIban?s.paymentToBankAccount?.bankAccountIban?.slice(s.paymentToBankAccount?.bankAccountIban.length-4):"",fn=s.paymentToBankAccount?.bankAccountName!=null&&s.paymentToBankAccount?.bankAccountName!=""?s.paymentToBankAccount?.bankAccountName:`${e.transactionDetails?.vendor?.name} - ${s.paymentToBankAccount?.bankName} XXXX${gn}`,wn=e.transactionDetails?.billPayInfo?.isCollectToAccountInfoFromVendorContact?t.jsxs(t.Fragment,{children:[`${n.magicLink.collectFrom} ${e.transactionDetails?.billPayInfo?.toAccountVendorEmail}`,t.jsx(ci,{windowSize:l,children:t.jsx(di,{})})]}):void 0,Je=e.transactionDetails?.date!=null&&e.transactionDetails.bookCloseDate!=null&&e.transactionDetails.date.isBefore(e.transactionDetails.bookCloseDate),Tn=()=>`${xt.achDetails.bankRoutingNumber} ${s?.paymentToBankAccount?.bankRoutingNumberAch}, ${s?.paymentToBankAccount?.bankName}
2
- ${xt.achDetails.bankAccountNumber} ${s?.paymentToBankAccount?.bankAccountNumber}`,ne=e.transactionDetails?.billPayInfo!=null?L.getActualPaymentDate(e.transactionDetails?.billPayInfo):void 0,vn=ne!=null&&e.paymentMethodType?.maxPeriod?.value!=null?L.zeniDate(L.getNextNthWorkingDay(ne?.toDate(),[0,6],e.paymentMethodType?.maxPeriod.value).toDateString()):void 0,Qe=e.transactionDetails?.billPayInfo.expectedDepositDate??vn,Xe=it(s?.paymentType?.method??"").replace("Same Day",""),Dn=(s?.paymentToBankAccount!=null||s?.paymentToPI)!=null?n.addedByZeni:e.transactionDetails?.billPayInfo.isCollectToAccountInfoFromVendorContact?t.jsx(Un,{paymentTypeLabel:Xe,onClick:rn,style:{marginTop:`${l==="small"?a.sp2:a.sp0}`}}):void 0,jn=()=>s?.paymentToBankAccount==null&&s?.paymentToPI==null&&s?.paymentType?.method!=null&&e.transactionDetails?.billPayInfo.isCollectToAccountInfoFromVendorContact&&e.transactionDetails?.billPayInfo.paymentDate!=null?t.jsx(wa,{paymentType:s?.paymentType?.method,paymentDate:e.transactionDetails?.billPayInfo.paymentDate}):null,be=!(v?.code==="processing"||e.transactionDetails?.billPayInfo.isRefundInitiated===!0||e.transactionDetails?.billPayInfo.isRefundComplete===!0),xe=e.zeniAssist?.isEligibleForRetryIBT===!0||e.zeniAssist?.isEligibleForRetryOBP===!0,ge=e.zeniAssist?.isEligibleForRefund===!0,In=e?.transactionDetails?.billPayInfo.billPaymentMethodType.code==="wire"&&e?.transactionDetails?.billPayInfo.billPaymentMethodType.subCode==="international",$n=Lt&&e.transactionDetails?.billPayInfo.billPaymentStatus.code!=null&&["failed","cancelled","returned"].includes(e.transactionDetails.billPayInfo.billPaymentStatus.code)&&(xe||ge)&&In===!1,fe=xe||ge,An=e.transactionDetails?.billPayInfo.isRefundInitiated===!0&&e.transactionDetails?.billPayInfo.isRefundComplete===!1,we=v?.code,kn=!An&&(!Je||v?.code==="processing"&&!M),Sn=!Je,et=["small","medium-compact","medium-regular"].includes(l),ae=L.isBulkProcessing(e.transactionDetails?.bulkProcessingDetail?.type),E=L.isPaymentMethodOutsideZeni(e.paymentMethodType?.method),Cn=c=>{z.trackBillPayMarkAsPaidSubmit(c.paymentMode??"other",k?.code??"",v?.code??""),Yt(!0,Ue,c)},tt=()=>{Ve(!0),z.trackBillPayMarkAsPaid(k?.code??"",v?.code??"")},Pn=()=>{Ye(!0),tt()},Bn=()=>{Gt(),Ve(!1),Ue&&Ye(!1)},Rn=p.useMemo(()=>({companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,entityType:"bill.details",entityId:y??d,isGlobalComment:!1,application:"dashboard",tab:"bill",url:window.location.href}),[o.currentTenant,y]),W=Zt&&e.transactionDetails?.totalAmountWithFeesInUSD!=null&&k?.code!=="paid"&&v?.code!=="failed"&&v?.code!=="processing"&&v?.code!=="cancelled"&&v?.code!=="returned"&&v?.code!=="rejected"?Yn(e.transactionDetails?.totalAmountWithFeesInUSD,e.withdrawFrom,s.paymentDate):void 0,nt=()=>{Ze("approved"),Ee===!0&&q(!1),W!=null&&z.trackLowBalanceAccountApprove(k?.code??"",e.transactionDetails?.billPayInfo.billPaymentStatus.code??"",e.isRecurring?["Recurring"]:["One-Time"],e.transactionDetails?.documentId??"",yt(o.loggedInUser),e.withdrawFrom?.accType==="depositAccount"?"ZA":"External Account"),Re({billId:e.transactionDetails?.id??"",type:"approved"})},zn=()=>{Ze("rejected"),W!=null&&z.trackLowBalanceAccountReject(k?.code??"",e.transactionDetails?.billPayInfo.billPaymentStatus.code??"",e.isRecurring?["Recurring"]:["One-Time"],e.transactionDetails?.documentId??"",yt(o.loggedInUser),e.withdrawFrom?.accType==="depositAccount"?"ZA":"External Account"),ce(!0)},at=p.useRef(null);return t.jsxs(qa,{windowSize:l,ref:at,children:[t.jsx(Gn,{anchor:"right",open:ln,onClose:Ge,transitionDuration:250,"data-testid":b("vendor-email-preview-drawer"),children:t.jsx(Hn,{companyName:qn(g.company?.companyInfo),vendor:e.transactionDetails?.vendor?.name,paymentDate:s.paymentDate?.format(ve)??"",paymentType:Xe,amount:Ae("0,0.[00]",he),isInvoiceAttached:!!e.transactionDetails?.attachments?.length,onClose:Ge})}),t.jsxs(ei,{windowSize:l,children:[t.jsx(ui,{windowSize:l,children:l==="small"?t.jsx(lt,{"data-testid":b("bill-detail-nav-bar-mobile"),title:t.jsxs(t.Fragment,{children:[ue,e.isRecurring?t.jsx($e,{width:a.sp4,height:a.sp4}):null]}),backgroundColor:Ne.colors.grey4,rightSideComponent:t.jsxs(It,{windowSize:l,children:[f?t.jsxs(Pt,{isDisabled:P,"data-testid":b("bill-comment-button"),onClick:P?()=>null:c=>{c.preventDefault(),c.stopPropagation(),U(!0),z.trackCommentActivity("bill","clicked",o.currentTenant?.companyName??"",o.controllersList.controllers.map(h=>rt(h)),void 0,void 0,"page icon")},children:[t.jsx(ot,{count:P?void 0:We,isLoading:P,style:{left:"12px"}}),t.jsx(Bt,{})]}):null,t.jsx($t,{onClick:()=>X(),"data-testid":b("bill-detail-nav-bar-small-close-button"),children:t.jsx(jt,{})})]}),leftSideComponent:t.jsx(Dt,{windowSize:l,onClick:Me,"data-testid":b("bill-detail-nav-bar-small-back-button"),style:{visibility:`${Ce?"visible":"hidden"}`},children:t.jsx(vt,{})}),source:"BillDetailPage"}):t.jsx(lt,{"data-testid":b("bill-detail-nav-bar"),title:t.jsxs(t.Fragment,{children:[ue,e.isRecurring?t.jsx($e,{width:a.sp4,height:a.sp4}):null]}),rightSideComponent:t.jsxs(It,{windowSize:l,children:[f?t.jsxs(Pt,{isDisabled:P,"data-testid":b("bill-comment-button"),onClick:P?()=>null:c=>{c.preventDefault(),c.stopPropagation(),U(!0),z.trackCommentActivity("bill","clicked",o.currentTenant?.companyName??"",o.controllersList.controllers.map(h=>rt(h)),void 0,void 0,"page icon")},children:[t.jsx(ot,{count:P?void 0:We,isLoading:P,style:{left:"12px"}}),t.jsx(Bt,{})]}):null,t.jsx($t,{onClick:()=>X(),"data-testid":b("bill-detail-nav-bar-close-button"),children:t.jsx(jt,{})})]}),leftSideComponent:t.jsx(Dt,{windowSize:l,onClick:Me,"data-testid":b("bill-detail-nav-bar-back-button"),style:{visibility:`${Ce?"visible":"hidden"}`},children:t.jsx(vt,{})}),enableTitleOnScroll:!0,scrollableContent:at,source:"BillDetailPage"})}),t.jsxs(ti,{windowSize:l,children:[Ee?t.jsx(Aa,{withdrawFrom:e.withdrawFrom,paymentDate:e?.transactionDetails?.billPayInfo.paymentDate,onOkClick:nt,onCancelClick:()=>{q(!1),qe()},onClickAway:()=>{q(!1)}}):null,on?t.jsx(ka,{onCancel:Bn,onProceedForMarkAsPaid:Cn,saveDetailsFetchState:e.billSaveStatus,paymentData:e.outsideZeniPaymentInfo}):null,Xt||re?t.jsx(st,{titleComponent:t.jsx(ct,{children:N.title}),descriptionComponent:t.jsx(dt,{children:N.description}),primaryButtonText:N.primaryButtonText,proceedButtonVariant:re?"primary":"danger",secondaryButtonText:N.secondaryButtonText,action:un,isEditPopup:!0,isLoading:e.zeniAssist?.refundStatus.fetchState==="In-Progress",children:re?Oa(l,e):null}):null,en?t.jsx(st,{titleComponent:t.jsx(ct,{children:n.rejectBillTitlePrefix+" "+(e.transactionDetails?.vendor?.name!=null?e.transactionDetails.vendor.name:"")}),descriptionComponent:t.jsx(dt,{children:n.rejectBillDescription}),primaryButtonText:n.send,secondaryButtonText:n.cancel,action:yn,isEditPopup:!0,isNotesIncluded:!0,notesPlaceholder:n.rejectBillReasonPlaceholder}):null,l!=="small"||S?t.jsxs(ai,{windowSize:l,children:[l!=="small"?t.jsxs(ii,{windowSize:l,children:[ue,e.isRecurring?t.jsx($e,{height:a.sp5,width:a.sp5}):null]}):null,Z&&S!=null&&S.code==="deleted"?t.jsx(At,{color:S.color,bgColor:S.bgColor,borderColor:S.borderColor,children:S.value}):S?.value===ke.tabsById.overdue?t.jsx(At,{color:S.color,bgColor:S.bgColor,borderColor:S.borderColor,children:S.value}):null]}):null,F!=null&&F.code?l==="small"?t.jsx(Jn,{progressSectionObj:F,createDate:e.transactionDetails?.createTime,paymentDate:Qe,scheduleDate:ne,approvedDate:e.latestApprovedDate,isFrozen:e.transactionDetails?.isDeleted}):t.jsx(Qn,{progressSectionObj:F,createDate:e.transactionDetails?.createTime,paymentDate:Qe,scheduleDate:ne,approvedDate:e.latestApprovedDate,isFrozen:e.transactionDetails?.isDeleted}):null,La(ae,e,W),t.jsx(Xn,{sectionId:ea,currentVendorOption:{defaultOptions:[]},billId:y,isBillPayCommentingEnabled:Se,isBillPaid:me,disableVendorActions:!0,vendor:e.transactionDetails?.vendor,prevBills:e.previousBills,onAttachmentClick:ze,isVendorRecommendationEnabled:!1,showVendorGptRecommendationText:!1}),s.paymentType?.method?.includes("ach"),t.jsxs(je,{children:[t.jsx(Ie,{children:n.whatForTitle}),t.jsxs(De,{children:[t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:"invoiceNumber"}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("invoiceNumber")}`},children:t.jsx(A,{label:{label:n.invoiceNumber,width:D},text:te.invoiceNumber??C,style:{width:"auto"}})}),t.jsx(R,{}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:"invoiceDate"}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("invoiceDate")}`},children:t.jsx(A,{label:{label:n.invoiceDate,width:D},text:te.invoiceDate?.format(ve)??C,style:{width:"auto"}})}),t.jsx(R,{}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:"billDueDate"}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("billDueDate")}`},children:t.jsx(A,{label:{label:n.billDueDate,width:D},text:te.billDueDate?.format(ve)??C,style:{width:"auto"}})}),t.jsx(R,{}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:"memo"}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("memo")}`},children:t.jsx(A,{label:{label:n.memo,width:D},text:te.memo??C,style:{width:"auto"}})})]})]}),t.jsxs(je,{children:[t.jsx(ni,{windowSize:l,children:t.jsx(Ie,{children:n.lineItemsTitle})}),ye.length>0?ye.map((c,h)=>{const B=e?.transactionDetails?.lines?.find(Mn=>Mn.id===c.lineId)?.recipientAmount;return t.jsxs(Ja,{children:[ye.length>1?t.jsx(Qa,{windowSize:l,children:t.jsx(Xa,{windowSize:l,children:`${n.line} # ${h+1}`})}):null,t.jsxs(De,{children:[t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:`${h}.recipientAmount`}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("recipientAmount",h)}`},children:t.jsx(A,{label:{label:n.amount,width:D},text:B!=null?Ae("0,0[.]00",B):C,style:{width:"auto"}})}),t.jsx(R,{}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:`${h}.lineDescription`}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("lineDescription",h)}`},children:t.jsx(A,{label:{label:n.description,width:D},text:c.lineDescription??C,style:{width:"auto"}})}),t.jsx(R,{}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:`${h}.account`}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("account",h)}`},children:t.jsx(A,{label:{label:n.category,width:D},text:c.account?.accountName??C,style:{width:"auto"}})}),t.jsx(R,{}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:`${h}.class`}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("class",h)}`},children:t.jsx(A,{label:{label:n.class,width:D},text:c.class?.className??C,style:{width:"auto"}})}),t.jsx(R,{}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:`${h}.billable`}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("billable",h)}`},children:t.jsx(A,{label:{label:n.billable,width:D},text:c.billable!=null?xn(c.billable):C,style:{width:"auto"}})}),t.jsx(R,{}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:`${h}.customer`}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("customer",h)}`},children:t.jsx(A,{label:{label:n.customer,width:D},text:c.customer?.name??C,style:{width:"auto"}})})]})]},h)}):null]}),t.jsxs(li,{windowSize:l,children:[t.jsx(oi,{children:n.total}),t.jsx(ri,{children:he!=null?t.jsx(ta,{amount:he,integerStyles:pt.h6Medium.cssObject,decimalStyles:pt.standardMedium.cssObject}):C})]}),t.jsxs(je,{children:[t.jsx(Ie,{children:n.paymentDetailsTitle}),t.jsxs(De,{children:[E?null:t.jsxs(t.Fragment,{children:[t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:"withdrawFrom"}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("withdrawFrom")}`},children:t.jsx(A,{label:{label:n.withdrawFrom,width:D},text:e.withdrawFrom!=null?Rt(e.withdrawFrom,l):d,style:{width:"auto"},additionalInfoLabelStyles:{textAlign:"right",paddingRight:m.infoLabelPaddingRight.valuePx(l),marginTop:m.infoLabelMarginTop.valuePx(l),color:ie.brandColorGoldDark},additionalInfoLabel:W!=null&&k?.code==="pending_approval"?Nt.addMoney:W})}),t.jsx(R,{})]}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:"paymentType"}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("paymentType")}`},children:t.jsx(A,{additionalInfoLabel:s.paymentType?.method!=null&&s.paymentType.method.includes(L.NEW_INTERNATIONAL_METHOD_SUBTEXT)&&Et&&s.internationalTransferFeeBearerPaymentMethod!=null?t.jsx(_a,{children:na(s.internationalTransferFeeBearerPaymentMethod)}):void 0,label:{label:n.paymentMethod,width:D},text:E&&e.outsideZeniPaymentInfo!=null?Ea(e.outsideZeniPaymentInfo):it(s.paymentType?.method??""),style:{width:"auto"}})}),E?null:t.jsxs(t.Fragment,{children:[t.jsx(R,{}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:"paymentTo"}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("paymentTo")}`},children:t.jsxs(t.Fragment,{children:[t.jsx(A,{label:{label:n.paymentTo,width:D},text:s.paymentToBankAccount!=null?fn:s.paymentToPI!=null?s.paymentToPI.displayText:wn,style:{width:"auto"},showEyeIcon:s.paymentToBankAccount!=null&&!!s.paymentType?.method?.includes("ach"),showAdditionalInfoLabel:!!e.transactionDetails?.billPayInfo.isCollectToAccountInfoFromVendorContact||s.paymentType?.method?.includes("ach"),tooltipText:Tn(),additionalInfoLabel:t.jsx(Wa,{children:Dn})}),jn()]})})]}),E||e.isRecurring?t.jsxs(t.Fragment,{children:[t.jsx(R,{}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:"recurringPaymentType"}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("recurringPaymentType")}`},children:t.jsxs(t.Fragment,{children:[t.jsx(A,{label:{label:n.paymentType,width:D},labelStyles:{marginRight:m.labelMarginRight.valuePx(l)},style:{width:"auto"},text:ia(e.isRecurring,E,e.transactionDetails?.recurringBillInstance??1,e.recurringBillConfigDetail?.totalPaymentCycles??0),textStyles:{paddingLeft:m.textPadding.valuePx(l),paddingRight:m.textPadding.valuePx(l)},additionalInfoLabel:aa(l,e.isRecurring,E,e.recurringBillConfigDetail),additionalInfoLabelStyles:{paddingRight:m.paddingRight.valuePx(l),marginTop:m.additionalTextMarginTop.valuePx(l)}}),e.recurringBillInstances!=null&&e.recurringBillInstances.length>0?t.jsx(pi,{style:{paddingLeft:m.recurringSchedulePaddingLeft.valuePx(l)},children:t.jsx(la,{onAttachmentClick:ze,currencySymbol:e.transactionDetails?.recipientTotalAmount.currencySymbol??ht.currencySymbol,recurringBillInstances:e.recurringBillInstances})}):null]})})]}):null]})]}),e.transactionDetails&&e.transactionDetails.id&&t.jsx(oa,{amount:bn,activities:e.billActivities,stage:k?.code??"draft",onAddNewRule:Ut,entity:"bill_pay",realTimeApproval:{allApprovers:e.filteredApprovers,filteredAttributes:e.filteredAttributes,isRealTimeApproverEditMode:e.realTimeApproval.isEditMode,realTimeApprovalSaveStatus:{fetchState:e.realTimeApproval.fetchState,error:e.realTimeApproval.error},approvalListFetchState:e.approverListFetchState.fetchState,allAccountingClass:e.allAccountingClasses,vendorOwnerId:e.vendorOwnerId??"",isAdmin:Ot,signedInUserId:le?.userId,showRealTimeApproval:Ft,entityApprovalId:e.billActivities[0]?.entityApprovalId??e.transactionDetails.entityApprovalId,updateEditMode:Ht,onSaveRealTimeApprovals:qt},historicActivities:e.billHistory.activities}),t.jsx(si,{})]}),e.transactionDetails?.vendor!=null&&!me&&!e.transactionDetails.isDeleted?t.jsx(ra,{separatorStyle:{marginRight:a.sp4},showPrimaryButton:K||x,showCancel:!K&&x,cancelBtn:{label:et?n.buttons.reject:n.buttons.rejectBill,isLoading:_e==="rejected"&&e.approvalUpdateStatus.fetchState==="In-Progress",onClick:zn,style:{width:m.footerButtonWidth.value(l)},reverseSpinnerColor:!1},primaryBtn:{label:Fa(K,et),isLoading:_e==="approved"&&e.approvalUpdateStatus.fetchState==="In-Progress",onClick:K?tt:()=>{W!=null?q(!0):nt()},isDisabled:e.billSaveStatus==="In-Progress"||e.approvalUpdateStatus.fetchState==="In-Progress"||e.realTimeApproval.isEditMode===!0,style:{width:K?"auto":m.footerButtonWidth.value(l)}},rightSideComponent:t.jsx(Za,{children:t.jsxs(Ha,{windowSize:l,children:[!ae&&Oe?t.jsx(mt,{onClickAway:()=>{oe(!1),de(!1)},children:t.jsxs(Tt,{windowSize:l,"data-testid":b("bill-actions-container"),children:[we!=="processing"?t.jsx(_,{onClick:dn,"data-testid":b("delete-bill-action-item"),children:n.buttons.deleteBill}):null,we==="processing"&&!M?t.jsx(_,{onClick:cn,"data-testid":b("cancel-bill-action-item"),children:n.buttons.cancel}):null,we==="processing"&&Sn?t.jsx(_,{onClick:pn,"data-testid":b("cancel-and-delete-bill-action-item"),children:n.buttons.cancelAndDelete}):null,x&&E&&Wt?t.jsx(_,{onClick:Pn,"data-testid":b("mark-as-paid-action-item"),children:n.paymentOutsideZeni.markAsPaid}):null]})}):null,Fe?t.jsx(mt,{onClickAway:()=>{oe(!1),de(!1)},children:t.jsxs(Tt,{windowSize:l,"data-testid":b("bill-actions-with-zeni-assist-container"),children:[xe?t.jsx(_,{onClick:()=>{z.trackRetryClick(v?.code??"",k?.code??"",F?.description??"",M?["Recurring"]:["One-Time"],e.transactionDetails?.documentId??""),Jt()},"data-testid":b("retry-bill-action-item"),children:n.buttons.retry}):null,ge?t.jsx(_,{onClick:mn,"data-testid":b("refund-bill-action-item"),children:n.buttons.refund}):null]})}):null,t.jsxs(Ga,{windowSize:l,children:[$n===!0?t.jsx(Te,{enterDelay:600,style:{color:ie.heroDark,padding:`2px ${a.sp2}`},display:"flex",title:fe?n.zeniAssist.tooltip:n.zeniAssist.connectToTeamTooltip,placement:"top",maxWidth:"267px",children:t.jsx(wt,{windowSize:l,showEditIcon:be,isIconClickable:fe,"data-testid":b("other-actions-icon-container"),children:fe?t.jsx(hn,{}):t.jsx(Va,{})})}):null,!ae&&be===!0?t.jsx(Te,{enterDelay:600,style:{color:ie.heroDark,padding:`2px ${a.sp2}`},display:"flex",title:za,placement:"top",children:t.jsx(Ya,{onClick:qe,"data-testid":b("edit-bill-icon-container"),children:t.jsx(Ua,{})})}):null,!ae&&kn===!0?t.jsx(Te,{enterDelay:600,style:{color:ie.heroDark,padding:`2px ${a.sp2}`},display:"flex",title:Ra,placement:"top",children:t.jsx(wt,{windowSize:l,showEditIcon:be,isIconClickable:!0,"data-testid":b("more-details-icon-container"),children:t.jsx(Ka,{onClick:()=>oe(!Oe)})})}):null]})]})}),style:{minHeight:62}}):null]}),f?t.jsx($a,{id:T,children:t.jsx(sa,{isDrawerOpen:nn,allowComposer:!0,drawerTitle:Ma,threads:Y,filter:w,autoExpand:!0,autoFocus:!1,isLoading:P,textOverrides:{composerPlaceholder:gt.addANewComment,replyComposerPlaceholder:gt.replyAComment,threadResolve:ft.resolveComment,threadUnResolve:ft.unResolveComment},threadMetadata:Rn,onThreadClick:an,onCloseAllThreadsDrawer:()=>U(!1),drawerSectionStyle:{width:l==="small"?"100%":"400px",boxSizing:l==="small"?"border-box":"content-box",padding:`${a.sp0} ${m.drawerSectionPaddingLeftRight.valuePx(l)}`,backgroundColor:Ne.colors.background},collapsibleThreadStyle:{width:l==="small"?"100%":"360px"}})}):null]})},Na=(e,g)=>{const x=e?.code;if(e!=null&&x!=null)return g?.isDeleted===!0?{value:ke.tabsById.deleted,color:O.deleted.color,bgColor:O.deleted.bgColor,borderColor:O.deleted.borderColor,code:"deleted"}:x==="pending_approval"&&g?.dueDate?.isBefore(L.dateNow(),"date")===!0?{value:ke.tabsById.overdue,color:O.overdue.color,bgColor:O.overdue.bgColor,borderColor:O.overdue.borderColor}:{value:e.name,color:O[x].color,bgColor:O[x].bgColor,borderColor:O[x].borderColor}},Oa=(e,g)=>{const x=g.transactionDetails?.recipientTotalAmount;return t.jsxs(mi,{windowSize:e,children:[t.jsxs(kt,{windowSize:e,children:[t.jsx(St,{children:n.zeniAssist.accountNumber}),t.jsx(Ct,{children:g.withdrawFrom!=null?Rt(g.withdrawFrom,e):d})]}),t.jsxs(kt,{windowSize:e,children:[t.jsx(St,{children:n.zeniAssist.amount}),t.jsx(Ct,{children:x!=null?Ae("0,0[.]00",x):C})]})]})},Fa=(e,g)=>e?n.paymentOutsideZeni.markAsPaid:g?n.buttons.approve:n.buttons.approveBill,Ea=e=>{const g=e.paymentMode,x=n.paymentOutsideZeni.offline;if(g==null||g==="other")return x;const Z=n.paymentOutsideZeni.paymentModeOptions.find(le=>le.value===g)?.label;return`${x} ${Ba} ${Z}`},La=(e,g,x)=>{if(e)return t.jsx(ut,{variant:"warning",style:{marginTop:a.sp5,marginBottom:a.sp3},title:bt.duplicateWarning.title,description:bt.duplicateWarning.description});if(x!=null){const Z=`${g.withdrawFrom?.label??""} ${g.withdrawFrom?.maskedAccountNumber??""}`;return t.jsx(ut,{variant:"low-balance",style:{marginTop:a.sp2,marginBottom:a.sp3},title:`${Nt.lowBalanceIn.replace("__account__",Z)}`,description:x.replace("Low balance! ","")})}else return null},Wa=i.div``,_a=i.div``,Za=i.div`
1
+ import{X as Nn,w as On,u as Fn,fL as En,fM as Ln,fN as _n,fO as Wn,aV as Zn,a5 as Kn,M as Vn,C as u,j as t,l as L,cF as it,cG as Un,o as a,cH as qn,cI as Gn,Y as b,cJ as Hn,_ as Ae,cK as Yn,aW as lt,aH as ot,dr as rt,bN as st,bP as dt,bQ as ct,fP as Jn,fQ as Qn,fR as Xn,fS as ea,cP as j,cQ as I,cR as $,fT as A,cO as ta,q as pt,g as ie,cS as Rt,cT as na,cU as aa,cV as ia,fU as la,fV as oa,a7 as ra,m as mt,bu as Te,fW as sa,fX as O,p as r,b as da,bq as ca,fY as pa,a6 as ma,fZ as ua,f_ as ut,c_ as yt,Q as ya,cu as ha,ah as ba,aq as xa,as as ga,k as fa,eZ as zt,f$ as wa,v as Mt,at as Ta,au as va,aN as Da,eJ as ja,s as Ia}from"./index-C0q2xQ43.js";import{b as p,n as i}from"./vendor-CnQcJ2Lu.js";import{_ as $a}from"./liveblocks-BUGn2yQ6.js";import{o as Aa,t as ka}from"./LowBalancePopup-OSUi1Alp-D-EAEgV_.js";import"./mui-BgvZYSo0.js";import"./analytics-BSSiLa6f.js";import"./routing-BNz5gZgX.js";import"./sentry-HDxG13yk.js";import"./redux-DmDqXYej.js";import"./crypto-BURQLTgV.js";const Sa=e=>p.createElement("svg",{xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 32 32",...e},p.createElement("g",{id:"Layer_1"},p.createElement("path",{fill:"none",stroke:"#757d7e",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round",d:"M4.4,30.6l6-5.9c1,.6,2.1.9,3.3,1,1.1.1,2.3,0,3.4-.4,1.1-.4,2.1-.9,2.9-1.7.9-.8,1.5-1.7,2-2.7,0-.1,0-.2,0-.4,0-.1,0-.2-.1-.3,0-.1-.2-.2-.3-.2-.1,0-.2,0-.4,0h-4.6c-.8,0-1.6-.3-2.1-.9-.6-.6-.9-1.3-.9-2.1s.3-1.5.9-2.1c.6-.6,1.3-.9,2.1-.9h3.8c.1,0,.3,0,.4-.1s.2-.2.3-.3c0-.1,0-.3,0-.4,0-.1,0-.3-.1-.4-1.3-1.6-3.1-2.7-5.2-3.1-2.1-.4-4.2,0-5.9,1.2-1.8,1.1-3,2.8-3.5,4.8s-.2,4.1.8,5.9l-6.1,5.7,3.3,3.3Z"})),p.createElement("g",{id:"Layer_2"},p.createElement("g",null,p.createElement("path",{fill:"#c27419",stroke:"#f3f7f7",strokeWidth:1.2,strokeLinecap:"round",strokeLinejoin:"round",d:"M31,8c0,1.9-.7,3.8-2.1,5.1-1.3,1.4-3.2,2.2-5.1,2.2-.9,0-1.9-.2-2.7-.5-.9-.3-1.7-.9-2.3-1.5-.7-.7-1.2-1.4-1.6-2.3-.4-.9-.6-1.8-.6-2.7,0-1.9.7-3.8,2.1-5.1,1.3-1.4,3.2-2.2,5.1-2.2.9,0,1.9.2,2.7.5.9.3,1.7.9,2.3,1.5.7.7,1.2,1.4,1.6,2.3.4.9.6,1.8.6,2.7Z"}),p.createElement("path",{fill:"none",stroke:"#f3f7f7",strokeWidth:1.2,strokeLinecap:"round",strokeLinejoin:"round",d:"M23.8,9.4v-4.6"}),p.createElement("path",{fill:"none",stroke:"#f3f7f7",strokeWidth:1.2,strokeLinecap:"round",strokeLinejoin:"round",d:"M23.8,11.4s0,0,0,0c0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,.1,0,0,0,0,.1,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0-.1,0,0,0,0-.1,0h0"})))),Ca={formTitle:new ya("h6Medium","h5Medium")},m={containerPaddingLeft:new u(r[3],r[6],r[6]),containerPaddingRight:new u(r[3],r[6],r[8]),marginBottom:new u(r[3],r[3]),labelWidth:new u(120,160,160),formTitlePaddingLeftRight:new u(30,0),marginTop:new u(r[1],0),rightIconsGap:new u(r[4],r[5]),closeContainerMarginTop:new u(r[1],0),formTitleMarginTopBottom:new u(0,0),footerButtonWidth:new u(120,120,120,165,165),right:new u(r[3],r[0]),actionsContainerRight:new u(r[0],r[3],r[3],r[6],r[6]),otherActionsIconContainerMarginLeft:new u(r[5],r[4],r[4],r[5]),otherActionsContainerBottom:new u(58,44),iconContainerMarginTop:new u(2,r[1]),recurringSchedulePaddingLeft:new u(r[2],0),paddingRight:new u(r[2],r[3]),labelMarginRight:new u(r[0],r[3]),textPadding:new u(r[0],r[3]),additionalTextMarginTop:new u(-4,0),refundPopupWidth:new u(300,420,420),drawerSectionPaddingLeftRight:new u(r[4],r[5]),infoLabelPaddingRight:new u(r[3],r[3]),infoLabelMarginTop:new u(r[1],r[0]),navBarHeight:new u(0,0,r[8]),navBarContainerWidth:new u(100,58)},{dateFormat:Pa,common:{noText:C,strings:{empty:d},currency:ht,via:Ba,more:Ra,edit:za},spendManagement:{billPay:{billDetails:n,billsByTabs:ke,bulkActions:bt,vendorCreation:xt,insufficientFunds:Nt}},collaboration:{threads:{placeholder:gt,tooltip:ft,title:{comments:Ma}}}}=Vn.getLocalizedStrings(),ve=Pa.visual.MMMDCommaYYYYformat,ji=({billDetails:e,currentTenant:g,showApproveRejectBtns:x,isShowDeletedBillsEnabled:Z,signedInUser:le,isAdmin:Ot,isRealTimeApprovalEnabled:Ft,isInternationalPaymentShaVsOurEnabled:Et,hasZeniAssistAccess:Lt,analytics:z,showMarkAsPaidButtonToCreator:K,showMarkAsPaidButtonToApprover:_t,isBillPayCommentingEnabled:Se,isZeniUser:Wt,showBackButton:Ce=!0,isDetectInsufficientFundsEnabled:Zt,redirectToEditableBillScreen:Kt,redirectToBillsScreen:H,discardBillDetailsFromLocalStore:Pe,deleteBill:Vt,cancelAndDeleteBill:Be,approveOrRejectBill:Re,onAddNewRule:Ut,onAttachmentClick:ze,saveBillDetails:qt,discardOutsideZeniPaymentData:Gt,onBackClick:Me,updateEditRealTimeApproverClicked:Ht,onSaveRealTimeApprovals:Yt,onRetryPaymentClick:Jt,onRefundPaymentClick:Qt})=>{const l=Nn(),o=On(),Ne=Fn(),[Xt,V]=p.useState(!1),[Oe,oe]=p.useState(!1),[re,se]=p.useState(!1),[Fe,de]=p.useState(!1),[en,ce]=p.useState(!1),[Ee,Y]=p.useState(!1),y=e.transactionDetails?.id,tn=Wt?En:Ln,{requestToOpenThread:pe,setRequestToOpenThread:Le,setOpenThread:J}=p.useContext(tn),[nn,U]=p.useState(!1),w={application:"dashboard",companyId:o.currentTenant?.companyId,tab:"bill",entityId:y,isGlobalComment:!1},{threads:q,isLoading:P}=_n(w,"both",!1),f=Se&&y!=null,_e=p.useMemo(()=>y==null?[]:q.filter(c=>c.resolved===!1&&!c.id.includes(Wn)),[q,y]).length,T=`dashboard_${o.currentTenant?.companyId}`,an=p.useCallback((c,h)=>{J(h),U(!1)},[J,U]);p.useEffect(()=>{pe?.threadId!=null&&q.length>0&&!P&&(J(pe.threadId),Le(null))},[pe,q,P,J,Le]),Zn({componentName:"bills.details"});const[N,Q]=p.useState({title:"",description:"",primaryButtonText:"",secondaryButtonText:""}),[We,Ze]=p.useState("approved"),[ln,Ke]=p.useState(!1),[on,Ve]=p.useState(!1),[Ue,qe]=p.useState(!1),Ge=()=>Ke(!1),rn=()=>Ke(!0),He=Kn(e.zeniAssist?.refundStatus.fetchState),X=p.useCallback(()=>{H()},[H]);p.useEffect(()=>{(e.deleteStatus.fetchState==="Completed"||e.approvalUpdateStatus.fetchState==="Completed"||e.cancelAndDeleteStatus.fetchState==="Completed"||e.billSaveStatus==="Completed")&&(Pe(),H())},[e,H,Pe]),p.useEffect(()=>{He==="In-Progress"&&(e.zeniAssist?.refundStatus.fetchState==="Completed"||e.zeniAssist?.refundStatus.fetchState==="Error")&&(se(!1),X())},[He,e.zeniAssist?.refundStatus,X]);const k=e.transactionDetails?.billPayInfo.stage,ee=e.transactionDetails?.billPayInfo.billStatus,G=e.transactionDetails?.billPayInfo.billPaymentStatus,sn=e.transactionDetails?.billPayInfo.billPaymentRefundStatus,me=k?.code==="paid",v=me?k:ee?.code=="approved"&&G?.code?G:ee,S=Na(v,e.transactionDetails),F=e.transactionDetails?.billPayInfo.isRefundInitiated===!0?sn:G?.code!=null&&(ee?.code=="approved"||G.code==="mark_as_paid")?G:ee,ue=e.transactionDetails?.vendor?.name,M=e.isRecurring,Ye=()=>{e.transactionDetails?.id!=null&&Kt(e.transactionDetails?.id??"")},dn=()=>{Q({title:M?n.recurringBill.deleteRecurringTitle:n.deleteBillTitle,description:M?n.recurringBill.deleteRecurringAlertText:n.deleteAlertDescription,primaryButtonText:n.delete,secondaryButtonText:n.cancel}),V(!0)},cn=()=>{Q({title:n.cancelBillTitle,description:n.cancelAlertDescription,primaryButtonText:n.yes,secondaryButtonText:n.no}),V(!0)},pn=()=>{Q({title:M?n.recurringBill.cancelAndDeleteRecurringTitle:n.cancelAndDeleteBillTitle,description:M?n.recurringBill.cancelAndDeleteRecurringAlertText:n.cancelAndDeleteAlertDescription,primaryButtonText:n.yes,secondaryButtonText:n.no}),V(!0)},mn=()=>{z.trackRefundClick(v?.code??"",k?.code??"",F?.description??"",M?["Recurring"]:["One-Time"],e.transactionDetails?.documentId??""),Q({title:n.zeniAssist.refundTitle,description:n.zeniAssist.refundDescription,primaryButtonText:n.zeniAssist.proceed,secondaryButtonText:n.cancel}),se(!0)},un={onOkClick:()=>{V(!1),N.primaryButtonText===n.delete?Vt?.(e.isRecurring):N.title===n.cancelBillTitle?Be?.(e.isRecurring):N.title===n.cancelAndDeleteBillTitle||N.title===n.recurringBill.cancelAndDeleteRecurringTitle?Be?.(e.isRecurring,!0):N.primaryButtonText===n.zeniAssist.proceed&&(z.trackRefundConfirmClick(v?.code??"",k?.code??"",F?.description??"",M?["Recurring"]:["One-Time"],e.transactionDetails?.documentId??""),Qt())},onCancelClick:()=>{V(!1),se(!1)}},yn={onOkClick:c=>{ce(!1),Re({billId:e.transactionDetails?.id??"",type:"rejected",description:c})},onCancelClick:()=>{ce(!1)}},hn=()=>{const[c]=Ta("ZeniAssist");return c!=null?t.jsx(va,{"data-testid":b("bill-details-zeni-assist-icon",y),onClick:()=>{de(!Fe),z.trackZeniAssistClick(v?.code??"",k?.code??"",F?.description??"",M?["Recurring"]:["One-Time"],e.transactionDetails?.documentId??"")},style:{width:`${a.sp5}`,height:`${a.sp5}`,marginBottom:`${a.sp2}`},animationData:c,loop:!0,play:!0,rendererSettings:{preserveAspectRatio:"xMidYMid slice"}}):null},te={invoiceNumber:e.transactionDetails?.documentId??"",invoiceDate:e.transactionDetails?.date,billDueDate:e.transactionDetails?.dueDate,memo:e.transactionDetails?.memo,currencyCode:e.vendorCurrency??ht.currencyCode},ye=e.transactionDetails?.lines?.map((c,h)=>{const B=c;return{lineIndex:h,lineId:B.id,account:B.account,class:B.class,amount:B.amount.amount,billable:B.billable,customer:B.customer,lineDescription:B.lineDescription,recipientAmount:B.recipientAmount?.amount}})??[],bn=e.transactionDetails?.recipientTotalAmount.amount??0,he=e.transactionDetails?.recipientTotalAmount,s={paymentType:e.paymentMethodType,paymentDate:e.transactionDetails?.billPayInfo.paymentDate,internationalTransferFeeBearerPaymentMethod:e.transactionDetails?.billPayInfo.internationalTransferFeeBearerPaymentMethod,paymentToBankAccount:e.bankAccount,paymentToPI:e.paymentInstrument},D=m.labelWidth.value(l),xn=c=>c==="billable"||c==="has_been_billed"?n.yes:n.no,gn=s.paymentToBankAccount?.bankAccountNumber?s.paymentToBankAccount?.bankAccountNumber?.slice(s.paymentToBankAccount?.bankAccountNumber?.length-4):s.paymentType?.method?.includes("international")&&s.paymentToBankAccount?.bankAccountIban?s.paymentToBankAccount?.bankAccountIban?.slice(s.paymentToBankAccount?.bankAccountIban.length-4):"",fn=s.paymentToBankAccount?.bankAccountName!=null&&s.paymentToBankAccount?.bankAccountName!=""?s.paymentToBankAccount?.bankAccountName:`${e.transactionDetails?.vendor?.name} - ${s.paymentToBankAccount?.bankName} XXXX${gn}`,wn=e.transactionDetails?.billPayInfo?.isCollectToAccountInfoFromVendorContact?t.jsxs(t.Fragment,{children:[`${n.magicLink.collectFrom} ${e.transactionDetails?.billPayInfo?.toAccountVendorEmail}`,t.jsx(ci,{windowSize:l,children:t.jsx(di,{})})]}):void 0,Je=e.transactionDetails?.date!=null&&e.transactionDetails.bookCloseDate!=null&&e.transactionDetails.date.isBefore(e.transactionDetails.bookCloseDate),Tn=()=>`${xt.achDetails.bankRoutingNumber} ${s?.paymentToBankAccount?.bankRoutingNumberAch}, ${s?.paymentToBankAccount?.bankName}
2
+ ${xt.achDetails.bankAccountNumber} ${s?.paymentToBankAccount?.bankAccountNumber}`,ne=e.transactionDetails?.billPayInfo!=null?L.getActualPaymentDate(e.transactionDetails?.billPayInfo):void 0,vn=ne!=null&&e.paymentMethodType?.maxPeriod?.value!=null?L.zeniDate(L.getNextNthWorkingDay(ne?.toDate(),[0,6],e.paymentMethodType?.maxPeriod.value).toDateString()):void 0,Qe=e.transactionDetails?.billPayInfo.expectedDepositDate??vn,Xe=it(s?.paymentType?.method??"").replace("Same Day",""),Dn=(s?.paymentToBankAccount!=null||s?.paymentToPI)!=null?n.addedByZeni:e.transactionDetails?.billPayInfo.isCollectToAccountInfoFromVendorContact?t.jsx(Un,{paymentTypeLabel:Xe,onClick:rn,style:{marginTop:`${l==="small"?a.sp2:a.sp0}`}}):void 0,jn=()=>s?.paymentToBankAccount==null&&s?.paymentToPI==null&&s?.paymentType?.method!=null&&e.transactionDetails?.billPayInfo.isCollectToAccountInfoFromVendorContact&&e.transactionDetails?.billPayInfo.paymentDate!=null?t.jsx(wa,{paymentType:s?.paymentType?.method,paymentDate:e.transactionDetails?.billPayInfo.paymentDate}):null,be=!(v?.code==="processing"||e.transactionDetails?.billPayInfo.isRefundInitiated===!0||e.transactionDetails?.billPayInfo.isRefundComplete===!0),xe=e.zeniAssist?.isEligibleForRetryIBT===!0||e.zeniAssist?.isEligibleForRetryOBP===!0,ge=e.zeniAssist?.isEligibleForRefund===!0,In=e?.transactionDetails?.billPayInfo.billPaymentMethodType.code==="wire"&&e?.transactionDetails?.billPayInfo.billPaymentMethodType.subCode==="international",$n=Lt&&e.transactionDetails?.billPayInfo.billPaymentStatus.code!=null&&["failed","cancelled","returned"].includes(e.transactionDetails.billPayInfo.billPaymentStatus.code)&&(xe||ge)&&In===!1,fe=xe||ge,An=e.transactionDetails?.billPayInfo.isRefundInitiated===!0&&e.transactionDetails?.billPayInfo.isRefundComplete===!1,we=v?.code,kn=!An&&(!Je||v?.code==="processing"&&!M),Sn=!Je,et=["small","medium-compact","medium-regular"].includes(l),ae=L.isBulkProcessing(e.transactionDetails?.bulkProcessingDetail?.type),E=L.isPaymentMethodOutsideZeni(e.paymentMethodType?.method),Cn=c=>{z.trackBillPayMarkAsPaidSubmit(c.paymentMode??"other",k?.code??"",v?.code??""),qt(!0,Ue,c)},tt=()=>{Ve(!0),z.trackBillPayMarkAsPaid(k?.code??"",v?.code??"")},Pn=()=>{qe(!0),tt()},Bn=()=>{Gt(),Ve(!1),Ue&&qe(!1)},Rn=p.useMemo(()=>({companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,entityType:"bill.details",entityId:y??d,isGlobalComment:!1,application:"dashboard",tab:"bill",url:window.location.href}),[o.currentTenant,y]),_=Zt&&e.transactionDetails?.totalAmountWithFeesInUSD!=null&&k?.code!=="paid"&&v?.code!=="failed"&&v?.code!=="processing"&&v?.code!=="cancelled"&&v?.code!=="returned"&&v?.code!=="rejected"?qn(e.transactionDetails?.totalAmountWithFeesInUSD,e.withdrawFrom,s.paymentDate):void 0,nt=()=>{Ze("approved"),Ee===!0&&Y(!1),_!=null&&z.trackLowBalanceAccountApprove(k?.code??"",e.transactionDetails?.billPayInfo.billPaymentStatus.code??"",e.isRecurring?["Recurring"]:["One-Time"],e.transactionDetails?.documentId??"",yt(o.loggedInUser),e.withdrawFrom?.accType==="depositAccount"?"ZA":"External Account"),Re({billId:e.transactionDetails?.id??"",type:"approved"})},zn=()=>{Ze("rejected"),_!=null&&z.trackLowBalanceAccountReject(k?.code??"",e.transactionDetails?.billPayInfo.billPaymentStatus.code??"",e.isRecurring?["Recurring"]:["One-Time"],e.transactionDetails?.documentId??"",yt(o.loggedInUser),e.withdrawFrom?.accType==="depositAccount"?"ZA":"External Account"),ce(!0)},at=p.useRef(null);return t.jsxs(Ya,{windowSize:l,ref:at,children:[t.jsx(Gn,{anchor:"right",open:ln,onClose:Ge,transitionDuration:250,"data-testid":b("vendor-email-preview-drawer"),children:t.jsx(Hn,{companyName:Yn(g.company?.companyInfo),vendor:e.transactionDetails?.vendor?.name,paymentDate:s.paymentDate?.format(ve)??"",paymentType:Xe,amount:Ae("0,0.[00]",he),isInvoiceAttached:!!e.transactionDetails?.attachments?.length,onClose:Ge})}),t.jsxs(ei,{windowSize:l,children:[t.jsx(ui,{windowSize:l,children:l==="small"?t.jsx(lt,{"data-testid":b("bill-detail-nav-bar-mobile"),title:t.jsxs(t.Fragment,{children:[ue,e.isRecurring?t.jsx($e,{width:a.sp4,height:a.sp4}):null]}),backgroundColor:Ne.colors.grey4,rightSideComponent:t.jsxs(It,{windowSize:l,children:[f?t.jsxs(Pt,{isDisabled:P,"data-testid":b("bill-comment-button"),onClick:P?()=>null:c=>{c.preventDefault(),c.stopPropagation(),U(!0),z.trackCommentActivity("bill","clicked",o.currentTenant?.companyName??"",o.controllersList.controllers.map(h=>rt(h)),void 0,void 0,"page icon")},children:[t.jsx(ot,{count:P?void 0:_e,isLoading:P,style:{left:"12px"}}),t.jsx(Bt,{})]}):null,t.jsx($t,{onClick:()=>X(),"data-testid":b("bill-detail-nav-bar-small-close-button"),children:t.jsx(jt,{})})]}),leftSideComponent:t.jsx(Dt,{windowSize:l,onClick:Me,"data-testid":b("bill-detail-nav-bar-small-back-button"),style:{visibility:`${Ce?"visible":"hidden"}`},children:t.jsx(vt,{})}),source:"BillDetailPage"}):t.jsx(lt,{"data-testid":b("bill-detail-nav-bar"),title:t.jsxs(t.Fragment,{children:[ue,e.isRecurring?t.jsx($e,{width:a.sp4,height:a.sp4}):null]}),rightSideComponent:t.jsxs(It,{windowSize:l,children:[f?t.jsxs(Pt,{isDisabled:P,"data-testid":b("bill-comment-button"),onClick:P?()=>null:c=>{c.preventDefault(),c.stopPropagation(),U(!0),z.trackCommentActivity("bill","clicked",o.currentTenant?.companyName??"",o.controllersList.controllers.map(h=>rt(h)),void 0,void 0,"page icon")},children:[t.jsx(ot,{count:P?void 0:_e,isLoading:P,style:{left:"12px"}}),t.jsx(Bt,{})]}):null,t.jsx($t,{onClick:()=>X(),"data-testid":b("bill-detail-nav-bar-close-button"),children:t.jsx(jt,{})})]}),leftSideComponent:t.jsx(Dt,{windowSize:l,onClick:Me,"data-testid":b("bill-detail-nav-bar-back-button"),style:{visibility:`${Ce?"visible":"hidden"}`},children:t.jsx(vt,{})}),enableTitleOnScroll:!0,scrollableContent:at,source:"BillDetailPage"})}),t.jsxs(ti,{windowSize:l,children:[Ee?t.jsx(Aa,{withdrawFrom:e.withdrawFrom,paymentDate:e?.transactionDetails?.billPayInfo.paymentDate,onOkClick:nt,onCancelClick:()=>{Y(!1),Ye()},onClickAway:()=>{Y(!1)}}):null,on?t.jsx(ka,{onCancel:Bn,onProceedForMarkAsPaid:Cn,saveDetailsFetchState:e.billSaveStatus,paymentData:e.outsideZeniPaymentInfo}):null,Xt||re?t.jsx(st,{titleComponent:t.jsx(ct,{children:N.title}),descriptionComponent:t.jsx(dt,{children:N.description}),primaryButtonText:N.primaryButtonText,proceedButtonVariant:re?"primary":"danger",secondaryButtonText:N.secondaryButtonText,action:un,isEditPopup:!0,isLoading:e.zeniAssist?.refundStatus.fetchState==="In-Progress",children:re?Oa(l,e):null}):null,en?t.jsx(st,{titleComponent:t.jsx(ct,{children:n.rejectBillTitlePrefix+" "+(e.transactionDetails?.vendor?.name!=null?e.transactionDetails.vendor.name:"")}),descriptionComponent:t.jsx(dt,{children:n.rejectBillDescription}),primaryButtonText:n.send,secondaryButtonText:n.cancel,action:yn,isEditPopup:!0,isNotesIncluded:!0,notesPlaceholder:n.rejectBillReasonPlaceholder}):null,l!=="small"||S?t.jsxs(ai,{windowSize:l,children:[l!=="small"?t.jsxs(ii,{windowSize:l,children:[ue,e.isRecurring?t.jsx($e,{height:a.sp5,width:a.sp5}):null]}):null,Z&&S!=null&&S.code==="deleted"?t.jsx(At,{color:S.color,bgColor:S.bgColor,borderColor:S.borderColor,children:S.value}):S?.value===ke.tabsById.overdue?t.jsx(At,{color:S.color,bgColor:S.bgColor,borderColor:S.borderColor,children:S.value}):null]}):null,F!=null&&F.code?l==="small"?t.jsx(Jn,{progressSectionObj:F,createDate:e.transactionDetails?.createTime,paymentDate:Qe,scheduleDate:ne,approvedDate:e.latestApprovedDate,isFrozen:e.transactionDetails?.isDeleted}):t.jsx(Qn,{progressSectionObj:F,createDate:e.transactionDetails?.createTime,paymentDate:Qe,scheduleDate:ne,approvedDate:e.latestApprovedDate,isFrozen:e.transactionDetails?.isDeleted}):null,La(ae,e,_),t.jsx(Xn,{sectionId:ea,currentVendorOption:{defaultOptions:[]},billId:y,isBillPayCommentingEnabled:Se,isBillPaid:me,disableVendorActions:!0,vendor:e.transactionDetails?.vendor,prevBills:e.previousBills,onAttachmentClick:ze,isVendorRecommendationEnabled:!1,showVendorGptRecommendationText:!1}),s.paymentType?.method?.includes("ach"),t.jsxs(je,{children:[t.jsx(Ie,{children:n.whatForTitle}),t.jsxs(De,{children:[t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:"invoiceNumber"}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("invoiceNumber")}`},children:t.jsx(A,{label:{label:n.invoiceNumber,width:D},text:te.invoiceNumber??C,style:{width:"auto"}})}),t.jsx(R,{}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:"invoiceDate"}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("invoiceDate")}`},children:t.jsx(A,{label:{label:n.invoiceDate,width:D},text:te.invoiceDate?.format(ve)??C,style:{width:"auto"}})}),t.jsx(R,{}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:"billDueDate"}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("billDueDate")}`},children:t.jsx(A,{label:{label:n.billDueDate,width:D},text:te.billDueDate?.format(ve)??C,style:{width:"auto"}})}),t.jsx(R,{}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:"memo"}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("memo")}`},children:t.jsx(A,{label:{label:n.memo,width:D},text:te.memo??C,style:{width:"auto"}})})]})]}),t.jsxs(je,{children:[t.jsx(ni,{windowSize:l,children:t.jsx(Ie,{children:n.lineItemsTitle})}),ye.length>0?ye.map((c,h)=>{const B=e?.transactionDetails?.lines?.find(Mn=>Mn.id===c.lineId)?.recipientAmount;return t.jsxs(Ja,{children:[ye.length>1?t.jsx(Qa,{windowSize:l,children:t.jsx(Xa,{windowSize:l,children:`${n.line} # ${h+1}`})}):null,t.jsxs(De,{children:[t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:`${h}.recipientAmount`}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("recipientAmount",h)}`},children:t.jsx(A,{label:{label:n.amount,width:D},text:B!=null?Ae("0,0[.]00",B):C,style:{width:"auto"}})}),t.jsx(R,{}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:`${h}.lineDescription`}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("lineDescription",h)}`},children:t.jsx(A,{label:{label:n.description,width:D},text:c.lineDescription??C,style:{width:"auto"}})}),t.jsx(R,{}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:`${h}.account`}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("account",h)}`},children:t.jsx(A,{label:{label:n.category,width:D},text:c.account?.accountName??C,style:{width:"auto"}})}),t.jsx(R,{}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:`${h}.class`}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("class",h)}`},children:t.jsx(A,{label:{label:n.class,width:D},text:c.class?.className??C,style:{width:"auto"}})}),t.jsx(R,{}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:`${h}.billable`}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("billable",h)}`},children:t.jsx(A,{label:{label:n.billable,width:D},text:c.billable!=null?xn(c.billable):C,style:{width:"auto"}})}),t.jsx(R,{}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:`${h}.customer`}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("customer",h)}`},children:t.jsx(A,{label:{label:n.customer,width:D},text:c.customer?.name??C,style:{width:"auto"}})})]})]},h)}):null]}),t.jsxs(li,{windowSize:l,children:[t.jsx(oi,{children:n.total}),t.jsx(ri,{children:he!=null?t.jsx(ta,{amount:he,integerStyles:pt.h6Medium.cssObject,decimalStyles:pt.standardMedium.cssObject}):C})]}),t.jsxs(je,{children:[t.jsx(Ie,{children:n.paymentDetailsTitle}),t.jsxs(De,{children:[E?null:t.jsxs(t.Fragment,{children:[t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:"withdrawFrom"}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("withdrawFrom")}`},children:t.jsx(A,{label:{label:n.withdrawFrom,width:D},text:e.withdrawFrom!=null?Rt(e.withdrawFrom,l):d,style:{width:"auto"},additionalInfoLabelStyles:{textAlign:"right",paddingRight:m.infoLabelPaddingRight.valuePx(l),marginTop:m.infoLabelMarginTop.valuePx(l),color:ie.brandColorGoldDark},additionalInfoLabel:_!=null&&k?.code==="pending_approval"?Nt.addMoney:_})}),t.jsx(R,{})]}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:"paymentType"}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("paymentType")}`},children:t.jsx(A,{additionalInfoLabel:s.paymentType?.method!=null&&s.paymentType.method.includes(L.NEW_INTERNATIONAL_METHOD_SUBTEXT)&&Et&&s.internationalTransferFeeBearerPaymentMethod!=null?t.jsx(Wa,{children:na(s.internationalTransferFeeBearerPaymentMethod)}):void 0,label:{label:n.paymentMethod,width:D},text:E&&e.outsideZeniPaymentInfo!=null?Ea(e.outsideZeniPaymentInfo):it(s.paymentType?.method??""),style:{width:"auto"}})}),E?null:t.jsxs(t.Fragment,{children:[t.jsx(R,{}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:"paymentTo"}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("paymentTo")}`},children:t.jsxs(t.Fragment,{children:[t.jsx(A,{label:{label:n.paymentTo,width:D},text:s.paymentToBankAccount!=null?fn:s.paymentToPI!=null?s.paymentToPI.displayText:wn,style:{width:"auto"},showEyeIcon:s.paymentToBankAccount!=null&&!!s.paymentType?.method?.includes("ach"),showAdditionalInfoLabel:!!e.transactionDetails?.billPayInfo.isCollectToAccountInfoFromVendorContact||s.paymentType?.method?.includes("ach"),tooltipText:Tn(),additionalInfoLabel:t.jsx(_a,{children:Dn})}),jn()]})})]}),E||e.isRecurring?t.jsxs(t.Fragment,{children:[t.jsx(R,{}),t.jsx(j,{isThreadAllowed:f,entityId:y,dashboardTabKey:$({type:"details",key:"recurringPaymentType"}),roomId:T,companyId:o.currentTenant?.companyId??d,companyName:o.currentTenant?.companyName??d,dashboardOptionType:"bill",filterMetaData:{...w,entityType:`bill.details.${I("recurringPaymentType")}`},children:t.jsxs(t.Fragment,{children:[t.jsx(A,{label:{label:n.paymentType,width:D},labelStyles:{marginRight:m.labelMarginRight.valuePx(l)},style:{width:"auto"},text:ia(e.isRecurring,E,e.transactionDetails?.recurringBillInstance??1,e.recurringBillConfigDetail?.totalPaymentCycles??0),textStyles:{paddingLeft:m.textPadding.valuePx(l),paddingRight:m.textPadding.valuePx(l)},additionalInfoLabel:aa(l,e.isRecurring,E,e.recurringBillConfigDetail),additionalInfoLabelStyles:{paddingRight:m.paddingRight.valuePx(l),marginTop:m.additionalTextMarginTop.valuePx(l)}}),e.recurringBillInstances!=null&&e.recurringBillInstances.length>0?t.jsx(pi,{style:{paddingLeft:m.recurringSchedulePaddingLeft.valuePx(l)},children:t.jsx(la,{onAttachmentClick:ze,currencySymbol:e.transactionDetails?.recipientTotalAmount.currencySymbol??ht.currencySymbol,recurringBillInstances:e.recurringBillInstances})}):null]})})]}):null]})]}),e.transactionDetails&&e.transactionDetails.id&&t.jsx(oa,{amount:bn,activities:e.billActivities,stage:k?.code??"draft",onAddNewRule:Ut,entity:"bill_pay",realTimeApproval:{allApprovers:e.filteredApprovers,filteredAttributes:e.filteredAttributes,isRealTimeApproverEditMode:e.realTimeApproval.isEditMode,realTimeApprovalSaveStatus:{fetchState:e.realTimeApproval.fetchState,error:e.realTimeApproval.error},approvalListFetchState:e.approverListFetchState.fetchState,allAccountingClass:e.allAccountingClasses,vendorOwnerId:e.vendorOwnerId??"",isAdmin:Ot,signedInUserId:le?.userId,showRealTimeApproval:Ft,entityApprovalId:e.billActivities[0]?.entityApprovalId??e.transactionDetails.entityApprovalId,updateEditMode:Ht,onSaveRealTimeApprovals:Yt},historicActivities:e.billHistory.activities}),t.jsx(si,{})]}),e.transactionDetails?.vendor!=null&&!me&&!e.transactionDetails.isDeleted?t.jsx(ra,{separatorStyle:{marginRight:a.sp4},showPrimaryButton:K||x,showCancel:!K&&x,cancelBtn:{label:et?n.buttons.reject:n.buttons.rejectBill,isLoading:We==="rejected"&&e.approvalUpdateStatus.fetchState==="In-Progress",onClick:zn,style:{width:m.footerButtonWidth.value(l)},reverseSpinnerColor:!1},primaryBtn:{label:Fa(K,et),isLoading:We==="approved"&&e.approvalUpdateStatus.fetchState==="In-Progress",onClick:K?tt:()=>{_!=null?Y(!0):nt()},isDisabled:e.billSaveStatus==="In-Progress"||e.approvalUpdateStatus.fetchState==="In-Progress"||e.realTimeApproval.isEditMode===!0,style:{width:K?"auto":m.footerButtonWidth.value(l)}},rightSideComponent:t.jsx(Za,{children:t.jsxs(Ha,{windowSize:l,children:[!ae&&Oe?t.jsx(mt,{onClickAway:()=>{oe(!1),de(!1)},children:t.jsxs(Tt,{windowSize:l,"data-testid":b("bill-actions-container"),children:[we!=="processing"?t.jsx(W,{onClick:dn,"data-testid":b("delete-bill-action-item"),children:n.buttons.deleteBill}):null,we==="processing"&&!M?t.jsx(W,{onClick:cn,"data-testid":b("cancel-bill-action-item"),children:n.buttons.cancel}):null,we==="processing"&&Sn?t.jsx(W,{onClick:pn,"data-testid":b("cancel-and-delete-bill-action-item"),children:n.buttons.cancelAndDelete}):null,x&&E&&_t?t.jsx(W,{onClick:Pn,"data-testid":b("mark-as-paid-action-item"),children:n.paymentOutsideZeni.markAsPaid}):null]})}):null,Fe?t.jsx(mt,{onClickAway:()=>{oe(!1),de(!1)},children:t.jsxs(Tt,{windowSize:l,"data-testid":b("bill-actions-with-zeni-assist-container"),children:[xe?t.jsx(W,{onClick:()=>{z.trackRetryClick(v?.code??"",k?.code??"",F?.description??"",M?["Recurring"]:["One-Time"],e.transactionDetails?.documentId??""),Jt()},"data-testid":b("retry-bill-action-item"),children:n.buttons.retry}):null,ge?t.jsx(W,{onClick:mn,"data-testid":b("refund-bill-action-item"),children:n.buttons.refund}):null]})}):null,t.jsxs(Ga,{windowSize:l,children:[$n===!0?t.jsx(Te,{enterDelay:600,style:{color:ie.heroDark,padding:`2px ${a.sp2}`},display:"flex",title:fe?n.zeniAssist.tooltip:n.zeniAssist.connectToTeamTooltip,placement:"top",maxWidth:"267px",children:t.jsx(wt,{windowSize:l,showEditIcon:be,isIconClickable:fe,"data-testid":b("other-actions-icon-container"),children:fe?t.jsx(hn,{}):t.jsx(Va,{})})}):null,!ae&&be===!0?t.jsx(Te,{enterDelay:600,style:{color:ie.heroDark,padding:`2px ${a.sp2}`},display:"flex",title:za,placement:"top",children:t.jsx(qa,{onClick:Ye,"data-testid":b("edit-bill-icon-container"),children:t.jsx(Ua,{})})}):null,!ae&&kn===!0?t.jsx(Te,{enterDelay:600,style:{color:ie.heroDark,padding:`2px ${a.sp2}`},display:"flex",title:Ra,placement:"top",children:t.jsx(wt,{windowSize:l,showEditIcon:be,isIconClickable:!0,"data-testid":b("more-details-icon-container"),children:t.jsx(Ka,{onClick:()=>oe(!Oe)})})}):null]})]})}),style:{minHeight:62}}):null]}),f?t.jsx($a,{id:T,children:t.jsx(sa,{isDrawerOpen:nn,allowComposer:!0,drawerTitle:Ma,threads:q,filter:w,autoExpand:!0,autoFocus:!1,isLoading:P,textOverrides:{composerPlaceholder:gt.addANewComment,replyComposerPlaceholder:gt.replyAComment,threadResolve:ft.resolveComment,threadUnResolve:ft.unResolveComment},threadMetadata:Rn,onThreadClick:an,onCloseAllThreadsDrawer:()=>U(!1),drawerSectionStyle:{width:l==="small"?"100%":"400px",boxSizing:l==="small"?"border-box":"content-box",padding:`${a.sp0} ${m.drawerSectionPaddingLeftRight.valuePx(l)}`,backgroundColor:Ne.colors.background},collapsibleThreadStyle:{width:l==="small"?"100%":"360px"}})}):null]})},Na=(e,g)=>{const x=e?.code;if(e!=null&&x!=null)return g?.isDeleted===!0?{value:ke.tabsById.deleted,color:O.deleted.color,bgColor:O.deleted.bgColor,borderColor:O.deleted.borderColor,code:"deleted"}:x==="pending_approval"&&g?.dueDate?.isBefore(L.dateNow(),"date")===!0?{value:ke.tabsById.overdue,color:O.overdue.color,bgColor:O.overdue.bgColor,borderColor:O.overdue.borderColor}:{value:e.name,color:O[x].color,bgColor:O[x].bgColor,borderColor:O[x].borderColor}},Oa=(e,g)=>{const x=g.transactionDetails?.recipientTotalAmount;return t.jsxs(mi,{windowSize:e,children:[t.jsxs(kt,{windowSize:e,children:[t.jsx(St,{children:n.zeniAssist.accountNumber}),t.jsx(Ct,{children:g.withdrawFrom!=null?Rt(g.withdrawFrom,e):d})]}),t.jsxs(kt,{windowSize:e,children:[t.jsx(St,{children:n.zeniAssist.amount}),t.jsx(Ct,{children:x!=null?Ae("0,0[.]00",x):C})]})]})},Fa=(e,g)=>e?n.paymentOutsideZeni.markAsPaid:g?n.buttons.approve:n.buttons.approveBill,Ea=e=>{const g=e.paymentMode,x=n.paymentOutsideZeni.offline;if(g==null||g==="other")return x;const Z=n.paymentOutsideZeni.paymentModeOptions.find(le=>le.value===g)?.label;return`${x} ${Ba} ${Z}`},La=(e,g,x)=>{if(e)return t.jsx(ut,{variant:"warning",style:{marginTop:a.sp5,marginBottom:a.sp3},title:bt.duplicateWarning.title,description:bt.duplicateWarning.description});if(x!=null){const Z=`${g.withdrawFrom?.label??""} ${g.withdrawFrom?.maskedAccountNumber??""}`;return t.jsx(ut,{variant:"low-balance",style:{marginTop:a.sp2,marginBottom:a.sp3},title:`${Nt.lowBalanceIn.replace("__account__",Z)}`,description:x.replace("Low balance! ","")})}else return null},_a=i.div``,Wa=i.div``,Za=i.div`
3
3
  display: flex;
4
4
  justify-content: flex-end;
5
5
  `,Ka=i(ja)`
@@ -34,7 +34,7 @@ import{X as Nn,t as On,u as Fn,fI as En,fJ as Ln,fK as Wn,fL as _n,aV as Zn,a1 a
34
34
  &:hover {
35
35
  color: ${e=>e.theme.colors.primary};
36
36
  }
37
- `,Ya=i.div`
37
+ `,qa=i.div`
38
38
  display: flex;
39
39
  cursor: pointer;
40
40
  color: ${e=>e.theme.colors.grey1};
@@ -71,7 +71,7 @@ import{X as Nn,t as On,u as Fn,fI as En,fJ as Ln,fK as Wn,fL as _n,aV as Zn,a1 a
71
71
  right: ${e=>m.actionsContainerRight.valuePx(e.windowSize)};
72
72
  height: 100%;
73
73
  display: flex;
74
- `,_=i(Mt)`
74
+ `,W=i(Mt)`
75
75
  display: flex;
76
76
  align-items: center;
77
77
  width: 100%;
@@ -113,7 +113,7 @@ import{X as Nn,t as On,u as Fn,fI as En,fJ as Ln,fK as Wn,fL as _n,aV as Zn,a1 a
113
113
  width: ${a.sp4};
114
114
  height: ${a.sp4};
115
115
  display: flex;
116
- `,qa=i.div`
116
+ `,Ya=i.div`
117
117
  height: 100%;
118
118
  overflow: scroll;
119
119
  `,De=i.div`
@@ -1,4 +1,4 @@
1
- import{C as z,p as B,X as q,M as R,a as M,a1 as W,j as o,R as G,c2 as X,aW as Y,F as H,a3 as J,o as c}from"./index-C5RQ_I4f.js";import{b as D,n as h}from"./vendor-CnQcJ2Lu.js";import{b as K,f as Q,l as L,o as j}from"./FollowStepsSection-CIOJXyXO-Ck9BhOv7.js";import"./mui-C5LQ0bMa.js";import"./analytics-DThoELaW.js";import"./routing-Cpaypegg.js";import"./sentry-HDxG13yk.js";import"./redux-ByjIRbhZ.js";import"./liveblocks-sSQ9JElv.js";import"./crypto-BURQLTgV.js";const C="billPayApprovalRuleDetailPage",E="lowerBound",T="upperBound",y="steps",Z={footerPadding:new z(B[2],B[3])};function ve({localData:e,approvalUpdateActionType:t,onBackClick:l,onApprovalRuleDataUpdated:r,onResetClick:s,isLowerBoundDisabled:n=!1,isUpperBoundDisabled:b=!0,hideUpperBoundField:A=!1,onSaveRuleClick:_,onSaveRuleSuccess:S}){const I=q(),a=R.getLocalizedStrings().commonSetUp.approval,P=R.getLocalizedStrings().spendManagement.billPay.billPayApproval,x=ee(e,t==="approval_create"&&!n),v=M({mode:"all",reValidateMode:"onChange",defaultValues:x}),u=e.billPaySetupApproverViewUpdateData?.updateStatus,w=W(u?.fetchState),{upperBound:$}=x,{allApprovalRules:p,allAccountingClasses:k,billPaySetupApproverViewUpdateData:m}=e;let f=p.length>1?p.length-1:0,g=p.length>0?p[f].criteria[0].range.min.amount:0;if(m!=null&&m.type==="approval_update"&&m.data!=null){const{approvalRuleId:i}=m.data;f=p.findIndex(d=>d.approvalRuleId===i),g=f>0?p[f-1].criteria[0].range.min.amount:0}const F=v.handleSubmit(()=>{_()}),O=async(i,d)=>{r(d)};return D.useEffect(()=>{const i=v.watch((d,{name:U})=>{if(U!=null&&d!=null){const V=G(d);X(()=>O(U,V))}});return()=>{i.unsubscribe()}}),D.useEffect(()=>{w==="In-Progress"&&u?.fetchState==="Completed"&&S()},[w,u?.fetchState,S]),o.jsxs(re,{children:[o.jsx(Y,{title:t==="approval_create"?a.newApproval:a.editApproval,style:{zIndex:4},onBackClick:()=>{l()},source:"BillPayApprovalRuleDetailPage"}),o.jsx(se,{children:o.jsx(H,{...v,children:o.jsx("form",{id:N(C),onSubmit:F,children:o.jsxs(oe,{children:[o.jsx(K,{label:{label:A?P.amountPerBillGreaterLabel:P.amountPerBillLabel},firstText:{type:"number",name:E,placeholder:"$0",options:{required:!0,max:$===1/0?Number.MAX_SAFE_INTEGER-1:$-1,min:g,validate:i=>n?!0:i!=null&&i>g},isDisabled:n,additionalInfoLabel:a.firstRuleLowerBoundInfoLabel,additionalErrorLabel:a.firstRuleErrorInfoLabel},secondText:{type:"number",name:T,placeholder:"Infinity",isDisabled:b,hideField:A,additionalInfoLabel:a.upperBoundInfoLabel}}),o.jsx(ie,{}),o.jsx(Q,{sectionId:y,label:{label:a.followStepsLabel},approversPlaceholder:a.approversPlaceholder,notifiersPlaceholder:a.notifiersPlaceholder,allUserWithRoles:e.allApprovers,filteredApprovers:e.filteredApprovers.map(i=>i.user),allAttributes:e.allAttributes,filteredAttributes:e.filteredAttributes,allAccountingClasses:k,stepsInfo:x[y],userSelectPlaceholder:a.userSelectPlaceholder,approveNotifyPlaceholder:a.approveNotifyPlaceholder,productType:"zeni_bill_pay"})]})})})}),o.jsx(J,{formId:N(C),primaryBtn:{label:a.saveBtnText,isLoading:u?.fetchState==="In-Progress",isDisabled:u?.fetchState==="In-Progress",style:{width:"85px",minWidth:"auto"}},showCancel:!0,cancelBtn:{label:a.cancelBtnText,isLoading:!1,style:{width:"85px",minWidth:"auto"},onClick:s},containerStyle:{justifyContent:I==="small"?"space-between":"center"},style:{padding:Z.footerPadding.valuePx(I)},separatorStyle:{marginRight:c.sp4}})]})}const ee=(e,t)=>{const{criteria:l,steps:r}=e.billPaySetupApproverViewUpdateData?.data??{};return{[y]:le(e.allApprovers.map(s=>s.user),e.filteredApprovers.map(s=>s.user),j(e.allAttributes),j(e.filteredAttributes),r??[])??[],[E]:t?void 0:l!=null?l.range.min.amount??0:0,[T]:l!=null?l.range.max==null?1/0:l.range.max.amount:1/0}},le=(e,t,l,r,s)=>s&&s.length>0?s.map((n,b)=>({stepIndex:b,stepType:{selectedOption:n.action,allOptions:L},actors:{allUsers:t,selectedUsers:ae(e,n.actors),allNonUsers:r,selectedNonUsers:te(l,n.actors)}})):[{stepIndex:0,stepType:{selectedOption:"require_approval",allOptions:L},actors:{allUsers:t,selectedUsers:[],allNonUsers:r,selectedNonUsers:[]}}],ae=(e,t)=>e.filter(l=>l.userId!=null&&t.findIndex(r=>r.userId===l.userId)>-1),te=(e,t)=>e.filter(l=>t.findIndex(r=>r.subType===l.value)>-1),N=e=>`${e}_form`,ge=e=>`${e}`,re=h.div`
1
+ import{C as z,p as $,X as q,M as D,a as M,a5 as W,j as o,U as G,c3 as X,aW as Z,F as H,a7 as J,o as c}from"./index-C0q2xQ43.js";import{b as L,n as h}from"./vendor-CnQcJ2Lu.js";import{b as K,f as Q,l as R,o as j}from"./FollowStepsSection-DuElPK3y-BQRSekz2.js";import"./mui-BgvZYSo0.js";import"./analytics-BSSiLa6f.js";import"./routing-BNz5gZgX.js";import"./sentry-HDxG13yk.js";import"./redux-DmDqXYej.js";import"./liveblocks-BUGn2yQ6.js";import"./crypto-BURQLTgV.js";const C="billPayApprovalRuleDetailPage",T="lowerBound",E="upperBound",y="steps",Y={footerPadding:new z($[2],$[3])};function ve({localData:e,approvalUpdateActionType:t,onBackClick:l,onApprovalRuleDataUpdated:r,onResetClick:s,isLowerBoundDisabled:n=!1,isUpperBoundDisabled:b=!0,hideUpperBoundField:A=!1,onSaveRuleClick:_,onSaveRuleSuccess:S}){const I=q(),a=D.getLocalizedStrings().commonSetUp.approval,P=D.getLocalizedStrings().spendManagement.billPay.billPayApproval,x=ee(e,t==="approval_create"&&!n),v=M({mode:"all",reValidateMode:"onChange",defaultValues:x}),u=e.billPaySetupApproverViewUpdateData?.updateStatus,w=W(u?.fetchState),{upperBound:B}=x,{allApprovalRules:p,allAccountingClasses:k,billPaySetupApproverViewUpdateData:m}=e;let f=p.length>1?p.length-1:0,g=p.length>0?p[f].criteria[0].range.min.amount:0;if(m!=null&&m.type==="approval_update"&&m.data!=null){const{approvalRuleId:i}=m.data;f=p.findIndex(d=>d.approvalRuleId===i),g=f>0?p[f-1].criteria[0].range.min.amount:0}const F=v.handleSubmit(()=>{_()}),O=async(i,d)=>{r(d)};return L.useEffect(()=>{const i=v.watch((d,{name:U})=>{if(U!=null&&d!=null){const V=G(d);X(()=>O(U,V))}});return()=>{i.unsubscribe()}}),L.useEffect(()=>{w==="In-Progress"&&u?.fetchState==="Completed"&&S()},[w,u?.fetchState,S]),o.jsxs(re,{children:[o.jsx(Z,{title:t==="approval_create"?a.newApproval:a.editApproval,style:{zIndex:4},onBackClick:()=>{l()},source:"BillPayApprovalRuleDetailPage"}),o.jsx(se,{children:o.jsx(H,{...v,children:o.jsx("form",{id:N(C),onSubmit:F,children:o.jsxs(oe,{children:[o.jsx(K,{label:{label:A?P.amountPerBillGreaterLabel:P.amountPerBillLabel},firstText:{type:"number",name:T,placeholder:"$0",options:{required:!0,max:B===1/0?Number.MAX_SAFE_INTEGER-1:B-1,min:g,validate:i=>n?!0:i!=null&&i>g},isDisabled:n,additionalInfoLabel:a.firstRuleLowerBoundInfoLabel,additionalErrorLabel:a.firstRuleErrorInfoLabel},secondText:{type:"number",name:E,placeholder:"Infinity",isDisabled:b,hideField:A,additionalInfoLabel:a.upperBoundInfoLabel}}),o.jsx(ie,{}),o.jsx(Q,{sectionId:y,label:{label:a.followStepsLabel},approversPlaceholder:a.approversPlaceholder,notifiersPlaceholder:a.notifiersPlaceholder,allUserWithRoles:e.allApprovers,filteredApprovers:e.filteredApprovers.map(i=>i.user),allAttributes:e.allAttributes,filteredAttributes:e.filteredAttributes,allAccountingClasses:k,stepsInfo:x[y],userSelectPlaceholder:a.userSelectPlaceholder,approveNotifyPlaceholder:a.approveNotifyPlaceholder,productType:"zeni_bill_pay"})]})})})}),o.jsx(J,{formId:N(C),primaryBtn:{label:a.saveBtnText,isLoading:u?.fetchState==="In-Progress",isDisabled:u?.fetchState==="In-Progress",style:{width:"85px",minWidth:"auto"}},showCancel:!0,cancelBtn:{label:a.cancelBtnText,isLoading:!1,style:{width:"85px",minWidth:"auto"},onClick:s},containerStyle:{justifyContent:I==="small"?"space-between":"center"},style:{padding:Y.footerPadding.valuePx(I)},separatorStyle:{marginRight:c.sp4}})]})}const ee=(e,t)=>{const{criteria:l,steps:r}=e.billPaySetupApproverViewUpdateData?.data??{};return{[y]:le(e.allApprovers.map(s=>s.user),e.filteredApprovers.map(s=>s.user),j(e.allAttributes),j(e.filteredAttributes),r??[])??[],[T]:t?void 0:l!=null?l.range.min.amount??0:0,[E]:l!=null?l.range.max==null?1/0:l.range.max.amount:1/0}},le=(e,t,l,r,s)=>s&&s.length>0?s.map((n,b)=>({stepIndex:b,stepType:{selectedOption:n.action,allOptions:R},actors:{allUsers:t,selectedUsers:ae(e,n.actors),allNonUsers:r,selectedNonUsers:te(l,n.actors)}})):[{stepIndex:0,stepType:{selectedOption:"require_approval",allOptions:R},actors:{allUsers:t,selectedUsers:[],allNonUsers:r,selectedNonUsers:[]}}],ae=(e,t)=>e.filter(l=>l.userId!=null&&t.findIndex(r=>r.userId===l.userId)>-1),te=(e,t)=>e.filter(l=>t.findIndex(r=>r.subType===l.value)>-1),N=e=>`${e}_form`,ge=e=>`${e}`,re=h.div`
2
2
  display: flex;
3
3
  height: 100%;
4
4
  flex-direction: column;
@@ -24,4 +24,4 @@ import{C as z,p as B,X as q,M as R,a as M,a1 as W,j as o,R as G,c2 as X,aW as Y,
24
24
  background-color: ${e=>e.theme.colors.grey3};
25
25
  min-height: 1px;
26
26
  max-height: 1px;
27
- `;export{Z as D,ve as default,N as uniqueFormName,ge as uniqueName};
27
+ `;export{Y as D,ve as default,N as uniqueFormName,ge as uniqueName};
@@ -1,4 +1,4 @@
1
- import{X as I,M as y,j as t,aW as D,d as H,Y as b,C as r,q as B,_ as j,bM as E,bO as U,bP as q,o as i,cp as G,p as l,an as O,Q as z,am as V,g as S,cm as X,aN as Y,v as _}from"./index-C5RQ_I4f.js";import{n as o,b as F}from"./vendor-CnQcJ2Lu.js";import"./mui-C5LQ0bMa.js";import"./analytics-DThoELaW.js";import"./routing-Cpaypegg.js";import"./sentry-HDxG13yk.js";import"./redux-ByjIRbhZ.js";import"./liveblocks-sSQ9JElv.js";import"./crypto-BURQLTgV.js";const s={sectionWidth:new r(343,580,726),ruleWrapperPadding:new r(l[3],l[4]),wrapperGap:new r(l[4],l[3]),wrapperMarginBottom:new r(l[6],l[8]),lastWrapperMarginBottom:new r(l[5],l[9]),stepperWidthHeight:new r(20,l[5]),stepperItemLeft:new r(-29,-23),stepperItemTop:new r(2,l[0]),stepperItemPaddingLeft:new r(l[0],10),stepperItemMinHeight:new r(22,28),stepperLeft:new r(11,17),stepperTop:new r(2,l[0]),stepperContentTop:new r(-1,-4)},L={stepper:new z("smallRegular","standardRegular"),amount:new z("standardRegular","largeMedium")},Q=({showDeleteBtn:e=!1,isLastSection:f=!1,approvalRule:c,onEditRuleClick:v,onDeleteRuleClick:$})=>{const[m,x]=F.useState(!1),n=I(),{range:h}=c.criteria[0],{steps:u,approvalRuleId:w}=c,a=y.getLocalizedStrings().commonSetUp.approval,W=()=>{x(!0)},A={onOkClick:()=>{x(!1),$?.(w)},onCancelClick:()=>{x(!1)}};return t.jsxs(J,{windowSize:n,isLastSection:f,children:[t.jsxs(K,{windowSize:n,children:[t.jsxs(se,{children:[t.jsxs(R,{windowSize:n,children:[a.from," ",j("0,0",h.min)]}),t.jsxs(Z,{children:[t.jsx(P,{}),t.jsx(ee,{}),t.jsx(P,{})]}),h.max==null?t.jsx(de,{}):t.jsx(R,{windowSize:n,children:j("0,0",{...h.min,amount:h.max.amount})})]}),t.jsxs(ae,{className:"icons",children:[e&&t.jsx(ne,{onClick:W,"data-testid":b("delete-approval-rule-bill-pay",c.approvalRuleId)}),t.jsx(pe,{onClick:()=>{v(w)},"data-testid":b("edit-approval-rule-bill-pay",c.approvalRuleId)})]})]}),t.jsx(te,{windowSize:n,children:t.jsx(oe,{isSingleStep:u.length===1,windowSize:n,children:u.map((d,M)=>t.jsxs(ie,{isSingleStep:u.length===1,className:"stepperItem",windowSize:n,children:[d.action==="require_approval"?t.jsx(re,{children:a.requireText}):t.jsx(le,{children:a.notifyText}),d.nonUserActors!=null&&d.nonUserActors.filter(p=>p.subType!=null).map((p,N)=>t.jsxs(C,{children:[t.jsx(k,{children:p.subType!=null?a.nonUsers[p.subType].label:null}),d.operator!="is"?t.jsx(T,{className:"operator",children:d.operator}):null]},`${p.subType}_${N}`)),d.actors.map(p=>t.jsxs(C,{children:[t.jsxs(k,{children:[p.firstName," ",p.lastName]}),d.operator!="is"?t.jsx(T,{className:"operator",children:d.operator}):null]},p.userId))]},M))})}),m?t.jsx(E,{titleComponent:t.jsx(q,{children:a.deleteApprovalRuleTitle}),descriptionComponent:t.jsx(U,{children:a.deleteApprovalRuleDesc}),primaryButtonText:a.deleteTxt,proceedButtonVariant:"danger",secondaryButtonText:a.cancelBtnText,action:A}):null]})},J=o.div`
1
+ import{X as I,M as y,j as t,aW as D,d as H,Y as b,C as r,s as B,_ as j,bN as E,bP as q,bQ as U,o as i,cq as G,p as l,as as Q,Q as z,ar as V,g as S,cn as X,aN as Y,q as _}from"./index-C0q2xQ43.js";import{n as o,b as F}from"./vendor-CnQcJ2Lu.js";import"./mui-BgvZYSo0.js";import"./analytics-BSSiLa6f.js";import"./routing-BNz5gZgX.js";import"./sentry-HDxG13yk.js";import"./redux-DmDqXYej.js";import"./liveblocks-BUGn2yQ6.js";import"./crypto-BURQLTgV.js";const s={sectionWidth:new r(343,580,726),ruleWrapperPadding:new r(l[3],l[4]),wrapperGap:new r(l[4],l[3]),wrapperMarginBottom:new r(l[6],l[8]),lastWrapperMarginBottom:new r(l[5],l[9]),stepperWidthHeight:new r(20,l[5]),stepperItemLeft:new r(-29,-23),stepperItemTop:new r(2,l[0]),stepperItemPaddingLeft:new r(l[0],10),stepperItemMinHeight:new r(22,28),stepperLeft:new r(11,17),stepperTop:new r(2,l[0]),stepperContentTop:new r(-1,-4)},L={stepper:new z("smallRegular","standardRegular"),amount:new z("standardRegular","largeMedium")},O=({showDeleteBtn:e=!1,isLastSection:f=!1,approvalRule:c,onEditRuleClick:v,onDeleteRuleClick:$})=>{const[m,x]=F.useState(!1),n=I(),{range:h}=c.criteria[0],{steps:u,approvalRuleId:w}=c,a=y.getLocalizedStrings().commonSetUp.approval,W=()=>{x(!0)},A={onOkClick:()=>{x(!1),$?.(w)},onCancelClick:()=>{x(!1)}};return t.jsxs(J,{windowSize:n,isLastSection:f,children:[t.jsxs(K,{windowSize:n,children:[t.jsxs(se,{children:[t.jsxs(R,{windowSize:n,children:[a.from," ",j("0,0",h.min)]}),t.jsxs(Z,{children:[t.jsx(P,{}),t.jsx(ee,{}),t.jsx(P,{})]}),h.max==null?t.jsx(de,{}):t.jsx(R,{windowSize:n,children:j("0,0",{...h.min,amount:h.max.amount})})]}),t.jsxs(ae,{className:"icons",children:[e&&t.jsx(ne,{onClick:W,"data-testid":b("delete-approval-rule-bill-pay",c.approvalRuleId)}),t.jsx(pe,{onClick:()=>{v(w)},"data-testid":b("edit-approval-rule-bill-pay",c.approvalRuleId)})]})]}),t.jsx(te,{windowSize:n,children:t.jsx(oe,{isSingleStep:u.length===1,windowSize:n,children:u.map((d,N)=>t.jsxs(ie,{isSingleStep:u.length===1,className:"stepperItem",windowSize:n,children:[d.action==="require_approval"?t.jsx(re,{children:a.requireText}):t.jsx(le,{children:a.notifyText}),d.nonUserActors!=null&&d.nonUserActors.filter(p=>p.subType!=null).map((p,M)=>t.jsxs(C,{children:[t.jsx(k,{children:p.subType!=null?a.nonUsers[p.subType].label:null}),d.operator!="is"?t.jsx(T,{className:"operator",children:d.operator}):null]},`${p.subType}_${M}`)),d.actors.map(p=>t.jsxs(C,{children:[t.jsxs(k,{children:[p.firstName," ",p.lastName]}),d.operator!="is"?t.jsx(T,{className:"operator",children:d.operator}):null]},p.userId))]},N))})}),m?t.jsx(E,{titleComponent:t.jsx(U,{children:a.deleteApprovalRuleTitle}),descriptionComponent:t.jsx(q,{children:a.deleteApprovalRuleDesc}),primaryButtonText:a.deleteTxt,proceedButtonVariant:"danger",secondaryButtonText:a.cancelBtnText,action:A}):null]})},J=o.div`
2
2
  display: flex;
3
3
  flex-direction: column;
4
4
  gap: ${e=>s.wrapperGap.valuePx(e.windowSize)};
@@ -14,7 +14,7 @@ import{X as I,M as y,j as t,aW as D,d as H,Y as b,C as r,q as B,_ as j,bM as E,b
14
14
  border-color: ${e=>e.theme.colors.primary};
15
15
  }
16
16
  }
17
- `,K=o(O)`
17
+ `,K=o(Q)`
18
18
  display: flex;
19
19
  position: relative;
20
20
  align-items: center;
@@ -170,7 +170,7 @@ import{X as I,M as y,j as t,aW as D,d as H,Y as b,C as r,q as B,_ as j,bM as E,b
170
170
  ${e=>`${L.amount.style(e.windowSize)}`};
171
171
  color: ${e=>e.theme.colors.primary};
172
172
  word-break: break-word;
173
- `,g={width:new r(343,580,726),titleWidth:new r(343,580,780),addApprovalGap:new r(6,l[2]),subTitlePaddingTop:new r(12,l[3]),subTitlePaddingBottom:new r(28,l[7])},ke=({approvalView:e,onBackClick:f,onEditRuleClick:c,onDeleteRuleClick:v})=>{const $=I(),{fetchState:m,deleteStatus:x}=e,n=y.getLocalizedStrings().commonSetUp.approval,h=y.getLocalizedStrings().spendManagement.billPay.billPayApproval,u=x.fetchState;return t.jsxs(ce,{children:[t.jsx(D,{title:n.approvalPageHeader,style:{zIndex:4},onBackClick:()=>{f()},source:"BillPayApprovalRulesPage"}),t.jsxs(he,{children:[t.jsx(xe,{windowSize:$,children:h.approvalPageSubTitle}),m==="In-Progress"||m==="Not-Started"||u==="In-Progress"?t.jsx(me,{children:t.jsx(H,{size:"ExtraLarge",start:!0})}):m==="Completed"?t.jsxs(t.Fragment,{children:[e.allApprovalRules.map((w,a)=>t.jsx(Q,{showDeleteBtn:a!==0,approvalRule:w,isLastSection:a===e.allApprovalRules.length-1,onEditRuleClick:c,onDeleteRuleClick:v},w.approvalRuleId)),t.jsxs(ue,{windowSize:$,onClick:()=>{c()},"data-testid":b("add-approval-rule-bill-pay"),children:[t.jsx(we,{}),t.jsx(ge,{children:n.addApprovalText})]})]}):null]})]})},ce=o.div`
173
+ `,g={width:new r(343,580,726),titleWidth:new r(343,580,780),addApprovalGap:new r(6,l[2]),subTitlePaddingTop:new r(12,l[3]),subTitlePaddingBottom:new r(28,l[7])},ke=({approvalView:e,onBackClick:f,onEditRuleClick:c,onDeleteRuleClick:v})=>{const $=I(),{fetchState:m,deleteStatus:x}=e,n=y.getLocalizedStrings().commonSetUp.approval,h=y.getLocalizedStrings().spendManagement.billPay.billPayApproval,u=x.fetchState;return t.jsxs(ce,{children:[t.jsx(D,{title:n.approvalPageHeader,style:{zIndex:4},onBackClick:()=>{f()},source:"BillPayApprovalRulesPage"}),t.jsxs(he,{children:[t.jsx(xe,{windowSize:$,children:h.approvalPageSubTitle}),m==="In-Progress"||m==="Not-Started"||u==="In-Progress"?t.jsx(me,{children:t.jsx(H,{size:"ExtraLarge",start:!0})}):m==="Completed"?t.jsxs(t.Fragment,{children:[e.allApprovalRules.map((w,a)=>t.jsx(O,{showDeleteBtn:a!==0,approvalRule:w,isLastSection:a===e.allApprovalRules.length-1,onEditRuleClick:c,onDeleteRuleClick:v},w.approvalRuleId)),t.jsxs(ue,{windowSize:$,onClick:()=>{c()},"data-testid":b("add-approval-rule-bill-pay"),children:[t.jsx(we,{}),t.jsx(ge,{children:n.addApprovalText})]})]}):null]})]})},ce=o.div`
174
174
  display: flex;
175
175
  min-height: 100%;
176
176
  flex-direction: column;