@zeniai/web-app-ui 5.3.94-dev → 5.3.95-dev

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (121) hide show
  1. package/dist/assets/{AccountMappingScreen-DaAsvWlG.js → AccountMappingScreen-CJpxPjym.js} +2 -2
  2. package/dist/assets/{ActualMatchingMatchDetailScreen-DsOtbvkM.js → ActualMatchingMatchDetailScreen-BI1Xbj3L.js} +1 -1
  3. package/dist/assets/AddressRoutes-27wvZSFH.js +1 -0
  4. package/dist/assets/{AddressScreen-C0JLhAcE.js → AddressScreen-Ce6wpOqL.js} +1 -1
  5. package/dist/assets/{AiCfoScreen-BUHwXAf6.js → AiCfoScreen-baKqq38G.js} +1 -1
  6. package/dist/assets/{AppDrawer-vbC-QV57.js → AppDrawer-BAy3i2Dk.js} +1 -1
  7. package/dist/assets/{BillPayApprovalRoutes-DzF0eyUE.js → BillPayApprovalRoutes-BLLQGNfF.js} +1 -1
  8. package/dist/assets/{BillPayRoutes-Bi056p3z.js → BillPayRoutes-BF0qZi8Q.js} +1 -1
  9. package/dist/assets/{BusinessVerificationPageScreen-D1nbOYUs.js → BusinessVerificationPageScreen-B6gKgGKZ.js} +2 -2
  10. package/dist/assets/{CardsAiCfoScreen-CfZl8Gyx.js → CardsAiCfoScreen-495-iwbX.js} +1 -1
  11. package/dist/assets/{ChargeCardRoutes-S3N8oI1a.js → ChargeCardRoutes-CsLMN32g.js} +6 -6
  12. package/dist/assets/{CompanyPassportScreen-Cb0WDItw.js → CompanyPassportScreen-DFOWHlG6.js} +1 -1
  13. package/dist/assets/{ConnectionAuthScreen-DscrSY_4.js → ConnectionAuthScreen-DcGlWxyf.js} +1 -1
  14. package/dist/assets/CustomerOnboardingAuthScreen-Da1wSVu0.js +1 -0
  15. package/dist/assets/{CustomerOnboardingRoutes-Q5YqE-pG.js → CustomerOnboardingRoutes-7Bwv09dV.js} +3 -3
  16. package/dist/assets/{DashboardRoutes-CHLUwZtv.js → DashboardRoutes-s3deN1Di.js} +1 -1
  17. package/dist/assets/{DefaultTenantHome-BSW3FKbq.js → DefaultTenantHome-Bi2eWO-I.js} +1 -1
  18. package/dist/assets/{DomesticWireDetailScreen-BqNLFPCz.js → DomesticWireDetailScreen-CVJejZP9.js} +3 -3
  19. package/dist/assets/{DrawerScreen-CjvLDWWa.js → DrawerScreen-Bev9sxN6.js} +1 -1
  20. package/dist/assets/{EntityDetailRoutes-CiuhVFP6.js → EntityDetailRoutes-DTd2OX4g.js} +1 -1
  21. package/dist/assets/{ExpenseAutomationRoutes-yHkHWhCB.js → ExpenseAutomationRoutes-BNvZ1Bwi.js} +1 -1
  22. package/dist/assets/{FeaturePreviewScreen-t6-81tB3.js → FeaturePreviewScreen-DETqyCpy.js} +1 -1
  23. package/dist/assets/{HubSpotOAuthCallbackScreen-6v8VBEj0.js → HubSpotOAuthCallbackScreen-LgF5qdxr.js} +1 -1
  24. package/dist/assets/{InboxNotificationsProvider--Aami2sh.js → InboxNotificationsProvider-LdTK3V9o.js} +1 -1
  25. package/dist/assets/{InvoicingRoutes-DYvbJYG6.js → InvoicingRoutes-Mbynj2-j.js} +1 -1
  26. package/dist/assets/{MagicLinkRoutes-C2OazRqD.js → MagicLinkRoutes-BAL4OpO8.js} +2 -2
  27. package/dist/assets/{MagicLinkSignInScreen-Cn6GsNEp.js → MagicLinkSignInScreen-BIY2mGLo.js} +1 -1
  28. package/dist/assets/{MobileAppDrawer-CPwvCIYa.js → MobileAppDrawer-CsfNveW9.js} +1 -1
  29. package/dist/assets/NotFoundScreen-DDA41Ig7.js +1 -0
  30. package/dist/assets/{NotificationRoutes-aekj_lXX.js → NotificationRoutes-_8GAMr1Q.js} +1 -1
  31. package/dist/assets/{OAuthConsentScreen-xUzU6tqX.js → OAuthConsentScreen-DrAajreS.js} +1 -1
  32. package/dist/assets/{PandLWithForecastRoutes-DbBbI4iD.js → PandLWithForecastRoutes-BoihVLwz.js} +1 -1
  33. package/dist/assets/{PaymentLinkScreen-wDbMp6EU.js → PaymentLinkScreen-QPSeahMe.js} +1 -1
  34. package/dist/assets/{PeopleRoutes-DLFd4iV8.js → PeopleRoutes-BJ_Rsbpd.js} +3 -3
  35. package/dist/assets/{PerformanceRoutes-DgAZpNgm.js → PerformanceRoutes-BU_ssv__.js} +1 -1
  36. package/dist/assets/{Preview-9JjGFG_v.js → Preview-S6mtKRFK.js} +1 -1
  37. package/dist/assets/{QBOConnectionScreen-Dn2zy1VD.js → QBOConnectionScreen-DMcsRcZG.js} +1 -1
  38. package/dist/assets/{ReimbursementApprovalRoutes-y4qFEQsq.js → ReimbursementApprovalRoutes-c_eicF80.js} +1 -1
  39. package/dist/assets/{ReimbursementApprovalRuleDetailScreen-D0_gOHEu.js → ReimbursementApprovalRuleDetailScreen-NQbCpzYz.js} +1 -1
  40. package/dist/assets/{ReimbursementRoutes-BnId3F39.js → ReimbursementRoutes-BVOB8GHt.js} +4 -4
  41. package/dist/assets/{ReportsRoutes-DbeoJpVK.js → ReportsRoutes-BaXWnnZZ.js} +1 -1
  42. package/dist/assets/RewardsRoutes-Dr_V6CBY.js +1 -0
  43. package/dist/assets/{ScheduleDetailsPrepaidExpensesScreen-ISVWQj5Q.js → ScheduleDetailsPrepaidExpensesScreen-OdknWRFf.js} +1 -1
  44. package/dist/assets/ScreenRoutes-MAHnboyU.js +2 -0
  45. package/dist/assets/{SettingsRoutes-tCVJI0Fg.js → SettingsRoutes-CwikuwVk.js} +6 -6
  46. package/dist/assets/{SetupPagesScreen-fiQdFdcd.js → SetupPagesScreen-B0b-Fgla.js} +1 -1
  47. package/dist/assets/{SignInScreen-DiXsocpm.js → SignInScreen-DYTURHhx.js} +1 -1
  48. package/dist/assets/{SignOutScreen-BiwH5m6t.js → SignOutScreen-Be_uJc5B.js} +1 -1
  49. package/dist/assets/{TaskListScreen-BgIlrtZe.js → TaskListScreen-adKZru26.js} +2 -2
  50. package/dist/assets/{TaskRoutes-BNd4w4Bb.js → TaskRoutes-B74sfUtJ.js} +2 -2
  51. package/dist/assets/TransactionDetailRoutes-DRKjV_CD.js +1 -0
  52. package/dist/assets/{TransactionDetailScreen-BkV8Yidz.js → TransactionDetailScreen-CS9DS32g.js} +1 -1
  53. package/dist/assets/{TransactionListRoutes-Dy1QqSzY.js → TransactionListRoutes-BIufDhIc.js} +1 -1
  54. package/dist/assets/{TreasuryRoutes-Caywh1RR.js → TreasuryRoutes-Bt27xnQK.js} +5 -5
  55. package/dist/assets/{VendorsRoutes-g-EHYY2y.js → VendorsRoutes-ZMV0CecT.js} +1 -1
  56. package/dist/assets/{WiseConfirmationScreen-C46GF-q1.js → WiseConfirmationScreen-ZJ4gewaT.js} +1 -1
  57. package/dist/assets/{ZeniAccountRoutes-B6_vZk4u.js → ZeniAccountRoutes-DV3rsGFn.js} +9 -9
  58. package/dist/assets/{ZeniAccountStatementScreen-BjT0Ja6v.js → ZeniAccountStatementScreen-B-L8iMJL.js} +1 -1
  59. package/dist/assets/{accountMappingHelper-jzkx0QiS.js → accountMappingHelper-1wM-u5pk.js} +1 -1
  60. package/dist/assets/{analytics-BE49_JfE.js → analytics-DhotUQIQ.js} +1 -1
  61. package/dist/assets/{analyticsHelper-DZVn8KPX.js → analyticsHelper-BkudU6tc.js} +1 -1
  62. package/dist/assets/{core-R1zvmcG1.js → core-B1R51LGS.js} +1 -1
  63. package/dist/assets/{decodeURIComponentSafe-D4d600vS.js → decodeURIComponentSafe-sNmSv15A.js} +1 -1
  64. package/dist/assets/{dnd-LSyMQh_7.js → dnd-CBDtHD8g.js} +1 -1
  65. package/dist/assets/{empty-BfAyW5rR.js → empty-1ZFG33kK.js} +1 -1
  66. package/dist/assets/{empty-CtFP9XJw.js → empty-DDVSRnUK.js} +1 -1
  67. package/dist/assets/{emptyVideoElement-DYu9DRPv.js → emptyVideoElement-Cmgjsfjv.js} +1 -1
  68. package/dist/assets/{epic-DI5821Fd.js → epic--rTGN1ZF.js} +2 -2
  69. package/dist/assets/{expenseAutomationHelper-BlCRyV8f.js → expenseAutomationHelper-Bb1c_nBx.js} +1 -1
  70. package/dist/assets/{getLocaleForTenant-DZAPKjbH.js → getLocaleForTenant-Nj4zPyxj.js} +1 -1
  71. package/dist/assets/{index-IzH6rGRi.js → index-4kuDVIdn.js} +1 -1
  72. package/dist/assets/{index-ARkELHLC.js → index-B4fRbcqK.js} +1 -1
  73. package/dist/assets/{index-LeoAhFsn.js → index-BgCxp-PW.js} +1 -1
  74. package/dist/assets/{index-CooR7eTi.js → index-C5-029-z.js} +1 -1
  75. package/dist/assets/{index-D7BxdwHb.js → index-CmqWYVaK.js} +1 -1
  76. package/dist/assets/{index-DhHwwWlj.js → index-DUjhchTx.js} +1 -1
  77. package/dist/assets/{index-B-tyZK_L.js → index-DaxOKW2h.js} +2 -2
  78. package/dist/assets/{index-Cvus_VBr.js → index-Dp_Uc3gy.js} +1704 -1703
  79. package/dist/assets/{lexical-BG-nDmQN.js → lexical-Cft6chCX.js} +1 -1
  80. package/dist/assets/{liveblocks-DOdRxZ-H.js → liveblocks-BYqz0SWy.js} +1 -1
  81. package/dist/assets/{lottie-Z_NAxrmn.js → lottie-C4orech3.js} +1 -1
  82. package/dist/assets/{mui-ZKvbmPSP.js → mui-D-_RYGgU.js} +1 -1
  83. package/dist/assets/{pathToGoBack-DioXT2-t.js → pathToGoBack-DZ8Lgq0-.js} +1 -1
  84. package/dist/assets/{pdf-_w1KRTSP.js → pdf-DFgrdLB6.js} +3 -3
  85. package/dist/assets/{pdf-lib-Ctu1umZQ.js → pdf-lib-2bJZTByw.js} +1 -1
  86. package/dist/assets/{plaid-tDbexfSh.js → plaid-B0PWXAfV.js} +1 -1
  87. package/dist/assets/{pusher-9ZSIvZ4p.js → pusher-F6-lSe0Y.js} +1 -1
  88. package/dist/assets/{react-DofVj9Pu.js → react-BwTGo4yk.js} +1 -1
  89. package/dist/assets/{react-dAAwh8YD.js → react-CB4vP-t_.js} +1 -1
  90. package/dist/assets/{react-V1QPqCMR.js → react-CM16A7NA.js} +1 -1
  91. package/dist/assets/{react-DLfHBjuE.js → react-DUg8Ws81.js} +1 -1
  92. package/dist/assets/{react-CNq4EJHI.js → react-D_SPu3Ud.js} +1 -1
  93. package/dist/assets/{react-BwaH8vjo.js → react-DyLpv-r1.js} +1 -1
  94. package/dist/assets/{recharts-UmMlzZlF.js → recharts-By7FVN8f.js} +1 -1
  95. package/dist/assets/{routePaths-ME1g30cL.js → routePaths-BALvGXpp.js} +1 -1
  96. package/dist/assets/{sentry-DvoFEQx8.js → sentry-DjmIorbX.js} +1 -1
  97. package/dist/assets/{stripSplatSuffix-BaAbZcaB.js → stripSplatSuffix-B5IwbFj2.js} +1 -1
  98. package/dist/assets/{url-C4ptnP9R.js → url-B8llcdww.js} +1 -1
  99. package/dist/assets/{url-CxALZHMf.js → url-SyxPcinx.js} +1 -1
  100. package/dist/assets/{useActualMatchingMatchDetail-CuSDY9wd.js → useActualMatchingMatchDetail-CuDY29_K.js} +1 -1
  101. package/dist/assets/{useAiCfoDashboardSuggestedQuestionsChips-B-4Cv_Hc.js → useAiCfoDashboardSuggestedQuestionsChips-B5pmnrb8.js} +1 -1
  102. package/dist/assets/useAskAiCfoHostNavButtonProps-DWkTPomv.js +1 -0
  103. package/dist/assets/{useChargeCardPusherEvents-Cd0ovQSz.js → useChargeCardPusherEvents-Ce-wULUB.js} +1 -1
  104. package/dist/assets/{useDeviceId-DiDVtEd4.js → useDeviceId-D6nAUa-g.js} +1 -1
  105. package/dist/assets/{useEmailConnectResultRefresh-neeIEIrq.js → useEmailConnectResultRefresh-CQX3dx0q.js} +1 -1
  106. package/dist/assets/{useInitialThreadRequest-mCNzqzEf.js → useInitialThreadRequest-BaIZPAUw.js} +1 -1
  107. package/dist/assets/useTaskManagerAccess-CFJAytRv.js +1 -0
  108. package/dist/assets/{useTaskManagerPusherEvents-D1CY3bdf.js → useTaskManagerPusherEvents-B_vM_sss.js} +1 -1
  109. package/dist/assets/{utils-D06mHID-.js → utils-iOnDyQuG.js} +1 -1
  110. package/dist/assets/{withTransactionSidePanel-LlSL3tvn.js → withTransactionSidePanel-BuJ7rAhb.js} +2 -2
  111. package/dist/assets/{zeni-epic-state-Mdu-dKQU.js → zeni-epic-state-M9sMLOaG.js} +5 -5
  112. package/dist/index.html +1 -1
  113. package/package.json +3 -3
  114. package/dist/assets/AddressRoutes-DYRqLyFY.js +0 -1
  115. package/dist/assets/CustomerOnboardingAuthScreen-DZSTKSts.js +0 -1
  116. package/dist/assets/NotFoundScreen-BR0tBeJN.js +0 -1
  117. package/dist/assets/RewardsRoutes-CbVAxJ_Q.js +0 -1
  118. package/dist/assets/ScreenRoutes-BxsiowEM.js +0 -2
  119. package/dist/assets/TransactionDetailRoutes-BYsmhufD.js +0 -1
  120. package/dist/assets/useAskAiCfoHostNavButtonProps-D5Ew-Qzm.js +0 -1
  121. package/dist/assets/useTaskManagerAccess-CcPTnvTg.js +0 -1
@@ -1,4 +1,4 @@
1
- import{j as e}from"./liveblocks-DOdRxZ-H.js";import{h as L,g as U,u as P,i as V,j as y,N as D,l as M,n as xe,o as k}from"./core-R1zvmcG1.js";import{cw as N,fI as E,ZT as F,O$ as ae,OI as G,OJ as ne,ZV as Ie,P2 as Te,ZR as we,ZS as se,_5 as Ce,N3 as ke,CA as je,ZX as Ae,P9 as be,ZU as oe,de as H,Ha as re,d$ as ve,e0 as Ee,a0g as De,a0h as Le,OK as Ue,a0i as Pe,OL as Fe,OU as Be,bq as Re,bK as Oe,cH as Ve,bL as Me,cv as Ne,bu as _e,UR as $e,cu as ze}from"./zeni-epic-state-Mdu-dKQU.js";import{V as _,j as Ze,z as v,a6 as $,l as A,d4 as Ge,d5 as He,d6 as Z,_ as q,ao as qe,aq as Ke,Y as ie,$ as O,a9 as We,a5 as Je,d7 as Xe,ac as K,p as Ye,d8 as Qe,a2 as W,d9 as et,ag as tt,T as Y,da as at,g as nt}from"./index-Cvus_VBr.js";import{u as st,D as ot,n as R,S as rt}from"./mui-ZKvbmPSP.js";import it from"./NotFoundScreen-BR0tBeJN.js";import{S as Q}from"./SetupPagesScreen-fiQdFdcd.js";import{a as p}from"./sentry-DvoFEQx8.js";import{u as ct}from"./useAskAiCfoHostNavButtonProps-D5Ew-Qzm.js";import{u as lt}from"./useInitialThreadRequest-mCNzqzEf.js";import{M as ce}from"./MobileAppDrawer-CPwvCIYa.js";import{F as ut}from"./FeaturePreviewScreen-t6-81tB3.js";import{a as ee}from"./analyticsHelper-DZVn8KPX.js";import"./recharts-UmMlzZlF.js";import"./analytics-BE49_JfE.js";import"./plaid-tDbexfSh.js";import"./dnd-LSyMQh_7.js";import"./stripe-cKAAJElX.js";import"./lottie-Z_NAxrmn.js";import"./lexical-BG-nDmQN.js";import"./pdf-_w1KRTSP.js";import"./utils-D06mHID-.js";import"./BusinessVerificationPageScreen-D1nbOYUs.js";import"./routePaths-ME1g30cL.js";import"./InboxNotificationsProvider--Aami2sh.js";import"./useTaskManagerAccess-CcPTnvTg.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},a=new t.Error().stack;a&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[a]="01758bc6-e8c3-450b-9431-b465a560f9cd",t._sentryDebugIdIdentifier="sentry-dbid-01758bc6-e8c3-450b-9431-b465a560f9cd")}catch{}})();const dt=M((function(t,a){const{companyId:n}=a;return{treasurySetupView:F(t,n),analytics:A}}),(function(t,a){const{navigate:n,analytics:r,treasurySetupView:i}=a;return{onBackClick:()=>{n("../")},onNextClick:()=>{const o=i.fundAllocationLocalData;r.trackTreasuryPortfolioConfirm(o.riskScore,ee(o)),t(Te(!0))},onUpdateFundAllocation:o=>{r.trackTreasuryAllocationAction("update",ee(o)),t(Ie(o))}}}))(Ge);function pt(){const t=L(),a=U(),n=P(),{tenantEmailDomain:r}=V(),i=_(),o=y((w=>w.treasurySetupViewState.portfolioAllocationUpdateStatus?.fetchState)),m=Ze(o),s=N(i?.loggedInUserRoleMap),[d,c]=p.useState(!1),[S,I]=p.useState(!1),[l,u]=p.useState(!1),x=y((w=>E(w))),f=v.getSignedInUserTenant(r)?.companyId??x.companyId,C=v.getSignedInUser(),h=y((w=>F(w,f))),g=y((w=>w.treasurySetupViewState.fetchState)),j=y((w=>w.treasurySetupViewState.currentAllocation.fetchStatus?.fetchState)),T=y((w=>w.treasurySetupViewState.treasuryFundsDetails?.fetchStatus?.fetchState));if(C==null)throw Error("Can't access treasury portfolio allocation page without signing in...");if(p.useEffect((()=>{d||g!=="Not-Started"||f==null||(c(!0),n(ae(f,!0,!1)))}),[d,g,f,n]),p.useEffect((()=>{l||T!=="Not-Started"||f==null||(u(!0),n(G()))}),[l,T,f,n]),p.useEffect((()=>{S||j!=="Not-Started"||f==null||(I(!0),n(ne()))}),[S,j,f,n]),p.useEffect((()=>{m==="In-Progress"&&o==="Completed"&&t("../")}),[m,o,t]),x.companyTreasuryInfo?.info?.isTreasuryTOSAccepted===!1)return e.jsx(D,{to:"../promo"});const B=x.companyTreasuryInfo?.info?.isTreasuryTOSAccepted!==!0||g!=="Completed";return e.jsxs(e.Fragment,{children:[!B&&e.jsx($,{analytics:A,onLoad:()=>{}}),e.jsx(dt,{navigate:t,location:a,companyId:f,isEditMode:!0,isLoading:B,isReadOnly:!s,treasurySetupView:h,analytics:A})]})}const mt=M((function(t,a){const n=a.currentTenant?.companyId;return{plaidConnectionDetails:Ce(t,n,"zeni_treasury","treasury_setup").plaidConnectionDetails,treasurySetupView:F(t,n)}}),(function(t,a){const{navigate:n,transferDetails:r,treasurySetupView:i}=a,o=r.treasuryTransferMoneyLocalData,m=i.fundAllocationLocalData;return{onCancelClick:()=>{Z(a.analytics,"cancel",o,m,"Transfer"),t(se()),n("../")},onTransferClick:()=>{Z(a.analytics,"confirm",o,m,"Transfer"),t(be())},onSaveChangesToLocalStore:s=>{t(Ae(s))},onFetchLinkTokenClick:s=>{t(je("treasury_setup",s))},onEstablishConnectionClick:s=>{t(ke(s,a.currentTenant?.companyId,"treasury_setup","zeni_treasury"))}}}))(He),ft=({isFirstTransfer:t,isTransactionsLoaded:a})=>{const n=L(),{tenantEmailDomain:r}=V(),i=P(),[o,m]=p.useState(!1),[s,d]=p.useState(!1),[c,S]=p.useState(!1),[I,l]=p.useState(!1),u=y((T=>T.treasurySetupViewState.fetchState)),x=y((T=>T.treasurySetupViewState.treasuryFundsDetails?.fetchStatus?.fetchState)),f=y((T=>T.treasurySetupViewState.currentAllocation.fetchStatus?.fetchState)),C=y((T=>E(T))),h=v.getSignedInUserTenant(r)?.companyId??C.companyId,g=y((T=>we(T))),j=y((T=>F(T,h)));if(v.getSignedInUser()==null)throw Error("Can't access treasury transfer page without signing in...");return p.useEffect((()=>{s||u!=="Not-Started"||h==null||(d(!0),i(ae(h,!0,!1)))}),[s,u,h,i]),p.useEffect((()=>{c||x!=="Not-Started"||h==null||(S(!0),i(G()))}),[c,x,h,i]),p.useEffect((()=>{I||f!=="Not-Started"||h==null||(l(!0),i(ne()))}),[I,f,h,i]),e.jsxs(e.Fragment,{children:[e.jsx($,{analytics:A,onLoad:()=>{}}),e.jsx(mt,{analytics:A,navigate:n,transferDetails:g,onAnotherTransferClick:()=>{m(!1),i(se())},currentTenant:C,treasurySetupView:j,showReviewContent:o,maxInsuredAmount:5e5,onReviewClick:()=>{Z(A,"review",g.treasuryTransferMoneyLocalData,j.fundAllocationLocalData,"Transfer"),m(!0)},isFirstTransfer:t,isTransactionsLoaded:a,setShowReviewContent:m,onBackClick:()=>{}})]})},yt=R.div`
1
+ import{j as e}from"./liveblocks-BYqz0SWy.js";import{h as L,g as U,u as P,i as V,j as y,N as D,l as M,n as xe,o as k}from"./core-B1R51LGS.js";import{cw as N,fI as E,ZT as F,O$ as ae,OI as G,OJ as ne,ZV as Ie,P2 as Te,ZR as we,ZS as se,_5 as Ce,N3 as ke,CA as je,ZX as be,P9 as Ae,ZU as oe,de as H,Ha as re,d$ as ve,e0 as Ee,a0g as De,a0h as Le,OK as Ue,a0i as Pe,OL as Fe,OU as Be,bq as Re,bK as Oe,cH as Ve,bL as Me,cv as Ne,bu as _e,UR as $e,cu as ze}from"./zeni-epic-state-M9sMLOaG.js";import{V as _,j as Ze,z as v,a6 as $,l as b,d4 as Ge,d5 as He,d6 as Z,_ as q,ao as qe,aq as Ke,c as ie,$ as O,a9 as We,a5 as Je,d7 as Xe,ac as K,p as Qe,d8 as Ye,a2 as W,d9 as et,ag as tt,T as Q,da as at,h as nt}from"./index-Dp_Uc3gy.js";import{u as st,D as ot,n as R,S as rt}from"./mui-D-_RYGgU.js";import it from"./NotFoundScreen-DDA41Ig7.js";import{S as Y}from"./SetupPagesScreen-B0b-Fgla.js";import{a as p}from"./sentry-DjmIorbX.js";import{u as ct}from"./useAskAiCfoHostNavButtonProps-DWkTPomv.js";import{u as lt}from"./useInitialThreadRequest-BaIZPAUw.js";import{M as ce}from"./MobileAppDrawer-CsfNveW9.js";import{F as ut}from"./FeaturePreviewScreen-DETqyCpy.js";import{a as ee}from"./analyticsHelper-BkudU6tc.js";import"./recharts-By7FVN8f.js";import"./analytics-DhotUQIQ.js";import"./plaid-B0PWXAfV.js";import"./dnd-CBDtHD8g.js";import"./stripe-cKAAJElX.js";import"./lottie-C4orech3.js";import"./lexical-Cft6chCX.js";import"./pdf-DFgrdLB6.js";import"./utils-iOnDyQuG.js";import"./BusinessVerificationPageScreen-B6gKgGKZ.js";import"./routePaths-BALvGXpp.js";import"./InboxNotificationsProvider-LdTK3V9o.js";import"./useTaskManagerAccess-CFJAytRv.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},a=new t.Error().stack;a&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[a]="db6b4b37-9e86-4b04-bf19-5cfc271be40f",t._sentryDebugIdIdentifier="sentry-dbid-db6b4b37-9e86-4b04-bf19-5cfc271be40f")}catch{}})();const dt=M((function(t,a){const{companyId:n}=a;return{treasurySetupView:F(t,n),analytics:b}}),(function(t,a){const{navigate:n,analytics:r,treasurySetupView:i}=a;return{onBackClick:()=>{n("../")},onNextClick:()=>{const o=i.fundAllocationLocalData;r.trackTreasuryPortfolioConfirm(o.riskScore,ee(o)),t(Te(!0))},onUpdateFundAllocation:o=>{r.trackTreasuryAllocationAction("update",ee(o)),t(Ie(o))}}}))(Ge);function pt(){const t=L(),a=U(),n=P(),{tenantEmailDomain:r}=V(),i=_(),o=y((w=>w.treasurySetupViewState.portfolioAllocationUpdateStatus?.fetchState)),m=Ze(o),s=N(i?.loggedInUserRoleMap),[d,c]=p.useState(!1),[S,I]=p.useState(!1),[l,u]=p.useState(!1),x=y((w=>E(w))),f=v.getSignedInUserTenant(r)?.companyId??x.companyId,C=v.getSignedInUser(),h=y((w=>F(w,f))),g=y((w=>w.treasurySetupViewState.fetchState)),j=y((w=>w.treasurySetupViewState.currentAllocation.fetchStatus?.fetchState)),T=y((w=>w.treasurySetupViewState.treasuryFundsDetails?.fetchStatus?.fetchState));if(C==null)throw Error("Can't access treasury portfolio allocation page without signing in...");if(p.useEffect((()=>{d||g!=="Not-Started"||f==null||(c(!0),n(ae(f,!0,!1)))}),[d,g,f,n]),p.useEffect((()=>{l||T!=="Not-Started"||f==null||(u(!0),n(G()))}),[l,T,f,n]),p.useEffect((()=>{S||j!=="Not-Started"||f==null||(I(!0),n(ne()))}),[S,j,f,n]),p.useEffect((()=>{m==="In-Progress"&&o==="Completed"&&t("../")}),[m,o,t]),x.companyTreasuryInfo?.info?.isTreasuryTOSAccepted===!1)return e.jsx(D,{to:"../promo"});const B=x.companyTreasuryInfo?.info?.isTreasuryTOSAccepted!==!0||g!=="Completed";return e.jsxs(e.Fragment,{children:[!B&&e.jsx($,{analytics:b,onLoad:()=>{}}),e.jsx(dt,{navigate:t,location:a,companyId:f,isEditMode:!0,isLoading:B,isReadOnly:!s,treasurySetupView:h,analytics:b})]})}const mt=M((function(t,a){const n=a.currentTenant?.companyId;return{plaidConnectionDetails:Ce(t,n,"zeni_treasury","treasury_setup").plaidConnectionDetails,treasurySetupView:F(t,n)}}),(function(t,a){const{navigate:n,transferDetails:r,treasurySetupView:i}=a,o=r.treasuryTransferMoneyLocalData,m=i.fundAllocationLocalData;return{onCancelClick:()=>{Z(a.analytics,"cancel",o,m,"Transfer"),t(se()),n("../")},onTransferClick:()=>{Z(a.analytics,"confirm",o,m,"Transfer"),t(Ae())},onSaveChangesToLocalStore:s=>{t(be(s))},onFetchLinkTokenClick:s=>{t(je("treasury_setup",s))},onEstablishConnectionClick:s=>{t(ke(s,a.currentTenant?.companyId,"treasury_setup","zeni_treasury"))}}}))(He),ft=({isFirstTransfer:t,isTransactionsLoaded:a})=>{const n=L(),{tenantEmailDomain:r}=V(),i=P(),[o,m]=p.useState(!1),[s,d]=p.useState(!1),[c,S]=p.useState(!1),[I,l]=p.useState(!1),u=y((T=>T.treasurySetupViewState.fetchState)),x=y((T=>T.treasurySetupViewState.treasuryFundsDetails?.fetchStatus?.fetchState)),f=y((T=>T.treasurySetupViewState.currentAllocation.fetchStatus?.fetchState)),C=y((T=>E(T))),h=v.getSignedInUserTenant(r)?.companyId??C.companyId,g=y((T=>we(T))),j=y((T=>F(T,h)));if(v.getSignedInUser()==null)throw Error("Can't access treasury transfer page without signing in...");return p.useEffect((()=>{s||u!=="Not-Started"||h==null||(d(!0),i(ae(h,!0,!1)))}),[s,u,h,i]),p.useEffect((()=>{c||x!=="Not-Started"||h==null||(S(!0),i(G()))}),[c,x,h,i]),p.useEffect((()=>{I||f!=="Not-Started"||h==null||(l(!0),i(ne()))}),[I,f,h,i]),e.jsxs(e.Fragment,{children:[e.jsx($,{analytics:b,onLoad:()=>{}}),e.jsx(mt,{analytics:b,navigate:n,transferDetails:g,onAnotherTransferClick:()=>{m(!1),i(se())},currentTenant:C,treasurySetupView:j,showReviewContent:o,maxInsuredAmount:5e5,onReviewClick:()=>{Z(b,"review",g.treasuryTransferMoneyLocalData,j.fundAllocationLocalData,"Transfer"),m(!0)},isFirstTransfer:t,isTransactionsLoaded:a,setShowReviewContent:m,onBackClick:()=>{}})]})},yt=R.div`
2
2
  display: flex;
3
3
  min-height: 100%;
4
4
  width: 100%;
@@ -6,7 +6,7 @@ import{j as e}from"./liveblocks-DOdRxZ-H.js";import{h as L,g as U,u as P,i as V,
6
6
  flex-direction: column;
7
7
  align-items: center;
8
8
  background-color: ${t=>t.theme.colors.grey4};
9
- `,gt={overlayWidth:new We(100,100,48)},St=M((function(t,a){const n=oe(t),{companyId:r}=a;return{treasuryDetail:n,treasurySetupView:F(t,r),downloadEndPoint:`${K.bankingMicroServiceBaseUrl}/1.0/treasury-account/statements?query={"statement_type":"tax_statement"}`}}),(function(t,a){const{navigate:n,currentTenant:r,location:i,handleDrawerToggle:o,analytics:m}=a,{tenantEmailDomain:s}=r;return{onSettingsClick:()=>{m.trackAccountsListPageClicked("Settings Icon"),n("setup")},onReloadTransactions:()=>{t(re(!0))},handleTreasuryOptionSelection:d=>{let c="page-not-found";d==="editPortfolio"?c=ht(s):d==="statements"?c=xt(s):d==="taxLetter"?c=It(s):d==="settings"&&(c=Tt(s));const S=Ye(i.state?.pathnameStackToGoBack,i.pathname);n(c,{state:{pathnameStackToGoBack:S}})},onColumnSortConfigChanged:(d,c)=>{t(De({uiState:{sortKey:d,sortOrder:c}}))},onTransferClick:()=>{n("./transfer")},onBackClick:()=>{n("../../")},onClickMenuIcon:()=>{o(!0)},onAutoTransferClick:()=>{n("../../checking/auto-transfer")}}}))(Xe);function z({isTransferDrawerOpen:t,isEditPortfolioDrawerOpen:a}){const n=U(),r=L(),i=P(),o=q(),m=st(),s=y((b=>E(b))),{tenantEmailDomain:d}=V(),c=s.companyId??v.getSignedInUserTenant(d)?.companyId,[S,I]=p.useState(!1),l=y((b=>oe(b))),u=l.fetchState,x=l.accountSummary?.totalBalance?.amount,f=y((b=>b.treasurySetupViewState.treasuryFundsDetails?.fetchStatus)),C=s.companyTreasuryInfo?.info?.businessVerificationStatus?.code==="verified",h=_(),g=!!s.companyTreasuryInfo?.info?.isTreasuryTOSAccepted,j=N(h?.loggedInUserRoleMap),T=H(h?.loggedInUserRoleMap),{areTenantIdsInSync:B}=qe();p.useEffect((()=>{u==="Not-Started"&&!S&&B&&(I(!0),i(re(!0)))}),[S,i,u,B]),p.useEffect((()=>{l.transactionsFetchState.fetchState==="Completed"&&l.transactions.length===0&&!n.pathname.includes("transfer")&&j&&r("./transfer")}),[l.transactionsFetchState.fetchState,l.transactions.length,n.pathname,j,r]);const w=()=>{r("..")},[le,ue]=p.useState(!1),J=b=>{ue(b)},{isAiCfoAccessEnabled:de,onAskAiCfoClick:pe}=ct({mobileExploreReferrer:"Treasury"});Ke({isDataReady:u==="Completed"});const{useFeatureGate:X}=ie(),{isFeatureEnabled:me}=X(O.isDebitCardFeatureEnabled),{isFeatureEnabled:fe}=X(O.isAutoTransferRuleEnabled),ye=lt(c,{clearParams:u==="Completed"&&f?.fetchState==="Completed"}),ge=ve(s),Se=Ee(me,s);if(ge===!0&&Se!==!0)return e.jsx(ut,{});if(C){const b=f?.fetchState!=="Completed"||l.accountSummaryFetchState.fetchState!=="Completed";return e.jsxs(e.Fragment,{children:[l.accountSummaryFetchState.fetchState==="Completed"&&f?.fetchState==="Completed"&&t===!1&&a===!1?e.jsx($,{analytics:A,onLoad:()=>{}}):null,e.jsx(ot,{onClose:w,anchor:"right",open:a||t,transitionDuration:250,PaperProps:{style:{width:gt.overlayWidth.valuePercentage(o),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:m.colors.black,opacity:.75,cursor:"pointer"}}},children:e.jsxs(wt,{onClick:he=>he.stopPropagation(),children:[t===!0?e.jsx(ft,{isFirstTransfer:l.transactions.length===0||x===0,isTransactionsLoaded:l.transactionsFetchState.fetchState!=="In-Progress"&&l.transactionsFetchState.fetchState!=="Not-Started"}):null,a===!0?e.jsx(pt,{}):null]})}),e.jsxs(yt,{windowSize:o,children:[e.jsx(ce,{isAppContentDrawerOpen:le,handleDrawerToggle:J}),e.jsx(St,{treasuryDetailsView:l,isAutoTransferRuleEnabled:fe,navigate:r,currentTenant:s,location:n,companyId:c,analytics:A,handleDrawerToggle:J,initialOpenThreadRequest:ye,isLoading:b,isAiCfoAccessEnabled:de,onAskAiCfoClick:pe})]})]})}return g&&j?e.jsx(D,{to:"../setup"}):s.companyTreasuryInfo?.info&&!g&&T?e.jsx(D,{to:"../promo",state:n.state}):e.jsx(Je,{fetchState:"In-Progress",style:{backgroundColor:m.colors.grey5}})}const ht=t=>`/${t}/treasury/edit-portfolio`,xt=t=>`/${t}/treasury/statements`,It=t=>`/${t}/treasury/tax-letter`,Tt=t=>`/${t}/treasury/setup`,wt=R(rt)`
9
+ `,gt={overlayWidth:new We(100,100,48)},St=M((function(t,a){const n=oe(t),{companyId:r}=a;return{treasuryDetail:n,treasurySetupView:F(t,r),downloadEndPoint:`${K.bankingMicroServiceBaseUrl}/1.0/treasury-account/statements?query={"statement_type":"tax_statement"}`}}),(function(t,a){const{navigate:n,currentTenant:r,location:i,handleDrawerToggle:o,analytics:m}=a,{tenantEmailDomain:s}=r;return{onSettingsClick:()=>{m.trackAccountsListPageClicked("Settings Icon"),n("setup")},onReloadTransactions:()=>{t(re(!0))},handleTreasuryOptionSelection:d=>{let c="page-not-found";d==="editPortfolio"?c=ht(s):d==="statements"?c=xt(s):d==="taxLetter"?c=It(s):d==="settings"&&(c=Tt(s));const S=Qe(i.state?.pathnameStackToGoBack,i.pathname);n(c,{state:{pathnameStackToGoBack:S}})},onColumnSortConfigChanged:(d,c)=>{t(De({uiState:{sortKey:d,sortOrder:c}}))},onTransferClick:()=>{n("./transfer")},onBackClick:()=>{n("../../")},onClickMenuIcon:()=>{o(!0)},onAutoTransferClick:()=>{n("../../checking/auto-transfer")}}}))(Xe);function z({isTransferDrawerOpen:t,isEditPortfolioDrawerOpen:a}){const n=U(),r=L(),i=P(),o=q(),m=st(),s=y((A=>E(A))),{tenantEmailDomain:d}=V(),c=s.companyId??v.getSignedInUserTenant(d)?.companyId,[S,I]=p.useState(!1),l=y((A=>oe(A))),u=l.fetchState,x=l.accountSummary?.totalBalance?.amount,f=y((A=>A.treasurySetupViewState.treasuryFundsDetails?.fetchStatus)),C=s.companyTreasuryInfo?.info?.businessVerificationStatus?.code==="verified",h=_(),g=!!s.companyTreasuryInfo?.info?.isTreasuryTOSAccepted,j=N(h?.loggedInUserRoleMap),T=H(h?.loggedInUserRoleMap),{areTenantIdsInSync:B}=qe();p.useEffect((()=>{u==="Not-Started"&&!S&&B&&(I(!0),i(re(!0)))}),[S,i,u,B]),p.useEffect((()=>{l.transactionsFetchState.fetchState==="Completed"&&l.transactions.length===0&&!n.pathname.includes("transfer")&&j&&r("./transfer")}),[l.transactionsFetchState.fetchState,l.transactions.length,n.pathname,j,r]);const w=()=>{r("..")},[le,ue]=p.useState(!1),J=A=>{ue(A)},{isAiCfoAccessEnabled:de,onAskAiCfoClick:pe}=ct({mobileExploreReferrer:"Treasury"});Ke({isDataReady:u==="Completed"});const{useFeatureGate:X}=ie(),{isFeatureEnabled:me}=X(O.isDebitCardFeatureEnabled),{isFeatureEnabled:fe}=X(O.isAutoTransferRuleEnabled),ye=lt(c,{clearParams:u==="Completed"&&f?.fetchState==="Completed"}),ge=ve(s),Se=Ee(me,s);if(ge===!0&&Se!==!0)return e.jsx(ut,{});if(C){const A=f?.fetchState!=="Completed"||l.accountSummaryFetchState.fetchState!=="Completed";return e.jsxs(e.Fragment,{children:[l.accountSummaryFetchState.fetchState==="Completed"&&f?.fetchState==="Completed"&&t===!1&&a===!1?e.jsx($,{analytics:b,onLoad:()=>{}}):null,e.jsx(ot,{onClose:w,anchor:"right",open:a||t,transitionDuration:250,PaperProps:{style:{width:gt.overlayWidth.valuePercentage(o),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:m.colors.black,opacity:.75,cursor:"pointer"}}},children:e.jsxs(wt,{onClick:he=>he.stopPropagation(),children:[t===!0?e.jsx(ft,{isFirstTransfer:l.transactions.length===0||x===0,isTransactionsLoaded:l.transactionsFetchState.fetchState!=="In-Progress"&&l.transactionsFetchState.fetchState!=="Not-Started"}):null,a===!0?e.jsx(pt,{}):null]})}),e.jsxs(yt,{windowSize:o,children:[e.jsx(ce,{isAppContentDrawerOpen:le,handleDrawerToggle:J}),e.jsx(St,{treasuryDetailsView:l,isAutoTransferRuleEnabled:fe,navigate:r,currentTenant:s,location:n,companyId:c,analytics:b,handleDrawerToggle:J,initialOpenThreadRequest:ye,isLoading:A,isAiCfoAccessEnabled:de,onAskAiCfoClick:pe})]})]})}return g&&j?e.jsx(D,{to:"../setup"}):s.companyTreasuryInfo?.info&&!g&&T?e.jsx(D,{to:"../promo",state:n.state}):e.jsx(Je,{fetchState:"In-Progress",style:{backgroundColor:m.colors.grey5}})}const ht=t=>`/${t}/treasury/edit-portfolio`,xt=t=>`/${t}/treasury/statements`,It=t=>`/${t}/treasury/tax-letter`,Tt=t=>`/${t}/treasury/setup`,wt=R(rt)`
10
10
  display: flex;
11
11
  min-height: 100%;
12
12
  flex-direction: column;
@@ -18,7 +18,7 @@ import{j as e}from"./liveblocks-DOdRxZ-H.js";import{h as L,g as U,u as P,i as V,
18
18
  flex-direction: column;
19
19
  align-items: center;
20
20
  background-color: ${t=>t.theme.colors.grey4};
21
- `;function kt(){const t=L(),a=P(),n=q(),r=U(),i=`${K.bankingMicroServiceBaseUrl}/1.0/treasury-account`,[o,m]=p.useState(!1),s=y((u=>Le(u)));p.useEffect((()=>{o||s.fetchState!=="Not-Started"||(m(!0),a(Ue(!1)))}),[o,s.fetchState,a]);const d=v.getSignedInUser(),c=y((u=>E(u))),S={userId:d?.userId??"",sessionId:d?.zeniSessionId??"",tenantId:c.tenantId??""},I=c.company?.companyInfo.companyLegalName??c.companyName;if(d==null)throw Error("Can't access statements page without signing in...");const l=s.fetchState!=="Completed";return e.jsx(Ct,{windowSize:n,children:e.jsx(Qe,{currentTenantCompanyName:I,statementListView:s,isLoading:l,onBackClick:()=>{const u=W(r.state?.pathnameStackToGoBack),x=u.poppedPathname??"..";t(x,{state:{pathnameStackToGoBack:u.newStack}})},authParams:S,downloadEndPoint:i})})}const jt=R.div`
21
+ `;function kt(){const t=L(),a=P(),n=q(),r=U(),i=`${K.bankingMicroServiceBaseUrl}/1.0/treasury-account`,[o,m]=p.useState(!1),s=y((u=>Le(u)));p.useEffect((()=>{o||s.fetchState!=="Not-Started"||(m(!0),a(Ue(!1)))}),[o,s.fetchState,a]);const d=v.getSignedInUser(),c=y((u=>E(u))),S={userId:d?.userId??"",sessionId:d?.zeniSessionId??"",tenantId:c.tenantId??""},I=c.company?.companyInfo.companyLegalName??c.companyName;if(d==null)throw Error("Can't access statements page without signing in...");const l=s.fetchState!=="Completed";return e.jsx(Ct,{windowSize:n,children:e.jsx(Ye,{currentTenantCompanyName:I,statementListView:s,isLoading:l,onBackClick:()=>{const u=W(r.state?.pathnameStackToGoBack),x=u.poppedPathname??"..";t(x,{state:{pathnameStackToGoBack:u.newStack}})},authParams:S,downloadEndPoint:i})})}const jt=R.div`
22
22
  display: flex;
23
23
  height: 100vh;
24
24
  width: 100%;
@@ -26,7 +26,7 @@ import{j as e}from"./liveblocks-DOdRxZ-H.js";import{h as L,g as U,u as P,i as V,
26
26
  flex-direction: column;
27
27
  align-items: center;
28
28
  background-color: ${t=>t.theme.colors.grey4};
29
- `;function At(){const t=L(),a=q(),n=U(),r=P(),i=`${K.bankingMicroServiceBaseUrl}/1.0/treasury-account`,[o,m]=p.useState(!1),s=y((u=>Pe(u)));p.useEffect((()=>{o||s.fetchState!=="Not-Started"||(m(!0),r(Fe(!1)))}),[o,s.fetchState,r]);const d=v.getSignedInUser(),c=y((u=>E(u))),S={userId:d?.userId??"",sessionId:d?.zeniSessionId??"",tenantId:c.tenantId??""},I=c.company?.companyInfo.companyLegalName??c.companyName;if(d==null)throw Error("Can't access tax letter page without signing in...");const l=s.fetchState!=="Completed";return e.jsx(jt,{windowSize:a,children:e.jsx(et,{currentTenantCompanyName:I,taxLetterListView:s,isLoading:l,onBackClick:()=>{const u=W(n.state?.pathnameStackToGoBack),x=u.poppedPathname??"..";t(x,{state:{pathnameStackToGoBack:u.newStack}})},authParams:S,downloadEndPoint:i})})}const bt=M((function(t,a){const{companyId:n}=a,r=F(t,n);return{treasurySetupView:r,isSetupComplete:r.companyTreasuryInfo?.businessVerificationStatus?.code==="verified",videoUrl:"https://www.youtube.com/watch?v=sqvJWKCMZgk"}}),(function(t,a){const{navigate:n,companyId:r}=a;return{onSetupButtonClick:()=>{t(Be(r))},onBackClick:()=>{n("../..",{relative:"path"})},onTreasurySetupSuccess:i=>{n(i?"..":"../setup",{relative:"path"})}}}))(at),vt=()=>{const t=tt(),a=L(),n=U(),r=P(),{tenantEmailDomain:i}=V(),[o,m]=p.useState(!1),s=y((g=>E(g))),[d,c]=p.useState(!1),S=y((g=>g.treasurySetupViewState.treasuryFundsDetails?.fetchStatus));p.useEffect((()=>{d||S?.fetchState!=="Not-Started"||I==null||(c(!0),r(G()))}),[S,r]);const I=v.getSignedInUserTenant(i)?.companyId??s.companyId,l=v.getSignedInUser(),u=!!s.companyTreasuryInfo?.info?.isTreasuryTOSAccepted,x=g=>{m(g)};if(l==null)throw Error("Can't access treasury promo page without signing in...");const f=_(),C=N(f?.loggedInUserRoleMap),h=H(f?.loggedInUserRoleMap);if(u&&C)return e.jsx(D,{to:"../../treasury/setup"});if(s.company?.companyTreasuryInfo&&(!u&&C||h)){if(n.state?.message==="activation"){const g=W(n.state?.pathnameStackToGoBack);a(n.pathname,{state:{...n.state,message:void 0,pathnameStackToGoBack:g.newStack}})}return S?.fetchState!=="Completed"?e.jsx(te,{children:e.jsx(Y,{size:"ExtraLarge",start:!0})}):e.jsxs(e.Fragment,{children:[e.jsx($,{analytics:A,onLoad:g=>(j=>j.trackTreasuryPromoView("Treasury Promo Page"))(g)}),e.jsx(ce,{isAppContentDrawerOpen:o,handleDrawerToggle:x}),e.jsx(bt,{analytics:A,navigate:a,companyId:I,meetingUrl:t("treasury_promo"),onClickMenuIcon:()=>{x(!0)}})]})}return e.jsx(te,{children:e.jsx(Y,{size:"ExtraLarge",start:!0})})},te=R.div`
29
+ `;function bt(){const t=L(),a=q(),n=U(),r=P(),i=`${K.bankingMicroServiceBaseUrl}/1.0/treasury-account`,[o,m]=p.useState(!1),s=y((u=>Pe(u)));p.useEffect((()=>{o||s.fetchState!=="Not-Started"||(m(!0),r(Fe(!1)))}),[o,s.fetchState,r]);const d=v.getSignedInUser(),c=y((u=>E(u))),S={userId:d?.userId??"",sessionId:d?.zeniSessionId??"",tenantId:c.tenantId??""},I=c.company?.companyInfo.companyLegalName??c.companyName;if(d==null)throw Error("Can't access tax letter page without signing in...");const l=s.fetchState!=="Completed";return e.jsx(jt,{windowSize:a,children:e.jsx(et,{currentTenantCompanyName:I,taxLetterListView:s,isLoading:l,onBackClick:()=>{const u=W(n.state?.pathnameStackToGoBack),x=u.poppedPathname??"..";t(x,{state:{pathnameStackToGoBack:u.newStack}})},authParams:S,downloadEndPoint:i})})}const At=M((function(t,a){const{companyId:n}=a,r=F(t,n);return{treasurySetupView:r,isSetupComplete:r.companyTreasuryInfo?.businessVerificationStatus?.code==="verified",videoUrl:"https://www.youtube.com/watch?v=sqvJWKCMZgk"}}),(function(t,a){const{navigate:n,companyId:r}=a;return{onSetupButtonClick:()=>{t(Be(r))},onBackClick:()=>{n("../..",{relative:"path"})},onTreasurySetupSuccess:i=>{n(i?"..":"../setup",{relative:"path"})}}}))(at),vt=()=>{const t=tt(),a=L(),n=U(),r=P(),{tenantEmailDomain:i}=V(),[o,m]=p.useState(!1),s=y((g=>E(g))),[d,c]=p.useState(!1),S=y((g=>g.treasurySetupViewState.treasuryFundsDetails?.fetchStatus));p.useEffect((()=>{d||S?.fetchState!=="Not-Started"||I==null||(c(!0),r(G()))}),[S,r]);const I=v.getSignedInUserTenant(i)?.companyId??s.companyId,l=v.getSignedInUser(),u=!!s.companyTreasuryInfo?.info?.isTreasuryTOSAccepted,x=g=>{m(g)};if(l==null)throw Error("Can't access treasury promo page without signing in...");const f=_(),C=N(f?.loggedInUserRoleMap),h=H(f?.loggedInUserRoleMap);if(u&&C)return e.jsx(D,{to:"../../treasury/setup"});if(s.company?.companyTreasuryInfo&&(!u&&C||h)){if(n.state?.message==="activation"){const g=W(n.state?.pathnameStackToGoBack);a(n.pathname,{state:{...n.state,message:void 0,pathnameStackToGoBack:g.newStack}})}return S?.fetchState!=="Completed"?e.jsx(te,{children:e.jsx(Q,{size:"ExtraLarge",start:!0})}):e.jsxs(e.Fragment,{children:[e.jsx($,{analytics:b,onLoad:g=>(j=>j.trackTreasuryPromoView("Treasury Promo Page"))(g)}),e.jsx(ce,{isAppContentDrawerOpen:o,handleDrawerToggle:x}),e.jsx(At,{analytics:b,navigate:a,companyId:I,meetingUrl:t("treasury_promo"),onClickMenuIcon:()=>{x(!0)}})]})}return e.jsx(te,{children:e.jsx(Q,{size:"ExtraLarge",start:!0})})},te=R.div`
30
30
  display: flex;
31
31
  width: 100%;
32
32
  height: 100%;
@@ -34,4 +34,4 @@ import{j as e}from"./liveblocks-DOdRxZ-H.js";import{h as L,g as U,u as P,i as V,
34
34
  justify-content: center;
35
35
  align-items: center;
36
36
  background-color: ${t=>t.theme.colors.grey5};
37
- `;function ta(){const t=U(),a=y((g=>E(g))),{useFeatureGate:n}=ie(),r=a.companyTreasuryInfo?.info?.businessVerificationStatus?.code==="verified",i=!!a.company?.companyTreasuryInfo?.isTreasuryTOSAccepted,o=_(),m=H(o?.loggedInUserRoleMap),s=a?.userRole!=null&&Re(a?.userRole),d=(a?.company==null||a.company.featuresActivationInfo?.isBillPayFeatureEnabled&&!s)&&Oe(o?.loggedInUserRoleMap),c=Ve(o?.loggedInUserRoleMap),S=(a?.company==null||a.company.featuresActivationInfo?.isReimbursementFeatureEnabled&&!s)&&Me(o?.loggedInUserRoleMap),I=!!a.company?.companyZeniAccountInfo?.isZeniAccountEnabled&&!s&&Ne(o?.loggedInUserRoleMap),l=r&&!s&&N(o?.loggedInUserRoleMap),{isFeatureEnabled:u}=n(O.isChargeCardFeatureEnabled),{isFeatureEnabled:x}=n(O.isDebitCardFeatureEnabled),f=nt(a,u,x)&&!s&&_e(o?.loggedInUserRoleMap),C=$e(o?.loggedInUserRoleMap),h=ze(o?.loggedInUserRoleMap);return e.jsxs(xe,{children:[h?null:e.jsx(k,{path:"setup",element:e.jsx(Q,{isBillPayAdminLevelAccess:d,isReimbursementAdminLevelAccess:S,isZeniAccountAdminLevelAccess:I,isChargeCardAdminLevelAccess:f,isTreasuryAdminLevelAccess:l,isUserHasOnlyCardAccess:C,isUserHasOnlyBillPayAccess:c,productType:"zeni_treasury",type:"setup"})}),h?null:e.jsx(k,{path:"verification",element:e.jsx(Q,{isBillPayAdminLevelAccess:d,isUserHasOnlyBillPayAccess:c,isReimbursementAdminLevelAccess:S,isZeniAccountAdminLevelAccess:I,isChargeCardAdminLevelAccess:f,isTreasuryAdminLevelAccess:l,isUserHasOnlyCardAccess:C,productType:"zeni_treasury",type:"verification"})}),e.jsx(k,{path:"promo",element:e.jsx(vt,{})}),e.jsx(k,{path:"statements",element:e.jsx(kt,{})}),e.jsx(k,{path:"tax-letter",element:e.jsx(At,{})}),r?e.jsxs(e.Fragment,{children:[e.jsx(k,{path:"/",element:e.jsx(z,{isTransferDrawerOpen:!1,isEditPortfolioDrawerOpen:!1})}),l?e.jsxs(e.Fragment,{children:[e.jsx(k,{path:"edit-portfolio",element:e.jsx(z,{isEditPortfolioDrawerOpen:!0,isTransferDrawerOpen:!1})}),e.jsx(k,{path:"transfer",element:e.jsx(z,{isTransferDrawerOpen:!0,isEditPortfolioDrawerOpen:!1})})]}):null,e.jsx(k,{path:"*",element:e.jsx(it,{})})]}):i&&l?e.jsx(k,{path:"*",element:e.jsx(D,{to:"../setup"})}):a.company?.companyZeniAccountInfo&&m?e.jsx(k,{path:"*",element:e.jsx(D,{to:"../promo",state:t.state})}):e.jsx(k,{path:"*",element:null})]})}export{ta as default};
37
+ `;function ta(){const t=U(),a=y((g=>E(g))),{useFeatureGate:n}=ie(),r=a.companyTreasuryInfo?.info?.businessVerificationStatus?.code==="verified",i=!!a.company?.companyTreasuryInfo?.isTreasuryTOSAccepted,o=_(),m=H(o?.loggedInUserRoleMap),s=a?.userRole!=null&&Re(a?.userRole),d=(a?.company==null||a.company.featuresActivationInfo?.isBillPayFeatureEnabled&&!s)&&Oe(o?.loggedInUserRoleMap),c=Ve(o?.loggedInUserRoleMap),S=(a?.company==null||a.company.featuresActivationInfo?.isReimbursementFeatureEnabled&&!s)&&Me(o?.loggedInUserRoleMap),I=!!a.company?.companyZeniAccountInfo?.isZeniAccountEnabled&&!s&&Ne(o?.loggedInUserRoleMap),l=r&&!s&&N(o?.loggedInUserRoleMap),{isFeatureEnabled:u}=n(O.isChargeCardFeatureEnabled),{isFeatureEnabled:x}=n(O.isDebitCardFeatureEnabled),f=nt(a,u,x)&&!s&&_e(o?.loggedInUserRoleMap),C=$e(o?.loggedInUserRoleMap),h=ze(o?.loggedInUserRoleMap);return e.jsxs(xe,{children:[h?null:e.jsx(k,{path:"setup",element:e.jsx(Y,{isBillPayAdminLevelAccess:d,isReimbursementAdminLevelAccess:S,isZeniAccountAdminLevelAccess:I,isChargeCardAdminLevelAccess:f,isTreasuryAdminLevelAccess:l,isUserHasOnlyCardAccess:C,isUserHasOnlyBillPayAccess:c,productType:"zeni_treasury",type:"setup"})}),h?null:e.jsx(k,{path:"verification",element:e.jsx(Y,{isBillPayAdminLevelAccess:d,isUserHasOnlyBillPayAccess:c,isReimbursementAdminLevelAccess:S,isZeniAccountAdminLevelAccess:I,isChargeCardAdminLevelAccess:f,isTreasuryAdminLevelAccess:l,isUserHasOnlyCardAccess:C,productType:"zeni_treasury",type:"verification"})}),e.jsx(k,{path:"promo",element:e.jsx(vt,{})}),e.jsx(k,{path:"statements",element:e.jsx(kt,{})}),e.jsx(k,{path:"tax-letter",element:e.jsx(bt,{})}),r?e.jsxs(e.Fragment,{children:[e.jsx(k,{path:"/",element:e.jsx(z,{isTransferDrawerOpen:!1,isEditPortfolioDrawerOpen:!1})}),l?e.jsxs(e.Fragment,{children:[e.jsx(k,{path:"edit-portfolio",element:e.jsx(z,{isEditPortfolioDrawerOpen:!0,isTransferDrawerOpen:!1})}),e.jsx(k,{path:"transfer",element:e.jsx(z,{isTransferDrawerOpen:!0,isEditPortfolioDrawerOpen:!1})})]}):null,e.jsx(k,{path:"*",element:e.jsx(it,{})})]}):i&&l?e.jsx(k,{path:"*",element:e.jsx(D,{to:"../setup"})}):a.company?.companyZeniAccountInfo&&m?e.jsx(k,{path:"*",element:e.jsx(D,{to:"../promo",state:t.state})}):e.jsx(k,{path:"*",element:null})]})}export{ta as default};
@@ -1,4 +1,4 @@
1
- import{j as o}from"./liveblocks-DOdRxZ-H.js";import{a as u}from"./sentry-DvoFEQx8.js";import{h as N,u as $,i as z,j as f,l as W,g as K,n as Me,o as P,N as U}from"./core-R1zvmcG1.js";import{Wk as gt,Wl as Ze,S6 as et,Wm as vt,fI as L,h2 as ge,Wn as Tt,cF as xt,Wo as bt,G7 as yt,Wp as wt,Wq as oe,Wr as te,Ws as ve,TI as ue,TJ as ke,Gn as pe,TH as he,Ga as tt,FJ as Pe,Wt as It,TK as Y,m3 as me,Wu as je,FD as Ct,Wv as Dt,Ww as Et,Wx as _e,Wy as Ve,Wz as Ae,WA as Re,Gh as Te,WB as nt,F_ as at,WC as Ft,WD as kt,WE as Pt,WF as jt,WG as _t,WH as Vt,WI as At,WJ as Rt,CM as Lt,CU as Ut,CN as Bt,SO as we,WK as Ot,WL as Mt,lj as Ie,br as Nt,WM as Wt,WN as $t,n1 as Gt,na as zt,SN as Ce,bF as Ne,WO as ot,So as st,WP as Yt,WQ as Xt,WR as Jt,nc as Kt,WS as We,WT as $e,WU as Ge,WV as ze,WW as qt,n8 as Ht,WX as Qt,nb as Zt,WY as en,WZ as it,T8 as rt,mr as tn,W_ as nn,W$ as De,X0 as dt,T6 as lt,IR as an,X1 as on,X2 as sn,mL as ct,X3 as rn,X4 as dn,Tk as ln,vn as cn,X5 as ut,X6 as Ye,Th as Ee,X7 as Xe,X8 as un,Tm as pn,X9 as hn,Xa as mn,Xb as fn,Xc as Sn,Xd as gn,vq as vn,Xe as Tn,TL as xn,Vj as bn,S$ as Fe,ie as yn,Vl as wn,Vk as In,ic as Cn,Xf as Dn,Xg as En,IW as Fn,Xh as kn,Xi as Pn,Xj as jn,Xk as _n,mv as Vn,bn as An,e0 as Rn,d$ as Ln}from"./zeni-epic-state-Mdu-dKQU.js";import{_ as ne,a9 as Le,Y as q,$ as M,z as R,a5 as Un,aK as Bn,l as j,Q as Ue,k as xe,at as ee,aq as se,aL as On,aM as pt,ao as Mn,a6 as Se,aN as Nn,p as J,V as Wn,G as ht,aO as $n,ac as mt,a2 as Gn,j as Je,aP as zn,E as X,a7 as Yn,ad as ft,ae as Xn,aQ as Jn,aR as Kn,K as Be,aS as qn,aT as Hn,a1 as Qn,aU as Zn,aV as ea}from"./index-Cvus_VBr.js";import{u as ta,D as na,n as B,S as St}from"./mui-ZKvbmPSP.js";import{t as aa,A as oa}from"./AddressScreen-C0JLhAcE.js";import fe from"./NotFoundScreen-BR0tBeJN.js";import{F as sa}from"./FeaturePreviewScreen-t6-81tB3.js";import{S as ia,a as ra,J as da,b as la,c as ca}from"./ScheduleDetailsPrepaidExpensesScreen-ISVWQj5Q.js";import{u as ie}from"./useAskAiCfoHostNavButtonProps-D5Ew-Qzm.js";import{M as re}from"./MobileAppDrawer-CPwvCIYa.js";import{v as Oe,c as ua,d as pa}from"./routePaths-ME1g30cL.js";import{D as ha}from"./DrawerScreen-CjvLDWWa.js";import{a as ma,m as fa}from"./accountMappingHelper-jzkx0QiS.js";import"./recharts-UmMlzZlF.js";import"./analytics-BE49_JfE.js";import"./plaid-tDbexfSh.js";import"./dnd-LSyMQh_7.js";import"./stripe-cKAAJElX.js";import"./lottie-Z_NAxrmn.js";import"./lexical-BG-nDmQN.js";import"./pdf-_w1KRTSP.js";import"./utils-D06mHID-.js";import"./pathToGoBack-DioXT2-t.js";import"./InboxNotificationsProvider--Aami2sh.js";import"./useTaskManagerAccess-CcPTnvTg.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},a=new e.Error().stack;a&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[a]="5ec24063-99a9-458d-a8ee-b70ecaa15d47",e._sentryDebugIdIdentifier="sentry-dbid-5ec24063-99a9-458d-a8ee-b70ecaa15d47")}catch{}})();const Sa={drawerLeftMargin:new Le(0,0,100,200)},ga=W((function(e,a){const{jeScheduledTransaction:s,selectedJERow:t,scheduleType:n,isVendorBulkUpdateOnTransactionEnabled:i}=a,{scheduleDetailsLocalData:l,updateStatus:p}=Ze(e,a.scheduleType),h=L(e),v=l[n].jeScheduleDetails[t].jeLink,m=v.type==="recommended"?v.recommendedTransactionID:v.transactionDetailID,r=m!=null?Tt(e,m):void 0,d=R.getSignedInUser(),c=e.tenantState.currentTenantId,T={userId:d?.userId??"",sessionId:d?.zeniSessionId??"",tenantId:h.tenantId??c},x=h?.company?.companyInfo?.firstMonthOfFY??1;return{jeScheduledTransaction:s,transactionDetail:r,localData:l[n].jeScheduleDetails[t],saveStatus:p.fetchState,authParams:T,isVendorBulkUpdateOnTransactionEnabled:i,firstMonthOfFY:x,isDisabled:p.fetchState==="In-Progress"?"readonly":void 0,analytics:j,qboAppUrl:xt(Ue.qboRedirectionUrl)}}),(function(e,a){const{selectedJERow:s,jeScheduleDetailId:t,navigate:n}=a;return{onUpdateLocalData:i=>{const l=i.linkJETransaction.qboURL;l!=null&&e(wt({scheduleType:a.scheduleType,jeScheduleDetailId:t,rowId:s,jeLink:l}))},onFetchTransactionClick:i=>{e(et(i))},onSaveClick:()=>{e(yt(a.scheduleType,t))},onBackClick:()=>{n("..",{relative:"path"})},onCancelClick:()=>{const i=a.jeScheduledTransaction.scheduledJournalEntry[s];e(bt({scheduleType:a.scheduleType,jeScheduleDetailId:t,rowId:s,originalScheduledJE:i})),n("..",{relative:"path"})}}}))(Bn),va=()=>{const e=ta(),a=N(),s=$(),{scheduleDetailId:t}=z(),n=ne(),i=Sa.drawerLeftMargin.valuePx(n),{scheduleType:l}=z(),{useFeatureGate:p}=q(),{isFeatureEnabled:h}=p(M.isVendorBulkUpdateOnTransactionEnabled),v=gt(l)??"prepaid_expenses",[m,r]=u.useState(!1);if(R.getSignedInUser()==null)throw Error("Can't access Account detail page without signing in...");if(t==null)throw Error("Invalid Schedule Detail Id");const d=f((b=>Ze(b,v)));u.useEffect((()=>{d.fetchState==="Not-Started"&&a("..",{relative:"path"})}),[]);const c=d.selectedJELinkRowIndex,T=c!=null?d.scheduleDetailsLocalData[v].jeScheduleDetails[c]?.jeLink:null,x=T?.type==="recommended"?T.recommendedTransactionID:T?.transactionDetailID;u.useEffect((()=>{x!=null&&s(et(x))}),[]),u.useEffect((()=>{T?.type==="recommended"&&m===!1&&c!=null&&(r(!0),s(vt({scheduleType:v,jeScheduleDetailId:t,rowId:c})))}));const g=f((b=>L(b))),y=f((b=>ge(b,g.companyId)));return o.jsx(na,{anchor:"right",open:!0,PaperProps:{style:{width:`calc(100% - ${i})`,boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:e.colors.black,opacity:.75,cursor:"pointer"}}},onClose:()=>a("..",{relative:"path"}),children:o.jsx(Ta,{onClick:b=>b.stopPropagation(),children:d.fetchState!=="Completed"||d.selectedJEScheduleTransaction==null||c==null?o.jsx(Un,{fetchState:d.fetchState}):o.jsx(ga,{scheduleType:v,jeScheduleDetailId:t,selectedJERow:c,jeScheduledTransaction:d.selectedJEScheduleTransaction,isCOTEnabled:!1,navigate:a,scheduleTab:v,controllerUserDetails:y,isVendorBulkUpdateOnTransactionEnabled:h})})})},Ta=B(St)`
1
+ import{j as o}from"./liveblocks-BYqz0SWy.js";import{a as u}from"./sentry-DjmIorbX.js";import{h as N,u as $,i as z,j as f,l as W,g as K,n as Me,o as P,N as U}from"./core-B1R51LGS.js";import{Wk as gt,Wl as Ze,S6 as et,Wm as vt,fI as L,h2 as ge,Wn as Tt,cF as xt,Wo as bt,G7 as yt,Wp as wt,Wq as oe,Wr as te,Ws as ve,TI as ue,TJ as ke,Gn as pe,TH as he,Ga as tt,FJ as Pe,Wt as It,TK as Y,m3 as me,Wu as je,FD as Ct,Wv as Dt,Ww as Et,Wx as _e,Wy as Ve,Wz as Ae,WA as Re,Gh as Te,WB as nt,F_ as at,WC as Ft,WD as kt,WE as Pt,WF as jt,WG as _t,WH as Vt,WI as At,WJ as Rt,CM as Lt,CU as Ut,CN as Bt,SO as we,WK as Ot,WL as Mt,lj as Ie,br as Nt,WM as Wt,WN as $t,n1 as Gt,na as zt,SN as Ce,bF as Ne,WO as ot,So as st,WP as Yt,WQ as Xt,WR as Jt,nc as Kt,WS as We,WT as $e,WU as Ge,WV as ze,WW as qt,n8 as Ht,WX as Qt,nb as Zt,WY as en,WZ as it,T8 as rt,mr as tn,W_ as nn,W$ as De,X0 as dt,T6 as lt,IR as an,X1 as on,X2 as sn,mL as ct,X3 as rn,X4 as dn,Tk as ln,vn as cn,X5 as ut,X6 as Ye,Th as Ee,X7 as Xe,X8 as un,Tm as pn,X9 as hn,Xa as mn,Xb as fn,Xc as Sn,Xd as gn,vq as vn,Xe as Tn,TL as xn,Vj as bn,S$ as Fe,ie as yn,Vl as wn,Vk as In,ic as Cn,Xf as Dn,Xg as En,IW as Fn,Xh as kn,Xi as Pn,Xj as jn,Xk as _n,mv as Vn,bn as An,e0 as Rn,d$ as Ln}from"./zeni-epic-state-M9sMLOaG.js";import{_ as ne,a9 as Le,c as q,$ as M,z as R,a5 as Un,aK as Bn,l as j,Q as Ue,k as xe,at as ee,aq as se,aL as On,aM as pt,ao as Mn,a6 as Se,aN as Nn,p as J,V as Wn,G as ht,aO as $n,ac as mt,a2 as Gn,j as Je,aP as zn,E as X,a7 as Yn,ad as ft,ae as Xn,aQ as Jn,aR as Kn,K as Be,aS as qn,aT as Hn,a1 as Qn,aU as Zn,aV as ea}from"./index-Dp_Uc3gy.js";import{u as ta,D as na,n as B,S as St}from"./mui-D-_RYGgU.js";import{t as aa,A as oa}from"./AddressScreen-Ce6wpOqL.js";import fe from"./NotFoundScreen-DDA41Ig7.js";import{F as sa}from"./FeaturePreviewScreen-DETqyCpy.js";import{S as ia,a as ra,J as da,b as la,c as ca}from"./ScheduleDetailsPrepaidExpensesScreen-OdknWRFf.js";import{u as ie}from"./useAskAiCfoHostNavButtonProps-DWkTPomv.js";import{M as re}from"./MobileAppDrawer-CsfNveW9.js";import{v as Oe,c as ua,d as pa}from"./routePaths-BALvGXpp.js";import{D as ha}from"./DrawerScreen-Bev9sxN6.js";import{a as ma,m as fa}from"./accountMappingHelper-1wM-u5pk.js";import"./recharts-By7FVN8f.js";import"./analytics-DhotUQIQ.js";import"./plaid-B0PWXAfV.js";import"./dnd-CBDtHD8g.js";import"./stripe-cKAAJElX.js";import"./lottie-C4orech3.js";import"./lexical-Cft6chCX.js";import"./pdf-DFgrdLB6.js";import"./utils-iOnDyQuG.js";import"./pathToGoBack-DZ8Lgq0-.js";import"./InboxNotificationsProvider-LdTK3V9o.js";import"./useTaskManagerAccess-CFJAytRv.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},a=new e.Error().stack;a&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[a]="cefcdde5-2c81-42ee-a759-3c31172c7bb3",e._sentryDebugIdIdentifier="sentry-dbid-cefcdde5-2c81-42ee-a759-3c31172c7bb3")}catch{}})();const Sa={drawerLeftMargin:new Le(0,0,100,200)},ga=W((function(e,a){const{jeScheduledTransaction:s,selectedJERow:t,scheduleType:n,isVendorBulkUpdateOnTransactionEnabled:i}=a,{scheduleDetailsLocalData:l,updateStatus:p}=Ze(e,a.scheduleType),h=L(e),v=l[n].jeScheduleDetails[t].jeLink,m=v.type==="recommended"?v.recommendedTransactionID:v.transactionDetailID,r=m!=null?Tt(e,m):void 0,d=R.getSignedInUser(),c=e.tenantState.currentTenantId,T={userId:d?.userId??"",sessionId:d?.zeniSessionId??"",tenantId:h.tenantId??c},x=h?.company?.companyInfo?.firstMonthOfFY??1;return{jeScheduledTransaction:s,transactionDetail:r,localData:l[n].jeScheduleDetails[t],saveStatus:p.fetchState,authParams:T,isVendorBulkUpdateOnTransactionEnabled:i,firstMonthOfFY:x,isDisabled:p.fetchState==="In-Progress"?"readonly":void 0,analytics:j,qboAppUrl:xt(Ue.qboRedirectionUrl)}}),(function(e,a){const{selectedJERow:s,jeScheduleDetailId:t,navigate:n}=a;return{onUpdateLocalData:i=>{const l=i.linkJETransaction.qboURL;l!=null&&e(wt({scheduleType:a.scheduleType,jeScheduleDetailId:t,rowId:s,jeLink:l}))},onFetchTransactionClick:i=>{e(et(i))},onSaveClick:()=>{e(yt(a.scheduleType,t))},onBackClick:()=>{n("..",{relative:"path"})},onCancelClick:()=>{const i=a.jeScheduledTransaction.scheduledJournalEntry[s];e(bt({scheduleType:a.scheduleType,jeScheduleDetailId:t,rowId:s,originalScheduledJE:i})),n("..",{relative:"path"})}}}))(Bn),va=()=>{const e=ta(),a=N(),s=$(),{scheduleDetailId:t}=z(),n=ne(),i=Sa.drawerLeftMargin.valuePx(n),{scheduleType:l}=z(),{useFeatureGate:p}=q(),{isFeatureEnabled:h}=p(M.isVendorBulkUpdateOnTransactionEnabled),v=gt(l)??"prepaid_expenses",[m,r]=u.useState(!1);if(R.getSignedInUser()==null)throw Error("Can't access Account detail page without signing in...");if(t==null)throw Error("Invalid Schedule Detail Id");const d=f((b=>Ze(b,v)));u.useEffect((()=>{d.fetchState==="Not-Started"&&a("..",{relative:"path"})}),[]);const c=d.selectedJELinkRowIndex,T=c!=null?d.scheduleDetailsLocalData[v].jeScheduleDetails[c]?.jeLink:null,x=T?.type==="recommended"?T.recommendedTransactionID:T?.transactionDetailID;u.useEffect((()=>{x!=null&&s(et(x))}),[]),u.useEffect((()=>{T?.type==="recommended"&&m===!1&&c!=null&&(r(!0),s(vt({scheduleType:v,jeScheduleDetailId:t,rowId:c})))}));const g=f((b=>L(b))),y=f((b=>ge(b,g.companyId)));return o.jsx(na,{anchor:"right",open:!0,PaperProps:{style:{width:`calc(100% - ${i})`,boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:e.colors.black,opacity:.75,cursor:"pointer"}}},onClose:()=>a("..",{relative:"path"}),children:o.jsx(Ta,{onClick:b=>b.stopPropagation(),children:d.fetchState!=="Completed"||d.selectedJEScheduleTransaction==null||c==null?o.jsx(Un,{fetchState:d.fetchState}):o.jsx(ga,{scheduleType:v,jeScheduleDetailId:t,selectedJERow:c,jeScheduledTransaction:d.selectedJEScheduleTransaction,isCOTEnabled:!1,navigate:a,scheduleTab:v,controllerUserDetails:y,isVendorBulkUpdateOnTransactionEnabled:h})})})},Ta=B(St)`
2
2
  display: flex;
3
3
  min-height: 100%;
4
4
  flex-direction: column;
@@ -1,4 +1,4 @@
1
- import{j as o}from"./liveblocks-DOdRxZ-H.js";import{a as l}from"./sentry-DvoFEQx8.js";import{t as u,u as h,j as y,N as I}from"./core-R1zvmcG1.js";import{V7 as w,gl as b,K3 as j}from"./zeni-epic-state-Mdu-dKQU.js";import{z as f,a5 as x,ad as S,ae as D}from"./index-Cvus_VBr.js";import{n as g}from"./mui-ZKvbmPSP.js";import"./recharts-UmMlzZlF.js";import"./analytics-BE49_JfE.js";import"./plaid-tDbexfSh.js";import"./dnd-LSyMQh_7.js";import"./stripe-cKAAJElX.js";import"./lottie-Z_NAxrmn.js";import"./lexical-BG-nDmQN.js";import"./pdf-_w1KRTSP.js";import"./utils-D06mHID-.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]="716d832d-1c95-4da2-8705-8652519a0077",e._sentryDebugIdIdentifier="sentry-dbid-716d832d-1c95-4da2-8705-8652519a0077")}catch{}})();const A=()=>{const[e]=u(),t=e.get("code")??"",s=e.get("state")??"",p=e.get("profileId")??"",[n,c]=l.useState(!1),a=h(),i=y((m=>w(m))),r=f.getSignedInUser(),d=f.getSignedInUserTenantWithId(s);if(r==null||d==null)return o.jsx(I,{to:"/signin/auth",replace:!0});if(r==null)throw Error("Can't access this page without signing in...");return b(r.userId,r.zeniSessionId,d?.tenantId),l.useEffect((()=>{n||(c(!0),a(j(t,p,s)))}),[n,a]),i.fetchState==="Error"?o.jsx(E,{children:o.jsx(_,{children:i.error?.message??""})}):(i.fetchState==="Completed"&&window.close(),o.jsx(x,{fetchState:"In-Progress"}))},E=g.div`
1
+ import{j as o}from"./liveblocks-BYqz0SWy.js";import{a as l}from"./sentry-DjmIorbX.js";import{t as u,u as h,j as y,N as I}from"./core-B1R51LGS.js";import{V7 as w,gl as b,K3 as j}from"./zeni-epic-state-M9sMLOaG.js";import{z as f,a5 as x,ad as S,ae as D}from"./index-Dp_Uc3gy.js";import{n as g}from"./mui-D-_RYGgU.js";import"./recharts-By7FVN8f.js";import"./analytics-DhotUQIQ.js";import"./plaid-B0PWXAfV.js";import"./dnd-CBDtHD8g.js";import"./stripe-cKAAJElX.js";import"./lottie-C4orech3.js";import"./lexical-Cft6chCX.js";import"./pdf-DFgrdLB6.js";import"./utils-iOnDyQuG.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]="716d832d-1c95-4da2-8705-8652519a0077",e._sentryDebugIdIdentifier="sentry-dbid-716d832d-1c95-4da2-8705-8652519a0077")}catch{}})();const A=()=>{const[e]=u(),t=e.get("code")??"",s=e.get("state")??"",p=e.get("profileId")??"",[n,c]=l.useState(!1),a=h(),i=y((m=>w(m))),r=f.getSignedInUser(),d=f.getSignedInUserTenantWithId(s);if(r==null||d==null)return o.jsx(I,{to:"/signin/auth",replace:!0});if(r==null)throw Error("Can't access this page without signing in...");return b(r.userId,r.zeniSessionId,d?.tenantId),l.useEffect((()=>{n||(c(!0),a(j(t,p,s)))}),[n,a]),i.fetchState==="Error"?o.jsx(E,{children:o.jsx(_,{children:i.error?.message??""})}):(i.fetchState==="Completed"&&window.close(),o.jsx(x,{fetchState:"In-Progress"}))},E=g.div`
2
2
  display: flex;
3
3
  width: 100%;
4
4
  height: 100vh;
@@ -1,4 +1,4 @@
1
- import{j as e}from"./liveblocks-DOdRxZ-H.js";import{u as z,h as ne,g as G,i as W,j as k,l as ae,N as Q,n as Re,o as x}from"./core-R1zvmcG1.js";import{$X as Ue,LX as Fe,$Y as _e,fI as R,H8 as ze,$Z as An,cv as ee,cw as $e,H2 as wn,$_ as Dn,$$ as kn,H5 as In,Hc as me,G$ as Sn,GY as Pn,Zu as ce,a00 as bn,Pv as vn,Xq as jn,Px as En,mM as Pe,a01 as Tn,v2 as Me,uS as Ve,mD as Ze,mG as be,Xr as ve,Xs as Bn,a02 as On,mF as Ln,n0 as Rn,mu as Un,kU as Fn,kT as _n,a03 as zn,a04 as ge,Pc as $n,a05 as Mn,a06 as Vn,ZK as he,a07 as je,a08 as Zn,PI as Hn,_5 as Nn,N3 as He,CA as Ne,a09 as Gn,PF as Wn,a0a as Ge,db as ye,PM as We,d$ as Ye,e0 as xe,PK as Yn,MZ as Kn,PC as Xn,a0b as Ke,a0c as Xe,Pe as qe,Po as Ee,a0d as qn,ZY as Jn,PN as Qn,bq as ea,bK as na,cH as aa,bL as ta,bu as oa,UR as sa}from"./zeni-epic-state-Mdu-dKQU.js";import{V as te,Y as Z,$ as V,z as b,at as Ce,a5 as le,cV as ra,_ as $,a9 as Y,a2 as Je,j as ia,r as Te,l as L,cW as ca,ac as Ae,cX as la,a6 as de,cY as da,K as we,bg as N,cZ as ua,ao as pa,aq as Qe,c_ as Be,c$ as ma,p as ie,d0 as ga,ag as fa,d1 as ha,d2 as ya,g as xa,E as Ca}from"./index-Cvus_VBr.js";import{u as U,n as F,D as K,S as X}from"./mui-ZKvbmPSP.js";import J from"./NotFoundScreen-BR0tBeJN.js";import{S as Oe}from"./SetupPagesScreen-fiQdFdcd.js";import{F as en}from"./FeaturePreviewScreen-t6-81tB3.js";import{a as g}from"./sentry-DvoFEQx8.js";import{M as ue}from"./MobileAppDrawer-CPwvCIYa.js";import{A as Aa,D as wa,V as Da}from"./DomesticWireDetailScreen-BqNLFPCz.js";import{A as ka}from"./AddressScreen-C0JLhAcE.js";import{u as nn}from"./useAskAiCfoHostNavButtonProps-D5Ew-Qzm.js";import{Z as Ia}from"./ZeniAccountStatementScreen-BjT0Ja6v.js";import"./recharts-UmMlzZlF.js";import"./analytics-BE49_JfE.js";import"./plaid-tDbexfSh.js";import"./dnd-LSyMQh_7.js";import"./stripe-cKAAJElX.js";import"./lottie-Z_NAxrmn.js";import"./lexical-BG-nDmQN.js";import"./pdf-_w1KRTSP.js";import"./utils-D06mHID-.js";import"./BusinessVerificationPageScreen-D1nbOYUs.js";import"./routePaths-ME1g30cL.js";import"./analyticsHelper-DZVn8KPX.js";import"./InboxNotificationsProvider--Aami2sh.js";import"./useTaskManagerAccess-CcPTnvTg.js";(function(){try{var n=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},a=new n.Error().stack;a&&(n._sentryDebugIds=n._sentryDebugIds||{},n._sentryDebugIds[a]="6e807cf0-7f62-420c-9b08-f140eb555666",n._sentryDebugIdIdentifier="sentry-dbid-6e807cf0-7f62-420c-9b08-f140eb555666")}catch{}})();const Sa=F.div`
1
+ import{j as e}from"./liveblocks-BYqz0SWy.js";import{u as z,h as ne,g as G,i as W,j as k,l as ae,N as Q,n as Re,o as x}from"./core-B1R51LGS.js";import{$X as Ue,LX as Fe,$Y as _e,fI as R,H8 as ze,$Z as An,cv as ee,cw as $e,H2 as wn,$_ as Dn,$$ as kn,H5 as In,Hc as me,G$ as Sn,GY as Pn,Zu as ce,a00 as vn,Pv as bn,Xq as jn,Px as En,mM as Pe,a01 as Tn,v2 as Me,uS as Ve,mD as Ze,mG as ve,Xr as be,Xs as Bn,a02 as On,mF as Ln,n0 as Rn,mu as Un,kU as Fn,kT as _n,a03 as zn,a04 as ge,Pc as $n,a05 as Mn,a06 as Vn,ZK as he,a07 as je,a08 as Zn,PI as Hn,_5 as Nn,N3 as He,CA as Ne,a09 as Gn,PF as Wn,a0a as Ge,db as ye,PM as We,d$ as Ye,e0 as xe,PK as Yn,MZ as Kn,PC as Xn,a0b as Ke,a0c as Xe,Pe as qe,Po as Ee,a0d as qn,ZY as Jn,PN as Qn,bq as ea,bK as na,cH as aa,bL as ta,bu as oa,UR as sa}from"./zeni-epic-state-M9sMLOaG.js";import{V as te,c as Z,$ as V,z as v,at as Ce,a5 as le,cV as ra,_ as $,a9 as Y,a2 as Je,j as ia,r as Te,l as L,cW as ca,ac as Ae,cX as la,a6 as de,cY as da,K as we,bg as N,cZ as ua,ao as pa,aq as Qe,c_ as Be,c$ as ma,p as ie,d0 as ga,ag as fa,d1 as ha,d2 as ya,h as xa,E as Ca}from"./index-Dp_Uc3gy.js";import{u as U,n as F,D as K,S as X}from"./mui-D-_RYGgU.js";import J from"./NotFoundScreen-DDA41Ig7.js";import{S as Oe}from"./SetupPagesScreen-B0b-Fgla.js";import{F as en}from"./FeaturePreviewScreen-DETqyCpy.js";import{a as g}from"./sentry-DjmIorbX.js";import{M as ue}from"./MobileAppDrawer-CsfNveW9.js";import{A as Aa,D as wa,V as Da}from"./DomesticWireDetailScreen-CVJejZP9.js";import{A as ka}from"./AddressScreen-Ce6wpOqL.js";import{u as nn}from"./useAskAiCfoHostNavButtonProps-DWkTPomv.js";import{Z as Ia}from"./ZeniAccountStatementScreen-B-L8iMJL.js";import"./recharts-By7FVN8f.js";import"./analytics-DhotUQIQ.js";import"./plaid-B0PWXAfV.js";import"./dnd-CBDtHD8g.js";import"./stripe-cKAAJElX.js";import"./lottie-C4orech3.js";import"./lexical-Cft6chCX.js";import"./pdf-DFgrdLB6.js";import"./utils-iOnDyQuG.js";import"./BusinessVerificationPageScreen-B6gKgGKZ.js";import"./routePaths-BALvGXpp.js";import"./analyticsHelper-BkudU6tc.js";import"./InboxNotificationsProvider-LdTK3V9o.js";import"./useTaskManagerAccess-CFJAytRv.js";(function(){try{var n=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},a=new n.Error().stack;a&&(n._sentryDebugIds=n._sentryDebugIds||{},n._sentryDebugIds[a]="ef10151d-3f46-4ec3-8cf6-acf0d6e4d244",n._sentryDebugIdIdentifier="sentry-dbid-ef10151d-3f46-4ec3-8cf6-acf0d6e4d244")}catch{}})();const Sa=F.div`
2
2
  display: flex;
3
3
  min-height: 100%;
4
4
  width: 100%;
@@ -6,15 +6,15 @@ import{j as e}from"./liveblocks-DOdRxZ-H.js";import{u as z,h as ne,g as G,i as W
6
6
  flex-direction: column;
7
7
  align-items: center;
8
8
  background-color: ${n=>n.theme.colors.grey4};
9
- `;function Le({isEditDrawerOpen:n}){const a=U(),[r,t]=g.useState(!1),{autoTransferRulePageProps:o,isLoading:i}=(function({isEditDrawerOpen:d=!1}={}){const c=z(),p=ne(),f=G(),{ruleId:y,tenantEmailDomain:s}=W(),l=te(),{useFeatureGate:h}=Z(),m=k((u=>Ue(u))),P=k((u=>Fe(u.depositAccountState,u.depositAccountListState))),D=k((u=>_e(u))),w=k((u=>R(u))),{isFeatureEnabled:I}=h(V.isTreasuryEnabled),C=m?.fetchState??"Not-Started",A=w?.companyId??(s==null?void 0:b.getSignedInUserTenant(s)?.companyId);g.useEffect((()=>{C==="Not-Started"&&A!=null&&c(ze(!0))}),[c,C,A]);const E=m?.fetchState!=="Completed";if(E)return{autoTransferRulePageProps:void 0,isLoading:E};const T=w?.company!=null&&An(w.company),v=!!(I&&T),j=ee(l?.loggedInUserRoleMap)||$e(l?.loggedInUserRoleMap),O=b.getSignedInUser(),S={userId:O?.userId??"",sessionId:O?.zeniSessionId??"",tenantId:w?.tenantId??""},B=!!f.state?.scrollToAddRule;return{isLoading:E,autoTransferRulePageProps:{autoTransferRuleView:m,companyName:w?.companyName??"",hasAdminLevelAccess:j,includeTreasuryOption:v,transferLimit:5e5,authParams:S,currentTenant:w,depositAccountListView:P,downloadAccountDetailEndPoint:`${Ce}/account_details`,editingRuleId:y,isEditDrawerOpen:d,scrollToAddRule:B,zeniAccountsConfigDetail:D,onBackClick:()=>p(".."),onCreateRule:()=>{c(Pn())},onUpdateRule:u=>{c(me(u))},onDeleteClick:u=>{c(Sn(u))},onPauseClick:u=>{c(me(u,!0,!1))},onResumeClick:u=>{c(me(u,!1,!0))},onActivityClick:(u,M)=>{c(In(u,M))},onUpdateRuleLocalData:u=>{c(kn(u))},clearRuleLocalData:()=>{c(Dn())},onEditClick:u=>{p(`./${u}/edit`)},onEditDrawerClose:()=>{p("../../",{relative:"path"})},onReviewClick:()=>{c(wn())}}}})({isEditDrawerOpen:n});return i||o==null?e.jsx(le,{fetchState:"In-Progress",style:{backgroundColor:a.colors.grey5}}):e.jsxs(Sa,{children:[e.jsx(ue,{isAppContentDrawerOpen:r,handleDrawerToggle:d=>{t(d)}}),e.jsx(ra,{...o})]})}const Pa={overlayWidth:new Y(100,100,58)},ba=({vendorId:n,isDrawerOpen:a,closeDrawerHandler:r})=>{const t=z(),o=U(),i=$();if(b.getSignedInUser()==null)throw Error("Can't access ach account page without signing in...");return e.jsx(K,{onClose:()=>{r(!0),t(ce())},anchor:"right",open:a,PaperProps:{style:{width:Pa.overlayWidth.valuePercentage(i),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:o.colors.black,opacity:.75,cursor:"pointer"}}},children:e.jsx(va,{onClick:d=>d.stopPropagation(),children:e.jsx(Aa,{vendorIdParam:n,accountContext:"express-pay"})})})},va=F(X)`
9
+ `;function Le({isEditDrawerOpen:n}){const a=U(),[r,t]=g.useState(!1),{autoTransferRulePageProps:o,isLoading:i}=(function({isEditDrawerOpen:d=!1}={}){const c=z(),p=ne(),f=G(),{ruleId:y,tenantEmailDomain:s}=W(),l=te(),{useFeatureGate:h}=Z(),m=k((u=>Ue(u))),P=k((u=>Fe(u.depositAccountState,u.depositAccountListState))),D=k((u=>_e(u))),w=k((u=>R(u))),{isFeatureEnabled:I}=h(V.isTreasuryEnabled),C=m?.fetchState??"Not-Started",A=w?.companyId??(s==null?void 0:v.getSignedInUserTenant(s)?.companyId);g.useEffect((()=>{C==="Not-Started"&&A!=null&&c(ze(!0))}),[c,C,A]);const E=m?.fetchState!=="Completed";if(E)return{autoTransferRulePageProps:void 0,isLoading:E};const T=w?.company!=null&&An(w.company),b=!!(I&&T),j=ee(l?.loggedInUserRoleMap)||$e(l?.loggedInUserRoleMap),O=v.getSignedInUser(),S={userId:O?.userId??"",sessionId:O?.zeniSessionId??"",tenantId:w?.tenantId??""},B=!!f.state?.scrollToAddRule;return{isLoading:E,autoTransferRulePageProps:{autoTransferRuleView:m,companyName:w?.companyName??"",hasAdminLevelAccess:j,includeTreasuryOption:b,transferLimit:5e5,authParams:S,currentTenant:w,depositAccountListView:P,downloadAccountDetailEndPoint:`${Ce}/account_details`,editingRuleId:y,isEditDrawerOpen:d,scrollToAddRule:B,zeniAccountsConfigDetail:D,onBackClick:()=>p(".."),onCreateRule:()=>{c(Pn())},onUpdateRule:u=>{c(me(u))},onDeleteClick:u=>{c(Sn(u))},onPauseClick:u=>{c(me(u,!0,!1))},onResumeClick:u=>{c(me(u,!1,!0))},onActivityClick:(u,M)=>{c(In(u,M))},onUpdateRuleLocalData:u=>{c(kn(u))},clearRuleLocalData:()=>{c(Dn())},onEditClick:u=>{p(`./${u}/edit`)},onEditDrawerClose:()=>{p("../../",{relative:"path"})},onReviewClick:()=>{c(wn())}}}})({isEditDrawerOpen:n});return i||o==null?e.jsx(le,{fetchState:"In-Progress",style:{backgroundColor:a.colors.grey5}}):e.jsxs(Sa,{children:[e.jsx(ue,{isAppContentDrawerOpen:r,handleDrawerToggle:d=>{t(d)}}),e.jsx(ra,{...o})]})}const Pa={overlayWidth:new Y(100,100,58)},va=({vendorId:n,isDrawerOpen:a,closeDrawerHandler:r})=>{const t=z(),o=U(),i=$();if(v.getSignedInUser()==null)throw Error("Can't access ach account page without signing in...");return e.jsx(K,{onClose:()=>{r(!0),t(ce())},anchor:"right",open:a,PaperProps:{style:{width:Pa.overlayWidth.valuePercentage(i),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:o.colors.black,opacity:.75,cursor:"pointer"}}},children:e.jsx(ba,{onClick:d=>d.stopPropagation(),children:e.jsx(Aa,{vendorIdParam:n,accountContext:"express-pay"})})})},ba=F(X)`
10
10
  display: flex;
11
11
  min-height: 100%;
12
12
  flex-direction: column;
13
- `,ja={overlayWidth:new Y(100,100,58)},Ea=({isDrawerOpen:n,closeDrawerHandler:a})=>{const r=z(),t=U(),o=$();if(b.getSignedInUser()==null)throw Error("Can't access address page without signing in...");return e.jsx(K,{onClose:()=>{a(!0),r(ce())},anchor:"right",open:n,PaperProps:{style:{width:ja.overlayWidth.valuePercentage(o),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:t.colors.black,opacity:.75,cursor:"pointer"}}},children:e.jsx(Ta,{onClick:i=>i.stopPropagation(),children:e.jsx(ka,{accountContext:"express-pay",addressTypeParam:"vendor_address"})})})},Ta=F(X)`
13
+ `,ja={overlayWidth:new Y(100,100,58)},Ea=({isDrawerOpen:n,closeDrawerHandler:a})=>{const r=z(),t=U(),o=$();if(v.getSignedInUser()==null)throw Error("Can't access address page without signing in...");return e.jsx(K,{onClose:()=>{a(!0),r(ce())},anchor:"right",open:n,PaperProps:{style:{width:ja.overlayWidth.valuePercentage(o),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:t.colors.black,opacity:.75,cursor:"pointer"}}},children:e.jsx(Ta,{onClick:i=>i.stopPropagation(),children:e.jsx(ka,{accountContext:"express-pay",addressTypeParam:"vendor_address"})})})},Ta=F(X)`
14
14
  display: flex;
15
15
  min-height: 100%;
16
16
  flex-direction: column;
17
- `,Ba={overlayWidth:new Y(100,100,58)},Oa=({vendorId:n,isDrawerOpen:a,closeDrawerHandler:r})=>{const t=z(),o=U(),i=$();if(b.getSignedInUser()==null)throw Error("Can't access ach account page without signing in...");return e.jsx(K,{onClose:()=>{r(!0),t(ce())},anchor:"right",open:a,PaperProps:{style:{width:Ba.overlayWidth.valuePercentage(i),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:o.colors.black,opacity:.75,cursor:"pointer"}}},children:e.jsx(La,{onClick:d=>d.stopPropagation(),children:e.jsx(wa,{vendorIdParam:n,accountContext:"express-pay"})})})},La=F(X)`
17
+ `,Ba={overlayWidth:new Y(100,100,58)},Oa=({vendorId:n,isDrawerOpen:a,closeDrawerHandler:r})=>{const t=z(),o=U(),i=$();if(v.getSignedInUser()==null)throw Error("Can't access ach account page without signing in...");return e.jsx(K,{onClose:()=>{r(!0),t(ce())},anchor:"right",open:a,PaperProps:{style:{width:Ba.overlayWidth.valuePercentage(i),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:o.colors.black,opacity:.75,cursor:"pointer"}}},children:e.jsx(La,{onClick:d=>d.stopPropagation(),children:e.jsx(wa,{vendorIdParam:n,accountContext:"express-pay"})})})},La=F(X)`
18
18
  display: flex;
19
19
  min-height: 100%;
20
20
  flex-direction: column;
@@ -26,15 +26,15 @@ import{j as e}from"./liveblocks-DOdRxZ-H.js";import{u as z,h as ne,g as G,i as W
26
26
  flex-direction: column;
27
27
  align-items: center;
28
28
  background-color: ${n=>n.theme.colors.grey4};
29
- `,Ua=ae((function(n,a){const r=R(n),t=b.getSignedInUser(),o=r.tenantId,i={userId:t?.userId??"",sessionId:t?.zeniSessionId??"",tenantId:o??""},d=a.expressPayDetails,c=n.entityAutoCompleteState.autoCompleteText.common,p=jn(n,"common");return{expressPayDetails:d,fileProps:{authParams:i,filesEndPoint:`${Ae.fileMicroServiceBaseUrl}`},vendorSearchAutoCompleteData:{autoCompleteText:c,entityAutoCompleteView:p},analytics:a.analytics}}),(function(n,a){const{navigate:r}=a;return{onSaveVendor:t=>{n(_n(t,void 0,void 0,!0))},saveVendorDetailLocalData:(t,o)=>{n(be({vendorId:o,localData:t}))},saveExpressPayLocalData:t=>{n(Fn({localData:t}))},onVendorSelected:t=>{t!=null&&n(Un(t,!1))},updateSelectedVendorForCreate:t=>{n(Rn(t))},initializeVendorAddress:()=>{n(Ln())},resetVendorSaveStatus:t=>{n(On({vendorId:t}))},vendorSearchAutoCompleteActions:{onAutoCompleteInputChange:(t,o)=>{t.trim().length>=2?n(Bn({searchString:t,entityType:o,searchOrigin:"common"})):t.trim().length===0&&n(ve("common"))},onCancelAutoComplete:()=>{n(ve("common"))}},chooseNewVendor:t=>{n(be({localData:{vendorName:t}}))},onClickAddAccount:t=>{t.method.toLowerCase().indexOf("ach")!==-1?r("./add-ach",{relative:"path"}):t.method.toLowerCase().indexOf("wire")!==-1&&t.method.toLowerCase().indexOf("domestic")!==-1&&r("./add-wire",{relative:"path"})},updateFilesEntity:t=>{n(Ze({files:t}))},onDeleteFile:t=>{n(Ve(t))},onEditFileName:(t,o)=>{n(Me(t,o.split(".")[0]))},onBackClick:t=>{t!=null&&n(Pe(t)),n(Pe()),n(Tn()),n(ce()),r("../",{relative:"path"})},onSchedulePayment:()=>{n(En())}}}))(ca);function se({isAddACHDrawerOpen:n,isAddWireDrawerOpen:a,isAddAddressDrawerOpen:r}){const t=ne(),o=G(),i=z(),[d,c]=g.useState(!1),{tenantEmailDomain:p}=W(),f=te(),y=k((u=>u.expressPayState.fetchState)),s=k((u=>R(u))),l=k((u=>bn(u))),h=l.expressPayLocalData?.vendorId,m=s.companyId??b.getSignedInUserTenant(p)?.companyId,[P,D]=g.useState(!1),[w,I]=g.useState(!1),[C,A]=g.useState(!1),E=Je(o.state?.pathnameStackToGoBack),{poppedPathname:T}=E,v=T?.split("/"),j=v?.[v.length-1];g.useEffect((()=>{n===!0?D(!0):(D(!1),document.body.style.overflow="auto")}),[n]),g.useEffect((()=>{a===!0?I(!0):(I(!1),document.body.style.overflow="auto")}),[a]),g.useEffect((()=>{r===!0?A(!0):(A(!1),document.body.style.overflow="auto")}),[r]),g.useEffect((()=>{y==="Not-Started"&&i(vn(!0,!0))}),[y,i]);const O=ia(l.vendorViewDetails.bankAccountCreationState?.fetchState);if(g.useEffect((()=>{O==="In-Progress"&&l.vendorViewDetails.bankAccountCreationState?.fetchState==="Completed"&&B()}),[O,l.vendorViewDetails.bankAccountCreationState?.fetchState]),b.getSignedInUser()==null)throw Error("Can't access express pay page without signing in...");const S=u=>{c(u)},B=()=>{D(!1),I(!1),t("../",{relative:"path"})};return e.jsxs(Ra,{children:[Te(o)?e.jsx(ue,{isAppContentDrawerOpen:d,handleDrawerToggle:S}):null,P===!0?e.jsx(ba,{vendorId:h,closeDrawerHandler:B,isDrawerOpen:P}):null,w===!0?e.jsx(Oa,{vendorId:h,closeDrawerHandler:B,isDrawerOpen:w}):null,C===!0?e.jsx(Ea,{closeDrawerHandler:B,isDrawerOpen:C}):null,e.jsx(Da,{vendorId:h,isExpressPayPage:!0}),e.jsx(Ua,{navigate:t,location:o,companyId:m,accountId:j,analytics:L,currentTenant:s,vendorId:h,roleMap:f?.loggedInUserRoleMap,isSettings:Te(o),expressPayDetails:l,onClickMenuIcon:()=>{S(!0)}})]})}const Fa={overlayWidth:new Y(100,100,58)},_a=({authParams:n,downloadAccountDetailEndPoint:a,isAccountInfoDrawerOpen:r,zeniBankAccountDetail:t,closeDrawerHandler:o})=>{const i=U(),d=$(),c=k((s=>_e(s))),p=k((s=>R(s)));if(b.getSignedInUser()==null)throw Error("Can't access Account detail page without signing in...");const f=()=>{o(!0)},y={depositAccount:t,onDismissClick:f,zeniAccountsConfigDetail:c,authParams:n,downloadAccountDetailEndPoint:a,currentTenant:p};return e.jsx(K,{anchor:"right",open:r,PaperProps:{style:{width:Fa.overlayWidth.valuePercentage(d),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:i.colors.black,opacity:.75,cursor:"pointer"}}},onClose:()=>f(),children:e.jsx(za,{onClick:s=>s.stopPropagation(),children:e.jsx(la,{...y})})})},za=F(X)`
29
+ `,Ua=ae((function(n,a){const r=R(n),t=v.getSignedInUser(),o=r.tenantId,i={userId:t?.userId??"",sessionId:t?.zeniSessionId??"",tenantId:o??""},d=a.expressPayDetails,c=n.entityAutoCompleteState.autoCompleteText.common,p=jn(n,"common");return{expressPayDetails:d,fileProps:{authParams:i,filesEndPoint:`${Ae.fileMicroServiceBaseUrl}`},vendorSearchAutoCompleteData:{autoCompleteText:c,entityAutoCompleteView:p},analytics:a.analytics}}),(function(n,a){const{navigate:r}=a;return{onSaveVendor:t=>{n(_n(t,void 0,void 0,!0))},saveVendorDetailLocalData:(t,o)=>{n(ve({vendorId:o,localData:t}))},saveExpressPayLocalData:t=>{n(Fn({localData:t}))},onVendorSelected:t=>{t!=null&&n(Un(t,!1))},updateSelectedVendorForCreate:t=>{n(Rn(t))},initializeVendorAddress:()=>{n(Ln())},resetVendorSaveStatus:t=>{n(On({vendorId:t}))},vendorSearchAutoCompleteActions:{onAutoCompleteInputChange:(t,o)=>{t.trim().length>=2?n(Bn({searchString:t,entityType:o,searchOrigin:"common"})):t.trim().length===0&&n(be("common"))},onCancelAutoComplete:()=>{n(be("common"))}},chooseNewVendor:t=>{n(ve({localData:{vendorName:t}}))},onClickAddAccount:t=>{t.method.toLowerCase().indexOf("ach")!==-1?r("./add-ach",{relative:"path"}):t.method.toLowerCase().indexOf("wire")!==-1&&t.method.toLowerCase().indexOf("domestic")!==-1&&r("./add-wire",{relative:"path"})},updateFilesEntity:t=>{n(Ze({files:t}))},onDeleteFile:t=>{n(Ve(t))},onEditFileName:(t,o)=>{n(Me(t,o.split(".")[0]))},onBackClick:t=>{t!=null&&n(Pe(t)),n(Pe()),n(Tn()),n(ce()),r("../",{relative:"path"})},onSchedulePayment:()=>{n(En())}}}))(ca);function se({isAddACHDrawerOpen:n,isAddWireDrawerOpen:a,isAddAddressDrawerOpen:r}){const t=ne(),o=G(),i=z(),[d,c]=g.useState(!1),{tenantEmailDomain:p}=W(),f=te(),y=k((u=>u.expressPayState.fetchState)),s=k((u=>R(u))),l=k((u=>vn(u))),h=l.expressPayLocalData?.vendorId,m=s.companyId??v.getSignedInUserTenant(p)?.companyId,[P,D]=g.useState(!1),[w,I]=g.useState(!1),[C,A]=g.useState(!1),E=Je(o.state?.pathnameStackToGoBack),{poppedPathname:T}=E,b=T?.split("/"),j=b?.[b.length-1];g.useEffect((()=>{n===!0?D(!0):(D(!1),document.body.style.overflow="auto")}),[n]),g.useEffect((()=>{a===!0?I(!0):(I(!1),document.body.style.overflow="auto")}),[a]),g.useEffect((()=>{r===!0?A(!0):(A(!1),document.body.style.overflow="auto")}),[r]),g.useEffect((()=>{y==="Not-Started"&&i(bn(!0,!0))}),[y,i]);const O=ia(l.vendorViewDetails.bankAccountCreationState?.fetchState);if(g.useEffect((()=>{O==="In-Progress"&&l.vendorViewDetails.bankAccountCreationState?.fetchState==="Completed"&&B()}),[O,l.vendorViewDetails.bankAccountCreationState?.fetchState]),v.getSignedInUser()==null)throw Error("Can't access express pay page without signing in...");const S=u=>{c(u)},B=()=>{D(!1),I(!1),t("../",{relative:"path"})};return e.jsxs(Ra,{children:[Te(o)?e.jsx(ue,{isAppContentDrawerOpen:d,handleDrawerToggle:S}):null,P===!0?e.jsx(va,{vendorId:h,closeDrawerHandler:B,isDrawerOpen:P}):null,w===!0?e.jsx(Oa,{vendorId:h,closeDrawerHandler:B,isDrawerOpen:w}):null,C===!0?e.jsx(Ea,{closeDrawerHandler:B,isDrawerOpen:C}):null,e.jsx(Da,{vendorId:h,isExpressPayPage:!0}),e.jsx(Ua,{navigate:t,location:o,companyId:m,accountId:j,analytics:L,currentTenant:s,vendorId:h,roleMap:f?.loggedInUserRoleMap,isSettings:Te(o),expressPayDetails:l,onClickMenuIcon:()=>{S(!0)}})]})}const Fa={overlayWidth:new Y(100,100,58)},_a=({authParams:n,downloadAccountDetailEndPoint:a,isAccountInfoDrawerOpen:r,zeniBankAccountDetail:t,closeDrawerHandler:o})=>{const i=U(),d=$(),c=k((s=>_e(s))),p=k((s=>R(s)));if(v.getSignedInUser()==null)throw Error("Can't access Account detail page without signing in...");const f=()=>{o(!0)},y={depositAccount:t,onDismissClick:f,zeniAccountsConfigDetail:c,authParams:n,downloadAccountDetailEndPoint:a,currentTenant:p};return e.jsx(K,{anchor:"right",open:r,PaperProps:{style:{width:Fa.overlayWidth.valuePercentage(d),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:i.colors.black,opacity:.75,cursor:"pointer"}}},onClose:()=>f(),children:e.jsx(za,{onClick:s=>s.stopPropagation(),children:e.jsx(la,{...y})})})},za=F(X)`
30
30
  display: flex;
31
31
  min-height: 100%;
32
32
  flex-direction: column;
33
- `,$a={overlayWidth:new Y(100,100,58)},an=({isCheckDepositDrawerOpen:n,closeDrawerHandler:a})=>{const r=U(),t=$(),o=z(),i=k((s=>R(s))),d=b.getSignedInUser(),c=i.tenantId,p={userId:d?.userId??"",sessionId:d?.zeniSessionId??"",tenantId:c??""};if(d==null)throw Error("Can't access check deposit page without signing in...");const f=k((s=>zn(s))),y={analytics:L,checkDeposit:f,filesEndPoint:`${Ae.fileMicroServiceBaseUrl}`,authParams:p,onSaveChangesToLocalStore:s=>{o(Mn(s))},updateFilesEntity:s=>{o(Ze({files:s}))},onAnotherTransferClick:()=>{o(ge())},onDeleteFile:s=>{o(Ve(s))},onEditFileName:(s,l)=>{o(Me(s,l.split(".")[0]))},onCheckDpositClick:()=>{o($n())},onDismissClick:()=>{a(!0),o(ge())}};return e.jsxs(e.Fragment,{children:[e.jsx(de,{analytics:L,onLoad:s=>(l=>l.trackPageLoaded(we.Event.accountsDepositCheckFormViewed))(s)}),e.jsx(K,{anchor:"right",open:n,PaperProps:{style:{width:$a.overlayWidth.valuePercentage(t),boxShadow:"none",zIndex:8}},slotProps:{backdrop:{style:{backgroundColor:r.colors.black,opacity:.75,cursor:"pointer"}}},onClose:(s,l)=>(l==="backdropClick"||l==="escapeKeyDown")&&(a(!0),void o(ge())),children:e.jsx(Ma,{onClick:s=>s.stopPropagation(),children:e.jsx(da,{...y})})})]})},Ma=F(X)`
33
+ `,$a={overlayWidth:new Y(100,100,58)},an=({isCheckDepositDrawerOpen:n,closeDrawerHandler:a})=>{const r=U(),t=$(),o=z(),i=k((s=>R(s))),d=v.getSignedInUser(),c=i.tenantId,p={userId:d?.userId??"",sessionId:d?.zeniSessionId??"",tenantId:c??""};if(d==null)throw Error("Can't access check deposit page without signing in...");const f=k((s=>zn(s))),y={analytics:L,checkDeposit:f,filesEndPoint:`${Ae.fileMicroServiceBaseUrl}`,authParams:p,onSaveChangesToLocalStore:s=>{o(Mn(s))},updateFilesEntity:s=>{o(Ze({files:s}))},onAnotherTransferClick:()=>{o(ge())},onDeleteFile:s=>{o(Ve(s))},onEditFileName:(s,l)=>{o(Me(s,l.split(".")[0]))},onCheckDpositClick:()=>{o($n())},onDismissClick:()=>{a(!0),o(ge())}};return e.jsxs(e.Fragment,{children:[e.jsx(de,{analytics:L,onLoad:s=>(l=>l.trackPageLoaded(we.Event.accountsDepositCheckFormViewed))(s)}),e.jsx(K,{anchor:"right",open:n,PaperProps:{style:{width:$a.overlayWidth.valuePercentage(t),boxShadow:"none",zIndex:8}},slotProps:{backdrop:{style:{backgroundColor:r.colors.black,opacity:.75,cursor:"pointer"}}},onClose:(s,l)=>(l==="backdropClick"||l==="escapeKeyDown")&&(a(!0),void o(ge())),children:e.jsx(Ma,{onClick:s=>s.stopPropagation(),children:e.jsx(da,{...y})})})]})},Ma=F(X)`
34
34
  display: flex;
35
35
  min-height: 100%;
36
36
  flex-direction: column;
37
- `,Va={overlayWidth:new Y(100,100,58)},Za=ae((function(n,a){const r=a.currentTenant?.companyId;return{plaidConnectionDetails:Nn(n,r,"zeni_accounts","external_account").plaidConnectionDetails,depositAccountListView:Fe(n.depositAccountState,n.depositAccountListState)}}),(function(n,a){return{onReviewClick:()=>n(Wn()),clearReviewTransferDetail:()=>n(Gn()),onFetchLinkTokenClick:r=>{n(Ne("external_account",r))},onEstablishConnectionClick:r=>{n(He(r,a.currentTenant?.companyId,"external_account",void 0,"link_external_account"))}}}))(ua),tn=({isTransferDrawerOpen:n,authParams:a,downloadAccountDetailEndPoint:r,closeDrawerHandler:t,zeniAccountsConfig:o})=>{const i=k((C=>Vn(C))),d=k((C=>R(C))),c=U(),p=$(),f=z(),{accountId:y}=W(),[s,l]=g.useState("achTransfer"),[h,m]=g.useState(!1);if(b.getSignedInUser()==null)throw Error("Can't access invite people page without signing in...");const{useDynamicConfig:P}=Z(),{configValue:D}=P(N.zeniAccountsConfig),w=he(D),I=()=>{t(!0),f(je())};return g.useEffect((()=>{i.reviewTransferDetail.fetchState==="Completed"&&m(!0)}),[m,i.reviewTransferDetail.fetchState]),e.jsxs(e.Fragment,{children:[e.jsx(de,{analytics:L,onLoad:C=>(A=>A.trackPageLoaded(we.Event.zeniAccountsTransferFormViewed))(C)}),e.jsx(K,{onClose:()=>{(s==="achTransfer"&&h===!1||s==="achTransfer"&&h&&i.fetchState==="Completed")&&I()},anchor:"right",open:n,PaperProps:{style:{width:Va.overlayWidth.valuePercentage(p),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:c.colors.black,opacity:.75,cursor:"pointer"}}},children:e.jsx(Ha,{onClick:C=>C.stopPropagation(),children:e.jsx(Za,{analytics:L,transferDetails:i,authParams:a,downloadAccountDetailEndPoint:r,onTransferClick:()=>{L.trackTransferBetweenAccountsFormClicked("Transfer",i.reviewTransferDetail.reviewTransferMoney.isShowDailyAchLimitWarning?"Review Split Transfer":"Review Transfer",i.transferDetailLocalData.transferFrom?.label,i.transferDetailLocalData.transferTo?.label,i.transferDetailLocalData.amount.amount,i.reviewTransferDetail.reviewTransferMoney.isShowDailyAchLimitWarning,i.reviewTransferDetail.reviewTransferMoney.transferSchedules.length,i.transferDetailLocalData.transferFrom?.accType==="paymentAccount"&&i.transferDetailLocalData.transferTo?.accType==="depositAccount"&&o.zeniAccountsConfigDetail.depositProductConfig.depositProducts?.[0].range?.[1]!=null&&i.transferDetailLocalData.amount.amount>o.zeniAccountsConfigDetail.depositProductConfig.depositProducts[0].range[1]),f(Hn(y))},onDismissClick:I,onSaveChangesToLocalStore:C=>{f(Zn(C))},onAnotherTransferClick:()=>{m(!1),f(je())},currentTenant:d,zeniAccountsConfigDetail:o,currentDrawerContent:s,setCurrentDrawerContent:l,showReviewContent:h,setShowReviewContent:m,onBackClick:()=>{},maxInsuredAmount:w.maxInsuredAmount})})})]})},Ha=F(X)`
37
+ `,Va={overlayWidth:new Y(100,100,58)},Za=ae((function(n,a){const r=a.currentTenant?.companyId;return{plaidConnectionDetails:Nn(n,r,"zeni_accounts","external_account").plaidConnectionDetails,depositAccountListView:Fe(n.depositAccountState,n.depositAccountListState)}}),(function(n,a){return{onReviewClick:()=>n(Wn()),clearReviewTransferDetail:()=>n(Gn()),onFetchLinkTokenClick:r=>{n(Ne("external_account",r))},onEstablishConnectionClick:r=>{n(He(r,a.currentTenant?.companyId,"external_account",void 0,"link_external_account"))}}}))(ua),tn=({isTransferDrawerOpen:n,authParams:a,downloadAccountDetailEndPoint:r,closeDrawerHandler:t,zeniAccountsConfig:o})=>{const i=k((C=>Vn(C))),d=k((C=>R(C))),c=U(),p=$(),f=z(),{accountId:y}=W(),[s,l]=g.useState("achTransfer"),[h,m]=g.useState(!1);if(v.getSignedInUser()==null)throw Error("Can't access invite people page without signing in...");const{useDynamicConfig:P}=Z(),{configValue:D}=P(N.zeniAccountsConfig),w=he(D),I=()=>{t(!0),f(je())};return g.useEffect((()=>{i.reviewTransferDetail.fetchState==="Completed"&&m(!0)}),[m,i.reviewTransferDetail.fetchState]),e.jsxs(e.Fragment,{children:[e.jsx(de,{analytics:L,onLoad:C=>(A=>A.trackPageLoaded(we.Event.zeniAccountsTransferFormViewed))(C)}),e.jsx(K,{onClose:()=>{(s==="achTransfer"&&h===!1||s==="achTransfer"&&h&&i.fetchState==="Completed")&&I()},anchor:"right",open:n,PaperProps:{style:{width:Va.overlayWidth.valuePercentage(p),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:c.colors.black,opacity:.75,cursor:"pointer"}}},children:e.jsx(Ha,{onClick:C=>C.stopPropagation(),children:e.jsx(Za,{analytics:L,transferDetails:i,authParams:a,downloadAccountDetailEndPoint:r,onTransferClick:()=>{L.trackTransferBetweenAccountsFormClicked("Transfer",i.reviewTransferDetail.reviewTransferMoney.isShowDailyAchLimitWarning?"Review Split Transfer":"Review Transfer",i.transferDetailLocalData.transferFrom?.label,i.transferDetailLocalData.transferTo?.label,i.transferDetailLocalData.amount.amount,i.reviewTransferDetail.reviewTransferMoney.isShowDailyAchLimitWarning,i.reviewTransferDetail.reviewTransferMoney.transferSchedules.length,i.transferDetailLocalData.transferFrom?.accType==="paymentAccount"&&i.transferDetailLocalData.transferTo?.accType==="depositAccount"&&o.zeniAccountsConfigDetail.depositProductConfig.depositProducts?.[0].range?.[1]!=null&&i.transferDetailLocalData.amount.amount>o.zeniAccountsConfigDetail.depositProductConfig.depositProducts[0].range[1]),f(Hn(y))},onDismissClick:I,onSaveChangesToLocalStore:C=>{f(Zn(C))},onAnotherTransferClick:()=>{m(!1),f(je())},currentTenant:d,zeniAccountsConfigDetail:o,currentDrawerContent:s,setCurrentDrawerContent:l,showReviewContent:h,setShowReviewContent:m,onBackClick:()=>{},maxInsuredAmount:w.maxInsuredAmount})})})]})},Ha=F(X)`
38
38
  display: flex;
39
39
  min-height: 100%;
40
40
  flex-direction: column;
@@ -46,7 +46,7 @@ import{j as e}from"./liveblocks-DOdRxZ-H.js";import{u as z,h as ne,g as G,i as W
46
46
  flex-direction: column;
47
47
  align-items: center;
48
48
  background-color: ${n=>n.theme.colors.grey4};
49
- `,Ga=ae((function(n,a){return{zeniAccountListView:Ge(n),isExpressPayEnabled:a.isExpressPayEnabled,analytics:a.analytics}}),(function(n,a){const{navigate:r,currentTenant:t,location:o,companyId:i,handleDrawerToggle:d,analytics:c,isBillPayEnabled:p,isDebitCardFeatureEnabled:f}=a,{tenantEmailDomain:y}=t;return{onZeniAccountClick:(s,l)=>{c.trackAccountsListPageClicked("Accounts Row Item Click",l,"active");const h=Wa(y,s),m=ie(o.state?.pathnameStackToGoBack,o.pathname);r(h,{state:{pathnameStackToGoBack:m}})},onSettingsClick:()=>{c.trackAccountsListPageClicked("Settings Icon"),r("setup")},onReloadTransactions:()=>{n(We(!1))},handleMoveMoneyOptionSelection:(s,l)=>{let h="page-not-found";s==="sendMoney"&&(h=cn(y)),s==="payBill"?h=on(t,p,f):s==="transfer"?(h=sn(y),l!=null&&n(Ke(l))):s==="checkDeposit"&&(h=rn(y));const m=ie(o.state?.pathnameStackToGoBack,o.pathname);r(h,{state:{pathnameStackToGoBack:m}})},unlinkPaymentAccount:(s,l)=>{c.trackAccountsListPageClicked("Unlink Account",l),n(Xn(s))},onFetchLinkTokenClick:(s,l)=>{n(Ne("external_account",s,l))},onUpdatePaymentAccountStatus:(s,l,h)=>{n(Kn(s,l,"zeni_accounts","external_account",h))},onEstablishConnectionClick:s=>{n(He(s,i,"external_account",void 0,"link_external_account"))},onCreateCheckingClick:s=>{n(Yn(s))},onClickMenuIcon:()=>{d(!0)},onAutoTransferClick:s=>{const l="./auto-transfer";s?r(l,{state:{...o.state,scrollToAddRule:!0}}):r(l)}}}))(ma);function fe({isTransferDrawerOpen:n,isCheckDepositDrawerOpen:a}){const r=G(),t=ne(),o=z(),i=$(),{tenantEmailDomain:d}=W(),{useDynamicConfig:c,useFeatureGate:p}=Z(),f=U(),{configValue:y}=c(N.zeniAccountsConfig),{isFeatureEnabled:s}=p(V.isDebitCardFeatureEnabled),{isFeatureEnabled:l}=p(V.isAutoTransferRuleEnabled),h=he(y),m=k((_=>R(_))),P=m.companyId??b.getSignedInUserTenant(d)?.companyId,{configValue:D}=c(N.expressPayConfig),w=D.is_enable_all_tenants===!0||D.tenant_ids!=null&&D.tenant_ids.includes(m.tenantId),[I,C]=g.useState(!1),[A,E]=g.useState(!1),[T,v]=g.useState(!1),[j,O]=g.useState(!1),S=k((_=>Ge(_))),B=S.fetchState,u=k((_=>Ue(_))),M=u?.fetchState??"Not-Started",pe=!!m.companyZeniAccountInfo?.info?.isZeniAccountEnabled,oe=te(),H=!!m.companyZeniAccountInfo?.info?.isZeniAccountTOSAccepted,q=ee(oe?.loggedInUserRoleMap),ln=ye(oe?.loggedInUserRoleMap),dn=!!m.companyBillPayInfo?.info?.isBillPayEnabled,De=b.getSignedInUser(),un={userId:De?.userId??"",sessionId:De?.zeniSessionId??"",tenantId:m.tenantId??""},pn=`${Ce}/account_details`,{areTenantIdsInSync:ke}=pa();g.useEffect((()=>{!I&&ke&&(C(!0),o(We(!1)))}),[I,o,B,ke]),g.useEffect((()=>{!A&&M==="Not-Started"&&P&&(E(!0),o(ze(!0)))}),[A,M,P,o]),g.useEffect((()=>{n!=null&&n===!0?v(!0):(v(!1),document.body.style.overflow="auto")}),[n]),g.useEffect((()=>{O(a!=null&&a===!0)}),[a]);const Ie=()=>{v(!1),t("..")},[mn,gn]=g.useState(!1),Se=_=>{gn(_)},{isAiCfoAccessEnabled:fn,onAskAiCfoClick:hn}=nn({mobileExploreReferrer:"Checking Accounts"});Qe({isDataReady:B==="Completed"});const yn=Ye(m),xn=xe(s,m);return yn===!0&&xn!==!0?e.jsx(en,{}):pe?e.jsxs(e.Fragment,{children:[S.fetchState==="Completed"&&T===!1&&j===!1?e.jsx(de,{analytics:L,onLoad:_=>(Cn=>{Cn.trackAccountsListPageViewed(S.depositAccountsSelectorView.depositAccounts.length,S.externalAccountsSelectorView.paymentAccounts.length,Be(S.summary?.totalBalance.available.amount??0),Be(S.summary?.totalInterest.available.amount??0),S.zeniAccountsConfig.zeniAccountsConfigDetail.annualPercentageYield)})(_)}):null,T===!0?e.jsx(tn,{closeDrawerHandler:Ie,isTransferDrawerOpen:T,zeniAccountsConfig:S.zeniAccountsConfig,authParams:un,downloadAccountDetailEndPoint:pn}):null,j===!0?e.jsx(an,{closeDrawerHandler:Ie,isCheckDepositDrawerOpen:j}):null,e.jsxs(Na,{windowSize:i,children:[e.jsx(ue,{isAppContentDrawerOpen:mn,handleDrawerToggle:Se}),e.jsx(Ga,{zeniBankListView:S,navigate:t,currentTenant:m,location:r,companyId:P,analytics:L,maxInsuredAmount:h.maxInsuredAmount,isExpressPayEnabled:w,isBillPayEnabled:dn,isDebitCardFeatureEnabled:s,isAutoTransferRuleEnabled:l,handleDrawerToggle:Se,isAiCfoAccessEnabled:fn,onAskAiCfoClick:hn})]})]}):H&&q?e.jsx(Q,{to:"../setup"}):m.companyZeniAccountInfo?.info&&!H&&ln?e.jsx(Q,{to:"../promo",state:r.state}):e.jsx(le,{fetchState:"In-Progress",style:{backgroundColor:f.colors.grey5}})}const on=(n,a,r)=>{const t=xe(r,n),{tenantEmailDomain:o}=n;return t===!0||a===!1?`/${o}/bills`:`/${o}/bill/new`},Wa=(n,a)=>`/${n}/checking/${a}`,sn=(n,a)=>a==null?`/${n}/checking/transfer`:`/${n}/checking/${a}/transfer`,rn=(n,a)=>a==null?`/${n}/checking/check-deposit`:`/${n}/checking/${a}/check-deposit`,cn=n=>`/${n}/checking/express-pay`,Ya=F.div`
49
+ `,Ga=ae((function(n,a){return{zeniAccountListView:Ge(n),isExpressPayEnabled:a.isExpressPayEnabled,analytics:a.analytics}}),(function(n,a){const{navigate:r,currentTenant:t,location:o,companyId:i,handleDrawerToggle:d,analytics:c,isBillPayEnabled:p,isDebitCardFeatureEnabled:f}=a,{tenantEmailDomain:y}=t;return{onZeniAccountClick:(s,l)=>{c.trackAccountsListPageClicked("Accounts Row Item Click",l,"active");const h=Wa(y,s),m=ie(o.state?.pathnameStackToGoBack,o.pathname);r(h,{state:{pathnameStackToGoBack:m}})},onSettingsClick:()=>{c.trackAccountsListPageClicked("Settings Icon"),r("setup")},onReloadTransactions:()=>{n(We(!1))},handleMoveMoneyOptionSelection:(s,l)=>{let h="page-not-found";s==="sendMoney"&&(h=cn(y)),s==="payBill"?h=on(t,p,f):s==="transfer"?(h=sn(y),l!=null&&n(Ke(l))):s==="checkDeposit"&&(h=rn(y));const m=ie(o.state?.pathnameStackToGoBack,o.pathname);r(h,{state:{pathnameStackToGoBack:m}})},unlinkPaymentAccount:(s,l)=>{c.trackAccountsListPageClicked("Unlink Account",l),n(Xn(s))},onFetchLinkTokenClick:(s,l)=>{n(Ne("external_account",s,l))},onUpdatePaymentAccountStatus:(s,l,h)=>{n(Kn(s,l,"zeni_accounts","external_account",h))},onEstablishConnectionClick:s=>{n(He(s,i,"external_account",void 0,"link_external_account"))},onCreateCheckingClick:s=>{n(Yn(s))},onClickMenuIcon:()=>{d(!0)},onAutoTransferClick:s=>{const l="./auto-transfer";s?r(l,{state:{...o.state,scrollToAddRule:!0}}):r(l)}}}))(ma);function fe({isTransferDrawerOpen:n,isCheckDepositDrawerOpen:a}){const r=G(),t=ne(),o=z(),i=$(),{tenantEmailDomain:d}=W(),{useDynamicConfig:c,useFeatureGate:p}=Z(),f=U(),{configValue:y}=c(N.zeniAccountsConfig),{isFeatureEnabled:s}=p(V.isDebitCardFeatureEnabled),{isFeatureEnabled:l}=p(V.isAutoTransferRuleEnabled),h=he(y),m=k((_=>R(_))),P=m.companyId??v.getSignedInUserTenant(d)?.companyId,{configValue:D}=c(N.expressPayConfig),w=D.is_enable_all_tenants===!0||D.tenant_ids!=null&&D.tenant_ids.includes(m.tenantId),[I,C]=g.useState(!1),[A,E]=g.useState(!1),[T,b]=g.useState(!1),[j,O]=g.useState(!1),S=k((_=>Ge(_))),B=S.fetchState,u=k((_=>Ue(_))),M=u?.fetchState??"Not-Started",pe=!!m.companyZeniAccountInfo?.info?.isZeniAccountEnabled,oe=te(),H=!!m.companyZeniAccountInfo?.info?.isZeniAccountTOSAccepted,q=ee(oe?.loggedInUserRoleMap),ln=ye(oe?.loggedInUserRoleMap),dn=!!m.companyBillPayInfo?.info?.isBillPayEnabled,De=v.getSignedInUser(),un={userId:De?.userId??"",sessionId:De?.zeniSessionId??"",tenantId:m.tenantId??""},pn=`${Ce}/account_details`,{areTenantIdsInSync:ke}=pa();g.useEffect((()=>{!I&&ke&&(C(!0),o(We(!1)))}),[I,o,B,ke]),g.useEffect((()=>{!A&&M==="Not-Started"&&P&&(E(!0),o(ze(!0)))}),[A,M,P,o]),g.useEffect((()=>{n!=null&&n===!0?b(!0):(b(!1),document.body.style.overflow="auto")}),[n]),g.useEffect((()=>{O(a!=null&&a===!0)}),[a]);const Ie=()=>{b(!1),t("..")},[mn,gn]=g.useState(!1),Se=_=>{gn(_)},{isAiCfoAccessEnabled:fn,onAskAiCfoClick:hn}=nn({mobileExploreReferrer:"Checking Accounts"});Qe({isDataReady:B==="Completed"});const yn=Ye(m),xn=xe(s,m);return yn===!0&&xn!==!0?e.jsx(en,{}):pe?e.jsxs(e.Fragment,{children:[S.fetchState==="Completed"&&T===!1&&j===!1?e.jsx(de,{analytics:L,onLoad:_=>(Cn=>{Cn.trackAccountsListPageViewed(S.depositAccountsSelectorView.depositAccounts.length,S.externalAccountsSelectorView.paymentAccounts.length,Be(S.summary?.totalBalance.available.amount??0),Be(S.summary?.totalInterest.available.amount??0),S.zeniAccountsConfig.zeniAccountsConfigDetail.annualPercentageYield)})(_)}):null,T===!0?e.jsx(tn,{closeDrawerHandler:Ie,isTransferDrawerOpen:T,zeniAccountsConfig:S.zeniAccountsConfig,authParams:un,downloadAccountDetailEndPoint:pn}):null,j===!0?e.jsx(an,{closeDrawerHandler:Ie,isCheckDepositDrawerOpen:j}):null,e.jsxs(Na,{windowSize:i,children:[e.jsx(ue,{isAppContentDrawerOpen:mn,handleDrawerToggle:Se}),e.jsx(Ga,{zeniBankListView:S,navigate:t,currentTenant:m,location:r,companyId:P,analytics:L,maxInsuredAmount:h.maxInsuredAmount,isExpressPayEnabled:w,isBillPayEnabled:dn,isDebitCardFeatureEnabled:s,isAutoTransferRuleEnabled:l,handleDrawerToggle:Se,isAiCfoAccessEnabled:fn,onAskAiCfoClick:hn})]})]}):H&&q?e.jsx(Q,{to:"../setup"}):m.companyZeniAccountInfo?.info&&!H&&ln?e.jsx(Q,{to:"../promo",state:r.state}):e.jsx(le,{fetchState:"In-Progress",style:{backgroundColor:f.colors.grey5}})}const on=(n,a,r)=>{const t=xe(r,n),{tenantEmailDomain:o}=n;return t===!0||a===!1?`/${o}/bills`:`/${o}/bill/new`},Wa=(n,a)=>`/${n}/checking/${a}`,sn=(n,a)=>a==null?`/${n}/checking/transfer`:`/${n}/checking/${a}/transfer`,rn=(n,a)=>a==null?`/${n}/checking/check-deposit`:`/${n}/checking/${a}/check-deposit`,cn=n=>`/${n}/checking/express-pay`,Ya=F.div`
50
50
  display: flex;
51
51
  width: 100%;
52
52
  flex: 1 1 auto;
@@ -54,4 +54,4 @@ import{j as e}from"./liveblocks-DOdRxZ-H.js";import{u as z,h as ne,g as G,i as W
54
54
  align-items: center;
55
55
  min-height: 100vh;
56
56
  background-color: ${n=>n.theme.colors.grey4};
57
- `,Ka=ae((function(n,a){const{currentTenant:r}=a,t=Xe(n,a.accountId),o=b.getSignedInUser(),i=n.tenantState.currentTenantId,d={userId:o?.userId??"",sessionId:o?.zeniSessionId??"",tenantId:i??""},c=t.accountDetail?.id??"";return{currentTenantCompanyName:r.companyName??"",authParams:d,downloadEndPoint:`${Ae.bankingMicroServiceBaseUrl}/1.0/deposit-accounts/${c}`,zeniAccountDetail:t,isExpressPayEnabled:a.isExpressPayEnabled,fetchState:t.fetchState}}),(function(n,a){const{navigate:r,currentTenant:t,location:o,accountId:i}=a,{tenantEmailDomain:d}=t;return{handleMoveMoneyOptionSelection:(c,p)=>{let f="page-not-found";c==="sendMoney"?f=cn(d):c==="payBill"?f=on(t,a.isBillPayEnabled,a.isDebitCardFeatureEnabled):c==="transfer"?(f=sn(d,i),p!=null&&n(Ke(p))):c==="checkDeposit"?(f=rn(d,i),p!=null&&n(qn(p))):c==="accountStatement"&&(f=qa(d,i));const y=ie(o.state?.pathnameStackToGoBack,o.pathname);r(f,{state:{pathnameStackToGoBack:y}})},onAccountDetailClick:()=>{const c=Xa(d,i),p=ie(o.state?.pathnameStackToGoBack,o.pathname);r(c,{state:{pathnameStackToGoBack:p}})},onEditNameClick:c=>{n(Ee(i,"editName",c))},onReloadZeniAccountDetailPage:()=>{n(qe(i,!1))},onCloseAccountClick:()=>{n(Ee(i,"closeAccount",""))},onBackClick:()=>{r("../",{relative:"path"})}}}))(ga);function re({isTransferDrawerOpen:n,isCheckDepositDrawerOpen:a,isAccountInfoDrawerOpen:r}){const t=G(),o=ne(),i=z(),d=$(),{tenantEmailDomain:c,accountId:p}=W(),{useDynamicConfig:f}=Z(),{useFeatureGate:y}=Z(),{isFeatureEnabled:s}=y(V.isDebitCardFeatureEnabled),l=k((q=>R(q))),{configValue:h}=f(N.expressPayConfig),m=h.is_enable_all_tenants===!0||h.tenant_ids!=null&&h.tenant_ids.includes(l.tenantId),P=!!l.companyBillPayInfo?.info?.isBillPayEnabled,D=b.getSignedInUser(),w=l.companyId??b.getSignedInUserTenant(c)?.companyId,I={userId:D?.userId??"",sessionId:D?.zeniSessionId??"",tenantId:l.tenantId??""},C=`${Ce}/account_details`,[A,E]=g.useState(!1),[T,v]=g.useState(!1),[j,O]=g.useState(!1),[S,B]=g.useState(!1),u=k((q=>Xe(q,p??""))),M=u.fetchState,{isAiCfoAccessEnabled:pe,onAskAiCfoClick:oe}=nn({mobileExploreReferrer:"Checking Account Detail"});Qe({isDataReady:M==="Completed"}),g.useEffect((()=>{A||(i(qe(p??"",!1)),E(!0))}),[A,i,M]),g.useEffect((()=>{B(r!=null&&r===!0)}),[r]),g.useEffect((()=>{n!=null&&n===!0?v(!0):(v(!1),document.body.style.overflow="auto")}),[n]),g.useEffect((()=>{O(a!=null&&a===!0)}),[a]);const H=()=>{B(!1),o("..")};return e.jsxs(e.Fragment,{children:[S===!0&&u.accountDetail!=null?e.jsx(_a,{authParams:I,downloadAccountDetailEndPoint:C,closeDrawerHandler:H,isAccountInfoDrawerOpen:S,zeniBankAccountDetail:u.accountDetail}):null,T===!0?e.jsx(tn,{closeDrawerHandler:H,isTransferDrawerOpen:T,zeniAccountsConfig:u.zeniAccountsConfig,authParams:I,downloadAccountDetailEndPoint:C}):null,j===!0?e.jsx(an,{closeDrawerHandler:H,isCheckDepositDrawerOpen:j}):null,e.jsx(Ya,{windowSize:d,children:e.jsx(Ka,{navigate:o,currentTenant:l,location:t,companyId:w,isDebitCardFeatureEnabled:s,accountId:p??"",isBillPayEnabled:P,isExpressPayEnabled:m,isAiCfoAccessEnabled:pe,onAskAiCfoClick:oe})})]})}const Xa=(n,a)=>`/${n}/checking/${a}/account-info`,qa=(n,a)=>`/${n}/checking/${a}/statements`,Ja=ae((function(n,a){const{companyId:r}=a;return{zeniAccountSetupView:Jn(n,r)}}),(function(n,a){const{navigate:r,companyId:t}=a;return{onSetupButtonClick:()=>{L.trackAccountsPromoPageClicked("Setup Accounts"),n(Qn(t))},onBackClick:()=>{r("../..",{relative:"path"})},onSetupZeniAccountSuccess:()=>{r("../setup",{relative:"path"})}}}))(ya),Qa=()=>{const n=ne(),a=G(),{tenantEmailDomain:r}=W(),{useDynamicConfig:t}=Z(),o=fa(),i=U(),[d,c]=g.useState(!1),[p,f]=g.useState(!1),y=k((A=>R(A))),{configValue:s}=t(N.zeniAccountsConfig),l=he(s);g.useEffect((()=>{p===!1&&a.state?.message==="activation"&&f(!0)}),[a.state]);const h=b.getSignedInUserTenant(r)?.companyId??y.companyId,m=b.getSignedInUser(),P=!!y.companyZeniAccountInfo?.info?.isZeniAccountTOSAccepted,D=A=>{c(A)};if(m==null)throw Error("Can't access Zeni account promo page without signing in...");const w=te(),I=ee(w?.loggedInUserRoleMap),C=ye(w?.loggedInUserRoleMap);if(P&&I)return e.jsx(Q,{to:"../../checking/setup"});if(y.company?.companyZeniAccountInfo&&(!P&&I||C)){if(a.state?.message==="activation"){const A=Je(a.state?.pathnameStackToGoBack);n(a.pathname,{state:{...a.state,message:void 0,pathnameStackToGoBack:A.newStack}})}return e.jsxs(e.Fragment,{children:[e.jsx(ha,{showConfetti:p}),e.jsx(de,{analytics:L,onLoad:A=>(E=>E.trackPageLoaded(we.Event.accountsPromoPageViewed))(A)}),e.jsx(ue,{isAppContentDrawerOpen:d,handleDrawerToggle:D}),e.jsx(Ja,{analytics:L,navigate:n,companyId:h,meetingUrl:o("zeni_accounts_promo"),onClickMenuIcon:()=>{D(!0)},maxAnnualPercentageYield:l.maxAnnualPercentageYield,maxInsuredAmount:l.maxInsuredAmount,exampleBankBalance:3e6})]})}return e.jsx(le,{fetchState:"In-Progress",style:{backgroundColor:i.colors.grey5}})};function jt(){const n=G(),a=k((S=>R(S))),r=U(),{useFeatureGate:t,useDynamicConfig:o}=Z(),i=te(),d=ee(i?.loggedInUserRoleMap),c=ye(i?.loggedInUserRoleMap),p=!!a.company?.companyZeniAccountInfo?.isZeniAccountEnabled,f=!!a.company?.companyZeniAccountInfo?.isZeniAccountTOSAccepted,{isFeatureEnabled:y}=t(V.isChargeCardFeatureEnabled),{isFeatureEnabled:s}=t(V.isDebitCardFeatureEnabled),l=Ye(a),h=xe(s,a),m=a?.userRole!=null&&ea(a?.userRole),P=(a?.company==null||a.company.featuresActivationInfo?.isBillPayFeatureEnabled&&!m)&&na(i?.loggedInUserRoleMap),D=aa(i?.loggedInUserRoleMap),w=(a?.company==null||a.company.featuresActivationInfo?.isReimbursementFeatureEnabled&&!m)&&ta(i?.loggedInUserRoleMap),I=!!a.company?.companyZeniAccountInfo?.isZeniAccountEnabled&&!m,{configValue:C}=o(N.expressPayConfig),A=C.is_enable_all_tenants===!0||C.tenant_ids!=null&&C.tenant_ids.includes(a.tenantId),{isFeatureEnabled:E}=t(V.isAutoTransferRuleEnabled),T=xa(a,y,s)&&!m&&oa(i?.loggedInUserRoleMap),v=sa(i?.loggedInUserRoleMap),j=I&&ee(i?.loggedInUserRoleMap),O=j||$e(i?.loggedInUserRoleMap);return e.jsxs(Re,{children:[e.jsx(x,{path:"setup",element:e.jsx(Oe,{isBillPayAdminLevelAccess:P,isUserHasOnlyBillPayAccess:D,isReimbursementAdminLevelAccess:w,isZeniAccountAdminLevelAccess:j,isChargeCardAdminLevelAccess:T,isUserHasOnlyCardAccess:v,productType:"zeni_accounts",type:"setup"})}),e.jsx(x,{path:"verification",element:e.jsx(Oe,{isBillPayAdminLevelAccess:P,isUserHasOnlyBillPayAccess:D,isReimbursementAdminLevelAccess:w,isZeniAccountAdminLevelAccess:j,isChargeCardAdminLevelAccess:T,isUserHasOnlyCardAccess:v,productType:"zeni_accounts",type:"verification"})}),E?e.jsxs(e.Fragment,{children:[e.jsx(x,{path:"auto-transfer",element:e.jsx(Le,{})}),O?e.jsx(x,{path:"auto-transfer/:ruleId/edit",element:e.jsx(Le,{isEditDrawerOpen:!0})}):null]}):e.jsx(x,{path:"auto-transfer",element:e.jsx(J,{})}),A&&d?e.jsxs(e.Fragment,{children:[e.jsx(x,{path:"express-pay",element:e.jsx(se,{})}),e.jsx(x,{path:"express-pay/add-ach",element:e.jsx(se,{isAddACHDrawerOpen:!0})}),e.jsx(x,{path:"express-pay/add-wire/add-address",element:e.jsx(se,{isAddAddressDrawerOpen:!0})}),e.jsx(x,{path:"express-pay/add-wire",element:e.jsx(se,{isAddWireDrawerOpen:!0})})]}):e.jsx(x,{path:"express-pay",element:e.jsx(J,{})}),e.jsx(x,{path:"promo",element:e.jsx(Qa,{})}),l&&!h?e.jsx(x,{path:"/*",element:e.jsx(en,{})}):p?e.jsxs(e.Fragment,{children:[e.jsx(x,{path:"/",element:e.jsx(fe,{})}),e.jsx(x,{path:"transfer",element:e.jsx(fe,{isTransferDrawerOpen:!0})}),e.jsx(x,{path:"check-deposit",element:e.jsx(fe,{isCheckDepositDrawerOpen:!0})}),e.jsx(x,{path:"cash_management/*",element:e.jsx(J,{})}),e.jsx(x,{path:":accountId/*",element:e.jsx(et,{})}),e.jsx(x,{path:"*",element:e.jsx(J,{})})]}):f&&d?e.jsx(x,{path:"*",element:e.jsx(Q,{to:"../setup"})}):a.company?.companyZeniAccountInfo&&c?e.jsx(x,{path:"*",element:e.jsx(Q,{to:"../promo",state:n.state})}):e.jsx(x,{path:"*",element:e.jsx(le,{fetchState:"In-Progress",style:{backgroundColor:r.colors.grey5,boxShadow:`0px 2px ${Ca.sp1} ${r.colors.dropShadowNormal}`}})})]})}function et(){return e.jsxs(Re,{children:[e.jsx(x,{path:"/",element:e.jsx(re,{})}),e.jsx(x,{path:"account-info",element:e.jsx(re,{isAccountInfoDrawerOpen:!0})}),e.jsx(x,{path:"transfer",element:e.jsx(re,{isTransferDrawerOpen:!0})}),e.jsx(x,{path:"check-deposit",element:e.jsx(re,{isCheckDepositDrawerOpen:!0})}),e.jsx(x,{path:"statements",element:e.jsx(Ia,{})}),e.jsx(x,{path:"*",element:e.jsx(J,{})})]})}export{jt as default};
57
+ `,Ka=ae((function(n,a){const{currentTenant:r}=a,t=Xe(n,a.accountId),o=v.getSignedInUser(),i=n.tenantState.currentTenantId,d={userId:o?.userId??"",sessionId:o?.zeniSessionId??"",tenantId:i??""},c=t.accountDetail?.id??"";return{currentTenantCompanyName:r.companyName??"",authParams:d,downloadEndPoint:`${Ae.bankingMicroServiceBaseUrl}/1.0/deposit-accounts/${c}`,zeniAccountDetail:t,isExpressPayEnabled:a.isExpressPayEnabled,fetchState:t.fetchState}}),(function(n,a){const{navigate:r,currentTenant:t,location:o,accountId:i}=a,{tenantEmailDomain:d}=t;return{handleMoveMoneyOptionSelection:(c,p)=>{let f="page-not-found";c==="sendMoney"?f=cn(d):c==="payBill"?f=on(t,a.isBillPayEnabled,a.isDebitCardFeatureEnabled):c==="transfer"?(f=sn(d,i),p!=null&&n(Ke(p))):c==="checkDeposit"?(f=rn(d,i),p!=null&&n(qn(p))):c==="accountStatement"&&(f=qa(d,i));const y=ie(o.state?.pathnameStackToGoBack,o.pathname);r(f,{state:{pathnameStackToGoBack:y}})},onAccountDetailClick:()=>{const c=Xa(d,i),p=ie(o.state?.pathnameStackToGoBack,o.pathname);r(c,{state:{pathnameStackToGoBack:p}})},onEditNameClick:c=>{n(Ee(i,"editName",c))},onReloadZeniAccountDetailPage:()=>{n(qe(i,!1))},onCloseAccountClick:()=>{n(Ee(i,"closeAccount",""))},onBackClick:()=>{r("../",{relative:"path"})}}}))(ga);function re({isTransferDrawerOpen:n,isCheckDepositDrawerOpen:a,isAccountInfoDrawerOpen:r}){const t=G(),o=ne(),i=z(),d=$(),{tenantEmailDomain:c,accountId:p}=W(),{useDynamicConfig:f}=Z(),{useFeatureGate:y}=Z(),{isFeatureEnabled:s}=y(V.isDebitCardFeatureEnabled),l=k((q=>R(q))),{configValue:h}=f(N.expressPayConfig),m=h.is_enable_all_tenants===!0||h.tenant_ids!=null&&h.tenant_ids.includes(l.tenantId),P=!!l.companyBillPayInfo?.info?.isBillPayEnabled,D=v.getSignedInUser(),w=l.companyId??v.getSignedInUserTenant(c)?.companyId,I={userId:D?.userId??"",sessionId:D?.zeniSessionId??"",tenantId:l.tenantId??""},C=`${Ce}/account_details`,[A,E]=g.useState(!1),[T,b]=g.useState(!1),[j,O]=g.useState(!1),[S,B]=g.useState(!1),u=k((q=>Xe(q,p??""))),M=u.fetchState,{isAiCfoAccessEnabled:pe,onAskAiCfoClick:oe}=nn({mobileExploreReferrer:"Checking Account Detail"});Qe({isDataReady:M==="Completed"}),g.useEffect((()=>{A||(i(qe(p??"",!1)),E(!0))}),[A,i,M]),g.useEffect((()=>{B(r!=null&&r===!0)}),[r]),g.useEffect((()=>{n!=null&&n===!0?b(!0):(b(!1),document.body.style.overflow="auto")}),[n]),g.useEffect((()=>{O(a!=null&&a===!0)}),[a]);const H=()=>{B(!1),o("..")};return e.jsxs(e.Fragment,{children:[S===!0&&u.accountDetail!=null?e.jsx(_a,{authParams:I,downloadAccountDetailEndPoint:C,closeDrawerHandler:H,isAccountInfoDrawerOpen:S,zeniBankAccountDetail:u.accountDetail}):null,T===!0?e.jsx(tn,{closeDrawerHandler:H,isTransferDrawerOpen:T,zeniAccountsConfig:u.zeniAccountsConfig,authParams:I,downloadAccountDetailEndPoint:C}):null,j===!0?e.jsx(an,{closeDrawerHandler:H,isCheckDepositDrawerOpen:j}):null,e.jsx(Ya,{windowSize:d,children:e.jsx(Ka,{navigate:o,currentTenant:l,location:t,companyId:w,isDebitCardFeatureEnabled:s,accountId:p??"",isBillPayEnabled:P,isExpressPayEnabled:m,isAiCfoAccessEnabled:pe,onAskAiCfoClick:oe})})]})}const Xa=(n,a)=>`/${n}/checking/${a}/account-info`,qa=(n,a)=>`/${n}/checking/${a}/statements`,Ja=ae((function(n,a){const{companyId:r}=a;return{zeniAccountSetupView:Jn(n,r)}}),(function(n,a){const{navigate:r,companyId:t}=a;return{onSetupButtonClick:()=>{L.trackAccountsPromoPageClicked("Setup Accounts"),n(Qn(t))},onBackClick:()=>{r("../..",{relative:"path"})},onSetupZeniAccountSuccess:()=>{r("../setup",{relative:"path"})}}}))(ya),Qa=()=>{const n=ne(),a=G(),{tenantEmailDomain:r}=W(),{useDynamicConfig:t}=Z(),o=fa(),i=U(),[d,c]=g.useState(!1),[p,f]=g.useState(!1),y=k((A=>R(A))),{configValue:s}=t(N.zeniAccountsConfig),l=he(s);g.useEffect((()=>{p===!1&&a.state?.message==="activation"&&f(!0)}),[a.state]);const h=v.getSignedInUserTenant(r)?.companyId??y.companyId,m=v.getSignedInUser(),P=!!y.companyZeniAccountInfo?.info?.isZeniAccountTOSAccepted,D=A=>{c(A)};if(m==null)throw Error("Can't access Zeni account promo page without signing in...");const w=te(),I=ee(w?.loggedInUserRoleMap),C=ye(w?.loggedInUserRoleMap);if(P&&I)return e.jsx(Q,{to:"../../checking/setup"});if(y.company?.companyZeniAccountInfo&&(!P&&I||C)){if(a.state?.message==="activation"){const A=Je(a.state?.pathnameStackToGoBack);n(a.pathname,{state:{...a.state,message:void 0,pathnameStackToGoBack:A.newStack}})}return e.jsxs(e.Fragment,{children:[e.jsx(ha,{showConfetti:p}),e.jsx(de,{analytics:L,onLoad:A=>(E=>E.trackPageLoaded(we.Event.accountsPromoPageViewed))(A)}),e.jsx(ue,{isAppContentDrawerOpen:d,handleDrawerToggle:D}),e.jsx(Ja,{analytics:L,navigate:n,companyId:h,meetingUrl:o("zeni_accounts_promo"),onClickMenuIcon:()=>{D(!0)},maxAnnualPercentageYield:l.maxAnnualPercentageYield,maxInsuredAmount:l.maxInsuredAmount,exampleBankBalance:3e6})]})}return e.jsx(le,{fetchState:"In-Progress",style:{backgroundColor:i.colors.grey5}})};function jt(){const n=G(),a=k((S=>R(S))),r=U(),{useFeatureGate:t,useDynamicConfig:o}=Z(),i=te(),d=ee(i?.loggedInUserRoleMap),c=ye(i?.loggedInUserRoleMap),p=!!a.company?.companyZeniAccountInfo?.isZeniAccountEnabled,f=!!a.company?.companyZeniAccountInfo?.isZeniAccountTOSAccepted,{isFeatureEnabled:y}=t(V.isChargeCardFeatureEnabled),{isFeatureEnabled:s}=t(V.isDebitCardFeatureEnabled),l=Ye(a),h=xe(s,a),m=a?.userRole!=null&&ea(a?.userRole),P=(a?.company==null||a.company.featuresActivationInfo?.isBillPayFeatureEnabled&&!m)&&na(i?.loggedInUserRoleMap),D=aa(i?.loggedInUserRoleMap),w=(a?.company==null||a.company.featuresActivationInfo?.isReimbursementFeatureEnabled&&!m)&&ta(i?.loggedInUserRoleMap),I=!!a.company?.companyZeniAccountInfo?.isZeniAccountEnabled&&!m,{configValue:C}=o(N.expressPayConfig),A=C.is_enable_all_tenants===!0||C.tenant_ids!=null&&C.tenant_ids.includes(a.tenantId),{isFeatureEnabled:E}=t(V.isAutoTransferRuleEnabled),T=xa(a,y,s)&&!m&&oa(i?.loggedInUserRoleMap),b=sa(i?.loggedInUserRoleMap),j=I&&ee(i?.loggedInUserRoleMap),O=j||$e(i?.loggedInUserRoleMap);return e.jsxs(Re,{children:[e.jsx(x,{path:"setup",element:e.jsx(Oe,{isBillPayAdminLevelAccess:P,isUserHasOnlyBillPayAccess:D,isReimbursementAdminLevelAccess:w,isZeniAccountAdminLevelAccess:j,isChargeCardAdminLevelAccess:T,isUserHasOnlyCardAccess:b,productType:"zeni_accounts",type:"setup"})}),e.jsx(x,{path:"verification",element:e.jsx(Oe,{isBillPayAdminLevelAccess:P,isUserHasOnlyBillPayAccess:D,isReimbursementAdminLevelAccess:w,isZeniAccountAdminLevelAccess:j,isChargeCardAdminLevelAccess:T,isUserHasOnlyCardAccess:b,productType:"zeni_accounts",type:"verification"})}),E?e.jsxs(e.Fragment,{children:[e.jsx(x,{path:"auto-transfer",element:e.jsx(Le,{})}),O?e.jsx(x,{path:"auto-transfer/:ruleId/edit",element:e.jsx(Le,{isEditDrawerOpen:!0})}):null]}):e.jsx(x,{path:"auto-transfer",element:e.jsx(J,{})}),A&&d?e.jsxs(e.Fragment,{children:[e.jsx(x,{path:"express-pay",element:e.jsx(se,{})}),e.jsx(x,{path:"express-pay/add-ach",element:e.jsx(se,{isAddACHDrawerOpen:!0})}),e.jsx(x,{path:"express-pay/add-wire/add-address",element:e.jsx(se,{isAddAddressDrawerOpen:!0})}),e.jsx(x,{path:"express-pay/add-wire",element:e.jsx(se,{isAddWireDrawerOpen:!0})})]}):e.jsx(x,{path:"express-pay",element:e.jsx(J,{})}),e.jsx(x,{path:"promo",element:e.jsx(Qa,{})}),l&&!h?e.jsx(x,{path:"/*",element:e.jsx(en,{})}):p?e.jsxs(e.Fragment,{children:[e.jsx(x,{path:"/",element:e.jsx(fe,{})}),e.jsx(x,{path:"transfer",element:e.jsx(fe,{isTransferDrawerOpen:!0})}),e.jsx(x,{path:"check-deposit",element:e.jsx(fe,{isCheckDepositDrawerOpen:!0})}),e.jsx(x,{path:"cash_management/*",element:e.jsx(J,{})}),e.jsx(x,{path:":accountId/*",element:e.jsx(et,{})}),e.jsx(x,{path:"*",element:e.jsx(J,{})})]}):f&&d?e.jsx(x,{path:"*",element:e.jsx(Q,{to:"../setup"})}):a.company?.companyZeniAccountInfo&&c?e.jsx(x,{path:"*",element:e.jsx(Q,{to:"../promo",state:n.state})}):e.jsx(x,{path:"*",element:e.jsx(le,{fetchState:"In-Progress",style:{backgroundColor:r.colors.grey5,boxShadow:`0px 2px ${Ca.sp1} ${r.colors.dropShadowNormal}`}})})]})}function et(){return e.jsxs(Re,{children:[e.jsx(x,{path:"/",element:e.jsx(re,{})}),e.jsx(x,{path:"account-info",element:e.jsx(re,{isAccountInfoDrawerOpen:!0})}),e.jsx(x,{path:"transfer",element:e.jsx(re,{isTransferDrawerOpen:!0})}),e.jsx(x,{path:"check-deposit",element:e.jsx(re,{isCheckDepositDrawerOpen:!0})}),e.jsx(x,{path:"statements",element:e.jsx(Ia,{})}),e.jsx(x,{path:"*",element:e.jsx(J,{})})]})}export{jt as default};
@@ -1,4 +1,4 @@
1
- import{j as i}from"./liveblocks-DOdRxZ-H.js";import{a as m}from"./sentry-DvoFEQx8.js";import{h as x,u as T,g as $,i as j,j as p}from"./core-R1zvmcG1.js";import{TR as s,TQ as v,a0e as B,fI as C,a0f as z}from"./zeni-epic-state-Mdu-dKQU.js";import{_ as D,ac as g,z as E,a5 as L,d3 as P,a2 as _}from"./index-Cvus_VBr.js";import{u as N,n as U}from"./mui-ZKvbmPSP.js";(function(){try{var a=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},n=new a.Error().stack;n&&(a._sentryDebugIds=a._sentryDebugIds||{},a._sentryDebugIds[n]="73821a1d-b44f-4885-aa5c-f92906a23433",a._sentryDebugIdIdentifier="sentry-dbid-73821a1d-b44f-4885-aa5c-f92906a23433")}catch{}})();const G=U.div`
1
+ import{j as i}from"./liveblocks-BYqz0SWy.js";import{a as m}from"./sentry-DjmIorbX.js";import{h as x,u as T,g as $,i as j,j as p}from"./core-B1R51LGS.js";import{TR as s,TQ as v,a0e as B,fI as C,a0f as z}from"./zeni-epic-state-M9sMLOaG.js";import{_ as D,ac as g,z as E,a5 as L,d3 as P,a2 as _}from"./index-Dp_Uc3gy.js";import{u as N,n as U}from"./mui-D-_RYGgU.js";(function(){try{var a=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},n=new a.Error().stack;n&&(a._sentryDebugIds=a._sentryDebugIds||{},a._sentryDebugIds[n]="73821a1d-b44f-4885-aa5c-f92906a23433",a._sentryDebugIdIdentifier="sentry-dbid-73821a1d-b44f-4885-aa5c-f92906a23433")}catch{}})();const G=U.div`
2
2
  display: flex;
3
3
  height: 100vh;
4
4
  width: 100%;
@@ -1 +1 @@
1
- import"./sentry-DvoFEQx8.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]="459d6150-40e4-4fe0-88f2-7336312ca00a",e._sentryDebugIdIdentifier="sentry-dbid-459d6150-40e4-4fe0-88f2-7336312ca00a")}catch{}})();function d(e,t){if(t!=null)return e.find((n=>n.qboId===t))}function i(e,t){return e.filter((n=>n.qboId!=null&&t.includes(n.qboId)))}function s(e,t){return t.map((n=>({accountId:d(e,n.accountId.selectedOption)?.accountId??"",expenseType:n.expenseType.selectedOption??"",type1099:n.type1099.selectedOption??"",boxType:n.boxType.selectedOption??""})))}export{i as a,d as g,s as m};
1
+ import"./sentry-DjmIorbX.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]="459d6150-40e4-4fe0-88f2-7336312ca00a",e._sentryDebugIdIdentifier="sentry-dbid-459d6150-40e4-4fe0-88f2-7336312ca00a")}catch{}})();function d(e,t){if(t!=null)return e.find((n=>n.qboId===t))}function i(e,t){return e.filter((n=>n.qboId!=null&&t.includes(n.qboId)))}function s(e,t){return t.map((n=>({accountId:d(e,n.accountId.selectedOption)?.accountId??"",expenseType:n.expenseType.selectedOption??"",type1099:n.type1099.selectedOption??"",boxType:n.boxType.selectedOption??""})))}export{i as a,d as g,s as m};