@zeniai/web-cockpit-ui 2.0.54-qa → 2.0.55-dev
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/assets/{CreditAgentRoutes-Bxq1F6h0.js → CreditAgentRoutes-lbd_MK0D.js} +2 -2
- package/dist/assets/{Preview-B2dhyTVA.js → Preview-Dft8UMrA.js} +1 -1
- package/dist/assets/{ScreenRoutes-BypUB9x8.js → ScreenRoutes-CSwVMLdU.js} +63 -63
- package/dist/assets/{SignInScreen-BV5jDbyJ.js → SignInScreen-tR5i-k-R.js} +1 -1
- package/dist/assets/{analytics-DxrVsL3o.js → analytics-CZC88X5V.js} +1 -1
- package/dist/assets/{analyticsHelper-D4T-So_M.js → analyticsHelper-B6iKPGmi.js} +1 -1
- package/dist/assets/{core-BEaM6OJP.js → core-BwBR9UGX.js} +1 -1
- package/dist/assets/{dash.all.min-MMJCfPzU.js → dash.all.min--n3W8vKO.js} +1 -1
- package/dist/assets/{empty-u2A1ibtT.js → empty-BJtmobCg.js} +1 -1
- package/dist/assets/{empty-CJSA64Td.js → empty-D1jcH9CU.js} +1 -1
- package/dist/assets/epic-WTqV22B1.js +2 -0
- package/dist/assets/{index-DD16VSOb.js → index-1cOufiGn.js} +5836 -5840
- package/dist/assets/{index-DX6bTTcO.js → index-BTVtWPFV.js} +2 -2
- package/dist/assets/{index-CTK431mX.js → index-BUnmt4UX.js} +1 -1
- package/dist/assets/{index-EtHp3w0s.js → index-BjKp95p8.js} +1 -1
- package/dist/assets/{index-BClBXkno.js → index-C_SYn1tB.js} +1 -1
- package/dist/assets/{index-CsMf-_n1.js → index-D7t5xD4r.js} +1 -1
- package/dist/assets/{index-mW0eKyKU.js → index-QwVFwKAR.js} +1 -1
- package/dist/assets/{lexical-BnBhJ7wU.js → lexical-D8iPK0XK.js} +1 -1
- package/dist/assets/{liveblocks-DJmGcrV9.js → liveblocks-BRGrlVNy.js} +1 -1
- package/dist/assets/{lottie-BVK_PRd3.js → lottie-DMgLlnr6.js} +1 -1
- package/dist/assets/{mui-BzOdrXtH.js → mui-CvsuEZ8B.js} +1 -1
- package/dist/assets/{react-DL20wnlH.js → react-BdTZtVrZ.js} +1 -1
- package/dist/assets/{react-CBii5szV.js → react-Cw8iGbyo.js} +1 -1
- package/dist/assets/{react-DCrFvEmt.js → react-D2HlRp9b.js} +1 -1
- package/dist/assets/{react-DvMUOQRA.js → react-DZe9Jy5B.js} +1 -1
- package/dist/assets/{react-3G5V2mWN.js → react-DcBbMkYY.js} +2 -2
- package/dist/assets/{react-NAbQSm8l.js → react-DigT2Kde.js} +1 -1
- package/dist/assets/{react-BVymh9Ta.js → react-Dj7S2NuA.js} +1 -1
- package/dist/assets/{react-CAS7_AiY.js → react-OD6vUrpj.js} +1 -1
- package/dist/assets/{recharts-CAX3Qhsg.js → recharts-CgiWALSS.js} +1 -1
- package/dist/assets/{sentry-DMsB_HR9.js → sentry-CYft-6jQ.js} +1 -1
- package/dist/assets/{url-jXUbohHj.js → url-8qBdEVtr.js} +1 -1
- package/dist/assets/{url-Cy7vic92.js → url-CnnQaD6F.js} +1 -1
- package/dist/assets/{utils-DIo31iqp.js → utils-DAsEu9Dc.js} +1 -1
- package/dist/assets/{zeni-epic-state-D5hwvIfO.js → zeni-epic-state-CGyFmTlz.js} +6 -6
- package/dist/index.html +1 -1
- package/package.json +6 -10
- package/dist/assets/epic-BBIjk2kZ.js +0 -2
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as i}from"./liveblocks-
|
|
1
|
+
import{j as i}from"./liveblocks-BRGrlVNy.js";import{z as w,$ as v,D as j,o as E,a0 as P,F as k,Q as R,c as T,g as N,d as M,v as $,x as L}from"./index-1cOufiGn.js";import{a as f}from"./sentry-CYft-6jQ.js";import{i as _,n as F,g as S,h as O,k as A,l as C,N as B}from"./core-BwBR9UGX.js";import{H$ as V,I0 as q,jM as Q,I1 as H,kg as J,kj as Z,k3 as G,I2 as K,I3 as W,kd as X,k9 as Y}from"./zeni-epic-state-CGyFmTlz.js";import{n as ee}from"./mui-CvsuEZ8B.js";import{P as te}from"./ScreenRoutes-CSwVMLdU.js";import"./recharts-CgiWALSS.js";import"./analytics-CZC88X5V.js";import"./lottie-DMgLlnr6.js";import"./lexical-D8iPK0XK.js";import"./utils-DAsEu9Dc.js";import"./analyticsHelper-B6iKPGmi.js";import"./empty-BJtmobCg.js";import"./index-C_SYn1tB.js";import"./url-8qBdEVtr.js";import"./index-D7t5xD4r.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]="3e227ca6-7b7f-4a82-8a9d-2633141e145d",a._sentryDebugIdIdentifier="sentry-dbid-3e227ca6-7b7f-4a82-8a9d-2633141e145d")}catch{}})();function ne(a,t){return{headerData:{allTabOptions:k,selectedTabOption:R("creditAgent")},creditAgentPageData:{macroData:{data:t.macroCombined.data,fetchState:t.macroCombined.fetchStatus.fetchState,updateState:t.macroCombined.updateStatus.fetchState},cardProfilesData:t.cardProfilesData}}}function ae(a,t){return{headerActions:{onTabChange:n=>{const u=M(n),r=N(n);T.trackCockpitTabClicked(r),t.navigate(`../../${u}`,{replace:!0})}},creditAgentPageActions:{onFetchMacro:()=>{a(Y())},onSaveMacro:n=>{a(X(n))},onResetSaveMacro:()=>{a(W())},onUIStateChange:n=>{a(K(n))},cardProfilesActions:t.cardProfilesActions}}}const oe=O(ne,ae)(P),se=ee.div`
|
|
2
2
|
padding: ${E.sp5};
|
|
3
3
|
text-align: center;
|
|
4
|
-
`;function re(){const a=_(),t=F(),n=S(V),u=S(q),[r,m]=f.useState(new Set),g=f.useRef(new Set),y=S(e=>e.tenantState.currentTenantId),
|
|
4
|
+
`;function re(){const a=_(),t=F(),n=S(V),u=S(q),[r,m]=f.useState(new Set),g=f.useRef(new Set),y=S(e=>e.tenantState.currentTenantId),b=S(e=>e.companyViewState.zeniUsers.fetchState);f.useEffect(()=>{b==="Not-Started"&&t(Q())},[t,b]);const d=w.getSignedInUser(),I=d!=null&&[d.firstName,d.lastName].filter(Boolean).join(" ")||void 0,x=f.useMemo(()=>({onFetch:()=>{t(G())},onUpdateProfile:(e,o,s)=>{const c=s.updatedByName??I;t(Z({tenantId:o,tenantEmailDomain:e,update:{...s,updatedByName:c}}))},onAnalyse:e=>{m(o=>new Set(o).add(e)),t(J(e))},onDownloadReport:()=>{const e=H(n.rows),o=d?.userId??"",s=d?.zeniSessionId??"",c=y??"";if(!o||!s||!c)return;const z=encodeURIComponent(JSON.stringify(e)),D=`${v}/tableDownload?query=${z}`;fetch(D,{headers:{"zeni-user-id":o,"zeni-session-id":s,"zeni-tenant-id":c}}).then(async l=>{if(!l.ok){const p=await l.text();throw new Error(`Download failed: ${l.status} ${p}`)}return l.blob()}).then(l=>{const p=URL.createObjectURL(l),h=document.createElement("a");h.href=p,h.download=`${e.file_name}.xlsx`,h.click(),URL.revokeObjectURL(p)}).catch(()=>{})}}),[t,I,d,y,n.rows]);f.useEffect(()=>{if(r.size===0)return;const e=new Set;for(const o of r){const s=n.rows.find(c=>c.tenantId===o);s!=null&&s.isAnalyzing?g.current.add(o):s!=null&&!s.isAnalyzing&&g.current.has(o)&&(e.add(o),g.current.delete(o))}e.size>0&&m(o=>{const s=new Set(o);for(const c of e)s.delete(c);return s})},[n.rows,r]);const U=f.useMemo(()=>({fetchState:n.fetchStatus.fetchState,rows:n.rows.map(e=>e.isAnalyzing||e.tenantId!=null&&r.has(e.tenantId)?{...e,isAnalyzing:!0}:e),uiState:n.uiState}),[n,r]);return d==null?i.jsx(se,{children:j.getLocalizedStrings().cockpit.creditAgent.notSignedIn}):i.jsx(oe,{macroCombined:u,navigate:a,cardProfilesActions:x,cardProfilesData:U})}function xe(){const{useDynamicConfig:a}=$(),{configValue:t,isDynamicConfigLoading:n}=a(L.creditAgentEnablement);if(n)return null;const r=w.getSignedInUser()?.userEmail,m=Array.isArray(t?.allowedUserEmails)?t.allowedUserEmails:[];return r!=null&&m.includes(r)?i.jsx(A,{children:i.jsx(C,{path:"/*",element:i.jsx(te,{element:i.jsx(re,{})})})}):i.jsx(A,{children:i.jsx(C,{path:"/*",element:i.jsx(B,{to:"/management",replace:!0})})})}export{xe as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as h,b as a}from"./sentry-
|
|
1
|
+
import{a as h,b as a}from"./sentry-CYft-6jQ.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};
|