@decocms/mesh 1.0.0-alpha.40 → 1.0.0-alpha.42
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/client/assets/{AlertCircle-DXrRWAdV.js → AlertCircle-CP-aGRsA.js} +1 -1
- package/dist/client/assets/{ArrowLeft-B2kSl8Am.js → ArrowLeft-wElnUYJ0.js} +1 -1
- package/dist/client/assets/{CheckCircle-BjfQSM1r.js → CheckCircle-B_WVChj1.js} +1 -1
- package/dist/client/assets/{ChevronDown-LB39JZIr.js → ChevronDown-133w8HOk.js} +1 -1
- package/dist/client/assets/{Clock-umdgxXOC.js → Clock-DqQ41LIc.js} +1 -1
- package/dist/client/assets/{Copy01-Bilz-YTB.js → Copy01-BJwDNoQC.js} +1 -1
- package/dist/client/assets/{CpuChip02-CHm038ee.js → CpuChip02-bWa1f3Y1.js} +1 -1
- package/dist/client/assets/{DotsVertical-Bpn8NPVg.js → DotsVertical-CYYr09mb.js} +1 -1
- package/dist/client/assets/{File06-88jNCz1V.js → File06-Dtn5wW91.js} +1 -1
- package/dist/client/assets/{Grid01-irgYf3_6.js → Grid01-DZvMiQMk.js} +1 -1
- package/dist/client/assets/{Inbox01-CoVSGBs_.js → Inbox01-CSe7MExo.js} +1 -1
- package/dist/client/assets/{InfoCircle-D7V0pgdh.js → InfoCircle-D3bW5Omw.js} +1 -1
- package/dist/client/assets/{Key01-CKDDrXuQ.js → Key01-C1qHez6H.js} +1 -1
- package/dist/client/assets/{LinkExternal01-BWsuTDiz.js → LinkExternal01-BWIXuo1e.js} +1 -1
- package/dist/client/assets/{Loading01-BWm5a2UX.js → Loading01-CAh3R9sn.js} +1 -1
- package/dist/client/assets/{Plus-Slubr3Mn.js → Plus-CYOELvWT.js} +1 -1
- package/dist/client/assets/{SearchMd-D-BfTFbd.js → SearchMd-Bq2ogvbg.js} +1 -1
- package/dist/client/assets/{Trash01-QqFxB-ic.js → Trash01-KvM_z2HW.js} +1 -1
- package/dist/client/assets/{Upload01-BSDcq_ig.js → Upload01-BP0jqpHq.js} +1 -1
- package/dist/client/assets/{X-qVvh8Z0J.js → X-CafPP_Iv.js} +1 -1
- package/dist/client/assets/{XClose-Crvz7f11.js → XClose-CqJrzETU.js} +1 -1
- package/dist/client/assets/{alert-dialog-BKLc86P2.js → alert-dialog-BUlG7TA4.js} +1 -1
- package/dist/client/assets/{auth-g7Ue41hR.js → auth-CJSooDCA.js} +1 -1
- package/dist/client/assets/{auth-catchall-BAv_qdLN.js → auth-catchall-BjCX5usv.js} +1 -1
- package/dist/client/assets/{avatar-7mHRD9aF.js → avatar-Cq0eS4K8.js} +1 -1
- package/dist/client/assets/{badge-CuERIkGI.js → badge-DwRxIVxi.js} +1 -1
- package/dist/client/assets/{button-WiHHb1ae.js → button-DylnVNOq.js} +1 -1
- package/dist/client/assets/{card-BCizSi8r.js → card-DxJ2CMrY.js} +1 -1
- package/dist/client/assets/checkbox-DEErbcc0.js +1 -0
- package/dist/client/assets/collection-detail-CrH6CPOn.js +1 -0
- package/dist/client/assets/{collection-display-button-C_wVSNLi.js → collection-display-button-CvZ8eTT6.js} +1 -1
- package/dist/client/assets/{collection-header-l34pbgNv.js → collection-header-BZWDRhRJ.js} +1 -1
- package/dist/client/assets/{collection-page-BP2Cy5Z_.js → collection-page-Cy4Url61.js} +1 -1
- package/dist/client/assets/{collection-search-ByjFbpzN.js → collection-search-BEr5-om_.js} +1 -1
- package/dist/client/assets/{collection-table-wrapper-PcMFmqtb.js → collection-table-wrapper-CYIQZiF8.js} +1 -1
- package/dist/client/assets/{connection-card-DeV1geDy.js → connection-card-Cjb0De9E.js} +1 -1
- package/dist/client/assets/connection-detail-CtapWDy0.js +1 -0
- package/dist/client/assets/{connections-FFVYK2AT.js → connections-ByAWgP1A.js} +1 -1
- package/dist/client/assets/{core-BdjBMvYV.js → core-CwMiM80c.js} +1 -1
- package/dist/client/assets/{create-organization-dialog-DVhMCLRC.js → create-organization-dialog-CDHLiEAk.js} +1 -1
- package/dist/client/assets/{deco-chat-skeleton-DyT_mbhr.js → deco-chat-skeleton-DpvJuUNp.js} +39 -39
- package/dist/client/assets/{dialog-CbMK5n2S.js → dialog-DHu5nMEY.js} +1 -1
- package/dist/client/assets/{dropdown-menu-24ciec9y.js → dropdown-menu-DiYpBa-u.js} +1 -1
- package/dist/client/assets/{error-boundary-Bstevc3G.js → error-boundary-xo0wHpmi.js} +1 -1
- package/dist/client/assets/{extract-connection-data-BDRFIBL1.js → extract-connection-data-CuVedqWo.js} +1 -1
- package/dist/client/assets/{form-BrDOMpvk.js → form-DJrhF5P2.js} +1 -1
- package/dist/client/assets/formatDistanceToNow-BbvSNUQF.js +1 -0
- package/dist/client/assets/gateway-detail-BOFhJRga.js +1 -0
- package/dist/client/assets/{gateways-DSDcO81b.js → gateways-EOO6wJEW.js} +1 -1
- package/dist/client/assets/{home-jplK_fO7.js → home-BFuz55uE.js} +1 -1
- package/dist/client/assets/index-BwcY8s4g.js +32 -0
- package/dist/client/assets/{index-C3HgpkDC.js → index-Dm4arKBM.js} +1 -1
- package/dist/client/assets/{index-BXYAUeFB.js → index-DrO6_oKQ.js} +14 -14
- package/dist/client/assets/index-MyldRbGR.css +1 -0
- package/dist/client/assets/{index-RVsrtNt7.js → index-dUwc3ttQ.js} +1 -1
- package/dist/client/assets/{input-BElOouK2.js → input-KnYDv1A5.js} +1 -1
- package/dist/client/assets/json-D3Bs6F9t.js +1 -0
- package/dist/client/assets/{json-syntax-highlighter-D6mKVwSQ.js → json-syntax-highlighter-BHL3wK0f.js} +2 -2
- package/dist/client/assets/{layout-BDLGK1gR.js → layout-NjL7irXi.js} +1 -1
- package/dist/client/assets/{lazy-highlighter-nw4fsvsj.js → lazy-highlighter-DfXFtweD.js} +1 -1
- package/dist/client/assets/{localstorage-keys-BbAFEk_U.js → localstorage-keys-Bla3L5Kn.js} +1 -1
- package/dist/client/assets/{login-DlVoXdaF.js → login-DWfPFu6G.js} +1 -1
- package/dist/client/assets/{mcp-oauth-O6gPUgdn.js → mcp-oauth-B3voaRxT.js} +1 -1
- package/dist/client/assets/{members-DnI1WLbh.js → members-zioM9DX4.js} +1 -1
- package/dist/client/assets/{monitoring-WJqycdC6.js → monitoring-BWq8obqP.js} +1 -1
- package/dist/client/assets/{oauth-callback-C-msM3ED.js → oauth-callback-B4ueERM_.js} +1 -1
- package/dist/client/assets/{page-CKHPoEps.js → page-Clx7_tn2.js} +1 -1
- package/dist/client/assets/{popover--gsKamR2.js → popover-BUiNi8m6.js} +1 -1
- package/dist/client/assets/prism-light-CzedzUri.js +1 -0
- package/dist/client/assets/resource-tabs-yB0ODQBX.js +1 -0
- package/dist/client/assets/{schema-DxhaF6b0.js → schema-DS_MXXSd.js} +1 -1
- package/dist/client/assets/{select-DuRyb06m.js → select-D2oQHnH-.js} +1 -1
- package/dist/client/assets/{settings-Cf2w5DBP.js → settings-CPxuZwVp.js} +1 -1
- package/dist/client/assets/shell-layout-BX0g1F2C.js +17 -0
- package/dist/client/assets/{spinner-CkZFBFUf.js → spinner-B-LyDgpm.js} +1 -1
- package/dist/client/assets/{store-BCi6vudl.js → store-DpIupuN4.js} +1 -1
- package/dist/client/assets/store-app-detail-Dzqp2haZ.js +1 -0
- package/dist/client/assets/{switch-D3JJPNlW.js → switch-ZVXF1B-B.js} +1 -1
- package/dist/client/assets/{textarea-4CYb655q.js → textarea-BYzZCFR4.js} +1 -1
- package/dist/client/assets/tools-list-DX1uzNKs.js +1 -0
- package/dist/client/assets/{tooltip-Dgdin-_i.js → tooltip-C9HJ0ESh.js} +1 -1
- package/dist/client/assets/{types-DaSChKd_.js → types-BzJYylI4.js} +1 -1
- package/dist/client/assets/{use-binding-BgnJVxG_.js → use-binding-zihfVeqz.js} +2 -2
- package/dist/client/assets/{use-connection-DcTy916p.js → use-connection-PNwxddOO.js} +1 -1
- package/dist/client/assets/{use-gateway-I6Ko0Jgt.js → use-gateway-v9UrwqWL.js} +1 -1
- package/dist/client/assets/{use-list-state-SFgQOu4M.js → use-list-state-lBd2usQq.js} +1 -1
- package/dist/client/assets/{use-mcp-CiOCImLK.js → use-mcp-DnENzWav.js} +1 -1
- package/dist/client/assets/{use-members-DZwzW0q9.js → use-members-BZ9F4tXm.js} +1 -1
- package/dist/client/assets/{use-mobile-_Q7J0JGT.js → use-mobile-BZVx-pSu.js} +1 -1
- package/dist/client/assets/{use-organization-settings-CWarZMrC.js → use-organization-settings-D8NOmgEj.js} +1 -1
- package/dist/client/assets/{use-tool-call-BWqj0h3N.js → use-tool-call-CDsX2AuI.js} +1 -1
- package/dist/client/assets/useQuery-BeDo1OnH.js +1 -0
- package/dist/client/assets/utils-CzqUBWOD.js +1 -0
- package/dist/client/assets/{well-known-mcp-6m7w8EhN.js → well-known-mcp-0xOmKc1Z.js} +1 -1
- package/dist/client/index.html +2 -2
- package/dist/server/cli.js +164 -164
- package/dist/server/migrate.js +124 -124
- package/dist/server/server.js +123 -123
- package/package.json +1 -1
- package/dist/client/assets/checkbox-D_yjB9VU.js +0 -1
- package/dist/client/assets/collection-detail-CgNwKBY0.js +0 -1
- package/dist/client/assets/connection-detail-z_aMgOoM.js +0 -1
- package/dist/client/assets/formatDistanceToNow-Ctx6mZEP.js +0 -1
- package/dist/client/assets/gateway-detail-DT2HrSfW.js +0 -1
- package/dist/client/assets/index-1pyJ2pUa.js +0 -32
- package/dist/client/assets/index-CyW1ja-u.css +0 -1
- package/dist/client/assets/json-CtipqR6C.js +0 -1
- package/dist/client/assets/prism-light-DntDK3V1.js +0 -1
- package/dist/client/assets/resource-tabs-BwUWNlYE.js +0 -1
- package/dist/client/assets/shell-layout-Ca0-di6U.js +0 -17
- package/dist/client/assets/store-app-detail-CjU1HPaK.js +0 -1
- package/dist/client/assets/useQuery-C_tbj2zS.js +0 -1
- package/dist/client/assets/utils-D2m6QoGq.js +0 -1
- /package/dist/client/assets/{resource-tabs-CSRUKxnt.css → tools-list-CSRUKxnt.css} +0 -0
package/package.json
CHANGED
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{c as d,j as c,bs as n,bt as l}from"./index-BXYAUeFB.js";import{i as m}from"./tooltip-Dgdin-_i.js";import{c as b}from"./utils-D2m6QoGq.js";function f(o){const e=d.c(9);let r,i;e[0]!==o?({className:r,...i}=o,e[0]=o,e[1]=r,e[2]=i):(r=e[1],i=e[2]);let t;e[3]!==r?(t=b("peer border-foreground dark:bg-input/30 data-[state=checked]:bg-primary data-[state=checked]:text-primary-foreground dark:data-[state=checked]:bg-primary data-[state=checked]:border-primary focus-visible:border-ring focus-visible:ring-ring/50 aria-invalid:ring-destructive/20 dark:aria-invalid:ring-destructive/40 aria-invalid:border-destructive size-4 shrink-0 rounded-[4px] border shadow-xs transition-shadow outline-none focus-visible:ring-[3px] disabled:cursor-not-allowed disabled:opacity-50",r),e[3]=r,e[4]=t):t=e[4];let a;e[5]===Symbol.for("react.memo_cache_sentinel")?(a=c.jsx(l,{"data-slot":"checkbox-indicator",className:"flex items-center justify-center text-primary-foreground transition-none",children:c.jsx(m,{className:"size-3.5"})}),e[5]=a):a=e[5];let s;return e[6]!==i||e[7]!==t?(s=c.jsx(n,{"data-slot":"checkbox",className:t,...i,children:a}),e[6]=i,e[7]=t,e[8]=s):s=e[8],s}export{f as C};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as C,c as A,d as K,j as t,av as se,x as he,y as pe,h as ge,b as je,t as ve}from"./index-BXYAUeFB.js";import{U as q,f as be,d as le,c as ne,b as ie,I as Ne,n as ye}from"./use-connection-DcTy916p.js";import{d as we,C as J,j as ae,G as Se,M as Ce}from"./deco-chat-skeleton-DyT_mbhr.js";import{E as ce}from"./SearchMd-D-BfTFbd.js";import{E as X}from"./error-boundary-Bstevc3G.js";import{u as ke,L as Ie}from"./localstorage-keys-BbAFEk_U.js";import{u as _e,a as $e,c as Ee,b as Te,T as Ae}from"./tooltip-Dgdin-_i.js";import{B as G}from"./button-WiHHb1ae.js";import{F as V,a as ze,b as Z,c as Y,d as oe}from"./form-BrDOMpvk.js";import{I as re}from"./input-BElOouK2.js";import{T as ee}from"./textarea-4CYb655q.js";import{c as W}from"./utils-D2m6QoGq.js";import{A as Oe}from"./use-binding-BgnJVxG_.js";import{i as H}from"./Loading01-BWm5a2UX.js";import{s as Me}from"./Plus-Slubr3Mn.js";import{i as Le}from"./Upload01-BSDcq_ig.js";import{V as de,b as te,a as Be}from"./layout-BDLGK1gR.js";import{i as Re}from"./AlertCircle-DXrRWAdV.js";import{s as De}from"./Clock-umdgxXOC.js";import{a as Fe}from"./Copy01-Bilz-YTB.js";import{i as Pe,J as Ue}from"./json-syntax-highlighter-D6mKVwSQ.js";import{s as Je}from"./XClose-Crvz7f11.js";import{u as Ve,O as We,M as Ge,P as qe,E as He}from"./index-1pyJ2pUa.js";import{u as Ke}from"./use-mcp-CiOCImLK.js";import"./Grid01-irgYf3_6.js";import"./CpuChip02-CHm038ee.js";import"./select-DuRyb06m.js";import"./ChevronDown-LB39JZIr.js";import"./use-mobile-_Q7J0JGT.js";import"./use-gateway-I6Ko0Jgt.js";import"./connection-card-DeV1geDy.js";import"./card-BCizSi8r.js";import"./LinkExternal01-BWsuTDiz.js";import"./spinner-CkZFBFUf.js";import"./File06-88jNCz1V.js";import"./InfoCircle-D7V0pgdh.js";import"./useQuery-C_tbj2zS.js";import"./auth-g7Ue41hR.js";import"./ArrowLeft-B2kSl8Am.js";import"./mcp-oauth-O6gPUgdn.js";import"./use-organization-settings-CWarZMrC.js";import"./use-tool-call-BWqj0h3N.js";import"./Key01-CKDDrXuQ.js";import"./formatDistanceToNow-Ctx6mZEP.js";import"./extract-connection-data-BDRFIBL1.js";import"./registry-utils-ulDDT0d8.js";import"./generate-id-Dyweu44Y.js";import"./index-RVsrtNt7.js";import"./index-C3HgpkDC.js";import"./schema-DxhaF6b0.js";const me=({size:s=24,color:e="currentColor",...n})=>C.createElement("svg",{viewBox:"0 0 24 24",width:s,height:s,stroke:e,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...n},C.createElement("path",{d:"M20.5 8v8.2c0 1.68 0 2.52-.327 3.162a3 3 0 0 1-1.311 1.311C18.22 21 17.38 21 15.7 21H8.3c-1.68 0-2.52 0-3.162-.327a3 3 0 0 1-1.311-1.311C3.5 18.72 3.5 17.88 3.5 16.2V8m.1-5h16.8c.56 0 .84 0 1.054.109a1 1 0 0 1 .437.437C22 3.76 22 4.04 22 4.6v1.8c0 .56 0 .84-.109 1.054a1 1 0 0 1-.437.437C21.24 8 20.96 8 20.4 8H3.6c-.56 0-.84 0-1.054-.109a1 1 0 0 1-.437-.437C2 7.24 2 6.96 2 6.4V4.6c0-.56 0-.84.109-1.054a1 1 0 0 1 .437-.437C2.76 3 3.04 3 3.6 3Zm6 8.5h4.8c.56 0 .84 0 1.054.109a1 1 0 0 1 .437.437C16 12.26 16 12.54 16 13.1v.8c0 .56 0 .84-.109 1.054a1 1 0 0 1-.437.437c-.214.109-.494.109-1.054.109H9.6c-.56 0-.84 0-1.054-.109a1 1 0 0 1-.437-.437C8 14.74 8 14.46 8 13.9v-.8c0-.56 0-.84.109-1.054a1 1 0 0 1 .437-.437C8.76 11.5 9.04 11.5 9.6 11.5Z"}));me.displayName="Box";const ue=({size:s=24,color:e="currentColor",...n})=>C.createElement("svg",{viewBox:"0 0 24 24",width:s,height:s,stroke:e,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...n},C.createElement("path",{d:"m16 18 6-6-6-6M8 6l-6 6 6 6"}));ue.displayName="Code01";const fe=({size:s=24,color:e="currentColor",...n})=>C.createElement("svg",{viewBox:"0 0 24 24",width:s,height:s,stroke:e,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...n},C.createElement("path",{d:"M21 5c0 1.657-4.03 3-9 3S3 6.657 3 5m18 0c0-1.657-4.03-3-9-3S3 3.343 3 5m18 0v14c0 1.66-4 3-9 3s-9-1.34-9-3V5m18 7c0 1.66-4 3-9 3s-9-1.34-9-3"}));fe.displayName="Database01";const xe=({size:s=24,color:e="currentColor",...n})=>C.createElement("svg",{viewBox:"0 0 24 24",width:s,height:s,stroke:e,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...n},C.createElement("path",{d:"M11 4H6.8c-1.68 0-2.52 0-3.162.327a3 3 0 0 0-1.311 1.311C2 6.28 2 7.12 2 8.8v8.4c0 1.68 0 2.52.327 3.162a3 3 0 0 0 1.311 1.311C4.28 22 5.12 22 6.8 22h8.4c1.68 0 2.52 0 3.162-.327a3 3 0 0 0 1.311-1.311C20 19.72 20 18.88 20 17.2V13M8 16h1.675c.489 0 .733 0 .963-.055.204-.05.4-.13.579-.24.201-.123.374-.296.72-.642L21.5 5.5a2.121 2.121 0 0 0-3-3l-9.563 9.563c-.346.346-.519.519-.642.72a2 2 0 0 0-.24.579c-.055.23-.055.474-.055.963V16Z"}));xe.displayName="Edit05";const Q=({size:s=24,color:e="currentColor",...n})=>C.createElement("svg",{viewBox:"0 0 24 24",width:s,height:s,stroke:e,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...n},C.createElement("path",{d:"M16 3.468a4.5 4.5 0 0 1 0 8.064m2 5.234c1.512.684 2.872 1.799 4 3.234M2 20c1.946-2.477 4.59-4 7.5-4s5.553 1.523 7.5 4M14 7.5a4.5 4.5 0 1 1-9 0 4.5 4.5 0 0 1 9 0Z"}));Q.displayName="Users02";function Ze(s){const e=A.c(20),{form:n}=s;let r;e[0]!==n?(r=v=>{const{field:p}=v;return t.jsx(nt,{size:"md",value:p.value,onChange:p.onChange,alt:n.watch("title")})},e[0]=n,e[1]=r):r=e[1];let o;e[2]!==n.control||e[3]!==r?(o=t.jsx(V,{control:n.control,name:"avatar",render:r}),e[2]=n.control,e[3]=r,e[4]=o):o=e[4];let l;e[5]!==n.control?(l=t.jsxs("div",{className:"flex flex-col gap-3 flex-1 min-w-0",children:[t.jsx(V,{control:n.control,name:"title",render:tt}),t.jsx(V,{control:n.control,name:"description",render:et})]}),e[5]=n.control,e[6]=l):l=e[6];let a;e[7]!==o||e[8]!==l?(a=t.jsxs("div",{className:"flex gap-4 items-start",children:[o,l]}),e[7]=o,e[8]=l,e[9]=a):a=e[9];let i,d;e[10]!==n.control?(i=t.jsxs("div",{className:"flex gap-4",children:[t.jsx(V,{control:n.control,name:"gateway_id",render:Xe}),t.jsx(V,{control:n.control,name:"model",render:Qe})]}),d=t.jsx(V,{control:n.control,name:"system_prompt",render:Ye}),e[10]=n.control,e[11]=i,e[12]=d):(i=e[11],d=e[12]);let m;e[13]!==a||e[14]!==i||e[15]!==d?(m=t.jsxs("div",{className:"h-full py-6 flex flex-col max-w-2xl mx-auto w-full min-w-0 gap-6 overflow-y-auto",children:[a,i,d]}),e[13]=a,e[14]=i,e[15]=d,e[16]=m):m=e[16];let h;return e[17]!==n||e[18]!==m?(h=t.jsx(ze,{...n,children:m}),e[17]=n,e[18]=m,e[19]=h):h=e[19],h}function Ye(s){const{field:e}=s;return t.jsxs(Z,{className:"flex-1 flex flex-col min-h-0",children:[t.jsx(Y,{className:"text-xs text-muted-foreground",children:"System prompt"}),t.jsx(oe,{children:t.jsx(ee,{...e,placeholder:"You are a helpful assistant...",className:"flex-1 min-h-[200px] resize-none text-base leading-relaxed font-normal rounded-xl border border-border bg-muted/20 px-4 py-3 shadow-none focus-visible:ring-0"})})]})}function Qe(s){const{field:e}=s;return t.jsxs(Z,{className:"flex-1",children:[t.jsx(Y,{className:"text-xs text-muted-foreground",children:"Model"}),t.jsx(Ce,{selectedModel:e.value?{id:e.value.id,connectionId:e.value.connectionId}:void 0,onModelChange:n=>e.onChange({id:n.id,connectionId:n.connectionId}),placeholder:"Select model",variant:"bordered",className:"w-full"})]})}function Xe(s){const{field:e}=s;return t.jsxs(Z,{className:"flex-1",children:[t.jsx(Y,{className:"text-xs text-muted-foreground",children:"Gateway"}),t.jsx(Se,{selectedGatewayId:e.value,onGatewayChange:e.onChange,placeholder:"Select gateway",variant:"bordered",className:"w-full"})]})}function et(s){const{field:e}=s;return t.jsxs(Z,{children:[t.jsx(Y,{className:"text-xs text-muted-foreground",children:"Description"}),t.jsx(oe,{children:t.jsx(re,{...e,value:e.value??"",placeholder:"Add a description…",className:"h-9 rounded-lg border border-border bg-muted/20 shadow-none focus-visible:ring-0"})})]})}function tt(s){const{field:e}=s;return t.jsxs(Z,{children:[t.jsx(Y,{className:"text-xs text-muted-foreground",children:"Name"}),t.jsx(oe,{children:t.jsx(re,{...e,placeholder:"Untitled assistant",className:"h-9 rounded-lg border border-border bg-muted/20 shadow-none focus-visible:ring-0"})})]})}function st(s){const e=A.c(53),{activeThreadId:n,mode:r,assistant:o,form:l}=s;let a;e[0]!==n||e[1]!==o.system_prompt?(a={threadId:n,systemPrompt:o.system_prompt},e[0]=n,e[1]=o.system_prompt,e[2]=a):a=e[2];const i=we(a),d=!!o.gateway_id&&!!o.model?.id&&!!o.model?.connectionId;let m;e[3]!==n||e[4]!==o.gateway_id||e[5]!==o.model||e[6]!==i||e[7]!==d?(m=async O=>{if(!d)return;const B={created_at:new Date().toISOString(),thread_id:n,model:{id:o.model.id,connectionId:o.model.connectionId},gateway:{id:o.gateway_id??""},user:{name:"you"}};await i.sendMessage(O,B)},e[3]=n,e[4]=o.gateway_id,e[5]=o.model,e[6]=i,e[7]=d,e[8]=m):m=e[8];const h=m;let v;e[9]!==o.avatar||e[10]!==o.title?(v=o.avatar?t.jsx("div",{className:"size-[60px] rounded-[18px] border border-border shrink-0 overflow-hidden",children:t.jsx("img",{src:o.avatar,alt:o.title,className:"h-full w-full object-cover"})}):t.jsx("div",{className:"size-[60px] rounded-[18px] border border-border shrink-0 overflow-hidden bg-muted/20 flex items-center justify-center",children:t.jsx(Q,{size:28,className:"text-muted-foreground"})}),e[9]=o.avatar,e[10]=o.title,e[11]=v):v=e[11];let p;e[12]!==o.title?(p=t.jsx("h3",{className:"text-xl font-medium text-foreground",children:o.title}),e[12]=o.title,e[13]=p):p=e[13];let y;e[14]!==o.description?(y=o.description?t.jsx("div",{className:"text-muted-foreground text-center text-sm max-w-md",children:o.description}):null,e[14]=o.description,e[15]=y):y=e[15];let _;e[16]!==v||e[17]!==p||e[18]!==y?(_=t.jsxs("div",{className:"flex flex-col items-center justify-center gap-4 p-8 text-center",children:[v,p,y]}),e[16]=v,e[17]=p,e[18]=y,e[19]=_):_=e[19];const u=_,k=r==="edit",g=k?"opacity-100 pointer-events-auto":"opacity-0 pointer-events-none";let b;e[20]!==g?(b=W("absolute inset-0 px-2 transition-opacity duration-200 ease-out",g),e[20]=g,e[21]=b):b=e[21];let w;e[22]!==l?(w=t.jsx(Ze,{form:l}),e[22]=l,e[23]=w):w=e[23];let f;e[24]!==b||e[25]!==w?(f=t.jsx("div",{className:b,children:w}),e[24]=b,e[25]=w,e[26]=f):f=e[26];const N=k?"opacity-0 pointer-events-none":"opacity-100";let E;e[27]!==N?(E=W("h-full transition-opacity duration-200 ease-out",N),e[27]=N,e[28]=E):E=e[28];let S;e[29]!==i.messages||e[30]!==i.status||e[31]!==u?(S=i.messages.length===0?t.jsx(J.EmptyState,{children:u}):t.jsx(J.Messages,{messages:i.messages,status:i.status,minHeightOffset:240}),e[29]=i.messages,e[30]=i.status,e[31]=u,e[32]=S):S=e[32];let I;e[33]!==E||e[34]!==S?(I=t.jsx("div",{className:E,children:S}),e[33]=E,e[34]=S,e[35]=I):I=e[35];let $;e[36]!==f||e[37]!==I?($=t.jsxs(J.Main,{className:"h-full relative overflow-hidden",innerClassName:"px-2",children:[f,I]}),e[36]=f,e[37]=I,e[38]=$):$=e[38];const L=k?"translate-y-full":"translate-y-0";let T;e[39]!==L?(T=W("transition-transform duration-300 ease-out",L),e[39]=L,e[40]=T):T=e[40];const z=!d,M=i.status==="submitted"||i.status==="streaming";let c;e[41]!==i.messages||e[42]!==i.stop||e[43]!==h||e[44]!==z||e[45]!==M?(c=t.jsx(J.Footer,{children:t.jsx("div",{className:"max-w-2xl mx-auto w-full min-w-0",children:t.jsx(J.Input,{onSubmit:h,onStop:i.stop,disabled:z,isStreaming:M,placeholder:"Ask anything or @ for context",usageMessages:i.messages})})}),e[41]=i.messages,e[42]=i.stop,e[43]=h,e[44]=z,e[45]=M,e[46]=c):c=e[46];let j;e[47]!==T||e[48]!==c?(j=t.jsx("div",{className:T,children:c}),e[47]=T,e[48]=c,e[49]=j):j=e[49];let x;return e[50]!==$||e[51]!==j?(x=t.jsxs(J,{children:[$,j]}),e[50]=$,e[51]=j,e[52]=x):x=e[52],x}function nt(s){const e=A.c(18),{value:n,onChange:r,alt:o,size:l}=s,a=l===void 0?"md":l,i=C.useRef(null),d=a==="xs"?"h-6 w-6":a==="sm"?"h-8 w-8":"h-16 w-16",m=a==="xs"?"h-3 w-3":a==="sm"?"h-4 w-4":"h-6 w-6",h=a==="xs"?"h-3 w-3":a==="sm"?"h-3.5 w-3.5":"h-5 w-5";let v;e[0]!==r?(v=E=>{const S=E.target.files?.[0];if(!S)return;const I=new FileReader;I.onloadend=()=>{const $=I.result;r($)},I.readAsDataURL(S)},e[0]=r,e[1]=v):v=e[1];const p=v;let y;e[2]===Symbol.for("react.memo_cache_sentinel")?(y=()=>{i.current?.click()},e[2]=y):y=e[2];const _=y,u=`relative ${d} shrink-0 cursor-pointer group`;let k;e[3]!==p?(k=t.jsx("input",{type:"file",ref:i,className:"hidden",accept:"image/*",onChange:p}),e[3]=p,e[4]=k):k=e[4];let g;e[5]!==o||e[6]!==m||e[7]!==n?(g=n?t.jsx("img",{src:n,alt:o||"Avatar",className:"w-full h-full object-cover"}):t.jsx("div",{className:"w-full h-full flex items-center justify-center text-muted-foreground",children:t.jsx(Q,{className:m})}),e[5]=o,e[6]=m,e[7]=n,e[8]=g):g=e[8];const b=`${h} text-white`;let w;e[9]!==b?(w=t.jsx("div",{className:"absolute inset-0 bg-black/50 opacity-0 group-hover:opacity-100 transition-opacity flex items-center justify-center rounded-xl",children:t.jsx(Le,{className:b})}),e[9]=b,e[10]=w):w=e[10];let f;e[11]!==g||e[12]!==w?(f=t.jsxs("div",{className:"h-full w-full rounded-xl border border-border bg-muted/20 overflow-hidden relative",children:[g,w]}),e[11]=g,e[12]=w,e[13]=f):f=e[13];let N;return e[14]!==u||e[15]!==k||e[16]!==f?(N=t.jsxs("div",{className:u,onClick:_,children:[k,f]}),e[14]=u,e[15]=k,e[16]=f,e[17]=N):N=e[17],N}function ot(s){const e=A.c(49),{providerId:n,assistantId:r,onBack:o}=s,l=se();let a;e[0]!==o||e[1]!==l?(a=o??(()=>l.history.back()),e[0]=o,e[1]=l,e[2]=a):a=e[2];const i=a,{locator:d}=_e();let m;e[3]!==r||e[4]!==d?(m=Ie.assistantChatActiveThread(d,r),e[3]=r,e[4]=d,e[5]=m):m=e[5];const[h,v]=ke(m,rt),p=n||q;let y;e[6]!==p?(y=ne(p),e[6]=p,e[7]=y):y=e[7];const _=y,u=be(n,"ASSISTANT",r,_),k=le(n,"ASSISTANT",_),g=k.update.isPending,[b,w]=C.useState(u?.model.id&&u?.gateway_id?"chat":"edit");let f;e[8]===Symbol.for("react.memo_cache_sentinel")?(f=he(Oe),e[8]=f):f=e[8];const N=u??void 0;let E;e[9]!==N?(E={resolver:f,values:N},e[9]=N,e[10]=E):E=e[10];const S=pe(E);let I;e[11]!==k.update||e[12]!==r||e[13]!==S?(I=S.handleSubmit(async R=>{const D=await k.update.mutateAsync({id:r,data:R});S.reset(D),w("chat")}),e[11]=k.update,e[12]=r,e[13]=S,e[14]=I):I=e[14];const $=I;if(!u){let R;e[15]===Symbol.for("react.memo_cache_sentinel")?(R=t.jsx(ae,{}),e[15]=R):R=e[15];let D;e[16]===Symbol.for("react.memo_cache_sentinel")?(D=t.jsx("div",{className:"flex h-full w-full bg-background",children:t.jsx(ce,{title:"Assistant not found",description:"This assistant may have been deleted or you may not have access to it."})}),e[16]=D):D=e[16];let F;return e[17]!==i?(F=t.jsx(X,{children:t.jsx(C.Suspense,{fallback:R,children:t.jsx(te,{onBack:i,children:D})})}),e[17]=i,e[18]=F):F=e[18],F}let L;e[19]===Symbol.for("react.memo_cache_sentinel")?(L=t.jsx(ae,{}),e[19]=L):L=e[19];let T;e[20]!==u.avatar||e[21]!==u.title?(T=t.jsx("div",{className:"h-6 w-6 min-w-6 rounded-lg border border-border bg-muted/20 overflow-hidden shrink-0",children:u.avatar?t.jsx("img",{src:u.avatar,alt:u.title,className:"h-full w-full object-cover"}):t.jsx("div",{className:"h-full w-full flex items-center justify-center text-muted-foreground",children:t.jsx(Q,{size:12,className:"text-muted-foreground"})})}),e[20]=u.avatar,e[21]=u.title,e[22]=T):T=e[22];let z;e[23]!==u.title?(z=t.jsx("span",{className:"text-sm font-medium text-foreground truncate",children:u.title}),e[23]=u.title,e[24]=z):z=e[24];let M;e[25]!==u.description?(M=u.description?t.jsxs(t.Fragment,{children:[t.jsx("span",{className:"text-xs text-muted-foreground font-normal",children:"•"}),t.jsx("span",{className:"text-xs text-muted-foreground font-normal truncate min-w-0 max-w-[20ch]",children:u.description})]}):null,e[25]=u.description,e[26]=M):M=e[26];let c;e[27]!==z||e[28]!==M?(c=t.jsxs("div",{className:"flex items-center gap-2 min-w-0",children:[z,M]}),e[27]=z,e[28]=M,e[29]=c):c=e[29];let j;e[30]!==T||e[31]!==c?(j=t.jsx(Be,{children:t.jsxs("div",{className:"flex items-center gap-3 min-w-0",children:[T,c]})}),e[30]=T,e[31]=c,e[32]=j):j=e[32];let x;e[33]!==S.formState.isDirty||e[34]!==g||e[35]!==b||e[36]!==$||e[37]!==v?(x=t.jsx(de,{children:b==="chat"?t.jsxs(t.Fragment,{children:[t.jsx("button",{type:"button",onClick:()=>v(crypto.randomUUID()),title:"New thread",className:"flex size-6 items-center justify-center rounded-full p-1 hover:bg-transparent group cursor-pointer",children:t.jsx(Me,{size:16,className:"text-muted-foreground group-hover:text-foreground transition-colors"})}),t.jsx("button",{type:"button",onClick:()=>w("edit"),title:"Edit",className:"flex size-6 items-center justify-center rounded-full p-1 hover:bg-transparent group cursor-pointer",children:t.jsx(xe,{size:16,className:"text-muted-foreground group-hover:text-foreground transition-colors"})})]}):t.jsxs(t.Fragment,{children:[t.jsx(G,{variant:"ghost",size:"sm",className:"h-7 gap-1.5",disabled:g,onClick:()=>w("chat"),children:"Cancel"}),t.jsx(G,{variant:"default",size:"sm",className:"h-7 gap-1.5",disabled:!S.formState.isDirty||g,onClick:()=>{$()},children:g?t.jsxs(t.Fragment,{children:[t.jsx(H,{size:14,className:"animate-spin"}),"Saving..."]}):"Save"})]})}),e[33]=S.formState.isDirty,e[34]=g,e[35]=b,e[36]=$,e[37]=v,e[38]=x):x=e[38];let O;e[39]!==h||e[40]!==u||e[41]!==S||e[42]!==b?(O=t.jsx("div",{className:"h-full",children:t.jsx(st,{activeThreadId:h,mode:b,assistant:u,form:S},S.formState.submitCount)}),e[39]=h,e[40]=u,e[41]=S,e[42]=b,e[43]=O):O=e[43];let B;return e[44]!==i||e[45]!==j||e[46]!==x||e[47]!==O?(B=t.jsx(X,{children:t.jsx(C.Suspense,{fallback:L,children:t.jsxs(te,{onBack:i,children:[j,x,O]})})}),e[44]=i,e[45]=j,e[46]=x,e[47]=O,e[48]=B):B=e[48],B}function rt(s){return s||crypto.randomUUID()}function at(s){const e=A.c(6),{itemId:n,onBack:r}=s;let o;e[0]===Symbol.for("react.memo_cache_sentinel")?(o={strict:!1},e[0]=o):o=e[0];const a=K(o).connectionId??q;if(!a||a===q){let d;return e[1]===Symbol.for("react.memo_cache_sentinel")?(d=t.jsx("div",{className:"flex h-full w-full bg-background",children:t.jsx(ce,{title:"Assistant not found",description:"Missing connection information in the current route."})}),e[1]=d):d=e[1],d}let i;return e[2]!==a||e[3]!==n||e[4]!==r?(i=t.jsx(ot,{providerId:a,assistantId:n,onBack:r}),e[2]=a,e[3]=n,e[4]=r,e[5]=i):i=e[5],i}const lt=ge("relative w-full rounded-lg border px-4 py-3 text-sm flex items-start gap-3 [&>svg]:size-4 [&>svg]:flex-shrink-0 [&>svg]:mt-0.5 [&>svg]:text-current",{variants:{variant:{default:"bg-card text-card-foreground",destructive:"bg-destructive/5 text-destructive border-destructive/25 [&>svg]:text-current *:data-[slot=alert-description]:text-destructive/90",warning:"bg-warning/10 text-warning-foreground border-warning [&>svg]:text-current *:data-[slot=alert-description]:text-warning-foreground/90",success:"bg-success/10 text-success-foreground border-success [&>svg]:text-current *:data-[slot=alert-description]:text-success-foreground/90",info:"bg-card text-card-foreground border-border [&>svg]:text-current *:data-[slot=alert-description]:text-muted-foreground/90"}},defaultVariants:{variant:"default"}});function it(s){const e=A.c(10);let n,r,o;e[0]!==s?({className:n,variant:o,...r}=s,e[0]=s,e[1]=n,e[2]=r,e[3]=o):(n=e[1],r=e[2],o=e[3]);let l;e[4]!==n||e[5]!==o?(l=W(lt({variant:o}),n),e[4]=n,e[5]=o,e[6]=l):l=e[6];let a;return e[7]!==r||e[8]!==l?(a=t.jsx("div",{"data-slot":"alert",role:"alert",className:l,...r}),e[7]=r,e[8]=l,e[9]=a):a=e[9],a}function ct(s){const e=A.c(8);let n,r;e[0]!==s?({className:n,...r}=s,e[0]=s,e[1]=n,e[2]=r):(n=e[1],r=e[2]);let o;e[3]!==n?(o=W("line-clamp-1 min-h-4 font-medium tracking-tight",n),e[3]=n,e[4]=o):o=e[4];let l;return e[5]!==r||e[6]!==o?(l=t.jsx("div",{"data-slot":"alert-title",className:o,...r}),e[5]=r,e[6]=o,e[7]=l):l=e[7],l}function dt(s){const e=A.c(8);let n,r;e[0]!==s?({className:n,...r}=s,e[0]=s,e[1]=n,e[2]=r):(n=e[1],r=e[2]);let o;e[3]!==n?(o=W("text-muted-foreground leading-relaxed",n),e[3]=n,e[4]=o):o=e[4];let l;return e[5]!==r||e[6]!==o?(l=t.jsx("div",{"data-slot":"alert-description",className:o,...r}),e[5]=r,e[6]=o,e[7]=l):l=e[7],l}const mt=s=>s.replace(/_/g," ").replace(/\b\w/g,e=>e.toLocaleLowerCase());function ut(s){const e=A.c(13),{toolName:n,connectionId:r,onBack:o}=s,l=`/mcp/${r}`;let a;e[0]!==l?(a=new URL(l,window.location.origin),e[0]=l,e[1]=a):a=e[1];const i=a;let d;e[2]!==r?(d={connectionId:r},e[2]=r,e[3]=d):d=e[3];const m=Ve(d);if(!m.isAuthenticated){let p;return e[4]!==m.supportsOAuth||e[5]!==o?(p=t.jsx("div",{className:"flex h-full items-center justify-center",children:m.supportsOAuth?t.jsx(We,{onAuthenticate:()=>o(),buttonText:"Go back to authenticate"}):t.jsx(Ge,{hasReadme:!1})}),e[4]=m.supportsOAuth,e[5]=o,e[6]=p):p=e[6],p}const h=`${r}:${n}`;let v;return e[7]!==r||e[8]!==i||e[9]!==o||e[10]!==h||e[11]!==n?(v=t.jsx(ft,{toolName:n,connectionId:r,mcpProxyUrl:i,onBack:o},h),e[7]=r,e[8]=i,e[9]=o,e[10]=h,e[11]=n,e[12]=v):v=e[12],v}function ft({toolName:s,connectionId:e,mcpProxyUrl:n,onBack:r}){const{replayId:o}=je({strict:!1}),l=(()=>{if(!o)return null;const c=`replay-${o}`,j=sessionStorage.getItem(c);if(!j)return null;sessionStorage.removeItem(c);try{return JSON.parse(j)}catch{return null}})(),a=(()=>{if(!l)return null;const c={};for(const[j,x]of Object.entries(l))x!==null&&typeof x=="object"?c[j]=JSON.stringify(x,null,2):c[j]=x;return c})(),[i,d]=C.useState(a??{}),[m,h]=C.useState(l?JSON.stringify(l,null,2):"{}"),[v,p]=C.useState(null),[y,_]=C.useState(null),[u,k]=C.useState(!1),[g,b]=C.useState(null),w=ie(e),f=Ke({url:n.href});C.useEffect(()=>{f.error&&console.error("MCP Error:",f.error)},[f.error]);const N=f.tools?.find(c=>c.name===s),E=N?.inputSchema?.properties,S=E?Object.keys(E):[],I=S.length>0,$={};if(I&&N?.inputSchema?.properties)for(const c of S)$[c]=N.inputSchema.required?.includes(c)?"":void 0;const L=c=>Object.prototype.hasOwnProperty.call(i,c),T=async()=>{k(!0),_(null),p(null),b(null);const c=performance.now(),j=ne(e);try{const x=I?{...$,...i}:(()=>{const P=m.trim();if(!P)return{};const U=JSON.parse(P);if(U&&typeof U=="object")return U;throw new Error("Raw JSON input must be an object.")})();I&&N?.inputSchema?.properties&&Object.entries(N.inputSchema.properties).forEach(([P,U])=>{if((U.type==="object"||U.type==="array")&&typeof x[P]=="string")try{x[P]=JSON.parse(x[P])}catch{}});const O=await j(s,x),B=performance.now(),R=Math.round(B-c);p(O);const D=JSON.stringify(O),F=new TextEncoder().encode(D).length;b({duration:`${R}ms`,bytes:`${F} bytes`,tokens:`~${Math.ceil(F/4)} tokens`,cost:"$0.0000"})}catch(x){const O=x instanceof Error?x.message:String(x);_(O||"Unknown error occurred");const B=performance.now();b({duration:`${Math.round(B-c)}ms`})}finally{k(!1)}},z=(c,j)=>{d(x=>({...x,[c]:j}))},M=()=>{p(null),_(null),b(null)};return t.jsxs(te,{onBack:r,children:[t.jsx(de,{children:t.jsx(qe,{connectionId:e,title:N?.name??mt(s),icon:"build"})}),t.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-2 h-full",children:[t.jsx("div",{className:"flex flex-col border-r border-border overflow-hidden",children:t.jsxs("div",{className:"flex-1 overflow-auto",children:[t.jsx("div",{className:"flex flex-col gap-4 p-6 border-b border-border min-h-28",children:t.jsxs("div",{className:"flex flex-col gap-2",children:[t.jsxs("div",{className:"flex items-center gap-3",children:[t.jsx(Ne,{icon:w?.icon||null,name:w?.title||s,size:"sm",className:"shadow-sm shrink-0"}),t.jsx("h1",{className:"text-lg font-medium text-foreground leading-none",children:s}),t.jsxs("div",{className:"flex items-center gap-2 px-2.5 py-1 bg-muted/50 rounded-md h-fit",children:[f.state==="ready"?t.jsx("div",{className:"h-1.5 w-1.5 rounded-full bg-green-500 animate-pulse shrink-0"}):f.state==="connecting"?t.jsx(H,{size:10,className:"animate-spin text-yellow-500 shrink-0"}):t.jsx("div",{className:"h-1.5 w-1.5 rounded-full bg-red-500 shrink-0"}),t.jsx("span",{className:"font-mono text-xs capitalize text-muted-foreground leading-none",children:f.state.replace("_"," ")})]})]}),t.jsx("p",{className:"text-sm text-muted-foreground leading-relaxed",children:N?.description||"No description available"})]})}),t.jsxs("div",{className:"flex flex-col p-6 gap-4",children:[t.jsxs("div",{className:"flex items-center justify-between",children:[t.jsx("h2",{className:"text-sm font-semibold text-foreground uppercase tracking-wide",children:"Parameters"}),N?.inputSchema?.required&&N.inputSchema.required.length>0&&t.jsxs("span",{className:"text-xs text-muted-foreground",children:[t.jsx("span",{className:"text-red-500",children:"*"})," Required"]})]}),t.jsx("div",{className:"space-y-4",children:I&&N?.inputSchema?.properties?Object.entries(N.inputSchema.properties).map(([c,j])=>t.jsxs("div",{className:"space-y-2",children:[t.jsxs("div",{className:"flex items-center justify-between",children:[t.jsxs("label",{className:"text-sm font-medium leading-none flex items-center gap-1.5",children:[c,N.inputSchema?.required?.includes(c)&&t.jsx("span",{className:"text-red-500 text-xs",children:"*"})]}),t.jsx("span",{className:"text-xs text-muted-foreground font-mono",children:j.type})]}),j.description&&t.jsx("p",{className:"text-xs text-muted-foreground leading-relaxed",children:j.description}),j.type==="object"||j.type==="array"?t.jsx(ee,{className:"font-mono text-xs",value:L(c)?i[c]??"":$[c]??"",onChange:x=>z(c,x.target.value),placeholder:`Enter ${c} as JSON...`,rows:3}):t.jsx(re,{value:L(c)?i[c]??"":$[c]??"",onChange:x=>z(c,x.target.value),placeholder:`Enter ${c}...`})]},c)):N?.inputSchema&&!I?t.jsxs("div",{className:"space-y-2",children:[t.jsx("label",{className:"text-sm font-medium",children:"Raw JSON Input"}),t.jsx(ee,{className:"font-mono text-xs min-h-[120px]",value:m,onChange:c=>h(c.target.value),placeholder:'e.g. { "foo": "bar" }'})]}):t.jsx("div",{className:"flex items-center justify-center p-8 bg-muted/30 rounded-lg border border-dashed border-border",children:t.jsx("p",{className:"text-sm text-muted-foreground",children:"No parameters required"})})})]})]})}),t.jsxs("div",{className:"flex flex-col h-full overflow-hidden",children:[t.jsxs("div",{className:"flex items-center justify-between px-4 h-14 border-t lg:border-t-0 border-b border-border bg-background",children:[t.jsx("h2",{className:"text-sm font-medium text-foreground uppercase tracking-wide",children:"Result"}),g&&t.jsxs("div",{className:"flex items-center gap-3 text-xs",children:[t.jsxs("div",{className:"flex items-center gap-1.5",children:[t.jsx(De,{className:"h-3 w-3 text-muted-foreground"}),t.jsx("span",{className:"font-mono text-foreground",children:g.duration})]}),g.tokens&&t.jsxs("div",{className:"flex items-center gap-1.5",children:[t.jsx(me,{className:"h-3 w-3 text-muted-foreground"}),t.jsx("span",{className:"font-mono text-foreground",children:g.tokens})]}),g.bytes&&t.jsxs("div",{className:"flex items-center gap-1.5",children:[t.jsx(fe,{className:"h-3 w-3 text-muted-foreground"}),t.jsx("span",{className:"font-mono text-foreground",children:g.bytes})]}),g.cost&&t.jsx("div",{className:"flex items-center gap-1.5",children:t.jsx("span",{className:"font-mono text-foreground",children:g.cost})})]})]}),t.jsx("div",{className:"flex items-center justify-end lg:justify-between px-4 h-14 border-b border-border bg-background",children:t.jsxs("div",{className:"flex items-center gap-2 w-full lg:w-auto",children:[t.jsx(G,{size:"sm",variant:"default",className:"h-8 gap-2 flex-1 lg:flex-none",onClick:T,disabled:u,children:u?t.jsxs(t.Fragment,{children:[t.jsx(H,{size:14,className:"animate-spin"}),"Executing..."]}):t.jsxs(t.Fragment,{children:[t.jsx(Pe,{className:"h-3.5 w-3.5 fill-current"}),"Execute Tool"]})}),t.jsx($e,{children:t.jsxs(Ee,{children:[t.jsx(Te,{asChild:!0,children:t.jsx(G,{size:"icon",variant:"outline",className:"h-8 w-8 shrink-0",onClick:M,disabled:!v&&!y,children:t.jsx(Je,{size:14})})}),t.jsx(Ae,{children:t.jsx("p",{children:"Clear results"})})]})})]})}),y&&t.jsx("div",{className:"px-6 py-4 bg-background",children:t.jsx(it,{variant:"destructive",children:t.jsxs("div",{className:"flex flex-col gap-2",children:[t.jsxs("div",{className:"flex items-center gap-2",children:[t.jsx(Re,{className:"h-4 w-4"}),t.jsx(ct,{className:"mb-0",children:"Execution Failed"})]}),t.jsx(dt,{className:"text-xs text-destructive",children:y})]})})}),t.jsx("div",{className:"relative flex-1 overflow-auto bg-muted/50",children:v?t.jsxs(t.Fragment,{children:[t.jsx(Ue,{jsonString:JSON.stringify(v,null,2),padding:"1.5rem"}),t.jsx(G,{size:"icon",variant:"ghost",className:"absolute top-4 right-4 h-8 w-8 bg-background/80 hover:bg-background border border-border shadow-sm",onClick:()=>{navigator.clipboard.writeText(JSON.stringify(v,null,2)),ve.success("Copied to clipboard")},children:t.jsx(Fe,{className:"h-3.5 w-3.5"})})]}):t.jsxs("div",{className:"absolute inset-0 flex flex-col items-center justify-center text-muted-foreground",children:[t.jsx(ue,{className:"h-12 w-12 mb-3 opacity-40"}),t.jsx("p",{className:"text-sm",children:"Run the tool to see results"})]})})]})]})]})}function xt(s){const e=A.c(7),{itemId:n,onBack:r}=s;let o;e[0]===Symbol.for("react.memo_cache_sentinel")?(o={strict:!1},e[0]=o):o=e[0];const a=K(o).connectionId??q;if(!ie(a)){let h;return e[1]===Symbol.for("react.memo_cache_sentinel")?(h=t.jsx("div",{className:"flex h-full items-center justify-center",children:t.jsxs("div",{className:"flex flex-col items-center gap-2 text-center",children:[t.jsx("h3",{className:"text-lg font-semibold",children:"Connection not found"}),t.jsx("p",{className:"text-sm text-muted-foreground",children:"This connection may have been deleted or you may not have access."})]})}),e[1]=h):h=e[1],h}let d;e[2]===Symbol.for("react.memo_cache_sentinel")?(d=t.jsx("div",{className:"flex h-full items-center justify-center",children:t.jsx(H,{size:32,className:"animate-spin text-muted-foreground"})}),e[2]=d):d=e[2];let m;return e[3]!==a||e[4]!==r||e[5]!==n?(m=t.jsx(C.Suspense,{fallback:d,children:t.jsx(ut,{toolName:n,connectionId:a,onBack:r})}),e[3]=a,e[4]=r,e[5]=n,e[6]=m):m=e[6],m}const ht={assistant:at};function pt(){const s=A.c(6),e=se();let n;s[0]===Symbol.for("react.memo_cache_sentinel")?(n={from:"/shell/$org/mcps/$connectionId/$collectionName/$itemId"},s[0]=n):n=s[0];const r=K(n),o=decodeURIComponent(r.itemId);let l;s[1]!==e.history?(l=()=>{e.history.back()},s[1]=e.history,s[2]=l):l=s[2];const a=l,i=gt;let d;return s[3]!==a||s[4]!==o?(d=t.jsx(xt,{itemId:o,onBack:a,onUpdate:i}),s[3]=a,s[4]=o,s[5]=d):d=s[5],d}async function gt(s){return Promise.resolve()}function jt(){const s=A.c(18),e=se();let n;s[0]===Symbol.for("react.memo_cache_sentinel")?(n={from:"/shell/$org/mcps/$connectionId/$collectionName/$itemId"},s[0]=n):n=s[0];const r=K(n),o=r.connectionId,l=decodeURIComponent(r.collectionName),a=decodeURIComponent(r.itemId);let i;s[1]!==e.history?(i=()=>{e.history.back()},s[1]=e.history,s[2]=i):i=s[2];const d=i,m=o??q;let h;s[3]!==m?(h=ne(m),s[3]=m,s[4]=h):h=s[4];const p=le(m,l,h);let y;s[5]!==p||s[6]!==a?(y=async f=>{a&&await p.update.mutateAsync({id:a,data:f})},s[5]=p,s[6]=a,s[7]=y):y=s[7];const _=y;let u;s[8]!==l?(u=l?.toLowerCase(),s[8]=l,s[9]=u):u=s[9];const k=u,g=k&&ht[k];if(g){let f;return s[10]!==g||s[11]!==d||s[12]!==_||s[13]!==a?(f=t.jsx(g,{itemId:a,onBack:d,onUpdate:_}),s[10]=g,s[11]=d,s[12]=_,s[13]=a,s[14]=f):f=s[14],f}let b;s[15]===Symbol.for("react.memo_cache_sentinel")?(b=t.jsx(ye,{size:36,className:"text-muted-foreground"}),s[15]=b):b=s[15];let w;return s[16]!==d?(w=t.jsx(He,{icon:b,title:"No component defined",description:"No component for this collection was defined",buttonProps:{onClick:d,children:"Go back"}}),s[16]=d,s[17]=w):w=s[17],w}function vt(){const s=A.c(3);let e;s[0]===Symbol.for("react.memo_cache_sentinel")?(e={from:"/shell/$org/mcps/$connectionId/$collectionName/$itemId"},s[0]=e):e=s[0];const n=K(e);if(decodeURIComponent(n.collectionName)==="tools"){let a;return s[1]===Symbol.for("react.memo_cache_sentinel")?(a=t.jsx(pt,{}),s[1]=a):a=s[1],a}let l;return s[2]===Symbol.for("react.memo_cache_sentinel")?(l=t.jsx(jt,{}),s[2]=l):l=s[2],l}function ps(){const s=A.c(1);let e;return s[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsx(X,{children:t.jsx(C.Suspense,{fallback:t.jsx("div",{className:"flex h-full items-center justify-center",children:t.jsx(H,{size:32,className:"animate-spin text-muted-foreground"})}),children:t.jsx(vt,{})})}),s[0]=e):e=s[0],e}export{ps as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{r as ie,c as L,j as t,f as Ee,a as lt,t as rt,d as at,b as ct,av as dt}from"./index-BXYAUeFB.js";import{E as Oe}from"./SearchMd-D-BfTFbd.js";import{E as Ue}from"./error-boundary-Bstevc3G.js";import{I as Ke,b as We,d as mt,e as ut,c as ft,a as pt}from"./use-connection-DcTy916p.js";import{b as ht}from"./use-binding-BgnJVxG_.js";import{E as Ve,P as xt,u as gt,S as jt}from"./index-1pyJ2pUa.js";import{B as xe}from"./button-WiHHb1ae.js";import{i as qe}from"./Loading01-BWm5a2UX.js";import{a as bt,T as Ct,R as vt}from"./resource-tabs-BwUWNlYE.js";import{V as yt,a as wt,b as Nt}from"./layout-BDLGK1gR.js";import{g as Be}from"./generate-id-Dyweu44Y.js";import{C as Ge}from"./collection-display-button-C_wVSNLi.js";import{C as St}from"./collection-search-ByjFbpzN.js";import{C as _t}from"./card-BCizSi8r.js";import{b as He,D as Je,a as Ze,c as V}from"./dropdown-menu-24ciec9y.js";import{a as Qe}from"./Copy01-Bilz-YTB.js";import{i as Xe}from"./DotsVertical-Bpn8NPVg.js";import{s as Ye,u as It}from"./use-list-state-SFgQOu4M.js";import{s as et}from"./Trash01-QqFxB-ic.js";import{C as Tt}from"./collection-table-wrapper-PcMFmqtb.js";import{n as Re}from"./Inbox01-CoVSGBs_.js";import{B as At}from"./extract-connection-data-BDRFIBL1.js";import{A as Dt,g as $t,c as Pt,b as kt,d as Et,e as Ot,a as zt,f as Mt}from"./alert-dialog-BKLc86P2.js";import{s as Lt}from"./Plus-Slubr3Mn.js";import"./utils-D2m6QoGq.js";import"./tooltip-Dgdin-_i.js";import"./auth-g7Ue41hR.js";import"./mcp-oauth-O6gPUgdn.js";import"./use-organization-settings-CWarZMrC.js";import"./use-tool-call-BWqj0h3N.js";import"./File06-88jNCz1V.js";import"./Key01-CKDDrXuQ.js";import"./form-BrDOMpvk.js";import"./input-BElOouK2.js";import"./select-DuRyb06m.js";import"./ChevronDown-LB39JZIr.js";import"./use-gateway-I6Ko0Jgt.js";import"./Grid01-irgYf3_6.js";import"./CpuChip02-CHm038ee.js";import"./formatDistanceToNow-Ctx6mZEP.js";import"./registry-utils-ulDDT0d8.js";import"./index-RVsrtNt7.js";import"./index-C3HgpkDC.js";import"./schema-DxhaF6b0.js";import"./useQuery-C_tbj2zS.js";import"./badge-CuERIkGI.js";import"./ArrowLeft-B2kSl8Am.js";import"./use-mobile-_Q7J0JGT.js";const ze=({size:s=24,color:e="currentColor",...o})=>ie.createElement("svg",{viewBox:"0 0 24 24",width:s,height:s,stroke:e,strokeWidth:"2",fill:"none",strokeLinecap:"round",strokeLinejoin:"round","aria-hidden":"true",...o},ie.createElement("path",{d:"M2.876 18.116c.046-.414.069-.62.131-.814a2 2 0 0 1 .234-.485c.111-.17.259-.317.553-.61L17 3a2.828 2.828 0 1 1 4 4L7.794 20.206c-.294.294-.442.442-.611.553a2 2 0 0 1-.485.233c-.193.063-.4.086-.814.132L2.5 21.5l.376-3.384Z"}));ze.displayName="Edit01";function Vt(s,e){const o=s.properties||{};for(const n in o){const r=o[n];if(r&&r.type==="string"&&(r.format==="url"||r.format==="uri")&&e&&typeof e=="object"&&n in e&&e[n])return e[n]}const l=["image","img","avatar","icon","logo","thumbnail","cover"];for(const n of l)if(e&&typeof e=="object"&&n in e&&typeof e[n]=="string")return e[n]}function Bt(s){const e=L.c(25),{item:o,schema:l,actions:n}=s;let r;e[0]!==o||e[1]!==l?(r=Vt(l,o),e[0]=o,e[1]=l,e[2]=r):r=e[2];const d=r,f=o&&typeof o=="object"&&"description"in o&&typeof o.description=="string"?o.description:void 0;let C;e[3]!==n?(C=n&&Object.keys(n).length>0,e[3]=n,e[4]=C):C=e[4];const i=C;let c;e[5]!==d||e[6]!==o.title?(c=t.jsx(Ke,{icon:d,name:o.title,size:"md",className:"shrink-0 shadow-sm"}),e[5]=d,e[6]=o.title,e[7]=c):c=e[7];let j;e[8]!==o.title?(j=t.jsx("h3",{className:"text-base font-medium text-foreground truncate",children:o.title}),e[8]=o.title,e[9]=j):j=e[9];const m=f||"No description";let u;e[10]!==m?(u=t.jsx("p",{className:"text-base text-muted-foreground line-clamp-2",children:m}),e[10]=m,e[11]=u):u=e[11];let p;e[12]!==j||e[13]!==u?(p=t.jsxs("div",{className:"flex flex-col gap-0 flex-1",children:[j,u]}),e[12]=j,e[13]=u,e[14]=p):p=e[14];let g;e[15]!==c||e[16]!==p?(g=t.jsxs("div",{className:"flex flex-col gap-4 p-6 flex-1",children:[c,p]}),e[15]=c,e[16]=p,e[17]=g):g=e[17];let a;e[18]!==n||e[19]!==i||e[20]!==o?(a=i&&t.jsx("div",{className:"absolute top-6 right-6 opacity-0 group-hover:opacity-100 transition-opacity",onClick:Kt,onMouseDown:Ut,children:t.jsxs(He,{children:[t.jsx(Je,{asChild:!0,children:t.jsx(xe,{variant:"ghost",size:"icon",className:"h-8 w-8",onClick:Ft,children:t.jsx(Xe,{size:20})})}),t.jsxs(Ze,{align:"end",onClick:Rt,children:[n.open&&t.jsxs(V,{onClick:v=>{v.stopPropagation(),n.open?.(o)},children:[t.jsx(Ye,{size:16}),"Open"]}),n.edit&&t.jsxs(V,{onClick:v=>{v.stopPropagation(),n.edit?.(o)},children:[t.jsx(ze,{size:16}),"Edit"]}),n.duplicate&&t.jsxs(V,{onClick:v=>{v.stopPropagation(),n.duplicate?.(o)},children:[t.jsx(Qe,{size:16}),"Duplicate"]}),n.delete&&t.jsxs(V,{variant:"destructive",onClick:v=>{v.stopPropagation(),n.delete?.(o)},children:[t.jsx(et,{size:16}),"Delete"]})]})]})}),e[18]=n,e[19]=i,e[20]=o,e[21]=a):a=e[21];let T;return e[22]!==g||e[23]!==a?(T=t.jsxs(_t,{className:"cursor-pointer transition-colors h-full flex flex-col group relative",children:[g,a]}),e[22]=g,e[23]=a,e[24]=T):T=e[24],T}function Rt(s){return s.stopPropagation()}function Ft(s){return s.stopPropagation()}function Ut(s){return s.stopPropagation()}function Kt(s){return s.stopPropagation()}const Wt=["icon","avatar","logo"],Fe=["created_at","created_by","id"];function qt(s){return Object.keys(s).find(e=>Wt.includes(e.toLowerCase()))}function tt(s,e){return Object.keys(s.properties||{}).filter(o=>["id","created_at","updated_at","created_by","updated_by"].includes(o)?!1:e?e.includes(o):!0).map(o=>({id:o,label:o.charAt(0).toUpperCase()+o.slice(1).replace(/_/g," ")}))}function Gt(s){const e=L.c(32),{data:o,schema:l,viewMode:n,onViewModeChange:r,search:d,sortKey:f,sortDirection:C,onSort:i,actions:c,onItemClick:j,headerActions:m,emptyState:u,readOnly:p,columns:g,hideToolbar:a,sortableFields:T}=s,v=r===void 0?Xt:r,b=C===void 0?"asc":C,P=i===void 0?Qt:i;let w;e[0]!==c?(w=c===void 0?{}:c,e[0]=c,e[1]=w):w=e[1];const h=w,A=j===void 0?Zt:j,D=m===void 0?null:m,y=u===void 0?null:u,k=p===void 0?!1:p,_=g===void 0?void 0:g,E=a===void 0?!1:a,N=T===void 0?void 0:T;let z;e[2]!==_||e[3]!==l||e[4]!==N?(z=_?_.filter(Jt).filter(M=>!N||N.includes(M.id)).map(Ht):tt(l,N),e[2]=_,e[3]=l,e[4]=N,e[5]=z):z=e[5];const I=z;let S;e[6]!==D||e[7]!==E||e[8]!==P||e[9]!==v||e[10]!==b||e[11]!==f||e[12]!==I||e[13]!==n?(S=!E&&t.jsx("div",{className:"shrink-0 w-full border-b border-border h-12",children:t.jsxs("div",{className:"flex items-center gap-3 h-12 px-4",children:[t.jsx("div",{className:"flex items-center gap-2 flex-1",children:D}),t.jsx("div",{className:"flex items-center gap-2 shrink-0",children:t.jsx(Ge,{viewMode:n,onViewModeChange:v,sortKey:f,sortDirection:b,onSort:P,sortOptions:I})})]})}),e[6]=D,e[7]=E,e[8]=P,e[9]=v,e[10]=b,e[11]=f,e[12]=I,e[13]=n,e[14]=S):S=e[14];let O;e[15]!==h||e[16]!==_||e[17]!==o||e[18]!==y||e[19]!==A||e[20]!==P||e[21]!==k||e[22]!==l||e[23]!==d||e[24]!==b||e[25]!==f||e[26]!==N||e[27]!==n?(O=n==="cards"?t.jsx("div",{className:"flex-1 overflow-auto p-5",children:o.length===0?t.jsx("div",{className:"flex items-center justify-center h-full",children:y||t.jsx(Ve,{icon:t.jsx(Re,{size:36,className:"text-muted-foreground"}),title:"No items found",description:d?"Try adjusting your search":"No items to display"})}):t.jsx("div",{className:"grid grid-cols-1 md:grid-cols-3 lg:grid-cols-4 gap-4",children:o.map(M=>t.jsx("div",{onClick:()=>A?.(M),className:"cursor-pointer h-full",children:t.jsx(Bt,{item:M,schema:l,readOnly:k,actions:h})},M.id))})}):t.jsx(Tt,{columns:ts(_,l,N,h),data:o,sortKey:f,sortDirection:b,onSort:P,onRowClick:A,emptyState:y||t.jsx(Ve,{icon:t.jsx(Re,{size:36,className:"text-muted-foreground"}),title:"No items found",description:d?"Try adjusting your search":"No items to display"})}),e[15]=h,e[16]=_,e[17]=o,e[18]=y,e[19]=A,e[20]=P,e[21]=k,e[22]=l,e[23]=d,e[24]=b,e[25]=f,e[26]=N,e[27]=n,e[28]=O):O=e[28];let x;return e[29]!==S||e[30]!==O?(x=t.jsxs("div",{className:"h-full flex flex-col overflow-hidden",children:[S,O]}),e[29]=S,e[30]=O,e[31]=x):x=e[31],x}function Ht(s){return{id:s.id,label:typeof s.header=="string"?s.header:s.id}}function Jt(s){return s.sortable!==!1}function Zt(){}function Qt(){}function Xt(){}function Yt(s){return{id:"actions",header:"",render:e=>t.jsxs(He,{children:[t.jsx(Je,{asChild:!0,children:t.jsx(xe,{variant:"ghost",size:"sm",className:"h-8 w-8 p-0",onClick:o=>o.stopPropagation(),children:t.jsx(Xe,{size:20})})}),t.jsxs(Ze,{align:"end",onClick:o=>o.stopPropagation(),children:[s.open&&t.jsxs(V,{onClick:o=>{o.stopPropagation(),s.open?.(e)},children:[t.jsx(Ye,{size:16}),"Open"]}),s.edit&&t.jsxs(V,{onClick:o=>{o.stopPropagation(),s.edit?.(e)},children:[t.jsx(ze,{size:16}),"Edit"]}),s.duplicate&&t.jsxs(V,{onClick:o=>{o.stopPropagation(),s.duplicate?.(e)},children:[t.jsx(Qe,{size:16}),"Duplicate"]}),s.delete&&t.jsxs(V,{variant:"destructive",onClick:o=>{o.stopPropagation(),s.delete?.(e)},children:[t.jsx(et,{size:16}),"Delete"]})]})]}),cellClassName:"w-[60px]",sortable:!1}}function st(s){const e=s.type;return Array.isArray(e)?e.every(o=>st({type:o})):e==="string"||e==="number"||e==="integer"||e==="boolean"||e==="null"}function es(s,e){const o=s.properties||{},l=Object.keys(o).filter(i=>{const c=o[i];return c&&st(c)}),n=qt(o),r=[],d=new Set;n&&l.includes(n)&&(r.push(n),d.add(n));const f=["title","description","updated_at","updated_by"];for(const i of f)l.includes(i)&&!d.has(i)&&(r.push(i),d.add(i));const C=l.filter(i=>!d.has(i)&&!Fe.includes(i)).sort((i,c)=>i.localeCompare(c));for(const i of C)r.push(i),d.add(i);for(const i of Fe)l.includes(i)&&!d.has(i)&&(r.push(i),d.add(i));return r.map(i=>{const c=o[i],j=e?e.includes(i):!["id"].includes(i);return i===n?{id:i,header:"",render:m=>{const u=m[i];return t.jsx(Ke,{icon:u,name:m.title,size:"sm",className:"shrink-0 shadow-sm"})},sortable:!1,cellClassName:"w-16 shrink-0",wrap:!0}:i==="description"?{id:i,header:"Description",render:m=>{const u=m[i];return u==null?"—":t.jsx("span",{className:"block truncate max-w-[50ch]",children:String(u)})},sortable:j,cellClassName:"max-w-[50ch]"}:c?.format==="date-time"||i.endsWith("_at")?{id:i,header:i.charAt(0).toUpperCase()+i.slice(1).replace(/_/g," "),render:m=>{const u=m[i];return u?t.jsx("span",{className:"block truncate max-w-full",children:new Date(u).toLocaleDateString()}):"—"},sortable:j,cellClassName:"max-w-[200px]"}:{id:i,header:i.charAt(0).toUpperCase()+i.slice(1).replace(/_/g," "),render:m=>{const u=m[i];return u==null?"—":t.jsx("span",{className:"block truncate max-w-full",children:String(u)})},sortable:j,cellClassName:"max-w-[200px]"}})}function ts(s,e,o,l){const n=s||es(e,o);return n.some(f=>f.id==="actions")?n:Object.keys(l).length>0?[...n,Yt(l)]:n}function ss(s){const e=L.c(117),{connectionId:o,org:l,activeCollection:n}=s,r=n.name,d=n.schema??At,f=n.hasCreateTool,C=n.hasUpdateTool,i=n.hasDeleteTool,c=Ee(),{data:j}=lt.useSession(),m=j?.user?.id||"unknown",u=We(o);let p;e[0]!==o?(p=ft(o),e[0]=o,e[1]=p):p=e[1];const g=p,a=mt(o,r,g),T=`${o}-${r}`;let v;e[2]!==l||e[3]!==T?(v={namespace:l,resource:T,defaultSortKey:"updated_at"},e[2]=l,e[3]=T,e[4]=v):v=e[4];const{search:b,searchTerm:P,setSearch:w,viewMode:h,setViewMode:A,sortKey:D,sortDirection:y,handleSort:k}=It(v);let _;e[5]!==P||e[6]!==y||e[7]!==D?(_={searchTerm:P,sortKey:D,sortDirection:y},e[5]=P,e[6]=y,e[7]=D,e[8]=_):_=e[8];const E=ut(o,r,g,_),N=!f&&!C&&!i;let z;e[9]!==r||e[10]!==o||e[11]!==c||e[12]!==l?(z=$=>{c({to:"/$org/mcps/$connectionId/$collectionName/$itemId",params:{org:l,connectionId:o,collectionName:r,itemId:$.id}})},e[9]=r,e[10]=o,e[11]=c,e[12]=l,e[13]=z):z=e[13];const I=z;let S;e[14]!==a.create||e[15]!==m?(S=async $=>{const he=new Date().toISOString();await a.create.mutateAsync({...$,id:Be("conn"),title:`${$.title} (Copy)`,created_at:he,updated_at:he,created_by:m,updated_by:m})},e[14]=a.create,e[15]=m,e[16]=S):S=e[16];const O=S,[x,M]=ie.useState(null);let le;e[17]===Symbol.for("react.memo_cache_sentinel")?(le=$=>{M($)},e[17]=le):le=e[17];const ot=le;let B;e[18]!==I||e[19]!==C?(B=C&&{edit:I},e[18]=I,e[19]=C,e[20]=B):B=e[20];let R;e[21]!==O||e[22]!==f?(R=f&&{duplicate:O},e[21]=O,e[22]=f,e[23]=R):R=e[23];let F;e[24]!==i?(F=i&&{delete:ot},e[24]=i,e[25]=F):F=e[25];let re;e[26]!==F||e[27]!==B||e[28]!==R?(re={...B,...R,...F},e[26]=F,e[27]=B,e[28]=R,e[29]=re):re=e[29];const ge=re;let ae;e[30]!==a.delete||e[31]!==x?(ae=async()=>{x&&(await a.delete.mutateAsync(x.id),M(null))},e[30]=a.delete,e[31]=x,e[32]=ae):ae=e[32];const je=ae;let ce;e[33]!==a.create||e[34]!==r||e[35]!==o||e[36]!==f||e[37]!==c||e[38]!==l||e[39]!==m?(ce=async()=>{if(!f){rt.error("Create operation is not available for this collection");return}const $=new Date().toISOString(),he={id:Be("conn"),title:"New Item",description:"A brief description of the item",created_at:$,updated_at:$,created_by:m,updated_by:m};try{const ke=await a.create.mutateAsync(he);c({to:"/$org/mcps/$connectionId/$collectionName/$itemId",params:{org:l,connectionId:o,collectionName:r,itemId:ke.id}})}catch(ke){console.error("Failed to create item:",ke)}},e[33]=a.create,e[34]=r,e[35]=o,e[36]=f,e[37]=c,e[38]=l,e[39]=m,e[40]=ce):ce=e[40];const be=ce;let de;e[41]!==d?(de=tt(d),e[41]=d,e[42]=de):de=e[42];const Ce=de,Me=(E?.length??0)>0,nt=f&&Me,it=f&&!Me&&!b;let me;e[43]!==a.create||e[44]!==be||e[45]!==f?(me=f?t.jsxs(xe,{onClick:be,size:"sm",disabled:a.create.isPending,className:"h-7",children:[t.jsx(Lt,{className:"mr-2 h-4 w-4"}),a.create.isPending?"Creating...":"Create"]}):null,e[43]=a.create,e[44]=be,e[45]=f,e[46]=me):me=e[46];const Le=me,ve=D;let U;e[47]!==k||e[48]!==A||e[49]!==y||e[50]!==Ce||e[51]!==ve||e[52]!==h?(U=t.jsx(Ge,{viewMode:h,onViewModeChange:A,sortKey:ve,sortDirection:y,onSort:k,sortOptions:Ce}),e[47]=k,e[48]=A,e[49]=y,e[50]=Ce,e[51]=ve,e[52]=h,e[53]=U):U=e[53];const ye=`${r}s`,we=u?.icon??"grid_view";let K;e[54]!==o||e[55]!==ye||e[56]!==we?(K=t.jsx(xt,{connectionId:o,title:ye,icon:we}),e[54]=o,e[55]=ye,e[56]=we,e[57]=K):K=e[57];const Ne=nt&&Le;let W;e[58]!==U||e[59]!==K||e[60]!==Ne?(W=t.jsxs(yt,{children:[U,K,Ne]}),e[58]=U,e[59]=K,e[60]=Ne,e[61]=W):W=e[61];const Se=`Search ${r}...`;let q;e[62]!==w?(q=$=>{$.key==="Escape"&&(w(""),$.target.blur())},e[62]=w,e[63]=q):q=e[63];let G;e[64]!==b||e[65]!==w||e[66]!==Se||e[67]!==q?(G=t.jsx(St,{value:b,onChange:w,placeholder:Se,onKeyDown:q}),e[64]=b,e[65]=w,e[66]=Se,e[67]=q,e[68]=G):G=e[68];let H;e[69]!==E?(H=E??[],e[69]=E,e[70]=H):H=e[70];const _e=D;let J;e[71]!==I?(J=$=>I($),e[71]=I,e[72]=J):J=e[72];const Ie="No items found",Te=b?"Try adjusting your search terms":"This collection doesn't have any items yet.",Ae=it?Le:void 0;let Z;e[73]!==Ie||e[74]!==Te||e[75]!==Ae?(Z=t.jsx(Oe,{image:null,title:Ie,description:Te,actions:Ae}),e[73]=Ie,e[74]=Te,e[75]=Ae,e[76]=Z):Z=e[76];let Q;e[77]!==k||e[78]!==N||e[79]!==ge||e[80]!==d||e[81]!==b||e[82]!==w||e[83]!==A||e[84]!==y||e[85]!==H||e[86]!==_e||e[87]!==J||e[88]!==Z||e[89]!==h?(Q=t.jsx("div",{className:"flex-1 overflow-auto",children:t.jsx(Gt,{hideToolbar:!0,data:H,schema:d,viewMode:h,onViewModeChange:A,search:b,onSearchChange:w,sortKey:_e,sortDirection:y,onSort:k,actions:ge,onItemClick:J,readOnly:N,emptyState:Z})}),e[77]=k,e[78]=N,e[79]=ge,e[80]=d,e[81]=b,e[82]=w,e[83]=A,e[84]=y,e[85]=H,e[86]=_e,e[87]=J,e[88]=Z,e[89]=h,e[90]=Q):Q=e[90];let X;e[91]!==G||e[92]!==Q?(X=t.jsxs("div",{className:"flex flex-col h-full overflow-hidden",children:[G,Q]}),e[91]=G,e[92]=Q,e[93]=X):X=e[93];const De=!!x;let ue;e[94]===Symbol.for("react.memo_cache_sentinel")?(ue=$=>{$||M(null)},e[94]=ue):ue=e[94];let fe;e[95]===Symbol.for("react.memo_cache_sentinel")?(fe=t.jsx(Pt,{children:"Delete item?"}),e[95]=fe):fe=e[95];const $e=x?.title;let Y;e[96]!==$e?(Y=t.jsxs(kt,{children:[fe,t.jsxs(Et,{children:['Are you sure you want to delete "',$e,'"? This action cannot be undone.']})]}),e[96]=$e,e[97]=Y):Y=e[97];let ee;e[98]!==a.delete.isPending?(ee=t.jsx(Dt,{disabled:a.delete.isPending,children:"Cancel"}),e[98]=a.delete.isPending,e[99]=ee):ee=e[99];const Pe=a.delete.isPending?"Deleting...":"Delete";let te;e[100]!==a.delete.isPending||e[101]!==je||e[102]!==Pe?(te=t.jsx($t,{onClick:je,disabled:a.delete.isPending,className:"bg-destructive text-destructive-foreground hover:bg-destructive/90",children:Pe}),e[100]=a.delete.isPending,e[101]=je,e[102]=Pe,e[103]=te):te=e[103];let se;e[104]!==ee||e[105]!==te?(se=t.jsxs(Ot,{children:[ee,te]}),e[104]=ee,e[105]=te,e[106]=se):se=e[106];let oe;e[107]!==Y||e[108]!==se?(oe=t.jsxs(zt,{children:[Y,se]}),e[107]=Y,e[108]=se,e[109]=oe):oe=e[109];let ne;e[110]!==De||e[111]!==oe?(ne=t.jsx(Mt,{open:De,onOpenChange:ue,children:oe}),e[110]=De,e[111]=oe,e[112]=ne):ne=e[112];let pe;return e[113]!==W||e[114]!==X||e[115]!==ne?(pe=t.jsxs(t.Fragment,{children:[W,X,ne]}),e[113]=W,e[114]=X,e[115]=ne,e[116]=pe):pe=e[116],pe}function os(s){const e=L.c(2),{repository:o}=s;let l;return e[0]!==o?(l=t.jsx("div",{className:"flex-1 overflow-y-auto bg-background",children:t.jsx(bt,{repository:o})}),e[0]=o,e[1]=l):l=e[1],l}function ns(s){const e=L.c(4),{tools:o,connectionId:l,org:n}=s;let r;return e[0]!==l||e[1]!==n||e[2]!==o?(r=t.jsx(Ct,{tools:o,connectionId:l,org:n}),e[0]=l,e[1]=n,e[2]=o,e[3]=r):r=e[3],r}function is(s){const e=L.c(50),{connection:o,connectionId:l,org:n,requestedTabId:r,collections:d,onUpdate:f,isUpdating:C}=s,i=dt();let c;e[0]===Symbol.for("react.memo_cache_sentinel")?(c={from:"/$org/mcps/$connectionId"},e[0]=c):c=e[0];const j=Ee(c);let m;e[1]!==l?(m={connectionId:l},e[1]=l,e[2]=m):m=e[2];const u=gt(m),p=u.isAuthenticated,g=o?.metadata?.repository,a=!!g?.url,T=o?.tools?.length??0;let v;e[3]===Symbol.for("react.memo_cache_sentinel")?(v={id:"settings",label:"Settings"},e[3]=v):v=e[3];let b;e[4]!==p||e[5]!==T?(b=p&&T>0?[{id:"tools",label:"Tools",count:T}]:[],e[4]=p,e[5]=T,e[6]=b):b=e[6];let P;if(e[7]!==d||e[8]!==a||e[9]!==p||e[10]!==b){let x;e[12]!==a?(x=a?[{id:"readme",label:"README"}]:[],e[12]=a,e[13]=x):x=e[13],P=[v,...b,...p?(d||[]).map(ls):[],...x],e[7]=d,e[8]=a,e[9]=p,e[10]=b,e[11]=P}else P=e[11];const w=P,h=w.some(x=>x.id===r)?r:"settings";let A;e[14]!==j?(A=x=>{j({search:M=>({...M,tab:x}),replace:!0})},e[14]=j,e[15]=A):A=e[15];const D=A;let y;e[16]!==d?(y=d||[],e[16]=d,e[17]=y):y=e[17];let k;if(e[18]!==h||e[19]!==y){let x;e[21]!==h?(x=M=>M.name===h,e[21]=h,e[22]=x):x=e[22],k=y.find(x),e[18]=h,e[19]=y,e[20]=k}else k=e[20];const _=k;let E;e[23]!==i.history?(E=()=>i.history.back(),e[23]=i.history,e[24]=E):E=e[24];let N;e[25]!==h||e[26]!==D||e[27]!==w?(N=t.jsx(wt,{children:t.jsx(vt,{tabs:w,activeTab:h,onTabChange:D})}),e[25]=h,e[26]=D,e[27]=w,e[28]=N):N=e[28];let z;e[29]===Symbol.for("react.memo_cache_sentinel")?(z=t.jsx("div",{className:"flex h-full items-center justify-center",children:t.jsx(qe,{size:32,className:"animate-spin text-muted-foreground"})}),e[29]=z):z=e[29];let I;e[30]!==_||e[31]!==h||e[32]!==u.supportsOAuth||e[33]!==o||e[34]!==l||e[35]!==D||e[36]!==a||e[37]!==p||e[38]!==C||e[39]!==f||e[40]!==n||e[41]!==g?(I=t.jsx(ie.Suspense,{fallback:z,children:h==="tools"?t.jsx(ns,{tools:o.tools??void 0,connectionId:l,org:n}):h==="settings"?t.jsx(jt,{connection:o,onUpdate:f,isUpdating:C,isMCPAuthenticated:p,supportsOAuth:u.supportsOAuth,onViewReadme:a?()=>D("readme"):void 0}):h==="readme"&&a?t.jsx(os,{repository:g}):_&&p?t.jsx(ss,{connectionId:l,org:n,activeCollection:_},h):t.jsx(Oe,{title:"Collection not found",description:"This collection may have been deleted or you may not have access."})}),e[30]=_,e[31]=h,e[32]=u.supportsOAuth,e[33]=o,e[34]=l,e[35]=D,e[36]=a,e[37]=p,e[38]=C,e[39]=f,e[40]=n,e[41]=g,e[42]=I):I=e[42];let S;e[43]!==h||e[44]!==I?(S=t.jsx("div",{className:"flex h-full w-full bg-background overflow-hidden",children:t.jsx("div",{className:"flex-1 flex flex-col min-w-0 bg-background overflow-auto",children:t.jsx(Ue,{children:I},h)})}),e[43]=h,e[44]=I,e[45]=S):S=e[45];let O;return e[46]!==N||e[47]!==S||e[48]!==E?(O=t.jsxs(Nt,{onBack:E,children:[N,S]}),e[46]=N,e[47]=S,e[48]=E,e[49]=O):O=e[49],O}function ls(s){return{id:s.name,label:s.displayName}}function rs(){const s=L.c(17);let e;s[0]===Symbol.for("react.memo_cache_sentinel")?(e={from:"/$org/mcps/$connectionId"},s[0]=e):e=s[0];const o=Ee(e);let l;s[1]===Symbol.for("react.memo_cache_sentinel")?(l={from:"/shell/$org/mcps/$connectionId"},s[1]=l):l=s[1];const{connectionId:n,org:r}=at(l);let d;s[2]===Symbol.for("react.memo_cache_sentinel")?(d={from:"/shell/$org/mcps/$connectionId"},s[2]=d):d=s[2];const C=ct(d).tab||"settings",i=We(n),c=pt(),j=ht(i??void 0);let m;s[3]!==c.update||s[4]!==n?(m=async g=>{await c.update.mutateAsync({id:n,data:g})},s[3]=c.update,s[4]=n,s[5]=m):m=s[5];const u=m;if(!i){let g;return s[6]!==o||s[7]!==r?(g=t.jsx("div",{className:"flex h-full w-full bg-background",children:t.jsx(Oe,{title:"Connection not found",description:"This connection may have been deleted or you may not have access.",actions:t.jsx(xe,{variant:"outline",onClick:()=>o({to:"/$org/mcps",params:{org:r}}),children:"Back to connections"})})}),s[6]=o,s[7]=r,s[8]=g):g=s[8],g}let p;return s[9]!==c.update.isPending||s[10]!==j||s[11]!==i||s[12]!==n||s[13]!==u||s[14]!==r||s[15]!==C?(p=t.jsx(is,{org:r,connection:i,connectionId:n,requestedTabId:C,collections:j,onUpdate:u,isUpdating:c.update.isPending}),s[9]=c.update.isPending,s[10]=j,s[11]=i,s[12]=n,s[13]=u,s[14]=r,s[15]=C,s[16]=p):p=s[16],p}function as(){const s=L.c(1);let e;return s[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsx(Ue,{children:t.jsx(ie.Suspense,{fallback:t.jsx("div",{className:"flex h-full items-center justify-center bg-background",children:t.jsx(qe,{size:32,className:"animate-spin text-muted-foreground"})}),children:t.jsx(rs,{})})}),s[0]=e):e=s[0],e}function no(){const s=L.c(1);let e;return s[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsx(as,{}),s[0]=e):e=s[0],e}export{no as default};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
const P=Symbol.for("constructDateFrom");function p(t,n){return typeof t=="function"?t(n):t&&typeof t=="object"&&P in t?t[P](n):t instanceof Date?new t.constructor(n):new Date(n)}function h(t,n){return p(t,t)}let S={};function k(){return S}function W(t){const n=h(t),e=new Date(Date.UTC(n.getFullYear(),n.getMonth(),n.getDate(),n.getHours(),n.getMinutes(),n.getSeconds(),n.getMilliseconds()));return e.setUTCFullYear(n.getFullYear()),+t-+e}function v(t,...n){const e=p.bind(null,t||n.find(o=>typeof o=="object"));return n.map(e)}function M(t,n){const e=+h(t)-+h(n);return e<0?-1:e>0?1:e}function F(t){return p(t,Date.now())}function x(t,n,e){const[o,a]=v(e?.in,t,n),s=o.getFullYear()-a.getFullYear(),i=o.getMonth()-a.getMonth();return s*12+i}function T(t){return n=>{const o=(t?Math[t]:Math.trunc)(n);return o===0?0:o}}function C(t,n){return+h(t)-+h(n)}function X(t,n){const e=h(t);return e.setHours(23,59,59,999),e}function A(t,n){const e=h(t),o=e.getMonth();return e.setFullYear(e.getFullYear(),o+1,0),e.setHours(23,59,59,999),e}function I(t,n){const e=h(t);return+X(e)==+A(e)}function O(t,n,e){const[o,a,s]=v(e?.in,t,t,n),i=M(a,s),r=Math.abs(x(a,s));if(r<1)return 0;a.getMonth()===1&&a.getDate()>27&&a.setDate(30),a.setMonth(a.getMonth()-i*r);let d=M(a,s)===-i;I(o)&&r===1&&M(o,s)===1&&(d=!1);const c=i*(r-+d);return c===0?0:c}function j(t,n,e){const o=C(t,n)/1e3;return T(e?.roundingMethod)(o)}const Y={lessThanXSeconds:{one:"less than a second",other:"less than {{count}} seconds"},xSeconds:{one:"1 second",other:"{{count}} seconds"},halfAMinute:"half a minute",lessThanXMinutes:{one:"less than a minute",other:"less than {{count}} minutes"},xMinutes:{one:"1 minute",other:"{{count}} minutes"},aboutXHours:{one:"about 1 hour",other:"about {{count}} hours"},xHours:{one:"1 hour",other:"{{count}} hours"},xDays:{one:"1 day",other:"{{count}} days"},aboutXWeeks:{one:"about 1 week",other:"about {{count}} weeks"},xWeeks:{one:"1 week",other:"{{count}} weeks"},aboutXMonths:{one:"about 1 month",other:"about {{count}} months"},xMonths:{one:"1 month",other:"{{count}} months"},aboutXYears:{one:"about 1 year",other:"about {{count}} years"},xYears:{one:"1 year",other:"{{count}} years"},overXYears:{one:"over 1 year",other:"over {{count}} years"},almostXYears:{one:"almost 1 year",other:"almost {{count}} years"}},_=(t,n,e)=>{let o;const a=Y[t];return typeof a=="string"?o=a:n===1?o=a.one:o=a.other.replace("{{count}}",n.toString()),e?.addSuffix?e.comparison&&e.comparison>0?"in "+o:o+" ago":o};function D(t){return(n={})=>{const e=n.width?String(n.width):t.defaultWidth;return t.formats[e]||t.formats[t.defaultWidth]}}const N={full:"EEEE, MMMM do, y",long:"MMMM do, y",medium:"MMM d, y",short:"MM/dd/yyyy"},z={full:"h:mm:ss a zzzz",long:"h:mm:ss a z",medium:"h:mm:ss a",short:"h:mm a"},V={full:"{{date}} 'at' {{time}}",long:"{{date}} 'at' {{time}}",medium:"{{date}}, {{time}}",short:"{{date}}, {{time}}"},q={date:D({formats:N,defaultWidth:"full"}),time:D({formats:z,defaultWidth:"full"}),dateTime:D({formats:V,defaultWidth:"full"})},J={lastWeek:"'last' eeee 'at' p",yesterday:"'yesterday at' p",today:"'today at' p",tomorrow:"'tomorrow at' p",nextWeek:"eeee 'at' p",other:"P"},L=(t,n,e,o)=>J[t];function g(t){return(n,e)=>{const o=e?.context?String(e.context):"standalone";let a;if(o==="formatting"&&t.formattingValues){const i=t.defaultFormattingWidth||t.defaultWidth,r=e?.width?String(e.width):i;a=t.formattingValues[r]||t.formattingValues[i]}else{const i=t.defaultWidth,r=e?.width?String(e.width):t.defaultWidth;a=t.values[r]||t.values[i]}const s=t.argumentCallback?t.argumentCallback(n):n;return a[s]}}const R={narrow:["B","A"],abbreviated:["BC","AD"],wide:["Before Christ","Anno Domini"]},E={narrow:["1","2","3","4"],abbreviated:["Q1","Q2","Q3","Q4"],wide:["1st quarter","2nd quarter","3rd quarter","4th quarter"]},H={narrow:["J","F","M","A","M","J","J","A","S","O","N","D"],abbreviated:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],wide:["January","February","March","April","May","June","July","August","September","October","November","December"]},Q={narrow:["S","M","T","W","T","F","S"],short:["Su","Mo","Tu","We","Th","Fr","Sa"],abbreviated:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],wide:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},U={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"morning",afternoon:"afternoon",evening:"evening",night:"night"}},B={narrow:{am:"a",pm:"p",midnight:"mi",noon:"n",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},abbreviated:{am:"AM",pm:"PM",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"},wide:{am:"a.m.",pm:"p.m.",midnight:"midnight",noon:"noon",morning:"in the morning",afternoon:"in the afternoon",evening:"in the evening",night:"at night"}},K=(t,n)=>{const e=Number(t),o=e%100;if(o>20||o<10)switch(o%10){case 1:return e+"st";case 2:return e+"nd";case 3:return e+"rd"}return e+"th"},$={ordinalNumber:K,era:g({values:R,defaultWidth:"wide"}),quarter:g({values:E,defaultWidth:"wide",argumentCallback:t=>t-1}),month:g({values:H,defaultWidth:"wide"}),day:g({values:Q,defaultWidth:"wide"}),dayPeriod:g({values:U,defaultWidth:"wide",formattingValues:B,defaultFormattingWidth:"wide"})};function b(t){return(n,e={})=>{const o=e.width,a=o&&t.matchPatterns[o]||t.matchPatterns[t.defaultMatchWidth],s=n.match(a);if(!s)return null;const i=s[0],r=o&&t.parsePatterns[o]||t.parsePatterns[t.defaultParseWidth],d=Array.isArray(r)?Z(r,y=>y.test(i)):G(r,y=>y.test(i));let c;c=t.valueCallback?t.valueCallback(d):d,c=e.valueCallback?e.valueCallback(c):c;const l=n.slice(i.length);return{value:c,rest:l}}}function G(t,n){for(const e in t)if(Object.prototype.hasOwnProperty.call(t,e)&&n(t[e]))return e}function Z(t,n){for(let e=0;e<t.length;e++)if(n(t[e]))return e}function tt(t){return(n,e={})=>{const o=n.match(t.matchPattern);if(!o)return null;const a=o[0],s=n.match(t.parsePattern);if(!s)return null;let i=t.valueCallback?t.valueCallback(s[0]):s[0];i=e.valueCallback?e.valueCallback(i):i;const r=n.slice(a.length);return{value:i,rest:r}}}const et=/^(\d+)(th|st|nd|rd)?/i,nt=/\d+/i,at={narrow:/^(b|a)/i,abbreviated:/^(b\.?\s?c\.?|b\.?\s?c\.?\s?e\.?|a\.?\s?d\.?|c\.?\s?e\.?)/i,wide:/^(before christ|before common era|anno domini|common era)/i},ot={any:[/^b/i,/^(a|c)/i]},rt={narrow:/^[1234]/i,abbreviated:/^q[1234]/i,wide:/^[1234](th|st|nd|rd)? quarter/i},it={any:[/1/i,/2/i,/3/i,/4/i]},st={narrow:/^[jfmasond]/i,abbreviated:/^(jan|feb|mar|apr|may|jun|jul|aug|sep|oct|nov|dec)/i,wide:/^(january|february|march|april|may|june|july|august|september|october|november|december)/i},ut={narrow:[/^j/i,/^f/i,/^m/i,/^a/i,/^m/i,/^j/i,/^j/i,/^a/i,/^s/i,/^o/i,/^n/i,/^d/i],any:[/^ja/i,/^f/i,/^mar/i,/^ap/i,/^may/i,/^jun/i,/^jul/i,/^au/i,/^s/i,/^o/i,/^n/i,/^d/i]},ct={narrow:/^[smtwf]/i,short:/^(su|mo|tu|we|th|fr|sa)/i,abbreviated:/^(sun|mon|tue|wed|thu|fri|sat)/i,wide:/^(sunday|monday|tuesday|wednesday|thursday|friday|saturday)/i},dt={narrow:[/^s/i,/^m/i,/^t/i,/^w/i,/^t/i,/^f/i,/^s/i],any:[/^su/i,/^m/i,/^tu/i,/^w/i,/^th/i,/^f/i,/^sa/i]},lt={narrow:/^(a|p|mi|n|(in the|at) (morning|afternoon|evening|night))/i,any:/^([ap]\.?\s?m\.?|midnight|noon|(in the|at) (morning|afternoon|evening|night))/i},mt={any:{am:/^a/i,pm:/^p/i,midnight:/^mi/i,noon:/^no/i,morning:/morning/i,afternoon:/afternoon/i,evening:/evening/i,night:/night/i}},ht={ordinalNumber:tt({matchPattern:et,parsePattern:nt,valueCallback:t=>parseInt(t,10)}),era:b({matchPatterns:at,defaultMatchWidth:"wide",parsePatterns:ot,defaultParseWidth:"any"}),quarter:b({matchPatterns:rt,defaultMatchWidth:"wide",parsePatterns:it,defaultParseWidth:"any",valueCallback:t=>t+1}),month:b({matchPatterns:st,defaultMatchWidth:"wide",parsePatterns:ut,defaultParseWidth:"any"}),day:b({matchPatterns:ct,defaultMatchWidth:"wide",parsePatterns:dt,defaultParseWidth:"any"}),dayPeriod:b({matchPatterns:lt,defaultMatchWidth:"any",parsePatterns:mt,defaultParseWidth:"any"})},ft={code:"en-US",formatDistance:_,formatLong:q,formatRelative:L,localize:$,match:ht,options:{weekStartsOn:0,firstWeekContainsDate:1}};function yt(t,n,e){const o=k(),a=e?.locale??o.locale??ft,s=2520,i=M(t,n);if(isNaN(i))throw new RangeError("Invalid time value");const r=Object.assign({},e,{addSuffix:e?.addSuffix,comparison:i}),[d,c]=v(e?.in,...i>0?[n,t]:[t,n]),l=j(c,d),y=(W(c)-W(d))/1e3,u=Math.round((l-y)/60);let f;if(u<2)return e?.includeSeconds?l<5?a.formatDistance("lessThanXSeconds",5,r):l<10?a.formatDistance("lessThanXSeconds",10,r):l<20?a.formatDistance("lessThanXSeconds",20,r):l<40?a.formatDistance("halfAMinute",0,r):l<60?a.formatDistance("lessThanXMinutes",1,r):a.formatDistance("xMinutes",1,r):u===0?a.formatDistance("lessThanXMinutes",1,r):a.formatDistance("xMinutes",u,r);if(u<45)return a.formatDistance("xMinutes",u,r);if(u<90)return a.formatDistance("aboutXHours",1,r);if(u<1440){const m=Math.round(u/60);return a.formatDistance("aboutXHours",m,r)}else{if(u<s)return a.formatDistance("xDays",1,r);if(u<43200){const m=Math.round(u/1440);return a.formatDistance("xDays",m,r)}else if(u<43200*2)return f=Math.round(u/43200),a.formatDistance("aboutXMonths",f,r)}if(f=O(c,d),f<12){const m=Math.round(u/43200);return a.formatDistance("xMonths",m,r)}else{const m=f%12,w=Math.trunc(f/12);return m<3?a.formatDistance("aboutXYears",w,r):m<9?a.formatDistance("overXYears",w,r):a.formatDistance("almostXYears",w+1,r)}}function gt(t,n){return yt(t,F(t),n)}export{gt as f};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
import{c as O,j as t,r as U,f as be,d as _e,v as ve,by as oe,w as ae,av as we,x as Ce,y as Ne,t as ie}from"./index-BXYAUeFB.js";import{E as Se}from"./SearchMd-D-BfTFbd.js";import{E as ce}from"./error-boundary-Bstevc3G.js";import{u as Te,I as ke}from"./use-connection-DcTy916p.js";import{S as Ie,T as $e}from"./switch-D3JJPNlW.js";import{b as Ee,a as Fe}from"./use-gateway-I6Ko0Jgt.js";import{B as L}from"./button-WiHHb1ae.js";import{a as M,c as q,b as W,T as H,i as re}from"./tooltip-Dgdin-_i.js";import{a as Ge}from"./Copy01-Bilz-YTB.js";import{i as ze}from"./CpuChip02-CHm038ee.js";import{i as de}from"./InfoCircle-D7V0pgdh.js";import{i as le}from"./Loading01-BWm5a2UX.js";import{I as me}from"./input-BElOouK2.js";import{F as J,a as Ae,b as Q,d as X,f as Y,c as fe}from"./form-BrDOMpvk.js";import{S as ue,a as xe,b as he,c as pe,d as K}from"./select-DuRyb06m.js";import{s as Ve}from"./slugify-CEUa2lfQ.js";import{V as De,b as Pe}from"./layout-BDLGK1gR.js";import{f as Be}from"./formatDistanceToNow-Ctx6mZEP.js";import"./utils-D2m6QoGq.js";import"./checkbox-D_yjB9VU.js";import"./ArrowLeft-B2kSl8Am.js";import"./collection-search-ByjFbpzN.js";import"./ChevronDown-LB39JZIr.js";function Ue(o){const s=new TextEncoder().encode(o),l=Array.from(s,a=>String.fromCharCode(a)).join("");return btoa(l)}function Oe(o){const e=O.c(52),{serverName:s,gatewayUrl:l}=o,[a,c]=U.useState(!1),[i,f]=U.useState(null),n=Ve(s);let r,d,g,j;if(e[0]!==l||e[1]!==n){const ee={type:"http",url:l},te={[n]:ee};r=JSON.stringify(te,null,2);const ne=ye=>JSON.stringify({...ee,headers:{"x-mesh-client":ye}},null,2),ge=Ue(ne("Cursor"));d=`cursor://anysphere.cursor-deeplink/mcp/install?name=${encodeURIComponent(n)}&config=${encodeURIComponent(ge)}`;const je=ne("Claude Code");g=n;let se;e[6]===Symbol.for("react.memo_cache_sentinel")?(se=/'/g,e[6]=se):se=e[6],j=je.replace(se,"'\\''"),e[0]=l,e[1]=n,e[2]=r,e[3]=d,e[4]=g,e[5]=j}else r=e[2],d=e[3],g=e[4],j=e[5];const y=`claude mcp add "${g}" --config '${j}'`;let p;e[7]!==r?(p=async()=>{await navigator.clipboard.writeText(r),c(!0),ie.success("Configuration copied to clipboard"),setTimeout(()=>c(!1),2e3)},e[7]=r,e[8]=p):p=e[8];const x=p;let u;e[9]===Symbol.for("react.memo_cache_sentinel")?(u=async(ee,te)=>{await navigator.clipboard.writeText(ee),f(te),ie.success(`${te} command copied`),setTimeout(()=>f(null),2e3)},e[9]=u):u=e[9];const F=u,R=Re;let z;e[10]===Symbol.for("react.memo_cache_sentinel")?(z=t.jsx("div",{children:t.jsx("h4",{className:"text-sm font-medium text-foreground mb-1",children:"Install in your IDE"})}),e[10]=z):z=e[10];let h;e[11]!==a?(h=a?t.jsx(re,{size:14}):t.jsx(Ge,{size:14}),e[11]=a,e[12]=h):h=e[12];let B;e[13]!==x||e[14]!==h?(B=t.jsx(W,{asChild:!0,children:t.jsx(L,{variant:"ghost",size:"sm",className:"h-7 w-7 p-0 shrink-0",onClick:x,children:h})}),e[13]=x,e[14]=h,e[15]=B):B=e[15];let V;e[16]===Symbol.for("react.memo_cache_sentinel")?(V=t.jsx(H,{children:"Copy configuration"}),e[16]=V):V=e[16];let S;e[17]!==B?(S=t.jsx("div",{className:"absolute top-2 right-2",children:t.jsx(M,{children:t.jsxs(q,{children:[B,V]})})}),e[17]=B,e[18]=S):S=e[18];let G;e[19]!==r||e[20]!==x?(G=t.jsx("pre",{className:"text-xs font-mono text-foreground overflow-auto max-h-40 whitespace-pre-wrap wrap-break-word cursor-pointer",onClick:x,children:r}),e[19]=r,e[20]=x,e[21]=G):G=e[21];let b;e[22]!==G||e[23]!==S?(b=t.jsxs("div",{className:"relative flex flex-col gap-2 p-3 bg-muted/50 rounded-lg",children:[S,G]}),e[22]=G,e[23]=S,e[24]=b):b=e[24];let _;e[25]!==d?(_=()=>R(d),e[25]=d,e[26]=_):_=e[26];let T,k;e[27]===Symbol.for("react.memo_cache_sentinel")?(T=t.jsx("img",{src:"/logos/cursor.svg",alt:"Cursor",className:"h-6 w-6",style:{filter:"brightness(0) saturate(100%) invert(11%) sepia(8%) saturate(785%) hue-rotate(1deg) brightness(95%) contrast(89%)"}}),k=t.jsx("span",{className:"text-sm font-medium",children:"Cursor"}),e[27]=T,e[28]=k):(T=e[27],k=e[28]);let v;e[29]!==_?(v=t.jsx(W,{asChild:!0,children:t.jsxs(L,{variant:"outline",className:"h-auto py-3 px-4 justify-center gap-2 flex-1 min-w-fit",onClick:_,children:[T,k]})}),e[29]=_,e[30]=v):v=e[30];let D;e[31]===Symbol.for("react.memo_cache_sentinel")?(D=t.jsx(H,{children:"Add to Cursor"}),e[31]=D):D=e[31];let w;e[32]!==v?(w=t.jsx(M,{children:t.jsxs(q,{children:[v,D]})}),e[32]=v,e[33]=w):w=e[33];let I;e[34]!==y?(I=()=>F(y,"Claude"),e[34]=y,e[35]=I):I=e[35];let $,E;e[36]===Symbol.for("react.memo_cache_sentinel")?($=t.jsx("img",{src:"/logos/Claude Code.svg",alt:"Claude Code",className:"h-6 w-6",style:{filter:"brightness(0) saturate(100%) invert(55%) sepia(31%) saturate(1264%) hue-rotate(331deg) brightness(92%) contrast(86%)"}}),E=t.jsx("span",{className:"text-sm font-medium",children:"Claude Code"}),e[36]=$,e[37]=E):($=e[36],E=e[37]);let C;e[38]!==i?(C=i==="Claude"&&t.jsx(re,{size:14,className:"ml-2 text-green-500"}),e[38]=i,e[39]=C):C=e[39];let N;e[40]!==I||e[41]!==C?(N=t.jsx(W,{asChild:!0,children:t.jsxs(L,{variant:"outline",className:"h-auto py-3 px-4 justify-center gap-2 flex-1 min-w-fit",onClick:I,children:[$,E,C]})}),e[40]=I,e[41]=C,e[42]=N):N=e[42];let A;e[43]===Symbol.for("react.memo_cache_sentinel")?(A=t.jsx(H,{children:"Add to Claude Code"}),e[43]=A):A=e[43];let m;e[44]!==N?(m=t.jsx(M,{children:t.jsxs(q,{children:[N,A]})}),e[44]=N,e[45]=m):m=e[45];let P;e[46]!==w||e[47]!==m?(P=t.jsxs("div",{className:"flex flex-wrap gap-2",children:[w,m]}),e[46]=w,e[47]=m,e[48]=P):P=e[48];let Z;return e[49]!==b||e[50]!==P?(Z=t.jsxs("div",{className:"flex flex-col gap-4",children:[z,b,P]}),e[49]=b,e[50]=P,e[51]=Z):Z=e[51],Z}function Re(o){window.open(o,"_blank")}const Je=ve({title:ae().min(1,"Name is required").max(255),description:ae().nullable(),status:oe(["active","inactive"]),tool_selection_mode:oe(["inclusion","exclusion"]),tool_selection_strategy:oe(["passthrough","smart_tool_selection","code_execution"])});function Le(o,e){const s={};for(const l of o.connections)if(l.selected_tools===null){const a=e.get(l.connection_id)??[];a.length>0&&(s[l.connection_id]=a)}else l.selected_tools.length>0&&(s[l.connection_id]=l.selected_tools);return s}function Me(o,e){return Object.entries(o).map(([s,l])=>{const a=e.get(s)??[],c=a.length>0&&a.every(i=>l.includes(i));return{connection_id:s,selected_tools:c?null:l}})}function qe(o){const e=O.c(29),{form:s,toolSet:l,onToolSetChange:a,icon:c}=o;let i;e[0]!==s?(i=s.watch("title")||"Gateway",e[0]=s,e[1]=i):i=e[1];let f;e[2]===Symbol.for("react.memo_cache_sentinel")?(f=t.jsx(ze,{}),e[2]=f):f=e[2];let n;e[3]!==c||e[4]!==i?(n=t.jsx(ke,{icon:c,name:i,size:"lg",className:"shrink-0 shadow-sm",fallbackIcon:f}),e[3]=c,e[4]=i,e[5]=n):n=e[5];let r;e[6]!==s.control?(r=t.jsx(J,{control:s.control,name:"status",render:Xe}),e[6]=s.control,e[7]=r):r=e[7];let d;e[8]!==n||e[9]!==r?(d=t.jsxs("div",{className:"flex items-start justify-between",children:[n,r]}),e[8]=n,e[9]=r,e[10]=d):d=e[10];let g;e[11]!==s.control?(g=t.jsxs("div",{className:"flex flex-col",children:[t.jsx(J,{control:s.control,name:"title",render:Qe}),t.jsx(J,{control:s.control,name:"description",render:Ke})]}),e[11]=s.control,e[12]=g):g=e[12];let j;e[13]!==d||e[14]!==g?(j=t.jsxs("div",{className:"flex flex-col gap-4 p-5 border-b border-border",children:[d,g]}),e[13]=d,e[14]=g,e[15]=j):j=e[15];let y;e[16]!==s.control?(y=t.jsxs("div",{className:"flex flex-col gap-4 p-5 border-b border-border",children:[t.jsx(J,{control:s.control,name:"tool_selection_mode",render:He}),t.jsx(J,{control:s.control,name:"tool_selection_strategy",render:We})]}),e[16]=s.control,e[17]=y):y=e[17];let p;e[18]===Symbol.for("react.memo_cache_sentinel")?(p=t.jsx("div",{className:"flex-1 flex items-center justify-center p-5",children:t.jsx(le,{size:32,className:"animate-spin text-muted-foreground"})}),e[18]=p):p=e[18];let x;e[19]!==a||e[20]!==l?(x=t.jsx("div",{className:"flex-1 min-h-0 overflow-auto",children:t.jsx(ce,{children:t.jsx(U.Suspense,{fallback:p,children:t.jsx($e,{toolSet:l,onToolSetChange:a})})})}),e[19]=a,e[20]=l,e[21]=x):x=e[21];let u;e[22]!==x||e[23]!==j||e[24]!==y?(u=t.jsxs("div",{className:"flex flex-col h-full",children:[j,y,x]}),e[22]=x,e[23]=j,e[24]=y,e[25]=u):u=e[25];let F;return e[26]!==s||e[27]!==u?(F=t.jsx(Ae,{...s,children:u}),e[26]=s,e[27]=u,e[28]=F):F=e[28],F}function We(o){const{field:e}=o;return t.jsxs(Q,{children:[t.jsxs("div",{className:"flex items-center justify-between gap-3",children:[t.jsx(fe,{className:"mb-0",children:"Gateway Strategy"}),t.jsxs("div",{className:"flex items-center gap-1.5",children:[t.jsx(M,{children:t.jsxs(q,{children:[t.jsx(W,{asChild:!0,children:t.jsx("button",{type:"button",className:"cursor-help flex items-center",children:t.jsx(de,{size:14,className:"text-muted-foreground"})})}),t.jsx(H,{side:"left",className:"max-w-sm",children:t.jsxs("div",{className:"text-xs space-y-1",children:[t.jsxs("div",{children:[t.jsx("strong",{children:"Passthrough:"})," Pass tools through as-is (default)."]}),t.jsxs("div",{children:[t.jsx("strong",{children:"Smart Tool Selection:"})," Intelligent tool selection behavior."]}),t.jsxs("div",{children:[t.jsx("strong",{children:"Code Execution:"})," Code execution behavior."]})]})})]})}),t.jsxs(ue,{value:e.value,onValueChange:e.onChange,children:[t.jsx(X,{children:t.jsx(xe,{className:"w-[180px]",children:t.jsx(he,{})})}),t.jsxs(pe,{children:[t.jsx(K,{value:"passthrough",children:"Passthrough"}),t.jsx(K,{value:"smart_tool_selection",children:"Smart Tool Selection"}),t.jsx(K,{value:"code_execution",children:"Code Execution"})]})]})]})]}),t.jsx(Y,{})]})}function He(o){const{field:e}=o;return t.jsxs(Q,{children:[t.jsxs("div",{className:"flex items-center justify-between gap-3",children:[t.jsx(fe,{className:"mb-0",children:"Tool Selection Mode"}),t.jsxs("div",{className:"flex items-center gap-1.5",children:[t.jsx(M,{children:t.jsxs(q,{children:[t.jsx(W,{asChild:!0,children:t.jsx("button",{type:"button",className:"cursor-help flex items-center",children:t.jsx(de,{size:14,className:"text-muted-foreground"})})}),t.jsx(H,{side:"left",className:"max-w-sm",children:t.jsxs("div",{className:"text-xs space-y-1",children:[t.jsxs("div",{children:[t.jsx("strong",{children:"Include:"})," Only selected connections/tools are exposed."]}),t.jsxs("div",{children:[t.jsx("strong",{children:"Exclude:"})," All connections/tools except selected ones are exposed."]})]})})]})}),t.jsxs(ue,{value:e.value,onValueChange:e.onChange,children:[t.jsx(X,{children:t.jsx(xe,{className:"w-[180px]",children:t.jsx(he,{})})}),t.jsxs(pe,{children:[t.jsx(K,{value:"inclusion",children:"Include Selected"}),t.jsx(K,{value:"exclusion",children:"Exclude Selected"})]})]})]})]}),t.jsx(Y,{})]})}function Ke(o){const{field:e}=o;return t.jsxs(Q,{className:"w-full space-y-0",children:[t.jsx(X,{children:t.jsx(me,{...e,value:e.value||"",className:"h-auto text-base text-muted-foreground leading-6 px-0 border-transparent hover:border-input focus:border-input bg-transparent transition-all",placeholder:"Add a description..."})}),t.jsx(Y,{})]})}function Qe(o){const{field:e}=o;return t.jsxs(Q,{className:"w-full space-y-0",children:[t.jsx(X,{children:t.jsx(me,{...e,className:"h-auto text-lg! font-medium leading-7 px-0 border-transparent hover:border-input focus:border-input bg-transparent transition-all",placeholder:"Gateway Name"})}),t.jsx(Y,{})]})}function Xe(o){const{field:e}=o;return t.jsxs(Q,{children:[t.jsxs("div",{className:"flex items-center gap-2",children:[t.jsx("span",{className:"text-sm text-muted-foreground",children:e.value==="active"?"Active":"Inactive"}),t.jsx(X,{children:t.jsx(Ie,{checked:e.value==="active",onCheckedChange:s=>e.onChange(s?"active":"inactive")})})]}),t.jsx(Y,{})]})}function Ye(o){const e=O.c(53),{gateway:s,gatewayId:l}=o,a=we(),c=Fe();let i;e[0]===Symbol.for("react.memo_cache_sentinel")?(i={},e[0]=i):i=e[0];const f=Te(i);let n;if(e[1]!==f){n=new Map;for(const m of f)m.tools&&m.tools.length>0&&n.set(m.id,m.tools.map(Ze));e[1]=f,e[2]=n}else n=e[2];let r;e[3]!==n||e[4]!==s?(r=()=>Le(s,n),e[3]=n,e[4]=s,e[5]=r):r=e[5];const[d,g]=U.useState(r),[j,y]=U.useState(!1);let p;e[6]===Symbol.for("react.memo_cache_sentinel")?(p=m=>{g(m),y(!0)},e[6]=p):p=e[6];const x=p;let u;e[7]===Symbol.for("react.memo_cache_sentinel")?(u=Ce(Je),e[7]=u):u=e[7];const F=s.tool_selection_mode??"inclusion",R=s.tool_selection_strategy??"passthrough";let z;e[8]!==s.description||e[9]!==s.status||e[10]!==s.title||e[11]!==F||e[12]!==R?(z={resolver:u,defaultValues:{title:s.title,description:s.description,status:s.status,tool_selection_mode:F,tool_selection_strategy:R}},e[8]=s.description,e[9]=s.status,e[10]=s.title,e[11]=F,e[12]=R,e[13]=z):z=e[13];const h=Ne(z),V=h.formState.isDirty||j;let S;e[14]!==c.update||e[15]!==n||e[16]!==h||e[17]!==l||e[18]!==d?(S=async()=>{const m=h.getValues(),P=Me(d,n);await c.update.mutateAsync({id:l,data:{title:m.title,description:m.description,status:m.status,tool_selection_mode:m.tool_selection_mode,tool_selection_strategy:m.tool_selection_strategy,connections:P}}),h.reset(m),y(!1)},e[14]=c.update,e[15]=n,e[16]=h,e[17]=l,e[18]=d,e[19]=S):S=e[19];const G=S;let b;e[20]!==a.history?(b=()=>a.history.back(),e[20]=a.history,e[21]=b):b=e[21];let _;e[22]!==c.update.isPending||e[23]!==G||e[24]!==V?(_=V&&t.jsxs(L,{onClick:G,disabled:c.update.isPending,size:"sm",className:"h-7",children:[c.update.isPending&&t.jsx(le,{size:16,className:"mr-2 animate-spin"}),"Save Changes"]}),e[22]=c.update.isPending,e[23]=G,e[24]=V,e[25]=_):_=e[25];let T;e[26]!==_?(T=t.jsx(De,{children:_}),e[26]=_,e[27]=T):T=e[27];let k;e[28]!==h||e[29]!==s.icon||e[30]!==d?(k=t.jsx("div",{className:"lg:border-r border-b lg:border-b-0 border-border overflow-auto",children:t.jsx(qe,{form:h,toolSet:d,onToolSetChange:x,icon:s.icon})}),e[28]=h,e[29]=s.icon,e[30]=d,e[31]=k):k=e[31];let v;e[32]!==s.id||e[33]!==s.title?(v=s.title||`gateway-${s.id.slice(0,8)}`,e[32]=s.id,e[33]=s.title,e[34]=v):v=e[34];const D=`${window.location.origin}/mcp/gateway/${s.id}`;let w;e[35]!==v||e[36]!==D?(w=t.jsx("div",{className:"p-5",children:t.jsx(Oe,{serverName:v,gatewayUrl:D})}),e[35]=v,e[36]=D,e[37]=w):w=e[37];let I;e[38]===Symbol.for("react.memo_cache_sentinel")?(I=t.jsx("span",{className:"flex-1 text-sm text-foreground",children:"Last Updated"}),e[38]=I):I=e[38];let $;e[39]!==s.updated_at?($=s.updated_at?Be(new Date(s.updated_at),{addSuffix:!1}):"Unknown",e[39]=s.updated_at,e[40]=$):$=e[40];let E;e[41]!==$?(E=t.jsxs("div",{className:"flex items-center gap-4 p-5 border-t border-border",children:[I,t.jsx("span",{className:"text-muted-foreground uppercase text-xs",children:$})]}),e[41]=$,e[42]=E):E=e[42];let C;e[43]!==w||e[44]!==E?(C=t.jsxs("div",{className:"flex flex-col overflow-auto",children:[w,E]}),e[43]=w,e[44]=E,e[45]=C):C=e[45];let N;e[46]!==k||e[47]!==C?(N=t.jsxs("div",{className:"grid grid-cols-1 lg:grid-cols-[2fr_1fr] h-full",children:[k,C]}),e[46]=k,e[47]=C,e[48]=N):N=e[48];let A;return e[49]!==T||e[50]!==N||e[51]!==b?(A=t.jsxs(Pe,{onBack:b,children:[T,N]}),e[49]=T,e[50]=N,e[51]=b,e[52]=A):A=e[52],A}function Ze(o){return o.name}function et(){const o=O.c(8);let e;o[0]===Symbol.for("react.memo_cache_sentinel")?(e={from:"/$org/gateways/$gatewayId"},o[0]=e):e=o[0];const s=be(e);let l;o[1]===Symbol.for("react.memo_cache_sentinel")?(l={from:"/shell/$org/gateways/$gatewayId"},o[1]=l):l=o[1];const{gatewayId:a,org:c}=_e(l),i=Ee(a);if(!i){let n;return o[2]!==s||o[3]!==c?(n=t.jsx("div",{className:"flex h-full w-full bg-background",children:t.jsx(Se,{title:"Gateway not found",description:"This gateway may have been deleted or you may not have access.",actions:t.jsx(L,{variant:"outline",onClick:()=>s({to:"/$org/gateways",params:{org:c}}),children:"Back to gateways"})})}),o[2]=s,o[3]=c,o[4]=n):n=o[4],n}let f;return o[5]!==i||o[6]!==a?(f=t.jsx(Ye,{gateway:i,gatewayId:a}),o[5]=i,o[6]=a,o[7]=f):f=o[7],f}function tt(){const o=O.c(1);let e;return o[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsx(ce,{children:t.jsx(U.Suspense,{fallback:t.jsx("div",{className:"flex h-full items-center justify-center bg-background",children:t.jsx(le,{size:32,className:"animate-spin text-muted-foreground"})}),children:t.jsx(et,{})})}),o[0]=e):e=o[0],e}function Nt(){const o=O.c(1);let e;return o[0]===Symbol.for("react.memo_cache_sentinel")?(e=t.jsx(tt,{}),o[0]=e):e=o[0],e}export{Nt as default};
|