@zeniai/web-app-ui 5.3.44-qa → 5.3.45-qa
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-B400AyQJ.js → AccountMappingScreen-EqyOLk0W.js} +2 -2
- package/dist/assets/{ActualMatchingMatchDetailScreen-at2idxY8.js → ActualMatchingMatchDetailScreen-B_Hxuz1x.js} +1 -1
- package/dist/assets/AddressRoutes-ByQnL6Ep.js +1 -0
- package/dist/assets/AddressScreen-C2qj6tYr.js +9 -0
- package/dist/assets/{AiCfoScreen-C2YvBVu2.js → AiCfoScreen-DgiomMQs.js} +3 -3
- package/dist/assets/{AppDrawer-D0KfLMaT.js → AppDrawer-C9JSspSl.js} +3 -3
- package/dist/assets/{BillPayApprovalRoutes-LmedJ5XD.js → BillPayApprovalRoutes-CtPNwVvl.js} +1 -1
- package/dist/assets/{BillPayRoutes-CDWH4S4C.js → BillPayRoutes-Duz6Vx7D.js} +10 -10
- package/dist/assets/{BusinessVerificationPageScreen-BVXryUGP.js → BusinessVerificationPageScreen-BAWcvg1q.js} +2 -2
- package/dist/assets/{CardsAiCfoScreen-CyRzyeQR.js → CardsAiCfoScreen-BdTJBLec.js} +3 -3
- package/dist/assets/{ChargeCardRoutes-00uaD3zR.js → ChargeCardRoutes-B08xwpTq.js} +9 -9
- package/dist/assets/{CompanyPassportScreen-DSUfEnP2.js → CompanyPassportScreen-CbwVCSdf.js} +1 -1
- package/dist/assets/ConnectionAuthScreen-BcoTZa8L.js +11 -0
- package/dist/assets/CustomerOnboardingAuthScreen-BpGFH1t5.js +1 -0
- package/dist/assets/CustomerOnboardingRoutes-BP006ys9.js +30 -0
- package/dist/assets/{DashboardRoutes-CsjwE5Mt.js → DashboardRoutes-DKsy8kjy.js} +3 -3
- package/dist/assets/{DefaultTenantHome-BmcgKJw_.js → DefaultTenantHome-h9sstg-6.js} +1 -1
- package/dist/assets/{DomesticWireDetailScreen-BHofWD_4.js → DomesticWireDetailScreen-DdrkO-LG.js} +4 -4
- package/dist/assets/{DrawerScreen-eoSileBw.js → DrawerScreen-KSeYe6Xi.js} +1 -1
- package/dist/assets/EntityDetailRoutes-TJfEMlzp.js +1 -0
- package/dist/assets/{ExpenseAutomationRoutes-C41VbCrR.js → ExpenseAutomationRoutes-FRK8lYq7.js} +4 -4
- package/dist/assets/{FeaturePreviewScreen-BAENITNo.js → FeaturePreviewScreen-R_rh5xYj.js} +1 -1
- package/dist/assets/HubSpotOAuthCallbackScreen-Bf48Zrcv.js +1 -0
- package/dist/assets/InboxNotificationsProvider-CMirleoY.js +1 -0
- package/dist/assets/{InvoicingRoutes-C6flJIVP.js → InvoicingRoutes-D9DMbY6F.js} +2 -2
- package/dist/assets/MagicLinkRoutes-DVS2kuyq.js +72 -0
- package/dist/assets/MagicLinkSignInScreen-CmaiVv9M.js +12 -0
- package/dist/assets/MobileAppDrawer-DEm85bH8.js +1 -0
- package/dist/assets/NotFoundScreen-CS6UgwGr.js +1 -0
- package/dist/assets/NotificationRoutes-DlVY8cS0.js +1 -0
- package/dist/assets/OAuthConsentScreen-0eyA85wD.js +1 -0
- package/dist/assets/PandLWithForecastRoutes-Ciu8QGi3.js +1 -0
- package/dist/assets/{PaymentLinkScreen-DiueSn16.js → PaymentLinkScreen-DSvOcNW8.js} +4 -4
- package/dist/assets/PeopleRoutes-B29gnv2-.js +22 -0
- package/dist/assets/PerformanceRoutes-C-oSemZm.js +1 -0
- package/dist/assets/{Preview-DEgobwYA.js → Preview-DPyEVqHc.js} +1 -1
- package/dist/assets/{QBOConnectionScreen-Dcslm4FM.js → QBOConnectionScreen-CUhLSYvc.js} +1 -1
- package/dist/assets/ReimbursementApprovalRoutes-CS9p1qcB.js +1 -0
- package/dist/assets/{ReimbursementApprovalRuleDetailScreen-C95Tlh44.js → ReimbursementApprovalRuleDetailScreen-CJnxkFoz.js} +1 -1
- package/dist/assets/{ReimbursementRoutes-Sdsth_9q.js → ReimbursementRoutes-DaGg2TTR.js} +4 -4
- package/dist/assets/{ReportsRoutes-DA2ZKfqn.js → ReportsRoutes-BsvYUCIx.js} +1 -1
- package/dist/assets/RewardsRoutes-BeNSEmB_.js +1 -0
- package/dist/assets/{ScheduleDetailsPrepaidExpensesScreen-BinEqncH.js → ScheduleDetailsPrepaidExpensesScreen-CJ28c5Wc.js} +5 -5
- package/dist/assets/ScreenRoutes-Lei7nnrR.js +2 -0
- package/dist/assets/{SettingsRoutes-Cwcsb2Ys.js → SettingsRoutes-DJiPiJIZ.js} +6 -6
- package/dist/assets/{SetupPagesScreen-C64hdzmo.js → SetupPagesScreen-BzPNt5Xb.js} +5 -5
- package/dist/assets/SignInScreen-OFMK0Fhv.js +1 -0
- package/dist/assets/SignOutScreen-Duww-LZM.js +9 -0
- package/dist/assets/TaskListScreen-Dy6L1Gr_.js +9 -0
- package/dist/assets/TaskRoutes-BAifN0A-.js +9 -0
- package/dist/assets/TransactionDetailRoutes-KEbThb3n.js +1 -0
- package/dist/assets/{TransactionDetailScreen-DcuSfVKO.js → TransactionDetailScreen-C32uKUIF.js} +2 -2
- package/dist/assets/{TransactionListRoutes-B_voFmAT.js → TransactionListRoutes-Ebou9bMl.js} +1 -1
- package/dist/assets/{TreasuryRoutes-CXgACPbz.js → TreasuryRoutes-Bq4RVae3.js} +5 -5
- package/dist/assets/{VendorsRoutes-DdY9Fw_b.js → VendorsRoutes-dtzf2p8G.js} +12 -12
- package/dist/assets/WiseConfirmationScreen-Dzz50WS2.js +12 -0
- package/dist/assets/{ZeniAccountRoutes-OVjm5L3x.js → ZeniAccountRoutes-C2FWt_0o.js} +11 -11
- package/dist/assets/ZeniAccountStatementScreen-CJtdjYJW.js +9 -0
- package/dist/assets/{accountMappingHelper-Djr6f8Xt.js → accountMappingHelper-B5wpHG39.js} +1 -1
- package/dist/assets/{analytics-B06OpwA-.js → analytics-5LJ4BXQX.js} +1 -1
- package/dist/assets/analyticsHelper-k_Sp-PwA.js +1 -0
- package/dist/assets/{core-Bl4MLhFi.js → core-BI5oX4mx.js} +1 -1
- package/dist/assets/{decodeURIComponentSafe-Buybgpqw.js → decodeURIComponentSafe-B7oIXSPO.js} +1 -1
- package/dist/assets/{dnd-CimhpTrK.js → dnd-D6wtGmk9.js} +1 -1
- package/dist/assets/{empty-B4WpR10s.js → empty-D1y42ZwI.js} +1 -1
- package/dist/assets/{empty-BTbLiTP7.js → empty-PW7BYANj.js} +1 -1
- package/dist/assets/{emptyVideoElement-Do1ktOmR.js → emptyVideoElement-DRIlZkGm.js} +1 -1
- package/dist/assets/{epic-Ck-sEMUn.js → epic-BgEnH7Qf.js} +1 -1
- package/dist/assets/expenseAutomationHelper-CqPrLTRM.js +1 -0
- package/dist/assets/{getLocaleForTenant-NAFAfy2t.js → getLocaleForTenant-Cv6I-eSM.js} +1 -1
- package/dist/assets/{index-Bmwrrrme.js → index-BT5wSX8Z.js} +1 -1
- package/dist/assets/{index-BXYzwgW0.js → index-BgSgl7o0.js} +1 -1
- package/dist/assets/{index-D_qRPRIi.js → index-C2L5Bzwa.js} +9582 -9582
- package/dist/assets/{index-DFR56SYR.js → index-C8KisrNI.js} +2 -2
- package/dist/assets/{index-jyJQzleF.js → index-COJM8F4x.js} +1 -1
- package/dist/assets/{index-H-kll8aI.js → index-Cf-PV9pR.js} +1 -1
- package/dist/assets/{index-CivWMXxp.js → index-ChUBWLsO.js} +1 -1
- package/dist/assets/{index-BKWyG8Iu.js → index-Cnd56s5E.js} +1 -1
- package/dist/assets/{lexical-BbBoQdpc.js → lexical-BLu7UAko.js} +1 -1
- package/dist/assets/{liveblocks-BXyXenK7.js → liveblocks-CW9yScMF.js} +1 -1
- package/dist/assets/{lottie-2qUppQdg.js → lottie-lQbJqTc2.js} +1 -1
- package/dist/assets/{mui-CyP-P4av.js → mui-KP5Ep0NX.js} +1 -1
- package/dist/assets/{pathToGoBack-sGBxvK0B.js → pathToGoBack-Ddmf68xx.js} +1 -1
- package/dist/assets/{pdf-BENieWk6.js → pdf-DflcYtDk.js} +4 -4
- package/dist/assets/{pdf-lib-CLkFJB86.js → pdf-lib-iL5hUpKl.js} +1 -1
- package/dist/assets/{plaid-C0aCR9wu.js → plaid-BrgJMdej.js} +1 -1
- package/dist/assets/{pusher-B9dsvvYE.js → pusher-CN7UYIVv.js} +1 -1
- package/dist/assets/{react-DIwVQX4M.js → react-BvzziK5i.js} +1 -1
- package/dist/assets/{react-BqELFJJh.js → react-C3_gvmu5.js} +1 -1
- package/dist/assets/{react-DEsZRrdi.js → react-C3b5GjIN.js} +1 -1
- package/dist/assets/{react-Do3Z3oDl.js → react-D7C_-SWb.js} +1 -1
- package/dist/assets/{react-BvpkKAe3.js → react-Ow08-_5J.js} +1 -1
- package/dist/assets/{react-C4fns4CR.js → react-XJ6XyB9N.js} +1 -1
- package/dist/assets/{recharts-CZKBTuPa.js → recharts-DRl2ZsSW.js} +1 -1
- package/dist/assets/{routePaths-D20OKXnM.js → routePaths-BrIEdo8u.js} +1 -1
- package/dist/assets/{sentry-D4svnzxK.js → sentry-C_uJQK1a.js} +1 -1
- package/dist/assets/{stripSplatSuffix-G7yC23v6.js → stripSplatSuffix-CSXpdRK5.js} +1 -1
- package/dist/assets/{url-SRUWz_6t.js → url-0wqXxJRo.js} +1 -1
- package/dist/assets/{url-m7LStd7o.js → url-Csr3E4Sb.js} +1 -1
- package/dist/assets/useActualMatchingMatchDetail-C-OzIN8B.js +1 -0
- package/dist/assets/{useAiCfoDashboardSuggestedQuestionsChips-BfYubNz7.js → useAiCfoDashboardSuggestedQuestionsChips-CZodBcrZ.js} +1 -1
- package/dist/assets/useAskAiCfoHostNavButtonProps-4TGjNsPg.js +1 -0
- package/dist/assets/{useChargeCardPusherEvents-CLgbV2wJ.js → useChargeCardPusherEvents-B3svLsmE.js} +1 -1
- package/dist/assets/{useDeviceId-4WJY9vuN.js → useDeviceId-CAlK1w38.js} +1 -1
- package/dist/assets/useEmailConnectResultRefresh-CIZ_wxDt.js +1 -0
- package/dist/assets/{useInitialThreadRequest-R2hAErYY.js → useInitialThreadRequest-BNsRpSRE.js} +1 -1
- package/dist/assets/{useTaskManagerAccess-Rxke8A9H.js → useTaskManagerAccess-Bhr2JI_X.js} +1 -1
- package/dist/assets/{utils-Bycom664.js → utils-BzQpFQvw.js} +1 -1
- package/dist/assets/{withTransactionSidePanel-rDK0lUVX.js → withTransactionSidePanel-mkP2Wc9X.js} +2 -2
- package/dist/assets/{zeni-epic-state-UM7IPCLf.js → zeni-epic-state-CIizsNeB.js} +4 -4
- package/dist/index.html +1 -1
- package/package.json +3 -3
- package/dist/assets/AddressRoutes-Bf2-WRel.js +0 -1
- package/dist/assets/AddressScreen-Cbo3iSD8.js +0 -9
- package/dist/assets/ConnectionAuthScreen-DlFUg2cH.js +0 -11
- package/dist/assets/CustomerOnboardingAuthScreen-DGrAYURi.js +0 -1
- package/dist/assets/CustomerOnboardingRoutes-CfsElRde.js +0 -30
- package/dist/assets/EntityDetailRoutes-BTuykNTu.js +0 -1
- package/dist/assets/HubSpotOAuthCallbackScreen-B57X4QKD.js +0 -1
- package/dist/assets/InboxNotificationsProvider-CMdsyY0A.js +0 -1
- package/dist/assets/MagicLinkRoutes-Bo0FAVj9.js +0 -72
- package/dist/assets/MagicLinkSignInScreen-Dusac1BV.js +0 -12
- package/dist/assets/MobileAppDrawer-Bm1u6Ken.js +0 -1
- package/dist/assets/NotFoundScreen-BHAnIkPW.js +0 -1
- package/dist/assets/NotificationRoutes-DxiudUgY.js +0 -1
- package/dist/assets/OAuthConsentScreen-yUIZ6DV2.js +0 -1
- package/dist/assets/PandLWithForecastRoutes-eu7U2LpI.js +0 -1
- package/dist/assets/PeopleRoutes-D0lDTK4i.js +0 -22
- package/dist/assets/PerformanceRoutes-UIwOxwXM.js +0 -1
- package/dist/assets/ReimbursementApprovalRoutes-C0yLDyE9.js +0 -1
- package/dist/assets/RewardsRoutes-MCkqCd4q.js +0 -1
- package/dist/assets/ScreenRoutes-CoBHM0a5.js +0 -2
- package/dist/assets/SignInScreen-D-UWxMUC.js +0 -1
- package/dist/assets/SignOutScreen-CLMaxTgY.js +0 -9
- package/dist/assets/TaskListScreen-BBXffRbT.js +0 -9
- package/dist/assets/TaskRoutes-DvNx4Qap.js +0 -9
- package/dist/assets/TransactionDetailRoutes-Bz8OXpUB.js +0 -1
- package/dist/assets/WiseConfirmationScreen-BLw9xWiw.js +0 -12
- package/dist/assets/ZeniAccountStatementScreen-CJ2iauJ5.js +0 -9
- package/dist/assets/analyticsHelper-xKlm2_zz.js +0 -1
- package/dist/assets/expenseAutomationHelper-CkBJgYs_.js +0 -1
- package/dist/assets/useActualMatchingMatchDetail-DjU1UsXK.js +0 -1
- package/dist/assets/useAskAiCfoHostNavButtonProps-DYVVwney.js +0 -1
- package/dist/assets/useEmailConnectResultRefresh-fWgBKuNg.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-C2L5Bzwa.js"></script><link rel="modulepreload" crossorigin href="/assets/sentry-C_uJQK1a.js"><link rel="modulepreload" crossorigin href="/assets/core-BI5oX4mx.js"><link rel="modulepreload" crossorigin href="/assets/zeni-epic-state-CIizsNeB.js"><link rel="modulepreload" crossorigin href="/assets/mui-KP5Ep0NX.js"><link rel="modulepreload" crossorigin href="/assets/analytics-5LJ4BXQX.js"><link rel="modulepreload" crossorigin href="/assets/utils-BzQpFQvw.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.45-qa",
|
|
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.92",
|
|
32
|
-
"@zeniai/client-epic-state": "5.2.
|
|
33
|
-
"@zeniai/web-components": "4.3.
|
|
32
|
+
"@zeniai/client-epic-state": "5.2.48",
|
|
33
|
+
"@zeniai/web-components": "4.3.81",
|
|
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-BXyXenK7.js";import{A as i}from"./AddressScreen-Cbo3iSD8.js";import s from"./NotFoundScreen-BHAnIkPW.js";import"./sentry-D4svnzxK.js";import{n as d,o as r}from"./core-Bl4MLhFi.js";import"./zeni-epic-state-UM7IPCLf.js";import"./recharts-CZKBTuPa.js";import"./index-D_qRPRIi.js";import"./mui-CyP-P4av.js";import"./analytics-B06OpwA-.js";import"./plaid-C0aCR9wu.js";import"./dnd-CimhpTrK.js";import"./stripe-cKAAJElX.js";import"./lottie-2qUppQdg.js";import"./lexical-BbBoQdpc.js";import"./pdf-BENieWk6.js";import"./utils-Bycom664.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{j as r}from"./liveblocks-BXyXenK7.js";import{a as b}from"./sentry-D4svnzxK.js";import{h as T,u as P,g as j,i as E,j as B,l as M}from"./core-Bl4MLhFi.js";import{a1 as $,c as D,z as L,U as V,a7 as K,a8 as U,k as C,S,a3 as z,Z as h,a4 as F}from"./index-D_qRPRIi.js";import{Va as _,io as G,fE as R,Vb as N,c8 as O,Vc as q,mG as H}from"./zeni-epic-state-UM7IPCLf.js";import{n as Z}from"./mui-CyP-P4av.js";import J from"./NotFoundScreen-BHAnIkPW.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]="68dcb300-40f2-4e5e-9cf2-6e7bf5fca262",e._sentryDebugIdIdentifier="sentry-dbid-68dcb300-40f2-4e5e-9cf2-6e7bf5fca262")}catch{}})();const Q=Z.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
|
-
`,W=M((function(e,s){const{addressId:o,isSubPage:i,addressType:c}=s,l=R(e),a=s.roleMap!=null&&N(s.roleMap),n=i||c==="user_address"||O(l?.userRole??[])||a?void 0:"readonly";if(o==null){const t=q(c,e);return{addressToEdit:t?.addressToCreate,loadingState:t?.status?.fetchState,googleAPIKey:h.googleMapsAPIKey,isDisabled:n,isSubPage:i,dontShowSaveConfirmationPopup:s.dontShowSaveConfirmation}}const d=_(e,o);return{addressToEdit:d.address,loadingState:d.fetchState,googleAPIKey:h.googleMapsAPIKey,isDisabled:n}}),(function(e,s){const{navigate:o,location:i,addressType:c}=s,l=a=>{if(a==="express-pay")o("../express-pay/add-wire");else{const n=i.state,d=F(n?.pathnameStackToGoBack);let t=d.poppedPathname??v();const u=n?.queryParams;if(u){const f=new URLSearchParams(u).toString();f&&(t=`${t}?${f}`)}o(t,{state:{pathnameStackToGoBack:d.newStack}})}};return{onSubmitHandler:a=>{const n=X(a);e(H({addressType:c,addressToCreate:n})),C?.trackSaveAddressClicked(S.Event.saveAddressClicked,{street:a.street.addressString,city:a.city,state:a.state,country:a.country.selectedOption??"",postalCode:a.postalCode,suite:a.suite,secondaryInfo:a.secondaryInfo}),l(s.bankAccountContext)},onCancel:()=>{l(s.bankAccountContext)}}}))(z);function re({isSubPage:e,hideAddressSubTitle:s=!1,hideAddressBackButton:o=!1,dontShowSaveConfirmation:i,accountContext:c,addressTypeParam:l}){const a=T(),n=P(),d=j(),{addressId:t,addressType:u}=E(),f=$(),I=D(),k=L.getSignedInUser(),[g,w]=b.useState(t==null),p=B((m=>t!=null?_(m,t).fetchState:"Not-Started")),x=V();if(k==null)throw Error("Can't access address page without signing in...");const A=m=>m.trackPageLoaded(t!=null?S.Event.editAddress:S.Event.addAddress),y=l??u;return b.useEffect((()=>{g||t==null||(w(!0),n(G(t,!1)))}),[g,t,n]),y==null||y.match(/(user_address|company_address|company_registered_address|vendor_address|officer_([1-9]|10)_address|invoicing_customer_billing_address|invoicing_subscription_shipping_address|invoicing_business_address)$/g)?!g&&p==="Not-Started"||g&&p==="In-Progress"?r.jsx(K,{fetchState:p,style:{backgroundColor:I.colors.grey5}}):t!=null&&p==="Error"?(a(`${v(1)}/new`,{replace:!0}),r.jsx(r.Fragment,{})):r.jsxs(r.Fragment,{children:[r.jsx(U,{analytics:C,onLoad:A}),r.jsx(Q,{windowSize:f,children:r.jsx(W,{location:d,navigate:a,isSubPage:e===!0,hideAddressBackButton:o,hideAddressSubTitle:s,addressId:t,addressType:y,dontShowSaveConfirmation:i,bankAccountContext:c,roleMap:x?.loggedInUserRoleMap})})]}):r.jsx(J,{})}const v=(e=2)=>{let s="../";for(let o=0;o<e;o++)s=`${s}../`;return s},X=e=>({street:[e.street.addressString,e.suite,e.secondaryInfo],city:e.city,state:e.state,country:e.country.selectedOption??"",countryCode:e.countryCode,postalCode:e.postalCode,latitude:e.street.addressValue?.locationLat,longitude:e.street.addressValue?.locationLng});export{re as A,X as t};
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import{j as I}from"./liveblocks-BXyXenK7.js";import{a as o}from"./sentry-D4svnzxK.js";import{u as F,h as H,g as P,j as C,N as w}from"./core-Bl4MLhFi.js";import{TI as q,fE as z,gk as G,pR as Q,gL as A,gj as V,gh as B,U6 as J,gg as O}from"./zeni-epic-state-UM7IPCLf.js";import{u as K,z as E,L as D,G as M,H as W}from"./index-D_qRPRIi.js";import{n as X}from"./mui-CyP-P4av.js";import{P as h,a as _}from"./AccountMappingScreen-B400AyQJ.js";import{t as Y}from"./getLocaleForTenant-NAFAfy2t.js";import{g as Z,Q as ee}from"./QBOConnectionScreen-Dcslm4FM.js";import"./recharts-CZKBTuPa.js";import"./analytics-B06OpwA-.js";import"./plaid-C0aCR9wu.js";import"./dnd-CimhpTrK.js";import"./stripe-cKAAJElX.js";import"./lottie-2qUppQdg.js";import"./lexical-BbBoQdpc.js";import"./pdf-BENieWk6.js";import"./utils-Bycom664.js";import"./MobileAppDrawer-Bm1u6Ken.js";import"./InboxNotificationsProvider-CMdsyY0A.js";import"./useTaskManagerAccess-Rxke8A9H.js";import"./accountMappingHelper-Djr6f8Xt.js";import"./empty-B4WpR10s.js";import"./pdf-lib-CLkFJB86.js";import"./index-Bmwrrrme.js";import"./url-SRUWz_6t.js";import"./index-H-kll8aI.js";import"./decodeURIComponentSafe-Buybgpqw.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]="a8bae5a2-68ce-44ff-a73e-9f784add32e4",t._sentryDebugIdIdentifier="sentry-dbid-a8bae5a2-68ce-44ff-a73e-9f784add32e4")}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=H(),v=P(),{setLoading:c,clearAllLoading:m}=K(),S=o.useRef(!1),x=o.useRef(!1),N=o.useRef(!1),f=o.useRef(!1),{code:U,realmId:L,state:$}=Z(v.search),p=U!==""&&L!==""&&$!=="";p&&(N.current=!0);const j=sessionStorage.getItem(h),u=j===_.pending,R=j===_.ready,b=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,d=e?.externalConnections?.saveConnectionState,y=e.externalConnections?.accounting[0]?.isValid;o.useLayoutEffect((()=>{c(D.CONNECTION_AUTH)}),[c]),o.useEffect((()=>{S.current||a==null||g==null||(S.current=!0,n==="Completed"||r!=="Not-Started"&&r!=="Error"||(c(D.TENANT_FETCHING),t(G(a.userId,g))))}),[S,n,c]),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(Q(a.userId)))}),[x,n,r]),o.useEffect((()=>{a==null||e?.tenantId==null||e.externalConnections!=null||n!=="Completed"&&r!=="Completed"||l==="In-Progress"||d!=="Error"||(c(D.CONNECTION_AUTH),t(A(a.userId,e.tenantId)))}),[d]),o.useEffect((()=>{n!=="Completed"&&r!=="Completed"||a==null||e?.tenantId==null||(t(V(e.tenantId)),E.saveActiveTenantDomainForUser(e.tenantEmailDomain),B(a?.userId,a?.zeniSessionId,e.tenantId),M.updateAppLocaleID(Y(J(e))),e.externalConnections!=null||n!=="Completed"&&r!=="Completed"||l==="In-Progress"||a==null||e==null||t(A(a.userId,e.tenantId)))}),[n,r,l]),o.useEffect((()=>{b.tenantsCoreDetailsInOrder.length>0&&n==="Completed"&&E.saveSignedInUserTenants(b.tenantsCoreDetailsInOrder)}),[b.tenantsCoreDetailsInOrder.length,n]);const T=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&&d==="In-Progress"&&(f.current=!0)}),[u,d]),o.useEffect((()=>{if(!u||T)return;const s=e.tenantEmailDomain!=null?`/${e.tenantEmailDomain}/settings/accounting`:"/";return f.current&&d==="Completed"?(sessionStorage.setItem(h,_.ready),m(),void i(s,{replace:!0})):f.current&&d==="Error"?(sessionStorage.removeItem(h),t(O({messageSection:"accounting_projects_qbo_reconnect_failed",messageText:"failed",type:"error"})),m(),void i(s,{replace:!0})):void(p||N.current||f.current||y!==!0||(sessionStorage.removeItem(h),t(O({messageSection:"accounting_projects_qbo_reconnect_failed",messageText:"failed",type:"error"})),m(),i(s,{replace:!0})))}),[u,T,d,p,y,e.tenantEmailDomain,m,t,i]),T)return null;if(p||y!==!0)return I.jsx(te,{children:I.jsx(ee,{})});if(u)return null;const k=e.tenantEmailDomain!=null?`/${e.tenantEmailDomain}/settings/accounting`:"/";return R?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-BXyXenK7.js";import{z as m}from"./index-D_qRPRIi.js";import{g as n}from"./QBOConnectionScreen-Dcslm4FM.js";import"./sentry-D4svnzxK.js";import{g as p,N as a}from"./core-Bl4MLhFi.js";import"./zeni-epic-state-UM7IPCLf.js";import"./recharts-CZKBTuPa.js";import"./mui-CyP-P4av.js";import"./analytics-B06OpwA-.js";import"./plaid-C0aCR9wu.js";import"./dnd-CimhpTrK.js";import"./stripe-cKAAJElX.js";import"./lottie-2qUppQdg.js";import"./lexical-BbBoQdpc.js";import"./pdf-BENieWk6.js";import"./utils-Bycom664.js";import"./empty-B4WpR10s.js";import"./pdf-lib-CLkFJB86.js";import"./index-Bmwrrrme.js";import"./url-SRUWz_6t.js";import"./index-H-kll8aI.js";import"./decodeURIComponentSafe-Buybgpqw.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,30 +0,0 @@
|
|
|
1
|
-
import{j as s}from"./liveblocks-BXyXenK7.js";import{t as xt,A as $e}from"./AddressScreen-Cbo3iSD8.js";import wt from"./NotFoundScreen-BHAnIkPW.js";import{a as d,t as Me}from"./sentry-D4svnzxK.js";import{h as _e,g as Ee,u as se,i as Te,j as x,N as Q,q as At,l as it,n as Pt,o as H}from"./core-Bl4MLhFi.js";import{fE as X,dZ as xe,dY as we,bq as Dt,TZ as Bt,bR as jt,pP as Ft,Bf as Vt,Bi as Ut,Vk as Rt,Vl as Lt,lt as Oe,lw as ct,UA as Nt,b$ as Gt,c8 as fe,BJ as Ae,Bu as $t,Vm as me,BK as dt,S7 as Mt,mG as ut,dh as lt,Vn as Qt,Vo as Kt,uz as zt,Un as Ce,hU as qt,Um as be,hR as Ht,G7 as Zt,uD as Jt,hJ as Wt,hM as Qe,Vp as pt,Vq as Yt,LU as Xt,Vr as en,LY as tn,Bl as nn,Vs as an,Vt as on,lr as sn,lu as rn,BW as cn,Bw as mt,BI as dn,bE as Ke,cE as un,BV as ze,uS as ln,uG as pn,my as mn,gF as gn,gE as fn,gD as yn,Vu as hn,Bo as Cn,BX as bn,B_ as Sn,C1 as In,C7 as kn,di as On}from"./zeni-epic-state-UM7IPCLf.js";import{z,N as Pe,d as W,q as vn,p as q,a8 as re,k as g,aE as _n,ai as gt,a1 as En,E as ft,U as yt,j as Y,Z as ge,S as ve,aF as Tn,H as qe,v as He,ae as xn,aG as Ze,aH as wn,aI as An}from"./index-D_qRPRIi.js";import{n as De}from"./mui-CyP-P4av.js";import{g as Pn,h as Dn,q as ie}from"./QBOConnectionScreen-Dcslm4FM.js";import{u as Bn,a as jn}from"./useEmailConnectResultRefresh-fWgBKuNg.js";import{u as Fn}from"./useChargeCardPusherEvents-CLgbV2wJ.js";import"./recharts-CZKBTuPa.js";import"./analytics-B06OpwA-.js";import"./plaid-C0aCR9wu.js";import"./dnd-CimhpTrK.js";import"./stripe-cKAAJElX.js";import"./lottie-2qUppQdg.js";import"./lexical-BbBoQdpc.js";import"./pdf-BENieWk6.js";import"./utils-Bycom664.js";import"./empty-B4WpR10s.js";import"./pdf-lib-CLkFJB86.js";import"./index-Bmwrrrme.js";import"./url-SRUWz_6t.js";import"./index-H-kll8aI.js";import"./decodeURIComponentSafe-Buybgpqw.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},l=new e.Error().stack;l&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[l]="de82fd8a-11d4-47a4-97f3-fc4c02a43d46",e._sentryDebugIdIdentifier="sentry-dbid-de82fd8a-11d4-47a4-97f3-fc4c02a43d46")}catch{}})();const Je=e=>{switch(e){case"Complete":return"yes";case"Pending Review":case"Incomplete":return"partially";default:return"no"}},Vn=()=>{const e=_e(),l=Ee(),i=se(),[a,p]=d.useState(!1),[u,c]=d.useState(!1),{tenantEmailDomain:v}=Te(),t=z.getSignedInUser(),{useFeatureGate:n}=Pe(),{isFeatureEnabled:C}=n(W.isApAgingFeatureEnabled),{isFeatureEnabled:o}=n(W.isArAgingFeatureEnabled),{isFeatureEnabled:A}=n(W.isReferralFeatureEnabled),{isFeatureEnabled:w}=n(W.isDebitCardFeatureEnabled),k=vn(),O=x((S=>X(S))),P=x((S=>S.onboardingCustomerViewState.fetchState)),_=O.excludedResources,F=O.companyId??z.getSignedInUserTenant(v)?.companyId;if(t==null)throw Error("Can't access onboarding flow without signing in...");const m=xe(w,O),b=we(O),D=[],U=_?.resources?.find((S=>S.resource==="/reports/top_expenses"))==null,h=_?.resources?.find((S=>S.resource==="/reports/task_card"))==null,r=O?.userRole!=null&&Dt(O?.userRole),E=_?.resources?.find((S=>S.resource==="/bills"))==null&&!r,T=_?.resources?.find((S=>S.resource==="/reimbursements"))==null;U===!1&&D.push("top_expenses"),h===!1&&D.push("task_card"),E===!1&&D.push("bill_pay_card","bill_pay_promo_card"),T===!1&&D.push("reimbursement_card","reimbursement_promo_card"),D.push("zeni_accounts_promo_card","treasury_promo_card"),A===!1&&D.push("rewards_card");const f=x((S=>{const V=[];C===!1&&V.push("accounts_payable_aging"),o===!1&&V.push("accounts_receivable_aging"),V.push("zeni_accounts_promo_card","treasury_promo_card"),A===!1&&V.push("rewards_card"),k===!1&&V.push("expense_automation_card");const Z=Bt(S,V);return jt(Z.reportsInOrder.map(($=>({fetchState:$.fetchState,error:$.error})))).fetchState}));d.useEffect((()=>{P!=="Completed"||a||m||b||(p(!0),i(Ft(t.userId,F,O.tenantId,!0,!1,D)))}),[a,P,m,b,t,O.tenantId,i]);const B=d.useRef(!1),N=d.useCallback((()=>{const S={pathnameStackToGoBack:q(l.state?.pathnameStackToGoBack,l.pathname),message:"activation"};e(m?"../../checking":b?"../../cards":"../../dashboard",{state:S})}),[e,l,m,b]),G=d.useCallback((()=>{B.current||(B.current=!0,N())}),[N]);if(d.useEffect((()=>{const S=setTimeout((()=>c(!0)),3e3);return()=>clearTimeout(S)}),[]),d.useEffect((()=>{const S=setTimeout(G,6e3);return()=>clearTimeout(S)}),[G]),d.useEffect((()=>{m||b||!u||f!=="Completed"&&f!=="Error"||G()}),[u,f,m,b,G]),P!=="Completed")return s.jsx(Q,{to:"../"});const L=O.company?.companyOnboardingInfo?.onboardingInfo,ee={timeSinceQuoteSign:L?.onboardingTimeSinceQuoteSigned??"",timeSinceQuoteSignInMinutes:L?.onboardingToQuoteSignMinutes??0,isKybDone:Je(L?.businessVerified?.status),isKycDone:Je(L?.identityVerified?.status),paymentType:"",paymentSource:"",qboConnectionSource:L?.accountingConnectionCreationMode??""};return s.jsxs(s.Fragment,{children:[s.jsx(re,{analytics:g,onLoad:S=>S.trackOnboardingDashboardActivation(ee)}),s.jsx(_n,{show:!0,onComplete:G})]})},Se=["reading_books","finance_graph","reconciliation","cfo_foundation"],Ie=["llm_fine_tuning","rag_knowledge_graph","personalized_context"],We=(e,l)=>{const i=new Map(e.map((a=>[a.key,a])));return l.map((a=>{return p=i.get(a)?.status,p==="starting"||p==="building"?p:"idle";var p}))},Ye=(e,l)=>{if(e.length===0)return!1;const i=new Map(e.map((a=>[a.key,a])));return l.every((a=>i.get(a)?.status==="ready"))},Xe=De.div`
|
|
2
|
-
display: flex;
|
|
3
|
-
height: 100vh;
|
|
4
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
5
|
-
`,et=De.div`
|
|
6
|
-
display: flex;
|
|
7
|
-
flex-direction: column;
|
|
8
|
-
align-items: center;
|
|
9
|
-
flex: 1;
|
|
10
|
-
min-width: 0;
|
|
11
|
-
|
|
12
|
-
${e=>e.skipLegacyDrawerOffset?`
|
|
13
|
-
width: 100%;
|
|
14
|
-
padding-left: ${qe.sp0};
|
|
15
|
-
`:`
|
|
16
|
-
min-width: calc(100% - ${He}px);
|
|
17
|
-
padding-left: ${He}px;
|
|
18
|
-
`}
|
|
19
|
-
|
|
20
|
-
${e=>e.theme.breakpoints.down("md")} {
|
|
21
|
-
width: 100%;
|
|
22
|
-
padding-left: ${qe.sp0};
|
|
23
|
-
}
|
|
24
|
-
|
|
25
|
-
${e=>e.windowSize!=="small"?"overflow: auto;":""}
|
|
26
|
-
`,tt=it((function(e,l){const{companyId:i,isAdmin:a,currentTenant:p,isOnAddressPage:u}=l,c=z.getSignedInUser(),v=p.tenantId,t={userId:c?.userId??"",sessionId:c?.zeniSessionId??"",tenantId:v??""},n=X(e),C=Ae(e,i),o=pt(e),A=fe(p?.userRole??[])&&C.updateStatus.fetchState!=="In-Progress"?void 0:"readonly",w=Yt(e.userRoleConfigState);return{onboardingCustomerView:C,analytics:g,isRefreshingViewInBackground:!1,isDisabled:A,companyTitles:w.companyTitles,connectedAccountProvider:n.company?.featuresActivationInfo.connectedAccountProvider??"",fileProps:{filesEndPoint:xn.fileMicroServiceBaseUrl,authParams:t},signedInUser:z.getSignedInUser(),currentTenant:n,isAdmin:a,isOnAddressPage:u,cardPaymentView:o,isCardPaymentPopupOpen:!1,stripeKey:ge.stripeKey}}),(function(e,l){const{companyId:i,currentTenant:a,themeState:p,navigate:u,location:c}=l,{tenantEmailDomain:v}=a;return{onFetchLinkTokenClick:(t,n)=>{e(kn(t,n))},onEstablishConnectionClick:(t,n)=>{e(In(t,n))},onUpdatePaymentAccountStatus:(t,n,C)=>{e(Sn(t,n,C))},onUpdatePaymentAccountLoginStatus:(t,n)=>{e(bn(!1,t,n))},onEstablishConnectionSuccess:()=>{e(Cn(i,!0,!1))},handleOnConnectClick:()=>{g.trackOnboardingConnectQBO(),ie.handleClick()},updateQBOPopupState:t=>{e(me({isQBOPopupOpen:t}))},onCompanyOfficerUpdated:t=>{const n=t.map((C=>{const{officerType:o,userId:A,name:w,email:k,ssn:O,nationalityCountryCode:P,dob:_,phone:F,syncToken:m,selectDocument:b,role:D,ownership:U,isSelectedForVerification:h,userVerificationStatus:r,fileIds:E,isPhoneVerified:T}=C;let f;return b.selectDocumentType==="driverLicense"?f="driving_license":b.selectDocumentType==="passport"?f="passport":b.selectDocumentType==="stateId"?f="id_document":b.selectDocumentType==="ssnCard"&&(f="social_security_card"),{officerType:o,userId:A,firstName:w.firstName,lastName:w.lastName,email:k,ssn:O,nationalityCountryCode:P?.selectedOption!=null?Ze(P.selectedOption):void 0,phone:F,birthday:_!=null?Ke(_?.toString()):_,syncToken:m,titleAtCompany:D.selectedOption,ownershipInCompany:U,documentTypeSelectedForVerification:f,isSelectedForVerification:h,userVerificationStatus:r,fileIds:E,additionalDocumentTypesRequestedForVerification:[],additionalSubmittedDocumentsForVerificationFileIds:[],areAdditionalDocumentsRequestedForVerification:!1,areAdditionalDocumentsSubmittedForVerification:!1,isPhoneVerified:T}}));e(ze({officers:n}))},onGetOtp:(t,n)=>{e(yn(t,"CustomerOnboarding")),n!=null&&e(hn({officerType:n,phone:t}))},onResendOtp:t=>{e(fn(t,"CustomerOnboarding"))},onVerifyOtp:(t,n)=>{g.trackOnboardingPhoneVerified(),e(gn(t,n,"CustomerOnboarding"))},updateFilesEntity:t=>{e(mn({files:t}))},onDeleteFile:t=>{e(pn(t))},onEditFileName:(t,n)=>{e(ln(t,n.split(".")[0]))},onCompanyDetailsChanged:t=>{const{companyDescription:n,companyIndustry:C,companyIndustryType:o,companyLegalName:A,companyTaxId:w,companyWebsite:k,companyPhone:O,primaryContactEmail:P,primaryContactName:_,primaryContactUserId:F,primaryContactSyncToken:m,syncToken:b,fileIds:D,typeOfIncorporation:U,stateOfIncorporation:h,incDate:r,companySourceOfFunds:E,companySourceOfFundsDescription:T,companySubIndustry:f,countriesOfOperations:B,purposeOfAccount:N,purposeOfAccountDescription:G,regulatedStatus:L,regulatedStatusDescription:ee,transactionVolume:S,transactionVolumeDescription:V,usNexus:Z,usNexusTypes:$}=t,M={companyId:i,companyDescription:n,companyIndustry:C.selectedOption,companyIndustryType:o?.selectedOption??"",companyLegalName:A,taxIdOrEIN:w,website:k!=""&&k!=null?un(k):void 0,phone:O,syncToken:b,fileIds:D,incDate:r!=null?Ke(r?.toString()):r,typeOfIncorporation:U?.selectedOption??"",stateOfIncorporation:h?.selectedOption??"",companySourceOfFunds:E?.selectedOption??"",companySourceOfFundsDescription:T,companySubIndustry:f?.selectedOption??"",countriesOfOperations:B?.selectedOptions.map((R=>R.length===2?R:Ze(R)))??[],purposeOfAccount:N?.selectedOption??"",purposeOfAccountDescription:G,regulatedStatus:L??"",regulatedStatusDescription:ee,transactionVolume:S?.selectedOption??"",transactionVolumeDescription:V,usNexus:Z,usNexusTypes:$?.selectedOptions??[]},ce={userId:F,firstName:_.firstName,lastName:_.lastName,email:P,syncToken:m};e(ze({companyDetails:M,primaryContactDetails:ce}))},onAddressClick:(t,n)=>{const C=at(v,t,n),o=q(c.state?.pathnameStackToGoBack,c.pathname);u(C,{state:{pathnameStackToGoBack:o}})},onRegisteredAddressClick:(t,n)=>{const C=at(v,t,n),o=q(c.state?.pathnameStackToGoBack,c.pathname);u(C,{state:{pathnameStackToGoBack:o}})},onUpdateCustomerView:(t,n,C)=>{e(dn(i,!1,n,C,t))},onAddressEditHandler:t=>{if(t!=null){const n=xt(t);e(ut({addressType:"subscription_billing_address",addressToCreate:n}))}},onSkipSetupClick:()=>{const t=q(c.state?.pathnameStackToGoBack,c.pathname);e(mt(i,!1,!1)),u("./activation",{state:{pathnameStackToGoBack:t}})},onUpdateStep:t=>{e(dt({step:t}))},onUpdateSubStep:t=>{e(cn({subStep:t}))},onZeniLogoClick:()=>{p.toggle()},handleLogOutClick:()=>{const t=q(c.state?.pathnameStackToGoBack,c.pathname);u("/signout",{replace:!0,state:{pathnameStackToGoBack:t,message:"logout"}})},handleCockpitClick:()=>{g.trackOnboardingFlowExited("cockpit"),window.open("/cockpit")},handleReferralsClick:()=>{u(`/${v}/rewards`)},handleCreateCardSetupIntent:t=>{e(ct(t))},handleConfirmCardSetupIntent:t=>{e(rn(t))},updateCardPaymentModalState:t=>{e(me({isCardPaymentPopupOpen:t}))},handleAddCardPaymentSource:(t,n,C)=>{e(sn(t,n,C))},handleFetchPaymentSources:()=>{e(Oe())},resetCardPaymentViewState:()=>{e(on())},handleResetCardPaymentErrorStatuses:()=>{e(an())},redirectToProductSuitePage:()=>{g.trackOnboardingFlowExited("product_suite");const t=q(c.state?.pathnameStackToGoBack,c.pathname);u(`/${v}/onboarding/thankyou`,{state:{pathnameStackToGoBack:t,message:"OnboardingThankyou"},replace:!0})},onAcknowledgeAiFinanceTeam:()=>{i!=null&&(g.trackOnboardingAiFinanceTeamAcknowledged(),e(nn(i)))},onIdentityDocumentUploadedForAutofill:t=>{if(i==null)return;const n=en(t.documentType);n!=null&&(g.trackOnboardingDocumentUploaded("kyc",n),e(tn({target:"onboarding",companyId:i,officerType:t.officerType,fileId:t.fileId,documentType:n})))},onCompanyDocumentUploadedForAutofill:t=>{i!=null&&(g.trackOnboardingDocumentUploaded("kyb",t.documentType),e(Xt({target:"onboarding",companyId:i,fileId:t.fileId,documentType:t.documentType})))}}}))(Tn),le=({taxCFOCustomer:e=!1,isOnAddressPage:l=!1,appContent:i})=>{const a=gt(),p=_e(),u=Ee(),c=se(),v=En(),t=ft(),[n,C]=d.useState(!1),[o,A]=d.useState(!1),[w,k]=d.useState(!1),{tenantEmailDomain:O}=Te(),P=yt(),{useFeatureGate:_}=Pe(),{isFeatureEnabled:F}=_(W.isDebitCardFeatureEnabled),m=At("/:tenantEmailDomain/onboarding")!==null&&u.search?.includes("code"),b=x((y=>y.onboardingCustomerViewState.fetchState)),D=x((y=>y.onboardingCustomerViewState.currentStep)),U=x((y=>y.onboardingCustomerViewState.uiState)),h=x((y=>X(y))),r=x((y=>y.userRoleConfigState.fetchState)),E=x((y=>y.cardPaymentViewState)),T=Y(E.addCardPaymentSourceStatus.fetchState),f=E.addCardPaymentSourceStatus.fetchState,{code:B,realmId:N,state:G}=Pn(u.search),L=h.externalConnections?.accounting[0],ee=L?.connectionType,S=L?.connectionName,V=L?.connectionId??"",Z=z.getSignedInUser()?.userId??"",$=d.useRef({realmId:"",connectionId:""});d.useEffect((()=>{o||(A(!0),c(Oe()))}),[o,c]),d.useEffect((()=>{w||(ct(["card"]),k(!0))}),[w]),d.useEffect((()=>{T==="In-Progress"&&f==="Completed"&&c(Oe())}),[T,f]),d.useEffect((()=>{Dn(B,N,G,V,Z)===!0&&h.externalConnections?.saveConnectionState!=="In-Progress"&&b==="Completed"&&(c(Nt(h.tenantId,{connection_type:ee??"accounting",connection_name:S??"quickbooks_online",authorization_code:B,realm_id:N,connection_id:V,user_id:Z},Gt(window.location.origin+"/onboarding/auth"))),$.current={realmId:N,connectionId:V},g.trackOnboardingSaveQBOConnection(N,V),p(u.pathname))}),[B,N,G,u.pathname,b]),d.useEffect((()=>{ie.isInitiated===!1&&b==="Completed"&&ie.init("/onboarding/auth",h.tenantEmailDomain)}),[b]);const M=h.companyId??z.getSignedInUserTenant(O)?.companyId,ce=fe(h?.userRole??[]),R=x((y=>Ae(y,M)));d.useEffect((()=>{n||b!=="Not-Started"||M==null||(C(!0),c($t(M,!0,!m)))}),[n,b,M]);const te=h.externalConnections?.saveConnectionState,Be=Y(te);d.useEffect((()=>{Be==="In-Progress"&&(te==="Completed"||te==="Error")&&U.isQBOPopupOpen&&D==="connect_ledger"&&(te==="Completed"?g.trackOnboardingQBOConnectionSuccess($.current.realmId,$.current.connectionId):g.trackOnboardingQBOConnectionFailed($.current.realmId,$.current.connectionId,h.externalConnections?.saveOAuthConnectionError?.message??""),c(me({isQBOPopupOpen:!1})))}),[te,Be,U.isQBOPopupOpen,D,g,c]),d.useEffect((()=>{b==="Completed"&&m&&(c(dt({step:"connect_ledger"})),c(me({isQBOPopupOpen:!0})))}),[m,b]),d.useEffect((()=>{r==="Not-Started"&&c(Mt(!0))}),[r,c]);const ht=Y(R.companyDetailsLocalData?.addressStatus);d.useEffect((()=>{R.companyDetailsLocalData?.registeredAddressStatus?.addressToCreate==null&&R.companyDetailsLocalData?.addressStatus?.addressToCreate!=null&&ht==null&&c(ut({addressType:"company_registered_address",addressToCreate:R.companyDetailsLocalData?.addressStatus?.addressToCreate}))}),[R.companyDetailsLocalData?.addressStatus?.addressToCreate,R.companyDetailsLocalData?.registeredAddressStatus?.addressToCreate]);const Ct=R.isInterimEmailSent,je=z.getSignedInUser();if(je==null)throw Error("Can't access onboarding flow without signing in...");const bt=xe(F,h),St=we(h),Fe=h.company?.companyOnboardingInfo.isOnboardingCompleted,Ve=y=>y.trackPageLoaded(ve.Event.onboardingPage),ye=h.productSettings.isOtherProductsEnabled,It=ye===!0&&!lt(h),kt=h.productSettings.isTreasuryEnabled,Ue=Un({tenantEmailDomain:O??"",signedInUserEmail:je.userEmail??"",companyId:M}),Re=(({companyId:y})=>{const K=se(),de=x((j=>j.onboardingCustomerViewState?.aiAgentsActivation)),ne=x((j=>X(j).company?.companyOnboardingInfo?.onboardingInfo?.onboardingAiActivationInfo?.isOnboardingAiActivationViewed??!1)),he=d.useCallback((()=>{K(Vt())}),[K]);d.useEffect((()=>{he()}),[he]);const Le=d.useCallback((()=>{y==null||y===""||ne||K(Ut(y))}),[y,ne,K]),Ot=d.useMemo((()=>{if(y==null||y==="")return[];const j=`private-encrypted-${y}`;return[`${j}.ledger-ingestion.counts-updated`,`${j}.ai-agents-activation.phase-changed`]}),[y]),vt=d.useCallback(((j,ae)=>{if(ae==null||typeof ae!="object")return;const I=ae;if(j!=="ledger-ingestion.counts-updated"){if(j==="ai-agents-activation.phase-changed"){const ue=typeof I.phase_key=="string"?I.phase_key:typeof I.key=="string"?I.key:"",J=typeof I.status=="string"?I.status:"idle";if(ue==="")return;K(Lt({key:ue,status:J==="starting"||J==="building"||J==="ready"?J:"idle",startedAt:typeof I.started_at=="string"?I.started_at:void 0,completedAt:typeof I.completed_at=="string"?I.completed_at:void 0}))}}else K(Rt({customerCount:typeof I.customer_count=="number"?I.customer_count:void 0,glAccountCount:typeof I.gl_account_count=="number"?I.gl_account_count:void 0,targetTransactionCount:typeof I.target_transaction_count=="number"?I.target_transaction_count:void 0,transactionCount:typeof I.transaction_count=="number"?I.transaction_count:void 0,vendorCount:typeof I.vendor_count=="number"?I.vendor_count:void 0}))}),[K]);return Fn({events:Ot,onEvent:vt,onSubscribed:he}),d.useMemo((()=>{const j=de?.phases??[],ae=We(j,Se),I=We(j,Ie),ue=Ye(j,Se),J=Ye(j,Ie),Ne=j.some((Tt=>Tt.status!=="idle")),oe=!ne&&!Ne,Ge=ne&&!Ne,_t=Ge?Se.map((()=>"building")):ae,Et=Ge?Ie.map((()=>"building")):I;return{ledgerRowStatuses:oe?void 0:_t,backgroundRowStatuses:oe?void 0:Et,showLedgerReadyInLabel:oe?void 0:ue,showBackgroundReadyInLabel:oe?void 0:J,forceContinueEnabled:!oe||void 0,counts:de?.counts,onContinueClicked:Le}}),[de?.phases,de?.counts,ne,Le])})({companyId:M});if(Fe===!0){if(!ye)return kt?s.jsx(Q,{to:"../../treasury"}):bt?s.jsx(Q,{to:"../../checking"}):St?s.jsx(Q,{to:"../../cards"}):s.jsx(Q,{to:"../../dashboard"});const y=R.updateStatus.fetchState==="In-Progress";if(ye&&!y)return e?s.jsxs(Xe,{children:[s.jsx(re,{analytics:g,onLoad:K=>Ve(K)}),s.jsx(tt,{navigate:p,location:u,companyId:M,currentTenant:h,isAdmin:ce,isOnAddressPage:l,themeState:t,googleAPIKey:ge.googleMapsAPIKey,integrationsSectionProps:Ue,aiAgentsActivationProps:Re,meetingUrl:a("onboarding_overview")}),i!=null?s.jsx(et,{windowSize:v,skipLegacyDrawerOffset:l&&h.productSettings.isOtherProductsEnabled!==!0,children:i}):null]}):s.jsx(Q,{to:"../../onboarding/thankyou"})}else if(Fe===!1&&P?.loggedInUserRoleMap!=null)return Ct===!0&&It?s.jsx(Q,{to:"../../onboarding/thankyou"}):s.jsxs(Xe,{children:[s.jsx(re,{analytics:g,onLoad:y=>Ve(y)}),s.jsx(tt,{navigate:p,location:u,companyId:M,currentTenant:h,isAdmin:ce,isOnAddressPage:l,themeState:t,googleAPIKey:ge.googleMapsAPIKey,integrationsSectionProps:Ue,aiAgentsActivationProps:Re,meetingUrl:a("onboarding_overview")}),i!=null?s.jsx(et,{windowSize:v,skipLegacyDrawerOffset:l&&h.productSettings.isOtherProductsEnabled!==!0,children:i}):null]});return null},ke="external_integrations",Un=({tenantEmailDomain:e,signedInUserEmail:l,companyId:i})=>{const a=se(),{pendingAutoFocusTabId:p}=Bn(),{plaidAccounts:u,onAddPlaidAccount:c,onReLoginPlaidAccount:v}=jn({companyId:i}),t=x((r=>r.plaidAccountViewState.external_account.plaidConnectionDetails)),n=x((r=>X(r))),C=x((r=>r.tenantState.fetchState)),o=x((r=>Qt(r,i))),A=x((r=>Kt(r,ke))),w=d.useMemo((()=>new Set(A.map((r=>r.additionalInfo)).filter((r=>r!=null)))),[A]),k=n.tenantId,O=fe(n.userRole??[]);d.useEffect((()=>{a(zt(ke))}),[a]);const P=o.externalConnections?.saveAPIKeyConnectionState,_=o.externalConnections?.saveAPIKeyConnectionError?.message,F=Y(P);d.useEffect((()=>{F==="In-Progress"&&(P==="Completed"?g.trackIntegrationConnected("chargebee","Onboarding","revenue"):P==="Error"&&g.trackIntegrationConnectFailed("chargebee","Onboarding","revenue",_??""))}),[P,F,_]);const m=o.externalConnections?.saveOAuthConnectionState,b=o.externalConnections?.saveOAuthConnectionError?.message,D=Y(m);d.useEffect((()=>{D==="In-Progress"&&(m==="Completed"?g.trackIntegrationConnected("hubspot","Onboarding","revenue"):m==="Error"&&g.trackIntegrationConnectFailed("hubspot","Onboarding","revenue",b??""))}),[m,D,b]);const U=o.externalConnections?.saveConnectorCredentialsStateBySlug,h=Y(U);return d.useEffect((()=>{const r=U??{},E=h??{},T=o.externalConnections?.saveConnectorCredentialsErrorBySlug??{};Object.keys(r).forEach((f=>{if(E[f]!=="In-Progress")return;let B;try{B=Ce(f)}catch{return}r[f]==="Completed"?g.trackIntegrationConnected(B,"Onboarding","payments"):r[f]==="Error"&&g.trackIntegrationConnectFailed(B,"Onboarding","payments",T[f]?.message??"")}))}),[U,h,o]),d.useMemo((()=>({isAdmin:O,analytics:g,referrer:"Onboarding",integrationsView:o,isLoading:C==="In-Progress",notifyMeRegisteredSlugs:w,autoFocusTabId:p??void 0,saveChargeBeeState:o.externalConnections?.saveAPIKeyConnectionState??"Not-Started",saveChargeBeeError:o.externalConnections?.saveAPIKeyConnectionError?.message,saveHubSpotState:o.externalConnections?.saveOAuthConnectionState??"Not-Started",saveHubSpotError:o.externalConnections?.saveOAuthConnectionError?.message,saveConnectorCredentialsStateBySlug:o.externalConnections?.saveConnectorCredentialsStateBySlug??{},saveConnectorCredentialsErrorBySlug:Object.fromEntries(Object.entries(o.externalConnections?.saveConnectorCredentialsErrorBySlug??{}).map((([r,E])=>[r,E?.message]))),deleteConnectionState:o.externalConnections?.deleteConnectionState??"Not-Started",deleteConnectionError:o.externalConnections?.deleteConnectionError?.message,onConnectGmail:()=>{g.trackIntegrationConnectClicked("gmail","Onboarding","email"),a(Qe(k,"gmail",nt()))},onConnectOutlook:()=>{g.trackIntegrationConnectClicked("outlook","Onboarding","email"),a(Qe(k,"outlook",nt()))},onConnectHubSpot:(r,E)=>{const T=o.externalConnections?.revenue?.find((B=>B.connectionName==="hubspot"))?.connectionId;if(T==null)return;g.trackIntegrationCredentialsSubmitted("hubspot","Onboarding","revenue");const f=`${window.location.origin}/oauth/hubspot/callback`;sessionStorage.setItem("hubspot_oauth_pending",JSON.stringify({client_id:r,client_secret:E,connection_id:T,redirect_uri:f,tenant_id:k})),window.location.href=`https://app.hubspot.com/oauth/authorize?client_id=${encodeURIComponent(r)}&scope=${encodeURIComponent("oauth crm.objects.deals.read crm.objects.owners.read")}&redirect_uri=${encodeURIComponent(f)}`},onDisconnect:(r,E)=>{const T=[...o.externalConnections?.accounting??[],...o.externalConnections?.payments??[],...o.externalConnections?.revenue??[]].find((B=>B.connectionId===r))?.connectionName;let f;try{f=T!=null?Ce(T):void 0}catch{f=void 0}f!=null&&g.trackIntegrationDisconnected(f,"Onboarding",E),a(Wt(k,r,be(E)))},onNotifyMe:r=>{g.trackIntegrationsNotifyMeClicked("Onboarding",r),a(Jt(ke,r,l))},onReconnectQBO:()=>{ie.init("/onboarding/auth",e),ie.handleClick()},onRefreshClick:()=>{o.integrations.refreshQBO.fetchState!=="In-Progress"&&a(Zt())},onSaveChargeBeeCredentials:(r,E)=>{const T=o.externalConnections?.revenue?.find((f=>f.connectionName==="chargebee"))?.connectionId;T!=null&&(g.trackIntegrationCredentialsSubmitted("chargebee","Onboarding","revenue"),a(Ht(k,T,be("revenue"),Ce("chargebee"),{api_key:r,site:E})))},onSaveConnectorCredentials:r=>{g.trackIntegrationCredentialsSubmitted(r.connectionName,"Onboarding","payments"),a(qt(k,be("payments"),r))},plaidAccounts:u,onAddPlaidAccount:c,onReLoginPlaidAccount:v,plaidConnectionDetails:t})),[O,o,C,w,p,k,l,e,a,u,c,v,t])};function nt(){const e=new URL(window.location.href);return e.searchParams.set("onboarding_step","connect_data_source"),e.toString()}function at(e,l,i){let a=`/${e}/onboarding/address`;return a=i!=null?a.concat(`/edit/${l}/${encodeURIComponent(i)}`):a.concat(`/new/${l}`),a}const ot=De.div`
|
|
27
|
-
display: flex;
|
|
28
|
-
height: 100vh;
|
|
29
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
30
|
-
`,st=it((function(e,l){const{companyId:i,currentTenant:a}=l,p=Ae(e,i),u=pt(e);return{hasVerifiedBankAccount:(p.paymentAccount?.providerVerificationStatus?.code?.includes("verified")??!1)||(u.bankAccountsList[0]?.providerVerificationStatus?.code?.includes("verified")??!1),isDisabled:fe(a?.userRole??[])&&p.updateStatus.fetchState!=="In-Progress"?void 0:"readonly",signedInUser:z.getSignedInUser(),currentTenant:a}}),(function(e,l){const{currentTenant:i,themeState:a,navigate:p,location:u}=l,{tenantEmailDomain:c}=i;return{onZeniLogoClick:()=>{a.toggle()},handleLogOutClick:()=>{const v=q(u.state?.pathnameStackToGoBack,u.pathname);p("/signout",{replace:!0,state:{pathnameStackToGoBack:v,message:"logout"}})},handleCockpitClick:()=>{window.open("/cockpit")},handleReferralsClick:()=>{p(`/${c}/rewards`)},handleUpdatePaymentAddressDetailClick:()=>{const v=q(u.state?.pathnameStackToGoBack,u.pathname);p(`/${c}/onboarding/billing/edit`,{state:{pathnameStackToGoBack:v,message:"UpdatePaymentAddressDetail"}})}}}))(An),Rn=()=>{const e=gt(),l=_e(),i=se(),a=Ee(),p=ft(),{useFeatureGate:u}=Pe(),{isFeatureEnabled:c}=u(W.isDebitCardFeatureEnabled),{tenantEmailDomain:v}=Te(),t=yt(),[n,C]=d.useState(!1);d.useEffect((()=>{n===!1&&a.state?.message==="OnboardingThankyou"&&C(!0)}),[a.state]);const o=x((m=>X(m))),A=o.productSettings.isOtherProductsEnabled,w=A===!0&&!lt(o);d.useEffect((()=>{i(mt(k,!1,!w))}),[]);const k=o.companyId??z.getSignedInUserTenant(v)?.companyId;if(t.loggedInUser==null)throw Error("Can't access onboarding flow without signing in...");const O=xe(c,o),P=we(o),_=x((m=>m.onboardingCustomerViewState.updateStatus.fetchState)),F=o.company?.companyOnboardingInfo.isOnboardingCompleted;if(F!==!0||w)return _==="Completed"&&F===!0&&w&&t?.loggedInUserRoleMap!=null?s.jsxs(ot,{children:[s.jsx(re,{analytics:g,onLoad:m=>{m.trackPageLoaded(ve.Event.onboardingLandingPage,"Onboarding",On(o.productSettings))}}),s.jsx(st,{navigate:l,showUpdatePaymentDetailButton:A,location:a,companyId:k,currentTenant:o,themeState:p,isVisitingFirstTime:n,meetingUrl:e("onboarding_overview")})]}):_==="Completed"&&F===!1&&t?.loggedInUserRoleMap!=null?s.jsxs(ot,{children:[s.jsx(re,{analytics:g,onLoad:m=>{m.trackPageLoaded(ve.Event.onboardingInterimPage)}}),s.jsx(st,{navigate:l,showUpdatePaymentDetailButton:A,location:a,companyId:k,currentTenant:o,themeState:p,isVisitingFirstTime:n,meetingUrl:e("onboarding_overview")})]}):s.jsx(wn,{});{const m={pathnameStackToGoBack:a.state?.pathnameStackToGoBack,message:"activation"};return O?s.jsx(Q,{to:"../../checking",state:m,replace:!0}):P?s.jsx(Q,{to:"../../cards",state:m,replace:!0}):s.jsx(Q,{to:"../../dashboard",state:m,replace:!0})}};function rt(){return typeof Me=="function"?Me():void 0}let pe=0;function Ln(){d.useEffect((()=>{if(!ge.sentryDsn?.trim())return;let e,l=!1,i=0;const a=()=>{e!==void 0&&(clearInterval(e),e=void 0)},p=()=>{const u=rt();return u!==void 0&&(u.flush(),!0)};return pe+=1,p()||(e=setInterval((()=>{i+=1,(l||p()||i>=10)&&a()}),1e3)),()=>{l=!0,a(),pe-=1,queueMicrotask((()=>{pe===0&&(function(){const u=rt();if(u===void 0)return;const c=()=>{if(pe===0)try{u.startBuffering()}catch{}};u.stop().then(c,c)})()}))}}),[])}function pa(){return Ln(),s.jsxs(Pt,{children:[s.jsx(H,{path:"/",element:s.jsx(le,{})}),s.jsx(H,{path:"/billing/edit",element:s.jsx(le,{taxCFOCustomer:!0})}),s.jsx(H,{path:"/thankyou",element:s.jsx(Rn,{})}),s.jsx(H,{path:"/activation",element:s.jsx(Vn,{})}),s.jsx(H,{path:"/address/edit/:addressType/:addressId",element:s.jsx(le,{isOnAddressPage:!0,appContent:s.jsx($e,{})})}),s.jsx(H,{path:"/address/new/:addressType",element:s.jsx(le,{isOnAddressPage:!0,appContent:s.jsx($e,{})})}),s.jsx(H,{path:"*",element:s.jsx(wt,{})})]})}export{pa as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as s}from"./liveblocks-BXyXenK7.js";import{a as d}from"./sentry-D4svnzxK.js";import{h as B,u as G,g as A,i as F,j as l,N as _,l as q,n as O,o as N}from"./core-Bl4MLhFi.js";import{WJ as R,fE as $,V$ as M,m_ as V,S0 as k,WO as Y,WE as z,l_ as J,S1 as S,W4 as H,W5 as K,WG as L,WF as Q}from"./zeni-epic-state-UM7IPCLf.js";import{b8 as U,k as X,a4 as Z,p as tt}from"./index-D_qRPRIi.js";import"./mui-CyP-P4av.js";import{d as b}from"./decodeURIComponentSafe-Buybgpqw.js";import{w as et}from"./withTransactionSidePanel-rDK0lUVX.js";import{f as at,c as nt}from"./routePaths-D20OKXnM.js";import"./recharts-CZKBTuPa.js";import"./analytics-B06OpwA-.js";import"./plaid-C0aCR9wu.js";import"./dnd-CimhpTrK.js";import"./stripe-cKAAJElX.js";import"./lottie-2qUppQdg.js";import"./lexical-BbBoQdpc.js";import"./pdf-BENieWk6.js";import"./utils-Bycom664.js";import"./useAskAiCfoHostNavButtonProps-DYVVwney.js";import"./TransactionDetailScreen-DcuSfVKO.js";import"./useInitialThreadRequest-R2hAErYY.js";import"./expenseAutomationHelper-CkBJgYs_.js";import"./stripSplatSuffix-G7yC23v6.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]="0bbe0158-8213-4f98-9235-1db845ddb36d",a._sentryDebugIdIdentifier="sentry-dbid-0bbe0158-8213-4f98-9235-1db845ddb36d")}catch{}})();const ot=q((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:X,isAccountingClassesEnabled:J(a)}}),(function(a,t){return{onTransactionItemClick:e=>{if(t.openTransactionPanel)return void t.openTransactionPanel(e.id,e.type);const o=`${nt(e,t.tenantEmailDomain)}`,c=tt(t.location.state?.pathnameStackToGoBack,t.location.pathname);t.navigate(o,{state:{pathnameStackToGoBack:c}})},autoCompleteActions:{onAutoCompleteInputChange:e=>{e.trim().length>=2?a(L({searchString:e,searchOrigin:"common"})):e.trim().length===0&&a(Q("common"))},onAutoCompleteEntity:e=>{const o=at(e,t.tenantEmailDomain);a(H()),a(K()),t.resetTrendIsFetchedStates(),t.navigate(o,{replace:!0,state:{pathnameStackToGoBack:t.location.state?.pathnameStackToGoBack}})},onCancelAutoComplete:()=>{const e=Z(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}))}}}}))(U),it=et((function({entityType:a,...t}){const e=B(),o=G(),c=A(),[m,T]=d.useState(!1),[h,D]=d.useState(!1),{tenantEmailDomain:C,entityIdEncoded:W,entityNameEncoded:w}=F(),r=b(W??""),p=b(w??""),u=rt(r,p),x=[r,p].filter((n=>n!=null)),i={name:p,id:r,type:a,zeniId:r,qboId:r},E=l((n=>R(n.customerIncomeState,n.vendorExpenseState,n.trendState,i,"quarter"))),j=l((n=>$(n).company?.companyInfo.firstMonthOfFY??1)),f=l((n=>M(n.trendWithTransactionsState,i,"EntityDetail")));d.useEffect((()=>{m===!1&&u===!0&&(T(!0),o(V(i)))}),[m,u,i]);const g=l((n=>n.trendState.fetchState)),P=f?.selectedPeriod?.timePeriod??E,v=(function(n,y){return n!=null&&y!=null?{startDate:n.startDate,endDate:y?.endDate}:y})(f?.selectedPeriod?.timePeriod,E);return d.useEffect((()=>{m===!0&&h===!1&&g==="Completed"&&(D(!0),P!=null&&o(k(i,"EntityDetail",{timeframe:f?.selectedPeriod?.timeframe??"quarter",timePeriod:P})))}),[m,h,g]),u?s.jsx(ot,{firstMonthOfFY:j,tenantEmailDomain:C,location:c,navigate:e,entity:i,defaultTransactionTimePeriod:v,resetTrendIsFetchedStates:()=>{T(!1),D(!1)},...t}):s.jsx(_,{to:I(x.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 jt({entityType:a}){return s.jsx(O,{children:s.jsx(N,{path:"/:entityIdEncoded/:entityNameEncoded/*",element:s.jsx(it,{entityType:a})})})}export{jt as EntityDetailRoutes,jt as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{a as r}from"./sentry-D4svnzxK.js";import{u as l,h as m,g as p}from"./core-Bl4MLhFi.js";import{hX as f,Um as b,Un as g}from"./zeni-epic-state-UM7IPCLf.js";import{u as _,L as h,z as y}from"./index-D_qRPRIi.js";import"./liveblocks-BXyXenK7.js";import"./recharts-CZKBTuPa.js";import"./mui-CyP-P4av.js";import"./analytics-B06OpwA-.js";import"./plaid-C0aCR9wu.js";import"./dnd-CimhpTrK.js";import"./stripe-cKAAJElX.js";import"./lottie-2qUppQdg.js";import"./lexical-BbBoQdpc.js";import"./pdf-BENieWk6.js";import"./utils-Bycom664.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]="e9b28de4-2a87-44bb-ac80-7c7b5c451240",e._sentryDebugIdIdentifier="sentry-dbid-e9b28de4-2a87-44bb-ac80-7c7b5c451240")}catch{}})();function j(){const e=l(),n=m(),o=p(),{setLoading:i,clearAllLoading:d}=_(),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"),c=sessionStorage.getItem("hubspot_oauth_pending");if(sessionStorage.removeItem("hubspot_oauth_pending"),a!=null&&c!=null){const t=JSON.parse(c);e(f(t.tenant_id,t.connection_id,b("revenue"),g("hubspot"),{authorization_code:a,client_id:t.client_id,client_secret:t.client_secret,redirect_uri:t.redirect_uri}))}d();const u=y.getActiveTenantForUser();n(u?.tenantEmailDomain!=null?`/${u.tenantEmailDomain}/settings/integrations`:"/",{replace:!0})}),[]),null}export{j as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{n as s}from"./liveblocks-BXyXenK7.js";import{j as a}from"./core-Bl4MLhFi.js";import{fE as r}from"./zeni-epic-state-UM7IPCLf.js";import"./sentry-D4svnzxK.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]="8137abfa-99ca-4e9c-806b-445a788f7b64",e._sentryDebugIdIdentifier="sentry-dbid-8137abfa-99ca-4e9c-806b-445a788f7b64")}catch{}})();const b=()=>a((e=>r(e))).tenantId==null?{inboxNotifications:[],isLoading:!1,isFetchingMore:!1,hasFetchedAll:!0,fetchMore:()=>null}:(()=>{const{inboxNotifications:e,isLoading:o,isFetchingMore:i,hasFetchedAll:t,fetchMore:n}=s();return{inboxNotifications:e,isLoading:o,isFetchingMore:i,hasFetchedAll:t,fetchMore:n}})();export{b as u};
|
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
import{j as a}from"./liveblocks-BXyXenK7.js";import{i as S,l as g,h as C,g as y,u as ee,t as ae,j as E,N as te,n as ne,o as p}from"./core-Bl4MLhFi.js";import{Uf as k,Ug as j,Uh as T,Jj as D,J5 as U,Ui as B,Uj as oe,Uk as ie,J9 as se,gh as $,Jg as le,Jd as re}from"./zeni-epic-state-UM7IPCLf.js";import{a1 as x,H as r,a2 as de,k as v,Z as G,a3 as ce,a4 as me,a5 as pe,p as J,N as ue,d as he,a6 as ge,E as xe,c as fe,g as be,a7 as we,a8 as Se,$ as ye,a9 as ke,aa as je,ab as ve,ac as $e}from"./index-D_qRPRIi.js";import{n as m}from"./mui-CyP-P4av.js";import f from"./NotFoundScreen-BHAnIkPW.js";import{a as I}from"./sentry-D4svnzxK.js";import"./recharts-CZKBTuPa.js";import"./analytics-B06OpwA-.js";import"./plaid-C0aCR9wu.js";import"./dnd-CimhpTrK.js";import"./stripe-cKAAJElX.js";import"./lottie-2qUppQdg.js";import"./lexical-BbBoQdpc.js";import"./pdf-BENieWk6.js";import"./utils-Bycom664.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]="c4e5d84f-eb07-4223-95c8-4b1e91ce57be",e._sentryDebugIdIdentifier="sentry-dbid-c4e5d84f-eb07-4223-95c8-4b1e91ce57be")}catch{}})();const Ie=m.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
|
-
box-shadow: ${e=>`0px 2px ${r.sp1} ${e.theme.colors.dropShadowNormal}`};
|
|
10
|
-
`,Ce=g((function(e){const t=k(e),n=j(e),{companyName:o}=t;return{companyName:o,isDisabled:t.fetchState!=="Completed"?"disabled":void 0,magicLinkBankAccountDetails:n,magicLinkViewState:t}}),(function(e,t){const{vendorId:n,billId:o}=t;return{onFetchBankName:i=>{e(U(i))},onSaveHandler:i=>{v.trackBillPayMagicLinkSubmitBankAccountDetails(o),e(D(i,"standard",n,o))},onACHDetailsUpdated:i=>{const{bankAccountSection:l}=i;e(T({data:l}))}}}))(de);function F(){const e=x(),{vendorId:t,billId:n}=S();return t==null||n==null?a.jsx(f,{}):a.jsx(a.Fragment,{children:a.jsx(Ie,{windowSize:e,children:a.jsx(Ce,{vendorId:t,billId:n})})})}const De=m.div`
|
|
11
|
-
display: flex;
|
|
12
|
-
height: 100vh;
|
|
13
|
-
width: 100%;
|
|
14
|
-
flex: 1 1 auto;
|
|
15
|
-
flex-direction: column;
|
|
16
|
-
align-items: center;
|
|
17
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
18
|
-
box-shadow: ${e=>`0px 2px ${r.sp1} ${e.theme.colors.dropShadowNormal}`};
|
|
19
|
-
`,Be=g((function(e,t){const{isSubPage:n}=t;return{addressToEdit:B(e),googleAPIKey:G.googleMapsAPIKey,isSubPage:n}}),(function(e,t){const{navigate:n,location:o}=t,i=()=>{const l=me(o.state?.pathnameStackToGoBack),s=l.poppedPathname??Pe();n(s,{state:{pathnameStackToGoBack:l.newStack}})};return{onSubmitHandler:l=>{const s=ze(l);e(oe({addressToCreate:s})),i()},onCancel:()=>{i()}}}))(ce);function Ae({isSubPage:e}){const t=C(),n=y(),o=x();return a.jsx(a.Fragment,{children:a.jsx(De,{windowSize:o,children:a.jsx(Be,{location:n,navigate:t,isSubPage:e===!0,googleAPIKey:G.googleMapsAPIKey})})})}const Pe=(e=2)=>{let t="../";for(let n=0;n<e;n++)t=`${t}../`;return t},ze=e=>({street:[e.street.addressString,e.suite,e.secondaryInfo],city:e.city,state:e.state,country:e.country.selectedOption??"",countryCode:e.countryCode,postalCode:e.postalCode,latitude:e.street.addressValue?.locationLat,longitude:e.street.addressValue?.locationLng}),Ne=m.div`
|
|
20
|
-
display: flex;
|
|
21
|
-
height: 100%;
|
|
22
|
-
width: 100%;
|
|
23
|
-
flex: 1 1 auto;
|
|
24
|
-
flex-direction: column;
|
|
25
|
-
align-items: center;
|
|
26
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
27
|
-
box-shadow: ${e=>`0px 2px ${r.sp1} ${e.theme.colors.dropShadowNormal}`};
|
|
28
|
-
`,Le=g((function(e){const t=k(e),n=j(e),o=B(e),{companyName:i}=t;return{companyName:i,isDisabled:t.fetchState!=="Completed"?"disabled":void 0,magicLinkBankAccountDetails:n,mailingAddressDetails:o,magicLinkViewState:t}}),(function(e,t){const{navigate:n,location:o,vendorId:i,billId:l}=t;return{onFetchBankName:s=>{e(U(s))},onSaveHandler:s=>{v.trackBillPayMagicLinkSubmitBankAccountDetails(l),e(D(s,"us-domestic",i,l))},onWireDetailsUpdated:s=>{const{bankAccountSection:d}=s;e(T({data:d}))},onAddressClick:()=>{const s=o.pathname.replace("us-domestic","address"),d=J(o.state?.pathnameStackToGoBack,o.pathname);n(s,{state:{pathnameStackToGoBack:d}})}}}))(pe);function Ee(){const e=C(),t=y(),n=x(),{vendorId:o,billId:i}=S();return o==null||i==null?a.jsx(f,{}):a.jsx(a.Fragment,{children:a.jsx(Ne,{windowSize:n,children:a.jsx(Le,{location:t,navigate:e,vendorId:o,billId:i})})})}const Fe=m.div`
|
|
29
|
-
display: flex;
|
|
30
|
-
height: 100%;
|
|
31
|
-
width: 100%;
|
|
32
|
-
flex: 1 1 auto;
|
|
33
|
-
flex-direction: column;
|
|
34
|
-
align-items: center;
|
|
35
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
36
|
-
box-shadow: ${e=>`0px 2px ${r.sp1} ${e.theme.colors.dropShadowNormal}`};
|
|
37
|
-
`,Te=g((function(e){const t=k(e),n=j(e),o=B(e),{companyName:i}=t;return{companyName:i,isDisabled:t.fetchState!=="Completed"?"disabled":void 0,magicLinkBankAccountDetails:n,mailingAddressDetails:o,magicLinkViewState:t}}),(function(e,t){const{navigate:n,location:o,vendorId:i,billId:l}=t;return{onFetchBankNameBySwift:s=>{e(se(s))},onSaveHandler:s=>{v.trackBillPayMagicLinkSubmitBankAccountDetails(l),e(D(s,"international",i,l,t.isLocalCurrencyEnabled))},onBankDetailsUpdated:s=>{const{internationalWireSwiftAccountSection:d}=s;e(ie({data:d}))},onAddressClick:()=>{const s=o.pathname.replace("international","address"),d=J(o.state?.pathnameStackToGoBack,o.pathname);n(s,{state:{pathnameStackToGoBack:d}})}}}))(ge);function Ue(){const e=C(),t=y(),n=x(),{vendorId:o,billId:i}=S(),{useFeatureGate:l}=ue(),{isFeatureEnabled:s}=l(he.isBillPayLocalCurrencyFeatureEnabled);return o==null||i==null?a.jsx(f,{}):a.jsx(Fe,{windowSize:n,children:a.jsx(Te,{location:t,navigate:e,vendorId:o,billId:i,isLocalCurrencyEnabled:s})})}const Ge={containerWidth:new ve(100,58)},Je=m(ke)`
|
|
38
|
-
width: ${r.sp4};
|
|
39
|
-
height: ${r.sp4};
|
|
40
|
-
margin-bottom: ${r.sp3};
|
|
41
|
-
margin-top: ${r.sp3};
|
|
42
|
-
margin-left: ${r.sp8};
|
|
43
|
-
cursor: pointer;
|
|
44
|
-
position: absolute;
|
|
45
|
-
color: ${e=>e.theme.colors.brandColorJade};
|
|
46
|
-
`,Me=m.div`
|
|
47
|
-
display: flex;
|
|
48
|
-
height: 100vh;
|
|
49
|
-
flex-direction: ${e=>e.windowSize==="small"?"column":"row"};
|
|
50
|
-
width: 100vw;
|
|
51
|
-
overflow-y: scroll;
|
|
52
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
53
|
-
`,He=m.div`
|
|
54
|
-
display: flex;
|
|
55
|
-
flex-direction: ${e=>e.windowSize==="small"?"column":"row"};
|
|
56
|
-
flex-direction: column;
|
|
57
|
-
width: ${e=>`${Ge.containerWidth.value(e.windowSize)}%`};
|
|
58
|
-
${e=>e.windowSize!=="small"?"overflow: auto;":""}
|
|
59
|
-
box-shadow: ${e=>`0px 2px ${r.sp1} ${e.theme.colors.dropShadowNormal}`};
|
|
60
|
-
padding-top: ${e=>e.windowSize!=="small"?r.sp2:"0px"};
|
|
61
|
-
`,Ve=m.div`
|
|
62
|
-
display: flex;
|
|
63
|
-
flex-direction: column;
|
|
64
|
-
align-items: center;
|
|
65
|
-
justify-content: center;
|
|
66
|
-
padding: ${e=>e.windowSize==="small"?r.sp3:`62px ${r.sp6} ${r.sp9} ${r.sp8}`};
|
|
67
|
-
height: ${e=>e.windowSize==="small"?"490px":"auto"};
|
|
68
|
-
overflow: ${e=>e.windowSize==="small"?"unset":"hidden"};
|
|
69
|
-
width: ${e=>e.windowSize=="small"?"auto":"42%"};
|
|
70
|
-
background-color: ${e=>e.windowSize==="small"?e.theme.colors.grey4:e.theme.colors.background};
|
|
71
|
-
margin-top: ${e=>e.windowSize==="small"?e.isAddressPage?"0px":"186px":"unset"};
|
|
72
|
-
`,_e=g((function(e,t){return{file:t.file,type:t.type}}))(je);function h({appContent:e}){const t=ee(),n=y(),{tenantEmailDomain:o,vendorId:i,billId:l}=S(),[s]=ae(),d=s.get("token"),M=n.pathname.includes("address"),b=x(),H=xe(),A=fe(),w=be(),V=()=>{H.toggle()},_=E((u=>k(u))),K=E((u=>j(u))),{authParams:W,fetchState:c,billAttachment:q,billFetchState:P,companyName:O,currencySymbol:Q,amount:Z}=_,{tenantId:z,userId:N,sessionId:L}=W,{fetchState:R,internationalBankAccountCreateStatus:X}=K;return I.useEffect((()=>{$()}),[]),I.useEffect((()=>{w&&c==="Not-Started"&&i!=null&&o!=null&&d!=null&&t(le(i,o,d))}),[w,c,i,o,d,t]),I.useEffect((()=>{w&&c==="Completed"&&($(N,L,z),l!=null&&t(re(l)))}),[c,w,N,L,z,l,t]),c==="Error"?a.jsx(f,{}):R==="Completed"||X.fetchState==="Completed"?($(),a.jsx(te,{to:"../../../../../../../bank/account/save/success",replace:!0,relative:"path"})):c==="In-Progress"?a.jsx(we,{fetchState:c,style:{height:"100vh",backgroundColor:A.colors.grey5,boxShadow:`0px 2px ${r.sp1} ${A.colors.dropShadowNormal}`}}):a.jsxs(a.Fragment,{children:[c==="Completed"&&P==="Completed"&&a.jsx(Se,{analytics:v,onLoad:u=>(Y=>Y.trackBillPayMagicLinkPageLoad(o??"",i??"",O,l??"",Ke(n.pathname),Q,Z))(u)}),a.jsxs(Me,{windowSize:b,children:[b!=="small"?a.jsx(Je,{onClick:V}):null,a.jsx(Ve,{windowSize:b,isAddressPage:M,children:P==="In-Progress"?a.jsx(ye,{size:"ExtraLarge",start:!0}):a.jsx(_e,{file:q,type:"bill"})}),a.jsx(He,{windowSize:b,children:e})]})]})}const Ke=e=>`${e.split("/").at(-2)}_${e.split("/").at(-1)}`;function We(){return a.jsx($e,{})}function da(){return a.jsxs(ne,{children:[a.jsx(p,{path:"bank/account/save/success",element:a.jsx(We,{})}),a.jsx(p,{path:":tenantEmailDomain/vendor/:vendorId/bill/:billId/ach/standard",element:a.jsx(h,{appContent:a.jsx(F,{})})}),a.jsx(p,{path:":tenantEmailDomain/vendor/:vendorId/bill/:billId/ach/same-day",element:a.jsx(h,{appContent:a.jsx(F,{})})}),a.jsx(p,{path:":tenantEmailDomain/vendor/:vendorId/bill/:billId/wire/address",element:a.jsx(h,{appContent:a.jsx(Ae,{isSubPage:!0})})}),a.jsx(p,{path:":tenantEmailDomain/vendor/:vendorId/bill/:billId/wire/us-domestic",element:a.jsx(h,{appContent:a.jsx(Ee,{})})}),a.jsx(p,{path:":tenantEmailDomain/vendor/:vendorId/bill/:billId/wire/international",element:a.jsx(h,{appContent:a.jsx(Ue,{})})}),a.jsx(p,{path:"*",element:a.jsx(f,{})})]})}export{da as default};
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import{j as u}from"./liveblocks-BXyXenK7.js";import{a as g}from"./sentry-D4svnzxK.js";import{u as O,g as _,h as w,t as M,j as l,N as T}from"./core-Bl4MLhFi.js";import{z as r,c as P,G as V,Q as A,k as N,S as $,_ as G,$ as K,X as Q}from"./index-D_qRPRIi.js";import{fE as R,TK as W,Ub as X,U2 as q,gh as B,gj as H,U7 as J,gT as Y,di as Z,Uc as ee,Ud as te}from"./zeni-epic-state-UM7IPCLf.js";import{n as ne}from"./mui-CyP-P4av.js";import{u as ae}from"./useDeviceId-4WJY9vuN.js";import{f as se}from"./analyticsHelper-xKlm2_zz.js";import{t as ie}from"./getLocaleForTenant-NAFAfy2t.js";import"./recharts-CZKBTuPa.js";import"./analytics-B06OpwA-.js";import"./plaid-C0aCR9wu.js";import"./dnd-CimhpTrK.js";import"./stripe-cKAAJElX.js";import"./lottie-2qUppQdg.js";import"./lexical-BbBoQdpc.js";import"./pdf-BENieWk6.js";import"./utils-Bycom664.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},s=new t.Error().stack;s&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[s]="858ab34d-afec-438c-9a8d-ab7ee682a94f",t._sentryDebugIdIdentifier="sentry-dbid-858ab34d-afec-438c-9a8d-ab7ee682a94f")}catch{}})();const U=(t,s)=>t!=null&&t.length>0&&s==="magic_links";function Ue(){const t=O(),s=_(),m=w(),[k]=M(),n=k.get("token"),p=k.get("stytch_token_type"),f=r.getMagicLinkCodeVerifier(),i=ae(),{otpChallenge:d,twoFAPhoneNumber:x,magicLinkEmail:c,verifyDeviceFetchState:z,resendVerifyDeviceOTPFetchState:C}=l((e=>e.tenantState)),S=l((e=>e.tenantState.fetchState)),y=l((e=>e.tenantState.activeTenantFetchState.fetchState)),h=l((e=>e.tenantState.signInState)),I=l((e=>e.tenantState.magicLinkSignInFetchState.fetchState)),a=l((e=>e.tenantState.loggedInUser)),o=l((e=>R(e))),b=l((e=>W(e))),D=r.getSignedInUser(),v=P().mode;g.useEffect((()=>{a?.zeniSessionId==null&&n!=null&&U(n,p)&&i!=null&&f!=null&&(r.saveMagicLinkTriggered(n),t(X(n,i,f)))}),[n,p,t,i,f,a?.zeniSessionId]),g.useEffect((()=>{h!=="In-Progress"||S!=="Completed"&&y!=="Completed"||a?.zeniSessionId==null||o==null||(n!=null&&r.saveLastUsedMagicLinkToken(n),r.saveSignedInUserWithSession(a,a.zeniSessionId),r.saveSignedInUserTenants(q(b.tenantsInOrder),a.zeniSessionId),B(a.userId,a.zeniSessionId,o.tenantId),t(H(o.tenantId)),r.saveActiveTenantDomainForUser(o.tenantEmailDomain),t(J("Completed")),V.updateAppLocaleID(ie(o)),se(a,o,v,void 0,b.tenantsInOrder),Y().then((()=>{const e=Q();e!=null&&A(e)})),setTimeout((()=>{N.trackLogin($.Event.loginSuccess,"email",Z(o.productSettings))}),2e3))}),[h,S,y,a,o,b,v,s.state,t]);const E=g.useCallback((()=>{m("/signin/auth")}),[m]),j=g.useCallback((()=>{i!=null&&d!=null&&c!=null&&t(ee(i,c,d))}),[i,d,t,c]),F=g.useCallback((e=>{i!=null&&n!=null&&c!=null&&d!=null&&t(te(e,i,c,d))}),[i,n,t,c,d]);if(I==="Completed"&&d!=null)return u.jsx(G,{phoneNumber:x,verifyOtpFetchState:z.fetchState,resendVerifyDeviceOTPFetchState:C,onResendOtp:j,onVerifyOtp:F,onCancelVerifyDevice:E});if(h==="In-Progress"&&S==="Completed"&&a?.zeniSessionId!=null&&o!=null||D!=null){const e=s.state?.origin??"/";return u.jsx(T,{to:e,state:{...s.state,origin:""}})}if(!U(n,p)||f==null||I==="Error"){const e=s.state?.origin??"/",L=n!=null&&r.getLastUsedMagicLinkToken()===n;return u.jsx(T,{to:e,state:{...s.state,origin:"",magicLinkAlreadyUsed:L,magicLinkExpired:!L&&(r.isMagicLinkTriggered(n??"")||I==="Error"&&a?.zeniSessionId==null)}})}return u.jsx(oe,{"data-testid":"smooth-loader",children:u.jsx(K,{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{Ue as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as D}from"./liveblocks-BXyXenK7.js";import{a as m}from"./sentry-D4svnzxK.js";import{u as te,j as t,i as $e,g as Ge,h as Me,q as F}from"./core-Bl4MLhFi.js";import{fE as ne,TL as xe,TM as se,g8 as Ne,fD as Ve,TV as Pe,TO as Re,TP as Le,p_ as Oe,gl as je,TS as h,TX as Ue,TY as K,gm as Ze,TZ as ze,E0 as Ye,h0 as qe,cV as He,T_ as We,g7 as Xe,gn as Je}from"./zeni-epic-state-UM7IPCLf.js";import{w as Ke,i as Qe,E as ea,N as aa,e as ta,g as na,u as sa,d as c,h as oa,q as ia,z as ra,f as da,l as ca,V as la,s as ua,n as ma,o as Q,L as fa,C as ba,D as ha,p as S,k as ee,x as pa,W as ae,A as ga,B as Sa}from"./index-D_qRPRIi.js";import{D as Ea}from"./mui-CyP-P4av.js";import{u as Ta}from"./InboxNotificationsProvider-CMdsyY0A.js";import{u as ka}from"./useTaskManagerAccess-Rxke8A9H.js";(function(){try{var l=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},i=new l.Error().stack;i&&(l._sentryDebugIds=l._sentryDebugIds||{},l._sentryDebugIds[i]="35e1e647-478a-40bb-8ed2-1cbbb78f84d0",l._sentryDebugIdIdentifier="sentry-dbid-35e1e647-478a-40bb-8ed2-1cbbb78f84d0")}catch{}})();const Ca=Ke((({isAppContentDrawerOpen:l,handleDrawerToggle:i})=>{const{tenantEmailDomain:s}=$e(),a=Ge(),E=ea(),n=Me(),B=Ne(),r=te(),{useFeatureGate:d}=aa(),p=ta(),{isTaskManagerAccessEnabled:T}=ka(p),o=t((e=>ne(e))),oe=o.masterTOSInfo?.isMasterTOSAccepted??!1,$=t((e=>Ve(e))),{status:ie}=t(Pe),G=$.uiState.currentChatSessionId,k=na(),{setLoading:re}=sa(),[w,M]=m.useState(void 0),A=F("/:tenantEmailDomain/dashboard")!==null,x=F("/:tenantEmailDomain/reports")!==null,f=F("/:tenantEmailDomain/onboarding/*")!==null,de=!!o.company?.companyZeniAccountInfo?.isZeniAccountEnabled,{isFeatureEnabled:ce}=d(c.isChargeCardFeatureEnabled),{isFeatureEnabled:N}=d(c.isDebitCardFeatureEnabled),le=oa(o,ce,N),{isFeatureEnabled:ue}=d(c.isSettingsFeatureEnabled),V=t((e=>Re(e))),{isFeatureEnabled:C}=d(c.isReferralFeatureEnabled),v=t((e=>Le(e)));m.useEffect((()=>{k&&C&&!f&&v.fetchState==="Not-Started"&&r(Oe(!0))}),[k,C,v.fetchState,f]);const _=t((e=>e.tenantState)),me=t((e=>_.fetchState==="Completed"?je(e):[])),g=t((e=>e.expenseAutomationViewState.selectedPeriodByTenantId)),{isFeatureEnabled:fe}=d(c.isApAgingFeatureEnabled),{isFeatureEnabled:be}=d(c.isArAgingFeatureEnabled),P=ia(),{isFeatureEnabled:he}=d(c.isDashboardSidebarHalloweenAnimationEnabled),{isFeatureEnabled:pe}=d(c.isDashboardSidebarThanksGivingAnimationEnabled),{isFeatureEnabled:ge}=d(c.isDashboardSidebarChristmasAnimationEnabled),{isFeatureEnabled:Se}=d(c.isDashboardSidebarNewYearAnimationEnabled),Ee=o.companyTreasuryInfo?.info?.businessVerificationStatus?.code==="verified",Te=t((e=>h(e).totalUnreadCount)),ke=t((e=>h(e).reducedFetchCountState)),R=t((e=>h(e).notificationDetailsByTab.tasks.uiState.unreadCount)),L=t((e=>h(e).notificationDetailsByTab.comments.uiState.unreadCount)),O=t((e=>h(e).notificationDetailsByTab.tasks.fetchCountState)),I=t((e=>h(e).notificationDetailsByTab.comments.fetchCountState)),{inboxNotifications:j,isLoading:U,isFetchingMore:Z,hasFetchedAll:z,fetchMore:Ce}=Ta();m.useEffect((()=>{const e=setTimeout((()=>Ce?.()),0);return()=>clearTimeout(e)})),m.useEffect((()=>{if(U===!1&&Z===!1&&z===!0)if(o?.companyId!=null&&j!=null){const e=`dashboard_${o.companyId}`;M(j.filter((u=>u.roomId===e&&u.readAt==null)).length)}else M(0)}),[U,Z,z]),m.useEffect((()=>{k&&T&&!f&&O.fetchState==="Not-Started"&&B.tenantId!=null&&r(Ue("task_manager","dashboard"))}),[k,T,f,O.fetchState,B.tenantId,r]),m.useEffect((()=>{f||I.fetchState!=="Not-Started"||r(K({fetchCountState:{fetchState:"In-Progress",error:void 0}},"comments"))}),[f,I.fetchState,r]),m.useEffect((()=>{w!=null&&I.fetchState==="In-Progress"&&(r(K({fetchCountState:{fetchState:"Completed",error:void 0}},"comments")),r(se({unreadCount:w},"comments")))}),[w,I.fetchState]);const Ie={fetchStatus:ke,count:Te},Y=s!=null?ra.getSignedInUserTenant(s):null,q=t((e=>Y?.tenantId!=null?Ze(e,Y.tenantId):void 0)),b=[];fe===!1&&b.push("accounts_payable_aging"),be===!1&&b.push("accounts_receivable_aging"),b.push("zeni_accounts_promo_card","treasury_promo_card"),C===!1&&b.push("rewards_card"),P===!1&&b.push("expense_automation_card");const H=t((e=>ze(e,b).fetchState)),W=t((e=>Ye(e).fetchState)),ye=A&&(H==="Completed"||H==="Error")||x&&(W==="Completed"||W==="Error")||!A&&!x?void 0:"disabled",we=m.useMemo((()=>qe(o.userRole)),[o.userRole]),Ae=He(we),ve=o?.rewardsLastViewedTime==null,_e=p?.userEmail!=null&&V.fetchState==="Completed"&&We(V.notificationSettings,p.userEmail,N,o,T),X=da(),Fe=X&&ca(a);return D.jsx(Ea,{container:window.document.body,variant:"temporary",open:l,onClose:()=>i(!1),PaperProps:{sx:{width:240,zIndex:8,borderRight:"none",backgroundImage:"none"}},ModalProps:{keepMounted:!0},children:D.jsx(la,{signedInUser:p,currentTenantId:_.currentTenantId??"",tenants:_.fetchState==="Completed"?me:q!=null?[q]:[],currentTenant:o,isTenantDropdownDisabled:ye,isSettings:Q(a),isInvoicing:ma(a)&&ie==="completed",isSettingsFeatureEnabled:ue,isVendorsTabVisible:Ae,isZeniAccountEnabled:de,isChargeCardEnabled:le,isTreasuryEnabled:Ee,isNotificationsTabVisible:_e,notificationCountDetails:Ie,isExpenseAutomationEnabledForUser:P,selectedMenu:ua(a),rewardsConfiguration:{isRewardsTabVisible:C,isRewardsAnimated:ve,rewardsPlan:v.rewardsPlan},isAiCfoAccessEnabled:X,onNotificationIconClick:()=>{i(!1);let e=R===0&&L>0?"notifications/comments":"notifications/tasks";Q(a)&&(e=R===0&&L>0?"../../notifications/comments":"../../notifications/tasks");const u=S(a.state?.pathnameStackToGoBack,a.pathname);n(e,{state:{pathnameStackToGoBack:u}})},handleCockpitClick:()=>{window.open("/cockpit")},handleLogOutClick:()=>{i(!1);const e=S(a.state?.pathnameStackToGoBack,a.pathname);n("/signout",{replace:!0,state:{pathnameStackToGoBack:e,message:"logout"}})},handleMenuChange:e=>{if(i(!1),s==null)return;if(e.type==="invoicing")return void n(`../${s}/invoicing/overview`,{state:{pathnameStackToGoBack:S(a.state?.pathnameStackToGoBack,a.pathname),referrer:"Sidebar"}});if(e.type==="ai_cfo"){if(ee.trackAICFOChatScreenStateChanged("viewed","left_menu",G??null,null),!oe)return void pa({location:a,navigate:n,mergeState:{referrer:"Sidebar"}});const y=S(a.state?.pathnameStackToGoBack,a.pathname);return void n(`/${s}/ai-cfo/explore`,{state:{pathnameStackToGoBack:y,referrer:"Sidebar"}})}const u=S(a.state?.pathnameStackToGoBack,a.pathname),J=e.type,De=ae(J)&&J!=="command_center";if(ae(e.type)&&g[o.tenantId]!=null&&ee.trackMonthEndCloseClicked(g[o.tenantId].month,g[o.tenantId].year,"Sidebar"),De&&g[o.tenantId]!=null){const y=g[o.tenantId];return void n(`/${s}/month_end_close_checks/review/${e.type}/${y.month}-${y.year}`,{state:{pathnameStackToGoBack:u,referrer:"Sidebar"}})}const Be=ga(e.type);Sa(e.type)?(G!=null&&r(Je()),n(`/${s}/ai-cfo/${e.type}`,{state:{pathnameStackToGoBack:u.slice(0,-1),referrer:"Sidebar"}})):n(`/${s}/${Be}`,{state:{pathnameStackToGoBack:u,referrer:"Sidebar"}})},handleMyProfileClick:()=>{i(!1),n(`/${s}/settings/my_profile`)},handleReferralsClick:()=>{i(!1),n(`/${s}/rewards`)},handleBackClick:()=>{n(`/${s}/dashboard`)},handleTenantSelect:e=>{re(fa.TENANT_SWITCHING),i(!1),ba({dispatch:r,navigate:n,pathToNavigate:ha(e.tenantEmailDomain,a),selectedTenant:e,signedInUser:p})},onZeniLogoClick:()=>{E.toggle()},isAiCfo:Fe,aiCfoView:$,isOnDashboard:A,updateCurrentChatSessionId:e=>{r(Xe({sessionId:e,agentId:"controller"})),n(`/${s}/ai-cfo/${e}`,{state:{...a.state}})},halloweenAnimationEnabled:he,isTaskManagerAccessEnabled:T,thanksGivingAnimationEnabled:pe,christmasAnimationEnabled:ge,newYearAnimationEnabled:Se})})})),Ba=l=>{const i=te(),s=t((E=>ne(E))),a={events:s.userRoleId!=null?[`private-encrypted-${s.userRoleId}.dashboard-user-notification`]:[],eventCallback:(E,n)=>{Qe(n)&&xe(n.mode)==="dashboard"&&i(se({unreadCount:n.data.unread},"tasks"))}};return D.jsx(Ca,{...l,...a})};export{Ba as M};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as e}from"./liveblocks-BXyXenK7.js";import{h as r,l as i}from"./core-Bl4MLhFi.js";import{am as n}from"./index-D_qRPRIi.js";import"./mui-CyP-P4av.js";import"./sentry-D4svnzxK.js";import"./zeni-epic-state-UM7IPCLf.js";import"./recharts-CZKBTuPa.js";import"./analytics-B06OpwA-.js";import"./plaid-C0aCR9wu.js";import"./dnd-CimhpTrK.js";import"./stripe-cKAAJElX.js";import"./lottie-2qUppQdg.js";import"./lexical-BbBoQdpc.js";import"./pdf-BENieWk6.js";import"./utils-Bycom664.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{n as mt,b as lt,o as ft,j as N}from"./liveblocks-BXyXenK7.js";import ut from"./NotFoundScreen-BHAnIkPW.js";import{a as k}from"./sentry-D4svnzxK.js";import{h as ht,g as pt,i as kt,u as gt,j as S,l as St,n as bt,o as Q}from"./core-Bl4MLhFi.js";import{cA as Tt,TO as Y,fE as H,h0 as It,TS as b,a0M as K,TY as m,TM as E,Ai as $,F_ as Ct,a0N as At,TL as Et,T_ as yt,An as _t,a0O as F,br as j,gg as x,Ar as X,a0P as Nt,cM as Bt,cF as wt}from"./zeni-epic-state-UM7IPCLf.js";import{aq as xt,e as vt,N as Mt,d as Dt,as as Pt,dM as Rt,p as B,dN as Gt,w as Ut,dO as Ft,i as jt,a4 as $t}from"./index-D_qRPRIi.js";import"./mui-CyP-P4av.js";import{u as Vt}from"./useAskAiCfoHostNavButtonProps-DYVVwney.js";import{u as Ot}from"./useTaskManagerAccess-Rxke8A9H.js";import"./recharts-CZKBTuPa.js";import"./analytics-B06OpwA-.js";import"./plaid-C0aCR9wu.js";import"./dnd-CimhpTrK.js";import"./stripe-cKAAJElX.js";import"./lottie-2qUppQdg.js";import"./lexical-BbBoQdpc.js";import"./pdf-BENieWk6.js";import"./utils-Bycom664.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},l=new t.Error().stack;l&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[l]="a0a71995-14fb-42cd-8ab5-49c9c8294ce0",t._sentryDebugIdIdentifier="sentry-dbid-a0a71995-14fb-42cd-8ab5-49c9c8294ce0")}catch{}})();const qt=(t,l)=>new Promise(((n,h)=>{const g=t.map((c=>new Promise((o=>{l(c),o()}))));Promise.all(g).then((()=>{setTimeout((()=>{n()}),2e3)})).catch((c=>{h(c)}))})),Lt=St((function(t,l){const n=Y(t),{signedInUser:h,isDebitCardFeatureEnabled:g,isTaskManagerAccessEnabled:c}=l,o=b(t),f=H(t),{currentTab:T}=o;return{notificationView:o,isNotificationSettingsVisible:h.userEmail!=null&&yt(n.notificationSettings,h.userEmail,g,f,c),isDisabled:o.notificationDetailsByTab[T].fetchState==="In-Progress"?"disabled":void 0}}),(function(t,l){const{location:n,tenantEmailDomain:h,loggedInUserRoleMap:g,externalNotificationsUnreadCount:c,allUnreadCommentsNotificationIds:o,navigate:f,markInboxNotificationAsRead:T,fetchMoreCommentsNotifications:M}=l;return{onNotificationClick:(e,s,d,r)=>{if(r==="task_deleted"){const i=`/${h}/tasks`,I=B(n.state?.pathnameStackToGoBack,n.pathname);f(i,{state:{pathnameStackToGoBack:I,message:"triggerBackClick"}})}else{const i=`/${h}/tasks/${s}`,I=B(n.state?.pathnameStackToGoBack,n.pathname);f(i,{state:{pathnameStackToGoBack:I,message:"triggerBackClick"}})}d==="unread"&&t(X("task_manager","read",[e],!1))},onCommentNotificationClick:(e,s,d)=>{const r=s.toString().split(`/${h}/`);if(r[1]!=null){d==="unread"&&(T(e),t(F([e],j())));let i=`/${h}/${r[1]}`;const I=B(n.state?.pathnameStackToGoBack,n.pathname);r[1].startsWith("reimbursement")&&!Bt(g)&&(i="not-found"),r[1].startsWith("bill")&&!wt(g)&&(i="not-found"),f(i,{state:{pathnameStackToGoBack:I,message:"triggerBackClick"}})}},onUpdateNotificationViewUIState:(e,s)=>{t(E(e,s))},onUpdateNotificationTabState:(e,s)=>{t(m(e,s))},onUpdateNotificationViewCurrentTabAndSubTab:(e,s)=>{t(K(e,s));const d=`../${e}`,r=B(n.state?.pathnameStackToGoBack,n.pathname);f(d,{state:{pathnameStackToGoBack:r}})},onUpdateNotificationViewSubTab:e=>{t(Nt(e))},onFetchMoreNotifications:(e,s)=>{if(e==="tasks"){const d=[];s==="all"?d.push("read","unread"):s!=="mentions"&&d.push(s),t($("task_manager","dashboard",d))}else M?.()},onUpdateNotificationStatus:(e,s,d,r)=>{e==="tasks"?t(X("task_manager",d,r)):(t(m({markAsReadState:{fetchState:"In-Progress",error:void 0}},"comments")),Promise.all(r.map((i=>{d==="read"&&(T(i),t(F([i],j())))}))).then((()=>{t(m({markAsReadState:{fetchState:"Completed",error:void 0},selectedNotificationIds:[]},"comments")),t(E({unreadCount:c-r.length>0?c-r.length:0},"comments")),t(x({messageSection:"notification_mark_as_read",messageText:"success",type:"success",showStatusIcon:!0}))}),(i=>{t(m({markAsReadState:{fetchState:"Error",error:i}},"comments")),t(x({messageSection:"notification_mark_as_read",messageText:"failed",type:"error",showStatusIcon:!0}))})).catch((i=>{t(m({markAsReadState:{fetchState:"Error",error:i}},"comments")),t(x({messageSection:"notification_mark_as_read",messageText:"failed",type:"error",showStatusIcon:!0}))})))},onMarkAllNotificationsAsRead:e=>{e==="tasks"?t(_t("task_manager","read")):(t(m({markAsAllReadState:{fetchState:"In-Progress",error:void 0}},"comments")),qt(o,T).then((()=>{t(F(o,j())),t(m({markAsAllReadState:{fetchState:"Completed",error:void 0}},"comments")),t(E({unreadCount:0},"comments")),t(x({messageSection:"notification_mark_as_read",messageText:"success",type:"success",showStatusIcon:!0}))})).catch((s=>{t(m({markAsAllReadState:{fetchState:"Error",error:s}},"comments")),t(x({messageSection:"notification_mark_as_read",messageText:"failed",type:"error",showStatusIcon:!0}))})))},onBackClick:()=>{const e=$t(n.state?.pathnameStackToGoBack),s=e.poppedPathname??"../../dashboard";f(s,{state:{pathnameStackToGoBack:e.newStack}})},onSettingsClick:()=>{const e=B(n.state?.pathnameStackToGoBack,n.pathname);f("../../settings/notifications",{state:{pathnameStackToGoBack:e}})}}}))(Ut(Ft)),Wt=()=>{const t=ht(),l=pt(),{tenantEmailDomain:n,selectedTab:h}=kt(),{areTenantIdsInSync:g}=xt(),c=Tt(h??""),o=gt(),f=vt(),[T,M]=k.useState(!1),e=S((a=>Y(a))),s=S((a=>H(a))),{useFeatureGate:d}=Mt(),{isFeatureEnabled:r}=d(Dt.isDebitCardFeatureEnabled),{isAiCfoAccessEnabled:i,onAskAiCfoClick:I}=Vt({mobileExploreReferrer:"Notifications"});Pt({isDataReady:!0});const Z=It(s.userRole);if(s==null||n==null||s.companyId==null)throw Error("Can't access notifications page without current tenant...");if(f==null)throw Error("Can't access notifications page without signed in...");const V=S((a=>b(a).notificationDetailsByTab.tasks.fetchState)),O=S((a=>b(a).currentTab)),D=S((a=>b(a).currentSubTab)),tt=S((a=>b(a).notificationDetailsByTab.comments.fetchCountState)),P=S((a=>b(a).notificationDetailsByTab.comments.fetchState)),at=S((a=>b(a).notificationDetailsByTab.comments.uiState.unreadCount)),et=S((a=>b(a).allExternalNotifications)).filter((a=>a.inboxNotification.readAt==null)).map((a=>a.inboxNotification.id)),st=Rt().allUsers,{inboxNotifications:w,isLoading:y,hasFetchedAll:C,isFetchingMore:R,fetchMore:ot}=mt(),{threads:q,isLoading:L,fetchMore:W,isFetchingMore:z,hasFetchedAll:J}=lt({query:{metadata:{companyId:s.companyId,application:"dashboard"}}});k.useEffect((()=>{if(O!==c&&c!=null&&o(K(c)),c==null){const a=`../${O}`,p=B(l.state?.pathnameStackToGoBack,l.pathname);t(a,{state:{pathnameStackToGoBack:p}})}}),[c]),k.useEffect((()=>{tt.fetchState==="Not-Started"&&o(m({fetchCountState:{fetchState:"In-Progress",error:void 0}},"comments"))}),[]),k.useEffect((()=>{if(y===!1&&C===!0&&s?.companyId!=null&&w!=null){const a=`dashboard_${s.companyId}`,p=w.filter((A=>A.roomId===a&&A.readAt==null)).length;o(m({fetchCountState:{fetchState:"Completed",error:void 0}},"comments")),o(E({unreadCount:p},"comments"))}}),[y,C]),k.useEffect((()=>{V!=="In-Progress"&&g&&o($("task_manager","dashboard",["read","unread"]))}),[g]),k.useEffect((()=>{const a=setTimeout((()=>ot?.()),0);return()=>clearTimeout(a)}));const G=y||R===!0||C!==!0||y||R===!0||C!==!0;k.useEffect((()=>{G&&P!=="In-Progress"?o(m({fetchState:"In-Progress",error:void 0},"comments")):G||P!=="In-Progress"||o(m({fetchState:"Completed",error:void 0},"comments"))}),[G,P]),k.useEffect((()=>{o(E({hasMore:C!==!0},"comments"))}),[C]),k.useEffect((()=>{e.fetchState!=="In-Progress"&&e.fetchState!=="Completed"&&T===!1&&(M(!0),o(Ct()))}),[e.fetchState]),k.useEffect((()=>{if(y===!1&&L===!1&&w!=null&&q!=null){const a=`dashboard_${s.companyId}`,p=w.filter((u=>u.roomId===a)).filter((u=>Gt(u.kind))),A=p.filter((u=>u.readAt==null)),_=p.map((u=>u.id)),ct=p.map((u=>{const U=q.find((dt=>{return dt.id===((v=u).kind==="thread"?v.threadId:"subjectId"in v?v.subjectId:void 0);var v}));return U!=null?{inboxNotification:{...u,threadId:U.id},thread:U}:(z||J===!0||W==null||W(),null)})).filter((u=>u!=null));o(m({allNotificationsIds:_},"comments")),o(E({totalCount:_.length,unreadCount:A.length},"comments")),o(At(ct))}}),[y,R,z,C,J,L,w?.length]);const nt={events:s.userRoleId!=null?[`private-encrypted-${s.userRoleId}.dashboard-user-notification`]:[],eventCallback:(a,p)=>{if(jt(p)){const A=Et(p.mode);if(A==="dashboard"&&o(E({unreadCount:p.data.unread},"tasks")),V!=="In-Progress"){const _=[];D==="all"?_.push("read","unread"):D!=="mentions"&&_.push(D),o($("task_manager",A,_,!0))}}}},it=ft(),{isTaskManagerAccessEnabled:rt}=Ot(f);return N.jsx(Lt,{tenantEmailDomain:n,loggedInUserRoleMap:Z,signedInUser:f,externalNotificationsUnreadCount:at,location:l,navigate:t,isDebitCardFeatureEnabled:r,isTaskManagerAccessEnabled:rt,users:st,markInboxNotificationAsRead:it,allUnreadCommentsNotificationIds:et,isAiCfoAccessEnabled:i,onAskAiCfoClick:I,...nt})};function ma(){return N.jsxs(bt,{children:[N.jsx(Q,{path:"/:selectedTab",element:N.jsx(Wt,{})}),N.jsx(Q,{path:"*",element:N.jsx(ut,{})})]})}export{ma as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as m}from"./liveblocks-BXyXenK7.js";import{a as r}from"./sentry-D4svnzxK.js";import{u as A,g as j,j as o,N as C}from"./core-Bl4MLhFi.js";import{Up as P,fE as R,gl as x,Uq as z,Ur as D,Us as M,Ut as q,pR as k,T4 as L}from"./zeni-epic-state-UM7IPCLf.js";import{z as h,ah as I}from"./index-D_qRPRIi.js";import"./mui-CyP-P4av.js";import"./recharts-CZKBTuPa.js";import"./analytics-B06OpwA-.js";import"./plaid-C0aCR9wu.js";import"./dnd-CimhpTrK.js";import"./stripe-cKAAJElX.js";import"./lottie-2qUppQdg.js";import"./lexical-BbBoQdpc.js";import"./pdf-BENieWk6.js";import"./utils-Bycom664.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]="2d540bfd-91dc-4e08-b3b2-57a4be0a533b",n._sentryDebugIdIdentifier="sentry-dbid-2d540bfd-91dc-4e08-b3b2-57a4be0a533b")}catch{}})();function ee(){const n=A(),s=j(),{params:t,error:i}=r.useMemo((()=>P(s.search)),[s.search]),b=r.useMemo((()=>new URLSearchParams(s.search).get("client_name")??t?.clientId??"Unknown Application"),[s.search,t]),p=h.isSignedIn(),a=h.getSignedInUser(),f=o((e=>R(e))),l=o((e=>x(e))),d=o((e=>e.tenantState.fetchState)),w=o(z),y=o(D),u=o(M),[U,v]=r.useState(null),[S,E]=r.useState(null);r.useEffect((()=>{document.querySelector("#app-shell-loader")?.remove()}),[]),r.useEffect((()=>()=>{n(q())}),[n,s.search]),r.useEffect((()=>{i!=null&&console.warn("[OAuthConsent] invalid params:",i)}),[i]);const g=r.useRef(!1);r.useEffect((()=>{p&&a!=null&&!g.current&&(d!=="Not-Started"&&d!=="Error"||(g.current=!0,n(k(a.userId,a.zeniSessionId??void 0))))}),[p,a,d,n]),r.useEffect((()=>{u!=null&&u!==""&&(window.location.href=u)}),[u]);const _=r.useMemo((()=>{if(f?.tenantId!=null)return f.tenantId;const e=h.getActiveTenantForUser()?.tenantId;return e!=null&&l.some((T=>T.tenantId===e))?e:l.length===1?l[0].tenantId:null}),[f?.tenantId,l]),c=U??_;return i!=null?m.jsx(I,{variant:"invalid_params",paramsError:i}):p?m.jsx(I,{variant:"signed_in",clientName:b,userEmail:a?.userEmail,isInitializing:d!=="Completed",tenants:l,selectedTenantId:c,onSelectTenant:v,approveError:S??y,isApproving:w==="In-Progress",showAllowButton:c!=null,onApprove:()=>{t!=null&&a!=null&&c!=null&&n(L(a.userId,a.zeniSessionId??void 0,c,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-BXyXenK7.js";import{h as Z,u as H,g as J,i as K,j as d,l as Q,n as ee,o as C}from"./core-Bl4MLhFi.js";import{fE as M,A3 as O,v0 as ae,Vh as w,uX as T,bq as te,b$ as se,uY as oe,Vi as re,U$ as S,eh as ne,DR as ce,Vj as ie,Ed as le,dZ as de,dY as me}from"./zeni-epic-state-UM7IPCLf.js";import{ai as fe,z as pe,aq as ue,as as he,U as Fe,N,d as V,a8 as ge,k as $,aD as be,p as Ie}from"./index-D_qRPRIi.js";import"./mui-CyP-P4av.js";import Ce from"./NotFoundScreen-BHAnIkPW.js";import{F as Se}from"./FeaturePreviewScreen-BAENITNo.js";import{a as F}from"./sentry-D4svnzxK.js";import{u as Te}from"./useAskAiCfoHostNavButtonProps-DYVVwney.js";import{u as ye}from"./useInitialThreadRequest-R2hAErYY.js";import{t as Ae}from"./routePaths-D20OKXnM.js";import{M as De}from"./MobileAppDrawer-Bm1u6Ken.js";import"./recharts-CZKBTuPa.js";import"./analytics-B06OpwA-.js";import"./plaid-C0aCR9wu.js";import"./dnd-CimhpTrK.js";import"./stripe-cKAAJElX.js";import"./lottie-2qUppQdg.js";import"./lexical-BbBoQdpc.js";import"./pdf-BENieWk6.js";import"./utils-Bycom664.js";import"./InboxNotificationsProvider-CMdsyY0A.js";import"./useTaskManagerAccess-Rxke8A9H.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]="b29ed508-41b4-465d-92ea-a9c464d61e37",s._sentryDebugIdIdentifier="sentry-dbid-b29ed508-41b4-465d-92ea-a9c464d61e37")}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})}},xe=Q((function(s){const e=re(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:$}}),(function(s,e){return{onForecastSelectionChanged:(a,o)=>{s(w(a,o)),e.isPandLReportFetched(a)||s(T(a)),y(e.forecastIdFromUrlPath,a,e.navigate)},onTimeframeChanged:a=>{s(le(a))},onForecastVsActualsCompareToggle:a=>{s(ie(a)),s(S({forecastId:e.forecastIdFromUrlPath,scrollPosition:{scrollLeft:0,scrollTop:0}}))},onCompareModeChanged:a=>{s(ce(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=ne(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=Ae(e.tenantEmailDomain,a.accountId,a.accountType,p,r,c),m=Ie(e.location.state?.pathnameStackToGoBack,e.location.pathname);e.navigate(u,{state:{pathnameStackToGoBack:m,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("../../")}}}))(be);function v(){const s=fe(),e=Z(),a=H(),o=J(),{forecastId:r,tenantEmailDomain:c}=K(),[p,u]=F.useState(!1),[m,A]=F.useState(!1),g=pe.getSignedInUser(),D=d((t=>M(t))),q=D.company?.companyInfo.firstMonthOfFY??1,i=d((t=>O(t.forecastState,t.forecastListState))),l=d((t=>t.forecastListState.fetchState==="Completed")),x=d((t=>t.profitAndLossState)),E=d((t=>t.reportUIOptionsState.selectedForecast)),j=t=>x.pandLByForecastID[t]!=null&&oe(t,x).reducedAllFetchState.fetchState==="Completed",{areTenantIdsInSync:b}=ue();he({isDataReady:l});const{isAiCfoAccessEnabled:_,onAskAiCfoClick:B}=Te({mobileExploreReferrer:"Forecast"});F.useEffect((()=>{if(!p&&b)u(!0),l||a(ae());else if(l&&!m){A(!0);const t=((f,R,U)=>R!=null?f.forecasts.findIndex((I=>I.id===R)):U!=null?f.forecasts.findIndex((I=>I.id===U)):f.forecasts.length>0?0:-1)(i,r,E?.id);t===-1&&r!=null?e("page-not-found",{replace:!0}):t!==-1&&t!=E?.index?(a(w(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)&&b&&a(T(i.forecasts[t].id))}}),[p,u,a,l,i,m,A,O,T,b]);const k=Fe(),Y=k?.loggedInUserRole!=null&&te(k.loggedInUserRole),{useFeatureGate:G}=N(),{isFeatureEnabled:L}=G(V.isReportsCommentingEnabled),W=ye(L?D?.companyId:void 0,{clearParams:l&&m}),[z,X]=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 P=t=>{X(t)};return n.jsxs(n.Fragment,{children:[l?n.jsx(ge,{analytics:$,onLoad:t=>(f=>f.trackForecast())(t)}):null,n.jsx(De,{isAppContentDrawerOpen:z,handleDrawerToggle:P}),n.jsx(xe,{firstMonthOfFY:q,tenantEmailDomain:c,forecastIdFromUrlPath:r,navigate:e,location:o,isPandLReportFetched:j,meetingUrl:se(h.toString()),hasTransactionAccess:Y,isAiCfoAccessEnabled:_,onAskAiCfoClick:B,isReportsCommentingEnabled:L,initialOpenThreadRequest:W,onClickMenuIcon:()=>{P(!0)}})]})}function He(){const s=d((c=>M(c))),{useFeatureGate:e}=N(),{isFeatureEnabled:a}=e(V.isDebitCardFeatureEnabled),o=de(a,s),r=me(s);return o===!0||r===!0?n.jsx(Se,{}):n.jsxs(ee,{children:[n.jsx(C,{path:"/",element:n.jsx(v,{})}),n.jsx(C,{path:"/:forecastId",element:n.jsx(v,{})}),n.jsx(C,{path:"/:forecastId/*",element:n.jsx(Ce,{})})]})}export{He as default};
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import{j as a}from"./liveblocks-BXyXenK7.js";import{Vd as re,fE as N,l_ as G,dZ as X,dY as le,S4 as J,UC as ce,CO as Pe,Ve as q,CD as je,CY as Le,CS as de,CH as pe,CW as Te,CT as ve,Vf as ue,sk as Ve,g5 as Ae,gC as Fe,Vg as H,CL as me,CK as ge,C$ as Oe,c8 as Re}from"./zeni-epic-state-UM7IPCLf.js";import{a1 as Ce,N as Q,d as _,z as W,h as fe,J as he,af as ye,az as be,aA as Ze,ab as Se,H as O,ag as we,G as K,aB as Ue,aq as Be,as as $e,a8 as ze,k as xe,S as He,p as _e,aC as Ge,U as We}from"./index-D_qRPRIi.js";import{D as De,n as M,S as Ie}from"./mui-CyP-P4av.js";import ae from"./NotFoundScreen-BHAnIkPW.js";import{a as c}from"./sentry-D4svnzxK.js";import{u as ee,i as Ke,j as g,h as Me,g as Ye,l as qe,n as se,o as z}from"./core-Bl4MLhFi.js";import{u as Ne}from"./useAskAiCfoHostNavButtonProps-DYVVwney.js";import{M as Xe}from"./MobileAppDrawer-Bm1u6Ken.js";import"./recharts-CZKBTuPa.js";import"./analytics-B06OpwA-.js";import"./plaid-C0aCR9wu.js";import"./dnd-CimhpTrK.js";import"./stripe-cKAAJElX.js";import"./lottie-2qUppQdg.js";import"./lexical-BbBoQdpc.js";import"./pdf-BENieWk6.js";import"./utils-Bycom664.js";import"./InboxNotificationsProvider-CMdsyY0A.js";import"./useTaskManagerAccess-Rxke8A9H.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]="b24eb986-011a-4d0d-a9cc-6103cbcefa7f",e._sentryDebugIdIdentifier="sentry-dbid-b24eb986-011a-4d0d-a9cc-6103cbcefa7f")}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:C,isEditPeopleDrawerOpen:i,closeDrawerHandler:b})=>{const f=Ce(),m=ee(),[R,Z]=c.useState(!1),[k,S]=c.useState(!1),{userId:w}=Ke(),r=g((l=>re(l))),p=g((l=>N(l))),E=g((l=>G(l))),{useFeatureGate:D}=Q(),{isFeatureEnabled:I}=D(_.isDebitCardFeatureEnabled),P=X(I,p),T=le(p),v=J(p),U=ce(p),B=!!p.company?.featuresActivationInfo?.isReimbursementFeatureEnabled,x=!P&&E&&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(q()),b()},V=()=>{R===!0?S(!0):h()},$=d.companyView?.controllers?.map((l=>l.user)),u=!!p.company?.companyZeniAccountInfo?.isZeniAccountEnabled,{isFeatureEnabled:j}=D(_.isChargeCardFeatureEnabled),L=fe(p,j,I),{isCardsHidden:A}=he(p?.tenantId),y=!L||A,F=p.companyTreasuryInfo?.info?.businessVerificationStatus?.code==="verified",s={peopleDetails:r,classList:n.classes,managersList:t.users,controllersList:$,mode:C,isZeniTenant:v,isAccountingClassesEnabled:E,isReimbursementDisabled:B===!1,isZeniAccountsDisabled:u===!1,isChargeCardDisabled:y,isTreasuryDisabled:F===!1,isLiteRoleDisabled:U===!1,isBankingOnlyTenant:P,isCardsOnlyTenant:T,onResetClick:h,onDeleteUser:l=>{m(pe(l.userId,l.userRole.userRoleId))},onPeopleLocalDataUpdated:l=>{m(de({peopleLocalData:l})),Z(!0)},onSaveClick:()=>{m(C==="zeni_only"?je(e):Le(v))},onCloseClick:V,isLoading:x||r.person==null},o={onOkClick:()=>{S(!1),h()},onCancelClick:()=>{S(!1)}};return c.useEffect((()=>{x===!1&&w!=null&&m(Pe(w))}),[x,w]),c.useEffect((()=>{r.updatePersonState.fetchState==="Completed"&&h()}),[r.updatePersonState.fetchState]),a.jsx(De,{anchor:"right",open:i,PaperProps:{style:{width:Je.overlayWidth.valuePercentage(f),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:ye.overlayDark,cursor:"pointer"}}},onClose:V,children:a.jsxs(ea,{onClick:l=>l.stopPropagation(),children:[k===!0?a.jsx(be,{titleComponent:a.jsx(ke,{children:te.discardTitle}),descriptionComponent:a.jsx(Ee,{children:te.discardDescription}),primaryButtonText:ne.yes,secondaryButtonText:ne.no,action:o,isEditPopup:!0}):null,a.jsx(Ze,{...s})]})})},ea=M(Ie)`
|
|
2
|
-
display: flex;
|
|
3
|
-
min-height: 100%;
|
|
4
|
-
flex-direction: column;
|
|
5
|
-
`,ke=M(we.H6Regular)`
|
|
6
|
-
margin-top: ${O.sp7};
|
|
7
|
-
padding-left: ${O.sp8};
|
|
8
|
-
padding-right: ${O.sp8};
|
|
9
|
-
color: ${e=>e.theme.colors.primary};
|
|
10
|
-
word-break: break-word;
|
|
11
|
-
`,Ee=M(we.LargeRegularSp)`
|
|
12
|
-
color: ${e=>e.theme.colors.hero};
|
|
13
|
-
padding-left: ${O.sp8};
|
|
14
|
-
padding-right: ${O.sp8};
|
|
15
|
-
margin-bottom: 30px;
|
|
16
|
-
margin-top: ${O.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:C,isInvitePeopleDrawerOpen:i,closeDrawerHandler:b})=>{const f=Ce(),m=ee(),[R,Z]=c.useState(!1),[k,S]=c.useState(!1),w=g((o=>re(o))),r=g((o=>N(o))),p=g((o=>G(o))),{useFeatureGate:E}=Q(),{isFeatureEnabled:D}=E(_.isDebitCardFeatureEnabled),I=X(D,r),P=le(r),T=J(r),v=ce(r),U=!!r.company?.featuresActivationInfo?.isReimbursementFeatureEnabled,B=!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 x=()=>{b(),m(q())},h=()=>{R===!0?S(!0):x()},V={onOkClick:()=>{S(!1),x()},onCancelClick:()=>{S(!1)}},$=d.companyView?.controllers.map((o=>o.user)),u=!!r.company?.companyZeniAccountInfo?.isZeniAccountEnabled,{isFeatureEnabled:j}=E(_.isChargeCardFeatureEnabled),L=fe(r,j,D),{isCardsHidden:A}=he(r?.tenantId),y=!L||A,F=r.companyTreasuryInfo?.info?.businessVerificationStatus?.code==="verified",s={classList:n.classes,managersList:t.users,controllersList:$,mode:C,isZeniTenant:T,onPeopleLocalDataUpdated:o=>{m(de({peopleLocalData:o})),Z(!0)},onResetClick:x,onSaveClick:()=>{m(C==="zeni_only"?Te(e):ve())},onCloseClick:h,peopleDetails:w,isAccountingClassesEnabled:p,isReimbursementDisabled:U===!1,isLiteRoleDisabled:v===!1,isZeniAccountsDisabled:u===!1,isChargeCardDisabled:y,isTreasuryDisabled:F===!1,isBankingOnlyTenant:I,isCardsOnlyTenant:P,isLoading:B};return c.useEffect((()=>{w.invitePersonState.fetchState==="Completed"&&(b(),m(q()))}),[w.invitePersonState.fetchState]),a.jsx(De,{anchor:"right",open:i,PaperProps:{style:{width:aa.overlayWidth.valuePercentage(f),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(Ee,{children:oe.discardDescription}),primaryButtonText:ie.yes,secondaryButtonText:ie.no,action:V}):null,a.jsx(Ue,{...s})]})})},ta=M(Ie)`
|
|
19
|
-
display: flex;
|
|
20
|
-
min-height: 100%;
|
|
21
|
-
flex-direction: column;
|
|
22
|
-
`,na=qe((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:G(e),analytics:xe}}),(function(e,t){const{navigate:d,companyId:n,shouldFetchClasses:C}=t;return{personAction:{onPersonDelete:(i,b)=>{e(pe(i,b))},onResendInvite:i=>{e(Oe(i))},onReloadPeople:()=>{e(me()),e(ge(n,C))},onBackClick:()=>{d("../../")},onModeChange:i=>{e(H({mode:i,searchText:"",sortKey:"name",sortOrder:"ascending"}))},onSearchTextChanged:i=>{e(H({searchText:i}))}}}}))(Ge);function Y({isInvitePeopleDrawerOpen:e,isEditPeopleDrawerOpen:t}){const d=Me(),n=ee(),C=Ye(),{areTenantIdsInSync:i}=Be(),b=W.getSignedInUser(),f=g((s=>N(s))),{useFeatureGate:m}=Q(),{isFeatureEnabled:R}=m(_.isDebitCardFeatureEnabled),Z=g((s=>G(s))),k=!X(R,f)&&Z,S=J(f),w=f?.tenantId,{tenantEmailDomain:r}=f,[p,E]=c.useState(!1),[D,I]=c.useState(!1),[P,T]=c.useState(!1),[v,U]=c.useState("off"),[B,x]=c.useState(!1),h=s=>{x(s)},{isAiCfoAccessEnabled:V,onAskAiCfoClick:$}=Ne({mobileExploreReferrer:"People"}),u=g((s=>ue(s)));$e({isDataReady:u.fetchState==="Completed"});const j=g((s=>Ve(s.classState,s.classListState))),L=g((s=>Ae(s.userState,s.userRoleState,s.userListViewState,"manager"))),A=g((s=>Fe(s))),y=f?.companyId;c.useEffect((()=>{p&&v===u.uiState.mode||!i||(n(H({searchText:"",sortKey:"name",sortOrder:"ascending"})),U(u.uiState.mode),E(!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(H({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:xe,onLoad:s=>s.trackPageLoaded(He.Event.members)}):null,D===!0?a.jsx(sa,{closeDrawerHandler:F,isInvitePeopleDrawerOpen:D,managersListView:L,companyPassportView:A,classListView:j,companyId:y,mode:u.uiState.mode}):null,P===!0?a.jsx(Qe,{closeDrawerHandler:F,isEditPeopleDrawerOpen:P,managersListView:L,companyPassportView:A,classListView:j,companyId:y,mode:u.uiState.mode}):null,a.jsx(Xe,{isAppContentDrawerOpen:B,handleDrawerToggle:h}),a.jsx(na,{navigate:d,signedInUser:b,isZeni:f.isZeni,isZeniTenant:S,peopleUIState:u.uiState,companyId:y,shouldFetchClasses:k,classList:j,managersView:L,peopleView:u,onInvitePeopleClick:()=>{d("./new")},onColumnSortConfigChanged:(s,o)=>{n(H({sortKey:s,sortOrder:o}))},onRowClick:s=>{const o=`/${r}/people/${encodeURIComponent(s)}/edit`,l=_e(C.state?.pathnameStackToGoBack,C.pathname);d(o,{state:{pathnameStackToGoBack:l}})},onClickMenuIcon:()=>{h(!0)},isAiCfoAccessEnabled:V,onAskAiCfoClick:$})]})}function ka(){const e=We();return Re(e?.loggedInUserRole??[])?a.jsxs(se,{children:[a.jsx(z,{path:"/",element:a.jsx(Y,{})}),a.jsx(z,{path:"new",element:a.jsx(Y,{isInvitePeopleDrawerOpen:!0})}),a.jsx(z,{path:":userId/edit",element:a.jsx(Y,{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-BXyXenK7.js";import T from"./NotFoundScreen-BHAnIkPW.js";import{a as r}from"./sentry-D4svnzxK.js";import{h as _,g as v,j as p,i as M,u as P,N as U,l as z,n as O,o as b}from"./core-Bl4MLhFi.js";import{fE as B,a0Q as h,bo as F,bn as N,iK as V,gg as K}from"./zeni-epic-state-UM7IPCLf.js";import{E as Q,z as I,as as $,dP as q}from"./index-D_qRPRIi.js";import"./mui-CyP-P4av.js";import{u as G}from"./useAskAiCfoHostNavButtonProps-DYVVwney.js";import{M as H}from"./MobileAppDrawer-Bm1u6Ken.js";import"./recharts-CZKBTuPa.js";import"./analytics-B06OpwA-.js";import"./plaid-C0aCR9wu.js";import"./dnd-CimhpTrK.js";import"./stripe-cKAAJElX.js";import"./lottie-2qUppQdg.js";import"./lexical-BbBoQdpc.js";import"./pdf-BENieWk6.js";import"./utils-Bycom664.js";import"./InboxNotificationsProvider-CMdsyY0A.js";import"./useTaskManagerAccess-Rxke8A9H.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]="aba1268b-3a8b-48a7-88c7-41884e51df55",e._sentryDebugIdIdentifier="sentry-dbid-aba1268b-3a8b-48a7-88c7-41884e51df55")}catch{}})();const J=z((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)}}}))(q),L=()=>{const e=_(),t=v(),c=Q(),o=p((a=>B(a))),{aggregatedReportViewState:n}=p((a=>h(a))),{tenantEmailDomain:f}=M(),g=P(),l=I.getSignedInUser();if(l==null)throw new Error("Can't access this page without signing in...");const m=r.useRef(!1),[w,S]=r.useState(!1),C=F(o?.userRole??[]),k=o?.userRole?.includes("bookkeeping_admin")??!1,x=N(l),y=C||k||x,d=r.useCallback(((a,i,A)=>{g(V({fromMonth:a,toMonth:i,cacheOverride:A}))}),[]);r.useEffect((()=>{n?.fetchState==="Completed"&&m.current&&(g(K({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"||d(a,i,!0),m.current=!0}),[n?.fetchState,d]),j=r.useCallback(((a,i)=>{d(a,i,!1)}),[d]),u=a=>{S(a)},{isAiCfoAccessEnabled:R,onAskAiCfoClick:E}=G({mobileExploreReferrer:"Performance"});return $({isDataReady:n?.fetchState==="Completed"}),y?s.jsxs(s.Fragment,{children:[s.jsx(H,{isAppContentDrawerOpen:w,handleDrawerToggle:u}),s.jsx(J,{navigate:e,location:t,themeState:c,currentTenant:o,signedInUser:l,tenantEmailDomain:f,onReload:D,onTimeRangeSelect:j,handleDrawerToggle:u,isAiCfoAccessEnabled:R,onAskAiCfoClick:E})]}):s.jsx(U,{to:`/${f}/dashboard`,replace:!0})};function be(){return s.jsxs(O,{children:[s.jsx(b,{path:"*",element:s.jsx(L,{})}),s.jsx(b,{path:"*",element:s.jsx(T,{})})]})}export{be as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as o}from"./liveblocks-BXyXenK7.js";import z from"./NotFoundScreen-BHAnIkPW.js";import{a as p}from"./sentry-D4svnzxK.js";import{h as C,g as N,u as V,j as u,N as k,l as D,n as Z,o as b}from"./core-Bl4MLhFi.js";import{fE as E,YV as h,Za as w,Nv as U,Nr as L,Nu as f,Nk as B,Zz as $,No as K,Nx as Y}from"./zeni-epic-state-UM7IPCLf.js";import{z as T,w as O,c9 as q,o as W,bS as F,ca as G}from"./index-D_qRPRIi.js";import"./mui-CyP-P4av.js";import{u as H,R as x}from"./ReimbursementApprovalRuleDetailScreen-C95Tlh44.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]="916bc5f9-5920-4951-846f-9d938a6fa75c",e._sentryDebugIdIdentifier="sentry-dbid-916bc5f9-5920-4951-846f-9d938a6fa75c")}catch{}})();const j="reimbursement-approval-rule-update",J=D((function(e){return{approvalView:h(e),remiSetupApproverViewUpdateData:w(e).remiSetupApproverViewUpdateData}}),(function(e,s){const{navigate:n,location:a}=s;return{onApprovalRulesEventReceived:t=>{t.endsWith(j)&&e($(!1))},onBackClick:()=>{W(a)?n("../../"):n("../../../reimbursements/setup")},onDeleteRuleClick:t=>{e(B(t,!1))},onEditRuleClick:t=>{t!=null?(e(f(t)),n(`./${t}/edit`)):(e(f()),n("./new"))}}}))(O(q)),M=({isLoading:e})=>{const s=C(),n=N(),a=V(),[t,l]=p.useState(!1),[v,R]=p.useState(!1),S=u((r=>r.remiSetupApproverViewState.fetchState)),c=u((r=>E(r))),d=u((r=>h(r))),g=u((r=>w(r).remiSetupApproverViewUpdateData));if(p.useEffect((()=>{g?.updateStatus.fetchState==="Completed"&&a(U())}),[g]),p.useEffect((()=>{t||S!=="Not-Started"||e||(l(!0),a(L(!0,!1,!1,!1)))}),[t,S,e,a]),T.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(f())),s("./new"))}),[v,d,a]);const m={events:c.companyId!=null?[`private-encrypted-${c.companyId}.${j}`]:[],eventCallback:(r,y,I)=>{r.endsWith(j)&&I.onApprovalRulesEventReceived(r)}};return c?.companyReimbursementInfo?.info?.isReimbursementTOSAccepted===!1?o.jsx(k,{to:"../../promo"}):o.jsx(J,{currentTenant:c,location:n,navigate:s,...m})},A="reimbursement-approval-rule-update",P=D((function(e){const s=h(e),n=w(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($(!1))},onBackClick:()=>{W(a)?n("../../"):n("../../../reimbursements/setup")},onDeleteRuleClick:t=>{e(B(t,!0))},onEditRuleClick:t=>{t!=null?(e(f(t)),n(`./${t}/edit`)):(e(f()),n("./new"))},onReorderRules:t=>{e(Y(t,!0))}}}))(O(G)),Q=()=>{const e=u((a=>E(a))),{isApprovalRulesV3Enabled:s,isLoading:n}=F(e?.tenantId);return s?o.jsx(X,{isLoading:n}):o.jsx(M,{isLoading:n})},X=({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)),g=u((i=>i.remiSetupApproverViewState.approverListState.fetchStatus.fetchState)),m=u((i=>E(i))),r=u((i=>h(i)));H();const y=u((i=>w(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||g!=="Not-Started"||e||(R(!0),a(K(!1,!0)))}),[v,g,e,a]),T.getSignedInUser()==null)throw Error("Can't access reimbursement approval without signing in...");p.useEffect((()=>{r.allApprovalRules.length===0&&r.fetchState==="Completed"&&(S||(c(!0),a(f())),s("./new"))}),[S,r,a]);const I={events:m.companyId!=null?[`private-encrypted-${m.companyId}.${A}`]:[],eventCallback:(i,ee,_)=>{i.endsWith(A)&&_.onApprovalRulesEventReceived(i)}};return m?.companyReimbursementInfo?.info?.isReimbursementTOSAccepted===!1?o.jsx(k,{to:"../../promo"}):o.jsx(P,{currentTenant:m,location:n,navigate:s,isLoading:e,...I})};function le(){return o.jsxs(Z,{children:[o.jsx(b,{path:"/",element:o.jsx(Q,{})}),o.jsx(b,{path:"/new",element:o.jsx(x,{})}),o.jsx(b,{path:"/:approvalRuleId/edit",element:o.jsx(x,{})}),o.jsx(b,{path:"*",element:o.jsx(z,{})})]})}export{le as R};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as a}from"./liveblocks-BXyXenK7.js";import{z as b,a8 as v,k as d,S as E,e4 as k,N as D,d as C}from"./index-D_qRPRIi.js";import"./mui-CyP-P4av.js";import g from"./NotFoundScreen-BHAnIkPW.js";import{a as c}from"./sentry-D4svnzxK.js";import{u as I,j as h,h as F,g as L,l as _,n as T,o as f,N as y}from"./core-Bl4MLhFi.js";import{fE as U,a1L as j,a1M as p,DH as P,p_ as V,a1N as z,DF as G}from"./zeni-epic-state-UM7IPCLf.js";import"./recharts-CZKBTuPa.js";import"./analytics-B06OpwA-.js";import"./plaid-C0aCR9wu.js";import"./dnd-CimhpTrK.js";import"./stripe-cKAAJElX.js";import"./lottie-2qUppQdg.js";import"./lexical-BbBoQdpc.js";import"./pdf-BENieWk6.js";import"./utils-Bycom664.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]="338fbb83-e072-4e39-ac76-f26874066af7",e._sentryDebugIdIdentifier="sentry-dbid-338fbb83-e072-4e39-ac76-f26874066af7")}catch{}})();const H=_((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((l=>{s.push(l.companyName),r.push(l.emailIds[0])})),d.trackInviteEmailClicked("send",s,r,s.length)}e(G())},onUpdateInviteFormLocalData:s=>{e(z({localData:s}))},onSubmitSuccess:()=>{e(p())},onCancelClick:()=>{i!=null&&d.trackInviteEmailClicked("cancel")}}}))(k),M=()=>{const e=I(),[t,n]=c.useState(!1),[i,s]=c.useState(!1),r=h((o=>U(o))),l=F(),w=L(),u=b.getSignedInUser();if(u==null)throw Error("Can't access invite referral screen without signing in...");const m=h((o=>j(o))),x=u?.firstName!=null?u.firstName:"User";c.useEffect((()=>{e(p()),r?.rewardsLastViewedTime==null&&i===!1&&(e(P()),s(!0))}),[]),c.useEffect((()=>{t||m.fetchState!=="Not-Started"||(n(!0),e(V(!0)))}),[m.fetchState,e]);const N=r.company?.companyInfo.companyLegalName??r.companyName;return a.jsxs(a.Fragment,{children:[m.fetchState==="Completed"?a.jsx(v,{analytics:d,onLoad:o=>(S=>S.trackPageLoaded(E.Event.inviteEmailViewed))(o)}):null,a.jsx(H,{navigate:l,location:w,currentTenant:r,companyName:N,userName:x,inviteFormCompayData:m.localData})]})};function ne(){const{useFeatureGate:e}=D(),{isFeatureEnabled:t}=e(C.isReferralFeatureEnabled);return a.jsxs(T,{children:[a.jsx(f,{path:"/",element:a.jsx(y,{to:"refer",replace:!0})}),a.jsx(f,{path:"how-it-works",element:a.jsx(y,{to:"refer",replace:!0})}),a.jsx(f,{path:"refer/*",element:t?a.jsx(M,{}):a.jsx(g,{})}),a.jsx(f,{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-BHAnIkPW.js","assets/sentry-D4svnzxK.js","assets/core-Bl4MLhFi.js","assets/zeni-epic-state-UM7IPCLf.js","assets/index-D_qRPRIi.js","assets/mui-CyP-P4av.js","assets/analytics-B06OpwA-.js","assets/utils-Bycom664.js","assets/index-BhC2LNQw.css","assets/DashboardRoutes-CsjwE5Mt.js","assets/withTransactionSidePanel-rDK0lUVX.js","assets/useAskAiCfoHostNavButtonProps-DYVVwney.js","assets/TransactionDetailScreen-DcuSfVKO.js","assets/decodeURIComponentSafe-Buybgpqw.js","assets/useInitialThreadRequest-R2hAErYY.js","assets/routePaths-D20OKXnM.js","assets/expenseAutomationHelper-CkBJgYs_.js","assets/stripSplatSuffix-G7yC23v6.js","assets/analyticsHelper-xKlm2_zz.js","assets/CompanyPassportScreen-DSUfEnP2.js","assets/MobileAppDrawer-Bm1u6Ken.js","assets/InboxNotificationsProvider-CMdsyY0A.js","assets/useTaskManagerAccess-Rxke8A9H.js","assets/useAiCfoDashboardSuggestedQuestionsChips-BfYubNz7.js","assets/FeaturePreviewScreen-BAENITNo.js","assets/BillPayRoutes-CDWH4S4C.js","assets/AddressScreen-Cbo3iSD8.js","assets/DomesticWireDetailScreen-BHofWD_4.js","assets/BusinessVerificationPageScreen-BVXryUGP.js","assets/DrawerScreen-eoSileBw.js","assets/SetupPagesScreen-C64hdzmo.js","assets/BillPayApprovalRoutes-LmedJ5XD.js","assets/ReimbursementApprovalRuleDetailScreen-C95Tlh44.js","assets/getLocaleForTenant-NAFAfy2t.js","assets/ReimbursementRoutes-Sdsth_9q.js","assets/ReimbursementApprovalRoutes-C0yLDyE9.js","assets/TransactionListRoutes-B_voFmAT.js","assets/ZeniAccountStatementScreen-CJ2iauJ5.js","assets/SettingsRoutes-Cwcsb2Ys.js","assets/AccountMappingScreen-B400AyQJ.js","assets/QBOConnectionScreen-Dcslm4FM.js","assets/empty-B4WpR10s.js","assets/index-Bmwrrrme.js","assets/url-SRUWz_6t.js","assets/index-H-kll8aI.js","assets/accountMappingHelper-Djr6f8Xt.js","assets/useEmailConnectResultRefresh-fWgBKuNg.js","assets/ReportsRoutes-DA2ZKfqn.js","assets/ChargeCardRoutes-00uaD3zR.js","assets/useChargeCardPusherEvents-CLgbV2wJ.js","assets/PeopleRoutes-D0lDTK4i.js","assets/ExpenseAutomationRoutes-C41VbCrR.js","assets/useActualMatchingMatchDetail-DjU1UsXK.js","assets/ScheduleDetailsPrepaidExpensesScreen-BinEqncH.js","assets/pathToGoBack-sGBxvK0B.js","assets/TreasuryRoutes-CXgACPbz.js","assets/VendorsRoutes-DdY9Fw_b.js","assets/ZeniAccountRoutes-OVjm5L3x.js","assets/AddressRoutes-Bf2-WRel.js","assets/PandLWithForecastRoutes-eu7U2LpI.js","assets/CustomerOnboardingRoutes-CfsElRde.js","assets/TransactionDetailRoutes-Bz8OXpUB.js","assets/EntityDetailRoutes-BTuykNTu.js","assets/InvoicingRoutes-C6flJIVP.js","assets/NotificationRoutes-DxiudUgY.js","assets/PerformanceRoutes-UIwOxwXM.js","assets/ActualMatchingMatchDetailScreen-at2idxY8.js","assets/RewardsRoutes-MCkqCd4q.js","assets/TaskRoutes-DvNx4Qap.js","assets/TaskListScreen-BBXffRbT.js","assets/AiCfoScreen-C2YvBVu2.js","assets/CardsAiCfoScreen-CyRzyeQR.js"])))=>i.map(i=>d[i]);
|
|
2
|
-
import{_ as s,bn as Es,fE as hs,dZ as ps,dY as xs,AU as Rs,dh as gs,c8 as Is,gI as js,g8 as Ts,de as pe,cG as As,gm as bs,cy as Ds,bE as ys,br as fs,T$ as Cs,v as vs,U2 as Us,bq as Os,U3 as Ps,bK as ws,bJ as Fs,bt as Ls,cu as ks,U4 as Vs,U5 as Hs,d9 as Ss,dc as Bs,db as Ns,cF as Ms,cM as Zs,pR as xe,gh as Re,gX as $s,gj as ge,gK as Ie,gL as je,gk as Gs}from"./zeni-epic-state-UM7IPCLf.js";import{j as e}from"./liveblocks-BXyXenK7.js";import{a as P}from"./sentry-D4svnzxK.js";import{N as u,u as zs,h as qs,i as Ys,g as Ks,j as $,q as Te,n as Ws,o as n}from"./core-Bl4MLhFi.js";import{I as l,c as Js,u as Xs,z as f,N as Qs,f as et,q as st,d as B,h as tt,J as nt,U as at,L as F,G as Ae,t as _,K as ot,M as rt,k as ne}from"./index-D_qRPRIi.js";import"./mui-CyP-P4av.js";import{f as be}from"./analyticsHelper-xKlm2_zz.js";import{t as it}from"./getLocaleForTenant-NAFAfy2t.js";(function(){try{var o=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},D=new o.Error().stack;D&&(o._sentryDebugIds=o._sentryDebugIds||{},o._sentryDebugIds[D]="dc59a74b-6d23-402c-a1dd-e3619ea19078",o._sentryDebugIdIdentifier="sentry-dbid-dc59a74b-6d23-402c-a1dd-e3619ea19078")}catch{}})();const lt=l((()=>s((()=>import("./NotFoundScreen-BHAnIkPW.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`}),De=({tenantEmailDomain:o})=>e.jsx(u,{to:`/${o}/treasury`}),ye=({tenantEmailDomain:o})=>e.jsx(u,{to:`/${o}/checking`}),fe=({tenantEmailDomain:o})=>e.jsx(u,{to:`/${o}/cards`}),C=({showZeniAccountRoute:o,isUserHasBillPayAccess:D,isUserHasReimbursementAccess:N,showTreasuryRoute:i,isTenantBankingOnly:k,showChargeCardRoute:U,tenantEmailDomain:v})=>{if(k===!0){if(o)return e.jsx(ye,{tenantEmailDomain:v});if(i)return e.jsx(De,{tenantEmailDomain:v});if(U)return e.jsx(fe,{tenantEmailDomain:v})}return o?e.jsx(ye,{tenantEmailDomain:v}):i?e.jsx(De,{tenantEmailDomain:v}):U?e.jsx(fe,{tenantEmailDomain:v}):D?e.jsx(dt,{tenantEmailDomain:v}):N?e.jsx(ut,{tenantEmailDomain:v}):e.jsx(lt,{})},ct={dashboard:()=>s((()=>import("./DashboardRoutes-CsjwE5Mt.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-CDWH4S4C.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-Sdsth_9q.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-B_voFmAT.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-Cwcsb2Ys.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-DA2ZKfqn.js")),__vite__mapDeps([47,1,2,3,4,5,6,7,0,24,14,15,20,21,22,8])),chargeCards:()=>s((()=>import("./ChargeCardRoutes-00uaD3zR.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-D0lDTK4i.js")),__vite__mapDeps([50,1,2,3,4,5,6,7,0,11,20,21,22,8])),expenseAutomation:()=>s((()=>import("./ExpenseAutomationRoutes-C41VbCrR.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-CXgACPbz.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-DdY9Fw_b.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-OVjm5L3x.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-DA2ZKfqn.js")),__vite__mapDeps([47,1,2,3,4,5,6,7,0,24,14,15,20,21,22,8])))),Et=l((()=>s((()=>import("./AddressRoutes-Bf2-WRel.js")),__vite__mapDeps([58,1,2,3,26,4,5,6,7,0,8])))),ht=l((()=>s((()=>import("./PeopleRoutes-D0lDTK4i.js")),__vite__mapDeps([50,1,2,3,4,5,6,7,0,11,20,21,22,8])))),pt=l((()=>s((()=>import("./PandLWithForecastRoutes-eu7U2LpI.js")),__vite__mapDeps([59,1,2,3,4,5,6,7,0,24,11,14,15,20,21,22,8])))),xt=l((()=>s((()=>import("./CustomerOnboardingRoutes-CfsElRde.js")),__vite__mapDeps([60,1,2,3,26,4,5,6,7,0,40,41,42,43,44,13,46,49,8])))),Rt=l((()=>s((()=>import("./VendorsRoutes-DdY9Fw_b.js")),__vite__mapDeps([56,1,2,3,4,5,6,7,26,0,24,53,54,15,11,20,21,22,29,45,8])))),gt=l((()=>s((()=>import("./TransactionDetailRoutes-Bz8OXpUB.js")),__vite__mapDeps([61,1,2,3,0,4,5,6,7,12,11,13,14,15,16,8])))),Ce=l((()=>s((()=>import("./EntityDetailRoutes-BTuykNTu.js")),__vite__mapDeps([62,1,2,3,4,5,6,7,13,10,11,12,14,15,16,17,8])))),It=l((()=>s((()=>import("./DashboardRoutes-CsjwE5Mt.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])))),ve=l((()=>s((()=>import("./BillPayRoutes-CDWH4S4C.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])))),jt=l((()=>s((()=>import("./SettingsRoutes-Cwcsb2Ys.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-C6flJIVP.js")),__vite__mapDeps([63,1,2,3,4,5,6,7,26,0,20,21,22,40,41,42,43,44,13,8])))),Ue=l((()=>s((()=>import("./ReimbursementRoutes-Sdsth_9q.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-OVjm5L3x.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])))),bt=l((()=>s((()=>import("./TreasuryRoutes-CXgACPbz.js")),__vite__mapDeps([55,1,2,3,4,5,6,7,0,30,28,15,20,21,22,18,11,14,24,8])))),Dt=l((()=>s((()=>import("./TransactionListRoutes-B_voFmAT.js")),__vite__mapDeps([36,1,2,3,4,5,6,7,10,11,12,13,14,15,16,17,37,8])))),yt=l((()=>s((()=>import("./ChargeCardRoutes-00uaD3zR.js")),__vite__mapDeps([48,1,2,3,4,5,6,7,11,20,21,22,30,28,15,0,18,14,49,26,8])))),ft=l((()=>s((()=>import("./NotificationRoutes-DxiudUgY.js")),__vite__mapDeps([64,1,2,3,0,4,5,6,7,11,22,8])))),Ct=l((()=>s((()=>import("./PerformanceRoutes-UIwOxwXM.js")),__vite__mapDeps([65,1,2,3,0,4,5,6,7,11,20,21,22,8])))),vt=l((()=>s((()=>import("./ExpenseAutomationRoutes-C41VbCrR.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])))),Ut=l((()=>s((()=>import("./ActualMatchingMatchDetailScreen-at2idxY8.js")),__vite__mapDeps([66,1,2,3,4,5,6,7,52,17,13,15,0,8])))),Ot=l((()=>s((()=>import("./RewardsRoutes-MCkqCd4q.js")),__vite__mapDeps([67,1,2,3,4,5,6,7,0,8])))),Pt=l((()=>s((()=>import("./TaskRoutes-DvNx4Qap.js")),__vite__mapDeps([68,1,2,3,0,4,5,6,7,14,20,21,22,69,11,8])))),wt=l((()=>s((()=>import("./AiCfoScreen-C2YvBVu2.js")),__vite__mapDeps([70,1,2,3,4,5,6,7,23,54,15,8])))),Oe=l((()=>s((()=>import("./CardsAiCfoScreen-CyRzyeQR.js")),__vite__mapDeps([71,1,2,3,4,5,6,7,8])))),b=l((()=>s((()=>import("./NotFoundScreen-BHAnIkPW.js")),__vite__mapDeps([0,1,2,3,4,5,6,7,8])))),Ft=l((()=>s((()=>import("./TaskListScreen-BBXffRbT.js").then((o=>o.f))),__vite__mapDeps([69,1,2,3,4,5,6,7,11,20,21,22,8])))),Lt=({isDashboardAccess:o,showZeniAccountRoute:D,isUserHasBillPayAccess:N,isUserHasReimbursementAccess:i,showTreasuryRoute:k,isTenantBankingOnly:U,isTenantCardsOnly:v,showChargeCardRoute:V})=>{if(U===!0){if(D)return e.jsx(u,{to:"checking"});if(k)return e.jsx(u,{to:"treasury"});if(V)return e.jsx(u,{to:"cards"})}return v===!0&&V?e.jsx(u,{to:"cards"}):o?e.jsx(u,{to:"dashboard"}):D?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 D=zs(),N=qs(),{tenantEmailDomain:i}=Ys(),k=Js().mode,{setLoading:U,clearAllLoading:v,clearLoading:V}=Xs(),y=f.getSignedInUserTenant(i)?.tenantId,j=f.getSignedInUser(),W=Es(j),G=Ks(),[L,we]=P.useState(!1),r=$((a=>hs(a))),{useFeatureGate:H}=Qs(),M=et(),J=st(),Fe=!!r.company?.companyZeniAccountInfo?.isZeniAccountEnabled,Le=r.companyTreasuryInfo?.info?.businessVerificationStatus?.code==="verified",{isFeatureEnabled:ke}=H(B.isChargeCardFeatureEnabled),{isFeatureEnabled:oe}=H(B.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"?xs(r):void 0,re=p==="Completed"||T==="Completed"?Rs(r)&&!gs(r):void 0,Ve=tt(r,ke,oe),{isCardsHidden:He}=nt(r?.tenantId),Se=!Ve||!!He,{isFeatureEnabled:Be}=H(B.isSettingsFeatureEnabled),{isFeatureEnabled:Q}=H(B.isAiCfoFileUploadEnabled),{isFeatureEnabled:Ne}=H(B.isInvoicingFeatureEnabled??"is_invoicing_feature_enabled"),Me=Ne||rt==="DEV",Ze=r?.userRole!=null&&Is(r.userRole),z=$((a=>js(a)));if(i!=null){const a=f.getSignedInUserTenant(i);j!=null&&a!=null&&be(j,r,k)}const Z={tenantId:y,userId:j?.userId,sessionId:j?.zeniSessionId},ie=Ts(),h=at(),$e=r.company==null||h?.loggedInUserRoleMap!=null&&pe(h.loggedInUserRole),Ge=As(h?.loggedInUserRoleMap),ee=Te("/:tenantEmailDomain/onboarding/*")!==null,ze=Te("/:tenantEmailDomain/month_end_close_checks/review/:selectedTab/:selectedPeriod/*"),se=ze?.params.selectedPeriod,qe=$((a=>Z.tenantId!=null?bs(a,Z.tenantId):void 0));P.useEffect((()=>{U(F.TENANT_FETCHING),o(i)}),[i]),P.useEffect((()=>{if(se!=null&&y!=null){const a=se.split("-");if(a.length===2){const A=Ds(Number(a[0])),c=Number(a[1]),t=ys(`01-${A<10?`0${A}`:A}-${c}`,Ae.getLocalizedStrings().dateFormat.analytics.DDDashMMDashYYYY),d=fs();t.isAfter(d,"month")===!1?D(Cs(y,{month:A,year:c})):N(`/${i}/month_end_close_checks/review`)}}}),[se,i,y]),P.useEffect((()=>{L||(we(!0),U(F.TENANT_FETCHING))}),[L,Z,ie,j,D,f]),P.useLayoutEffect((()=>{!vs(ie,Z)&&f.isSignedIn()&&(U(F.TENANT_FETCHING),(function(a,A,c,t){if(Re(A?.userId,A?.zeniSessionId,a.tenantId),c($s(!0)),c(ge(a.tenantId)),a.tenantId!=null&&_.clearTenant(a.tenantId),a.tenantId!=null){const d=f.getSignedInUserTenantWithId(a.tenantId);t&&Ae.updateAppLocaleID(it(t)),d?.tenantEmailDomain!=null&&f.saveActiveTenantDomainForUser(d?.tenantEmailDomain)}a.userId!=null?ne.identify(a.userId,{tenant_id:a.tenantId}):ne.resetUserIdentity()})(Z,j,D,qe))}),[y]),P.useEffect((()=>{f.isSignedIn()&&(U(F.TENANT_FETCHING),(function(a,A,c,t,d,q,S){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){S(ge(t));const K=f.getSignedInUserTenantWithId(t);K?.tenantEmailDomain!=null&&f.saveActiveTenantDomainForUser(K?.tenantEmailDomain),Re(d?.userId,d?.zeniSessionId,t),_.shouldFetchExcludedResources(t)&&(_.markExcludedResourcesFetchStarted(t),S(Ie(d.userId,t))),_.shouldFetchConnections(t)&&(_.markConnectionsFetchStarted(t),S(je(d.userId,t)))}else Y&&ms&&_.shouldFetchExcludedResources(t)&&(_.markExcludedResourcesFetchStarted(t),S(Ie(d.userId,t))),Y&&_s&&_.shouldFetchConnections(t)&&(_.markConnectionsFetchStarted(t),S(je(d.userId,t)));if(Y){ne.identify(d.userId,{tenant_id:t});const K=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),S(Gs(d.userId,t,d.zeniSessionId))),K&&(a==="Not-Started"||a==="Error")&&_.shouldFetchAllTenants()&&(_.markAllTenantsFetchStarted(),S(xe(d.userId,d.zeniSessionId)))}})(T,p,r,y,j,U,D))}),[y,p]),P.useEffect((()=>{f.isSignedIn()&&T==="Completed"&&z.tenantsBaseInOrder.length>0&&(V(F.TENANT_FETCHING),f.saveSignedInUserTenants(Us(z.tenantsBaseInOrder)),j!=null&&be(j,r,k,void 0,z.tenantsBaseInOrder))}),[z,T,r,j]),P.useEffect((()=>{p==="In-Progress"&&U(F.TENANT_FETCHING),p!=="Completed"&&p!=="Error"||(p==="Completed"&&y!=null?(v(),_.markActiveTenantFetchCompleted(y)):p==="Error"&&y!=null&&(_.markActiveTenantFetchFailed(y),V(F.TENANT_FETCHING),V(F.TENANT_SWITCHING))),T!=="Completed"&&T!=="Error"||(T==="Completed"?_.markAllTenantsFetchCompleted():T==="Error"&&_.markAllTenantsFetchFailed())}),[p,T,y,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 O=r?.userRole!=null&&Os(r?.userRole),{isFeatureEnabled:Ye}=H(B.isReferralFeatureEnabled),{isFeatureEnabled:Ke}=H(B.isAccrualEnabled),We=r?.userRole!=null&&r.userRole.includes("charge_card_user"),Je=r?.userRole!=null&&r.userRole.includes("charge_card_admin"),w=r?.userRole!=null&&pe(r.userRole),ue=r?.company==null||r.company.featuresActivationInfo?.isBillPayFeatureEnabled&&!O,de=!Se&&!O,Xe=Ps(h?.loggedInUserRoleMap),Qe=r.externalConnections?.accounting[0]?.isValid,es=r.externalConnections?.fetchState==="Completed",te=r.company?.companyOnboardingInfo.isOnboardingCompleted,ce=r?.company==null||r.company.featuresActivationInfo?.isReimbursementFeatureEnabled&&!O,me=ce&&ws(h?.loggedInUserRoleMap),_e=Fe&&!O,ss=Le&&!O,ts=ue&&Fs(h?.loggedInUserRoleMap),ns=de&&Ls(h?.loggedInUserRoleMap),as=_e&&ks(h?.loggedInUserRoleMap),os=Vs(h?.loggedInUserRoleMap),rs=Hs(h?.loggedInUserRoleMap),is=Ss(h?.loggedInUserRoleMap),ls=Bs(h?.loggedInUserRoleMap),us=Ns(h?.loggedInUserRoleMap),x=Ms(h?.loggedInUserRoleMap),R=Zs(h?.loggedInUserRoleMap),Ee=ue&&x,he=ce&&R,g=_e&&is,I=ss&&ls,m=de&&us,ds=r.excludedResources?.resources?.find((a=>a.resource==="/invites"))!=null||Ge===!0||Xe===!0||os===!0||rs===!0;return f.isSignedIn()?y==null?T==="Completed"?e.jsx(u,{to:"/",replace:!0,state:{...G.state,message:"...",origin:G.pathname}}):(j!=null&&T!=="In-Progress"&&D(xe(j.userId,j.zeniSessionId)),null):p!=="In-Progress"&&p!=="Not-Started"||T==="Completed"?(te===!0||W&&!ee)&&es&&Qe!==!0&&E===!1&&X===!1&&re===!1?(o(void 0),e.jsx(u,{to:"/connection/auth",replace:!0})):!L||re!==!0||te!==!0||ee||W?!L||te!==!1||ee||W?L&&r?.userRole&&E!=null&&X!=null&&i!=null&&Object.keys(h.loggedInUserRoleMap).length>0?e.jsx(Ws,{children:e.jsxs(n,{element:e.jsx(ot,{}),children:[e.jsx(n,{path:"/",element:e.jsx(Lt,{isDashboardAccess:w,showZeniAccountRoute:g,isUserHasBillPayAccess:x,isUserHasReimbursementAccess:R,showTreasuryRoute:I,isTenantBankingOnly:E,isTenantCardsOnly:X,showChargeCardRoute:m})}),e.jsx(n,{path:"dashboard/*",element:w?e.jsx(It,{}):e.jsx(C,{showZeniAccountRoute:g,isUserHasBillPayAccess:x,isUserHasReimbursementAccess:R,showTreasuryRoute:I,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"reports/*",element:w?e.jsx(_t,{}):e.jsx(C,{showZeniAccountRoute:g,isUserHasBillPayAccess:x,isUserHasReimbursementAccess:R,showTreasuryRoute:I,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"people/*",element:ds||w?e.jsx(ht,{}):e.jsx(C,{showZeniAccountRoute:g,isUserHasBillPayAccess:x,isUserHasReimbursementAccess:R,showTreasuryRoute:I,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"forecast/*",element:w?e.jsx(pt,{}):e.jsx(C,{showZeniAccountRoute:g,isUserHasBillPayAccess:x,isUserHasReimbursementAccess:R,showTreasuryRoute:I,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"onboarding/*",element:e.jsx(xt,{})}),e.jsx(n,{path:"transaction/*",element:w&&O===!1||We||Je?e.jsx(gt,{}):e.jsx(C,{showZeniAccountRoute:g,isUserHasBillPayAccess:x,isUserHasReimbursementAccess:R,showTreasuryRoute:I,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"transactions/*",element:w&&O===!1?e.jsx(Dt,{}):e.jsx(C,{showZeniAccountRoute:g,isUserHasBillPayAccess:x,isUserHasReimbursementAccess:R,showTreasuryRoute:I,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"customer/*",element:w&&O===!1?e.jsx(Ce,{entityType:"customer"}):e.jsx(C,{showZeniAccountRoute:g,isUserHasBillPayAccess:x,isUserHasReimbursementAccess:R,isTenantBankingOnly:E,showTreasuryRoute:I,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"vendor/*",element:w&&O===!1?e.jsx(Ce,{entityType:"vendor"}):e.jsx(C,{showZeniAccountRoute:g,isUserHasBillPayAccess:x,isUserHasReimbursementAccess:R,showTreasuryRoute:I,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(C,{showZeniAccountRoute:g,isUserHasBillPayAccess:x,isUserHasReimbursementAccess:R,showTreasuryRoute:I,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"checking/*",element:g?e.jsx(At,{}):e.jsx(b,{})}),e.jsx(n,{path:"treasury/*",element:I?e.jsx(bt,{}):e.jsx(b,{})}),e.jsx(n,{path:"performance",element:J===!0?e.jsx(Ct,{}):e.jsx(Pe,{tenantEmailDomain:i})}),e.jsx(n,{path:"month_end_close_checks/review/*",element:J===!0&&O===!1?e.jsx(vt,{}):e.jsx(Pe,{tenantEmailDomain:i})}),e.jsx(n,{path:"expense-automation/actual-matching/:matchId",element:J===!0&&O===!1&&Ke===!0?e.jsx(Ut,{}):e.jsx(b,{})}),e.jsx(n,{path:"notifications/*",element:e.jsx(ft,{})}),e.jsx(n,{path:"vendors/*",element:$e?e.jsx(Rt,{}):e.jsx(b,{})}),e.jsx(n,{path:"bill/*",element:Ee?e.jsx(ve,{}):e.jsx(C,{showZeniAccountRoute:g,isUserHasBillPayAccess:x,isUserHasReimbursementAccess:R,showTreasuryRoute:I,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"bills/*",element:Ee?e.jsx(ve,{}):e.jsx(C,{showZeniAccountRoute:g,isUserHasBillPayAccess:x,isUserHasReimbursementAccess:R,showTreasuryRoute:I,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"reimbursement/*",element:he?e.jsx(Ue,{}):e.jsx(C,{showZeniAccountRoute:g,isUserHasBillPayAccess:x,isUserHasReimbursementAccess:R,showTreasuryRoute:I,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"reimbursements/*",element:he?e.jsx(Ue,{}):e.jsx(C,{showZeniAccountRoute:g,isUserHasBillPayAccess:x,isUserHasReimbursementAccess:R,showTreasuryRoute:I,isTenantBankingOnly:E,showChargeCardRoute:m,tenantEmailDomain:i})}),e.jsx(n,{path:"settings/*",element:Be?e.jsx(jt,{hasAdminLevelAccess:me}):e.jsx(b,{})}),e.jsx(n,{path:"invoicing/*",element:Me&&Ze?e.jsx(Tt,{}):e.jsx(b,{})}),e.jsx(n,{path:"cards/ask",element:m&&M?e.jsx(Oe,{isFileUploadEnabled:Q}):e.jsx(b,{})}),e.jsx(n,{path:"cards/ask/:session_id",element:m&&M?e.jsx(Oe,{isFileUploadEnabled:Q}):e.jsx(b,{})}),e.jsx(n,{path:"cards/*",element:m?e.jsx(yt,{}):e.jsx(b,{})}),e.jsx(n,{path:"rewards/*",element:Ye?e.jsx(Ot,{}):e.jsx(b,{})}),e.jsx(n,{path:"/ai-cfo",element:M?e.jsx(u,{to:"explore"}):e.jsx(b,{})}),e.jsx(n,{path:"/ai-cfo/",element:M?e.jsx(u,{to:"explore"}):e.jsx(b,{})}),e.jsx(n,{path:"/ai-cfo/:session_id",element:M?e.jsx(wt,{isFileUploadEnabled:Q}):e.jsx(b,{})}),e.jsx(n,{path:"*",element:e.jsx(b,{})})]})}):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:{...G.state,message:"...",origin:G.pathname}}))}},Symbol.toStringTag,{value:"Module"}));export{C as F,$t as S};
|