@zeniai/web-app-ui 5.3.67-dev → 5.3.68-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/{AccountMappingScreen-NREHTMQ1.js → AccountMappingScreen-DSZj_uCQ.js} +2 -2
- package/dist/assets/{ActualMatchingMatchDetailScreen-ZfOyWL5F.js → ActualMatchingMatchDetailScreen-BQRgUBiV.js} +1 -1
- package/dist/assets/AddressRoutes-BC4juuf4.js +1 -0
- package/dist/assets/{AddressScreen-CB5BRM9y.js → AddressScreen-BQYkT2m3.js} +2 -2
- package/dist/assets/{AiCfoScreen-HyI4GQCb.js → AiCfoScreen-DNMX1_2h.js} +1 -1
- package/dist/assets/{AppDrawer-BasRiDQ4.js → AppDrawer-BpkkZZ__.js} +1 -1
- package/dist/assets/{BillPayApprovalRoutes-XdVdW0PG.js → BillPayApprovalRoutes-DJXolFor.js} +1 -1
- package/dist/assets/{BillPayRoutes-BbZifdx_.js → BillPayRoutes-Bwj63a_R.js} +18 -18
- package/dist/assets/BusinessVerificationPageScreen-D3H22Ycs.js +9 -0
- package/dist/assets/{CardsAiCfoScreen-Csz8lSCn.js → CardsAiCfoScreen-_x1fFH7I.js} +1 -1
- package/dist/assets/{ChargeCardRoutes-D2v71o2S.js → ChargeCardRoutes-Dd0GuLnx.js} +1 -1
- package/dist/assets/CompanyPassportScreen-lZWEIVDl.js +1 -0
- package/dist/assets/ConnectionAuthScreen-ue9LJgbU.js +11 -0
- package/dist/assets/CustomerOnboardingAuthScreen-6IBywESu.js +1 -0
- package/dist/assets/{CustomerOnboardingRoutes-DYEVoKvU.js → CustomerOnboardingRoutes-C5hH9_2G.js} +3 -3
- package/dist/assets/{DashboardRoutes-bD-NpO4n.js → DashboardRoutes-DEtQqaVs.js} +3 -3
- package/dist/assets/{DefaultTenantHome-CqzOdGZK.js → DefaultTenantHome-CCyE91GO.js} +1 -1
- package/dist/assets/{DomesticWireDetailScreen-C5k3DT9m.js → DomesticWireDetailScreen-B2C3yRyz.js} +4 -4
- package/dist/assets/{DrawerScreen-Dvp_bzzQ.js → DrawerScreen-CVgBvegK.js} +1 -1
- package/dist/assets/EntityDetailRoutes-BxIXjZHN.js +1 -0
- package/dist/assets/{ExpenseAutomationRoutes-IJIfqkj-.js → ExpenseAutomationRoutes-Kn5gQkyW.js} +7 -7
- package/dist/assets/FeaturePreviewScreen-CsKi-5Np.js +1 -0
- package/dist/assets/HubSpotOAuthCallbackScreen-CSdvQVKy.js +1 -0
- package/dist/assets/{InboxNotificationsProvider-CxBkh6GM.js → InboxNotificationsProvider-BLd671md.js} +1 -1
- package/dist/assets/{InvoicingRoutes-BDyr12_i.js → InvoicingRoutes-BkO_wRtc.js} +2 -2
- package/dist/assets/{MagicLinkRoutes-qLSg0r1Z.js → MagicLinkRoutes-BFQMSIdk.js} +6 -6
- package/dist/assets/MagicLinkSignInScreen-DNABK1wd.js +12 -0
- package/dist/assets/{MobileAppDrawer-C8UsE0YH.js → MobileAppDrawer-CUkRGmov.js} +1 -1
- package/dist/assets/NotFoundScreen-DcIIEjdb.js +1 -0
- package/dist/assets/{NotificationRoutes-D4O9EUNW.js → NotificationRoutes-BDrKKRmf.js} +1 -1
- package/dist/assets/OAuthConsentScreen-BfqQ59Hm.js +1 -0
- package/dist/assets/PandLWithForecastRoutes-BM_Kx0Gi.js +1 -0
- package/dist/assets/{PaymentLinkScreen-CS1xqYIt.js → PaymentLinkScreen-oDUUM_rp.js} +9 -9
- package/dist/assets/PeopleRoutes-CLcQG2z8.js +22 -0
- package/dist/assets/PerformanceRoutes-ZkTu6xdk.js +1 -0
- package/dist/assets/{Preview-C0e56SfV.js → Preview-DjryQabZ.js} +1 -1
- package/dist/assets/{QBOConnectionScreen-6U4C9EuT.js → QBOConnectionScreen-CC1mgdSE.js} +1 -1
- package/dist/assets/ReimbursementApprovalRoutes-DqdHGUab.js +1 -0
- package/dist/assets/{ReimbursementApprovalRuleDetailScreen-ZM1Aw-_i.js → ReimbursementApprovalRuleDetailScreen-DGkJ20Az.js} +1 -1
- package/dist/assets/{ReimbursementRoutes-DPiReCXE.js → ReimbursementRoutes-CwIONxFo.js} +7 -7
- package/dist/assets/{ReportsRoutes-Cf01mfIk.js → ReportsRoutes-DVA33cfE.js} +1 -1
- package/dist/assets/RewardsRoutes-wgZH1oXi.js +1 -0
- package/dist/assets/{ScheduleDetailsPrepaidExpensesScreen-CuO3_SI4.js → ScheduleDetailsPrepaidExpensesScreen-BVhDF7k2.js} +5 -5
- package/dist/assets/ScreenRoutes-BIW4o9AI.js +2 -0
- package/dist/assets/{SettingsRoutes-D4kzb4To.js → SettingsRoutes-B2D7KOAB.js} +6 -6
- package/dist/assets/SetupPagesScreen-BVuXxhDx.js +29 -0
- package/dist/assets/SignInScreen-CmC92pbo.js +1 -0
- package/dist/assets/SignOutScreen-CyRRVOip.js +9 -0
- package/dist/assets/{TaskListScreen-DhMAwdLm.js → TaskListScreen-BbBcN7pH.js} +2 -2
- package/dist/assets/TaskRoutes-YYUAqa-i.js +9 -0
- package/dist/assets/TransactionDetailRoutes-45rDqVHh.js +1 -0
- package/dist/assets/{TransactionDetailScreen-CCYZhbpM.js → TransactionDetailScreen-Cqrtgoki.js} +2 -2
- package/dist/assets/TransactionListRoutes-BfvppQmn.js +1 -0
- package/dist/assets/{TreasuryRoutes-BjdfZTjc.js → TreasuryRoutes-DJXblfti.js} +5 -5
- package/dist/assets/{VendorsRoutes-X9IFemZr.js → VendorsRoutes-iqjJ6KwN.js} +11 -11
- package/dist/assets/WiseConfirmationScreen-CdA1V-kW.js +12 -0
- package/dist/assets/{ZeniAccountRoutes-Cwkn0zT6.js → ZeniAccountRoutes-CRqmMO-M.js} +11 -11
- package/dist/assets/ZeniAccountStatementScreen-Ds7h68QG.js +9 -0
- package/dist/assets/{accountMappingHelper-42mDzLtR.js → accountMappingHelper-DDpt4thU.js} +1 -1
- package/dist/assets/{analytics-CmKkcxmz.js → analytics-HUGlc_YA.js} +1 -1
- package/dist/assets/analyticsHelper-C858uUp8.js +1 -0
- package/dist/assets/{core-pDUZcPB0.js → core-BAlzhg_1.js} +1 -1
- package/dist/assets/{decodeURIComponentSafe-DBYvBfqM.js → decodeURIComponentSafe-BlS7R_TX.js} +1 -1
- package/dist/assets/{dnd-Bslfq-ku.js → dnd-CtBfGkHE.js} +1 -1
- package/dist/assets/{empty-COUJOkyp.js → empty-BRHFv2sW.js} +1 -1
- package/dist/assets/{empty-ChYivft5.js → empty-Bi7Yf941.js} +1 -1
- package/dist/assets/{emptyVideoElement-DkcKVFUD.js → emptyVideoElement-63TR5aDR.js} +1 -1
- package/dist/assets/epic-ucHpX8wh.js +2 -0
- package/dist/assets/expenseAutomationHelper-D89gAMsk.js +1 -0
- package/dist/assets/{getLocaleForTenant-0mV5x3GU.js → getLocaleForTenant-D_cnKwPq.js} +1 -1
- package/dist/assets/{index-DElaqJ7F.js → index-1u2aDJ3l.js} +17658 -17581
- package/dist/assets/{index-C7P994Rq.js → index-BvIRHYdj.js} +1 -1
- package/dist/assets/{index-DCm9kFzB.js → index-C3vxNQm5.js} +1 -1
- package/dist/assets/{index-BsYuRUyP.js → index-CGTcDwKM.js} +1 -1
- package/dist/assets/{index-DDEprezU.js → index-CWRZ55RL.js} +1 -1
- package/dist/assets/{index-DF1xpOd3.js → index-DGpWyM9Y.js} +1 -1
- package/dist/assets/{index-BqEm26lC.js → index-Df4gn8fh.js} +2 -2
- package/dist/assets/{index-BL3wAHTU.js → index-DuPam2hY.js} +1 -1
- package/dist/assets/{lexical-BMD9Skdu.js → lexical-CpUvnOjl.js} +1 -1
- package/dist/assets/{liveblocks-BLPKVqHo.js → liveblocks-Cmn0IneY.js} +1 -1
- package/dist/assets/{lottie-DWJdupW0.js → lottie-CqVjxmYG.js} +1 -1
- package/dist/assets/{mui-BiqpQr6x.js → mui-BP68m4Fu.js} +1 -1
- package/dist/assets/{pathToGoBack-Bl5vJY_-.js → pathToGoBack-WCSQSILz.js} +1 -1
- package/dist/assets/{pdf-B3souC9z.js → pdf-DVoBxypI.js} +3 -3
- package/dist/assets/{pdf-lib-qMo5mrxo.js → pdf-lib-CfwiSXQl.js} +1 -1
- package/dist/assets/{plaid-BXFY-KIk.js → plaid-D_c1UYI3.js} +1 -1
- package/dist/assets/{pusher-DEaV-Zmd.js → pusher-HOxR7Sbp.js} +1 -1
- package/dist/assets/{react-B88SuQgy.js → react-AUOblSvr.js} +1 -1
- package/dist/assets/{react-DnL-jdtH.js → react-C7Adach0.js} +1 -1
- package/dist/assets/{react-0LIbF3KH.js → react-CAp25EsP.js} +1 -1
- package/dist/assets/{react-CJK0LLCw.js → react-Deo915rj.js} +1 -1
- package/dist/assets/{react--S1-ZiQC.js → react-DxMuJXc7.js} +1 -1
- package/dist/assets/{react-B1Ev53Dd.js → react-S7mn4-ov.js} +1 -1
- package/dist/assets/{recharts-Dg9FaaKY.js → recharts-BDERfoBp.js} +1 -1
- package/dist/assets/{routePaths-KJ0Mf_VR.js → routePaths-DSGBDygY.js} +1 -1
- package/dist/assets/{sentry-BYwRJ99F.js → sentry-D-L93P51.js} +1 -1
- package/dist/assets/{stripSplatSuffix-5xMPsJCi.js → stripSplatSuffix--MOgwIwN.js} +1 -1
- package/dist/assets/{url-BHkvYei3.js → url-BDV8gAHg.js} +1 -1
- package/dist/assets/{url-BlXMXHHv.js → url-D0vuH2sS.js} +1 -1
- package/dist/assets/useActualMatchingMatchDetail-BbZiVOuy.js +1 -0
- package/dist/assets/{useAiCfoDashboardSuggestedQuestionsChips-DtXjJJR9.js → useAiCfoDashboardSuggestedQuestionsChips-CLtV2UPA.js} +1 -1
- package/dist/assets/useAskAiCfoHostNavButtonProps-bvl6a2jc.js +1 -0
- package/dist/assets/{useChargeCardPusherEvents-B8oEFskx.js → useChargeCardPusherEvents-00JeET2P.js} +1 -1
- package/dist/assets/{useDeviceId-D1mK-mWi.js → useDeviceId-BjLcJw5r.js} +1 -1
- package/dist/assets/useEmailConnectResultRefresh-BfM5did4.js +1 -0
- package/dist/assets/{useInitialThreadRequest-BWnJWIOJ.js → useInitialThreadRequest-BujZmxW_.js} +1 -1
- package/dist/assets/useTaskManagerAccess-EuL6L5n0.js +1 -0
- package/dist/assets/{useTaskManagerPusherEvents-P3ZIbHSQ.js → useTaskManagerPusherEvents-C8CQ-n2I.js} +1 -1
- package/dist/assets/{utils-CJY4ogMD.js → utils-DrMX637r.js} +1 -1
- package/dist/assets/{withTransactionSidePanel-EmB6Lhe6.js → withTransactionSidePanel-B22s9Gp7.js} +5 -5
- package/dist/assets/{zeni-epic-state-Bke7DGFg.js → zeni-epic-state-CGi26_dN.js} +3 -3
- package/dist/index.html +1 -1
- package/package.json +3 -3
- package/dist/assets/AddressRoutes-D8ARdNLG.js +0 -1
- package/dist/assets/BusinessVerificationPageScreen-gGCsmsgi.js +0 -9
- package/dist/assets/CompanyPassportScreen-CwpDDfL0.js +0 -1
- package/dist/assets/ConnectionAuthScreen-BRB9fe2c.js +0 -11
- package/dist/assets/CustomerOnboardingAuthScreen-B-5iE_q3.js +0 -1
- package/dist/assets/EntityDetailRoutes-DTAUvz4h.js +0 -1
- package/dist/assets/FeaturePreviewScreen-Y3cKkUSF.js +0 -1
- package/dist/assets/HubSpotOAuthCallbackScreen-Jq8q5AT8.js +0 -1
- package/dist/assets/MagicLinkSignInScreen-_gduvnj0.js +0 -12
- package/dist/assets/NotFoundScreen-rNNJF3rA.js +0 -1
- package/dist/assets/OAuthConsentScreen-DyVkStLe.js +0 -1
- package/dist/assets/PandLWithForecastRoutes-Cij2SWS4.js +0 -1
- package/dist/assets/PeopleRoutes-DjY-_8xS.js +0 -22
- package/dist/assets/PerformanceRoutes-BGY0_n-J.js +0 -1
- package/dist/assets/ReimbursementApprovalRoutes-DY5FrgK2.js +0 -1
- package/dist/assets/RewardsRoutes-cPzFd3Pi.js +0 -1
- package/dist/assets/ScreenRoutes-BbEWtCht.js +0 -2
- package/dist/assets/SetupPagesScreen-DJ1w7kWs.js +0 -29
- package/dist/assets/SignInScreen-CCevyTCf.js +0 -1
- package/dist/assets/SignOutScreen-D7saoktq.js +0 -9
- package/dist/assets/TaskRoutes-CgC8VN7O.js +0 -9
- package/dist/assets/TransactionDetailRoutes-B6e8aJoM.js +0 -1
- package/dist/assets/TransactionListRoutes-BmQiF0V2.js +0 -1
- package/dist/assets/WiseConfirmationScreen-Bw63j9Jj.js +0 -12
- package/dist/assets/ZeniAccountStatementScreen-Bm0CaqwY.js +0 -9
- package/dist/assets/analyticsHelper-CT62vOeP.js +0 -1
- package/dist/assets/epic-YDmGQkJ8.js +0 -2
- package/dist/assets/expenseAutomationHelper-pbEk9tHa.js +0 -1
- package/dist/assets/useActualMatchingMatchDetail-Bs6gwQjf.js +0 -1
- package/dist/assets/useAskAiCfoHostNavButtonProps-BEEGOqdG.js +0 -1
- package/dist/assets/useEmailConnectResultRefresh-C0yzwvmf.js +0 -1
- package/dist/assets/useTaskManagerAccess-BpKEGOBZ.js +0 -1
package/dist/index.html
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
<!DOCTYPE html><html lang="en"><head><meta http-equiv="cache-control" content="no-cache, no-store, must-revalidate"><meta http-equiv="expires" content="0"><meta http-equiv="pragma" content="no-cache"><meta charset="UTF-8"><link rel="icon" type="image/svg+xml" href="/assets/favicon-D56XvgAH.ico"><meta name="ROBOTS" content="NOINDEX, NOFOLLOW"><meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1"><meta name="theme-color" content="#000000"><meta name="description" content="Zeni - Modern Finance Team For Startups"><link rel="preconnect" href="https://fonts.googleapis.com"><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin><link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Roboto:wght@100;300;400;500;700;900&family=Manrope:wght@200..800&display=swap"><link rel="apple-touch-icon" href="/assets/logo192-CqcTe-t4.png"><link rel="manifest" href="/assets/manifest-icT4lOF5.json"><title>Zeni - Modern Finance Team For Startups</title><script src="/theme-detect.js"></script><style>:root{--logo-color-from:#D4DCDD;--logo-color-to:#E9F0F0;--bar-color-from:#E9F0F0;--bar-color-to:#D4DCDD;--sidebar-bg:#F3F7F7;--main-bg:#FAFCFC;--divider-color:#D4DCDD}html{background-color:#f3f7f7}html[data-theme=dark]{background-color:#1b1c1c;--logo-color-from:#545B5C;--logo-color-to:#3E4343;--bar-color-from:#3E4343;--bar-color-to:#545B5C;--sidebar-bg:#1B1C1C;--main-bg:#202222;--divider-color:#545B5C}.app-shell-loader{position:fixed;inset:0;display:flex;background-color:var(--sidebar-bg);z-index:9999}.app-shell-sidebar{width:210px;flex-shrink:0;background-color:var(--sidebar-bg);padding:16px 16px 0;display:flex;flex-direction:column;gap:36px;border-right:1px solid var(--divider-color);box-sizing:border-box}.app-shell-sidebar-group{display:flex;flex-direction:column;gap:10px}.app-shell-bar{height:10px;border-radius:5px;background-color:var(--bar-color-from);animation:app-shell-bar-shimmer 1.6s linear infinite}.app-shell-navbar{height:56px;display:flex;flex-direction:row;border-bottom:1px solid var(--divider-color);padding:0 32px;align-items:center;justify-content:space-between;box-sizing:border-box}@keyframes app-shell-bar-shimmer{0%,100%{background-color:var(--bar-color-from)}50%{background-color:var(--bar-color-to)}}.app-shell-main{flex:1;background-color:var(--main-bg)}.app-shell-logo{display:inline-flex;width:100%;height:calc(100vh - 56px);justify-content:center;align-items:center}.app-shell-logo svg path{animation:app-shell-color-cycle 1.6s linear infinite}@keyframes app-shell-color-cycle{0%,100%{fill:var(--logo-color-from)}50%{fill:var(--logo-color-to)}}@media (max-width:899px){.app-shell-sidebar{display:none}.app-shell-main{background-color:var(--sidebar-bg)}}</style><noscript><style>.app-shell-loader{display:none}</style></noscript><script async type="module" crossorigin src="/assets/index-
|
|
1
|
+
<!DOCTYPE html><html lang="en"><head><meta http-equiv="cache-control" content="no-cache, no-store, must-revalidate"><meta http-equiv="expires" content="0"><meta http-equiv="pragma" content="no-cache"><meta charset="UTF-8"><link rel="icon" type="image/svg+xml" href="/assets/favicon-D56XvgAH.ico"><meta name="ROBOTS" content="NOINDEX, NOFOLLOW"><meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1"><meta name="theme-color" content="#000000"><meta name="description" content="Zeni - Modern Finance Team For Startups"><link rel="preconnect" href="https://fonts.googleapis.com"><link rel="preconnect" href="https://fonts.gstatic.com" crossorigin><link rel="stylesheet" href="https://fonts.googleapis.com/css2?family=Roboto:wght@100;300;400;500;700;900&family=Manrope:wght@200..800&display=swap"><link rel="apple-touch-icon" href="/assets/logo192-CqcTe-t4.png"><link rel="manifest" href="/assets/manifest-icT4lOF5.json"><title>Zeni - Modern Finance Team For Startups</title><script src="/theme-detect.js"></script><style>:root{--logo-color-from:#D4DCDD;--logo-color-to:#E9F0F0;--bar-color-from:#E9F0F0;--bar-color-to:#D4DCDD;--sidebar-bg:#F3F7F7;--main-bg:#FAFCFC;--divider-color:#D4DCDD}html{background-color:#f3f7f7}html[data-theme=dark]{background-color:#1b1c1c;--logo-color-from:#545B5C;--logo-color-to:#3E4343;--bar-color-from:#3E4343;--bar-color-to:#545B5C;--sidebar-bg:#1B1C1C;--main-bg:#202222;--divider-color:#545B5C}.app-shell-loader{position:fixed;inset:0;display:flex;background-color:var(--sidebar-bg);z-index:9999}.app-shell-sidebar{width:210px;flex-shrink:0;background-color:var(--sidebar-bg);padding:16px 16px 0;display:flex;flex-direction:column;gap:36px;border-right:1px solid var(--divider-color);box-sizing:border-box}.app-shell-sidebar-group{display:flex;flex-direction:column;gap:10px}.app-shell-bar{height:10px;border-radius:5px;background-color:var(--bar-color-from);animation:app-shell-bar-shimmer 1.6s linear infinite}.app-shell-navbar{height:56px;display:flex;flex-direction:row;border-bottom:1px solid var(--divider-color);padding:0 32px;align-items:center;justify-content:space-between;box-sizing:border-box}@keyframes app-shell-bar-shimmer{0%,100%{background-color:var(--bar-color-from)}50%{background-color:var(--bar-color-to)}}.app-shell-main{flex:1;background-color:var(--main-bg)}.app-shell-logo{display:inline-flex;width:100%;height:calc(100vh - 56px);justify-content:center;align-items:center}.app-shell-logo svg path{animation:app-shell-color-cycle 1.6s linear infinite}@keyframes app-shell-color-cycle{0%,100%{fill:var(--logo-color-from)}50%{fill:var(--logo-color-to)}}@media (max-width:899px){.app-shell-sidebar{display:none}.app-shell-main{background-color:var(--sidebar-bg)}}</style><noscript><style>.app-shell-loader{display:none}</style></noscript><script async type="module" crossorigin src="/assets/index-1u2aDJ3l.js"></script><link rel="modulepreload" crossorigin href="/assets/sentry-D-L93P51.js"><link rel="modulepreload" crossorigin href="/assets/core-BAlzhg_1.js"><link rel="modulepreload" crossorigin href="/assets/zeni-epic-state-CGi26_dN.js"><link rel="modulepreload" crossorigin href="/assets/mui-BP68m4Fu.js"><link rel="modulepreload" crossorigin href="/assets/analytics-HUGlc_YA.js"><link rel="modulepreload" crossorigin href="/assets/utils-DrMX637r.js"><link rel="stylesheet" crossorigin href="/assets/index-BhC2LNQw.css"></head><body style="margin:0"><noscript>You need to enable JavaScript to run this app.</noscript><div id="root"></div><div class="app-shell-loader" id="app-shell-loader"><div class="app-shell-sidebar"><div class="app-shell-sidebar-group"><div class="app-shell-bar zeni-logo" style="width:96px;height:20px"></div></div><div class="app-shell-sidebar-group"><div class="app-shell-bar" style="width:55px;height:12px"></div><div class="app-shell-bar" style="width:78px;height:16px"></div><div class="app-shell-bar" style="width:46px;height:16px"></div></div><div class="app-shell-sidebar-group"><div class="app-shell-bar" style="width:55px;height:12px"></div><div class="app-shell-bar" style="width:110px;height:16px"></div><div class="app-shell-bar" style="width:84px;height:16px"></div></div><div class="app-shell-sidebar-group"><div class="app-shell-bar" style="width:55px;height:12px"></div><div class="app-shell-bar" style="width:84px;height:16px"></div><div class="app-shell-bar" style="width:64px;height:16px"></div></div></div><div class="app-shell-main"><div class="app-shell-navbar"><div class="app-shell-bar" style="width:106px;height:27px"></div><div class="app-shell-bar" style="width:111px;height:32px"></div></div><div class="app-shell-logo"><svg width="96" height="96" viewBox="0 0 24 24" fill="none" xmlns="http://www.w3.org/2000/svg"><path d="M16.768 0.0270284C16.571 -0.055168 16.348 0.0572476 16.2913 0.267574C16.2713 0.342517 16.2489 0.417461 16.2253 0.491196C16.0094 1.15723 15.6459 1.76645 15.148 2.27776C14.3056 3.14203 13.1847 3.61949 11.9918 3.6207H11.9883C10.7978 3.6207 9.67689 3.14565 8.83445 2.2838C8.33653 1.7737 7.97077 1.16448 7.75367 0.499657C7.73007 0.425922 7.70765 0.350979 7.68641 0.276035C7.62978 0.065709 7.40678 -0.0454978 7.20974 0.0366985C6.05463 0.522624 4.98565 1.17899 4.0323 1.97436C3.91195 2.07468 3.87301 2.24512 3.93083 2.39259C3.9792 2.51589 4.03112 2.63797 4.08539 2.75764C4.51133 3.70894 5.10364 4.5853 5.84815 5.34682C7.48937 7.0246 9.66863 7.9493 11.9871 7.9493H11.9954C14.3162 7.94689 16.4978 7.01855 18.1379 5.33595C18.8812 4.57321 19.4711 3.69564 19.8959 2.74434C19.9502 2.62347 20.0009 2.50138 20.0493 2.37809C20.1071 2.23062 20.0682 2.06018 19.9478 1.95985C18.9933 1.16569 17.9231 0.511745 16.768 0.0270284Z"/><path d="M19.9102 21.2422C19.4843 20.2933 18.8931 19.4194 18.151 18.6603C16.5086 16.9801 14.3223 16.053 12.0038 16.0578C8.50304 16.0614 5.48371 18.1961 4.11031 21.2603C4.05722 21.38 4.0053 21.5009 3.95575 21.623C3.89675 21.7704 3.93569 21.9421 4.05722 22.0436C5.01175 22.8366 6.08073 23.4893 7.23466 23.9728C7.4317 24.055 7.65352 23.9438 7.71134 23.7335C7.73139 23.6573 7.75381 23.5836 7.77859 23.5086C8.37207 21.6979 10.0416 20.3888 12.0073 20.3864H12.012C13.2025 20.3864 14.3234 20.8614 15.1659 21.7233C15.6626 22.231 16.026 22.8378 16.2431 23.5002C16.2679 23.5739 16.2903 23.6489 16.3104 23.7238C16.3682 23.9341 16.59 24.0453 16.787 23.9619C17.9422 23.476 19.01 22.8209 19.9633 22.0255C20.0837 21.9252 20.1226 21.7535 20.0648 21.606C20.0164 21.4828 19.9645 21.3631 19.9102 21.2422Z"/><path d="M0.132148 10.1666C0.158105 9.98769 0.305591 9.85352 0.482575 9.85352L23.5093 9.81726C23.6863 9.81726 23.8338 9.95022 23.8609 10.1291C23.9518 10.7347 23.999 11.3548 23.999 11.9858C24.0001 12.6131 23.9541 13.2284 23.8668 13.8292C23.8408 14.0081 23.6934 14.1422 23.5164 14.1422L0.489654 14.1773C0.312671 14.1773 0.165185 14.0443 0.138047 13.8654C0.0471956 13.2598 0 12.6397 0 12.0088C0 11.3826 0.0448358 10.7673 0.132148 10.1666Z"/></svg></div></div></div></body></html>
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@zeniai/web-app-ui",
|
|
3
|
-
"version": "5.3.
|
|
3
|
+
"version": "5.3.68-dev",
|
|
4
4
|
"files": [
|
|
5
5
|
"dist/**/*"
|
|
6
6
|
],
|
|
@@ -29,8 +29,8 @@
|
|
|
29
29
|
"@sentry/react": "^9.42.1",
|
|
30
30
|
"@stripe/stripe-js": "^4.4.0",
|
|
31
31
|
"@zeniai/client-analytics": "2.0.96",
|
|
32
|
-
"@zeniai/client-epic-state": "5.2.
|
|
33
|
-
"@zeniai/web-components": "4.4.
|
|
32
|
+
"@zeniai/client-epic-state": "5.2.66",
|
|
33
|
+
"@zeniai/web-components": "4.4.7",
|
|
34
34
|
"color": "3.1.3",
|
|
35
35
|
"crypto-js": "4.2.0",
|
|
36
36
|
"dnd-core": "^16.0.1",
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as e}from"./liveblocks-BLPKVqHo.js";import{A as i}from"./AddressScreen-CB5BRM9y.js";import s from"./NotFoundScreen-rNNJF3rA.js";import"./sentry-BYwRJ99F.js";import{n as d,o as r}from"./core-pDUZcPB0.js";import"./zeni-epic-state-Bke7DGFg.js";import"./recharts-Dg9FaaKY.js";import"./index-DElaqJ7F.js";import"./mui-BiqpQr6x.js";import"./analytics-CmKkcxmz.js";import"./plaid-BXFY-KIk.js";import"./dnd-Bslfq-ku.js";import"./stripe-cKAAJElX.js";import"./lottie-DWJdupW0.js";import"./lexical-BMD9Skdu.js";import"./pdf-B3souC9z.js";import"./utils-CJY4ogMD.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},o=new t.Error().stack;o&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[o]="81cbb5c1-1b56-4d87-a240-ae6c03b91825",t._sentryDebugIdIdentifier="sentry-dbid-81cbb5c1-1b56-4d87-a240-ae6c03b91825")}catch{}})();function _(){return e.jsxs(d,{children:[e.jsx(r,{path:"/edit/:addressType/:addressId",element:e.jsx(i,{})}),e.jsx(r,{path:"/new/:addressType",element:e.jsx(i,{})}),e.jsx(r,{path:"*",element:e.jsx(s,{})})]})}export{_ as default};
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import{a as V}from"./sentry-BYwRJ99F.js";import{u as G,j as T,h as ne,g as se,i as oe,N as ie,l as re}from"./core-pDUZcPB0.js";import{fI as z,HL as ce,Zh as ue,BK as de,Ss as pe,HZ as le,L9 as me,NY as fe,OC as ye,Pr as Se,Zi as ge,Zj as Ie,Zk as he,Zl as Te,Zm as be,Vw as De,Yn as Oe,VL as Ce,Md as ke,VM as Ve,Mh as we,mK as Ae,gJ as Ne,gI as Fe,gH as _e,v1 as ve,uU as xe,uR as Be,mC as Ee,BT as ze,BR as R,bF as L,C3 as P,cF as Re}from"./zeni-epic-state-Bke7DGFg.js";import{bT as Le,_ as Pe,c as Me,bi as Ue,z as E,a8 as je,j as M,r as x,T as B,bV as Ze,ae as Ge,p as U,aG as j}from"./index-DElaqJ7F.js";import{n as He}from"./mui-BiqpQr6x.js";import{j as k}from"./liveblocks-BLPKVqHo.js";import{d as Z}from"./routePaths-KJ0Mf_VR.js";import{M as qe}from"./MobileAppDrawer-C8UsE0YH.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},u=new t.Error().stack;u&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[u]="679a6f59-7ff7-4783-8dad-c1e70900daf1",t._sentryDebugIdIdentifier="sentry-dbid-679a6f59-7ff7-4783-8dad-c1e70900daf1")}catch{}})();function nt(){const t=G(),u=T((r=>z(r))),n=u?.tenantId,{isApprovalRulesV3Enabled:i,isLoading:d}=Le(n),p=T((r=>r.billPaySetupApproverViewState.fetchState));V.useEffect((()=>{n==null||d||p==="Not-Started"&&t(ce(!0,!0,i))}),[n,d,i,p,t])}const Ke=He.div`
|
|
2
|
-
display: flex;
|
|
3
|
-
min-height: 100%;
|
|
4
|
-
width: 100%;
|
|
5
|
-
flex: 1 1 auto;
|
|
6
|
-
flex-direction: column;
|
|
7
|
-
align-items: center;
|
|
8
|
-
background-color: ${t=>t.theme.colors.grey4};
|
|
9
|
-
`,Ye=re((function(t,u){const{businessVerificationDetails:n}=u,i=z(t),d=E.getSignedInUser(),p=i.tenantId,r={userId:d?.userId??"",sessionId:d?.zeniSessionId??"",tenantId:p??""},b=De(u.roleMap)&&n.updateStatus.fetchState!=="In-Progress"?void 0:"readonly",e=Oe(t.companyConfigState),s=Ce(t.userRoleConfigState);return{businessVerificationDetails:n,verficationDetailsFetchState:n.fetchState,isRefreshingViewInBackground:n.isRefreshingViewInBackground,allNationalityCountries:n.allNationalityCountries,filesEndPoint:`${Ge.fileMicroServiceBaseUrl}`,authParams:r,isDisabled:b,allIndustries:e.companyIndustries??[],companyTitles:s.companyTitles}}),(function(t,u){const{companyId:n,productType:i,currentTenant:d,navigate:p,location:r}=u,{tenantEmailDomain:b}=d;return{onCompanyDetailsChanged:e=>{const{companyDescription:s,companyIndustry:m,companyIndustryType:O,companyLegalName:C,companyTaxId:g,companyWebsite:y,companyPhone:I,primaryContactEmail:c,primaryContactName:o,primaryContactUserId:l,primaryContactSyncToken:D,syncToken:S,fileIds:a,incDate:f,typeOfIncorporation:w,stateOfIncorporation:A,sourceOfFunds:N,companySubIndustry:F,countriesOfOperations:h,companySourceOfFunds:H,companySourceOfFundsDescription:q,transactionVolume:K,transactionVolumeDescription:Y,purposeOfAccount:$,purposeOfAccountDescription:J,regulatedStatus:W,regulatedStatusDescription:Q,usNexus:X,usNexusTypes:ee}=e,_=O?.selectedOption,te={companyId:n,companyDescription:s,companyIndustry:m.selectedOption,companyIndustryType:_==null||_===""?void 0:_,companyLegalName:C,taxIdOrEIN:g,website:y!=""&&y!=null?Re(y):void 0,phone:I,syncToken:S,fileIds:a,incDate:f!=null?L(f?.toString()):f,typeOfIncorporation:w?.selectedOption??"",stateOfIncorporation:A?.selectedOption??"",sourceOfFunds:N?.selectedOption??"",companySubIndustry:F?.selectedOption??"",countriesOfOperations:h?.selectedOptions.map((v=>v.length===2?v:j(v)))??[],companySourceOfFunds:H?.selectedOption??"",companySourceOfFundsDescription:q,transactionVolume:K?.selectedOption??"",transactionVolumeDescription:Y,purposeOfAccount:$?.selectedOption??"",purposeOfAccountDescription:J,regulatedStatus:W??"",regulatedStatusDescription:Q,usNexus:X,usNexusTypes:ee?.selectedOptions??[]},ae={userId:l,firstName:o.firstName,lastName:o.lastName,email:c,syncToken:D};t(P({companyDetails:te,primaryContactDetails:ae}))},onCompanyOfficerUpdated:e=>{const s=e.map((m=>{const{officerType:O,userId:C,name:g,email:y,nationalityCountryCode:I,ssn:c,dob:o,phone:l,syncToken:D,selectDocument:S,role:a,ownership:f,isSelectedForVerification:w,userVerificationStatus:A,treasuryUserVerificationStatus:N,fileIds:F}=m;let h;return S.selectDocumentType==="driverLicense"?h="driving_license":S.selectDocumentType==="passport"?h="passport":S.selectDocumentType==="stateId"?h="id_document":S.selectDocumentType==="ssnCard"&&(h="social_security_card"),{officerType:O,userId:C,firstName:g.firstName,lastName:g.lastName,email:y,ssn:c,nationalityCountryCode:I?.selectedOption!=null?j(I.selectedOption):void 0,phone:l,birthday:o!=null?L(o?.toString()):o,syncToken:D,titleAtCompany:a.selectedOption,ownershipInCompany:f,documentTypeSelectedForVerification:h,isSelectedForVerification:w,userVerificationStatus:A,treasuryUserVerificationStatus:N,fileIds:F,additionalDocumentTypesRequestedForVerification:[],additionalSubmittedDocumentsForVerificationFileIds:[],areAdditionalDocumentsRequestedForVerification:!1,areAdditionalDocumentsSubmittedForVerification:!1}}));t(P({officers:s}))},onSaveDetailsClick:e=>{t(R(n,e,i))},onSendForVerificationClick:e=>{t(R(n,e,i,!0))},onAddressClick:e=>{const s=Z(b,e),m=U(r.state?.pathnameStackToGoBack,r.pathname);p(s,{state:{pathnameStackToGoBack:m}})},onRegisteredAddressClick:e=>{const s=Z(b,e),m=U(r.state?.pathnameStackToGoBack,r.pathname);p(s,{state:{pathnameStackToGoBack:m}})},onBackClick:()=>{t(ze({companyId:n})),p("../setup")},updateFilesEntity:e=>{t(Ee({files:e}))},onDeleteFile:e=>{t(Be(e))},onDeleteFileList:e=>{t(xe(e))},onEditFileName:(e,s)=>{t(ve(e,s.split(".")[0]))},onGetOtp:e=>{t(_e(e,"SpendManagementSetup"))},onResendOtp:e=>{t(Fe(e,"SpendManagementSetup"))},onVerifyOtp:(e,s)=>{t(Ne(e,s,"SpendManagementSetup"))},saveNewAddressInLocalStore:(e,s)=>{t(Ae({addressType:e,addressToCreate:s}))},onIdentityDocumentUploadedForAutofill:e=>{if(n==null)return;const s=Ve(e.documentType);s!=null&&t(we({target:"setup",companyId:n,officerType:e.officerType,fileId:e.fileId,documentType:s}))},onCompanyDocumentUploadedForAutofill:e=>{n!=null&&t(ke({target:"setup",companyId:n,fileId:e.fileId,documentType:e.documentType}))}}}))(Ze),st=({productType:t})=>{const u=ne(),n=se(),i=G(),[d,p]=V.useState(!1),[r,b]=V.useState(!1),{tenantEmailDomain:e}=oe(),s=Pe(),{useDynamicConfig:m}=Me(),{configValue:O}=m(Ue.zeniAccountsConfig),C=ue(O),g=T((a=>{switch(t){case"zeni_accounts":return a.zeniAccountSetupViewState.fetchState;case"reimbursement":return a.remiSetupViewState.fetchState;case"charge_cards":return a.chargeCardSetupViewState.fetchState;case"zeni_treasury":return a.treasurySetupViewState.fetchState;default:return a.billPaySetupViewState.fetchState}})),y=T((a=>a.companyConfigState.fetchState)),I=T((a=>a.userRoleConfigState.fetchState)),c=T((a=>z(a))),o=c.companyId??E.getSignedInUserTenant(e)?.companyId;if(V.useEffect((()=>{y==="Not-Started"&&i(de()),I==="Not-Started"&&i(pe(!0))}),[y,I,i]),V.useEffect((()=>{if(!d&&g==="Not-Started"&&o!=null)switch(p(!0),t){case"zeni_accounts":i(Se(o,!0));break;case"zeni_treasury":i(ye(o,!0));break;case"reimbursement":i(fe(o,!0));break;case"charge_cards":i(me(o,!0));break;default:i(le(o,!0))}}),[d,g,o,i]),E.getSignedInUser()==null)throw Error("Can't access business verification without signing in...");let l;switch(t){case"zeni_accounts":l=c.companyZeniAccountInfo?.info?.isZeniAccountTOSAccepted;break;case"reimbursement":l=c.companyReimbursementInfo?.info?.isReimbursementTOSAccepted;break;case"charge_cards":l=c.companyChargeCardInfo?.info?.isChargeCardTOSAccepted===!0||c.companyDebitCardInfo?.info?.isDebitCardTOSAccepted;break;case"zeni_treasury":l=c.companyTreasuryInfo?.info?.isTreasuryTOSAccepted;break;default:l=c.companyBillPayInfo?.info?.isBillPayTOSAccepted}const D=a=>{b(a)},S=T((a=>{switch(t){case"zeni_accounts":return be(a,o);case"zeni_treasury":return Te(a,o);case"charge_cards":return he(a,o);case"reimbursement":return Ie(a,o);default:return ge(a,o)}}));return l===!1?k.jsx(ie,{to:"../promo"}):k.jsxs(Ke,{children:[k.jsx(je,{analytics:M,onLoad:a=>(f=>{switch(t){case"zeni_accounts":return f.trackPageLoaded(B.Event.zeniAccountsBusinessVerification);case"reimbursement":case"charge_cards":return f.trackPageLoaded(B.Event.reimbursementBusinessVerification);default:return f.trackPageLoaded(B.Event.billPayBusinessVerification,x(n)?"Settings":void 0)}})(a)}),x(n)?k.jsx(qe,{isAppContentDrawerOpen:r,handleDrawerToggle:D}):null,k.jsx(Ye,{businessVerificationDetails:S,navigate:u,location:n,companyId:o,analytics:M,currentTenant:c,productType:t,isSettings:x(n),roleMap:s?.loggedInUserRoleMap??{},onClickMenuIcon:()=>{D(!0)},maxInsuredAmount:C.maxInsuredAmount})]})};export{st as B,nt as u};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as m}from"./liveblocks-BLPKVqHo.js";import{a as g}from"./sentry-BYwRJ99F.js";import{h as w,u as T,g as x,i as k,j as b,l as E}from"./core-pDUZcPB0.js";import{z as N,bs as F,a8 as P,j as V,T as j,r as O,bt as L,ae as A,aG as U,p as B}from"./index-DElaqJ7F.js";import{fI as D,gL as G,BK as M,gG as R,c9 as _,Yn as Y,bn as z,v1 as H,uR as K,mC as Z,ob as S,Yo as $,bF as q,cF as C,om as J,ow as Q}from"./zeni-epic-state-Bke7DGFg.js";import"./mui-BiqpQr6x.js";import{d as W}from"./routePaths-KJ0Mf_VR.js";import{M as X}from"./MobileAppDrawer-C8UsE0YH.js";(function(){try{var a=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new a.Error().stack;t&&(a._sentryDebugIds=a._sentryDebugIds||{},a._sentryDebugIds[t]="0f39e074-fa6a-4e21-b0e3-9bd0bbc969a1",a._sentryDebugIdIdentifier="sentry-dbid-0f39e074-fa6a-4e21-b0e3-9bd0bbc969a1")}catch{}})();const ee=E((function(a){const t=R(a),i=N.getSignedInUser(),p=D(a),c=p.tenantId,l={userId:i?.userId??"",sessionId:i?.zeniSessionId??"",tenantId:c??""},f=_(p?.userRole??[])&&t.localData.updateStatus.fetchState!=="In-Progress"?void 0:"readonly",e=Y(a.companyConfigState),n=a.countryListState?.byCountryListCode?.nationalityCountryList?.countries??[];return{isCompanyVerified:t.companyView?.company?.company?.companyBillPayInfo?.companyVerificationStatus?.code==="verified",companyPassportView:t,allIndustries:e.companyIndustries??[],allNationalityCountries:n,isDisabled:f,authParams:l,filesEndPoint:`${A.fileMicroServiceBaseUrl}`,isZeniUser:z(i)}}),(function(a,t){const{companyId:i,currentTenant:p,navigate:c,location:l}=t,{tenantEmailDomain:f}=p;return{onScheduleClick:e=>{let n=e.href;n.includes("http")||(n="https://".concat(n)),window.open(n,"_blank")},onSaveAll:()=>{a(Q())},onAddressClick:e=>{const n=W(f,e),o=B(l.state?.pathnameStackToGoBack,l.pathname);c(n,{state:{pathnameStackToGoBack:o}})},onResetClick:()=>{a(J({companyId:i}))},onBackClick:()=>{c("../")},onCompanyDetailsChanged:e=>{const{companyInfo:n,incInfo:o,taxDetails:r,zeniFinanceTeam:d}=e,{website:u}=n,{meetingLink:y}=d,{incDate:s}=o,{taxesFiledYears:h}=r,v={companyInfo:{...n,website:u!=""&&u!=null?C(u):void 0,meetingLink:y!=""&&y!=null?C(y):void 0,industry:n.industry.selectedOption,companyIndustryType:n.companyIndustryType?.selectedOption??void 0,companySubIndustry:n.companySubIndustry?.selectedOption??void 0,businessModel:n.businessModel.selectedOption??"",companySourceOfFunds:n.companySourceOfFunds?.selectedOption,companySourceOfFundsDescription:n.companySourceOfFundsDescription??void 0,countriesOfOperations:n.countriesOfOperations?.selectedOptions?.map((I=>I.length===2?I:U(I)))??[],transactionVolume:n.transactionVolume?.selectedOption??void 0,transactionVolumeDescription:n.transactionVolumeDescription??void 0,regulatedStatus:n.regulatedStatus??void 0,regulatedStatusDescription:n.regulatedStatusDescription??void 0,usNexus:n.usNexus??void 0,usNexusTypes:n.usNexusTypes?.selectedOptions??[],purposeOfAccount:n.purposeOfAccount?.selectedOption??void 0,purposeOfAccountDescription:n.purposeOfAccountDescription??void 0},incInfo:{typeOfInc:o.typeOfInc.selectedOption??"",stateOfInc:o.stateOfInc.selectedOption??"",incDate:s!=null?q(s?.toString()):s,fileId:o.fileIds[0]},taxDetails:{taxIdOrEIN:r.taxIdOrEIN,sicCode:r.sicCode,naicsCode:r.naicsCode,dunsNumber:r.dunsNumber,taxesFiledYears:h.selectedOptions.map((I=>parseInt(I))),fileId:r.fileIds[0]}};a(S({companyDetails:v}))},onPrimaryContactDetailsUpdated:e=>{a(S({primaryContact:{userId:e.userId,email:e.email.trim(),firstName:e.name.firstName,lastName:e.name.lastName}}))},onNewCompanyOfficerAdded:e=>{a(S({officers:[{officerType:e.officerType,email:e.email.trim(),phone:e.phone,firstName:e.name.firstName,lastName:e.name.lastName,userId:void 0}]}))},onNewCompanyOfficerRemoved:e=>{a($(e))},onCompanyOfficerUpdated:e=>{a(S({officers:[{officerType:e.officerType,email:e.email.trim(),phone:e.phone,firstName:e.name.firstName,lastName:e.name.lastName,userId:e.userId}]}))},updateFilesEntity:e=>{a(Z({files:e}))},onDeleteFile:e=>{a(K(e))},onEditFileName:(e,n)=>{a(H(e,n.split(".")[0]))}}}))(L);function de(){const a=w(),t=T(),i=x(),{tenantEmailDomain:p}=k(),[c,l]=g.useState(!1),[f,e]=g.useState(!1),n=b((s=>s.companyViewState.passportView.fetchState)),o=b((s=>s.companyConfigState.fetchState)),r=b((s=>D(s))),d=r.companyId??N.getSignedInUserTenant(p)?.companyId;if(N.getSignedInUser()==null)throw Error("Can't access company details page without signing in...");g.useEffect((()=>{c||n!=="Not-Started"||d==null||(l(!0),t(G(d)))}),[c,n,d,t]),g.useEffect((()=>{o==="Not-Started"&&t(M())}),[o,t]);const u=s=>{e(s)},y=n==="Not-Started"||n==="In-Progress"||o==="Not-Started"||o==="In-Progress";return d!=null&&n==="Error"?m.jsx(F,{onGoHome:()=>a("../",{replace:!0}),onReload:()=>window.location.reload()}):m.jsxs(m.Fragment,{children:[m.jsx(P,{analytics:V,onLoad:s=>s.trackPageLoaded(j.Event.companyPassport,O(i)?"Settings":"Company Passport")}),O(i)?m.jsx(X,{isAppContentDrawerOpen:f,handleDrawerToggle:u}):null,m.jsx(ee,{companyId:d,navigate:a,location:i,isLoading:y,currentTenant:r,isSettings:O(i),onClickMenuIcon:()=>{u(!0)}})]})}export{de as C};
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import{j as I}from"./liveblocks-BLPKVqHo.js";import{a as o}from"./sentry-BYwRJ99F.js";import{u as F,h as R,g as H,j as C,N as w}from"./core-pDUZcPB0.js";import{U1 as q,fI as z,go as G,pV as V,gP as U,gn as M,gl as Q,Ur as B,gk as A}from"./zeni-epic-state-Bke7DGFg.js";import{u as J,z as E,L as T,G as K,M as W}from"./index-DElaqJ7F.js";import{n as X}from"./mui-BiqpQr6x.js";import{P as h,a as _}from"./AccountMappingScreen-NREHTMQ1.js";import{t as Y}from"./getLocaleForTenant-0mV5x3GU.js";import{g as Z,Q as ee}from"./QBOConnectionScreen-6U4C9EuT.js";import"./recharts-Dg9FaaKY.js";import"./analytics-CmKkcxmz.js";import"./plaid-BXFY-KIk.js";import"./dnd-Bslfq-ku.js";import"./stripe-cKAAJElX.js";import"./lottie-DWJdupW0.js";import"./lexical-BMD9Skdu.js";import"./pdf-B3souC9z.js";import"./utils-CJY4ogMD.js";import"./MobileAppDrawer-C8UsE0YH.js";import"./InboxNotificationsProvider-CxBkh6GM.js";import"./useTaskManagerAccess-BpKEGOBZ.js";import"./accountMappingHelper-42mDzLtR.js";import"./empty-ChYivft5.js";import"./pdf-lib-qMo5mrxo.js";import"./index-DDEprezU.js";import"./url-BlXMXHHv.js";import"./index-C7P994Rq.js";import"./decodeURIComponentSafe-DBYvBfqM.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},i=new t.Error().stack;i&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[i]="763a13dc-2c3c-4656-a8ee-82fc55014cce",t._sentryDebugIdIdentifier="sentry-dbid-763a13dc-2c3c-4656-a8ee-82fc55014cce")}catch{}})();const te=X.div`
|
|
2
|
-
display: flex;
|
|
3
|
-
flex: 1 1 auto;
|
|
4
|
-
flex-direction: row;
|
|
5
|
-
justify-content: center;
|
|
6
|
-
align-items: center;
|
|
7
|
-
width: 100%;
|
|
8
|
-
height: 100vh;
|
|
9
|
-
background-color: ${t=>t.theme.colors.background};
|
|
10
|
-
box-shadow: ${t=>`0px 2px ${W.sp1} ${t.theme.colors.dropShadowNormal}`};
|
|
11
|
-
`;function we(){const t=F(),i=R(),v=H(),{setLoading:d,clearAllLoading:m}=J(),S=o.useRef(!1),x=o.useRef(!1),N=o.useRef(!1),p=o.useRef(!1),{code:O,realmId:$,state:L}=Z(v.search),f=O!==""&&$!==""&&L!=="";f&&(N.current=!0);const j=sessionStorage.getItem(h),u=j===_.pending,P=j===_.ready,y=C((s=>q(s))),e=C((s=>z(s))),n=C((s=>s.tenantState.fetchState)),r=C((s=>s.tenantState.activeTenantFetchState.fetchState)),a=E.getSignedInUser(),g=E.getActiveTenantForUser()?.tenantId,l=e?.externalConnections?.fetchState,c=e?.externalConnections?.saveConnectionState,b=e.externalConnections?.accounting[0]?.isValid;o.useLayoutEffect((()=>{d(T.CONNECTION_AUTH)}),[d]),o.useEffect((()=>{S.current||a==null||g==null||(S.current=!0,n==="Completed"||r!=="Not-Started"&&r!=="Error"||(d(T.TENANT_FETCHING),t(G(a.userId,g))))}),[S,n,d]),o.useEffect((()=>{e.tenantId==null&&!x.current&&a!=null&&(x.current=!0,!(g==null||g!=null&&(r==="Completed"||r==="Error"))||n!=="Not-Started"&&n!=="Error"||t(V(a.userId)))}),[x,n,r]),o.useEffect((()=>{a==null||e?.tenantId==null||e.externalConnections!=null||n!=="Completed"&&r!=="Completed"||l==="In-Progress"||c!=="Error"||(d(T.CONNECTION_AUTH),t(U(a.userId,e.tenantId)))}),[c]),o.useEffect((()=>{n!=="Completed"&&r!=="Completed"||a==null||e?.tenantId==null||(t(M(e.tenantId)),E.saveActiveTenantDomainForUser(e.tenantEmailDomain),Q(a?.userId,a?.zeniSessionId,e.tenantId),K.updateAppLocaleID(Y(B(e))),e.externalConnections!=null||n!=="Completed"&&r!=="Completed"||l==="In-Progress"||a==null||e==null||t(U(a.userId,e.tenantId)))}),[n,r,l]),o.useEffect((()=>{y.tenantsCoreDetailsInOrder.length>0&&n==="Completed"&&E.saveSignedInUserTenants(y.tenantsCoreDetailsInOrder)}),[y.tenantsCoreDetailsInOrder.length,n]);const D=e==null||n!=="Completed"&&r!=="Completed"||l!=="Completed";if(o.useEffect((()=>{n!=="Completed"&&n!=="Error"||r!=="Completed"&&r!=="Error"||l!=="Completed"&&l!=="Error"||m()}),[n,r,l]),o.useEffect((()=>{u&&c==="In-Progress"&&(p.current=!0)}),[u,c]),o.useEffect((()=>{if(!u||D)return;const s=e.tenantEmailDomain!=null?`/${e.tenantEmailDomain}/settings/accounting`:"/";return p.current&&c==="Completed"?(sessionStorage.setItem(h,_.ready),m(),void i(s,{replace:!0})):p.current&&c==="Error"?(sessionStorage.removeItem(h),t(A({messageSection:"accounting_projects_qbo_reconnect_failed",messageText:"failed",type:"error"})),m(),void i(s,{replace:!0})):void(f||N.current||p.current||b!==!0||(sessionStorage.removeItem(h),t(A({messageSection:"accounting_projects_qbo_reconnect_failed",messageText:"failed",type:"error"})),m(),i(s,{replace:!0})))}),[u,D,c,f,b,e.tenantEmailDomain,m,t,i]),D)return null;if(f||b!==!0)return I.jsx(te,{children:I.jsx(ee,{})});if(u)return null;const k=e.tenantEmailDomain!=null?`/${e.tenantEmailDomain}/settings/accounting`:"/";return P?I.jsx(w,{to:k,replace:!0}):I.jsx(w,{to:"/",replace:!0})}export{we as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as i}from"./liveblocks-BLPKVqHo.js";import{z as m}from"./index-DElaqJ7F.js";import{g as n}from"./QBOConnectionScreen-6U4C9EuT.js";import"./sentry-BYwRJ99F.js";import{g as p,N as a}from"./core-pDUZcPB0.js";import"./zeni-epic-state-Bke7DGFg.js";import"./recharts-Dg9FaaKY.js";import"./mui-BiqpQr6x.js";import"./analytics-CmKkcxmz.js";import"./plaid-BXFY-KIk.js";import"./dnd-Bslfq-ku.js";import"./stripe-cKAAJElX.js";import"./lottie-DWJdupW0.js";import"./lexical-BMD9Skdu.js";import"./pdf-B3souC9z.js";import"./utils-CJY4ogMD.js";import"./empty-ChYivft5.js";import"./pdf-lib-qMo5mrxo.js";import"./index-DDEprezU.js";import"./url-BlXMXHHv.js";import"./index-C7P994Rq.js";import"./decodeURIComponentSafe-DBYvBfqM.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},o=new t.Error().stack;o&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[o]="a1205b81-d106-415b-bd92-85aeae53ace3",t._sentryDebugIdIdentifier="sentry-dbid-a1205b81-d106-415b-bd92-85aeae53ace3")}catch{}})();const U=()=>{const t=p(),{code:o,realmId:r,state:e}=n(t.search),s=m.getSignedInUser()?.userId??"";if(f(o,r,e,s)===!0){const d=`../../${e}/onboarding?code=${o}&realmId=${r}&state=auth_flow`;return i.jsx(a,{to:d})}return i.jsx(a,{to:"../../"})},f=(t,o,r,e)=>t!=""&&o!=""&&r!=""&&e!=null&&e!="";export{U as default,f as hasValidParams};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as s}from"./liveblocks-BLPKVqHo.js";import{a as d}from"./sentry-BYwRJ99F.js";import{h as B,u as G,g as A,i as q,j as c,N as F,l as _,n as N,o as O}from"./core-pDUZcPB0.js";import{X3 as R,fI as $,Wk as M,n2 as X,Sl as k,X8 as Y,WZ as z,m2 as V,Sm as S,Wp as Z,Wq as H,W$ as J,W_ as K}from"./zeni-epic-state-Bke7DGFg.js";import{b8 as L,j as Q,a4 as U,p as tt}from"./index-DElaqJ7F.js";import"./mui-BiqpQr6x.js";import{d as b}from"./decodeURIComponentSafe-DBYvBfqM.js";import{w as et}from"./withTransactionSidePanel-EmB6Lhe6.js";import{f as at,c as nt}from"./routePaths-KJ0Mf_VR.js";import"./recharts-Dg9FaaKY.js";import"./analytics-CmKkcxmz.js";import"./plaid-BXFY-KIk.js";import"./dnd-Bslfq-ku.js";import"./stripe-cKAAJElX.js";import"./lottie-DWJdupW0.js";import"./lexical-BMD9Skdu.js";import"./pdf-B3souC9z.js";import"./utils-CJY4ogMD.js";import"./useAskAiCfoHostNavButtonProps-BEEGOqdG.js";import"./TransactionDetailScreen-CCYZhbpM.js";import"./useInitialThreadRequest-BWnJWIOJ.js";import"./expenseAutomationHelper-pbEk9tHa.js";import"./stripSplatSuffix-5xMPsJCi.js";(function(){try{var a=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new a.Error().stack;t&&(a._sentryDebugIds=a._sentryDebugIds||{},a._sentryDebugIds[t]="ca3bb1e9-fa4c-4062-a411-b043bd85351c",a._sentryDebugIdIdentifier="sentry-dbid-ca3bb1e9-fa4c-4062-a411-b043bd85351c")}catch{}})();const ot=_((function(a,t){const e=t.entity,o=Y(a,t.entity,"EntityDetail");return{selectedEntity:e,autoCompleteData:{autoCompleteText:e.name,entityAutoCompleteView:z(a,"common")},trendWithTransactionsReport:o,analytics:Q,isAccountingClassesEnabled:V(a)}}),(function(a,t){return{onTransactionItemClick:e=>{if(t.openTransactionPanel)return void t.openTransactionPanel(e.id,e.type);const o=`${nt(e,t.tenantEmailDomain)}`,l=tt(t.location.state?.pathnameStackToGoBack,t.location.pathname);t.navigate(o,{state:{pathnameStackToGoBack:l}})},autoCompleteActions:{onAutoCompleteInputChange:e=>{e.trim().length>=2?a(J({searchString:e,searchOrigin:"common"})):e.trim().length===0&&a(K("common"))},onAutoCompleteEntity:e=>{const o=at(e,t.tenantEmailDomain);a(Z()),a(H()),t.resetTrendIsFetchedStates(),t.navigate(o,{replace:!0,state:{pathnameStackToGoBack:t.location.state?.pathnameStackToGoBack}})},onCancelAutoComplete:()=>{const e=U(t.location.state?.pathnameStackToGoBack),o=e.poppedPathname??I();t.navigate(o,{state:{pathnameStackToGoBack:e.newStack}})}},onTrendSelectedPeriodChange:e=>{if(t.closeSidePanel?.(),e==null)t.defaultTransactionTimePeriod!=null&&a(S(t.entity,"EntityDetail",{timeframe:"quarter",timePeriod:t.defaultTransactionTimePeriod}));else{const o=e.currentTimePeriod==null?e.addTimePeriod:{startDate:e.addTimePeriod.startDate,endDate:e.currentTimePeriod.endDate};a(k(t.entity,"EntityDetail",{timeframe:e.timeframe,timePeriod:e.addTimePeriod})),a(S(t.entity,"EntityDetail",{timeframe:e.timeframe,timePeriod:o}))}}}}))(L),it=et((function({entityType:a,...t}){const e=B(),o=G(),l=A(),[m,T]=d.useState(!1),[h,D]=d.useState(!1),{tenantEmailDomain:C,entityIdEncoded:x,entityNameEncoded:W}=q(),r=b(x??""),p=b(W??""),u=rt(r,p),j=[r,p].filter((n=>n!=null)),i={name:p,id:r,type:a,zeniId:r,qboId:r},g=c((n=>R(n.customerIncomeState,n.vendorExpenseState,n.trendState,i,"quarter"))),v=c((n=>$(n).company?.companyInfo.firstMonthOfFY??1)),f=c((n=>M(n.trendWithTransactionsState,i,"EntityDetail")));d.useEffect((()=>{m===!1&&u===!0&&(T(!0),o(X(i)))}),[m,u,i]);const E=c((n=>n.trendState.fetchState)),P=f?.selectedPeriod?.timePeriod??g,w=(function(n,y){return n!=null&&y!=null?{startDate:n.startDate,endDate:y?.endDate}:y})(f?.selectedPeriod?.timePeriod,g);return d.useEffect((()=>{m===!0&&h===!1&&E==="Completed"&&(D(!0),P!=null&&o(k(i,"EntityDetail",{timeframe:f?.selectedPeriod?.timeframe??"quarter",timePeriod:P})))}),[m,h,E]),u?s.jsx(ot,{firstMonthOfFY:v,tenantEmailDomain:C,location:l,navigate:e,entity:i,defaultTransactionTimePeriod:w,resetTrendIsFetchedStates:()=>{T(!1),D(!1)},...t}):s.jsx(F,{to:I(j.length)})})),rt=(a,t)=>t!=null&&t.length>0&&a!=null&&a.length>0,I=(a=2)=>{let t="../";for(let e=0;e<a;e++)t=`${t}../`;return t};function vt({entityType:a}){return s.jsx(N,{children:s.jsx(O,{path:"/:entityIdEncoded/:entityNameEncoded/*",element:s.jsx(it,{entityType:a})})})}export{vt as EntityDetailRoutes,vt as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as s}from"./liveblocks-BLPKVqHo.js";import{a as r}from"./sentry-BYwRJ99F.js";import{aw as d,ax as l,s as p,a4 as m}from"./index-DElaqJ7F.js";import"./mui-BiqpQr6x.js";import c from"./NotFoundScreen-rNNJF3rA.js";import{h as u,g as b}from"./core-pDUZcPB0.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},a=new e.Error().stack;a&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[a]="052e3476-042d-44ff-b15b-67fe1524a52f",e._sentryDebugIdIdentifier="sentry-dbid-052e3476-042d-44ff-b15b-67fe1524a52f")}catch{}})();const _=()=>{const e=u(),a=b(),t=r.useCallback((()=>{window.open("https://www.zeni.ai/demo/request","_blank")}),[]),f=r.useCallback((()=>{(()=>{const n=m(a.state?.pathnameStackToGoBack),i=n.poppedPathname??k();e(i,{state:{pathnameStackToGoBack:n.newStack}})})()}),[]),o=d(a.pathname);return o!=null?s.jsx(l,{menuItem:p(o),onDemoClick:t,onGoBack:f}):s.jsx(c,{})},k=(e=2)=>{let a="../";for(let t=0;t<e;t++)a=`${a}../`;return a};export{_ as F};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as r}from"./sentry-BYwRJ99F.js";import{u as l,h as f,g as m}from"./core-pDUZcPB0.js";import{h$ as p,UH as g,UI as b}from"./zeni-epic-state-Bke7DGFg.js";import{u as _,L as h,z as y}from"./index-DElaqJ7F.js";import"./liveblocks-BLPKVqHo.js";import"./recharts-Dg9FaaKY.js";import"./mui-BiqpQr6x.js";import"./analytics-CmKkcxmz.js";import"./plaid-BXFY-KIk.js";import"./dnd-Bslfq-ku.js";import"./stripe-cKAAJElX.js";import"./lottie-DWJdupW0.js";import"./lexical-BMD9Skdu.js";import"./pdf-B3souC9z.js";import"./utils-CJY4ogMD.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},n=new e.Error().stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="cbaf99b7-e770-4476-819d-df693b100290",e._sentryDebugIdIdentifier="sentry-dbid-cbaf99b7-e770-4476-819d-df693b100290")}catch{}})();function R(){const e=l(),n=f(),o=m(),{setLoading:i,clearAllLoading:c}=_(),s=r.useRef(!1);return r.useLayoutEffect((()=>{i(h.CONNECTION_AUTH)}),[i]),r.useEffect((()=>{if(s.current)return;s.current=!0;const a=new URLSearchParams(o.search).get("code"),d=sessionStorage.getItem("hubspot_oauth_pending");if(sessionStorage.removeItem("hubspot_oauth_pending"),a!=null&&d!=null){const t=JSON.parse(d);e(p(t.tenant_id,t.connection_id,g("revenue"),b("hubspot"),{authorization_code:a,client_id:t.client_id,client_secret:t.client_secret,redirect_uri:t.redirect_uri}))}c();const u=y.getActiveTenantForUser();n(u?.tenantEmailDomain!=null?`/${u.tenantEmailDomain}/settings/integrations`:"/",{replace:!0})}),[]),null}export{R as default};
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import{j as u}from"./liveblocks-BLPKVqHo.js";import{a as f}from"./sentry-BYwRJ99F.js";import{u as O,g as w,h as _,t as M,j as l,N as L}from"./core-pDUZcPB0.js";import{z as r,E as P,G as V,S as A,j as N,T as X,X as $,$ as G,U as R}from"./index-DElaqJ7F.js";import{fI as W,U3 as q,Uw as B,Un as H,gl as J,gn as K,Us as Q,gX as Y,dk as Z,Ux as ee,Uy as te}from"./zeni-epic-state-Bke7DGFg.js";import{n as ne}from"./mui-BiqpQr6x.js";import{u as se}from"./useDeviceId-D1mK-mWi.js";import{f as ae}from"./analyticsHelper-CT62vOeP.js";import{t as ie}from"./getLocaleForTenant-0mV5x3GU.js";import"./recharts-Dg9FaaKY.js";import"./analytics-CmKkcxmz.js";import"./plaid-BXFY-KIk.js";import"./dnd-Bslfq-ku.js";import"./stripe-cKAAJElX.js";import"./lottie-DWJdupW0.js";import"./lexical-BMD9Skdu.js";import"./pdf-B3souC9z.js";import"./utils-CJY4ogMD.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},a=new t.Error().stack;a&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[a]="7e10fda2-7a5f-44f9-8707-bc4a5f1b433b",t._sentryDebugIdIdentifier="sentry-dbid-7e10fda2-7a5f-44f9-8707-bc4a5f1b433b")}catch{}})();const T=(t,a)=>t!=null&&t.length>0&&a==="magic_links";function Te(){const t=O(),a=w(),m=_(),[k]=M(),n=k.get("token"),p=k.get("stytch_token_type"),g=r.getMagicLinkCodeVerifier(),i=se(),{otpChallenge:d,twoFAPhoneNumber:x,magicLinkEmail:c,verifyDeviceFetchState:C,resendVerifyDeviceOTPFetchState:z}=l((e=>e.tenantState)),S=l((e=>e.tenantState.fetchState)),y=l((e=>e.tenantState.activeTenantFetchState.fetchState)),I=l((e=>e.tenantState.signInState)),h=l((e=>e.tenantState.magicLinkSignInFetchState.fetchState)),s=l((e=>e.tenantState.loggedInUser)),o=l((e=>W(e))),b=l((e=>q(e))),D=r.getSignedInUser(),v=P().mode;f.useEffect((()=>{s?.zeniSessionId==null&&n!=null&&T(n,p)&&i!=null&&g!=null&&(r.saveMagicLinkTriggered(n),t(B(n,i,g)))}),[n,p,t,i,g,s?.zeniSessionId]),f.useEffect((()=>{I!=="In-Progress"||S!=="Completed"&&y!=="Completed"||s?.zeniSessionId==null||o==null||(n!=null&&r.saveLastUsedMagicLinkToken(n),r.saveSignedInUserWithSession(s,s.zeniSessionId),r.saveSignedInUserTenants(H(b.tenantsInOrder),s.zeniSessionId),J(s.userId,s.zeniSessionId,o.tenantId),t(K(o.tenantId)),r.saveActiveTenantDomainForUser(o.tenantEmailDomain),t(Q("Completed")),V.updateAppLocaleID(ie(o)),ae(s,o,v,void 0,b.tenantsInOrder),Y().then((()=>{const e=R();e!=null&&A(e)})),setTimeout((()=>{N.trackLogin(X.Event.loginSuccess,"email",Z(o.productSettings))}),2e3))}),[I,S,y,s,o,b,v,a.state,t]);const E=f.useCallback((()=>{m("/signin/auth")}),[m]),j=f.useCallback((()=>{i!=null&&d!=null&&c!=null&&t(ee(i,c,d))}),[i,d,t,c]),F=f.useCallback((e=>{i!=null&&n!=null&&c!=null&&d!=null&&t(te(e,i,c,d))}),[i,n,t,c,d]);if(h==="Completed"&&d!=null)return u.jsx($,{phoneNumber:x,verifyOtpFetchState:C.fetchState,resendVerifyDeviceOTPFetchState:z,onResendOtp:j,onVerifyOtp:F,onCancelVerifyDevice:E});if(I==="In-Progress"&&S==="Completed"&&s?.zeniSessionId!=null&&o!=null||D!=null){const e=a.state?.origin??"/";return u.jsx(L,{to:e,state:{...a.state,origin:""}})}if(!T(n,p)||g==null||h==="Error"){const e=a.state?.origin??"/",U=n!=null&&r.getLastUsedMagicLinkToken()===n;return u.jsx(L,{to:e,state:{...a.state,origin:"",magicLinkAlreadyUsed:U,magicLinkExpired:!U&&(r.isMagicLinkTriggered(n??"")||h==="Error"&&s?.zeniSessionId==null)}})}return u.jsx(oe,{"data-testid":"smooth-loader",children:u.jsx(G,{size:"ExtraLarge",start:!0})})}const oe=ne.div`
|
|
2
|
-
position: fixed;
|
|
3
|
-
top: 0;
|
|
4
|
-
left: 0;
|
|
5
|
-
right: 0;
|
|
6
|
-
bottom: 0;
|
|
7
|
-
display: flex;
|
|
8
|
-
align-items: center;
|
|
9
|
-
justify-content: center;
|
|
10
|
-
z-index: 9999;
|
|
11
|
-
background-color: ${t=>t.theme.colors.background};
|
|
12
|
-
`;export{Te as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as e}from"./liveblocks-BLPKVqHo.js";import{h as r,l as i}from"./core-pDUZcPB0.js";import{am as n}from"./index-DElaqJ7F.js";import"./mui-BiqpQr6x.js";import"./sentry-BYwRJ99F.js";import"./zeni-epic-state-Bke7DGFg.js";import"./recharts-Dg9FaaKY.js";import"./analytics-CmKkcxmz.js";import"./plaid-BXFY-KIk.js";import"./dnd-Bslfq-ku.js";import"./stripe-cKAAJElX.js";import"./lottie-DWJdupW0.js";import"./lexical-BMD9Skdu.js";import"./pdf-B3souC9z.js";import"./utils-CJY4ogMD.js";(function(){try{var o=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new o.Error().stack;t&&(o._sentryDebugIds=o._sentryDebugIds||{},o._sentryDebugIds[t]="f2f6ef04-8019-4dfe-8bec-98d5efe59039",o._sentryDebugIdIdentifier="sentry-dbid-f2f6ef04-8019-4dfe-8bec-98d5efe59039")}catch{}})();const f=i(null,(function(o,t){return{onGoBack:()=>{t.navigate(-1)},onGoHome:()=>{t.navigate("/")}}}))(n);function _(){const o=r();return e.jsx(f,{navigate:o})}export{_ as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as m}from"./liveblocks-BLPKVqHo.js";import{a as r}from"./sentry-BYwRJ99F.js";import{u as A,g as j,j as o,N as C}from"./core-pDUZcPB0.js";import{UK as M,fI as P,gp as x,UL as z,UM as D,UN as L,UO as N,pV as R,Tp as k}from"./zeni-epic-state-Bke7DGFg.js";import{z as h,ah as I}from"./index-DElaqJ7F.js";import"./mui-BiqpQr6x.js";import"./recharts-Dg9FaaKY.js";import"./analytics-CmKkcxmz.js";import"./plaid-BXFY-KIk.js";import"./dnd-Bslfq-ku.js";import"./stripe-cKAAJElX.js";import"./lottie-DWJdupW0.js";import"./lexical-BMD9Skdu.js";import"./pdf-B3souC9z.js";import"./utils-CJY4ogMD.js";(function(){try{var n=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},s=new n.Error().stack;s&&(n._sentryDebugIds=n._sentryDebugIds||{},n._sentryDebugIds[s]="c0c0c2dd-06ea-49f7-89ff-99c0b9b0a35f",n._sentryDebugIdIdentifier="sentry-dbid-c0c0c2dd-06ea-49f7-89ff-99c0b9b0a35f")}catch{}})();function ee(){const n=A(),s=j(),{params:t,error:i}=r.useMemo((()=>M(s.search)),[s.search]),w=r.useMemo((()=>new URLSearchParams(s.search).get("client_name")??t?.clientId??"Unknown Application"),[s.search,t]),f=h.isSignedIn(),a=h.getSignedInUser(),p=o((e=>P(e))),l=o((e=>x(e))),d=o((e=>e.tenantState.fetchState)),y=o(z),b=o(D),c=o(L),[U,v]=r.useState(null),[S,E]=r.useState(null);r.useEffect((()=>{document.querySelector("#app-shell-loader")?.remove()}),[]),r.useEffect((()=>()=>{n(N())}),[n,s.search]),r.useEffect((()=>{i!=null&&console.warn("[OAuthConsent] invalid params:",i)}),[i]);const g=r.useRef(!1);r.useEffect((()=>{f&&a!=null&&!g.current&&(d!=="Not-Started"&&d!=="Error"||(g.current=!0,n(R(a.userId,a.zeniSessionId??void 0))))}),[f,a,d,n]),r.useEffect((()=>{c!=null&&c!==""&&(window.location.href=c)}),[c]);const _=r.useMemo((()=>{if(p?.tenantId!=null)return p.tenantId;const e=h.getActiveTenantForUser()?.tenantId;return e!=null&&l.some((T=>T.tenantId===e))?e:l.length===1?l[0].tenantId:null}),[p?.tenantId,l]),u=U??_;return i!=null?m.jsx(I,{variant:"invalid_params",paramsError:i}):f?m.jsx(I,{variant:"signed_in",clientName:w,userEmail:a?.userEmail,isInitializing:d!=="Completed",tenants:l,selectedTenantId:u,onSelectTenant:v,approveError:S??b,isApproving:y==="In-Progress",showAllowButton:u!=null,onApprove:()=>{t!=null&&a!=null&&u!=null&&n(k(a.userId,a.zeniSessionId??void 0,u,t.clientId,t.redirectUri,t.codeChallenge,t.codeChallengeMethod,t.state,t.responseType))},onDeny:()=>{if(t!=null)try{const e=new URL(t.redirectUri);e.searchParams.set("error","access_denied"),e.searchParams.set("error_description","The user denied the request"),e.searchParams.set("state",t.state),window.location.href=e.toString()}catch{E("Unable to deny: redirect_uri is not a valid URL. Close this window or contact support.")}}}):m.jsx(C,{to:"/signin/auth",state:{origin:s.pathname+s.search},replace:!0})}export{ee as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as n}from"./liveblocks-BLPKVqHo.js";import{h as G,u as W,g as z,i as H,j as d,l as J,n as K,o as C}from"./core-pDUZcPB0.js";import{fI as v,Ai as R,vb as Q,VC as M,v6 as T,bq as X,c0 as Z,v7 as ee,VD as ae,Vk as S,ek as te,E6 as se,VE as oe,Eu as re,e0 as ne,d$ as ce}from"./zeni-epic-state-Bke7DGFg.js";import{ai as ie,z as le,aq as de,as as fe,_ as me,a8 as pe,j as w,aD as ue,p as he,c as Fe,m as ge}from"./index-DElaqJ7F.js";import"./mui-BiqpQr6x.js";import Ie from"./NotFoundScreen-rNNJF3rA.js";import{F as be}from"./FeaturePreviewScreen-Y3cKkUSF.js";import{a as F}from"./sentry-BYwRJ99F.js";import{u as Ce}from"./useAskAiCfoHostNavButtonProps-BEEGOqdG.js";import{u as Se}from"./useInitialThreadRequest-BWnJWIOJ.js";import{t as Te}from"./routePaths-KJ0Mf_VR.js";import{M as ye}from"./MobileAppDrawer-C8UsE0YH.js";import"./recharts-Dg9FaaKY.js";import"./analytics-CmKkcxmz.js";import"./plaid-BXFY-KIk.js";import"./dnd-Bslfq-ku.js";import"./stripe-cKAAJElX.js";import"./lottie-DWJdupW0.js";import"./lexical-BMD9Skdu.js";import"./pdf-B3souC9z.js";import"./utils-CJY4ogMD.js";import"./InboxNotificationsProvider-CxBkh6GM.js";import"./useTaskManagerAccess-BpKEGOBZ.js";(function(){try{var s=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},e=new s.Error().stack;e&&(s._sentryDebugIds=s._sentryDebugIds||{},s._sentryDebugIds[e]="cbd0beef-1da9-48dd-9ff6-6c5817075a9f",s._sentryDebugIdIdentifier="sentry-dbid-cbd0beef-1da9-48dd-9ff6-6c5817075a9f")}catch{}})();const y=(s,e,a,o)=>{if(s!=e){const r=o??"";s!=null&&s.length>0?a(`../${e}${r}`,{replace:!0}):a(`${e}${r}`,{replace:!0})}},Ae=J((function(s){const e=ae(s),a={},o=e.pandLReportWithForecast.uiState.nodeCollapseState;return Object.keys(o).forEach((r=>{a[r]=o[r]===!1})),{selectedTimeframe:e.selectedTimeframe,isForecastVsActualOn:e.isForecastVsActualOn,compareMode:e.compareMode,forecastList:e.forecastList,selectedForecast:e.selectedForecast,pandLreport:e.pandLReportWithForecast,scrollPosition:e.pandLReportWithForecast.uiState.scrollPosition,nodeOpenStatus:a,type:"name+balances_forecast",analytics:w}}),(function(s,e){return{onForecastSelectionChanged:(a,o)=>{s(M(a,o)),e.isPandLReportFetched(a)||s(T(a)),y(e.forecastIdFromUrlPath,a,e.navigate)},onTimeframeChanged:a=>{s(re(a))},onForecastVsActualsCompareToggle:a=>{s(oe(a)),s(S({forecastId:e.forecastIdFromUrlPath,scrollPosition:{scrollLeft:0,scrollTop:0}}))},onCompareModeChanged:a=>{s(se(e.firstMonthOfFY,a,0,[]))},onAccountBalanceClick:e.hasTransactionAccess!==!0?void 0:(a,o)=>{let r,c;const p=a.accountName===""?a.accountDescription:a.accountName;if(o.balanceTimeFrame==="month"||o.balanceTimeFrame==="quarter"?(r=o.balanceTimeFrame,c=te(o)):o.balanceTimeFrame==="year"?(r="quarter",c={startDate:o.endDate.startOf("quarter"),endDate:o.endDate}):console.error(`timeframe ${o.balanceTimeFrame} is not supported`),c!=null&&r!=null){const u=Te(e.tenantEmailDomain,a.accountId,a.accountType,p,r,c),f=he(e.location.state?.pathnameStackToGoBack,e.location.pathname);e.navigate(u,{state:{pathnameStackToGoBack:f,referrer:"Forecast"}})}},onNodeCollapseToggled:(a,o)=>{s(S({forecastId:e.forecastIdFromUrlPath,nodeCollapseState:{nodeId:a,isCollapsed:o===!1}}))},onTableScroll:a=>{s(S({forecastId:e.forecastIdFromUrlPath,scrollPosition:a}))},onBackClick:()=>{e.navigate("../../")}}}))(ue);function U(){const s=ie(),e=G(),a=W(),o=z(),{forecastId:r,tenantEmailDomain:c}=H(),[p,u]=F.useState(!1),[f,A]=F.useState(!1),g=le.getSignedInUser(),D=d((t=>v(t))),_=D.company?.companyInfo.firstMonthOfFY??1,i=d((t=>R(t.forecastState,t.forecastListState))),l=d((t=>t.forecastListState.fetchState==="Completed")),k=d((t=>t.profitAndLossState)),x=d((t=>t.reportUIOptionsState.selectedForecast)),j=t=>k.pandLByForecastID[t]!=null&&ee(t,k).reducedAllFetchState.fetchState==="Completed",{areTenantIdsInSync:I}=de();fe({isDataReady:l});const{isAiCfoAccessEnabled:q,onAskAiCfoClick:V}=Ce({mobileExploreReferrer:"Forecast"});F.useEffect((()=>{if(!p&&I)u(!0),l||a(Q());else if(l&&!f){A(!0);const t=((m,P,O)=>P!=null?m.forecasts.findIndex((b=>b.id===P)):O!=null?m.forecasts.findIndex((b=>b.id===O)):m.forecasts.length>0?0:-1)(i,r,x?.id);t===-1&&r!=null?e("page-not-found",{replace:!0}):t!==-1&&t!=x?.index?(a(M(i.forecasts[t].id,t)),y(r,i.forecasts[t].id,e,o.search)):r==null&&t!==-1&&y(void 0,i.forecasts[t].id,e,o.search),t!==-1&&!j(i.forecasts[t].id)&&I&&a(T(i.forecasts[t].id))}}),[p,u,a,l,i,f,A,R,T,I]);const E=me(),$=E?.loggedInUserRole!=null&&X(E.loggedInUserRole),B=Se(D?.companyId,{clearParams:l&&f}),[N,Y]=F.useState(!1),h=new URL(s("forecast_pandl"));h.searchParams.set("firstname",g?.firstName??""),h.searchParams.set("lastname",g?.lastName??""),h.searchParams.set("email",g?.userEmail??"");const L=t=>{Y(t)};return n.jsxs(n.Fragment,{children:[l?n.jsx(pe,{analytics:w,onLoad:t=>(m=>m.trackForecast())(t)}):null,n.jsx(ye,{isAppContentDrawerOpen:N,handleDrawerToggle:L}),n.jsx(Ae,{firstMonthOfFY:_,tenantEmailDomain:c,forecastIdFromUrlPath:r,navigate:e,location:o,isPandLReportFetched:j,meetingUrl:Z(h.toString()),hasTransactionAccess:$,isAiCfoAccessEnabled:q,onAskAiCfoClick:V,initialOpenThreadRequest:B,onClickMenuIcon:()=>{L(!0)}})]})}function He(){const s=d((c=>v(c))),{useFeatureGate:e}=Fe(),{isFeatureEnabled:a}=e(ge.isDebitCardFeatureEnabled),o=ne(a,s),r=ce(s);return o===!0||r===!0?n.jsx(be,{}):n.jsxs(K,{children:[n.jsx(C,{path:"/",element:n.jsx(U,{})}),n.jsx(C,{path:"/:forecastId",element:n.jsx(U,{})}),n.jsx(C,{path:"/:forecastId/*",element:n.jsx(Ie,{})})]})}export{He as default};
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import{j as a}from"./liveblocks-BLPKVqHo.js";import{Vy as re,fI as N,m2 as _,e0 as Y,d$ as le,Sp as J,UX as ce,D1 as Ee,Vz as X,CS as je,Db as Le,D5 as de,CW as pe,D9 as Te,D6 as ve,VA as ue,sw as Ae,g9 as Ve,gG as Fe,VB as G,C_ as me,CZ as ge,De as Re,c9 as Oe}from"./zeni-epic-state-Bke7DGFg.js";import{a1 as fe,c as Q,m as H,z as W,g as Ce,P as he,af as ye,az as be,aA as Be,ab as Se,M as R,ag as we,G as K,aB as Ze,aq as Ue,as as $e,a8 as ze,j as De,T as Ge,p as He,aC as _e,_ as We}from"./index-DElaqJ7F.js";import{D as xe,n as M,S as Ie}from"./mui-BiqpQr6x.js";import ae from"./NotFoundScreen-rNNJF3rA.js";import{a as c}from"./sentry-BYwRJ99F.js";import{u as ee,i as Ke,j as g,h as Me,g as qe,l as Xe,n as se,o as z}from"./core-pDUZcPB0.js";import{u as Ne}from"./useAskAiCfoHostNavButtonProps-BEEGOqdG.js";import{M as Ye}from"./MobileAppDrawer-C8UsE0YH.js";import"./recharts-Dg9FaaKY.js";import"./analytics-CmKkcxmz.js";import"./plaid-BXFY-KIk.js";import"./dnd-Bslfq-ku.js";import"./stripe-cKAAJElX.js";import"./lottie-DWJdupW0.js";import"./lexical-BMD9Skdu.js";import"./pdf-B3souC9z.js";import"./utils-CJY4ogMD.js";import"./InboxNotificationsProvider-CxBkh6GM.js";import"./useTaskManagerAccess-BpKEGOBZ.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="72807287-0305-4585-9e60-6c5947f8a40f",e._sentryDebugIdIdentifier="sentry-dbid-72807287-0305-4585-9e60-6c5947f8a40f")}catch{}})();const Je={overlayWidth:new Se(100,100,48)},te=K.getLocalizedStrings().peoplePage.invitePage,ne=K.getLocalizedStrings().common,Qe=({companyId:e,managersListView:t,companyPassportView:d,classListView:n,mode:f,isEditPeopleDrawerOpen:i,closeDrawerHandler:b})=>{const C=fe(),m=ee(),[O,B]=c.useState(!1),[k,S]=c.useState(!1),{userId:w}=Ke(),r=g((l=>re(l))),p=g((l=>N(l))),P=g((l=>_(l))),{useFeatureGate:x}=Q(),{isFeatureEnabled:I}=x(H.isDebitCardFeatureEnabled),E=Y(I,p),T=le(p),v=J(p),Z=ce(p),U=!!p.company?.featuresActivationInfo?.isReimbursementFeatureEnabled,D=!E&&P&&n.fetchState!=="Completed"||t.fetchState!=="Completed"||d.fetchState!=="Completed"||e==null;if(W.getSignedInUser()==null)throw Error("Can't access invite people page without signing in...");const h=()=>{m(X()),b()},A=()=>{O===!0?S(!0):h()},$=d.companyView?.controllers?.map((l=>l.user)),u=!!p.company?.companyZeniAccountInfo?.isZeniAccountEnabled,{isFeatureEnabled:j}=x(H.isChargeCardFeatureEnabled),L=Ce(p,j,I),{isCardsHidden:V}=he(p?.tenantId),y=!L||V,F=p.companyTreasuryInfo?.info?.businessVerificationStatus?.code==="verified",s={peopleDetails:r,classList:n.classes,managersList:t.users,controllersList:$,mode:f,isZeniTenant:v,isAccountingClassesEnabled:P,isReimbursementDisabled:U===!1,isZeniAccountsDisabled:u===!1,isChargeCardDisabled:y,isTreasuryDisabled:F===!1,isLiteRoleDisabled:Z===!1,isBankingOnlyTenant:E,isCardsOnlyTenant:T,onResetClick:h,onDeleteUser:l=>{m(pe(l.userId,l.userRole.userRoleId))},onPeopleLocalDataUpdated:l=>{m(de({peopleLocalData:l})),B(!0)},onSaveClick:()=>{m(f==="zeni_only"?je(e):Le(v))},onCloseClick:A,isLoading:D||r.person==null},o={onOkClick:()=>{S(!1),h()},onCancelClick:()=>{S(!1)}};return c.useEffect((()=>{D===!1&&w!=null&&m(Ee(w))}),[D,w]),c.useEffect((()=>{r.updatePersonState.fetchState==="Completed"&&h()}),[r.updatePersonState.fetchState]),a.jsx(xe,{anchor:"right",open:i,PaperProps:{style:{width:Je.overlayWidth.valuePercentage(C),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:ye.overlayDark,cursor:"pointer"}}},onClose:A,children:a.jsxs(ea,{onClick:l=>l.stopPropagation(),children:[k===!0?a.jsx(be,{titleComponent:a.jsx(ke,{children:te.discardTitle}),descriptionComponent:a.jsx(Pe,{children:te.discardDescription}),primaryButtonText:ne.yes,secondaryButtonText:ne.no,action:o,isEditPopup:!0}):null,a.jsx(Be,{...s})]})})},ea=M(Ie)`
|
|
2
|
-
display: flex;
|
|
3
|
-
min-height: 100%;
|
|
4
|
-
flex-direction: column;
|
|
5
|
-
`,ke=M(we.H6Regular)`
|
|
6
|
-
margin-top: ${R.sp7};
|
|
7
|
-
padding-left: ${R.sp8};
|
|
8
|
-
padding-right: ${R.sp8};
|
|
9
|
-
color: ${e=>e.theme.colors.primary};
|
|
10
|
-
word-break: break-word;
|
|
11
|
-
`,Pe=M(we.LargeRegularSp)`
|
|
12
|
-
color: ${e=>e.theme.colors.hero};
|
|
13
|
-
padding-left: ${R.sp8};
|
|
14
|
-
padding-right: ${R.sp8};
|
|
15
|
-
margin-bottom: 30px;
|
|
16
|
-
margin-top: ${R.sp4};
|
|
17
|
-
white-space: pre-line;
|
|
18
|
-
`,aa={overlayWidth:new Se(100,100,48)},oe=K.getLocalizedStrings().peoplePage.invitePage,ie=K.getLocalizedStrings().common,sa=({companyId:e,managersListView:t,companyPassportView:d,classListView:n,mode:f,isInvitePeopleDrawerOpen:i,closeDrawerHandler:b})=>{const C=fe(),m=ee(),[O,B]=c.useState(!1),[k,S]=c.useState(!1),w=g((o=>re(o))),r=g((o=>N(o))),p=g((o=>_(o))),{useFeatureGate:P}=Q(),{isFeatureEnabled:x}=P(H.isDebitCardFeatureEnabled),I=Y(x,r),E=le(r),T=J(r),v=ce(r),Z=!!r.company?.featuresActivationInfo?.isReimbursementFeatureEnabled,U=!I&&p&&n.fetchState!=="Completed"||t.fetchState!=="Completed"||d.fetchState!=="Completed"||e==null;if(W.getSignedInUser()==null)throw Error("Can't access invite people page without signing in...");const D=()=>{b(),m(X())},h=()=>{O===!0?S(!0):D()},A={onOkClick:()=>{S(!1),D()},onCancelClick:()=>{S(!1)}},$=d.companyView?.controllers.map((o=>o.user)),u=!!r.company?.companyZeniAccountInfo?.isZeniAccountEnabled,{isFeatureEnabled:j}=P(H.isChargeCardFeatureEnabled),L=Ce(r,j,x),{isCardsHidden:V}=he(r?.tenantId),y=!L||V,F=r.companyTreasuryInfo?.info?.businessVerificationStatus?.code==="verified",s={classList:n.classes,managersList:t.users,controllersList:$,mode:f,isZeniTenant:T,onPeopleLocalDataUpdated:o=>{m(de({peopleLocalData:o})),B(!0)},onResetClick:D,onSaveClick:()=>{m(f==="zeni_only"?Te(e):ve())},onCloseClick:h,peopleDetails:w,isAccountingClassesEnabled:p,isReimbursementDisabled:Z===!1,isLiteRoleDisabled:v===!1,isZeniAccountsDisabled:u===!1,isChargeCardDisabled:y,isTreasuryDisabled:F===!1,isBankingOnlyTenant:I,isCardsOnlyTenant:E,isLoading:U};return c.useEffect((()=>{w.invitePersonState.fetchState==="Completed"&&(b(),m(X()))}),[w.invitePersonState.fetchState]),a.jsx(xe,{anchor:"right",open:i,PaperProps:{style:{width:aa.overlayWidth.valuePercentage(C),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:ye.overlayDark,cursor:"pointer"}}},onClose:h,children:a.jsxs(ta,{onClick:o=>o.stopPropagation(),children:[k===!0?a.jsx(be,{titleComponent:a.jsx(ke,{children:oe.discardTitle}),descriptionComponent:a.jsx(Pe,{children:oe.discardDescription}),primaryButtonText:ie.yes,secondaryButtonText:ie.no,action:A}):null,a.jsx(Ze,{...s})]})})},ta=M(Ie)`
|
|
19
|
-
display: flex;
|
|
20
|
-
min-height: 100%;
|
|
21
|
-
flex-direction: column;
|
|
22
|
-
`,na=Xe((function(e,t){const d=ue(e),n=W.getSignedInUser();return{data:d,loggedinUserId:n?.userId??"",isZeniTenant:t.isZeniTenant===!0,shouldFetchClasses:t.shouldFetchClasses,isZeniAdminUser:n?.userEmailDomain==="zeni.ai"&&t.isZeni===!0,isAccountingClassesEnabled:_(e),analytics:De}}),(function(e,t){const{navigate:d,companyId:n,shouldFetchClasses:f}=t;return{personAction:{onPersonDelete:(i,b)=>{e(pe(i,b))},onResendInvite:i=>{e(Re(i))},onReloadPeople:()=>{e(me()),e(ge(n,f))},onBackClick:()=>{d("../../")},onModeChange:i=>{e(G({mode:i,searchText:"",sortKey:"name",sortOrder:"ascending"}))},onSearchTextChanged:i=>{e(G({searchText:i}))}}}}))(_e);function q({isInvitePeopleDrawerOpen:e,isEditPeopleDrawerOpen:t}){const d=Me(),n=ee(),f=qe(),{areTenantIdsInSync:i}=Ue(),b=W.getSignedInUser(),C=g((s=>N(s))),{useFeatureGate:m}=Q(),{isFeatureEnabled:O}=m(H.isDebitCardFeatureEnabled),B=g((s=>_(s))),k=!Y(O,C)&&B,S=J(C),w=C?.tenantId,{tenantEmailDomain:r}=C,[p,P]=c.useState(!1),[x,I]=c.useState(!1),[E,T]=c.useState(!1),[v,Z]=c.useState("off"),[U,D]=c.useState(!1),h=s=>{D(s)},{isAiCfoAccessEnabled:A,onAskAiCfoClick:$}=Ne({mobileExploreReferrer:"People"}),u=g((s=>ue(s)));$e({isDataReady:u.fetchState==="Completed"});const j=g((s=>Ae(s.classState,s.classListState))),L=g((s=>Ve(s.userState,s.userRoleState,s.userListViewState,"manager"))),V=g((s=>Fe(s))),y=C?.companyId;c.useEffect((()=>{p&&v===u.uiState.mode||!i||(n(G({searchText:"",sortKey:"name",sortOrder:"ascending"})),Z(u.uiState.mode),P(!0),n(me()))}),[p,b,w,n,u.uiState.mode,i]),c.useEffect((()=>{y!=null&&i&&n(ge(y,k))}),[y,k,i]),c.useEffect((()=>{I(e!=null&&e===!0),T(t!=null&&t===!0&&t)}),[e,t]),c.useEffect((()=>{n(G({searchText:"",sortKey:"name",sortOrder:"ascending"}))}),[]);const F=()=>{I(!1),T(!1),d("../")};return a.jsxs(a.Fragment,{children:[u.fetchState==="Completed"?a.jsx(ze,{analytics:De,onLoad:s=>s.trackPageLoaded(Ge.Event.members)}):null,x===!0?a.jsx(sa,{closeDrawerHandler:F,isInvitePeopleDrawerOpen:x,managersListView:L,companyPassportView:V,classListView:j,companyId:y,mode:u.uiState.mode}):null,E===!0?a.jsx(Qe,{closeDrawerHandler:F,isEditPeopleDrawerOpen:E,managersListView:L,companyPassportView:V,classListView:j,companyId:y,mode:u.uiState.mode}):null,a.jsx(Ye,{isAppContentDrawerOpen:U,handleDrawerToggle:h}),a.jsx(na,{navigate:d,signedInUser:b,isZeni:C.isZeni,isZeniTenant:S,peopleUIState:u.uiState,companyId:y,shouldFetchClasses:k,classList:j,managersView:L,peopleView:u,onInvitePeopleClick:()=>{d("./new")},onColumnSortConfigChanged:(s,o)=>{n(G({sortKey:s,sortOrder:o}))},onRowClick:s=>{const o=`/${r}/people/${encodeURIComponent(s)}/edit`,l=He(f.state?.pathnameStackToGoBack,f.pathname);d(o,{state:{pathnameStackToGoBack:l}})},onClickMenuIcon:()=>{h(!0)},isAiCfoAccessEnabled:A,onAskAiCfoClick:$})]})}function ka(){const e=We();return Oe(e?.loggedInUserRole??[])?a.jsxs(se,{children:[a.jsx(z,{path:"/",element:a.jsx(q,{})}),a.jsx(z,{path:"new",element:a.jsx(q,{isInvitePeopleDrawerOpen:!0})}),a.jsx(z,{path:":userId/edit",element:a.jsx(q,{isEditPeopleDrawerOpen:!0})}),a.jsx(z,{path:"*",element:a.jsx(ae,{})})]}):a.jsx(se,{children:a.jsx(z,{path:"*",element:a.jsx(ae,{})})})}export{ka as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as s}from"./liveblocks-BLPKVqHo.js";import E from"./NotFoundScreen-rNNJF3rA.js";import{a as r}from"./sentry-BYwRJ99F.js";import{h as _,g as v,j as p,i as M,u as U,N as O,l as P,n as z,o as b}from"./core-pDUZcPB0.js";import{fI as N,a19 as h,bo as B,bn as F,iO as V,gk as Z}from"./zeni-epic-state-Bke7DGFg.js";import{Z as $,z as I,as as q,dN as G}from"./index-DElaqJ7F.js";import"./mui-BiqpQr6x.js";import{u as H}from"./useAskAiCfoHostNavButtonProps-BEEGOqdG.js";import{M as J}from"./MobileAppDrawer-C8UsE0YH.js";import"./recharts-Dg9FaaKY.js";import"./analytics-CmKkcxmz.js";import"./plaid-BXFY-KIk.js";import"./dnd-Bslfq-ku.js";import"./stripe-cKAAJElX.js";import"./lottie-DWJdupW0.js";import"./lexical-BMD9Skdu.js";import"./pdf-B3souC9z.js";import"./utils-CJY4ogMD.js";import"./InboxNotificationsProvider-CxBkh6GM.js";import"./useTaskManagerAccess-BpKEGOBZ.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="6b6578bc-920a-4264-90bc-b9b92b4f22c7",e._sentryDebugIdIdentifier="sentry-dbid-6b6578bc-920a-4264-90bc-b9b92b4f22c7")}catch{}})();const K=P((function(e){const t=I.getSignedInUser(),c=e.tenantState.currentTenantId,o={userId:t?.userId??"",sessionId:t?.zeniSessionId??"",tenantId:c??""},{aggregatedReportViewState:n}=h(e);return{authParams:o,isDisabled:!1,loggedInUser:t,aggregatedReport:n}}),(function(e,t){return{onBackClick:()=>{t.navigate("../../")},onClickMenuIcon:()=>{t.handleDrawerToggle(!0)}}}))(G),L=()=>{const e=_(),t=v(),c=$(),o=p((a=>N(a))),{aggregatedReportViewState:n}=p((a=>h(a))),{tenantEmailDomain:f}=M(),u=U(),d=I.getSignedInUser();if(d==null)throw new Error("Can't access this page without signing in...");const m=r.useRef(!1),[w,S]=r.useState(!1),C=B(o?.userRole??[]),k=o?.userRole?.includes("bookkeeping_admin")??!1,x=F(d),y=C||k||x,l=r.useCallback(((a,i,T)=>{u(V({fromMonth:a,toMonth:i,cacheOverride:T}))}),[]);r.useEffect((()=>{n?.fetchState==="Completed"&&m.current&&(u(Z({messageSection:"data_refresh_update",messageText:"success",type:"success",showStatusIcon:!0})),m.current=!1)}),[n?.fetchState]);const D=r.useCallback(((a,i)=>{n!=null&&n?.fetchState==="In-Progress"||l(a,i,!0),m.current=!0}),[n?.fetchState,l]),j=r.useCallback(((a,i)=>{l(a,i,!1)}),[l]),g=a=>{S(a)},{isAiCfoAccessEnabled:R,onAskAiCfoClick:A}=H({mobileExploreReferrer:"Performance"});return q({isDataReady:n?.fetchState==="Completed"}),y?s.jsxs(s.Fragment,{children:[s.jsx(J,{isAppContentDrawerOpen:w,handleDrawerToggle:g}),s.jsx(K,{navigate:e,location:t,themeState:c,currentTenant:o,signedInUser:d,tenantEmailDomain:f,onReload:D,onTimeRangeSelect:j,handleDrawerToggle:g,isAiCfoAccessEnabled:R,onAskAiCfoClick:A})]}):s.jsx(O,{to:`/${f}/dashboard`,replace:!0})};function be(){return s.jsxs(z,{children:[s.jsx(b,{path:"*",element:s.jsx(L,{})}),s.jsx(b,{path:"*",element:s.jsx(E,{})})]})}export{be as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as r}from"./liveblocks-BLPKVqHo.js";import Z from"./NotFoundScreen-rNNJF3rA.js";import{a as p}from"./sentry-BYwRJ99F.js";import{h as C,g as N,u as V,j as u,N as D,l as k,n as z,o as g}from"./core-pDUZcPB0.js";import{fI as E,Zf as w,Zw as h,NQ as U,NM as L,NP as m,NF as B,ZV as T,NJ as F,NS as J}from"./zeni-epic-state-Bke7DGFg.js";import{z as $,w as O,ca as K,r as W,bT as M,cb as P}from"./index-DElaqJ7F.js";import"./mui-BiqpQr6x.js";import{u as Q,R as x}from"./ReimbursementApprovalRuleDetailScreen-ZM1Aw-_i.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},s=new e.Error().stack;s&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[s]="fdfb7fd5-94ba-4768-81bd-e5f6a87f3ec2",e._sentryDebugIdIdentifier="sentry-dbid-fdfb7fd5-94ba-4768-81bd-e5f6a87f3ec2")}catch{}})();const j="reimbursement-approval-rule-update",q=k((function(e){return{approvalView:w(e),remiSetupApproverViewUpdateData:h(e).remiSetupApproverViewUpdateData}}),(function(e,s){const{navigate:n,location:a}=s;return{onApprovalRulesEventReceived:t=>{t.endsWith(j)&&e(T(!1))},onBackClick:()=>{W(a)?n("../../"):n("../../../reimbursements/setup")},onDeleteRuleClick:t=>{e(B(t,!1))},onEditRuleClick:t=>{t!=null?(e(m(t)),n(`./${t}/edit`)):(e(m()),n("./new"))}}}))(O(K)),G=({isLoading:e})=>{const s=C(),n=N(),a=V(),[t,l]=p.useState(!1),[v,R]=p.useState(!1),S=u((o=>o.remiSetupApproverViewState.fetchState)),c=u((o=>E(o))),d=u((o=>w(o))),b=u((o=>h(o).remiSetupApproverViewUpdateData));if(p.useEffect((()=>{b?.updateStatus.fetchState==="Completed"&&a(U())}),[b]),p.useEffect((()=>{t||S!=="Not-Started"||e||(l(!0),a(L(!0,!1,!1,!1)))}),[t,S,e,a]),$.getSignedInUser()==null)throw Error("Can't access reimbursement approval without signing in...");p.useEffect((()=>{d.allApprovalRules.length===0&&d.fetchState==="Completed"&&(v||(R(!0),a(m())),s("./new"))}),[v,d,a]);const f={events:c.companyId!=null?[`private-encrypted-${c.companyId}.${j}`]:[],eventCallback:(o,y,I)=>{o.endsWith(j)&&I.onApprovalRulesEventReceived(o)}};return c?.companyReimbursementInfo?.info?.isReimbursementTOSAccepted===!1?r.jsx(D,{to:"../../promo"}):r.jsx(q,{currentTenant:c,location:n,navigate:s,...f})},A="reimbursement-approval-rule-update",H=k((function(e){const s=w(e),n=h(e).remiSetupApproverViewUpdateData,a={};for(const l of Object.values(e.vendorState.vendorByID))l?.id!=null&&(a[l.id]=l.name);const t={};for(const l of Object.values(e.classState.classesByKey))l?.classId!=null&&(t[l.classId]=l.className);return{approvalView:s,remiSetupApproverViewUpdateData:n,vendorNamesById:a,departmentNamesById:t}}),(function(e,s){const{navigate:n,location:a}=s;return{onApprovalRulesEventReceived:t=>{t.endsWith(A)&&e(T(!1))},onBackClick:()=>{W(a)?n("../../"):n("../../../reimbursements/setup")},onDeleteRuleClick:t=>{e(B(t,!0))},onEditRuleClick:t=>{t!=null?(e(m(t)),n(`./${t}/edit`)):(e(m()),n("./new"))},onReorderRules:t=>{e(J(t,!0))}}}))(O(P)),X=()=>{const e=u((a=>E(a))),{isApprovalRulesV3Enabled:s,isLoading:n}=M(e?.tenantId);return s?r.jsx(Y,{isLoading:n}):r.jsx(G,{isLoading:n})},Y=({isLoading:e})=>{const s=C(),n=N(),a=V(),[t,l]=p.useState(!1),[v,R]=p.useState(!1),[S,c]=p.useState(!1),d=u((i=>i.remiSetupApproverViewState.fetchState)),b=u((i=>i.remiSetupApproverViewState.approverListState.fetchStatus.fetchState)),f=u((i=>E(i))),o=u((i=>w(i)));Q();const y=u((i=>h(i).remiSetupApproverViewUpdateData));if(p.useEffect((()=>{y?.updateStatus.fetchState==="Completed"&&a(U())}),[y]),p.useEffect((()=>{t||d!=="Not-Started"||e||(l(!0),a(L(!0,!1,!1,!0)))}),[t,d,e,a]),p.useEffect((()=>{v||b!=="Not-Started"||e||(R(!0),a(F(!1,!0)))}),[v,b,e,a]),$.getSignedInUser()==null)throw Error("Can't access reimbursement approval without signing in...");p.useEffect((()=>{o.allApprovalRules.length===0&&o.fetchState==="Completed"&&(S||(c(!0),a(m())),s("./new"))}),[S,o,a]);const I={events:f.companyId!=null?[`private-encrypted-${f.companyId}.${A}`]:[],eventCallback:(i,ee,_)=>{i.endsWith(A)&&_.onApprovalRulesEventReceived(i)}};return f?.companyReimbursementInfo?.info?.isReimbursementTOSAccepted===!1?r.jsx(D,{to:"../../promo"}):r.jsx(H,{currentTenant:f,location:n,navigate:s,isLoading:e,...I})};function le(){return r.jsxs(z,{children:[r.jsx(g,{path:"/",element:r.jsx(X,{})}),r.jsx(g,{path:"/new",element:r.jsx(x,{})}),r.jsx(g,{path:"/:approvalRuleId/edit",element:r.jsx(x,{})}),r.jsx(g,{path:"*",element:r.jsx(Z,{})})]})}export{le as R};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as a}from"./liveblocks-BLPKVqHo.js";import{z as b,a8 as N,j as u,T as S,e2 as E,c as I,m as k}from"./index-DElaqJ7F.js";import"./mui-BiqpQr6x.js";import g from"./NotFoundScreen-rNNJF3rA.js";import{a as c}from"./sentry-BYwRJ99F.js";import{u as C,j as h,h as F,g as L,l as T,n as U,o as d,N as y}from"./core-pDUZcPB0.js";import{fI as _,a28 as j,a29 as p,DY as P,q2 as V,a2a as q,DW as z}from"./zeni-epic-state-Bke7DGFg.js";import"./recharts-Dg9FaaKY.js";import"./analytics-CmKkcxmz.js";import"./plaid-BXFY-KIk.js";import"./dnd-Bslfq-ku.js";import"./stripe-cKAAJElX.js";import"./lottie-DWJdupW0.js";import"./lexical-BMD9Skdu.js";import"./pdf-B3souC9z.js";import"./utils-CJY4ogMD.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="400ee9fb-1a2e-4dc9-ab8e-1d39a329604e",e._sentryDebugIdIdentifier="sentry-dbid-400ee9fb-1a2e-4dc9-ab8e-1d39a329604e")}catch{}})();const G=T((function(e,t){const n=j(e);return{inviteFormView:n.localData,submitStatus:n.saveStatus,userName:t.userName,rewardsPlan:n.rewardsPlan,companyLegalName:t.companyName}}),(function(e,t){const{navigate:n}=t,i=b.getSignedInUser();return{onDismissClick:()=>{e(p()),n("/")},onSendClick:()=>{if(i!=null){const s=[],r=[];t.inviteFormCompayData.forEach((m=>{s.push(m.companyName),r.push(m.emailIds[0])})),u.trackInviteEmailClicked("send",s,r,s.length)}e(z())},onUpdateInviteFormLocalData:s=>{e(q({localData:s}))},onSubmitSuccess:()=>{e(p())},onCancelClick:()=>{i!=null&&u.trackInviteEmailClicked("cancel")}}}))(E),R=()=>{const e=C(),[t,n]=c.useState(!1),[i,s]=c.useState(!1),r=h((o=>_(o))),m=F(),w=L(),f=b.getSignedInUser();if(f==null)throw Error("Can't access invite referral screen without signing in...");const l=h((o=>j(o))),x=f?.firstName!=null?f.firstName:"User";c.useEffect((()=>{e(p()),r?.rewardsLastViewedTime==null&&i===!1&&(e(P()),s(!0))}),[]),c.useEffect((()=>{t||l.fetchState!=="Not-Started"||(n(!0),e(V(!0)))}),[l.fetchState,e]);const D=r.company?.companyInfo.companyLegalName??r.companyName;return a.jsxs(a.Fragment,{children:[l.fetchState==="Completed"?a.jsx(N,{analytics:u,onLoad:o=>(v=>v.trackPageLoaded(S.Event.inviteEmailViewed))(o)}):null,a.jsx(G,{navigate:m,location:w,currentTenant:r,companyName:D,userName:x,inviteFormCompayData:l.localData})]})};function ne(){const{useFeatureGate:e}=I(),{isFeatureEnabled:t}=e(k.isReferralFeatureEnabled);return a.jsxs(U,{children:[a.jsx(d,{path:"/",element:a.jsx(y,{to:"refer",replace:!0})}),a.jsx(d,{path:"how-it-works",element:a.jsx(y,{to:"refer",replace:!0})}),a.jsx(d,{path:"refer/*",element:t?a.jsx(R,{}):a.jsx(g,{})}),a.jsx(d,{path:"*",element:a.jsx(g,{})})]})}export{ne as default};
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/NotFoundScreen-rNNJF3rA.js","assets/sentry-BYwRJ99F.js","assets/core-pDUZcPB0.js","assets/zeni-epic-state-Bke7DGFg.js","assets/index-DElaqJ7F.js","assets/mui-BiqpQr6x.js","assets/analytics-CmKkcxmz.js","assets/utils-CJY4ogMD.js","assets/index-BhC2LNQw.css","assets/DashboardRoutes-bD-NpO4n.js","assets/withTransactionSidePanel-EmB6Lhe6.js","assets/useAskAiCfoHostNavButtonProps-BEEGOqdG.js","assets/TransactionDetailScreen-CCYZhbpM.js","assets/decodeURIComponentSafe-DBYvBfqM.js","assets/useInitialThreadRequest-BWnJWIOJ.js","assets/routePaths-KJ0Mf_VR.js","assets/expenseAutomationHelper-pbEk9tHa.js","assets/stripSplatSuffix-5xMPsJCi.js","assets/analyticsHelper-CT62vOeP.js","assets/CompanyPassportScreen-CwpDDfL0.js","assets/MobileAppDrawer-C8UsE0YH.js","assets/InboxNotificationsProvider-CxBkh6GM.js","assets/useTaskManagerAccess-BpKEGOBZ.js","assets/useAiCfoDashboardSuggestedQuestionsChips-DtXjJJR9.js","assets/FeaturePreviewScreen-Y3cKkUSF.js","assets/BillPayRoutes-BbZifdx_.js","assets/AddressScreen-CB5BRM9y.js","assets/DomesticWireDetailScreen-C5k3DT9m.js","assets/BusinessVerificationPageScreen-gGCsmsgi.js","assets/DrawerScreen-Dvp_bzzQ.js","assets/SetupPagesScreen-DJ1w7kWs.js","assets/BillPayApprovalRoutes-XdVdW0PG.js","assets/ReimbursementApprovalRuleDetailScreen-ZM1Aw-_i.js","assets/getLocaleForTenant-0mV5x3GU.js","assets/ReimbursementRoutes-DPiReCXE.js","assets/ReimbursementApprovalRoutes-DY5FrgK2.js","assets/TransactionListRoutes-BmQiF0V2.js","assets/ZeniAccountStatementScreen-Bm0CaqwY.js","assets/SettingsRoutes-D4kzb4To.js","assets/AccountMappingScreen-NREHTMQ1.js","assets/QBOConnectionScreen-6U4C9EuT.js","assets/empty-ChYivft5.js","assets/index-DDEprezU.js","assets/url-BlXMXHHv.js","assets/index-C7P994Rq.js","assets/accountMappingHelper-42mDzLtR.js","assets/useEmailConnectResultRefresh-C0yzwvmf.js","assets/ReportsRoutes-Cf01mfIk.js","assets/ChargeCardRoutes-D2v71o2S.js","assets/useChargeCardPusherEvents-B8oEFskx.js","assets/PeopleRoutes-DjY-_8xS.js","assets/ExpenseAutomationRoutes-IJIfqkj-.js","assets/useActualMatchingMatchDetail-Bs6gwQjf.js","assets/ScheduleDetailsPrepaidExpensesScreen-CuO3_SI4.js","assets/pathToGoBack-Bl5vJY_-.js","assets/TreasuryRoutes-BjdfZTjc.js","assets/VendorsRoutes-X9IFemZr.js","assets/ZeniAccountRoutes-Cwkn0zT6.js","assets/AddressRoutes-D8ARdNLG.js","assets/PandLWithForecastRoutes-Cij2SWS4.js","assets/CustomerOnboardingRoutes-DYEVoKvU.js","assets/TransactionDetailRoutes-B6e8aJoM.js","assets/EntityDetailRoutes-DTAUvz4h.js","assets/InvoicingRoutes-BDyr12_i.js","assets/NotificationRoutes-D4O9EUNW.js","assets/PerformanceRoutes-BGY0_n-J.js","assets/ActualMatchingMatchDetailScreen-ZfOyWL5F.js","assets/RewardsRoutes-cPzFd3Pi.js","assets/TaskRoutes-CgC8VN7O.js","assets/TaskListScreen-DhMAwdLm.js","assets/useTaskManagerPusherEvents-P3ZIbHSQ.js","assets/AiCfoScreen-HyI4GQCb.js","assets/CardsAiCfoScreen-Csz8lSCn.js"])))=>i.map(i=>d[i]);
|
|
2
|
-
import{_ as s,bn as Es,fI as hs,e0 as ps,d$ as gs,B7 as xs,dj as Rs,c9 as js,gM as Is,gc as Ts,dg as pe,cH as As,gq as fs,cz as bs,bF as Ds,br as ys,Uk as vs,v as Cs,Un as Os,bq as Us,Uo as Ps,bL as ws,bK as Fs,bu as Ls,cv as ks,Up as Vs,Uq as Hs,db as Bs,de as Ss,dd as Ns,cG as Ms,cN as Zs,pV as ge,gl as xe,g$ as $s,gn as Re,gO as je,gP as Ie,go as zs}from"./zeni-epic-state-Bke7DGFg.js";import{j as e}from"./liveblocks-BLPKVqHo.js";import{a as P}from"./sentry-BYwRJ99F.js";import{N as u,u as Gs,h as qs,i as Ys,g as Ws,j as $,q as Te,n as Ks,o as n}from"./core-pDUZcPB0.js";import{O as l,E as Qs,u as Xs,z as y,c as Js,e as et,k as st,m as S,g as tt,P as nt,_ as at,L as F,G as Ae,t as _,Q as ot,R as rt,j as ne}from"./index-DElaqJ7F.js";import"./mui-BiqpQr6x.js";import{f as fe}from"./analyticsHelper-CT62vOeP.js";import{t as it}from"./getLocaleForTenant-0mV5x3GU.js";(function(){try{var o=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},b=new o.Error().stack;b&&(o._sentryDebugIds=o._sentryDebugIds||{},o._sentryDebugIds[b]="21a57c7a-c58d-454f-973f-b499d51f28df",o._sentryDebugIdIdentifier="sentry-dbid-21a57c7a-c58d-454f-973f-b499d51f28df")}catch{}})();const lt=l((()=>s((()=>import("./NotFoundScreen-rNNJF3rA.js")),__vite__mapDeps([0,1,2,3,4,5,6,7,8])))),ut=({tenantEmailDomain:o})=>e.jsx(u,{to:`/${o}/reimbursements`}),dt=({tenantEmailDomain:o})=>e.jsx(u,{to:`/${o}/bills`}),be=({tenantEmailDomain:o})=>e.jsx(u,{to:`/${o}/treasury`}),De=({tenantEmailDomain:o})=>e.jsx(u,{to:`/${o}/checking`}),ye=({tenantEmailDomain:o})=>e.jsx(u,{to:`/${o}/cards`}),v=({showZeniAccountRoute:o,isUserHasBillPayAccess:b,isUserHasReimbursementAccess:N,showTreasuryRoute:i,isTenantBankingOnly:k,showChargeCardRoute:O,tenantEmailDomain:C})=>{if(k===!0){if(o)return e.jsx(De,{tenantEmailDomain:C});if(i)return e.jsx(be,{tenantEmailDomain:C});if(O)return e.jsx(ye,{tenantEmailDomain:C})}return o?e.jsx(De,{tenantEmailDomain:C}):i?e.jsx(be,{tenantEmailDomain:C}):O?e.jsx(ye,{tenantEmailDomain:C}):b?e.jsx(dt,{tenantEmailDomain:C}):N?e.jsx(ut,{tenantEmailDomain:C}):e.jsx(lt,{})},ct={dashboard:()=>s((()=>import("./DashboardRoutes-bD-NpO4n.js")),__vite__mapDeps([9,1,2,3,4,5,6,7,10,11,12,13,14,15,16,17,0,18,19,20,21,22,23,24,8])),bills:()=>s((()=>import("./BillPayRoutes-BbZifdx_.js")),__vite__mapDeps([25,1,2,3,4,5,6,7,26,0,27,11,14,28,15,20,21,22,29,24,30,18,31,32,33,8])),reimbursement:()=>s((()=>import("./ReimbursementRoutes-DPiReCXE.js")),__vite__mapDeps([34,1,2,3,4,5,6,7,0,30,28,15,20,21,22,18,24,11,14,29,35,32,33,8])),transactions:()=>s((()=>import("./TransactionListRoutes-BmQiF0V2.js")),__vite__mapDeps([36,1,2,3,4,5,6,7,10,11,12,13,14,15,16,17,37,8])),settings:()=>s((()=>import("./SettingsRoutes-D4kzb4To.js")),__vite__mapDeps([38,1,2,3,4,5,6,7,22,39,20,21,40,41,42,43,44,13,45,26,0,18,28,15,19,46,31,32,35,8])),reports:()=>s((()=>import("./ReportsRoutes-Cf01mfIk.js")),__vite__mapDeps([47,1,2,3,4,5,6,7,0,24,14,15,20,21,22,8])),chargeCards:()=>s((()=>import("./ChargeCardRoutes-D2v71o2S.js")),__vite__mapDeps([48,1,2,3,4,5,6,7,11,20,21,22,30,28,15,0,18,14,49,26,8])),people:()=>s((()=>import("./PeopleRoutes-DjY-_8xS.js")),__vite__mapDeps([50,1,2,3,4,5,6,7,0,11,20,21,22,8])),expenseAutomation:()=>s((()=>import("./ExpenseAutomationRoutes-IJIfqkj-.js")),__vite__mapDeps([51,1,2,3,0,4,5,6,7,11,12,13,14,15,16,52,17,10,53,54,45,29,8])),treasury:()=>s((()=>import("./TreasuryRoutes-BjdfZTjc.js")),__vite__mapDeps([55,1,2,3,4,5,6,7,0,30,28,15,20,21,22,18,11,14,24,8])),vendors:()=>s((()=>import("./VendorsRoutes-X9IFemZr.js")),__vite__mapDeps([56,1,2,3,4,5,6,7,26,0,24,53,54,15,11,20,21,22,29,45,8])),zeniAccounts:()=>s((()=>import("./ZeniAccountRoutes-Cwkn0zT6.js")),__vite__mapDeps([57,1,2,3,4,5,6,7,0,30,28,15,20,21,22,18,24,27,26,11,37,8]))},mt=["bills","transactions","settings","reimbursement","reports","chargeCards","people"],ae=o=>{"requestIdleCallback"in window?requestIdleCallback(o):setTimeout(o,100)},_t=l((()=>s((()=>import("./ReportsRoutes-Cf01mfIk.js")),__vite__mapDeps([47,1,2,3,4,5,6,7,0,24,14,15,20,21,22,8])))),Et=l((()=>s((()=>import("./AddressRoutes-D8ARdNLG.js")),__vite__mapDeps([58,1,2,3,26,4,5,6,7,0,8])))),ht=l((()=>s((()=>import("./PeopleRoutes-DjY-_8xS.js")),__vite__mapDeps([50,1,2,3,4,5,6,7,0,11,20,21,22,8])))),pt=l((()=>s((()=>import("./PandLWithForecastRoutes-Cij2SWS4.js")),__vite__mapDeps([59,1,2,3,4,5,6,7,0,24,11,14,15,20,21,22,8])))),gt=l((()=>s((()=>import("./CustomerOnboardingRoutes-DYEVoKvU.js")),__vite__mapDeps([60,1,2,3,26,4,5,6,7,0,40,41,42,43,44,13,46,49,8])))),xt=l((()=>s((()=>import("./VendorsRoutes-X9IFemZr.js")),__vite__mapDeps([56,1,2,3,4,5,6,7,26,0,24,53,54,15,11,20,21,22,29,45,8])))),Rt=l((()=>s((()=>import("./TransactionDetailRoutes-B6e8aJoM.js")),__vite__mapDeps([61,1,2,3,0,4,5,6,7,12,11,13,14,15,16,8])))),ve=l((()=>s((()=>import("./EntityDetailRoutes-DTAUvz4h.js")),__vite__mapDeps([62,1,2,3,4,5,6,7,13,10,11,12,14,15,16,17,8])))),jt=l((()=>s((()=>import("./DashboardRoutes-bD-NpO4n.js")),__vite__mapDeps([9,1,2,3,4,5,6,7,10,11,12,13,14,15,16,17,0,18,19,20,21,22,23,24,8])))),Ce=l((()=>s((()=>import("./BillPayRoutes-BbZifdx_.js")),__vite__mapDeps([25,1,2,3,4,5,6,7,26,0,27,11,14,28,15,20,21,22,29,24,30,18,31,32,33,8])))),It=l((()=>s((()=>import("./SettingsRoutes-D4kzb4To.js")),__vite__mapDeps([38,1,2,3,4,5,6,7,22,39,20,21,40,41,42,43,44,13,45,26,0,18,28,15,19,46,31,32,35,8])))),Tt=l((()=>s((()=>import("./InvoicingRoutes-BDyr12_i.js")),__vite__mapDeps([63,1,2,3,4,5,6,7,26,0,20,21,22,40,41,42,43,44,13,8])))),Oe=l((()=>s((()=>import("./ReimbursementRoutes-DPiReCXE.js")),__vite__mapDeps([34,1,2,3,4,5,6,7,0,30,28,15,20,21,22,18,24,11,14,29,35,32,33,8])))),At=l((()=>s((()=>import("./ZeniAccountRoutes-Cwkn0zT6.js")),__vite__mapDeps([57,1,2,3,4,5,6,7,0,30,28,15,20,21,22,18,24,27,26,11,37,8])))),ft=l((()=>s((()=>import("./TreasuryRoutes-BjdfZTjc.js")),__vite__mapDeps([55,1,2,3,4,5,6,7,0,30,28,15,20,21,22,18,11,14,24,8])))),bt=l((()=>s((()=>import("./TransactionListRoutes-BmQiF0V2.js")),__vite__mapDeps([36,1,2,3,4,5,6,7,10,11,12,13,14,15,16,17,37,8])))),Dt=l((()=>s((()=>import("./ChargeCardRoutes-D2v71o2S.js")),__vite__mapDeps([48,1,2,3,4,5,6,7,11,20,21,22,30,28,15,0,18,14,49,26,8])))),yt=l((()=>s((()=>import("./NotificationRoutes-D4O9EUNW.js")),__vite__mapDeps([64,1,2,3,0,4,5,6,7,11,22,8])))),vt=l((()=>s((()=>import("./PerformanceRoutes-BGY0_n-J.js")),__vite__mapDeps([65,1,2,3,0,4,5,6,7,11,20,21,22,8])))),Ct=l((()=>s((()=>import("./ExpenseAutomationRoutes-IJIfqkj-.js")),__vite__mapDeps([51,1,2,3,0,4,5,6,7,11,12,13,14,15,16,52,17,10,53,54,45,29,8])))),Ot=l((()=>s((()=>import("./ActualMatchingMatchDetailScreen-ZfOyWL5F.js")),__vite__mapDeps([66,1,2,3,4,5,6,7,52,17,13,15,0,8])))),Ut=l((()=>s((()=>import("./RewardsRoutes-cPzFd3Pi.js")),__vite__mapDeps([67,1,2,3,4,5,6,7,0,8])))),Pt=l((()=>s((()=>import("./TaskRoutes-CgC8VN7O.js")),__vite__mapDeps([68,1,2,3,0,4,5,6,7,14,20,21,22,69,11,70,8])))),wt=l((()=>s((()=>import("./AiCfoScreen-HyI4GQCb.js")),__vite__mapDeps([71,1,2,3,4,5,6,7,23,54,15,70,8])))),Ue=l((()=>s((()=>import("./CardsAiCfoScreen-Csz8lSCn.js")),__vite__mapDeps([72,1,2,3,4,5,6,7,8])))),f=l((()=>s((()=>import("./NotFoundScreen-rNNJF3rA.js")),__vite__mapDeps([0,1,2,3,4,5,6,7,8])))),Ft=l((()=>s((()=>import("./TaskListScreen-DhMAwdLm.js").then((o=>o.f))),__vite__mapDeps([69,1,2,3,4,5,6,7,11,20,21,22,70,8])))),Lt=({isDashboardAccess:o,showZeniAccountRoute:b,isUserHasBillPayAccess:N,isUserHasReimbursementAccess:i,showTreasuryRoute:k,isTenantBankingOnly:O,isTenantCardsOnly:C,showChargeCardRoute:V})=>{if(O===!0){if(b)return e.jsx(u,{to:"checking"});if(k)return e.jsx(u,{to:"treasury"});if(V)return e.jsx(u,{to:"cards"})}return C===!0&&V?e.jsx(u,{to:"cards"}):o?e.jsx(u,{to:"dashboard"}):b?e.jsx(u,{to:"checking"}):k?e.jsx(u,{to:"treasury"}):V?e.jsx(u,{to:"cards"}):N?e.jsx(u,{to:"bills"}):i?e.jsx(u,{to:"reimbursements"}):e.jsx(u,{to:"dashboard"})},Pe=({tenantEmailDomain:o})=>e.jsx(u,{to:`/${o}/dashboard`}),$t=Object.freeze(Object.defineProperty({__proto__:null,default:function({setTenantEmailDomain:o}){const b=Gs(),N=qs(),{tenantEmailDomain:i}=Ys(),k=Qs().mode,{setLoading:O,clearAllLoading:C,clearLoading:V}=Xs(),D=y.getSignedInUserTenant(i)?.tenantId,I=y.getSignedInUser(),K=Es(I),z=Ws(),[L,we]=P.useState(!1),r=$((a=>hs(a))),{useFeatureGate:H}=Js(),M=et(),Q=st(),Fe=!!r.company?.companyZeniAccountInfo?.isZeniAccountEnabled,Le=r.companyTreasuryInfo?.info?.businessVerificationStatus?.code==="verified",{isFeatureEnabled:ke}=H(S.isChargeCardFeatureEnabled),{isFeatureEnabled:oe}=H(S.isDebitCardFeatureEnabled),T=$((a=>a.tenantState.fetchState)),p=$((a=>a.tenantState.activeTenantFetchState.fetchState)),E=p==="Completed"||T==="Completed"?ps(oe,r):void 0,X=p==="Completed"||T==="Completed"?gs(r):void 0,re=p==="Completed"||T==="Completed"?xs(r)&&!Rs(r):void 0,Ve=tt(r,ke,oe),{isCardsHidden:He}=nt(r?.tenantId),Be=!Ve||!!He,{isFeatureEnabled:Se}=H(S.isSettingsFeatureEnabled),{isFeatureEnabled:J}=H(S.isAiCfoFileUploadEnabled),{isFeatureEnabled:Ne}=H(S.isInvoicingFeatureEnabled??"is_invoicing_feature_enabled"),Me=Ne||rt==="DEV",Ze=r?.userRole!=null&&js(r.userRole),G=$((a=>Is(a)));if(i!=null){const a=y.getSignedInUserTenant(i);I!=null&&a!=null&&fe(I,r,k)}const Z={tenantId:D,userId:I?.userId,sessionId:I?.zeniSessionId},ie=Ts(),h=at(),$e=r.company==null||h?.loggedInUserRoleMap!=null&&pe(h.loggedInUserRole),ze=As(h?.loggedInUserRoleMap),ee=Te("/:tenantEmailDomain/onboarding/*")!==null,Ge=Te("/:tenantEmailDomain/month_end_close_checks/review/:selectedTab/:selectedPeriod/*"),se=Ge?.params.selectedPeriod,qe=$((a=>Z.tenantId!=null?fs(a,Z.tenantId):void 0));P.useEffect((()=>{O(F.TENANT_FETCHING),o(i)}),[i]),P.useEffect((()=>{if(se!=null&&D!=null){const a=se.split("-");if(a.length===2){const A=bs(Number(a[0])),c=Number(a[1]),t=Ds(`01-${A<10?`0${A}`:A}-${c}`,Ae.getLocalizedStrings().dateFormat.analytics.DDDashMMDashYYYY),d=ys();t.isAfter(d,"month")===!1?b(vs(D,{month:A,year:c})):N(`/${i}/month_end_close_checks/review`)}}}),[se,i,D]),P.useEffect((()=>{L||(we(!0),O(F.TENANT_FETCHING))}),[L,Z,ie,I,b,y]),P.useLayoutEffect((()=>{!Cs(ie,Z)&&y.isSignedIn()&&(O(F.TENANT_FETCHING),(function(a,A,c,t){if(xe(A?.userId,A?.zeniSessionId,a.tenantId),c($s(!0)),c(Re(a.tenantId)),a.tenantId!=null&&_.clearTenant(a.tenantId),a.tenantId!=null){const d=y.getSignedInUserTenantWithId(a.tenantId);t&&Ae.updateAppLocaleID(it(t)),d?.tenantEmailDomain!=null&&y.saveActiveTenantDomainForUser(d?.tenantEmailDomain)}a.userId!=null?ne.identify(a.userId,{tenant_id:a.tenantId}):ne.resetUserIdentity()})(Z,I,b,qe))}),[D]),P.useEffect((()=>{y.isSignedIn()&&(O(F.TENANT_FETCHING),(function(a,A,c,t,d,q,B){if(c==null&&t==null)return void console.warn("There is no current tenant selected!!");const Y=t!=null&&d?.zeniSessionId!=null,cs=c==null||c.tenantId!==t,ms=c!=null&&c.excludedResources==null,_s=c!=null&&c.externalConnections==null;if(Y&&cs){B(Re(t));const W=y.getSignedInUserTenantWithId(t);W?.tenantEmailDomain!=null&&y.saveActiveTenantDomainForUser(W?.tenantEmailDomain),xe(d?.userId,d?.zeniSessionId,t),_.shouldFetchExcludedResources(t)&&(_.markExcludedResourcesFetchStarted(t),B(je(d.userId,t))),_.shouldFetchConnections(t)&&(_.markConnectionsFetchStarted(t),B(Ie(d.userId,t)))}else Y&&ms&&_.shouldFetchExcludedResources(t)&&(_.markExcludedResourcesFetchStarted(t),B(je(d.userId,t))),Y&&_s&&_.shouldFetchConnections(t)&&(_.markConnectionsFetchStarted(t),B(Ie(d.userId,t)));if(Y){ne.identify(d.userId,{tenant_id:t});const W=t==null||t!=null&&(A==="Completed"||A==="Error");a==="Completed"||A!=="Not-Started"&&A!=="Error"||t==null||!_.shouldFetchActiveTenant(t)||(_.markActiveTenantFetchStarted(t),q(F.TENANT_FETCHING),B(zs(d.userId,t,d.zeniSessionId))),W&&(a==="Not-Started"||a==="Error")&&_.shouldFetchAllTenants()&&(_.markAllTenantsFetchStarted(),B(ge(d.userId,d.zeniSessionId)))}})(T,p,r,D,I,O,b))}),[D,p]),P.useEffect((()=>{y.isSignedIn()&&T==="Completed"&&G.tenantsBaseInOrder.length>0&&(V(F.TENANT_FETCHING),y.saveSignedInUserTenants(Os(G.tenantsBaseInOrder)),I!=null&&fe(I,r,k,void 0,G.tenantsBaseInOrder))}),[G,T,r,I]),P.useEffect((()=>{p==="In-Progress"&&O(F.TENANT_FETCHING),p!=="Completed"&&p!=="Error"||(p==="Completed"&&D!=null?(C(),_.markActiveTenantFetchCompleted(D)):p==="Error"&&D!=null&&(_.markActiveTenantFetchFailed(D),V(F.TENANT_FETCHING),V(F.TENANT_SWITCHING))),T!=="Completed"&&T!=="Error"||(T==="Completed"?_.markAllTenantsFetchCompleted():T==="Error"&&_.markAllTenantsFetchFailed())}),[p,T,D,L]);const le=P.useRef(!1);P.useEffect((()=>{!le.current&&p==="Completed"&&L&&(le.current=!0,(function(a=mt,A=3e3){setTimeout((()=>{const c=t=>{if(t>=a.length)return;const d=a[t],q=ct[d];q!=null?q().then((()=>ae((()=>c(t+1))))).catch((()=>ae((()=>c(t+1))))):c(t+1)};ae((()=>c(0)))}),A)})())}),[p,L]);const U=r?.userRole!=null&&Us(r?.userRole),{isFeatureEnabled:Ye}=H(S.isReferralFeatureEnabled),{isFeatureEnabled:We}=H(S.isAccrualEnabled),Ke=r?.userRole!=null&&r.userRole.includes("charge_card_user"),Qe=r?.userRole!=null&&r.userRole.includes("charge_card_admin"),w=r?.userRole!=null&&pe(r.userRole),ue=r?.company==null||r.company.featuresActivationInfo?.isBillPayFeatureEnabled&&!U,de=!Be&&!U,Xe=Ps(h?.loggedInUserRoleMap),Je=r.externalConnections?.accounting[0]?.isValid,es=r.externalConnections?.fetchState==="Completed",te=r.company?.companyOnboardingInfo.isOnboardingCompleted,ce=r?.company==null||r.company.featuresActivationInfo?.isReimbursementFeatureEnabled&&!U,me=ce&&ws(h?.loggedInUserRoleMap),_e=Fe&&!U,ss=Le&&!U,ts=ue&&Fs(h?.loggedInUserRoleMap),ns=de&&Ls(h?.loggedInUserRoleMap),as=_e&&ks(h?.loggedInUserRoleMap),os=Vs(h?.loggedInUserRoleMap),rs=Hs(h?.loggedInUserRoleMap),is=Bs(h?.loggedInUserRoleMap),ls=Ss(h?.loggedInUserRoleMap),us=Ns(h?.loggedInUserRoleMap),g=Ms(h?.loggedInUserRoleMap),x=Zs(h?.loggedInUserRoleMap),Ee=ue&&g,he=ce&&x,R=_e&&is,j=ss&&ls,m=de&&us,ds=r.excludedResources?.resources?.find((a=>a.resource==="/invites"))!=null||ze===!0||Xe===!0||os===!0||rs===!0;return y.isSignedIn()?D==null?T==="Completed"?e.jsx(u,{to:"/",replace:!0,state:{...z.state,message:"...",origin:z.pathname}}):(I!=null&&T!=="In-Progress"&&b(ge(I.userId,I.zeniSessionId)),null):p!=="In-Progress"&&p!=="Not-Started"||T==="Completed"?(te===!0||K&&!ee)&&es&&Je!==!0&&E===!1&&X===!1&&re===!1?(o(void 0),e.jsx(u,{to:"/connection/auth",replace:!0})):!L||re!==!0||te!==!0||ee||K?!L||te!==!1||ee||K?L&&r?.userRole&&E!=null&&X!=null&&i!=null&&Object.keys(h.loggedInUserRoleMap).length>0?e.jsx(Ks,{children:e.jsxs(n,{element:e.jsx(ot,{}),children:[e.jsx(n,{path:"/",element:e.jsx(Lt,{isDashboardAccess:w,showZeniAccountRoute:R,isUserHasBillPayAccess:g,isUserHasReimbursementAccess:x,showTreasuryRoute:j,isTenantBankingOnly:E,isTenantCardsOnly:X,showChargeCardRoute:m})}),e.jsx(n,{path:"dashboard/*",element:w?e.jsx(jt,{}):e.jsx(v,{showZeniAccountRoute:R,isUserHasBillPayAccess:g,isUserHasReimbursementAccess:x,showTreasuryRoute:j,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"reports/*",element:w?e.jsx(_t,{}):e.jsx(v,{showZeniAccountRoute:R,isUserHasBillPayAccess:g,isUserHasReimbursementAccess:x,showTreasuryRoute:j,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"people/*",element:ds||w?e.jsx(ht,{}):e.jsx(v,{showZeniAccountRoute:R,isUserHasBillPayAccess:g,isUserHasReimbursementAccess:x,showTreasuryRoute:j,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"forecast/*",element:w?e.jsx(pt,{}):e.jsx(v,{showZeniAccountRoute:R,isUserHasBillPayAccess:g,isUserHasReimbursementAccess:x,showTreasuryRoute:j,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"onboarding/*",element:e.jsx(gt,{})}),e.jsx(n,{path:"transaction/*",element:w&&U===!1||Ke||Qe?e.jsx(Rt,{}):e.jsx(v,{showZeniAccountRoute:R,isUserHasBillPayAccess:g,isUserHasReimbursementAccess:x,showTreasuryRoute:j,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"transactions/*",element:w&&U===!1?e.jsx(bt,{}):e.jsx(v,{showZeniAccountRoute:R,isUserHasBillPayAccess:g,isUserHasReimbursementAccess:x,showTreasuryRoute:j,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"customer/*",element:w&&U===!1?e.jsx(ve,{entityType:"customer"}):e.jsx(v,{showZeniAccountRoute:R,isUserHasBillPayAccess:g,isUserHasReimbursementAccess:x,isTenantBankingOnly:E,showTreasuryRoute:j,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"vendor/*",element:w&&U===!1?e.jsx(ve,{entityType:"vendor"}):e.jsx(v,{showZeniAccountRoute:R,isUserHasBillPayAccess:g,isUserHasReimbursementAccess:x,showTreasuryRoute:j,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"tasks",element:e.jsx(Ft,{})}),e.jsx(n,{path:"tasks/*",element:e.jsx(Pt,{})}),e.jsx(n,{path:"address/*",element:ts||me||as||ns?e.jsx(Et,{}):e.jsx(v,{showZeniAccountRoute:R,isUserHasBillPayAccess:g,isUserHasReimbursementAccess:x,showTreasuryRoute:j,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"checking/*",element:R?e.jsx(At,{}):e.jsx(f,{})}),e.jsx(n,{path:"treasury/*",element:j?e.jsx(ft,{}):e.jsx(f,{})}),e.jsx(n,{path:"performance",element:Q===!0?e.jsx(vt,{}):e.jsx(Pe,{tenantEmailDomain:i})}),e.jsx(n,{path:"month_end_close_checks/review/*",element:Q===!0&&U===!1?e.jsx(Ct,{}):e.jsx(Pe,{tenantEmailDomain:i})}),e.jsx(n,{path:"expense-automation/actual-matching/:matchId",element:Q===!0&&U===!1&&We===!0?e.jsx(Ot,{}):e.jsx(f,{})}),e.jsx(n,{path:"notifications/*",element:e.jsx(yt,{})}),e.jsx(n,{path:"vendors/*",element:$e?e.jsx(xt,{}):e.jsx(f,{})}),e.jsx(n,{path:"bill/*",element:Ee?e.jsx(Ce,{}):e.jsx(v,{showZeniAccountRoute:R,isUserHasBillPayAccess:g,isUserHasReimbursementAccess:x,showTreasuryRoute:j,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"bills/*",element:Ee?e.jsx(Ce,{}):e.jsx(v,{showZeniAccountRoute:R,isUserHasBillPayAccess:g,isUserHasReimbursementAccess:x,showTreasuryRoute:j,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"reimbursement/*",element:he?e.jsx(Oe,{}):e.jsx(v,{showZeniAccountRoute:R,isUserHasBillPayAccess:g,isUserHasReimbursementAccess:x,showTreasuryRoute:j,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"reimbursements/*",element:he?e.jsx(Oe,{}):e.jsx(v,{showZeniAccountRoute:R,isUserHasBillPayAccess:g,isUserHasReimbursementAccess:x,showTreasuryRoute:j,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"settings/*",element:Se?e.jsx(It,{hasAdminLevelAccess:me}):e.jsx(f,{})}),e.jsx(n,{path:"invoicing/*",element:Me&&Ze?e.jsx(Tt,{}):e.jsx(f,{})}),e.jsx(n,{path:"cards/ask",element:m&&M?e.jsx(Ue,{isFileUploadEnabled:J}):e.jsx(f,{})}),e.jsx(n,{path:"cards/ask/:session_id",element:m&&M?e.jsx(Ue,{isFileUploadEnabled:J}):e.jsx(f,{})}),e.jsx(n,{path:"cards/*",element:m?e.jsx(Dt,{}):e.jsx(f,{})}),e.jsx(n,{path:"rewards/*",element:Ye?e.jsx(Ut,{}):e.jsx(f,{})}),e.jsx(n,{path:"/ai-cfo",element:M?e.jsx(u,{to:"explore"}):e.jsx(f,{})}),e.jsx(n,{path:"/ai-cfo/",element:M?e.jsx(u,{to:"explore"}):e.jsx(f,{})}),e.jsx(n,{path:"/ai-cfo/:session_id",element:M?e.jsx(wt,{isFileUploadEnabled:J}):e.jsx(f,{})}),e.jsx(n,{path:"*",element:e.jsx(f,{})})]})}):null:(o(void 0),e.jsx(u,{to:`/${i}/onboarding`,replace:!0})):(o(void 0),e.jsx(u,{to:`/${i}/onboarding/thankyou`,replace:!0})):null:(console.warn("User logged out!!"),o(void 0),e.jsx(u,{to:"/signin/auth",replace:!0,state:{...z.state,message:"...",origin:z.pathname}}))}},Symbol.toStringTag,{value:"Module"}));export{v as F,$t as S};
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
import{j as u}from"./liveblocks-BLPKVqHo.js";import{h as Q,g as X,u as ee,i as H,j as v,N as j,l as G,t as Xe}from"./core-pDUZcPB0.js";import{bK as en,fI as F,cH as nn,HZ as $,Z6 as tn,Z9 as an,v1 as ne,uR as te,mC as ae,BR as L,Zb as Ce,gJ as We,gI as He,gH as Ge,Zc as sn,I6 as on,MD as he,Mu as Ie,Mr as Ae,M9 as Y,Mx as _e,MA as ke,MG as ve,Cj as Pe,h1 as cn,cC as rn,e0 as un,d$ as dn,dj as ln,bu as pn,cv as Fe,Zd as mn,L9 as de,LN as yn,Ze as fn,bL as gn,NY as le,NM as Sn,Zf as bn,Zg as Cn,O0 as hn,O4 as In,Zh as je,BK as An,Ss as _n,OC as be,Pr as pe,Zi as kn,Zj as vn,Zk as Pn,Zl as Ke,Zm as Tn,Vw as En,Yn as Dn,VL as Un,Zn as qe,Md as On,VM as wn,Mh as Fn,Zo as we,OM as Je,mK as Vn,uU as Ye,BT as xn,bF as Re,C3 as Le,cF as Bn,Zp as Qe,Oj as jn,Ok as Rn,Oo as Ln,Zq as Nn,OF as Ne,Zr as Mn,Zs as zn,Zt as Zn,Zu as $n,gY as Wn,Ji as Hn,Zv as Gn,Jn as Kn,Jm as qn}from"./zeni-epic-state-Bke7DGFg.js";import{ai as Te,_ as ie,c as me,m as J,E as Ee,z as E,a8 as se,j as D,a7 as De,T as W,bQ as Jn,ae as oe,bR as V,bi as Ve,bS as Yn,bT as Qn,bU as Xn,r as Be,bV as et,p as Me,aG as ze,a1 as nt,ab as tt,bW as at,bX as it,bY as st,w as ot}from"./index-DElaqJ7F.js";import{a as h}from"./sentry-BYwRJ99F.js";import{n as xe,D as ct,S as rt}from"./mui-BiqpQr6x.js";import{u as ut,B as Oe}from"./BusinessVerificationPageScreen-gGCsmsgi.js";import{M as ye}from"./MobileAppDrawer-C8UsE0YH.js";import R from"./NotFoundScreen-rNNJF3rA.js";import{a as Ze}from"./analyticsHelper-CT62vOeP.js";import{d as $e}from"./routePaths-KJ0Mf_VR.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},o=new e.Error().stack;o&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[o]="337c3b58-bd41-4978-a5cd-7325bf7c8ca8",e._sentryDebugIdIdentifier="sentry-dbid-337c3b58-bd41-4978-a5cd-7325bf7c8ca8")}catch{}})();const dt=xe.div`
|
|
2
|
-
display: flex;
|
|
3
|
-
height: 100%;
|
|
4
|
-
width: 100%;
|
|
5
|
-
flex: 1 1 auto;
|
|
6
|
-
flex-direction: column;
|
|
7
|
-
align-items: center;
|
|
8
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
9
|
-
`,lt=G((function(e,o){const{isUserBillPayAdmin:a,companyId:t}=o,r=F(e),n=tn(e),i=E.getSignedInUser(),l=r.tenantId,s={userId:i?.userId??"",sessionId:i?.zeniSessionId??"",tenantId:l??""},c=an(e,t),p=a&&c.updateStatus.fetchState!=="In-Progress"&&c.plaidConnectionDetails.link_account.updateStatus.fetchState!=="In-Progress"&&c.plaidConnectionDetails.update_account.updateStatus.fetchState!=="In-Progress"&&c.accountUpdateStatus?.fetchState!=="In-Progress"?void 0:"readonly";return{billPaySetupView:c,connectedAccountProvider:r.company?.featuresActivationInfo.connectedAccountProvider??"",showIntlWiseWidget:o.showIntlWiseWidget,isDisabled:p,billpayApprovalView:n,analytics:D,filesEndPoint:`${oe.fileMicroServiceBaseUrl}`,authParams:s}}),(function(e,o){const{navigate:a,companyId:t,currentTenant:r}=o;return{onBusinessVerificationSectionClick:()=>{a("../verification"),r?.company?.companyBillPayInfo!=null&&r?.company?.companyBillPayInfo?.businessVerificationStatus?.code==="pending_review"&&e($(t,!1,!0))},onSetupApprovalRulesSectionClick:()=>{a("../approval-rules")},onFetchLinkTokenClick:(n,i)=>{e(Pe("bill_pay_setup",n,i))},onEstablishConnectionClick:n=>{e(ve(n,t,"bill_pay_setup","bill_pay"))},onUpdatePaymentAccountStatus:(n,i,l)=>{e(ke(n,i,"bill_pay","bill_pay_setup",l))},onUpdatePaymentAccountLoginStatus:(n,i)=>{e(_e(!1,n,"bill_pay","bill_pay_setup",i))},onEstablishConnectionSuccess:()=>{e($(t,!0))},onEnableBillPayClick:()=>{e(Y(t,"bill_pay"))},onUpdateAccountClick:(n,i,l)=>{e(l==="paymentAccount"?Ie(n,i,"bill_pay","bill_pay_setup"):Ae("reimbursement_setup",n,i))},onUpdatePrimaryFundingAccount:(n,i)=>{e(he(t,"bill_pay_setup",n,i))},onEnableBillPaySuccess:()=>{a("../",{relative:"path"})},onBackClick:()=>{r?.companyBillPayInfo?.info?.isBillPayEnabled!=null&&r.companyBillPayInfo.info.isBillPayEnabled===!1?a("../.."):a("../",{relative:"path"})},onAcceptUpdatedTOS:()=>{e(on(t))},onAcceptUpdatedTOSSuccess:()=>{e($(t,!0))},onGetOtp:(n,i)=>{e(Ge(n,"SpendManagementSetup")),i!=null&&e(sn({officerType:i,phone:n}))},onResendOtp:n=>{e(He(n,"SpendManagementSetup"))},onVerifyOtp:(n,i)=>{e(We(n,i,"SpendManagementSetup"))},onVerifyOtpSuccess:(n,i)=>{n!=null&&i!=null&&e(L(t,n,"bill_pay",!0,!0))},onNavigateToDashboard:()=>{a("../../dashboard")},onNavigateToSettings:()=>{a("../bills/setup")},onInternationPaymentSetUpClick:()=>{a("../international-wire")},onCompanyOfficerUpdated:(n,i)=>{e(Ce({officerType:n,fileIds:i}))},onSendForVerificationClick:n=>{e(L(t,n,"bill_pay",!0,!0,!0))},updateFilesEntity:n=>{e(ae({files:n}))},onDeleteFile:n=>{e(te(n))},onEditFileName:(n,i)=>{e(ne(n,i.split(".")[0]))}}}))(Jn),pt=()=>{const e=Te(),o=Q(),a=X(),t=ee(),{tenantEmailDomain:r}=H(),n=ie(),i=en(n?.loggedInUserRoleMap),{useFeatureGate:l}=me(),{isFeatureEnabled:s}=l(J.billPaySetupShowInternationalPaymentByWise),{isFeatureEnabled:c}=l(J.isBillPayLocalCurrencyFeatureEnabled),p=Ee(),[g,S]=h.useState(!1),_=h.useRef(!1),I=v((m=>m.billPaySetupViewState.fetchState)),d=v((m=>F(m)));ut();const y=d.companyId??E.getSignedInUserTenant(r)?.companyId;if(E.getSignedInUser()==null)throw Error("Can't access bill pay setup page without signing in...");const f=!!d.companyBillPayInfo?.info?.isBillPayTOSAccepted,P=nn(n?.loggedInUserRoleMap);h.useEffect((()=>{_.current||I!=="Not-Started"||y==null?_.current||I!=="Completed"||y==null||d.companyBillPayInfo?.info?.businessVerificationStatus?.code!=="pending_review"||(_.current=!0,t($(y,!1,!0))):(_.current=!0,t($(y,!0)))}),[I,y,t]);const b=m=>{S(m)};if(f===!1||P&&!n?.loggedInUserRoleMap?.bill_pay_admin)return u.jsx(j,{to:"../promo"});if(f===!0&&n?.loggedInUserRoleMap!=null){const m=C=>C.trackPageLoaded(W.Event.billPaySetup);return u.jsxs(dt,{children:[u.jsx(se,{analytics:D,onLoad:C=>m(C)}),u.jsx(ye,{isAppContentDrawerOpen:g,handleDrawerToggle:b}),u.jsx(lt,{navigate:o,location:a,companyId:y,currentTenant:d,isUserBillPayAdmin:i,showIntlWiseWidget:s,meetingUrl:e("bill_pay_setup"),onClickMenuIcon:()=>{b(!0)},isLocalCurrencyEnabled:c})]})}return u.jsx(De,{fetchState:"In-Progress",style:{backgroundColor:p.colors.grey5}})},$t=(e,o)=>e!=null&&(function(a){return a==="debit"||a==="credit"||a==="debit_and_credit"})(e)?e:o,Wt=e=>`/${e}/cards`,Ht=e=>`/${e}/cards/setup`,Gt=e=>`/${e}/cards/onboard`,Kt=(e,o,a,t,r=!1)=>{let n=`/${e}/cards/${encodeURIComponent(o)}`;return t==null||t.status.code!=="inactive"||t.cardHolderUserId!==a.userId||t.type.code!=="business_physical_credit_card"&&t.type.code!=="business_physical_debit_card"?t!=null&&t.status.code==="active"&&t.cardHolderUserId===a.userId&&t.type.code==="business_physical_credit_card"&&r===!0?n+="/addToWallet":t==null||t.type.code!=="business_physical_debit_card"&&t.type.code!=="business_virtual_debit_card"||t.status.code!=="active"||t.cardHolderUserId!==a.userId||t.isPinSet!==!1||(n+="/setPin"):n+="/activate",n},qt=(e,o)=>e.find((a=>a.id===o)),Jt=(e,o,a)=>!e||!o||a.fetchState==="Completed",mt=(e,o,a,t)=>({isCreditCardOffered:e,isDebitCardOffered:o,isDebitCardEnabled:a,isCreditCardEnabled:t}),Yt=(e,o)=>e?{creditCardCashbackOffer:`${o.cashbackAnalytics.creditCardCashbackOffer}%`,debitCardCashbackOffer:`${o.cashbackAnalytics.debitCardCashbackOffer}%`,totalEarnedCashback:V(o.cashbackSummary.cashbackEarned.amount),redeemedCashback:V(o.cashbackSummary.cashbackRedeemed.amount),availableCashback:V(o.cashbackSummary.cashbackAvailable.amount),creditCardCashbackRedemptionMode:o.cashbackAnalytics.creditCardCashbackRedemptionMode,debitCardCashbackRedemptionMode:o.cashbackAnalytics.debitCardCashbackRedemptionMode}:void 0,Qt=(e,o,a,t,r)=>e&&o&&a?{creditAccountId:t.id,creditAccountLimit:V(t.limit.amount),creditAccountAvailableAmount:V(t.available.amount),creditAccountSpentAmount:V(t.balance.amount+t.hold.amount),creditAccountStatus:t.status,outstandingBalance:V(r.remainingAmountDue.amount)}:void 0,Xt=(e,o,a,t,r)=>e&&o&&a?{debitAccountId:t.depositAccounts.map((n=>n.id)),debitAccountName:t.depositAccounts.map((n=>n.accountName)),debitAccountBalance:t.depositAccounts.map((n=>V(n.accountBalance.available.amount))),debitCardsSpend:V(r?.currentMonthSpends.amount??0),debitAccountStatus:t.depositAccounts.map((n=>n.accountStatus))}:void 0,ea=(e,o)=>e&&o.depositAccountLimit!=null&&o.chargeCard!=null?{debitAccountId:o.depositAccountLimit.id,debitAccountName:o.depositAccountLimit?.accountName??o.connectedAccount?.accountName,debitAccountBalance:V(o.depositAccountLimit?.accountBalance.available.amount),debitCardsSpend:V(o.chargeCard.limit.amount-o.chargeCard.available.amount),debitAccountStatus:o.depositAccountLimit?.accountStatus??o.connectedAccount?.accountStatus}:void 0,na=80,ta=80,aa=e=>e.companyId??E.getSignedInUserTenant(e.tenantEmailDomain)?.companyId,yt=({isBankingOnlyTenant:e,isDebitCardFeatureEnabled:o})=>o||e,ft=({isCardsOnlyTenant:e,isChargeCardFeatureEnabled:o,isBookKeepingTenant:a,isDebitCardProductVisible:t,chargeCardsCreditAccountLimit:r})=>(e||o||a)&&(!t||r>0),ia=({isCardsOnlyTenant:e,isChargeCardFeatureEnabled:o,isBookKeepingTenant:a})=>e||o||a,sa=({cardInfo:e,isProductVisible:o,isTOSAccepted:a,isSetupEnabled:t,isUserHasCardsAdminLevelAccess:r,isUserHasCardsAccess:n})=>!!e&&o&&(!a&&r||n&&!r&&!t),gt=G((function(e,o){const{isUserChargeCardAdmin:a,chargeCardSetUpView:t,isDebitCardOnlyEnabled:r,isCreditCardOnlyEnabled:n}=o,i=F(e),l=E.getSignedInUser(),s=i.tenantId,c={userId:l?.userId??"",sessionId:l?.zeniSessionId??"",tenantId:s??""},p=a&&t.updateStatus.fetchState!=="In-Progress"&&t.plaidConnectionDetails.link_account.updateStatus.fetchState!=="In-Progress"&&t.plaidConnectionDetails.update_account.updateStatus.fetchState!=="In-Progress"&&t.accountUpdateStatus?.fetchState!=="In-Progress"?void 0:"readonly";return{chargeCardSetUpView:t,connectedAccountProvider:i.company?.featuresActivationInfo.connectedAccountProvider??"",isDisabled:p,analytics:D,isDebitCardOnlyEnabled:r,isCreditCardOnlyEnabled:n,filesEndPoint:`${oe.fileMicroServiceBaseUrl}`,authParams:c}}),(function(e,o){const{navigate:a,companyId:t,currentTenant:r,chargeCardSetUpView:n,isDebitCardTOSAccepted:i,isChargeCardTOSAccepted:l,isChargeCardSetupEnabled:s,isDebitCardSetupEnabled:c,productInformation:p,controllerEmails:g,businessVerificationStatus:S,isCardPolicyEnabled:_,isUserChargeCardAdmin:I}=o;return{onBusinessVerificationSectionClick:()=>{D.trackCardsVerifyIdentityCompanyDetailsClick(g,p,S?.code),a("../verification"),r?.company?.companyChargeCardInfo!=null&&r.company.companyBillPayInfo?.businessVerificationStatus?.code==="pending_review"&&e(de(t,!1,!0))},...I&&_?{onCardPolicySectionClick:()=>{a("../policy")}}:{},onFetchLinkTokenClick:(d,y)=>{e(Pe("charge_card_setup",d,y))},onEstablishConnectionClick:d=>{e(ve(d,t,"charge_card_setup","charge_cards"))},onUpdatePaymentAccountStatus:(d,y,f)=>{e(ke(d,y,"charge_cards","charge_card_setup",f))},onUpdatePaymentAccountLoginStatus:(d,y)=>{e(_e(!1,d,"charge_cards","charge_card_setup",y))},onEstablishConnectionSuccess:()=>{e(de(t,!0))},onEnableChargeCardClick:()=>{D.trackCardsEnableCardsClick(g,p,"Cards Card Setup"),l===!0&&i===!0&&s===!1&&c===!1?e(Y(t,"charge_cards__debit_cards")):l===!0&&s===!1?e(Y(t,"charge_cards")):i===!0&&c===!1&&e(Y(t,"debit_cards"))},onUpdateChargeCardClick:(d,y,f)=>{const P=n.allBankAccounts.find((m=>m.accountId===n.primaryFundingAccount?.zeniAccountId)),b=n.allBankAccounts.find((m=>m.accountId===d));D.trackCardsZeniCashAccountChangeClick(g,p,{oldZeniCashAccount:P?.accountName??"",newZeniCashAccount:b?.accountName??"",oldZeniCashAccountPosition:n.allBankAccounts.findIndex((m=>m.accountId===n.primaryFundingAccount?.zeniAccountId))+1,newZeniCashAccountPosition:n.allBankAccounts.findIndex((m=>m.accountId===d))+1,numberOfCashAccounts:n.allBankAccounts.length}),e(f==="paymentAccount"?Ie(d,y,"charge_cards","charge_card_setup"):Ae("charge_card_setup",d,y))},onUpdatePrimaryFundingAccount:(d,y)=>{const f=n.allFundingAccounts.find((m=>m.id===d)),P=n.allFundingAccounts.findIndex((m=>m.id===n.primaryFundingAccount?.id))+1,b=n.allFundingAccounts.findIndex((m=>m.id===d))+1;D.trackCardsPaymentAccountChangeClick(g,p,{oldPaymentAccountName:n.primaryFundingAccount?.label??"",oldPaymentAccountBalance:V(n.primaryFundingAccount?.accountBalance?.available?.amount??0),newPaymentAccountName:f?.label??"",newPaymentAccountBalance:V(f?.accountBalance?.available?.amount??0),isOldPaymentAccountRecommended:n.primaryFundingAccount?.accType==="depositAccount",isNewPaymentAccountRecommended:f?.accType==="depositAccount",oldPaymentAccountPosition:P,newPaymentAccountPosition:b,numberOfPaymentAccounts:n.allFundingAccounts.length}),e(he(t,"charge_card_setup",d,y))},onEnableChargeCardSuccess:()=>{e(fn()),a("../",{relative:"path"})},onBackClick:()=>{r?.companyChargeCardInfo?.info?.isChargeCardEnabled||r?.companyDebitCardInfo?.info?.isDebitCardEnabled?a("../",{relative:"path"}):a("../..",{relative:"path"})},onNavigateToDashboard:()=>{a("../../dashboard")},onCompanyOfficerUpdated:(d,y)=>{e(Ce({officerType:d,fileIds:y}))},onSendForVerificationClick:d=>{l===!0&&i===!0?e(L(t,d,"charge_cards__debit_cards",!0,!0,!0)):l===!0?e(L(t,d,"charge_cards",!0,!0,!0)):i===!0&&e(L(t,d,"debit_cards",!0,!0,!0))},updateFilesEntity:d=>{e(ae({files:d}))},onDeleteFile:d=>{e(te(d))},onEditFileName:(d,y)=>{e(ne(d,y.split(".")[0]))},onUpdateAutoPayClick:d=>{e(yn(t,d))}}}))(Yn),St=()=>{const e=Te(),o=Q(),a=X(),t=ee(),{tenantEmailDomain:r}=H(),n=ie(),i=v((N=>F(N))),{useDynamicConfig:l,useFeatureGate:s}=me(),c=a.state?.pathnameStackToGoBack?.[0],{configValue:p}=l(Ve.zeniCardsConfig),g=p.credit_card_auto_pay_threshold_by_company_id?.[i.companyId]??p.default_credit_card_auto_pay_threshold??80,{isFeatureEnabled:S}=s(J.isDebitCardFeatureEnabled),{isFeatureEnabled:_}=s(J.isChargeCardFeatureEnabled),{isFeatureEnabled:I}=s(J.isEarlyPayFeatureEnabled),{isFeatureEnabled:d}=s(J.isCardPolicyEnabled),y=v((N=>cn(N,i.companyId))),f=rn(y.controllers),P=!!i.company?.companyChargeCardInfo.isChargeCardEnabled,b=!!i.company?.companyDebitCardInfo.isDebitCardEnabled,m=un(S,i),C=yt({isDebitCardFeatureEnabled:S,isBankingOnlyTenant:m}),k=dn(i),T=ln(i),A=i.companyChargeCardInfo?.info?.chargeCardsCreditAccountLimit??0,U=ft({isCardsOnlyTenant:k,isChargeCardFeatureEnabled:_,isBookKeepingTenant:T,isDebitCardProductVisible:C,chargeCardsCreditAccountLimit:A}),M=C&&U===!1,x=C===!1&&U,z=pn(n?.loggedInUserRoleMap),w=Fe(n?.loggedInUserRoleMap),[ce,K]=h.useState(!1),[q,re]=h.useState(!1),Z=v((N=>N.chargeCardSetupViewState.fetchState)),B=E.getSignedInUserTenant(r)?.companyId??i.companyId,O=E.getSignedInUser(),Ue=N=>{K(N)},fe=v((N=>mn(N,B)));if(O==null)throw Error("Can't access charge card setup page without signing in...");h.useEffect((()=>{q||Z!=="Not-Started"||B==null?q||Z!=="Completed"||B==null||i.companyBillPayInfo?.info?.businessVerificationStatus?.code!=="pending_review"||t(de(B,!1,!0)):(re(!0),t(de(B,!0)))}),[q,Z,B,t]);const ge=!!i.company?.companyChargeCardInfo.isChargeCardTOSAccepted,Se=!!i.company?.companyDebitCardInfo.isDebitCardTOSAccepted,ue=mt(U,C,b,P);return ge||Se?ge||Se?u.jsxs(u.Fragment,{children:[u.jsx(se,{analytics:D,onLoad:()=>{D.trackPageLoaded(W.Event.cardsSetupVisited),D.trackCardsCardSetupView(f,ue,c==null?"Cards Setup":c.includes("cards/promo")?"Promo":c.includes("cards")?"Settings":"Cards Tab")}}),u.jsx(ye,{isAppContentDrawerOpen:ce,handleDrawerToggle:Ue}),u.jsx(gt,{autoPayThreshold:g,navigate:o,meetingUrl:e("charge_card_setup"),location:a,companyId:B,currentTenant:i,isEarlyPayEnabled:I,isChargeCardTOSAccepted:ge,isDebitCardTOSAccepted:Se,isUserChargeCardAdmin:z,isCardPolicyEnabled:d,isDebitCardOnlyEnabled:M,isCreditCardOnlyEnabled:x,chargeCardSetUpView:fe,isCreditCardProductVisible:U,isDebitCardFeatureEnabled:C,isChargeCardSetupEnabled:P,isDebitCardSetupEnabled:b,businessVerificationStatus:i.companyBillPayInfo?.info?.businessVerificationStatus,controllerEmails:f,productInformation:ue,onClickMenuIcon:()=>{Ue(!0)},hasZeniAccountsAdminAccess:w})]}):u.jsx(De,{fetchState:"Not-Started"}):u.jsx(j,{to:"../promo"})},bt=xe.div`
|
|
10
|
-
display: flex;
|
|
11
|
-
height: 100%;
|
|
12
|
-
width: 100%;
|
|
13
|
-
flex: 1 1 auto;
|
|
14
|
-
flex-direction: column;
|
|
15
|
-
align-items: center;
|
|
16
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
17
|
-
`,Ct=G((function(e,o){const{isUserRemiAdmin:a,companyId:t}=o,r=F(e),n=bn(e),i=Cn(e,t),l=E.getSignedInUser(),s=r.tenantId,c={userId:l?.userId??"",sessionId:l?.zeniSessionId??"",tenantId:s??""};return{remiSetupView:i,isDisabled:a&&i.updateStatus.fetchState!=="In-Progress"&&i.plaidConnectionDetails.link_account.updateStatus.fetchState!=="In-Progress"&&i.plaidConnectionDetails.update_account.updateStatus.fetchState!=="In-Progress"&&i.accountUpdateStatus?.fetchState!=="In-Progress"?void 0:"readonly",remiApprovalView:n,connectedAccountProvider:r.company?.featuresActivationInfo.connectedAccountProvider??"",analytics:D,filesEndPoint:`${oe.fileMicroServiceBaseUrl}`,authParams:c}}),(function(e,o){const{navigate:a,companyId:t,currentTenant:r}=o;return{updateMileageDetails:n=>{const{mileageAmount:i,mileageUnit:l,mileageCurrencyCode:s,mileageCurrencySymbol:c,denomination:p,denominationSymbol:g,mileageAmountInDenomination:S,description:_}=n;e(In({mileageDetails:{mileageUnitAmount:{amount:i,currencyCode:s,currencySymbol:c},denomination:p,denominationSymbol:g,mileageAmountInDenomination:S,mileageCurrencyCode:s,mileageCurrencySymbol:c,mileageUnit:l,description:_}}))},onSaveMileageClick:n=>{e(hn(t)),D.trackReimbursementMileageRateSave(n)},onBusinessVerificationSectionClick:()=>{a("../verification"),r?.company?.companyReimbursementInfo!=null&&r?.company?.companyBillPayInfo?.businessVerificationStatus?.code==="pending_review"&&e(le(t,!1,!0))},onSetupApprovalRulesSectionClick:()=>{a("../approval-rules")},onFetchLinkTokenClick:(n,i)=>{e(Pe("reimbursement_setup",n,i))},onEstablishConnectionClick:n=>{e(ve(n,t,"reimbursement_setup","reimbursement"))},onUpdatePaymentAccountStatus:(n,i,l)=>{e(ke(n,i,"reimbursement","reimbursement_setup",l))},onUpdatePaymentAccountLoginStatus:(n,i)=>{e(_e(!1,n,"reimbursement","reimbursement_setup",i))},onEstablishConnectionSuccess:()=>{e(le(t,!0))},onEnableRemiClick:()=>{e(Y(t,"reimbursement"))},onUpdateAccountClick:(n,i,l)=>{e(l==="paymentAccount"?Ie(n,i,"reimbursement","reimbursement_setup"):Ae("reimbursement_setup",n,i))},onEnableRemiSuccess:()=>{a("../",{relative:"path"})},onBackClick:()=>{r?.companyReimbursementInfo?.info?.isReimbursementEnabled!=null&&r.companyReimbursementInfo.info.isReimbursementEnabled===!1?a("../.."):a("../",{relative:"path"})},onCompanyOfficerUpdated:(n,i)=>{e(Ce({officerType:n,fileIds:i}))},onSendForVerificationClick:n=>{e(L(t,n,"reimbursement",!0,!0,!0))},updateFilesEntity:n=>{e(ae({files:n}))},onDeleteFile:n=>{e(te(n))},onEditFileName:(n,i)=>{e(ne(n,i.split(".")[0]))},onUpdatePrimaryFundingAccount:(n,i)=>{e(he(t,"reimbursement_setup",n,i))}}}))(Xn),ht=()=>{const e=Te(),o=Q(),a=X(),t=ee(),{tenantEmailDomain:r}=H(),n=ie(),i=Ee(),l=gn(n?.loggedInUserRoleMap),s=Fe(n?.loggedInUserRoleMap),[c,p]=h.useState(!1),g=h.useRef(!1),[S,_]=h.useState(!1),I=v((k=>k.remiSetupViewState.fetchState)),d=v((k=>F(k))),y=v((k=>k.remiSetupApproverViewState.fetchState)),{isApprovalRulesV3Enabled:f,isLoading:P}=Qn(d?.tenantId),b=E.getSignedInUserTenant(r)?.companyId??d.companyId,m=E.getSignedInUser(),C=k=>{p(k)};if(m==null)throw Error("Can't access reimbursement setup page without signing in...");if(h.useEffect((()=>{g.current||I!=="Not-Started"||b==null?g.current||I!=="Completed"||b==null||d.companyBillPayInfo?.info?.businessVerificationStatus?.code!=="pending_review"||(g.current=!0,t(le(b,!1,!0))):(g.current=!0,t(le(b,!0)))}),[I,b,t]),h.useEffect((()=>{S||y!=="Not-Started"||P||(_(!0),t(Sn(!0,!1,!1,f)))}),[S,y,P,f,t]),d.companyReimbursementInfo?.info?.isReimbursementTOSAccepted===!1)return u.jsx(j,{to:"../promo"});if(d.companyReimbursementInfo?.info?.isReimbursementTOSAccepted===!0){const k=T=>T.trackPageLoaded(W.Event.reimbursementSetup);return u.jsxs(bt,{children:[u.jsx(se,{analytics:D,onLoad:T=>k(T)}),u.jsx(ye,{isAppContentDrawerOpen:c,handleDrawerToggle:C}),u.jsx(Ct,{navigate:o,location:a,companyId:b,currentTenant:d,isUserRemiAdmin:l,meetingUrl:e("reimbursement_setup"),onClickMenuIcon:()=>{C(!0)},hasZeniAccountsAdminAccess:s})]})}return u.jsx(De,{fetchState:"In-Progress",style:{backgroundColor:i.colors.grey5}})},It=G((function(e,o){const{businessVerificationDetails:a,productType:t}=o,r=F(e),n=E.getSignedInUser(),i=r.tenantId,l={userId:n?.userId??"",sessionId:n?.zeniSessionId??"",tenantId:i??""},s=En(o.roleMap)&&a.updateStatus.fetchState!=="In-Progress"?void 0:"readonly",c=Dn(e.companyConfigState),p=Un(e.userRoleConfigState),g=t==="zeni_treasury"?qe(e):void 0;return{businessVerificationDetails:a,verficationDetailsFetchState:a.fetchState,isRefreshingViewInBackground:a.isRefreshingViewInBackground,allNationalityCountries:a.allNationalityCountries,filesEndPoint:`${oe.fileMicroServiceBaseUrl}`,authParams:l,isDisabled:s,allIndustries:c.companyIndustries??[],companyTitles:p.companyTitles,transferDetails:g}}),(function(e,o){const{companyId:a,productType:t,currentTenant:r,navigate:n,location:i}=o,{tenantEmailDomain:l}=r;return{onCompanyDetailsChanged:s=>{const{companyDescription:c,companyIndustry:p,companyIndustryType:g,companyLegalName:S,companyTaxId:_,companyWebsite:I,companyPhone:d,primaryContactEmail:y,primaryContactName:f,primaryContactUserId:P,primaryContactSyncToken:b,syncToken:m,fileIds:C,incDate:k,typeOfIncorporation:T,stateOfIncorporation:A,sourceOfFunds:U,companySubIndustry:M,countriesOfOperations:x,companySourceOfFunds:z,companySourceOfFundsDescription:w,transactionVolume:ce,transactionVolumeDescription:K,purposeOfAccount:q,purposeOfAccountDescription:re,regulatedStatus:Z,regulatedStatusDescription:B,usNexus:O,usNexusTypes:Ue}=s,fe=g?.selectedOption,ge={companyId:a,companyDescription:c,companyIndustry:p.selectedOption,companyIndustryType:fe==null||fe===""?void 0:fe,companyLegalName:S,taxIdOrEIN:_,website:I!=""&&I!=null?Bn(I):void 0,phone:d,syncToken:m,fileIds:C,incDate:k!=null?Re(k?.toString()):k,typeOfIncorporation:T?.selectedOption??"",stateOfIncorporation:A?.selectedOption??"",sourceOfFunds:U?.selectedOption??"",companySubIndustry:M?.selectedOption??"",countriesOfOperations:x?.selectedOptions.map((ue=>ue.length===2?ue:ze(ue)))??[],companySourceOfFunds:z?.selectedOption??"",companySourceOfFundsDescription:w,transactionVolume:ce?.selectedOption??"",transactionVolumeDescription:K,purposeOfAccount:q?.selectedOption??"",purposeOfAccountDescription:re,regulatedStatus:Z??"",regulatedStatusDescription:B,usNexus:O,usNexusTypes:Ue?.selectedOptions??[]},Se={userId:P,firstName:f.firstName,lastName:f.lastName,email:y,syncToken:b};e(Le({companyDetails:ge,primaryContactDetails:Se}))},onCompanyOfficerUpdated:s=>{const c=s.map((p=>{const{officerType:g,userId:S,name:_,email:I,nationalityCountryCode:d,ssn:y,dob:f,phone:P,syncToken:b,selectDocument:m,role:C,ownership:k,isSelectedForVerification:T,userVerificationStatus:A,treasuryUserVerificationStatus:U,fileIds:M}=p;let x;return m.selectDocumentType==="driverLicense"?x="driving_license":m.selectDocumentType==="passport"?x="passport":m.selectDocumentType==="stateId"?x="id_document":m.selectDocumentType==="ssnCard"&&(x="social_security_card"),{officerType:g,userId:S,firstName:_.firstName,lastName:_.lastName,email:I,ssn:y,nationalityCountryCode:d?.selectedOption!=null?ze(d.selectedOption):void 0,phone:P,birthday:f!=null?Re(f?.toString()):f,syncToken:b,titleAtCompany:C.selectedOption,ownershipInCompany:k,documentTypeSelectedForVerification:x,isSelectedForVerification:T,userVerificationStatus:A,treasuryUserVerificationStatus:U,fileIds:M,additionalDocumentTypesRequestedForVerification:[],additionalSubmittedDocumentsForVerificationFileIds:[],areAdditionalDocumentsRequestedForVerification:!1,areAdditionalDocumentsSubmittedForVerification:!1}}));e(Le({officers:c}))},onSaveDetailsClick:s=>{e(L(a,s,t))},onSendForVerificationClick:s=>{e(L(a,s,t,!0))},onAddressClick:s=>{const c=$e(l,s),p=Me(i.state?.pathnameStackToGoBack,i.pathname),g=new URLSearchParams(i.search),S={};g.forEach(((_,I)=>{S[I]=_})),n(c,{state:{pathnameStackToGoBack:p,queryParams:Object.keys(S).length>0?S:void 0}})},onRegisteredAddressClick:s=>{const c=$e(l,s),p=Me(i.state?.pathnameStackToGoBack,i.pathname),g=new URLSearchParams(i.search),S=Object.fromEntries(g.entries());n(c,{state:{pathnameStackToGoBack:p,queryParams:Object.keys(S).length>0?S:void 0}})},onBackClick:()=>{e(xn({companyId:a})),n("../setup")},updateFilesEntity:s=>{e(ae({files:s}))},onDeleteFile:s=>{e(te(s))},onDeleteFileList:s=>{e(Ye(s))},onEditFileName:(s,c)=>{e(ne(s,c.split(".")[0]))},onGetOtp:s=>{e(Ge(s,"SpendManagementSetup"))},onResendOtp:s=>{e(He(s,"SpendManagementSetup"))},onVerifyOtp:(s,c)=>{e(We(s,c,"SpendManagementSetup"))},saveNewAddressInLocalStore:(s,c)=>{e(Vn({addressType:s,addressToCreate:c}))},onExecuteTreasuryTransfer:()=>{e(Je())},onOverlayClose:()=>{e(we())},onIdentityDocumentUploadedForAutofill:s=>{if(a==null)return;const c=wn(s.documentType);c!=null&&e(Fn({target:"setup",companyId:a,officerType:s.officerType,fileId:s.fileId,documentType:c}))},onCompanyDocumentUploadedForAutofill:s=>{a!=null&&e(On({target:"setup",companyId:a,fileId:s.fileId,documentType:s.documentType}))}}}))(et),At=({productType:e,isBusinessVerificationDrawerOpen:o,closeDrawerHandler:a})=>{const t=Q(),r=X(),n=ee(),[i]=Xe(),l=i.get("showStepProgress"),s=i.get("isTransferInitiated"),[c,p]=h.useState(!1),{tenantEmailDomain:g}=H(),S=ie(),{useDynamicConfig:_}=me(),I=Ee(),{configValue:d}=_(Ve.zeniAccountsConfig),y=je(d),f=v((A=>{switch(e){case"zeni_accounts":return A.zeniAccountSetupViewState.fetchState;case"reimbursement":return A.remiSetupViewState.fetchState;case"charge_cards":return A.chargeCardSetupViewState.fetchState;case"zeni_treasury":return A.treasurySetupViewState.fetchState;default:return A.billPaySetupViewState.fetchState}})),P=v((A=>A.companyConfigState.fetchState)),b=v((A=>A.userRoleConfigState.fetchState)),m=v((A=>F(A))),C=m.companyId??E.getSignedInUserTenant(g)?.companyId;if(h.useEffect((()=>{P==="Not-Started"&&n(An()),b==="Not-Started"&&n(_n(!0))}),[P,b,n]),h.useEffect((()=>{if(!c&&f==="Not-Started"&&C!=null)switch(p(!0),e){case"zeni_accounts":n(pe(C,!0));break;case"zeni_treasury":n(be(C,!0));break;case"reimbursement":n(le(C,!0));break;case"charge_cards":n(de(C,!0));break;default:n($(C,!0))}}),[c,f,C,n]),E.getSignedInUser()==null)throw Error("Can't access business verification without signing in...");let k;switch(e){case"zeni_accounts":k=m.companyZeniAccountInfo?.info?.isZeniAccountTOSAccepted;break;case"reimbursement":k=m.companyReimbursementInfo?.info?.isReimbursementTOSAccepted;break;case"charge_cards":k=m.companyChargeCardInfo?.info?.isChargeCardTOSAccepted===!0||m.companyDebitCardInfo?.info?.isDebitCardTOSAccepted;break;case"zeni_treasury":k=m.companyTreasuryInfo?.info?.isTreasuryTOSAccepted;break;default:k=m.companyBillPayInfo?.info?.isBillPayTOSAccepted}const T=v((A=>{let U;switch(e){case"zeni_accounts":U=Tn(A,C);break;case"zeni_treasury":U=Ke(A,C);break;case"charge_cards":U=Pn(A,C);break;case"reimbursement":U=vn(A,C);break;default:U=kn(A,C)}return U}));return k===!1?null:T.fetchState==="Completed"&&k===!0&&S?.loggedInUserRoleMap!=null?u.jsxs(u.Fragment,{children:[u.jsx(se,{analytics:D,onLoad:A=>(U=>{switch(e){case"zeni_accounts":return U.trackPageLoaded(W.Event.zeniAccountsBusinessVerification);case"reimbursement":case"charge_cards":return U.trackPageLoaded(W.Event.reimbursementBusinessVerification);default:return U.trackPageLoaded(W.Event.billPayBusinessVerification,Be(r)?"Settings":void 0)}})(A)}),u.jsx(It,{businessVerificationDetails:T,navigate:t,location:r,companyId:C,analytics:D,currentTenant:m,productType:e,roleMap:S.loggedInUserRoleMap,isSettings:Be(r),isOverlay:!0,isStepInProgress:l!=null,isTreasuryTransferInitiated:s!=null,onClickMenuIcon:()=>{},maxInsuredAmount:y.maxInsuredAmount,isBusinessVerificationDrawerOpen:o,closeDrawerHandler:a})]}):u.jsx(De,{fetchState:"In-Progress",style:{backgroundColor:I.colors.grey5}})},_t={overlayWidth:new tt(100,100,59)},kt=G((function(e,o){const{isUserZeniAccountsAdmin:a,companyId:t}=o,r=F(e),n=E.getSignedInUser(),i=r.tenantId,l={userId:n?.userId??"",sessionId:n?.zeniSessionId??"",tenantId:i??""},s=Qe(e,t),c=Ke(e,t),p=a&&s.updateStatus.fetchState!=="In-Progress"&&s.plaidConnectionDetails.link_account.updateStatus.fetchState!=="In-Progress"&&s.plaidConnectionDetails.update_account.updateStatus.fetchState!=="In-Progress"&&s.accountUpdateStatus?.fetchState!=="In-Progress"?void 0:"readonly",g=Nn(e),S=g.transactions,_=qe(e),I=g.accountSummary?.totalBalance?.amount,d=S.length===0||I===0;return{treasurySetupView:s,businessVerificationDetails:c,connectedAccountProvider:r.company?.featuresActivationInfo.connectedAccountProvider??"",transactions:S,transferDetails:_,isFirstTransfer:d,isDisabled:p,analytics:D,filesEndPoint:`${oe.fileMicroServiceBaseUrl}`,authParams:l,isOnSetup:!0,maxInsuredAmount:o.maxInsuredAmount}}),(function(e,o){const{navigate:a,companyId:t,currentTenant:r,isAllocationDone:n,analytics:i,treasurySetupView:l}=o;return{onTransferSaveChangesToLocalStore:s=>{e(Zn(s))},onBusinessVerificationSectionClick:(s,c)=>{let p="../verification";s&&(p+="?showStepProgress=true",c&&(p+="&isTransferInitiated=true")),a(p),r?.company?.companyTreasuryInfo!=null&&r?.company?.companyTreasuryInfo?.businessVerificationStatus?.code==="pending_review"&&e(be(t,!1,!0))},onFetchLinkTokenClick:(s,c)=>{e(Pe("treasury_setup",s,c))},onEstablishConnectionClick:s=>{e(ve(s,t,"treasury_setup","zeni_treasury"))},onUpdatePaymentAccountStatus:(s,c,p)=>{e(ke(s,c,"zeni_treasury","treasury_setup",p))},onUpdatePaymentAccountLoginStatus:(s,c)=>{e(_e(!1,s,"zeni_treasury","treasury_setup",c))},onEstablishConnectionSuccess:()=>{e(be(t,!0))},onEnableTreasuryClick:()=>{e(Y(t,"zeni_treasury"))},onUpdateTreasuryClick:(s,c,p)=>{e(p==="paymentAccount"?Ie(s,c,"zeni_treasury","treasury_setup"):Ae("treasury_setup",s,c))},onUpdatePrimaryFundingAccount:(s,c)=>{e(he(t,"treasury_setup",s,c))},onNavigateToDashboard:()=>{a(r?.company?.companyTreasuryInfo?.businessVerificationStatus?.code==="verified"?"../":"../../")},onCompanyOfficerUpdated:(s,c)=>{e(Ce({officerType:s,fileIds:c}))},onSendForVerificationClick:(s,c)=>{if(e(L(t,s,"zeni_treasury",!0,!0,!0)),!n){const p=l.fundAllocationLocalData;i.trackTreasuryPortfolioConfirm(p.riskScore,Ze(p)),e(Ne(!1))}c===!0&&e(Je())},updateFilesEntity:s=>{e(ae({files:s}))},onDeleteFile:s=>{e(te(s))},onEditFileName:(s,c)=>{e(ne(s,c.split(".")[0]))},onAdditionalVerificationFieldsChanged:s=>{const{sourceOfFunds:c}=s;e(zn({sourceOfFunds:c?.selectedOption??""}))},onUpdateFundAllocation:s=>{i.trackTreasuryAllocationAction("update",Ze(s)),e(Mn(s))},onConfirmFundAllocation:()=>{e(Ne(n))},onOverlayClose:()=>{e(we())}}}))(at),vt=()=>{const e=Te(),o=Q(),a=X(),t=ee(),r=Ee(),n=nt(),{tenantEmailDomain:i}=H(),{useDynamicConfig:l}=me(),s=ie(),[c,p]=h.useState(!1),g=Fe(s?.loggedInUserRoleMap),{configValue:S}=l(Ve.zeniAccountsConfig),_=je(S),[I,d]=h.useState(!1),[y,f]=h.useState(!1),[P,b]=h.useState(!1),[m,C]=h.useState(!1),[k,T]=h.useState(!1),A=v((O=>O.treasurySetupViewState.fetchState)),U=v((O=>O.treasurySetupViewState.treasuryFundsDetails?.fetchStatus?.fetchState)),M=v((O=>O.treasurySetupViewState.currentAllocation.fetchStatus?.fetchState)),x=v((O=>O.treasuryDetailState.transactionsState?.fetchState)),z=v((O=>F(O))),w=E.getSignedInUserTenant(i)?.companyId??z.companyId,ce=v((O=>Qe(O,w))),K=ce.isAtomicAccountExists,q=E.getSignedInUser(),re=O=>{d(O)};if(q==null)throw Error("Can't access treasury setup page without signing in...");h.useEffect((()=>{y||A!=="Not-Started"||w==null||(f(!0),t(be(w,!0,!1)))}),[y,A,w,t]),h.useEffect((()=>{P||U!=="Not-Started"||w==null||(b(!0),t(jn()))}),[P,U,w,t]),h.useEffect((()=>{m||M!=="Not-Started"||w==null||(C(!0),t(Rn()))}),[m,M,w,t]),h.useEffect((()=>{k||x!=="Not-Started"||w==null||(T(!0),t(Ln(!0)))}),[k,x,w,t]);const Z=z.companyTreasuryInfo?.info?.businessVerificationStatus?.code,B=Z==="pending_review"||Z==="verified";return h.useEffect((()=>{c||A!=="Completed"||K||B||!a.pathname.includes("setup")||p(!0)}),[A,K,B]),z.companyTreasuryInfo?.info?.isTreasuryTOSAccepted===!1?u.jsx(j,{to:"../promo"}):u.jsxs(u.Fragment,{children:[u.jsx(se,{analytics:D,onLoad:()=>{}}),u.jsx(ye,{isAppContentDrawerOpen:I,handleDrawerToggle:re}),u.jsx(ct,{onClose:()=>{t(we()),o("../setup")},anchor:"right",open:a.pathname.includes("verification"),transitionDuration:c?0:250,PaperProps:{style:{width:_t.overlayWidth.valuePercentage(n),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:c?"transparent":r.colors.black,opacity:.75,cursor:"pointer"}}},children:u.jsx(Pt,{onClick:O=>O.stopPropagation(),children:u.jsx(At,{productType:"zeni_treasury",isBusinessVerificationDrawerOpen:!0,closeDrawerHandler:()=>{t(we()),o("../setup")}})})}),u.jsx(kt,{navigate:o,location:a,companyId:w,currentTenant:z,isUserZeniAccountsAdmin:g,meetingUrl:e("treasury_setup"),maxInsuredAmount:_.maxInsuredAmount,isAllocationDone:K,analytics:D,treasurySetupView:ce,onClickMenuIcon:()=>{re(!0)},showTreasurySetupOverlay:c,setShowTreasurySetupOverlay:p})]})},Pt=xe(rt)`
|
|
18
|
-
display: flex;
|
|
19
|
-
min-height: 100%;
|
|
20
|
-
flex-direction: column;
|
|
21
|
-
`,Tt=G((function(e,o){const{isUserZeniAccountsAdmin:a,companyId:t}=o,r=F(e),n=E.getSignedInUser(),i=r.tenantId,l={userId:n?.userId??"",sessionId:n?.zeniSessionId??"",tenantId:i??""},s=$n(e,t),c=a&&s.updateStatus.fetchState!=="In-Progress"&&s.plaidConnectionDetails.link_account.updateStatus.fetchState!=="In-Progress"&&s.plaidConnectionDetails.update_account.updateStatus.fetchState!=="In-Progress"&&s.accountUpdateStatus?.fetchState!=="In-Progress"?void 0:"readonly";return{zeniAccountSetUpView:s,connectedAccountProvider:r.company?.featuresActivationInfo.connectedAccountProvider??"",isDisabled:c,analytics:D,filesEndPoint:`${oe.fileMicroServiceBaseUrl}`,authParams:l}}),(function(e,o){const{navigate:a,companyId:t,currentTenant:r}=o;return{onBusinessVerificationSectionClick:()=>{a("../verification"),r?.company?.companyZeniAccountInfo!=null&&r?.company?.companyBillPayInfo?.businessVerificationStatus?.code==="pending_review"&&e(pe(t,!1,!0))},onFetchLinkTokenClick:(n,i)=>{e(Pe("account_setup",n,i))},onEstablishConnectionClick:n=>{e(ve(n,t,"account_setup","zeni_accounts"))},onUpdatePaymentAccountStatus:(n,i,l)=>{e(ke(n,i,"zeni_accounts","account_setup",l))},onUpdatePaymentAccountLoginStatus:(n,i)=>{e(_e(!1,n,"zeni_accounts","account_setup",i))},onEstablishConnectionSuccess:()=>{e(pe(t,!0))},onEnableZeniAccountClick:()=>{e(Y(t,"zeni_accounts"))},onUpdateZeniAccountClick:(n,i,l)=>{e(l==="paymentAccount"?Ie(n,i,"zeni_accounts","account_setup"):Ae("account_setup",n,i))},onUpdatePrimaryFundingAccount:(n,i)=>{e(he(t,"account_setup",n,i))},onEnableZeniAccountSuccess:()=>{a("../",{relative:"path"})},onBackClick:()=>{r?.companyZeniAccountInfo?.info?.isZeniAccountEnabled?a("../"):a("../../")},onNavigateToDashboard:()=>{a("../../dashboard")},onCompanyOfficerUpdated:(n,i)=>{e(Ce({officerType:n,fileIds:i}))},onSendForVerificationClick:n=>{e(L(t,n,"zeni_accounts",!0,!0,!0))},updateFilesEntity:n=>{e(ae({files:n}))},onDeleteFile:n=>{e(te(n))},onEditFileName:(n,i)=>{e(ne(n,i.split(".")[0]))}}}))(it),Et=()=>{const e=Te(),o=Q(),a=X(),t=ee(),{tenantEmailDomain:r}=H(),{useDynamicConfig:n}=me(),i=ie(),l=Fe(i?.loggedInUserRoleMap),{configValue:s}=n(Ve.zeniAccountsConfig),c=je(s),[p,g]=h.useState(!1),[S,_]=h.useState(!1),I=v((b=>b.zeniAccountSetupViewState.fetchState)),d=v((b=>F(b))),y=E.getSignedInUserTenant(r)?.companyId??d.companyId,f=E.getSignedInUser(),P=b=>{g(b)};if(f==null)throw Error("Can't access zeni bank account setup page without signing in...");if(h.useEffect((()=>{S||I!=="Not-Started"||y==null?S||I!=="Completed"||y==null||d.companyBillPayInfo?.info?.businessVerificationStatus?.code!=="pending_review"||t(pe(y,!1,!0)):(_(!0),t(pe(y,!0)))}),[S,I,y,t]),d.companyZeniAccountInfo?.info?.isZeniAccountTOSAccepted===!1)return u.jsx(j,{to:"../promo"});{const b=m=>m.trackPageLoaded(W.Event.zeniAccountsSetup);return u.jsxs(u.Fragment,{children:[u.jsx(se,{analytics:D,onLoad:m=>b(m)}),u.jsx(ye,{isAppContentDrawerOpen:p,handleDrawerToggle:P}),u.jsx(Tt,{navigate:o,location:a,companyId:y,currentTenant:d,isUserZeniAccountsAdmin:l,accountsPromoConfig:c,meetingUrl:e("zeni_accounts_setup"),onClickMenuIcon:()=>{P(!0)}})]})}},Dt=xe.div`
|
|
22
|
-
display: flex;
|
|
23
|
-
height: 100vh;
|
|
24
|
-
width: 100%;
|
|
25
|
-
flex: 1 1 auto;
|
|
26
|
-
flex-direction: column;
|
|
27
|
-
align-items: center;
|
|
28
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
29
|
-
`,Ut=G((function(e,o){const a=F(e),t=E.getSignedInUser(),r=a.tenantId,n={userId:t?.userId??"",sessionId:t?.zeniSessionId??"",tenantId:r??""};return{internationalOnboardingDetails:Gn(e),isReadonly:o.isFormReadonly,filesEndPoint:`${oe.fileMicroServiceBaseUrl}`,authParams:n,analytics:D}}),(function(e,o){const{navigate:a}=o;return{onFormDataChange:t=>{e(qn(t))},onSubmitClick:()=>{e(Kn(o.companyId))},onCancelClick:()=>{a("../setup")},updateFilesEntity:t=>{e(ae({files:t}))},onDeleteFile:t=>{e(te(t))},onDeleteFileList:t=>{e(Ye(t))},onEditFileName:(t,r)=>{e(ne(t,r.split(".")[0]))}}}))(st),Ot=()=>{const e=Q(),o=X(),a=ee(),[t,r]=h.useState(!1),[n,i]=h.useState(!1),[l,s]=h.useState(!1),{tenantEmailDomain:c}=H(),p=ie(),{useFeatureGate:g}=me(),{isFeatureEnabled:S}=g(J.isBillPayLocalCurrencyFeatureEnabled),_=v((T=>T.internationalWireVerificationState.verificationFormFetchState.fetchState)),I=v((T=>T.billPaySetupViewState.fetchState)),d=v((T=>F(T))),y=Ee(),f=d.companyId??E.getSignedInUserTenant(c)?.companyId,P=v((T=>Wn(T.companyState,d.companyId))),b=P?.company.companyBillPayInfo.internationalWireOnboardingStatus,m=b?.code==="onboarding_status_not_started"?void 0:"readonly";if(h.useEffect((()=>{t||_!=="Not-Started"||f==null||(r(!0),a(Hn(f)))}),[t,_,f,a]),h.useEffect((()=>{n||I!=="Not-Started"||f==null||(i(!0),a($(f,!0)))}),[I,n,f,a]),E.getSignedInUser()==null)throw Error("Can't access international verification without signing in...");const C=d.companyBillPayInfo?.info?.isBillPayTOSAccepted,k=T=>{s(T)};return C===!1?u.jsx(j,{to:"../promo"}):C===!0&&p?.loggedInUserRoleMap!=null?u.jsxs(Dt,{children:[u.jsx(se,{analytics:D,onLoad:T=>(A=>A.trackPageLoaded(W.Event.billPayBusinessVerification,void 0))(T)}),Be(o)?u.jsx(ye,{isAppContentDrawerOpen:l,handleDrawerToggle:k}):null,u.jsx(Ut,{navigate:e,location:o,companyId:f,analytics:D,currentTenant:d,roleMap:p.loggedInUserRoleMap,isFormReadonly:m,isLocalCurrencyEnabled:S})]}):u.jsx(De,{fetchState:"In-Progress",style:{backgroundColor:y.colors.grey5}})},wt=G((function(){return{}}),(function(e,o){const{companyId:a,productType:t}=o;return{onEventReceived:r=>{switch(r){case"bill-pay-set-up-verification-update":case"bill-pay-wise-setup":switch(t){case"reimbursement":e(le(a,!0,!0));break;case"zeni_accounts":e(pe(a,!0,!0));break;case"charge_cards":e(de(a,!0,!0));break;case"zeni_treasury":e(be(a,!0,!0));break;default:e($(a,!0,!0))}}}}}))(ot((e=>{const{isBillPayAdminLevelAccess:o,isUserHasOnlyBillPayAccess:a,isReimbursementAdminLevelAccess:t,isZeniAccountAdminLevelAccess:r,isTreasuryAdminLevelAccess:n,isChargeCardAdminLevelAccess:i,isUserHasOnlyCardAccess:l,productType:s,type:c}=e;switch(s){case"bill_pay":switch(c){case"verification":return o?u.jsx(Oe,{productType:s}):a?u.jsx(j,{to:"../"}):u.jsx(R,{});case"international-wire":return o?u.jsx(Ot,{}):a?u.jsx(j,{to:"../"}):u.jsx(R,{});default:return o?u.jsx(pt,{}):a?u.jsx(j,{to:"../"}):u.jsx(R,{})}case"reimbursement":return c==="verification"?t?u.jsx(Oe,{productType:s}):u.jsx(R,{}):t?u.jsx(ht,{}):u.jsx(R,{});case"zeni_accounts":return c==="verification"?r?u.jsx(Oe,{productType:"zeni_accounts"}):u.jsx(R,{}):r?u.jsx(Et,{}):u.jsx(R,{});case"zeni_treasury":return n===!0?u.jsx(vt,{}):u.jsx(R,{});case"charge_cards":return c==="verification"?i?u.jsx(Oe,{productType:"charge_cards"}):l?u.jsx(j,{to:"../"}):u.jsx(R,{}):i?u.jsx(St,{}):l?u.jsx(j,{to:"../"}):u.jsx(R,{})}})));function oa(e){const{tenantEmailDomain:o}=H(),a=v((r=>F(r))).companyId??E.getSignedInUserTenant(o)?.companyId,t={events:a!=null?[`private-encrypted-${a}.bill-pay-set-up-verification-update`,`private-encrypted-${a}.bill-pay-wise-setup`]:[],eventCallback:(r,n,i)=>{i.onEventReceived(r)}};if(E.getSignedInUser()==null)throw Error("Can't access setup details page without signing in...");return u.jsx(wt,{...e,companyId:a,...t})}export{na as A,ta as P,oa as S,Qt as a,ea as b,yt as c,ft as d,mt as e,aa as f,Kt as g,Wt as h,Yt as i,Xt as j,ia as k,Jt as l,qt as m,Ht as n,Gt as o,$t as p,sa as s};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as u}from"./liveblocks-BLPKVqHo.js";import{a as f,R as T,q as A}from"./sentry-BYwRJ99F.js";import{u as z,h as D,j as l,g as j,N as M,l as P}from"./core-pDUZcPB0.js";import{u as O,z as s,E as F,j as w,G as N,S as _,T as B,Y as V,U as W,V as $,W as v}from"./index-DElaqJ7F.js";import{fI as q,U3 as J,Un as R,gl as X,gn as Y,Us as G,gX as H,dk as K,Ut as y,Uu as Q,Uv as Z,c0 as U}from"./zeni-epic-state-Bke7DGFg.js";import"./mui-BiqpQr6x.js";import{u as ee}from"./useDeviceId-D1mK-mWi.js";import{f as te}from"./analyticsHelper-CT62vOeP.js";import{t as ne}from"./getLocaleForTenant-0mV5x3GU.js";import"./recharts-Dg9FaaKY.js";import"./analytics-CmKkcxmz.js";import"./plaid-BXFY-KIk.js";import"./dnd-Bslfq-ku.js";import"./stripe-cKAAJElX.js";import"./lottie-DWJdupW0.js";import"./lexical-BMD9Skdu.js";import"./pdf-B3souC9z.js";import"./utils-CJY4ogMD.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},i=new t.Error().stack;i&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[i]="95369ab9-8e9d-4231-9c11-4e20d33fe362",t._sentryDebugIdIdentifier="sentry-dbid-95369ab9-8e9d-4231-9c11-4e20d33fe362")}catch{}})();const ie=P((function(t,i){const d=t.tenantState.fetchState,g=t.tenantState.sendEmailMagicLinkFetchState,{magicLinkExpired:n,magicLinkAlreadyUsed:a,magicLinkExpiredEmail:c}=i;return{googleClientId:v.googleClientId,microsoftClientId:v.microsoftClientId,signInError:t.tenantState.error?.error,fetchState:d,sendMagicLinkStatus:g,magicLinkExpired:n,magicLinkAlreadyUsed:a,magicLinkExpiredEmail:c}}),(function(t,i){const{location:d,navigate:g}=i;return console.warn(JSON.stringify(window.location)),{onOAuthError:(n,a)=>{A({message:`OAuth error from provider ${a} with error ${n}`,level:"error",tags:{authProvider:a,errorType:"zeni.login.error"},extra:{error:n,windowLocation:window.location.href}})},onOAuthSuccess:(n,a)=>{const c=a==="google"?window.location.origin:window.location.origin+window.location.pathname;t(Z({authCode:n,oauthProvider:a,appType:"web",redirectUri:U(c),sourceUri:U(d.state!=null?d.state.origin:"")}))},getSignedInUser:()=>s.getSignedInUser(),onSignedInCallback:()=>{const n=d.state?.origin;n&&n!=="/"?g(n,{replace:!0}):window.open(window.location.origin,"_self")},sendMagicLink:n=>{const{deviceId:a}=i;a!=null&&(s.saveMagicLinkEmail(n),t(Q(n,a)))},clearSignInError:()=>{t(y())}}}))($),ae=T.memo(ie);function ve({setTenantEmailDomain:t}){const i=z(),d=D(),{clearAllLoading:g}=O(),n=s.getSignedInUser();f.useLayoutEffect((()=>{g()}),[g]);const a=ee(),c=l((e=>e.tenantState.magicLinkCodeVerifier)),{sendEmailMagicLinkFetchState:k,accountLocked:C,accountUnlockTime:L}=l((e=>e.tenantState)),p=l((e=>e.tenantState.fetchState)),h=l((e=>e.tenantState.activeTenantFetchState.fetchState)),S=l((e=>e.tenantState.signInState)),o=l((e=>e.tenantState.loggedInUser)),r=l((e=>q(e))),I=l((e=>J(e))),m=j(),E=F().mode,b=m.state?.magicLinkExpired,x=m.state?.magicLinkAlreadyUsed;if(f.useEffect((()=>{k.fetchState==="Completed"&&c!=null&&(w.trackSignInLinkSent(),s.saveMagicLinkCodeVerifier(c))}),[k.fetchState,c]),f.useEffect((()=>{t(void 0)}),[]),f.useEffect((()=>{S!=="In-Progress"||p!=="Completed"&&h!=="Completed"||o?.zeniSessionId==null||r==null||(s.savePayNowInfoTooltip(!0,o.zeniSessionId),s.saveSignedInUserWithSession(o,o.zeniSessionId),s.saveSignedInUserTenants(R(I.tenantsInOrder),o.zeniSessionId),X(o.userId,o.zeniSessionId,r.tenantId),i(Y(r.tenantId)),s.saveActiveTenantDomainForUser(r.tenantEmailDomain),i(G("Completed")),N.updateAppLocaleID(ne(r)),te(o,r,E,void 0,I.tenantsInOrder),H().then((()=>{const e=W();e!=null&&_(e)})),setTimeout((()=>{w.trackLogin(B.Event.loginSuccess,o.authProvider??"google",K(r.productSettings))}),2e3))}),[S,p,h,o,r,I,E,m.state,i]),S==="In-Progress"&&p==="Completed"&&o?.zeniSessionId!=null&&r!=null||n!=null){const e=m.state?.origin??"/";return u.jsx(M,{to:e,state:{...m.state,origin:""}})}return u.jsxs(u.Fragment,{children:[u.jsx(ae,{magicLinkExpired:!!b,magicLinkAlreadyUsed:!!x,magicLinkExpiredEmail:s.getMagicLinkEmail()??void 0,location:m,navigate:d,deviceId:a??void 0,showEmailLogin:!0}),C===!0&&L!=null?u.jsx(V,{onClose:()=>i(y()),unlockDate:L}):null]})}export{ve as default};
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import{j as s}from"./liveblocks-BLPKVqHo.js";import{a as i}from"./sentry-BYwRJ99F.js";import{u as l,g as c,N as u}from"./core-pDUZcPB0.js";import{z as n,j as a,T as m,a7 as p}from"./index-DElaqJ7F.js";import{g_ as g,UJ as b}from"./zeni-epic-state-Bke7DGFg.js";import{n as y}from"./mui-BiqpQr6x.js";import"./recharts-Dg9FaaKY.js";import"./analytics-CmKkcxmz.js";import"./plaid-BXFY-KIk.js";import"./dnd-Bslfq-ku.js";import"./stripe-cKAAJElX.js";import"./lottie-DWJdupW0.js";import"./lexical-BMD9Skdu.js";import"./pdf-B3souC9z.js";import"./utils-CJY4ogMD.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new e.Error().stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="51254eed-428b-435f-9235-06c86bbd9753",e._sentryDebugIdIdentifier="sentry-dbid-51254eed-428b-435f-9235-06c86bbd9753")}catch{}})();function L(){const e=l(),t=c(),r=i.useRef(!1),d=n.isSignedIn(),o=t.state?.message==="logout"||d;return i.useEffect((()=>{if(o&&!r.current){r.current=!0;try{e(g()),b(),a.trackLogout(m.Event.logoutSuccess),a.resetUserIdentity(),n.clearAll()}catch(f){console.error("Error during sign out:",f)}finally{window.location.replace("/signin/auth")}}}),[o,e]),o?s.jsx(h,{children:s.jsx(p,{fetchState:"In-Progress"})}):s.jsx(u,{to:"../",replace:!0})}const h=y.div`
|
|
2
|
-
display: flex;
|
|
3
|
-
height: 100vh;
|
|
4
|
-
width: 100%;
|
|
5
|
-
flex: 1 1 auto;
|
|
6
|
-
flex-direction: column;
|
|
7
|
-
align-items: center;
|
|
8
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
9
|
-
`;export{L as default};
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import{j as i}from"./liveblocks-BLPKVqHo.js";import ue from"./NotFoundScreen-rNNJF3rA.js";import{a as k}from"./sentry-BYwRJ99F.js";import{h as H,u as ee,j as E,g as de,i as ke,N as pe,l as me,n as Se,o as b}from"./core-pDUZcPB0.js";import{Q9 as ae,Qc as fe,Q6 as Te,a2b as ge,fI as te,a2c as se,Qy as g,Qq as T,Q3 as he,R2 as be,QX as Ee,a2d as ne,gk as oe,a2e as Z,P$ as Ie,PY as De,v1 as Ce,uR as Ge,mC as Re,Qo as _e,a2f as ye,Rf as Ue,Qk as xe,QJ as Be,QG as ve,Qf as we,QD as je,QC as Ae}from"./zeni-epic-state-Bke7DGFg.js";import{z as _,e3 as Pe,Z as Fe,c as Le,m as G,a4 as re,p as R,a8 as Ke,j as q,T as Qe,e4 as $e,W as M,ae as Ne}from"./index-DElaqJ7F.js";import{n as Oe}from"./mui-BiqpQr6x.js";import{u as ze}from"./useInitialThreadRequest-BWnJWIOJ.js";import{M as Ve}from"./MobileAppDrawer-C8UsE0YH.js";import{b as Ze,a as qe,T as f,t as Me,c as J,d as X,e as Je}from"./TaskListScreen-DhMAwdLm.js";import{u as Xe}from"./useTaskManagerPusherEvents-P3ZIbHSQ.js";import"./recharts-Dg9FaaKY.js";import"./analytics-CmKkcxmz.js";import"./plaid-BXFY-KIk.js";import"./dnd-Bslfq-ku.js";import"./stripe-cKAAJElX.js";import"./lottie-DWJdupW0.js";import"./lexical-BMD9Skdu.js";import"./pdf-B3souC9z.js";import"./utils-CJY4ogMD.js";import"./InboxNotificationsProvider-CxBkh6GM.js";import"./useTaskManagerAccess-BpKEGOBZ.js";import"./useAskAiCfoHostNavButtonProps-BEEGOqdG.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},a=new e.Error().stack;a&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[a]="15ab7d34-8ef9-4c71-8277-e37387918647",e._sentryDebugIdIdentifier="sentry-dbid-15ab7d34-8ef9-4c71-8277-e37387918647")}catch{}})();function Ye(){const e=H(),a=ee(),n=_.getSignedInUser(),{cannedResponses:c,fetchState:s,saveFetchState:u}=E((o=>o.cannedResponsesState)),d=k.useCallback((()=>{a(ae())}),[a]),m=k.useCallback(((o,I,D)=>{a(fe({name:o,content:I,cannedResponseId:D}))}),[a]),t=k.useCallback((o=>{a(Te({cannedResponseId:o}))}),[a]);if(n==null)throw Error("Can't access quick responses page without signing in...");return i.jsx(Pe,{cannedResponses:c,isLoading:s==="In-Progress"||s==="Not-Started",isSaving:u==="In-Progress",onBackClick:()=>e(-1),onDelete:t,onFetch:d,onSave:m})}const L=e=>e?.taskState?.taskByID,P=(e,a)=>{const n=L(e);if(a!=null&&n!=null)return n[a]?.parentTaskId??void 0},We=ge([P,(e,a)=>{const n=P(e,a),c=L(e);if(n!=null&&c!=null)return c[n]?.name},(e,a)=>{const n=P(e,a),c=L(e);return n!=null&&c!=null&&c[n]!=null}],((e,a,n)=>{if(e!=null&&n===!0)return{id:e,name:a??""}}));let Y,W=[];const He=me((function(e,a){const{location:n,taskGroupId:c}=a,s=ne(e,a.taskId),u=te(e),d=We(e,a.taskId),m=s.taskGroupId??c,t=m!=null?Z(e.taskGroupState,m):void 0,o=_.getSignedInUser(),I=u.tenantId,D={userId:o?.userId??"",sessionId:o?.zeniSessionId??"",tenantId:I??""},B=se(e),{tenantEmailDomain:v}=u,y=s.recurringSourceTaskId,w=y!=null?`${M.appUrl}/${v}/tasks/${encodeURIComponent(y)}`:void 0;var h;return{taskDetailSelectorView:s,authParams:D,isZeniUser:_.isZeniUser(),userGroupList:((h=e.userGroupsState.userGroupByUserGroupId)!==Y&&(Y=h,W=Object.values(h)),W),isNewClicked:n.state?.message==="comingFromTaskListPage",filesEndPoint:Ne.fileMicroServiceBaseUrl,companyName:a.currentTenant.companyName,companyId:a.currentTenant.companyId,currentUrl:`${M.appUrl}${a.location.pathname}`,cannedResponses:e.cannedResponsesState.cannedResponses,isCannedResponsesLoading:e.cannedResponsesState.fetchState==="In-Progress",recurringSourceTaskUrl:w,tagListView:B,taskGroupName:m!=null&&t!=null&&t.isDefault===!1?t.name:void 0,taskGroupList:e.taskGroupViewState.taskGroupsIds.map((S=>Z(e.taskGroupState,S))).filter((S=>S!=null&&!S.isDeleted)).map((S=>({id:S.id,name:S.name,isDefault:S.isDefault}))),subtasks:s.subtasks,parentTaskRef:d,subTaskCreateStatus:e.taskDetailState?.subTaskCreateStatus?.fetchState}}),(function(e,a){const{taskId:n,navigate:c,currentTenant:s,location:u,taskGroupId:d}=a,{tenantEmailDomain:m}=s;return{onSaveChangesToLocalStore:t=>{e(Ae({taskDetailLocalData:t,taskId:n}))},onSaveDetailClick:t=>{e(je(n,t??d))},onArchiveTaskClick:()=>{a.taskId!=null&&e(we(a.taskId))},onSnoozeTask:(t,o)=>{e(ve(t,o))},onUnsnoozeTask:t=>{e(Be(t))},onCreateSubtask:(t,o)=>{e(xe({...o,parentTaskId:t}))},onSubtaskUpdate:(t,o)=>{e(Ue({task:t,updates:o}))},onShowToast:t=>{e(oe(t))},onSubtaskRowClick:t=>{c(`/${m}/tasks/${t}`,{state:{pathnameStackToGoBack:R(u.state?.pathnameStackToGoBack,u.pathname)}})},onParentBreadcrumbClick:t=>{c(`/${m}/tasks/${t}`,{state:{pathnameStackToGoBack:R(u.state?.pathnameStackToGoBack,u.pathname)}})},onDismissClick:()=>{if(u.state?.message==="triggerBackClick"){const t=re(u.state?.pathnameStackToGoBack),o=t.poppedPathname??"../../dashboard";c(o,{state:{pathnameStackToGoBack:t.newStack}})}else{const t=x(m),o=R(u.state?.pathnameStackToGoBack,u.pathname);c(t,{state:{pathnameStackToGoBack:o}})}e(ye({taskId:n}))},onDeleteTaskClick:()=>{e(_e(n))},updateFilesEntity:t=>{e(Re({files:t}))},onDeleteFile:t=>{e(Ge(t))},onEditFileName:(t,o)=>{e(Ce(t,o.split(".")[0]))},onReloadTaskDetailPage:()=>{e(g(!1,n))},onCreateTagClick:t=>{e(De(t,n))},onDeleteTagClick:t=>{e(Ie(t,n))},onFetchCannedResponses:()=>{e(ae())},onManageTemplatesClick:()=>{c(`/${s.tenantEmailDomain}/tasks/quick-responses`)}}}))($e);function F(){const e=H(),a=ee(),n=de(),c=Fe(),{taskId:s,taskGroupId:u}=ke(),d=E((r=>te(r))),m=ze(d?.companyId),{useFeatureGate:t}=Le(),{isFeatureEnabled:o}=t(G.isTaskSnoozeEnabled),{isFeatureEnabled:I}=t(G.isTaskVisibilityEnabled),{isFeatureEnabled:D}=t(G.isTaskCannedResponsesEnabled),{isFeatureEnabled:B}=t(G.isTaskRecurringParentEnabled),{isFeatureEnabled:v}=t(G.isTaskGroupAssigneesEnabled),[y,w]=k.useState(!1),[h,S]=k.useState(!1),[K,ie]=k.useState(!1),[Q,j]=k.useState(!1),C=k.useRef(!1),U=E((r=>r.taskListState.updateTasksFetchState.fetchState)),$=E((r=>se(r))),N=E((r=>r.taskGroupViewState.fetchState));k.useEffect((()=>{a(g(!1,s)),s!=null&&a(T(s))}),[a,s]);const O=_.getSignedInUser()?.userId,ce=k.useMemo((()=>{const r=[f.TASK_CREATED,f.TASK_UPDATED,f.TASKS_BULK_UPDATED,f.TASKS_BULK_DELETED],l=[...r,f.TASK_SNOOZE_RESURFACED];return[...Ze(d?.companyId,r),...qe(O,l)]}),[d?.companyId,O]);Xe({events:ce,onSubscribed:()=>{s!=null&&(a(g(!0,s)),a(T(s)))},onEvent:(r,l)=>{if(s!=null)switch(r){case f.TASK_CREATED:{X(l)?.parent_task_id===s&&(a(g(!0,s)),a(T(s)));break}case f.TASK_UPDATED:{const p=X(l);if(p==null)break;p.task_id===s?(a(g(!0,s)),a(T(s))):p.parent_task_id===s&&a(T(s));break}case f.TASKS_BULK_UPDATED:{const p=J(l);if(p==null)break;p.task_ids.includes(s)&&a(g(!0,s)),a(T(s));break}case f.TASKS_BULK_DELETED:{const p=J(l);if(p==null)break;if(p.task_ids.includes(s)){a(oe({messageSection:"delete_task",messageText:"success",type:"success"})),d?.tenantEmailDomain!=null&&e(x(d.tenantEmailDomain));break}a(T(s));break}case f.TASK_SNOOZE_RESURFACED:{Me(l)?.task_id===s&&a(g(!0,s));break}}}}),k.useEffect((()=>{h||$.fetchState==="Completed"||(S(!0),a(he()))}),[h,a,$.fetchState]),k.useEffect((()=>{K||N==="Completed"||(ie(!0),a(be()))}),[K,a,N]);const le=k.useCallback((()=>{s!=null&&(C.current=!1,a(Ee([s],null,{isArchived:!1})),j(!0))}),[a,s]);k.useEffect((()=>{if(Q)if(U!=="In-Progress"){if(C.current){if(U==="Error")return j(!1),void(C.current=!1);if(U==="Completed"){j(!1),C.current=!1;const{tenantEmailDomain:r}=d;if(n.state?.message==="triggerBackClick"){const l=re(n.state?.pathnameStackToGoBack);e(l.poppedPathname??"../../dashboard",{state:{pathnameStackToGoBack:l.newStack}})}else{const l=x(r);e(l,{state:{pathnameStackToGoBack:R(n.state?.pathnameStackToGoBack,n.pathname)}})}}}}else C.current=!0}),[Q,U,d,n,e]);const z=E((r=>ne(r,s))),A=z.fetchState,V=_.getSignedInUser();if(V==null)throw Error("Can't access task detail page without signing in...");if(A==="Error"&&z.error?.code===400){const{tenantEmailDomain:r}=d,l=x(r),p=R(n.state?.pathnameStackToGoBack,n.pathname);return i.jsx(pe,{to:l,state:{pathnameStackToGoBack:p}})}return i.jsxs(i.Fragment,{children:[A==="Completed"?i.jsx(Ke,{analytics:q,onLoad:r=>(l=>l.trackPageLoaded(Qe.Event.taskDetailPage))(r)}):null,i.jsxs(ea,{children:[i.jsx(Ve,{isAppContentDrawerOpen:y,handleDrawerToggle:r=>{w(r)}}),i.jsx(He,{analytics:q,currentTenant:d,handleZeniLogoClick:()=>{c.toggle()},initialOpenThreadRequest:m,location:n,loggedInUser:V,navigate:e,taskGroupId:u,taskId:s,taskDetailFetchState:A,onUnarchiveTaskClick:le,isTaskSnoozeEnabled:o,isTaskVisibilityEnabled:I,isTaskCannedResponsesEnabled:D,isTaskRecurringParentEnabled:B,isTaskGroupAssigneesEnabled:v})]})]})}const ea=Oe.div`
|
|
2
|
-
display: flex;
|
|
3
|
-
min-height: 100%;
|
|
4
|
-
width: 100%;
|
|
5
|
-
flex: 1 1 auto;
|
|
6
|
-
flex-direction: column;
|
|
7
|
-
align-items: center;
|
|
8
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
9
|
-
`,x=e=>`/${e}/tasks`;function Ca(){return i.jsxs(Se,{children:[i.jsx(b,{path:"/new",element:i.jsx(F,{})}),i.jsx(b,{path:"/new/:taskGroupId",element:i.jsx(F,{})}),i.jsx(b,{path:"/group/:taskGroupId",element:i.jsx(Je,{})}),i.jsx(b,{path:"/quick-responses",element:i.jsx(Ye,{})}),i.jsx(b,{path:"/:taskId",element:i.jsx(F,{})}),i.jsx(b,{path:"*",element:i.jsx(ue,{})})]})}export{Ca as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as t}from"./liveblocks-BLPKVqHo.js";import i from"./NotFoundScreen-rNNJF3rA.js";import{T as r}from"./TransactionDetailScreen-CCYZhbpM.js";import"./sentry-BYwRJ99F.js";import{n as a,o as e}from"./core-pDUZcPB0.js";import"./zeni-epic-state-Bke7DGFg.js";import"./recharts-Dg9FaaKY.js";import"./index-DElaqJ7F.js";import"./mui-BiqpQr6x.js";import"./analytics-CmKkcxmz.js";import"./plaid-BXFY-KIk.js";import"./dnd-Bslfq-ku.js";import"./stripe-cKAAJElX.js";import"./lottie-DWJdupW0.js";import"./lexical-BMD9Skdu.js";import"./pdf-B3souC9z.js";import"./utils-CJY4ogMD.js";import"./useAskAiCfoHostNavButtonProps-BEEGOqdG.js";import"./decodeURIComponentSafe-DBYvBfqM.js";import"./useInitialThreadRequest-BWnJWIOJ.js";import"./routePaths-KJ0Mf_VR.js";import"./expenseAutomationHelper-pbEk9tHa.js";(function(){try{var o=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},n=new o.Error().stack;n&&(o._sentryDebugIds=o._sentryDebugIds||{},o._sentryDebugIds[n]="bfd19369-9f5a-4875-9ff9-f0a50fe2624d",o._sentryDebugIdIdentifier="sentry-dbid-bfd19369-9f5a-4875-9ff9-f0a50fe2624d")}catch{}})();function z(){return t.jsxs(a,{children:[t.jsx(e,{path:"/:transactionTypeEncoded/:transactionId",element:t.jsx(r,{})}),t.jsx(e,{path:"/:transactionTypeEncoded/:transactionId/page-not-found",element:t.jsx(i,{})}),t.jsx(e,{path:"/:transactionTypeEncoded/:transactionId/vendor/create",element:t.jsx(r,{})}),t.jsx(e,{path:"/*",element:t.jsx(r,{})})]})}export{z as default};
|