morpheus-cli 0.9.20 → 0.9.22
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/http/api.js +3 -0
- package/dist/http/middleware/auth.js +2 -1
- package/dist/http/routers/display.js +33 -0
- package/dist/runtime/display.js +17 -2
- package/dist/ui/assets/{AuditDashboard-Cu33zb_7.js → AuditDashboard-z3OBbJ8I.js} +1 -1
- package/dist/ui/assets/{Chat-mt1j5V55.js → Chat-aFz9FjrD.js} +7 -7
- package/dist/ui/assets/{Chronos-Bq_h41cw.js → Chronos-MP_NCj2A.js} +1 -1
- package/dist/ui/assets/{ConfirmationModal-CxLP8iC6.js → ConfirmationModal-B3gHIVKY.js} +1 -1
- package/dist/ui/assets/Dashboard-OyZXnj44.js +4120 -0
- package/dist/ui/assets/{DeleteConfirmationModal-kZ_c3sFk.js → DeleteConfirmationModal-D8QsQzwP.js} +1 -1
- package/dist/ui/assets/{Documents-nlQNoUcq.js → Documents-B8g_yv4f.js} +1 -1
- package/dist/ui/assets/{Logs-C1tlg574.js → Logs-BWufAtHa.js} +1 -1
- package/dist/ui/assets/{MCPManager-Do7isizG.js → MCPManager-lLoGEyBy.js} +1 -1
- package/dist/ui/assets/{ModelPricing-BeJ7oXBA.js → ModelPricing-CuYIUwXt.js} +1 -1
- package/dist/ui/assets/Notifications-nI--fmYx.js +1 -0
- package/dist/ui/assets/{Pagination-BHZKk42X.js → Pagination-D4ShqUKO.js} +1 -1
- package/dist/ui/assets/SatiMemories-DO3JDQBi.js +1 -0
- package/dist/ui/assets/{SelectInput-KVLsnfra.js → SelectInput-BPDcd3y7.js} +1 -1
- package/dist/ui/assets/{SessionAudit-Da1ySlYg.js → SessionAudit-BWtJRkj1.js} +1 -1
- package/dist/ui/assets/{Settings-DpXwpEhO.js → Settings-CblauAVd.js} +1 -1
- package/dist/ui/assets/Skills-Dw6G5c8W.js +7 -0
- package/dist/ui/assets/{Smiths-DA-x4KFT.js → Smiths-B6-CnRMv.js} +1 -1
- package/dist/ui/assets/{Switch-CJTE4ZQm.js → Switch-C7TxLq0E.js} +1 -1
- package/dist/ui/assets/Tasks-DzUyw5z3.js +1 -0
- package/dist/ui/assets/{TrinityDatabases-CoKzKTL-.js → TrinityDatabases-DCjdwnLH.js} +1 -1
- package/dist/ui/assets/{UsageStats-cds352Pj.js → UsageStats-VajzjndO.js} +1 -1
- package/dist/ui/assets/{WebhookManager-DdAdHQUk.js → WebhookManager-BbfMCiy-.js} +2 -2
- package/dist/ui/assets/{agents-B1z_dlQC.js → agents-CN_AKX_I.js} +1 -1
- package/dist/ui/assets/{audit-BAhaGrKY.js → audit-M-5UGwoK.js} +1 -1
- package/dist/ui/assets/{chronos-DGD_Md9M.js → chronos-mZ0RIvh4.js} +1 -1
- package/dist/ui/assets/{config-BwTXe5M2.js → config-7LGRnJ26.js} +1 -1
- package/dist/ui/assets/index-Bko2TlZY.css +1 -0
- package/dist/ui/assets/{index-BcX5O7kY.js → index-Db1XEN8v.js} +3 -3
- package/dist/ui/assets/{mcp-BlkruPaA.js → mcp-YiYC-9IH.js} +1 -1
- package/dist/ui/assets/{skills-CtCb-52u.js → skills-dc6Xqqhb.js} +1 -1
- package/dist/ui/assets/{stats-BiPI2kaw.js → stats-BzqxCDuj.js} +1 -1
- package/dist/ui/assets/{useCurrency-BCdG-pHx.js → useCurrency-CEc5edm2.js} +1 -1
- package/dist/ui/assets/vendor-icons-DE7PWdkN.js +1 -0
- package/dist/ui/assets/vendor-utils-BIYveU_1.js +39 -0
- package/dist/ui/index.html +4 -4
- package/dist/ui/sw.js +1 -1
- package/package.json +1 -1
- package/dist/ui/assets/Dashboard-D0LAlHtG.js +0 -1
- package/dist/ui/assets/Notifications-Cg5CMlY0.js +0 -1
- package/dist/ui/assets/SatiMemories-D9l6s8Pc.js +0 -1
- package/dist/ui/assets/Skills-DaqCY8QH.js +0 -7
- package/dist/ui/assets/Tasks-DU49M9U-.js +0 -1
- package/dist/ui/assets/index-Cjli-AD7.css +0 -1
- package/dist/ui/assets/vendor-icons-NHF9HNeN.js +0 -1
- package/dist/ui/assets/vendor-utils-D4NnWbOU.js +0 -39
|
@@ -1 +1 @@
|
|
|
1
|
-
import{H as c}from"./index-
|
|
1
|
+
import{H as c}from"./index-Db1XEN8v.js";const e=c.getInstance(),n={fetchServers:async()=>e.get("/mcp/servers"),addServer:async(t,s)=>e.post("/mcp/servers",{name:t,config:s}),updateServer:async(t,s)=>e.put(`/mcp/servers/${encodeURIComponent(t)}`,{config:s}),deleteServer:async t=>e.delete(`/mcp/servers/${encodeURIComponent(t)}`),toggleServer:async(t,s)=>e.patch(`/mcp/servers/${encodeURIComponent(t)}/toggle`,{enabled:s}),reloadTools:async()=>e.post("/mcp/reload",{}),fetchStatus:async()=>e.get("/mcp/status"),fetchStats:async()=>e.get("/mcp/stats")};export{n as m};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{H as e}from"./index-
|
|
1
|
+
import{H as e}from"./index-Db1XEN8v.js";const s=e.getInstance(),o={fetchSkills:async()=>s.get("/skills"),fetchSkill:async l=>s.get(`/skills/${encodeURIComponent(l)}`),reloadSkills:async()=>s.post("/skills/reload",{}),enableSkill:async l=>s.post(`/skills/${encodeURIComponent(l)}/enable`,{}),disableSkill:async l=>s.post(`/skills/${encodeURIComponent(l)}/disable`,{}),uploadSkill:async l=>s.uploadFile("/skills/upload",l)};export{o as s};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{h as t}from"./index-
|
|
1
|
+
import{h as t}from"./index-Db1XEN8v.js";const e={fetchUsageStats:async()=>t.get("/stats/usage"),fetchGroupedUsageStats:async()=>t.get("/stats/usage/grouped")};export{e as s};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import{u as f}from"./vendor-utils-
|
|
1
|
+
import{u as f}from"./vendor-utils-BIYveU_1.js";import{c as $}from"./config-7LGRnJ26.js";const y={code:"USD",symbol:"$",rate:1};function m(){const{data:c}=f("config/currency",()=>$.fetchConfig(),{revalidateOnFocus:!1,dedupingInterval:6e4}),r=c?.currency?{code:c.currency.code,symbol:c.currency.symbol,rate:c.currency.rate}:y,n=r.code==="USD"||r.rate===1;function s(t){if(t==null||t===0)return"—";const e=t<1e-4?"<$0.0001":`$${t.toFixed(4)}`;if(n)return e;const o=t*r.rate,u=o<1e-4?`<${r.symbol}0.0001`:`${r.symbol}${o.toFixed(4)}`;return`${e} / ${u}`}function i(t){const e=`$${t.toFixed(4)}`;if(n)return e;const o=t*r.rate;return`${e} / ${r.symbol}${o.toFixed(4)}`}return{currency:r,isUSD:n,fmtCost:s,fmtPrice:i}}export{m as u};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{r as n}from"./vendor-react-DikRIOlj.js";const k=(...t)=>t.filter((a,o,c)=>!!a&&a.trim()!==""&&c.indexOf(a)===o).join(" ").trim();const _=t=>t.replace(/([a-z0-9])([A-Z])/g,"$1-$2").toLowerCase();const M=t=>t.replace(/^([A-Z])|[\s-_]+(\w)/g,(a,o,c)=>c?c.toUpperCase():o.toLowerCase());const y=t=>{const a=M(t);return a.charAt(0).toUpperCase()+a.slice(1)};var x={xmlns:"http://www.w3.org/2000/svg",width:24,height:24,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor",strokeWidth:2,strokeLinecap:"round",strokeLinejoin:"round"};const m=t=>{for(const a in t)if(a.startsWith("aria-")||a==="role"||a==="title")return!0;return!1};const v=n.forwardRef(({color:t="currentColor",size:a=24,strokeWidth:o=2,absoluteStrokeWidth:c,className:s="",children:h,iconNode:i,...d},p)=>n.createElement("svg",{ref:p,...x,width:a,height:a,stroke:t,strokeWidth:c?Number(o)*24/Number(a):o,className:k("lucide",s),...!h&&!m(d)&&{"aria-hidden":"true"},...d},[...i.map(([r,l])=>n.createElement(r,l)),...Array.isArray(h)?h:[h]]));const e=(t,a)=>{const o=n.forwardRef(({className:c,...s},h)=>n.createElement(v,{ref:h,iconNode:a,className:k(`lucide-${_(y(t))}`,`lucide-${t}`,c),...s}));return o.displayName=y(t),o};const g=[["path",{d:"M22 12h-2.48a2 2 0 0 0-1.93 1.46l-2.35 8.36a.25.25 0 0 1-.48 0L9.24 2.18a.25.25 0 0 0-.48 0l-2.35 8.36A2 2 0 0 1 4.49 12H2",key:"169zse"}]],o2=e("activity",g);const f=[["rect",{width:"20",height:"5",x:"2",y:"3",rx:"1",key:"1wp1u1"}],["path",{d:"M4 8v11a2 2 0 0 0 2 2h12a2 2 0 0 0 2-2V8",key:"1s80jp"}],["path",{d:"M10 12h4",key:"a56b0p"}]],c2=e("archive",f);const u=[["path",{d:"m12 19-7-7 7-7",key:"1l729n"}],["path",{d:"M19 12H5",key:"x3x0zl"}]],h2=e("arrow-left",u);const w=[["path",{d:"M4.929 4.929 19.07 19.071",key:"196cmz"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],n2=e("ban",w);const $=[["path",{d:"M10.268 21a2 2 0 0 0 3.464 0",key:"vwvbt9"}],["path",{d:"M3.262 15.326A1 1 0 0 0 4 17h16a1 1 0 0 0 .74-1.673C19.41 13.956 18 12.499 18 8A6 6 0 0 0 6 8c0 4.499-1.411 5.956-2.738 7.326",key:"11g9vi"}]],s2=e("bell",$);const N=[["path",{d:"M12 8V4H8",key:"hb8ula"}],["rect",{width:"16",height:"12",x:"4",y:"8",rx:"2",key:"enze0r"}],["path",{d:"M2 14h2",key:"vft8re"}],["path",{d:"M20 14h2",key:"4cs60a"}],["path",{d:"M15 13v2",key:"1xurst"}],["path",{d:"M9 13v2",key:"rq6x2g"}]],d2=e("bot",N);const z=[["path",{d:"M21 8a2 2 0 0 0-1-1.73l-7-4a2 2 0 0 0-2 0l-7 4A2 2 0 0 0 3 8v8a2 2 0 0 0 1 1.73l7 4a2 2 0 0 0 2 0l7-4A2 2 0 0 0 21 16Z",key:"hh9hay"}],["path",{d:"m3.3 7 8.7 5 8.7-5",key:"g66t2b"}],["path",{d:"M12 22V12",key:"d0xqtd"}]],y2=e("box",z);const b=[["path",{d:"M12 18V5",key:"adv99a"}],["path",{d:"M15 13a4.17 4.17 0 0 1-3-4 4.17 4.17 0 0 1-3 4",key:"1e3is1"}],["path",{d:"M17.598 6.5A3 3 0 1 0 12 5a3 3 0 1 0-5.598 1.5",key:"1gqd8o"}],["path",{d:"M17.997 5.125a4 4 0 0 1 2.526 5.77",key:"iwvgf7"}],["path",{d:"M18 18a4 4 0 0 0 2-7.464",key:"efp6ie"}],["path",{d:"M19.967 17.483A4 4 0 1 1 12 18a4 4 0 1 1-7.967-.517",key:"1gq6am"}],["path",{d:"M6 18a4 4 0 0 1-2-7.464",key:"k1g0md"}],["path",{d:"M6.003 5.125a4 4 0 0 0-2.526 5.77",key:"q97ue3"}]],k2=e("brain",b);const q=[["path",{d:"M8 2v4",key:"1cmpym"}],["path",{d:"M16 2v4",key:"4m81vk"}],["rect",{width:"18",height:"18",x:"3",y:"4",rx:"2",key:"1hopcy"}],["path",{d:"M3 10h18",key:"8toen8"}]],i2=e("calendar",q);const C=[["path",{d:"M3 3v16a2 2 0 0 0 2 2h16",key:"c24i48"}],["path",{d:"M18 17V9",key:"2bz60n"}],["path",{d:"M13 17V5",key:"1frdt8"}],["path",{d:"M8 17v-3",key:"17ska0"}]],p2=e("chart-column",C);const A=[["path",{d:"M5 21v-6",key:"1hz6c0"}],["path",{d:"M12 21V3",key:"1lcnhd"}],["path",{d:"M19 21V9",key:"unv183"}]],r2=e("chart-no-axes-column",A);const j=[["path",{d:"M18 6 7 17l-5-5",key:"116fxf"}],["path",{d:"m22 10-7.5 7.5L13 16",key:"ke71qq"}]],l2=e("check-check",j);const L=[["path",{d:"M20 6 9 17l-5-5",key:"1gmf2c"}]],_2=e("check",L);const H=[["path",{d:"m6 9 6 6 6-6",key:"qrunsl"}]],M2=e("chevron-down",H);const V=[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]],x2=e("chevron-left",V);const S=[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]],m2=e("chevron-right",S);const P=[["path",{d:"m18 15-6-6-6 6",key:"153udz"}]],v2=e("chevron-up",P);const B=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["line",{x1:"12",x2:"12",y1:"8",y2:"12",key:"1pkeuh"}],["line",{x1:"12",x2:"12.01",y1:"16",y2:"16",key:"4dfq90"}]],g2=e("circle-alert",B);const R=[["path",{d:"M21.801 10A10 10 0 1 1 17 3.335",key:"yps3ct"}],["path",{d:"m9 11 3 3L22 4",key:"1pflzl"}]],f2=e("circle-check-big",R);const T=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],u2=e("circle-check",T);const W=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"m15 9-6 6",key:"1uzhvr"}],["path",{d:"m9 9 6 6",key:"z0biqf"}]],w2=e("circle-x",W);const D=[["path",{d:"M12 6v6l4 2",key:"mmk7yg"}],["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}]],$2=e("clock",D);const E=[["path",{d:"M13 16a3 3 0 0 1 0 6H7a5 5 0 1 1 4.9-6z",key:"ie2ih4"}],["path",{d:"M18.376 14.512a6 6 0 0 0 3.461-4.127c.148-.625-.659-.97-1.248-.714a4 4 0 0 1-5.259-5.26c.255-.589-.09-1.395-.716-1.248a6 6 0 0 0-4.594 5.36",key:"zwnc1e"}]],N2=e("cloud-moon",E);const U=[["rect",{width:"14",height:"14",x:"8",y:"8",rx:"2",ry:"2",key:"17jyea"}],["path",{d:"M4 16c-1.1 0-2-.9-2-2V4c0-1.1.9-2 2-2h10c1.1 0 2 .9 2 2",key:"zix9uf"}]],z2=e("copy",U);const O=[["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M17 20v2",key:"1rnc9c"}],["path",{d:"M17 2v2",key:"11trls"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M2 17h2",key:"7oei6x"}],["path",{d:"M2 7h2",key:"asdhe0"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"M20 17h2",key:"1fpfkl"}],["path",{d:"M20 7h2",key:"1o8tra"}],["path",{d:"M7 20v2",key:"4gnj0m"}],["path",{d:"M7 2v2",key:"1i4yhu"}],["rect",{x:"4",y:"4",width:"16",height:"16",rx:"2",key:"1vbyd7"}],["rect",{x:"8",y:"8",width:"8",height:"8",rx:"1",key:"z9xiuo"}]],b2=e("cpu",O);const F=[["ellipse",{cx:"12",cy:"5",rx:"9",ry:"3",key:"msslwz"}],["path",{d:"M3 5V19A9 3 0 0 0 21 19V5",key:"1wlel7"}],["path",{d:"M3 12A9 3 0 0 0 21 12",key:"mv7ke4"}]],q2=e("database",F);const Z=[["line",{x1:"12",x2:"12",y1:"2",y2:"22",key:"7eqyqh"}],["path",{d:"M17 5H9.5a3.5 3.5 0 0 0 0 7h5a3.5 3.5 0 0 1 0 7H6",key:"1b0p4s"}]],C2=e("dollar-sign",Z);const I=[["path",{d:"M12 15V3",key:"m9g1x1"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}],["path",{d:"m7 10 5 5 5-5",key:"brsn70"}]],A2=e("download",I);const G=[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"M10 14 21 3",key:"gplh6r"}],["path",{d:"M18 13v6a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2V8a2 2 0 0 1 2-2h6",key:"a6xqqp"}]],j2=e("external-link",G);const K=[["path",{d:"M2.062 12.348a1 1 0 0 1 0-.696 10.75 10.75 0 0 1 19.876 0 1 1 0 0 1 0 .696 10.75 10.75 0 0 1-19.876 0",key:"1nclc0"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],L2=e("eye",K);const X=[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 12a1 1 0 0 0-1 1v1a1 1 0 0 1-1 1 1 1 0 0 1 1 1v1a1 1 0 0 0 1 1",key:"1oajmo"}],["path",{d:"M14 18a1 1 0 0 0 1-1v-1a1 1 0 0 1 1-1 1 1 0 0 1-1-1v-1a1 1 0 0 0-1-1",key:"mpwhp6"}]],H2=e("file-braces",X);const J=[["path",{d:"M6 22a2 2 0 0 1-2-2V4a2 2 0 0 1 2-2h8a2.4 2.4 0 0 1 1.704.706l3.588 3.588A2.4 2.4 0 0 1 20 8v12a2 2 0 0 1-2 2z",key:"1oefj6"}],["path",{d:"M14 2v5a1 1 0 0 0 1 1h5",key:"wfsgrz"}],["path",{d:"M10 9H8",key:"b1mrlr"}],["path",{d:"M16 13H8",key:"t4e002"}],["path",{d:"M16 17H8",key:"z1uh3a"}]],V2=e("file-text",J);const Q=[["path",{d:"m6 14 1.5-2.9A2 2 0 0 1 9.24 10H20a2 2 0 0 1 1.94 2.5l-1.54 6a2 2 0 0 1-1.95 1.5H4a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h3.9a2 2 0 0 1 1.69.9l.81 1.2a2 2 0 0 0 1.67.9H18a2 2 0 0 1 2 2v2",key:"usdka0"}]],S2=e("folder-open",Q);const Y=[["path",{d:"M10 20a1 1 0 0 0 .553.895l2 1A1 1 0 0 0 14 21v-7a2 2 0 0 1 .517-1.341L21.74 4.67A1 1 0 0 0 21 3H3a1 1 0 0 0-.742 1.67l7.225 7.989A2 2 0 0 1 10 14z",key:"sc7q7i"}]],P2=e("funnel",Y);const e1=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 2a14.5 14.5 0 0 0 0 20 14.5 14.5 0 0 0 0-20",key:"13o1zl"}],["path",{d:"M2 12h20",key:"9i4pu4"}]],B2=e("globe",e1);const a1=[["line",{x1:"22",x2:"2",y1:"12",y2:"12",key:"1y58io"}],["path",{d:"M5.45 5.11 2 12v6a2 2 0 0 0 2 2h16a2 2 0 0 0 2-2v-6l-3.45-6.89A2 2 0 0 0 16.76 4H7.24a2 2 0 0 0-1.79 1.11z",key:"oot6mr"}],["line",{x1:"6",x2:"6.01",y1:"16",y2:"16",key:"sgf278"}],["line",{x1:"10",x2:"10.01",y1:"16",y2:"16",key:"1l4acy"}]],R2=e("hard-drive",a1);const t1=[["line",{x1:"4",x2:"20",y1:"9",y2:"9",key:"4lhtct"}],["line",{x1:"4",x2:"20",y1:"15",y2:"15",key:"vyu0kd"}],["line",{x1:"10",x2:"8",y1:"3",y2:"21",key:"1ggp8o"}],["line",{x1:"16",x2:"14",y1:"3",y2:"21",key:"weycgp"}]],T2=e("hash",t1);const o1=[["path",{d:"M14 18a2 2 0 0 0-4 0",key:"1v8fkw"}],["path",{d:"m19 11-2.11-6.657a2 2 0 0 0-2.752-1.148l-1.276.61A2 2 0 0 1 12 4H8.5a2 2 0 0 0-1.925 1.456L5 11",key:"1fkr7p"}],["path",{d:"M2 11h20",key:"3eubbj"}],["circle",{cx:"17",cy:"18",r:"3",key:"82mm0e"}],["circle",{cx:"7",cy:"18",r:"3",key:"lvkj7j"}]],W2=e("hat-glasses",o1);const c1=[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}],["path",{d:"M12 7v5l4 2",key:"1fdv2h"}]],D2=e("history",c1);const h1=[["circle",{cx:"12",cy:"12",r:"10",key:"1mglay"}],["path",{d:"M12 16v-4",key:"1dtifu"}],["path",{d:"M12 8h.01",key:"e9boi3"}]],E2=e("info",h1);const n1=[["path",{d:"M12.83 2.18a2 2 0 0 0-1.66 0L2.6 6.08a1 1 0 0 0 0 1.83l8.58 3.91a2 2 0 0 0 1.66 0l8.58-3.9a1 1 0 0 0 0-1.83z",key:"zw3jo"}],["path",{d:"M2 12a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 12",key:"1wduqc"}],["path",{d:"M2 17a1 1 0 0 0 .58.91l8.6 3.91a2 2 0 0 0 1.65 0l8.58-3.9A1 1 0 0 0 22 17",key:"kqbvx6"}]],U2=e("layers",n1);const s1=[["rect",{width:"7",height:"9",x:"3",y:"3",rx:"1",key:"10lvy0"}],["rect",{width:"7",height:"5",x:"14",y:"3",rx:"1",key:"16une8"}],["rect",{width:"7",height:"9",x:"14",y:"12",rx:"1",key:"1hutg5"}],["rect",{width:"7",height:"5",x:"3",y:"16",rx:"1",key:"ldoo1y"}]],O2=e("layout-dashboard",s1);const d1=[["path",{d:"M13 5h8",key:"a7qcls"}],["path",{d:"M13 12h8",key:"h98zly"}],["path",{d:"M13 19h8",key:"c3s6r1"}],["path",{d:"m3 17 2 2 4-4",key:"1jhpwq"}],["path",{d:"m3 7 2 2 4-4",key:"1obspn"}]],F2=e("list-checks",d1);const y1=[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]],Z2=e("loader-circle",y1);const k1=[["rect",{width:"18",height:"11",x:"3",y:"11",rx:"2",ry:"2",key:"1w4ew1"}],["path",{d:"M7 11V7a5 5 0 0 1 10 0v4",key:"fwvmzm"}]],I2=e("lock",k1);const i1=[["path",{d:"m16 17 5-5-5-5",key:"1bji2h"}],["path",{d:"M21 12H9",key:"dn1m92"}],["path",{d:"M9 21H5a2 2 0 0 1-2-2V5a2 2 0 0 1 2-2h4",key:"1uf3rs"}]],G2=e("log-out",i1);const p1=[["path",{d:"M15 3h6v6",key:"1q9fwt"}],["path",{d:"m21 3-7 7",key:"1l2asr"}],["path",{d:"m3 21 7-7",key:"tjx5ai"}],["path",{d:"M9 21H3v-6",key:"wtvkvv"}]],K2=e("maximize-2",p1);const r1=[["path",{d:"M4 5h16",key:"1tepv9"}],["path",{d:"M4 12h16",key:"1lakjw"}],["path",{d:"M4 19h16",key:"1djgab"}]],X2=e("menu",r1);const l1=[["path",{d:"M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z",key:"18887p"}],["path",{d:"M12 8v6",key:"1ib9pf"}],["path",{d:"M9 11h6",key:"1fldmi"}]],J2=e("message-square-plus",l1);const _1=[["path",{d:"M22 17a2 2 0 0 1-2 2H6.828a2 2 0 0 0-1.414.586l-2.202 2.202A.71.71 0 0 1 2 21.286V5a2 2 0 0 1 2-2h16a2 2 0 0 1 2 2z",key:"18887p"}]],Q2=e("message-square",_1);const M1=[["path",{d:"M12 19v3",key:"npa21l"}],["path",{d:"M19 10v2a7 7 0 0 1-14 0v-2",key:"1vc78b"}],["rect",{x:"9",y:"2",width:"6",height:"13",rx:"3",key:"s6n7sd"}]],Y2=e("mic",M1);const x1=[["path",{d:"m14 10 7-7",key:"oa77jy"}],["path",{d:"M20 10h-6V4",key:"mjg0md"}],["path",{d:"m3 21 7-7",key:"tjx5ai"}],["path",{d:"M4 14h6v6",key:"rmj7iw"}]],e0=e("minimize-2",x1);const m1=[["path",{d:"M18 5h4",key:"1lhgn2"}],["path",{d:"M20 3v4",key:"1olli1"}],["path",{d:"M20.985 12.486a9 9 0 1 1-9.473-9.472c.405-.022.617.46.402.803a6 6 0 0 0 8.268 8.268c.344-.215.825-.004.803.401",key:"kfwtm"}]],a0=e("moon-star",m1);const v1=[["rect",{width:"20",height:"14",x:"2",y:"3",rx:"2",key:"48i651"}],["line",{x1:"8",x2:"16",y1:"21",y2:"21",key:"1svkeh"}],["line",{x1:"12",x2:"12",y1:"17",y2:"21",key:"vw1qmm"}]],t0=e("monitor",v1);const g1=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}],["path",{d:"m16 15-3-3 3-3",key:"14y99z"}]],o0=e("panel-left-close",g1);const f1=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M9 3v18",key:"fh3hqa"}]],c0=e("panel-left",f1);const u1=[["rect",{width:"18",height:"18",x:"3",y:"3",rx:"2",key:"afitv7"}],["path",{d:"M15 3v18",key:"14nvp0"}]],h0=e("panel-right",u1);const w1=[["rect",{x:"14",y:"3",width:"5",height:"18",rx:"1",key:"kaeet6"}],["rect",{x:"5",y:"3",width:"5",height:"18",rx:"1",key:"1wsw3u"}]],n0=e("pause",w1);const $1=[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}]],s0=e("pen",$1);const N1=[["path",{d:"M21.174 6.812a1 1 0 0 0-3.986-3.987L3.842 16.174a2 2 0 0 0-.5.83l-1.321 4.352a.5.5 0 0 0 .623.622l4.353-1.32a2 2 0 0 0 .83-.497z",key:"1a8usu"}],["path",{d:"m15 5 4 4",key:"1mk7zo"}]],d0=e("pencil",N1);const z1=[["path",{d:"M5 5a2 2 0 0 1 3.008-1.728l11.997 6.998a2 2 0 0 1 .003 3.458l-12 7A2 2 0 0 1 5 19z",key:"10ikf1"}]],y0=e("play",z1);const b1=[["path",{d:"M5 12h14",key:"1ays0h"}],["path",{d:"M12 5v14",key:"s699le"}]],k0=e("plus",b1);const q1=[["path",{d:"M15.39 4.39a1 1 0 0 0 1.68-.474 2.5 2.5 0 1 1 3.014 3.015 1 1 0 0 0-.474 1.68l1.683 1.682a2.414 2.414 0 0 1 0 3.414L19.61 15.39a1 1 0 0 1-1.68-.474 2.5 2.5 0 1 0-3.014 3.015 1 1 0 0 1 .474 1.68l-1.683 1.682a2.414 2.414 0 0 1-3.414 0L8.61 19.61a1 1 0 0 0-1.68.474 2.5 2.5 0 1 1-3.014-3.015 1 1 0 0 0 .474-1.68l-1.683-1.682a2.414 2.414 0 0 1 0-3.414L4.39 8.61a1 1 0 0 1 1.68.474 2.5 2.5 0 1 0 3.014-3.015 1 1 0 0 1-.474-1.68l1.683-1.682a2.414 2.414 0 0 1 3.414 0z",key:"w46dr5"}]],i0=e("puzzle",q1);const C1=[["path",{d:"M16.247 7.761a6 6 0 0 1 0 8.478",key:"1fwjs5"}],["path",{d:"M19.075 4.933a10 10 0 0 1 0 14.134",key:"ehdyv1"}],["path",{d:"M4.925 19.067a10 10 0 0 1 0-14.134",key:"1q22gi"}],["path",{d:"M7.753 16.239a6 6 0 0 1 0-8.478",key:"r2q7qm"}],["circle",{cx:"12",cy:"12",r:"2",key:"1c9p78"}]],p0=e("radio",C1);const A1=[["path",{d:"M3 12a9 9 0 0 1 9-9 9.75 9.75 0 0 1 6.74 2.74L21 8",key:"v9h5vc"}],["path",{d:"M21 3v5h-5",key:"1q7to0"}],["path",{d:"M21 12a9 9 0 0 1-9 9 9.75 9.75 0 0 1-6.74-2.74L3 16",key:"3uifl3"}],["path",{d:"M8 16H3v5",key:"1cv678"}]],r0=e("refresh-cw",A1);const j1=[["path",{d:"M3 12a9 9 0 1 0 9-9 9.75 9.75 0 0 0-6.74 2.74L3 8",key:"1357e3"}],["path",{d:"M3 3v5h5",key:"1xhq8a"}]],l0=e("rotate-ccw",j1);const L1=[["path",{d:"m21 21-4.34-4.34",key:"14j7rj"}],["circle",{cx:"11",cy:"11",r:"8",key:"4ej97u"}]],_0=e("search",L1);const H1=[["path",{d:"M14.536 21.686a.5.5 0 0 0 .937-.024l6.5-19a.496.496 0 0 0-.635-.635l-19 6.5a.5.5 0 0 0-.024.937l7.93 3.18a2 2 0 0 1 1.112 1.11z",key:"1ffxy3"}],["path",{d:"m21.854 2.147-10.94 10.939",key:"12cjpa"}]],M0=e("send",H1);const V1=[["rect",{width:"20",height:"8",x:"2",y:"2",rx:"2",ry:"2",key:"ngkwjq"}],["rect",{width:"20",height:"8",x:"2",y:"14",rx:"2",ry:"2",key:"iecqi9"}],["line",{x1:"6",x2:"6.01",y1:"6",y2:"6",key:"16zg32"}],["line",{x1:"6",x2:"6.01",y1:"18",y2:"18",key:"nzw8ys"}]],x0=e("server",V1);const S1=[["path",{d:"M14 17H5",key:"gfn3mx"}],["path",{d:"M19 7h-9",key:"6i9tg"}],["circle",{cx:"17",cy:"17",r:"3",key:"18b49y"}],["circle",{cx:"7",cy:"7",r:"3",key:"dfmy0x"}]],m0=e("settings-2",S1);const P1=[["path",{d:"M9.671 4.136a2.34 2.34 0 0 1 4.659 0 2.34 2.34 0 0 0 3.319 1.915 2.34 2.34 0 0 1 2.33 4.033 2.34 2.34 0 0 0 0 3.831 2.34 2.34 0 0 1-2.33 4.033 2.34 2.34 0 0 0-3.319 1.915 2.34 2.34 0 0 1-4.659 0 2.34 2.34 0 0 0-3.32-1.915 2.34 2.34 0 0 1-2.33-4.033 2.34 2.34 0 0 0 0-3.831A2.34 2.34 0 0 1 6.35 6.051a2.34 2.34 0 0 0 3.319-1.915",key:"1i5ecw"}],["circle",{cx:"12",cy:"12",r:"3",key:"1v7zrd"}]],v0=e("settings",P1);const B1=[["path",{d:"M20 13c0 5-3.5 7.5-7.66 8.95a1 1 0 0 1-.67-.01C7.5 20.5 4 18 4 13V6a1 1 0 0 1 1-1c2 0 4.5-1.2 6.24-2.72a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1z",key:"oel41y"}],["path",{d:"m9 12 2 2 4-4",key:"dzmm74"}]],g0=e("shield-check",B1);const R1=[["path",{d:"m2 2 20 20",key:"1ooewy"}],["path",{d:"M5 5a1 1 0 0 0-1 1v7c0 5 3.5 7.5 7.67 8.94a1 1 0 0 0 .67.01c2.35-.82 4.48-1.97 5.9-3.71",key:"1jlk70"}],["path",{d:"M9.309 3.652A12.252 12.252 0 0 0 11.24 2.28a1.17 1.17 0 0 1 1.52 0C14.51 3.81 17 5 19 5a1 1 0 0 1 1 1v7a9.784 9.784 0 0 1-.08 1.264",key:"18rp1v"}]],f0=e("shield-off",R1);const T1=[["circle",{cx:"12",cy:"12",r:"4",key:"4exip2"}],["path",{d:"M12 2v2",key:"tus03m"}],["path",{d:"M12 20v2",key:"1lh1kg"}],["path",{d:"m4.93 4.93 1.41 1.41",key:"149t6j"}],["path",{d:"m17.66 17.66 1.41 1.41",key:"ptbguv"}],["path",{d:"M2 12h2",key:"1t8f8n"}],["path",{d:"M20 12h2",key:"1q8mjw"}],["path",{d:"m6.34 17.66-1.41 1.41",key:"1m8zz5"}],["path",{d:"m19.07 4.93-1.41 1.41",key:"1shlcs"}]],u0=e("sun",T1);const W1=[["path",{d:"M12.586 2.586A2 2 0 0 0 11.172 2H4a2 2 0 0 0-2 2v7.172a2 2 0 0 0 .586 1.414l8.704 8.704a2.426 2.426 0 0 0 3.42 0l6.58-6.58a2.426 2.426 0 0 0 0-3.42z",key:"vktsd0"}],["circle",{cx:"7.5",cy:"7.5",r:".5",fill:"currentColor",key:"kqv944"}]],w0=e("tag",W1);const D1=[["path",{d:"M12 19h8",key:"baeox8"}],["path",{d:"m4 17 6-6-6-6",key:"1yngyt"}]],$0=e("terminal",D1);const E1=[["circle",{cx:"9",cy:"12",r:"3",key:"u3jwor"}],["rect",{width:"20",height:"14",x:"2",y:"5",rx:"7",key:"g7kal2"}]],N0=e("toggle-left",E1);const U1=[["circle",{cx:"15",cy:"12",r:"3",key:"1afu0r"}],["rect",{width:"20",height:"14",x:"2",y:"5",rx:"7",key:"g7kal2"}]],z0=e("toggle-right",U1);const O1=[["path",{d:"M10 11v6",key:"nco0om"}],["path",{d:"M14 11v6",key:"outv1u"}],["path",{d:"M19 6v14a2 2 0 0 1-2 2H7a2 2 0 0 1-2-2V6",key:"miytrc"}],["path",{d:"M3 6h18",key:"d0wm0j"}],["path",{d:"M8 6V4a2 2 0 0 1 2-2h4a2 2 0 0 1 2 2v2",key:"e791ji"}]],b0=e("trash-2",O1);const F1=[["path",{d:"M16 7h6v6",key:"box55l"}],["path",{d:"m22 7-8.5 8.5-5-5L2 17",key:"1t1m79"}]],q0=e("trending-up",F1);const Z1=[["path",{d:"m21.73 18-8-14a2 2 0 0 0-3.48 0l-8 14A2 2 0 0 0 4 21h16a2 2 0 0 0 1.73-3",key:"wmoenq"}],["path",{d:"M12 9v4",key:"juzpu7"}],["path",{d:"M12 17h.01",key:"p32p05"}]],C0=e("triangle-alert",Z1);const I1=[["path",{d:"M12 3v12",key:"1x0j5s"}],["path",{d:"m17 8-5-5-5 5",key:"7q97r8"}],["path",{d:"M21 15v4a2 2 0 0 1-2 2H5a2 2 0 0 1-2-2v-4",key:"ih7n3h"}]],A0=e("upload",I1);const G1=[["path",{d:"M19 21v-2a4 4 0 0 0-4-4H9a4 4 0 0 0-4 4v2",key:"975kel"}],["circle",{cx:"12",cy:"7",r:"4",key:"17ys0d"}]],j0=e("user",G1);const K1=[["path",{d:"m21.64 3.64-1.28-1.28a1.21 1.21 0 0 0-1.72 0L2.36 18.64a1.21 1.21 0 0 0 0 1.72l1.28 1.28a1.2 1.2 0 0 0 1.72 0L21.64 5.36a1.2 1.2 0 0 0 0-1.72",key:"ul74o6"}],["path",{d:"m14 7 3 3",key:"1r5n42"}],["path",{d:"M5 6v4",key:"ilb8ba"}],["path",{d:"M19 14v4",key:"blhpug"}],["path",{d:"M10 2v2",key:"7u0qdc"}],["path",{d:"M7 8H3",key:"zfb6yr"}],["path",{d:"M21 16h-4",key:"1cnmox"}],["path",{d:"M11 3H9",key:"1obp7u"}]],L0=e("wand-sparkles",K1);const X1=[["path",{d:"M18 16.98h-5.99c-1.1 0-1.95.94-2.48 1.9A4 4 0 0 1 2 17c.01-.7.2-1.4.57-2",key:"q3hayz"}],["path",{d:"m6 17 3.13-5.78c.53-.97.1-2.18-.5-3.1a4 4 0 1 1 6.89-4.06",key:"1go1hn"}],["path",{d:"m12 6 3.13 5.73C15.66 12.7 16.9 13 18 13a4 4 0 0 1 0 8",key:"qlwsc0"}]],H0=e("webhook",X1);const J1=[["path",{d:"M12 20h.01",key:"zekei9"}],["path",{d:"M8.5 16.429a5 5 0 0 1 7 0",key:"1bycff"}],["path",{d:"M5 12.859a10 10 0 0 1 5.17-2.69",key:"1dl1wf"}],["path",{d:"M19 12.859a10 10 0 0 0-2.007-1.523",key:"4k23kn"}],["path",{d:"M2 8.82a15 15 0 0 1 4.177-2.643",key:"1grhjp"}],["path",{d:"M22 8.82a15 15 0 0 0-11.288-3.764",key:"z3jwby"}],["path",{d:"m2 2 20 20",key:"1ooewy"}]],V0=e("wifi-off",J1);const Q1=[["path",{d:"M12 20h.01",key:"zekei9"}],["path",{d:"M2 8.82a15 15 0 0 1 20 0",key:"dnpr2z"}],["path",{d:"M5 12.859a10 10 0 0 1 14 0",key:"1x1e6c"}],["path",{d:"M8.5 16.429a5 5 0 0 1 7 0",key:"1bycff"}]],S0=e("wifi",Q1);const Y1=[["path",{d:"M14.7 6.3a1 1 0 0 0 0 1.4l1.6 1.6a1 1 0 0 0 1.4 0l3.106-3.105c.32-.322.863-.22.983.218a6 6 0 0 1-8.259 7.057l-7.91 7.91a1 1 0 0 1-2.999-3l7.91-7.91a6 6 0 0 1 7.057-8.259c.438.12.54.662.219.984z",key:"1ngwbx"}]],P0=e("wrench",Y1);const e2=[["path",{d:"M18 6 6 18",key:"1bl5f8"}],["path",{d:"m6 6 12 12",key:"d8bk6v"}]],B0=e("x",e2);const a2=[["path",{d:"M4 14a1 1 0 0 1-.78-1.63l9.9-10.2a.5.5 0 0 1 .86.46l-1.92 6.02A1 1 0 0 0 13 10h7a1 1 0 0 1 .78 1.63l-9.9 10.2a.5.5 0 0 1-.86-.46l1.92-6.02A1 1 0 0 0 11 14z",key:"1xq2db"}]],R0=e("zap",a2);export{i2 as $,o2 as A,s2 as B,N2 as C,q2 as D,c2 as E,V2 as F,b0 as G,W2 as H,P0 as I,f2 as J,M2 as K,O2 as L,X2 as M,d2 as N,Y2 as O,i0 as P,M0 as Q,l0 as R,u0 as S,$0 as T,j0 as U,C0 as V,L0 as W,B0 as X,r0 as Y,w0 as Z,q0 as _,a0 as a,L2 as a0,T2 as a1,E2 as a2,_0 as a3,g2 as a4,z0 as a5,N0 as a6,B2 as a7,k0 as a8,z2 as a9,h2 as aa,P2 as ab,l2 as ac,n2 as ad,S0 as ae,V0 as af,v2 as ag,D2 as ah,s0 as ai,n0 as aj,y0 as ak,x2 as al,A0 as am,S2 as an,m0 as ao,p0 as ap,f0 as aq,x0 as ar,I2 as as,R2 as at,R0 as au,A2 as av,H2 as aw,h0 as ax,U2 as ay,j2 as az,t0 as b,Q2 as c,v0 as d,H0 as e,F2 as f,$2 as g,g0 as h,C2 as i,G2 as j,p2 as k,e0 as l,K2 as m,b2 as n,k2 as o,y2 as p,m2 as q,u2 as r,w2 as s,Z2 as t,c0 as u,J2 as v,o0 as w,_2 as x,d0 as y,r2 as z};
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import{a as zr,r as G,R as Ct}from"./vendor-react-DikRIOlj.js";var pt={exports:{}},ht={};var Ht;function Sr(){if(Ht)return ht;Ht=1;var e=zr();function t(p,f){return p===f&&(p!==0||1/p===1/f)||p!==p&&f!==f}var n=typeof Object.is=="function"?Object.is:t,r=e.useState,o=e.useEffect,i=e.useLayoutEffect,s=e.useDebugValue;function a(p,f){var h=f(),k=r({inst:{value:h,getSnapshot:f}}),b=k[0].inst,$=k[1];return i(function(){b.value=h,b.getSnapshot=f,c(b)&&$({inst:b})},[p,h,f]),o(function(){return c(b)&&$({inst:b}),p(function(){c(b)&&$({inst:b})})},[p]),s(h),h}function c(p){var f=p.getSnapshot;p=p.value;try{var h=f();return!n(p,h)}catch{return!0}}function u(p,f){return f()}var d=typeof window>"u"||typeof window.document>"u"||typeof window.document.createElement>"u"?u:a;return ht.useSyncExternalStore=e.useSyncExternalStore!==void 0?e.useSyncExternalStore:d,ht}var Yt;function $r(){return Yt||(Yt=1,pt.exports=Sr()),pt.exports}var Xt=$r();const xn=0,Rn=1,Tn=2,Qt=3;var en=Object.prototype.hasOwnProperty;function zt(e,t){var n,r;if(e===t)return!0;if(e&&t&&(n=e.constructor)===t.constructor){if(n===Date)return e.getTime()===t.getTime();if(n===RegExp)return e.toString()===t.toString();if(n===Array){if((r=e.length)===t.length)for(;r--&&zt(e[r],t[r]););return r===-1}if(!n||typeof e=="object"){r=0;for(n in e)if(en.call(e,n)&&++r&&!en.call(t,n)||!(n in t)||!zt(e[n],t[n]))return!1;return Object.keys(t).length===r}}return e!==e&&t!==t}const ge=new WeakMap,be=()=>{},q=be(),St=Object,O=e=>e===q,ue=e=>typeof e=="function",we=(e,t)=>({...e,...t}),Pn=e=>ue(e.then),mt={},He={},jt="undefined",Be=typeof window!=jt,$t=typeof document!=jt,Or=Be&&"Deno"in window,Er=()=>Be&&typeof window.requestAnimationFrame!=jt,In=(e,t)=>{const n=ge.get(e);return[()=>!O(t)&&e.get(t)||mt,r=>{if(!O(t)){const o=e.get(t);t in He||(He[t]=o),n[5](t,we(o,r),o||mt)}},n[6],()=>!O(t)&&t in He?He[t]:!O(t)&&e.get(t)||mt]};let Ot=!0;const Zr=()=>Ot,[Et,Zt]=Be&&window.addEventListener?[window.addEventListener.bind(window),window.removeEventListener.bind(window)]:[be,be],xr=()=>{const e=$t&&document.visibilityState;return O(e)||e!=="hidden"},Rr=e=>($t&&document.addEventListener("visibilitychange",e),Et("focus",e),()=>{$t&&document.removeEventListener("visibilitychange",e),Zt("focus",e)}),Tr=e=>{const t=()=>{Ot=!0,e()},n=()=>{Ot=!1};return Et("online",t),Et("offline",n),()=>{Zt("online",t),Zt("offline",n)}},Pr={isOnline:Zr,isVisible:xr},Ir={initFocus:Rr,initReconnect:Tr},tn=!Ct.useId,Ae=!Be||Or,Ar=e=>Er()?window.requestAnimationFrame(e):setTimeout(e,1),gt=Ae?G.useEffect:G.useLayoutEffect,bt=typeof navigator<"u"&&navigator.connection,nn=!Ae&&bt&&(["slow-2g","2g"].includes(bt.effectiveType)||bt.saveData),Ye=new WeakMap,Cr=e=>St.prototype.toString.call(e),vt=(e,t)=>e===`[object ${t}]`;let jr=0;const xt=e=>{const t=typeof e,n=Cr(e),r=vt(n,"Date"),o=vt(n,"RegExp"),i=vt(n,"Object");let s,a;if(St(e)===e&&!r&&!o){if(s=Ye.get(e),s)return s;if(s=++jr+"~",Ye.set(e,s),Array.isArray(e)){for(s="@",a=0;a<e.length;a++)s+=xt(e[a])+",";Ye.set(e,s)}if(i){s="#";const c=St.keys(e).sort();for(;!O(a=c.pop());)O(e[a])||(s+=a+":"+xt(e[a])+",");Ye.set(e,s)}}else s=r?e.toJSON():t=="symbol"?e.toString():t=="string"?JSON.stringify(e):""+e;return s},Dt=e=>{if(ue(e))try{e=e()}catch{e=""}const t=e;return e=typeof e=="string"?e:(Array.isArray(e)?e.length:e)?xt(e):"",[e,t]};let Dr=0;const Rt=()=>++Dr;async function An(...e){const[t,n,r,o]=e,i=we({populateCache:!0,throwOnError:!0},typeof o=="boolean"?{revalidate:o}:o||{});let s=i.populateCache;const a=i.rollbackOnError;let c=i.optimisticData;const u=f=>typeof a=="function"?a(f):a!==!1,d=i.throwOnError;if(ue(n)){const f=n,h=[],k=t.keys();for(const b of k)!/^\$(inf|sub)\$/.test(b)&&f(t.get(b)._k)&&h.push(b);return Promise.all(h.map(p))}return p(n);async function p(f){const[h]=Dt(f);if(!h)return;const[k,b]=In(t,h),[$,K,w,j]=ge.get(t),x=()=>{const H=$[h];return(ue(i.revalidate)?i.revalidate(k().data,f):i.revalidate!==!1)&&(delete w[h],delete j[h],H&&H[0])?H[0](Tn).then(()=>k().data):k().data};if(e.length<3)return x();let S=r,F,V=!1;const _=Rt();K[h]=[_,0];const E=!O(c),de=k(),ee=de.data,oe=de._c,ie=O(oe)?ee:oe;if(E&&(c=ue(c)?c(ie,ee):c,b({data:c,_c:ie})),ue(S))try{S=S(ie)}catch(H){F=H,V=!0}if(S&&Pn(S))if(S=await S.catch(H=>{F=H,V=!0}),_!==K[h][0]){if(V)throw F;return S}else V&&E&&u(F)&&(s=!0,b({data:ie,_c:q}));if(s&&!V)if(ue(s)){const H=s(S,ie);b({data:H,error:q,_c:q})}else b({data:S,error:q,_c:q});if(K[h][1]=Rt(),Promise.resolve(x()).then(()=>{b({_c:q})}),V){if(d)throw F;return}return S}}const rn=(e,t)=>{for(const n in e)e[n][0]&&e[n][0](t)},Nr=(e,t)=>{if(!ge.has(e)){const n=we(Ir,t),r=Object.create(null),o=An.bind(q,e);let i=be;const s=Object.create(null),a=(d,p)=>{const f=s[d]||[];return s[d]=f,f.push(p),()=>f.splice(f.indexOf(p),1)},c=(d,p,f)=>{e.set(d,p);const h=s[d];if(h)for(const k of h)k(p,f)},u=()=>{if(!ge.has(e)&&(ge.set(e,[r,Object.create(null),Object.create(null),Object.create(null),o,c,a]),!Ae)){const d=n.initFocus(setTimeout.bind(q,rn.bind(q,r,xn))),p=n.initReconnect(setTimeout.bind(q,rn.bind(q,r,Rn)));i=()=>{d&&d(),p&&p(),ge.delete(e)}}};return u(),[e,o,u,i]}return[e,ge.get(e)[4]]},Lr=(e,t,n,r,o)=>{const i=n.errorRetryCount,s=o.retryCount,a=~~((Math.random()+.5)*(1<<(s<8?s:8)))*n.errorRetryInterval;!O(i)&&s>i||setTimeout(r,a,o)},Ur=zt,[Cn,Fr]=Nr(new Map),Mr=we({onLoadingSlow:be,onSuccess:be,onError:be,onErrorRetry:Lr,onDiscarded:be,revalidateOnFocus:!0,revalidateOnReconnect:!0,revalidateIfStale:!0,shouldRetryOnError:!0,errorRetryInterval:nn?1e4:5e3,focusThrottleInterval:5*1e3,dedupingInterval:2*1e3,loadingTimeout:nn?5e3:3e3,compare:Ur,isPaused:()=>!1,cache:Cn,mutate:Fr,fallback:{}},Pr),Vr=(e,t)=>{const n=we(e,t);if(t){const{use:r,fallback:o}=e,{use:i,fallback:s}=t;r&&i&&(n.use=r.concat(i)),o&&s&&(n.fallback=we(o,s))}return n},Jr=G.createContext({}),Wr="$inf$",jn=Be&&window.__SWR_DEVTOOLS_USE__,Gr=jn?window.__SWR_DEVTOOLS_USE__:[],Br=()=>{jn&&(window.__SWR_DEVTOOLS_REACT__=Ct)},qr=e=>ue(e[1])?[e[0],e[1],e[2]||{}]:[e[0],null,(e[1]===null?e[2]:e[1])||{}],Kr=()=>{const e=G.useContext(Jr);return G.useMemo(()=>we(Mr,e),[e])},Hr=e=>(t,n,r)=>e(t,n&&((...i)=>{const[s]=Dt(t),[,,,a]=ge.get(Cn);if(s.startsWith(Wr))return n(...i);const c=a[s];return O(c)?n(...i):(delete a[s],c)}),r),Yr=Gr.concat(Hr),Xr=e=>function(...n){const r=Kr(),[o,i,s]=qr(n),a=Vr(r,s);let c=e;const{use:u}=a,d=(u||[]).concat(Yr);for(let p=d.length;p--;)c=d[p](c);return c(o,i||a.fetcher||null,a)},Qr=(e,t,n)=>{const r=t[e]||(t[e]=[]);return r.push(n),()=>{const o=r.indexOf(n);o>=0&&(r[o]=r[r.length-1],r.pop())}};Br();const _t=Ct.use||(e=>{switch(e.status){case"pending":throw e;case"fulfilled":return e.value;case"rejected":throw e.reason;default:throw e.status="pending",e.then(t=>{e.status="fulfilled",e.value=t},t=>{e.status="rejected",e.reason=t}),e}}),wt={dedupe:!0},on=Promise.resolve(q),eo=(e,t,n)=>{const{cache:r,compare:o,suspense:i,fallbackData:s,revalidateOnMount:a,revalidateIfStale:c,refreshInterval:u,refreshWhenHidden:d,refreshWhenOffline:p,keepPreviousData:f,strictServerPrefetchWarning:h}=n,[k,b,$,K]=ge.get(r),[w,j]=Dt(e),x=G.useRef(!1),S=G.useRef(!1),F=G.useRef(w),V=G.useRef(t),_=G.useRef(n),E=()=>_.current,de=()=>E().isVisible()&&E().isOnline(),[ee,oe,ie,H]=In(r,w),te=G.useRef({}).current,Q=O(s)?O(n.fallback)?q:n.fallback[w]:s,ae=(T,C)=>{for(const N in te){const D=N;if(D==="data"){if(!o(T[D],C[D])&&(!O(T[D])||!o(ze,C[D])))return!1}else if(C[D]!==T[D])return!1}return!0},v=G.useMemo(()=>{const T=!w||!t?!1:O(a)?E().isPaused()||i?!1:c!==!1:a,C=Y=>{const pe=we(Y);return delete pe._k,T?{isValidating:!0,isLoading:!0,...pe}:pe},N=ee(),D=H(),se=C(N),Te=N===D?se:C(D);let W=se;return[()=>{const Y=C(ee());return ae(Y,W)?(W.data=Y.data,W.isLoading=Y.isLoading,W.isValidating=Y.isValidating,W.error=Y.error,W):(W=Y,Y)},()=>Te]},[r,w]),fe=Xt.useSyncExternalStore(G.useCallback(T=>ie(w,(C,N)=>{ae(N,C)||T()}),[r,w]),v[0],v[1]),Ue=!x.current,qe=k[w]&&k[w].length>0,ce=fe.data,I=O(ce)?Q&&Pn(Q)?_t(Q):Q:ce,J=fe.error,ve=G.useRef(I),ze=f?O(ce)?O(ve.current)?I:ve.current:ce:I,R=w&&O(I),Ke=!Ae&&Xt.useSyncExternalStore(()=>be,()=>!1,()=>!0);h&&Ke&&!i&&R&&console.warn(`Missing pre-initiated data for serialized key "${w}" during server-side rendering. Data fethcing should be initiated on the server and provided to SWR via fallback data. You can set "strictServerPrefetchWarning: false" to disable this warning.`);const Se=qe&&!O(J)?!1:Ue&&!O(a)?a:E().isPaused()?!1:i?O(I)?!1:c:O(I)||c,$e=!!(w&&t&&Ue&&Se),Fe=O(fe.isValidating)?$e:fe.isValidating,Re=O(fe.isLoading)?$e:fe.isLoading,Me=G.useCallback(async T=>{const C=V.current;if(!w||!C||S.current||E().isPaused())return!1;let N,D,se=!0;const Te=T||{},W=!$[w]||!Te.dedupe,Y=()=>tn?!S.current&&w===F.current&&x.current:w===F.current,pe={isValidating:!1,isLoading:!1},Bt=()=>{oe(pe)},qt=()=>{const ne=$[w];ne&&ne[1]===D&&delete $[w]},Kt={isValidating:!0};O(ee().data)&&(Kt.isLoading=!0);try{if(W&&(oe(Kt),n.loadingTimeout&&O(ee().data)&&setTimeout(()=>{se&&Y()&&E().onLoadingSlow(w,n)},n.loadingTimeout),$[w]=[C(j),Rt()]),[N,D]=$[w],N=await N,W&&setTimeout(qt,n.dedupingInterval),!$[w]||$[w][1]!==D)return W&&Y()&&E().onDiscarded(w),!1;pe.error=q;const ne=b[w];if(!O(ne)&&(D<=ne[0]||D<=ne[1]||ne[1]===0))return Bt(),W&&Y()&&E().onDiscarded(w),!1;const he=ee().data;pe.data=o(he,N)?he:N,W&&Y()&&E().onSuccess(N,w,n)}catch(ne){qt();const he=E(),{shouldRetryOnError:dt}=he;he.isPaused()||(pe.error=ne,W&&Y()&&(he.onError(ne,w,he),(dt===!0||ue(dt)&&dt(ne))&&(!E().revalidateOnFocus||!E().revalidateOnReconnect||de())&&he.onErrorRetry(ne,w,he,kr=>{const ft=k[w];ft&&ft[0]&&ft[0](Qt,kr)},{retryCount:(Te.retryCount||0)+1,dedupe:!0})))}return se=!1,Bt(),!0},[w,r]),Gt=G.useCallback((...T)=>An(r,F.current,...T),[]);if(gt(()=>{V.current=t,_.current=n,O(ce)||(ve.current=ce)}),gt(()=>{if(!w)return;const T=Me.bind(q,wt);let C=0;E().revalidateOnFocus&&(C=Date.now()+E().focusThrottleInterval);const D=Qr(w,k,(se,Te={})=>{if(se==xn){const W=Date.now();E().revalidateOnFocus&&W>C&&de()&&(C=W+E().focusThrottleInterval,T())}else if(se==Rn)E().revalidateOnReconnect&&de()&&T();else{if(se==Tn)return Me();if(se==Qt)return Me(Te)}});return S.current=!1,F.current=w,x.current=!0,oe({_k:j}),Se&&($[w]||(O(I)||Ae?T():Ar(T))),()=>{S.current=!0,D()}},[w]),gt(()=>{let T;function C(){const D=ue(u)?u(ee().data):u;D&&T!==-1&&(T=setTimeout(N,D))}function N(){!ee().error&&(d||E().isVisible())&&(p||E().isOnline())?Me(wt).then(C):C()}return C(),()=>{T&&(clearTimeout(T),T=-1)}},[u,d,p,w]),G.useDebugValue(ze),i){if(!tn&&Ae&&R)throw new Error("Fallback data is required when using Suspense in SSR.");R&&(V.current=t,_.current=n,S.current=!1);const T=K[w],C=!O(T)&&R?Gt(T):on;if(_t(C),!O(J)&&R)throw J;const N=R?Me(wt):on;!O(ze)&&R&&(N.status="fulfilled",N.value=!0),_t(N)}return{mutate:Gt,get data(){return te.data=!0,ze},get error(){return te.error=!0,J},get isValidating(){return te.isValidating=!0,Fe},get isLoading(){return te.isLoading=!0,Re}}},lu=Xr(eo);function Dn(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var o=e.length;for(t=0;t<o;t++)e[t]&&(n=Dn(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function du(){for(var e,t,n=0,r="",o=arguments.length;n<o;n++)(e=arguments[n])&&(t=Dn(e))&&(r&&(r+=" "),r+=t);return r}const to=(e,t)=>{const n=new Array(e.length+t.length);for(let r=0;r<e.length;r++)n[r]=e[r];for(let r=0;r<t.length;r++)n[e.length+r]=t[r];return n},no=(e,t)=>({classGroupId:e,validator:t}),Nn=(e=new Map,t=null,n)=>({nextPart:e,validators:t,classGroupId:n}),rt="-",sn=[],ro="arbitrary..",oo=e=>{const t=io(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:s=>{if(s.startsWith("[")&&s.endsWith("]"))return so(s);const a=s.split(rt),c=a[0]===""&&a.length>1?1:0;return Ln(a,c,t)},getConflictingClassGroupIds:(s,a)=>{if(a){const c=r[s],u=n[s];return c?u?to(u,c):c:u||sn}return n[s]||sn}}},Ln=(e,t,n)=>{if(e.length-t===0)return n.classGroupId;const o=e[t],i=n.nextPart.get(o);if(i){const u=Ln(e,t+1,i);if(u)return u}const s=n.validators;if(s===null)return;const a=t===0?e.join(rt):e.slice(t).join(rt),c=s.length;for(let u=0;u<c;u++){const d=s[u];if(d.validator(a))return d.classGroupId}},so=e=>e.slice(1,-1).indexOf(":")===-1?void 0:(()=>{const t=e.slice(1,-1),n=t.indexOf(":"),r=t.slice(0,n);return r?ro+r:void 0})(),io=e=>{const{theme:t,classGroups:n}=e;return ao(n,t)},ao=(e,t)=>{const n=Nn();for(const r in e){const o=e[r];Nt(o,n,r,t)}return n},Nt=(e,t,n,r)=>{const o=e.length;for(let i=0;i<o;i++){const s=e[i];co(s,t,n,r)}},co=(e,t,n,r)=>{if(typeof e=="string"){uo(e,t,n);return}if(typeof e=="function"){lo(e,t,n,r);return}fo(e,t,n,r)},uo=(e,t,n)=>{const r=e===""?t:Un(t,e);r.classGroupId=n},lo=(e,t,n,r)=>{if(po(e)){Nt(e(r),t,n,r);return}t.validators===null&&(t.validators=[]),t.validators.push(no(n,e))},fo=(e,t,n,r)=>{const o=Object.entries(e),i=o.length;for(let s=0;s<i;s++){const[a,c]=o[s];Nt(c,Un(t,a),n,r)}},Un=(e,t)=>{let n=e;const r=t.split(rt),o=r.length;for(let i=0;i<o;i++){const s=r[i];let a=n.nextPart.get(s);a||(a=Nn(),n.nextPart.set(s,a)),n=a}return n},po=e=>"isThemeGetter"in e&&e.isThemeGetter===!0,ho=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=Object.create(null),r=Object.create(null);const o=(i,s)=>{n[i]=s,t++,t>e&&(t=0,r=n,n=Object.create(null))};return{get(i){let s=n[i];if(s!==void 0)return s;if((s=r[i])!==void 0)return o(i,s),s},set(i,s){i in n?n[i]=s:o(i,s)}}},Tt="!",an=":",mo=[],cn=(e,t,n,r,o)=>({modifiers:e,hasImportantModifier:t,baseClassName:n,maybePostfixModifierPosition:r,isExternal:o}),go=e=>{const{prefix:t,experimentalParseClassName:n}=e;let r=o=>{const i=[];let s=0,a=0,c=0,u;const d=o.length;for(let b=0;b<d;b++){const $=o[b];if(s===0&&a===0){if($===an){i.push(o.slice(c,b)),c=b+1;continue}if($==="/"){u=b;continue}}$==="["?s++:$==="]"?s--:$==="("?a++:$===")"&&a--}const p=i.length===0?o:o.slice(c);let f=p,h=!1;p.endsWith(Tt)?(f=p.slice(0,-1),h=!0):p.startsWith(Tt)&&(f=p.slice(1),h=!0);const k=u&&u>c?u-c:void 0;return cn(i,h,f,k)};if(t){const o=t+an,i=r;r=s=>s.startsWith(o)?i(s.slice(o.length)):cn(mo,!1,s,void 0,!0)}if(n){const o=r;r=i=>n({className:i,parseClassName:o})}return r},bo=e=>{const t=new Map;return e.orderSensitiveModifiers.forEach((n,r)=>{t.set(n,1e6+r)}),n=>{const r=[];let o=[];for(let i=0;i<n.length;i++){const s=n[i],a=s[0]==="[",c=t.has(s);a||c?(o.length>0&&(o.sort(),r.push(...o),o=[]),r.push(s)):o.push(s)}return o.length>0&&(o.sort(),r.push(...o)),r}},vo=e=>({cache:ho(e.cacheSize),parseClassName:go(e),sortModifiers:bo(e),...oo(e)}),_o=/\s+/,wo=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:o,sortModifiers:i}=t,s=[],a=e.trim().split(_o);let c="";for(let u=a.length-1;u>=0;u-=1){const d=a[u],{isExternal:p,modifiers:f,hasImportantModifier:h,baseClassName:k,maybePostfixModifierPosition:b}=n(d);if(p){c=d+(c.length>0?" "+c:c);continue}let $=!!b,K=r($?k.substring(0,b):k);if(!K){if(!$){c=d+(c.length>0?" "+c:c);continue}if(K=r(k),!K){c=d+(c.length>0?" "+c:c);continue}$=!1}const w=f.length===0?"":f.length===1?f[0]:i(f).join(":"),j=h?w+Tt:w,x=j+K;if(s.indexOf(x)>-1)continue;s.push(x);const S=o(K,$);for(let F=0;F<S.length;++F){const V=S[F];s.push(j+V)}c=d+(c.length>0?" "+c:c)}return c},yo=(...e)=>{let t=0,n,r,o="";for(;t<e.length;)(n=e[t++])&&(r=Fn(n))&&(o&&(o+=" "),o+=r);return o},Fn=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=Fn(e[r]))&&(n&&(n+=" "),n+=t);return n},ko=(e,...t)=>{let n,r,o,i;const s=c=>{const u=t.reduce((d,p)=>p(d),e());return n=vo(u),r=n.cache.get,o=n.cache.set,i=a,a(c)},a=c=>{const u=r(c);if(u)return u;const d=wo(c,n);return o(c,d),d};return i=s,(...c)=>i(yo(...c))},zo=[],M=e=>{const t=n=>n[e]||zo;return t.isThemeGetter=!0,t},Mn=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,Vn=/^\((?:(\w[\w-]*):)?(.+)\)$/i,So=/^\d+\/\d+$/,$o=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,Oo=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Eo=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,Zo=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,xo=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Pe=e=>So.test(e),z=e=>!!e&&!Number.isNaN(Number(e)),_e=e=>!!e&&Number.isInteger(Number(e)),yt=e=>e.endsWith("%")&&z(e.slice(0,-1)),me=e=>$o.test(e),Ro=()=>!0,To=e=>Oo.test(e)&&!Eo.test(e),Jn=()=>!1,Po=e=>Zo.test(e),Io=e=>xo.test(e),Ao=e=>!m(e)&&!g(e),Co=e=>De(e,Bn,Jn),m=e=>Mn.test(e),Oe=e=>De(e,qn,To),kt=e=>De(e,Uo,z),un=e=>De(e,Wn,Jn),jo=e=>De(e,Gn,Io),Xe=e=>De(e,Kn,Po),g=e=>Vn.test(e),Ve=e=>Ne(e,qn),Do=e=>Ne(e,Fo),ln=e=>Ne(e,Wn),No=e=>Ne(e,Bn),Lo=e=>Ne(e,Gn),Qe=e=>Ne(e,Kn,!0),De=(e,t,n)=>{const r=Mn.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},Ne=(e,t,n=!1)=>{const r=Vn.exec(e);return r?r[1]?t(r[1]):n:!1},Wn=e=>e==="position"||e==="percentage",Gn=e=>e==="image"||e==="url",Bn=e=>e==="length"||e==="size"||e==="bg-size",qn=e=>e==="length",Uo=e=>e==="number",Fo=e=>e==="family-name",Kn=e=>e==="shadow",Mo=()=>{const e=M("color"),t=M("font"),n=M("text"),r=M("font-weight"),o=M("tracking"),i=M("leading"),s=M("breakpoint"),a=M("container"),c=M("spacing"),u=M("radius"),d=M("shadow"),p=M("inset-shadow"),f=M("text-shadow"),h=M("drop-shadow"),k=M("blur"),b=M("perspective"),$=M("aspect"),K=M("ease"),w=M("animate"),j=()=>["auto","avoid","all","avoid-page","page","left","right","column"],x=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],S=()=>[...x(),g,m],F=()=>["auto","hidden","clip","visible","scroll"],V=()=>["auto","contain","none"],_=()=>[g,m,c],E=()=>[Pe,"full","auto",..._()],de=()=>[_e,"none","subgrid",g,m],ee=()=>["auto",{span:["full",_e,g,m]},_e,g,m],oe=()=>[_e,"auto",g,m],ie=()=>["auto","min","max","fr",g,m],H=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],te=()=>["start","end","center","stretch","center-safe","end-safe"],Q=()=>["auto",..._()],ae=()=>[Pe,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",..._()],v=()=>[e,g,m],fe=()=>[...x(),ln,un,{position:[g,m]}],Ue=()=>["no-repeat",{repeat:["","x","y","space","round"]}],qe=()=>["auto","cover","contain",No,Co,{size:[g,m]}],ce=()=>[yt,Ve,Oe],I=()=>["","none","full",u,g,m],J=()=>["",z,Ve,Oe],ve=()=>["solid","dashed","dotted","double"],ze=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],R=()=>[z,yt,ln,un],Ke=()=>["","none",k,g,m],Se=()=>["none",z,g,m],$e=()=>["none",z,g,m],Fe=()=>[z,g,m],Re=()=>[Pe,"full",..._()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[me],breakpoint:[me],color:[Ro],container:[me],"drop-shadow":[me],ease:["in","out","in-out"],font:[Ao],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[me],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[me],shadow:[me],spacing:["px",z],text:[me],"text-shadow":[me],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",Pe,m,g,$]}],container:["container"],columns:[{columns:[z,m,g,a]}],"break-after":[{"break-after":j()}],"break-before":[{"break-before":j()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:S()}],overflow:[{overflow:F()}],"overflow-x":[{"overflow-x":F()}],"overflow-y":[{"overflow-y":F()}],overscroll:[{overscroll:V()}],"overscroll-x":[{"overscroll-x":V()}],"overscroll-y":[{"overscroll-y":V()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:E()}],"inset-x":[{"inset-x":E()}],"inset-y":[{"inset-y":E()}],start:[{start:E()}],end:[{end:E()}],top:[{top:E()}],right:[{right:E()}],bottom:[{bottom:E()}],left:[{left:E()}],visibility:["visible","invisible","collapse"],z:[{z:[_e,"auto",g,m]}],basis:[{basis:[Pe,"full","auto",a,..._()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[z,Pe,"auto","initial","none",m]}],grow:[{grow:["",z,g,m]}],shrink:[{shrink:["",z,g,m]}],order:[{order:[_e,"first","last","none",g,m]}],"grid-cols":[{"grid-cols":de()}],"col-start-end":[{col:ee()}],"col-start":[{"col-start":oe()}],"col-end":[{"col-end":oe()}],"grid-rows":[{"grid-rows":de()}],"row-start-end":[{row:ee()}],"row-start":[{"row-start":oe()}],"row-end":[{"row-end":oe()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":ie()}],"auto-rows":[{"auto-rows":ie()}],gap:[{gap:_()}],"gap-x":[{"gap-x":_()}],"gap-y":[{"gap-y":_()}],"justify-content":[{justify:[...H(),"normal"]}],"justify-items":[{"justify-items":[...te(),"normal"]}],"justify-self":[{"justify-self":["auto",...te()]}],"align-content":[{content:["normal",...H()]}],"align-items":[{items:[...te(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...te(),{baseline:["","last"]}]}],"place-content":[{"place-content":H()}],"place-items":[{"place-items":[...te(),"baseline"]}],"place-self":[{"place-self":["auto",...te()]}],p:[{p:_()}],px:[{px:_()}],py:[{py:_()}],ps:[{ps:_()}],pe:[{pe:_()}],pt:[{pt:_()}],pr:[{pr:_()}],pb:[{pb:_()}],pl:[{pl:_()}],m:[{m:Q()}],mx:[{mx:Q()}],my:[{my:Q()}],ms:[{ms:Q()}],me:[{me:Q()}],mt:[{mt:Q()}],mr:[{mr:Q()}],mb:[{mb:Q()}],ml:[{ml:Q()}],"space-x":[{"space-x":_()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":_()}],"space-y-reverse":["space-y-reverse"],size:[{size:ae()}],w:[{w:[a,"screen",...ae()]}],"min-w":[{"min-w":[a,"screen","none",...ae()]}],"max-w":[{"max-w":[a,"screen","none","prose",{screen:[s]},...ae()]}],h:[{h:["screen","lh",...ae()]}],"min-h":[{"min-h":["screen","lh","none",...ae()]}],"max-h":[{"max-h":["screen","lh",...ae()]}],"font-size":[{text:["base",n,Ve,Oe]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[r,g,kt]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",yt,m]}],"font-family":[{font:[Do,m,t]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[o,g,m]}],"line-clamp":[{"line-clamp":[z,"none",g,kt]}],leading:[{leading:[i,..._()]}],"list-image":[{"list-image":["none",g,m]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",g,m]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:v()}],"text-color":[{text:v()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...ve(),"wavy"]}],"text-decoration-thickness":[{decoration:[z,"from-font","auto",g,Oe]}],"text-decoration-color":[{decoration:v()}],"underline-offset":[{"underline-offset":[z,"auto",g,m]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:_()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",g,m]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",g,m]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:fe()}],"bg-repeat":[{bg:Ue()}],"bg-size":[{bg:qe()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},_e,g,m],radial:["",g,m],conic:[_e,g,m]},Lo,jo]}],"bg-color":[{bg:v()}],"gradient-from-pos":[{from:ce()}],"gradient-via-pos":[{via:ce()}],"gradient-to-pos":[{to:ce()}],"gradient-from":[{from:v()}],"gradient-via":[{via:v()}],"gradient-to":[{to:v()}],rounded:[{rounded:I()}],"rounded-s":[{"rounded-s":I()}],"rounded-e":[{"rounded-e":I()}],"rounded-t":[{"rounded-t":I()}],"rounded-r":[{"rounded-r":I()}],"rounded-b":[{"rounded-b":I()}],"rounded-l":[{"rounded-l":I()}],"rounded-ss":[{"rounded-ss":I()}],"rounded-se":[{"rounded-se":I()}],"rounded-ee":[{"rounded-ee":I()}],"rounded-es":[{"rounded-es":I()}],"rounded-tl":[{"rounded-tl":I()}],"rounded-tr":[{"rounded-tr":I()}],"rounded-br":[{"rounded-br":I()}],"rounded-bl":[{"rounded-bl":I()}],"border-w":[{border:J()}],"border-w-x":[{"border-x":J()}],"border-w-y":[{"border-y":J()}],"border-w-s":[{"border-s":J()}],"border-w-e":[{"border-e":J()}],"border-w-t":[{"border-t":J()}],"border-w-r":[{"border-r":J()}],"border-w-b":[{"border-b":J()}],"border-w-l":[{"border-l":J()}],"divide-x":[{"divide-x":J()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":J()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...ve(),"hidden","none"]}],"divide-style":[{divide:[...ve(),"hidden","none"]}],"border-color":[{border:v()}],"border-color-x":[{"border-x":v()}],"border-color-y":[{"border-y":v()}],"border-color-s":[{"border-s":v()}],"border-color-e":[{"border-e":v()}],"border-color-t":[{"border-t":v()}],"border-color-r":[{"border-r":v()}],"border-color-b":[{"border-b":v()}],"border-color-l":[{"border-l":v()}],"divide-color":[{divide:v()}],"outline-style":[{outline:[...ve(),"none","hidden"]}],"outline-offset":[{"outline-offset":[z,g,m]}],"outline-w":[{outline:["",z,Ve,Oe]}],"outline-color":[{outline:v()}],shadow:[{shadow:["","none",d,Qe,Xe]}],"shadow-color":[{shadow:v()}],"inset-shadow":[{"inset-shadow":["none",p,Qe,Xe]}],"inset-shadow-color":[{"inset-shadow":v()}],"ring-w":[{ring:J()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:v()}],"ring-offset-w":[{"ring-offset":[z,Oe]}],"ring-offset-color":[{"ring-offset":v()}],"inset-ring-w":[{"inset-ring":J()}],"inset-ring-color":[{"inset-ring":v()}],"text-shadow":[{"text-shadow":["none",f,Qe,Xe]}],"text-shadow-color":[{"text-shadow":v()}],opacity:[{opacity:[z,g,m]}],"mix-blend":[{"mix-blend":[...ze(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":ze()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[z]}],"mask-image-linear-from-pos":[{"mask-linear-from":R()}],"mask-image-linear-to-pos":[{"mask-linear-to":R()}],"mask-image-linear-from-color":[{"mask-linear-from":v()}],"mask-image-linear-to-color":[{"mask-linear-to":v()}],"mask-image-t-from-pos":[{"mask-t-from":R()}],"mask-image-t-to-pos":[{"mask-t-to":R()}],"mask-image-t-from-color":[{"mask-t-from":v()}],"mask-image-t-to-color":[{"mask-t-to":v()}],"mask-image-r-from-pos":[{"mask-r-from":R()}],"mask-image-r-to-pos":[{"mask-r-to":R()}],"mask-image-r-from-color":[{"mask-r-from":v()}],"mask-image-r-to-color":[{"mask-r-to":v()}],"mask-image-b-from-pos":[{"mask-b-from":R()}],"mask-image-b-to-pos":[{"mask-b-to":R()}],"mask-image-b-from-color":[{"mask-b-from":v()}],"mask-image-b-to-color":[{"mask-b-to":v()}],"mask-image-l-from-pos":[{"mask-l-from":R()}],"mask-image-l-to-pos":[{"mask-l-to":R()}],"mask-image-l-from-color":[{"mask-l-from":v()}],"mask-image-l-to-color":[{"mask-l-to":v()}],"mask-image-x-from-pos":[{"mask-x-from":R()}],"mask-image-x-to-pos":[{"mask-x-to":R()}],"mask-image-x-from-color":[{"mask-x-from":v()}],"mask-image-x-to-color":[{"mask-x-to":v()}],"mask-image-y-from-pos":[{"mask-y-from":R()}],"mask-image-y-to-pos":[{"mask-y-to":R()}],"mask-image-y-from-color":[{"mask-y-from":v()}],"mask-image-y-to-color":[{"mask-y-to":v()}],"mask-image-radial":[{"mask-radial":[g,m]}],"mask-image-radial-from-pos":[{"mask-radial-from":R()}],"mask-image-radial-to-pos":[{"mask-radial-to":R()}],"mask-image-radial-from-color":[{"mask-radial-from":v()}],"mask-image-radial-to-color":[{"mask-radial-to":v()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":x()}],"mask-image-conic-pos":[{"mask-conic":[z]}],"mask-image-conic-from-pos":[{"mask-conic-from":R()}],"mask-image-conic-to-pos":[{"mask-conic-to":R()}],"mask-image-conic-from-color":[{"mask-conic-from":v()}],"mask-image-conic-to-color":[{"mask-conic-to":v()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:fe()}],"mask-repeat":[{mask:Ue()}],"mask-size":[{mask:qe()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",g,m]}],filter:[{filter:["","none",g,m]}],blur:[{blur:Ke()}],brightness:[{brightness:[z,g,m]}],contrast:[{contrast:[z,g,m]}],"drop-shadow":[{"drop-shadow":["","none",h,Qe,Xe]}],"drop-shadow-color":[{"drop-shadow":v()}],grayscale:[{grayscale:["",z,g,m]}],"hue-rotate":[{"hue-rotate":[z,g,m]}],invert:[{invert:["",z,g,m]}],saturate:[{saturate:[z,g,m]}],sepia:[{sepia:["",z,g,m]}],"backdrop-filter":[{"backdrop-filter":["","none",g,m]}],"backdrop-blur":[{"backdrop-blur":Ke()}],"backdrop-brightness":[{"backdrop-brightness":[z,g,m]}],"backdrop-contrast":[{"backdrop-contrast":[z,g,m]}],"backdrop-grayscale":[{"backdrop-grayscale":["",z,g,m]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[z,g,m]}],"backdrop-invert":[{"backdrop-invert":["",z,g,m]}],"backdrop-opacity":[{"backdrop-opacity":[z,g,m]}],"backdrop-saturate":[{"backdrop-saturate":[z,g,m]}],"backdrop-sepia":[{"backdrop-sepia":["",z,g,m]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":_()}],"border-spacing-x":[{"border-spacing-x":_()}],"border-spacing-y":[{"border-spacing-y":_()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",g,m]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[z,"initial",g,m]}],ease:[{ease:["linear","initial",K,g,m]}],delay:[{delay:[z,g,m]}],animate:[{animate:["none",w,g,m]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[b,g,m]}],"perspective-origin":[{"perspective-origin":S()}],rotate:[{rotate:Se()}],"rotate-x":[{"rotate-x":Se()}],"rotate-y":[{"rotate-y":Se()}],"rotate-z":[{"rotate-z":Se()}],scale:[{scale:$e()}],"scale-x":[{"scale-x":$e()}],"scale-y":[{"scale-y":$e()}],"scale-z":[{"scale-z":$e()}],"scale-3d":["scale-3d"],skew:[{skew:Fe()}],"skew-x":[{"skew-x":Fe()}],"skew-y":[{"skew-y":Fe()}],transform:[{transform:[g,m,"","none","gpu","cpu"]}],"transform-origin":[{origin:S()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:Re()}],"translate-x":[{"translate-x":Re()}],"translate-y":[{"translate-y":Re()}],"translate-z":[{"translate-z":Re()}],"translate-none":["translate-none"],accent:[{accent:v()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:v()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",g,m]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":_()}],"scroll-mx":[{"scroll-mx":_()}],"scroll-my":[{"scroll-my":_()}],"scroll-ms":[{"scroll-ms":_()}],"scroll-me":[{"scroll-me":_()}],"scroll-mt":[{"scroll-mt":_()}],"scroll-mr":[{"scroll-mr":_()}],"scroll-mb":[{"scroll-mb":_()}],"scroll-ml":[{"scroll-ml":_()}],"scroll-p":[{"scroll-p":_()}],"scroll-px":[{"scroll-px":_()}],"scroll-py":[{"scroll-py":_()}],"scroll-ps":[{"scroll-ps":_()}],"scroll-pe":[{"scroll-pe":_()}],"scroll-pt":[{"scroll-pt":_()}],"scroll-pr":[{"scroll-pr":_()}],"scroll-pb":[{"scroll-pb":_()}],"scroll-pl":[{"scroll-pl":_()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",g,m]}],fill:[{fill:["none",...v()]}],"stroke-w":[{stroke:[z,Ve,Oe,kt]}],stroke:[{stroke:["none",...v()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}},fu=ko(Mo);function l(e,t,n){function r(a,c){if(a._zod||Object.defineProperty(a,"_zod",{value:{def:c,constr:s,traits:new Set},enumerable:!1}),a._zod.traits.has(e))return;a._zod.traits.add(e),t(a,c);const u=s.prototype,d=Object.keys(u);for(let p=0;p<d.length;p++){const f=d[p];f in a||(a[f]=u[f].bind(a))}}const o=n?.Parent??Object;class i extends o{}Object.defineProperty(i,"name",{value:e});function s(a){var c;const u=n?.Parent?new i:this;r(u,a),(c=u._zod).deferred??(c.deferred=[]);for(const d of u._zod.deferred)d();return u}return Object.defineProperty(s,"init",{value:r}),Object.defineProperty(s,Symbol.hasInstance,{value:a=>n?.Parent&&a instanceof n.Parent?!0:a?._zod?.traits?.has(e)}),Object.defineProperty(s,"name",{value:e}),s}class Ce extends Error{constructor(){super("Encountered Promise during synchronous parse. Use .parseAsync() instead.")}}class Hn extends Error{constructor(t){super(`Encountered unidirectional transform during encode: ${t}`),this.name="ZodEncodeError"}}const Yn={};function Ee(e){return Yn}function Xn(e){const t=Object.values(e).filter(r=>typeof r=="number");return Object.entries(e).filter(([r,o])=>t.indexOf(+r)===-1).map(([r,o])=>o)}function Pt(e,t){return typeof t=="bigint"?t.toString():t}function Lt(e){return{get value(){{const t=e();return Object.defineProperty(this,"value",{value:t}),t}}}}function Ut(e){return e==null}function Ft(e){const t=e.startsWith("^")?1:0,n=e.endsWith("$")?e.length-1:e.length;return e.slice(t,n)}const dn=Symbol("evaluating");function Z(e,t,n){let r;Object.defineProperty(e,t,{get(){if(r!==dn)return r===void 0&&(r=dn,r=n()),r},set(o){Object.defineProperty(e,t,{value:o})},configurable:!0})}function xe(e,t,n){Object.defineProperty(e,t,{value:n,writable:!0,enumerable:!0,configurable:!0})}function ye(...e){const t={};for(const n of e){const r=Object.getOwnPropertyDescriptors(n);Object.assign(t,r)}return Object.defineProperties({},t)}function fn(e){return JSON.stringify(e)}function Vo(e){return e.toLowerCase().trim().replace(/[^\w\s-]/g,"").replace(/[\s_-]+/g,"-").replace(/^-+|-+$/g,"")}const Qn="captureStackTrace"in Error?Error.captureStackTrace:(...e)=>{};function ot(e){return typeof e=="object"&&e!==null&&!Array.isArray(e)}const Jo=Lt(()=>{if(typeof navigator<"u"&&navigator?.userAgent?.includes("Cloudflare"))return!1;try{const e=Function;return new e(""),!0}catch{return!1}});function We(e){if(ot(e)===!1)return!1;const t=e.constructor;if(t===void 0||typeof t!="function")return!0;const n=t.prototype;return!(ot(n)===!1||Object.prototype.hasOwnProperty.call(n,"isPrototypeOf")===!1)}function er(e){return We(e)?{...e}:Array.isArray(e)?[...e]:e}const Wo=new Set(["string","number","symbol"]);function je(e){return e.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}function ke(e,t,n){const r=new e._zod.constr(t??e._zod.def);return(!t||n?.parent)&&(r._zod.parent=e),r}function y(e){const t=e;if(!t)return{};if(typeof t=="string")return{error:()=>t};if(t?.message!==void 0){if(t?.error!==void 0)throw new Error("Cannot specify both `message` and `error` params");t.error=t.message}return delete t.message,typeof t.error=="string"?{...t,error:()=>t.error}:t}function Go(e){return Object.keys(e).filter(t=>e[t]._zod.optin==="optional"&&e[t]._zod.optout==="optional")}function Bo(e,t){const n=e._zod.def,r=n.checks;if(r&&r.length>0)throw new Error(".pick() cannot be used on object schemas containing refinements");const i=ye(e._zod.def,{get shape(){const s={};for(const a in t){if(!(a in n.shape))throw new Error(`Unrecognized key: "${a}"`);t[a]&&(s[a]=n.shape[a])}return xe(this,"shape",s),s},checks:[]});return ke(e,i)}function qo(e,t){const n=e._zod.def,r=n.checks;if(r&&r.length>0)throw new Error(".omit() cannot be used on object schemas containing refinements");const i=ye(e._zod.def,{get shape(){const s={...e._zod.def.shape};for(const a in t){if(!(a in n.shape))throw new Error(`Unrecognized key: "${a}"`);t[a]&&delete s[a]}return xe(this,"shape",s),s},checks:[]});return ke(e,i)}function Ko(e,t){if(!We(t))throw new Error("Invalid input to extend: expected a plain object");const n=e._zod.def.checks;if(n&&n.length>0){const i=e._zod.def.shape;for(const s in t)if(Object.getOwnPropertyDescriptor(i,s)!==void 0)throw new Error("Cannot overwrite keys on object schemas containing refinements. Use `.safeExtend()` instead.")}const o=ye(e._zod.def,{get shape(){const i={...e._zod.def.shape,...t};return xe(this,"shape",i),i}});return ke(e,o)}function Ho(e,t){if(!We(t))throw new Error("Invalid input to safeExtend: expected a plain object");const n=ye(e._zod.def,{get shape(){const r={...e._zod.def.shape,...t};return xe(this,"shape",r),r}});return ke(e,n)}function Yo(e,t){const n=ye(e._zod.def,{get shape(){const r={...e._zod.def.shape,...t._zod.def.shape};return xe(this,"shape",r),r},get catchall(){return t._zod.def.catchall},checks:[]});return ke(e,n)}function Xo(e,t,n){const o=t._zod.def.checks;if(o&&o.length>0)throw new Error(".partial() cannot be used on object schemas containing refinements");const s=ye(t._zod.def,{get shape(){const a=t._zod.def.shape,c={...a};if(n)for(const u in n){if(!(u in a))throw new Error(`Unrecognized key: "${u}"`);n[u]&&(c[u]=e?new e({type:"optional",innerType:a[u]}):a[u])}else for(const u in a)c[u]=e?new e({type:"optional",innerType:a[u]}):a[u];return xe(this,"shape",c),c},checks:[]});return ke(t,s)}function Qo(e,t,n){const r=ye(t._zod.def,{get shape(){const o=t._zod.def.shape,i={...o};if(n)for(const s in n){if(!(s in i))throw new Error(`Unrecognized key: "${s}"`);n[s]&&(i[s]=new e({type:"nonoptional",innerType:o[s]}))}else for(const s in o)i[s]=new e({type:"nonoptional",innerType:o[s]});return xe(this,"shape",i),i}});return ke(t,r)}function Ie(e,t=0){if(e.aborted===!0)return!0;for(let n=t;n<e.issues.length;n++)if(e.issues[n]?.continue!==!0)return!0;return!1}function tr(e,t){return t.map(n=>{var r;return(r=n).path??(r.path=[]),n.path.unshift(e),n})}function et(e){return typeof e=="string"?e:e?.message}function Ze(e,t,n){const r={...e,path:e.path??[]};if(!e.message){const o=et(e.inst?._zod.def?.error?.(e))??et(t?.error?.(e))??et(n.customError?.(e))??et(n.localeError?.(e))??"Invalid input";r.message=o}return delete r.inst,delete r.continue,t?.reportInput||delete r.input,r}function Mt(e){return Array.isArray(e)?"array":typeof e=="string"?"string":"unknown"}function Ge(...e){const[t,n,r]=e;return typeof t=="string"?{message:t,code:"custom",input:n,inst:r}:{...t}}const nr=(e,t)=>{e.name="$ZodError",Object.defineProperty(e,"_zod",{value:e._zod,enumerable:!1}),Object.defineProperty(e,"issues",{value:t,enumerable:!1}),e.message=JSON.stringify(t,Pt,2),Object.defineProperty(e,"toString",{value:()=>e.message,enumerable:!1})},rr=l("$ZodError",nr),or=l("$ZodError",nr,{Parent:Error});function es(e,t=n=>n.message){const n={},r=[];for(const o of e.issues)o.path.length>0?(n[o.path[0]]=n[o.path[0]]||[],n[o.path[0]].push(t(o))):r.push(t(o));return{formErrors:r,fieldErrors:n}}function ts(e,t=n=>n.message){const n={_errors:[]},r=o=>{for(const i of o.issues)if(i.code==="invalid_union"&&i.errors.length)i.errors.map(s=>r({issues:s}));else if(i.code==="invalid_key")r({issues:i.issues});else if(i.code==="invalid_element")r({issues:i.issues});else if(i.path.length===0)n._errors.push(t(i));else{let s=n,a=0;for(;a<i.path.length;){const c=i.path[a];a===i.path.length-1?(s[c]=s[c]||{_errors:[]},s[c]._errors.push(t(i))):s[c]=s[c]||{_errors:[]},s=s[c],a++}}};return r(e),n}const Vt=e=>(t,n,r,o)=>{const i=r?Object.assign(r,{async:!1}):{async:!1},s=t._zod.run({value:n,issues:[]},i);if(s instanceof Promise)throw new Ce;if(s.issues.length){const a=new(o?.Err??e)(s.issues.map(c=>Ze(c,i,Ee())));throw Qn(a,o?.callee),a}return s.value},Jt=e=>async(t,n,r,o)=>{const i=r?Object.assign(r,{async:!0}):{async:!0};let s=t._zod.run({value:n,issues:[]},i);if(s instanceof Promise&&(s=await s),s.issues.length){const a=new(o?.Err??e)(s.issues.map(c=>Ze(c,i,Ee())));throw Qn(a,o?.callee),a}return s.value},ct=e=>(t,n,r)=>{const o=r?{...r,async:!1}:{async:!1},i=t._zod.run({value:n,issues:[]},o);if(i instanceof Promise)throw new Ce;return i.issues.length?{success:!1,error:new(e??rr)(i.issues.map(s=>Ze(s,o,Ee())))}:{success:!0,data:i.value}},ns=ct(or),ut=e=>async(t,n,r)=>{const o=r?Object.assign(r,{async:!0}):{async:!0};let i=t._zod.run({value:n,issues:[]},o);return i instanceof Promise&&(i=await i),i.issues.length?{success:!1,error:new e(i.issues.map(s=>Ze(s,o,Ee())))}:{success:!0,data:i.value}},rs=ut(or),os=e=>(t,n,r)=>{const o=r?Object.assign(r,{direction:"backward"}):{direction:"backward"};return Vt(e)(t,n,o)},ss=e=>(t,n,r)=>Vt(e)(t,n,r),is=e=>async(t,n,r)=>{const o=r?Object.assign(r,{direction:"backward"}):{direction:"backward"};return Jt(e)(t,n,o)},as=e=>async(t,n,r)=>Jt(e)(t,n,r),cs=e=>(t,n,r)=>{const o=r?Object.assign(r,{direction:"backward"}):{direction:"backward"};return ct(e)(t,n,o)},us=e=>(t,n,r)=>ct(e)(t,n,r),ls=e=>async(t,n,r)=>{const o=r?Object.assign(r,{direction:"backward"}):{direction:"backward"};return ut(e)(t,n,o)},ds=e=>async(t,n,r)=>ut(e)(t,n,r),fs=/^[cC][^\s-]{8,}$/,ps=/^[0-9a-z]+$/,hs=/^[0-9A-HJKMNP-TV-Za-hjkmnp-tv-z]{26}$/,ms=/^[0-9a-vA-V]{20}$/,gs=/^[A-Za-z0-9]{27}$/,bs=/^[a-zA-Z0-9_-]{21}$/,vs=/^P(?:(\d+W)|(?!.*W)(?=\d|T\d)(\d+Y)?(\d+M)?(\d+D)?(T(?=\d)(\d+H)?(\d+M)?(\d+([.,]\d+)?S)?)?)$/,_s=/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12})$/,pn=e=>e?new RegExp(`^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-${e}[0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12})$`):/^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$/,ws=/^(?!\.)(?!.*\.\.)([A-Za-z0-9_'+\-\.]*)[A-Za-z0-9_+-]@([A-Za-z0-9][A-Za-z0-9\-]*\.)+[A-Za-z]{2,}$/,ys="^(\\p{Extended_Pictographic}|\\p{Emoji_Component})+$";function ks(){return new RegExp(ys,"u")}const zs=/^(?:(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(?:25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])$/,Ss=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,7}:|([0-9a-fA-F]{1,4}:){1,6}:[0-9a-fA-F]{1,4}|([0-9a-fA-F]{1,4}:){1,5}(:[0-9a-fA-F]{1,4}){1,2}|([0-9a-fA-F]{1,4}:){1,4}(:[0-9a-fA-F]{1,4}){1,3}|([0-9a-fA-F]{1,4}:){1,3}(:[0-9a-fA-F]{1,4}){1,4}|([0-9a-fA-F]{1,4}:){1,2}(:[0-9a-fA-F]{1,4}){1,5}|[0-9a-fA-F]{1,4}:((:[0-9a-fA-F]{1,4}){1,6})|:((:[0-9a-fA-F]{1,4}){1,7}|:))$/,$s=/^((25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\.){3}(25[0-5]|2[0-4][0-9]|1[0-9][0-9]|[1-9][0-9]|[0-9])\/([0-9]|[1-2][0-9]|3[0-2])$/,Os=/^(([0-9a-fA-F]{1,4}:){7}[0-9a-fA-F]{1,4}|::|([0-9a-fA-F]{1,4})?::([0-9a-fA-F]{1,4}:?){0,6})\/(12[0-8]|1[01][0-9]|[1-9]?[0-9])$/,Es=/^$|^(?:[0-9a-zA-Z+/]{4})*(?:(?:[0-9a-zA-Z+/]{2}==)|(?:[0-9a-zA-Z+/]{3}=))?$/,sr=/^[A-Za-z0-9_-]*$/,Zs=/^\+[1-9]\d{6,14}$/,ir="(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))",xs=new RegExp(`^${ir}$`);function ar(e){const t="(?:[01]\\d|2[0-3]):[0-5]\\d";return typeof e.precision=="number"?e.precision===-1?`${t}`:e.precision===0?`${t}:[0-5]\\d`:`${t}:[0-5]\\d\\.\\d{${e.precision}}`:`${t}(?::[0-5]\\d(?:\\.\\d+)?)?`}function Rs(e){return new RegExp(`^${ar(e)}$`)}function Ts(e){const t=ar({precision:e.precision}),n=["Z"];e.local&&n.push(""),e.offset&&n.push("([+-](?:[01]\\d|2[0-3]):[0-5]\\d)");const r=`${t}(?:${n.join("|")})`;return new RegExp(`^${ir}T(?:${r})$`)}const Ps=e=>{const t=e?`[\\s\\S]{${e?.minimum??0},${e?.maximum??""}}`:"[\\s\\S]*";return new RegExp(`^${t}$`)},Is=/^[^A-Z]*$/,As=/^[^a-z]*$/,le=l("$ZodCheck",(e,t)=>{var n;e._zod??(e._zod={}),e._zod.def=t,(n=e._zod).onattach??(n.onattach=[])}),Cs=l("$ZodCheckMaxLength",(e,t)=>{var n;le.init(e,t),(n=e._zod.def).when??(n.when=r=>{const o=r.value;return!Ut(o)&&o.length!==void 0}),e._zod.onattach.push(r=>{const o=r._zod.bag.maximum??Number.POSITIVE_INFINITY;t.maximum<o&&(r._zod.bag.maximum=t.maximum)}),e._zod.check=r=>{const o=r.value;if(o.length<=t.maximum)return;const s=Mt(o);r.issues.push({origin:s,code:"too_big",maximum:t.maximum,inclusive:!0,input:o,inst:e,continue:!t.abort})}}),js=l("$ZodCheckMinLength",(e,t)=>{var n;le.init(e,t),(n=e._zod.def).when??(n.when=r=>{const o=r.value;return!Ut(o)&&o.length!==void 0}),e._zod.onattach.push(r=>{const o=r._zod.bag.minimum??Number.NEGATIVE_INFINITY;t.minimum>o&&(r._zod.bag.minimum=t.minimum)}),e._zod.check=r=>{const o=r.value;if(o.length>=t.minimum)return;const s=Mt(o);r.issues.push({origin:s,code:"too_small",minimum:t.minimum,inclusive:!0,input:o,inst:e,continue:!t.abort})}}),Ds=l("$ZodCheckLengthEquals",(e,t)=>{var n;le.init(e,t),(n=e._zod.def).when??(n.when=r=>{const o=r.value;return!Ut(o)&&o.length!==void 0}),e._zod.onattach.push(r=>{const o=r._zod.bag;o.minimum=t.length,o.maximum=t.length,o.length=t.length}),e._zod.check=r=>{const o=r.value,i=o.length;if(i===t.length)return;const s=Mt(o),a=i>t.length;r.issues.push({origin:s,...a?{code:"too_big",maximum:t.length}:{code:"too_small",minimum:t.length},inclusive:!0,exact:!0,input:r.value,inst:e,continue:!t.abort})}}),lt=l("$ZodCheckStringFormat",(e,t)=>{var n,r;le.init(e,t),e._zod.onattach.push(o=>{const i=o._zod.bag;i.format=t.format,t.pattern&&(i.patterns??(i.patterns=new Set),i.patterns.add(t.pattern))}),t.pattern?(n=e._zod).check??(n.check=o=>{t.pattern.lastIndex=0,!t.pattern.test(o.value)&&o.issues.push({origin:"string",code:"invalid_format",format:t.format,input:o.value,...t.pattern?{pattern:t.pattern.toString()}:{},inst:e,continue:!t.abort})}):(r=e._zod).check??(r.check=()=>{})}),Ns=l("$ZodCheckRegex",(e,t)=>{lt.init(e,t),e._zod.check=n=>{t.pattern.lastIndex=0,!t.pattern.test(n.value)&&n.issues.push({origin:"string",code:"invalid_format",format:"regex",input:n.value,pattern:t.pattern.toString(),inst:e,continue:!t.abort})}}),Ls=l("$ZodCheckLowerCase",(e,t)=>{t.pattern??(t.pattern=Is),lt.init(e,t)}),Us=l("$ZodCheckUpperCase",(e,t)=>{t.pattern??(t.pattern=As),lt.init(e,t)}),Fs=l("$ZodCheckIncludes",(e,t)=>{le.init(e,t);const n=je(t.includes),r=new RegExp(typeof t.position=="number"?`^.{${t.position}}${n}`:n);t.pattern=r,e._zod.onattach.push(o=>{const i=o._zod.bag;i.patterns??(i.patterns=new Set),i.patterns.add(r)}),e._zod.check=o=>{o.value.includes(t.includes,t.position)||o.issues.push({origin:"string",code:"invalid_format",format:"includes",includes:t.includes,input:o.value,inst:e,continue:!t.abort})}}),Ms=l("$ZodCheckStartsWith",(e,t)=>{le.init(e,t);const n=new RegExp(`^${je(t.prefix)}.*`);t.pattern??(t.pattern=n),e._zod.onattach.push(r=>{const o=r._zod.bag;o.patterns??(o.patterns=new Set),o.patterns.add(n)}),e._zod.check=r=>{r.value.startsWith(t.prefix)||r.issues.push({origin:"string",code:"invalid_format",format:"starts_with",prefix:t.prefix,input:r.value,inst:e,continue:!t.abort})}}),Vs=l("$ZodCheckEndsWith",(e,t)=>{le.init(e,t);const n=new RegExp(`.*${je(t.suffix)}$`);t.pattern??(t.pattern=n),e._zod.onattach.push(r=>{const o=r._zod.bag;o.patterns??(o.patterns=new Set),o.patterns.add(n)}),e._zod.check=r=>{r.value.endsWith(t.suffix)||r.issues.push({origin:"string",code:"invalid_format",format:"ends_with",suffix:t.suffix,input:r.value,inst:e,continue:!t.abort})}}),Js=l("$ZodCheckOverwrite",(e,t)=>{le.init(e,t),e._zod.check=n=>{n.value=t.tx(n.value)}});class Ws{constructor(t=[]){this.content=[],this.indent=0,this&&(this.args=t)}indented(t){this.indent+=1,t(this),this.indent-=1}write(t){if(typeof t=="function"){t(this,{execution:"sync"}),t(this,{execution:"async"});return}const r=t.split(`
|
|
2
|
+
`).filter(s=>s),o=Math.min(...r.map(s=>s.length-s.trimStart().length)),i=r.map(s=>s.slice(o)).map(s=>" ".repeat(this.indent*2)+s);for(const s of i)this.content.push(s)}compile(){const t=Function,n=this?.args,o=[...(this?.content??[""]).map(i=>` ${i}`)];return new t(...n,o.join(`
|
|
3
|
+
`))}}const Gs={major:4,minor:3,patch:6},L=l("$ZodType",(e,t)=>{var n;e??(e={}),e._zod.def=t,e._zod.bag=e._zod.bag||{},e._zod.version=Gs;const r=[...e._zod.def.checks??[]];e._zod.traits.has("$ZodCheck")&&r.unshift(e);for(const o of r)for(const i of o._zod.onattach)i(e);if(r.length===0)(n=e._zod).deferred??(n.deferred=[]),e._zod.deferred?.push(()=>{e._zod.run=e._zod.parse});else{const o=(s,a,c)=>{let u=Ie(s),d;for(const p of a){if(p._zod.def.when){if(!p._zod.def.when(s))continue}else if(u)continue;const f=s.issues.length,h=p._zod.check(s);if(h instanceof Promise&&c?.async===!1)throw new Ce;if(d||h instanceof Promise)d=(d??Promise.resolve()).then(async()=>{await h,s.issues.length!==f&&(u||(u=Ie(s,f)))});else{if(s.issues.length===f)continue;u||(u=Ie(s,f))}}return d?d.then(()=>s):s},i=(s,a,c)=>{if(Ie(s))return s.aborted=!0,s;const u=o(a,r,c);if(u instanceof Promise){if(c.async===!1)throw new Ce;return u.then(d=>e._zod.parse(d,c))}return e._zod.parse(u,c)};e._zod.run=(s,a)=>{if(a.skipChecks)return e._zod.parse(s,a);if(a.direction==="backward"){const u=e._zod.parse({value:s.value,issues:[]},{...a,skipChecks:!0});return u instanceof Promise?u.then(d=>i(d,s,a)):i(u,s,a)}const c=e._zod.parse(s,a);if(c instanceof Promise){if(a.async===!1)throw new Ce;return c.then(u=>o(u,r,a))}return o(c,r,a)}}Z(e,"~standard",()=>({validate:o=>{try{const i=ns(e,o);return i.success?{value:i.data}:{issues:i.error?.issues}}catch{return rs(e,o).then(s=>s.success?{value:s.data}:{issues:s.error?.issues})}},vendor:"zod",version:1}))}),Wt=l("$ZodString",(e,t)=>{L.init(e,t),e._zod.pattern=[...e?._zod.bag?.patterns??[]].pop()??Ps(e._zod.bag),e._zod.parse=(n,r)=>{if(t.coerce)try{n.value=String(n.value)}catch{}return typeof n.value=="string"||n.issues.push({expected:"string",code:"invalid_type",input:n.value,inst:e}),n}}),P=l("$ZodStringFormat",(e,t)=>{lt.init(e,t),Wt.init(e,t)}),Bs=l("$ZodGUID",(e,t)=>{t.pattern??(t.pattern=_s),P.init(e,t)}),qs=l("$ZodUUID",(e,t)=>{if(t.version){const r={v1:1,v2:2,v3:3,v4:4,v5:5,v6:6,v7:7,v8:8}[t.version];if(r===void 0)throw new Error(`Invalid UUID version: "${t.version}"`);t.pattern??(t.pattern=pn(r))}else t.pattern??(t.pattern=pn());P.init(e,t)}),Ks=l("$ZodEmail",(e,t)=>{t.pattern??(t.pattern=ws),P.init(e,t)}),Hs=l("$ZodURL",(e,t)=>{P.init(e,t),e._zod.check=n=>{try{const r=n.value.trim(),o=new URL(r);t.hostname&&(t.hostname.lastIndex=0,t.hostname.test(o.hostname)||n.issues.push({code:"invalid_format",format:"url",note:"Invalid hostname",pattern:t.hostname.source,input:n.value,inst:e,continue:!t.abort})),t.protocol&&(t.protocol.lastIndex=0,t.protocol.test(o.protocol.endsWith(":")?o.protocol.slice(0,-1):o.protocol)||n.issues.push({code:"invalid_format",format:"url",note:"Invalid protocol",pattern:t.protocol.source,input:n.value,inst:e,continue:!t.abort})),t.normalize?n.value=o.href:n.value=r;return}catch{n.issues.push({code:"invalid_format",format:"url",input:n.value,inst:e,continue:!t.abort})}}}),Ys=l("$ZodEmoji",(e,t)=>{t.pattern??(t.pattern=ks()),P.init(e,t)}),Xs=l("$ZodNanoID",(e,t)=>{t.pattern??(t.pattern=bs),P.init(e,t)}),Qs=l("$ZodCUID",(e,t)=>{t.pattern??(t.pattern=fs),P.init(e,t)}),ei=l("$ZodCUID2",(e,t)=>{t.pattern??(t.pattern=ps),P.init(e,t)}),ti=l("$ZodULID",(e,t)=>{t.pattern??(t.pattern=hs),P.init(e,t)}),ni=l("$ZodXID",(e,t)=>{t.pattern??(t.pattern=ms),P.init(e,t)}),ri=l("$ZodKSUID",(e,t)=>{t.pattern??(t.pattern=gs),P.init(e,t)}),oi=l("$ZodISODateTime",(e,t)=>{t.pattern??(t.pattern=Ts(t)),P.init(e,t)}),si=l("$ZodISODate",(e,t)=>{t.pattern??(t.pattern=xs),P.init(e,t)}),ii=l("$ZodISOTime",(e,t)=>{t.pattern??(t.pattern=Rs(t)),P.init(e,t)}),ai=l("$ZodISODuration",(e,t)=>{t.pattern??(t.pattern=vs),P.init(e,t)}),ci=l("$ZodIPv4",(e,t)=>{t.pattern??(t.pattern=zs),P.init(e,t),e._zod.bag.format="ipv4"}),ui=l("$ZodIPv6",(e,t)=>{t.pattern??(t.pattern=Ss),P.init(e,t),e._zod.bag.format="ipv6",e._zod.check=n=>{try{new URL(`http://[${n.value}]`)}catch{n.issues.push({code:"invalid_format",format:"ipv6",input:n.value,inst:e,continue:!t.abort})}}}),li=l("$ZodCIDRv4",(e,t)=>{t.pattern??(t.pattern=$s),P.init(e,t)}),di=l("$ZodCIDRv6",(e,t)=>{t.pattern??(t.pattern=Os),P.init(e,t),e._zod.check=n=>{const r=n.value.split("/");try{if(r.length!==2)throw new Error;const[o,i]=r;if(!i)throw new Error;const s=Number(i);if(`${s}`!==i)throw new Error;if(s<0||s>128)throw new Error;new URL(`http://[${o}]`)}catch{n.issues.push({code:"invalid_format",format:"cidrv6",input:n.value,inst:e,continue:!t.abort})}}});function cr(e){if(e==="")return!0;if(e.length%4!==0)return!1;try{return atob(e),!0}catch{return!1}}const fi=l("$ZodBase64",(e,t)=>{t.pattern??(t.pattern=Es),P.init(e,t),e._zod.bag.contentEncoding="base64",e._zod.check=n=>{cr(n.value)||n.issues.push({code:"invalid_format",format:"base64",input:n.value,inst:e,continue:!t.abort})}});function pi(e){if(!sr.test(e))return!1;const t=e.replace(/[-_]/g,r=>r==="-"?"+":"/"),n=t.padEnd(Math.ceil(t.length/4)*4,"=");return cr(n)}const hi=l("$ZodBase64URL",(e,t)=>{t.pattern??(t.pattern=sr),P.init(e,t),e._zod.bag.contentEncoding="base64url",e._zod.check=n=>{pi(n.value)||n.issues.push({code:"invalid_format",format:"base64url",input:n.value,inst:e,continue:!t.abort})}}),mi=l("$ZodE164",(e,t)=>{t.pattern??(t.pattern=Zs),P.init(e,t)});function gi(e,t=null){try{const n=e.split(".");if(n.length!==3)return!1;const[r]=n;if(!r)return!1;const o=JSON.parse(atob(r));return!("typ"in o&&o?.typ!=="JWT"||!o.alg||t&&(!("alg"in o)||o.alg!==t))}catch{return!1}}const bi=l("$ZodJWT",(e,t)=>{P.init(e,t),e._zod.check=n=>{gi(n.value,t.alg)||n.issues.push({code:"invalid_format",format:"jwt",input:n.value,inst:e,continue:!t.abort})}}),vi=l("$ZodUnknown",(e,t)=>{L.init(e,t),e._zod.parse=n=>n}),_i=l("$ZodNever",(e,t)=>{L.init(e,t),e._zod.parse=(n,r)=>(n.issues.push({expected:"never",code:"invalid_type",input:n.value,inst:e}),n)});function hn(e,t,n){e.issues.length&&t.issues.push(...tr(n,e.issues)),t.value[n]=e.value}const wi=l("$ZodArray",(e,t)=>{L.init(e,t),e._zod.parse=(n,r)=>{const o=n.value;if(!Array.isArray(o))return n.issues.push({expected:"array",code:"invalid_type",input:o,inst:e}),n;n.value=Array(o.length);const i=[];for(let s=0;s<o.length;s++){const a=o[s],c=t.element._zod.run({value:a,issues:[]},r);c instanceof Promise?i.push(c.then(u=>hn(u,n,s))):hn(c,n,s)}return i.length?Promise.all(i).then(()=>n):n}});function st(e,t,n,r,o){if(e.issues.length){if(o&&!(n in r))return;t.issues.push(...tr(n,e.issues))}e.value===void 0?n in r&&(t.value[n]=void 0):t.value[n]=e.value}function ur(e){const t=Object.keys(e.shape);for(const r of t)if(!e.shape?.[r]?._zod?.traits?.has("$ZodType"))throw new Error(`Invalid element at key "${r}": expected a Zod schema`);const n=Go(e.shape);return{...e,keys:t,keySet:new Set(t),numKeys:t.length,optionalKeys:new Set(n)}}function lr(e,t,n,r,o,i){const s=[],a=o.keySet,c=o.catchall._zod,u=c.def.type,d=c.optout==="optional";for(const p in t){if(a.has(p))continue;if(u==="never"){s.push(p);continue}const f=c.run({value:t[p],issues:[]},r);f instanceof Promise?e.push(f.then(h=>st(h,n,p,t,d))):st(f,n,p,t,d)}return s.length&&n.issues.push({code:"unrecognized_keys",keys:s,input:t,inst:i}),e.length?Promise.all(e).then(()=>n):n}const yi=l("$ZodObject",(e,t)=>{if(L.init(e,t),!Object.getOwnPropertyDescriptor(t,"shape")?.get){const a=t.shape;Object.defineProperty(t,"shape",{get:()=>{const c={...a};return Object.defineProperty(t,"shape",{value:c}),c}})}const r=Lt(()=>ur(t));Z(e._zod,"propValues",()=>{const a=t.shape,c={};for(const u in a){const d=a[u]._zod;if(d.values){c[u]??(c[u]=new Set);for(const p of d.values)c[u].add(p)}}return c});const o=ot,i=t.catchall;let s;e._zod.parse=(a,c)=>{s??(s=r.value);const u=a.value;if(!o(u))return a.issues.push({expected:"object",code:"invalid_type",input:u,inst:e}),a;a.value={};const d=[],p=s.shape;for(const f of s.keys){const h=p[f],k=h._zod.optout==="optional",b=h._zod.run({value:u[f],issues:[]},c);b instanceof Promise?d.push(b.then($=>st($,a,f,u,k))):st(b,a,f,u,k)}return i?lr(d,u,a,c,r.value,e):d.length?Promise.all(d).then(()=>a):a}}),ki=l("$ZodObjectJIT",(e,t)=>{yi.init(e,t);const n=e._zod.parse,r=Lt(()=>ur(t)),o=f=>{const h=new Ws(["shape","payload","ctx"]),k=r.value,b=j=>{const x=fn(j);return`shape[${x}]._zod.run({ value: input[${x}], issues: [] }, ctx)`};h.write("const input = payload.value;");const $=Object.create(null);let K=0;for(const j of k.keys)$[j]=`key_${K++}`;h.write("const newResult = {};");for(const j of k.keys){const x=$[j],S=fn(j),V=f[j]?._zod?.optout==="optional";h.write(`const ${x} = ${b(j)};`),V?h.write(`
|
|
4
|
+
if (${x}.issues.length) {
|
|
5
|
+
if (${S} in input) {
|
|
6
|
+
payload.issues = payload.issues.concat(${x}.issues.map(iss => ({
|
|
7
|
+
...iss,
|
|
8
|
+
path: iss.path ? [${S}, ...iss.path] : [${S}]
|
|
9
|
+
})));
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
|
|
13
|
+
if (${x}.value === undefined) {
|
|
14
|
+
if (${S} in input) {
|
|
15
|
+
newResult[${S}] = undefined;
|
|
16
|
+
}
|
|
17
|
+
} else {
|
|
18
|
+
newResult[${S}] = ${x}.value;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
`):h.write(`
|
|
22
|
+
if (${x}.issues.length) {
|
|
23
|
+
payload.issues = payload.issues.concat(${x}.issues.map(iss => ({
|
|
24
|
+
...iss,
|
|
25
|
+
path: iss.path ? [${S}, ...iss.path] : [${S}]
|
|
26
|
+
})));
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
if (${x}.value === undefined) {
|
|
30
|
+
if (${S} in input) {
|
|
31
|
+
newResult[${S}] = undefined;
|
|
32
|
+
}
|
|
33
|
+
} else {
|
|
34
|
+
newResult[${S}] = ${x}.value;
|
|
35
|
+
}
|
|
36
|
+
|
|
37
|
+
`)}h.write("payload.value = newResult;"),h.write("return payload;");const w=h.compile();return(j,x)=>w(f,j,x)};let i;const s=ot,a=!Yn.jitless,u=a&&Jo.value,d=t.catchall;let p;e._zod.parse=(f,h)=>{p??(p=r.value);const k=f.value;return s(k)?a&&u&&h?.async===!1&&h.jitless!==!0?(i||(i=o(t.shape)),f=i(f,h),d?lr([],k,f,h,p,e):f):n(f,h):(f.issues.push({expected:"object",code:"invalid_type",input:k,inst:e}),f)}});function mn(e,t,n,r){for(const i of e)if(i.issues.length===0)return t.value=i.value,t;const o=e.filter(i=>!Ie(i));return o.length===1?(t.value=o[0].value,o[0]):(t.issues.push({code:"invalid_union",input:t.value,inst:n,errors:e.map(i=>i.issues.map(s=>Ze(s,r,Ee())))}),t)}const zi=l("$ZodUnion",(e,t)=>{L.init(e,t),Z(e._zod,"optin",()=>t.options.some(o=>o._zod.optin==="optional")?"optional":void 0),Z(e._zod,"optout",()=>t.options.some(o=>o._zod.optout==="optional")?"optional":void 0),Z(e._zod,"values",()=>{if(t.options.every(o=>o._zod.values))return new Set(t.options.flatMap(o=>Array.from(o._zod.values)))}),Z(e._zod,"pattern",()=>{if(t.options.every(o=>o._zod.pattern)){const o=t.options.map(i=>i._zod.pattern);return new RegExp(`^(${o.map(i=>Ft(i.source)).join("|")})$`)}});const n=t.options.length===1,r=t.options[0]._zod.run;e._zod.parse=(o,i)=>{if(n)return r(o,i);let s=!1;const a=[];for(const c of t.options){const u=c._zod.run({value:o.value,issues:[]},i);if(u instanceof Promise)a.push(u),s=!0;else{if(u.issues.length===0)return u;a.push(u)}}return s?Promise.all(a).then(c=>mn(c,o,e,i)):mn(a,o,e,i)}}),Si=l("$ZodIntersection",(e,t)=>{L.init(e,t),e._zod.parse=(n,r)=>{const o=n.value,i=t.left._zod.run({value:o,issues:[]},r),s=t.right._zod.run({value:o,issues:[]},r);return i instanceof Promise||s instanceof Promise?Promise.all([i,s]).then(([c,u])=>gn(n,c,u)):gn(n,i,s)}});function It(e,t){if(e===t)return{valid:!0,data:e};if(e instanceof Date&&t instanceof Date&&+e==+t)return{valid:!0,data:e};if(We(e)&&We(t)){const n=Object.keys(t),r=Object.keys(e).filter(i=>n.indexOf(i)!==-1),o={...e,...t};for(const i of r){const s=It(e[i],t[i]);if(!s.valid)return{valid:!1,mergeErrorPath:[i,...s.mergeErrorPath]};o[i]=s.data}return{valid:!0,data:o}}if(Array.isArray(e)&&Array.isArray(t)){if(e.length!==t.length)return{valid:!1,mergeErrorPath:[]};const n=[];for(let r=0;r<e.length;r++){const o=e[r],i=t[r],s=It(o,i);if(!s.valid)return{valid:!1,mergeErrorPath:[r,...s.mergeErrorPath]};n.push(s.data)}return{valid:!0,data:n}}return{valid:!1,mergeErrorPath:[]}}function gn(e,t,n){const r=new Map;let o;for(const a of t.issues)if(a.code==="unrecognized_keys"){o??(o=a);for(const c of a.keys)r.has(c)||r.set(c,{}),r.get(c).l=!0}else e.issues.push(a);for(const a of n.issues)if(a.code==="unrecognized_keys")for(const c of a.keys)r.has(c)||r.set(c,{}),r.get(c).r=!0;else e.issues.push(a);const i=[...r].filter(([,a])=>a.l&&a.r).map(([a])=>a);if(i.length&&o&&e.issues.push({...o,keys:i}),Ie(e))return e;const s=It(t.value,n.value);if(!s.valid)throw new Error(`Unmergable intersection. Error path: ${JSON.stringify(s.mergeErrorPath)}`);return e.value=s.data,e}const $i=l("$ZodEnum",(e,t)=>{L.init(e,t);const n=Xn(t.entries),r=new Set(n);e._zod.values=r,e._zod.pattern=new RegExp(`^(${n.filter(o=>Wo.has(typeof o)).map(o=>typeof o=="string"?je(o):o.toString()).join("|")})$`),e._zod.parse=(o,i)=>{const s=o.value;return r.has(s)||o.issues.push({code:"invalid_value",values:n,input:s,inst:e}),o}}),Oi=l("$ZodLiteral",(e,t)=>{if(L.init(e,t),t.values.length===0)throw new Error("Cannot create literal schema with no valid values");const n=new Set(t.values);e._zod.values=n,e._zod.pattern=new RegExp(`^(${t.values.map(r=>typeof r=="string"?je(r):r?je(r.toString()):String(r)).join("|")})$`),e._zod.parse=(r,o)=>{const i=r.value;return n.has(i)||r.issues.push({code:"invalid_value",values:t.values,input:i,inst:e}),r}}),Ei=l("$ZodTransform",(e,t)=>{L.init(e,t),e._zod.parse=(n,r)=>{if(r.direction==="backward")throw new Hn(e.constructor.name);const o=t.transform(n.value,n);if(r.async)return(o instanceof Promise?o:Promise.resolve(o)).then(s=>(n.value=s,n));if(o instanceof Promise)throw new Ce;return n.value=o,n}});function bn(e,t){return e.issues.length&&t===void 0?{issues:[],value:void 0}:e}const dr=l("$ZodOptional",(e,t)=>{L.init(e,t),e._zod.optin="optional",e._zod.optout="optional",Z(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,void 0]):void 0),Z(e._zod,"pattern",()=>{const n=t.innerType._zod.pattern;return n?new RegExp(`^(${Ft(n.source)})?$`):void 0}),e._zod.parse=(n,r)=>{if(t.innerType._zod.optin==="optional"){const o=t.innerType._zod.run(n,r);return o instanceof Promise?o.then(i=>bn(i,n.value)):bn(o,n.value)}return n.value===void 0?n:t.innerType._zod.run(n,r)}}),Zi=l("$ZodExactOptional",(e,t)=>{dr.init(e,t),Z(e._zod,"values",()=>t.innerType._zod.values),Z(e._zod,"pattern",()=>t.innerType._zod.pattern),e._zod.parse=(n,r)=>t.innerType._zod.run(n,r)}),xi=l("$ZodNullable",(e,t)=>{L.init(e,t),Z(e._zod,"optin",()=>t.innerType._zod.optin),Z(e._zod,"optout",()=>t.innerType._zod.optout),Z(e._zod,"pattern",()=>{const n=t.innerType._zod.pattern;return n?new RegExp(`^(${Ft(n.source)}|null)$`):void 0}),Z(e._zod,"values",()=>t.innerType._zod.values?new Set([...t.innerType._zod.values,null]):void 0),e._zod.parse=(n,r)=>n.value===null?n:t.innerType._zod.run(n,r)}),Ri=l("$ZodDefault",(e,t)=>{L.init(e,t),e._zod.optin="optional",Z(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(n,r)=>{if(r.direction==="backward")return t.innerType._zod.run(n,r);if(n.value===void 0)return n.value=t.defaultValue,n;const o=t.innerType._zod.run(n,r);return o instanceof Promise?o.then(i=>vn(i,t)):vn(o,t)}});function vn(e,t){return e.value===void 0&&(e.value=t.defaultValue),e}const Ti=l("$ZodPrefault",(e,t)=>{L.init(e,t),e._zod.optin="optional",Z(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(n,r)=>(r.direction==="backward"||n.value===void 0&&(n.value=t.defaultValue),t.innerType._zod.run(n,r))}),Pi=l("$ZodNonOptional",(e,t)=>{L.init(e,t),Z(e._zod,"values",()=>{const n=t.innerType._zod.values;return n?new Set([...n].filter(r=>r!==void 0)):void 0}),e._zod.parse=(n,r)=>{const o=t.innerType._zod.run(n,r);return o instanceof Promise?o.then(i=>_n(i,e)):_n(o,e)}});function _n(e,t){return!e.issues.length&&e.value===void 0&&e.issues.push({code:"invalid_type",expected:"nonoptional",input:e.value,inst:t}),e}const Ii=l("$ZodCatch",(e,t)=>{L.init(e,t),Z(e._zod,"optin",()=>t.innerType._zod.optin),Z(e._zod,"optout",()=>t.innerType._zod.optout),Z(e._zod,"values",()=>t.innerType._zod.values),e._zod.parse=(n,r)=>{if(r.direction==="backward")return t.innerType._zod.run(n,r);const o=t.innerType._zod.run(n,r);return o instanceof Promise?o.then(i=>(n.value=i.value,i.issues.length&&(n.value=t.catchValue({...n,error:{issues:i.issues.map(s=>Ze(s,r,Ee()))},input:n.value}),n.issues=[]),n)):(n.value=o.value,o.issues.length&&(n.value=t.catchValue({...n,error:{issues:o.issues.map(i=>Ze(i,r,Ee()))},input:n.value}),n.issues=[]),n)}}),Ai=l("$ZodPipe",(e,t)=>{L.init(e,t),Z(e._zod,"values",()=>t.in._zod.values),Z(e._zod,"optin",()=>t.in._zod.optin),Z(e._zod,"optout",()=>t.out._zod.optout),Z(e._zod,"propValues",()=>t.in._zod.propValues),e._zod.parse=(n,r)=>{if(r.direction==="backward"){const i=t.out._zod.run(n,r);return i instanceof Promise?i.then(s=>tt(s,t.in,r)):tt(i,t.in,r)}const o=t.in._zod.run(n,r);return o instanceof Promise?o.then(i=>tt(i,t.out,r)):tt(o,t.out,r)}});function tt(e,t,n){return e.issues.length?(e.aborted=!0,e):t._zod.run({value:e.value,issues:e.issues},n)}const Ci=l("$ZodReadonly",(e,t)=>{L.init(e,t),Z(e._zod,"propValues",()=>t.innerType._zod.propValues),Z(e._zod,"values",()=>t.innerType._zod.values),Z(e._zod,"optin",()=>t.innerType?._zod?.optin),Z(e._zod,"optout",()=>t.innerType?._zod?.optout),e._zod.parse=(n,r)=>{if(r.direction==="backward")return t.innerType._zod.run(n,r);const o=t.innerType._zod.run(n,r);return o instanceof Promise?o.then(wn):wn(o)}});function wn(e){return e.value=Object.freeze(e.value),e}const ji=l("$ZodCustom",(e,t)=>{le.init(e,t),L.init(e,t),e._zod.parse=(n,r)=>n,e._zod.check=n=>{const r=n.value,o=t.fn(r);if(o instanceof Promise)return o.then(i=>yn(i,n,r,e));yn(o,n,r,e)}});function yn(e,t,n,r){if(!e){const o={code:"custom",input:n,inst:r,path:[...r._zod.def.path??[]],continue:!r._zod.def.abort};r._zod.def.params&&(o.params=r._zod.def.params),t.issues.push(Ge(o))}}var kn;class Di{constructor(){this._map=new WeakMap,this._idmap=new Map}add(t,...n){const r=n[0];return this._map.set(t,r),r&&typeof r=="object"&&"id"in r&&this._idmap.set(r.id,t),this}clear(){return this._map=new WeakMap,this._idmap=new Map,this}remove(t){const n=this._map.get(t);return n&&typeof n=="object"&&"id"in n&&this._idmap.delete(n.id),this._map.delete(t),this}get(t){const n=t._zod.parent;if(n){const r={...this.get(n)??{}};delete r.id;const o={...r,...this._map.get(t)};return Object.keys(o).length?o:void 0}return this._map.get(t)}has(t){return this._map.has(t)}}function Ni(){return new Di}(kn=globalThis).__zod_globalRegistry??(kn.__zod_globalRegistry=Ni());const Je=globalThis.__zod_globalRegistry;function Li(e,t){return new e({type:"string",...y(t)})}function Ui(e,t){return new e({type:"string",format:"email",check:"string_format",abort:!1,...y(t)})}function zn(e,t){return new e({type:"string",format:"guid",check:"string_format",abort:!1,...y(t)})}function Fi(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,...y(t)})}function Mi(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v4",...y(t)})}function Vi(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v6",...y(t)})}function Ji(e,t){return new e({type:"string",format:"uuid",check:"string_format",abort:!1,version:"v7",...y(t)})}function Wi(e,t){return new e({type:"string",format:"url",check:"string_format",abort:!1,...y(t)})}function Gi(e,t){return new e({type:"string",format:"emoji",check:"string_format",abort:!1,...y(t)})}function Bi(e,t){return new e({type:"string",format:"nanoid",check:"string_format",abort:!1,...y(t)})}function qi(e,t){return new e({type:"string",format:"cuid",check:"string_format",abort:!1,...y(t)})}function Ki(e,t){return new e({type:"string",format:"cuid2",check:"string_format",abort:!1,...y(t)})}function Hi(e,t){return new e({type:"string",format:"ulid",check:"string_format",abort:!1,...y(t)})}function Yi(e,t){return new e({type:"string",format:"xid",check:"string_format",abort:!1,...y(t)})}function Xi(e,t){return new e({type:"string",format:"ksuid",check:"string_format",abort:!1,...y(t)})}function Qi(e,t){return new e({type:"string",format:"ipv4",check:"string_format",abort:!1,...y(t)})}function ea(e,t){return new e({type:"string",format:"ipv6",check:"string_format",abort:!1,...y(t)})}function ta(e,t){return new e({type:"string",format:"cidrv4",check:"string_format",abort:!1,...y(t)})}function na(e,t){return new e({type:"string",format:"cidrv6",check:"string_format",abort:!1,...y(t)})}function ra(e,t){return new e({type:"string",format:"base64",check:"string_format",abort:!1,...y(t)})}function oa(e,t){return new e({type:"string",format:"base64url",check:"string_format",abort:!1,...y(t)})}function sa(e,t){return new e({type:"string",format:"e164",check:"string_format",abort:!1,...y(t)})}function ia(e,t){return new e({type:"string",format:"jwt",check:"string_format",abort:!1,...y(t)})}function aa(e,t){return new e({type:"string",format:"datetime",check:"string_format",offset:!1,local:!1,precision:null,...y(t)})}function ca(e,t){return new e({type:"string",format:"date",check:"string_format",...y(t)})}function ua(e,t){return new e({type:"string",format:"time",check:"string_format",precision:null,...y(t)})}function la(e,t){return new e({type:"string",format:"duration",check:"string_format",...y(t)})}function da(e){return new e({type:"unknown"})}function fa(e,t){return new e({type:"never",...y(t)})}function fr(e,t){return new Cs({check:"max_length",...y(t),maximum:e})}function it(e,t){return new js({check:"min_length",...y(t),minimum:e})}function pr(e,t){return new Ds({check:"length_equals",...y(t),length:e})}function pa(e,t){return new Ns({check:"string_format",format:"regex",...y(t),pattern:e})}function ha(e){return new Ls({check:"string_format",format:"lowercase",...y(e)})}function ma(e){return new Us({check:"string_format",format:"uppercase",...y(e)})}function ga(e,t){return new Fs({check:"string_format",format:"includes",...y(t),includes:e})}function ba(e,t){return new Ms({check:"string_format",format:"starts_with",...y(t),prefix:e})}function va(e,t){return new Vs({check:"string_format",format:"ends_with",...y(t),suffix:e})}function Le(e){return new Js({check:"overwrite",tx:e})}function _a(e){return Le(t=>t.normalize(e))}function wa(){return Le(e=>e.trim())}function ya(){return Le(e=>e.toLowerCase())}function ka(){return Le(e=>e.toUpperCase())}function za(){return Le(e=>Vo(e))}function Sa(e,t,n){return new e({type:"array",element:t,...y(n)})}function $a(e,t,n){return new e({type:"custom",check:"custom",fn:t,...y(n)})}function Oa(e){const t=Ea(n=>(n.addIssue=r=>{if(typeof r=="string")n.issues.push(Ge(r,n.value,t._zod.def));else{const o=r;o.fatal&&(o.continue=!1),o.code??(o.code="custom"),o.input??(o.input=n.value),o.inst??(o.inst=t),o.continue??(o.continue=!t._zod.def.abort),n.issues.push(Ge(o))}},e(n.value,n)));return t}function Ea(e,t){const n=new le({check:"custom",...y(t)});return n._zod.check=e,n}function hr(e){let t=e?.target??"draft-2020-12";return t==="draft-4"&&(t="draft-04"),t==="draft-7"&&(t="draft-07"),{processors:e.processors??{},metadataRegistry:e?.metadata??Je,target:t,unrepresentable:e?.unrepresentable??"throw",override:e?.override??(()=>{}),io:e?.io??"output",counter:0,seen:new Map,cycles:e?.cycles??"ref",reused:e?.reused??"inline",external:e?.external??void 0}}function B(e,t,n={path:[],schemaPath:[]}){var r;const o=e._zod.def,i=t.seen.get(e);if(i)return i.count++,n.schemaPath.includes(e)&&(i.cycle=n.path),i.schema;const s={schema:{},count:1,cycle:void 0,path:n.path};t.seen.set(e,s);const a=e._zod.toJSONSchema?.();if(a)s.schema=a;else{const d={...n,schemaPath:[...n.schemaPath,e],path:n.path};if(e._zod.processJSONSchema)e._zod.processJSONSchema(t,s.schema,d);else{const f=s.schema,h=t.processors[o.type];if(!h)throw new Error(`[toJSONSchema]: Non-representable type encountered: ${o.type}`);h(e,t,f,d)}const p=e._zod.parent;p&&(s.ref||(s.ref=p),B(p,t,d),t.seen.get(p).isParent=!0)}const c=t.metadataRegistry.get(e);return c&&Object.assign(s.schema,c),t.io==="input"&&X(e)&&(delete s.schema.examples,delete s.schema.default),t.io==="input"&&s.schema._prefault&&((r=s.schema).default??(r.default=s.schema._prefault)),delete s.schema._prefault,t.seen.get(e).schema}function mr(e,t){const n=e.seen.get(t);if(!n)throw new Error("Unprocessed schema. This is a bug in Zod.");const r=new Map;for(const s of e.seen.entries()){const a=e.metadataRegistry.get(s[0])?.id;if(a){const c=r.get(a);if(c&&c!==s[0])throw new Error(`Duplicate schema id "${a}" detected during JSON Schema conversion. Two different schemas cannot share the same id when converted together.`);r.set(a,s[0])}}const o=s=>{const a=e.target==="draft-2020-12"?"$defs":"definitions";if(e.external){const p=e.external.registry.get(s[0])?.id,f=e.external.uri??(k=>k);if(p)return{ref:f(p)};const h=s[1].defId??s[1].schema.id??`schema${e.counter++}`;return s[1].defId=h,{defId:h,ref:`${f("__shared")}#/${a}/${h}`}}if(s[1]===n)return{ref:"#"};const u=`#/${a}/`,d=s[1].schema.id??`__schema${e.counter++}`;return{defId:d,ref:u+d}},i=s=>{if(s[1].schema.$ref)return;const a=s[1],{ref:c,defId:u}=o(s);a.def={...a.schema},u&&(a.defId=u);const d=a.schema;for(const p in d)delete d[p];d.$ref=c};if(e.cycles==="throw")for(const s of e.seen.entries()){const a=s[1];if(a.cycle)throw new Error(`Cycle detected: #/${a.cycle?.join("/")}/<root>
|
|
38
|
+
|
|
39
|
+
Set the \`cycles\` parameter to \`"ref"\` to resolve cyclical schemas with defs.`)}for(const s of e.seen.entries()){const a=s[1];if(t===s[0]){i(s);continue}if(e.external){const u=e.external.registry.get(s[0])?.id;if(t!==s[0]&&u){i(s);continue}}if(e.metadataRegistry.get(s[0])?.id){i(s);continue}if(a.cycle){i(s);continue}if(a.count>1&&e.reused==="ref"){i(s);continue}}}function gr(e,t){const n=e.seen.get(t);if(!n)throw new Error("Unprocessed schema. This is a bug in Zod.");const r=s=>{const a=e.seen.get(s);if(a.ref===null)return;const c=a.def??a.schema,u={...c},d=a.ref;if(a.ref=null,d){r(d);const f=e.seen.get(d),h=f.schema;if(h.$ref&&(e.target==="draft-07"||e.target==="draft-04"||e.target==="openapi-3.0")?(c.allOf=c.allOf??[],c.allOf.push(h)):Object.assign(c,h),Object.assign(c,u),s._zod.parent===d)for(const b in c)b==="$ref"||b==="allOf"||b in u||delete c[b];if(h.$ref&&f.def)for(const b in c)b==="$ref"||b==="allOf"||b in f.def&&JSON.stringify(c[b])===JSON.stringify(f.def[b])&&delete c[b]}const p=s._zod.parent;if(p&&p!==d){r(p);const f=e.seen.get(p);if(f?.schema.$ref&&(c.$ref=f.schema.$ref,f.def))for(const h in c)h==="$ref"||h==="allOf"||h in f.def&&JSON.stringify(c[h])===JSON.stringify(f.def[h])&&delete c[h]}e.override({zodSchema:s,jsonSchema:c,path:a.path??[]})};for(const s of[...e.seen.entries()].reverse())r(s[0]);const o={};if(e.target==="draft-2020-12"?o.$schema="https://json-schema.org/draft/2020-12/schema":e.target==="draft-07"?o.$schema="http://json-schema.org/draft-07/schema#":e.target==="draft-04"?o.$schema="http://json-schema.org/draft-04/schema#":e.target,e.external?.uri){const s=e.external.registry.get(t)?.id;if(!s)throw new Error("Schema is missing an `id` property");o.$id=e.external.uri(s)}Object.assign(o,n.def??n.schema);const i=e.external?.defs??{};for(const s of e.seen.entries()){const a=s[1];a.def&&a.defId&&(i[a.defId]=a.def)}e.external||Object.keys(i).length>0&&(e.target==="draft-2020-12"?o.$defs=i:o.definitions=i);try{const s=JSON.parse(JSON.stringify(o));return Object.defineProperty(s,"~standard",{value:{...t["~standard"],jsonSchema:{input:at(t,"input",e.processors),output:at(t,"output",e.processors)}},enumerable:!1,writable:!1}),s}catch{throw new Error("Error converting schema to JSON.")}}function X(e,t){const n=t??{seen:new Set};if(n.seen.has(e))return!1;n.seen.add(e);const r=e._zod.def;if(r.type==="transform")return!0;if(r.type==="array")return X(r.element,n);if(r.type==="set")return X(r.valueType,n);if(r.type==="lazy")return X(r.getter(),n);if(r.type==="promise"||r.type==="optional"||r.type==="nonoptional"||r.type==="nullable"||r.type==="readonly"||r.type==="default"||r.type==="prefault")return X(r.innerType,n);if(r.type==="intersection")return X(r.left,n)||X(r.right,n);if(r.type==="record"||r.type==="map")return X(r.keyType,n)||X(r.valueType,n);if(r.type==="pipe")return X(r.in,n)||X(r.out,n);if(r.type==="object"){for(const o in r.shape)if(X(r.shape[o],n))return!0;return!1}if(r.type==="union"){for(const o of r.options)if(X(o,n))return!0;return!1}if(r.type==="tuple"){for(const o of r.items)if(X(o,n))return!0;return!!(r.rest&&X(r.rest,n))}return!1}const Za=(e,t={})=>n=>{const r=hr({...n,processors:t});return B(e,r),mr(r,e),gr(r,e)},at=(e,t,n={})=>r=>{const{libraryOptions:o,target:i}=r??{},s=hr({...o??{},target:i,io:t,processors:n});return B(e,s),mr(s,e),gr(s,e)},xa={guid:"uuid",url:"uri",datetime:"date-time",json_string:"json-string",regex:""},Ra=(e,t,n,r)=>{const o=n;o.type="string";const{minimum:i,maximum:s,format:a,patterns:c,contentEncoding:u}=e._zod.bag;if(typeof i=="number"&&(o.minLength=i),typeof s=="number"&&(o.maxLength=s),a&&(o.format=xa[a]??a,o.format===""&&delete o.format,a==="time"&&delete o.format),u&&(o.contentEncoding=u),c&&c.size>0){const d=[...c];d.length===1?o.pattern=d[0].source:d.length>1&&(o.allOf=[...d.map(p=>({...t.target==="draft-07"||t.target==="draft-04"||t.target==="openapi-3.0"?{type:"string"}:{},pattern:p.source}))])}},Ta=(e,t,n,r)=>{n.not={}},Pa=(e,t,n,r)=>{},Ia=(e,t,n,r)=>{const o=e._zod.def,i=Xn(o.entries);i.every(s=>typeof s=="number")&&(n.type="number"),i.every(s=>typeof s=="string")&&(n.type="string"),n.enum=i},Aa=(e,t,n,r)=>{const o=e._zod.def,i=[];for(const s of o.values)if(s===void 0){if(t.unrepresentable==="throw")throw new Error("Literal `undefined` cannot be represented in JSON Schema")}else if(typeof s=="bigint"){if(t.unrepresentable==="throw")throw new Error("BigInt literals cannot be represented in JSON Schema");i.push(Number(s))}else i.push(s);if(i.length!==0)if(i.length===1){const s=i[0];n.type=s===null?"null":typeof s,t.target==="draft-04"||t.target==="openapi-3.0"?n.enum=[s]:n.const=s}else i.every(s=>typeof s=="number")&&(n.type="number"),i.every(s=>typeof s=="string")&&(n.type="string"),i.every(s=>typeof s=="boolean")&&(n.type="boolean"),i.every(s=>s===null)&&(n.type="null"),n.enum=i},Ca=(e,t,n,r)=>{if(t.unrepresentable==="throw")throw new Error("Custom types cannot be represented in JSON Schema")},ja=(e,t,n,r)=>{if(t.unrepresentable==="throw")throw new Error("Transforms cannot be represented in JSON Schema")},Da=(e,t,n,r)=>{const o=n,i=e._zod.def,{minimum:s,maximum:a}=e._zod.bag;typeof s=="number"&&(o.minItems=s),typeof a=="number"&&(o.maxItems=a),o.type="array",o.items=B(i.element,t,{...r,path:[...r.path,"items"]})},Na=(e,t,n,r)=>{const o=n,i=e._zod.def;o.type="object",o.properties={};const s=i.shape;for(const u in s)o.properties[u]=B(s[u],t,{...r,path:[...r.path,"properties",u]});const a=new Set(Object.keys(s)),c=new Set([...a].filter(u=>{const d=i.shape[u]._zod;return t.io==="input"?d.optin===void 0:d.optout===void 0}));c.size>0&&(o.required=Array.from(c)),i.catchall?._zod.def.type==="never"?o.additionalProperties=!1:i.catchall?i.catchall&&(o.additionalProperties=B(i.catchall,t,{...r,path:[...r.path,"additionalProperties"]})):t.io==="output"&&(o.additionalProperties=!1)},La=(e,t,n,r)=>{const o=e._zod.def,i=o.inclusive===!1,s=o.options.map((a,c)=>B(a,t,{...r,path:[...r.path,i?"oneOf":"anyOf",c]}));i?n.oneOf=s:n.anyOf=s},Ua=(e,t,n,r)=>{const o=e._zod.def,i=B(o.left,t,{...r,path:[...r.path,"allOf",0]}),s=B(o.right,t,{...r,path:[...r.path,"allOf",1]}),a=u=>"allOf"in u&&Object.keys(u).length===1,c=[...a(i)?i.allOf:[i],...a(s)?s.allOf:[s]];n.allOf=c},Fa=(e,t,n,r)=>{const o=e._zod.def,i=B(o.innerType,t,r),s=t.seen.get(e);t.target==="openapi-3.0"?(s.ref=o.innerType,n.nullable=!0):n.anyOf=[i,{type:"null"}]},Ma=(e,t,n,r)=>{const o=e._zod.def;B(o.innerType,t,r);const i=t.seen.get(e);i.ref=o.innerType},Va=(e,t,n,r)=>{const o=e._zod.def;B(o.innerType,t,r);const i=t.seen.get(e);i.ref=o.innerType,n.default=JSON.parse(JSON.stringify(o.defaultValue))},Ja=(e,t,n,r)=>{const o=e._zod.def;B(o.innerType,t,r);const i=t.seen.get(e);i.ref=o.innerType,t.io==="input"&&(n._prefault=JSON.parse(JSON.stringify(o.defaultValue)))},Wa=(e,t,n,r)=>{const o=e._zod.def;B(o.innerType,t,r);const i=t.seen.get(e);i.ref=o.innerType;let s;try{s=o.catchValue(void 0)}catch{throw new Error("Dynamic catch values are not supported in JSON Schema")}n.default=s},Ga=(e,t,n,r)=>{const o=e._zod.def,i=t.io==="input"?o.in._zod.def.type==="transform"?o.out:o.in:o.out;B(i,t,r);const s=t.seen.get(e);s.ref=i},Ba=(e,t,n,r)=>{const o=e._zod.def;B(o.innerType,t,r);const i=t.seen.get(e);i.ref=o.innerType,n.readOnly=!0},br=(e,t,n,r)=>{const o=e._zod.def;B(o.innerType,t,r);const i=t.seen.get(e);i.ref=o.innerType},qa=l("ZodISODateTime",(e,t)=>{oi.init(e,t),A.init(e,t)});function Ka(e){return aa(qa,e)}const Ha=l("ZodISODate",(e,t)=>{si.init(e,t),A.init(e,t)});function Ya(e){return ca(Ha,e)}const Xa=l("ZodISOTime",(e,t)=>{ii.init(e,t),A.init(e,t)});function Qa(e){return ua(Xa,e)}const ec=l("ZodISODuration",(e,t)=>{ai.init(e,t),A.init(e,t)});function tc(e){return la(ec,e)}const vr=(e,t)=>{rr.init(e,t),e.name="ZodError",Object.defineProperties(e,{format:{value:n=>ts(e,n)},flatten:{value:n=>es(e,n)},addIssue:{value:n=>{e.issues.push(n),e.message=JSON.stringify(e.issues,Pt,2)}},addIssues:{value:n=>{e.issues.push(...n),e.message=JSON.stringify(e.issues,Pt,2)}},isEmpty:{get(){return e.issues.length===0}}})},pu=l("ZodError",vr),re=l("ZodError",vr,{Parent:Error}),nc=Vt(re),rc=Jt(re),oc=ct(re),sc=ut(re),ic=os(re),ac=ss(re),cc=is(re),uc=as(re),lc=cs(re),dc=us(re),fc=ls(re),pc=ds(re),U=l("ZodType",(e,t)=>(L.init(e,t),Object.assign(e["~standard"],{jsonSchema:{input:at(e,"input"),output:at(e,"output")}}),e.toJSONSchema=Za(e,{}),e.def=t,e.type=t.type,Object.defineProperty(e,"_def",{value:t}),e.check=(...n)=>e.clone(ye(t,{checks:[...t.checks??[],...n.map(r=>typeof r=="function"?{_zod:{check:r,def:{check:"custom"},onattach:[]}}:r)]}),{parent:!0}),e.with=e.check,e.clone=(n,r)=>ke(e,n,r),e.brand=()=>e,e.register=((n,r)=>(n.add(e,r),e)),e.parse=(n,r)=>nc(e,n,r,{callee:e.parse}),e.safeParse=(n,r)=>oc(e,n,r),e.parseAsync=async(n,r)=>rc(e,n,r,{callee:e.parseAsync}),e.safeParseAsync=async(n,r)=>sc(e,n,r),e.spa=e.safeParseAsync,e.encode=(n,r)=>ic(e,n,r),e.decode=(n,r)=>ac(e,n,r),e.encodeAsync=async(n,r)=>cc(e,n,r),e.decodeAsync=async(n,r)=>uc(e,n,r),e.safeEncode=(n,r)=>lc(e,n,r),e.safeDecode=(n,r)=>dc(e,n,r),e.safeEncodeAsync=async(n,r)=>fc(e,n,r),e.safeDecodeAsync=async(n,r)=>pc(e,n,r),e.refine=(n,r)=>e.check(iu(n,r)),e.superRefine=n=>e.check(au(n)),e.overwrite=n=>e.check(Le(n)),e.optional=()=>On(e),e.exactOptional=()=>Bc(e),e.nullable=()=>En(e),e.nullish=()=>On(En(e)),e.nonoptional=n=>Qc(e,n),e.array=()=>jc(e),e.or=n=>Lc([e,n]),e.and=n=>Fc(e,n),e.transform=n=>Zn(e,Wc(n)),e.default=n=>Hc(e,n),e.prefault=n=>Xc(e,n),e.catch=n=>tu(e,n),e.pipe=n=>Zn(e,n),e.readonly=()=>ou(e),e.describe=n=>{const r=e.clone();return Je.add(r,{description:n}),r},Object.defineProperty(e,"description",{get(){return Je.get(e)?.description},configurable:!0}),e.meta=(...n)=>{if(n.length===0)return Je.get(e);const r=e.clone();return Je.add(r,n[0]),r},e.isOptional=()=>e.safeParse(void 0).success,e.isNullable=()=>e.safeParse(null).success,e.apply=n=>n(e),e)),_r=l("_ZodString",(e,t)=>{Wt.init(e,t),U.init(e,t),e._zod.processJSONSchema=(r,o,i)=>Ra(e,r,o);const n=e._zod.bag;e.format=n.format??null,e.minLength=n.minimum??null,e.maxLength=n.maximum??null,e.regex=(...r)=>e.check(pa(...r)),e.includes=(...r)=>e.check(ga(...r)),e.startsWith=(...r)=>e.check(ba(...r)),e.endsWith=(...r)=>e.check(va(...r)),e.min=(...r)=>e.check(it(...r)),e.max=(...r)=>e.check(fr(...r)),e.length=(...r)=>e.check(pr(...r)),e.nonempty=(...r)=>e.check(it(1,...r)),e.lowercase=r=>e.check(ha(r)),e.uppercase=r=>e.check(ma(r)),e.trim=()=>e.check(wa()),e.normalize=(...r)=>e.check(_a(...r)),e.toLowerCase=()=>e.check(ya()),e.toUpperCase=()=>e.check(ka()),e.slugify=()=>e.check(za())}),hc=l("ZodString",(e,t)=>{Wt.init(e,t),_r.init(e,t),e.email=n=>e.check(Ui(mc,n)),e.url=n=>e.check(Wi(gc,n)),e.jwt=n=>e.check(ia(Tc,n)),e.emoji=n=>e.check(Gi(bc,n)),e.guid=n=>e.check(zn(Sn,n)),e.uuid=n=>e.check(Fi(nt,n)),e.uuidv4=n=>e.check(Mi(nt,n)),e.uuidv6=n=>e.check(Vi(nt,n)),e.uuidv7=n=>e.check(Ji(nt,n)),e.nanoid=n=>e.check(Bi(vc,n)),e.guid=n=>e.check(zn(Sn,n)),e.cuid=n=>e.check(qi(_c,n)),e.cuid2=n=>e.check(Ki(wc,n)),e.ulid=n=>e.check(Hi(yc,n)),e.base64=n=>e.check(ra(Zc,n)),e.base64url=n=>e.check(oa(xc,n)),e.xid=n=>e.check(Yi(kc,n)),e.ksuid=n=>e.check(Xi(zc,n)),e.ipv4=n=>e.check(Qi(Sc,n)),e.ipv6=n=>e.check(ea($c,n)),e.cidrv4=n=>e.check(ta(Oc,n)),e.cidrv6=n=>e.check(na(Ec,n)),e.e164=n=>e.check(sa(Rc,n)),e.datetime=n=>e.check(Ka(n)),e.date=n=>e.check(Ya(n)),e.time=n=>e.check(Qa(n)),e.duration=n=>e.check(tc(n))});function hu(e){return Li(hc,e)}const A=l("ZodStringFormat",(e,t)=>{P.init(e,t),_r.init(e,t)}),mc=l("ZodEmail",(e,t)=>{Ks.init(e,t),A.init(e,t)}),Sn=l("ZodGUID",(e,t)=>{Bs.init(e,t),A.init(e,t)}),nt=l("ZodUUID",(e,t)=>{qs.init(e,t),A.init(e,t)}),gc=l("ZodURL",(e,t)=>{Hs.init(e,t),A.init(e,t)}),bc=l("ZodEmoji",(e,t)=>{Ys.init(e,t),A.init(e,t)}),vc=l("ZodNanoID",(e,t)=>{Xs.init(e,t),A.init(e,t)}),_c=l("ZodCUID",(e,t)=>{Qs.init(e,t),A.init(e,t)}),wc=l("ZodCUID2",(e,t)=>{ei.init(e,t),A.init(e,t)}),yc=l("ZodULID",(e,t)=>{ti.init(e,t),A.init(e,t)}),kc=l("ZodXID",(e,t)=>{ni.init(e,t),A.init(e,t)}),zc=l("ZodKSUID",(e,t)=>{ri.init(e,t),A.init(e,t)}),Sc=l("ZodIPv4",(e,t)=>{ci.init(e,t),A.init(e,t)}),$c=l("ZodIPv6",(e,t)=>{ui.init(e,t),A.init(e,t)}),Oc=l("ZodCIDRv4",(e,t)=>{li.init(e,t),A.init(e,t)}),Ec=l("ZodCIDRv6",(e,t)=>{di.init(e,t),A.init(e,t)}),Zc=l("ZodBase64",(e,t)=>{fi.init(e,t),A.init(e,t)}),xc=l("ZodBase64URL",(e,t)=>{hi.init(e,t),A.init(e,t)}),Rc=l("ZodE164",(e,t)=>{mi.init(e,t),A.init(e,t)}),Tc=l("ZodJWT",(e,t)=>{bi.init(e,t),A.init(e,t)}),Pc=l("ZodUnknown",(e,t)=>{vi.init(e,t),U.init(e,t),e._zod.processJSONSchema=(n,r,o)=>Pa()});function $n(){return da(Pc)}const Ic=l("ZodNever",(e,t)=>{_i.init(e,t),U.init(e,t),e._zod.processJSONSchema=(n,r,o)=>Ta(e,n,r)});function Ac(e){return fa(Ic,e)}const Cc=l("ZodArray",(e,t)=>{wi.init(e,t),U.init(e,t),e._zod.processJSONSchema=(n,r,o)=>Da(e,n,r,o),e.element=t.element,e.min=(n,r)=>e.check(it(n,r)),e.nonempty=n=>e.check(it(1,n)),e.max=(n,r)=>e.check(fr(n,r)),e.length=(n,r)=>e.check(pr(n,r)),e.unwrap=()=>e.element});function jc(e,t){return Sa(Cc,e,t)}const Dc=l("ZodObject",(e,t)=>{ki.init(e,t),U.init(e,t),e._zod.processJSONSchema=(n,r,o)=>Na(e,n,r,o),Z(e,"shape",()=>t.shape),e.keyof=()=>Mc(Object.keys(e._zod.def.shape)),e.catchall=n=>e.clone({...e._zod.def,catchall:n}),e.passthrough=()=>e.clone({...e._zod.def,catchall:$n()}),e.loose=()=>e.clone({...e._zod.def,catchall:$n()}),e.strict=()=>e.clone({...e._zod.def,catchall:Ac()}),e.strip=()=>e.clone({...e._zod.def,catchall:void 0}),e.extend=n=>Ko(e,n),e.safeExtend=n=>Ho(e,n),e.merge=n=>Yo(e,n),e.pick=n=>Bo(e,n),e.omit=n=>qo(e,n),e.partial=(...n)=>Xo(wr,e,n[0]),e.required=(...n)=>Qo(yr,e,n[0])});function mu(e,t){const n={type:"object",shape:e??{},...y(t)};return new Dc(n)}const Nc=l("ZodUnion",(e,t)=>{zi.init(e,t),U.init(e,t),e._zod.processJSONSchema=(n,r,o)=>La(e,n,r,o),e.options=t.options});function Lc(e,t){return new Nc({type:"union",options:e,...y(t)})}const Uc=l("ZodIntersection",(e,t)=>{Si.init(e,t),U.init(e,t),e._zod.processJSONSchema=(n,r,o)=>Ua(e,n,r,o)});function Fc(e,t){return new Uc({type:"intersection",left:e,right:t})}const At=l("ZodEnum",(e,t)=>{$i.init(e,t),U.init(e,t),e._zod.processJSONSchema=(r,o,i)=>Ia(e,r,o),e.enum=t.entries,e.options=Object.values(t.entries);const n=new Set(Object.keys(t.entries));e.extract=(r,o)=>{const i={};for(const s of r)if(n.has(s))i[s]=t.entries[s];else throw new Error(`Key ${s} not found in enum`);return new At({...t,checks:[],...y(o),entries:i})},e.exclude=(r,o)=>{const i={...t.entries};for(const s of r)if(n.has(s))delete i[s];else throw new Error(`Key ${s} not found in enum`);return new At({...t,checks:[],...y(o),entries:i})}});function Mc(e,t){const n=Array.isArray(e)?Object.fromEntries(e.map(r=>[r,r])):e;return new At({type:"enum",entries:n,...y(t)})}const Vc=l("ZodLiteral",(e,t)=>{Oi.init(e,t),U.init(e,t),e._zod.processJSONSchema=(n,r,o)=>Aa(e,n,r),e.values=new Set(t.values),Object.defineProperty(e,"value",{get(){if(t.values.length>1)throw new Error("This schema contains multiple valid literal values. Use `.values` instead.");return t.values[0]}})});function gu(e,t){return new Vc({type:"literal",values:Array.isArray(e)?e:[e],...y(t)})}const Jc=l("ZodTransform",(e,t)=>{Ei.init(e,t),U.init(e,t),e._zod.processJSONSchema=(n,r,o)=>ja(e,n),e._zod.parse=(n,r)=>{if(r.direction==="backward")throw new Hn(e.constructor.name);n.addIssue=i=>{if(typeof i=="string")n.issues.push(Ge(i,n.value,t));else{const s=i;s.fatal&&(s.continue=!1),s.code??(s.code="custom"),s.input??(s.input=n.value),s.inst??(s.inst=e),n.issues.push(Ge(s))}};const o=t.transform(n.value,n);return o instanceof Promise?o.then(i=>(n.value=i,n)):(n.value=o,n)}});function Wc(e){return new Jc({type:"transform",transform:e})}const wr=l("ZodOptional",(e,t)=>{dr.init(e,t),U.init(e,t),e._zod.processJSONSchema=(n,r,o)=>br(e,n,r,o),e.unwrap=()=>e._zod.def.innerType});function On(e){return new wr({type:"optional",innerType:e})}const Gc=l("ZodExactOptional",(e,t)=>{Zi.init(e,t),U.init(e,t),e._zod.processJSONSchema=(n,r,o)=>br(e,n,r,o),e.unwrap=()=>e._zod.def.innerType});function Bc(e){return new Gc({type:"optional",innerType:e})}const qc=l("ZodNullable",(e,t)=>{xi.init(e,t),U.init(e,t),e._zod.processJSONSchema=(n,r,o)=>Fa(e,n,r,o),e.unwrap=()=>e._zod.def.innerType});function En(e){return new qc({type:"nullable",innerType:e})}const Kc=l("ZodDefault",(e,t)=>{Ri.init(e,t),U.init(e,t),e._zod.processJSONSchema=(n,r,o)=>Va(e,n,r,o),e.unwrap=()=>e._zod.def.innerType,e.removeDefault=e.unwrap});function Hc(e,t){return new Kc({type:"default",innerType:e,get defaultValue(){return typeof t=="function"?t():er(t)}})}const Yc=l("ZodPrefault",(e,t)=>{Ti.init(e,t),U.init(e,t),e._zod.processJSONSchema=(n,r,o)=>Ja(e,n,r,o),e.unwrap=()=>e._zod.def.innerType});function Xc(e,t){return new Yc({type:"prefault",innerType:e,get defaultValue(){return typeof t=="function"?t():er(t)}})}const yr=l("ZodNonOptional",(e,t)=>{Pi.init(e,t),U.init(e,t),e._zod.processJSONSchema=(n,r,o)=>Ma(e,n,r,o),e.unwrap=()=>e._zod.def.innerType});function Qc(e,t){return new yr({type:"nonoptional",innerType:e,...y(t)})}const eu=l("ZodCatch",(e,t)=>{Ii.init(e,t),U.init(e,t),e._zod.processJSONSchema=(n,r,o)=>Wa(e,n,r,o),e.unwrap=()=>e._zod.def.innerType,e.removeCatch=e.unwrap});function tu(e,t){return new eu({type:"catch",innerType:e,catchValue:typeof t=="function"?t:()=>t})}const nu=l("ZodPipe",(e,t)=>{Ai.init(e,t),U.init(e,t),e._zod.processJSONSchema=(n,r,o)=>Ga(e,n,r,o),e.in=t.in,e.out=t.out});function Zn(e,t){return new nu({type:"pipe",in:e,out:t})}const ru=l("ZodReadonly",(e,t)=>{Ci.init(e,t),U.init(e,t),e._zod.processJSONSchema=(n,r,o)=>Ba(e,n,r,o),e.unwrap=()=>e._zod.def.innerType});function ou(e){return new ru({type:"readonly",innerType:e})}const su=l("ZodCustom",(e,t)=>{ji.init(e,t),U.init(e,t),e._zod.processJSONSchema=(n,r,o)=>Ca(e,n)});function iu(e,t={}){return $a(su,e,t)}function au(e){return Oa(e)}export{pu as Z,Lc as a,du as c,gu as l,Fr as m,mu as o,$r as r,hu as s,fu as t,lu as u};
|
package/dist/ui/index.html
CHANGED
|
@@ -18,12 +18,12 @@
|
|
|
18
18
|
|
|
19
19
|
<title>Morpheus Agent UI</title>
|
|
20
20
|
<!-- vite-plugin-pwa injeta <link rel="manifest"> automaticamente no build -->
|
|
21
|
-
<script type="module" crossorigin src="./assets/index-
|
|
21
|
+
<script type="module" crossorigin src="./assets/index-Db1XEN8v.js"></script>
|
|
22
22
|
<link rel="modulepreload" crossorigin href="./assets/vendor-react-DikRIOlj.js">
|
|
23
23
|
<link rel="modulepreload" crossorigin href="./assets/vendor-motion-C3CZ8ZlO.js">
|
|
24
|
-
<link rel="modulepreload" crossorigin href="./assets/vendor-utils-
|
|
25
|
-
<link rel="modulepreload" crossorigin href="./assets/vendor-icons-
|
|
26
|
-
<link rel="stylesheet" crossorigin href="./assets/index-
|
|
24
|
+
<link rel="modulepreload" crossorigin href="./assets/vendor-utils-BIYveU_1.js">
|
|
25
|
+
<link rel="modulepreload" crossorigin href="./assets/vendor-icons-DE7PWdkN.js">
|
|
26
|
+
<link rel="stylesheet" crossorigin href="./assets/index-Bko2TlZY.css">
|
|
27
27
|
<link rel="manifest" href="./manifest.webmanifest"><script id="vite-plugin-pwa:register-sw" src="./registerSW.js"></script></head>
|
|
28
28
|
<body>
|
|
29
29
|
<div id="root"></div>
|
package/dist/ui/sw.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
if(!self.define){let s,e={};const
|
|
1
|
+
if(!self.define){let s,e={};const n=(n,i)=>(n=new URL(n+".js",i).href,e[n]||new Promise(e=>{if("document"in self){const s=document.createElement("script");s.src=n,s.onload=e,document.head.appendChild(s)}else s=n,importScripts(n),e()}).then(()=>{let s=e[n];if(!s)throw new Error(`Module ${n} didn’t register its module`);return s}));self.define=(i,l)=>{const r=s||("document"in self?document.currentScript.src:"")||location.href;if(e[r])return;let u={};const a=s=>n(s,r),o={module:{uri:r},exports:u,require:a};e[r]=Promise.all(i.map(s=>o[s]||a(s))).then(s=>(l(...s),u))}}define(["./workbox-26f462e7"],function(s){"use strict";self.skipWaiting(),s.clientsClaim(),s.precacheAndRoute([{url:"vite.svg",revision:"5e386a6b1608494961c0a0de283e0df8"},{url:"registerSW.js",revision:"402b66900e731ca748771b6fc5e7a068"},{url:"pwa-maskable-512x512.png",revision:"e9dc04fc1b43cd6093e286bf765726d8"},{url:"pwa-maskable-192x192.png",revision:"8eb12fd764e6cb6f56247b2e1b21a31f"},{url:"pwa-512x512.png",revision:"f9619ef45b67856ce91010c1eb1d3c0c"},{url:"pwa-192x192.png",revision:"6174f6c5724689f6c15526be28983ca8"},{url:"index.html",revision:"21289d6cefb64fee816905ca7743e693"},{url:"assets/vendor-utils-BIYveU_1.js",revision:null},{url:"assets/vendor-react-DikRIOlj.js",revision:null},{url:"assets/vendor-motion-C3CZ8ZlO.js",revision:null},{url:"assets/vendor-markdown-BN_Np5Ta.js",revision:null},{url:"assets/vendor-icons-DE7PWdkN.js",revision:null},{url:"assets/useCurrency-CEc5edm2.js",revision:null},{url:"assets/stats-BzqxCDuj.js",revision:null},{url:"assets/skills-dc6Xqqhb.js",revision:null},{url:"assets/mcp-YiYC-9IH.js",revision:null},{url:"assets/index-Db1XEN8v.js",revision:null},{url:"assets/index-Bko2TlZY.css",revision:null},{url:"assets/config-7LGRnJ26.js",revision:null},{url:"assets/chronos-mZ0RIvh4.js",revision:null},{url:"assets/audit-M-5UGwoK.js",revision:null},{url:"assets/agents-CN_AKX_I.js",revision:null},{url:"assets/WebhookManager-BbfMCiy-.js",revision:null},{url:"assets/UsageStats-VajzjndO.js",revision:null},{url:"assets/TrinityDatabases-DCjdwnLH.js",revision:null},{url:"assets/Tasks-DzUyw5z3.js",revision:null},{url:"assets/Switch-C7TxLq0E.js",revision:null},{url:"assets/Smiths-B6-CnRMv.js",revision:null},{url:"assets/Skills-Dw6G5c8W.js",revision:null},{url:"assets/Settings-CblauAVd.js",revision:null},{url:"assets/SessionAudit-BWtJRkj1.js",revision:null},{url:"assets/SelectInput-BPDcd3y7.js",revision:null},{url:"assets/SatiMemories-DO3JDQBi.js",revision:null},{url:"assets/Pagination-D4ShqUKO.js",revision:null},{url:"assets/Notifications-nI--fmYx.js",revision:null},{url:"assets/ModelPricing-CuYIUwXt.js",revision:null},{url:"assets/MCPManager-lLoGEyBy.js",revision:null},{url:"assets/Logs-BWufAtHa.js",revision:null},{url:"assets/Documents-B8g_yv4f.js",revision:null},{url:"assets/DeleteConfirmationModal-D8QsQzwP.js",revision:null},{url:"assets/Dashboard-OyZXnj44.js",revision:null},{url:"assets/ConfirmationModal-B3gHIVKY.js",revision:null},{url:"assets/Chronos-MP_NCj2A.js",revision:null},{url:"assets/Chat-aFz9FjrD.js",revision:null},{url:"assets/AuditDashboard-z3OBbJ8I.js",revision:null},{url:"pwa-192x192.png",revision:"6174f6c5724689f6c15526be28983ca8"},{url:"pwa-512x512.png",revision:"f9619ef45b67856ce91010c1eb1d3c0c"},{url:"pwa-maskable-192x192.png",revision:"8eb12fd764e6cb6f56247b2e1b21a31f"},{url:"pwa-maskable-512x512.png",revision:"e9dc04fc1b43cd6093e286bf765726d8"},{url:"manifest.webmanifest",revision:"da8b9a11743009a7e50876a50de29362"}],{}),s.cleanupOutdatedCaches(),s.registerRoute(new s.NavigationRoute(s.createHandlerBoundToURL("/index.html"),{denylist:[/^\/api\//]})),s.registerRoute(/^\/api\//,new s.NetworkOnly,"GET"),s.registerRoute(/\.(?:js|css|woff2)$/,new s.CacheFirst({cacheName:"static-assets",plugins:[new s.ExpirationPlugin({maxAgeSeconds:31536e3})]}),"GET"),s.registerRoute(/\.(?:png|svg|ico)$/,new s.StaleWhileRevalidate({cacheName:"images",plugins:[new s.ExpirationPlugin({maxEntries:50,maxAgeSeconds:2592e3})]}),"GET")});
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "morpheus-cli",
|
|
3
|
-
"version": "0.9.
|
|
3
|
+
"version": "0.9.22",
|
|
4
4
|
"description": "Morpheus is a local AI agent for developers, running as a CLI daemon that connects to LLMs, local tools, and MCPs, enabling interaction via Terminal, Telegram, and Discord. Inspired by the character Morpheus from *The Matrix*, the project acts as an intelligent orchestrator, bridging the gap between the developer and complex systems.",
|
|
5
5
|
"bin": {
|
|
6
6
|
"morpheus": "./bin/morpheus.js"
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as e,m as d}from"./vendor-motion-C3CZ8ZlO.js";import{u as P,t as z,h as w,f as U}from"./index-BcX5O7kY.js";import{u as n}from"./vendor-utils-D4NnWbOU.js";import{s as A}from"./stats-BiPI2kaw.js";import{m as E}from"./mcp-BlkruPaA.js";import{s as R}from"./skills-CtCb-52u.js";import{L as V,A as F,g as j,l as O,m as J,n as W,i as B,W as G,P as H,H as q,f as X,o as S,p as K,q as Q,r as Y}from"./vendor-icons-NHF9HNeN.js";import{L as C}from"./vendor-react-DikRIOlj.js";const Z={hidden:{opacity:0,y:20},show:{opacity:1,y:0}},k=({title:r,value:a,icon:i,subValue:l})=>e.jsxs(d.div,{variants:Z,className:"border border-azure-border dark:border-matrix-primary bg-azure-surface/50 dark:bg-zinc-950/50 p-6 rounded relative overflow-hidden group hover:border-azure-primary dark:hover:border-matrix-highlight transition-colors",children:[e.jsxs("div",{className:"flex justify-between items-start mb-4",children:[e.jsx("h3",{className:"text-azure-text-secondary dark:text-matrix-secondary text-sm font-bold uppercase",children:r}),e.jsx(i,{className:"w-6 h-6 text-azure-primary dark:text-matrix-primary group-hover:text-azure-primary dark:group-hover:text-matrix-highlight transition-colors"})]}),e.jsx("div",{className:"text-3xl font-bold text-azure-primary dark:text-matrix-highlight mb-1 font-mono tracking-tighter truncate",children:a}),l&&e.jsx("div",{className:"text-xs text-azure-text-secondary dark:text-matrix-secondary opacity-70 font-mono",children:l})]}),ee={hidden:{opacity:0},show:{opacity:1,transition:{staggerChildren:.07}}},c={hidden:{opacity:0,y:12},show:{opacity:1,y:0}};function m({icon:r,title:a,to:i,children:l,status:o="neutral"}){const h=o==="ok"?"border-emerald-300/60 dark:border-emerald-700/40":o==="warn"?"border-amber-300/60 dark:border-amber-700/40":o==="error"?"border-red-300/60 dark:border-red-700/40":"border-azure-border dark:border-matrix-primary/50";return e.jsxs(C,{to:i,className:`group flex flex-col gap-3 rounded-lg border bg-white dark:bg-black p-4 hover:border-azure-primary dark:hover:border-matrix-highlight transition-colors ${h}`,children:[e.jsxs("div",{className:"flex items-center justify-between",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(r,{className:"w-4 h-4 text-azure-primary dark:text-matrix-highlight"}),e.jsx("span",{className:"text-sm font-semibold text-azure-text dark:text-matrix-highlight",children:a})]}),e.jsx(S,{className:"w-3.5 h-3.5 text-azure-text-secondary dark:text-matrix-tertiary group-hover:text-azure-primary dark:group-hover:text-matrix-highlight transition-colors"})]}),e.jsx("div",{className:"space-y-1.5",children:l})]})}function s({label:r,value:a,highlight:i}){return e.jsxs("div",{className:"flex items-center justify-between text-xs",children:[e.jsx("span",{className:"text-azure-text-secondary dark:text-matrix-tertiary",children:r}),e.jsx("span",{className:i?"font-semibold text-azure-text dark:text-matrix-highlight":"text-azure-text-secondary dark:text-matrix-secondary",children:a})]})}function te({status:r}){return r==="completed"?e.jsx(K,{className:"w-3.5 h-3.5 text-emerald-500 shrink-0"}):r==="failed"?e.jsx(Q,{className:"w-3.5 h-3.5 text-red-500 shrink-0"}):r==="running"?e.jsx(Y,{className:"w-3.5 h-3.5 text-blue-500 animate-spin shrink-0"}):e.jsx(j,{className:"w-3.5 h-3.5 text-yellow-500 shrink-0"})}function xe(){const{data:r}=P(),{data:a}=n("/tasks/stats",()=>z.stats(),{refreshInterval:5e3}),{data:i}=n("/api/stats/usage",()=>A.fetchUsageStats(),{refreshInterval:3e4}),{data:l}=n("/api/mcp/stats",()=>E.fetchStats(),{refreshInterval:3e4}),{data:o}=n("/smiths",()=>w.get("/smiths"),{refreshInterval:1e4}),{data:h=[]}=n("/chronos",()=>w.get("/chronos"),{refreshInterval:3e4}),{data:x}=n("/api/skills",()=>R.fetchSkills(),{refreshInterval:6e4}),{data:p=[]}=n(["/tasks",{limit:5}],()=>z.list({limit:5}),{refreshInterval:5e3}),v=(i?.totalInputTokens??0)+(i?.totalOutputTokens??0),f=i?.totalEstimatedCostUsd!=null,T=i?.totalEstimatedCostUsd??0,g=t=>t>=1e6?`${(t/1e6).toFixed(1)}M`:t>=1e3?`${(t/1e3).toFixed(1)}k`:String(t),u=h.filter(t=>t.enabled),y=u.filter(t=>t.next_run_at).sort((t,b)=>t.next_run_at-b.next_run_at)[0],N=y?.next_run_at?(()=>{const t=y.next_run_at-Date.now();return t<0?"due now":t<6e4?`${Math.floor(t/1e3)}s`:t<36e5?`${Math.floor(t/6e4)}m`:`${Math.floor(t/36e5)}h`})():null,$=(a?.pending??0)+(a?.running??0),I=a?.failed?"warn":$>0?"ok":"neutral",L=(l?.totalTools??0)>0?"ok":"neutral",_=(o?.online??0)>0?"ok":(o?.total??0)>0?"warn":"neutral",D=u.length>0?"ok":"neutral",M=(x?.enabled??0)>0?"ok":"neutral";return e.jsxs(d.div,{className:"space-y-6",variants:ee,initial:"hidden",animate:"show",children:[e.jsxs(d.div,{variants:c,className:"flex items-center gap-3",children:[e.jsx("div",{className:"w-10 h-10 rounded-lg bg-azure-primary/10 dark:bg-matrix-highlight/10 border border-azure-primary/20 dark:border-matrix-highlight/30 flex items-center justify-center",children:e.jsx(V,{className:"w-5 h-5 text-azure-primary dark:text-matrix-highlight"})}),e.jsxs("div",{children:[e.jsx("h1",{className:"text-xl font-bold text-azure-text dark:text-matrix-highlight",children:"Dashboard"}),e.jsx("p",{className:"text-sm text-azure-text-secondary dark:text-matrix-tertiary",children:"Overview of the Morpheus agent runtime."})]})]}),e.jsxs(d.div,{variants:c,className:"grid grid-cols-1 sm:grid-cols-3 gap-4",children:[e.jsx(k,{title:"Agent Status",value:r?.status.toUpperCase()??"CONNECTING...",icon:F,subValue:r?`PID: ${r.pid}`:""}),e.jsx(k,{title:"Uptime",value:r?U(r.uptimeSeconds):"-",icon:j,subValue:r?`${r.uptimeSeconds.toFixed(0)}s elapsed`:""}),e.jsx(k,{title:"Version",value:r?.projectVersion??"-",icon:O,subValue:`Node ${r?.nodeVersion??"-"}`})]}),e.jsxs(d.div,{variants:c,className:"grid grid-cols-2 md:grid-cols-4 gap-4",children:[e.jsxs("div",{className:"rounded-lg border border-azure-border dark:border-matrix-primary bg-white dark:bg-black p-4",children:[e.jsx("p",{className:"text-[10px] font-semibold uppercase tracking-wider text-azure-text-secondary dark:text-matrix-tertiary mb-2",children:"Provider"}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(J,{className:"w-4 h-4 text-azure-primary dark:text-matrix-highlight shrink-0"}),e.jsx("p",{className:"text-base font-bold text-azure-text dark:text-matrix-highlight truncate",children:r?.llmProvider?.toUpperCase()??"—"})]})]}),e.jsxs("div",{className:"rounded-lg border border-azure-border dark:border-matrix-primary bg-white dark:bg-black p-4",children:[e.jsx("p",{className:"text-[10px] font-semibold uppercase tracking-wider text-azure-text-secondary dark:text-matrix-tertiary mb-2",children:"Model"}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(W,{className:"w-4 h-4 text-azure-primary dark:text-matrix-highlight shrink-0"}),e.jsx("p",{className:"text-sm font-bold text-azure-text dark:text-matrix-highlight truncate leading-tight",children:r?.llmModel??"—"})]})]}),e.jsxs("div",{className:"rounded-lg border border-azure-border dark:border-matrix-primary bg-white dark:bg-black p-4",children:[e.jsx("p",{className:"text-[10px] font-semibold uppercase tracking-wider text-azure-text-secondary dark:text-matrix-tertiary mb-2",children:"Total Tokens"}),e.jsx("p",{className:"text-xl font-bold text-azure-text dark:text-matrix-highlight",children:v>0?g(v):"—"}),e.jsxs("p",{className:"text-[10px] text-azure-text-secondary dark:text-matrix-tertiary mt-1",children:[g(i?.totalInputTokens??0)," in · ",g(i?.totalOutputTokens??0)," out"]})]}),e.jsxs("div",{className:"rounded-lg border border-azure-border dark:border-matrix-primary bg-white dark:bg-black p-4",children:[e.jsx("p",{className:"text-[10px] font-semibold uppercase tracking-wider text-azure-text-secondary dark:text-matrix-tertiary mb-2",children:"Est. Cost"}),e.jsxs("div",{className:"flex items-center gap-1.5",children:[e.jsx(B,{className:"w-4 h-4 text-emerald-500 shrink-0"}),e.jsx("p",{className:"text-xl font-bold text-azure-text dark:text-matrix-highlight",children:f?`$${T.toFixed(4)}`:"—"})]}),e.jsx("p",{className:"text-[10px] text-azure-text-secondary dark:text-matrix-tertiary mt-1",children:f?"accumulated total":"configure pricing to track"})]})]}),e.jsxs(d.div,{variants:c,children:[e.jsx("p",{className:"text-[10px] font-semibold uppercase tracking-wider text-azure-text-secondary dark:text-matrix-tertiary mb-3",children:"Platform"}),e.jsxs("div",{className:"grid grid-cols-1 sm:grid-cols-2 lg:grid-cols-5 gap-4",children:[e.jsxs(m,{icon:G,title:"Skills",to:"/skills",status:M,children:[e.jsx(s,{label:"Enabled",value:x?`${x.enabled} / ${x.total}`:"—",highlight:(x?.enabled??0)>0}),e.jsx(s,{label:"Total",value:x?.total??"—"})]}),e.jsxs(m,{icon:H,title:"MCP Servers",to:"/mcp-servers",status:L,children:[e.jsx(s,{label:"Tools loaded",value:l?.totalTools??"—",highlight:!!l?.totalTools}),e.jsx(s,{label:"Servers",value:l?.servers?.length??"—"}),l?.lastLoadedAt&&e.jsx(s,{label:"Last loaded",value:new Date(l.lastLoadedAt).toLocaleTimeString(void 0,{hour:"2-digit",minute:"2-digit"})})]}),e.jsxs(m,{icon:q,title:"Smiths",to:"/smiths",status:_,children:[e.jsx(s,{label:"Online",value:o?`${o.online} / ${o.total}`:"—",highlight:(o?.online??0)>0}),e.jsx(s,{label:"System",value:o?.enabled?"enabled":"disabled"})]}),e.jsxs(m,{icon:X,title:"Tasks",to:"/tasks",status:I,children:[e.jsx(s,{label:"Running",value:a?.running??"—",highlight:!!a?.running}),e.jsx(s,{label:"Pending",value:a?.pending??"—"}),e.jsx(s,{label:"Completed",value:a?.completed??"—"}),(a?.failed??0)>0&&e.jsx(s,{label:"Failed",value:a.failed})]}),e.jsxs(m,{icon:j,title:"Chronos",to:"/chronos",status:D,children:[e.jsx(s,{label:"Active jobs",value:u.length,highlight:u.length>0}),e.jsx(s,{label:"Total jobs",value:h.length}),N&&e.jsx(s,{label:"Next run",value:`in ${N}`})]})]})]}),p.length>0&&e.jsxs(d.div,{variants:c,children:[e.jsxs("div",{className:"flex items-center justify-between mb-3",children:[e.jsx("p",{className:"text-[10px] font-semibold uppercase tracking-wider text-azure-text-secondary dark:text-matrix-tertiary",children:"Recent Tasks"}),e.jsxs(C,{to:"/tasks",className:"flex items-center gap-0.5 text-xs text-azure-primary dark:text-matrix-highlight hover:underline",children:["View all ",e.jsx(S,{className:"w-3 h-3"})]})]}),e.jsx("div",{className:"rounded-lg border border-azure-border dark:border-matrix-primary overflow-hidden",children:p.map((t,b)=>e.jsxs("div",{className:`flex items-center gap-3 px-4 py-2.5 ${b<p.length-1?"border-b border-azure-border dark:border-matrix-primary/30":""} hover:bg-azure-surface/60 dark:hover:bg-zinc-900/50 transition-colors`,children:[e.jsx(te,{status:t.status}),e.jsx("span",{className:"font-mono text-[10px] text-azure-text-secondary dark:text-matrix-tertiary w-16 shrink-0",children:t.id.slice(0,8)}),e.jsx("span",{className:"flex-1 text-xs text-azure-text dark:text-matrix-secondary truncate",children:t.input.slice(0,100)}),e.jsx("span",{className:"text-[10px] font-mono uppercase text-azure-text-secondary dark:text-matrix-tertiary shrink-0",children:t.agent}),e.jsx("span",{className:"text-[10px] text-azure-text-secondary dark:text-matrix-tertiary shrink-0",children:new Date(t.created_at).toLocaleTimeString(void 0,{hour:"2-digit",minute:"2-digit"})})]},t.id))})]})]})}export{xe as Dashboard};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as e,m as n}from"./vendor-motion-C3CZ8ZlO.js";import{r as i,L as P}from"./vendor-react-DikRIOlj.js";import{u as S}from"./vendor-utils-D4NnWbOU.js";import{w as y,D as _,e as D,j as R}from"./index-BcX5O7kY.js";import{P as O}from"./Pagination-BHZKk42X.js";import{B as k,a8 as A,a9 as F,aa as B,_ as L,p as W,q as E,g as J}from"./vendor-icons-NHF9HNeN.js";const M={hidden:{opacity:0},show:{opacity:1,transition:{staggerChildren:.05}}},g={hidden:{opacity:0,y:10},show:{opacity:1,y:0}},j=({status:r})=>r==="completed"?e.jsxs("div",{className:"flex items-center gap-1.5 text-green-600 dark:text-green-400",children:[e.jsx(W,{className:"w-4 h-4"}),e.jsx("span",{className:"text-xs",children:"Completed"})]}):r==="failed"?e.jsxs("div",{className:"flex items-center gap-1.5 text-red-600 dark:text-red-400",children:[e.jsx(E,{className:"w-4 h-4"}),e.jsx("span",{className:"text-xs",children:"Failed"})]}):e.jsxs("div",{className:"flex items-center gap-1.5 text-yellow-600 dark:text-yellow-400",children:[e.jsx(J,{className:"w-4 h-4 animate-pulse"}),e.jsx("span",{className:"text-xs",children:"Pending"})]}),x=r=>new Date(r).toLocaleString(void 0,{month:"short",day:"numeric",hour:"2-digit",minute:"2-digit"}),U=r=>{try{return JSON.stringify(JSON.parse(r),null,2)}catch{return r}},X=()=>{const[r,f]=i.useState(!1),[c,N]=i.useState("all"),[m,d]=i.useState(1),[h,v]=i.useState(20),[a,u]=i.useState(null),{data:s,mutate:z}=S(["/webhooks/notifications",r,c,m,h],()=>y.listNotifications({unreadOnly:r,status:c,page:m,per_page:h}),{refreshInterval:5e3}),o=s?.data??[],l=o.filter(t=>!t.read).length,b=async t=>{t.length!==0&&(await y.markRead(t),await z())},w=()=>{const t=o.filter(p=>!p.read).map(p=>p.id);b(t)},C=async t=>{u(t),t.read||await b([t.id])};return e.jsxs(n.div,{variants:M,initial:"hidden",animate:"show",className:"space-y-6",children:[e.jsxs(n.div,{variants:g,className:"flex items-center justify-between flex-wrap gap-3",children:[e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsxs("div",{className:"relative w-10 h-10 rounded-lg bg-azure-primary/10 dark:bg-matrix-highlight/10 border border-azure-primary/20 dark:border-matrix-highlight/30 flex items-center justify-center",children:[e.jsx(k,{className:"w-5 h-5 text-azure-primary dark:text-matrix-highlight"}),l>0&&e.jsx("span",{className:"absolute -top-1.5 -right-1.5 bg-red-500 text-white text-[10px] font-bold rounded-full w-4 h-4 flex items-center justify-center leading-none",children:l>9?"9+":l})]}),e.jsxs("div",{children:[e.jsx("h1",{className:"text-xl font-bold text-azure-text dark:text-matrix-highlight",children:"Notifications"}),e.jsx("p",{className:"text-sm text-azure-text-secondary dark:text-matrix-tertiary mt-0.5",children:"Webhook execution results from the Oracle agent."})]})]}),e.jsxs("div",{className:"flex items-center gap-3 flex-wrap",children:[e.jsxs(P,{to:"/webhooks",className:"flex items-center gap-2 text-sm text-azure-text-secondary dark:text-matrix-dim hover:text-azure-primary dark:hover:text-matrix-highlight transition-colors",children:[e.jsx(A,{className:"w-4 h-4"}),"Back to Webhooks"]}),e.jsxs("select",{value:c,onChange:t=>{N(t.target.value),d(1)},className:"px-3 py-2 rounded-lg border border-azure-border dark:border-matrix-primary bg-white dark:bg-black text-azure-text-secondary dark:text-matrix-dim text-sm focus:outline-none focus:border-azure-primary dark:focus:border-matrix-highlight",children:[e.jsx("option",{value:"all",children:"All statuses"}),e.jsx("option",{value:"completed",children:"Completed"}),e.jsx("option",{value:"failed",children:"Failed"}),e.jsx("option",{value:"pending",children:"Pending"})]}),e.jsxs("button",{onClick:()=>{f(!r),d(1)},className:`flex items-center gap-2 px-3 py-2 rounded-lg border text-sm transition-colors ${r?"border-azure-primary dark:border-matrix-highlight bg-azure-active dark:bg-matrix-primary/20 text-azure-primary dark:text-matrix-highlight":"border-azure-border dark:border-matrix-primary text-azure-text-secondary dark:text-matrix-dim hover:bg-azure-surface dark:hover:bg-zinc-800"}`,children:[e.jsx(F,{className:"w-4 h-4"}),"Unread only"]}),l>0&&e.jsxs("button",{onClick:w,className:"flex items-center gap-2 px-3 py-2 rounded-lg border border-azure-border dark:border-matrix-primary text-sm text-azure-text-secondary dark:text-matrix-dim hover:bg-azure-surface dark:hover:bg-zinc-800 transition-colors",children:[e.jsx(B,{className:"w-4 h-4"}),"Mark all read"]})]})]}),e.jsx(n.div,{variants:g,className:"rounded-lg border border-azure-border dark:border-matrix-primary overflow-hidden",children:e.jsx("div",{className:"overflow-x-auto",children:e.jsxs("table",{className:"w-full text-sm",children:[e.jsx("thead",{className:"bg-azure-surface dark:bg-zinc-900 border-b border-azure-border dark:border-matrix-primary",children:e.jsx("tr",{children:["","Webhook","Status","Created","Completed","Actions"].map(t=>e.jsx("th",{className:"px-4 py-3 text-left font-semibold text-azure-text-secondary dark:text-matrix-dim",children:t},t))})}),e.jsx("tbody",{children:o.length===0?e.jsx("tr",{children:e.jsx("td",{colSpan:6,className:"px-4 py-10 text-center text-azure-text-secondary dark:text-matrix-dim",children:r?"No unread notifications.":"No notifications yet."})}):o.map(t=>e.jsxs("tr",{className:`border-b border-azure-border dark:border-matrix-primary/30 hover:bg-azure-surface/50 dark:hover:bg-zinc-800/50 transition-colors ${t.read?"":"bg-blue-50/40 dark:bg-blue-900/10"}`,children:[e.jsx("td",{className:"px-4 py-3 w-6",children:!t.read&&e.jsx("span",{className:"inline-block w-2 h-2 rounded-full bg-blue-500 dark:bg-matrix-highlight"})}),e.jsx("td",{className:"px-4 py-3 font-mono font-medium text-azure-text-primary dark:text-matrix-text",children:t.webhook_name}),e.jsx("td",{className:"px-4 py-3",children:e.jsx(j,{status:t.status})}),e.jsx("td",{className:"px-4 py-3 text-xs text-azure-text-secondary dark:text-matrix-dim whitespace-nowrap",children:x(t.created_at)}),e.jsx("td",{className:"px-4 py-3 text-xs text-azure-text-secondary dark:text-matrix-dim whitespace-nowrap",children:t.completed_at?x(t.completed_at):"—"}),e.jsx("td",{className:"px-4 py-3",children:e.jsx("button",{onClick:()=>C(t),title:"View details",className:"p-1.5 rounded hover:bg-azure-border dark:hover:bg-matrix-primary/30 text-azure-text-secondary dark:text-matrix-dim hover:text-azure-primary dark:hover:text-matrix-highlight transition-colors",children:e.jsx(L,{className:"w-4 h-4"})})})]},t.id))})]})})}),s&&s.total_pages>1&&e.jsx(n.div,{variants:g,children:e.jsx("div",{className:"rounded-lg border border-azure-border dark:border-matrix-primary bg-white dark:bg-black",children:e.jsx(O,{page:m,totalPages:s.total_pages,perPage:h,total:s.total,onPageChange:d,onPerPageChange:t=>{v(t),d(1)}})})}),e.jsxs(_,{open:!!a,onOpenChange:t=>!t&&u(null),children:[e.jsx(D,{children:e.jsxs(R,{className:"text-azure-text-primary dark:text-matrix-highlight flex items-center gap-2",children:[e.jsx(k,{className:"w-4 h-4"}),a?.webhook_name]})}),a&&e.jsxs("div",{className:"p-6 space-y-4 overflow-y-auto max-h-[65vh]",children:[e.jsxs("div",{className:"flex items-center gap-4 text-xs text-azure-text-secondary dark:text-matrix-dim",children:[e.jsx(j,{status:a.status}),e.jsx("span",{children:x(a.created_at)}),a.completed_at&&e.jsxs("span",{children:["→ ",x(a.completed_at)]})]}),e.jsxs("div",{children:[e.jsx("p",{className:"text-sm font-medium text-azure-text-secondary dark:text-matrix-dim mb-1.5",children:"Received Payload"}),e.jsx("pre",{className:"bg-azure-bg dark:bg-zinc-950 rounded-lg p-3 text-xs font-mono overflow-auto max-h-44 text-azure-text-primary dark:text-matrix-text border border-azure-border dark:border-matrix-primary/30 whitespace-pre-wrap",children:U(a.payload)})]}),e.jsxs("div",{children:[e.jsx("p",{className:"text-sm font-medium text-azure-text-secondary dark:text-matrix-dim mb-1.5",children:"Agent Result"}),e.jsx("div",{className:"bg-azure-bg dark:bg-zinc-950 rounded-lg p-3 text-xs font-mono overflow-auto max-h-64 text-azure-text-primary dark:text-matrix-text border border-azure-border dark:border-matrix-primary/30 whitespace-pre-wrap",children:a.result??e.jsx("span",{className:"text-yellow-600 dark:text-yellow-400 animate-pulse",children:"Processing…"})})]}),e.jsx("div",{className:"flex justify-end pt-2",children:e.jsx("button",{onClick:()=>u(null),className:"px-4 py-2 rounded-lg border border-azure-border dark:border-matrix-primary text-azure-text-secondary dark:text-matrix-dim text-sm hover:bg-azure-surface dark:hover:bg-zinc-800 transition-colors",children:"Close"})})]})]})]})};export{X as Notifications};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{j as e}from"./vendor-motion-C3CZ8ZlO.js";import{r as i}from"./vendor-react-DikRIOlj.js";import{B as j,h as N}from"./index-BcX5O7kY.js";import{M as de,D as oe}from"./DeleteConfirmationModal-kZ_c3sFk.js";import{V as xe,Y as me,Z as H,g as ue,_ as O,$ as he,a0 as ge,A as pe,z as B,a1 as fe}from"./vendor-icons-NHF9HNeN.js";import{P as je}from"./Pagination-BHZKk42X.js";import"./vendor-utils-D4NnWbOU.js";const ye=({className:r,...a})=>e.jsx("div",{className:"relative w-full overflow-auto",children:e.jsx("table",{className:`w-full caption-bottom text-sm ${r}`,...a})}),be=({...r})=>e.jsx("thead",{...r}),ke=({...r})=>e.jsx("tbody",{...r}),M=({...r})=>e.jsx("tr",{className:"border-b border-azure-border dark:border-matrix-primary/30 transition-colors hover:bg-azure-hover/50 dark:hover:bg-matrix-primary/10",...r}),f=({className:r,...a})=>e.jsx("th",{className:`h-12 px-4 text-left align-middle font-medium text-azure-text-secondary dark:text-matrix-secondary/70 [&:has([role=checkbox])]:pr-0 ${r}`,...a}),g=({className:r,...a})=>e.jsx("td",{className:`p-4 align-middle [&:has([role=checkbox])]:pr-0 ${r}`,...a}),F=({checked:r,onCheckedChange:a,className:s,...n})=>{const l=x=>{a&&a(x.target.checked),n.onChange&&n.onChange(x)};return e.jsx("input",{type:"checkbox",checked:r,onChange:l,className:`h-4 w-4 rounded border-azure-border dark:border-matrix-primary bg-azure-surface dark:bg-black text-azure-primary dark:text-matrix-highlight focus:ring-azure-primary dark:focus:ring-matrix-highlight ${s||""}`,...n})},v=({className:r,variant:a="default",...s})=>{const l=`inline-flex items-center rounded-full px-2.5 py-0.5 text-xs font-semibold transition-colors focus:outline-none focus:ring-2 focus:ring-zinc-950 focus:ring-offset-2 dark:focus:ring-zinc-300 ${a==="destructive"?"border-transparent bg-red-500 text-zinc-50 dark:bg-red-900 dark:text-zinc-50":a==="secondary"?"border-transparent bg-azure-surface dark:bg-zinc-800 text-azure-text-secondary dark:text-matrix-secondary":a==="outline"?"text-azure-text-primary dark:text-matrix-secondary border-azure-border dark:border-matrix-primary":"border-transparent bg-azure-primary dark:bg-matrix-highlight text-azure-text-inverse dark:text-black"} ${r||""}`;return e.jsx("div",{className:l,...s})},T=({className:r,...a})=>e.jsx("div",{className:`rounded-lg border border-azure-border dark:border-matrix-primary/30 bg-azure-surface dark:bg-zinc-900 text-azure-text-primary dark:text-matrix-secondary shadow-sm ${r||""}`,...a}),I=({className:r,...a})=>e.jsx("div",{className:`flex flex-col space-y-1.5 p-6 ${r||""}`,...a}),Ne=({className:r,...a})=>e.jsx("h3",{className:`text-2xl font-semibold leading-none tracking-tight ${r||""}`,...a}),A=({className:r,...a})=>e.jsx("div",{className:`p-6 pt-0 ${r||""}`,...a}),ve=({className:r,variant:a="default",...s})=>{const l=`relative w-full rounded-lg border p-4 ${a==="destructive"?"border-red-500/50 text-red-700 dark:border-red-900/50 dark:text-red-300":"border-azure-border dark:border-matrix-primary"} ${r||""}`;return e.jsx("div",{className:l,...s})},ze=({className:r,...a})=>e.jsx("div",{className:`text-sm [&_p]:leading-relaxed ${r||""}`,...a}),we=({isOpen:r,onClose:a,memory:s})=>s?e.jsx(de,{isOpen:r,onClose:a,title:"Memory Details",size:"lg",children:e.jsxs("div",{className:"space-y-6",children:[e.jsxs("div",{className:"grid grid-cols-1 md:grid-cols-2 gap-4",children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(xe,{className:"w-4 h-4 text-azure-text-secondary dark:text-matrix-tertiary"}),e.jsx("span",{className:"text-azure-text-secondary dark:text-matrix-tertiary text-sm",children:"Category"})]}),e.jsx("div",{children:e.jsx(v,{variant:"outline",children:s.category})}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(me,{className:"w-4 h-4 text-azure-text-secondary dark:text-matrix-tertiary"}),e.jsx("span",{className:"text-azure-text-secondary dark:text-matrix-tertiary text-sm",children:"Importance"})]}),e.jsx("div",{children:e.jsx(v,{variant:s.importance==="critical"?"destructive":s.importance==="high"?"default":s.importance==="medium"?"secondary":"outline",children:s.importance})}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(H,{className:"w-4 h-4 text-azure-text-secondary dark:text-matrix-tertiary"}),e.jsx("span",{className:"text-azure-text-secondary dark:text-matrix-tertiary text-sm",children:"Created"})]}),e.jsx("div",{className:"text-azure-text-primary dark:text-matrix-secondary",children:new Date(s.created_at).toLocaleString()}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(ue,{className:"w-4 h-4 text-azure-text-secondary dark:text-matrix-tertiary"}),e.jsx("span",{className:"text-azure-text-secondary dark:text-matrix-tertiary text-sm",children:"Updated"})]}),e.jsx("div",{className:"text-azure-text-primary dark:text-matrix-secondary",children:new Date(s.updated_at).toLocaleString()}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(O,{className:"w-4 h-4 text-azure-text-secondary dark:text-matrix-tertiary"}),e.jsx("span",{className:"text-azure-text-secondary dark:text-matrix-tertiary text-sm",children:"Access Count"})]}),e.jsx("div",{className:"text-azure-text-primary dark:text-matrix-secondary",children:s.access_count}),e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(he,{className:"w-4 h-4 text-azure-text-secondary dark:text-matrix-tertiary"}),e.jsx("span",{className:"text-azure-text-secondary dark:text-matrix-tertiary text-sm",children:"Hash"})]}),e.jsx("div",{className:"text-azure-text-primary dark:text-matrix-secondary break-all text-sm",children:s.hash}),s.source&&e.jsxs(e.Fragment,{children:[e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsx(ge,{className:"w-4 h-4 text-azure-text-secondary dark:text-matrix-tertiary"}),e.jsx("span",{className:"text-azure-text-secondary dark:text-matrix-tertiary text-sm",children:"Source"})]}),e.jsx("div",{className:"text-azure-text-primary dark:text-matrix-secondary",children:s.source})]})]}),e.jsxs("div",{children:[e.jsx("h4",{className:"text-azure-text-secondary dark:text-matrix-tertiary text-sm mb-2",children:"Summary"}),e.jsx("p",{className:"text-azure-text-primary dark:text-matrix-secondary bg-azure-surface dark:bg-zinc-900 p-3 rounded-md",children:s.summary})]}),s.details&&e.jsxs("div",{children:[e.jsx("h4",{className:"text-azure-text-secondary dark:text-matrix-tertiary text-sm mb-2",children:"Details"}),e.jsx("div",{className:"text-azure-text-primary dark:text-matrix-secondary bg-azure-surface dark:bg-zinc-900 p-3 rounded-md whitespace-pre-wrap",children:s.details})]}),e.jsx("div",{className:"flex justify-end pt-4",children:e.jsx(j,{onClick:a,children:"Close"})})]})}):null,Ce=()=>{const[r,a]=i.useState(!1),[s,n]=i.useState(null),l=i.useCallback(o=>(a(!0),n(null),N.get(o).then(c=>c).catch(c=>{throw n(c.message||"An error occurred"),c}).finally(()=>{a(!1)})),[]),x=i.useCallback((o,c)=>(a(!0),n(null),N.post(o,c).then(d=>d).catch(d=>{throw n(d.message||"An error occurred"),d}).finally(()=>{a(!1)})),[]),m=i.useCallback((o,c)=>(a(!0),n(null),N.post(o,c).then(d=>d).catch(d=>{throw n(d.message||"An error occurred"),d}).finally(()=>{a(!1)})),[]),z=i.useCallback(o=>(a(!0),n(null),N.delete(o).then(c=>c).catch(c=>{throw n(c.message||"An error occurred"),c}).finally(()=>{a(!1)})),[]);return{get:l,post:x,put:m,del:z,loading:r,error:s}},_e=()=>{const[r,a]=i.useState([]),[s,n]=i.useState(!0),[l,x]=i.useState([]),[m,z]=i.useState(""),[o,c]=i.useState("all"),[d,R]=i.useState("all"),[u,y]=i.useState(1),[h,U]=i.useState(20),[V,q]=i.useState(0),[$,Y]=i.useState(1),[P,b]=i.useState(null),[Z,w]=i.useState(!1),[G,J]=i.useState(null),[K,_]=i.useState(!1),[E,L]=i.useState(null),[Q,C]=i.useState(!1),{get:W,del:X,post:ee}=Ce(),S=i.useCallback(async(t=u,D=h)=>{try{n(!0);const p=new URLSearchParams({page:String(t),per_page:String(D)});o!=="all"&&p.set("category",o),d!=="all"&&p.set("importance",d),m.trim()&&p.set("search",m.trim());const k=await W(`/sati/memories?${p}`);a(k.data??k),q(k.total??0),Y(k.total_pages??1),b(null)}catch(p){b("Failed to load memories. Please try again."),console.error("Error fetching memories:",p)}finally{n(!1)}},[u,h,o,d,m]);i.useEffect(()=>{S(u,h)},[u,h,o,d,m]);const te=()=>{l.length===r.length?x([]):x(r.map(t=>t.id))},re=t=>{l.includes(t)?x(l.filter(D=>D!==t)):x([...l,t])},ae=async()=>{if(l.length!==0)try{await ee("/sati/memories/bulk-delete",{ids:l}),await S(u,h),x([]),w(!1)}catch(t){b("Failed to delete memories. Please try again."),console.error("Error deleting memories:",t)}},se=t=>{L(t),C(!0)},ie=async()=>{if(E)try{await X(`/sati/memories/${E}`),await S(u,h)}catch(t){b("Failed to delete memory. Please try again."),console.error("Error deleting memory:",t)}finally{L(null),C(!1)}},le=t=>{J(t),_(!0)},ne=["preference","project","identity","constraint","context","personal_data","languages","favorite_things","relationships","pets","naming","professional_profile"],ce=["low","medium","high"];return s&&r.length===0?e.jsx(T,{className:"w-full",children:e.jsx(A,{className:"flex justify-center items-center h-64",children:e.jsx("div",{className:"animate-spin rounded-full h-8 w-8 border-b-2 border-azure-primary dark:border-matrix-highlight"})})}):e.jsxs("div",{className:"space-y-6",children:[e.jsxs("div",{className:"flex flex-col sm:flex-row justify-between items-start sm:items-center gap-4",children:[e.jsxs("div",{className:"flex items-center gap-3",children:[e.jsx("div",{className:"w-10 h-10 rounded-lg bg-azure-primary/10 dark:bg-matrix-highlight/10 border border-azure-primary/20 dark:border-matrix-highlight/30 flex items-center justify-center",children:e.jsx(pe,{className:"w-5 h-5 text-azure-primary dark:text-matrix-highlight"})}),e.jsxs("div",{children:[e.jsx("h1",{className:"text-xl font-bold text-azure-text dark:text-matrix-highlight",children:"Sati Memories"}),e.jsx("p",{className:"text-sm text-azure-text-secondary dark:text-matrix-tertiary",children:"View and manage long-term memories stored by Sati."})]})]}),l.length>0&&e.jsxs("div",{className:"flex items-center gap-2",children:[e.jsxs("span",{className:"text-sm text-azure-text-muted dark:text-matrix-secondary",children:[l.length," selected"]}),e.jsxs(j,{variant:"destructive",size:"sm",onClick:()=>w(!0),disabled:l.length===0,children:[e.jsx(B,{className:"w-4 h-4 mr-1"}),"Delete Selected"]})]})]}),P&&e.jsx(ve,{variant:"destructive",children:e.jsx(ze,{children:P})}),e.jsxs(T,{children:[e.jsx(I,{className:"border-b border-azure-border dark:border-matrix-primary",children:e.jsxs("div",{className:"flex flex-col lg:flex-row gap-4",children:[e.jsxs("div",{className:"flex flex-col relative w-full",children:[e.jsx(fe,{className:"absolute left-3 top-1/2 transform -translate-y-1/2 text-azure-text-secondary dark:text-matrix-secondary w-4 h-4"}),e.jsx("input",{type:"text",placeholder:"Search memories...",value:m,onChange:t=>{z(t.target.value),y(1)},className:"w-full pl-10 pr-4 py-2 bg-azure-surface dark:bg-black border border-azure-border dark:border-matrix-primary rounded-md text-azure-text-primary dark:text-matrix-secondary focus:outline-none focus:ring-2 focus:ring-azure-primary dark:focus:ring-matrix-highlight"})]}),e.jsxs("div",{className:"flex flex-col sm:flex-row gap-2 w-full",children:[e.jsxs("select",{value:o,onChange:t=>{c(t.target.value),y(1)},className:"px-3 py-2 bg-azure-surface dark:bg-black border border-azure-border dark:border-matrix-primary rounded-md text-azure-text-primary dark:text-matrix-secondary focus:outline-none focus:ring-2 focus:ring-azure-primary dark:focus:ring-matrix-highlight flex-grow",children:[e.jsx("option",{value:"all",children:"All Categories"}),ne.map(t=>e.jsx("option",{value:t,children:t},t))]}),e.jsxs("select",{value:d,onChange:t=>{R(t.target.value),y(1)},className:"px-3 py-2 bg-azure-surface dark:bg-black border border-azure-border dark:border-matrix-primary rounded-md text-azure-text-primary dark:text-matrix-secondary focus:outline-none focus:ring-2 focus:ring-azure-primary dark:focus:ring-matrix-highlight flex-grow",children:[e.jsx("option",{value:"all",children:"All Importance"}),ce.map(t=>e.jsx("option",{value:t,children:t},t))]})]})]})}),e.jsx(A,{className:"p-0",children:e.jsxs(ye,{children:[e.jsx(be,{children:e.jsxs(M,{className:"hover:bg-transparent",children:[e.jsx(f,{className:"w-12",children:e.jsx(F,{checked:r.length>0&&l.length===r.length,onCheckedChange:te})}),e.jsx(f,{children:"Summary"}),e.jsx(f,{children:"Category"}),e.jsx(f,{children:"Importance"}),e.jsx(f,{children:"Created"}),e.jsx(f,{className:"w-32",children:"Actions"})]})}),e.jsx(ke,{children:r.length===0?e.jsx(M,{children:e.jsx(g,{colSpan:6,className:"text-center py-8 text-azure-text-secondary dark:text-matrix-secondary",children:s?"Loading memories...":"No memories found"})}):r.map(t=>e.jsxs(M,{children:[e.jsx(g,{children:e.jsx(F,{checked:l.includes(t.id),onCheckedChange:()=>re(t.id)})}),e.jsx(g,{className:"font-medium max-w-xs truncate",children:t.summary}),e.jsx(g,{children:e.jsx(v,{variant:"outline",children:t.category})}),e.jsx(g,{children:e.jsx(v,{variant:t.importance==="critical"?"destructive":t.importance==="high"?"default":t.importance==="medium"?"secondary":"outline",children:t.importance})}),e.jsx(g,{children:e.jsxs("div",{className:"flex items-center gap-1 text-azure-text-secondary dark:text-matrix-secondary",children:[e.jsx(H,{className:"w-4 h-4"}),new Date(t.created_at).toLocaleDateString()]})}),e.jsx(g,{children:e.jsxs("div",{className:"flex gap-1",children:[e.jsx(j,{variant:"ghost",size:"sm",onClick:()=>le(t),className:"text-blue-500 hover:text-blue-700 dark:text-blue-400 dark:hover:text-blue-300",children:e.jsx(O,{className:"w-4 h-4"})}),e.jsx(j,{variant:"ghost",size:"sm",onClick:()=>se(t.id),className:"text-red-500 hover:text-red-700 dark:text-red-400 dark:hover:text-red-300",children:e.jsx(B,{className:"w-4 h-4"})})]})})]},t.id))})]})}),$>1&&e.jsx(je,{page:u,totalPages:$,perPage:h,total:V,onPageChange:y,onPerPageChange:t=>{U(t),y(1)}})]}),Z&&e.jsx("div",{className:"fixed inset-0 bg-black/50 flex items-center justify-center z-50",children:e.jsxs(T,{className:"w-full max-w-md mx-4",children:[e.jsx(I,{children:e.jsx(Ne,{children:"Delete Memories"})}),e.jsxs(A,{children:[e.jsxs("p",{className:"mb-4",children:["Are you sure you want to delete ",l.length," ","memory(ies)? This action cannot be undone."]}),e.jsxs("div",{className:"flex justify-end gap-2",children:[e.jsx(j,{variant:"outline",onClick:()=>w(!1),children:"Cancel"}),e.jsx(j,{variant:"destructive",onClick:ae,children:"Delete"})]})]})]})}),e.jsx(we,{isOpen:K,onClose:()=>_(!1),memory:G}),e.jsx(oe,{isOpen:Q,onClose:()=>C(!1),onConfirm:ie,title:"Confirm Memory Deletion",message:"Are you sure you want to delete this memory? This action cannot be undone.",confirmButtonText:"Delete Memory",cancelButtonText:"Cancel"})]})};export{_e as SatiMemories};
|