@zeniai/web-app-ui 5.0.10-dev → 5.0.10-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.
Files changed (58) hide show
  1. package/dist/assets/{AddressRoutes-ClrG4czN.js → AddressRoutes-BAXgA4i8.js} +1 -1
  2. package/dist/assets/{AddressScreen-UQTTt07o.js → AddressScreen-nigwI_KO.js} +1 -1
  3. package/dist/assets/{AiCfoScreen-D0ZuamWZ.js → AiCfoScreen-Ckw592Hw.js} +1 -1
  4. package/dist/assets/{BillPayApprovalRoutes-BLBcPx1B.js → BillPayApprovalRoutes-BMer3wuj.js} +1 -1
  5. package/dist/assets/{BillPayRoutes-7EIRA000.js → BillPayRoutes-C1s11_iz.js} +1 -1
  6. package/dist/assets/{BusinessVerificationPageScreen-BCq9-s11.js → BusinessVerificationPageScreen-CbiCbjAZ.js} +1 -1
  7. package/dist/assets/{ChargeCardRoutes-CqL5qnQo.js → ChargeCardRoutes-YilITIsN.js} +1 -1
  8. package/dist/assets/{CompanyPassportScreen-9atxEdFF.js → CompanyPassportScreen-D4aivbz2.js} +1 -1
  9. package/dist/assets/{ConnectionAuthScreen-BMnYn9YI.js → ConnectionAuthScreen-DqGy4a3m.js} +1 -1
  10. package/dist/assets/{CustomerOnboardingAuthScreen-Cg582Z8u.js → CustomerOnboardingAuthScreen-P2DxwlCb.js} +1 -1
  11. package/dist/assets/{CustomerOnboardingRoutes-QRW1FZfI.js → CustomerOnboardingRoutes-drLdNHDD.js} +1 -1
  12. package/dist/assets/{DashboardRoutes-TZIxTJeb.js → DashboardRoutes-B2wE4D0T.js} +1 -1
  13. package/dist/assets/{DefaultTenantHome-Dhx02wWv.js → DefaultTenantHome-CwZEkfQX.js} +1 -1
  14. package/dist/assets/{DomesticWireDetailScreen-DjDGDTBz.js → DomesticWireDetailScreen-BYpZqZEo.js} +1 -1
  15. package/dist/assets/{DrawerScreen-DG33YoSv.js → DrawerScreen-DkRsu6_3.js} +1 -1
  16. package/dist/assets/{EntityDetailRoutes-Dql5Od85.js → EntityDetailRoutes-Ch0rvPIy.js} +1 -1
  17. package/dist/assets/{ExpenseAutomationRoutes-CYo6nFC7.js → ExpenseAutomationRoutes-C70FMshm.js} +1 -1
  18. package/dist/assets/{FeaturePreviewScreen-DgltNyCi.js → FeaturePreviewScreen-Csy8zadv.js} +1 -1
  19. package/dist/assets/{MagicLinkRoutes-BGM-sZzT.js → MagicLinkRoutes-BQEi0ZJK.js} +1 -1
  20. package/dist/assets/{MagicLinkSignInScreen-CRNknrGE.js → MagicLinkSignInScreen-BOUQOOvb.js} +1 -1
  21. package/dist/assets/{MobileAppDrawer-jslKljAh.js → MobileAppDrawer-CimbS3hY.js} +1 -1
  22. package/dist/assets/{NotFoundScreen-BOOShTFL.js → NotFoundScreen-0YxizmXw.js} +1 -1
  23. package/dist/assets/{NotificationRoutes-DOHToAa0.js → NotificationRoutes--kFdvLLf.js} +1 -1
  24. package/dist/assets/{PandLWithForecastRoutes-DT93-O0O.js → PandLWithForecastRoutes-BgdJ5LRb.js} +1 -1
  25. package/dist/assets/{PeopleRoutes-BdMtXhM0.js → PeopleRoutes-CFGmFJC7.js} +1 -1
  26. package/dist/assets/{PerformanceRoutes-DA01xJZL.js → PerformanceRoutes-DbpgSm9u.js} +1 -1
  27. package/dist/assets/{QBOConnectionScreen-DaAy9F4R.js → QBOConnectionScreen-CYdGz_84.js} +1 -1
  28. package/dist/assets/{ReferralListScreen-CT6Goua6.js → ReferralListScreen-CAKSMH_r.js} +1 -1
  29. package/dist/assets/{ReimbursementApprovalRoutes-C76OIpQC.js → ReimbursementApprovalRoutes-DafN-Tqf.js} +1 -1
  30. package/dist/assets/{ReimbursementApprovalRuleDetailScreen-CwI2DR20.js → ReimbursementApprovalRuleDetailScreen-eQzzNWqC.js} +1 -1
  31. package/dist/assets/{ReimbursementRoutes-By4bhdmE.js → ReimbursementRoutes-BifooTxj.js} +1 -1
  32. package/dist/assets/{ReportsRoutes-CUGvAqPf.js → ReportsRoutes-Ck89aMEv.js} +1 -1
  33. package/dist/assets/{RewardsRoutes-BYzVPFGi.js → RewardsRoutes-CdKUlgwY.js} +1 -1
  34. package/dist/assets/{ScreenRoutes-B6e-0n2O.js → ScreenRoutes-Dv_kin0Y.js} +2 -2
  35. package/dist/assets/{SettingsRoutes-AaKbs5Fo.js → SettingsRoutes-DbKrx5vl.js} +1 -1
  36. package/dist/assets/{SetupPagesScreen-BCxvmwj2.js → SetupPagesScreen-C-SdBEE6.js} +1 -1
  37. package/dist/assets/{SignInScreen-CxIts5DK.js → SignInScreen-DDCpQD2D.js} +1 -1
  38. package/dist/assets/{SignOutScreen-27MvP0w6.js → SignOutScreen-C-4uLvDn.js} +1 -1
  39. package/dist/assets/{TaskListScreen-BCHbQwTl.js → TaskListScreen-C5lfphC9.js} +1 -1
  40. package/dist/assets/{TaskRoutes-Bf2oLDNl.js → TaskRoutes-BbW1TW2g.js} +1 -1
  41. package/dist/assets/{TransactionDetailRoutes-BZGy1w7P.js → TransactionDetailRoutes-CKVbSnqj.js} +1 -1
  42. package/dist/assets/{TransactionDetailScreen-CfRj9Znj.js → TransactionDetailScreen-BWX6dDBh.js} +1 -1
  43. package/dist/assets/{TransactionListRoutes-D0AbWIhY.js → TransactionListRoutes-BMf4CZ_1.js} +1 -1
  44. package/dist/assets/{TreasuryRoutes-CHF8__07.js → TreasuryRoutes-BgPbwTe3.js} +1 -1
  45. package/dist/assets/{VendorsRoutes-FdyKnvtG.js → VendorsRoutes-B8xcZKUi.js} +1 -1
  46. package/dist/assets/{WiseConfirmationScreen-CoxEFEpW.js → WiseConfirmationScreen-Cplv20co.js} +1 -1
  47. package/dist/assets/{ZeniAccountRoutes-C6tX7kSt.js → ZeniAccountRoutes-CwnbuK3E.js} +1 -1
  48. package/dist/assets/{ZeniAccountStatementScreen--z-dKl5C.js → ZeniAccountStatementScreen-B1G-7Ulg.js} +1 -1
  49. package/dist/assets/{analyticsHelper-BvhlneFh.js → analyticsHelper-DMYHMyd-.js} +1 -1
  50. package/dist/assets/{getLocaleForTenant-BNCERJ--.js → getLocaleForTenant-Blx2jmcV.js} +1 -1
  51. package/dist/assets/{index-DO3Ev_EW.js → index-h4jm-UQJ.js} +5 -5
  52. package/dist/assets/{routePaths-BOWJQWRe.js → routePaths-NcYvgIlg.js} +1 -1
  53. package/dist/assets/{useAskAiCfoHostNavButtonProps-BECmuzX_.js → useAskAiCfoHostNavButtonProps-BBHohiIK.js} +1 -1
  54. package/dist/assets/{useFetchSuggestedQuestionsWhenReady-CapxOzLt.js → useFetchSuggestedQuestionsWhenReady-m6vzz_hW.js} +1 -1
  55. package/dist/assets/{useInitialThreadRequest-B5pNRjBx.js → useInitialThreadRequest-CLJyupbh.js} +1 -1
  56. package/dist/assets/{withTransactionSidePanel-IHJ8nGIi.js → withTransactionSidePanel-DT5dIUC2.js} +1 -1
  57. package/dist/index.html +1 -1
  58. package/package.json +1 -1
@@ -1,4 +1,4 @@
1
- import{j as t}from"./liveblocks-CGYIz1sf.js";import{a as u}from"./sentry-ClGNqxTu.js";import{j as T,u as R,h as P,g as m,k as B,l as _,n as W,o as C}from"./core--8kDo-LJ.js";import{bm as Ie,eM as w,gr as ce,Kg as Ce,IF as xe,jm as le,lF as Ee,gt as Ae,Ki as ke,Kh as we,MH as je,w$ as Pe,Bu as ve,Mg as Me,Mp as De,b$ as re,cD as Ue,cE as Te,Is as Fe,MI as Re,It as Be,vr as _e,MJ as Ve,DK as Le,Ba as Oe,B1 as de,A_ as Ne,vv as ue,B4 as pe,B7 as ge,Bd as q,s2 as X,vu as $e,i_ as Y,j1 as me,MK as Ke,k2 as ze,vK as Ge,Jb as Ze,Jc as Je,iY as He,ML as Qe,i$ as We,MM as Ye,vH as qe,MN as Xe,MO as en,Br as nn,eR as fe,eT as he,MP as tn,fw as an,IE as sn,vG as te,fB as ae,fA as on,vF as cn,fz as ln,fy as rn,MQ as dn,eW as be,MR as un,MS as pn,vN as gn,vE as se,MT as mn,fd as fn,vB as hn,bS as bn,b_ as Sn,bZ as yn,bT as In,bX as Cn,bW as xn,bV as En,bY as An,bU as kn}from"./zeni-epic-state-Cb3mJiT_.js";import{i as ee,s as D,z as x,aa as Se,bx as wn,d as K,f as jn,S as V,v as ne,by as Pn,bz as vn,al as Mn,k as ye,bA as Dn,bB as Un,bC as Tn,a4 as Fn,N as Rn,bD as Bn,r as _n,bE as Vn}from"./index-DO3Ev_EW.js";import{n as U}from"./mui-COKu087d.js";import{M as v}from"./MobileAppDrawer-jslKljAh.js";import{a as N,g as $,m as Ln}from"./accountMappingHelper-DC8hLo25.js";import{t as On,A as Nn}from"./AddressScreen-UQTTt07o.js";import F from"./NotFoundScreen-BOOShTFL.js";import{g as $n}from"./analyticsHelper-BvhlneFh.js";import{B as Kn}from"./BusinessVerificationPageScreen-BCq9-s11.js";import{C as zn}from"./CompanyPassportScreen-9atxEdFF.js";import{q as oe}from"./QBOConnectionScreen-DaAy9F4R.js";import{B as Gn}from"./BillPayApprovalRoutes-BLBcPx1B.js";import{R as Zn}from"./ReimbursementApprovalRoutes-C76OIpQC.js";import"./recharts-jENt1xXk.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./utils-C9gYeSwW.js";import"./routePaths-BOWJQWRe.js";import"./empty-Be_BVx3n.js";import"./pdf-lib-C9qLw4cO.js";import"./index-BWzDqQ_Z.js";import"./url-BQx25DrG.js";import"./index-GDJvj_1Q.js";import"./decodeURIComponentSafe-C7w4UFFF.js";import"./ReimbursementApprovalRuleDetailScreen-CwI2DR20.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]="5f83191b-db65-494b-83ac-e0ec9325bf9d",e._sentryDebugIdIdentifier="sentry-dbid-5f83191b-db65-494b-83ac-e0ec9325bf9d")}catch{}})();const Jn=U.div`
1
+ import{j as t}from"./liveblocks-CGYIz1sf.js";import{a as u}from"./sentry-ClGNqxTu.js";import{j as T,u as R,h as P,g as m,k as B,l as _,n as W,o as C}from"./core--8kDo-LJ.js";import{bm as Ie,eM as w,gr as ce,Kg as Ce,IF as xe,jm as le,lF as Ee,gt as Ae,Ki as ke,Kh as we,MH as je,w$ as Pe,Bu as ve,Mg as Me,Mp as De,b$ as re,cD as Ue,cE as Te,Is as Fe,MI as Re,It as Be,vr as _e,MJ as Ve,DK as Le,Ba as Oe,B1 as de,A_ as Ne,vv as ue,B4 as pe,B7 as ge,Bd as q,s2 as X,vu as $e,i_ as Y,j1 as me,MK as Ke,k2 as ze,vK as Ge,Jb as Ze,Jc as Je,iY as He,ML as Qe,i$ as We,MM as Ye,vH as qe,MN as Xe,MO as en,Br as nn,eR as fe,eT as he,MP as tn,fw as an,IE as sn,vG as te,fB as ae,fA as on,vF as cn,fz as ln,fy as rn,MQ as dn,eW as be,MR as un,MS as pn,vN as gn,vE as se,MT as mn,fd as fn,vB as hn,bS as bn,b_ as Sn,bZ as yn,bT as In,bX as Cn,bW as xn,bV as En,bY as An,bU as kn}from"./zeni-epic-state-Cb3mJiT_.js";import{i as ee,s as D,z as x,aa as Se,bx as wn,d as K,f as jn,S as V,v as ne,by as Pn,bz as vn,al as Mn,k as ye,bA as Dn,bB as Un,bC as Tn,a4 as Fn,N as Rn,bD as Bn,r as _n,bE as Vn}from"./index-h4jm-UQJ.js";import{n as U}from"./mui-COKu087d.js";import{M as v}from"./MobileAppDrawer-CimbS3hY.js";import{a as N,g as $,m as Ln}from"./accountMappingHelper-DC8hLo25.js";import{t as On,A as Nn}from"./AddressScreen-nigwI_KO.js";import F from"./NotFoundScreen-0YxizmXw.js";import{g as $n}from"./analyticsHelper-DMYHMyd-.js";import{B as Kn}from"./BusinessVerificationPageScreen-CbiCbjAZ.js";import{C as zn}from"./CompanyPassportScreen-D4aivbz2.js";import{q as oe}from"./QBOConnectionScreen-CYdGz_84.js";import{B as Gn}from"./BillPayApprovalRoutes-BMer3wuj.js";import{R as Zn}from"./ReimbursementApprovalRoutes-DafN-Tqf.js";import"./recharts-jENt1xXk.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./utils-C9gYeSwW.js";import"./routePaths-NcYvgIlg.js";import"./empty-Be_BVx3n.js";import"./pdf-lib-C9qLw4cO.js";import"./index-BWzDqQ_Z.js";import"./url-BQx25DrG.js";import"./index-GDJvj_1Q.js";import"./decodeURIComponentSafe-C7w4UFFF.js";import"./ReimbursementApprovalRuleDetailScreen-eQzzNWqC.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]="5f83191b-db65-494b-83ac-e0ec9325bf9d",e._sentryDebugIdIdentifier="sentry-dbid-5f83191b-db65-494b-83ac-e0ec9325bf9d")}catch{}})();const Jn=U.div`
2
2
  display: flex;
3
3
  height: 100%;
4
4
  width: 100%;
@@ -1,4 +1,4 @@
1
- import{j as u}from"./liveblocks-CGYIz1sf.js";import{j as Y,u as Q,h as X,l as W,g as E,N as M,k as G,q as Qe}from"./core--8kDo-LJ.js";import{bC as Xe,cN as Ie,M4 as ye,eM as x,ct as en,xa as Z,w$ as nn,Mg as tn,Mj as an,pB as ee,pp as ne,jW as te,rA as N,Ml as Ae,fA as $e,fz as We,fy as Ge,Mm as sn,xj as on,Ba as ke,B1 as _e,A_ as ve,AR as K,B4 as Pe,B7 as Ee,Bd as we,s2 as Te,fK as cn,co as rn,eT as un,eR as dn,eS as ln,br as pn,Mn as mn,zT as le,Av as yn,Mo as fn,bD as gn,Cq as pe,Bu as Sn,Mp as bn,Mq as hn,Cu as Cn,Cy as In,rt as An,GE as kn,D3 as Ce,DY as me,Mr as _n,Ms as vn,Mt as Pn,Mu as He,Mv as En,I_ as wn,Lt as Tn,Ja as Dn,Mw as qe,Mx as Fe,Dh as Ke,k2 as Un,ps as Je,rC as On,bB as je,rO as Me,cr as Bn,My as Ye,fc as Fn,CN as xn,CR as Vn,Mz as jn,D6 as Re,MA as Mn,MB as Rn,MC as Nn,MD as zn,fG as Ln,yu as Zn,ME as $n,yz as Wn,yy as Gn}from"./zeni-epic-state-Cb3mJiT_.js";import{S as ae,i as ie,s as de,h as De,aI as J,z as T,O as se,d as w,v as Ue,f as $,bm as Hn,ao as oe,bn as V,bo as qn,bp as Kn,aa as Ve,bq as Jn,r as Ne,ap as ze,J as Yn,A as Qn,br as Xn,bs as et,bt as nt,a1 as tt}from"./index-DO3Ev_EW.js";import{a as C}from"./sentry-ClGNqxTu.js";import{n as xe,D as at,S as it}from"./mui-COKu087d.js";import{M as fe}from"./MobileAppDrawer-jslKljAh.js";import R from"./NotFoundScreen-BOOShTFL.js";import{a as Le}from"./analyticsHelper-BvhlneFh.js";import{c as Ze}from"./routePaths-BOWJQWRe.js";import{B as Be}from"./BusinessVerificationPageScreen-BCq9-s11.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]="29bf36b0-7f0e-4a20-b7f3-cc94e1cec8e6",e._sentryDebugIdIdentifier="sentry-dbid-29bf36b0-7f0e-4a20-b7f3-cc94e1cec8e6")}catch{}})();const st=xe.div`
1
+ import{j as u}from"./liveblocks-CGYIz1sf.js";import{j as Y,u as Q,h as X,l as W,g as E,N as M,k as G,q as Qe}from"./core--8kDo-LJ.js";import{bC as Xe,cN as Ie,M4 as ye,eM as x,ct as en,xa as Z,w$ as nn,Mg as tn,Mj as an,pB as ee,pp as ne,jW as te,rA as N,Ml as Ae,fA as $e,fz as We,fy as Ge,Mm as sn,xj as on,Ba as ke,B1 as _e,A_ as ve,AR as K,B4 as Pe,B7 as Ee,Bd as we,s2 as Te,fK as cn,co as rn,eT as un,eR as dn,eS as ln,br as pn,Mn as mn,zT as le,Av as yn,Mo as fn,bD as gn,Cq as pe,Bu as Sn,Mp as bn,Mq as hn,Cu as Cn,Cy as In,rt as An,GE as kn,D3 as Ce,DY as me,Mr as _n,Ms as vn,Mt as Pn,Mu as He,Mv as En,I_ as wn,Lt as Tn,Ja as Dn,Mw as qe,Mx as Fe,Dh as Ke,k2 as Un,ps as Je,rC as On,bB as je,rO as Me,cr as Bn,My as Ye,fc as Fn,CN as xn,CR as Vn,Mz as jn,D6 as Re,MA as Mn,MB as Rn,MC as Nn,MD as zn,fG as Ln,yu as Zn,ME as $n,yz as Wn,yy as Gn}from"./zeni-epic-state-Cb3mJiT_.js";import{S as ae,i as ie,s as de,h as De,aI as J,z as T,O as se,d as w,v as Ue,f as $,bm as Hn,ao as oe,bn as V,bo as qn,bp as Kn,aa as Ve,bq as Jn,r as Ne,ap as ze,J as Yn,A as Qn,br as Xn,bs as et,bt as nt,a1 as tt}from"./index-h4jm-UQJ.js";import{a as C}from"./sentry-ClGNqxTu.js";import{n as xe,D as at,S as it}from"./mui-COKu087d.js";import{M as fe}from"./MobileAppDrawer-CimbS3hY.js";import R from"./NotFoundScreen-0YxizmXw.js";import{a as Le}from"./analyticsHelper-DMYHMyd-.js";import{c as Ze}from"./routePaths-NcYvgIlg.js";import{B as Be}from"./BusinessVerificationPageScreen-CbiCbjAZ.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]="29bf36b0-7f0e-4a20-b7f3-cc94e1cec8e6",e._sentryDebugIdIdentifier="sentry-dbid-29bf36b0-7f0e-4a20-b7f3-cc94e1cec8e6")}catch{}})();const st=xe.div`
2
2
  display: flex;
3
3
  height: 100%;
4
4
  width: 100%;
@@ -1 +1 @@
1
- import{j as f}from"./liveblocks-CGYIz1sf.js";import{a as u,b as T,q as A}from"./sentry-ClGNqxTu.js";import{h as D,j as z,g as c,u as M,N as j,k as O}from"./core--8kDo-LJ.js";import{u as F,z as s,h as P,d as E,D as N,e as _,f as B,y as V,g as $,j as q,k as v}from"./index-DO3Ev_EW.js";import{eM as J,Ie as Q,If as R,eN as W,fi as H,Il as G,fF as K,cR as X,Im as b,In as Y,Io as Z,bQ as y}from"./zeni-epic-state-Cb3mJiT_.js";import"./mui-COKu087d.js";import{u as ee}from"./useDeviceId-CESE7gTF.js";import{f as te}from"./analyticsHelper-BvhlneFh.js";import{t as ne}from"./getLocaleForTenant-BNCERJ--.js";import"./recharts-jENt1xXk.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./utils-C9gYeSwW.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},i=new t.Error().stack;i&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[i]="3986738b-a8cc-4d13-bbde-1111ee6ee4cf",t._sentryDebugIdIdentifier="sentry-dbid-3986738b-a8cc-4d13-bbde-1111ee6ee4cf")}catch{}})();const ie=O(function(t,i){const d=t.tenantState.fetchState,g=t.tenantState.sendEmailMagicLinkFetchState,{magicLinkExpired:n,magicLinkAlreadyUsed:a,magicLinkExpiredEmail:l}=i;return{googleClientId:v.googleClientId,microsoftClientId:v.microsoftClientId,signInError:t.tenantState.error?.error,fetchState:d,sendMagicLinkStatus:g,magicLinkExpired:n,magicLinkAlreadyUsed:a,magicLinkExpiredEmail:l}},function(t,i){const{location:d,navigate:g}=i;return console.warn(JSON.stringify(window.location)),{onOAuthError:(n,a)=>{A({message:`OAuth error from provider ${a} with error ${n}`,level:"error",tags:{authProvider:a,errorType:"zeni.login.error"},extra:{error:n,windowLocation:window.location.href}})},onOAuthSuccess:(n,a)=>{const l=a==="google"?window.location.origin:window.location.origin+window.location.pathname;t(Z({authCode:n,oauthProvider:a,appType:"web",redirectUri:y(l),sourceUri:y(d.state!=null?d.state.origin:"")}))},getSignedInUser:()=>s.getSignedInUser(),onSignedInCallback:()=>{const n=d.state?.origin;n&&n!=="/"?g(n,{replace:!0}):window.open(window.location.origin,"_self")},sendMagicLink:n=>{const{deviceId:a}=i;a!=null&&(s.saveMagicLinkEmail(n),t(Y(n,a)))},clearSignInError:()=>{t(b())}}})(q),ae=T.memo(ie);function ve({setTenantEmailDomain:t}){const i=D(),d=z(),{clearAllLoading:g}=F(),n=s.getSignedInUser();u.useLayoutEffect(()=>{g()},[g]);const a=ee(),l=c(e=>e.tenantState.magicLinkCodeVerifier),{sendEmailMagicLinkFetchState:h,accountLocked:C,accountUnlockTime:k}=c(e=>e.tenantState),p=c(e=>e.tenantState.fetchState),L=c(e=>e.tenantState.activeTenantFetchState.fetchState),I=c(e=>e.tenantState.signInState),o=c(e=>e.tenantState.loggedInUser),r=c(e=>J(e)),S=c(e=>Q(e)),m=M(),w=P().mode,U=m.state?.magicLinkExpired,x=m.state?.magicLinkAlreadyUsed;if(u.useEffect(()=>{h.fetchState==="Completed"&&l!=null&&(E.trackSignInLinkSent(),s.saveMagicLinkCodeVerifier(l))},[h.fetchState,l]),u.useEffect(()=>{t(void 0)},[]),u.useEffect(()=>{I!=="In-Progress"||p!=="Completed"&&L!=="Completed"||o?.zeniSessionId==null||r==null||(s.savePayNowInfoTooltip(!0,o.zeniSessionId),s.saveSignedInUserWithSession(o,o.zeniSessionId),s.saveSignedInUserTenants(R(S.tenantsInOrder),o.zeniSessionId),W(o.userId,o.zeniSessionId,r.tenantId),i(H(r.tenantId)),s.saveActiveTenantDomainForUser(r.tenantEmailDomain),i(G("Completed")),N.updateAppLocaleID(ne(r)),te(o,r,w,void 0,S.tenantsInOrder),K().then(()=>{const e=$();e!=null&&_(e)}),setTimeout(()=>{E.trackLogin(B.Event.loginSuccess,o.authProvider??"google",X(r.productSettings))},2e3))},[I,p,L,o,r,S,w,m.state,i]),I==="In-Progress"&&p==="Completed"&&o?.zeniSessionId!=null&&r!=null||n!=null){const e=m.state?.origin??"/";return f.jsx(j,{to:e,state:{...m.state,origin:""}})}return f.jsxs(f.Fragment,{children:[f.jsx(ae,{magicLinkExpired:!!U,magicLinkAlreadyUsed:!!x,magicLinkExpiredEmail:s.getMagicLinkEmail()??void 0,location:m,navigate:d,deviceId:a??void 0,showEmailLogin:!0}),C===!0&&k!=null?f.jsx(V,{onClose:()=>i(b()),unlockDate:k}):null]})}export{ve as default};
1
+ import{j as f}from"./liveblocks-CGYIz1sf.js";import{a as u,b as T,q as A}from"./sentry-ClGNqxTu.js";import{h as D,j as z,g as c,u as M,N as j,k as O}from"./core--8kDo-LJ.js";import{u as F,z as s,h as P,d as E,D as N,e as _,f as B,y as V,g as $,j as q,k as v}from"./index-h4jm-UQJ.js";import{eM as J,Ie as Q,If as R,eN as W,fi as H,Il as G,fF as K,cR as X,Im as b,In as Y,Io as Z,bQ as y}from"./zeni-epic-state-Cb3mJiT_.js";import"./mui-COKu087d.js";import{u as ee}from"./useDeviceId-CESE7gTF.js";import{f as te}from"./analyticsHelper-DMYHMyd-.js";import{t as ne}from"./getLocaleForTenant-Blx2jmcV.js";import"./recharts-jENt1xXk.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./utils-C9gYeSwW.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},i=new t.Error().stack;i&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[i]="3986738b-a8cc-4d13-bbde-1111ee6ee4cf",t._sentryDebugIdIdentifier="sentry-dbid-3986738b-a8cc-4d13-bbde-1111ee6ee4cf")}catch{}})();const ie=O(function(t,i){const d=t.tenantState.fetchState,g=t.tenantState.sendEmailMagicLinkFetchState,{magicLinkExpired:n,magicLinkAlreadyUsed:a,magicLinkExpiredEmail:l}=i;return{googleClientId:v.googleClientId,microsoftClientId:v.microsoftClientId,signInError:t.tenantState.error?.error,fetchState:d,sendMagicLinkStatus:g,magicLinkExpired:n,magicLinkAlreadyUsed:a,magicLinkExpiredEmail:l}},function(t,i){const{location:d,navigate:g}=i;return console.warn(JSON.stringify(window.location)),{onOAuthError:(n,a)=>{A({message:`OAuth error from provider ${a} with error ${n}`,level:"error",tags:{authProvider:a,errorType:"zeni.login.error"},extra:{error:n,windowLocation:window.location.href}})},onOAuthSuccess:(n,a)=>{const l=a==="google"?window.location.origin:window.location.origin+window.location.pathname;t(Z({authCode:n,oauthProvider:a,appType:"web",redirectUri:y(l),sourceUri:y(d.state!=null?d.state.origin:"")}))},getSignedInUser:()=>s.getSignedInUser(),onSignedInCallback:()=>{const n=d.state?.origin;n&&n!=="/"?g(n,{replace:!0}):window.open(window.location.origin,"_self")},sendMagicLink:n=>{const{deviceId:a}=i;a!=null&&(s.saveMagicLinkEmail(n),t(Y(n,a)))},clearSignInError:()=>{t(b())}}})(q),ae=T.memo(ie);function ve({setTenantEmailDomain:t}){const i=D(),d=z(),{clearAllLoading:g}=F(),n=s.getSignedInUser();u.useLayoutEffect(()=>{g()},[g]);const a=ee(),l=c(e=>e.tenantState.magicLinkCodeVerifier),{sendEmailMagicLinkFetchState:h,accountLocked:C,accountUnlockTime:k}=c(e=>e.tenantState),p=c(e=>e.tenantState.fetchState),L=c(e=>e.tenantState.activeTenantFetchState.fetchState),I=c(e=>e.tenantState.signInState),o=c(e=>e.tenantState.loggedInUser),r=c(e=>J(e)),S=c(e=>Q(e)),m=M(),w=P().mode,U=m.state?.magicLinkExpired,x=m.state?.magicLinkAlreadyUsed;if(u.useEffect(()=>{h.fetchState==="Completed"&&l!=null&&(E.trackSignInLinkSent(),s.saveMagicLinkCodeVerifier(l))},[h.fetchState,l]),u.useEffect(()=>{t(void 0)},[]),u.useEffect(()=>{I!=="In-Progress"||p!=="Completed"&&L!=="Completed"||o?.zeniSessionId==null||r==null||(s.savePayNowInfoTooltip(!0,o.zeniSessionId),s.saveSignedInUserWithSession(o,o.zeniSessionId),s.saveSignedInUserTenants(R(S.tenantsInOrder),o.zeniSessionId),W(o.userId,o.zeniSessionId,r.tenantId),i(H(r.tenantId)),s.saveActiveTenantDomainForUser(r.tenantEmailDomain),i(G("Completed")),N.updateAppLocaleID(ne(r)),te(o,r,w,void 0,S.tenantsInOrder),K().then(()=>{const e=$();e!=null&&_(e)}),setTimeout(()=>{E.trackLogin(B.Event.loginSuccess,o.authProvider??"google",X(r.productSettings))},2e3))},[I,p,L,o,r,S,w,m.state,i]),I==="In-Progress"&&p==="Completed"&&o?.zeniSessionId!=null&&r!=null||n!=null){const e=m.state?.origin??"/";return f.jsx(j,{to:e,state:{...m.state,origin:""}})}return f.jsxs(f.Fragment,{children:[f.jsx(ae,{magicLinkExpired:!!U,magicLinkAlreadyUsed:!!x,magicLinkExpiredEmail:s.getMagicLinkEmail()??void 0,location:m,navigate:d,deviceId:a??void 0,showEmailLogin:!0}),C===!0&&k!=null?f.jsx(V,{onClose:()=>i(b()),unlockDate:k}):null]})}export{ve as default};
@@ -1,4 +1,4 @@
1
- import{j as s}from"./liveblocks-CGYIz1sf.js";import{a as n}from"./sentry-ClGNqxTu.js";import{h as c,u as m,j as p,N as g}from"./core--8kDo-LJ.js";import{z as d,v as y,t as h,d as f,f as b}from"./index-DO3Ev_EW.js";import{IB as I,Ij as x,IC as j}from"./zeni-epic-state-Cb3mJiT_.js";import{n as v}from"./mui-COKu087d.js";import"./recharts-jENt1xXk.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./utils-C9gYeSwW.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]="31fdf977-a47a-4655-b7e9-40586787dd85",e._sentryDebugIdIdentifier="sentry-dbid-31fdf977-a47a-4655-b7e9-40586787dd85")}catch{}})();function $(){const e=c(),t=m(),i=p(),a=n.useRef(!1),l=d.isSignedIn(),r=t.state?.message==="logout",o=r||l;return n.useEffect(()=>{o&&!a.current&&(a.current=!0,setTimeout(()=>{try{d.clearAll(),e(I()),e(x(!1)),j(),h.reset(),f.trackLogout(b.Event.logoutSuccess),f.resetUserIdentity()}catch(u){console.error("Error during sign out:",u)}finally{r||i("/signin/auth",{replace:!0})}},0))},[o,r]),o?s.jsx(w,{children:s.jsx(y,{fetchState:"In-Progress"})}):s.jsx(g,{to:"../",replace:!0})}const w=v.div`
1
+ import{j as s}from"./liveblocks-CGYIz1sf.js";import{a as n}from"./sentry-ClGNqxTu.js";import{h as c,u as m,j as p,N as g}from"./core--8kDo-LJ.js";import{z as d,v as y,t as h,d as f,f as b}from"./index-h4jm-UQJ.js";import{IB as I,Ij as x,IC as j}from"./zeni-epic-state-Cb3mJiT_.js";import{n as v}from"./mui-COKu087d.js";import"./recharts-jENt1xXk.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./utils-C9gYeSwW.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]="31fdf977-a47a-4655-b7e9-40586787dd85",e._sentryDebugIdIdentifier="sentry-dbid-31fdf977-a47a-4655-b7e9-40586787dd85")}catch{}})();function $(){const e=c(),t=m(),i=p(),a=n.useRef(!1),l=d.isSignedIn(),r=t.state?.message==="logout",o=r||l;return n.useEffect(()=>{o&&!a.current&&(a.current=!0,setTimeout(()=>{try{d.clearAll(),e(I()),e(x(!1)),j(),h.reset(),f.trackLogout(b.Event.logoutSuccess),f.resetUserIdentity()}catch(u){console.error("Error during sign out:",u)}finally{r||i("/signin/auth",{replace:!0})}},0))},[o,r]),o?s.jsx(w,{children:s.jsx(y,{fetchState:"In-Progress"})}):s.jsx(g,{to:"../",replace:!0})}const w=v.div`
2
2
  display: flex;
3
3
  height: 100vh;
4
4
  width: 100%;
@@ -1,4 +1,4 @@
1
- import{j as k}from"./liveblocks-CGYIz1sf.js";import{a as m}from"./sentry-ClGNqxTu.js";import{j,h as N,u as R,g as G,l as O,k as $}from"./core--8kDo-LJ.js";import{M as v,z as K,i as M,s as U,O as q,d as _,f as z,cA as V,r as f,q as W}from"./index-DO3Ev_EW.js";import{eM as Q,Pl as L,Fp as y,Pm as w,Ph as H,EQ as S,Pn as J,EU as I,Et as X,Fq as b,Po as B,gy as Y,Ff as Z,Fk as aa,F7 as ta,F5 as ea,Fl as sa,F2 as oa,Pp as na,Pq as ia,Pr as la,Ps as u,eh as ra,Pt as ca,Pu as pa}from"./zeni-epic-state-Cb3mJiT_.js";import{n as ka}from"./mui-COKu087d.js";import{u as ua}from"./useAskAiCfoHostNavButtonProps-BECmuzX_.js";import{c as da}from"./useFetchSuggestedQuestionsWhenReady-CapxOzLt.js";import{M as ma}from"./MobileAppDrawer-jslKljAh.js";import"./recharts-jENt1xXk.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./utils-C9gYeSwW.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},e=new t.Error().stack;e&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[e]="a29a66a7-7891-44de-93ce-e0b81656af61",t._sentryDebugIdIdentifier="sentry-dbid-a29a66a7-7891-44de-93ce-e0b81656af61")}catch{}})();const fa=ka.div`
1
+ import{j as k}from"./liveblocks-CGYIz1sf.js";import{a as m}from"./sentry-ClGNqxTu.js";import{j,h as N,u as R,g as G,l as O,k as $}from"./core--8kDo-LJ.js";import{M as v,z as K,i as M,s as U,O as q,d as _,f as z,cA as V,r as f,q as W}from"./index-h4jm-UQJ.js";import{eM as Q,Pl as L,Fp as y,Pm as w,Ph as H,EQ as S,Pn as J,EU as I,Et as X,Fq as b,Po as B,gy as Y,Ff as Z,Fk as aa,F7 as ta,F5 as ea,Fl as sa,F2 as oa,Pp as na,Pq as ia,Pr as la,Ps as u,eh as ra,Pt as ca,Pu as pa}from"./zeni-epic-state-Cb3mJiT_.js";import{n as ka}from"./mui-COKu087d.js";import{u as ua}from"./useAskAiCfoHostNavButtonProps-BBHohiIK.js";import{c as da}from"./useFetchSuggestedQuestionsWhenReady-m6vzz_hW.js";import{M as ma}from"./MobileAppDrawer-CimbS3hY.js";import"./recharts-jENt1xXk.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./utils-C9gYeSwW.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},e=new t.Error().stack;e&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[e]="a29a66a7-7891-44de-93ce-e0b81656af61",t._sentryDebugIdIdentifier="sentry-dbid-a29a66a7-7891-44de-93ce-e0b81656af61")}catch{}})();const fa=ka.div`
2
2
  display: flex;
3
3
  min-height: 100%;
4
4
  width: 100%;
@@ -1,4 +1,4 @@
1
- import{j as s}from"./liveblocks-CGYIz1sf.js";import M from"./NotFoundScreen-BOOShTFL.js";import{a as p}from"./sentry-ClGNqxTu.js";import{j as A,h as R,u as $,l as q,g as f,N as z,k as O,n as V,o as u}from"./core--8kDo-LJ.js";import{Z as _,z as w,r as b,O as Z,d as E,f as Q,cz as W,k as H,ao as J,q as K}from"./index-DO3Ev_EW.js";import{eM as C,Ph as G,EM as v,EA as X,Fc as Y,Pi as P,Pj as ee,Ew as ae,Et as te,pB as se,pp as ne,jW as oe,EG as ie,Pk as re,ED as le,ER as ce,EQ as de}from"./zeni-epic-state-Cb3mJiT_.js";import{n as pe}from"./mui-COKu087d.js";import{u as me}from"./useInitialThreadRequest-B5pNRjBx.js";import{M as ue}from"./MobileAppDrawer-jslKljAh.js";import ke from"./TaskListScreen-BCHbQwTl.js";import"./recharts-jENt1xXk.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./utils-C9gYeSwW.js";import"./useAskAiCfoHostNavButtonProps-BECmuzX_.js";import"./useFetchSuggestedQuestionsWhenReady-CapxOzLt.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]="33e8c216-2a8f-4bee-aeab-2dda34942dd6",e._sentryDebugIdIdentifier="sentry-dbid-33e8c216-2a8f-4bee-aeab-2dda34942dd6")}catch{}})();const fe=O(function(e,t){const{location:n,taskGroupId:l}=t,d=P(e,t.taskId),c=C(e),i=l!=null?ee(e.taskGroupState,l):void 0,m=w.getSignedInUser(),a=c.tenantId,r={userId:m?.userId??"",sessionId:m?.zeniSessionId??"",tenantId:a??""},k=G(e);return{taskDetailSelectorView:d,authParams:r,isNewClicked:n.state?.message==="comingFromTaskListPage",filesEndPoint:J.fileMicroServiceBaseUrl,companyName:t.currentTenant.companyName,companyId:t.currentTenant.companyId,currentUrl:`${H.appUrl}${t.location.pathname}`,tagListView:k,taskGroupName:l!=null&&i!=null&&i.isDefault===!1?i.name:void 0}},function(e,t){const{taskId:n,navigate:l,currentTenant:d,location:c,taskGroupId:i}=t,{tenantEmailDomain:m}=d;return{onSaveChangesToLocalStore:a=>{e(de({taskDetailLocalData:a,taskId:n}))},onSaveDetailClick:()=>{e(ce(n,i))},onArchiveTaskClick:()=>{t.taskId!=null&&e(le(t.taskId))},onDismissClick:()=>{if(c.state?.message==="triggerBackClick"){const a=K(c.state?.pathnameStackToGoBack),r=a.poppedPathname??"../../dashboard";l(r,{state:{pathnameStackToGoBack:a.newStack}})}else{const a=B(m),r=b(c.state?.pathnameStackToGoBack,c.pathname);l(a,{state:{pathnameStackToGoBack:r}})}e(re({taskId:n}))},onDeleteTaskClick:()=>{e(ie(n))},updateFilesEntity:a=>{e(oe({files:a}))},onDeleteFile:a=>{e(ne(a))},onEditFileName:(a,r)=>{e(se(a,r.split(".")[0]))},onReloadTaskDetailPage:()=>{e(v(!1,n))},onCreateTagClick:a=>{e(te(a,n))},onDeleteTagClick:a=>{e(ae(a,n))}}})(W);function I(){const e=A(),t=R(),n=$(),l=_(),{taskId:d,taskGroupId:c}=q(),i=f(o=>C(o)),m=me(i?.companyId),[a,r]=p.useState(!1),[k,F]=p.useState(!1),[S,L]=p.useState(!1),[x,N]=p.useState(!1),j=f(o=>G(o)),y=f(o=>o.taskGroupViewState.fetchState);p.useEffect(()=>{k||(F(!0),t(v(!1,d)))},[k,t]),p.useEffect(()=>{S||j.fetchState==="Completed"||(L(!0),t(X()))},[S,t,j.fetchState]),p.useEffect(()=>{x||y==="Completed"||(N(!0),t(Y()))},[x,t,y]);const D=f(o=>P(o,d)),g=D.fetchState,T=w.getSignedInUser();if(T==null)throw Error("Can't access task detail page without signing in...");if(g==="Error"&&D.error?.code===400){const{tenantEmailDomain:o}=i,h=B(o),U=b(n.state?.pathnameStackToGoBack,n.pathname);return s.jsx(z,{to:h,state:{pathnameStackToGoBack:U}})}return s.jsxs(s.Fragment,{children:[g==="Completed"?s.jsx(Z,{analytics:E,onLoad:o=>(h=>h.trackPageLoaded(Q.Event.taskDetailPage))(o)}):null,s.jsxs(ge,{children:[s.jsx(ue,{isAppContentDrawerOpen:a,handleDrawerToggle:o=>{r(o)}}),s.jsx(fe,{analytics:E,currentTenant:i,handleZeniLogoClick:()=>{l.toggle()},initialOpenThreadRequest:m,location:n,loggedInUser:T,navigate:e,taskGroupId:c,taskId:d,taskDetailFetchState:g})]})]})}const ge=pe.div`
1
+ import{j as s}from"./liveblocks-CGYIz1sf.js";import M from"./NotFoundScreen-0YxizmXw.js";import{a as p}from"./sentry-ClGNqxTu.js";import{j as A,h as R,u as $,l as q,g as f,N as z,k as O,n as V,o as u}from"./core--8kDo-LJ.js";import{Z as _,z as w,r as b,O as Z,d as E,f as Q,cz as W,k as H,ao as J,q as K}from"./index-h4jm-UQJ.js";import{eM as C,Ph as G,EM as v,EA as X,Fc as Y,Pi as P,Pj as ee,Ew as ae,Et as te,pB as se,pp as ne,jW as oe,EG as ie,Pk as re,ED as le,ER as ce,EQ as de}from"./zeni-epic-state-Cb3mJiT_.js";import{n as pe}from"./mui-COKu087d.js";import{u as me}from"./useInitialThreadRequest-CLJyupbh.js";import{M as ue}from"./MobileAppDrawer-CimbS3hY.js";import ke from"./TaskListScreen-C5lfphC9.js";import"./recharts-jENt1xXk.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./utils-C9gYeSwW.js";import"./useAskAiCfoHostNavButtonProps-BBHohiIK.js";import"./useFetchSuggestedQuestionsWhenReady-m6vzz_hW.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]="33e8c216-2a8f-4bee-aeab-2dda34942dd6",e._sentryDebugIdIdentifier="sentry-dbid-33e8c216-2a8f-4bee-aeab-2dda34942dd6")}catch{}})();const fe=O(function(e,t){const{location:n,taskGroupId:l}=t,d=P(e,t.taskId),c=C(e),i=l!=null?ee(e.taskGroupState,l):void 0,m=w.getSignedInUser(),a=c.tenantId,r={userId:m?.userId??"",sessionId:m?.zeniSessionId??"",tenantId:a??""},k=G(e);return{taskDetailSelectorView:d,authParams:r,isNewClicked:n.state?.message==="comingFromTaskListPage",filesEndPoint:J.fileMicroServiceBaseUrl,companyName:t.currentTenant.companyName,companyId:t.currentTenant.companyId,currentUrl:`${H.appUrl}${t.location.pathname}`,tagListView:k,taskGroupName:l!=null&&i!=null&&i.isDefault===!1?i.name:void 0}},function(e,t){const{taskId:n,navigate:l,currentTenant:d,location:c,taskGroupId:i}=t,{tenantEmailDomain:m}=d;return{onSaveChangesToLocalStore:a=>{e(de({taskDetailLocalData:a,taskId:n}))},onSaveDetailClick:()=>{e(ce(n,i))},onArchiveTaskClick:()=>{t.taskId!=null&&e(le(t.taskId))},onDismissClick:()=>{if(c.state?.message==="triggerBackClick"){const a=K(c.state?.pathnameStackToGoBack),r=a.poppedPathname??"../../dashboard";l(r,{state:{pathnameStackToGoBack:a.newStack}})}else{const a=B(m),r=b(c.state?.pathnameStackToGoBack,c.pathname);l(a,{state:{pathnameStackToGoBack:r}})}e(re({taskId:n}))},onDeleteTaskClick:()=>{e(ie(n))},updateFilesEntity:a=>{e(oe({files:a}))},onDeleteFile:a=>{e(ne(a))},onEditFileName:(a,r)=>{e(se(a,r.split(".")[0]))},onReloadTaskDetailPage:()=>{e(v(!1,n))},onCreateTagClick:a=>{e(te(a,n))},onDeleteTagClick:a=>{e(ae(a,n))}}})(W);function I(){const e=A(),t=R(),n=$(),l=_(),{taskId:d,taskGroupId:c}=q(),i=f(o=>C(o)),m=me(i?.companyId),[a,r]=p.useState(!1),[k,F]=p.useState(!1),[S,L]=p.useState(!1),[x,N]=p.useState(!1),j=f(o=>G(o)),y=f(o=>o.taskGroupViewState.fetchState);p.useEffect(()=>{k||(F(!0),t(v(!1,d)))},[k,t]),p.useEffect(()=>{S||j.fetchState==="Completed"||(L(!0),t(X()))},[S,t,j.fetchState]),p.useEffect(()=>{x||y==="Completed"||(N(!0),t(Y()))},[x,t,y]);const D=f(o=>P(o,d)),g=D.fetchState,T=w.getSignedInUser();if(T==null)throw Error("Can't access task detail page without signing in...");if(g==="Error"&&D.error?.code===400){const{tenantEmailDomain:o}=i,h=B(o),U=b(n.state?.pathnameStackToGoBack,n.pathname);return s.jsx(z,{to:h,state:{pathnameStackToGoBack:U}})}return s.jsxs(s.Fragment,{children:[g==="Completed"?s.jsx(Z,{analytics:E,onLoad:o=>(h=>h.trackPageLoaded(Q.Event.taskDetailPage))(o)}):null,s.jsxs(ge,{children:[s.jsx(ue,{isAppContentDrawerOpen:a,handleDrawerToggle:o=>{r(o)}}),s.jsx(fe,{analytics:E,currentTenant:i,handleZeniLogoClick:()=>{l.toggle()},initialOpenThreadRequest:m,location:n,loggedInUser:T,navigate:e,taskGroupId:c,taskId:d,taskDetailFetchState:g})]})]})}const ge=pe.div`
2
2
  display: flex;
3
3
  min-height: 100%;
4
4
  width: 100%;
@@ -1 +1 @@
1
- import{j as t}from"./liveblocks-CGYIz1sf.js";import i from"./NotFoundScreen-BOOShTFL.js";import{T as r}from"./TransactionDetailScreen-CfRj9Znj.js";import"./sentry-ClGNqxTu.js";import{n as d,o as e}from"./core--8kDo-LJ.js";import"./zeni-epic-state-Cb3mJiT_.js";import"./recharts-jENt1xXk.js";import"./index-DO3Ev_EW.js";import"./mui-COKu087d.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./utils-C9gYeSwW.js";import"./useAskAiCfoHostNavButtonProps-BECmuzX_.js";import"./useFetchSuggestedQuestionsWhenReady-CapxOzLt.js";import"./decodeURIComponentSafe-C7w4UFFF.js";import"./routePaths-BOWJQWRe.js";(function(){try{var o=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},n=new o.Error().stack;n&&(o._sentryDebugIds=o._sentryDebugIds||{},o._sentryDebugIds[n]="256f287b-7a3d-4d6d-890e-a8cb9db8b86d",o._sentryDebugIdIdentifier="sentry-dbid-256f287b-7a3d-4d6d-890e-a8cb9db8b86d")}catch{}})();function q(){return t.jsxs(d,{children:[t.jsx(e,{path:"/:transactionTypeEncoded/:transactionId",element:t.jsx(r,{})}),t.jsx(e,{path:"/:transactionTypeEncoded/:transactionId/page-not-found",element:t.jsx(i,{})}),t.jsx(e,{path:"/:transactionTypeEncoded/:transactionId/vendor/create",element:t.jsx(r,{})}),t.jsx(e,{path:"/*",element:t.jsx(r,{})})]})}export{q as default};
1
+ import{j as t}from"./liveblocks-CGYIz1sf.js";import i from"./NotFoundScreen-0YxizmXw.js";import{T as r}from"./TransactionDetailScreen-BWX6dDBh.js";import"./sentry-ClGNqxTu.js";import{n as d,o as e}from"./core--8kDo-LJ.js";import"./zeni-epic-state-Cb3mJiT_.js";import"./recharts-jENt1xXk.js";import"./index-h4jm-UQJ.js";import"./mui-COKu087d.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./utils-C9gYeSwW.js";import"./useAskAiCfoHostNavButtonProps-BBHohiIK.js";import"./useFetchSuggestedQuestionsWhenReady-m6vzz_hW.js";import"./decodeURIComponentSafe-C7w4UFFF.js";import"./routePaths-NcYvgIlg.js";(function(){try{var o=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},n=new o.Error().stack;n&&(o._sentryDebugIds=o._sentryDebugIds||{},o._sentryDebugIds[n]="256f287b-7a3d-4d6d-890e-a8cb9db8b86d",o._sentryDebugIdIdentifier="sentry-dbid-256f287b-7a3d-4d6d-890e-a8cb9db8b86d")}catch{}})();function q(){return t.jsxs(d,{children:[t.jsx(e,{path:"/:transactionTypeEncoded/:transactionId",element:t.jsx(r,{})}),t.jsx(e,{path:"/:transactionTypeEncoded/:transactionId/page-not-found",element:t.jsx(i,{})}),t.jsx(e,{path:"/:transactionTypeEncoded/:transactionId/vendor/create",element:t.jsx(r,{})}),t.jsx(e,{path:"/*",element:t.jsx(r,{})})]})}export{q as default};
@@ -1,4 +1,4 @@
1
- import{j as I}from"./liveblocks-CGYIz1sf.js";import{a as d}from"./sentry-ClGNqxTu.js";import{h as K,g as S,u as re,j as le,l as de,N as Ke,k as je}from"./core--8kDo-LJ.js";import{bm as Me,eM as W,cM as ue,bu as me,pg as H,Jo as B,Kp as pe,Kq as Y,JO as fe,jx as he,Kr as ge,JT as Q,JU as X,km as Se,Gw as Z,Ji as _,jr as Te,jp as ye,jB as $e,Ks as Je,Kt as qe,t5 as G,jw as ve,FT as Ee,cS as We,cT as He,Ku as Ye,Jh as Qe,Kv as Xe,t9 as Ze,Kw as ea,Kx as aa,Ky as ta,Kz as na,KA as oa,jA as sa,KB as ia,KC as ca,Jj as ra,KD as la,KE as da,KF as ua,FN as ma,FB as pa,G3 as fa,jC as ha,Gx as ie,FK as ga}from"./zeni-epic-state-Cb3mJiT_.js";import{z as Ce,i as ee,s as V,aI as De,h as Sa,J as Ta,aJ as ya,A as va,q as J,S as Ea,aK as Ca,r as q,M as Da,d as be,aL as ba,ao as Ia,T as $}from"./index-DO3Ev_EW.js";import{n as ka,S as Aa,D as Ua}from"./mui-COKu087d.js";import{u as xa}from"./useAskAiCfoHostNavButtonProps-BECmuzX_.js";import{c as _a}from"./useFetchSuggestedQuestionsWhenReady-CapxOzLt.js";import{d as Ie}from"./decodeURIComponentSafe-C7w4UFFF.js";import{h as ke,g as Va,d as Fa,b as wa}from"./routePaths-BOWJQWRe.js";import{t as Ba}from"./utils-C9gYeSwW.js";(function(){try{var a=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},e=new a.Error().stack;e&&(a._sentryDebugIds=a._sentryDebugIds||{},a._sentryDebugIds[e]="3db68eef-9191-450c-bfc8-325327f49415",a._sentryDebugIdIdentifier="sentry-dbid-3db68eef-9191-450c-bfc8-325327f49415")}catch{}})();const ae=()=>{const a=Ce.getSignedInUser(),{useFeatureGate:e}=ee(),{isFeatureEnabled:s}=e(V.isChainOfThoughtEnabled);return d.useMemo(()=>Me(a)&&s,[a,s])};function Ae(a){if(a!=null){if("customer"in a&&a.customer!=null){const{customer:e}=a;return{id:e.id,name:e.name,logo:e.logo,type:"customer",zeniId:e.id,qboId:e.id}}if("vendor"in a&&a.vendor!=null){const{vendor:e}=a;return{id:e.id,name:e.name,logo:e.logo,type:"vendor",zeniId:e.id,qboId:e.id}}}}function Za(a,e){const s=K(),{useFeatureGate:t,useDynamicConfig:n}=ee(),o=S(u=>W(u)),i=o.userRole.includes("charge_card_user")||o.userRole.includes("charge_card_admin"),l=o.userRole!=null&&ue(o.userRole),g=o.userRole!=null&&me(o.userRole),{isFeatureEnabled:T}=t(V.isVendorBulkUpdateOnTransactionEnabled),{isFeatureEnabled:b}=t(V.isExpenseAutomationEnabled),{configValue:f}=n(De.enableUncategorizedExpenseCategory),h=f?.uncategorized_expense_category_enabled===!0,k=ae(),y=d.useMemo(()=>({id:a,type:H(e)}),[a,e]),m=S(u=>B(u,y)),D=S(u=>{const N=B(u,y)?.transactionDetailLocalData.vendorUpdates?.id;return N==null?"Not-Started":u.transactionVendorViewState.editVendorStateById[N]?.saveStatus.fetchState??"Not-Started"}),p=d.useMemo(()=>m?.fetchState==="Completed"?Ae(m?.transaction):void 0,[m?.fetchState,m?.transaction]),E=S(u=>{if(p!=null)return pe(u.customerIncomeState,u.vendorExpenseState,u.trendState,p,"month")}),A=S(u=>Y(u)),F=S(u=>{if(p!=null)return fe(u.trendWithTransactionsState,p,"TransactionDetail")}),j=o.company?.companyInfo.firstMonthOfFY??1,M=S(u=>he(u.accountState,u.accountListState,"accountList")),[P,w]=d.useState(!1),[L,v]=d.useState(!1),[c,O]=d.useState(!1);d.useEffect(()=>{w(!1),v(!1),O(!1)},[a,e]);const C=d.useCallback(()=>{w(!1),v(!1)},[]),[U,x]=d.useState(!1),z=F?.selectedPeriod?.timePeriod;return d.useEffect(()=>{c||m==null||m.transaction==null||(s(ge({id:m.transaction.id,type:m.transaction.type})),O(!0)),p!=null&&(!i||l&&g===!1)&&(P?L||E==null||(v(!0),s(Z(p,"TransactionDetail",{timeframe:"month",timePeriod:z??E}))):(s(Q()),s(X()),w(!0),s(Se(p))))},[s,c,m?.fetchState,m?.transaction,p,i,l,g,P,L,E,z]),d.useEffect(()=>{A.newVendorState?.vendorDetailLocalData?.vendorName!=null?x(!0):x(!1)},[A.newVendorState?.vendorDetailLocalData?.vendorName]),d.useEffect(()=>()=>{s(_("common"))},[s]),{currentTenant:o,loggedInUserHasCardUserOrAdminRole:i,isUserHasDashboardAccess:l,isUserHasInvestorOrBankerAccess:g,isVendorBulkUpdateOnTransactionEnabled:T,isExpenseAutomationEnabled:b,isUncategorizedExpenseCategoryEnabled:h,isChainOfThoughtEnabled:k,selectedTransaction:y,transactionDetail:m,vendorSaveStatus:D,tranEntity:p,defaultTrendTransactionTimePeriod:E,vendorViewDetails:A,uiState:F,firstMonthOfFY:j,uncategorizedAccounts:M,resetTrendIsFetchedStates:C,isCreateVendorDrawerOpen:U,setIsCreateVendorDrawerOpen:x}}const Pa={overlayWidth:new va(100,100,58)},La=({isOpen:a,onSaveVendor:e,onSaveSuccess:s,onCancel:t,vendorViewDetails:n})=>{const o=Sa(),i=Ta(),l=K(),g=S(f=>Y(f)),T=()=>{t()},b={vendorDetailView:n??g,onSaveSuccess:()=>{l(ye()),l($e("Not-Started")),s()},onSaveVendor:e,onCancelClick:T,saveVendorDetailLocalData:f=>{l(Te({vendorId:void 0,localData:f}))}};return I.jsx(Ua,{anchor:"right",open:a,PaperProps:{style:{width:Pa.overlayWidth.valuePercentage(i),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:o.colors.black,opacity:.4,cursor:"pointer"}}},onClose:T,children:I.jsx(Oa,{onClick:f=>f.stopPropagation(),children:I.jsx(ya,{...b})})})},Oa=ka(Aa)`
1
+ import{j as I}from"./liveblocks-CGYIz1sf.js";import{a as d}from"./sentry-ClGNqxTu.js";import{h as K,g as S,u as re,j as le,l as de,N as Ke,k as je}from"./core--8kDo-LJ.js";import{bm as Me,eM as W,cM as ue,bu as me,pg as H,Jo as B,Kp as pe,Kq as Y,JO as fe,jx as he,Kr as ge,JT as Q,JU as X,km as Se,Gw as Z,Ji as _,jr as Te,jp as ye,jB as $e,Ks as Je,Kt as qe,t5 as G,jw as ve,FT as Ee,cS as We,cT as He,Ku as Ye,Jh as Qe,Kv as Xe,t9 as Ze,Kw as ea,Kx as aa,Ky as ta,Kz as na,KA as oa,jA as sa,KB as ia,KC as ca,Jj as ra,KD as la,KE as da,KF as ua,FN as ma,FB as pa,G3 as fa,jC as ha,Gx as ie,FK as ga}from"./zeni-epic-state-Cb3mJiT_.js";import{z as Ce,i as ee,s as V,aI as De,h as Sa,J as Ta,aJ as ya,A as va,q as J,S as Ea,aK as Ca,r as q,M as Da,d as be,aL as ba,ao as Ia,T as $}from"./index-h4jm-UQJ.js";import{n as ka,S as Aa,D as Ua}from"./mui-COKu087d.js";import{u as xa}from"./useAskAiCfoHostNavButtonProps-BBHohiIK.js";import{c as _a}from"./useFetchSuggestedQuestionsWhenReady-m6vzz_hW.js";import{d as Ie}from"./decodeURIComponentSafe-C7w4UFFF.js";import{h as ke,g as Va,d as Fa,b as wa}from"./routePaths-NcYvgIlg.js";import{t as Ba}from"./utils-C9gYeSwW.js";(function(){try{var a=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},e=new a.Error().stack;e&&(a._sentryDebugIds=a._sentryDebugIds||{},a._sentryDebugIds[e]="3db68eef-9191-450c-bfc8-325327f49415",a._sentryDebugIdIdentifier="sentry-dbid-3db68eef-9191-450c-bfc8-325327f49415")}catch{}})();const ae=()=>{const a=Ce.getSignedInUser(),{useFeatureGate:e}=ee(),{isFeatureEnabled:s}=e(V.isChainOfThoughtEnabled);return d.useMemo(()=>Me(a)&&s,[a,s])};function Ae(a){if(a!=null){if("customer"in a&&a.customer!=null){const{customer:e}=a;return{id:e.id,name:e.name,logo:e.logo,type:"customer",zeniId:e.id,qboId:e.id}}if("vendor"in a&&a.vendor!=null){const{vendor:e}=a;return{id:e.id,name:e.name,logo:e.logo,type:"vendor",zeniId:e.id,qboId:e.id}}}}function Za(a,e){const s=K(),{useFeatureGate:t,useDynamicConfig:n}=ee(),o=S(u=>W(u)),i=o.userRole.includes("charge_card_user")||o.userRole.includes("charge_card_admin"),l=o.userRole!=null&&ue(o.userRole),g=o.userRole!=null&&me(o.userRole),{isFeatureEnabled:T}=t(V.isVendorBulkUpdateOnTransactionEnabled),{isFeatureEnabled:b}=t(V.isExpenseAutomationEnabled),{configValue:f}=n(De.enableUncategorizedExpenseCategory),h=f?.uncategorized_expense_category_enabled===!0,k=ae(),y=d.useMemo(()=>({id:a,type:H(e)}),[a,e]),m=S(u=>B(u,y)),D=S(u=>{const N=B(u,y)?.transactionDetailLocalData.vendorUpdates?.id;return N==null?"Not-Started":u.transactionVendorViewState.editVendorStateById[N]?.saveStatus.fetchState??"Not-Started"}),p=d.useMemo(()=>m?.fetchState==="Completed"?Ae(m?.transaction):void 0,[m?.fetchState,m?.transaction]),E=S(u=>{if(p!=null)return pe(u.customerIncomeState,u.vendorExpenseState,u.trendState,p,"month")}),A=S(u=>Y(u)),F=S(u=>{if(p!=null)return fe(u.trendWithTransactionsState,p,"TransactionDetail")}),j=o.company?.companyInfo.firstMonthOfFY??1,M=S(u=>he(u.accountState,u.accountListState,"accountList")),[P,w]=d.useState(!1),[L,v]=d.useState(!1),[c,O]=d.useState(!1);d.useEffect(()=>{w(!1),v(!1),O(!1)},[a,e]);const C=d.useCallback(()=>{w(!1),v(!1)},[]),[U,x]=d.useState(!1),z=F?.selectedPeriod?.timePeriod;return d.useEffect(()=>{c||m==null||m.transaction==null||(s(ge({id:m.transaction.id,type:m.transaction.type})),O(!0)),p!=null&&(!i||l&&g===!1)&&(P?L||E==null||(v(!0),s(Z(p,"TransactionDetail",{timeframe:"month",timePeriod:z??E}))):(s(Q()),s(X()),w(!0),s(Se(p))))},[s,c,m?.fetchState,m?.transaction,p,i,l,g,P,L,E,z]),d.useEffect(()=>{A.newVendorState?.vendorDetailLocalData?.vendorName!=null?x(!0):x(!1)},[A.newVendorState?.vendorDetailLocalData?.vendorName]),d.useEffect(()=>()=>{s(_("common"))},[s]),{currentTenant:o,loggedInUserHasCardUserOrAdminRole:i,isUserHasDashboardAccess:l,isUserHasInvestorOrBankerAccess:g,isVendorBulkUpdateOnTransactionEnabled:T,isExpenseAutomationEnabled:b,isUncategorizedExpenseCategoryEnabled:h,isChainOfThoughtEnabled:k,selectedTransaction:y,transactionDetail:m,vendorSaveStatus:D,tranEntity:p,defaultTrendTransactionTimePeriod:E,vendorViewDetails:A,uiState:F,firstMonthOfFY:j,uncategorizedAccounts:M,resetTrendIsFetchedStates:C,isCreateVendorDrawerOpen:U,setIsCreateVendorDrawerOpen:x}}const Pa={overlayWidth:new va(100,100,58)},La=({isOpen:a,onSaveVendor:e,onSaveSuccess:s,onCancel:t,vendorViewDetails:n})=>{const o=Sa(),i=Ta(),l=K(),g=S(f=>Y(f)),T=()=>{t()},b={vendorDetailView:n??g,onSaveSuccess:()=>{l(ye()),l($e("Not-Started")),s()},onSaveVendor:e,onCancelClick:T,saveVendorDetailLocalData:f=>{l(Te({vendorId:void 0,localData:f}))}};return I.jsx(Ua,{anchor:"right",open:a,PaperProps:{style:{width:Pa.overlayWidth.valuePercentage(i),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:o.colors.black,opacity:.4,cursor:"pointer"}}},onClose:T,children:I.jsx(Oa,{onClick:f=>f.stopPropagation(),children:I.jsx(ya,{...b})})})},Oa=ka(Aa)`
2
2
  display: flex;
3
3
  min-height: 100%;
4
4
  flex-direction: column;
@@ -1 +1 @@
1
- import{j as i}from"./liveblocks-CGYIz1sf.js";import{j as q,u as w,h as U,l as Q,g as L,N as B,k as H,n as Ae,o as v}from"./core--8kDo-LJ.js";import{eM as R,iL as T,NM as W,Gn as ue,bp as ie,NN as he,jm as Z,JQ as K,NO as se,NP as Se,bB as x,Gk as me,NQ as ke,NR as re,NS as Ie,NT as pe,NU as be,NV as ve,NW as de,HA as Ye,bm as xe}from"./zeni-epic-state-Cb3mJiT_.js";import{D as X,d as C,c2 as ee,r as _,q as te,i as fe,s as J,N as Pe,z as Ee}from"./index-DO3Ev_EW.js";import"./mui-COKu087d.js";import{a as A}from"./sentry-ClGNqxTu.js";import{w as ae}from"./withTransactionSidePanel-IHJ8nGIi.js";import{p as ne,b as ce}from"./routePaths-BOWJQWRe.js";import{u as Le}from"./utils-C9gYeSwW.js";import{d as E}from"./decodeURIComponentSafe-C7w4UFFF.js";import{Z as je}from"./ZeniAccountStatementScreen--z-dKl5C.js";import"./recharts-jENt1xXk.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./useAskAiCfoHostNavButtonProps-BECmuzX_.js";import"./useFetchSuggestedQuestionsWhenReady-CapxOzLt.js";import"./TransactionDetailScreen-CfRj9Znj.js";(function(){try{var a=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},e=new a.Error().stack;e&&(a._sentryDebugIds=a._sentryDebugIds||{},a._sentryDebugIds[e]="6e73cff1-c71c-43c7-a79e-342c6f878fac",a._sentryDebugIdIdentifier="sentry-dbid-6e73cff1-c71c-43c7-a79e-342c6f878fac")}catch{}})();const G=a=>Le(a),Me=H(function(a,e){const t=he(a.transactionState,a.transactionListState,e.selectedAccount.period,e.selectedAccount.timeframe,G(e.selectedAccount.tranListType));return{title:e.selectedAccount.title,subTitle:e.selectedAccount.subTitle,timeframe:e.selectedAccount.timeframe,timePeriod:K(e.selectedAccount.period),dataAvailableForPeriod:e.dataAvailableForPeriod,report:t,currentScrollYOffset:t.uiState?.scrollYOffset??0,isAccountingClassesEnabled:Z(a)}},function(a,e){return{onBackClick:()=>{const t=te(e.location.state?.pathnameStackToGoBack),n=t.poppedPathname??"../../";e.navigate(n,{state:{pathnameStackToGoBack:t.newStack}})},onTimePeriodChange:(t,n,c)=>{e.closeSidePanel?.();const o=X.getLocalizedStrings(),r=G(e.selectedAccount.tranListType),s=Ce(t,n,c,r,e.bookCloseDate);C.trackTransactionList(void 0,void 0,void 0,e.selectedAccount.title,void 0,!0),a(se({uiState:{dateRange:s},type:G(e.selectedAccount.tranListType)})),a(ue(r,T(s),!1,r==="missingReceipts"?o.uncategorizedTransactionList.missingReceipt.missingReceiptMinAmount:void 0)),e.onSelectedTimePeriodChange(T(s))},onTransactionItemClick:t=>{if(e.openTransactionPanel)return void e.openTransactionPanel(t.id,t.type);const n=ce(t,e.tenantEmailDomain),c=_(e.location.state?.pathnameStackToGoBack,e.location.pathname);e.navigate(n,{state:{pathnameStackToGoBack:c}})},onTransactionListScroll:t=>{a(se({uiState:{scrollYOffset:t},type:G(e.selectedAccount.tranListType)}))}}})(ee),F=ae(function({...a}){const e=q(),t=w(),n=U(),c=t.pathname.substring(t.pathname.lastIndexOf("/")+1),{tenantEmailDomain:o}=Q(),r=X.getLocalizedStrings(),{accountType:s,title:u,subTitle:h}=ze(c),D="month",g=L(p=>R(p)),Y=g.company?.companyInfo.firstMonthOfFY??1,{dataAvailable:y,initialTimeframeTick:S}=Be(c,Y,g.bookCloseDate),[k,j]=A.useState(!1),[M,P]=A.useState(void 0),m=A.useMemo(()=>{const p=T(S);return{tranListType:c,accountType:W(s),title:u,subTitle:h,timeframe:D,period:p}},[c,D,s,y]);A.useEffect(()=>{if(!k&&m!=null){j(!0),C.trackTransactionList(void 0,void 0,void 0,m.title);const p=G(m.tranListType);n(ue(p,m.period,!0,p==="missingReceipts"?r.uncategorizedTransactionList.missingReceipt.missingReceiptMinAmount:void 0))}},[k,m,n]);let I=m;return m!=null&&M!=null&&(I={...m,period:M}),I==null?i.jsx(B,{to:"../"}):i.jsx(Me,{firstMonthOfFY:Y,tenantEmailDomain:o,location:t,useFixedPeriod:{timeframe:"month",numberOfPeriods:12},dataAvailableForPeriod:y,navigate:e,selectedAccount:I,referrerType:c,bookCloseDate:g.bookCloseDate,onSelectedTimePeriodChange:p=>P(p),...a})}),ze=a=>{let e="",t="",n="";const c=X.getLocalizedStrings();switch(a){case"uncategorized-income":e="income",t=c.uncategorizedTransactionList.income.title,n=c.uncategorizedTransactionList.income.subTitle;break;case"uncategorized-expense":e="expenses",t=c.uncategorizedTransactionList.expense.title,n=c.uncategorizedTransactionList.expense.subTitle;break;case"miscategorized-expense":e="expenses",t=c.miscategorizedTransactionList.expense.title,n=c.miscategorizedTransactionList.expense.subTitle;break;case"miscategorized-income":e="income",t=c.miscategorizedTransactionList.income.title,n=c.miscategorizedTransactionList.income.subTitle;break;case"missing-receipts":t=c.uncategorizedTransactionList.missingReceipt.title,n=c.uncategorizedTransactionList.missingReceipt.subTitle}return{accountType:e,title:t,subTitle:n}},Be=(a,e,t)=>{const n=ie();let c=ie().startOf("month").subtract(11,"month");return t!=null&&a!=="missing-receipts"?t.add(1,"day").isBefore(c)?{dataAvailable:{startDate:t.add(1,"day"),endDate:n},initialTimeframeTick:{startDate:c,endDate:n}}:(c=t.add(1,"day"),{dataAvailable:{startDate:c,endDate:n},initialTimeframeTick:{startDate:c,endDate:n}}):{dataAvailable:ne(5,e),initialTimeframeTick:{startDate:c,endDate:n}}},Ce=(a,e,t,n,c)=>{let o=e;return n==="missingReceipts"||c==null?a.startDate.isBefore(e.startDate,t)?o={startDate:a.startDate,endDate:e.endDate}:a.startDate.isAfter(e.endDate,t)?o={startDate:e.startDate,endDate:a.endDate}:console.error(`Invalid addTimePeriod ${JSON.stringify(a)}`):o=a.startDate.isBefore(c,t)?{startDate:c.add(1,"day"),endDate:e.endDate}:{startDate:a.startDate,endDate:e.endDate},o},Oe=H(function(a,e){const t=ke(a.transactionState,a.transactionListState,e.selectedAccount.accountId,e.selectedAccount.accountType,e.selectedAccount.classId,e.selectedAccount.timeframe,e.selectedAccount.period);return{accountId:e.selectedAccount.accountId,accountType:e.selectedAccount.accountType,title:e.selectedAccount.title,timeframe:e.selectedAccount.timeframe,timePeriod:K(e.selectedAccount.period),dataAvailableForPeriod:ne(5,e.firstMonthOfFY),report:t,currentScrollYOffset:t.uiState?.scrollYOffset??0,isAccountingClassesEnabled:Z(a)}},function(a,e){return{onBackClick:()=>{const t=te(e.location.state?.pathnameStackToGoBack),n=t.poppedPathname??Te();e.navigate(n,{state:{pathnameStackToGoBack:t.newStack}})},onTimePeriodChange:(t,n,c)=>{e.closeSidePanel?.();let o=n;t.startDate.isBefore(n.startDate,c)?o={startDate:t.startDate,endDate:n.endDate}:t.startDate.isAfter(n.endDate,c)?o={startDate:n.startDate,endDate:t.endDate}:console.error(`Invalid addTimePeriod ${JSON.stringify(t)}`),C.trackTransactionList(e.selectedAccount.accountId,void 0,e.referrerType,e.selectedAccount.title,void 0,!0),a(re({accountId:e.selectedAccount.accountId,accountType:e.selectedAccount.accountType,classId:e.selectedAccount.classId,uiState:{dateRange:o}})),a(me(e.selectedAccount.accountId,e.selectedAccount.accountType,e.selectedAccount.classId,T(o))),e.onSelectedTimePeriodChange(T(o))},onTransactionItemClick:t=>{if(e.openTransactionPanel)return void e.openTransactionPanel(t.id,t.type);const n=ce(t,e.tenantEmailDomain),c=_(e.location.state?.pathnameStackToGoBack,e.location.pathname);e.navigate(n,{state:{pathnameStackToGoBack:c}})},onTransactionListScroll:t=>{a(re({accountId:e.selectedAccount.accountId,accountType:e.selectedAccount.accountType,classId:e.selectedAccount.classId,uiState:{scrollYOffset:t}}))}}})(ee),Fe=ae(function({referrerType:a,...e}){const t=q(),n=w(),c=U(),{tenantEmailDomain:o,accountTypeEncoded:r,accountIdEncoded:s,classIdEncoded:u,timeframe:h,startDate:D,endDate:g,titleEncoded:Y}=Q(),y=E(r??""),S=E(s??""),k=E(u??""),j=E(Y??""),M=L(f=>Se(f.transactionListState,S,y,k)),[P,m]=A.useState(!1),[I,p]=A.useState(void 0),N=L(f=>R(f)),$=N.company?.companyInfo.firstMonthOfFY??1;let d;const l=Ge(y,S,k,h,D,g,j);if(l){const f={startDate:x(D,"YYYY-MM-DD"),endDate:x(g,"YYYY-MM-DD")},V=Ne(M?.dateRange,f);d={accountId:S,accountType:W(y),classId:k,title:j,timeframe:h,period:V}}A.useEffect(()=>{P||d==null||(m(!0),C.trackTransactionList(d.accountId,void 0,a,d.title),c(me(d.accountId,d.accountType,d.classId,d.period)))},[P,d,c]);let z=d;d!=null&&I!=null&&(z={...d,period:I});const O=[r,s,u,h,D,g,Y].filter(f=>f!=null);return l&&z!=null?i.jsx(Oe,{firstMonthOfFY:$,tenantEmailDomain:o,location:n,navigate:t,selectedAccount:z,referrerType:a,onSelectedTimePeriodChange:f=>p(f),...e}):i.jsx(B,{to:Te(O.length)})}),Te=(a=7)=>{let e="../";for(let t=0;t<a;t++)e=`${e}../`;return e},Ge=(a,e,t,n,c,o,r)=>a!=null&&e!=null&&t!=null&&n!=null&&c!=null&&o!=null&&(n==="month"||n==="quarter")&&x(c,"YYYY-MM-DD").isValid()&&x(o,"YYYY-MM-DD").isValid()&&r!=null,Ne=(a,e)=>a!=null&&a.endDate.isSame(e.endDate,"day")&&a.startDate.isBefore(e.startDate,"day")?T(a):T(e),_e=H(function(a,e){const t=be(a.transactionState,a.transactionListState,e.selectedAccount.accountId,e.selectedAccount.accountType,e.selectedAccount.timeframe,e.selectedAccount.period),n=t.account?.coaId,c=e.isConnectedAccountProviderUnit&&ve(n??"");return{accountId:e.selectedAccount.accountId,accountType:e.selectedAccount.accountType,title:e.selectedAccount.title,timeframe:e.selectedAccount.timeframe,timePeriod:K(e.selectedAccount.period),dataAvailableForPeriod:ne(5,e.firstMonthOfFY),report:t,currentScrollYOffset:t.uiState?.scrollYOffset??0,showStatementPageIcon:c,isAccountingClassesEnabled:Z(a)}},function(a,e){return{onBackClick:()=>{const t=te(e.location.state?.pathnameStackToGoBack),n=t.poppedPathname??De();e.navigate(n,{state:{pathnameStackToGoBack:t.newStack}})},onTimePeriodChange:(t,n,c)=>{e.closeSidePanel?.();let o=n;t.startDate.isBefore(n.startDate,c)?o={startDate:t.startDate,endDate:n.endDate}:t.startDate.isAfter(n.endDate,c)?o={startDate:n.startDate,endDate:t.endDate}:console.error(`Invalid addTimePeriod ${JSON.stringify(t)}`),C.trackTransactionList(e.selectedAccount.accountId,void 0,e.referrerType,e.selectedAccount.title,void 0,!0),a(de({accountId:e.selectedAccount.accountId,accountType:e.selectedAccount.accountType,uiState:{dateRange:o}})),a(pe(e.selectedAccount.accountId,e.selectedAccount.accountType,T(o))),e.onSelectedTimePeriodChange(T(o))},onTransactionItemClick:t=>{if(e.openTransactionPanel)return void e.openTransactionPanel(t.id,t.type);const n=ce(t,e.tenantEmailDomain),c=_(e.location.state?.pathnameStackToGoBack,e.location.pathname);e.navigate(n,{state:{pathnameStackToGoBack:c}})},onTransactionListScroll:t=>{a(de({accountId:e.selectedAccount.accountId,accountType:e.selectedAccount.accountType,uiState:{scrollYOffset:t}}))},onStatementPageIconClick:()=>{const t=$e(e.tenantEmailDomain),n=_(e.location.state?.pathnameStackToGoBack,e.location.pathname);e.navigate(t,{state:{pathnameStackToGoBack:n}})}}})(ee),le=ae(function({referrerType:a,...e}){const t=q(),n=w(),c=U(),{tenantEmailDomain:o,accountTypeEncoded:r,accountIdEncoded:s,timeframe:u,startDate:h,endDate:D,titleEncoded:g,excludeSubAccounts:Y}=Q(),y=E(r??""),S=E(s??""),k=E(g??""),j=!(Y!=null&&Y==="exclude_subaccounts"),M=L(b=>Ie(b.transactionListState,S,y)),[P,m]=A.useState(!1),[I,p]=A.useState(void 0),N=L(b=>R(b)),$=N.company?.featuresActivationInfo.connectedAccountProvider==="unit",d=N.company?.companyInfo.firstMonthOfFY??1;let l;const z=we(y,S,u,h,D,k);if(z){const b={startDate:x(h,"YYYY-MM-DD"),endDate:x(D,"YYYY-MM-DD")},ye=Re(M?.dateRange,b);l={accountId:S,accountType:W(y),title:k,timeframe:u,period:ye}}let O=l;l!=null&&I!=null&&(O={...l,period:I});const{useFeatureGate:f}=fe(),{isFeatureEnabled:V}=f(J.isTransactionCommentingEnabled),{areTenantIdsInSync:oe}=Pe();A.useEffect(()=>{!P&&l!=null&&oe&&(m(!0),C.trackTransactionList(l.accountId,void 0,a,l.title),c(pe(l.accountId,l.accountType,l.period,void 0,!1,j)))},[P,l,c,oe]);const ge=[r,s,u,h,D,g].filter(b=>b!=null);return z&&O!=null?i.jsx(_e,{firstMonthOfFY:d,tenantEmailDomain:o,location:n,navigate:t,isConnectedAccountProviderUnit:$,isTransactionCommentingEnabled:V,selectedAccount:O,referrerType:a,onSelectedTimePeriodChange:b=>p(b),...e}):i.jsx(B,{to:De(ge.length)})}),De=(a=7)=>{let e="../";for(let t=0;t<a;t++)e=`${e}../`;return e},we=(a,e,t,n,c,o)=>a!=null&&e!=null&&t!=null&&n!=null&&c!=null&&(t==="month"||t==="quarter")&&x(n,"YYYY-MM-DD").isValid()&&x(c,"YYYY-MM-DD").isValid()&&o!=null,Re=(a,e)=>a!=null&&a.endDate.isSame(e.endDate,"day")&&a.startDate.isBefore(e.startDate,"day")?T(a):T(e),$e=a=>`/${a}/transactions/${Ye}/statements`;function mt(){const a=w().state?.referrer,e=Ee.getSignedInUser(),t=xe(e),{useFeatureGate:n}=fe(),{isFeatureEnabled:c}=n(J.isExpenseAutomationEnabled),o=L(u=>u.expenseAutomationViewState.selectedPeriodByTenantId)[L(u=>R(u)).tenantId],{isFeatureEnabled:r}=n(J.isExpenseAutomationEnabledV2),s=r||c&&t;return i.jsxs(Ae,{children:[i.jsx(v,{path:"/:accountTypeEncoded/:accountIdEncoded/:timeframe/:startDate/:endDate/:titleEncoded/:excludeSubAccounts/*",element:i.jsx(le,{referrerType:a})}),i.jsx(v,{path:"/zeni-clearing-account/statements",element:i.jsx(je,{})}),i.jsx(v,{path:"/*",element:i.jsx(le,{referrerType:a})}),i.jsx(v,{path:"/uncategorized-income/*",element:i.jsx(F,{})}),i.jsx(v,{path:"/uncategorized-expense/*",element:s?i.jsx(B,{to:`../../month_end_close_checks/review/transaction_categorization/${o.month}-${o.year}`}):i.jsx(F,{})}),i.jsx(v,{path:"/miscategorized-income/*",element:i.jsx(F,{})}),i.jsx(v,{path:"/miscategorized-expense/*",element:s?i.jsx(B,{to:`../../month_end_close_checks/review/transaction_categorization/${o.month}-${o.year}`}):i.jsx(F,{})}),i.jsx(v,{path:"/missing-receipts/*",element:s?i.jsx(B,{to:`../../month_end_close_checks/review/missing_receipts/${o.month}-${o.year}`}):i.jsx(F,{})}),i.jsx(v,{path:"/by-class/:accountTypeEncoded/:accountIdEncoded/:classIdEncoded/:timeframe/:startDate/:endDate/:titleEncoded/*",element:i.jsx(Fe,{referrerType:a})})]})}export{mt as default};
1
+ import{j as i}from"./liveblocks-CGYIz1sf.js";import{j as q,u as w,h as U,l as Q,g as L,N as B,k as H,n as Ae,o as v}from"./core--8kDo-LJ.js";import{eM as R,iL as T,NM as W,Gn as ue,bp as ie,NN as he,jm as Z,JQ as K,NO as se,NP as Se,bB as x,Gk as me,NQ as ke,NR as re,NS as Ie,NT as pe,NU as be,NV as ve,NW as de,HA as Ye,bm as xe}from"./zeni-epic-state-Cb3mJiT_.js";import{D as X,d as C,c2 as ee,r as _,q as te,i as fe,s as J,N as Pe,z as Ee}from"./index-h4jm-UQJ.js";import"./mui-COKu087d.js";import{a as A}from"./sentry-ClGNqxTu.js";import{w as ae}from"./withTransactionSidePanel-DT5dIUC2.js";import{p as ne,b as ce}from"./routePaths-NcYvgIlg.js";import{u as Le}from"./utils-C9gYeSwW.js";import{d as E}from"./decodeURIComponentSafe-C7w4UFFF.js";import{Z as je}from"./ZeniAccountStatementScreen-B1G-7Ulg.js";import"./recharts-jENt1xXk.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./useAskAiCfoHostNavButtonProps-BBHohiIK.js";import"./useFetchSuggestedQuestionsWhenReady-m6vzz_hW.js";import"./TransactionDetailScreen-BWX6dDBh.js";(function(){try{var a=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},e=new a.Error().stack;e&&(a._sentryDebugIds=a._sentryDebugIds||{},a._sentryDebugIds[e]="6e73cff1-c71c-43c7-a79e-342c6f878fac",a._sentryDebugIdIdentifier="sentry-dbid-6e73cff1-c71c-43c7-a79e-342c6f878fac")}catch{}})();const G=a=>Le(a),Me=H(function(a,e){const t=he(a.transactionState,a.transactionListState,e.selectedAccount.period,e.selectedAccount.timeframe,G(e.selectedAccount.tranListType));return{title:e.selectedAccount.title,subTitle:e.selectedAccount.subTitle,timeframe:e.selectedAccount.timeframe,timePeriod:K(e.selectedAccount.period),dataAvailableForPeriod:e.dataAvailableForPeriod,report:t,currentScrollYOffset:t.uiState?.scrollYOffset??0,isAccountingClassesEnabled:Z(a)}},function(a,e){return{onBackClick:()=>{const t=te(e.location.state?.pathnameStackToGoBack),n=t.poppedPathname??"../../";e.navigate(n,{state:{pathnameStackToGoBack:t.newStack}})},onTimePeriodChange:(t,n,c)=>{e.closeSidePanel?.();const o=X.getLocalizedStrings(),r=G(e.selectedAccount.tranListType),s=Ce(t,n,c,r,e.bookCloseDate);C.trackTransactionList(void 0,void 0,void 0,e.selectedAccount.title,void 0,!0),a(se({uiState:{dateRange:s},type:G(e.selectedAccount.tranListType)})),a(ue(r,T(s),!1,r==="missingReceipts"?o.uncategorizedTransactionList.missingReceipt.missingReceiptMinAmount:void 0)),e.onSelectedTimePeriodChange(T(s))},onTransactionItemClick:t=>{if(e.openTransactionPanel)return void e.openTransactionPanel(t.id,t.type);const n=ce(t,e.tenantEmailDomain),c=_(e.location.state?.pathnameStackToGoBack,e.location.pathname);e.navigate(n,{state:{pathnameStackToGoBack:c}})},onTransactionListScroll:t=>{a(se({uiState:{scrollYOffset:t},type:G(e.selectedAccount.tranListType)}))}}})(ee),F=ae(function({...a}){const e=q(),t=w(),n=U(),c=t.pathname.substring(t.pathname.lastIndexOf("/")+1),{tenantEmailDomain:o}=Q(),r=X.getLocalizedStrings(),{accountType:s,title:u,subTitle:h}=ze(c),D="month",g=L(p=>R(p)),Y=g.company?.companyInfo.firstMonthOfFY??1,{dataAvailable:y,initialTimeframeTick:S}=Be(c,Y,g.bookCloseDate),[k,j]=A.useState(!1),[M,P]=A.useState(void 0),m=A.useMemo(()=>{const p=T(S);return{tranListType:c,accountType:W(s),title:u,subTitle:h,timeframe:D,period:p}},[c,D,s,y]);A.useEffect(()=>{if(!k&&m!=null){j(!0),C.trackTransactionList(void 0,void 0,void 0,m.title);const p=G(m.tranListType);n(ue(p,m.period,!0,p==="missingReceipts"?r.uncategorizedTransactionList.missingReceipt.missingReceiptMinAmount:void 0))}},[k,m,n]);let I=m;return m!=null&&M!=null&&(I={...m,period:M}),I==null?i.jsx(B,{to:"../"}):i.jsx(Me,{firstMonthOfFY:Y,tenantEmailDomain:o,location:t,useFixedPeriod:{timeframe:"month",numberOfPeriods:12},dataAvailableForPeriod:y,navigate:e,selectedAccount:I,referrerType:c,bookCloseDate:g.bookCloseDate,onSelectedTimePeriodChange:p=>P(p),...a})}),ze=a=>{let e="",t="",n="";const c=X.getLocalizedStrings();switch(a){case"uncategorized-income":e="income",t=c.uncategorizedTransactionList.income.title,n=c.uncategorizedTransactionList.income.subTitle;break;case"uncategorized-expense":e="expenses",t=c.uncategorizedTransactionList.expense.title,n=c.uncategorizedTransactionList.expense.subTitle;break;case"miscategorized-expense":e="expenses",t=c.miscategorizedTransactionList.expense.title,n=c.miscategorizedTransactionList.expense.subTitle;break;case"miscategorized-income":e="income",t=c.miscategorizedTransactionList.income.title,n=c.miscategorizedTransactionList.income.subTitle;break;case"missing-receipts":t=c.uncategorizedTransactionList.missingReceipt.title,n=c.uncategorizedTransactionList.missingReceipt.subTitle}return{accountType:e,title:t,subTitle:n}},Be=(a,e,t)=>{const n=ie();let c=ie().startOf("month").subtract(11,"month");return t!=null&&a!=="missing-receipts"?t.add(1,"day").isBefore(c)?{dataAvailable:{startDate:t.add(1,"day"),endDate:n},initialTimeframeTick:{startDate:c,endDate:n}}:(c=t.add(1,"day"),{dataAvailable:{startDate:c,endDate:n},initialTimeframeTick:{startDate:c,endDate:n}}):{dataAvailable:ne(5,e),initialTimeframeTick:{startDate:c,endDate:n}}},Ce=(a,e,t,n,c)=>{let o=e;return n==="missingReceipts"||c==null?a.startDate.isBefore(e.startDate,t)?o={startDate:a.startDate,endDate:e.endDate}:a.startDate.isAfter(e.endDate,t)?o={startDate:e.startDate,endDate:a.endDate}:console.error(`Invalid addTimePeriod ${JSON.stringify(a)}`):o=a.startDate.isBefore(c,t)?{startDate:c.add(1,"day"),endDate:e.endDate}:{startDate:a.startDate,endDate:e.endDate},o},Oe=H(function(a,e){const t=ke(a.transactionState,a.transactionListState,e.selectedAccount.accountId,e.selectedAccount.accountType,e.selectedAccount.classId,e.selectedAccount.timeframe,e.selectedAccount.period);return{accountId:e.selectedAccount.accountId,accountType:e.selectedAccount.accountType,title:e.selectedAccount.title,timeframe:e.selectedAccount.timeframe,timePeriod:K(e.selectedAccount.period),dataAvailableForPeriod:ne(5,e.firstMonthOfFY),report:t,currentScrollYOffset:t.uiState?.scrollYOffset??0,isAccountingClassesEnabled:Z(a)}},function(a,e){return{onBackClick:()=>{const t=te(e.location.state?.pathnameStackToGoBack),n=t.poppedPathname??Te();e.navigate(n,{state:{pathnameStackToGoBack:t.newStack}})},onTimePeriodChange:(t,n,c)=>{e.closeSidePanel?.();let o=n;t.startDate.isBefore(n.startDate,c)?o={startDate:t.startDate,endDate:n.endDate}:t.startDate.isAfter(n.endDate,c)?o={startDate:n.startDate,endDate:t.endDate}:console.error(`Invalid addTimePeriod ${JSON.stringify(t)}`),C.trackTransactionList(e.selectedAccount.accountId,void 0,e.referrerType,e.selectedAccount.title,void 0,!0),a(re({accountId:e.selectedAccount.accountId,accountType:e.selectedAccount.accountType,classId:e.selectedAccount.classId,uiState:{dateRange:o}})),a(me(e.selectedAccount.accountId,e.selectedAccount.accountType,e.selectedAccount.classId,T(o))),e.onSelectedTimePeriodChange(T(o))},onTransactionItemClick:t=>{if(e.openTransactionPanel)return void e.openTransactionPanel(t.id,t.type);const n=ce(t,e.tenantEmailDomain),c=_(e.location.state?.pathnameStackToGoBack,e.location.pathname);e.navigate(n,{state:{pathnameStackToGoBack:c}})},onTransactionListScroll:t=>{a(re({accountId:e.selectedAccount.accountId,accountType:e.selectedAccount.accountType,classId:e.selectedAccount.classId,uiState:{scrollYOffset:t}}))}}})(ee),Fe=ae(function({referrerType:a,...e}){const t=q(),n=w(),c=U(),{tenantEmailDomain:o,accountTypeEncoded:r,accountIdEncoded:s,classIdEncoded:u,timeframe:h,startDate:D,endDate:g,titleEncoded:Y}=Q(),y=E(r??""),S=E(s??""),k=E(u??""),j=E(Y??""),M=L(f=>Se(f.transactionListState,S,y,k)),[P,m]=A.useState(!1),[I,p]=A.useState(void 0),N=L(f=>R(f)),$=N.company?.companyInfo.firstMonthOfFY??1;let d;const l=Ge(y,S,k,h,D,g,j);if(l){const f={startDate:x(D,"YYYY-MM-DD"),endDate:x(g,"YYYY-MM-DD")},V=Ne(M?.dateRange,f);d={accountId:S,accountType:W(y),classId:k,title:j,timeframe:h,period:V}}A.useEffect(()=>{P||d==null||(m(!0),C.trackTransactionList(d.accountId,void 0,a,d.title),c(me(d.accountId,d.accountType,d.classId,d.period)))},[P,d,c]);let z=d;d!=null&&I!=null&&(z={...d,period:I});const O=[r,s,u,h,D,g,Y].filter(f=>f!=null);return l&&z!=null?i.jsx(Oe,{firstMonthOfFY:$,tenantEmailDomain:o,location:n,navigate:t,selectedAccount:z,referrerType:a,onSelectedTimePeriodChange:f=>p(f),...e}):i.jsx(B,{to:Te(O.length)})}),Te=(a=7)=>{let e="../";for(let t=0;t<a;t++)e=`${e}../`;return e},Ge=(a,e,t,n,c,o,r)=>a!=null&&e!=null&&t!=null&&n!=null&&c!=null&&o!=null&&(n==="month"||n==="quarter")&&x(c,"YYYY-MM-DD").isValid()&&x(o,"YYYY-MM-DD").isValid()&&r!=null,Ne=(a,e)=>a!=null&&a.endDate.isSame(e.endDate,"day")&&a.startDate.isBefore(e.startDate,"day")?T(a):T(e),_e=H(function(a,e){const t=be(a.transactionState,a.transactionListState,e.selectedAccount.accountId,e.selectedAccount.accountType,e.selectedAccount.timeframe,e.selectedAccount.period),n=t.account?.coaId,c=e.isConnectedAccountProviderUnit&&ve(n??"");return{accountId:e.selectedAccount.accountId,accountType:e.selectedAccount.accountType,title:e.selectedAccount.title,timeframe:e.selectedAccount.timeframe,timePeriod:K(e.selectedAccount.period),dataAvailableForPeriod:ne(5,e.firstMonthOfFY),report:t,currentScrollYOffset:t.uiState?.scrollYOffset??0,showStatementPageIcon:c,isAccountingClassesEnabled:Z(a)}},function(a,e){return{onBackClick:()=>{const t=te(e.location.state?.pathnameStackToGoBack),n=t.poppedPathname??De();e.navigate(n,{state:{pathnameStackToGoBack:t.newStack}})},onTimePeriodChange:(t,n,c)=>{e.closeSidePanel?.();let o=n;t.startDate.isBefore(n.startDate,c)?o={startDate:t.startDate,endDate:n.endDate}:t.startDate.isAfter(n.endDate,c)?o={startDate:n.startDate,endDate:t.endDate}:console.error(`Invalid addTimePeriod ${JSON.stringify(t)}`),C.trackTransactionList(e.selectedAccount.accountId,void 0,e.referrerType,e.selectedAccount.title,void 0,!0),a(de({accountId:e.selectedAccount.accountId,accountType:e.selectedAccount.accountType,uiState:{dateRange:o}})),a(pe(e.selectedAccount.accountId,e.selectedAccount.accountType,T(o))),e.onSelectedTimePeriodChange(T(o))},onTransactionItemClick:t=>{if(e.openTransactionPanel)return void e.openTransactionPanel(t.id,t.type);const n=ce(t,e.tenantEmailDomain),c=_(e.location.state?.pathnameStackToGoBack,e.location.pathname);e.navigate(n,{state:{pathnameStackToGoBack:c}})},onTransactionListScroll:t=>{a(de({accountId:e.selectedAccount.accountId,accountType:e.selectedAccount.accountType,uiState:{scrollYOffset:t}}))},onStatementPageIconClick:()=>{const t=$e(e.tenantEmailDomain),n=_(e.location.state?.pathnameStackToGoBack,e.location.pathname);e.navigate(t,{state:{pathnameStackToGoBack:n}})}}})(ee),le=ae(function({referrerType:a,...e}){const t=q(),n=w(),c=U(),{tenantEmailDomain:o,accountTypeEncoded:r,accountIdEncoded:s,timeframe:u,startDate:h,endDate:D,titleEncoded:g,excludeSubAccounts:Y}=Q(),y=E(r??""),S=E(s??""),k=E(g??""),j=!(Y!=null&&Y==="exclude_subaccounts"),M=L(b=>Ie(b.transactionListState,S,y)),[P,m]=A.useState(!1),[I,p]=A.useState(void 0),N=L(b=>R(b)),$=N.company?.featuresActivationInfo.connectedAccountProvider==="unit",d=N.company?.companyInfo.firstMonthOfFY??1;let l;const z=we(y,S,u,h,D,k);if(z){const b={startDate:x(h,"YYYY-MM-DD"),endDate:x(D,"YYYY-MM-DD")},ye=Re(M?.dateRange,b);l={accountId:S,accountType:W(y),title:k,timeframe:u,period:ye}}let O=l;l!=null&&I!=null&&(O={...l,period:I});const{useFeatureGate:f}=fe(),{isFeatureEnabled:V}=f(J.isTransactionCommentingEnabled),{areTenantIdsInSync:oe}=Pe();A.useEffect(()=>{!P&&l!=null&&oe&&(m(!0),C.trackTransactionList(l.accountId,void 0,a,l.title),c(pe(l.accountId,l.accountType,l.period,void 0,!1,j)))},[P,l,c,oe]);const ge=[r,s,u,h,D,g].filter(b=>b!=null);return z&&O!=null?i.jsx(_e,{firstMonthOfFY:d,tenantEmailDomain:o,location:n,navigate:t,isConnectedAccountProviderUnit:$,isTransactionCommentingEnabled:V,selectedAccount:O,referrerType:a,onSelectedTimePeriodChange:b=>p(b),...e}):i.jsx(B,{to:De(ge.length)})}),De=(a=7)=>{let e="../";for(let t=0;t<a;t++)e=`${e}../`;return e},we=(a,e,t,n,c,o)=>a!=null&&e!=null&&t!=null&&n!=null&&c!=null&&(t==="month"||t==="quarter")&&x(n,"YYYY-MM-DD").isValid()&&x(c,"YYYY-MM-DD").isValid()&&o!=null,Re=(a,e)=>a!=null&&a.endDate.isSame(e.endDate,"day")&&a.startDate.isBefore(e.startDate,"day")?T(a):T(e),$e=a=>`/${a}/transactions/${Ye}/statements`;function mt(){const a=w().state?.referrer,e=Ee.getSignedInUser(),t=xe(e),{useFeatureGate:n}=fe(),{isFeatureEnabled:c}=n(J.isExpenseAutomationEnabled),o=L(u=>u.expenseAutomationViewState.selectedPeriodByTenantId)[L(u=>R(u)).tenantId],{isFeatureEnabled:r}=n(J.isExpenseAutomationEnabledV2),s=r||c&&t;return i.jsxs(Ae,{children:[i.jsx(v,{path:"/:accountTypeEncoded/:accountIdEncoded/:timeframe/:startDate/:endDate/:titleEncoded/:excludeSubAccounts/*",element:i.jsx(le,{referrerType:a})}),i.jsx(v,{path:"/zeni-clearing-account/statements",element:i.jsx(je,{})}),i.jsx(v,{path:"/*",element:i.jsx(le,{referrerType:a})}),i.jsx(v,{path:"/uncategorized-income/*",element:i.jsx(F,{})}),i.jsx(v,{path:"/uncategorized-expense/*",element:s?i.jsx(B,{to:`../../month_end_close_checks/review/transaction_categorization/${o.month}-${o.year}`}):i.jsx(F,{})}),i.jsx(v,{path:"/miscategorized-income/*",element:i.jsx(F,{})}),i.jsx(v,{path:"/miscategorized-expense/*",element:s?i.jsx(B,{to:`../../month_end_close_checks/review/transaction_categorization/${o.month}-${o.year}`}):i.jsx(F,{})}),i.jsx(v,{path:"/missing-receipts/*",element:s?i.jsx(B,{to:`../../month_end_close_checks/review/missing_receipts/${o.month}-${o.year}`}):i.jsx(F,{})}),i.jsx(v,{path:"/by-class/:accountTypeEncoded/:accountIdEncoded/:classIdEncoded/:timeframe/:startDate/:endDate/:titleEncoded/*",element:i.jsx(Fe,{referrerType:a})})]})}export{mt as default};
@@ -1,4 +1,4 @@
1
- import{j as e}from"./liveblocks-CGYIz1sf.js";import{j as U,u as B,h as M,l as R,g as f,N as F,k as N,n as Ie,o as k}from"./core--8kDo-LJ.js";import{ci as V,eM as D,My as P,D3 as ae,fc as H,CN as ne,MA as we,D6 as Te,Mw as ke,Mx as se,MO as be,Bd as Ae,s2 as je,MC as Ee,Dh as ve,Mz as re,cL as J,w8 as oe,eR as De,eT as Le,NJ as Fe,NK as Ue,CO as Be,NL as Me,CP as Pe,CY as Oe,bu as Re,bC as Ne,ct as Ve,bD as _e,cN as ze,fb as $e,br as Ge,Ig as Ze,ch as He}from"./zeni-epic-state-Cb3mJiT_.js";import{S as _,al as Je,z as j,O as z,d as b,bX as We,bY as qe,bZ as Z,J as W,h as Ke,N as Ye,M as Qe,i as ie,s as v,A as Xe,v as et,b_ as tt,ao as q,r as at,b$ as nt,q as K,c0 as st,m as Q,c1 as rt,a4 as ot}from"./index-DO3Ev_EW.js";import{D as it,n as O,S as ct}from"./mui-COKu087d.js";import lt from"./NotFoundScreen-BOOShTFL.js";import{S as X}from"./SetupPagesScreen-BCxvmwj2.js";import{a as d}from"./sentry-ClGNqxTu.js";import{u as ut}from"./useAskAiCfoHostNavButtonProps-BECmuzX_.js";import{c as dt}from"./useFetchSuggestedQuestionsWhenReady-CapxOzLt.js";import{M as ce}from"./MobileAppDrawer-jslKljAh.js";import{F as pt}from"./FeaturePreviewScreen-DgltNyCi.js";import{a as ee}from"./analyticsHelper-BvhlneFh.js";import"./recharts-jENt1xXk.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./utils-C9gYeSwW.js";import"./routePaths-BOWJQWRe.js";import"./BusinessVerificationPageScreen-BCq9-s11.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]="e791011f-d7ba-4221-8ee2-d4082f0df72d",t._sentryDebugIdIdentifier="sentry-dbid-e791011f-d7ba-4221-8ee2-d4082f0df72d")}catch{}})();const mt=N(function(t,a){const{companyId:n}=a;return{treasurySetupView:P(t,n),analytics:b}},function(t,a){const{navigate:n,analytics:o,treasurySetupView:p}=a;return{onBackClick:()=>{n("../")},onNextClick:()=>{const r=p.fundAllocationLocalData;o.trackTreasuryPortfolioConfirm(r.riskScore,ee(r)),t(Te(!0))},onUpdateFundAllocation:r=>{o.trackTreasuryAllocationAction("update",ee(r)),t(we(r))}}})(We);function ft(){const t=U(),a=B(),n=M(),{tenantEmailDomain:o}=R(),p=_(),r=f(T=>T.treasurySetupViewState.portfolioAllocationUpdateStatus?.fetchState),m=Je(r),s=V(p?.loggedInUserRoleMap),[c,i]=d.useState(!1),[y,w]=d.useState(!1),[u,l]=d.useState(!1),g=f(T=>D(T)),h=j.getSignedInUserTenant(o)?.companyId??g.companyId,C=j.getSignedInUser(),S=f(T=>P(T,h)),I=f(T=>T.treasurySetupViewState.fetchState),x=f(T=>T.treasurySetupViewState.currentAllocation.fetchStatus?.fetchState),L=f(T=>T.treasurySetupViewState.treasuryFundsDetails?.fetchStatus?.fetchState);if(C==null)throw Error("Can't access treasury portfolio allocation page without signing in...");if(d.useEffect(()=>{c||I!=="Not-Started"||h==null||(i(!0),n(ae(h,!0,!1)))},[c,I,h,n]),d.useEffect(()=>{u||L!=="Not-Started"||h==null||(l(!0),n(H()))},[u,L,h,n]),d.useEffect(()=>{y||x!=="Not-Started"||h==null||(w(!0),n(ne()))},[y,x,h,n]),d.useEffect(()=>{m==="In-Progress"&&r==="Completed"&&t("../")},[m,r,t]),g.companyTreasuryInfo?.info?.isTreasuryTOSAccepted===!1)return e.jsx(F,{to:"../promo"});const E=g.companyTreasuryInfo?.info?.isTreasuryTOSAccepted!==!0||I!=="Completed";return e.jsxs(e.Fragment,{children:[!E&&e.jsx(z,{analytics:b,onLoad:()=>{}}),e.jsx(mt,{navigate:t,location:a,companyId:h,isEditMode:!0,isLoading:E,isReadOnly:!s,treasurySetupView:S,analytics:b})]})}const yt=N(function(t,a){const n=a.currentTenant?.companyId;return{plaidConnectionDetails:be(t,n,"zeni_treasury","treasury_setup").plaidConnectionDetails,treasurySetupView:P(t,n)}},function(t,a){const{navigate:n,transferDetails:o,treasurySetupView:p}=a,r=o.treasuryTransferMoneyLocalData,m=p.fundAllocationLocalData;return{onCancelClick:()=>{Z(a.analytics,"cancel",r,m,"Transfer"),t(se()),n("../")},onTransferClick:()=>{Z(a.analytics,"confirm",r,m,"Transfer"),t(ve())},onSaveChangesToLocalStore:s=>{t(Ee(s))},onFetchLinkTokenClick:s=>{t(je("treasury_setup",s))},onEstablishConnectionClick:s=>{t(Ae(s,a.currentTenant?.companyId,"treasury_setup","zeni_treasury"))}}})(qe),gt=({isFirstTransfer:t})=>{const a=U(),{tenantEmailDomain:n}=R(),o=M(),[p,r]=d.useState(!1),[m,s]=d.useState(!1),[c,i]=d.useState(!1),[y,w]=d.useState(!1),u=f(x=>x.treasurySetupViewState.fetchState),l=f(x=>x.treasurySetupViewState.treasuryFundsDetails?.fetchStatus?.fetchState),g=f(x=>x.treasurySetupViewState.currentAllocation.fetchStatus?.fetchState),h=f(x=>D(x)),C=j.getSignedInUserTenant(n)?.companyId??h.companyId,S=f(x=>ke(x)),I=f(x=>P(x,C));if(j.getSignedInUser()==null)throw Error("Can't access treasury transfer page without signing in...");return d.useEffect(()=>{m||u!=="Not-Started"||C==null||(s(!0),o(ae(C,!0,!1)))},[m,u,C,o]),d.useEffect(()=>{c||l!=="Not-Started"||C==null||(i(!0),o(H()))},[c,l,C,o]),d.useEffect(()=>{y||g!=="Not-Started"||C==null||(w(!0),o(ne()))},[y,g,C,o]),e.jsxs(e.Fragment,{children:[e.jsx(z,{analytics:b,onLoad:()=>{}}),e.jsx(yt,{analytics:b,navigate:a,transferDetails:S,onAnotherTransferClick:()=>{r(!1),o(se())},currentTenant:h,treasurySetupView:I,showReviewContent:p,maxInsuredAmount:5e5,onReviewClick:()=>{Z(b,"review",S.treasuryTransferMoneyLocalData,I.fundAllocationLocalData,"Transfer"),r(!0)},isFirstTransfer:t,setShowReviewContent:r,onBackClick:()=>{}})]})},ht=O.div`
1
+ import{j as e}from"./liveblocks-CGYIz1sf.js";import{j as U,u as B,h as M,l as R,g as f,N as F,k as N,n as Ie,o as k}from"./core--8kDo-LJ.js";import{ci as V,eM as D,My as P,D3 as ae,fc as H,CN as ne,MA as we,D6 as Te,Mw as ke,Mx as se,MO as be,Bd as Ae,s2 as je,MC as Ee,Dh as ve,Mz as re,cL as J,w8 as oe,eR as De,eT as Le,NJ as Fe,NK as Ue,CO as Be,NL as Me,CP as Pe,CY as Oe,bu as Re,bC as Ne,ct as Ve,bD as _e,cN as ze,fb as $e,br as Ge,Ig as Ze,ch as He}from"./zeni-epic-state-Cb3mJiT_.js";import{S as _,al as Je,z as j,O as z,d as b,bX as We,bY as qe,bZ as Z,J as W,h as Ke,N as Ye,M as Qe,i as ie,s as v,A as Xe,v as et,b_ as tt,ao as q,r as at,b$ as nt,q as K,c0 as st,m as Q,c1 as rt,a4 as ot}from"./index-h4jm-UQJ.js";import{D as it,n as O,S as ct}from"./mui-COKu087d.js";import lt from"./NotFoundScreen-0YxizmXw.js";import{S as X}from"./SetupPagesScreen-C-SdBEE6.js";import{a as d}from"./sentry-ClGNqxTu.js";import{u as ut}from"./useAskAiCfoHostNavButtonProps-BBHohiIK.js";import{c as dt}from"./useFetchSuggestedQuestionsWhenReady-m6vzz_hW.js";import{M as ce}from"./MobileAppDrawer-CimbS3hY.js";import{F as pt}from"./FeaturePreviewScreen-Csy8zadv.js";import{a as ee}from"./analyticsHelper-DMYHMyd-.js";import"./recharts-jENt1xXk.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./utils-C9gYeSwW.js";import"./routePaths-NcYvgIlg.js";import"./BusinessVerificationPageScreen-CbiCbjAZ.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]="e791011f-d7ba-4221-8ee2-d4082f0df72d",t._sentryDebugIdIdentifier="sentry-dbid-e791011f-d7ba-4221-8ee2-d4082f0df72d")}catch{}})();const mt=N(function(t,a){const{companyId:n}=a;return{treasurySetupView:P(t,n),analytics:b}},function(t,a){const{navigate:n,analytics:o,treasurySetupView:p}=a;return{onBackClick:()=>{n("../")},onNextClick:()=>{const r=p.fundAllocationLocalData;o.trackTreasuryPortfolioConfirm(r.riskScore,ee(r)),t(Te(!0))},onUpdateFundAllocation:r=>{o.trackTreasuryAllocationAction("update",ee(r)),t(we(r))}}})(We);function ft(){const t=U(),a=B(),n=M(),{tenantEmailDomain:o}=R(),p=_(),r=f(T=>T.treasurySetupViewState.portfolioAllocationUpdateStatus?.fetchState),m=Je(r),s=V(p?.loggedInUserRoleMap),[c,i]=d.useState(!1),[y,w]=d.useState(!1),[u,l]=d.useState(!1),g=f(T=>D(T)),h=j.getSignedInUserTenant(o)?.companyId??g.companyId,C=j.getSignedInUser(),S=f(T=>P(T,h)),I=f(T=>T.treasurySetupViewState.fetchState),x=f(T=>T.treasurySetupViewState.currentAllocation.fetchStatus?.fetchState),L=f(T=>T.treasurySetupViewState.treasuryFundsDetails?.fetchStatus?.fetchState);if(C==null)throw Error("Can't access treasury portfolio allocation page without signing in...");if(d.useEffect(()=>{c||I!=="Not-Started"||h==null||(i(!0),n(ae(h,!0,!1)))},[c,I,h,n]),d.useEffect(()=>{u||L!=="Not-Started"||h==null||(l(!0),n(H()))},[u,L,h,n]),d.useEffect(()=>{y||x!=="Not-Started"||h==null||(w(!0),n(ne()))},[y,x,h,n]),d.useEffect(()=>{m==="In-Progress"&&r==="Completed"&&t("../")},[m,r,t]),g.companyTreasuryInfo?.info?.isTreasuryTOSAccepted===!1)return e.jsx(F,{to:"../promo"});const E=g.companyTreasuryInfo?.info?.isTreasuryTOSAccepted!==!0||I!=="Completed";return e.jsxs(e.Fragment,{children:[!E&&e.jsx(z,{analytics:b,onLoad:()=>{}}),e.jsx(mt,{navigate:t,location:a,companyId:h,isEditMode:!0,isLoading:E,isReadOnly:!s,treasurySetupView:S,analytics:b})]})}const yt=N(function(t,a){const n=a.currentTenant?.companyId;return{plaidConnectionDetails:be(t,n,"zeni_treasury","treasury_setup").plaidConnectionDetails,treasurySetupView:P(t,n)}},function(t,a){const{navigate:n,transferDetails:o,treasurySetupView:p}=a,r=o.treasuryTransferMoneyLocalData,m=p.fundAllocationLocalData;return{onCancelClick:()=>{Z(a.analytics,"cancel",r,m,"Transfer"),t(se()),n("../")},onTransferClick:()=>{Z(a.analytics,"confirm",r,m,"Transfer"),t(ve())},onSaveChangesToLocalStore:s=>{t(Ee(s))},onFetchLinkTokenClick:s=>{t(je("treasury_setup",s))},onEstablishConnectionClick:s=>{t(Ae(s,a.currentTenant?.companyId,"treasury_setup","zeni_treasury"))}}})(qe),gt=({isFirstTransfer:t})=>{const a=U(),{tenantEmailDomain:n}=R(),o=M(),[p,r]=d.useState(!1),[m,s]=d.useState(!1),[c,i]=d.useState(!1),[y,w]=d.useState(!1),u=f(x=>x.treasurySetupViewState.fetchState),l=f(x=>x.treasurySetupViewState.treasuryFundsDetails?.fetchStatus?.fetchState),g=f(x=>x.treasurySetupViewState.currentAllocation.fetchStatus?.fetchState),h=f(x=>D(x)),C=j.getSignedInUserTenant(n)?.companyId??h.companyId,S=f(x=>ke(x)),I=f(x=>P(x,C));if(j.getSignedInUser()==null)throw Error("Can't access treasury transfer page without signing in...");return d.useEffect(()=>{m||u!=="Not-Started"||C==null||(s(!0),o(ae(C,!0,!1)))},[m,u,C,o]),d.useEffect(()=>{c||l!=="Not-Started"||C==null||(i(!0),o(H()))},[c,l,C,o]),d.useEffect(()=>{y||g!=="Not-Started"||C==null||(w(!0),o(ne()))},[y,g,C,o]),e.jsxs(e.Fragment,{children:[e.jsx(z,{analytics:b,onLoad:()=>{}}),e.jsx(yt,{analytics:b,navigate:a,transferDetails:S,onAnotherTransferClick:()=>{r(!1),o(se())},currentTenant:h,treasurySetupView:I,showReviewContent:p,maxInsuredAmount:5e5,onReviewClick:()=>{Z(b,"review",S.treasuryTransferMoneyLocalData,I.fundAllocationLocalData,"Transfer"),r(!0)},isFirstTransfer:t,setShowReviewContent:r,onBackClick:()=>{}})]})},ht=O.div`
2
2
  display: flex;
3
3
  min-height: 100%;
4
4
  width: 100%;
@@ -1,4 +1,4 @@
1
- import{j as l}from"./liveblocks-CGYIz1sf.js";import{a as g}from"./sentry-ClGNqxTu.js";import{j as M,u as q,l as J,g as f,k as G,h as Y,n as nt,o as B,N as K}from"./core--8kDo-LJ.js";import{eM as O,Je as Ee,Jf as Ue,fK as ee,co as be,cp as ke,uJ as St,Jg as st,uN as Yt,Hr as te,jm as ae,uH as qt,uB as Ht,Jh as Ne,ut as Wt,us as Qt,um as Zt,uy as Xt,uO as ea,Ji as pe,Jj as Me,uu as ta,Jk as he,eY as gt,v1 as vt,uW as xt,Jl as Tt,nO as Ct,uR as yt,uP as Dt,Jm as It,v8 as Et,v5 as bt,uS as kt,v7 as Ge,FT as wt,Jn as aa,Jo as na,cr as sa,Jp as oa,Jq as la,Jr as me,Js as ce,Jt as we,Hs as $e,vn as ye,Hq as De,va as At,uK as Ke,Ju as ia,Ht as W,Jv as ze,uE as ca,Jw as da,Jx as ra,Jy as Ye,Jz as qe,JA as He,JB as We,vh as Ae,JC as jt,u_ as Ft,JD as ua,JE as pa,JF as ha,JG as ma,JH as fa,JI as Sa,JJ as ga,JK as va,se as xa,sf as Ta,Gx as Fe,JL as Ca,JM as ya,iL as Pe,bp as Da,JN as Ia,JO as Ea,kk as ba,kt as ka,Gw as _e,bB as ot,JP as Pt,Gc as _t,JQ as wa,JR as Aa,JS as ja,kv as Fa,JT as lt,JU as it,JV as ct,JW as dt,JX as Pa,kr as _a,JY as Va,ku as La,JZ as Oa,J_ as Vt,GT as Lt,jK as Ba,J$ as Ja,K0 as Ve,K1 as Ot,GR as Bt,xA as Ra,K2 as Ua,K3 as Na,k2 as Jt,K4 as Ma,K5 as Ga,H3 as $a,pW as Ka,K6 as Rt,K7 as rt,H0 as Le,K8 as ut,K9 as za,H5 as Ya,Ka as qa,Kb as Ha,Kc as Wa,Kd as Qa,Ke as Za,pZ as Xa,Kf as en,Hu as tn,Kg as an,GK as Oe,gt as nn,Kh as sn,Ki as on,gr as ln,Kj as cn,Kk as dn,xE as rn,Kl as un,Km as pn,Kn as hn,Ko as mn,jO as fn,bm as Sn,eT as gn,eR as vn}from"./zeni-epic-state-Cb3mJiT_.js";import{z as R,al as Be,v as Ut,O as Z,d as P,T as X,ar as xn,r as N,D as Ie,Z as de,as as Qe,at as Tn,au as Cn,q as Ze,av as yn,h as Dn,J as re,A as Xe,i as ne,s as z,aw as In,k as et,M as fe,ax as En,ay as Nt,N as bn,az as kn,S as wn,aA as An,ao as Mt,aB as jn,o as Q,w as Fn,G as Gt,I as Pn,aC as _n,aD as Vn,f as tt,aE as Ln,aF as On,H as Bn,aG as Jn,aH as Rn}from"./index-DO3Ev_EW.js";import{n as U,D as Un,S as $t}from"./mui-COKu087d.js";import{t as Nn,A as Mn}from"./AddressScreen-UQTTt07o.js";import ie from"./NotFoundScreen-BOOShTFL.js";import{F as Gn}from"./FeaturePreviewScreen-DgltNyCi.js";import{b as H,v as at,c as $n}from"./routePaths-BOWJQWRe.js";import{p as Kt}from"./pathToGoBack-BAEmu1ZG.js";import{u as Se}from"./useAskAiCfoHostNavButtonProps-BECmuzX_.js";import{c as ge}from"./useFetchSuggestedQuestionsWhenReady-CapxOzLt.js";import{M as ve}from"./MobileAppDrawer-jslKljAh.js";import{D as Kn}from"./DrawerScreen-DG33YoSv.js";import{g as zn,m as Yn}from"./accountMappingHelper-DC8hLo25.js";import"./recharts-jENt1xXk.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./utils-C9gYeSwW.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]="1f073956-2b98-440d-8f5b-8f1cfa0a8cac",e._sentryDebugIdIdentifier="sentry-dbid-1f073956-2b98-440d-8f5b-8f1cfa0a8cac")}catch{}})();const qn=Ie.getLocalizedStrings(),Hn=G(function(e,a){const s=Ue(e,a.scheduleTab),t=e.tenantState.currentTenantId;return{authParams:{userId:a.signedInUser.userId??"",sessionId:a.signedInUser.zeniSessionId??"",tenantId:t??""},linkBillExpenseView:s.linkBillExpenseView,transactions:s.linkBillExpenseView.transactions}},function(e,a){const{navigate:s,location:t}=a;return{onTransactionSelect(n){e(st({selectedTransaction:n}))},onBackClick:()=>{s("..",{relative:"path"})},onCancel(){e(st({selectedTransaction:void 0})),e(Yt()),s("..",{relative:"path"})},onTransactionClick:n=>{const o=`${H(n,a.tenantEmailDomain)}`,c=N(t.state?.pathnameStackToGoBack,t.pathname);s(o,{state:{pathnameStackToGoBack:c}})},onLinkSave(){a.setShouldNavigateBack(!1),e(St(a.scheduleTab,a.scheduleAccruedDetailsView.selectedJEAccruedSchedule?.jeScheduleId))}}})(xn),Wn=({setShouldNavigateBack:e})=>{const a=M(),s=q(),{scheduleDetailId:t,tenantEmailDomain:n}=J(),{scheduleType:o}=J();if(n==null)throw Error("Can't access Link Bill Expense page without tenant Email Domain");const c=f(S=>O(S)),d=Ee(o)??"accrued_expenses",u=R.getSignedInUser();if(u==null)throw Error("Can't access Link Bill Expensedetail page without signing in...");if(t==null)throw Error("Invalid Schedule Detail Id");const i=f(S=>Ue(S,d)),m=i.selectedJELinkRowIndex,r=f(S=>ee(S,c.companyId)),p=Be(i.updateStatus.fetchState);g.useEffect(()=>{p==="In-Progress"&&i.updateStatus.fetchState==="Completed"&&a("..",{relative:"path"})},[p,i.updateStatus.fetchState]),g.useEffect(()=>{i.fetchState==="Not-Started"&&a("..",{relative:"path"})},[]),g.useEffect(()=>{i.selectedJEAccruedSchedule!=null&&i.selectedJELinkRowIndex!=null||a("..",{relative:"path"})},[i.selectedJEAccruedSchedule,i.selectedJELinkRowIndex]);const h=i.linkBillExpenseView.fetchState==="Completed";return l.jsx(l.Fragment,{children:i.linkBillExpenseView.fetchState==="In-Progress"?l.jsx(Ut,{fetchState:i.linkBillExpenseView.fetchState}):i.selectedJEAccruedSchedule!=null&&m!=null?l.jsxs(l.Fragment,{children:[h===!0?l.jsx(Z,{analytics:P,onLoad:()=>{Qn(i,d,r)}}):null,l.jsx(Hn,{signedInUser:u,attachmentEndPoint:`${X}/vendor_attachments`,setShouldNavigateBack:e,scheduleVendorId:i.selectedJEAccruedSchedule.vendor.id??"",location:s,tenantEmailDomain:n,scheduleAccruedDetailsView:i,saveFetchState:i.updateStatus.fetchState,scheduleTab:d,navigate:a,analytics:P,controllerUserDetails:r,saveStatus:i.updateStatus.fetchState,jeAccruedSchedule:i.selectedJEAccruedSchedule,localData:i.scheduleAccruedDetailsLocalData.jeScheduleDetails[m]})]}):null})},zt=e=>{const a=qn.dateFormat.analytics.YYYYDashMMDashDDFormat;return{scheduleCreateDate:e.createTime.format(a)??null,scheduleMonthlyAmount:e.recurringAmount??null,startingBalance:e.otherAttributes.startingBalance??null,scheduleAccountCategory:e.jeCredit.account?.accountName??null,description:e.memo,runningBalance:e.balanceAsOfToday??null,currentBalance:e.balanceAsOfToday??null,currentStatus:e.status.label,period:e.period??null,startMonth:e.startDate?.format(a)??null,endMonth:e.endDate?.format(a)??null}},Qn=(e,a,s)=>{const t=e.selectedJEAccruedSchedule,n=e.selectedJELinkRowIndex;let o;n!=null&&t!=null&&(o=t.scheduledJournalEntry[n]);const{transactions:c}=e.linkBillExpenseView,d=c.some(m=>m.isRecommendedTransaction===!0),u=be(s.controllers),i=ke(s.controllerUserIds);t!=null&&P.trackScheduleAccruedDetailsJournalEntryLinkedLoaded({scheduleType:a,schedule:{...zt(t)},scheduleExpenseCategoryAndClass:{expenseCategory:t.jeDebit.account?.accountName??null,expenseClass:t.jeDebit.accountingClass?.className??null},journalEntryDetails:{wasRecommendationAvailable:d,journalEntryPostingStatus:o?.status.label??""},vendorName:t.vendor.name??null,controllerEmails:u,controllerUserIds:i})},Zn=U.div`
1
+ import{j as l}from"./liveblocks-CGYIz1sf.js";import{a as g}from"./sentry-ClGNqxTu.js";import{j as M,u as q,l as J,g as f,k as G,h as Y,n as nt,o as B,N as K}from"./core--8kDo-LJ.js";import{eM as O,Je as Ee,Jf as Ue,fK as ee,co as be,cp as ke,uJ as St,Jg as st,uN as Yt,Hr as te,jm as ae,uH as qt,uB as Ht,Jh as Ne,ut as Wt,us as Qt,um as Zt,uy as Xt,uO as ea,Ji as pe,Jj as Me,uu as ta,Jk as he,eY as gt,v1 as vt,uW as xt,Jl as Tt,nO as Ct,uR as yt,uP as Dt,Jm as It,v8 as Et,v5 as bt,uS as kt,v7 as Ge,FT as wt,Jn as aa,Jo as na,cr as sa,Jp as oa,Jq as la,Jr as me,Js as ce,Jt as we,Hs as $e,vn as ye,Hq as De,va as At,uK as Ke,Ju as ia,Ht as W,Jv as ze,uE as ca,Jw as da,Jx as ra,Jy as Ye,Jz as qe,JA as He,JB as We,vh as Ae,JC as jt,u_ as Ft,JD as ua,JE as pa,JF as ha,JG as ma,JH as fa,JI as Sa,JJ as ga,JK as va,se as xa,sf as Ta,Gx as Fe,JL as Ca,JM as ya,iL as Pe,bp as Da,JN as Ia,JO as Ea,kk as ba,kt as ka,Gw as _e,bB as ot,JP as Pt,Gc as _t,JQ as wa,JR as Aa,JS as ja,kv as Fa,JT as lt,JU as it,JV as ct,JW as dt,JX as Pa,kr as _a,JY as Va,ku as La,JZ as Oa,J_ as Vt,GT as Lt,jK as Ba,J$ as Ja,K0 as Ve,K1 as Ot,GR as Bt,xA as Ra,K2 as Ua,K3 as Na,k2 as Jt,K4 as Ma,K5 as Ga,H3 as $a,pW as Ka,K6 as Rt,K7 as rt,H0 as Le,K8 as ut,K9 as za,H5 as Ya,Ka as qa,Kb as Ha,Kc as Wa,Kd as Qa,Ke as Za,pZ as Xa,Kf as en,Hu as tn,Kg as an,GK as Oe,gt as nn,Kh as sn,Ki as on,gr as ln,Kj as cn,Kk as dn,xE as rn,Kl as un,Km as pn,Kn as hn,Ko as mn,jO as fn,bm as Sn,eT as gn,eR as vn}from"./zeni-epic-state-Cb3mJiT_.js";import{z as R,al as Be,v as Ut,O as Z,d as P,T as X,ar as xn,r as N,D as Ie,Z as de,as as Qe,at as Tn,au as Cn,q as Ze,av as yn,h as Dn,J as re,A as Xe,i as ne,s as z,aw as In,k as et,M as fe,ax as En,ay as Nt,N as bn,az as kn,S as wn,aA as An,ao as Mt,aB as jn,o as Q,w as Fn,G as Gt,I as Pn,aC as _n,aD as Vn,f as tt,aE as Ln,aF as On,H as Bn,aG as Jn,aH as Rn}from"./index-h4jm-UQJ.js";import{n as U,D as Un,S as $t}from"./mui-COKu087d.js";import{t as Nn,A as Mn}from"./AddressScreen-nigwI_KO.js";import ie from"./NotFoundScreen-0YxizmXw.js";import{F as Gn}from"./FeaturePreviewScreen-Csy8zadv.js";import{b as H,v as at,c as $n}from"./routePaths-NcYvgIlg.js";import{p as Kt}from"./pathToGoBack-BAEmu1ZG.js";import{u as Se}from"./useAskAiCfoHostNavButtonProps-BBHohiIK.js";import{c as ge}from"./useFetchSuggestedQuestionsWhenReady-m6vzz_hW.js";import{M as ve}from"./MobileAppDrawer-CimbS3hY.js";import{D as Kn}from"./DrawerScreen-DkRsu6_3.js";import{g as zn,m as Yn}from"./accountMappingHelper-DC8hLo25.js";import"./recharts-jENt1xXk.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./utils-C9gYeSwW.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]="1f073956-2b98-440d-8f5b-8f1cfa0a8cac",e._sentryDebugIdIdentifier="sentry-dbid-1f073956-2b98-440d-8f5b-8f1cfa0a8cac")}catch{}})();const qn=Ie.getLocalizedStrings(),Hn=G(function(e,a){const s=Ue(e,a.scheduleTab),t=e.tenantState.currentTenantId;return{authParams:{userId:a.signedInUser.userId??"",sessionId:a.signedInUser.zeniSessionId??"",tenantId:t??""},linkBillExpenseView:s.linkBillExpenseView,transactions:s.linkBillExpenseView.transactions}},function(e,a){const{navigate:s,location:t}=a;return{onTransactionSelect(n){e(st({selectedTransaction:n}))},onBackClick:()=>{s("..",{relative:"path"})},onCancel(){e(st({selectedTransaction:void 0})),e(Yt()),s("..",{relative:"path"})},onTransactionClick:n=>{const o=`${H(n,a.tenantEmailDomain)}`,c=N(t.state?.pathnameStackToGoBack,t.pathname);s(o,{state:{pathnameStackToGoBack:c}})},onLinkSave(){a.setShouldNavigateBack(!1),e(St(a.scheduleTab,a.scheduleAccruedDetailsView.selectedJEAccruedSchedule?.jeScheduleId))}}})(xn),Wn=({setShouldNavigateBack:e})=>{const a=M(),s=q(),{scheduleDetailId:t,tenantEmailDomain:n}=J(),{scheduleType:o}=J();if(n==null)throw Error("Can't access Link Bill Expense page without tenant Email Domain");const c=f(S=>O(S)),d=Ee(o)??"accrued_expenses",u=R.getSignedInUser();if(u==null)throw Error("Can't access Link Bill Expensedetail page without signing in...");if(t==null)throw Error("Invalid Schedule Detail Id");const i=f(S=>Ue(S,d)),m=i.selectedJELinkRowIndex,r=f(S=>ee(S,c.companyId)),p=Be(i.updateStatus.fetchState);g.useEffect(()=>{p==="In-Progress"&&i.updateStatus.fetchState==="Completed"&&a("..",{relative:"path"})},[p,i.updateStatus.fetchState]),g.useEffect(()=>{i.fetchState==="Not-Started"&&a("..",{relative:"path"})},[]),g.useEffect(()=>{i.selectedJEAccruedSchedule!=null&&i.selectedJELinkRowIndex!=null||a("..",{relative:"path"})},[i.selectedJEAccruedSchedule,i.selectedJELinkRowIndex]);const h=i.linkBillExpenseView.fetchState==="Completed";return l.jsx(l.Fragment,{children:i.linkBillExpenseView.fetchState==="In-Progress"?l.jsx(Ut,{fetchState:i.linkBillExpenseView.fetchState}):i.selectedJEAccruedSchedule!=null&&m!=null?l.jsxs(l.Fragment,{children:[h===!0?l.jsx(Z,{analytics:P,onLoad:()=>{Qn(i,d,r)}}):null,l.jsx(Hn,{signedInUser:u,attachmentEndPoint:`${X}/vendor_attachments`,setShouldNavigateBack:e,scheduleVendorId:i.selectedJEAccruedSchedule.vendor.id??"",location:s,tenantEmailDomain:n,scheduleAccruedDetailsView:i,saveFetchState:i.updateStatus.fetchState,scheduleTab:d,navigate:a,analytics:P,controllerUserDetails:r,saveStatus:i.updateStatus.fetchState,jeAccruedSchedule:i.selectedJEAccruedSchedule,localData:i.scheduleAccruedDetailsLocalData.jeScheduleDetails[m]})]}):null})},zt=e=>{const a=qn.dateFormat.analytics.YYYYDashMMDashDDFormat;return{scheduleCreateDate:e.createTime.format(a)??null,scheduleMonthlyAmount:e.recurringAmount??null,startingBalance:e.otherAttributes.startingBalance??null,scheduleAccountCategory:e.jeCredit.account?.accountName??null,description:e.memo,runningBalance:e.balanceAsOfToday??null,currentBalance:e.balanceAsOfToday??null,currentStatus:e.status.label,period:e.period??null,startMonth:e.startDate?.format(a)??null,endMonth:e.endDate?.format(a)??null}},Qn=(e,a,s)=>{const t=e.selectedJEAccruedSchedule,n=e.selectedJELinkRowIndex;let o;n!=null&&t!=null&&(o=t.scheduledJournalEntry[n]);const{transactions:c}=e.linkBillExpenseView,d=c.some(m=>m.isRecommendedTransaction===!0),u=be(s.controllers),i=ke(s.controllerUserIds);t!=null&&P.trackScheduleAccruedDetailsJournalEntryLinkedLoaded({scheduleType:a,schedule:{...zt(t)},scheduleExpenseCategoryAndClass:{expenseCategory:t.jeDebit.account?.accountName??null,expenseClass:t.jeDebit.accountingClass?.className??null},journalEntryDetails:{wasRecommendationAvailable:d,journalEntryPostingStatus:o?.status.label??""},vendorName:t.vendor.name??null,controllerEmails:u,controllerUserIds:i})},Zn=U.div`
2
2
  display: flex;
3
3
  min-height: 100%;
4
4
  width: 100%;
@@ -1,4 +1,4 @@
1
- import{j as o}from"./liveblocks-CGYIz1sf.js";import{a as f}from"./sentry-ClGNqxTu.js";import{q as u,h,g as y,N as I}from"./core--8kDo-LJ.js";import{IA as w,eN as b,yV as x}from"./zeni-epic-state-Cb3mJiT_.js";import{z as l,v as j,G as S,I as v}from"./index-DO3Ev_EW.js";import{n as g}from"./mui-COKu087d.js";import"./recharts-jENt1xXk.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./utils-C9gYeSwW.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]="820063d6-44d6-4ea9-9831-7183569568cf",e._sentryDebugIdIdentifier="sentry-dbid-820063d6-44d6-4ea9-9831-7183569568cf")}catch{}})();const W=()=>{const[e]=u(),t=e.get("code")??"",s=e.get("state")??"",p=e.get("profileId")??"",[n,c]=f.useState(!1),a=h(),i=y(m=>w(m)),r=l.getSignedInUser(),d=l.getSignedInUserTenantWithId(s);if(r==null||d==null)return o.jsx(I,{to:"/signin/auth",replace:!0});if(r==null)throw Error("Can't access this page without signing in...");return b(r.userId,r.zeniSessionId,d?.tenantId),f.useEffect(()=>{n||(c(!0),a(x(t,p,s)))},[n,a]),i.fetchState==="Error"?o.jsx(D,{children:o.jsx(E,{children:i.error?.message??""})}):(i.fetchState==="Completed"&&window.close(),o.jsx(j,{fetchState:"In-Progress"}))},D=g.div`
1
+ import{j as o}from"./liveblocks-CGYIz1sf.js";import{a as f}from"./sentry-ClGNqxTu.js";import{q as u,h,g as y,N as I}from"./core--8kDo-LJ.js";import{IA as w,eN as b,yV as x}from"./zeni-epic-state-Cb3mJiT_.js";import{z as l,v as j,G as S,I as v}from"./index-h4jm-UQJ.js";import{n as g}from"./mui-COKu087d.js";import"./recharts-jENt1xXk.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./utils-C9gYeSwW.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]="820063d6-44d6-4ea9-9831-7183569568cf",e._sentryDebugIdIdentifier="sentry-dbid-820063d6-44d6-4ea9-9831-7183569568cf")}catch{}})();const W=()=>{const[e]=u(),t=e.get("code")??"",s=e.get("state")??"",p=e.get("profileId")??"",[n,c]=f.useState(!1),a=h(),i=y(m=>w(m)),r=l.getSignedInUser(),d=l.getSignedInUserTenantWithId(s);if(r==null||d==null)return o.jsx(I,{to:"/signin/auth",replace:!0});if(r==null)throw Error("Can't access this page without signing in...");return b(r.userId,r.zeniSessionId,d?.tenantId),f.useEffect(()=>{n||(c(!0),a(x(t,p,s)))},[n,a]),i.fetchState==="Error"?o.jsx(D,{children:o.jsx(E,{children:i.error?.message??""})}):(i.fetchState==="Completed"&&window.close(),o.jsx(j,{fetchState:"In-Progress"}))},D=g.div`
2
2
  display: flex;
3
3
  width: 100%;
4
4
  height: 100vh;
@@ -1,4 +1,4 @@
1
- import{j as n}from"./liveblocks-CGYIz1sf.js";import{j as W,u as J,h as U,l as G,g as w,k as Y,N as te,n as _e,o as x}from"./core--8kDo-LJ.js";import{eM as M,No as Ve,Np as $e,cN as ae,ci as Ze,fb as Ge,w6 as He,Aj as We,w0 as Pn,Nq as Tn,Nr as On,w3 as Bn,wa as xe,vZ as Fn,vW as Rn,Mb as ue,Ns as Ln,DD as Un,Jh as Mn,DF as zn,k3 as Oe,Nt as Nn,pB as Je,pp as Ye,jW as qe,jZ as Be,Ji as Fe,Jj as _n,Nu as Vn,jY as $n,kj as Zn,jN as Gn,ij as Hn,ii as Wn,Nv as Jn,Nw as ke,Dk as Yn,Nx as qn,Ny as Kn,M4 as Ae,Nz as Re,NA as Qn,DQ as Xn,MO as et,Bd as Ke,s2 as Qe,NB as nt,DN as tt,NC as Xe,cJ as De,DU as en,fc as at,eR as nn,eT as Ie,DS as ot,B7 as st,DK as it,ND as tn,NE as an,Dm as on,Dw as Le,NF as rt,Dq as ct,NG as lt,MD as dt,DV as ut,bu as pt,bC as mt,ct as ht,bD as gt,br as ft,Ig as yt}from"./zeni-epic-state-Cb3mJiT_.js";import{S as oe,i as $,z as A,s as E,h as R,v as se,bL as Ct,T as Se,J as V,A as q,q as sn,al as xt,aa as Ue,d as F,bM as kt,ao as be,bN as wt,O as pe,bO as At,f as je,aI as H,bP as Dt,N as It,M as rn,a7 as St,bQ as Me,bR as bt,r as ne,bS as jt,bT as vt,bU as Et,bV as Pt,a4 as Tt,o as Ot}from"./index-DO3Ev_EW.js";import{n as L,D as K,S as Q}from"./mui-COKu087d.js";import de from"./NotFoundScreen-BOOShTFL.js";import{S as ze}from"./SetupPagesScreen-BCxvmwj2.js";import{F as cn}from"./FeaturePreviewScreen-DgltNyCi.js";import{a as p}from"./sentry-ClGNqxTu.js";import{M as me}from"./MobileAppDrawer-jslKljAh.js";import{A as Bt,D as Ft,V as Rt}from"./DomesticWireDetailScreen-DjDGDTBz.js";import{A as Lt}from"./AddressScreen-UQTTt07o.js";import{u as ln}from"./useAskAiCfoHostNavButtonProps-BECmuzX_.js";import{c as dn}from"./useFetchSuggestedQuestionsWhenReady-CapxOzLt.js";import{Z as Ut}from"./ZeniAccountStatementScreen--z-dKl5C.js";import"./recharts-jENt1xXk.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./utils-C9gYeSwW.js";import"./analyticsHelper-BvhlneFh.js";import"./routePaths-BOWJQWRe.js";import"./BusinessVerificationPageScreen-BCq9-s11.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]="de7352c2-c842-4f92-9b7c-2a71540ebc84",e._sentryDebugIdIdentifier="sentry-dbid-de7352c2-c842-4f92-9b7c-2a71540ebc84")}catch{}})();const Mt=L.div`
1
+ import{j as n}from"./liveblocks-CGYIz1sf.js";import{j as W,u as J,h as U,l as G,g as w,k as Y,N as te,n as _e,o as x}from"./core--8kDo-LJ.js";import{eM as M,No as Ve,Np as $e,cN as ae,ci as Ze,fb as Ge,w6 as He,Aj as We,w0 as Pn,Nq as Tn,Nr as On,w3 as Bn,wa as xe,vZ as Fn,vW as Rn,Mb as ue,Ns as Ln,DD as Un,Jh as Mn,DF as zn,k3 as Oe,Nt as Nn,pB as Je,pp as Ye,jW as qe,jZ as Be,Ji as Fe,Jj as _n,Nu as Vn,jY as $n,kj as Zn,jN as Gn,ij as Hn,ii as Wn,Nv as Jn,Nw as ke,Dk as Yn,Nx as qn,Ny as Kn,M4 as Ae,Nz as Re,NA as Qn,DQ as Xn,MO as et,Bd as Ke,s2 as Qe,NB as nt,DN as tt,NC as Xe,cJ as De,DU as en,fc as at,eR as nn,eT as Ie,DS as ot,B7 as st,DK as it,ND as tn,NE as an,Dm as on,Dw as Le,NF as rt,Dq as ct,NG as lt,MD as dt,DV as ut,bu as pt,bC as mt,ct as ht,bD as gt,br as ft,Ig as yt}from"./zeni-epic-state-Cb3mJiT_.js";import{S as oe,i as $,z as A,s as E,h as R,v as se,bL as Ct,T as Se,J as V,A as q,q as sn,al as xt,aa as Ue,d as F,bM as kt,ao as be,bN as wt,O as pe,bO as At,f as je,aI as H,bP as Dt,N as It,M as rn,a7 as St,bQ as Me,bR as bt,r as ne,bS as jt,bT as vt,bU as Et,bV as Pt,a4 as Tt,o as Ot}from"./index-h4jm-UQJ.js";import{n as L,D as K,S as Q}from"./mui-COKu087d.js";import de from"./NotFoundScreen-0YxizmXw.js";import{S as ze}from"./SetupPagesScreen-C-SdBEE6.js";import{F as cn}from"./FeaturePreviewScreen-Csy8zadv.js";import{a as p}from"./sentry-ClGNqxTu.js";import{M as me}from"./MobileAppDrawer-CimbS3hY.js";import{A as Bt,D as Ft,V as Rt}from"./DomesticWireDetailScreen-BYpZqZEo.js";import{A as Lt}from"./AddressScreen-nigwI_KO.js";import{u as ln}from"./useAskAiCfoHostNavButtonProps-BBHohiIK.js";import{c as dn}from"./useFetchSuggestedQuestionsWhenReady-m6vzz_hW.js";import{Z as Ut}from"./ZeniAccountStatementScreen-B1G-7Ulg.js";import"./recharts-jENt1xXk.js";import"./analytics-D76TbnBG.js";import"./plaid-DzMABTsR.js";import"./dnd-C7FILogn.js";import"./stripe-DMRn4zHo.js";import"./lottie-BwZdyUox.js";import"./lexical-roIufkFt.js";import"./pdf-CBQkrKS2.js";import"./utils-C9gYeSwW.js";import"./analyticsHelper-DMYHMyd-.js";import"./routePaths-NcYvgIlg.js";import"./BusinessVerificationPageScreen-CbiCbjAZ.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]="de7352c2-c842-4f92-9b7c-2a71540ebc84",e._sentryDebugIdIdentifier="sentry-dbid-de7352c2-c842-4f92-9b7c-2a71540ebc84")}catch{}})();const Mt=L.div`
2
2
  display: flex;
3
3
  min-height: 100%;
4
4
  width: 100%;
@@ -1,4 +1,4 @@
1
- import{j as i}from"./liveblocks-CGYIz1sf.js";import{a as u}from"./sentry-ClGNqxTu.js";import{j as x,h as v,u as $,l as j,g as p}from"./core--8kDo-LJ.js";import{HA as s,Hz as z,NH as B,eM as C,NI as N}from"./zeni-epic-state-Cb3mJiT_.js";import{J as D,ao as g,h as E,z as L,v as P,bW as T,q as H}from"./index-DO3Ev_EW.js";import{n as M}from"./mui-COKu087d.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]="a1ae41c3-90f5-4509-aa6e-efa2a5d33c96",e._sentryDebugIdIdentifier="sentry-dbid-a1ae41c3-90f5-4509-aa6e-efa2a5d33c96")}catch{}})();const _=M.div`
1
+ import{j as i}from"./liveblocks-CGYIz1sf.js";import{a as u}from"./sentry-ClGNqxTu.js";import{j as x,h as v,u as $,l as j,g as p}from"./core--8kDo-LJ.js";import{HA as s,Hz as z,NH as B,eM as C,NI as N}from"./zeni-epic-state-Cb3mJiT_.js";import{J as D,ao as g,h as E,z as L,v as P,bW as T,q as H}from"./index-h4jm-UQJ.js";import{n as M}from"./mui-COKu087d.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]="a1ae41c3-90f5-4509-aa6e-efa2a5d33c96",e._sentryDebugIdIdentifier="sentry-dbid-a1ae41c3-90f5-4509-aa6e-efa2a5d33c96")}catch{}})();const _=M.div`
2
2
  display: flex;
3
3
  height: 100vh;
4
4
  width: 100%;
@@ -1 +1 @@
1
- import{cD as m,cE as l,Is as _,It as d}from"./zeni-epic-state-Cb3mJiT_.js";import{d as u}from"./index-DO3Ev_EW.js";import"./sentry-ClGNqxTu.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]="330a078e-50a5-4bcb-ac87-b2635492c771",e._sentryDebugIdIdentifier="sentry-dbid-330a078e-50a5-4bcb-ac87-b2635492c771")}catch{}})();const f=e=>{switch(e){case"this_month_to_date":case"this_week_to_date":case"this_year_to_date":case"last_year":case"last_week":case"last_month":case"last_6_months":case"last_3_months":case"last_12_months":case"free_range":return e;case"month":default:return"months";case"quarter":return"quarters";case"year":return"years"}},h=(e,a,o,i,s)=>{const r=[],c=[];let t=[];s?.forEach(n=>{r.push(n.companyId),c.push(n.companyName),t=t.concat(n.userRole)}),u.identify(e.userId,{tenant_id:a.tenantId,tenant_email_domain:a.tenantEmailDomain,company_id:a.companyId,company_name:a.companyName,user_role:a.userRole,chargebee_customer_id:i,$email:e.userEmail,user_email_domain:e.userEmailDomain,$first_name:e.firstName,$last_name:e.lastName,company_ids:s!=null?r:void 0,company_names:s!=null?c:void 0,user_roles:s!=null?t:void 0,app_type:"web",appearance:o})},g=(e,a)=>m(e,a)?"bill_pay":l(e,a)?"reimbursement":_(e,a)?"zeni_accounts":d(e,a)?"charge_cards":"bill_pay",I=e=>Object.values(e.allocation).map(String).join("-");export{I as a,h as f,g,f as t};
1
+ import{cD as m,cE as l,Is as _,It as d}from"./zeni-epic-state-Cb3mJiT_.js";import{d as u}from"./index-h4jm-UQJ.js";import"./sentry-ClGNqxTu.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]="330a078e-50a5-4bcb-ac87-b2635492c771",e._sentryDebugIdIdentifier="sentry-dbid-330a078e-50a5-4bcb-ac87-b2635492c771")}catch{}})();const f=e=>{switch(e){case"this_month_to_date":case"this_week_to_date":case"this_year_to_date":case"last_year":case"last_week":case"last_month":case"last_6_months":case"last_3_months":case"last_12_months":case"free_range":return e;case"month":default:return"months";case"quarter":return"quarters";case"year":return"years"}},h=(e,a,o,i,s)=>{const r=[],c=[];let t=[];s?.forEach(n=>{r.push(n.companyId),c.push(n.companyName),t=t.concat(n.userRole)}),u.identify(e.userId,{tenant_id:a.tenantId,tenant_email_domain:a.tenantEmailDomain,company_id:a.companyId,company_name:a.companyName,user_role:a.userRole,chargebee_customer_id:i,$email:e.userEmail,user_email_domain:e.userEmailDomain,$first_name:e.firstName,$last_name:e.lastName,company_ids:s!=null?r:void 0,company_names:s!=null?c:void 0,user_roles:s!=null?t:void 0,app_type:"web",appearance:o})},g=(e,a)=>m(e,a)?"bill_pay":l(e,a)?"reimbursement":_(e,a)?"zeni_accounts":d(e,a)?"charge_cards":"bill_pay",I=e=>Object.values(e.allocation).map(String).join("-");export{I as a,h as f,g,f as t};
@@ -1 +1 @@
1
- import{n}from"./index-DO3Ev_EW.js";import"./mui-COKu087d.js";import"./sentry-ClGNqxTu.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]="8f615ada-cbf3-4f3b-9d44-87b6c97d7e87",e._sentryDebugIdIdentifier="sentry-dbid-8f615ada-cbf3-4f3b-9d44-87b6c97d7e87")}catch{}})();function f(e){if(e.companyLocaleInfo!=null&&e.companyLocaleInfo.languageCode.length>0&&e.companyLocaleInfo.companyIncCountryCode.length>0){const o=`${e.companyLocaleInfo.languageCode.toLowerCase()}-${e.companyLocaleInfo.companyIncCountryCode.toUpperCase()}`;return console.warn(`localeID ${o}`),n(o)??"en"}return"en"}export{f as t};
1
+ import{n}from"./index-h4jm-UQJ.js";import"./mui-COKu087d.js";import"./sentry-ClGNqxTu.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]="8f615ada-cbf3-4f3b-9d44-87b6c97d7e87",e._sentryDebugIdIdentifier="sentry-dbid-8f615ada-cbf3-4f3b-9d44-87b6c97d7e87")}catch{}})();function f(e){if(e.companyLocaleInfo!=null&&e.companyLocaleInfo.languageCode.length>0&&e.companyLocaleInfo.companyIncCountryCode.length>0){const o=`${e.companyLocaleInfo.languageCode.toLowerCase()}-${e.companyLocaleInfo.companyIncCountryCode.toUpperCase()}`;return console.warn(`localeID ${o}`),n(o)??"en"}return"en"}export{f as t};