@zeniai/web-cockpit-ui 2.2.98-qa → 2.2.99-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.
- package/dist/assets/CreditAgentRoutes-DvHQKnb9.js +4 -0
- package/dist/assets/{Preview-D5KcYjyY.js → Preview-ggKf0LRt.js} +1 -1
- package/dist/assets/ScreenRoutes-DKbHKe47.js +180 -0
- package/dist/assets/SignInScreen-B5j0d1yh.js +1 -0
- package/dist/assets/{analytics-9LJeC2ui.js → analytics-BmbjpANm.js} +1 -1
- package/dist/assets/{analyticsHelper-Bn5zNxT6.js → analyticsHelper-Ci0x3sK0.js} +1 -1
- package/dist/assets/{core-BeN_MChz.js → core-D-Vlp23s.js} +2 -2
- package/dist/assets/{dash.all.min-Rnd031u8.js → dash.all.min-jDncxyQF.js} +1 -1
- package/dist/assets/{empty-B6Juc8c0.js → empty-2xsJlgGw.js} +1 -1
- package/dist/assets/{empty-B6fhfTji.js → empty-BN3k40A0.js} +1 -1
- package/dist/assets/epic-ByKamKWD.js +2 -0
- package/dist/assets/{index-D2Snqbrz.js → index-B3tQN2Ou.js} +2 -2
- package/dist/assets/{index-BVKpk70U.js → index-B7oLjpC_.js} +1 -1
- package/dist/assets/{index-oaCCkHQy.js → index-BCSV7VKj.js} +1 -1
- package/dist/assets/{index-DOUoD24w.js → index-Ck0BHUCw.js} +8834 -8873
- package/dist/assets/{index-BheXYrT5.js → index-YXOoz2xD.js} +1 -1
- package/dist/assets/{index-BAoPLD4I.js → index-d-PNdGSe.js} +1 -1
- package/dist/assets/{index-B6pbH0gy.js → index-sxWmjH1D.js} +1 -1
- package/dist/assets/{lexical-BqK5-7NV.js → lexical-B8BrfuLX.js} +1 -1
- package/dist/assets/{liveblocks-DJRlGFea.js → liveblocks-CuYKBdWD.js} +1 -1
- package/dist/assets/{lottie-42X37YWv.js → lottie-HbwInLor.js} +1 -1
- package/dist/assets/{mui-CGQrau-g.js → mui-CI_QcAux.js} +1 -1
- package/dist/assets/{react-DPG_U-wR.js → react-BljoWTky.js} +1 -1
- package/dist/assets/{react-DiqwxBH3.js → react-Cf7Q-TXQ.js} +1 -1
- package/dist/assets/{react-ojhVLh7w.js → react-DTJyscEN.js} +1 -1
- package/dist/assets/{react-KHSurLLg.js → react-D_X_n0u8.js} +1 -1
- package/dist/assets/{react-CIqV91Wz.js → react-Dt_P3Kcx.js} +2 -2
- package/dist/assets/{react-DlKpTtFX.js → react-DxQL2c71.js} +1 -1
- package/dist/assets/{react-p-OZ61XO.js → react-FNPJViWL.js} +1 -1
- package/dist/assets/{react-2C81n5o6.js → react-vuuKOhIx.js} +1 -1
- package/dist/assets/{recharts-DbjCNeeG.js → recharts-BS3zSciQ.js} +1 -1
- package/dist/assets/{sentry-Byc6pCkb.js → sentry-Bg0tGjUz.js} +1 -1
- package/dist/assets/{url-BK_ow_fu.js → url-BtWQCRh2.js} +1 -1
- package/dist/assets/{url-CrLeJSNF.js → url-DmTMZYMX.js} +1 -1
- package/dist/assets/{utils-DUjxgMjZ.js → utils-BnibThjb.js} +1 -1
- package/dist/assets/{zeni-epic-state-DVoFFDBc.js → zeni-epic-state-0nsBF6z1.js} +7 -7
- package/dist/index.html +1 -1
- package/package.json +4 -4
- package/dist/assets/CreditAgentRoutes-CFkzos0Q.js +0 -4
- package/dist/assets/ScreenRoutes-BBkA1OBX.js +0 -180
- package/dist/assets/SignInScreen-Cty5USqv.js +0 -1
- package/dist/assets/epic-C2_weDsD.js +0 -2
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import{j as s}from"./liveblocks-CuYKBdWD.js";import{u as P,P as v}from"./ScreenRoutes-DKbHKe47.js";import{a as f}from"./sentry-Bg0tGjUz.js";import{i as T,n as U,g as m,h as N,k as C,l as I,N as R}from"./core-D-Vlp23s.js";import{SL as j,SM as M,lB as k,SN as E,mr as L,mu as $,mg as B,SO as O,SP as _,mo as F,mk as q}from"./zeni-epic-state-0nsBF6z1.js";import{z as V,T as G,G as J,n as W,W as Z,B as H,$ as K,b as Q,g as X,h as Y}from"./index-Ck0BHUCw.js";import{n as ee}from"./mui-CI_QcAux.js";import"./recharts-BS3zSciQ.js";import"./analyticsHelper-Ci0x3sK0.js";import"./utils-BnibThjb.js";import"./empty-2xsJlgGw.js";import"./index-sxWmjH1D.js";import"./url-BtWQCRh2.js";import"./index-YXOoz2xD.js";import"./analytics-BmbjpANm.js";import"./lottie-HbwInLor.js";import"./lexical-B8BrfuLX.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]="4f466a1e-a4e9-4b04-a705-e6aca64c9f3f",a._sentryDebugIdIdentifier="sentry-dbid-4f466a1e-a4e9-4b04-a705-e6aca64c9f3f")}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);Q.trackCockpitTabClicked(c),t.navigate(`../../${g}`,{replace:!0})}},creditAgentPageActions:{onFetchMacro:()=>{a(q())},onSaveMacro:n=>{a(F(n))},onResetSaveMacro:()=>{a(_())},onUIStateChange:n=>{a(O(n))},cardProfilesActions:t.cardProfilesActions}}}const ae=N(te,ne)(Z),oe=ee.div`
|
|
2
|
+
padding: ${W.sp5};
|
|
3
|
+
text-align: center;
|
|
4
|
+
`;function re(){const a=T(),t=U(),n=m(j),g=m(M),[c,h]=f.useState(new Set),S=f.useRef(new Set),b=m(e=>e.tenantState.currentTenantId),y=m(e=>e.companyViewState.zeniUsers.fetchState);f.useEffect(()=>{y==="Not-Started"&&t(k())},[t,y]);const d=V.getSignedInUser(),A=d!=null&&[d.firstName,d.lastName].filter(Boolean).join(" ")||void 0,w=f.useMemo(()=>({onFetch:()=>{t(B())},onUpdateProfile:(e,o,r)=>{const i=r.updatedByName??A;t($({tenantId:o,tenantEmailDomain:e,update:{...r,updatedByName:i}}))},onAnalyse:e=>{h(o=>new Set(o).add(e)),t(L(e))},onDownloadReport:()=>{const e=E(n.rows),o=d?.userId??"",r=d?.zeniSessionId??"",i=b??"";if(!o||!r||!i)return;const x=encodeURIComponent(JSON.stringify(e)),D=`${G}/tableDownload?query=${x}`;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),p=document.createElement("a");p.href=u,p.download=`${e.file_name}.xlsx`,p.click(),URL.revokeObjectURL(u)}).catch(()=>{})}}),[t,A,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?S.current.add(o):r!=null&&!r.isAnalyzing&&S.current.has(o)&&(e.add(o),S.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 z=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:z})}function we(){const{isAllowed:a,isLoading:t}=P();return t?null:a?s.jsx(C,{children:s.jsx(I,{path:"/*",element:s.jsx(v,{element:s.jsx(re,{})})})}):s.jsx(C,{children:s.jsx(I,{path:"/*",element:s.jsx(R,{to:"/management",replace:!0})})})}export{we as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as h,R as n}from"./sentry-
|
|
1
|
+
import{a as h,R as n}from"./sentry-Bg0tGjUz.js";(function(){try{var t=typeof window<"u"?window:typeof global<"u"?global:typeof globalThis<"u"?globalThis:typeof self<"u"?self:{},a=new t.Error().stack;a&&(t._sentryDebugIds=t._sentryDebugIds||{},t._sentryDebugIds[a]="f4ba052c-9e02-4735-9454-bf2cba2bc7bc",t._sentryDebugIdIdentifier="sentry-dbid-f4ba052c-9e02-4735-9454-bf2cba2bc7bc")}catch{}})();const d="64px",u={},k=({src:t,light:a,oEmbedUrl:r,onClickPreview:s,playIcon:m,previewTabIndex:I,previewAriaLabel:f})=>{const[b,o]=h.useState(null);h.useEffect(()=>{!t||!a||!r||_({src:t,light:a,oEmbedUrl:r})},[t,a,r]);const _=async({src:e,light:i,oEmbedUrl:E})=>{if(n.isValidElement(i))return;if(typeof i=="string"){o(i);return}if(u[e]){o(u[e]);return}o(null);const y=await(await fetch(E.replace("{url}",e))).json();if(y.thumbnail_url){const g=y.thumbnail_url.replace("height=100","height=480").replace("-d_295x166","-d_640");o(g),u[e]=g}},w=e=>{(e.key==="Enter"||e.key===" ")&&s?.(e)},v=e=>{s?.(e)},l=n.isValidElement(a),p={display:"flex",alignItems:"center",justifyContent:"center"},c={preview:{width:"100%",height:"100%",backgroundImage:b&&!l?`url(${b})`:void 0,backgroundSize:"cover",backgroundPosition:"center",cursor:"pointer",...p},shadow:{background:"radial-gradient(rgb(0, 0, 0, 0.3), rgba(0, 0, 0, 0) 60%)",borderRadius:d,width:d,height:d,position:l?"absolute":void 0,...p},playIcon:{borderStyle:"solid",borderWidth:"16px 0 16px 26px",borderColor:"transparent transparent transparent white",marginLeft:"7px"}},x=n.createElement("div",{style:c.shadow,className:"react-player__shadow"},n.createElement("div",{style:c.playIcon,className:"react-player__play-icon"}));return n.createElement("div",{style:c.preview,className:"react-player__preview",tabIndex:I,onClick:v,onKeyDown:w,...f?{"aria-label":f}:{}},l?a:null,m||x)};var S=k;export{S as default};
|