@whoz-oss/coday-client 0.128.0 → 0.129.0

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 (86) hide show
  1. package/browser/{chunk-D6WU5O4X.js → chunk-2TT2VS4Q.js} +1 -1
  2. package/browser/{chunk-GVX63TKQ.js → chunk-2YPR6RKN.js} +1 -1
  3. package/browser/{chunk-6LO3ANKL.js → chunk-3CAK3MY2.js} +1 -1
  4. package/browser/{chunk-ZAM3WGZM.js → chunk-3DDLKUVJ.js} +1 -1
  5. package/browser/{chunk-7XSGZTN3.js → chunk-4AYGP75X.js} +1 -1
  6. package/browser/chunk-4KNZ7PUG.js +1 -0
  7. package/browser/{chunk-KYPWHL43.js → chunk-4XDVIAH5.js} +1 -1
  8. package/browser/{chunk-HSNVFCBN.js → chunk-6DNANWSF.js} +1 -1
  9. package/browser/{chunk-AK6F2DC7.js → chunk-6JH2UGTU.js} +1 -1
  10. package/browser/chunk-6MVTL5VJ.js +1 -0
  11. package/browser/chunk-7GBHCDC2.js +1 -0
  12. package/browser/{chunk-7CFO7WWZ.js → chunk-AHABNNMX.js} +1 -1
  13. package/browser/{chunk-Z26H5ES2.js → chunk-AKD5MBRD.js} +1 -1
  14. package/browser/chunk-B6DPIDKI.js +1 -0
  15. package/browser/{chunk-EPA5P2I6.js → chunk-BEKG4CZE.js} +1 -1
  16. package/browser/{chunk-3TO5PQRD.js → chunk-BYSD3PVJ.js} +1 -1
  17. package/browser/{chunk-LLDKKRUC.js → chunk-BZJFZW26.js} +1 -1
  18. package/browser/{chunk-ADWJAQMQ.js → chunk-CL3F6CYH.js} +1 -1
  19. package/browser/{chunk-WNNKQ2DH.js → chunk-CND4W2V5.js} +1 -1
  20. package/browser/chunk-CX2W2KP4.js +1 -0
  21. package/browser/{chunk-DVO44NIX.js → chunk-CXN4NTRD.js} +1 -1
  22. package/browser/chunk-DIZZ6MCJ.js +1 -0
  23. package/browser/{chunk-XJUBZLY2.js → chunk-DLU3TQID.js} +1 -1
  24. package/browser/{chunk-7T6Q4MDL.js → chunk-DPFJ6LFY.js} +1 -1
  25. package/browser/{chunk-MWWLTJ77.js → chunk-FAAHG43E.js} +1 -1
  26. package/browser/{chunk-KTPX26DH.js → chunk-FDCPX2YT.js} +1 -1
  27. package/browser/{chunk-YCJZTFYJ.js → chunk-FJR6WCPX.js} +1 -1
  28. package/browser/{chunk-VNCIHM33.js → chunk-FQSDA7SM.js} +1 -1
  29. package/browser/{chunk-IFXDK4GQ.js → chunk-FTMDL4HX.js} +1 -1
  30. package/browser/{chunk-XIQ3L6H6.js → chunk-G4QDBE4F.js} +1 -1
  31. package/browser/chunk-GYZJRAEL.js +1 -0
  32. package/browser/chunk-HCMK67ST.js +1 -0
  33. package/browser/chunk-HUWAPEGQ.js +1 -0
  34. package/browser/{chunk-DRBOHCTP.js → chunk-HY7OYHZF.js} +1 -1
  35. package/browser/{chunk-RQLQ22PM.js → chunk-HYNHL5RY.js} +1 -1
  36. package/browser/{chunk-3U3QVZEU.js → chunk-I75FDNMK.js} +1 -1
  37. package/browser/{chunk-TSDYLM5L.js → chunk-J6NHAJP2.js} +1 -1
  38. package/browser/{chunk-GEUVTKHG.js → chunk-KNY6WJUH.js} +1 -1
  39. package/browser/{chunk-AJOXSD6I.js → chunk-LCBWJP6Z.js} +1 -1
  40. package/browser/{chunk-QWMDAFBN.js → chunk-LTFITYTW.js} +1 -1
  41. package/browser/{chunk-7A54VTP2.js → chunk-MLNEYB77.js} +1 -1
  42. package/browser/{chunk-VGRGY2U3.js → chunk-MO6H3TK3.js} +1 -1
  43. package/browser/{chunk-EU3J4G2Y.js → chunk-NEINI73V.js} +1 -1
  44. package/browser/{chunk-UORJVNGU.js → chunk-NLRFBAA2.js} +1 -1
  45. package/browser/chunk-NV3MNDVJ.js +1 -0
  46. package/browser/{chunk-NZDKKDRG.js → chunk-OBMXZUQM.js} +1 -1
  47. package/browser/{chunk-IJ2YZMNS.js → chunk-OHLGZXEO.js} +1 -1
  48. package/browser/chunk-OMENROC2.js +1 -0
  49. package/browser/{chunk-QSQYSFNQ.js → chunk-OSX2KHVN.js} +1 -1
  50. package/browser/{chunk-I5OT3IGD.js → chunk-Q74LPU7S.js} +1 -1
  51. package/browser/{chunk-YXFL2FTT.js → chunk-QDQW667Q.js} +1 -1
  52. package/browser/{chunk-WPC6XC7P.js → chunk-QFSZDRP2.js} +1 -1
  53. package/browser/chunk-R2OQMKB5.js +1 -0
  54. package/browser/{chunk-DE5MXWYR.js → chunk-R3DKNIV5.js} +1 -1
  55. package/browser/chunk-R5RVDZLX.js +1 -0
  56. package/browser/{chunk-JWEUUCFC.js → chunk-RAJZGLER.js} +1 -1
  57. package/browser/{chunk-3JGMGRXW.js → chunk-RNXBUYHW.js} +2 -2
  58. package/browser/{chunk-B2QA6UZX.js → chunk-SDLTQWY6.js} +1 -1
  59. package/browser/{chunk-FFMGEAGW.js → chunk-SHWW6WRB.js} +1 -1
  60. package/browser/{chunk-WQUBEVZN.js → chunk-SI36SMXC.js} +1 -1
  61. package/browser/{chunk-AQ3SEH2N.js → chunk-SKVQOMLG.js} +1 -1
  62. package/browser/{chunk-NAQEVUOV.js → chunk-SQWEKOLS.js} +1 -1
  63. package/browser/{chunk-SDNXWYG5.js → chunk-T2JHUF63.js} +1 -1
  64. package/browser/chunk-T2LG7TT2.js +1 -0
  65. package/browser/{chunk-U4662WTU.js → chunk-TY4VCUP2.js} +1 -1
  66. package/browser/{chunk-IXD43YQI.js → chunk-UQNMPA5Y.js} +1 -1
  67. package/browser/chunk-WBRWLEC2.js +1 -0
  68. package/browser/{chunk-MVATXMLV.js → chunk-WC5DQJKZ.js} +1 -1
  69. package/browser/{chunk-IZFHJAEI.js → chunk-YBAY4MP6.js} +1 -1
  70. package/browser/{chunk-RHFQ7GO2.js → chunk-ZQJGEWGV.js} +1 -1
  71. package/browser/index.html +1 -1
  72. package/browser/{main-YSLZYJ4P.js → main-XJQHXNY2.js} +1 -1
  73. package/package.json +1 -1
  74. package/browser/chunk-3D3KN52V.js +0 -1
  75. package/browser/chunk-3YSNMKXU.js +0 -1
  76. package/browser/chunk-5B6P72NR.js +0 -1
  77. package/browser/chunk-B2FFL2F7.js +0 -1
  78. package/browser/chunk-FPNKDL3E.js +0 -1
  79. package/browser/chunk-GAZJZBKP.js +0 -1
  80. package/browser/chunk-GG2XORTA.js +0 -1
  81. package/browser/chunk-H6Q42HHV.js +0 -1
  82. package/browser/chunk-I5EEQETN.js +0 -1
  83. package/browser/chunk-O3U2KGCT.js +0 -1
  84. package/browser/chunk-ONXSTLRN.js +0 -1
  85. package/browser/chunk-QU37OGFO.js +0 -1
  86. package/browser/chunk-QXZ6AR76.js +0 -1
@@ -1 +1 @@
1
- import{k as ei}from"./chunk-GAZJZBKP.js";import{a as S,b as K,e as xt,f as Ye,h as X,i as ve,j as le,k as si}from"./chunk-MVATXMLV.js";import{a as ti}from"./chunk-GVX63TKQ.js";import{b as ii,w as ni}from"./chunk-YCJZTFYJ.js";import"./chunk-MWWLTJ77.js";import{c as Ht,f as Yt,g as Xt}from"./chunk-QWMDAFBN.js";import{a as Jt}from"./chunk-WNNKQ2DH.js";import{c as Zt}from"./chunk-DRBOHCTP.js";import"./chunk-IXD43YQI.js";import{b as Te}from"./chunk-XIQ3L6H6.js";import"./chunk-B2QA6UZX.js";import{B as Ot,Ca as We,G as It,L as Ft,La as Bt,Mc as $t,Nc as Gt,Oa as qt,Sc as Wt,V as Lt,W as v,Wa as Qt,Z as Se,a as ye,ba as Ee,c as Mt,ca as z,d as _e,fb as He,la as zt,pa as Kt,q as Ge,r as Dt,rc as Vt,sa as jt,t as Rt,u as kt,ub as Ut}from"./chunk-3JGMGRXW.js";function ri(s){return new v(3e3,!1)}function ln(){return new v(3100,!1)}function cn(){return new v(3101,!1)}function un(s){return new v(3001,!1)}function hn(s){return new v(3003,!1)}function dn(s){return new v(3004,!1)}function oi(s,e){return new v(3005,!1)}function li(){return new v(3006,!1)}function ci(){return new v(3007,!1)}function ui(s,e){return new v(3008,!1)}function hi(s){return new v(3002,!1)}function di(s,e,t,i,n){return new v(3010,!1)}function mi(){return new v(3011,!1)}function fi(){return new v(3012,!1)}function pi(){return new v(3200,!1)}function gi(){return new v(3202,!1)}function yi(){return new v(3013,!1)}function _i(s){return new v(3014,!1)}function Si(s){return new v(3015,!1)}function Ei(s){return new v(3016,!1)}function vi(s,e){return new v(3404,!1)}function mn(s){return new v(3502,!1)}function Ti(s){return new v(3503,!1)}function Ai(){return new v(3300,!1)}function bi(s){return new v(3504,!1)}function wi(s){return new v(3301,!1)}function Pi(s,e){return new v(3302,!1)}function Ni(s){return new v(3303,!1)}function Ci(s,e){return new v(3400,!1)}function Mi(s){return new v(3401,!1)}function Di(s){return new v(3402,!1)}function Ri(s,e){return new v(3505,!1)}function V(s){switch(s.length){case 0:return new X;case 1:return s[0];default:return new ve(s)}}function Je(s,e,t=new Map,i=new Map){let n=[],r=[],a=-1,o=null;if(e.forEach(l=>{let c=l.get("offset"),h=c==a,u=h&&o||new Map;l.forEach((_,y)=>{let m=y,g=_;if(y!=="offset")switch(m=s.normalizePropertyName(m,n),g){case le:g=t.get(y);break;case K:g=i.get(y);break;default:g=s.normalizeStyleValue(y,m,g,n);break}u.set(m,g)}),h||r.push(u),o=u,a=c}),n.length)throw mn(n);return r}function Ae(s,e,t,i){switch(e){case"start":s.onStart(()=>i(t&&Xe(t,"start",s)));break;case"done":s.onDone(()=>i(t&&Xe(t,"done",s)));break;case"destroy":s.onDestroy(()=>i(t&&Xe(t,"destroy",s)));break}}function Xe(s,e,t){let i=t.totalTime,n=!!t.disabled,r=be(s.element,s.triggerName,s.fromState,s.toState,e||s.phaseName,i??s.totalTime,n),a=s._data;return a!=null&&(r._data=a),r}function be(s,e,t,i,n="",r=0,a){return{element:s,triggerName:e,fromState:t,toState:i,phaseName:n,totalTime:r,disabled:!!a}}function k(s,e,t){let i=s.get(e);return i||s.set(e,i=t),i}function et(s){let e=s.indexOf(":"),t=s.substring(1,e),i=s.slice(e+1);return[t,i]}var fn=typeof document>"u"?null:document.documentElement;function we(s){let e=s.parentNode||s.host||null;return e===fn?null:e}function pn(s){return s.substring(1,6)=="ebkit"}var x=null,ai=!1;function ki(s){x||(x=gn()||{},ai=x.style?"WebkitAppearance"in x.style:!1);let e=!0;return x.style&&!pn(s)&&(e=s in x.style,!e&&ai&&(e="Webkit"+s.charAt(0).toUpperCase()+s.slice(1)in x.style)),e}function gn(){return typeof document<"u"?document.body:null}function tt(s,e){for(;e;){if(e===s)return!0;e=we(e)}return!1}function it(s,e,t){if(t)return Array.from(s.querySelectorAll(e));let i=s.querySelector(e);return i?[i]:[]}var yn=1e3,nt="{{",_n="}}",st="ng-enter",Pe="ng-leave",ce="ng-trigger",ue=".ng-trigger",rt="ng-animating",Ne=".ng-animating";function U(s){if(typeof s=="number")return s;let e=s.match(/^(-?[\.\d]+)(m?s)/);return!e||e.length<2?0:xe(parseFloat(e[1]),e[2])}function xe(s,e){return e==="s"?s*yn:s}function he(s,e,t){return s.hasOwnProperty("duration")?s:En(s,e,t)}var Sn=/^(-?[\.\d]+)(m?s)(?:\s+(-?[\.\d]+)(m?s))?(?:\s+([-a-z]+(?:\(.+?\))?))?$/i;function En(s,e,t){let i,n=0,r="";if(typeof s=="string"){let a=s.match(Sn);if(a===null)return e.push(ri(s)),{duration:0,delay:0,easing:""};i=xe(parseFloat(a[1]),a[2]);let o=a[3];o!=null&&(n=xe(parseFloat(o),a[4]));let l=a[5];l&&(r=l)}else i=s;if(!t){let a=!1,o=e.length;i<0&&(e.push(ln()),a=!0),n<0&&(e.push(cn()),a=!0),a&&e.splice(o,0,ri(s))}return{duration:i,delay:n,easing:r}}function Oi(s){return s.length?s[0]instanceof Map?s:s.map(e=>new Map(Object.entries(e))):[]}function j(s,e,t){e.forEach((i,n)=>{let r=Ce(n);t&&!t.has(n)&&t.set(n,s.style[r]),s.style[r]=i})}function G(s,e){e.forEach((t,i)=>{let n=Ce(i);s.style[n]=""})}function se(s){return Array.isArray(s)?s.length==1?s[0]:xt(s):s}function Ii(s,e,t){let i=e.params||{},n=at(s);n.length&&n.forEach(r=>{i.hasOwnProperty(r)||t.push(un(r))})}var Ze=new RegExp(`${nt}\\s*(.+?)\\s*${_n}`,"g");function at(s){let e=[];if(typeof s=="string"){let t;for(;t=Ze.exec(s);)e.push(t[1]);Ze.lastIndex=0}return e}function re(s,e,t){let i=`${s}`,n=i.replace(Ze,(r,a)=>{let o=e[a];return o==null&&(t.push(hn(a)),o=""),o.toString()});return n==i?s:n}var vn=/-+([a-z0-9])/g;function Ce(s){return s.replace(vn,(...e)=>e[1].toUpperCase())}function Fi(s,e){return s===0||e===0}function Li(s,e,t){if(t.size&&e.length){let i=e[0],n=[];if(t.forEach((r,a)=>{i.has(a)||n.push(a),i.set(a,r)}),n.length)for(let r=1;r<e.length;r++){let a=e[r];n.forEach(o=>a.set(o,Me(s,o)))}}return e}function O(s,e,t){switch(e.type){case S.Trigger:return s.visitTrigger(e,t);case S.State:return s.visitState(e,t);case S.Transition:return s.visitTransition(e,t);case S.Sequence:return s.visitSequence(e,t);case S.Group:return s.visitGroup(e,t);case S.Animate:return s.visitAnimate(e,t);case S.Keyframes:return s.visitKeyframes(e,t);case S.Style:return s.visitStyle(e,t);case S.Reference:return s.visitReference(e,t);case S.AnimateChild:return s.visitAnimateChild(e,t);case S.AnimateRef:return s.visitAnimateRef(e,t);case S.Query:return s.visitQuery(e,t);case S.Stagger:return s.visitStagger(e,t);default:throw dn(e.type)}}function Me(s,e){return window.getComputedStyle(s)[e]}var At=(()=>{class s{validateStyleProperty(t){return ki(t)}containsElement(t,i){return tt(t,i)}getParentElement(t){return we(t)}query(t,i,n){return it(t,i,n)}computeStyle(t,i,n){return n||""}animate(t,i,n,r,a,o=[],l){return new X(n,r)}static \u0275fac=function(i){return new(i||s)};static \u0275prov=Se({token:s,factory:s.\u0275fac})}return s})(),J=class{static NOOP=new At},ee=class{};var Tn=new Set(["width","height","minWidth","minHeight","maxWidth","maxHeight","left","top","bottom","right","fontSize","outlineWidth","outlineOffset","paddingTop","paddingLeft","paddingBottom","paddingRight","marginTop","marginLeft","marginBottom","marginRight","borderRadius","borderWidth","borderTopWidth","borderLeftWidth","borderRightWidth","borderBottomWidth","textIndent","perspective"]),Ie=class extends ee{normalizePropertyName(e,t){return Ce(e)}normalizeStyleValue(e,t,i,n){let r="",a=i.toString().trim();if(Tn.has(t)&&i!==0&&i!=="0")if(typeof i=="number")r="px";else{let o=i.match(/^[+-]?[\d\.]+([a-z]*)$/);o&&o[1].length==0&&n.push(oi(e,i))}return a+r}};var Fe="*";function An(s,e){let t=[];return typeof s=="string"?s.split(/\s*,\s*/).forEach(i=>bn(i,t,e)):t.push(s),t}function bn(s,e,t){if(s[0]==":"){let l=wn(s,t);if(typeof l=="function"){e.push(l);return}s=l}let i=s.match(/^(\*|[-\w]+)\s*(<?[=-]>)\s*(\*|[-\w]+)$/);if(i==null||i.length<4)return t.push(Si(s)),e;let n=i[1],r=i[2],a=i[3];e.push(zi(n,a));let o=n==Fe&&a==Fe;r[0]=="<"&&!o&&e.push(zi(a,n))}function wn(s,e){switch(s){case":enter":return"void => *";case":leave":return"* => void";case":increment":return(t,i)=>parseFloat(i)>parseFloat(t);case":decrement":return(t,i)=>parseFloat(i)<parseFloat(t);default:return e.push(Ei(s)),"* => *"}}var De=new Set(["true","1"]),Re=new Set(["false","0"]);function zi(s,e){let t=De.has(s)||Re.has(s),i=De.has(e)||Re.has(e);return(n,r)=>{let a=s==Fe||s==n,o=e==Fe||e==r;return!a&&t&&typeof n=="boolean"&&(a=n?De.has(s):Re.has(s)),!o&&i&&typeof r=="boolean"&&(o=r?De.has(e):Re.has(e)),a&&o}}var Hi=":self",Pn=new RegExp(`s*${Hi}s*,?`,"g");function Yi(s,e,t,i){return new dt(s).build(e,t,i)}var Ki="",dt=class{_driver;constructor(e){this._driver=e}build(e,t,i){let n=new mt(t);return this._resetContextStyleTimingState(n),O(this,se(e),n)}_resetContextStyleTimingState(e){e.currentQuerySelector=Ki,e.collectedStyles=new Map,e.collectedStyles.set(Ki,new Map),e.currentTime=0}visitTrigger(e,t){let i=t.queryCount=0,n=t.depCount=0,r=[],a=[];return e.name.charAt(0)=="@"&&t.errors.push(li()),e.definitions.forEach(o=>{if(this._resetContextStyleTimingState(t),o.type==S.State){let l=o,c=l.name;c.toString().split(/\s*,\s*/).forEach(h=>{l.name=h,r.push(this.visitState(l,t))}),l.name=c}else if(o.type==S.Transition){let l=this.visitTransition(o,t);i+=l.queryCount,n+=l.depCount,a.push(l)}else t.errors.push(ci())}),{type:S.Trigger,name:e.name,states:r,transitions:a,queryCount:i,depCount:n,options:null}}visitState(e,t){let i=this.visitStyle(e.styles,t),n=e.options&&e.options.params||null;if(i.containsDynamicStyles){let r=new Set,a=n||{};i.styles.forEach(o=>{o instanceof Map&&o.forEach(l=>{at(l).forEach(c=>{a.hasOwnProperty(c)||r.add(c)})})}),r.size&&t.errors.push(ui(e.name,[...r.values()]))}return{type:S.State,name:e.name,style:i,options:n?{params:n}:null}}visitTransition(e,t){t.queryCount=0,t.depCount=0;let i=O(this,se(e.animation),t),n=An(e.expr,t.errors);return{type:S.Transition,matchers:n,animation:i,queryCount:t.queryCount,depCount:t.depCount,options:Z(e.options)}}visitSequence(e,t){return{type:S.Sequence,steps:e.steps.map(i=>O(this,i,t)),options:Z(e.options)}}visitGroup(e,t){let i=t.currentTime,n=0,r=e.steps.map(a=>{t.currentTime=i;let o=O(this,a,t);return n=Math.max(n,t.currentTime),o});return t.currentTime=n,{type:S.Group,steps:r,options:Z(e.options)}}visitAnimate(e,t){let i=Dn(e.timings,t.errors);t.currentAnimateTimings=i;let n,r=e.styles?e.styles:Ye({});if(r.type==S.Keyframes)n=this.visitKeyframes(r,t);else{let a=e.styles,o=!1;if(!a){o=!0;let c={};i.easing&&(c.easing=i.easing),a=Ye(c)}t.currentTime+=i.duration+i.delay;let l=this.visitStyle(a,t);l.isEmptyStep=o,n=l}return t.currentAnimateTimings=null,{type:S.Animate,timings:i,style:n,options:null}}visitStyle(e,t){let i=this._makeStyleAst(e,t);return this._validateStyleAst(i,t),i}_makeStyleAst(e,t){let i=[],n=Array.isArray(e.styles)?e.styles:[e.styles];for(let o of n)typeof o=="string"?o===K?i.push(o):t.errors.push(hi(o)):i.push(new Map(Object.entries(o)));let r=!1,a=null;return i.forEach(o=>{if(o instanceof Map&&(o.has("easing")&&(a=o.get("easing"),o.delete("easing")),!r)){for(let l of o.values())if(l.toString().indexOf(nt)>=0){r=!0;break}}}),{type:S.Style,styles:i,easing:a,offset:e.offset,containsDynamicStyles:r,options:null}}_validateStyleAst(e,t){let i=t.currentAnimateTimings,n=t.currentTime,r=t.currentTime;i&&r>0&&(r-=i.duration+i.delay),e.styles.forEach(a=>{typeof a!="string"&&a.forEach((o,l)=>{let c=t.collectedStyles.get(t.currentQuerySelector),h=c.get(l),u=!0;h&&(r!=n&&r>=h.startTime&&n<=h.endTime&&(t.errors.push(di(l,h.startTime,h.endTime,r,n)),u=!1),r=h.startTime),u&&c.set(l,{startTime:r,endTime:n}),t.options&&Ii(o,t.options,t.errors)})})}visitKeyframes(e,t){let i={type:S.Keyframes,styles:[],options:null};if(!t.currentAnimateTimings)return t.errors.push(mi()),i;let n=1,r=0,a=[],o=!1,l=!1,c=0,h=e.steps.map(b=>{let w=this._makeStyleAst(b,t),M=w.offset!=null?w.offset:Mn(w.styles),N=0;return M!=null&&(r++,N=w.offset=M),l=l||N<0||N>1,o=o||N<c,c=N,a.push(N),w});l&&t.errors.push(fi()),o&&t.errors.push(pi());let u=e.steps.length,_=0;r>0&&r<u?t.errors.push(gi()):r==0&&(_=n/(u-1));let y=u-1,m=t.currentTime,g=t.currentAnimateTimings,T=g.duration;return h.forEach((b,w)=>{let M=_>0?w==y?1:_*w:a[w],N=M*T;t.currentTime=m+g.delay+N,g.duration=N,this._validateStyleAst(b,t),b.offset=M,i.styles.push(b)}),i}visitReference(e,t){return{type:S.Reference,animation:O(this,se(e.animation),t),options:Z(e.options)}}visitAnimateChild(e,t){return t.depCount++,{type:S.AnimateChild,options:Z(e.options)}}visitAnimateRef(e,t){return{type:S.AnimateRef,animation:this.visitReference(e.animation,t),options:Z(e.options)}}visitQuery(e,t){let i=t.currentQuerySelector,n=e.options||{};t.queryCount++,t.currentQuery=e;let[r,a]=Nn(e.selector);t.currentQuerySelector=i.length?i+" "+r:r,k(t.collectedStyles,t.currentQuerySelector,new Map);let o=O(this,se(e.animation),t);return t.currentQuery=null,t.currentQuerySelector=i,{type:S.Query,selector:r,limit:n.limit||0,optional:!!n.optional,includeSelf:a,animation:o,originalSelector:e.selector,options:Z(e.options)}}visitStagger(e,t){t.currentQuery||t.errors.push(yi());let i=e.timings==="full"?{duration:0,delay:0,easing:"full"}:he(e.timings,t.errors,!0);return{type:S.Stagger,animation:O(this,se(e.animation),t),timings:i,options:null}}};function Nn(s){let e=!!s.split(/\s*,\s*/).find(t=>t==Hi);return e&&(s=s.replace(Pn,"")),s=s.replace(/@\*/g,ue).replace(/@\w+/g,t=>ue+"-"+t.slice(1)).replace(/:animating/g,Ne),[s,e]}function Cn(s){return s?ye({},s):null}var mt=class{errors;queryCount=0;depCount=0;currentTransition=null;currentQuery=null;currentQuerySelector=null;currentAnimateTimings=null;currentTime=0;collectedStyles=new Map;options=null;unsupportedCSSPropertiesFound=new Set;constructor(e){this.errors=e}};function Mn(s){if(typeof s=="string")return null;let e=null;if(Array.isArray(s))s.forEach(t=>{if(t instanceof Map&&t.has("offset")){let i=t;e=parseFloat(i.get("offset")),i.delete("offset")}});else if(s instanceof Map&&s.has("offset")){let t=s;e=parseFloat(t.get("offset")),t.delete("offset")}return e}function Dn(s,e){if(s.hasOwnProperty("duration"))return s;if(typeof s=="number"){let r=he(s,e).duration;return ot(r,0,"")}let t=s;if(t.split(/\s+/).some(r=>r.charAt(0)=="{"&&r.charAt(1)=="{")){let r=ot(0,0,"");return r.dynamic=!0,r.strValue=t,r}let n=he(t,e);return ot(n.duration,n.delay,n.easing)}function Z(s){return s?(s=ye({},s),s.params&&(s.params=Cn(s.params))):s={},s}function ot(s,e,t){return{duration:s,delay:e,easing:t}}function bt(s,e,t,i,n,r,a=null,o=!1){return{type:1,element:s,keyframes:e,preStyleProps:t,postStyleProps:i,duration:n,delay:r,totalTime:n+r,easing:a,subTimeline:o}}var me=class{_map=new Map;get(e){return this._map.get(e)||[]}append(e,t){let i=this._map.get(e);i||this._map.set(e,i=[]),i.push(...t)}has(e){return this._map.has(e)}clear(){this._map.clear()}},Rn=1,kn=":enter",On=new RegExp(kn,"g"),In=":leave",Fn=new RegExp(In,"g");function Xi(s,e,t,i,n,r=new Map,a=new Map,o,l,c=[]){return new ft().buildKeyframes(s,e,t,i,n,r,a,o,l,c)}var ft=class{buildKeyframes(e,t,i,n,r,a,o,l,c,h=[]){c=c||new me;let u=new pt(e,t,c,n,r,h,[]);u.options=l;let _=l.delay?U(l.delay):0;u.currentTimeline.delayNextStep(_),u.currentTimeline.setStyles([a],null,u.errors,l),O(this,i,u);let y=u.timelines.filter(m=>m.containsAnimation());if(y.length&&o.size){let m;for(let g=y.length-1;g>=0;g--){let T=y[g];if(T.element===t){m=T;break}}m&&!m.allowOnlyTimelineStyles()&&m.setStyles([o],null,u.errors,l)}return y.length?y.map(m=>m.buildKeyframes()):[bt(t,[],[],[],0,_,"",!1)]}visitTrigger(e,t){}visitState(e,t){}visitTransition(e,t){}visitAnimateChild(e,t){let i=t.subInstructions.get(t.element);if(i){let n=t.createSubContext(e.options),r=t.currentTimeline.currentTime,a=this._visitSubInstructions(i,n,n.options);r!=a&&t.transformIntoNewTimeline(a)}t.previousNode=e}visitAnimateRef(e,t){let i=t.createSubContext(e.options);i.transformIntoNewTimeline(),this._applyAnimationRefDelays([e.options,e.animation.options],t,i),this.visitReference(e.animation,i),t.transformIntoNewTimeline(i.currentTimeline.currentTime),t.previousNode=e}_applyAnimationRefDelays(e,t,i){for(let n of e){let r=n?.delay;if(r){let a=typeof r=="number"?r:U(re(r,n?.params??{},t.errors));i.delayNextStep(a)}}}_visitSubInstructions(e,t,i){let r=t.currentTimeline.currentTime,a=i.duration!=null?U(i.duration):null,o=i.delay!=null?U(i.delay):null;return a!==0&&e.forEach(l=>{let c=t.appendInstructionToTimeline(l,a,o);r=Math.max(r,c.duration+c.delay)}),r}visitReference(e,t){t.updateOptions(e.options,!0),O(this,e.animation,t),t.previousNode=e}visitSequence(e,t){let i=t.subContextCount,n=t,r=e.options;if(r&&(r.params||r.delay)&&(n=t.createSubContext(r),n.transformIntoNewTimeline(),r.delay!=null)){n.previousNode.type==S.Style&&(n.currentTimeline.snapshotCurrentStyles(),n.previousNode=Le);let a=U(r.delay);n.delayNextStep(a)}e.steps.length&&(e.steps.forEach(a=>O(this,a,n)),n.currentTimeline.applyStylesToKeyframe(),n.subContextCount>i&&n.transformIntoNewTimeline()),t.previousNode=e}visitGroup(e,t){let i=[],n=t.currentTimeline.currentTime,r=e.options&&e.options.delay?U(e.options.delay):0;e.steps.forEach(a=>{let o=t.createSubContext(e.options);r&&o.delayNextStep(r),O(this,a,o),n=Math.max(n,o.currentTimeline.currentTime),i.push(o.currentTimeline)}),i.forEach(a=>t.currentTimeline.mergeTimelineCollectedStyles(a)),t.transformIntoNewTimeline(n),t.previousNode=e}_visitTiming(e,t){if(e.dynamic){let i=e.strValue,n=t.params?re(i,t.params,t.errors):i;return he(n,t.errors)}else return{duration:e.duration,delay:e.delay,easing:e.easing}}visitAnimate(e,t){let i=t.currentAnimateTimings=this._visitTiming(e.timings,t),n=t.currentTimeline;i.delay&&(t.incrementTime(i.delay),n.snapshotCurrentStyles());let r=e.style;r.type==S.Keyframes?this.visitKeyframes(r,t):(t.incrementTime(i.duration),this.visitStyle(r,t),n.applyStylesToKeyframe()),t.currentAnimateTimings=null,t.previousNode=e}visitStyle(e,t){let i=t.currentTimeline,n=t.currentAnimateTimings;!n&&i.hasCurrentStyleProperties()&&i.forwardFrame();let r=n&&n.easing||e.easing;e.isEmptyStep?i.applyEmptyStep(r):i.setStyles(e.styles,r,t.errors,t.options),t.previousNode=e}visitKeyframes(e,t){let i=t.currentAnimateTimings,n=t.currentTimeline.duration,r=i.duration,o=t.createSubContext().currentTimeline;o.easing=i.easing,e.styles.forEach(l=>{let c=l.offset||0;o.forwardTime(c*r),o.setStyles(l.styles,l.easing,t.errors,t.options),o.applyStylesToKeyframe()}),t.currentTimeline.mergeTimelineCollectedStyles(o),t.transformIntoNewTimeline(n+r),t.previousNode=e}visitQuery(e,t){let i=t.currentTimeline.currentTime,n=e.options||{},r=n.delay?U(n.delay):0;r&&(t.previousNode.type===S.Style||i==0&&t.currentTimeline.hasCurrentStyleProperties())&&(t.currentTimeline.snapshotCurrentStyles(),t.previousNode=Le);let a=i,o=t.invokeQuery(e.selector,e.originalSelector,e.limit,e.includeSelf,!!n.optional,t.errors);t.currentQueryTotal=o.length;let l=null;o.forEach((c,h)=>{t.currentQueryIndex=h;let u=t.createSubContext(e.options,c);r&&u.delayNextStep(r),c===t.element&&(l=u.currentTimeline),O(this,e.animation,u),u.currentTimeline.applyStylesToKeyframe();let _=u.currentTimeline.currentTime;a=Math.max(a,_)}),t.currentQueryIndex=0,t.currentQueryTotal=0,t.transformIntoNewTimeline(a),l&&(t.currentTimeline.mergeTimelineCollectedStyles(l),t.currentTimeline.snapshotCurrentStyles()),t.previousNode=e}visitStagger(e,t){let i=t.parentContext,n=t.currentTimeline,r=e.timings,a=Math.abs(r.duration),o=a*(t.currentQueryTotal-1),l=a*t.currentQueryIndex;switch(r.duration<0?"reverse":r.easing){case"reverse":l=o-l;break;case"full":l=i.currentStaggerTime;break}let h=t.currentTimeline;l&&h.delayNextStep(l);let u=h.currentTime;O(this,e.animation,t),t.previousNode=e,i.currentStaggerTime=n.currentTime-u+(n.startTime-i.currentTimeline.startTime)}},Le={},pt=class s{_driver;element;subInstructions;_enterClassName;_leaveClassName;errors;timelines;parentContext=null;currentTimeline;currentAnimateTimings=null;previousNode=Le;subContextCount=0;options={};currentQueryIndex=0;currentQueryTotal=0;currentStaggerTime=0;constructor(e,t,i,n,r,a,o,l){this._driver=e,this.element=t,this.subInstructions=i,this._enterClassName=n,this._leaveClassName=r,this.errors=a,this.timelines=o,this.currentTimeline=l||new ze(this._driver,t,0),o.push(this.currentTimeline)}get params(){return this.options.params}updateOptions(e,t){if(!e)return;let i=e,n=this.options;i.duration!=null&&(n.duration=U(i.duration)),i.delay!=null&&(n.delay=U(i.delay));let r=i.params;if(r){let a=n.params;a||(a=this.options.params={}),Object.keys(r).forEach(o=>{(!t||!a.hasOwnProperty(o))&&(a[o]=re(r[o],a,this.errors))})}}_copyOptions(){let e={};if(this.options){let t=this.options.params;if(t){let i=e.params={};Object.keys(t).forEach(n=>{i[n]=t[n]})}}return e}createSubContext(e=null,t,i){let n=t||this.element,r=new s(this._driver,n,this.subInstructions,this._enterClassName,this._leaveClassName,this.errors,this.timelines,this.currentTimeline.fork(n,i||0));return r.previousNode=this.previousNode,r.currentAnimateTimings=this.currentAnimateTimings,r.options=this._copyOptions(),r.updateOptions(e),r.currentQueryIndex=this.currentQueryIndex,r.currentQueryTotal=this.currentQueryTotal,r.parentContext=this,this.subContextCount++,r}transformIntoNewTimeline(e){return this.previousNode=Le,this.currentTimeline=this.currentTimeline.fork(this.element,e),this.timelines.push(this.currentTimeline),this.currentTimeline}appendInstructionToTimeline(e,t,i){let n={duration:t??e.duration,delay:this.currentTimeline.currentTime+(i??0)+e.delay,easing:""},r=new gt(this._driver,e.element,e.keyframes,e.preStyleProps,e.postStyleProps,n,e.stretchStartingKeyframe);return this.timelines.push(r),n}incrementTime(e){this.currentTimeline.forwardTime(this.currentTimeline.duration+e)}delayNextStep(e){e>0&&this.currentTimeline.delayNextStep(e)}invokeQuery(e,t,i,n,r,a){let o=[];if(n&&o.push(this.element),e.length>0){e=e.replace(On,"."+this._enterClassName),e=e.replace(Fn,"."+this._leaveClassName);let l=i!=1,c=this._driver.query(this.element,e,l);i!==0&&(c=i<0?c.slice(c.length+i,c.length):c.slice(0,i)),o.push(...c)}return!r&&o.length==0&&a.push(_i(t)),o}},ze=class s{_driver;element;startTime;_elementTimelineStylesLookup;duration=0;easing=null;_previousKeyframe=new Map;_currentKeyframe=new Map;_keyframes=new Map;_styleSummary=new Map;_localTimelineStyles=new Map;_globalTimelineStyles;_pendingStyles=new Map;_backFill=new Map;_currentEmptyStepKeyframe=null;constructor(e,t,i,n){this._driver=e,this.element=t,this.startTime=i,this._elementTimelineStylesLookup=n,this._elementTimelineStylesLookup||(this._elementTimelineStylesLookup=new Map),this._globalTimelineStyles=this._elementTimelineStylesLookup.get(t),this._globalTimelineStyles||(this._globalTimelineStyles=this._localTimelineStyles,this._elementTimelineStylesLookup.set(t,this._localTimelineStyles)),this._loadKeyframe()}containsAnimation(){switch(this._keyframes.size){case 0:return!1;case 1:return this.hasCurrentStyleProperties();default:return!0}}hasCurrentStyleProperties(){return this._currentKeyframe.size>0}get currentTime(){return this.startTime+this.duration}delayNextStep(e){let t=this._keyframes.size===1&&this._pendingStyles.size;this.duration||t?(this.forwardTime(this.currentTime+e),t&&this.snapshotCurrentStyles()):this.startTime+=e}fork(e,t){return this.applyStylesToKeyframe(),new s(this._driver,e,t||this.currentTime,this._elementTimelineStylesLookup)}_loadKeyframe(){this._currentKeyframe&&(this._previousKeyframe=this._currentKeyframe),this._currentKeyframe=this._keyframes.get(this.duration),this._currentKeyframe||(this._currentKeyframe=new Map,this._keyframes.set(this.duration,this._currentKeyframe))}forwardFrame(){this.duration+=Rn,this._loadKeyframe()}forwardTime(e){this.applyStylesToKeyframe(),this.duration=e,this._loadKeyframe()}_updateStyle(e,t){this._localTimelineStyles.set(e,t),this._globalTimelineStyles.set(e,t),this._styleSummary.set(e,{time:this.currentTime,value:t})}allowOnlyTimelineStyles(){return this._currentEmptyStepKeyframe!==this._currentKeyframe}applyEmptyStep(e){e&&this._previousKeyframe.set("easing",e);for(let[t,i]of this._globalTimelineStyles)this._backFill.set(t,i||K),this._currentKeyframe.set(t,K);this._currentEmptyStepKeyframe=this._currentKeyframe}setStyles(e,t,i,n){t&&this._previousKeyframe.set("easing",t);let r=n&&n.params||{},a=Ln(e,this._globalTimelineStyles);for(let[o,l]of a){let c=re(l,r,i);this._pendingStyles.set(o,c),this._localTimelineStyles.has(o)||this._backFill.set(o,this._globalTimelineStyles.get(o)??K),this._updateStyle(o,c)}}applyStylesToKeyframe(){this._pendingStyles.size!=0&&(this._pendingStyles.forEach((e,t)=>{this._currentKeyframe.set(t,e)}),this._pendingStyles.clear(),this._localTimelineStyles.forEach((e,t)=>{this._currentKeyframe.has(t)||this._currentKeyframe.set(t,e)}))}snapshotCurrentStyles(){for(let[e,t]of this._localTimelineStyles)this._pendingStyles.set(e,t),this._updateStyle(e,t)}getFinalKeyframe(){return this._keyframes.get(this.duration)}get properties(){let e=[];for(let t in this._currentKeyframe)e.push(t);return e}mergeTimelineCollectedStyles(e){e._styleSummary.forEach((t,i)=>{let n=this._styleSummary.get(i);(!n||t.time>n.time)&&this._updateStyle(i,t.value)})}buildKeyframes(){this.applyStylesToKeyframe();let e=new Set,t=new Set,i=this._keyframes.size===1&&this.duration===0,n=[];this._keyframes.forEach((o,l)=>{let c=new Map([...this._backFill,...o]);c.forEach((h,u)=>{h===le?e.add(u):h===K&&t.add(u)}),i||c.set("offset",l/this.duration),n.push(c)});let r=[...e.values()],a=[...t.values()];if(i){let o=n[0],l=new Map(o);o.set("offset",0),l.set("offset",1),n=[o,l]}return bt(this.element,n,r,a,this.duration,this.startTime,this.easing,!1)}},gt=class extends ze{keyframes;preStyleProps;postStyleProps;_stretchStartingKeyframe;timings;constructor(e,t,i,n,r,a,o=!1){super(e,t,a.delay),this.keyframes=i,this.preStyleProps=n,this.postStyleProps=r,this._stretchStartingKeyframe=o,this.timings={duration:a.duration,delay:a.delay,easing:a.easing}}containsAnimation(){return this.keyframes.length>1}buildKeyframes(){let e=this.keyframes,{delay:t,duration:i,easing:n}=this.timings;if(this._stretchStartingKeyframe&&t){let r=[],a=i+t,o=t/a,l=new Map(e[0]);l.set("offset",0),r.push(l);let c=new Map(e[0]);c.set("offset",ji(o)),r.push(c);let h=e.length-1;for(let u=1;u<=h;u++){let _=new Map(e[u]),y=_.get("offset"),m=t+y*i;_.set("offset",ji(m/a)),r.push(_)}i=a,t=0,n="",e=r}return bt(this.element,e,this.preStyleProps,this.postStyleProps,i,t,n,!0)}};function ji(s,e=3){let t=Math.pow(10,e-1);return Math.round(s*t)/t}function Ln(s,e){let t=new Map,i;return s.forEach(n=>{if(n==="*"){i??=e.keys();for(let r of i)t.set(r,K)}else for(let[r,a]of n)t.set(r,a)}),t}function Bi(s,e,t,i,n,r,a,o,l,c,h,u,_){return{type:0,element:s,triggerName:e,isRemovalTransition:n,fromState:t,fromStyles:r,toState:i,toStyles:a,timelines:o,queriedElements:l,preStyleProps:c,postStyleProps:h,totalTime:u,errors:_}}var lt={},Ke=class{_triggerName;ast;_stateStyles;constructor(e,t,i){this._triggerName=e,this.ast=t,this._stateStyles=i}match(e,t,i,n){return zn(this.ast.matchers,e,t,i,n)}buildStyles(e,t,i){let n=this._stateStyles.get("*");return e!==void 0&&(n=this._stateStyles.get(e?.toString())||n),n?n.buildStyles(t,i):new Map}build(e,t,i,n,r,a,o,l,c,h){let u=[],_=this.ast.options&&this.ast.options.params||lt,y=o&&o.params||lt,m=this.buildStyles(i,y,u),g=l&&l.params||lt,T=this.buildStyles(n,g,u),b=new Set,w=new Map,M=new Map,N=n==="void",ie={params:xi(g,_),delay:this.ast.options?.delay},q=h?[]:Xi(e,t,this.ast.animation,r,a,m,T,ie,c,u),D=0;return q.forEach(R=>{D=Math.max(R.duration+R.delay,D)}),u.length?Bi(t,this._triggerName,i,n,N,m,T,[],[],w,M,D,u):(q.forEach(R=>{let W=R.element,ne=k(w,W,new Set);R.preStyleProps.forEach(H=>ne.add(H));let wt=k(M,W,new Set);R.postStyleProps.forEach(H=>wt.add(H)),W!==t&&b.add(W)}),Bi(t,this._triggerName,i,n,N,m,T,q,[...b.values()],w,M,D))}};function zn(s,e,t,i,n){return s.some(r=>r(e,t,i,n))}function xi(s,e){let t=ye({},e);return Object.entries(s).forEach(([i,n])=>{n!=null&&(t[i]=n)}),t}var yt=class{styles;defaultParams;normalizer;constructor(e,t,i){this.styles=e,this.defaultParams=t,this.normalizer=i}buildStyles(e,t){let i=new Map,n=xi(e,this.defaultParams);return this.styles.styles.forEach(r=>{typeof r!="string"&&r.forEach((a,o)=>{a&&(a=re(a,n,t));let l=this.normalizer.normalizePropertyName(o,t);a=this.normalizer.normalizeStyleValue(o,l,a,t),i.set(o,a)})}),i}};function Kn(s,e,t){return new _t(s,e,t)}var _t=class{name;ast;_normalizer;transitionFactories=[];fallbackTransition;states=new Map;constructor(e,t,i){this.name=e,this.ast=t,this._normalizer=i,t.states.forEach(n=>{let r=n.options&&n.options.params||{};this.states.set(n.name,new yt(n.style,r,i))}),qi(this.states,"true","1"),qi(this.states,"false","0"),t.transitions.forEach(n=>{this.transitionFactories.push(new Ke(e,n,this.states))}),this.fallbackTransition=jn(e,this.states)}get containsQueries(){return this.ast.queryCount>0}matchTransition(e,t,i,n){return this.transitionFactories.find(a=>a.match(e,t,i,n))||null}matchStyles(e,t,i){return this.fallbackTransition.buildStyles(e,t,i)}};function jn(s,e,t){let i=[(a,o)=>!0],n={type:S.Sequence,steps:[],options:null},r={type:S.Transition,animation:n,matchers:i,options:null,queryCount:0,depCount:0};return new Ke(s,r,e)}function qi(s,e,t){s.has(e)?s.has(t)||s.set(t,s.get(e)):s.has(t)&&s.set(e,s.get(t))}var Bn=new me,St=class{bodyNode;_driver;_normalizer;_animations=new Map;_playersById=new Map;players=[];constructor(e,t,i){this.bodyNode=e,this._driver=t,this._normalizer=i}register(e,t){let i=[],n=[],r=Yi(this._driver,t,i,n);if(i.length)throw Ti(i);this._animations.set(e,r)}_buildPlayer(e,t,i){let n=e.element,r=Je(this._normalizer,e.keyframes,t,i);return this._driver.animate(n,r,e.duration,e.delay,e.easing,[],!0)}create(e,t,i={}){let n=[],r=this._animations.get(e),a,o=new Map;if(r?(a=Xi(this._driver,t,r,st,Pe,new Map,new Map,i,Bn,n),a.forEach(h=>{let u=k(o,h.element,new Map);h.postStyleProps.forEach(_=>u.set(_,null))})):(n.push(Ai()),a=[]),n.length)throw bi(n);o.forEach((h,u)=>{h.forEach((_,y)=>{h.set(y,this._driver.computeStyle(u,y,K))})});let l=a.map(h=>{let u=o.get(h.element);return this._buildPlayer(h,new Map,u)}),c=V(l);return this._playersById.set(e,c),c.onDestroy(()=>this.destroy(e)),this.players.push(c),c}destroy(e){let t=this._getPlayer(e);t.destroy(),this._playersById.delete(e);let i=this.players.indexOf(t);i>=0&&this.players.splice(i,1)}_getPlayer(e){let t=this._playersById.get(e);if(!t)throw wi(e);return t}listen(e,t,i,n){let r=be(t,"","","");return Ae(this._getPlayer(e),i,r,n),()=>{}}command(e,t,i,n){if(i=="register"){this.register(e,n[0]);return}if(i=="create"){let a=n[0]||{};this.create(e,t,a);return}let r=this._getPlayer(e);switch(i){case"play":r.play();break;case"pause":r.pause();break;case"reset":r.reset();break;case"restart":r.restart();break;case"finish":r.finish();break;case"init":r.init();break;case"setPosition":r.setPosition(parseFloat(n[0]));break;case"destroy":this.destroy(e);break}}},Qi="ng-animate-queued",qn=".ng-animate-queued",ct="ng-animate-disabled",Qn=".ng-animate-disabled",Un="ng-star-inserted",Vn=".ng-star-inserted",$n=[],Zi={namespaceId:"",setForRemoval:!1,setForMove:!1,hasAnimation:!1,removedBeforeQueried:!1},Gn={namespaceId:"",setForMove:!1,setForRemoval:!1,hasAnimation:!1,removedBeforeQueried:!0},B="__ng_removed",fe=class{namespaceId;value;options;get params(){return this.options.params}constructor(e,t=""){this.namespaceId=t;let i=e&&e.hasOwnProperty("value"),n=i?e.value:e;if(this.value=Hn(n),i){let r=e,{value:a}=r,o=Mt(r,["value"]);this.options=o}else this.options={};this.options.params||(this.options.params={})}absorbOptions(e){let t=e.params;if(t){let i=this.options.params;Object.keys(t).forEach(n=>{i[n]==null&&(i[n]=t[n])})}}},de="void",ut=new fe(de),Et=class{id;hostElement;_engine;players=[];_triggers=new Map;_queue=[];_elementListeners=new Map;_hostClassName;constructor(e,t,i){this.id=e,this.hostElement=t,this._engine=i,this._hostClassName="ng-tns-"+e,L(t,this._hostClassName)}listen(e,t,i,n){if(!this._triggers.has(t))throw Pi(i,t);if(i==null||i.length==0)throw Ni(t);if(!Yn(i))throw Ci(i,t);let r=k(this._elementListeners,e,[]),a={name:t,phase:i,callback:n};r.push(a);let o=k(this._engine.statesByElement,e,new Map);return o.has(t)||(L(e,ce),L(e,ce+"-"+t),o.set(t,ut)),()=>{this._engine.afterFlush(()=>{let l=r.indexOf(a);l>=0&&r.splice(l,1),this._triggers.has(t)||o.delete(t)})}}register(e,t){return this._triggers.has(e)?!1:(this._triggers.set(e,t),!0)}_getTrigger(e){let t=this._triggers.get(e);if(!t)throw Mi(e);return t}trigger(e,t,i,n=!0){let r=this._getTrigger(t),a=new pe(this.id,t,e),o=this._engine.statesByElement.get(e);o||(L(e,ce),L(e,ce+"-"+t),this._engine.statesByElement.set(e,o=new Map));let l=o.get(t),c=new fe(i,this.id);if(!(i&&i.hasOwnProperty("value"))&&l&&c.absorbOptions(l.options),o.set(t,c),l||(l=ut),!(c.value===de)&&l.value===c.value){if(!Zn(l.params,c.params)){let g=[],T=r.matchStyles(l.value,l.params,g),b=r.matchStyles(c.value,c.params,g);g.length?this._engine.reportError(g):this._engine.afterFlush(()=>{G(e,T),j(e,b)})}return}let _=k(this._engine.playersByElement,e,[]);_.forEach(g=>{g.namespaceId==this.id&&g.triggerName==t&&g.queued&&g.destroy()});let y=r.matchTransition(l.value,c.value,e,c.params),m=!1;if(!y){if(!n)return;y=r.fallbackTransition,m=!0}return this._engine.totalQueuedPlayers++,this._queue.push({element:e,triggerName:t,transition:y,fromState:l,toState:c,player:a,isFallbackTransition:m}),m||(L(e,Qi),a.onStart(()=>{ae(e,Qi)})),a.onDone(()=>{let g=this.players.indexOf(a);g>=0&&this.players.splice(g,1);let T=this._engine.playersByElement.get(e);if(T){let b=T.indexOf(a);b>=0&&T.splice(b,1)}}),this.players.push(a),_.push(a),a}deregister(e){this._triggers.delete(e),this._engine.statesByElement.forEach(t=>t.delete(e)),this._elementListeners.forEach((t,i)=>{this._elementListeners.set(i,t.filter(n=>n.name!=e))})}clearElementCache(e){this._engine.statesByElement.delete(e),this._elementListeners.delete(e);let t=this._engine.playersByElement.get(e);t&&(t.forEach(i=>i.destroy()),this._engine.playersByElement.delete(e))}_signalRemovalForInnerTriggers(e,t){let i=this._engine.driver.query(e,ue,!0);i.forEach(n=>{if(n[B])return;let r=this._engine.fetchNamespacesByElement(n);r.size?r.forEach(a=>a.triggerLeaveAnimation(n,t,!1,!0)):this.clearElementCache(n)}),this._engine.afterFlushAnimationsDone(()=>i.forEach(n=>this.clearElementCache(n)))}triggerLeaveAnimation(e,t,i,n){let r=this._engine.statesByElement.get(e),a=new Map;if(r){let o=[];if(r.forEach((l,c)=>{if(a.set(c,l.value),this._triggers.has(c)){let h=this.trigger(e,c,de,n);h&&o.push(h)}}),o.length)return this._engine.markElementAsRemoved(this.id,e,!0,t,a),i&&V(o).onDone(()=>this._engine.processLeaveNode(e)),!0}return!1}prepareLeaveAnimationListeners(e){let t=this._elementListeners.get(e),i=this._engine.statesByElement.get(e);if(t&&i){let n=new Set;t.forEach(r=>{let a=r.name;if(n.has(a))return;n.add(a);let l=this._triggers.get(a).fallbackTransition,c=i.get(a)||ut,h=new fe(de),u=new pe(this.id,a,e);this._engine.totalQueuedPlayers++,this._queue.push({element:e,triggerName:a,transition:l,fromState:c,toState:h,player:u,isFallbackTransition:!0})})}}removeNode(e,t){let i=this._engine;if(e.childElementCount&&this._signalRemovalForInnerTriggers(e,t),this.triggerLeaveAnimation(e,t,!0))return;let n=!1;if(i.totalAnimations){let r=i.players.length?i.playersByQueriedElement.get(e):[];if(r&&r.length)n=!0;else{let a=e;for(;a=a.parentNode;)if(i.statesByElement.get(a)){n=!0;break}}}if(this.prepareLeaveAnimationListeners(e),n)i.markElementAsRemoved(this.id,e,!1,t);else{let r=e[B];(!r||r===Zi)&&(i.afterFlush(()=>this.clearElementCache(e)),i.destroyInnerAnimations(e),i._onRemovalComplete(e,t))}}insertNode(e,t){L(e,this._hostClassName)}drainQueuedTransitions(e){let t=[];return this._queue.forEach(i=>{let n=i.player;if(n.destroyed)return;let r=i.element,a=this._elementListeners.get(r);a&&a.forEach(o=>{if(o.name==i.triggerName){let l=be(r,i.triggerName,i.fromState.value,i.toState.value);l._data=e,Ae(i.player,o.phase,l,o.callback)}}),n.markedForDestroy?this._engine.afterFlush(()=>{n.destroy()}):t.push(i)}),this._queue=[],t.sort((i,n)=>{let r=i.transition.ast.depCount,a=n.transition.ast.depCount;return r==0||a==0?r-a:this._engine.driver.containsElement(i.element,n.element)?1:-1})}destroy(e){this.players.forEach(t=>t.destroy()),this._signalRemovalForInnerTriggers(this.hostElement,e)}},vt=class{bodyNode;driver;_normalizer;players=[];newHostElements=new Map;playersByElement=new Map;playersByQueriedElement=new Map;statesByElement=new Map;disabledNodes=new Set;totalAnimations=0;totalQueuedPlayers=0;_namespaceLookup={};_namespaceList=[];_flushFns=[];_whenQuietFns=[];namespacesByHostElement=new Map;collectedEnterElements=[];collectedLeaveElements=[];onRemovalComplete=(e,t)=>{};_onRemovalComplete(e,t){this.onRemovalComplete(e,t)}constructor(e,t,i){this.bodyNode=e,this.driver=t,this._normalizer=i}get queuedPlayers(){let e=[];return this._namespaceList.forEach(t=>{t.players.forEach(i=>{i.queued&&e.push(i)})}),e}createNamespace(e,t){let i=new Et(e,t,this);return this.bodyNode&&this.driver.containsElement(this.bodyNode,t)?this._balanceNamespaceList(i,t):(this.newHostElements.set(t,i),this.collectEnterElement(t)),this._namespaceLookup[e]=i}_balanceNamespaceList(e,t){let i=this._namespaceList,n=this.namespacesByHostElement;if(i.length-1>=0){let a=!1,o=this.driver.getParentElement(t);for(;o;){let l=n.get(o);if(l){let c=i.indexOf(l);i.splice(c+1,0,e),a=!0;break}o=this.driver.getParentElement(o)}a||i.unshift(e)}else i.push(e);return n.set(t,e),e}register(e,t){let i=this._namespaceLookup[e];return i||(i=this.createNamespace(e,t)),i}registerTrigger(e,t,i){let n=this._namespaceLookup[e];n&&n.register(t,i)&&this.totalAnimations++}destroy(e,t){e&&(this.afterFlush(()=>{}),this.afterFlushAnimationsDone(()=>{let i=this._fetchNamespace(e);this.namespacesByHostElement.delete(i.hostElement);let n=this._namespaceList.indexOf(i);n>=0&&this._namespaceList.splice(n,1),i.destroy(t),delete this._namespaceLookup[e]}))}_fetchNamespace(e){return this._namespaceLookup[e]}fetchNamespacesByElement(e){let t=new Set,i=this.statesByElement.get(e);if(i){for(let n of i.values())if(n.namespaceId){let r=this._fetchNamespace(n.namespaceId);r&&t.add(r)}}return t}trigger(e,t,i,n){if(ke(t)){let r=this._fetchNamespace(e);if(r)return r.trigger(t,i,n),!0}return!1}insertNode(e,t,i,n){if(!ke(t))return;let r=t[B];if(r&&r.setForRemoval){r.setForRemoval=!1,r.setForMove=!0;let a=this.collectedLeaveElements.indexOf(t);a>=0&&this.collectedLeaveElements.splice(a,1)}if(e){let a=this._fetchNamespace(e);a&&a.insertNode(t,i)}n&&this.collectEnterElement(t)}collectEnterElement(e){this.collectedEnterElements.push(e)}markElementAsDisabled(e,t){t?this.disabledNodes.has(e)||(this.disabledNodes.add(e),L(e,ct)):this.disabledNodes.has(e)&&(this.disabledNodes.delete(e),ae(e,ct))}removeNode(e,t,i){if(ke(t)){let n=e?this._fetchNamespace(e):null;n?n.removeNode(t,i):this.markElementAsRemoved(e,t,!1,i);let r=this.namespacesByHostElement.get(t);r&&r.id!==e&&r.removeNode(t,i)}else this._onRemovalComplete(t,i)}markElementAsRemoved(e,t,i,n,r){this.collectedLeaveElements.push(t),t[B]={namespaceId:e,setForRemoval:n,hasAnimation:i,removedBeforeQueried:!1,previousTriggersValues:r}}listen(e,t,i,n,r){return ke(t)?this._fetchNamespace(e).listen(t,i,n,r):()=>{}}_buildInstruction(e,t,i,n,r){return e.transition.build(this.driver,e.element,e.fromState.value,e.toState.value,i,n,e.fromState.options,e.toState.options,t,r)}destroyInnerAnimations(e){let t=this.driver.query(e,ue,!0);t.forEach(i=>this.destroyActiveAnimationsForElement(i)),this.playersByQueriedElement.size!=0&&(t=this.driver.query(e,Ne,!0),t.forEach(i=>this.finishActiveQueriedAnimationOnElement(i)))}destroyActiveAnimationsForElement(e){let t=this.playersByElement.get(e);t&&t.forEach(i=>{i.queued?i.markedForDestroy=!0:i.destroy()})}finishActiveQueriedAnimationOnElement(e){let t=this.playersByQueriedElement.get(e);t&&t.forEach(i=>i.finish())}whenRenderingDone(){return new Promise(e=>{if(this.players.length)return V(this.players).onDone(()=>e());e()})}processLeaveNode(e){let t=e[B];if(t&&t.setForRemoval){if(e[B]=Zi,t.namespaceId){this.destroyInnerAnimations(e);let i=this._fetchNamespace(t.namespaceId);i&&i.clearElementCache(e)}this._onRemovalComplete(e,t.setForRemoval)}e.classList?.contains(ct)&&this.markElementAsDisabled(e,!1),this.driver.query(e,Qn,!0).forEach(i=>{this.markElementAsDisabled(i,!1)})}flush(e=-1){let t=[];if(this.newHostElements.size&&(this.newHostElements.forEach((i,n)=>this._balanceNamespaceList(i,n)),this.newHostElements.clear()),this.totalAnimations&&this.collectedEnterElements.length)for(let i=0;i<this.collectedEnterElements.length;i++){let n=this.collectedEnterElements[i];L(n,Un)}if(this._namespaceList.length&&(this.totalQueuedPlayers||this.collectedLeaveElements.length)){let i=[];try{t=this._flushAnimations(i,e)}finally{for(let n=0;n<i.length;n++)i[n]()}}else for(let i=0;i<this.collectedLeaveElements.length;i++){let n=this.collectedLeaveElements[i];this.processLeaveNode(n)}if(this.totalQueuedPlayers=0,this.collectedEnterElements.length=0,this.collectedLeaveElements.length=0,this._flushFns.forEach(i=>i()),this._flushFns=[],this._whenQuietFns.length){let i=this._whenQuietFns;this._whenQuietFns=[],t.length?V(t).onDone(()=>{i.forEach(n=>n())}):i.forEach(n=>n())}}reportError(e){throw Di(e)}_flushAnimations(e,t){let i=new me,n=[],r=new Map,a=[],o=new Map,l=new Map,c=new Map,h=new Set;this.disabledNodes.forEach(d=>{h.add(d);let f=this.driver.query(d,qn,!0);for(let p=0;p<f.length;p++)h.add(f[p])});let u=this.bodyNode,_=Array.from(this.statesByElement.keys()),y=$i(_,this.collectedEnterElements),m=new Map,g=0;y.forEach((d,f)=>{let p=st+g++;m.set(f,p),d.forEach(E=>L(E,p))});let T=[],b=new Set,w=new Set;for(let d=0;d<this.collectedLeaveElements.length;d++){let f=this.collectedLeaveElements[d],p=f[B];p&&p.setForRemoval&&(T.push(f),b.add(f),p.hasAnimation?this.driver.query(f,Vn,!0).forEach(E=>b.add(E)):w.add(f))}let M=new Map,N=$i(_,Array.from(b));N.forEach((d,f)=>{let p=Pe+g++;M.set(f,p),d.forEach(E=>L(E,p))}),e.push(()=>{y.forEach((d,f)=>{let p=m.get(f);d.forEach(E=>ae(E,p))}),N.forEach((d,f)=>{let p=M.get(f);d.forEach(E=>ae(E,p))}),T.forEach(d=>{this.processLeaveNode(d)})});let ie=[],q=[];for(let d=this._namespaceList.length-1;d>=0;d--)this._namespaceList[d].drainQueuedTransitions(t).forEach(p=>{let E=p.player,P=p.element;if(ie.push(E),this.collectedEnterElements.length){let C=P[B];if(C&&C.setForMove){if(C.previousTriggersValues&&C.previousTriggersValues.has(p.triggerName)){let Y=C.previousTriggersValues.get(p.triggerName),F=this.statesByElement.get(p.element);if(F&&F.has(p.triggerName)){let ge=F.get(p.triggerName);ge.value=Y,F.set(p.triggerName,ge)}}E.destroy();return}}let Q=!u||!this.driver.containsElement(u,P),I=M.get(P),$=m.get(P),A=this._buildInstruction(p,i,$,I,Q);if(A.errors&&A.errors.length){q.push(A);return}if(Q){E.onStart(()=>G(P,A.fromStyles)),E.onDestroy(()=>j(P,A.toStyles)),n.push(E);return}if(p.isFallbackTransition){E.onStart(()=>G(P,A.fromStyles)),E.onDestroy(()=>j(P,A.toStyles)),n.push(E);return}let Ct=[];A.timelines.forEach(C=>{C.stretchStartingKeyframe=!0,this.disabledNodes.has(C.element)||Ct.push(C)}),A.timelines=Ct,i.append(P,A.timelines);let on={instruction:A,player:E,element:P};a.push(on),A.queriedElements.forEach(C=>k(o,C,[]).push(E)),A.preStyleProps.forEach((C,Y)=>{if(C.size){let F=l.get(Y);F||l.set(Y,F=new Set),C.forEach((ge,$e)=>F.add($e))}}),A.postStyleProps.forEach((C,Y)=>{let F=c.get(Y);F||c.set(Y,F=new Set),C.forEach((ge,$e)=>F.add($e))})});if(q.length){let d=[];q.forEach(f=>{d.push(Ri(f.triggerName,f.errors))}),ie.forEach(f=>f.destroy()),this.reportError(d)}let D=new Map,R=new Map;a.forEach(d=>{let f=d.element;i.has(f)&&(R.set(f,f),this._beforeAnimationBuild(d.player.namespaceId,d.instruction,D))}),n.forEach(d=>{let f=d.element;this._getPreviousPlayers(f,!1,d.namespaceId,d.triggerName,null).forEach(E=>{k(D,f,[]).push(E),E.destroy()})});let W=T.filter(d=>Gi(d,l,c)),ne=new Map;Vi(ne,this.driver,w,c,K).forEach(d=>{Gi(d,l,c)&&W.push(d)});let H=new Map;y.forEach((d,f)=>{Vi(H,this.driver,new Set(d),l,le)}),W.forEach(d=>{let f=ne.get(d),p=H.get(d);ne.set(d,new Map([...f?.entries()??[],...p?.entries()??[]]))});let Ve=[],Pt=[],Nt={};a.forEach(d=>{let{element:f,player:p,instruction:E}=d;if(i.has(f)){if(h.has(f)){p.onDestroy(()=>j(f,E.toStyles)),p.disabled=!0,p.overrideTotalTime(E.totalTime),n.push(p);return}let P=Nt;if(R.size>1){let I=f,$=[];for(;I=I.parentNode;){let A=R.get(I);if(A){P=A;break}$.push(I)}$.forEach(A=>R.set(A,P))}let Q=this._buildAnimation(p.namespaceId,E,D,r,H,ne);if(p.setRealPlayer(Q),P===Nt)Ve.push(p);else{let I=this.playersByElement.get(P);I&&I.length&&(p.parentPlayer=V(I)),n.push(p)}}else G(f,E.fromStyles),p.onDestroy(()=>j(f,E.toStyles)),Pt.push(p),h.has(f)&&n.push(p)}),Pt.forEach(d=>{let f=r.get(d.element);if(f&&f.length){let p=V(f);d.setRealPlayer(p)}}),n.forEach(d=>{d.parentPlayer?d.syncPlayerEvents(d.parentPlayer):d.destroy()});for(let d=0;d<T.length;d++){let f=T[d],p=f[B];if(ae(f,Pe),p&&p.hasAnimation)continue;let E=[];if(o.size){let Q=o.get(f);Q&&Q.length&&E.push(...Q);let I=this.driver.query(f,Ne,!0);for(let $=0;$<I.length;$++){let A=o.get(I[$]);A&&A.length&&E.push(...A)}}let P=E.filter(Q=>!Q.destroyed);P.length?Xn(this,f,P):this.processLeaveNode(f)}return T.length=0,Ve.forEach(d=>{this.players.push(d),d.onDone(()=>{d.destroy();let f=this.players.indexOf(d);this.players.splice(f,1)}),d.play()}),Ve}afterFlush(e){this._flushFns.push(e)}afterFlushAnimationsDone(e){this._whenQuietFns.push(e)}_getPreviousPlayers(e,t,i,n,r){let a=[];if(t){let o=this.playersByQueriedElement.get(e);o&&(a=o)}else{let o=this.playersByElement.get(e);if(o){let l=!r||r==de;o.forEach(c=>{c.queued||!l&&c.triggerName!=n||a.push(c)})}}return(i||n)&&(a=a.filter(o=>!(i&&i!=o.namespaceId||n&&n!=o.triggerName))),a}_beforeAnimationBuild(e,t,i){let n=t.triggerName,r=t.element,a=t.isRemovalTransition?void 0:e,o=t.isRemovalTransition?void 0:n;for(let l of t.timelines){let c=l.element,h=c!==r,u=k(i,c,[]);this._getPreviousPlayers(c,h,a,o,t.toState).forEach(y=>{let m=y.getRealPlayer();m.beforeDestroy&&m.beforeDestroy(),y.destroy(),u.push(y)})}G(r,t.fromStyles)}_buildAnimation(e,t,i,n,r,a){let o=t.triggerName,l=t.element,c=[],h=new Set,u=new Set,_=t.timelines.map(m=>{let g=m.element;h.add(g);let T=g[B];if(T&&T.removedBeforeQueried)return new X(m.duration,m.delay);let b=g!==l,w=xn((i.get(g)||$n).map(D=>D.getRealPlayer())).filter(D=>{let R=D;return R.element?R.element===g:!1}),M=r.get(g),N=a.get(g),ie=Je(this._normalizer,m.keyframes,M,N),q=this._buildPlayer(m,ie,w);if(m.subTimeline&&n&&u.add(g),b){let D=new pe(e,o,g);D.setRealPlayer(q),c.push(D)}return q});c.forEach(m=>{k(this.playersByQueriedElement,m.element,[]).push(m),m.onDone(()=>Wn(this.playersByQueriedElement,m.element,m))}),h.forEach(m=>L(m,rt));let y=V(_);return y.onDestroy(()=>{h.forEach(m=>ae(m,rt)),j(l,t.toStyles)}),u.forEach(m=>{k(n,m,[]).push(y)}),y}_buildPlayer(e,t,i){return t.length>0?this.driver.animate(e.element,t,e.duration,e.delay,e.easing,i):new X(e.duration,e.delay)}},pe=class{namespaceId;triggerName;element;_player=new X;_containsRealPlayer=!1;_queuedCallbacks=new Map;destroyed=!1;parentPlayer=null;markedForDestroy=!1;disabled=!1;queued=!0;totalTime=0;constructor(e,t,i){this.namespaceId=e,this.triggerName=t,this.element=i}setRealPlayer(e){this._containsRealPlayer||(this._player=e,this._queuedCallbacks.forEach((t,i)=>{t.forEach(n=>Ae(e,i,void 0,n))}),this._queuedCallbacks.clear(),this._containsRealPlayer=!0,this.overrideTotalTime(e.totalTime),this.queued=!1)}getRealPlayer(){return this._player}overrideTotalTime(e){this.totalTime=e}syncPlayerEvents(e){let t=this._player;t.triggerCallback&&e.onStart(()=>t.triggerCallback("start")),e.onDone(()=>this.finish()),e.onDestroy(()=>this.destroy())}_queueEvent(e,t){k(this._queuedCallbacks,e,[]).push(t)}onDone(e){this.queued&&this._queueEvent("done",e),this._player.onDone(e)}onStart(e){this.queued&&this._queueEvent("start",e),this._player.onStart(e)}onDestroy(e){this.queued&&this._queueEvent("destroy",e),this._player.onDestroy(e)}init(){this._player.init()}hasStarted(){return this.queued?!1:this._player.hasStarted()}play(){!this.queued&&this._player.play()}pause(){!this.queued&&this._player.pause()}restart(){!this.queued&&this._player.restart()}finish(){this._player.finish()}destroy(){this.destroyed=!0,this._player.destroy()}reset(){!this.queued&&this._player.reset()}setPosition(e){this.queued||this._player.setPosition(e)}getPosition(){return this.queued?0:this._player.getPosition()}triggerCallback(e){let t=this._player;t.triggerCallback&&t.triggerCallback(e)}};function Wn(s,e,t){let i=s.get(e);if(i){if(i.length){let n=i.indexOf(t);i.splice(n,1)}i.length==0&&s.delete(e)}return i}function Hn(s){return s??null}function ke(s){return s&&s.nodeType===1}function Yn(s){return s=="start"||s=="done"}function Ui(s,e){let t=s.style.display;return s.style.display=e??"none",t}function Vi(s,e,t,i,n){let r=[];t.forEach(l=>r.push(Ui(l)));let a=[];i.forEach((l,c)=>{let h=new Map;l.forEach(u=>{let _=e.computeStyle(c,u,n);h.set(u,_),(!_||_.length==0)&&(c[B]=Gn,a.push(c))}),s.set(c,h)});let o=0;return t.forEach(l=>Ui(l,r[o++])),a}function $i(s,e){let t=new Map;if(s.forEach(o=>t.set(o,[])),e.length==0)return t;let i=1,n=new Set(e),r=new Map;function a(o){if(!o)return i;let l=r.get(o);if(l)return l;let c=o.parentNode;return t.has(c)?l=c:n.has(c)?l=i:l=a(c),r.set(o,l),l}return e.forEach(o=>{let l=a(o);l!==i&&t.get(l).push(o)}),t}function L(s,e){s.classList?.add(e)}function ae(s,e){s.classList?.remove(e)}function Xn(s,e,t){V(t).onDone(()=>s.processLeaveNode(e))}function xn(s){let e=[];return Ji(s,e),e}function Ji(s,e){for(let t=0;t<s.length;t++){let i=s[t];i instanceof ve?Ji(i.players,e):e.push(i)}}function Zn(s,e){let t=Object.keys(s),i=Object.keys(e);if(t.length!=i.length)return!1;for(let n=0;n<t.length;n++){let r=t[n];if(!e.hasOwnProperty(r)||s[r]!==e[r])return!1}return!0}function Gi(s,e,t){let i=t.get(s);if(!i)return!1;let n=e.get(s);return n?i.forEach(r=>n.add(r)):e.set(s,i),t.delete(s),!0}var oe=class{_driver;_normalizer;_transitionEngine;_timelineEngine;_triggerCache={};onRemovalComplete=(e,t)=>{};constructor(e,t,i){this._driver=t,this._normalizer=i,this._transitionEngine=new vt(e.body,t,i),this._timelineEngine=new St(e.body,t,i),this._transitionEngine.onRemovalComplete=(n,r)=>this.onRemovalComplete(n,r)}registerTrigger(e,t,i,n,r){let a=e+"-"+n,o=this._triggerCache[a];if(!o){let l=[],c=[],h=Yi(this._driver,r,l,c);if(l.length)throw vi(n,l);o=Kn(n,h,this._normalizer),this._triggerCache[a]=o}this._transitionEngine.registerTrigger(t,n,o)}register(e,t){this._transitionEngine.register(e,t)}destroy(e,t){this._transitionEngine.destroy(e,t)}onInsert(e,t,i,n){this._transitionEngine.insertNode(e,t,i,n)}onRemove(e,t,i){this._transitionEngine.removeNode(e,t,i)}disableAnimations(e,t){this._transitionEngine.markElementAsDisabled(e,t)}process(e,t,i,n){if(i.charAt(0)=="@"){let[r,a]=et(i),o=n;this._timelineEngine.command(r,t,a,o)}else this._transitionEngine.trigger(e,t,i,n)}listen(e,t,i,n,r){if(i.charAt(0)=="@"){let[a,o]=et(i);return this._timelineEngine.listen(a,t,o,r)}return this._transitionEngine.listen(e,t,i,n,r)}flush(e=-1){this._transitionEngine.flush(e)}get players(){return[...this._transitionEngine.players,...this._timelineEngine.players]}whenRenderingDone(){return this._transitionEngine.whenRenderingDone()}afterFlushAnimationsDone(e){this._transitionEngine.afterFlushAnimationsDone(e)}};function Jn(s,e){let t=null,i=null;return Array.isArray(e)&&e.length?(t=ht(e[0]),e.length>1&&(i=ht(e[e.length-1]))):e instanceof Map&&(t=ht(e)),t||i?new es(s,t,i):null}var es=(()=>{class s{_element;_startStyles;_endStyles;static initialStylesByElement=new WeakMap;_state=0;_initialStyles;constructor(t,i,n){this._element=t,this._startStyles=i,this._endStyles=n;let r=s.initialStylesByElement.get(t);r||s.initialStylesByElement.set(t,r=new Map),this._initialStyles=r}start(){this._state<1&&(this._startStyles&&j(this._element,this._startStyles,this._initialStyles),this._state=1)}finish(){this.start(),this._state<2&&(j(this._element,this._initialStyles),this._endStyles&&(j(this._element,this._endStyles),this._endStyles=null),this._state=1)}destroy(){this.finish(),this._state<3&&(s.initialStylesByElement.delete(this._element),this._startStyles&&(G(this._element,this._startStyles),this._endStyles=null),this._endStyles&&(G(this._element,this._endStyles),this._endStyles=null),j(this._element,this._initialStyles),this._state=3)}}return s})();function ht(s){let e=null;return s.forEach((t,i)=>{ts(i)&&(e=e||new Map,e.set(i,t))}),e}function ts(s){return s==="display"||s==="position"}var je=class{element;keyframes;options;_specialStyles;_onDoneFns=[];_onStartFns=[];_onDestroyFns=[];_duration;_delay;_initialized=!1;_finished=!1;_started=!1;_destroyed=!1;_finalKeyframe;_originalOnDoneFns=[];_originalOnStartFns=[];domPlayer=null;time=0;parentPlayer=null;currentSnapshot=new Map;constructor(e,t,i,n){this.element=e,this.keyframes=t,this.options=i,this._specialStyles=n,this._duration=i.duration,this._delay=i.delay||0,this.time=this._duration+this._delay}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(e=>e()),this._onDoneFns=[])}init(){this._buildPlayer()&&this._preparePlayerBeforeStart()}_buildPlayer(){if(this._initialized)return this.domPlayer;this._initialized=!0;let e=this.keyframes,t=this._triggerWebAnimation(this.element,e,this.options);if(!t)return this._onFinish(),null;this.domPlayer=t,this._finalKeyframe=e.length?e[e.length-1]:new Map;let i=()=>this._onFinish();return t.addEventListener("finish",i),this.onDestroy(()=>{t.removeEventListener("finish",i)}),t}_preparePlayerBeforeStart(){this._delay?this._resetDomPlayerState():this.domPlayer?.pause()}_convertKeyframesToObject(e){let t=[];return e.forEach(i=>{t.push(Object.fromEntries(i))}),t}_triggerWebAnimation(e,t,i){let n=this._convertKeyframesToObject(t);try{return e.animate(n,i)}catch(r){return null}}onStart(e){this._originalOnStartFns.push(e),this._onStartFns.push(e)}onDone(e){this._originalOnDoneFns.push(e),this._onDoneFns.push(e)}onDestroy(e){this._onDestroyFns.push(e)}play(){let e=this._buildPlayer();e&&(this.hasStarted()||(this._onStartFns.forEach(t=>t()),this._onStartFns=[],this._started=!0,this._specialStyles&&this._specialStyles.start()),e.play())}pause(){this.init(),this.domPlayer?.pause()}finish(){this.init(),this.domPlayer&&(this._specialStyles&&this._specialStyles.finish(),this._onFinish(),this.domPlayer.finish())}reset(){this._resetDomPlayerState(),this._destroyed=!1,this._finished=!1,this._started=!1,this._onStartFns=this._originalOnStartFns,this._onDoneFns=this._originalOnDoneFns}_resetDomPlayerState(){this.domPlayer?.cancel()}restart(){this.reset(),this.play()}hasStarted(){return this._started}destroy(){this._destroyed||(this._destroyed=!0,this._resetDomPlayerState(),this._onFinish(),this._specialStyles&&this._specialStyles.destroy(),this._onDestroyFns.forEach(e=>e()),this._onDestroyFns=[])}setPosition(e){this.domPlayer||this.init(),this.domPlayer&&(this.domPlayer.currentTime=e*this.time)}getPosition(){return this.domPlayer?+(this.domPlayer.currentTime??0)/this.time:this._initialized?1:0}get totalTime(){return this._delay+this._duration}beforeDestroy(){let e=new Map;this.hasStarted()&&this._finalKeyframe.forEach((i,n)=>{n!=="offset"&&e.set(n,this._finished?i:Me(this.element,n))}),this.currentSnapshot=e}triggerCallback(e){let t=e==="start"?this._onStartFns:this._onDoneFns;t.forEach(i=>i()),t.length=0}},Be=class{validateStyleProperty(e){return!0}validateAnimatableStyleProperty(e){return!0}containsElement(e,t){return tt(e,t)}getParentElement(e){return we(e)}query(e,t,i){return it(e,t,i)}computeStyle(e,t,i){return Me(e,t)}animate(e,t,i,n,r,a=[]){let o=n==0?"both":"forwards",l={duration:i,delay:n,fill:o};r&&(l.easing=r);let c=new Map,h=a.filter(y=>y instanceof je);Fi(i,n)&&h.forEach(y=>{y.currentSnapshot.forEach((m,g)=>c.set(g,m))});let u=Oi(t).map(y=>new Map(y));u=Li(e,u,c);let _=Jn(e,u);return new je(e,u,l,_)}};var Oe="@",en="@.disabled",qe=class{namespaceId;delegate;engine;_onDestroy;\u0275type=0;constructor(e,t,i,n){this.namespaceId=e,this.delegate=t,this.engine=i,this._onDestroy=n}get data(){return this.delegate.data}destroyNode(e){this.delegate.destroyNode?.(e)}destroy(){this.engine.destroy(this.namespaceId,this.delegate),this.engine.afterFlushAnimationsDone(()=>{queueMicrotask(()=>{this.delegate.destroy()})}),this._onDestroy?.()}createElement(e,t){return this.delegate.createElement(e,t)}createComment(e){return this.delegate.createComment(e)}createText(e){return this.delegate.createText(e)}appendChild(e,t){this.delegate.appendChild(e,t),this.engine.onInsert(this.namespaceId,t,e,!1)}insertBefore(e,t,i,n=!0){this.delegate.insertBefore(e,t,i),this.engine.onInsert(this.namespaceId,t,e,n)}removeChild(e,t,i,n){if(n){this.delegate.removeChild(e,t,i,n);return}this.parentNode(t)&&this.engine.onRemove(this.namespaceId,t,this.delegate)}selectRootElement(e,t){return this.delegate.selectRootElement(e,t)}parentNode(e){return this.delegate.parentNode(e)}nextSibling(e){return this.delegate.nextSibling(e)}setAttribute(e,t,i,n){this.delegate.setAttribute(e,t,i,n)}removeAttribute(e,t,i){this.delegate.removeAttribute(e,t,i)}addClass(e,t){this.delegate.addClass(e,t)}removeClass(e,t){this.delegate.removeClass(e,t)}setStyle(e,t,i,n){this.delegate.setStyle(e,t,i,n)}removeStyle(e,t,i){this.delegate.removeStyle(e,t,i)}setProperty(e,t,i){t.charAt(0)==Oe&&t==en?this.disableAnimations(e,!!i):this.delegate.setProperty(e,t,i)}setValue(e,t){this.delegate.setValue(e,t)}listen(e,t,i,n){return this.delegate.listen(e,t,i,n)}disableAnimations(e,t){this.engine.disableAnimations(e,t)}},Tt=class extends qe{factory;constructor(e,t,i,n,r){super(t,i,n,r),this.factory=e,this.namespaceId=t}setProperty(e,t,i){t.charAt(0)==Oe?t.charAt(1)=="."&&t==en?(i=i===void 0?!0:!!i,this.disableAnimations(e,i)):this.engine.process(this.namespaceId,e,t.slice(1),i):this.delegate.setProperty(e,t,i)}listen(e,t,i,n){if(t.charAt(0)==Oe){let r=is(e),a=t.slice(1),o="";return a.charAt(0)!=Oe&&([a,o]=ns(a)),this.engine.listen(this.namespaceId,r,a,o,l=>{let c=l._data||-1;this.factory.scheduleListenerCallback(c,i,l)})}return this.delegate.listen(e,t,i,n)}};function is(s){switch(s){case"body":return document.body;case"document":return document;case"window":return window;default:return s}}function ns(s){let e=s.indexOf("."),t=s.substring(0,e),i=s.slice(e+1);return[t,i]}var Qe=class{delegate;engine;_zone;_currentId=0;_microtaskId=1;_animationCallbacksBuffer=[];_rendererCache=new Map;_cdRecurDepth=0;constructor(e,t,i){this.delegate=e,this.engine=t,this._zone=i,t.onRemovalComplete=(n,r)=>{r?.removeChild(null,n)}}createRenderer(e,t){let n=this.delegate.createRenderer(e,t);if(!e||!t?.data?.animation){let c=this._rendererCache,h=c.get(n);if(!h){let u=()=>c.delete(n);h=new qe("",n,this.engine,u),c.set(n,h)}return h}let r=t.id,a=t.id+"-"+this._currentId;this._currentId++,this.engine.register(a,e);let o=c=>{Array.isArray(c)?c.forEach(o):this.engine.registerTrigger(r,a,e,c.name,c)};return t.data.animation.forEach(o),new Tt(this,a,n,this.engine)}begin(){this._cdRecurDepth++,this.delegate.begin&&this.delegate.begin()}_scheduleCountTask(){queueMicrotask(()=>{this._microtaskId++})}scheduleListenerCallback(e,t,i){if(e>=0&&e<this._microtaskId){this._zone.run(()=>t(i));return}let n=this._animationCallbacksBuffer;n.length==0&&queueMicrotask(()=>{this._zone.run(()=>{n.forEach(r=>{let[a,o]=r;a(o)}),this._animationCallbacksBuffer=[]})}),n.push([t,i])}end(){this._cdRecurDepth--,this._cdRecurDepth==0&&this._zone.runOutsideAngular(()=>{this._scheduleCountTask(),this.engine.flush(this._microtaskId)}),this.delegate.end&&this.delegate.end()}whenRenderingDone(){return this.engine.whenRenderingDone()}componentReplaced(e){this.engine.flush(),this.delegate.componentReplaced?.(e)}};var rs=(()=>{class s extends oe{constructor(t,i,n){super(t,i,n)}ngOnDestroy(){this.flush()}static \u0275fac=function(i){return new(i||s)(Ee(zt),Ee(J),Ee(ee))};static \u0275prov=Se({token:s,factory:s.\u0275fac})}return s})();function as(){return new Ie}function os(){return new Qe(z($t),z(oe),z(Kt))}var tn=[{provide:ee,useFactory:as},{provide:oe,useClass:rs},{provide:qt,useFactory:os}],Rs=[{provide:J,useClass:At},{provide:We,useValue:"NoopAnimations"},...tn],ls=[{provide:J,useFactory:()=>new Be},{provide:We,useFactory:()=>"BrowserAnimations"},...tn];function nn(){return Bt("NgEagerAnimations"),[...ls]}var te=s=>_e(null,null,function*(){let e=z(Te),t=s.params.projectName;return t?e.getSelectedProjectId()===t?!0:(e.selectProject(t),(yield Dt(e.selectedProject$.pipe(Ft(n=>n?.name===t))))?.name===t):(console.log("[PROJECT GUARD] no project id in route"),!1)});var sn=s=>_e(null,null,function*(){let e=z(ti),t=z(ii),i=s.params.threadId;if(!t.getUsername())try{yield Ge(t.fetchCurrentUser())}catch(n){console.error("[THREAD GUARD] Failed to load current user:",n)}if(!i)return console.log("[THREAD GUARD] no threadId in route"),!1;if(console.log("[THREAD GUARD] Checking thread:",i),console.log("[THREAD GUARD] Current selected thread:",e.getSelectedThreadId()),e.getSelectedThreadId()===i)return console.log("[THREAD GUARD] Thread already selected, allowing navigation"),!0;console.log("[THREAD GUARD] Selecting thread:",i),e.selectThread(i);try{let n=yield Ge(kt([e.isLoading$,e.selectedThread$]).pipe(Lt(([a,o])=>console.log(`\u{1F43C} [${a?"loading":"loaded"}]`,o?.id)),Ot(([a,o])=>!a&&!!o),It(1),Rt(([a,o])=>o?.id))),r=n===i;return r?console.log("[THREAD GUARD] Thread validated, allowing navigation"):console.error("[THREAD GUARD] Thread ID mismatch - route:",i,"loaded:",n),r}catch(n){return console.error("[THREAD GUARD] Error loading thread:",n),!1}});var rn=[{path:"",loadComponent:()=>import("./chunk-GEUVTKHG.js").then(s=>s.GlobalTaskControlComponent)},{path:"projects",loadComponent:()=>import("./chunk-NZDKKDRG.js").then(s=>s.ProjectListComponent)},{path:"oauth/callback",loadComponent:()=>import("./chunk-QXZ6AR76.js").then(s=>s.OAuthCallbackComponent)},{path:"project/new",loadComponent:()=>import("./chunk-KYPWHL43.js").then(s=>s.ProjectNewComponent)},{path:"project/:projectName",loadComponent:()=>import("./chunk-DVO44NIX.js").then(s=>s.MainAppComponent),canActivate:[te]},{path:"project/:projectName/prompts",loadComponent:()=>import("./chunk-JWEUUCFC.js").then(s=>s.PromptListComponent),canActivate:[te]},{path:"project/:projectName/schedulers",loadComponent:()=>import("./chunk-TSDYLM5L.js").then(s=>s.SchedulerListComponent),canActivate:[te]},{path:"project/:projectName/agents",loadComponent:()=>import("./chunk-D6WU5O4X.js").then(s=>s.AgentListComponent),canActivate:[te]},{path:"project/:projectName/tasks",loadComponent:()=>import("./chunk-FFMGEAGW.js").then(s=>s.TaskControlComponent),canActivate:[te]},{path:"project/:projectName/missions",redirectTo:"project/:projectName/tasks"},{path:"project/:projectName/thread/:threadId",loadComponent:()=>import("./chunk-DVO44NIX.js").then(s=>s.MainAppComponent),canActivate:[te,sn]},{path:"token-usage",loadComponent:()=>import("./chunk-HSNVFCBN.js").then(s=>s.TokenUsageComponent)},{path:"agentos",loadChildren:()=>import("./chunk-5B6P72NR.js").then(s=>s.AGENTOS_ROUTES)},{path:"**",redirectTo:""}];function cs(s){return()=>s.initializeDefaultProject()}function us(s){return()=>{console.log("[APP_INIT] OAuthService initialized")}}var an={providers:[jt(),Vt({eventCoalescing:!0}),Yt(rn),Wt(),nn(),{provide:Jt,useValue:{duration:3e3}},{provide:He,useFactory:cs,deps:[Te],multi:!0},{provide:He,useFactory:us,deps:[si],multi:!0},ei({basePath:"/api/agentos"}),{provide:Zt,useValue:{width:"80vw",maxWidth:"80vw",maxHeight:"80vh"}}]};var Ue=class s{title="client";themeService=z(ni);ngOnInit(){console.log("[APP] Application initialized with theme:",this.themeService.getCurrentTheme())}static \u0275fac=function(t){return new(t||s)};static \u0275cmp=Qt({type:s,selectors:[["app-root"]],decls:1,vars:0,template:function(t,i){t&1&&Ut(0,"router-outlet")},dependencies:[Xt,Ht],encapsulation:2})};Gt(Ue,an).catch(s=>console.error(s));
1
+ import{l as ei}from"./chunk-R5RVDZLX.js";import{a as S,b as K,e as xt,f as Ye,h as X,i as ve,j as le,k as si}from"./chunk-WC5DQJKZ.js";import{a as ti}from"./chunk-2YPR6RKN.js";import{b as ii,w as ni}from"./chunk-FJR6WCPX.js";import"./chunk-FAAHG43E.js";import{c as Ht,f as Yt,g as Xt}from"./chunk-LTFITYTW.js";import{a as Jt}from"./chunk-CND4W2V5.js";import{c as Zt}from"./chunk-HY7OYHZF.js";import"./chunk-UQNMPA5Y.js";import{b as Te}from"./chunk-G4QDBE4F.js";import"./chunk-SDLTQWY6.js";import{B as Ot,Ca as We,G as It,L as Ft,La as Bt,Mc as $t,Nc as Gt,Oa as qt,Sc as Wt,V as Lt,W as v,Wa as Qt,Z as Se,a as ye,ba as Ee,c as Mt,ca as z,d as _e,fb as He,la as zt,pa as Kt,q as Ge,r as Dt,rc as Vt,sa as jt,t as Rt,u as kt,ub as Ut}from"./chunk-RNXBUYHW.js";function ri(s){return new v(3e3,!1)}function ln(){return new v(3100,!1)}function cn(){return new v(3101,!1)}function un(s){return new v(3001,!1)}function hn(s){return new v(3003,!1)}function dn(s){return new v(3004,!1)}function oi(s,e){return new v(3005,!1)}function li(){return new v(3006,!1)}function ci(){return new v(3007,!1)}function ui(s,e){return new v(3008,!1)}function hi(s){return new v(3002,!1)}function di(s,e,t,i,n){return new v(3010,!1)}function mi(){return new v(3011,!1)}function fi(){return new v(3012,!1)}function pi(){return new v(3200,!1)}function gi(){return new v(3202,!1)}function yi(){return new v(3013,!1)}function _i(s){return new v(3014,!1)}function Si(s){return new v(3015,!1)}function Ei(s){return new v(3016,!1)}function vi(s,e){return new v(3404,!1)}function mn(s){return new v(3502,!1)}function Ti(s){return new v(3503,!1)}function Ai(){return new v(3300,!1)}function bi(s){return new v(3504,!1)}function wi(s){return new v(3301,!1)}function Pi(s,e){return new v(3302,!1)}function Ni(s){return new v(3303,!1)}function Ci(s,e){return new v(3400,!1)}function Mi(s){return new v(3401,!1)}function Di(s){return new v(3402,!1)}function Ri(s,e){return new v(3505,!1)}function V(s){switch(s.length){case 0:return new X;case 1:return s[0];default:return new ve(s)}}function Je(s,e,t=new Map,i=new Map){let n=[],r=[],a=-1,o=null;if(e.forEach(l=>{let c=l.get("offset"),h=c==a,u=h&&o||new Map;l.forEach((_,y)=>{let m=y,g=_;if(y!=="offset")switch(m=s.normalizePropertyName(m,n),g){case le:g=t.get(y);break;case K:g=i.get(y);break;default:g=s.normalizeStyleValue(y,m,g,n);break}u.set(m,g)}),h||r.push(u),o=u,a=c}),n.length)throw mn(n);return r}function Ae(s,e,t,i){switch(e){case"start":s.onStart(()=>i(t&&Xe(t,"start",s)));break;case"done":s.onDone(()=>i(t&&Xe(t,"done",s)));break;case"destroy":s.onDestroy(()=>i(t&&Xe(t,"destroy",s)));break}}function Xe(s,e,t){let i=t.totalTime,n=!!t.disabled,r=be(s.element,s.triggerName,s.fromState,s.toState,e||s.phaseName,i??s.totalTime,n),a=s._data;return a!=null&&(r._data=a),r}function be(s,e,t,i,n="",r=0,a){return{element:s,triggerName:e,fromState:t,toState:i,phaseName:n,totalTime:r,disabled:!!a}}function k(s,e,t){let i=s.get(e);return i||s.set(e,i=t),i}function et(s){let e=s.indexOf(":"),t=s.substring(1,e),i=s.slice(e+1);return[t,i]}var fn=typeof document>"u"?null:document.documentElement;function we(s){let e=s.parentNode||s.host||null;return e===fn?null:e}function pn(s){return s.substring(1,6)=="ebkit"}var x=null,ai=!1;function ki(s){x||(x=gn()||{},ai=x.style?"WebkitAppearance"in x.style:!1);let e=!0;return x.style&&!pn(s)&&(e=s in x.style,!e&&ai&&(e="Webkit"+s.charAt(0).toUpperCase()+s.slice(1)in x.style)),e}function gn(){return typeof document<"u"?document.body:null}function tt(s,e){for(;e;){if(e===s)return!0;e=we(e)}return!1}function it(s,e,t){if(t)return Array.from(s.querySelectorAll(e));let i=s.querySelector(e);return i?[i]:[]}var yn=1e3,nt="{{",_n="}}",st="ng-enter",Pe="ng-leave",ce="ng-trigger",ue=".ng-trigger",rt="ng-animating",Ne=".ng-animating";function U(s){if(typeof s=="number")return s;let e=s.match(/^(-?[\.\d]+)(m?s)/);return!e||e.length<2?0:xe(parseFloat(e[1]),e[2])}function xe(s,e){return e==="s"?s*yn:s}function he(s,e,t){return s.hasOwnProperty("duration")?s:En(s,e,t)}var Sn=/^(-?[\.\d]+)(m?s)(?:\s+(-?[\.\d]+)(m?s))?(?:\s+([-a-z]+(?:\(.+?\))?))?$/i;function En(s,e,t){let i,n=0,r="";if(typeof s=="string"){let a=s.match(Sn);if(a===null)return e.push(ri(s)),{duration:0,delay:0,easing:""};i=xe(parseFloat(a[1]),a[2]);let o=a[3];o!=null&&(n=xe(parseFloat(o),a[4]));let l=a[5];l&&(r=l)}else i=s;if(!t){let a=!1,o=e.length;i<0&&(e.push(ln()),a=!0),n<0&&(e.push(cn()),a=!0),a&&e.splice(o,0,ri(s))}return{duration:i,delay:n,easing:r}}function Oi(s){return s.length?s[0]instanceof Map?s:s.map(e=>new Map(Object.entries(e))):[]}function j(s,e,t){e.forEach((i,n)=>{let r=Ce(n);t&&!t.has(n)&&t.set(n,s.style[r]),s.style[r]=i})}function G(s,e){e.forEach((t,i)=>{let n=Ce(i);s.style[n]=""})}function se(s){return Array.isArray(s)?s.length==1?s[0]:xt(s):s}function Ii(s,e,t){let i=e.params||{},n=at(s);n.length&&n.forEach(r=>{i.hasOwnProperty(r)||t.push(un(r))})}var Ze=new RegExp(`${nt}\\s*(.+?)\\s*${_n}`,"g");function at(s){let e=[];if(typeof s=="string"){let t;for(;t=Ze.exec(s);)e.push(t[1]);Ze.lastIndex=0}return e}function re(s,e,t){let i=`${s}`,n=i.replace(Ze,(r,a)=>{let o=e[a];return o==null&&(t.push(hn(a)),o=""),o.toString()});return n==i?s:n}var vn=/-+([a-z0-9])/g;function Ce(s){return s.replace(vn,(...e)=>e[1].toUpperCase())}function Fi(s,e){return s===0||e===0}function Li(s,e,t){if(t.size&&e.length){let i=e[0],n=[];if(t.forEach((r,a)=>{i.has(a)||n.push(a),i.set(a,r)}),n.length)for(let r=1;r<e.length;r++){let a=e[r];n.forEach(o=>a.set(o,Me(s,o)))}}return e}function O(s,e,t){switch(e.type){case S.Trigger:return s.visitTrigger(e,t);case S.State:return s.visitState(e,t);case S.Transition:return s.visitTransition(e,t);case S.Sequence:return s.visitSequence(e,t);case S.Group:return s.visitGroup(e,t);case S.Animate:return s.visitAnimate(e,t);case S.Keyframes:return s.visitKeyframes(e,t);case S.Style:return s.visitStyle(e,t);case S.Reference:return s.visitReference(e,t);case S.AnimateChild:return s.visitAnimateChild(e,t);case S.AnimateRef:return s.visitAnimateRef(e,t);case S.Query:return s.visitQuery(e,t);case S.Stagger:return s.visitStagger(e,t);default:throw dn(e.type)}}function Me(s,e){return window.getComputedStyle(s)[e]}var At=(()=>{class s{validateStyleProperty(t){return ki(t)}containsElement(t,i){return tt(t,i)}getParentElement(t){return we(t)}query(t,i,n){return it(t,i,n)}computeStyle(t,i,n){return n||""}animate(t,i,n,r,a,o=[],l){return new X(n,r)}static \u0275fac=function(i){return new(i||s)};static \u0275prov=Se({token:s,factory:s.\u0275fac})}return s})(),J=class{static NOOP=new At},ee=class{};var Tn=new Set(["width","height","minWidth","minHeight","maxWidth","maxHeight","left","top","bottom","right","fontSize","outlineWidth","outlineOffset","paddingTop","paddingLeft","paddingBottom","paddingRight","marginTop","marginLeft","marginBottom","marginRight","borderRadius","borderWidth","borderTopWidth","borderLeftWidth","borderRightWidth","borderBottomWidth","textIndent","perspective"]),Ie=class extends ee{normalizePropertyName(e,t){return Ce(e)}normalizeStyleValue(e,t,i,n){let r="",a=i.toString().trim();if(Tn.has(t)&&i!==0&&i!=="0")if(typeof i=="number")r="px";else{let o=i.match(/^[+-]?[\d\.]+([a-z]*)$/);o&&o[1].length==0&&n.push(oi(e,i))}return a+r}};var Fe="*";function An(s,e){let t=[];return typeof s=="string"?s.split(/\s*,\s*/).forEach(i=>bn(i,t,e)):t.push(s),t}function bn(s,e,t){if(s[0]==":"){let l=wn(s,t);if(typeof l=="function"){e.push(l);return}s=l}let i=s.match(/^(\*|[-\w]+)\s*(<?[=-]>)\s*(\*|[-\w]+)$/);if(i==null||i.length<4)return t.push(Si(s)),e;let n=i[1],r=i[2],a=i[3];e.push(zi(n,a));let o=n==Fe&&a==Fe;r[0]=="<"&&!o&&e.push(zi(a,n))}function wn(s,e){switch(s){case":enter":return"void => *";case":leave":return"* => void";case":increment":return(t,i)=>parseFloat(i)>parseFloat(t);case":decrement":return(t,i)=>parseFloat(i)<parseFloat(t);default:return e.push(Ei(s)),"* => *"}}var De=new Set(["true","1"]),Re=new Set(["false","0"]);function zi(s,e){let t=De.has(s)||Re.has(s),i=De.has(e)||Re.has(e);return(n,r)=>{let a=s==Fe||s==n,o=e==Fe||e==r;return!a&&t&&typeof n=="boolean"&&(a=n?De.has(s):Re.has(s)),!o&&i&&typeof r=="boolean"&&(o=r?De.has(e):Re.has(e)),a&&o}}var Hi=":self",Pn=new RegExp(`s*${Hi}s*,?`,"g");function Yi(s,e,t,i){return new dt(s).build(e,t,i)}var Ki="",dt=class{_driver;constructor(e){this._driver=e}build(e,t,i){let n=new mt(t);return this._resetContextStyleTimingState(n),O(this,se(e),n)}_resetContextStyleTimingState(e){e.currentQuerySelector=Ki,e.collectedStyles=new Map,e.collectedStyles.set(Ki,new Map),e.currentTime=0}visitTrigger(e,t){let i=t.queryCount=0,n=t.depCount=0,r=[],a=[];return e.name.charAt(0)=="@"&&t.errors.push(li()),e.definitions.forEach(o=>{if(this._resetContextStyleTimingState(t),o.type==S.State){let l=o,c=l.name;c.toString().split(/\s*,\s*/).forEach(h=>{l.name=h,r.push(this.visitState(l,t))}),l.name=c}else if(o.type==S.Transition){let l=this.visitTransition(o,t);i+=l.queryCount,n+=l.depCount,a.push(l)}else t.errors.push(ci())}),{type:S.Trigger,name:e.name,states:r,transitions:a,queryCount:i,depCount:n,options:null}}visitState(e,t){let i=this.visitStyle(e.styles,t),n=e.options&&e.options.params||null;if(i.containsDynamicStyles){let r=new Set,a=n||{};i.styles.forEach(o=>{o instanceof Map&&o.forEach(l=>{at(l).forEach(c=>{a.hasOwnProperty(c)||r.add(c)})})}),r.size&&t.errors.push(ui(e.name,[...r.values()]))}return{type:S.State,name:e.name,style:i,options:n?{params:n}:null}}visitTransition(e,t){t.queryCount=0,t.depCount=0;let i=O(this,se(e.animation),t),n=An(e.expr,t.errors);return{type:S.Transition,matchers:n,animation:i,queryCount:t.queryCount,depCount:t.depCount,options:Z(e.options)}}visitSequence(e,t){return{type:S.Sequence,steps:e.steps.map(i=>O(this,i,t)),options:Z(e.options)}}visitGroup(e,t){let i=t.currentTime,n=0,r=e.steps.map(a=>{t.currentTime=i;let o=O(this,a,t);return n=Math.max(n,t.currentTime),o});return t.currentTime=n,{type:S.Group,steps:r,options:Z(e.options)}}visitAnimate(e,t){let i=Dn(e.timings,t.errors);t.currentAnimateTimings=i;let n,r=e.styles?e.styles:Ye({});if(r.type==S.Keyframes)n=this.visitKeyframes(r,t);else{let a=e.styles,o=!1;if(!a){o=!0;let c={};i.easing&&(c.easing=i.easing),a=Ye(c)}t.currentTime+=i.duration+i.delay;let l=this.visitStyle(a,t);l.isEmptyStep=o,n=l}return t.currentAnimateTimings=null,{type:S.Animate,timings:i,style:n,options:null}}visitStyle(e,t){let i=this._makeStyleAst(e,t);return this._validateStyleAst(i,t),i}_makeStyleAst(e,t){let i=[],n=Array.isArray(e.styles)?e.styles:[e.styles];for(let o of n)typeof o=="string"?o===K?i.push(o):t.errors.push(hi(o)):i.push(new Map(Object.entries(o)));let r=!1,a=null;return i.forEach(o=>{if(o instanceof Map&&(o.has("easing")&&(a=o.get("easing"),o.delete("easing")),!r)){for(let l of o.values())if(l.toString().indexOf(nt)>=0){r=!0;break}}}),{type:S.Style,styles:i,easing:a,offset:e.offset,containsDynamicStyles:r,options:null}}_validateStyleAst(e,t){let i=t.currentAnimateTimings,n=t.currentTime,r=t.currentTime;i&&r>0&&(r-=i.duration+i.delay),e.styles.forEach(a=>{typeof a!="string"&&a.forEach((o,l)=>{let c=t.collectedStyles.get(t.currentQuerySelector),h=c.get(l),u=!0;h&&(r!=n&&r>=h.startTime&&n<=h.endTime&&(t.errors.push(di(l,h.startTime,h.endTime,r,n)),u=!1),r=h.startTime),u&&c.set(l,{startTime:r,endTime:n}),t.options&&Ii(o,t.options,t.errors)})})}visitKeyframes(e,t){let i={type:S.Keyframes,styles:[],options:null};if(!t.currentAnimateTimings)return t.errors.push(mi()),i;let n=1,r=0,a=[],o=!1,l=!1,c=0,h=e.steps.map(b=>{let w=this._makeStyleAst(b,t),M=w.offset!=null?w.offset:Mn(w.styles),N=0;return M!=null&&(r++,N=w.offset=M),l=l||N<0||N>1,o=o||N<c,c=N,a.push(N),w});l&&t.errors.push(fi()),o&&t.errors.push(pi());let u=e.steps.length,_=0;r>0&&r<u?t.errors.push(gi()):r==0&&(_=n/(u-1));let y=u-1,m=t.currentTime,g=t.currentAnimateTimings,T=g.duration;return h.forEach((b,w)=>{let M=_>0?w==y?1:_*w:a[w],N=M*T;t.currentTime=m+g.delay+N,g.duration=N,this._validateStyleAst(b,t),b.offset=M,i.styles.push(b)}),i}visitReference(e,t){return{type:S.Reference,animation:O(this,se(e.animation),t),options:Z(e.options)}}visitAnimateChild(e,t){return t.depCount++,{type:S.AnimateChild,options:Z(e.options)}}visitAnimateRef(e,t){return{type:S.AnimateRef,animation:this.visitReference(e.animation,t),options:Z(e.options)}}visitQuery(e,t){let i=t.currentQuerySelector,n=e.options||{};t.queryCount++,t.currentQuery=e;let[r,a]=Nn(e.selector);t.currentQuerySelector=i.length?i+" "+r:r,k(t.collectedStyles,t.currentQuerySelector,new Map);let o=O(this,se(e.animation),t);return t.currentQuery=null,t.currentQuerySelector=i,{type:S.Query,selector:r,limit:n.limit||0,optional:!!n.optional,includeSelf:a,animation:o,originalSelector:e.selector,options:Z(e.options)}}visitStagger(e,t){t.currentQuery||t.errors.push(yi());let i=e.timings==="full"?{duration:0,delay:0,easing:"full"}:he(e.timings,t.errors,!0);return{type:S.Stagger,animation:O(this,se(e.animation),t),timings:i,options:null}}};function Nn(s){let e=!!s.split(/\s*,\s*/).find(t=>t==Hi);return e&&(s=s.replace(Pn,"")),s=s.replace(/@\*/g,ue).replace(/@\w+/g,t=>ue+"-"+t.slice(1)).replace(/:animating/g,Ne),[s,e]}function Cn(s){return s?ye({},s):null}var mt=class{errors;queryCount=0;depCount=0;currentTransition=null;currentQuery=null;currentQuerySelector=null;currentAnimateTimings=null;currentTime=0;collectedStyles=new Map;options=null;unsupportedCSSPropertiesFound=new Set;constructor(e){this.errors=e}};function Mn(s){if(typeof s=="string")return null;let e=null;if(Array.isArray(s))s.forEach(t=>{if(t instanceof Map&&t.has("offset")){let i=t;e=parseFloat(i.get("offset")),i.delete("offset")}});else if(s instanceof Map&&s.has("offset")){let t=s;e=parseFloat(t.get("offset")),t.delete("offset")}return e}function Dn(s,e){if(s.hasOwnProperty("duration"))return s;if(typeof s=="number"){let r=he(s,e).duration;return ot(r,0,"")}let t=s;if(t.split(/\s+/).some(r=>r.charAt(0)=="{"&&r.charAt(1)=="{")){let r=ot(0,0,"");return r.dynamic=!0,r.strValue=t,r}let n=he(t,e);return ot(n.duration,n.delay,n.easing)}function Z(s){return s?(s=ye({},s),s.params&&(s.params=Cn(s.params))):s={},s}function ot(s,e,t){return{duration:s,delay:e,easing:t}}function bt(s,e,t,i,n,r,a=null,o=!1){return{type:1,element:s,keyframes:e,preStyleProps:t,postStyleProps:i,duration:n,delay:r,totalTime:n+r,easing:a,subTimeline:o}}var me=class{_map=new Map;get(e){return this._map.get(e)||[]}append(e,t){let i=this._map.get(e);i||this._map.set(e,i=[]),i.push(...t)}has(e){return this._map.has(e)}clear(){this._map.clear()}},Rn=1,kn=":enter",On=new RegExp(kn,"g"),In=":leave",Fn=new RegExp(In,"g");function Xi(s,e,t,i,n,r=new Map,a=new Map,o,l,c=[]){return new ft().buildKeyframes(s,e,t,i,n,r,a,o,l,c)}var ft=class{buildKeyframes(e,t,i,n,r,a,o,l,c,h=[]){c=c||new me;let u=new pt(e,t,c,n,r,h,[]);u.options=l;let _=l.delay?U(l.delay):0;u.currentTimeline.delayNextStep(_),u.currentTimeline.setStyles([a],null,u.errors,l),O(this,i,u);let y=u.timelines.filter(m=>m.containsAnimation());if(y.length&&o.size){let m;for(let g=y.length-1;g>=0;g--){let T=y[g];if(T.element===t){m=T;break}}m&&!m.allowOnlyTimelineStyles()&&m.setStyles([o],null,u.errors,l)}return y.length?y.map(m=>m.buildKeyframes()):[bt(t,[],[],[],0,_,"",!1)]}visitTrigger(e,t){}visitState(e,t){}visitTransition(e,t){}visitAnimateChild(e,t){let i=t.subInstructions.get(t.element);if(i){let n=t.createSubContext(e.options),r=t.currentTimeline.currentTime,a=this._visitSubInstructions(i,n,n.options);r!=a&&t.transformIntoNewTimeline(a)}t.previousNode=e}visitAnimateRef(e,t){let i=t.createSubContext(e.options);i.transformIntoNewTimeline(),this._applyAnimationRefDelays([e.options,e.animation.options],t,i),this.visitReference(e.animation,i),t.transformIntoNewTimeline(i.currentTimeline.currentTime),t.previousNode=e}_applyAnimationRefDelays(e,t,i){for(let n of e){let r=n?.delay;if(r){let a=typeof r=="number"?r:U(re(r,n?.params??{},t.errors));i.delayNextStep(a)}}}_visitSubInstructions(e,t,i){let r=t.currentTimeline.currentTime,a=i.duration!=null?U(i.duration):null,o=i.delay!=null?U(i.delay):null;return a!==0&&e.forEach(l=>{let c=t.appendInstructionToTimeline(l,a,o);r=Math.max(r,c.duration+c.delay)}),r}visitReference(e,t){t.updateOptions(e.options,!0),O(this,e.animation,t),t.previousNode=e}visitSequence(e,t){let i=t.subContextCount,n=t,r=e.options;if(r&&(r.params||r.delay)&&(n=t.createSubContext(r),n.transformIntoNewTimeline(),r.delay!=null)){n.previousNode.type==S.Style&&(n.currentTimeline.snapshotCurrentStyles(),n.previousNode=Le);let a=U(r.delay);n.delayNextStep(a)}e.steps.length&&(e.steps.forEach(a=>O(this,a,n)),n.currentTimeline.applyStylesToKeyframe(),n.subContextCount>i&&n.transformIntoNewTimeline()),t.previousNode=e}visitGroup(e,t){let i=[],n=t.currentTimeline.currentTime,r=e.options&&e.options.delay?U(e.options.delay):0;e.steps.forEach(a=>{let o=t.createSubContext(e.options);r&&o.delayNextStep(r),O(this,a,o),n=Math.max(n,o.currentTimeline.currentTime),i.push(o.currentTimeline)}),i.forEach(a=>t.currentTimeline.mergeTimelineCollectedStyles(a)),t.transformIntoNewTimeline(n),t.previousNode=e}_visitTiming(e,t){if(e.dynamic){let i=e.strValue,n=t.params?re(i,t.params,t.errors):i;return he(n,t.errors)}else return{duration:e.duration,delay:e.delay,easing:e.easing}}visitAnimate(e,t){let i=t.currentAnimateTimings=this._visitTiming(e.timings,t),n=t.currentTimeline;i.delay&&(t.incrementTime(i.delay),n.snapshotCurrentStyles());let r=e.style;r.type==S.Keyframes?this.visitKeyframes(r,t):(t.incrementTime(i.duration),this.visitStyle(r,t),n.applyStylesToKeyframe()),t.currentAnimateTimings=null,t.previousNode=e}visitStyle(e,t){let i=t.currentTimeline,n=t.currentAnimateTimings;!n&&i.hasCurrentStyleProperties()&&i.forwardFrame();let r=n&&n.easing||e.easing;e.isEmptyStep?i.applyEmptyStep(r):i.setStyles(e.styles,r,t.errors,t.options),t.previousNode=e}visitKeyframes(e,t){let i=t.currentAnimateTimings,n=t.currentTimeline.duration,r=i.duration,o=t.createSubContext().currentTimeline;o.easing=i.easing,e.styles.forEach(l=>{let c=l.offset||0;o.forwardTime(c*r),o.setStyles(l.styles,l.easing,t.errors,t.options),o.applyStylesToKeyframe()}),t.currentTimeline.mergeTimelineCollectedStyles(o),t.transformIntoNewTimeline(n+r),t.previousNode=e}visitQuery(e,t){let i=t.currentTimeline.currentTime,n=e.options||{},r=n.delay?U(n.delay):0;r&&(t.previousNode.type===S.Style||i==0&&t.currentTimeline.hasCurrentStyleProperties())&&(t.currentTimeline.snapshotCurrentStyles(),t.previousNode=Le);let a=i,o=t.invokeQuery(e.selector,e.originalSelector,e.limit,e.includeSelf,!!n.optional,t.errors);t.currentQueryTotal=o.length;let l=null;o.forEach((c,h)=>{t.currentQueryIndex=h;let u=t.createSubContext(e.options,c);r&&u.delayNextStep(r),c===t.element&&(l=u.currentTimeline),O(this,e.animation,u),u.currentTimeline.applyStylesToKeyframe();let _=u.currentTimeline.currentTime;a=Math.max(a,_)}),t.currentQueryIndex=0,t.currentQueryTotal=0,t.transformIntoNewTimeline(a),l&&(t.currentTimeline.mergeTimelineCollectedStyles(l),t.currentTimeline.snapshotCurrentStyles()),t.previousNode=e}visitStagger(e,t){let i=t.parentContext,n=t.currentTimeline,r=e.timings,a=Math.abs(r.duration),o=a*(t.currentQueryTotal-1),l=a*t.currentQueryIndex;switch(r.duration<0?"reverse":r.easing){case"reverse":l=o-l;break;case"full":l=i.currentStaggerTime;break}let h=t.currentTimeline;l&&h.delayNextStep(l);let u=h.currentTime;O(this,e.animation,t),t.previousNode=e,i.currentStaggerTime=n.currentTime-u+(n.startTime-i.currentTimeline.startTime)}},Le={},pt=class s{_driver;element;subInstructions;_enterClassName;_leaveClassName;errors;timelines;parentContext=null;currentTimeline;currentAnimateTimings=null;previousNode=Le;subContextCount=0;options={};currentQueryIndex=0;currentQueryTotal=0;currentStaggerTime=0;constructor(e,t,i,n,r,a,o,l){this._driver=e,this.element=t,this.subInstructions=i,this._enterClassName=n,this._leaveClassName=r,this.errors=a,this.timelines=o,this.currentTimeline=l||new ze(this._driver,t,0),o.push(this.currentTimeline)}get params(){return this.options.params}updateOptions(e,t){if(!e)return;let i=e,n=this.options;i.duration!=null&&(n.duration=U(i.duration)),i.delay!=null&&(n.delay=U(i.delay));let r=i.params;if(r){let a=n.params;a||(a=this.options.params={}),Object.keys(r).forEach(o=>{(!t||!a.hasOwnProperty(o))&&(a[o]=re(r[o],a,this.errors))})}}_copyOptions(){let e={};if(this.options){let t=this.options.params;if(t){let i=e.params={};Object.keys(t).forEach(n=>{i[n]=t[n]})}}return e}createSubContext(e=null,t,i){let n=t||this.element,r=new s(this._driver,n,this.subInstructions,this._enterClassName,this._leaveClassName,this.errors,this.timelines,this.currentTimeline.fork(n,i||0));return r.previousNode=this.previousNode,r.currentAnimateTimings=this.currentAnimateTimings,r.options=this._copyOptions(),r.updateOptions(e),r.currentQueryIndex=this.currentQueryIndex,r.currentQueryTotal=this.currentQueryTotal,r.parentContext=this,this.subContextCount++,r}transformIntoNewTimeline(e){return this.previousNode=Le,this.currentTimeline=this.currentTimeline.fork(this.element,e),this.timelines.push(this.currentTimeline),this.currentTimeline}appendInstructionToTimeline(e,t,i){let n={duration:t??e.duration,delay:this.currentTimeline.currentTime+(i??0)+e.delay,easing:""},r=new gt(this._driver,e.element,e.keyframes,e.preStyleProps,e.postStyleProps,n,e.stretchStartingKeyframe);return this.timelines.push(r),n}incrementTime(e){this.currentTimeline.forwardTime(this.currentTimeline.duration+e)}delayNextStep(e){e>0&&this.currentTimeline.delayNextStep(e)}invokeQuery(e,t,i,n,r,a){let o=[];if(n&&o.push(this.element),e.length>0){e=e.replace(On,"."+this._enterClassName),e=e.replace(Fn,"."+this._leaveClassName);let l=i!=1,c=this._driver.query(this.element,e,l);i!==0&&(c=i<0?c.slice(c.length+i,c.length):c.slice(0,i)),o.push(...c)}return!r&&o.length==0&&a.push(_i(t)),o}},ze=class s{_driver;element;startTime;_elementTimelineStylesLookup;duration=0;easing=null;_previousKeyframe=new Map;_currentKeyframe=new Map;_keyframes=new Map;_styleSummary=new Map;_localTimelineStyles=new Map;_globalTimelineStyles;_pendingStyles=new Map;_backFill=new Map;_currentEmptyStepKeyframe=null;constructor(e,t,i,n){this._driver=e,this.element=t,this.startTime=i,this._elementTimelineStylesLookup=n,this._elementTimelineStylesLookup||(this._elementTimelineStylesLookup=new Map),this._globalTimelineStyles=this._elementTimelineStylesLookup.get(t),this._globalTimelineStyles||(this._globalTimelineStyles=this._localTimelineStyles,this._elementTimelineStylesLookup.set(t,this._localTimelineStyles)),this._loadKeyframe()}containsAnimation(){switch(this._keyframes.size){case 0:return!1;case 1:return this.hasCurrentStyleProperties();default:return!0}}hasCurrentStyleProperties(){return this._currentKeyframe.size>0}get currentTime(){return this.startTime+this.duration}delayNextStep(e){let t=this._keyframes.size===1&&this._pendingStyles.size;this.duration||t?(this.forwardTime(this.currentTime+e),t&&this.snapshotCurrentStyles()):this.startTime+=e}fork(e,t){return this.applyStylesToKeyframe(),new s(this._driver,e,t||this.currentTime,this._elementTimelineStylesLookup)}_loadKeyframe(){this._currentKeyframe&&(this._previousKeyframe=this._currentKeyframe),this._currentKeyframe=this._keyframes.get(this.duration),this._currentKeyframe||(this._currentKeyframe=new Map,this._keyframes.set(this.duration,this._currentKeyframe))}forwardFrame(){this.duration+=Rn,this._loadKeyframe()}forwardTime(e){this.applyStylesToKeyframe(),this.duration=e,this._loadKeyframe()}_updateStyle(e,t){this._localTimelineStyles.set(e,t),this._globalTimelineStyles.set(e,t),this._styleSummary.set(e,{time:this.currentTime,value:t})}allowOnlyTimelineStyles(){return this._currentEmptyStepKeyframe!==this._currentKeyframe}applyEmptyStep(e){e&&this._previousKeyframe.set("easing",e);for(let[t,i]of this._globalTimelineStyles)this._backFill.set(t,i||K),this._currentKeyframe.set(t,K);this._currentEmptyStepKeyframe=this._currentKeyframe}setStyles(e,t,i,n){t&&this._previousKeyframe.set("easing",t);let r=n&&n.params||{},a=Ln(e,this._globalTimelineStyles);for(let[o,l]of a){let c=re(l,r,i);this._pendingStyles.set(o,c),this._localTimelineStyles.has(o)||this._backFill.set(o,this._globalTimelineStyles.get(o)??K),this._updateStyle(o,c)}}applyStylesToKeyframe(){this._pendingStyles.size!=0&&(this._pendingStyles.forEach((e,t)=>{this._currentKeyframe.set(t,e)}),this._pendingStyles.clear(),this._localTimelineStyles.forEach((e,t)=>{this._currentKeyframe.has(t)||this._currentKeyframe.set(t,e)}))}snapshotCurrentStyles(){for(let[e,t]of this._localTimelineStyles)this._pendingStyles.set(e,t),this._updateStyle(e,t)}getFinalKeyframe(){return this._keyframes.get(this.duration)}get properties(){let e=[];for(let t in this._currentKeyframe)e.push(t);return e}mergeTimelineCollectedStyles(e){e._styleSummary.forEach((t,i)=>{let n=this._styleSummary.get(i);(!n||t.time>n.time)&&this._updateStyle(i,t.value)})}buildKeyframes(){this.applyStylesToKeyframe();let e=new Set,t=new Set,i=this._keyframes.size===1&&this.duration===0,n=[];this._keyframes.forEach((o,l)=>{let c=new Map([...this._backFill,...o]);c.forEach((h,u)=>{h===le?e.add(u):h===K&&t.add(u)}),i||c.set("offset",l/this.duration),n.push(c)});let r=[...e.values()],a=[...t.values()];if(i){let o=n[0],l=new Map(o);o.set("offset",0),l.set("offset",1),n=[o,l]}return bt(this.element,n,r,a,this.duration,this.startTime,this.easing,!1)}},gt=class extends ze{keyframes;preStyleProps;postStyleProps;_stretchStartingKeyframe;timings;constructor(e,t,i,n,r,a,o=!1){super(e,t,a.delay),this.keyframes=i,this.preStyleProps=n,this.postStyleProps=r,this._stretchStartingKeyframe=o,this.timings={duration:a.duration,delay:a.delay,easing:a.easing}}containsAnimation(){return this.keyframes.length>1}buildKeyframes(){let e=this.keyframes,{delay:t,duration:i,easing:n}=this.timings;if(this._stretchStartingKeyframe&&t){let r=[],a=i+t,o=t/a,l=new Map(e[0]);l.set("offset",0),r.push(l);let c=new Map(e[0]);c.set("offset",ji(o)),r.push(c);let h=e.length-1;for(let u=1;u<=h;u++){let _=new Map(e[u]),y=_.get("offset"),m=t+y*i;_.set("offset",ji(m/a)),r.push(_)}i=a,t=0,n="",e=r}return bt(this.element,e,this.preStyleProps,this.postStyleProps,i,t,n,!0)}};function ji(s,e=3){let t=Math.pow(10,e-1);return Math.round(s*t)/t}function Ln(s,e){let t=new Map,i;return s.forEach(n=>{if(n==="*"){i??=e.keys();for(let r of i)t.set(r,K)}else for(let[r,a]of n)t.set(r,a)}),t}function Bi(s,e,t,i,n,r,a,o,l,c,h,u,_){return{type:0,element:s,triggerName:e,isRemovalTransition:n,fromState:t,fromStyles:r,toState:i,toStyles:a,timelines:o,queriedElements:l,preStyleProps:c,postStyleProps:h,totalTime:u,errors:_}}var lt={},Ke=class{_triggerName;ast;_stateStyles;constructor(e,t,i){this._triggerName=e,this.ast=t,this._stateStyles=i}match(e,t,i,n){return zn(this.ast.matchers,e,t,i,n)}buildStyles(e,t,i){let n=this._stateStyles.get("*");return e!==void 0&&(n=this._stateStyles.get(e?.toString())||n),n?n.buildStyles(t,i):new Map}build(e,t,i,n,r,a,o,l,c,h){let u=[],_=this.ast.options&&this.ast.options.params||lt,y=o&&o.params||lt,m=this.buildStyles(i,y,u),g=l&&l.params||lt,T=this.buildStyles(n,g,u),b=new Set,w=new Map,M=new Map,N=n==="void",ie={params:xi(g,_),delay:this.ast.options?.delay},q=h?[]:Xi(e,t,this.ast.animation,r,a,m,T,ie,c,u),D=0;return q.forEach(R=>{D=Math.max(R.duration+R.delay,D)}),u.length?Bi(t,this._triggerName,i,n,N,m,T,[],[],w,M,D,u):(q.forEach(R=>{let W=R.element,ne=k(w,W,new Set);R.preStyleProps.forEach(H=>ne.add(H));let wt=k(M,W,new Set);R.postStyleProps.forEach(H=>wt.add(H)),W!==t&&b.add(W)}),Bi(t,this._triggerName,i,n,N,m,T,q,[...b.values()],w,M,D))}};function zn(s,e,t,i,n){return s.some(r=>r(e,t,i,n))}function xi(s,e){let t=ye({},e);return Object.entries(s).forEach(([i,n])=>{n!=null&&(t[i]=n)}),t}var yt=class{styles;defaultParams;normalizer;constructor(e,t,i){this.styles=e,this.defaultParams=t,this.normalizer=i}buildStyles(e,t){let i=new Map,n=xi(e,this.defaultParams);return this.styles.styles.forEach(r=>{typeof r!="string"&&r.forEach((a,o)=>{a&&(a=re(a,n,t));let l=this.normalizer.normalizePropertyName(o,t);a=this.normalizer.normalizeStyleValue(o,l,a,t),i.set(o,a)})}),i}};function Kn(s,e,t){return new _t(s,e,t)}var _t=class{name;ast;_normalizer;transitionFactories=[];fallbackTransition;states=new Map;constructor(e,t,i){this.name=e,this.ast=t,this._normalizer=i,t.states.forEach(n=>{let r=n.options&&n.options.params||{};this.states.set(n.name,new yt(n.style,r,i))}),qi(this.states,"true","1"),qi(this.states,"false","0"),t.transitions.forEach(n=>{this.transitionFactories.push(new Ke(e,n,this.states))}),this.fallbackTransition=jn(e,this.states)}get containsQueries(){return this.ast.queryCount>0}matchTransition(e,t,i,n){return this.transitionFactories.find(a=>a.match(e,t,i,n))||null}matchStyles(e,t,i){return this.fallbackTransition.buildStyles(e,t,i)}};function jn(s,e,t){let i=[(a,o)=>!0],n={type:S.Sequence,steps:[],options:null},r={type:S.Transition,animation:n,matchers:i,options:null,queryCount:0,depCount:0};return new Ke(s,r,e)}function qi(s,e,t){s.has(e)?s.has(t)||s.set(t,s.get(e)):s.has(t)&&s.set(e,s.get(t))}var Bn=new me,St=class{bodyNode;_driver;_normalizer;_animations=new Map;_playersById=new Map;players=[];constructor(e,t,i){this.bodyNode=e,this._driver=t,this._normalizer=i}register(e,t){let i=[],n=[],r=Yi(this._driver,t,i,n);if(i.length)throw Ti(i);this._animations.set(e,r)}_buildPlayer(e,t,i){let n=e.element,r=Je(this._normalizer,e.keyframes,t,i);return this._driver.animate(n,r,e.duration,e.delay,e.easing,[],!0)}create(e,t,i={}){let n=[],r=this._animations.get(e),a,o=new Map;if(r?(a=Xi(this._driver,t,r,st,Pe,new Map,new Map,i,Bn,n),a.forEach(h=>{let u=k(o,h.element,new Map);h.postStyleProps.forEach(_=>u.set(_,null))})):(n.push(Ai()),a=[]),n.length)throw bi(n);o.forEach((h,u)=>{h.forEach((_,y)=>{h.set(y,this._driver.computeStyle(u,y,K))})});let l=a.map(h=>{let u=o.get(h.element);return this._buildPlayer(h,new Map,u)}),c=V(l);return this._playersById.set(e,c),c.onDestroy(()=>this.destroy(e)),this.players.push(c),c}destroy(e){let t=this._getPlayer(e);t.destroy(),this._playersById.delete(e);let i=this.players.indexOf(t);i>=0&&this.players.splice(i,1)}_getPlayer(e){let t=this._playersById.get(e);if(!t)throw wi(e);return t}listen(e,t,i,n){let r=be(t,"","","");return Ae(this._getPlayer(e),i,r,n),()=>{}}command(e,t,i,n){if(i=="register"){this.register(e,n[0]);return}if(i=="create"){let a=n[0]||{};this.create(e,t,a);return}let r=this._getPlayer(e);switch(i){case"play":r.play();break;case"pause":r.pause();break;case"reset":r.reset();break;case"restart":r.restart();break;case"finish":r.finish();break;case"init":r.init();break;case"setPosition":r.setPosition(parseFloat(n[0]));break;case"destroy":this.destroy(e);break}}},Qi="ng-animate-queued",qn=".ng-animate-queued",ct="ng-animate-disabled",Qn=".ng-animate-disabled",Un="ng-star-inserted",Vn=".ng-star-inserted",$n=[],Zi={namespaceId:"",setForRemoval:!1,setForMove:!1,hasAnimation:!1,removedBeforeQueried:!1},Gn={namespaceId:"",setForMove:!1,setForRemoval:!1,hasAnimation:!1,removedBeforeQueried:!0},B="__ng_removed",fe=class{namespaceId;value;options;get params(){return this.options.params}constructor(e,t=""){this.namespaceId=t;let i=e&&e.hasOwnProperty("value"),n=i?e.value:e;if(this.value=Hn(n),i){let r=e,{value:a}=r,o=Mt(r,["value"]);this.options=o}else this.options={};this.options.params||(this.options.params={})}absorbOptions(e){let t=e.params;if(t){let i=this.options.params;Object.keys(t).forEach(n=>{i[n]==null&&(i[n]=t[n])})}}},de="void",ut=new fe(de),Et=class{id;hostElement;_engine;players=[];_triggers=new Map;_queue=[];_elementListeners=new Map;_hostClassName;constructor(e,t,i){this.id=e,this.hostElement=t,this._engine=i,this._hostClassName="ng-tns-"+e,L(t,this._hostClassName)}listen(e,t,i,n){if(!this._triggers.has(t))throw Pi(i,t);if(i==null||i.length==0)throw Ni(t);if(!Yn(i))throw Ci(i,t);let r=k(this._elementListeners,e,[]),a={name:t,phase:i,callback:n};r.push(a);let o=k(this._engine.statesByElement,e,new Map);return o.has(t)||(L(e,ce),L(e,ce+"-"+t),o.set(t,ut)),()=>{this._engine.afterFlush(()=>{let l=r.indexOf(a);l>=0&&r.splice(l,1),this._triggers.has(t)||o.delete(t)})}}register(e,t){return this._triggers.has(e)?!1:(this._triggers.set(e,t),!0)}_getTrigger(e){let t=this._triggers.get(e);if(!t)throw Mi(e);return t}trigger(e,t,i,n=!0){let r=this._getTrigger(t),a=new pe(this.id,t,e),o=this._engine.statesByElement.get(e);o||(L(e,ce),L(e,ce+"-"+t),this._engine.statesByElement.set(e,o=new Map));let l=o.get(t),c=new fe(i,this.id);if(!(i&&i.hasOwnProperty("value"))&&l&&c.absorbOptions(l.options),o.set(t,c),l||(l=ut),!(c.value===de)&&l.value===c.value){if(!Zn(l.params,c.params)){let g=[],T=r.matchStyles(l.value,l.params,g),b=r.matchStyles(c.value,c.params,g);g.length?this._engine.reportError(g):this._engine.afterFlush(()=>{G(e,T),j(e,b)})}return}let _=k(this._engine.playersByElement,e,[]);_.forEach(g=>{g.namespaceId==this.id&&g.triggerName==t&&g.queued&&g.destroy()});let y=r.matchTransition(l.value,c.value,e,c.params),m=!1;if(!y){if(!n)return;y=r.fallbackTransition,m=!0}return this._engine.totalQueuedPlayers++,this._queue.push({element:e,triggerName:t,transition:y,fromState:l,toState:c,player:a,isFallbackTransition:m}),m||(L(e,Qi),a.onStart(()=>{ae(e,Qi)})),a.onDone(()=>{let g=this.players.indexOf(a);g>=0&&this.players.splice(g,1);let T=this._engine.playersByElement.get(e);if(T){let b=T.indexOf(a);b>=0&&T.splice(b,1)}}),this.players.push(a),_.push(a),a}deregister(e){this._triggers.delete(e),this._engine.statesByElement.forEach(t=>t.delete(e)),this._elementListeners.forEach((t,i)=>{this._elementListeners.set(i,t.filter(n=>n.name!=e))})}clearElementCache(e){this._engine.statesByElement.delete(e),this._elementListeners.delete(e);let t=this._engine.playersByElement.get(e);t&&(t.forEach(i=>i.destroy()),this._engine.playersByElement.delete(e))}_signalRemovalForInnerTriggers(e,t){let i=this._engine.driver.query(e,ue,!0);i.forEach(n=>{if(n[B])return;let r=this._engine.fetchNamespacesByElement(n);r.size?r.forEach(a=>a.triggerLeaveAnimation(n,t,!1,!0)):this.clearElementCache(n)}),this._engine.afterFlushAnimationsDone(()=>i.forEach(n=>this.clearElementCache(n)))}triggerLeaveAnimation(e,t,i,n){let r=this._engine.statesByElement.get(e),a=new Map;if(r){let o=[];if(r.forEach((l,c)=>{if(a.set(c,l.value),this._triggers.has(c)){let h=this.trigger(e,c,de,n);h&&o.push(h)}}),o.length)return this._engine.markElementAsRemoved(this.id,e,!0,t,a),i&&V(o).onDone(()=>this._engine.processLeaveNode(e)),!0}return!1}prepareLeaveAnimationListeners(e){let t=this._elementListeners.get(e),i=this._engine.statesByElement.get(e);if(t&&i){let n=new Set;t.forEach(r=>{let a=r.name;if(n.has(a))return;n.add(a);let l=this._triggers.get(a).fallbackTransition,c=i.get(a)||ut,h=new fe(de),u=new pe(this.id,a,e);this._engine.totalQueuedPlayers++,this._queue.push({element:e,triggerName:a,transition:l,fromState:c,toState:h,player:u,isFallbackTransition:!0})})}}removeNode(e,t){let i=this._engine;if(e.childElementCount&&this._signalRemovalForInnerTriggers(e,t),this.triggerLeaveAnimation(e,t,!0))return;let n=!1;if(i.totalAnimations){let r=i.players.length?i.playersByQueriedElement.get(e):[];if(r&&r.length)n=!0;else{let a=e;for(;a=a.parentNode;)if(i.statesByElement.get(a)){n=!0;break}}}if(this.prepareLeaveAnimationListeners(e),n)i.markElementAsRemoved(this.id,e,!1,t);else{let r=e[B];(!r||r===Zi)&&(i.afterFlush(()=>this.clearElementCache(e)),i.destroyInnerAnimations(e),i._onRemovalComplete(e,t))}}insertNode(e,t){L(e,this._hostClassName)}drainQueuedTransitions(e){let t=[];return this._queue.forEach(i=>{let n=i.player;if(n.destroyed)return;let r=i.element,a=this._elementListeners.get(r);a&&a.forEach(o=>{if(o.name==i.triggerName){let l=be(r,i.triggerName,i.fromState.value,i.toState.value);l._data=e,Ae(i.player,o.phase,l,o.callback)}}),n.markedForDestroy?this._engine.afterFlush(()=>{n.destroy()}):t.push(i)}),this._queue=[],t.sort((i,n)=>{let r=i.transition.ast.depCount,a=n.transition.ast.depCount;return r==0||a==0?r-a:this._engine.driver.containsElement(i.element,n.element)?1:-1})}destroy(e){this.players.forEach(t=>t.destroy()),this._signalRemovalForInnerTriggers(this.hostElement,e)}},vt=class{bodyNode;driver;_normalizer;players=[];newHostElements=new Map;playersByElement=new Map;playersByQueriedElement=new Map;statesByElement=new Map;disabledNodes=new Set;totalAnimations=0;totalQueuedPlayers=0;_namespaceLookup={};_namespaceList=[];_flushFns=[];_whenQuietFns=[];namespacesByHostElement=new Map;collectedEnterElements=[];collectedLeaveElements=[];onRemovalComplete=(e,t)=>{};_onRemovalComplete(e,t){this.onRemovalComplete(e,t)}constructor(e,t,i){this.bodyNode=e,this.driver=t,this._normalizer=i}get queuedPlayers(){let e=[];return this._namespaceList.forEach(t=>{t.players.forEach(i=>{i.queued&&e.push(i)})}),e}createNamespace(e,t){let i=new Et(e,t,this);return this.bodyNode&&this.driver.containsElement(this.bodyNode,t)?this._balanceNamespaceList(i,t):(this.newHostElements.set(t,i),this.collectEnterElement(t)),this._namespaceLookup[e]=i}_balanceNamespaceList(e,t){let i=this._namespaceList,n=this.namespacesByHostElement;if(i.length-1>=0){let a=!1,o=this.driver.getParentElement(t);for(;o;){let l=n.get(o);if(l){let c=i.indexOf(l);i.splice(c+1,0,e),a=!0;break}o=this.driver.getParentElement(o)}a||i.unshift(e)}else i.push(e);return n.set(t,e),e}register(e,t){let i=this._namespaceLookup[e];return i||(i=this.createNamespace(e,t)),i}registerTrigger(e,t,i){let n=this._namespaceLookup[e];n&&n.register(t,i)&&this.totalAnimations++}destroy(e,t){e&&(this.afterFlush(()=>{}),this.afterFlushAnimationsDone(()=>{let i=this._fetchNamespace(e);this.namespacesByHostElement.delete(i.hostElement);let n=this._namespaceList.indexOf(i);n>=0&&this._namespaceList.splice(n,1),i.destroy(t),delete this._namespaceLookup[e]}))}_fetchNamespace(e){return this._namespaceLookup[e]}fetchNamespacesByElement(e){let t=new Set,i=this.statesByElement.get(e);if(i){for(let n of i.values())if(n.namespaceId){let r=this._fetchNamespace(n.namespaceId);r&&t.add(r)}}return t}trigger(e,t,i,n){if(ke(t)){let r=this._fetchNamespace(e);if(r)return r.trigger(t,i,n),!0}return!1}insertNode(e,t,i,n){if(!ke(t))return;let r=t[B];if(r&&r.setForRemoval){r.setForRemoval=!1,r.setForMove=!0;let a=this.collectedLeaveElements.indexOf(t);a>=0&&this.collectedLeaveElements.splice(a,1)}if(e){let a=this._fetchNamespace(e);a&&a.insertNode(t,i)}n&&this.collectEnterElement(t)}collectEnterElement(e){this.collectedEnterElements.push(e)}markElementAsDisabled(e,t){t?this.disabledNodes.has(e)||(this.disabledNodes.add(e),L(e,ct)):this.disabledNodes.has(e)&&(this.disabledNodes.delete(e),ae(e,ct))}removeNode(e,t,i){if(ke(t)){let n=e?this._fetchNamespace(e):null;n?n.removeNode(t,i):this.markElementAsRemoved(e,t,!1,i);let r=this.namespacesByHostElement.get(t);r&&r.id!==e&&r.removeNode(t,i)}else this._onRemovalComplete(t,i)}markElementAsRemoved(e,t,i,n,r){this.collectedLeaveElements.push(t),t[B]={namespaceId:e,setForRemoval:n,hasAnimation:i,removedBeforeQueried:!1,previousTriggersValues:r}}listen(e,t,i,n,r){return ke(t)?this._fetchNamespace(e).listen(t,i,n,r):()=>{}}_buildInstruction(e,t,i,n,r){return e.transition.build(this.driver,e.element,e.fromState.value,e.toState.value,i,n,e.fromState.options,e.toState.options,t,r)}destroyInnerAnimations(e){let t=this.driver.query(e,ue,!0);t.forEach(i=>this.destroyActiveAnimationsForElement(i)),this.playersByQueriedElement.size!=0&&(t=this.driver.query(e,Ne,!0),t.forEach(i=>this.finishActiveQueriedAnimationOnElement(i)))}destroyActiveAnimationsForElement(e){let t=this.playersByElement.get(e);t&&t.forEach(i=>{i.queued?i.markedForDestroy=!0:i.destroy()})}finishActiveQueriedAnimationOnElement(e){let t=this.playersByQueriedElement.get(e);t&&t.forEach(i=>i.finish())}whenRenderingDone(){return new Promise(e=>{if(this.players.length)return V(this.players).onDone(()=>e());e()})}processLeaveNode(e){let t=e[B];if(t&&t.setForRemoval){if(e[B]=Zi,t.namespaceId){this.destroyInnerAnimations(e);let i=this._fetchNamespace(t.namespaceId);i&&i.clearElementCache(e)}this._onRemovalComplete(e,t.setForRemoval)}e.classList?.contains(ct)&&this.markElementAsDisabled(e,!1),this.driver.query(e,Qn,!0).forEach(i=>{this.markElementAsDisabled(i,!1)})}flush(e=-1){let t=[];if(this.newHostElements.size&&(this.newHostElements.forEach((i,n)=>this._balanceNamespaceList(i,n)),this.newHostElements.clear()),this.totalAnimations&&this.collectedEnterElements.length)for(let i=0;i<this.collectedEnterElements.length;i++){let n=this.collectedEnterElements[i];L(n,Un)}if(this._namespaceList.length&&(this.totalQueuedPlayers||this.collectedLeaveElements.length)){let i=[];try{t=this._flushAnimations(i,e)}finally{for(let n=0;n<i.length;n++)i[n]()}}else for(let i=0;i<this.collectedLeaveElements.length;i++){let n=this.collectedLeaveElements[i];this.processLeaveNode(n)}if(this.totalQueuedPlayers=0,this.collectedEnterElements.length=0,this.collectedLeaveElements.length=0,this._flushFns.forEach(i=>i()),this._flushFns=[],this._whenQuietFns.length){let i=this._whenQuietFns;this._whenQuietFns=[],t.length?V(t).onDone(()=>{i.forEach(n=>n())}):i.forEach(n=>n())}}reportError(e){throw Di(e)}_flushAnimations(e,t){let i=new me,n=[],r=new Map,a=[],o=new Map,l=new Map,c=new Map,h=new Set;this.disabledNodes.forEach(d=>{h.add(d);let f=this.driver.query(d,qn,!0);for(let p=0;p<f.length;p++)h.add(f[p])});let u=this.bodyNode,_=Array.from(this.statesByElement.keys()),y=$i(_,this.collectedEnterElements),m=new Map,g=0;y.forEach((d,f)=>{let p=st+g++;m.set(f,p),d.forEach(E=>L(E,p))});let T=[],b=new Set,w=new Set;for(let d=0;d<this.collectedLeaveElements.length;d++){let f=this.collectedLeaveElements[d],p=f[B];p&&p.setForRemoval&&(T.push(f),b.add(f),p.hasAnimation?this.driver.query(f,Vn,!0).forEach(E=>b.add(E)):w.add(f))}let M=new Map,N=$i(_,Array.from(b));N.forEach((d,f)=>{let p=Pe+g++;M.set(f,p),d.forEach(E=>L(E,p))}),e.push(()=>{y.forEach((d,f)=>{let p=m.get(f);d.forEach(E=>ae(E,p))}),N.forEach((d,f)=>{let p=M.get(f);d.forEach(E=>ae(E,p))}),T.forEach(d=>{this.processLeaveNode(d)})});let ie=[],q=[];for(let d=this._namespaceList.length-1;d>=0;d--)this._namespaceList[d].drainQueuedTransitions(t).forEach(p=>{let E=p.player,P=p.element;if(ie.push(E),this.collectedEnterElements.length){let C=P[B];if(C&&C.setForMove){if(C.previousTriggersValues&&C.previousTriggersValues.has(p.triggerName)){let Y=C.previousTriggersValues.get(p.triggerName),F=this.statesByElement.get(p.element);if(F&&F.has(p.triggerName)){let ge=F.get(p.triggerName);ge.value=Y,F.set(p.triggerName,ge)}}E.destroy();return}}let Q=!u||!this.driver.containsElement(u,P),I=M.get(P),$=m.get(P),A=this._buildInstruction(p,i,$,I,Q);if(A.errors&&A.errors.length){q.push(A);return}if(Q){E.onStart(()=>G(P,A.fromStyles)),E.onDestroy(()=>j(P,A.toStyles)),n.push(E);return}if(p.isFallbackTransition){E.onStart(()=>G(P,A.fromStyles)),E.onDestroy(()=>j(P,A.toStyles)),n.push(E);return}let Ct=[];A.timelines.forEach(C=>{C.stretchStartingKeyframe=!0,this.disabledNodes.has(C.element)||Ct.push(C)}),A.timelines=Ct,i.append(P,A.timelines);let on={instruction:A,player:E,element:P};a.push(on),A.queriedElements.forEach(C=>k(o,C,[]).push(E)),A.preStyleProps.forEach((C,Y)=>{if(C.size){let F=l.get(Y);F||l.set(Y,F=new Set),C.forEach((ge,$e)=>F.add($e))}}),A.postStyleProps.forEach((C,Y)=>{let F=c.get(Y);F||c.set(Y,F=new Set),C.forEach((ge,$e)=>F.add($e))})});if(q.length){let d=[];q.forEach(f=>{d.push(Ri(f.triggerName,f.errors))}),ie.forEach(f=>f.destroy()),this.reportError(d)}let D=new Map,R=new Map;a.forEach(d=>{let f=d.element;i.has(f)&&(R.set(f,f),this._beforeAnimationBuild(d.player.namespaceId,d.instruction,D))}),n.forEach(d=>{let f=d.element;this._getPreviousPlayers(f,!1,d.namespaceId,d.triggerName,null).forEach(E=>{k(D,f,[]).push(E),E.destroy()})});let W=T.filter(d=>Gi(d,l,c)),ne=new Map;Vi(ne,this.driver,w,c,K).forEach(d=>{Gi(d,l,c)&&W.push(d)});let H=new Map;y.forEach((d,f)=>{Vi(H,this.driver,new Set(d),l,le)}),W.forEach(d=>{let f=ne.get(d),p=H.get(d);ne.set(d,new Map([...f?.entries()??[],...p?.entries()??[]]))});let Ve=[],Pt=[],Nt={};a.forEach(d=>{let{element:f,player:p,instruction:E}=d;if(i.has(f)){if(h.has(f)){p.onDestroy(()=>j(f,E.toStyles)),p.disabled=!0,p.overrideTotalTime(E.totalTime),n.push(p);return}let P=Nt;if(R.size>1){let I=f,$=[];for(;I=I.parentNode;){let A=R.get(I);if(A){P=A;break}$.push(I)}$.forEach(A=>R.set(A,P))}let Q=this._buildAnimation(p.namespaceId,E,D,r,H,ne);if(p.setRealPlayer(Q),P===Nt)Ve.push(p);else{let I=this.playersByElement.get(P);I&&I.length&&(p.parentPlayer=V(I)),n.push(p)}}else G(f,E.fromStyles),p.onDestroy(()=>j(f,E.toStyles)),Pt.push(p),h.has(f)&&n.push(p)}),Pt.forEach(d=>{let f=r.get(d.element);if(f&&f.length){let p=V(f);d.setRealPlayer(p)}}),n.forEach(d=>{d.parentPlayer?d.syncPlayerEvents(d.parentPlayer):d.destroy()});for(let d=0;d<T.length;d++){let f=T[d],p=f[B];if(ae(f,Pe),p&&p.hasAnimation)continue;let E=[];if(o.size){let Q=o.get(f);Q&&Q.length&&E.push(...Q);let I=this.driver.query(f,Ne,!0);for(let $=0;$<I.length;$++){let A=o.get(I[$]);A&&A.length&&E.push(...A)}}let P=E.filter(Q=>!Q.destroyed);P.length?Xn(this,f,P):this.processLeaveNode(f)}return T.length=0,Ve.forEach(d=>{this.players.push(d),d.onDone(()=>{d.destroy();let f=this.players.indexOf(d);this.players.splice(f,1)}),d.play()}),Ve}afterFlush(e){this._flushFns.push(e)}afterFlushAnimationsDone(e){this._whenQuietFns.push(e)}_getPreviousPlayers(e,t,i,n,r){let a=[];if(t){let o=this.playersByQueriedElement.get(e);o&&(a=o)}else{let o=this.playersByElement.get(e);if(o){let l=!r||r==de;o.forEach(c=>{c.queued||!l&&c.triggerName!=n||a.push(c)})}}return(i||n)&&(a=a.filter(o=>!(i&&i!=o.namespaceId||n&&n!=o.triggerName))),a}_beforeAnimationBuild(e,t,i){let n=t.triggerName,r=t.element,a=t.isRemovalTransition?void 0:e,o=t.isRemovalTransition?void 0:n;for(let l of t.timelines){let c=l.element,h=c!==r,u=k(i,c,[]);this._getPreviousPlayers(c,h,a,o,t.toState).forEach(y=>{let m=y.getRealPlayer();m.beforeDestroy&&m.beforeDestroy(),y.destroy(),u.push(y)})}G(r,t.fromStyles)}_buildAnimation(e,t,i,n,r,a){let o=t.triggerName,l=t.element,c=[],h=new Set,u=new Set,_=t.timelines.map(m=>{let g=m.element;h.add(g);let T=g[B];if(T&&T.removedBeforeQueried)return new X(m.duration,m.delay);let b=g!==l,w=xn((i.get(g)||$n).map(D=>D.getRealPlayer())).filter(D=>{let R=D;return R.element?R.element===g:!1}),M=r.get(g),N=a.get(g),ie=Je(this._normalizer,m.keyframes,M,N),q=this._buildPlayer(m,ie,w);if(m.subTimeline&&n&&u.add(g),b){let D=new pe(e,o,g);D.setRealPlayer(q),c.push(D)}return q});c.forEach(m=>{k(this.playersByQueriedElement,m.element,[]).push(m),m.onDone(()=>Wn(this.playersByQueriedElement,m.element,m))}),h.forEach(m=>L(m,rt));let y=V(_);return y.onDestroy(()=>{h.forEach(m=>ae(m,rt)),j(l,t.toStyles)}),u.forEach(m=>{k(n,m,[]).push(y)}),y}_buildPlayer(e,t,i){return t.length>0?this.driver.animate(e.element,t,e.duration,e.delay,e.easing,i):new X(e.duration,e.delay)}},pe=class{namespaceId;triggerName;element;_player=new X;_containsRealPlayer=!1;_queuedCallbacks=new Map;destroyed=!1;parentPlayer=null;markedForDestroy=!1;disabled=!1;queued=!0;totalTime=0;constructor(e,t,i){this.namespaceId=e,this.triggerName=t,this.element=i}setRealPlayer(e){this._containsRealPlayer||(this._player=e,this._queuedCallbacks.forEach((t,i)=>{t.forEach(n=>Ae(e,i,void 0,n))}),this._queuedCallbacks.clear(),this._containsRealPlayer=!0,this.overrideTotalTime(e.totalTime),this.queued=!1)}getRealPlayer(){return this._player}overrideTotalTime(e){this.totalTime=e}syncPlayerEvents(e){let t=this._player;t.triggerCallback&&e.onStart(()=>t.triggerCallback("start")),e.onDone(()=>this.finish()),e.onDestroy(()=>this.destroy())}_queueEvent(e,t){k(this._queuedCallbacks,e,[]).push(t)}onDone(e){this.queued&&this._queueEvent("done",e),this._player.onDone(e)}onStart(e){this.queued&&this._queueEvent("start",e),this._player.onStart(e)}onDestroy(e){this.queued&&this._queueEvent("destroy",e),this._player.onDestroy(e)}init(){this._player.init()}hasStarted(){return this.queued?!1:this._player.hasStarted()}play(){!this.queued&&this._player.play()}pause(){!this.queued&&this._player.pause()}restart(){!this.queued&&this._player.restart()}finish(){this._player.finish()}destroy(){this.destroyed=!0,this._player.destroy()}reset(){!this.queued&&this._player.reset()}setPosition(e){this.queued||this._player.setPosition(e)}getPosition(){return this.queued?0:this._player.getPosition()}triggerCallback(e){let t=this._player;t.triggerCallback&&t.triggerCallback(e)}};function Wn(s,e,t){let i=s.get(e);if(i){if(i.length){let n=i.indexOf(t);i.splice(n,1)}i.length==0&&s.delete(e)}return i}function Hn(s){return s??null}function ke(s){return s&&s.nodeType===1}function Yn(s){return s=="start"||s=="done"}function Ui(s,e){let t=s.style.display;return s.style.display=e??"none",t}function Vi(s,e,t,i,n){let r=[];t.forEach(l=>r.push(Ui(l)));let a=[];i.forEach((l,c)=>{let h=new Map;l.forEach(u=>{let _=e.computeStyle(c,u,n);h.set(u,_),(!_||_.length==0)&&(c[B]=Gn,a.push(c))}),s.set(c,h)});let o=0;return t.forEach(l=>Ui(l,r[o++])),a}function $i(s,e){let t=new Map;if(s.forEach(o=>t.set(o,[])),e.length==0)return t;let i=1,n=new Set(e),r=new Map;function a(o){if(!o)return i;let l=r.get(o);if(l)return l;let c=o.parentNode;return t.has(c)?l=c:n.has(c)?l=i:l=a(c),r.set(o,l),l}return e.forEach(o=>{let l=a(o);l!==i&&t.get(l).push(o)}),t}function L(s,e){s.classList?.add(e)}function ae(s,e){s.classList?.remove(e)}function Xn(s,e,t){V(t).onDone(()=>s.processLeaveNode(e))}function xn(s){let e=[];return Ji(s,e),e}function Ji(s,e){for(let t=0;t<s.length;t++){let i=s[t];i instanceof ve?Ji(i.players,e):e.push(i)}}function Zn(s,e){let t=Object.keys(s),i=Object.keys(e);if(t.length!=i.length)return!1;for(let n=0;n<t.length;n++){let r=t[n];if(!e.hasOwnProperty(r)||s[r]!==e[r])return!1}return!0}function Gi(s,e,t){let i=t.get(s);if(!i)return!1;let n=e.get(s);return n?i.forEach(r=>n.add(r)):e.set(s,i),t.delete(s),!0}var oe=class{_driver;_normalizer;_transitionEngine;_timelineEngine;_triggerCache={};onRemovalComplete=(e,t)=>{};constructor(e,t,i){this._driver=t,this._normalizer=i,this._transitionEngine=new vt(e.body,t,i),this._timelineEngine=new St(e.body,t,i),this._transitionEngine.onRemovalComplete=(n,r)=>this.onRemovalComplete(n,r)}registerTrigger(e,t,i,n,r){let a=e+"-"+n,o=this._triggerCache[a];if(!o){let l=[],c=[],h=Yi(this._driver,r,l,c);if(l.length)throw vi(n,l);o=Kn(n,h,this._normalizer),this._triggerCache[a]=o}this._transitionEngine.registerTrigger(t,n,o)}register(e,t){this._transitionEngine.register(e,t)}destroy(e,t){this._transitionEngine.destroy(e,t)}onInsert(e,t,i,n){this._transitionEngine.insertNode(e,t,i,n)}onRemove(e,t,i){this._transitionEngine.removeNode(e,t,i)}disableAnimations(e,t){this._transitionEngine.markElementAsDisabled(e,t)}process(e,t,i,n){if(i.charAt(0)=="@"){let[r,a]=et(i),o=n;this._timelineEngine.command(r,t,a,o)}else this._transitionEngine.trigger(e,t,i,n)}listen(e,t,i,n,r){if(i.charAt(0)=="@"){let[a,o]=et(i);return this._timelineEngine.listen(a,t,o,r)}return this._transitionEngine.listen(e,t,i,n,r)}flush(e=-1){this._transitionEngine.flush(e)}get players(){return[...this._transitionEngine.players,...this._timelineEngine.players]}whenRenderingDone(){return this._transitionEngine.whenRenderingDone()}afterFlushAnimationsDone(e){this._transitionEngine.afterFlushAnimationsDone(e)}};function Jn(s,e){let t=null,i=null;return Array.isArray(e)&&e.length?(t=ht(e[0]),e.length>1&&(i=ht(e[e.length-1]))):e instanceof Map&&(t=ht(e)),t||i?new es(s,t,i):null}var es=(()=>{class s{_element;_startStyles;_endStyles;static initialStylesByElement=new WeakMap;_state=0;_initialStyles;constructor(t,i,n){this._element=t,this._startStyles=i,this._endStyles=n;let r=s.initialStylesByElement.get(t);r||s.initialStylesByElement.set(t,r=new Map),this._initialStyles=r}start(){this._state<1&&(this._startStyles&&j(this._element,this._startStyles,this._initialStyles),this._state=1)}finish(){this.start(),this._state<2&&(j(this._element,this._initialStyles),this._endStyles&&(j(this._element,this._endStyles),this._endStyles=null),this._state=1)}destroy(){this.finish(),this._state<3&&(s.initialStylesByElement.delete(this._element),this._startStyles&&(G(this._element,this._startStyles),this._endStyles=null),this._endStyles&&(G(this._element,this._endStyles),this._endStyles=null),j(this._element,this._initialStyles),this._state=3)}}return s})();function ht(s){let e=null;return s.forEach((t,i)=>{ts(i)&&(e=e||new Map,e.set(i,t))}),e}function ts(s){return s==="display"||s==="position"}var je=class{element;keyframes;options;_specialStyles;_onDoneFns=[];_onStartFns=[];_onDestroyFns=[];_duration;_delay;_initialized=!1;_finished=!1;_started=!1;_destroyed=!1;_finalKeyframe;_originalOnDoneFns=[];_originalOnStartFns=[];domPlayer=null;time=0;parentPlayer=null;currentSnapshot=new Map;constructor(e,t,i,n){this.element=e,this.keyframes=t,this.options=i,this._specialStyles=n,this._duration=i.duration,this._delay=i.delay||0,this.time=this._duration+this._delay}_onFinish(){this._finished||(this._finished=!0,this._onDoneFns.forEach(e=>e()),this._onDoneFns=[])}init(){this._buildPlayer()&&this._preparePlayerBeforeStart()}_buildPlayer(){if(this._initialized)return this.domPlayer;this._initialized=!0;let e=this.keyframes,t=this._triggerWebAnimation(this.element,e,this.options);if(!t)return this._onFinish(),null;this.domPlayer=t,this._finalKeyframe=e.length?e[e.length-1]:new Map;let i=()=>this._onFinish();return t.addEventListener("finish",i),this.onDestroy(()=>{t.removeEventListener("finish",i)}),t}_preparePlayerBeforeStart(){this._delay?this._resetDomPlayerState():this.domPlayer?.pause()}_convertKeyframesToObject(e){let t=[];return e.forEach(i=>{t.push(Object.fromEntries(i))}),t}_triggerWebAnimation(e,t,i){let n=this._convertKeyframesToObject(t);try{return e.animate(n,i)}catch(r){return null}}onStart(e){this._originalOnStartFns.push(e),this._onStartFns.push(e)}onDone(e){this._originalOnDoneFns.push(e),this._onDoneFns.push(e)}onDestroy(e){this._onDestroyFns.push(e)}play(){let e=this._buildPlayer();e&&(this.hasStarted()||(this._onStartFns.forEach(t=>t()),this._onStartFns=[],this._started=!0,this._specialStyles&&this._specialStyles.start()),e.play())}pause(){this.init(),this.domPlayer?.pause()}finish(){this.init(),this.domPlayer&&(this._specialStyles&&this._specialStyles.finish(),this._onFinish(),this.domPlayer.finish())}reset(){this._resetDomPlayerState(),this._destroyed=!1,this._finished=!1,this._started=!1,this._onStartFns=this._originalOnStartFns,this._onDoneFns=this._originalOnDoneFns}_resetDomPlayerState(){this.domPlayer?.cancel()}restart(){this.reset(),this.play()}hasStarted(){return this._started}destroy(){this._destroyed||(this._destroyed=!0,this._resetDomPlayerState(),this._onFinish(),this._specialStyles&&this._specialStyles.destroy(),this._onDestroyFns.forEach(e=>e()),this._onDestroyFns=[])}setPosition(e){this.domPlayer||this.init(),this.domPlayer&&(this.domPlayer.currentTime=e*this.time)}getPosition(){return this.domPlayer?+(this.domPlayer.currentTime??0)/this.time:this._initialized?1:0}get totalTime(){return this._delay+this._duration}beforeDestroy(){let e=new Map;this.hasStarted()&&this._finalKeyframe.forEach((i,n)=>{n!=="offset"&&e.set(n,this._finished?i:Me(this.element,n))}),this.currentSnapshot=e}triggerCallback(e){let t=e==="start"?this._onStartFns:this._onDoneFns;t.forEach(i=>i()),t.length=0}},Be=class{validateStyleProperty(e){return!0}validateAnimatableStyleProperty(e){return!0}containsElement(e,t){return tt(e,t)}getParentElement(e){return we(e)}query(e,t,i){return it(e,t,i)}computeStyle(e,t,i){return Me(e,t)}animate(e,t,i,n,r,a=[]){let o=n==0?"both":"forwards",l={duration:i,delay:n,fill:o};r&&(l.easing=r);let c=new Map,h=a.filter(y=>y instanceof je);Fi(i,n)&&h.forEach(y=>{y.currentSnapshot.forEach((m,g)=>c.set(g,m))});let u=Oi(t).map(y=>new Map(y));u=Li(e,u,c);let _=Jn(e,u);return new je(e,u,l,_)}};var Oe="@",en="@.disabled",qe=class{namespaceId;delegate;engine;_onDestroy;\u0275type=0;constructor(e,t,i,n){this.namespaceId=e,this.delegate=t,this.engine=i,this._onDestroy=n}get data(){return this.delegate.data}destroyNode(e){this.delegate.destroyNode?.(e)}destroy(){this.engine.destroy(this.namespaceId,this.delegate),this.engine.afterFlushAnimationsDone(()=>{queueMicrotask(()=>{this.delegate.destroy()})}),this._onDestroy?.()}createElement(e,t){return this.delegate.createElement(e,t)}createComment(e){return this.delegate.createComment(e)}createText(e){return this.delegate.createText(e)}appendChild(e,t){this.delegate.appendChild(e,t),this.engine.onInsert(this.namespaceId,t,e,!1)}insertBefore(e,t,i,n=!0){this.delegate.insertBefore(e,t,i),this.engine.onInsert(this.namespaceId,t,e,n)}removeChild(e,t,i,n){if(n){this.delegate.removeChild(e,t,i,n);return}this.parentNode(t)&&this.engine.onRemove(this.namespaceId,t,this.delegate)}selectRootElement(e,t){return this.delegate.selectRootElement(e,t)}parentNode(e){return this.delegate.parentNode(e)}nextSibling(e){return this.delegate.nextSibling(e)}setAttribute(e,t,i,n){this.delegate.setAttribute(e,t,i,n)}removeAttribute(e,t,i){this.delegate.removeAttribute(e,t,i)}addClass(e,t){this.delegate.addClass(e,t)}removeClass(e,t){this.delegate.removeClass(e,t)}setStyle(e,t,i,n){this.delegate.setStyle(e,t,i,n)}removeStyle(e,t,i){this.delegate.removeStyle(e,t,i)}setProperty(e,t,i){t.charAt(0)==Oe&&t==en?this.disableAnimations(e,!!i):this.delegate.setProperty(e,t,i)}setValue(e,t){this.delegate.setValue(e,t)}listen(e,t,i,n){return this.delegate.listen(e,t,i,n)}disableAnimations(e,t){this.engine.disableAnimations(e,t)}},Tt=class extends qe{factory;constructor(e,t,i,n,r){super(t,i,n,r),this.factory=e,this.namespaceId=t}setProperty(e,t,i){t.charAt(0)==Oe?t.charAt(1)=="."&&t==en?(i=i===void 0?!0:!!i,this.disableAnimations(e,i)):this.engine.process(this.namespaceId,e,t.slice(1),i):this.delegate.setProperty(e,t,i)}listen(e,t,i,n){if(t.charAt(0)==Oe){let r=is(e),a=t.slice(1),o="";return a.charAt(0)!=Oe&&([a,o]=ns(a)),this.engine.listen(this.namespaceId,r,a,o,l=>{let c=l._data||-1;this.factory.scheduleListenerCallback(c,i,l)})}return this.delegate.listen(e,t,i,n)}};function is(s){switch(s){case"body":return document.body;case"document":return document;case"window":return window;default:return s}}function ns(s){let e=s.indexOf("."),t=s.substring(0,e),i=s.slice(e+1);return[t,i]}var Qe=class{delegate;engine;_zone;_currentId=0;_microtaskId=1;_animationCallbacksBuffer=[];_rendererCache=new Map;_cdRecurDepth=0;constructor(e,t,i){this.delegate=e,this.engine=t,this._zone=i,t.onRemovalComplete=(n,r)=>{r?.removeChild(null,n)}}createRenderer(e,t){let n=this.delegate.createRenderer(e,t);if(!e||!t?.data?.animation){let c=this._rendererCache,h=c.get(n);if(!h){let u=()=>c.delete(n);h=new qe("",n,this.engine,u),c.set(n,h)}return h}let r=t.id,a=t.id+"-"+this._currentId;this._currentId++,this.engine.register(a,e);let o=c=>{Array.isArray(c)?c.forEach(o):this.engine.registerTrigger(r,a,e,c.name,c)};return t.data.animation.forEach(o),new Tt(this,a,n,this.engine)}begin(){this._cdRecurDepth++,this.delegate.begin&&this.delegate.begin()}_scheduleCountTask(){queueMicrotask(()=>{this._microtaskId++})}scheduleListenerCallback(e,t,i){if(e>=0&&e<this._microtaskId){this._zone.run(()=>t(i));return}let n=this._animationCallbacksBuffer;n.length==0&&queueMicrotask(()=>{this._zone.run(()=>{n.forEach(r=>{let[a,o]=r;a(o)}),this._animationCallbacksBuffer=[]})}),n.push([t,i])}end(){this._cdRecurDepth--,this._cdRecurDepth==0&&this._zone.runOutsideAngular(()=>{this._scheduleCountTask(),this.engine.flush(this._microtaskId)}),this.delegate.end&&this.delegate.end()}whenRenderingDone(){return this.engine.whenRenderingDone()}componentReplaced(e){this.engine.flush(),this.delegate.componentReplaced?.(e)}};var rs=(()=>{class s extends oe{constructor(t,i,n){super(t,i,n)}ngOnDestroy(){this.flush()}static \u0275fac=function(i){return new(i||s)(Ee(zt),Ee(J),Ee(ee))};static \u0275prov=Se({token:s,factory:s.\u0275fac})}return s})();function as(){return new Ie}function os(){return new Qe(z($t),z(oe),z(Kt))}var tn=[{provide:ee,useFactory:as},{provide:oe,useClass:rs},{provide:qt,useFactory:os}],Rs=[{provide:J,useClass:At},{provide:We,useValue:"NoopAnimations"},...tn],ls=[{provide:J,useFactory:()=>new Be},{provide:We,useFactory:()=>"BrowserAnimations"},...tn];function nn(){return Bt("NgEagerAnimations"),[...ls]}var te=s=>_e(null,null,function*(){let e=z(Te),t=s.params.projectName;return t?e.getSelectedProjectId()===t?!0:(e.selectProject(t),(yield Dt(e.selectedProject$.pipe(Ft(n=>n?.name===t))))?.name===t):(console.log("[PROJECT GUARD] no project id in route"),!1)});var sn=s=>_e(null,null,function*(){let e=z(ti),t=z(ii),i=s.params.threadId;if(!t.getUsername())try{yield Ge(t.fetchCurrentUser())}catch(n){console.error("[THREAD GUARD] Failed to load current user:",n)}if(!i)return console.log("[THREAD GUARD] no threadId in route"),!1;if(console.log("[THREAD GUARD] Checking thread:",i),console.log("[THREAD GUARD] Current selected thread:",e.getSelectedThreadId()),e.getSelectedThreadId()===i)return console.log("[THREAD GUARD] Thread already selected, allowing navigation"),!0;console.log("[THREAD GUARD] Selecting thread:",i),e.selectThread(i);try{let n=yield Ge(kt([e.isLoading$,e.selectedThread$]).pipe(Lt(([a,o])=>console.log(`\u{1F43C} [${a?"loading":"loaded"}]`,o?.id)),Ot(([a,o])=>!a&&!!o),It(1),Rt(([a,o])=>o?.id))),r=n===i;return r?console.log("[THREAD GUARD] Thread validated, allowing navigation"):console.error("[THREAD GUARD] Thread ID mismatch - route:",i,"loaded:",n),r}catch(n){return console.error("[THREAD GUARD] Error loading thread:",n),!1}});var rn=[{path:"",loadComponent:()=>import("./chunk-KNY6WJUH.js").then(s=>s.GlobalTaskControlComponent)},{path:"projects",loadComponent:()=>import("./chunk-OBMXZUQM.js").then(s=>s.ProjectListComponent)},{path:"oauth/callback",loadComponent:()=>import("./chunk-GYZJRAEL.js").then(s=>s.OAuthCallbackComponent)},{path:"project/new",loadComponent:()=>import("./chunk-4XDVIAH5.js").then(s=>s.ProjectNewComponent)},{path:"project/:projectName",loadComponent:()=>import("./chunk-CXN4NTRD.js").then(s=>s.MainAppComponent),canActivate:[te]},{path:"project/:projectName/prompts",loadComponent:()=>import("./chunk-RAJZGLER.js").then(s=>s.PromptListComponent),canActivate:[te]},{path:"project/:projectName/schedulers",loadComponent:()=>import("./chunk-J6NHAJP2.js").then(s=>s.SchedulerListComponent),canActivate:[te]},{path:"project/:projectName/agents",loadComponent:()=>import("./chunk-2TT2VS4Q.js").then(s=>s.AgentListComponent),canActivate:[te]},{path:"project/:projectName/tasks",loadComponent:()=>import("./chunk-SHWW6WRB.js").then(s=>s.TaskControlComponent),canActivate:[te]},{path:"project/:projectName/missions",redirectTo:"project/:projectName/tasks"},{path:"project/:projectName/thread/:threadId",loadComponent:()=>import("./chunk-CXN4NTRD.js").then(s=>s.MainAppComponent),canActivate:[te,sn]},{path:"token-usage",loadComponent:()=>import("./chunk-6DNANWSF.js").then(s=>s.TokenUsageComponent)},{path:"agentos",loadChildren:()=>import("./chunk-HCMK67ST.js").then(s=>s.AGENTOS_ROUTES)},{path:"**",redirectTo:""}];function cs(s){return()=>s.initializeDefaultProject()}function us(s){return()=>{console.log("[APP_INIT] OAuthService initialized")}}var an={providers:[jt(),Vt({eventCoalescing:!0}),Yt(rn),Wt(),nn(),{provide:Jt,useValue:{duration:3e3}},{provide:He,useFactory:cs,deps:[Te],multi:!0},{provide:He,useFactory:us,deps:[si],multi:!0},ei({basePath:"/api/agentos"}),{provide:Zt,useValue:{width:"80vw",maxWidth:"80vw",maxHeight:"80vh"}}]};var Ue=class s{title="client";themeService=z(ni);ngOnInit(){console.log("[APP] Application initialized with theme:",this.themeService.getCurrentTheme())}static \u0275fac=function(t){return new(t||s)};static \u0275cmp=Qt({type:s,selectors:[["app-root"]],decls:1,vars:0,template:function(t,i){t&1&&Ut(0,"router-outlet")},dependencies:[Xt,Ht],encapsulation:2})};Gt(Ue,an).catch(s=>console.error(s));
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@whoz-oss/coday-client",
3
- "version": "0.128.0",
3
+ "version": "0.129.0",
4
4
  "repository": "https://github.com/whoz-oss/coday",
5
5
  "type": "module",
6
6
  "dependencies": {
@@ -1 +0,0 @@
1
- import{a}from"./chunk-B2FFL2F7.js";import"./chunk-IFXDK4GQ.js";import"./chunk-GAZJZBKP.js";import"./chunk-QWMDAFBN.js";import"./chunk-AJOXSD6I.js";import"./chunk-XJUBZLY2.js";import"./chunk-3JGMGRXW.js";export{a as UserFormComponent};
@@ -1 +0,0 @@
1
- import{b as a}from"./chunk-GG2XORTA.js";import"./chunk-GAZJZBKP.js";import"./chunk-QWMDAFBN.js";import"./chunk-7A54VTP2.js";import"./chunk-ZAM3WGZM.js";import"./chunk-RQLQ22PM.js";import"./chunk-AK6F2DC7.js";import"./chunk-AJOXSD6I.js";import"./chunk-IXD43YQI.js";import"./chunk-WPC6XC7P.js";import"./chunk-XJUBZLY2.js";import"./chunk-B2QA6UZX.js";import"./chunk-3JGMGRXW.js";export{a as NamespaceListComponent};
@@ -1 +0,0 @@
1
- import{a as ae}from"./chunk-B2FFL2F7.js";import{a as ie,b as re}from"./chunk-7XSGZTN3.js";import{a as oe}from"./chunk-IFXDK4GQ.js";import{a as te,b as ne}from"./chunk-GG2XORTA.js";import{a as q}from"./chunk-QSQYSFNQ.js";import{a as J,b as Q,c as X}from"./chunk-EU3J4G2Y.js";import{a as Y}from"./chunk-7CFO7WWZ.js";import{a as Z}from"./chunk-ADWJAQMQ.js";import{a as ee}from"./chunk-VNCIHM33.js";import{a as H,b as W}from"./chunk-6LO3ANKL.js";import"./chunk-DE5MXWYR.js";import{a as z,d as L}from"./chunk-GAZJZBKP.js";import{b as T,d as F}from"./chunk-QWMDAFBN.js";import{b as N}from"./chunk-7A54VTP2.js";import"./chunk-ZAM3WGZM.js";import"./chunk-RQLQ22PM.js";import"./chunk-AK6F2DC7.js";import"./chunk-AJOXSD6I.js";import"./chunk-IXD43YQI.js";import"./chunk-WPC6XC7P.js";import"./chunk-XJUBZLY2.js";import"./chunk-B2QA6UZX.js";import{Cb as S,Db as f,Eb as M,Fb as h,Gc as w,Ka as l,Rc as k,Tb as t,Ub as C,Wa as b,ca as p,dc as O,ec as I,kb as x,lb as g,mb as u,pb as y,qb as A,rb as E,sb as a,ta as _,tb as r,ub as P,vb as c,wb as d}from"./chunk-3JGMGRXW.js";var i=()=>!0;var me=[{path:"",loadComponent:()=>import("./chunk-O3U2KGCT.js").then(e=>e.AgentosShellComponent),children:[{path:":namespaceId/cases",canActivate:[i],loadComponent:()=>import("./chunk-ONXSTLRN.js").then(e=>e.CaseShellComponent),children:[{path:"",loadComponent:()=>import("./chunk-FPNKDL3E.js").then(e=>e.CaseHomeComponent)},{path:":caseId",loadComponent:()=>import("./chunk-QU37OGFO.js").then(e=>e.CaseChatComponent)}]},{path:"",loadComponent:()=>import("./chunk-I5EEQETN.js").then(e=>e.LayoutComponent),children:[{path:"namespaces/new",canActivate:[i],loadComponent:()=>import("./chunk-NAQEVUOV.js").then(e=>e.NamespaceFormComponent)},{path:"namespaces/:namespaceId/edit",canActivate:[i],loadComponent:()=>import("./chunk-NAQEVUOV.js").then(e=>e.NamespaceFormComponent)},{path:"namespaces",canActivate:[i],loadComponent:()=>import("./chunk-3YSNMKXU.js").then(e=>e.NamespaceListComponent)},{path:":namespaceId/integrations/new",canActivate:[i],loadComponent:()=>import("./chunk-YXFL2FTT.js").then(e=>e.IntegrationFormComponent)},{path:":namespaceId/integrations/:integrationId/edit",canActivate:[i],loadComponent:()=>import("./chunk-YXFL2FTT.js").then(e=>e.IntegrationFormComponent)},{path:":namespaceId/integrations",canActivate:[i],loadComponent:()=>import("./chunk-Z26H5ES2.js").then(e=>e.NamespaceIntegrationsComponent)},{path:":namespaceId/ai-providers/new",canActivate:[i],loadComponent:()=>import("./chunk-U4662WTU.js").then(e=>e.AiProviderFormComponent)},{path:":namespaceId/ai-providers/:aiProviderId/edit",canActivate:[i],loadComponent:()=>import("./chunk-U4662WTU.js").then(e=>e.AiProviderFormComponent)},{path:":namespaceId/ai-providers",canActivate:[i],loadComponent:()=>import("./chunk-RHFQ7GO2.js").then(e=>e.NamespaceAiProvidersComponent)},{path:":namespaceId/ai-models/new",canActivate:[i],loadComponent:()=>import("./chunk-IZFHJAEI.js").then(e=>e.AiModelFormComponent)},{path:":namespaceId/ai-models/:modelId/edit",canActivate:[i],loadComponent:()=>import("./chunk-IZFHJAEI.js").then(e=>e.AiModelFormComponent)},{path:":namespaceId/ai-models",canActivate:[i],loadComponent:()=>import("./chunk-VGRGY2U3.js").then(e=>e.NamespaceAiModelsComponent)},{path:"admin/users/new",canActivate:[i],loadComponent:()=>import("./chunk-3D3KN52V.js").then(e=>e.UserFormComponent)},{path:"admin/users/:userId/edit",canActivate:[i],loadComponent:()=>import("./chunk-3D3KN52V.js").then(e=>e.UserFormComponent)},{path:"admin/users",canActivate:[i],loadComponent:()=>import("./chunk-H6Q42HHV.js").then(e=>e.UserListComponent)},{path:"me",canActivate:[i],loadComponent:()=>import("./chunk-EPA5P2I6.js").then(e=>e.UserProfileComponent)},{path:"",redirectTo:"namespaces",pathMatch:"full"}]}]}];function V(e,o){e&1&&(c(0,"p",6),t(1,"No cases yet. Start one below."),d())}function K(e,o){if(e&1&&(c(0,"div",7)(1,"span",8),t(2),d(),c(3,"span",9),t(4),d()()),e&2){let n=o.$implicit;l(2),C(n.id),l(2),C(n.status)}}function $(e,o){if(e&1&&y(0,K,5,2,"div",7,x().trackById,!0),e&2){let n=h();A(n)}}function j(e,o){e&1&&g(0,V,2,0,"p",6)(1,$,2,0),e&2&&u(o.length===0?0:1)}var D=class e{http=p(k);router=p(F);route=p(T);config=p(z);caseController=p(L);namespaceId=this.route.snapshot.params.namespaceId;cases$=this.caseController.listByParentCase(this.namespaceId);inputValue=_("");onInput(o){this.inputValue.set(o.target.value)}onKeydown(o){o.key==="Enter"&&!o.shiftKey&&(o.preventDefault(),this.submit())}submit(){this.inputValue().trim()&&this.http.post(`${this.config.basePath}/api/cases`,{namespaceId:this.namespaceId,metadata:{}}).subscribe(n=>{this.inputValue.set(""),this.router.navigate(["/agentos",this.namespaceId,"cases",n.id??""])})}trackById(o,n){return n.id??""}static \u0275fac=function(n){return new(n||e)};static \u0275cmp=b({type:e,selectors:[["agentos-case-list"]],decls:11,vars:4,consts:[[1,"case-list"],[1,"case-list__header"],[1,"case-list__items"],[1,"case-list__composer"],["placeholder","Start a new case\u2026","rows","3",1,"case-list__input",3,"input","keydown","value"],[1,"case-list__hint"],[1,"case-list__empty"],[1,"case-list__item"],[1,"case-list__item-id"],[1,"case-list__item-status"]],template:function(n,s){if(n&1&&(c(0,"div",0)(1,"header",1)(2,"h2"),t(3,"Cases"),d()(),c(4,"div",2),g(5,j,2,1),O(6,"async"),d(),c(7,"div",3)(8,"textarea",4),M("input",function(v){return s.onInput(v)})("keydown",function(v){return s.onKeydown(v)}),d(),c(9,"p",5),t(10,"Press Enter to send, Shift+Enter for new line"),d()()()),n&2){let m;l(5),u((m=I(6,2,s.cases$))?5:-1,m),l(3),S("value",s.inputValue())}},dependencies:[w],styles:[".case-list[_ngcontent-%COMP%]{display:flex;flex-direction:column;height:100%;max-width:720px;margin:0 auto;padding:2rem;gap:1.5rem}.case-list__header[_ngcontent-%COMP%] h2[_ngcontent-%COMP%]{margin:0;font-size:1.5rem;font-weight:600;color:var(--color-text, #1d1d1f);letter-spacing:-.02em}.case-list__items[_ngcontent-%COMP%]{flex:1;overflow-y:auto}.case-list__empty[_ngcontent-%COMP%]{color:var(--color-text-secondary, #6e6e73);font-size:.9rem;margin:0}.case-list__composer[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.375rem}.case-list__input[_ngcontent-%COMP%]{width:100%;resize:none;padding:.75rem 1rem;border-radius:12px;border:1px solid var(--color-border, rgba(0, 0, 0, .1));background:var(--glass-bg, rgba(255, 255, 255, .72));-webkit-backdrop-filter:var(--glass-backdrop-blur, blur(20px));backdrop-filter:var(--glass-backdrop-blur, blur(20px));color:var(--color-text, #1d1d1f);font-size:.95rem;font-family:inherit;line-height:1.5;outline:none;box-sizing:border-box;transition:border-color .15s ease}.case-list__input[_ngcontent-%COMP%]:focus{border-color:var(--color-primary, #007aff)}.case-list__input[_ngcontent-%COMP%]::placeholder{color:var(--color-text-secondary, #6e6e73)}.case-list__hint[_ngcontent-%COMP%]{margin:0;font-size:.75rem;color:var(--color-text-secondary, #6e6e73);opacity:.7}"]})};function G(e,o){if(e&1&&(a(0,"p",11),t(1," Last action: "),a(2,"strong"),t(3),r()()),e&2){let n=h();l(3),C(n.lastAction())}}var R=class e{lastAction=_(null);onSend(){this.lastAction.set("send")}onStop(){this.lastAction.set("stop")}onAttach(){this.lastAction.set("attach")}static \u0275fac=function(n){return new(n||e)};static \u0275cmp=b({type:e,selectors:[["agentos-hello"]],decls:35,vars:2,consts:[[1,"hello-agentos"],[1,"card"],[1,"badge"],[1,"principles"],[1,"demo"],[1,"demo-label"],[1,"demo-buttons"],["icon","send","variant","primary","title","Send",3,"action"],["icon","stop","variant","danger","title","Stop",3,"action"],["icon","attach_file","variant","default","title","Attach",3,"action"],["icon","mic","variant","default","title","Record",3,"action","disabled"],[1,"demo-feedback"]],template:function(n,s){n&1&&(a(0,"div",0)(1,"div",1)(2,"div",2),t(3,"AgentOS UI"),r(),a(4,"h1"),t(5,"Hello AgentOS"),r(),a(6,"p"),t(7," This component lives in "),a(8,"code"),t(9,"libs/agentos-ui"),r(),t(10," \u2014 isolated from Coday internals, ready to be published as "),a(11,"code"),t(12,"@whoz-oss/agentos-ui"),r(),t(13,". "),r(),P(14,"agentos-backend-status"),a(15,"ul",3)(16,"li"),t(17,"\u2726 No imports from Coday app"),r(),a(18,"li"),t(19,"\u2726 CSS custom properties as host contract"),r(),a(20,"li"),t(21,"\u2726 Standalone Angular components"),r(),a(22,"li"),t(23,"\u2726 Signals-first reactive state"),r()(),a(24,"div",4)(25,"p",5),t(26,"ds-icon-button from "),a(27,"code"),t(28,"@whoz-oss/design-system"),r()(),a(29,"div",6)(30,"ds-icon-button",7),f("action",function(){return s.onSend()}),r(),a(31,"ds-icon-button",8),f("action",function(){return s.onStop()}),r(),a(32,"ds-icon-button",9),f("action",function(){return s.onAttach()}),r(),a(33,"ds-icon-button",10),f("action",function(){return s.onAttach()}),r()(),g(34,G,4,1,"p",11),r()()()),n&2&&(l(33),E("disabled",!0),l(),u(s.lastAction()?34:-1))},dependencies:[N,H],styles:['@charset "UTF-8";.hello-agentos[_ngcontent-%COMP%]{display:flex;align-items:center;justify-content:center;min-height:100vh;padding:2rem}.card[_ngcontent-%COMP%]{background:var(--glass-bg, rgba(255, 255, 255, .72));border:1px solid var(--glass-border, rgba(255, 255, 255, .18));box-shadow:var(--glass-shadow, 0 8px 32px 0 rgba(31, 38, 135, .15));backdrop-filter:var(--glass-backdrop-blur, blur(20px));-webkit-backdrop-filter:var(--glass-backdrop-blur, blur(20px));border-radius:20px;padding:3rem;max-width:480px;width:100%;text-align:center}.badge[_ngcontent-%COMP%]{display:inline-block;background:var(--color-primary, #007aff);color:var(--color-text-inverse, #ffffff);font-size:.75rem;font-weight:600;letter-spacing:.08em;text-transform:uppercase;padding:.25rem .75rem;border-radius:100px;margin-bottom:1.5rem}h1[_ngcontent-%COMP%]{color:var(--color-text, #1d1d1f);font-size:2rem;font-weight:700;margin:0 0 1rem;letter-spacing:-.02em}p[_ngcontent-%COMP%]{color:var(--color-text-secondary, #6e6e73);line-height:1.6;margin:0 0 1.5rem}p[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{background:var(--color-code-bg, rgba(142, 142, 147, .12));color:var(--color-code-text, #ff375f);padding:.125rem .375rem;border-radius:6px;font-size:.875em;border:1px solid var(--color-border, rgba(0, 0, 0, .1))}.principles[_ngcontent-%COMP%]{list-style:none;margin:0 0 1.5rem;padding:0;text-align:left;display:flex;flex-direction:column;gap:.5rem}.principles[_ngcontent-%COMP%] li[_ngcontent-%COMP%]{color:var(--color-text-secondary, #6e6e73);font-size:.9rem;padding:.5rem .75rem;background:var(--color-bg-hover, rgba(0, 0, 0, .04));border-radius:8px;border:1px solid var(--color-border-light, rgba(40, 40, 40, .08))}.demo[_ngcontent-%COMP%]{border-top:1px solid var(--color-border-light, rgba(40, 40, 40, .08));padding-top:1.25rem}.demo[_ngcontent-%COMP%] .demo-label[_ngcontent-%COMP%]{color:var(--color-text-secondary, #6e6e73);font-size:.8rem;margin:0 0 .75rem}.demo[_ngcontent-%COMP%] .demo-label[_ngcontent-%COMP%] code[_ngcontent-%COMP%]{background:var(--color-code-bg, rgba(142, 142, 147, .12));color:var(--color-code-text, #ff375f);padding:.125rem .375rem;border-radius:6px;font-size:.875em;border:1px solid var(--color-border, rgba(0, 0, 0, .1))}.demo[_ngcontent-%COMP%] .demo-buttons[_ngcontent-%COMP%]{display:flex;gap:.5rem;align-items:center;justify-content:center;padding:.75rem;background:var(--color-bg-hover, rgba(0, 0, 0, .04));border-radius:12px;border:1px solid var(--color-border-light, rgba(40, 40, 40, .08))}.demo[_ngcontent-%COMP%] .demo-feedback[_ngcontent-%COMP%]{margin:.75rem 0 0;font-size:.85rem;color:var(--color-text-secondary, #6e6e73)}.demo[_ngcontent-%COMP%] .demo-feedback[_ngcontent-%COMP%] strong[_ngcontent-%COMP%]{color:var(--color-primary, #007aff)}']})};export{me as AGENTOS_ROUTES,q as AgentosShellComponent,H as BackendStatusComponent,Z as CaseChatComponent,Q as CaseDrawerComponent,Y as CaseHomeComponent,J as CaseItemComponent,D as CaseListComponent,X as CaseShellComponent,W as HeaderComponent,R as HelloAgentosComponent,ee as LayoutComponent,te as NamespaceItemComponent,ne as NamespaceListComponent,oe as UserAdminStateService,ae as UserFormComponent,ie as UserItemComponent,re as UserListComponent,i as agentosReadyGuard};
@@ -1 +0,0 @@
1
- import{a as L}from"./chunk-IFXDK4GQ.js";import{b as I,d as k}from"./chunk-QWMDAFBN.js";import{a as C}from"./chunk-AJOXSD6I.js";import{D as V,c as w,e as y,g as F,h as N,i as U,l as d,n as z,t as D,u as A}from"./chunk-XJUBZLY2.js";import{Bb as O,Db as f,Fb as c,Ka as l,Tb as o,Ub as h,Vb as P,Wa as E,ca as u,ga as _,ha as p,lb as b,ma as M,mb as v,rb as x,sb as r,ta as g,tb as t,ub as m}from"./chunk-3JGMGRXW.js";function T(i,n){i&1&&(r(0,"p",5),o(1,"Loading\u2026"),t())}function G(i,n){if(i&1&&(r(0,"span",13),o(1),t()),i&2){let e=c(2);l(),h(e.form.controls.email.value)}}function B(i,n){i&1&&m(0,"input",14)}function q(i,n){if(i&1){let e=O();r(0,"form",7),f("ngSubmit",function(){_(e);let s=c();return p(s.save())}),r(1,"div",8)(2,"h2",9),o(3,"Identity"),t(),r(4,"div",10)(5,"label",11),o(6,"Email "),r(7,"span",12),o(8,"*"),t()(),b(9,G,2,1,"span",13)(10,B,1,0,"input",14),t(),r(11,"div",10)(12,"label",15),o(13,"External ID"),t(),m(14,"input",16),t()(),r(15,"div",8)(16,"h2",9),o(17,"Profile"),t(),r(18,"div",10)(19,"label",17),o(20,"First name"),t(),m(21,"input",18),t(),r(22,"div",10)(23,"label",19),o(24,"Last name"),t(),m(25,"input",20),t(),r(26,"div",21)(27,"label",22),o(28,"Bio"),t(),m(29,"textarea",23),t()(),r(30,"div",24)(31,"button",25),o(32),t(),r(33,"button",26),f("click",function(){_(e);let s=c();return p(s.cancel())}),o(34,"Cancel"),t()()()}if(i&2){let e=c();x("formGroup",e.form),l(9),v(e.isEditMode?9:10),l(22),x("disabled",e.form.invalid||e.isSaving()),l(),P(" ",e.isSaving()?"Saving\u2026":e.isEditMode?"Save changes":"Create user"," ")}}var R=class i{route=u(I);router=u(k);destroyRef=u(M);userAdminState=u(L);userId=this.route.snapshot.params.userId;isEditMode=!!this.userId;isSaving=g(!1);isLoading=g(!1);form=new U({email:new d("",{nonNullable:!0,validators:[y.required,y.email]}),externalId:new d("",{nonNullable:!0}),firstname:new d("",{nonNullable:!0}),lastname:new d("",{nonNullable:!0}),bio:new d("",{nonNullable:!0})});ngOnInit(){if(!this.isEditMode)return;let n=this.userAdminState.users().find(e=>e.id===this.userId);if(n){this.syncForm(n),this.form.controls.email.disable();return}this.isLoading.set(!0),this.userAdminState.loadAll().pipe(C(this.destroyRef)).subscribe({next:()=>{let e=this.userAdminState.users().find(a=>a.id===this.userId);e&&(this.syncForm(e),this.form.controls.email.disable()),this.isLoading.set(!1)},error:()=>this.isLoading.set(!1)})}get title(){return this.isEditMode?"Edit user":"New user"}save(){if(this.form.invalid||this.isSaving())return;this.isSaving.set(!0);let{email:n,externalId:e,firstname:a,lastname:s,bio:S}=this.form.getRawValue();(this.isEditMode?this.userAdminState.updateUser(this.userId,{externalId:e||void 0,firstname:a||void 0,lastname:s||void 0,bio:S||void 0}):this.userAdminState.createUser({email:n||void 0,externalId:e||void 0,firstname:a||void 0,lastname:s||void 0,bio:S||void 0})).pipe(C(this.destroyRef)).subscribe({next:()=>this.navigateBack(),error:()=>this.isSaving.set(!1)})}cancel(){this.navigateBack()}navigateBack(){this.router.navigate(["/agentos/admin/users"])}syncForm(n){this.form.setValue({email:n.email??"",externalId:n.externalId??"",firstname:n.firstname??"",lastname:n.lastname??"",bio:n.bio??""})}static \u0275fac=function(e){return new(e||i)};static \u0275cmp=E({type:i,selectors:[["agentos-user-form"]],decls:10,vars:2,consts:[[1,"user-form"],[1,"user-form__header"],["type","button","title","Back to users",1,"user-form__back",3,"click"],[1,"user-form__back-icon"],[1,"user-form__title"],[1,"user-form__loading"],[1,"user-form__body",3,"formGroup"],[1,"user-form__body",3,"ngSubmit","formGroup"],[1,"user-form__section"],[1,"user-form__section-title"],[1,"user-form__field"],["for","uf-email",1,"user-form__label"],[1,"user-form__required"],[1,"user-form__value","user-form__value--readonly"],["id","uf-email","type","email","placeholder","user@example.com","formControlName","email","autocomplete","email",1,"user-form__input"],["for","uf-externalId",1,"user-form__label"],["id","uf-externalId","type","text","placeholder","External identifier","formControlName","externalId",1,"user-form__input"],["for","uf-firstname",1,"user-form__label"],["id","uf-firstname","type","text","placeholder","First name","formControlName","firstname","autocomplete","given-name",1,"user-form__input"],["for","uf-lastname",1,"user-form__label"],["id","uf-lastname","type","text","placeholder","Last name","formControlName","lastname","autocomplete","family-name",1,"user-form__input"],[1,"user-form__field","user-form__field--bio"],["for","uf-bio",1,"user-form__label"],["id","uf-bio","placeholder","A short description","formControlName","bio","rows","4",1,"user-form__input","user-form__input--textarea"],[1,"user-form__actions"],["type","submit",1,"user-form__btn","user-form__btn--primary",3,"disabled"],["type","button",1,"user-form__btn",3,"click"]],template:function(e,a){e&1&&(r(0,"div",0)(1,"header",1)(2,"button",2),f("click",function(){return a.cancel()}),r(3,"span",3),o(4,"\u2190"),t(),o(5," Users "),t(),r(6,"h1",4),o(7),t()(),b(8,T,2,0,"p",5)(9,q,35,4,"form",6),t()),e&2&&(l(7),h(a.title),l(),v(a.isLoading()?8:9))},dependencies:[V,z,w,F,N,A,D],styles:[".user-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:2rem;max-width:560px;margin:0 auto;padding:2rem 1rem}.user-form__header[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.user-form__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}.user-form__back[_ngcontent-%COMP%]:hover{text-decoration:underline}.user-form__back-icon[_ngcontent-%COMP%]{font-size:1rem;line-height:1}.user-form__title[_ngcontent-%COMP%]{margin:0;font-size:1.5rem;font-weight:600;color:var(--color-text, #1d1d1f);letter-spacing:-.02em}.user-form__loading[_ngcontent-%COMP%]{color:var(--color-text-secondary, #6e6e73);font-size:.9rem;margin:0}.user-form__body[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:2rem}.user-form__section[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1rem}.user-form__section-title[_ngcontent-%COMP%]{margin:0;font-size:.75rem;font-weight:600;text-transform:uppercase;letter-spacing:.08em;color:var(--color-text-secondary, #6e6e73);border-bottom:1px solid var(--color-border-light, rgba(0, 0, 0, .06));padding-bottom:.5rem}.user-form__field[_ngcontent-%COMP%]{display:grid;grid-template-columns:140px 1fr;align-items:baseline;gap:.75rem}.user-form__field--bio[_ngcontent-%COMP%]{align-items:start}.user-form__label[_ngcontent-%COMP%]{font-size:.875rem;font-weight:500;color:var(--color-text-secondary, #6e6e73);white-space:nowrap}.user-form__required[_ngcontent-%COMP%]{color:var(--color-error, #ff3b30)}.user-form__value[_ngcontent-%COMP%]{font-size:.9375rem;color:var(--color-text, #1d1d1f)}.user-form__value--readonly[_ngcontent-%COMP%]{color:var(--color-text-secondary, #6e6e73);font-size:.875rem}.user-form__input[_ngcontent-%COMP%]{width:100%;padding:.625rem .875rem;border-radius:8px;border:1px solid var(--color-border, rgba(0, 0, 0, .1));background:transparent;color:var(--color-text, #1d1d1f);font-size:.9375rem;font-family:inherit;outline:none;box-sizing:border-box;transition:border-color .15s ease;resize:none}.user-form__input[_ngcontent-%COMP%]:focus{border-color:var(--color-primary, #007aff)}.user-form__input[_ngcontent-%COMP%]::placeholder{color:var(--color-text-secondary, #6e6e73)}.user-form__input--textarea[_ngcontent-%COMP%]{line-height:1.5;resize:vertical}.user-form__actions[_ngcontent-%COMP%]{display:flex;gap:.75rem;padding-top:.5rem}.user-form__btn[_ngcontent-%COMP%]{padding:.6rem 1.25rem;border-radius:8px;border:1px solid var(--color-border, rgba(0, 0, 0, .1));background:transparent;color:var(--color-text, #1d1d1f);font-size:.9375rem;font-family:inherit;cursor:pointer;transition:background .15s ease,border-color .15s ease}.user-form__btn[_ngcontent-%COMP%]:hover:not(:disabled){background:var(--color-surface-hover, rgba(0, 0, 0, .04))}.user-form__btn[_ngcontent-%COMP%]:disabled{opacity:.45;cursor:not-allowed}.user-form__btn--primary[_ngcontent-%COMP%]{background:var(--color-primary, #007aff);border-color:var(--color-primary, #007aff);color:#fff}.user-form__btn--primary[_ngcontent-%COMP%]:hover:not(:disabled){background:var(--color-primary-hover, #0051d5);border-color:var(--color-primary-hover, #0051d5)}"],changeDetection:0})};export{R as a};
@@ -1 +0,0 @@
1
- import{a}from"./chunk-7CFO7WWZ.js";import"./chunk-GAZJZBKP.js";import"./chunk-QWMDAFBN.js";import"./chunk-7A54VTP2.js";import"./chunk-ZAM3WGZM.js";import"./chunk-RQLQ22PM.js";import"./chunk-AK6F2DC7.js";import"./chunk-AJOXSD6I.js";import"./chunk-IXD43YQI.js";import"./chunk-WPC6XC7P.js";import"./chunk-XJUBZLY2.js";import"./chunk-B2QA6UZX.js";import"./chunk-3JGMGRXW.js";export{a as CaseHomeComponent};
@@ -1 +0,0 @@
1
- import{Oc as k,Pc as u,Rc as j,Z as A,a as b,aa as D,b as f,ba as x,ca as O,da as G,g as _,pa as L}from"./chunk-3JGMGRXW.js";var y=class{apiKeys;username;password;accessToken;basePath;withCredentials;encoder;encodeParam;credentials;constructor({accessToken:h,apiKeys:n,basePath:a,credentials:i,encodeParam:o,encoder:t,password:e,username:c,withCredentials:l}={}){n&&(this.apiKeys=n),c!==void 0&&(this.username=c),e!==void 0&&(this.password=e),h!==void 0&&(this.accessToken=h),a!==void 0&&(this.basePath=a),l!==void 0&&(this.withCredentials=l),t&&(this.encoder=t),this.encodeParam=o??(r=>this.defaultEncodeParam(r)),this.credentials=i??{}}selectHeaderContentType(h){if(h.length===0)return;let n=h.find(a=>this.isJsonMime(a));return n===void 0?h[0]:n}selectHeaderAccept(h){if(h.length===0)return;let n=h.find(a=>this.isJsonMime(a));return n===void 0?h[0]:n}isJsonMime(h){let n=new RegExp("^(application/json|[^;/ ]+/[^;/ ]+[+]json)[ ]*(;.*)?$","i");return h!==null&&(n.test(h)||h.toLowerCase()==="application/json-patch+json")}lookupCredential(h){let n=this.credentials[h];return typeof n=="function"?n():n}addCredentialToHeaders(h,n,a,i){let o=this.lookupCredential(h);return o?a.set(n,(i??"")+o):a}addCredentialToQuery(h,n,a){let i=this.lookupCredential(h);return i?a.set(n,i):a}defaultEncodeParam(h){let n=h.dataFormat==="date-time"&&h.value instanceof Date?h.value.toISOString():h.value;return encodeURIComponent(String(n))}};var v=new D("basePath");var V=class{encodeKey(h){return encodeURIComponent(h)}encodeValue(h){return encodeURIComponent(h)}decodeKey(h){return decodeURIComponent(h)}decodeValue(h){return decodeURIComponent(h)}};var m=class{basePath="http://localhost:8124";defaultHeaders=new k;configuration;encoder;constructor(h,n){if(this.configuration=n||new y,typeof this.configuration.basePath!="string"){let a=Array.isArray(h)?h[0]:void 0;a!=null&&(h=a),typeof h!="string"&&(h=this.basePath),this.configuration.basePath=h}this.encoder=this.configuration.encoder||new V}canConsumeForm(h){return h.indexOf("multipart/form-data")!==-1}addToHttpParams(h,n,a,i=!1){return typeof n=="object"&&!(n instanceof Date)?this.addToHttpParamsRecursive(h,n,i?a:void 0,i):this.addToHttpParamsRecursive(h,n,a)}addToHttpParamsRecursive(h,n,a,i=!1){if(n==null)return h;if(typeof n=="object"){if(a!=null)return i?Object.keys(n).reduce((o,t)=>o.append(`${a}[${t}]`,n[t]),h):h.append(a,JSON.stringify(n));if(Array.isArray(n))n.forEach(o=>h=this.addToHttpParamsRecursive(h,o,a));else if(n instanceof Date)if(a!=null)h=h.append(a,n.toISOString());else throw Error("key may not be null if value is Date");else Object.keys(n).forEach(o=>{let t=a?`${a}.${o}`:o;h=this.addToHttpParamsRecursive(h,n[o],t)});return h}else if(a!=null)return h.append(a,n);throw Error("key may not be null if value is not object or array")}};var R=class C extends m{constructor(n,a,i){super(a,i);this.httpClient=n}createAiModel(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter aiModel was null or undefined when calling createAiModel.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r=["application/json"],d=this.configuration.selectHeaderContentType(r);d!==void 0&&(t=t.set("Content-Type",d));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let p="/api/ai-models",{basePath:H,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${H}${p}`,f(b({context:c,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}deleteAiModel(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteAiModel.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/ai-models/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("delete",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}getByIdAiModel(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdAiModel.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/ai-models/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}getByIdsAiModel(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsAiModel.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r=["application/json"],d=this.configuration.selectHeaderContentType(r);d!==void 0&&(t=t.set("Content-Type",d));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let p="/api/ai-models/by-ids",{basePath:H,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${H}${p}`,f(b({context:c,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}listByNamespaceIdAiModel(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter namespaceId was null or undefined when calling listByNamespaceIdAiModel.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/ai-models/by-namespaceId/${this.configuration.encodeParam({name:"namespaceId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}listByParentAiModel(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentAiModel.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/ai-models/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}updateAiModel(n,a,i="body",o=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateAiModel.");if(a==null)throw new Error("Required parameter aiModel was null or undefined when calling updateAiModel.");let e=this.defaultHeaders,c=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);c!==void 0&&(e=e.set("Accept",c));let l=t?.context??new u,r=t?.transferCache??!0,d=["application/json"],s=this.configuration.selectHeaderContentType(d);s!==void 0&&(e=e.set("Content-Type",s));let p="json";c&&(c.startsWith("text")?p="text":this.configuration.isJsonMime(c)?p="json":p="blob");let H=`/api/ai-models/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${H}`,f(b({context:l,body:a,responseType:p},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:r,reportProgress:o}))}static \u0275fac=function(a){return new(a||C)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:C,factory:C.\u0275fac,providedIn:"root"})};var E=class C extends m{constructor(n,a,i){super(a,i);this.httpClient=n}createAiProvider(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter aiProvider was null or undefined when calling createAiProvider.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r=["application/json"],d=this.configuration.selectHeaderContentType(r);d!==void 0&&(t=t.set("Content-Type",d));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let p="/api/ai-providers",{basePath:H,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${H}${p}`,f(b({context:c,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}deleteAiProvider(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteAiProvider.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/ai-providers/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("delete",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}getByIdAiProvider(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdAiProvider.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/ai-providers/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}getByIdsAiProvider(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsAiProvider.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r=["application/json"],d=this.configuration.selectHeaderContentType(r);d!==void 0&&(t=t.set("Content-Type",d));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let p="/api/ai-providers/by-ids",{basePath:H,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${H}${p}`,f(b({context:c,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}listByNamespaceIdAiProvider(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter namespaceId was null or undefined when calling listByNamespaceIdAiProvider.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/ai-providers/by-namespaceId/${this.configuration.encodeParam({name:"namespaceId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}listByParentAiProvider(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentAiProvider.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/ai-providers/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}listByUserIdAiProvider(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter userId was null or undefined when calling listByUserIdAiProvider.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/ai-providers/by-userId/${this.configuration.encodeParam({name:"userId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}updateAiProvider(n,a,i="body",o=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateAiProvider.");if(a==null)throw new Error("Required parameter aiProvider was null or undefined when calling updateAiProvider.");let e=this.defaultHeaders,c=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);c!==void 0&&(e=e.set("Accept",c));let l=t?.context??new u,r=t?.transferCache??!0,d=["application/json"],s=this.configuration.selectHeaderContentType(d);s!==void 0&&(e=e.set("Content-Type",s));let p="json";c&&(c.startsWith("text")?p="text":this.configuration.isJsonMime(c)?p="json":p="blob");let H=`/api/ai-providers/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${H}`,f(b({context:l,body:a,responseType:p},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:r,reportProgress:o}))}static \u0275fac=function(a){return new(a||C)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:C,factory:C.\u0275fac,providedIn:"root"})};var B=class C extends m{constructor(n,a,i){super(a,i);this.httpClient=n}addMessageCase(n,a,i="body",o=!1,t){if(n==null)throw new Error("Required parameter caseId was null or undefined when calling addMessageCase.");if(a==null)throw new Error("Required parameter addMessageRequest was null or undefined when calling addMessageCase.");let e=this.defaultHeaders,c=t?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);c!==void 0&&(e=e.set("Accept",c));let l=t?.context??new u,r=t?.transferCache??!0,d=["application/json"],s=this.configuration.selectHeaderContentType(d);s!==void 0&&(e=e.set("Content-Type",s));let p="json";c&&(c.startsWith("text")?p="text":this.configuration.isJsonMime(c)?p="json":p="blob");let H=`/api/cases/${this.configuration.encodeParam({name:"caseId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/messages`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("post",`${g}${H}`,f(b({context:l,body:a,responseType:p},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:r,reportProgress:o}))}createCase(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter _case was null or undefined when calling createCase.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r=["application/json"],d=this.configuration.selectHeaderContentType(r);d!==void 0&&(t=t.set("Content-Type",d));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let p="/api/cases",{basePath:H,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${H}${p}`,f(b({context:c,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}deleteCase(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteCase.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/cases/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("delete",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}getByIdCase(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdCase.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/cases/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}getByIdsCase(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsCase.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r=["application/json"],d=this.configuration.selectHeaderContentType(r);d!==void 0&&(t=t.set("Content-Type",d));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let p="/api/cases/by-ids",{basePath:H,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${H}${p}`,f(b({context:c,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}interruptCase(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter caseId was null or undefined when calling interruptCase.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/cases/${this.configuration.encodeParam({name:"caseId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/interrupt`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("post",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}killCase(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter caseId was null or undefined when calling killCase.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/cases/${this.configuration.encodeParam({name:"caseId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/kill`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("post",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}listByParentCase(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentCase.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/cases/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}updateCase(n,a,i="body",o=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateCase.");if(a==null)throw new Error("Required parameter _case was null or undefined when calling updateCase.");let e=this.defaultHeaders,c=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);c!==void 0&&(e=e.set("Accept",c));let l=t?.context??new u,r=t?.transferCache??!0,d=["application/json"],s=this.configuration.selectHeaderContentType(d);s!==void 0&&(e=e.set("Content-Type",s));let p="json";c&&(c.startsWith("text")?p="text":this.configuration.isJsonMime(c)?p="json":p="blob");let H=`/api/cases/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${H}`,f(b({context:l,body:a,responseType:p},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:r,reportProgress:o}))}static \u0275fac=function(a){return new(a||C)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:C,factory:C.\u0275fac,providedIn:"root"})};var $=class C extends m{constructor(n,a,i){super(a,i);this.httpClient=n}createIntegrationConfig(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter integrationConfig was null or undefined when calling createIntegrationConfig.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r=["application/json"],d=this.configuration.selectHeaderContentType(r);d!==void 0&&(t=t.set("Content-Type",d));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let p="/api/integration-configs",{basePath:H,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${H}${p}`,f(b({context:c,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}deleteIntegrationConfig(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteIntegrationConfig.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/integration-configs/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("delete",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}getByIdIntegrationConfig(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdIntegrationConfig.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/integration-configs/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}getByIdsIntegrationConfig(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsIntegrationConfig.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r=["application/json"],d=this.configuration.selectHeaderContentType(r);d!==void 0&&(t=t.set("Content-Type",d));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let p="/api/integration-configs/by-ids",{basePath:H,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${H}${p}`,f(b({context:c,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}listByParentIntegrationConfig(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentIntegrationConfig.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/integration-configs/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}updateIntegrationConfig(n,a,i="body",o=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateIntegrationConfig.");if(a==null)throw new Error("Required parameter integrationConfig was null or undefined when calling updateIntegrationConfig.");let e=this.defaultHeaders,c=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);c!==void 0&&(e=e.set("Accept",c));let l=t?.context??new u,r=t?.transferCache??!0,d=["application/json"],s=this.configuration.selectHeaderContentType(d);s!==void 0&&(e=e.set("Content-Type",s));let p="json";c&&(c.startsWith("text")?p="text":this.configuration.isJsonMime(c)?p="json":p="blob");let H=`/api/integration-configs/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${H}`,f(b({context:l,body:a,responseType:p},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:r,reportProgress:o}))}static \u0275fac=function(a){return new(a||C)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:C,factory:C.\u0275fac,providedIn:"root"})};var M=class C extends m{constructor(n,a,i){super(a,i);this.httpClient=n}getTypeIntegrationType(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter type was null or undefined when calling getTypeIntegrationType.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/integration-types/${this.configuration.encodeParam({name:"type",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}listTypesIntegrationType(n="body",a=!1,i){let o=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);t!==void 0&&(o=o.set("Accept",t));let e=i?.context??new u,c=i?.transferCache??!0,l="json";t&&(t.startsWith("text")?l="text":this.configuration.isJsonMime(t)?l="json":l="blob");let r="/api/integration-types",{basePath:d,withCredentials:s}=this.configuration;return this.httpClient.request("get",`${d}${r}`,f(b({context:e,responseType:l},s?{withCredentials:s}:{}),{headers:o,observe:n,transferCache:c,reportProgress:a}))}static \u0275fac=function(a){return new(a||C)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:C,factory:C.\u0275fac,providedIn:"root"})};var q=class C extends m{constructor(n,a,i){super(a,i);this.httpClient=n}createNamespace(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter namespace was null or undefined when calling createNamespace.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r=["application/json"],d=this.configuration.selectHeaderContentType(r);d!==void 0&&(t=t.set("Content-Type",d));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let p="/api/namespaces",{basePath:H,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${H}${p}`,f(b({context:c,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}deleteNamespace(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteNamespace.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/namespaces/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("delete",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}getByIdNamespace(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdNamespace.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/namespaces/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}getByIdsNamespace(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsNamespace.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r=["application/json"],d=this.configuration.selectHeaderContentType(r);d!==void 0&&(t=t.set("Content-Type",d));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let p="/api/namespaces/by-ids",{basePath:H,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${H}${p}`,f(b({context:c,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}listAllNamespace(n="body",a=!1,i){let o=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);t!==void 0&&(o=o.set("Accept",t));let e=i?.context??new u,c=i?.transferCache??!0,l="json";t&&(t.startsWith("text")?l="text":this.configuration.isJsonMime(t)?l="json":l="blob");let r="/api/namespaces",{basePath:d,withCredentials:s}=this.configuration;return this.httpClient.request("get",`${d}${r}`,f(b({context:e,responseType:l},s?{withCredentials:s}:{}),{headers:o,observe:n,transferCache:c,reportProgress:a}))}listByParentNamespace(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentNamespace.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/namespaces/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}updateNamespace(n,a,i="body",o=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateNamespace.");if(a==null)throw new Error("Required parameter namespace was null or undefined when calling updateNamespace.");let e=this.defaultHeaders,c=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);c!==void 0&&(e=e.set("Accept",c));let l=t?.context??new u,r=t?.transferCache??!0,d=["application/json"],s=this.configuration.selectHeaderContentType(d);s!==void 0&&(e=e.set("Content-Type",s));let p="json";c&&(c.startsWith("text")?p="text":this.configuration.isJsonMime(c)?p="json":p="blob");let H=`/api/namespaces/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${H}`,f(b({context:l,body:a,responseType:p},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:r,reportProgress:o}))}static \u0275fac=function(a){return new(a||C)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:C,factory:C.\u0275fac,providedIn:"root"})};var K=(a=>(a.OpenAI="OpenAI",a.Anthropic="Anthropic",a.Gemini="Gemini",a))(K||{});var S=class C extends m{constructor(n,a,i){super(a,i);this.httpClient=n}createAgentConfig(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter agentConfig was null or undefined when calling createAgentConfig.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r=["application/json"],d=this.configuration.selectHeaderContentType(r);d!==void 0&&(t=t.set("Content-Type",d));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let p="/api/agent-configs",{basePath:H,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${H}${p}`,f(b({context:c,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}deleteAgentConfig(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteAgentConfig.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/agent-configs/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("delete",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}getByIdAgentConfig(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdAgentConfig.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/agent-configs/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}getByIdsAgentConfig(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsAgentConfig.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r=["application/json"],d=this.configuration.selectHeaderContentType(r);d!==void 0&&(t=t.set("Content-Type",d));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let p="/api/agent-configs/by-ids",{basePath:H,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${H}${p}`,f(b({context:c,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}listByParentAgentConfig(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentAgentConfig.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/agent-configs/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}updateAgentConfig(n,a,i="body",o=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateAgentConfig.");if(a==null)throw new Error("Required parameter agentConfig was null or undefined when calling updateAgentConfig.");let e=this.defaultHeaders,c=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);c!==void 0&&(e=e.set("Accept",c));let l=t?.context??new u,r=t?.transferCache??!0,d=["application/json"],s=this.configuration.selectHeaderContentType(d);s!==void 0&&(e=e.set("Content-Type",s));let p="json";c&&(c.startsWith("text")?p="text":this.configuration.isJsonMime(c)?p="json":p="blob");let H=`/api/agent-configs/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${H}`,f(b({context:l,body:a,responseType:p},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:r,reportProgress:o}))}static \u0275fac=function(a){return new(a||C)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:C,factory:C.\u0275fac,providedIn:"root"})};var N=class C extends m{constructor(n,a,i){super(a,i);this.httpClient=n}getByIdCaseEventRest(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdCaseEventRest.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/case-events/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}getByIdsCaseEventRest(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsCaseEventRest.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r=["application/json"],d=this.configuration.selectHeaderContentType(r);d!==void 0&&(t=t.set("Content-Type",d));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let p="/api/case-events/by-ids",{basePath:H,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${H}${p}`,f(b({context:c,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}listByCaseCaseEventRest(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter caseId was null or undefined when calling listByCaseCaseEventRest.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/case-events/by-parentId/${this.configuration.encodeParam({name:"caseId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}static \u0275fac=function(a){return new(a||C)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:C,factory:C.\u0275fac,providedIn:"root"})};var U=class C extends m{constructor(n,a,i){super(a,i);this.httpClient=n}debugAllPlugins(n="body",a=!1,i){let o=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);t!==void 0&&(o=o.set("Accept",t));let e=i?.context??new u,c=i?.transferCache??!0,l="json";t&&(t.startsWith("text")?l="text":this.configuration.isJsonMime(t)?l="json":l="blob");let r="/api/plugins/debug",{basePath:d,withCredentials:s}=this.configuration;return this.httpClient.request("get",`${d}${r}`,f(b({context:e,responseType:l},s?{withCredentials:s}:{}),{headers:o,observe:n,transferCache:c,reportProgress:a}))}debugPlugin(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter pluginId was null or undefined when calling debugPlugin.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/plugins/${this.configuration.encodeParam({name:"pluginId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}/debug`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}getAllPlugins(n="body",a=!1,i){let o=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);t!==void 0&&(o=o.set("Accept",t));let e=i?.context??new u,c=i?.transferCache??!0,l="json";t&&(t.startsWith("text")?l="text":this.configuration.isJsonMime(t)?l="json":l="blob");let r="/api/plugins",{basePath:d,withCredentials:s}=this.configuration;return this.httpClient.request("get",`${d}${r}`,f(b({context:e,responseType:l},s?{withCredentials:s}:{}),{headers:o,observe:n,transferCache:c,reportProgress:a}))}getPlugin(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter pluginId was null or undefined when calling getPlugin.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/plugins/${this.configuration.encodeParam({name:"pluginId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}reloadAllAgentsPlugin(n="body",a=!1,i){let o=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);t!==void 0&&(o=o.set("Accept",t));let e=i?.context??new u,c=i?.transferCache??!0,l="json";t&&(t.startsWith("text")?l="text":this.configuration.isJsonMime(t)?l="json":l="blob");let r="/api/plugins/reload-agents",{basePath:d,withCredentials:s}=this.configuration;return this.httpClient.request("post",`${d}${r}`,f(b({context:e,responseType:l},s?{withCredentials:s}:{}),{headers:o,observe:n,transferCache:c,reportProgress:a}))}reloadPlugin(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter pluginId was null or undefined when calling reloadPlugin.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/plugins/${this.configuration.encodeParam({name:"pluginId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}/reload`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("post",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}startPlugin(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter pluginId was null or undefined when calling startPlugin.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/plugins/${this.configuration.encodeParam({name:"pluginId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}/start`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("post",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}stopPlugin(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter pluginId was null or undefined when calling stopPlugin.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/plugins/${this.configuration.encodeParam({name:"pluginId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}/stop`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("post",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}unloadPlugin(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter pluginId was null or undefined when calling unloadPlugin.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/plugins/${this.configuration.encodeParam({name:"pluginId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:void 0})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("delete",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}uploadPlugin(n="body",a=!1,i){let o=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["*/*"]);t!==void 0&&(o=o.set("Accept",t));let e=i?.context??new u,c=i?.transferCache??!0,l="json";t&&(t.startsWith("text")?l="text":this.configuration.isJsonMime(t)?l="json":l="blob");let r="/api/plugins/upload",{basePath:d,withCredentials:s}=this.configuration;return this.httpClient.request("post",`${d}${r}`,f(b({context:e,responseType:l},s?{withCredentials:s}:{}),{headers:o,observe:n,transferCache:c,reportProgress:a}))}static \u0275fac=function(a){return new(a||C)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:C,factory:C.\u0275fac,providedIn:"root"})};var J=class C extends m{constructor(n,a,i){super(a,i);this.httpClient=n}streamEventsCaseEventSse(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter caseId was null or undefined when calling streamEventsCaseEventSse.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["text/event-stream"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/cases/${this.configuration.encodeParam({name:"caseId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}/events`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}static \u0275fac=function(a){return new(a||C)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:C,factory:C.\u0275fac,providedIn:"root"})};var W=class C extends m{constructor(n,a,i){super(a,i);this.httpClient=n}createUser(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter user was null or undefined when calling createUser.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r=["application/json"],d=this.configuration.selectHeaderContentType(r);d!==void 0&&(t=t.set("Content-Type",d));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let p="/api/users",{basePath:H,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${H}${p}`,f(b({context:c,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}deleteUser(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter id was null or undefined when calling deleteUser.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept([]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/users/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("delete",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}getByIdUser(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter id was null or undefined when calling getByIdUser.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/users/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}getByIdsUser(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter requestBody was null or undefined when calling getByIdsUser.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r=["application/json"],d=this.configuration.selectHeaderContentType(r);d!==void 0&&(t=t.set("Content-Type",d));let s="json";e&&(e.startsWith("text")?s="text":this.configuration.isJsonMime(e)?s="json":s="blob");let p="/api/users/by-ids",{basePath:H,withCredentials:g}=this.configuration;return this.httpClient.request("post",`${H}${p}`,f(b({context:c,body:n,responseType:s},g?{withCredentials:g}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}getMeUser(n="body",a=!1,i){let o=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);t!==void 0&&(o=o.set("Accept",t));let e=i?.context??new u,c=i?.transferCache??!0,l="json";t&&(t.startsWith("text")?l="text":this.configuration.isJsonMime(t)?l="json":l="blob");let r="/api/users/me",{basePath:d,withCredentials:s}=this.configuration;return this.httpClient.request("get",`${d}${r}`,f(b({context:e,responseType:l},s?{withCredentials:s}:{}),{headers:o,observe:n,transferCache:c,reportProgress:a}))}listAllUser(n="body",a=!1,i){let o=this.defaultHeaders,t=i?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);t!==void 0&&(o=o.set("Accept",t));let e=i?.context??new u,c=i?.transferCache??!0,l="json";t&&(t.startsWith("text")?l="text":this.configuration.isJsonMime(t)?l="json":l="blob");let r="/api/users",{basePath:d,withCredentials:s}=this.configuration;return this.httpClient.request("get",`${d}${r}`,f(b({context:e,responseType:l},s?{withCredentials:s}:{}),{headers:o,observe:n,transferCache:c,reportProgress:a}))}listByParentUser(n,a="body",i=!1,o){if(n==null)throw new Error("Required parameter parentId was null or undefined when calling listByParentUser.");let t=this.defaultHeaders,e=o?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);e!==void 0&&(t=t.set("Accept",e));let c=o?.context??new u,l=o?.transferCache??!0,r="json";e&&(e.startsWith("text")?r="text":this.configuration.isJsonMime(e)?r="json":r="blob");let d=`/api/users/by-parentId/${this.configuration.encodeParam({name:"parentId",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:s,withCredentials:p}=this.configuration;return this.httpClient.request("get",`${s}${d}`,f(b({context:c,responseType:r},p?{withCredentials:p}:{}),{headers:t,observe:a,transferCache:l,reportProgress:i}))}updateUser(n,a,i="body",o=!1,t){if(n==null)throw new Error("Required parameter id was null or undefined when calling updateUser.");if(a==null)throw new Error("Required parameter user was null or undefined when calling updateUser.");let e=this.defaultHeaders,c=t?.httpHeaderAccept??this.configuration.selectHeaderAccept(["application/json"]);c!==void 0&&(e=e.set("Accept",c));let l=t?.context??new u,r=t?.transferCache??!0,d=["application/json"],s=this.configuration.selectHeaderContentType(d);s!==void 0&&(e=e.set("Content-Type",s));let p="json";c&&(c.startsWith("text")?p="text":this.configuration.isJsonMime(c)?p="json":p="blob");let H=`/api/users/${this.configuration.encodeParam({name:"id",value:n,in:"path",style:"simple",explode:!1,dataType:"string",dataFormat:"uuid"})}`,{basePath:g,withCredentials:P}=this.configuration;return this.httpClient.request("put",`${g}${H}`,f(b({context:l,body:a,responseType:p},P?{withCredentials:P}:{}),{headers:e,observe:i,transferCache:r,reportProgress:o}))}static \u0275fac=function(a){return new(a||C)(x(j),x(v,8),x(y,8))};static \u0275prov=A({token:C,factory:C.\u0275fac,providedIn:"root"})};function no(C){return G([typeof C=="string"?{provide:v,useValue:C}:{provide:y,useValue:new y(b({},C))}])}var F=class C{config=O(y);zone=O(L);connect(h){let n=`${this.config.basePath}/api/cases/${h}/events`;return new _(a=>{let i=this.zone.runOutsideAngular(()=>new EventSource(n));return i.onmessage=o=>{try{let t=JSON.parse(o.data);this.zone.run(()=>a.next(t))}catch(t){this.zone.run(()=>a.error(new Error(`Failed to parse SSE event: ${t}`)))}},i.onerror=o=>{i.readyState===EventSource.CLOSED?this.zone.run(()=>a.complete()):this.zone.run(()=>a.error(new Error(`SSE connection error for case ${h}`))),i.close()},()=>i.close()})}static \u0275fac=function(n){return new(n||C)};static \u0275prov=A({token:C,factory:C.\u0275fac,providedIn:"root"})};export{y as a,R as b,E as c,B as d,$ as e,M as f,q as g,U as h,W as i,K as j,no as k};
@@ -1 +0,0 @@
1
- import{g as D}from"./chunk-GAZJZBKP.js";import{d as V}from"./chunk-QWMDAFBN.js";import{g as O,h as A}from"./chunk-7A54VTP2.js";import{a as N}from"./chunk-AJOXSD6I.js";import{Bb as I,Db as l,Fb as o,Gc as E,Ka as _,Pb as k,S as w,Tb as b,Ub as h,Wa as f,ab as M,ac as T,ca as g,dc as P,ec as S,ga as c,ha as p,hc as L,i as x,lb as v,ma as q,mb as C,oa as d,rb as u,sb as r,t as R,tb as m}from"./chunk-3JGMGRXW.js";function K(s,e){if(s&1&&(r(0,"span",3),b(1),m()),s&2){let t=o();_(),h(t.namespace.description)}}var y=class s{namespace;selected=new d;editRequested=new d;integrationsRequested=new d;aiProvidersRequested=new d;aiModelsRequested=new d;deleteRequested=new d;menuItems=[{key:"edit",label:"Edit namespace",icon:"edit"},{key:"integrations",label:"Manage integrations",icon:"settings"},{key:"ai-providers",label:"AI Providers",icon:"smart_toy"},{key:"ai-models",label:"AI models",icon:"model_training"},{key:"delete",label:"Delete namespace",icon:"delete",variant:"danger"}];onSelect(){this.selected.emit(this.namespace)}onMenuAction(e){switch(e){case"edit":this.editRequested.emit(this.namespace);break;case"integrations":this.integrationsRequested.emit(this.namespace);break;case"ai-providers":this.aiProvidersRequested.emit(this.namespace);break;case"ai-models":this.aiModelsRequested.emit(this.namespace);break;case"delete":confirm(`Delete namespace "${this.namespace.name}"?`)&&this.deleteRequested.emit(this.namespace);break}}static \u0275fac=function(t){return new(t||s)};static \u0275cmp=f({type:s,selectors:[["agentos-namespace-item"]],inputs:{namespace:"namespace"},outputs:{selected:"selected",editRequested:"editRequested",integrationsRequested:"integrationsRequested",aiProvidersRequested:"aiProvidersRequested",aiModelsRequested:"aiModelsRequested",deleteRequested:"deleteRequested"},decls:7,vars:3,consts:[["role","listitem",1,"namespace-item"],["type","button",1,"namespace-item__body",3,"click"],[1,"namespace-item__name"],[1,"namespace-item__desc"],[1,"namespace-item__actions"],[3,"itemSelected","items"]],template:function(t,a){t&1&&(r(0,"div",0)(1,"button",1),l("click",function(){return a.onSelect()}),r(2,"span",2),b(3),m(),v(4,K,2,1,"span",3),m(),r(5,"div",4)(6,"ds-kebab-menu",5),l("itemSelected",function(i){return a.onMenuAction(i)}),m()()()),t&2&&(_(3),h(a.namespace.name),_(),C(a.namespace.description?4:-1),_(2),u("items",a.menuItems))},dependencies:[A],styles:[".namespace-item[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;padding:.875rem 1.25rem;border-radius:10px;border:1px solid var(--color-border, rgba(0, 0, 0, .08));background:var(--glass-bg, rgba(255, 255, 255, .72));-webkit-backdrop-filter:var(--glass-backdrop-blur, blur(20px));backdrop-filter:var(--glass-backdrop-blur, blur(20px));transition:background .15s ease,border-color .15s ease}.namespace-item[_ngcontent-%COMP%]:hover{background:var(--color-bg-hover, rgba(0, 0, 0, .04));border-color:var(--color-primary, #007aff)}.namespace-item__body[_ngcontent-%COMP%]{flex:1;display:flex;flex-direction:column;align-items:flex-start;gap:.2rem;background:none;border:none;padding:0;cursor:pointer;text-align:left;min-width:0}.namespace-item__name[_ngcontent-%COMP%]{font-size:.95rem;font-weight:500;color:var(--color-text, #1d1d1f);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%}.namespace-item__desc[_ngcontent-%COMP%]{font-size:.8rem;color:var(--color-text-secondary, #6e6e73);white-space:nowrap;overflow:hidden;text-overflow:ellipsis;max-width:100%}.namespace-item__actions[_ngcontent-%COMP%]{flex-shrink:0;display:flex;align-items:center;gap:.125rem;opacity:0;transition:opacity .15s ease}.namespace-item[_ngcontent-%COMP%]:hover .namespace-item__actions[_ngcontent-%COMP%], .namespace-item[_ngcontent-%COMP%]:focus-within .namespace-item__actions[_ngcontent-%COMP%]{opacity:1}"],changeDetection:0})};var j=()=>[];function z(s,e){if(s&1){let t=I();r(0,"agentos-namespace-item",3),l("selected",function(n){c(t);let i=o(2);return p(i.navigateToCases(n.id??""))})("editRequested",function(n){c(t);let i=o(2);return p(i.navigateToEdit(n))})("deleteRequested",function(n){c(t);let i=o(2);return p(i.deleteNamespace(n))})("integrationsRequested",function(n){c(t);let i=o(2);return p(i.openIntegrations(n))})("aiProvidersRequested",function(n){c(t);let i=o(2);return p(i.openAiProviders(n))})("aiModelsRequested",function(n){c(t);let i=o(2);return p(i.openAiModels(n))}),m()}s&2&&u("namespace",e)}function U(s,e){if(s&1&&v(0,z,1,1,"agentos-namespace-item",2),s&2){let t,a=e.$implicit,n=o();C((t=n.resolveNamespace(a.id))?0:-1,t)}}var $=class s{router=g(V);namespaceController=g(D);destroyRef=g(q);refresh$=new x(void 0);namespaces$=this.refresh$.pipe(w(()=>this.namespaceController.listAllNamespace()));namespaceItems$=this.namespaces$.pipe(R(e=>e.map(t=>({id:t.id??"",name:t.name,description:t.description}))));namespacesById=new Map;constructor(){this.namespaces$.pipe(N(this.destroyRef)).subscribe(e=>{this.namespacesById=new Map(e.map(t=>[t.id??"",t]))})}navigateToCases(e){this.router.navigate(["/agentos",e,"cases"])}navigateToCreate(){this.router.navigate(["/agentos/namespaces/new"])}navigateToEdit(e){this.router.navigate(["/agentos/namespaces",e.id??"","edit"])}openIntegrations(e){this.router.navigate(["/agentos",e.id,"integrations"])}openAiProviders(e){this.router.navigate(["/agentos",e.id,"ai-providers"])}openAiModels(e){this.router.navigate(["/agentos",e.id,"ai-models"])}deleteNamespace(e){this.namespaceController.deleteNamespace(e.id??"").pipe(N(this.destroyRef)).subscribe(()=>this.refresh$.next())}resolveNamespace(e){return this.namespacesById.get(e)??null}static \u0275fac=function(t){return new(t||s)};static \u0275cmp=f({type:s,selectors:[["agentos-namespace-list"]],decls:4,vars:6,consts:[["namespaceItemTpl",""],["title","Namespaces","emptyMessage","No namespaces yet. Create one to get started.","cardMinWidth","400px",3,"itemSelected","createRequested","items","showCreate","itemTemplate"],[3,"namespace"],[3,"selected","editRequested","deleteRequested","integrationsRequested","aiProvidersRequested","aiModelsRequested","namespace"]],template:function(t,a){if(t&1&&(r(0,"ds-entity-list",1),P(1,"async"),l("itemSelected",function(i){return a.navigateToCases(i)})("createRequested",function(){return a.navigateToCreate()}),m(),M(2,U,1,1,"ng-template",null,0,L)),t&2){let n=k(3);u("items",S(1,3,a.namespaceItems$)??T(5,j))("showCreate",!0)("itemTemplate",n)}},dependencies:[y,O,E],encapsulation:2})};export{y as a,$ as b};