@lacneu/atrium 0.26.1 → 0.27.0
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/{AccessTab-C_Lvzi-s.js → AccessTab-CEmMOcXT.js} +1 -1
- package/dist/assets/{AdvancedFilter-DnGyDWXx.js → AdvancedFilter-C7EdUbso.js} +1 -1
- package/dist/assets/AgentFilesTab-C9tMrmAg.js +3 -0
- package/dist/assets/AnomaliesTab-DrUwzDmG.js +1 -0
- package/dist/assets/AuditTab-Aj8uI0v6.js +1 -0
- package/dist/assets/BridgeTab-CA5_P4aZ.js +1 -0
- package/dist/assets/ChatDefaultsTab-CVNE9suc.js +1 -0
- package/dist/assets/{DataTableShell-y4F1v6a9.js → DataTableShell-B9cSAz8l.js} +1 -1
- package/dist/assets/{DetailChips-BFrPLaU7.js → DetailChips-CWQEoST8.js} +1 -1
- package/dist/assets/FeedbacksTab-DSeHh3a5.js +1 -0
- package/dist/assets/{FieldLabel-GI9NETEt.js → FieldLabel-BGZ_qKFR.js} +2 -2
- package/dist/assets/FilesTab-Bkb5DTn0.js +1 -0
- package/dist/assets/{FilterBar-B_mSpGb-.js → FilterBar-CHAmMDFh.js} +1 -1
- package/dist/assets/GroupsTab-CR4m4DqG.js +1 -0
- package/dist/assets/InstancesTab-V2KYNZTK.js +1 -0
- package/dist/assets/IntegrationsTab-B3B8_e3n.js +1 -0
- package/dist/assets/KpiTab-Bh67xpFW.js +1 -0
- package/dist/assets/PreferencesTab-Bp7NvRbP.js +1 -0
- package/dist/assets/PromptInjectionsTab-Bp6feq2x.js +3 -0
- package/dist/assets/RolesTab-B22EPCra.js +1 -0
- package/dist/assets/ServiceAccountsTab-pWc6hbtd.js +1 -0
- package/dist/assets/SubAgentReportsTab-CzLYKjvx.js +1 -0
- package/dist/assets/ThemeShowroom-Da9-MU65.js +1 -0
- package/dist/assets/{TimeRangePicker-CFCLAlKB.js → TimeRangePicker-Dj6YRWgA.js} +1 -1
- package/dist/assets/TracesTab-Bxfvod8I.js +1 -0
- package/dist/assets/UsersTab-C6FpLZh2.js +1 -0
- package/dist/assets/{button-BOkPsnkZ.js → button-J0r_4wz5.js} +1 -1
- package/dist/assets/{card-D7I9UeSH.js → card-dyG2YjyY.js} +1 -1
- package/dist/assets/chevrons-up-down-0_epvFU7.js +1 -0
- package/dist/assets/{compatView-CcKTaWCH.js → compatView-DPRQjsZh.js} +1 -1
- package/dist/assets/dispatchErrorInfo-xSgyy7Pa.js +1 -0
- package/dist/assets/{dist-CRGyTqMI.js → dist-BFIP7qvw.js} +1 -1
- package/dist/assets/{dist-CI2WPmAQ.js → dist-DS1M4Gey.js} +1 -1
- package/dist/assets/{dist-Cxz8d8g5.js → dist-DggIHtPt.js} +1 -1
- package/dist/assets/dist-dDi5a2bA.js +1 -0
- package/dist/assets/{highlighted-body-OFNGDK62-D8Rm1ZUS.js → highlighted-body-OFNGDK62-EPlwFMM-.js} +1 -1
- package/dist/assets/{index-DbRDkkXU.css → index-B08-jWhj.css} +1 -1
- package/dist/assets/index-BI4JM57h.js +229 -0
- package/dist/assets/mermaid-GHXKKRXX-Dap6Di3w.js +1 -0
- package/dist/assets/roleDescriptions-BJkLcyAA.js +1 -0
- package/dist/assets/{table-XSL9PnTz.js → table-BuMPc1vP.js} +1 -1
- package/dist/assets/{tabs-DT8VXxMj.js → tabs-BTVXPiSJ.js} +1 -1
- package/dist/assets/x-CjN2swsp.js +1 -0
- package/dist/index.html +8 -8
- package/package.json +1 -1
- package/dist/assets/AgentFilesTab-mB_H9qhv.js +0 -3
- package/dist/assets/AnomaliesTab-DXWIdPjg.js +0 -1
- package/dist/assets/AuditTab-CM3yKrcE.js +0 -1
- package/dist/assets/BridgeTab-Bba1_oYY.js +0 -1
- package/dist/assets/ChatDefaultsTab-BJWGY5p4.js +0 -1
- package/dist/assets/FeedbacksTab-Dypzq2xC.js +0 -1
- package/dist/assets/FilesTab-Bo0mLlHv.js +0 -1
- package/dist/assets/GroupsTab-BsdKKpSh.js +0 -1
- package/dist/assets/InstancesTab-AFQsddYr.js +0 -1
- package/dist/assets/IntegrationsTab-_AZobXTN.js +0 -1
- package/dist/assets/KpiTab-DS2vaP8Y.js +0 -1
- package/dist/assets/PreferencesTab-D5id-SH6.js +0 -1
- package/dist/assets/PromptInjectionsTab-DHLbMEQv.js +0 -3
- package/dist/assets/RolesTab-DfLWu7KJ.js +0 -1
- package/dist/assets/ServiceAccountsTab-BdNBgyiw.js +0 -1
- package/dist/assets/SubAgentReportsTab-DiGx-0oc.js +0 -1
- package/dist/assets/ThemeShowroom-BAS4cMDv.js +0 -1
- package/dist/assets/TracesTab-w5olufef.js +0 -1
- package/dist/assets/UsersTab-DFcSXBQJ.js +0 -1
- package/dist/assets/chevrons-up-down-Cg6ojBxr.js +0 -1
- package/dist/assets/dispatchErrorInfo-_T-F61vE.js +0 -1
- package/dist/assets/dist-CZgL-Z5m.js +0 -1
- package/dist/assets/index-BlRMvXrJ.js +0 -227
- package/dist/assets/mermaid-GHXKKRXX-CS3UuvWM.js +0 -1
- package/dist/assets/roleDescriptions-mq0g_Z5c.js +0 -1
- package/dist/assets/x-BimfpZdd.js +0 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as e,l as t,r as n}from"./bundle-mjs-C73ZY4La.js";import{Ap as r,Bb as i,Bp as a,Cp as o,Cx as s,DO as c,Dp as l,Ep as u,Ex as d,Fp as f,Gb as p,Hb as m,Ip as h,Jb as g,Kb as _,Lb as v,Lp as ee,Mp as te,NO as y,Np as ne,OO as b,Op as re,PO as x,Pp as ie,Rb as S,Rp as ae,Sp as oe,Sx as C,Tp as se,Tx as w,Ub as T,Vb as ce,Wb as le,Xb as ue,Yb as de,Zb as fe,_p as pe,_x as me,ap as he,ax as ge,bp as _e,bx as E,cp as ve,cx as D,dp as ye,dx as be,fp as xe,fx as O,gp as Se,gx as k,hp as Ce,hx as A,ip as j,ix as M,jp as we,kp as Te,lp as Ee,lx as N,mp as De,mx as P,np as Oe,nx as F,op as ke,ox as I,pp as Ae,px as L,qb as je,rp as Me,rx as R,sp as Ne,sx as Pe,up as Fe,ux as Ie,vp as Le,vx as Re,wp as ze,wx as Be,xp as Ve,xx as He,yp as Ue,yx as We,zb as Ge,zp as Ke}from"./dist-DggIHtPt.js";import{n as qe}from"./dist-BFIP7qvw.js";import{t as Je}from"./x-CjN2swsp.js";import{i as z,n as B,r as Ye,t as Xe}from"./tabs-BTVXPiSJ.js";import{t as V}from"./button-J0r_4wz5.js";import{$ as Ze,C as H,Ct as Qe,Dt as $e,Mt as et,Q as tt,S as U,X as W,a as nt,b as G,et as rt,i as it,jt as at,k as ot,nt as st,o as ct,ot as lt,r as ut,rt as dt,wt as ft,x as K,y as q}from"./index-BI4JM57h.js";import{n as pt}from"./TimeRangePicker-Dj6YRWgA.js";import{t as mt}from"./FilterBar-CHAmMDFh.js";import{t as ht}from"./AdvancedFilter-C7EdUbso.js";import{t as gt}from"./DataTableShell-B9cSAz8l.js";var _t=b(`eye-off`,[[`path`,{d:`M10.733 5.076a10.744 10.744 0 0 1 11.205 6.575 1 1 0 0 1 0 .696 10.747 10.747 0 0 1-1.444 2.49`,key:`ct8e1f`}],[`path`,{d:`M14.084 14.158a3 3 0 0 1-4.242-4.242`,key:`151rxh`}],[`path`,{d:`M17.479 17.499a10.75 10.75 0 0 1-15.417-5.151 1 1 0 0 1 0-.696 10.75 10.75 0 0 1 4.446-5.143`,key:`13bj9a`}],[`path`,{d:`m2 2 20 20`,key:`1ooewy`}]]),vt=b(`scroll-text`,[[`path`,{d:`M15 12h-5`,key:`r7krc0`}],[`path`,{d:`M15 8h-5`,key:`1khuty`}],[`path`,{d:`M19 17V5a2 2 0 0 0-2-2H4`,key:`zz82l3`}],[`path`,{d:`M8 21h12a2 2 0 0 0 2-2v-1a1 1 0 0 0-1-1H11a1 1 0 0 0-1 1v1a2 2 0 1 1-4 0V5a2 2 0 1 0-4 0v2a1 1 0 0 0 1 1h3`,key:`1ph1d7`}]]),J=t(e(),1),Y=n(),X={kind:`relative`,from:`now-520w`,to:`now`},Z=e=>e===null?`-`:String(Math.round(e));function yt(e){let t=e.indexOf(`:`);if(t<0)return e;let n=e.slice(0,t),r=e.slice(t+1);return n===`admin`?Pe():n===`agent`?`${I()} - ${r}`:e}function bt(){let e=x(c.me.getMe,{host:lt})?.role===`admin`,t=x(c.deliveryTiming.getDeliveryStatus,{}),n=y(c.deliveryTiming.startDeliveryRecord),r=y(c.deliveryTiming.stopDeliveryRecord),[i,a]=(0,J.useState)(!1),[o,l]=(0,J.useState)(!1),u=t?.recording??!1,f=async()=>{l(!0);try{u?await r({}):await n({})}finally{l(!1)}};return(0,Y.jsxs)(`section`,{className:`mb-4 flex flex-col gap-3 rounded-lg border border-border p-4`,children:[(0,Y.jsxs)(`div`,{className:`flex items-start justify-between gap-4`,children:[(0,Y.jsxs)(`div`,{children:[(0,Y.jsx)(`h3`,{className:`text-sm font-semibold`,children:d()}),(0,Y.jsx)(`p`,{className:`oc-admin__hint`,children:w()})]}),e?(0,Y.jsx)(V,{variant:u?`destructive`:`default`,size:`sm`,disabled:o||t===void 0,onClick:()=>void f(),children:u?s():Be()}):null]}),u?(0,Y.jsxs)(`p`,{className:`flex items-center gap-2 text-sm`,children:[(0,Y.jsx)(W,{variant:`secondary`,children:C()}),t?.startedAt?(0,Y.jsx)(`span`,{className:`text-muted-foreground`,children:He({time:new Date(t.startedAt).toLocaleTimeString()})}):null]}):null,(0,Y.jsx)(`div`,{children:(0,Y.jsx)(V,{variant:`outline`,size:`sm`,onClick:()=>a(e=>!e),children:i?Re():We()})}),i?(0,Y.jsx)(xt,{isAdmin:e}):null]})}function xt({isAdmin:e}){let t=x(c.deliveryTiming.listDeliverySessions,{}),n=y(c.deliveryTiming.deleteDeliverySessions),[r,i]=(0,J.useState)(``),[a,o]=(0,J.useState)(`all`),[s,l]=(0,J.useState)(X),[u,d]=(0,J.useState)(null),{from:f,to:p}=pt(s),m=s.to===`now`?1/0:p,h=r.trim()!==``||a!==`all`||s!==X,g=()=>{i(``),o(`all`),l(X)},_=(0,J.useMemo)(()=>{if(t===void 0)return;let e=r.trim().toLowerCase();return t.filter(t=>(e===``||t.startedBy.toLowerCase().includes(e))&&(a===`all`||(a===`active`?t.active:!t.active))&&t.startedAt>=f&&t.startedAt<=m).map(e=>({...e,_id:e.sessionId}))},[t,r,a,f,m]),v=e=>{let t=new Set((_??[]).map(e=>e.sessionId)),r=e.filter(e=>t.has(e));r.length!==0&&(n({sessionIds:r}),u!==null&&r.includes(u)&&d(null))};return(0,Y.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[(0,Y.jsx)(mt,{q:r,onQChange:i,searchPlaceholder:k(),timeRange:s,onTimeRangeChange:l,onReset:g,canReset:h,children:(0,Y.jsxs)(q,{value:a,onValueChange:e=>o(e),children:[(0,Y.jsx)(U,{size:`sm`,className:`w-36`,children:(0,Y.jsx)(H,{})}),(0,Y.jsxs)(G,{children:[(0,Y.jsx)(K,{value:`all`,children:A()}),(0,Y.jsx)(K,{value:`active`,children:P()}),(0,Y.jsx)(K,{value:`stopped`,children:L()})]})]})}),(0,Y.jsx)(gt,{title:me(),rows:_,emptyHint:S(),columns:[{header:``,className:`w-8`,cell:e=>(0,Y.jsx)(V,{variant:`ghost`,size:`icon`,"aria-label":u===e.sessionId?M():ge(),onClick:()=>d(t=>t===e.sessionId?null:e.sessionId),children:u===e.sessionId?(0,Y.jsx)(_t,{size:15,"aria-hidden":!0}):(0,Y.jsx)(ft,{size:15,"aria-hidden":!0})})},{header:O(),sort:e=>e.startedAt,cell:e=>(0,Y.jsx)(`span`,{className:`tabular-nums`,children:new Date(e.startedAt).toLocaleString()})},{header:be(),sort:e=>e.stoppedAt,cell:e=>e.stoppedAt===null?(0,Y.jsx)(`span`,{className:`text-muted-foreground`,children:`-`}):(0,Y.jsx)(`span`,{className:`tabular-nums`,children:new Date(e.stoppedAt).toLocaleString()})},{header:Ie(),sort:e=>e.count,cell:e=>(0,Y.jsx)(`span`,{className:`tabular-nums`,children:Z(e.count)})},{header:N(),sort:e=>e.startedBy,cell:e=>yt(e.startedBy)},{header:D(),sort:e=>e.active,cell:e=>e.active?(0,Y.jsx)(W,{variant:`secondary`,children:P()}):(0,Y.jsx)(`span`,{className:`text-muted-foreground`,children:L()})}],rowActions:e?e=>[{label:R(),variant:`destructive`,onSelect:()=>v([e.sessionId])}]:void 0,bulkActions:e?[{label:R(),variant:`destructive`,onSelect:e=>v(e)}]:void 0,isExpanded:e=>e.sessionId===u,renderExpanded:e=>(0,Y.jsx)(St,{sessionId:e.sessionId})})]})}function St({sessionId:e}){let t=x(c.deliveryTiming.getDeliveryReport,{sessionId:e}),[n,r]=(0,J.useState)(!1);return(0,Y.jsx)(Ct,{report:t,copied:n,onCopy:()=>{t&&navigator.clipboard?.writeText(ot(t)).then(()=>{r(!0),window.setTimeout(()=>r(!1),1200)}).catch(()=>{})}})}function Ct({report:e,copied:t,onCopy:n}){if(!e)return(0,Y.jsx)(`p`,{className:`oc-admin__hint`,children:F()});if(e.count===0||e.segments===null)return(0,Y.jsx)(`p`,{className:`oc-admin__hint`,children:E()});let r=e.segments,a=(e,t)=>(0,Y.jsxs)(`tr`,{className:`border-t border-border`,children:[(0,Y.jsx)(`td`,{className:`py-1`,children:e}),(0,Y.jsx)(`td`,{className:`py-1 text-right tabular-nums`,children:t.count}),(0,Y.jsxs)(`td`,{className:`py-1 text-right tabular-nums`,children:[Z(t.p50),` / `,Z(t.p95),` / `,Z(t.max)]})]});return(0,Y.jsxs)(`div`,{className:`flex flex-col gap-2`,children:[(0,Y.jsxs)(`div`,{className:`flex items-center justify-between`,children:[(0,Y.jsxs)(`p`,{className:`text-xs text-muted-foreground`,children:[e.count,` `,v()]}),(0,Y.jsxs)(V,{variant:`outline`,size:`sm`,onClick:n,children:[t?(0,Y.jsx)(qe,{size:13,"aria-hidden":!0}):(0,Y.jsx)($e,{size:13,"aria-hidden":!0}),t?Ge():i()]})]}),(0,Y.jsxs)(`table`,{className:`w-full text-sm`,children:[(0,Y.jsx)(`thead`,{children:(0,Y.jsxs)(`tr`,{className:`text-left text-muted-foreground`,children:[(0,Y.jsx)(`th`,{className:`py-1 font-medium`,children:de()}),(0,Y.jsx)(`th`,{className:`py-1 text-right font-medium`,children:g()}),(0,Y.jsx)(`th`,{className:`py-1 text-right font-medium`,children:je()})]})}),(0,Y.jsxs)(`tbody`,{children:[a(_(),r.bridge),a(p(),r.A),a(le(),r.C)]})]}),(0,Y.jsx)(`p`,{className:`oc-admin__hint`,children:T()}),e.truncated?(0,Y.jsx)(`p`,{className:`oc-admin__hint`,children:ce()}):null,(0,Y.jsx)(`p`,{className:`oc-admin__hint`,children:m()})]})}var wt=[50,100,200,500],Tt=`all`,Q=`__all__`,Et=[`2xx`,`4xx`,`5xx`],Dt=[`user`,`service`,`system`],Ot=[`inbound`,`outbound`,`internal`],kt={kind:`relative`,from:`now-30d`,to:`now`},At=[{value:`kind`,label:`kind`},{value:`status`,label:`status`},{value:`latencyMs`,label:`latence (ms)`},{value:`principalType`,label:`principal`},{value:`direction`,label:`direction`},{value:`roleKey`,label:`rôle`},{value:`route`,label:`route`},{value:`correlationId`,label:`correlationId`}];function jt(){let e=et({from:`/settings/traces`}),t=at({from:`/settings/traces`}),n=e.limit,i=e.kind,s=e.statusClass??Q,d=e.principalType??Q,p=e.direction??Q,m=e.roleKey??Q,g=e.q??``,_=ut(e.from,e.to),v=(0,J.useMemo)(()=>ct(e.adv),[e.adv]),{from:y,to:b}=pt(_),[S,C]=(0,J.useState)(null),[w,T]=(0,J.useState)(null),ce=e=>void t({search:t=>({...t,limit:e})}),le=e=>void t({search:t=>({...t,kind:e})}),de=e=>void t({search:t=>({...t,q:e||void 0}),replace:!0}),me=e=>void t({search:t=>({...t,statusClass:e===Q?void 0:e})}),ge=e=>void t({search:t=>({...t,principalType:e===Q?void 0:e})}),E=e=>void t({search:t=>({...t,direction:e===Q?void 0:e})}),D=e=>void t({search:t=>({...t,roleKey:e===Q?void 0:e})}),be=e=>void t({search:t=>({...t,...nt(e)})}),O=e=>void t({search:t=>({...t,adv:it(e)}),replace:!0}),k=x(c.observability.listEvents,{limit:n}),A=x(c.observability.listEvents,{limit:n,kind:i===Tt?void 0:i,filter:{q:g||void 0,from:y,to:b,statusClass:s===Q?void 0:s,principalType:d===Q?void 0:d,direction:p===Q?void 0:p,roleKey:m===Q?void 0:m,advanced:v.length>0?v:void 0}}),j=(0,J.useMemo)(()=>{let e=new Set;for(let t of k??[])e.add(t.kind);return[...e].sort()},[k]),M=(0,J.useMemo)(()=>{let e=new Set;for(let t of k??[])t.roleKey&&e.add(t.roleKey);return[...e].sort()},[k]),N=g!==``||s!==Q||d!==Q||p!==Q||m!==Q||v.length>0||_.kind!==`relative`||_.from!==kt.from;function P(){t({search:{limit:100,kind:`all`},replace:!0})}let Oe=S?k?.filter(e=>e.correlationId===S):A,[F,I]=(0,J.useState)(`events`);return(0,Y.jsxs)(Xe,{value:F,onValueChange:e=>I(e),children:[(0,Y.jsxs)(Ye,{className:`w-full`,children:[(0,Y.jsxs)(z,{value:`latency`,className:`flex-1 gap-1.5`,children:[(0,Y.jsx)(Qe,{size:13,"aria-hidden":!0}),fe()]}),(0,Y.jsxs)(z,{value:`events`,className:`flex-1 gap-1.5`,children:[(0,Y.jsx)(vt,{size:13,"aria-hidden":!0}),ue()]})]}),(0,Y.jsx)(B,{value:`latency`,children:(0,Y.jsx)(bt,{})}),(0,Y.jsxs)(B,{value:`events`,className:`flex flex-col gap-3`,children:[(0,Y.jsxs)(`p`,{className:`oc-admin__hint`,children:[a(),(0,Y.jsx)(`strong`,{children:Ke()}),ae(),` `,(0,Y.jsx)(`span`,{className:`oc-filter__window`,children:ee()})]}),(0,Y.jsxs)(mt,{q:g,onQChange:de,searchPlaceholder:h(),timeRange:_,onTimeRangeChange:be,onReset:P,canReset:N,children:[(0,Y.jsxs)(q,{value:s,onValueChange:me,children:[(0,Y.jsx)(U,{size:`sm`,className:`w-32`,children:(0,Y.jsx)(H,{placeholder:f()})}),(0,Y.jsxs)(G,{children:[(0,Y.jsx)(K,{value:Q,children:ie()}),Et.map(e=>(0,Y.jsx)(K,{value:e,children:e},e))]})]}),(0,Y.jsxs)(q,{value:d,onValueChange:ge,children:[(0,Y.jsx)(U,{size:`sm`,className:`w-32`,children:(0,Y.jsx)(H,{placeholder:ne()})}),(0,Y.jsxs)(G,{children:[(0,Y.jsx)(K,{value:Q,children:te()}),Dt.map(e=>(0,Y.jsx)(K,{value:e,children:e},e))]})]}),(0,Y.jsxs)(q,{value:p,onValueChange:E,children:[(0,Y.jsx)(U,{size:`sm`,className:`w-32`,children:(0,Y.jsx)(H,{placeholder:we()})}),(0,Y.jsxs)(G,{children:[(0,Y.jsx)(K,{value:Q,children:r()}),Ot.map(e=>(0,Y.jsx)(K,{value:e,children:e},e))]})]}),(0,Y.jsxs)(q,{value:m,onValueChange:D,children:[(0,Y.jsx)(U,{size:`sm`,className:`w-36`,children:(0,Y.jsx)(H,{placeholder:Te()})}),(0,Y.jsxs)(G,{children:[(0,Y.jsx)(K,{value:Q,children:re()}),M.map(e=>(0,Y.jsx)(K,{value:e,children:e},e))]})]}),(0,Y.jsxs)(q,{value:i,onValueChange:le,children:[(0,Y.jsx)(U,{size:`sm`,className:`w-44`,children:(0,Y.jsx)(H,{placeholder:l()})}),(0,Y.jsxs)(G,{children:[(0,Y.jsx)(K,{value:Tt,children:u()}),j.map(e=>(0,Y.jsx)(K,{value:e,children:e},e))]})]}),(0,Y.jsxs)(q,{value:String(n),onValueChange:e=>ce(Number(e)),children:[(0,Y.jsx)(U,{size:`sm`,className:`w-28`,children:(0,Y.jsx)(H,{})}),(0,Y.jsx)(G,{children:wt.map(e=>(0,Y.jsx)(K,{value:String(e),children:se({count:e})},e))})]})]}),(0,Y.jsx)(ht,{fields:At,seed:v,onChange:O}),S?(0,Y.jsx)(`div`,{className:`oc-traces__followline`,children:(0,Y.jsxs)(`button`,{type:`button`,className:`oc-traces__chip`,onClick:()=>C(null),title:ze(),children:[(0,Y.jsxs)(`span`,{className:`oc-traces__chip-label`,children:[o(),(0,Y.jsx)(`code`,{children:$(S)})]}),(0,Y.jsx)(Je,{className:`oc-traces__chip-x`,"aria-hidden":!0}),(0,Y.jsx)(`span`,{className:`sr-only`,children:oe()})]})}):null,(0,Y.jsx)(gt,{title:Ve(),rows:Oe,emptyHint:S?_e():Ue(),columns:[{header:Le(),sort:e=>e.at,cell:e=>(0,Y.jsx)(`span`,{className:`oc-traces__time`,children:new Date(e.at).toLocaleString(`fr-FR`)})},{header:pe(),sort:e=>e.kind,cell:e=>(0,Y.jsx)(W,{variant:`secondary`,children:e.kind})},{header:Se(),sort:e=>Nt(e)??null,cell:e=>{let t=Nt(e);return t?(0,Y.jsxs)(`span`,{className:`oc-traces__fail`,title:t,children:[`✕ `,t]}):(0,Y.jsx)(`span`,{className:`oc-traces__ok`,"aria-label":Ce(),children:`✓`})}},{header:De(),sort:e=>e.direction,cell:e=>e.direction?(0,Y.jsx)(W,{variant:`outline`,children:e.direction}):(0,Y.jsx)(`span`,{className:`oc-traces__muted`,children:`—`})},{header:Ae(),sort:e=>e.principalType,cell:e=>(0,Y.jsxs)(`span`,{className:`oc-traces__principal`,children:[(0,Y.jsx)(W,{variant:`outline`,children:e.principalType}),e.principalId?(0,Y.jsx)(`code`,{className:`oc-traces__mono`,children:$(e.principalId)}):null]})},{header:xe(),sort:e=>e.roleKey,cell:e=>e.roleKey?(0,Y.jsx)(W,{variant:`secondary`,children:e.roleKey}):(0,Y.jsx)(`span`,{className:`oc-traces__muted`,children:`—`})},{header:ye(),sort:e=>e.route,cell:e=>e.route?(0,Y.jsxs)(`span`,{className:`oc-traces__route`,children:[e.method?(0,Y.jsx)(`span`,{className:`oc-traces__method`,children:e.method}):null,(0,Y.jsx)(`code`,{className:`oc-traces__mono`,children:e.route})]}):(0,Y.jsx)(`span`,{className:`oc-traces__muted`,children:`—`})},{header:Fe(),sort:e=>e.status,cell:e=>e.status===null?(0,Y.jsx)(`span`,{className:`oc-traces__muted`,children:`—`}):(0,Y.jsx)(`span`,{className:`oc-traces__status ${Mt(e.status)}`,children:e.status})},{header:Ee(),sort:e=>e.latencyMs,cell:e=>e.latencyMs===null?(0,Y.jsx)(`span`,{className:`oc-traces__muted`,children:`—`}):(0,Y.jsxs)(`span`,{className:`oc-traces__mono`,children:[e.latencyMs,` ms`]})},{header:ve(),sort:e=>e.correlationId,cell:e=>e.correlationId?(0,Y.jsx)(`button`,{type:`button`,className:`oc-traces__corr`,title:Ne(),onClick:()=>C(e.correlationId),children:$(e.correlationId)}):(0,Y.jsx)(`span`,{className:`oc-traces__muted`,children:`—`})},{header:ke(),sort:e=>+!!e.meta,cell:e=>e.meta?(0,Y.jsx)(V,{variant:`outline`,size:`sm`,onClick:()=>T(e),children:he()}):(0,Y.jsx)(`span`,{className:`oc-traces__muted`,children:`—`})}]}),(0,Y.jsx)(Pt,{row:w,onClose:()=>T(null)})]})]})}function Mt(e){return e>=500?`oc-traces__status--5xx`:e>=400?`oc-traces__status--4xx`:e>=200&&e<300?`oc-traces__status--2xx`:`oc-traces__status--other`}function $(e){return e.length>8?e.slice(0,8):e}function Nt(e){if(typeof e.status==`number`&&e.status>=400)return String(e.status);if(!e.meta)return null;try{let t=JSON.parse(e.meta);if(e.kind===`openclaw.dispatch`&&t.dispatchStatus===`failed`)return t.errorCode??`failed`;if(e.kind===`assistant.stream`&&t.phase===`finalize`&&(t.streamStatus===`error`||t.streamStatus===`aborted`))return t.streamStatus;if(e.kind===`openclaw.ingest.denied`)return`denied`}catch{}return null}function Pt({row:e,onClose:t}){let n=(0,J.useMemo)(()=>{if(!e?.meta)return``;try{return JSON.stringify(JSON.parse(e.meta),null,2)}catch{return e.meta}},[e]);return(0,Y.jsx)(tt,{open:e!==null,onOpenChange:e=>{e||t()},children:e?(0,Y.jsxs)(Ze,{className:`max-w-lg`,children:[(0,Y.jsxs)(st,{children:[(0,Y.jsxs)(dt,{className:`oc-traces__meta-title`,children:[j(),` `,(0,Y.jsx)(`code`,{children:e.kind}),(0,Y.jsx)(W,{variant:`outline`,children:Me()})]}),(0,Y.jsx)(rt,{children:Oe()})]}),(0,Y.jsx)(`pre`,{className:`oc-traces__meta-json`,children:n})]}):null})}export{jt as TracesTab};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as e,l as t,r as n}from"./bundle-mjs-C73ZY4La.js";import{$_ as r,Cf as i,DO as a,Df as o,Ef as s,J_ as c,NO as l,O_ as u,Of as d,PO as f,Q_ as p,Sf as m,Tf as h,X_ as g,Y_ as _,Z_ as ee,_f as v,_v as te,av as ne,bf as y,bv as b,cv as re,dv as ie,ev as ae,fv as oe,gf as x,gv as se,hv as ce,iv as le,lv as ue,mv as de,nv as fe,ov as pe,pv as me,q_ as S,rv as C,sv as w,tv as T,uv as he,vf as E,vv as ge,wf as D,xf as O,xv as k,yf as A,yv as j}from"./dist-DggIHtPt.js";import{t as M}from"./button-J0r_4wz5.js";import{$ as N,A as P,C as F,G as I,K as L,M as _e,Mt as ve,Q as R,S as z,W as B,X as V,Y as ye,_ as H,_t as U,b as W,d as G,et as be,f as xe,gt as K,j as Se,jt as Ce,nt as we,ot as Te,p as q,q as Ee,rt as De,x as J,y as Y}from"./index-BI4JM57h.js";import{t as X}from"./FilterBar-CHAmMDFh.js";import{t as Oe}from"./DataTableShell-B9cSAz8l.js";import{t as ke}from"./DetailChips-CWQEoST8.js";var Z=t(e(),1),Q=n();function Ae({profileId:e,userLabel:t,open:n,onOpenChange:r}){let i=f(a.agents.listAgentPoolForUser,n&&e?{profileId:e}:`skip`),c=f(a.agents.listUserAgents,n&&e?{profileId:e}:`skip`),l=new Set((c??[]).map(e=>`${e.instanceName}/${e.agentId}`)),u=(c??[]).find(e=>e.isDefault)??null,p=u?`${u.instanceName}/${u.agentId}`:null,m=new Set((i?.agents??[]).map(e=>`${e.instanceName}/${e.agentId}`)),g=[...(i?.agents??[]).map(e=>({...e,outOfPool:!1})),...(c??[]).filter(e=>!m.has(`${e.instanceName}/${e.agentId}`)).map(e=>({instanceName:e.instanceName,agentId:e.agentId,displayName:e.displayName,emoji:e.emoji,model:e.model,kind:e.kind,state:e.state,outOfPool:!0}))],_=new Map;for(let e of g){let t=_.get(e.instanceName)??[];t.push(e),_.set(e.instanceName,t)}return(0,Q.jsx)(R,{open:n,onOpenChange:r,children:(0,Q.jsxs)(N,{className:`oc-access`,children:[(0,Q.jsxs)(we,{children:[(0,Q.jsx)(De,{children:d({user:t})}),(0,Q.jsx)(be,{children:o()})]}),i?(0,Q.jsx)(`p`,{className:`oc-access__hint`,children:i.inGroup?s():h()}):null,(0,Q.jsx)(`div`,{className:`oc-access__list`,children:i===void 0?(0,Q.jsx)(`p`,{className:`oc-access__hint`,children:D()}):g.length===0?(0,Q.jsx)(`p`,{className:`oc-access__hint`,children:O()}):[..._.entries()].map(([t,n])=>(0,Q.jsx)(je,{profileId:e,instanceName:t,kind:n[0].kind,agents:n,assigned:l,defaultKey:p},t))})]})})}function je({profileId:e,instanceName:t,kind:n,agents:r,assigned:o,defaultKey:s}){let c=l(a.agents.assignAgent),u=l(a.agents.removeAgent),d=l(a.agents.setDefaultAgent),f=P();if(!e)return null;async function p(n,r){try{r?await u({profileId:e,instanceName:t,agentId:n}):await c({profileId:e,instanceName:t,agentId:n})}catch(e){f.error(i(),e)}}async function h(n){try{await d({profileId:e,instanceName:t,agentId:n})}catch(e){f.error(m(),e)}}return(0,Q.jsxs)(`div`,{className:`oc-access__group`,children:[(0,Q.jsxs)(`div`,{className:`oc-access__instance`,children:[(0,Q.jsx)(U,{size:13,"aria-hidden":!0}),(0,Q.jsx)(`span`,{children:t}),(0,Q.jsx)(V,{variant:`outline`,className:`oc-access__kind`,children:n})]}),r.map(e=>{let n=`${t}/${e.agentId}`,r=o.has(n),i=s===n,a=e.state===`deleted`;return(0,Q.jsxs)(`div`,{className:`oc-access__row`,children:[(0,Q.jsx)(H,{checked:r,disabled:a&&!r,onCheckedChange:()=>void p(e.agentId,r),"aria-label":y({name:e.displayName??e.agentId})}),(0,Q.jsxs)(`span`,{className:`oc-access__label`,children:[e.emoji?`${e.emoji} `:``,e.displayName??e.agentId]}),e.model?(0,Q.jsx)(`span`,{className:`oc-access__model`,children:e.model}):null,a?(0,Q.jsx)(V,{variant:`outline`,className:`oc-access__gone`,children:A()}):null,e.outOfPool?(0,Q.jsx)(V,{variant:`outline`,className:`oc-access__gone`,children:E()}):null,r?i?(0,Q.jsx)(`span`,{className:`oc-access__fav`,role:`img`,"aria-label":v(),title:v(),children:(0,Q.jsx)(K,{size:14,fill:`currentColor`})}):(0,Q.jsx)(M,{type:`button`,size:`icon-sm`,variant:`ghost`,className:`oc-access__setdefault`,"aria-label":x(),title:x(),onClick:()=>void h(e.agentId),children:(0,Q.jsx)(K,{size:14})}):null]},e.agentId)})]})}var $=`__all__`;function Me({granted:e,onToggle:t}){let n=new Set(e),r=G.filter(e=>n.has(q[e])).length;return(0,Q.jsxs)(B,{children:[(0,Q.jsx)(ye,{asChild:!0,children:(0,Q.jsx)(M,{variant:`outline`,size:`sm`,className:`h-8 w-36 justify-start font-normal`,children:r===0?k():b({count:r})})}),(0,Q.jsxs)(I,{align:`start`,className:`w-52`,children:[(0,Q.jsx)(Ee,{children:j()}),G.map(e=>{let r=q[e];return(0,Q.jsxs)(L,{className:`gap-2`,onSelect:e=>{e.preventDefault(),t(r)},children:[(0,Q.jsx)(H,{checked:n.has(r),"aria-hidden":!0,tabIndex:-1,className:`pointer-events-none`}),(0,Q.jsx)(`span`,{children:xe[e]??e})]},e)})]})]})}function Ne(){let e=ve({from:`/settings/users`}),t=Ce({from:`/settings/users`}),n=e.q??``,i=e.role??$,o=e=>void t({search:t=>({...t,q:e||void 0}),replace:!0}),s=e=>void t({search:t=>({...t,role:e===$?void 0:e})}),d=f(a.admin.listUsers,{filter:{q:n||void 0,role:i===$?void 0:i},withAgents:!0}),m=f(a.me.getMe,{host:Te}),h=l(a.admin.setRole),v=l(a.admin.setUserPermissions),y=l(a.admin.startImpersonation),b=l(a.admin.deleteUser),x=l(a.admin.setUserName),E=Se(),D=_e(),O=P(),[k,A]=(0,Z.useState)(null),j=(0,Z.useMemo)(()=>{let e=new Set([`pending`,`user`,`admin`]);for(let t of d??[])e.add(t.role);return[...e]},[d]),M=n!==``||i!==$;function N(){t({search:{},replace:!0})}async function I(e){try{await h(e)}catch(e){O.error(ge(),e)}}async function L(e){try{await v(e)}catch(e){O.error(te(),e)}}async function R(e){let t=e.email||e.name||e.canonical||e.userId.slice(0,8);if(await E({title:he(),description:ue({user:t}),confirmWord:re(),confirmLabel:w(),destructive:!0}))try{await b({profileId:e._id}),O.success(ne({user:t}))}catch(e){O.error(pe(),e)}}async function B(e){let t=e.email||e.name||e.userId.slice(0,8),n=await D({title:C(),label:fe({user:t}),placeholder:T(),defaultValue:e.name??``,confirmLabel:u()});if(n!==null)try{await x({profileId:e._id,name:n}),O.success(ae())}catch(e){O.error(r(),e)}}return(0,Q.jsxs)(Q.Fragment,{children:[(0,Q.jsx)(X,{q:n,onQChange:o,searchPlaceholder:se(),onReset:N,canReset:M,children:(0,Q.jsxs)(Y,{value:i,onValueChange:s,children:[(0,Q.jsx)(z,{size:`sm`,className:`w-36`,children:(0,Q.jsx)(F,{})}),(0,Q.jsxs)(W,{children:[(0,Q.jsx)(J,{value:$,children:ce()}),j.map(e=>(0,Q.jsx)(J,{value:e,children:e},e))]})]})}),(0,Q.jsx)(Oe,{title:de(),rows:d,emptyHint:me(),rowActions:e=>{let t=[{label:S(),onSelect:()=>A({profileId:e._id,label:e.email||e.name||e.canonical||e.userId.slice(0,8)})},{label:le(),onSelect:()=>void B(e)}];return e.userId!==m?.userId&&t.push({label:oe(),onSelect:()=>void y({profileId:e._id})},{label:ie(),variant:`destructive`,onSelect:()=>void R(e)}),t},columns:[{header:p(),cell:e=>{let t=e.email||e.name||e.canonical||e.userId.slice(0,8),n=e.email&&e.name&&e.name!==e.email?e.name:null;return(0,Q.jsxs)(`div`,{className:`flex flex-col`,children:[(0,Q.jsx)(`span`,{children:t}),n?(0,Q.jsx)(`span`,{className:`text-muted-foreground text-xs`,children:n}):null]})},sort:e=>e.email||e.name||e.canonical||e.userId},{header:ee(),sort:e=>e.role===`admin`?2:+(e.role===`user`),cell:e=>(0,Q.jsxs)(Y,{value:e.role,onValueChange:t=>void I({profileId:e._id,role:t}),children:[(0,Q.jsx)(z,{size:`sm`,className:`w-28`,children:(0,Q.jsx)(F,{})}),(0,Q.jsxs)(W,{children:[(0,Q.jsx)(J,{value:`pending`,children:`pending`}),(0,Q.jsx)(J,{value:`user`,children:`user`}),(0,Q.jsx)(J,{value:`admin`,children:`admin`})]})]})},{header:g(),sort:e=>e.role===`admin`?9999:e.extraPermissions?.length??0,cell:e=>e.role===`admin`?(0,Q.jsx)(`span`,{className:`text-muted-foreground text-xs`,children:_()}):(0,Q.jsx)(Me,{granted:e.extraPermissions??[],onToggle:t=>{let n=new Set(e.extraPermissions??[]);n.has(t)?n.delete(t):n.add(t),L({profileId:e._id,permissions:[...n]})}})},{header:c(),cell:e=>(0,Q.jsx)(ke,{icon:(0,Q.jsx)(U,{size:12,"aria-hidden":!0}),total:e.agentCount??0,items:e.agents.map(e=>({label:e}))}),sort:e=>e.agentCount??0}]}),(0,Q.jsx)(Ae,{profileId:k?.profileId??null,userLabel:k?.label??``,open:k!==null,onOpenChange:e=>{e||A(null)}})]})}export{Ne as UsersTab};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e,r as t}from"./bundle-mjs-C73ZY4La.js";import{
|
|
1
|
+
import{a as e,r as t}from"./bundle-mjs-C73ZY4La.js";import{SO as n,n as r,t as i}from"./dist-DggIHtPt.js";e();var a=t(),o=i(`group/button inline-flex shrink-0 items-center justify-center rounded-lg border border-transparent bg-clip-padding text-sm font-medium whitespace-nowrap transition-all outline-none select-none focus-visible:border-ring focus-visible:ring-3 focus-visible:ring-ring/50 active:not-aria-[haspopup]:translate-y-px disabled:pointer-events-none disabled:opacity-50 aria-invalid:border-destructive aria-invalid:ring-3 aria-invalid:ring-destructive/20 dark:aria-invalid:border-destructive/50 dark:aria-invalid:ring-destructive/40 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4`,{variants:{variant:{default:`bg-primary text-primary-foreground hover:bg-primary/80`,outline:`border-border bg-background hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:border-input dark:bg-input/30 dark:hover:bg-input/50`,secondary:`bg-secondary text-secondary-foreground hover:bg-[color-mix(in_oklch,var(--secondary),var(--foreground)_5%)] aria-expanded:bg-secondary aria-expanded:text-secondary-foreground`,ghost:`hover:bg-muted hover:text-foreground aria-expanded:bg-muted aria-expanded:text-foreground dark:hover:bg-muted/50`,destructive:`bg-destructive/10 text-destructive hover:bg-destructive/20 focus-visible:border-destructive/40 focus-visible:ring-destructive/20 dark:bg-destructive/20 dark:hover:bg-destructive/30 dark:focus-visible:ring-destructive/40`,link:`text-primary underline-offset-4 hover:underline`},size:{default:`h-8 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2`,xs:`h-6 gap-1 rounded-[min(var(--radius-md),10px)] px-2 text-xs in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3`,sm:`h-7 gap-1 rounded-[min(var(--radius-md),12px)] px-2.5 text-[0.8rem] in-data-[slot=button-group]:rounded-lg has-data-[icon=inline-end]:pr-1.5 has-data-[icon=inline-start]:pl-1.5 [&_svg:not([class*='size-'])]:size-3.5`,lg:`h-9 gap-1.5 px-2.5 has-data-[icon=inline-end]:pr-2 has-data-[icon=inline-start]:pl-2`,icon:`size-8`,"icon-xs":`size-6 rounded-[min(var(--radius-md),10px)] in-data-[slot=button-group]:rounded-lg [&_svg:not([class*='size-'])]:size-3`,"icon-sm":`size-7 rounded-[min(var(--radius-md),12px)] in-data-[slot=button-group]:rounded-lg`,"icon-lg":`size-9`}},defaultVariants:{variant:`default`,size:`default`}});function s({className:e,variant:t=`default`,size:i=`default`,asChild:s=!1,...c}){return(0,a.jsx)(s?n:`button`,{"data-slot":`button`,"data-variant":t,"data-size":i,className:r(o({variant:t,size:i,className:e})),...c})}export{o as n,s as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e,r as t}from"./bundle-mjs-C73ZY4La.js";import{n}from"./dist-
|
|
1
|
+
import{a as e,r as t}from"./bundle-mjs-C73ZY4La.js";import{n}from"./dist-DggIHtPt.js";e();var r=t();function i({className:e,size:t=`default`,...i}){return(0,r.jsx)(`div`,{"data-slot":`card`,"data-size":t,className:n(`group/card flex flex-col gap-4 overflow-hidden rounded-xl bg-card py-4 text-sm text-card-foreground ring-1 ring-foreground/10 has-data-[slot=card-footer]:pb-0 has-[>img:first-child]:pt-0 data-[size=sm]:gap-3 data-[size=sm]:py-3 data-[size=sm]:has-data-[slot=card-footer]:pb-0 *:[img:first-child]:rounded-t-xl *:[img:last-child]:rounded-b-xl`,e),...i})}function a({className:e,...t}){return(0,r.jsx)(`div`,{"data-slot":`card-header`,className:n(`group/card-header @container/card-header grid auto-rows-min items-start gap-1 rounded-t-xl px-4 group-data-[size=sm]/card:px-3 has-data-[slot=card-action]:grid-cols-[1fr_auto] has-data-[slot=card-description]:grid-rows-[auto_auto] [.border-b]:pb-4 group-data-[size=sm]/card:[.border-b]:pb-3`,e),...t})}function o({className:e,...t}){return(0,r.jsx)(`div`,{"data-slot":`card-title`,className:n(`font-heading text-base leading-snug font-medium group-data-[size=sm]/card:text-sm`,e),...t})}function s({className:e,...t}){return(0,r.jsx)(`div`,{"data-slot":`card-description`,className:n(`text-sm text-muted-foreground`,e),...t})}function c({className:e,...t}){return(0,r.jsx)(`div`,{"data-slot":`card-content`,className:n(`px-4 group-data-[size=sm]/card:px-3`,e),...t})}function l({className:e,...t}){return(0,r.jsx)(`div`,{"data-slot":`card-footer`,className:n(`flex items-center rounded-b-xl border-t bg-muted/50 p-4 group-data-[size=sm]/card:p-3`,e),...t})}export{a,l as i,c as n,o,s as r,i as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{OO as e}from"./dist-DggIHtPt.js";var t=e(`chevrons-up-down`,[[`path`,{d:`m7 15 5 5 5-5`,key:`1hf1tw`}],[`path`,{d:`m7 9 5-5 5 5`,key:`sgt6xg`}]]);export{t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{
|
|
1
|
+
import{Hr as e,Mr as t,Nr as n,Or as r,jr as i,kr as a}from"./dist-DggIHtPt.js";var o=e=>typeof e==`string`?e:null;function s(e){return/^\d+\.\d+\.\d+$/.test(e)?e.split(`.`).map(e=>Number.parseInt(e,10)):null}function c(e,t){let n=s(e),r=s(t);if(n===null||r===null)return null;for(let e=0;e<3;e++){let t=n[e]-r[e];if(t!==0)return t}return 0}function l(e,t){if(e===null||t===null)return!1;let n=c(t,e.min);return n!==null&&n>=0}function u(e,t){let n={range:null,validatedVersions:[]};if(typeof e!=`object`||!e)return n;let r=e.providers;if(typeof r!=`object`||!r)return n;let i=r[t];if(typeof i!=`object`||!i)return n;let a=i,s=null;if(typeof a.supportedRange==`object`&&a.supportedRange!==null){let e=a.supportedRange,t=o(e.min),n=o(e.maxValidated);t!==null&&n!==null&&(s={min:t,maxValidated:n})}let c=Array.isArray(a.validatedVersions)?a.validatedVersions.filter(e=>typeof e==`string`):[];return{range:s,validatedVersions:c}}function d(e,t,n){if(e===null)return`unknown`;let{range:r}=u(n,t);return l(r,e)?r!==null&&(c(e,r.maxValidated)??0)>0?`beyond`:`supported`:`unknown`}function f(e){return e===`supported`?n():e===`beyond`?t():i()}function p(t){return t??e()}function m(e){return e===null?r():a({version:e})}function h(e,t){if(typeof e!=`object`||!e)return!1;let n=e.providers;return typeof n!=`object`||!n?!1:t in n}export{p as a,m as i,h as n,c as o,f as r,u as s,d as t};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{$s as e,Gs as t,Js as n,Ks as r,Qs as i,Ws as a,Xs as o,Ys as s,Zs as c,_c as l,ac as u,cc as d,dc as f,ec as p,fc as m,gc as h,hc as g,ic as _,lc as v,mc as y,nc as b,oc as x,pc as S,qs as C,rc as w,sc as T,tc as E,uc as D,vc as O}from"./dist-DggIHtPt.js";var k={AGENT_NOT_FOUND:()=>({label:O(),hint:l()}),AUTH_TOKEN_MISMATCH:()=>({label:h(),hint:g()}),DEVICE_SIGNING_FAILED:()=>({label:y(),hint:S()}),SESSION_SCOPE_DENIED:()=>({label:m(),hint:f()}),GATEWAY_TIMEOUT:()=>({label:D(),hint:v()}),GATEWAY_DISCONNECTED:()=>({label:d(),hint:T()}),ATTACHMENT_TOO_LARGE:()=>({label:_(),hint:w()}),ATTACHMENT_REJECTED:()=>({label:b(),hint:E()}),BRIDGE_UNREACHABLE:()=>({label:x(),hint:u()}),INVALID_REQUEST:()=>({label:p(),hint:e()}),NOT_CONFIGURED:()=>({label:i(),hint:c()}),UNROUTED:()=>({label:o(),hint:s()}),UPSTREAM_ERROR:()=>({label:n(),hint:C()}),UNKNOWN:()=>({label:r(),hint:t()})};function A(e){return e?k[e]?.()??{label:e,hint:a()}:k.UNKNOWN()}export{A as t};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as e,l as t}from"./bundle-mjs-C73ZY4La.js";import{
|
|
1
|
+
import{a as e,l as t}from"./bundle-mjs-C73ZY4La.js";import{OO as n}from"./dist-DggIHtPt.js";var r=n(`check`,[[`path`,{d:`M20 6 9 17l-5-5`,key:`1gmf2c`}]]),i=t(e(),1);function a(e){let t=i.useRef({value:e,previous:e});return i.useMemo(()=>(t.current.value!==e&&(t.current.previous=t.current.value,t.current.value=e),t.current.previous),[e])}export{r as n,a as t};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as e,l as t,r as n}from"./bundle-mjs-C73ZY4La.js";import{
|
|
1
|
+
import{a as e,l as t,r as n}from"./bundle-mjs-C73ZY4La.js";import{CO as r,EO as i,aO as a,bO as o,cO as s,dO as c,fO as l,gO as u,hO as d,lO as f,oO as p,pO as m,sO as h,uO as g,yO as _}from"./dist-DggIHtPt.js";var v=t(e(),1),y=n(),b=`Dialog`,[x,S]=u(b),[C,w]=x(b),T=e=>{let{__scopeDialog:t,children:n,open:r,defaultOpen:i,onOpenChange:a,modal:o=!0}=e,s=v.useRef(null),l=v.useRef(null),[u,d]=m({prop:r,defaultProp:i??!1,onChange:a,caller:b});return(0,y.jsx)(C,{scope:t,triggerRef:s,contentRef:l,contentId:c(),titleId:c(),descriptionId:c(),open:u,onOpenChange:d,onOpenToggle:v.useCallback(()=>d(e=>!e),[d]),modal:o,children:n})};T.displayName=b;var E=`DialogTrigger`,D=v.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,a=w(E,n),s=i(t,a.triggerRef);return(0,y.jsx)(o.button,{type:`button`,"aria-haspopup":`dialog`,"aria-expanded":a.open,"aria-controls":a.open?a.contentId:void 0,"data-state":q(a.open),...r,ref:s,onClick:_(e.onClick,a.onOpenToggle)})});D.displayName=E;var O=`DialogPortal`,[k,A]=x(O,{forceMount:void 0}),j=e=>{let{__scopeDialog:t,forceMount:n,children:r,container:i}=e,a=w(O,t);return(0,y.jsx)(k,{scope:t,forceMount:n,children:v.Children.map(r,e=>(0,y.jsx)(l,{present:n||a.open,children:(0,y.jsx)(s,{asChild:!0,container:i,children:e})}))})};j.displayName=O;var M=`DialogOverlay`,N=v.forwardRef((e,t)=>{let n=A(M,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=w(M,e.__scopeDialog);return a.modal?(0,y.jsx)(l,{present:r||a.open,children:(0,y.jsx)(F,{...i,ref:t})}):null});N.displayName=M;var P=r(`DialogOverlay.RemoveScroll`),F=v.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=w(M,n);return(0,y.jsx)(p,{as:P,allowPinchZoom:!0,shards:[i.contentRef],children:(0,y.jsx)(o.div,{"data-state":q(i.open),...r,ref:t,style:{pointerEvents:`auto`,...r.style}})})}),I=`DialogContent`,L=v.forwardRef((e,t)=>{let n=A(I,e.__scopeDialog),{forceMount:r=n.forceMount,...i}=e,a=w(I,e.__scopeDialog);return(0,y.jsx)(l,{present:r||a.open,children:a.modal?(0,y.jsx)(R,{...i,ref:t}):(0,y.jsx)(z,{...i,ref:t})})});L.displayName=I;var R=v.forwardRef((e,t)=>{let n=w(I,e.__scopeDialog),r=v.useRef(null),o=i(t,n.contentRef,r);return v.useEffect(()=>{let e=r.current;if(e)return a(e)},[]),(0,y.jsx)(B,{...e,ref:o,trapFocus:n.open,disableOutsidePointerEvents:n.open,onCloseAutoFocus:_(e.onCloseAutoFocus,e=>{e.preventDefault(),n.triggerRef.current?.focus()}),onPointerDownOutside:_(e.onPointerDownOutside,e=>{let t=e.detail.originalEvent,n=t.button===0&&t.ctrlKey===!0;(t.button===2||n)&&e.preventDefault()}),onFocusOutside:_(e.onFocusOutside,e=>e.preventDefault())})}),z=v.forwardRef((e,t)=>{let n=w(I,e.__scopeDialog),r=v.useRef(!1),i=v.useRef(!1);return(0,y.jsx)(B,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{e.onCloseAutoFocus?.(t),t.defaultPrevented||(r.current||n.triggerRef.current?.focus(),t.preventDefault()),r.current=!1,i.current=!1},onInteractOutside:t=>{e.onInteractOutside?.(t),t.defaultPrevented||(r.current=!0,t.detail.originalEvent.type===`pointerdown`&&(i.current=!0));let a=t.target;n.triggerRef.current?.contains(a)&&t.preventDefault(),t.detail.originalEvent.type===`focusin`&&i.current&&t.preventDefault()}})}),B=v.forwardRef((e,t)=>{let{__scopeDialog:n,trapFocus:r,onOpenAutoFocus:a,onCloseAutoFocus:o,...s}=e,c=w(I,n),l=v.useRef(null),u=i(t,l);return h(),(0,y.jsxs)(y.Fragment,{children:[(0,y.jsx)(f,{asChild:!0,loop:!0,trapped:r,onMountAutoFocus:a,onUnmountAutoFocus:o,children:(0,y.jsx)(g,{role:`dialog`,id:c.contentId,"aria-describedby":c.descriptionId,"aria-labelledby":c.titleId,"data-state":q(c.open),...s,ref:u,onDismiss:()=>c.onOpenChange(!1)})}),(0,y.jsxs)(y.Fragment,{children:[(0,y.jsx)(Z,{titleId:c.titleId}),(0,y.jsx)($,{contentRef:l,descriptionId:c.descriptionId})]})]})}),V=`DialogTitle`,H=v.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=w(V,n);return(0,y.jsx)(o.h2,{id:i.titleId,...r,ref:t})});H.displayName=V;var U=`DialogDescription`,W=v.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=w(U,n);return(0,y.jsx)(o.p,{id:i.descriptionId,...r,ref:t})});W.displayName=U;var G=`DialogClose`,K=v.forwardRef((e,t)=>{let{__scopeDialog:n,...r}=e,i=w(G,n);return(0,y.jsx)(o.button,{type:`button`,...r,ref:t,onClick:_(e.onClick,()=>i.onOpenChange(!1))})});K.displayName=G;function q(e){return e?`open`:`closed`}var J=`DialogTitleWarning`,[Y,X]=d(J,{contentName:I,titleName:V,docsSlug:`dialog`}),Z=({titleId:e})=>{let t=X(J),n=`\`${t.contentName}\` requires a \`${t.titleName}\` for the component to be accessible for screen reader users.
|
|
2
2
|
|
|
3
3
|
If you want to hide the \`${t.titleName}\`, you can wrap it with our VisuallyHidden component.
|
|
4
4
|
|