module.exports=[270574,573800,a=>{"use strict";let b=(0,a.i(578447).default)("trash-2",[["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"}]]);a.s(["default",0,b],573800),a.s(["Trash2",0,b],270574)},259067,a=>{"use strict";let b=(0,a.i(578447).default)("loader-circle",[["path",{d:"M21 12a9 9 0 1 1-6.219-8.56",key:"13zald"}]]);a.s(["default",0,b])},421878,a=>{"use strict";var b=a.i(259067);a.s(["Loader2",()=>b.default])},317917,a=>{"use strict";var b=a.i(542082),c=a.i(142261),d=a.i(167418);let e=(0,c.cva)("relative w-full rounded-lg border px-4 py-3 text-sm grid has-[>svg]:grid-cols-[calc(var(--spacing)*4)_1fr] grid-cols-[0_1fr] has-[>svg]:gap-x-3 gap-y-0.5 items-start [&>svg]:size-4 [&>svg]:translate-y-0.5 [&>svg]:text-current",{variants:{variant:{default:"bg-card text-card-foreground",destructive:"text-destructive bg-card [&>svg]:text-current *:data-[slot=alert-description]:text-destructive/90",warning:"text-amber-700 bg-card [&>svg]:text-current *:data-[slot=alert-description]:text-amber-700/90 *:data-[slot=alert-description]:dark:text-amber-300/90 dark:text-amber-300 bg-amber-50 border-amber-200 dark:bg-amber-950/40 dark:border-amber-700"}},defaultVariants:{variant:"default"}});a.s(["Alert",0,function({className:a,variant:c,...f}){return(0,b.jsx)("div",{"data-slot":"alert",role:"alert",className:(0,d.cn)(e({variant:c}),a),...f})},"AlertDescription",0,function({className:a,...c}){return(0,b.jsx)("div",{"data-slot":"alert-description",className:(0,d.cn)("text-muted-foreground col-start-2 grid justify-items-start gap-1 text-sm [&_p]:leading-relaxed",a),...c})},"AlertTitle",0,function({className:a,...c}){return(0,b.jsx)("div",{"data-slot":"alert-title",className:(0,d.cn)("col-start-2 line-clamp-1 min-h-4 font-medium tracking-tight",a),...c})}])},924031,a=>{"use strict";var b=a.i(542082),c=a.i(421878),d=a.i(888890),e=a.i(535567);a.s(["DeleteConfirmation",0,function({itemName:a="this item",isSubmitting:f,onDelete:g,customTitle:h,customDescription:i,children:j}){return(0,b.jsxs)(e.DialogContent,{children:[(0,b.jsx)(e.DialogTitle,{children:h??`Delete ${a}`}),(0,b.jsx)(e.DialogDescription,{className:"whitespace-pre-wrap",children:i??`Are you sure you want to delete ${a}? This action cannot be undone.`}),j,(0,b.jsxs)(e.DialogFooter,{children:[(0,b.jsx)(e.DialogClose,{asChild:!0,children:(0,b.jsx)(d.Button,{variant:"outline",children:"Cancel"})}),(0,b.jsx)(d.Button,{variant:"destructive",onClick:g,disabled:f,children:f?(0,b.jsxs)(b.Fragment,{children:[(0,b.jsx)(c.Loader2,{className:"size-4 animate-spin"})," Deleting..."]}):"Delete"})]})]})}])},30987,180216,a=>{"use strict";var b=a.i(578447);let c=(0,b.default)("file",[["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"}]]);a.s(["default",0,c],30987);let d=(0,b.default)("folder",[["path",{d:"M20 20a2 2 0 0 0 2-2V8a2 2 0 0 0-2-2h-7.9a2 2 0 0 1-1.69-.9L9.6 3.9A2 2 0 0 0 7.93 3H4a2 2 0 0 0-2 2v13a2 2 0 0 0 2 2Z",key:"1kt360"}]]);a.s(["default",0,d],180216)},168524,a=>{"use strict";let b=(0,a.i(578447).default)("folder-open",[["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"}]]);a.s(["default",0,b])},23895,a=>{"use strict";var b=a.i(542082),c=a.i(607410),d=a.i(284141),e=a.i(225526),f=a.i(952313),g=a.i(317917),h=a.i(924031),i=a.i(535567),j=a.i(713116);let k=(0,j.createServerReference)("7015dc17c745d9b8a3b5da97aa8e35f43efd05d30c",j.callServer,void 0,j.findSourceMapURL,"deleteSkill");a.s(["DeleteSkillConfirmation",0,({skillId:a,setIsOpen:j,redirectOnDelete:l=!0})=>{let m=(0,d.useRouter)(),{tenantId:n,projectId:o}=(0,d.useParams)(),[p,q]=(0,e.useTransition)();return(0,b.jsx)(i.Dialog,{open:!0,onOpenChange:j,children:(0,b.jsx)(h.DeleteConfirmation,{itemName:a,isSubmitting:p,onDelete:function(){q(async()=>{try{await k(n,o,a)}catch(a){f.toast.error(a instanceof Error?a.message:"Failed to delete skill");return}f.toast.success(`Skill "${a}" deleted.`),j(!1),l&&m.push(`/${n}/projects/${o}/skills`)})},customTitle:"Delete skill",customDescription:`This will remove "${a}" skill.
Sub-agents using this skill will lose access.`,children:(0,b.jsxs)(g.Alert,{variant:"warning",children:[(0,b.jsx)(c.AlertTriangle,{}),(0,b.jsx)(g.AlertTitle,{children:"All files in this skill will be permanently deleted."}),(0,b.jsx)(g.AlertDescription,{children:"This action cannot be undone."})]})})})}],23895)},69881,115195,774139,401395,a=>{"use strict";var b=a.i(30987);a.s(["File",()=>b.default],69881);var c=a.i(180216);a.s(["Folder",()=>c.default],115195);var d=a.i(542082),e=a.i(284141),f=a.i(225526),g=a.i(952313),h=a.i(924031),i=a.i(535567),j=a.i(713116);let k=(0,j.createServerReference)("7c06184775c21be296146ffc24cfadf5f1603d5ebd",j.callServer,void 0,j.findSourceMapURL,"deleteSkillFileAction");a.s(["DeleteSkillFileConfirmation",0,({skillId:a,fileId:b,filePath:c,redirectPath:j,setIsOpen:l})=>{let{tenantId:m,projectId:n}=(0,e.useParams)(),o=(0,e.useRouter)(),[p,q]=(0,f.useTransition)();return(0,d.jsx)(i.Dialog,{open:!0,onOpenChange:l,children:(0,d.jsx)(h.DeleteConfirmation,{itemName:c,isSubmitting:p,onDelete:function(){q(async()=>{let d=await k(m,n,a,b,c);d.success?(g.toast.success(`Removed ${c}`),l(!1),j&&o.push(j),o.refresh()):g.toast.error(d.error??"Failed to remove skill file")})},customTitle:"Remove file",customDescription:`Remove "${c}" from this skill? This action cannot be undone.`})})}],774139),a.i(562366);var l=a.i(511279);function m(a){return a===l.SKILL_ENTRY_FILE_PATH}function n(a){return a.split("/").filter(Boolean).map(a=>encodeURIComponent(a)).join("/")}a.s(["buildNewSkillFileHref",0,function(a,b,c,d){let e=d?`/${n(d)}`:"";return`/${a}/projects/${b}/skills/new/${encodeURIComponent(c)}${e}`},"buildSkillFileViewHref",0,function(a,b,c,d){return`/${a}/projects/${b}/skills/files/${n(m(d)?c:`${c}/${d}`)}`},"buildSkillFolderViewHref",0,function(a,b,c,d){return`/${a}/projects/${b}/skills/folders/${n([c,d].filter(Boolean).join("/"))}`},"getSkillFileEditorUri",0,function(a){let b=a.replace(/[^a-zA-Z0-9.-]+/g,"-").replace(/\.[^.]+$/,"")||"skill-file";return a.endsWith(".md")?`${b}.md`:`${b}.template`},"getSkillFileParentDirectory",0,function(a){return a.split("/").filter(Boolean).slice(0,-1).join("/")},"getSkillFileRemovalLabel",0,function(a){return m(a)?"Delete skill":"Remove file"},"isSkillEntryFile",0,m],401395)}];

//# sourceMappingURL=_0yokhp5._.js.map