@zeniai/web-cockpit-ui 1.14.71-dev → 1.14.72-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 (226) hide show
  1. package/dist/assets/{ACHDetailsPage-B40ur5bp-qLUbcavz.js → ACHDetailsPage-BZFkcCOG-Bm0yzLzS.js} +1 -1
  2. package/dist/assets/{AIPerformancePage-3KzgwQEg-Car9ubk8.js → AIPerformancePage-DtNLjoUW-C8WssBlV.js} +1 -1
  3. package/dist/assets/{AccountInfoPage-vLCfulj4-z4VKkvZc.js → AccountInfoPage-D-E_-WpE-D3xkesKo.js} +1 -1
  4. package/dist/assets/{AccountInfoPageContent-C0kb83_4-BAkZvdVH.js → AccountInfoPageContent-B8GKrtCm-Bl_GPEk1.js} +1 -1
  5. package/dist/assets/{AccountLockedInfoModal-DqWq-DtD-BcxpOdhH.js → AccountLockedInfoModal-BD7Nb81U-CexK1k9m.js} +1 -1
  6. package/dist/assets/{AccountReconDetailsDrawerPage-C1-aZ2IL-Ck9_GjU2.js → AccountReconDetailsDrawerPage-D-_ME0pV-s74oVSdU.js} +1 -1
  7. package/dist/assets/{AccountRow-C9q6i3az-Dw8PGRm0.js → AccountRow-Be3LIHO--AtWCxnkE.js} +1 -1
  8. package/dist/assets/{AccountsPromoCardStack-CcKxTC_P-C--n47Gr.js → AccountsPromoCardStack-CdBwPVgI-0eZTGbZE.js} +1 -1
  9. package/dist/assets/{AddAddressForCardDrawer-CgFUm8yP-CrKB_Dwv.js → AddAddressForCardDrawer-Lm7cn4kq-BwSuj-eK.js} +1 -1
  10. package/dist/assets/{AddToWalletPage-CcGENV5h-UoiarLil.js → AddToWalletPage-nSq-9dQy-DNXeo8yV.js} +1 -1
  11. package/dist/assets/{AgingReportsPage-B24eKpNK-DYSYO6T8.js → AgingReportsPage-L0zQxwCf-BGxthXxn.js} +1 -1
  12. package/dist/assets/{AllUserItems-D_8QwwoX-CJcv0jgE.js → AllUserItems-CvwaOEhu-4FgiUHmj.js} +1 -1
  13. package/dist/assets/{ApAgingDetailPage-CkjF2eck-CUC_Mtgo.js → ApAgingDetailPage-B_78aSEv-BIkW3as9.js} +1 -1
  14. package/dist/assets/{AppBasePage-BKLe2VqM-MW0rA3r6.js → AppBasePage-Br0WbQRY-C5P2SI_a.js} +1 -1
  15. package/dist/assets/{AppDrawerContent-amGpNlZr-DzZHETAi.js → AppDrawerContent-BZODvVvi-DO9-i0u3.js} +1 -1
  16. package/dist/assets/{ApprovalRulesSettingsPage-D42YDnFU-CNrvwDLo.js → ApprovalRulesSettingsPage-Dxd7A3hZ-B57JU70m.js} +1 -1
  17. package/dist/assets/{ArAgingChart-qZaIsWtq-BZLaZ9Ct.js → ArAgingChart-BezVy1Sm-UplSlTlX.js} +1 -1
  18. package/dist/assets/{ArAgingDetailPage-CHCdWveg-vZj7uIx-.js → ArAgingDetailPage-BlV3iJeW-DvSoM4Rd.js} +1 -1
  19. package/dist/assets/{AttachmentView-DZCtCZK_-BwikHNAT.js → AttachmentView-DhluaeAV-DnrJUkr5.js} +1 -1
  20. package/dist/assets/{BankAccountSection-BroWfNc_-CvTo199_.js → BankAccountSection-GDEQdiGL-CuwfGvXF.js} +1 -1
  21. package/dist/assets/{BankAccountWarningSection-lNbSkw5--D5G2vsMX.js → BankAccountWarningSection-Di_BsiJC-Cp36wJhl.js} +1 -1
  22. package/dist/assets/{BankConnectionsSettingsPage-BG5FAR53-DZr6wEfX.js → BankConnectionsSettingsPage-D5hI4xtm-CIHmOttI.js} +1 -1
  23. package/dist/assets/{BillDetailPage-BNlsd0AF-BFTUTyDQ.js → BillDetailPage-CDAh8Jtl-0qBbZ__0.js} +1 -1
  24. package/dist/assets/{BillPayApprovalRuleDetailPage-Br6UCYrF-D0uLNJ76.js → BillPayApprovalRuleDetailPage-BzyTn4mC-DYCBn6RW.js} +1 -1
  25. package/dist/assets/{BillPayApprovalRulesPage-DL0aveSN-DoAtCpfR.js → BillPayApprovalRulesPage-DDJ-LxQz-D20J03DB.js} +1 -1
  26. package/dist/assets/{BillPayPromoPage-DLMTqP9B-Qdj_ZRax.js → BillPayPromoPage-B2YcxWc9-CwLnyiow.js} +1 -1
  27. package/dist/assets/{BillPaySetUpPage-7Z5WhvCj-DUMDnm--.js → BillPaySetUpPage-oJvoWpFu-CYkgRBSH.js} +1 -1
  28. package/dist/assets/{BillingSettingsPage-HsRQLM6k-wTKAVFEO.js → BillingSettingsPage-BRsKYzT5-gKM6YCmc.js} +1 -1
  29. package/dist/assets/{BillsBulkReviewDrawerPage-CZEdLC67-B02pvysO.js → BillsBulkReviewDrawerPage-B7tORIok-Cjhni78W.js} +1 -1
  30. package/dist/assets/{BoxItem-CvQS_sLm-D_wBZcaU.js → BoxItem-COIjjFrn-DqU4ZyNU.js} +1 -1
  31. package/dist/assets/{BusinessVerificationPage-BQ3ZYVyp-Cnlr3LEP.js → BusinessVerificationPage-Nw_fedst-D0V3bhmc.js} +1 -1
  32. package/dist/assets/{CardNumberSubText-DVfY641B-Ca4CUToE.js → CardNumberSubText-CmhH95Ff-CLBGKyAX.js} +1 -1
  33. package/dist/assets/{CashbackDetailPage-Bq-wjfJM-D2Niv1Ey.js → CashbackDetailPage-BPLjvuA3-362WFi2j.js} +1 -1
  34. package/dist/assets/{ChargeCardDetailPage-BBksBgc_-CunwAXKE.js → ChargeCardDetailPage-qOu4cPGd-BUoeKuHJ.js} +1 -1
  35. package/dist/assets/{ChargeCardListPage-D8LM_cZf-BYxkaOMa.js → ChargeCardListPage-v5hH98Wi-D_Ffaz0x.js} +1 -1
  36. package/dist/assets/{ChargeCardListTable-Cstar82M-BZIvTdeq.js → ChargeCardListTable-BGWV4zJl-fPTlw7hA.js} +1 -1
  37. package/dist/assets/{ChargeCardPromoPage-DMAUyVe7-UqwVvfTW.js → ChargeCardPromoPage-CPEaGOL3-BJBmWN7Q.js} +1 -1
  38. package/dist/assets/{ChargeCardSetupPage-xuPp_o4--VeJFY_V2.js → ChargeCardSetupPage-G5Rn0o6y-DXJQIwPQ.js} +1 -1
  39. package/dist/assets/{ChargeCardStatementsPage-BtEC80N4-CLyMpzOI.js → ChargeCardStatementsPage-CJgUrcLz-BpTcE_Fq.js} +1 -1
  40. package/dist/assets/{ChargeCardUtils-CHhHodZN-6DoofQsj.js → ChargeCardUtils-BRgkrCTs-DoVoCmwL.js} +1 -1
  41. package/dist/assets/{ChaseOverlay-laPjyJU7-DF7Or1ye.js → ChaseOverlay-BC_4vwtb-ZJ37WP7g.js} +1 -1
  42. package/dist/assets/{CheckDepositDrawerPage-Cg3R57ad-x4vbhtLo.js → CheckDepositDrawerPage-CDo5E13X-BcLnzbHC.js} +1 -1
  43. package/dist/assets/{CollapsableReportTable-BTquJgcd-BW5UxAeQ.js → CollapsableReportTable-7iAngywY-CxWB4sRz.js} +1 -1
  44. package/dist/assets/{CompanyOfficerDetailsSection-BpiZ5rDk-DPn4GdQZ.js → CompanyOfficerDetailsSection-CJKyxEnf-BshC7d2B.js} +1 -1
  45. package/dist/assets/{CompanyPassportCard-BV9mPVRb-Q4C_0Loc.js → CompanyPassportCard-D3F01eJL-CYg3XwZh.js} +1 -1
  46. package/dist/assets/{CompanyPassportPage-D5tRbHXG-CLVMqmrR.js → CompanyPassportPage-BQoEcPJr-DzLqV-NZ.js} +1 -1
  47. package/dist/assets/{CompleteProfile-CARUXqXR-C7CBy6gL.js → CompleteProfile-D5e9TQgy-ppOK1lFi.js} +1 -1
  48. package/dist/assets/{ConfettiBurst-CPnRASxV-Cf8S2srw.js → ConfettiBurst--HIHB7Os-CFkZhGnX.js} +1 -1
  49. package/dist/assets/{CreateOrEditVendorPage-BnMzZWIJ-Dtcizi2x.js → CreateOrEditVendorPage-D9jmSrKr-BqbzMjKm.js} +1 -1
  50. package/dist/assets/{CreditCardPaymentDrawerPage-ZGFxbf6p-CEB_tt9p.js → CreditCardPaymentDrawerPage-DXeq4z9l-Dr585X5v.js} +1 -1
  51. package/dist/assets/{CreditCardPaymentPlgSection-CfIXTZi1-BWmvJdS4.js → CreditCardPaymentPlgSection-8ZShMO31-D_nbIzHo.js} +1 -1
  52. package/dist/assets/{CurrencySelectField-D5qstOV_-BfQhwVcO.js → CurrencySelectField-nhg_dhDw-Ct_sJsLw.js} +1 -1
  53. package/dist/assets/{CustomerOnboardingActivationPage-EoS5UWcr-BDzCJZJq.js → CustomerOnboardingActivationPage-CoGvz7Kd-2HboMU2B.js} +1 -1
  54. package/dist/assets/CustomerOnboardingContainerPage-CZRkKPDD-4OaWohod.js +1 -0
  55. package/dist/assets/{CustomerOnboardingDetailPageSkeleton-CATcejsu-h_QqrMWP.js → CustomerOnboardingDetailPageSkeleton-DUGRKWtN-Bm0dGA9J.js} +1 -1
  56. package/dist/assets/{CustomerOnboardingNoStepsPage-DhXSZZDt-BhNth72s.js → CustomerOnboardingNoStepsPage-Cc5frP29-BNFSu_0c.js} +1 -1
  57. package/dist/assets/{CustomerOnboardingPage-Dw4jho3E-BiCBI5MF.js → CustomerOnboardingPage-zBqp9QN6-D_UHEoUt.js} +1 -1
  58. package/dist/assets/{CustomerOnboardingProductSuitePage-BrcfWdR_-CxuJiBMx.js → CustomerOnboardingProductSuitePage-BbJ4oiCI-C_0KKlnp.js} +1 -1
  59. package/dist/assets/{Dashboard-Dncu8Llu-CNokCy8K.js → Dashboard-D6Ba5oj0-DGZ5Ekyf.js} +1 -1
  60. package/dist/assets/{DashboardReportPage-Cd2aI286-D3ivv6JU.js → DashboardReportPage-DTMbYOWH-CSMllwg6.js} +1 -1
  61. package/dist/assets/{DashboardSidebarBackgroundAnimation-Bsd2tllR-Cs2-dBQO.js → DashboardSidebarBackgroundAnimation-Locz2zHR-BPk9MxB4.js} +1 -1
  62. package/dist/assets/{DepositAccTransactionItem-BCvM718U-BQ7X3anC.js → DepositAccTransactionItem-B0BGwVqF-CxL2uxQm.js} +1 -1
  63. package/dist/assets/{DepositAccTransactionListPage-BV0C4uw5-D3ujml3L.js → DepositAccTransactionListPage-CcO673ZL-CiLAoQqZ.js} +1 -1
  64. package/dist/assets/{DomesticWireDetailsPage-C7YCWnpX-BJhnsPOT.js → DomesticWireDetailsPage-D5hbPNCt-Bj16Fg_f.js} +1 -1
  65. package/dist/assets/{DownloadOverlay-XFeHlPT1-CEQi5sme.js → DownloadOverlay-DRcasKoB-BDQCkt6Q.js} +1 -1
  66. package/dist/assets/{DrawerPage-B5swtpnW-ExQw__-M.js → DrawerPage-BRD6cE6J-CdG9rNJx.js} +1 -1
  67. package/dist/assets/{EditPeoplePage-gSBB6VWT-C32EYjas.js → EditPeoplePage-Zzo62if7-CQfgpQsa.js} +1 -1
  68. package/dist/assets/{EditReimbursementDetailPage-wgieh-cS-u2wJ_U8V.js → EditReimbursementDetailPage-D59OJdZ1-7T5j9Uz8.js} +1 -1
  69. package/dist/assets/{EntityDetailPage-wDSbBdas-CScHSqtE.js → EntityDetailPage-CzlzOW8n-DjZ6eItY.js} +1 -1
  70. package/dist/assets/{EntitySummarySection-DUkLpeab-jp4lR-ND.js → EntitySummarySection-BRt1kPDf-BrvMzC_z.js} +1 -1
  71. package/dist/assets/{ExpenseAutomationOverviewPage-8Kor6jbw-C1EEcWSe.js → ExpenseAutomationOverviewPage-vUkGameq-D28DcERt.js} +1 -1
  72. package/dist/assets/{ExpenseAutomationPage-BrMLIa8l-rO7v5FFr.js → ExpenseAutomationPage-Cm_IiRlb-Ch0agMlw.js} +14 -14
  73. package/dist/assets/{ExpressPayPage-mNQZwQjW-BuMy6vAf.js → ExpressPayPage-DdQiFzDu-ykW984zo.js} +1 -1
  74. package/dist/assets/{FeaturePreviewPage-DBHT9uKl-CuaenWGz.js → FeaturePreviewPage-CQN2xThT-D8GcVVCI.js} +1 -1
  75. package/dist/assets/{FollowStepsSection-CSUuXn2f-BgH_uZF9.js → FollowStepsSection-DdwEVWhG-XjqeMDlz.js} +1 -1
  76. package/dist/assets/{GlobalReviewListPage-p0vz_C5a-CbqMjPf4.js → GlobalReviewListPage-DHn2Uk8R-Cd3V8M7p.js} +1 -1
  77. package/dist/assets/{HelpButton-B2amus4B-DejCwWuG.js → HelpButton-BNMy-6ce-WFq-iELy.js} +1 -1
  78. package/dist/assets/{InformationCardStack-BJ727KaL-BL1jahfP.js → InformationCardStack-Cw7c9Pnd-JKEjusS_.js} +1 -1
  79. package/dist/assets/{InsightsCardStack-DY6RY7Qe-DssEfhxv.js → InsightsCardStack-CaMZiCnn-D5ut2TNQ.js} +1 -1
  80. package/dist/assets/{InsightsSection-D-8tYkse-DLCSfT0G.js → InsightsSection-JIKb9lz3-CSUvMdaP.js} +1 -1
  81. package/dist/assets/{IntegrationsSettingsPage-1rJOamsZ-CCFrMSer.js → IntegrationsSettingsPage-h4pel2yK-CfkisAjm.js} +1 -1
  82. package/dist/assets/{InternationalWireSwiftDetailsPage-Ri6TSG6P-8V-Jx_AK.js → InternationalWireSwiftDetailsPage-C2SnHEV1-D4h6wt17.js} +1 -1
  83. package/dist/assets/{InternationalWireVerificationPage-CjriI8l--DVeYNdlX.js → InternationalWireVerificationPage-Dk11ztF7-CGQwkBKG.js} +1 -1
  84. package/dist/assets/{InviteFormPage-BY76duGE-C5wtRqak.js → InviteFormPage-CrtH0cSG-lBcBfRNC.js} +1 -1
  85. package/dist/assets/{InvitePageListView-AAJf0dR1-CCPXRa4B.js → InvitePageListView-DUoopPip-D3WES4Ay.js} +1 -1
  86. package/dist/assets/{InvitePeoplePage-CyMnjfEI-CTqEBEr_.js → InvitePeoplePage-C3ecL8XJ-D06hBumB.js} +1 -1
  87. package/dist/assets/{InvoiceUploadSection-DNao9DwT-C7CWv1v1.js → InvoiceUploadSection-DoR834b4-BezkawDL.js} +1 -1
  88. package/dist/assets/{IssueChargeCardPage-Bjy6NLc8-Ctym8rQ1.js → IssueChargeCardPage-D6DCohbK-CY0NLJ-D.js} +1 -1
  89. package/dist/assets/{LabeledAddressValue-B2k1GZHx-KNC3sWJt.js → LabeledAddressValue-C3R0DSjj-DSFQoK0_.js} +1 -1
  90. package/dist/assets/{LabeledAddressValueField-C6oH2tzZ-BPatozjs.js → LabeledAddressValueField-YP7bXlgZ-8CibrbWw.js} +1 -1
  91. package/dist/assets/{LabeledControlledCheckBoxField-D3legl2B-CCkkJ4fv.js → LabeledControlledCheckBoxField-zwoLFM1n-WAKwiqVu.js} +1 -1
  92. package/dist/assets/{LabeledCreatableSingleSelectField-BVxws_IH-DG8QIGXB.js → LabeledCreatableSingleSelectField-BhaeopJt-r1U--LmU.js} +1 -1
  93. package/dist/assets/{LabeledDocumentField-DwPfHt2N-rSrQz57g.js → LabeledDocumentField-ED03S2kQ-wbMhlpMQ.js} +1 -1
  94. package/dist/assets/{LabeledDropDownFormattedTextField-BFT3G777-BsOgj8n2.js → LabeledDropDownFormattedTextField-brzU_fnp-DR9C1PhE.js} +1 -1
  95. package/dist/assets/{LabeledText-nWCZBDTc-C9SVi_iV.js → LabeledText-BESSkt5Z-DvRhicFs.js} +1 -1
  96. package/dist/assets/{LabeledUserSingleSelectWithSubtitlesField-B5USvGOt-C0Rd0eYT.js → LabeledUserSingleSelectWithSubtitlesField-vEIvvd-n-BRFp4N3Z.js} +1 -1
  97. package/dist/assets/{LabeledZeniRolesDropDownField-CFKa2QEv-kq16r6NO.js → LabeledZeniRolesDropDownField-BXTCN4j2-C9dcF_vL.js} +1 -1
  98. package/dist/assets/{LinkJETransactionPage-C1nuQ_6i-CyK7Wga_.js → LinkJETransactionPage-_ROjxBMO-DP6JabBY.js} +1 -1
  99. package/dist/assets/{LockCardPage-s_PD9AzH-s3h7PN-R.js → LockCardPage-DYfgK11k-CA2sqFlt.js} +1 -1
  100. package/dist/assets/{LowBalancePopup-C3XwZy2N-CiNVfO8z.js → LowBalancePopup-CZDcHxyW-BHOAXZjC.js} +1 -1
  101. package/dist/assets/{MagicLinkACHDetailsPage-CAcRKnmW-BgyBZ6s3.js → MagicLinkACHDetailsPage-CLXcRbZ--CVcTUs2d.js} +1 -1
  102. package/dist/assets/{MagicLinkDomesticWireDetailsPage-BYmO4Xr9-CGhpWO66.js → MagicLinkDomesticWireDetailsPage-CZlZr96w-BPglJFOV.js} +1 -1
  103. package/dist/assets/{MagicLinkInternationalWireDetailsPage-BfVzS_Di-TeD5sFaU.js → MagicLinkInternationalWireDetailsPage-DhPjvv0o-DFwZaRYm.js} +1 -1
  104. package/dist/assets/{MagicLinkSuccessPage-CAnSgQhj-C5wC1vo0.js → MagicLinkSuccessPage-Bh2nlLPN-Ddx1hbRe.js} +1 -1
  105. package/dist/assets/{MagicLinkTitleSection-cO3EG-gp-BIrRsD_t.js → MagicLinkTitleSection-Cn1v72Rs-BaSRKY-c.js} +1 -1
  106. package/dist/assets/{MailingDetailsSection-DgN7ACVL-BU_sDZYM.js → MailingDetailsSection-9RwlQxVG-C09sdGhg.js} +1 -1
  107. package/dist/assets/{MeetingCalenderPopup-C1bMV1I3-DBaPSnGq.js → MeetingCalenderPopup-BxV_UIXP-B9VDTxkT.js} +1 -1
  108. package/dist/assets/{Menu-C-o9HER2-D5q1mW8f.js → Menu-B6iTf2H7-Cqx4dVPp.js} +1 -1
  109. package/dist/assets/{MyBankConnectionsSettingsPage-DiJHbt8A-DqapM7vm.js → MyBankConnectionsSettingsPage-IPPiH6jv-CVF8iXYJ.js} +1 -1
  110. package/dist/assets/{MyPendingActivationChargeCardListPage-CAH07oE4-CgBbGkED.js → MyPendingActivationChargeCardListPage-BTGb1yIE-BD419NGA.js} +1 -1
  111. package/dist/assets/{MyProfileSettingsPage-CWWb3u86-CBtfB4gW.js → MyProfileSettingsPage-BRK5nWg2--GwgfIws.js} +1 -1
  112. package/dist/assets/{NavBarWithPicker-BswkyMmW-cQa2dvHa.js → NavBarWithPicker-CKh_HMfV-U1f60LTo.js} +1 -1
  113. package/dist/assets/{NavigationArrow-cWkaAVwE-BjtSKPvG.js → NavigationArrow-XZmJpDrE-BSGdgz-m.js} +1 -1
  114. package/dist/assets/{NavigationDots-DDGYTuFE-BeWXaAY8.js → NavigationDots-BxPgEW_p-CnLRJgGA.js} +1 -1
  115. package/dist/assets/{NewGlobalMerchantPage-VAYeGHLy-CSl4x7Ux.js → NewGlobalMerchantPage-CQzrDe0S-CFbklyjG.js} +1 -1
  116. package/dist/assets/{NoDataChart-DOvXvjb9-v-09guTZ.js → NoDataChart-5E72SElf-Bfyft1Tp.js} +1 -1
  117. package/dist/assets/{NoDataTable-DRlkLFHY-xjLa4o8y.js → NoDataTable-BwHbkm3l-C4AJlFQY.js} +1 -1
  118. package/dist/assets/{NotFoundPage-BUQyPFn7-BMBYf8M4.js → NotFoundPage-6udaksBZ-Bdrzyyzv.js} +1 -1
  119. package/dist/assets/{NotificationSettingsPage-B1KXf_X_--eK-MD2V.js → NotificationSettingsPage-DkYmxMgg-B7fNoy2R.js} +1 -1
  120. package/dist/assets/{NotificationsListConfig-BoGND2x4-YVD5PFCu.js → NotificationsListConfig-FGxLgO1o-Bjqs17aQ.js} +1 -1
  121. package/dist/assets/{NotificationsPage-CsXXgLel-DjWMDFMU.js → NotificationsPage-C7lSAnUb-wDRHsOkp.js} +1 -1
  122. package/dist/assets/{OpExByVendorPage-BnJYy01U-CLIBojo-.js → OpExByVendorPage-CM0RluUk-BgpW2giu.js} +1 -1
  123. package/dist/assets/{OverlayContainerPage-BKHs_4eI-D7QJnRfx.js → OverlayContainerPage-BKHs_4eI-mLdiagVZ.js} +1 -1
  124. package/dist/assets/{PandLWithForecastPage-o-jbKy2e-C3ps-DTA.js → PandLWithForecastPage-W4jlNjml-Bcn3UKYp.js} +1 -1
  125. package/dist/assets/{PaymentAccountSetupBillingAddressSection-De5SXBpI-DsGHWie5.js → PaymentAccountSetupBillingAddressSection-DQ82eP9Q-ChYOGpfy.js} +1 -1
  126. package/dist/assets/{PeoplePage-DQ6Hff1k-Ctss-oGf.js → PeoplePage-CB3T3u_F-DC1PdCPq.js} +1 -1
  127. package/dist/assets/{PortfolioAllocationFormPage-V0wgI9Ce-Byk1mL3R.js → PortfolioAllocationFormPage-CZkJD6tu-CmTdPnvM.js} +1 -1
  128. package/dist/assets/{PortfolioDetails-CD5ZpbUI-CfC8RDVa.js → PortfolioDetails-D4yT8r35-DSk0Sc23.js} +1 -1
  129. package/dist/assets/{ProductsCarousel-V_jWJEER-D24dcvyt.js → ProductsCarousel-CR7_rk0K-DQWJaP-C.js} +1 -1
  130. package/dist/assets/{PromoBaseCards-BAFdMFqw-DEK2bZlE.js → PromoBaseCards-BAPolzxE-DLtmx-3v.js} +1 -1
  131. package/dist/assets/{QBOConnectionDialog-DKpO649n-B6_Kc8GW.js → QBOConnectionDialog-D3eazhj7-fJDNmSLU.js} +1 -1
  132. package/dist/assets/{QBOSetupSection-D0ZCB5UD-Cl7hjSJK.js → QBOSetupSection-Cjjhm_Ee-CrlXRkit.js} +1 -1
  133. package/dist/assets/{ReimbursementApprovalRuleDetailPage-DNt15Ut8-CvzV-Ew0.js → ReimbursementApprovalRuleDetailPage-eidNY097-DmIjK42h.js} +1 -1
  134. package/dist/assets/{ReimbursementApprovalRulesPage-Brx7wunO-CmtJNp7d.js → ReimbursementApprovalRulesPage-GSzJGSuy-H2GhhV11.js} +1 -1
  135. package/dist/assets/{ReimbursementDetailPage-DX_Fn31o-BfotdQuY.js → ReimbursementDetailPage-AvqEBxbz-fUbgpa2M.js} +1 -1
  136. package/dist/assets/{ReimbursementPromoPage-CkEv6rCJ-9jexXpR8.js → ReimbursementPromoPage-PshodHUZ-B_XNUegE.js} +1 -1
  137. package/dist/assets/{ReimbursementSetUpPage-CFO-blEl-Cs09UtRs.js → ReimbursementSetUpPage-6P4FT-UC-Bw__edeG.js} +1 -1
  138. package/dist/assets/{ReimbursementsBulkReviewDrawerPage-B-IcycaW-CSDGBoIN.js → ReimbursementsBulkReviewDrawerPage-Cas6GzVp-BQcspCuT.js} +1 -1
  139. package/dist/assets/{ReloadCard-DrU5ZC4a-DUG927nK.js → ReloadCard-Dpoxd9nE-B9DlyhD4.js} +1 -1
  140. package/dist/assets/{ReportTableViewSelector-oB74PECo-ByHpctQ-.js → ReportTableViewSelector-Ci-WKrCO-DAZRgQwg.js} +1 -1
  141. package/dist/assets/{ReportsPage-D0Psj2SZ-BuCtWHsX.js → ReportsPage-C7zirS74-CyyHiNy4.js} +1 -1
  142. package/dist/assets/{RevenueChart-Bnc2RxbY-D-b73Jp0.js → RevenueChart-CXMBT3cr-DnDEiqPG.js} +1 -1
  143. package/dist/assets/{ReviewDetailsPage-E4-dpZ3_-BirqasoD.js → ReviewDetailsPage-ClsyL5-w-_y4o463o.js} +1 -1
  144. package/dist/assets/{ReviewOverlay-C9hLAPaS-CC8EN_X1.js → ReviewOverlay-C6Kx7Hfm-IahzUsv3.js} +1 -1
  145. package/dist/assets/{RoleWithToolTip-BdIHsErU-B421SxNc.js → RoleWithToolTip-BqI6M0x_-CwUqJeb5.js} +1 -1
  146. package/dist/assets/{ScheduleDetailsFixedAssetsPage-DCrTdK6_-DlmUyg8r.js → ScheduleDetailsFixedAssetsPage-zFyJPVpN-BSd6OZtz.js} +1 -1
  147. package/dist/assets/{ScheduleDetailsPage-BNVBIY34-C9SHkuNO.js → ScheduleDetailsPage-BftjSvA7-Jy_FtZQR.js} +1 -1
  148. package/dist/assets/{ScheduleSequenceTable-DeLVkslS-C15n76pT.js → ScheduleSequenceTable-lTN7r0p4-BFWt_8N-.js} +1 -1
  149. package/dist/assets/{ScreenRoutes-C5AUDOTH.js → ScreenRoutes-en4svsq9.js} +1 -1
  150. package/dist/assets/{SetUpAccountSection-XaB8Huky-BnLG2flz.js → SetUpAccountSection-Bnbi8X23-DL-18RCf.js} +1 -1
  151. package/dist/assets/{SetUpDefaultSection-Dko6eOr--DSAIqPKL.js → SetUpDefaultSection-Bm1eZSgT-BcxYXAIw.js} +1 -1
  152. package/dist/assets/{SignIn-BKZ0UqXu-CQQAQGhJ.js → SignIn-BlISBvt5-C9HXqHPg.js} +1 -1
  153. package/dist/assets/{SignInScreen-_7s87q7V.js → SignInScreen-Ba17TSWH.js} +1 -1
  154. package/dist/assets/{SpendManagementListViewPage-Crlns-YT-CLQMoQch.js → SpendManagementListViewPage-ChNp8dgm-BhMjXPdH.js} +3 -3
  155. package/dist/assets/{SpendManagementPerTabPage-YjfDDwP4-BZ31j83o.js → SpendManagementPerTabPage-D-bOr2-6-GaRieOUe.js} +1 -1
  156. package/dist/assets/{SpendManagementSection-D8lfWWWV-43vrbIvO.js → SpendManagementSection-kucZgC-H-DLgSRXEX.js} +1 -1
  157. package/dist/assets/{SpendMgmtSetupAccountSection-C7WofOL3-C_mHdj1H.js → SpendMgmtSetupAccountSection-de7hEmtE-CX-1PNOC.js} +1 -1
  158. package/dist/assets/{StatementItem-CpZ-MDHo-Db04ym8p.js → StatementItem-BVIVLdDn-BLcyHqWZ.js} +1 -1
  159. package/dist/assets/{StatementsPage-BbO8PdHq-CoyYvllE.js → StatementsPage-KnLUSJbm-DvU_Y3UP.js} +1 -1
  160. package/dist/assets/{StatusSwitcher-DW-Q6MLD-CxdXHbCg.js → StatusSwitcher-aAizq1mr-D4E7X1zy.js} +1 -1
  161. package/dist/assets/{SubTabSwitcher-BgmKYyVl-CY4zKZFC.js → SubTabSwitcher-COrYJ6CW-B2hsvJe_.js} +1 -1
  162. package/dist/assets/{SummaryCard-V7fE0ql0--g0gbjUo.js → SummaryCard-Dv0dWKBw-BnK7xgrF.js} +1 -1
  163. package/dist/assets/{TaskManagementPage-D8UAfCaw-BnMxrHh5.js → TaskManagementPage-CPLyyK1Y-ena6uodh.js} +1 -1
  164. package/dist/assets/{TimeRangeSwitcher-BRY0oixp-B_RoHkbN.js → TimeRangeSwitcher-ifkHfqEg-CGFdCObN.js} +1 -1
  165. package/dist/assets/{TimeframeSwitcher-DIg8e-x0-2kFxMkvp.js → TimeframeSwitcher-BP-PxO5g-DG6ysLlp.js} +1 -1
  166. package/dist/assets/{TimeframeSwitcherWithToggle-utawMrzT-Bill4UcO.js → TimeframeSwitcherWithToggle-DH-PfsTQ-Dd12kokF.js} +1 -1
  167. package/dist/assets/{TopExCard-C2AE49xP-BraB7eP7.js → TopExCard-Bam-Q4MV-GCmLzO6i.js} +1 -1
  168. package/dist/assets/{TopExDetailPage-rA6jQ_FN-D6TDt_SY.js → TopExDetailPage-P0Twt5zZ-BElfoauE.js} +1 -1
  169. package/dist/assets/{TransactionDetailPage-r-DU5f0M-iBWQv_cT.js → TransactionDetailPage-D1Z1f-DD-DTPxqy3v.js} +1 -1
  170. package/dist/assets/{TransactionList-N7P-LryH--lfm65bH.js → TransactionList-BzJEbOV9-BQZ8x4Oq.js} +1 -1
  171. package/dist/assets/{TransactionListBig-cTDebILS-CtjpsP8i.js → TransactionListBig-u4SJBZTE-BZvqZwTB.js} +1 -1
  172. package/dist/assets/{TransactionListPage-DWfOgmyP-x0LIfwop.js → TransactionListPage-D4GJ6i3l-BXLL3BhX.js} +1 -1
  173. package/dist/assets/{TransactionVendorDetailPage-X0hlTlLK-B1OvnXkf.js → TransactionVendorDetailPage-CuFHbm8c-Cl9iluIt.js} +1 -1
  174. package/dist/assets/{TransferDrawerPage-BGdlNOXt-BVJKKJ3s.js → TransferDrawerPage-GD2I8ptj-B7cXbGdy.js} +1 -1
  175. package/dist/assets/{TreasuryOverviewPage-DLqZCVMi-CmlFguUG.js → TreasuryOverviewPage-DySunaqy-CWB-hp0S.js} +1 -1
  176. package/dist/assets/{TreasuryPromoPage-DbzfXlgw-Cnr9zUw4.js → TreasuryPromoPage-DW1f8_q1-CZjoBD0v.js} +1 -1
  177. package/dist/assets/{TreasurySetupPage-D9GxfZ9F-A-ZWAnnz.js → TreasurySetupPage-53k6ARHC-8YVNt5Wt.js} +1 -1
  178. package/dist/assets/{TreasuryStatementsPage-DLi_sZPF-BwcPosXZ.js → TreasuryStatementsPage-pIshKNaR-Dtfk2lx_.js} +1 -1
  179. package/dist/assets/{TreasuryTaxLetterPage-DT9qtjBD-BRXBc7C_.js → TreasuryTaxLetterPage-B3PkB1al-CKVKJh1V.js} +1 -1
  180. package/dist/assets/{TreasuryTransferOrReviewPage-Bwmdvxcf-BC7BjXMz.js → TreasuryTransferOrReviewPage-Dzq-FxSM-CX84O_mN.js} +1 -1
  181. package/dist/assets/{TrendChart-PEPDz5Rb-C5_CXK8K.js → TrendChart-B_5D-Zud-BUU2-6nI.js} +1 -1
  182. package/dist/assets/{TrendWithTransactions-D0kwx2QH-C1njpMfG.js → TrendWithTransactions-mI_El5D1-SbfSjDf-.js} +1 -1
  183. package/dist/assets/{UncategorizedAccountsMappingPage-B_m-aQN1-BdI8jrrw.js → UncategorizedAccountsMappingPage-LQeq8Gdv-BxpsIXJf.js} +1 -1
  184. package/dist/assets/{UnitIntegrationPage-D_I3woOf-BdB9dVUS.js → UnitIntegrationPage-XOWqGHla-DR8O2yO4.js} +1 -1
  185. package/dist/assets/{UploadAdditionalDocumentOverlay-BzWXbm7_-BYxLpWvz.js → UploadAdditionalDocumentOverlay-DhXRLBEg-DvVrgitE.js} +1 -1
  186. package/dist/assets/{Vendor2FAPopup-ZhMUe2XG-CMbLzdmx.js → Vendor2FAPopup-BfqIHZBb-CksyyTez.js} +1 -1
  187. package/dist/assets/{VendorACHDetailsPage-BxSB3e3f-NKMZBQ_S.js → VendorACHDetailsPage-CswCvAFH-CdUK-HJH.js} +1 -1
  188. package/dist/assets/{VendorDetailPage-Cil4QKpo-OKzerEoj.js → VendorDetailPage-CEX7xMIN-Djo4PloX.js} +1 -1
  189. package/dist/assets/{VendorDomesticWireDetailsPage-t9rrf_8I-BW4LvYLe.js → VendorDomesticWireDetailsPage-DxrSjlTR-B4ZHtbXA.js} +1 -1
  190. package/dist/assets/{VendorFiling1099EditablePage-CVvvZInI-CbWeL7rE.js → VendorFiling1099EditablePage-q1gQ8keD-BmDatzoV.js} +1 -1
  191. package/dist/assets/{VendorFirstReviewPage-CEhcXzDq-CF9AIieN.js → VendorFirstReviewPage-D9ogNmAK-PlB10gEr.js} +1 -1
  192. package/dist/assets/{VendorInternationalWireDetailsPage-BuII-Mam-BGd0kiN2.js → VendorInternationalWireDetailsPage-Ct689KuY-DAoPjpj5.js} +1 -1
  193. package/dist/assets/{VendorInternationalWireSwiftDetailsPage-CcVcyWBe-D99dYtWX.js → VendorInternationalWireSwiftDetailsPage-W0s1zQNC-ZgE8KOcO.js} +1 -1
  194. package/dist/assets/{VendorsAccountsSection-DH0mosVk-JqDhMB4O.js → VendorsAccountsSection-C13Z2HN9-C2XOcHy1.js} +1 -1
  195. package/dist/assets/{VerifyDevice-BWzESmW--BKst56S-.js → VerifyDevice-C27gEWkZ-C7pLL5Wm.js} +1 -1
  196. package/dist/assets/{VideoPlayer-DPXISthv-iABqInol.js → VideoPlayer-ByyqUuhG-DTMNeCaX.js} +1 -1
  197. package/dist/assets/{VideoPopup-B2pu7j6O-DcAtt4hw.js → VideoPopup-DJrQQTPq-DoXO-Vwb.js} +1 -1
  198. package/dist/assets/{WarningsDrawerPage-DQjc5yVp-RGVHjaxW.js → WarningsDrawerPage-B3Ht3VnM-DBDTIhyB.js} +1 -1
  199. package/dist/assets/{ZeniAccountDetailPage-CI2TQILk-PuWbEnGQ.js → ZeniAccountDetailPage-egmysAfI-DFbZv9KZ.js} +1 -1
  200. package/dist/assets/{ZeniAccountListViewPage-DjhscUyw-7icktWUA.js → ZeniAccountListViewPage-q_v2FogF-B-baYGeD.js} +1 -1
  201. package/dist/assets/{ZeniAccountNavBarPieces-BMOxM3Ul-612xJvF6.js → ZeniAccountNavBarPieces-HNIht0FM-aSJ3m6rj.js} +1 -1
  202. package/dist/assets/{ZeniAccountPromoPage-CoegRWXG-DicGPTSL.js → ZeniAccountPromoPage-CzncR6vK-DAONZr9A.js} +1 -1
  203. package/dist/assets/{ZeniAccountSetupPage-l8SdQK7w-BdI_dgyM.js → ZeniAccountSetupPage-TcdzEL_V-CApQPT0B.js} +1 -1
  204. package/dist/assets/{ZeniCopyright-CrpLjMla-DvRGZGQ9.js → ZeniCopyright-B7Q6IUGC-Ca3UXoxG.js} +1 -1
  205. package/dist/assets/{ZeniTransferAmountSlider-oZNLHFd5-PDQERkPa.js → ZeniTransferAmountSlider-Dmf5xxv4-D_ugGHJW.js} +1 -1
  206. package/dist/assets/{analyticsHelper-mfWw4TCX.js → analyticsHelper-CVWZE356.js} +1 -1
  207. package/dist/assets/{analyticsHelper-ColsUhUK-vardy7WR.js → analyticsHelper-or1KkBWk-Plh_6I_p.js} +1 -1
  208. package/dist/assets/{chartTypes-BFE_S1PL-DOHRtqWo.js → chartTypes-DCvOVjlS-BdPIN5WI.js} +1 -1
  209. package/dist/assets/{commonDimensions-Dq7P0AE6-Cdz-7EJl.js → commonDimensions-C32v1F7H-CiAEfJl2.js} +1 -1
  210. package/dist/assets/{detailCommon-DSe7Tzn3-C15dhIqY.js → detailCommon-CRAGrqoO-Cq9phP1q.js} +1 -1
  211. package/dist/assets/{downloadPdf-D3hiuG-R-CfWEq2eL.js → downloadPdf-D7p3yKmg-CYmmjPHt.js} +1 -1
  212. package/dist/assets/{index-D94hlokH.js → index-sAOH0Fje.js} +4 -4
  213. package/dist/assets/{mapLoadingInProgressToTreeNode-COnUyXAf-oqBOjgHh.js → mapLoadingInProgressToTreeNode-CRwG2DSD-B4LnWZMC.js} +1 -1
  214. package/dist/assets/{mapSectionWithAcOnlyToTreeNode-CDE8V8lh-9J1CJPJ0.js → mapSectionWithAcOnlyToTreeNode-C9O-C2dp-BYZLhSZo.js} +1 -1
  215. package/dist/assets/{mapSpacerToTreeNode-Ljk42Rtu-DPJWdE3q.js → mapSpacerToTreeNode-5aJk-sLn-DpF_Q8pH.js} +1 -1
  216. package/dist/assets/{mapTimeframeBalancesToTreeNode-Cv95aY-B-VNSYZVhm.js → mapTimeframeBalancesToTreeNode-CnviLujI-Do2_oG27.js} +1 -1
  217. package/dist/assets/{mapTimeframeBalancesToTreeNode-B64chWyJ-CiceKmAm.js → mapTimeframeBalancesToTreeNode-Cv4d4PqE-C559SZVp.js} +1 -1
  218. package/dist/assets/{mapTimeframeHeaderLoadingInProgressToTreeNode-DFgAA2si-DqUkzVrn.js → mapTimeframeHeaderLoadingInProgressToTreeNode-BaGM4krW-yJCRTG35.js} +1 -1
  219. package/dist/assets/{toCOABalancesWithID-BK1XA0gz-D3HM3wW9.js → toCOABalancesWithID-B3yVGPrV-B_BzNOYP.js} +1 -1
  220. package/dist/assets/{toChartData-D7n7RyVD-Ugd_lC5Y.js → toChartData-DEW0iT7T-DrkbvIyQ.js} +1 -1
  221. package/dist/assets/{treasuryColorHelper-tTPJnd8d-BU6MV_k4.js → treasuryColorHelper-13LJ_xhk-LqN_6Xl4.js} +1 -1
  222. package/dist/assets/{uploadAttachment-By_eR78P-BWtANd19.js → uploadAttachment-DVy2pZeJ-X-xSyfvF.js} +1 -1
  223. package/dist/assets/{uploadReceipts-Dp1dvCjf-DS6AgWc1.js → uploadReceipts-Dp1dvCjf-Bw0_dVvQ.js} +1 -1
  224. package/dist/index.html +1 -1
  225. package/package.json +2 -2
  226. package/dist/assets/CustomerOnboardingContainerPage-Bzjew7MV-D4ymslq9.js +0 -1
@@ -1,4 +1,4 @@
1
- import{q as C,O as u,j as i,n as k,o,y as a,h as d,fJ as T,c as E,ag as W,bz as q,f1 as B,fH as H,aU as w,ai as $,u as t}from"./index-D94hlokH.js";import{n as s}from"./vendor-Bs1fkIUX.js";import I from"./QBOConnectionDialog-DKpO649n-B6_Kc8GW.js";const r={containerPadding:new a(t[3],t[4]),sectionWidth:new a(343,580,726),topElementsRowGap:new a(t[3],t[0]),arrowIconWidthHeight:new a(t[3],t[4])},A={title:new E("standardMedium","largeMedium")},ee=({isAdmin:e,hasError:c=!1,isValid:l,saveConnectionState:p,isQBOPopupOpen:y,companyName:j,updateQBOPopupState:h,handleOnConnectClick:f})=>{const n=C(),{qbo_connection:S}=u.getLocalizedStrings().customerOnboardingPage.sections,{title:b,sucessText:z,button:v,errorText:P,requiredText:O}=S;return i.jsxs(G,{windowSize:n,children:[i.jsxs(N,{windowSize:n,children:[n==="small"?i.jsx(V,{children:l?i.jsx(_,{}):i.jsx(K,{})}):null,i.jsx(Q,{windowSize:n,children:b})]}),i.jsxs(D,{windowSize:n,children:[i.jsxs(J,{windowSize:n,children:[i.jsxs(R,{children:[i.jsx(F,{}),i.jsx(L,{windowSize:n}),i.jsx(U,{})]}),l?n!=="small"?i.jsx(m,{}):null:i.jsx(k,{variant:"primary",size:n!=="small"?"standard":"xs-small",label:v.connect,style:{width:"fit-content"},onClick:()=>h(!0),loading:p==="In-Progress"})]}),l?i.jsxs(i.Fragment,{children:[i.jsx(M,{children:z}),n==="small"?i.jsx(m,{}):null]}):null,p==="Error"?i.jsx(x,{children:i.jsx(g,{windowSize:n,children:P})}):null,c&&!l?i.jsx(x,{children:i.jsx(g,{windowSize:n,children:O})}):null]}),i.jsx(I,{isAdmin:e,isGoBackAllowed:!0,isQBOPopupOpen:y,companyName:j,saveConnectionState:p,handleOnConnectClick:f,handleGoBack:()=>h(!1)})]})},m=()=>{const{tags:e}=u.getLocalizedStrings().customerOnboardingPage,{connected:c}=e;return i.jsx(H,{style:{width:"max-content",padding:0,marginTop:o.sp2},tagTitle:c,textColor:{color:new w(d.successDark),borderColor:new w(d.successDark)}})},G=s.div`
1
+ import{q as C,O as u,j as i,n as k,o,y as a,h as d,fJ as T,c as E,ag as W,bz as q,f1 as B,fH as H,aU as w,ai as $,u as t}from"./index-sAOH0Fje.js";import{n as s}from"./vendor-Bs1fkIUX.js";import I from"./QBOConnectionDialog-D3eazhj7-fJDNmSLU.js";const r={containerPadding:new a(t[3],t[4]),sectionWidth:new a(343,580,726),topElementsRowGap:new a(t[3],t[0]),arrowIconWidthHeight:new a(t[3],t[4])},A={title:new E("standardMedium","largeMedium")},ee=({isAdmin:e,hasError:c=!1,isValid:l,saveConnectionState:p,isQBOPopupOpen:y,companyName:j,updateQBOPopupState:h,handleOnConnectClick:f})=>{const n=C(),{qbo_connection:S}=u.getLocalizedStrings().customerOnboardingPage.sections,{title:b,sucessText:z,button:v,errorText:P,requiredText:O}=S;return i.jsxs(G,{windowSize:n,children:[i.jsxs(N,{windowSize:n,children:[n==="small"?i.jsx(V,{children:l?i.jsx(_,{}):i.jsx(K,{})}):null,i.jsx(Q,{windowSize:n,children:b})]}),i.jsxs(D,{windowSize:n,children:[i.jsxs(J,{windowSize:n,children:[i.jsxs(R,{children:[i.jsx(F,{}),i.jsx(L,{windowSize:n}),i.jsx(U,{})]}),l?n!=="small"?i.jsx(m,{}):null:i.jsx(k,{variant:"primary",size:n!=="small"?"standard":"xs-small",label:v.connect,style:{width:"fit-content"},onClick:()=>h(!0),loading:p==="In-Progress"})]}),l?i.jsxs(i.Fragment,{children:[i.jsx(M,{children:z}),n==="small"?i.jsx(m,{}):null]}):null,p==="Error"?i.jsx(x,{children:i.jsx(g,{windowSize:n,children:P})}):null,c&&!l?i.jsx(x,{children:i.jsx(g,{windowSize:n,children:O})}):null]}),i.jsx(I,{isAdmin:e,isGoBackAllowed:!0,isQBOPopupOpen:y,companyName:j,saveConnectionState:p,handleOnConnectClick:f,handleGoBack:()=>h(!1)})]})},m=()=>{const{tags:e}=u.getLocalizedStrings().customerOnboardingPage,{connected:c}=e;return i.jsx(H,{style:{width:"max-content",padding:0,marginTop:o.sp2},tagTitle:c,textColor:{color:new w(d.successDark),borderColor:new w(d.successDark)}})},G=s.div`
2
2
  display: flex;
3
3
  flex-direction: column;
4
4
  align-items: center;
@@ -1,4 +1,4 @@
1
- import{y as O,u as U,d as M,q as W,O as D,aa as G,aP as J,j as s,aJ as Q,cS as X,bF as H,ad as K,aQ as Y,o as f}from"./index-D94hlokH.js";import{b as j,n as h}from"./vendor-Bs1fkIUX.js";import{b as Z,f as ee,l as B,o as L}from"./FollowStepsSection-CSUuXn2f-BgH_uZF9.js";import"./mui-Ty75qFQF.js";import"./analytics-CcevxdRy.js";import"./routing-Dk1A2KYI.js";import"./sentry-BE5FTzpq.js";import"./redux-CEhZD0hA.js";import"./liveblocks-8ht9CoL5.js";import"./crypto-cQYYQPTZ.js";const $="reimbursementApprovalRuleDetailPage",T="lowerBound",k="upperBound",y="steps",te={footerPadding:new O(U[2],U[3])};function ye({localData:e,approvalUpdateActionType:r,isLowerBoundDisabled:t=!1,isUpperBoundDisabled:l=!0,hideUpperBoundField:o=!1,onBackClick:d,onApprovalRuleDataUpdated:b,onResetClick:N,onSaveRuleClick:E,onSaveRuleSuccess:S}){const _=M(),A=W(),a=D.getLocalizedStrings().commonSetUp.approval,I=D.getLocalizedStrings().spendManagement.reimbursement.reimbursementApproval,x=ae(e,r==="approval_create"&&!t),g=G({mode:"all",reValidateMode:"onChange",defaultValues:x}),u=e.remiSetupApproverViewUpdateData?.updateStatus,P=J(u?.fetchState),{upperBound:w}=x,{allApprovalRules:n,allAccountingClasses:F,remiSetupApproverViewUpdateData:c}=e;let m=n.length>1?n.length-1:0,v=n.length>0?n[m].criteria[0].range.min.amount:0;if(c!=null&&c.type==="approval_update"&&c.data!=null){const{approvalRuleId:i}=c.data;m=n.findIndex(p=>p.approvalRuleId===i),v=m>0?n[m-1].criteria[0].range.min.amount:0}const q=g.handleSubmit(()=>{E()}),V=async(i,p)=>{b(p)};return j.useEffect(()=>{const i=g.watch((p,{name:R})=>{if(R!=null&&p!=null){const z=Q(p);X(()=>V(R,z))}});return()=>{i.unsubscribe()}}),j.useEffect(()=>{P==="In-Progress"&&u?.fetchState==="Completed"&&S()},[P,u?.fetchState,S]),s.jsxs(se,{children:[s.jsx(H,{title:r==="approval_create"?a.newApproval:a.editApproval,backgroundColor:_.colors.grey4,style:{zIndex:4},onBackClick:()=>{d()},source:"ReimbursementApprovalRuleDetailPage"}),s.jsx(ne,{children:s.jsx(K,{...g,children:s.jsx("form",{id:C($),onSubmit:q,children:s.jsxs(ie,{children:[s.jsx(Z,{label:{label:o?I.amountPerRemiGreaterLabel:I.amountPerRemiLabel},firstText:{type:"number",name:T,placeholder:"$0",options:{required:!0,max:w===1/0?Number.MAX_SAFE_INTEGER-1:w-1,min:v,validate:i=>t?!0:i!=null&&i>v},isDisabled:t,additionalInfoLabel:a.firstRuleLowerBoundInfoLabel,additionalErrorLabel:a.firstRuleErrorInfoLabel},secondText:{type:"number",name:k,placeholder:"Infinity",isDisabled:l,hideField:o,additionalInfoLabel:a.upperBoundInfoLabel}}),s.jsx(pe,{}),s.jsx(ee,{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:F,stepsInfo:x[y],userSelectPlaceholder:a.userSelectPlaceholder,approveNotifyPlaceholder:a.approveNotifyPlaceholder,productType:"zeni_reimbursements"})]})})})}),s.jsx(Y,{formId: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:N},containerStyle:{justifyContent:A==="small"?"space-between":"center"},style:{padding:te.footerPadding.valuePx(A)},separatorStyle:{marginRight:f.sp4}})]})}const ae=(e,r)=>{const{criteria:t,steps:l}=e.remiSetupApproverViewUpdateData?.data??{};return{[y]:re(e.allApprovers.map(o=>o.user),e.filteredApprovers.map(o=>o.user),L(e.allAttributes),L(e.filteredAttributes),l??[])??[],[T]:r?void 0:t!=null?t.range.min.amount??0:0,[k]:t!=null?t.range.max==null?1/0:t.range.max.amount:1/0}},re=(e,r,t,l,o)=>o&&o.length>0?o.map((d,b)=>({stepIndex:b,stepType:{selectedOption:d.action,allOptions:B},actors:{allUsers:r,selectedUsers:le(e,d.actors),allNonUsers:l,selectedNonUsers:oe(t,d.actors)}})):[{stepIndex:0,stepType:{selectedOption:"require_approval",allOptions:B},actors:{allUsers:r,selectedUsers:[],allNonUsers:l,selectedNonUsers:[]}}],le=(e,r)=>e.filter(t=>t.userId!=null&&r.findIndex(l=>l.userId===t.userId)>-1),oe=(e,r)=>e.filter(t=>r.findIndex(l=>l.subType===t.value)>-1),C=e=>`${e}_form`,Se=e=>`${e}`,se=h.div`
1
+ import{y as O,u as U,d as M,q as W,O as D,aa as G,aP as J,j as s,aJ as Q,cS as X,bF as H,ad as K,aQ as Y,o as f}from"./index-sAOH0Fje.js";import{b as j,n as h}from"./vendor-Bs1fkIUX.js";import{b as Z,f as ee,l as B,o as L}from"./FollowStepsSection-DdwEVWhG-XjqeMDlz.js";import"./mui-Ty75qFQF.js";import"./analytics-CcevxdRy.js";import"./routing-Dk1A2KYI.js";import"./sentry-BE5FTzpq.js";import"./redux-CEhZD0hA.js";import"./liveblocks-8ht9CoL5.js";import"./crypto-cQYYQPTZ.js";const $="reimbursementApprovalRuleDetailPage",T="lowerBound",k="upperBound",y="steps",te={footerPadding:new O(U[2],U[3])};function ye({localData:e,approvalUpdateActionType:r,isLowerBoundDisabled:t=!1,isUpperBoundDisabled:l=!0,hideUpperBoundField:o=!1,onBackClick:d,onApprovalRuleDataUpdated:b,onResetClick:N,onSaveRuleClick:E,onSaveRuleSuccess:S}){const _=M(),A=W(),a=D.getLocalizedStrings().commonSetUp.approval,I=D.getLocalizedStrings().spendManagement.reimbursement.reimbursementApproval,x=ae(e,r==="approval_create"&&!t),g=G({mode:"all",reValidateMode:"onChange",defaultValues:x}),u=e.remiSetupApproverViewUpdateData?.updateStatus,P=J(u?.fetchState),{upperBound:w}=x,{allApprovalRules:n,allAccountingClasses:F,remiSetupApproverViewUpdateData:c}=e;let m=n.length>1?n.length-1:0,v=n.length>0?n[m].criteria[0].range.min.amount:0;if(c!=null&&c.type==="approval_update"&&c.data!=null){const{approvalRuleId:i}=c.data;m=n.findIndex(p=>p.approvalRuleId===i),v=m>0?n[m-1].criteria[0].range.min.amount:0}const q=g.handleSubmit(()=>{E()}),V=async(i,p)=>{b(p)};return j.useEffect(()=>{const i=g.watch((p,{name:R})=>{if(R!=null&&p!=null){const z=Q(p);X(()=>V(R,z))}});return()=>{i.unsubscribe()}}),j.useEffect(()=>{P==="In-Progress"&&u?.fetchState==="Completed"&&S()},[P,u?.fetchState,S]),s.jsxs(se,{children:[s.jsx(H,{title:r==="approval_create"?a.newApproval:a.editApproval,backgroundColor:_.colors.grey4,style:{zIndex:4},onBackClick:()=>{d()},source:"ReimbursementApprovalRuleDetailPage"}),s.jsx(ne,{children:s.jsx(K,{...g,children:s.jsx("form",{id:C($),onSubmit:q,children:s.jsxs(ie,{children:[s.jsx(Z,{label:{label:o?I.amountPerRemiGreaterLabel:I.amountPerRemiLabel},firstText:{type:"number",name:T,placeholder:"$0",options:{required:!0,max:w===1/0?Number.MAX_SAFE_INTEGER-1:w-1,min:v,validate:i=>t?!0:i!=null&&i>v},isDisabled:t,additionalInfoLabel:a.firstRuleLowerBoundInfoLabel,additionalErrorLabel:a.firstRuleErrorInfoLabel},secondText:{type:"number",name:k,placeholder:"Infinity",isDisabled:l,hideField:o,additionalInfoLabel:a.upperBoundInfoLabel}}),s.jsx(pe,{}),s.jsx(ee,{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:F,stepsInfo:x[y],userSelectPlaceholder:a.userSelectPlaceholder,approveNotifyPlaceholder:a.approveNotifyPlaceholder,productType:"zeni_reimbursements"})]})})})}),s.jsx(Y,{formId: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:N},containerStyle:{justifyContent:A==="small"?"space-between":"center"},style:{padding:te.footerPadding.valuePx(A)},separatorStyle:{marginRight:f.sp4}})]})}const ae=(e,r)=>{const{criteria:t,steps:l}=e.remiSetupApproverViewUpdateData?.data??{};return{[y]:re(e.allApprovers.map(o=>o.user),e.filteredApprovers.map(o=>o.user),L(e.allAttributes),L(e.filteredAttributes),l??[])??[],[T]:r?void 0:t!=null?t.range.min.amount??0:0,[k]:t!=null?t.range.max==null?1/0:t.range.max.amount:1/0}},re=(e,r,t,l,o)=>o&&o.length>0?o.map((d,b)=>({stepIndex:b,stepType:{selectedOption:d.action,allOptions:B},actors:{allUsers:r,selectedUsers:le(e,d.actors),allNonUsers:l,selectedNonUsers:oe(t,d.actors)}})):[{stepIndex:0,stepType:{selectedOption:"require_approval",allOptions:B},actors:{allUsers:r,selectedUsers:[],allNonUsers:l,selectedNonUsers:[]}}],le=(e,r)=>e.filter(t=>t.userId!=null&&r.findIndex(l=>l.userId===t.userId)>-1),oe=(e,r)=>e.filter(t=>r.findIndex(l=>l.subType===t.value)>-1),C=e=>`${e}_form`,Se=e=>`${e}`,se=h.div`
2
2
  display: flex;
3
3
  height: 100%;
4
4
  flex-direction: column;
@@ -1,4 +1,4 @@
1
- import{d as M,q as B,O as y,j as o,bF as E,P as H,aM as S,o as t,y as r,am as L,aN as z,cD as G,cE as U,cF as q,dd as F,u as l,b8 as O,c as P,b7 as V,h as j,da as _,bx as K,C as Y}from"./index-D94hlokH.js";import{n as i,b as Z}from"./vendor-Bs1fkIUX.js";import"./mui-Ty75qFQF.js";import"./analytics-CcevxdRy.js";import"./routing-Dk1A2KYI.js";import"./sentry-BE5FTzpq.js";import"./redux-CEhZD0hA.js";import"./liveblocks-8ht9CoL5.js";import"./crypto-cQYYQPTZ.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(l[0],-4)},N={stepper:new P("smallRegular","standardRegular"),amount:new P("standardRegular","largeRegular")},J=({showDeleteBtn:e=!1,isLastSection:f=!1,approvalRule:x,onEditRuleClick:v,onDeleteRuleClick:b})=>{const[g,d]=Z.useState(!1),n=B(),{range:c}=x.criteria[0],{steps:w,approvalRuleId:m}=x,a=y.getLocalizedStrings().commonSetUp.approval,$=()=>{d(!0)},W={onOkClick:()=>{d(!1),b?.(m)},onCancelClick:()=>{d(!1)}};return o.jsxs(Q,{windowSize:n,isLastSection:f,"data-testid":S("approval-rule-section",m),children:[o.jsxs(X,{windowSize:n,children:[o.jsxs(ae,{children:[o.jsxs(I,{windowSize:n,children:[a.from," ",z("0,0",c.min)]}),o.jsxs(ee,{children:[o.jsx(k,{}),o.jsx(oe,{}),o.jsx(k,{})]}),c.max==null?o.jsx(ce,{}):o.jsx(I,{windowSize:n,children:z("0,0",{...c.min,amount:c.max.amount})})]}),o.jsxs(ne,{className:"icons",children:[e?o.jsx(pe,{onClick:$}):null,o.jsx(de,{onClick:()=>{v(m)},"data-testid":S("edit-approval-rule",m)})]})]}),o.jsx(te,{windowSize:n,children:o.jsx(ie,{isSingleStep:w.length===1,windowSize:n,children:w.map((h,A)=>o.jsxs(re,{isSingleStep:w.length===1,className:"stepperItem",windowSize:n,children:[h.action==="require_approval"?o.jsx(le,{children:a.requireText}):o.jsx(se,{children:a.notifyText}),h.nonUserActors.filter(p=>p.subType!=null).map((p,D)=>o.jsxs(R,{children:[o.jsx(T,{children:p.subType!=null?a.nonUsers[p.subType].label:null}),h.operator!="is"?o.jsx(C,{className:"operator",children:h.operator}):null]},`${p.subType}_${D}`)),h.actors.map(p=>o.jsxs(R,{children:[o.jsxs(T,{children:[p.firstName," ",p.lastName]}),h.operator!="is"?o.jsx(C,{className:"operator",children:h.operator}):null]},p.userId))]},A))})}),g?o.jsx(G,{titleComponent:o.jsx(q,{children:a.deleteApprovalRuleTitle}),descriptionComponent:o.jsx(U,{children:a.deleteApprovalRuleDesc}),primaryButtonText:a.deleteTxt,proceedButtonVariant:"danger",secondaryButtonText:a.cancelBtnText,action:W}):null]})},Q=i.div`
1
+ import{d as M,q as B,O as y,j as o,bF as E,P as H,aM as S,o as t,y as r,am as L,aN as z,cD as G,cE as U,cF as q,dd as F,u as l,b8 as O,c as P,b7 as V,h as j,da as _,bx as K,C as Y}from"./index-sAOH0Fje.js";import{n as i,b as Z}from"./vendor-Bs1fkIUX.js";import"./mui-Ty75qFQF.js";import"./analytics-CcevxdRy.js";import"./routing-Dk1A2KYI.js";import"./sentry-BE5FTzpq.js";import"./redux-CEhZD0hA.js";import"./liveblocks-8ht9CoL5.js";import"./crypto-cQYYQPTZ.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(l[0],-4)},N={stepper:new P("smallRegular","standardRegular"),amount:new P("standardRegular","largeRegular")},J=({showDeleteBtn:e=!1,isLastSection:f=!1,approvalRule:x,onEditRuleClick:v,onDeleteRuleClick:b})=>{const[g,d]=Z.useState(!1),n=B(),{range:c}=x.criteria[0],{steps:w,approvalRuleId:m}=x,a=y.getLocalizedStrings().commonSetUp.approval,$=()=>{d(!0)},W={onOkClick:()=>{d(!1),b?.(m)},onCancelClick:()=>{d(!1)}};return o.jsxs(Q,{windowSize:n,isLastSection:f,"data-testid":S("approval-rule-section",m),children:[o.jsxs(X,{windowSize:n,children:[o.jsxs(ae,{children:[o.jsxs(I,{windowSize:n,children:[a.from," ",z("0,0",c.min)]}),o.jsxs(ee,{children:[o.jsx(k,{}),o.jsx(oe,{}),o.jsx(k,{})]}),c.max==null?o.jsx(ce,{}):o.jsx(I,{windowSize:n,children:z("0,0",{...c.min,amount:c.max.amount})})]}),o.jsxs(ne,{className:"icons",children:[e?o.jsx(pe,{onClick:$}):null,o.jsx(de,{onClick:()=>{v(m)},"data-testid":S("edit-approval-rule",m)})]})]}),o.jsx(te,{windowSize:n,children:o.jsx(ie,{isSingleStep:w.length===1,windowSize:n,children:w.map((h,A)=>o.jsxs(re,{isSingleStep:w.length===1,className:"stepperItem",windowSize:n,children:[h.action==="require_approval"?o.jsx(le,{children:a.requireText}):o.jsx(se,{children:a.notifyText}),h.nonUserActors.filter(p=>p.subType!=null).map((p,D)=>o.jsxs(R,{children:[o.jsx(T,{children:p.subType!=null?a.nonUsers[p.subType].label:null}),h.operator!="is"?o.jsx(C,{className:"operator",children:h.operator}):null]},`${p.subType}_${D}`)),h.actors.map(p=>o.jsxs(R,{children:[o.jsxs(T,{children:[p.firstName," ",p.lastName]}),h.operator!="is"?o.jsx(C,{className:"operator",children:h.operator}):null]},p.userId))]},A))})}),g?o.jsx(G,{titleComponent:o.jsx(q,{children:a.deleteApprovalRuleTitle}),descriptionComponent:o.jsx(U,{children:a.deleteApprovalRuleDesc}),primaryButtonText:a.deleteTxt,proceedButtonVariant:"danger",secondaryButtonText:a.cancelBtnText,action:W}):null]})},Q=i.div`
2
2
  display: flex;
3
3
  flex-direction: column;
4
4
  gap: ${e=>s.wrapperGap.valuePx(e.windowSize)};
@@ -1,4 +1,4 @@
1
- import{ax as Mt,a9 as Rt,q as Pt,d as Bt,cr as Nt,y as m,O as Ze,l as ie,gr as Lt,gt as Ot,gu as _t,j as t,cD as ze,cE as Ae,cF as Me,aM as y,bF as Re,bs as Wt,dN as Et,gv as Ft,gG as Pe,o as a,gw as Be,fu as b,fw as w,gz as x,aN as Ne,ft as Le,C as F,gB as Oe,aQ as Kt,ap as Ut,gC as Vt,gD as ae,bB as Gt,gE as Yt,A as Ht,c as qt,H as Jt,am as et,b8 as tt,h as K,an as Qt,c7 as Xt,ai as Zt,gV as ei,gR as ti,u as c,cw as ii,d8 as ai}from"./index-D94hlokH.js";import{b as p,n as r}from"./vendor-Bs1fkIUX.js";import{_ as ri}from"./liveblocks-8ht9CoL5.js";import oi from"./InvoiceUploadSection-DNao9DwT-C7CWv1v1.js";import{r as ni,h as f,u as li}from"./types-DyvtCprH-BcZYcgaq.js";import"./mui-Ty75qFQF.js";import"./analytics-CcevxdRy.js";import"./routing-Dk1A2KYI.js";import"./sentry-BE5FTzpq.js";import"./redux-CEhZD0hA.js";import"./crypto-cQYYQPTZ.js";import"./AttachmentView-DZCtCZK_-BwikHNAT.js";import"./uploadReceipts-Dp1dvCjf-DS6AgWc1.js";const s={labelWidth:new m(120,160,160),largeLabelWidth:new m(150,235,235),rightMargin:new m(c[3],c[8]),leftMargin:new m(c[3],c[6]),invoiceRightMargin:new m(c[3],c[6]),invoiceLeftMargin:new m(c[3],c[8]),topMargin:new m(c[3],0),bottomMargin:new m(c[4],27),activityBottomMargin:new m(96,0),totalBottomMargin:new m(c[5],c[3]),formBottomMargin:new m(c[5],c[3]),navBarHeight:new m(44,62),closeMarginTop:new m(0,0),rightSectionWidth:new m(100,58),leftSectionWidth:new m(100,42),footerButtonWidth:new m(120,165),right:new m(c[3],c[0]),actionsContainerRight:new m(c[0],c[6]),otherActionsContainerBottom:new m(58,44),duplicateBannerWrapperMarginTop:new m(c[5],c[3]),duplicateBannerWrapperMarginRight:new m(c[3],c[8]),duplicateBannerWrapperMarginBottom:new m(c[5],c[3]),duplicateBannerWrapperMarginLeft:new m(c[3],c[6])},si={formTitle:new qt("h6Regular","h5Regular")},aa=({remiDetails:e,uploadInvoiceEndPoint:U,authParams:it,isAdmin:oe,signedInUser:ne,showApproveRejectBtns:le,isRealTimeApprovalEnabled:se,isReimbursementCommentingEnabled:u,isShowDeletedReimbursementEnabled:de,isSignedInUserReimbursementCreator:at,updateEditRealTimeApproverClicked:ce,onSaveRealTimeApprovals:me,redirectToReimbursementListScreen:V,redirectToEditableReimbursementScreen:rt,onDuplicateLineClick:ot,approveOrRejectRemi:pe,deleteReimbursement:nt,cancelAndDeleteReport:ue,handleZeniLogoClick:lt,onAddNewRule:he})=>{const d=Mt(),st=Rt().analytics,o=Pt(),ye=Bt(),[dt,k]=p.useState(!1),[G,Y]=p.useState(!1),[ct,H]=p.useState(!1),[q,J]=p.useState("approved"),P=p.useRef(null),[S,Q]=p.useState({title:"",description:"",primaryButtonText:"",secondaryButtonText:""}),[C,mt]=p.useState(null),[pt,B]=p.useState(!1),h=`dashboard_${d.currentTenant?.companyId}`,ge=p.useRef({}),be=l=>{const n=ge.current[l];n!=null&&setTimeout(()=>li(n,P.current),100)};p.useEffect(()=>{(e.deleteStatus.fetchState==="Completed"||e.approvalUpdateStatus.fetchState==="Completed"||e.cancelAndDeleteStatus.fetchState==="Completed")&&V()},[e,V]),p.useEffect(()=>{const l=window.location.hash;if(l&&l.startsWith("#L")){const n=l.substring(1);be(n)}},[]);const ut=()=>{V()};Nt({componentName:"reimbursement.details"});const ht={onOkClick:()=>{k(!1),S.primaryButtonText===i.buttons.delete?nt?.():S.title===i.cancelReportTitle?ue?.():S.title===i.cancelAndDeleteReportTitle&&ue?.(!0)},onCancelClick:()=>{k(!1)}},D=s.labelWidth.value(o),z=s.largeLabelWidth.value(o),we=Ze.getLocalizedStrings(),{common:{texts:{comments:yt},strings:{empty:xe}},collaboration:{threads:{placeholder:{addANewComment:gt,replyAComment:bt},tooltip:{resolveComment:wt,unResolveComment:xt}}},dateFormat:fe}=we,{reimbursementDetail:i,bulkActions:N}=we.spendManagement.reimbursement,X=e.remiDetails?.reportTitle,j=e.remiDetails?.lines??[],L=e.remiDetails?.reimbursementInfo.stage,O=e.remiDetails?.reimbursementInfo.billStatus,_=e.remiDetails?.reimbursementInfo.billPaymentStatus,$e=L?.code==="paid",ft=$e?L:O?.code=="approved"&&_?.code?_:O,$=di(e.remiDetails),A=O?.code=="approved"&&_?.code?_:O,W=e.remiDetails?.isDeleted??!1,ve=e.remiDetails?.amount,Te=e.remiDetails?.amount.amount??0,je=()=>{Q({title:e.remiDetails?.reimbursementInfo.stage.code==="draft"?i.deleteDraftTitle:i.deleteReportTitle,description:i.deleteAlertDescription,primaryButtonText:i.buttons.delete,secondaryButtonText:i.buttons.cancel}),k(!0)},$t=()=>{Q({title:i.cancelReportTitle,description:i.cancelAlertDescription,primaryButtonText:i.buttons.yes,secondaryButtonText:i.buttons.no}),k(!0)},vt=()=>{Q({title:i.cancelAndDeleteReportTitle,description:i.cancelAndDeleteAlertDescription,primaryButtonText:i.buttons.yes,secondaryButtonText:i.buttons.no}),k(!0)},Se=()=>{rt()},Tt={onOkClick:l=>{H(!1),pe({reimbursementId:e.remiDetails?.id??"",type:"rejected",description:l})},onCancelClick:()=>{H(!1)}},jt=()=>{e.remiDetails?.reimbursementInfo.billStatus.code==="rejected"?Se():(J("approved"),pe({reimbursementId:e.remiDetails?.id??"",type:"approved"}))},St=()=>{e.remiDetails?.reimbursementInfo.billStatus.code==="rejected"?(J("delete"),je()):(J("rejected"),H(!0))},Dt=e.remiDetails?.reimbursementInfo.paymentDate!=null?ie.zeniDate(ie.getNextNthWorkingDay(e.remiDetails.reimbursementInfo.paymentDate.toDate(),[0,6],e.achSameDayMaxDays).toDateString()):void 0,Z=e.remiDetails?.reimbursementInfo.expectedDepositDate??Dt,It=e.remiDetails?.lines?.some(l=>{const n=l.lineDetail;return n?.account?.isDeleted===!0&&n?.account?.isBillEditableCoaAccountType===!1})??!1,De=e.remiDetails?.reimbursementInfo.billStatus.code==="pending_approval"&&at&&!It,Ct=e.remiDetails?.reimbursementInfo.billStatus.code!=="rejected"&&e.remiDetails?.reimbursementInfo.billPaymentStatus.code!=="paid",ee=ft?.code,kt=ni(e.duplicateLineByLineId),Ie=e.duplicateReimbursementStatus.fetchState==="Completed"&&kt>0,{requestToOpenThread:te,setRequestToOpenThread:Ce,setOpenThread:E}=p.useContext(Lt),{threads:M,isLoading:I}=Ot({application:"dashboard",companyId:d.currentTenant?.companyId,tab:"reimbursement",entityId:e.remiDetails?.id,isGlobalComment:!1},"both",!1),zt=p.useMemo(()=>M.filter(l=>l.resolved===!1&&!l.id.includes(_t)),[M]).length,At=p.useCallback((l,n)=>{E(n),B(!1)},[E,B]);p.useEffect(()=>{te?.threadId!=null&&M.length>0&&!I&&(E(te.threadId),Ce(null))},[te,M,I,E,Ce]);const g={application:"dashboard",companyId:d.currentTenant?.companyId,tab:"reimbursement",entityId:e.remiDetails?.id},R=ie.isBulkProcessing(e.remiDetails?.bulkProcessingDetail?.type);return t.jsxs(Ni,{windowSize:o,ref:P,children:[dt?t.jsx(ze,{titleComponent:t.jsx(Me,{children:S.title}),descriptionComponent:t.jsx(Ae,{children:S.description}),primaryButtonText:S.primaryButtonText,proceedButtonVariant:"danger",secondaryButtonText:S.secondaryButtonText,action:ht}):null,ct?t.jsx(ze,{titleComponent:t.jsx(Me,{children:`${i.rejectRemiTitlePrefix} ${e.remiDetails?.reportTitle??""} by ${e.createdBy?.firstName??""} ${e.createdBy?.lastName??""}`}),descriptionComponent:t.jsx(Ae,{children:i.rejectRemiDescription}),primaryButtonText:i.buttons.send,secondaryButtonText:i.buttons.cancel,action:Tt,isEditPopup:!0,isNotesIncluded:!0,notesPlaceholder:i.rejectRejectReasonPlaceholder}):null,t.jsxs(ki,{windowSize:o,"data-testid":y("reimbursement-detail-page-nav-bar-container"),children:[o!=="small"?t.jsx(Re,{"data-testid":y("reimbursement-detail-page-nav-bar-left"),style:{width:"42%"},title:"",leftSideComponent:t.jsx(zi,{onClick:()=>lt?.(),"data-testid":y("remi-detail-page-nav-bar-zeni-logo")}),enableTitleOnScroll:!1,backgroundColor:ye.colors.background,keepBackgroundOnScroll:!0,scrollableContent:P,source:"ReimbursementDetailPage"}):null,o!=="small"?t.jsx(Di,{}):null,t.jsx(Re,{"data-testid":y("reimbursement-detail-page-nav-bar-right"),title:X??xe,leftSideComponent:t.jsx(t.Fragment,{}),style:{width:o!=="small"?"58%":"100%"},rightSideComponent:t.jsxs(Mi,{children:[u?t.jsxs(Ri,{isDisabled:I,onClick:I?()=>null:l=>{l.preventDefault(),l.stopPropagation(),mt({roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityType:"reimbursement.details",entityId:e.remiDetails?.id??""}),B(!0),st.trackCommentActivity("reimbursement","clicked",d.currentTenant?.companyName??"",d.controllersList.controllers.map(n=>Et(n)),void 0,void 0,"page icon")},"data-testid":y("remi-comments-section"),children:[t.jsx(Wt,{count:I?void 0:zt,isLoading:I,style:{left:"12px"}}),t.jsx(Pi,{})]}):null,t.jsx(Bi,{size:o,onClick:()=>ut(),"data-testid":y("remi-detail-page-close"),children:t.jsx(Ai,{})})]}),scrollableContent:P,enableTitleOnScroll:o!=="small",scrollThreshold:64,source:"ReimbursementDetailPage"})]}),t.jsxs(Ki,{children:[o==="small"?t.jsxs(t.Fragment,{children:[t.jsx(He,{windowSize:o,children:t.jsx(qe,{windowsSize:o,children:X})}),e.createdBy?.userId!=null?t.jsx(Ue,{windowSize:o,children:`${i.by} ${e.createdBy.firstName} ${e.createdBy.lastName}`}):null,de&&$!=null?t.jsx(Ve,{color:$.color,bgColor:$.bgColor,borderColor:$.borderColor,children:$.value}):null,A?.code!=null?o==="small"?t.jsxs(t.Fragment,{children:[t.jsx(Ft,{progressSectionObj:A,createDate:e.remiDetails?.createTime,paymentDate:Z,scheduleDate:e.remiDetails?.reimbursementInfo.paymentDate,approvedDate:e.latestApprovedDate,isFrozen:W}),R?t.jsx(Pe,{variant:"warning",style:{margin:`${a.sp5} ${a.sp3}`},title:N.duplicateWarning.title,description:N.duplicateWarning.description}):Ie?t.jsxs(_e,{size:o,children:[t.jsx(Ke,{}),t.jsxs(Ee,{children:[t.jsx(We,{children:i.thereSeems}),t.jsx(Fe,{children:i.pleaseFind})]})]}):null]}):t.jsx(Ye,{windowSize:o,children:t.jsx(Be,{progressSectionObj:A,createDate:e.remiDetails?.createTime,paymentDate:Z,scheduleDate:e.remiDetails?.reimbursementInfo.paymentDate,approvedDate:e.latestApprovedDate,isFrozen:W})}):null]}):null,j.map((l,n)=>{const v=e.duplicateLineByLineId[l.lineId];return t.jsxs(Xe,{windowSize:o,children:[t.jsx(Wi,{windowSize:o,children:t.jsx(Ei,{bottomSeperator:j.length!==1,windowSize:o,children:t.jsx(oi,{showAutofill:!1,uploadInvoiceEndPoint:U,authParams:it,entityId:e.remiDetails?.id,file:l.file,showTitlebar:!0,showTitlebarIcon:!1,pdfTitle:j.length>1?`#${n+1} Receipt`:"Receipt",style:{width:"auto",padding:0,height:j.length-1===n||n===0?760:451},onInvoiceUpload:()=>{console.log("onInvoiceUpload")},noAttachmentText:i.noReceiptAttached,type:"reimbursement"})})}),t.jsxs(_i,{windowSize:o,children:[n===0&&o!=="small"?t.jsxs(t.Fragment,{children:[t.jsxs(He,{windowSize:o,children:[t.jsx(qe,{windowsSize:o,children:X}),de&&$!=null?t.jsx(Ve,{color:$.color,bgColor:$.bgColor,borderColor:$.borderColor,children:$.value}):null]}),e.createdBy?.userId!=null?t.jsx(Ue,{windowSize:o,children:`By ${e.createdBy.firstName} ${e.createdBy.lastName}`}):null,A?.code!=null?t.jsx(Ye,{windowSize:o,children:t.jsx(Be,{progressSectionObj:A,createDate:e.remiDetails?.createTime,paymentDate:Z,scheduleDate:e.remiDetails?.reimbursementInfo.paymentDate,approvedDate:e.latestApprovedDate,isFrozen:W})}):null,R?t.jsx(Pe,{variant:"warning",style:{margin:`${a.sp3} ${a.sp8} ${a.sp3} ${a.sp6}`},title:N.duplicateWarning.title,description:N.duplicateWarning.description}):Ie?t.jsxs(_e,{size:o,children:[t.jsx(Ke,{}),t.jsxs(Ee,{children:[t.jsx(We,{children:i.thereSeems}),t.jsx(Fe,{children:i.pleaseFind})]})]}):null]}):null,t.jsxs(yi,{windowSize:o,ref:ke=>{ke!=null&&(ge.current[`L${l.lineId}`]=ke)},children:[o!=="small"?t.jsx(hi,{children:t.jsx(gi,{children:j.length>1?`#${n+1} ${i.reimbursement}`:i.reimbursement})}):null,t.jsxs(bi,{windowSize:o,children:[v?.duplicateLineId!=null?t.jsxs(pi,{children:[i.thisExpenseReview," ",t.jsx(ui,{onClick:()=>{if(v.isDuplicateWithinTransaction&&v.duplicateLineId!=null)return be(`L${v.duplicateLineId}`);v.duplicateTransactionId!=null&&v.duplicateLineId!=null&&ot(v.duplicateTransactionId,v.duplicateLineId)},"data-testid":y("remi-view-duplicate-expense"),children:i.viewOriginalExpense})]}):null,t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:l.type===i.mileageKey?`${n}.mileage.reimbursementType`:`${n}.out_of_pocket.reimbursementType`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("reimbursementType",n,l.type===i.mileageKey?"mileage":"out_of_pocket")}`},style:{borderRadius:v?.duplicateLineId==null?`${a.sp2} ${a.sp2} 0 0`:"0 0 0 0"},children:t.jsx(x,{label:{label:i.reimbursementType,width:z},text:l.type===i.mileageKey?i.mileage:i.outOfPocket,style:{width:"auto",borderRadius:v?.duplicateLineId==null?`${a.sp2} ${a.sp2} 0 0`:"0 0 0 0"}})}),t.jsx(T,{}),l.type===i.mileageKey?t.jsxs(t.Fragment,{children:[t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.mileage.transactionDate`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("transactionDate",n,"mileage")}`},children:t.jsx(x,{label:{label:i.transactionDate,width:z},text:l.transactionDate?.format(fe.visual.MMMDCommaYYYYformat)??i.emptyValue,style:{width:"auto"}})}),t.jsx(T,{}),t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.mileage.distanceInMiles`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("distanceInMiles",n,"mileage")}`},children:t.jsx(x,{label:{label:i.distanceInMiles,width:z},text:l.distanceMileage.value.toString()??i.emptyValue,style:{width:"auto"}})}),t.jsx(T,{}),t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.mileage.amount`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("amount",n,"mileage")}`},children:t.jsx(x,{label:{label:i.amount,width:D},text:l.homeCurrencyConversions!=null?Ne("0,0[.]00",l.homeCurrencyConversions):i.emptyValue,style:{width:"auto"}})}),t.jsx(T,{}),t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.mileage.memo`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("memo",n,"mileage")}`},children:t.jsx(x,{label:{label:i.memo,width:D},text:l.description??i.emptyValue,style:{width:"auto"}})}),t.jsx(T,{}),t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.mileage.class`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("class",n,"mileage")}`},style:{borderRadius:`0 0 ${a.sp2} ${a.sp2}`},children:t.jsx(x,{label:{label:i.department,width:D},text:l.lineDetail.class?.className??i.emptyValue,style:{width:"auto",borderRadius:`0 0 ${a.sp2} ${a.sp2}`}})})]}):t.jsxs(t.Fragment,{children:[t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.out_of_pocket.merchant`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("merchant",n,"out_of_pocket")}`},children:t.jsx(x,{label:{label:i.merchant,width:z},text:l.merchant?.name??i.emptyValue,style:{width:"auto"}})}),t.jsx(T,{}),t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.out_of_pocket.transactionDate`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("transactionDate",n,"out_of_pocket")}`},children:t.jsx(x,{label:{label:i.transactionDate,width:z},text:l.transactionDate?.format(fe.visual.MMMDCommaYYYYformat)??i.emptyValue,style:{width:"auto"}})}),t.jsx(T,{}),t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.out_of_pocket.amount`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("amount",n,"out_of_pocket")}`},children:t.jsx(x,{label:{label:i.amount,width:D},text:l.homeCurrencyConversions!=null?Ne("0,0[.]00",l.homeCurrencyConversions):i.emptyValue,style:{width:"auto"}})}),t.jsx(T,{}),t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.out_of_pocket.memo`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("memo",n,"out_of_pocket")}`},children:t.jsx(x,{label:{label:i.memo,width:D},text:l.description??i.emptyValue,style:{width:"auto"}})}),t.jsx(T,{}),t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.out_of_pocket.account`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("account",n,"out_of_pocket")}`},children:t.jsx(x,{label:{label:i.category,width:D},text:l.lineDetail.account?.accountName??i.emptyValue,style:{width:"auto"}})}),t.jsx(T,{}),t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.out_of_pocket.class`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("class",n,"out_of_pocket")}`},style:{borderRadius:`0 0 ${a.sp2} ${a.sp2}`},children:t.jsx(x,{label:{label:i.department,width:D},text:l.lineDetail.class?.className??i.emptyValue,style:{width:"auto",borderRadius:`0 0 ${a.sp2} ${a.sp2}`}})})]})]})]}),j.length!==1&&j.length===n+1&&t.jsxs(Oi,{windowSize:o,children:[t.jsxs(Je,{windowSize:o,children:[t.jsx(Qe,{children:i.total}),t.jsx(Le,{amount:ve,integerStyles:F.h6Regular.cssObject,decimalStyles:F.standardRegular.cssObject})]}),e.remiDetails&&t.jsx(Oe,{amount:Te,activities:e.remiActivities,stage:L?.code??"draft",onAddNewRule:he,entity:"reimbursement",realTimeApproval:{allApprovers:e.filteredApprovers,filteredAttributes:e.filteredAttributes,allAccountingClass:e.allAccountingClasses,isRealTimeApproverEditMode:e.realTimeApproval.isEditMode??!1,realTimeApprovalSaveStatus:{fetchState:e.realTimeApproval.fetchState,error:e.realTimeApproval.error},approvalListFetchState:e.approverListFetchState.fetchState,attributeSubTypeToUserIdMapping:e.attributeSubTypeToUserIdMapping,isAdmin:oe,signedInUserId:ne?.userId,showRealTimeApproval:se,entityApprovalId:e.remiActivities[0]?.entityApprovalId??e.remiDetails.entityApprovalId,updateEditMode:ce,onSaveRealTimeApprovals:me},historicActivities:e.remiHistory.activities})]})]})]},l.lineId)}),j.length===1&&t.jsxs(Xe,{windowSize:o,children:[t.jsx(Ge,{}),t.jsxs(ci,{windowSize:o,children:[t.jsx(Li,{windowSize:o,children:t.jsxs(Je,{windowSize:o,children:[t.jsx(Qe,{children:i.total}),t.jsx(Le,{amount:ve,integerStyles:F.h6Regular.cssObject,decimalStyles:F.standardRegular.cssObject})]})}),e.remiDetails&&t.jsx(mi,{windowSize:o,children:t.jsx(Oe,{amount:Te,activities:e.remiActivities,stage:L?.code??"draft",onAddNewRule:he,entity:"reimbursement",historicActivities:e.remiHistory.activities,realTimeApproval:{allApprovers:e.filteredApprovers,allAccountingClass:e.allAccountingClasses,filteredAttributes:e.filteredAttributes,isRealTimeApproverEditMode:e.realTimeApproval.isEditMode??!1,realTimeApprovalSaveStatus:{fetchState:e.realTimeApproval.fetchState,error:e.realTimeApproval.error},approvalListFetchState:e.approverListFetchState.fetchState,attributeSubTypeToUserIdMapping:e.attributeSubTypeToUserIdMapping,isAdmin:oe,signedInUserId:ne?.userId,showRealTimeApproval:se,entityApprovalId:e.remiActivities[0]?.entityApprovalId??e.remiDetails.entityApprovalId,updateEditMode:ce,onSaveRealTimeApprovals:me}})})]})]}),t.jsx(Fi,{})]}),$e||W===!0?null:t.jsxs(Ci,{children:[o!=="small"?t.jsx(Ge,{}):null,t.jsx(xi,{windowSize:o,"data-testid":y("remi-detail-page-footer"),onClick:l=>{l.stopPropagation(),G===!0&&Y(!1)},children:t.jsx(Kt,{separatorStyle:{marginRight:a.sp4},showPrimaryButton:e.remiDetails?.reimbursementInfo.billStatus.code==="rejected"||le,showCancel:e.remiDetails?.reimbursementInfo.billStatus.code==="rejected"||le,cancelBtn:{label:e.remiDetails?.reimbursementInfo.billStatus.code==="rejected"?o==="small"?i.buttons.delete:i.buttons.deleteReport:o==="small"?i.buttons.reject:i.buttons.rejectReport,isLoading:q==="rejected"&&e.approvalUpdateStatus.fetchState==="In-Progress"||q==="delete"&&e.deleteStatus.fetchState==="In-Progress",onClick:St,style:{width:s.footerButtonWidth.value(o)},reverseSpinnerColor:!1},primaryBtn:{label:e.remiDetails?.reimbursementInfo.billStatus.code==="rejected"?o==="small"?i.buttons.edit:i.buttons.editAndResubmit:o==="small"?i.buttons.approve:i.buttons.approveReport,isLoading:q==="approved"&&e.approvalUpdateStatus.fetchState==="In-Progress",onClick:jt,style:{width:s.footerButtonWidth.value(o)},isDisabled:e.approvalUpdateStatus.fetchState==="In-Progress"||e.realTimeApproval.isEditMode===!0},rightSideComponent:t.jsx(wi,{children:t.jsxs(Ii,{windowSize:o,children:[!R&&G?t.jsx(Ut,{onClickAway:()=>Y(!1),children:t.jsxs(Si,{windowSize:o,children:[ee!=="processing"?t.jsx(re,{onClick:je,"data-testid":y("remi-delete-action"),children:i.buttons.deleteReport}):null,ee==="processing"?t.jsx(re,{onClick:$t,"data-testid":y("remi-cancel-action"),children:i.buttons.cancel}):null,ee==="processing"?t.jsx(re,{onClick:vt,"data-testid":y("remi-cancel-and-delete-action"),children:i.buttons.cancelAndDelete}):null]})}):null,t.jsxs(ji,{windowSize:o,children:[!R&&De?t.jsx(Ti,{onClick:Se,"data-testid":y("remi-edit-button"),children:t.jsx(vi,{})}):null,!R&&Ct===!0?t.jsx($i,{windowSize:o,showEditIcon:De,children:t.jsx(fi,{onClick:()=>Y(!G),"data-testid":y("remi-more-actions-button")})}):null]})]})}),style:{minHeight:62}})})]}),u?t.jsx(ri,{id:h,children:t.jsx(Vt,{isDrawerOpen:pt,allowComposer:!0,drawerTitle:yt,threads:M,autoExpand:!0,autoFocus:!1,filter:{application:"dashboard",companyId:C?.companyId??xe,isGlobalComment:!1,tab:"reimbursement"},isLoading:I,threadMetadata:C?{companyName:C.companyName,companyId:C.companyId,entityId:C.entityId,entityType:C.entityType,isGlobalComment:!1,application:"dashboard",tab:"reimbursement",url:window.location.href}:void 0,textOverrides:{composerPlaceholder:gt,replyComposerPlaceholder:bt,threadResolve:wt,threadUnResolve:xt},onThreadClick:(l,n)=>At(l,n),onCloseAllThreadsDrawer:()=>B(!1),drawerSectionStyle:{width:"400px",backgroundColor:ye.colors.background}})}):null]})},di=e=>{const U=Ze.getLocalizedStrings().spendManagement.billPay.billsByTabs;if(e?.isDeleted===!0)return{value:U.tabsById.deleted,color:ae.deleted.color,bgColor:ae.deleted.bgColor,borderColor:ae.deleted.borderColor,code:"deleted"}},ci=r.div`
1
+ import{ax as Mt,a9 as Rt,q as Pt,d as Bt,cr as Nt,y as m,O as Ze,l as ie,gr as Lt,gt as Ot,gu as _t,j as t,cD as ze,cE as Ae,cF as Me,aM as y,bF as Re,bs as Wt,dN as Et,gv as Ft,gG as Pe,o as a,gw as Be,fu as b,fw as w,gz as x,aN as Ne,ft as Le,C as F,gB as Oe,aQ as Kt,ap as Ut,gC as Vt,gD as ae,bB as Gt,gE as Yt,A as Ht,c as qt,H as Jt,am as et,b8 as tt,h as K,an as Qt,c7 as Xt,ai as Zt,gV as ei,gR as ti,u as c,cw as ii,d8 as ai}from"./index-sAOH0Fje.js";import{b as p,n as r}from"./vendor-Bs1fkIUX.js";import{_ as ri}from"./liveblocks-8ht9CoL5.js";import oi from"./InvoiceUploadSection-DoR834b4-BezkawDL.js";import{r as ni,h as f,u as li}from"./types-DyvtCprH-BcZYcgaq.js";import"./mui-Ty75qFQF.js";import"./analytics-CcevxdRy.js";import"./routing-Dk1A2KYI.js";import"./sentry-BE5FTzpq.js";import"./redux-CEhZD0hA.js";import"./crypto-cQYYQPTZ.js";import"./AttachmentView-DhluaeAV-DnrJUkr5.js";import"./uploadReceipts-Dp1dvCjf-Bw0_dVvQ.js";const s={labelWidth:new m(120,160,160),largeLabelWidth:new m(150,235,235),rightMargin:new m(c[3],c[8]),leftMargin:new m(c[3],c[6]),invoiceRightMargin:new m(c[3],c[6]),invoiceLeftMargin:new m(c[3],c[8]),topMargin:new m(c[3],0),bottomMargin:new m(c[4],27),activityBottomMargin:new m(96,0),totalBottomMargin:new m(c[5],c[3]),formBottomMargin:new m(c[5],c[3]),navBarHeight:new m(44,62),closeMarginTop:new m(0,0),rightSectionWidth:new m(100,58),leftSectionWidth:new m(100,42),footerButtonWidth:new m(120,165),right:new m(c[3],c[0]),actionsContainerRight:new m(c[0],c[6]),otherActionsContainerBottom:new m(58,44),duplicateBannerWrapperMarginTop:new m(c[5],c[3]),duplicateBannerWrapperMarginRight:new m(c[3],c[8]),duplicateBannerWrapperMarginBottom:new m(c[5],c[3]),duplicateBannerWrapperMarginLeft:new m(c[3],c[6])},si={formTitle:new qt("h6Regular","h5Regular")},aa=({remiDetails:e,uploadInvoiceEndPoint:U,authParams:it,isAdmin:oe,signedInUser:ne,showApproveRejectBtns:le,isRealTimeApprovalEnabled:se,isReimbursementCommentingEnabled:u,isShowDeletedReimbursementEnabled:de,isSignedInUserReimbursementCreator:at,updateEditRealTimeApproverClicked:ce,onSaveRealTimeApprovals:me,redirectToReimbursementListScreen:V,redirectToEditableReimbursementScreen:rt,onDuplicateLineClick:ot,approveOrRejectRemi:pe,deleteReimbursement:nt,cancelAndDeleteReport:ue,handleZeniLogoClick:lt,onAddNewRule:he})=>{const d=Mt(),st=Rt().analytics,o=Pt(),ye=Bt(),[dt,k]=p.useState(!1),[G,Y]=p.useState(!1),[ct,H]=p.useState(!1),[q,J]=p.useState("approved"),P=p.useRef(null),[S,Q]=p.useState({title:"",description:"",primaryButtonText:"",secondaryButtonText:""}),[C,mt]=p.useState(null),[pt,B]=p.useState(!1),h=`dashboard_${d.currentTenant?.companyId}`,ge=p.useRef({}),be=l=>{const n=ge.current[l];n!=null&&setTimeout(()=>li(n,P.current),100)};p.useEffect(()=>{(e.deleteStatus.fetchState==="Completed"||e.approvalUpdateStatus.fetchState==="Completed"||e.cancelAndDeleteStatus.fetchState==="Completed")&&V()},[e,V]),p.useEffect(()=>{const l=window.location.hash;if(l&&l.startsWith("#L")){const n=l.substring(1);be(n)}},[]);const ut=()=>{V()};Nt({componentName:"reimbursement.details"});const ht={onOkClick:()=>{k(!1),S.primaryButtonText===i.buttons.delete?nt?.():S.title===i.cancelReportTitle?ue?.():S.title===i.cancelAndDeleteReportTitle&&ue?.(!0)},onCancelClick:()=>{k(!1)}},D=s.labelWidth.value(o),z=s.largeLabelWidth.value(o),we=Ze.getLocalizedStrings(),{common:{texts:{comments:yt},strings:{empty:xe}},collaboration:{threads:{placeholder:{addANewComment:gt,replyAComment:bt},tooltip:{resolveComment:wt,unResolveComment:xt}}},dateFormat:fe}=we,{reimbursementDetail:i,bulkActions:N}=we.spendManagement.reimbursement,X=e.remiDetails?.reportTitle,j=e.remiDetails?.lines??[],L=e.remiDetails?.reimbursementInfo.stage,O=e.remiDetails?.reimbursementInfo.billStatus,_=e.remiDetails?.reimbursementInfo.billPaymentStatus,$e=L?.code==="paid",ft=$e?L:O?.code=="approved"&&_?.code?_:O,$=di(e.remiDetails),A=O?.code=="approved"&&_?.code?_:O,W=e.remiDetails?.isDeleted??!1,ve=e.remiDetails?.amount,Te=e.remiDetails?.amount.amount??0,je=()=>{Q({title:e.remiDetails?.reimbursementInfo.stage.code==="draft"?i.deleteDraftTitle:i.deleteReportTitle,description:i.deleteAlertDescription,primaryButtonText:i.buttons.delete,secondaryButtonText:i.buttons.cancel}),k(!0)},$t=()=>{Q({title:i.cancelReportTitle,description:i.cancelAlertDescription,primaryButtonText:i.buttons.yes,secondaryButtonText:i.buttons.no}),k(!0)},vt=()=>{Q({title:i.cancelAndDeleteReportTitle,description:i.cancelAndDeleteAlertDescription,primaryButtonText:i.buttons.yes,secondaryButtonText:i.buttons.no}),k(!0)},Se=()=>{rt()},Tt={onOkClick:l=>{H(!1),pe({reimbursementId:e.remiDetails?.id??"",type:"rejected",description:l})},onCancelClick:()=>{H(!1)}},jt=()=>{e.remiDetails?.reimbursementInfo.billStatus.code==="rejected"?Se():(J("approved"),pe({reimbursementId:e.remiDetails?.id??"",type:"approved"}))},St=()=>{e.remiDetails?.reimbursementInfo.billStatus.code==="rejected"?(J("delete"),je()):(J("rejected"),H(!0))},Dt=e.remiDetails?.reimbursementInfo.paymentDate!=null?ie.zeniDate(ie.getNextNthWorkingDay(e.remiDetails.reimbursementInfo.paymentDate.toDate(),[0,6],e.achSameDayMaxDays).toDateString()):void 0,Z=e.remiDetails?.reimbursementInfo.expectedDepositDate??Dt,It=e.remiDetails?.lines?.some(l=>{const n=l.lineDetail;return n?.account?.isDeleted===!0&&n?.account?.isBillEditableCoaAccountType===!1})??!1,De=e.remiDetails?.reimbursementInfo.billStatus.code==="pending_approval"&&at&&!It,Ct=e.remiDetails?.reimbursementInfo.billStatus.code!=="rejected"&&e.remiDetails?.reimbursementInfo.billPaymentStatus.code!=="paid",ee=ft?.code,kt=ni(e.duplicateLineByLineId),Ie=e.duplicateReimbursementStatus.fetchState==="Completed"&&kt>0,{requestToOpenThread:te,setRequestToOpenThread:Ce,setOpenThread:E}=p.useContext(Lt),{threads:M,isLoading:I}=Ot({application:"dashboard",companyId:d.currentTenant?.companyId,tab:"reimbursement",entityId:e.remiDetails?.id,isGlobalComment:!1},"both",!1),zt=p.useMemo(()=>M.filter(l=>l.resolved===!1&&!l.id.includes(_t)),[M]).length,At=p.useCallback((l,n)=>{E(n),B(!1)},[E,B]);p.useEffect(()=>{te?.threadId!=null&&M.length>0&&!I&&(E(te.threadId),Ce(null))},[te,M,I,E,Ce]);const g={application:"dashboard",companyId:d.currentTenant?.companyId,tab:"reimbursement",entityId:e.remiDetails?.id},R=ie.isBulkProcessing(e.remiDetails?.bulkProcessingDetail?.type);return t.jsxs(Ni,{windowSize:o,ref:P,children:[dt?t.jsx(ze,{titleComponent:t.jsx(Me,{children:S.title}),descriptionComponent:t.jsx(Ae,{children:S.description}),primaryButtonText:S.primaryButtonText,proceedButtonVariant:"danger",secondaryButtonText:S.secondaryButtonText,action:ht}):null,ct?t.jsx(ze,{titleComponent:t.jsx(Me,{children:`${i.rejectRemiTitlePrefix} ${e.remiDetails?.reportTitle??""} by ${e.createdBy?.firstName??""} ${e.createdBy?.lastName??""}`}),descriptionComponent:t.jsx(Ae,{children:i.rejectRemiDescription}),primaryButtonText:i.buttons.send,secondaryButtonText:i.buttons.cancel,action:Tt,isEditPopup:!0,isNotesIncluded:!0,notesPlaceholder:i.rejectRejectReasonPlaceholder}):null,t.jsxs(ki,{windowSize:o,"data-testid":y("reimbursement-detail-page-nav-bar-container"),children:[o!=="small"?t.jsx(Re,{"data-testid":y("reimbursement-detail-page-nav-bar-left"),style:{width:"42%"},title:"",leftSideComponent:t.jsx(zi,{onClick:()=>lt?.(),"data-testid":y("remi-detail-page-nav-bar-zeni-logo")}),enableTitleOnScroll:!1,backgroundColor:ye.colors.background,keepBackgroundOnScroll:!0,scrollableContent:P,source:"ReimbursementDetailPage"}):null,o!=="small"?t.jsx(Di,{}):null,t.jsx(Re,{"data-testid":y("reimbursement-detail-page-nav-bar-right"),title:X??xe,leftSideComponent:t.jsx(t.Fragment,{}),style:{width:o!=="small"?"58%":"100%"},rightSideComponent:t.jsxs(Mi,{children:[u?t.jsxs(Ri,{isDisabled:I,onClick:I?()=>null:l=>{l.preventDefault(),l.stopPropagation(),mt({roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityType:"reimbursement.details",entityId:e.remiDetails?.id??""}),B(!0),st.trackCommentActivity("reimbursement","clicked",d.currentTenant?.companyName??"",d.controllersList.controllers.map(n=>Et(n)),void 0,void 0,"page icon")},"data-testid":y("remi-comments-section"),children:[t.jsx(Wt,{count:I?void 0:zt,isLoading:I,style:{left:"12px"}}),t.jsx(Pi,{})]}):null,t.jsx(Bi,{size:o,onClick:()=>ut(),"data-testid":y("remi-detail-page-close"),children:t.jsx(Ai,{})})]}),scrollableContent:P,enableTitleOnScroll:o!=="small",scrollThreshold:64,source:"ReimbursementDetailPage"})]}),t.jsxs(Ki,{children:[o==="small"?t.jsxs(t.Fragment,{children:[t.jsx(He,{windowSize:o,children:t.jsx(qe,{windowsSize:o,children:X})}),e.createdBy?.userId!=null?t.jsx(Ue,{windowSize:o,children:`${i.by} ${e.createdBy.firstName} ${e.createdBy.lastName}`}):null,de&&$!=null?t.jsx(Ve,{color:$.color,bgColor:$.bgColor,borderColor:$.borderColor,children:$.value}):null,A?.code!=null?o==="small"?t.jsxs(t.Fragment,{children:[t.jsx(Ft,{progressSectionObj:A,createDate:e.remiDetails?.createTime,paymentDate:Z,scheduleDate:e.remiDetails?.reimbursementInfo.paymentDate,approvedDate:e.latestApprovedDate,isFrozen:W}),R?t.jsx(Pe,{variant:"warning",style:{margin:`${a.sp5} ${a.sp3}`},title:N.duplicateWarning.title,description:N.duplicateWarning.description}):Ie?t.jsxs(_e,{size:o,children:[t.jsx(Ke,{}),t.jsxs(Ee,{children:[t.jsx(We,{children:i.thereSeems}),t.jsx(Fe,{children:i.pleaseFind})]})]}):null]}):t.jsx(Ye,{windowSize:o,children:t.jsx(Be,{progressSectionObj:A,createDate:e.remiDetails?.createTime,paymentDate:Z,scheduleDate:e.remiDetails?.reimbursementInfo.paymentDate,approvedDate:e.latestApprovedDate,isFrozen:W})}):null]}):null,j.map((l,n)=>{const v=e.duplicateLineByLineId[l.lineId];return t.jsxs(Xe,{windowSize:o,children:[t.jsx(Wi,{windowSize:o,children:t.jsx(Ei,{bottomSeperator:j.length!==1,windowSize:o,children:t.jsx(oi,{showAutofill:!1,uploadInvoiceEndPoint:U,authParams:it,entityId:e.remiDetails?.id,file:l.file,showTitlebar:!0,showTitlebarIcon:!1,pdfTitle:j.length>1?`#${n+1} Receipt`:"Receipt",style:{width:"auto",padding:0,height:j.length-1===n||n===0?760:451},onInvoiceUpload:()=>{console.log("onInvoiceUpload")},noAttachmentText:i.noReceiptAttached,type:"reimbursement"})})}),t.jsxs(_i,{windowSize:o,children:[n===0&&o!=="small"?t.jsxs(t.Fragment,{children:[t.jsxs(He,{windowSize:o,children:[t.jsx(qe,{windowsSize:o,children:X}),de&&$!=null?t.jsx(Ve,{color:$.color,bgColor:$.bgColor,borderColor:$.borderColor,children:$.value}):null]}),e.createdBy?.userId!=null?t.jsx(Ue,{windowSize:o,children:`By ${e.createdBy.firstName} ${e.createdBy.lastName}`}):null,A?.code!=null?t.jsx(Ye,{windowSize:o,children:t.jsx(Be,{progressSectionObj:A,createDate:e.remiDetails?.createTime,paymentDate:Z,scheduleDate:e.remiDetails?.reimbursementInfo.paymentDate,approvedDate:e.latestApprovedDate,isFrozen:W})}):null,R?t.jsx(Pe,{variant:"warning",style:{margin:`${a.sp3} ${a.sp8} ${a.sp3} ${a.sp6}`},title:N.duplicateWarning.title,description:N.duplicateWarning.description}):Ie?t.jsxs(_e,{size:o,children:[t.jsx(Ke,{}),t.jsxs(Ee,{children:[t.jsx(We,{children:i.thereSeems}),t.jsx(Fe,{children:i.pleaseFind})]})]}):null]}):null,t.jsxs(yi,{windowSize:o,ref:ke=>{ke!=null&&(ge.current[`L${l.lineId}`]=ke)},children:[o!=="small"?t.jsx(hi,{children:t.jsx(gi,{children:j.length>1?`#${n+1} ${i.reimbursement}`:i.reimbursement})}):null,t.jsxs(bi,{windowSize:o,children:[v?.duplicateLineId!=null?t.jsxs(pi,{children:[i.thisExpenseReview," ",t.jsx(ui,{onClick:()=>{if(v.isDuplicateWithinTransaction&&v.duplicateLineId!=null)return be(`L${v.duplicateLineId}`);v.duplicateTransactionId!=null&&v.duplicateLineId!=null&&ot(v.duplicateTransactionId,v.duplicateLineId)},"data-testid":y("remi-view-duplicate-expense"),children:i.viewOriginalExpense})]}):null,t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:l.type===i.mileageKey?`${n}.mileage.reimbursementType`:`${n}.out_of_pocket.reimbursementType`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("reimbursementType",n,l.type===i.mileageKey?"mileage":"out_of_pocket")}`},style:{borderRadius:v?.duplicateLineId==null?`${a.sp2} ${a.sp2} 0 0`:"0 0 0 0"},children:t.jsx(x,{label:{label:i.reimbursementType,width:z},text:l.type===i.mileageKey?i.mileage:i.outOfPocket,style:{width:"auto",borderRadius:v?.duplicateLineId==null?`${a.sp2} ${a.sp2} 0 0`:"0 0 0 0"}})}),t.jsx(T,{}),l.type===i.mileageKey?t.jsxs(t.Fragment,{children:[t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.mileage.transactionDate`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("transactionDate",n,"mileage")}`},children:t.jsx(x,{label:{label:i.transactionDate,width:z},text:l.transactionDate?.format(fe.visual.MMMDCommaYYYYformat)??i.emptyValue,style:{width:"auto"}})}),t.jsx(T,{}),t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.mileage.distanceInMiles`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("distanceInMiles",n,"mileage")}`},children:t.jsx(x,{label:{label:i.distanceInMiles,width:z},text:l.distanceMileage.value.toString()??i.emptyValue,style:{width:"auto"}})}),t.jsx(T,{}),t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.mileage.amount`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("amount",n,"mileage")}`},children:t.jsx(x,{label:{label:i.amount,width:D},text:l.homeCurrencyConversions!=null?Ne("0,0[.]00",l.homeCurrencyConversions):i.emptyValue,style:{width:"auto"}})}),t.jsx(T,{}),t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.mileage.memo`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("memo",n,"mileage")}`},children:t.jsx(x,{label:{label:i.memo,width:D},text:l.description??i.emptyValue,style:{width:"auto"}})}),t.jsx(T,{}),t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.mileage.class`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("class",n,"mileage")}`},style:{borderRadius:`0 0 ${a.sp2} ${a.sp2}`},children:t.jsx(x,{label:{label:i.department,width:D},text:l.lineDetail.class?.className??i.emptyValue,style:{width:"auto",borderRadius:`0 0 ${a.sp2} ${a.sp2}`}})})]}):t.jsxs(t.Fragment,{children:[t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.out_of_pocket.merchant`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("merchant",n,"out_of_pocket")}`},children:t.jsx(x,{label:{label:i.merchant,width:z},text:l.merchant?.name??i.emptyValue,style:{width:"auto"}})}),t.jsx(T,{}),t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.out_of_pocket.transactionDate`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("transactionDate",n,"out_of_pocket")}`},children:t.jsx(x,{label:{label:i.transactionDate,width:z},text:l.transactionDate?.format(fe.visual.MMMDCommaYYYYformat)??i.emptyValue,style:{width:"auto"}})}),t.jsx(T,{}),t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.out_of_pocket.amount`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("amount",n,"out_of_pocket")}`},children:t.jsx(x,{label:{label:i.amount,width:D},text:l.homeCurrencyConversions!=null?Ne("0,0[.]00",l.homeCurrencyConversions):i.emptyValue,style:{width:"auto"}})}),t.jsx(T,{}),t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.out_of_pocket.memo`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("memo",n,"out_of_pocket")}`},children:t.jsx(x,{label:{label:i.memo,width:D},text:l.description??i.emptyValue,style:{width:"auto"}})}),t.jsx(T,{}),t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.out_of_pocket.account`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("account",n,"out_of_pocket")}`},children:t.jsx(x,{label:{label:i.category,width:D},text:l.lineDetail.account?.accountName??i.emptyValue,style:{width:"auto"}})}),t.jsx(T,{}),t.jsx(b,{isThreadAllowed:u,dashboardTabKey:w({type:"details",key:`${n}.out_of_pocket.class`}),roomId:h,companyId:d.currentTenant?.companyId??"",companyName:d.currentTenant?.companyName??"",entityId:e.remiDetails?.id??"",dashboardOptionType:"reimbursement",filterMetaData:{...g,entityType:`reimbursement.details.${f("class",n,"out_of_pocket")}`},style:{borderRadius:`0 0 ${a.sp2} ${a.sp2}`},children:t.jsx(x,{label:{label:i.department,width:D},text:l.lineDetail.class?.className??i.emptyValue,style:{width:"auto",borderRadius:`0 0 ${a.sp2} ${a.sp2}`}})})]})]})]}),j.length!==1&&j.length===n+1&&t.jsxs(Oi,{windowSize:o,children:[t.jsxs(Je,{windowSize:o,children:[t.jsx(Qe,{children:i.total}),t.jsx(Le,{amount:ve,integerStyles:F.h6Regular.cssObject,decimalStyles:F.standardRegular.cssObject})]}),e.remiDetails&&t.jsx(Oe,{amount:Te,activities:e.remiActivities,stage:L?.code??"draft",onAddNewRule:he,entity:"reimbursement",realTimeApproval:{allApprovers:e.filteredApprovers,filteredAttributes:e.filteredAttributes,allAccountingClass:e.allAccountingClasses,isRealTimeApproverEditMode:e.realTimeApproval.isEditMode??!1,realTimeApprovalSaveStatus:{fetchState:e.realTimeApproval.fetchState,error:e.realTimeApproval.error},approvalListFetchState:e.approverListFetchState.fetchState,attributeSubTypeToUserIdMapping:e.attributeSubTypeToUserIdMapping,isAdmin:oe,signedInUserId:ne?.userId,showRealTimeApproval:se,entityApprovalId:e.remiActivities[0]?.entityApprovalId??e.remiDetails.entityApprovalId,updateEditMode:ce,onSaveRealTimeApprovals:me},historicActivities:e.remiHistory.activities})]})]})]},l.lineId)}),j.length===1&&t.jsxs(Xe,{windowSize:o,children:[t.jsx(Ge,{}),t.jsxs(ci,{windowSize:o,children:[t.jsx(Li,{windowSize:o,children:t.jsxs(Je,{windowSize:o,children:[t.jsx(Qe,{children:i.total}),t.jsx(Le,{amount:ve,integerStyles:F.h6Regular.cssObject,decimalStyles:F.standardRegular.cssObject})]})}),e.remiDetails&&t.jsx(mi,{windowSize:o,children:t.jsx(Oe,{amount:Te,activities:e.remiActivities,stage:L?.code??"draft",onAddNewRule:he,entity:"reimbursement",historicActivities:e.remiHistory.activities,realTimeApproval:{allApprovers:e.filteredApprovers,allAccountingClass:e.allAccountingClasses,filteredAttributes:e.filteredAttributes,isRealTimeApproverEditMode:e.realTimeApproval.isEditMode??!1,realTimeApprovalSaveStatus:{fetchState:e.realTimeApproval.fetchState,error:e.realTimeApproval.error},approvalListFetchState:e.approverListFetchState.fetchState,attributeSubTypeToUserIdMapping:e.attributeSubTypeToUserIdMapping,isAdmin:oe,signedInUserId:ne?.userId,showRealTimeApproval:se,entityApprovalId:e.remiActivities[0]?.entityApprovalId??e.remiDetails.entityApprovalId,updateEditMode:ce,onSaveRealTimeApprovals:me}})})]})]}),t.jsx(Fi,{})]}),$e||W===!0?null:t.jsxs(Ci,{children:[o!=="small"?t.jsx(Ge,{}):null,t.jsx(xi,{windowSize:o,"data-testid":y("remi-detail-page-footer"),onClick:l=>{l.stopPropagation(),G===!0&&Y(!1)},children:t.jsx(Kt,{separatorStyle:{marginRight:a.sp4},showPrimaryButton:e.remiDetails?.reimbursementInfo.billStatus.code==="rejected"||le,showCancel:e.remiDetails?.reimbursementInfo.billStatus.code==="rejected"||le,cancelBtn:{label:e.remiDetails?.reimbursementInfo.billStatus.code==="rejected"?o==="small"?i.buttons.delete:i.buttons.deleteReport:o==="small"?i.buttons.reject:i.buttons.rejectReport,isLoading:q==="rejected"&&e.approvalUpdateStatus.fetchState==="In-Progress"||q==="delete"&&e.deleteStatus.fetchState==="In-Progress",onClick:St,style:{width:s.footerButtonWidth.value(o)},reverseSpinnerColor:!1},primaryBtn:{label:e.remiDetails?.reimbursementInfo.billStatus.code==="rejected"?o==="small"?i.buttons.edit:i.buttons.editAndResubmit:o==="small"?i.buttons.approve:i.buttons.approveReport,isLoading:q==="approved"&&e.approvalUpdateStatus.fetchState==="In-Progress",onClick:jt,style:{width:s.footerButtonWidth.value(o)},isDisabled:e.approvalUpdateStatus.fetchState==="In-Progress"||e.realTimeApproval.isEditMode===!0},rightSideComponent:t.jsx(wi,{children:t.jsxs(Ii,{windowSize:o,children:[!R&&G?t.jsx(Ut,{onClickAway:()=>Y(!1),children:t.jsxs(Si,{windowSize:o,children:[ee!=="processing"?t.jsx(re,{onClick:je,"data-testid":y("remi-delete-action"),children:i.buttons.deleteReport}):null,ee==="processing"?t.jsx(re,{onClick:$t,"data-testid":y("remi-cancel-action"),children:i.buttons.cancel}):null,ee==="processing"?t.jsx(re,{onClick:vt,"data-testid":y("remi-cancel-and-delete-action"),children:i.buttons.cancelAndDelete}):null]})}):null,t.jsxs(ji,{windowSize:o,children:[!R&&De?t.jsx(Ti,{onClick:Se,"data-testid":y("remi-edit-button"),children:t.jsx(vi,{})}):null,!R&&Ct===!0?t.jsx($i,{windowSize:o,showEditIcon:De,children:t.jsx(fi,{onClick:()=>Y(!G),"data-testid":y("remi-more-actions-button")})}):null]})]})}),style:{minHeight:62}})})]}),u?t.jsx(ri,{id:h,children:t.jsx(Vt,{isDrawerOpen:pt,allowComposer:!0,drawerTitle:yt,threads:M,autoExpand:!0,autoFocus:!1,filter:{application:"dashboard",companyId:C?.companyId??xe,isGlobalComment:!1,tab:"reimbursement"},isLoading:I,threadMetadata:C?{companyName:C.companyName,companyId:C.companyId,entityId:C.entityId,entityType:C.entityType,isGlobalComment:!1,application:"dashboard",tab:"reimbursement",url:window.location.href}:void 0,textOverrides:{composerPlaceholder:gt,replyComposerPlaceholder:bt,threadResolve:wt,threadUnResolve:xt},onThreadClick:(l,n)=>At(l,n),onCloseAllThreadsDrawer:()=>B(!1),drawerSectionStyle:{width:"400px",backgroundColor:ye.colors.background}})}):null]})},di=e=>{const U=Ze.getLocalizedStrings().spendManagement.billPay.billsByTabs;if(e?.isDeleted===!0)return{value:U.tabsById.deleted,color:ae.deleted.color,bgColor:ae.deleted.bgColor,borderColor:ae.deleted.borderColor,code:"deleted"}},ci=r.div`
2
2
  display: flex;
3
3
  flex-direction: column;
4
4
  width: ${e=>s.rightSectionWidth.valuePercentage(e.windowSize)};
@@ -1,4 +1,4 @@
1
- import{ax as le,d as $,q as k,aP as ae,l as L,O as E,j as e,aM as a,bF as me,n as u,af as m,o as s,ar as ce,_ as de,aS as F,an as pe,y as xe,h as z,cR as he,aT as ue,b9 as ge,u as we}from"./index-D94hlokH.js";import{b as j,n as t}from"./vendor-Bs1fkIUX.js";import{x as je}from"./MeetingCalenderPopup-C1bMV1I3-DBaPSnGq.js";import{f as be}from"./VideoPopup-B2pu7j6O-DcAtt4hw.js";import{M as v}from"./usp-line-BBd1wKwW-ZlUrfnG1.js";import"./mui-Ty75qFQF.js";import"./analytics-CcevxdRy.js";import"./routing-Dk1A2KYI.js";import"./sentry-BE5FTzpq.js";import"./redux-CEhZD0hA.js";import"./liveblocks-8ht9CoL5.js";import"./crypto-cQYYQPTZ.js";import"./VideoPlayer-DPXISthv-iABqInol.js";const Z="https://storage.googleapis.com/zeni-apis.appspot.com/images/reimbursement-promo-light.png",O="https://storage.googleapis.com/zeni-apis.appspot.com/images/reimbursement-promo-dark.png",fe={midContainerMarginBottom:new xe(we[5],44)},ye=t.div`
1
+ import{ax as le,d as $,q as k,aP as ae,l as L,O as E,j as e,aM as a,bF as me,n as u,af as m,o as s,ar as ce,_ as de,aS as F,an as pe,y as xe,h as z,cR as he,aT as ue,b9 as ge,u as we}from"./index-sAOH0Fje.js";import{b as j,n as t}from"./vendor-Bs1fkIUX.js";import{x as je}from"./MeetingCalenderPopup-BxV_UIXP-B9VDTxkT.js";import{f as be}from"./VideoPopup-DJrQQTPq-DoXO-Vwb.js";import{M as v}from"./usp-line-BBd1wKwW-ZlUrfnG1.js";import"./mui-Ty75qFQF.js";import"./analytics-CcevxdRy.js";import"./routing-Dk1A2KYI.js";import"./sentry-BE5FTzpq.js";import"./redux-CEhZD0hA.js";import"./liveblocks-8ht9CoL5.js";import"./crypto-cQYYQPTZ.js";import"./VideoPlayer-ByyqUuhG-DTMNeCaX.js";const Z="https://storage.googleapis.com/zeni-apis.appspot.com/images/reimbursement-promo-light.png",O="https://storage.googleapis.com/zeni-apis.appspot.com/images/reimbursement-promo-dark.png",fe={midContainerMarginBottom:new xe(we[5],44)},ye=t.div`
2
2
  display: flex;
3
3
  flex: 1 1 auto;
4
4
  min-height: 100%;
@@ -1,4 +1,4 @@
1
- import{d as Ee,q as Te,aP as N,aa as qe,cS as Ge,O as Ve,l as Je,aU as be,j as t,fn as Ke,h as J,y as r,bF as Ze,P as Ye,ad as Xe,e6 as Qe,bA as et,dY as tt,aQ as it,o as a,u as n,cw as nt,d3 as ot,db as at,fH as ve,fI as ke,gq as lt,n as rt,aM as $e,c as Pe,bX as st,ai as ct,bx as dt}from"./index-D94hlokH.js";import{b as o,n as i}from"./vendor-Bs1fkIUX.js";import{D as ut}from"./HelpButton-B2amus4B-DejCwWuG.js";import{K as je}from"./SetUpDefaultSection-Dko6eOr--DSAIqPKL.js";import{f as mt}from"./SpendMgmtSetupAccountSection-C7WofOL3-C_mHdj1H.js";import{g as pt}from"./UploadAdditionalDocumentOverlay-BzWXbm7_-BYxLpWvz.js";import"./mui-Ty75qFQF.js";import"./analytics-CcevxdRy.js";import"./routing-Dk1A2KYI.js";import"./sentry-BE5FTzpq.js";import"./redux-CEhZD0hA.js";import"./liveblocks-8ht9CoL5.js";import"./crypto-cQYYQPTZ.js";import"./MeetingCalenderPopup-C1bMV1I3-DBaPSnGq.js";import"./ChargeCardUtils-CHhHodZN-6DoofQsj.js";import"./CreditCardPaymentPlgSection-CfIXTZi1-BWmvJdS4.js";import"./ChaseOverlay-laPjyJU7-DF7Or1ye.js";const gt=e=>o.createElement("svg",{viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},o.createElement("path",{d:"M12.7113 3H2.89261C2.39963 3 2 3.39963 2 3.89261V20.8522C2 21.3451 2.39963 21.7448 2.89261 21.7448H12.7113C13.2043 21.7448 13.6039 21.3451 13.6039 20.8522V3.89261C13.6039 3.39963 13.2043 3 12.7113 3Z",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),o.createElement("path",{d:"M10.4798 13.7113H9.58719C9.3407 13.7113 9.14088 13.9111 9.14088 14.1576V16.8354C9.14088 17.0819 9.3407 17.2817 9.58719 17.2817H10.4798C10.7263 17.2817 10.9261 17.0819 10.9261 16.8354V14.1576C10.9261 13.9111 10.7263 13.7113 10.4798 13.7113Z",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),o.createElement("path",{d:"M21.6374 16.1133C21.6374 16.1961 21.6143 16.2773 21.5708 16.3477C21.5273 16.4182 21.4651 16.4752 21.391 16.5123L19.8522 17.2817V14.6039H21.1911C21.3095 14.6039 21.423 14.6509 21.5067 14.7346C21.5904 14.8183 21.6374 14.9318 21.6374 15.0502V16.1133Z",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),o.createElement("path",{d:"M19.8522 14.6039V13.265C19.8522 12.5268 22.53 10.1409 22.53 10.1409",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),o.createElement("path",{d:"M19.8522 17.2817V19.9596C19.8522 20.433 19.6641 20.8871 19.3293 21.2219C18.9945 21.5567 18.5404 21.7448 18.067 21.7448C17.5935 21.7448 17.1394 21.5567 16.8046 21.2219C16.4698 20.8871 16.2817 20.433 16.2817 19.9596V7.90935C16.2817 7.55424 16.1407 7.21369 15.8896 6.96259C15.6385 6.7115 15.2979 6.57043 14.9428 6.57043H13.6039",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),o.createElement("path",{d:"M2 10.1409H13.6039",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),o.createElement("path",{d:"M11.3724 4.78528H4.23154C3.98505 4.78528 3.78523 4.9851 3.78523 5.23158V7.90941C3.78523 8.15589 3.98505 8.35571 4.23154 8.35571H11.3724C11.6189 8.35571 11.8187 8.15589 11.8187 7.90941V5.23158C11.8187 4.9851 11.6189 4.78528 11.3724 4.78528Z",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),o.createElement("path",{d:"M9.14088 19.0669H10.9261",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})),h={sectionWidth:new r(343,580,726),iconContainerMaxWidthHeight:new r(n[6],n[7]),iconContainerMarginRight:new r(12,n[3]),infoLabelPaddingLeft:new r(n[0],n[3]),iconPadding:new r(10,12),iconWidthHeight:new r(20,n[4]),rowGap:new r(n[2],n[3]),containerPadding:new r(n[3],n[4])},ge={title:new Pe("standardSemiBold","largeSemiBold"),infoLabel:new Pe("extraSmallRegular","smallRegular")};function ht({companyMileageConfigInfo:e,mileageDetails:y,analytics:j,style:A,sectionId:$,isActive:d=!0,isDisabled:s,onSaveMileageClick:K}){const l=Te(),D=Ee(),{formState:{errors:Z},trigger:Y}=ot(),E=ft($,"mileageAmountInDenomination"),f=at(Z,E),{localData:c,updateStatus:F,mileageStatus:S}=y,U=e?.denominationConversions.amount==null||e.denominationConversions.amount!==c?.mileageAmountInDenomination,{commonSetUp:X,spendManagement:Q}=Ve.getLocalizedStrings(),{reimbursement:ee}=Q,[C,T]=o.useState(U),[te,H]=o.useState(!1);o.useEffect(()=>{f||Y(E)},[]),o.useEffect(()=>{e?.denominationConversions.amount!=null&&e.denominationConversions.amount===c?.mileageAmountInDenomination&&T(!1)},[e?.denominationConversions.amount]),o.useEffect(()=>{C||H(C)},[C]);const{reimbursementSetup:x}=ee,{setUp:ie}=X,ne=C===!1||F.fetchState==="In-Progress"?"readonly":s,oe=c&&c?.denominationSymbol?`${c?.denominationSymbol} `:"",ae=c&&c?.mileageUnit?c?.mileageUnit:"";return t.jsxs(xt,{windowSize:l,style:A,isActive:d&&s==null,children:[t.jsxs(Pt,{windowSize:l,children:[x.mileageHeader,d===!1?t.jsx(Dt,{children:ie.comingSoon}):null]}),t.jsxs(kt,{windowSize:l,children:[t.jsx(vt,{windowSize:l,isDarkMode:D.mode==="dark",children:t.jsx(gt,{width:h.iconWidthHeight.valuePx(l),height:h.iconWidthHeight.valuePx(l)})}),t.jsxs(wt,{children:[t.jsxs($t,{children:[t.jsxs(jt,{children:[t.jsxs(At,{children:[t.jsx(St,{windowSize:l,children:e?.denominationConversions.amount==null?x.mileageAddTitle:x.mileageEditTitle}),t.jsx(Ct,{children:x.mileageSubTitle})]}),S!=null&&e?.denominationConversions.amount!=null&&l==="small"?t.jsx(ve,{style:{width:"max-content",padding:a.sp0,marginTop:a.sp2},tagTitle:S.name,textColor:ke(S.code)}):null]}),t.jsxs(yt,{children:[S!=null&&e?.denominationConversions.amount!=null&&l!=="small"?t.jsx(ve,{style:{width:"max-content"},tagTitle:S.name,textColor:ke(S.code)}):null,t.jsx(bt,{})]})]}),t.jsxs(Et,{children:[t.jsxs(Tt,{children:[t.jsx(lt,{style:{height:a.sp6,textAlign:"left"},inputStyle:{textAlign:"left",paddingRight:a.sp10,backgroundColor:f?void 0:D.colors.background,color:C||f?void 0:D.colors.grey1},isFieldError:f,type:"number",autoFocus:!1,focus:te,name:E,defaultValue:c?.mileageAmountInDenomination,returnValueType:"floatValue",allowEmptyFormatting:!0,prefix:oe,suffix:` ${x.perText} ${ae}`,decimalScale:1,allowNegative:!1,isNumericString:!1,registerOptions:{min:1,validate:V=>V!=null||s!=null,required:s==null},isDisabled:ne}),t.jsx(It,{children:C?t.jsx(rt,{label:x.save,"data-testid":$e("save-mileage"),onClick:()=>{c?.mileageAmountInDenomination!=null&&U&&!f&&K?.(c.mileageAmountInDenomination)},style:{outline:"none"},size:"small",disabled:s!=null,variant:"light_transparent",reverseSpinnerColor:!1,loading:F.fetchState==="In-Progress"}):t.jsx(Lt,{isDisabled:s,"data-testid":$e("edit-mileage"),onClick:V=>{V.stopPropagation(),T(!0),H(!0),j.trackReimbursementMileageRateEdit()}})})]}),c?.description!=null?t.jsx(Vt,{size:l,hasError:f,children:f&&e?.defaultMileageUnitAmount!=null?x.yourMileage.replace("__defaultMileageUnitAmount__",(e.defaultMileageUnitAmount*100).toString()):c.description}):null]})]})]})]})}const ft=(e,y)=>`${e}.${y}`,xt=i.div`
1
+ import{d as Ee,q as Te,aP as N,aa as qe,cS as Ge,O as Ve,l as Je,aU as be,j as t,fn as Ke,h as J,y as r,bF as Ze,P as Ye,ad as Xe,e6 as Qe,bA as et,dY as tt,aQ as it,o as a,u as n,cw as nt,d3 as ot,db as at,fH as ve,fI as ke,gq as lt,n as rt,aM as $e,c as Pe,bX as st,ai as ct,bx as dt}from"./index-sAOH0Fje.js";import{b as o,n as i}from"./vendor-Bs1fkIUX.js";import{D as ut}from"./HelpButton-BNMy-6ce-WFq-iELy.js";import{K as je}from"./SetUpDefaultSection-Bm1eZSgT-BcxYXAIw.js";import{f as mt}from"./SpendMgmtSetupAccountSection-de7hEmtE-CX-1PNOC.js";import{g as pt}from"./UploadAdditionalDocumentOverlay-DhXRLBEg-DvVrgitE.js";import"./mui-Ty75qFQF.js";import"./analytics-CcevxdRy.js";import"./routing-Dk1A2KYI.js";import"./sentry-BE5FTzpq.js";import"./redux-CEhZD0hA.js";import"./liveblocks-8ht9CoL5.js";import"./crypto-cQYYQPTZ.js";import"./MeetingCalenderPopup-BxV_UIXP-B9VDTxkT.js";import"./ChargeCardUtils-BRgkrCTs-DoVoCmwL.js";import"./CreditCardPaymentPlgSection-8ZShMO31-D_nbIzHo.js";import"./ChaseOverlay-BC_4vwtb-ZJ37WP7g.js";const gt=e=>o.createElement("svg",{viewBox:"0 0 24 24",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},o.createElement("path",{d:"M12.7113 3H2.89261C2.39963 3 2 3.39963 2 3.89261V20.8522C2 21.3451 2.39963 21.7448 2.89261 21.7448H12.7113C13.2043 21.7448 13.6039 21.3451 13.6039 20.8522V3.89261C13.6039 3.39963 13.2043 3 12.7113 3Z",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),o.createElement("path",{d:"M10.4798 13.7113H9.58719C9.3407 13.7113 9.14088 13.9111 9.14088 14.1576V16.8354C9.14088 17.0819 9.3407 17.2817 9.58719 17.2817H10.4798C10.7263 17.2817 10.9261 17.0819 10.9261 16.8354V14.1576C10.9261 13.9111 10.7263 13.7113 10.4798 13.7113Z",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),o.createElement("path",{d:"M21.6374 16.1133C21.6374 16.1961 21.6143 16.2773 21.5708 16.3477C21.5273 16.4182 21.4651 16.4752 21.391 16.5123L19.8522 17.2817V14.6039H21.1911C21.3095 14.6039 21.423 14.6509 21.5067 14.7346C21.5904 14.8183 21.6374 14.9318 21.6374 15.0502V16.1133Z",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),o.createElement("path",{d:"M19.8522 14.6039V13.265C19.8522 12.5268 22.53 10.1409 22.53 10.1409",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),o.createElement("path",{d:"M19.8522 17.2817V19.9596C19.8522 20.433 19.6641 20.8871 19.3293 21.2219C18.9945 21.5567 18.5404 21.7448 18.067 21.7448C17.5935 21.7448 17.1394 21.5567 16.8046 21.2219C16.4698 20.8871 16.2817 20.433 16.2817 19.9596V7.90935C16.2817 7.55424 16.1407 7.21369 15.8896 6.96259C15.6385 6.7115 15.2979 6.57043 14.9428 6.57043H13.6039",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),o.createElement("path",{d:"M2 10.1409H13.6039",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),o.createElement("path",{d:"M11.3724 4.78528H4.23154C3.98505 4.78528 3.78523 4.9851 3.78523 5.23158V7.90941C3.78523 8.15589 3.98505 8.35571 4.23154 8.35571H11.3724C11.6189 8.35571 11.8187 8.15589 11.8187 7.90941V5.23158C11.8187 4.9851 11.6189 4.78528 11.3724 4.78528Z",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),o.createElement("path",{d:"M9.14088 19.0669H10.9261",stroke:"currentColor",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})),h={sectionWidth:new r(343,580,726),iconContainerMaxWidthHeight:new r(n[6],n[7]),iconContainerMarginRight:new r(12,n[3]),infoLabelPaddingLeft:new r(n[0],n[3]),iconPadding:new r(10,12),iconWidthHeight:new r(20,n[4]),rowGap:new r(n[2],n[3]),containerPadding:new r(n[3],n[4])},ge={title:new Pe("standardSemiBold","largeSemiBold"),infoLabel:new Pe("extraSmallRegular","smallRegular")};function ht({companyMileageConfigInfo:e,mileageDetails:y,analytics:j,style:A,sectionId:$,isActive:d=!0,isDisabled:s,onSaveMileageClick:K}){const l=Te(),D=Ee(),{formState:{errors:Z},trigger:Y}=ot(),E=ft($,"mileageAmountInDenomination"),f=at(Z,E),{localData:c,updateStatus:F,mileageStatus:S}=y,U=e?.denominationConversions.amount==null||e.denominationConversions.amount!==c?.mileageAmountInDenomination,{commonSetUp:X,spendManagement:Q}=Ve.getLocalizedStrings(),{reimbursement:ee}=Q,[C,T]=o.useState(U),[te,H]=o.useState(!1);o.useEffect(()=>{f||Y(E)},[]),o.useEffect(()=>{e?.denominationConversions.amount!=null&&e.denominationConversions.amount===c?.mileageAmountInDenomination&&T(!1)},[e?.denominationConversions.amount]),o.useEffect(()=>{C||H(C)},[C]);const{reimbursementSetup:x}=ee,{setUp:ie}=X,ne=C===!1||F.fetchState==="In-Progress"?"readonly":s,oe=c&&c?.denominationSymbol?`${c?.denominationSymbol} `:"",ae=c&&c?.mileageUnit?c?.mileageUnit:"";return t.jsxs(xt,{windowSize:l,style:A,isActive:d&&s==null,children:[t.jsxs(Pt,{windowSize:l,children:[x.mileageHeader,d===!1?t.jsx(Dt,{children:ie.comingSoon}):null]}),t.jsxs(kt,{windowSize:l,children:[t.jsx(vt,{windowSize:l,isDarkMode:D.mode==="dark",children:t.jsx(gt,{width:h.iconWidthHeight.valuePx(l),height:h.iconWidthHeight.valuePx(l)})}),t.jsxs(wt,{children:[t.jsxs($t,{children:[t.jsxs(jt,{children:[t.jsxs(At,{children:[t.jsx(St,{windowSize:l,children:e?.denominationConversions.amount==null?x.mileageAddTitle:x.mileageEditTitle}),t.jsx(Ct,{children:x.mileageSubTitle})]}),S!=null&&e?.denominationConversions.amount!=null&&l==="small"?t.jsx(ve,{style:{width:"max-content",padding:a.sp0,marginTop:a.sp2},tagTitle:S.name,textColor:ke(S.code)}):null]}),t.jsxs(yt,{children:[S!=null&&e?.denominationConversions.amount!=null&&l!=="small"?t.jsx(ve,{style:{width:"max-content"},tagTitle:S.name,textColor:ke(S.code)}):null,t.jsx(bt,{})]})]}),t.jsxs(Et,{children:[t.jsxs(Tt,{children:[t.jsx(lt,{style:{height:a.sp6,textAlign:"left"},inputStyle:{textAlign:"left",paddingRight:a.sp10,backgroundColor:f?void 0:D.colors.background,color:C||f?void 0:D.colors.grey1},isFieldError:f,type:"number",autoFocus:!1,focus:te,name:E,defaultValue:c?.mileageAmountInDenomination,returnValueType:"floatValue",allowEmptyFormatting:!0,prefix:oe,suffix:` ${x.perText} ${ae}`,decimalScale:1,allowNegative:!1,isNumericString:!1,registerOptions:{min:1,validate:V=>V!=null||s!=null,required:s==null},isDisabled:ne}),t.jsx(It,{children:C?t.jsx(rt,{label:x.save,"data-testid":$e("save-mileage"),onClick:()=>{c?.mileageAmountInDenomination!=null&&U&&!f&&K?.(c.mileageAmountInDenomination)},style:{outline:"none"},size:"small",disabled:s!=null,variant:"light_transparent",reverseSpinnerColor:!1,loading:F.fetchState==="In-Progress"}):t.jsx(Lt,{isDisabled:s,"data-testid":$e("edit-mileage"),onClick:V=>{V.stopPropagation(),T(!0),H(!0),j.trackReimbursementMileageRateEdit()}})})]}),c?.description!=null?t.jsx(Vt,{size:l,hasError:f,children:f&&e?.defaultMileageUnitAmount!=null?x.yourMileage.replace("__defaultMileageUnitAmount__",(e.defaultMileageUnitAmount*100).toString()):c.description}):null]})]})]})]})}const ft=(e,y)=>`${e}.${y}`,xt=i.div`
2
2
  display: flex;
3
3
  flex-direction: column;
4
4
  pointer-events: ${e=>e.isLoading===!0||e.isActive===!1?"none":"initial"};
@@ -1 +1 @@
1
- import{O as M,j as b,cD as X,cE as z,cF as V,k1 as W,aX as q,l as Y}from"./index-D94hlokH.js";import{b as f}from"./vendor-Bs1fkIUX.js";import{u as Z}from"./ReviewOverlay-C9hLAPaS-CC8EN_X1.js";import"./mui-Ty75qFQF.js";import"./analytics-CcevxdRy.js";import"./routing-Dk1A2KYI.js";import"./sentry-BE5FTzpq.js";import"./redux-CEhZD0hA.js";import"./liveblocks-8ht9CoL5.js";import"./crypto-cQYYQPTZ.js";const{common:n,spendManagement:{reimbursement:j}}=M.getLocalizedStrings(),o=j.bulkActions;let I;const le=({remisReviewView:e,isAdmin:a,analytics:i,onProceedForBulkActionClick:d,onCloseReviewItem:r,onCloseOverlay:s})=>{const{fetchState:p,bulkSubmissionFetchState:c,bulkOperationTypeSelected:t,currentTab:v,currentSubTab:g}=e,h=!1,[w,l]=f.useState(!1),[m,_]=f.useState(P(e,h,a)),[x,R]=f.useState(h),[B,J]=f.useState(0),[y,A]=f.useState({type:"",title:"",description:"",primaryButtonText:"",secondaryButtonText:""});f.useEffect(()=>(B===m.length&&x&&(R(!1),clearInterval(I)),e.fetchState==="Completed"&&_(P(e,!1,a)),()=>{clearInterval(I)}),[m.length,B,x,e.fetchState,h,e,a]);const E=m.length,S=m.filter(u=>u.reviewStatus.code!=="error").length,F=()=>{const{title:u,description:T}=G(S);A({type:"reject",title:u,description:T,primaryButtonText:n.texts.confirm,secondaryButtonText:n.texts.close}),i.trackReimbursementBulkSubmit(t,v,g),l(!0)},$={onOkClick:u=>{l(!1);const T=e.remisForReview.map(k=>k.reimbursement);i.trackReimbursementBulkPopupConfirm(t,v,g,Y.getRemiListUniqueType(T.map(k=>k?.reimbursementTypesIncluded??[]))),d("reject",u)},onCancelClick:()=>{l(!1)}},{title:L,description:U}=H(p,S,E,x),C=e.fetchState==="Completed"&&S===0,D=()=>{i.trackReimbursementBulkSubmit(t,v,g),d(t)},N=()=>{let u=n.footer.approve;return C?u=n.texts.close:t==="send_for_approval"&&(u=n.footer.submit),{label:u,isDisabled:p!=="Completed"||t==="reject"&&c==="In-Progress",isLoading:c==="In-Progress"&&(t==="send_for_approval"||t==="approve"),onClick:C?s:D,style:t==="send_for_approval"?{minWidth:"92px"}:{}}},O={label:t==="send_for_approval"?n.texts.goBack:n.footer.reject,isDisabled:t!=="reject"&&c==="In-Progress",isLoading:t==="reject"&&c==="In-Progress",reverseSpinnerColor:!1,onClick:t==="send_for_approval"?s:F,style:t==="approve"?{minWidth:"92px"}:{}};return b.jsxs(b.Fragment,{children:[w?b.jsx(X,{titleComponent:b.jsx(V,{children:y.title}),descriptionComponent:b.jsx(z,{children:y.description}),primaryButtonText:y.primaryButtonText,proceedButtonVariant:"danger",secondaryButtonText:y.secondaryButtonText,action:$,isNotesIncluded:!0,isEditPopup:!0}):null,b.jsx(Z,{title:L,description:{content:U,isError:e.fetchState==="Completed"&&S===0},reviewItems:m,onCloseReviewItem:r,onCloseOverlay:s,showFooter:e.fetchState==="Completed"&&!x,footerProps:{primaryButton:N(),cancelButton:O,hideCancel:C}})]})},P=(e,a,i)=>{const d=e.fetchState==="In-Progress";return e.remisForReview.map(r=>{const s=W(i,r.submittedBy);return{id:r.transactionId,leftSideText:{title:r.reimbursement?.reportTitle!=null?r.reimbursement.reportTitle:j.reimbursementDetail.newReimbursementTitle,subTitle:s!=null?`${n.by} ${s?.firstName} ${s?.lastName}`:n.strings.empty},rightSideText:{title:q("0,0.[00]",r.reimbursement?.amount?.amount,r.reimbursement?.amount?.currencySymbol),showThunderIcon:!1,subTitle:r.reviewInfoMessage??""},reviewStatus:{isLoading:d,code:r.reviewStatus??""}}})},G=e=>{const{this_:a,these:i,report:d,reports:r,payment:s,payments:p}=n.texts;return e>1?{title:o.popUps.reject.title.replace("__report__",o.reports),description:o.popUps.reject.description.replaceAll("<_this_>",i).replaceAll("<_payment_>",p).replaceAll("__report__",r)}:{title:o.popUps.reject.title.replace("__report__",o.report),description:o.popUps.reject.description.replaceAll("<_this_>",a).replaceAll("<_payment_>",s).replaceAll("__report__",d)}},H=(e,a,i,d)=>{const{has:r,have:s,report:p,reports:c,are:t,is:v,do_:g,does:h}=n.texts,w=a>1,l=i>1;let m="",_="";return e==="Completed"&&!d?(m=o.reviewPage.reportsReviewed.title.replace("__report__",l?j.bulkActions.reports:o.report).replace("<_has_>",l?s:r),a===0?_=o.reviewPage.reportsReviewed.descriptionError.replace("__report__",l?c:p).replace("<_do_>",l?g:h):_=`${a}/${i} ${o.reviewPage.reportsReviewed.description.replace("__report__",i>1?c:p).replace("<_is_>",w?t:v)}`):(m=o.reviewPage.reportsReviewing.title.replace("__report__",l?c:p),_=o.reviewPage.reportsReviewing.description.replace("__report__",l?c:p)),{title:m,description:_}};export{le as default};
1
+ import{O as M,j as b,cD as X,cE as z,cF as V,k1 as W,aX as q,l as Y}from"./index-sAOH0Fje.js";import{b as f}from"./vendor-Bs1fkIUX.js";import{u as Z}from"./ReviewOverlay-C6Kx7Hfm-IahzUsv3.js";import"./mui-Ty75qFQF.js";import"./analytics-CcevxdRy.js";import"./routing-Dk1A2KYI.js";import"./sentry-BE5FTzpq.js";import"./redux-CEhZD0hA.js";import"./liveblocks-8ht9CoL5.js";import"./crypto-cQYYQPTZ.js";const{common:n,spendManagement:{reimbursement:j}}=M.getLocalizedStrings(),o=j.bulkActions;let I;const le=({remisReviewView:e,isAdmin:a,analytics:i,onProceedForBulkActionClick:d,onCloseReviewItem:r,onCloseOverlay:s})=>{const{fetchState:p,bulkSubmissionFetchState:c,bulkOperationTypeSelected:t,currentTab:v,currentSubTab:g}=e,h=!1,[w,l]=f.useState(!1),[m,_]=f.useState(P(e,h,a)),[x,R]=f.useState(h),[B,J]=f.useState(0),[y,A]=f.useState({type:"",title:"",description:"",primaryButtonText:"",secondaryButtonText:""});f.useEffect(()=>(B===m.length&&x&&(R(!1),clearInterval(I)),e.fetchState==="Completed"&&_(P(e,!1,a)),()=>{clearInterval(I)}),[m.length,B,x,e.fetchState,h,e,a]);const E=m.length,S=m.filter(u=>u.reviewStatus.code!=="error").length,F=()=>{const{title:u,description:T}=G(S);A({type:"reject",title:u,description:T,primaryButtonText:n.texts.confirm,secondaryButtonText:n.texts.close}),i.trackReimbursementBulkSubmit(t,v,g),l(!0)},$={onOkClick:u=>{l(!1);const T=e.remisForReview.map(k=>k.reimbursement);i.trackReimbursementBulkPopupConfirm(t,v,g,Y.getRemiListUniqueType(T.map(k=>k?.reimbursementTypesIncluded??[]))),d("reject",u)},onCancelClick:()=>{l(!1)}},{title:L,description:U}=H(p,S,E,x),C=e.fetchState==="Completed"&&S===0,D=()=>{i.trackReimbursementBulkSubmit(t,v,g),d(t)},N=()=>{let u=n.footer.approve;return C?u=n.texts.close:t==="send_for_approval"&&(u=n.footer.submit),{label:u,isDisabled:p!=="Completed"||t==="reject"&&c==="In-Progress",isLoading:c==="In-Progress"&&(t==="send_for_approval"||t==="approve"),onClick:C?s:D,style:t==="send_for_approval"?{minWidth:"92px"}:{}}},O={label:t==="send_for_approval"?n.texts.goBack:n.footer.reject,isDisabled:t!=="reject"&&c==="In-Progress",isLoading:t==="reject"&&c==="In-Progress",reverseSpinnerColor:!1,onClick:t==="send_for_approval"?s:F,style:t==="approve"?{minWidth:"92px"}:{}};return b.jsxs(b.Fragment,{children:[w?b.jsx(X,{titleComponent:b.jsx(V,{children:y.title}),descriptionComponent:b.jsx(z,{children:y.description}),primaryButtonText:y.primaryButtonText,proceedButtonVariant:"danger",secondaryButtonText:y.secondaryButtonText,action:$,isNotesIncluded:!0,isEditPopup:!0}):null,b.jsx(Z,{title:L,description:{content:U,isError:e.fetchState==="Completed"&&S===0},reviewItems:m,onCloseReviewItem:r,onCloseOverlay:s,showFooter:e.fetchState==="Completed"&&!x,footerProps:{primaryButton:N(),cancelButton:O,hideCancel:C}})]})},P=(e,a,i)=>{const d=e.fetchState==="In-Progress";return e.remisForReview.map(r=>{const s=W(i,r.submittedBy);return{id:r.transactionId,leftSideText:{title:r.reimbursement?.reportTitle!=null?r.reimbursement.reportTitle:j.reimbursementDetail.newReimbursementTitle,subTitle:s!=null?`${n.by} ${s?.firstName} ${s?.lastName}`:n.strings.empty},rightSideText:{title:q("0,0.[00]",r.reimbursement?.amount?.amount,r.reimbursement?.amount?.currencySymbol),showThunderIcon:!1,subTitle:r.reviewInfoMessage??""},reviewStatus:{isLoading:d,code:r.reviewStatus??""}}})},G=e=>{const{this_:a,these:i,report:d,reports:r,payment:s,payments:p}=n.texts;return e>1?{title:o.popUps.reject.title.replace("__report__",o.reports),description:o.popUps.reject.description.replaceAll("<_this_>",i).replaceAll("<_payment_>",p).replaceAll("__report__",r)}:{title:o.popUps.reject.title.replace("__report__",o.report),description:o.popUps.reject.description.replaceAll("<_this_>",a).replaceAll("<_payment_>",s).replaceAll("__report__",d)}},H=(e,a,i,d)=>{const{has:r,have:s,report:p,reports:c,are:t,is:v,do_:g,does:h}=n.texts,w=a>1,l=i>1;let m="",_="";return e==="Completed"&&!d?(m=o.reviewPage.reportsReviewed.title.replace("__report__",l?j.bulkActions.reports:o.report).replace("<_has_>",l?s:r),a===0?_=o.reviewPage.reportsReviewed.descriptionError.replace("__report__",l?c:p).replace("<_do_>",l?g:h):_=`${a}/${i} ${o.reviewPage.reportsReviewed.description.replace("__report__",i>1?c:p).replace("<_is_>",w?t:v)}`):(m=o.reviewPage.reportsReviewing.title.replace("__report__",l?c:p),_=o.reviewPage.reportsReviewing.description.replace("__report__",l?c:p)),{title:m,description:_}};export{le as default};
@@ -1,4 +1,4 @@
1
- import{d as h,j as r,aL as a,aM as m,b2 as j,O as C,aR as l,bI as x,ai as g,o as c,b3 as f}from"./index-D94hlokH.js";import{n as s,b as d}from"./vendor-Bs1fkIUX.js";function p({backgroundColor:e,foregroundColor:o,animated:t,width:i,height:n}){return r.jsxs(x,{speed:2,width:i,height:n,viewBox:`0 0 ${i} ${n}`,animate:t!=!1,backgroundColor:e,foregroundColor:o,children:[r.jsx("rect",{x:"64",y:"0",rx:"4",ry:"4",width:`${i-128}`,height:"21"}),r.jsx("rect",{x:"24",y:"45",rx:"4",ry:"4",width:`${i-48}`,height:"228"})]})}function w({backgroundColor:e,foregroundColor:o,animated:t}){return r.jsxs(x,{speed:2,width:240,height:98,viewBox:"0 0 240 98",animate:t!=!1,backgroundColor:e,foregroundColor:o,children:[r.jsx("rect",{x:"66",y:"0",rx:"4",ry:"4",width:"108",height:"21"}),r.jsx("rect",{x:"44",y:"77",rx:"4",ry:"4",width:"152",height:"21"}),r.jsx("rect",{x:"0",y:"29",rx:"4",ry:"4",width:"240",height:"40"})]})}const u=s(l)`
1
+ import{d as h,j as r,aL as a,aM as m,b2 as j,O as C,aR as l,bI as x,ai as g,o as c,b3 as f}from"./index-sAOH0Fje.js";import{n as s,b as d}from"./vendor-Bs1fkIUX.js";function p({backgroundColor:e,foregroundColor:o,animated:t,width:i,height:n}){return r.jsxs(x,{speed:2,width:i,height:n,viewBox:`0 0 ${i} ${n}`,animate:t!=!1,backgroundColor:e,foregroundColor:o,children:[r.jsx("rect",{x:"64",y:"0",rx:"4",ry:"4",width:`${i-128}`,height:"21"}),r.jsx("rect",{x:"24",y:"45",rx:"4",ry:"4",width:`${i-48}`,height:"228"})]})}function w({backgroundColor:e,foregroundColor:o,animated:t}){return r.jsxs(x,{speed:2,width:240,height:98,viewBox:"0 0 240 98",animate:t!=!1,backgroundColor:e,foregroundColor:o,children:[r.jsx("rect",{x:"66",y:"0",rx:"4",ry:"4",width:"108",height:"21"}),r.jsx("rect",{x:"44",y:"77",rx:"4",ry:"4",width:"152",height:"21"}),r.jsx("rect",{x:"0",y:"29",rx:"4",ry:"4",width:"240",height:"40"})]})}const u=s(l)`
2
2
  justify-content: flex-start;
3
3
  `;function z({dimension:e,animated:o}){const t=h();return r.jsx(a,{dimension:e,children:r.jsx(u,{children:r.jsx(w,{backgroundColor:t.colors.grey3,foregroundColor:t.colors.grey4,animated:o})})})}function T({dimension:e,animated:o}){const t=h();return r.jsx(a,{dimension:e,children:r.jsx(u,{children:r.jsx("div",{style:{width:"100%",height:"100%"},children:r.jsx(f,{children:({height:i,width:n})=>r.jsx(p,{backgroundColor:t.colors.grey3,foregroundColor:t.colors.grey4,animated:o,width:n,height:i})})})})})}const y=e=>d.createElement("svg",{viewBox:"0 0 72 72",fill:"none",xmlns:"http://www.w3.org/2000/svg",...e},d.createElement("rect",{opacity:.2,width:72,height:72,rx:36,fill:"#97C3B9"}),d.createElement("path",{d:"M46.7755 32.5635L43.8368 36.9716L40.4082 33.0533",stroke:"#97C3B9",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"}),d.createElement("path",{d:"M34.5307 44.8163C32.6902 44.8163 30.8909 44.2705 29.3605 43.248C27.8301 42.2254 26.6374 40.772 25.933 39.0715C25.2286 37.3711 25.0443 35.4999 25.4034 33.6947C25.7625 31.8895 26.6488 30.2313 27.9503 28.9298C29.2518 27.6283 30.91 26.742 32.7152 26.3829C34.5204 26.0238 36.3916 26.2081 38.092 26.9125C39.7925 27.6169 41.2459 28.8096 42.2685 30.34C43.291 31.8704 43.8369 33.6697 43.8369 35.5102V36.9737",stroke:"#97C3B9",strokeWidth:1.5,strokeLinecap:"round",strokeLinejoin:"round"})),k=s(l)`
4
4
  justify-content: space-between;
@@ -1,4 +1,4 @@
1
- import{d as X,q as ie,cr as me,aa as fe,j as o,ap as ge,O as K,cs as ee,ad as xe,y as O,aQ as be,o as n,ct as ye,cu as we,cv as _e,cw as $e,cx as ve,an as ce,cy as Ce,u as p,ai as ke,aC as Q,bI as je,aU as Se,am as Ie,av as Ne}from"./index-D94hlokH.js";import{b as f,w as de,n as d}from"./vendor-Bs1fkIUX.js";import{R as P,I as Oe}from"./CollapsableReportTable-BTquJgcd-BW5UxAeQ.js";const W=K.getLocalizedStrings().dateFormat.analytics.YYYYDashMMDashDDFormat,Pe=e=>({this_period:{start_date:e.thisPeriod.startDate.format(W),end_date:e.thisPeriod.endDate.format(W)},number_of_periods:e.numberOfPeriods,order_by:e.orderBy}),De=e=>e!=null?{start_date:e.startDate.format(W),end_date:e.endDate.format(W)}:void 0;function Fe(e){return{locale_id:e.localeId,show_negative_amount_in_parenthesis:e.showNegativeAmountInParenthesis,filter_accounts_with_nil_balances:e.filterAccountsWithNilBalances,filter_account_groups_with_nil_balances:e.filterAccountGroupsWithNilBalances,include_cover_page:e.includeCoverPage,company_name:e.companyName,statement_file_type:e.statementFileType,statements:e.statements,first_month_of_fy:e.firstMonthOfFY,book_close_date:e.bookCloseDate!=null?e.bookCloseDate.format(W):void 0,timeframe:e.timeframe,additional_balances:e.additionalBalances,format:e.format,balances_filter:Pe(e.balancesFilter),account_view_mode:e.accountViewMode,classes_to_filter_out:e.classesToFilterOut,data_available:De(e.dataAvailable),is_zeni_coa_used:e.isZeniCOAUsed}}async function no(e,c,a){const t=K.getLocalizedStrings().downloadReport,r=`${e}?query=${encodeURIComponent(JSON.stringify(Fe(a)))}`;try{const h=await ye({urlEndPoint:r,authParams:c,fileType:a.statementFileType});if(h.ok){const b=we(h.headers,t.defaultFileName),y=await h.arrayBuffer();_e(y,b)}else console.error(`${t.reportErrorMessage} ${h.statusText}`)}catch(h){console.error(`${t.reportErrorMessage} ${JSON.stringify(h)}`)}}const Be=d.div`
1
+ import{d as X,q as ie,cr as me,aa as fe,j as o,ap as ge,O as K,cs as ee,ad as xe,y as O,aQ as be,o as n,ct as ye,cu as we,cv as _e,cw as $e,cx as ve,an as ce,cy as Ce,u as p,ai as ke,aC as Q,bI as je,aU as Se,am as Ie,av as Ne}from"./index-sAOH0Fje.js";import{b as f,w as de,n as d}from"./vendor-Bs1fkIUX.js";import{R as P,I as Oe}from"./CollapsableReportTable-7iAngywY-CxWB4sRz.js";const W=K.getLocalizedStrings().dateFormat.analytics.YYYYDashMMDashDDFormat,Pe=e=>({this_period:{start_date:e.thisPeriod.startDate.format(W),end_date:e.thisPeriod.endDate.format(W)},number_of_periods:e.numberOfPeriods,order_by:e.orderBy}),De=e=>e!=null?{start_date:e.startDate.format(W),end_date:e.endDate.format(W)}:void 0;function Fe(e){return{locale_id:e.localeId,show_negative_amount_in_parenthesis:e.showNegativeAmountInParenthesis,filter_accounts_with_nil_balances:e.filterAccountsWithNilBalances,filter_account_groups_with_nil_balances:e.filterAccountGroupsWithNilBalances,include_cover_page:e.includeCoverPage,company_name:e.companyName,statement_file_type:e.statementFileType,statements:e.statements,first_month_of_fy:e.firstMonthOfFY,book_close_date:e.bookCloseDate!=null?e.bookCloseDate.format(W):void 0,timeframe:e.timeframe,additional_balances:e.additionalBalances,format:e.format,balances_filter:Pe(e.balancesFilter),account_view_mode:e.accountViewMode,classes_to_filter_out:e.classesToFilterOut,data_available:De(e.dataAvailable),is_zeni_coa_used:e.isZeniCOAUsed}}async function no(e,c,a){const t=K.getLocalizedStrings().downloadReport,r=`${e}?query=${encodeURIComponent(JSON.stringify(Fe(a)))}`;try{const h=await ye({urlEndPoint:r,authParams:c,fileType:a.statementFileType});if(h.ok){const b=we(h.headers,t.defaultFileName),y=await h.arrayBuffer();_e(y,b)}else console.error(`${t.reportErrorMessage} ${h.statusText}`)}catch(h){console.error(`${t.reportErrorMessage} ${JSON.stringify(h)}`)}}const Be=d.div`
2
2
  padding: 0 ${n.sp3} 0 ${n.sp3};
3
3
  border: 1px solid ${e=>e.theme.colors.primary};
4
4
  background: ${e=>e.theme.colors.grey5};
@@ -1,4 +1,4 @@
1
- import{q as W,d as G,O as y,ax as he,l as _,j as r,aM as k,bZ as fe,bH as me,bF as ge,y as v,o as C,aS as _e,P as be,b_ as Se,u as w,B,aC as Q,x as we,aU as Ce,au as ye,bK as xe}from"./index-D94hlokH.js";import{b as P,w as J,n as b}from"./vendor-Bs1fkIUX.js";import{m as z,l as Z}from"./analyticsHelper-ColsUhUK-vardy7WR.js";import{u as Oe}from"./ReportTableViewSelector-oB74PECo-ByHpctQ-.js";import{a as X,p as Re}from"./TimeRangeSwitcher-BRY0oixp-B_RoHkbN.js";import{M as Ae}from"./TimeframeSwitcherWithToggle-utawMrzT-Bill4UcO.js";import{DownloadOverlayButton as Be}from"./DownloadOverlay-XFeHlPT1-CEQi5sme.js";import{I as ve,R as F,x as ee}from"./CollapsableReportTable-BTquJgcd-BW5UxAeQ.js";import{T as te,I as se,L as j,D as Te,g as ne}from"./mapSectionWithAcOnlyToTreeNode-CDE8V8lh-9J1CJPJ0.js";import{s as H}from"./mapTimeframeBalancesToTreeNode-B64chWyJ-CiceKmAm.js";import{d as Le,l as Pe}from"./mapTimeframeHeaderLoadingInProgressToTreeNode-DFgAA2si-DqUkzVrn.js";import{d as ke}from"./mapLoadingInProgressToTreeNode-COnUyXAf-oqBOjgHh.js";import"./mui-Ty75qFQF.js";import"./analytics-CcevxdRy.js";import"./routing-Dk1A2KYI.js";import"./sentry-BE5FTzpq.js";import"./redux-CEhZD0hA.js";import"./liveblocks-8ht9CoL5.js";import"./crypto-cQYYQPTZ.js";import"./TimeframeSwitcher-DIg8e-x0-2kFxMkvp.js";import"./page-detail-CWX5S47F-lMo0MYzU.js";import"./AccountRow-C9q6i3az-Dw8PGRm0.js";function oe({section:e,sectionId:t,numOfBalances:o,config:a}){return ee("no_filter",a.filterAccountsWithNilBalances,a.filterAccountGroupsWithNilBalances).compactedAccountGroupsSelector(e.accountGroups).map(n=>Ie({accountGroup:n,sectionType:t,numOfBalances:o,title:n.accountGroupName,isLastNode:!0,config:a}))}function Ie({accountGroup:e,sectionType:t,numOfBalances:o,title:a,isLastNode:n,config:d}){const p=F("section",[],a+t),l={children:[],id:p,isLastNode:n,reportElementData:{element:{kind:"section",title:a,sectionType:t,data:e,numOfBalances:o},config:d}},i=ee("no_filter",d.filterAccountsWithNilBalances,d.filterAccountGroupsWithNilBalances).compactedAccountsSelectorVariant(e.accounts),u=i.map((g,h)=>ne({account:g,sectionType:t,numOfBalances:o,title:g.account.accountName,config:d,isLastNode:h===i.length-1,parentNodeIDs:[p],ancestorMetadata:{subAccountAncestorMetadata:[{depth:0,hasSibling:i.length>1,hasChildren:g.children.length>0,isLastNode:h===i.length-1}]}}));return l.children.push(...u),l}function ae({sectionWithAcOnly:e,sectionType:t,numOfBalances:o,config:a}){return e.accounts.map((n,d)=>ne({account:n,sectionType:t,numOfBalances:o,title:n.account.accountName,config:a,isLastNode:d===e.accounts.length-1,parentNodeIDs:[],ancestorMetadata:{subAccountAncestorMetadata:[{depth:0,hasSibling:e.accounts.length>1,hasChildren:n.children.length>0,isLastNode:d===e.accounts.length-1}]}}))}function ie({balances:e,config:t,nodeId:o}){return{children:[],id:o??F("timeframe_header",[]),isLastNode:!1,reportElementData:{element:{kind:t.mode==="actual_vs_forecast"?"timeframe_headers_with_forecast":"timeframe_headers",title:"",data:e,numOfBalances:e.length},config:t}}}function Ne(e,t,o,a=!0){Object.assign(e.config,t);const n=ce(o),d=H({balances:n,config:t});return{config:t,headerNodes:a?[d]:[],contentNodes:[d,...e.contentNodes.slice(1)]}}const ce=e=>{switch(e.reportId){case"profit_and_loss":{const t=e;return t.sections.expenses.balances.length>0?[...t.sections.expenses.balances,...t.sections.expenses.additionalBalances]:[...t.sections.income.balances,...t.sections.income.additionalBalances]}case"profit_and_loss_by_classes":{const t=e;return t.sections.expenses.balances.length>0?[...t.sections.expenses.balances,...t.sections.expenses.additionalBalances]:[...t.sections.income.balances,...t.sections.income.additionalBalances]}case"cash_flow":{const t=e;return[...t.calculatedSections.operatingActivitiesTotal.balances,...t.calculatedSections.operatingActivitiesTotal.additionalBalances]}case"balance_sheet":{const t=e;let o=[];return Object.keys(t.sections).forEach(a=>{t.sections[a].balances.length>0&&(o=[...t.sections[a].balances,...t.sections[a].additionalBalances])}),o}default:return[]}};function Me(e,t,o=!0){const a=y.getLocalizedStrings().reports.sections,n=y.getLocalizedStrings().reports.balanceSheet,d=ce(e),p=t.mode!=null&&t.mode==="this_period_vs_period_before"&&d.length>1?e.filter.balancesRange.numberOfPeriods+2:e.filter.balancesRange.numberOfPeriods+1,l=ie({balances:d,config:t}),i=[];return i.push(l),Object.keys(e.rootSectionsWithSubSectionIds).forEach(u=>{const g=F("title_string_only",[],u),h={children:[],id:g,isLastNode:!0,reportElementData:{element:{kind:"title_string_only",title:a[u],data:void 0,numOfBalances:0},config:t}};i.push(h),e.rootSectionsWithSubSectionIds[u].forEach(s=>{if(_.isBalanceSheetReportViewSectionID(s)===!0)if(e.sections[s].accountGroups.length>0)if(s==="equity"){const c=oe({sectionId:s,section:e.sections[s],numOfBalances:p,config:t});i.push(...c)}else i.push(te({section:e.sections[s],sectionType:s,numOfBalances:p,title:n[s],isLastNode:!0,config:t}));else if(s==="equity"){const c=ae({sectionWithAcOnly:e.sections[s],sectionType:s,numOfBalances:p,config:t});i.push(...c)}else{const c=e.sections[s];i.push(se({sectionWithAcOnly:c,sectionType:s,numOfBalances:p,title:n[s],isLastNode:!0,config:t}))}else _.isBalanceSheetReportViewCalculatedSectionID(s)===!0&&i.push(j({calculatedSection:e.calculatedSections[s],numOfBalances:p,title:n[s],isLastNode:!0,config:t}))})}),{config:t,headerNodes:o?[l]:[],contentNodes:i}}function Fe({calculatedSection:e,numOfBalances:t,title:o,isLastNode:a,config:n}){return{children:[],id:F("calculated_section_type1",[],o),isLastNode:a,reportElementData:{element:{kind:"calculated_section_type1",title:o,data:e,numOfBalances:t},config:n}}}function $e(e,t,o=!0){const a=y.getLocalizedStrings().reports.sections,n=y.getLocalizedStrings().reports.cashFlow,d=[...e.calculatedSections.operatingActivitiesTotal.balances,...e.calculatedSections.operatingActivitiesTotal.additionalBalances],p=t.mode!=null&&t.mode==="this_period_vs_period_before"&&d.length>1?e.filter.balancesRange.numberOfPeriods+2:e.filter.balancesRange.numberOfPeriods+1,l=ie({balances:d,config:t}),i=[];return Object.keys(e.rootSectionsWithSubSectionIds).forEach(u=>{const g=F("title_string_only",[],u),h={children:[],id:g,isLastNode:!0,reportElementData:{element:{kind:"title_string_only",title:a[u],data:void 0,numOfBalances:0},config:t}};i.push(h),e.rootSectionsWithSubSectionIds[u].forEach(s=>{if(_.isCashFlowReportViewSectionID(s)===!0)if(e.sections[s].accountGroups.length>0){const c=oe({sectionId:s,section:e.sections[s],numOfBalances:p,config:t});i.push(...c)}else{const c=ae({sectionWithAcOnly:e.sections[s],sectionType:s,numOfBalances:p,config:t});i.push(...c)}else _.isCashFlowReportViewCalculatedSectionType1ID(s)===!0?i.push(Fe({calculatedSection:e.calculatedSections[s],numOfBalances:p,title:n[s],isLastNode:!0,config:t})):_.isCashFlowReportViewCalculatedSectionID(s)===!0&&i.push(j({calculatedSection:e.calculatedSections[s],numOfBalances:p,title:n[s],isLastNode:!0,config:t}))})}),{config:t,headerNodes:o?[l]:[],contentNodes:[l,...i]}}function je(e,t,o=!0,a=!1){const n=y.getLocalizedStrings().reports,d=y.getLocalizedStrings().common;let p=[];const l=[];let i=[];if(a===!0){const u=Le({title:d.loading,balances:[],config:t});u.reportElementData.element.numOfBalances=6,o&&(i=[u]),l.push(u),[...Array(8)].forEach((g,h)=>{const s=h%4;let c=Pe[s];const x=ke({title:`${h}+${c}`,balances:p,config:t});x.reportElementData.element.numOfBalances=6,l.push(x)})}else{const u=e.sections.expenses.balances.length>0?[...e.sections.expenses.balances,...e.sections.expenses.additionalBalances]:e.sections.income.balances.length>0?[...e.sections.income.balances,...e.sections.income.additionalBalances]:e.sections.cogs.balances.length>0?[...e.sections.cogs.balances,...e.sections.cogs.additionalBalances]:e.sections.otherIncome.balances.length>0?[...e.sections.otherIncome.balances,...e.sections.otherIncome.additionalBalances]:e.sections.otherExpenses.balances.length>0?[...e.sections.otherExpenses.balances,...e.sections.otherExpenses.additionalBalances]:[],g=H({balances:u,config:t}),h=t.mode!=null&&t.mode==="this_period_vs_period_before"&&u.length>1?e.filter.balancesRange.numberOfPeriods+2:e.filter.balancesRange.numberOfPeriods+1;l.push(g),o&&(i=[g]),e.idsInOrder.forEach(s=>{if(_.isPandLReportViewSectionID(s)===!0){const c=e.sections[s];c!=null&&l.push(Te({section:c,sectionType:s,numOfBalances:h,title:n.sections[s],isLastNode:!0,config:t}))}else if(_.isPandLReportViewCalculatedSectionID(s)===!0){const c=e.calculatedSections[s];c!=null&&l.push(j({calculatedSection:c,numOfBalances:h,title:n.sections[s],isLastNode:!0,config:t}))}})}return{config:t,headerNodes:i,contentNodes:l}}function Ee(e,t,o=!0){const a=y.getLocalizedStrings().reports,n=e.sections.expenses!=null&&e.sections.expenses.balances.length>0?[...e.sections.expenses.balances,...e.sections.expenses.additionalBalances]:e.sections.income!=null&&e.sections.income.balances.length>0?[...e.sections.income.balances,...e.sections.income.additionalBalances]:e.sections.cogs!=null&&e.sections.cogs.balances.length>0?[...e.sections.cogs.balances,...e.sections.cogs.additionalBalances]:e.sections.otherIncome!=null&&e.sections.otherIncome.balances.length>0?[...e.sections.otherIncome.balances,...e.sections.otherIncome.additionalBalances]:e.sections.otherExpenses!=null&&e.sections.otherExpenses.balances.length>0?[...e.sections.otherExpenses.balances,...e.sections.otherExpenses.additionalBalances]:[],d=t.mode!=null&&t.mode==="this_period_vs_period_before"&&n.length>1?e.filter.balancesRange.numberOfPeriods+2:e.filter.balancesRange.numberOfPeriods+1,p=H({balances:n,config:t}),l=[];return l.push(p),e.idsInOrder.forEach(i=>{if(_.isPandLReportViewSectionID(i)===!0&&(e.sections[i].accountGroups.length>0?l.push(te({section:e.sections[i],sectionType:i,numOfBalances:d,title:a.sections[i],isLastNode:!0,config:t})):l.push(se({sectionWithAcOnly:e.sections[i],sectionType:i,numOfBalances:d,title:a.sections[i],isLastNode:!0,config:t}))),_.isPandLReportViewCalculatedSectionID(i)===!0){const u=e.calculatedSections[i];u!=null&&l.push(j({calculatedSection:u,numOfBalances:d,title:a.sections[i],isLastNode:!0,config:t}))}}),{config:t,headerNodes:o?[p]:[],contentNodes:l}}const q={contentPaddingLeft:new v(w[0],w[0],w[0]),contentPaddingRight:new v(w[3],w[3],w[8])},Ve=b.div`
1
+ import{q as W,d as G,O as y,ax as he,l as _,j as r,aM as k,bZ as fe,bH as me,bF as ge,y as v,o as C,aS as _e,P as be,b_ as Se,u as w,B,aC as Q,x as we,aU as Ce,au as ye,bK as xe}from"./index-sAOH0Fje.js";import{b as P,w as J,n as b}from"./vendor-Bs1fkIUX.js";import{m as z,l as Z}from"./analyticsHelper-or1KkBWk-Plh_6I_p.js";import{u as Oe}from"./ReportTableViewSelector-Ci-WKrCO-DAZRgQwg.js";import{a as X,p as Re}from"./TimeRangeSwitcher-ifkHfqEg-CGFdCObN.js";import{M as Ae}from"./TimeframeSwitcherWithToggle-DH-PfsTQ-Dd12kokF.js";import{DownloadOverlayButton as Be}from"./DownloadOverlay-DRcasKoB-BDQCkt6Q.js";import{I as ve,R as F,x as ee}from"./CollapsableReportTable-7iAngywY-CxWB4sRz.js";import{T as te,I as se,L as j,D as Te,g as ne}from"./mapSectionWithAcOnlyToTreeNode-C9O-C2dp-BYZLhSZo.js";import{s as H}from"./mapTimeframeBalancesToTreeNode-Cv4d4PqE-C559SZVp.js";import{d as Le,l as Pe}from"./mapTimeframeHeaderLoadingInProgressToTreeNode-BaGM4krW-yJCRTG35.js";import{d as ke}from"./mapLoadingInProgressToTreeNode-CRwG2DSD-B4LnWZMC.js";import"./mui-Ty75qFQF.js";import"./analytics-CcevxdRy.js";import"./routing-Dk1A2KYI.js";import"./sentry-BE5FTzpq.js";import"./redux-CEhZD0hA.js";import"./liveblocks-8ht9CoL5.js";import"./crypto-cQYYQPTZ.js";import"./TimeframeSwitcher-BP-PxO5g-DG6ysLlp.js";import"./page-detail-CWX5S47F-lMo0MYzU.js";import"./AccountRow-Be3LIHO--AtWCxnkE.js";function oe({section:e,sectionId:t,numOfBalances:o,config:a}){return ee("no_filter",a.filterAccountsWithNilBalances,a.filterAccountGroupsWithNilBalances).compactedAccountGroupsSelector(e.accountGroups).map(n=>Ie({accountGroup:n,sectionType:t,numOfBalances:o,title:n.accountGroupName,isLastNode:!0,config:a}))}function Ie({accountGroup:e,sectionType:t,numOfBalances:o,title:a,isLastNode:n,config:d}){const p=F("section",[],a+t),l={children:[],id:p,isLastNode:n,reportElementData:{element:{kind:"section",title:a,sectionType:t,data:e,numOfBalances:o},config:d}},i=ee("no_filter",d.filterAccountsWithNilBalances,d.filterAccountGroupsWithNilBalances).compactedAccountsSelectorVariant(e.accounts),u=i.map((g,h)=>ne({account:g,sectionType:t,numOfBalances:o,title:g.account.accountName,config:d,isLastNode:h===i.length-1,parentNodeIDs:[p],ancestorMetadata:{subAccountAncestorMetadata:[{depth:0,hasSibling:i.length>1,hasChildren:g.children.length>0,isLastNode:h===i.length-1}]}}));return l.children.push(...u),l}function ae({sectionWithAcOnly:e,sectionType:t,numOfBalances:o,config:a}){return e.accounts.map((n,d)=>ne({account:n,sectionType:t,numOfBalances:o,title:n.account.accountName,config:a,isLastNode:d===e.accounts.length-1,parentNodeIDs:[],ancestorMetadata:{subAccountAncestorMetadata:[{depth:0,hasSibling:e.accounts.length>1,hasChildren:n.children.length>0,isLastNode:d===e.accounts.length-1}]}}))}function ie({balances:e,config:t,nodeId:o}){return{children:[],id:o??F("timeframe_header",[]),isLastNode:!1,reportElementData:{element:{kind:t.mode==="actual_vs_forecast"?"timeframe_headers_with_forecast":"timeframe_headers",title:"",data:e,numOfBalances:e.length},config:t}}}function Ne(e,t,o,a=!0){Object.assign(e.config,t);const n=ce(o),d=H({balances:n,config:t});return{config:t,headerNodes:a?[d]:[],contentNodes:[d,...e.contentNodes.slice(1)]}}const ce=e=>{switch(e.reportId){case"profit_and_loss":{const t=e;return t.sections.expenses.balances.length>0?[...t.sections.expenses.balances,...t.sections.expenses.additionalBalances]:[...t.sections.income.balances,...t.sections.income.additionalBalances]}case"profit_and_loss_by_classes":{const t=e;return t.sections.expenses.balances.length>0?[...t.sections.expenses.balances,...t.sections.expenses.additionalBalances]:[...t.sections.income.balances,...t.sections.income.additionalBalances]}case"cash_flow":{const t=e;return[...t.calculatedSections.operatingActivitiesTotal.balances,...t.calculatedSections.operatingActivitiesTotal.additionalBalances]}case"balance_sheet":{const t=e;let o=[];return Object.keys(t.sections).forEach(a=>{t.sections[a].balances.length>0&&(o=[...t.sections[a].balances,...t.sections[a].additionalBalances])}),o}default:return[]}};function Me(e,t,o=!0){const a=y.getLocalizedStrings().reports.sections,n=y.getLocalizedStrings().reports.balanceSheet,d=ce(e),p=t.mode!=null&&t.mode==="this_period_vs_period_before"&&d.length>1?e.filter.balancesRange.numberOfPeriods+2:e.filter.balancesRange.numberOfPeriods+1,l=ie({balances:d,config:t}),i=[];return i.push(l),Object.keys(e.rootSectionsWithSubSectionIds).forEach(u=>{const g=F("title_string_only",[],u),h={children:[],id:g,isLastNode:!0,reportElementData:{element:{kind:"title_string_only",title:a[u],data:void 0,numOfBalances:0},config:t}};i.push(h),e.rootSectionsWithSubSectionIds[u].forEach(s=>{if(_.isBalanceSheetReportViewSectionID(s)===!0)if(e.sections[s].accountGroups.length>0)if(s==="equity"){const c=oe({sectionId:s,section:e.sections[s],numOfBalances:p,config:t});i.push(...c)}else i.push(te({section:e.sections[s],sectionType:s,numOfBalances:p,title:n[s],isLastNode:!0,config:t}));else if(s==="equity"){const c=ae({sectionWithAcOnly:e.sections[s],sectionType:s,numOfBalances:p,config:t});i.push(...c)}else{const c=e.sections[s];i.push(se({sectionWithAcOnly:c,sectionType:s,numOfBalances:p,title:n[s],isLastNode:!0,config:t}))}else _.isBalanceSheetReportViewCalculatedSectionID(s)===!0&&i.push(j({calculatedSection:e.calculatedSections[s],numOfBalances:p,title:n[s],isLastNode:!0,config:t}))})}),{config:t,headerNodes:o?[l]:[],contentNodes:i}}function Fe({calculatedSection:e,numOfBalances:t,title:o,isLastNode:a,config:n}){return{children:[],id:F("calculated_section_type1",[],o),isLastNode:a,reportElementData:{element:{kind:"calculated_section_type1",title:o,data:e,numOfBalances:t},config:n}}}function $e(e,t,o=!0){const a=y.getLocalizedStrings().reports.sections,n=y.getLocalizedStrings().reports.cashFlow,d=[...e.calculatedSections.operatingActivitiesTotal.balances,...e.calculatedSections.operatingActivitiesTotal.additionalBalances],p=t.mode!=null&&t.mode==="this_period_vs_period_before"&&d.length>1?e.filter.balancesRange.numberOfPeriods+2:e.filter.balancesRange.numberOfPeriods+1,l=ie({balances:d,config:t}),i=[];return Object.keys(e.rootSectionsWithSubSectionIds).forEach(u=>{const g=F("title_string_only",[],u),h={children:[],id:g,isLastNode:!0,reportElementData:{element:{kind:"title_string_only",title:a[u],data:void 0,numOfBalances:0},config:t}};i.push(h),e.rootSectionsWithSubSectionIds[u].forEach(s=>{if(_.isCashFlowReportViewSectionID(s)===!0)if(e.sections[s].accountGroups.length>0){const c=oe({sectionId:s,section:e.sections[s],numOfBalances:p,config:t});i.push(...c)}else{const c=ae({sectionWithAcOnly:e.sections[s],sectionType:s,numOfBalances:p,config:t});i.push(...c)}else _.isCashFlowReportViewCalculatedSectionType1ID(s)===!0?i.push(Fe({calculatedSection:e.calculatedSections[s],numOfBalances:p,title:n[s],isLastNode:!0,config:t})):_.isCashFlowReportViewCalculatedSectionID(s)===!0&&i.push(j({calculatedSection:e.calculatedSections[s],numOfBalances:p,title:n[s],isLastNode:!0,config:t}))})}),{config:t,headerNodes:o?[l]:[],contentNodes:[l,...i]}}function je(e,t,o=!0,a=!1){const n=y.getLocalizedStrings().reports,d=y.getLocalizedStrings().common;let p=[];const l=[];let i=[];if(a===!0){const u=Le({title:d.loading,balances:[],config:t});u.reportElementData.element.numOfBalances=6,o&&(i=[u]),l.push(u),[...Array(8)].forEach((g,h)=>{const s=h%4;let c=Pe[s];const x=ke({title:`${h}+${c}`,balances:p,config:t});x.reportElementData.element.numOfBalances=6,l.push(x)})}else{const u=e.sections.expenses.balances.length>0?[...e.sections.expenses.balances,...e.sections.expenses.additionalBalances]:e.sections.income.balances.length>0?[...e.sections.income.balances,...e.sections.income.additionalBalances]:e.sections.cogs.balances.length>0?[...e.sections.cogs.balances,...e.sections.cogs.additionalBalances]:e.sections.otherIncome.balances.length>0?[...e.sections.otherIncome.balances,...e.sections.otherIncome.additionalBalances]:e.sections.otherExpenses.balances.length>0?[...e.sections.otherExpenses.balances,...e.sections.otherExpenses.additionalBalances]:[],g=H({balances:u,config:t}),h=t.mode!=null&&t.mode==="this_period_vs_period_before"&&u.length>1?e.filter.balancesRange.numberOfPeriods+2:e.filter.balancesRange.numberOfPeriods+1;l.push(g),o&&(i=[g]),e.idsInOrder.forEach(s=>{if(_.isPandLReportViewSectionID(s)===!0){const c=e.sections[s];c!=null&&l.push(Te({section:c,sectionType:s,numOfBalances:h,title:n.sections[s],isLastNode:!0,config:t}))}else if(_.isPandLReportViewCalculatedSectionID(s)===!0){const c=e.calculatedSections[s];c!=null&&l.push(j({calculatedSection:c,numOfBalances:h,title:n.sections[s],isLastNode:!0,config:t}))}})}return{config:t,headerNodes:i,contentNodes:l}}function Ee(e,t,o=!0){const a=y.getLocalizedStrings().reports,n=e.sections.expenses!=null&&e.sections.expenses.balances.length>0?[...e.sections.expenses.balances,...e.sections.expenses.additionalBalances]:e.sections.income!=null&&e.sections.income.balances.length>0?[...e.sections.income.balances,...e.sections.income.additionalBalances]:e.sections.cogs!=null&&e.sections.cogs.balances.length>0?[...e.sections.cogs.balances,...e.sections.cogs.additionalBalances]:e.sections.otherIncome!=null&&e.sections.otherIncome.balances.length>0?[...e.sections.otherIncome.balances,...e.sections.otherIncome.additionalBalances]:e.sections.otherExpenses!=null&&e.sections.otherExpenses.balances.length>0?[...e.sections.otherExpenses.balances,...e.sections.otherExpenses.additionalBalances]:[],d=t.mode!=null&&t.mode==="this_period_vs_period_before"&&n.length>1?e.filter.balancesRange.numberOfPeriods+2:e.filter.balancesRange.numberOfPeriods+1,p=H({balances:n,config:t}),l=[];return l.push(p),e.idsInOrder.forEach(i=>{if(_.isPandLReportViewSectionID(i)===!0&&(e.sections[i].accountGroups.length>0?l.push(te({section:e.sections[i],sectionType:i,numOfBalances:d,title:a.sections[i],isLastNode:!0,config:t})):l.push(se({sectionWithAcOnly:e.sections[i],sectionType:i,numOfBalances:d,title:a.sections[i],isLastNode:!0,config:t}))),_.isPandLReportViewCalculatedSectionID(i)===!0){const u=e.calculatedSections[i];u!=null&&l.push(j({calculatedSection:u,numOfBalances:d,title:a.sections[i],isLastNode:!0,config:t}))}}),{config:t,headerNodes:o?[p]:[],contentNodes:l}}const q={contentPaddingLeft:new v(w[0],w[0],w[0]),contentPaddingRight:new v(w[3],w[3],w[8])},Ve=b.div`
2
2
  height: ${e=>e.height}px;
3
3
  width: 99.9%;
4
4
  margin-top: ${C.sp2};
@@ -1,4 +1,4 @@
1
- import{d as A,j as a,O as S,q as de,aM as Ae,b3 as Z,bQ as Te,u as E,bR as J,bh as ee,C as M,bg as ae,aX as re,bS as oe,bT as ge,o as m,bU as te,h as g,aC as Ve,bV as pe,bW as me,y as xe,bX as fe,am as P,bY as V,b9 as F}from"./index-D94hlokH.js";import{b as R,w as le,n as x}from"./vendor-Bs1fkIUX.js";import{p as b,d as ne,y as W,b as N,g as ce,u as T}from"./chartTypes-BFE_S1PL-DOHRtqWo.js";import{i as K,h as se,c as I}from"./toCOABalancesWithID-BK1XA0gz-D3HM3wW9.js";import{V as Q}from"./toChartData-D7n7RyVD-Ugd_lC5Y.js";const X={legendLabelMarginLeft:new xe(2,2),legendLabelMarginRight:new xe(E[3],E[4])},Fe=x.div`
1
+ import{d as A,j as a,O as S,q as de,aM as Ae,b3 as Z,bQ as Te,u as E,bR as J,bh as ee,C as M,bg as ae,aX as re,bS as oe,bT as ge,o as m,bU as te,h as g,aC as Ve,bV as pe,bW as me,y as xe,bX as fe,am as P,bY as V,b9 as F}from"./index-sAOH0Fje.js";import{b as R,w as le,n as x}from"./vendor-Bs1fkIUX.js";import{p as b,d as ne,y as W,b as N,g as ce,u as T}from"./chartTypes-DCvOVjlS-BdPIN5WI.js";import{i as K,h as se,c as I}from"./toCOABalancesWithID-B3yVGPrV-B_BzNOYP.js";import{V as Q}from"./toChartData-DEW0iT7T-DrkbvIyQ.js";const X={legendLabelMarginLeft:new xe(2,2),legendLabelMarginRight:new xe(E[3],E[4])},Fe=x.div`
2
2
  display: flex;
3
3
  `,He=x.div`
4
4
  margin: ${m.sp2} ${m.sp0} ${m.sp2} ${m.sp0};
@@ -1,4 +1,4 @@
1
- import{q as Tt,ax as jt,y,fg as vt,O as St,fh as Ct,fi as Dt,j as t,fj as It,fk as le,fl as Pt,l as d,fm as At,fn as kt,aM as v,fo as Mt,aN as k,fp as Bt,fq as Nt,fr as ke,fs as Me,ft as Be,C as Y,fu as O,fv as z,fw as _,h as S,fx as Rt,fy as Et,fz as Ft,fA as Lt,c5 as Ne,o as n,aQ as Ot,u as c,aj as zt,cg as _t,c as Wt,H as Ht,fB as Ut,cw as Zt,am as se,an as de,fC as qt,fD as Vt,bm as Yt,s as Gt,b8 as Kt,ar as Xe,bP as Xt,ai as Qe,bx as Qt,fE as Jt}from"./index-D94hlokH.js";import{b as H,n as i}from"./vendor-Bs1fkIUX.js";import{t as en,o as tn}from"./LowBalancePopup-C3XwZy2N-CiNVfO8z.js";import{S as W}from"./LabeledText-nWCZBDTc-C9SVi_iV.js";import"./mui-Ty75qFQF.js";import"./analytics-CcevxdRy.js";import"./routing-Dk1A2KYI.js";import"./sentry-BE5FTzpq.js";import"./redux-CEhZD0hA.js";import"./liveblocks-8ht9CoL5.js";import"./crypto-cQYYQPTZ.js";const Je=["small","medium-compact","medium-regular"],p={largeLabelWidth:new y(150,215,215),infoMinWidth:new y(0,0,0,142,142),infoMarginRight:new y(0,0,0,c[2],c[2]),footerButtonWidth:new y(120,165),iconContainerMarginTop:new y(6,c[1]),navBarContainerPaddingTop:new y(10,c[3]),sectionTitleMarginLeft:new y(c[3],c[0]),reviewContainerMarginLeft:new y(c[3],c[6]),reviewContainerMarginRight:new y(c[3],c[8]),footerRightIconMarginRight:new y(c[0],c[0],c[7]),infoLabelPaddingRight:new y(c[0],c[3]),infoLabelMarginTop:new y(c[1],c[0])},nn={sectionTitle:new Wt("h6Medium","h5Medium")},{dateFormat:Re,common:{currency:j,labels:Ee,edit:an,strings:{empty:h}},spendManagement:{billPay:ln}}=St.getLocalizedStrings(),{billDetails:a,paymentDetails:Fe}=ln,Le=({attachment:e})=>{const[w,x]=H.useState(!1),M=()=>{x(!1)},C=e.fileId?.length===0;return t.jsxs(Bn,{isDisabled:e.fileId?.length===0,"data-testid":v("attachment-tag",e.fileName),onClick:()=>C===!1?x(!0):null,children:[w&&e?.fileDownloadUrl!=null?t.jsx(qt,{title:e.fileName,file:e,onCrossClick:()=>M(),setShowFullScreenView:x}):null,t.jsx(Nn,{children:t.jsx(Vt,{contentType:e.contentType})})]})},ti=({billDetails:e,billpayApprovalView:w,isBillPayCommentingEnabled:x,currentTenant:M,isInternationalPaymentShaVsOurEnabled:C,isLocalCurrencyEnabled:et,style:tt,analytics:$,isRecurringBillsFeatureEnabled:nt,isApprovalRequiredForMarkAsPaid:it,isDetectInsufficientFundsEnabled:at,billId:f,onClickEdit:ce,discardBillDetailsFromLocalStore:me,saveBillDetails:pe,discardOutsideZeniPaymentData:lt,updateBillDetailSaveBillCode:ue,redirectToBillsScreen:ye,onAttachmentClick:Q,retryPayment:ot})=>{const s=Tt(),m=jt(),B={application:"dashboard",companyId:m.currentTenant?.companyId,tab:"bill",entityId:f},N=x&&f!=null,R=`dashboard_${m.currentTenant?.companyId}`,E=p.largeLabelWidth.value(s),F=e.saveStatus,J=e.zeniAssistRetryStatus,ee=e.vendor?.vendorCurrencyCode,o=vt(C,et,e.billPayConfigList.filter(l=>l.method.includes(e.paymentDetailsSection?.withdrawFrom?.accType??"depositAccount")),e.paymentDetailsSection?.internationalTransferFeeBearerPaymentMethod,e.paymentDetailsSection?.paymentType,ee),D=Re.visual.MMMDCommaYYYYformat,he={amount:e.recipientTotalAmount.amount/(e.paymentDetailsSection?.conversionRate??1)*100/100,currencyCode:j.currencyCode,currencySymbol:j.currencySymbol},u={amount:o?.method.includes("international")===!0?Ct(he,o):e.recipientTotalAmount.amount+(o?.fee.amount??0),currencyCode:j.currencyCode,currencySymbol:j.currencySymbol},L={amount:o?.method.includes("international")===!0?Dt(he,o):o?.fee.amount??0,currencyCode:j.currencyCode,currencySymbol:j.currencySymbol},[rt,ge]=H.useState(!1),[st,xe]=H.useState(!1),fe=()=>ge(!1),dt=()=>{$.trackBillPayMagicLinkPreviewEmail("review_bill"),ge(!0)},ct=e.isCollectToAccountInfoFromVendorContact?t.jsxs(t.Fragment,{children:[`${a.magicLink.collectFrom} ${e.toAccountVendorEmail}`,t.jsx(An,{size:s,children:t.jsx(Pn,{})})]}):It(e.paymentDetailsSection?.paymentTo);H.useEffect(()=>{(F?.fetchState==="Completed"||J?.fetchState==="Completed")&&(me(),ue(),ye())},[F,J,ye,me,ue]);const T=e.billPayInfo?.stage,P=e.billPayInfo?.billStatus,U=e.billPayInfo?.billPaymentStatus,mt=e.billPayInfo?.billPaymentRefundStatus,te=T?.code==="paid"?T:P?.code=="approved"&&U?.code?U:P,pt=e.billPayInfo?.isRefundInitiated===!0?mt:P?.code=="approved"&&U?.code?U:P,ne=()=>{ce()},be=()=>{ce()},Z=e.paymentDetailsSection?.paymentDate,ie=le(o?.method??""),we=ie.replace("Same Day",""),ut=e.isCollectToAccountInfoFromVendorContact?t.jsx(Pt,{paymentTypeLabel:we,onClick:dt}):a.addedByZeni,q=w.allApprovalRules.length>0,yt=d.toAmount(o?.method!=null&&(o.method.includes(d.NEW_INTERNATIONAL_METHOD_SUBTEXT)||o?.fee.amount!=null&&o.fee.amount!==0)?u.amount-L.amount:u.amount,o?.fee.currencyCode??d.defaultVendorCurrency.currencyCode,o?.fee.currencySymbol??d.defaultVendorCurrency.currencySymbol),g=d.isPaymentMethodOutsideZeni(e.paymentDetailsSection?.paymentType?.method),ht=l=>{$.trackBillPayMarkAsPaidSubmit(l.paymentMode??"other",T?.code??"draft",te?.code??""),pe(!0,l)},$e=()=>{xe(!0),$.trackBillPayMarkAsPaid(T?.code??"draft",te?.code??"")},gt=()=>{lt(),xe(!1)},A=g&&(T?.code!=null?T.code==="draft"||P?.code==="approved":!0),b=A&&!it,Te=Oe(b,q,e.isBillMarkedForRetry),xt=()=>g?b?void 0:a.paymentOutsideZeni.reviewInfo:o?.method!=null&&o.method.includes(d.NEW_INTERNATIONAL_METHOD_SUBTEXT)&&e.paymentDetailsSection?.internationalTransferFeeBearerPaymentMethod!=null&&C&&ee===j.currencyCode?Et(e.paymentDetailsSection.internationalTransferFeeBearerPaymentMethod):void 0,ae=at&&e.paymentDetailsSection!=null?At(u,e.paymentDetailsSection.withdrawFrom,e.paymentDetailsSection.paymentDate):void 0,ft=()=>{const l=e.paymentDetailsSection?.paymentDate,r=e.isCollectToAccountInfoFromVendorContact,I=e.recurringConfig,wt=e.recipientTotalAmount;if(e.isInvoiceDateAutoUpdated===!0&&$.trackBillPayAutoDateChange(f??"new_bill"),o?.method!=null&&l!=null){const $t=g?a.paymentOutsideZeni.offline:le(o.method);if($.trackBillPaySendForApproval($t,l.format(Re.analytics.MMMDashDDDashYYYYFormat),r,e.isRecurring,f,e.paymentDetailsSection?.internationalTransferFeeBearerPaymentMethod,{startDate:d.zeniDate(I?.startDate?.toString()??"").format(D),endDate:d.zeniDate(I?.endDate?.toString()??"").format(D),frequency:I?.frequency??"monthly",totalAmount:wt.amount,totalPaymentCycles:I?.totalPaymentCycles??0,isApprovalRequired:I?.isApprovalRequired??!1,updateCurrentBill:e.recurringConfig?.id!=null?I?.updateRecurringBills==="current":void 0,updateFutureRecurringBills:e.recurringConfig?.id!=null?I?.updateRecurringBills==="all":void 0}),ae!=null){const Se=T?.code??"draft",Ce=P?.code??"",De=e.isRecurring?["Recurring"]:["One-Time"],Ie=e.invoiceNumber??"",Pe=Jt(m.loggedInUser),Ae=e.paymentDetailsSection?.withdrawFrom?.accType==="depositAccount"?"ZA":"External Account";Te===a.scheduleBill?$.trackLowBalanceAccountSchedule(Se,Ce,De,Ie,Pe,Ae):Te===a.sendForApproval&&$.trackLowBalanceAccountSentForApproval(Se,Ce,De,Ie,Pe,Ae)}}},je=()=>{ve===!0&&V(!1),e.isBillMarkedForRetry===!0?(ot(),$.trackRetryConfirmClick(te?.code??"",T?.code??"",pt?.description??"",e.isRecurring?["Recurring"]:["One-Time"],e.invoiceNumber??"")):e.vendor!=null&&(ft(),pe(!1,{}))},bt=d.checkIfCreatorIsApprover(u.amount,w.allApprovalRules,m.loggedInUser),[ve,V]=H.useState(!1);return t.jsxs(hn,{children:[st?t.jsx(en,{onCancel:gt,onProceedForMarkAsPaid:ht,saveDetailsFetchState:F?.fetchState,paymentData:e.outsideZeniPaymentInfo}):null,ve?t.jsx(tn,{withdrawFrom:e.paymentDetailsSection?.withdrawFrom,paymentDate:e.paymentDetailsSection?.paymentDate,onOkClick:je,onCancelClick:()=>{V(!1),ne()},onClickAway:()=>{V(!1)}}):null,t.jsx(kt,{anchor:"right",open:rt,onClose:fe,transitionDuration:250,"data-testid":v("vendor-email-preview-drawer"),children:t.jsx(Mt,{companyName:Bt(M.company?.companyInfo),vendor:e.vendor?.name,paymentDate:Z?.format(D)??"",paymentType:we,amount:k("0,0[.]00",u),isInvoiceAttached:!!e.file,onClose:fe})}),t.jsxs(gn,{windowSize:s,style:tt,children:[s==="small"?t.jsxs(In,{windowSize:s,children:[t.jsx(qe,{onClick:be,"data-testid":v("review-detail-nav-bar-small-back")}),t.jsx(We,{windowSize:s,children:a.oneLastLook})]}):t.jsx(Dn,{"data-testid":v("review-details-nav-bar-back"),children:t.jsx(qe,{onClick:be})}),s!=="small"?t.jsx(fn,{children:t.jsx(We,{windowSize:s,children:a.oneLastLook})}):null,e.duplicateBillTransactions.length>0?t.jsxs(bn,{children:[t.jsxs(wn,{children:[t.jsx(zn,{}),t.jsxs($n,{children:[t.jsx(jn,{children:a.duplicateBillPayWarning}),t.jsxs(Tn,{children:[a.duplicateBillPayWarningSubHeading,t.jsxs("span",{"data-testid":v("review-detail-attachment-button"),onClick:()=>Q(e.duplicateBillTransactions[0].id,e.duplicateBillTransactions[0].billPayInfo.stage.code),style:{textDecoration:"underline",cursor:"pointer"},children:[a.viewBill,e.duplicateBillTransactions[0].documentId]})]})]})]}),t.jsxs(Fn,{children:[t.jsx(On,{children:a.duplicateInvoiceFound}),e.duplicateBillTransactions.map(l=>{const r=Nt(l);return l!=null?t.jsx(Ln,{children:Je.includes(s)?t.jsxs(He,{windowSize:s,children:[t.jsxs(vn,{children:[t.jsxs(Sn,{children:[l.attachments&&l.attachments.length>0?t.jsx(Le,{attachment:l.attachments[0]}):t.jsx(Ve,{children:t.jsx(Ye,{})}),t.jsx(K,{children:t.jsxs(t.Fragment,{children:[l.documentId!=null?a.invoiceNo:null,l.documentId]})})]}),t.jsx(Ge,{windowSize:s,children:k("0,0[.]00",l.recipientTotalAmount)})]}),t.jsxs(Rn,{"data-testid":v("review-detail-mobile-info"),onClick:()=>Q(l.id,l.billPayInfo.stage.code),children:[t.jsxs(K,{children:[l.dueDate!=null?a.due:null," ",l.dueDate?.format(D)]}),t.jsx(Ke,{children:r!=null?ke.includes(r.code)?t.jsx(Me,{style:{padding:"2px 5px"},title:r.value,placement:"top",children:t.jsx(X,{color:r.color,bgColor:r.bgColor,borderColor:r.borderColor,children:r.value})}):t.jsx(X,{color:r.color,bgColor:r.bgColor,borderColor:r.borderColor,children:r.value}):null})]})]}):t.jsxs(He,{windowSize:s,children:[l.attachments&&l.attachments.length>0?t.jsx(Le,{attachment:l.attachments[0]}):t.jsx(Ve,{children:t.jsx(Ye,{})}),t.jsxs(En,{"data-testid":v("review-detail-info"),onClick:()=>Q(l.id,l.billPayInfo.stage.code),children:[t.jsx(K,{style:{width:"50%"},children:t.jsxs("div",{children:[l.documentId!=null?a.invoiceNo:null," ",l.documentId]})}),t.jsxs(K,{style:{width:"25%"},children:[l.dueDate!=null?a.due:null," ",l.dueDate?.format(D)]}),t.jsx(Ge,{style:{width:"25%"},windowSize:s,children:k("0,0[.]00",l.amount)})]}),t.jsx(Ke,{children:r!=null?ke.includes(r.code)?t.jsx(Me,{style:{padding:"2px 5px"},title:r.value,placement:"top",children:t.jsx(X,{color:r.color,bgColor:r.bgColor,borderColor:r.borderColor,children:r.value})}):t.jsx(X,{color:r.color,bgColor:r.bgColor,borderColor:r.borderColor,children:r.value}):null})]})},l.id):null})]})]}):null,t.jsxs(Cn,{children:[t.jsx(Ue,{children:a.pay}),t.jsx(Ze,{children:t.jsx(Be,{amount:yt,integerStyles:Y.largeMedium.cssObject,decimalStyles:Y.smallMedium.cssObject})}),t.jsx(Ue,{children:a.to}),t.jsx(Ze,{children:e.vendor?.name})]}),t.jsxs(xn,{children:[g?null:t.jsxs(t.Fragment,{children:[t.jsx(O,{isThreadAllowed:N,entityId:f,dashboardTabKey:_({type:"details",key:"withdrawFrom"}),roomId:R,companyId:m.currentTenant?.companyId??h,companyName:m.currentTenant?.companyName??h,dashboardOptionType:"bill",filterMetaData:{...B,entityType:`bill.details.${z("withdrawFrom")}`},children:t.jsx(W,{label:{label:a.withdrawFrom,width:E},style:{width:"auto"},value:e.paymentDetailsSection?.withdrawFrom!=null?Rt(e.paymentDetailsSection.withdrawFrom,s):h,infoLabelStyle:{textAlign:s==="small"?"left":"right",paddingRight:p.infoLabelPaddingRight.valuePx(s),marginTop:p.infoLabelMarginTop.valuePx(s),color:S.brandColorGoldDark},additionalInfoLabel:ae})}),t.jsx(G,{})]}),t.jsx(O,{isThreadAllowed:N,entityId:f,dashboardTabKey:_({type:"details",key:"paymentType"}),roomId:R,companyId:m.currentTenant?.companyId??h,companyName:m.currentTenant?.companyName??h,dashboardOptionType:"bill",filterMetaData:{...B,entityType:`bill.details.${z("paymentType")}`},children:t.jsx(W,{label:{label:a.paymentMethod,width:E},style:{width:"auto"},value:le(o?.method??""),additionalInfoLabel:xt()})}),t.jsx(G,{}),!g&&Z!=null?t.jsxs(t.Fragment,{children:[t.jsx(O,{isThreadAllowed:N,entityId:f,dashboardTabKey:_({type:"details",key:"paymentDate"}),roomId:R,companyId:m.currentTenant?.companyId??h,companyName:m.currentTenant?.companyName??h,dashboardOptionType:"bill",filterMetaData:{...B,entityType:`bill.details.${z("paymentDate")}`},children:t.jsx(W,{label:{label:a.paymentDate,width:E},style:{width:"auto"},value:Z.format(D),additionalInfoLabel:`${a.estimatedArrival}${d.zeniDate(d.getNextNthWorkingDay(Z.toDate(),[0,6],o?.maxPeriod.value??0).toDateString()).format(D)} - (${ie.length>0?`${ie} `:""}${a.deliveryTimeLabel} = ${o?.maxPeriod.value??"0"} ${a.deliveryTimeUnits})`})}),t.jsx(G,{})]}):null,g?null:t.jsx(O,{isThreadAllowed:N,entityId:f,dashboardTabKey:_({type:"details",key:"paymentTo"}),roomId:R,companyId:m.currentTenant?.companyId??h,companyName:m.currentTenant?.companyName??h,dashboardOptionType:"bill",filterMetaData:{...B,entityType:`bill.details.${z("paymentTo")}`},children:t.jsx(W,{label:{label:a.paymentTo,width:E},style:{width:"auto"},value:ct??"",additionalInfoLabel:ut})}),g||nt?t.jsxs(t.Fragment,{children:[t.jsx(G,{}),t.jsx(O,{isThreadAllowed:N,entityId:f,dashboardTabKey:_({type:"details",key:"recurringPaymentType"}),roomId:R,companyId:m.currentTenant?.companyId??h,companyName:m.currentTenant?.companyName??h,dashboardOptionType:"bill",filterMetaData:{...B,entityType:`bill.details.${z("recurringPaymentType")}`},children:t.jsx(W,{label:{label:a.paymentType,width:E},style:{width:"auto"},value:Lt(e.isRecurring,g,e.recurringBillInstance??1,e.recurringConfig?.totalPaymentCycles??0),additionalInfoLabel:Ft(s,e.isRecurring,g,e.recurringConfig)})})]}):null]}),!g&&o?.method!=null&&(o.method.includes(d.NEW_INTERNATIONAL_METHOD_SUBTEXT)||o?.fee.amount!=null&&o.fee.amount!==0)?t.jsx(mn,{children:t.jsxs(pn,{windowSize:s,children:[t.jsxs(un,{children:[t.jsx(sn,{children:a.total}),t.jsx(Ne,{style:{padding:`12px ${n.sp3}`,lineHeight:"18px"},maxWidth:"312px",title:t.jsxs(cn,{children:[t.jsxs(_e,{children:[t.jsx(re,{children:o.method.includes(d.NEW_INTERNATIONAL_METHOD_SUBTEXT)&&ee!==j.currencyCode?Fe.conversionAmountColon:Ee.invoiceAmount}),t.jsx(oe,{children:k("0,0[.]00",{amount:u.amount-L.amount,currencySymbol:L.currencySymbol})})]}),t.jsxs(_e,{children:[t.jsx(re,{children:Fe.transactionFee}),t.jsx(oe,{children:k("0,0[.]00",{amount:L.amount,currencySymbol:L.currencySymbol})})]}),t.jsx(dn,{}),t.jsxs(rn,{children:[t.jsx(re,{children:Ee.total}),t.jsx(oe,{children:k("0,0[.]00",{amount:u.amount,currencyCode:u.currencyCode,currencySymbol:u.currencySymbol})})]})]}),placement:"top-end",children:t.jsx(on,{})})]}),t.jsx(yn,{children:t.jsx(Be,{amount:d.toAmount(u.amount,u.currencyCode,u.currencySymbol),integerStyles:Y.h6Medium.cssObject,decimalStyles:Y.standardMedium.cssObject})})]})}):null]}),t.jsx(Ot,{cancelBtn:{label:A&&!b?a.paymentOutsideZeni.markAsPaid:a.editBill,onClick:A&&!b?$e:ne,style:{width:ze(!1,A,b,q,s)}},primaryBtn:{label:Oe(b,q,e.isBillMarkedForRetry),isLoading:F?.fetchState==="In-Progress"||J?.fetchState==="In-Progress",onClick:b?$e:()=>{bt&&ae!=null?V(!0):je()},style:{width:ze(!0,A,b,q,s)}},rightSideComponent:A&&!b&&F.fetchState!=="In-Progress"?t.jsx(_n,{windowSize:s,children:t.jsx(Ne,{style:{color:S.heroDark,padding:`2px ${n.sp2}`},display:"flex",title:an,placement:"top",children:t.jsx(Hn,{onClick:ne,"data-testid":v("review-detail-edit-bill-button"),children:t.jsx(Wn,{})})})}):null,style:{minHeight:e.paymentDetailsSection?.paymentType?.method!=null&&e.paymentDetailsSection.paymentType.method.includes(d.NEW_INTERNATIONAL_METHOD_SUBTEXT)?127:62,...e.paymentDetailsSection?.paymentType?.method!=null&&e.paymentDetailsSection.paymentType.method.includes(d.NEW_INTERNATIONAL_METHOD_SUBTEXT)&&{padding:n.sp3,rowGap:n.sp3}},children:e.paymentDetailsSection?.paymentType?.method!=null&&e.paymentDetailsSection.paymentType.method.includes(d.NEW_INTERNATIONAL_METHOD_SUBTEXT)?t.jsxs(kn,{children:[a.internationalText1,t.jsx(Mn,{href:"https://www.nium.com/legal/end-customer-terms",target:"_Blank",rel:"noopener noreferrer",children:a.internationalTerms}),a.internationalText2]}):null})]})},Oe=(e,w,x)=>e?a.paymentOutsideZeni.markAsPaid:x===!0?a.retryPayment:w?a.sendForApproval:a.scheduleBill,ze=(e,w,x,M,C)=>x?128:w&&!e&&C==="small"?"auto":M?165:p.footerButtonWidth.value(C),on=i(Xt)`
1
+ import{q as Tt,ax as jt,y,fg as vt,O as St,fh as Ct,fi as Dt,j as t,fj as It,fk as le,fl as Pt,l as d,fm as At,fn as kt,aM as v,fo as Mt,aN as k,fp as Bt,fq as Nt,fr as ke,fs as Me,ft as Be,C as Y,fu as O,fv as z,fw as _,h as S,fx as Rt,fy as Et,fz as Ft,fA as Lt,c5 as Ne,o as n,aQ as Ot,u as c,aj as zt,cg as _t,c as Wt,H as Ht,fB as Ut,cw as Zt,am as se,an as de,fC as qt,fD as Vt,bm as Yt,s as Gt,b8 as Kt,ar as Xe,bP as Xt,ai as Qe,bx as Qt,fE as Jt}from"./index-sAOH0Fje.js";import{b as H,n as i}from"./vendor-Bs1fkIUX.js";import{t as en,o as tn}from"./LowBalancePopup-CZDcHxyW-BHOAXZjC.js";import{S as W}from"./LabeledText-BESSkt5Z-DvRhicFs.js";import"./mui-Ty75qFQF.js";import"./analytics-CcevxdRy.js";import"./routing-Dk1A2KYI.js";import"./sentry-BE5FTzpq.js";import"./redux-CEhZD0hA.js";import"./liveblocks-8ht9CoL5.js";import"./crypto-cQYYQPTZ.js";const Je=["small","medium-compact","medium-regular"],p={largeLabelWidth:new y(150,215,215),infoMinWidth:new y(0,0,0,142,142),infoMarginRight:new y(0,0,0,c[2],c[2]),footerButtonWidth:new y(120,165),iconContainerMarginTop:new y(6,c[1]),navBarContainerPaddingTop:new y(10,c[3]),sectionTitleMarginLeft:new y(c[3],c[0]),reviewContainerMarginLeft:new y(c[3],c[6]),reviewContainerMarginRight:new y(c[3],c[8]),footerRightIconMarginRight:new y(c[0],c[0],c[7]),infoLabelPaddingRight:new y(c[0],c[3]),infoLabelMarginTop:new y(c[1],c[0])},nn={sectionTitle:new Wt("h6Medium","h5Medium")},{dateFormat:Re,common:{currency:j,labels:Ee,edit:an,strings:{empty:h}},spendManagement:{billPay:ln}}=St.getLocalizedStrings(),{billDetails:a,paymentDetails:Fe}=ln,Le=({attachment:e})=>{const[w,x]=H.useState(!1),M=()=>{x(!1)},C=e.fileId?.length===0;return t.jsxs(Bn,{isDisabled:e.fileId?.length===0,"data-testid":v("attachment-tag",e.fileName),onClick:()=>C===!1?x(!0):null,children:[w&&e?.fileDownloadUrl!=null?t.jsx(qt,{title:e.fileName,file:e,onCrossClick:()=>M(),setShowFullScreenView:x}):null,t.jsx(Nn,{children:t.jsx(Vt,{contentType:e.contentType})})]})},ti=({billDetails:e,billpayApprovalView:w,isBillPayCommentingEnabled:x,currentTenant:M,isInternationalPaymentShaVsOurEnabled:C,isLocalCurrencyEnabled:et,style:tt,analytics:$,isRecurringBillsFeatureEnabled:nt,isApprovalRequiredForMarkAsPaid:it,isDetectInsufficientFundsEnabled:at,billId:f,onClickEdit:ce,discardBillDetailsFromLocalStore:me,saveBillDetails:pe,discardOutsideZeniPaymentData:lt,updateBillDetailSaveBillCode:ue,redirectToBillsScreen:ye,onAttachmentClick:Q,retryPayment:ot})=>{const s=Tt(),m=jt(),B={application:"dashboard",companyId:m.currentTenant?.companyId,tab:"bill",entityId:f},N=x&&f!=null,R=`dashboard_${m.currentTenant?.companyId}`,E=p.largeLabelWidth.value(s),F=e.saveStatus,J=e.zeniAssistRetryStatus,ee=e.vendor?.vendorCurrencyCode,o=vt(C,et,e.billPayConfigList.filter(l=>l.method.includes(e.paymentDetailsSection?.withdrawFrom?.accType??"depositAccount")),e.paymentDetailsSection?.internationalTransferFeeBearerPaymentMethod,e.paymentDetailsSection?.paymentType,ee),D=Re.visual.MMMDCommaYYYYformat,he={amount:e.recipientTotalAmount.amount/(e.paymentDetailsSection?.conversionRate??1)*100/100,currencyCode:j.currencyCode,currencySymbol:j.currencySymbol},u={amount:o?.method.includes("international")===!0?Ct(he,o):e.recipientTotalAmount.amount+(o?.fee.amount??0),currencyCode:j.currencyCode,currencySymbol:j.currencySymbol},L={amount:o?.method.includes("international")===!0?Dt(he,o):o?.fee.amount??0,currencyCode:j.currencyCode,currencySymbol:j.currencySymbol},[rt,ge]=H.useState(!1),[st,xe]=H.useState(!1),fe=()=>ge(!1),dt=()=>{$.trackBillPayMagicLinkPreviewEmail("review_bill"),ge(!0)},ct=e.isCollectToAccountInfoFromVendorContact?t.jsxs(t.Fragment,{children:[`${a.magicLink.collectFrom} ${e.toAccountVendorEmail}`,t.jsx(An,{size:s,children:t.jsx(Pn,{})})]}):It(e.paymentDetailsSection?.paymentTo);H.useEffect(()=>{(F?.fetchState==="Completed"||J?.fetchState==="Completed")&&(me(),ue(),ye())},[F,J,ye,me,ue]);const T=e.billPayInfo?.stage,P=e.billPayInfo?.billStatus,U=e.billPayInfo?.billPaymentStatus,mt=e.billPayInfo?.billPaymentRefundStatus,te=T?.code==="paid"?T:P?.code=="approved"&&U?.code?U:P,pt=e.billPayInfo?.isRefundInitiated===!0?mt:P?.code=="approved"&&U?.code?U:P,ne=()=>{ce()},be=()=>{ce()},Z=e.paymentDetailsSection?.paymentDate,ie=le(o?.method??""),we=ie.replace("Same Day",""),ut=e.isCollectToAccountInfoFromVendorContact?t.jsx(Pt,{paymentTypeLabel:we,onClick:dt}):a.addedByZeni,q=w.allApprovalRules.length>0,yt=d.toAmount(o?.method!=null&&(o.method.includes(d.NEW_INTERNATIONAL_METHOD_SUBTEXT)||o?.fee.amount!=null&&o.fee.amount!==0)?u.amount-L.amount:u.amount,o?.fee.currencyCode??d.defaultVendorCurrency.currencyCode,o?.fee.currencySymbol??d.defaultVendorCurrency.currencySymbol),g=d.isPaymentMethodOutsideZeni(e.paymentDetailsSection?.paymentType?.method),ht=l=>{$.trackBillPayMarkAsPaidSubmit(l.paymentMode??"other",T?.code??"draft",te?.code??""),pe(!0,l)},$e=()=>{xe(!0),$.trackBillPayMarkAsPaid(T?.code??"draft",te?.code??"")},gt=()=>{lt(),xe(!1)},A=g&&(T?.code!=null?T.code==="draft"||P?.code==="approved":!0),b=A&&!it,Te=Oe(b,q,e.isBillMarkedForRetry),xt=()=>g?b?void 0:a.paymentOutsideZeni.reviewInfo:o?.method!=null&&o.method.includes(d.NEW_INTERNATIONAL_METHOD_SUBTEXT)&&e.paymentDetailsSection?.internationalTransferFeeBearerPaymentMethod!=null&&C&&ee===j.currencyCode?Et(e.paymentDetailsSection.internationalTransferFeeBearerPaymentMethod):void 0,ae=at&&e.paymentDetailsSection!=null?At(u,e.paymentDetailsSection.withdrawFrom,e.paymentDetailsSection.paymentDate):void 0,ft=()=>{const l=e.paymentDetailsSection?.paymentDate,r=e.isCollectToAccountInfoFromVendorContact,I=e.recurringConfig,wt=e.recipientTotalAmount;if(e.isInvoiceDateAutoUpdated===!0&&$.trackBillPayAutoDateChange(f??"new_bill"),o?.method!=null&&l!=null){const $t=g?a.paymentOutsideZeni.offline:le(o.method);if($.trackBillPaySendForApproval($t,l.format(Re.analytics.MMMDashDDDashYYYYFormat),r,e.isRecurring,f,e.paymentDetailsSection?.internationalTransferFeeBearerPaymentMethod,{startDate:d.zeniDate(I?.startDate?.toString()??"").format(D),endDate:d.zeniDate(I?.endDate?.toString()??"").format(D),frequency:I?.frequency??"monthly",totalAmount:wt.amount,totalPaymentCycles:I?.totalPaymentCycles??0,isApprovalRequired:I?.isApprovalRequired??!1,updateCurrentBill:e.recurringConfig?.id!=null?I?.updateRecurringBills==="current":void 0,updateFutureRecurringBills:e.recurringConfig?.id!=null?I?.updateRecurringBills==="all":void 0}),ae!=null){const Se=T?.code??"draft",Ce=P?.code??"",De=e.isRecurring?["Recurring"]:["One-Time"],Ie=e.invoiceNumber??"",Pe=Jt(m.loggedInUser),Ae=e.paymentDetailsSection?.withdrawFrom?.accType==="depositAccount"?"ZA":"External Account";Te===a.scheduleBill?$.trackLowBalanceAccountSchedule(Se,Ce,De,Ie,Pe,Ae):Te===a.sendForApproval&&$.trackLowBalanceAccountSentForApproval(Se,Ce,De,Ie,Pe,Ae)}}},je=()=>{ve===!0&&V(!1),e.isBillMarkedForRetry===!0?(ot(),$.trackRetryConfirmClick(te?.code??"",T?.code??"",pt?.description??"",e.isRecurring?["Recurring"]:["One-Time"],e.invoiceNumber??"")):e.vendor!=null&&(ft(),pe(!1,{}))},bt=d.checkIfCreatorIsApprover(u.amount,w.allApprovalRules,m.loggedInUser),[ve,V]=H.useState(!1);return t.jsxs(hn,{children:[st?t.jsx(en,{onCancel:gt,onProceedForMarkAsPaid:ht,saveDetailsFetchState:F?.fetchState,paymentData:e.outsideZeniPaymentInfo}):null,ve?t.jsx(tn,{withdrawFrom:e.paymentDetailsSection?.withdrawFrom,paymentDate:e.paymentDetailsSection?.paymentDate,onOkClick:je,onCancelClick:()=>{V(!1),ne()},onClickAway:()=>{V(!1)}}):null,t.jsx(kt,{anchor:"right",open:rt,onClose:fe,transitionDuration:250,"data-testid":v("vendor-email-preview-drawer"),children:t.jsx(Mt,{companyName:Bt(M.company?.companyInfo),vendor:e.vendor?.name,paymentDate:Z?.format(D)??"",paymentType:we,amount:k("0,0[.]00",u),isInvoiceAttached:!!e.file,onClose:fe})}),t.jsxs(gn,{windowSize:s,style:tt,children:[s==="small"?t.jsxs(In,{windowSize:s,children:[t.jsx(qe,{onClick:be,"data-testid":v("review-detail-nav-bar-small-back")}),t.jsx(We,{windowSize:s,children:a.oneLastLook})]}):t.jsx(Dn,{"data-testid":v("review-details-nav-bar-back"),children:t.jsx(qe,{onClick:be})}),s!=="small"?t.jsx(fn,{children:t.jsx(We,{windowSize:s,children:a.oneLastLook})}):null,e.duplicateBillTransactions.length>0?t.jsxs(bn,{children:[t.jsxs(wn,{children:[t.jsx(zn,{}),t.jsxs($n,{children:[t.jsx(jn,{children:a.duplicateBillPayWarning}),t.jsxs(Tn,{children:[a.duplicateBillPayWarningSubHeading,t.jsxs("span",{"data-testid":v("review-detail-attachment-button"),onClick:()=>Q(e.duplicateBillTransactions[0].id,e.duplicateBillTransactions[0].billPayInfo.stage.code),style:{textDecoration:"underline",cursor:"pointer"},children:[a.viewBill,e.duplicateBillTransactions[0].documentId]})]})]})]}),t.jsxs(Fn,{children:[t.jsx(On,{children:a.duplicateInvoiceFound}),e.duplicateBillTransactions.map(l=>{const r=Nt(l);return l!=null?t.jsx(Ln,{children:Je.includes(s)?t.jsxs(He,{windowSize:s,children:[t.jsxs(vn,{children:[t.jsxs(Sn,{children:[l.attachments&&l.attachments.length>0?t.jsx(Le,{attachment:l.attachments[0]}):t.jsx(Ve,{children:t.jsx(Ye,{})}),t.jsx(K,{children:t.jsxs(t.Fragment,{children:[l.documentId!=null?a.invoiceNo:null,l.documentId]})})]}),t.jsx(Ge,{windowSize:s,children:k("0,0[.]00",l.recipientTotalAmount)})]}),t.jsxs(Rn,{"data-testid":v("review-detail-mobile-info"),onClick:()=>Q(l.id,l.billPayInfo.stage.code),children:[t.jsxs(K,{children:[l.dueDate!=null?a.due:null," ",l.dueDate?.format(D)]}),t.jsx(Ke,{children:r!=null?ke.includes(r.code)?t.jsx(Me,{style:{padding:"2px 5px"},title:r.value,placement:"top",children:t.jsx(X,{color:r.color,bgColor:r.bgColor,borderColor:r.borderColor,children:r.value})}):t.jsx(X,{color:r.color,bgColor:r.bgColor,borderColor:r.borderColor,children:r.value}):null})]})]}):t.jsxs(He,{windowSize:s,children:[l.attachments&&l.attachments.length>0?t.jsx(Le,{attachment:l.attachments[0]}):t.jsx(Ve,{children:t.jsx(Ye,{})}),t.jsxs(En,{"data-testid":v("review-detail-info"),onClick:()=>Q(l.id,l.billPayInfo.stage.code),children:[t.jsx(K,{style:{width:"50%"},children:t.jsxs("div",{children:[l.documentId!=null?a.invoiceNo:null," ",l.documentId]})}),t.jsxs(K,{style:{width:"25%"},children:[l.dueDate!=null?a.due:null," ",l.dueDate?.format(D)]}),t.jsx(Ge,{style:{width:"25%"},windowSize:s,children:k("0,0[.]00",l.amount)})]}),t.jsx(Ke,{children:r!=null?ke.includes(r.code)?t.jsx(Me,{style:{padding:"2px 5px"},title:r.value,placement:"top",children:t.jsx(X,{color:r.color,bgColor:r.bgColor,borderColor:r.borderColor,children:r.value})}):t.jsx(X,{color:r.color,bgColor:r.bgColor,borderColor:r.borderColor,children:r.value}):null})]})},l.id):null})]})]}):null,t.jsxs(Cn,{children:[t.jsx(Ue,{children:a.pay}),t.jsx(Ze,{children:t.jsx(Be,{amount:yt,integerStyles:Y.largeMedium.cssObject,decimalStyles:Y.smallMedium.cssObject})}),t.jsx(Ue,{children:a.to}),t.jsx(Ze,{children:e.vendor?.name})]}),t.jsxs(xn,{children:[g?null:t.jsxs(t.Fragment,{children:[t.jsx(O,{isThreadAllowed:N,entityId:f,dashboardTabKey:_({type:"details",key:"withdrawFrom"}),roomId:R,companyId:m.currentTenant?.companyId??h,companyName:m.currentTenant?.companyName??h,dashboardOptionType:"bill",filterMetaData:{...B,entityType:`bill.details.${z("withdrawFrom")}`},children:t.jsx(W,{label:{label:a.withdrawFrom,width:E},style:{width:"auto"},value:e.paymentDetailsSection?.withdrawFrom!=null?Rt(e.paymentDetailsSection.withdrawFrom,s):h,infoLabelStyle:{textAlign:s==="small"?"left":"right",paddingRight:p.infoLabelPaddingRight.valuePx(s),marginTop:p.infoLabelMarginTop.valuePx(s),color:S.brandColorGoldDark},additionalInfoLabel:ae})}),t.jsx(G,{})]}),t.jsx(O,{isThreadAllowed:N,entityId:f,dashboardTabKey:_({type:"details",key:"paymentType"}),roomId:R,companyId:m.currentTenant?.companyId??h,companyName:m.currentTenant?.companyName??h,dashboardOptionType:"bill",filterMetaData:{...B,entityType:`bill.details.${z("paymentType")}`},children:t.jsx(W,{label:{label:a.paymentMethod,width:E},style:{width:"auto"},value:le(o?.method??""),additionalInfoLabel:xt()})}),t.jsx(G,{}),!g&&Z!=null?t.jsxs(t.Fragment,{children:[t.jsx(O,{isThreadAllowed:N,entityId:f,dashboardTabKey:_({type:"details",key:"paymentDate"}),roomId:R,companyId:m.currentTenant?.companyId??h,companyName:m.currentTenant?.companyName??h,dashboardOptionType:"bill",filterMetaData:{...B,entityType:`bill.details.${z("paymentDate")}`},children:t.jsx(W,{label:{label:a.paymentDate,width:E},style:{width:"auto"},value:Z.format(D),additionalInfoLabel:`${a.estimatedArrival}${d.zeniDate(d.getNextNthWorkingDay(Z.toDate(),[0,6],o?.maxPeriod.value??0).toDateString()).format(D)} - (${ie.length>0?`${ie} `:""}${a.deliveryTimeLabel} = ${o?.maxPeriod.value??"0"} ${a.deliveryTimeUnits})`})}),t.jsx(G,{})]}):null,g?null:t.jsx(O,{isThreadAllowed:N,entityId:f,dashboardTabKey:_({type:"details",key:"paymentTo"}),roomId:R,companyId:m.currentTenant?.companyId??h,companyName:m.currentTenant?.companyName??h,dashboardOptionType:"bill",filterMetaData:{...B,entityType:`bill.details.${z("paymentTo")}`},children:t.jsx(W,{label:{label:a.paymentTo,width:E},style:{width:"auto"},value:ct??"",additionalInfoLabel:ut})}),g||nt?t.jsxs(t.Fragment,{children:[t.jsx(G,{}),t.jsx(O,{isThreadAllowed:N,entityId:f,dashboardTabKey:_({type:"details",key:"recurringPaymentType"}),roomId:R,companyId:m.currentTenant?.companyId??h,companyName:m.currentTenant?.companyName??h,dashboardOptionType:"bill",filterMetaData:{...B,entityType:`bill.details.${z("recurringPaymentType")}`},children:t.jsx(W,{label:{label:a.paymentType,width:E},style:{width:"auto"},value:Lt(e.isRecurring,g,e.recurringBillInstance??1,e.recurringConfig?.totalPaymentCycles??0),additionalInfoLabel:Ft(s,e.isRecurring,g,e.recurringConfig)})})]}):null]}),!g&&o?.method!=null&&(o.method.includes(d.NEW_INTERNATIONAL_METHOD_SUBTEXT)||o?.fee.amount!=null&&o.fee.amount!==0)?t.jsx(mn,{children:t.jsxs(pn,{windowSize:s,children:[t.jsxs(un,{children:[t.jsx(sn,{children:a.total}),t.jsx(Ne,{style:{padding:`12px ${n.sp3}`,lineHeight:"18px"},maxWidth:"312px",title:t.jsxs(cn,{children:[t.jsxs(_e,{children:[t.jsx(re,{children:o.method.includes(d.NEW_INTERNATIONAL_METHOD_SUBTEXT)&&ee!==j.currencyCode?Fe.conversionAmountColon:Ee.invoiceAmount}),t.jsx(oe,{children:k("0,0[.]00",{amount:u.amount-L.amount,currencySymbol:L.currencySymbol})})]}),t.jsxs(_e,{children:[t.jsx(re,{children:Fe.transactionFee}),t.jsx(oe,{children:k("0,0[.]00",{amount:L.amount,currencySymbol:L.currencySymbol})})]}),t.jsx(dn,{}),t.jsxs(rn,{children:[t.jsx(re,{children:Ee.total}),t.jsx(oe,{children:k("0,0[.]00",{amount:u.amount,currencyCode:u.currencyCode,currencySymbol:u.currencySymbol})})]})]}),placement:"top-end",children:t.jsx(on,{})})]}),t.jsx(yn,{children:t.jsx(Be,{amount:d.toAmount(u.amount,u.currencyCode,u.currencySymbol),integerStyles:Y.h6Medium.cssObject,decimalStyles:Y.standardMedium.cssObject})})]})}):null]}),t.jsx(Ot,{cancelBtn:{label:A&&!b?a.paymentOutsideZeni.markAsPaid:a.editBill,onClick:A&&!b?$e:ne,style:{width:ze(!1,A,b,q,s)}},primaryBtn:{label:Oe(b,q,e.isBillMarkedForRetry),isLoading:F?.fetchState==="In-Progress"||J?.fetchState==="In-Progress",onClick:b?$e:()=>{bt&&ae!=null?V(!0):je()},style:{width:ze(!0,A,b,q,s)}},rightSideComponent:A&&!b&&F.fetchState!=="In-Progress"?t.jsx(_n,{windowSize:s,children:t.jsx(Ne,{style:{color:S.heroDark,padding:`2px ${n.sp2}`},display:"flex",title:an,placement:"top",children:t.jsx(Hn,{onClick:ne,"data-testid":v("review-detail-edit-bill-button"),children:t.jsx(Wn,{})})})}):null,style:{minHeight:e.paymentDetailsSection?.paymentType?.method!=null&&e.paymentDetailsSection.paymentType.method.includes(d.NEW_INTERNATIONAL_METHOD_SUBTEXT)?127:62,...e.paymentDetailsSection?.paymentType?.method!=null&&e.paymentDetailsSection.paymentType.method.includes(d.NEW_INTERNATIONAL_METHOD_SUBTEXT)&&{padding:n.sp3,rowGap:n.sp3}},children:e.paymentDetailsSection?.paymentType?.method!=null&&e.paymentDetailsSection.paymentType.method.includes(d.NEW_INTERNATIONAL_METHOD_SUBTEXT)?t.jsxs(kn,{children:[a.internationalText1,t.jsx(Mn,{href:"https://www.nium.com/legal/end-customer-terms",target:"_Blank",rel:"noopener noreferrer",children:a.internationalTerms}),a.internationalText2]}):null})]})},Oe=(e,w,x)=>e?a.paymentOutsideZeni.markAsPaid:x===!0?a.retryPayment:w?a.sendForApproval:a.scheduleBill,ze=(e,w,x,M,C)=>x?128:w&&!e&&C==="small"?"auto":M?165:p.footerButtonWidth.value(C),on=i(Xt)`
2
2
  width: ${n.sp3};
3
3
  height: ${n.sp3};
4
4
  color: ${e=>e.theme.colors.hero};
@@ -1,4 +1,4 @@
1
- import{q as M,j as e,aM as x,o as r,aQ as B,y as d,A as L,c as C,H as W,h as s,am as $,cP as R,P as D,ai as j,bl as I,u as n,eC as A,M as G,iV as H,k0 as q}from"./index-D94hlokH.js";import{n as t}from"./vendor-Bs1fkIUX.js";const a={containerMarginTop:new d(0,n[2]),containerMarginLeft:new d(n[3],n[8]),containerMarginRight:new d(n[3],n[8]),subTitleMarginBottom:new d(n[2],n[2]),titleMarginBotom:new d(n[0],n[2]),titleMarginRight:new d(n[0],n[3]),navBarHeight:new d(62,62,62),navBarPaddingLeft:new d(n[3],n[3],n[8]),navBarPaddingRight:new d(n[3],n[3],n[8])},F={title:new C("h6Regular","h5Regular")},xi=({title:i,description:p,reviewItems:S,showFooter:b,footerProps:{primaryButton:z,cancelButton:T,hideCancel:E},onCloseOverlay:P,onCloseReviewItem:k})=>{const l=M();return e.jsxs(J,{children:[e.jsx(Y,{windowSize:l,children:e.jsx(Z,{children:e.jsx(_,{windowSize:l,children:e.jsx(ii,{children:e.jsx(ei,{onClick:P,"data-testid":x("review-overlay-close",i)})})})})}),e.jsxs(Q,{windowSize:l,children:[e.jsxs(V,{windowSize:l,children:[e.jsx(K,{children:e.jsx(N,{windowSize:l,children:i})}),e.jsx(U,{isError:p.isError,windowSize:l,children:p.content})]}),e.jsx(X,{windowSize:l,children:S.map(o=>{const h=o.reviewStatus.code==="error",c=o.reviewStatus.code==="warning"||o.reviewStatus.code==="low-balance";return e.jsxs(ri,{isLoading:!1,isActive:!0,isWarning:c,isError:h,children:[c?e.jsx(ci,{onClick:()=>k(o.id),"data-testid":x("review-close",o.id)}):null,e.jsxs(ti,{children:[e.jsxs(ni,{children:[e.jsx(di,{children:O(o)}),e.jsxs(oi,{children:[e.jsxs(m,{children:[e.jsx(u,{style:{marginLeft:r.sp2},isWarning:c,isError:h,children:o.leftSideText.title}),e.jsx(u,{isWarning:c,isError:h,children:o.rightSideText.title})]}),e.jsxs(m,{children:[e.jsx(si,{style:{marginLeft:r.sp2},children:o.leftSideText.subTitle}),l!=="small"?e.jsxs(w,{windowSize:l,children:[e.jsx(g,{isError:h,isWarning:c,children:e.jsxs(e.Fragment,{children:[o.rightSideText.showThunderIcon===!0?e.jsx(f,{children:e.jsx(y,{})}):null,o.rightSideText.subTitle]})}),e.jsx(g,{isWarning:!0,isError:!1,children:o.rightSideText.additonalInfo})]}):null]})]})]}),l==="small"?e.jsxs(w,{windowSize:l,children:[e.jsx(g,{style:{marginLeft:r.sp5,marginTop:r.sp0},isError:h,isWarning:c,children:e.jsxs(e.Fragment,{children:[o.rightSideText.showThunderIcon===!0?e.jsx(f,{children:e.jsx(y,{})}):null,o.rightSideText.subTitle]})}),e.jsx(g,{style:{marginLeft:r.sp5,marginTop:r.sp0},isWarning:c,isError:h,children:o.rightSideText.additonalInfo})]}):null]})]},o.id)})})]}),b?e.jsx(B,{primaryBtn:z,cancelBtn:T,showCancel:!E}):null]})},O=i=>i.reviewStatus.isLoading?e.jsx(D,{size:"Small",style:{display:"flex",width:r.sp4,height:r.sp4,alignItems:"center",justifyContent:"center"},start:!0}):i.reviewStatus.code==="error"?e.jsx(v,{isError:!0}):i.reviewStatus.code==="warning"?e.jsx(v,{isError:!1}):i.reviewStatus.code==="valid"?e.jsx(li,{}):i.reviewStatus.code==="low-balance"?e.jsx(hi,{}):e.jsx(ai,{}),J=t.div`
1
+ import{q as M,j as e,aM as x,o as r,aQ as B,y as d,A as L,c as C,H as W,h as s,am as $,cP as R,P as D,ai as j,bl as I,u as n,eC as A,M as G,iV as H,k0 as q}from"./index-sAOH0Fje.js";import{n as t}from"./vendor-Bs1fkIUX.js";const a={containerMarginTop:new d(0,n[2]),containerMarginLeft:new d(n[3],n[8]),containerMarginRight:new d(n[3],n[8]),subTitleMarginBottom:new d(n[2],n[2]),titleMarginBotom:new d(n[0],n[2]),titleMarginRight:new d(n[0],n[3]),navBarHeight:new d(62,62,62),navBarPaddingLeft:new d(n[3],n[3],n[8]),navBarPaddingRight:new d(n[3],n[3],n[8])},F={title:new C("h6Regular","h5Regular")},xi=({title:i,description:p,reviewItems:S,showFooter:b,footerProps:{primaryButton:z,cancelButton:T,hideCancel:E},onCloseOverlay:P,onCloseReviewItem:k})=>{const l=M();return e.jsxs(J,{children:[e.jsx(Y,{windowSize:l,children:e.jsx(Z,{children:e.jsx(_,{windowSize:l,children:e.jsx(ii,{children:e.jsx(ei,{onClick:P,"data-testid":x("review-overlay-close",i)})})})})}),e.jsxs(Q,{windowSize:l,children:[e.jsxs(V,{windowSize:l,children:[e.jsx(K,{children:e.jsx(N,{windowSize:l,children:i})}),e.jsx(U,{isError:p.isError,windowSize:l,children:p.content})]}),e.jsx(X,{windowSize:l,children:S.map(o=>{const h=o.reviewStatus.code==="error",c=o.reviewStatus.code==="warning"||o.reviewStatus.code==="low-balance";return e.jsxs(ri,{isLoading:!1,isActive:!0,isWarning:c,isError:h,children:[c?e.jsx(ci,{onClick:()=>k(o.id),"data-testid":x("review-close",o.id)}):null,e.jsxs(ti,{children:[e.jsxs(ni,{children:[e.jsx(di,{children:O(o)}),e.jsxs(oi,{children:[e.jsxs(m,{children:[e.jsx(u,{style:{marginLeft:r.sp2},isWarning:c,isError:h,children:o.leftSideText.title}),e.jsx(u,{isWarning:c,isError:h,children:o.rightSideText.title})]}),e.jsxs(m,{children:[e.jsx(si,{style:{marginLeft:r.sp2},children:o.leftSideText.subTitle}),l!=="small"?e.jsxs(w,{windowSize:l,children:[e.jsx(g,{isError:h,isWarning:c,children:e.jsxs(e.Fragment,{children:[o.rightSideText.showThunderIcon===!0?e.jsx(f,{children:e.jsx(y,{})}):null,o.rightSideText.subTitle]})}),e.jsx(g,{isWarning:!0,isError:!1,children:o.rightSideText.additonalInfo})]}):null]})]})]}),l==="small"?e.jsxs(w,{windowSize:l,children:[e.jsx(g,{style:{marginLeft:r.sp5,marginTop:r.sp0},isError:h,isWarning:c,children:e.jsxs(e.Fragment,{children:[o.rightSideText.showThunderIcon===!0?e.jsx(f,{children:e.jsx(y,{})}):null,o.rightSideText.subTitle]})}),e.jsx(g,{style:{marginLeft:r.sp5,marginTop:r.sp0},isWarning:c,isError:h,children:o.rightSideText.additonalInfo})]}):null]})]},o.id)})})]}),b?e.jsx(B,{primaryBtn:z,cancelBtn:T,showCancel:!E}):null]})},O=i=>i.reviewStatus.isLoading?e.jsx(D,{size:"Small",style:{display:"flex",width:r.sp4,height:r.sp4,alignItems:"center",justifyContent:"center"},start:!0}):i.reviewStatus.code==="error"?e.jsx(v,{isError:!0}):i.reviewStatus.code==="warning"?e.jsx(v,{isError:!1}):i.reviewStatus.code==="valid"?e.jsx(li,{}):i.reviewStatus.code==="low-balance"?e.jsx(hi,{}):e.jsx(ai,{}),J=t.div`
2
2
  display: flex;
3
3
  flex-direction: column;
4
4
  background-color: ${i=>i.theme.colors.grey4};
@@ -1,4 +1,4 @@
1
- import{f4 as h,f5 as x,j as t,c5 as m,o as n,aM as i,O as g,ao as j,ai as p}from"./index-D94hlokH.js";import{n as s}from"./vendor-Bs1fkIUX.js";const{hyphen:a}=g.getLocalizedStrings().common.strings,f=s.div``,y=s.div`
1
+ import{f4 as h,f5 as x,j as t,c5 as m,o as n,aM as i,O as g,ao as j,ai as p}from"./index-sAOH0Fje.js";import{n as s}from"./vendor-Bs1fkIUX.js";const{hyphen:a}=g.getLocalizedStrings().common.strings,f=s.div``,y=s.div`
2
2
  display: flex;
3
3
  min-width: 192px;
4
4
  justify-content: space-between;
@@ -1,4 +1,4 @@
1
- import{aP as H,l as me,im as ee,gO as fe,eR as we,io as Je,aa as Me,ip as Ve,cS as _e,cT as Pe,j as a,O as xe,ad as Fe,cD as $e,cE as Ne,cF as qe,aQ as Re,iq as We,ir as Be,ab as he,is as Se,it as Ue,d3 as ze,q as Ge,iH as He,gT as re,u as R,h as De,y as Ce,cV as Ke,iu as Ye,iv as Xe,iw as Ze,o as _}from"./index-D94hlokH.js";import{b as m,n as B}from"./vendor-Bs1fkIUX.js";import{i as Qe,r as et,n as tt,o as lt}from"./ScheduleSequenceTable-DeLVkslS-C15n76pT.js";import"./mui-Ty75qFQF.js";import"./analytics-CcevxdRy.js";import"./routing-Dk1A2KYI.js";import"./sentry-BE5FTzpq.js";import"./redux-CEhZD0hA.js";import"./liveblocks-8ht9CoL5.js";import"./crypto-cQYYQPTZ.js";const W={labelWidth:new Ce(160,160,160),depCategoryLabelWidth:new Ce(200,280,280)},at=B.div`
1
+ import{aP as H,l as me,im as ee,gO as fe,eR as we,io as Je,aa as Me,ip as Ve,cS as _e,cT as Pe,j as a,O as xe,ad as Fe,cD as $e,cE as Ne,cF as qe,aQ as Re,iq as We,ir as Be,ab as he,is as Se,it as Ue,d3 as ze,q as Ge,iH as He,gT as re,u as R,h as De,y as Ce,cV as Ke,iu as Ye,iv as Xe,iw as Ze,o as _}from"./index-sAOH0Fje.js";import{b as m,n as B}from"./vendor-Bs1fkIUX.js";import{i as Qe,r as et,n as tt,o as lt}from"./ScheduleSequenceTable-lTN7r0p4-BFWt_8N-.js";import"./mui-Ty75qFQF.js";import"./analytics-CcevxdRy.js";import"./routing-Dk1A2KYI.js";import"./sentry-BE5FTzpq.js";import"./redux-CEhZD0hA.js";import"./liveblocks-8ht9CoL5.js";import"./crypto-cQYYQPTZ.js";const W={labelWidth:new Ce(160,160,160),depCategoryLabelWidth:new Ce(200,280,280)},at=B.div`
2
2
  display: flex;
3
3
  flex-direction: column;
4
4
  width: 100%;
@@ -1,4 +1,4 @@
1
- import{aP as $,l as ie,im as Q,gO as ke,eR as Ie,io as Je,aa as Le,ip as we,cS as Me,cT as Ve,j as a,O as De,ad as Pe,cD as Fe,cE as $e,cF as _e,aQ as Ne,iq as qe,ir as ze,ab as re,is as pe,it as Be,d3 as Re,q as Ue,gT as me,u as X,h as We,y as Ke,iu as Ge,iv as Ye,iw as He,o as L}from"./index-D94hlokH.js";import{b as D,n as P}from"./vendor-Bs1fkIUX.js";import{i as Qe,r as Xe,n as Ze,o as et}from"./ScheduleSequenceTable-DeLVkslS-C15n76pT.js";import"./mui-Ty75qFQF.js";import"./analytics-CcevxdRy.js";import"./routing-Dk1A2KYI.js";import"./sentry-BE5FTzpq.js";import"./redux-CEhZD0hA.js";import"./liveblocks-8ht9CoL5.js";import"./crypto-cQYYQPTZ.js";const z={labelWidth:new Ke(160,160,160)},tt=P.div`
1
+ import{aP as $,l as ie,im as Q,gO as ke,eR as Ie,io as Je,aa as Le,ip as we,cS as Me,cT as Ve,j as a,O as De,ad as Pe,cD as Fe,cE as $e,cF as _e,aQ as Ne,iq as qe,ir as ze,ab as re,is as pe,it as Be,d3 as Re,q as Ue,gT as me,u as X,h as We,y as Ke,iu as Ge,iv as Ye,iw as He,o as L}from"./index-sAOH0Fje.js";import{b as D,n as P}from"./vendor-Bs1fkIUX.js";import{i as Qe,r as Xe,n as Ze,o as et}from"./ScheduleSequenceTable-lTN7r0p4-BFWt_8N-.js";import"./mui-Ty75qFQF.js";import"./analytics-CcevxdRy.js";import"./routing-Dk1A2KYI.js";import"./sentry-BE5FTzpq.js";import"./redux-CEhZD0hA.js";import"./liveblocks-8ht9CoL5.js";import"./crypto-cQYYQPTZ.js";const z={labelWidth:new Ke(160,160,160)},tt=P.div`
2
2
  display: flex;
3
3
  flex-direction: column;
4
4
  width: 100%;
@@ -1,4 +1,4 @@
1
- import{q as F,d as X,j as t,ix as ie,O as N,iy as le,c as oe,iz as ge,e7 as fe,ft as we,C as A,iA as ye,iw as be,o as i,y as b,h as j,s as $e,ab as re,e3 as je,cD as Se,cF as ke,d3 as Z,db as ee,d9 as ve,iB as K,iC as Ce,b3 as De,iD as Me,cH as ze,iE as Ee,u as h,am as E,b8 as Oe,cE as Le,ap as pe,dc as Ae,b1 as ne,dn as Fe,aQ as Ie,l as Y,iF as I,gq as Te,aN as Je,iG as Ve,aU as G,dd as Be,bl as Pe}from"./index-D94hlokH.js";import{b as D,n as o,i as B}from"./vendor-Bs1fkIUX.js";const R=(e,l)=>`${e}.${l}`,{formElements:{dayOfMonthSelector:M},common:se}=N.getLocalizedStrings();function Ne({defaultValue:e,name:l,placeholder:s,alignLeft:r=!1,style:p,isDisabled:n,registerOptions:d,onSaveClick:c,onCancelClick:y}){const[f,u]=D.useState(!1),{control:m,formState:{errors:g},setValue:S}=Z(),v=()=>{k||(c(),u(!1))},w=()=>{y(),u(!1)},k=ee(g,l),x=F(),a=X();return t.jsx(pe,{onClickAway:()=>{u(!1)},children:t.jsx(Ue,{style:p,isDisabled:n!=null,windowSize:x,onClick:()=>{!f&&n==null&&u(!0)},children:t.jsx(Ae,{name:R(l,"dayOfMonth"),control:m,rules:{...d},render:()=>t.jsxs(He,{children:[t.jsx(Re,{placeholder:s,defaultValue:e,isDisabled:n}),f?t.jsxs(_e,{alignLeft:r===!0,children:[t.jsx(Ze,{}),t.jsxs(ae,{isSelected:e.type==="day",children:[t.jsxs(Xe,{isError:e.type==="day"&&k,children:[t.jsx(ne,{label:{label:M.pickDate},radioField:{id:"day",name:R(l,"type"),value:"day",radioSize:"small",checked:e.type==="day"},style:{...A.smallRegular.cssObject,padding:`${i.sp3} ${i.sp0}`,width:"fit-content",marginLeft:i.sp3,minWidth:"35%"},labelStyle:{color:e.type==="day"&&k?j.important:"inherit"}}),t.jsx(Fe,{name:R(l,"dayOfMonth"),type:"number",placeholder:M.placeholder,disableCopyPaste:!0,autoTrim:"trim",onKeyDown:$=>{$.key!=="Backspace"&&isNaN(parseInt($.key))&&$.preventDefault()},defaultValue:e.dayOfMonth!=null&&!isNaN(e.dayOfMonth)?e.dayOfMonth:0,registerOptions:{min:1,max:28},outerDivStyle:{width:"fit-content",marginLeft:i.sp1,marginRight:i.sp1},style:{border:`1px solid ${e.type==="day"&&k?j.important:a.colors.grey2}`,borderRadius:i.sp1,...A.smallRegular.cssObject,padding:i.sp2,maxWidth:"35px",boxSizing:"border-box"}}),t.jsx(Ke,{isSelected:e.type==="day",children:M.ofEveryMonth})]}),t.jsx(We,{defaultValue:e.dayOfMonth,onClick:$=>{S(`${l}.dayOfMonth`,$),S(`${l}.type`,"day")}})]}),t.jsx(et,{}),t.jsx(ae,{isSelected:e.type==="lastDayOfMonth",children:t.jsx(ne,{label:{label:M.lastDayOfMonth},radioField:{id:"lastDayOfMonth",name:R(l,"type"),value:"lastDayOfMonth",radioSize:"small",checked:e.type==="lastDayOfMonth"},style:{...A.smallRegular.cssObject,padding:`${i.sp3} ${i.sp0}`,width:"fit-content",marginLeft:i.sp3},labelStyle:{color:e.type==="lastDayOfMonth"&&k?j.important:"inherit"}})}),t.jsx(Ie,{primaryBtn:{label:se.footer.save,onClick:v,isDisabled:qe(e),type:"button",style:{minWidth:"83px"}},cancelBtn:{label:se.footer.cancel,onClick:w,style:{minWidth:"83px"}},style:{position:"unset",backgroundColor:"transparent"}})]}):null]})})})})}function Re({placeholder:e,defaultValue:l,isDisabled:s}){return t.jsxs(Ye,{isDisabled:s!=null,children:[l?.type==null?t.jsx(Ge,{children:e}):null,l?.type=="day"&&l.dayOfMonth!=null?t.jsxs(de,{children:[t.jsx(W,{children:M.daysOfMonth[`${l.dayOfMonth}`]}),t.jsx(W,{children:M.ofEveryMonth})]}):null,l?.type==="lastDayOfMonth"?t.jsxs(de,{children:[t.jsx(W,{children:M.daysOfMonth.lastDayOfMonth}),t.jsx(W,{children:M.ofEveryMonth})]}):null]})}function We({defaultValue:e,onClick:l}){return t.jsxs(Qe,{children:[t.jsx(q,{children:[...Array(7).keys()].map(s=>{const r=s+1;return t.jsx(H,{isSelected:r===e,onClick:()=>l(Y.toScheduleDaysOfMonth(r)),children:r},r)})}),t.jsx(q,{children:[...Array(7).keys()].map(s=>{const r=s+8;return t.jsx(H,{isSelected:r===e,onClick:()=>l(r),children:r},r)})}),t.jsx(q,{children:[...Array(7).keys()].map(s=>{const r=s+15;return t.jsx(H,{isSelected:r===e,onClick:()=>l(r),children:r},r)})}),t.jsx(q,{children:[...Array(7).keys()].map(s=>{const r=s+22;return t.jsx(H,{isSelected:r===e,onClick:()=>l(r),children:r},r)})})]})}const qe=e=>{switch(e.type){case"day":return e.dayOfMonth==null;case"lastDayOfMonth":return!1;default:return!0}},He=o.div`
1
+ import{q as F,d as X,j as t,ix as ie,O as N,iy as le,c as oe,iz as ge,e7 as fe,ft as we,C as A,iA as ye,iw as be,o as i,y as b,h as j,s as $e,ab as re,e3 as je,cD as Se,cF as ke,d3 as Z,db as ee,d9 as ve,iB as K,iC as Ce,b3 as De,iD as Me,cH as ze,iE as Ee,u as h,am as E,b8 as Oe,cE as Le,ap as pe,dc as Ae,b1 as ne,dn as Fe,aQ as Ie,l as Y,iF as I,gq as Te,aN as Je,iG as Ve,aU as G,dd as Be,bl as Pe}from"./index-sAOH0Fje.js";import{b as D,n as o,i as B}from"./vendor-Bs1fkIUX.js";const R=(e,l)=>`${e}.${l}`,{formElements:{dayOfMonthSelector:M},common:se}=N.getLocalizedStrings();function Ne({defaultValue:e,name:l,placeholder:s,alignLeft:r=!1,style:p,isDisabled:n,registerOptions:d,onSaveClick:c,onCancelClick:y}){const[f,u]=D.useState(!1),{control:m,formState:{errors:g},setValue:S}=Z(),v=()=>{k||(c(),u(!1))},w=()=>{y(),u(!1)},k=ee(g,l),x=F(),a=X();return t.jsx(pe,{onClickAway:()=>{u(!1)},children:t.jsx(Ue,{style:p,isDisabled:n!=null,windowSize:x,onClick:()=>{!f&&n==null&&u(!0)},children:t.jsx(Ae,{name:R(l,"dayOfMonth"),control:m,rules:{...d},render:()=>t.jsxs(He,{children:[t.jsx(Re,{placeholder:s,defaultValue:e,isDisabled:n}),f?t.jsxs(_e,{alignLeft:r===!0,children:[t.jsx(Ze,{}),t.jsxs(ae,{isSelected:e.type==="day",children:[t.jsxs(Xe,{isError:e.type==="day"&&k,children:[t.jsx(ne,{label:{label:M.pickDate},radioField:{id:"day",name:R(l,"type"),value:"day",radioSize:"small",checked:e.type==="day"},style:{...A.smallRegular.cssObject,padding:`${i.sp3} ${i.sp0}`,width:"fit-content",marginLeft:i.sp3,minWidth:"35%"},labelStyle:{color:e.type==="day"&&k?j.important:"inherit"}}),t.jsx(Fe,{name:R(l,"dayOfMonth"),type:"number",placeholder:M.placeholder,disableCopyPaste:!0,autoTrim:"trim",onKeyDown:$=>{$.key!=="Backspace"&&isNaN(parseInt($.key))&&$.preventDefault()},defaultValue:e.dayOfMonth!=null&&!isNaN(e.dayOfMonth)?e.dayOfMonth:0,registerOptions:{min:1,max:28},outerDivStyle:{width:"fit-content",marginLeft:i.sp1,marginRight:i.sp1},style:{border:`1px solid ${e.type==="day"&&k?j.important:a.colors.grey2}`,borderRadius:i.sp1,...A.smallRegular.cssObject,padding:i.sp2,maxWidth:"35px",boxSizing:"border-box"}}),t.jsx(Ke,{isSelected:e.type==="day",children:M.ofEveryMonth})]}),t.jsx(We,{defaultValue:e.dayOfMonth,onClick:$=>{S(`${l}.dayOfMonth`,$),S(`${l}.type`,"day")}})]}),t.jsx(et,{}),t.jsx(ae,{isSelected:e.type==="lastDayOfMonth",children:t.jsx(ne,{label:{label:M.lastDayOfMonth},radioField:{id:"lastDayOfMonth",name:R(l,"type"),value:"lastDayOfMonth",radioSize:"small",checked:e.type==="lastDayOfMonth"},style:{...A.smallRegular.cssObject,padding:`${i.sp3} ${i.sp0}`,width:"fit-content",marginLeft:i.sp3},labelStyle:{color:e.type==="lastDayOfMonth"&&k?j.important:"inherit"}})}),t.jsx(Ie,{primaryBtn:{label:se.footer.save,onClick:v,isDisabled:qe(e),type:"button",style:{minWidth:"83px"}},cancelBtn:{label:se.footer.cancel,onClick:w,style:{minWidth:"83px"}},style:{position:"unset",backgroundColor:"transparent"}})]}):null]})})})})}function Re({placeholder:e,defaultValue:l,isDisabled:s}){return t.jsxs(Ye,{isDisabled:s!=null,children:[l?.type==null?t.jsx(Ge,{children:e}):null,l?.type=="day"&&l.dayOfMonth!=null?t.jsxs(de,{children:[t.jsx(W,{children:M.daysOfMonth[`${l.dayOfMonth}`]}),t.jsx(W,{children:M.ofEveryMonth})]}):null,l?.type==="lastDayOfMonth"?t.jsxs(de,{children:[t.jsx(W,{children:M.daysOfMonth.lastDayOfMonth}),t.jsx(W,{children:M.ofEveryMonth})]}):null]})}function We({defaultValue:e,onClick:l}){return t.jsxs(Qe,{children:[t.jsx(q,{children:[...Array(7).keys()].map(s=>{const r=s+1;return t.jsx(H,{isSelected:r===e,onClick:()=>l(Y.toScheduleDaysOfMonth(r)),children:r},r)})}),t.jsx(q,{children:[...Array(7).keys()].map(s=>{const r=s+8;return t.jsx(H,{isSelected:r===e,onClick:()=>l(r),children:r},r)})}),t.jsx(q,{children:[...Array(7).keys()].map(s=>{const r=s+15;return t.jsx(H,{isSelected:r===e,onClick:()=>l(r),children:r},r)})}),t.jsx(q,{children:[...Array(7).keys()].map(s=>{const r=s+22;return t.jsx(H,{isSelected:r===e,onClick:()=>l(r),children:r},r)})})]})}const qe=e=>{switch(e.type){case"day":return e.dayOfMonth==null;case"lastDayOfMonth":return!1;default:return!0}},He=o.div`
2
2
  position: relative;
3
3
  `,Ye=o.div`
4
4
  display: flex;
@@ -1,4 +1,4 @@
1
- import{d as Ut,q as en,l as Y,e as Ke,z as tt,y as dt,f as cd,g as fd,i as tn,F as ld,N as Tt,O as ir,k as Bt,m as qt,P as rn,o as kt,Y as hd,K as dd,Q as Ft,p as Kl,r as Lt,G as pd,t as md,u as yn,$ as gd,D as Yl,v as vd,w as Jl,x as Xl,B as zo,Z as yd,E as _d,J as bd,L as Ql,U as wd,V as Sd,R as Ed,S as Rd,T as Od,W as Td,X as xd,a0 as Cd,a1 as Id,a2 as Ad,a3 as Pd,a4 as kd,a5 as Ld,a6 as qd}from"./index-D94hlokH.js";import{j as X,D as nn,S as Vt}from"./mui-Ty75qFQF.js";import{b as Se,n as ut,c as Ve,f as eh,g as jd}from"./vendor-Bs1fkIUX.js";import{f as Dd}from"./analyticsHelper-mfWw4TCX.js";import{g as rt,u as Ae,f as Ye}from"./redux-CEhZD0hA.js";import{a as Je,d as pt,e as Nd,N as er,R as wt,c as qe,u as Zo,b as Go}from"./routing-Dk1A2KYI.js";import{B as ze}from"./analytics-CcevxdRy.js";import{p as Oe}from"./sentry-BE5FTzpq.js";import{a as Qe,b as $d,c as Wo,d as Md,e as Ko,f as Yo,g as Fd,h as Ud,i as zt,j as th,k as rr,l as an,m as Bd,n as Vd,o as zd,p as Gd,q as Hd,s as Zd,t as Wd,u as rh,v as on,w as ar}from"./crypto-cQYYQPTZ.js";import{r as Kd}from"./lodash-B66NTFTY.js";import"./liveblocks-8ht9CoL5.js";const Yd={overlayWidth:new dt(100,100,50)},{common:{strings:vs}}=ir.getLocalizedStrings();function Jd(e,n){return{headerActions:{onTabChange:a=>{const i=qt(a),o=Bt(a);Ke.trackCockpitTabClicked(o),n.navigate(`../../${i}`,{replace:!0})},filterActions:{onFilterTextChanged:(a,i)=>{e(Y.updateCompanyHealthViewUIState({uiState:{filterText:i}}))},onFiltersChange:(a,i)=>{i.categories!=null&&i.categoryCombinationOperator!=null&&Ke.trackHealthMonitorFiltersApplied({filterSelection:{condition:i.categories.map(o=>o.matchingOperator).join(vs.comma),logic:i.categoryCombinationOperator,parameter:i.categories.map(o=>o.field).join(vs.comma)}}),e(Y.updateCompanyHealthViewUIState({uiState:{filters:i}}))}}},healthPageActions:{onRowClick:a=>{e(Y.initializeCompanyHealthMetricViewLocalData(a))},onColumnSortConfigChanged:(a,i)=>{e(Y.updateCompanyHealthViewUIState({uiState:{sortKey:a,sortOrder:i}}))},onCockpitReloadData:a=>{a==="healthMonitor"&&e(Y.fetchCompanyHealthMetricView())},onFiltersChange:a=>{e(Y.updateCompanyHealthViewUIState({uiState:{filters:a}}))}}}}function Xd(e,n){return{headerData:{selectedTabOption:Tt("healthMonitor")},healthPageData:{healthView:n.healthView,managementView:n.managementView,mixpanelUrl:n.mixpanelHMUrl}}}const Qd=Ye(Xd,Jd)(ld);function _n({isDrawerOpen:e}){const n=Je(),a=rt(),i=Ut(),o=en(),{companyId:t}=pt(),[r,s]=Nd(),[p,l]=Se.useState(!1),u=Ae(b=>Y.getCompanyHealthMetricView(b)),f=Ae(b=>Y.getCompanyManagementView(b)),{additionalChurnFactors:d}=Ae(b=>Y.getCompanyHealthMetricConfig(b)),{selectedCompanyDetail:w,selectedCompanyId:h,localFormDataAndStatusByCompanyId:v}=u,m=Ae(b=>b.companyViewState.zeniUsers.fetchState),c=Ae(b=>b.companyHealthMetricConfigViewState);if(Se.useEffect(()=>{const b=y=>y==="Not-Started"||y==="Error";u.fetchState==="Completed"?a(Y.fetchAllCockpitViews(!1)):b(u.fetchState)&&(a(Y.fetchCompanyHealthMetricView()),b(m)&&a(Y.fetchZeniUsers()),b(c.fetchState)&&a(Y.fetchCompanyHealthMetricConfig()))},[u.fetchState,c.fetchState]),Se.useEffect(()=>{t!=null&&u.fetchState==="Completed"&&r.has("utm_source")===!0&&(a(Y.initializeCompanyHealthMetricViewLocalData(t)),w!=null&&(Ke.trackCockpitHealthMonitorNotificationAlertClicked(r.get("utm_source"),{companyId:w.companyInfo.companyId,companyName:w.companyInfo.name,churnProbability:w.companyHealthMetric.churnProbabilityPercentage??null}),l(r.has("utm_source")),r.delete("utm_source"),s(r)))},[u.fetchState,w?.companyInfo.companyId,w?.companyInfo.name]),tt.getSignedInUser()==null)throw Error("Can't access Health Monitor page without signing in...");return X.jsxs(X.Fragment,{children:[e===!0||h!=null&&w!=null?X.jsx(nn,{anchor:"right",open:h!=null,PaperProps:{style:{width:Yd.overlayWidth.valuePercentage(o),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:i.colors.black,opacity:.75,cursor:"pointer"}}},onClose:()=>a(Y.removeSelectedCompanyId()),children:X.jsx(cd,{roomId:`cockpit_${h}`,autoConnect:!0,children:X.jsx(fd,{onSaveClick:()=>{h!=null&&a(Y.saveCompanyHealthMetricById(h))},onSaveChangesToLocalStore:b=>{u.selectedCompanyId!=null&&a(Y.updateCompanyHealthMetricLocalStore({companyId:u.selectedCompanyId,updatedLocalData:b}))},localData:v?.companyHealthMetricLocalData??{netPromoterScore:void 0,externalProductServiceExposure:void 0,additionalChurnFactors:{increasingChurnProbability:[],decreasingChurnProbability:[]}},companyHealthMetricViewSelector:u,onCloseDrawer:()=>a(Y.removeSelectedCompanyId()),analytics:Ke,urlSource:p,additionalChurnFactorsOptions:d})})}):null,X.jsx(Qd,{healthView:u,managementView:f,navigate:n,mixpanelHMUrl:tn.mixpanelHMUrl})]})}const nh=(e,n)=>{const a=[...e??[]];return a.push(n),a},ep=e=>{const n=[...e??[]];return{poppedPathname:n.pop(),newStack:n}},tp=(e=2)=>{let n="../";for(let a=0;a<e;a++)n=`${n}../`;return n},Fe=({state:e,element:n})=>tt.isSignedIn()===!0?X.jsx(X.Fragment,{children:n}):X.jsx(er,{to:"/signin/auth",replace:!0,state:{...e,message:"...",origin:window.location.pathname}});function rp(){return X.jsxs(wt,{children:[X.jsx(qe,{path:"/companies/:companyId",element:X.jsx(Fe,{element:X.jsx(_n,{isDrawerOpen:!0})})}),X.jsx(qe,{path:"/",element:X.jsx(Fe,{element:X.jsx(_n,{})})}),X.jsx(qe,{path:"/*",element:X.jsx(Fe,{element:X.jsx(_n,{})})})]})}const np={drawerLeftMargin:new dt(0,0,240)};function or(e){const{isOpen:n,drawerLeftMargin:a,children:i,onClose:o}=e,t=en(),r=a?.valuePx(t)??np.drawerLeftMargin.valuePx(t),s=Ut();return X.jsx(nn,{anchor:"right",open:n,PaperProps:{style:{width:`calc(100% - ${r})`}},slotProps:{backdrop:{style:{backgroundColor:s.colors.black,opacity:.8,cursor:"pointer"}}},onClose:o,children:i})}const ip=({fetchState:e})=>e==="In-Progress"||e==="Not-Started"?X.jsx(ap,{children:X.jsx(rn,{size:"ExtraLarge",start:!0})}):null,ap=ut.div`
1
+ import{d as Ut,q as en,l as Y,e as Ke,z as tt,y as dt,f as cd,g as fd,i as tn,F as ld,N as Tt,O as ir,k as Bt,m as qt,P as rn,o as kt,Y as hd,K as dd,Q as Ft,p as Kl,r as Lt,G as pd,t as md,u as yn,$ as gd,D as Yl,v as vd,w as Jl,x as Xl,B as zo,Z as yd,E as _d,J as bd,L as Ql,U as wd,V as Sd,R as Ed,S as Rd,T as Od,W as Td,X as xd,a0 as Cd,a1 as Id,a2 as Ad,a3 as Pd,a4 as kd,a5 as Ld,a6 as qd}from"./index-sAOH0Fje.js";import{j as X,D as nn,S as Vt}from"./mui-Ty75qFQF.js";import{b as Se,n as ut,c as Ve,f as eh,g as jd}from"./vendor-Bs1fkIUX.js";import{f as Dd}from"./analyticsHelper-CVWZE356.js";import{g as rt,u as Ae,f as Ye}from"./redux-CEhZD0hA.js";import{a as Je,d as pt,e as Nd,N as er,R as wt,c as qe,u as Zo,b as Go}from"./routing-Dk1A2KYI.js";import{B as ze}from"./analytics-CcevxdRy.js";import{p as Oe}from"./sentry-BE5FTzpq.js";import{a as Qe,b as $d,c as Wo,d as Md,e as Ko,f as Yo,g as Fd,h as Ud,i as zt,j as th,k as rr,l as an,m as Bd,n as Vd,o as zd,p as Gd,q as Hd,s as Zd,t as Wd,u as rh,v as on,w as ar}from"./crypto-cQYYQPTZ.js";import{r as Kd}from"./lodash-B66NTFTY.js";import"./liveblocks-8ht9CoL5.js";const Yd={overlayWidth:new dt(100,100,50)},{common:{strings:vs}}=ir.getLocalizedStrings();function Jd(e,n){return{headerActions:{onTabChange:a=>{const i=qt(a),o=Bt(a);Ke.trackCockpitTabClicked(o),n.navigate(`../../${i}`,{replace:!0})},filterActions:{onFilterTextChanged:(a,i)=>{e(Y.updateCompanyHealthViewUIState({uiState:{filterText:i}}))},onFiltersChange:(a,i)=>{i.categories!=null&&i.categoryCombinationOperator!=null&&Ke.trackHealthMonitorFiltersApplied({filterSelection:{condition:i.categories.map(o=>o.matchingOperator).join(vs.comma),logic:i.categoryCombinationOperator,parameter:i.categories.map(o=>o.field).join(vs.comma)}}),e(Y.updateCompanyHealthViewUIState({uiState:{filters:i}}))}}},healthPageActions:{onRowClick:a=>{e(Y.initializeCompanyHealthMetricViewLocalData(a))},onColumnSortConfigChanged:(a,i)=>{e(Y.updateCompanyHealthViewUIState({uiState:{sortKey:a,sortOrder:i}}))},onCockpitReloadData:a=>{a==="healthMonitor"&&e(Y.fetchCompanyHealthMetricView())},onFiltersChange:a=>{e(Y.updateCompanyHealthViewUIState({uiState:{filters:a}}))}}}}function Xd(e,n){return{headerData:{selectedTabOption:Tt("healthMonitor")},healthPageData:{healthView:n.healthView,managementView:n.managementView,mixpanelUrl:n.mixpanelHMUrl}}}const Qd=Ye(Xd,Jd)(ld);function _n({isDrawerOpen:e}){const n=Je(),a=rt(),i=Ut(),o=en(),{companyId:t}=pt(),[r,s]=Nd(),[p,l]=Se.useState(!1),u=Ae(b=>Y.getCompanyHealthMetricView(b)),f=Ae(b=>Y.getCompanyManagementView(b)),{additionalChurnFactors:d}=Ae(b=>Y.getCompanyHealthMetricConfig(b)),{selectedCompanyDetail:w,selectedCompanyId:h,localFormDataAndStatusByCompanyId:v}=u,m=Ae(b=>b.companyViewState.zeniUsers.fetchState),c=Ae(b=>b.companyHealthMetricConfigViewState);if(Se.useEffect(()=>{const b=y=>y==="Not-Started"||y==="Error";u.fetchState==="Completed"?a(Y.fetchAllCockpitViews(!1)):b(u.fetchState)&&(a(Y.fetchCompanyHealthMetricView()),b(m)&&a(Y.fetchZeniUsers()),b(c.fetchState)&&a(Y.fetchCompanyHealthMetricConfig()))},[u.fetchState,c.fetchState]),Se.useEffect(()=>{t!=null&&u.fetchState==="Completed"&&r.has("utm_source")===!0&&(a(Y.initializeCompanyHealthMetricViewLocalData(t)),w!=null&&(Ke.trackCockpitHealthMonitorNotificationAlertClicked(r.get("utm_source"),{companyId:w.companyInfo.companyId,companyName:w.companyInfo.name,churnProbability:w.companyHealthMetric.churnProbabilityPercentage??null}),l(r.has("utm_source")),r.delete("utm_source"),s(r)))},[u.fetchState,w?.companyInfo.companyId,w?.companyInfo.name]),tt.getSignedInUser()==null)throw Error("Can't access Health Monitor page without signing in...");return X.jsxs(X.Fragment,{children:[e===!0||h!=null&&w!=null?X.jsx(nn,{anchor:"right",open:h!=null,PaperProps:{style:{width:Yd.overlayWidth.valuePercentage(o),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:i.colors.black,opacity:.75,cursor:"pointer"}}},onClose:()=>a(Y.removeSelectedCompanyId()),children:X.jsx(cd,{roomId:`cockpit_${h}`,autoConnect:!0,children:X.jsx(fd,{onSaveClick:()=>{h!=null&&a(Y.saveCompanyHealthMetricById(h))},onSaveChangesToLocalStore:b=>{u.selectedCompanyId!=null&&a(Y.updateCompanyHealthMetricLocalStore({companyId:u.selectedCompanyId,updatedLocalData:b}))},localData:v?.companyHealthMetricLocalData??{netPromoterScore:void 0,externalProductServiceExposure:void 0,additionalChurnFactors:{increasingChurnProbability:[],decreasingChurnProbability:[]}},companyHealthMetricViewSelector:u,onCloseDrawer:()=>a(Y.removeSelectedCompanyId()),analytics:Ke,urlSource:p,additionalChurnFactorsOptions:d})})}):null,X.jsx(Qd,{healthView:u,managementView:f,navigate:n,mixpanelHMUrl:tn.mixpanelHMUrl})]})}const nh=(e,n)=>{const a=[...e??[]];return a.push(n),a},ep=e=>{const n=[...e??[]];return{poppedPathname:n.pop(),newStack:n}},tp=(e=2)=>{let n="../";for(let a=0;a<e;a++)n=`${n}../`;return n},Fe=({state:e,element:n})=>tt.isSignedIn()===!0?X.jsx(X.Fragment,{children:n}):X.jsx(er,{to:"/signin/auth",replace:!0,state:{...e,message:"...",origin:window.location.pathname}});function rp(){return X.jsxs(wt,{children:[X.jsx(qe,{path:"/companies/:companyId",element:X.jsx(Fe,{element:X.jsx(_n,{isDrawerOpen:!0})})}),X.jsx(qe,{path:"/",element:X.jsx(Fe,{element:X.jsx(_n,{})})}),X.jsx(qe,{path:"/*",element:X.jsx(Fe,{element:X.jsx(_n,{})})})]})}const np={drawerLeftMargin:new dt(0,0,240)};function or(e){const{isOpen:n,drawerLeftMargin:a,children:i,onClose:o}=e,t=en(),r=a?.valuePx(t)??np.drawerLeftMargin.valuePx(t),s=Ut();return X.jsx(nn,{anchor:"right",open:n,PaperProps:{style:{width:`calc(100% - ${r})`}},slotProps:{backdrop:{style:{backgroundColor:s.colors.black,opacity:.8,cursor:"pointer"}}},onClose:o,children:i})}const ip=({fetchState:e})=>e==="In-Progress"||e==="Not-Started"?X.jsx(ap,{children:X.jsx(rn,{size:"ExtraLarge",start:!0})}):null,ap=ut.div`
2
2
  display: flex;
3
3
  width: 100%;
4
4
  height: 100%;