@whoz-oss/coday-client 0.0.0-workstream-forge.74 → 0.0.0-workstream-forge.75

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.
Files changed (118) hide show
  1. package/browser/{chunk-CZNy6umN.js → chunk-13WTmKep.js} +1 -1
  2. package/browser/chunk-1nyEsjkY.js +1 -0
  3. package/browser/chunk-2hH5YbLe.js +2 -0
  4. package/browser/{chunk-D_7-CBYr.js → chunk-42jw_j0t.js} +1 -1
  5. package/browser/chunk-5lNA_LR4.js +1 -0
  6. package/browser/{chunk-Bx7qneB8.js → chunk-6Be7kW0o.js} +2 -2
  7. package/browser/{chunk-DGK9lovv.js → chunk-6VeNGs2-.js} +2 -2
  8. package/browser/{chunk-BbRdwepF.js → chunk-80hCpwon.js} +1 -1
  9. package/browser/chunk-93qYG1j4.js +1 -0
  10. package/browser/{chunk-C203BkIo.js → chunk-AJHLyP2Q.js} +1 -1
  11. package/browser/chunk-AblS4pXb.js +1 -0
  12. package/browser/{chunk-BLhKuE4K.js → chunk-B0es9TQT.js} +6 -6
  13. package/browser/chunk-B1R1JDKX.js +1 -0
  14. package/browser/chunk-B1nDWA3v.js +1 -0
  15. package/browser/{chunk-B1ShZ0JH.js → chunk-B9cQUPc7.js} +1 -1
  16. package/browser/{chunk-CSUuBOmE.js → chunk-BCvr3olm.js} +1 -1
  17. package/browser/chunk-BJ3cmxps.js +10 -0
  18. package/browser/chunk-BRFVbU6N.js +1 -0
  19. package/browser/chunk-BYvnZ4jZ.js +1 -0
  20. package/browser/chunk-BcDCPUzh.js +1 -0
  21. package/browser/chunk-BlYydhGT.js +1 -0
  22. package/browser/chunk-BmMRXr--.js +1 -0
  23. package/browser/chunk-BnVoIxkm.js +1 -0
  24. package/browser/chunk-Bs4cz8et.js +1 -0
  25. package/browser/chunk-Buv4bUwG.js +1 -0
  26. package/browser/chunk-BwapsUV-.js +1 -0
  27. package/browser/chunk-C-7EKaLv.js +1 -0
  28. package/browser/{chunk-M4Cpl726.js → chunk-C0RjV9YR.js} +1 -1
  29. package/browser/chunk-C2h53xO8.js +1 -0
  30. package/browser/chunk-C519Azc-.js +1 -0
  31. package/browser/{chunk-B_Hi7_K5.js → chunk-C5CsTmNj.js} +1 -1
  32. package/browser/chunk-C5jla22M.js +1 -0
  33. package/browser/{chunk-C2eLmHLe.js → chunk-C7774IZF.js} +1 -1
  34. package/browser/chunk-C8Lny5xG.js +2 -0
  35. package/browser/chunk-CBAzExoV.js +1 -0
  36. package/browser/chunk-CErujabN.js +1 -0
  37. package/browser/{chunk-lTYooNBT.js → chunk-CFuJNk7Q.js} +1 -1
  38. package/browser/{chunk-CPqDcxVZ.js → chunk-CIMARU-Z.js} +2 -2
  39. package/browser/chunk-CIPMuL5o.js +1 -0
  40. package/browser/chunk-CJy6YujN.js +1 -0
  41. package/browser/chunk-CLQWshBg.js +1 -0
  42. package/browser/chunk-CNbCiJwC.js +1 -0
  43. package/browser/chunk-CQzD4hlX.js +1 -0
  44. package/browser/chunk-CTep3Zcv.js +1 -0
  45. package/browser/chunk-CUD8zCnQ.js +1 -0
  46. package/browser/chunk-CX09OqPp.js +1 -0
  47. package/browser/{chunk-C6cird4-.js → chunk-CY9LGSZW.js} +5 -5
  48. package/browser/chunk-Ccxus4_o.js +2 -0
  49. package/browser/{chunk-CFMwkAqk.js → chunk-CoVye3Su.js} +1 -1
  50. package/browser/{chunk-DbPvMw8d.js → chunk-Cr26pdWO.js} +2 -2
  51. package/browser/chunk-CrIQg7gg.js +5 -0
  52. package/browser/chunk-CtRqtZpo.js +1 -0
  53. package/browser/chunk-Cw_eJAWw.js +1 -0
  54. package/browser/chunk-D0rG88ee.js +1 -0
  55. package/browser/{chunk-Y05Tjbrm.js → chunk-D2VUzw11.js} +1 -1
  56. package/browser/chunk-D4rIP_px.js +1 -0
  57. package/browser/{chunk-KM2T1f6P.js → chunk-D6Uyjin9.js} +2 -2
  58. package/browser/{chunk-DlhAr3__.js → chunk-D9lhavsa.js} +1 -1
  59. package/browser/{chunk-Cp-2lm96.js → chunk-DOfFWQHE.js} +1 -1
  60. package/browser/chunk-DSohMG90.js +1 -0
  61. package/browser/chunk-DVa9gI4Z.js +1 -0
  62. package/browser/{chunk-ClEc5shX.js → chunk-DYWO9D4-.js} +1 -1
  63. package/browser/chunk-DdV87KC5.js +1 -0
  64. package/browser/chunk-DgQbMek3.js +1 -0
  65. package/browser/{chunk-DG-m2q1x.js → chunk-DqyQME6K.js} +1 -1
  66. package/browser/{chunk-BW4eILJX.js → chunk-DrGGZMUF.js} +1 -1
  67. package/browser/{chunk-Bqv3DvAm.js → chunk-DsE7jEkK.js} +1 -1
  68. package/browser/{chunk-BP2pU4C3.js → chunk-Dw-TsQE6.js} +1 -1
  69. package/browser/{chunk-7G55pK8Z.js → chunk-DwLys37P.js} +2 -2
  70. package/browser/chunk-EzRHT4mT.js +1 -0
  71. package/browser/chunk-Iomqh4vI.js +1 -0
  72. package/browser/chunk-MhUYxl3Z.js +1 -0
  73. package/browser/chunk-SyIy1dgS.js +1 -0
  74. package/browser/{chunk-CCTdYVJX.js → chunk-buMTi15H.js} +4 -4
  75. package/browser/chunk-cwPycVUY.js +1 -0
  76. package/browser/chunk-o7tHGyvk.js +1 -0
  77. package/browser/{chunk-BJ9nT4n9.js → chunk-tzI8SDtI.js} +1 -1
  78. package/browser/chunk-zsOy-bBo.js +1 -0
  79. package/browser/index.html +1 -1
  80. package/browser/main-A4H3MFZY.js +1811 -0
  81. package/package.json +1 -1
  82. package/browser/chunk-1WmIT8wX.js +0 -1
  83. package/browser/chunk-B1IC3iY7.js +0 -1
  84. package/browser/chunk-B8J8il5X.js +0 -1
  85. package/browser/chunk-BABwlZSD.js +0 -1
  86. package/browser/chunk-BFahvE7L.js +0 -1
  87. package/browser/chunk-BI5fPB8c.js +0 -1
  88. package/browser/chunk-BSNpL-pC.js +0 -1
  89. package/browser/chunk-B_VLh7lF.js +0 -1
  90. package/browser/chunk-Ba5k_K16.js +0 -1
  91. package/browser/chunk-BbmtZ9zm.js +0 -2
  92. package/browser/chunk-BhycFXHL.js +0 -5
  93. package/browser/chunk-Bn4R3MGx.js +0 -1
  94. package/browser/chunk-BnLH_3kS.js +0 -1
  95. package/browser/chunk-Bu4hi2wI.js +0 -1
  96. package/browser/chunk-C71jcOxe.js +0 -1
  97. package/browser/chunk-CB9KlPVw.js +0 -2
  98. package/browser/chunk-CJgl7qIz.js +0 -1
  99. package/browser/chunk-CP2uiJAD.js +0 -1
  100. package/browser/chunk-CQKlSHSr.js +0 -1
  101. package/browser/chunk-CQU20jCm.js +0 -1
  102. package/browser/chunk-Cc2tD9_S.js +0 -1
  103. package/browser/chunk-CflSlmTd.js +0 -1
  104. package/browser/chunk-Chm8g-FZ.js +0 -1
  105. package/browser/chunk-Cyu9ud2j.js +0 -1
  106. package/browser/chunk-D1zGCmJc.js +0 -2
  107. package/browser/chunk-DN_cGxhi.js +0 -1
  108. package/browser/chunk-DSCHg4pY.js +0 -1
  109. package/browser/chunk-DX81Wkaz.js +0 -1
  110. package/browser/chunk-Dvfnbhcq.js +0 -1
  111. package/browser/chunk-GiNThHhM.js +0 -1
  112. package/browser/chunk-c4c3f890.js +0 -1
  113. package/browser/chunk-fvDcXd63.js +0 -1
  114. package/browser/chunk-kDXa94an.js +0 -10
  115. package/browser/chunk-le7lcHE6.js +0 -1
  116. package/browser/chunk-pXkBb_FT.js +0 -1
  117. package/browser/chunk-yfNymwEt.js +0 -1
  118. package/browser/main-RV7LPVHR.js +0 -1811
@@ -1 +1 @@
1
- import {g,D as py,P,Q as br,r as re,W as x}from'./main-RV7LPVHR.js';var d=class i{http=g(py);projectState=g(P);promptsCache=new Map;getBaseUrl(){return `/api/projects/${this.projectState.getSelectedProjectIdOrThrow()}/prompts`}listPrompts(){return this.http.get(this.getBaseUrl())}getPromptsAutocomplete(t,e){let r=this.promptsCache.get(t);return r?br(this.filterPromptsForAutocomplete(r,e)):this.http.get(`/api/projects/${t}/prompts`).pipe(re(p=>(this.promptsCache.set(t,p),this.filterPromptsForAutocomplete(p,e))))}filterPromptsForAutocomplete(t,e){let r=e.toLowerCase();return t.filter(o=>o.name.toLowerCase().includes(r)||o.description.toLowerCase().includes(r)).map(o=>({name:o.name,description:o.description,parameterFormat:o.parameterFormat}))}clearCache(t){t?this.promptsCache.delete(t):this.promptsCache.clear();}getPrompt(t){return this.http.get(`${this.getBaseUrl()}/${t}`)}createPrompt(t){return this.http.post(this.getBaseUrl(),t).pipe(re(e=>(this.clearCache(this.projectState.getSelectedProjectId()??void 0),e)))}updatePrompt(t,e){return this.http.put(`${this.getBaseUrl()}/${t}`,e).pipe(re(r=>(this.clearCache(this.projectState.getSelectedProjectId()??void 0),r)))}deletePrompt(t){return this.http.delete(`${this.getBaseUrl()}/${t}`).pipe(re(e=>(this.clearCache(this.projectState.getSelectedProjectId()??void 0),e)))}enableWebhook(t){return this.http.post(`${this.getBaseUrl()}/${t}/webhook`,{})}disableWebhook(t){return this.http.delete(`${this.getBaseUrl()}/${t}/webhook`)}static \u0275fac=function(e){return new(e||i)};static \u0275prov=x({token:i,factory:i.\u0275fac,providedIn:"root"})};export{d};
1
+ import {g,H as py,P,W as br,r as re,Y as x}from'./main-A4H3MFZY.js';var d=class i{http=g(py);projectState=g(P);promptsCache=new Map;getBaseUrl(){return `/api/projects/${this.projectState.getSelectedProjectIdOrThrow()}/prompts`}listPrompts(){return this.http.get(this.getBaseUrl())}getPromptsAutocomplete(t,e){let r=this.promptsCache.get(t);return r?br(this.filterPromptsForAutocomplete(r,e)):this.http.get(`/api/projects/${t}/prompts`).pipe(re(p=>(this.promptsCache.set(t,p),this.filterPromptsForAutocomplete(p,e))))}filterPromptsForAutocomplete(t,e){let r=e.toLowerCase();return t.filter(o=>o.name.toLowerCase().includes(r)||o.description.toLowerCase().includes(r)).map(o=>({name:o.name,description:o.description,parameterFormat:o.parameterFormat}))}clearCache(t){t?this.promptsCache.delete(t):this.promptsCache.clear();}getPrompt(t){return this.http.get(`${this.getBaseUrl()}/${t}`)}createPrompt(t){return this.http.post(this.getBaseUrl(),t).pipe(re(e=>(this.clearCache(this.projectState.getSelectedProjectId()??void 0),e)))}updatePrompt(t,e){return this.http.put(`${this.getBaseUrl()}/${t}`,e).pipe(re(r=>(this.clearCache(this.projectState.getSelectedProjectId()??void 0),r)))}deletePrompt(t){return this.http.delete(`${this.getBaseUrl()}/${t}`).pipe(re(e=>(this.clearCache(this.projectState.getSelectedProjectId()??void 0),e)))}enableWebhook(t){return this.http.post(`${this.getBaseUrl()}/${t}/webhook`,{})}disableWebhook(t){return this.http.delete(`${this.getBaseUrl()}/${t}/webhook`)}static \u0275fac=function(e){return new(e||i)};static \u0275prov=x({token:i,factory:i.\u0275fac,providedIn:"root"})};export{d};
@@ -0,0 +1 @@
1
+ var r="*";function l(e){return e.trim().replace(/\/SKILL\.md$/,"").replace(/\/$/,"").replace(/^\/+/,"")}function o(e){return (e??[]).some(n=>n.trim()===r)}function i(e){let n=(e??[]).map(t=>t.trim()).filter(t=>t.length>0&&t!==r).map(t=>l(t).toLowerCase());return new Set(n)}function a(e,n){return i(e).has(l(n).toLowerCase())?"named":o(e)?"all":"none"}export{a,i,l,o,r};
@@ -0,0 +1,2 @@
1
+ import {v}from'./chunk-BRFVbU6N.js';import {R,q,J}from'./chunk-DOfFWQHE.js';import {g,ao as V,G,C as Ce$1,a as Gi,F,m as mT,cd as Hf,b as U,x,w,e as xw,k as ws,q as Rg,n as GC,o as pl,J as Jw,X as XE,a8 as Yg,y as eC,a9 as lC,t as rC,a4 as nC,a3 as VI,S as Sg,ac as gC,v as bg,a6 as UI,z as oC,a5 as vl,cH as Kw,aa as If,ab as wf,b$ as kC,T as Tg}from'./main-A4H3MFZY.js';import'./chunk-BJ3cmxps.js';import {k as _t,b as _e$1,o as z,n as ni,J as Jn,Q as Qn,e as ei,Y as Ye,A as At,m as mn,Z as Zn,l as Xn,C as Cn,E as En}from'./chunk-CFuJNk7Q.js';import'./chunk-cwPycVUY.js';import'./chunk-D2VUzw11.js';import'./chunk-B0es9TQT.js';import'./chunk-D6Uyjin9.js';function se(i,t){i&1&&(ws(0,"p",5),GC(1,"Loading\u2026"),pl());}function ce(i,t){if(i&1&&(ws(0,"label",23),Sg(1,"input",24),VI(),ws(2,"span"),GC(3),pl()()),i&2){let e=t.$implicit,o=gC(3);XE(),bg("formControl",o.scopeControl)("value",e.value)("disabled",e.value==="namespace"&&!o.isAdmin()),UI(),XE(2),Yg(e.label);}}function de(i,t){if(i&1&&(ws(0,"fieldset",8)(1,"legend",22),GC(2,"Configuration scope"),pl(),rC(3,ce,4,4,"label",23,Kw().trackByScope,true),pl()),i&2){let e=gC(2);bg("disabled",e.isEditMode()),XE(3),oC(e.scopeOptions);}}function ue(i,t){if(i&1&&(ws(0,"option",13),GC(1),pl()),i&2){let e=t.$implicit,o=gC(2);bg("value",e),XE(),Yg(o.authTypeLabel[e]);}}function pe(i,t){i&1&&GC(0," Leave a field unchanged to keep the stored credential. ");}function he(i,t){i&1&&(ws(0,"span",11),GC(1,"*"),pl());}function me(i,t){if(i&1&&(ws(0,"p",28),GC(1),pl()),i&2){let e=gC(2).$implicit;bg("id","as-hint-"+e.key),XE(),Yg(e.hint);}}function ge(i,t){if(i&1&&(Sg(0,"input",27),VI(),Jw(1,me,2,2,"p",28)),i&2){let e=gC().$implicit;kC("auth-setting-form__input"+(e.secret?" auth-setting-form__input--secret":"")),bg("id","as-cred-"+e.key)("type",e.secret?"password":"text")("placeholder",e.placeholder)("formControl",t)("autocomplete",e.secret?"new-password":"off"),Tg("aria-describedby",e.hint?"as-hint-"+e.key:null),UI(),XE(),eC(e.hint?1:-1);}}function Ce(i,t){if(i&1&&(ws(0,"div",9)(1,"label",26),GC(2),Jw(3,he,2,0,"span",11),pl(),Jw(4,ge,2,9),pl()),i&2){let e,o=t.$implicit,l=gC(3);XE(),bg("for","as-cred-"+o.key),XE(),vl(" ",o.label," "),XE(),eC(o.required?3:-1),XE(),eC((e=l.controlForField(o.key))?4:-1,e);}}function fe(i,t){if(i&1&&(ws(0,"fieldset",18)(1,"legend",22),GC(2,"Credentials"),pl(),ws(3,"p",25),GC(4," Values are stored encrypted and masked on read. "),Jw(5,pe,1,0),pl(),rC(6,Ce,5,4,"div",9,Kw().trackByField,true),pl()),i&2){let e=gC(2);XE(5),eC(e.isEditMode()?5:-1),XE(),oC(e.credentialFields());}}function ye(i,t){if(i&1){let e=lC();ws(0,"form",7),Rg("ngSubmit",function(){If(e);let l=gC();return wf(l.submit())}),Jw(1,de,5,1,"fieldset",8),ws(2,"div",9)(3,"label",10),GC(4,"Auth type "),ws(5,"span",11),GC(6,"*"),pl()(),ws(7,"select",12),rC(8,ue,2,2,"option",13,nC),pl(),VI(),pl(),ws(10,"div",9)(11,"label",14),GC(12,"Name "),ws(13,"span",11),GC(14,"*"),pl()(),Sg(15,"input",15),VI(),pl(),ws(16,"div",9)(17,"label",16),GC(18,"Description"),pl(),Sg(19,"input",17),VI(),pl(),Jw(20,fe,8,1,"fieldset",18),ws(21,"div",19)(22,"button",20),GC(23),pl(),ws(24,"button",21),Rg("click",function(){If(e);let l=gC();return wf(l.cancel())}),GC(25,"Cancel"),pl()()();}if(i&2){let e=gC();bg("formGroup",e.form),XE(),eC(e.isPlatformMode?-1:1),XE(6),bg("formControl",e.authTypeControl),UI(),XE(),oC(e.authTypeOptions),XE(7),bg("formControl",e.nameControl),UI(),XE(4),bg("formControl",e.descriptionControl),UI(),XE(),eC(e.credentialFields().length>0?20:-1),XE(2),bg("disabled",e.form.invalid||e.isSubmitting()),XE(),vl(" ",e.isEditMode()?"Save changes":"Create"," ");}}var _e=new Set(["namespace","userOnNs","userGlobal"]),P=Object.freeze({platform:"Platform (read-only)",namespace:"Namespace configuration",userOnNs:"Personal \u2014 this namespace only",userGlobal:"Personal \u2014 all namespaces"}),Se={ApiKeyAuthSetting:[{key:"apiKey",label:"API Key",placeholder:"sk-\u2026",secret:true,required:false}],BasicAuthAuthSetting:[{key:"username",label:"Username",placeholder:"user@example.com",secret:false,required:false},{key:"password",label:"Password",placeholder:"\u2022\u2022\u2022\u2022\u2022\u2022\u2022\u2022",secret:true,required:false}],BearerTokenAuthSetting:[{key:"token",label:"Bearer token",placeholder:"eyJ\u2026",secret:true,required:false}],OAuthDiscoverableAuthSetting:[{key:"discoveryUrl",label:"Discovery URL",placeholder:"https://\u2026/.well-known/openid-configuration",secret:false,required:false},{key:"clientId",label:"Client ID",placeholder:"",secret:false,required:false},{key:"clientSecret",label:"Client secret",placeholder:"",secret:true,required:false},{key:"scopes",label:"Scopes",placeholder:"",hint:"Space-separated OAuth scopes to request (e.g. openid profile email). Check your provider's documentation for the exact values.",secret:false,required:false}],OAuthCustomAuthSetting:[{key:"authorizationUrl",label:"Authorization URL",placeholder:"https://\u2026/authorize",secret:false,required:false},{key:"tokenUrl",label:"Token URL",placeholder:"https://\u2026/token",secret:false,required:false},{key:"clientId",label:"Client ID",placeholder:"",secret:false,required:false},{key:"clientSecret",label:"Client secret",placeholder:"",secret:true,required:false},{key:"scopes",label:"Scopes",placeholder:"",hint:"Space-separated OAuth scopes to request (e.g. openid profile email). Check your provider's documentation for the exact values.",secret:false,required:false}],OAuthRegisteredAuthSetting:[{key:"authorizationUrl",label:"Authorization URL",placeholder:"https://\u2026/authorize",secret:false,required:false},{key:"tokenUrl",label:"Token URL",placeholder:"https://\u2026/token",secret:false,required:false},{key:"clientId",label:"Client ID",placeholder:"",secret:false,required:false},{key:"clientSecret",label:"Client secret",placeholder:"",secret:true,required:false},{key:"scopes",label:"Scopes",placeholder:"",hint:"Space-separated OAuth scopes to request (e.g. openid profile email). Check your provider's documentation for the exact values.",secret:false,required:false}],OAuthMcpDiscoverableAuthSetting:[{key:"resourceUrl",label:"Resource URL",placeholder:"https://mcp.example.com",hint:"Use the base URL exactly as documented by your provider \u2014 do not append a path suffix. Examples: https://mcp.hubspot.com (HubSpot), https://mcp.atlassian.com/v1/mcp (Atlassian).",secret:false,required:false},{key:"clientId",label:"Client ID",placeholder:"",hint:"Leave empty to let the server register an OAuth client automatically (RFC 7591 dynamic registration). Fill in only if you have a pre-registered client ID from your provider.",secret:false,required:false},{key:"clientSecret",label:"Client secret",placeholder:"",secret:true,required:false},{key:"scopes",label:"Scopes",placeholder:"",hint:"Leave empty in most cases \u2014 the MCP server declares the required scopes itself. Fill in only if your provider explicitly requires client-declared scopes.",secret:false,required:false}]},le=class i{route=g(V);router=g(G);destroyRef=g(Ce$1);state=g(R);namespaceRole=g(v);namespaceId=this.route.snapshot.params.namespaceId;isPlatformMode=this.namespaceId===void 0;isAdmin=this.isPlatformMode?Gi(true):F(this.namespaceRole.isAdminOfNamespace$(this.namespaceId),{initialValue:false});authTypeOptions=q;authTypeLabel=J;scopeOptions=[{value:"namespace",label:P.namespace},{value:"userOnNs",label:P.userOnNs},{value:"userGlobal",label:P.userGlobal}];nameControl=new _t("",{nonNullable:true,validators:[_e$1.required,_e$1.minLength(1)]});descriptionControl=new _t(null);authTypeControl=new _t("ApiKeyAuthSetting",{nonNullable:true,validators:[_e$1.required]});scopeControl=new _t("namespace",{nonNullable:true});form=new z({name:this.nameControl,description:this.descriptionControl,authType:this.authTypeControl,scope:this.scopeControl});apiKeyControl=new _t("",{nonNullable:true});usernameControl=new _t("",{nonNullable:true});passwordControl=new _t("",{nonNullable:true});tokenControl=new _t("",{nonNullable:true});discoveryUrlControl=new _t("",{nonNullable:true});authorizationUrlControl=new _t("",{nonNullable:true});tokenUrlControl=new _t("",{nonNullable:true});clientIdControl=new _t("",{nonNullable:true});clientSecretControl=new _t("",{nonNullable:true});scopesControl=new _t("",{nonNullable:true});resourceUrlControl=new _t("",{nonNullable:true});selectedAuthType=F(this.authTypeControl.valueChanges,{initialValue:this.authTypeControl.value});credentialFields=mT(()=>Se[this.selectedAuthType()]);isEditMode=Gi(false);isSubmitting=Gi(false);isLoading=Gi(false);existingConfig=null;initialCredentials={};constructor(){this.isPlatformMode||Hf(()=>{this.isAdmin()||this.isEditMode()||this.scopeControl.value==="namespace"&&this.scopeControl.setValue("userOnNs");});}ngOnInit(){this.namespaceId&&this.state.setNamespace(this.namespaceId);let t=this.route.snapshot.paramMap,e=this.route.snapshot.queryParamMap,o=t.get("authSettingId");if(o){this.isEditMode.set(true),this.scopeControl.disable(),this.authTypeControl.disable(),this.loadConfig(o);return}if(this.isPlatformMode){this.scopeControl.setValue("platform"),this.scopeControl.disable();return}let l=this.parseScope(e.get("scope"));this.scopeControl.setValue(l);let v=e.get("template");v&&this.hydrateFromTemplate(v);}parseScope(t){return t&&_e.has(t)?t:"namespace"}deriveScopeFromConfig(t){return !t.userId&&!t.namespaceId?"platform":t.userId?t.namespaceId?"userOnNs":"userGlobal":"namespace"}loadConfig(t){this.isLoading.set(true),this.state.getById(t).pipe(U(this.destroyRef)).subscribe({next:e=>{this.existingConfig=e,this.scopeControl.setValue(this.deriveScopeFromConfig(e)),this.applyConfigToForm(e),this.isLoading.set(false);},error:()=>{this.isLoading.set(false),console.warn(`[AuthSettingForm] Could not load auth setting '${t}' \u2014 navigating back`),this.navigateBack();}});}hydrateFromTemplate(t){this.isLoading.set(true),this.state.getById(t).pipe(U(this.destroyRef)).subscribe({next:e=>{this.nameControl.setValue(e.name),this.descriptionControl.setValue(e.description??null),this.authTypeControl.setValue(e.authType),this.clearCredentialControls(),this.initialCredentials={},this.isLoading.set(false),this.router.navigate([],{relativeTo:this.route,queryParams:{template:null,templateScope:null},queryParamsHandling:"merge",replaceUrl:true});},error:e=>{console.warn(`[AuthSettingForm] Could not hydrate from template ${t}:`,e),this.isLoading.set(false),this.router.navigate([],{relativeTo:this.route,queryParams:{template:null,templateScope:null},queryParamsHandling:"merge",replaceUrl:true});}});}applyConfigToForm(t){switch(this.nameControl.setValue(t.name),this.descriptionControl.setValue(t.description??null),this.authTypeControl.setValue(t.authType),this.clearCredentialControls(),this.initialCredentials={},t.authType){case "ApiKeyAuthSetting":{let e=t.apiKey??"";this.apiKeyControl.setValue(e),this.initialCredentials.apiKey=e;break}case "BasicAuthAuthSetting":{let e=t,o=e.username??"",l=e.password??"";this.usernameControl.setValue(o),this.passwordControl.setValue(l),this.initialCredentials.username=o,this.initialCredentials.password=l;break}case "BearerTokenAuthSetting":{let e=t.token??"";this.tokenControl.setValue(e),this.initialCredentials.token=e;break}case "OAuthDiscoverableAuthSetting":{let e=t;this.discoveryUrlControl.setValue(e.discoveryUrl??""),this.clientIdControl.setValue(e.clientId??""),this.clientSecretControl.setValue(e.clientSecret??""),this.scopesControl.setValue(e.scopes??""),this.initialCredentials.discoveryUrl=e.discoveryUrl??"",this.initialCredentials.clientId=e.clientId??"",this.initialCredentials.clientSecret=e.clientSecret??"",this.initialCredentials.scopes=e.scopes??"";break}case "OAuthCustomAuthSetting":{let e=t;this.authorizationUrlControl.setValue(e.authorizationUrl??""),this.tokenUrlControl.setValue(e.tokenUrl??""),this.clientIdControl.setValue(e.clientId??""),this.clientSecretControl.setValue(e.clientSecret??""),this.scopesControl.setValue(e.scopes??""),this.initialCredentials.authorizationUrl=e.authorizationUrl??"",this.initialCredentials.tokenUrl=e.tokenUrl??"",this.initialCredentials.clientId=e.clientId??"",this.initialCredentials.clientSecret=e.clientSecret??"",this.initialCredentials.scopes=e.scopes??"";break}case "OAuthRegisteredAuthSetting":{let e=t;this.authorizationUrlControl.setValue(e.authorizationUrl??""),this.tokenUrlControl.setValue(e.tokenUrl??""),this.clientIdControl.setValue(e.clientId??""),this.clientSecretControl.setValue(e.clientSecret??""),this.scopesControl.setValue(e.scopes??""),this.initialCredentials.authorizationUrl=e.authorizationUrl??"",this.initialCredentials.tokenUrl=e.tokenUrl??"",this.initialCredentials.clientId=e.clientId??"",this.initialCredentials.clientSecret=e.clientSecret??"",this.initialCredentials.scopes=e.scopes??"";break}case "OAuthMcpDiscoverableAuthSetting":{let e=t;this.resourceUrlControl.setValue(e.resourceUrl??""),this.clientIdControl.setValue(e.clientId??""),this.clientSecretControl.setValue(e.clientSecret??""),this.scopesControl.setValue(e.scopes??""),this.initialCredentials.resourceUrl=e.resourceUrl??"",this.initialCredentials.clientId=e.clientId??"",this.initialCredentials.clientSecret=e.clientSecret??"",this.initialCredentials.scopes=e.scopes??"";break}}}clearCredentialControls(){this.apiKeyControl.setValue(""),this.usernameControl.setValue(""),this.passwordControl.setValue(""),this.tokenControl.setValue(""),this.discoveryUrlControl.setValue(""),this.authorizationUrlControl.setValue(""),this.tokenUrlControl.setValue(""),this.clientIdControl.setValue(""),this.clientSecretControl.setValue(""),this.scopesControl.setValue(""),this.resourceUrlControl.setValue("");}credentialValue(t,e){if(!(this.isEditMode()&&e===this.initialCredentials[t]))return e||void 0}submit(){if(this.form.invalid||this.isSubmitting())return;if(this.isEditMode()&&!this.existingConfig?.id){this.navigateBack();return}this.isSubmitting.set(true);let t=this.nameControl.value.trim(),e=this.descriptionControl.value?.trim()||void 0,o=this.authTypeControl.value,l=this.form.getRawValue().scope,v=this.isPlatformMode?null:this.namespaceId??null,w=this.buildTypedPayload(o,t,e);(this.isEditMode()&&this.existingConfig?.id?this.state.update(this.existingConfig.id,w,this.existingConfig):this.state.create(w,l,v)).pipe(U(this.destroyRef)).subscribe({next:()=>this.navigateBack(),error:()=>this.isSubmitting.set(false)});}buildTypedPayload(t,e,o){let l={name:e,description:o};switch(t){case "ApiKeyAuthSetting":return x(w({},l),{authType:"ApiKeyAuthSetting",apiKey:this.credentialValue("apiKey",this.apiKeyControl.value)});case "BasicAuthAuthSetting":return x(w({},l),{authType:"BasicAuthAuthSetting",username:this.credentialValue("username",this.usernameControl.value),password:this.credentialValue("password",this.passwordControl.value)});case "BearerTokenAuthSetting":return x(w({},l),{authType:"BearerTokenAuthSetting",token:this.credentialValue("token",this.tokenControl.value)});case "OAuthDiscoverableAuthSetting":return x(w({},l),{authType:"OAuthDiscoverableAuthSetting",discoveryUrl:this.credentialValue("discoveryUrl",this.discoveryUrlControl.value),clientId:this.credentialValue("clientId",this.clientIdControl.value),clientSecret:this.credentialValue("clientSecret",this.clientSecretControl.value),scopes:this.credentialValue("scopes",this.scopesControl.value)});case "OAuthCustomAuthSetting":return x(w({},l),{authType:"OAuthCustomAuthSetting",authorizationUrl:this.credentialValue("authorizationUrl",this.authorizationUrlControl.value),tokenUrl:this.credentialValue("tokenUrl",this.tokenUrlControl.value),clientId:this.credentialValue("clientId",this.clientIdControl.value),clientSecret:this.credentialValue("clientSecret",this.clientSecretControl.value),scopes:this.credentialValue("scopes",this.scopesControl.value)});case "OAuthRegisteredAuthSetting":return x(w({},l),{authType:"OAuthRegisteredAuthSetting",authorizationUrl:this.credentialValue("authorizationUrl",this.authorizationUrlControl.value),tokenUrl:this.credentialValue("tokenUrl",this.tokenUrlControl.value),clientId:this.credentialValue("clientId",this.clientIdControl.value),clientSecret:this.credentialValue("clientSecret",this.clientSecretControl.value),scopes:this.credentialValue("scopes",this.scopesControl.value)});case "OAuthMcpDiscoverableAuthSetting":return x(w({},l),{authType:"OAuthMcpDiscoverableAuthSetting",resourceUrl:this.credentialValue("resourceUrl",this.resourceUrlControl.value),clientId:this.credentialValue("clientId",this.clientIdControl.value),clientSecret:this.credentialValue("clientSecret",this.clientSecretControl.value),scopes:this.credentialValue("scopes",this.scopesControl.value)})}}controlForField(t){return {apiKey:this.apiKeyControl,username:this.usernameControl,password:this.passwordControl,token:this.tokenControl,discoveryUrl:this.discoveryUrlControl,authorizationUrl:this.authorizationUrlControl,tokenUrl:this.tokenUrlControl,clientId:this.clientIdControl,clientSecret:this.clientSecretControl,scopes:this.scopesControl,resourceUrl:this.resourceUrlControl}[t]}cancel(){this.navigateBack();}navigateBack(){this.isPlatformMode?this.router.navigate(["/agentos","admin","auth-settings"]):this.router.navigate(["/agentos",this.namespaceId,"auth-settings"]);}trackByScope(t,e){return e.value}trackByField(t,e){return e.key}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=xw({type:i,selectors:[["agentos-auth-setting-form"]],decls:10,vars:2,consts:[[1,"auth-setting-form"],[1,"auth-setting-form__header"],["type","button","title","Back to auth settings",1,"auth-setting-form__back",3,"click"],[1,"auth-setting-form__back-icon"],[1,"auth-setting-form__title"],[1,"auth-setting-form__loading"],[1,"auth-setting-form__form",3,"formGroup"],[1,"auth-setting-form__form",3,"ngSubmit","formGroup"],[1,"auth-setting-form__scope",3,"disabled"],[1,"auth-setting-form__field"],["for","as-auth-type",1,"auth-setting-form__label"],["aria-hidden","true"],["id","as-auth-type",1,"auth-setting-form__select",3,"formControl"],[3,"value"],["for","as-name",1,"auth-setting-form__label"],["id","as-name","type","text","placeholder","e.g. GitHub OAuth App","autocomplete","off",1,"auth-setting-form__input",3,"formControl"],["for","as-description",1,"auth-setting-form__label"],["id","as-description","type","text","placeholder","Optional \u2014 short description of this auth setting","autocomplete","off",1,"auth-setting-form__input",3,"formControl"],[1,"auth-setting-form__credentials"],[1,"auth-setting-form__actions"],["type","submit",1,"auth-setting-form__btn","auth-setting-form__btn--primary",3,"disabled"],["type","button",1,"auth-setting-form__btn",3,"click"],[1,"auth-setting-form__label"],[1,"auth-setting-form__scope-option"],["type","radio",3,"formControl","value","disabled"],[1,"auth-setting-form__credentials-hint"],[1,"auth-setting-form__label",3,"for"],[3,"id","type","placeholder","formControl","autocomplete"],[1,"auth-setting-form__field-hint",3,"id"]],template:function(e,o){e&1&&(ws(0,"div",0)(1,"header",1)(2,"button",2),Rg("click",function(){return o.cancel()}),ws(3,"span",3),GC(4,"\u2190"),pl(),GC(5," Auth Settings "),pl(),ws(6,"h1",4),GC(7),pl()(),Jw(8,se,2,0,"p",5)(9,ye,26,8,"form",6),pl()),e&2&&(XE(7),Yg(o.isEditMode()?"Edit auth setting":"New auth setting"),XE(),eC(o.isLoading()?8:9));},dependencies:[ni,Jn,Qn,ei,Ye,At,mn,Zn,Xn,Cn,En],styles:[".auth-setting-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem;padding:1.5rem;max-width:640px}.auth-setting-form__header[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.auth-setting-form__back[_ngcontent-%COMP%]{display:inline-flex;align-items:center;gap:.4rem;background:none;border:none;cursor:pointer;color:var(--color-text-secondary);font-size:.85rem;padding:0}.auth-setting-form__back[_ngcontent-%COMP%]:hover{color:var(--color-primary)}.auth-setting-form__back-icon[_ngcontent-%COMP%]{font-size:1rem}.auth-setting-form__title[_ngcontent-%COMP%]{font-size:1.4rem;font-weight:600;color:var(--color-text);margin:0}.auth-setting-form__loading[_ngcontent-%COMP%]{color:var(--color-text-secondary);font-size:.9rem}.auth-setting-form__form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.25rem}.auth-setting-form__scope[_ngcontent-%COMP%]{border:1px solid var(--color-border);border-radius:8px;padding:.75rem 1rem;display:flex;flex-direction:column;gap:.5rem}.auth-setting-form__scope[_ngcontent-%COMP%] legend[_ngcontent-%COMP%]{padding:0 .25rem}.auth-setting-form__scope-option[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;cursor:pointer;font-size:.9rem;color:var(--color-text)}.auth-setting-form__field[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.35rem}.auth-setting-form__field-hint[_ngcontent-%COMP%]{font-size:.75rem;color:var(--color-text-secondary);margin:0;line-height:1.4}.auth-setting-form__label[_ngcontent-%COMP%]{font-size:.85rem;font-weight:500;color:var(--color-text-secondary)}.auth-setting-form__input[_ngcontent-%COMP%]{border:1px solid var(--color-border);border-radius:6px;padding:.5rem .75rem;background:var(--color-bg-secondary);color:var(--color-text);font-size:.9rem;outline:none;transition:border-color .15s ease;width:100%;box-sizing:border-box}.auth-setting-form__input[_ngcontent-%COMP%]:focus{border-color:var(--color-primary)}.auth-setting-form__input--secret[_ngcontent-%COMP%]{font-family:monospace;letter-spacing:.05em}.auth-setting-form__select[_ngcontent-%COMP%]{border:1px solid var(--color-border);border-radius:6px;padding:.5rem .75rem;background:var(--color-bg-secondary);color:var(--color-text);font-size:.9rem;outline:none;cursor:pointer;transition:border-color .15s ease}.auth-setting-form__select[_ngcontent-%COMP%]:focus{border-color:var(--color-primary)}.auth-setting-form__credentials[_ngcontent-%COMP%]{border:1px solid var(--color-border);border-radius:8px;padding:.75rem 1rem 1rem;display:flex;flex-direction:column;gap:.75rem;margin:0}.auth-setting-form__credentials[_ngcontent-%COMP%] legend[_ngcontent-%COMP%]{padding:0 .25rem}.auth-setting-form__credentials-hint[_ngcontent-%COMP%]{font-size:.78rem;color:var(--color-text-secondary);margin:0}.auth-setting-form__actions[_ngcontent-%COMP%]{display:flex;gap:.75rem;align-items:center;padding-top:.5rem}.auth-setting-form__btn[_ngcontent-%COMP%]{border:1px solid var(--color-border);border-radius:6px;padding:.5rem 1.25rem;cursor:pointer;font-size:.9rem;font-weight:500;background:var(--color-bg-secondary);color:var(--color-text);transition:background .15s ease}.auth-setting-form__btn[_ngcontent-%COMP%]:hover:not(:disabled){background:var(--color-bg-hover)}.auth-setting-form__btn[_ngcontent-%COMP%]:disabled{opacity:.5;cursor:not-allowed}.auth-setting-form__btn--primary[_ngcontent-%COMP%]{background:var(--color-primary);color:var(--color-on-primary, #fff);border-color:var(--color-primary)}.auth-setting-form__btn--primary[_ngcontent-%COMP%]:hover:not(:disabled){background:var(--color-primary-hover, var(--color-primary))}"]})};
2
+ export{le as AuthSettingFormComponent};
@@ -1,2 +1,2 @@
1
- import {n as ne}from'./chunk-C2eLmHLe.js';import {g,Y as z$1,Z as Ue,e as xw,_ as zt,a0 as jt,a1 as Vt,a2 as Nt,h as hr,i as pr,k as ws,n as GC,o as pl,J as Jw,q as Rg,X as XE,z as Ug,a5 as vl,a8 as Yg,v as eC,u as bg,a9 as lC,ai as tm,aa as If,ac as gC,aj as KC,ab as wf,a3 as VI,ak as em,a6 as UI}from'./main-RV7LPVHR.js';import {y as yt,w as wt,t as ti,Z as Zn,c as cn}from'./chunk-lTYooNBT.js';function G(c,p){if(c&1){let t=lC();ws(0,"mat-checkbox",5),tm("ngModelChange",function(l){If(t);let f=gC();return KC(f.checkboxChecked,l)||(f.checkboxChecked=l),wf(l)}),GC(1),pl(),VI();}if(c&2){let t=gC();em("ngModel",t.checkboxChecked),UI(),XE(),Yg(t.data.checkboxLabel);}}var z=class c{dialogRef=g(z$1);data=g(Ue);checkboxChecked=false;confirm(){this.dialogRef.close({confirmed:true,checkboxChecked:this.checkboxChecked});}cancel(){this.dialogRef.close({confirmed:false});}static \u0275fac=function(t){return new(t||c)};static \u0275cmp=xw({type:c,selectors:[["app-confirm-dialog"]],decls:13,vars:8,consts:[["mat-dialog-title",""],[3,"ngModel"],["align","end"],["mat-button","",3,"click"],["mat-flat-button","",3,"click","color"],[3,"ngModelChange","ngModel"]],template:function(t,e){t&1&&(ws(0,"h2",0)(1,"mat-icon"),GC(2,"warning"),pl(),GC(3),pl(),ws(4,"mat-dialog-content")(5,"p"),GC(6),pl(),Jw(7,G,2,2,"mat-checkbox",1),pl(),ws(8,"mat-dialog-actions",2)(9,"button",3),Rg("click",function(){return e.cancel()}),GC(10),pl(),ws(11,"button",4),Rg("click",function(){return e.confirm()}),GC(12),pl()()),t&2&&(XE(),Ug("destructive",!!e.data.isDestructive),XE(2),vl(" ",e.data.title,`
1
+ import {n as ne}from'./chunk-C7774IZF.js';import {g,Z as z$1,_ as Ue,e as xw,$ as zt,a0 as jt,a1 as Vt,a2 as Nt,h as hr,i as pr,k as ws,n as GC,o as pl,J as Jw,q as Rg,X as XE,A as Ug,a5 as vl,a8 as Yg,y as eC,v as bg,a9 as lC,ai as tm,aa as If,ac as gC,aj as KC,ab as wf,a3 as VI,ak as em,a6 as UI}from'./main-A4H3MFZY.js';import {y as yt,w as wt,t as ti,Z as Zn,c as cn}from'./chunk-CFuJNk7Q.js';function G(c,p){if(c&1){let t=lC();ws(0,"mat-checkbox",5),tm("ngModelChange",function(l){If(t);let f=gC();return KC(f.checkboxChecked,l)||(f.checkboxChecked=l),wf(l)}),GC(1),pl(),VI();}if(c&2){let t=gC();em("ngModel",t.checkboxChecked),UI(),XE(),Yg(t.data.checkboxLabel);}}var z=class c{dialogRef=g(z$1);data=g(Ue);checkboxChecked=false;confirm(){this.dialogRef.close({confirmed:true,checkboxChecked:this.checkboxChecked});}cancel(){this.dialogRef.close({confirmed:false});}static \u0275fac=function(t){return new(t||c)};static \u0275cmp=xw({type:c,selectors:[["app-confirm-dialog"]],decls:13,vars:8,consts:[["mat-dialog-title",""],[3,"ngModel"],["align","end"],["mat-button","",3,"click"],["mat-flat-button","",3,"click","color"],[3,"ngModelChange","ngModel"]],template:function(t,e){t&1&&(ws(0,"h2",0)(1,"mat-icon"),GC(2,"warning"),pl(),GC(3),pl(),ws(4,"mat-dialog-content")(5,"p"),GC(6),pl(),Jw(7,G,2,2,"mat-checkbox",1),pl(),ws(8,"mat-dialog-actions",2)(9,"button",3),Rg("click",function(){return e.cancel()}),GC(10),pl(),ws(11,"button",4),Rg("click",function(){return e.confirm()}),GC(12),pl()()),t&2&&(XE(),Ug("destructive",!!e.data.isDestructive),XE(2),vl(" ",e.data.title,`
2
2
  `),XE(3),Yg(e.data.message),XE(),eC(e.data.checkboxLabel?7:-1),XE(3),Yg(e.data.cancelLabel??"Cancel"),XE(),bg("color",e.data.isDestructive?"warn":"primary"),XE(),vl(" ",e.data.confirmLabel??"Confirm"," "));},dependencies:[zt,jt,Vt,Nt,hr,pr,yt,wt,ne,ti,Zn,cn],styles:["h2[mat-dialog-title][_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem}h2[mat-dialog-title][_ngcontent-%COMP%] mat-icon.destructive[_ngcontent-%COMP%]{color:var(--color-error, #f44336)}mat-dialog-content[_ngcontent-%COMP%] p[_ngcontent-%COMP%]{color:var(--color-text-secondary);line-height:1.5}mat-dialog-content[_ngcontent-%COMP%] mat-checkbox[_ngcontent-%COMP%]{display:block;margin-top:8px;font-size:.875rem}"]})};export{z};
@@ -0,0 +1 @@
1
+ import {a}from'./chunk-1nyEsjkY.js';import {o}from'./chunk-BwapsUV-.js';import {s,d}from'./chunk-BJ3cmxps.js';import {g,ao as V,G as G$1,C as Ce,a as Gi,m as mT,b as U,Q as By,a7 as ya,W as br,e as xw,s as si,k as ws,q as Rg,n as GC,o as pl,J as Jw,X as XE,y as eC,ac as gC,v as bg,a9 as lC,a8 as Yg,A as Ug,a5 as vl,T as Tg,t as rC,z as oC,S as Sg,bf as aT,bg as uT,a4 as nC,aa as If,ab as wf,bj as aE}from'./main-A4H3MFZY.js';import'./chunk-D2VUzw11.js';import'./chunk-B0es9TQT.js';import'./chunk-D6Uyjin9.js';import'./chunk-CFuJNk7Q.js';var J=(e,n)=>n.name+n.grant;function K(e,n){if(e&1&&(ws(0,"a",5),GC(1,"Edit skill \u2192"),pl()),e&2){let i=gC();bg("routerLink",i.editRoute());}}function q(e,n){e&1&&(ws(0,"span",6),GC(1,"Platform level"),pl());}function Q(e,n){e&1&&(ws(0,"p",7),GC(1,"Loading\u2026"),pl());}function W(e,n){e&1&&(ws(0,"p",8),GC(1,"Failed to load skill."),pl());}function X(e,n){if(e&1&&(ws(0,"dt",13),GC(1,"Created by"),pl(),ws(2,"dd",15),GC(3),pl()),e&2){let i=gC(2);XE(3),Yg(i.createdBy);}}function Y(e,n){if(e&1&&(ws(0,"dt",13),GC(1,"Last updated"),pl(),ws(2,"dd",15),GC(3),pl()),e&2){let i=gC(2);XE(3),Yg(i.updatedOn);}}function Z(e,n){if(e&1&&(Jw(0,X,4,1),Jw(1,Y,4,1)),e&2){let i=gC();eC(i.createdBy?0:-1),XE(),eC(i.updatedOn?1:-1);}}function ee(e,n){if(e&1&&(ws(0,"span",17),GC(1),pl()),e&2){let i=gC(2);XE(),vl("(",i.consumers().length,")");}}function te(e,n){e&1&&(ws(0,"p",18),GC(1," A platform skill is offered to every namespace. Open it from a namespace to see which of its agents use it. "),pl());}function ne(e,n){e&1&&(ws(0,"p",18),GC(1,"Loading\u2026"),pl());}function ie(e,n){e&1&&(ws(0,"p",8),GC(1," The agent configs could not be read, so it is unknown whether any agent uses this skill. "),pl());}function oe(e,n){e&1&&(ws(0,"p",18),GC(1,"No agent references this skill."),pl());}function le(e,n){e&1&&(ws(0,"span",16),GC(1,"platform agent"),pl());}function ae(e,n){e&1&&(ws(0,"span",16),GC(1,"via *"),pl());}function re(e,n){if(e&1&&(ws(0,"li",24)(1,"span",26),GC(2),pl(),Jw(3,le,2,0,"span",16),Jw(4,ae,2,0,"span",16),pl()),e&2){let i=n.$implicit;XE(2),Yg(i.name),XE(),eC(i.platform?3:-1),XE(),eC(i.grant==="all"?4:-1);}}function se(e,n){if(e&1&&(ws(0,"ul",23),rC(1,re,5,3,"li",24,J),pl(),ws(3,"p",25),GC(4," An agent listed "),ws(5,"code"),GC(6,"via *"),pl(),GC(7," takes the whole catalogue and keeps working without this skill. The others name it, so deleting the skill leaves their selector resolving to nothing. "),pl()),e&2){let i=gC(2);XE(),oC(i.consumers());}}function ce(e,n){if(e&1&&(Sg(0,"div",21),aT(1,"agentosMarkdown")),e&2){let i=gC();bg("innerHTML",uT(1,1,i.body),aE);}}function de(e,n){e&1&&(ws(0,"p",18),GC(1,"No resources bundled with this skill."),pl());}function pe(e,n){if(e&1&&(ws(0,"pre",30),GC(1),pl()),e&2){let i=gC().$implicit,a=gC(3);XE(),Yg(a.resourceContent(i));}}function me(e,n){if(e&1){let i=lC();ws(0,"li",27)(1,"button",28),Rg("click",function(){let s=If(i).$implicit,g=gC(3);return wf(g.toggleResource(s))}),ws(2,"span",29),GC(3),pl(),ws(4,"span",20),GC(5,"\u25BC"),pl()(),Jw(6,pe,2,1,"pre",30),pl();}if(e&2){let i=n.$implicit,a=gC(3);XE(),Tg("aria-expanded",a.isResourceExpanded(i)),XE(2),Yg(i),XE(),Ug("skill-inspect__chevron--open",a.isResourceExpanded(i)),XE(2),eC(a.isResourceExpanded(i)?6:-1);}}function _e(e,n){if(e&1&&(ws(0,"ul",22),rC(1,me,7,5,"li",27,nC),pl()),e&2){let i=gC(2);XE(),oC(i.resourcePaths());}}function ge(e,n){if(e&1){let i=lC();ws(0,"div",9)(1,"section",10)(2,"h2",11),GC(3,"General"),pl(),ws(4,"dl",12)(5,"dt",13),GC(6,"Name"),pl(),ws(7,"dd",14),GC(8),pl(),ws(9,"dt",13),GC(10,"Description"),pl(),ws(11,"dd",15),GC(12),pl(),ws(13,"dt",13),GC(14,"Scope"),pl(),ws(15,"dd",15),GC(16),pl(),ws(17,"dt",13),GC(18,"Storage"),pl(),ws(19,"dd",15)(20,"span",16),GC(21),pl()(),Jw(22,Z,2,2),pl()(),ws(23,"section",10)(24,"h2",11),GC(25," Used by "),Jw(26,ee,2,1,"span",17),pl(),Jw(27,te,2,0,"p",18)(28,ne,2,0,"p",18)(29,ie,2,0,"p",8)(30,oe,2,0,"p",18)(31,se,8,0),pl(),ws(32,"section",10)(33,"button",19),Rg("click",function(){If(i);let s=gC();return wf(s.toggleBody())}),ws(34,"h2",11),GC(35,"Body"),pl(),ws(36,"span",20),GC(37,"\u25BC"),pl()(),Jw(38,ce,2,3,"div",21),pl(),ws(39,"section",10)(40,"h2",11),GC(41," Resources "),ws(42,"span",17),GC(43),pl()(),Jw(44,de,2,0,"p",18)(45,_e,3,0,"ul",22),pl()();}if(e&2){let i=n,a=gC();XE(8),Yg(i.name),XE(4),Yg(i.description),XE(4),Yg(i.namespaceId?"Namespace":"Platform"),XE(4),Ug("skill-inspect__badge--readonly",a.isFilesystemBacked()),XE(),vl(" ",a.isFilesystemBacked()?"SKILL.md file (read-only)":"Database"," "),XE(),eC(a.isFilesystemBacked()?-1:22),XE(4),eC(!a.isPlatformMode&&!a.consumersLoading()&&!a.consumersUnavailable()?26:-1),XE(),eC(a.isPlatformMode?27:a.consumersLoading()?28:a.consumersUnavailable()?29:a.consumers().length===0?30:31),XE(6),Tg("aria-expanded",!a.bodyCollapsed()),XE(3),Ug("skill-inspect__chevron--open",!a.bodyCollapsed()),XE(2),eC(a.bodyCollapsed()?-1:38),XE(5),vl("(",a.resourcePaths().length,")"),XE(),eC(a.resourcePaths().length===0?44:45);}}var G=class e{route=g(V);router=g(G$1);destroyRef=g(Ce);skillState=g(o);agentState=g(s);namespaceId=this.route.snapshot.params.namespaceId;skillId=this.route.snapshot.params.skillId;isPlatformMode=!this.namespaceId;isLoading=Gi(true);hasError=Gi(false);skill=Gi(null);bodyCollapsed=Gi(false);expandedResources=Gi(new Set);resourcePaths=mT(()=>Object.keys(this.skill()?.resources??{}).sort());isFilesystemBacked=mT(()=>this.skill()?.readOnly===true);consumers=Gi([]);consumersUnavailable=Gi(false);consumersLoading=Gi(false);ngOnInit(){this.skillState.getById(this.skillId).pipe(U(this.destroyRef)).subscribe({next:n=>{this.skill.set(n),this.isLoading.set(false),this.loadConsumers(n.name);},error:()=>{this.hasError.set(true),this.isLoading.set(false);}});}loadConsumers(n){this.namespaceId&&(this.consumersLoading.set(true),By({namespace:this.agentState.listByNamespace(this.namespaceId),platform:this.agentState.listPlatform().pipe(ya(()=>br([])))}).pipe(U(this.destroyRef)).subscribe({next:({namespace:i,platform:a})=>{let s=[...this.toConsumers(i,n,false),...this.toConsumers(a,n,true)];this.consumers.set([...s.filter(g=>g.grant==="named"),...s.filter(g=>g.grant==="all")]),this.consumersLoading.set(false);},error:()=>{this.consumersUnavailable.set(true),this.consumersLoading.set(false);}}));}toConsumers(n,i,a$1){return n.map(s=>({config:s,grant:a(s.skillSelectors,i)})).filter(s=>s.grant!=="none").map(({config:s,grant:g})=>({name:s.name,grant:g,platform:a$1}))}toggleBody(){this.bodyCollapsed.update(n=>!n);}toggleResource(n){this.expandedResources.update(i=>{let a=new Set(i);return a.has(n)?a.delete(n):a.add(n),a});}isResourceExpanded(n){return this.expandedResources().has(n)}resourceContent(n){return this.skill()?.resources?.[n]??""}editRoute(){return this.isPlatformMode?["/agentos","admin","skills",this.skillId,"edit"]:["/agentos",this.namespaceId,"skills",this.skillId,"edit"]}back(){this.isPlatformMode?this.router.navigate(["/agentos","admin","skills"]):this.router.navigate(["/agentos",this.namespaceId,"skills"]);}static \u0275fac=function(i){return new(i||e)};static \u0275cmp=xw({type:e,selectors:[["agentos-skill-inspect"]],decls:13,vars:3,consts:[[1,"skill-inspect"],[1,"skill-inspect__header"],["type","button","title","Back to skills",1,"skill-inspect__back",3,"click"],[1,"skill-inspect__back-icon"],[1,"skill-inspect__title"],[1,"skill-inspect__sibling-link",3,"routerLink"],[1,"skill-inspect__platform-badge"],[1,"skill-inspect__loading"],["role","alert",1,"skill-inspect__error"],[1,"skill-inspect__content"],[1,"skill-inspect__section"],[1,"skill-inspect__section-title"],[1,"skill-inspect__dl"],[1,"skill-inspect__dt"],[1,"skill-inspect__dd","skill-inspect__dd--mono"],[1,"skill-inspect__dd"],[1,"skill-inspect__badge"],[1,"skill-inspect__count"],[1,"skill-inspect__empty"],["type","button",1,"skill-inspect__collapsible",3,"click"],[1,"skill-inspect__chevron"],[1,"skill-inspect__body",3,"innerHTML"],[1,"skill-inspect__resources"],[1,"skill-inspect__consumers"],[1,"skill-inspect__consumer"],[1,"skill-inspect__consumers-hint"],[1,"skill-inspect__consumer-name"],[1,"skill-inspect__resource"],["type","button",1,"skill-inspect__resource-header",3,"click"],[1,"skill-inspect__resource-path"],[1,"skill-inspect__resource-content"]],template:function(i,a){if(i&1&&(ws(0,"div",0)(1,"header",1)(2,"button",2),Rg("click",function(){return a.back()}),ws(3,"span",3),GC(4,"\u2190"),pl(),GC(5," Skills "),pl(),ws(6,"h1",4),GC(7,"Skill"),pl(),Jw(8,K,2,1,"a",5),Jw(9,q,2,0,"span",6),pl(),Jw(10,Q,2,0,"p",7)(11,W,2,0,"p",8)(12,ge,46,15,"div",9),pl()),i&2){let s;XE(8),eC(a.skill()&&!a.isFilesystemBacked()?8:-1),XE(),eC(a.isPlatformMode?9:-1),XE(),eC(a.isLoading()?10:a.hasError()?11:(s=a.skill())?12:-1,s);}},dependencies:[si,d],styles:[".skill-inspect[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:2rem;max-width:720px;margin:0 auto;padding:2rem 1rem}.skill-inspect__header[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.skill-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}.skill-inspect__back[_ngcontent-%COMP%]:hover{text-decoration:underline}.skill-inspect__back-icon[_ngcontent-%COMP%]{font-size:1rem;line-height:1}.skill-inspect__title[_ngcontent-%COMP%]{margin:0;font-size:1.5rem;font-weight:600;color:var(--color-text, #1d1d1f);letter-spacing:-.02em}.skill-inspect__sibling-link[_ngcontent-%COMP%]{font-size:.8125rem;color:var(--color-primary, #007aff);text-decoration:none}.skill-inspect__sibling-link[_ngcontent-%COMP%]:hover{text-decoration:underline}.skill-inspect__platform-badge[_ngcontent-%COMP%]{align-self:flex-start;font-family:var(--font-heading);font-size:11px;font-weight:600;letter-spacing:.08em;text-transform:uppercase;padding:.15rem .5rem;border:1px solid var(--color-divider, rgba(0, 0, 0, .12));color:var(--color-neutral-600, #6e6e73)}.skill-inspect__loading[_ngcontent-%COMP%], .skill-inspect__error[_ngcontent-%COMP%], .skill-inspect__empty[_ngcontent-%COMP%]{margin:0;font-size:.9rem;color:var(--color-text-secondary, #6e6e73)}.skill-inspect__error[_ngcontent-%COMP%]{color:var(--color-error, #ff3b30)}.skill-inspect__content[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.5rem}.skill-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}.skill-inspect__section-title[_ngcontent-%COMP%]{margin:0;font-size:.9375rem;font-weight:600;color:var(--color-text, #1d1d1f)}.skill-inspect__count[_ngcontent-%COMP%]{font-weight:400;color:var(--color-text-secondary, #6e6e73);font-size:.875rem;margin-left:.25rem}.skill-inspect__dl[_ngcontent-%COMP%]{display:grid;grid-template-columns:max-content 1fr;gap:.5rem 1.25rem;margin:0}.skill-inspect__dt[_ngcontent-%COMP%]{font-size:.8125rem;font-weight:500;color:var(--color-text-secondary, #6e6e73);align-self:center}.skill-inspect__dd[_ngcontent-%COMP%]{margin:0;font-size:.9375rem;color:var(--color-text, #1d1d1f);align-self:center;word-break:break-word}.skill-inspect__dd--mono[_ngcontent-%COMP%]{font-family:monospace;font-size:.875rem}.skill-inspect__consumers[_ngcontent-%COMP%]{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:.375rem}.skill-inspect__consumer[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;align-items:center;gap:.5rem}.skill-inspect__consumer-name[_ngcontent-%COMP%]{font-size:.9rem;font-weight:500}.skill-inspect__consumers-hint[_ngcontent-%COMP%]{margin:.5rem 0 0;font-size:.8rem;color:var(--color-text-secondary, #6e6e73);line-height:1.4}.skill-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)}.skill-inspect__badge--readonly[_ngcontent-%COMP%]{background:var(--color-surface-muted, rgba(0, 0, 0, .06));color:var(--color-text, #1d1d1f);border:1px solid var(--color-divider, rgba(0, 0, 0, .12))}.skill-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}.skill-inspect__chevron[_ngcontent-%COMP%]{font-size:.7rem;color:var(--color-text-secondary, #6e6e73);transition:transform .15s ease;flex-shrink:0}.skill-inspect__chevron--open[_ngcontent-%COMP%]{transform:rotate(180deg)}.skill-inspect__body[_ngcontent-%COMP%]{font-size:.9375rem;line-height:1.6;color:var(--color-text, #1d1d1f);max-height:520px;overflow-y:auto;padding:.875rem 1rem;border-radius:6px;background:var(--color-surface-muted, rgba(0, 0, 0, .04));word-break:break-word}.skill-inspect__body[_ngcontent-%COMP%] [_ngcontent-%COMP%]:first-child{margin-top:0}.skill-inspect__body[_ngcontent-%COMP%] [_ngcontent-%COMP%]:last-child{margin-bottom:0}.skill-inspect__body[_ngcontent-%COMP%] pre[_ngcontent-%COMP%], .skill-inspect__body[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{font-family:var(--font-code, monospace);font-size:.8125rem}.skill-inspect__body[_ngcontent-%COMP%] pre[_ngcontent-%COMP%]{padding:.75rem;border-radius:6px;background:var(--color-code-bg, rgba(0, 0, 0, .06));overflow-x:auto}.skill-inspect__resources[_ngcontent-%COMP%]{list-style:none;margin:0;padding:0;display:flex;flex-direction:column;gap:.5rem}.skill-inspect__resource[_ngcontent-%COMP%]{border:1px solid var(--color-border, rgba(0, 0, 0, .08));border-radius:6px;overflow:hidden}.skill-inspect__resource-header[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:space-between;gap:.75rem;width:100%;background:none;border:none;padding:.625rem .875rem;cursor:pointer;font-family:inherit;text-align:left}.skill-inspect__resource-header[_ngcontent-%COMP%]:hover{background:var(--color-bg-hover, rgba(0, 0, 0, .04))}.skill-inspect__resource-path[_ngcontent-%COMP%]{font-family:var(--font-code, monospace);font-size:.8125rem;color:var(--color-text, #1d1d1f);word-break:break-all}.skill-inspect__resource-content[_ngcontent-%COMP%]{margin:0;padding:.875rem;font-family:var(--font-code, monospace);font-size:.8125rem;color:var(--color-text, #1d1d1f);background:var(--color-surface-muted, rgba(0, 0, 0, .04));white-space:pre-wrap;word-break:break-word;max-height:320px;overflow-y:auto}"]})};export{G as SkillInspectComponent};
@@ -1,4 +1,4 @@
1
- import {c as ce,s as se,b as at$1,d as de}from'./chunk-M4Cpl726.js';import {b as Fr,w as wr,k as kr,g as gt,Q as Qi,F as Fn,K as Ki}from'./chunk-BLhKuE4K.js';import {W as We,Q as Qt}from'./chunk-KM2T1f6P.js';import {aL as wo,aM as Zn,bD as ge,aO as wt,bE as vt,g,bN as F,bs as Tl,az as Xt,bt as Qn,aT as Ut,aR as Fs,c4 as On,aW as C,aS as K,an as ue,G as Gi,bQ as Gy,bR as Id,bS as va,bP as Wy,al as vt$1,ae as kt,r as re,by as um,c5 as Et,ap as wd,aA as an$1,bu as Ve,c6 as Rt,bH as Pt$1,c1 as E,e as xw,c7 as _e$1,aC as Tu,a_ as QT,c8 as KT,bA as yC,k as ws,q as Rg,J as Jw,o as pl,c9 as kf,S as Sg,af as Eg,t as CC,X as XE,T as Tg,v as eC,u as bg,b5 as nT,z as Ug,B as Pg,E as EC,I as IC,bv as Fg,bL as pe,c3 as kt$1,n as GC,ac as gC,a8 as Yg,a9 as lC,aa as If,ab as wf,bB as vC,b$ as kC}from'./main-RV7LPVHR.js';import {_,b as _e,d as an,E as En}from'./chunk-lTYooNBT.js';var Qe=["trigger"],Ye=["panel"],Ue=[[["mat-select-trigger"]],"*"],Xe=["mat-select-trigger","*"];function Je(a,_){if(a&1&&(ws(0,"span",4),GC(1),pl()),a&2){let e=gC();XE(),Yg(e.placeholder);}}function Ze(a,_){a&1&&vC(0);}function $e(a,_){if(a&1&&(ws(0,"span",11),GC(1),pl()),a&2){let e=gC(2);XE(),Yg(e.triggerValue);}}function et(a,_){if(a&1&&(ws(0,"span",5),Jw(1,Ze,1,0)(2,$e,2,1,"span",11),pl()),a&2){let e=gC();XE(),eC(e.customTrigger?1:2);}}function tt(a,_){if(a&1){let e=lC();ws(0,"div",12,1),Rg("keydown",function(i){If(e);let n=gC();return wf(n._handleKeydown(i))}),vC(2,1),pl();}if(a&2){let e=gC();kC(e.panelClass),Ug("mat-select-panel-animations-enabled",!e._animationsDisabled)("mat-primary",e._parentFormField?.color==="primary")("mat-accent",e._parentFormField?.color==="accent")("mat-warn",e._parentFormField?.color==="warn")("mat-undefined",!e._parentFormField?.color),Tg("id",e.id+"-panel")("aria-multiselectable",e.multiple)("aria-label",e.ariaLabel||null)("aria-labelledby",e._getPanelAriaLabelledby());}}var it=new C("mat-select-scroll-strategy",{providedIn:"root",factory:()=>{let a=g(pe);return ()=>kt$1(a)}}),nt=new C("MAT_SELECT_CONFIG"),at=new C("MatSelectTrigger"),B=class{source;value;constructor(_,e){this.source=_,this.value=e;}},Lt=(()=>{class a{_viewportRuler=g(F);_changeDetectorRef=g(Tl);_elementRef=g(Xt);_dir=g(Qn,{optional:true});_idGenerator=g(Ut);_renderer=g(Fs);_parentFormField=g(se,{optional:true});ngControl=g(_,{self:true,optional:true});_liveAnnouncer=g(On);_defaultOptions=g(nt,{optional:true});_animationsDisabled=K();_popoverLocation;_initialized=new ue;_cleanupDetach;options;optionGroups;customTrigger;_positions=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom",panelClass:"mat-mdc-select-panel-above"},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom",panelClass:"mat-mdc-select-panel-above"}];_scrollOptionIntoView(e){let t=this.options.toArray()[e];if(t){let i=this.panel.nativeElement,n=wr(e,this.options,this.optionGroups),r=t._getHostElement();e===0&&n===1?i.scrollTop=0:i.scrollTop=kr(r.offsetTop,r.offsetHeight,i.scrollTop,i.offsetHeight);}}_positioningSettled(){this._scrollOptionIntoView(this._keyManager.activeItemIndex||0);}_getChangeEvent(e){return new B(this,e)}_scrollStrategyFactory=g(it);_panelOpen=false;_compareWith=(e,t)=>e===t;_uid=this._idGenerator.getId("mat-select-");_triggerAriaLabelledBy=null;_previousControl;_destroy=new ue;_errorStateTracker;stateChanges=new ue;disableAutomaticLabeling=true;userAriaDescribedBy;_selectionModel;_keyManager;_preferredOverlayOrigin;_overlayWidth;_onChange=()=>{};_onTouched=()=>{};_valueId=this._idGenerator.getId("mat-select-value-");_scrollStrategy;_overlayPanelClass=this._defaultOptions?.overlayPanelClass||"";get focused(){return this._focused||this._panelOpen}_focused=false;controlType="mat-select";trigger;panel;_overlayDir;panelClass;disabled=false;get disableRipple(){return this._disableRipple()}set disableRipple(e){this._disableRipple.set(e);}_disableRipple=Gi(false);tabIndex=0;get hideSingleSelectionIndicator(){return this._hideSingleSelectionIndicator}set hideSingleSelectionIndicator(e){this._hideSingleSelectionIndicator=e,this._syncParentProperties();}_hideSingleSelectionIndicator=this._defaultOptions?.hideSingleSelectionIndicator??false;get placeholder(){return this._placeholder}set placeholder(e){this._placeholder=e,this.stateChanges.next();}_placeholder;get required(){return this._required??this.ngControl?.control?.hasValidator(_e.required)??false}set required(e){this._required=e,this.stateChanges.next();}_required;get multiple(){return this._multiple}set multiple(e){this._selectionModel,this._multiple=e;}_multiple=false;disableOptionCentering=this._defaultOptions?.disableOptionCentering??false;get compareWith(){return this._compareWith}set compareWith(e){this._compareWith=e,this._selectionModel&&this._initializeSelection();}get value(){return this._value}set value(e){this._assignValue(e)&&this._onChange(e);}_value;ariaLabel="";ariaLabelledby;get errorStateMatcher(){return this._errorStateTracker.matcher}set errorStateMatcher(e){this._errorStateTracker.matcher=e;}typeaheadDebounceInterval;sortComparator;get id(){return this._id}set id(e){this._id=e||this._uid,this.stateChanges.next();}_id;get errorState(){return this._errorStateTracker.errorState}set errorState(e){this._errorStateTracker.errorState=e;}panelWidth=this._defaultOptions&&typeof this._defaultOptions.panelWidth<"u"?this._defaultOptions.panelWidth:"auto";canSelectNullableOptions=this._defaultOptions?.canSelectNullableOptions??false;optionSelectionChanges=Gy(()=>{let e=this.options;return e?e.changes.pipe(Id(e),va(()=>Wy(...e.map(t=>t.onSelectionChange)))):this._initialized.pipe(va(()=>this.optionSelectionChanges))});openedChange=new vt$1;_openedStream=this.openedChange.pipe(kt(e=>e),re(()=>{}));_closedStream=this.openedChange.pipe(kt(e=>!e),re(()=>{}));selectionChange=new vt$1;valueChange=new vt$1;constructor(){let e=g(We),t=g(an,{optional:true}),i=g(En,{optional:true}),n=g(new um("tabindex"),{optional:true}),r=g(Et,{optional:true}),d=g(at$1,{optional:true,self:true});this.ngControl&&(this.ngControl.valueAccessor=this),this._defaultOptions?.typeaheadDebounceInterval!=null&&(this.typeaheadDebounceInterval=this._defaultOptions.typeaheadDebounceInterval),this._errorStateTracker=new Qt(e,d||this.ngControl,i,t,this.stateChanges),this._scrollStrategy=this._scrollStrategyFactory(),this.tabIndex=n==null?0:parseInt(n)||0,this._popoverLocation=r?.usePopover===false?null:"inline",this.id=this.id;}ngOnInit(){this._selectionModel=new gt(this.multiple),this.stateChanges.next(),this._viewportRuler.change().pipe(wd(this._destroy)).subscribe(()=>{this.panelOpen&&(this._overlayWidth=this._getOverlayWidth(this._preferredOverlayOrigin),this._changeDetectorRef.detectChanges());});}ngAfterContentInit(){this._initialized.next(),this._initialized.complete(),this._initKeyManager(),this._selectionModel.changed.pipe(wd(this._destroy)).subscribe(e=>{e.added.forEach(t=>t.select()),e.removed.forEach(t=>t.deselect());}),this.options.changes.pipe(Id(null),wd(this._destroy)).subscribe(()=>{this._resetOptions(),this._initializeSelection();});}ngDoCheck(){let e=this._getTriggerAriaLabelledby(),t=this.ngControl;if(e!==this._triggerAriaLabelledBy){let i=this._elementRef.nativeElement;this._triggerAriaLabelledBy=e,e?i.setAttribute("aria-labelledby",e):i.removeAttribute("aria-labelledby");}t&&(this._previousControl!==t.control&&(this._previousControl!==void 0&&t.disabled!==null&&t.disabled!==this.disabled&&(this.disabled=t.disabled),this._previousControl=t.control),this.updateErrorState());}ngOnChanges(e){(e.disabled||e.userAriaDescribedBy)&&this.stateChanges.next(),e.typeaheadDebounceInterval&&this._keyManager&&this._keyManager.withTypeAhead(this.typeaheadDebounceInterval),e.panelClass&&this.panelClass instanceof Set&&(this.panelClass=Array.from(this.panelClass));}ngOnDestroy(){this._cleanupDetach?.(),this._keyManager?.destroy(),this._destroy.next(),this._destroy.complete(),this.stateChanges.complete();}toggle(){this.panelOpen?this.close():this.open();}open(){this._canOpen()&&(this._parentFormField&&(this._preferredOverlayOrigin=this._parentFormField.getConnectedOverlayOrigin()),this._cleanupDetach?.(),this._overlayWidth=this._getOverlayWidth(this._preferredOverlayOrigin),this._panelOpen=true,this._overlayDir.positionChange.pipe(an$1(1)).subscribe(()=>{this._changeDetectorRef.detectChanges(),this._positioningSettled();}),this._overlayDir.attachOverlay(),this._keyManager.withHorizontalOrientation(null),this._highlightCorrectOption(),this._changeDetectorRef.markForCheck(),this.stateChanges.next(),Promise.resolve().then(()=>this.openedChange.emit(true)));}close(){this._panelOpen&&(this._panelOpen=false,this._exitAndDetach(),this._keyManager.withHorizontalOrientation(this._isRtl()?"rtl":"ltr"),this._changeDetectorRef.markForCheck(),this._onTouched(),this.stateChanges.next(),Promise.resolve().then(()=>this.openedChange.emit(false)));}_exitAndDetach(){if(this._animationsDisabled||!this.panel){this._detachOverlay();return}this._cleanupDetach?.(),this._cleanupDetach=()=>{t(),clearTimeout(i),this._cleanupDetach=void 0;};let e=this.panel.nativeElement,t=this._renderer.listen(e,"animationend",n=>{n.animationName==="_mat-select-exit"&&(this._cleanupDetach?.(),this._detachOverlay());}),i=setTimeout(()=>{this._cleanupDetach?.(),this._detachOverlay();},200);e.classList.add("mat-select-panel-exit");}_detachOverlay(){this._overlayDir.detachOverlay(),this._changeDetectorRef.markForCheck();}writeValue(e){this._assignValue(e);}registerOnChange(e){this._onChange=e;}registerOnTouched(e){this._onTouched=e;}setDisabledState(e){this.disabled=e,this._changeDetectorRef.markForCheck(),this.stateChanges.next();}get panelOpen(){return this._panelOpen}get selected(){return this.multiple?this._selectionModel?.selected||[]:this._selectionModel?.selected[0]}get triggerValue(){if(this.empty)return "";if(this._multiple){let e=this._selectionModel.selected.map(t=>t.viewValue);return this._isRtl()&&e.reverse(),e.join(", ")}return this._selectionModel.selected[0].viewValue}updateErrorState(){this._errorStateTracker.updateErrorState();}_isRtl(){return this._dir?this._dir.value==="rtl":false}_handleKeydown(e){this.disabled||(this.panelOpen?this._handleOpenKeydown(e):this._handleClosedKeydown(e));}_handleClosedKeydown(e){let t=e.keyCode,i=t===40||t===38||t===37||t===39,n=t===13||t===32,r=this._keyManager;if(!r.isTyping()&&n&&!Ve(e)||(this.multiple||e.altKey)&&i)e.preventDefault(),this.open();else if(!this.multiple){let d=this.selected;r.onKeydown(e);let o=this.selected;o&&d!==o&&this._liveAnnouncer.announce(o.viewValue,1e4);}}_handleOpenKeydown(e){let t=this._keyManager,i=e.keyCode,n=i===40||i===38,r=t.isTyping();if(n&&e.altKey)e.preventDefault(),this.close();else if(!r&&(i===13||i===32)&&t.activeItem&&!Ve(e))e.preventDefault(),t.activeItem._selectViaInteraction();else if(!r&&this._multiple&&i===65&&e.ctrlKey){e.preventDefault();let d=this.options.some(o=>!o.disabled&&!o.selected);this.options.forEach(o=>{o.disabled||(d?o.select():o.deselect());});}else {let d=t.activeItemIndex;t.onKeydown(e),this._multiple&&n&&e.shiftKey&&t.activeItem&&t.activeItemIndex!==d&&t.activeItem._selectViaInteraction();}}_handleOverlayKeydown(e){e.keyCode===27&&!Ve(e)&&(e.preventDefault(),this.close());}_onFocus(){this.disabled||(this._focused=true,this.stateChanges.next());}_onBlur(){this._focused=false,this._keyManager?.cancelTypeahead(),!this.disabled&&!this.panelOpen&&(this._onTouched(),this._changeDetectorRef.markForCheck(),this.stateChanges.next());}get empty(){return !this._selectionModel||this._selectionModel.isEmpty()}_initializeSelection(){Promise.resolve().then(()=>{this.ngControl&&(this._value=this.ngControl.value),this._setSelectionByValue(this._value),this.stateChanges.next();});}_setSelectionByValue(e){if(this.options.forEach(t=>t.setInactiveStyles()),this._selectionModel.clear(),this.multiple&&e)e.forEach(t=>this._selectOptionByValue(t)),this._sortValues();else {let t=this._selectOptionByValue(e);t?this._keyManager.updateActiveItem(t):this.panelOpen||this._keyManager.updateActiveItem(-1);}this._changeDetectorRef.markForCheck();}_selectOptionByValue(e){let t=this.options.find(i=>{if(this._selectionModel.isSelected(i))return false;try{return (i.value!=null||this.canSelectNullableOptions)&&this._compareWith(i.value,e)}catch(n){return false}});return t&&this._selectionModel.select(t),t}_assignValue(e){return e!==this._value||this._multiple&&Array.isArray(e)?(this.options&&this._setSelectionByValue(e),this._value=e,true):false}_skipPredicate=e=>this.panelOpen?false:e.disabled;_getOverlayWidth(e){return this.panelWidth==="auto"?(e instanceof Rt?e.elementRef:e||this._elementRef).nativeElement.getBoundingClientRect().width:this.panelWidth===null?"":this.panelWidth}_syncParentProperties(){if(this.options)for(let e of this.options)e._changeDetectorRef.markForCheck();}_initKeyManager(){this._keyManager=new Pt$1(this.options).withTypeAhead(this.typeaheadDebounceInterval).withVerticalOrientation().withHorizontalOrientation(this._isRtl()?"rtl":"ltr").withHomeAndEnd().withPageUpDown().withAllowedModifierKeys(["shiftKey"]).skipPredicate(this._skipPredicate),this._keyManager.tabOut.subscribe(()=>{this.panelOpen&&(!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction(),this.focus(),this.close());}),this._keyManager.change.subscribe(()=>{this._panelOpen&&this.panel?this._scrollOptionIntoView(this._keyManager.activeItemIndex||0):!this._panelOpen&&!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction();});}_resetOptions(){let e=Wy(this.options.changes,this._destroy);this.optionSelectionChanges.pipe(wd(e)).subscribe(t=>{this._onSelect(t.source,t.isUserInput),t.isUserInput&&!this.multiple&&this._panelOpen&&(this.close(),this.focus());}),Wy(...this.options.map(t=>t._stateChanges)).pipe(wd(e)).subscribe(()=>{this._changeDetectorRef.detectChanges(),this.stateChanges.next();});}_onSelect(e,t){let i=this._selectionModel.isSelected(e);!this.canSelectNullableOptions&&e.value==null&&!this._multiple?(e.deselect(),this._selectionModel.clear(),this.value!=null&&this._propagateChanges(e.value)):(i!==e.selected&&(e.selected?this._selectionModel.select(e):this._selectionModel.deselect(e)),t&&this._keyManager.setActiveItem(e),this.multiple&&(this._sortValues(),t&&this.focus())),i!==this._selectionModel.isSelected(e)&&this._propagateChanges(),this.stateChanges.next();}_sortValues(){if(this.multiple){let e=this.options.toArray();this._selectionModel.sort((t,i)=>this.sortComparator?this.sortComparator(t,i,e):e.indexOf(t)-e.indexOf(i)),this.stateChanges.next();}}_propagateChanges(e){let t;this.multiple?t=this.selected.map(i=>i.value):t=this.selected?this.selected.value:e,this._value=t,this.valueChange.emit(t),this._onChange(t),this.selectionChange.emit(this._getChangeEvent(t)),this._changeDetectorRef.markForCheck();}_highlightCorrectOption(){if(this._keyManager)if(this.empty){let e=-1;for(let t=0;t<this.options.length;t++)if(!this.options.get(t).disabled){e=t;break}this._keyManager.setActiveItem(e);}else this._keyManager.setActiveItem(this._selectionModel.selected[0]);}_canOpen(){return !this._panelOpen&&!this.disabled&&this.options?.length>0&&!!this._overlayDir}focus(e){this._elementRef.nativeElement.focus(e);}_getPanelAriaLabelledby(){if(this.ariaLabel)return null;let e=this._parentFormField?.getLabelId()||null,t=e?e+" ":"";return this.ariaLabelledby?t+this.ariaLabelledby:e}_getAriaActiveDescendant(){return this.panelOpen&&this._keyManager&&this._keyManager.activeItem?this._keyManager.activeItem.id:null}_getTriggerAriaLabelledby(){if(this.ariaLabel)return null;let e=this._parentFormField?.getLabelId()||"";return this.ariaLabelledby&&(e+=" "+this.ariaLabelledby),e||(e=this._valueId),e}get describedByIds(){return this._elementRef.nativeElement.getAttribute("aria-describedby")?.split(" ")||[]}setDescribedByIds(e){let t=this._elementRef.nativeElement;e.length?t.setAttribute("aria-describedby",e.join(" ")):t.removeAttribute("aria-describedby");}onContainerClick(e){let t=E(e);t&&(t.tagName==="MAT-OPTION"||t.classList.contains("cdk-overlay-backdrop")||t.closest(".mat-mdc-select-panel"))||(this.focus(),this.open());}get shouldLabelFloat(){return this.panelOpen||!this.empty||this.focused&&!!this.placeholder}static \u0275fac=function(t){return new(t||a)};static \u0275cmp=xw({type:a,selectors:[["mat-select"]],contentQueries:function(t,i,n){if(t&1&&Fg(n,at,5)(n,Fn,5)(n,Ki,5),t&2){let r;EC(r=IC())&&(i.customTrigger=r.first),EC(r=IC())&&(i.options=r),EC(r=IC())&&(i.optionGroups=r);}},viewQuery:function(t,i){if(t&1&&Pg(Qe,5)(Ye,5)(_e$1,5),t&2){let n;EC(n=IC())&&(i.trigger=n.first),EC(n=IC())&&(i.panel=n.first),EC(n=IC())&&(i._overlayDir=n.first);}},hostAttrs:["role","combobox","aria-haspopup","listbox",1,"mat-mdc-select"],hostVars:21,hostBindings:function(t,i){t&1&&Rg("keydown",function(r){return i._handleKeydown(r)})("focus",function(){return i._onFocus()})("blur",function(){return i._onBlur()}),t&2&&(Tg("id",i.id)("tabindex",i.disabled?-1:i.tabIndex)("aria-controls",i.panelOpen?i.id+"-panel":null)("aria-expanded",i.panelOpen)("aria-label",i.ariaLabel||null)("aria-required",i.required.toString())("aria-disabled",i.disabled.toString())("aria-invalid",i.errorState)("aria-activedescendant",i._getAriaActiveDescendant()),Ug("mat-mdc-select-disabled",i.disabled)("mat-mdc-select-invalid",i.errorState)("mat-mdc-select-required",i.required)("mat-mdc-select-empty",i.empty)("mat-mdc-select-multiple",i.multiple)("mat-select-open",i.panelOpen));},inputs:{userAriaDescribedBy:[0,"aria-describedby","userAriaDescribedBy"],panelClass:"panelClass",disabled:[2,"disabled","disabled",QT],disableRipple:[2,"disableRipple","disableRipple",QT],tabIndex:[2,"tabIndex","tabIndex",e=>e==null?0:KT(e)],hideSingleSelectionIndicator:[2,"hideSingleSelectionIndicator","hideSingleSelectionIndicator",QT],placeholder:"placeholder",required:[2,"required","required",QT],multiple:[2,"multiple","multiple",QT],disableOptionCentering:[2,"disableOptionCentering","disableOptionCentering",QT],compareWith:"compareWith",value:"value",ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],errorStateMatcher:"errorStateMatcher",typeaheadDebounceInterval:[2,"typeaheadDebounceInterval","typeaheadDebounceInterval",KT],sortComparator:"sortComparator",id:"id",panelWidth:"panelWidth",canSelectNullableOptions:[2,"canSelectNullableOptions","canSelectNullableOptions",QT]},outputs:{openedChange:"openedChange",_openedStream:"opened",_closedStream:"closed",selectionChange:"selectionChange",valueChange:"valueChange"},exportAs:["matSelect"],features:[nT([{provide:de,useExisting:a},{provide:Qi,useExisting:a}]),Tu],ngContentSelectors:Xe,decls:11,vars:10,consts:[["fallbackOverlayOrigin","cdkOverlayOrigin","trigger",""],["panel",""],["cdk-overlay-origin","",1,"mat-mdc-select-trigger",3,"click"],[1,"mat-mdc-select-value"],[1,"mat-mdc-select-placeholder","mat-mdc-select-min-line"],[1,"mat-mdc-select-value-text"],[1,"mat-mdc-select-arrow-wrapper"],[1,"mat-mdc-select-arrow"],["viewBox","0 0 24 24","width","24px","height","24px","focusable","false","aria-hidden","true"],["d","M7 10l5 5 5-5z"],["cdk-connected-overlay","","cdkConnectedOverlayHasBackdrop","","cdkConnectedOverlayBackdropClass","cdk-overlay-transparent-backdrop",3,"detach","backdropClick","overlayKeydown","cdkConnectedOverlayDisableClose","cdkConnectedOverlayPanelClass","cdkConnectedOverlayScrollStrategy","cdkConnectedOverlayOrigin","cdkConnectedOverlayPositions","cdkConnectedOverlayWidth","cdkConnectedOverlayFlexibleDimensions","cdkConnectedOverlayUsePopover"],[1,"mat-mdc-select-min-line"],["role","listbox","tabindex","-1",1,"mat-mdc-select-panel","mdc-menu-surface","mdc-menu-surface--open",3,"keydown"]],template:function(t,i){if(t&1&&(yC(Ue),ws(0,"div",2,0),Rg("click",function(){return i.open()}),ws(3,"div",3),Jw(4,Je,2,1,"span",4)(5,et,3,1,"span",5),pl(),ws(6,"div",6)(7,"div",7),kf(),ws(8,"svg",8),Sg(9,"path",9),pl()()()(),Eg(10,tt,3,16,"ng-template",10),Rg("detach",function(){return i.close()})("backdropClick",function(){return i.close()})("overlayKeydown",function(r){return i._handleOverlayKeydown(r)})),t&2){let n=CC(1);XE(3),Tg("id",i._valueId),XE(),eC(i.empty?4:5),XE(6),bg("cdkConnectedOverlayDisableClose",true)("cdkConnectedOverlayPanelClass",i._overlayPanelClass)("cdkConnectedOverlayScrollStrategy",i._scrollStrategy)("cdkConnectedOverlayOrigin",i._preferredOverlayOrigin||n)("cdkConnectedOverlayPositions",i._positions)("cdkConnectedOverlayWidth",i._overlayWidth)("cdkConnectedOverlayFlexibleDimensions",true)("cdkConnectedOverlayUsePopover",i._popoverLocation);}},dependencies:[Rt,_e$1],styles:[`@keyframes _mat-select-enter {
1
+ import {c as ce,s as se,b as at$1,d as de}from'./chunk-C0RjV9YR.js';import {a as Dr,c as br,y as yr,g as gt,q as qi,F as Fn,b as $i}from'./chunk-B0es9TQT.js';import {W as We,Q as Qt}from'./chunk-D6Uyjin9.js';import {aL as wo,aM as Zn,bD as ge,aO as wt,bE as vt,g,bN as F,bs as Tl,az as Xt,bt as Qn,aT as Ut,aR as Fs,c4 as On,aW as C,aS as K,an as ue,a as Gi,bQ as Gy,bR as wd,bS as Ea,bP as Wy,al as vt$1,ae as kt,r as re,by as um,c5 as Et,ap as Cd,aA as an$1,bu as Ve,c6 as Rt,bH as Pt$1,c1 as E,e as xw,c7 as _e$1,aC as Tu,a_ as QT,c8 as KT,bA as yC,k as ws,q as Rg,J as Jw,o as pl,c9 as kf,S as Sg,af as Eg,u as CC,X as XE,T as Tg,y as eC,v as bg,b5 as nT,A as Ug,D as Pg,E as EC,I as IC,bv as Fg,bL as pe,c3 as kt$1,n as GC,ac as gC,a8 as Yg,a9 as lC,aa as If,ab as wf,bB as vC,b$ as kC}from'./main-A4H3MFZY.js';import {_,b as _e,d as an,E as En}from'./chunk-CFuJNk7Q.js';var Qe=["trigger"],Ye=["panel"],Ue=[[["mat-select-trigger"]],"*"],Xe=["mat-select-trigger","*"];function Je(a,_){if(a&1&&(ws(0,"span",4),GC(1),pl()),a&2){let e=gC();XE(),Yg(e.placeholder);}}function Ze(a,_){a&1&&vC(0);}function $e(a,_){if(a&1&&(ws(0,"span",11),GC(1),pl()),a&2){let e=gC(2);XE(),Yg(e.triggerValue);}}function et(a,_){if(a&1&&(ws(0,"span",5),Jw(1,Ze,1,0)(2,$e,2,1,"span",11),pl()),a&2){let e=gC();XE(),eC(e.customTrigger?1:2);}}function tt(a,_){if(a&1){let e=lC();ws(0,"div",12,1),Rg("keydown",function(i){If(e);let n=gC();return wf(n._handleKeydown(i))}),vC(2,1),pl();}if(a&2){let e=gC();kC(e.panelClass),Ug("mat-select-panel-animations-enabled",!e._animationsDisabled)("mat-primary",e._parentFormField?.color==="primary")("mat-accent",e._parentFormField?.color==="accent")("mat-warn",e._parentFormField?.color==="warn")("mat-undefined",!e._parentFormField?.color),Tg("id",e.id+"-panel")("aria-multiselectable",e.multiple)("aria-label",e.ariaLabel||null)("aria-labelledby",e._getPanelAriaLabelledby());}}var it=new C("mat-select-scroll-strategy",{providedIn:"root",factory:()=>{let a=g(pe);return ()=>kt$1(a)}}),nt=new C("MAT_SELECT_CONFIG"),at=new C("MatSelectTrigger"),B=class{source;value;constructor(_,e){this.source=_,this.value=e;}},Lt=(()=>{class a{_viewportRuler=g(F);_changeDetectorRef=g(Tl);_elementRef=g(Xt);_dir=g(Qn,{optional:true});_idGenerator=g(Ut);_renderer=g(Fs);_parentFormField=g(se,{optional:true});ngControl=g(_,{self:true,optional:true});_liveAnnouncer=g(On);_defaultOptions=g(nt,{optional:true});_animationsDisabled=K();_popoverLocation;_initialized=new ue;_cleanupDetach;options;optionGroups;customTrigger;_positions=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"},{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom",panelClass:"mat-mdc-select-panel-above"},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom",panelClass:"mat-mdc-select-panel-above"}];_scrollOptionIntoView(e){let t=this.options.toArray()[e];if(t){let i=this.panel.nativeElement,n=br(e,this.options,this.optionGroups),r=t._getHostElement();e===0&&n===1?i.scrollTop=0:i.scrollTop=yr(r.offsetTop,r.offsetHeight,i.scrollTop,i.offsetHeight);}}_positioningSettled(){this._scrollOptionIntoView(this._keyManager.activeItemIndex||0);}_getChangeEvent(e){return new B(this,e)}_scrollStrategyFactory=g(it);_panelOpen=false;_compareWith=(e,t)=>e===t;_uid=this._idGenerator.getId("mat-select-");_triggerAriaLabelledBy=null;_previousControl;_destroy=new ue;_errorStateTracker;stateChanges=new ue;disableAutomaticLabeling=true;userAriaDescribedBy;_selectionModel;_keyManager;_preferredOverlayOrigin;_overlayWidth;_onChange=()=>{};_onTouched=()=>{};_valueId=this._idGenerator.getId("mat-select-value-");_scrollStrategy;_overlayPanelClass=this._defaultOptions?.overlayPanelClass||"";get focused(){return this._focused||this._panelOpen}_focused=false;controlType="mat-select";trigger;panel;_overlayDir;panelClass;disabled=false;get disableRipple(){return this._disableRipple()}set disableRipple(e){this._disableRipple.set(e);}_disableRipple=Gi(false);tabIndex=0;get hideSingleSelectionIndicator(){return this._hideSingleSelectionIndicator}set hideSingleSelectionIndicator(e){this._hideSingleSelectionIndicator=e,this._syncParentProperties();}_hideSingleSelectionIndicator=this._defaultOptions?.hideSingleSelectionIndicator??false;get placeholder(){return this._placeholder}set placeholder(e){this._placeholder=e,this.stateChanges.next();}_placeholder;get required(){return this._required??this.ngControl?.control?.hasValidator(_e.required)??false}set required(e){this._required=e,this.stateChanges.next();}_required;get multiple(){return this._multiple}set multiple(e){this._selectionModel,this._multiple=e;}_multiple=false;disableOptionCentering=this._defaultOptions?.disableOptionCentering??false;get compareWith(){return this._compareWith}set compareWith(e){this._compareWith=e,this._selectionModel&&this._initializeSelection();}get value(){return this._value}set value(e){this._assignValue(e)&&this._onChange(e);}_value;ariaLabel="";ariaLabelledby;get errorStateMatcher(){return this._errorStateTracker.matcher}set errorStateMatcher(e){this._errorStateTracker.matcher=e;}typeaheadDebounceInterval;sortComparator;get id(){return this._id}set id(e){this._id=e||this._uid,this.stateChanges.next();}_id;get errorState(){return this._errorStateTracker.errorState}set errorState(e){this._errorStateTracker.errorState=e;}panelWidth=this._defaultOptions&&typeof this._defaultOptions.panelWidth<"u"?this._defaultOptions.panelWidth:"auto";canSelectNullableOptions=this._defaultOptions?.canSelectNullableOptions??false;optionSelectionChanges=Gy(()=>{let e=this.options;return e?e.changes.pipe(wd(e),Ea(()=>Wy(...e.map(t=>t.onSelectionChange)))):this._initialized.pipe(Ea(()=>this.optionSelectionChanges))});openedChange=new vt$1;_openedStream=this.openedChange.pipe(kt(e=>e),re(()=>{}));_closedStream=this.openedChange.pipe(kt(e=>!e),re(()=>{}));selectionChange=new vt$1;valueChange=new vt$1;constructor(){let e=g(We),t=g(an,{optional:true}),i=g(En,{optional:true}),n=g(new um("tabindex"),{optional:true}),r=g(Et,{optional:true}),d=g(at$1,{optional:true,self:true});this.ngControl&&(this.ngControl.valueAccessor=this),this._defaultOptions?.typeaheadDebounceInterval!=null&&(this.typeaheadDebounceInterval=this._defaultOptions.typeaheadDebounceInterval),this._errorStateTracker=new Qt(e,d||this.ngControl,i,t,this.stateChanges),this._scrollStrategy=this._scrollStrategyFactory(),this.tabIndex=n==null?0:parseInt(n)||0,this._popoverLocation=r?.usePopover===false?null:"inline",this.id=this.id;}ngOnInit(){this._selectionModel=new gt(this.multiple),this.stateChanges.next(),this._viewportRuler.change().pipe(Cd(this._destroy)).subscribe(()=>{this.panelOpen&&(this._overlayWidth=this._getOverlayWidth(this._preferredOverlayOrigin),this._changeDetectorRef.detectChanges());});}ngAfterContentInit(){this._initialized.next(),this._initialized.complete(),this._initKeyManager(),this._selectionModel.changed.pipe(Cd(this._destroy)).subscribe(e=>{e.added.forEach(t=>t.select()),e.removed.forEach(t=>t.deselect());}),this.options.changes.pipe(wd(null),Cd(this._destroy)).subscribe(()=>{this._resetOptions(),this._initializeSelection();});}ngDoCheck(){let e=this._getTriggerAriaLabelledby(),t=this.ngControl;if(e!==this._triggerAriaLabelledBy){let i=this._elementRef.nativeElement;this._triggerAriaLabelledBy=e,e?i.setAttribute("aria-labelledby",e):i.removeAttribute("aria-labelledby");}t&&(this._previousControl!==t.control&&(this._previousControl!==void 0&&t.disabled!==null&&t.disabled!==this.disabled&&(this.disabled=t.disabled),this._previousControl=t.control),this.updateErrorState());}ngOnChanges(e){(e.disabled||e.userAriaDescribedBy)&&this.stateChanges.next(),e.typeaheadDebounceInterval&&this._keyManager&&this._keyManager.withTypeAhead(this.typeaheadDebounceInterval),e.panelClass&&this.panelClass instanceof Set&&(this.panelClass=Array.from(this.panelClass));}ngOnDestroy(){this._cleanupDetach?.(),this._keyManager?.destroy(),this._destroy.next(),this._destroy.complete(),this.stateChanges.complete();}toggle(){this.panelOpen?this.close():this.open();}open(){this._canOpen()&&(this._parentFormField&&(this._preferredOverlayOrigin=this._parentFormField.getConnectedOverlayOrigin()),this._cleanupDetach?.(),this._overlayWidth=this._getOverlayWidth(this._preferredOverlayOrigin),this._panelOpen=true,this._overlayDir.positionChange.pipe(an$1(1)).subscribe(()=>{this._changeDetectorRef.detectChanges(),this._positioningSettled();}),this._overlayDir.attachOverlay(),this._keyManager.withHorizontalOrientation(null),this._highlightCorrectOption(),this._changeDetectorRef.markForCheck(),this.stateChanges.next(),Promise.resolve().then(()=>this.openedChange.emit(true)));}close(){this._panelOpen&&(this._panelOpen=false,this._exitAndDetach(),this._keyManager.withHorizontalOrientation(this._isRtl()?"rtl":"ltr"),this._changeDetectorRef.markForCheck(),this._onTouched(),this.stateChanges.next(),Promise.resolve().then(()=>this.openedChange.emit(false)));}_exitAndDetach(){if(this._animationsDisabled||!this.panel){this._detachOverlay();return}this._cleanupDetach?.(),this._cleanupDetach=()=>{t(),clearTimeout(i),this._cleanupDetach=void 0;};let e=this.panel.nativeElement,t=this._renderer.listen(e,"animationend",n=>{n.animationName==="_mat-select-exit"&&(this._cleanupDetach?.(),this._detachOverlay());}),i=setTimeout(()=>{this._cleanupDetach?.(),this._detachOverlay();},200);e.classList.add("mat-select-panel-exit");}_detachOverlay(){this._overlayDir.detachOverlay(),this._changeDetectorRef.markForCheck();}writeValue(e){this._assignValue(e);}registerOnChange(e){this._onChange=e;}registerOnTouched(e){this._onTouched=e;}setDisabledState(e){this.disabled=e,this._changeDetectorRef.markForCheck(),this.stateChanges.next();}get panelOpen(){return this._panelOpen}get selected(){return this.multiple?this._selectionModel?.selected||[]:this._selectionModel?.selected[0]}get triggerValue(){if(this.empty)return "";if(this._multiple){let e=this._selectionModel.selected.map(t=>t.viewValue);return this._isRtl()&&e.reverse(),e.join(", ")}return this._selectionModel.selected[0].viewValue}updateErrorState(){this._errorStateTracker.updateErrorState();}_isRtl(){return this._dir?this._dir.value==="rtl":false}_handleKeydown(e){this.disabled||(this.panelOpen?this._handleOpenKeydown(e):this._handleClosedKeydown(e));}_handleClosedKeydown(e){let t=e.keyCode,i=t===40||t===38||t===37||t===39,n=t===13||t===32,r=this._keyManager;if(!r.isTyping()&&n&&!Ve(e)||(this.multiple||e.altKey)&&i)e.preventDefault(),this.open();else if(!this.multiple){let d=this.selected;r.onKeydown(e);let o=this.selected;o&&d!==o&&this._liveAnnouncer.announce(o.viewValue,1e4);}}_handleOpenKeydown(e){let t=this._keyManager,i=e.keyCode,n=i===40||i===38,r=t.isTyping();if(n&&e.altKey)e.preventDefault(),this.close();else if(!r&&(i===13||i===32)&&t.activeItem&&!Ve(e))e.preventDefault(),t.activeItem._selectViaInteraction();else if(!r&&this._multiple&&i===65&&e.ctrlKey){e.preventDefault();let d=this.options.some(o=>!o.disabled&&!o.selected);this.options.forEach(o=>{o.disabled||(d?o.select():o.deselect());});}else {let d=t.activeItemIndex;t.onKeydown(e),this._multiple&&n&&e.shiftKey&&t.activeItem&&t.activeItemIndex!==d&&t.activeItem._selectViaInteraction();}}_handleOverlayKeydown(e){e.keyCode===27&&!Ve(e)&&(e.preventDefault(),this.close());}_onFocus(){this.disabled||(this._focused=true,this.stateChanges.next());}_onBlur(){this._focused=false,this._keyManager?.cancelTypeahead(),!this.disabled&&!this.panelOpen&&(this._onTouched(),this._changeDetectorRef.markForCheck(),this.stateChanges.next());}get empty(){return !this._selectionModel||this._selectionModel.isEmpty()}_initializeSelection(){Promise.resolve().then(()=>{this.ngControl&&(this._value=this.ngControl.value),this._setSelectionByValue(this._value),this.stateChanges.next();});}_setSelectionByValue(e){if(this.options.forEach(t=>t.setInactiveStyles()),this._selectionModel.clear(),this.multiple&&e)e.forEach(t=>this._selectOptionByValue(t)),this._sortValues();else {let t=this._selectOptionByValue(e);t?this._keyManager.updateActiveItem(t):this.panelOpen||this._keyManager.updateActiveItem(-1);}this._changeDetectorRef.markForCheck();}_selectOptionByValue(e){let t=this.options.find(i=>{if(this._selectionModel.isSelected(i))return false;try{return (i.value!=null||this.canSelectNullableOptions)&&this._compareWith(i.value,e)}catch(n){return false}});return t&&this._selectionModel.select(t),t}_assignValue(e){return e!==this._value||this._multiple&&Array.isArray(e)?(this.options&&this._setSelectionByValue(e),this._value=e,true):false}_skipPredicate=e=>this.panelOpen?false:e.disabled;_getOverlayWidth(e){return this.panelWidth==="auto"?(e instanceof Rt?e.elementRef:e||this._elementRef).nativeElement.getBoundingClientRect().width:this.panelWidth===null?"":this.panelWidth}_syncParentProperties(){if(this.options)for(let e of this.options)e._changeDetectorRef.markForCheck();}_initKeyManager(){this._keyManager=new Pt$1(this.options).withTypeAhead(this.typeaheadDebounceInterval).withVerticalOrientation().withHorizontalOrientation(this._isRtl()?"rtl":"ltr").withHomeAndEnd().withPageUpDown().withAllowedModifierKeys(["shiftKey"]).skipPredicate(this._skipPredicate),this._keyManager.tabOut.subscribe(()=>{this.panelOpen&&(!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction(),this.focus(),this.close());}),this._keyManager.change.subscribe(()=>{this._panelOpen&&this.panel?this._scrollOptionIntoView(this._keyManager.activeItemIndex||0):!this._panelOpen&&!this.multiple&&this._keyManager.activeItem&&this._keyManager.activeItem._selectViaInteraction();});}_resetOptions(){let e=Wy(this.options.changes,this._destroy);this.optionSelectionChanges.pipe(Cd(e)).subscribe(t=>{this._onSelect(t.source,t.isUserInput),t.isUserInput&&!this.multiple&&this._panelOpen&&(this.close(),this.focus());}),Wy(...this.options.map(t=>t._stateChanges)).pipe(Cd(e)).subscribe(()=>{this._changeDetectorRef.detectChanges(),this.stateChanges.next();});}_onSelect(e,t){let i=this._selectionModel.isSelected(e);!this.canSelectNullableOptions&&e.value==null&&!this._multiple?(e.deselect(),this._selectionModel.clear(),this.value!=null&&this._propagateChanges(e.value)):(i!==e.selected&&(e.selected?this._selectionModel.select(e):this._selectionModel.deselect(e)),t&&this._keyManager.setActiveItem(e),this.multiple&&(this._sortValues(),t&&this.focus())),i!==this._selectionModel.isSelected(e)&&this._propagateChanges(),this.stateChanges.next();}_sortValues(){if(this.multiple){let e=this.options.toArray();this._selectionModel.sort((t,i)=>this.sortComparator?this.sortComparator(t,i,e):e.indexOf(t)-e.indexOf(i)),this.stateChanges.next();}}_propagateChanges(e){let t;this.multiple?t=this.selected.map(i=>i.value):t=this.selected?this.selected.value:e,this._value=t,this.valueChange.emit(t),this._onChange(t),this.selectionChange.emit(this._getChangeEvent(t)),this._changeDetectorRef.markForCheck();}_highlightCorrectOption(){if(this._keyManager)if(this.empty){let e=-1;for(let t=0;t<this.options.length;t++)if(!this.options.get(t).disabled){e=t;break}this._keyManager.setActiveItem(e);}else this._keyManager.setActiveItem(this._selectionModel.selected[0]);}_canOpen(){return !this._panelOpen&&!this.disabled&&this.options?.length>0&&!!this._overlayDir}focus(e){this._elementRef.nativeElement.focus(e);}_getPanelAriaLabelledby(){if(this.ariaLabel)return null;let e=this._parentFormField?.getLabelId()||null,t=e?e+" ":"";return this.ariaLabelledby?t+this.ariaLabelledby:e}_getAriaActiveDescendant(){return this.panelOpen&&this._keyManager&&this._keyManager.activeItem?this._keyManager.activeItem.id:null}_getTriggerAriaLabelledby(){if(this.ariaLabel)return null;let e=this._parentFormField?.getLabelId()||"";return this.ariaLabelledby&&(e+=" "+this.ariaLabelledby),e||(e=this._valueId),e}get describedByIds(){return this._elementRef.nativeElement.getAttribute("aria-describedby")?.split(" ")||[]}setDescribedByIds(e){let t=this._elementRef.nativeElement;e.length?t.setAttribute("aria-describedby",e.join(" ")):t.removeAttribute("aria-describedby");}onContainerClick(e){let t=E(e);t&&(t.tagName==="MAT-OPTION"||t.classList.contains("cdk-overlay-backdrop")||t.closest(".mat-mdc-select-panel"))||(this.focus(),this.open());}get shouldLabelFloat(){return this.panelOpen||!this.empty||this.focused&&!!this.placeholder}static \u0275fac=function(t){return new(t||a)};static \u0275cmp=xw({type:a,selectors:[["mat-select"]],contentQueries:function(t,i,n){if(t&1&&Fg(n,at,5)(n,Fn,5)(n,$i,5),t&2){let r;EC(r=IC())&&(i.customTrigger=r.first),EC(r=IC())&&(i.options=r),EC(r=IC())&&(i.optionGroups=r);}},viewQuery:function(t,i){if(t&1&&Pg(Qe,5)(Ye,5)(_e$1,5),t&2){let n;EC(n=IC())&&(i.trigger=n.first),EC(n=IC())&&(i.panel=n.first),EC(n=IC())&&(i._overlayDir=n.first);}},hostAttrs:["role","combobox","aria-haspopup","listbox",1,"mat-mdc-select"],hostVars:21,hostBindings:function(t,i){t&1&&Rg("keydown",function(r){return i._handleKeydown(r)})("focus",function(){return i._onFocus()})("blur",function(){return i._onBlur()}),t&2&&(Tg("id",i.id)("tabindex",i.disabled?-1:i.tabIndex)("aria-controls",i.panelOpen?i.id+"-panel":null)("aria-expanded",i.panelOpen)("aria-label",i.ariaLabel||null)("aria-required",i.required.toString())("aria-disabled",i.disabled.toString())("aria-invalid",i.errorState)("aria-activedescendant",i._getAriaActiveDescendant()),Ug("mat-mdc-select-disabled",i.disabled)("mat-mdc-select-invalid",i.errorState)("mat-mdc-select-required",i.required)("mat-mdc-select-empty",i.empty)("mat-mdc-select-multiple",i.multiple)("mat-select-open",i.panelOpen));},inputs:{userAriaDescribedBy:[0,"aria-describedby","userAriaDescribedBy"],panelClass:"panelClass",disabled:[2,"disabled","disabled",QT],disableRipple:[2,"disableRipple","disableRipple",QT],tabIndex:[2,"tabIndex","tabIndex",e=>e==null?0:KT(e)],hideSingleSelectionIndicator:[2,"hideSingleSelectionIndicator","hideSingleSelectionIndicator",QT],placeholder:"placeholder",required:[2,"required","required",QT],multiple:[2,"multiple","multiple",QT],disableOptionCentering:[2,"disableOptionCentering","disableOptionCentering",QT],compareWith:"compareWith",value:"value",ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],errorStateMatcher:"errorStateMatcher",typeaheadDebounceInterval:[2,"typeaheadDebounceInterval","typeaheadDebounceInterval",KT],sortComparator:"sortComparator",id:"id",panelWidth:"panelWidth",canSelectNullableOptions:[2,"canSelectNullableOptions","canSelectNullableOptions",QT]},outputs:{openedChange:"openedChange",_openedStream:"opened",_closedStream:"closed",selectionChange:"selectionChange",valueChange:"valueChange"},exportAs:["matSelect"],features:[nT([{provide:de,useExisting:a},{provide:qi,useExisting:a}]),Tu],ngContentSelectors:Xe,decls:11,vars:10,consts:[["fallbackOverlayOrigin","cdkOverlayOrigin","trigger",""],["panel",""],["cdk-overlay-origin","",1,"mat-mdc-select-trigger",3,"click"],[1,"mat-mdc-select-value"],[1,"mat-mdc-select-placeholder","mat-mdc-select-min-line"],[1,"mat-mdc-select-value-text"],[1,"mat-mdc-select-arrow-wrapper"],[1,"mat-mdc-select-arrow"],["viewBox","0 0 24 24","width","24px","height","24px","focusable","false","aria-hidden","true"],["d","M7 10l5 5 5-5z"],["cdk-connected-overlay","","cdkConnectedOverlayHasBackdrop","","cdkConnectedOverlayBackdropClass","cdk-overlay-transparent-backdrop",3,"detach","backdropClick","overlayKeydown","cdkConnectedOverlayDisableClose","cdkConnectedOverlayPanelClass","cdkConnectedOverlayScrollStrategy","cdkConnectedOverlayOrigin","cdkConnectedOverlayPositions","cdkConnectedOverlayWidth","cdkConnectedOverlayFlexibleDimensions","cdkConnectedOverlayUsePopover"],[1,"mat-mdc-select-min-line"],["role","listbox","tabindex","-1",1,"mat-mdc-select-panel","mdc-menu-surface","mdc-menu-surface--open",3,"keydown"]],template:function(t,i){if(t&1&&(yC(Ue),ws(0,"div",2,0),Rg("click",function(){return i.open()}),ws(3,"div",3),Jw(4,Je,2,1,"span",4)(5,et,3,1,"span",5),pl(),ws(6,"div",6)(7,"div",7),kf(),ws(8,"svg",8),Sg(9,"path",9),pl()()()(),Eg(10,tt,3,16,"ng-template",10),Rg("detach",function(){return i.close()})("backdropClick",function(){return i.close()})("overlayKeydown",function(r){return i._handleOverlayKeydown(r)})),t&2){let n=CC(1);XE(3),Tg("id",i._valueId),XE(),eC(i.empty?4:5),XE(6),bg("cdkConnectedOverlayDisableClose",true)("cdkConnectedOverlayPanelClass",i._overlayPanelClass)("cdkConnectedOverlayScrollStrategy",i._scrollStrategy)("cdkConnectedOverlayOrigin",i._preferredOverlayOrigin||n)("cdkConnectedOverlayPositions",i._positions)("cdkConnectedOverlayWidth",i._overlayWidth)("cdkConnectedOverlayFlexibleDimensions",true)("cdkConnectedOverlayUsePopover",i._popoverLocation);}},dependencies:[Rt,_e$1],styles:[`@keyframes _mat-select-enter {
2
2
  from {
3
3
  opacity: 0;
4
4
  transform: scaleY(0.8);
@@ -187,4 +187,4 @@ div.mat-mdc-select-panel {
187
187
  .mat-form-field-appearance-fill .mat-mdc-select-arrow-wrapper {
188
188
  transform: var(--mat-select-arrow-transform, translateY(-8px));
189
189
  }
190
- `],encapsulation:2})}return a})();var Pt=(()=>{class a{static \u0275fac=function(t){return new(t||a)};static \u0275mod=wo({type:a});static \u0275inj=Zn({imports:[ge,Fr,wt,vt,ce,Fr]})}return a})();export{Lt as L,Pt as P};
190
+ `],encapsulation:2})}return a})();var Pt=(()=>{class a{static \u0275fac=function(t){return new(t||a)};static \u0275mod=wo({type:a});static \u0275inj=Zn({imports:[ge,Dr,wt,vt,ce,Dr]})}return a})();export{Lt as L,Pt as P};
@@ -1,4 +1,4 @@
1
- import {s as se}from'./chunk-M4Cpl726.js';import {b as Fr,Q as Qi,F as Fn,K as Ki,h as ht,w as wr,k as kr}from'./chunk-BLhKuE4K.js';import {g,D as py,P,W as x,aL as wo,aM as Zn,bD as ge,bE as vt,aO as wt,bs as Tl,az as Xt,aW as C,aS as K,bF as J,al as vt$1,aT as Ut,bG as p,bH as Pt,e as xw,a_ as QT,bA as yC,bI as Ig,b5 as nT,B as Pg,bJ as dr,E as EC,I as IC,bv as Fg,bK as fe,bL as pe,bM as mr,aP as G,bt as Qn,bN as F,aR as Fs,an as ue,O as Ot,bO as mt,bP as Wy,ae as kt$1,Q as br,r as re,bQ as Gy,bR as Id,bS as va,aF as R$1,bu as Ve$1,bT as pn,bU as Cd,bV as Zy,aA as an,bW as Y,bX as Pt$1,bY as po,bZ as X,b_ as xt,aZ as js,aC as Tu,q as Rg,T as Tg,aw as hl,bB as vC,ax as gl,ac as gC,b$ as kC,z as Ug,c0 as xg,c1 as E,c2 as ME,c3 as kt$2,bC as Si}from'./main-RV7LPVHR.js';import {D}from'./chunk-lTYooNBT.js';var xe=class a{http=g(py);projectState=g(P);getBaseUrl(){return `/api/projects/${this.projectState.getSelectedProjectIdOrThrow()}/schedulers`}listSchedulers(){return this.http.get(this.getBaseUrl())}getScheduler(o){return this.http.get(`${this.getBaseUrl()}/${o}`)}createScheduler(o){return this.http.post(this.getBaseUrl(),o)}listSchedulersForProject(o){return this.http.get(`/api/projects/${o}/schedulers`)}enableSchedulerForProject(o,e){return this.http.post(`/api/projects/${o}/schedulers/${e}/enable`,{})}disableSchedulerForProject(o,e){return this.http.post(`/api/projects/${o}/schedulers/${e}/disable`,{})}runSchedulerNowForProject(o,e){return this.http.post(`/api/projects/${o}/schedulers/${e}/run-now`,{})}deleteSchedulerForProject(o,e){return this.http.delete(`/api/projects/${o}/schedulers/${e}`)}updateSchedulerForProject(o,e,t){return this.http.put(`/api/projects/${o}/schedulers/${e}`,t)}createSchedulerForProject(o,e){return this.http.post(`/api/projects/${o}/schedulers`,e)}updateScheduler(o,e){return this.http.put(`${this.getBaseUrl()}/${o}`,e)}deleteScheduler(o){return this.http.delete(`${this.getBaseUrl()}/${o}`)}enableScheduler(o){return this.http.post(`${this.getBaseUrl()}/${o}/enable`,{})}disableScheduler(o){return this.http.post(`${this.getBaseUrl()}/${o}/disable`,{})}runSchedulerNow(o){return this.http.post(`${this.getBaseUrl()}/${o}/run-now`,{})}static \u0275fac=function(e){return new(e||a)};static \u0275prov=x({token:a,factory:a.\u0275fac,providedIn:"root"})};var Ke=["panel"],Ue=["*"];function qe(a,o){if(a&1&&(hl(0,"div",1,0),vC(2),gl()),a&2){let e=o.id,t=gC();kC(t._classList),Ug("mat-mdc-autocomplete-visible",t.showPanel)("mat-mdc-autocomplete-hidden",!t.showPanel)("mat-autocomplete-panel-animations-enabled",!t._animationsDisabled)("mat-primary",t._color==="primary")("mat-accent",t._color==="accent")("mat-warn",t._color==="warn"),xg("id",t.id),Tg("aria-label",t.ariaLabel||null)("aria-labelledby",t._getPanelAriaLabelledby(e));}}var R=class{source;option;constructor(o,e){this.source=o,this.option=e;}},Ve=new C("mat-autocomplete-default-options",{providedIn:"root",factory:()=>({autoActiveFirstOption:false,autoSelectActiveOption:false,hideSingleSelectionIndicator:false,requireSelection:false,hasBackdrop:false})}),Ct=(()=>{class a{_changeDetectorRef=g(Tl);_elementRef=g(Xt);_defaults=g(Ve);_animationsDisabled=K();_activeOptionChanges=J.EMPTY;_keyManager;showPanel=false;get isOpen(){return this._isOpen&&this.showPanel}_isOpen=false;_latestOpeningTrigger;_setColor(e){this._color=e,this._changeDetectorRef.markForCheck();}_color;template;panel;options;optionGroups;ariaLabel;ariaLabelledby;displayWith=null;autoActiveFirstOption;autoSelectActiveOption;requireSelection;panelWidth;disableRipple=false;optionSelected=new vt$1;opened=new vt$1;closed=new vt$1;optionActivated=new vt$1;set classList(e){this._classList=e,this._elementRef.nativeElement.className="";}_classList;get hideSingleSelectionIndicator(){return this._hideSingleSelectionIndicator}set hideSingleSelectionIndicator(e){this._hideSingleSelectionIndicator=e,this._syncParentProperties();}_hideSingleSelectionIndicator;_syncParentProperties(){if(this.options)for(let e of this.options)e._changeDetectorRef.markForCheck();}id=g(Ut).getId("mat-autocomplete-");inertGroups;constructor(){let e=g(p);this.inertGroups=e?.SAFARI||false,this.autoActiveFirstOption=!!this._defaults.autoActiveFirstOption,this.autoSelectActiveOption=!!this._defaults.autoSelectActiveOption,this.requireSelection=!!this._defaults.requireSelection,this._hideSingleSelectionIndicator=this._defaults.hideSingleSelectionIndicator??false;}ngAfterContentInit(){this._keyManager=new Pt(this.options).withWrap().skipPredicate(this._skipPredicate),this._activeOptionChanges=this._keyManager.change.subscribe(e=>{this.isOpen&&this.optionActivated.emit({source:this,option:this.options.toArray()[e]||null});}),this._setVisibility();}ngOnDestroy(){this._keyManager?.destroy(),this._activeOptionChanges.unsubscribe();}_setScrollTop(e){this.panel&&(this.panel.nativeElement.scrollTop=e);}_getScrollTop(){return this.panel?this.panel.nativeElement.scrollTop:0}_setVisibility(){this.showPanel=!!this.options?.length,this._changeDetectorRef.markForCheck();}_emitSelectEvent(e){let t=new R(this,e);this.optionSelected.emit(t);}_getPanelAriaLabelledby(e){if(this.ariaLabel)return null;let t=e?e+" ":"";return this.ariaLabelledby?t+this.ariaLabelledby:e}_skipPredicate(){return false}static \u0275fac=function(t){return new(t||a)};static \u0275cmp=xw({type:a,selectors:[["mat-autocomplete"]],contentQueries:function(t,i,n){if(t&1&&Fg(n,Fn,5)(n,Ki,5),t&2){let s;EC(s=IC())&&(i.options=s),EC(s=IC())&&(i.optionGroups=s);}},viewQuery:function(t,i){if(t&1&&Pg(dr,7)(Ke,5),t&2){let n;EC(n=IC())&&(i.template=n.first),EC(n=IC())&&(i.panel=n.first);}},hostAttrs:[1,"mat-mdc-autocomplete"],inputs:{ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],displayWith:"displayWith",autoActiveFirstOption:[2,"autoActiveFirstOption","autoActiveFirstOption",QT],autoSelectActiveOption:[2,"autoSelectActiveOption","autoSelectActiveOption",QT],requireSelection:[2,"requireSelection","requireSelection",QT],panelWidth:"panelWidth",disableRipple:[2,"disableRipple","disableRipple",QT],classList:[0,"class","classList"],hideSingleSelectionIndicator:[2,"hideSingleSelectionIndicator","hideSingleSelectionIndicator",QT]},outputs:{optionSelected:"optionSelected",opened:"opened",closed:"closed",optionActivated:"optionActivated"},exportAs:["matAutocomplete"],features:[nT([{provide:Qi,useExisting:a}])],ngContentSelectors:Ue,decls:1,vars:0,consts:[["panel",""],["role","listbox",1,"mat-mdc-autocomplete-panel","mdc-menu-surface","mdc-menu-surface--open",3,"id"]],template:function(t,i){t&1&&(yC(),Ig(0,qe,3,17,"ng-template"));},styles:[`div.mat-mdc-autocomplete-panel {
1
+ import {s as se}from'./chunk-C0RjV9YR.js';import {a as Dr,q as qi,F as Fn,b as $i,h as ht,c as br$1,y as yr}from'./chunk-B0es9TQT.js';import {g,H as py,P,Y as x,aL as wo,aM as Zn,bD as ge,bE as vt,aO as wt,bs as Tl,az as Xt,aW as C,aS as K,bF as J,al as vt$1,aT as Ut,bG as p,bH as Pt,e as xw,a_ as QT,bA as yC,bI as Ig,b5 as nT,D as Pg,bJ as dr,E as EC,I as IC,bv as Fg,bK as fe,bL as pe,bM as mr,aP as G,bt as Qn,bN as F,aR as Fs,an as ue,O as Ot,bO as mt,bP as Wy,ae as kt$1,W as br,r as re,bQ as Gy,bR as wd,bS as Ea,aF as R$1,bu as Ve$1,bT as pn,bU as Od,bV as Zy,aA as an,bW as Y,bX as Pt$1,bY as po,bZ as X,b_ as xt,aZ as js,aC as Tu,q as Rg,T as Tg,aw as hl,bB as vC,ax as gl,ac as gC,b$ as kC,A as Ug,c0 as xg,c1 as E,c2 as ME,c3 as kt$2,bC as Si}from'./main-A4H3MFZY.js';import {D}from'./chunk-CFuJNk7Q.js';var xe=class a{http=g(py);projectState=g(P);getBaseUrl(){return `/api/projects/${this.projectState.getSelectedProjectIdOrThrow()}/schedulers`}listSchedulers(){return this.http.get(this.getBaseUrl())}getScheduler(o){return this.http.get(`${this.getBaseUrl()}/${o}`)}createScheduler(o){return this.http.post(this.getBaseUrl(),o)}listSchedulersForProject(o){return this.http.get(`/api/projects/${o}/schedulers`)}enableSchedulerForProject(o,e){return this.http.post(`/api/projects/${o}/schedulers/${e}/enable`,{})}disableSchedulerForProject(o,e){return this.http.post(`/api/projects/${o}/schedulers/${e}/disable`,{})}runSchedulerNowForProject(o,e){return this.http.post(`/api/projects/${o}/schedulers/${e}/run-now`,{})}deleteSchedulerForProject(o,e){return this.http.delete(`/api/projects/${o}/schedulers/${e}`)}updateSchedulerForProject(o,e,t){return this.http.put(`/api/projects/${o}/schedulers/${e}`,t)}createSchedulerForProject(o,e){return this.http.post(`/api/projects/${o}/schedulers`,e)}updateScheduler(o,e){return this.http.put(`${this.getBaseUrl()}/${o}`,e)}deleteScheduler(o){return this.http.delete(`${this.getBaseUrl()}/${o}`)}enableScheduler(o){return this.http.post(`${this.getBaseUrl()}/${o}/enable`,{})}disableScheduler(o){return this.http.post(`${this.getBaseUrl()}/${o}/disable`,{})}runSchedulerNow(o){return this.http.post(`${this.getBaseUrl()}/${o}/run-now`,{})}static \u0275fac=function(e){return new(e||a)};static \u0275prov=x({token:a,factory:a.\u0275fac,providedIn:"root"})};var Ke=["panel"],Ue=["*"];function qe(a,o){if(a&1&&(hl(0,"div",1,0),vC(2),gl()),a&2){let e=o.id,t=gC();kC(t._classList),Ug("mat-mdc-autocomplete-visible",t.showPanel)("mat-mdc-autocomplete-hidden",!t.showPanel)("mat-autocomplete-panel-animations-enabled",!t._animationsDisabled)("mat-primary",t._color==="primary")("mat-accent",t._color==="accent")("mat-warn",t._color==="warn"),xg("id",t.id),Tg("aria-label",t.ariaLabel||null)("aria-labelledby",t._getPanelAriaLabelledby(e));}}var R=class{source;option;constructor(o,e){this.source=o,this.option=e;}},Ve=new C("mat-autocomplete-default-options",{providedIn:"root",factory:()=>({autoActiveFirstOption:false,autoSelectActiveOption:false,hideSingleSelectionIndicator:false,requireSelection:false,hasBackdrop:false})}),Ct=(()=>{class a{_changeDetectorRef=g(Tl);_elementRef=g(Xt);_defaults=g(Ve);_animationsDisabled=K();_activeOptionChanges=J.EMPTY;_keyManager;showPanel=false;get isOpen(){return this._isOpen&&this.showPanel}_isOpen=false;_latestOpeningTrigger;_setColor(e){this._color=e,this._changeDetectorRef.markForCheck();}_color;template;panel;options;optionGroups;ariaLabel;ariaLabelledby;displayWith=null;autoActiveFirstOption;autoSelectActiveOption;requireSelection;panelWidth;disableRipple=false;optionSelected=new vt$1;opened=new vt$1;closed=new vt$1;optionActivated=new vt$1;set classList(e){this._classList=e,this._elementRef.nativeElement.className="";}_classList;get hideSingleSelectionIndicator(){return this._hideSingleSelectionIndicator}set hideSingleSelectionIndicator(e){this._hideSingleSelectionIndicator=e,this._syncParentProperties();}_hideSingleSelectionIndicator;_syncParentProperties(){if(this.options)for(let e of this.options)e._changeDetectorRef.markForCheck();}id=g(Ut).getId("mat-autocomplete-");inertGroups;constructor(){let e=g(p);this.inertGroups=e?.SAFARI||false,this.autoActiveFirstOption=!!this._defaults.autoActiveFirstOption,this.autoSelectActiveOption=!!this._defaults.autoSelectActiveOption,this.requireSelection=!!this._defaults.requireSelection,this._hideSingleSelectionIndicator=this._defaults.hideSingleSelectionIndicator??false;}ngAfterContentInit(){this._keyManager=new Pt(this.options).withWrap().skipPredicate(this._skipPredicate),this._activeOptionChanges=this._keyManager.change.subscribe(e=>{this.isOpen&&this.optionActivated.emit({source:this,option:this.options.toArray()[e]||null});}),this._setVisibility();}ngOnDestroy(){this._keyManager?.destroy(),this._activeOptionChanges.unsubscribe();}_setScrollTop(e){this.panel&&(this.panel.nativeElement.scrollTop=e);}_getScrollTop(){return this.panel?this.panel.nativeElement.scrollTop:0}_setVisibility(){this.showPanel=!!this.options?.length,this._changeDetectorRef.markForCheck();}_emitSelectEvent(e){let t=new R(this,e);this.optionSelected.emit(t);}_getPanelAriaLabelledby(e){if(this.ariaLabel)return null;let t=e?e+" ":"";return this.ariaLabelledby?t+this.ariaLabelledby:e}_skipPredicate(){return false}static \u0275fac=function(t){return new(t||a)};static \u0275cmp=xw({type:a,selectors:[["mat-autocomplete"]],contentQueries:function(t,i,n){if(t&1&&Fg(n,Fn,5)(n,$i,5),t&2){let s;EC(s=IC())&&(i.options=s),EC(s=IC())&&(i.optionGroups=s);}},viewQuery:function(t,i){if(t&1&&Pg(dr,7)(Ke,5),t&2){let n;EC(n=IC())&&(i.template=n.first),EC(n=IC())&&(i.panel=n.first);}},hostAttrs:[1,"mat-mdc-autocomplete"],inputs:{ariaLabel:[0,"aria-label","ariaLabel"],ariaLabelledby:[0,"aria-labelledby","ariaLabelledby"],displayWith:"displayWith",autoActiveFirstOption:[2,"autoActiveFirstOption","autoActiveFirstOption",QT],autoSelectActiveOption:[2,"autoSelectActiveOption","autoSelectActiveOption",QT],requireSelection:[2,"requireSelection","requireSelection",QT],panelWidth:"panelWidth",disableRipple:[2,"disableRipple","disableRipple",QT],classList:[0,"class","classList"],hideSingleSelectionIndicator:[2,"hideSingleSelectionIndicator","hideSingleSelectionIndicator",QT]},outputs:{optionSelected:"optionSelected",opened:"opened",closed:"closed",optionActivated:"optionActivated"},exportAs:["matAutocomplete"],features:[nT([{provide:qi,useExisting:a}])],ngContentSelectors:Ue,decls:1,vars:0,consts:[["panel",""],["role","listbox",1,"mat-mdc-autocomplete-panel","mdc-menu-surface","mdc-menu-surface--open",3,"id"]],template:function(t,i){t&1&&(yC(),Ig(0,qe,3,17,"ng-template"));},styles:[`div.mat-mdc-autocomplete-panel {
2
2
  width: 100%;
3
3
  max-height: 256px;
4
4
  visibility: hidden;
@@ -52,4 +52,4 @@ div.mat-mdc-autocomplete-panel.mat-mdc-autocomplete-hidden,
52
52
  mat-autocomplete {
53
53
  display: none;
54
54
  }
55
- `],encapsulation:2})}return a})();var Ye={provide:D,useExisting:Si(()=>ze),multi:true};var Ge=new C("mat-autocomplete-scroll-strategy",{providedIn:"root",factory:()=>{let a=g(pe);return ()=>kt$2(a)}}),ze=(()=>{class a{_environmentInjector=g(fe);_element=g(Xt);_injector=g(pe);_viewContainerRef=g(mr);_zone=g(G);_changeDetectorRef=g(Tl);_dir=g(Qn,{optional:true});_formField=g(se,{optional:true,host:true});_viewportRuler=g(F);_scrollStrategy=g(Ge);_renderer=g(Fs);_animationsDisabled=K();_defaults=g(Ve,{optional:true});_overlayRef=null;_portal;_componentDestroyed=false;_initialized=new ue;_keydownSubscription;_outsideClickSubscription;_cleanupWindowBlur;_previousValue=null;_valueOnAttach=null;_valueOnLastKeydown=null;_positionStrategy;_manuallyFloatingLabel=false;_closingActionsSubscription;_viewportSubscription=J.EMPTY;_breakpointObserver=g(Ot);_handsetLandscapeSubscription=J.EMPTY;_canOpenOnNextFocus=true;_valueBeforeAutoSelection;_pendingAutoselectedOption=null;_closeKeyEventStream=new ue;_overlayPanelClass=mt(this._defaults?.overlayPanelClass||[]);_windowBlurHandler=()=>{this._canOpenOnNextFocus=this.panelOpen||!this._hasFocus();};_onChange=()=>{};_onTouched=()=>{};autocomplete;position="auto";connectedTo;autocompleteAttribute="off";autocompleteDisabled=false;_aboveClass="mat-mdc-autocomplete-panel-above";ngAfterViewInit(){this._initialized.next(),this._initialized.complete(),this._cleanupWindowBlur=this._renderer.listen("window","blur",this._windowBlurHandler);}ngOnChanges(e){e.position&&this._positionStrategy&&(this._setStrategyPositions(this._positionStrategy),this.panelOpen&&this._overlayRef.updatePosition());}ngOnDestroy(){this._cleanupWindowBlur?.(),this._handsetLandscapeSubscription.unsubscribe(),this._viewportSubscription.unsubscribe(),this._componentDestroyed=true,this._destroyPanel(),this._closeKeyEventStream.complete();}get panelOpen(){return this._overlayAttached&&this.autocomplete.showPanel}_overlayAttached=false;openPanel(){this._openPanelInternal();}closePanel(){this._resetLabel(),this._overlayAttached&&(this.panelOpen&&this._zone.run(()=>{this.autocomplete.closed.emit();}),this.autocomplete._latestOpeningTrigger===this&&(this.autocomplete._isOpen=false,this.autocomplete._latestOpeningTrigger=null),this._overlayAttached=false,this._pendingAutoselectedOption=null,this._overlayRef&&this._overlayRef.hasAttached()&&(this._overlayRef.detach(),this._closingActionsSubscription.unsubscribe()),this._updatePanelState(),this._componentDestroyed||this._changeDetectorRef.detectChanges());}updatePosition(){this._overlayAttached&&this._overlayRef.updatePosition();}get panelClosingActions(){return Wy(this.optionSelections,this.autocomplete._keyManager.tabOut.pipe(kt$1(()=>this._overlayAttached)),this._closeKeyEventStream,this._getOutsideClickStream(),this._overlayRef?this._overlayRef.detachments().pipe(kt$1(()=>this._overlayAttached)):br()).pipe(re(e=>e instanceof ht?e:null))}optionSelections=Gy(()=>{let e=this.autocomplete?this.autocomplete.options:null;return e?e.changes.pipe(Id(e),va(()=>Wy(...e.map(t=>t.onSelectionChange)))):this._initialized.pipe(va(()=>this.optionSelections))});get activeOption(){return this.autocomplete&&this.autocomplete._keyManager?this.autocomplete._keyManager.activeItem:null}_getOutsideClickStream(){return new R$1(e=>{let t=n=>{let s=E(n),l=this._formField?this._formField.getConnectedOverlayOrigin().nativeElement:null,E$1=this.connectedTo?this.connectedTo.elementRef.nativeElement:null;this._overlayAttached&&s!==this._element.nativeElement&&!this._hasFocus()&&(!l||!l.contains(s))&&(!E$1||!E$1.contains(s))&&this._overlayRef&&!this._overlayRef.overlayElement.contains(s)&&e.next(n);},i=[this._renderer.listen("document","click",t),this._renderer.listen("document","auxclick",t),this._renderer.listen("document","touchend",t)];return ()=>{i.forEach(n=>n());}})}writeValue(e){Promise.resolve(null).then(()=>this._assignOptionValue(e));}registerOnChange(e){this._onChange=e;}registerOnTouched(e){this._onTouched=e;}setDisabledState(e){this._element.nativeElement.disabled=e;}_handleKeydown(e){let t=e,i=t.keyCode,n=Ve$1(t);if(i===27&&!n&&t.preventDefault(),this._valueOnLastKeydown=this._element.nativeElement.value,this.activeOption&&i===13&&this.panelOpen&&!n)this.activeOption._selectViaInteraction(),this._resetActiveItem(),t.preventDefault();else if(this.autocomplete){let s=this.autocomplete._keyManager.activeItem,l=i===38||i===40;i===9||l&&!n&&this.panelOpen?this.autocomplete._keyManager.onKeydown(t):l&&this._canOpen()&&this._openPanelInternal(this._valueOnLastKeydown),(l||this.autocomplete._keyManager.activeItem!==s)&&(this._scrollToOption(this.autocomplete._keyManager.activeItemIndex||0),this.autocomplete.autoSelectActiveOption&&this.activeOption&&(this._pendingAutoselectedOption||(this._valueBeforeAutoSelection=this._valueOnLastKeydown),this._pendingAutoselectedOption=this.activeOption,this._assignOptionValue(this.activeOption.value)));}}_handleInput(e){let t=e.target,i=t.value;if(t.type==="number"&&(i=i==""?null:parseFloat(i)),this._previousValue!==i){if(this._previousValue=i,this._pendingAutoselectedOption=null,(!this.autocomplete||!this.autocomplete.requireSelection)&&this._onChange(i),!i)this._clearPreviousSelectedOption(null,false);else if(this.panelOpen&&!this.autocomplete.requireSelection){let n=this.autocomplete.options?.find(s=>s.selected);if(n){let s=this._getDisplayValue(n.value);i!==s&&n.deselect(false);}}if(this._canOpen()&&this._hasFocus()){let n=this._valueOnLastKeydown??this._element.nativeElement.value;this._valueOnLastKeydown=null,this._openPanelInternal(n);}}}_handleFocus(){this._canOpenOnNextFocus?this._canOpen()&&(this._previousValue=this._element.nativeElement.value,this._attachOverlay(this._previousValue),this._floatLabel(true)):this._canOpenOnNextFocus=true;}_handleClick(){this._canOpen()&&!this.panelOpen&&this._openPanelInternal();}_hasFocus(){return pn()===this._element.nativeElement}_floatLabel(e=false){this._formField&&this._formField.floatLabel==="auto"&&(e?this._formField._animateAndLockLabel():this._formField.floatLabel="always",this._manuallyFloatingLabel=true);}_resetLabel(){this._manuallyFloatingLabel&&(this._formField&&(this._formField.floatLabel="auto"),this._manuallyFloatingLabel=false);}_subscribeToClosingActions(){let e=new R$1(i=>{ME(()=>{i.next();},{injector:this._environmentInjector});}),t=this.autocomplete.options?.changes.pipe(Cd(()=>this._positionStrategy.reapplyLastPosition()),Zy(0))??br();return Wy(e,t).pipe(va(()=>this._zone.run(()=>{let i=this.panelOpen;return this._resetActiveItem(),this._updatePanelState(),this._changeDetectorRef.detectChanges(),this.panelOpen&&this._overlayRef.updatePosition(),i!==this.panelOpen&&(this.panelOpen?this._emitOpened():this.autocomplete.closed.emit()),this.panelClosingActions})),an(1)).subscribe(i=>this._setValueAndClose(i))}_emitOpened(){this.autocomplete.opened.emit();}_destroyPanel(){this._overlayRef&&(this.closePanel(),this._overlayRef.dispose(),this._overlayRef=null);}_getDisplayValue(e){let t=this.autocomplete;return t&&t.displayWith?t.displayWith(e):e}_assignOptionValue(e){let t=this._getDisplayValue(e);e==null&&this._clearPreviousSelectedOption(null,false),this._updateNativeInputValue(t??"");}_updateNativeInputValue(e){this._formField?this._formField._control.value=e:this._element.nativeElement.value=e,this._previousValue=e;}_setValueAndClose(e){let t=this.autocomplete,i=e?e.source:this._pendingAutoselectedOption;i?(this._clearPreviousSelectedOption(i),this._assignOptionValue(i.value),this._onChange(i.value),t._emitSelectEvent(i),this._element.nativeElement.focus()):t.requireSelection&&this._element.nativeElement.value!==this._valueOnAttach&&(this._clearPreviousSelectedOption(null),this._assignOptionValue(null),this._onChange(null)),this.closePanel();}_clearPreviousSelectedOption(e,t){this.autocomplete?.options?.forEach(i=>{i!==e&&i.selected&&i.deselect(t);});}_openPanelInternal(e=this._element.nativeElement.value){this._attachOverlay(e),this._floatLabel();}_attachOverlay(e){if(!this.autocomplete)return;let t=this._overlayRef;t?(this._positionStrategy.setOrigin(this._getConnectedElement()),t.updateSize({width:this._getPanelWidth()})):(this._portal=new Y(this.autocomplete.template,this._viewContainerRef,{id:this._formField?.getLabelId()}),t=Pt$1(this._injector,this._getOverlayConfig()),this._overlayRef=t,this._viewportSubscription=this._viewportRuler.change().subscribe(()=>{this.panelOpen&&t&&t.updateSize({width:this._getPanelWidth()});}),this._handsetLandscapeSubscription=this._breakpointObserver.observe(po.HandsetLandscape).subscribe(n=>{n.matches?this._positionStrategy.withFlexibleDimensions(true).withGrowAfterOpen(true).withViewportMargin(8):this._positionStrategy.withFlexibleDimensions(false).withGrowAfterOpen(false).withViewportMargin(0);})),t&&!t.hasAttached()&&(t.attach(this._portal),this._valueOnAttach=e,this._valueOnLastKeydown=null,this._closingActionsSubscription=this._subscribeToClosingActions());let i=this.panelOpen;this.autocomplete._isOpen=this._overlayAttached=true,this.autocomplete._latestOpeningTrigger=this,this.autocomplete._setColor(this._formField?.color),this._updatePanelState(),this.panelOpen&&i!==this.panelOpen&&this._emitOpened();}_handlePanelKeydown=e=>{(e.keyCode===27&&!Ve$1(e)||e.keyCode===38&&Ve$1(e,"altKey"))&&(this._pendingAutoselectedOption&&(this._updateNativeInputValue(this._valueBeforeAutoSelection??""),this._pendingAutoselectedOption=null),this._closeKeyEventStream.next(),this._resetActiveItem(),e.stopPropagation(),e.preventDefault());};_updatePanelState(){if(this.autocomplete._setVisibility(),this.panelOpen){let e=this._overlayRef;this._keydownSubscription||(this._keydownSubscription=e.keydownEvents().subscribe(this._handlePanelKeydown)),this._outsideClickSubscription||(this._outsideClickSubscription=e.outsidePointerEvents().subscribe());}else this._keydownSubscription?.unsubscribe(),this._outsideClickSubscription?.unsubscribe(),this._keydownSubscription=this._outsideClickSubscription=void 0;}_getOverlayConfig(){return new X({positionStrategy:this._getOverlayPosition(),scrollStrategy:this._scrollStrategy(),width:this._getPanelWidth(),direction:this._dir??void 0,hasBackdrop:this._defaults?.hasBackdrop,backdropClass:this._defaults?.backdropClass||"cdk-overlay-transparent-backdrop",panelClass:this._overlayPanelClass,disableAnimations:this._animationsDisabled})}_getOverlayPosition(){let e=xt(this._injector,this._getConnectedElement()).withFlexibleDimensions(false).withPush(false).withPopoverLocation("inline");return this._setStrategyPositions(e),this._positionStrategy=e,e}_setStrategyPositions(e){let t=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"}],i=this._aboveClass,n=[{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom",panelClass:i},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom",panelClass:i}],s;this.position==="above"?s=n:this.position==="below"?s=t:s=[...t,...n],e.withPositions(s);}_getConnectedElement(){return this.connectedTo?this.connectedTo.elementRef:this._formField?this._formField.getConnectedOverlayOrigin():this._element}_getPanelWidth(){return this.autocomplete.panelWidth||this._getHostWidth()}_getHostWidth(){return this._getConnectedElement().nativeElement.getBoundingClientRect().width}_resetActiveItem(){let e=this.autocomplete;if(e.autoActiveFirstOption){let t=-1;for(let i=0;i<e.options.length;i++)if(!e.options.get(i).disabled){t=i;break}e._keyManager.setActiveItem(t);}else e._keyManager.setActiveItem(-1);}_canOpen(){let e=this._element.nativeElement;return !e.readOnly&&!e.disabled&&!this.autocompleteDisabled}_scrollToOption(e){let t=this.autocomplete,i=wr(e,t.options,t.optionGroups);if(e===0&&i===1)t._setScrollTop(0);else if(t.panel){let n=t.options.toArray()[e];if(n){let s=n._getHostElement(),l=kr(s.offsetTop,s.offsetHeight,t._getScrollTop(),t.panel.nativeElement.offsetHeight);t._setScrollTop(l);}}}static \u0275fac=function(t){return new(t||a)};static \u0275dir=js({type:a,selectors:[["input","matAutocomplete",""],["textarea","matAutocomplete",""]],hostAttrs:[1,"mat-mdc-autocomplete-trigger"],hostVars:7,hostBindings:function(t,i){t&1&&Rg("focusin",function(){return i._handleFocus()})("blur",function(){return i._onTouched()})("input",function(s){return i._handleInput(s)})("keydown",function(s){return i._handleKeydown(s)})("click",function(){return i._handleClick()}),t&2&&Tg("autocomplete",i.autocompleteAttribute)("role",i.autocompleteDisabled?null:"combobox")("aria-autocomplete",i.autocompleteDisabled?null:"list")("aria-activedescendant",i.panelOpen&&i.activeOption?i.activeOption.id:null)("aria-expanded",i.autocompleteDisabled?null:i.panelOpen.toString())("aria-controls",i.autocompleteDisabled||!i.panelOpen?null:i.autocomplete?.id)("aria-haspopup",i.autocompleteDisabled?null:"listbox");},inputs:{autocomplete:[0,"matAutocomplete","autocomplete"],position:[0,"matAutocompletePosition","position"],connectedTo:[0,"matAutocompleteConnectedTo","connectedTo"],autocompleteAttribute:[0,"autocomplete","autocompleteAttribute"],autocompleteDisabled:[2,"matAutocompleteDisabled","autocompleteDisabled",QT]},exportAs:["matAutocompleteTrigger"],features:[nT([Ye]),Tu]})}return a})(),kt=(()=>{class a{static \u0275fac=function(t){return new(t||a)};static \u0275mod=wo({type:a});static \u0275inj=Zn({imports:[ge,Fr,vt,Fr,wt]})}return a})();export{Ct as C,kt as k,xe as x,ze as z};
55
+ `],encapsulation:2})}return a})();var Ye={provide:D,useExisting:Si(()=>ze),multi:true};var Ge=new C("mat-autocomplete-scroll-strategy",{providedIn:"root",factory:()=>{let a=g(pe);return ()=>kt$2(a)}}),ze=(()=>{class a{_environmentInjector=g(fe);_element=g(Xt);_injector=g(pe);_viewContainerRef=g(mr);_zone=g(G);_changeDetectorRef=g(Tl);_dir=g(Qn,{optional:true});_formField=g(se,{optional:true,host:true});_viewportRuler=g(F);_scrollStrategy=g(Ge);_renderer=g(Fs);_animationsDisabled=K();_defaults=g(Ve,{optional:true});_overlayRef=null;_portal;_componentDestroyed=false;_initialized=new ue;_keydownSubscription;_outsideClickSubscription;_cleanupWindowBlur;_previousValue=null;_valueOnAttach=null;_valueOnLastKeydown=null;_positionStrategy;_manuallyFloatingLabel=false;_closingActionsSubscription;_viewportSubscription=J.EMPTY;_breakpointObserver=g(Ot);_handsetLandscapeSubscription=J.EMPTY;_canOpenOnNextFocus=true;_valueBeforeAutoSelection;_pendingAutoselectedOption=null;_closeKeyEventStream=new ue;_overlayPanelClass=mt(this._defaults?.overlayPanelClass||[]);_windowBlurHandler=()=>{this._canOpenOnNextFocus=this.panelOpen||!this._hasFocus();};_onChange=()=>{};_onTouched=()=>{};autocomplete;position="auto";connectedTo;autocompleteAttribute="off";autocompleteDisabled=false;_aboveClass="mat-mdc-autocomplete-panel-above";ngAfterViewInit(){this._initialized.next(),this._initialized.complete(),this._cleanupWindowBlur=this._renderer.listen("window","blur",this._windowBlurHandler);}ngOnChanges(e){e.position&&this._positionStrategy&&(this._setStrategyPositions(this._positionStrategy),this.panelOpen&&this._overlayRef.updatePosition());}ngOnDestroy(){this._cleanupWindowBlur?.(),this._handsetLandscapeSubscription.unsubscribe(),this._viewportSubscription.unsubscribe(),this._componentDestroyed=true,this._destroyPanel(),this._closeKeyEventStream.complete();}get panelOpen(){return this._overlayAttached&&this.autocomplete.showPanel}_overlayAttached=false;openPanel(){this._openPanelInternal();}closePanel(){this._resetLabel(),this._overlayAttached&&(this.panelOpen&&this._zone.run(()=>{this.autocomplete.closed.emit();}),this.autocomplete._latestOpeningTrigger===this&&(this.autocomplete._isOpen=false,this.autocomplete._latestOpeningTrigger=null),this._overlayAttached=false,this._pendingAutoselectedOption=null,this._overlayRef&&this._overlayRef.hasAttached()&&(this._overlayRef.detach(),this._closingActionsSubscription.unsubscribe()),this._updatePanelState(),this._componentDestroyed||this._changeDetectorRef.detectChanges());}updatePosition(){this._overlayAttached&&this._overlayRef.updatePosition();}get panelClosingActions(){return Wy(this.optionSelections,this.autocomplete._keyManager.tabOut.pipe(kt$1(()=>this._overlayAttached)),this._closeKeyEventStream,this._getOutsideClickStream(),this._overlayRef?this._overlayRef.detachments().pipe(kt$1(()=>this._overlayAttached)):br()).pipe(re(e=>e instanceof ht?e:null))}optionSelections=Gy(()=>{let e=this.autocomplete?this.autocomplete.options:null;return e?e.changes.pipe(wd(e),Ea(()=>Wy(...e.map(t=>t.onSelectionChange)))):this._initialized.pipe(Ea(()=>this.optionSelections))});get activeOption(){return this.autocomplete&&this.autocomplete._keyManager?this.autocomplete._keyManager.activeItem:null}_getOutsideClickStream(){return new R$1(e=>{let t=n=>{let s=E(n),l=this._formField?this._formField.getConnectedOverlayOrigin().nativeElement:null,E$1=this.connectedTo?this.connectedTo.elementRef.nativeElement:null;this._overlayAttached&&s!==this._element.nativeElement&&!this._hasFocus()&&(!l||!l.contains(s))&&(!E$1||!E$1.contains(s))&&this._overlayRef&&!this._overlayRef.overlayElement.contains(s)&&e.next(n);},i=[this._renderer.listen("document","click",t),this._renderer.listen("document","auxclick",t),this._renderer.listen("document","touchend",t)];return ()=>{i.forEach(n=>n());}})}writeValue(e){Promise.resolve(null).then(()=>this._assignOptionValue(e));}registerOnChange(e){this._onChange=e;}registerOnTouched(e){this._onTouched=e;}setDisabledState(e){this._element.nativeElement.disabled=e;}_handleKeydown(e){let t=e,i=t.keyCode,n=Ve$1(t);if(i===27&&!n&&t.preventDefault(),this._valueOnLastKeydown=this._element.nativeElement.value,this.activeOption&&i===13&&this.panelOpen&&!n)this.activeOption._selectViaInteraction(),this._resetActiveItem(),t.preventDefault();else if(this.autocomplete){let s=this.autocomplete._keyManager.activeItem,l=i===38||i===40;i===9||l&&!n&&this.panelOpen?this.autocomplete._keyManager.onKeydown(t):l&&this._canOpen()&&this._openPanelInternal(this._valueOnLastKeydown),(l||this.autocomplete._keyManager.activeItem!==s)&&(this._scrollToOption(this.autocomplete._keyManager.activeItemIndex||0),this.autocomplete.autoSelectActiveOption&&this.activeOption&&(this._pendingAutoselectedOption||(this._valueBeforeAutoSelection=this._valueOnLastKeydown),this._pendingAutoselectedOption=this.activeOption,this._assignOptionValue(this.activeOption.value)));}}_handleInput(e){let t=e.target,i=t.value;if(t.type==="number"&&(i=i==""?null:parseFloat(i)),this._previousValue!==i){if(this._previousValue=i,this._pendingAutoselectedOption=null,(!this.autocomplete||!this.autocomplete.requireSelection)&&this._onChange(i),!i)this._clearPreviousSelectedOption(null,false);else if(this.panelOpen&&!this.autocomplete.requireSelection){let n=this.autocomplete.options?.find(s=>s.selected);if(n){let s=this._getDisplayValue(n.value);i!==s&&n.deselect(false);}}if(this._canOpen()&&this._hasFocus()){let n=this._valueOnLastKeydown??this._element.nativeElement.value;this._valueOnLastKeydown=null,this._openPanelInternal(n);}}}_handleFocus(){this._canOpenOnNextFocus?this._canOpen()&&(this._previousValue=this._element.nativeElement.value,this._attachOverlay(this._previousValue),this._floatLabel(true)):this._canOpenOnNextFocus=true;}_handleClick(){this._canOpen()&&!this.panelOpen&&this._openPanelInternal();}_hasFocus(){return pn()===this._element.nativeElement}_floatLabel(e=false){this._formField&&this._formField.floatLabel==="auto"&&(e?this._formField._animateAndLockLabel():this._formField.floatLabel="always",this._manuallyFloatingLabel=true);}_resetLabel(){this._manuallyFloatingLabel&&(this._formField&&(this._formField.floatLabel="auto"),this._manuallyFloatingLabel=false);}_subscribeToClosingActions(){let e=new R$1(i=>{ME(()=>{i.next();},{injector:this._environmentInjector});}),t=this.autocomplete.options?.changes.pipe(Od(()=>this._positionStrategy.reapplyLastPosition()),Zy(0))??br();return Wy(e,t).pipe(Ea(()=>this._zone.run(()=>{let i=this.panelOpen;return this._resetActiveItem(),this._updatePanelState(),this._changeDetectorRef.detectChanges(),this.panelOpen&&this._overlayRef.updatePosition(),i!==this.panelOpen&&(this.panelOpen?this._emitOpened():this.autocomplete.closed.emit()),this.panelClosingActions})),an(1)).subscribe(i=>this._setValueAndClose(i))}_emitOpened(){this.autocomplete.opened.emit();}_destroyPanel(){this._overlayRef&&(this.closePanel(),this._overlayRef.dispose(),this._overlayRef=null);}_getDisplayValue(e){let t=this.autocomplete;return t&&t.displayWith?t.displayWith(e):e}_assignOptionValue(e){let t=this._getDisplayValue(e);e==null&&this._clearPreviousSelectedOption(null,false),this._updateNativeInputValue(t??"");}_updateNativeInputValue(e){this._formField?this._formField._control.value=e:this._element.nativeElement.value=e,this._previousValue=e;}_setValueAndClose(e){let t=this.autocomplete,i=e?e.source:this._pendingAutoselectedOption;i?(this._clearPreviousSelectedOption(i),this._assignOptionValue(i.value),this._onChange(i.value),t._emitSelectEvent(i),this._element.nativeElement.focus()):t.requireSelection&&this._element.nativeElement.value!==this._valueOnAttach&&(this._clearPreviousSelectedOption(null),this._assignOptionValue(null),this._onChange(null)),this.closePanel();}_clearPreviousSelectedOption(e,t){this.autocomplete?.options?.forEach(i=>{i!==e&&i.selected&&i.deselect(t);});}_openPanelInternal(e=this._element.nativeElement.value){this._attachOverlay(e),this._floatLabel();}_attachOverlay(e){if(!this.autocomplete)return;let t=this._overlayRef;t?(this._positionStrategy.setOrigin(this._getConnectedElement()),t.updateSize({width:this._getPanelWidth()})):(this._portal=new Y(this.autocomplete.template,this._viewContainerRef,{id:this._formField?.getLabelId()}),t=Pt$1(this._injector,this._getOverlayConfig()),this._overlayRef=t,this._viewportSubscription=this._viewportRuler.change().subscribe(()=>{this.panelOpen&&t&&t.updateSize({width:this._getPanelWidth()});}),this._handsetLandscapeSubscription=this._breakpointObserver.observe(po.HandsetLandscape).subscribe(n=>{n.matches?this._positionStrategy.withFlexibleDimensions(true).withGrowAfterOpen(true).withViewportMargin(8):this._positionStrategy.withFlexibleDimensions(false).withGrowAfterOpen(false).withViewportMargin(0);})),t&&!t.hasAttached()&&(t.attach(this._portal),this._valueOnAttach=e,this._valueOnLastKeydown=null,this._closingActionsSubscription=this._subscribeToClosingActions());let i=this.panelOpen;this.autocomplete._isOpen=this._overlayAttached=true,this.autocomplete._latestOpeningTrigger=this,this.autocomplete._setColor(this._formField?.color),this._updatePanelState(),this.panelOpen&&i!==this.panelOpen&&this._emitOpened();}_handlePanelKeydown=e=>{(e.keyCode===27&&!Ve$1(e)||e.keyCode===38&&Ve$1(e,"altKey"))&&(this._pendingAutoselectedOption&&(this._updateNativeInputValue(this._valueBeforeAutoSelection??""),this._pendingAutoselectedOption=null),this._closeKeyEventStream.next(),this._resetActiveItem(),e.stopPropagation(),e.preventDefault());};_updatePanelState(){if(this.autocomplete._setVisibility(),this.panelOpen){let e=this._overlayRef;this._keydownSubscription||(this._keydownSubscription=e.keydownEvents().subscribe(this._handlePanelKeydown)),this._outsideClickSubscription||(this._outsideClickSubscription=e.outsidePointerEvents().subscribe());}else this._keydownSubscription?.unsubscribe(),this._outsideClickSubscription?.unsubscribe(),this._keydownSubscription=this._outsideClickSubscription=void 0;}_getOverlayConfig(){return new X({positionStrategy:this._getOverlayPosition(),scrollStrategy:this._scrollStrategy(),width:this._getPanelWidth(),direction:this._dir??void 0,hasBackdrop:this._defaults?.hasBackdrop,backdropClass:this._defaults?.backdropClass||"cdk-overlay-transparent-backdrop",panelClass:this._overlayPanelClass,disableAnimations:this._animationsDisabled})}_getOverlayPosition(){let e=xt(this._injector,this._getConnectedElement()).withFlexibleDimensions(false).withPush(false).withPopoverLocation("inline");return this._setStrategyPositions(e),this._positionStrategy=e,e}_setStrategyPositions(e){let t=[{originX:"start",originY:"bottom",overlayX:"start",overlayY:"top"},{originX:"end",originY:"bottom",overlayX:"end",overlayY:"top"}],i=this._aboveClass,n=[{originX:"start",originY:"top",overlayX:"start",overlayY:"bottom",panelClass:i},{originX:"end",originY:"top",overlayX:"end",overlayY:"bottom",panelClass:i}],s;this.position==="above"?s=n:this.position==="below"?s=t:s=[...t,...n],e.withPositions(s);}_getConnectedElement(){return this.connectedTo?this.connectedTo.elementRef:this._formField?this._formField.getConnectedOverlayOrigin():this._element}_getPanelWidth(){return this.autocomplete.panelWidth||this._getHostWidth()}_getHostWidth(){return this._getConnectedElement().nativeElement.getBoundingClientRect().width}_resetActiveItem(){let e=this.autocomplete;if(e.autoActiveFirstOption){let t=-1;for(let i=0;i<e.options.length;i++)if(!e.options.get(i).disabled){t=i;break}e._keyManager.setActiveItem(t);}else e._keyManager.setActiveItem(-1);}_canOpen(){let e=this._element.nativeElement;return !e.readOnly&&!e.disabled&&!this.autocompleteDisabled}_scrollToOption(e){let t=this.autocomplete,i=br$1(e,t.options,t.optionGroups);if(e===0&&i===1)t._setScrollTop(0);else if(t.panel){let n=t.options.toArray()[e];if(n){let s=n._getHostElement(),l=yr(s.offsetTop,s.offsetHeight,t._getScrollTop(),t.panel.nativeElement.offsetHeight);t._setScrollTop(l);}}}static \u0275fac=function(t){return new(t||a)};static \u0275dir=js({type:a,selectors:[["input","matAutocomplete",""],["textarea","matAutocomplete",""]],hostAttrs:[1,"mat-mdc-autocomplete-trigger"],hostVars:7,hostBindings:function(t,i){t&1&&Rg("focusin",function(){return i._handleFocus()})("blur",function(){return i._onTouched()})("input",function(s){return i._handleInput(s)})("keydown",function(s){return i._handleKeydown(s)})("click",function(){return i._handleClick()}),t&2&&Tg("autocomplete",i.autocompleteAttribute)("role",i.autocompleteDisabled?null:"combobox")("aria-autocomplete",i.autocompleteDisabled?null:"list")("aria-activedescendant",i.panelOpen&&i.activeOption?i.activeOption.id:null)("aria-expanded",i.autocompleteDisabled?null:i.panelOpen.toString())("aria-controls",i.autocompleteDisabled||!i.panelOpen?null:i.autocomplete?.id)("aria-haspopup",i.autocompleteDisabled?null:"listbox");},inputs:{autocomplete:[0,"matAutocomplete","autocomplete"],position:[0,"matAutocompletePosition","position"],connectedTo:[0,"matAutocompleteConnectedTo","connectedTo"],autocompleteAttribute:[0,"autocomplete","autocompleteAttribute"],autocompleteDisabled:[2,"matAutocompleteDisabled","autocompleteDisabled",QT]},exportAs:["matAutocompleteTrigger"],features:[nT([Ye]),Tu]})}return a})(),kt=(()=>{class a{static \u0275fac=function(t){return new(t||a)};static \u0275mod=wo({type:a});static \u0275inj=Zn({imports:[ge,Dr,vt,Dr,wt]})}return a})();export{Ct as C,kt as k,xe as x,ze as z};
@@ -1 +1 @@
1
- import {g,bl as Mt,W as x}from'./main-RV7LPVHR.js';var s=class n{snackBar=g(Mt);success(t,o=2e3){this.snackBar.open(t,"",{duration:o,horizontalPosition:"center",verticalPosition:"bottom",panelClass:["snackbar-success"]});}error(t,o=3e3){this.snackBar.open(t,"",{duration:o,horizontalPosition:"center",verticalPosition:"bottom",panelClass:["snackbar-error"]});}info(t,o=2e3){this.snackBar.open(t,"",{duration:o,horizontalPosition:"center",verticalPosition:"bottom",panelClass:["snackbar-info"]});}static \u0275fac=function(o){return new(o||n)};static \u0275prov=x({token:n,factory:n.\u0275fac,providedIn:"root"})};export{s};
1
+ import {g,bl as Mt,Y as x}from'./main-A4H3MFZY.js';var s=class n{snackBar=g(Mt);success(t,o=2e3){this.snackBar.open(t,"",{duration:o,horizontalPosition:"center",verticalPosition:"bottom",panelClass:["snackbar-success"]});}error(t,o=3e3){this.snackBar.open(t,"",{duration:o,horizontalPosition:"center",verticalPosition:"bottom",panelClass:["snackbar-error"]});}info(t,o=2e3){this.snackBar.open(t,"",{duration:o,horizontalPosition:"center",verticalPosition:"bottom",panelClass:["snackbar-info"]});}static \u0275fac=function(o){return new(o||n)};static \u0275prov=x({token:n,factory:n.\u0275fac,providedIn:"root"})};export{s};
@@ -0,0 +1 @@
1
+ import {O}from'./chunk-C519Azc-.js';import {N as N$1}from'./chunk-DrGGZMUF.js';import {g,G,C as Ce,d9 as D,aJ as Tr,a as Gi,bS as Ea,r as re,b as U,e as xw,aK as xb,k as ws,bf as aT,q as Rg,o as pl,af as Eg,u as CC,v as bg,bg as uT,ah as rT,J as Jw,ac as gC,y as eC,a9 as lC,aa as If,ab as wf,ag as fT}from'./main-A4H3MFZY.js';import'./chunk-BJ3cmxps.js';import {$ as $n,S as Se}from'./chunk-B0es9TQT.js';import'./chunk-D6Uyjin9.js';import'./chunk-CFuJNk7Q.js';import'./chunk-cwPycVUY.js';import'./chunk-D2VUzw11.js';var F=()=>[];function N(i,t){if(i&1){let e=lC();ws(0,"agentos-integration-config-item",4),Rg("editRequested",function(n){If(e);let f=gC(2);return wf(f.onEdit(n))})("deleteRequested",function(n){If(e);let f=gC(2);return wf(f.deleteConfig(n))}),pl();}i&2&&bg("config",t);}function j(i,t){if(i&1&&Jw(0,N,1,1,"agentos-integration-config-item",3),i&2){let e,o=t.$implicit,n=gC();eC((e=n.resolveConfig(o.id))?0:-1,e);}}var V=class i{router=g(G);destroyRef=g(Ce);state=g(N$1);integrationConfigController=g(D);refresh$=new Tr(void 0);isLoading=Gi(true);configs$=this.refresh$.pipe(Ea(()=>(this.isLoading.set(true),this.state.loadPlatformConfigs())));configItems$=this.configs$.pipe(re(t=>t.map(e=>({id:e.id??"",name:e.name,description:e.integrationType}))));configsById=new Map;constructor(){this.configs$.pipe(U(this.destroyRef)).subscribe({next:t=>{this.configsById=new Map(t.map(e=>[e.id??"",e])),this.isLoading.set(false);},error:()=>this.isLoading.set(false)});}goBack(){this.router.navigate(["/agentos","admin"]);}openCreateForm(){this.router.navigate(["/agentos","admin","integration-configs","new"]);}deleteConfig(t){this.integrationConfigController.deleteIntegrationConfig(t.id??"").pipe(U(this.destroyRef)).subscribe(()=>this.refresh$.next());}onEdit(t){this.router.navigate(["/agentos","admin","integration-configs",t.id??"","edit"]);}resolveConfig(t){return this.configsById.get(t)??null}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=xw({type:i,selectors:[["agentos-platform-integration-configs"]],decls:5,vars:7,consts:[["integrationConfigItemTpl",""],["title","Platform Integration Configs","emptyMessage","No platform integration configs defined yet. Add one above.","cardMinWidth","400px",3,"createRequested","items","loading","showCreate","itemTemplate"],["toolbar-start","","icon","arrow_back","title","Back",3,"action"],["scope","platform",3,"config"],["scope","platform",3,"editRequested","deleteRequested","config"]],template:function(e,o){if(e&1&&(ws(0,"ds-entity-list",1),aT(1,"async"),Rg("createRequested",function(){return o.openCreateForm()}),ws(2,"ds-icon-button",2),Rg("action",function(){return o.goBack()}),pl()(),Eg(3,j,1,1,"ng-template",null,0,fT)),e&2){let n=CC(4);bg("items",uT(1,4,o.configItems$)??rT(6,F))("loading",o.isLoading())("showCreate",true)("itemTemplate",n);}},dependencies:[$n,O,Se,xb],styles:[".platform-integration-configs__back[_ngcontent-%COMP%]{background:none;border:none;padding:0;cursor:pointer;font-size:.875rem;color:var(--color-primary, #007aff);font-family:inherit}.platform-integration-configs__back[_ngcontent-%COMP%]:hover{text-decoration:underline}"]})};export{V as PlatformIntegrationConfigsComponent};
@@ -1 +1 @@
1
- import {c}from'./chunk-kDXa94an.js';import {g,ao as W,dr as J,G as Gi,an as ue$1,cd as Hf,e as xw,$ as $t,cF as Pb,k as ws,n as GC,o as pl,J as Jw,X as XE,v as eC,bR as Id,bS as va,cB as on,M as By,a7 as ya,a9 as lC,q as Rg,ai as tm,a3 as VI,ac as gC,ak as em,a6 as UI,a8 as Yg,s as rC,y as oC,cg as iT,b4 as oT,bf as aT,bg as uT,b0 as Qg,bi as lT,aa as If,ab as wf,aj as KC,a5 as vl}from'./main-RV7LPVHR.js';import {t as ti,J as Jn,Y as Ye,Z as Zn,l as Xn,g as gt,c as cn,d as an}from'./chunk-lTYooNBT.js';import'./chunk-Y05Tjbrm.js';import'./chunk-BLhKuE4K.js';import'./chunk-KM2T1f6P.js';var ne=e=>({title:"By agent",rows:e}),ie=e=>({title:"By model",rows:e}),ae=(e,o)=>[e,o],oe=(e,o)=>o.title,re=(e,o)=>o.key;function se(e,o){e&1&&(ws(0,"p",2),GC(1,"Loading usage settings\u2026"),pl());}function le(e,o){if(e&1){let t=lC();ws(0,"p",3),GC(1,"Could not load usage settings. Please try again."),pl(),ws(2,"button",4),Rg("click",function(){If(t);let s=gC();return wf(s.configuration.retry())}),GC(3,"Retry usage settings"),pl();}}function me(e,o){e&1&&(ws(0,"p",2),GC(1,"Usage tracking is disabled."),pl());}function de(e,o){e&1&&(ws(0,"p",3),GC(1),pl()),e&2&&(XE(),Yg(o));}function ce(e,o){e&1&&(ws(0,"p",2),GC(1,"Loading usage\u2026"),pl());}function pe(e,o){e&1&&(ws(0,"p"),GC(1,"No recorded usage for this period."),pl());}function ge(e,o){if(e&1&&(ws(0,"small"),GC(1),pl()),e&2){let t=gC().$implicit;XE(),vl("",t.aggregate.unknownCostCount," record(s) with unknown cost");}}function ue(e,o){if(e&1&&(ws(0,"tr")(1,"th",11),GC(2),pl(),ws(3,"td"),GC(4),aT(5,"number"),pl(),ws(6,"td"),GC(7),aT(8,"number"),aT(9,"number"),pl(),ws(10,"td"),GC(11),aT(12,"number"),aT(13,"number"),pl(),ws(14,"td"),GC(15),aT(16,"number"),Jw(17,ge,2,1,"small"),pl()()),e&2){let t=o.$implicit;XE(2),Yg(t.key),XE(2),Yg(uT(5,9,t.aggregate.totalTokens)),XE(3),Qg("",uT(8,11,t.aggregate.inputTokens)," / ",uT(9,13,t.aggregate.outputTokens)),XE(4),Qg(" ",uT(12,15,t.aggregate.cacheReadTokens)," / ",uT(13,17,t.aggregate.cacheWriteTokens)," "),XE(4),Qg(" ",t.aggregate.unknownCostCount>0?"At least ":"","",lT(16,19,t.aggregate.cost,"1.2-6")," "),XE(2),eC(t.aggregate.unknownCostCount>0?17:-1);}}function _e(e,o){if(e&1&&(ws(0,"div",9)(1,"table")(2,"thead")(3,"tr")(4,"th",10),GC(5,"Name"),pl(),ws(6,"th",10),GC(7,"Tokens"),pl(),ws(8,"th",10),GC(9,"Input / output"),pl(),ws(10,"th",10),GC(11,"Cache read / write"),pl(),ws(12,"th",10),GC(13,"Estimated cost"),pl()()(),ws(14,"tbody"),rC(15,ue,18,22,"tr",null,re),pl()()()),e&2){let t=gC().$implicit;XE(15),oC(t.rows);}}function Ce(e,o){if(e&1&&(ws(0,"h2"),GC(1),pl(),Jw(2,pe,2,0,"p")(3,_e,17,0,"div",9)),e&2){let t=o.$implicit;XE(),Yg(t.title),XE(),eC(t.rows.length===0?2:3);}}function fe(e,o){if(e&1&&(rC(0,Ce,4,2,null,null,oe),ws(2,"p"),GC(3,"Unpriced usage is kept separate from known costs. Active agent runs appear here after they finish."),pl()),e&2){let t=gC(2);oC(iT(4,ae,oT(0,ne,t.agents()),oT(2,ie,t.models())));}}function ye(e,o){if(e&1){let t=lC();ws(0,"p"),GC(1,"Recorded LLM usage across this namespace. Costs are estimates in the platform currency."),pl(),ws(2,"form",5),Rg("ngSubmit",function(){If(t);let s=gC();return wf(s.load())}),ws(3,"label"),GC(4,"From (UTC)"),ws(5,"input",6),tm("ngModelChange",function(s){If(t);let d=gC();return KC(d.from,s)||(d.from=s),wf(s)}),pl(),VI(),pl(),ws(6,"label"),GC(7,"To (UTC)"),ws(8,"input",7),tm("ngModelChange",function(s){If(t);let d=gC();return KC(d.to,s)||(d.to=s),wf(s)}),pl(),VI(),pl(),ws(9,"button",8),GC(10,"Refresh"),pl()(),Jw(11,de,2,1,"p",3),Jw(12,ce,2,0,"p",2)(13,fe,4,7);}if(e&2){let t,r=gC();XE(5),em("ngModel",r.from),UI(),XE(3),em("ngModel",r.to),UI(),XE(3),eC((t=r.error())?11:-1,t),XE(),eC(r.loading()?12:r.error()?-1:13);}}var te=class e{route=g(W);api=g(J);configuration=g(c);namespaceId=this.route.snapshot.params.namespaceId;agents=Gi([]);models=Gi([]);error=Gi(null);loading=Gi(false);from=new Date(Date.now()-30*864e5).toISOString().slice(0,10);to=new Date().toISOString().slice(0,10);refresh=new ue$1;constructor(){Hf(o=>{if(!this.configuration.enabled())return;let t=this.refresh.pipe(Id(void 0),va(()=>{this.error.set(null),this.agents.set([]),this.models.set([]);let r=new Date(`${this.from}T00:00:00.000Z`),s=new Date(`${this.to}T23:59:59.999Z`);return !Number.isFinite(r.getTime())||!Number.isFinite(s.getTime())||r>s?(this.error.set("Select a valid date range."),this.loading.set(false),on):(this.loading.set(true),By({agents:this.api.aggregateByAgentUsageRecord(this.namespaceId,r.toISOString(),s.toISOString()),models:this.api.aggregateByModelUsageRecord(this.namespaceId,r.toISOString(),s.toISOString())}).pipe(ya(d=>(this.loading.set(false),this.error.set(d.status===403?"Namespace admin permission is required to view this report.":"Could not load usage. Please try again."),on))))})).subscribe(({agents:r,models:s})=>{this.agents.set(r),this.models.set(s),this.loading.set(false);});o(()=>t.unsubscribe());});}load(){this.configuration.enabled()&&this.refresh.next();}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=xw({type:e,selectors:[["agentos-namespace-usage"]],decls:9,vars:1,consts:[[1,"report"],["routerLink","/agentos/namespaces"],["role","status"],["role","alert"],["type","button",3,"click"],[1,"filters",3,"ngSubmit"],["type","date","name","from","required","",3,"ngModelChange","ngModel"],["type","date","name","to","required","",3,"ngModelChange","ngModel"],["type","submit"],[1,"table-wrap"],["scope","col"],["scope","row"]],template:function(t,r){t&1&&(ws(0,"section",0)(1,"a",1),GC(2,"\u2190 Namespaces"),pl(),ws(3,"h1"),GC(4,"Usage and costs"),pl(),Jw(5,se,2,0,"p",2)(6,le,4,0)(7,me,2,0,"p",2)(8,ye,14,4),pl()),t&2&&(XE(5),eC(r.configuration.state()==="loading"?5:r.configuration.state()==="error"?6:r.configuration.state()==="disabled"?7:8));},dependencies:[ti,Jn,Ye,Zn,Xn,gt,cn,an,$t,Pb],styles:["[_nghost-%COMP%]{display:block}.report[_ngcontent-%COMP%]{max-width:1100px;margin:auto;padding:1.5rem;color:var(--color-text, inherit)}a[_ngcontent-%COMP%]{color:inherit}.filters[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:1rem;align-items:end;margin:1.5rem 0}label[_ngcontent-%COMP%]{display:grid;gap:.4rem}input[_ngcontent-%COMP%], button[_ngcontent-%COMP%]{font:inherit;color:inherit;background:transparent;border:1px solid var(--color-border, rgba(136, 136, 136, .5333333333));border-radius:.4rem;padding:.5rem .75rem}button[_ngcontent-%COMP%]{cursor:pointer}.table-wrap[_ngcontent-%COMP%]{overflow-x:auto}table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%}th[_ngcontent-%COMP%], td[_ngcontent-%COMP%]{text-align:left;padding:.75rem;border-bottom:1px solid var(--color-border, rgba(136, 136, 136, .3333333333))}small[_ngcontent-%COMP%]{display:block;margin-top:.3rem}h2[_ngcontent-%COMP%]{margin-top:2rem}"]})};export{te as NamespaceUsageComponent};
1
+ import {c}from'./chunk-BJ3cmxps.js';import {g,ao as V,ds as _,a as Gi,an as ue$1,cd as Hf,e as xw,s as si,cF as Pb,k as ws,n as GC,o as pl,J as Jw,X as XE,y as eC,bR as wd,bS as Ea,cB as on,Q as By,a7 as ya,a9 as lC,q as Rg,ai as tm,a3 as VI,ac as gC,ak as em,a6 as UI,a8 as Yg,t as rC,z as oC,cg as iT,b4 as oT,bf as aT,bg as uT,b0 as Qg,bi as lT,aa as If,ab as wf,aj as KC,a5 as vl}from'./main-A4H3MFZY.js';import {t as ti,J as Jn,Y as Ye,Z as Zn,l as Xn,g as gt,c as cn,d as an}from'./chunk-CFuJNk7Q.js';import'./chunk-D2VUzw11.js';import'./chunk-B0es9TQT.js';import'./chunk-D6Uyjin9.js';var ne=e=>({title:"By agent",rows:e}),ie=e=>({title:"By model",rows:e}),ae=(e,o)=>[e,o],oe=(e,o)=>o.title,re=(e,o)=>o.key;function se(e,o){e&1&&(ws(0,"p",2),GC(1,"Loading usage settings\u2026"),pl());}function le(e,o){if(e&1){let t=lC();ws(0,"p",3),GC(1,"Could not load usage settings. Please try again."),pl(),ws(2,"button",4),Rg("click",function(){If(t);let s=gC();return wf(s.configuration.retry())}),GC(3,"Retry usage settings"),pl();}}function me(e,o){e&1&&(ws(0,"p",2),GC(1,"Usage tracking is disabled."),pl());}function de(e,o){e&1&&(ws(0,"p",3),GC(1),pl()),e&2&&(XE(),Yg(o));}function ce(e,o){e&1&&(ws(0,"p",2),GC(1,"Loading usage\u2026"),pl());}function pe(e,o){e&1&&(ws(0,"p"),GC(1,"No recorded usage for this period."),pl());}function ge(e,o){if(e&1&&(ws(0,"small"),GC(1),pl()),e&2){let t=gC().$implicit;XE(),vl("",t.aggregate.unknownCostCount," record(s) with unknown cost");}}function ue(e,o){if(e&1&&(ws(0,"tr")(1,"th",11),GC(2),pl(),ws(3,"td"),GC(4),aT(5,"number"),pl(),ws(6,"td"),GC(7),aT(8,"number"),aT(9,"number"),pl(),ws(10,"td"),GC(11),aT(12,"number"),aT(13,"number"),pl(),ws(14,"td"),GC(15),aT(16,"number"),Jw(17,ge,2,1,"small"),pl()()),e&2){let t=o.$implicit;XE(2),Yg(t.key),XE(2),Yg(uT(5,9,t.aggregate.totalTokens)),XE(3),Qg("",uT(8,11,t.aggregate.inputTokens)," / ",uT(9,13,t.aggregate.outputTokens)),XE(4),Qg(" ",uT(12,15,t.aggregate.cacheReadTokens)," / ",uT(13,17,t.aggregate.cacheWriteTokens)," "),XE(4),Qg(" ",t.aggregate.unknownCostCount>0?"At least ":"","",lT(16,19,t.aggregate.cost,"1.2-6")," "),XE(2),eC(t.aggregate.unknownCostCount>0?17:-1);}}function _e(e,o){if(e&1&&(ws(0,"div",9)(1,"table")(2,"thead")(3,"tr")(4,"th",10),GC(5,"Name"),pl(),ws(6,"th",10),GC(7,"Tokens"),pl(),ws(8,"th",10),GC(9,"Input / output"),pl(),ws(10,"th",10),GC(11,"Cache read / write"),pl(),ws(12,"th",10),GC(13,"Estimated cost"),pl()()(),ws(14,"tbody"),rC(15,ue,18,22,"tr",null,re),pl()()()),e&2){let t=gC().$implicit;XE(15),oC(t.rows);}}function Ce(e,o){if(e&1&&(ws(0,"h2"),GC(1),pl(),Jw(2,pe,2,0,"p")(3,_e,17,0,"div",9)),e&2){let t=o.$implicit;XE(),Yg(t.title),XE(),eC(t.rows.length===0?2:3);}}function fe(e,o){if(e&1&&(rC(0,Ce,4,2,null,null,oe),ws(2,"p"),GC(3,"Unpriced usage is kept separate from known costs. Active agent runs appear here after they finish."),pl()),e&2){let t=gC(2);oC(iT(4,ae,oT(0,ne,t.agents()),oT(2,ie,t.models())));}}function ye(e,o){if(e&1){let t=lC();ws(0,"p"),GC(1,"Recorded LLM usage across this namespace. Costs are estimates in the platform currency."),pl(),ws(2,"form",5),Rg("ngSubmit",function(){If(t);let s=gC();return wf(s.load())}),ws(3,"label"),GC(4,"From (UTC)"),ws(5,"input",6),tm("ngModelChange",function(s){If(t);let d=gC();return KC(d.from,s)||(d.from=s),wf(s)}),pl(),VI(),pl(),ws(6,"label"),GC(7,"To (UTC)"),ws(8,"input",7),tm("ngModelChange",function(s){If(t);let d=gC();return KC(d.to,s)||(d.to=s),wf(s)}),pl(),VI(),pl(),ws(9,"button",8),GC(10,"Refresh"),pl()(),Jw(11,de,2,1,"p",3),Jw(12,ce,2,0,"p",2)(13,fe,4,7);}if(e&2){let t,r=gC();XE(5),em("ngModel",r.from),UI(),XE(3),em("ngModel",r.to),UI(),XE(3),eC((t=r.error())?11:-1,t),XE(),eC(r.loading()?12:r.error()?-1:13);}}var te=class e{route=g(V);api=g(_);configuration=g(c);namespaceId=this.route.snapshot.params.namespaceId;agents=Gi([]);models=Gi([]);error=Gi(null);loading=Gi(false);from=new Date(Date.now()-30*864e5).toISOString().slice(0,10);to=new Date().toISOString().slice(0,10);refresh=new ue$1;constructor(){Hf(o=>{if(!this.configuration.enabled())return;let t=this.refresh.pipe(wd(void 0),Ea(()=>{this.error.set(null),this.agents.set([]),this.models.set([]);let r=new Date(`${this.from}T00:00:00.000Z`),s=new Date(`${this.to}T23:59:59.999Z`);return !Number.isFinite(r.getTime())||!Number.isFinite(s.getTime())||r>s?(this.error.set("Select a valid date range."),this.loading.set(false),on):(this.loading.set(true),By({agents:this.api.aggregateByAgentUsageRecord(this.namespaceId,r.toISOString(),s.toISOString()),models:this.api.aggregateByModelUsageRecord(this.namespaceId,r.toISOString(),s.toISOString())}).pipe(ya(d=>(this.loading.set(false),this.error.set(d.status===403?"Namespace admin permission is required to view this report.":"Could not load usage. Please try again."),on))))})).subscribe(({agents:r,models:s})=>{this.agents.set(r),this.models.set(s),this.loading.set(false);});o(()=>t.unsubscribe());});}load(){this.configuration.enabled()&&this.refresh.next();}static \u0275fac=function(t){return new(t||e)};static \u0275cmp=xw({type:e,selectors:[["agentos-namespace-usage"]],decls:9,vars:1,consts:[[1,"report"],["routerLink","/agentos/namespaces"],["role","status"],["role","alert"],["type","button",3,"click"],[1,"filters",3,"ngSubmit"],["type","date","name","from","required","",3,"ngModelChange","ngModel"],["type","date","name","to","required","",3,"ngModelChange","ngModel"],["type","submit"],[1,"table-wrap"],["scope","col"],["scope","row"]],template:function(t,r){t&1&&(ws(0,"section",0)(1,"a",1),GC(2,"\u2190 Namespaces"),pl(),ws(3,"h1"),GC(4,"Usage and costs"),pl(),Jw(5,se,2,0,"p",2)(6,le,4,0)(7,me,2,0,"p",2)(8,ye,14,4),pl()),t&2&&(XE(5),eC(r.configuration.state()==="loading"?5:r.configuration.state()==="error"?6:r.configuration.state()==="disabled"?7:8));},dependencies:[ti,Jn,Ye,Zn,Xn,gt,cn,an,si,Pb],styles:["[_nghost-%COMP%]{display:block}.report[_ngcontent-%COMP%]{max-width:1100px;margin:auto;padding:1.5rem;color:var(--color-text, inherit)}a[_ngcontent-%COMP%]{color:inherit}.filters[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:1rem;align-items:end;margin:1.5rem 0}label[_ngcontent-%COMP%]{display:grid;gap:.4rem}input[_ngcontent-%COMP%], button[_ngcontent-%COMP%]{font:inherit;color:inherit;background:transparent;border:1px solid var(--color-border, rgba(136, 136, 136, .5333333333));border-radius:.4rem;padding:.5rem .75rem}button[_ngcontent-%COMP%]{cursor:pointer}.table-wrap[_ngcontent-%COMP%]{overflow-x:auto}table[_ngcontent-%COMP%]{border-collapse:collapse;width:100%}th[_ngcontent-%COMP%], td[_ngcontent-%COMP%]{text-align:left;padding:.75rem;border-bottom:1px solid var(--color-border, rgba(136, 136, 136, .3333333333))}small[_ngcontent-%COMP%]{display:block;margin-top:.3rem}h2[_ngcontent-%COMP%]{margin-top:2rem}"]})};export{te as NamespaceUsageComponent};
@@ -0,0 +1 @@
1
+ import {N}from'./chunk-BJ3cmxps.js';import {g,ao as V,G,dt as F,da as $,C as Ce,a as Gi,b as U,av as B,du 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,y as eC,a5 as vl,ac as gC}from'./main-A4H3MFZY.js';import'./chunk-D2VUzw11.js';import'./chunk-B0es9TQT.js';import'./chunk-D6Uyjin9.js';import'./chunk-CFuJNk7Q.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(V);router=g(G);caseController=g(F);caseState=g(N);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};