@zeniai/web-cockpit-ui 2.1.85-qa → 2.1.86-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-CQ6nvR_j.js +4 -0
- package/dist/assets/{Preview-DwmmQie2.js → Preview-CxrVuV-8.js} +1 -1
- package/dist/assets/{ScreenRoutes-CsEmhO8V.js → ScreenRoutes-Y3skv7Ot.js} +41 -41
- package/dist/assets/SignInScreen-BVAEBH0K.js +1 -0
- package/dist/assets/{analytics-D_rxXpC8.js → analytics-uNu76d06.js} +1 -1
- package/dist/assets/{analyticsHelper-BYviqzjl.js → analyticsHelper-Dp6GltpC.js} +1 -1
- package/dist/assets/{core-B5lxTB18.js → core-BEVTODUP.js} +1 -1
- package/dist/assets/{dash.all.min-FuXZcGuC.js → dash.all.min-C31TNyc8.js} +1 -1
- package/dist/assets/{empty-BAfjRBOW.js → empty-Cbbl4oDf.js} +1 -1
- package/dist/assets/{empty-DjVh230I.js → empty-DcuJ8A78.js} +1 -1
- package/dist/assets/epic-BIcq-9vS.js +2 -0
- package/dist/assets/{index-B_1gqLvT.js → index-B8XvUm28.js} +1 -1
- package/dist/assets/{index-CbbrC6Lc.js → index-BZo7nzUY.js} +31684 -31883
- package/dist/assets/{index-DrH8gx9P.js → index-CI2JImx2.js} +1 -1
- package/dist/assets/{index-9ImZDj9u.js → index-DAHXoToS.js} +1 -1
- package/dist/assets/{index-BOdYj0hR.js → index-DF7Uy5Cv.js} +1 -1
- package/dist/assets/{index-uT-uJGqW.js → index-DhIj5yXz.js} +1 -1
- package/dist/assets/{index-DofMNFo7.js → index-PSxZ3mW2.js} +2 -2
- package/dist/assets/{lexical-CIrl5_25.js → lexical-BU8BWNhf.js} +1 -1
- package/dist/assets/{liveblocks-616HfeVO.js → liveblocks-B0jvrYAQ.js} +1 -1
- package/dist/assets/{lottie-B9CIsRey.js → lottie-DWJajBaT.js} +1 -1
- package/dist/assets/{mui-C_tWhNid.js → mui-BcdxMqTx.js} +1 -1
- package/dist/assets/{react-BHfdYj_q.js → react-0qGAyoEu.js} +1 -1
- package/dist/assets/{react-CZ15AAPD.js → react-BI3izMOc.js} +1 -1
- package/dist/assets/{react-DHGjR2bS.js → react-BuUiulo4.js} +1 -1
- package/dist/assets/{react-ev4iwCEU.js → react-Cxfqcrye.js} +1 -1
- package/dist/assets/{react-CnKYZ5zZ.js → react-DP4VeL5B.js} +1 -1
- package/dist/assets/{react-CYGGiUoP.js → react-DcaeW70i.js} +1 -1
- package/dist/assets/{react-C4rnRtSC.js → react-DnZBYLJp.js} +1 -1
- package/dist/assets/{react-BtntQDZ7.js → react-DoEQFb_Q.js} +2 -2
- package/dist/assets/{recharts-kUgrDs-8.js → recharts-B1p_4yzo.js} +1 -1
- package/dist/assets/{sentry-CkTOwWbC.js → sentry-Di6CJKc4.js} +1 -1
- package/dist/assets/{url-g12hUIgR.js → url-D_ItoLAi.js} +1 -1
- package/dist/assets/url-G41ER1sZ.js +6 -0
- package/dist/assets/{utils-BlVqaD8r.js → utils-e6hTVceB.js} +2 -2
- package/dist/assets/{zeni-epic-state-CLqy7eng.js → zeni-epic-state-BJnhH8T3.js} +8 -8
- package/dist/index.html +1 -1
- package/package.json +21 -8
- package/dist/assets/CreditAgentRoutes-D6ZL9hPd.js +0 -4
- package/dist/assets/SignInScreen-BeTSRWZi.js +0 -1
- package/dist/assets/epic-qpEahqro.js +0 -2
- package/dist/assets/url-CICmpbKD.js +0 -3
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import{j as s}from"./liveblocks-B0jvrYAQ.js";import{u as D,P as v}from"./ScreenRoutes-Y3skv7Ot.js";import{a as f}from"./sentry-Di6CJKc4.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-BEVTODUP.js";import{Po as N,Pp as k,kB as E,Pq as M,lr as L,lu as $,lg as _,Pr as q,Ps as B,lo as O,lk as F}from"./zeni-epic-state-BJnhH8T3.js";import{z as V,$ as J,e as Z,f as G,a0 as H,D as K,a as Q,b as W,g as X,h as Y}from"./index-BZo7nzUY.js";import{n as ee}from"./mui-BcdxMqTx.js";import"./recharts-B1p_4yzo.js";import"./analyticsHelper-Dp6GltpC.js";import"./utils-e6hTVceB.js";import"./empty-DcuJ8A78.js";import"./index-DhIj5yXz.js";import"./url-G41ER1sZ.js";import"./index-CI2JImx2.js";import"./analytics-uNu76d06.js";import"./lottie-DWJajBaT.js";import"./lexical-BU8BWNhf.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]="36dd4faa-f2e8-470e-91c1-2ba4da2e70df",a._sentryDebugIdIdentifier="sentry-dbid-36dd4faa-f2e8-470e-91c1-2ba4da2e70df")}catch{}})();function te(a,t){return{headerData:{allTabOptions:K,selectedTabOption:Q("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(F())},onSaveMacro:n=>{a(O(n))},onResetSaveMacro:()=>{a(B())},onUIStateChange:n=>{a(q(n))},cardProfilesActions:t.cardProfilesActions}}}const ae=T(te,ne)(H),oe=ee.div`
|
|
2
|
+
padding: ${G.sp5};
|
|
3
|
+
text-align: center;
|
|
4
|
+
`;function re(){const a=U(),t=R(),n=m(N),g=m(k),[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=V.getSignedInUser(),A=d!=null&&[d.firstName,d.lastName].filter(Boolean).join(" ")||void 0,z=f.useMemo(()=>({onFetch:()=>{t(_())},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 w=encodeURIComponent(JSON.stringify(e)),x=`${J}/tableDownload?query=${w}`;fetch(x,{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,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?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 P=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:Z.getLocalizedStrings().cockpit.creditAgent.notSignedIn}):s.jsx(ae,{macroCombined:g,navigate:a,cardProfilesActions:z,cardProfilesData:P})}function ze(){const{isAllowed:a,isLoading:t}=D();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(j,{to:"/management",replace:!0})})})}export{ze as default};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as h,R as n}from"./sentry-
|
|
1
|
+
import{a as h,R as n}from"./sentry-Di6CJKc4.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};
|