@zeniai/web-cockpit-ui 2.2.51-qa → 2.2.52-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-C-xYt5E2.js → CreditAgentRoutes-TGoHqRFT.js} +3 -3
- package/dist/assets/{Preview-CJdpXjqX.js → Preview-DS_LyfZu.js} +1 -1
- package/dist/assets/{ScreenRoutes-BazUMhrE.js → ScreenRoutes-BhDo-OUu.js} +62 -62
- package/dist/assets/SignInScreen-BA3IfNnz.js +1 -0
- package/dist/assets/{analytics-ctJXmkvw.js → analytics-GiIC554g.js} +1 -1
- package/dist/assets/analyticsHelper-yGPhFmoY.js +1 -0
- package/dist/assets/{core-BCgnsMH7.js → core-Bv4uDnP0.js} +1 -1
- package/dist/assets/{dash.all.min-exygind6.js → dash.all.min-BtBK3Em1.js} +1 -1
- package/dist/assets/{empty-ds0Fe9RR.js → empty-Qfejz67q.js} +1 -1
- package/dist/assets/{empty-CaRBJEwL.js → empty-u5JEudn5.js} +1 -1
- package/dist/assets/epic-BL5TL-2s.js +2 -0
- package/dist/assets/{index-B88Q2pRm.js → index-CAmExejI.js} +9309 -9386
- package/dist/assets/{index-CfcSN8OH.js → index-CV-r7kkP.js} +1 -1
- package/dist/assets/{index-Dl9XdT_V.js → index-CY-urLsj.js} +1 -1
- package/dist/assets/{index-SIyxfXvy.js → index-DHQG2-hm.js} +1 -1
- package/dist/assets/{index-B-Am3qm6.js → index-Qy6JU2gv.js} +1 -1
- package/dist/assets/{index-B_tyfSO4.js → index-YNvROpbD.js} +1 -1
- package/dist/assets/{index-CFMT8GQx.js → index-aoxWDZe-.js} +2 -2
- package/dist/assets/{lexical-DUmphpSF.js → lexical-BxOg5F7V.js} +1 -1
- package/dist/assets/{liveblocks-CBXVKwHX.js → liveblocks-BY0-kO4Q.js} +1 -1
- package/dist/assets/{lottie-DOshSqxu.js → lottie-EabEFJ_M.js} +1 -1
- package/dist/assets/{mui-BaUx3JyA.js → mui-0SU7Tnx3.js} +1 -1
- package/dist/assets/{react-DI8WS9zM.js → react--KLFkMtz.js} +1 -1
- package/dist/assets/{react-BwNfy_DK.js → react-C6j1riWB.js} +1 -1
- package/dist/assets/{react-Cg-RQQVf.js → react-CcJ72XH1.js} +2 -2
- package/dist/assets/{react-CJdI51iL.js → react-CeZHdx0W.js} +1 -1
- package/dist/assets/{react-o0JazEja.js → react-D3_QvBRt.js} +1 -1
- package/dist/assets/{react-DrkyKLly.js → react-D428vJGe.js} +1 -1
- package/dist/assets/{react-CWbB20R_.js → react-KLs83Tbo.js} +1 -1
- package/dist/assets/{react-C09RWrWl.js → react-nAifvcKS.js} +1 -1
- package/dist/assets/{recharts-D-OWlkt2.js → recharts-BdWOIB1p.js} +1 -1
- package/dist/assets/{sentry-CXZepgpF.js → sentry-cBFyiNr6.js} +1 -1
- package/dist/assets/{url-DeByVjOE.js → url-DepGCZEc.js} +1 -1
- package/dist/assets/{url-BnW_WmFY.js → url-DyPlrLRq.js} +1 -1
- package/dist/assets/{utils-CYjfnf3r.js → utils-Cyd2wKCe.js} +1 -1
- package/dist/assets/zeni-epic-state-BSw-_Mx_.js +13 -0
- package/dist/index.html +1 -1
- package/package.json +4 -4
- package/dist/assets/SignInScreen-BjoZYmbO.js +0 -1
- package/dist/assets/analyticsHelper-D9M5Zcjp.js +0 -1
- package/dist/assets/epic-CSHIo21y.js +0 -2
- package/dist/assets/zeni-epic-state-ZIgcQT2P.js +0 -14
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{j as s}from"./liveblocks-
|
|
2
|
-
padding: ${
|
|
1
|
+
import{j as s}from"./liveblocks-BY0-kO4Q.js";import{u as v,P}from"./ScreenRoutes-BhDo-OUu.js";import{a as f}from"./sentry-cBFyiNr6.js";import{i as U,n as R,g as m,h as T,k as C,l as I,N as j}from"./core-Bv4uDnP0.js";import{S2 as N,S3 as k,lu as E,S4 as M,mk as L,mn as $,m9 as O,S5 as _,S6 as B,mh as F,md as q}from"./zeni-epic-state-BSw-_Mx_.js";import{z as V,Y as G,G as J,n as Y,a0 as Z,c as H,w as K,a as Q,g as W,b as X}from"./index-CAmExejI.js";import{n as ee}from"./mui-0SU7Tnx3.js";import"./recharts-BdWOIB1p.js";import"./analyticsHelper-yGPhFmoY.js";import"./utils-Cyd2wKCe.js";import"./empty-Qfejz67q.js";import"./index-YNvROpbD.js";import"./url-DyPlrLRq.js";import"./index-Qy6JU2gv.js";import"./analytics-GiIC554g.js";import"./lottie-EabEFJ_M.js";import"./lexical-BxOg5F7V.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]="05497886-b8af-4db3-9315-f0e8f9713ccc",a._sentryDebugIdIdentifier="sentry-dbid-05497886-b8af-4db3-9315-f0e8f9713ccc")}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=X(n),c=W(n);Q.trackCockpitTabClicked(c),t.navigate(`../../${g}`,{replace:!0})}},creditAgentPageActions:{onFetchMacro:()=>{a(q())},onSaveMacro:n=>{a(F(n))},onResetSaveMacro:()=>{a(B())},onUIStateChange:n=>{a(_(n))},cardProfilesActions:t.cardProfilesActions}}}const ae=T(te,ne)(Z),oe=ee.div`
|
|
2
|
+
padding: ${Y.sp5};
|
|
3
3
|
text-align: center;
|
|
4
|
-
`;function re(){const a=U(),t=R(),n=m(N),g=m(k),[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(E())},[t,y]);const d=V.getSignedInUser(),A=d!=null&&[d.firstName,d.lastName].filter(Boolean).join(" ")||void 0,w=f.useMemo(()=>({onFetch:()=>{t(
|
|
4
|
+
`;function re(){const a=U(),t=R(),n=m(N),g=m(k),[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(E())},[t,y]);const d=V.getSignedInUser(),A=d!=null&&[d.firstName,d.lastName].filter(Boolean).join(" ")||void 0,w=f.useMemo(()=>({onFetch:()=>{t(O())},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=M(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}=v();return t?null:a?s.jsx(C,{children:s.jsx(I,{path:"/*",element:s.jsx(P,{element:s.jsx(re,{})})})}):s.jsx(C,{children:s.jsx(I,{path:"/*",element:s.jsx(j,{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-cBFyiNr6.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};
|