@zeniai/web-cockpit-ui 2.0.70-qa → 2.0.71-next

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 (38) hide show
  1. package/dist/assets/{CreditAgentRoutes-CWKjlOLH.js → CreditAgentRoutes-Rfl_XZgN.js} +1 -1
  2. package/dist/assets/{Preview-BUkq80T4.js → Preview-BAEoVRmx.js} +1 -1
  3. package/dist/assets/{ScreenRoutes-BfI06UNG.js → ScreenRoutes-B_0RdvVB.js} +3 -3
  4. package/dist/assets/{SignInScreen-DSJHRjC6.js → SignInScreen-HnTASa66.js} +1 -1
  5. package/dist/assets/{analytics-l9sdkpP9.js → analytics-B-cuNK8P.js} +1 -1
  6. package/dist/assets/{analyticsHelper-D81pIoPK.js → analyticsHelper-BiwhWgyJ.js} +1 -1
  7. package/dist/assets/{core-CubrU-Ir.js → core-zJRmDR0C.js} +1 -1
  8. package/dist/assets/{dash.all.min-CV5Y4knI.js → dash.all.min-Blgbgh7R.js} +1 -1
  9. package/dist/assets/{empty-DQn3kXjD.js → empty-BNB1T8Bo.js} +1 -1
  10. package/dist/assets/{empty-DIigh3aD.js → empty-Dv1mKqcx.js} +1 -1
  11. package/dist/assets/{epic-DcgTOIEI.js → epic-DBb_W4QH.js} +1 -1
  12. package/dist/assets/{index-kGLKeDfe.js → index-BdcP7oxB.js} +1 -1
  13. package/dist/assets/{index-B6kwgn-g.js → index-BkuaEqDM.js} +7 -7
  14. package/dist/assets/{index-1lhQa0ev.js → index-CbweS8FJ.js} +1 -1
  15. package/dist/assets/{index-pfawYbFW.js → index-D3-0WPfY.js} +1 -1
  16. package/dist/assets/{index-Bg9JMAQG.js → index-D3NSk86o.js} +2 -2
  17. package/dist/assets/{index-DiJZgjgc.js → index-kT_U0Bw1.js} +1 -1
  18. package/dist/assets/{index-Dv6rxYo7.js → index-tSocjKC5.js} +1 -1
  19. package/dist/assets/{lexical-BUlYyLJO.js → lexical-DgFeVxHB.js} +1 -1
  20. package/dist/assets/{liveblocks-ahYf3CBU.js → liveblocks-C75FN-S8.js} +1 -1
  21. package/dist/assets/{lottie-Cqe0-Pdp.js → lottie-Bu1dVLzt.js} +1 -1
  22. package/dist/assets/{mui-Ck6E7dQO.js → mui-k1YoVrai.js} +1 -1
  23. package/dist/assets/{react-SN0uckiu.js → react--TVfczXx.js} +2 -2
  24. package/dist/assets/{react-pdxrHvdO.js → react-BCxzQcXl.js} +1 -1
  25. package/dist/assets/{react-DMA-zMKP.js → react-C9MvpDzT.js} +1 -1
  26. package/dist/assets/{react-19t5FERR.js → react-CilpLHu8.js} +1 -1
  27. package/dist/assets/{react-Ng2enpqN.js → react-Hz0d64Vl.js} +1 -1
  28. package/dist/assets/{react-BEupoJkg.js → react-KZ-WFVIt.js} +1 -1
  29. package/dist/assets/{react-wBgGmKTm.js → react-Kr6jjulm.js} +1 -1
  30. package/dist/assets/{react-D8sGumgu.js → react-rzqwMuO0.js} +1 -1
  31. package/dist/assets/{recharts-MWMfXqT7.js → recharts-BbCfzDSc.js} +1 -1
  32. package/dist/assets/{sentry-ClFkBudX.js → sentry-B3Shr2Jp.js} +1 -1
  33. package/dist/assets/{url-B-1mdnl6.js → url-B9hPj8mz.js} +1 -1
  34. package/dist/assets/{url-DR_0iTF4.js → url-DcAJmlTB.js} +1 -1
  35. package/dist/assets/{utils-Ca1dkZzF.js → utils-CBBpikVS.js} +1 -1
  36. package/dist/assets/{zeni-epic-state-ClxFvNCS.js → zeni-epic-state-DvZcg696.js} +3 -3
  37. package/dist/index.html +1 -1
  38. package/package.json +2 -2
@@ -1,4 +1,4 @@
1
- import{j as s}from"./liveblocks-ahYf3CBU.js";import{u as j,P as v}from"./ScreenRoutes-BfI06UNG.js";import{a as f}from"./sentry-ClFkBudX.js";import{i as P,n as R,g as m,h as U,k as A,l as C,N as k}from"./core-CubrU-Ir.js";import{Iw as T,Ix as N,jR as E,Iy as M,kA as L,kD as $,kp as _,Iz as F,IA as O,kx as B,kt as q}from"./zeni-epic-state-ClxFvNCS.js";import{z as Q,$ as V,D as J,o as Z,a0 as G,F as H,Q as K,b as W,g as X,h as Y}from"./index-B6kwgn-g.js";import{n as ee}from"./mui-Ck6E7dQO.js";import"./recharts-MWMfXqT7.js";import"./analyticsHelper-D81pIoPK.js";import"./utils-Ca1dkZzF.js";import"./empty-DIigh3aD.js";import"./index-1lhQa0ev.js";import"./url-DR_0iTF4.js";import"./index-pfawYbFW.js";import"./analytics-l9sdkpP9.js";import"./lottie-Cqe0-Pdp.js";import"./lexical-BUlYyLJO.js";(function(){try{var a=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new a.Error().stack;t&&(a._sentryDebugIds=a._sentryDebugIds||{},a._sentryDebugIds[t]="a4739f01-99b2-4ce2-9ce9-81be95c4d3c5",a._sentryDebugIdIdentifier="sentry-dbid-a4739f01-99b2-4ce2-9ce9-81be95c4d3c5")}catch{}})();function te(a,t){return{headerData:{allTabOptions:H,selectedTabOption:K("creditAgent")},creditAgentPageData:{macroData:{data:t.macroCombined.data,fetchState:t.macroCombined.fetchStatus.fetchState,updateState:t.macroCombined.updateStatus.fetchState},cardProfilesData:t.cardProfilesData}}}function ne(a,t){return{headerActions:{onTabChange:n=>{const g=Y(n),c=X(n);W.trackCockpitTabClicked(c),t.navigate(`../../${g}`,{replace:!0})}},creditAgentPageActions:{onFetchMacro:()=>{a(q())},onSaveMacro:n=>{a(B(n))},onResetSaveMacro:()=>{a(O())},onUIStateChange:n=>{a(F(n))},cardProfilesActions:t.cardProfilesActions}}}const ae=U(te,ne)(G),oe=ee.div`
1
+ import{j as s}from"./liveblocks-C75FN-S8.js";import{u as j,P as v}from"./ScreenRoutes-B_0RdvVB.js";import{a as f}from"./sentry-B3Shr2Jp.js";import{i as P,n as R,g as m,h as U,k as A,l as C,N as k}from"./core-zJRmDR0C.js";import{Iw as T,Ix as N,jR as E,Iy as M,kA as L,kD as $,kp as _,Iz as F,IA as O,kx as B,kt as q}from"./zeni-epic-state-DvZcg696.js";import{z as Q,$ as V,D as J,o as Z,a0 as G,F as H,Q as K,b as W,g as X,h as Y}from"./index-BkuaEqDM.js";import{n as ee}from"./mui-k1YoVrai.js";import"./recharts-BbCfzDSc.js";import"./analyticsHelper-BiwhWgyJ.js";import"./utils-CBBpikVS.js";import"./empty-Dv1mKqcx.js";import"./index-CbweS8FJ.js";import"./url-DcAJmlTB.js";import"./index-D3-0WPfY.js";import"./analytics-B-cuNK8P.js";import"./lottie-Bu1dVLzt.js";import"./lexical-DgFeVxHB.js";(function(){try{var a=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},t=new a.Error().stack;t&&(a._sentryDebugIds=a._sentryDebugIds||{},a._sentryDebugIds[t]="a4739f01-99b2-4ce2-9ce9-81be95c4d3c5",a._sentryDebugIdIdentifier="sentry-dbid-a4739f01-99b2-4ce2-9ce9-81be95c4d3c5")}catch{}})();function te(a,t){return{headerData:{allTabOptions:H,selectedTabOption:K("creditAgent")},creditAgentPageData:{macroData:{data:t.macroCombined.data,fetchState:t.macroCombined.fetchStatus.fetchState,updateState:t.macroCombined.updateStatus.fetchState},cardProfilesData:t.cardProfilesData}}}function ne(a,t){return{headerActions:{onTabChange:n=>{const g=Y(n),c=X(n);W.trackCockpitTabClicked(c),t.navigate(`../../${g}`,{replace:!0})}},creditAgentPageActions:{onFetchMacro:()=>{a(q())},onSaveMacro:n=>{a(B(n))},onResetSaveMacro:()=>{a(O())},onUIStateChange:n=>{a(F(n))},cardProfilesActions:t.cardProfilesActions}}}const ae=U(te,ne)(G),oe=ee.div`
2
2
  padding: ${Z.sp5};
3
3
  text-align: center;
4
4
  `;function re(){const a=P(),t=R(),n=m(T),g=m(N),[c,h]=f.useState(new Set),p=f.useRef(new Set),b=m(e=>e.tenantState.currentTenantId),y=m(e=>e.companyViewState.zeniUsers.fetchState);f.useEffect(()=>{y==="Not-Started"&&t(E())},[t,y]);const d=Q.getSignedInUser(),I=d!=null&&[d.firstName,d.lastName].filter(Boolean).join(" ")||void 0,w=f.useMemo(()=>({onFetch:()=>{t(_())},onUpdateProfile:(e,o,r)=>{const i=r.updatedByName??I;t($({tenantId:o,tenantEmailDomain:e,update:{...r,updatedByName:i}}))},onAnalyse:e=>{h(o=>new Set(o).add(e)),t(L(e))},onDownloadReport:()=>{const e=M(n.rows),o=d?.userId??"",r=d?.zeniSessionId??"",i=b??"";if(!o||!r||!i)return;const z=encodeURIComponent(JSON.stringify(e)),D=`${V}/tableDownload?query=${z}`;fetch(D,{headers:{"zeni-user-id":o,"zeni-session-id":r,"zeni-tenant-id":i}}).then(async l=>{if(!l.ok){const u=await l.text();throw new Error(`Download failed: ${l.status} ${u}`)}return l.blob()}).then(l=>{const u=URL.createObjectURL(l),S=document.createElement("a");S.href=u,S.download=`${e.file_name}.xlsx`,S.click(),URL.revokeObjectURL(u)}).catch(()=>{})}}),[t,I,d,b,n.rows]);f.useEffect(()=>{if(c.size===0)return;const e=new Set;for(const o of c){const r=n.rows.find(i=>i.tenantId===o);r!=null&&r.isAnalyzing?p.current.add(o):r!=null&&!r.isAnalyzing&&p.current.has(o)&&(e.add(o),p.current.delete(o))}e.size>0&&h(o=>{const r=new Set(o);for(const i of e)r.delete(i);return r})},[n.rows,c]);const x=f.useMemo(()=>({fetchState:n.fetchStatus.fetchState,rows:n.rows.map(e=>e.isAnalyzing||e.tenantId!=null&&c.has(e.tenantId)?{...e,isAnalyzing:!0}:e),uiState:n.uiState}),[n,c]);return d==null?s.jsx(oe,{children:J.getLocalizedStrings().cockpit.creditAgent.notSignedIn}):s.jsx(ae,{macroCombined:g,navigate:a,cardProfilesActions:w,cardProfilesData:x})}function we(){const{isAllowed:a,isLoading:t}=j();return t?null:a?s.jsx(A,{children:s.jsx(C,{path:"/*",element:s.jsx(v,{element:s.jsx(re,{})})})}):s.jsx(A,{children:s.jsx(C,{path:"/*",element:s.jsx(k,{to:"/management",replace:!0})})})}export{we as default};
@@ -1 +1 @@
1
- import{a as h,b as a}from"./sentry-ClFkBudX.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},n=new t.Error().stack;n&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[n]="6d600b3f-6c40-4b9e-8892-371ff81f1c30",t._sentryDebugIdIdentifier="sentry-dbid-6d600b3f-6c40-4b9e-8892-371ff81f1c30")}catch{}})();const c="64px",f={},k=({src:t,light:n,oEmbedUrl:r,onClickPreview:s,playIcon:m,previewTabIndex:I,previewAriaLabel:u})=>{const[p,o]=h.useState(null);h.useEffect(()=>{!t||!n||!r||_({src:t,light:n,oEmbedUrl:r})},[t,n,r]);const _=async({src:e,light:i,oEmbedUrl:E})=>{if(a.isValidElement(i))return;if(typeof i=="string"){o(i);return}if(f[e]){o(f[e]);return}o(null);const b=await(await fetch(E.replace("{url}",e))).json();if(b.thumbnail_url){const g=b.thumbnail_url.replace("height=100","height=480").replace("-d_295x166","-d_640");o(g),f[e]=g}},w=e=>{(e.key==="Enter"||e.key===" ")&&s?.(e)},v=e=>{s?.(e)},l=a.isValidElement(n),y={display:"flex",alignItems:"center",justifyContent:"center"},d={preview:{width:"100%",height:"100%",backgroundImage:p&&!l?`url(${p})`:void 0,backgroundSize:"cover",backgroundPosition:"center",cursor:"pointer",...y},shadow:{background:"radial-gradient(rgb(0, 0, 0, 0.3), rgba(0, 0, 0, 0) 60%)",borderRadius:c,width:c,height:c,position:l?"absolute":void 0,...y},playIcon:{borderStyle:"solid",borderWidth:"16px 0 16px 26px",borderColor:"transparent transparent transparent white",marginLeft:"7px"}},x=a.createElement("div",{style:d.shadow,className:"react-player__shadow"},a.createElement("div",{style:d.playIcon,className:"react-player__play-icon"}));return a.createElement("div",{style:d.preview,className:"react-player__preview",tabIndex:I,onClick:v,onKeyDown:w,...u?{"aria-label":u}:{}},l?n:null,m||x)};var S=k;export{S as default};
1
+ import{a as h,b as a}from"./sentry-B3Shr2Jp.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},n=new t.Error().stack;n&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[n]="6d600b3f-6c40-4b9e-8892-371ff81f1c30",t._sentryDebugIdIdentifier="sentry-dbid-6d600b3f-6c40-4b9e-8892-371ff81f1c30")}catch{}})();const c="64px",f={},k=({src:t,light:n,oEmbedUrl:r,onClickPreview:s,playIcon:m,previewTabIndex:I,previewAriaLabel:u})=>{const[p,o]=h.useState(null);h.useEffect(()=>{!t||!n||!r||_({src:t,light:n,oEmbedUrl:r})},[t,n,r]);const _=async({src:e,light:i,oEmbedUrl:E})=>{if(a.isValidElement(i))return;if(typeof i=="string"){o(i);return}if(f[e]){o(f[e]);return}o(null);const b=await(await fetch(E.replace("{url}",e))).json();if(b.thumbnail_url){const g=b.thumbnail_url.replace("height=100","height=480").replace("-d_295x166","-d_640");o(g),f[e]=g}},w=e=>{(e.key==="Enter"||e.key===" ")&&s?.(e)},v=e=>{s?.(e)},l=a.isValidElement(n),y={display:"flex",alignItems:"center",justifyContent:"center"},d={preview:{width:"100%",height:"100%",backgroundImage:p&&!l?`url(${p})`:void 0,backgroundSize:"cover",backgroundPosition:"center",cursor:"pointer",...y},shadow:{background:"radial-gradient(rgb(0, 0, 0, 0.3), rgba(0, 0, 0, 0) 60%)",borderRadius:c,width:c,height:c,position:l?"absolute":void 0,...y},playIcon:{borderStyle:"solid",borderWidth:"16px 0 16px 26px",borderColor:"transparent transparent transparent white",marginLeft:"7px"}},x=a.createElement("div",{style:d.shadow,className:"react-player__shadow"},a.createElement("div",{style:d.playIcon,className:"react-player__play-icon"}));return a.createElement("div",{style:d.preview,className:"react-player__preview",tabIndex:I,onClick:v,onKeyDown:w,...u?{"aria-label":u}:{}},l?n:null,m||x)};var S=k;export{S as default};
@@ -1,5 +1,5 @@
1
- const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/CreditAgentRoutes-CWKjlOLH.js","assets/liveblocks-ahYf3CBU.js","assets/sentry-ClFkBudX.js","assets/core-CubrU-Ir.js","assets/recharts-MWMfXqT7.js","assets/zeni-epic-state-ClxFvNCS.js","assets/index-B6kwgn-g.js","assets/mui-Ck6E7dQO.js","assets/analytics-l9sdkpP9.js","assets/lottie-Cqe0-Pdp.js","assets/lexical-BUlYyLJO.js","assets/utils-Ca1dkZzF.js","assets/index-xQ8260uf.css","assets/analyticsHelper-D81pIoPK.js","assets/empty-DIigh3aD.js","assets/index-1lhQa0ev.js","assets/url-DR_0iTF4.js","assets/index-pfawYbFW.js"])))=>i.map(i=>d[i]);
2
- import{HH as Lf,HI as qf,jP as At,ex as vs,HJ as Dt,eG as nn,ev as Df,HK as Jt,eC as on,HL as sd,HM as ud,HN as ur,HO as cd,il as Nf,jR as Ct,ii as ld,iq as Mf,HP as ys,is as fd,it as hd,HQ as wr,HR as cr,hP as dd,HS as hn,HT as Vo,d3 as pd,fP as $o,fM as sn,fU as Mt,fS as md,HU as Ff,HV as Bf,iH as gd,iE as vd,HW as yd,iS as _d,iN as _s,iK as bd,iz as wd,HX as Ed,ed as Sd,da as Rd,k1 as Uf,HY as Od,be as an,iw as bs,iB as Td,rv as Vf,jQ as dn,HZ as pt,j5 as Go,H_ as xd,k7 as Id,H as et,bk as zo,H$ as Ad,hM as Cd,I0 as Pd,I1 as $f,I2 as kd,q3 as ws,pA as jd,I3 as Ld,pG as xn,I4 as qd,pI as Dd,I5 as Tt,px as Nd,cT as Md,jU as Gf,jV as zf,jT as Ho,jS as Zo,jW as Fd,I6 as Bd,q6 as Ud,I7 as Vd,pP as $d,q0 as Gd,I8 as zd,pT as Hd,I9 as Zd,Ia as Kt,Ib as Yo,Ic as Yd,Id as Wd,oB as Jd,oH as Hf,Ie as Zf,hh as Kd,GJ as Yf,If as Xd,GD as Qd,Ig as ep,Ih as tp,oK as rp,Ii as np,GO as ip,GC as ap,te as Wf,Ij as In,Ik as Jf,Dx as Wo,Dj as op,DA as Kf,Dm as sp,Il as up,Dr as cp,Dd as lp,Dg as fp,Im as hp,DE as dp,Du as pp,bn as mp,bd as gp,In as vp,Io as Gt,Ip as yp,Iq as _p,Ir as bp,iW as Mo,j0 as wp,ba as Xf}from"./zeni-epic-state-ClxFvNCS.js";import{j as U}from"./liveblocks-ahYf3CBU.js";import{a as fe,p as ye,e as Qf,d as eh,g as Ep}from"./sentry-ClFkBudX.js";import{s as wt,f as xt,z as He,F as Sp,t as Rp,J as lr,m as Ft,X as Op,Q as Et,a as th,w as at,b as Ve,h as Pt,g as Bt,L as Tp,u as xp,N as Ip,H as Ap,c as pn,K as Cp,D as fr,P as mn,o as Nt,r as Pp,C as kp,U as gn,d as jp,e as Lp,i as An,j as qp,V as rh,E as Dp,k as nh,T as ih,l as Fo,n as Np,p as Mp,q as Fp,v as ah,x as Bp,y as Up,A as Vp,B as $p,G as Gp,I as zp,Z as Hp,R as Zp,_ as Yp,Y as Wp,M as Jp,O as Kp,S as oh}from"./index-B6kwgn-g.js";import{f as Xp}from"./analyticsHelper-D81pIoPK.js";import{i as Fe,n as Ye,g as Se,o as ot,N as ir,k as gt,l as Te,p as sh,h as Ge,u as Jo,j as Bo}from"./core-CubrU-Ir.js";import{D as hr,n as tt,S as Ht}from"./mui-Ck6E7dQO.js";import{a as Ze,b as Qp,c as em,d as tm,e as Ko,f as rm,g as nm,h as im,i as Zt,j as am,k as or,l as vn,m as om,n as dr,o as sm}from"./utils-Ca1dkZzF.js";import{r as Xo}from"./empty-DIigh3aD.js";import{r as pr,a as um}from"./index-1lhQa0ev.js";import{r as cm}from"./index-pfawYbFW.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]="0710ec83-6617-4170-a172-2b9acccabb24",e._sentryDebugIdIdentifier="sentry-dbid-0710ec83-6617-4170-a172-2b9acccabb24")}catch{}})();var Cn={},Es;function yn(){return Es||(Es=1,function(e){var n=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Int32Array<"u";function o(t,r){return Object.prototype.hasOwnProperty.call(t,r)}e.assign=function(t){for(var r=Array.prototype.slice.call(arguments,1);r.length;){var s=r.shift();if(s){if(typeof s!="object")throw new TypeError(s+"must be non-object");for(var h in s)o(s,h)&&(t[h]=s[h])}}return t},e.shrinkBuf=function(t,r){return t.length===r?t:t.subarray?t.subarray(0,r):(t.length=r,t)};var i={arraySet:function(t,r,s,h,f){if(r.subarray&&t.subarray){t.set(r.subarray(s,s+h),f);return}for(var l=0;l<h;l++)t[f+l]=r[s+l]},flattenChunks:function(t){var r,s,h,f,l,d;for(h=0,r=0,s=t.length;r<s;r++)h+=t[r].length;for(d=new Uint8Array(h),f=0,r=0,s=t.length;r<s;r++)l=t[r],d.set(l,f),f+=l.length;return d}},a={arraySet:function(t,r,s,h,f){for(var l=0;l<h;l++)t[f+l]=r[s+l]},flattenChunks:function(t){return[].concat.apply([],t)}};e.setTyped=function(t){t?(e.Buf8=Uint8Array,e.Buf16=Uint16Array,e.Buf32=Int32Array,e.assign(e,i)):(e.Buf8=Array,e.Buf16=Array,e.Buf32=Array,e.assign(e,a))},e.setTyped(n)}(Cn)),Cn}var ut={},kt={},Ss;function lm(){if(Ss)return kt;Ss=1;var e=yn(),n=4,o=0,i=1,a=2;function t(A){for(var ne=A.length;--ne>=0;)A[ne]=0}var r=0,s=1,h=2,f=3,l=258,d=29,c=256,b=c+1+d,m=30,y=19,g=2*b+1,u=15,_=16,E=7,v=256,w=16,x=17,O=18,C=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],N=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],W=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],M=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],S=512,R=new Array((b+2)*2);t(R);var L=new Array(m*2);t(L);var q=new Array(S);t(q);var G=new Array(l-f+1);t(G);var P=new Array(d);t(P);var j=new Array(m);t(j);function k(A,ne,se,le,Z){this.static_tree=A,this.extra_bits=ne,this.extra_base=se,this.elems=le,this.max_length=Z,this.has_stree=A&&A.length}var B,Y,H;function V(A,ne){this.dyn_tree=A,this.max_code=0,this.stat_desc=ne}function D(A){return A<256?q[A]:q[256+(A>>>7)]}function F(A,ne){A.pending_buf[A.pending++]=ne&255,A.pending_buf[A.pending++]=ne>>>8&255}function $(A,ne,se){A.bi_valid>_-se?(A.bi_buf|=ne<<A.bi_valid&65535,F(A,A.bi_buf),A.bi_buf=ne>>_-A.bi_valid,A.bi_valid+=se-_):(A.bi_buf|=ne<<A.bi_valid&65535,A.bi_valid+=se)}function X(A,ne,se){$(A,se[ne*2],se[ne*2+1])}function K(A,ne){var se=0;do se|=A&1,A>>>=1,se<<=1;while(--ne>0);return se>>>1}function ae(A){A.bi_valid===16?(F(A,A.bi_buf),A.bi_buf=0,A.bi_valid=0):A.bi_valid>=8&&(A.pending_buf[A.pending++]=A.bi_buf&255,A.bi_buf>>=8,A.bi_valid-=8)}function ue(A,ne){var se=ne.dyn_tree,le=ne.max_code,Z=ne.stat_desc.static_tree,ie=ne.stat_desc.has_stree,T=ne.stat_desc.extra_bits,oe=ne.stat_desc.extra_base,be=ne.stat_desc.max_length,p,te,re,I,z,ee,_e=0;for(I=0;I<=u;I++)A.bl_count[I]=0;for(se[A.heap[A.heap_max]*2+1]=0,p=A.heap_max+1;p<g;p++)te=A.heap[p],I=se[se[te*2+1]*2+1]+1,I>be&&(I=be,_e++),se[te*2+1]=I,!(te>le)&&(A.bl_count[I]++,z=0,te>=oe&&(z=T[te-oe]),ee=se[te*2],A.opt_len+=ee*(I+z),ie&&(A.static_len+=ee*(Z[te*2+1]+z)));if(_e!==0){do{for(I=be-1;A.bl_count[I]===0;)I--;A.bl_count[I]--,A.bl_count[I+1]+=2,A.bl_count[be]--,_e-=2}while(_e>0);for(I=be;I!==0;I--)for(te=A.bl_count[I];te!==0;)re=A.heap[--p],!(re>le)&&(se[re*2+1]!==I&&(A.opt_len+=(I-se[re*2+1])*se[re*2],se[re*2+1]=I),te--)}}function ve(A,ne,se){var le=new Array(u+1),Z=0,ie,T;for(ie=1;ie<=u;ie++)le[ie]=Z=Z+se[ie-1]<<1;for(T=0;T<=ne;T++){var oe=A[T*2+1];oe!==0&&(A[T*2]=K(le[oe]++,oe))}}function me(){var A,ne,se,le,Z,ie=new Array(u+1);for(se=0,le=0;le<d-1;le++)for(P[le]=se,A=0;A<1<<C[le];A++)G[se++]=le;for(G[se-1]=le,Z=0,le=0;le<16;le++)for(j[le]=Z,A=0;A<1<<N[le];A++)q[Z++]=le;for(Z>>=7;le<m;le++)for(j[le]=Z<<7,A=0;A<1<<N[le]-7;A++)q[256+Z++]=le;for(ne=0;ne<=u;ne++)ie[ne]=0;for(A=0;A<=143;)R[A*2+1]=8,A++,ie[8]++;for(;A<=255;)R[A*2+1]=9,A++,ie[9]++;for(;A<=279;)R[A*2+1]=7,A++,ie[7]++;for(;A<=287;)R[A*2+1]=8,A++,ie[8]++;for(ve(R,b+1,ie),A=0;A<m;A++)L[A*2+1]=5,L[A*2]=K(A,5);B=new k(R,C,c+1,b,u),Y=new k(L,N,0,m,u),H=new k(new Array(0),W,0,y,E)}function we(A){var ne;for(ne=0;ne<b;ne++)A.dyn_ltree[ne*2]=0;for(ne=0;ne<m;ne++)A.dyn_dtree[ne*2]=0;for(ne=0;ne<y;ne++)A.bl_tree[ne*2]=0;A.dyn_ltree[v*2]=1,A.opt_len=A.static_len=0,A.last_lit=A.matches=0}function Ce(A){A.bi_valid>8?F(A,A.bi_buf):A.bi_valid>0&&(A.pending_buf[A.pending++]=A.bi_buf),A.bi_buf=0,A.bi_valid=0}function ke(A,ne,se,le){Ce(A),F(A,se),F(A,~se),e.arraySet(A.pending_buf,A.window,ne,se,A.pending),A.pending+=se}function je(A,ne,se,le){var Z=ne*2,ie=se*2;return A[Z]<A[ie]||A[Z]===A[ie]&&le[ne]<=le[se]}function Ie(A,ne,se){for(var le=A.heap[se],Z=se<<1;Z<=A.heap_len&&(Z<A.heap_len&&je(ne,A.heap[Z+1],A.heap[Z],A.depth)&&Z++,!je(ne,le,A.heap[Z],A.depth));)A.heap[se]=A.heap[Z],se=Z,Z<<=1;A.heap[se]=le}function Ee(A,ne,se){var le,Z,ie=0,T,oe;if(A.last_lit!==0)do le=A.pending_buf[A.d_buf+ie*2]<<8|A.pending_buf[A.d_buf+ie*2+1],Z=A.pending_buf[A.l_buf+ie],ie++,le===0?X(A,Z,ne):(T=G[Z],X(A,T+c+1,ne),oe=C[T],oe!==0&&(Z-=P[T],$(A,Z,oe)),le--,T=D(le),X(A,T,se),oe=N[T],oe!==0&&(le-=j[T],$(A,le,oe)));while(ie<A.last_lit);X(A,v,ne)}function $e(A,ne){var se=ne.dyn_tree,le=ne.stat_desc.static_tree,Z=ne.stat_desc.has_stree,ie=ne.stat_desc.elems,T,oe,be=-1,p;for(A.heap_len=0,A.heap_max=g,T=0;T<ie;T++)se[T*2]!==0?(A.heap[++A.heap_len]=be=T,A.depth[T]=0):se[T*2+1]=0;for(;A.heap_len<2;)p=A.heap[++A.heap_len]=be<2?++be:0,se[p*2]=1,A.depth[p]=0,A.opt_len--,Z&&(A.static_len-=le[p*2+1]);for(ne.max_code=be,T=A.heap_len>>1;T>=1;T--)Ie(A,se,T);p=ie;do T=A.heap[1],A.heap[1]=A.heap[A.heap_len--],Ie(A,se,1),oe=A.heap[1],A.heap[--A.heap_max]=T,A.heap[--A.heap_max]=oe,se[p*2]=se[T*2]+se[oe*2],A.depth[p]=(A.depth[T]>=A.depth[oe]?A.depth[T]:A.depth[oe])+1,se[T*2+1]=se[oe*2+1]=p,A.heap[1]=p++,Ie(A,se,1);while(A.heap_len>=2);A.heap[--A.heap_max]=A.heap[1],ue(A,ne),ve(se,be,A.bl_count)}function st(A,ne,se){var le,Z=-1,ie,T=ne[0*2+1],oe=0,be=7,p=4;for(T===0&&(be=138,p=3),ne[(se+1)*2+1]=65535,le=0;le<=se;le++)ie=T,T=ne[(le+1)*2+1],!(++oe<be&&ie===T)&&(oe<p?A.bl_tree[ie*2]+=oe:ie!==0?(ie!==Z&&A.bl_tree[ie*2]++,A.bl_tree[w*2]++):oe<=10?A.bl_tree[x*2]++:A.bl_tree[O*2]++,oe=0,Z=ie,T===0?(be=138,p=3):ie===T?(be=6,p=3):(be=7,p=4))}function qe(A,ne,se){var le,Z=-1,ie,T=ne[0*2+1],oe=0,be=7,p=4;for(T===0&&(be=138,p=3),le=0;le<=se;le++)if(ie=T,T=ne[(le+1)*2+1],!(++oe<be&&ie===T)){if(oe<p)do X(A,ie,A.bl_tree);while(--oe!==0);else ie!==0?(ie!==Z&&(X(A,ie,A.bl_tree),oe--),X(A,w,A.bl_tree),$(A,oe-3,2)):oe<=10?(X(A,x,A.bl_tree),$(A,oe-3,3)):(X(A,O,A.bl_tree),$(A,oe-11,7));oe=0,Z=ie,T===0?(be=138,p=3):ie===T?(be=6,p=3):(be=7,p=4)}}function Ne(A){var ne;for(st(A,A.dyn_ltree,A.l_desc.max_code),st(A,A.dyn_dtree,A.d_desc.max_code),$e(A,A.bl_desc),ne=y-1;ne>=3&&A.bl_tree[M[ne]*2+1]===0;ne--);return A.opt_len+=3*(ne+1)+5+5+4,ne}function We(A,ne,se,le){var Z;for($(A,ne-257,5),$(A,se-1,5),$(A,le-4,4),Z=0;Z<le;Z++)$(A,A.bl_tree[M[Z]*2+1],3);qe(A,A.dyn_ltree,ne-1),qe(A,A.dyn_dtree,se-1)}function J(A){var ne=4093624447,se;for(se=0;se<=31;se++,ne>>>=1)if(ne&1&&A.dyn_ltree[se*2]!==0)return o;if(A.dyn_ltree[9*2]!==0||A.dyn_ltree[10*2]!==0||A.dyn_ltree[13*2]!==0)return i;for(se=32;se<c;se++)if(A.dyn_ltree[se*2]!==0)return i;return o}var Q=!1;function ce(A){Q||(me(),Q=!0),A.l_desc=new V(A.dyn_ltree,B),A.d_desc=new V(A.dyn_dtree,Y),A.bl_desc=new V(A.bl_tree,H),A.bi_buf=0,A.bi_valid=0,we(A)}function ge(A,ne,se,le){$(A,(r<<1)+(le?1:0),3),ke(A,ne,se)}function he(A){$(A,s<<1,3),X(A,v,R),ae(A)}function Re(A,ne,se,le){var Z,ie,T=0;A.level>0?(A.strm.data_type===a&&(A.strm.data_type=J(A)),$e(A,A.l_desc),$e(A,A.d_desc),T=Ne(A),Z=A.opt_len+3+7>>>3,ie=A.static_len+3+7>>>3,ie<=Z&&(Z=ie)):Z=ie=se+5,se+4<=Z&&ne!==-1?ge(A,ne,se,le):A.strategy===n||ie===Z?($(A,(s<<1)+(le?1:0),3),Ee(A,R,L)):($(A,(h<<1)+(le?1:0),3),We(A,A.l_desc.max_code+1,A.d_desc.max_code+1,T+1),Ee(A,A.dyn_ltree,A.dyn_dtree)),we(A),le&&Ce(A)}function Oe(A,ne,se){return A.pending_buf[A.d_buf+A.last_lit*2]=ne>>>8&255,A.pending_buf[A.d_buf+A.last_lit*2+1]=ne&255,A.pending_buf[A.l_buf+A.last_lit]=se&255,A.last_lit++,ne===0?A.dyn_ltree[se*2]++:(A.matches++,ne--,A.dyn_ltree[(G[se]+c+1)*2]++,A.dyn_dtree[D(ne)*2]++),A.last_lit===A.lit_bufsize-1}return kt._tr_init=ce,kt._tr_stored_block=ge,kt._tr_flush_block=Re,kt._tr_tally=Oe,kt._tr_align=he,kt}var Pn,Rs;function uh(){if(Rs)return Pn;Rs=1;function e(n,o,i,a){for(var t=n&65535|0,r=n>>>16&65535|0,s=0;i!==0;){s=i>2e3?2e3:i,i-=s;do t=t+o[a++]|0,r=r+t|0;while(--s);t%=65521,r%=65521}return t|r<<16|0}return Pn=e,Pn}var kn,Os;function ch(){if(Os)return kn;Os=1;function e(){for(var i,a=[],t=0;t<256;t++){i=t;for(var r=0;r<8;r++)i=i&1?3988292384^i>>>1:i>>>1;a[t]=i}return a}var n=e();function o(i,a,t,r){var s=n,h=r+t;i^=-1;for(var f=r;f<h;f++)i=i>>>8^s[(i^a[f])&255];return i^-1}return kn=o,kn}var jn,Ts;function fm(){return Ts||(Ts=1,jn={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}),jn}var xs;function hm(){if(xs)return ut;xs=1;var e=yn(),n=lm(),o=uh(),i=ch(),a=fm(),t=0,r=1,s=3,h=4,f=5,l=0,d=1,c=-2,b=-3,m=-5,y=-1,g=1,u=2,_=3,E=4,v=0,w=2,x=8,O=9,C=15,N=8,W=29,M=256,S=M+1+W,R=30,L=19,q=2*S+1,G=15,P=3,j=258,k=j+P+1,B=32,Y=42,H=69,V=73,D=91,F=103,$=113,X=666,K=1,ae=2,ue=3,ve=4,me=3;function we(p,te){return p.msg=a[te],te}function Ce(p){return(p<<1)-(p>4?9:0)}function ke(p){for(var te=p.length;--te>=0;)p[te]=0}function je(p){var te=p.state,re=te.pending;re>p.avail_out&&(re=p.avail_out),re!==0&&(e.arraySet(p.output,te.pending_buf,te.pending_out,re,p.next_out),p.next_out+=re,te.pending_out+=re,p.total_out+=re,p.avail_out-=re,te.pending-=re,te.pending===0&&(te.pending_out=0))}function Ie(p,te){n._tr_flush_block(p,p.block_start>=0?p.block_start:-1,p.strstart-p.block_start,te),p.block_start=p.strstart,je(p.strm)}function Ee(p,te){p.pending_buf[p.pending++]=te}function $e(p,te){p.pending_buf[p.pending++]=te>>>8&255,p.pending_buf[p.pending++]=te&255}function st(p,te,re,I){var z=p.avail_in;return z>I&&(z=I),z===0?0:(p.avail_in-=z,e.arraySet(te,p.input,p.next_in,z,re),p.state.wrap===1?p.adler=o(p.adler,te,z,re):p.state.wrap===2&&(p.adler=i(p.adler,te,z,re)),p.next_in+=z,p.total_in+=z,z)}function qe(p,te){var re=p.max_chain_length,I=p.strstart,z,ee,_e=p.prev_length,de=p.nice_match,pe=p.strstart>p.w_size-k?p.strstart-(p.w_size-k):0,xe=p.window,vt=p.w_mask,Le=p.prev,Ae=p.strstart+j,Be=xe[I+_e-1],Je=xe[I+_e];p.prev_length>=p.good_match&&(re>>=2),de>p.lookahead&&(de=p.lookahead);do if(z=te,!(xe[z+_e]!==Je||xe[z+_e-1]!==Be||xe[z]!==xe[I]||xe[++z]!==xe[I+1])){I+=2,z++;do;while(xe[++I]===xe[++z]&&xe[++I]===xe[++z]&&xe[++I]===xe[++z]&&xe[++I]===xe[++z]&&xe[++I]===xe[++z]&&xe[++I]===xe[++z]&&xe[++I]===xe[++z]&&xe[++I]===xe[++z]&&I<Ae);if(ee=j-(Ae-I),I=Ae-j,ee>_e){if(p.match_start=te,_e=ee,ee>=de)break;Be=xe[I+_e-1],Je=xe[I+_e]}}while((te=Le[te&vt])>pe&&--re!==0);return _e<=p.lookahead?_e:p.lookahead}function Ne(p){var te=p.w_size,re,I,z,ee,_e;do{if(ee=p.window_size-p.lookahead-p.strstart,p.strstart>=te+(te-k)){e.arraySet(p.window,p.window,te,te,0),p.match_start-=te,p.strstart-=te,p.block_start-=te,I=p.hash_size,re=I;do z=p.head[--re],p.head[re]=z>=te?z-te:0;while(--I);I=te,re=I;do z=p.prev[--re],p.prev[re]=z>=te?z-te:0;while(--I);ee+=te}if(p.strm.avail_in===0)break;if(I=st(p.strm,p.window,p.strstart+p.lookahead,ee),p.lookahead+=I,p.lookahead+p.insert>=P)for(_e=p.strstart-p.insert,p.ins_h=p.window[_e],p.ins_h=(p.ins_h<<p.hash_shift^p.window[_e+1])&p.hash_mask;p.insert&&(p.ins_h=(p.ins_h<<p.hash_shift^p.window[_e+P-1])&p.hash_mask,p.prev[_e&p.w_mask]=p.head[p.ins_h],p.head[p.ins_h]=_e,_e++,p.insert--,!(p.lookahead+p.insert<P)););}while(p.lookahead<k&&p.strm.avail_in!==0)}function We(p,te){var re=65535;for(re>p.pending_buf_size-5&&(re=p.pending_buf_size-5);;){if(p.lookahead<=1){if(Ne(p),p.lookahead===0&&te===t)return K;if(p.lookahead===0)break}p.strstart+=p.lookahead,p.lookahead=0;var I=p.block_start+re;if((p.strstart===0||p.strstart>=I)&&(p.lookahead=p.strstart-I,p.strstart=I,Ie(p,!1),p.strm.avail_out===0)||p.strstart-p.block_start>=p.w_size-k&&(Ie(p,!1),p.strm.avail_out===0))return K}return p.insert=0,te===h?(Ie(p,!0),p.strm.avail_out===0?ue:ve):(p.strstart>p.block_start&&(Ie(p,!1),p.strm.avail_out===0),K)}function J(p,te){for(var re,I;;){if(p.lookahead<k){if(Ne(p),p.lookahead<k&&te===t)return K;if(p.lookahead===0)break}if(re=0,p.lookahead>=P&&(p.ins_h=(p.ins_h<<p.hash_shift^p.window[p.strstart+P-1])&p.hash_mask,re=p.prev[p.strstart&p.w_mask]=p.head[p.ins_h],p.head[p.ins_h]=p.strstart),re!==0&&p.strstart-re<=p.w_size-k&&(p.match_length=qe(p,re)),p.match_length>=P)if(I=n._tr_tally(p,p.strstart-p.match_start,p.match_length-P),p.lookahead-=p.match_length,p.match_length<=p.max_lazy_match&&p.lookahead>=P){p.match_length--;do p.strstart++,p.ins_h=(p.ins_h<<p.hash_shift^p.window[p.strstart+P-1])&p.hash_mask,re=p.prev[p.strstart&p.w_mask]=p.head[p.ins_h],p.head[p.ins_h]=p.strstart;while(--p.match_length!==0);p.strstart++}else p.strstart+=p.match_length,p.match_length=0,p.ins_h=p.window[p.strstart],p.ins_h=(p.ins_h<<p.hash_shift^p.window[p.strstart+1])&p.hash_mask;else I=n._tr_tally(p,0,p.window[p.strstart]),p.lookahead--,p.strstart++;if(I&&(Ie(p,!1),p.strm.avail_out===0))return K}return p.insert=p.strstart<P-1?p.strstart:P-1,te===h?(Ie(p,!0),p.strm.avail_out===0?ue:ve):p.last_lit&&(Ie(p,!1),p.strm.avail_out===0)?K:ae}function Q(p,te){for(var re,I,z;;){if(p.lookahead<k){if(Ne(p),p.lookahead<k&&te===t)return K;if(p.lookahead===0)break}if(re=0,p.lookahead>=P&&(p.ins_h=(p.ins_h<<p.hash_shift^p.window[p.strstart+P-1])&p.hash_mask,re=p.prev[p.strstart&p.w_mask]=p.head[p.ins_h],p.head[p.ins_h]=p.strstart),p.prev_length=p.match_length,p.prev_match=p.match_start,p.match_length=P-1,re!==0&&p.prev_length<p.max_lazy_match&&p.strstart-re<=p.w_size-k&&(p.match_length=qe(p,re),p.match_length<=5&&(p.strategy===g||p.match_length===P&&p.strstart-p.match_start>4096)&&(p.match_length=P-1)),p.prev_length>=P&&p.match_length<=p.prev_length){z=p.strstart+p.lookahead-P,I=n._tr_tally(p,p.strstart-1-p.prev_match,p.prev_length-P),p.lookahead-=p.prev_length-1,p.prev_length-=2;do++p.strstart<=z&&(p.ins_h=(p.ins_h<<p.hash_shift^p.window[p.strstart+P-1])&p.hash_mask,re=p.prev[p.strstart&p.w_mask]=p.head[p.ins_h],p.head[p.ins_h]=p.strstart);while(--p.prev_length!==0);if(p.match_available=0,p.match_length=P-1,p.strstart++,I&&(Ie(p,!1),p.strm.avail_out===0))return K}else if(p.match_available){if(I=n._tr_tally(p,0,p.window[p.strstart-1]),I&&Ie(p,!1),p.strstart++,p.lookahead--,p.strm.avail_out===0)return K}else p.match_available=1,p.strstart++,p.lookahead--}return p.match_available&&(I=n._tr_tally(p,0,p.window[p.strstart-1]),p.match_available=0),p.insert=p.strstart<P-1?p.strstart:P-1,te===h?(Ie(p,!0),p.strm.avail_out===0?ue:ve):p.last_lit&&(Ie(p,!1),p.strm.avail_out===0)?K:ae}function ce(p,te){for(var re,I,z,ee,_e=p.window;;){if(p.lookahead<=j){if(Ne(p),p.lookahead<=j&&te===t)return K;if(p.lookahead===0)break}if(p.match_length=0,p.lookahead>=P&&p.strstart>0&&(z=p.strstart-1,I=_e[z],I===_e[++z]&&I===_e[++z]&&I===_e[++z])){ee=p.strstart+j;do;while(I===_e[++z]&&I===_e[++z]&&I===_e[++z]&&I===_e[++z]&&I===_e[++z]&&I===_e[++z]&&I===_e[++z]&&I===_e[++z]&&z<ee);p.match_length=j-(ee-z),p.match_length>p.lookahead&&(p.match_length=p.lookahead)}if(p.match_length>=P?(re=n._tr_tally(p,1,p.match_length-P),p.lookahead-=p.match_length,p.strstart+=p.match_length,p.match_length=0):(re=n._tr_tally(p,0,p.window[p.strstart]),p.lookahead--,p.strstart++),re&&(Ie(p,!1),p.strm.avail_out===0))return K}return p.insert=0,te===h?(Ie(p,!0),p.strm.avail_out===0?ue:ve):p.last_lit&&(Ie(p,!1),p.strm.avail_out===0)?K:ae}function ge(p,te){for(var re;;){if(p.lookahead===0&&(Ne(p),p.lookahead===0)){if(te===t)return K;break}if(p.match_length=0,re=n._tr_tally(p,0,p.window[p.strstart]),p.lookahead--,p.strstart++,re&&(Ie(p,!1),p.strm.avail_out===0))return K}return p.insert=0,te===h?(Ie(p,!0),p.strm.avail_out===0?ue:ve):p.last_lit&&(Ie(p,!1),p.strm.avail_out===0)?K:ae}function he(p,te,re,I,z){this.good_length=p,this.max_lazy=te,this.nice_length=re,this.max_chain=I,this.func=z}var Re;Re=[new he(0,0,0,0,We),new he(4,4,8,4,J),new he(4,5,16,8,J),new he(4,6,32,32,J),new he(4,4,16,16,Q),new he(8,16,32,32,Q),new he(8,16,128,128,Q),new he(8,32,128,256,Q),new he(32,128,258,1024,Q),new he(32,258,258,4096,Q)];function Oe(p){p.window_size=2*p.w_size,ke(p.head),p.max_lazy_match=Re[p.level].max_lazy,p.good_match=Re[p.level].good_length,p.nice_match=Re[p.level].nice_length,p.max_chain_length=Re[p.level].max_chain,p.strstart=0,p.block_start=0,p.lookahead=0,p.insert=0,p.match_length=p.prev_length=P-1,p.match_available=0,p.ins_h=0}function A(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=x,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new e.Buf16(q*2),this.dyn_dtree=new e.Buf16((2*R+1)*2),this.bl_tree=new e.Buf16((2*L+1)*2),ke(this.dyn_ltree),ke(this.dyn_dtree),ke(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new e.Buf16(G+1),this.heap=new e.Buf16(2*S+1),ke(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new e.Buf16(2*S+1),ke(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function ne(p){var te;return!p||!p.state?we(p,c):(p.total_in=p.total_out=0,p.data_type=w,te=p.state,te.pending=0,te.pending_out=0,te.wrap<0&&(te.wrap=-te.wrap),te.status=te.wrap?Y:$,p.adler=te.wrap===2?0:1,te.last_flush=t,n._tr_init(te),l)}function se(p){var te=ne(p);return te===l&&Oe(p.state),te}function le(p,te){return!p||!p.state||p.state.wrap!==2?c:(p.state.gzhead=te,l)}function Z(p,te,re,I,z,ee){if(!p)return c;var _e=1;if(te===y&&(te=6),I<0?(_e=0,I=-I):I>15&&(_e=2,I-=16),z<1||z>O||re!==x||I<8||I>15||te<0||te>9||ee<0||ee>E)return we(p,c);I===8&&(I=9);var de=new A;return p.state=de,de.strm=p,de.wrap=_e,de.gzhead=null,de.w_bits=I,de.w_size=1<<de.w_bits,de.w_mask=de.w_size-1,de.hash_bits=z+7,de.hash_size=1<<de.hash_bits,de.hash_mask=de.hash_size-1,de.hash_shift=~~((de.hash_bits+P-1)/P),de.window=new e.Buf8(de.w_size*2),de.head=new e.Buf16(de.hash_size),de.prev=new e.Buf16(de.w_size),de.lit_bufsize=1<<z+6,de.pending_buf_size=de.lit_bufsize*4,de.pending_buf=new e.Buf8(de.pending_buf_size),de.d_buf=1*de.lit_bufsize,de.l_buf=3*de.lit_bufsize,de.level=te,de.strategy=ee,de.method=re,se(p)}function ie(p,te){return Z(p,te,x,C,N,v)}function T(p,te){var re,I,z,ee;if(!p||!p.state||te>f||te<0)return p?we(p,c):c;if(I=p.state,!p.output||!p.input&&p.avail_in!==0||I.status===X&&te!==h)return we(p,p.avail_out===0?m:c);if(I.strm=p,re=I.last_flush,I.last_flush=te,I.status===Y)if(I.wrap===2)p.adler=0,Ee(I,31),Ee(I,139),Ee(I,8),I.gzhead?(Ee(I,(I.gzhead.text?1:0)+(I.gzhead.hcrc?2:0)+(I.gzhead.extra?4:0)+(I.gzhead.name?8:0)+(I.gzhead.comment?16:0)),Ee(I,I.gzhead.time&255),Ee(I,I.gzhead.time>>8&255),Ee(I,I.gzhead.time>>16&255),Ee(I,I.gzhead.time>>24&255),Ee(I,I.level===9?2:I.strategy>=u||I.level<2?4:0),Ee(I,I.gzhead.os&255),I.gzhead.extra&&I.gzhead.extra.length&&(Ee(I,I.gzhead.extra.length&255),Ee(I,I.gzhead.extra.length>>8&255)),I.gzhead.hcrc&&(p.adler=i(p.adler,I.pending_buf,I.pending,0)),I.gzindex=0,I.status=H):(Ee(I,0),Ee(I,0),Ee(I,0),Ee(I,0),Ee(I,0),Ee(I,I.level===9?2:I.strategy>=u||I.level<2?4:0),Ee(I,me),I.status=$);else{var _e=x+(I.w_bits-8<<4)<<8,de=-1;I.strategy>=u||I.level<2?de=0:I.level<6?de=1:I.level===6?de=2:de=3,_e|=de<<6,I.strstart!==0&&(_e|=B),_e+=31-_e%31,I.status=$,$e(I,_e),I.strstart!==0&&($e(I,p.adler>>>16),$e(I,p.adler&65535)),p.adler=1}if(I.status===H)if(I.gzhead.extra){for(z=I.pending;I.gzindex<(I.gzhead.extra.length&65535)&&!(I.pending===I.pending_buf_size&&(I.gzhead.hcrc&&I.pending>z&&(p.adler=i(p.adler,I.pending_buf,I.pending-z,z)),je(p),z=I.pending,I.pending===I.pending_buf_size));)Ee(I,I.gzhead.extra[I.gzindex]&255),I.gzindex++;I.gzhead.hcrc&&I.pending>z&&(p.adler=i(p.adler,I.pending_buf,I.pending-z,z)),I.gzindex===I.gzhead.extra.length&&(I.gzindex=0,I.status=V)}else I.status=V;if(I.status===V)if(I.gzhead.name){z=I.pending;do{if(I.pending===I.pending_buf_size&&(I.gzhead.hcrc&&I.pending>z&&(p.adler=i(p.adler,I.pending_buf,I.pending-z,z)),je(p),z=I.pending,I.pending===I.pending_buf_size)){ee=1;break}I.gzindex<I.gzhead.name.length?ee=I.gzhead.name.charCodeAt(I.gzindex++)&255:ee=0,Ee(I,ee)}while(ee!==0);I.gzhead.hcrc&&I.pending>z&&(p.adler=i(p.adler,I.pending_buf,I.pending-z,z)),ee===0&&(I.gzindex=0,I.status=D)}else I.status=D;if(I.status===D)if(I.gzhead.comment){z=I.pending;do{if(I.pending===I.pending_buf_size&&(I.gzhead.hcrc&&I.pending>z&&(p.adler=i(p.adler,I.pending_buf,I.pending-z,z)),je(p),z=I.pending,I.pending===I.pending_buf_size)){ee=1;break}I.gzindex<I.gzhead.comment.length?ee=I.gzhead.comment.charCodeAt(I.gzindex++)&255:ee=0,Ee(I,ee)}while(ee!==0);I.gzhead.hcrc&&I.pending>z&&(p.adler=i(p.adler,I.pending_buf,I.pending-z,z)),ee===0&&(I.status=F)}else I.status=F;if(I.status===F&&(I.gzhead.hcrc?(I.pending+2>I.pending_buf_size&&je(p),I.pending+2<=I.pending_buf_size&&(Ee(I,p.adler&255),Ee(I,p.adler>>8&255),p.adler=0,I.status=$)):I.status=$),I.pending!==0){if(je(p),p.avail_out===0)return I.last_flush=-1,l}else if(p.avail_in===0&&Ce(te)<=Ce(re)&&te!==h)return we(p,m);if(I.status===X&&p.avail_in!==0)return we(p,m);if(p.avail_in!==0||I.lookahead!==0||te!==t&&I.status!==X){var pe=I.strategy===u?ge(I,te):I.strategy===_?ce(I,te):Re[I.level].func(I,te);if((pe===ue||pe===ve)&&(I.status=X),pe===K||pe===ue)return p.avail_out===0&&(I.last_flush=-1),l;if(pe===ae&&(te===r?n._tr_align(I):te!==f&&(n._tr_stored_block(I,0,0,!1),te===s&&(ke(I.head),I.lookahead===0&&(I.strstart=0,I.block_start=0,I.insert=0))),je(p),p.avail_out===0))return I.last_flush=-1,l}return te!==h?l:I.wrap<=0?d:(I.wrap===2?(Ee(I,p.adler&255),Ee(I,p.adler>>8&255),Ee(I,p.adler>>16&255),Ee(I,p.adler>>24&255),Ee(I,p.total_in&255),Ee(I,p.total_in>>8&255),Ee(I,p.total_in>>16&255),Ee(I,p.total_in>>24&255)):($e(I,p.adler>>>16),$e(I,p.adler&65535)),je(p),I.wrap>0&&(I.wrap=-I.wrap),I.pending!==0?l:d)}function oe(p){var te;return!p||!p.state?c:(te=p.state.status,te!==Y&&te!==H&&te!==V&&te!==D&&te!==F&&te!==$&&te!==X?we(p,c):(p.state=null,te===$?we(p,b):l))}function be(p,te){var re=te.length,I,z,ee,_e,de,pe,xe,vt;if(!p||!p.state||(I=p.state,_e=I.wrap,_e===2||_e===1&&I.status!==Y||I.lookahead))return c;for(_e===1&&(p.adler=o(p.adler,te,re,0)),I.wrap=0,re>=I.w_size&&(_e===0&&(ke(I.head),I.strstart=0,I.block_start=0,I.insert=0),vt=new e.Buf8(I.w_size),e.arraySet(vt,te,re-I.w_size,I.w_size,0),te=vt,re=I.w_size),de=p.avail_in,pe=p.next_in,xe=p.input,p.avail_in=re,p.next_in=0,p.input=te,Ne(I);I.lookahead>=P;){z=I.strstart,ee=I.lookahead-(P-1);do I.ins_h=(I.ins_h<<I.hash_shift^I.window[z+P-1])&I.hash_mask,I.prev[z&I.w_mask]=I.head[I.ins_h],I.head[I.ins_h]=z,z++;while(--ee);I.strstart=z,I.lookahead=P-1,Ne(I)}return I.strstart+=I.lookahead,I.block_start=I.strstart,I.insert=I.lookahead,I.lookahead=0,I.match_length=I.prev_length=P-1,I.match_available=0,p.next_in=pe,p.input=xe,p.avail_in=de,I.wrap=_e,l}return ut.deflateInit=ie,ut.deflateInit2=Z,ut.deflateReset=se,ut.deflateResetKeep=ne,ut.deflateSetHeader=le,ut.deflate=T,ut.deflateEnd=oe,ut.deflateSetDictionary=be,ut.deflateInfo="pako deflate (from Nodeca project)",ut}var Ln,Is;function dm(){if(Is)return Ln;Is=1;function e(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}return Ln=e,Ln}var it={},qn,As;function pm(){if(As)return qn;As=1;var e=30,n=12;return qn=function(i,a){var t,r,s,h,f,l,d,c,b,m,y,g,u,_,E,v,w,x,O,C,N,W,M,S,R;t=i.state,r=i.next_in,S=i.input,s=r+(i.avail_in-5),h=i.next_out,R=i.output,f=h-(a-i.avail_out),l=h+(i.avail_out-257),d=t.dmax,c=t.wsize,b=t.whave,m=t.wnext,y=t.window,g=t.hold,u=t.bits,_=t.lencode,E=t.distcode,v=(1<<t.lenbits)-1,w=(1<<t.distbits)-1;e:do{u<15&&(g+=S[r++]<<u,u+=8,g+=S[r++]<<u,u+=8),x=_[g&v];t:for(;;){if(O=x>>>24,g>>>=O,u-=O,O=x>>>16&255,O===0)R[h++]=x&65535;else if(O&16){C=x&65535,O&=15,O&&(u<O&&(g+=S[r++]<<u,u+=8),C+=g&(1<<O)-1,g>>>=O,u-=O),u<15&&(g+=S[r++]<<u,u+=8,g+=S[r++]<<u,u+=8),x=E[g&w];r:for(;;){if(O=x>>>24,g>>>=O,u-=O,O=x>>>16&255,O&16){if(N=x&65535,O&=15,u<O&&(g+=S[r++]<<u,u+=8,u<O&&(g+=S[r++]<<u,u+=8)),N+=g&(1<<O)-1,N>d){i.msg="invalid distance too far back",t.mode=e;break e}if(g>>>=O,u-=O,O=h-f,N>O){if(O=N-O,O>b&&t.sane){i.msg="invalid distance too far back",t.mode=e;break e}if(W=0,M=y,m===0){if(W+=c-O,O<C){C-=O;do R[h++]=y[W++];while(--O);W=h-N,M=R}}else if(m<O){if(W+=c+m-O,O-=m,O<C){C-=O;do R[h++]=y[W++];while(--O);if(W=0,m<C){O=m,C-=O;do R[h++]=y[W++];while(--O);W=h-N,M=R}}}else if(W+=m-O,O<C){C-=O;do R[h++]=y[W++];while(--O);W=h-N,M=R}for(;C>2;)R[h++]=M[W++],R[h++]=M[W++],R[h++]=M[W++],C-=3;C&&(R[h++]=M[W++],C>1&&(R[h++]=M[W++]))}else{W=h-N;do R[h++]=R[W++],R[h++]=R[W++],R[h++]=R[W++],C-=3;while(C>2);C&&(R[h++]=R[W++],C>1&&(R[h++]=R[W++]))}}else if((O&64)===0){x=E[(x&65535)+(g&(1<<O)-1)];continue r}else{i.msg="invalid distance code",t.mode=e;break e}break}}else if((O&64)===0){x=_[(x&65535)+(g&(1<<O)-1)];continue t}else if(O&32){t.mode=n;break e}else{i.msg="invalid literal/length code",t.mode=e;break e}break}}while(r<s&&h<l);C=u>>3,r-=C,u-=C<<3,g&=(1<<u)-1,i.next_in=r,i.next_out=h,i.avail_in=r<s?5+(s-r):5-(r-s),i.avail_out=h<l?257+(l-h):257-(h-l),t.hold=g,t.bits=u},qn}var Dn,Cs;function mm(){if(Cs)return Dn;Cs=1;var e=yn(),n=15,o=852,i=592,a=0,t=1,r=2,s=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],h=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],f=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],l=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];return Dn=function(c,b,m,y,g,u,_,E){var v=E.bits,w=0,x=0,O=0,C=0,N=0,W=0,M=0,S=0,R=0,L=0,q,G,P,j,k,B=null,Y=0,H,V=new e.Buf16(n+1),D=new e.Buf16(n+1),F=null,$=0,X,K,ae;for(w=0;w<=n;w++)V[w]=0;for(x=0;x<y;x++)V[b[m+x]]++;for(N=v,C=n;C>=1&&V[C]===0;C--);if(N>C&&(N=C),C===0)return g[u++]=1<<24|64<<16|0,g[u++]=1<<24|64<<16|0,E.bits=1,0;for(O=1;O<C&&V[O]===0;O++);for(N<O&&(N=O),S=1,w=1;w<=n;w++)if(S<<=1,S-=V[w],S<0)return-1;if(S>0&&(c===a||C!==1))return-1;for(D[1]=0,w=1;w<n;w++)D[w+1]=D[w]+V[w];for(x=0;x<y;x++)b[m+x]!==0&&(_[D[b[m+x]]++]=x);if(c===a?(B=F=_,H=19):c===t?(B=s,Y-=257,F=h,$-=257,H=256):(B=f,F=l,H=-1),L=0,x=0,w=O,k=u,W=N,M=0,P=-1,R=1<<N,j=R-1,c===t&&R>o||c===r&&R>i)return 1;for(;;){X=w-M,_[x]<H?(K=0,ae=_[x]):_[x]>H?(K=F[$+_[x]],ae=B[Y+_[x]]):(K=96,ae=0),q=1<<w-M,G=1<<W,O=G;do G-=q,g[k+(L>>M)+G]=X<<24|K<<16|ae|0;while(G!==0);for(q=1<<w-1;L&q;)q>>=1;if(q!==0?(L&=q-1,L+=q):L=0,x++,--V[w]===0){if(w===C)break;w=b[m+_[x]]}if(w>N&&(L&j)!==P){for(M===0&&(M=N),k+=O,W=w-M,S=1<<W;W+M<C&&(S-=V[W+M],!(S<=0));)W++,S<<=1;if(R+=1<<W,c===t&&R>o||c===r&&R>i)return 1;P=L&j,g[P]=N<<24|W<<16|k-u|0}}return L!==0&&(g[k+L]=w-M<<24|64<<16|0),E.bits=N,0},Dn}var Ps;function gm(){if(Ps)return it;Ps=1;var e=yn(),n=uh(),o=ch(),i=pm(),a=mm(),t=0,r=1,s=2,h=4,f=5,l=6,d=0,c=1,b=2,m=-2,y=-3,g=-4,u=-5,_=8,E=1,v=2,w=3,x=4,O=5,C=6,N=7,W=8,M=9,S=10,R=11,L=12,q=13,G=14,P=15,j=16,k=17,B=18,Y=19,H=20,V=21,D=22,F=23,$=24,X=25,K=26,ae=27,ue=28,ve=29,me=30,we=31,Ce=32,ke=852,je=592,Ie=15,Ee=Ie;function $e(Z){return(Z>>>24&255)+(Z>>>8&65280)+((Z&65280)<<8)+((Z&255)<<24)}function st(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new e.Buf16(320),this.work=new e.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function qe(Z){var ie;return!Z||!Z.state?m:(ie=Z.state,Z.total_in=Z.total_out=ie.total=0,Z.msg="",ie.wrap&&(Z.adler=ie.wrap&1),ie.mode=E,ie.last=0,ie.havedict=0,ie.dmax=32768,ie.head=null,ie.hold=0,ie.bits=0,ie.lencode=ie.lendyn=new e.Buf32(ke),ie.distcode=ie.distdyn=new e.Buf32(je),ie.sane=1,ie.back=-1,d)}function Ne(Z){var ie;return!Z||!Z.state?m:(ie=Z.state,ie.wsize=0,ie.whave=0,ie.wnext=0,qe(Z))}function We(Z,ie){var T,oe;return!Z||!Z.state||(oe=Z.state,ie<0?(T=0,ie=-ie):(T=(ie>>4)+1,ie<48&&(ie&=15)),ie&&(ie<8||ie>15))?m:(oe.window!==null&&oe.wbits!==ie&&(oe.window=null),oe.wrap=T,oe.wbits=ie,Ne(Z))}function J(Z,ie){var T,oe;return Z?(oe=new st,Z.state=oe,oe.window=null,T=We(Z,ie),T!==d&&(Z.state=null),T):m}function Q(Z){return J(Z,Ee)}var ce=!0,ge,he;function Re(Z){if(ce){var ie;for(ge=new e.Buf32(512),he=new e.Buf32(32),ie=0;ie<144;)Z.lens[ie++]=8;for(;ie<256;)Z.lens[ie++]=9;for(;ie<280;)Z.lens[ie++]=7;for(;ie<288;)Z.lens[ie++]=8;for(a(r,Z.lens,0,288,ge,0,Z.work,{bits:9}),ie=0;ie<32;)Z.lens[ie++]=5;a(s,Z.lens,0,32,he,0,Z.work,{bits:5}),ce=!1}Z.lencode=ge,Z.lenbits=9,Z.distcode=he,Z.distbits=5}function Oe(Z,ie,T,oe){var be,p=Z.state;return p.window===null&&(p.wsize=1<<p.wbits,p.wnext=0,p.whave=0,p.window=new e.Buf8(p.wsize)),oe>=p.wsize?(e.arraySet(p.window,ie,T-p.wsize,p.wsize,0),p.wnext=0,p.whave=p.wsize):(be=p.wsize-p.wnext,be>oe&&(be=oe),e.arraySet(p.window,ie,T-oe,be,p.wnext),oe-=be,oe?(e.arraySet(p.window,ie,T-oe,oe,0),p.wnext=oe,p.whave=p.wsize):(p.wnext+=be,p.wnext===p.wsize&&(p.wnext=0),p.whave<p.wsize&&(p.whave+=be))),0}function A(Z,ie){var T,oe,be,p,te,re,I,z,ee,_e,de,pe,xe,vt,Le=0,Ae,Be,Je,Xe,_r,br,Me,nt,ze=new e.Buf8(4),yt,ht,gs=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!Z||!Z.state||!Z.output||!Z.input&&Z.avail_in!==0)return m;T=Z.state,T.mode===L&&(T.mode=q),te=Z.next_out,be=Z.output,I=Z.avail_out,p=Z.next_in,oe=Z.input,re=Z.avail_in,z=T.hold,ee=T.bits,_e=re,de=I,nt=d;e:for(;;)switch(T.mode){case E:if(T.wrap===0){T.mode=q;break}for(;ee<16;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}if(T.wrap&2&&z===35615){T.check=0,ze[0]=z&255,ze[1]=z>>>8&255,T.check=o(T.check,ze,2,0),z=0,ee=0,T.mode=v;break}if(T.flags=0,T.head&&(T.head.done=!1),!(T.wrap&1)||(((z&255)<<8)+(z>>8))%31){Z.msg="incorrect header check",T.mode=me;break}if((z&15)!==_){Z.msg="unknown compression method",T.mode=me;break}if(z>>>=4,ee-=4,Me=(z&15)+8,T.wbits===0)T.wbits=Me;else if(Me>T.wbits){Z.msg="invalid window size",T.mode=me;break}T.dmax=1<<Me,Z.adler=T.check=1,T.mode=z&512?S:L,z=0,ee=0;break;case v:for(;ee<16;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}if(T.flags=z,(T.flags&255)!==_){Z.msg="unknown compression method",T.mode=me;break}if(T.flags&57344){Z.msg="unknown header flags set",T.mode=me;break}T.head&&(T.head.text=z>>8&1),T.flags&512&&(ze[0]=z&255,ze[1]=z>>>8&255,T.check=o(T.check,ze,2,0)),z=0,ee=0,T.mode=w;case w:for(;ee<32;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}T.head&&(T.head.time=z),T.flags&512&&(ze[0]=z&255,ze[1]=z>>>8&255,ze[2]=z>>>16&255,ze[3]=z>>>24&255,T.check=o(T.check,ze,4,0)),z=0,ee=0,T.mode=x;case x:for(;ee<16;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}T.head&&(T.head.xflags=z&255,T.head.os=z>>8),T.flags&512&&(ze[0]=z&255,ze[1]=z>>>8&255,T.check=o(T.check,ze,2,0)),z=0,ee=0,T.mode=O;case O:if(T.flags&1024){for(;ee<16;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}T.length=z,T.head&&(T.head.extra_len=z),T.flags&512&&(ze[0]=z&255,ze[1]=z>>>8&255,T.check=o(T.check,ze,2,0)),z=0,ee=0}else T.head&&(T.head.extra=null);T.mode=C;case C:if(T.flags&1024&&(pe=T.length,pe>re&&(pe=re),pe&&(T.head&&(Me=T.head.extra_len-T.length,T.head.extra||(T.head.extra=new Array(T.head.extra_len)),e.arraySet(T.head.extra,oe,p,pe,Me)),T.flags&512&&(T.check=o(T.check,oe,pe,p)),re-=pe,p+=pe,T.length-=pe),T.length))break e;T.length=0,T.mode=N;case N:if(T.flags&2048){if(re===0)break e;pe=0;do Me=oe[p+pe++],T.head&&Me&&T.length<65536&&(T.head.name+=String.fromCharCode(Me));while(Me&&pe<re);if(T.flags&512&&(T.check=o(T.check,oe,pe,p)),re-=pe,p+=pe,Me)break e}else T.head&&(T.head.name=null);T.length=0,T.mode=W;case W:if(T.flags&4096){if(re===0)break e;pe=0;do Me=oe[p+pe++],T.head&&Me&&T.length<65536&&(T.head.comment+=String.fromCharCode(Me));while(Me&&pe<re);if(T.flags&512&&(T.check=o(T.check,oe,pe,p)),re-=pe,p+=pe,Me)break e}else T.head&&(T.head.comment=null);T.mode=M;case M:if(T.flags&512){for(;ee<16;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}if(z!==(T.check&65535)){Z.msg="header crc mismatch",T.mode=me;break}z=0,ee=0}T.head&&(T.head.hcrc=T.flags>>9&1,T.head.done=!0),Z.adler=T.check=0,T.mode=L;break;case S:for(;ee<32;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}Z.adler=T.check=$e(z),z=0,ee=0,T.mode=R;case R:if(T.havedict===0)return Z.next_out=te,Z.avail_out=I,Z.next_in=p,Z.avail_in=re,T.hold=z,T.bits=ee,b;Z.adler=T.check=1,T.mode=L;case L:if(ie===f||ie===l)break e;case q:if(T.last){z>>>=ee&7,ee-=ee&7,T.mode=ae;break}for(;ee<3;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}switch(T.last=z&1,z>>>=1,ee-=1,z&3){case 0:T.mode=G;break;case 1:if(Re(T),T.mode=H,ie===l){z>>>=2,ee-=2;break e}break;case 2:T.mode=k;break;case 3:Z.msg="invalid block type",T.mode=me}z>>>=2,ee-=2;break;case G:for(z>>>=ee&7,ee-=ee&7;ee<32;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}if((z&65535)!==(z>>>16^65535)){Z.msg="invalid stored block lengths",T.mode=me;break}if(T.length=z&65535,z=0,ee=0,T.mode=P,ie===l)break e;case P:T.mode=j;case j:if(pe=T.length,pe){if(pe>re&&(pe=re),pe>I&&(pe=I),pe===0)break e;e.arraySet(be,oe,p,pe,te),re-=pe,p+=pe,I-=pe,te+=pe,T.length-=pe;break}T.mode=L;break;case k:for(;ee<14;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}if(T.nlen=(z&31)+257,z>>>=5,ee-=5,T.ndist=(z&31)+1,z>>>=5,ee-=5,T.ncode=(z&15)+4,z>>>=4,ee-=4,T.nlen>286||T.ndist>30){Z.msg="too many length or distance symbols",T.mode=me;break}T.have=0,T.mode=B;case B:for(;T.have<T.ncode;){for(;ee<3;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}T.lens[gs[T.have++]]=z&7,z>>>=3,ee-=3}for(;T.have<19;)T.lens[gs[T.have++]]=0;if(T.lencode=T.lendyn,T.lenbits=7,yt={bits:T.lenbits},nt=a(t,T.lens,0,19,T.lencode,0,T.work,yt),T.lenbits=yt.bits,nt){Z.msg="invalid code lengths set",T.mode=me;break}T.have=0,T.mode=Y;case Y:for(;T.have<T.nlen+T.ndist;){for(;Le=T.lencode[z&(1<<T.lenbits)-1],Ae=Le>>>24,Be=Le>>>16&255,Je=Le&65535,!(Ae<=ee);){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}if(Je<16)z>>>=Ae,ee-=Ae,T.lens[T.have++]=Je;else{if(Je===16){for(ht=Ae+2;ee<ht;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}if(z>>>=Ae,ee-=Ae,T.have===0){Z.msg="invalid bit length repeat",T.mode=me;break}Me=T.lens[T.have-1],pe=3+(z&3),z>>>=2,ee-=2}else if(Je===17){for(ht=Ae+3;ee<ht;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}z>>>=Ae,ee-=Ae,Me=0,pe=3+(z&7),z>>>=3,ee-=3}else{for(ht=Ae+7;ee<ht;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}z>>>=Ae,ee-=Ae,Me=0,pe=11+(z&127),z>>>=7,ee-=7}if(T.have+pe>T.nlen+T.ndist){Z.msg="invalid bit length repeat",T.mode=me;break}for(;pe--;)T.lens[T.have++]=Me}}if(T.mode===me)break;if(T.lens[256]===0){Z.msg="invalid code -- missing end-of-block",T.mode=me;break}if(T.lenbits=9,yt={bits:T.lenbits},nt=a(r,T.lens,0,T.nlen,T.lencode,0,T.work,yt),T.lenbits=yt.bits,nt){Z.msg="invalid literal/lengths set",T.mode=me;break}if(T.distbits=6,T.distcode=T.distdyn,yt={bits:T.distbits},nt=a(s,T.lens,T.nlen,T.ndist,T.distcode,0,T.work,yt),T.distbits=yt.bits,nt){Z.msg="invalid distances set",T.mode=me;break}if(T.mode=H,ie===l)break e;case H:T.mode=V;case V:if(re>=6&&I>=258){Z.next_out=te,Z.avail_out=I,Z.next_in=p,Z.avail_in=re,T.hold=z,T.bits=ee,i(Z,de),te=Z.next_out,be=Z.output,I=Z.avail_out,p=Z.next_in,oe=Z.input,re=Z.avail_in,z=T.hold,ee=T.bits,T.mode===L&&(T.back=-1);break}for(T.back=0;Le=T.lencode[z&(1<<T.lenbits)-1],Ae=Le>>>24,Be=Le>>>16&255,Je=Le&65535,!(Ae<=ee);){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}if(Be&&(Be&240)===0){for(Xe=Ae,_r=Be,br=Je;Le=T.lencode[br+((z&(1<<Xe+_r)-1)>>Xe)],Ae=Le>>>24,Be=Le>>>16&255,Je=Le&65535,!(Xe+Ae<=ee);){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}z>>>=Xe,ee-=Xe,T.back+=Xe}if(z>>>=Ae,ee-=Ae,T.back+=Ae,T.length=Je,Be===0){T.mode=K;break}if(Be&32){T.back=-1,T.mode=L;break}if(Be&64){Z.msg="invalid literal/length code",T.mode=me;break}T.extra=Be&15,T.mode=D;case D:if(T.extra){for(ht=T.extra;ee<ht;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}T.length+=z&(1<<T.extra)-1,z>>>=T.extra,ee-=T.extra,T.back+=T.extra}T.was=T.length,T.mode=F;case F:for(;Le=T.distcode[z&(1<<T.distbits)-1],Ae=Le>>>24,Be=Le>>>16&255,Je=Le&65535,!(Ae<=ee);){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}if((Be&240)===0){for(Xe=Ae,_r=Be,br=Je;Le=T.distcode[br+((z&(1<<Xe+_r)-1)>>Xe)],Ae=Le>>>24,Be=Le>>>16&255,Je=Le&65535,!(Xe+Ae<=ee);){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}z>>>=Xe,ee-=Xe,T.back+=Xe}if(z>>>=Ae,ee-=Ae,T.back+=Ae,Be&64){Z.msg="invalid distance code",T.mode=me;break}T.offset=Je,T.extra=Be&15,T.mode=$;case $:if(T.extra){for(ht=T.extra;ee<ht;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}T.offset+=z&(1<<T.extra)-1,z>>>=T.extra,ee-=T.extra,T.back+=T.extra}if(T.offset>T.dmax){Z.msg="invalid distance too far back",T.mode=me;break}T.mode=X;case X:if(I===0)break e;if(pe=de-I,T.offset>pe){if(pe=T.offset-pe,pe>T.whave&&T.sane){Z.msg="invalid distance too far back",T.mode=me;break}pe>T.wnext?(pe-=T.wnext,xe=T.wsize-pe):xe=T.wnext-pe,pe>T.length&&(pe=T.length),vt=T.window}else vt=be,xe=te-T.offset,pe=T.length;pe>I&&(pe=I),I-=pe,T.length-=pe;do be[te++]=vt[xe++];while(--pe);T.length===0&&(T.mode=V);break;case K:if(I===0)break e;be[te++]=T.length,I--,T.mode=V;break;case ae:if(T.wrap){for(;ee<32;){if(re===0)break e;re--,z|=oe[p++]<<ee,ee+=8}if(de-=I,Z.total_out+=de,T.total+=de,de&&(Z.adler=T.check=T.flags?o(T.check,be,de,te-de):n(T.check,be,de,te-de)),de=I,(T.flags?z:$e(z))!==T.check){Z.msg="incorrect data check",T.mode=me;break}z=0,ee=0}T.mode=ue;case ue:if(T.wrap&&T.flags){for(;ee<32;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}if(z!==(T.total&4294967295)){Z.msg="incorrect length check",T.mode=me;break}z=0,ee=0}T.mode=ve;case ve:nt=c;break e;case me:nt=y;break e;case we:return g;case Ce:default:return m}return Z.next_out=te,Z.avail_out=I,Z.next_in=p,Z.avail_in=re,T.hold=z,T.bits=ee,(T.wsize||de!==Z.avail_out&&T.mode<me&&(T.mode<ae||ie!==h))&&Oe(Z,Z.output,Z.next_out,de-Z.avail_out),_e-=Z.avail_in,de-=Z.avail_out,Z.total_in+=_e,Z.total_out+=de,T.total+=de,T.wrap&&de&&(Z.adler=T.check=T.flags?o(T.check,be,de,Z.next_out-de):n(T.check,be,de,Z.next_out-de)),Z.data_type=T.bits+(T.last?64:0)+(T.mode===L?128:0)+(T.mode===H||T.mode===P?256:0),(_e===0&&de===0||ie===h)&&nt===d&&(nt=u),nt}function ne(Z){if(!Z||!Z.state)return m;var ie=Z.state;return ie.window&&(ie.window=null),Z.state=null,d}function se(Z,ie){var T;return!Z||!Z.state||(T=Z.state,(T.wrap&2)===0)?m:(T.head=ie,ie.done=!1,d)}function le(Z,ie){var T=ie.length,oe,be,p;return!Z||!Z.state||(oe=Z.state,oe.wrap!==0&&oe.mode!==R)?m:oe.mode===R&&(be=1,be=n(be,ie,T,0),be!==oe.check)?y:(p=Oe(Z,ie,T,T),p?(oe.mode=we,g):(oe.havedict=1,d))}return it.inflateReset=Ne,it.inflateReset2=We,it.inflateResetKeep=qe,it.inflateInit=Q,it.inflateInit2=J,it.inflate=A,it.inflateEnd=ne,it.inflateGetHeader=se,it.inflateSetDictionary=le,it.inflateInfo="pako inflate (from Nodeca project)",it}var Nn,ks;function vm(){return ks||(ks=1,Nn={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}),Nn}function ym(){const{useDynamicConfig:e}=wt(),{configValue:n,isDynamicConfigLoading:o}=e(xt.creditAgentEnablement),i=He.getSignedInUser()?.userEmail;return{isAllowed:fe.useMemo(()=>{const t=Array.isArray(n?.allowedUserEmails)?n.allowedUserEmails:[];return i!=null&&t.includes(i)},[n,i]),isLoading:o}}function St(){const{isAllowed:e}=ym();return e?Sp:Rp}const _m={overlayWidth:new at(100,100,50)};function js(){const e=Fe(),n=Ye(),o=lr(),i=Ft(),a=St(),t=Se(M=>Lf(M)),r=t.uiState.selectedCustomerTenantId,s=fe.useMemo(()=>r?t.customers.find(M=>M.tenantId===r):void 0,[t.customers,r]),h=Se(M=>r?qf(M.aiAccountantCustomerState,M.userState,r):[]),f=t.customerViewStateByTenantId[r],l=f?.jobsFetchStatus??{fetchState:"Not-Started"},d=f?.jobsPageToken!=null;fe.useEffect(()=>{t.fetchState==="Completed"?n(At(!1)):(t.fetchState==="Not-Started"||t.fetchState==="Error")&&n(vs())},[t.fetchState]);const c=M=>{const S=Pt(M),R=Bt(M);Ve.trackCockpitTabClicked(R),e(`../../${S}`,{replace:!0})},b=(M,S,R,L)=>{n(Dt([M.tenantId])),n(nn(S,R,L))},m=(M,S,R)=>{n(nn(M,S,R))},y=(M,S)=>{n(Dt(t.unonboardedTenantIds)),n(nn("retrain",M,S))},g=M=>{const S=t.selectedTenantIds,R=S.includes(M)?S.filter(L=>L!==M):[...S,M];n(Dt(R))},u=M=>{if(M.length===0)return;const S=t.selectedTenantIds,R=new Set(S);if(M.every(q=>R.has(q))){const q=new Set(M);n(Dt(S.filter(G=>!q.has(G))))}else{const q=Array.from(new Set([...S,...M]));n(Dt(q))}},_=()=>{n(Dt([]))},E=M=>{n(Df(M.companyId,M.tenantId))},v=M=>{M==="aiAccountant"&&n(vs())},w=(M,S)=>{n(Jt({sortKey:M,sortOrder:S}))},x=M=>{n(Jt({selectedCustomerTenantId:M.tenantId})),n(on(M.tenantId))},O=()=>{n(Jt({selectedCustomerTenantId:""}))},C=M=>{n(Jt({filterText:M}))},N=(M,S)=>{n(Jt({filters:S}))},W=()=>{r&&n(on(r,!0))};return U.jsxs(U.Fragment,{children:[U.jsx(Op,{headerData:{allTabOptions:a,selectedTabOption:Et("aiAccountant")},headerActions:{onTabChange:c},aiAccountantPageData:{aiAccountantView:t},aiAccountantPageActions:{onAction:b,onBulkAction:m,onCancelOnboarding:E,onClearSelection:_,onCockpitReloadData:v,onColumnSortConfigChanged:w,onCustomerSelected:x,onEvaluateAll:y,onFilterTextChanged:C,onFiltersChange:N,onToggleAllVisible:u,onToggleTenantSelection:g}}),U.jsx(hr,{anchor:"right",open:s!=null,PaperProps:{style:{width:_m.overlayWidth.valuePercentage(o),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:i.colors.black,opacity:.75,cursor:"pointer"}}},onClose:O,children:s!=null&&U.jsx(th,{customer:s,hasMoreJobs:d,jobs:h,jobsFetchStatus:l,onAction:b,onCancelOnboarding:E,onClose:O,onLoadMoreJobs:W})})]})}function bm(){const{tenantId:e=""}=ot(),n=Fe(),o=Ye(),i=Se(c=>sd(c.aiAccountantCustomerState,c.userState)),a=Se(c=>Lf(c)),t=i.find(c=>c.tenantId===e),r=a.customerViewStateByTenantId[e],s=Se(c=>qf(c.aiAccountantCustomerState,c.userState,e));if(fe.useEffect(()=>{o(on(e))},[e,o]),t==null)return null;const h=(c,b,m,y)=>{o(Dt([c.tenantId])),o(nn(b,m,y))},f=c=>{o(Df(c.companyId,c.tenantId))},l=()=>{n("../")},d=()=>{o(on(e,!0))};return U.jsx(th,{customer:t,hasMoreJobs:r?.jobsPageToken!=null,jobs:s,jobsFetchStatus:r?.jobsFetchStatus??{fetchState:"Not-Started"},onAction:h,onCancelOnboarding:f,onClose:l,onLoadMoreJobs:d})}const lh=(e,n)=>{const o=[...e??[]];return o.push(n),o},wm=e=>{const n=[...e??[]];return{poppedPathname:n.pop(),newStack:n}},Em=(e=2)=>{let n="../";for(let o=0;o<e;o++)n=`${n}../`;return n},Pe=({state:e,element:n})=>He.isSignedIn()===!0?U.jsx(U.Fragment,{children:n}):U.jsx(ir,{to:"/signin/auth",replace:!0,state:{...e,message:"...",origin:window.location.pathname}});function Sm(){return U.jsxs(gt,{children:[U.jsx(Te,{path:"/",element:U.jsx(Pe,{element:U.jsx(js,{})})}),U.jsx(Te,{path:"/detail/:tenantId",element:U.jsx(Pe,{element:U.jsx(bm,{})})}),U.jsx(Te,{path:"/*",element:U.jsx(Pe,{element:U.jsx(js,{})})})]})}const Ut=()=>{const[e,n]=sh(),[o,i]=fe.useState(),a=fe.useRef(!1);return fe.useEffect(()=>{if(a.current===!0||!(e.has("thread_id")||e.has("entity_type")||e.has("company_id")))return;const r=Tp(e);r!=null&&i(r);const s=new URLSearchParams(e);s.delete("thread_id"),s.delete("entity_type"),s.delete("company_id"),n(s,{replace:!0}),a.current=!0},[e,n]),o},Rm={overlayWidth:new at(100,100,50)},{common:{strings:Ls}}=fr.getLocalizedStrings();function Om(e,n){return{headerActions:{onTabChange:o=>{const i=Pt(o),a=Bt(o);Ve.trackCockpitTabClicked(a),n.navigate(`../../${i}`,{replace:!0})},filterActions:{onFilterTextChanged:(o,i)=>{e(wr({uiState:{filterText:i}}))},onFiltersChange:(o,i)=>{i.categories!=null&&i.categoryCombinationOperator!=null&&Ve.trackHealthMonitorFiltersApplied({filterSelection:{condition:i.categories.map(a=>a.matchingOperator).join(Ls.comma),logic:i.categoryCombinationOperator,parameter:i.categories.map(a=>a.field).join(Ls.comma)}}),e(wr({uiState:{filters:i}}))}}},healthPageActions:{onRowClick:o=>{e(Mf(o))},onColumnSortConfigChanged:(o,i)=>{e(wr({uiState:{sortKey:o,sortOrder:i}}))},onCockpitReloadData:o=>{o==="healthMonitor"&&e(Nf())},onFiltersChange:o=>{e(wr({uiState:{filters:o}}))}}}}function Tm(e,n){return{healthPageData:{healthView:n.healthView,managementView:n.managementView,mixpanelUrl:n.mixpanelHMUrl}}}const xm=Ge(Tm,Om)(Cp);function Mn({isDrawerOpen:e}){const n=Fe(),o=Ye(),i=Ft(),a=lr(),{companyId:t}=ot(),[r,s]=sh(),[h,f]=fe.useState(!1),l=Ut(),d=St(),c=Se(w=>ud(w)),b=Se(w=>ur(w)),{additionalChurnFactors:m}=Se(w=>cd(w)),{selectedCompanyDetail:y,selectedCompanyId:g,localFormDataAndStatusByCompanyId:u}=c,_=Se(w=>w.companyViewState.zeniUsers.fetchState),E=Se(w=>w.companyHealthMetricConfigViewState);if(fe.useEffect(()=>{const w=x=>x==="Not-Started"||x==="Error";c.fetchState==="Completed"?o(At(!1)):w(c.fetchState)&&(o(Nf()),w(_)&&o(Ct()),w(E.fetchState)&&o(ld()))},[c.fetchState,E.fetchState]),fe.useEffect(()=>{t!=null&&c.fetchState==="Completed"&&r.has("utm_source")===!0&&(o(Mf(t)),y!=null&&(xp(),Ve.trackCockpitHealthMonitorNotificationAlertClicked({companyId:y.companyInfo.companyId,companyName:y.companyInfo.name,churnProbability:y.companyHealthMetric.churnProbabilityPercentage??null}),f(!0),r.delete("utm_source"),s(r)))},[c.fetchState,y?.companyInfo.companyId,y?.companyInfo.name]),He.getSignedInUser()==null)throw Error("Can't access Health Monitor page without signing in...");return U.jsxs(U.Fragment,{children:[e===!0||g!=null&&y!=null?U.jsx(hr,{anchor:"right",open:g!=null,PaperProps:{style:{width:Rm.overlayWidth.valuePercentage(a),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:i.colors.black,opacity:.75,cursor:"pointer"}}},onClose:()=>o(ys()),children:U.jsx(Ip,{roomId:`cockpit_${g}`,autoConnect:!0,children:U.jsx(Ap,{onSaveClick:()=>{g!=null&&o(hd(g))},onSaveChangesToLocalStore:w=>{c.selectedCompanyId!=null&&o(fd({companyId:c.selectedCompanyId,updatedLocalData:w}))},localData:u?.companyHealthMetricLocalData??{netPromoterScore:void 0,externalProductServiceExposure:void 0,additionalChurnFactors:{increasingChurnProbability:[],decreasingChurnProbability:[]}},companyHealthMetricViewSelector:c,onCloseDrawer:()=>o(ys()),analytics:Ve,urlSource:h,additionalChurnFactorsOptions:m})})}):null,U.jsx(xm,{headerData:{allTabOptions:d,selectedTabOption:Et("healthMonitor")},initialOpenThreadRequest:l??void 0,healthView:c,managementView:b,navigate:n,mixpanelHMUrl:pn.mixpanelHMUrl})]})}function Im(){return U.jsxs(gt,{children:[U.jsx(Te,{path:"/companies/:companyId",element:U.jsx(Pe,{element:U.jsx(Mn,{isDrawerOpen:!0})})}),U.jsx(Te,{path:"/",element:U.jsx(Pe,{element:U.jsx(Mn,{})})}),U.jsx(Te,{path:"/*",element:U.jsx(Pe,{element:U.jsx(Mn,{})})})]})}const Am={drawerLeftMargin:new at(0,0,240)};function mr(e){const{isOpen:n,drawerLeftMargin:o,children:i,onClose:a}=e,t=lr(),r=o?.valuePx(t)??Am.drawerLeftMargin.valuePx(t),s=Ft();return U.jsx(hr,{anchor:"right",open:n,PaperProps:{style:{width:`calc(100% - ${r})`}},slotProps:{backdrop:{style:{backgroundColor:s.colors.black,opacity:.8,cursor:"pointer"}}},onClose:a,children:i})}const Cm=({fetchState:e})=>e==="In-Progress"||e==="Not-Started"?U.jsx(Pm,{children:U.jsx(mn,{size:"ExtraLarge",start:!0})}):null,Pm=tt.div`
1
+ const __vite__mapDeps=(i,m=__vite__mapDeps,d=(m.f||(m.f=["assets/CreditAgentRoutes-Rfl_XZgN.js","assets/liveblocks-C75FN-S8.js","assets/sentry-B3Shr2Jp.js","assets/core-zJRmDR0C.js","assets/recharts-BbCfzDSc.js","assets/zeni-epic-state-DvZcg696.js","assets/index-BkuaEqDM.js","assets/mui-k1YoVrai.js","assets/analytics-B-cuNK8P.js","assets/lottie-Bu1dVLzt.js","assets/lexical-DgFeVxHB.js","assets/utils-CBBpikVS.js","assets/index-xQ8260uf.css","assets/analyticsHelper-BiwhWgyJ.js","assets/empty-Dv1mKqcx.js","assets/index-CbweS8FJ.js","assets/url-DcAJmlTB.js","assets/index-D3-0WPfY.js"])))=>i.map(i=>d[i]);
2
+ import{HH as Lf,HI as qf,jP as At,ex as vs,HJ as Dt,eG as nn,ev as Df,HK as Jt,eC as on,HL as sd,HM as ud,HN as ur,HO as cd,il as Nf,jR as Ct,ii as ld,iq as Mf,HP as ys,is as fd,it as hd,HQ as wr,HR as cr,hP as dd,HS as hn,HT as Vo,d3 as pd,fP as $o,fM as sn,fU as Mt,fS as md,HU as Ff,HV as Bf,iH as gd,iE as vd,HW as yd,iS as _d,iN as _s,iK as bd,iz as wd,HX as Ed,ed as Sd,da as Rd,k1 as Uf,HY as Od,be as an,iw as bs,iB as Td,rv as Vf,jQ as dn,HZ as pt,j5 as Go,H_ as xd,k7 as Id,H as et,bk as zo,H$ as Ad,hM as Cd,I0 as Pd,I1 as $f,I2 as kd,q3 as ws,pA as jd,I3 as Ld,pG as xn,I4 as qd,pI as Dd,I5 as Tt,px as Nd,cT as Md,jU as Gf,jV as zf,jT as Ho,jS as Zo,jW as Fd,I6 as Bd,q6 as Ud,I7 as Vd,pP as $d,q0 as Gd,I8 as zd,pT as Hd,I9 as Zd,Ia as Kt,Ib as Yo,Ic as Yd,Id as Wd,oB as Jd,oH as Hf,Ie as Zf,hh as Kd,GJ as Yf,If as Xd,GD as Qd,Ig as ep,Ih as tp,oK as rp,Ii as np,GO as ip,GC as ap,te as Wf,Ij as In,Ik as Jf,Dx as Wo,Dj as op,DA as Kf,Dm as sp,Il as up,Dr as cp,Dd as lp,Dg as fp,Im as hp,DE as dp,Du as pp,bn as mp,bd as gp,In as vp,Io as Gt,Ip as yp,Iq as _p,Ir as bp,iW as Mo,j0 as wp,ba as Xf}from"./zeni-epic-state-DvZcg696.js";import{j as U}from"./liveblocks-C75FN-S8.js";import{a as fe,p as ye,e as Qf,d as eh,g as Ep}from"./sentry-B3Shr2Jp.js";import{s as wt,f as xt,z as He,F as Sp,t as Rp,J as lr,m as Ft,X as Op,Q as Et,a as th,w as at,b as Ve,h as Pt,g as Bt,L as Tp,u as xp,N as Ip,H as Ap,c as pn,K as Cp,D as fr,P as mn,o as Nt,r as Pp,C as kp,U as gn,d as jp,e as Lp,i as An,j as qp,V as rh,E as Dp,k as nh,T as ih,l as Fo,n as Np,p as Mp,q as Fp,v as ah,x as Bp,y as Up,A as Vp,B as $p,G as Gp,I as zp,Z as Hp,R as Zp,_ as Yp,Y as Wp,M as Jp,O as Kp,S as oh}from"./index-BkuaEqDM.js";import{f as Xp}from"./analyticsHelper-BiwhWgyJ.js";import{i as Fe,n as Ye,g as Se,o as ot,N as ir,k as gt,l as Te,p as sh,h as Ge,u as Jo,j as Bo}from"./core-zJRmDR0C.js";import{D as hr,n as tt,S as Ht}from"./mui-k1YoVrai.js";import{a as Ze,b as Qp,c as em,d as tm,e as Ko,f as rm,g as nm,h as im,i as Zt,j as am,k as or,l as vn,m as om,n as dr,o as sm}from"./utils-CBBpikVS.js";import{r as Xo}from"./empty-Dv1mKqcx.js";import{r as pr,a as um}from"./index-CbweS8FJ.js";import{r as cm}from"./index-D3-0WPfY.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]="0710ec83-6617-4170-a172-2b9acccabb24",e._sentryDebugIdIdentifier="sentry-dbid-0710ec83-6617-4170-a172-2b9acccabb24")}catch{}})();var Cn={},Es;function yn(){return Es||(Es=1,function(e){var n=typeof Uint8Array<"u"&&typeof Uint16Array<"u"&&typeof Int32Array<"u";function o(t,r){return Object.prototype.hasOwnProperty.call(t,r)}e.assign=function(t){for(var r=Array.prototype.slice.call(arguments,1);r.length;){var s=r.shift();if(s){if(typeof s!="object")throw new TypeError(s+"must be non-object");for(var h in s)o(s,h)&&(t[h]=s[h])}}return t},e.shrinkBuf=function(t,r){return t.length===r?t:t.subarray?t.subarray(0,r):(t.length=r,t)};var i={arraySet:function(t,r,s,h,f){if(r.subarray&&t.subarray){t.set(r.subarray(s,s+h),f);return}for(var l=0;l<h;l++)t[f+l]=r[s+l]},flattenChunks:function(t){var r,s,h,f,l,d;for(h=0,r=0,s=t.length;r<s;r++)h+=t[r].length;for(d=new Uint8Array(h),f=0,r=0,s=t.length;r<s;r++)l=t[r],d.set(l,f),f+=l.length;return d}},a={arraySet:function(t,r,s,h,f){for(var l=0;l<h;l++)t[f+l]=r[s+l]},flattenChunks:function(t){return[].concat.apply([],t)}};e.setTyped=function(t){t?(e.Buf8=Uint8Array,e.Buf16=Uint16Array,e.Buf32=Int32Array,e.assign(e,i)):(e.Buf8=Array,e.Buf16=Array,e.Buf32=Array,e.assign(e,a))},e.setTyped(n)}(Cn)),Cn}var ut={},kt={},Ss;function lm(){if(Ss)return kt;Ss=1;var e=yn(),n=4,o=0,i=1,a=2;function t(A){for(var ne=A.length;--ne>=0;)A[ne]=0}var r=0,s=1,h=2,f=3,l=258,d=29,c=256,b=c+1+d,m=30,y=19,g=2*b+1,u=15,_=16,E=7,v=256,w=16,x=17,O=18,C=[0,0,0,0,0,0,0,0,1,1,1,1,2,2,2,2,3,3,3,3,4,4,4,4,5,5,5,5,0],N=[0,0,0,0,1,1,2,2,3,3,4,4,5,5,6,6,7,7,8,8,9,9,10,10,11,11,12,12,13,13],W=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,2,3,7],M=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15],S=512,R=new Array((b+2)*2);t(R);var L=new Array(m*2);t(L);var q=new Array(S);t(q);var G=new Array(l-f+1);t(G);var P=new Array(d);t(P);var j=new Array(m);t(j);function k(A,ne,se,le,Z){this.static_tree=A,this.extra_bits=ne,this.extra_base=se,this.elems=le,this.max_length=Z,this.has_stree=A&&A.length}var B,Y,H;function V(A,ne){this.dyn_tree=A,this.max_code=0,this.stat_desc=ne}function D(A){return A<256?q[A]:q[256+(A>>>7)]}function F(A,ne){A.pending_buf[A.pending++]=ne&255,A.pending_buf[A.pending++]=ne>>>8&255}function $(A,ne,se){A.bi_valid>_-se?(A.bi_buf|=ne<<A.bi_valid&65535,F(A,A.bi_buf),A.bi_buf=ne>>_-A.bi_valid,A.bi_valid+=se-_):(A.bi_buf|=ne<<A.bi_valid&65535,A.bi_valid+=se)}function X(A,ne,se){$(A,se[ne*2],se[ne*2+1])}function K(A,ne){var se=0;do se|=A&1,A>>>=1,se<<=1;while(--ne>0);return se>>>1}function ae(A){A.bi_valid===16?(F(A,A.bi_buf),A.bi_buf=0,A.bi_valid=0):A.bi_valid>=8&&(A.pending_buf[A.pending++]=A.bi_buf&255,A.bi_buf>>=8,A.bi_valid-=8)}function ue(A,ne){var se=ne.dyn_tree,le=ne.max_code,Z=ne.stat_desc.static_tree,ie=ne.stat_desc.has_stree,T=ne.stat_desc.extra_bits,oe=ne.stat_desc.extra_base,be=ne.stat_desc.max_length,p,te,re,I,z,ee,_e=0;for(I=0;I<=u;I++)A.bl_count[I]=0;for(se[A.heap[A.heap_max]*2+1]=0,p=A.heap_max+1;p<g;p++)te=A.heap[p],I=se[se[te*2+1]*2+1]+1,I>be&&(I=be,_e++),se[te*2+1]=I,!(te>le)&&(A.bl_count[I]++,z=0,te>=oe&&(z=T[te-oe]),ee=se[te*2],A.opt_len+=ee*(I+z),ie&&(A.static_len+=ee*(Z[te*2+1]+z)));if(_e!==0){do{for(I=be-1;A.bl_count[I]===0;)I--;A.bl_count[I]--,A.bl_count[I+1]+=2,A.bl_count[be]--,_e-=2}while(_e>0);for(I=be;I!==0;I--)for(te=A.bl_count[I];te!==0;)re=A.heap[--p],!(re>le)&&(se[re*2+1]!==I&&(A.opt_len+=(I-se[re*2+1])*se[re*2],se[re*2+1]=I),te--)}}function ve(A,ne,se){var le=new Array(u+1),Z=0,ie,T;for(ie=1;ie<=u;ie++)le[ie]=Z=Z+se[ie-1]<<1;for(T=0;T<=ne;T++){var oe=A[T*2+1];oe!==0&&(A[T*2]=K(le[oe]++,oe))}}function me(){var A,ne,se,le,Z,ie=new Array(u+1);for(se=0,le=0;le<d-1;le++)for(P[le]=se,A=0;A<1<<C[le];A++)G[se++]=le;for(G[se-1]=le,Z=0,le=0;le<16;le++)for(j[le]=Z,A=0;A<1<<N[le];A++)q[Z++]=le;for(Z>>=7;le<m;le++)for(j[le]=Z<<7,A=0;A<1<<N[le]-7;A++)q[256+Z++]=le;for(ne=0;ne<=u;ne++)ie[ne]=0;for(A=0;A<=143;)R[A*2+1]=8,A++,ie[8]++;for(;A<=255;)R[A*2+1]=9,A++,ie[9]++;for(;A<=279;)R[A*2+1]=7,A++,ie[7]++;for(;A<=287;)R[A*2+1]=8,A++,ie[8]++;for(ve(R,b+1,ie),A=0;A<m;A++)L[A*2+1]=5,L[A*2]=K(A,5);B=new k(R,C,c+1,b,u),Y=new k(L,N,0,m,u),H=new k(new Array(0),W,0,y,E)}function we(A){var ne;for(ne=0;ne<b;ne++)A.dyn_ltree[ne*2]=0;for(ne=0;ne<m;ne++)A.dyn_dtree[ne*2]=0;for(ne=0;ne<y;ne++)A.bl_tree[ne*2]=0;A.dyn_ltree[v*2]=1,A.opt_len=A.static_len=0,A.last_lit=A.matches=0}function Ce(A){A.bi_valid>8?F(A,A.bi_buf):A.bi_valid>0&&(A.pending_buf[A.pending++]=A.bi_buf),A.bi_buf=0,A.bi_valid=0}function ke(A,ne,se,le){Ce(A),F(A,se),F(A,~se),e.arraySet(A.pending_buf,A.window,ne,se,A.pending),A.pending+=se}function je(A,ne,se,le){var Z=ne*2,ie=se*2;return A[Z]<A[ie]||A[Z]===A[ie]&&le[ne]<=le[se]}function Ie(A,ne,se){for(var le=A.heap[se],Z=se<<1;Z<=A.heap_len&&(Z<A.heap_len&&je(ne,A.heap[Z+1],A.heap[Z],A.depth)&&Z++,!je(ne,le,A.heap[Z],A.depth));)A.heap[se]=A.heap[Z],se=Z,Z<<=1;A.heap[se]=le}function Ee(A,ne,se){var le,Z,ie=0,T,oe;if(A.last_lit!==0)do le=A.pending_buf[A.d_buf+ie*2]<<8|A.pending_buf[A.d_buf+ie*2+1],Z=A.pending_buf[A.l_buf+ie],ie++,le===0?X(A,Z,ne):(T=G[Z],X(A,T+c+1,ne),oe=C[T],oe!==0&&(Z-=P[T],$(A,Z,oe)),le--,T=D(le),X(A,T,se),oe=N[T],oe!==0&&(le-=j[T],$(A,le,oe)));while(ie<A.last_lit);X(A,v,ne)}function $e(A,ne){var se=ne.dyn_tree,le=ne.stat_desc.static_tree,Z=ne.stat_desc.has_stree,ie=ne.stat_desc.elems,T,oe,be=-1,p;for(A.heap_len=0,A.heap_max=g,T=0;T<ie;T++)se[T*2]!==0?(A.heap[++A.heap_len]=be=T,A.depth[T]=0):se[T*2+1]=0;for(;A.heap_len<2;)p=A.heap[++A.heap_len]=be<2?++be:0,se[p*2]=1,A.depth[p]=0,A.opt_len--,Z&&(A.static_len-=le[p*2+1]);for(ne.max_code=be,T=A.heap_len>>1;T>=1;T--)Ie(A,se,T);p=ie;do T=A.heap[1],A.heap[1]=A.heap[A.heap_len--],Ie(A,se,1),oe=A.heap[1],A.heap[--A.heap_max]=T,A.heap[--A.heap_max]=oe,se[p*2]=se[T*2]+se[oe*2],A.depth[p]=(A.depth[T]>=A.depth[oe]?A.depth[T]:A.depth[oe])+1,se[T*2+1]=se[oe*2+1]=p,A.heap[1]=p++,Ie(A,se,1);while(A.heap_len>=2);A.heap[--A.heap_max]=A.heap[1],ue(A,ne),ve(se,be,A.bl_count)}function st(A,ne,se){var le,Z=-1,ie,T=ne[0*2+1],oe=0,be=7,p=4;for(T===0&&(be=138,p=3),ne[(se+1)*2+1]=65535,le=0;le<=se;le++)ie=T,T=ne[(le+1)*2+1],!(++oe<be&&ie===T)&&(oe<p?A.bl_tree[ie*2]+=oe:ie!==0?(ie!==Z&&A.bl_tree[ie*2]++,A.bl_tree[w*2]++):oe<=10?A.bl_tree[x*2]++:A.bl_tree[O*2]++,oe=0,Z=ie,T===0?(be=138,p=3):ie===T?(be=6,p=3):(be=7,p=4))}function qe(A,ne,se){var le,Z=-1,ie,T=ne[0*2+1],oe=0,be=7,p=4;for(T===0&&(be=138,p=3),le=0;le<=se;le++)if(ie=T,T=ne[(le+1)*2+1],!(++oe<be&&ie===T)){if(oe<p)do X(A,ie,A.bl_tree);while(--oe!==0);else ie!==0?(ie!==Z&&(X(A,ie,A.bl_tree),oe--),X(A,w,A.bl_tree),$(A,oe-3,2)):oe<=10?(X(A,x,A.bl_tree),$(A,oe-3,3)):(X(A,O,A.bl_tree),$(A,oe-11,7));oe=0,Z=ie,T===0?(be=138,p=3):ie===T?(be=6,p=3):(be=7,p=4)}}function Ne(A){var ne;for(st(A,A.dyn_ltree,A.l_desc.max_code),st(A,A.dyn_dtree,A.d_desc.max_code),$e(A,A.bl_desc),ne=y-1;ne>=3&&A.bl_tree[M[ne]*2+1]===0;ne--);return A.opt_len+=3*(ne+1)+5+5+4,ne}function We(A,ne,se,le){var Z;for($(A,ne-257,5),$(A,se-1,5),$(A,le-4,4),Z=0;Z<le;Z++)$(A,A.bl_tree[M[Z]*2+1],3);qe(A,A.dyn_ltree,ne-1),qe(A,A.dyn_dtree,se-1)}function J(A){var ne=4093624447,se;for(se=0;se<=31;se++,ne>>>=1)if(ne&1&&A.dyn_ltree[se*2]!==0)return o;if(A.dyn_ltree[9*2]!==0||A.dyn_ltree[10*2]!==0||A.dyn_ltree[13*2]!==0)return i;for(se=32;se<c;se++)if(A.dyn_ltree[se*2]!==0)return i;return o}var Q=!1;function ce(A){Q||(me(),Q=!0),A.l_desc=new V(A.dyn_ltree,B),A.d_desc=new V(A.dyn_dtree,Y),A.bl_desc=new V(A.bl_tree,H),A.bi_buf=0,A.bi_valid=0,we(A)}function ge(A,ne,se,le){$(A,(r<<1)+(le?1:0),3),ke(A,ne,se)}function he(A){$(A,s<<1,3),X(A,v,R),ae(A)}function Re(A,ne,se,le){var Z,ie,T=0;A.level>0?(A.strm.data_type===a&&(A.strm.data_type=J(A)),$e(A,A.l_desc),$e(A,A.d_desc),T=Ne(A),Z=A.opt_len+3+7>>>3,ie=A.static_len+3+7>>>3,ie<=Z&&(Z=ie)):Z=ie=se+5,se+4<=Z&&ne!==-1?ge(A,ne,se,le):A.strategy===n||ie===Z?($(A,(s<<1)+(le?1:0),3),Ee(A,R,L)):($(A,(h<<1)+(le?1:0),3),We(A,A.l_desc.max_code+1,A.d_desc.max_code+1,T+1),Ee(A,A.dyn_ltree,A.dyn_dtree)),we(A),le&&Ce(A)}function Oe(A,ne,se){return A.pending_buf[A.d_buf+A.last_lit*2]=ne>>>8&255,A.pending_buf[A.d_buf+A.last_lit*2+1]=ne&255,A.pending_buf[A.l_buf+A.last_lit]=se&255,A.last_lit++,ne===0?A.dyn_ltree[se*2]++:(A.matches++,ne--,A.dyn_ltree[(G[se]+c+1)*2]++,A.dyn_dtree[D(ne)*2]++),A.last_lit===A.lit_bufsize-1}return kt._tr_init=ce,kt._tr_stored_block=ge,kt._tr_flush_block=Re,kt._tr_tally=Oe,kt._tr_align=he,kt}var Pn,Rs;function uh(){if(Rs)return Pn;Rs=1;function e(n,o,i,a){for(var t=n&65535|0,r=n>>>16&65535|0,s=0;i!==0;){s=i>2e3?2e3:i,i-=s;do t=t+o[a++]|0,r=r+t|0;while(--s);t%=65521,r%=65521}return t|r<<16|0}return Pn=e,Pn}var kn,Os;function ch(){if(Os)return kn;Os=1;function e(){for(var i,a=[],t=0;t<256;t++){i=t;for(var r=0;r<8;r++)i=i&1?3988292384^i>>>1:i>>>1;a[t]=i}return a}var n=e();function o(i,a,t,r){var s=n,h=r+t;i^=-1;for(var f=r;f<h;f++)i=i>>>8^s[(i^a[f])&255];return i^-1}return kn=o,kn}var jn,Ts;function fm(){return Ts||(Ts=1,jn={2:"need dictionary",1:"stream end",0:"","-1":"file error","-2":"stream error","-3":"data error","-4":"insufficient memory","-5":"buffer error","-6":"incompatible version"}),jn}var xs;function hm(){if(xs)return ut;xs=1;var e=yn(),n=lm(),o=uh(),i=ch(),a=fm(),t=0,r=1,s=3,h=4,f=5,l=0,d=1,c=-2,b=-3,m=-5,y=-1,g=1,u=2,_=3,E=4,v=0,w=2,x=8,O=9,C=15,N=8,W=29,M=256,S=M+1+W,R=30,L=19,q=2*S+1,G=15,P=3,j=258,k=j+P+1,B=32,Y=42,H=69,V=73,D=91,F=103,$=113,X=666,K=1,ae=2,ue=3,ve=4,me=3;function we(p,te){return p.msg=a[te],te}function Ce(p){return(p<<1)-(p>4?9:0)}function ke(p){for(var te=p.length;--te>=0;)p[te]=0}function je(p){var te=p.state,re=te.pending;re>p.avail_out&&(re=p.avail_out),re!==0&&(e.arraySet(p.output,te.pending_buf,te.pending_out,re,p.next_out),p.next_out+=re,te.pending_out+=re,p.total_out+=re,p.avail_out-=re,te.pending-=re,te.pending===0&&(te.pending_out=0))}function Ie(p,te){n._tr_flush_block(p,p.block_start>=0?p.block_start:-1,p.strstart-p.block_start,te),p.block_start=p.strstart,je(p.strm)}function Ee(p,te){p.pending_buf[p.pending++]=te}function $e(p,te){p.pending_buf[p.pending++]=te>>>8&255,p.pending_buf[p.pending++]=te&255}function st(p,te,re,I){var z=p.avail_in;return z>I&&(z=I),z===0?0:(p.avail_in-=z,e.arraySet(te,p.input,p.next_in,z,re),p.state.wrap===1?p.adler=o(p.adler,te,z,re):p.state.wrap===2&&(p.adler=i(p.adler,te,z,re)),p.next_in+=z,p.total_in+=z,z)}function qe(p,te){var re=p.max_chain_length,I=p.strstart,z,ee,_e=p.prev_length,de=p.nice_match,pe=p.strstart>p.w_size-k?p.strstart-(p.w_size-k):0,xe=p.window,vt=p.w_mask,Le=p.prev,Ae=p.strstart+j,Be=xe[I+_e-1],Je=xe[I+_e];p.prev_length>=p.good_match&&(re>>=2),de>p.lookahead&&(de=p.lookahead);do if(z=te,!(xe[z+_e]!==Je||xe[z+_e-1]!==Be||xe[z]!==xe[I]||xe[++z]!==xe[I+1])){I+=2,z++;do;while(xe[++I]===xe[++z]&&xe[++I]===xe[++z]&&xe[++I]===xe[++z]&&xe[++I]===xe[++z]&&xe[++I]===xe[++z]&&xe[++I]===xe[++z]&&xe[++I]===xe[++z]&&xe[++I]===xe[++z]&&I<Ae);if(ee=j-(Ae-I),I=Ae-j,ee>_e){if(p.match_start=te,_e=ee,ee>=de)break;Be=xe[I+_e-1],Je=xe[I+_e]}}while((te=Le[te&vt])>pe&&--re!==0);return _e<=p.lookahead?_e:p.lookahead}function Ne(p){var te=p.w_size,re,I,z,ee,_e;do{if(ee=p.window_size-p.lookahead-p.strstart,p.strstart>=te+(te-k)){e.arraySet(p.window,p.window,te,te,0),p.match_start-=te,p.strstart-=te,p.block_start-=te,I=p.hash_size,re=I;do z=p.head[--re],p.head[re]=z>=te?z-te:0;while(--I);I=te,re=I;do z=p.prev[--re],p.prev[re]=z>=te?z-te:0;while(--I);ee+=te}if(p.strm.avail_in===0)break;if(I=st(p.strm,p.window,p.strstart+p.lookahead,ee),p.lookahead+=I,p.lookahead+p.insert>=P)for(_e=p.strstart-p.insert,p.ins_h=p.window[_e],p.ins_h=(p.ins_h<<p.hash_shift^p.window[_e+1])&p.hash_mask;p.insert&&(p.ins_h=(p.ins_h<<p.hash_shift^p.window[_e+P-1])&p.hash_mask,p.prev[_e&p.w_mask]=p.head[p.ins_h],p.head[p.ins_h]=_e,_e++,p.insert--,!(p.lookahead+p.insert<P)););}while(p.lookahead<k&&p.strm.avail_in!==0)}function We(p,te){var re=65535;for(re>p.pending_buf_size-5&&(re=p.pending_buf_size-5);;){if(p.lookahead<=1){if(Ne(p),p.lookahead===0&&te===t)return K;if(p.lookahead===0)break}p.strstart+=p.lookahead,p.lookahead=0;var I=p.block_start+re;if((p.strstart===0||p.strstart>=I)&&(p.lookahead=p.strstart-I,p.strstart=I,Ie(p,!1),p.strm.avail_out===0)||p.strstart-p.block_start>=p.w_size-k&&(Ie(p,!1),p.strm.avail_out===0))return K}return p.insert=0,te===h?(Ie(p,!0),p.strm.avail_out===0?ue:ve):(p.strstart>p.block_start&&(Ie(p,!1),p.strm.avail_out===0),K)}function J(p,te){for(var re,I;;){if(p.lookahead<k){if(Ne(p),p.lookahead<k&&te===t)return K;if(p.lookahead===0)break}if(re=0,p.lookahead>=P&&(p.ins_h=(p.ins_h<<p.hash_shift^p.window[p.strstart+P-1])&p.hash_mask,re=p.prev[p.strstart&p.w_mask]=p.head[p.ins_h],p.head[p.ins_h]=p.strstart),re!==0&&p.strstart-re<=p.w_size-k&&(p.match_length=qe(p,re)),p.match_length>=P)if(I=n._tr_tally(p,p.strstart-p.match_start,p.match_length-P),p.lookahead-=p.match_length,p.match_length<=p.max_lazy_match&&p.lookahead>=P){p.match_length--;do p.strstart++,p.ins_h=(p.ins_h<<p.hash_shift^p.window[p.strstart+P-1])&p.hash_mask,re=p.prev[p.strstart&p.w_mask]=p.head[p.ins_h],p.head[p.ins_h]=p.strstart;while(--p.match_length!==0);p.strstart++}else p.strstart+=p.match_length,p.match_length=0,p.ins_h=p.window[p.strstart],p.ins_h=(p.ins_h<<p.hash_shift^p.window[p.strstart+1])&p.hash_mask;else I=n._tr_tally(p,0,p.window[p.strstart]),p.lookahead--,p.strstart++;if(I&&(Ie(p,!1),p.strm.avail_out===0))return K}return p.insert=p.strstart<P-1?p.strstart:P-1,te===h?(Ie(p,!0),p.strm.avail_out===0?ue:ve):p.last_lit&&(Ie(p,!1),p.strm.avail_out===0)?K:ae}function Q(p,te){for(var re,I,z;;){if(p.lookahead<k){if(Ne(p),p.lookahead<k&&te===t)return K;if(p.lookahead===0)break}if(re=0,p.lookahead>=P&&(p.ins_h=(p.ins_h<<p.hash_shift^p.window[p.strstart+P-1])&p.hash_mask,re=p.prev[p.strstart&p.w_mask]=p.head[p.ins_h],p.head[p.ins_h]=p.strstart),p.prev_length=p.match_length,p.prev_match=p.match_start,p.match_length=P-1,re!==0&&p.prev_length<p.max_lazy_match&&p.strstart-re<=p.w_size-k&&(p.match_length=qe(p,re),p.match_length<=5&&(p.strategy===g||p.match_length===P&&p.strstart-p.match_start>4096)&&(p.match_length=P-1)),p.prev_length>=P&&p.match_length<=p.prev_length){z=p.strstart+p.lookahead-P,I=n._tr_tally(p,p.strstart-1-p.prev_match,p.prev_length-P),p.lookahead-=p.prev_length-1,p.prev_length-=2;do++p.strstart<=z&&(p.ins_h=(p.ins_h<<p.hash_shift^p.window[p.strstart+P-1])&p.hash_mask,re=p.prev[p.strstart&p.w_mask]=p.head[p.ins_h],p.head[p.ins_h]=p.strstart);while(--p.prev_length!==0);if(p.match_available=0,p.match_length=P-1,p.strstart++,I&&(Ie(p,!1),p.strm.avail_out===0))return K}else if(p.match_available){if(I=n._tr_tally(p,0,p.window[p.strstart-1]),I&&Ie(p,!1),p.strstart++,p.lookahead--,p.strm.avail_out===0)return K}else p.match_available=1,p.strstart++,p.lookahead--}return p.match_available&&(I=n._tr_tally(p,0,p.window[p.strstart-1]),p.match_available=0),p.insert=p.strstart<P-1?p.strstart:P-1,te===h?(Ie(p,!0),p.strm.avail_out===0?ue:ve):p.last_lit&&(Ie(p,!1),p.strm.avail_out===0)?K:ae}function ce(p,te){for(var re,I,z,ee,_e=p.window;;){if(p.lookahead<=j){if(Ne(p),p.lookahead<=j&&te===t)return K;if(p.lookahead===0)break}if(p.match_length=0,p.lookahead>=P&&p.strstart>0&&(z=p.strstart-1,I=_e[z],I===_e[++z]&&I===_e[++z]&&I===_e[++z])){ee=p.strstart+j;do;while(I===_e[++z]&&I===_e[++z]&&I===_e[++z]&&I===_e[++z]&&I===_e[++z]&&I===_e[++z]&&I===_e[++z]&&I===_e[++z]&&z<ee);p.match_length=j-(ee-z),p.match_length>p.lookahead&&(p.match_length=p.lookahead)}if(p.match_length>=P?(re=n._tr_tally(p,1,p.match_length-P),p.lookahead-=p.match_length,p.strstart+=p.match_length,p.match_length=0):(re=n._tr_tally(p,0,p.window[p.strstart]),p.lookahead--,p.strstart++),re&&(Ie(p,!1),p.strm.avail_out===0))return K}return p.insert=0,te===h?(Ie(p,!0),p.strm.avail_out===0?ue:ve):p.last_lit&&(Ie(p,!1),p.strm.avail_out===0)?K:ae}function ge(p,te){for(var re;;){if(p.lookahead===0&&(Ne(p),p.lookahead===0)){if(te===t)return K;break}if(p.match_length=0,re=n._tr_tally(p,0,p.window[p.strstart]),p.lookahead--,p.strstart++,re&&(Ie(p,!1),p.strm.avail_out===0))return K}return p.insert=0,te===h?(Ie(p,!0),p.strm.avail_out===0?ue:ve):p.last_lit&&(Ie(p,!1),p.strm.avail_out===0)?K:ae}function he(p,te,re,I,z){this.good_length=p,this.max_lazy=te,this.nice_length=re,this.max_chain=I,this.func=z}var Re;Re=[new he(0,0,0,0,We),new he(4,4,8,4,J),new he(4,5,16,8,J),new he(4,6,32,32,J),new he(4,4,16,16,Q),new he(8,16,32,32,Q),new he(8,16,128,128,Q),new he(8,32,128,256,Q),new he(32,128,258,1024,Q),new he(32,258,258,4096,Q)];function Oe(p){p.window_size=2*p.w_size,ke(p.head),p.max_lazy_match=Re[p.level].max_lazy,p.good_match=Re[p.level].good_length,p.nice_match=Re[p.level].nice_length,p.max_chain_length=Re[p.level].max_chain,p.strstart=0,p.block_start=0,p.lookahead=0,p.insert=0,p.match_length=p.prev_length=P-1,p.match_available=0,p.ins_h=0}function A(){this.strm=null,this.status=0,this.pending_buf=null,this.pending_buf_size=0,this.pending_out=0,this.pending=0,this.wrap=0,this.gzhead=null,this.gzindex=0,this.method=x,this.last_flush=-1,this.w_size=0,this.w_bits=0,this.w_mask=0,this.window=null,this.window_size=0,this.prev=null,this.head=null,this.ins_h=0,this.hash_size=0,this.hash_bits=0,this.hash_mask=0,this.hash_shift=0,this.block_start=0,this.match_length=0,this.prev_match=0,this.match_available=0,this.strstart=0,this.match_start=0,this.lookahead=0,this.prev_length=0,this.max_chain_length=0,this.max_lazy_match=0,this.level=0,this.strategy=0,this.good_match=0,this.nice_match=0,this.dyn_ltree=new e.Buf16(q*2),this.dyn_dtree=new e.Buf16((2*R+1)*2),this.bl_tree=new e.Buf16((2*L+1)*2),ke(this.dyn_ltree),ke(this.dyn_dtree),ke(this.bl_tree),this.l_desc=null,this.d_desc=null,this.bl_desc=null,this.bl_count=new e.Buf16(G+1),this.heap=new e.Buf16(2*S+1),ke(this.heap),this.heap_len=0,this.heap_max=0,this.depth=new e.Buf16(2*S+1),ke(this.depth),this.l_buf=0,this.lit_bufsize=0,this.last_lit=0,this.d_buf=0,this.opt_len=0,this.static_len=0,this.matches=0,this.insert=0,this.bi_buf=0,this.bi_valid=0}function ne(p){var te;return!p||!p.state?we(p,c):(p.total_in=p.total_out=0,p.data_type=w,te=p.state,te.pending=0,te.pending_out=0,te.wrap<0&&(te.wrap=-te.wrap),te.status=te.wrap?Y:$,p.adler=te.wrap===2?0:1,te.last_flush=t,n._tr_init(te),l)}function se(p){var te=ne(p);return te===l&&Oe(p.state),te}function le(p,te){return!p||!p.state||p.state.wrap!==2?c:(p.state.gzhead=te,l)}function Z(p,te,re,I,z,ee){if(!p)return c;var _e=1;if(te===y&&(te=6),I<0?(_e=0,I=-I):I>15&&(_e=2,I-=16),z<1||z>O||re!==x||I<8||I>15||te<0||te>9||ee<0||ee>E)return we(p,c);I===8&&(I=9);var de=new A;return p.state=de,de.strm=p,de.wrap=_e,de.gzhead=null,de.w_bits=I,de.w_size=1<<de.w_bits,de.w_mask=de.w_size-1,de.hash_bits=z+7,de.hash_size=1<<de.hash_bits,de.hash_mask=de.hash_size-1,de.hash_shift=~~((de.hash_bits+P-1)/P),de.window=new e.Buf8(de.w_size*2),de.head=new e.Buf16(de.hash_size),de.prev=new e.Buf16(de.w_size),de.lit_bufsize=1<<z+6,de.pending_buf_size=de.lit_bufsize*4,de.pending_buf=new e.Buf8(de.pending_buf_size),de.d_buf=1*de.lit_bufsize,de.l_buf=3*de.lit_bufsize,de.level=te,de.strategy=ee,de.method=re,se(p)}function ie(p,te){return Z(p,te,x,C,N,v)}function T(p,te){var re,I,z,ee;if(!p||!p.state||te>f||te<0)return p?we(p,c):c;if(I=p.state,!p.output||!p.input&&p.avail_in!==0||I.status===X&&te!==h)return we(p,p.avail_out===0?m:c);if(I.strm=p,re=I.last_flush,I.last_flush=te,I.status===Y)if(I.wrap===2)p.adler=0,Ee(I,31),Ee(I,139),Ee(I,8),I.gzhead?(Ee(I,(I.gzhead.text?1:0)+(I.gzhead.hcrc?2:0)+(I.gzhead.extra?4:0)+(I.gzhead.name?8:0)+(I.gzhead.comment?16:0)),Ee(I,I.gzhead.time&255),Ee(I,I.gzhead.time>>8&255),Ee(I,I.gzhead.time>>16&255),Ee(I,I.gzhead.time>>24&255),Ee(I,I.level===9?2:I.strategy>=u||I.level<2?4:0),Ee(I,I.gzhead.os&255),I.gzhead.extra&&I.gzhead.extra.length&&(Ee(I,I.gzhead.extra.length&255),Ee(I,I.gzhead.extra.length>>8&255)),I.gzhead.hcrc&&(p.adler=i(p.adler,I.pending_buf,I.pending,0)),I.gzindex=0,I.status=H):(Ee(I,0),Ee(I,0),Ee(I,0),Ee(I,0),Ee(I,0),Ee(I,I.level===9?2:I.strategy>=u||I.level<2?4:0),Ee(I,me),I.status=$);else{var _e=x+(I.w_bits-8<<4)<<8,de=-1;I.strategy>=u||I.level<2?de=0:I.level<6?de=1:I.level===6?de=2:de=3,_e|=de<<6,I.strstart!==0&&(_e|=B),_e+=31-_e%31,I.status=$,$e(I,_e),I.strstart!==0&&($e(I,p.adler>>>16),$e(I,p.adler&65535)),p.adler=1}if(I.status===H)if(I.gzhead.extra){for(z=I.pending;I.gzindex<(I.gzhead.extra.length&65535)&&!(I.pending===I.pending_buf_size&&(I.gzhead.hcrc&&I.pending>z&&(p.adler=i(p.adler,I.pending_buf,I.pending-z,z)),je(p),z=I.pending,I.pending===I.pending_buf_size));)Ee(I,I.gzhead.extra[I.gzindex]&255),I.gzindex++;I.gzhead.hcrc&&I.pending>z&&(p.adler=i(p.adler,I.pending_buf,I.pending-z,z)),I.gzindex===I.gzhead.extra.length&&(I.gzindex=0,I.status=V)}else I.status=V;if(I.status===V)if(I.gzhead.name){z=I.pending;do{if(I.pending===I.pending_buf_size&&(I.gzhead.hcrc&&I.pending>z&&(p.adler=i(p.adler,I.pending_buf,I.pending-z,z)),je(p),z=I.pending,I.pending===I.pending_buf_size)){ee=1;break}I.gzindex<I.gzhead.name.length?ee=I.gzhead.name.charCodeAt(I.gzindex++)&255:ee=0,Ee(I,ee)}while(ee!==0);I.gzhead.hcrc&&I.pending>z&&(p.adler=i(p.adler,I.pending_buf,I.pending-z,z)),ee===0&&(I.gzindex=0,I.status=D)}else I.status=D;if(I.status===D)if(I.gzhead.comment){z=I.pending;do{if(I.pending===I.pending_buf_size&&(I.gzhead.hcrc&&I.pending>z&&(p.adler=i(p.adler,I.pending_buf,I.pending-z,z)),je(p),z=I.pending,I.pending===I.pending_buf_size)){ee=1;break}I.gzindex<I.gzhead.comment.length?ee=I.gzhead.comment.charCodeAt(I.gzindex++)&255:ee=0,Ee(I,ee)}while(ee!==0);I.gzhead.hcrc&&I.pending>z&&(p.adler=i(p.adler,I.pending_buf,I.pending-z,z)),ee===0&&(I.status=F)}else I.status=F;if(I.status===F&&(I.gzhead.hcrc?(I.pending+2>I.pending_buf_size&&je(p),I.pending+2<=I.pending_buf_size&&(Ee(I,p.adler&255),Ee(I,p.adler>>8&255),p.adler=0,I.status=$)):I.status=$),I.pending!==0){if(je(p),p.avail_out===0)return I.last_flush=-1,l}else if(p.avail_in===0&&Ce(te)<=Ce(re)&&te!==h)return we(p,m);if(I.status===X&&p.avail_in!==0)return we(p,m);if(p.avail_in!==0||I.lookahead!==0||te!==t&&I.status!==X){var pe=I.strategy===u?ge(I,te):I.strategy===_?ce(I,te):Re[I.level].func(I,te);if((pe===ue||pe===ve)&&(I.status=X),pe===K||pe===ue)return p.avail_out===0&&(I.last_flush=-1),l;if(pe===ae&&(te===r?n._tr_align(I):te!==f&&(n._tr_stored_block(I,0,0,!1),te===s&&(ke(I.head),I.lookahead===0&&(I.strstart=0,I.block_start=0,I.insert=0))),je(p),p.avail_out===0))return I.last_flush=-1,l}return te!==h?l:I.wrap<=0?d:(I.wrap===2?(Ee(I,p.adler&255),Ee(I,p.adler>>8&255),Ee(I,p.adler>>16&255),Ee(I,p.adler>>24&255),Ee(I,p.total_in&255),Ee(I,p.total_in>>8&255),Ee(I,p.total_in>>16&255),Ee(I,p.total_in>>24&255)):($e(I,p.adler>>>16),$e(I,p.adler&65535)),je(p),I.wrap>0&&(I.wrap=-I.wrap),I.pending!==0?l:d)}function oe(p){var te;return!p||!p.state?c:(te=p.state.status,te!==Y&&te!==H&&te!==V&&te!==D&&te!==F&&te!==$&&te!==X?we(p,c):(p.state=null,te===$?we(p,b):l))}function be(p,te){var re=te.length,I,z,ee,_e,de,pe,xe,vt;if(!p||!p.state||(I=p.state,_e=I.wrap,_e===2||_e===1&&I.status!==Y||I.lookahead))return c;for(_e===1&&(p.adler=o(p.adler,te,re,0)),I.wrap=0,re>=I.w_size&&(_e===0&&(ke(I.head),I.strstart=0,I.block_start=0,I.insert=0),vt=new e.Buf8(I.w_size),e.arraySet(vt,te,re-I.w_size,I.w_size,0),te=vt,re=I.w_size),de=p.avail_in,pe=p.next_in,xe=p.input,p.avail_in=re,p.next_in=0,p.input=te,Ne(I);I.lookahead>=P;){z=I.strstart,ee=I.lookahead-(P-1);do I.ins_h=(I.ins_h<<I.hash_shift^I.window[z+P-1])&I.hash_mask,I.prev[z&I.w_mask]=I.head[I.ins_h],I.head[I.ins_h]=z,z++;while(--ee);I.strstart=z,I.lookahead=P-1,Ne(I)}return I.strstart+=I.lookahead,I.block_start=I.strstart,I.insert=I.lookahead,I.lookahead=0,I.match_length=I.prev_length=P-1,I.match_available=0,p.next_in=pe,p.input=xe,p.avail_in=de,I.wrap=_e,l}return ut.deflateInit=ie,ut.deflateInit2=Z,ut.deflateReset=se,ut.deflateResetKeep=ne,ut.deflateSetHeader=le,ut.deflate=T,ut.deflateEnd=oe,ut.deflateSetDictionary=be,ut.deflateInfo="pako deflate (from Nodeca project)",ut}var Ln,Is;function dm(){if(Is)return Ln;Is=1;function e(){this.input=null,this.next_in=0,this.avail_in=0,this.total_in=0,this.output=null,this.next_out=0,this.avail_out=0,this.total_out=0,this.msg="",this.state=null,this.data_type=2,this.adler=0}return Ln=e,Ln}var it={},qn,As;function pm(){if(As)return qn;As=1;var e=30,n=12;return qn=function(i,a){var t,r,s,h,f,l,d,c,b,m,y,g,u,_,E,v,w,x,O,C,N,W,M,S,R;t=i.state,r=i.next_in,S=i.input,s=r+(i.avail_in-5),h=i.next_out,R=i.output,f=h-(a-i.avail_out),l=h+(i.avail_out-257),d=t.dmax,c=t.wsize,b=t.whave,m=t.wnext,y=t.window,g=t.hold,u=t.bits,_=t.lencode,E=t.distcode,v=(1<<t.lenbits)-1,w=(1<<t.distbits)-1;e:do{u<15&&(g+=S[r++]<<u,u+=8,g+=S[r++]<<u,u+=8),x=_[g&v];t:for(;;){if(O=x>>>24,g>>>=O,u-=O,O=x>>>16&255,O===0)R[h++]=x&65535;else if(O&16){C=x&65535,O&=15,O&&(u<O&&(g+=S[r++]<<u,u+=8),C+=g&(1<<O)-1,g>>>=O,u-=O),u<15&&(g+=S[r++]<<u,u+=8,g+=S[r++]<<u,u+=8),x=E[g&w];r:for(;;){if(O=x>>>24,g>>>=O,u-=O,O=x>>>16&255,O&16){if(N=x&65535,O&=15,u<O&&(g+=S[r++]<<u,u+=8,u<O&&(g+=S[r++]<<u,u+=8)),N+=g&(1<<O)-1,N>d){i.msg="invalid distance too far back",t.mode=e;break e}if(g>>>=O,u-=O,O=h-f,N>O){if(O=N-O,O>b&&t.sane){i.msg="invalid distance too far back",t.mode=e;break e}if(W=0,M=y,m===0){if(W+=c-O,O<C){C-=O;do R[h++]=y[W++];while(--O);W=h-N,M=R}}else if(m<O){if(W+=c+m-O,O-=m,O<C){C-=O;do R[h++]=y[W++];while(--O);if(W=0,m<C){O=m,C-=O;do R[h++]=y[W++];while(--O);W=h-N,M=R}}}else if(W+=m-O,O<C){C-=O;do R[h++]=y[W++];while(--O);W=h-N,M=R}for(;C>2;)R[h++]=M[W++],R[h++]=M[W++],R[h++]=M[W++],C-=3;C&&(R[h++]=M[W++],C>1&&(R[h++]=M[W++]))}else{W=h-N;do R[h++]=R[W++],R[h++]=R[W++],R[h++]=R[W++],C-=3;while(C>2);C&&(R[h++]=R[W++],C>1&&(R[h++]=R[W++]))}}else if((O&64)===0){x=E[(x&65535)+(g&(1<<O)-1)];continue r}else{i.msg="invalid distance code",t.mode=e;break e}break}}else if((O&64)===0){x=_[(x&65535)+(g&(1<<O)-1)];continue t}else if(O&32){t.mode=n;break e}else{i.msg="invalid literal/length code",t.mode=e;break e}break}}while(r<s&&h<l);C=u>>3,r-=C,u-=C<<3,g&=(1<<u)-1,i.next_in=r,i.next_out=h,i.avail_in=r<s?5+(s-r):5-(r-s),i.avail_out=h<l?257+(l-h):257-(h-l),t.hold=g,t.bits=u},qn}var Dn,Cs;function mm(){if(Cs)return Dn;Cs=1;var e=yn(),n=15,o=852,i=592,a=0,t=1,r=2,s=[3,4,5,6,7,8,9,10,11,13,15,17,19,23,27,31,35,43,51,59,67,83,99,115,131,163,195,227,258,0,0],h=[16,16,16,16,16,16,16,16,17,17,17,17,18,18,18,18,19,19,19,19,20,20,20,20,21,21,21,21,16,72,78],f=[1,2,3,4,5,7,9,13,17,25,33,49,65,97,129,193,257,385,513,769,1025,1537,2049,3073,4097,6145,8193,12289,16385,24577,0,0],l=[16,16,16,16,17,17,18,18,19,19,20,20,21,21,22,22,23,23,24,24,25,25,26,26,27,27,28,28,29,29,64,64];return Dn=function(c,b,m,y,g,u,_,E){var v=E.bits,w=0,x=0,O=0,C=0,N=0,W=0,M=0,S=0,R=0,L=0,q,G,P,j,k,B=null,Y=0,H,V=new e.Buf16(n+1),D=new e.Buf16(n+1),F=null,$=0,X,K,ae;for(w=0;w<=n;w++)V[w]=0;for(x=0;x<y;x++)V[b[m+x]]++;for(N=v,C=n;C>=1&&V[C]===0;C--);if(N>C&&(N=C),C===0)return g[u++]=1<<24|64<<16|0,g[u++]=1<<24|64<<16|0,E.bits=1,0;for(O=1;O<C&&V[O]===0;O++);for(N<O&&(N=O),S=1,w=1;w<=n;w++)if(S<<=1,S-=V[w],S<0)return-1;if(S>0&&(c===a||C!==1))return-1;for(D[1]=0,w=1;w<n;w++)D[w+1]=D[w]+V[w];for(x=0;x<y;x++)b[m+x]!==0&&(_[D[b[m+x]]++]=x);if(c===a?(B=F=_,H=19):c===t?(B=s,Y-=257,F=h,$-=257,H=256):(B=f,F=l,H=-1),L=0,x=0,w=O,k=u,W=N,M=0,P=-1,R=1<<N,j=R-1,c===t&&R>o||c===r&&R>i)return 1;for(;;){X=w-M,_[x]<H?(K=0,ae=_[x]):_[x]>H?(K=F[$+_[x]],ae=B[Y+_[x]]):(K=96,ae=0),q=1<<w-M,G=1<<W,O=G;do G-=q,g[k+(L>>M)+G]=X<<24|K<<16|ae|0;while(G!==0);for(q=1<<w-1;L&q;)q>>=1;if(q!==0?(L&=q-1,L+=q):L=0,x++,--V[w]===0){if(w===C)break;w=b[m+_[x]]}if(w>N&&(L&j)!==P){for(M===0&&(M=N),k+=O,W=w-M,S=1<<W;W+M<C&&(S-=V[W+M],!(S<=0));)W++,S<<=1;if(R+=1<<W,c===t&&R>o||c===r&&R>i)return 1;P=L&j,g[P]=N<<24|W<<16|k-u|0}}return L!==0&&(g[k+L]=w-M<<24|64<<16|0),E.bits=N,0},Dn}var Ps;function gm(){if(Ps)return it;Ps=1;var e=yn(),n=uh(),o=ch(),i=pm(),a=mm(),t=0,r=1,s=2,h=4,f=5,l=6,d=0,c=1,b=2,m=-2,y=-3,g=-4,u=-5,_=8,E=1,v=2,w=3,x=4,O=5,C=6,N=7,W=8,M=9,S=10,R=11,L=12,q=13,G=14,P=15,j=16,k=17,B=18,Y=19,H=20,V=21,D=22,F=23,$=24,X=25,K=26,ae=27,ue=28,ve=29,me=30,we=31,Ce=32,ke=852,je=592,Ie=15,Ee=Ie;function $e(Z){return(Z>>>24&255)+(Z>>>8&65280)+((Z&65280)<<8)+((Z&255)<<24)}function st(){this.mode=0,this.last=!1,this.wrap=0,this.havedict=!1,this.flags=0,this.dmax=0,this.check=0,this.total=0,this.head=null,this.wbits=0,this.wsize=0,this.whave=0,this.wnext=0,this.window=null,this.hold=0,this.bits=0,this.length=0,this.offset=0,this.extra=0,this.lencode=null,this.distcode=null,this.lenbits=0,this.distbits=0,this.ncode=0,this.nlen=0,this.ndist=0,this.have=0,this.next=null,this.lens=new e.Buf16(320),this.work=new e.Buf16(288),this.lendyn=null,this.distdyn=null,this.sane=0,this.back=0,this.was=0}function qe(Z){var ie;return!Z||!Z.state?m:(ie=Z.state,Z.total_in=Z.total_out=ie.total=0,Z.msg="",ie.wrap&&(Z.adler=ie.wrap&1),ie.mode=E,ie.last=0,ie.havedict=0,ie.dmax=32768,ie.head=null,ie.hold=0,ie.bits=0,ie.lencode=ie.lendyn=new e.Buf32(ke),ie.distcode=ie.distdyn=new e.Buf32(je),ie.sane=1,ie.back=-1,d)}function Ne(Z){var ie;return!Z||!Z.state?m:(ie=Z.state,ie.wsize=0,ie.whave=0,ie.wnext=0,qe(Z))}function We(Z,ie){var T,oe;return!Z||!Z.state||(oe=Z.state,ie<0?(T=0,ie=-ie):(T=(ie>>4)+1,ie<48&&(ie&=15)),ie&&(ie<8||ie>15))?m:(oe.window!==null&&oe.wbits!==ie&&(oe.window=null),oe.wrap=T,oe.wbits=ie,Ne(Z))}function J(Z,ie){var T,oe;return Z?(oe=new st,Z.state=oe,oe.window=null,T=We(Z,ie),T!==d&&(Z.state=null),T):m}function Q(Z){return J(Z,Ee)}var ce=!0,ge,he;function Re(Z){if(ce){var ie;for(ge=new e.Buf32(512),he=new e.Buf32(32),ie=0;ie<144;)Z.lens[ie++]=8;for(;ie<256;)Z.lens[ie++]=9;for(;ie<280;)Z.lens[ie++]=7;for(;ie<288;)Z.lens[ie++]=8;for(a(r,Z.lens,0,288,ge,0,Z.work,{bits:9}),ie=0;ie<32;)Z.lens[ie++]=5;a(s,Z.lens,0,32,he,0,Z.work,{bits:5}),ce=!1}Z.lencode=ge,Z.lenbits=9,Z.distcode=he,Z.distbits=5}function Oe(Z,ie,T,oe){var be,p=Z.state;return p.window===null&&(p.wsize=1<<p.wbits,p.wnext=0,p.whave=0,p.window=new e.Buf8(p.wsize)),oe>=p.wsize?(e.arraySet(p.window,ie,T-p.wsize,p.wsize,0),p.wnext=0,p.whave=p.wsize):(be=p.wsize-p.wnext,be>oe&&(be=oe),e.arraySet(p.window,ie,T-oe,be,p.wnext),oe-=be,oe?(e.arraySet(p.window,ie,T-oe,oe,0),p.wnext=oe,p.whave=p.wsize):(p.wnext+=be,p.wnext===p.wsize&&(p.wnext=0),p.whave<p.wsize&&(p.whave+=be))),0}function A(Z,ie){var T,oe,be,p,te,re,I,z,ee,_e,de,pe,xe,vt,Le=0,Ae,Be,Je,Xe,_r,br,Me,nt,ze=new e.Buf8(4),yt,ht,gs=[16,17,18,0,8,7,9,6,10,5,11,4,12,3,13,2,14,1,15];if(!Z||!Z.state||!Z.output||!Z.input&&Z.avail_in!==0)return m;T=Z.state,T.mode===L&&(T.mode=q),te=Z.next_out,be=Z.output,I=Z.avail_out,p=Z.next_in,oe=Z.input,re=Z.avail_in,z=T.hold,ee=T.bits,_e=re,de=I,nt=d;e:for(;;)switch(T.mode){case E:if(T.wrap===0){T.mode=q;break}for(;ee<16;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}if(T.wrap&2&&z===35615){T.check=0,ze[0]=z&255,ze[1]=z>>>8&255,T.check=o(T.check,ze,2,0),z=0,ee=0,T.mode=v;break}if(T.flags=0,T.head&&(T.head.done=!1),!(T.wrap&1)||(((z&255)<<8)+(z>>8))%31){Z.msg="incorrect header check",T.mode=me;break}if((z&15)!==_){Z.msg="unknown compression method",T.mode=me;break}if(z>>>=4,ee-=4,Me=(z&15)+8,T.wbits===0)T.wbits=Me;else if(Me>T.wbits){Z.msg="invalid window size",T.mode=me;break}T.dmax=1<<Me,Z.adler=T.check=1,T.mode=z&512?S:L,z=0,ee=0;break;case v:for(;ee<16;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}if(T.flags=z,(T.flags&255)!==_){Z.msg="unknown compression method",T.mode=me;break}if(T.flags&57344){Z.msg="unknown header flags set",T.mode=me;break}T.head&&(T.head.text=z>>8&1),T.flags&512&&(ze[0]=z&255,ze[1]=z>>>8&255,T.check=o(T.check,ze,2,0)),z=0,ee=0,T.mode=w;case w:for(;ee<32;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}T.head&&(T.head.time=z),T.flags&512&&(ze[0]=z&255,ze[1]=z>>>8&255,ze[2]=z>>>16&255,ze[3]=z>>>24&255,T.check=o(T.check,ze,4,0)),z=0,ee=0,T.mode=x;case x:for(;ee<16;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}T.head&&(T.head.xflags=z&255,T.head.os=z>>8),T.flags&512&&(ze[0]=z&255,ze[1]=z>>>8&255,T.check=o(T.check,ze,2,0)),z=0,ee=0,T.mode=O;case O:if(T.flags&1024){for(;ee<16;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}T.length=z,T.head&&(T.head.extra_len=z),T.flags&512&&(ze[0]=z&255,ze[1]=z>>>8&255,T.check=o(T.check,ze,2,0)),z=0,ee=0}else T.head&&(T.head.extra=null);T.mode=C;case C:if(T.flags&1024&&(pe=T.length,pe>re&&(pe=re),pe&&(T.head&&(Me=T.head.extra_len-T.length,T.head.extra||(T.head.extra=new Array(T.head.extra_len)),e.arraySet(T.head.extra,oe,p,pe,Me)),T.flags&512&&(T.check=o(T.check,oe,pe,p)),re-=pe,p+=pe,T.length-=pe),T.length))break e;T.length=0,T.mode=N;case N:if(T.flags&2048){if(re===0)break e;pe=0;do Me=oe[p+pe++],T.head&&Me&&T.length<65536&&(T.head.name+=String.fromCharCode(Me));while(Me&&pe<re);if(T.flags&512&&(T.check=o(T.check,oe,pe,p)),re-=pe,p+=pe,Me)break e}else T.head&&(T.head.name=null);T.length=0,T.mode=W;case W:if(T.flags&4096){if(re===0)break e;pe=0;do Me=oe[p+pe++],T.head&&Me&&T.length<65536&&(T.head.comment+=String.fromCharCode(Me));while(Me&&pe<re);if(T.flags&512&&(T.check=o(T.check,oe,pe,p)),re-=pe,p+=pe,Me)break e}else T.head&&(T.head.comment=null);T.mode=M;case M:if(T.flags&512){for(;ee<16;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}if(z!==(T.check&65535)){Z.msg="header crc mismatch",T.mode=me;break}z=0,ee=0}T.head&&(T.head.hcrc=T.flags>>9&1,T.head.done=!0),Z.adler=T.check=0,T.mode=L;break;case S:for(;ee<32;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}Z.adler=T.check=$e(z),z=0,ee=0,T.mode=R;case R:if(T.havedict===0)return Z.next_out=te,Z.avail_out=I,Z.next_in=p,Z.avail_in=re,T.hold=z,T.bits=ee,b;Z.adler=T.check=1,T.mode=L;case L:if(ie===f||ie===l)break e;case q:if(T.last){z>>>=ee&7,ee-=ee&7,T.mode=ae;break}for(;ee<3;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}switch(T.last=z&1,z>>>=1,ee-=1,z&3){case 0:T.mode=G;break;case 1:if(Re(T),T.mode=H,ie===l){z>>>=2,ee-=2;break e}break;case 2:T.mode=k;break;case 3:Z.msg="invalid block type",T.mode=me}z>>>=2,ee-=2;break;case G:for(z>>>=ee&7,ee-=ee&7;ee<32;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}if((z&65535)!==(z>>>16^65535)){Z.msg="invalid stored block lengths",T.mode=me;break}if(T.length=z&65535,z=0,ee=0,T.mode=P,ie===l)break e;case P:T.mode=j;case j:if(pe=T.length,pe){if(pe>re&&(pe=re),pe>I&&(pe=I),pe===0)break e;e.arraySet(be,oe,p,pe,te),re-=pe,p+=pe,I-=pe,te+=pe,T.length-=pe;break}T.mode=L;break;case k:for(;ee<14;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}if(T.nlen=(z&31)+257,z>>>=5,ee-=5,T.ndist=(z&31)+1,z>>>=5,ee-=5,T.ncode=(z&15)+4,z>>>=4,ee-=4,T.nlen>286||T.ndist>30){Z.msg="too many length or distance symbols",T.mode=me;break}T.have=0,T.mode=B;case B:for(;T.have<T.ncode;){for(;ee<3;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}T.lens[gs[T.have++]]=z&7,z>>>=3,ee-=3}for(;T.have<19;)T.lens[gs[T.have++]]=0;if(T.lencode=T.lendyn,T.lenbits=7,yt={bits:T.lenbits},nt=a(t,T.lens,0,19,T.lencode,0,T.work,yt),T.lenbits=yt.bits,nt){Z.msg="invalid code lengths set",T.mode=me;break}T.have=0,T.mode=Y;case Y:for(;T.have<T.nlen+T.ndist;){for(;Le=T.lencode[z&(1<<T.lenbits)-1],Ae=Le>>>24,Be=Le>>>16&255,Je=Le&65535,!(Ae<=ee);){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}if(Je<16)z>>>=Ae,ee-=Ae,T.lens[T.have++]=Je;else{if(Je===16){for(ht=Ae+2;ee<ht;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}if(z>>>=Ae,ee-=Ae,T.have===0){Z.msg="invalid bit length repeat",T.mode=me;break}Me=T.lens[T.have-1],pe=3+(z&3),z>>>=2,ee-=2}else if(Je===17){for(ht=Ae+3;ee<ht;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}z>>>=Ae,ee-=Ae,Me=0,pe=3+(z&7),z>>>=3,ee-=3}else{for(ht=Ae+7;ee<ht;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}z>>>=Ae,ee-=Ae,Me=0,pe=11+(z&127),z>>>=7,ee-=7}if(T.have+pe>T.nlen+T.ndist){Z.msg="invalid bit length repeat",T.mode=me;break}for(;pe--;)T.lens[T.have++]=Me}}if(T.mode===me)break;if(T.lens[256]===0){Z.msg="invalid code -- missing end-of-block",T.mode=me;break}if(T.lenbits=9,yt={bits:T.lenbits},nt=a(r,T.lens,0,T.nlen,T.lencode,0,T.work,yt),T.lenbits=yt.bits,nt){Z.msg="invalid literal/lengths set",T.mode=me;break}if(T.distbits=6,T.distcode=T.distdyn,yt={bits:T.distbits},nt=a(s,T.lens,T.nlen,T.ndist,T.distcode,0,T.work,yt),T.distbits=yt.bits,nt){Z.msg="invalid distances set",T.mode=me;break}if(T.mode=H,ie===l)break e;case H:T.mode=V;case V:if(re>=6&&I>=258){Z.next_out=te,Z.avail_out=I,Z.next_in=p,Z.avail_in=re,T.hold=z,T.bits=ee,i(Z,de),te=Z.next_out,be=Z.output,I=Z.avail_out,p=Z.next_in,oe=Z.input,re=Z.avail_in,z=T.hold,ee=T.bits,T.mode===L&&(T.back=-1);break}for(T.back=0;Le=T.lencode[z&(1<<T.lenbits)-1],Ae=Le>>>24,Be=Le>>>16&255,Je=Le&65535,!(Ae<=ee);){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}if(Be&&(Be&240)===0){for(Xe=Ae,_r=Be,br=Je;Le=T.lencode[br+((z&(1<<Xe+_r)-1)>>Xe)],Ae=Le>>>24,Be=Le>>>16&255,Je=Le&65535,!(Xe+Ae<=ee);){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}z>>>=Xe,ee-=Xe,T.back+=Xe}if(z>>>=Ae,ee-=Ae,T.back+=Ae,T.length=Je,Be===0){T.mode=K;break}if(Be&32){T.back=-1,T.mode=L;break}if(Be&64){Z.msg="invalid literal/length code",T.mode=me;break}T.extra=Be&15,T.mode=D;case D:if(T.extra){for(ht=T.extra;ee<ht;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}T.length+=z&(1<<T.extra)-1,z>>>=T.extra,ee-=T.extra,T.back+=T.extra}T.was=T.length,T.mode=F;case F:for(;Le=T.distcode[z&(1<<T.distbits)-1],Ae=Le>>>24,Be=Le>>>16&255,Je=Le&65535,!(Ae<=ee);){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}if((Be&240)===0){for(Xe=Ae,_r=Be,br=Je;Le=T.distcode[br+((z&(1<<Xe+_r)-1)>>Xe)],Ae=Le>>>24,Be=Le>>>16&255,Je=Le&65535,!(Xe+Ae<=ee);){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}z>>>=Xe,ee-=Xe,T.back+=Xe}if(z>>>=Ae,ee-=Ae,T.back+=Ae,Be&64){Z.msg="invalid distance code",T.mode=me;break}T.offset=Je,T.extra=Be&15,T.mode=$;case $:if(T.extra){for(ht=T.extra;ee<ht;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}T.offset+=z&(1<<T.extra)-1,z>>>=T.extra,ee-=T.extra,T.back+=T.extra}if(T.offset>T.dmax){Z.msg="invalid distance too far back",T.mode=me;break}T.mode=X;case X:if(I===0)break e;if(pe=de-I,T.offset>pe){if(pe=T.offset-pe,pe>T.whave&&T.sane){Z.msg="invalid distance too far back",T.mode=me;break}pe>T.wnext?(pe-=T.wnext,xe=T.wsize-pe):xe=T.wnext-pe,pe>T.length&&(pe=T.length),vt=T.window}else vt=be,xe=te-T.offset,pe=T.length;pe>I&&(pe=I),I-=pe,T.length-=pe;do be[te++]=vt[xe++];while(--pe);T.length===0&&(T.mode=V);break;case K:if(I===0)break e;be[te++]=T.length,I--,T.mode=V;break;case ae:if(T.wrap){for(;ee<32;){if(re===0)break e;re--,z|=oe[p++]<<ee,ee+=8}if(de-=I,Z.total_out+=de,T.total+=de,de&&(Z.adler=T.check=T.flags?o(T.check,be,de,te-de):n(T.check,be,de,te-de)),de=I,(T.flags?z:$e(z))!==T.check){Z.msg="incorrect data check",T.mode=me;break}z=0,ee=0}T.mode=ue;case ue:if(T.wrap&&T.flags){for(;ee<32;){if(re===0)break e;re--,z+=oe[p++]<<ee,ee+=8}if(z!==(T.total&4294967295)){Z.msg="incorrect length check",T.mode=me;break}z=0,ee=0}T.mode=ve;case ve:nt=c;break e;case me:nt=y;break e;case we:return g;case Ce:default:return m}return Z.next_out=te,Z.avail_out=I,Z.next_in=p,Z.avail_in=re,T.hold=z,T.bits=ee,(T.wsize||de!==Z.avail_out&&T.mode<me&&(T.mode<ae||ie!==h))&&Oe(Z,Z.output,Z.next_out,de-Z.avail_out),_e-=Z.avail_in,de-=Z.avail_out,Z.total_in+=_e,Z.total_out+=de,T.total+=de,T.wrap&&de&&(Z.adler=T.check=T.flags?o(T.check,be,de,Z.next_out-de):n(T.check,be,de,Z.next_out-de)),Z.data_type=T.bits+(T.last?64:0)+(T.mode===L?128:0)+(T.mode===H||T.mode===P?256:0),(_e===0&&de===0||ie===h)&&nt===d&&(nt=u),nt}function ne(Z){if(!Z||!Z.state)return m;var ie=Z.state;return ie.window&&(ie.window=null),Z.state=null,d}function se(Z,ie){var T;return!Z||!Z.state||(T=Z.state,(T.wrap&2)===0)?m:(T.head=ie,ie.done=!1,d)}function le(Z,ie){var T=ie.length,oe,be,p;return!Z||!Z.state||(oe=Z.state,oe.wrap!==0&&oe.mode!==R)?m:oe.mode===R&&(be=1,be=n(be,ie,T,0),be!==oe.check)?y:(p=Oe(Z,ie,T,T),p?(oe.mode=we,g):(oe.havedict=1,d))}return it.inflateReset=Ne,it.inflateReset2=We,it.inflateResetKeep=qe,it.inflateInit=Q,it.inflateInit2=J,it.inflate=A,it.inflateEnd=ne,it.inflateGetHeader=se,it.inflateSetDictionary=le,it.inflateInfo="pako inflate (from Nodeca project)",it}var Nn,ks;function vm(){return ks||(ks=1,Nn={Z_NO_FLUSH:0,Z_PARTIAL_FLUSH:1,Z_SYNC_FLUSH:2,Z_FULL_FLUSH:3,Z_FINISH:4,Z_BLOCK:5,Z_TREES:6,Z_OK:0,Z_STREAM_END:1,Z_NEED_DICT:2,Z_ERRNO:-1,Z_STREAM_ERROR:-2,Z_DATA_ERROR:-3,Z_BUF_ERROR:-5,Z_NO_COMPRESSION:0,Z_BEST_SPEED:1,Z_BEST_COMPRESSION:9,Z_DEFAULT_COMPRESSION:-1,Z_FILTERED:1,Z_HUFFMAN_ONLY:2,Z_RLE:3,Z_FIXED:4,Z_DEFAULT_STRATEGY:0,Z_BINARY:0,Z_TEXT:1,Z_UNKNOWN:2,Z_DEFLATED:8}),Nn}function ym(){const{useDynamicConfig:e}=wt(),{configValue:n,isDynamicConfigLoading:o}=e(xt.creditAgentEnablement),i=He.getSignedInUser()?.userEmail;return{isAllowed:fe.useMemo(()=>{const t=Array.isArray(n?.allowedUserEmails)?n.allowedUserEmails:[];return i!=null&&t.includes(i)},[n,i]),isLoading:o}}function St(){const{isAllowed:e}=ym();return e?Sp:Rp}const _m={overlayWidth:new at(100,100,50)};function js(){const e=Fe(),n=Ye(),o=lr(),i=Ft(),a=St(),t=Se(M=>Lf(M)),r=t.uiState.selectedCustomerTenantId,s=fe.useMemo(()=>r?t.customers.find(M=>M.tenantId===r):void 0,[t.customers,r]),h=Se(M=>r?qf(M.aiAccountantCustomerState,M.userState,r):[]),f=t.customerViewStateByTenantId[r],l=f?.jobsFetchStatus??{fetchState:"Not-Started"},d=f?.jobsPageToken!=null;fe.useEffect(()=>{t.fetchState==="Completed"?n(At(!1)):(t.fetchState==="Not-Started"||t.fetchState==="Error")&&n(vs())},[t.fetchState]);const c=M=>{const S=Pt(M),R=Bt(M);Ve.trackCockpitTabClicked(R),e(`../../${S}`,{replace:!0})},b=(M,S,R,L)=>{n(Dt([M.tenantId])),n(nn(S,R,L))},m=(M,S,R)=>{n(nn(M,S,R))},y=(M,S)=>{n(Dt(t.unonboardedTenantIds)),n(nn("retrain",M,S))},g=M=>{const S=t.selectedTenantIds,R=S.includes(M)?S.filter(L=>L!==M):[...S,M];n(Dt(R))},u=M=>{if(M.length===0)return;const S=t.selectedTenantIds,R=new Set(S);if(M.every(q=>R.has(q))){const q=new Set(M);n(Dt(S.filter(G=>!q.has(G))))}else{const q=Array.from(new Set([...S,...M]));n(Dt(q))}},_=()=>{n(Dt([]))},E=M=>{n(Df(M.companyId,M.tenantId))},v=M=>{M==="aiAccountant"&&n(vs())},w=(M,S)=>{n(Jt({sortKey:M,sortOrder:S}))},x=M=>{n(Jt({selectedCustomerTenantId:M.tenantId})),n(on(M.tenantId))},O=()=>{n(Jt({selectedCustomerTenantId:""}))},C=M=>{n(Jt({filterText:M}))},N=(M,S)=>{n(Jt({filters:S}))},W=()=>{r&&n(on(r,!0))};return U.jsxs(U.Fragment,{children:[U.jsx(Op,{headerData:{allTabOptions:a,selectedTabOption:Et("aiAccountant")},headerActions:{onTabChange:c},aiAccountantPageData:{aiAccountantView:t},aiAccountantPageActions:{onAction:b,onBulkAction:m,onCancelOnboarding:E,onClearSelection:_,onCockpitReloadData:v,onColumnSortConfigChanged:w,onCustomerSelected:x,onEvaluateAll:y,onFilterTextChanged:C,onFiltersChange:N,onToggleAllVisible:u,onToggleTenantSelection:g}}),U.jsx(hr,{anchor:"right",open:s!=null,PaperProps:{style:{width:_m.overlayWidth.valuePercentage(o),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:i.colors.black,opacity:.75,cursor:"pointer"}}},onClose:O,children:s!=null&&U.jsx(th,{customer:s,hasMoreJobs:d,jobs:h,jobsFetchStatus:l,onAction:b,onCancelOnboarding:E,onClose:O,onLoadMoreJobs:W})})]})}function bm(){const{tenantId:e=""}=ot(),n=Fe(),o=Ye(),i=Se(c=>sd(c.aiAccountantCustomerState,c.userState)),a=Se(c=>Lf(c)),t=i.find(c=>c.tenantId===e),r=a.customerViewStateByTenantId[e],s=Se(c=>qf(c.aiAccountantCustomerState,c.userState,e));if(fe.useEffect(()=>{o(on(e))},[e,o]),t==null)return null;const h=(c,b,m,y)=>{o(Dt([c.tenantId])),o(nn(b,m,y))},f=c=>{o(Df(c.companyId,c.tenantId))},l=()=>{n("../")},d=()=>{o(on(e,!0))};return U.jsx(th,{customer:t,hasMoreJobs:r?.jobsPageToken!=null,jobs:s,jobsFetchStatus:r?.jobsFetchStatus??{fetchState:"Not-Started"},onAction:h,onCancelOnboarding:f,onClose:l,onLoadMoreJobs:d})}const lh=(e,n)=>{const o=[...e??[]];return o.push(n),o},wm=e=>{const n=[...e??[]];return{poppedPathname:n.pop(),newStack:n}},Em=(e=2)=>{let n="../";for(let o=0;o<e;o++)n=`${n}../`;return n},Pe=({state:e,element:n})=>He.isSignedIn()===!0?U.jsx(U.Fragment,{children:n}):U.jsx(ir,{to:"/signin/auth",replace:!0,state:{...e,message:"...",origin:window.location.pathname}});function Sm(){return U.jsxs(gt,{children:[U.jsx(Te,{path:"/",element:U.jsx(Pe,{element:U.jsx(js,{})})}),U.jsx(Te,{path:"/detail/:tenantId",element:U.jsx(Pe,{element:U.jsx(bm,{})})}),U.jsx(Te,{path:"/*",element:U.jsx(Pe,{element:U.jsx(js,{})})})]})}const Ut=()=>{const[e,n]=sh(),[o,i]=fe.useState(),a=fe.useRef(!1);return fe.useEffect(()=>{if(a.current===!0||!(e.has("thread_id")||e.has("entity_type")||e.has("company_id")))return;const r=Tp(e);r!=null&&i(r);const s=new URLSearchParams(e);s.delete("thread_id"),s.delete("entity_type"),s.delete("company_id"),n(s,{replace:!0}),a.current=!0},[e,n]),o},Rm={overlayWidth:new at(100,100,50)},{common:{strings:Ls}}=fr.getLocalizedStrings();function Om(e,n){return{headerActions:{onTabChange:o=>{const i=Pt(o),a=Bt(o);Ve.trackCockpitTabClicked(a),n.navigate(`../../${i}`,{replace:!0})},filterActions:{onFilterTextChanged:(o,i)=>{e(wr({uiState:{filterText:i}}))},onFiltersChange:(o,i)=>{i.categories!=null&&i.categoryCombinationOperator!=null&&Ve.trackHealthMonitorFiltersApplied({filterSelection:{condition:i.categories.map(a=>a.matchingOperator).join(Ls.comma),logic:i.categoryCombinationOperator,parameter:i.categories.map(a=>a.field).join(Ls.comma)}}),e(wr({uiState:{filters:i}}))}}},healthPageActions:{onRowClick:o=>{e(Mf(o))},onColumnSortConfigChanged:(o,i)=>{e(wr({uiState:{sortKey:o,sortOrder:i}}))},onCockpitReloadData:o=>{o==="healthMonitor"&&e(Nf())},onFiltersChange:o=>{e(wr({uiState:{filters:o}}))}}}}function Tm(e,n){return{healthPageData:{healthView:n.healthView,managementView:n.managementView,mixpanelUrl:n.mixpanelHMUrl}}}const xm=Ge(Tm,Om)(Cp);function Mn({isDrawerOpen:e}){const n=Fe(),o=Ye(),i=Ft(),a=lr(),{companyId:t}=ot(),[r,s]=sh(),[h,f]=fe.useState(!1),l=Ut(),d=St(),c=Se(w=>ud(w)),b=Se(w=>ur(w)),{additionalChurnFactors:m}=Se(w=>cd(w)),{selectedCompanyDetail:y,selectedCompanyId:g,localFormDataAndStatusByCompanyId:u}=c,_=Se(w=>w.companyViewState.zeniUsers.fetchState),E=Se(w=>w.companyHealthMetricConfigViewState);if(fe.useEffect(()=>{const w=x=>x==="Not-Started"||x==="Error";c.fetchState==="Completed"?o(At(!1)):w(c.fetchState)&&(o(Nf()),w(_)&&o(Ct()),w(E.fetchState)&&o(ld()))},[c.fetchState,E.fetchState]),fe.useEffect(()=>{t!=null&&c.fetchState==="Completed"&&r.has("utm_source")===!0&&(o(Mf(t)),y!=null&&(xp(),Ve.trackCockpitHealthMonitorNotificationAlertClicked({companyId:y.companyInfo.companyId,companyName:y.companyInfo.name,churnProbability:y.companyHealthMetric.churnProbabilityPercentage??null}),f(!0),r.delete("utm_source"),s(r)))},[c.fetchState,y?.companyInfo.companyId,y?.companyInfo.name]),He.getSignedInUser()==null)throw Error("Can't access Health Monitor page without signing in...");return U.jsxs(U.Fragment,{children:[e===!0||g!=null&&y!=null?U.jsx(hr,{anchor:"right",open:g!=null,PaperProps:{style:{width:Rm.overlayWidth.valuePercentage(a),boxShadow:"none"}},slotProps:{backdrop:{style:{backgroundColor:i.colors.black,opacity:.75,cursor:"pointer"}}},onClose:()=>o(ys()),children:U.jsx(Ip,{roomId:`cockpit_${g}`,autoConnect:!0,children:U.jsx(Ap,{onSaveClick:()=>{g!=null&&o(hd(g))},onSaveChangesToLocalStore:w=>{c.selectedCompanyId!=null&&o(fd({companyId:c.selectedCompanyId,updatedLocalData:w}))},localData:u?.companyHealthMetricLocalData??{netPromoterScore:void 0,externalProductServiceExposure:void 0,additionalChurnFactors:{increasingChurnProbability:[],decreasingChurnProbability:[]}},companyHealthMetricViewSelector:c,onCloseDrawer:()=>o(ys()),analytics:Ve,urlSource:h,additionalChurnFactorsOptions:m})})}):null,U.jsx(xm,{headerData:{allTabOptions:d,selectedTabOption:Et("healthMonitor")},initialOpenThreadRequest:l??void 0,healthView:c,managementView:b,navigate:n,mixpanelHMUrl:pn.mixpanelHMUrl})]})}function Im(){return U.jsxs(gt,{children:[U.jsx(Te,{path:"/companies/:companyId",element:U.jsx(Pe,{element:U.jsx(Mn,{isDrawerOpen:!0})})}),U.jsx(Te,{path:"/",element:U.jsx(Pe,{element:U.jsx(Mn,{})})}),U.jsx(Te,{path:"/*",element:U.jsx(Pe,{element:U.jsx(Mn,{})})})]})}const Am={drawerLeftMargin:new at(0,0,240)};function mr(e){const{isOpen:n,drawerLeftMargin:o,children:i,onClose:a}=e,t=lr(),r=o?.valuePx(t)??Am.drawerLeftMargin.valuePx(t),s=Ft();return U.jsx(hr,{anchor:"right",open:n,PaperProps:{style:{width:`calc(100% - ${r})`}},slotProps:{backdrop:{style:{backgroundColor:s.colors.black,opacity:.8,cursor:"pointer"}}},onClose:a,children:i})}const Cm=({fetchState:e})=>e==="In-Progress"||e==="Not-Started"?U.jsx(Pm,{children:U.jsx(mn,{size:"ExtraLarge",start:!0})}):null,Pm=tt.div`
3
3
  display: flex;
4
4
  width: 100%;
5
5
  height: 100%;
@@ -177,4 +177,4 @@ Found: ${o.toString().split(`
177
177
  `;function C_(){return U.jsxs(gt,{children:[U.jsx(Te,{path:"/report/:companyId",element:U.jsx(Pe,{element:U.jsx(Do,{})})}),U.jsx(Te,{path:"/warnings/:companyId",element:U.jsx(Pe,{element:U.jsx(Do,{})})}),U.jsx(Te,{path:"/*",element:U.jsx(Pe,{element:U.jsx(Do,{})})})]})}function P_(e,n){const o=Jf(e,n.tenantId),i=o.estimateStatus?.fetchState!=="In-Progress"?void 0:"readonly";return{localData:o,isDisabled:i}}function k_(e,n){const{tenantId:o,companyId:i,location:a,navigate:t}=n;return{onSubscriptionDetailsChanged:r=>{const{addPlan:s,invoiceOption:h}=r,{subscriptionPlan:f,recurringAddOns:l,coupon:d}=s,c={subscriptionPlanId:f.selectedOption??"",subscriptionAddOnIds:l.filter(b=>b.selectedOption!=null).map(b=>b.selectedOption),subscriptionCouponIds:d.selectedOption!=null?[d.selectedOption]:[],invoiceImmediately:h.invoicingOption!=null};s.planStartDate!=null&&(c.startDate=an(s.planStartDate.toString())),e(Kf({tenantId:o,subscriptionData:c}))},onEstimateSuccess:()=>{const r=lh(a.state?.pathnameStackToGoBack,a.pathname);t(`../tenants/${o}/companies/${i}/summary`,{state:{pathnameStackToGoBack:r}})},onReviewClick:()=>{e(op(o))},onBackClick:()=>{t(`../tenants/${o}/companies/${i}`)},onResetClick:()=>{e(Wo(o))}}}const j_=Ge(P_,k_)(Hp),L_=e=>{const{tenantId:n,companyId:o,location:i,navigate:a}=e;return U.jsx(j_,{tenantId:n,companyId:o,location:i,navigate:a})};function q_(e,n){const{companyId:o,tenantId:i}=n,a=up(e,o,i),t=a.fetchState!=="In-Progress";return{subscriptionDetailView:a,canUpdate:t}}function D_(e,n){const{tenantId:o,location:i,navigate:a}=n;return{onUpdateOrAddPlanClick:t=>{e(Wo(o,t)),e(cp()),e(lp()),e(fp()),t!=null?a(`${i.pathname}/update`):a(`${i.pathname}/add`)},onCloseClick:()=>{a("../")}}}const N_=Ge(q_,D_)(Zp),M_=e=>{const{tenantId:n,companyId:o,location:i,navigate:a}=e,t=Ye(),[r,s]=fe.useState(!1),h=Se(f=>f.subscriptionViewState.subscriptionDetailsByCompanyId[o]?.fetchStatus);return fe.useEffect(()=>{!r&&(h==null||h?.fetchState==="Not-Started")&&(s(!0),t(sp(o)))},[r,h,o,t]),fe.useEffect(()=>{r&&h!=null&&h?.fetchState==="Error"&&a("../subscription")},[r,h]),U.jsx(N_,{tenantId:n,companyId:o,location:i,navigate:a})};function F_(e,n){return{subscriptionEstimateData:hp(e,n.tenantId)}}function B_(e,n){const{tenantId:o,companyId:i,location:a,navigate:t}=n,r=()=>{const s=wm(a.state?.pathnameStackToGoBack),h=s.poppedPathname??Em(1);t(h,{state:{pathnameStackToGoBack:s.newStack}})};return{onBackClick:()=>{r()},onCancelClick:()=>{r()},onConfirmClick:()=>{e(dp(o))},onConfirmSuccess:()=>{t(`../tenants/${o}/companies/${i}`)}}}const U_=Ge(F_,B_)(Yp),V_=e=>{const{tenantId:n,companyId:o,location:i,navigate:a}=e;return U.jsx(U_,{companyId:o,tenantId:n,location:i,navigate:a})};function $_(e,n){const o=Jf(e,n.tenantId),i=o.estimateStatus.fetchState!=="In-Progress"?void 0:"readonly";return{localData:o,isDisabled:i}}function G_(e,n){const{tenantId:o,companyId:i,location:a,navigate:t}=n;return{onSubscriptionDetailsChanged:r=>{const{updatePlan:s,applyChanges:h}=r,{subscriptionPlan:f,recurringAddOns:l,coupon:d}=s,c={subscriptionPlanId:f.selectedOption??"",subscriptionAddOnIds:l.filter(b=>b.selectedOption!=null).map(b=>b.selectedOption),subscriptionCouponIds:d.selectedOption!=null?[d.selectedOption]:[],invoiceImmediately:!0,applyEndOfTerm:h.changeType==="applyEndOfTerm",shouldProrate:h.shouldProrate};e(Kf({tenantId:o,subscriptionData:c}))},onEstimateSuccess:()=>{const r=lh(a.state?.pathnameStackToGoBack,a.pathname);t(`../tenants/${o}/companies/${i}/summary`,{state:{pathnameStackToGoBack:r}})},onReviewClick:()=>{e(pp(o))},onBackClick:()=>{t(`../tenants/${o}/companies/${i}`)},onResetClick:r=>{e(Wo(o,r.subscription.subscription.subscriptionId))}}}const z_=Ge($_,G_)(Wp),H_=e=>{const{tenantId:n,companyId:o,location:i,navigate:a}=e;return U.jsx(z_,{tenantId:n,companyId:o,location:i,navigate:a})},od=["add","update","summary"],Z_=e=>gp(e,od),Y_=e=>mp(e,od),W_=()=>{const[e,n]=fe.useState(!0),{tenantId:o,companyId:i,updatePageType:a}=ot(),t=Fe(),r=Se(h=>o!=null?h.subscriptionViewState.subscriptionUpdateViewDataByTenantId[o]:null);if(He.getSignedInUser()==null)throw Error("Can't access subscription details drawer without signing in...");return fe.useEffect(()=>{(r==null&&a!=null||Y_(a??"")==null)&&t(`../tenants/${o}/companies/${i}`)},[r]),U.jsx(mr,{isOpen:e,onClose:()=>{n(!1),t("../subscription")},children:U.jsx(K_,{children:U.jsx(J_,{tenantId:o,companyId:i,updatePageType:a!=null?Z_(a):void 0})})})},J_=({tenantId:e,companyId:n,updatePageType:o})=>{const i=Fe(),a=Jo(),t={tenantId:e,companyId:n,navigate:i,location:a};if(o==null)return U.jsx(M_,{...t});switch(o){case"update":return U.jsx(H_,{...t});case"add":return U.jsx(L_,{...t});case"summary":return U.jsx(V_,{...t});default:return console.error("Subscription Update Page - Invalid Url"),U.jsx(ir,{to:"/",replace:!0})}},K_=tt(Ht)`
178
178
  display: flex;
179
179
  min-height: 100%;
180
- `;function X_(e,n){return{headerActions:{onTabChange:o=>{const i=Pt(o),a=Bt(o);Ve.trackCockpitTabClicked(a),n.navigate(`../../${i}`,{replace:!0})},filterActions:{onFilterTextChanged:(o,i)=>{e(Gt({filterText:i}))},onFiltersChange:(o,i)=>{e(Gt({filters:i}))}}},subscriptionPageActions:{onColumnSortConfigChanged:(o,i)=>{e(Gt({sortKey:o,sortOrder:i}))},onCollapseToggled:(o,i)=>{e(Gt({isRowCollapseToggled:{companyId:o,isCollapsed:i}}))},onScroll:o=>{e(Gt({scrollYOffset:o}))},changeHandlers:(o,i)=>{const a=tb(i);Object.keys(a).length>0&&e(Go(o,a))},onCompanyNameClicked:o=>window.open(`/${o.company.company.companyInfo.primaryEmailDomain}/dashboard`),onPassportIconClicked:o=>window.open(`/${o.company.company.companyInfo.primaryEmailDomain}/dashboard/company_details`),onPlanOrAddOnClicked:(o,i)=>{e(yp({tenantId:i})),n.navigate(`../tenants/${i}/companies/${o}`)},onFiltersChange:(o,i)=>{e(Gt({filters:i}))},onCockpitReloadData:o=>{o==="subscription"&&e(Zo())}}}}function Q_(e,n){return{subscriptionPageData:{loggedInUser:n.signedInUser,subscriptionView:n.subscriptionView}}}const eb=Ge(Q_,X_)(Jp);function No({isDrawerOpen:e}){const n=Fe(),o=Ye(),i=Ut(),a=St(),t=Se(h=>vp(h)),r=Se(h=>h.companyViewState.zeniUsers.fetchState);fe.useEffect(()=>{t.fetchState==="Completed"?o(At(!1)):(t.fetchState==="Not-Started"||t.fetchState==="Error")&&(o(Zo()),(r==="Not-Started"||r==="Error")&&o(Ct()))},[t.fetchState]);const s=He.getSignedInUser();return U.jsxs(U.Fragment,{children:[e===!0?U.jsx(W_,{}):null,U.jsx(eb,{headerData:{allTabOptions:a,selectedTabOption:Et("subscription")},initialOpenThreadRequest:i??void 0,signedInUser:s,subscriptionView:t,navigate:n})]})}const tb=e=>{const{users:n}=e;return n?{users:n}:{}};function rb(){return U.jsxs(gt,{children:[U.jsx(Te,{path:"/tenants/:tenantId/companies/:companyId",element:U.jsx(Pe,{element:U.jsx(No,{isDrawerOpen:!0})})}),U.jsx(Te,{path:"/tenants/:tenantId/companies/:companyId/:updatePageType",element:U.jsx(Pe,{element:U.jsx(No,{isDrawerOpen:!0})})}),U.jsx(Te,{path:"/*",element:U.jsx(Pe,{element:U.jsx(No,{})})})]})}function nb(e,n){const{navigate:o}=n;return{headerActions:{onTabChange:i=>{const a=Pt(i);o(`../../${a}`,{replace:!0})}},taskManagerPageActions:{onRowClick:(i,a)=>{window.open(`/${i}/tasks/${a}`)},onCockpitReloadData:i=>{i==="taskManager"&&e(Mo(null,"dueDate","descending",!1))},onFetchTaskManagerView:(i,a,t,r,s)=>{e(Mo(i,a,t,r,s))}}}}function ib(e,n){return{isBirdsEyeViewEnabled:n.isBirdsEyeViewEnabled,taskManagerPageData:{companyTaskManagerView:n.companyTaskManagerView}}}const ab=Ge(ib,nb)(Kp);function kf(){const e=Fe(),n=Ye(),o=Ut(),i=St(),{useFeatureGate:a}=wt(),{isFeatureEnabled:t}=a(gn.isBirdsEyeViewEnabled),r=Se(l=>_p(l)),s=Se(l=>bp(l)),h=Se(l=>l.companyViewState.zeniUsers.fetchState);if(fe.useEffect(()=>{r.fetchState==="Completed"?n(At(!1)):(r.fetchState==="Not-Started"||r.fetchState==="Error")&&(n(Mo(null,"dueDate","descending",!1)),(h==="Not-Started"||h==="Error")&&n(Ct()))},[r.fetchState]),fe.useEffect(()=>{t&&(r.metricsFetchState==="Not-Started"||r.metricsFetchState==="Error")&&n(wp())},[t,r.metricsFetchState]),He.getSignedInUser()==null)throw Error("Can't access task manager page without signing in...");return U.jsx(ab,{headerData:{allTabOptions:i,selectedTabOption:Et("taskManager")},companyTaskManagerView:r,isBirdsEyeViewEnabled:t,initialOpenThreadRequest:o,navigate:e,reviewCount:s})}function ob(){return U.jsxs(gt,{children:[U.jsx(Te,{path:"/",element:U.jsx(Pe,{element:U.jsx(kf,{})})}),U.jsx(Te,{path:"/*",element:U.jsx(Pe,{element:U.jsx(kf,{})})})]})}const sb=oh(()=>Xf(()=>import("./CreditAgentRoutes-CWKjlOLH.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17])));let jf=!1;const ub=oh(()=>Xf(()=>Promise.resolve().then(()=>Ym),void 0));function cb(){const e=He.getSignedInUser(),n=Ft().mode;return fe.useEffect(()=>{He.isSignedIn()&&!jf&&e!=null&&(Xp(e,n),jf=!0)},[e]),U.jsxs(gt,{children:[U.jsx(Te,{path:"/ai-accountant/*",element:U.jsx(Sm,{})}),U.jsx(Te,{path:"/management/*",element:U.jsx(tg,{})}),U.jsx(Te,{path:"/subscription/*",element:U.jsx(rb,{})}),U.jsx(Te,{path:"/onboarding/*",element:U.jsx(o_,{})}),U.jsx(Te,{path:"/portfolio/*",element:U.jsx(l_,{})}),U.jsx(Te,{path:"/audit/*",element:U.jsx(C_,{})}),U.jsx(Te,{path:"/reconciliation/*",element:U.jsx(b_,{})}),U.jsx(Te,{path:"/health-monitor/*",element:U.jsx(Im,{})}),U.jsx(Te,{path:"/task-manager/*",element:U.jsx(ob,{})}),U.jsx(Te,{path:"/credit-agent/*",element:U.jsx(sb,{})}),U.jsx(Te,{path:"/*",element:U.jsx(ub,{})})]})}const wb=Object.freeze(Object.defineProperty({__proto__:null,default:cb},Symbol.toStringTag,{value:"Module"}));export{Pe as P,wb as S,ym as u};
180
+ `;function X_(e,n){return{headerActions:{onTabChange:o=>{const i=Pt(o),a=Bt(o);Ve.trackCockpitTabClicked(a),n.navigate(`../../${i}`,{replace:!0})},filterActions:{onFilterTextChanged:(o,i)=>{e(Gt({filterText:i}))},onFiltersChange:(o,i)=>{e(Gt({filters:i}))}}},subscriptionPageActions:{onColumnSortConfigChanged:(o,i)=>{e(Gt({sortKey:o,sortOrder:i}))},onCollapseToggled:(o,i)=>{e(Gt({isRowCollapseToggled:{companyId:o,isCollapsed:i}}))},onScroll:o=>{e(Gt({scrollYOffset:o}))},changeHandlers:(o,i)=>{const a=tb(i);Object.keys(a).length>0&&e(Go(o,a))},onCompanyNameClicked:o=>window.open(`/${o.company.company.companyInfo.primaryEmailDomain}/dashboard`),onPassportIconClicked:o=>window.open(`/${o.company.company.companyInfo.primaryEmailDomain}/dashboard/company_details`),onPlanOrAddOnClicked:(o,i)=>{e(yp({tenantId:i})),n.navigate(`../tenants/${i}/companies/${o}`)},onFiltersChange:(o,i)=>{e(Gt({filters:i}))},onCockpitReloadData:o=>{o==="subscription"&&e(Zo())}}}}function Q_(e,n){return{subscriptionPageData:{loggedInUser:n.signedInUser,subscriptionView:n.subscriptionView}}}const eb=Ge(Q_,X_)(Jp);function No({isDrawerOpen:e}){const n=Fe(),o=Ye(),i=Ut(),a=St(),t=Se(h=>vp(h)),r=Se(h=>h.companyViewState.zeniUsers.fetchState);fe.useEffect(()=>{t.fetchState==="Completed"?o(At(!1)):(t.fetchState==="Not-Started"||t.fetchState==="Error")&&(o(Zo()),(r==="Not-Started"||r==="Error")&&o(Ct()))},[t.fetchState]);const s=He.getSignedInUser();return U.jsxs(U.Fragment,{children:[e===!0?U.jsx(W_,{}):null,U.jsx(eb,{headerData:{allTabOptions:a,selectedTabOption:Et("subscription")},initialOpenThreadRequest:i??void 0,signedInUser:s,subscriptionView:t,navigate:n})]})}const tb=e=>{const{users:n}=e;return n?{users:n}:{}};function rb(){return U.jsxs(gt,{children:[U.jsx(Te,{path:"/tenants/:tenantId/companies/:companyId",element:U.jsx(Pe,{element:U.jsx(No,{isDrawerOpen:!0})})}),U.jsx(Te,{path:"/tenants/:tenantId/companies/:companyId/:updatePageType",element:U.jsx(Pe,{element:U.jsx(No,{isDrawerOpen:!0})})}),U.jsx(Te,{path:"/*",element:U.jsx(Pe,{element:U.jsx(No,{})})})]})}function nb(e,n){const{navigate:o}=n;return{headerActions:{onTabChange:i=>{const a=Pt(i);o(`../../${a}`,{replace:!0})}},taskManagerPageActions:{onRowClick:(i,a)=>{window.open(`/${i}/tasks/${a}`)},onCockpitReloadData:i=>{i==="taskManager"&&e(Mo(null,"dueDate","descending",!1))},onFetchTaskManagerView:(i,a,t,r,s)=>{e(Mo(i,a,t,r,s))}}}}function ib(e,n){return{isBirdsEyeViewEnabled:n.isBirdsEyeViewEnabled,taskManagerPageData:{companyTaskManagerView:n.companyTaskManagerView}}}const ab=Ge(ib,nb)(Kp);function kf(){const e=Fe(),n=Ye(),o=Ut(),i=St(),{useFeatureGate:a}=wt(),{isFeatureEnabled:t}=a(gn.isBirdsEyeViewEnabled),r=Se(l=>_p(l)),s=Se(l=>bp(l)),h=Se(l=>l.companyViewState.zeniUsers.fetchState);if(fe.useEffect(()=>{r.fetchState==="Completed"?n(At(!1)):(r.fetchState==="Not-Started"||r.fetchState==="Error")&&(n(Mo(null,"dueDate","descending",!1)),(h==="Not-Started"||h==="Error")&&n(Ct()))},[r.fetchState]),fe.useEffect(()=>{t&&(r.metricsFetchState==="Not-Started"||r.metricsFetchState==="Error")&&n(wp())},[t,r.metricsFetchState]),He.getSignedInUser()==null)throw Error("Can't access task manager page without signing in...");return U.jsx(ab,{headerData:{allTabOptions:i,selectedTabOption:Et("taskManager")},companyTaskManagerView:r,isBirdsEyeViewEnabled:t,initialOpenThreadRequest:o,navigate:e,reviewCount:s})}function ob(){return U.jsxs(gt,{children:[U.jsx(Te,{path:"/",element:U.jsx(Pe,{element:U.jsx(kf,{})})}),U.jsx(Te,{path:"/*",element:U.jsx(Pe,{element:U.jsx(kf,{})})})]})}const sb=oh(()=>Xf(()=>import("./CreditAgentRoutes-Rfl_XZgN.js"),__vite__mapDeps([0,1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17])));let jf=!1;const ub=oh(()=>Xf(()=>Promise.resolve().then(()=>Ym),void 0));function cb(){const e=He.getSignedInUser(),n=Ft().mode;return fe.useEffect(()=>{He.isSignedIn()&&!jf&&e!=null&&(Xp(e,n),jf=!0)},[e]),U.jsxs(gt,{children:[U.jsx(Te,{path:"/ai-accountant/*",element:U.jsx(Sm,{})}),U.jsx(Te,{path:"/management/*",element:U.jsx(tg,{})}),U.jsx(Te,{path:"/subscription/*",element:U.jsx(rb,{})}),U.jsx(Te,{path:"/onboarding/*",element:U.jsx(o_,{})}),U.jsx(Te,{path:"/portfolio/*",element:U.jsx(l_,{})}),U.jsx(Te,{path:"/audit/*",element:U.jsx(C_,{})}),U.jsx(Te,{path:"/reconciliation/*",element:U.jsx(b_,{})}),U.jsx(Te,{path:"/health-monitor/*",element:U.jsx(Im,{})}),U.jsx(Te,{path:"/task-manager/*",element:U.jsx(ob,{})}),U.jsx(Te,{path:"/credit-agent/*",element:U.jsx(sb,{})}),U.jsx(Te,{path:"/*",element:U.jsx(ub,{})})]})}const wb=Object.freeze(Object.defineProperty({__proto__:null,default:cb},Symbol.toStringTag,{value:"Module"}));export{Pe as P,wb as S,ym as u};
@@ -1 +1 @@
1
- import{j as d}from"./liveblocks-ahYf3CBU.js";import{a as f,b as S,n as I}from"./sentry-ClFkBudX.js";import{n as m,i as w,g,u as b,N as h,h as y}from"./core-CubrU-Ir.js";import{z as l,m as v,D as C,b as E,l as U,W as T,c as p}from"./index-B6kwgn-g.js";import{Is as x,It as D,Iu as L,Iv as z,bk as u}from"./zeni-epic-state-ClxFvNCS.js";import{f as k}from"./analyticsHelper-D81pIoPK.js";import"./recharts-MWMfXqT7.js";import"./mui-Ck6E7dQO.js";import"./analytics-l9sdkpP9.js";import"./lottie-Cqe0-Pdp.js";import"./lexical-BUlYyLJO.js";import"./utils-Ca1dkZzF.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]="be47b645-29df-458b-aa01-1aa0e513cbde",e._sentryDebugIdIdentifier="sentry-dbid-be47b645-29df-458b-aa01-1aa0e513cbde")}catch{}})();function A(e){const o=e.tenantState.fetchState,i=e.tenantState.sendEmailMagicLinkFetchState;return{googleClientId:p.googleClientId,microsoftClientId:p.microsoftClientId,signInError:e.tenantState.error?.error,fetchState:o,sendMagicLinkStatus:i,showEmailLogin:!1}}function N(e,o){const{location:i,navigate:r}=o;return console.warn(JSON.stringify(window.location)),{onOAuthError:(n,t)=>{I({message:`OAuth error from provider ${t} with error ${n}`,level:"error",tags:{authProvider:t,errorType:"zeni.login.error"},extra:{error:n,windowLocation:window.location.href}})},onOAuthSuccess:(n,t)=>{const s=t==="google"?window.location.origin:window.location.origin+window.location.pathname;e(z({authCode:n,oauthProvider:t,appType:"web",redirectUri:u(s),sourceUri:u(i.state!=null?i.state.origin:"")}))},getSignedInUser:()=>l.getSignedInUser(),onSignedInCallback:()=>{const n=i.state?.origin;n&&n!=="/"?r(n,{replace:!0}):window.open(window.location.origin,"_self")},clearSignInError:()=>{e(L())}}}const P=y(A,N)(T),_=S.memo(P);function G(){const e=m(),o=w(),i=l.getSignedInUser(),r=g(a=>a.tenantState.fetchState),n=g(a=>a.tenantState.signInState),t=g(a=>a.tenantState.loggedInUser),s=v().mode,c=b();if(f.useEffect(()=>{n==="In-Progress"&&r==="Completed"&&t?.zeniSessionId!=null&&(l.saveSignedInUserWithSession(t,t.zeniSessionId),x(t.userId,t.zeniSessionId),e(D("Completed")),C.updateAppLocaleID("en"),k(t,s),setTimeout(()=>{E.trackLogin(U.Event.loginSuccess,t.authProvider??"google")},2e3))},[]),n==="In-Progress"&&r==="Completed"&&t?.zeniSessionId!=null||i!=null){const a=c.state?.origin??"/";return d.jsx(h,{to:a,state:{...c.state,origin:""}})}else return d.jsx(_,{navigate:o,location:c})}export{G as default};
1
+ import{j as d}from"./liveblocks-C75FN-S8.js";import{a as f,b as S,n as I}from"./sentry-B3Shr2Jp.js";import{n as m,i as w,g,u as b,N as h,h as y}from"./core-zJRmDR0C.js";import{z as l,m as v,D as C,b as E,l as U,W as T,c as p}from"./index-BkuaEqDM.js";import{Is as x,It as D,Iu as L,Iv as z,bk as u}from"./zeni-epic-state-DvZcg696.js";import{f as k}from"./analyticsHelper-BiwhWgyJ.js";import"./recharts-BbCfzDSc.js";import"./mui-k1YoVrai.js";import"./analytics-B-cuNK8P.js";import"./lottie-Bu1dVLzt.js";import"./lexical-DgFeVxHB.js";import"./utils-CBBpikVS.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]="be47b645-29df-458b-aa01-1aa0e513cbde",e._sentryDebugIdIdentifier="sentry-dbid-be47b645-29df-458b-aa01-1aa0e513cbde")}catch{}})();function A(e){const o=e.tenantState.fetchState,i=e.tenantState.sendEmailMagicLinkFetchState;return{googleClientId:p.googleClientId,microsoftClientId:p.microsoftClientId,signInError:e.tenantState.error?.error,fetchState:o,sendMagicLinkStatus:i,showEmailLogin:!1}}function N(e,o){const{location:i,navigate:r}=o;return console.warn(JSON.stringify(window.location)),{onOAuthError:(n,t)=>{I({message:`OAuth error from provider ${t} with error ${n}`,level:"error",tags:{authProvider:t,errorType:"zeni.login.error"},extra:{error:n,windowLocation:window.location.href}})},onOAuthSuccess:(n,t)=>{const s=t==="google"?window.location.origin:window.location.origin+window.location.pathname;e(z({authCode:n,oauthProvider:t,appType:"web",redirectUri:u(s),sourceUri:u(i.state!=null?i.state.origin:"")}))},getSignedInUser:()=>l.getSignedInUser(),onSignedInCallback:()=>{const n=i.state?.origin;n&&n!=="/"?r(n,{replace:!0}):window.open(window.location.origin,"_self")},clearSignInError:()=>{e(L())}}}const P=y(A,N)(T),_=S.memo(P);function G(){const e=m(),o=w(),i=l.getSignedInUser(),r=g(a=>a.tenantState.fetchState),n=g(a=>a.tenantState.signInState),t=g(a=>a.tenantState.loggedInUser),s=v().mode,c=b();if(f.useEffect(()=>{n==="In-Progress"&&r==="Completed"&&t?.zeniSessionId!=null&&(l.saveSignedInUserWithSession(t,t.zeniSessionId),x(t.userId,t.zeniSessionId),e(D("Completed")),C.updateAppLocaleID("en"),k(t,s),setTimeout(()=>{E.trackLogin(U.Event.loginSuccess,t.authProvider??"google")},2e3))},[]),n==="In-Progress"&&r==="Completed"&&t?.zeniSessionId!=null||i!=null){const a=c.state?.origin??"/";return d.jsx(h,{to:a,state:{...c.state,origin:""}})}else return d.jsx(_,{navigate:o,location:c})}export{G as default};