@zeniai/web-app-ui 5.1.60-qa → 5.1.61-qa
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/AddressRoutes-DYu6X0mE.js +1 -0
- package/dist/assets/{AddressScreen-FgxQZ6Pn.js → AddressScreen-DmitYkw7.js} +1 -1
- package/dist/assets/{AiCfoScreen-CZfRGF0l.js → AiCfoScreen-It5Iqwvu.js} +1 -1
- package/dist/assets/{BillPayApprovalRoutes-DxR0TAud.js → BillPayApprovalRoutes-BzW0b3Z-.js} +1 -1
- package/dist/assets/{BillPayRoutes-CxBU4_Qt.js → BillPayRoutes-BM10Ap-2.js} +1 -1
- package/dist/assets/{BusinessVerificationPageScreen-CsuP5vKP.js → BusinessVerificationPageScreen-tq2Pq8-k.js} +1 -1
- package/dist/assets/{CardsAiCfoScreen-BJGdQu7N.js → CardsAiCfoScreen-DWCPoMx2.js} +1 -1
- package/dist/assets/{ChargeCardRoutes-DV0rSLTc.js → ChargeCardRoutes-BKpbGgWX.js} +1 -1
- package/dist/assets/{CompanyPassportScreen-MkVkCyf-.js → CompanyPassportScreen-CdbgEPbH.js} +1 -1
- package/dist/assets/{ConnectionAuthScreen-BZSmdXjw.js → ConnectionAuthScreen-B6ApFE5A.js} +1 -1
- package/dist/assets/CustomerOnboardingAuthScreen-BC6kPGo0.js +1 -0
- package/dist/assets/CustomerOnboardingRoutes-DC4e3Ogu.js +30 -0
- package/dist/assets/{DashboardRoutes-CF_VnugU.js → DashboardRoutes-BpHU2Qkf.js} +1 -1
- package/dist/assets/{DefaultTenantHome-DDp58t5d.js → DefaultTenantHome-TmE6YsRf.js} +1 -1
- package/dist/assets/{DomesticWireDetailScreen-DJG5dj2b.js → DomesticWireDetailScreen-Bg4mE0II.js} +1 -1
- package/dist/assets/{DrawerScreen-Q_os61z4.js → DrawerScreen-Q_Fkogtz.js} +1 -1
- package/dist/assets/{EntityDetailRoutes-DWaZ2x0h.js → EntityDetailRoutes-FVCOQ4xF.js} +1 -1
- package/dist/assets/{ExpenseAutomationRoutes-BAGScNm2.js → ExpenseAutomationRoutes-CGrxhlUE.js} +1 -1
- package/dist/assets/{FeaturePreviewScreen-BsLL5iCn.js → FeaturePreviewScreen-D35UAPet.js} +1 -1
- package/dist/assets/{HubSpotOAuthCallbackScreen-OGK79MYJ.js → HubSpotOAuthCallbackScreen-CqLWzeL5.js} +1 -1
- package/dist/assets/{MagicLinkRoutes-DPOV0bqy.js → MagicLinkRoutes-Cy9sY1KO.js} +1 -1
- package/dist/assets/{MagicLinkSignInScreen-DIaQ6IJE.js → MagicLinkSignInScreen-CTQVJ1D1.js} +1 -1
- package/dist/assets/{MobileAppDrawer-DQwHFEP8.js → MobileAppDrawer-DChLZMjE.js} +1 -1
- package/dist/assets/NotFoundScreen-DRRoMVDk.js +1 -0
- package/dist/assets/{NotificationRoutes-BLkbRobx.js → NotificationRoutes-DC-UVqrq.js} +1 -1
- package/dist/assets/{OAuthConsentScreen-B21EksvD.js → OAuthConsentScreen-DXJTz5MU.js} +1 -1
- package/dist/assets/{PandLWithForecastRoutes-ClN_7czZ.js → PandLWithForecastRoutes-DtN54cOv.js} +1 -1
- package/dist/assets/{PeopleRoutes-BBk6x3GN.js → PeopleRoutes-DM0B31yg.js} +1 -1
- package/dist/assets/{PerformanceRoutes-BpOIoQ_l.js → PerformanceRoutes-yT4nKfMt.js} +1 -1
- package/dist/assets/{Preview-dDFLUSBQ.js → Preview-DgYvT3D-.js} +1 -1
- package/dist/assets/{QBOConnectionScreen-BmcSCHav.js → QBOConnectionScreen-Dxk5EKMF.js} +1 -1
- package/dist/assets/{ReferralListScreen-CXbObkR0.js → ReferralListScreen-DoZyTHjO.js} +1 -1
- package/dist/assets/{ReimbursementApprovalRoutes-C7YE-LAA.js → ReimbursementApprovalRoutes-AEJXMIeN.js} +1 -1
- package/dist/assets/{ReimbursementApprovalRuleDetailScreen-Q0l5mvWj.js → ReimbursementApprovalRuleDetailScreen-Btjx5v4l.js} +1 -1
- package/dist/assets/{ReimbursementRoutes-DcDcmnq5.js → ReimbursementRoutes-CLjD-rz3.js} +1 -1
- package/dist/assets/{ReportsRoutes-BMAOx8yk.js → ReportsRoutes-DIvKwgKT.js} +1 -1
- package/dist/assets/{RewardsRoutes-Cz7znVbs.js → RewardsRoutes-B_SjWYxl.js} +1 -1
- package/dist/assets/{ScreenRoutes-Uy0Kxm7R.js → ScreenRoutes-DrzMUCeq.js} +2 -2
- package/dist/assets/{SettingsRoutes-DVfn4HMx.js → SettingsRoutes-CwZJeFhH.js} +1 -1
- package/dist/assets/{SetupPagesScreen-CVepw64Y.js → SetupPagesScreen-DHP6inkV.js} +1 -1
- package/dist/assets/{SignInScreen-CA6G7f6o.js → SignInScreen-B5h77NMY.js} +1 -1
- package/dist/assets/{SignOutScreen-B7LAzkpH.js → SignOutScreen-MsTaSP0q.js} +1 -1
- package/dist/assets/{TaskListScreen-BYXHdSHM.js → TaskListScreen-BDTDGrzi.js} +1 -1
- package/dist/assets/{TaskRoutes-0COd9gMj.js → TaskRoutes-CNamnrYQ.js} +1 -1
- package/dist/assets/{TransactionDetailRoutes-B7hwRUTE.js → TransactionDetailRoutes-DWs1Egcj.js} +1 -1
- package/dist/assets/{TransactionDetailScreen-BLBk60iy.js → TransactionDetailScreen-BbsGsqi_.js} +1 -1
- package/dist/assets/{TransactionListRoutes-CU2IvbfK.js → TransactionListRoutes-Co9duxwX.js} +1 -1
- package/dist/assets/{TreasuryRoutes-nOHCoa6D.js → TreasuryRoutes-B_Dv4GZ7.js} +1 -1
- package/dist/assets/{VendorsRoutes-Bms7VhV2.js → VendorsRoutes-puD2Dgk7.js} +1 -1
- package/dist/assets/{WiseConfirmationScreen-DgOnupdP.js → WiseConfirmationScreen-DAi_rrl_.js} +1 -1
- package/dist/assets/{ZeniAccountRoutes-rCwoYBVh.js → ZeniAccountRoutes-CbulRVVe.js} +1 -1
- package/dist/assets/{ZeniAccountStatementScreen-DnZ2Bj4h.js → ZeniAccountStatementScreen-DbJvbotJ.js} +1 -1
- package/dist/assets/{accountMappingHelper-BBILjeHz.js → accountMappingHelper-BPz1owqi.js} +1 -1
- package/dist/assets/{analytics-BlxwN6GD.js → analytics-C-A3qVJh.js} +1 -1
- package/dist/assets/{analyticsHelper-CrGhWq9e.js → analyticsHelper-CewoJ3Hu.js} +1 -1
- package/dist/assets/{core-Ctjv24YM.js → core-SRRzy8qJ.js} +1 -1
- package/dist/assets/{decodeURIComponentSafe-Z8As9uQN.js → decodeURIComponentSafe-Bz-26BXW.js} +1 -1
- package/dist/assets/{dnd-DdE4ICzz.js → dnd-CR8sMRK3.js} +1 -1
- package/dist/assets/{empty-Cgmg-ODN.js → empty-BjaZv87n.js} +1 -1
- package/dist/assets/{empty-BgBFHjf_.js → empty-Btqk4ZK3.js} +1 -1
- package/dist/assets/{emptyVideoElement-BxJPDgaA.js → emptyVideoElement-CcSCePHi.js} +1 -1
- package/dist/assets/{epic-D1NCPIYf.js → epic-DDYIjE2A.js} +1 -1
- package/dist/assets/{getLocaleForTenant-DnliJT-u.js → getLocaleForTenant-DHWNDQcY.js} +1 -1
- package/dist/assets/{index-B6LHkFfA.js → index-6PBzTIZ2.js} +1 -1
- package/dist/assets/{index-BJyv5Z6x.js → index-BnX1nS7p.js} +85 -85
- package/dist/assets/{index-DN_Tvj5e.js → index-CEFX9nem.js} +1 -1
- package/dist/assets/{index-DZAo63F3.js → index-CejiZfG4.js} +1 -1
- package/dist/assets/{index-Brx9Hk6c.js → index-CxtVVz4g.js} +1 -1
- package/dist/assets/{index-DrylXWCT.js → index-DiKyQs4W.js} +1 -1
- package/dist/assets/{index-D5yqrruP.js → index-JPErnqsm.js} +2 -2
- package/dist/assets/{index-hzMyClsK.js → index-rTYnRLvf.js} +1 -1
- package/dist/assets/{lexical-z-P2V9ug.js → lexical-qJrDnJMV.js} +1 -1
- package/dist/assets/{liveblocks-UQZFqaDN.js → liveblocks-DS8sOLD1.js} +1 -1
- package/dist/assets/{lottie-h9wdJ9gi.js → lottie-Coq2aDEW.js} +1 -1
- package/dist/assets/{mui-DU4JyJ-_.js → mui-DQ-jfgFM.js} +1 -1
- package/dist/assets/{pathToGoBack-dHZq4iEC.js → pathToGoBack-BmSmVqnZ.js} +1 -1
- package/dist/assets/{pdf-BK4Cbxeo.js → pdf-D2Xq7623.js} +4 -4
- package/dist/assets/{pdf-lib-BWuwD2_b.js → pdf-lib-fB9Fkl6A.js} +1 -1
- package/dist/assets/{plaid-Dtkg2fMC.js → plaid-DWZgMqW3.js} +1 -1
- package/dist/assets/{pusher-BRkEMaTd.js → pusher-Xj81uOBz.js} +1 -1
- package/dist/assets/{react-DDqHZ_bg.js → react-BlqDZveQ.js} +1 -1
- package/dist/assets/{react-BEV1hQDm.js → react-CgdBA-iC.js} +1 -1
- package/dist/assets/{react-lX-1Fc9t.js → react-DRyTZBkZ.js} +1 -1
- package/dist/assets/{react-BTEnGEot.js → react-DrjKWElm.js} +1 -1
- package/dist/assets/{react-Tzoiwmeg.js → react-DyXk5i5q.js} +1 -1
- package/dist/assets/{react-B6jUeEM2.js → react-eGjCUI9Z.js} +1 -1
- package/dist/assets/{recharts-RL5R0Iqz.js → recharts-CHATJmXy.js} +1 -1
- package/dist/assets/{routePaths-C7N5VwuK.js → routePaths-DyfF54Mg.js} +1 -1
- package/dist/assets/{sentry-C0E1AQIe.js → sentry-B2Aew07S.js} +1 -1
- package/dist/assets/{url-DASTrDxO.js → url-BOKPP8B2.js} +1 -1
- package/dist/assets/{url-B8pn9E20.js → url-BfvldWlU.js} +1 -1
- package/dist/assets/{useAiCfoDashboardSuggestedQuestionsChips-BguLij7r.js → useAiCfoDashboardSuggestedQuestionsChips-DiiAXpvy.js} +1 -1
- package/dist/assets/{useAskAiCfoHostNavButtonProps-DZ2VqCuW.js → useAskAiCfoHostNavButtonProps-RYFll1PC.js} +1 -1
- package/dist/assets/{useCashManagementBanner-Cg-NIFnV.js → useCashManagementBanner-DeSZsTvv.js} +1 -1
- package/dist/assets/{useChargeCardPusherEvents-CaVuS_Mc.js → useChargeCardPusherEvents-iVaYEDl9.js} +1 -1
- package/dist/assets/{useDeviceId-_WmC04ST.js → useDeviceId-obtSvxuy.js} +1 -1
- package/dist/assets/{useEmailConnectResultRefresh-BJvktFhn.js → useEmailConnectResultRefresh-DEaO6bJX.js} +1 -1
- package/dist/assets/{useInitialThreadRequest-B13VgkiL.js → useInitialThreadRequest-8loDIspA.js} +1 -1
- package/dist/assets/{utils-hcCBORos.js → utils-D8kKiFqT.js} +1 -1
- package/dist/assets/{withTransactionSidePanel-Dj5HWFje.js → withTransactionSidePanel-CpddR0Hs.js} +1 -1
- package/dist/assets/{zeni-epic-state-ym9j-rvL.js → zeni-epic-state-DcKqCCCg.js} +3 -3
- package/dist/index.html +1 -1
- package/package.json +1 -1
- package/dist/assets/AddressRoutes-RF8G7l2e.js +0 -1
- package/dist/assets/CustomerOnboardingAuthScreen-xBcb8Thx.js +0 -1
- package/dist/assets/CustomerOnboardingRoutes-B7Fnla-Z.js +0 -30
- package/dist/assets/NotFoundScreen-DtHa7L00.js +0 -1
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as d}from"./liveblocks-UQZFqaDN.js";import{i as K,j as k,g as H,u as z,h as W,n as ee,k as ia,o as Ct,p as P}from"./core-Ctjv24YM.js";import{eV as L,Ng as We,bE as ca,bo as xe,Ou as On,iY as Pn,Ov as Zt,Ow as Fn,i$ as _t,Ox as qe,Oy as Rn,j4 as Bn,Oz as qt,OA as jn,j8 as kt,OB as Qe,OC as Mn,co as vt,OD as Un,OE as Ln,NA as Gn,k0 as Vn,OF as Yn,bn as Xe,OG as la,N4 as ce,bc as da,ke as ua,oe as ma,jZ as pa,N6 as le,N5 as J,eU as ha,fo as Nn,g0 as St,OH as $n,OI as zn,OJ as fa,OK as Fe,vM as Ue,vN as Le,w8 as De,w2 as de,vR as Ge,OL as Kn,OM as Zn,ON as qn,OO as ga,OP as Re,OQ as Qn,dI as Je,s7 as ba,OR as Hn,OS as Wn,OT as Xn,OU as At,Mm as It,ku as we,wg as Et,sf as Jn,OV as eo,vO as Qt,sa as Ee,s6 as Ca,OW as ge,OX as to,OY as Tt,Ml as xt,uf as _a,OZ as ao,O_ as no,O$ as oo,P0 as Dt,us as so,P1 as ro,vQ as Ht,ue as ka,P2 as be,P3 as io,bs as Sa,wk as ya,P4 as co,P5 as lo,P6 as uo,P7 as wt,wf as mo,P8 as po,vP as Wt,wj as va,P9 as Ce,Pa as ho,Pb as fo,Pc as Aa,kj as Ia,ob as Ea,ko as Ta,o9 as xa,o8 as Da,o7 as wa,tD as go,fS as bo,cR as Co,cS as _o,o4 as ko,fO as So,ol as yo,Gy as ut,Gq as vo,Gu as Ao,Pd as Io,Pe as Eo,Pf as To,b5 as et,fG as xo,hG as Do,gg as wo,of as Oo,jS as Po,oc as Fo,oa as Ro,fA as Bo,fy as jo}from"./zeni-epic-state-ym9j-rvL.js";import{z as M,a2 as te,s as D,d as T,a as Z,aY as Mo,Z as Ve,x as Ye,aZ as Oa,f as N,a_ as Uo,I as ke,a$ as Pa,W as Se,U as B,m as Lo,b0 as Go,b1 as Vo,Q as Fa,q as Ra,c as Ba,X as Yo,b2 as No,K as $o,aQ as ja,_ as se,b3 as Ma,b4 as Ua,a1 as La,b5 as zo,b6 as Ko,B as Zo,ar as qo,k as Qo,V as Ho,b7 as Wo,b8 as Xo,b9 as Jo,ba as es,bb as _e}from"./index-BJyv5Z6x.js";import{n as Ot}from"./mui-DU4JyJ-_.js";import{a as b}from"./sentry-C0E1AQIe.js";import{w as Ga}from"./withTransactionSidePanel-Dj5HWFje.js";import{c as Va,t as Oe,f as ue,a as Pt,v as ts}from"./routePaths-C7N5VwuK.js";import{u as ae}from"./useAskAiCfoHostNavButtonProps-DZ2VqCuW.js";import Me from"./NotFoundScreen-DtHa7L00.js";import{u as Ft}from"./useInitialThreadRequest-B13VgkiL.js";import{t as Ya}from"./analyticsHelper-CrGhWq9e.js";import{C as as}from"./CompanyPassportScreen-MkVkCyf-.js";import{u as ns}from"./useAiCfoDashboardSuggestedQuestionsChips-BguLij7r.js";import{F as os}from"./FeaturePreviewScreen-BsLL5iCn.js";import{R as ss}from"./ReferralListScreen-CXbObkR0.js";import"./recharts-RL5R0Iqz.js";import"./analytics-BlxwN6GD.js";import"./plaid-Dtkg2fMC.js";import"./dnd-DdE4ICzz.js";import"./stripe-DMRn4zHo.js";import"./lottie-h9wdJ9gi.js";import"./lexical-z-P2V9ug.js";import"./pdf-BK4Cbxeo.js";import"./utils-hcCBORos.js";import"./TransactionDetailScreen-BLBk60iy.js";import"./decodeURIComponentSafe-Z8As9uQN.js";import"./MobileAppDrawer-DQwHFEP8.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]="c04cb67b-c185-48a3-9640-80a5e0a2b819",e._sentryDebugIdIdentifier="sentry-dbid-c04cb67b-c185-48a3-9640-80a5e0a2b819")}catch{}})();const rs=Ga(function({openTransactionPanel:e,panelContent:a,sidePanelIsOpen:t,sidePanelIsFullView:n}){const{vendorId:o,reportDate:r}=K(),s=M.getSignedInUser(),i=k(I=>I.tenantState.currentTenantId),c=k(I=>L(I)),{tenantEmailDomain:m}=K(),g=H(),C=c?.companyName??"",u={userId:s?.userId??"",sessionId:s?.zeniSessionId??"",tenantId:i??""},l=b.useMemo(()=>({authParams:u,companyName:C,downloadEndPoint:`${te}/agingDetailedReport`,timezone:We()}),[]),h=b.useMemo(()=>r!=null?ca(r):xe(),[r]),p=z(),f=W(),S=k(I=>On(I,h,o)),E=b.useCallback(()=>{o!=null&&S.fetchState!=="In-Progress"&&S.fetchState!=="Completed"&&p(Pn(o,h))},[h]),v=b.useCallback(()=>{f("../../",{relative:"path"})},[]),_=b.useCallback((I,U)=>{p(Zt({sortKey:I,sortOrder:U}))},[]),x=b.useCallback(I=>{p(Zt({downloadState:I}))},[]),w=b.useCallback(I=>{if(e)e(I.transactionId,I.transactionType);else if(m!=null){const U=Va({id:I.transactionId,type:I.transactionType},m);f(U);const ne=D(g.state?.pathnameStackToGoBack,g.pathname);f(U,{state:{pathnameStackToGoBack:ne}})}},[m,e]),y=b.useCallback(()=>{S.vendor!=null&&T.trackApAgingDetail("AP Aging",h.format(Z.getLocalizedStrings().dateFormat.analytics.YYYYDashMMDashDDFormat),S.vendor.id,S.vendor.name)},[S.vendor,h]);return b.useEffect(()=>{E()},[]),b.useEffect(()=>{S.fetchState==="Completed"&&y()},[y,S.fetchState]),d.jsx(Mo,{apAgingDetail:S,downloadParams:l,reportDate:h,analytics:T,onTransactionClick:w,onReload:E,onBackClick:v,onColumnSortConfigChanged:_,updateDownloadStateHandler:x,panelContent:a,sidePanelIsOpen:t,sidePanelIsFullView:n})}),is=()=>{const e=z(),a=W(),t=k(_=>Fn(_)),{isAiCfoAccessEnabled:n,onAskAiCfoClick:o}=ae({mobileExploreReferrer:"AP Aging"});Ve({isDataReady:t.fetchState==="Completed"});const r=M.getSignedInUser(),s=k(_=>_.tenantState.currentTenantId),i=k(_=>L(_)),c=i?.companyName??"",m={userId:r?.userId??"",sessionId:r?.zeniSessionId??"",tenantId:s??""},g=b.useMemo(()=>({authParams:m,companyName:c,downloadEndPoint:`${te}/agingReport`,timezone:We()}),[]),C=t.apAgingUIState.selectedDate??xe(),u=b.useCallback(()=>{t.fetchState!=="In-Progress"&&t.fetchState!=="Completed"&&e(_t(C))},[]);b.useEffect(()=>{u()},[]);const l=b.useCallback(()=>{a("../",{relative:"path"})},[]),h=b.useCallback(_=>{e(qe({searchString:_}))},[]),p=b.useCallback((_,x)=>{e(qe({sortKey:x,sortOrder:_}))},[]),f=b.useCallback(_=>{a(`./${_}/${C.format(Z.getLocalizedStrings().dateFormat.analytics.YYYYDashMMDashDDFormat)}`)},[C]),S=b.useCallback(_=>{e(qe({downloadState:_}))},[]),E=b.useCallback((_,x)=>{},[]),v=b.useCallback((_,x)=>{e(qe({selectedDate:_,agingDateSelectionType:x})),e(_t(_))},[]);return d.jsxs(d.Fragment,{children:[t.fetchState==="Completed"?d.jsx(Ye,{analytics:T,onLoad:_=>_.trackPageLoaded(N.Event.agingReport,"AP Aging")}):null,d.jsx(Oa,{uiState:t.apAgingUIState,report:t,downloadParams:g,analytics:T,onReloadReport:u,onBackClick:l,onSearchTextChange:h,onSortOrderChange:p,onEntityNameClick:f,updateDownloadStateHandler:S,onSelectedDateChanged:v,onNodeCollapseToggled:E,isAiCfoAccessEnabled:n,onAskAiCfoClick:o})]})},cs=Ga(function({openTransactionPanel:e,panelContent:a,sidePanelIsOpen:t,sidePanelIsFullView:n}){const{customerId:o,reportDate:r}=K(),s=M.getSignedInUser(),i=k(y=>L(y)),{tenantEmailDomain:c}=K(),m=H(),g=i.companyName,C={userId:s?.userId??"",sessionId:s?.zeniSessionId??"",tenantId:i.tenantId},u=b.useMemo(()=>({authParams:C,companyName:g,downloadEndPoint:`${te}/agingDetailedReport`,timezone:We()}),[]),l=b.useMemo(()=>r!=null?ca(r):xe(),[r]),h=z(),p=W(),f=k(y=>Rn(y,l,o)),S=b.useCallback(()=>{o!=null&&f.fetchState!=="In-Progress"&&f.fetchState!=="Completed"&&h(Bn(o,l))},[l]),E=b.useCallback(()=>{p("../../",{relative:"path"})},[]),v=b.useCallback((y,I)=>{h(qt({sortKey:y,sortOrder:I}))},[]),_=b.useCallback(y=>{h(qt({downloadState:y}))},[]),x=b.useCallback(y=>{if(e)e(y.transactionId,y.transactionType);else if(c!=null){const I=Va({id:y.transactionId,type:y.transactionType},c);p(I);const U=D(m.state?.pathnameStackToGoBack,m.pathname);p(I,{state:{pathnameStackToGoBack:U}})}},[c,e]),w=b.useCallback(()=>{f.customer!=null&&T.trackArAgingDetail("AR Aging",l.format(Z.getLocalizedStrings().dateFormat.analytics.YYYYDashMMDashDDFormat),f.customer.id,f.customer.name)},[f.customer,l]);return b.useEffect(()=>{S()},[]),b.useEffect(()=>{f.fetchState==="Completed"&&w()},[f.fetchState,w]),d.jsx(Uo,{arAgingDetail:f,downloadParams:u,reportDate:l,analytics:T,onTransactionClick:x,onReload:S,onBackClick:E,onColumnSortConfigChanged:v,updateDownloadStateHandler:_,panelContent:a,sidePanelIsOpen:t,sidePanelIsFullView:n})}),ls=()=>{const e=z(),a=W(),t=k(v=>jn(v)),{isAiCfoAccessEnabled:n,onAskAiCfoClick:o}=ae({mobileExploreReferrer:"AR Aging"});Ve({isDataReady:t.fetchState==="Completed"});const r=M.getSignedInUser(),s=k(v=>L(v)),i=s.companyName,c={userId:r?.userId??"",sessionId:r?.zeniSessionId??"",tenantId:s.tenantId},m=b.useMemo(()=>({authParams:c,companyName:i,downloadEndPoint:`${te}/agingReport`,timezone:We()}),[]),g=t.arAgingUIState.selectedDate??xe(),C=b.useCallback(()=>{t.fetchState!=="In-Progress"&&t.fetchState!=="Completed"&&e(kt(g))},[]);b.useEffect(()=>{C()},[]);const u=b.useCallback(()=>{a("../",{relative:"path"})},[]),l=b.useCallback(v=>{e(Qe({searchString:v}))},[]),h=b.useCallback((v,_)=>{e(Qe({sortKey:_,sortOrder:v}))},[]),p=b.useCallback(v=>{a(`./${v}/${g.format(Z.getLocalizedStrings().dateFormat.analytics.YYYYDashMMDashDDFormat)}`)},[g]),f=b.useCallback(v=>{e(Qe({downloadState:v}))},[]),S=b.useCallback((v,_)=>{e(Qe({selectedDate:v,agingDateSelectionType:_})),e(kt(v))},[]),E=b.useCallback((v,_)=>{e(Mn({nodeId:v,isCollapsed:_}))},[]);return d.jsxs(d.Fragment,{children:[t.fetchState==="Completed"?d.jsx(Ye,{analytics:T,onLoad:v=>v.trackPageLoaded(N.Event.agingReport,"AR Aging")}):null,d.jsx(Oa,{uiState:t.arAgingUIState,report:t,downloadParams:m,analytics:T,onReloadReport:C,onBackClick:u,onSearchTextChange:l,onSortOrderChange:h,onEntityNameClick:p,updateDownloadStateHandler:f,onSelectedDateChanged:S,onNodeCollapseToggled:E,isAiCfoAccessEnabled:n,onAskAiCfoClick:o})]})},Na=(e,a)=>({key:a,title:e.accountName,amount:e.balance?.available,logoUri:e.logo?.toString(),source:e});function $a(e,a){const t=Gn(a.firstMonthOfFY);return{onItemClick:(n,o)=>{const r=o.accountName===""?o.accountDescription:o.accountName,s=Oe(a.tenantEmailDomain,o.accountId,o.accountType,r,"quarter",t,!1),i=D(a.location.state?.pathnameStackToGoBack,a.location.pathname);a.navigate(s,{state:{pathnameStackToGoBack:i,referrer:a.referrerType}})},onSetAccountsStatementDate:(n,o)=>{e(Vn(n,o))},onPromoCardBtnClick:n=>{if(a.isZeniAccountsAdmin){let o=`../../checking/${n}`;n?T.trackZeniAccountsCashBalancePromoClicked("Move Money"):(T.trackZeniAccountsCashBalancePromoClicked("Sign Up for Free"),o="../../checking/promo");const r=D(a.location.state?.pathnameStackToGoBack,a.location.pathname);a.navigate(o,{state:{pathnameStackToGoBack:r}})}else T.trackZeniAccountsCashBalancePromoClicked("Learn More"),window.open("https://www.zeni.ai/product/business-checking-accounts","_blank")}}}const ds=ee(function(e){const a=Un(e).accountsInOrder.map((n,o)=>Na(n,o)),t=Ln(e);return{sectionTitle:Z.getLocalizedStrings().balanceCard.cashBalanceSectionTitle,transactionArray:a,zeniAccountsPromoCardReport:t,fetchState:e.cashBalanceState.fetchState,analytics:T}},$a)(Pa),us=ee(function(e){const a=Yn(e).accountsInOrder.map((o,r)=>Na(o,r)),t=M.getSignedInUser(),n=Xe(t);return{sectionTitle:Z.getLocalizedStrings().balanceCard.cardBalanceSectionTitle,transactionArray:a,isZeniUser:n,fetchState:e.cardBalanceState.fetchState,analytics:T}},$a)(Pa);function ms(){const e=W(),a=H(),{tenantEmailDomain:t}=K(),n=ke(),o=k(s=>L(s).company?.companyInfo.firstMonthOfFY??1),r=vt(n?.loggedInUserRoleMap);return k(s=>s.cashBalanceState.fetchState)==="Error"?d.jsx(Me,{}):d.jsx(ds,{tenantEmailDomain:t,location:a,referrerType:"Cash Balance",navigate:e,isZeniAccountsAdmin:r,firstMonthOfFY:o})}function ps(){const e=W(),a=H(),{tenantEmailDomain:t}=K(),n=ke(),o=vt(n?.loggedInUserRoleMap),r=k(s=>L(s).company?.companyInfo.firstMonthOfFY??1);return k(s=>s.cardBalanceState.fetchState)==="Error"?d.jsx(Me,{}):d.jsx(us,{tenantEmailDomain:t,location:a,referrerType:"Card Balance",navigate:e,isZeniAccountsAdmin:o,firstMonthOfFY:r})}const hs=Ot.div`
|
|
1
|
+
import{j as d}from"./liveblocks-DS8sOLD1.js";import{i as K,j as k,g as H,u as z,h as W,n as ee,k as ia,o as Ct,p as P}from"./core-SRRzy8qJ.js";import{eV as L,Ng as We,bE as ca,bo as xe,Ou as On,iY as Pn,Ov as Zt,Ow as Fn,i$ as _t,Ox as qe,Oy as Rn,j4 as Bn,Oz as qt,OA as jn,j8 as kt,OB as Qe,OC as Mn,co as vt,OD as Un,OE as Ln,NA as Gn,k0 as Vn,OF as Yn,bn as Xe,OG as la,N4 as ce,bc as da,ke as ua,oe as ma,jZ as pa,N6 as le,N5 as J,eU as ha,fo as Nn,g0 as St,OH as $n,OI as zn,OJ as fa,OK as Fe,vM as Ue,vN as Le,w8 as De,w2 as de,vR as Ge,OL as Kn,OM as Zn,ON as qn,OO as ga,OP as Re,OQ as Qn,dI as Je,s7 as ba,OR as Hn,OS as Wn,OT as Xn,OU as At,Mm as It,ku as we,wg as Et,sf as Jn,OV as eo,vO as Qt,sa as Ee,s6 as Ca,OW as ge,OX as to,OY as Tt,Ml as xt,uf as _a,OZ as ao,O_ as no,O$ as oo,P0 as Dt,us as so,P1 as ro,vQ as Ht,ue as ka,P2 as be,P3 as io,bs as Sa,wk as ya,P4 as co,P5 as lo,P6 as uo,P7 as wt,wf as mo,P8 as po,vP as Wt,wj as va,P9 as Ce,Pa as ho,Pb as fo,Pc as Aa,kj as Ia,ob as Ea,ko as Ta,o9 as xa,o8 as Da,o7 as wa,tD as go,fS as bo,cR as Co,cS as _o,o4 as ko,fO as So,ol as yo,Gy as ut,Gq as vo,Gu as Ao,Pd as Io,Pe as Eo,Pf as To,b5 as et,fG as xo,hG as Do,gg as wo,of as Oo,jS as Po,oc as Fo,oa as Ro,fA as Bo,fy as jo}from"./zeni-epic-state-DcKqCCCg.js";import{z as M,a2 as te,s as D,d as T,a as Z,aY as Mo,Z as Ve,x as Ye,aZ as Oa,f as N,a_ as Uo,I as ke,a$ as Pa,W as Se,U as B,m as Lo,b0 as Go,b1 as Vo,Q as Fa,q as Ra,c as Ba,X as Yo,b2 as No,K as $o,aQ as ja,_ as se,b3 as Ma,b4 as Ua,a1 as La,b5 as zo,b6 as Ko,B as Zo,ar as qo,k as Qo,V as Ho,b7 as Wo,b8 as Xo,b9 as Jo,ba as es,bb as _e}from"./index-BnX1nS7p.js";import{n as Ot}from"./mui-DQ-jfgFM.js";import{a as b}from"./sentry-B2Aew07S.js";import{w as Ga}from"./withTransactionSidePanel-CpddR0Hs.js";import{c as Va,t as Oe,f as ue,a as Pt,v as ts}from"./routePaths-DyfF54Mg.js";import{u as ae}from"./useAskAiCfoHostNavButtonProps-RYFll1PC.js";import Me from"./NotFoundScreen-DRRoMVDk.js";import{u as Ft}from"./useInitialThreadRequest-8loDIspA.js";import{t as Ya}from"./analyticsHelper-CewoJ3Hu.js";import{C as as}from"./CompanyPassportScreen-CdbgEPbH.js";import{u as ns}from"./useAiCfoDashboardSuggestedQuestionsChips-DiiAXpvy.js";import{F as os}from"./FeaturePreviewScreen-D35UAPet.js";import{R as ss}from"./ReferralListScreen-DoZyTHjO.js";import"./recharts-CHATJmXy.js";import"./analytics-C-A3qVJh.js";import"./plaid-DWZgMqW3.js";import"./dnd-CR8sMRK3.js";import"./stripe-DMRn4zHo.js";import"./lottie-Coq2aDEW.js";import"./lexical-qJrDnJMV.js";import"./pdf-D2Xq7623.js";import"./utils-D8kKiFqT.js";import"./TransactionDetailScreen-BbsGsqi_.js";import"./decodeURIComponentSafe-Bz-26BXW.js";import"./MobileAppDrawer-DChLZMjE.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]="c04cb67b-c185-48a3-9640-80a5e0a2b819",e._sentryDebugIdIdentifier="sentry-dbid-c04cb67b-c185-48a3-9640-80a5e0a2b819")}catch{}})();const rs=Ga(function({openTransactionPanel:e,panelContent:a,sidePanelIsOpen:t,sidePanelIsFullView:n}){const{vendorId:o,reportDate:r}=K(),s=M.getSignedInUser(),i=k(I=>I.tenantState.currentTenantId),c=k(I=>L(I)),{tenantEmailDomain:m}=K(),g=H(),C=c?.companyName??"",u={userId:s?.userId??"",sessionId:s?.zeniSessionId??"",tenantId:i??""},l=b.useMemo(()=>({authParams:u,companyName:C,downloadEndPoint:`${te}/agingDetailedReport`,timezone:We()}),[]),h=b.useMemo(()=>r!=null?ca(r):xe(),[r]),p=z(),f=W(),S=k(I=>On(I,h,o)),E=b.useCallback(()=>{o!=null&&S.fetchState!=="In-Progress"&&S.fetchState!=="Completed"&&p(Pn(o,h))},[h]),v=b.useCallback(()=>{f("../../",{relative:"path"})},[]),_=b.useCallback((I,U)=>{p(Zt({sortKey:I,sortOrder:U}))},[]),x=b.useCallback(I=>{p(Zt({downloadState:I}))},[]),w=b.useCallback(I=>{if(e)e(I.transactionId,I.transactionType);else if(m!=null){const U=Va({id:I.transactionId,type:I.transactionType},m);f(U);const ne=D(g.state?.pathnameStackToGoBack,g.pathname);f(U,{state:{pathnameStackToGoBack:ne}})}},[m,e]),y=b.useCallback(()=>{S.vendor!=null&&T.trackApAgingDetail("AP Aging",h.format(Z.getLocalizedStrings().dateFormat.analytics.YYYYDashMMDashDDFormat),S.vendor.id,S.vendor.name)},[S.vendor,h]);return b.useEffect(()=>{E()},[]),b.useEffect(()=>{S.fetchState==="Completed"&&y()},[y,S.fetchState]),d.jsx(Mo,{apAgingDetail:S,downloadParams:l,reportDate:h,analytics:T,onTransactionClick:w,onReload:E,onBackClick:v,onColumnSortConfigChanged:_,updateDownloadStateHandler:x,panelContent:a,sidePanelIsOpen:t,sidePanelIsFullView:n})}),is=()=>{const e=z(),a=W(),t=k(_=>Fn(_)),{isAiCfoAccessEnabled:n,onAskAiCfoClick:o}=ae({mobileExploreReferrer:"AP Aging"});Ve({isDataReady:t.fetchState==="Completed"});const r=M.getSignedInUser(),s=k(_=>_.tenantState.currentTenantId),i=k(_=>L(_)),c=i?.companyName??"",m={userId:r?.userId??"",sessionId:r?.zeniSessionId??"",tenantId:s??""},g=b.useMemo(()=>({authParams:m,companyName:c,downloadEndPoint:`${te}/agingReport`,timezone:We()}),[]),C=t.apAgingUIState.selectedDate??xe(),u=b.useCallback(()=>{t.fetchState!=="In-Progress"&&t.fetchState!=="Completed"&&e(_t(C))},[]);b.useEffect(()=>{u()},[]);const l=b.useCallback(()=>{a("../",{relative:"path"})},[]),h=b.useCallback(_=>{e(qe({searchString:_}))},[]),p=b.useCallback((_,x)=>{e(qe({sortKey:x,sortOrder:_}))},[]),f=b.useCallback(_=>{a(`./${_}/${C.format(Z.getLocalizedStrings().dateFormat.analytics.YYYYDashMMDashDDFormat)}`)},[C]),S=b.useCallback(_=>{e(qe({downloadState:_}))},[]),E=b.useCallback((_,x)=>{},[]),v=b.useCallback((_,x)=>{e(qe({selectedDate:_,agingDateSelectionType:x})),e(_t(_))},[]);return d.jsxs(d.Fragment,{children:[t.fetchState==="Completed"?d.jsx(Ye,{analytics:T,onLoad:_=>_.trackPageLoaded(N.Event.agingReport,"AP Aging")}):null,d.jsx(Oa,{uiState:t.apAgingUIState,report:t,downloadParams:g,analytics:T,onReloadReport:u,onBackClick:l,onSearchTextChange:h,onSortOrderChange:p,onEntityNameClick:f,updateDownloadStateHandler:S,onSelectedDateChanged:v,onNodeCollapseToggled:E,isAiCfoAccessEnabled:n,onAskAiCfoClick:o})]})},cs=Ga(function({openTransactionPanel:e,panelContent:a,sidePanelIsOpen:t,sidePanelIsFullView:n}){const{customerId:o,reportDate:r}=K(),s=M.getSignedInUser(),i=k(y=>L(y)),{tenantEmailDomain:c}=K(),m=H(),g=i.companyName,C={userId:s?.userId??"",sessionId:s?.zeniSessionId??"",tenantId:i.tenantId},u=b.useMemo(()=>({authParams:C,companyName:g,downloadEndPoint:`${te}/agingDetailedReport`,timezone:We()}),[]),l=b.useMemo(()=>r!=null?ca(r):xe(),[r]),h=z(),p=W(),f=k(y=>Rn(y,l,o)),S=b.useCallback(()=>{o!=null&&f.fetchState!=="In-Progress"&&f.fetchState!=="Completed"&&h(Bn(o,l))},[l]),E=b.useCallback(()=>{p("../../",{relative:"path"})},[]),v=b.useCallback((y,I)=>{h(qt({sortKey:y,sortOrder:I}))},[]),_=b.useCallback(y=>{h(qt({downloadState:y}))},[]),x=b.useCallback(y=>{if(e)e(y.transactionId,y.transactionType);else if(c!=null){const I=Va({id:y.transactionId,type:y.transactionType},c);p(I);const U=D(m.state?.pathnameStackToGoBack,m.pathname);p(I,{state:{pathnameStackToGoBack:U}})}},[c,e]),w=b.useCallback(()=>{f.customer!=null&&T.trackArAgingDetail("AR Aging",l.format(Z.getLocalizedStrings().dateFormat.analytics.YYYYDashMMDashDDFormat),f.customer.id,f.customer.name)},[f.customer,l]);return b.useEffect(()=>{S()},[]),b.useEffect(()=>{f.fetchState==="Completed"&&w()},[f.fetchState,w]),d.jsx(Uo,{arAgingDetail:f,downloadParams:u,reportDate:l,analytics:T,onTransactionClick:x,onReload:S,onBackClick:E,onColumnSortConfigChanged:v,updateDownloadStateHandler:_,panelContent:a,sidePanelIsOpen:t,sidePanelIsFullView:n})}),ls=()=>{const e=z(),a=W(),t=k(v=>jn(v)),{isAiCfoAccessEnabled:n,onAskAiCfoClick:o}=ae({mobileExploreReferrer:"AR Aging"});Ve({isDataReady:t.fetchState==="Completed"});const r=M.getSignedInUser(),s=k(v=>L(v)),i=s.companyName,c={userId:r?.userId??"",sessionId:r?.zeniSessionId??"",tenantId:s.tenantId},m=b.useMemo(()=>({authParams:c,companyName:i,downloadEndPoint:`${te}/agingReport`,timezone:We()}),[]),g=t.arAgingUIState.selectedDate??xe(),C=b.useCallback(()=>{t.fetchState!=="In-Progress"&&t.fetchState!=="Completed"&&e(kt(g))},[]);b.useEffect(()=>{C()},[]);const u=b.useCallback(()=>{a("../",{relative:"path"})},[]),l=b.useCallback(v=>{e(Qe({searchString:v}))},[]),h=b.useCallback((v,_)=>{e(Qe({sortKey:_,sortOrder:v}))},[]),p=b.useCallback(v=>{a(`./${v}/${g.format(Z.getLocalizedStrings().dateFormat.analytics.YYYYDashMMDashDDFormat)}`)},[g]),f=b.useCallback(v=>{e(Qe({downloadState:v}))},[]),S=b.useCallback((v,_)=>{e(Qe({selectedDate:v,agingDateSelectionType:_})),e(kt(v))},[]),E=b.useCallback((v,_)=>{e(Mn({nodeId:v,isCollapsed:_}))},[]);return d.jsxs(d.Fragment,{children:[t.fetchState==="Completed"?d.jsx(Ye,{analytics:T,onLoad:v=>v.trackPageLoaded(N.Event.agingReport,"AR Aging")}):null,d.jsx(Oa,{uiState:t.arAgingUIState,report:t,downloadParams:m,analytics:T,onReloadReport:C,onBackClick:u,onSearchTextChange:l,onSortOrderChange:h,onEntityNameClick:p,updateDownloadStateHandler:f,onSelectedDateChanged:S,onNodeCollapseToggled:E,isAiCfoAccessEnabled:n,onAskAiCfoClick:o})]})},Na=(e,a)=>({key:a,title:e.accountName,amount:e.balance?.available,logoUri:e.logo?.toString(),source:e});function $a(e,a){const t=Gn(a.firstMonthOfFY);return{onItemClick:(n,o)=>{const r=o.accountName===""?o.accountDescription:o.accountName,s=Oe(a.tenantEmailDomain,o.accountId,o.accountType,r,"quarter",t,!1),i=D(a.location.state?.pathnameStackToGoBack,a.location.pathname);a.navigate(s,{state:{pathnameStackToGoBack:i,referrer:a.referrerType}})},onSetAccountsStatementDate:(n,o)=>{e(Vn(n,o))},onPromoCardBtnClick:n=>{if(a.isZeniAccountsAdmin){let o=`../../checking/${n}`;n?T.trackZeniAccountsCashBalancePromoClicked("Move Money"):(T.trackZeniAccountsCashBalancePromoClicked("Sign Up for Free"),o="../../checking/promo");const r=D(a.location.state?.pathnameStackToGoBack,a.location.pathname);a.navigate(o,{state:{pathnameStackToGoBack:r}})}else T.trackZeniAccountsCashBalancePromoClicked("Learn More"),window.open("https://www.zeni.ai/product/business-checking-accounts","_blank")}}}const ds=ee(function(e){const a=Un(e).accountsInOrder.map((n,o)=>Na(n,o)),t=Ln(e);return{sectionTitle:Z.getLocalizedStrings().balanceCard.cashBalanceSectionTitle,transactionArray:a,zeniAccountsPromoCardReport:t,fetchState:e.cashBalanceState.fetchState,analytics:T}},$a)(Pa),us=ee(function(e){const a=Yn(e).accountsInOrder.map((o,r)=>Na(o,r)),t=M.getSignedInUser(),n=Xe(t);return{sectionTitle:Z.getLocalizedStrings().balanceCard.cardBalanceSectionTitle,transactionArray:a,isZeniUser:n,fetchState:e.cardBalanceState.fetchState,analytics:T}},$a)(Pa);function ms(){const e=W(),a=H(),{tenantEmailDomain:t}=K(),n=ke(),o=k(s=>L(s).company?.companyInfo.firstMonthOfFY??1),r=vt(n?.loggedInUserRoleMap);return k(s=>s.cashBalanceState.fetchState)==="Error"?d.jsx(Me,{}):d.jsx(ds,{tenantEmailDomain:t,location:a,referrerType:"Cash Balance",navigate:e,isZeniAccountsAdmin:r,firstMonthOfFY:o})}function ps(){const e=W(),a=H(),{tenantEmailDomain:t}=K(),n=ke(),o=vt(n?.loggedInUserRoleMap),r=k(s=>L(s).company?.companyInfo.firstMonthOfFY??1);return k(s=>s.cardBalanceState.fetchState)==="Error"?d.jsx(Me,{}):d.jsx(us,{tenantEmailDomain:t,location:a,referrerType:"Card Balance",navigate:e,isZeniAccountsAdmin:o,firstMonthOfFY:r})}const hs=Ot.div`
|
|
2
2
|
display: flex;
|
|
3
3
|
flex: 1 1 auto;
|
|
4
4
|
min-height: 100%;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as v}from"./liveblocks-
|
|
1
|
+
import{j as v}from"./liveblocks-DS8sOLD1.js";import{a as u}from"./sentry-B2Aew07S.js";import{u as y,j as b,n as w,g as A,N as L}from"./core-SRRzy8qJ.js";import{LQ as N,eV as _,f_ as R,LR as U,o6 as k,LS as z}from"./zeni-epic-state-DcKqCCCg.js";import{u as j,z as f,L as T,t as I,a as O,b as $}from"./index-BnX1nS7p.js";import"./mui-DQ-jfgFM.js";import{t as P}from"./getLocaleForTenant-DHWNDQcY.js";import"./recharts-CHATJmXy.js";import"./analytics-C-A3qVJh.js";import"./plaid-DWZgMqW3.js";import"./dnd-CR8sMRK3.js";import"./stripe-DMRn4zHo.js";import"./lottie-Coq2aDEW.js";import"./lexical-qJrDnJMV.js";import"./pdf-D2Xq7623.js";import"./utils-D8kKiFqT.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},s=new t.Error().stack;s&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[s]="5ab2c3e1-e462-4f85-a22b-7530d1380688",t._sentryDebugIdIdentifier="sentry-dbid-5ab2c3e1-e462-4f85-a22b-7530d1380688")}catch{}})();const Q=w(function(t){return{fetchState:t.tenantState.fetchState,activeTenantFetchState:t.tenantState.activeTenantFetchState.fetchState,currentTenant:_(t),tenantsInOrder:z(t).tenantsInOrder}})(function({fetchState:t,activeTenantFetchState:s,currentTenant:o,tenantsInOrder:h}){const r=A(),p=new URLSearchParams(r.search);if(o==null||t!=="Completed"&&s!=="Completed")return null;{let m="";const n=h.map(l=>l.tenantEmailDomain),i=r.state?.origin,a=r.state?.queryParams;let c=`../${o.tenantEmailDomain}`,d=null,e=!1,g=null,S=null;const C=E(r.pathname);if(C!=null)c=`../${o.tenantEmailDomain}/${C}`,m="comingFromV2UrlPath",C==="ai-cfo/explore"&&(d=p.get("question")?.replace(/^["']|["']$/g,"")??null,e=p.get("should_submit")==="true");else if(i!=null)if(n.reduce((l,F)=>l||i.split("/").find(D=>D===F)!=null,!1))c=i,i.includes("ai-cfo")&&a!=null&&(g=a.aiCfoRef??null,S=a.aiCfoEmailRefId??null);else{const l=E(i);l!=null?(c=`../${o.tenantEmailDomain}/${l}`,m="comingFromV2UrlPath",l==="ai-cfo/explore"&&a!=null&&(a.aiCfoQuestion!=null&&(d=a.aiCfoQuestion),a.aiCfoShouldSubmit==="true"&&(e=!0))):console.warn("Don't have access to previous path tenant!")}const x=$(c,p);return v.jsx(L,{to:x,replace:!0,state:{...r.state,origin:"",message:m,aiCfoInitialQuestion:d,aiCfoShouldSubmit:e,aiCfoRef:g,aiCfoEmailRefId:S}})}});function oe(){const t=y(),{setLoading:s,clearAllLoading:o}=j(),h=u.useRef(!1),r=u.useRef(!1),p=u.useRef(null),m=b(e=>N(e)),n=b(e=>e.tenantState.fetchState),i=b(e=>e.tenantState.error),a=b(e=>e.tenantState.activeTenantFetchState.fetchState),c=b(e=>_(e)),d=f.getSignedInUser();return u.useLayoutEffect(()=>{const e=f.getActiveTenantForUser()?.tenantId??null;p.current!==e&&(p.current=e,h.current=!1,r.current=!1,s(T.TENANT_FETCHING)),!h.current||a!=="Completed"&&a!=="Error"||(h.current=!1),!r.current||n!=="Completed"&&n!=="Error"||(r.current=!1)},[a,n]),u.useEffect(()=>{const e=f.getActiveTenantForUser()?.tenantId;h.current===!1&&d!=null&&e!=null&&I.shouldFetchActiveTenant(e)&&(h.current=!0,I.markActiveTenantFetchStarted(e),n==="Completed"||a!=="Not-Started"&&a!=="Error"||(s(T.TENANT_FETCHING),t(R(d.userId,e))))},[n,a,d,t]),u.useEffect(()=>{const e=f.getSignedInUser(),g=f.getActiveTenantForUser()?.tenantId,S=g==null||a==="Completed"||a==="Error";r.current===!1&&e!=null&&S&&I.shouldFetchAllTenants()&&(r.current=!0,I.markAllTenantsFetchStarted(),(n==="Not-Started"||n==="Error"&&!U(i))&&t(k(e.userId)))},[n,a,i,d,t]),u.useEffect(()=>{f.isSignedIn()&&n==="Completed"&&m.tenantsCoreDetailsInOrder.length>0&&(f.saveSignedInUserTenants(m.tenantsCoreDetailsInOrder),o())},[m.tenantsCoreDetailsInOrder,n]),u.useEffect(()=>{!f.isSignedIn()||n!=="Completed"&&a!=="Completed"||c==null||(O.updateAppLocaleID(P(c)),o())},[n,a,c]),v.jsx(Q,{})}const V=["dashboard/cash-balance","dashboard/card-balance","dashboard/operating-expenses","dashboard/revenue","dashboard/burn-rate","dashboard/cash-position","dashboard/top-expenses","dashboard/cash-in-cash-out","dashboard","reports","forecast","uncategorized-expense","uncategorized-income","missing-receipts","bills","cards/activate","cards","reimbursements","wise","checking","aicfo"],q={"dashboard/cash-balance":"dashboard/cash_balance","dashboard/card-balance":"dashboard/card_balance","dashboard/operating-expenses":"dashboard/operating_expenses","dashboard/revenue":"dashboard/revenue","dashboard/burn-rate":"dashboard/net_burn_or_income","dashboard/cash-position":"dashboard/cash_position","dashboard/top-expenses":"dashboard/top_expenses","dashboard/cash-in-cash-out":"dashboard/cash_in_cash_out",dashboard:"dashboard",reports:"reports",forecast:"forecast","uncategorized-expense":"transactions/uncategorized-expense","uncategorized-income":"transactions/uncategorized-income","missing-receipts":"transactions/missing-receipts",bills:"bills",reimbursements:"reimbursements","cards/activate":"cards/activate",cards:"cards",wise:"bills/wise/callback/link-account",checking:"checking",aicfo:"ai-cfo/explore"};function E(t){for(const s of V)if(t.toLocaleLowerCase().includes(s))return q[s]}export{oe as default};
|
package/dist/assets/{DomesticWireDetailScreen-DJG5dj2b.js → DomesticWireDetailScreen-Bg4mE0II.js}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as l}from"./liveblocks-
|
|
1
|
+
import{j as l}from"./liveblocks-DS8sOLD1.js";import{h as w,g as C,j as f,n as A,i as V}from"./core-SRRzy8qJ.js";import{PZ as k,Q4 as q,ge as Q,gd as W,gc as K,jr as J,N5 as L,rq as M,eV as B,Pv as D,jp as T,P_ as v,Q7 as j,jn as F,jK as G}from"./zeni-epic-state-DcKqCCCg.js";import{bz as X,q as N,W as R,z as U,m as Z,k as p,U as S,w as _,bA as Y,o as z,bB as ee,s as te}from"./index-BnX1nS7p.js";import{n as O}from"./mui-DQ-jfgFM.js";import"./sentry-B2Aew07S.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]="a56dd42a-dcbe-4214-bcdb-e69e7565a887",e._sentryDebugIdIdentifier="sentry-dbid-a56dd42a-dcbe-4214-bcdb-e69e7565a887")}catch{}})();const ne=A(null,function(e,t){return{onSaveVendor:n=>{e(J(t.vendorId!==void 0?t.vendorId:void 0,t.billId,void 0,t.isExpressPayPage)),e(L("common")),n!=null&&e(M(n))},onGetOtp:n=>{e(K(n,"BillPayVendor"))},onResendOtp:n=>{e(W(n,"BillPayVendor"))},onVerifyOtp:(n,a)=>{e(Q(n,a,"BillPayVendor"))},onVerifyOtpSuccess:(n,a,o)=>{e(q(n,a,o))}}})(X);function H({vendorId:e,billId:t,isExpressPayPage:n}){const a=w(),o=C(),s=f(r=>k(r,e));return l.jsx(ne,{location:o,navigate:a,vendorId:e,billId:t,vendorViewDetails:s,isExpressPayPage:n??!1})}const ae=O.div`
|
|
2
2
|
display: flex;
|
|
3
3
|
height: 100vh;
|
|
4
4
|
width: 100%;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as i}from"./liveblocks-
|
|
1
|
+
import{j as i}from"./liveblocks-DS8sOLD1.js";import{q as c,y as l,m as f}from"./index-BnX1nS7p.js";import{D as p}from"./mui-DQ-jfgFM.js";import"./sentry-B2Aew07S.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]="605d8c5c-1597-48ec-b4ae-a39d31464417",e._sentryDebugIdIdentifier="sentry-dbid-605d8c5c-1597-48ec-b4ae-a39d31464417")}catch{}})();const u={drawerLeftMargin:new l(0,0,240)};function m(e){const{isOpen:r,drawerLeftMargin:o,children:t,onClose:a}=e,n=c(),s=o?.valuePx(n)??u.drawerLeftMargin.valuePx(n),d=f();return i.jsx(p,{anchor:"right",open:r,PaperProps:{style:{width:`calc(100% - ${s})`}},slotProps:{backdrop:{style:{backgroundColor:d.colors.black,opacity:.8,cursor:"pointer"}}},onClose:a,children:t})}export{m as D};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as s}from"./liveblocks-
|
|
1
|
+
import{j as s}from"./liveblocks-DS8sOLD1.js";import{a as d}from"./sentry-B2Aew07S.js";import{h as B,u as A,g as G,i as O,j as l,N as q,n as F,o as V,p as _}from"./core-SRRzy8qJ.js";import{Od as z,eV as K,NB as M,lu as R,K6 as I,Oi as W,N4 as Y,ku as $,K7 as S,NG as H,NH as J,N6 as L,N5 as Q}from"./zeni-epic-state-DcKqCCCg.js";import{aV as U,d as X,k as Z,s as tt}from"./index-BnX1nS7p.js";import"./mui-DQ-jfgFM.js";import{d as k}from"./decodeURIComponentSafe-Bz-26BXW.js";import{w as et}from"./withTransactionSidePanel-CpddR0Hs.js";import{f as at,c as nt}from"./routePaths-DyfF54Mg.js";import"./recharts-CHATJmXy.js";import"./analytics-C-A3qVJh.js";import"./plaid-DWZgMqW3.js";import"./dnd-CR8sMRK3.js";import"./stripe-DMRn4zHo.js";import"./lottie-Coq2aDEW.js";import"./lexical-qJrDnJMV.js";import"./pdf-D2Xq7623.js";import"./utils-D8kKiFqT.js";import"./useAskAiCfoHostNavButtonProps-RYFll1PC.js";import"./TransactionDetailScreen-BbsGsqi_.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]="73a71096-20f6-4346-9b90-8a7c9c92d386",a._sentryDebugIdIdentifier="sentry-dbid-73a71096-20f6-4346-9b90-8a7c9c92d386")}catch{}})();const it=F(function(a,t){const e=t.entity,i=W(a,t.entity,"EntityDetail");return{selectedEntity:e,autoCompleteData:{autoCompleteText:e.name,entityAutoCompleteView:Y(a,"common")},trendWithTransactionsReport:i,analytics:X,isAccountingClassesEnabled:$(a)}},function(a,t){return{onTransactionItemClick:e=>{if(t.openTransactionPanel)return void t.openTransactionPanel(e.id,e.type);const i=`${nt(e,t.tenantEmailDomain)}`,c=tt(t.location.state?.pathnameStackToGoBack,t.location.pathname);t.navigate(i,{state:{pathnameStackToGoBack:c}})},autoCompleteActions:{onAutoCompleteInputChange:e=>{e.trim().length>=2?a(L({searchString:e,searchOrigin:"common"})):e.trim().length===0&&a(Q("common"))},onAutoCompleteEntity:e=>{const i=at(e,t.tenantEmailDomain);a(H()),a(J()),t.resetTrendIsFetchedStates(),t.navigate(i,{replace:!0,state:{pathnameStackToGoBack:t.location.state?.pathnameStackToGoBack}})},onCancelAutoComplete:()=>{const e=Z(t.location.state?.pathnameStackToGoBack),i=e.poppedPathname??C();t.navigate(i,{state:{pathnameStackToGoBack:e.newStack}})}},onTrendSelectedPeriodChange:e=>{if(t.closeSidePanel?.(),e==null)t.defaultTransactionTimePeriod!=null&&a(S(t.entity,"EntityDetail",{timeframe:"quarter",timePeriod:t.defaultTransactionTimePeriod}));else{const i=e.currentTimePeriod==null?e.addTimePeriod:{startDate:e.addTimePeriod.startDate,endDate:e.currentTimePeriod.endDate};a(I(t.entity,"EntityDetail",{timeframe:e.timeframe,timePeriod:e.addTimePeriod})),a(S(t.entity,"EntityDetail",{timeframe:e.timeframe,timePeriod:i}))}}}})(U),ot=et(function({entityType:a,...t}){const e=B(),i=A(),c=G(),[m,T]=d.useState(!1),[h,D]=d.useState(!1),{tenantEmailDomain:b,entityIdEncoded:w,entityNameEncoded:x}=O(),r=k(w??""),p=k(x??""),u=rt(r,p),N=[r,p].filter(n=>n!=null),o={name:p,id:r,type:a,zeniId:r,qboId:r},g=l(n=>z(n.customerIncomeState,n.vendorExpenseState,n.trendState,o,"quarter")),j=l(n=>K(n).company?.companyInfo.firstMonthOfFY??1),f=l(n=>M(n.trendWithTransactionsState,o,"EntityDetail"));d.useEffect(()=>{m===!1&&u===!0&&(T(!0),i(R(o)))},[m,u,o]);const E=l(n=>n.trendState.fetchState),P=f?.selectedPeriod?.timePeriod??g,v=function(n,y){return n!=null&&y!=null?{startDate:n.startDate,endDate:y?.endDate}:y}(f?.selectedPeriod?.timePeriod,g);return d.useEffect(()=>{m===!0&&h===!1&&E==="Completed"&&(D(!0),P!=null&&i(I(o,"EntityDetail",{timeframe:f?.selectedPeriod?.timeframe??"quarter",timePeriod:P})))},[m,h,E]),u?s.jsx(it,{firstMonthOfFY:j,tenantEmailDomain:b,location:c,navigate:e,entity:o,defaultTransactionTimePeriod:v,resetTrendIsFetchedStates:()=>{T(!1),D(!1)},...t}):s.jsx(q,{to:C(N.length)})}),rt=(a,t)=>t!=null&&t.length>0&&a!=null&&a.length>0,C=(a=2)=>{let t="../";for(let e=0;e<a;e++)t=`${t}../`;return t};function wt({entityType:a}){return s.jsx(V,{children:s.jsx(_,{path:"/:entityIdEncoded/:entityNameEncoded/*",element:s.jsx(ot,{entityType:a})})})}export{wt as EntityDetailRoutes,wt as default};
|
package/dist/assets/{ExpenseAutomationRoutes-BAGScNm2.js → ExpenseAutomationRoutes-CGrxhlUE.js}
RENAMED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as h}from"./liveblocks-
|
|
1
|
+
import{j as h}from"./liveblocks-DS8sOLD1.js";import oa from"./NotFoundScreen-DRRoMVDk.js";import{a as o,b as Jt}from"./sentry-B2Aew07S.js";import{n as Ue,S as sa}from"./mui-DQ-jfgFM.js";import{u as pe,h as Yt,g as He,j as x,n as ca,i as xt,o as ia,p as Ge}from"./core-SRRzy8qJ.js";import{eV as Re,SZ as la,og as Ee,fV as ra,s1 as da,oy as Ht,oT as Zt,S_ as Kt,p1 as ua,S$ as Qt,or as ma,rz as pa,fF as Ie,T0 as De,u8 as Wt,Er as Xt,T1 as en,T2 as ha,r7 as Ze,Oe as Pt,Og as ga,kx as Ca,Oh as Sa,kE as fa,cZ as Ia,vk as Ke,oE as tn,p6 as Fe,ow as de,T3 as Ea,N6 as Rt,N5 as we,T4 as Dt,kV as ka,T5 as Ta,T6 as ya,T7 as ba,T8 as va,oL as Aa,p9 as xe,T9 as wa,Ta as xa,Tb as Pa,pg as Ra,kI as Da,kz as Fa,Tc as Ua,kH as Ft,Oo as Va,Td as Ba,Te as Oa,r3 as _a,qH as za,p7 as me,qG as Ne,Tf as Ma,Tg as ja,Th as La,mc as $a,bo as qa,m7 as Ut,lV as Ga,Ti as Na,fv as Vt,gu as Ja,m4 as Ya,xd as Ha,Tj as Za,pH as Ka,pC as Qa,pG as Wa,pr as Xa,Tk as eo,fI as nn,oW as to,oH as no,fW as Bt,pb as ao,Tl as oo,Tm as so,p8 as an,Tn as co,To as io,Tp as lo,Tq as ro,Tr as Ot,rf as uo,qy as mo,N4 as po,Ts as ho,Tt as go,kG as Co,Tu as So,J7 as fo,kF as Io,ku as Eo,fH as ko,q4 as on,qq as To,p5 as _t,pa as yo,bE as bo,m1 as vo,l_ as Ao,Tv as wo,pq as zt,qm as Mt,qk as xo,Tw as Po,q9 as Ro,pR as Do,qn as Fo,Tx as Uo,Ty as Vo,pV as Bo,Tz as Oo,pM as _o,pU as zo,pS as Mo,qt as jo}from"./zeni-epic-state-DcKqCCCg.js";import{W as sn,U as X,d as q,s as ae,V as cn,Z as ln,cY as Lo,z as Ve,cZ as $o,au as Pe,c_ as qo,aX as jt,w as rn,c$ as Go,ar as Je,a as No,a7 as Jo,d0 as Yo,a2 as Ho,d1 as Zo,Q as Ko,d2 as Qo,d3 as Wo,$ as Xo,I as es,aQ as ts,d4 as ns,d5 as as,bc as os,y as ss,aT as cs}from"./index-BnX1nS7p.js";import{u as dn}from"./useAskAiCfoHostNavButtonProps-RYFll1PC.js";import{f as Lt,a as is,b as ls,g as rs,C as ds}from"./TransactionDetailScreen-BbsGsqi_.js";import{w as us}from"./withTransactionSidePanel-CpddR0Hs.js";import{h as ms,v as ps}from"./routePaths-DyfF54Mg.js";import{g as Ye}from"./accountMappingHelper-BPz1owqi.js";import{D as hs}from"./DrawerScreen-Q_Fkogtz.js";import"./recharts-CHATJmXy.js";import"./analytics-C-A3qVJh.js";import"./plaid-DWZgMqW3.js";import"./dnd-CR8sMRK3.js";import"./stripe-DMRn4zHo.js";import"./lottie-Coq2aDEW.js";import"./lexical-qJrDnJMV.js";import"./pdf-D2Xq7623.js";import"./utils-D8kKiFqT.js";import"./decodeURIComponentSafe-Bz-26BXW.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},l=new t.Error().stack;l&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[l]="05957122-2cc4-4cd9-948c-bf7f722cd06f",t._sentryDebugIdIdentifier="sentry-dbid-05957122-2cc4-4cd9-948c-bf7f722cd06f")}catch{}})();const gs=()=>{const t=pe(),l=Yt(),V=He(),f=x(d=>Re(d)),{useFeatureGate:b}=sn(),{isFeatureEnabled:S}=b(X.isRealtimeInsightsFeatureEnabled),{isFeatureEnabled:r}=b(X.aiAuditScorePercentage),I=x(d=>d.expenseAutomationViewState.selectedPeriodByTenantId),s=x(d=>la(d,f.tenantId)),{isAiCfoAccessEnabled:p,onAskAiCfoClick:u}=dn({mobileExploreReferrer:"Month-End Close Overview"}),k=o.useCallback((d,G,ee=!1)=>{t(Ee({tenantId:G,period:{month:d.month,year:d.year},refreshViewInBackground:ee}))},[]),v=o.useCallback(d=>{const G=V.state?.referrer;s.monthEndCloseChecks?.auditSummary!=null&&q.trackMonthCloseAuditPage(d.month,d.year,s.monthEndCloseChecks.reportEmailSentDate!=null?"closed":"in-review",s.monthEndCloseChecks.auditSummary.auditScorePercentage,!1,G??null),t(ra(f.tenantId,d))},[f.tenantId,s.monthEndCloseChecks?.auditSummary,s.monthEndCloseChecks?.reportEmailSentDate]),g=I[f.tenantId],m=o.useCallback(()=>{const d=V.state?.referrer;s.monthEndCloseChecks?.auditSummary!=null&&q.trackMonthCloseAuditPage(g.month,g.year,s.monthEndCloseChecks.reportEmailSentDate!=null?"closed":"in-review",s.monthEndCloseChecks.auditSummary.auditScorePercentage,!0,d??null),k(g,f.tenantId,!0)},[k,g,f.tenantId,s.monthEndCloseChecks?.auditSummary,s.monthEndCloseChecks?.reportEmailSentDate]),P=ae(V.state?.pathnameStackToGoBack,V.pathname),E=o.useCallback(()=>{if(s.monthEndCloseChecks!=null&&g!=null){const d=s.monthEndCloseChecks.monthEndCloseCheckList.find(G=>G.progress<100);if(d!=null)return void l(`./${d.id}/${g.month}-${g.year}`,{state:{pathnameStackToGoBack:P,message:"comingFromOverview"}});l(`./month_end_insights/${g.month}-${g.year}`,{state:{pathnameStackToGoBack:P,message:"comingFromOverview"}})}},[s.monthEndCloseChecks,g]),{areTenantIdsInSync:T}=cn();return ln({isDataReady:s.fetchState==="Completed"}),o.useEffect(()=>{g!=null&&s.fetchState!=="In-Progress"&&s.fetchState!=="Completed"&&T&&k(g,f.tenantId)},[k,g,s.fetchState,f.tenantId,T]),o.useEffect(()=>{g!=null&&s.monthClosePerformanceTrendFetchStatus.fetchState!=="In-Progress"&&s.monthClosePerformanceTrendFetchStatus.fetchState!=="Completed"&&T&&t(da(g))},[g,s.monthClosePerformanceTrendFetchStatus.fetchState,T]),o.useEffect(()=>{const d=setInterval(()=>{s.fetchState!=="In-Progress"&&s.fetchState==="Completed"&&m()},3e5);return()=>clearInterval(d)},[s.fetchState]),o.useEffect(()=>{if(s.fetchState==="Completed"&&s.monthEndCloseChecks?.auditSummary!=null){const d=V.state?.referrer;q.trackMonthCloseAuditPage(s.selectedPeriod.month,s.selectedPeriod.year,s.monthEndCloseChecks.reportEmailSentDate!=null?"closed":"in-review",s.monthEndCloseChecks.auditSummary.auditScorePercentage,!1,d??null)}},[s.fetchState,s.selectedPeriod,s.monthEndCloseChecks?.auditSummary,s.monthEndCloseChecks?.reportEmailSentDate]),h.jsx(Cs,{children:h.jsx(Lo,{monthEndCloseChecksView:s,isRealtimeInsightsFeatureEnabled:S,onMonthEndCheckClick:d=>{l(`./${d}/${g.month}-${g.year}`,{state:{pathnameStackToGoBack:P,message:"comingFromOverview",referrer:"Expense Automation - Overview"}})},onPeriodChange:v,handleReviewButtonClick:E,onBackClick:()=>{l("../../dashboard")},onReload:m,isAiCfoAccessEnabled:p,onAskAiCfoClick:u,aiAuditScorePercentageEnabled:r})})},Cs=Ue.div`
|
|
2
2
|
display: flex;
|
|
3
3
|
height: 100vh;
|
|
4
4
|
width: 100%;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as s}from"./liveblocks-
|
|
1
|
+
import{j as s}from"./liveblocks-DS8sOLD1.js";import{a as r}from"./sentry-B2Aew07S.js";import{a3 as i,a4 as l,a5 as p,k as m}from"./index-BnX1nS7p.js";import"./mui-DQ-jfgFM.js";import c from"./NotFoundScreen-DRRoMVDk.js";import{h as b,g as u}from"./core-SRRzy8qJ.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]="c9079827-83a3-4fdb-a5d4-2b9f64b3f7ee",e._sentryDebugIdIdentifier="sentry-dbid-c9079827-83a3-4fdb-a5d4-2b9f64b3f7ee")}catch{}})();const _=()=>{const e=b(),a=u(),t=r.useCallback(()=>{window.open("https://www.zeni.ai/demo/request","_blank")},[]),d=r.useCallback(()=>{(()=>{const n=m(a.state?.pathnameStackToGoBack),f=n.poppedPathname??k();e(f,{state:{pathnameStackToGoBack:n.newStack}})})()},[]),o=i(a.pathname);return o!=null?s.jsx(l,{menuItem:p(o),onDemoClick:t,onGoBack:d}):s.jsx(c,{})},k=(e=2)=>{let a="../";for(let t=0;t<e;t++)a=`${a}../`;return a};export{_ as F};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as r}from"./sentry-
|
|
1
|
+
import{a as r}from"./sentry-B2Aew07S.js";import{u as l,h as f,g as m}from"./core-SRRzy8qJ.js";import{hq as p,Mc as g,Md as _}from"./zeni-epic-state-DcKqCCCg.js";import{u as b,L as h,z as y}from"./index-BnX1nS7p.js";import"./liveblocks-DS8sOLD1.js";import"./recharts-CHATJmXy.js";import"./mui-DQ-jfgFM.js";import"./analytics-C-A3qVJh.js";import"./plaid-DWZgMqW3.js";import"./dnd-CR8sMRK3.js";import"./stripe-DMRn4zHo.js";import"./lottie-Coq2aDEW.js";import"./lexical-qJrDnJMV.js";import"./pdf-D2Xq7623.js";import"./utils-D8kKiFqT.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]="17b1664a-957d-4fcb-994a-06c7ccf67e22",e._sentryDebugIdIdentifier="sentry-dbid-17b1664a-957d-4fcb-994a-06c7ccf67e22")}catch{}})();function R(){const e=l(),n=f(),o=m(),{setLoading:i,clearAllLoading:d}=b(),s=r.useRef(!1);return r.useLayoutEffect(()=>{i(h.CONNECTION_AUTH)},[i]),r.useEffect(()=>{if(s.current)return;s.current=!0;const a=new URLSearchParams(o.search).get("code"),c=sessionStorage.getItem("hubspot_oauth_pending");if(sessionStorage.removeItem("hubspot_oauth_pending"),a!=null&&c!=null){const t=JSON.parse(c);e(p(t.tenant_id,t.connection_id,g("revenue"),_("hubspot"),{authorization_code:a,client_id:t.client_id,client_secret:t.client_secret,redirect_uri:t.redirect_uri}))}d();const u=y.getActiveTenantForUser();n(u?.tenantEmailDomain!=null?`/${u.tenantEmailDomain}/settings/integrations`:"/",{replace:!0})},[]),null}export{R as default};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as a}from"./liveblocks-
|
|
1
|
+
import{j as a}from"./liveblocks-DS8sOLD1.js";import{i as S,n as x,h as C,g as y,u as ee,t as ae,j as E,N as te,o as ne,p}from"./core-SRRzy8qJ.js";import{M5 as k,M6 as v,M7 as F,B8 as B,AW as T,M8 as A,M9 as oe,Ma as ie,A_ as se,fw as $,B5 as le,B2 as re}from"./zeni-epic-state-DcKqCCCg.js";import{q as g,o as r,E as de,d as j,i as G,j as ce,k as me,r as pe,s as H,W as ue,U as he,R as xe,$ as ge,m as fe,v as we,w as be,x as Se,O as ye,S as ke,T as ve,y as je,M as $e}from"./index-BnX1nS7p.js";import{n as m}from"./mui-DQ-jfgFM.js";import f from"./NotFoundScreen-DRRoMVDk.js";import{a as I}from"./sentry-B2Aew07S.js";import"./recharts-CHATJmXy.js";import"./analytics-C-A3qVJh.js";import"./plaid-DWZgMqW3.js";import"./dnd-CR8sMRK3.js";import"./stripe-DMRn4zHo.js";import"./lottie-Coq2aDEW.js";import"./lexical-qJrDnJMV.js";import"./pdf-D2Xq7623.js";import"./utils-D8kKiFqT.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]="434e76de-8b3a-44ab-9582-6fac83853eb4",e._sentryDebugIdIdentifier="sentry-dbid-434e76de-8b3a-44ab-9582-6fac83853eb4")}catch{}})();const Ie=m.div`
|
|
2
2
|
display: flex;
|
|
3
3
|
height: 100%;
|
|
4
4
|
width: 100%;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as u}from"./liveblocks-
|
|
1
|
+
import{j as u}from"./liveblocks-DS8sOLD1.js";import{a as g}from"./sentry-B2Aew07S.js";import{u as M,g as U,h as w,t as _,j as l,N as T}from"./core-SRRzy8qJ.js";import{z as r,m as V,a as P,e as A,d as N,f as R,p as W,O as X,g as Y}from"./index-BnX1nS7p.js";import{eV as Z,LS as $,M0 as q,LT as B,fw as G,fZ as H,LY as J,gl as K,cX as Q,M1 as ee,M2 as te}from"./zeni-epic-state-DcKqCCCg.js";import{n as ne}from"./mui-DQ-jfgFM.js";import{u as se}from"./useDeviceId-obtSvxuy.js";import{f as ae}from"./analyticsHelper-CewoJ3Hu.js";import{t as ie}from"./getLocaleForTenant-DHWNDQcY.js";import"./recharts-CHATJmXy.js";import"./analytics-C-A3qVJh.js";import"./plaid-DWZgMqW3.js";import"./dnd-CR8sMRK3.js";import"./stripe-DMRn4zHo.js";import"./lottie-Coq2aDEW.js";import"./lexical-qJrDnJMV.js";import"./pdf-D2Xq7623.js";import"./utils-D8kKiFqT.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]="3cec93e3-b334-4405-a749-0d6cdcbfdae2",t._sentryDebugIdIdentifier="sentry-dbid-3cec93e3-b334-4405-a749-0d6cdcbfdae2")}catch{}})();const x=(t,a)=>t!=null&&t.length>0&&a==="magic_links";function xe(){const t=M(),a=U(),m=w(),[k]=_(),n=k.get("token"),p=k.get("stytch_token_type"),f=r.getMagicLinkCodeVerifier(),i=se(),{otpChallenge:d,twoFAPhoneNumber:z,magicLinkEmail:c,verifyDeviceFetchState:C,resendVerifyDeviceOTPFetchState:D}=l(e=>e.tenantState),S=l(e=>e.tenantState.fetchState),y=l(e=>e.tenantState.activeTenantFetchState.fetchState),I=l(e=>e.tenantState.signInState),h=l(e=>e.tenantState.magicLinkSignInFetchState.fetchState),s=l(e=>e.tenantState.loggedInUser),o=l(e=>Z(e)),b=l(e=>$(e)),E=r.getSignedInUser(),v=V().mode;g.useEffect(()=>{s?.zeniSessionId==null&&n!=null&&x(n,p)&&i!=null&&f!=null&&(r.saveMagicLinkTriggered(n),t(q(n,i,f)))},[n,p,t,i,f,s?.zeniSessionId]),g.useEffect(()=>{I!=="In-Progress"||S!=="Completed"&&y!=="Completed"||s?.zeniSessionId==null||o==null||(n!=null&&r.saveLastUsedMagicLinkToken(n),r.saveSignedInUserWithSession(s,s.zeniSessionId),r.saveSignedInUserTenants(B(b.tenantsInOrder),s.zeniSessionId),G(s.userId,s.zeniSessionId,o.tenantId),t(H(o.tenantId)),r.saveActiveTenantDomainForUser(o.tenantEmailDomain),t(J("Completed")),P.updateAppLocaleID(ie(o)),ae(s,o,v,void 0,b.tenantsInOrder),K().then(()=>{const e=Y();e!=null&&A(e)}),setTimeout(()=>{N.trackLogin(R.Event.loginSuccess,"email",Q(o.productSettings))},2e3))},[I,S,y,s,o,b,v,a.state,t]);const O=g.useCallback(()=>{m("/signin/auth")},[m]),j=g.useCallback(()=>{i!=null&&d!=null&&c!=null&&t(ee(i,c,d))},[i,d,t,c]),F=g.useCallback(e=>{i!=null&&n!=null&&c!=null&&d!=null&&t(te(e,i,c,d))},[i,n,t,c,d]);if(h==="Completed"&&d!=null)return u.jsx(W,{phoneNumber:z,verifyOtpFetchState:C.fetchState,resendVerifyDeviceOTPFetchState:D,onResendOtp:j,onVerifyOtp:F,onCancelVerifyDevice:O});if(I==="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(!x(n,p)||f==null||h==="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??"")||h==="Error"&&s?.zeniSessionId==null)}})}return u.jsx(oe,{"data-testid":"smooth-loader",children:u.jsx(X,{size:"ExtraLarge",start:!0})})}const oe=ne.div`
|
|
2
2
|
position: fixed;
|
|
3
3
|
top: 0;
|
|
4
4
|
left: 0;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as N}from"./liveblocks-
|
|
1
|
+
import{j as N}from"./liveblocks-DS8sOLD1.js";import{a as c}from"./sentry-B2Aew07S.js";import{u as me,j as n,i as Je,g as Ke,h as Qe,l as P}from"./core-SRRzy8qJ.js";import{eV as be,fB as qe,fC as pe,fn as Xe,bn as ea,eU as aa,fD as ta,fE as na,fG as sa,fJ as oa,fS as ia,fK as g,fM as ra,fN as le,fQ as da,fO as la,fP as ca,fR as ua,cN as fa,fU as ma,cS as ba,fm as pa,fZ as ha,f_ as Sa,fY as ga}from"./zeni-epic-state-DcKqCCCg.js";import{a7 as Ea,a8 as Ca,$ as ka,W as ya,z as C,v as Ia,u as Ta,U as r,a9 as wa,B as _a,aa as Aa,I as Fa,c as Da,ab as va,a3 as $a,ac as Ba,ad as Ma,ae as ce,af as ue,L as Pa,ag as Ra,ah as fe,d as R,_ as xa,s as _,ai as x,aj as Na}from"./index-BnX1nS7p.js";import{D as Ua}from"./mui-DQ-jfgFM.js";(function(){try{var f=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},d=new f.Error().stack;d&&(f._sentryDebugIds=f._sentryDebugIds||{},f._sentryDebugIds[d]="1e3dbbec-f449-4f39-8005-98d5dc45118e",f._sentryDebugIdIdentifier="sentry-dbid-1e3dbbec-f449-4f39-8005-98d5dc45118e")}catch{}})();const Va=Ea(({isAppContentDrawerOpen:f,handleDrawerToggle:d})=>{const{tenantEmailDomain:t}=Je(),a=Ke(),k=ka(),o=Qe(),U=Xe(),m=me(),{useFeatureGate:i}=ya(),V=C.getSignedInUser(),G=ea(V),s=n(e=>be(e)),he=s.masterTOSInfo?.isMasterTOSAccepted??!1,O=n(e=>aa(e)),j=O.uiState.currentChatSessionId,y=Ia(),{setLoading:Se}=Ta(),[A,L]=c.useState(void 0),F=P("/:tenantEmailDomain/dashboard")!==null,z=P("/:tenantEmailDomain/reports")!==null,I=P("/:tenantEmailDomain/onboarding/*")!==null,{isFeatureEnabled:Y}=i(r.isDepositAccountsFeatureEnabled),{isFeatureEnabled:ge}=i(r.isChargeCardFeatureEnabled),{isFeatureEnabled:Z}=i(r.isDebitCardFeatureEnabled),Ee=wa(s,ge,Z),{isFeatureEnabled:Ce}=i(r.isSettingsFeatureEnabled),H=n(e=>ta(e)),{isFeatureEnabled:T}=i(r.isReferralFeatureEnabled),D=n(e=>na(e));c.useEffect(()=>{y&&T&&!I&&D.fetchState==="Not-Started"&&m(sa(!0))},[y,T,D.fetchState,I]);const h=C.getSignedInUser(),v=n(e=>e.tenantState),ke=n(e=>v.fetchState==="Completed"?oa(e):[]),E=n(e=>e.expenseAutomationViewState.selectedPeriodByTenantId),{isFeatureEnabled:ye}=i(r.isApAgingFeatureEnabled),{isFeatureEnabled:Ie}=i(r.isArAgingFeatureEnabled),{isFeatureEnabled:Te}=i(r.isExpenseAutomationEnabled),{isFeatureEnabled:we}=i(r.isExpenseAutomationEnabledV2),W=_a(),{isFeatureEnabled:_e}=i(r.isDashboardSidebarHalloweenAnimationEnabled),{isFeatureEnabled:Ae}=i(r.isDashboardSidebarThanksGivingAnimationEnabled),{isFeatureEnabled:Fe}=i(r.isDashboardSidebarChristmasAnimationEnabled),{isFeatureEnabled:De}=i(r.isDashboardSidebarNewYearAnimationEnabled),{isFeatureEnabled:ve}=i(r.isTreasuryEnabled),{isFeatureEnabled:$e}=i(r.isTaskManagerCustomerUserAccessEnabled),Be=G||!G&&$e,Me=s.company!=null&&ia(s.company),w=ve&&Me,Pe=n(e=>g(e).totalUnreadCount),Re=n(e=>g(e).reducedFetchCountState),J=n(e=>g(e).notificationDetailsByTab.tasks.uiState.unreadCount),K=n(e=>g(e).notificationDetailsByTab.comments.uiState.unreadCount),xe=n(e=>g(e).notificationDetailsByTab.tasks.fetchCountState),$=n(e=>g(e).notificationDetailsByTab.comments.fetchCountState),{inboxNotifications:Q,isLoading:q,isFetchingMore:X,hasFetchedAll:ee,fetchMore:Ne}=Aa();c.useEffect(()=>{const e=setTimeout(()=>Ne?.(),0);return()=>clearTimeout(e)}),c.useEffect(()=>{if(q===!1&&X===!1&&ee===!0)if(s?.companyId!=null&&Q!=null){const e=`dashboard_${s.companyId}`;L(Q.filter(u=>u.roomId===e&&u.readAt==null).length)}else L(0)},[q,X,ee]),c.useEffect(()=>{y&&!I&&xe.fetchState==="Not-Started"&&U.tenantId!=null&&m(ra("task_manager","dashboard"))},[y,U.tenantId]),c.useEffect(()=>{I||$.fetchState!=="Not-Started"||m(le({fetchCountState:{fetchState:"In-Progress",error:void 0}},"comments"))},[]),c.useEffect(()=>{A!=null&&$.fetchState==="In-Progress"&&(m(le({fetchCountState:{fetchState:"Completed",error:void 0}},"comments")),m(pe({unreadCount:A},"comments")))},[A,$.fetchState]);const Ue={fetchStatus:Re,count:Pe},ae=t!=null?C.getSignedInUserTenant(t):null,te=n(e=>ae?.tenantId!=null?da(e,ae.tenantId):void 0),S=[];ye===!1&&S.push("accounts_payable_aging"),Ie===!1&&S.push("accounts_receivable_aging"),Y===!1&&S.push("zeni_accounts_promo_card"),T===!1&&S.push("rewards_card"),W===!1&&S.push("expense_automation_card");const Ve=Fa(),ne=n(e=>la(e,S,h,we,Te,w).fetchState),se=n(e=>ca(e).fetchState),Ge=F&&(ne==="Completed"||ne==="Error")||z&&(se==="Completed"||se==="Error")||!F&&!z?void 0:"disabled",Oe=c.useMemo(()=>ua(s.userRole),[s.userRole]),je=fa(Oe),Le=s?.rewardsLastViewedTime==null,ze=h?.userEmail!=null&&H.fetchState==="Completed"&&ma(H.notificationSettings,h.userEmail,Z,s),oe=Da(),Ye=oe&&va(a),ie=ba(Ve?.loggedInUserRoleMap),re=s.companyTreasuryInfo?.info?.isTreasuryTOSAccepted,B=c.useCallback(()=>w&&ie&&!C.getTreasuryPopupSeen(t??"")&&re===!1&&$a(a.pathname)!=="treasury",[w,ie,re,a.pathname,t]),[Ze,de]=c.useState(B);c.useEffect(()=>{de(B())},[B]);const He=n(e=>e.treasurySetupViewState.treasuryFundsDetails).fundsDetails,We=Ba(He);return N.jsx(Ua,{container:window.document.body,variant:"temporary",open:f,onClose:()=>d(!1),PaperProps:{sx:{width:240,zIndex:8,borderRight:"none",backgroundImage:"none"}},ModalProps:{keepMounted:!0},children:N.jsx(Ma,{signedInUser:V,currentTenantId:v.currentTenantId??"",tenants:v.fetchState==="Completed"?ke:te!=null?[te]:[],currentTenant:s,isTenantDropdownDisabled:Ge,isSettings:ue(a),isSettingsFeatureEnabled:Ce,isVendorsTabVisible:je,isZeniAccountEnabled:Y,isChargeCardEnabled:Ee,isTreasuryEnabled:w,treasuryYieldPercentage:We,isTreasuryPopupVisible:Ze,isNotificationsTabVisible:ze,notificationCountDetails:Ue,isExpenseAutomationEnabledForUser:W,selectedMenu:ce(a),rewardsConfiguration:{isRewardsTabVisible:T,isRewardsAnimated:Le,rewardsPlan:D.rewardsPlan},isAiCfoAccessEnabled:oe,onNotificationIconClick:()=>{d(!1);let e=J===0&&K>0?"notifications/comments":"notifications/tasks";ue(a)&&(e=J===0&&K>0?"../../notifications/comments":"../../notifications/tasks");const u=_(a.state?.pathnameStackToGoBack,a.pathname);o(e,{state:{pathnameStackToGoBack:u}})},handleCockpitClick:()=>{window.open("/cockpit")},handleLogOutClick:()=>{d(!1);const e=_(a.state?.pathnameStackToGoBack,a.pathname);o("/signout",{replace:!0,state:{pathnameStackToGoBack:e,message:"logout"}})},handleMenuChange:e=>{if(d(!1),t==null)return;if(e.type==="ai_cfo"){if(R.trackAICFOChatScreenStateChanged("viewed","left_menu",j??null,null),!he)return void xa({location:a,navigate:o,mergeState:{referrer:"Sidebar"}});const p=_(a.state?.pathnameStackToGoBack,a.pathname);return void o(`/${t}/ai-cfo/explore`,{state:{pathnameStackToGoBack:p,referrer:"Sidebar"}})}const u=_(a.state?.pathnameStackToGoBack,a.pathname),l=e.type,b=x(l)&&l!=="command_center";if(x(e.type)&&E[s.tenantId]!=null&&R.trackMonthEndCloseClicked(E[s.tenantId].month,E[s.tenantId].year,"Sidebar"),b&&E[s.tenantId]!=null){const p=E[s.tenantId];return void o(`/${t}/month_end_close_checks/review/${e.type}/${p.month}-${p.year}`,{state:{pathnameStackToGoBack:u,referrer:"Sidebar"}})}const M=Na(e.type);fe(e.type)?(j!=null&&m(ga()),o(`/${t}/ai-cfo/${e.type}`,{state:{pathnameStackToGoBack:u.slice(0,-1),referrer:"Sidebar"}})):o(`/${t}/${M}`,{state:{pathnameStackToGoBack:u,referrer:"Sidebar"}})},handleMyProfileClick:()=>{d(!1),o(`/${t}/settings/my_profile`)},handleReferralsClick:()=>{d(!1),o(`/${t}/rewards`)},handleBackClick:()=>{o(`/${t}/dashboard`)},handleTenantSelect:e=>{Se(Pa.TENANT_SWITCHING),d(!1);const u=e.tenantEmailDomain,l=ce(a);let b=`/${encodeURIComponent(u)}/`;const M=x(l);l==="home"?b+="dashboard":l==="users_and_roles"?b+="people":Ra(l)?b+="settings/my_profile":fe(l)?b+=`ai-cfo/${l}`:b+=l==="task_checklist"?"tasks":M?"month_end_close_checks/review":encodeURIComponent(l),o(b,{replace:!0}),h!=null&&(m(ha(e.tenantId)),m(Sa(h.userId,e.tenantId,h.zeniSessionId)));const p=e;R.trackCompanySwitch(p.companyId,p.companyName,p.userRole)},handlePopupClose:()=>{C.saveTreasuryPopupSeen(t??"",!0),de(!1)},onZeniLogoClick:()=>{k.toggle()},isAiCfo:Ye,aiCfoView:O,isOnDashboard:F,updateCurrentChatSessionId:e=>{m(pa({sessionId:e,agentId:"controller"})),o(`/${t}/ai-cfo/${e}`,{state:{...a.state}})},halloweenAnimationEnabled:_e,isTaskManagerAccessEnabled:Be,thanksGivingAnimationEnabled:Ae,christmasAnimationEnabled:Fe,newYearAnimationEnabled:De})})}),Za=f=>{const d=me(),t=n(k=>be(k)),a={events:t.userRoleId!=null?[`private-encrypted-${t.userRoleId}.dashboard-user-notification`]:[],eventCallback:(k,o)=>{Ca(o)&&qe(o.mode)==="dashboard"&&d(pe({unreadCount:o.data.unread},"tasks"))}};return N.jsx(Va,{...f,...a})};export{Za as M};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{j as r}from"./liveblocks-DS8sOLD1.js";import{h as n,n as e}from"./core-SRRzy8qJ.js";import{H as i}from"./index-BnX1nS7p.js";import"./mui-DQ-jfgFM.js";import"./sentry-B2Aew07S.js";import"./zeni-epic-state-DcKqCCCg.js";import"./recharts-CHATJmXy.js";import"./analytics-C-A3qVJh.js";import"./plaid-DWZgMqW3.js";import"./dnd-CR8sMRK3.js";import"./stripe-DMRn4zHo.js";import"./lottie-Coq2aDEW.js";import"./lexical-qJrDnJMV.js";import"./pdf-D2Xq7623.js";import"./utils-D8kKiFqT.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 +1 @@
|
|
|
1
|
-
import{l as ct,a as mt,m as dt,j as E}from"./liveblocks-
|
|
1
|
+
import{l as ct,a as mt,m as dt,j as E}from"./liveblocks-DS8sOLD1.js";import lt from"./NotFoundScreen-DRRoMVDk.js";import{a as k}from"./sentry-B2Aew07S.js";import{h as ft,g as ut,i as ht,u as pt,j as S,n as kt,o as gt,p as X}from"./core-SRRzy8qJ.js";import{cu as St,fD as Q,eV as H,fR as bt,fK as b,SU as J,fN as d,fC as y,sl as M,xQ as It,SV as Ct,fB as Tt,fU as yt,sq as _t,SW as $,bo as F,fv as w,su as Z,SX as At,cG as Et,cz as Nt}from"./zeni-epic-state-DcKqCCCg.js";import{V as Bt,z as xt,W as wt,U as Ut,Z as Rt,cV as Dt,s as N,a7 as vt,cW as Gt,a8 as Pt,k as $t}from"./index-BnX1nS7p.js";import"./mui-DQ-jfgFM.js";import{u as Ft}from"./useAskAiCfoHostNavButtonProps-RYFll1PC.js";import"./recharts-CHATJmXy.js";import"./analytics-C-A3qVJh.js";import"./plaid-DWZgMqW3.js";import"./dnd-CR8sMRK3.js";import"./stripe-DMRn4zHo.js";import"./lottie-Coq2aDEW.js";import"./lexical-qJrDnJMV.js";import"./pdf-D2Xq7623.js";import"./utils-D8kKiFqT.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},l=new t.Error().stack;l&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[l]="28a8ee73-ccd5-4ad5-906f-d4c93e7f71fa",t._sentryDebugIdIdentifier="sentry-dbid-28a8ee73-ccd5-4ad5-906f-d4c93e7f71fa")}catch{}})();const Mt=(t,l)=>new Promise((n,u)=>{const g=t.map(i=>new Promise(s=>{l(i),s()}));Promise.all(g).then(()=>{setTimeout(()=>{n()},2e3)}).catch(i=>{u(i)})}),jt=kt(function(t,l){const n=Q(t),{signedInUser:u,isDebitCardFeatureEnabled:g}=l,i=b(t),s=H(t),{currentTab:h}=i;return{notificationView:i,isNotificationSettingsVisible:u.userEmail!=null&&yt(n.notificationSettings,u.userEmail,g,s),isDisabled:i.notificationDetailsByTab[h].fetchState==="In-Progress"?"disabled":void 0}},function(t,l){const{location:n,tenantEmailDomain:u,loggedInUserRoleMap:g,externalNotificationsUnreadCount:i,allUnreadCommentsNotificationIds:s,navigate:h,markInboxNotificationAsRead:B,fetchMoreCommentsNotifications:U}=l;return{onNotificationClick:(a,o,m,c)=>{if(c==="task_deleted"){const r=`/${u}/tasks`,I=N(n.state?.pathnameStackToGoBack,n.pathname);h(r,{state:{pathnameStackToGoBack:I,message:"triggerBackClick"}})}else{const r=`/${u}/tasks/${o}`,I=N(n.state?.pathnameStackToGoBack,n.pathname);h(r,{state:{pathnameStackToGoBack:I,message:"triggerBackClick"}})}m==="unread"&&t(Z("task_manager","read",[a],!1))},onCommentNotificationClick:(a,o,m)=>{const c=o.toString().split(`/${u}/`);if(c[1]!=null){m==="unread"&&(B(a),t($([a],F())));let r=`/${u}/${c[1]}`;const I=N(n.state?.pathnameStackToGoBack,n.pathname);c[1].startsWith("reimbursement")&&!Et(g)&&(r="not-found"),c[1].startsWith("bill")&&!Nt(g)&&(r="not-found"),h(r,{state:{pathnameStackToGoBack:I,message:"triggerBackClick"}})}},onUpdateNotificationViewUIState:(a,o)=>{t(y(a,o))},onUpdateNotificationTabState:(a,o)=>{t(d(a,o))},onUpdateNotificationViewCurrentTabAndSubTab:(a,o)=>{t(J(a,o));const m=`../${a}`,c=N(n.state?.pathnameStackToGoBack,n.pathname);h(m,{state:{pathnameStackToGoBack:c}})},onUpdateNotificationViewSubTab:a=>{t(At(a))},onFetchMoreNotifications:(a,o)=>{if(a==="tasks"){const m=[];o==="all"?m.push("read","unread"):o!=="mentions"&&m.push(o),t(M("task_manager","dashboard",m))}else U?.()},onUpdateNotificationStatus:(a,o,m,c)=>{a==="tasks"?t(Z("task_manager",m,c)):(t(d({markAsReadState:{fetchState:"In-Progress",error:void 0}},"comments")),Promise.all(c.map(r=>{m==="read"&&(B(r),t($([r],F())))})).then(()=>{t(d({markAsReadState:{fetchState:"Completed",error:void 0},selectedNotificationIds:[]},"comments")),t(y({unreadCount:i-c.length>0?i-c.length:0},"comments")),t(w({messageSection:"notification_mark_as_read",messageText:"success",type:"success",showStatusIcon:!0}))},r=>{t(d({markAsReadState:{fetchState:"Error",error:r}},"comments")),t(w({messageSection:"notification_mark_as_read",messageText:"failed",type:"error",showStatusIcon:!0}))}).catch(r=>{t(d({markAsReadState:{fetchState:"Error",error:r}},"comments")),t(w({messageSection:"notification_mark_as_read",messageText:"failed",type:"error",showStatusIcon:!0}))}))},onMarkAllNotificationsAsRead:a=>{a==="tasks"?t(_t("task_manager","read")):(t(d({markAsAllReadState:{fetchState:"In-Progress",error:void 0}},"comments")),Mt(s,B).then(()=>{t($(s,F())),t(d({markAsAllReadState:{fetchState:"Completed",error:void 0}},"comments")),t(y({unreadCount:0},"comments")),t(w({messageSection:"notification_mark_as_read",messageText:"success",type:"success",showStatusIcon:!0}))}).catch(o=>{t(d({markAsAllReadState:{fetchState:"Error",error:o}},"comments")),t(w({messageSection:"notification_mark_as_read",messageText:"failed",type:"error",showStatusIcon:!0}))}))},onBackClick:()=>{const a=$t(n.state?.pathnameStackToGoBack),o=a.poppedPathname??"../../dashboard";h(o,{state:{pathnameStackToGoBack:a.newStack}})},onSettingsClick:()=>{const a=N(n.state?.pathnameStackToGoBack,n.pathname);h("../../settings/notifications",{state:{pathnameStackToGoBack:a}})}}})(vt(Gt)),Vt=()=>{const t=ft(),l=ut(),{tenantEmailDomain:n,selectedTab:u}=ht(),{areTenantIdsInSync:g}=Bt(),i=St(u??""),s=pt(),h=xt.getSignedInUser(),[B,U]=k.useState(!1),a=S(e=>Q(e)),o=S(e=>H(e)),{useFeatureGate:m}=wt(),{isFeatureEnabled:c}=m(Ut.isDebitCardFeatureEnabled),{isAiCfoAccessEnabled:r,onAskAiCfoClick:I}=Ft({mobileExploreReferrer:"Notifications"});Rt({isDataReady:!0});const O=bt(o.userRole);if(o==null||n==null||o.companyId==null)throw Error("Can't access notifications page without current tenant...");if(h==null)throw Error("Can't access notifications page without signed in...");const j=S(e=>b(e).notificationDetailsByTab.tasks.fetchState),V=S(e=>b(e).currentTab),R=S(e=>b(e).currentSubTab),Y=S(e=>b(e).notificationDetailsByTab.comments.fetchCountState),D=S(e=>b(e).notificationDetailsByTab.comments.fetchState),tt=S(e=>b(e).notificationDetailsByTab.comments.uiState.unreadCount),et=S(e=>b(e).allExternalNotifications).filter(e=>e.inboxNotification.readAt==null).map(e=>e.inboxNotification.id),at=Dt().allUsers,{inboxNotifications:x,isLoading:_,hasFetchedAll:C,isFetchingMore:v,fetchMore:ot}=ct(),{threads:W,isLoading:z,fetchMore:L,isFetchingMore:q,hasFetchedAll:K}=mt({query:{metadata:{companyId:o.companyId,application:"dashboard"}}});k.useEffect(()=>{if(V!==i&&i!=null&&s(J(i)),i==null){const e=`../${V}`,p=N(l.state?.pathnameStackToGoBack,l.pathname);t(e,{state:{pathnameStackToGoBack:p}})}},[i]),k.useEffect(()=>{Y.fetchState==="Not-Started"&&s(d({fetchCountState:{fetchState:"In-Progress",error:void 0}},"comments"))},[]),k.useEffect(()=>{if(_===!1&&C===!0&&o?.companyId!=null&&x!=null){const e=`dashboard_${o.companyId}`,p=x.filter(T=>T.roomId===e&&T.readAt==null).length;s(d({fetchCountState:{fetchState:"Completed",error:void 0}},"comments")),s(y({unreadCount:p},"comments"))}},[_,C]),k.useEffect(()=>{j!=="In-Progress"&&g&&s(M("task_manager","dashboard",["read","unread"]))},[g]),k.useEffect(()=>{const e=setTimeout(()=>ot?.(),0);return()=>clearTimeout(e)});const G=_||v===!0||C!==!0||_||v===!0||C!==!0;k.useEffect(()=>{G&&D!=="In-Progress"?s(d({fetchState:"In-Progress",error:void 0},"comments")):G||D!=="In-Progress"||s(d({fetchState:"Completed",error:void 0},"comments"))},[G,D]),k.useEffect(()=>{s(y({hasMore:C!==!0},"comments"))},[C]),k.useEffect(()=>{a.fetchState!=="In-Progress"&&a.fetchState!=="Completed"&&B===!1&&(U(!0),s(It()))},[a.fetchState]),k.useEffect(()=>{if(_===!1&&z===!1&&x!=null&&W!=null){const e=`dashboard_${o.companyId}`,p=x.filter(f=>f.roomId===e).filter(f=>f.kind==="thread"),T=p.filter(f=>f.readAt==null),A=p.map(f=>f.id),it=p.map(f=>{const P=W.find(rt=>rt.id===f.threadId);return P!=null?{inboxNotification:{...f,threadId:P.id},thread:P}:(q||K===!0||L==null||L(),null)}).filter(f=>f!=null);s(d({allNotificationsIds:A},"comments")),s(y({totalCount:A.length,unreadCount:T.length},"comments")),s(Ct(it))}},[_,v,q,C,K,z,x?.length]);const st={events:o.userRoleId!=null?[`private-encrypted-${o.userRoleId}.dashboard-user-notification`]:[],eventCallback:(e,p)=>{if(Pt(p)){const T=Tt(p.mode);if(T==="dashboard"&&s(y({unreadCount:p.data.unread},"tasks")),j!=="In-Progress"){const A=[];R==="all"?A.push("read","unread"):R!=="mentions"&&A.push(R),s(M("task_manager",T,A,!0))}}}},nt=dt();return E.jsx(jt,{tenantEmailDomain:n,loggedInUserRoleMap:O,signedInUser:h,externalNotificationsUnreadCount:tt,location:l,navigate:t,isDebitCardFeatureEnabled:c,users:at,markInboxNotificationAsRead:nt,allUnreadCommentsNotificationIds:et,isAiCfoAccessEnabled:r,onAskAiCfoClick:I,...st})};function ne(){return E.jsxs(gt,{children:[E.jsx(X,{path:"/:selectedTab",element:E.jsx(Vt,{})}),E.jsx(X,{path:"*",element:E.jsx(lt,{})})]})}export{ne as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as m}from"./liveblocks-
|
|
1
|
+
import{j as m}from"./liveblocks-DS8sOLD1.js";import{a as r}from"./sentry-B2Aew07S.js";import{u as T,g as j,j as o,N as A}from"./core-SRRzy8qJ.js";import{Mf as C,eV as D,fJ as P,Mg as x,Mh as z,Mi as L,Mj as R,o6 as k,Lc as N}from"./zeni-epic-state-DcKqCCCg.js";import{z as h,D as I}from"./index-BnX1nS7p.js";import"./mui-DQ-jfgFM.js";import"./recharts-CHATJmXy.js";import"./analytics-C-A3qVJh.js";import"./plaid-DWZgMqW3.js";import"./dnd-CR8sMRK3.js";import"./stripe-DMRn4zHo.js";import"./lottie-Coq2aDEW.js";import"./lexical-qJrDnJMV.js";import"./pdf-D2Xq7623.js";import"./utils-D8kKiFqT.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]="c2210ef0-d802-4d19-a6b1-35f098255155",n._sentryDebugIdIdentifier="sentry-dbid-c2210ef0-d802-4d19-a6b1-35f098255155")}catch{}})();function ee(){const n=T(),s=j(),{params:t,error:i}=r.useMemo(()=>C(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=>D(e)),l=o(e=>P(e)),d=o(e=>e.tenantState.fetchState),y=o(x),v=o(z),c=o(L),[S,b]=r.useState(null),[E,_]=r.useState(null);r.useEffect(()=>{document.querySelector("#app-shell-loader")?.remove()},[]),r.useEffect(()=>()=>{n(R())},[n,s.search]),r.useEffect(()=>{i!=null&&console.warn("[OAuthConsent] invalid params:",i)},[i]);const g=r.useRef(!1);r.useEffect(()=>{f&&a!=null&&!g.current&&(d!=="Not-Started"&&d!=="Error"||(g.current=!0,n(k(a.userId,a.zeniSessionId??void 0))))},[f,a,d,n]),r.useEffect(()=>{c!=null&&c!==""&&(window.location.href=c)},[c]);const M=r.useMemo(()=>{if(p?.tenantId!=null)return p.tenantId;const e=h.getActiveTenantForUser()?.tenantId;return e!=null&&l.some(U=>U.tenantId===e)?e:l.length===1?l[0].tenantId:null},[p?.tenantId,l]),u=S??M;return i!=null?m.jsx(I,{variant:"invalid_params",paramsError:i}):f?m.jsx(I,{variant:"signed_in",clientName:w,userEmail:a?.userEmail,isInitializing:d!=="Completed",tenants:l,selectedTenantId:u,onSelectTenant:b,approveError:E??v,isApproving:y==="In-Progress",showAllowButton:u!=null,onApprove:()=>{t!=null&&a!=null&&u!=null&&n(N(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(A,{to:"/signin/auth",state:{origin:s.pathname+s.search},replace:!0})}export{ee as default};
|
package/dist/assets/{PandLWithForecastRoutes-ClN_7czZ.js → PandLWithForecastRoutes-DtN54cOv.js}
RENAMED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as n}from"./liveblocks-
|
|
1
|
+
import{j as n}from"./liveblocks-DS8sOLD1.js";import{h as z,u as Z,g as J,i as H,j as d,n as K,o as Q,p as I}from"./core-SRRzy8qJ.js";import{eV as P,s9 as M,rJ as X,MM as U,rE as y,bs as ee,bn as ae,bY as te,rF as se,MN as oe,Mz as C,dI as re,vN as ne,MO as ce,w8 as ie,fA as le,fy as de}from"./zeni-epic-state-DcKqCCCg.js";import{z as me,V as fe,Z as pe,I as ue,W as v,U as w,x as he,d as N,ao as be,s as Fe}from"./index-BnX1nS7p.js";import"./mui-DQ-jfgFM.js";import ge from"./NotFoundScreen-DRRoMVDk.js";import{F as Ie}from"./FeaturePreviewScreen-D35UAPet.js";import{a as b}from"./sentry-B2Aew07S.js";import{u as Ce}from"./useAskAiCfoHostNavButtonProps-RYFll1PC.js";import{u as ye}from"./useInitialThreadRequest-8loDIspA.js";import{t as Se}from"./routePaths-DyfF54Mg.js";import{M as Te}from"./MobileAppDrawer-DChLZMjE.js";import"./recharts-CHATJmXy.js";import"./analytics-C-A3qVJh.js";import"./plaid-DWZgMqW3.js";import"./dnd-CR8sMRK3.js";import"./stripe-DMRn4zHo.js";import"./lottie-Coq2aDEW.js";import"./lexical-qJrDnJMV.js";import"./pdf-D2Xq7623.js";import"./utils-D8kKiFqT.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]="ce23e1fc-fd8c-41c7-8ec1-96554bb79bbe",s._sentryDebugIdIdentifier="sentry-dbid-ce23e1fc-fd8c-41c7-8ec1-96554bb79bbe")}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})}},xe=K(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:N}},function(s,e){return{onForecastSelectionChanged:(a,o)=>{s(U(a,o)),e.isPandLReportFetched(a)||s(y(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("../../")}}})(be);function O(){const s=z(),e=Z(),a=J(),{forecastId:o,tenantEmailDomain:r}=H(),[c,p]=b.useState(!1),[m,u]=b.useState(!1),h=me.getSignedInUser(),T=d(t=>P(t)),$=T.company?.companyInfo.firstMonthOfFY??1,i=d(t=>M(t.forecastState,t.forecastListState)),l=d(t=>t.forecastListState.fetchState==="Completed"),x=d(t=>t.profitAndLossState),A=d(t=>t.reportUIOptionsState.selectedForecast),k=t=>x.pandLByForecastID[t]!=null&&se(t,x).reducedAllFetchState.fetchState==="Completed",{areTenantIdsInSync:F}=fe();pe({isDataReady:l});const{isAiCfoAccessEnabled:B,onAskAiCfoClick:V}=Ce({mobileExploreReferrer:"Forecast"});b.useEffect(()=>{if(!c&&F)p(!0),l||e(X());else if(l&&!m){u(!0);const t=((f,L,R)=>L!=null?f.forecasts.findIndex(g=>g.id===L):R!=null?f.forecasts.findIndex(g=>g.id===R):f.forecasts.length>0?0:-1)(i,o,A?.id);t===-1&&o!=null?s("page-not-found",{replace:!0}):t!==-1&&t!=A?.index?(e(U(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&&!k(i.forecasts[t].id)&&F&&e(y(i.forecasts[t].id))}},[c,p,e,l,i,m,u,M,y,F]);const D=ue(),W=D?.loggedInUserRole!=null&&ee(D.loggedInUserRole),{useFeatureGate:Y}=v(),{isFeatureEnabled:E}=Y(w.isReportsCommentingEnabled),_=ye(E?T?.companyId:void 0,{clearParams:l&&m}),[q,G]=b.useState(!1),j=t=>{G(t)};return n.jsxs(n.Fragment,{children:[l?n.jsx(he,{analytics:N,onLoad:t=>(f=>f.trackForecast())(t)}):null,n.jsx(Te,{isAppContentDrawerOpen:q,handleDrawerToggle:j}),n.jsx(xe,{firstMonthOfFY:$,tenantEmailDomain:r,forecastIdFromUrlPath:o,navigate:s,location:a,isPandLReportFetched:k,meetingUrl:te(`https://meetings.hubspot.com/svitlana-grankovska?firstname=${h?.firstName}&lastname=${h?.lastName}&email=${h?.userEmail}`),hasTransactionAccess:W,isAiCfoAccessEnabled:B,onAskAiCfoClick:V,isReportsCommentingEnabled:E,isZeniUser:ae(h),initialOpenThreadRequest:_,onClickMenuIcon:()=>{j(!0)}})]})}function Ge(){const s=d(c=>P(c)),{useFeatureGate:e}=v(),{isFeatureEnabled:a}=e(w.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(ge,{})})]})}export{Ge as PandLWithForecastRoutes,Ge as default};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as s}from"./liveblocks-
|
|
1
|
+
import{j as s}from"./liveblocks-DS8sOLD1.js";import{MI as te,eV as Q,ku as _,fA as q,fy as ne,Ka as X,Mm as oe,uL as Ee,MJ as N,uA as ke,uU as Ie,uO as ie,uE as re,uS as Pe,uP as je,MK as le,wz as Le,fk as Te,gb as ve,ML as M,uI as de,uH as ce,uX as Fe,c6 as Ae}from"./zeni-epic-state-DcKqCCCg.js";import{q as pe,W as Y,U as E,z as G,a9 as ue,A as me,ak as ge,al as Oe,y as he,o as O,C as fe,a as Ce,am as Re,V as Ve,Z as Ue,x as Be,d as be,f as Ze,s as $e,an as Me,I as ze}from"./index-BnX1nS7p.js";import{D as ye,n as H,S as Se}from"./mui-DQ-jfgFM.js";import ae from"./NotFoundScreen-DRRoMVDk.js";import{a as r}from"./sentry-B2Aew07S.js";import{u as ee,i as Ke,j as m,h as _e,g as Ge,n as He,o as se,p as $}from"./core-SRRzy8qJ.js";import{u as We}from"./useAskAiCfoHostNavButtonProps-RYFll1PC.js";import{M as Je}from"./MobileAppDrawer-DChLZMjE.js";import"./recharts-CHATJmXy.js";import"./analytics-C-A3qVJh.js";import"./plaid-DWZgMqW3.js";import"./dnd-CR8sMRK3.js";import"./stripe-DMRn4zHo.js";import"./lottie-Coq2aDEW.js";import"./lexical-qJrDnJMV.js";import"./pdf-D2Xq7623.js";import"./utils-D8kKiFqT.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]="608e049d-0fb3-4a6f-9dec-1d8e6be1cd15",a._sentryDebugIdIdentifier="sentry-dbid-608e049d-0fb3-4a6f-9dec-1d8e6be1cd15")}catch{}})();const Ne={overlayWidth:new he(100,100,48)},z=Ce.getLocalizedStrings().peoplePage.invitePage,Qe=({companyId:a,managersListView:t,companyPassportView:l,classListView:n,mode:g,isEditPeopleDrawerOpen:o,closeDrawerHandler:y})=>{const h=pe(),p=ee(),[R,V]=r.useState(!1),[I,S]=r.useState(!1),{userId:w}=Ke(),d=m(e=>te(e)),u=m(e=>Q(e)),D=m(e=>_(e)),{useFeatureGate:f}=Y(),{isFeatureEnabled:k}=f(E.isDebitCardFeatureEnabled),P=q(k,u),T=ne(u),v=X(u),U=oe(u),B=!!u.company?.featuresActivationInfo?.isReimbursementFeatureEnabled,x=!P&&D&&n.fetchState!=="Completed"||t.fetchState!=="Completed"||l.fetchState!=="Completed"||a==null;if(G.getSignedInUser()==null)throw Error("Can't access invite people page without signing in...");const C=()=>{p(N()),y()},F=()=>{R===!0?S(!0):C()},Z=l.companyView?.controllers?.map(e=>e.user),{isFeatureEnabled:c}=f(E.isDepositAccountsFeatureEnabled),{isFeatureEnabled:j}=f(E.isChargeCardFeatureEnabled),L=ue(u,j,k),{isFeatureEnabled:A}=f(E.isTreasuryEnabled),b={peopleDetails:d,classList:n.classes,managersList:t.users,controllersList:Z,mode:g,isZeniTenant:v,isAccountingClassesEnabled:D,isReimbursementDisabled:B===!1,isZeniAccountsDisabled:c===!1,isChargeCardDisabled:L===!1,isTreasuryDisabled:A===!1,isLiteRoleDisabled:U===!1,isBankingOnlyTenant:P,isCardsOnlyTenant:T,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(v))},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:z.discardTitle}),descriptionComponent:s.jsx(De,{children:z.discardDescription}),primaryButtonText:z.discard,secondaryButtonText:z.no,action:i,isEditPopup:!0}):null,s.jsx(Oe,{...b})]})})},qe=H(Se)`
|
|
2
2
|
display: flex;
|
|
3
3
|
min-height: 100%;
|
|
4
4
|
flex-direction: column;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as s}from"./liveblocks-
|
|
1
|
+
import{j as s}from"./liveblocks-DS8sOLD1.js";import E from"./NotFoundScreen-DRRoMVDk.js";import{a as r}from"./sentry-B2Aew07S.js";import{h as _,g as v,j as p,i as M,u as U,N as P,n as V,o as z,p as h}from"./core-SRRzy8qJ.js";import{eV as B,SY as b,bq as F,bn as N,ib as O,fv as $}from"./zeni-epic-state-DcKqCCCg.js";import{$ as q,z as I,Z as X,cX as Y}from"./index-BnX1nS7p.js";import"./mui-DQ-jfgFM.js";import{u as Z}from"./useAskAiCfoHostNavButtonProps-RYFll1PC.js";import{M as G}from"./MobileAppDrawer-DChLZMjE.js";import"./recharts-CHATJmXy.js";import"./analytics-C-A3qVJh.js";import"./plaid-DWZgMqW3.js";import"./dnd-CR8sMRK3.js";import"./stripe-DMRn4zHo.js";import"./lottie-Coq2aDEW.js";import"./lexical-qJrDnJMV.js";import"./pdf-D2Xq7623.js";import"./utils-D8kKiFqT.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]="50d8e646-1f4a-4a0f-9ba7-acc72348bd63",e._sentryDebugIdIdentifier="sentry-dbid-50d8e646-1f4a-4a0f-9ba7-acc72348bd63")}catch{}})();const H=V(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)}}})(Y),J=()=>{const e=_(),t=v(),c=q(),o=p(a=>B(a)),{aggregatedReportViewState:n}=p(a=>b(a)),{tenantEmailDomain:m}=M(),u=U(),l=I.getSignedInUser();if(l==null)throw new Error("Can't access this page without signing in...");const f=r.useRef(!1),[S,w]=r.useState(!1),C=F(o?.userRole??[]),k=o?.userRole?.includes("bookkeeping_admin")??!1,x=N(l),y=C||k||x,d=r.useCallback((a,i,T)=>{u(O({fromMonth:a,toMonth:i,cacheOverride:T}))},[]);r.useEffect(()=>{n?.fetchState==="Completed"&&f.current&&(u($({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"||d(a,i,!0),f.current=!0},[n?.fetchState,d]),j=r.useCallback((a,i)=>{d(a,i,!1)},[d]),g=a=>{w(a)},{isAiCfoAccessEnabled:R,onAskAiCfoClick:A}=Z({mobileExploreReferrer:"Performance"});return X({isDataReady:n?.fetchState==="Completed"}),y?s.jsxs(s.Fragment,{children:[s.jsx(G,{isAppContentDrawerOpen:S,handleDrawerToggle:g}),s.jsx(H,{navigate:e,location:t,themeState:c,currentTenant:o,signedInUser:l,tenantEmailDomain:m,onReload:D,onTimeRangeSelect:j,handleDrawerToggle:g,isAiCfoAccessEnabled:R,onAskAiCfoClick:A})]}):s.jsx(P,{to:`/${m}/dashboard`,replace:!0})};function ge(){return s.jsxs(z,{children:[s.jsx(h,{path:"*",element:s.jsx(J,{})}),s.jsx(h,{path:"*",element:s.jsx(E,{})})]})}export{ge as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as h,b as t}from"./sentry-
|
|
1
|
+
import{a as h,b as t}from"./sentry-B2Aew07S.js";(function(){try{var r=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},a=new r.Error().stack;a&&(r._sentryDebugIds=r._sentryDebugIds||{},r._sentryDebugIds[a]="a301a95b-8420-43bd-aa56-5738077199ba",r._sentryDebugIdIdentifier="sentry-dbid-a301a95b-8420-43bd-aa56-5738077199ba")}catch{}})();const c="64px",b={};var k=({src:r,light:a,oEmbedUrl:n,onClickPreview:l,playIcon:w,previewTabIndex:m,previewAriaLabel:u})=>{const[p,i]=h.useState(null);h.useEffect(()=>{r&&a&&n&&v({src:r,light:a,oEmbedUrl:n})},[r,a,n]);const v=async({src:e,light:d,oEmbedUrl:I})=>{if(t.isValidElement(d))return;if(typeof d=="string")return void i(d);if(b[e])return void i(b[e]);i(null);const E=await fetch(I.replace("{url}",e)),g=await E.json();if(g.thumbnail_url){const f=g.thumbnail_url.replace("height=100","height=480").replace("-d_295x166","-d_640");i(f),b[e]=f}},o=t.isValidElement(a),y={display:"flex",alignItems:"center",justifyContent:"center"},s={preview:{width:"100%",height:"100%",backgroundImage:p&&!o?`url(${p})`:void 0,backgroundSize:"cover",backgroundPosition:"center",cursor:"pointer",...y},shadow:{background:"radial-gradient(rgb(0, 0, 0, 0.3), rgba(0, 0, 0, 0) 60%)",borderRadius:c,width:c,height:c,position:o?"absolute":void 0,...y},playIcon:{borderStyle:"solid",borderWidth:"16px 0 16px 26px",borderColor:"transparent transparent transparent white",marginLeft:"7px"}},_=t.createElement("div",{style:s.shadow,className:"react-player__shadow"},t.createElement("div",{style:s.playIcon,className:"react-player__play-icon"}));return t.createElement("div",{style:s.preview,className:"react-player__preview",tabIndex:m,onClick:e=>{l?.(e)},onKeyDown:e=>{e.key!=="Enter"&&e.key!==" "||l==null||l(e)},...u?{"aria-label":u}:{}},o?a:null,w||_)};export{k as default};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as Ol}from"./liveblocks-
|
|
1
|
+
import{j as Ol}from"./liveblocks-DS8sOLD1.js";import{p as Q,e as xc,d as kc,g as jl,a as xl}from"./sentry-B2Aew07S.js";import{L as dt,bY as Tc,eV as Ac,LS as Rc,Mk as kl,c6 as Tl,fZ as Al,f_ as Rl}from"./zeni-epic-state-DcKqCCCg.js";import{a as lt,b as Il,c as Pl,d as Nl,e as an,f as Ll,g as $l,h as Ml,i as Vt,j as Ic,k as oe,l as je,m as Cl,o as Yt,p as ue,q as Dl}from"./utils-D8kKiFqT.js";import{r as un}from"./empty-Btqk4ZK3.js";import{r as Fl,a as Bl,b as Ul,c as ql}from"./pdf-lib-fB9Fkl6A.js";import{r as Gl}from"./index-DiKyQs4W.js";import{r as zl}from"./index-6PBzTIZ2.js";import{h as Zl,g as Hl,u as Vl,j as En,n as Yl}from"./core-SRRzy8qJ.js";import{u as Kl,z as Pc,L as Wl,F as Jl,G as Xl,i as Ql,d as tf}from"./index-BnX1nS7p.js";import"./mui-DQ-jfgFM.js";import{d as Pe}from"./decodeURIComponentSafe-Bz-26BXW.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},f=new t.Error().stack;f&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[f]="0f71a4e8-a164-428e-837f-4eb7d4956ebe",t._sentryDebugIdIdentifier="sentry-dbid-0f71a4e8-a164-428e-837f-4eb7d4956ebe")}catch{}})();var _n,Sn={exports:{}},On,jn,xn,kn,Tn,An,Rn,In,Pn,Ne,Nn,Ln,$n,Mn,Cn,Dn,Fn,Bn,Un,qn,Gn,Le,zn,Zn,Hn,Vn,Yn,Kn,Wn,$e,Jn,Xn,Qn,to,eo,ro,no,Me={exports:{}},Ce={exports:{}},De={};function Nc(){if(On)return De;function t(r){return t=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},t(r)}function f(r,e){return f=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(a,p){return a.__proto__=p,a},f(r,e)}function m(r){var e=function(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}();return function(){var a,p=s(r);if(e){var h=s(this).constructor;a=Reflect.construct(p,arguments,h)}else a=p.apply(this,arguments);return function(d,b){if(b&&(t(b)==="object"||typeof b=="function"))return b;if(b!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return function(g){if(g===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return g}(d)}(this,a)}}function s(r){return s=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(e){return e.__proto__||Object.getPrototypeOf(e)},s(r)}On=1;var l,o,n={};function i(r,e,a){a||(a=Error);var p=function(h){(function(c,y){if(typeof y!="function"&&y!==null)throw new TypeError("Super expression must either be null or a function");c.prototype=Object.create(y&&y.prototype,{constructor:{value:c,writable:!0,configurable:!0}}),Object.defineProperty(c,"prototype",{writable:!1}),y&&f(c,y)})(g,h);var d,b=m(g);function g(c,y,v){var S;return function(w,_){if(!(w instanceof _))throw new TypeError("Cannot call a class as a function")}(this,g),S=b.call(this,function(w,_,M){return typeof e=="string"?e:e(w,_,M)}(c,y,v)),S.code=r,S}return d=g,Object.defineProperty(d,"prototype",{writable:!1}),d}(a);n[r]=p}function u(r,e){if(Array.isArray(r)){var a=r.length;return r=r.map(function(p){return String(p)}),a>2?"one of ".concat(e," ").concat(r.slice(0,a-1).join(", "),", or ")+r[a-1]:a===2?"one of ".concat(e," ").concat(r[0]," or ").concat(r[1]):"of ".concat(e," ").concat(r[0])}return"of ".concat(e," ").concat(String(r))}return i("ERR_AMBIGUOUS_ARGUMENT",'The "%s" argument is ambiguous. %s',TypeError),i("ERR_INVALID_ARG_TYPE",function(r,e,a){var p,h,d;if(l===void 0&&(l=ie()),l(typeof r=="string","'name' must be a string"),typeof e=="string"&&(h="not ",e.substr(0,h.length)===h)?(p="must not be",e=e.replace(/^not /,"")):p="must be",function(g,c,y){return(y===void 0||y>g.length)&&(y=g.length),g.substring(y-c.length,y)===c}(r," argument"))d="The ".concat(r," ").concat(p," ").concat(u(e,"type"));else{var b=function(g,c,y){return typeof y!="number"&&(y=0),!(y+c.length>g.length)&&g.indexOf(c,y)!==-1}(r,".")?"property":"argument";d='The "'.concat(r,'" ').concat(b," ").concat(p," ").concat(u(e,"type"))}return d+=". Received type ".concat(t(a))},TypeError),i("ERR_INVALID_ARG_VALUE",function(r,e){var a=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"is invalid";o===void 0&&(o=lt());var p=o.inspect(e);return p.length>128&&(p="".concat(p.slice(0,128),"...")),"The argument '".concat(r,"' ").concat(a,". Received ").concat(p)},TypeError),i("ERR_INVALID_RETURN_VALUE",function(r,e,a){var p;return p=a&&a.constructor&&a.constructor.name?"instance of ".concat(a.constructor.name):"type ".concat(t(a)),"Expected ".concat(r,' to be returned from the "').concat(e,'"')+" function but got ".concat(p,".")},TypeError),i("ERR_MISSING_ARGS",function(){for(var r=arguments.length,e=new Array(r),a=0;a<r;a++)e[a]=arguments[a];l===void 0&&(l=ie()),l(e.length>0,"At least one arg needs to be specified");var p="The ",h=e.length;switch(e=e.map(function(d){return'"'.concat(d,'"')}),h){case 1:p+="".concat(e[0]," argument");break;case 2:p+="".concat(e[0]," and ").concat(e[1]," arguments");break;default:p+=e.slice(0,h-1).join(", "),p+=", and ".concat(e[h-1]," arguments")}return"".concat(p," must be specified")},TypeError),De.codes=n,De}function ef(){if(xn)return jn;function t(k,E){var j=Object.keys(k);if(Object.getOwnPropertySymbols){var x=Object.getOwnPropertySymbols(k);E&&(x=x.filter(function(O){return Object.getOwnPropertyDescriptor(k,O).enumerable})),j.push.apply(j,x)}return j}function f(k){for(var E=1;E<arguments.length;E++){var j=arguments[E]!=null?arguments[E]:{};E%2?t(Object(j),!0).forEach(function(x){m(k,x,j[x])}):Object.getOwnPropertyDescriptors?Object.defineProperties(k,Object.getOwnPropertyDescriptors(j)):t(Object(j)).forEach(function(x){Object.defineProperty(k,x,Object.getOwnPropertyDescriptor(j,x))})}return k}function m(k,E,j){return(E=l(E))in k?Object.defineProperty(k,E,{value:j,enumerable:!0,configurable:!0,writable:!0}):k[E]=j,k}function s(k,E,j){return E&&function(x,O){for(var $=0;$<O.length;$++){var N=O[$];N.enumerable=N.enumerable||!1,N.configurable=!0,"value"in N&&(N.writable=!0),Object.defineProperty(x,l(N.key),N)}}(k.prototype,E),Object.defineProperty(k,"prototype",{writable:!1}),k}function l(k){var E=function(j,x){if(p(j)!=="object"||j===null)return j;var O=j[Symbol.toPrimitive];if(O!==void 0){var $=O.call(j,x);if(p($)!=="object")return $;throw new TypeError("@@toPrimitive must return a primitive value.")}return String(j)}(k,"string");return p(E)==="symbol"?E:String(E)}function o(k,E){if(E&&(p(E)==="object"||typeof E=="function"))return E;if(E!==void 0)throw new TypeError("Derived constructors may only return object or undefined");return n(k)}function n(k){if(k===void 0)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return k}function i(k){var E=typeof Map=="function"?new Map:void 0;return i=function(j){if(j===null||(x=j,Function.toString.call(x).indexOf("[native code]")===-1))return j;var x;if(typeof j!="function")throw new TypeError("Super expression must either be null or a function");if(E!==void 0){if(E.has(j))return E.get(j);E.set(j,O)}function O(){return u(j,arguments,a(this).constructor)}return O.prototype=Object.create(j.prototype,{constructor:{value:O,enumerable:!1,writable:!0,configurable:!0}}),e(O,j)},i(k)}function u(k,E,j){return u=r()?Reflect.construct.bind():function(x,O,$){var N=[null];N.push.apply(N,O);var P=new(Function.bind.apply(x,N));return $&&e(P,$.prototype),P},u.apply(null,arguments)}function r(){if(typeof Reflect>"u"||!Reflect.construct||Reflect.construct.sham)return!1;if(typeof Proxy=="function")return!0;try{return Boolean.prototype.valueOf.call(Reflect.construct(Boolean,[],function(){})),!0}catch{return!1}}function e(k,E){return e=Object.setPrototypeOf?Object.setPrototypeOf.bind():function(j,x){return j.__proto__=x,j},e(k,E)}function a(k){return a=Object.setPrototypeOf?Object.getPrototypeOf.bind():function(E){return E.__proto__||Object.getPrototypeOf(E)},a(k)}function p(k){return p=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(E){return typeof E}:function(E){return E&&typeof Symbol=="function"&&E.constructor===Symbol&&E!==Symbol.prototype?"symbol":typeof E},p(k)}xn=1;var h=lt().inspect,d=Nc().codes.ERR_INVALID_ARG_TYPE;function b(k,E,j){return(j===void 0||j>k.length)&&(j=k.length),k.substring(j-E.length,j)===E}var g="",c="",y="",v="",S={deepStrictEqual:"Expected values to be strictly deep-equal:",strictEqual:"Expected values to be strictly equal:",strictEqualObject:'Expected "actual" to be reference-equal to "expected":',deepEqual:"Expected values to be loosely deep-equal:",equal:"Expected values to be loosely equal:",notDeepStrictEqual:'Expected "actual" not to be strictly deep-equal to:',notStrictEqual:'Expected "actual" to be strictly unequal to:',notStrictEqualObject:'Expected "actual" not to be reference-equal to "expected":',notDeepEqual:'Expected "actual" not to be loosely deep-equal to:',notEqual:'Expected "actual" to be loosely unequal to:',notIdentical:"Values identical but not reference-equal:"};function w(k){var E=Object.keys(k),j=Object.create(Object.getPrototypeOf(k));return E.forEach(function(x){j[x]=k[x]}),Object.defineProperty(j,"message",{value:k.message}),j}function _(k){return h(k,{compact:!1,customInspect:!1,depth:1e3,maxArrayLength:1/0,showHidden:!1,breakLength:1/0,showProxy:!1,sorted:!0,getters:!0})}function M(k,E,j){var x="",O="",$=0,N="",P=!1,G=_(k),A=G.split(`
|
|
2
2
|
`),I=_(E).split(`
|
|
3
3
|
`),R=0,B="";if(j==="strictEqual"&&p(k)==="object"&&p(E)==="object"&&k!==null&&E!==null&&(j="strictEqualObject"),A.length===1&&I.length===1&&A[0]!==I[0]){var V=A[0].length+I[0].length;if(V<=10){if(!(p(k)==="object"&&k!==null||p(E)==="object"&&E!==null||k===0&&E===0))return"".concat(S[j],`
|
|
4
4
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as s}from"./liveblocks-
|
|
1
|
+
import{j as s}from"./liveblocks-DS8sOLD1.js";import{a as o}from"./sentry-B2Aew07S.js";import{j as f,h as O,u as H,g as F,n as N}from"./core-SRRzy8qJ.js";import{m as W,q as _,z as P,be as M,y as U,V as $,Z as q,x as z,d as l,f as G,a7 as Z,bf as J}from"./index-BnX1nS7p.js";import{fE as K,eV as Q,Pi as R,Pj as X,vD as Y,vt as g,fG as ee,bS as re,vy as ae,Pk as ne}from"./zeni-epic-state-DcKqCCCg.js";import{D as te,e as se,n as oe,S as ie}from"./mui-DQ-jfgFM.js";import{u as le}from"./useAskAiCfoHostNavButtonProps-RYFll1PC.js";import{M as de}from"./MobileAppDrawer-DChLZMjE.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]="1040b778-358b-4364-81e9-884fdb034b46",e._sentryDebugIdIdentifier="sentry-dbid-1040b778-358b-4364-81e9-884fdb034b46")}catch{}})();const ce={overlayWidth:new U(100,100,30)},fe=({isReferralDrawerOpen:e,closeDrawerHandler:r})=>{const a=W(),n=_();if(P.getSignedInUser()==null)throw Error("Can't access How Referral works without signing in...");const i=()=>{r(!0)},u=f(d=>K(d));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:d=>d.stopPropagation(),children:s.jsx(M,{onDismissClick:i,rewardsPlan:u.rewardsPlan})})})})},ue=oe(ie)`
|
|
2
2
|
display: flex;
|
|
3
3
|
min-height: 100%;
|
|
4
4
|
flex-direction: column;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{j as r}from"./liveblocks-
|
|
1
|
+
import{j as r}from"./liveblocks-DS8sOLD1.js";import F from"./NotFoundScreen-DRRoMVDk.js";import{a as p}from"./sentry-B2Aew07S.js";import{h as E,g as x,u as C,j as u,N as D,n as V,o as O,p as b}from"./core-SRRzy8qJ.js";import{eV as j,Qc as S,Qs as g,Fz as k,EI as U,Fy as d,Fp as B,QG as L,FB as W}from"./zeni-epic-state-DcKqCCCg.js";import{z as N,a7 as T,bZ as Q,af as $,bC as z,b_ as G}from"./index-BnX1nS7p.js";import"./mui-DQ-jfgFM.js";import{u as K,R as A}from"./ReimbursementApprovalRuleDetailScreen-Btjx5v4l.js";(function(){try{var e=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},o=new e.Error().stack;o&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[o]="e3ddac2a-b647-4177-8d68-9652e00fe3b4",e._sentryDebugIdIdentifier="sentry-dbid-e3ddac2a-b647-4177-8d68-9652e00fe3b4")}catch{}})();const y="reimbursement-approval-rule-update",Z=V(function(e){return{approvalView:S(e),remiSetupApproverViewUpdateData:g(e).remiSetupApproverViewUpdateData}},function(e,o){const{navigate:s,location:n}=o;return{onApprovalRulesEventReceived:t=>{t.endsWith(y)&&e(L(!1))},onBackClick:()=>{$(n)?s("../../"):s("../../../reimbursements/setup")},onDeleteRuleClick:t=>{e(B(t,!1))},onEditRuleClick:t=>{t!=null?(e(d(t)),s(`./${t}/edit`)):(e(d()),s("./new"))}}})(T(Q)),q=({isLoading:e})=>{const o=E(),s=x(),n=C(),[t,i]=p.useState(!1),[m,h]=p.useState(!1),f=u(a=>a.remiSetupApproverViewState.fetchState),l=u(a=>j(a)),c=u(a=>S(a)),v=u(a=>g(a).remiSetupApproverViewUpdateData);if(p.useEffect(()=>{v?.updateStatus.fetchState==="Completed"&&n(k())},[v]),p.useEffect(()=>{t||f!=="Not-Started"||e||(i(!0),n(U(!0,!1,!1,!1)))},[t,f,e,n]),N.getSignedInUser()==null)throw Error("Can't access reimbursement approval without signing in...");p.useEffect(()=>{c.allApprovalRules.length===0&&c.fetchState==="Completed"&&(m||(h(!0),n(d())),o("./new"))},[m,c,n]);const w={events:l.companyId!=null?[`private-encrypted-${l.companyId}.${y}`]:[],eventCallback:(a,_,R)=>{a.endsWith(y)&&R.onApprovalRulesEventReceived(a)}};return l?.companyReimbursementInfo?.info?.isReimbursementTOSAccepted===!1?r.jsx(D,{to:"../../promo"}):r.jsx(Z,{currentTenant:l,location:s,navigate:o,...w})},I="reimbursement-approval-rule-update",H=V(function(e){const o=S(e),s=g(e).remiSetupApproverViewUpdateData,n={};for(const i of Object.values(e.vendorState.vendorByID))i?.id!=null&&(n[i.id]=i.name);const t={};for(const i of Object.values(e.classState.classesByKey))i?.classId!=null&&(t[i.classId]=i.className);return{approvalView:o,remiSetupApproverViewUpdateData:s,vendorNamesById:n,departmentNamesById:t}},function(e,o){const{navigate:s,location:n}=o;return{onApprovalRulesEventReceived:t=>{t.endsWith(I)&&e(L(!1))},onBackClick:()=>{$(n)?s("../../"):s("../../../reimbursements/setup")},onDeleteRuleClick:t=>{e(B(t,!0))},onEditRuleClick:t=>{t!=null?(e(d(t)),s(`./${t}/edit`)):(e(d()),s("./new"))},onReorderRules:t=>{e(W(t,!0))}}})(T(G)),J=()=>{const e=u(n=>j(n)),{isApprovalRulesV3Enabled:o,isLoading:s}=z(e?.tenantId);return o?r.jsx(M,{isLoading:s}):r.jsx(q,{isLoading:s})},M=({isLoading:e})=>{const o=E(),s=x(),n=C(),[t,i]=p.useState(!1),[m,h]=p.useState(!1),f=u(a=>a.remiSetupApproverViewState.fetchState),l=u(a=>j(a)),c=u(a=>S(a));K();const v=u(a=>g(a).remiSetupApproverViewUpdateData);if(p.useEffect(()=>{v?.updateStatus.fetchState==="Completed"&&n(k())},[v]),p.useEffect(()=>{t||f!=="Not-Started"||e||(i(!0),n(U(!0,!1,!1,!0)))},[t,f,e,n]),N.getSignedInUser()==null)throw Error("Can't access reimbursement approval without signing in...");p.useEffect(()=>{c.allApprovalRules.length===0&&c.fetchState==="Completed"&&(m||(h(!0),n(d())),o("./new"))},[m,c,n]);const w={events:l.companyId!=null?[`private-encrypted-${l.companyId}.${I}`]:[],eventCallback:(a,_,R)=>{a.endsWith(I)&&R.onApprovalRulesEventReceived(a)}};return l?.companyReimbursementInfo?.info?.isReimbursementTOSAccepted===!1?r.jsx(D,{to:"../../promo"}):r.jsx(H,{currentTenant:l,location:s,navigate:o,isLoading:e,...w})};function oe(){return r.jsxs(O,{children:[r.jsx(b,{path:"/",element:r.jsx(J,{})}),r.jsx(b,{path:"/new",element:r.jsx(A,{})}),r.jsx(b,{path:"/:approvalRuleId/edit",element:r.jsx(A,{})}),r.jsx(b,{path:"*",element:r.jsx(F,{})})]})}export{oe as R};
|