@zeniai/web-cockpit-ui 1.13.83-qa → 1.13.84-dev
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/{ACHDetailsPage-_VHVuqJw-Bymc8CZ3.js → ACHDetailsPage-Bya_wRcI-Cbp0qhsx.js} +3 -3
- package/dist/assets/{AIPerformancePage-C89zANQm-DAbfunq3.js → AIPerformancePage-Bc2kKHSK-BgXzMS_3.js} +24 -24
- package/dist/assets/AccountInfoPage-d3ST-rTL-C_leII_k.js +18 -0
- package/dist/assets/{AccountInfoPageContent-B8SOX9i5-7d4Bt0bR.js → AccountInfoPageContent-BhU-TVmh-BdzRn56o.js} +20 -20
- package/dist/assets/{AccountReconDetailsDrawerPage-BVnXwxD4-DEurx_N4.js → AccountReconDetailsDrawerPage-Dp2R5isq-DTMzR1zA.js} +18 -18
- package/dist/assets/AccountRow-t4I1y-2K-CgC6OUhN.js +298 -0
- package/dist/assets/{AccountsPromoCardStack-9UqzeTvF-CzL1CjSW.js → AccountsPromoCardStack-DYUyO-ip-D1yzvIYh.js} +22 -22
- package/dist/assets/{AddAddressForCardDrawer-flYKIptj-CZXNkdja.js → AddAddressForCardDrawer-CNSnxc8q-xbp24EPr.js} +1 -1
- package/dist/assets/{AddToWalletPage-qMFXqjhm-BLIVGZdo.js → AddToWalletPage-Q8uWTckm-XMYIU9V3.js} +30 -30
- package/dist/assets/{AgingReportsPage-CdVOTjjc-BjXskb5q.js → AgingReportsPage-B-DOb7my-C3NgaG-U.js} +4 -4
- package/dist/assets/{AllUserItems-6g-IFiDP-BF7NBOrr.js → AllUserItems-B86Y2Fmg-DavCuBOs.js} +7 -7
- package/dist/assets/{ApAgingDetailPage-DNG6y6eT-DhHZsXHm.js → ApAgingDetailPage-CMYJgTzS-sOBU6gP5.js} +3 -3
- package/dist/assets/{AppBasePage-C0Sy0oae-DvEJ-ATe.js → AppBasePage-DJO-V2ox-D56HdnuV.js} +4 -4
- package/dist/assets/{AppDrawerContent-BAYPGtYY-CUnHM7PZ.js → AppDrawerContent-5_QaBLwS-CM4yA7GZ.js} +2 -2
- package/dist/assets/{ApprovalRulesSettingsPage-D52kq1hZ-BYg8vnKt.js → ApprovalRulesSettingsPage-CPbVQ97S-DsB9ftyn.js} +6 -6
- package/dist/assets/{ArAgingChart-Bso6mAzK-j6sfc3fv.js → ArAgingChart-l020Rk_S-DwzSqVCY.js} +5 -5
- package/dist/assets/{ArAgingDetailPage-BxtXGjOk-CBtuYc3L.js → ArAgingDetailPage-BeUPeHBJ-DWBF7rvM.js} +2 -2
- package/dist/assets/{AttachmentView-cjbbz-rh-BnkWjld0.js → AttachmentView-Afp_U4fV-ChOQ6Ub6.js} +8 -8
- package/dist/assets/{BankAccountSection-Cf1NyJua-CA0IxE0G.js → BankAccountSection-CNQgxgSJ-Ca43edcO.js} +4 -4
- package/dist/assets/{BankAccountWarningSection-hZNBR8bC-DgrV5hrK.js → BankAccountWarningSection-V0HHzW57-BXTr_4tn.js} +5 -5
- package/dist/assets/{BankConnectionsSettingsPage-C42Z61VJ-BjXrRucN.js → BankConnectionsSettingsPage-Bk8K0xUn-B_F9KKkf.js} +22 -22
- package/dist/assets/{BillDetailPage-C9ABXSip-Dyhvss4T.js → BillDetailPage-D9d6X0o4-D-GS6Om8.js} +5 -5
- package/dist/assets/{BillPayApprovalRuleDetailPage-C_P8uDLH-c09oNfGD.js → BillPayApprovalRuleDetailPage-CSVTc5Mn-BViwJkEX.js} +2 -2
- package/dist/assets/{BillPayApprovalRulesPage-B-e1bydX-37-nfPS6.js → BillPayApprovalRulesPage-DIOOCVKH-D1Pdhh1K.js} +3 -3
- package/dist/assets/{BillPayPromoPage-CdGuDH1_-DoTWyE5k.js → BillPayPromoPage-C44YKAlE-CyfJbYHe.js} +2 -2
- package/dist/assets/{BillPaySetUpPage-BJzAf5ei-BfqA1r1q.js → BillPaySetUpPage-erTIfKkS-e9d2uLlE.js} +2 -2
- package/dist/assets/BillingSettingsPage-CmvoTc8r-CgKVc-Hp.js +44 -0
- package/dist/assets/BillsBulkReviewDrawerPage-OSbHVAMk-B7pVq5dd.js +1 -0
- package/dist/assets/{BoxItem-BMejIo17-DfTWFZ7_.js → BoxItem-UFBGpfBB-Cl1_IwAU.js} +1 -1
- package/dist/assets/{BusinessVerificationPage-B4T4eKqS-Bye3WrQZ.js → BusinessVerificationPage-Cl7jz1DF-B1c4YlYQ.js} +8 -8
- package/dist/assets/{CardNumberSubText-DU4-NQyz-186D7nSj.js → CardNumberSubText-DyFZudV_-D11cIePr.js} +1 -1
- package/dist/assets/{CashbackDetailPage-gEd-o4kR-C4wVKPgt.js → CashbackDetailPage-D0_YW2Dy-BvqJCdMM.js} +21 -21
- package/dist/assets/{ChargeCardDetailPage-Bi0lqA56-BFxB7GLk.js → ChargeCardDetailPage-YkvyvIEk-BL54Gn2n.js} +58 -58
- package/dist/assets/{ChargeCardListPage-D0DuXZ7e-DlfCFnes.js → ChargeCardListPage-4vg8Q6bl-B7zHIOPp.js} +35 -35
- package/dist/assets/{ChargeCardListTable-C1RWnfY_-CHbl4tuS.js → ChargeCardListTable-Dl-rblE6-cI3INYu9.js} +25 -25
- package/dist/assets/ChargeCardPromoPage-BzcIsHeK-CL-PWL5a.js +175 -0
- package/dist/assets/{ChargeCardSetupPage-DNUctoFI-CLAGahbp.js → ChargeCardSetupPage-BSiJnRP_-C-GYT256.js} +2 -2
- package/dist/assets/{ChargeCardStatementsPage-B565dWKi-BNK7rWNj.js → ChargeCardStatementsPage-NkfA1SYG-Dm6-iBGo.js} +4 -4
- package/dist/assets/{ChargeCardUtils-BN7bbdUB-BbkRwxs1.js → ChargeCardUtils-CLpd-HDH-B3csze9l.js} +1 -1
- package/dist/assets/{ChaseOverlay-BrHcqwQQ-D5p6lw7W.js → ChaseOverlay-B1cuawle-p6HzSxTf.js} +8 -8
- package/dist/assets/CheckDepositDrawerPage-BwJ5tAF--CpJrHbza.js +206 -0
- package/dist/assets/{CollapsableReportTable-C5VV-Hqz-BgVDm2Ba.js → CollapsableReportTable-iMD5xyGN-Bi-fik_C.js} +29 -29
- package/dist/assets/{CompanyOfficerDetailsSection-DHqtLqa--DkQW91X6.js → CompanyOfficerDetailsSection-BA7etm2I-CmO-KOuc.js} +26 -26
- package/dist/assets/{CompanyPassportCard-BtC806n1-BE2Vutw3.js → CompanyPassportCard-Dks4EQDN-Dn-jW4u-.js} +2 -2
- package/dist/assets/{CompanyPassportPage-CZBZoHu3-CVdv1vFg.js → CompanyPassportPage-Denliwgg-BKRikNew.js} +140 -140
- package/dist/assets/{CompleteProfile-CwZtbTzm-B0JwwIUN.js → CompleteProfile-CCLq4pNY-y7V5PpLY.js} +10 -10
- package/dist/assets/ConfettiBurst-MKPxinI7-gHaE20YT.js +1 -0
- package/dist/assets/{CreateOrEditVendorPage-B43jo6gf-XWR76dqm.js → CreateOrEditVendorPage-BFejWQMx-BjDnDTWQ.js} +15 -15
- package/dist/assets/{CreditCardPaymentDrawerPage-1litLdxa-C6R9hrSu.js → CreditCardPaymentDrawerPage-B7Sesq_n-V9iiiMuJ.js} +16 -16
- package/dist/assets/{CreditCardPaymentPlgSection-CEjV1ee_-C66jG_cF.js → CreditCardPaymentPlgSection-D5CNl0oa-C-cdC2QZ.js} +10 -10
- package/dist/assets/{CurrencySelectField-DMPtPzwJ-CVyHXZxa.js → CurrencySelectField-DYvc6rwt-ByvmhvI-.js} +5 -5
- package/dist/assets/{CustomerOnboardingActivationPage-DUQPZIJW-C2-ZWnw3.js → CustomerOnboardingActivationPage-oUiw--hv-BRyHoZHP.js} +3 -3
- package/dist/assets/CustomerOnboardingContainerPage-D2xC_a0G-DLJn2o1E.js +1 -0
- package/dist/assets/{CustomerOnboardingDetailPageSkeleton-D-MkZIDQ-DF5QLwbE.js → CustomerOnboardingDetailPageSkeleton-BaDpU--M-CL7UtNSJ.js} +11 -11
- package/dist/assets/{CustomerOnboardingNoStepsPage-JnxUTXUI-92Zb-Tm2.js → CustomerOnboardingNoStepsPage-C_cxcuWE-CPcXa-uY.js} +8 -8
- package/dist/assets/CustomerOnboardingPage-Cuf1lJmu-BwFC9Sia.js +107 -0
- package/dist/assets/{CustomerOnboardingProductSuitePage-C47rlXpl-wD-8riam.js → CustomerOnboardingProductSuitePage-DEqdhh-2-wQlqTtpc.js} +4 -4
- package/dist/assets/Dashboard-DnR1KvYd-DzOeF_LG.js +778 -0
- package/dist/assets/{DashboardReportPage-B8sZBvi0-Bkka6zpc.js → DashboardReportPage-Tq4KsQuw-DPow_DwG.js} +67 -67
- package/dist/assets/{DepositAccTransactionItem-SBvKiZUo-DJaX4dE5.js → DepositAccTransactionItem-DWhVL-kH-YH09Nnsw.js} +2 -2
- package/dist/assets/{DepositAccTransactionListPage-DxyOodRG-CDy1pV7B.js → DepositAccTransactionListPage-BiaZBvV4-5ezA9uiX.js} +8 -8
- package/dist/assets/{DocumentSecurityBanner-2RwwRIbj-KpNSpuh7.js → DocumentSecurityBanner-eGDvEOvr-CyvEFE94.js} +1 -1
- package/dist/assets/DomesticWireDetailsPage-Bvmpk8LN-QDvn8074.js +21 -0
- package/dist/assets/{DownloadOverlay-D_7Q3gwF-BtTWiRYh.js → DownloadOverlay-C0vGOFIR-D53GsOkg.js} +20 -20
- package/dist/assets/{DrawerPage-D7ZExidR-CIWuPHJ5.js → DrawerPage-keu-rP1c-Ad94AagR.js} +8 -8
- package/dist/assets/EditPeoplePage-BTnhywM--fqULQ6DL.js +55 -0
- package/dist/assets/{EditReimbursementDetailPage-CZWIuR9q-DiQem3xT.js → EditReimbursementDetailPage-jqf5akyj-Dbu8QTQE.js} +74 -74
- package/dist/assets/{EntityDetailPage-liLBcaFa-BbblawRB.js → EntityDetailPage-D0mZIEcR-BRw589Gw.js} +2 -2
- package/dist/assets/{EntitySummarySection-BEubg_Ke-Bdvy7iaP.js → EntitySummarySection-bL2stKO1-B_cCEADD.js} +11 -11
- package/dist/assets/{ExpenseAutomationOverviewPage-De7pJxb1--Us_wwQ9.js → ExpenseAutomationOverviewPage-Cm00uGHv-CZxuB80N.js} +17 -17
- package/dist/assets/{ExpenseAutomationPage-JGlqvmW0-DGGQ5kes.js → ExpenseAutomationPage-BA8sRxM--BI5FDTiq.js} +84 -84
- package/dist/assets/{ExpressPayPage-DMuL6rjt-BbpZP04j.js → ExpressPayPage-DRNbLpuL-BqPn8Tnj.js} +8 -8
- package/dist/assets/{FeaturePreviewPage-eU2Fncgw-Df6t4vlN.js → FeaturePreviewPage-CeeAOF5C-B1ePxZD_.js} +2 -2
- package/dist/assets/{FollowStepsSection-CIOJXyXO-Ck9BhOv7.js → FollowStepsSection-DuElPK3y-BQRSekz2.js} +7 -7
- package/dist/assets/{GlobalReviewListPage-DbGsAMQF-DEii590Y.js → GlobalReviewListPage-DfjZMTms-CbpLeCqy.js} +10 -10
- package/dist/assets/HelpButton-BKCFqzW3-Ds4n43qE.js +28 -0
- package/dist/assets/{InformationCardStack-DBC0PIB2-ZpzVR8Pu.js → InformationCardStack-CmquAm7A-t9P9_NGQ.js} +5 -5
- package/dist/assets/{InsightsCardStack-BiyzY54v-DjzlYvXC.js → InsightsCardStack-D5ahtQWr-CLdQOUoS.js} +9 -9
- package/dist/assets/{InsightsSection-CB95rM5E-D6F0bC-C.js → InsightsSection-xgqf4arB-B8DybT5O.js} +3 -3
- package/dist/assets/{IntegrationsSettingsPage-IozP8XCs-Covl1ghU.js → IntegrationsSettingsPage-Cl6dfKQL-DtlX3Ccg.js} +5 -5
- package/dist/assets/{InternationalWireSwiftDetailsPage-CBLjT_qk-C24yuZmd.js → InternationalWireSwiftDetailsPage-D_jWoFli-DlLuf4mS.js} +11 -11
- package/dist/assets/{InternationalWireVerificationPage-BDHKKPIV-Kq4wZhMp.js → InternationalWireVerificationPage-it1U4OPj-CpKm_Jls.js} +17 -17
- package/dist/assets/{InviteFormPage-DcVcYJU0-CpPhN43t.js → InviteFormPage-DTMy8xZk-2c0kPCFn.js} +23 -23
- package/dist/assets/{InvitePageListView-CtGrvvWG-DUC9eyzx.js → InvitePageListView-X7W1jRxY-C4s0X98I.js} +31 -31
- package/dist/assets/InvitePeoplePage-fzgtceuE-B5MjB6BF.js +12 -0
- package/dist/assets/{InvoiceUploadSection-CzeBCw69-MIl0YoqM.js → InvoiceUploadSection-BhCDvIPX-wOQXy0Yc.js} +7 -7
- package/dist/assets/{IssueChargeCardPage-DywMnIW9-DZC1TtsH.js → IssueChargeCardPage-CqE8lMsX-C6vz_dxs.js} +22 -22
- package/dist/assets/{LabeledAddressValue-aXAfyy6x-zuxWHZ35.js → LabeledAddressValue-CCEVX0ke-C3sCHRt6.js} +1 -1
- package/dist/assets/{LabeledAddressValueField-BdNErK0u-BCVVhFLg.js → LabeledAddressValueField-B9iirKZj-Cw-fixky.js} +3 -3
- package/dist/assets/{LabeledControlledCheckBoxField-DPoSmzJi-B9fcjMs6.js → LabeledControlledCheckBoxField-Bl3-Zao6-6WoEZpzL.js} +1 -1
- package/dist/assets/{LabeledCreatableSingleSelectField-DsyZw9q6-BgU9LeRU.js → LabeledCreatableSingleSelectField-v86g-OZd-YeybErPj.js} +7 -7
- package/dist/assets/LabeledDocumentField-Dv4qzOY0-lFebzE73.js +41 -0
- package/dist/assets/LabeledDropDownFormattedTextField-BFMEaVfR-Dv78a583.js +59 -0
- package/dist/assets/{LabeledText-CcIJZUuh-CPcjfLXi.js → LabeledText-D9feJraX-padWmGRQ.js} +3 -3
- package/dist/assets/{LabeledUserSingleSelectWithSubtitlesField-CPJQjrJK-DWx8mI1V.js → LabeledUserSingleSelectWithSubtitlesField-BKNBvO_C-Dvjne4f2.js} +7 -7
- package/dist/assets/{LabeledZeniRolesDropDownField-WCoZXbuy-DHAUidGL.js → LabeledZeniRolesDropDownField-AwQaO42N-D65CRYdT.js} +26 -26
- package/dist/assets/{LinkJETransactionPage-jB4x6YYH-CygKAijz.js → LinkJETransactionPage-D3I2NvQw-B2_s-lzz.js} +8 -8
- package/dist/assets/{LowBalancePopup-c-6SC1hh-B9wQAJ9M.js → LowBalancePopup-OSUi1Alp-D-EAEgV_.js} +7 -7
- package/dist/assets/{MagicLinkACHDetailsPage-Cm98tK2_-7ec-cqHZ.js → MagicLinkACHDetailsPage-r3XSoJ11-ByBszh-P.js} +1 -1
- package/dist/assets/{MagicLinkDomesticWireDetailsPage-26S-99Ie-D3QNyjAa.js → MagicLinkDomesticWireDetailsPage-DPG9fUzZ-DLN7eK6J.js} +1 -1
- package/dist/assets/{MagicLinkInternationalWireDetailsPage-CY-hI3QM-D4hmDiEg.js → MagicLinkInternationalWireDetailsPage-CmXJXEaN-DSJ-KZsN.js} +1 -1
- package/dist/assets/{MagicLinkSuccessPage-1VMpD_t0-YoPoa1Fs.js → MagicLinkSuccessPage-CwszAuW2-CcLjVoXZ.js} +5 -5
- package/dist/assets/{MagicLinkTitleSection-BiZ9MGYp-Cl_WugVD.js → MagicLinkTitleSection-CvrbJ-of-eRuegy0D.js} +3 -3
- package/dist/assets/{MailingDetailsSection-DfxeX2uy-D2drNkzT.js → MailingDetailsSection-BJHZIZCt-CtVNeOVh.js} +1 -1
- package/dist/assets/{MeetingCalenderPopup-ifcJuMu9-ByO1X2Hh.js → MeetingCalenderPopup-C4r3bJ84-DJC2p-pW.js} +1 -1
- package/dist/assets/{Menu-B4Q04CAH-4XWj_HwH.js → Menu-MHZ6Ibt0-ClGVoJHI.js} +3 -3
- package/dist/assets/{MyBankConnectionsSettingsPage-rM_qhevU-DITmqjDy.js → MyBankConnectionsSettingsPage-DG1tuqAt-BJM-bRYR.js} +13 -13
- package/dist/assets/{MyPendingActivationChargeCardListPage-CwwpQgC6-iU-kUMq9.js → MyPendingActivationChargeCardListPage-DZyxqqyJ-gmzsoe2r.js} +1 -1
- package/dist/assets/{MyProfileSettingsPage-DbkgXE3d-BGJQs-jC.js → MyProfileSettingsPage-BnNbspx9-I-RR_w-w.js} +8 -8
- package/dist/assets/{NavBarWithPicker-CHrbDC5H-DmfI4NHq.js → NavBarWithPicker-3okDhiol-Mch2cVg7.js} +2 -2
- package/dist/assets/{NavigationArrow-B68QyyUR-DJ2p6cca.js → NavigationArrow-iw-yd_9S-DZPtXupp.js} +6 -9
- package/dist/assets/{NavigationDots-DYkUvR3H-CWQugA3e.js → NavigationDots-CB5JLuJi-yLXSzdJi.js} +1 -1
- package/dist/assets/{NewGlobalMerchantPage-CEZgARa1-Oq3mm2EE.js → NewGlobalMerchantPage-CcGws2R2-C4Fp7WXy.js} +33 -33
- package/dist/assets/NoDataChart-BsN_tNbW-BMMW2NFW.js +26 -0
- package/dist/assets/{NoDataTable-Z4rV9ZBK-p_2JIShf.js → NoDataTable-BbDo9Kma-CQu0CK8r.js} +1 -1
- package/dist/assets/{NotFoundPage-DGbe5Rh8-DP7xmEtU.js → NotFoundPage-gbtwlR8l-C5FBVYn3.js} +1 -1
- package/dist/assets/{NotificationSettingsPage-SovYc7X1-B3BS2dbe.js → NotificationSettingsPage-slkQwvVZ-CHC42QkE.js} +16 -16
- package/dist/assets/NotificationsListConfig-DtsQwW2b-qiwAhcXr.js +1 -0
- package/dist/assets/{NotificationsPage-D1uWQ3_a-DxSIxDxP.js → NotificationsPage-BAyRPK64-CK6wfh9r.js} +32 -32
- package/dist/assets/{OpExByVendorPage-bwyUuTg3-r5i2RybY.js → OpExByVendorPage-CofD6hKi-CAsz1_Xh.js} +5 -5
- package/dist/assets/{OverlayContainerPage-C0rUb6-5-DlNZMe2A.js → OverlayContainerPage-nhe7xtoR-BoqVZnRB.js} +1 -1
- package/dist/assets/{PandLWithForecastPage-C316N1hQ-aHIR4J9h.js → PandLWithForecastPage-_uOEFXiy-CCb56j7T.js} +7 -7
- package/dist/assets/{PaymentAccountSetupBillingAddressSection-07laMoUE-vyb_PzAc.js → PaymentAccountSetupBillingAddressSection-C0zGxU4f-CRvVxf4b.js} +8 -8
- package/dist/assets/{PeoplePage-nMBpp-i7-C_FzQc4I.js → PeoplePage-8GExF-Lt-BPrOO_zy.js} +19 -19
- package/dist/assets/{PortfolioAllocationFormPage-BNM5_3mQ-DaO3Xs0l.js → PortfolioAllocationFormPage-CMKEE7P7-CSoW27F2.js} +3 -3
- package/dist/assets/{PortfolioDetails-Cxr764um-DhzbvH6Q.js → PortfolioDetails-A3P3vG57-BlNZUWBn.js} +11 -11
- package/dist/assets/{ProductsCarousel-W3-LEsKP-DbLcA25z.js → ProductsCarousel-D9H3mUJ--BvtxFJIQ.js} +7 -7
- package/dist/assets/{PromoBaseCards-zZLO1ftd-CE6hJoyp.js → PromoBaseCards-CF0Bv_9G-CKYPGzvR.js} +25 -25
- package/dist/assets/{QBOConnectionDialog-027QZpKQ-BMM6Z1LZ.js → QBOConnectionDialog-D2zi5wKm-DM4ITFKi.js} +6 -6
- package/dist/assets/{QBOSetupSection-BT0OZMcW-35drr2J_.js → QBOSetupSection-B3Dj2g2k-Cs2MQ5jD.js} +11 -11
- package/dist/assets/{ReimbursementApprovalRuleDetailPage-DsBcRdLI-4vSu0HBp.js → ReimbursementApprovalRuleDetailPage-DgpHHy3U-MMqXWdUz.js} +1 -1
- package/dist/assets/{ReimbursementApprovalRulesPage-DFUfuIiJ-CI-ZWabB.js → ReimbursementApprovalRulesPage-BjFi-uJl-DaBDnL86.js} +8 -8
- package/dist/assets/{ReimbursementDetailPage-8b3khOnV-B2Q02bEe.js → ReimbursementDetailPage-BersvjG9-CiBW1b2M.js} +7 -7
- package/dist/assets/{ReimbursementPromoPage-BDuxIiMu-BQx3j8pw.js → ReimbursementPromoPage-K8dT-rtu-Dt7hPy-o.js} +16 -16
- package/dist/assets/{ReimbursementSetUpPage-CQnnv-Km-dR4LVsPp.js → ReimbursementSetUpPage-CfBuIpx6-al_7hXdG.js} +12 -12
- package/dist/assets/{ReimbursementsBulkReviewDrawerPage-B42Iy6Wl-CPgHrEv8.js → ReimbursementsBulkReviewDrawerPage-yaSD_tF5-D0BnyUB5.js} +1 -1
- package/dist/assets/{ReloadCard-BRfBNfTQ-BU52RUhd.js → ReloadCard-Do9Znv21-DK8BGS1A.js} +5 -5
- package/dist/assets/{ReportTableViewSelector-CsIuIfQF-CglQQFO3.js → ReportTableViewSelector-D1UrK7VQ-C8LWU1S2.js} +7 -7
- package/dist/assets/{ReportsPage-BgjHAROL-CDbPtbWw.js → ReportsPage-dER5Ukfc-SfboVh2R.js} +9 -9
- package/dist/assets/{RevenueChart-DSSPucUL-BpbrhJFv.js → RevenueChart-CCr_XauF-D36ZxwH2.js} +1 -1
- package/dist/assets/{ReviewDetailsPage-DRTS4tm7-GkJsi7Yf.js → ReviewDetailsPage-ZoXTLGfR-B_ONtomw.js} +19 -19
- package/dist/assets/{ReviewOverlay-fCgnrRah-tZ00a0Uu.js → ReviewOverlay-Bywh-8pJ-Bg5lskK_.js} +14 -14
- package/dist/assets/{RoleWithToolTip-aKLOITw0-B48eYV-X.js → RoleWithToolTip-CX9tF-BO-DG7wC_Jt.js} +6 -6
- package/dist/assets/{ScheduleDetailsFixedAssetsPage-ChR3tFhH-e-z1NRNI.js → ScheduleDetailsFixedAssetsPage-BEXr2qc0-3xkvpS1C.js} +8 -8
- package/dist/assets/{ScheduleDetailsPage-DmVZaX9M-CeCNgksq.js → ScheduleDetailsPage-CR8uJC5O-DnUdhwKF.js} +3 -3
- package/dist/assets/{ScheduleSequenceTable-CqrIr7OX-Cen2QelK.js → ScheduleSequenceTable-D7kDvImN-DWkMGP8Z.js} +50 -50
- package/dist/assets/{ScreenRoutes-ByaRWdsC.js → ScreenRoutes-erL9wWZG.js} +1 -1
- package/dist/assets/{SetUpAccountSection-DkqyfYdP-DWiWb20O.js → SetUpAccountSection-B0J0zCOF-oWsU5thz.js} +103 -103
- package/dist/assets/{SetUpDefaultSection-CEcqnqlD-BSjLZl3B.js → SetUpDefaultSection-ES6v0-xw-oKoRPhrf.js} +16 -16
- package/dist/assets/{SignIn-BKCeqJmF-B6GB44w2.js → SignIn-yQ-8MBRA-D6UXon_1.js} +19 -19
- package/dist/assets/{SignInScreen-BY-NI1BX.js → SignInScreen-DTuVG-E_.js} +1 -1
- package/dist/assets/{SpendManagementListViewPage-DWrIY48Y-1thafgez.js → SpendManagementListViewPage-_rUojA3M-DqnZrIvk.js} +13 -13
- package/dist/assets/{SpendManagementPerTabPage-BIK3QfAG-BprzbGtF.js → SpendManagementPerTabPage-Bhes-f7M-AdXufxw9.js} +47 -47
- package/dist/assets/{SpendManagementSection-BibcrHiQ-ojX7OXv7.js → SpendManagementSection-CQHWqht2-D_0KXsJm.js} +9 -9
- package/dist/assets/{SpendMgmtSetupAccountSection-BZzCEn49-xlvJK4VE.js → SpendMgmtSetupAccountSection-BHZ9nmWy-Ct-UFhaG.js} +14 -14
- package/dist/assets/{StatementItem-DujQ-hfS-Co0MjdA1.js → StatementItem-CKnsnb3u-CUpANIC7.js} +8 -8
- package/dist/assets/StatementsPage-B73U7d9e-BeHUtVc7.js +58 -0
- package/dist/assets/{StatusSwitcher-CmoFEW3h-B8khGWcG.js → StatusSwitcher-xR-S3KaW-DXC0VRqb.js} +4 -4
- package/dist/assets/{SubTabSwitcher-CZqJSgrt-BzzBfBEV.js → SubTabSwitcher-DczmDw-I-BDr0EcZn.js} +1 -1
- package/dist/assets/{SummaryCard-BC_pbmca-BA-2CDI2.js → SummaryCard-YTxf_JPz-Coldl1KM.js} +1 -1
- package/dist/assets/TaskManagementPage-LDFC29Ik-CNoI4m-y.js +508 -0
- package/dist/assets/{TimeRangeSwitcher-6HHMsbMu-BJeGDam3.js → TimeRangeSwitcher-C5yC8ifv-CCSUflgJ.js} +5 -5
- package/dist/assets/{TimeframeSwitcher-9Tl1lDvO-2gI3pMJ6.js → TimeframeSwitcher-D1xKpIjp-CW5UZCib.js} +5 -5
- package/dist/assets/TimeframeSwitcherWithToggle-BiHAqit5-B759eYFG.js +31 -0
- package/dist/assets/{TopExCard-BRR6W73W-BCkskQ6y.js → TopExCard-CJN2nSdQ-g0e-zKZy.js} +6 -6
- package/dist/assets/{TopExDetailPage-DzqG7MND-r9FRTnlF.js → TopExDetailPage-ClQK2WDh-DhYxPAx6.js} +11 -11
- package/dist/assets/{TransactionDetailPage-DD-5Uhso-5-XIEojv.js → TransactionDetailPage-CcNUBQmc-C-LCspti.js} +47 -47
- package/dist/assets/{TransactionList-B_1X_r62-D6FSjlP-.js → TransactionList-Dtqr5BZm--fERmRQ-.js} +13 -13
- package/dist/assets/{TransactionListBig-CUOjhYmg-CQ2RJ0bc.js → TransactionListBig-D5_iDOBi-D6XHrCJg.js} +18 -18
- package/dist/assets/{TransactionListPage-Ck8dLdRo-F9HAGy3S.js → TransactionListPage-DUCJRiyi-gKenoaPe.js} +6 -6
- package/dist/assets/{TransactionVendorDetailPage-C2_Yo1np-DO9ni0JA.js → TransactionVendorDetailPage-DSpchZAl-Dh-5qwdH.js} +6 -6
- package/dist/assets/{TransferDrawerPage-D9sHV8Dz-C3BJeiz0.js → TransferDrawerPage-BKWQEojA-hbYmgGo9.js} +28 -28
- package/dist/assets/{TreasuryOverviewPage-Co2mrPcn-BY4IGK6R.js → TreasuryOverviewPage-D1D2WipM-D-3r290_.js} +31 -31
- package/dist/assets/{TreasuryPromoPage-x3aBAAof-CzINUoky.js → TreasuryPromoPage-BKgJHnC1-CFaA1Ntn.js} +15 -15
- package/dist/assets/TreasurySetupPage-C2JtTOhh-RYkURx4_.js +152 -0
- package/dist/assets/{TreasuryStatementsPage-BIxlBphR-CLkwORFF.js → TreasuryStatementsPage-DKHWWnrU-D8FyTRXK.js} +7 -7
- package/dist/assets/{TreasuryTaxLetterPage-00l2eDaD-D4R_SIte.js → TreasuryTaxLetterPage-ieX9MUQd-DjUqrhOK.js} +7 -7
- package/dist/assets/{TreasuryTransferOrReviewPage-8kYRXJ8--BXlfWwAt.js → TreasuryTransferOrReviewPage-DebuIwR3-C0bGE1CG.js} +85 -85
- package/dist/assets/{TrendChart-CnawkdG8-C1f54OIB.js → TrendChart-B3VgdtYY-DKvOx-kx.js} +3 -3
- package/dist/assets/{TrendWithTransactions-CNNCV2hi-Lc8Mvmvx.js → TrendWithTransactions-BMorBxWJ-Bk3io0dy.js} +3 -3
- package/dist/assets/{UncategorizedAccountsMappingPage-6dSPWwUH-BNmql1oS.js → UncategorizedAccountsMappingPage-BtmfySl9-ChDGqLCY.js} +15 -15
- package/dist/assets/{UnitIntegrationPage-CQz8bAr--Be6E8wgt.js → UnitIntegrationPage-ByqJQgJ1-DOZOjWB7.js} +4 -4
- package/dist/assets/{UploadAdditionalDocumentOverlay-qVx1t-kK-BfnzSXgO.js → UploadAdditionalDocumentOverlay-Dwv3x7HQ-DAFruYVO.js} +1 -1
- package/dist/assets/{Vendor2FAPopup-BwICX5Jo-DRxdFSoT.js → Vendor2FAPopup-BVCUSOMr-DusuQd4O.js} +1 -1
- package/dist/assets/{VendorACHDetailsPage-U9vQ2YO1-C3wP_7rP.js → VendorACHDetailsPage-Cyp1bTJx-Bb_u0lQ9.js} +1 -1
- package/dist/assets/{VendorDetailPage-v3AJufvV-B6BEQrJw.js → VendorDetailPage-1_rVoehK-Exna90A5.js} +15 -15
- package/dist/assets/{VendorDomesticWireDetailsPage-DY5Enpxz-CMAOISi3.js → VendorDomesticWireDetailsPage-B0wv2GP--CBJnbhVR.js} +1 -1
- package/dist/assets/{VendorFiling1099EditablePage-BJ1K4EB2-CnqK8eQN.js → VendorFiling1099EditablePage-C5rHkQrV-BGIvQipF.js} +10 -10
- package/dist/assets/{VendorFirstReviewPage-Dqu2JeBh-BTSOdkvj.js → VendorFirstReviewPage-CDlmZHmw-QoRtPJE2.js} +29 -29
- package/dist/assets/{VendorInternationalWireDetailsPage-B3jL5IpJ-Ge2HUtcT.js → VendorInternationalWireDetailsPage-Cdy000Jx-J6b7bfbg.js} +7 -7
- package/dist/assets/{VendorInternationalWireSwiftDetailsPage-OyW2sXjN-BaDu_Rbp.js → VendorInternationalWireSwiftDetailsPage-DRN-5n5Y-CNM_VAVJ.js} +1 -1
- package/dist/assets/{VendorsAccountsSection-CnVky8J2-BnxyHrsh.js → VendorsAccountsSection-Ba7QpWAm-CKQDggOk.js} +4 -4
- package/dist/assets/{WarningsDrawerPage-Bc8HwhJZ-CoRSEL1r.js → WarningsDrawerPage-DCUPzxfi-BYSPfHfW.js} +4 -4
- package/dist/assets/{ZeniAccountDetailPage-I3Qn-mIV-D6WbzhnA.js → ZeniAccountDetailPage-DF7Tn3t3-yyv_Cgn9.js} +28 -28
- package/dist/assets/{ZeniAccountListViewPage-BFUoGrvu-CvFvWDHE.js → ZeniAccountListViewPage-Cz9v3TCo-D-RvbaDA.js} +18 -18
- package/dist/assets/ZeniAccountNavBarPieces-BSObmR0D-w7GK2i5h.js +14 -0
- package/dist/assets/{ZeniAccountPromoPage-B_Kt_gIx-BmUo-cHo.js → ZeniAccountPromoPage-D7veJGZk-D-YrsEI2.js} +10 -10
- package/dist/assets/{ZeniAccountSetupPage-BvzXgVNr-Cojq6XAe.js → ZeniAccountSetupPage-ftl559Pj-C-xIgDUh.js} +1 -1
- package/dist/assets/{ZeniCopyright-B5gFkT_K-Bd1To88b.js → ZeniCopyright-BScA_p2_-CnTtKSEg.js} +1 -1
- package/dist/assets/{ZeniTransferAmountSlider-dNQVv3xh-Dj4F9WJ8.js → ZeniTransferAmountSlider-Bu23FZCA-BlrXEMp9.js} +1 -1
- package/dist/assets/analytics-BSSiLa6f.js +7 -0
- package/dist/assets/{analyticsHelper-DaI4EFSR.js → analyticsHelper-C8rNMzIR.js} +1 -1
- package/dist/assets/{analyticsHelper-CiRIn2W--BxtgqDE2.js → analyticsHelper-CGq-fGOi-peFW_WyF.js} +1 -1
- package/dist/assets/{chartTypes-om8APqYr-BLTaCwIq.js → chartTypes-ChsIdl40-BE86tbr4.js} +1 -1
- package/dist/assets/{commonDimensions-CnEuBCL0-BaKrm6VO.js → commonDimensions-Dk1fkj7r-DLRSQmNd.js} +1 -1
- package/dist/assets/{detailCommon-B8snZE0k-CD_QEBke.js → detailCommon-BdiFpATU-WeUxnZIy.js} +6 -6
- package/dist/assets/{downloadPdf-UYNSbWcH-CCjYi8d_.js → downloadPdf-h21F3Bzk-CjxZKaAj.js} +1 -1
- package/dist/assets/{index-C5RQ_I4f.js → index-C0q2xQ43.js} +3324 -3364
- package/dist/assets/{liveblocks-sSQ9JElv.js → liveblocks-BUGn2yQ6.js} +1 -1
- package/dist/assets/{mapLoadingInProgressToTreeNode-Ct5Hw9GL-CIhY2PIH.js → mapLoadingInProgressToTreeNode-Bimz-BOL-Dlsg7XHk.js} +1 -1
- package/dist/assets/{mapSectionWithAcOnlyToTreeNode-DAi-q9qz-uRnsjJzp.js → mapSectionWithAcOnlyToTreeNode-Dy2RH2lH-Bxhhy_dm.js} +1 -1
- package/dist/assets/{mapSpacerToTreeNode-NdVrr_Rq-h2jl1W7n.js → mapSpacerToTreeNode-CadZGfr8-CsWvhMid.js} +1 -1
- package/dist/assets/{mapTimeframeBalancesToTreeNode-Bq1k2j24-C-EGB4JJ.js → mapTimeframeBalancesToTreeNode-BvXiirfs-D7NlfjoQ.js} +1 -1
- package/dist/assets/mui-BgvZYSo0.js +22 -0
- package/dist/assets/{play-icon-cU_HA46u-DKk-rWaT.js → play-icon-DD7TfH-R-B2AdmUNp.js} +1 -1
- package/dist/assets/{redux-ByjIRbhZ.js → redux-DmDqXYej.js} +1 -1
- package/dist/assets/{routing-Cpaypegg.js → routing-BNz5gZgX.js} +1 -1
- package/dist/assets/{toCOABalancesWithID-D8CsJNcd-D3oEVThj.js → toCOABalancesWithID-Dy9J_UtA-GKQFY-wL.js} +1 -1
- package/dist/assets/{toChartData-DUoI4wMR-BpwvMCd8.js → toChartData-BdomEAJ--DBqHs0fD.js} +1 -1
- package/dist/assets/{treasuryColorHelper-X9PYqjk_-B0f97nM8.js → treasuryColorHelper-D2LtJllD-BWyq3ShU.js} +1 -1
- package/dist/assets/{uploadAttachment-BHcSLQXP-Dd6nHf0l.js → uploadAttachment-C5PL0FaC-qWy-M3Ai.js} +29 -29
- package/dist/assets/{uploadReceipts-Buvz7DfG-TsfYrPiB.js → uploadReceipts-BH9fi3Vt-Bn1YAl68.js} +1 -1
- package/dist/index.html +1 -1
- package/package.json +5 -5
- package/dist/assets/AccountInfoPage-DygdgdmU-DOUY2WTN.js +0 -18
- package/dist/assets/AccountRow-CpUAoVFw-BuMEboIn.js +0 -298
- package/dist/assets/BillingSettingsPage-CqFQk_xm-Wzi8-Pxm.js +0 -44
- package/dist/assets/BillsBulkReviewDrawerPage-Bo9JcC7R-D0jNWqxU.js +0 -1
- package/dist/assets/ChargeCardPromoPage-CIboCUSV-y-DLxjGT.js +0 -190
- package/dist/assets/CheckDepositDrawerPage-K9NmaIpu-DOGNQqAq.js +0 -206
- package/dist/assets/ConfettiBurst-Bvvql-8k-BorMAewb.js +0 -1
- package/dist/assets/CustomerOnboardingContainerPage-BsErtHzd-BdcZe_io.js +0 -1
- package/dist/assets/CustomerOnboardingPage-C1pKcpFC-CGanCl6o.js +0 -107
- package/dist/assets/Dashboard-CyZG5DEY-C3KfWHk8.js +0 -1251
- package/dist/assets/DomesticWireDetailsPage-BbmbS2h3-Ch-Vtjq-.js +0 -21
- package/dist/assets/EditPeoplePage-QsjUi5_S-DkWH1BmJ.js +0 -55
- package/dist/assets/HelpButton-DYFzwkI3-Cel7B9gC.js +0 -28
- package/dist/assets/InvitePeoplePage-CV75uhrr-B1Hdsrwm.js +0 -12
- package/dist/assets/LabeledDocumentField-IC75UO-m-BR65Je6h.js +0 -41
- package/dist/assets/LabeledDropDownFormattedTextField-DRdoEEXa-ihK1IWBq.js +0 -59
- package/dist/assets/NoDataChart-CEPkoKCh-CJB-ycSI.js +0 -26
- package/dist/assets/NotificationsListConfig-8oQmiFyf-BOGk1_4Q.js +0 -1
- package/dist/assets/StatementsPage-BEBaWRll-Dv0qqBwe.js +0 -58
- package/dist/assets/TaskManagementPage-IrjSDISn-Cdu4CkH2.js +0 -508
- package/dist/assets/TimeframeSwitcherWithToggle-L5acx38l-CrZfZFxd.js +0 -31
- package/dist/assets/TreasurySetupPage-COLv35Sa-D7XzYH1g.js +0 -152
- package/dist/assets/ZeniAccountNavBarPieces-B6K9Q5ca-BG64SHxp.js +0 -14
- package/dist/assets/analytics-DThoELaW.js +0 -7
- package/dist/assets/mui-C5LQ0bMa.js +0 -25
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{a5 as ai,u as bt,w as ft,a as en,z as Ci,l as ee,M as me,J as tn,X as Ie,fL as Xn,fN as Qn,fO as eo,j as t,g5 as to,F as nn,bN as li,bP as on,bQ as an,Y as q,o as i,C as c,aW as ki,aH as io,dr as no,fP as oo,f_ as rn,fV as Ii,a7 as ln,m as sn,fW as ao,ev as _e,g6 as At,eY as si,d as xt,g7 as ro,g as j,a6 as cn,Z as ci,p as a,aR as lo,fY as so,c4 as co,eC as di,g8 as zt,cP as fe,cR as xe,c6 as ui,cg as ct,eh as uo,cO as dn,q as Rt,c9 as un,c8 as Qe,co as st,v as mi,g9 as mo,e_ as po,c3 as ho,ab as Di,aQ as go,av as mn,ee as yo,ef as bo,aq as Bt,fQ as fo,eZ as pn,Q as pi,h as hn,cq as gn,ah as Mt,eS as xo,as as wo,cu as So,cW as vo,s as hi,K as Ti,bu as yn,am as ji,cn as $o,f as Co,cc as bn,_ as ko,ga as fn,gb as ri,fG as Pi,gc as Ot,cm as Io,fK as Do,b6 as To,cl as jo}from"./index-C0q2xQ43.js";import{b as $,n,f as $t}from"./vendor-CnQcJ2Lu.js";import{_ as Po}from"./liveblocks-BUGn2yQ6.js";import xn from"./InvoiceUploadSection-BhCDvIPX-wOQXy0Yc.js";import{r as Ro,f as Lt,d as yt,p as gi,u as Ri,h as $e}from"./types-DyvtCprH-BcZYcgaq.js";import{I as Oo}from"./LabeledCreatableSingleSelectField-v86g-OZd-YeybErPj.js";import{S as Lo}from"./CurrencySelectField-DYvc6rwt-ByvmhvI-.js";import{J as Ao}from"./SetUpDefaultSection-ES6v0-xw-oKoRPhrf.js";import{e as zo}from"./BankAccountSection-CNQgxgSJ-Ca43edcO.js";import{W as Bo,A as Mo}from"./BankAccountWarningSection-V0HHzW57-BXTr_4tn.js";import{o as Fo}from"./radio-default-CiSgisfh-ub7QGXr8.js";import"./mui-BgvZYSo0.js";import"./analytics-BSSiLa6f.js";import"./routing-BNz5gZgX.js";import"./sentry-HDxG13yk.js";import"./redux-DmDqXYej.js";import"./crypto-BURQLTgV.js";import"./AttachmentView-Afp_U4fV-ChOQ6Ub6.js";import"./uploadReceipts-BH9fi3Vt-Bn1YAl68.js";const Je=(e,o)=>`${e}.${o}`,Oi={largeLabelWidth:new c(120,120,160),paddingBottom:new c(a[3],a[2])},{spendManagement:{reimbursement:{reimbursementDetail:Pe}},dateFormat:Eo,common:No}=me.getLocalizedStrings(),Wo=({lineIndex:e,mileage:o,classList:r,defaultCurrency:d,sectionId:p,isReimbursementCommentingEnabled:C,isDisabled:m,isAddReimbursementDisabled:S,companyMileageConfigInfo:b,reimbursementId:l,classHierarchyList:k})=>{const f=Ie(),s=ft(),g=zt(),w=`dashboard_${s.currentTenant?.companyId}`,P=bt(),{getValues:D}=ct(),v=No.strings.empty,K=D(Je(p,"distanceInMiles")),L=Oi.largeLabelWidth.value(f),I={application:"dashboard",companyId:s.currentTenant?.companyId,tab:"reimbursement",entityId:l},E=A=>r.filter(_=>_.classId===A)[0]?.accountingClassNumber,te=r.find(A=>A.classId===o.class),pe={valueContainer:A=>({...A,padding:`2px ${i.sp3} !important`,overflow:"unset"}),singleValue:()=>({margin:0})};return t.jsxs(t.Fragment,{children:[t.jsx(fe,{isThreadAllowed:C&&l!=null,dashboardTabKey:xe({type:"details",key:`${e}.mileage.transactionDate`}),roomId:w,companyId:s.currentTenant?.companyId??v,companyName:s.currentTenant?.companyName??v,entityId:l,dashboardOptionType:"reimbursement",filterMetaData:{...I,entityType:`reimbursement.details.${$e("transactionDate",e,"mileage")}`},fieldThreadTargetElement:g?.sharedRef?.contentWrapperRef,children:t.jsx(bn,{isDisabled:m,label:{label:Pe.transactionDate,width:L},style:{paddingBottom:Oi.paddingBottom.valuePx(f),width:"auto"},dateField:{name:Je(p,"transactionDate"),placeholder:Pe.datePlaceholder,defaultValue:o?.transactionDate,dateFormat:Eo.visual.defaultInput,autoComplete:"off",maxDate:ee.dateNow(),registerOptions:{required:!0,validate:A=>!!A}}})}),t.jsx(Ct,{}),t.jsx(fe,{isThreadAllowed:C&&l!=null,dashboardTabKey:xe({type:"details",key:`${e}.mileage.distanceInMiles`}),roomId:w,companyId:s.currentTenant?.companyId??v,companyName:s.currentTenant?.companyName??v,entityId:l,dashboardOptionType:"reimbursement",filterMetaData:{...I,entityType:`reimbursement.details.${$e("distanceInMiles",e,"mileage")}`},fieldThreadTargetElement:g?.sharedRef?.contentWrapperRef,children:t.jsx(Pi,{isDisabled:S?"disabled":void 0,style:{width:"auto"},label:{label:Pe.distanceInMiles,width:L},formattedTextField:{type:"number",name:Je(p,"distanceInMiles"),placeholder:Pe.addMiles,defaultValue:o.distanceInMiles,registerOptions:{required:!0,validate:A=>A!=null?A>0:!0,min:.01},returnValueType:"floatValue",allowNegative:!1,isNumericString:!1,decimalScale:2}})}),t.jsx(Ct,{}),t.jsx(fe,{isThreadAllowed:C&&l!=null,dashboardTabKey:xe({type:"details",key:`${e}.mileage.amount`}),roomId:w,companyId:s.currentTenant?.companyId??v,companyName:s.currentTenant?.companyName??v,entityId:l,dashboardOptionType:"reimbursement",filterMetaData:{...I,entityType:`reimbursement.details.${$e("amount",e,"mileage")}`},fieldThreadTargetElement:g?.sharedRef?.contentWrapperRef,children:t.jsx(Pi,{isDisabled:"disabled",label:{label:Pe.amount,width:L},formattedTextField:{type:"number",name:Je(`${p}.amount`,"amount"),defaultValue:o.amount?.amount,placeholder:Qe(Pe.amount),returnValueType:"floatValue",prefix:o.amount?.currencySymbol,allowNegative:!1,isNumericString:!1,registerOptions:{required:!0,validate:A=>A!=null?A>0:!0},autoComplete:"off",decimalSeparator:".",decimalScale:2,fixedDecimalScale:!1,thousandSeparator:!0},style:{width:"auto"},additionalInfoLabel:K!=null&&b?.mileageUnitAmount!=null?`${d.currencySymbol}${b?.mileageUnitAmount} per mile x ${K}`:void 0})}),t.jsx(Ct,{}),t.jsx(fe,{isThreadAllowed:C&&l!=null,dashboardTabKey:xe({type:"details",key:`${e}.mileage.memo`}),roomId:w,companyId:s.currentTenant?.companyId??v,companyName:s.currentTenant?.companyName??v,entityId:l,dashboardOptionType:"reimbursement",filterMetaData:{...I,entityType:`reimbursement.details.${$e("memo",e,"mileage")}`},fieldThreadTargetElement:g?.sharedRef?.contentWrapperRef,children:t.jsx(ui,{isDisabled:m,label:{label:Pe.memo,width:L},style:{width:"auto"},text:{type:"text",name:Je(p,"memo"),placeholder:Qe(Pe.memo),defaultValue:o.memo,autoComplete:"off",options:{pattern:fn}}})}),t.jsx(Ct,{}),t.jsx(fe,{isThreadAllowed:C&&l!=null,dashboardTabKey:xe({type:"details",key:`${e}.mileage.class`}),roomId:w,companyId:s.currentTenant?.companyId??v,companyName:s.currentTenant?.companyName??v,entityId:l,dashboardOptionType:"reimbursement",filterMetaData:{...I,entityType:`reimbursement.details.${$e("class",e,"mileage")}`},fieldThreadTargetElement:g?.sharedRef?.contentWrapperRef,style:{borderRadius:`0 0 ${i.sp2} ${i.sp2}`},children:t.jsx(ri,{isLoading:!1,label:{label:Pe.department,width:L},groupedSingleSelectField:{shouldShowChevronIcon:!1,name:Je(p,"class"),placeholder:Qe(Pe.department),valueToId:A=>E(A),defaultValue:{selectedOption:te?.classId,allOptions:_e(k,[])},style:{width:"100%"},customStyleConfig:pe,registerOptions:{required:!0,validate:A=>!!A.selectedOption}},style:{borderBottom:`1px solid ${P.colors.grey3}`,borderBottomLeftRadius:i.sp2,borderBottomRightRadius:i.sp2},fullWidthSelect:!0},Je(p,"class"))})]})},Ct=n.div`
|
|
2
2
|
display: flex;
|
|
3
3
|
flex: 1;
|
|
4
4
|
background-color: ${e=>e.theme.colors.grey3};
|
|
5
5
|
min-height: 1px;
|
|
6
6
|
max-height: 1px;
|
|
7
|
-
`,Li={amounWidth:new c(50,30),currencyWidth:new c(50,70)};function Uo({name:e,placeHolder:o,defaultValue:r,isDisabled:d,showAmountCurrencyError:p,style:C,allCurrencies:m}){const[S,b]
|
|
7
|
+
`,Li={amounWidth:new c(50,30),currencyWidth:new c(50,70)};function Uo({name:e,placeHolder:o,defaultValue:r,isDisabled:d,showAmountCurrencyError:p,style:C,allCurrencies:m}){const[S,b]=$.useState(!1),{getValues:l,formState:{errors:k}}=ct(),f=bt(),s=Ie(),g=d!=null,w=l(e),P=`${w?.amount} ${w?.currency?.selectedOption}`,D=st(k,e)&&Ot(k,`${e}.amount`)!=null,v=st(k,e)&&Ot(k,`${e}.currency`)!=null,K=p===!0?D||v:!1,L=!K&&S===!1;return $.useEffect(()=>{L===!1&&b(!0)},[L]),t.jsx(sn,{onClickAway:()=>g===!1&&!K&&b(!1),children:t.jsx(_o,{style:C,isDisabled:g,tabIndex:L&&!g?0:void 0,onClick:()=>g===!1&&b(!0),"data-testid":q("currency-amount-field",e),children:t.jsxs(t.Fragment,{children:[w?.amount!=null?t.jsx(Ai,{className:"amount-field",isVisible:L,children:P}):t.jsx(Ai,{className:"amount-field amount-placeholder",isVisible:L,children:o?.name}),t.jsxs(Vo,{isVisible:!L,children:[t.jsx(Do,{type:"number",name:`${e}.amount`,defaultValue:r?.amount,placeholder:o?.amount,returnValueType:"floatValue",allowNegative:!1,isNumericString:!1,registerOptions:{required:!0,validate:I=>I!=null?I>0:!0},autoComplete:"off",decimalSeparator:".",decimalScale:2,fixedDecimalScale:!1,thousandSeparator:!0,isDisabled:d,style:{display:"flex",flexGrow:1,width:Li.amounWidth.valuePercentage(s),cursor:"inherit"},bgColor:f.colors.background,isFieldError:D,shouldHighlightZeroAmount:!0}),L?null:t.jsx(Ho,{}),t.jsx(Lo,{name:`${e}.currency`,registerOptions:{validate:I=>I!=null&&I.selectedOption!=null},defaultValue:{allOptions:m.map(I=>({label:s==="small"?I.currencyCode:`${I.currencyCode} - ${I.currency}`,value:I.currencyCode,countryCode:I.countryCode})),selectedOption:r?.currencyCode},controlStyle:{justifyContent:"flex-start",backgroundColor:f.colors.background},isDisabled:d,style:{width:Li.currencyWidth.valuePercentage(s),flexGrow:1},isOptionRemovable:!1})]})]})})})}const Vo=n.div`
|
|
8
8
|
display: ${e=>e.isVisible?"flex":"none"};
|
|
9
9
|
width: 100%;
|
|
10
10
|
input {
|
|
@@ -37,7 +37,7 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
37
37
|
&.amount-placeholder {
|
|
38
38
|
color: ${e=>e.theme.colors.grey1};
|
|
39
39
|
}
|
|
40
|
-
`,Fe={width:new c(343,580,726),height:new c(a[6],a[6]),controlHeight:new c(a[6],a[6]),paddingTopBottom:new c(a[2],a[2]),marginRight:new c(a[2],a[2]),labelMarginLeft:new c(a[3],a[4]),labelMarginRight:new c(a[3],a[4]),labelMarginTop:new c(a[2],a[2])},wn={infoLabel:new pi("extraSmallRegular","smallRegular")};function
|
|
40
|
+
`,Fe={width:new c(343,580,726),height:new c(a[6],a[6]),controlHeight:new c(a[6],a[6]),paddingTopBottom:new c(a[2],a[2]),marginRight:new c(a[2],a[2]),labelMarginLeft:new c(a[3],a[4]),labelMarginRight:new c(a[3],a[4]),labelMarginTop:new c(a[2],a[2])},wn={infoLabel:new pi("extraSmallRegular","smallRegular")};function qo({isDisabled:e,label:o,currencyAmountField:r,style:d,errorInfoLabel:p,isAdditionalInfoLabelLoading:C,showAdditionalLabelTooltip:m=!1,additionalLabelTooltip:S,additionalInfoLabel:b,showAdditionalInfoLabel:l=!0}){const k=Ie(),{formState:{errors:f}}=ct(),s=st(f,r.name)&&Ot(f,`${r.name}.amount`)!=null,g=st(f,r.name)&&Ot(f,`${r.name}.currency`)!=null,w=r.showAmountCurrencyError===!0?s||g:!1,P=s||g||w,D=()=>{if(C===!0)return t.jsx(Zo,{children:t.jsx(xt,{size:"Small",start:!0})});if(l&&b||w){let v=null;return m===!0&&l&&b&&(v=t.jsx(yn,{placement:k==="small"?"bottom":"right",maxWidth:"364px",title:t.jsx(Jo,{children:S??""}),children:t.jsx(Qo,{children:t.jsx(ea,{})})})),t.jsxs(Xo,{size:k,isError:w,hasToolTip:m,children:[v,b]})}};return t.jsxs(Ko,{size:k,style:d,isDisabled:e!=null,isAmountError:s,isCurrencyError:g,"data-testid":q("labeled-currency-amount-field",r.name),children:[t.jsx(Io,{isDisabled:e,label:o.label,htmlFor:r.name,style:{marginLeft:Fe.labelMarginLeft.value(k),marginRight:Fe.labelMarginRight.value(k),marginTop:Fe.labelMarginTop.value(k),width:o.width??"auto"}}),t.jsxs(Yo,{labelWidth:o.width,children:[t.jsx(Uo,{...r,isDisabled:e,style:{flexGrow:1,height:Fe.controlHeight.value(k)}}),P?t.jsx(Go,{size:k,hasError:P,children:p}):null,D()]})]})}const Ko=n.div`
|
|
41
41
|
display: flex;
|
|
42
42
|
flex-direction: row;
|
|
43
43
|
align-items: flex-start;
|
|
@@ -121,12 +121,12 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
121
121
|
color: ${e=>e.theme.colors.grey1};
|
|
122
122
|
background: ${e=>e.theme.colors.overlayColor};
|
|
123
123
|
border-radius: ${i.sp1};
|
|
124
|
-
`,
|
|
124
|
+
`,Zo=n.div`
|
|
125
125
|
padding-right: ${i.sp3};
|
|
126
126
|
padding-top: ${i.sp1};
|
|
127
127
|
display: flex;
|
|
128
128
|
justify-content: flex-end;
|
|
129
|
-
`,
|
|
129
|
+
`,Xo=n.label`
|
|
130
130
|
display: flex;
|
|
131
131
|
justify-content: flex-end;
|
|
132
132
|
color: ${e=>e.isError?j.important:e.theme.colors.hero};
|
|
@@ -137,16 +137,16 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
137
137
|
padding-right: ${i.sp3};
|
|
138
138
|
text-align: right;
|
|
139
139
|
margin-top: ${e=>e.hasToolTip===!0?i.sp1:i.sp0};
|
|
140
|
-
`,
|
|
140
|
+
`,Qo=n.div`
|
|
141
141
|
display: flex;
|
|
142
142
|
margin-right: ${i.sp2};
|
|
143
143
|
margin-top: 2px;
|
|
144
144
|
align-items: center;
|
|
145
|
-
`,ea=n(
|
|
145
|
+
`,ea=n(To)`
|
|
146
146
|
width: ${i.sp3};
|
|
147
147
|
height: ${i.sp3};
|
|
148
148
|
color: inherit;
|
|
149
|
-
`,Be=(e,o)=>`${e}.${o}`,jt={largeLabelWidth:new c(120,120,160),smallLabelWidth:new c(85,85,160),paddingBottom:new c(a[3],a[2]),autoFillIconLeft:new c(-8,-24)},{dateFormat:ta,common:Sn,spendManagement:{reimbursement:{reimbursementDetail:de}}}=me.getLocalizedStrings(),{strings:{empty:oe}}=Sn,ia=(e,o)=>{const r=e.slice(1);let d=!1;return r.forEach(p=>{p.account?.qboId!=null&&p.account?.qboId===o&&(d=!0)}),d},na=e=>e.charAt(0).toLowerCase()+e.slice(1),oa=({lineIndex:e,outOfPocket:o,accountList:r,classList:d,merchantList:p,isAddReimbursementDisabled:C,sectionId:m,isReimbursementCommentingEnabled:S,isDisabled:b,autoFields:l=[],accountsHierarchyList:k,classHierarchyList:f,reimbursementId:s,tentativeMerchantName:g,allCurrencies:w,uncategorizedAccounts:P})=>{const
|
|
149
|
+
`,Be=(e,o)=>`${e}.${o}`,jt={largeLabelWidth:new c(120,120,160),smallLabelWidth:new c(85,85,160),paddingBottom:new c(a[3],a[2]),autoFillIconLeft:new c(-8,-24)},{dateFormat:ta,common:Sn,spendManagement:{reimbursement:{reimbursementDetail:de}}}=me.getLocalizedStrings(),{strings:{empty:oe}}=Sn,ia=(e,o)=>{const r=e.slice(1);let d=!1;return r.forEach(p=>{p.account?.qboId!=null&&p.account?.qboId===o&&(d=!0)}),d},na=e=>e.charAt(0).toLowerCase()+e.slice(1),oa=({lineIndex:e,outOfPocket:o,accountList:r,classList:d,merchantList:p,isAddReimbursementDisabled:C,sectionId:m,isReimbursementCommentingEnabled:S,isDisabled:b,autoFields:l=[],accountsHierarchyList:k,classHierarchyList:f,reimbursementId:s,tentativeMerchantName:g,allCurrencies:w,uncategorizedAccounts:P})=>{const D=Ie(),v=ft(),K=zt(),L=bt(),I=o.isCategoryUpdateSelected!=null&&o.recommendedAccount!=null&&!o.isCategoryFirstTimeAutofilled&&!ia(o.recommendations,o.account),E=o.isRetainedCategorySelected!=null&&o.retainedAccount!=null,te=jt.largeLabelWidth.value(D),pe=jt.smallLabelWidth.value(D),A=p.map(R=>R.id??oe),_={application:"dashboard",companyId:v.currentTenant?.companyId,tab:"reimbursement",entityId:s},Y=`dashboard_${v.currentTenant?.companyId}`,H=R=>p.find(ge=>ge.id===R)?.name??R,ie=r.find(R=>R.qboId===o.account),Q=R=>[P.expense?.qboId,P.income?.qboId].includes(R),we=d.find(R=>R.classId===o.class),he={valueContainer:R=>({...R,padding:`2px ${i.sp3} !important`,overflow:"unset"}),singleValue:()=>({margin:0})},re=R=>r.filter(ge=>ge.qboId===R)[0]?.qboId,J=R=>d.filter(ge=>ge.classId===R)[0]?.accountingClassNumber,le=me.getLocalizedStrings().spendManagement.reimbursement.reimbursementDetail.tooltip.category.replace("__based__",na(o?.recommendedAccount?.reason??oe)),Oe=At(k,o.recommendations);return t.jsxs(t.Fragment,{children:[g!=null||l.includes("merchant")?t.jsx(ot,{children:t.jsx(rt,{windowSize:D,children:t.jsx(at,{})})}):null,t.jsx(fe,{isThreadAllowed:S&&s!=null,dashboardTabKey:xe({type:"details",key:`${e}.out_of_pocket.merchant`}),roomId:Y,companyId:v.currentTenant?.companyId??oe,companyName:v.currentTenant?.companyName??oe,entityId:s,dashboardOptionType:"reimbursement",filterMetaData:{..._,entityType:`reimbursement.details.${$e("merchant",e,"out_of_pocket")}`},fieldThreadTargetElement:K?.sharedRef?.contentWrapperRef,children:t.jsx(Oo,{isDisabled:b!=null||C?"disabled":void 0,label:{label:de.merchant,width:te},style:{width:"auto"},creatableSingleSelectField:{name:Be(m,"merchant"),placeholder:de.merchantPlaceholder,defaultValue:{selectedOption:o.merchant??oe,allOptions:A},registerOptions:{required:!0,validate:R=>!!R.selectedOption}},isOptionRemovable:!0,addIconInCreateLabel:!0,getLabelForId:H})}),t.jsx(kt,{}),l.includes("transactionDate")?t.jsx(ot,{children:t.jsx(rt,{windowSize:D,children:t.jsx(at,{})})}):null,t.jsx(fe,{isThreadAllowed:S&&s!=null,dashboardTabKey:xe({type:"details",key:`${e}.out_of_pocket.transactionDate`}),roomId:Y,companyId:v.currentTenant?.companyId??oe,companyName:v.currentTenant?.companyName??oe,entityId:s,dashboardOptionType:"reimbursement",filterMetaData:{..._,entityType:`reimbursement.details.${$e("transactionDate",e,"out_of_pocket")}`},fieldThreadTargetElement:K?.sharedRef?.contentWrapperRef,children:t.jsx(bn,{isDisabled:b,label:{label:de.transactionDate,width:te},style:{paddingBottom:jt.paddingBottom.valuePx(D),width:"auto"},dateField:{name:Be(m,"transactionDate"),placeholder:de.datePlaceholder,defaultValue:o?.transactionDate,dateFormat:ta.visual.defaultInput,autoComplete:"off",maxDate:ee.dateNow(),registerOptions:{required:!0,validate:R=>!!R}}})}),t.jsx(kt,{}),l.includes("amount")?t.jsx(ot,{children:t.jsx(rt,{windowSize:D,isTwoLined:!0,children:t.jsx(at,{})})}):null,t.jsx(fe,{isThreadAllowed:S&&s!=null,dashboardTabKey:xe({type:"details",key:`${e}.out_of_pocket.amount`}),roomId:Y,companyId:v.currentTenant?.companyId??oe,companyName:v.currentTenant?.companyName??oe,entityId:s,dashboardOptionType:"reimbursement",filterMetaData:{..._,entityType:`reimbursement.details.${$e("amount",e,"out_of_pocket")}`},fieldThreadTargetElement:K?.sharedRef?.contentWrapperRef,children:t.jsx(qo,{isDisabled:b!=null||C?"disabled":void 0,label:{label:de.amount,width:pe},style:{width:"auto"},currencyAmountField:{style:{height:i.sp6},name:`${m}.amount`,defaultValue:{amount:o.amount.amount,currencyCode:o.amount.currencyCode,currencySymbol:o.amount.currencySymbol},placeHolder:{amount:de.addAmount,name:de.addAmount},allCurrencies:w,showAmountCurrencyError:!0},showAdditionalInfoLabel:!0,showAdditionalLabelTooltip:!0,additionalLabelTooltip:de.amountExchangeRateTooltip,isAdditionalInfoLabelLoading:o.isConvertedCurrencyLoading===!0,additionalInfoLabel:!tn(o.homeCurrencyDetails,o.amount)&&o.amount.currencyCode!==Sn.currency.currencyCode&&o.homeCurrencyDetails?.amount!==0?`${ko("0,0[.]00",o.homeCurrencyDetails)} ${o.homeCurrencyDetails?.currencyCode}`:void 0})}),t.jsx(kt,{}),l.includes("memo")?t.jsx(ot,{children:t.jsx(rt,{windowSize:D,children:t.jsx(at,{})})}):null,t.jsx(fe,{isThreadAllowed:S&&s!=null,dashboardTabKey:xe({type:"details",key:`${e}.out_of_pocket.memo`}),roomId:Y,companyId:v.currentTenant?.companyId??oe,companyName:v.currentTenant?.companyName??oe,entityId:s,dashboardOptionType:"reimbursement",filterMetaData:{..._,entityType:`reimbursement.details.${$e("memo",e,"out_of_pocket")}`},fieldThreadTargetElement:K?.sharedRef?.contentWrapperRef,children:t.jsx(ui,{isDisabled:b,label:{label:de.memo,width:te},style:{width:"auto"},text:{type:"text",name:Be(m,"memo"),placeholder:Qe(de.memo),defaultValue:o.memo,autoComplete:"off",options:{pattern:fn}}})}),t.jsx(kt,{}),l.includes("account")?t.jsx(ot,{children:t.jsx(rt,{windowSize:D,children:t.jsx(at,{})})}):null,t.jsx(fe,{isThreadAllowed:S&&s!=null,dashboardTabKey:xe({type:"details",key:`${e}.out_of_pocket.account`}),roomId:Y,companyId:v.currentTenant?.companyId??oe,companyName:v.currentTenant?.companyName??oe,entityId:s,dashboardOptionType:"reimbursement",filterMetaData:{..._,entityType:`reimbursement.details.${$e("account",e,"out_of_pocket")}`},fieldThreadTargetElement:K?.sharedRef?.contentWrapperRef,children:t.jsx(ri,{label:{label:de.category,width:te},groupedSingleSelectField:{shouldShowChevronIcon:I||E,name:Be(m,"account"),placeholder:de.categoryPlaceholder,valueToId:R=>re(R),defaultValue:{selectedOption:ie?.qboId??ie?.accountId,allOptions:Oe},style:{width:"100%"},customStyleConfig:he,registerOptions:{required:!0,validate:R=>!!R.selectedOption}},disableCurrentOption:Q,style:{borderBottom:`1px solid ${L.colors.grey3}`,minHeight:i.sp6,boxSizing:"initial"},fullWidthSelect:!0,isLoading:o.isRecommendationLoading,recommendationCheckboxField:I?{tooltipProps:{text:le},label:{label:o.recommendedAccount?.accountName??oe},checkBoxField:{name:Be(m,"isCategoryUpdateSelected"),defaultChecked:!!o.isCategoryUpdateSelected}}:void 0,retainCheckboxField:E?{label:{label:o.retainedAccount?.accountName??oe},checkBoxField:{name:Be(m,"isRetainedCategorySelected"),defaultChecked:!!o.isRetainedCategorySelected}}:void 0},Be(m,"account"))}),l.includes("class")?t.jsx(ot,{children:t.jsx(rt,{windowSize:D,children:t.jsx(at,{})})}):null,t.jsx(fe,{isThreadAllowed:S&&s!=null,dashboardTabKey:xe({type:"details",key:`${e}.out_of_pocket.class`}),roomId:Y,companyId:v.currentTenant?.companyId??oe,companyName:v.currentTenant?.companyName??oe,entityId:s,dashboardOptionType:"reimbursement",filterMetaData:{..._,entityType:`reimbursement.details.${$e("class",e,"out_of_pocket")}`},fieldThreadTargetElement:K?.sharedRef?.contentWrapperRef,style:{borderRadius:`0 0 ${i.sp2} ${i.sp2}`},children:t.jsx(ri,{isLoading:!1,label:{label:de.department,width:te},groupedSingleSelectField:{shouldShowChevronIcon:!1,name:Be(m,"class"),placeholder:Qe(de.department),valueToId:R=>J(R),defaultValue:{selectedOption:we?.classId,allOptions:_e(f,[])},style:{width:"100%"},customStyleConfig:he,registerOptions:{required:!0,validate:R=>!!R.selectedOption}},style:{borderBottom:`1px solid ${L.colors.grey3}`,borderBottomLeftRadius:i.sp2,borderBottomRightRadius:i.sp2},fullWidthSelect:!0},Be(m,"class"))})]})},ot=n.span`
|
|
150
150
|
position: relative;
|
|
151
151
|
`,at=n(di)`
|
|
152
152
|
color: ${e=>e.theme.colors.primary};
|
|
@@ -163,7 +163,7 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
163
163
|
background-color: ${e=>e.theme.colors.grey3};
|
|
164
164
|
min-height: 1px;
|
|
165
165
|
max-height: 1px;
|
|
166
|
-
`,
|
|
166
|
+
`,Ze=(e,o)=>`${e}.${o}`,Ee={paddingTop:new c(a[5],a[4]),marginBottom:new c(a[3],a[3]),labelPaddingLeft:new c(a[3],a[4]),buttonWidth:new c(70,70),containerRightMargin:new c(a[3],a[8]),containerLeftMargin:new c(a[3],a[6]),deleteConfirmationTextMarginBottom:new c(a[2],a[0])},G=me.getLocalizedStrings().spendManagement.reimbursement.reimbursementDetail,aa=({lineData:e,currencyConversionState:o,recommendationFetchState:r,remiStage:d,lineIndex:p,accountList:C,classList:m,merchantList:S,hasFile:b,defaultCurrency:l,hasMultipleLineItems:k,fileRequiredLineIds:f,duplicateLineDetails:s,remiStatus:g,sectionId:w,isDisabled:P,isReimbursementCommentingEnabled:D,isAddReimbursementDisabled:v,style:K,autoFields:L=[],analytics:I,reimbursementId:E,tentativeMerchantName:te,companyMileageConfigInfo:pe,uncategorizedAccounts:A,removeDuplicateReimbursementForLine:_,scrollToSection:Y,onDuplicateLineClick:H,onRemoveReimbursement:ie,clearTentativeNameForLine:Q,allCurrencies:we,accountsHierarchyList:he,classHierarchyList:re})=>{const J=Ie(),le=ft(),Oe=zt(),R=me.getLocalizedStrings().common.strings.empty,ge={application:"dashboard",companyId:le.currentTenant?.companyId,tab:"reimbursement",entityId:E},se=`dashboard_${le.currentTenant?.companyId}`,{getValues:Ne}=ct(),[Le,Ae]=$.useState(!1),Se=Ne(Ze(w,"reimbursementType"));return t.jsxs(ma,{style:K,windowSize:J,children:[t.jsxs(la,{hasFile:b,windowSize:J,showDeleteConfirmation:Le,children:[t.jsx(ha,{windowSize:J,children:k?`#${p+1} ${G.reimbursement}`:G.reimbursement}),Le?t.jsxs(ua,{windowSize:J,children:[t.jsx(da,{windowSize:J,children:G.deleteConfirmation}),t.jsxs(ra,{children:[t.jsx(Ti,{label:G.buttons.cancel,onClick:()=>Ae(!1),style:{width:Ee.buttonWidth.value(J),marginLeft:J==="small"?i.sp0:i.sp4,marginRight:i.sp3},size:"small",variant:"secondary","data-testid":q("delete-remi-button",G.buttons.cancel)}),t.jsx(Ti,{label:G.buttons.remove,onClick:()=>{I?.trackReimbursementDeleteReimbursementLine(e.lineId,E),Q?.(e.lineId??"1"),Ae(!1),_(e.lineId),ie(p)},style:{width:Ee.buttonWidth.value(J)},size:"small",variant:"danger","data-testid":q("delete-remi-button",G.buttons.remove)})]})]}):k&&(d==="draft"||g==="rejected")?t.jsx(sa,{className:"deleteIconWrapper",windowSize:J,onClick:()=>Ae(!0),"data-testid":q("delete-remi-button",e.lineId),children:t.jsx(yn,{enterDelay:600,title:G.deleteReimbursement,placement:"top-end",children:t.jsx(ca,{})})}):null]}),f.includes(e.lineId)?t.jsx(rn,{title:G.missingReceipt,description:G.missingReceiptDescription,style:{marginBottom:i.sp3}}):null,t.jsxs(ga,{windowSize:J,children:[s?.duplicateLineId!=null?t.jsxs(pa,{children:[G.thisExpense," ",s.isDuplicateWithinTransaction?t.jsx(zi,{"data-testid":q("view-duplicate-transaction-expense"),onClick:()=>(I?.trackReimbursementViewDuplicateExpense(!0,E),Y(s.duplicateLineId)),children:G.viewOriginalExpense}):t.jsx(zi,{"data-testid":q("view-duplicate-expense"),onClick:()=>{s.duplicateTransactionId!=null&&s.duplicateLineId!=null&&(I?.trackReimbursementViewDuplicateExpense(!1,E),H(s.duplicateTransactionId,s.duplicateLineId))},children:G.viewOriginalExpense})]}):null,t.jsx(fe,{isThreadAllowed:D&&E!=null,dashboardTabKey:xe({type:"details",key:Se===G.mileageKey?`${p}.mileage.reimbursementType`:`${p}.out_of_pocket.reimbursementType`}),roomId:se,companyId:le.currentTenant?.companyId??R,companyName:le.currentTenant?.companyName??R,entityId:E,dashboardOptionType:"reimbursement",filterMetaData:{...ge,entityType:`reimbursement.details.${$e("reimbursementType",p,Se===G.mileageKey?"mileage":"out_of_pocket")}`},fieldThreadTargetElement:Oe?.sharedRef?.contentWrapperRef,style:{borderRadius:s?.duplicateLineId!=null?"0 0 0 0":`${i.sp2} ${i.sp2} 0 0`},children:t.jsxs(ba,{isDisabled:P!=null,haveBorderRadius:s?.duplicateLineId==null,children:[t.jsx(ji,{isDisabled:P!=null||v?"disabled":void 0,isContainerClickable:!0,label:{label:G.outOfPocket},style:{padding:`${i.sp3} ${i.sp0}`,paddingLeft:Ee.labelPaddingLeft.value(J),borderTopLeftRadius:"inherit"},showOutline:!(D&&E!=null),radioField:{name:Ze(w,"reimbursementType"),id:`${Ze(w,"reimbursementType")}.${G.outOfPocketKey}`,value:G.outOfPocketKey}}),t.jsx(ya,{}),t.jsx(ji,{isDisabled:P!=null||v?"disabled":void 0,isContainerClickable:!0,label:{label:G.mileage},style:{padding:`${i.sp3} ${i.sp0}`,paddingLeft:Ee.labelPaddingLeft.value(J),borderTopRightRadius:"inherit"},showOutline:!(D&&E!=null),radioField:{name:Ze(w,"reimbursementType"),id:`${Ze(w,"reimbursementType")}.${G.mileageKey}`,value:G.mileageKey}})]})}),t.jsx(fa,{}),Se===G.outOfPocketKey?t.jsx(oa,{lineIndex:p,reimbursementId:E,uncategorizedAccounts:A,isReimbursementCommentingEnabled:D,isDisabled:P,outOfPocket:{transactionDate:e.outOfPocket.transactionDate!=null?ee.zeniDate(e.outOfPocket.transactionDate.toDateString()):void 0,account:e.outOfPocket.account.selectedOption,isConvertedCurrencyLoading:o?.fetchState==="In-Progress",isRecommendationLoading:r==="In-Progress",homeCurrencyDetails:e.homeCurrencyConversions,class:e.outOfPocket.class.selectedOption,amount:{amount:e.outOfPocket.amount?.amount??0,currencyCode:e.outOfPocket.amount?.currencyCode??"USD",currencySymbol:e.outOfPocket.amount?.currencySymbol??"$"},memo:e.outOfPocket.memo,merchant:e.outOfPocket.merchant.selectedOption,recommendations:e.outOfPocket.recommendations,recommendedAccount:e.outOfPocket.recommendedAccount,isCategoryUpdateSelected:e.outOfPocket.isCategoryUpdateSelected,isCategoryFirstTimeAutofilled:e.outOfPocket.isCategoryFirstTimeAutofilled,retainedAccount:e.outOfPocket.retainedAccount,isRetainedCategorySelected:e.outOfPocket.isRetainedCategorySelected},sectionId:Ze(w,"outOfPocket"),accountList:C,classList:m,autoFields:L,merchantList:S,tentativeMerchantName:te,allCurrencies:we,isAddReimbursementDisabled:v,accountsHierarchyList:he,classHierarchyList:re}):t.jsx(Wo,{lineIndex:p,reimbursementId:E,isReimbursementCommentingEnabled:D,isDisabled:P,mileage:{transactionDate:e.mileage.transactionDate!=null?ee.zeniDate(e.mileage.transactionDate.toDateString()):void 0,class:e.mileage.class.selectedOption,distanceInMiles:e.mileage.distanceInMiles,amount:{amount:e.mileage.amount?.amount??0,currencyCode:e.mileage.amount?.currencyCode??"USD",currencySymbol:e.mileage.amount?.currencySymbol??"$"},memo:e.mileage.memo},classList:m,sectionId:Ze(w,"mileage"),companyMileageConfigInfo:pe,defaultCurrency:l,isAddReimbursementDisabled:v,classHierarchyList:re})]})]})},ra=n.div``,la=n.div`
|
|
167
167
|
//when file is present and it's a small window, we don't have to show the title and delete icon. Delete icon will be displayed inside the invoice title, next to replace
|
|
168
168
|
//https://www.figma.com/file/ERKhHKvXKZSfIUruWfHqwU/New-Reimbursement-Mobile-Ver-1.0?type=design&node-id=419%3A6356&mode=design&t=upxphJ6HQRaue6wK-1
|
|
169
169
|
display: ${e=>e.hasFile&&e.windowSize==="small"?"none":"flex"};
|
|
@@ -182,7 +182,7 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
182
182
|
`,zi=n.span`
|
|
183
183
|
border-bottom: 1px solid currentColor;
|
|
184
184
|
cursor: pointer;
|
|
185
|
-
`,ca=n(
|
|
185
|
+
`,ca=n($o)`
|
|
186
186
|
width: ${i.sp3};
|
|
187
187
|
height: ${i.sp3};
|
|
188
188
|
cursor: pointer;
|
|
@@ -241,7 +241,7 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
241
241
|
background-color: ${e=>e.theme.colors.grey3};
|
|
242
242
|
min-height: 1px;
|
|
243
243
|
max-height: 1px;
|
|
244
|
-
`,xa=(e,o)=>`${e}.${o}`,lt={labelWidth:new c(120,160,160),paddingBottom:new c(a[3],a[3]),paddingTop:new c(12,a[3]),marginBottom:new c(12,a[3]),containerRightMargin:new c(a[3],a[8]),containerLeftMargin:new c(a[3],a[6])}
|
|
244
|
+
`,xa=(e,o)=>`${e}.${o}`,lt={labelWidth:new c(120,160,160),paddingBottom:new c(a[3],a[3]),paddingTop:new c(12,a[3]),marginBottom:new c(12,a[3]),containerRightMargin:new c(a[3],a[8]),containerLeftMargin:new c(a[3],a[6])},vn=({isReimbursementCommentingEnabled:e,sectionId:o,isDisabled:r,reportTitle:d,reimbursementId:p,style:C})=>{const m=Ie(),S=ft(),b=zt(),l=`dashboard_${S.currentTenant?.companyId}`,k=me.getLocalizedStrings(),f=k.spendManagement.reimbursement.reimbursementDetail,s=k.common.strings.empty,g=lt.labelWidth.value(m);return t.jsxs(wa,{style:C,windowSize:m,children:[t.jsx(va,{windowSize:m,children:f.whatFor}),t.jsx(Sa,{children:t.jsx(fe,{isThreadAllowed:e&&p!=null,dashboardTabKey:xe({type:"details",key:"whatFor"}),roomId:l,companyId:S.currentTenant?.companyId??s,companyName:S.currentTenant?.companyName??s,entityId:p,dashboardOptionType:"reimbursement",filterMetaData:{application:"dashboard",companyId:S.currentTenant?.companyId,tab:"reimbursement",entityId:p,entityType:"reimbursement.details.whatFor"},fieldThreadTargetElement:b?.sharedRef?.contentWrapperRef,style:{borderRadius:i.sp2},children:t.jsx(ui,{isDisabled:r,label:{label:f.reportTitle,width:g},text:{type:"text",name:xa(o,"reportTitle"),placeholder:f.lunchWithClient,defaultValue:d,autoComplete:"off",options:{required:!0,validate:w=>!!w}},style:{width:"auto",borderRadius:i.sp2}})})})]})},wa=n.div`
|
|
245
245
|
display: flex;
|
|
246
246
|
flex-direction: column;
|
|
247
247
|
padding-top: ${e=>lt.paddingTop.valuePx(e.windowSize)};
|
|
@@ -255,20 +255,20 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
255
255
|
border: 1px solid ${e=>e.theme.colors.grey3};
|
|
256
256
|
box-shadow: ${e=>`${i.sp0} 2px ${i.sp1} ${e.theme.colors.dropShadowNormal}`};
|
|
257
257
|
border-radius: ${i.sp2};
|
|
258
|
-
|
|
258
|
+
`,va=n(Bt)`
|
|
259
259
|
color: ${e=>e.theme.colors.primary};
|
|
260
260
|
margin-bottom: ${e=>lt.marginBottom.valuePx(e.windowSize)};
|
|
261
|
-
`,M={largeLabelWidth:new c(120,120,220),marginTop:new c(28,8),paymentToMarginTop:new c(0,a[4]),marginBottom:new c(a[5],a[4]),paymentToMarginBottom:new c(12,a[3]),totalMarginBottom:new c(a[3],a[3]),reimbursementSectionLeftMargin:new c(a[3],a[6]),reimbursementSectionRightMargin:new c(a[3],a[8]),invoiceSectionLeftMargin:new c(a[3],a[8]),invoiceSectionRightMargin:new c(a[3],a[6]),rightSectionWidth:new c(100,58),firstOrLastItemHeight:new c(390,760),itemHeight:new c(390,459),duplicateBannerWrapperMarginTop:new c(a[5],a[3]),duplicateBannerWrapperMarginRight:new c(a[3],a[8]),duplicateBannerWrapperMarginBottom:new c(a[5],a[3]),duplicateBannerWrapperMarginLeft:new c(a[3],a[6])}
|
|
261
|
+
`,M={largeLabelWidth:new c(120,120,220),marginTop:new c(28,8),paymentToMarginTop:new c(0,a[4]),marginBottom:new c(a[5],a[4]),paymentToMarginBottom:new c(12,a[3]),totalMarginBottom:new c(a[3],a[3]),reimbursementSectionLeftMargin:new c(a[3],a[6]),reimbursementSectionRightMargin:new c(a[3],a[8]),invoiceSectionLeftMargin:new c(a[3],a[8]),invoiceSectionRightMargin:new c(a[3],a[6]),rightSectionWidth:new c(100,58),firstOrLastItemHeight:new c(390,760),itemHeight:new c(390,459),duplicateBannerWrapperMarginTop:new c(a[5],a[3]),duplicateBannerWrapperMarginRight:new c(a[3],a[8]),duplicateBannerWrapperMarginBottom:new c(a[5],a[3]),duplicateBannerWrapperMarginLeft:new c(a[3],a[6])},$a={total:new pi("largeMedium","h6Medium")},{spendManagement:{reimbursement:{reimbursementDetail:V},billPay:{vendorCreation:{achDetails:It}}},common:{currency:{currencyCode:Dt}}}=me.getLocalizedStrings(),$n=e=>{let o=0,r=Dt;if("recommendationFetchState"in e&&e.recommendationFetchState!=null){const d=e;o=d.outOfPocket.amount??0,r=d.outOfPocket.currencyCode??Dt}else{const d=e;o=d.outOfPocket.amount?.amount??0,r=d.outOfPocket.amount?.currencyCode??Dt}return(e.homeCurrencyConversions?.currencyCode??Dt)!==r&&(o=e.homeCurrencyConversions?.amount??0),o},Ca=({remiUploadStatus:e,progressSectionObj:o,reimbursementId:r,createDate:d,scheduleDate:p,paymentDate:C,hasDuplicateLine:m,approvedDate:S,isFirstOrLastListItem:b,index:l,reimbursementSectionRef:k,showSkipAutoFill:f,lineData:s,currencyConversionState:g,authParams:w,uploadInvoiceEndPoint:P,accountList:D,classList:v,merchantList:K,remiStage:L,autoFieldsByLineId:I,isReimbursementCommentingEnabled:E,isAutoFieldsExist:te,totalAmount:pe,showTotalAmountLoader:A,totalNumberOfLines:_,defaultCurrency:Y,bankAccounts:H,fileRequiredLineIds:ie,isAddReimbursementDisabled:Q,duplicateLineByLineId:we,remiStatus:he,file:re,uncategorizedAccounts:J,reportTitle:le,recommendationFetchState:Oe,tentativeMerchantName:R,paymentTo:ge,analytics:se,companyMileageConfigInfo:Ne,loggedInUserDepartmentId:Le,isSignedInUserReimbursementCreator:Ae,setShowBankAccountPage:Se,setRefByLineId:ze,setCurrentLineIdForUpload:ye,onDuplicateLineClick:De,setUploadedReceiptPayload:dt,removeDuplicateReimbursementForLine:W,onReceiptsUpload:et,scrollToSection:tt,onRemoveReimbursement:We,onAddReimbursement:ke,clearTentativeNameForLine:He,onReplaceClick:Te,onDeleteBankAccount:Ue,updateInvoiceUploadFetchState:Ve,removeFileFromLine:qe,allCurrencies:Ke,accountsHierarchyList:ne,classHierarchyList:it})=>{const{formState:{errors:ut}}=ct(),Ge=$.useRef(null);$.useEffect(()=>(ze(z=>({...z,[`L${s.lineId}`]:Ge.current})),()=>{ze(z=>({...z,[`L${s.lineId}`]:null}))}),[s.lineId,ze]);const U=Ie(),mt=L==="draft"?V.newReimbursementTitle:V.editReimbursementTitle,F=M.largeLabelWidth.value(U),ae=z=>z.outOfPocket.account.selectedOption==null&&(z.outOfPocket.amount==null||z.outOfPocket.amount.amount==0)&&(z.outOfPocket.class.selectedOption==null||z.outOfPocket.class.selectedOption===Le)&&(z.outOfPocket.memo===""||z.outOfPocket.memo==null)&&z.outOfPocket.merchant.selectedOption==null&&z.outOfPocket.transactionDate==null,wt=H.map(z=>z.bankAccountId),ve=s.reimbursementType===V.outOfPocketKey&&$n(s)>=75&&re==null;return t.jsxs(Va,{ref:k,windowSize:U,children:[t.jsx(_a,{ref:z=>{z!=null&&(Ge.current=z)},windowSize:U,bottomSeperator:_!==1,showSkipAutoFill:f,isFirstItem:l===0,children:t.jsx(xn,{customError:ve?V.requireReceipt:void 0,analytics:se,showAutofill:!1,uploadInvoiceEndPoint:P,authParams:w,entityId:Q?"":void 0,file:re,style:{width:"auto",padding:0,height:b?M.firstOrLastItemHeight.valuePx(U):M.itemHeight.valuePx(U),margin:U==="small"?i.sp0:void 0},updateInvoiceUploadFetchState:Ve,onInvoiceUpload:z=>{s.reimbursementType===V.outOfPocketKey&&!ae(s)?(ye(Number(s.lineId)),dt(z),Te?.()):et(z,Number(s.lineId),!0)},dropFilePlaceholder:{upload:V.dropReceipt.upload,receipt:V.dropReceipt.receipt},showInfoText:!1,showTitlebar:!0,showTitlebarIcon:!Q,pdfTitle:_>1?`#${l+1} Receipt`:"Receipt",onDeleteClick:()=>{Ve?.("In-Progress"),setTimeout(()=>qe?.(Number(s.lineId)))},onReplaceClick:()=>{ye(Number(s.lineId)),Te?.()},allowMultiFiles:_===l+1,type:"receipt"})}),t.jsxs(Ua,{windowSize:U,children:[l===0&&U!=="small"?t.jsxs(t.Fragment,{children:[t.jsx(La,{children:mt}),t.jsx(Ha,{children:t.jsx(fo,{progressSectionObj:o,createDate:d,paymentDate:C,scheduleDate:p,approvedDate:S,isBillUploaded:r!=null?!0:e==="Completed"})}),te&&t.jsxs(Da,{children:[t.jsx(ka,{}),t.jsx(Oa,{children:V.banner})]}),m&&t.jsxs(Ta,{size:U,children:[t.jsx(Ia,{}),t.jsxs(Pa,{children:[t.jsx(ja,{children:V.thereSeems}),t.jsx(Ra,{children:V.pleaseFind})]})]}),t.jsx(vn,{isReimbursementCommentingEnabled:E,sectionId:Lt,reportTitle:le,reimbursementId:r})]}):null,t.jsx(aa,{analytics:se,reimbursementId:r,onDuplicateLineClick:De,uncategorizedAccounts:J,sectionId:`${gi}.${l}`,scrollToSection:tt,lineIndex:l,lineData:s,accountList:D,classList:v,merchantList:K,autoFields:s.lineId!=null?I[s.lineId]:[],currencyConversionState:g,recommendationFetchState:Oe,onRemoveReimbursement:We,hasMultipleLineItems:_>1,clearTentativeNameForLine:He,tentativeMerchantName:R,hasFile:re!=null,companyMileageConfigInfo:Ne,defaultCurrency:Y,remiStage:L,remiStatus:he,fileRequiredLineIds:ie,allCurrencies:Ke,isReimbursementCommentingEnabled:E,isAddReimbursementDisabled:Q,accountsHierarchyList:ne,classHierarchyList:it,duplicateLineDetails:we[s.lineId],removeDuplicateReimbursementForLine:W}),_!==1&&_===l+1&&t.jsxs(t.Fragment,{children:[t.jsxs(za,{windowSize:U,children:[t.jsx(Ba,{children:V.total}),A?t.jsx(Ma,{windowSize:U,children:t.jsx(Fa,{children:t.jsx(xt,{size:"Standard",start:!0,style:{display:"flex"}})})}):t.jsx(dn,{amount:ee.toAmount(pe,"USD","$"),integerStyles:Rt.h6Regular.cssObject,decimalStyles:Rt.standardRegular.cssObject})]}),t.jsxs(Na,{windowSize:U,onClick:()=>{Q===!1&&ke()},isDisabled:Q,"data-testid":q("add-reimbursement-row"),children:[t.jsx(Mi,{}),t.jsx(Bi,{children:V.addReimbursement})]}),Ae?t.jsxs(t.Fragment,{children:[t.jsx(Aa,{windowSize:U,children:V.receivePaymentTo}),t.jsx(Ea,{windowSize:U,shouldDisplay:H.length>0,children:t.jsx(un,{label:{label:V.yourBankAccount,width:F},style:{width:"auto"},singleSelectField:{singleSelect:{name:yt,placeholder:Qe(V.yourBankAccount),showValueEyeIcon:!Q,menuPlacement:"top",maxMenuHeight:308,showEyeIconOnSelect:!1,onDelete:Ue,getTooltipInfo:z=>Cn(H,z),onClickCreateBankAccount:()=>Se(!0),getLabelForId:z=>In(H,z),isOptionRemovable:!1,showDeleteIcon:!0,showAddBankAccountOption:!0,isDisabled:Q?"readonly":void 0,showTickMark:!1,alwaysShowEyeTooltip:!0},defaultValue:{selectedOption:ge,allOptions:wt},registerOptions:{required:!0,validate:z=>!!z.selectedOption}},isFunctional:!0})}),t.jsxs(Wa,{shouldDisplay:H.length===0,windowSize:U,hasError:st(ut,yt),onClick:()=>{Q===!1&&Se(!0)},isDisabled:Q,"data-testid":q("remi-add-bank-account-container"),children:[t.jsx(Mi,{}),t.jsx(Bi,{children:V.addBankAccount})]})]}):null]})]})]})},Cn=(e,o)=>{const r=kn(e,o);return r==null?`${It.bankRoutingNumber} ${V.emptyValue}
|
|
262
262
|
${It.bankAccountNumber} ${V.emptyValue}`:`${It.bankRoutingNumber} ${r.bankRoutingNumberAch??V.emptyValue}, ${r.bankName??V.emptyValue}
|
|
263
263
|
${It.bankAccountNumber} ${r.bankAccountNumber??V.emptyValue}`},kn=(e,o)=>e.find(r=>r.bankAccountId===o),In=(e,o)=>{const r=kn(e,o);return r==null?V.selectBankAccount:r.bankAccountName?r.bankAccountName:r.maskedAccountNumber?r.maskedAccountNumber:r.bankName&&r.bankAccountNumber?`${r.bankName} ${V.accountNameConnector}${r.bankAccountNumber.slice(r.bankAccountNumber.length-4)}`:V.selectBankAccount},ka=n(di)`
|
|
264
264
|
color: ${e=>e.theme.colors.primary};
|
|
265
265
|
width: ${i.sp3};
|
|
266
266
|
height: ${i.sp3};
|
|
267
|
-
`,Ia=n(
|
|
267
|
+
`,Ia=n(vo)`
|
|
268
268
|
width: ${i.sp4};
|
|
269
269
|
height: ${i.sp4};
|
|
270
270
|
color: ${j.brandColorGoldDark};
|
|
271
|
-
`,
|
|
271
|
+
`,Da=n.div`
|
|
272
272
|
display: flex;
|
|
273
273
|
gap: ${i.sp2};
|
|
274
274
|
border: 1px solid ${e=>e.theme.colors.grey3};
|
|
@@ -276,7 +276,7 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
276
276
|
border-radius: ${i.sp2};
|
|
277
277
|
align-items: center;
|
|
278
278
|
margin: 0 ${i.sp8} 0 ${i.sp6};
|
|
279
|
-
`,
|
|
279
|
+
`,Ta=n.div`
|
|
280
280
|
display: flex;
|
|
281
281
|
gap: ${i.sp2};
|
|
282
282
|
padding: ${i.sp3};
|
|
@@ -330,7 +330,7 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
330
330
|
width: calc(100% - 176px);
|
|
331
331
|
justify-content: flex-end;
|
|
332
332
|
color: ${e=>e.theme.colors.primary};
|
|
333
|
-
${e=>`${
|
|
333
|
+
${e=>`${$a.total.style(e.windowSize)}`};
|
|
334
334
|
`,Fa=n.div`
|
|
335
335
|
padding-right: ${i.sp3};
|
|
336
336
|
height: 30px;
|
|
@@ -407,10 +407,10 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
407
407
|
margin-top: ${e=>M.marginTop.valuePx(e.windowSize)};
|
|
408
408
|
`,Ha=n.div`
|
|
409
409
|
padding: ${i.sp2} ${i.sp8} ${i.sp0} ${i.sp6};
|
|
410
|
-
`,
|
|
411
|
-
margin-left: ${e=>
|
|
412
|
-
margin-right: ${e=>
|
|
413
|
-
margin-bottom: ${e=>
|
|
410
|
+
`,qa={total:new pi("largeMedium","h6Medium")},Z={largeLabelWidth:new c(120,120,220),marginBottom:new c(a[5],a[4]),addBankAccountMarginBottom:new c(a[5],a[5]),marginTop:new c(a[0],78),paymentToMarginTop:new c(0,a[4]),totalMarginBottom:new c(a[3],a[3]),rightMargin:new c(a[3],a[8]),leftMargin:new c(a[3],a[6]),paymentToMarginBottom:new c(12,a[3])},Xe=me.getLocalizedStrings().spendManagement.reimbursement.reimbursementDetail,Ka=({remiDetails:e,isUserAdmin:o,authParams:r,uploadInvoiceEndPoint:d,showSkipAutoFill:p,isReimbursementCommentingEnabled:C,isAutoFieldsExist:m,totalAmount:S,defaultCurrency:b,hasDuplicateLine:l,bankAccounts:k,fileRequiredLineIds:f,companyMileageConfigInfo:s,analytics:g,reimbursementId:w,currencyConversionStatus:P,setShowSkipAutoFill:D,setShowBankAccountPage:v,removeDuplicateReimbursementForLine:K,onReceiptsUpload:L,setCurrentLineIdForUpload:I,onDuplicateLineClick:E,setUploadedReceiptPayload:te,removeFileFromLine:pe,onReplaceClick:A,updateInvoiceUploadFetchState:_,clearTentativeNameForLine:Y,onDeleteBankAccount:H,uncategorizedAccounts:ie,isSignedInUserReimbursementCreator:Q,duplicateLineByLineId:we,showTotalAmountLoader:he,scrollContainerRef:re})=>{const{control:J,formState:{errors:le}}=ct(),{fields:Oe,append:R,remove:ge}=uo({name:gi,control:J}),se=Oe,Ne=$.useRef(null),Le=F=>{setTimeout(()=>{ge(F)})},{tentativeMerchantNameByLineId:Ae,remiStage:Se,remiStatus:ze}=e,ye=!Q||Se==="pending_approval"&&ze!=="rejected"&&o||Se==="pending_approval"&&ze==="rejected",De=ye?e.paymentToBankAccountDetail!=null?[e.paymentToBankAccountDetail]:[]:k,dt=De.map(F=>F.bankAccountId),W=Ie(),et=Z.largeLabelWidth.value(W),tt=e.whatForSection.reportTitle,We=e.accountList.accounts,ke=e.accountsHierarchyList,He=e.classHierarchyList,Te=e.classList.classes,Ue=e.merchantList.merchants,Ve=e.addRemiAutoFieldsByLineId,qe=Math.max(...Object.keys(e.editRemiInitialDetails?.lineDetailSection??{}).map(F=>Number(F)),0),Ke=()=>{const F=se[se.length-1],ae=Dn(se.length,Number(F.lineId)>qe?String(Number(F.lineId)+1):String(qe+1),ke,He,Ue,b,e.allCurrencies,e.loggedInUserDepartmentId);setTimeout(()=>{R(ae,{shouldFocus:!1})}),I(Number(ae.lineId)),D(!0),setTimeout(()=>Ri(Ne.current,re?.current),50)},[ne,it]=$.useState({}),ut=$.useCallback(F=>{const ae=ne[`L${F}`];ae!=null&&Ri(ae,re?.current)},[ne,re]),Ge=e.reimbursementInfo?.billStatus.code=="approved"&&e.reimbursementInfo?.billPaymentStatus.code?e.reimbursementInfo?.billPaymentStatus:e.reimbursementInfo?.billStatus,U=e.reimbursementInfo?.paymentDate!=null?ee.zeniDate(ee.getNextNthWorkingDay(e.reimbursementInfo.paymentDate.toDate(),[0,6],e.achSameDayMaxDays).toDateString()):void 0,mt=e.reimbursementInfo?.expectedDepositDate??U;return t.jsxs(Za,{windowSize:W,showSkipAutoFill:p,children:[se.map((F,ae)=>t.jsx(Ca,{removeDuplicateReimbursementForLine:K,onDuplicateLineClick:E,scrollToSection:ut,setRefByLineId:it,duplicateLineByLineId:we,reimbursementId:w,remiUploadStatus:e.uploadStatus,uncategorizedAccounts:ie,progressSectionObj:Ge,createDate:e.createTime,paymentDate:mt,scheduleDate:e.reimbursementInfo?.paymentDate,approvedDate:e.latestApprovedDate,isFirstOrLastListItem:se.length-1===ae||ae===0,index:ae,reimbursementSectionRef:Ne,remiStage:Se,remiStatus:ze,authParams:r,file:F.file,uploadInvoiceEndPoint:d,showSkipAutoFill:p,lineData:F,currencyConversionState:P[F.lineId],recommendationFetchState:e.lineDetailSection[F.lineId]?.recommendationFetchState,setCurrentLineIdForUpload:I,setUploadedReceiptPayload:te,onReplaceClick:A,onReceiptsUpload:L,removeFileFromLine:pe,isReimbursementCommentingEnabled:C,isAutoFieldsExist:m,reportTitle:tt,accountList:We,classList:Te,merchantList:Ue,autoFieldsByLineId:Ve,onRemoveReimbursement:Le,onAddReimbursement:Ke,totalAmount:S,showTotalAmountLoader:he,hasDuplicateLine:l,totalNumberOfLines:se.length,updateInvoiceUploadFetchState:_,clearTentativeNameForLine:Y,tentativeMerchantName:Ae[F.lineId],companyMileageConfigInfo:s,defaultCurrency:b,setShowBankAccountPage:v,paymentTo:e.paymentTo,bankAccounts:De,onDeleteBankAccount:H,analytics:g,fileRequiredLineIds:f,allCurrencies:e.allCurrencies,loggedInUserDepartmentId:e.loggedInUserDepartmentId,isAddReimbursementDisabled:ye,accountsHierarchyList:ke,classHierarchyList:He,isSignedInUserReimbursementCreator:Q},F.lineId)),se.length===1&&t.jsxs(t.Fragment,{children:[t.jsxs(Jt,{children:[W!=="small"?t.jsx(Gt,{windowSize:W}):null,t.jsx(Yt,{windowSize:W,children:t.jsxs(Xa,{windowSize:W,children:[t.jsx(Qa,{children:Xe.total}),he?t.jsx(tr,{windowSize:W,children:t.jsx(ir,{children:t.jsx(xt,{size:"Standard",start:!0,style:{display:"flex"}})})}):t.jsx(dn,{amount:ee.toAmount(S,ee.defaultVendorCurrency.currencyCode,ee.defaultVendorCurrency.currencySymbol),integerStyles:Rt.h6Regular.cssObject,decimalStyles:Rt.standardRegular.cssObject})]})})]}),t.jsxs(Jt,{children:[W!=="small"?t.jsx(Gt,{windowSize:W}):null,t.jsx(Yt,{windowSize:W,children:t.jsxs(nr,{windowSize:W,onClick:()=>{ye===!1&&Ke()},isDisabled:ye,"data-testid":q("add-reimbursement-container"),children:[t.jsx(Ei,{}),t.jsx(Fi,{children:Xe.addReimbursement})]})})]}),t.jsxs(Jt,{children:[W!=="small"?t.jsx(Gt,{windowSize:W}):null,Q?t.jsxs(Yt,{windowSize:W,children:[t.jsx(er,{windowSize:W,children:Xe.receivePaymentTo}),t.jsx(Ja,{windowSize:W,shouldDisplay:De.length>0,children:t.jsx(un,{label:{label:Xe.yourBankAccount,width:et},style:{width:"auto"},singleSelectField:{singleSelect:{name:yt,placeholder:Qe(Xe.yourBankAccount),showValueEyeIcon:!ye,menuPlacement:"top",maxMenuHeight:308,showEyeIconOnSelect:!1,onDelete:H,getTooltipInfo:F=>Cn(De,F),onClickCreateBankAccount:()=>v(!0),getLabelForId:F=>In(De,F),isOptionRemovable:!1,showDeleteIcon:!0,showAddBankAccountOption:!0,isDisabled:ye?"readonly":void 0,showTickMark:!1,alwaysShowEyeTooltip:!0},defaultValue:{selectedOption:e.paymentTo,allOptions:dt},registerOptions:{required:!0,validate:F=>!!F.selectedOption}},isFunctional:!0})}),t.jsxs(or,{shouldDisplay:De.length===0,windowSize:W,onClick:()=>{ye===!1&&v(!0)},hasError:st(le,yt),isDisabled:ye,"data-testid":q("remi-add-bank-account-container"),children:[t.jsx(Ei,{}),t.jsx(Fi,{children:Xe.addBankAccount})]})]}):null]})]})]})},Dn=(e,o,r,d,p,C,m,S)=>{const b=Ga(r,d,p,C,m,S);return{lineIndex:e,lineId:o,reimbursementType:Xe.outOfPocketKey,file:void 0,outOfPocket:b,mileage:Ya(d,C,S)}},Ga=(e,o,r,d,p,C)=>({transactionDate:void 0,class:{allOptions:_e(o,[]),selectedOption:C},account:{allOptions:At(e,[]),selectedOption:void 0},amount:{amount:0,currencyCode:d.currencyCode,currencySymbol:d.currencySymbol,currency:{allOptions:p.map(m=>({label:`${m.currencyCode} - ${m.currency}`,value:m.currencyCode,countryCode:si(m.countryCode)})),selectedOption:d.currencyCode??me.getLocalizedStrings().common.currency.currencyCode}},memo:void 0,merchant:{allOptions:r.map(m=>m.id).filter(m=>!!m),selectedOption:void 0},recommendations:[],isCategoryUpdateSelected:!1,isCategoryFirstTimeAutofilled:!1,isRetainedCategorySelected:!1}),Ya=(e,o,r)=>({transactionDate:void 0,class:{allOptions:_e(e,[]),selectedOption:r},distanceInMiles:void 0,amount:{amount:0,currencyCode:o.currencyCode,currencySymbol:o.currencySymbol},memo:void 0}),Ja=n.div`
|
|
411
|
+
margin-left: ${e=>Z.leftMargin.valuePx(e.windowSize)};
|
|
412
|
+
margin-right: ${e=>Z.rightMargin.valuePx(e.windowSize)};
|
|
413
|
+
margin-bottom: ${e=>Z.addBankAccountMarginBottom.valuePx(e.windowSize)};
|
|
414
414
|
border: 1px solid ${e=>e.theme.colors.grey3};
|
|
415
415
|
border-radius: ${i.sp2};
|
|
416
416
|
box-shadow: ${e=>`${i.sp0} 2px ${i.sp1} ${e.theme.colors.dropShadowNormal}`};
|
|
@@ -419,11 +419,11 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
419
419
|
width: ${e=>e.windowSize==="small"?"100%":"42%"};
|
|
420
420
|
`,Yt=n.div`
|
|
421
421
|
width: ${e=>e.windowSize==="small"?"100%":"58%"};
|
|
422
|
-
`,
|
|
422
|
+
`,Za=n.div`
|
|
423
423
|
display: ${e=>e.windowSize==="small"&&e.showSkipAutoFill?"none":"flex"};
|
|
424
424
|
flex-direction: column;
|
|
425
|
-
margin-top: ${e=>
|
|
426
|
-
`,
|
|
425
|
+
margin-top: ${e=>Z.marginTop.valuePx(e.windowSize)};
|
|
426
|
+
`,Xa=n.div`
|
|
427
427
|
padding: ${i.sp3};
|
|
428
428
|
display: flex;
|
|
429
429
|
align-items: center;
|
|
@@ -432,26 +432,26 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
432
432
|
border: 1px solid ${e=>e.theme.colors.grey3};
|
|
433
433
|
border-radius: ${i.sp2};
|
|
434
434
|
color: ${e=>e.theme.colors.hero};
|
|
435
|
-
margin-top: ${e=>
|
|
436
|
-
margin-left: ${e=>
|
|
437
|
-
margin-right: ${e=>
|
|
438
|
-
margin-bottom: ${e=>
|
|
439
|
-
`,
|
|
435
|
+
margin-top: ${e=>Z.totalMarginBottom.valuePx(e.windowSize)};
|
|
436
|
+
margin-left: ${e=>Z.leftMargin.valuePx(e.windowSize)};
|
|
437
|
+
margin-right: ${e=>Z.rightMargin.valuePx(e.windowSize)};
|
|
438
|
+
margin-bottom: ${e=>Z.totalMarginBottom.valuePx(e.windowSize)};
|
|
439
|
+
`,Qa=n(pn)`
|
|
440
440
|
display: flex;
|
|
441
441
|
width: 176px;
|
|
442
442
|
color: ${e=>e.theme.colors.primary};
|
|
443
443
|
`,er=n(Bt)`
|
|
444
444
|
color: ${e=>e.theme.colors.primary};
|
|
445
|
-
margin-top: ${e=>
|
|
446
|
-
margin-bottom: ${e=>
|
|
447
|
-
margin-left: ${e=>
|
|
448
|
-
margin-right: ${e=>
|
|
445
|
+
margin-top: ${e=>Z.paymentToMarginTop.valuePx(e.windowSize)};
|
|
446
|
+
margin-bottom: ${e=>Z.paymentToMarginBottom.valuePx(e.windowSize)};
|
|
447
|
+
margin-left: ${e=>Z.leftMargin.valuePx(e.windowSize)};
|
|
448
|
+
margin-right: ${e=>Z.rightMargin.valuePx(e.windowSize)};
|
|
449
449
|
`,tr=n(hn)`
|
|
450
450
|
display: flex;
|
|
451
451
|
width: calc(100% - 176px);
|
|
452
452
|
justify-content: flex-end;
|
|
453
453
|
color: ${e=>e.theme.colors.primary};
|
|
454
|
-
${e=>`${
|
|
454
|
+
${e=>`${qa.total.style(e.windowSize)}`};
|
|
455
455
|
`,ir=n.div`
|
|
456
456
|
padding-right: ${i.sp3};
|
|
457
457
|
height: 30px;
|
|
@@ -473,10 +473,10 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
473
473
|
border: 1px solid
|
|
474
474
|
${e=>e.isDisabled?e.theme.colors.grey3:e.hasError===!0?j.important:e.theme.colors.primary};
|
|
475
475
|
}
|
|
476
|
-
margin-top: ${e=>
|
|
477
|
-
margin-left: ${e=>
|
|
478
|
-
margin-right: ${e=>
|
|
479
|
-
margin-bottom: ${e=>
|
|
476
|
+
margin-top: ${e=>Z.totalMarginBottom.valuePx(e.windowSize)};
|
|
477
|
+
margin-left: ${e=>Z.leftMargin.valuePx(e.windowSize)};
|
|
478
|
+
margin-right: ${e=>Z.rightMargin.valuePx(e.windowSize)};
|
|
479
|
+
margin-bottom: ${e=>Z.marginBottom.valuePx(e.windowSize)};
|
|
480
480
|
`,or=n.div`
|
|
481
481
|
padding: ${i.sp3};
|
|
482
482
|
display: ${e=>e.shouldDisplay?"flex":"none"};
|
|
@@ -492,9 +492,9 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
492
492
|
border: 1px solid
|
|
493
493
|
${e=>e.isDisabled?e.theme.colors.grey3:e.hasError===!0?j.important:e.theme.colors.primary};
|
|
494
494
|
}
|
|
495
|
-
margin-left: ${e=>
|
|
496
|
-
margin-right: ${e=>
|
|
497
|
-
margin-bottom: ${e=>
|
|
495
|
+
margin-left: ${e=>Z.leftMargin.valuePx(e.windowSize)};
|
|
496
|
+
margin-right: ${e=>Z.rightMargin.valuePx(e.windowSize)};
|
|
497
|
+
margin-bottom: ${e=>Z.addBankAccountMarginBottom.valuePx(e.windowSize)};
|
|
498
498
|
`,Fi=n(Mt)`
|
|
499
499
|
color: inherit;
|
|
500
500
|
`,Ei=n(gn)`
|
|
@@ -504,7 +504,7 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
504
504
|
`,Jt=n.div`
|
|
505
505
|
display: flex;
|
|
506
506
|
width: 100%;
|
|
507
|
-
`,Re={buttonWidth:new c(140,140),paddingLeft:new c(a[3],a[6]),paddingRight:new c(a[3],a[8]),subTitleMarginbottom:new c(a[2],a[3]),orSeperatorTopBottomMargin:new c(a[6],44),iconWidthHeight:new c(20,a[4])},Ni="userBankAccountPage",Pt="bankAccountSection",ar=e=>({[Pt]:{bankRoutingNumber:e?.bankRoutingNumber,bankName:e?.bankName,bankAccountNumber:e?.bankAccountNumber,confirmedBankAccountNumber:e?.confirmedBankAccountNumber,bankAccountName:e?.bankAccountName}}),Wi=e=>`${e}_form`,rr=({bankAccountCreationState:e,setShowBankAccountPage:o,plaidConnectionDetails:r,onFetchLinkTokenClick:d,onEstablishConnectionClick:p,bankAccountToCreate:C,fetchBankNameByRoutingStatus:m,isDisabled:S,onSaveHandler:b,onUserBankDetailsUpdated:l,onFetchBankName:k,onBackClick:f})=>{const s=bt(),g=Ie(),w=en({mode:"onBlur",reValidateMode:"onChange",defaultValues
|
|
507
|
+
`,Re={buttonWidth:new c(140,140),paddingLeft:new c(a[3],a[6]),paddingRight:new c(a[3],a[8]),subTitleMarginbottom:new c(a[2],a[3]),orSeperatorTopBottomMargin:new c(a[6],44),iconWidthHeight:new c(20,a[4])},Ni="userBankAccountPage",Pt="bankAccountSection",ar=e=>({[Pt]:{bankRoutingNumber:e?.bankRoutingNumber,bankName:e?.bankName,bankAccountNumber:e?.bankAccountNumber,confirmedBankAccountNumber:e?.confirmedBankAccountNumber,bankAccountName:e?.bankAccountName}}),Wi=e=>`${e}_form`,rr=({bankAccountCreationState:e,setShowBankAccountPage:o,plaidConnectionDetails:r,onFetchLinkTokenClick:d,onEstablishConnectionClick:p,bankAccountToCreate:C,fetchBankNameByRoutingStatus:m,isDisabled:S,onSaveHandler:b,onUserBankDetailsUpdated:l,onFetchBankName:k,onBackClick:f})=>{const s=bt(),g=Ie(),w=en({mode:"onBlur",reValidateMode:"onChange",defaultValues:$.useMemo(()=>ar(C),[C])}),P=$.useCallback(Y=>{p?.(Y),f()},[f,p]),D=r.link_account_no_microdeposit,{open:v}=po({token:D.linkToken??null,onSuccess:P});$.useEffect(()=>{(ee.zeniDate(new Date().toISOString()).isAfter(D.expiration)||D.linkToken==null)&&d?.("link_account_no_microdeposit")},[]);const[K,L]=$.useState(!1),I=me.getLocalizedStrings().spendManagement.reimbursement.reimbursementDetail,E=me.getLocalizedStrings().common.footer,te={onOkClick:()=>{L(!1),w.reset(),f()},onCancelClick:()=>{L(!1)}},pe=async(Y,H)=>{const ie=H[Pt].bankRoutingNumber;l(H),Y===`${Pt}.bankRoutingNumber`&&ie?.length===9&&xo.test(ie)===!0&&k?.(ie)};$.useEffect(()=>{const Y=w.watch((H,{name:ie})=>{ie!=null&&H!=null&&ho(()=>pe(ie,H))});return()=>{Y.unsubscribe()}}),$.useEffect(()=>{e?.fetchState==="Completed"&&f()},[e?.fetchState,f,o]);const A=w.handleSubmit(Y=>{m.fetchState!=="In-Progress"&&b()}),_=s.mode==="light"?new Di(s.colors.brandColorJadeLight):new Di(s.colors.brandColorJadeDark);return t.jsxs(lr,{children:[t.jsxs(hr,{windowSize:g,children:[K===!0?t.jsx(li,{titleComponent:t.jsx(an,{children:I.discardTitle}),descriptionComponent:t.jsx(on,{children:I.discardDescription}),primaryButtonText:I.buttons.delete,secondaryButtonText:I.buttons.cancel,action:te}):null,t.jsx(Bo,{header:I.addBankAccount,isDirty:w.formState.isDirty,onBackClick:f,setShowConfirmationPopup:L}),t.jsx(sr,{}),t.jsxs(gr,{size:g,children:[t.jsx(Ao,{onClick:()=>{w.reset(),v()},title:I.connectYourBank,subTitle:I.loginToBank,header:I.setupAchPayments,icon:{element:t.jsx(go,{width:Re.iconWidthHeight.valuePx(g),height:Re.iconWidthHeight.valuePx(g)}),color:_},style:{width:"unset",rowGap:g==="small"?i.sp2:void 0}}),t.jsxs(cr,{windowSize:g,children:[t.jsx(dr,{}),t.jsx(mr,{children:t.jsx(pr,{children:I.or})})]}),t.jsx(ur,{windowSize:g,children:I.saveAccountManually})]}),t.jsx(yr,{size:g,children:t.jsx(nn,{...w,children:t.jsxs("form",{id:Wi(Ni),onSubmit:A,children:[e?.fetchState==="Error"&&e.error?.code===409?t.jsx(Mo,{warningText:I.accountExistWarning}):null,t.jsx(zo,{bankAccountToCreate:C,fetchBankNameByRoutingStatus:m,sectionId:Pt})]})})})]}),t.jsx(ln,{formId:Wi(Ni),primaryBtn:{label:I.saveAccount,isLoading:e.fetchState==="In-Progress",style:{width:Re.buttonWidth.value(g)},isDisabled:S!=null},cancelBtn:{label:E.cancel,style:{width:Re.buttonWidth.value(g)},shouldResetOnCancel:!1,onClick:()=>{w.formState.isDirty?L(!0):(L(!1),w.reset(),f())}}})]})},lr=n.div`
|
|
508
508
|
display: flex;
|
|
509
509
|
flex-direction: column;
|
|
510
510
|
width: 100%;
|
|
@@ -547,7 +547,7 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
547
547
|
padding-left: ${e=>Re.paddingLeft.valuePx(e.size)};
|
|
548
548
|
padding-right: ${e=>Re.paddingRight.valuePx(e.size)};
|
|
549
549
|
padding-bottom: ${i.sp3};
|
|
550
|
-
`,Ce={containerWidth:new c(343,544),confirmationPopUpTitleMarginTop:new c(a[6],a[7]),confirmationPopUpTitlePaddingLeftRight:new c(a[5],a[8]),submitButtonWidth:new c(145,156),cancelButtonWidth:new c(121,121),errorLineItemGap:new c(a[2],12),styledCloseIconRight:new c(a[3],a[8])},{footer:Ui}=me.getLocalizedStrings().common,ue=me.getLocalizedStrings().spendManagement.reimbursement.reimbursementDetail.duplicatePopUpInfo,Vi=({fetchState:e})=>{switch(e){case"Not-Started":return t.jsx(Hi,{});case"In-Progress":return t.jsx(xt,{size:"Small",start:!0,style:{alignItems:"center",display:"flex"}});case"Completed":return t.jsx(
|
|
550
|
+
`,Ce={containerWidth:new c(343,544),confirmationPopUpTitleMarginTop:new c(a[6],a[7]),confirmationPopUpTitlePaddingLeftRight:new c(a[5],a[8]),submitButtonWidth:new c(145,156),cancelButtonWidth:new c(121,121),errorLineItemGap:new c(a[2],12),styledCloseIconRight:new c(a[3],a[8])},{footer:Ui}=me.getLocalizedStrings().common,ue=me.getLocalizedStrings().spendManagement.reimbursement.reimbursementDetail.duplicatePopUpInfo,Vi=({fetchState:e})=>{switch(e){case"Not-Started":return t.jsx(Hi,{});case"In-Progress":return t.jsx(xt,{size:"Small",start:!0,style:{alignItems:"center",display:"flex"}});case"Completed":return t.jsx(Tn,{});default:return t.jsx(Hi,{})}},br=e=>{switch(e){case"Not-Started":return ue.detectDuplicates;case"In-Progress":return ue.detectingDuplicates;case"Completed":return ue.noDuplicatesFound;default:return ue.detectDuplicates}},fr=({submitFetchState:e,duplicateReimbursementStatus:o,hasDuplicateLine:r,numberOfDuplicateLines:d,setShowDuplicatePopup:p,analytics:C,reimbursementId:m,submitReport:S,fetchDuplicateReimbursement:b,clearDuplicateReimbursementDetail:l,clearRemiSaveStatus:k})=>{const f=Ie(),[s,g]=$t.useState(!0),w=ai(e),P=ai(o);$t.useEffect(()=>{setTimeout(()=>{s&&(g(!1),o==="Not-Started"&&b())},2e3)},[o,b,s]),$t.useEffect(()=>{w==="In-Progress"&&e==="Completed"&&(l(),p(!1))},[e,w,p,l]),$t.useEffect(()=>{P==="In-Progress"&&o==="Completed"&&!r&&S()},[P,o,r,S]);const D=o==="Error"||e==="Error";return t.jsxs(t.Fragment,{children:[D?t.jsx(xr,{size:f}):null,t.jsx(li,{action:{onOkClick:()=>{D?(l(),e==="Error"&&k(),g(!0)):(C?.trackReimbursementReviewDuplicateReportReimbursement(d,m),p(!1),ro())},onCancelClick:()=>{D?(l(),e==="Error"&&k(),p(!1)):(C?.trackReimbursementSubmitAnywayDuplicateReimbursement(d,m),S())}},shouldClickAway:D,isSecondaryLoading:e==="In-Progress",secondaryButtonVariant:"secondary",primaryButtonText:D?Ui.resubmit:ue.primaryButtonText,secondaryButtonText:D?Ui.cancel:ue.secondaryButtonText,primaryButtonWidth:D?Ce.cancelButtonWidth.value(f):Ce.submitButtonWidth.value(f),secondaryButtonWidth:D?Ce.cancelButtonWidth.value(f):Ce.submitButtonWidth.value(f),descriptionComponent:t.jsx(vr,{size:f,children:t.jsxs(wr,{hasDuplicate:r,duplicateReimbursementStatus:o,children:[t.jsxs(Xt,{isDisabled:!1,isSuccess:!s,children:[s?t.jsx(xt,{size:"Small",start:!0,style:{alignItems:"center",display:"flex"}}):t.jsx(Tn,{}),t.jsx(Zt,{isDisabled:!1,children:s?ue.reviewingExpenses:ue.reviewedAllExpenses})]}),r||o==="Error"?t.jsxs(Ki,{size:f,children:[t.jsx(_i,{}),t.jsx(qi,{children:o==="Error"?ue.failedToDetect:`${d} ${ue.duplicateExpensesFound}`})]}):t.jsxs(Xt,{isDisabled:o==="Not-Started",isSuccess:o==="Completed"&&d===0,children:[t.jsx(Vi,{fetchState:o}),t.jsx(Zt,{isDisabled:o==="Not-Started",children:br(o)})]}),e==="Error"?t.jsxs(Ki,{size:f,children:[t.jsx(_i,{}),t.jsx(qi,{children:ue.failedToSubmit})]}):r||o==="Error"?null:t.jsxs(Xt,{isDisabled:e==="Not-Started",isSuccess:e==="Completed",children:[t.jsx(Vi,{fetchState:e}),t.jsx(Zt,{isDisabled:e==="Not-Started",children:e==="Not-Started"?ue.submitReport:ue.submittingReport})]})]})}),titleComponent:t.jsx(Sr,{size:f,children:ue.title}),showFooter:r||D,containerStyle:{width:Ce.containerWidth.value(f),maxWidth:"unset"}})]})},xr=n(cn)`
|
|
551
551
|
width: ${i.sp4};
|
|
552
552
|
height: ${i.sp4};
|
|
553
553
|
color: ${e=>e.theme.colors.hero};
|
|
@@ -569,12 +569,12 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
569
569
|
height: ${i.sp3};
|
|
570
570
|
min-width: ${i.sp3};
|
|
571
571
|
color: ${e=>e.theme.colors.grey3};
|
|
572
|
-
`,
|
|
572
|
+
`,Zt=n.div`
|
|
573
573
|
color: ${e=>e.isDisabled?e.theme.colors.grey2:e.theme.colors.primary};
|
|
574
574
|
text-align: left;
|
|
575
|
-
`,
|
|
575
|
+
`,qi=n.div`
|
|
576
576
|
color: ${j.brandColorGoldDark};
|
|
577
|
-
`,
|
|
577
|
+
`,Xt=n.div`
|
|
578
578
|
display: flex;
|
|
579
579
|
align-items: center;
|
|
580
580
|
gap: ${e=>e.isSuccess?i.sp2:i.sp3};
|
|
@@ -587,7 +587,7 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
587
587
|
flex-direction: column;
|
|
588
588
|
gap: ${i.sp3};
|
|
589
589
|
margin-bottom: ${e=>e.hasDuplicate||e.duplicateReimbursementStatus==="Error"?0:i.sp3};
|
|
590
|
-
`,
|
|
590
|
+
`,Ki=n.div`
|
|
591
591
|
display: flex;
|
|
592
592
|
align-items: center;
|
|
593
593
|
gap: ${e=>Ce.errorLineItemGap.valuePx(e.size)};
|
|
@@ -603,7 +603,7 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
603
603
|
color: ${e=>e.theme.colors.primary};
|
|
604
604
|
word-break: break-word;
|
|
605
605
|
width: ${e=>e.size==="small"?"max-content":"-webkit-fill-available"};
|
|
606
|
-
|
|
606
|
+
`,vr=n(mn)`
|
|
607
607
|
color: ${e=>e.theme.colors.hero};
|
|
608
608
|
padding-left: ${e=>Ce.confirmationPopUpTitlePaddingLeftRight.valuePx(e.size)};
|
|
609
609
|
padding-right: ${e=>Ce.confirmationPopUpTitlePaddingLeftRight.valuePx(e.size)};
|
|
@@ -611,12 +611,12 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
611
611
|
margin-top: ${i.sp4};
|
|
612
612
|
white-space: pre-line;
|
|
613
613
|
width: -webkit-fill-available;
|
|
614
|
-
`,
|
|
614
|
+
`,Tn=n(yo)`
|
|
615
615
|
width: ${i.sp4};
|
|
616
616
|
height: ${i.sp4};
|
|
617
617
|
min-width: ${i.sp4};
|
|
618
618
|
color: ${j.success};
|
|
619
|
-
`,Z={rightMargin:new c(a[3],a[8]),leftMargin:new c(a[3],a[6]),bottomMargin:new c(56,56),closeMarginTop:new c(0,19),closeMarginRight:new c(a[3],a[8]),rightSectionWidth:new c(100,58),leftSectionWidth:new c(100,42),footerButtonWidth:new c(120,165),right:new c(a[3],a[0]),actionsContainerRight:new c(a[0],a[6]),otherActionsContainerBottom:new c(58,44),duplicateBannerWrapperMarginTop:new c(a[5],a[3]),duplicateBannerWrapperMarginRight:new c(a[3],a[8]),duplicateBannerWrapperMarginBottom:new c(a[5],a[3]),duplicateBannerWrapperMarginLeft:new c(a[3],a[6]),navBarWidth:new c(100,58)},{spendManagement:{reimbursement:{reimbursementDetail:y,bulkActions:Gi}},common:{currency:{currencyCode:Me,currencySymbol:Dt},texts:{comments:vr},strings:{empty:Cr}},collaboration:{threads:{placeholder:{addANewComment:kr,replyAComment:Ir},tooltip:{resolveComment:Tr,unResolveComment:Dr}}},dateFormat:Yi}=me.getLocalizedStrings(),Ji="editReimbursementDetailPage",Qi=e=>`${e}_form`,jr=(e,o,r,d,p,C,m,S,b)=>{const l=e.outOfPocket,k=e.mileage,f=l.merchant,s=l.recommendations;return{lineIndex:C,lineId:e?.lineId??String(C+1),reimbursementType:e?.type??y.outOfPocketKey,file:e?.file,homeCurrencyConversions:{amount:e?.homeCurrencyConversions?.amount??0,currencyCode:e?.homeCurrencyConversions?.currencyCode??m.currencyCode,currencySymbol:e?.homeCurrencyConversions?.currencySymbol??m.currencySymbol},outOfPocket:{recommendedAccount:l.recommendedAccount,isCategoryUpdateSelected:l.isCategoryUpdateSelected??!1,isCategoryFirstTimeAutofilled:l.isCategoryFirstTimeAutofilled??!1,retainedAccount:l.retainedAccount,isRetainedCategorySelected:l.isRetainedCategorySelected??!1,recommendations:s??[],transactionDate:l?.transactionDate?.toDate()??void 0,class:{allOptions:_e(r,[]),selectedOption:l?.lineDetail?.class?.classId??b},account:{allOptions:At(o,s),selectedOption:l.lineDetail?.account?.qboId??l.lineDetail?.account?.accountId},amount:{amount:l?.amount??0,currencyCode:l?.currencyCode??m.currencyCode,currencySymbol:l?.currencySymbol??m.currencySymbol,currency:{allOptions:S.map(g=>({label:`${g.currencyCode} - ${g.currency}`,value:g.currencyCode,countryCode:si(g.countryCode)})),selectedOption:l?.currencyCode??m.currencyCode??Me}},memo:l?.description??void 0,merchant:{allOptions:d.map(g=>g.id).filter(g=>!!g),selectedOption:f?.id?f?.id:f?.name?f?.name:e?.lineId!=null?p[e?.lineId]:void 0}},mileage:{transactionDate:k?.transactionDate?.toDate(),class:{allOptions:_e(r,[]),selectedOption:k?.lineDetail?.class?.classId},distanceInMiles:k?.distanceMileage?.value,amount:{amount:k?.amount??0,currencyCode:k?.currencyCode??m.currencyCode,currencySymbol:k?.currencySymbol??m.currencySymbol},memo:k?.description}}},Xt=(e,o,r)=>{const d=[];return Object.values(e.lineDetailSection).forEach((p,C)=>{p?.lineId!=null&&d.push(jr(p,e.accountsHierarchyList,e.classHierarchyList,e.merchantList.merchants,e.tentativeMerchantNameByLineId,C,o,e.allCurrencies,e.loggedInUserDepartmentId))}),d.length===0&&d.push(Tn(0,"1",e.accountsHierarchyList,e.classHierarchyList,e.merchantList.merchants,o,e.allCurrencies,e.loggedInUserDepartmentId)),{[Lt]:{reportTitle:e.whatForSection.reportTitle},[gi]:d,[yt]:{selectedOption:e.paymentTo,allOptions:r.map(p=>p.bankAccountId)}}},ei=(e,o)=>{const r=d=>d.lineId==null||o[d.lineId]?.fetchState==="In-Progress"?0:(o[d.lineId]?.fetchState,d.type===y.mileageKey?d?.mileage?.amount??0:d?.outOfPocket?.currencyCode!==Me&&d.homeCurrencyConversions?.amount!==d?.outOfPocket?.amount?d.homeCurrencyConversions?.amount??0:d?.outOfPocket?.amount??0);return Object.values(e).reduce((d,p)=>d+r(p),0)},ti=(e,o,r,d,p,C,m,S)=>{const b={};return e.lineInfo.forEach(l=>{const k=S.find(P=>P.classId===l.mileage.class.selectedOption),f=m.find(P=>P.qboId===l.outOfPocket.account.selectedOption||P.accountId===l.outOfPocket.account.selectedOption),s=S.find(P=>P.classId===l.outOfPocket.class.selectedOption),g=o.find(P=>P.id===l.outOfPocket.merchant.selectedOption),w=C.find(P=>P.currencyCode===l.outOfPocket.amount?.currency.selectedOption)?.currencySymbol;b[l.lineId]={fileId:l.file?.fileId,lineId:l.lineId,type:l.reimbursementType,homeCurrencyConversions:l.homeCurrencyConversions??{amount:0,currencyCode:"USD",currencySymbol:"$"},mileage:{description:l.mileage.memo??"",lineDetail:{class:k},transactionDate:l.mileage.transactionDate!=null?ee.zeniDate(l.mileage.transactionDate.toDateString()):void 0,amount:l.mileage.amount?.amount??0,currencyCode:l.mileage.amount?.currencyCode??w,currencySymbol:l.mileage.amount?.currencySymbol??w,distanceMileage:{unit:"miles",value:l.mileage.distanceInMiles??0}},outOfPocket:{description:l.outOfPocket.memo??"",lineDetail:{class:s,account:f},transactionDate:l.outOfPocket.transactionDate!=null?ee.zeniDate(l.outOfPocket.transactionDate.toDateString()):void 0,amount:l.outOfPocket.amount?.amount??0,currencyCode:l.outOfPocket.amount?.currency.selectedOption??w,currencySymbol:w,merchant:l.outOfPocket.merchant.selectedOption!=null?{id:g?.id??"",name:g?.name??l.outOfPocket.merchant.selectedOption}:void 0,recommendations:l.outOfPocket.recommendations,recommendedAccount:l.outOfPocket.recommendedAccount,isCategoryUpdateSelected:l.outOfPocket.isCategoryUpdateSelected,isCategoryFirstTimeAutofilled:l.outOfPocket.isCategoryFirstTimeAutofilled,isRetainedCategorySelected:l.outOfPocket.isRetainedCategorySelected,retainedAccount:l.outOfPocket.retainedAccount}}}),{whatForSection:{reportTitle:e.whatFor.reportTitle},updatesByLineId:b,totalAmount:{amount:d,...r},currencyConversionStateByLineId:p,paymentTo:e.paymentTo.selectedOption}},Pl=({remiDetails:e,authParams:o,defaultCurrency:r,companyMileageConfigInfo:d,uploadInvoiceEndPoint:p,isReimbursementCommentingEnabled:C,isUserAdmin:m,analytics:S,reimbursementId:b,plaidConnectionDetails:l,bankAccountCreationState:k,bankNameByRouting:f,bankAccounts:s,isSignedInUserReimbursementCreator:g,uncategorizedAccounts:w,bankAccountToCreate:P,fetchBankNameByRoutingStatus:T,onUserBankDetailsUpdated:$,onFetchBankName:q,onSaveBankAccount:L,fetchDuplicateReimbursement:I,clearDuplicateReimbursementDetail:E,clearRemiSaveStatus:te,removeDuplicateReimbursementForLine:pe,onDuplicateLineClick:A,onExistingMerchantChange:_,onNewMerchantChange:Y,onReceiptsUpload:H,saveRemiDetails:ie,submitRemiDetails:X,discardReimbursementDetailsFromLocalStore:we,onReimbursementDetailsChanged:he,updateReimbursementType:re,onHomeCurrencyConversionUpdate:J,redirectToReimbursementListScreen:le,redirectToReimbursementDetailScreen:Oe,deleteReimbursement:R,removeFileFromLine:ge,onZeniLogoClick:se,onAmountChanged:Ne,updateInvoiceUploadFetchState:Le,clearTentativeNameForLine:Ae,onAddNewRule:Se,onFetchLinkTokenClick:ze,onEstablishConnectionClick:ye,deleteBankAccount:Te,onBackClickFromBankAccountPage:dt})=>{const W=v.useRef(null),et=v.useRef(null),tt=ai(e.uploadStatus),We=bt(),ke=ft(),[He,De]=v.useState(!1),[Ue,Ve]=v.useState(!1),[Ke,qe]=v.useState("save"),[ne,it]=v.useState(ei(e.lineDetailSection,e.currencyConversionStatus)),[ut,Ge]=v.useState(!1),[U,mt]=v.useState(null),[F,ae]=v.useState(!1),wt=`dashboard_${ke.currentTenant?.companyId}`,$e=en({mode:"all",reValidateMode:"onChange",defaultValues:v.useMemo(()=>Xt(e,r,s),[e,r,s]),values:v.useMemo(()=>Xt(e,r,s),[e,r,s])}),{isDirty:z,dirtyFields:jn}=$e.formState,Pn=async(h,D)=>{const{lineInfo:u}=D,x=Number(h.split(".")[1]);if(h.includes("reportTitle")||h.includes("memo"))return;if(h.includes("reimbursementType")){const B=u[x].mileage,N=u[x].outOfPocket;u[x]={...u[x],outOfPocket:{transactionDate:N.transactionDate??void 0,class:{allOptions:N.class.allOptions??_e(e.classHierarchyList,[]),selectedOption:N.class.selectedOption??void 0},account:{allOptions:N.account.allOptions??At(e.accountsHierarchyList,[]),selectedOption:N.account.selectedOption??void 0},amount:N.amount??{amount:0,currencyCode:r.currencyCode,currencySymbol:r.currencySymbol,currency:{allOptions:e.allCurrencies.map(be=>({label:`${be.currencyCode} - ${be.currency}`,value:be.currencyCode,countryCode:si(be.countryCode)})),selectedOption:r.currencyCode??Me}},memo:N.memo??void 0,merchant:N.merchant??void 0,recommendations:N.recommendations??[],recommendedAccount:N.recommendedAccount??void 0,isCategoryUpdateSelected:N.isCategoryUpdateSelected??!1,isCategoryFirstTimeAutofilled:N.isCategoryFirstTimeAutofilled??!1,retainedAccount:N.retainedAccount??void 0,isRetainedCategorySelected:N.isRetainedCategorySelected??!1},mileage:{transactionDate:B.transactionDate??void 0,class:{allOptions:B.class.allOptions??_e(e.classHierarchyList,[]),selectedOption:B.class.selectedOption??e.loggedInUserDepartmentId},distanceInMiles:B.distanceInMiles,amount:{amount:B?.amount?.amount??0,currencyCode:B?.amount?.currencyCode??Me,currencySymbol:B?.amount?.currencySymbol??Dt},memo:B.memo??void 0}}}else if(h.includes("mileage.distanceInMiles")){const{distanceInMiles:B}=u[x].mileage,N=d?.mileageUnitAmount??0;u[x].mileage={...u[x].mileage,amount:{amount:B!=null?B*N:0,currencyCode:r.currencyCode,currencySymbol:r.currencySymbol}}}else if(h.includes("outOfPocket.amount")&&u[x].lineId){const B=u[x].outOfPocket.amount,N=e.allCurrencies.find(be=>be.currencyCode===B?.currency.selectedOption)?.currencySymbol;if(B?.currencyCode!==B?.currency.selectedOption){const be=B?.currency?.allOptions||[];u[x].outOfPocket.amount={currency:{allOptions:be,selectedOption:B?.currency?.selectedOption},amount:u[x].outOfPocket?.amount?.amount??0,currencyCode:B?.currency.selectedOption??Me,currencySymbol:N??Dt}}if(B?.currency.selectedOption!==Me)Ge(!0),Fn(u[x].lineId,Me);else{const be={};u.forEach(qt=>{be[qt.lineId]={lineId:qt.lineId,homeCurrencyConversions:qt.homeCurrencyConversions}}),u[x].homeCurrencyConversions={amount:B.amount??0,currencyCode:B?.currency.selectedOption??Me,currencySymbol:N??Dt};const vi=ei(be,e.currencyConversionStatus);ne!==vi&&it(vi)}}else if(h.includes("outOfPocket.isRetainedCategorySelected"))u[x].outOfPocket.isRetainedCategorySelected===!0&&(u[x].outOfPocket.isCategoryUpdateSelected=!1,u[x].outOfPocket.account.selectedOption=u[x].outOfPocket.retainedAccount?.qboId);else if(h.includes("outOfPocket.isCategoryUpdateSelected"))if(u[x].outOfPocket.isCategoryUpdateSelected===!0)u[x].outOfPocket.account.selectedOption=u[x].outOfPocket.recommendedAccount?.qboId,u[x].outOfPocket.isRetainedCategorySelected=!1;else{const B=u[x].lineId,N=e.editRemiInitialDetails.lineDetailSection[B]?.lineDetail?.account?.qboId;u[x].outOfPocket.account.selectedOption=N,u[x].outOfPocket.isRetainedCategorySelected=!1}else h.includes("outOfPocket.account")&&(u[x].outOfPocket.recommendations.length>0&&(u[x].outOfPocket.recommendedAccount=u[x].outOfPocket.recommendations[0].account),u[x].outOfPocket.recommendedAccount?.qboId!=null&&u[x].outOfPocket.account.selectedOption===u[x].outOfPocket.recommendedAccount?.qboId?u[x].outOfPocket.isCategoryUpdateSelected=!0:u[x].outOfPocket.isCategoryUpdateSelected=!1,u[x].outOfPocket.retainedAccount?.qboId!=null&&u[x].outOfPocket.account.selectedOption===u[x].outOfPocket.retainedAccount?.qboId?u[x].outOfPocket.isRetainedCategorySelected=!0:u[x].outOfPocket.isRetainedCategorySelected=!1,u[x].outOfPocket.isCategoryFirstTimeAutofilled=!1);const $t=ti({...D,lineInfo:u},e.merchantList.merchants,r,ne,e.currencyConversionStatus,e.allCurrencies,e.accountList.accounts,e.classList.classes);if(he?.($t),h.includes("outOfPocket.merchant")){const B=u[x].lineId,N=u[x].outOfPocket.merchant.selectedOption??"";u[x].outOfPocket.merchant.allOptions.find(be=>be===N)!=null?_(N,B):Y(N,B)}},yi=v.useMemo(()=>Ci((h,D)=>Pn(h,D),300),[e.accountList.fetchState,e.classList.fetchState,e.merchantList.fetchState]);v.useEffect(()=>{const h=$e.watch((D,{name:u})=>{u!=null&&D!=null&&yi(u,D)});return()=>{h.unsubscribe()}},[yi,$e]),v.useEffect(()=>{const h=ee.reduceAnyFetchState(Object.values(e.currencyConversionStatus)),D=h.fetchState==="In-Progress"||h.fetchState==="Error";Ge(D)},[e.currencyConversionStatus]),v.useEffect(()=>{for(const D in e.currencyConversionStatus){const u=e.lineDetailSection[D],x=e.lineDetailSection[D];e.currencyConversionStatus[D].fetchState==="Completed"&&x!=null&&u.type!==y.mileageKey&&!tn(u?.homeCurrencyConversions,x.homeCurrencyConversions)&&J({amount:u?.homeCurrencyConversions?.amount??0,currencyCode:u?.homeCurrencyConversions?.currencyCode??Me,currencySymbol:u?.homeCurrencyConversions?.currencySymbol??Dt},D,b)}const h=ei(e.lineDetailSection,e.currencyConversionStatus);ne!==h&&it(h)},[e.currencyConversionStatus,e.lineDetailSection]),v.useEffect(()=>{(e.saveStatus?.fetchState==="Completed"||e.deleteStatus.fetchState==="Completed")&&(we(b),le?.())},[e.saveStatus?.fetchState,e.deleteStatus.fetchState,b,we,le]);const O=Ie(),[je,pt]=v.useState(b==null),[ht,Rn]=v.useState(1),[On,Ft]=v.useState(!1),[Ln,An]=v.useState(""),[Et,zn]=v.useState(null),[Bn,nt]=v.useState(!1),[Mn,bi]=v.useState(!1),[Nt,Wt]=v.useState([]),[ce,St]=v.useState({title:"",description:"",primaryButtonText:"",secondaryButtonText:""}),Fn=v.useRef(Ci((h,D)=>Ne(h,D),500,{trailing:!0})).current;v.useEffect(()=>{tt==="In-Progress"&&(e.uploadStatus==="Completed"?($e.reset(Xt(e,r,s),{keepDefaultValues:!0}),De(!1),pt(!1)):e.uploadStatus==="Error"&&De(!1))},[tt,e.uploadStatus,$e,e,He,De,je,r,s,S]),v.useEffect(()=>{e.uploadStatus==="In-Progress"&&je===!1&&De(!0)},[e.uploadStatus,De,je]);const Ut=e.remiStage==="draft"?y.newReimbursementTitle:y.editReimbursementTitle,En={onOkClick:()=>{if(nt(!1),ce.primaryButtonText===y.buttons.discard)we(b),e.remiStage==="draft"?le?.():Oe?.();else if(ce.primaryButtonText===y.buttons.delete)ce.title===y.deleteBankAccountTitle?Te?.(Ln):R?.();else if(ce.primaryButtonText===y.buttons.yes&&Et!=null){const h=Nt.filter(D=>D!==ht.toString());Wt(h),H(Et,ht,!0)}},onCancelClick:()=>{if(nt(!1),ce.secondaryButtonText===y.buttons.no){const h=Nt.filter(D=>D!==ht.toString());Wt(h),H(Et,ht,!1)}}},fi=()=>{z||co(jn)?(St({title:y.discardTitle,description:y.discardDescription,primaryButtonText:y.buttons.discard,secondaryButtonText:y.buttons.cancel}),nt(!0)):(we(b),le?.())},Nn=()=>{St({title:e.remiStage==="draft"?y.deleteDraftTitle:y.deleteReportTitle,description:y.deleteAlertDescription,primaryButtonText:y.buttons.delete,secondaryButtonText:y.buttons.cancel}),nt(!0)},Wn=h=>{An(h),St({title:y.deleteBankAccountTitle,description:y.deleteBankAccountDescription,primaryButtonText:y.buttons.delete,secondaryButtonText:y.buttons.cancel}),nt(!0)},Un=()=>{St({title:y.overwriteTitle,description:y.overwriteDescription,primaryButtonText:y.buttons.yes,secondaryButtonText:y.buttons.no}),nt(!0)},Vn=()=>{let h=!0;const D=[];return Object.values(e.lineDetailSection).forEach((u,x)=>{u.type===y.outOfPocketKey&&vn(u)>=75&&u.file==null&&(D.push(u.lineId),h=!1)}),Wt(D),h},xi=()=>{if(m&&e.remiStage==="pending_approval"&&e.remiStatus!=="rejected")fi();else if(e.whatForSection.reportTitle!=null&&e.whatForSection.reportTitle.length>0){qe("save");const h=$e.getValues(),D=ti(h,e.merchantList.merchants,r,ne,e.currencyConversionStatus,e.allCurrencies,e.accountList.accounts,e.classList.classes);he?.(D),ie(e.remiStatus==="rejected"?"pending_approval":"draft")}else $e.trigger(`${Lt}.reportTitle`,{shouldFocus:!0})};let Vt=!1;Object.values(e.addRemiAutoFieldsByLineId).forEach(h=>{h.length>0&&(Vt=!0)});let wi=[];if(e.remiId==null){const h=ne??0;h>0&&(wi=e.approvalRules.allApprovalRules?.filter(D=>{const u=D.criteria[0].range;if(u.max!=null){if(u.min.amount<h&&u.max.amount>=h)return D}else if(u.min.amount<h)return D;return null}).map(D=>({...D,stepsWithStatus:D.steps.map(u=>({...u,actorsActivity:[],isOriginalApprovalStep:!0})),isRealTimeApprovalEnabled:!1})))}const _n=h=>{const D=Vn();return $e.handleSubmit(()=>{D&&(qe("submit"),S?.trackReimbursementSubmitReimbursement(e.createTime?.format(Yi.analytics.MMMDashDDDashYYYYFormat)??ee.dateNow().format(Yi.analytics.MMMDashDDDashYYYYFormat),r.currencyCode,ne,b),E(),bi(!0))})(h)},Hn=()=>{const h=$e.getValues(),D=ti(h,e.merchantList.merchants,r,ne,e.currencyConversionStatus,e.allCurrencies,e.accountList.accounts,e.classList.classes);he?.(D),X()},Kn=e.reimbursementInfo?.billStatus.code=="approved"&&e.reimbursementInfo?.billPaymentStatus.code?e.reimbursementInfo?.billPaymentStatus:e.reimbursementInfo?.billStatus,qn=e.reimbursementInfo?.paymentDate!=null?ee.zeniDate(ee.getNextNthWorkingDay(e.reimbursementInfo.paymentDate.toDate(),[0,6],e.achSameDayMaxDays).toDateString()):void 0,Gn=e.reimbursementInfo?.expectedDepositDate??qn,Yn=b!=null&&e.remiStage==="draft",Si=Ro(e.duplicateLineByLineId),_t=e.duplicateReimbursementStatus.fetchState==="Completed"&&Si>0,{requestToOpenThread:Ht,setRequestToOpenThread:$i,setOpenThread:Kt}=v.useContext(Zn),{threads:gt,isLoading:Ye}=Xn({application:"dashboard",companyId:ke.currentTenant?.companyId,tab:"reimbursement",entityId:b,isGlobalComment:!1},"both",!1);v.useEffect(()=>{Ht?.threadId!=null&>.length>0&&!Ye&&(Kt(Ht.threadId),$i(null))},[Ht,gt,Ye,Kt,$i]);const Jn=v.useMemo(()=>b==null?[]:gt.filter(h=>h.resolved===!1&&!h.id.includes(eo)),[gt,b]).length,Qn=(h,D)=>{Kt(D);const u=h.entityType.split("."),x=parseInt(u[2]);if(isNaN(x)){ae(!1);return}const $t=`${x+1}`,B=e.lineDetailSection[x+1].type;u.includes(y.mileageKey)&&B===y.outOfPocketKey?re(ee.toReimbursementTypeCode(y.mileageKey),$t,b):u.includes(y.outOfPocketKey)&&B===y.mileageKey&&re(ee.toReimbursementTypeCode(y.outOfPocketKey),$t,b),ae(!1)};return t.jsx(Rr,{ref:W,children:t.jsx(to,{sharedItems:{sharedFunctions:void 0,sharedRef:{contentWrapperRef:et.current??null}},children:t.jsxs(nn,{...$e,children:[t.jsx("form",{id:Qi(Ji),onSubmit:h=>_n(h),children:t.jsxs(rl,{windowSize:O,ref:et,children:[Bn?t.jsx(li,{titleComponent:t.jsx(an,{children:ce.title}),descriptionComponent:t.jsx(on,{children:ce.description}),primaryButtonText:ce.primaryButtonText,secondaryButtonText:ce.secondaryButtonText,action:En,proceedButtonVariant:ce.title===y.deleteBankAccountTitle||ce.title===y.deleteDraftTitle||ce.title===y.deleteReportTitle||ce.title===y.discardTitle?"danger":"primary",isEditPopup:ce.title===y.deleteBankAccountTitle}):null,Mn?t.jsx(fr,{reimbursementId:b,submitFetchState:e.saveStatus?.fetchState??"Not-Started",duplicateReimbursementStatus:e.duplicateReimbursementStatus.fetchState,hasDuplicateLine:_t,numberOfDuplicateLines:Si,setShowDuplicatePopup:bi,submitReport:Hn,fetchDuplicateReimbursement:I,clearDuplicateReimbursementDetail:E,clearRemiSaveStatus:te,analytics:S}):null,He?t.jsx(Xi,{windowSize:O}):null,je?t.jsxs(Xi,{windowSize:O,"data-testid":K("skip-autofill-section"),children:[O==="small"?t.jsxs(t.Fragment,{children:[t.jsx(Vr,{children:t.jsx(oi,{partOfSkipAutoFill:!0,size:O,onClick:()=>pt(!1),"data-testid":K("close-invoice-upload"),children:t.jsx(ni,{withOverlay:!0,children:t.jsx(ii,{})})})}),t.jsx(Hr,{children:Ut})]}):null,t.jsx(xn,{showAutofill:je,analytics:S,onSkipAutofill:()=>{S?.trackReimbursementSkipAutofill(),pt(!1)},uploadInvoiceEndPoint:p,authParams:o,style:{width:Z.leftSectionWidth.valuePercentage(O),boxSizing:"border-box",backgroundColor:O==="small"?We.colors.grey4:"unset",padding:O==="small"?`${i.sp5} ${i.sp3}`:`78px ${i.sp6} 15px ${i.sp8}`,margin:O==="small"?i.sp0:void 0},onInvoiceUpload:h=>H(h,ht,!0),dropFilePlaceholder:{upload:y.dropReceipt.upload,single:y.dropReceipt.single,or:y.dropReceipt.or,multiple:y.dropReceipt.multiple,receipts:y.dropReceipt.receipts},updateInvoiceUploadFetchState:Le,showInfoText:!1,allowMultiFiles:je,type:"receipt"}),O!=="small"?t.jsx(_r,{children:t.jsx(oi,{partOfSkipAutoFill:!0,onClick:()=>pt(!1),"data-testid":K("close-invoice-upload"),children:t.jsx(ni,{withOverlay:!0,children:t.jsx(ii,{})})})}):null]}):null,t.jsxs(tl,{windowSize:O,"data-testid":K("edit-reimbursement-detail-page-nav-bar-container"),children:[O!=="small"?t.jsx(ki,{style:{width:"42%"},"data-testid":K("edit-reimbursement-detail-page-left-nav-bar"),title:"",leftSideComponent:t.jsx(il,{"data-testid":K("zeni-logo-spend-management-reimbursement-detail-page"),onClick:se}),enableTitleOnScroll:!1,scrollableContent:W,backgroundColor:We.colors.background,keepBackgroundOnScroll:!0,source:"EditReimbursementDetailPage"}):null,O!=="small"?t.jsx(Or,{}):null,t.jsx(ki,{style:{width:Z.navBarWidth.valuePercentage(O)},"data-testid":K("edit-reimbursement-detail-page-right-nav-bar"),source:"EditReimbursementDetailPage",title:Ut,leftSideComponent:t.jsx(t.Fragment,{}),rightSideComponent:je!=!0?t.jsxs(nl,{children:[C&&b!=null?t.jsxs(ol,{isDisabled:Ye,"data-testid":K("remi-comment-button"),onClick:Ye?()=>null:h=>{h.preventDefault(),h.stopPropagation(),mt({roomId:wt,companyId:ke.currentTenant?.companyId??"",companyName:ke.currentTenant?.companyName??"",entityType:"reimbursement.details",entityId:b}),ae(!0),S?.trackCommentActivity("reimbursement","clicked",ke.currentTenant?.companyName??"",ke.controllersList.controllers.map(D=>no(D)),void 0,void 0,"page icon")},children:[t.jsx(io,{count:Ye?void 0:Jn,isLoading:Ye,style:{left:"12px"}}),t.jsx(al,{})]}):null,t.jsx(oi,{size:O,onClick:()=>fi(),"data-testid":K("close-nav-bar"),children:t.jsx(ni,{withOverlay:!1,children:t.jsx(ii,{})})})]}):null,enableTitleOnScroll:O!=="small",scrollThreshold:64,scrollableContent:W,backgroundColor:We.colors.grey4})]}),O==="small"?t.jsxs(t.Fragment,{children:[t.jsx(el,{children:Ut}),t.jsx(oo,{progressSectionObj:Kn,createDate:e.createTime,paymentDate:Gn,scheduleDate:e.reimbursementInfo?.paymentDate,approvedDate:e.latestApprovedDate,isBillUploaded:b!=null?!0:e.uploadStatus==="Completed"}),Vt&&t.jsxs(Gr,{children:[t.jsx(qr,{}),t.jsx(Yr,{children:y.banner})]}),e.isProcessing?t.jsx(rn,{variant:"warning",style:{margin:O==="small"?`${i.sp5} ${i.sp3}`:`${i.sp3} ${i.sp8} ${i.sp3} ${i.sp6}`},title:Gi.duplicateWarning.title,description:Gi.duplicateWarning.description}):_t?t.jsxs(Jr,{size:O,children:[t.jsx(Br,{}),t.jsxs(Zr,{children:[t.jsx(Qr,{children:y.thereSeems}),t.jsx(Xr,{children:y.pleaseFind})]})]}):null,t.jsx($n,{isReimbursementCommentingEnabled:C,sectionId:Lt,reimbursementId:e.remiId,reportTitle:e.whatForSection.reportTitle})]}):null,t.jsx(qa,{onDuplicateLineClick:A,reimbursementId:b,remiDetails:e,uploadInvoiceEndPoint:p,authParams:o,showSkipAutoFill:je,setShowSkipAutoFill:pt,isReimbursementCommentingEnabled:C,isAutoFieldsExist:Vt,totalAmount:ne,removeFileFromLine:ge,onReplaceClick:Un,onReceiptsUpload:H,currencyConversionStatus:e.currencyConversionStatus,setCurrentLineIdForUpload:Rn,setUploadedReceiptPayload:zn,updateInvoiceUploadFetchState:Le,clearTentativeNameForLine:Ae,defaultCurrency:r,companyMileageConfigInfo:d,isUserAdmin:m,setShowBankAccountPage:Ft,bankAccounts:s,onDeleteBankAccount:Wn,analytics:S,fileRequiredLineIds:Nt,isSignedInUserReimbursementCreator:g,uncategorizedAccounts:w,showTotalAmountLoader:ut,duplicateLineByLineId:e.duplicateLineByLineId,hasDuplicateLine:_t,removeDuplicateReimbursementForLine:pe,scrollContainerRef:W}),t.jsxs(ll,{showSkipAutoFill:je,windowSize:O,children:[O!=="small"?t.jsx(Zi,{}):null,t.jsx(sl,{windowSize:O,children:t.jsxs(cl,{windowSize:O,children:[e.remiId!==void 0&&t.jsx(Ii,{amount:ne??0,activities:e.remiActivities,stage:e.remiStage??"draft",onAddNewRule:Se,entity:"reimbursement",historicActivities:e.remiHistory.activities}),e.remiId==null&&ne!=null&&ne>0?t.jsx(Ii,{amount:ne??0,activities:wi,stage:"draft",entity:"reimbursement",historicActivities:e.remiHistory.activities}):null]})})]}),t.jsx(dl,{}),t.jsxs(Kr,{showSkipAutoFill:je,windowSize:O,children:[O!=="small"?t.jsx(Zi,{}):null,t.jsx(Lr,{windowSize:O,onClick:h=>{h.stopPropagation(),Ue===!0&&Ve(!1)},children:t.jsx(ln,{formId:Qi(Ji),separatorStyle:{marginRight:i.sp4},showCancel:g,cancelBtn:{label:m&&e.remiStage==="pending_approval"&&e.remiStatus!=="rejected"?O==="small"?y.buttons.discard:y.buttons.discardChanges:O==="small"?y.buttons.save:y.buttons.saveChanges,isLoading:Ke==="save"&&e.saveStatus?.fetchState==="In-Progress",onClick:xi,style:{width:Z.footerButtonWidth.value(O)},reverseSpinnerColor:!1},primaryBtn:{label:Pr(g,m,e,O),isDisabled:!g,style:{width:g?Z.footerButtonWidth.value(O):"auto"},type:g?"submit":"button",onClick:g?()=>null:xi,isLoading:!g&&Ke==="save"&&e.saveStatus?.fetchState==="In-Progress"},rightSideComponent:t.jsx(Ar,{children:t.jsxs(Nr,{windowSize:O,children:[Ue?t.jsx(sn,{onClickAway:()=>Ve(!1),children:t.jsx(Er,{windowSize:O,"data-testid":K("remi-other-actions-container"),children:t.jsx(Wr,{onClick:Nn,"data-testid":K("delete-report-action"),children:y.buttons.deleteReport})})}):null,t.jsx(Fr,{windowSize:O,children:Yn===!0?t.jsx(Mr,{windowSize:O,"data-testid":K("more-details-button"),children:t.jsx(zr,{onClick:()=>Ve(!Ue)})}):null})]})}),style:{minHeight:62}})})]}),C&&b!=null?t.jsx(Po,{id:wt,children:t.jsx(ao,{isDrawerOpen:F,allowComposer:!0,drawerTitle:vr,threads:gt,autoExpand:!0,autoFocus:!1,filter:{application:"dashboard",companyId:U?.companyId??Cr,isGlobalComment:!1,tab:"reimbursement"},isLoading:Ye,threadMetadata:U?{companyName:U.companyName,companyId:U.companyId,entityId:U.entityId,entityType:U.entityType,isGlobalComment:!1,application:"dashboard",tab:"reimbursement",url:window.location.href}:void 0,textOverrides:{composerPlaceholder:kr,replyComposerPlaceholder:Ir,threadResolve:Tr,threadUnResolve:Dr},onThreadClick:(h,D)=>Qn(h,D),onCloseAllThreadsDrawer:()=>ae(!1),drawerSectionStyle:{width:"400px",backgroundColor:We.colors.background}})}):null]})}),On?t.jsx(Ur,{windowSize:O,children:t.jsx(rr,{bankAccountCreationState:k,setShowBankAccountPage:Ft,plaidConnectionDetails:l,onFetchLinkTokenClick:ze,onEstablishConnectionClick:ye,onSaveHandler:L,bankAccountToCreate:P,bankNameByRouting:f,fetchBankNameByRoutingStatus:T,onUserBankDetailsUpdated:$,onFetchBankName:q,onBackClick:()=>{dt(),Ft(!1)}})}):null]})})})},Pr=(e,o,r,d)=>e?r.reimbursementId!=null&&r.remiStage==="pending_approval"?y.buttons.resubmit:y.buttons.submit:o&&r.remiStage==="pending_approval"&&r.remiStatus!=="rejected"?d==="small"?y.buttons.discard:y.buttons.discardChanges:d==="small"?y.buttons.save:y.buttons.saveChanges,Rr=n.div`
|
|
619
|
+
`,X={rightMargin:new c(a[3],a[8]),leftMargin:new c(a[3],a[6]),bottomMargin:new c(56,56),closeMarginTop:new c(0,19),closeMarginRight:new c(a[3],a[8]),rightSectionWidth:new c(100,58),leftSectionWidth:new c(100,42),footerButtonWidth:new c(120,165),right:new c(a[3],a[0]),actionsContainerRight:new c(a[0],a[6]),otherActionsContainerBottom:new c(58,44),duplicateBannerWrapperMarginTop:new c(a[5],a[3]),duplicateBannerWrapperMarginRight:new c(a[3],a[8]),duplicateBannerWrapperMarginBottom:new c(a[5],a[3]),duplicateBannerWrapperMarginLeft:new c(a[3],a[6]),navBarWidth:new c(100,58)},{spendManagement:{reimbursement:{reimbursementDetail:y,bulkActions:Gi}},common:{currency:{currencyCode:Me,currencySymbol:Tt},texts:{comments:$r},strings:{empty:Cr}},collaboration:{threads:{placeholder:{addANewComment:kr,replyAComment:Ir},tooltip:{resolveComment:Dr,unResolveComment:Tr}}},dateFormat:Yi}=me.getLocalizedStrings(),Ji="editReimbursementDetailPage",Zi=e=>`${e}_form`,jr=(e,o,r,d,p,C,m,S,b)=>{const l=e.outOfPocket,k=e.mileage,f=l.merchant,s=l.recommendations;return{lineIndex:C,lineId:e?.lineId??String(C+1),reimbursementType:e?.type??y.outOfPocketKey,file:e?.file,homeCurrencyConversions:{amount:e?.homeCurrencyConversions?.amount??0,currencyCode:e?.homeCurrencyConversions?.currencyCode??m.currencyCode,currencySymbol:e?.homeCurrencyConversions?.currencySymbol??m.currencySymbol},outOfPocket:{recommendedAccount:l.recommendedAccount,isCategoryUpdateSelected:l.isCategoryUpdateSelected??!1,isCategoryFirstTimeAutofilled:l.isCategoryFirstTimeAutofilled??!1,retainedAccount:l.retainedAccount,isRetainedCategorySelected:l.isRetainedCategorySelected??!1,recommendations:s??[],transactionDate:l?.transactionDate?.toDate()??void 0,class:{allOptions:_e(r,[]),selectedOption:l?.lineDetail?.class?.classId??b},account:{allOptions:At(o,s),selectedOption:l.lineDetail?.account?.qboId??l.lineDetail?.account?.accountId},amount:{amount:l?.amount??0,currencyCode:l?.currencyCode??m.currencyCode,currencySymbol:l?.currencySymbol??m.currencySymbol,currency:{allOptions:S.map(g=>({label:`${g.currencyCode} - ${g.currency}`,value:g.currencyCode,countryCode:si(g.countryCode)})),selectedOption:l?.currencyCode??m.currencyCode??Me}},memo:l?.description??void 0,merchant:{allOptions:d.map(g=>g.id).filter(g=>!!g),selectedOption:f?.id?f?.id:f?.name?f?.name:e?.lineId!=null?p[e?.lineId]:void 0}},mileage:{transactionDate:k?.transactionDate?.toDate(),class:{allOptions:_e(r,[]),selectedOption:k?.lineDetail?.class?.classId},distanceInMiles:k?.distanceMileage?.value,amount:{amount:k?.amount??0,currencyCode:k?.currencyCode??m.currencyCode,currencySymbol:k?.currencySymbol??m.currencySymbol},memo:k?.description}}},Qt=(e,o,r)=>{const d=[];return Object.values(e.lineDetailSection).forEach((p,C)=>{p?.lineId!=null&&d.push(jr(p,e.accountsHierarchyList,e.classHierarchyList,e.merchantList.merchants,e.tentativeMerchantNameByLineId,C,o,e.allCurrencies,e.loggedInUserDepartmentId))}),d.length===0&&d.push(Dn(0,"1",e.accountsHierarchyList,e.classHierarchyList,e.merchantList.merchants,o,e.allCurrencies,e.loggedInUserDepartmentId)),{[Lt]:{reportTitle:e.whatForSection.reportTitle},[gi]:d,[yt]:{selectedOption:e.paymentTo,allOptions:r.map(p=>p.bankAccountId)}}},ei=(e,o)=>{const r=d=>d.lineId==null||o[d.lineId]?.fetchState==="In-Progress"?0:(o[d.lineId]?.fetchState,d.type===y.mileageKey?d?.mileage?.amount??0:d?.outOfPocket?.currencyCode!==Me&&d.homeCurrencyConversions?.amount!==d?.outOfPocket?.amount?d.homeCurrencyConversions?.amount??0:d?.outOfPocket?.amount??0);return Object.values(e).reduce((d,p)=>d+r(p),0)},ti=(e,o,r,d,p,C,m,S)=>{const b={};return e.lineInfo.forEach(l=>{const k=S.find(P=>P.classId===l.mileage.class.selectedOption),f=m.find(P=>P.qboId===l.outOfPocket.account.selectedOption||P.accountId===l.outOfPocket.account.selectedOption),s=S.find(P=>P.classId===l.outOfPocket.class.selectedOption),g=o.find(P=>P.id===l.outOfPocket.merchant.selectedOption),w=C.find(P=>P.currencyCode===l.outOfPocket.amount?.currency.selectedOption)?.currencySymbol;b[l.lineId]={fileId:l.file?.fileId,lineId:l.lineId,type:l.reimbursementType,homeCurrencyConversions:l.homeCurrencyConversions??{amount:0,currencyCode:"USD",currencySymbol:"$"},mileage:{description:l.mileage.memo??"",lineDetail:{class:k},transactionDate:l.mileage.transactionDate!=null?ee.zeniDate(l.mileage.transactionDate.toDateString()):void 0,amount:l.mileage.amount?.amount??0,currencyCode:l.mileage.amount?.currencyCode??w,currencySymbol:l.mileage.amount?.currencySymbol??w,distanceMileage:{unit:"miles",value:l.mileage.distanceInMiles??0}},outOfPocket:{description:l.outOfPocket.memo??"",lineDetail:{class:s,account:f},transactionDate:l.outOfPocket.transactionDate!=null?ee.zeniDate(l.outOfPocket.transactionDate.toDateString()):void 0,amount:l.outOfPocket.amount?.amount??0,currencyCode:l.outOfPocket.amount?.currency.selectedOption??w,currencySymbol:w,merchant:l.outOfPocket.merchant.selectedOption!=null?{id:g?.id??"",name:g?.name??l.outOfPocket.merchant.selectedOption}:void 0,recommendations:l.outOfPocket.recommendations,recommendedAccount:l.outOfPocket.recommendedAccount,isCategoryUpdateSelected:l.outOfPocket.isCategoryUpdateSelected,isCategoryFirstTimeAutofilled:l.outOfPocket.isCategoryFirstTimeAutofilled,isRetainedCategorySelected:l.outOfPocket.isRetainedCategorySelected,retainedAccount:l.outOfPocket.retainedAccount}}}),{whatForSection:{reportTitle:e.whatFor.reportTitle},updatesByLineId:b,totalAmount:{amount:d,...r},currencyConversionStateByLineId:p,paymentTo:e.paymentTo.selectedOption}},Pl=({remiDetails:e,authParams:o,defaultCurrency:r,companyMileageConfigInfo:d,uploadInvoiceEndPoint:p,isReimbursementCommentingEnabled:C,isUserAdmin:m,analytics:S,reimbursementId:b,plaidConnectionDetails:l,bankAccountCreationState:k,bankNameByRouting:f,bankAccounts:s,isSignedInUserReimbursementCreator:g,uncategorizedAccounts:w,bankAccountToCreate:P,fetchBankNameByRoutingStatus:D,onUserBankDetailsUpdated:v,onFetchBankName:K,onSaveBankAccount:L,fetchDuplicateReimbursement:I,clearDuplicateReimbursementDetail:E,clearRemiSaveStatus:te,removeDuplicateReimbursementForLine:pe,onDuplicateLineClick:A,onExistingMerchantChange:_,onNewMerchantChange:Y,onReceiptsUpload:H,saveRemiDetails:ie,submitRemiDetails:Q,discardReimbursementDetailsFromLocalStore:we,onReimbursementDetailsChanged:he,updateReimbursementType:re,onHomeCurrencyConversionUpdate:J,redirectToReimbursementListScreen:le,redirectToReimbursementDetailScreen:Oe,deleteReimbursement:R,removeFileFromLine:ge,onZeniLogoClick:se,onAmountChanged:Ne,updateInvoiceUploadFetchState:Le,clearTentativeNameForLine:Ae,onAddNewRule:Se,onFetchLinkTokenClick:ze,onEstablishConnectionClick:ye,deleteBankAccount:De,onBackClickFromBankAccountPage:dt})=>{const W=$.useRef(null),et=$.useRef(null),tt=ai(e.uploadStatus),We=bt(),ke=ft(),[He,Te]=$.useState(!1),[Ue,Ve]=$.useState(!1),[qe,Ke]=$.useState("save"),[ne,it]=$.useState(ei(e.lineDetailSection,e.currencyConversionStatus)),[ut,Ge]=$.useState(!1),[U,mt]=$.useState(null),[F,ae]=$.useState(!1),wt=`dashboard_${ke.currentTenant?.companyId}`,ve=en({mode:"all",reValidateMode:"onChange",defaultValues:$.useMemo(()=>Qt(e,r,s),[e,r,s]),values:$.useMemo(()=>Qt(e,r,s),[e,r,s])}),{isDirty:z,dirtyFields:jn}=ve.formState,Pn=async(h,T)=>{const{lineInfo:u}=T,x=Number(h.split(".")[1]);if(h.includes("reportTitle")||h.includes("memo"))return;if(h.includes("reimbursementType")){const B=u[x].mileage,N=u[x].outOfPocket;u[x]={...u[x],outOfPocket:{transactionDate:N.transactionDate??void 0,class:{allOptions:N.class.allOptions??_e(e.classHierarchyList,[]),selectedOption:N.class.selectedOption??void 0},account:{allOptions:N.account.allOptions??At(e.accountsHierarchyList,[]),selectedOption:N.account.selectedOption??void 0},amount:N.amount??{amount:0,currencyCode:r.currencyCode,currencySymbol:r.currencySymbol,currency:{allOptions:e.allCurrencies.map(be=>({label:`${be.currencyCode} - ${be.currency}`,value:be.currencyCode,countryCode:si(be.countryCode)})),selectedOption:r.currencyCode??Me}},memo:N.memo??void 0,merchant:N.merchant??void 0,recommendations:N.recommendations??[],recommendedAccount:N.recommendedAccount??void 0,isCategoryUpdateSelected:N.isCategoryUpdateSelected??!1,isCategoryFirstTimeAutofilled:N.isCategoryFirstTimeAutofilled??!1,retainedAccount:N.retainedAccount??void 0,isRetainedCategorySelected:N.isRetainedCategorySelected??!1},mileage:{transactionDate:B.transactionDate??void 0,class:{allOptions:B.class.allOptions??_e(e.classHierarchyList,[]),selectedOption:B.class.selectedOption??e.loggedInUserDepartmentId},distanceInMiles:B.distanceInMiles,amount:{amount:B?.amount?.amount??0,currencyCode:B?.amount?.currencyCode??Me,currencySymbol:B?.amount?.currencySymbol??Tt},memo:B.memo??void 0}}}else if(h.includes("mileage.distanceInMiles")){const{distanceInMiles:B}=u[x].mileage,N=d?.mileageUnitAmount??0;u[x].mileage={...u[x].mileage,amount:{amount:B!=null?B*N:0,currencyCode:r.currencyCode,currencySymbol:r.currencySymbol}}}else if(h.includes("outOfPocket.amount")&&u[x].lineId){const B=u[x].outOfPocket.amount,N=e.allCurrencies.find(be=>be.currencyCode===B?.currency.selectedOption)?.currencySymbol;if(B?.currencyCode!==B?.currency.selectedOption){const be=B?.currency?.allOptions||[];u[x].outOfPocket.amount={currency:{allOptions:be,selectedOption:B?.currency?.selectedOption},amount:u[x].outOfPocket?.amount?.amount??0,currencyCode:B?.currency.selectedOption??Me,currencySymbol:N??Tt}}if(B?.currency.selectedOption!==Me)Ge(!0),Fn(u[x].lineId,Me);else{const be={};u.forEach(Kt=>{be[Kt.lineId]={lineId:Kt.lineId,homeCurrencyConversions:Kt.homeCurrencyConversions}}),u[x].homeCurrencyConversions={amount:B.amount??0,currencyCode:B?.currency.selectedOption??Me,currencySymbol:N??Tt};const $i=ei(be,e.currencyConversionStatus);ne!==$i&&it($i)}}else if(h.includes("outOfPocket.isRetainedCategorySelected"))u[x].outOfPocket.isRetainedCategorySelected===!0&&(u[x].outOfPocket.isCategoryUpdateSelected=!1,u[x].outOfPocket.account.selectedOption=u[x].outOfPocket.retainedAccount?.qboId);else if(h.includes("outOfPocket.isCategoryUpdateSelected"))if(u[x].outOfPocket.isCategoryUpdateSelected===!0)u[x].outOfPocket.account.selectedOption=u[x].outOfPocket.recommendedAccount?.qboId,u[x].outOfPocket.isRetainedCategorySelected=!1;else{const B=u[x].lineId,N=e.editRemiInitialDetails.lineDetailSection[B]?.lineDetail?.account?.qboId;u[x].outOfPocket.account.selectedOption=N,u[x].outOfPocket.isRetainedCategorySelected=!1}else h.includes("outOfPocket.account")&&(u[x].outOfPocket.recommendations.length>0&&(u[x].outOfPocket.recommendedAccount=u[x].outOfPocket.recommendations[0].account),u[x].outOfPocket.recommendedAccount?.qboId!=null&&u[x].outOfPocket.account.selectedOption===u[x].outOfPocket.recommendedAccount?.qboId?u[x].outOfPocket.isCategoryUpdateSelected=!0:u[x].outOfPocket.isCategoryUpdateSelected=!1,u[x].outOfPocket.retainedAccount?.qboId!=null&&u[x].outOfPocket.account.selectedOption===u[x].outOfPocket.retainedAccount?.qboId?u[x].outOfPocket.isRetainedCategorySelected=!0:u[x].outOfPocket.isRetainedCategorySelected=!1,u[x].outOfPocket.isCategoryFirstTimeAutofilled=!1);const vt=ti({...T,lineInfo:u},e.merchantList.merchants,r,ne,e.currencyConversionStatus,e.allCurrencies,e.accountList.accounts,e.classList.classes);if(he?.(vt),h.includes("outOfPocket.merchant")){const B=u[x].lineId,N=u[x].outOfPocket.merchant.selectedOption??"";u[x].outOfPocket.merchant.allOptions.find(be=>be===N)!=null?_(N,B):Y(N,B)}},yi=$.useMemo(()=>Ci((h,T)=>Pn(h,T),300),[e.accountList.fetchState,e.classList.fetchState,e.merchantList.fetchState]);$.useEffect(()=>{const h=ve.watch((T,{name:u})=>{u!=null&&T!=null&&yi(u,T)});return()=>{h.unsubscribe()}},[yi,ve]),$.useEffect(()=>{const h=ee.reduceAnyFetchState(Object.values(e.currencyConversionStatus)),T=h.fetchState==="In-Progress"||h.fetchState==="Error";Ge(T)},[e.currencyConversionStatus]),$.useEffect(()=>{for(const T in e.currencyConversionStatus){const u=e.lineDetailSection[T],x=e.lineDetailSection[T];e.currencyConversionStatus[T].fetchState==="Completed"&&x!=null&&u.type!==y.mileageKey&&!tn(u?.homeCurrencyConversions,x.homeCurrencyConversions)&&J({amount:u?.homeCurrencyConversions?.amount??0,currencyCode:u?.homeCurrencyConversions?.currencyCode??Me,currencySymbol:u?.homeCurrencyConversions?.currencySymbol??Tt},T,b)}const h=ei(e.lineDetailSection,e.currencyConversionStatus);ne!==h&&it(h)},[e.currencyConversionStatus,e.lineDetailSection]),$.useEffect(()=>{(e.saveStatus?.fetchState==="Completed"||e.deleteStatus.fetchState==="Completed")&&(we(b),le?.())},[e.saveStatus?.fetchState,e.deleteStatus.fetchState,b,we,le]);const O=Ie(),[je,pt]=$.useState(b==null),[ht,Rn]=$.useState(1),[On,Ft]=$.useState(!1),[Ln,An]=$.useState(""),[Et,zn]=$.useState(null),[Bn,nt]=$.useState(!1),[Mn,bi]=$.useState(!1),[Nt,Wt]=$.useState([]),[ce,St]=$.useState({title:"",description:"",primaryButtonText:"",secondaryButtonText:""}),Fn=$.useRef(Ci((h,T)=>Ne(h,T),500,{trailing:!0})).current;$.useEffect(()=>{tt==="In-Progress"&&(e.uploadStatus==="Completed"?(ve.reset(Qt(e,r,s),{keepDefaultValues:!0}),Te(!1),pt(!1)):e.uploadStatus==="Error"&&Te(!1))},[tt,e.uploadStatus,ve,e,He,Te,je,r,s,S]),$.useEffect(()=>{e.uploadStatus==="In-Progress"&&je===!1&&Te(!0)},[e.uploadStatus,Te,je]);const Ut=e.remiStage==="draft"?y.newReimbursementTitle:y.editReimbursementTitle,En={onOkClick:()=>{if(nt(!1),ce.primaryButtonText===y.buttons.discard)we(b),e.remiStage==="draft"?le?.():Oe?.();else if(ce.primaryButtonText===y.buttons.delete)ce.title===y.deleteBankAccountTitle?De?.(Ln):R?.();else if(ce.primaryButtonText===y.buttons.yes&&Et!=null){const h=Nt.filter(T=>T!==ht.toString());Wt(h),H(Et,ht,!0)}},onCancelClick:()=>{if(nt(!1),ce.secondaryButtonText===y.buttons.no){const h=Nt.filter(T=>T!==ht.toString());Wt(h),H(Et,ht,!1)}}},fi=()=>{z||co(jn)?(St({title:y.discardTitle,description:y.discardDescription,primaryButtonText:y.buttons.discard,secondaryButtonText:y.buttons.cancel}),nt(!0)):(we(b),le?.())},Nn=()=>{St({title:e.remiStage==="draft"?y.deleteDraftTitle:y.deleteReportTitle,description:y.deleteAlertDescription,primaryButtonText:y.buttons.delete,secondaryButtonText:y.buttons.cancel}),nt(!0)},Wn=h=>{An(h),St({title:y.deleteBankAccountTitle,description:y.deleteBankAccountDescription,primaryButtonText:y.buttons.delete,secondaryButtonText:y.buttons.cancel}),nt(!0)},Un=()=>{St({title:y.overwriteTitle,description:y.overwriteDescription,primaryButtonText:y.buttons.yes,secondaryButtonText:y.buttons.no}),nt(!0)},Vn=()=>{let h=!0;const T=[];return Object.values(e.lineDetailSection).forEach((u,x)=>{u.type===y.outOfPocketKey&&$n(u)>=75&&u.file==null&&(T.push(u.lineId),h=!1)}),Wt(T),h},xi=()=>{if(m&&e.remiStage==="pending_approval"&&e.remiStatus!=="rejected")fi();else if(e.whatForSection.reportTitle!=null&&e.whatForSection.reportTitle.length>0){Ke("save");const h=ve.getValues(),T=ti(h,e.merchantList.merchants,r,ne,e.currencyConversionStatus,e.allCurrencies,e.accountList.accounts,e.classList.classes);he?.(T),ie(e.remiStatus==="rejected"?"pending_approval":"draft")}else ve.trigger(`${Lt}.reportTitle`,{shouldFocus:!0})};let Vt=!1;Object.values(e.addRemiAutoFieldsByLineId).forEach(h=>{h.length>0&&(Vt=!0)});let wi=[];if(e.remiId==null){const h=ne??0;h>0&&(wi=e.approvalRules.allApprovalRules?.filter(T=>{const u=T.criteria[0].range;if(u.max!=null){if(u.min.amount<h&&u.max.amount>=h)return T}else if(u.min.amount<h)return T;return null}).map(T=>({...T,stepsWithStatus:T.steps.map(u=>({...u,actorsActivity:[],isOriginalApprovalStep:!0})),isRealTimeApprovalEnabled:!1})))}const _n=h=>{const T=Vn();return ve.handleSubmit(()=>{T&&(Ke("submit"),S?.trackReimbursementSubmitReimbursement(e.createTime?.format(Yi.analytics.MMMDashDDDashYYYYFormat)??ee.dateNow().format(Yi.analytics.MMMDashDDDashYYYYFormat),r.currencyCode,ne,b),E(),bi(!0))})(h)},Hn=()=>{const h=ve.getValues(),T=ti(h,e.merchantList.merchants,r,ne,e.currencyConversionStatus,e.allCurrencies,e.accountList.accounts,e.classList.classes);he?.(T),Q()},qn=e.reimbursementInfo?.billStatus.code=="approved"&&e.reimbursementInfo?.billPaymentStatus.code?e.reimbursementInfo?.billPaymentStatus:e.reimbursementInfo?.billStatus,Kn=e.reimbursementInfo?.paymentDate!=null?ee.zeniDate(ee.getNextNthWorkingDay(e.reimbursementInfo.paymentDate.toDate(),[0,6],e.achSameDayMaxDays).toDateString()):void 0,Gn=e.reimbursementInfo?.expectedDepositDate??Kn,Yn=b!=null&&e.remiStage==="draft",Si=Ro(e.duplicateLineByLineId),_t=e.duplicateReimbursementStatus.fetchState==="Completed"&&Si>0,{requestToOpenThread:Ht,setRequestToOpenThread:vi,setOpenThread:qt}=$.useContext(Xn),{threads:gt,isLoading:Ye}=Qn({application:"dashboard",companyId:ke.currentTenant?.companyId,tab:"reimbursement",entityId:b,isGlobalComment:!1},"both",!1);$.useEffect(()=>{Ht?.threadId!=null&>.length>0&&!Ye&&(qt(Ht.threadId),vi(null))},[Ht,gt,Ye,qt,vi]);const Jn=$.useMemo(()=>b==null?[]:gt.filter(h=>h.resolved===!1&&!h.id.includes(eo)),[gt,b]).length,Zn=(h,T)=>{qt(T);const u=h.entityType.split("."),x=parseInt(u[2]);if(isNaN(x)){ae(!1);return}const vt=`${x+1}`,B=e.lineDetailSection[x+1].type;u.includes(y.mileageKey)&&B===y.outOfPocketKey?re(ee.toReimbursementTypeCode(y.mileageKey),vt,b):u.includes(y.outOfPocketKey)&&B===y.mileageKey&&re(ee.toReimbursementTypeCode(y.outOfPocketKey),vt,b),ae(!1)};return t.jsx(Rr,{ref:W,children:t.jsx(to,{sharedItems:{sharedFunctions:void 0,sharedRef:{contentWrapperRef:et.current??null}},children:t.jsxs(nn,{...ve,children:[t.jsx("form",{id:Zi(Ji),onSubmit:h=>_n(h),children:t.jsxs(rl,{windowSize:O,ref:et,children:[Bn?t.jsx(li,{titleComponent:t.jsx(an,{children:ce.title}),descriptionComponent:t.jsx(on,{children:ce.description}),primaryButtonText:ce.primaryButtonText,secondaryButtonText:ce.secondaryButtonText,action:En,proceedButtonVariant:ce.title===y.deleteBankAccountTitle||ce.title===y.deleteDraftTitle||ce.title===y.deleteReportTitle||ce.title===y.discardTitle?"danger":"primary",isEditPopup:ce.title===y.deleteBankAccountTitle}):null,Mn?t.jsx(fr,{reimbursementId:b,submitFetchState:e.saveStatus?.fetchState??"Not-Started",duplicateReimbursementStatus:e.duplicateReimbursementStatus.fetchState,hasDuplicateLine:_t,numberOfDuplicateLines:Si,setShowDuplicatePopup:bi,submitReport:Hn,fetchDuplicateReimbursement:I,clearDuplicateReimbursementDetail:E,clearRemiSaveStatus:te,analytics:S}):null,He?t.jsx(Qi,{windowSize:O}):null,je?t.jsxs(Qi,{windowSize:O,"data-testid":q("skip-autofill-section"),children:[O==="small"?t.jsxs(t.Fragment,{children:[t.jsx(Vr,{children:t.jsx(oi,{partOfSkipAutoFill:!0,size:O,onClick:()=>pt(!1),"data-testid":q("close-invoice-upload"),children:t.jsx(ni,{withOverlay:!0,children:t.jsx(ii,{})})})}),t.jsx(Hr,{children:Ut})]}):null,t.jsx(xn,{showAutofill:je,analytics:S,onSkipAutofill:()=>{S?.trackReimbursementSkipAutofill(),pt(!1)},uploadInvoiceEndPoint:p,authParams:o,style:{width:X.leftSectionWidth.valuePercentage(O),boxSizing:"border-box",backgroundColor:O==="small"?We.colors.grey4:"unset",padding:O==="small"?`${i.sp5} ${i.sp3}`:`78px ${i.sp6} 15px ${i.sp8}`,margin:O==="small"?i.sp0:void 0},onInvoiceUpload:h=>H(h,ht,!0),dropFilePlaceholder:{upload:y.dropReceipt.upload,single:y.dropReceipt.single,or:y.dropReceipt.or,multiple:y.dropReceipt.multiple,receipts:y.dropReceipt.receipts},updateInvoiceUploadFetchState:Le,showInfoText:!1,allowMultiFiles:je,type:"receipt"}),O!=="small"?t.jsx(_r,{children:t.jsx(oi,{partOfSkipAutoFill:!0,onClick:()=>pt(!1),"data-testid":q("close-invoice-upload"),children:t.jsx(ni,{withOverlay:!0,children:t.jsx(ii,{})})})}):null]}):null,t.jsxs(tl,{windowSize:O,"data-testid":q("edit-reimbursement-detail-page-nav-bar-container"),children:[O!=="small"?t.jsx(ki,{style:{width:"42%"},"data-testid":q("edit-reimbursement-detail-page-left-nav-bar"),title:"",leftSideComponent:t.jsx(il,{"data-testid":q("zeni-logo-spend-management-reimbursement-detail-page"),onClick:se}),enableTitleOnScroll:!1,scrollableContent:W,backgroundColor:We.colors.background,keepBackgroundOnScroll:!0,source:"EditReimbursementDetailPage"}):null,O!=="small"?t.jsx(Or,{}):null,t.jsx(ki,{style:{width:X.navBarWidth.valuePercentage(O)},"data-testid":q("edit-reimbursement-detail-page-right-nav-bar"),source:"EditReimbursementDetailPage",title:Ut,leftSideComponent:t.jsx(t.Fragment,{}),rightSideComponent:je!=!0?t.jsxs(nl,{children:[C&&b!=null?t.jsxs(ol,{isDisabled:Ye,"data-testid":q("remi-comment-button"),onClick:Ye?()=>null:h=>{h.preventDefault(),h.stopPropagation(),mt({roomId:wt,companyId:ke.currentTenant?.companyId??"",companyName:ke.currentTenant?.companyName??"",entityType:"reimbursement.details",entityId:b}),ae(!0),S?.trackCommentActivity("reimbursement","clicked",ke.currentTenant?.companyName??"",ke.controllersList.controllers.map(T=>no(T)),void 0,void 0,"page icon")},children:[t.jsx(io,{count:Ye?void 0:Jn,isLoading:Ye,style:{left:"12px"}}),t.jsx(al,{})]}):null,t.jsx(oi,{size:O,onClick:()=>fi(),"data-testid":q("close-nav-bar"),children:t.jsx(ni,{withOverlay:!1,children:t.jsx(ii,{})})})]}):null,enableTitleOnScroll:O!=="small",scrollThreshold:64,scrollableContent:W,backgroundColor:We.colors.grey4})]}),O==="small"?t.jsxs(t.Fragment,{children:[t.jsx(el,{children:Ut}),t.jsx(oo,{progressSectionObj:qn,createDate:e.createTime,paymentDate:Gn,scheduleDate:e.reimbursementInfo?.paymentDate,approvedDate:e.latestApprovedDate,isBillUploaded:b!=null?!0:e.uploadStatus==="Completed"}),Vt&&t.jsxs(Gr,{children:[t.jsx(Kr,{}),t.jsx(Yr,{children:y.banner})]}),e.isProcessing?t.jsx(rn,{variant:"warning",style:{margin:O==="small"?`${i.sp5} ${i.sp3}`:`${i.sp3} ${i.sp8} ${i.sp3} ${i.sp6}`},title:Gi.duplicateWarning.title,description:Gi.duplicateWarning.description}):_t?t.jsxs(Jr,{size:O,children:[t.jsx(Br,{}),t.jsxs(Xr,{children:[t.jsx(Zr,{children:y.thereSeems}),t.jsx(Qr,{children:y.pleaseFind})]})]}):null,t.jsx(vn,{isReimbursementCommentingEnabled:C,sectionId:Lt,reimbursementId:e.remiId,reportTitle:e.whatForSection.reportTitle})]}):null,t.jsx(Ka,{onDuplicateLineClick:A,reimbursementId:b,remiDetails:e,uploadInvoiceEndPoint:p,authParams:o,showSkipAutoFill:je,setShowSkipAutoFill:pt,isReimbursementCommentingEnabled:C,isAutoFieldsExist:Vt,totalAmount:ne,removeFileFromLine:ge,onReplaceClick:Un,onReceiptsUpload:H,currencyConversionStatus:e.currencyConversionStatus,setCurrentLineIdForUpload:Rn,setUploadedReceiptPayload:zn,updateInvoiceUploadFetchState:Le,clearTentativeNameForLine:Ae,defaultCurrency:r,companyMileageConfigInfo:d,isUserAdmin:m,setShowBankAccountPage:Ft,bankAccounts:s,onDeleteBankAccount:Wn,analytics:S,fileRequiredLineIds:Nt,isSignedInUserReimbursementCreator:g,uncategorizedAccounts:w,showTotalAmountLoader:ut,duplicateLineByLineId:e.duplicateLineByLineId,hasDuplicateLine:_t,removeDuplicateReimbursementForLine:pe,scrollContainerRef:W}),t.jsxs(ll,{showSkipAutoFill:je,windowSize:O,children:[O!=="small"?t.jsx(Xi,{}):null,t.jsx(sl,{windowSize:O,children:t.jsxs(cl,{windowSize:O,children:[e.remiId!==void 0&&t.jsx(Ii,{amount:ne??0,activities:e.remiActivities,stage:e.remiStage??"draft",onAddNewRule:Se,entity:"reimbursement",historicActivities:e.remiHistory.activities}),e.remiId==null&&ne!=null&&ne>0?t.jsx(Ii,{amount:ne??0,activities:wi,stage:"draft",entity:"reimbursement",historicActivities:e.remiHistory.activities}):null]})})]}),t.jsx(dl,{}),t.jsxs(qr,{showSkipAutoFill:je,windowSize:O,children:[O!=="small"?t.jsx(Xi,{}):null,t.jsx(Lr,{windowSize:O,onClick:h=>{h.stopPropagation(),Ue===!0&&Ve(!1)},children:t.jsx(ln,{formId:Zi(Ji),separatorStyle:{marginRight:i.sp4},showCancel:g,cancelBtn:{label:m&&e.remiStage==="pending_approval"&&e.remiStatus!=="rejected"?O==="small"?y.buttons.discard:y.buttons.discardChanges:O==="small"?y.buttons.save:y.buttons.saveChanges,isLoading:qe==="save"&&e.saveStatus?.fetchState==="In-Progress",onClick:xi,style:{width:X.footerButtonWidth.value(O)},reverseSpinnerColor:!1},primaryBtn:{label:Pr(g,m,e,O),isDisabled:!g,style:{width:g?X.footerButtonWidth.value(O):"auto"},type:g?"submit":"button",onClick:g?()=>null:xi,isLoading:!g&&qe==="save"&&e.saveStatus?.fetchState==="In-Progress"},rightSideComponent:t.jsx(Ar,{children:t.jsxs(Nr,{windowSize:O,children:[Ue?t.jsx(sn,{onClickAway:()=>Ve(!1),children:t.jsx(Er,{windowSize:O,"data-testid":q("remi-other-actions-container"),children:t.jsx(Wr,{onClick:Nn,"data-testid":q("delete-report-action"),children:y.buttons.deleteReport})})}):null,t.jsx(Fr,{windowSize:O,children:Yn===!0?t.jsx(Mr,{windowSize:O,"data-testid":q("more-details-button"),children:t.jsx(zr,{onClick:()=>Ve(!Ue)})}):null})]})}),style:{minHeight:62}})})]}),C&&b!=null?t.jsx(Po,{id:wt,children:t.jsx(ao,{isDrawerOpen:F,allowComposer:!0,drawerTitle:$r,threads:gt,autoExpand:!0,autoFocus:!1,filter:{application:"dashboard",companyId:U?.companyId??Cr,isGlobalComment:!1,tab:"reimbursement"},isLoading:Ye,threadMetadata:U?{companyName:U.companyName,companyId:U.companyId,entityId:U.entityId,entityType:U.entityType,isGlobalComment:!1,application:"dashboard",tab:"reimbursement",url:window.location.href}:void 0,textOverrides:{composerPlaceholder:kr,replyComposerPlaceholder:Ir,threadResolve:Dr,threadUnResolve:Tr},onThreadClick:(h,T)=>Zn(h,T),onCloseAllThreadsDrawer:()=>ae(!1),drawerSectionStyle:{width:"400px",backgroundColor:We.colors.background}})}):null]})}),On?t.jsx(Ur,{windowSize:O,children:t.jsx(rr,{bankAccountCreationState:k,setShowBankAccountPage:Ft,plaidConnectionDetails:l,onFetchLinkTokenClick:ze,onEstablishConnectionClick:ye,onSaveHandler:L,bankAccountToCreate:P,bankNameByRouting:f,fetchBankNameByRoutingStatus:D,onUserBankDetailsUpdated:v,onFetchBankName:K,onBackClick:()=>{dt(),Ft(!1)}})}):null]})})})},Pr=(e,o,r,d)=>e?r.reimbursementId!=null&&r.remiStage==="pending_approval"?y.buttons.resubmit:y.buttons.submit:o&&r.remiStage==="pending_approval"&&r.remiStatus!=="rejected"?d==="small"?y.buttons.discard:y.buttons.discardChanges:d==="small"?y.buttons.save:y.buttons.saveChanges,Rr=n.div`
|
|
620
620
|
position: relative;
|
|
621
621
|
height: 100vh;
|
|
622
622
|
overflow-y: scroll;
|
|
@@ -631,7 +631,7 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
631
631
|
pointer-events: none;
|
|
632
632
|
z-index: 3;
|
|
633
633
|
`,Lr=n.div`
|
|
634
|
-
width: ${e=>
|
|
634
|
+
width: ${e=>X.rightSectionWidth.valuePercentage(e.windowSize)};
|
|
635
635
|
`,Ar=n.div`
|
|
636
636
|
display: flex;
|
|
637
637
|
justify-content: flex-end;
|
|
@@ -671,17 +671,17 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
671
671
|
padding-top: ${i.sp1};
|
|
672
672
|
padding-bottom: ${i.sp1};
|
|
673
673
|
position: absolute;
|
|
674
|
-
bottom: ${e=>
|
|
674
|
+
bottom: ${e=>X.otherActionsContainerBottom.valuePx(e.windowSize)};
|
|
675
675
|
z-index: 3;
|
|
676
676
|
border: ${e=>`1px solid ${e.theme.colors.grey3}`};
|
|
677
677
|
border-radius: ${i.sp1};
|
|
678
|
-
right: ${e=>
|
|
678
|
+
right: ${e=>X.right.valuePx(e.windowSize)};
|
|
679
679
|
box-shadow: ${e=>`${i.sp0} 2px ${i.sp1} ${e.theme.colors.grey1} 3D`};
|
|
680
680
|
`,Nr=n.div`
|
|
681
681
|
width: 100%;
|
|
682
682
|
justify-content: flex-end;
|
|
683
683
|
position: ${e=>e.windowSize==="small"?"static":"relative"};
|
|
684
|
-
right: ${e=>
|
|
684
|
+
right: ${e=>X.actionsContainerRight.valuePx(e.windowSize)};
|
|
685
685
|
height: 100%;
|
|
686
686
|
display: flex;
|
|
687
687
|
`,Wr=n(mi)`
|
|
@@ -701,7 +701,7 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
701
701
|
height: 100vh;
|
|
702
702
|
position: fixed;
|
|
703
703
|
background: ${e=>e.theme.colors.grey4};
|
|
704
|
-
width: ${e=>
|
|
704
|
+
width: ${e=>X.rightSectionWidth.valuePercentage(e.windowSize)};
|
|
705
705
|
right: 0;
|
|
706
706
|
top: 0;
|
|
707
707
|
`,Vr=n.div`
|
|
@@ -716,15 +716,15 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
716
716
|
padding: ${i.sp3} ${i.sp3} 0 ${i.sp3};
|
|
717
717
|
background: ${e=>e.theme.colors.grey4};
|
|
718
718
|
color: ${e=>e.theme.colors.primary};
|
|
719
|
-
`,
|
|
719
|
+
`,qr=n.div`
|
|
720
720
|
display: ${e=>e.windowSize==="small"&&e.showSkipAutoFill?"none":"flex"};
|
|
721
721
|
width: 100%;
|
|
722
722
|
position: fixed;
|
|
723
723
|
bottom: 0;
|
|
724
724
|
z-index: 3;
|
|
725
|
-
`,
|
|
725
|
+
`,Xi=n.div`
|
|
726
726
|
width: 42%;
|
|
727
|
-
`,
|
|
727
|
+
`,Kr=n(di)`
|
|
728
728
|
color: ${e=>e.theme.colors.primary};
|
|
729
729
|
width: ${i.sp3};
|
|
730
730
|
height: ${i.sp3};
|
|
@@ -744,23 +744,23 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
744
744
|
padding: ${i.sp3};
|
|
745
745
|
border-radius: ${i.sp2};
|
|
746
746
|
align-items: start;
|
|
747
|
-
margin-top: ${e=>
|
|
748
|
-
margin-right: ${e=>
|
|
749
|
-
margin-bottom: ${e=>
|
|
750
|
-
margin-left: ${e=>
|
|
747
|
+
margin-top: ${e=>X.duplicateBannerWrapperMarginTop.valuePx(e.size)};
|
|
748
|
+
margin-right: ${e=>X.duplicateBannerWrapperMarginRight.valuePx(e.size)};
|
|
749
|
+
margin-bottom: ${e=>X.duplicateBannerWrapperMarginBottom.valuePx(e.size)};
|
|
750
|
+
margin-left: ${e=>X.duplicateBannerWrapperMarginLeft.valuePx(e.size)};
|
|
751
751
|
background-color: ${j.alertLight};
|
|
752
752
|
border: 1px solid ${e=>e.theme.colors.brandColorGoldDark};
|
|
753
|
-
`,
|
|
753
|
+
`,Zr=n(Mt)`
|
|
754
754
|
color: ${e=>e.theme.colors.brandColorGoldDark};
|
|
755
|
-
`,
|
|
755
|
+
`,Xr=n.div`
|
|
756
756
|
width: 100%;
|
|
757
|
-
`,
|
|
757
|
+
`,Qr=n(hi)`
|
|
758
758
|
color: ${e=>e.theme.colors.brandColorGoldDark};
|
|
759
759
|
`,el=n(ci)`
|
|
760
760
|
letter-spacing: -0.02em;
|
|
761
761
|
color: ${e=>e.theme.colors.primary};
|
|
762
762
|
margin: ${i.sp3};
|
|
763
|
-
`,
|
|
763
|
+
`,Qi=n.div`
|
|
764
764
|
display: flex;
|
|
765
765
|
flex-direction: ${e=>e.windowSize==="small"?"column":"row"};
|
|
766
766
|
height: 100vh;
|
|
@@ -796,7 +796,7 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
796
796
|
color: ${e=>e.withOverlay?j.primaryDark:e.theme.colors.primary};
|
|
797
797
|
}
|
|
798
798
|
`,nl=n.div`
|
|
799
|
-
margin-top: ${e=>
|
|
799
|
+
margin-top: ${e=>X.closeMarginTop.valuePx(e.windowSize)};
|
|
800
800
|
display: flex;
|
|
801
801
|
float: right;
|
|
802
802
|
`,ol=n.div`
|
|
@@ -817,9 +817,9 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
817
817
|
align-items: center;
|
|
818
818
|
justify-content: center;
|
|
819
819
|
`,oi=n.div`
|
|
820
|
-
margin-top: ${e=>e.partOfSkipAutoFill===!0?
|
|
820
|
+
margin-top: ${e=>e.partOfSkipAutoFill===!0?X.closeMarginTop.valuePx(e.size):0};
|
|
821
821
|
margin-left: ${i.sp5};
|
|
822
|
-
margin-right: ${e=>e.partOfSkipAutoFill===!0?
|
|
822
|
+
margin-right: ${e=>e.partOfSkipAutoFill===!0?X.closeMarginRight.valuePx(e.size):0};
|
|
823
823
|
`,rl=n.div`
|
|
824
824
|
display: flex;
|
|
825
825
|
flex-direction: column;
|
|
@@ -852,14 +852,14 @@ import{a1 as ai,u as bt,t as ft,a as en,z as Ci,l as ee,M as me,H as tn,X as Ie,
|
|
|
852
852
|
`,ll=n.div`
|
|
853
853
|
display: ${e=>e.windowSize==="small"&&e.showSkipAutoFill?"none":"flex"};
|
|
854
854
|
width: 100%;
|
|
855
|
-
margin-bottom: ${e=>
|
|
855
|
+
margin-bottom: ${e=>X.bottomMargin.valuePx(e.windowSize)};
|
|
856
856
|
`,sl=n.div`
|
|
857
|
-
width: ${e=>
|
|
857
|
+
width: ${e=>X.rightSectionWidth.valuePercentage(e.windowSize)};
|
|
858
858
|
`,cl=n.div`
|
|
859
|
-
margin-left: ${e=>
|
|
860
|
-
margin-right: ${e=>
|
|
859
|
+
margin-left: ${e=>X.leftMargin.valuePx(e.windowSize)};
|
|
860
|
+
margin-right: ${e=>X.rightMargin.valuePx(e.windowSize)};
|
|
861
861
|
`,dl=n.div`
|
|
862
862
|
display: flex;
|
|
863
863
|
flex-direction: column;
|
|
864
864
|
height: ${i.sp11};
|
|
865
|
-
`;export{Pl as default,
|
|
865
|
+
`;export{Pl as default,Zi as uniqueName};
|