@zeniai/web-app-ui 5.4.5-qa → 5.4.6-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 (130) hide show
  1. package/dist/assets/{AccountMappingScreen-BWKnAhO1.js → AccountMappingScreen-SCZflztG.js} +2 -2
  2. package/dist/assets/{ActualMatchingMatchDetailScreen-prrMNk5W.js → ActualMatchingMatchDetailScreen-7ejDN7L9.js} +1 -1
  3. package/dist/assets/AddressRoutes-CLELuUsR.js +1 -0
  4. package/dist/assets/{AddressScreen-DV_seWrj.js → AddressScreen-B0Rw7Meo.js} +2 -2
  5. package/dist/assets/{AiCfoScreen-BxsT0eIz.js → AiCfoScreen-DKJ-p6eF.js} +1 -1
  6. package/dist/assets/{AppDrawer-DZQvsWt-.js → AppDrawer-BKB3zk04.js} +1 -1
  7. package/dist/assets/{BillPayApprovalRoutes-Bju1WCIG.js → BillPayApprovalRoutes-BtDxRLl1.js} +1 -1
  8. package/dist/assets/{BillPayRoutes-B5C1sy74.js → BillPayRoutes-6REomPK2.js} +1 -1
  9. package/dist/assets/{BusinessVerificationPageScreen-CHnv9h-G.js → BusinessVerificationPageScreen-BMf-N2Vi.js} +2 -2
  10. package/dist/assets/{CardsAiCfoScreen-9EMasO85.js → CardsAiCfoScreen-CqJShJeB.js} +1 -1
  11. package/dist/assets/{ChargeCardRoutes-BaMQHWSk.js → ChargeCardRoutes-D7tv1fBd.js} +8 -8
  12. package/dist/assets/CompanyPassportScreen-4AwGBpLN.js +1 -0
  13. package/dist/assets/ConnectionAuthScreen-z5NU1m6z.js +11 -0
  14. package/dist/assets/CustomerOnboardingAuthScreen-DnVfkWnJ.js +1 -0
  15. package/dist/assets/{CustomerOnboardingRoutes-BG8C7Jsp.js → CustomerOnboardingRoutes-xhreU1r_.js} +1 -1
  16. package/dist/assets/{DashboardRoutes-BaCf_oaP.js → DashboardRoutes-BuO07ghp.js} +1 -1
  17. package/dist/assets/{DefaultTenantHome-BVwxetH2.js → DefaultTenantHome-BC5rOeXI.js} +1 -1
  18. package/dist/assets/{DomesticWireDetailScreen-DGJN9xE3.js → DomesticWireDetailScreen-CaGljNLv.js} +3 -3
  19. package/dist/assets/{DrawerScreen-7VKOEAfQ.js → DrawerScreen-rHSg_gue.js} +1 -1
  20. package/dist/assets/EntityDetailRoutes--MdngBIG.js +1 -0
  21. package/dist/assets/ExpenseAutomationRoutes-DYmcRf2Y.js +38 -0
  22. package/dist/assets/FeaturePreviewScreen-DC7afd7c.js +1 -0
  23. package/dist/assets/{HubSpotOAuthCallbackScreen-C4TussO5.js → HubSpotOAuthCallbackScreen-C0xL_x_3.js} +1 -1
  24. package/dist/assets/{InboxNotificationsProvider-DdFv467m.js → InboxNotificationsProvider-CzmfZzrH.js} +1 -1
  25. package/dist/assets/{InvoicingRoutes-A2F2Idkk.js → InvoicingRoutes-DXTxFFRs.js} +2 -2
  26. package/dist/assets/{MagicLinkRoutes-GG9-asD0.js → MagicLinkRoutes-BFmbM5yx.js} +20 -20
  27. package/dist/assets/{MagicLinkSignInScreen-BNXc2Z47.js → MagicLinkSignInScreen-CHrNWiKa.js} +1 -1
  28. package/dist/assets/MobileAppDrawer-bVKqFYWU.js +1 -0
  29. package/dist/assets/NotFoundScreen-hkzdCFF0.js +1 -0
  30. package/dist/assets/{NotificationRoutes-B6qCEhEA.js → NotificationRoutes-CYDbuufR.js} +1 -1
  31. package/dist/assets/{OAuthConsentScreen-ByDEEtm9.js → OAuthConsentScreen-DZDpd-Z-.js} +1 -1
  32. package/dist/assets/{PandLWithForecastRoutes-BThOUwkA.js → PandLWithForecastRoutes-CFLi_CxP.js} +1 -1
  33. package/dist/assets/{PaymentLinkScreen-DLDtN7x9.js → PaymentLinkScreen-CpdHRn1U.js} +5 -5
  34. package/dist/assets/{PeopleRoutes-DP9DNcZj.js → PeopleRoutes-AJ554iC2.js} +3 -3
  35. package/dist/assets/{PerformanceRoutes-BdmV3UkN.js → PerformanceRoutes-D8I4kb3U.js} +1 -1
  36. package/dist/assets/{Preview-oDCzP_I-.js → Preview-BCw1uWDH.js} +1 -1
  37. package/dist/assets/{QBOConnectionScreen-DnvAmBm7.js → QBOConnectionScreen-BGhOi3fX.js} +1 -1
  38. package/dist/assets/{ReimbursementApprovalRoutes-D-tFMhkM.js → ReimbursementApprovalRoutes-BtmeGKGb.js} +1 -1
  39. package/dist/assets/{ReimbursementApprovalRuleDetailScreen-BdcBQ2Fs.js → ReimbursementApprovalRuleDetailScreen-BsbNzk3P.js} +1 -1
  40. package/dist/assets/{ReimbursementRoutes-B-L5JkAX.js → ReimbursementRoutes-BRTQNUHH.js} +4 -4
  41. package/dist/assets/{ReportsRoutes-CAe6aO_T.js → ReportsRoutes-BYZqoije.js} +1 -1
  42. package/dist/assets/RewardsRoutes-BsHY1Ep_.js +1 -0
  43. package/dist/assets/{ScheduleDetailsPrepaidExpensesScreen-DsoZ7iR9.js → ScheduleDetailsPrepaidExpensesScreen-fz7l0JQi.js} +1 -1
  44. package/dist/assets/ScreenRoutes-qNFwM728.js +2 -0
  45. package/dist/assets/{SettingsRoutes-BptMaUzQ.js → SettingsRoutes-Djet13lj.js} +5 -5
  46. package/dist/assets/{SetupPagesScreen-DD6RFr92.js → SetupPagesScreen-BmSvJAdQ.js} +5 -5
  47. package/dist/assets/SignInScreen-BGkNc7IE.js +1 -0
  48. package/dist/assets/{SignOutScreen-DkZxckI9.js → SignOutScreen-B93wbxy6.js} +1 -1
  49. package/dist/assets/{TaskListScreen-DguGk7Gq.js → TaskListScreen-cdgkarHh.js} +1 -1
  50. package/dist/assets/TaskRoutes-HLl20yd9.js +9 -0
  51. package/dist/assets/{TransactionDetailRoutes-CATLIK7c.js → TransactionDetailRoutes-kgWQaR9h.js} +1 -1
  52. package/dist/assets/{TransactionDetailScreen-CVxYtuTZ.js → TransactionDetailScreen-DtJ6rMlR.js} +2 -2
  53. package/dist/assets/{TransactionListRoutes-6jE_ufUt.js → TransactionListRoutes-DhZldMUL.js} +1 -1
  54. package/dist/assets/{TreasuryRoutes-DSLhZdKN.js → TreasuryRoutes-D0BRJ3ZW.js} +5 -5
  55. package/dist/assets/{VendorsRoutes-CvIYMadh.js → VendorsRoutes-BwTH4o1S.js} +1 -1
  56. package/dist/assets/{WiseConfirmationScreen-drIKSRjj.js → WiseConfirmationScreen-Dhlh7Lh_.js} +1 -1
  57. package/dist/assets/{ZeniAccountRoutes-L-z-yZX3.js → ZeniAccountRoutes-BL-bcu2k.js} +9 -9
  58. package/dist/assets/{ZeniAccountStatementScreen-BewnCgtV.js → ZeniAccountStatementScreen-BEz6NmsH.js} +1 -1
  59. package/dist/assets/{accountMappingHelper-CXKMWjqE.js → accountMappingHelper-D4hWQbUP.js} +1 -1
  60. package/dist/assets/{analytics-CT9_7buT.js → analytics-womxmO1W.js} +1 -1
  61. package/dist/assets/{analyticsHelper-CqZ_kCDb.js → analyticsHelper-CxSqx_Vn.js} +1 -1
  62. package/dist/assets/{core-oLPZqW1J.js → core-Du7UPqMS.js} +1 -1
  63. package/dist/assets/{decodeURIComponentSafe-6wXj8PHD.js → decodeURIComponentSafe-DbtFOMtW.js} +1 -1
  64. package/dist/assets/{dnd-BPV24-LJ.js → dnd-S6NFwVgt.js} +1 -1
  65. package/dist/assets/{empty-BcSiHcXL.js → empty-C-V7VSx7.js} +1 -1
  66. package/dist/assets/{empty-DN47JZY_.js → empty-ZFv_rQaI.js} +1 -1
  67. package/dist/assets/{emptyVideoElement-w75hgfQh.js → emptyVideoElement-ivFUaI5J.js} +1 -1
  68. package/dist/assets/{epic-BLxAn3gl.js → epic-DY0-L_k8.js} +2 -2
  69. package/dist/assets/{expenseAutomationHelper-6besgfMx.js → expenseAutomationHelper-hfq5qiQV.js} +1 -1
  70. package/dist/assets/{getLocaleForTenant-evpqVMoH.js → getLocaleForTenant-BUJ8EMP9.js} +1 -1
  71. package/dist/assets/{index-DXmrlDJg.js → index-Bkw6b9BJ.js} +15753 -15646
  72. package/dist/assets/{index-BwQSO1Gf.js → index-C--EEhaU.js} +1 -1
  73. package/dist/assets/{index-CPs6r8EN.js → index-CBC3SEYW.js} +2 -2
  74. package/dist/assets/{index-DvAdcXzG.js → index-CDjcugHk.js} +1 -1
  75. package/dist/assets/{index-Cvol4Z8K.js → index-CTgW5pl7.js} +1 -1
  76. package/dist/assets/{index-BW6TTdRv.js → index-ChFrwqPf.js} +1 -1
  77. package/dist/assets/{index-BZHjS3DF.js → index-DNXWHydt.js} +1 -1
  78. package/dist/assets/{index-B6RGXHdB.js → index-Dr8FwNck.js} +1 -1
  79. package/dist/assets/{lexical-TaM4g62q.js → lexical-Brc0Kroj.js} +1 -1
  80. package/dist/assets/{liveblocks-VaiuWGni.js → liveblocks-CtP3KKBx.js} +1 -1
  81. package/dist/assets/{lottie-CwZSkzHt.js → lottie-C1ice4dY.js} +1 -1
  82. package/dist/assets/{mui-1Y-6fO7a.js → mui-DWdv7IPr.js} +1 -1
  83. package/dist/assets/{pathToGoBack-C46IKitI.js → pathToGoBack-CIs954KZ.js} +1 -1
  84. package/dist/assets/{pdf-Ct5fILY1.js → pdf-CyjPx40H.js} +4 -4
  85. package/dist/assets/{pdf-lib-BEKORWvl.js → pdf-lib-hzctzu5c.js} +1 -1
  86. package/dist/assets/{plaid-BVr4napu.js → plaid-D1Y_x9zk.js} +1 -1
  87. package/dist/assets/{pusher-toV6mdy-.js → pusher-Bf-Kyp-u.js} +1 -1
  88. package/dist/assets/{react-D35AUcwW.js → react-4lBsc_Sj.js} +1 -1
  89. package/dist/assets/{react-C4JTLwbG.js → react-B3PIOfhA.js} +1 -1
  90. package/dist/assets/{react-BZRFhDBF.js → react-C4_N_gR3.js} +1 -1
  91. package/dist/assets/{react-DvdXAf0r.js → react-ClXtsDGs.js} +1 -1
  92. package/dist/assets/{react-DYqOL3_D.js → react-Cuc0l7Y2.js} +1 -1
  93. package/dist/assets/{react-Dl1gPnaI.js → react-DaIPoN40.js} +1 -1
  94. package/dist/assets/{recharts-CkVt8ler.js → recharts-BZz4-Irz.js} +1 -1
  95. package/dist/assets/{reportTimeframe-HxUbMI8P.js → reportTimeframe-CV2nBGFr.js} +1 -1
  96. package/dist/assets/{routePaths-CxYiw-4T.js → routePaths-BNm3GfSn.js} +1 -1
  97. package/dist/assets/{sentry-DzjqovIb.js → sentry-D1S3f4Dm.js} +1 -1
  98. package/dist/assets/{stripSplatSuffix-G5PPYFug.js → stripSplatSuffix-RB0FcK3v.js} +1 -1
  99. package/dist/assets/{url-DMQB7EoP.js → url-BNZk3DcK.js} +1 -1
  100. package/dist/assets/{url-_lYpxB0p.js → url-CgMPlwHc.js} +1 -1
  101. package/dist/assets/{useActualMatchingMatchDetail-D3muF-a1.js → useActualMatchingMatchDetail-BJV9Abbq.js} +1 -1
  102. package/dist/assets/{useAiCfoDashboardSuggestedQuestionsChips-BdqTAv-X.js → useAiCfoDashboardSuggestedQuestionsChips-CIT2ORI9.js} +1 -1
  103. package/dist/assets/useAskAiCfoHostNavButtonProps-CzbzINoa.js +1 -0
  104. package/dist/assets/{useChargeCardPusherEvents-BnOjhMlI.js → useChargeCardPusherEvents-BkB2IQnj.js} +1 -1
  105. package/dist/assets/{useDeviceId-nigD_iox.js → useDeviceId-C-8rsdcg.js} +1 -1
  106. package/dist/assets/{useEmailConnectResultRefresh-B2p-wLMz.js → useEmailConnectResultRefresh-Dyrsm0Ed.js} +1 -1
  107. package/dist/assets/{useEnsureVendorListLoaded-C6MBRle6.js → useEnsureVendorListLoaded-CFVw0qeE.js} +1 -1
  108. package/dist/assets/{useInitialThreadRequest-WCCdj0AZ.js → useInitialThreadRequest-CjVnEZkt.js} +1 -1
  109. package/dist/assets/useTaskManagerAccess-CLdmxrLC.js +1 -0
  110. package/dist/assets/{useTaskManagerPusherEvents-qDHkXsem.js → useTaskManagerPusherEvents-DyJvPV12.js} +1 -1
  111. package/dist/assets/{utils-D23hmDQp.js → utils-DWeOhfkQ.js} +1 -1
  112. package/dist/assets/{withTransactionSidePanel-DraP-Uf9.js → withTransactionSidePanel-ChnX-EmP.js} +4 -4
  113. package/dist/assets/{zeni-epic-state-DADihDI9.js → zeni-epic-state-SU_Ch21f.js} +3 -3
  114. package/dist/index.html +1 -1
  115. package/package.json +3 -3
  116. package/dist/assets/AddressRoutes-57-vkThK.js +0 -1
  117. package/dist/assets/CompanyPassportScreen-DnG_8q0s.js +0 -1
  118. package/dist/assets/ConnectionAuthScreen-DFbNzUuE.js +0 -11
  119. package/dist/assets/CustomerOnboardingAuthScreen-CY2j8mtq.js +0 -1
  120. package/dist/assets/EntityDetailRoutes-BtHgNhJ8.js +0 -1
  121. package/dist/assets/ExpenseAutomationRoutes-CX4Va03K.js +0 -38
  122. package/dist/assets/FeaturePreviewScreen-aGuUW4V9.js +0 -1
  123. package/dist/assets/MobileAppDrawer-C1KwOL1M.js +0 -1
  124. package/dist/assets/NotFoundScreen-DmU7PDer.js +0 -1
  125. package/dist/assets/RewardsRoutes-1gk6zyei.js +0 -1
  126. package/dist/assets/ScreenRoutes-CK2Otl4P.js +0 -2
  127. package/dist/assets/SignInScreen-SExJ5FqL.js +0 -1
  128. package/dist/assets/TaskRoutes-CvW79egt.js +0 -9
  129. package/dist/assets/useAskAiCfoHostNavButtonProps-CvyWGbPs.js +0 -1
  130. package/dist/assets/useTaskManagerAccess-B6ERMew5.js +0 -1
@@ -1,4 +1,4 @@
1
- import{j as e}from"./liveblocks-VaiuWGni.js";import{h as L,g as P,u as U,i as M,j as y,N as D,l as V,n as xe,o as k}from"./core-oLPZqW1J.js";import{cx as _,fI as E,_9 as F,P0 as ae,OJ as Z,OK as ne,_b as Ie,P3 as Te,_7 as we,_8 as se,_n as Ce,N4 as ke,CA as je,_d as Ae,Pa as be,_a as oe,df as q,Hb as re,e0 as ve,e1 as Ee,a0y as De,a0z as Le,OL as Pe,a0A as Ue,OM as Fe,OV as Be,bq as Re,bL as Oe,cI as Me,bM as Ve,cw as _e,bu as Ne,U$ as ze,cv as $e}from"./zeni-epic-state-DADihDI9.js";import{V as N,j as Ge,z as v,a6 as z,k as A,d7 as Ze,d8 as qe,d9 as G,$ as H,ao as He,aq as Ke,c as ie,F as O,a9 as We,a5 as Je,da as Qe,ac as K,p as Xe,db as Ye,a2 as W,dc as et,ag as tt,Z as X,dd as at,h as nt}from"./index-DXmrlDJg.js";import{u as st,D as ot,n as R,S as rt}from"./mui-1Y-6fO7a.js";import it from"./NotFoundScreen-DmU7PDer.js";import{S as Y}from"./SetupPagesScreen-DD6RFr92.js";import{a as p}from"./sentry-DzjqovIb.js";import{u as ct}from"./useAskAiCfoHostNavButtonProps-CvyWGbPs.js";import{u as lt}from"./useInitialThreadRequest-WCCdj0AZ.js";import{M as ce}from"./MobileAppDrawer-C1KwOL1M.js";import{F as ut}from"./FeaturePreviewScreen-aGuUW4V9.js";import{a as ee}from"./analyticsHelper-CqZ_kCDb.js";import"./recharts-CkVt8ler.js";import"./analytics-CT9_7buT.js";import"./plaid-BVr4napu.js";import"./dnd-BPV24-LJ.js";import"./stripe-cKAAJElX.js";import"./lottie-CwZSkzHt.js";import"./lexical-TaM4g62q.js";import"./pdf-Ct5fILY1.js";import"./utils-D23hmDQp.js";import"./BusinessVerificationPageScreen-CHnv9h-G.js";import"./routePaths-CxYiw-4T.js";import"./InboxNotificationsProvider-DdFv467m.js";import"./useTaskManagerAccess-B6ERMew5.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]="37b6731e-e352-4430-ab63-8e80442cc38c",t._sentryDebugIdIdentifier="sentry-dbid-37b6731e-e352-4430-ab63-8e80442cc38c")}catch{}})();const dt=V((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))}}}))(Ze);function pt(){const t=L(),a=P(),n=U(),{tenantEmailDomain:r}=M(),i=N(),o=y((w=>w.treasurySetupViewState.portfolioAllocationUpdateStatus?.fetchState)),m=Ge(o),s=_(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(Z()))}),[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(z,{analytics:A,onLoad:()=>{}}),e.jsx(dt,{navigate:t,location:a,companyId:f,isEditMode:!0,isLoading:B,isReadOnly:!s,treasurySetupView:h,analytics:A})]})}const mt=V((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:()=>{G(a.analytics,"cancel",o,m,"Transfer"),t(se()),n("../")},onTransferClick:()=>{G(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"))}}}))(qe),ft=({isFirstTransfer:t,isTransactionsLoaded:a})=>{const n=L(),{tenantEmailDomain:r}=M(),i=U(),[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(Z()))}),[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(z,{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:()=>{G(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-CtP3KKBx.js";import{h as L,g as P,u as U,i as M,j as y,N as D,l as V,n as xe,o as k}from"./core-Du7UPqMS.js";import{cx as _,fI as E,_9 as F,P0 as ae,OJ as q,OK as ne,_b as Ie,P3 as Te,_7 as we,_8 as se,_n as Ce,N4 as ke,CA as je,_d as Ae,Pa as be,_a as oe,df as Z,Hb as re,e0 as ve,e1 as Ee,a0y as De,a0z as Le,OL as Pe,a0A as Ue,OM as Fe,OV as Be,bq as Re,bL as Oe,cI as Me,bM as Ve,cw as _e,bu as Ne,U$ as ze,cv as $e}from"./zeni-epic-state-SU_Ch21f.js";import{J as N,h as Ge,z as v,a6 as z,j as A,d7 as qe,d8 as Ze,d9 as G,$ as H,ao as He,aq as Ke,p as ie,c as O,a9 as We,a5 as Je,da as Ye,ac as K,k as Qe,db as Xe,a2 as W,dc as et,ag as tt,Y as Q,dd as at,g as nt}from"./index-Bkw6b9BJ.js";import{u as st,D as ot,n as R,S as rt}from"./mui-DWdv7IPr.js";import it from"./NotFoundScreen-hkzdCFF0.js";import{S as X}from"./SetupPagesScreen-BmSvJAdQ.js";import{a as p}from"./sentry-D1S3f4Dm.js";import{u as ct}from"./useAskAiCfoHostNavButtonProps-CzbzINoa.js";import{u as lt}from"./useInitialThreadRequest-CjVnEZkt.js";import{M as ce}from"./MobileAppDrawer-bVKqFYWU.js";import{F as ut}from"./FeaturePreviewScreen-DC7afd7c.js";import{a as ee}from"./analyticsHelper-CxSqx_Vn.js";import"./recharts-BZz4-Irz.js";import"./analytics-womxmO1W.js";import"./plaid-D1Y_x9zk.js";import"./dnd-S6NFwVgt.js";import"./stripe-cKAAJElX.js";import"./lottie-C1ice4dY.js";import"./lexical-Brc0Kroj.js";import"./pdf-CyjPx40H.js";import"./utils-DWeOhfkQ.js";import"./BusinessVerificationPageScreen-BMf-N2Vi.js";import"./routePaths-BNm3GfSn.js";import"./InboxNotificationsProvider-CzmfZzrH.js";import"./useTaskManagerAccess-CLdmxrLC.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]="567c711f-2579-488a-8d80-313d72ba595b",t._sentryDebugIdIdentifier="sentry-dbid-567c711f-2579-488a-8d80-313d72ba595b")}catch{}})();const dt=V((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))}}}))(qe);function pt(){const t=L(),a=P(),n=U(),{tenantEmailDomain:r}=M(),i=N(),o=y((w=>w.treasurySetupViewState.portfolioAllocationUpdateStatus?.fetchState)),m=Ge(o),s=_(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(q()))}),[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(z,{analytics:A,onLoad:()=>{}}),e.jsx(dt,{navigate:t,location:a,companyId:f,isEditMode:!0,isLoading:B,isReadOnly:!s,treasurySetupView:h,analytics:A})]})}const mt=V((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:()=>{G(a.analytics,"cancel",o,m,"Transfer"),t(se()),n("../")},onTransferClick:()=>{G(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"))}}}))(Ze),ft=({isFirstTransfer:t,isTransactionsLoaded:a})=>{const n=L(),{tenantEmailDomain:r}=M(),i=U(),[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(q()))}),[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(z,{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:()=>{G(A,"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-VaiuWGni.js";import{h as L,g as P,u as U,i as M,
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=V((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=Xe(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")}}}))(Qe);function $({isTransferDrawerOpen:t,isEditPortfolioDrawerOpen:a}){const n=P(),r=L(),i=U(),o=H(),m=st(),s=y((b=>E(b))),{tenantEmailDomain:d}=M(),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=N(),g=!!s.companyTreasuryInfo?.info?.isTreasuryTOSAccepted,j=_(h?.loggedInUserRoleMap),T=q(h?.loggedInUserRoleMap),{areTenantIdsInSync:B}=He();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:Q}=ie(),{isFeatureEnabled:me}=Q(O.isDebitCardFeatureEnabled),{isFeatureEnabled:fe}=Q(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(z,{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=V((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")}}}))(Ye);function $({isTransferDrawerOpen:t,isEditPortfolioDrawerOpen:a}){const n=P(),r=L(),i=U(),o=H(),m=st(),s=y((b=>E(b))),{tenantEmailDomain:d}=M(),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=N(),g=!!s.companyTreasuryInfo?.info?.isTreasuryTOSAccepted,j=_(h?.loggedInUserRoleMap),T=Z(h?.loggedInUserRoleMap),{areTenantIdsInSync:B}=He();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:Y}=ie(),{isFeatureEnabled:me}=Y(O.isDebitCardFeatureEnabled),{isFeatureEnabled:fe}=Y(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(z,{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)`
10
10
  display: flex;
11
11
  min-height: 100%;
12
12
  flex-direction: column;
@@ -18,7 +18,7 @@ import{j as e}from"./liveblocks-VaiuWGni.js";import{h as L,g as P,u as U,i as M,
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=U(),n=H(),r=P(),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(Pe(!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`
21
+ `;function kt(){const t=L(),a=U(),n=H(),r=P(),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(Pe(!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(Xe,{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-VaiuWGni.js";import{h as L,g as P,u as U,i as M,
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=H(),n=P(),r=U(),i=`${K.bankingMicroServiceBaseUrl}/1.0/treasury-account`,[o,m]=p.useState(!1),s=y((u=>Ue(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=V((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=P(),r=U(),{tenantEmailDomain:i}=M(),[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(Z()))}),[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=N(),C=_(f?.loggedInUserRoleMap),h=q(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(X,{size:"ExtraLarge",start:!0})}):e.jsxs(e.Fragment,{children:[e.jsx(z,{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(X,{size:"ExtraLarge",start:!0})})},te=R.div`
29
+ `;function At(){const t=L(),a=H(),n=P(),r=U(),i=`${K.bankingMicroServiceBaseUrl}/1.0/treasury-account`,[o,m]=p.useState(!1),s=y((u=>Ue(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=V((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=P(),r=U(),{tenantEmailDomain:i}=M(),[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(q()))}),[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=N(),C=_(f?.loggedInUserRoleMap),h=Z(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(z,{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(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-VaiuWGni.js";import{h as L,g as P,u as U,i as M,
34
34
  justify-content: center;
35
35
  align-items: center;
36
36
  background-color: ${t=>t.theme.colors.grey5};
37
- `;function ta(){const t=P(),a=y((g=>E(g))),{useFeatureGate:n}=ie(),r=a.companyTreasuryInfo?.info?.businessVerificationStatus?.code==="verified",i=!!a.company?.companyTreasuryInfo?.isTreasuryTOSAccepted,o=N(),m=q(o?.loggedInUserRoleMap),s=a?.userRole!=null&&Re(a?.userRole),d=(a?.company==null||a.company.featuresActivationInfo?.isBillPayFeatureEnabled&&!s)&&Oe(o?.loggedInUserRoleMap),c=Me(o?.loggedInUserRoleMap),S=(a?.company==null||a.company.featuresActivationInfo?.isReimbursementFeatureEnabled&&!s)&&Ve(o?.loggedInUserRoleMap),I=!!a.company?.companyZeniAccountInfo?.isZeniAccountEnabled&&!s&&_e(o?.loggedInUserRoleMap),l=r&&!s&&_(o?.loggedInUserRoleMap),{isFeatureEnabled:u}=n(O.isChargeCardFeatureEnabled),{isFeatureEnabled:x}=n(O.isDebitCardFeatureEnabled),f=nt(a,u,x)&&!s&&Ne(o?.loggedInUserRoleMap),C=ze(o?.loggedInUserRoleMap),h=$e(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(At,{})}),r?e.jsxs(e.Fragment,{children:[e.jsx(k,{path:"/",element:e.jsx($,{isTransferDrawerOpen:!1,isEditPortfolioDrawerOpen:!1})}),l?e.jsxs(e.Fragment,{children:[e.jsx(k,{path:"edit-portfolio",element:e.jsx($,{isEditPortfolioDrawerOpen:!0,isTransferDrawerOpen:!1})}),e.jsx(k,{path:"transfer",element:e.jsx($,{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=P(),a=y((g=>E(g))),{useFeatureGate:n}=ie(),r=a.companyTreasuryInfo?.info?.businessVerificationStatus?.code==="verified",i=!!a.company?.companyTreasuryInfo?.isTreasuryTOSAccepted,o=N(),m=Z(o?.loggedInUserRoleMap),s=a?.userRole!=null&&Re(a?.userRole),d=(a?.company==null||a.company.featuresActivationInfo?.isBillPayFeatureEnabled&&!s)&&Oe(o?.loggedInUserRoleMap),c=Me(o?.loggedInUserRoleMap),S=(a?.company==null||a.company.featuresActivationInfo?.isReimbursementFeatureEnabled&&!s)&&Ve(o?.loggedInUserRoleMap),I=!!a.company?.companyZeniAccountInfo?.isZeniAccountEnabled&&!s&&_e(o?.loggedInUserRoleMap),l=r&&!s&&_(o?.loggedInUserRoleMap),{isFeatureEnabled:u}=n(O.isChargeCardFeatureEnabled),{isFeatureEnabled:x}=n(O.isDebitCardFeatureEnabled),f=nt(a,u,x)&&!s&&Ne(o?.loggedInUserRoleMap),C=ze(o?.loggedInUserRoleMap),h=$e(o?.loggedInUserRoleMap);return e.jsxs(xe,{children:[h?null:e.jsx(k,{path:"setup",element:e.jsx(X,{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(X,{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($,{isTransferDrawerOpen:!1,isEditPortfolioDrawerOpen:!1})}),l?e.jsxs(e.Fragment,{children:[e.jsx(k,{path:"edit-portfolio",element:e.jsx($,{isEditPortfolioDrawerOpen:!0,isTransferDrawerOpen:!1})}),e.jsx(k,{path:"transfer",element:e.jsx($,{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-VaiuWGni.js";import{a as u}from"./sentry-DzjqovIb.js";import{h as G,u as $,i as X,j as f,l as N,g as K,n as Me,o as P,N as U}from"./core-oLPZqW1J.js";import{Wv as gt,Ww as Ze,Sg as et,Wx as vt,fI as L,h2 as ge,Wy as Tt,cG as xt,Wz as bt,G8 as yt,WA as wt,WB as oe,WC as te,WD as ve,TS as ue,TT as ke,Go as pe,TR as he,Gb as tt,FK as Pe,WE as It,TU as z,m3 as me,WF as je,FE as Ct,WG as Dt,WH as Et,WI as _e,WJ as Ve,WK as Ae,WL as Re,Gi as Te,WM as nt,F$ as at,WN as Ft,WO as kt,WP as Pt,WQ as jt,WR as _t,WS as Vt,WT as At,WU as Rt,CM as Lt,CU as Ut,CN as Bt,SY as we,WV as Ot,WW as Mt,lj as Ie,br as Gt,WX as Nt,WY as $t,n1 as Wt,na as Xt,SX as Ce,bG as Ge,WZ as ot,Sy as st,W_ as zt,W$ as Yt,X0 as Jt,nc as Kt,X1 as Ne,X2 as $e,X3 as We,X4 as Xe,X5 as qt,n8 as Ht,X6 as Qt,nb as Zt,X7 as en,X8 as it,Ti as rt,mr as tn,X9 as nn,Xa as De,Xb as dt,Tg as lt,IS as an,Xc as on,Xd as sn,mL as ct,Xe as rn,Xf as dn,Tu as ln,vn as cn,Xg as ut,Xh as ze,Tr as Ee,Xi as Ye,Xj as un,Tw as pn,Xk as hn,Xl as mn,Xm as fn,Xn as Sn,Xo as gn,vq as vn,Xp as Tn,TV as xn,Vt as bn,T9 as Fe,ie as yn,Vv as wn,Vu as In,ic as Cn,Xq as Dn,Xr as En,IX as Fn,Xs as kn,Xt as Pn,Xu as jn,Xv as _n,mv as Vn,bn as An,e1 as Rn,e0 as Ln}from"./zeni-epic-state-DADihDI9.js";import{$ as ne,a9 as Le,c as q,F as M,z as R,a5 as Un,aK as Bn,k as j,X as Ue,U as xe,at as ee,aq as se,aL as On,aM as pt,ao as Mn,a6 as Se,aN as Gn,p as J,V as Nn,G as ht,aO as $n,ac as mt,a2 as Wn,j as Je,aP as Xn,J as Y,a7 as zn,ad as ft,ae as Yn,aQ as Jn,aR as Kn,R as Be,aS as qn,aT as Hn,a1 as Qn,aU as Zn,aV as ea}from"./index-DXmrlDJg.js";import{u as ta,D as na,n as B,S as St}from"./mui-1Y-6fO7a.js";import{t as aa,A as oa}from"./AddressScreen-DV_seWrj.js";import fe from"./NotFoundScreen-DmU7PDer.js";import{F as sa}from"./FeaturePreviewScreen-aGuUW4V9.js";import{S as ia,a as ra,J as da,b as la,c as ca}from"./ScheduleDetailsPrepaidExpensesScreen-DsoZ7iR9.js";import{u as ie}from"./useAskAiCfoHostNavButtonProps-CvyWGbPs.js";import{M as re}from"./MobileAppDrawer-C1KwOL1M.js";import{v as Oe,c as ua,d as pa}from"./routePaths-CxYiw-4T.js";import{D as ha}from"./DrawerScreen-7VKOEAfQ.js";import{a as ma,m as fa}from"./accountMappingHelper-CXKMWjqE.js";import"./recharts-CkVt8ler.js";import"./analytics-CT9_7buT.js";import"./plaid-BVr4napu.js";import"./dnd-BPV24-LJ.js";import"./stripe-cKAAJElX.js";import"./lottie-CwZSkzHt.js";import"./lexical-TaM4g62q.js";import"./pdf-Ct5fILY1.js";import"./utils-D23hmDQp.js";import"./pathToGoBack-C46IKitI.js";import"./InboxNotificationsProvider-DdFv467m.js";import"./useTaskManagerAccess-B6ERMew5.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]="98853003-1695-4585-8692-a40a7291a54f",e._sentryDebugIdIdentifier="sentry-dbid-98853003-1695-4585-8692-a40a7291a54f")}catch{}})();const Sa={drawerLeftMargin:new Le(0,0,100,200)},ga=N((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=G(),s=$(),{scheduleDetailId:t}=X(),n=ne(),i=Sa.drawerLeftMargin.valuePx(n),{scheduleType:l}=X(),{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-CtP3KKBx.js";import{a as u}from"./sentry-D1S3f4Dm.js";import{h as G,u as $,i as X,j as f,l as N,g as K,n as Me,o as P,N as U}from"./core-Du7UPqMS.js";import{Wv as gt,Ww as Ze,Sg as et,Wx as vt,fI as L,h2 as ge,Wy as Tt,cG as xt,Wz as bt,G8 as yt,WA as wt,WB as oe,WC as te,WD as ve,TS as ue,TT as ke,Go as pe,TR as he,Gb as tt,FK as Pe,WE as It,TU as z,m3 as me,WF as je,FE as Ct,WG as Dt,WH as Et,WI as _e,WJ as Ve,WK as Ae,WL as Re,Gi as Te,WM as nt,F$ as at,WN as Ft,WO as kt,WP as Pt,WQ as jt,WR as _t,WS as Vt,WT as At,WU as Rt,CM as Lt,CU as Ut,CN as Bt,SY as we,WV as Ot,WW as Mt,lj as Ie,br as Gt,WX as Nt,WY as $t,n1 as Wt,na as Xt,SX as Ce,bG as Ge,WZ as ot,Sy as st,W_ as zt,W$ as Yt,X0 as Jt,nc as Kt,X1 as Ne,X2 as $e,X3 as We,X4 as Xe,X5 as qt,n8 as Ht,X6 as Qt,nb as Zt,X7 as en,X8 as it,Ti as rt,mr as tn,X9 as nn,Xa as De,Xb as dt,Tg as lt,IS as an,Xc as on,Xd as sn,mL as ct,Xe as rn,Xf as dn,Tu as ln,vn as cn,Xg as ut,Xh as ze,Tr as Ee,Xi as Ye,Xj as un,Tw as pn,Xk as hn,Xl as mn,Xm as fn,Xn as Sn,Xo as gn,vq as vn,Xp as Tn,TV as xn,Vt as bn,T9 as Fe,ie as yn,Vv as wn,Vu as In,ic as Cn,Xq as Dn,Xr as En,IX as Fn,Xs as kn,Xt as Pn,Xu as jn,Xv as _n,mv as Vn,bn as An,e1 as Rn,e0 as Ln}from"./zeni-epic-state-SU_Ch21f.js";import{$ as ne,a9 as Le,p as q,c as M,z as R,a5 as Un,aK as Bn,j,W as Ue,l as xe,at as ee,aq as se,aL as On,aM as pt,ao as Mn,a6 as Se,aN as Gn,k as J,J as Nn,G as ht,aO as $n,ac as mt,a2 as Wn,h as Je,aP as Xn,E as Y,a7 as zn,ad as ft,ae as Yn,aQ as Jn,aR as Kn,R as Be,aS as qn,aT as Hn,a1 as Qn,aU as Zn,aV as ea}from"./index-Bkw6b9BJ.js";import{u as ta,D as na,n as B,S as St}from"./mui-DWdv7IPr.js";import{t as aa,A as oa}from"./AddressScreen-B0Rw7Meo.js";import fe from"./NotFoundScreen-hkzdCFF0.js";import{F as sa}from"./FeaturePreviewScreen-DC7afd7c.js";import{S as ia,a as ra,J as da,b as la,c as ca}from"./ScheduleDetailsPrepaidExpensesScreen-fz7l0JQi.js";import{u as ie}from"./useAskAiCfoHostNavButtonProps-CzbzINoa.js";import{M as re}from"./MobileAppDrawer-bVKqFYWU.js";import{v as Oe,c as ua,d as pa}from"./routePaths-BNm3GfSn.js";import{D as ha}from"./DrawerScreen-rHSg_gue.js";import{a as ma,m as fa}from"./accountMappingHelper-D4hWQbUP.js";import"./recharts-BZz4-Irz.js";import"./analytics-womxmO1W.js";import"./plaid-D1Y_x9zk.js";import"./dnd-S6NFwVgt.js";import"./stripe-cKAAJElX.js";import"./lottie-C1ice4dY.js";import"./lexical-Brc0Kroj.js";import"./pdf-CyjPx40H.js";import"./utils-DWeOhfkQ.js";import"./pathToGoBack-CIs954KZ.js";import"./InboxNotificationsProvider-CzmfZzrH.js";import"./useTaskManagerAccess-CLdmxrLC.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]="38bb26f4-bc23-4d7f-b9c6-46879b998034",e._sentryDebugIdIdentifier="sentry-dbid-38bb26f4-bc23-4d7f-b9c6-46879b998034")}catch{}})();const Sa={drawerLeftMargin:new Le(0,0,100,200)},ga=N((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=G(),s=$(),{scheduleDetailId:t}=X(),n=ne(),i=Sa.drawerLeftMargin.valuePx(n),{scheduleType:l}=X(),{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-VaiuWGni.js";import{a as f}from"./sentry-DzjqovIb.js";import{t as u,u as h,j as y,N as I}from"./core-oLPZqW1J.js";import{Vh as w,gl as b,K4 as j}from"./zeni-epic-state-DADihDI9.js";import{z as l,a5 as x,ad as S,ae as D}from"./index-DXmrlDJg.js";import{n as g}from"./mui-1Y-6fO7a.js";import"./recharts-CkVt8ler.js";import"./analytics-CT9_7buT.js";import"./plaid-BVr4napu.js";import"./dnd-BPV24-LJ.js";import"./stripe-cKAAJElX.js";import"./lottie-CwZSkzHt.js";import"./lexical-TaM4g62q.js";import"./pdf-Ct5fILY1.js";import"./utils-D23hmDQp.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]="712154e0-8713-4560-84ad-5989284e4aff",e._sentryDebugIdIdentifier="sentry-dbid-712154e0-8713-4560-84ad-5989284e4aff")}catch{}})();const A=()=>{const[e]=u(),t=e.get("code")??"",s=e.get("state")??"",p=e.get("profileId")??"",[n,m]=f.useState(!1),a=h(),i=y((c=>w(c))),r=l.getSignedInUser(),d=l.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),f.useEffect((()=>{n||(m(!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-CtP3KKBx.js";import{a as f}from"./sentry-D1S3f4Dm.js";import{t as u,u as h,j as y,N as I}from"./core-Du7UPqMS.js";import{Vh as w,gl as b,K4 as j}from"./zeni-epic-state-SU_Ch21f.js";import{z as l,a5 as x,ad as S,ae as D}from"./index-Bkw6b9BJ.js";import{n as g}from"./mui-DWdv7IPr.js";import"./recharts-BZz4-Irz.js";import"./analytics-womxmO1W.js";import"./plaid-D1Y_x9zk.js";import"./dnd-S6NFwVgt.js";import"./stripe-cKAAJElX.js";import"./lottie-C1ice4dY.js";import"./lexical-Brc0Kroj.js";import"./pdf-CyjPx40H.js";import"./utils-DWeOhfkQ.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]="712154e0-8713-4560-84ad-5989284e4aff",e._sentryDebugIdIdentifier="sentry-dbid-712154e0-8713-4560-84ad-5989284e4aff")}catch{}})();const A=()=>{const[e]=u(),t=e.get("code")??"",s=e.get("state")??"",p=e.get("profileId")??"",[n,m]=f.useState(!1),a=h(),i=y((c=>w(c))),r=l.getSignedInUser(),d=l.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),f.useEffect((()=>{n||(m(!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-VaiuWGni.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-oLPZqW1J.js";import{a0d as Ue,LY as Fe,a0e as _e,fI as R,H9 as ze,a0f as wn,cw as ee,cx as Me,H3 as An,a0g as Dn,a0h as kn,H6 as In,Hd as me,H0 as Sn,GZ as Pn,ZM as ce,a0i as bn,Pw as jn,XB as vn,Py as En,mM as Pe,a0j as Tn,v2 as Ve,uS as $e,mD as He,mG as be,XC as je,XD as Bn,a0k as On,mF as Ln,n0 as Rn,mu as Un,kU as Fn,kT as _n,a0l as zn,a0m as ge,Pd as Mn,a0n as Vn,a0o as $n,_0 as he,a0p as ve,a0q as Hn,PJ as Zn,_n as Nn,N4 as Ze,CA as Ne,a0r as Gn,PG as Wn,a0s as Ge,dc as ye,PN as We,e0 as qe,e1 as xe,PL as qn,M_ as Yn,PD as Xn,a0t as Ye,a0u as Xe,Pf as Je,Pp as Ee,a0v as Jn,_e as Kn,PO as Qn,bq as ea,bL as na,cI as aa,bM as ta,bu as oa,U$ as sa}from"./zeni-epic-state-DADihDI9.js";import{V as te,c as H,F as $,z as b,at as Ce,a5 as le,cY as ra,$ as M,a9 as q,a2 as Ke,j as ia,q as Te,k as L,cZ as ca,ac as we,c_ as la,a6 as de,c$ as da,R as Ae,bj as N,d0 as ua,ao as pa,aq as Qe,d1 as Be,d2 as ma,p as ie,d3 as ga,ag as fa,d4 as ha,d5 as ya,h as xa,J as Ca}from"./index-DXmrlDJg.js";import{u as U,n as F,D as Y,S as X}from"./mui-1Y-6fO7a.js";import K from"./NotFoundScreen-DmU7PDer.js";import{S as Oe}from"./SetupPagesScreen-DD6RFr92.js";import{F as en}from"./FeaturePreviewScreen-aGuUW4V9.js";import{a as g}from"./sentry-DzjqovIb.js";import{M as ue}from"./MobileAppDrawer-C1KwOL1M.js";import{A as wa,D as Aa,V as Da}from"./DomesticWireDetailScreen-DGJN9xE3.js";import{A as ka}from"./AddressScreen-DV_seWrj.js";import{u as nn}from"./useAskAiCfoHostNavButtonProps-CvyWGbPs.js";import{Z as Ia}from"./ZeniAccountStatementScreen-BewnCgtV.js";import"./recharts-CkVt8ler.js";import"./analytics-CT9_7buT.js";import"./plaid-BVr4napu.js";import"./dnd-BPV24-LJ.js";import"./stripe-cKAAJElX.js";import"./lottie-CwZSkzHt.js";import"./lexical-TaM4g62q.js";import"./pdf-Ct5fILY1.js";import"./utils-D23hmDQp.js";import"./BusinessVerificationPageScreen-CHnv9h-G.js";import"./routePaths-CxYiw-4T.js";import"./analyticsHelper-CqZ_kCDb.js";import"./InboxNotificationsProvider-DdFv467m.js";import"./useTaskManagerAccess-B6ERMew5.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]="0a6a18ec-15d6-44b5-b114-c8172ccfa04f",n._sentryDebugIdIdentifier="sentry-dbid-0a6a18ec-15d6-44b5-b114-c8172ccfa04f")}catch{}})();const Sa=F.div`
1
+ import{j as e}from"./liveblocks-CtP3KKBx.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-Du7UPqMS.js";import{a0d as Ue,LY as Fe,a0e as _e,fI as R,H9 as ze,a0f as wn,cw as ee,cx as Me,H3 as An,a0g as Dn,a0h as kn,H6 as In,Hd as me,H0 as Sn,GZ as Pn,ZM as ce,a0i as jn,Pw as vn,XB as bn,Py as En,mM as Pe,a0j as Tn,v2 as $e,uS as Ve,mD as He,mG as je,XC as ve,XD as Bn,a0k as On,mF as Ln,n0 as Rn,mu as Un,kU as Fn,kT as _n,a0l as zn,a0m as ge,Pd as Mn,a0n as $n,a0o as Vn,_0 as he,a0p as be,a0q as Hn,PJ as Zn,_n as Nn,N4 as Ze,CA as Ne,a0r as Gn,PG as Wn,a0s as Ge,dc as ye,PN as We,e0 as qe,e1 as xe,PL as qn,M_ as Yn,PD as Xn,a0t as Ye,a0u as Xe,Pf as Je,Pp as Ee,a0v as Jn,_e as Kn,PO as Qn,bq as ea,bL as na,cI as aa,bM as ta,bu as oa,U$ as sa}from"./zeni-epic-state-SU_Ch21f.js";import{J as te,p as H,c as V,z as j,at as Ce,a5 as le,cY as ra,$ as M,a9 as q,a2 as Ke,h as ia,q as Te,j as L,cZ as ca,ac as we,c_ as la,a6 as de,c$ as da,R as Ae,bj as N,d0 as ua,ao as pa,aq as Qe,d1 as Be,d2 as ma,k as ie,d3 as ga,ag as fa,d4 as ha,d5 as ya,g as xa,E as Ca}from"./index-Bkw6b9BJ.js";import{u as U,n as F,D as Y,S as X}from"./mui-DWdv7IPr.js";import K from"./NotFoundScreen-hkzdCFF0.js";import{S as Oe}from"./SetupPagesScreen-BmSvJAdQ.js";import{F as en}from"./FeaturePreviewScreen-DC7afd7c.js";import{a as g}from"./sentry-D1S3f4Dm.js";import{M as ue}from"./MobileAppDrawer-bVKqFYWU.js";import{A as wa,D as Aa,V as Da}from"./DomesticWireDetailScreen-CaGljNLv.js";import{A as ka}from"./AddressScreen-B0Rw7Meo.js";import{u as nn}from"./useAskAiCfoHostNavButtonProps-CzbzINoa.js";import{Z as Ia}from"./ZeniAccountStatementScreen-BEz6NmsH.js";import"./recharts-BZz4-Irz.js";import"./analytics-womxmO1W.js";import"./plaid-D1Y_x9zk.js";import"./dnd-S6NFwVgt.js";import"./stripe-cKAAJElX.js";import"./lottie-C1ice4dY.js";import"./lexical-Brc0Kroj.js";import"./pdf-CyjPx40H.js";import"./utils-DWeOhfkQ.js";import"./BusinessVerificationPageScreen-BMf-N2Vi.js";import"./routePaths-BNm3GfSn.js";import"./analyticsHelper-CxSqx_Vn.js";import"./InboxNotificationsProvider-CzmfZzrH.js";import"./useTaskManagerAccess-CLdmxrLC.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]="f4aeed59-6fd4-47a2-b7d3-77c06f806955",n._sentryDebugIdIdentifier="sentry-dbid-f4aeed59-6fd4-47a2-b7d3-77c06f806955")}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-VaiuWGni.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}=H(),m=k((u=>Ue(u))),P=k((u=>Fe(u.depositAccountState,u.depositAccountListState))),D=k((u=>_e(u))),A=k((u=>R(u))),{isFeatureEnabled:I}=h($.isTreasuryEnabled),C=m?.fetchState??"Not-Started",w=A?.companyId??(s==null?void 0:b.getSignedInUserTenant(s)?.companyId);g.useEffect((()=>{C==="Not-Started"&&w!=null&&c(ze(!0))}),[c,C,w]);const E=m?.fetchState!=="Completed";if(E)return{autoTransferRulePageProps:void 0,isLoading:E};const T=A?.company!=null&&wn(A.company),j=!!(I&&T),v=ee(l?.loggedInUserRoleMap)||Me(l?.loggedInUserRoleMap),O=b.getSignedInUser(),S={userId:O?.userId??"",sessionId:O?.zeniSessionId??"",tenantId:A?.tenantId??""},B=!!f.state?.scrollToAddRule;return{isLoading:E,autoTransferRulePageProps:{autoTransferRuleView:m,companyName:A?.companyName??"",hasAdminLevelAccess:v,includeTreasuryOption:j,transferLimit:5e5,authParams:S,currentTenant:A,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,V)=>{c(In(u,V))},onUpdateRuleLocalData:u=>{c(kn(u))},clearRuleLocalData:()=>{c(Dn())},onEditClick:u=>{p(`./${u}/edit`)},onEditDrawerClose:()=>{p("../../",{relative:"path"})},onReviewClick:()=>{c(An())}}}})({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 q(100,100,58)},ba=({vendorId:n,isDrawerOpen:a,closeDrawerHandler:r})=>{const t=z(),o=U(),i=M();if(b.getSignedInUser()==null)throw Error("Can't access ach account page without signing in...");return e.jsx(Y,{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(ja,{onClick:d=>d.stopPropagation(),children:e.jsx(wa,{vendorIdParam:n,accountContext:"express-pay"})})})},ja=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}=H(),m=k((u=>Ue(u))),P=k((u=>Fe(u.depositAccountState,u.depositAccountListState))),D=k((u=>_e(u))),A=k((u=>R(u))),{isFeatureEnabled:I}=h(V.isTreasuryEnabled),C=m?.fetchState??"Not-Started",w=A?.companyId??(s==null?void 0:j.getSignedInUserTenant(s)?.companyId);g.useEffect((()=>{C==="Not-Started"&&w!=null&&c(ze(!0))}),[c,C,w]);const E=m?.fetchState!=="Completed";if(E)return{autoTransferRulePageProps:void 0,isLoading:E};const T=A?.company!=null&&wn(A.company),v=!!(I&&T),b=ee(l?.loggedInUserRoleMap)||Me(l?.loggedInUserRoleMap),O=j.getSignedInUser(),S={userId:O?.userId??"",sessionId:O?.zeniSessionId??"",tenantId:A?.tenantId??""},B=!!f.state?.scrollToAddRule;return{isLoading:E,autoTransferRulePageProps:{autoTransferRuleView:m,companyName:A?.companyName??"",hasAdminLevelAccess:b,includeTreasuryOption:v,transferLimit:5e5,authParams:S,currentTenant:A,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,$)=>{c(In(u,$))},onUpdateRuleLocalData:u=>{c(kn(u))},clearRuleLocalData:()=>{c(Dn())},onEditClick:u=>{p(`./${u}/edit`)},onEditDrawerClose:()=>{p("../../",{relative:"path"})},onReviewClick:()=>{c(An())}}}})({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 q(100,100,58)},ja=({vendorId:n,isDrawerOpen:a,closeDrawerHandler:r})=>{const t=z(),o=U(),i=M();if(j.getSignedInUser()==null)throw Error("Can't access ach account page without signing in...");return e.jsx(Y,{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(wa,{vendorIdParam:n,accountContext:"express-pay"})})})},va=F(X)`
10
10
  display: flex;
11
11
  min-height: 100%;
12
12
  flex-direction: column;
13
- `,va={overlayWidth:new q(100,100,58)},Ea=({isDrawerOpen:n,closeDrawerHandler:a})=>{const r=z(),t=U(),o=M();if(b.getSignedInUser()==null)throw Error("Can't access address page without signing in...");return e.jsx(Y,{onClose:()=>{a(!0),r(ce())},anchor:"right",open:n,PaperProps:{style:{width:va.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
+ `,ba={overlayWidth:new q(100,100,58)},Ea=({isDrawerOpen:n,closeDrawerHandler:a})=>{const r=z(),t=U(),o=M();if(j.getSignedInUser()==null)throw Error("Can't access address page without signing in...");return e.jsx(Y,{onClose:()=>{a(!0),r(ce())},anchor:"right",open:n,PaperProps:{style:{width:ba.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 q(100,100,58)},Oa=({vendorId:n,isDrawerOpen:a,closeDrawerHandler:r})=>{const t=z(),o=U(),i=M();if(b.getSignedInUser()==null)throw Error("Can't access ach account page without signing in...");return e.jsx(Y,{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(Aa,{vendorIdParam:n,accountContext:"express-pay"})})})},La=F(X)`
17
+ `,Ba={overlayWidth:new q(100,100,58)},Oa=({vendorId:n,isDrawerOpen:a,closeDrawerHandler:r})=>{const t=z(),o=U(),i=M();if(j.getSignedInUser()==null)throw Error("Can't access ach account page without signing in...");return e.jsx(Y,{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(Aa,{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-VaiuWGni.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=vn(n,"common");return{expressPayDetails:d,fileProps:{authParams:i,filesEndPoint:`${we.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(je("common"))},onCancelAutoComplete:()=>{n(je("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(He({files:t}))},onDeleteFile:t=>{n($e(t))},onEditFileName:(t,o)=>{n(Ve(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),[A,I]=g.useState(!1),[C,w]=g.useState(!1),E=Ke(o.state?.pathnameStackToGoBack),{poppedPathname:T}=E,j=T?.split("/"),v=j?.[j.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?w(!0):(w(!1),document.body.style.overflow="auto")}),[r]),g.useEffect((()=>{y==="Not-Started"&&i(jn(!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,A===!0?e.jsx(Oa,{vendorId:h,closeDrawerHandler:B,isDrawerOpen:A}):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:v,analytics:L,currentTenant:s,vendorId:h,roleMap:f?.loggedInUserRoleMap,isSettings:Te(o),expressPayDetails:l,onClickMenuIcon:()=>{S(!0)}})]})}const Fa={overlayWidth:new q(100,100,58)},_a=({authParams:n,downloadAccountDetailEndPoint:a,isAccountInfoDrawerOpen:r,zeniBankAccountDetail:t,closeDrawerHandler:o})=>{const i=U(),d=M(),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(Y,{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=j.getSignedInUser(),o=r.tenantId,i={userId:t?.userId??"",sessionId:t?.zeniSessionId??"",tenantId:o??""},d=a.expressPayDetails,c=n.entityAutoCompleteState.autoCompleteText.common,p=bn(n,"common");return{expressPayDetails:d,fileProps:{authParams:i,filesEndPoint:`${we.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(je({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(je({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(He({files:t}))},onDeleteFile:t=>{n(Ve(t))},onEditFileName:(t,o)=>{n($e(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=>jn(u))),h=l.expressPayLocalData?.vendorId,m=s.companyId??j.getSignedInUserTenant(p)?.companyId,[P,D]=g.useState(!1),[A,I]=g.useState(!1),[C,w]=g.useState(!1),E=Ke(o.state?.pathnameStackToGoBack),{poppedPathname:T}=E,v=T?.split("/"),b=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?w(!0):(w(!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]),j.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(ja,{vendorId:h,closeDrawerHandler:B,isDrawerOpen:P}):null,A===!0?e.jsx(Oa,{vendorId:h,closeDrawerHandler:B,isDrawerOpen:A}):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:b,analytics:L,currentTenant:s,vendorId:h,roleMap:f?.loggedInUserRoleMap,isSettings:Te(o),expressPayDetails:l,onClickMenuIcon:()=>{S(!0)}})]})}const Fa={overlayWidth:new q(100,100,58)},_a=({authParams:n,downloadAccountDetailEndPoint:a,isAccountInfoDrawerOpen:r,zeniBankAccountDetail:t,closeDrawerHandler:o})=>{const i=U(),d=M(),c=k((s=>_e(s))),p=k((s=>R(s)));if(j.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(Y,{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
- `,Ma={overlayWidth:new q(100,100,58)},an=({isCheckDepositDrawerOpen:n,closeDrawerHandler:a})=>{const r=U(),t=M(),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:`${we.fileMicroServiceBaseUrl}`,authParams:p,onSaveChangesToLocalStore:s=>{o(Vn(s))},updateFilesEntity:s=>{o(He({files:s}))},onAnotherTransferClick:()=>{o(ge())},onDeleteFile:s=>{o($e(s))},onEditFileName:(s,l)=>{o(Ve(s,l.split(".")[0]))},onCheckDpositClick:()=>{o(Mn())},onDismissClick:()=>{a(!0),o(ge())}};return e.jsxs(e.Fragment,{children:[e.jsx(de,{analytics:L,onLoad:s=>(l=>l.trackPageLoaded(Ae.Event.accountsDepositCheckFormViewed))(s)}),e.jsx(Y,{anchor:"right",open:n,PaperProps:{style:{width:Ma.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(Va,{onClick:s=>s.stopPropagation(),children:e.jsx(da,{...y})})})]})},Va=F(X)`
33
+ `,Ma={overlayWidth:new q(100,100,58)},an=({isCheckDepositDrawerOpen:n,closeDrawerHandler:a})=>{const r=U(),t=M(),o=z(),i=k((s=>R(s))),d=j.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:`${we.fileMicroServiceBaseUrl}`,authParams:p,onSaveChangesToLocalStore:s=>{o($n(s))},updateFilesEntity:s=>{o(He({files:s}))},onAnotherTransferClick:()=>{o(ge())},onDeleteFile:s=>{o(Ve(s))},onEditFileName:(s,l)=>{o($e(s,l.split(".")[0]))},onCheckDpositClick:()=>{o(Mn())},onDismissClick:()=>{a(!0),o(ge())}};return e.jsxs(e.Fragment,{children:[e.jsx(de,{analytics:L,onLoad:s=>(l=>l.trackPageLoaded(Ae.Event.accountsDepositCheckFormViewed))(s)}),e.jsx(Y,{anchor:"right",open:n,PaperProps:{style:{width:Ma.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($a,{onClick:s=>s.stopPropagation(),children:e.jsx(da,{...y})})})]})},$a=F(X)`
34
34
  display: flex;
35
35
  min-height: 100%;
36
36
  flex-direction: column;
37
- `,$a={overlayWidth:new q(100,100,58)},Ha=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(Ze(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=>$n(C))),d=k((C=>R(C))),c=U(),p=M(),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}=H(),{configValue:D}=P(N.zeniAccountsConfig),A=he(D),I=()=>{t(!0),f(ve())};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=>(w=>w.trackPageLoaded(Ae.Event.zeniAccountsTransferFormViewed))(C)}),e.jsx(Y,{onClose:()=>{(s==="achTransfer"&&h===!1||s==="achTransfer"&&h&&i.fetchState==="Completed")&&I()},anchor:"right",open:n,PaperProps:{style:{width:$a.overlayWidth.valuePercentage(p),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:c.colors.black,opacity:.75,cursor:"pointer"}}},children:e.jsx(Za,{onClick:C=>C.stopPropagation(),children:e.jsx(Ha,{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(Zn(y))},onDismissClick:I,onSaveChangesToLocalStore:C=>{f(Hn(C))},onAnotherTransferClick:()=>{m(!1),f(ve())},currentTenant:d,zeniAccountsConfigDetail:o,currentDrawerContent:s,setCurrentDrawerContent:l,showReviewContent:h,setShowReviewContent:m,onBackClick:()=>{},maxInsuredAmount:A.maxInsuredAmount})})})]})},Za=F(X)`
37
+ `,Va={overlayWidth:new q(100,100,58)},Ha=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(Ze(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=M(),f=z(),{accountId:y}=W(),[s,l]=g.useState("achTransfer"),[h,m]=g.useState(!1);if(j.getSignedInUser()==null)throw Error("Can't access invite people page without signing in...");const{useDynamicConfig:P}=H(),{configValue:D}=P(N.zeniAccountsConfig),A=he(D),I=()=>{t(!0),f(be())};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=>(w=>w.trackPageLoaded(Ae.Event.zeniAccountsTransferFormViewed))(C)}),e.jsx(Y,{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(Za,{onClick:C=>C.stopPropagation(),children:e.jsx(Ha,{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(Zn(y))},onDismissClick:I,onSaveChangesToLocalStore:C=>{f(Hn(C))},onAnotherTransferClick:()=>{m(!1),f(be())},currentTenant:d,zeniAccountsConfigDetail:o,currentDrawerContent:s,setCurrentDrawerContent:l,showReviewContent:h,setShowReviewContent:m,onBackClick:()=>{},maxInsuredAmount:A.maxInsuredAmount})})})]})},Za=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-VaiuWGni.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(Ye(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(Yn(s,l,"zeni_accounts","external_account",h))},onEstablishConnectionClick:s=>{n(Ze(s,i,"external_account",void 0,"link_external_account"))},onCreateCheckingClick:s=>{n(qn(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=M(),{tenantEmailDomain:d}=W(),{useDynamicConfig:c,useFeatureGate:p}=H(),f=U(),{configValue:y}=c(N.zeniAccountsConfig),{isFeatureEnabled:s}=p($.isDebitCardFeatureEnabled),{isFeatureEnabled:l}=p($.isAutoTransferRuleEnabled),h=he(y),m=k((_=>R(_))),P=m.companyId??b.getSignedInUserTenant(d)?.companyId,{configValue:D}=c(N.expressPayConfig),A=D.is_enable_all_tenants===!0||D.tenant_ids!=null&&D.tenant_ids.includes(m.tenantId),[I,C]=g.useState(!1),[w,E]=g.useState(!1),[T,j]=g.useState(!1),[v,O]=g.useState(!1),S=k((_=>Ge(_))),B=S.fetchState,u=k((_=>Ue(_))),V=u?.fetchState??"Not-Started",pe=!!m.companyZeniAccountInfo?.info?.isZeniAccountEnabled,oe=te(),Z=!!m.companyZeniAccountInfo?.info?.isZeniAccountTOSAccepted,J=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((()=>{!w&&V==="Not-Started"&&P&&(E(!0),o(ze(!0)))}),[w,V,P,o]),g.useEffect((()=>{n!=null&&n===!0?j(!0):(j(!1),document.body.style.overflow="auto")}),[n]),g.useEffect((()=>{O(a!=null&&a===!0)}),[a]);const Ie=()=>{j(!1),t("..")},[mn,gn]=g.useState(!1),Se=_=>{gn(_)},{isAiCfoAccessEnabled:fn,onAskAiCfoClick:hn}=nn({mobileExploreReferrer:"Checking Accounts"});Qe({isDataReady:B==="Completed"});const yn=qe(m),xn=xe(s,m);return yn===!0&&xn!==!0?e.jsx(en,{}):pe?e.jsxs(e.Fragment,{children:[S.fetchState==="Completed"&&T===!1&&v===!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,v===!0?e.jsx(an,{closeDrawerHandler:Ie,isCheckDepositDrawerOpen:v}):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:A,isBillPayEnabled:dn,isDebitCardFeatureEnabled:s,isAutoTransferRuleEnabled:l,handleDrawerToggle:Se,isAiCfoAccessEnabled:fn,onAskAiCfoClick:hn})]})]}):Z&&J?e.jsx(Q,{to:"../setup"}):m.companyZeniAccountInfo?.info&&!Z&&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`,qa=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(Ye(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(Yn(s,l,"zeni_accounts","external_account",h))},onEstablishConnectionClick:s=>{n(Ze(s,i,"external_account",void 0,"link_external_account"))},onCreateCheckingClick:s=>{n(qn(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=M(),{tenantEmailDomain:d}=W(),{useDynamicConfig:c,useFeatureGate:p}=H(),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??j.getSignedInUserTenant(d)?.companyId,{configValue:D}=c(N.expressPayConfig),A=D.is_enable_all_tenants===!0||D.tenant_ids!=null&&D.tenant_ids.includes(m.tenantId),[I,C]=g.useState(!1),[w,E]=g.useState(!1),[T,v]=g.useState(!1),[b,O]=g.useState(!1),S=k((_=>Ge(_))),B=S.fetchState,u=k((_=>Ue(_))),$=u?.fetchState??"Not-Started",pe=!!m.companyZeniAccountInfo?.info?.isZeniAccountEnabled,oe=te(),Z=!!m.companyZeniAccountInfo?.info?.isZeniAccountTOSAccepted,J=ee(oe?.loggedInUserRoleMap),ln=ye(oe?.loggedInUserRoleMap),dn=!!m.companyBillPayInfo?.info?.isBillPayEnabled,De=j.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((()=>{!w&&$==="Not-Started"&&P&&(E(!0),o(ze(!0)))}),[w,$,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=qe(m),xn=xe(s,m);return yn===!0&&xn!==!0?e.jsx(en,{}):pe?e.jsxs(e.Fragment,{children:[S.fetchState==="Completed"&&T===!1&&b===!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,b===!0?e.jsx(an,{closeDrawerHandler:Ie,isCheckDepositDrawerOpen:b}):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:A,isBillPayEnabled:dn,isDebitCardFeatureEnabled:s,isAutoTransferRuleEnabled:l,handleDrawerToggle:Se,isAiCfoAccessEnabled:fn,onAskAiCfoClick:hn})]})]}):Z&&J?e.jsx(Q,{to:"../setup"}):m.companyZeniAccountInfo?.info&&!Z&&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`,qa=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-VaiuWGni.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
- `,Ya=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:`${we.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(Ye(p))):c==="checkDeposit"?(f=rn(d,i),p!=null&&n(Jn(p))):c==="accountStatement"&&(f=Ja(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(Je(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=M(),{tenantEmailDomain:c,accountId:p}=W(),{useDynamicConfig:f}=H(),{useFeatureGate:y}=H(),{isFeatureEnabled:s}=y($.isDebitCardFeatureEnabled),l=k((J=>R(J))),{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(),A=l.companyId??b.getSignedInUserTenant(c)?.companyId,I={userId:D?.userId??"",sessionId:D?.zeniSessionId??"",tenantId:l.tenantId??""},C=`${Ce}/account_details`,[w,E]=g.useState(!1),[T,j]=g.useState(!1),[v,O]=g.useState(!1),[S,B]=g.useState(!1),u=k((J=>Xe(J,p??""))),V=u.fetchState,{isAiCfoAccessEnabled:pe,onAskAiCfoClick:oe}=nn({mobileExploreReferrer:"Checking Account Detail"});Qe({isDataReady:V==="Completed"}),g.useEffect((()=>{w||(i(Je(p??"",!1)),E(!0))}),[w,i,V]),g.useEffect((()=>{B(r!=null&&r===!0)}),[r]),g.useEffect((()=>{n!=null&&n===!0?j(!0):(j(!1),document.body.style.overflow="auto")}),[n]),g.useEffect((()=>{O(a!=null&&a===!0)}),[a]);const Z=()=>{B(!1),o("..")};return e.jsxs(e.Fragment,{children:[S===!0&&u.accountDetail!=null?e.jsx(_a,{authParams:I,downloadAccountDetailEndPoint:C,closeDrawerHandler:Z,isAccountInfoDrawerOpen:S,zeniBankAccountDetail:u.accountDetail}):null,T===!0?e.jsx(tn,{closeDrawerHandler:Z,isTransferDrawerOpen:T,zeniAccountsConfig:u.zeniAccountsConfig,authParams:I,downloadAccountDetailEndPoint:C}):null,v===!0?e.jsx(an,{closeDrawerHandler:Z,isCheckDepositDrawerOpen:v}):null,e.jsx(qa,{windowSize:d,children:e.jsx(Ya,{navigate:o,currentTenant:l,location:t,companyId:A,isDebitCardFeatureEnabled:s,accountId:p??"",isBillPayEnabled:P,isExpressPayEnabled:m,isAiCfoAccessEnabled:pe,onAskAiCfoClick:oe})})]})}const Xa=(n,a)=>`/${n}/checking/${a}/account-info`,Ja=(n,a)=>`/${n}/checking/${a}/statements`,Ka=ae((function(n,a){const{companyId:r}=a;return{zeniAccountSetupView:Kn(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}=H(),o=fa(),i=U(),[d,c]=g.useState(!1),[p,f]=g.useState(!1),y=k((w=>R(w))),{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=w=>{c(w)};if(m==null)throw Error("Can't access Zeni account promo page without signing in...");const A=te(),I=ee(A?.loggedInUserRoleMap),C=ye(A?.loggedInUserRoleMap);if(P&&I)return e.jsx(Q,{to:"../../checking/setup"});if(y.company?.companyZeniAccountInfo&&(!P&&I||C)){if(a.state?.message==="activation"){const w=Ke(a.state?.pathnameStackToGoBack);n(a.pathname,{state:{...a.state,message:void 0,pathnameStackToGoBack:w.newStack}})}return e.jsxs(e.Fragment,{children:[e.jsx(ha,{showConfetti:p}),e.jsx(de,{analytics:L,onLoad:w=>(E=>E.trackPageLoaded(Ae.Event.accountsPromoPageViewed))(w)}),e.jsx(ue,{isAppContentDrawerOpen:d,handleDrawerToggle:D}),e.jsx(Ka,{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 vt(){const n=G(),a=k((S=>R(S))),r=U(),{useFeatureGate:t,useDynamicConfig:o}=H(),i=te(),d=ee(i?.loggedInUserRoleMap),c=ye(i?.loggedInUserRoleMap),p=!!a.company?.companyZeniAccountInfo?.isZeniAccountEnabled,f=!!a.company?.companyZeniAccountInfo?.isZeniAccountTOSAccepted,{isFeatureEnabled:y}=t($.isChargeCardFeatureEnabled),{isFeatureEnabled:s}=t($.isDebitCardFeatureEnabled),l=qe(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),A=(a?.company==null||a.company.featuresActivationInfo?.isReimbursementFeatureEnabled&&!m)&&ta(i?.loggedInUserRoleMap),I=!!a.company?.companyZeniAccountInfo?.isZeniAccountEnabled&&!m,{configValue:C}=o(N.expressPayConfig),w=C.is_enable_all_tenants===!0||C.tenant_ids!=null&&C.tenant_ids.includes(a.tenantId),{isFeatureEnabled:E}=t($.isAutoTransferRuleEnabled),T=xa(a,y,s)&&!m&&oa(i?.loggedInUserRoleMap),j=sa(i?.loggedInUserRoleMap),v=I&&ee(i?.loggedInUserRoleMap),O=v||Me(i?.loggedInUserRoleMap);return e.jsxs(Re,{children:[e.jsx(x,{path:"setup",element:e.jsx(Oe,{isBillPayAdminLevelAccess:P,isUserHasOnlyBillPayAccess:D,isReimbursementAdminLevelAccess:A,isZeniAccountAdminLevelAccess:v,isChargeCardAdminLevelAccess:T,isUserHasOnlyCardAccess:j,productType:"zeni_accounts",type:"setup"})}),e.jsx(x,{path:"verification",element:e.jsx(Oe,{isBillPayAdminLevelAccess:P,isUserHasOnlyBillPayAccess:D,isReimbursementAdminLevelAccess:A,isZeniAccountAdminLevelAccess:v,isChargeCardAdminLevelAccess:T,isUserHasOnlyCardAccess:j,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(K,{})}),w&&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(K,{})}),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(K,{})}),e.jsx(x,{path:":accountId/*",element:e.jsx(et,{})}),e.jsx(x,{path:"*",element:e.jsx(K,{})})]}):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(K,{})})]})}export{vt as default};
57
+ `,Ya=ae((function(n,a){const{currentTenant:r}=a,t=Xe(n,a.accountId),o=j.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:`${we.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(Ye(p))):c==="checkDeposit"?(f=rn(d,i),p!=null&&n(Jn(p))):c==="accountStatement"&&(f=Ja(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(Je(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=M(),{tenantEmailDomain:c,accountId:p}=W(),{useDynamicConfig:f}=H(),{useFeatureGate:y}=H(),{isFeatureEnabled:s}=y(V.isDebitCardFeatureEnabled),l=k((J=>R(J))),{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=j.getSignedInUser(),A=l.companyId??j.getSignedInUserTenant(c)?.companyId,I={userId:D?.userId??"",sessionId:D?.zeniSessionId??"",tenantId:l.tenantId??""},C=`${Ce}/account_details`,[w,E]=g.useState(!1),[T,v]=g.useState(!1),[b,O]=g.useState(!1),[S,B]=g.useState(!1),u=k((J=>Xe(J,p??""))),$=u.fetchState,{isAiCfoAccessEnabled:pe,onAskAiCfoClick:oe}=nn({mobileExploreReferrer:"Checking Account Detail"});Qe({isDataReady:$==="Completed"}),g.useEffect((()=>{w||(i(Je(p??"",!1)),E(!0))}),[w,i,$]),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 Z=()=>{B(!1),o("..")};return e.jsxs(e.Fragment,{children:[S===!0&&u.accountDetail!=null?e.jsx(_a,{authParams:I,downloadAccountDetailEndPoint:C,closeDrawerHandler:Z,isAccountInfoDrawerOpen:S,zeniBankAccountDetail:u.accountDetail}):null,T===!0?e.jsx(tn,{closeDrawerHandler:Z,isTransferDrawerOpen:T,zeniAccountsConfig:u.zeniAccountsConfig,authParams:I,downloadAccountDetailEndPoint:C}):null,b===!0?e.jsx(an,{closeDrawerHandler:Z,isCheckDepositDrawerOpen:b}):null,e.jsx(qa,{windowSize:d,children:e.jsx(Ya,{navigate:o,currentTenant:l,location:t,companyId:A,isDebitCardFeatureEnabled:s,accountId:p??"",isBillPayEnabled:P,isExpressPayEnabled:m,isAiCfoAccessEnabled:pe,onAskAiCfoClick:oe})})]})}const Xa=(n,a)=>`/${n}/checking/${a}/account-info`,Ja=(n,a)=>`/${n}/checking/${a}/statements`,Ka=ae((function(n,a){const{companyId:r}=a;return{zeniAccountSetupView:Kn(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}=H(),o=fa(),i=U(),[d,c]=g.useState(!1),[p,f]=g.useState(!1),y=k((w=>R(w))),{configValue:s}=t(N.zeniAccountsConfig),l=he(s);g.useEffect((()=>{p===!1&&a.state?.message==="activation"&&f(!0)}),[a.state]);const h=j.getSignedInUserTenant(r)?.companyId??y.companyId,m=j.getSignedInUser(),P=!!y.companyZeniAccountInfo?.info?.isZeniAccountTOSAccepted,D=w=>{c(w)};if(m==null)throw Error("Can't access Zeni account promo page without signing in...");const A=te(),I=ee(A?.loggedInUserRoleMap),C=ye(A?.loggedInUserRoleMap);if(P&&I)return e.jsx(Q,{to:"../../checking/setup"});if(y.company?.companyZeniAccountInfo&&(!P&&I||C)){if(a.state?.message==="activation"){const w=Ke(a.state?.pathnameStackToGoBack);n(a.pathname,{state:{...a.state,message:void 0,pathnameStackToGoBack:w.newStack}})}return e.jsxs(e.Fragment,{children:[e.jsx(ha,{showConfetti:p}),e.jsx(de,{analytics:L,onLoad:w=>(E=>E.trackPageLoaded(Ae.Event.accountsPromoPageViewed))(w)}),e.jsx(ue,{isAppContentDrawerOpen:d,handleDrawerToggle:D}),e.jsx(Ka,{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 bt(){const n=G(),a=k((S=>R(S))),r=U(),{useFeatureGate:t,useDynamicConfig:o}=H(),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=qe(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),A=(a?.company==null||a.company.featuresActivationInfo?.isReimbursementFeatureEnabled&&!m)&&ta(i?.loggedInUserRoleMap),I=!!a.company?.companyZeniAccountInfo?.isZeniAccountEnabled&&!m,{configValue:C}=o(N.expressPayConfig),w=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),b=I&&ee(i?.loggedInUserRoleMap),O=b||Me(i?.loggedInUserRoleMap);return e.jsxs(Re,{children:[e.jsx(x,{path:"setup",element:e.jsx(Oe,{isBillPayAdminLevelAccess:P,isUserHasOnlyBillPayAccess:D,isReimbursementAdminLevelAccess:A,isZeniAccountAdminLevelAccess:b,isChargeCardAdminLevelAccess:T,isUserHasOnlyCardAccess:v,productType:"zeni_accounts",type:"setup"})}),e.jsx(x,{path:"verification",element:e.jsx(Oe,{isBillPayAdminLevelAccess:P,isUserHasOnlyBillPayAccess:D,isReimbursementAdminLevelAccess:A,isZeniAccountAdminLevelAccess:b,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(K,{})}),w&&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(K,{})}),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(K,{})}),e.jsx(x,{path:":accountId/*",element:e.jsx(et,{})}),e.jsx(x,{path:"*",element:e.jsx(K,{})})]}):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(K,{})})]})}export{bt as default};
@@ -1,4 +1,4 @@
1
- import{j as i}from"./liveblocks-VaiuWGni.js";import{a as m}from"./sentry-DzjqovIb.js";import{h as x,u as $,g as T,i as j,j as p}from"./core-oLPZqW1J.js";import{T$ as s,T_ as v,a0w as B,fI as C,a0x as z}from"./zeni-epic-state-DADihDI9.js";import{$ as D,ac as g,z as E,a5 as L,d6 as P,a2 as _}from"./index-DXmrlDJg.js";import{u as N,n as U}from"./mui-1Y-6fO7a.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},n=new e.Error().stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="66f9eca7-0337-4f28-92bc-f4364a576b91",e._sentryDebugIdIdentifier="sentry-dbid-66f9eca7-0337-4f28-92bc-f4364a576b91")}catch{}})();const G=U.div`
1
+ import{j as i}from"./liveblocks-CtP3KKBx.js";import{a as m}from"./sentry-D1S3f4Dm.js";import{h as x,u as $,g as T,i as j,j as p}from"./core-Du7UPqMS.js";import{T$ as s,T_ as v,a0w as B,fI as C,a0x as z}from"./zeni-epic-state-SU_Ch21f.js";import{$ as D,ac as g,z as E,a5 as L,d6 as P,a2 as _}from"./index-Bkw6b9BJ.js";import{u as N,n as U}from"./mui-DWdv7IPr.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},n=new e.Error().stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="66f9eca7-0337-4f28-92bc-f4364a576b91",e._sentryDebugIdIdentifier="sentry-dbid-66f9eca7-0337-4f28-92bc-f4364a576b91")}catch{}})();const G=U.div`
2
2
  display: flex;
3
3
  height: 100vh;
4
4
  width: 100%;
@@ -1 +1 @@
1
- import"./sentry-DzjqovIb.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-D1S3f4Dm.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};