@zeniai/web-app-ui 5.1.18-prod → 5.1.19-dev
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/AddressRoutes-B3K8Zkr4.js +1 -0
- package/dist/assets/{AddressScreen-h4XqWLFk.js → AddressScreen-BMBB0sFI.js} +2 -2
- package/dist/assets/AiCfoScreen-CfYVTAIg.js +22 -0
- package/dist/assets/{BillPayApprovalRoutes-D7gouICo.js → BillPayApprovalRoutes-BS62LH2L.js} +1 -1
- package/dist/assets/{BillPayRoutes-D5BgZ65T.js → BillPayRoutes-bisePnZd.js} +18 -18
- package/dist/assets/{BusinessVerificationPageScreen-C7p62r1u.js → BusinessVerificationPageScreen-BZD4skoh.js} +2 -2
- package/dist/assets/ChargeCardRoutes-CDS59Xwv.js +71 -0
- package/dist/assets/{CompanyPassportScreen-C0e99sp4.js → CompanyPassportScreen-DsJVzpFG.js} +1 -1
- package/dist/assets/ConnectionAuthScreen-BuI_oq90.js +11 -0
- package/dist/assets/CustomerOnboardingAuthScreen-DsZqbEUd.js +1 -0
- package/dist/assets/{CustomerOnboardingRoutes-Bu7JFFPk.js → CustomerOnboardingRoutes-O4av1jPs.js} +4 -4
- package/dist/assets/{DashboardRoutes-fSeiZsRj.js → DashboardRoutes-D0k050PV.js} +3 -3
- package/dist/assets/{DefaultTenantHome-CeW-U19J.js → DefaultTenantHome-BbBUbIWa.js} +1 -1
- package/dist/assets/{DomesticWireDetailScreen-C-ET-tHk.js → DomesticWireDetailScreen-SZO0rBvK.js} +3 -3
- package/dist/assets/DrawerScreen-CzCSQKkH.js +1 -0
- package/dist/assets/{EntityDetailRoutes-JgLiIHrE.js → EntityDetailRoutes-CBVlSnyd.js} +1 -1
- package/dist/assets/ExpenseAutomationRoutes-D0e3oZDv.js +25 -0
- package/dist/assets/FeaturePreviewScreen-D4eX4iQx.js +1 -0
- package/dist/assets/HubSpotOAuthCallbackScreen-C4cDnT-c.js +1 -0
- package/dist/assets/MagicLinkRoutes-Djx-V319.js +72 -0
- package/dist/assets/MagicLinkSignInScreen-B0K4xBkV.js +12 -0
- package/dist/assets/{MobileAppDrawer-C0O6RwlS.js → MobileAppDrawer-eKyN01h-.js} +1 -1
- package/dist/assets/NotFoundScreen-LDtxz9Tf.js +1 -0
- package/dist/assets/{NotificationRoutes-DBRG1ttF.js → NotificationRoutes-AmfzAHaK.js} +1 -1
- package/dist/assets/OAuthConsentScreen-A_pRI4oS.js +1 -0
- package/dist/assets/PandLWithForecastRoutes-Br3l95qG.js +1 -0
- package/dist/assets/PeopleRoutes-Bdl8afkN.js +22 -0
- package/dist/assets/PerformanceRoutes-BPACNNNy.js +1 -0
- package/dist/assets/{Preview-BdTx8_Ms.js → Preview-WyBDjHSN.js} +1 -1
- package/dist/assets/{QBOConnectionScreen-CjqTRbel.js → QBOConnectionScreen-DZKZ6dwk.js} +1 -1
- package/dist/assets/ReferralListScreen-CiLc0Wce.js +5 -0
- package/dist/assets/ReimbursementApprovalRoutes-D5IEw4ph.js +1 -0
- package/dist/assets/{ReimbursementApprovalRuleDetailScreen-DoAuMin4.js → ReimbursementApprovalRuleDetailScreen-BX7cJPUH.js} +1 -1
- package/dist/assets/{ReimbursementRoutes-CHFe5XIg.js → ReimbursementRoutes-Ba9Gs99b.js} +9 -9
- package/dist/assets/{ReportsRoutes-ChjB9-LL.js → ReportsRoutes-BP37j5Lj.js} +1 -1
- package/dist/assets/RewardsRoutes-DQ0AmGMz.js +1 -0
- package/dist/assets/{ScreenRoutes-BMdLa5gz.js → ScreenRoutes-BiKmDGCZ.js} +2 -2
- package/dist/assets/{SettingsRoutes-CEBU7Pmp.js → SettingsRoutes-CyWke5_f.js} +8 -8
- package/dist/assets/{SetupPagesScreen-BWtBrDwg.js → SetupPagesScreen-E55E2MtQ.js} +5 -5
- package/dist/assets/SignInScreen-xWnEnN5B.js +1 -0
- package/dist/assets/SignOutScreen-B-dBNRWO.js +9 -0
- package/dist/assets/{TaskListScreen-B_0YloJu.js → TaskListScreen-B3GpjTSI.js} +2 -2
- package/dist/assets/{TaskRoutes-BaioqWrn.js → TaskRoutes-CDUK--mB.js} +2 -2
- package/dist/assets/{TransactionDetailRoutes-C920_gbq.js → TransactionDetailRoutes-XMo1cIDn.js} +1 -1
- package/dist/assets/{TransactionDetailScreen-C0lakjhh.js → TransactionDetailScreen-wOqzGz4b.js} +2 -2
- package/dist/assets/{TransactionListRoutes-BB_-lbgH.js → TransactionListRoutes-BJgk8hPK.js} +1 -1
- package/dist/assets/TreasuryRoutes-NPRaF6Vs.js +37 -0
- package/dist/assets/{VendorsRoutes-Cd6YohAQ.js → VendorsRoutes-DYaI4UvS.js} +23 -23
- package/dist/assets/WiseConfirmationScreen-CKSpUKdd.js +12 -0
- package/dist/assets/ZeniAccountRoutes-PCcpiHfl.js +57 -0
- package/dist/assets/ZeniAccountStatementScreen-CpILstP9.js +9 -0
- package/dist/assets/{accountMappingHelper-U14pLYO6.js → accountMappingHelper-BN803kfl.js} +1 -1
- package/dist/assets/{analytics-BwaA5sD9.js → analytics-Bt-6aSwp.js} +1 -1
- package/dist/assets/analyticsHelper-Bx72793Y.js +1 -0
- package/dist/assets/{core-BQD7Nh1h.js → core-DA33MFkN.js} +1 -1
- package/dist/assets/{decodeURIComponentSafe-BhXJfnxb.js → decodeURIComponentSafe-Dp2pNC7r.js} +1 -1
- package/dist/assets/{dnd-DkRdAB95.js → dnd-vhylj_Eh.js} +1 -1
- package/dist/assets/{empty-D92l_sNN.js → empty-BkOHZhZ_.js} +1 -1
- package/dist/assets/{empty-DEt3xgrc.js → empty-C3vQ9p7W.js} +1 -1
- package/dist/assets/{emptyVideoElement-DGC_-fh5.js → emptyVideoElement-DqXx_3iz.js} +1 -1
- package/dist/assets/epic-DOohCIB-.js +2 -0
- package/dist/assets/getLocaleForTenant-DFOWY2yJ.js +1 -0
- package/dist/assets/{index-cOsp3DeK.js → index-B0KYqmOA.js} +1 -1
- package/dist/assets/{index-fagaUwRp.js → index-BDGZBSxD.js} +1 -1
- package/dist/assets/{index-OWkAmseL.js → index-BIecxFT-.js} +1 -1
- package/dist/assets/{index-NqZwiQK9.js → index-C0Rr_5w9.js} +10743 -10739
- package/dist/assets/{index-Ciae8kLV.js → index-C10P_vbj.js} +1 -1
- package/dist/assets/{index-C5176P0-.js → index-CLexxx1X.js} +1 -1
- package/dist/assets/{index-Bxy0xRCW.js → index-Daus_KEs.js} +2 -2
- package/dist/assets/{index-CvtLpop2.js → index-Dd3yljav.js} +1 -1
- package/dist/assets/{lexical-BChaWXti.js → lexical-CvOa6Yk0.js} +1 -1
- package/dist/assets/{liveblocks-DIG_sQTS.js → liveblocks-DENVUg9q.js} +1 -1
- package/dist/assets/{lottie-BzitVa6X.js → lottie-BT3ic1mv.js} +1 -1
- package/dist/assets/{mui-BTlbyoml.js → mui-D6faDY4H.js} +1 -1
- package/dist/assets/{pathToGoBack-B_A6jlhq.js → pathToGoBack-Dpj_uhjQ.js} +1 -1
- package/dist/assets/{pdf-C5Pt0V8d.js → pdf-DcKpVBQA.js} +3 -3
- package/dist/assets/{pdf-lib-CSo7oMDa.js → pdf-lib-BChZu1hi.js} +1 -1
- package/dist/assets/{plaid-q_a4iNLa.js → plaid-WpCusSjr.js} +1 -1
- package/dist/assets/{pusher-CnfjVWRr.js → pusher-BxdG568H.js} +1 -1
- package/dist/assets/{react-C9ZfY_T-.js → react-BHVVGiJF.js} +1 -1
- package/dist/assets/{react-D-OLDVsl.js → react-BIK8RdLM.js} +1 -1
- package/dist/assets/{react-6sr0tylv.js → react-CP7WlKlB.js} +1 -1
- package/dist/assets/{react-711VDp7d.js → react-CvIqlY8S.js} +1 -1
- package/dist/assets/{react-DbnNLORL.js → react-GQ6ntsPB.js} +1 -1
- package/dist/assets/{react-D1h5CEcP.js → react-cBSmH1hl.js} +1 -1
- package/dist/assets/{recharts-DvL3rz6g.js → recharts-Cqn7-bzR.js} +1 -1
- package/dist/assets/{routePaths-Bn28lFcN.js → routePaths-Bv4j02bo.js} +1 -1
- package/dist/assets/{sentry-DeeuWfnQ.js → sentry-BAjw0qw4.js} +1 -1
- package/dist/assets/{url-DKFJDlOB.js → url-C_Ezxzjh.js} +1 -1
- package/dist/assets/{url-A4MFeyPJ.js → url-Ckuey0dJ.js} +1 -1
- package/dist/assets/{useAiCfoDashboardSuggestedQuestionsChips-BiXyiTHA.js → useAiCfoDashboardSuggestedQuestionsChips-Dmb_D-47.js} +1 -1
- package/dist/assets/useAskAiCfoHostNavButtonProps-B95l7Aji.js +1 -0
- package/dist/assets/{useDeviceId-DVkU6ZvZ.js → useDeviceId-BDljgxSq.js} +1 -1
- package/dist/assets/{useInitialThreadRequest-D6gn8nP9.js → useInitialThreadRequest-TgcQ8YpV.js} +1 -1
- package/dist/assets/{utils-BQSiJMCN.js → utils-sY58mrq9.js} +1 -1
- package/dist/assets/{withTransactionSidePanel-BtMnmIsf.js → withTransactionSidePanel-B6JG8pbO.js} +3 -3
- package/dist/assets/{zeni-epic-state-DPMNRP9z.js → zeni-epic-state-PjsyjhMR.js} +6 -6
- package/dist/index.html +1 -1
- package/package.json +11 -6
- package/dist/assets/AddressRoutes-BDrwFvCT.js +0 -1
- package/dist/assets/AiCfoScreen-CYXcUeFt.js +0 -22
- package/dist/assets/ChargeCardRoutes-oHUMEoHv.js +0 -71
- package/dist/assets/ConnectionAuthScreen-C5ATh2aQ.js +0 -11
- package/dist/assets/CustomerOnboardingAuthScreen-Cf_7TqTo.js +0 -1
- package/dist/assets/DrawerScreen-C7CnGHit.js +0 -1
- package/dist/assets/ExpenseAutomationRoutes-rfivWdiO.js +0 -25
- package/dist/assets/FeaturePreviewScreen-CF3V2uH8.js +0 -1
- package/dist/assets/HubSpotOAuthCallbackScreen-4338dC9C.js +0 -1
- package/dist/assets/MagicLinkRoutes-Cfiv5xPy.js +0 -72
- package/dist/assets/MagicLinkSignInScreen-UJuPETvB.js +0 -12
- package/dist/assets/NotFoundScreen-AUmyqBev.js +0 -1
- package/dist/assets/OAuthConsentScreen-Bvo_J7wG.js +0 -1
- package/dist/assets/PandLWithForecastRoutes-ZpSBg-dz.js +0 -1
- package/dist/assets/PeopleRoutes-De8fDIhc.js +0 -22
- package/dist/assets/PerformanceRoutes-B2LMQXF2.js +0 -1
- package/dist/assets/ReferralListScreen-Dl9-tAZb.js +0 -5
- package/dist/assets/ReimbursementApprovalRoutes-CRxk3DiA.js +0 -1
- package/dist/assets/RewardsRoutes-BLviLFku.js +0 -1
- package/dist/assets/SignInScreen-B_BoWxfU.js +0 -1
- package/dist/assets/SignOutScreen-BDNz5E8-.js +0 -9
- package/dist/assets/TreasuryRoutes-C0gR0NDx.js +0 -37
- package/dist/assets/WiseConfirmationScreen-DJuP7iVN.js +0 -12
- package/dist/assets/ZeniAccountRoutes-DQJB2Hta.js +0 -57
- package/dist/assets/ZeniAccountStatementScreen-9NreSUns.js +0 -9
- package/dist/assets/analyticsHelper-DfvTrPlk.js +0 -1
- package/dist/assets/epic-D-w2dyIq.js +0 -2
- package/dist/assets/getLocaleForTenant-D4clEihj.js +0 -1
- package/dist/assets/useAskAiCfoHostNavButtonProps-DFP8Wx8F.js +0 -1
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
import{j as t}from"./liveblocks-DIG_sQTS.js";import{i as S,n as x,h as C,g as y,u as ee,s as te,j as E,N as ae,o as ne,p}from"./core-BQD7Nh1h.js";import{JD as k,JE as v,JF as T,zD as D,zp as G,JG as z,JH as oe,JI as se,zt as ie,eW as I,zA as le,zx as re}from"./zeni-epic-state-DPMNRP9z.js";import{J as g,o as r,M as de,c as j,i as J,Z as ce,j as me,_ as pe,m as H,v as ue,I as he,q as xe,r as ge,h as fe,s as we,B as be,x as Se,R as ye,S as ke,y as ve,A as je,O as Ie}from"./index-NqZwiQK9.js";import{n as m}from"./mui-BTlbyoml.js";import f from"./NotFoundScreen-AUmyqBev.js";import{a as $}from"./sentry-DeeuWfnQ.js";import"./recharts-DvL3rz6g.js";import"./analytics-BwaA5sD9.js";import"./plaid-q_a4iNLa.js";import"./dnd-DkRdAB95.js";import"./stripe-DMRn4zHo.js";import"./lottie-BzitVa6X.js";import"./lexical-BChaWXti.js";import"./pdf-C5Pt0V8d.js";import"./utils-BQSiJMCN.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]="b482d7dc-51e6-40e0-b6ce-071e8e1e4aca",e._sentryDebugIdIdentifier="sentry-dbid-b482d7dc-51e6-40e0-b6ce-071e8e1e4aca")}catch{}})();const $e=m.div`
|
|
2
|
-
display: flex;
|
|
3
|
-
height: 100%;
|
|
4
|
-
width: 100%;
|
|
5
|
-
flex: 1 1 auto;
|
|
6
|
-
flex-direction: column;
|
|
7
|
-
align-items: center;
|
|
8
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
9
|
-
box-shadow: ${e=>`0px 2px ${r.sp1} ${e.theme.colors.dropShadowNormal}`};
|
|
10
|
-
`,Ce=x(function(e){const a=k(e),n=v(e),{companyName:o}=a;return{companyName:o,isDisabled:a.fetchState!=="Completed"?"disabled":void 0,magicLinkBankAccountDetails:n,magicLinkViewState:a}},function(e,a){const{vendorId:n,billId:o}=a;return{onFetchBankName:s=>{e(G(s))},onSaveHandler:s=>{j.trackBillPayMagicLinkSubmitBankAccountDetails(o),e(D(s,"standard",n,o))},onACHDetailsUpdated:s=>{const{bankAccountSection:l}=s;e(T({data:l}))}}})(de);function F(){const e=g(),{vendorId:a,billId:n}=S();return a==null||n==null?t.jsx(f,{}):t.jsx(t.Fragment,{children:t.jsx($e,{windowSize:e,children:t.jsx(Ce,{vendorId:a,billId:n})})})}const De=m.div`
|
|
11
|
-
display: flex;
|
|
12
|
-
height: 100vh;
|
|
13
|
-
width: 100%;
|
|
14
|
-
flex: 1 1 auto;
|
|
15
|
-
flex-direction: column;
|
|
16
|
-
align-items: center;
|
|
17
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
18
|
-
box-shadow: ${e=>`0px 2px ${r.sp1} ${e.theme.colors.dropShadowNormal}`};
|
|
19
|
-
`,ze=x(function(e,a){const{isSubPage:n}=a;return{addressToEdit:z(e),googleAPIKey:J.googleMapsAPIKey,isSubPage:n}},function(e,a){const{navigate:n,location:o}=a,s=()=>{const l=me(o.state?.pathnameStackToGoBack),i=l.poppedPathname??Be();n(i,{state:{pathnameStackToGoBack:l.newStack}})};return{onSubmitHandler:l=>{const i=Pe(l);e(oe({addressToCreate:i})),s()},onCancel:()=>{s()}}})(ce);function Ae({isSubPage:e}){const a=C(),n=y(),o=g();return t.jsx(t.Fragment,{children:t.jsx(De,{windowSize:o,children:t.jsx(ze,{location:n,navigate:a,isSubPage:e===!0,googleAPIKey:J.googleMapsAPIKey})})})}const Be=(e=2)=>{let a="../";for(let n=0;n<e;n++)a=`${a}../`;return a},Pe=e=>({street:[e.street.addressString,e.suite,e.secondaryInfo],city:e.city,state:e.state,country:e.country.selectedOption??"",countryCode:e.countryCode,postalCode:e.postalCode,latitude:e.street.addressValue?.locationLat,longitude:e.street.addressValue?.locationLng}),Le=m.div`
|
|
20
|
-
display: flex;
|
|
21
|
-
height: 100%;
|
|
22
|
-
width: 100%;
|
|
23
|
-
flex: 1 1 auto;
|
|
24
|
-
flex-direction: column;
|
|
25
|
-
align-items: center;
|
|
26
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
27
|
-
box-shadow: ${e=>`0px 2px ${r.sp1} ${e.theme.colors.dropShadowNormal}`};
|
|
28
|
-
`,Ne=x(function(e){const a=k(e),n=v(e),o=z(e),{companyName:s}=a;return{companyName:s,isDisabled:a.fetchState!=="Completed"?"disabled":void 0,magicLinkBankAccountDetails:n,mailingAddressDetails:o,magicLinkViewState:a}},function(e,a){const{navigate:n,location:o,vendorId:s,billId:l}=a;return{onFetchBankName:i=>{e(G(i))},onSaveHandler:i=>{j.trackBillPayMagicLinkSubmitBankAccountDetails(l),e(D(i,"us-domestic",s,l))},onWireDetailsUpdated:i=>{const{bankAccountSection:d}=i;e(T({data:d}))},onAddressClick:()=>{const i=o.pathname.replace("us-domestic","address"),d=H(o.state?.pathnameStackToGoBack,o.pathname);n(i,{state:{pathnameStackToGoBack:d}})}}})(pe);function Ee(){const e=C(),a=y(),n=g(),{vendorId:o,billId:s}=S();return o==null||s==null?t.jsx(f,{}):t.jsx(t.Fragment,{children:t.jsx(Le,{windowSize:n,children:t.jsx(Ne,{location:a,navigate:e,vendorId:o,billId:s})})})}const Fe=m.div`
|
|
29
|
-
display: flex;
|
|
30
|
-
height: 100%;
|
|
31
|
-
width: 100%;
|
|
32
|
-
flex: 1 1 auto;
|
|
33
|
-
flex-direction: column;
|
|
34
|
-
align-items: center;
|
|
35
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
36
|
-
box-shadow: ${e=>`0px 2px ${r.sp1} ${e.theme.colors.dropShadowNormal}`};
|
|
37
|
-
`,Te=x(function(e){const a=k(e),n=v(e),o=z(e),{companyName:s}=a;return{companyName:s,isDisabled:a.fetchState!=="Completed"?"disabled":void 0,magicLinkBankAccountDetails:n,mailingAddressDetails:o,magicLinkViewState:a}},function(e,a){const{navigate:n,location:o,vendorId:s,billId:l}=a;return{onFetchBankNameBySwift:i=>{e(ie(i))},onSaveHandler:i=>{j.trackBillPayMagicLinkSubmitBankAccountDetails(l),e(D(i,"international",s,l,a.isLocalCurrencyEnabled))},onBankDetailsUpdated:i=>{const{internationalWireSwiftAccountSection:d}=i;e(se({data:d}))},onAddressClick:()=>{const i=o.pathname.replace("international","address"),d=H(o.state?.pathnameStackToGoBack,o.pathname);n(i,{state:{pathnameStackToGoBack:d}})}}})(xe);function Ge(){const e=C(),a=y(),n=g(),{vendorId:o,billId:s}=S(),{useFeatureGate:l}=ue(),{isFeatureEnabled:i}=l(he.isBillPayLocalCurrencyFeatureEnabled);return o==null||s==null?t.jsx(f,{}):t.jsx(Fe,{windowSize:n,children:t.jsx(Te,{location:a,navigate:e,vendorId:o,billId:s,isLocalCurrencyEnabled:i})})}const Je={containerWidth:new je(100,58)},He=m(ke)`
|
|
38
|
-
width: ${r.sp4};
|
|
39
|
-
height: ${r.sp4};
|
|
40
|
-
margin-bottom: ${r.sp3};
|
|
41
|
-
margin-top: ${r.sp3};
|
|
42
|
-
margin-left: ${r.sp8};
|
|
43
|
-
cursor: pointer;
|
|
44
|
-
position: absolute;
|
|
45
|
-
color: ${e=>e.theme.colors.brandColorJade};
|
|
46
|
-
`,Me=m.div`
|
|
47
|
-
display: flex;
|
|
48
|
-
height: 100vh;
|
|
49
|
-
flex-direction: ${e=>e.windowSize==="small"?"column":"row"};
|
|
50
|
-
width: 100vw;
|
|
51
|
-
overflow-y: scroll;
|
|
52
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
53
|
-
`,Ve=m.div`
|
|
54
|
-
display: flex;
|
|
55
|
-
flex-direction: ${e=>e.windowSize==="small"?"column":"row"};
|
|
56
|
-
flex-direction: column;
|
|
57
|
-
width: ${e=>`${Je.containerWidth.value(e.windowSize)}%`};
|
|
58
|
-
${e=>e.windowSize!=="small"?"overflow: auto;":""}
|
|
59
|
-
box-shadow: ${e=>`0px 2px ${r.sp1} ${e.theme.colors.dropShadowNormal}`};
|
|
60
|
-
padding-top: ${e=>e.windowSize!=="small"?r.sp2:"0px"};
|
|
61
|
-
`,We=m.div`
|
|
62
|
-
display: flex;
|
|
63
|
-
flex-direction: column;
|
|
64
|
-
align-items: center;
|
|
65
|
-
justify-content: center;
|
|
66
|
-
padding: ${e=>e.windowSize==="small"?r.sp3:`62px ${r.sp6} ${r.sp9} ${r.sp8}`};
|
|
67
|
-
height: ${e=>e.windowSize==="small"?"490px":"auto"};
|
|
68
|
-
overflow: ${e=>e.windowSize==="small"?"unset":"hidden"};
|
|
69
|
-
width: ${e=>e.windowSize=="small"?"auto":"42%"};
|
|
70
|
-
background-color: ${e=>e.windowSize==="small"?e.theme.colors.grey4:e.theme.colors.background};
|
|
71
|
-
margin-top: ${e=>e.windowSize==="small"?e.isAddressPage?"0px":"186px":"unset"};
|
|
72
|
-
`,_e=x(function(e,a){return{file:a.file,type:a.type}})(ve);function h({appContent:e}){const a=ee(),n=y(),{tenantEmailDomain:o,vendorId:s,billId:l}=S(),[i]=te(),d=i.get("token"),M=n.pathname.includes("address"),w=g(),V=ge(),A=fe(),b=we(),W=()=>{V.toggle()},_=E(u=>k(u)),K=E(u=>v(u)),{authParams:U,fetchState:c,billAttachment:q,billFetchState:B,companyName:O,currencySymbol:R,amount:Z}=_,{tenantId:P,userId:L,sessionId:N}=U,{fetchState:Q,internationalBankAccountCreateStatus:X}=K;return $.useEffect(()=>{I()},[]),$.useEffect(()=>{b&&c==="Not-Started"&&s!=null&&o!=null&&d!=null&&a(le(s,o,d))},[b,c,s,o,d,a]),$.useEffect(()=>{b&&c==="Completed"&&(I(L,N,P),l!=null&&a(re(l)))},[c,b,L,N,P,l,a]),c==="Error"?t.jsx(f,{}):Q==="Completed"||X.fetchState==="Completed"?(I(),t.jsx(ae,{to:"../../../../../../../bank/account/save/success",replace:!0,relative:"path"})):c==="In-Progress"?t.jsx(be,{fetchState:c,style:{height:"100vh",backgroundColor:A.colors.grey5,boxShadow:`0px 2px ${r.sp1} ${A.colors.dropShadowNormal}`}}):t.jsxs(t.Fragment,{children:[c==="Completed"&&B==="Completed"&&t.jsx(Se,{analytics:j,onLoad:u=>(Y=>Y.trackBillPayMagicLinkPageLoad(o??"",s??"",O,l??"",Ke(n.pathname),R,Z))(u)}),t.jsxs(Me,{windowSize:w,children:[w!=="small"?t.jsx(He,{onClick:W}):null,t.jsx(We,{windowSize:w,isAddressPage:M,children:B==="In-Progress"?t.jsx(ye,{size:"ExtraLarge",start:!0}):t.jsx(_e,{file:q,type:"bill"})}),t.jsx(Ve,{windowSize:w,children:e})]})]})}const Ke=e=>`${e.split("/").at(-2)}_${e.split("/").at(-1)}`;function Ue(){return t.jsx(Ie,{})}function dt(){return t.jsxs(ne,{children:[t.jsx(p,{path:"bank/account/save/success",element:t.jsx(Ue,{})}),t.jsx(p,{path:":tenantEmailDomain/vendor/:vendorId/bill/:billId/ach/standard",element:t.jsx(h,{appContent:t.jsx(F,{})})}),t.jsx(p,{path:":tenantEmailDomain/vendor/:vendorId/bill/:billId/ach/same-day",element:t.jsx(h,{appContent:t.jsx(F,{})})}),t.jsx(p,{path:":tenantEmailDomain/vendor/:vendorId/bill/:billId/wire/address",element:t.jsx(h,{appContent:t.jsx(Ae,{isSubPage:!0})})}),t.jsx(p,{path:":tenantEmailDomain/vendor/:vendorId/bill/:billId/wire/us-domestic",element:t.jsx(h,{appContent:t.jsx(Ee,{})})}),t.jsx(p,{path:":tenantEmailDomain/vendor/:vendorId/bill/:billId/wire/international",element:t.jsx(h,{appContent:t.jsx(Ge,{})})}),t.jsx(p,{path:"*",element:t.jsx(f,{})})]})}export{dt as default};
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import{j as u}from"./liveblocks-DIG_sQTS.js";import{a as f}from"./sentry-DeeuWfnQ.js";import{u as U,g as w,h as _,s as J,j as l,N as T}from"./core-BQD7Nh1h.js";import{z as r,h as P,D as A,d as M,c as V,e as N,w as R,R as W,g as $}from"./index-NqZwiQK9.js";import{eP as q,Jo as B,Jy as G,Jp as H,eW as K,fn as Q,Ju as X,fL as Y,cT as Z,Jz as ee,JA as te}from"./zeni-epic-state-DPMNRP9z.js";import{n as ne}from"./mui-BTlbyoml.js";import{u as se}from"./useDeviceId-DVkU6ZvZ.js";import{f as ae}from"./analyticsHelper-DfvTrPlk.js";import{t as ie}from"./getLocaleForTenant-D4clEihj.js";import"./recharts-DvL3rz6g.js";import"./analytics-BwaA5sD9.js";import"./plaid-q_a4iNLa.js";import"./dnd-DkRdAB95.js";import"./stripe-DMRn4zHo.js";import"./lottie-BzitVa6X.js";import"./lexical-BChaWXti.js";import"./pdf-C5Pt0V8d.js";import"./utils-BQSiJMCN.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]="4fc9674c-dcca-4588-b8f7-d92b9cf1e317",t._sentryDebugIdIdentifier="sentry-dbid-4fc9674c-dcca-4588-b8f7-d92b9cf1e317")}catch{}})();const z=(t,a)=>t!=null&&t.length>0&&a==="magic_links";function ze(){const t=U(),a=w(),m=_(),[y]=J(),n=y.get("token"),p=y.get("stytch_token_type"),g=r.getMagicLinkCodeVerifier(),i=se(),{otpChallenge:c,twoFAPhoneNumber:D,magicLinkEmail:d,verifyDeviceFetchState:x,resendVerifyDeviceOTPFetchState:C}=l(e=>e.tenantState),S=l(e=>e.tenantState.fetchState),k=l(e=>e.tenantState.activeTenantFetchState.fetchState),h=l(e=>e.tenantState.signInState),I=l(e=>e.tenantState.magicLinkSignInFetchState.fetchState),s=l(e=>e.tenantState.loggedInUser),o=l(e=>q(e)),b=l(e=>B(e)),E=r.getSignedInUser(),v=P().mode;f.useEffect(()=>{s?.zeniSessionId==null&&n!=null&&z(n,p)&&i!=null&&g!=null&&(r.saveMagicLinkTriggered(n),t(G(n,i,g)))},[n,p,t,i,g,s?.zeniSessionId]),f.useEffect(()=>{h!=="In-Progress"||S!=="Completed"&&k!=="Completed"||s?.zeniSessionId==null||o==null||(n!=null&&r.saveLastUsedMagicLinkToken(n),r.saveSignedInUserWithSession(s,s.zeniSessionId),r.saveSignedInUserTenants(H(b.tenantsInOrder),s.zeniSessionId),K(s.userId,s.zeniSessionId,o.tenantId),t(Q(o.tenantId)),r.saveActiveTenantDomainForUser(o.tenantEmailDomain),t(X("Completed")),A.updateAppLocaleID(ie(o)),ae(s,o,v,void 0,b.tenantsInOrder),Y().then(()=>{const e=$();e!=null&&M(e)}),setTimeout(()=>{V.trackLogin(N.Event.loginSuccess,"email",Z(o.productSettings))},2e3))},[h,S,k,s,o,b,v,a.state,t]);const j=f.useCallback(()=>{m("/signin/auth")},[m]),F=f.useCallback(()=>{i!=null&&c!=null&&d!=null&&t(ee(i,d,c))},[i,c,t,d]),O=f.useCallback(e=>{i!=null&&n!=null&&d!=null&&c!=null&&t(te(e,i,d,c))},[i,n,t,d,c]);if(I==="Completed"&&c!=null)return u.jsx(R,{phoneNumber:D,verifyOtpFetchState:x.fetchState,resendVerifyDeviceOTPFetchState:C,onResendOtp:F,onVerifyOtp:O,onCancelVerifyDevice:j});if(h==="In-Progress"&&S==="Completed"&&s?.zeniSessionId!=null&&o!=null||E!=null){const e=a.state?.origin??"/";return u.jsx(T,{to:e,state:{...a.state,origin:""}})}if(!z(n,p)||g==null||I==="Error"){const e=a.state?.origin??"/",L=n!=null&&r.getLastUsedMagicLinkToken()===n;return u.jsx(T,{to:e,state:{...a.state,origin:"",magicLinkAlreadyUsed:L,magicLinkExpired:!L&&(r.isMagicLinkTriggered(n??"")||I==="Error"&&s?.zeniSessionId==null)}})}return u.jsx(oe,{"data-testid":"smooth-loader",children:u.jsx(W,{size:"ExtraLarge",start:!0})})}const oe=ne.div`
|
|
2
|
-
position: fixed;
|
|
3
|
-
top: 0;
|
|
4
|
-
left: 0;
|
|
5
|
-
right: 0;
|
|
6
|
-
bottom: 0;
|
|
7
|
-
display: flex;
|
|
8
|
-
align-items: center;
|
|
9
|
-
justify-content: center;
|
|
10
|
-
z-index: 9999;
|
|
11
|
-
background-color: ${t=>t.theme.colors.background};
|
|
12
|
-
`;export{ze as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as r}from"./liveblocks-DIG_sQTS.js";import{h as n,n as e}from"./core-BQD7Nh1h.js";import{H as i}from"./index-NqZwiQK9.js";import"./mui-BTlbyoml.js";import"./sentry-DeeuWfnQ.js";import"./zeni-epic-state-DPMNRP9z.js";import"./recharts-DvL3rz6g.js";import"./analytics-BwaA5sD9.js";import"./plaid-q_a4iNLa.js";import"./dnd-DkRdAB95.js";import"./stripe-DMRn4zHo.js";import"./lottie-BzitVa6X.js";import"./lexical-BChaWXti.js";import"./pdf-C5Pt0V8d.js";import"./utils-BQSiJMCN.js";(function(){try{var o=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new o.Error().stack;t&&(o._sentryDebugIds=o._sentryDebugIds||{},o._sentryDebugIds[t]="0ab14885-0bd8-4d23-8ea3-76b5f5ab5fbf",o._sentryDebugIdIdentifier="sentry-dbid-0ab14885-0bd8-4d23-8ea3-76b5f5ab5fbf")}catch{}})();const a=e(null,function(o,t){return{onGoBack:()=>{t.navigate(-1)},onGoHome:()=>{t.navigate("/")}}})(i);function _(){const o=n();return r.jsx(a,{navigate:o})}export{_ as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as m}from"./liveblocks-DIG_sQTS.js";import{a as r}from"./sentry-DeeuWfnQ.js";import{u as T,g as A,j as o,N as J}from"./core-BQD7Nh1h.js";import{JN as j,eP as C,f7 as R,JO as x,JP as z,JQ as D,JR as M,mW as N,IJ as L}from"./zeni-epic-state-DPMNRP9z.js";import{z as h,F as I}from"./index-NqZwiQK9.js";import"./mui-BTlbyoml.js";import"./recharts-DvL3rz6g.js";import"./analytics-BwaA5sD9.js";import"./plaid-q_a4iNLa.js";import"./dnd-DkRdAB95.js";import"./stripe-DMRn4zHo.js";import"./lottie-BzitVa6X.js";import"./lexical-BChaWXti.js";import"./pdf-C5Pt0V8d.js";import"./utils-BQSiJMCN.js";(function(){try{var n=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},s=new n.Error().stack;s&&(n._sentryDebugIds=n._sentryDebugIds||{},n._sentryDebugIds[s]="8c1d474c-ec74-412c-af6c-933e247d919f",n._sentryDebugIdIdentifier="sentry-dbid-8c1d474c-ec74-412c-af6c-933e247d919f")}catch{}})();function ee(){const n=T(),s=A(),{params:t,error:i}=r.useMemo(()=>j(s.search),[s.search]),w=r.useMemo(()=>new URLSearchParams(s.search).get("client_name")??t?.clientId??"Unknown Application",[s.search,t]),f=h.isSignedIn(),a=h.getSignedInUser(),p=o(e=>C(e)),l=o(e=>R(e)),c=o(e=>e.tenantState.fetchState),y=o(x),v=o(z),d=o(D),[S,E]=r.useState(null),[b,_]=r.useState(null);r.useEffect(()=>{document.querySelector("#app-shell-loader")?.remove()},[]),r.useEffect(()=>()=>{n(M())},[n,s.search]),r.useEffect(()=>{i!=null&&console.warn("[OAuthConsent] invalid params:",i)},[i]);const g=r.useRef(!1);r.useEffect(()=>{f&&a!=null&&!g.current&&(c!=="Not-Started"&&c!=="Error"||(g.current=!0,n(N(a.userId,a.zeniSessionId??void 0))))},[f,a,c,n]),r.useEffect(()=>{d!=null&&d!==""&&(window.location.href=d)},[d]);const U=r.useMemo(()=>{if(p?.tenantId!=null)return p.tenantId;const e=h.getActiveTenantForUser()?.tenantId;return e!=null&&l.some(P=>P.tenantId===e)?e:l.length===1?l[0].tenantId:null},[p?.tenantId,l]),u=S??U;return i!=null?m.jsx(I,{variant:"invalid_params",paramsError:i}):f?m.jsx(I,{variant:"signed_in",clientName:w,userEmail:a?.userEmail,isInitializing:c!=="Completed",tenants:l,selectedTenantId:u,onSelectTenant:E,approveError:b??v,isApproving:y==="In-Progress",showAllowButton:u!=null,onApprove:()=>{t!=null&&a!=null&&u!=null&&n(L(a.userId,a.zeniSessionId??void 0,u,t.clientId,t.redirectUri,t.codeChallenge,t.codeChallengeMethod,t.state,t.responseType))},onDeny:()=>{if(t!=null)try{const e=new URL(t.redirectUri);e.searchParams.set("error","access_denied"),e.searchParams.set("error_description","The user denied the request"),e.searchParams.set("state",t.state),window.location.href=e.toString()}catch{_("Unable to deny: redirect_uri is not a valid URL. Close this window or contact support.")}}}):m.jsx(J,{to:"/signin/auth",state:{origin:s.pathname+s.search},replace:!0})}export{ee as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as n}from"./liveblocks-DIG_sQTS.js";import{h as K,u as z,g as Z,i as H,j as d,n as J,o as Q,p as I}from"./core-BQD7Nh1h.js";import{eP as U,qR as R,qp as X,Kj as v,qk as T,bt as ee,bn as ae,bT as te,ql as se,Kk as oe,K5 as C,dE as re,ul as ne,Kl as ce,uI as ie,e_ as le,eY as de}from"./zeni-epic-state-DPMNRP9z.js";import{z as me,V as fe,Y as pe,k as ue,v as q,I as M,x as he,c as $,ao as ge,m as Fe}from"./index-NqZwiQK9.js";import"./mui-BTlbyoml.js";import be from"./NotFoundScreen-AUmyqBev.js";import{F as Ie}from"./FeaturePreviewScreen-CF3V2uH8.js";import{a as g}from"./sentry-DeeuWfnQ.js";import{u as Ce}from"./useAskAiCfoHostNavButtonProps-DFP8Wx8F.js";import{u as Te}from"./useInitialThreadRequest-D6gn8nP9.js";import{t as Se}from"./routePaths-Bn28lFcN.js";import{M as ye}from"./MobileAppDrawer-C0O6RwlS.js";import"./recharts-DvL3rz6g.js";import"./analytics-BwaA5sD9.js";import"./plaid-q_a4iNLa.js";import"./dnd-DkRdAB95.js";import"./stripe-DMRn4zHo.js";import"./lottie-BzitVa6X.js";import"./lexical-BChaWXti.js";import"./pdf-C5Pt0V8d.js";import"./utils-BQSiJMCN.js";(function(){try{var s=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},e=new s.Error().stack;e&&(s._sentryDebugIds=s._sentryDebugIds||{},s._sentryDebugIds[e]="9bcbf007-514c-409c-ac5e-0e1743395d2a",s._sentryDebugIdIdentifier="sentry-dbid-9bcbf007-514c-409c-ac5e-0e1743395d2a")}catch{}})();const S=(s,e,a,o)=>{if(s!=e){const r=o??"";s!=null&&s.length>0?a(`../${e}${r}`,{replace:!0}):a(`${e}${r}`,{replace:!0})}},ke=J(function(s){const e=oe(s),a={},o=e.pandLReportWithForecast.uiState.nodeCollapseState;return Object.keys(o).forEach(r=>{a[r]=o[r]===!1}),{selectedTimeframe:e.selectedTimeframe,isForecastVsActualOn:e.isForecastVsActualOn,compareMode:e.compareMode,forecastList:e.forecastList,selectedForecast:e.selectedForecast,pandLreport:e.pandLReportWithForecast,scrollPosition:e.pandLReportWithForecast.uiState.scrollPosition,nodeOpenStatus:a,type:"name+balances_forecast",analytics:$}},function(s,e){return{onForecastSelectionChanged:(a,o)=>{s(v(a,o)),e.isPandLReportFetched(a)||s(T(a)),S(e.forecastIdFromUrlPath,a,e.navigate)},onTimeframeChanged:a=>{s(ie(a))},onForecastVsActualsCompareToggle:a=>{s(ce(a)),s(C({forecastId:e.forecastIdFromUrlPath,scrollPosition:{scrollLeft:0,scrollTop:0}}))},onCompareModeChanged:a=>{s(ne(e.firstMonthOfFY,a,0,[]))},onAccountBalanceClick:e.hasTransactionAccess!==!0?void 0:(a,o)=>{let r,c;const p=a.accountName===""?a.accountDescription:a.accountName;if(o.balanceTimeFrame==="month"||o.balanceTimeFrame==="quarter"?(r=o.balanceTimeFrame,c=re(o)):o.balanceTimeFrame==="year"?(r="quarter",c={startDate:o.endDate.startOf("quarter"),endDate:o.endDate}):console.error(`timeframe ${o.balanceTimeFrame} is not supported`),c!=null&&r!=null){const m=Se(e.tenantEmailDomain,a.accountId,a.accountType,p,r,c),u=Fe(e.location.state?.pathnameStackToGoBack,e.location.pathname);e.navigate(m,{state:{pathnameStackToGoBack:u,referrer:"Forecast"}})}},onNodeCollapseToggled:(a,o)=>{s(C({forecastId:e.forecastIdFromUrlPath,nodeCollapseState:{nodeId:a,isCollapsed:o===!1}}))},onTableScroll:a=>{s(C({forecastId:e.forecastIdFromUrlPath,scrollPosition:a}))},onBackClick:()=>{e.navigate("../../")}}})(ge);function O(){const s=K(),e=z(),a=Z(),{forecastId:o,tenantEmailDomain:r}=H(),[c,p]=g.useState(!1),[m,u]=g.useState(!1),h=me.getSignedInUser(),y=d(t=>U(t)),w=y.company?.companyInfo.firstMonthOfFY??1,i=d(t=>R(t.forecastState,t.forecastListState)),l=d(t=>t.forecastListState.fetchState==="Completed"),k=d(t=>t.profitAndLossState),x=d(t=>t.reportUIOptionsState.selectedForecast),A=t=>k.pandLByForecastID[t]!=null&&se(t,k).reducedAllFetchState.fetchState==="Completed",{areTenantIdsInSync:F}=fe();pe({isDataReady:l});const{isAiCfoAccessEnabled:Y,onAskAiCfoClick:_}=Ce({mobileExploreReferrer:"Forecast"});g.useEffect(()=>{if(!c&&F)p(!0),l||e(X());else if(l&&!m){u(!0);const t=((f,L,P)=>L!=null?f.forecasts.findIndex(b=>b.id===L):P!=null?f.forecasts.findIndex(b=>b.id===P):f.forecasts.length>0?0:-1)(i,o,x?.id);t===-1&&o!=null?s("page-not-found",{replace:!0}):t!==-1&&t!=x?.index?(e(v(i.forecasts[t].id,t)),S(o,i.forecasts[t].id,s,a.search)):o==null&&t!==-1&&S(void 0,i.forecasts[t].id,s,a.search),t!==-1&&!A(i.forecasts[t].id)&&F&&e(T(i.forecasts[t].id))}},[c,p,e,l,i,m,u,R,T,F]);const D=ue(),B=D?.loggedInUserRole!=null&&ee(D.loggedInUserRole),{useFeatureGate:N}=q(),{isFeatureEnabled:j}=N(M.isReportsCommentingEnabled),V=Te(j?y?.companyId:void 0,{clearParams:l&&m}),[W,G]=g.useState(!1),E=t=>{G(t)};return n.jsxs(n.Fragment,{children:[l?n.jsx(he,{analytics:$,onLoad:t=>(f=>f.trackForecast())(t)}):null,n.jsx(ye,{isAppContentDrawerOpen:W,handleDrawerToggle:E}),n.jsx(ke,{firstMonthOfFY:w,tenantEmailDomain:r,forecastIdFromUrlPath:o,navigate:s,location:a,isPandLReportFetched:A,meetingUrl:te(`https://meetings.hubspot.com/svitlana-grankovska?firstname=${h?.firstName}&lastname=${h?.lastName}&email=${h?.userEmail}`),hasTransactionAccess:B,isAiCfoAccessEnabled:Y,onAskAiCfoClick:_,isReportsCommentingEnabled:j,isZeniUser:ae(h),initialOpenThreadRequest:V,onClickMenuIcon:()=>{E(!0)}})]})}function Ge(){const s=d(c=>U(c)),{useFeatureGate:e}=q(),{isFeatureEnabled:a}=e(M.isDebitCardFeatureEnabled),o=le(a,s),r=de(s);return o===!0||r===!0?n.jsx(Ie,{}):n.jsxs(Q,{children:[n.jsx(I,{path:"/",element:n.jsx(O,{})}),n.jsx(I,{path:"/:forecastId",element:n.jsx(O,{})}),n.jsx(I,{path:"/:forecastId/*",element:n.jsx(be,{})})]})}export{Ge as PandLWithForecastRoutes,Ge as default};
|
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import{j as s}from"./liveblocks-DIG_sQTS.js";import{Ke as te,eP as J,jG as H,e_ as Q,eY as ne,HG as q,JU as oe,tr as Ee,Kf as N,tf as ke,tA as Ie,tu as ie,tj as re,ty as Pe,tv as je,Kg as le,v7 as ve,Kh as Le,fB as Te,Ki as K,to as de,tm as ce,tD as Fe,c2 as Ae}from"./zeni-epic-state-DPMNRP9z.js";import{J as pe,v as X,I as E,z,a9 as ue,C as me,ak as ge,al as Re,A as he,o as R,E as fe,D as Ce,am as Oe,V as Ve,Y as Ue,x as Be,c as be,e as Ze,m as $e,an as Ke,k as _e}from"./index-NqZwiQK9.js";import{D as ye,n as M,S as Se}from"./mui-BTlbyoml.js";import ae from"./NotFoundScreen-AUmyqBev.js";import{a as r}from"./sentry-DeeuWfnQ.js";import{u as ee,i as Ge,j as m,h as He,g as ze,n as Me,o as se,p as $}from"./core-BQD7Nh1h.js";import{u as We}from"./useAskAiCfoHostNavButtonProps-DFP8Wx8F.js";import{M as Ye}from"./MobileAppDrawer-C0O6RwlS.js";import"./recharts-DvL3rz6g.js";import"./analytics-BwaA5sD9.js";import"./plaid-q_a4iNLa.js";import"./dnd-DkRdAB95.js";import"./stripe-DMRn4zHo.js";import"./lottie-BzitVa6X.js";import"./lexical-BChaWXti.js";import"./pdf-C5Pt0V8d.js";import"./utils-BQSiJMCN.js";(function(){try{var a=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new a.Error().stack;t&&(a._sentryDebugIds=a._sentryDebugIds||{},a._sentryDebugIds[t]="fbb534d1-f820-44ce-bf08-4d3c166084c0",a._sentryDebugIdIdentifier="sentry-dbid-fbb534d1-f820-44ce-bf08-4d3c166084c0")}catch{}})();const Ne={overlayWidth:new he(100,100,48)},_=Ce.getLocalizedStrings().peoplePage.invitePage,Je=({companyId:a,managersListView:t,companyPassportView:l,classListView:n,mode:g,isEditPeopleDrawerOpen:o,closeDrawerHandler:y})=>{const h=pe(),p=ee(),[O,V]=r.useState(!1),[I,S]=r.useState(!1),{userId:w}=Ge(),d=m(e=>te(e)),u=m(e=>J(e)),D=m(e=>H(e)),{useFeatureGate:f}=X(),{isFeatureEnabled:k}=f(E.isDebitCardFeatureEnabled),P=Q(k,u),L=ne(u),T=q(u),U=oe(u),B=!!u.company?.featuresActivationInfo?.isReimbursementFeatureEnabled,x=!P&&D&&n.fetchState!=="Completed"||t.fetchState!=="Completed"||l.fetchState!=="Completed"||a==null;if(z.getSignedInUser()==null)throw Error("Can't access invite people page without signing in...");const C=()=>{p(N()),y()},F=()=>{O===!0?S(!0):C()},Z=l.companyView?.controllers?.map(e=>e.user),{isFeatureEnabled:c}=f(E.isDepositAccountsFeatureEnabled),{isFeatureEnabled:j}=f(E.isChargeCardFeatureEnabled),v=ue(u,j,k),{isFeatureEnabled:A}=f(E.isTreasuryEnabled),b={peopleDetails:d,classList:n.classes,managersList:t.users,controllersList:Z,mode:g,isZeniTenant:T,isAccountingClassesEnabled:D,isReimbursementDisabled:B===!1,isZeniAccountsDisabled:c===!1,isChargeCardDisabled:v===!1,isTreasuryDisabled:A===!1,isLiteRoleDisabled:U===!1,isBankingOnlyTenant:P,isCardsOnlyTenant:L,onResetClick:C,onDeleteUser:e=>{p(re(e.userId,e.userRole.userRoleId))},onPeopleLocalDataUpdated:e=>{p(ie({peopleLocalData:e})),V(!0)},onSaveClick:()=>{p(g==="zeni_only"?ke(a):Ie(T))},onCloseClick:F,isLoading:x||d.person==null},i={onOkClick:()=>{S(!1),C()},onCancelClick:()=>{S(!1)}};return r.useEffect(()=>{x===!1&&w!=null&&p(Ee(w))},[x,w]),r.useEffect(()=>{d.updatePersonState.fetchState==="Completed"&&C()},[d.updatePersonState.fetchState]),s.jsx(ye,{anchor:"right",open:o,PaperProps:{style:{width:Ne.overlayWidth.valuePercentage(h),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:me.overlayDark,cursor:"pointer"}}},onClose:F,children:s.jsxs(Qe,{onClick:e=>e.stopPropagation(),children:[I===!0?s.jsx(ge,{titleComponent:s.jsx(we,{children:_.discardTitle}),descriptionComponent:s.jsx(De,{children:_.discardDescription}),primaryButtonText:_.discard,secondaryButtonText:_.no,action:i,isEditPopup:!0}):null,s.jsx(Re,{...b})]})})},Qe=M(Se)`
|
|
2
|
-
display: flex;
|
|
3
|
-
min-height: 100%;
|
|
4
|
-
flex-direction: column;
|
|
5
|
-
`,we=M(fe.H6Regular)`
|
|
6
|
-
margin-top: ${R.sp7};
|
|
7
|
-
padding-left: ${R.sp8};
|
|
8
|
-
padding-right: ${R.sp8};
|
|
9
|
-
color: ${a=>a.theme.colors.primary};
|
|
10
|
-
word-break: break-word;
|
|
11
|
-
`,De=M(fe.LargeRegularSp)`
|
|
12
|
-
color: ${a=>a.theme.colors.hero};
|
|
13
|
-
padding-left: ${R.sp8};
|
|
14
|
-
padding-right: ${R.sp8};
|
|
15
|
-
margin-bottom: 30px;
|
|
16
|
-
margin-top: ${R.sp4};
|
|
17
|
-
white-space: pre-line;
|
|
18
|
-
`,qe={overlayWidth:new he(100,100,48)},G=Ce.getLocalizedStrings().peoplePage.invitePage,Xe=({companyId:a,managersListView:t,companyPassportView:l,classListView:n,mode:g,isInvitePeopleDrawerOpen:o,closeDrawerHandler:y})=>{const h=pe(),p=ee(),[O,V]=r.useState(!1),[I,S]=r.useState(!1),w=m(i=>te(i)),d=m(i=>J(i)),u=m(i=>H(i)),{useFeatureGate:D}=X(),{isFeatureEnabled:f}=D(E.isDebitCardFeatureEnabled),k=Q(f,d),P=ne(d),L=q(d),T=oe(d),U=!!d.company?.featuresActivationInfo?.isReimbursementFeatureEnabled,B=!k&&u&&n.fetchState!=="Completed"||t.fetchState!=="Completed"||l.fetchState!=="Completed"||a==null;if(z.getSignedInUser()==null)throw Error("Can't access invite people page without signing in...");const x=()=>{y(),p(N())},C=()=>{O===!0?S(!0):x()},F={onOkClick:()=>{S(!1),x()},onCancelClick:()=>{S(!1)}},Z=l.companyView?.controllers.map(i=>i.user),{isFeatureEnabled:c}=D(E.isDepositAccountsFeatureEnabled),{isFeatureEnabled:j}=D(E.isChargeCardFeatureEnabled),v=ue(d,j,f),{isFeatureEnabled:A}=D(E.isTreasuryEnabled),b={classList:n.classes,managersList:t.users,controllersList:Z,mode:g,isZeniTenant:L,onPeopleLocalDataUpdated:i=>{p(ie({peopleLocalData:i})),V(!0)},onResetClick:x,onSaveClick:()=>{p(g==="zeni_only"?Pe(a):je())},onCloseClick:C,peopleDetails:w,isAccountingClassesEnabled:u,isReimbursementDisabled:U===!1,isLiteRoleDisabled:T===!1,isZeniAccountsDisabled:c===!1,isChargeCardDisabled:v===!1,isTreasuryDisabled:A===!1,isBankingOnlyTenant:k,isCardsOnlyTenant:P,isLoading:B};return r.useEffect(()=>{w.invitePersonState.fetchState==="Completed"&&(y(),p(N()))},[w.invitePersonState.fetchState]),s.jsx(ye,{anchor:"right",open:o,PaperProps:{style:{width:qe.overlayWidth.valuePercentage(h),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:me.overlayDark,cursor:"pointer"}}},onClose:C,children:s.jsxs(ea,{onClick:i=>i.stopPropagation(),children:[I===!0?s.jsx(ge,{titleComponent:s.jsx(we,{children:G.discardTitle}),descriptionComponent:s.jsx(De,{children:G.discardDescription}),primaryButtonText:G.discard,secondaryButtonText:G.no,action:F}):null,s.jsx(Oe,{...b})]})})},ea=M(Se)`
|
|
19
|
-
display: flex;
|
|
20
|
-
min-height: 100%;
|
|
21
|
-
flex-direction: column;
|
|
22
|
-
`,aa=Me(function(a,t){const l=le(a),n=z.getSignedInUser();return{data:l,loggedinUserId:n?.userId??"",isZeniTenant:t.isZeniTenant===!0,shouldFetchClasses:t.shouldFetchClasses,isZeniAdminUser:n?.userEmailDomain==="zeni.ai"&&t.isZeni===!0,isAccountingClassesEnabled:H(a),analytics:be}},function(a,t){const{navigate:l,companyId:n,shouldFetchClasses:g}=t;return{personAction:{onPersonDelete:(o,y)=>{a(re(o,y))},onResendInvite:o=>{a(Fe(o))},onReloadPeople:()=>{a(de()),a(ce(n,g))},onBackClick:()=>{l("../../")},onModeChange:o=>{a(K({mode:o,searchText:"",sortKey:"name",sortOrder:"ascending"}))},onSearchTextChanged:o=>{a(K({searchText:o}))}}}})(Ke);function Y({isInvitePeopleDrawerOpen:a,isEditPeopleDrawerOpen:t}){const l=He(),n=ee(),g=ze(),{areTenantIdsInSync:o}=Ve(),y=z.getSignedInUser(),h=m(e=>J(e)),{useFeatureGate:p}=X(),{isFeatureEnabled:O}=p(E.isDebitCardFeatureEnabled),V=m(e=>H(e)),I=!Q(O,h)&&V,S=q(h),w=h?.tenantId,{tenantEmailDomain:d}=h,[u,D]=r.useState(!1),[f,k]=r.useState(!1),[P,L]=r.useState(!1),[T,U]=r.useState("off"),[B,x]=r.useState(!1),C=e=>{x(e)},{isAiCfoAccessEnabled:F,onAskAiCfoClick:Z}=We({mobileExploreReferrer:"People"}),c=m(e=>le(e));Ue({isDataReady:c.fetchState==="Completed"});const j=m(e=>ve(e.classState,e.classListState)),v=m(e=>Le(e.userState,e.userRoleState,e.userListViewState,"manager")),A=m(e=>Te(e)),b=h?.companyId;r.useEffect(()=>{u&&T===c.uiState.mode||!o||(n(K({searchText:"",sortKey:"name",sortOrder:"ascending"})),U(c.uiState.mode),D(!0),n(de()))},[u,y,w,n,c.uiState.mode,o]),r.useEffect(()=>{b!=null&&o&&n(ce(b,I))},[b,I,o]),r.useEffect(()=>{k(a!=null&&a===!0),L(t!=null&&t===!0&&t)},[a,t]),r.useEffect(()=>{n(K({searchText:"",sortKey:"name",sortOrder:"ascending"}))},[]);const i=()=>{k(!1),L(!1),l("../")};return s.jsxs(s.Fragment,{children:[c.fetchState==="Completed"?s.jsx(Be,{analytics:be,onLoad:e=>e.trackPageLoaded(Ze.Event.members)}):null,f===!0?s.jsx(Xe,{closeDrawerHandler:i,isInvitePeopleDrawerOpen:f,managersListView:v,companyPassportView:A,classListView:j,companyId:b,mode:c.uiState.mode}):null,P===!0?s.jsx(Je,{closeDrawerHandler:i,isEditPeopleDrawerOpen:P,managersListView:v,companyPassportView:A,classListView:j,companyId:b,mode:c.uiState.mode}):null,s.jsx(Ye,{isAppContentDrawerOpen:B,handleDrawerToggle:C}),s.jsx(aa,{navigate:l,signedInUser:y,isZeni:h.isZeni,isZeniTenant:S,peopleUIState:c.uiState,companyId:b,shouldFetchClasses:I,classList:j,managersView:v,peopleView:c,onInvitePeopleClick:()=>{l("./new")},onColumnSortConfigChanged:(e,W)=>{n(K({sortKey:e,sortOrder:W}))},onRowClick:e=>{const W=`/${d}/people/${encodeURIComponent(e)}/edit`,xe=$e(g.state?.pathnameStackToGoBack,g.pathname);l(W,{state:{pathnameStackToGoBack:xe}})},onClickMenuIcon:()=>{C(!0)},isAiCfoAccessEnabled:F,onAskAiCfoClick:Z})]})}function Sa(){const a=_e();return Ae(a?.loggedInUserRole??[])?s.jsxs(se,{children:[s.jsx($,{path:"/",element:s.jsx(Y,{})}),s.jsx($,{path:"new",element:s.jsx(Y,{isInvitePeopleDrawerOpen:!0})}),s.jsx($,{path:":userId/edit",element:s.jsx(Y,{isEditPeopleDrawerOpen:!0})}),s.jsx($,{path:"*",element:s.jsx(ae,{})})]}):s.jsx(se,{children:s.jsx($,{path:"*",element:s.jsx(ae,{})})})}export{Sa as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as s}from"./liveblocks-DIG_sQTS.js";import E from"./NotFoundScreen-AUmyqBev.js";import{a as r}from"./sentry-DeeuWfnQ.js";import{h as _,g as P,j as p,i as v,u as M,N as U,n as z,o as B,p as h}from"./core-BQD7Nh1h.js";import{eP as O,PY as b,bo as F,bn as N,hn as V,gT as Y}from"./zeni-epic-state-DPMNRP9z.js";import{r as $,z as I,Y as q,cB as G}from"./index-NqZwiQK9.js";import"./mui-BTlbyoml.js";import{u as H}from"./useAskAiCfoHostNavButtonProps-DFP8Wx8F.js";import{M as J}from"./MobileAppDrawer-C0O6RwlS.js";import"./recharts-DvL3rz6g.js";import"./analytics-BwaA5sD9.js";import"./plaid-q_a4iNLa.js";import"./dnd-DkRdAB95.js";import"./stripe-DMRn4zHo.js";import"./lottie-BzitVa6X.js";import"./lexical-BChaWXti.js";import"./pdf-C5Pt0V8d.js";import"./utils-BQSiJMCN.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]="6066dbf7-e290-4722-acc4-5fa61feb8e81",e._sentryDebugIdIdentifier="sentry-dbid-6066dbf7-e290-4722-acc4-5fa61feb8e81")}catch{}})();const K=z(function(e){const t=I.getSignedInUser(),c=e.tenantState.currentTenantId,o={userId:t?.userId??"",sessionId:t?.zeniSessionId??"",tenantId:c??""},{aggregatedReportViewState:n}=b(e);return{authParams:o,isDisabled:!1,loggedInUser:t,aggregatedReport:n}},function(e,t){return{onBackClick:()=>{t.navigate("../../")},onClickMenuIcon:()=>{t.handleDrawerToggle(!0)}}})(G),L=()=>{const e=_(),t=P(),c=$(),o=p(a=>O(a)),{aggregatedReportViewState:n}=p(a=>b(a)),{tenantEmailDomain:m}=v(),u=M(),d=I.getSignedInUser();if(d==null)throw new Error("Can't access this page without signing in...");const f=r.useRef(!1),[w,S]=r.useState(!1),C=F(o?.userRole??[]),k=o?.userRole?.includes("bookkeeping_admin")??!1,x=N(d),y=C||k||x,l=r.useCallback((a,i,A)=>{u(V({fromMonth:a,toMonth:i,cacheOverride:A}))},[]);r.useEffect(()=>{n?.fetchState==="Completed"&&f.current&&(u(Y({messageSection:"data_refresh_update",messageText:"success",type:"success",showStatusIcon:!0})),f.current=!1)},[n?.fetchState]);const D=r.useCallback((a,i)=>{n!=null&&n?.fetchState==="In-Progress"||l(a,i,!0),f.current=!0},[n?.fetchState,l]),j=r.useCallback((a,i)=>{l(a,i,!1)},[l]),g=a=>{S(a)},{isAiCfoAccessEnabled:R,onAskAiCfoClick:T}=H({mobileExploreReferrer:"Performance"});return q({isDataReady:n?.fetchState==="Completed"}),y?s.jsxs(s.Fragment,{children:[s.jsx(J,{isAppContentDrawerOpen:w,handleDrawerToggle:g}),s.jsx(K,{navigate:e,location:t,themeState:c,currentTenant:o,signedInUser:d,tenantEmailDomain:m,onReload:D,onTimeRangeSelect:j,handleDrawerToggle:g,isAiCfoAccessEnabled:R,onAskAiCfoClick:T})]}):s.jsx(U,{to:`/${m}/dashboard`,replace:!0})};function ge(){return s.jsxs(B,{children:[s.jsx(h,{path:"*",element:s.jsx(L,{})}),s.jsx(h,{path:"*",element:s.jsx(E,{})})]})}export{ge as default};
|
|
@@ -1,5 +0,0 @@
|
|
|
1
|
-
import{j as s}from"./liveblocks-DIG_sQTS.js";import{a as o}from"./sentry-DeeuWfnQ.js";import{j as f,h as V,u as H,g as M,n as F}from"./core-BQD7Nh1h.js";import{h as N,J as W,z as R,b9 as _,A as J,V as U,Y as $,x as z,c as d,e as K,a7 as Y,ba as q}from"./index-NqZwiQK9.js";import{f2 as G,eP as Q,MJ as P,MK as X,ub as Z,u1 as g,f4 as ee,bO as re,u6 as ae,ML as ne}from"./zeni-epic-state-DPMNRP9z.js";import{D as te,e as se,n as oe,S as ie}from"./mui-BTlbyoml.js";import{u as de}from"./useAskAiCfoHostNavButtonProps-DFP8Wx8F.js";import{M as le}from"./MobileAppDrawer-C0O6RwlS.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},r=new e.Error().stack;r&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[r]="ddd4d11f-c321-4e7e-984f-f1cc5f5d06b5",e._sentryDebugIdIdentifier="sentry-dbid-ddd4d11f-c321-4e7e-984f-f1cc5f5d06b5")}catch{}})();const ce={overlayWidth:new J(100,100,30)},fe=({isReferralDrawerOpen:e,closeDrawerHandler:r})=>{const a=N(),n=W();if(R.getSignedInUser()==null)throw Error("Can't access How Referral works without signing in...");const i=()=>{r(!0)},u=f(l=>G(l));return s.jsx(te,{anchor:"right",open:e,PaperProps:{style:{width:ce.overlayWidth.valuePercentage(n),boxShadow:"none"}},slotProps:{backdrop:{style:{opacity:.75,backgroundColor:a.colors.black,cursor:"pointer"}}},onClose:()=>i(),children:s.jsx(se,{in:e,direction:"left",children:s.jsx(ue,{onClick:l=>l.stopPropagation(),children:s.jsx(_,{onDismissClick:i,rewardsPlan:u.rewardsPlan})})})})},ue=oe(ie)`
|
|
2
|
-
display: flex;
|
|
3
|
-
min-height: 100%;
|
|
4
|
-
flex-direction: column;
|
|
5
|
-
`,I="refer-and-earn-status-update",we=F(function(e){const r=P(e),a=e.referralViewState.rewardsPlanFetchState,n=re([r,a]);return{inviteList:r.invitations,uiState:r.uiState,pendingBonus:r.pendingBonus,earnedBonus:r.earnedBonus,pendingReferrals:r.pendingReferrals,fetchState:n.fetchState,rewardsPlan:r.rewardsPlan}},function(e,r){const{navigate:a}=r;return{onColumnSortConfigChanged:(n,i)=>{e(ne({sortOrder:i,sortkey:n}))},onInviteClick:()=>{d.trackRewardsPageClicked("invite via email"),a("../refer")},onHowItWorksClick:()=>{d.trackRewardsPageClicked("know more"),a("../how-it-works")},onResendInviteClick:n=>{d.trackRewardsPageClicked("resend invite"),e(ae(n))},onBackClick:()=>{a("../",{relative:"path"})},onReloadInvitees:()=>{e(g(!0))},onCopyReferralLink:()=>{d.trackRewardsPageClicked("copy referral link")},onClickRefer:()=>{d.trackRewardsPageClicked("refer")},onEventReceived:n=>{n===I&&e(g(!0,!0))}}})(Y(q));function ve({isReferralDrawerOpen:e}){const r=V(),a=H(),n=M(),[i,u]=o.useState(!1),[l,x]=o.useState(!1),[D,E]=o.useState(!1),[k,h]=o.useState(!1),w=R.getSignedInUser(),C=f(t=>Q(t)),m=f(t=>P(t)),b=m.fetchState,p=f(t=>t.referralViewState.rewardsPlanFetchState),y=X([m,p]),{areTenantIdsInSync:c}=U();o.useEffect(()=>{C?.rewardsLastViewedTime==null&&D===!1&&(a(Z()),E(!0))},[]),o.useEffect(()=>{!i&&b==="Not-Started"&&c&&(u(!0),a(g(!0)))},[b,a,c]),o.useEffect(()=>{!l&&p.fetchState==="Not-Started"&&c&&(x(!0),a(ee(!0)))},[p,a,c]),o.useEffect(()=>{h(e!=null&&e===!0)},[e]);const[j,A]=o.useState(!1),v=t=>{A(t)},{isAiCfoAccessEnabled:O,onAskAiCfoClick:B}=de({mobileExploreReferrer:"Rewards"});$({isDataReady:y===!0});const L={events:w?.userId!=null?[`private-encrypted-${w.userId}.${I}`]:[],eventCallback:(t,S,T)=>{T.onEventReceived(t)}};return s.jsxs(s.Fragment,{children:[y===!0?s.jsx(z,{analytics:d,onLoad:t=>(S=>{w!=null&&S.trackPageLoaded(K.Event.rewardsPageViewed)})(t)}):null,s.jsx(le,{isAppContentDrawerOpen:j,handleDrawerToggle:v}),k===!0?s.jsx(fe,{closeDrawerHandler:()=>{h(!1),r("..")},isReferralDrawerOpen:k}):null,s.jsx(we,{location:n,navigate:r,currentTenant:C,onClickMenuIcon:()=>{v(!0)},isAiCfoAccessEnabled:O,onAskAiCfoClick:B,...L})]})}export{ve as R};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as t}from"./liveblocks-DIG_sQTS.js";import x from"./NotFoundScreen-AUmyqBev.js";import{a as p}from"./sentry-DeeuWfnQ.js";import{h as C,g as I,u as D,j as u,N as A,n as E,o as k,p as c}from"./core-BQD7Nh1h.js";import{eP as T,ND as g,NT as S,D8 as V,Ch as _,D7 as m,C_ as N,O7 as U}from"./zeni-epic-state-DPMNRP9z.js";import{h as O,z as $,B,a7 as P,bQ as W,af as z}from"./index-NqZwiQK9.js";import"./mui-BTlbyoml.js";import{R as v}from"./ReimbursementApprovalRuleDetailScreen-DoAuMin4.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},r=new e.Error().stack;r&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[r]="b2f855a3-5abe-40c7-8e44-051b5112cd58",e._sentryDebugIdIdentifier="sentry-dbid-b2f855a3-5abe-40c7-8e44-051b5112cd58")}catch{}})();const d="reimbursement-approval-rule-update",Q=E(function(e){return{approvalView:g(e),remiSetupApproverViewUpdateData:S(e).remiSetupApproverViewUpdateData}},function(e,r){const{navigate:a,location:l}=r;return{onApprovalRulesEventReceived:s=>{s.endsWith(d)&&e(U(!1))},onBackClick:()=>{z(l)?a("../../"):a("../../../reimbursements/setup")},onDeleteRuleClick:s=>{e(N(s))},onEditRuleClick:s=>{s!=null?(e(m(s)),a(`./${s}/edit`)):(e(m()),a("./new"))}}})(P(W)),q=()=>{const e=C(),r=I(),a=D(),[l,s]=p.useState(!1),[f,y]=p.useState(!1),b=u(n=>n.remiSetupApproverViewState.fetchState),o=u(n=>T(n)),w=O(),i=u(n=>g(n)),h=u(n=>S(n).remiSetupApproverViewUpdateData);if(p.useEffect(()=>{h?.updateStatus.fetchState==="Completed"&&a(V())},[h]),p.useEffect(()=>{l||b!=="Not-Started"||(s(!0),a(_(!0)))},[l,b,a]),$.getSignedInUser()==null)throw Error("Can't access reimbursement approval without signing in...");p.useEffect(()=>{i.allApprovalRules.length===0&&i.fetchState==="Completed"&&(f||(y(!0),a(m())),e("./new"))},[f,i,a]);const j={events:o.companyId!=null?[`private-encrypted-${o.companyId}.${d}`]:[],eventCallback:(n,F,R)=>{n.endsWith(d)&&R.onApprovalRulesEventReceived(n)}};return o.companyReimbursementInfo?.info?.isReimbursementTOSAccepted===!1?t.jsx(A,{to:"../../promo"}):o.companyReimbursementInfo?.info?.isReimbursementTOSAccepted!==!0||i.fetchState!=="Completed"&&i.fetchState!=="Error"?t.jsx(B,{fetchState:"In-Progress",style:{backgroundColor:w.colors.grey5}}):t.jsx(Q,{currentTenant:o,location:r,navigate:e,...j})};function Z(){return t.jsxs(k,{children:[t.jsx(c,{path:"/",element:t.jsx(q,{})}),t.jsx(c,{path:"/new",element:t.jsx(v,{})}),t.jsx(c,{path:"/:approvalRuleId/edit",element:t.jsx(v,{})}),t.jsx(c,{path:"*",element:t.jsx(x,{})})]})}export{Z as R};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as a}from"./liveblocks-DIG_sQTS.js";import{v as w,z as j,aN as y,x as E,c as p,e as F,cL as L,I as P}from"./index-NqZwiQK9.js";import"./mui-BTlbyoml.js";import l from"./NotFoundScreen-AUmyqBev.js";import{a as f}from"./sentry-DeeuWfnQ.js";import{u as T,j as b,h as V,g as A,n as R,o as U,p as u}from"./core-BQD7Nh1h.js";import{eP as z,Qv as C,Ni as Q,Qw as v,ub as Y,f4 as G,Qx as O,u9 as q}from"./zeni-epic-state-DPMNRP9z.js";import{R as x}from"./ReferralListScreen-Dl9-tAZb.js";import"./recharts-DvL3rz6g.js";import"./analytics-BwaA5sD9.js";import"./plaid-q_a4iNLa.js";import"./dnd-DkRdAB95.js";import"./stripe-DMRn4zHo.js";import"./lottie-BzitVa6X.js";import"./lexical-BChaWXti.js";import"./pdf-C5Pt0V8d.js";import"./utils-BQSiJMCN.js";import"./useAskAiCfoHostNavButtonProps-DFP8Wx8F.js";import"./MobileAppDrawer-C0O6RwlS.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]="913c2fae-b3bf-4cc7-8a44-36d0eff3e1c9",e._sentryDebugIdIdentifier="sentry-dbid-913c2fae-b3bf-4cc7-8a44-36d0eff3e1c9")}catch{}})();const B=R(function(e,t){const n=C(e);return{inviteFormView:n.localData,submitStatus:n.saveStatus,userName:t.userName,rewardsPlan:n.rewardsPlan,companyLegalName:t.companyName}},function(e,t){const{navigate:n}=t,o=j.getSignedInUser();return{onDismissClick:()=>{e(v()),n("..")},onSendClick:()=>{if(o!=null){const s=[],r=[];t.inviteFormCompayData.forEach(c=>{s.push(c.companyName),r.push(c.emailIds[0])}),p.trackInviteEmailClicked("send",s,r,s.length)}e(q())},onUpdateInviteFormLocalData:s=>{e(O({localData:s}))},onSubmitSuccess:()=>{n("../../")},onCancelClick:()=>{o!=null&&p.trackInviteEmailClicked("cancel")}}})(L),H=()=>{const e=T(),[t,n]=f.useState(!1),[o,s]=f.useState(!1),r=b(i=>z(i)),c=V(),_=A(),{useDynamicConfig:g}=w(),d=j.getSignedInUser();if(d==null)throw Error("Can't access invite referral screen without signing in...");const m=b(i=>C(i)),N=d?.firstName!=null?d.firstName:"User",{configValue:h}=g(y.zeniCardsConfig),{configValue:k}=g(y.zeniAccountsConfig),D=Q(k);f.useEffect(()=>{e(v()),r?.rewardsLastViewedTime==null&&o===!1&&(e(Y()),s(!0))},[]),f.useEffect(()=>{t||m.fetchState!=="Not-Started"||(n(!0),e(G(!0)))},[m.fetchState,e]);const I=r.company?.companyInfo.companyLegalName??r.companyName;return a.jsxs(a.Fragment,{children:[m.fetchState==="Completed"?a.jsx(E,{analytics:p,onLoad:i=>(S=>S.trackPageLoaded(F.Event.inviteEmailViewed))(i)}):null,a.jsx(B,{navigate:c,location:_,currentTenant:r,companyName:I,userName:N,inviteFormCompayData:m.localData,chargeCardCashbackRatePerTransaction:h.charge_card_cashback_rate_per_transaction!=null?h.charge_card_cashback_rate_per_transaction:.0175,maxAnnualPercentageYield:D.maxAnnualPercentageYield})]})};function ue(){const{useFeatureGate:e}=w(),{isFeatureEnabled:t}=e(P.isReferralFeatureEnabled);return a.jsxs(U,{children:[a.jsx(u,{path:"/",element:t?a.jsx(x,{}):a.jsx(l,{})}),a.jsx(u,{path:"how-it-works",element:t?a.jsx(x,{isReferralDrawerOpen:!0}):a.jsx(l,{})}),a.jsx(u,{path:"refer/*",element:t?a.jsx(H,{}):a.jsx(l,{})}),a.jsx(u,{path:"*",element:a.jsx(l,{})})]})}export{ue as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as u}from"./liveblocks-DIG_sQTS.js";import{a as f,b as T,q as A}from"./sentry-DeeuWfnQ.js";import{u as D,h as z,j as c,g as J,N as M,n as O}from"./core-BQD7Nh1h.js";import{u as P,z as s,h as j,c as E,D as F,d as _,e as B,f as N,g as V,n as W,i as v}from"./index-NqZwiQK9.js";import{eP as $,Jo as q,Jp as G,eW as H,fn as K,Ju as Q,fL as R,cT as X,Jv as x,Jw as Y,Jx as Z,bT as y}from"./zeni-epic-state-DPMNRP9z.js";import"./mui-BTlbyoml.js";import{u as ee}from"./useDeviceId-DVkU6ZvZ.js";import{f as te}from"./analyticsHelper-DfvTrPlk.js";import{t as ne}from"./getLocaleForTenant-D4clEihj.js";import"./recharts-DvL3rz6g.js";import"./analytics-BwaA5sD9.js";import"./plaid-q_a4iNLa.js";import"./dnd-DkRdAB95.js";import"./stripe-DMRn4zHo.js";import"./lottie-BzitVa6X.js";import"./lexical-BChaWXti.js";import"./pdf-C5Pt0V8d.js";import"./utils-BQSiJMCN.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},i=new t.Error().stack;i&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[i]="2e0e9471-1cc4-4d1d-9c2e-755504ca278d",t._sentryDebugIdIdentifier="sentry-dbid-2e0e9471-1cc4-4d1d-9c2e-755504ca278d")}catch{}})();const ie=O(function(t,i){const d=t.tenantState.fetchState,g=t.tenantState.sendEmailMagicLinkFetchState,{magicLinkExpired:n,magicLinkAlreadyUsed:a,magicLinkExpiredEmail:l}=i;return{googleClientId:v.googleClientId,microsoftClientId:v.microsoftClientId,signInError:t.tenantState.error?.error,fetchState:d,sendMagicLinkStatus:g,magicLinkExpired:n,magicLinkAlreadyUsed:a,magicLinkExpiredEmail:l}},function(t,i){const{location:d,navigate:g}=i;return console.warn(JSON.stringify(window.location)),{onOAuthError:(n,a)=>{A({message:`OAuth error from provider ${a} with error ${n}`,level:"error",tags:{authProvider:a,errorType:"zeni.login.error"},extra:{error:n,windowLocation:window.location.href}})},onOAuthSuccess:(n,a)=>{const l=a==="google"?window.location.origin:window.location.origin+window.location.pathname;t(Z({authCode:n,oauthProvider:a,appType:"web",redirectUri:y(l),sourceUri:y(d.state!=null?d.state.origin:"")}))},getSignedInUser:()=>s.getSignedInUser(),onSignedInCallback:()=>{const n=d.state?.origin;n&&n!=="/"?g(n,{replace:!0}):window.open(window.location.origin,"_self")},sendMagicLink:n=>{const{deviceId:a}=i;a!=null&&(s.saveMagicLinkEmail(n),t(Y(n,a)))},clearSignInError:()=>{t(x())}}})(W),ae=T.memo(ie);function ve({setTenantEmailDomain:t}){const i=D(),d=z(),{clearAllLoading:g}=P(),n=s.getSignedInUser();f.useLayoutEffect(()=>{g()},[g]);const a=ee(),l=c(e=>e.tenantState.magicLinkCodeVerifier),{sendEmailMagicLinkFetchState:h,accountLocked:C,accountUnlockTime:k}=c(e=>e.tenantState),p=c(e=>e.tenantState.fetchState),L=c(e=>e.tenantState.activeTenantFetchState.fetchState),S=c(e=>e.tenantState.signInState),o=c(e=>e.tenantState.loggedInUser),r=c(e=>$(e)),I=c(e=>q(e)),m=J(),w=j().mode,U=m.state?.magicLinkExpired,b=m.state?.magicLinkAlreadyUsed;if(f.useEffect(()=>{h.fetchState==="Completed"&&l!=null&&(E.trackSignInLinkSent(),s.saveMagicLinkCodeVerifier(l))},[h.fetchState,l]),f.useEffect(()=>{t(void 0)},[]),f.useEffect(()=>{S!=="In-Progress"||p!=="Completed"&&L!=="Completed"||o?.zeniSessionId==null||r==null||(s.savePayNowInfoTooltip(!0,o.zeniSessionId),s.saveSignedInUserWithSession(o,o.zeniSessionId),s.saveSignedInUserTenants(G(I.tenantsInOrder),o.zeniSessionId),H(o.userId,o.zeniSessionId,r.tenantId),i(K(r.tenantId)),s.saveActiveTenantDomainForUser(r.tenantEmailDomain),i(Q("Completed")),F.updateAppLocaleID(ne(r)),te(o,r,w,void 0,I.tenantsInOrder),R().then(()=>{const e=V();e!=null&&_(e)}),setTimeout(()=>{E.trackLogin(B.Event.loginSuccess,o.authProvider??"google",X(r.productSettings))},2e3))},[S,p,L,o,r,I,w,m.state,i]),S==="In-Progress"&&p==="Completed"&&o?.zeniSessionId!=null&&r!=null||n!=null){const e=m.state?.origin??"/";return u.jsx(M,{to:e,state:{...m.state,origin:""}})}return u.jsxs(u.Fragment,{children:[u.jsx(ae,{magicLinkExpired:!!U,magicLinkAlreadyUsed:!!b,magicLinkExpiredEmail:s.getMagicLinkEmail()??void 0,location:m,navigate:d,deviceId:a??void 0,showEmailLogin:!0}),C===!0&&k!=null?u.jsx(N,{onClose:()=>i(x()),unlockDate:k}):null]})}export{ve as default};
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import{j as s}from"./liveblocks-DIG_sQTS.js";import{a as n}from"./sentry-DeeuWfnQ.js";import{u,g as m,h as p,N as g}from"./core-BQD7Nh1h.js";import{z as c,B as b,t as y,c as d,e as h}from"./index-NqZwiQK9.js";import{fQ as x,fR as I,JM as w}from"./zeni-epic-state-DPMNRP9z.js";import{n as j}from"./mui-BTlbyoml.js";import"./recharts-DvL3rz6g.js";import"./analytics-BwaA5sD9.js";import"./plaid-q_a4iNLa.js";import"./dnd-DkRdAB95.js";import"./stripe-DMRn4zHo.js";import"./lottie-BzitVa6X.js";import"./lexical-BChaWXti.js";import"./pdf-C5Pt0V8d.js";import"./utils-BQSiJMCN.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]="be319cca-04a4-4d96-bcb2-d163451bc7b8",e._sentryDebugIdIdentifier="sentry-dbid-be319cca-04a4-4d96-bcb2-d163451bc7b8")}catch{}})();function Q(){const e=u(),t=m(),i=p(),a=n.useRef(!1),f=c.isSignedIn(),r=t.state?.message==="logout",o=r||f;return n.useEffect(()=>{o&&!a.current&&(a.current=!0,setTimeout(()=>{try{c.clearAll(),e(x()),e(I(!1)),w(),y.reset(),d.trackLogout(h.Event.logoutSuccess),d.resetUserIdentity()}catch(l){console.error("Error during sign out:",l)}finally{r||i("/signin/auth",{replace:!0})}},0))},[o,r]),o?s.jsx(v,{children:s.jsx(b,{fetchState:"In-Progress"})}):s.jsx(g,{to:"../",replace:!0})}const v=j.div`
|
|
2
|
-
display: flex;
|
|
3
|
-
height: 100vh;
|
|
4
|
-
width: 100%;
|
|
5
|
-
flex: 1 1 auto;
|
|
6
|
-
flex-direction: column;
|
|
7
|
-
align-items: center;
|
|
8
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
9
|
-
`;export{Q as default};
|
|
@@ -1,37 +0,0 @@
|
|
|
1
|
-
import{j as e}from"./liveblocks-DIG_sQTS.js";import{h as B,g as U,u as P,i as V,j as f,N as L,n as M,o as Te,p as k}from"./core-BQD7Nh1h.js";import{cm as N,eP as D,NM as R,DS as ae,fh as H,DA as ne,NO as we,DV as Ie,NK as Ce,NL as se,O1 as ke,C0 as be,sP as je,NQ as Ae,E4 as Ee,NN as re,cO as Z,wX as oe,eY as ve,e_ as De,OX as Fe,OY as Le,DB as Be,OZ as Ue,DC as Pe,DL as Re,bt as Oe,bF as Ve,cx as Me,bG as Ne,cl as _e,fg as ze,bs as Ge,Jq as $e,ck as qe}from"./zeni-epic-state-DPMNRP9z.js";import{k as _,aq as He,z as A,x as z,c as b,c5 as Ze,c6 as Je,c7 as q,J,h as Ye,V as Ke,Y as We,v as ie,I as v,A as Xe,B as Qe,c8 as et,at as Y,m as tt,c9 as at,j as K,ca as nt,R as X,cb as st,a9 as rt}from"./index-NqZwiQK9.js";import{D as ot,n as O,S as it}from"./mui-BTlbyoml.js";import ct from"./NotFoundScreen-AUmyqBev.js";import{S as Q}from"./SetupPagesScreen-BWtBrDwg.js";import{a as d}from"./sentry-DeeuWfnQ.js";import{u as lt}from"./useAskAiCfoHostNavButtonProps-DFP8Wx8F.js";import{u as ut}from"./useInitialThreadRequest-D6gn8nP9.js";import{M as ce}from"./MobileAppDrawer-C0O6RwlS.js";import{F as dt}from"./FeaturePreviewScreen-CF3V2uH8.js";import{a as ee}from"./analyticsHelper-DfvTrPlk.js";import"./recharts-DvL3rz6g.js";import"./analytics-BwaA5sD9.js";import"./plaid-q_a4iNLa.js";import"./dnd-DkRdAB95.js";import"./stripe-DMRn4zHo.js";import"./lottie-BzitVa6X.js";import"./lexical-BChaWXti.js";import"./pdf-C5Pt0V8d.js";import"./utils-BQSiJMCN.js";import"./routePaths-Bn28lFcN.js";import"./BusinessVerificationPageScreen-C7p62r1u.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]="2a019454-ae9d-42b3-97ad-fb97962497fb",t._sentryDebugIdIdentifier="sentry-dbid-2a019454-ae9d-42b3-97ad-fb97962497fb")}catch{}})();const pt=M(function(t,a){const{companyId:n}=a;return{treasurySetupView:R(t,n),analytics:b}},function(t,a){const{navigate:n,analytics:o,treasurySetupView:p}=a;return{onBackClick:()=>{n("../")},onNextClick:()=>{const r=p.fundAllocationLocalData;o.trackTreasuryPortfolioConfirm(r.riskScore,ee(r)),t(Ie(!0))},onUpdateFundAllocation:r=>{o.trackTreasuryAllocationAction("update",ee(r)),t(we(r))}}})(Ze);function mt(){const t=B(),a=U(),n=P(),{tenantEmailDomain:o}=V(),p=_(),r=f(C=>C.treasurySetupViewState.portfolioAllocationUpdateStatus?.fetchState),m=He(r),s=N(p?.loggedInUserRoleMap),[l,i]=d.useState(!1),[g,I]=d.useState(!1),[u,c]=d.useState(!1),h=f(C=>D(C)),y=A.getSignedInUserTenant(o)?.companyId??h.companyId,T=A.getSignedInUser(),S=f(C=>R(C,y)),w=f(C=>C.treasurySetupViewState.fetchState),x=f(C=>C.treasurySetupViewState.currentAllocation.fetchStatus?.fetchState),F=f(C=>C.treasurySetupViewState.treasuryFundsDetails?.fetchStatus?.fetchState);if(T==null)throw Error("Can't access treasury portfolio allocation page without signing in...");if(d.useEffect(()=>{l||w!=="Not-Started"||y==null||(i(!0),n(ae(y,!0,!1)))},[l,w,y,n]),d.useEffect(()=>{u||F!=="Not-Started"||y==null||(c(!0),n(H()))},[u,F,y,n]),d.useEffect(()=>{g||x!=="Not-Started"||y==null||(I(!0),n(ne()))},[g,x,y,n]),d.useEffect(()=>{m==="In-Progress"&&r==="Completed"&&t("../")},[m,r,t]),h.companyTreasuryInfo?.info?.isTreasuryTOSAccepted===!1)return e.jsx(L,{to:"../promo"});const E=h.companyTreasuryInfo?.info?.isTreasuryTOSAccepted!==!0||w!=="Completed";return e.jsxs(e.Fragment,{children:[!E&&e.jsx(z,{analytics:b,onLoad:()=>{}}),e.jsx(pt,{navigate:t,location:a,companyId:y,isEditMode:!0,isLoading:E,isReadOnly:!s,treasurySetupView:S,analytics:b})]})}const ft=M(function(t,a){const n=a.currentTenant?.companyId;return{plaidConnectionDetails:ke(t,n,"zeni_treasury","treasury_setup").plaidConnectionDetails,treasurySetupView:R(t,n)}},function(t,a){const{navigate:n,transferDetails:o,treasurySetupView:p}=a,r=o.treasuryTransferMoneyLocalData,m=p.fundAllocationLocalData;return{onCancelClick:()=>{q(a.analytics,"cancel",r,m,"Transfer"),t(se()),n("../")},onTransferClick:()=>{q(a.analytics,"confirm",r,m,"Transfer"),t(Ee())},onSaveChangesToLocalStore:s=>{t(Ae(s))},onFetchLinkTokenClick:s=>{t(je("treasury_setup",s))},onEstablishConnectionClick:s=>{t(be(s,a.currentTenant?.companyId,"treasury_setup","zeni_treasury"))}}})(Je),yt=({isFirstTransfer:t})=>{const a=B(),{tenantEmailDomain:n}=V(),o=P(),[p,r]=d.useState(!1),[m,s]=d.useState(!1),[l,i]=d.useState(!1),[g,I]=d.useState(!1),u=f(x=>x.treasurySetupViewState.fetchState),c=f(x=>x.treasurySetupViewState.treasuryFundsDetails?.fetchStatus?.fetchState),h=f(x=>x.treasurySetupViewState.currentAllocation.fetchStatus?.fetchState),y=f(x=>D(x)),T=A.getSignedInUserTenant(n)?.companyId??y.companyId,S=f(x=>Ce(x)),w=f(x=>R(x,T));if(A.getSignedInUser()==null)throw Error("Can't access treasury transfer page without signing in...");return d.useEffect(()=>{m||u!=="Not-Started"||T==null||(s(!0),o(ae(T,!0,!1)))},[m,u,T,o]),d.useEffect(()=>{l||c!=="Not-Started"||T==null||(i(!0),o(H()))},[l,c,T,o]),d.useEffect(()=>{g||h!=="Not-Started"||T==null||(I(!0),o(ne()))},[g,h,T,o]),e.jsxs(e.Fragment,{children:[e.jsx(z,{analytics:b,onLoad:()=>{}}),e.jsx(ft,{analytics:b,navigate:a,transferDetails:S,onAnotherTransferClick:()=>{r(!1),o(se())},currentTenant:y,treasurySetupView:w,showReviewContent:p,maxInsuredAmount:5e5,onReviewClick:()=>{q(b,"review",S.treasuryTransferMoneyLocalData,w.fundAllocationLocalData,"Transfer"),r(!0)},isFirstTransfer:t,setShowReviewContent:r,onBackClick:()=>{}})]})},gt=O.div`
|
|
2
|
-
display: flex;
|
|
3
|
-
min-height: 100%;
|
|
4
|
-
width: 100%;
|
|
5
|
-
flex: 1 1 auto;
|
|
6
|
-
flex-direction: column;
|
|
7
|
-
align-items: center;
|
|
8
|
-
background-color: ${t=>t.theme.colors.grey4};
|
|
9
|
-
`,ht={overlayWidth:new Xe(100,100,48)},St=M(function(t,a){const n=re(t),{companyId:o}=a;return{treasuryDetail:n,treasurySetupView:R(t,o),downloadEndPoint:`${Y.bankingMicroServiceBaseUrl}/1.0/treasury-account/statements?query={"statement_type":"tax_statement"}`}},function(t,a){const{navigate:n,currentTenant:o,location:p,handleDrawerToggle:r,analytics:m}=a,{tenantEmailDomain:s}=o;return{onSettingsClick:()=>{m.trackAccountsListPageClicked("Settings Icon"),n("setup")},onReloadTransactions:()=>{t(oe(!0))},handleTreasuryOptionSelection:l=>{let i="page-not-found";l==="editPortfolio"?i=xt(s):l==="statements"?i=Tt(s):l==="taxLetter"?i=wt(s):l==="settings"&&(i=It(s));const g=tt(p.state?.pathnameStackToGoBack,p.pathname);n(i,{state:{pathnameStackToGoBack:g}})},onColumnSortConfigChanged:(l,i)=>{t(Fe({uiState:{sortKey:l,sortOrder:i}}))},onTransferClick:()=>{n("./transfer")},onBackClick:()=>{n("../../")},onClickMenuIcon:()=>{r(!0)},onAutoTransferClick:()=>{n("../../checking/auto-transfer")}}})(et);function $({isTransferDrawerOpen:t,isEditPortfolioDrawerOpen:a}){const n=U(),o=B(),p=P(),r=J(),m=Ye(),s=f(j=>D(j)),{tenantEmailDomain:l}=V(),i=s.companyId??A.getSignedInUserTenant(l)?.companyId,[g,I]=d.useState(!1),u=f(j=>re(j)),c=u.fetchState,h=u.accountSummary?.totalBalance?.amount,y=f(j=>j.treasurySetupViewState.treasuryFundsDetails?.fetchStatus),T=s.companyTreasuryInfo?.info?.businessVerificationStatus?.code==="verified",S=_(),w=!!s.companyTreasuryInfo?.info?.isTreasuryTOSAccepted,x=N(S?.loggedInUserRoleMap),F=Z(S?.loggedInUserRoleMap),{areTenantIdsInSync:E}=Ke();d.useEffect(()=>{c==="Not-Started"&&!g&&E&&(I(!0),p(oe(!0)))},[g,p,c,E]),d.useEffect(()=>{u.transactionsFetchState.fetchState==="Completed"&&u.transactions.length===0&&!n.pathname.includes("transfer")&&x&&o("./transfer")},[u.transactionsFetchState.fetchState,u.transactions.length]);const C=()=>{o("..")},[le,ue]=d.useState(!1),W=j=>{ue(j)},{isAiCfoAccessEnabled:de,onAskAiCfoClick:pe}=lt({mobileExploreReferrer:"Treasury"});We({isDataReady:c==="Completed"});const{useFeatureGate:G}=ie(),{isFeatureEnabled:me}=G(v.isDebitCardFeatureEnabled),{isFeatureEnabled:fe}=G(v.isAutoTransferRuleEnabled),{isFeatureEnabled:ye}=G(v.isTreasuryCommentingEnabled),ge=ut(i,{clearParams:c==="Completed"&&y?.fetchState==="Completed"}),he=ve(s),Se=De(me,s);if(he===!0&&Se!==!0)return e.jsx(dt,{});if(T){const j=y?.fetchState!=="Completed"||u.accountSummaryFetchState.fetchState!=="Completed";return e.jsxs(e.Fragment,{children:[u.accountSummaryFetchState.fetchState==="Completed"&&y?.fetchState==="Completed"&&t===!1&&a===!1?e.jsx(z,{analytics:b,onLoad:()=>{}}):null,e.jsx(ot,{onClose:C,anchor:"right",open:a||t,transitionDuration:250,PaperProps:{style:{width:ht.overlayWidth.valuePercentage(r),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:m.colors.black,opacity:.75,cursor:"pointer"}}},children:e.jsxs(Ct,{onClick:xe=>xe.stopPropagation(),children:[t===!0?e.jsx(yt,{isFirstTransfer:u.transactions.length===0||h===0}):null,a===!0?e.jsx(mt,{}):null]})}),e.jsxs(gt,{windowSize:r,children:[e.jsx(ce,{isAppContentDrawerOpen:le,handleDrawerToggle:W}),e.jsx(St,{treasuryDetailsView:u,isAutoTransferRuleEnabled:fe,navigate:o,currentTenant:s,location:n,companyId:i,analytics:b,isTreasuryCommentingEnabled:ye,handleDrawerToggle:W,initialOpenThreadRequest:ge,isLoading:j,isAiCfoAccessEnabled:de,onAskAiCfoClick:pe})]})]})}return w&&x?e.jsx(L,{to:"../setup"}):s.companyTreasuryInfo?.info&&!w&&F?e.jsx(L,{to:"../promo",state:n.state}):e.jsx(Qe,{fetchState:"In-Progress",style:{backgroundColor:m.colors.grey5}})}const xt=t=>`/${t}/treasury/edit-portfolio`,Tt=t=>`/${t}/treasury/statements`,wt=t=>`/${t}/treasury/tax-letter`,It=t=>`/${t}/treasury/setup`,Ct=O(it)`
|
|
10
|
-
display: flex;
|
|
11
|
-
min-height: 100%;
|
|
12
|
-
flex-direction: column;
|
|
13
|
-
`,kt=O.div`
|
|
14
|
-
display: flex;
|
|
15
|
-
height: 100vh;
|
|
16
|
-
width: 100%;
|
|
17
|
-
flex: 1 1 auto;
|
|
18
|
-
flex-direction: column;
|
|
19
|
-
align-items: center;
|
|
20
|
-
background-color: ${t=>t.theme.colors.grey4};
|
|
21
|
-
`;function bt(){const t=B(),a=P(),n=J(),o=U(),p=`${Y.bankingMicroServiceBaseUrl}/1.0/treasury-account`,[r,m]=d.useState(!1),s=f(c=>Le(c));d.useEffect(()=>{r||s.fetchState!=="Not-Started"||(m(!0),a(Be(!1)))},[r,s.fetchState,a]);const l=A.getSignedInUser(),i=f(c=>D(c)),g={userId:l?.userId??"",sessionId:l?.zeniSessionId??"",tenantId:i.tenantId??""},I=i.company?.companyInfo.companyLegalName??i.companyName;if(l==null)throw Error("Can't access statements page without signing in...");const u=s.fetchState!=="Completed";return e.jsx(kt,{windowSize:n,children:e.jsx(at,{currentTenantCompanyName:I,statementListView:s,isLoading:u,onBackClick:()=>{const c=K(o.state?.pathnameStackToGoBack),h=c.poppedPathname??"..";t(h,{state:{pathnameStackToGoBack:c.newStack}})},authParams:g,downloadEndPoint:p})})}const jt=O.div`
|
|
22
|
-
display: flex;
|
|
23
|
-
height: 100vh;
|
|
24
|
-
width: 100%;
|
|
25
|
-
flex: 1 1 auto;
|
|
26
|
-
flex-direction: column;
|
|
27
|
-
align-items: center;
|
|
28
|
-
background-color: ${t=>t.theme.colors.grey4};
|
|
29
|
-
`;function At(){const t=B(),a=J(),n=U(),o=P(),p=`${Y.bankingMicroServiceBaseUrl}/1.0/treasury-account`,[r,m]=d.useState(!1),s=f(c=>Ue(c));d.useEffect(()=>{r||s.fetchState!=="Not-Started"||(m(!0),o(Pe(!1)))},[r,s.fetchState,o]);const l=A.getSignedInUser(),i=f(c=>D(c)),g={userId:l?.userId??"",sessionId:l?.zeniSessionId??"",tenantId:i.tenantId??""},I=i.company?.companyInfo.companyLegalName??i.companyName;if(l==null)throw Error("Can't access tax letter page without signing in...");const u=s.fetchState!=="Completed";return e.jsx(jt,{windowSize:a,children:e.jsx(nt,{currentTenantCompanyName:I,taxLetterListView:s,isLoading:u,onBackClick:()=>{const c=K(n.state?.pathnameStackToGoBack),h=c.poppedPathname??"..";t(h,{state:{pathnameStackToGoBack:c.newStack}})},authParams:g,downloadEndPoint:p})})}const Et=M(function(t,a){const{companyId:n}=a,o=R(t,n);return{treasurySetupView:o,isSetupComplete:o.companyTreasuryInfo?.businessVerificationStatus?.code==="verified",videoUrl:"https://www.youtube.com/watch?v=sqvJWKCMZgk",meetingUrl:"https://meetings.hubspot.com/yoshi-araki/treasury-product-schedule-demo-link?embed=true"}},function(t,a){const{navigate:n,companyId:o}=a;return{onSetupButtonClick:()=>{t(Re(o))},onBackClick:()=>{n("../..",{relative:"path"})},onTreasurySetupSuccess:p=>{n(p?"..":"../setup",{relative:"path"})}}})(st),vt=()=>{const t=B(),a=U(),n=P(),{tenantEmailDomain:o}=V(),[p,r]=d.useState(!1),m=f(S=>D(S)),[s,l]=d.useState(!1),i=f(S=>S.treasurySetupViewState.treasuryFundsDetails?.fetchStatus);d.useEffect(()=>{s||i?.fetchState!=="Not-Started"||g==null||(l(!0),n(H()))},[i,n]);const g=A.getSignedInUserTenant(o)?.companyId??m.companyId,I=A.getSignedInUser(),u=!!m.companyTreasuryInfo?.info?.isTreasuryTOSAccepted,c=S=>{r(S)};if(I==null)throw Error("Can't access treasury promo page without signing in...");const h=_(),y=N(h?.loggedInUserRoleMap),T=Z(h?.loggedInUserRoleMap);if(u&&y)return e.jsx(L,{to:"../../treasury/setup"});if(m.company?.companyTreasuryInfo&&(!u&&y||T)){if(a.state?.message==="activation"){const S=K(a.state?.pathnameStackToGoBack);t(a.pathname,{state:{...a.state,message:void 0,pathnameStackToGoBack:S.newStack}})}return i?.fetchState!=="Completed"?e.jsx(te,{children:e.jsx(X,{size:"ExtraLarge",start:!0})}):e.jsxs(e.Fragment,{children:[e.jsx(z,{analytics:b,onLoad:S=>(w=>w.trackTreasuryPromoView("Treasury Promo Page"))(S)}),e.jsx(ce,{isAppContentDrawerOpen:p,handleDrawerToggle:c}),e.jsx(Et,{analytics:b,navigate:t,companyId:g,onClickMenuIcon:()=>{c(!0)}})]})}return e.jsx(te,{children:e.jsx(X,{size:"ExtraLarge",start:!0})})},te=O.div`
|
|
30
|
-
display: flex;
|
|
31
|
-
width: 100%;
|
|
32
|
-
height: 100%;
|
|
33
|
-
flex-direction: row;
|
|
34
|
-
justify-content: center;
|
|
35
|
-
align-items: center;
|
|
36
|
-
background-color: ${t=>t.theme.colors.grey5};
|
|
37
|
-
`;function ea(){const t=U(),a=f(E=>D(E)),{useFeatureGate:n}=ie(),{isFeatureEnabled:o}=n(v.isTreasuryEnabled),p=!!a.company?.companyTreasuryInfo?.isTreasuryTOSAccepted,r=_(),m=Z(r?.loggedInUserRoleMap),s=a?.userRole!=null&&Oe(a?.userRole),l=(a?.company==null||a.company.featuresActivationInfo?.isBillPayFeatureEnabled&&!s)&&Ve(r?.loggedInUserRoleMap),i=Me(r?.loggedInUserRoleMap),g=(a?.company==null||a.company.featuresActivationInfo?.isReimbursementFeatureEnabled&&!s)&&Ne(r?.loggedInUserRoleMap),{isFeatureEnabled:I}=n(v.isDepositAccountsFeatureEnabled),u=I&&!s&&_e(r?.loggedInUserRoleMap),c=a.company!=null&&ze(a.company),h=o&&c===!0&&!s&&N(r?.loggedInUserRoleMap),{isFeatureEnabled:y}=n(v.isChargeCardFeatureEnabled),{isFeatureEnabled:T}=n(v.isDebitCardFeatureEnabled),S=rt(a,y,T)&&!s&&Ge(r?.loggedInUserRoleMap),w=$e(r?.loggedInUserRoleMap),x=qe(r?.loggedInUserRoleMap),F=a.companyTreasuryInfo?.info?.businessVerificationStatus?.code==="verified";return e.jsxs(Te,{children:[x?null:e.jsx(k,{path:"setup",element:e.jsx(Q,{isBillPayAdminLevelAccess:l,isReimbursementAdminLevelAccess:g,isZeniAccountAdminLevelAccess:u,isChargeCardAdminLevelAccess:S,isTreasuryAdminLevelAccess:h,isUserHasOnlyCardAccess:w,isUserHasOnlyBillPayAccess:i,productType:"zeni_treasury",type:"setup"})}),x?null:e.jsx(k,{path:"verification",element:e.jsx(Q,{isBillPayAdminLevelAccess:l,isUserHasOnlyBillPayAccess:i,isReimbursementAdminLevelAccess:g,isZeniAccountAdminLevelAccess:u,isChargeCardAdminLevelAccess:S,isTreasuryAdminLevelAccess:h,isUserHasOnlyCardAccess:w,productType:"zeni_treasury",type:"verification"})}),e.jsx(k,{path:"promo",element:e.jsx(vt,{})}),e.jsx(k,{path:"statements",element:e.jsx(bt,{})}),e.jsx(k,{path:"tax-letter",element:e.jsx(At,{})}),F?e.jsxs(e.Fragment,{children:[e.jsx(k,{path:"/",element:e.jsx($,{isTransferDrawerOpen:!1,isEditPortfolioDrawerOpen:!1})}),h?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(ct,{})})]}):p&&h?e.jsx(k,{path:"*",element:e.jsx(L,{to:"../setup"})}):a.company?.companyZeniAccountInfo&&m?e.jsx(k,{path:"*",element:e.jsx(L,{to:"../promo",state:t.state})}):e.jsx(k,{path:"*",element:null})]})}export{ea as default};
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import{j as o}from"./liveblocks-DIG_sQTS.js";import{a as d}from"./sentry-DeeuWfnQ.js";import{s as u,u as h,j as b,N as y}from"./core-BQD7Nh1h.js";import{JJ as I,eW as w,zI as j}from"./zeni-epic-state-DPMNRP9z.js";import{z as c,B as x,C as S,E}from"./index-NqZwiQK9.js";import{n as l}from"./mui-BTlbyoml.js";import"./recharts-DvL3rz6g.js";import"./analytics-BwaA5sD9.js";import"./plaid-q_a4iNLa.js";import"./dnd-DkRdAB95.js";import"./stripe-DMRn4zHo.js";import"./lottie-BzitVa6X.js";import"./lexical-BChaWXti.js";import"./pdf-C5Pt0V8d.js";import"./utils-BQSiJMCN.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]="b276ca57-fc29-42fb-9940-89f7415bc6ac",e._sentryDebugIdIdentifier="sentry-dbid-b276ca57-fc29-42fb-9940-89f7415bc6ac")}catch{}})();const A=()=>{const[e]=u(),t=e.get("code")??"",i=e.get("state")??"",p=e.get("profileId")??"",[n,g]=d.useState(!1),a=h(),s=b(m=>I(m)),r=c.getSignedInUser(),f=c.getSignedInUserTenantWithId(i);if(r==null||f==null)return o.jsx(y,{to:"/signin/auth",replace:!0});if(r==null)throw Error("Can't access this page without signing in...");return w(r.userId,r.zeniSessionId,f?.tenantId),d.useEffect(()=>{n||(g(!0),a(j(t,p,i)))},[n,a]),s.fetchState==="Error"?o.jsx(D,{children:o.jsx(_,{children:s.error?.message??""})}):(s.fetchState==="Completed"&&window.close(),o.jsx(x,{fetchState:"In-Progress"}))},D=l.div`
|
|
2
|
-
display: flex;
|
|
3
|
-
width: 100%;
|
|
4
|
-
height: 100vh;
|
|
5
|
-
flex-direction: row;
|
|
6
|
-
justify-content: center;
|
|
7
|
-
align-items: center;
|
|
8
|
-
background-color: ${e=>e.theme.colors.grey5};
|
|
9
|
-
`,_=l(E.LargeRegular)`
|
|
10
|
-
display: flex;
|
|
11
|
-
color: ${S.important};
|
|
12
|
-
`;export{A as default};
|
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
import{j as n}from"./liveblocks-DIG_sQTS.js";import{h as ne,g as W,u as _,i as Y,j as k,n as K,N as X,o as Ve,p as w}from"./core-BQD7Nh1h.js";import{eP as U,OD as Ce,OE as $e,cl as ee,cm as Ne,fg as He,wV as we,B6 as Ze,wP as Tn,OF as On,OG as Bn,wS as Fn,wZ as fe,wM as Rn,wJ as Ln,Np as le,OH as Un,Eq as zn,Kv as Mn,Es as _n,kn as Oe,OI as Vn,qf as Ge,q3 as We,ke as Ye,kh as Be,Kw as Fe,Kx as $n,OJ as Nn,kg as Hn,kD as Zn,k5 as Gn,iE as Wn,iD as Yn,OK as Kn,OL as ye,E7 as qn,OM as Jn,ON as Qn,Ni as ke,OO as Re,OP as Xn,ED as et,O1 as nt,C0 as Ke,sP as qe,OQ as tt,EA as at,OR as Je,cM as Ae,EH as Qe,fh as ot,eY as Xe,e_ as De,EF as st,BW as rt,Ex as it,OS as en,OT as nn,E9 as tn,Ej as Le,OU as ct,NR as lt,EI as dt,bt as ut,bF as pt,cx as mt,bG as ht,bs as gt,Jq as ft}from"./zeni-epic-state-DPMNRP9z.js";import{k as te,v as N,z as S,I as F,h as z,B as de,bW as yt,a2 as Ie,J as V,A as q,j as an,aq as xt,af as Ue,c as R,bX as Ct,at as Se,bY as wt,x as ue,bZ as kt,e as be,aN as G,b_ as At,V as Dt,Y as on,ac as It,b$ as ze,c0 as St,m as ce,c1 as bt,c2 as Et,c3 as vt,a9 as Pt,o as jt}from"./index-NqZwiQK9.js";import{n as M,D as J,S as Q}from"./mui-BTlbyoml.js";import ie from"./NotFoundScreen-AUmyqBev.js";import{S as Me}from"./SetupPagesScreen-BWtBrDwg.js";import{F as sn}from"./FeaturePreviewScreen-CF3V2uH8.js";import{a as d}from"./sentry-DeeuWfnQ.js";import{M as pe}from"./MobileAppDrawer-C0O6RwlS.js";import{A as Tt,D as Ot,V as Bt}from"./DomesticWireDetailScreen-C-ET-tHk.js";import{A as Ft}from"./AddressScreen-h4XqWLFk.js";import{u as rn}from"./useAskAiCfoHostNavButtonProps-DFP8Wx8F.js";import{Z as Rt}from"./ZeniAccountStatementScreen-9NreSUns.js";import"./recharts-DvL3rz6g.js";import"./analytics-BwaA5sD9.js";import"./plaid-q_a4iNLa.js";import"./dnd-DkRdAB95.js";import"./stripe-DMRn4zHo.js";import"./lottie-BzitVa6X.js";import"./lexical-BChaWXti.js";import"./pdf-C5Pt0V8d.js";import"./utils-BQSiJMCN.js";import"./analyticsHelper-DfvTrPlk.js";import"./routePaths-Bn28lFcN.js";import"./BusinessVerificationPageScreen-C7p62r1u.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]="9290ceb5-1144-48fe-8089-29fe981b2b3e",e._sentryDebugIdIdentifier="sentry-dbid-9290ceb5-1144-48fe-8089-29fe981b2b3e")}catch{}})();const Lt=M.div`
|
|
2
|
-
display: flex;
|
|
3
|
-
min-height: 100%;
|
|
4
|
-
width: 100%;
|
|
5
|
-
flex: 1 1 auto;
|
|
6
|
-
flex-direction: column;
|
|
7
|
-
align-items: center;
|
|
8
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
9
|
-
`,Ut=K(function(e){return{autoTransferRuleView:Ce(e),downloadAccountDetailEndPoint:`${Ie}/account_details`,transferLimit:5e5,depositAccountListView:Ze(e.depositAccountState,e.depositAccountListState)}},function(e,t){const{navigate:s,handleDrawerToggle:o}=t;return{onBackClick:()=>{s("..")},onClickMenuIcon:()=>{o(!0)},onFetchAutoTransferRules:a=>{e(we(a))},onCreateRule:()=>{e(Ln())},onUpdateRule:a=>{e(fe(a))},onDeleteClick:a=>{e(Rn(a))},onPauseClick:a=>{e(fe(a,!0,!1))},onResumeClick:a=>{e(fe(a,!1,!0))},onActivityClick:(a,r)=>{e(Fn(a,r))},onUpdateRuleLocalData:a=>{e(Bn(a))},clearRuleLocalData:()=>{e(On())},onEditClick:a=>{s(`./${a}/edit`)},onEditDrawerClose:()=>{s("../../",{relative:"path"})},onReviewClick:()=>{e(Tn())}}})(yt);function _e({isEditDrawerOpen:e}){const t=ne(),s=W(),o=_(),a=te(),{ruleId:r,tenantEmailDomain:u}=Y(),{useFeatureGate:l}=N(),[p,h]=d.useState(!1),[x,i]=d.useState(!1),c=k(y=>U(y)),m=k(y=>Ce(y)),C=m?.fetchState??"Not-Started",b=k(y=>$e(y)),g=c?.companyId??S.getSignedInUserTenant(u)?.companyId,A=ee(a?.loggedInUserRoleMap)||Ne(a?.loggedInUserRoleMap),{isFeatureEnabled:D}=l(F.isTreasuryEnabled),f=c?.company!=null&&He(c.company),I=D&&f,O=S.getSignedInUser(),L=c.tenantId,j={userId:O?.userId??"",sessionId:O?.zeniSessionId??"",tenantId:L??""},v=c.companyName;d.useEffect(()=>{!x&&C==="Not-Started"&&g&&(i(!0),o(we(!0)))},[x,C,g,o]);const E=y=>{h(y)},T=z(),P=!!s.state?.scrollToAddRule;return m?.fetchState!=="Completed"?n.jsx(de,{fetchState:"In-Progress",style:{backgroundColor:T.colors.grey5}}):n.jsxs(Lt,{children:[n.jsx(pe,{isAppContentDrawerOpen:p,handleDrawerToggle:E}),n.jsx(Ut,{navigate:t,location:s,currentTenant:c,companyName:v,handleDrawerToggle:E,isEditDrawerOpen:e,editingRuleId:r,authParams:j,includeTreasuryOption:I,hasAdminLevelAccess:A,zeniAccountsConfigDetail:b,scrollToAddRule:P})]})}const zt={overlayWidth:new q(100,100,58)},Mt=({vendorId:e,isDrawerOpen:t,closeDrawerHandler:s})=>{const o=_(),a=z(),r=V();if(S.getSignedInUser()==null)throw Error("Can't access ach account page without signing in...");return n.jsx(J,{onClose:()=>{s(!0),o(le())},anchor:"right",open:t,PaperProps:{style:{width:zt.overlayWidth.valuePercentage(r),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:a.colors.black,opacity:.75,cursor:"pointer"}}},children:n.jsx(_t,{onClick:u=>u.stopPropagation(),children:n.jsx(Tt,{vendorIdParam:e,accountContext:"express-pay"})})})},_t=M(Q)`
|
|
10
|
-
display: flex;
|
|
11
|
-
min-height: 100%;
|
|
12
|
-
flex-direction: column;
|
|
13
|
-
`,Vt={overlayWidth:new q(100,100,58)},$t=({isDrawerOpen:e,closeDrawerHandler:t})=>{const s=_(),o=z(),a=V();if(S.getSignedInUser()==null)throw Error("Can't access address page without signing in...");return n.jsx(J,{onClose:()=>{t(!0),s(le())},anchor:"right",open:e,PaperProps:{style:{width:Vt.overlayWidth.valuePercentage(a),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:o.colors.black,opacity:.75,cursor:"pointer"}}},children:n.jsx(Nt,{onClick:r=>r.stopPropagation(),children:n.jsx(Ft,{accountContext:"express-pay",addressTypeParam:"vendor_address"})})})},Nt=M(Q)`
|
|
14
|
-
display: flex;
|
|
15
|
-
min-height: 100%;
|
|
16
|
-
flex-direction: column;
|
|
17
|
-
`,Ht={overlayWidth:new q(100,100,58)},Zt=({vendorId:e,isDrawerOpen:t,closeDrawerHandler:s})=>{const o=_(),a=z(),r=V();if(S.getSignedInUser()==null)throw Error("Can't access ach account page without signing in...");return n.jsx(J,{onClose:()=>{s(!0),o(le())},anchor:"right",open:t,PaperProps:{style:{width:Ht.overlayWidth.valuePercentage(r),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:a.colors.black,opacity:.75,cursor:"pointer"}}},children:n.jsx(Gt,{onClick:u=>u.stopPropagation(),children:n.jsx(Ot,{vendorIdParam:e,accountContext:"express-pay"})})})},Gt=M(Q)`
|
|
18
|
-
display: flex;
|
|
19
|
-
min-height: 100%;
|
|
20
|
-
flex-direction: column;
|
|
21
|
-
`,Wt=M.div`
|
|
22
|
-
display: flex;
|
|
23
|
-
height: 100vh;
|
|
24
|
-
width: 100%;
|
|
25
|
-
flex: 1 1 auto;
|
|
26
|
-
flex-direction: column;
|
|
27
|
-
align-items: center;
|
|
28
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
29
|
-
`,Yt=K(function(e,t){const s=U(e),o=S.getSignedInUser(),a=s.tenantId,r={userId:o?.userId??"",sessionId:o?.zeniSessionId??"",tenantId:a??""},u=t.expressPayDetails,l=e.entityAutoCompleteState.autoCompleteText.common,p=Mn(e,"common");return{expressPayDetails:u,fileProps:{authParams:r,filesEndPoint:`${Se.fileMicroServiceBaseUrl}`},vendorSearchAutoCompleteData:{autoCompleteText:l,entityAutoCompleteView:p},analytics:t.analytics}},function(e,t){const{navigate:s}=t;return{onSaveVendor:o=>{e(Yn(o,void 0,void 0,!0))},saveVendorDetailLocalData:(o,a)=>{e(Be({vendorId:a,localData:o}))},saveExpressPayLocalData:o=>{e(Wn({localData:o}))},onVendorSelected:o=>{o!=null&&e(Gn(o,!1))},updateSelectedVendorForCreate:o=>{e(Zn(o))},initializeVendorAddress:()=>{e(Hn())},resetVendorSaveStatus:o=>{e(Nn({vendorId:o}))},vendorSearchAutoCompleteActions:{onAutoCompleteInputChange:(o,a)=>{o.trim().length>=2?e($n({searchString:o,entityType:a,searchOrigin:"common"})):o.trim().length===0&&e(Fe("common"))},onCancelAutoComplete:()=>{e(Fe("common"))}},chooseNewVendor:o=>{e(Be({localData:{vendorName:o}}))},onClickAddAccount:o=>{o.method.toLowerCase().indexOf("ach")!==-1?s("./add-ach",{relative:"path"}):o.method.toLowerCase().indexOf("wire")!==-1&&o.method.toLowerCase().indexOf("domestic")!==-1&&s("./add-wire",{relative:"path"})},updateFilesEntity:o=>{e(Ye({files:o}))},onDeleteFile:o=>{e(We(o))},onEditFileName:(o,a)=>{e(Ge(o,a.split(".")[0]))},onBackClick:o=>{o!=null&&e(Oe(o)),e(Oe()),e(Vn()),e(le()),s("../",{relative:"path"})},onSchedulePayment:()=>{e(_n())}}})(Ct);function se({isAddACHDrawerOpen:e,isAddWireDrawerOpen:t,isAddAddressDrawerOpen:s}){const o=ne(),a=W(),r=_(),[u,l]=d.useState(!1),{tenantEmailDomain:p}=Y(),h=te(),x=k(y=>y.expressPayState.fetchState),i=k(y=>U(y)),c=k(y=>Un(y)),m=c.expressPayLocalData?.vendorId,C=i.companyId??S.getSignedInUserTenant(p)?.companyId,[b,g]=d.useState(!1),[A,D]=d.useState(!1),[f,I]=d.useState(!1),O=an(a.state?.pathnameStackToGoBack),{poppedPathname:L}=O,j=L?.split("/"),v=j?.[j.length-1];d.useEffect(()=>{e===!0?g(!0):(g(!1),document.body.style.overflow="auto")},[e]),d.useEffect(()=>{t===!0?D(!0):(D(!1),document.body.style.overflow="auto")},[t]),d.useEffect(()=>{s===!0?I(!0):(I(!1),document.body.style.overflow="auto")},[s]),d.useEffect(()=>{x==="Not-Started"&&r(zn(!0,!0))},[x,r]);const E=xt(c.vendorViewDetails.bankAccountCreationState?.fetchState);if(d.useEffect(()=>{E==="In-Progress"&&c.vendorViewDetails.bankAccountCreationState?.fetchState==="Completed"&&P()},[E,c.vendorViewDetails.bankAccountCreationState?.fetchState]),S.getSignedInUser()==null)throw Error("Can't access express pay page without signing in...");const T=y=>{l(y)},P=()=>{g(!1),D(!1),o("../",{relative:"path"})};return n.jsxs(Wt,{children:[Ue(a)?n.jsx(pe,{isAppContentDrawerOpen:u,handleDrawerToggle:T}):null,b===!0?n.jsx(Mt,{vendorId:m,closeDrawerHandler:P,isDrawerOpen:b}):null,A===!0?n.jsx(Zt,{vendorId:m,closeDrawerHandler:P,isDrawerOpen:A}):null,f===!0?n.jsx($t,{closeDrawerHandler:P,isDrawerOpen:f}):null,n.jsx(Bt,{vendorId:m,isExpressPayPage:!0}),n.jsx(Yt,{navigate:o,location:a,companyId:C,accountId:v,analytics:R,currentTenant:i,vendorId:m,roleMap:h?.loggedInUserRoleMap,isSettings:Ue(a),expressPayDetails:c,onClickMenuIcon:()=>{T(!0)}})]})}const Kt={overlayWidth:new q(100,100,58)},qt=({authParams:e,downloadAccountDetailEndPoint:t,isAccountInfoDrawerOpen:s,zeniBankAccountDetail:o,closeDrawerHandler:a})=>{const r=z(),u=V(),l=k(i=>$e(i)),p=k(i=>U(i));if(S.getSignedInUser()==null)throw Error("Can't access Account detail page without signing in...");const h=()=>{a(!0)},x={depositAccount:o,onDismissClick:h,zeniAccountsConfigDetail:l,authParams:e,downloadAccountDetailEndPoint:t,currentTenant:p};return n.jsx(J,{anchor:"right",open:s,PaperProps:{style:{width:Kt.overlayWidth.valuePercentage(u),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:r.colors.black,opacity:.75,cursor:"pointer"}}},onClose:()=>h(),children:n.jsx(Jt,{onClick:i=>i.stopPropagation(),children:n.jsx(wt,{...x})})})},Jt=M(Q)`
|
|
30
|
-
display: flex;
|
|
31
|
-
min-height: 100%;
|
|
32
|
-
flex-direction: column;
|
|
33
|
-
`,Qt={overlayWidth:new q(100,100,58)},cn=({isCheckDepositDrawerOpen:e,closeDrawerHandler:t})=>{const s=z(),o=V(),a=_(),r=k(i=>U(i)),u=S.getSignedInUser(),l=r.tenantId,p={userId:u?.userId??"",sessionId:u?.zeniSessionId??"",tenantId:l??""};if(u==null)throw Error("Can't access check deposit page without signing in...");const h=k(i=>Kn(i)),x={analytics:R,checkDeposit:h,filesEndPoint:`${Se.fileMicroServiceBaseUrl}`,authParams:p,onSaveChangesToLocalStore:i=>{a(Jn(i))},updateFilesEntity:i=>{a(Ye({files:i}))},onAnotherTransferClick:()=>{a(ye())},onDeleteFile:i=>{a(We(i))},onEditFileName:(i,c)=>{a(Ge(i,c.split(".")[0]))},onCheckDpositClick:()=>{a(qn())},onDismissClick:()=>{t(!0),a(ye())}};return n.jsxs(n.Fragment,{children:[n.jsx(ue,{analytics:R,onLoad:i=>(c=>c.trackPageLoaded(be.Event.accountsDepositCheckFormViewed))(i)}),n.jsx(J,{anchor:"right",open:e,PaperProps:{style:{width:Qt.overlayWidth.valuePercentage(o),boxShadow:"none",zIndex:8}},slotProps:{backdrop:{style:{backgroundColor:s.colors.black,opacity:.75,cursor:"pointer"}}},onClose:(i,c)=>(c==="backdropClick"||c==="escapeKeyDown")&&(t(!0),void a(ye())),children:n.jsx(Xt,{onClick:i=>i.stopPropagation(),children:n.jsx(kt,{...x})})})]})},Xt=M(Q)`
|
|
34
|
-
display: flex;
|
|
35
|
-
min-height: 100%;
|
|
36
|
-
flex-direction: column;
|
|
37
|
-
`,ea={overlayWidth:new q(100,100,58)},na=K(function(e,t){const s=t.currentTenant?.companyId;return{plaidConnectionDetails:nt(e,s,"zeni_accounts","external_account").plaidConnectionDetails,depositAccountListView:Ze(e.depositAccountState,e.depositAccountListState)}},function(e,t){return{onReviewClick:()=>e(at()),clearReviewTransferDetail:()=>e(tt()),onFetchLinkTokenClick:s=>{e(qe("external_account",s))},onEstablishConnectionClick:s=>{e(Ke(s,t.currentTenant?.companyId,"external_account",void 0,"link_external_account"))}}})(At),ln=({isTransferDrawerOpen:e,authParams:t,downloadAccountDetailEndPoint:s,closeDrawerHandler:o,zeniAccountsConfig:a})=>{const r=k(f=>Qn(f)),u=k(f=>U(f)),l=z(),p=V(),h=_(),{accountId:x}=Y(),[i,c]=d.useState("achTransfer"),[m,C]=d.useState(!1);if(S.getSignedInUser()==null)throw Error("Can't access invite people page without signing in...");const{useDynamicConfig:b}=N(),{configValue:g}=b(G.zeniAccountsConfig),A=ke(g),D=()=>{o(!0),h(Re())};return d.useEffect(()=>{r.reviewTransferDetail.fetchState==="Completed"&&C(!0)},[C,r.reviewTransferDetail.fetchState]),n.jsxs(n.Fragment,{children:[n.jsx(ue,{analytics:R,onLoad:f=>(I=>I.trackPageLoaded(be.Event.zeniAccountsTransferFormViewed))(f)}),n.jsx(J,{onClose:()=>{(i==="achTransfer"&&m===!1||i==="achTransfer"&&m&&r.fetchState==="Completed")&&D()},anchor:"right",open:e,PaperProps:{style:{width:ea.overlayWidth.valuePercentage(p),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:l.colors.black,opacity:.75,cursor:"pointer"}}},children:n.jsx(ta,{onClick:f=>f.stopPropagation(),children:n.jsx(na,{analytics:R,transferDetails:r,authParams:t,downloadAccountDetailEndPoint:s,onTransferClick:()=>{R.trackTransferBetweenAccountsFormClicked("Transfer",r.reviewTransferDetail.reviewTransferMoney.isShowDailyAchLimitWarning?"Review Split Transfer":"Review Transfer",r.transferDetailLocalData.transferFrom?.label,r.transferDetailLocalData.transferTo?.label,r.transferDetailLocalData.amount.amount,r.reviewTransferDetail.reviewTransferMoney.isShowDailyAchLimitWarning,r.reviewTransferDetail.reviewTransferMoney.transferSchedules.length,r.transferDetailLocalData.transferFrom?.accType==="paymentAccount"&&r.transferDetailLocalData.transferTo?.accType==="depositAccount"&&a.zeniAccountsConfigDetail.depositProductConfig.depositProducts?.[0].range?.[1]!=null&&r.transferDetailLocalData.amount.amount>a.zeniAccountsConfigDetail.depositProductConfig.depositProducts[0].range[1]),h(et(x))},onDismissClick:D,onSaveChangesToLocalStore:f=>{h(Xn(f))},onAnotherTransferClick:()=>{C(!1),h(Re())},currentTenant:u,zeniAccountsConfigDetail:a,currentDrawerContent:i,setCurrentDrawerContent:c,showReviewContent:m,setShowReviewContent:C,onBackClick:()=>{},maxInsuredAmount:A.maxInsuredAmount})})})]})},ta=M(Q)`
|
|
38
|
-
display: flex;
|
|
39
|
-
min-height: 100%;
|
|
40
|
-
flex-direction: column;
|
|
41
|
-
`,aa=M.div`
|
|
42
|
-
display: flex;
|
|
43
|
-
min-height: 100%;
|
|
44
|
-
width: 100%;
|
|
45
|
-
flex: 1 1 auto;
|
|
46
|
-
flex-direction: column;
|
|
47
|
-
align-items: center;
|
|
48
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
49
|
-
`,oa=K(function(e,t){return{zeniAccountListView:Je(e),isExpressPayEnabled:t.isExpressPayEnabled,analytics:t.analytics}},function(e,t){const{navigate:s,currentTenant:o,location:a,companyId:r,handleDrawerToggle:u,analytics:l,isBillPayEnabled:p,isDebitCardFeatureEnabled:h}=t,{tenantEmailDomain:x}=o;return{onZeniAccountClick:(i,c)=>{l.trackAccountsListPageClicked("Accounts Row Item Click",c,"active");const m=sa(x,i),C=ce(a.state?.pathnameStackToGoBack,a.pathname);s(m,{state:{pathnameStackToGoBack:C}})},onSettingsClick:()=>{l.trackAccountsListPageClicked("Settings Icon"),s("setup")},onReloadTransactions:()=>{e(Qe(!1))},handleMoveMoneyOptionSelection:(i,c)=>{let m="page-not-found";i==="sendMoney"&&(m=mn(x)),i==="payBill"?m=dn(o,p,h):i==="transfer"?(m=un(x),c!=null&&e(en(c))):i==="checkDeposit"&&(m=pn(x));const C=ce(a.state?.pathnameStackToGoBack,a.pathname);s(m,{state:{pathnameStackToGoBack:C}})},unlinkPaymentAccount:(i,c)=>{l.trackAccountsListPageClicked("Unlink Account",c),e(it(i))},onFetchLinkTokenClick:(i,c)=>{e(qe("external_account",i,c))},onUpdatePaymentAccountStatus:(i,c,m)=>{e(rt(i,c,"zeni_accounts","external_account",m))},onEstablishConnectionClick:i=>{e(Ke(i,r,"external_account",void 0,"link_external_account"))},onCreateCheckingClick:i=>{e(st(i))},onClickMenuIcon:()=>{u(!0)},onTreasuryGetStartedClick:()=>{s("../../treasury/promo")},onAutoTransferClick:i=>{i?s("./auto-transfer",{state:{...a.state,scrollToAddRule:!0}}):s("./auto-transfer")}}})(St);function xe({isTransferDrawerOpen:e,isCheckDepositDrawerOpen:t}){const s=W(),o=ne(),a=_(),r=V(),{tenantEmailDomain:u}=Y(),{useDynamicConfig:l,useFeatureGate:p}=N(),h=z(),{configValue:x}=l(G.zeniAccountsConfig),{isFeatureEnabled:i}=p(F.isTreasuryEnabled),{isFeatureEnabled:c}=p(F.isDebitCardFeatureEnabled),{isFeatureEnabled:m}=p(F.isAutoTransferRuleEnabled),{isFeatureEnabled:C}=p(F.isCheckingCommentingEnabled),b=ke(x),g=k(B=>U(B)),A=g.companyId??S.getSignedInUserTenant(u)?.companyId,{configValue:D}=l(G.expressPayConfig),f=D.is_enable_all_tenants===!0||D.tenant_ids!=null&&D.tenant_ids.includes(g.tenantId),[I,O]=d.useState(!1),[L,j]=d.useState(!1),[v,E]=d.useState(!1),[T,P]=d.useState(!1),y=k(B=>Je(B)),$=y.fetchState,ae=k(B=>Ce(B)),oe=ae?.fetchState??"Not-Started",me=!!g.companyZeniAccountInfo?.info?.isZeniAccountEnabled,H=te(),Z=!!g.companyZeniAccountInfo?.info?.isZeniAccountTOSAccepted,hn=!!g.companyTreasuryInfo?.info?.isTreasuryTOSAccepted,gn=ee(H?.loggedInUserRoleMap),fn=Ae(H?.loggedInUserRoleMap),yn=!!g.companyBillPayInfo?.info?.isBillPayEnabled,Ee=S.getSignedInUser(),xn={userId:Ee?.userId??"",sessionId:Ee?.zeniSessionId??"",tenantId:g.tenantId??""},Cn=`${Ie}/account_details`,{areTenantIdsInSync:ve}=Dt();d.useEffect(()=>{!I&&ve&&(O(!0),a(Qe(!1)))},[I,a,$,ve]),d.useEffect(()=>{!L&&oe==="Not-Started"&&A&&(j(!0),a(we(!0)))},[L,oe,A,a]),d.useEffect(()=>{e!=null&&e===!0?E(!0):(E(!1),document.body.style.overflow="auto")},[e]),d.useEffect(()=>{P(t!=null&&t===!0)},[t]);const Pe=()=>{E(!1),o("..")},[wn,kn]=d.useState(!1),je=B=>{kn(B)},{isAiCfoAccessEnabled:An,onAskAiCfoClick:Dn}=rn({mobileExploreReferrer:"Checking Accounts"});on({isDataReady:$==="Completed"});const In=g.company!=null&&He(g.company),he=(i&&In)===!0&&!hn,[Sn,bn]=d.useState(!1),ge=k(B=>B.treasurySetupViewState.treasuryFundsDetails),En=ge.fundsDetails,vn=It(En);d.useEffect(()=>{he!==!0||Sn||ge?.fetchStatus.fetchState!=="Not-Started"||(bn(!0),a(ot()))},[ge.fetchStatus,a]);const Pn=Xe(g),jn=De(c,g);return Pn===!0&&jn!==!0?n.jsx(sn,{}):me?n.jsxs(n.Fragment,{children:[y.fetchState==="Completed"&&v===!1&&T===!1?n.jsx(ue,{analytics:R,onLoad:B=>(Te=>{Te.trackAccountsListPageViewed(y.depositAccountsSelectorView.depositAccounts.length,y.externalAccountsSelectorView.paymentAccounts.length,ze(y.summary?.totalBalance.available.amount??0),ze(y.summary?.totalInterest.available.amount??0),y.zeniAccountsConfig.zeniAccountsConfigDetail.annualPercentageYield),he&&Te.trackTreasuryPromoView("Checking Promo Banner")})(B)}):null,v===!0?n.jsx(ln,{closeDrawerHandler:Pe,isTransferDrawerOpen:v,zeniAccountsConfig:y.zeniAccountsConfig,authParams:xn,downloadAccountDetailEndPoint:Cn}):null,T===!0?n.jsx(cn,{closeDrawerHandler:Pe,isCheckDepositDrawerOpen:T}):null,n.jsxs(aa,{windowSize:r,children:[n.jsx(pe,{isAppContentDrawerOpen:wn,handleDrawerToggle:je}),n.jsx(oa,{zeniBankListView:y,navigate:o,currentTenant:g,location:s,companyId:A,analytics:R,maxInsuredAmount:b.maxInsuredAmount,isExpressPayEnabled:f,isBillPayEnabled:yn,isCheckingCommentingEnabled:C,isDebitCardFeatureEnabled:c,isAutoTransferRuleEnabled:m,handleDrawerToggle:je,showTreasuryPromo:he,treasuryYieldPercentage:vn,treasuryInsuredAmount:5e5,isAiCfoAccessEnabled:An,onAskAiCfoClick:Dn})]})]}):Z&&gn?n.jsx(X,{to:"../setup"}):g.companyZeniAccountInfo?.info&&!Z&&fn?n.jsx(X,{to:"../promo",state:s.state}):n.jsx(de,{fetchState:"In-Progress",style:{backgroundColor:h.colors.grey5}})}const dn=(e,t,s)=>{const o=De(s,e),{tenantEmailDomain:a}=e;return o===!0||t===!1?`/${a}/bills`:`/${a}/bill/new`},sa=(e,t)=>`/${e}/checking/${t}`,un=(e,t)=>t==null?`/${e}/checking/transfer`:`/${e}/checking/${t}/transfer`,pn=(e,t)=>t==null?`/${e}/checking/check-deposit`:`/${e}/checking/${t}/check-deposit`,mn=e=>`/${e}/checking/express-pay`,ra=M.div`
|
|
50
|
-
display: flex;
|
|
51
|
-
width: 100%;
|
|
52
|
-
flex: 1 1 auto;
|
|
53
|
-
flex-direction: column;
|
|
54
|
-
align-items: center;
|
|
55
|
-
min-height: 100vh;
|
|
56
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
57
|
-
`,ia=K(function(e,t){const{currentTenant:s}=t,o=nn(e,t.accountId),a=S.getSignedInUser(),r=e.tenantState.currentTenantId,u={userId:a?.userId??"",sessionId:a?.zeniSessionId??"",tenantId:r??""},l=o.accountDetail?.id??"";return{currentTenantCompanyName:s.companyName??"",authParams:u,downloadEndPoint:`${Se.bankingMicroServiceBaseUrl}/1.0/deposit-accounts/${l}`,zeniAccountDetail:o,isExpressPayEnabled:t.isExpressPayEnabled,fetchState:o.fetchState}},function(e,t){const{navigate:s,currentTenant:o,location:a,accountId:r}=t,{tenantEmailDomain:u}=o;return{handleMoveMoneyOptionSelection:(l,p)=>{let h="page-not-found";l==="sendMoney"?h=mn(u):l==="payBill"?h=dn(o,t.isBillPayEnabled,t.isDebitCardFeatureEnabled):l==="transfer"?(h=un(u,r),p!=null&&e(en(p))):l==="checkDeposit"?(h=pn(u,r),p!=null&&e(ct(p))):l==="accountStatement"&&(h=la(u,r));const x=ce(a.state?.pathnameStackToGoBack,a.pathname);s(h,{state:{pathnameStackToGoBack:x}})},onAccountDetailClick:()=>{const l=ca(u,r),p=ce(a.state?.pathnameStackToGoBack,a.pathname);s(l,{state:{pathnameStackToGoBack:p}})},onEditNameClick:l=>{e(Le(r,"editName",l))},onReloadZeniAccountDetailPage:()=>{e(tn(r,!1))},onCloseAccountClick:()=>{e(Le(r,"closeAccount",""))},onBackClick:()=>{s("../",{relative:"path"})}}})(bt);function re({isTransferDrawerOpen:e,isCheckDepositDrawerOpen:t,isAccountInfoDrawerOpen:s}){const o=W(),a=ne(),r=_(),u=V(),{tenantEmailDomain:l,accountId:p}=Y(),{useDynamicConfig:h}=N(),{useFeatureGate:x}=N(),{isFeatureEnabled:i}=x(F.isDebitCardFeatureEnabled),{isFeatureEnabled:c}=x(F.isCheckingCommentingEnabled),m=k(Z=>U(Z)),{configValue:C}=h(G.expressPayConfig),b=C.is_enable_all_tenants===!0||C.tenant_ids!=null&&C.tenant_ids.includes(m.tenantId),g=!!m.companyBillPayInfo?.info?.isBillPayEnabled,A=S.getSignedInUser(),D=m.companyId??S.getSignedInUserTenant(l)?.companyId,f={userId:A?.userId??"",sessionId:A?.zeniSessionId??"",tenantId:m.tenantId??""},I=`${Ie}/account_details`,[O,L]=d.useState(!1),[j,v]=d.useState(!1),[E,T]=d.useState(!1),[P,y]=d.useState(!1),$=k(Z=>nn(Z,p??"")),ae=$.fetchState,{isAiCfoAccessEnabled:oe,onAskAiCfoClick:me}=rn({mobileExploreReferrer:"Checking Account Detail"});on({isDataReady:ae==="Completed"}),d.useEffect(()=>{O||(r(tn(p??"",!1)),L(!0))},[O,r,ae]),d.useEffect(()=>{y(s!=null&&s===!0)},[s]),d.useEffect(()=>{e!=null&&e===!0?v(!0):(v(!1),document.body.style.overflow="auto")},[e]),d.useEffect(()=>{T(t!=null&&t===!0)},[t]);const H=()=>{y(!1),a("..")};return n.jsxs(n.Fragment,{children:[P===!0&&$.accountDetail!=null?n.jsx(qt,{authParams:f,downloadAccountDetailEndPoint:I,closeDrawerHandler:H,isAccountInfoDrawerOpen:P,zeniBankAccountDetail:$.accountDetail}):null,j===!0?n.jsx(ln,{closeDrawerHandler:H,isTransferDrawerOpen:j,zeniAccountsConfig:$.zeniAccountsConfig,authParams:f,downloadAccountDetailEndPoint:I}):null,E===!0?n.jsx(cn,{closeDrawerHandler:H,isCheckDepositDrawerOpen:E}):null,n.jsx(ra,{windowSize:u,children:n.jsx(ia,{navigate:a,currentTenant:m,location:o,companyId:D,isDebitCardFeatureEnabled:i,accountId:p??"",isBillPayEnabled:g,isCheckingCommentingEnabled:c,isExpressPayEnabled:b,isAiCfoAccessEnabled:oe,onAskAiCfoClick:me})})]})}const ca=(e,t)=>`/${e}/checking/${t}/account-info`,la=(e,t)=>`/${e}/checking/${t}/statements`,da=K(function(e,t){const{companyId:s}=t;return{zeniAccountSetupView:lt(e,s),meetingUrl:"https://meetings.hubspot.com/niharn/demo-accounts?embed=true"}},function(e,t){const{navigate:s,companyId:o}=t;return{onSetupButtonClick:()=>{R.trackAccountsPromoPageClicked("Setup Accounts"),e(dt(o))},onBackClick:()=>{s("../..",{relative:"path"})},onSetupZeniAccountSuccess:()=>{s("../setup",{relative:"path"})}}})(vt),ua=()=>{const e=ne(),t=W(),{tenantEmailDomain:s}=Y(),{useDynamicConfig:o}=N(),a=z(),[r,u]=d.useState(!1),[l,p]=d.useState(!1),h=k(f=>U(f)),{configValue:x}=o(G.zeniAccountsConfig),i=ke(x);d.useEffect(()=>{l===!1&&t.state?.message==="activation"&&p(!0)},[t.state]);const c=S.getSignedInUserTenant(s)?.companyId??h.companyId,m=S.getSignedInUser(),C=!!h.companyZeniAccountInfo?.info?.isZeniAccountTOSAccepted,b=f=>{u(f)};if(m==null)throw Error("Can't access Zeni account promo page without signing in...");const g=te(),A=ee(g?.loggedInUserRoleMap),D=Ae(g?.loggedInUserRoleMap);if(C&&A)return n.jsx(X,{to:"../../checking/setup"});if(h.company?.companyZeniAccountInfo&&(!C&&A||D)){if(t.state?.message==="activation"){const f=an(t.state?.pathnameStackToGoBack);e(t.pathname,{state:{...t.state,message:void 0,pathnameStackToGoBack:f.newStack}})}return n.jsxs(n.Fragment,{children:[n.jsx(Et,{showConfetti:l}),n.jsx(ue,{analytics:R,onLoad:f=>(I=>I.trackPageLoaded(be.Event.accountsPromoPageViewed))(f)}),n.jsx(pe,{isAppContentDrawerOpen:r,handleDrawerToggle:b}),n.jsx(da,{analytics:R,navigate:e,companyId:c,onClickMenuIcon:()=>{b(!0)},maxAnnualPercentageYield:i.maxAnnualPercentageYield,maxInsuredAmount:i.maxInsuredAmount,exampleBankBalance:3e6})]})}return n.jsx(de,{fetchState:"In-Progress",style:{backgroundColor:a.colors.grey5}})};function Ma(){const e=W(),t=k(P=>U(P)),s=z(),{useFeatureGate:o,useDynamicConfig:a}=N(),r=te(),u=ee(r?.loggedInUserRoleMap),l=Ae(r?.loggedInUserRoleMap),p=!!t.company?.companyZeniAccountInfo.isZeniAccountEnabled,h=!!t.company?.companyZeniAccountInfo.isZeniAccountTOSAccepted,{isFeatureEnabled:x}=o(F.isChargeCardFeatureEnabled),{isFeatureEnabled:i}=o(F.isDebitCardFeatureEnabled),c=Xe(t),m=De(i,t),C=t?.userRole!=null&&ut(t?.userRole),b=(t?.company==null||t.company.featuresActivationInfo?.isBillPayFeatureEnabled&&!C)&&pt(r?.loggedInUserRoleMap),g=mt(r?.loggedInUserRoleMap),A=(t?.company==null||t.company.featuresActivationInfo?.isReimbursementFeatureEnabled&&!C)&&ht(r?.loggedInUserRoleMap),{isFeatureEnabled:D}=o(F.isDepositAccountsFeatureEnabled),f=D&&!C,{configValue:I}=a(G.expressPayConfig),O=I.is_enable_all_tenants===!0||I.tenant_ids!=null&&I.tenant_ids.includes(t.tenantId),{isFeatureEnabled:L}=o(F.isAutoTransferRuleEnabled),j=Pt(t,x,i)&&!C&>(r?.loggedInUserRoleMap),v=ft(r?.loggedInUserRoleMap),E=f&&ee(r?.loggedInUserRoleMap),T=E||Ne(r?.loggedInUserRoleMap);return n.jsxs(Ve,{children:[n.jsx(w,{path:"setup",element:n.jsx(Me,{isBillPayAdminLevelAccess:b,isUserHasOnlyBillPayAccess:g,isReimbursementAdminLevelAccess:A,isZeniAccountAdminLevelAccess:E,isChargeCardAdminLevelAccess:j,isUserHasOnlyCardAccess:v,productType:"zeni_accounts",type:"setup"})}),n.jsx(w,{path:"verification",element:n.jsx(Me,{isBillPayAdminLevelAccess:b,isUserHasOnlyBillPayAccess:g,isReimbursementAdminLevelAccess:A,isZeniAccountAdminLevelAccess:E,isChargeCardAdminLevelAccess:j,isUserHasOnlyCardAccess:v,productType:"zeni_accounts",type:"verification"})}),L?n.jsxs(n.Fragment,{children:[n.jsx(w,{path:"auto-transfer",element:n.jsx(_e,{})}),T?n.jsx(w,{path:"auto-transfer/:ruleId/edit",element:n.jsx(_e,{isEditDrawerOpen:!0})}):null]}):n.jsx(w,{path:"auto-transfer",element:n.jsx(ie,{})}),O&&u?n.jsxs(n.Fragment,{children:[n.jsx(w,{path:"express-pay",element:n.jsx(se,{})}),n.jsx(w,{path:"express-pay/add-ach",element:n.jsx(se,{isAddACHDrawerOpen:!0})}),n.jsx(w,{path:"express-pay/add-wire/add-address",element:n.jsx(se,{isAddAddressDrawerOpen:!0})}),n.jsx(w,{path:"express-pay/add-wire",element:n.jsx(se,{isAddWireDrawerOpen:!0})})]}):n.jsx(w,{path:"express-pay",element:n.jsx(ie,{})}),n.jsx(w,{path:"promo",element:n.jsx(ua,{})}),c&&!m?n.jsx(w,{path:"/*",element:n.jsx(sn,{})}):p?n.jsxs(n.Fragment,{children:[n.jsx(w,{path:"/",element:n.jsx(xe,{})}),n.jsx(w,{path:"transfer",element:n.jsx(xe,{isTransferDrawerOpen:!0})}),n.jsx(w,{path:"check-deposit",element:n.jsx(xe,{isCheckDepositDrawerOpen:!0})}),n.jsx(w,{path:":accountId/*",element:n.jsx(pa,{})}),n.jsx(w,{path:"*",element:n.jsx(ie,{})})]}):h&&u?n.jsx(w,{path:"*",element:n.jsx(X,{to:"../setup"})}):t.company?.companyZeniAccountInfo&&l?n.jsx(w,{path:"*",element:n.jsx(X,{to:"../promo",state:e.state})}):n.jsx(w,{path:"*",element:n.jsx(de,{fetchState:"In-Progress",style:{backgroundColor:s.colors.grey5,boxShadow:`0px 2px ${jt.sp1} ${s.colors.dropShadowNormal}`}})})]})}function pa(){return n.jsxs(Ve,{children:[n.jsx(w,{path:"/",element:n.jsx(re,{})}),n.jsx(w,{path:"account-info",element:n.jsx(re,{isAccountInfoDrawerOpen:!0})}),n.jsx(w,{path:"transfer",element:n.jsx(re,{isTransferDrawerOpen:!0})}),n.jsx(w,{path:"check-deposit",element:n.jsx(re,{isCheckDepositDrawerOpen:!0})}),n.jsx(w,{path:"statements",element:n.jsx(Rt,{})}),n.jsx(w,{path:"*",element:n.jsx(ie,{})})]})}export{Ma as default};
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
import{j as i}from"./liveblocks-DIG_sQTS.js";import{a as u}from"./sentry-DeeuWfnQ.js";import{h as x,u as j,g as B,i as $,j as p}from"./core-BQD7Nh1h.js";import{IG as s,IF as v,OV as C,eP as P,OW as T}from"./zeni-epic-state-DPMNRP9z.js";import{J as z,at as g,h as D,z as E,B as L,c4 as G,j as N}from"./index-NqZwiQK9.js";import{n as _}from"./mui-BTlbyoml.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]="b93da8c0-9dcc-47cf-9a9e-fa9288cb5d30",e._sentryDebugIdIdentifier="sentry-dbid-b93da8c0-9dcc-47cf-9a9e-fa9288cb5d30")}catch{}})();const U=_.div`
|
|
2
|
-
display: flex;
|
|
3
|
-
height: 100vh;
|
|
4
|
-
width: 100%;
|
|
5
|
-
flex: 1 1 auto;
|
|
6
|
-
flex-direction: column;
|
|
7
|
-
align-items: center;
|
|
8
|
-
background-color: ${e=>e.theme.colors.grey4};
|
|
9
|
-
`;function W(){const e=x(),n=j(),d=z(),l=B();let{accountId:a}=$(),f=`${g.bankingMicroServiceBaseUrl}/1.0/deposit-accounts/${a}`;a==null&&l.pathname.includes(`${s}/statements`)&&(a=s,f=`${g.bankingMicroServiceBaseUrl}/1.0/${s}`);const[m,y]=u.useState(!1),h=D();u.useEffect(()=>{m||(y(!0),n(v(a??"",!1)))},[m,n]);const o=p(t=>C(t,a??"")),I=()=>{const t=N(l.state?.pathnameStackToGoBack),S=t.poppedPathname??"..";e(S,{state:{pathnameStackToGoBack:t.newStack}})},c=E.getSignedInUser(),r=p(t=>P(t)),b={userId:c?.userId??"",sessionId:c?.zeniSessionId??"",tenantId:r.tenantId??""},w=T(a??"")===!0?s:o.zeniAccountDetail?.accountLast4??"",k=r.company?.companyInfo.companyLegalName??r.companyName;if(c==null)throw Error("Can't access address page without signing in...");return o.fetchState!=="Completed"?i.jsx(L,{fetchState:"In-Progress",style:{backgroundColor:h.colors.grey5}}):i.jsx(U,{windowSize:d,children:i.jsx(G,{currentTenantCompanyName:k,statementListView:o,accountLast4:w,onBackClick:I,authParams:b,downloadEndPoint:f})})}export{W as Z};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{cH as m,cI as l,JB as _,JC as d}from"./zeni-epic-state-DPMNRP9z.js";import{c as u}from"./index-NqZwiQK9.js";import"./sentry-DeeuWfnQ.js";(function(){try{var a=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},e=new a.Error().stack;e&&(a._sentryDebugIds=a._sentryDebugIds||{},a._sentryDebugIds[e]="6a86137a-f870-4a19-ab5f-fcda0b1a9ea5",a._sentryDebugIdIdentifier="sentry-dbid-6a86137a-f870-4a19-ab5f-fcda0b1a9ea5")}catch{}})();const b=a=>{switch(a){case"this_month_to_date":case"this_week_to_date":case"this_year_to_date":case"last_year":case"last_week":case"last_month":case"last_6_months":case"last_3_months":case"last_12_months":case"free_range":return a;case"month":default:return"months";case"quarter":return"quarters";case"year":return"years"}},h=(a,e,o,i,s)=>{const r=[],c=[];let t=[];s?.forEach(n=>{r.push(n.companyId),c.push(n.companyName),t=t.concat(n.userRole)}),u.identify(a.userId,{tenant_id:e.tenantId,tenant_email_domain:e.tenantEmailDomain,company_id:e.companyId,company_name:e.companyName,user_role:e.userRole,chargebee_customer_id:i,$email:a.userEmail,user_email_domain:a.userEmailDomain,$first_name:a.firstName,$last_name:a.lastName,company_ids:s!=null?r:void 0,company_names:s!=null?c:void 0,user_roles:s!=null?t:void 0,app_type:"web",appearance:o})},g=(a,e)=>m(a,e)?"bill_pay":l(a,e)?"reimbursement":_(a,e)?"zeni_accounts":d(a,e)?"charge_cards":"bill_pay",I=a=>Object.values(a.allocation).map(String).join("-");export{I as a,h as f,g,b as t};
|