@whoz-oss/coday-client 0.0.0-workstream-forge.94 → 0.0.0-workstream-forge.95
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/browser/{chunk-B3baCRtb.js → chunk-9Na9wjEm.js} +1 -1
- package/browser/{chunk-CCHGxQwW.js → chunk-AB90cbB_.js} +1 -1
- package/browser/{chunk-7mdb_4mR.js → chunk-B-fXjnGz.js} +1 -1
- package/browser/{chunk-CjmliJcM.js → chunk-B7-BsDPf.js} +1 -1
- package/browser/{chunk-B-MDIiFA.js → chunk-B7sy8z4M.js} +1 -1
- package/browser/{chunk-C3w6kqV4.js → chunk-B9NACwUM.js} +1 -1
- package/browser/{chunk-WZ8ibLUm.js → chunk-B9bBPCOE.js} +1 -1
- package/browser/{chunk-CMcuhZca.js → chunk-BAGLvfTc.js} +1 -1
- package/browser/{chunk-UXySco7a.js → chunk-BBgiMYAx.js} +1 -1
- package/browser/{chunk-DZuzGTyw.js → chunk-BDPQgAAh.js} +1 -1
- package/browser/{chunk-g2KeqoSd.js → chunk-BJLKDKZZ.js} +1 -1
- package/browser/{chunk-4wXLkIgQ.js → chunk-BMUzpXmO.js} +1 -1
- package/browser/{chunk-Cn8R85n1.js → chunk-BYz2GJqY.js} +1 -1
- package/browser/{chunk-Bk3NqrnA.js → chunk-BbkpDuKm.js} +1 -1
- package/browser/{chunk-EaGpSLvo.js → chunk-Bbxz2alX.js} +1 -1
- package/browser/{chunk-C3dC15Cy.js → chunk-BgIYpV8F.js} +1 -1
- package/browser/{chunk-BdzUnayP.js → chunk-BhUi8VTd.js} +1 -1
- package/browser/{chunk-C9DRVPq2.js → chunk-BhsX6u7d.js} +1 -1
- package/browser/{chunk-DV5rOgFh.js → chunk-BmcMTmtD.js} +1 -1
- package/browser/{chunk-DyTaDs8R.js → chunk-BsG3PR--.js} +1 -1
- package/browser/{chunk-CEtg3c_H.js → chunk-BuCqp2zT.js} +1 -1
- package/browser/{chunk-7BX4gbCT.js → chunk-BvEhsGlp.js} +1 -1
- package/browser/{chunk-9xjn8Egf.js → chunk-C-3vHP5P.js} +1 -1
- package/browser/{chunk-B68rmVfl.js → chunk-C1PnQMtv.js} +1 -1
- package/browser/{chunk-G8AvIixl.js → chunk-C2_EBwWe.js} +1 -1
- package/browser/{chunk-B9R_DbfC.js → chunk-C3Sgc5rR.js} +1 -1
- package/browser/{chunk-Dl6jjuEM.js → chunk-C9sVqRdl.js} +1 -1
- package/browser/{chunk-DxysADy-.js → chunk-CMF1Mk9-.js} +1 -1
- package/browser/{chunk-CXywabYk.js → chunk-CPWl0V02.js} +1 -1
- package/browser/{chunk-Egf0g5_d.js → chunk-CPfRkt67.js} +1 -1
- package/browser/{chunk-DyMrbDO9.js → chunk-CSDBfCII.js} +1 -1
- package/browser/{chunk-C7oAHrH-.js → chunk-CX5D6OMW.js} +1 -1
- package/browser/{chunk-DUYMjeQJ.js → chunk-Cbvrb66H.js} +1 -1
- package/browser/{chunk-CGGV0vF4.js → chunk-CcfHhZEc.js} +1 -1
- package/browser/{chunk-CsyzylmW.js → chunk-Cd2wDBwK.js} +1 -1
- package/browser/{chunk-D1nZmts_.js → chunk-CigBS2kT.js} +7 -7
- package/browser/{chunk-Csa3hGs7.js → chunk-CmC0cVBl.js} +1 -1
- package/browser/{chunk-XpIi-MBQ.js → chunk-CnOd7CqJ.js} +1 -1
- package/browser/{chunk-DyyzL0tV.js → chunk-CtPtPfVh.js} +1 -1
- package/browser/{chunk-Doe9Up4y.js → chunk-CxSFWP2r.js} +1 -1
- package/browser/{chunk-BzU4ht22.js → chunk-D-l8Hr5w.js} +1 -1
- package/browser/{chunk-w0oeabgA.js → chunk-D22tCCQt.js} +1 -1
- package/browser/{chunk-AQsKVA6d.js → chunk-D3d5Wakn.js} +1 -1
- package/browser/{chunk-BojVkIWl.js → chunk-D6D0Z7ht.js} +1 -1
- package/browser/{chunk-D4oFaPAv.js → chunk-D84a_Xjq.js} +1 -1
- package/browser/{chunk-DurvOM6S.js → chunk-DCpiwt2H.js} +1 -1
- package/browser/{chunk-DqE2HsdR.js → chunk-DGq9evlM.js} +1 -1
- package/browser/{chunk-CJGaU-bS.js → chunk-DL5nsVeX.js} +1 -1
- package/browser/{chunk-BXFaW6J1.js → chunk-DOy5wwe3.js} +1 -1
- package/browser/{chunk-dBRlMEQQ.js → chunk-DPXq5z3x.js} +1 -1
- package/browser/{chunk-BgPtK78d.js → chunk-DZ-pYFnN.js} +1 -1
- package/browser/{chunk-C1w_QGS2.js → chunk-DZdAT-59.js} +1 -1
- package/browser/{chunk-D56Lf-dS.js → chunk-Da3C0oKy.js} +1 -1
- package/browser/{chunk-DXWpj06A.js → chunk-DhTfuwxD.js} +1 -1
- package/browser/{chunk-BKXvmkUu.js → chunk-DjCoQGhe.js} +1 -1
- package/browser/{chunk-CUA4cnMp.js → chunk-DlxQJ0Wq.js} +1 -1
- package/browser/{chunk-Dl-2liq_.js → chunk-Dn9qyCI-.js} +1 -1
- package/browser/{chunk-BTUoK8fP.js → chunk-DoK-l333.js} +1 -1
- package/browser/{chunk-nXl61KvO.js → chunk-Dx5UtZ5A.js} +1 -1
- package/browser/{chunk-B5idR_PH.js → chunk-DystVA5E.js} +1 -1
- package/browser/{chunk-DX_Vo3Ef.js → chunk-DywMt_F6.js} +1 -1
- package/browser/{chunk-Dsb0cbz7.js → chunk-DzLzwtOe.js} +1 -1
- package/browser/{chunk-KWNHQk-V.js → chunk-JZld8hhU.js} +1 -1
- package/browser/chunk-KsDoJ6rD.js +1 -0
- package/browser/{chunk-DKB_-5nU.js → chunk-MAe7L4co.js} +1 -1
- package/browser/{chunk-M_1EV2Ae.js → chunk-MHk6Nl7A.js} +1 -1
- package/browser/{chunk-BNoigwlG.js → chunk-QK8tU1La.js} +1 -1
- package/browser/{chunk-TFMuQzlk.js → chunk-SHexpzTz.js} +1 -1
- package/browser/{chunk-k5Amgaum.js → chunk-ZC1xA4AE.js} +1 -1
- package/browser/{chunk-0K1upHa9.js → chunk-ZK5QaNGY.js} +1 -1
- package/browser/{chunk-csI-VsQo.js → chunk-juX0bStc.js} +1 -1
- package/browser/index.html +1 -1
- package/browser/{main-NF2IMZ2D.js → main-CB44G2DK.js} +1 -1
- package/package.json +1 -1
- package/browser/chunk-YQeiGavg.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import {z}from'./chunk-
|
|
1
|
+
import {z}from'./chunk-C3Sgc5rR.js';import {s}from'./chunk-D22tCCQt.js';import {g as g$1,F,P,R as Re,C as Ce,a as F$1,m as mT,x,w,ae as kt,b as U,e as xw,j as Gn,$ as $t,k as ws,q as Rg,S as Sg,o as pl,af as Eg,ag as fT,t as CC,X as XE,u as bg,a9 as lC,aa as If,ac as gC,ab as wf,n as GC,ah as rT}from'./main-CB44G2DK.js';import'./chunk-D6D0Z7ht.js';import {$ as $n,o as ot}from'./chunk-CnOd7CqJ.js';import'./chunk-JZld8hhU.js';import {y as yt,w as wt}from'./chunk-BDPQgAAh.js';var ee=()=>[];function te(u,t){if(u&1){let o=lC();ws(0,"div",5)(1,"ds-entity-card",6),Rg("selected",function(r){If(o);let i=gC();return wf(i.onItemSelected(r))}),pl(),ws(2,"button",7),Rg("click",function(r){let i=If(o).$implicit,f=gC();return r.stopPropagation(),wf(f.onDeleteRequested(i.id))}),ws(3,"mat-icon"),GC(4,"close"),pl()()();}if(u&2){let o=t.$implicit;XE(),bg("id",o.id)("name",o.name)("description",o.description)("badges",o.badges??rT(4,ee));}}var g="__",Y=class u{router=g$1(F);projectStateService=g$1(P);dialog=g$1(Re);destroyRef=g$1(Ce);notification=g$1(s);projects=F$1(this.projectStateService.projectList$);forcedProject=F$1(this.projectStateService.forcedProject$,{initialValue:null});isLoading=F$1(this.projectStateService.isLoading$,{initialValue:false});projectItems=mT(()=>{let t=this.projects();if(!t)return [];let o=t.filter(e=>!e.name.includes(g)),n=t.filter(e=>e.name.includes(g)),r=new Set(o.map(e=>e.name)),i=e=>e.split(g)[0]??null,f=new Set(n.map(e=>i(e.name)).filter(e=>e!==null&&r.has(e))),l=[],G=[...f].sort((e,a)=>e.localeCompare(a));for(let e of G){let a=o.find(s=>s.name===e);l.push(x(w({},this.toEntityListItem(a)),{groupKey:e,groupLabel:e}));let Z=n.filter(s=>i(s.name)===e).sort((s,C)=>s.name.localeCompare(C.name));for(let s of Z){let C=s.name.slice(e.length+g.length);l.push(x(w({},this.toEntityListItem(s)),{name:C,description:s.name,groupKey:e,groupLabel:e}));}}let H=[...o].filter(e=>!f.has(e.name)&&!e.volatile).sort((e,a)=>e.name.localeCompare(a.name));for(let e of H)l.push(x(w({},this.toEntityListItem(e)),{groupKey:"__standalone__",groupLabel:"Projects"}));let Q=[...o].filter(e=>!f.has(e.name)&&e.volatile).sort((e,a)=>e.name.localeCompare(a.name));for(let e of Q)l.push(x(w({},this.toEntityListItem(e)),{groupKey:"__volatile__",groupLabel:"Temporary"}));let X=n.filter(e=>{let a=i(e.name);return a!==null&&!r.has(a)}).sort((e,a)=>e.name.localeCompare(a.name));for(let e of X)l.push(x(w({},this.toEntityListItem(e)),{groupKey:"__orphaned__",groupLabel:"Orphaned worktrees"}));return l});showCreateButton=mT(()=>!this.forcedProject());constructor(){}onItemSelected(t){this.projectStateService.selectProject(t),this.router.navigate(["project",t]);}onCreateRequested(){this.router.navigate(["project","new"]);}onDeleteRequested(t){let o=t.includes(g);this.dialog.open(z,{width:"400px",panelClass:"confirm-dialog-panel",data:w({title:"Delete project",message:`This will remove the project "${t}" from Coday and archive its configuration. The project source code on disk is not affected.`,confirmLabel:"Delete",cancelLabel:"Cancel",isDestructive:true},o?{checkboxLabel:"Also remove git worktree from disk"}:{})}).afterClosed().pipe(kt(r=>r?.confirmed===true),U(this.destroyRef)).subscribe(r=>{this.notification.info("Deleting project\u2026"),this.projectStateService.deleteProject(t,r.checkboxChecked).pipe(U(this.destroyRef)).subscribe({next:()=>{this.notification.success(`Project "${t}" deleted`),this.router.url.includes(`/project/${encodeURIComponent(t)}`)&&this.router.navigate(["/"]);},error:i=>{console.error("[PROJECT-LIST] Failed to delete project:",i),this.notification.error(i?.error?.error??"Failed to delete project");}});});}toEntityListItem(t){return {id:t.name,name:t.name,badges:t.volatile?[{label:"temp",variant:"warning"}]:[]}}static \u0275fac=function(o){return new(o||u)};static \u0275cmp=xw({type:u,selectors:[["app-project-selection"]],decls:6,vars:5,consts:[["projectCard",""],[1,"project-page-layout"],["title","Projects","contentMaxWidth","1400px","searchPlaceholder","Filter projects\u2026","emptyMessage","No projects found.",3,"itemSelected","createRequested","items","loading","itemTemplate","showCreate","autoFocusSearch"],["toolbar-start","","routerLink","/","title","Back to tasks",1,"project-list__logo"],["src","CODAY-Logo.png","alt","Coday"],[1,"project-card-wrapper"],[3,"selected","id","name","description","badges"],["mat-icon-button","","title","Delete project",1,"project-card-wrapper__delete",3,"click"]],template:function(o,n){if(o&1&&(ws(0,"div",1)(1,"ds-entity-list",2),Rg("itemSelected",function(i){return n.onItemSelected(i)})("createRequested",function(){return n.onCreateRequested()}),ws(2,"a",3),Sg(3,"img",4),pl()()(),Eg(4,te,5,5,"ng-template",null,0,fT)),o&2){let r=CC(5);XE(),bg("items",n.projectItems())("loading",n.isLoading())("itemTemplate",r)("showCreate",n.showCreateButton())("autoFocusSearch",true);}},dependencies:[$n,ot,yt,wt,Gn,$t],styles:["[_nghost-%COMP%]{display:block;width:100%;min-height:100vh;background:var(--color-bg);overflow-y:auto}.project-page-layout[_ngcontent-%COMP%]{display:flex;flex-direction:column;width:100%}.project-list__logo[_ngcontent-%COMP%]{display:flex;align-items:center;flex-shrink:0;border-radius:4px;opacity:.85;transition:opacity .15s ease;cursor:pointer}.project-list__logo[_ngcontent-%COMP%]:hover{opacity:1}.project-list__logo[_ngcontent-%COMP%] img[_ngcontent-%COMP%]{width:40px;height:40px;object-fit:contain;border-radius:4px}.project-card-wrapper[_ngcontent-%COMP%]{position:relative}.project-card-wrapper__delete[_ngcontent-%COMP%]{position:absolute;top:4px;right:4px;width:28px;height:28px;line-height:28px;padding:0;opacity:0;transition:opacity .15s ease;color:var(--color-text-secondary, #6e6e73)}.project-card-wrapper__delete[_ngcontent-%COMP%] .mat-icon[_ngcontent-%COMP%]{font-size:16px;width:16px;height:16px}.project-card-wrapper__delete[_ngcontent-%COMP%]:hover{color:var(--color-error, #ff3b30)}.project-card-wrapper[_ngcontent-%COMP%]:hover .project-card-wrapper__delete[_ngcontent-%COMP%]{opacity:1}"],changeDetection:1})};export{Y as ProjectListComponent};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import {d}from'./chunk-D1nZmts_.js';import {g,ao as W$1,F,C as Ce,da as $$1,G as Gi,m as mT,b as U$1,e as xw,$ as $t,k as ws,q as Rg,n as GC,o as pl,J as Jw,X as XE,u as bg,v as eC,ac as gC,a8 as Yg,z as Ug,a5 as vl,a9 as lC,T as Tg,s as rC,y as oC,S as Sg,bf as aT,bg as uT,aa as If,ab as wf,bj as aE}from'./main-NF2IMZ2D.js';import'./chunk-Dsb0cbz7.js';import'./chunk-XpIi-MBQ.js';import'./chunk-KWNHQk-V.js';import'./chunk-DZuzGTyw.js';var $=(n,o)=>o.id,B=(n,o)=>o.name;function j(n,o){n&1&&(ws(0,"p",6),GC(1,"Loading\u2026"),pl());}function H(n,o){n&1&&(ws(0,"p",7),GC(1,"Failed to load agent definition."),pl());}function J(n,o){if(n&1&&(ws(0,"dt",12),GC(1,"User context"),pl(),ws(2,"dd",14),GC(3),pl()),n&2){let e=gC();XE(3),Yg(e.userId);}}function U(n,o){if(n&1&&(ws(0,"pre",22),GC(1),pl()),n&2){let e=gC(2);XE(),Yg(e.systemPrompt);}}function G(n,o){if(n&1){let e=lC();ws(0,"section",9)(1,"button",20),Rg("click",function(){If(e);let p=gC(2);return wf(p.toggleSystemPrompt())}),ws(2,"h2",10),GC(3,"System Prompt"),pl(),ws(4,"span",21),GC(5," \u25BC "),pl()(),Jw(6,U,2,1,"pre",22),pl();}if(n&2){let e=gC(2);XE(),Tg("aria-expanded",!e.systemPromptCollapsed()),XE(3),Ug("agent-config-inspect__chevron--open",!e.systemPromptCollapsed()),XE(2),eC(e.systemPromptCollapsed()?-1:6);}}function K(n,o){if(n&1&&(ws(0,"pre",22),GC(1),pl()),n&2){let e=gC(2);XE(),Yg(e.instructions);}}function q(n,o){if(n&1){let e=lC();ws(0,"section",9)(1,"button",20),Rg("click",function(){If(e);let p=gC(2);return wf(p.toggleInstructions())}),ws(2,"h2",10),GC(3,"Instructions"),pl(),ws(4,"span",21),GC(5," \u25BC "),pl()(),Jw(6,K,2,1,"pre",22),pl();}if(n&2){let e=gC(2);XE(),Tg("aria-expanded",!e.instructionsCollapsed()),XE(3),Ug("agent-config-inspect__chevron--open",!e.instructionsCollapsed()),XE(2),eC(e.instructionsCollapsed()?-1:6);}}function Q(n,o){n&1&&(ws(0,"p",17),GC(1," This agent declares no skill, so it gets no skill tools. Attach skills from the edit form. "),pl());}function W(n,o){n&1&&(ws(0,"span",25),GC(1,"platform"),pl());}function X(n,o){n&1&&(ws(0,"span",25),GC(1,"SKILL.md"),pl());}function Y(n,o){if(n&1&&(ws(0,"li",23)(1,"span",24),GC(2),pl(),Jw(3,W,2,0,"span",25),Jw(4,X,2,0,"span",25),ws(5,"p",26),GC(6),pl()()),n&2){let e=o.$implicit;XE(2),Yg(e.name),XE(),eC(e.namespaceId?-1:3),XE(),eC(e.readOnly?4:-1),XE(2),Yg(e.description);}}function Z(n,o){if(n&1&&(ws(0,"ul",18),rC(1,Y,7,4,"li",23,$),pl()),n&2){let e=gC(2);XE(),oC(e.resolvedSkills());}}function ee(n,o){n&1&&(ws(0,"p",17),GC(1,"No tools available for this agent."),pl());}function ne(n,o){if(n&1&&(Sg(0,"div",31),aT(1,"agentosMarkdown")),n&2){let e=gC(2).$implicit;bg("innerHTML",uT(1,1,e.description),aE);}}function te(n,o){if(n&1&&(ws(0,"div",30),Jw(1,ne,2,3,"div",31),ws(2,"pre",32),GC(3),pl()()),n&2){let e=gC().$implicit,c=gC(3);XE(),eC(e.description?1:-1),XE(2),Yg(c.formatSchema(e.inputSchema));}}function ie(n,o){if(n&1){let e=lC();ws(0,"li",27)(1,"button",28),Rg("click",function(){let p=If(e).$implicit,V=gC(3);return wf(V.toggleTool(p))}),ws(2,"span",29),GC(3),pl(),ws(4,"span",21),GC(5," \u25BC "),pl()(),Jw(6,te,4,2,"div",30),pl();}if(n&2){let e=o.$implicit,c=gC(3);XE(),Tg("aria-expanded",c.isToolExpanded(e)),XE(2),Yg(e.name),XE(),Ug("agent-config-inspect__chevron--open",c.isToolExpanded(e)),XE(2),eC(c.isToolExpanded(e)?6:-1);}}function oe(n,o){if(n&1&&(ws(0,"ul",19),rC(1,ie,7,5,"li",27,B),pl()),n&2){let e=gC();XE(),oC(e.tools);}}function ae(n,o){if(n&1&&(ws(0,"div",8)(1,"section",9)(2,"h2",10),GC(3,"General"),pl(),ws(4,"dl",11)(5,"dt",12),GC(6,"Name"),pl(),ws(7,"dd",13),GC(8),pl(),ws(9,"dt",12),GC(10,"Resolved model"),pl(),ws(11,"dd",14),GC(12),pl(),ws(13,"dt",12),GC(14,"Provider"),pl(),ws(15,"dd",13),GC(16),pl(),ws(17,"dt",12),GC(18,"Advanced execution"),pl(),ws(19,"dd",13)(20,"span",15),GC(21),pl()(),Jw(22,J,4,1),pl()(),Jw(23,G,7,4,"section",9),Jw(24,q,7,4,"section",9),ws(25,"section",9)(26,"h2",10),GC(27," Skills "),ws(28,"span",16),GC(29),pl()(),Jw(30,Q,2,0,"p",17)(31,Z,3,0,"ul",18),pl(),ws(32,"section",9)(33,"h2",10),GC(34," Tools "),ws(35,"span",16),GC(36),pl()(),Jw(37,ee,2,0,"p",17)(38,oe,3,0,"ul",19),pl()()),n&2){let e=o,c=gC();XE(8),Yg(e.name),XE(4),Yg(e.resolvedModelApiName),XE(4),Yg(e.resolvedProviderName),XE(4),Ug("agent-config-inspect__badge--active",e.advancedExecution),XE(),vl(" ",e.advancedExecution?"Enabled":"Disabled"," "),XE(),eC(e.userId?22:-1),XE(),eC(e.systemPrompt?23:-1),XE(),eC(e.instructions?24:-1),XE(5),vl("(",c.resolvedSkills().length,")"),XE(),eC(c.resolvedSkills().length===0?30:31),XE(6),vl("(",e.tools.length,")"),XE(),eC(e.tools.length===0?37:38);}}var R=class n{route=g(W$1);router=g(F);destroyRef=g(Ce);agentConfigController=g($$1);namespaceId=this.route.snapshot.params.namespaceId;agentConfigId=this.route.snapshot.params.agentConfigId;isPlatformMode=!this.namespaceId;isLoading=Gi(true);hasError=Gi(false);definition=Gi(null);expandedTools=Gi(new Set);resolvedSkills=mT(()=>this.definition()?.skills??[]);systemPromptCollapsed=Gi(true);instructionsCollapsed=Gi(true);ngOnInit(){this.agentConfigController.getDefinitionAgentConfig(this.agentConfigId).pipe(U$1(this.destroyRef)).subscribe({next:o=>{this.definition.set(o),this.isLoading.set(false);},error:()=>{this.hasError.set(true),this.isLoading.set(false);}});}toggleTool(o){this.expandedTools.update(e=>{let c=new Set(e);return c.has(o.name)?c.delete(o.name):c.add(o.name),c});}isToolExpanded(o){return this.expandedTools().has(o.name)}toggleSystemPrompt(){this.systemPromptCollapsed.update(o=>!o);}toggleInstructions(){this.instructionsCollapsed.update(o=>!o);}formatSchema(o){try{return JSON.stringify(JSON.parse(o),null,2)}catch(e){return o}}editRoute(){return this.isPlatformMode?["/agentos","admin","agent-configs",this.agentConfigId,"edit"]:["/agentos",this.namespaceId,"agent-configs",this.agentConfigId,"edit"]}back(){this.isPlatformMode?this.router.navigate(["/agentos","admin","agent-configs"]):this.router.navigate(["/agentos",this.namespaceId,"agent-configs"]);}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=xw({type:n,selectors:[["agentos-agent-config-inspect"]],decls:13,vars:2,consts:[[1,"agent-config-inspect"],[1,"agent-config-inspect__header"],["type","button","title","Back to agent configs",1,"agent-config-inspect__back",3,"click"],[1,"agent-config-inspect__back-icon"],[1,"agent-config-inspect__title"],[1,"agent-config-inspect__sibling-link",3,"routerLink"],[1,"agent-config-inspect__loading"],[1,"agent-config-inspect__error"],[1,"agent-config-inspect__content"],[1,"agent-config-inspect__section"],[1,"agent-config-inspect__section-title"],[1,"agent-config-inspect__dl"],[1,"agent-config-inspect__dt"],[1,"agent-config-inspect__dd"],[1,"agent-config-inspect__dd","agent-config-inspect__dd--mono"],[1,"agent-config-inspect__badge"],[1,"agent-config-inspect__count"],[1,"agent-config-inspect__empty"],[1,"agent-config-inspect__skills"],[1,"agent-config-inspect__tools"],["type","button",1,"agent-config-inspect__collapsible",3,"click"],[1,"agent-config-inspect__chevron"],[1,"agent-config-inspect__instructions"],[1,"agent-config-inspect__skill"],[1,"agent-config-inspect__skill-name"],[1,"agent-config-inspect__skill-badge"],[1,"agent-config-inspect__skill-desc"],[1,"agent-config-inspect__tool"],["type","button",1,"agent-config-inspect__tool-header",3,"click"],[1,"agent-config-inspect__tool-name"],[1,"agent-config-inspect__tool-body"],[1,"agent-config-inspect__tool-description",3,"innerHTML"],[1,"agent-config-inspect__schema"]],template:function(e,c){if(e&1&&(ws(0,"div",0)(1,"header",1)(2,"button",2),Rg("click",function(){return c.back()}),ws(3,"span",3),GC(4,"\u2190"),pl(),GC(5," Agent Configs "),pl(),ws(6,"h1",4),GC(7,"Agent definition"),pl(),ws(8,"a",5),GC(9,"Edit config \u2192"),pl()(),Jw(10,j,2,0,"p",6)(11,H,2,0,"p",7)(12,ae,39,13,"div",8),pl()),e&2){let p;XE(8),bg("routerLink",c.editRoute()),XE(2),eC(c.isLoading()?10:c.hasError()?11:(p=c.definition())?12:-1,p);}},dependencies:[$t,d],styles:[".agent-config-inspect[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:2rem;max-width:720px;margin:0 auto;padding:2rem 1rem}.agent-config-inspect__header[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.agent-config-inspect__back[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:.375rem;background:none;border:none;padding:0;cursor:pointer;font-size:.875rem;color:var(--color-primary, #007aff);font-family:inherit}.agent-config-inspect__back[_ngcontent-%COMP%]:hover{text-decoration:underline}.agent-config-inspect__back-icon[_ngcontent-%COMP%]{font-size:1rem;line-height:1}.agent-config-inspect__title[_ngcontent-%COMP%]{margin:0;font-size:1.5rem;font-weight:600;color:var(--color-text, #1d1d1f);letter-spacing:-.02em}.agent-config-inspect__sibling-link[_ngcontent-%COMP%]{font-size:.8125rem;color:var(--color-primary, #007aff);text-decoration:none}.agent-config-inspect__sibling-link[_ngcontent-%COMP%]:hover{text-decoration:underline}.agent-config-inspect__loading[_ngcontent-%COMP%], .agent-config-inspect__error[_ngcontent-%COMP%], .agent-config-inspect__empty[_ngcontent-%COMP%]{margin:0;font-size:.9rem;color:var(--color-text-secondary, #6e6e73)}.agent-config-inspect__error[_ngcontent-%COMP%]{color:var(--color-error, #ff3b30)}.agent-config-inspect__content[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.agent-config-inspect__section[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.75rem;padding:1.25rem;border:1px solid var(--color-border, rgba(0, 0, 0, .1));border-radius:10px}.agent-config-inspect__section-title[_ngcontent-%COMP%]{margin:0;font-size:.9375rem;font-weight:600;color:var(--color-text, #1d1d1f)}.agent-config-inspect__count[_ngcontent-%COMP%]{font-weight:400;color:var(--color-text-secondary, #6e6e73);font-size:.875rem;margin-left:.25rem}.agent-config-inspect__dl[_ngcontent-%COMP%]{display:grid;grid-template-columns:max-content 1fr;gap:.5rem 1.25rem;margin:0}.agent-config-inspect__dt[_ngcontent-%COMP%]{font-size:.8125rem;font-weight:500;color:var(--color-text-secondary, #6e6e73);align-self:center}.agent-config-inspect__dd[_ngcontent-%COMP%]{margin:0;font-size:.9375rem;color:var(--color-text, #1d1d1f);align-self:center;word-break:break-word}.agent-config-inspect__dd--mono[_ngcontent-%COMP%]{font-family:monospace;font-size:.875rem}.agent-config-inspect__badge[_ngcontent-%COMP%]{display:inline-block;padding:.2em .6em;border-radius:4px;font-size:.75rem;font-weight:500;background:var(--color-surface-muted, rgba(0, 0, 0, .06));color:var(--color-text-secondary, #6e6e73)}.agent-config-inspect__badge--active[_ngcontent-%COMP%]{background:var(--color-success-bg, #e3f5e1);color:var(--color-success, #34c759)}.agent-config-inspect__collapsible[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:.5rem;width:100%;background:none;border:none;padding:0;cursor:pointer;font-family:inherit;text-align:left}.agent-config-inspect__chevron[_ngcontent-%COMP%]{font-size:.7rem;color:var(--color-text-secondary, #6e6e73);transition:transform .15s ease;flex-shrink:0}.agent-config-inspect__chevron--open[_ngcontent-%COMP%]{transform:rotate(180deg)}.agent-config-inspect__instructions[_ngcontent-%COMP%]{margin:0;padding:.875rem 1rem;border-radius:6px;background:var(--color-surface-muted, rgba(0, 0, 0, .04));font-size:.875rem;font-family:inherit;color:var(--color-text, #1d1d1f);white-space:pre-wrap;word-break:break-word;line-height:1.6;max-height:400px;overflow-y:auto}.agent-config-inspect__tools[_ngcontent-%COMP%], .agent-config-inspect__skills[_ngcontent-%COMP%]{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:.5rem}.agent-config-inspect__skill[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;align-items:baseline;gap:.5rem}.agent-config-inspect__skill-name[_ngcontent-%COMP%]{font-size:.9rem;font-weight:500}.agent-config-inspect__skill-badge[_ngcontent-%COMP%]{font-size:.75rem;font-family:monospace;color:var(--color-text-secondary, #6e6e73)}.agent-config-inspect__skill-desc[_ngcontent-%COMP%]{flex:1 1 100%;margin:0;font-size:.8rem;color:var(--color-text-secondary, #6e6e73);line-height:1.4}.agent-config-inspect__tool[_ngcontent-%COMP%]{border:1px solid var(--color-border, rgba(0, 0, 0, .08));border-radius:6px;overflow:hidden}.agent-config-inspect__tool-header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:.75rem;width:100%;padding:.75rem 1rem;background:none;border:none;cursor:pointer;font-family:inherit;text-align:left;transition:background .1s ease}.agent-config-inspect__tool-header[_ngcontent-%COMP%]:hover{background:var(--color-surface-hover, rgba(0, 0, 0, .04))}.agent-config-inspect__tool-name[_ngcontent-%COMP%]{font-size:.875rem;font-weight:600;font-family:monospace;color:var(--color-text, #1d1d1f);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.agent-config-inspect__tool-body[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;padding:0 1rem .75rem;border-top:1px solid var(--color-border, rgba(0, 0, 0, .08))}.agent-config-inspect__tool-description[_ngcontent-%COMP%]{margin:0;padding-top:.75rem;font-size:.8125rem;line-height:1.5;color:var(--color-text-secondary, #6e6e73)}.agent-config-inspect__tool-description[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0 0 .25rem}.agent-config-inspect__tool-description[_ngcontent-%COMP%] p[_ngcontent-%COMP%]:last-child{margin-bottom:0}.agent-config-inspect__tool-description[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{font-family:monospace;font-size:.8em;background:var(--color-surface-muted, rgba(0, 0, 0, .06));padding:.1em .3em;border-radius:3px}.agent-config-inspect__schema[_ngcontent-%COMP%]{margin:0;padding:.875rem 1rem;background:var(--color-surface-muted, rgba(0, 0, 0, .04));font-size:.8125rem;font-family:monospace;color:var(--color-text, #1d1d1f);white-space:pre;overflow-x:auto;line-height:1.5;max-height:360px;overflow-y:auto}"]})};export{R as AgentConfigInspectComponent};
|
|
1
|
+
import {d}from'./chunk-CigBS2kT.js';import {g,ao as W$1,F,C as Ce,da as $$1,G as Gi,m as mT,b as U$1,e as xw,$ as $t,k as ws,q as Rg,n as GC,o as pl,J as Jw,X as XE,u as bg,v as eC,ac as gC,a8 as Yg,z as Ug,a5 as vl,a9 as lC,T as Tg,s as rC,y as oC,S as Sg,bf as aT,bg as uT,aa as If,ab as wf,bj as aE}from'./main-CB44G2DK.js';import'./chunk-DzLzwtOe.js';import'./chunk-CnOd7CqJ.js';import'./chunk-JZld8hhU.js';import'./chunk-BDPQgAAh.js';var $=(n,o)=>o.id,B=(n,o)=>o.name;function j(n,o){n&1&&(ws(0,"p",6),GC(1,"Loading\u2026"),pl());}function H(n,o){n&1&&(ws(0,"p",7),GC(1,"Failed to load agent definition."),pl());}function J(n,o){if(n&1&&(ws(0,"dt",12),GC(1,"User context"),pl(),ws(2,"dd",14),GC(3),pl()),n&2){let e=gC();XE(3),Yg(e.userId);}}function U(n,o){if(n&1&&(ws(0,"pre",22),GC(1),pl()),n&2){let e=gC(2);XE(),Yg(e.systemPrompt);}}function G(n,o){if(n&1){let e=lC();ws(0,"section",9)(1,"button",20),Rg("click",function(){If(e);let p=gC(2);return wf(p.toggleSystemPrompt())}),ws(2,"h2",10),GC(3,"System Prompt"),pl(),ws(4,"span",21),GC(5," \u25BC "),pl()(),Jw(6,U,2,1,"pre",22),pl();}if(n&2){let e=gC(2);XE(),Tg("aria-expanded",!e.systemPromptCollapsed()),XE(3),Ug("agent-config-inspect__chevron--open",!e.systemPromptCollapsed()),XE(2),eC(e.systemPromptCollapsed()?-1:6);}}function K(n,o){if(n&1&&(ws(0,"pre",22),GC(1),pl()),n&2){let e=gC(2);XE(),Yg(e.instructions);}}function q(n,o){if(n&1){let e=lC();ws(0,"section",9)(1,"button",20),Rg("click",function(){If(e);let p=gC(2);return wf(p.toggleInstructions())}),ws(2,"h2",10),GC(3,"Instructions"),pl(),ws(4,"span",21),GC(5," \u25BC "),pl()(),Jw(6,K,2,1,"pre",22),pl();}if(n&2){let e=gC(2);XE(),Tg("aria-expanded",!e.instructionsCollapsed()),XE(3),Ug("agent-config-inspect__chevron--open",!e.instructionsCollapsed()),XE(2),eC(e.instructionsCollapsed()?-1:6);}}function Q(n,o){n&1&&(ws(0,"p",17),GC(1," This agent declares no skill, so it gets no skill tools. Attach skills from the edit form. "),pl());}function W(n,o){n&1&&(ws(0,"span",25),GC(1,"platform"),pl());}function X(n,o){n&1&&(ws(0,"span",25),GC(1,"SKILL.md"),pl());}function Y(n,o){if(n&1&&(ws(0,"li",23)(1,"span",24),GC(2),pl(),Jw(3,W,2,0,"span",25),Jw(4,X,2,0,"span",25),ws(5,"p",26),GC(6),pl()()),n&2){let e=o.$implicit;XE(2),Yg(e.name),XE(),eC(e.namespaceId?-1:3),XE(),eC(e.readOnly?4:-1),XE(2),Yg(e.description);}}function Z(n,o){if(n&1&&(ws(0,"ul",18),rC(1,Y,7,4,"li",23,$),pl()),n&2){let e=gC(2);XE(),oC(e.resolvedSkills());}}function ee(n,o){n&1&&(ws(0,"p",17),GC(1,"No tools available for this agent."),pl());}function ne(n,o){if(n&1&&(Sg(0,"div",31),aT(1,"agentosMarkdown")),n&2){let e=gC(2).$implicit;bg("innerHTML",uT(1,1,e.description),aE);}}function te(n,o){if(n&1&&(ws(0,"div",30),Jw(1,ne,2,3,"div",31),ws(2,"pre",32),GC(3),pl()()),n&2){let e=gC().$implicit,c=gC(3);XE(),eC(e.description?1:-1),XE(2),Yg(c.formatSchema(e.inputSchema));}}function ie(n,o){if(n&1){let e=lC();ws(0,"li",27)(1,"button",28),Rg("click",function(){let p=If(e).$implicit,V=gC(3);return wf(V.toggleTool(p))}),ws(2,"span",29),GC(3),pl(),ws(4,"span",21),GC(5," \u25BC "),pl()(),Jw(6,te,4,2,"div",30),pl();}if(n&2){let e=o.$implicit,c=gC(3);XE(),Tg("aria-expanded",c.isToolExpanded(e)),XE(2),Yg(e.name),XE(),Ug("agent-config-inspect__chevron--open",c.isToolExpanded(e)),XE(2),eC(c.isToolExpanded(e)?6:-1);}}function oe(n,o){if(n&1&&(ws(0,"ul",19),rC(1,ie,7,5,"li",27,B),pl()),n&2){let e=gC();XE(),oC(e.tools);}}function ae(n,o){if(n&1&&(ws(0,"div",8)(1,"section",9)(2,"h2",10),GC(3,"General"),pl(),ws(4,"dl",11)(5,"dt",12),GC(6,"Name"),pl(),ws(7,"dd",13),GC(8),pl(),ws(9,"dt",12),GC(10,"Resolved model"),pl(),ws(11,"dd",14),GC(12),pl(),ws(13,"dt",12),GC(14,"Provider"),pl(),ws(15,"dd",13),GC(16),pl(),ws(17,"dt",12),GC(18,"Advanced execution"),pl(),ws(19,"dd",13)(20,"span",15),GC(21),pl()(),Jw(22,J,4,1),pl()(),Jw(23,G,7,4,"section",9),Jw(24,q,7,4,"section",9),ws(25,"section",9)(26,"h2",10),GC(27," Skills "),ws(28,"span",16),GC(29),pl()(),Jw(30,Q,2,0,"p",17)(31,Z,3,0,"ul",18),pl(),ws(32,"section",9)(33,"h2",10),GC(34," Tools "),ws(35,"span",16),GC(36),pl()(),Jw(37,ee,2,0,"p",17)(38,oe,3,0,"ul",19),pl()()),n&2){let e=o,c=gC();XE(8),Yg(e.name),XE(4),Yg(e.resolvedModelApiName),XE(4),Yg(e.resolvedProviderName),XE(4),Ug("agent-config-inspect__badge--active",e.advancedExecution),XE(),vl(" ",e.advancedExecution?"Enabled":"Disabled"," "),XE(),eC(e.userId?22:-1),XE(),eC(e.systemPrompt?23:-1),XE(),eC(e.instructions?24:-1),XE(5),vl("(",c.resolvedSkills().length,")"),XE(),eC(c.resolvedSkills().length===0?30:31),XE(6),vl("(",e.tools.length,")"),XE(),eC(e.tools.length===0?37:38);}}var R=class n{route=g(W$1);router=g(F);destroyRef=g(Ce);agentConfigController=g($$1);namespaceId=this.route.snapshot.params.namespaceId;agentConfigId=this.route.snapshot.params.agentConfigId;isPlatformMode=!this.namespaceId;isLoading=Gi(true);hasError=Gi(false);definition=Gi(null);expandedTools=Gi(new Set);resolvedSkills=mT(()=>this.definition()?.skills??[]);systemPromptCollapsed=Gi(true);instructionsCollapsed=Gi(true);ngOnInit(){this.agentConfigController.getDefinitionAgentConfig(this.agentConfigId).pipe(U$1(this.destroyRef)).subscribe({next:o=>{this.definition.set(o),this.isLoading.set(false);},error:()=>{this.hasError.set(true),this.isLoading.set(false);}});}toggleTool(o){this.expandedTools.update(e=>{let c=new Set(e);return c.has(o.name)?c.delete(o.name):c.add(o.name),c});}isToolExpanded(o){return this.expandedTools().has(o.name)}toggleSystemPrompt(){this.systemPromptCollapsed.update(o=>!o);}toggleInstructions(){this.instructionsCollapsed.update(o=>!o);}formatSchema(o){try{return JSON.stringify(JSON.parse(o),null,2)}catch(e){return o}}editRoute(){return this.isPlatformMode?["/agentos","admin","agent-configs",this.agentConfigId,"edit"]:["/agentos",this.namespaceId,"agent-configs",this.agentConfigId,"edit"]}back(){this.isPlatformMode?this.router.navigate(["/agentos","admin","agent-configs"]):this.router.navigate(["/agentos",this.namespaceId,"agent-configs"]);}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=xw({type:n,selectors:[["agentos-agent-config-inspect"]],decls:13,vars:2,consts:[[1,"agent-config-inspect"],[1,"agent-config-inspect__header"],["type","button","title","Back to agent configs",1,"agent-config-inspect__back",3,"click"],[1,"agent-config-inspect__back-icon"],[1,"agent-config-inspect__title"],[1,"agent-config-inspect__sibling-link",3,"routerLink"],[1,"agent-config-inspect__loading"],[1,"agent-config-inspect__error"],[1,"agent-config-inspect__content"],[1,"agent-config-inspect__section"],[1,"agent-config-inspect__section-title"],[1,"agent-config-inspect__dl"],[1,"agent-config-inspect__dt"],[1,"agent-config-inspect__dd"],[1,"agent-config-inspect__dd","agent-config-inspect__dd--mono"],[1,"agent-config-inspect__badge"],[1,"agent-config-inspect__count"],[1,"agent-config-inspect__empty"],[1,"agent-config-inspect__skills"],[1,"agent-config-inspect__tools"],["type","button",1,"agent-config-inspect__collapsible",3,"click"],[1,"agent-config-inspect__chevron"],[1,"agent-config-inspect__instructions"],[1,"agent-config-inspect__skill"],[1,"agent-config-inspect__skill-name"],[1,"agent-config-inspect__skill-badge"],[1,"agent-config-inspect__skill-desc"],[1,"agent-config-inspect__tool"],["type","button",1,"agent-config-inspect__tool-header",3,"click"],[1,"agent-config-inspect__tool-name"],[1,"agent-config-inspect__tool-body"],[1,"agent-config-inspect__tool-description",3,"innerHTML"],[1,"agent-config-inspect__schema"]],template:function(e,c){if(e&1&&(ws(0,"div",0)(1,"header",1)(2,"button",2),Rg("click",function(){return c.back()}),ws(3,"span",3),GC(4,"\u2190"),pl(),GC(5," Agent Configs "),pl(),ws(6,"h1",4),GC(7,"Agent definition"),pl(),ws(8,"a",5),GC(9,"Edit config \u2192"),pl()(),Jw(10,j,2,0,"p",6)(11,H,2,0,"p",7)(12,ae,39,13,"div",8),pl()),e&2){let p;XE(8),bg("routerLink",c.editRoute()),XE(2),eC(c.isLoading()?10:c.hasError()?11:(p=c.definition())?12:-1,p);}},dependencies:[$t,d],styles:[".agent-config-inspect[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:2rem;max-width:720px;margin:0 auto;padding:2rem 1rem}.agent-config-inspect__header[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.agent-config-inspect__back[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:.375rem;background:none;border:none;padding:0;cursor:pointer;font-size:.875rem;color:var(--color-primary, #007aff);font-family:inherit}.agent-config-inspect__back[_ngcontent-%COMP%]:hover{text-decoration:underline}.agent-config-inspect__back-icon[_ngcontent-%COMP%]{font-size:1rem;line-height:1}.agent-config-inspect__title[_ngcontent-%COMP%]{margin:0;font-size:1.5rem;font-weight:600;color:var(--color-text, #1d1d1f);letter-spacing:-.02em}.agent-config-inspect__sibling-link[_ngcontent-%COMP%]{font-size:.8125rem;color:var(--color-primary, #007aff);text-decoration:none}.agent-config-inspect__sibling-link[_ngcontent-%COMP%]:hover{text-decoration:underline}.agent-config-inspect__loading[_ngcontent-%COMP%], .agent-config-inspect__error[_ngcontent-%COMP%], .agent-config-inspect__empty[_ngcontent-%COMP%]{margin:0;font-size:.9rem;color:var(--color-text-secondary, #6e6e73)}.agent-config-inspect__error[_ngcontent-%COMP%]{color:var(--color-error, #ff3b30)}.agent-config-inspect__content[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.agent-config-inspect__section[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.75rem;padding:1.25rem;border:1px solid var(--color-border, rgba(0, 0, 0, .1));border-radius:10px}.agent-config-inspect__section-title[_ngcontent-%COMP%]{margin:0;font-size:.9375rem;font-weight:600;color:var(--color-text, #1d1d1f)}.agent-config-inspect__count[_ngcontent-%COMP%]{font-weight:400;color:var(--color-text-secondary, #6e6e73);font-size:.875rem;margin-left:.25rem}.agent-config-inspect__dl[_ngcontent-%COMP%]{display:grid;grid-template-columns:max-content 1fr;gap:.5rem 1.25rem;margin:0}.agent-config-inspect__dt[_ngcontent-%COMP%]{font-size:.8125rem;font-weight:500;color:var(--color-text-secondary, #6e6e73);align-self:center}.agent-config-inspect__dd[_ngcontent-%COMP%]{margin:0;font-size:.9375rem;color:var(--color-text, #1d1d1f);align-self:center;word-break:break-word}.agent-config-inspect__dd--mono[_ngcontent-%COMP%]{font-family:monospace;font-size:.875rem}.agent-config-inspect__badge[_ngcontent-%COMP%]{display:inline-block;padding:.2em .6em;border-radius:4px;font-size:.75rem;font-weight:500;background:var(--color-surface-muted, rgba(0, 0, 0, .06));color:var(--color-text-secondary, #6e6e73)}.agent-config-inspect__badge--active[_ngcontent-%COMP%]{background:var(--color-success-bg, #e3f5e1);color:var(--color-success, #34c759)}.agent-config-inspect__collapsible[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:.5rem;width:100%;background:none;border:none;padding:0;cursor:pointer;font-family:inherit;text-align:left}.agent-config-inspect__chevron[_ngcontent-%COMP%]{font-size:.7rem;color:var(--color-text-secondary, #6e6e73);transition:transform .15s ease;flex-shrink:0}.agent-config-inspect__chevron--open[_ngcontent-%COMP%]{transform:rotate(180deg)}.agent-config-inspect__instructions[_ngcontent-%COMP%]{margin:0;padding:.875rem 1rem;border-radius:6px;background:var(--color-surface-muted, rgba(0, 0, 0, .04));font-size:.875rem;font-family:inherit;color:var(--color-text, #1d1d1f);white-space:pre-wrap;word-break:break-word;line-height:1.6;max-height:400px;overflow-y:auto}.agent-config-inspect__tools[_ngcontent-%COMP%], .agent-config-inspect__skills[_ngcontent-%COMP%]{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:.5rem}.agent-config-inspect__skill[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;align-items:baseline;gap:.5rem}.agent-config-inspect__skill-name[_ngcontent-%COMP%]{font-size:.9rem;font-weight:500}.agent-config-inspect__skill-badge[_ngcontent-%COMP%]{font-size:.75rem;font-family:monospace;color:var(--color-text-secondary, #6e6e73)}.agent-config-inspect__skill-desc[_ngcontent-%COMP%]{flex:1 1 100%;margin:0;font-size:.8rem;color:var(--color-text-secondary, #6e6e73);line-height:1.4}.agent-config-inspect__tool[_ngcontent-%COMP%]{border:1px solid var(--color-border, rgba(0, 0, 0, .08));border-radius:6px;overflow:hidden}.agent-config-inspect__tool-header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:.75rem;width:100%;padding:.75rem 1rem;background:none;border:none;cursor:pointer;font-family:inherit;text-align:left;transition:background .1s ease}.agent-config-inspect__tool-header[_ngcontent-%COMP%]:hover{background:var(--color-surface-hover, rgba(0, 0, 0, .04))}.agent-config-inspect__tool-name[_ngcontent-%COMP%]{font-size:.875rem;font-weight:600;font-family:monospace;color:var(--color-text, #1d1d1f);white-space:nowrap;overflow:hidden;text-overflow:ellipsis}.agent-config-inspect__tool-body[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem;padding:0 1rem .75rem;border-top:1px solid var(--color-border, rgba(0, 0, 0, .08))}.agent-config-inspect__tool-description[_ngcontent-%COMP%]{margin:0;padding-top:.75rem;font-size:.8125rem;line-height:1.5;color:var(--color-text-secondary, #6e6e73)}.agent-config-inspect__tool-description[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{margin:0 0 .25rem}.agent-config-inspect__tool-description[_ngcontent-%COMP%] p[_ngcontent-%COMP%]:last-child{margin-bottom:0}.agent-config-inspect__tool-description[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{font-family:monospace;font-size:.8em;background:var(--color-surface-muted, rgba(0, 0, 0, .06));padding:.1em .3em;border-radius:3px}.agent-config-inspect__schema[_ngcontent-%COMP%]{margin:0;padding:.875rem 1rem;background:var(--color-surface-muted, rgba(0, 0, 0, .04));font-size:.8125rem;font-family:monospace;color:var(--color-text, #1d1d1f);white-space:pre;overflow-x:auto;line-height:1.5;max-height:360px;overflow-y:auto}"]})};export{R as AgentConfigInspectComponent};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
import {O as O$1}from'./chunk-
|
|
1
|
+
import {O as O$1}from'./chunk-CigBS2kT.js';import {g,ao as W,F,du as F$1,da as $,C as Ce,G as Gi,b as U,av as B,dv as Ny,e as xw,aw as hl,cJ as Og,n as GC,ax as gl,b6 as _g,J as Jw,X as XE,c0 as xg,v as eC,a5 as vl,ac as gC}from'./main-CB44G2DK.js';import'./chunk-DzLzwtOe.js';import'./chunk-CnOd7CqJ.js';import'./chunk-JZld8hhU.js';import'./chunk-BDPQgAAh.js';function w(l,o){if(l&1&&(hl(0,"p",10),GC(1),gl()),l&2){let i=gC();XE(),vl(" ",i.launchError()," ");}}var O=class l{route=g(W);router=g(F);caseController=g(F$1);caseState=g(O$1);agentConfigController=g($);destroyRef=g(Ce);namespaceId=this.route.snapshot.params.namespaceId;agentConfigId=this.route.snapshot.params.agentConfigId;resolvedAgentConfig=null;payloadJson=Gi("");launchError=Gi(null);isLaunching=Gi(false);isLoading=Gi(false);ngOnInit(){this.isLoading.set(true),this.agentConfigController.getByIdAgentConfig(this.agentConfigId).pipe(U(this.destroyRef)).subscribe({next:o=>{this.resolvedAgentConfig=o,o.loopConfig!=null&&this.payloadJson.set(JSON.stringify(o.loopConfig,null,2)),this.isLoading.set(false);},error:()=>{this.isLoading.set(false);}});}launch(){return B(this,null,function*(){this.launchError.set(null),this.isLaunching.set(true);try{let o=this.resolvedAgentConfig??(yield Ny(this.agentConfigController.getByIdAgentConfig(this.agentConfigId))),i=yield Ny(this.caseController.createCase({namespaceId:this.namespaceId}));this.caseState.addCase(i);let e=i.id??"",d={content:`@${o.name} start`};yield Ny(this.caseController.addMessageCase(e,d)),this.router.navigate(["/agentos/home"],{queryParams:{ns:this.namespaceId,case:e}});}catch(o){console.error("[AgentConfigLaunch] Failed to launch loop agent",o),this.launchError.set("Failed to launch the agent loop. Please check the console for details."),this.isLaunching.set(false);}})}back(){this.router.navigate(["/agentos",this.namespaceId,"agent-configs",this.agentConfigId,"edit"]);}static \u0275fac=function(i){return new(i||l)};static \u0275cmp=xw({type:l,selectors:[["agentos-agent-config-launch"]],decls:23,vars:6,consts:[[1,"agent-config-launch"],[1,"agent-config-launch__header"],["type","button","title","Back to agent config",1,"agent-config-launch__back",3,"click"],[1,"agent-config-launch__back-icon"],[1,"agent-config-launch__title"],[1,"agent-config-launch__intro"],[1,"agent-config-launch__code"],[1,"agent-config-launch__field"],["for","agent-loop-payload",1,"agent-config-launch__label"],["id","agent-loop-payload","rows","15","readonly","","spellcheck","false","autocomplete","off",1,"agent-config-launch__textarea",3,"value","disabled"],["role","alert",1,"agent-config-launch__error","agent-config-launch__error--banner"],[1,"agent-config-launch__actions"],["type","button",1,"agent-config-launch__btn","agent-config-launch__btn--primary",3,"click","disabled"],["type","button",1,"agent-config-launch__btn",3,"click","disabled"]],template:function(i,e){i&1&&(hl(0,"div",0)(1,"header",1)(2,"button",2),Og("click",function(){return e.back()}),hl(3,"span",3),GC(4,"\u2190"),gl(),GC(5," Edit agent config "),gl(),hl(6,"h1",4),GC(7,"Launch loop agent"),gl()(),hl(8,"p",5),GC(9," The loop configuration below is read from "),hl(10,"code",6),GC(11,"AgentConfig.loopConfig"),gl(),GC(12," and will be used by the backend when the agent loop starts. A new Case will be created and one child case will be launched per entity found. "),gl(),hl(13,"div",7)(14,"label",8),GC(15,"Loop configuration (read-only)"),gl(),_g(16,"textarea",9),gl(),Jw(17,w,2,1,"p",10),hl(18,"div",11)(19,"button",12),Og("click",function(){return e.launch()}),GC(20),gl(),hl(21,"button",13),Og("click",function(){return e.back()}),GC(22,"Cancel"),gl()()()),i&2&&(XE(16),xg("value",e.payloadJson())("disabled",e.isLaunching()||e.isLoading()),XE(),eC(e.launchError()?17:-1),XE(2),xg("disabled",e.isLaunching()),XE(),vl(" ",e.isLaunching()?"Launching\u2026":"Launch"," "),XE(),xg("disabled",e.isLaunching()));},styles:[".agent-config-launch[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.75rem;max-width:720px;margin:0 auto;padding:2rem 1rem}.agent-config-launch__header[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.agent-config-launch__back[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:.375rem;background:none;border:none;padding:0;cursor:pointer;font-size:.875rem;font-family:inherit;color:var(--color-accent, #2563eb)}.agent-config-launch__back[_ngcontent-%COMP%]:hover{text-decoration:underline}.agent-config-launch__back-icon[_ngcontent-%COMP%]{font-size:1rem;line-height:1}.agent-config-launch__title[_ngcontent-%COMP%]{margin:0;font-size:1.5rem;font-weight:700;color:var(--color-text);letter-spacing:-.02em}.agent-config-launch__intro[_ngcontent-%COMP%]{margin:0;font-size:.9rem;color:var(--color-text-secondary);line-height:1.5}.agent-config-launch__code[_ngcontent-%COMP%]{font-family:var(--font-heading, monospace);font-size:.85em;background:var(--color-surface-muted, rgba(0, 0, 0, .06));padding:.1em .35em}.agent-config-launch__field[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.375rem}.agent-config-launch__label[_ngcontent-%COMP%]{font-size:.875rem;font-weight:500;color:var(--color-text)}.agent-config-launch__textarea[_ngcontent-%COMP%]{width:100%;padding:.75rem 1rem;border:1px solid var(--color-divider);background:var(--color-surface-muted, rgba(0, 0, 0, .03));color:var(--color-text-secondary);font-family:var(--font-heading, monospace);font-size:.8125rem;line-height:1.6;resize:vertical;outline:none;box-sizing:border-box;cursor:default}.agent-config-launch__textarea[_ngcontent-%COMP%]:disabled{opacity:.6;cursor:not-allowed}.agent-config-launch__error[_ngcontent-%COMP%]{margin:.25rem 0 0;font-size:.8125rem;color:var(--color-error, var(--red, #dc2626));line-height:1.4}.agent-config-launch__error--banner[_ngcontent-%COMP%]{padding:.75rem 1rem;background:color-mix(in srgb,var(--color-error, #dc2626) 8%,transparent);border:1px solid color-mix(in srgb,var(--color-error, #dc2626) 25%,transparent);border-left:3px solid var(--color-error, #dc2626)}.agent-config-launch__actions[_ngcontent-%COMP%]{display:flex;gap:.75rem}.agent-config-launch__btn[_ngcontent-%COMP%]{padding:.6rem 1.5rem;border:1px solid var(--color-divider);background:transparent;color:var(--color-text);font-size:13px;font-family:var(--font-heading);font-weight:600;cursor:pointer;transition:background .15s ease,border-color .15s ease}.agent-config-launch__btn[_ngcontent-%COMP%]:hover:not(:disabled){background:var(--color-bg-hover);border-color:var(--color-neutral-500)}.agent-config-launch__btn[_ngcontent-%COMP%]:disabled{opacity:.45;cursor:not-allowed}.agent-config-launch__btn--primary[_ngcontent-%COMP%]{background:var(--color-warning, #f59e0b);border-color:var(--color-warning, #f59e0b);color:#fff}.agent-config-launch__btn--primary[_ngcontent-%COMP%]:hover:not(:disabled){background:color-mix(in srgb,var(--color-warning, #f59e0b) 80%,black);border-color:color-mix(in srgb,var(--color-warning, #f59e0b) 80%,black)}"]})};export{O as AgentConfigLaunchComponent};
|