@whoz-oss/coday-client 1.3.3 → 1.3.4

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 (73) hide show
  1. package/browser/{chunk-BRf9jAIf.js → chunk-3QjpTDpt.js} +1 -1
  2. package/browser/{chunk--wHR1I8D.js → chunk-7IEj5tud.js} +1 -1
  3. package/browser/{chunk-DaK9SdKA.js → chunk-8RFsf09R.js} +1 -1
  4. package/browser/{chunk-S33m0v63.js → chunk-9rFJllaP.js} +1 -1
  5. package/browser/{chunk-BuK7YbXS.js → chunk-B3mPWOwM.js} +1 -1
  6. package/browser/{chunk-BvhdH1Xv.js → chunk-BDqV-dXo.js} +1 -1
  7. package/browser/chunk-BGM4NjUk.js +1 -0
  8. package/browser/{chunk-DZuiUHX9.js → chunk-BMBD8g8i.js} +1 -1
  9. package/browser/chunk-BYAMVo7F.js +1 -0
  10. package/browser/{chunk-DW33OOxm.js → chunk-BbOdBhQy.js} +1 -1
  11. package/browser/{chunk-5I4m0Psa.js → chunk-Bc_JiT75.js} +1 -1
  12. package/browser/{chunk-GU0OGBZz.js → chunk-BfoCTjUr.js} +1 -1
  13. package/browser/{chunk-j7t2mSd6.js → chunk-BhKcjruH.js} +1 -1
  14. package/browser/{chunk-dwDdFGUB.js → chunk-Bj9y8qST.js} +1 -1
  15. package/browser/{chunk-pySUFhL3.js → chunk-Brj8HlXc.js} +1 -1
  16. package/browser/{chunk-drd9oaGN.js → chunk-BxT6IsjS.js} +1 -1
  17. package/browser/{chunk-BhfTutz7.js → chunk-By4bK8Lp.js} +1 -1
  18. package/browser/chunk-C8qVsVH8.js +1 -0
  19. package/browser/{chunk-Cx9yTdUm.js → chunk-CFw8eyQX.js} +1 -1
  20. package/browser/{chunk-D4D8VOP2.js → chunk-CH0b9ss9.js} +1 -1
  21. package/browser/{chunk-BXWpkOo5.js → chunk-CInfUnUL.js} +1 -1
  22. package/browser/{chunk-jki7cP90.js → chunk-CJpYYZh2.js} +1 -1
  23. package/browser/{chunk-z6x1ROGz.js → chunk-CTjZECqR.js} +1 -1
  24. package/browser/{chunk-CV4cx-V6.js → chunk-CTx3Z0hA.js} +1 -1
  25. package/browser/{chunk-BMSbS6nO.js → chunk-CVuNrNOH.js} +1 -1
  26. package/browser/{chunk-CoQcKJau.js → chunk-CXVQ4M5H.js} +1 -1
  27. package/browser/{chunk-DHse9w28.js → chunk-Cb82rqle.js} +2 -2
  28. package/browser/{chunk-BFBXLzHo.js → chunk-CbSC-SSJ.js} +1 -1
  29. package/browser/{chunk-BGlC5myX.js → chunk-CeTVH-vp.js} +1 -1
  30. package/browser/{chunk-fxaq06d7.js → chunk-Cek4dv2K.js} +1 -1
  31. package/browser/{chunk-CIQjlvza.js → chunk-CekA5yLC.js} +1 -1
  32. package/browser/{chunk-BoBOhDYi.js → chunk-CisLHTrk.js} +1 -1
  33. package/browser/chunk-Cm35aeo6.js +1 -0
  34. package/browser/{chunk-C26xMDFo.js → chunk-Cm42_zF7.js} +1 -1
  35. package/browser/{chunk-Y4Oxet3L.js → chunk-CpMYZ9dG.js} +1 -1
  36. package/browser/{chunk-DWo8Yipj.js → chunk-CrExrE4n.js} +1 -1
  37. package/browser/{chunk-C_Vj6FE_.js → chunk-CsvLyu6R.js} +1 -1
  38. package/browser/{chunk-XynH5Ted.js → chunk-Cy-MbcIf.js} +1 -1
  39. package/browser/{chunk-CIOzO35E.js → chunk-CywonzJi.js} +1 -1
  40. package/browser/{chunk-DmZR81FM.js → chunk-D1ggthOI.js} +1 -1
  41. package/browser/{chunk-DL6rhSDN.js → chunk-DFaRJnOg.js} +1 -1
  42. package/browser/{chunk-D-K9FhYH.js → chunk-DJz2cMcV.js} +1 -1
  43. package/browser/{chunk-LNTSOB-k.js → chunk-DLhvPTZP.js} +1 -1
  44. package/browser/{chunk-DaJf2IFW.js → chunk-DVSN51SP.js} +1 -1
  45. package/browser/{chunk-DyKPeAU4.js → chunk-DWrJdp3G.js} +1 -1
  46. package/browser/{chunk--Cv5Auvq.js → chunk-DXVBbChn.js} +1 -1
  47. package/browser/{chunk-Cq8feM71.js → chunk-DgFkTqkZ.js} +1 -1
  48. package/browser/{chunk-mHggS-i6.js → chunk-DoS8-ZTX.js} +1 -1
  49. package/browser/{chunk-D9wQSJ4q.js → chunk-DpRS0jIN.js} +1 -1
  50. package/browser/{chunk-CjhnozeY.js → chunk-DvV6rFWO.js} +1 -1
  51. package/browser/{chunk-C87Bh3Ov.js → chunk-Lluy_pM_.js} +1 -1
  52. package/browser/{chunk-CNPdPW3v.js → chunk-NPBU5yIa.js} +1 -1
  53. package/browser/{chunk-B_DNrrfb.js → chunk-OpV-oEpT.js} +1 -1
  54. package/browser/{chunk-DRAFMqKn.js → chunk-S_TYzsa6.js} +1 -1
  55. package/browser/{chunk-Bd0IiMsO.js → chunk-X4zIHpcE.js} +1 -1
  56. package/browser/{chunk-C4iGhgYI.js → chunk-_Wj2M8II.js} +1 -1
  57. package/browser/{chunk-DtHFNV_5.js → chunk-_kolzKbl.js} +1 -1
  58. package/browser/{chunk-DmbSsVzR.js → chunk-_si25xRH.js} +1 -1
  59. package/browser/{chunk-CASGcP8y.js → chunk-eCkjwC-y.js} +1 -1
  60. package/browser/{chunk-vdkNDukI.js → chunk-eqpKdy80.js} +1 -1
  61. package/browser/{chunk-C0QR-AJM.js → chunk-hL6iczXD.js} +1 -1
  62. package/browser/{chunk-DxenqkEz.js → chunk-hcl2JPuw.js} +1 -1
  63. package/browser/{chunk-TwL6unik.js → chunk-i62b6Gtt.js} +1 -1
  64. package/browser/{chunk-PH-PuPg1.js → chunk-vkYtcaIT.js} +1 -1
  65. package/browser/{chunk-okzlJmPZ.js → chunk-xk_bqNV0.js} +1 -1
  66. package/browser/{chunk-DJSzQBCH.js → chunk-zyGtaVKQ.js} +1 -1
  67. package/browser/index.html +1 -1
  68. package/browser/{main-XVJVH4GF.js → main-FEA3BAHM.js} +1 -1
  69. package/package.json +1 -1
  70. package/browser/chunk-CCN3DpLY.js +0 -1
  71. package/browser/chunk-COcavU_q.js +0 -1
  72. package/browser/chunk-DlKQ1Cys.js +0 -1
  73. package/browser/chunk-SitBftU1.js +0 -1
@@ -1 +1 @@
1
- import {c}from'./chunk-C_Vj6FE_.js';import {g,ao as V,G,w as we$1,d7 as M,d8 as he$1,d9 as fe$1,H as Hi,da as ge$1,F,bQ as bd,m as mT,Q as By,b as U,a7 as ga,S as ha,z as z$1,a as P,A as Aw,v as vs,l as Ag,W as WC,k as fl,n as eC,X as XE,a5 as yl,t as tC,a9 as dC,o as bg,a3 as HI,q as oC,ac as mC,r as Tg,y as Hg,a6 as $I,x as iC,a8 as Zg,aa as If,ab as wf,bj as yh}from'./main-XVJVH4GF.js';import {o as z,k as _t,b as _e$1,n as ni,J as Jn,Q as Qn,e as ei,Y as Ye,f as fn,a as wt,A as At,Z as Zn,l as Xn,$ as $t,C as Cn,E as En}from'./chunk-DL6rhSDN.js';var A=(n,t)=>t.value,se=(n,t)=>t.id;function pe(n,t){n&1&&(vs(0,"p",5),WC(1,"Loading\u2026"),fl());}function ue(n,t){n&1&&(vs(0,"span",12),WC(1," Name is required. "),fl());}function fe(n,t){if(n&1&&(vs(0,"p",40),WC(1),fl(),vs(2,"span",13),WC(3,"Agent Config cannot be changed after creation."),fl()),n&2){let e=mC(2);XE(),Zg(e.resolveAgentConfigName(e.agentConfigIdControl.value));}}function _e(n,t){if(n&1&&(vs(0,"a",41),WC(1,"Add an agent config"),fl(),WC(2," first. ")),n&2){let e=mC(3);Tg("href","/agentos/"+e.namespaceId+"/agent-configs/new",yh);}}function he(n,t){if(n&1&&(vs(0,"p",13),WC(1," No agent configs available in this scope yet. "),eC(2,_e,3,1),fl()),n&2){let e=mC(2);XE(2),tC(e.isPlatformMode?-1:2);}}function ge(n,t){if(n&1&&(vs(0,"option",23),WC(1),fl()),n&2){let e=t.$implicit;Tg("value",e.id),XE(),Zg(e.name);}}function Ce(n,t){n&1&&(vs(0,"span",12),WC(1,"Agent Config is required."),fl());}function ve(n,t){if(n&1&&(vs(0,"select",42)(1,"option",43),WC(2,"Select an agent config\u2026"),fl(),oC(3,ge,2,2,"option",23,se),fl(),HI(),eC(5,Ce,2,0,"span",12),vs(6,"span",13),WC(7,"Immutable after creation."),fl()),n&2){let e=mC(2);Tg("formControl",e.agentConfigIdControl),$I(),XE(3),iC(e.availableAgentConfigs()),XE(2),tC(e.agentConfigIdControl.invalid&&e.agentConfigIdControl.touched?5:-1);}}function ye(n,t){n&1&&(vs(0,"span",12),WC(1,"Opening message is required."),fl());}function be(n,t){if(n&1&&(vs(0,"option",23),WC(1),fl()),n&2){let e=t.$implicit;Tg("value",e.value),XE(),Zg(e.label);}}function xe(n,t){if(n&1){let e=dC();vs(0,"label",46)(1,"input",47),Ag("change",function(){let h=If(e).$implicit,P=mC(3);return wf(P.toggleDay(h.value))}),fl(),vs(2,"span",48),WC(3),fl()();}if(n&2){let e=t.$implicit,l=mC(3);XE(),Tg("checked",l.isDaySelected(e.value)),XE(2),Zg(e.label);}}function Se(n,t){if(n&1&&(vs(0,"div",8)(1,"span",44),WC(2,"Days of week"),fl(),vs(3,"div",45),oC(4,xe,4,2,"label",46,A),fl(),vs(6,"span",13),WC(7,"Leave empty to run every day of the week."),fl()()),n&2){let e=mC(2);XE(4),iC(e.dayOptions);}}function Pe(n,t){n&1&&(vs(0,"span",12),WC(1,"Valid time is required (HH:mm)."),fl());}function Ee(n,t){n&1&&(vs(0,"span",12),WC(1,"Start date is required."),fl());}function Me(n,t){if(n&1&&(vs(0,"option",23),WC(1),fl()),n&2){let e=t.$implicit;Tg("value",e.value),XE(),Zg(e.label);}}function Oe(n,t){n&1&&(vs(0,"span",12),WC(1,"End date is required."),fl());}function De(n,t){if(n&1&&(vs(0,"div",8)(1,"label",49),WC(2," End date "),vs(3,"span",10),WC(4,"*"),fl()(),bg(5,"input",50),HI(),eC(6,Oe,2,0,"span",12),fl()),n&2){let e=mC(2);XE(5),Hg("scheduled-prompt-form__input--invalid",e.form.hasError("endDateRequired")&&e.endDateControl.touched),Tg("formControl",e.endDateControl),$I(),XE(),tC(e.form.hasError("endDateRequired")&&e.endDateControl.touched?6:-1);}}function Te(n,t){n&1&&(vs(0,"span",12),WC(1,"Must be at least 1."),fl());}function we(n,t){if(n&1&&(vs(0,"div",8)(1,"label",51),WC(2," Number of occurrences "),vs(3,"span",10),WC(4,"*"),fl()(),bg(5,"input",52),HI(),eC(6,Te,2,0,"span",12),fl()),n&2){let e=mC(2);XE(5),Hg("scheduled-prompt-form__input--invalid",e.form.hasError("occurrenceCountRequired")&&e.occurrenceCountControl.touched),Tg("formControl",e.occurrenceCountControl),$I(),XE(),tC(e.form.hasError("occurrenceCountRequired")&&e.occurrenceCountControl.touched?6:-1);}}function ke(n,t){if(n&1&&(vs(0,"p",36),WC(1),fl()),n&2){let e=mC(2);XE(),Zg(e.errorMessage());}}function Fe(n,t){if(n&1){let e=dC();vs(0,"form",7),Ag("ngSubmit",function(){If(e);let h=mC();return wf(h.submit())}),vs(1,"div",8)(2,"label",9),WC(3," Name "),vs(4,"span",10),WC(5,"*"),fl()(),bg(6,"input",11),HI(),eC(7,ue,2,0,"span",12),vs(8,"span",13),WC(9,'Free-form name (e.g. "Weekly Report"). Cannot be changed after creation.'),fl()(),vs(10,"div",8)(11,"label",14),WC(12,"Description"),fl(),bg(13,"input",15),HI(),fl(),vs(14,"div",8)(15,"label",16),WC(16," Agent Config "),vs(17,"span",10),WC(18,"*"),fl()(),eC(19,fe,4,1)(20,he,3,1,"p",13)(21,ve,8,2),fl(),vs(22,"div",8)(23,"label",17),WC(24," Opening message "),vs(25,"span",10),WC(26,"*"),fl()(),bg(27,"textarea",18),HI(),eC(28,ye,2,0,"span",12),vs(29,"span",13),WC(30," The message sent to the agent when the scheduled prompt fires. "),fl()(),vs(31,"fieldset",19)(32,"legend",20),WC(33,"Recurrence"),fl(),vs(34,"div",8)(35,"label",21),WC(36," Unit "),vs(37,"span",10),WC(38,"*"),fl()(),vs(39,"select",22),oC(40,be,2,2,"option",23,A),fl(),HI(),fl(),eC(42,Se,8,0,"div",8),vs(43,"div",8)(44,"label",24),WC(45," Time (UTC) "),vs(46,"span",10),WC(47,"*"),fl()(),vs(48,"div",25),bg(49,"input",26),HI(),vs(50,"span",27),WC(51,"UTC"),fl()(),eC(52,Pe,2,0,"span",12),fl()(),vs(53,"fieldset",19)(54,"legend",20),WC(55,"Planning"),fl(),vs(56,"div",8)(57,"label",28),WC(58," Start date "),vs(59,"span",10),WC(60,"*"),fl()(),bg(61,"input",29),HI(),eC(62,Ee,2,0,"span",12),fl(),vs(63,"div",8)(64,"label",30),WC(65," Ends "),vs(66,"span",10),WC(67,"*"),fl()(),vs(68,"select",31),oC(69,Me,2,2,"option",23,A),fl(),HI(),fl(),eC(71,De,7,4,"div",8),eC(72,we,7,4,"div",8),fl(),vs(73,"div",8)(74,"label",32),bg(75,"input",33),HI(),vs(76,"span",34),WC(77,"Enabled"),fl()(),vs(78,"p",35),WC(79," When disabled, the scheduled prompt is saved but will not run on schedule. "),fl()(),eC(80,ke,2,1,"p",36),vs(81,"div",37)(82,"button",38),WC(83),fl(),vs(84,"button",39),Ag("click",function(){If(e);let h=mC();return wf(h.cancel())}),WC(85,"Cancel"),fl()()();}if(n&2){let e=mC();Tg("formGroup",e.form),XE(6),Hg("scheduled-prompt-form__input--invalid",e.nameControl.invalid&&e.nameControl.touched),Tg("formControl",e.nameControl),$I(),XE(),tC(e.nameControl.invalid&&e.nameControl.touched?7:-1),XE(6),Tg("formControl",e.descriptionControl),$I(),XE(6),tC(e.isEditMode()?19:e.availableAgentConfigs().length===0?20:21),XE(8),Hg("scheduled-prompt-form__textarea--invalid",e.promptContentControl.invalid&&e.promptContentControl.touched),Tg("formControl",e.promptContentControl),$I(),XE(),tC(e.promptContentControl.invalid&&e.promptContentControl.touched?28:-1),XE(11),Tg("formControl",e.unitControl),$I(),XE(),iC(e.schedulerUnits),XE(2),tC(e.showDayFilter()?42:-1),XE(7),Tg("formControl",e.timeUtcControl),$I(),XE(3),tC(e.timeUtcControl.invalid&&e.timeUtcControl.touched?52:-1),XE(9),Hg("scheduled-prompt-form__input--invalid",e.startDateControl.invalid&&e.startDateControl.touched),Tg("formControl",e.startDateControl),$I(),XE(),tC(e.startDateControl.invalid&&e.startDateControl.touched?62:-1),XE(6),Tg("formControl",e.endTypeControl),$I(),XE(),iC(e.endTypes),XE(2),tC(e.showEndDate()?71:-1),XE(),tC(e.showOccurrenceCount()?72:-1),XE(3),Tg("formControl",e.enabledControl),$I(),XE(5),tC(e.errorMessage()?80:-1),XE(2),Tg("disabled",e.form.invalid||e.isSubmitting()),XE(),yl(" ",e.isEditMode()?"Save changes":"Create scheduled prompt"," ");}}var me=class n{route=g(V);router=g(G);destroyRef=g(we$1);state=g(c);agentConfigController=g(M);namespaceId=this.route.snapshot.params.namespaceId;isPlatformMode=!this.namespaceId;form=new z({name:new _t("",{nonNullable:true,validators:[_e$1.required]}),description:new _t(null),agentConfigId:new _t("",{nonNullable:true,validators:[_e$1.required]}),promptContent:new _t("",{nonNullable:true,validators:[_e$1.required]}),unit:new _t(fe$1.WEEK,{nonNullable:true,validators:[_e$1.required]}),days:new _t([],{nonNullable:true}),timeUtc:new _t("09:00",{nonNullable:true,validators:[_e$1.required,_e$1.pattern(/^([01]\d|2[0-3]):[0-5]\d$/)]}),startDate:new _t("",{nonNullable:true,validators:[_e$1.required]}),endType:new _t(he$1.NEVER,{nonNullable:true,validators:[_e$1.required]}),endDate:new _t(null),occurrenceCount:new _t(null),enabled:new _t(true,{nonNullable:true})},{validators:[Ne,Ie]});get nameControl(){return this.form.controls.name}get descriptionControl(){return this.form.controls.description}get agentConfigIdControl(){return this.form.controls.agentConfigId}get promptContentControl(){return this.form.controls.promptContent}get unitControl(){return this.form.controls.unit}get daysControl(){return this.form.controls.days}get timeUtcControl(){return this.form.controls.timeUtc}get startDateControl(){return this.form.controls.startDate}get endTypeControl(){return this.form.controls.endType}get endDateControl(){return this.form.controls.endDate}get occurrenceCountControl(){return this.form.controls.occurrenceCount}get enabledControl(){return this.form.controls.enabled}isEditMode=Hi(false);isSubmitting=Hi(false);isLoading=Hi(false);errorMessage=Hi(null);SchedulerUnit=fe$1;SchedulerEndType=he$1;schedulerUnits=[{value:fe$1.WEEK,label:"Week(s)"},{value:fe$1.MONTH,label:"Month(s)"}];endTypes=[{value:he$1.NEVER,label:"Never"},{value:he$1.ON_DATE,label:"On date"},{value:he$1.OCCURRENCES,label:"After N occurrences"}];dayOptions=Object.entries(ge$1).map(([t,e])=>({value:t,label:e}));unitSignal=F(this.unitControl.valueChanges.pipe(bd(this.unitControl.value)));endTypeSignal=F(this.endTypeControl.valueChanges.pipe(bd(this.endTypeControl.value)));showDayFilter=mT(()=>this.unitSignal()===fe$1.WEEK);showEndDate=mT(()=>this.endTypeSignal()===he$1.ON_DATE);showOccurrenceCount=mT(()=>this.endTypeSignal()===he$1.OCCURRENCES);agentConfigs=Hi([]);availableAgentConfigs=this.agentConfigs.asReadonly();existingPrompt=null;ngOnInit(){this.startDateControl.setValue(Ve());let t=this.route.snapshot.paramMap.get("scheduledPromptId");t?(this.isEditMode.set(true),this.loadPromptAndResources(t)):this.loadResources();}loadPromptAndResources(t){this.isLoading.set(true),By({prompt:this.state.getById(t),agentConfigs:this.agentConfigs$()}).pipe(U(this.destroyRef)).subscribe({next:({prompt:e,agentConfigs:l})=>{this.existingPrompt=e,this.agentConfigs.set(l),this.hydrateForm(e),this.isLoading.set(false);},error:()=>{this.isLoading.set(false),this.navigateBack();}});}loadResources(){this.agentConfigs$().pipe(U(this.destroyRef)).subscribe(t=>this.agentConfigs.set(t));}agentConfigs$(){return (this.isPlatformMode?this.agentConfigController.listPlatformAgentsAgentConfig():this.agentConfigController.listByParentAgentConfig(this.namespaceId)).pipe(ga(()=>ha([])))}hydrateForm(t){this.nameControl.setValue(t.name),this.descriptionControl.setValue(t.description??null),this.agentConfigIdControl.setValue(t.agentConfigId),this.promptContentControl.setValue(t.promptContent),this.unitControl.setValue(t.recurrence.unit),this.daysControl.setValue(t.recurrence.days??[]),this.timeUtcControl.setValue(t.recurrence.timeUtc),this.startDateControl.setValue(t.planning.startDate),this.endTypeControl.setValue(t.planning.endType),this.endDateControl.setValue(t.planning.endDate??null),this.occurrenceCountControl.setValue(t.planning.maxOccurrenceCount??null),this.enabledControl.setValue(t.enabled);}isDaySelected(t){return this.daysControl.value.includes(t)}toggleDay(t){let e=this.daysControl.value,l=e.includes(t)?e.filter(h=>h!==t):[...e,t];this.daysControl.setValue(l);}resolveAgentConfigName(t){return this.agentConfigs().find(e=>e.id===t)?.name??t}submit(){if(this.form.invalid||this.isSubmitting())return;this.isSubmitting.set(true),this.errorMessage.set(null);let t=this.isEditMode()&&!!this.existingPrompt?.id,e=this.endTypeControl.value,l=z$1(P({},this.existingPrompt??{}),{namespaceId:this.namespaceId??null,name:this.nameControl.value.trim(),description:this.descriptionControl.value?.trim()||void 0,agentConfigId:t?this.existingPrompt.agentConfigId:this.agentConfigIdControl.value,promptContent:this.promptContentControl.value.trim(),recurrence:{unit:this.unitControl.value,days:this.daysControl.value,timeUtc:this.timeUtcControl.value},planning:{startDate:this.startDateControl.value,endType:e,endDate:e===he$1.ON_DATE?this.endDateControl.value??void 0:void 0,maxOccurrenceCount:e===he$1.OCCURRENCES?this.occurrenceCountControl.value??void 0:void 0},enabled:this.enabledControl.value});(t?this.state.update(this.existingPrompt.id,l):this.state.create(l)).pipe(U(this.destroyRef)).subscribe({next:()=>this.navigateBack(),error:P=>{this.isSubmitting.set(false),P.status===409?this.errorMessage.set(`A scheduled prompt named "${l.name}" already exists in this scope.`):P.status===400?this.errorMessage.set(P.error?.message??"Invalid scheduled prompt data."):this.errorMessage.set("An unexpected error occurred. Please try again.");}});}cancel(){this.navigateBack();}navigateBack(){this.isPlatformMode?this.router.navigate(["/agentos","admin","scheduled-prompts"]):this.router.navigate(["/agentos",this.namespaceId,"scheduled-prompts"]);}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=Aw({type:n,selectors:[["agentos-scheduled-prompt-form"]],decls:10,vars:3,consts:[[1,"scheduled-prompt-form"],[1,"scheduled-prompt-form__header"],["type","button","title","Back to scheduled prompts",1,"scheduled-prompt-form__back",3,"click"],[1,"scheduled-prompt-form__back-icon"],[1,"scheduled-prompt-form__title"],[1,"scheduled-prompt-form__loading"],[1,"scheduled-prompt-form__form",3,"formGroup"],[1,"scheduled-prompt-form__form",3,"ngSubmit","formGroup"],[1,"scheduled-prompt-form__field"],["for","sp-name",1,"scheduled-prompt-form__label"],["aria-hidden","true"],["id","sp-name","type","text","placeholder","e.g. Weekly Report","autocomplete","off",1,"scheduled-prompt-form__input",3,"formControl"],[1,"scheduled-prompt-form__field-error"],[1,"scheduled-prompt-form__field-hint"],["for","sp-description",1,"scheduled-prompt-form__label"],["id","sp-description","type","text","placeholder","Optional \u2014 short description","autocomplete","off",1,"scheduled-prompt-form__input",3,"formControl"],["for","sp-agent-config",1,"scheduled-prompt-form__label"],["for","sp-prompt-content",1,"scheduled-prompt-form__label"],["id","sp-prompt-content","rows","6","placeholder","Enter the message sent to the agent when the scheduled prompt fires\u2026",1,"scheduled-prompt-form__textarea",3,"formControl"],[1,"scheduled-prompt-form__fieldset"],[1,"scheduled-prompt-form__legend"],["for","sp-unit",1,"scheduled-prompt-form__label"],["id","sp-unit",1,"scheduled-prompt-form__select",3,"formControl"],[3,"value"],["for","sp-time",1,"scheduled-prompt-form__label"],[1,"scheduled-prompt-form__time-wrapper"],["id","sp-time","type","time",1,"scheduled-prompt-form__input","scheduled-prompt-form__input--time",3,"formControl"],[1,"scheduled-prompt-form__utc-badge"],["for","sp-start-date",1,"scheduled-prompt-form__label"],["id","sp-start-date","type","date",1,"scheduled-prompt-form__input",3,"formControl"],["for","sp-end-type",1,"scheduled-prompt-form__label"],["id","sp-end-type",1,"scheduled-prompt-form__select",3,"formControl"],[1,"scheduled-prompt-form__toggle-label"],["type","checkbox",1,"scheduled-prompt-form__toggle-checkbox",3,"formControl"],[1,"scheduled-prompt-form__toggle-text"],[1,"scheduled-prompt-form__toggle-hint"],[1,"scheduled-prompt-form__error"],[1,"scheduled-prompt-form__actions"],["type","submit",1,"scheduled-prompt-form__btn","scheduled-prompt-form__btn--primary",3,"disabled"],["type","button",1,"scheduled-prompt-form__btn",3,"click"],[1,"scheduled-prompt-form__readonly-value"],[3,"href"],["id","sp-agent-config",1,"scheduled-prompt-form__select",3,"formControl"],["value","","disabled",""],[1,"scheduled-prompt-form__label"],[1,"scheduled-prompt-form__day-grid"],[1,"scheduled-prompt-form__day-label"],["type","checkbox",1,"scheduled-prompt-form__day-checkbox",3,"change","checked"],[1,"scheduled-prompt-form__day-text"],["for","sp-end-date",1,"scheduled-prompt-form__label"],["id","sp-end-date","type","date",1,"scheduled-prompt-form__input",3,"formControl"],["for","sp-occurrence-count",1,"scheduled-prompt-form__label"],["id","sp-occurrence-count","type","number","min","1",1,"scheduled-prompt-form__input","scheduled-prompt-form__input--number",3,"formControl"]],template:function(e,l){e&1&&(vs(0,"div",0)(1,"header",1)(2,"button",2),Ag("click",function(){return l.cancel()}),vs(3,"span",3),WC(4,"\u2190"),fl(),WC(5),fl(),vs(6,"h1",4),WC(7),fl()(),eC(8,pe,2,0,"p",5)(9,Fe,86,26,"form",6),fl()),e&2&&(XE(5),yl(" ",l.isPlatformMode?"Platform Scheduled Prompts":"Scheduled Prompts"," "),XE(2),yl(" ",l.isEditMode()?"Edit scheduled prompt":"New scheduled prompt"," "),XE(),tC(l.isLoading()?8:9));},dependencies:[ni,Jn,Qn,ei,Ye,fn,wt,At,Zn,Xn,$t,Cn,En],styles:[".scheduled-prompt-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:2rem;max-width:560px;margin:0 auto;padding:2rem 1rem}.scheduled-prompt-form__header[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.scheduled-prompt-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}.scheduled-prompt-form__back[_ngcontent-%COMP%]:hover{text-decoration:underline}.scheduled-prompt-form__back-icon[_ngcontent-%COMP%]{font-size:1rem;line-height:1}.scheduled-prompt-form__title[_ngcontent-%COMP%]{margin:0;font-size:1.5rem;font-weight:600;color:var(--color-text, #1d1d1f);letter-spacing:-.02em}.scheduled-prompt-form__loading[_ngcontent-%COMP%]{color:var(--color-text-secondary, #6e6e73);font-size:.9rem;margin:0}.scheduled-prompt-form__form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.25rem}.scheduled-prompt-form__field[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.375rem}.scheduled-prompt-form__row[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:1rem}.scheduled-prompt-form__label[_ngcontent-%COMP%]{font-size:.875rem;font-weight:500;color:var(--color-text, #1d1d1f)}.scheduled-prompt-form__input[_ngcontent-%COMP%], .scheduled-prompt-form__select[_ngcontent-%COMP%], .scheduled-prompt-form__textarea[_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}.scheduled-prompt-form__input[_ngcontent-%COMP%]:focus, .scheduled-prompt-form__select[_ngcontent-%COMP%]:focus, .scheduled-prompt-form__textarea[_ngcontent-%COMP%]:focus{border-color:var(--color-primary, #007aff)}.scheduled-prompt-form__input[_ngcontent-%COMP%]::placeholder, .scheduled-prompt-form__select[_ngcontent-%COMP%]::placeholder, .scheduled-prompt-form__textarea[_ngcontent-%COMP%]::placeholder{color:var(--color-text-secondary, #6e6e73)}.scheduled-prompt-form__select[_ngcontent-%COMP%]{cursor:pointer;appearance:auto}.scheduled-prompt-form__textarea[_ngcontent-%COMP%]{resize:vertical;min-height:100px;line-height:1.5}.scheduled-prompt-form__input--time[_ngcontent-%COMP%]{flex:1;min-width:0}.scheduled-prompt-form__input--number[_ngcontent-%COMP%]{max-width:120px}.scheduled-prompt-form__time-wrapper[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem}.scheduled-prompt-form__utc-badge[_ngcontent-%COMP%]{flex-shrink:0;font-size:.75rem;font-weight:600;font-family:monospace;color:var(--color-text-secondary, #6e6e73);background:var(--color-surface, rgba(0, 0, 0, .05));padding:.25rem .5rem;border-radius:4px;text-transform:uppercase;letter-spacing:.06em}.scheduled-prompt-form__fieldset[_ngcontent-%COMP%]{border:1px solid var(--color-border, rgba(0, 0, 0, .1));border-radius:8px;padding:1rem 1.25rem 1.25rem;margin:0;display:flex;flex-direction:column;gap:1.25rem}.scheduled-prompt-form__legend[_ngcontent-%COMP%]{font-size:.8125rem;font-weight:600;text-transform:uppercase;letter-spacing:.06em;color:var(--color-text-secondary, #6e6e73);padding:0 .375rem}.scheduled-prompt-form__day-grid[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:.5rem}.scheduled-prompt-form__day-label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.375rem;cursor:pointer;-webkit-user-select:none;user-select:none}.scheduled-prompt-form__day-checkbox[_ngcontent-%COMP%]{width:1rem;height:1rem;flex-shrink:0;accent-color:var(--color-primary, #007aff);cursor:pointer}.scheduled-prompt-form__day-text[_ngcontent-%COMP%]{font-size:.875rem;color:var(--color-text, #1d1d1f)}.scheduled-prompt-form__hint[_ngcontent-%COMP%]{margin:0;font-size:.875rem;color:var(--color-text-secondary, #6e6e73)}.scheduled-prompt-form__hint[_ngcontent-%COMP%] a[_ngcontent-%COMP%]{color:var(--color-primary, #007aff);text-decoration:none}.scheduled-prompt-form__hint[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:hover{text-decoration:underline}.scheduled-prompt-form__error[_ngcontent-%COMP%]{font-size:.8rem;color:var(--color-error, #ff3b30);margin:0}.scheduled-prompt-form__field-error[_ngcontent-%COMP%]{font-size:.8rem;color:var(--color-error, #ff3b30)}.scheduled-prompt-form__field-hint[_ngcontent-%COMP%]{font-size:.8rem;color:var(--color-text-secondary, #6e6e73);line-height:1.4}.scheduled-prompt-form__field-hint[_ngcontent-%COMP%] a[_ngcontent-%COMP%]{color:var(--color-primary, #007aff);text-decoration:none}.scheduled-prompt-form__field-hint[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:hover{text-decoration:underline}.scheduled-prompt-form__readonly-value[_ngcontent-%COMP%]{margin:0;font-size:.9375rem;color:var(--color-text, #1d1d1f);padding:.625rem .875rem;border-radius:8px;border:1px solid var(--color-border, rgba(0, 0, 0, .08));background:var(--color-surface, rgba(0, 0, 0, .03))}.scheduled-prompt-form__input--invalid[_ngcontent-%COMP%], .scheduled-prompt-form__textarea--invalid[_ngcontent-%COMP%]{border-color:var(--color-error, #ff3b30)}.scheduled-prompt-form__toggle-label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;cursor:pointer;-webkit-user-select:none;user-select:none}.scheduled-prompt-form__toggle-checkbox[_ngcontent-%COMP%]{width:1rem;height:1rem;flex-shrink:0;accent-color:var(--color-primary, #007aff);cursor:pointer}.scheduled-prompt-form__toggle-text[_ngcontent-%COMP%]{font-size:.9rem;font-weight:500;color:var(--color-text, #1d1d1f)}.scheduled-prompt-form__toggle-hint[_ngcontent-%COMP%]{margin:.25rem 0 0 1.5rem;font-size:.8rem;color:var(--color-text-secondary, #6e6e73);line-height:1.4}.scheduled-prompt-form__actions[_ngcontent-%COMP%]{display:flex;gap:.75rem;padding-top:.5rem}.scheduled-prompt-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}.scheduled-prompt-form__btn[_ngcontent-%COMP%]:hover:not(:disabled){background:var(--color-surface-hover, rgba(0, 0, 0, .04))}.scheduled-prompt-form__btn[_ngcontent-%COMP%]:disabled{opacity:.45;cursor:not-allowed}.scheduled-prompt-form__btn--primary[_ngcontent-%COMP%]{background:var(--color-primary, #007aff);border-color:var(--color-primary, #007aff);color:#fff}.scheduled-prompt-form__btn--primary[_ngcontent-%COMP%]:hover:not(:disabled){background:var(--color-primary-hover, #0051d5);border-color:var(--color-primary-hover, #0051d5)}"]})};function Ne(n){let t=n.get("endType")?.value,e=n.get("endDate")?.value;return t===he$1.ON_DATE&&!e?{endDateRequired:true}:null}function Ie(n){let t=n.get("endType")?.value,e=n.get("occurrenceCount")?.value;return t===he$1.OCCURRENCES&&(e==null||e<1)?{occurrenceCountRequired:true}:null}function Ve(){let n=new Date,t=n.getFullYear(),e=String(n.getMonth()+1).padStart(2,"0"),l=String(n.getDate()).padStart(2,"0");return `${t}-${e}-${l}`}export{me as ScheduledPromptFormComponent};
1
+ import {c}from'./chunk-CsvLyu6R.js';import {g,ao as V,G,w as we$1,d7 as M,d8 as he$1,d9 as fe$1,H as Hi,da as ge$1,F,bQ as bd,m as mT,Q as By,b as U,a7 as ga,S as ha,z as z$1,a as P,A as Aw,v as vs,l as Ag,W as WC,k as fl,n as eC,X as XE,a5 as yl,t as tC,a9 as dC,o as bg,a3 as HI,q as oC,ac as mC,r as Tg,y as Hg,a6 as $I,x as iC,a8 as Zg,aa as If,ab as wf,bj as yh}from'./main-FEA3BAHM.js';import {o as z,k as _t,b as _e$1,n as ni,J as Jn,Q as Qn,e as ei,Y as Ye,f as fn,a as wt,A as At,Z as Zn,l as Xn,$ as $t,C as Cn,E as En}from'./chunk-DFaRJnOg.js';var A=(n,t)=>t.value,se=(n,t)=>t.id;function pe(n,t){n&1&&(vs(0,"p",5),WC(1,"Loading\u2026"),fl());}function ue(n,t){n&1&&(vs(0,"span",12),WC(1," Name is required. "),fl());}function fe(n,t){if(n&1&&(vs(0,"p",40),WC(1),fl(),vs(2,"span",13),WC(3,"Agent Config cannot be changed after creation."),fl()),n&2){let e=mC(2);XE(),Zg(e.resolveAgentConfigName(e.agentConfigIdControl.value));}}function _e(n,t){if(n&1&&(vs(0,"a",41),WC(1,"Add an agent config"),fl(),WC(2," first. ")),n&2){let e=mC(3);Tg("href","/agentos/"+e.namespaceId+"/agent-configs/new",yh);}}function he(n,t){if(n&1&&(vs(0,"p",13),WC(1," No agent configs available in this scope yet. "),eC(2,_e,3,1),fl()),n&2){let e=mC(2);XE(2),tC(e.isPlatformMode?-1:2);}}function ge(n,t){if(n&1&&(vs(0,"option",23),WC(1),fl()),n&2){let e=t.$implicit;Tg("value",e.id),XE(),Zg(e.name);}}function Ce(n,t){n&1&&(vs(0,"span",12),WC(1,"Agent Config is required."),fl());}function ve(n,t){if(n&1&&(vs(0,"select",42)(1,"option",43),WC(2,"Select an agent config\u2026"),fl(),oC(3,ge,2,2,"option",23,se),fl(),HI(),eC(5,Ce,2,0,"span",12),vs(6,"span",13),WC(7,"Immutable after creation."),fl()),n&2){let e=mC(2);Tg("formControl",e.agentConfigIdControl),$I(),XE(3),iC(e.availableAgentConfigs()),XE(2),tC(e.agentConfigIdControl.invalid&&e.agentConfigIdControl.touched?5:-1);}}function ye(n,t){n&1&&(vs(0,"span",12),WC(1,"Opening message is required."),fl());}function be(n,t){if(n&1&&(vs(0,"option",23),WC(1),fl()),n&2){let e=t.$implicit;Tg("value",e.value),XE(),Zg(e.label);}}function xe(n,t){if(n&1){let e=dC();vs(0,"label",46)(1,"input",47),Ag("change",function(){let h=If(e).$implicit,P=mC(3);return wf(P.toggleDay(h.value))}),fl(),vs(2,"span",48),WC(3),fl()();}if(n&2){let e=t.$implicit,l=mC(3);XE(),Tg("checked",l.isDaySelected(e.value)),XE(2),Zg(e.label);}}function Se(n,t){if(n&1&&(vs(0,"div",8)(1,"span",44),WC(2,"Days of week"),fl(),vs(3,"div",45),oC(4,xe,4,2,"label",46,A),fl(),vs(6,"span",13),WC(7,"Leave empty to run every day of the week."),fl()()),n&2){let e=mC(2);XE(4),iC(e.dayOptions);}}function Pe(n,t){n&1&&(vs(0,"span",12),WC(1,"Valid time is required (HH:mm)."),fl());}function Ee(n,t){n&1&&(vs(0,"span",12),WC(1,"Start date is required."),fl());}function Me(n,t){if(n&1&&(vs(0,"option",23),WC(1),fl()),n&2){let e=t.$implicit;Tg("value",e.value),XE(),Zg(e.label);}}function Oe(n,t){n&1&&(vs(0,"span",12),WC(1,"End date is required."),fl());}function De(n,t){if(n&1&&(vs(0,"div",8)(1,"label",49),WC(2," End date "),vs(3,"span",10),WC(4,"*"),fl()(),bg(5,"input",50),HI(),eC(6,Oe,2,0,"span",12),fl()),n&2){let e=mC(2);XE(5),Hg("scheduled-prompt-form__input--invalid",e.form.hasError("endDateRequired")&&e.endDateControl.touched),Tg("formControl",e.endDateControl),$I(),XE(),tC(e.form.hasError("endDateRequired")&&e.endDateControl.touched?6:-1);}}function Te(n,t){n&1&&(vs(0,"span",12),WC(1,"Must be at least 1."),fl());}function we(n,t){if(n&1&&(vs(0,"div",8)(1,"label",51),WC(2," Number of occurrences "),vs(3,"span",10),WC(4,"*"),fl()(),bg(5,"input",52),HI(),eC(6,Te,2,0,"span",12),fl()),n&2){let e=mC(2);XE(5),Hg("scheduled-prompt-form__input--invalid",e.form.hasError("occurrenceCountRequired")&&e.occurrenceCountControl.touched),Tg("formControl",e.occurrenceCountControl),$I(),XE(),tC(e.form.hasError("occurrenceCountRequired")&&e.occurrenceCountControl.touched?6:-1);}}function ke(n,t){if(n&1&&(vs(0,"p",36),WC(1),fl()),n&2){let e=mC(2);XE(),Zg(e.errorMessage());}}function Fe(n,t){if(n&1){let e=dC();vs(0,"form",7),Ag("ngSubmit",function(){If(e);let h=mC();return wf(h.submit())}),vs(1,"div",8)(2,"label",9),WC(3," Name "),vs(4,"span",10),WC(5,"*"),fl()(),bg(6,"input",11),HI(),eC(7,ue,2,0,"span",12),vs(8,"span",13),WC(9,'Free-form name (e.g. "Weekly Report"). Cannot be changed after creation.'),fl()(),vs(10,"div",8)(11,"label",14),WC(12,"Description"),fl(),bg(13,"input",15),HI(),fl(),vs(14,"div",8)(15,"label",16),WC(16," Agent Config "),vs(17,"span",10),WC(18,"*"),fl()(),eC(19,fe,4,1)(20,he,3,1,"p",13)(21,ve,8,2),fl(),vs(22,"div",8)(23,"label",17),WC(24," Opening message "),vs(25,"span",10),WC(26,"*"),fl()(),bg(27,"textarea",18),HI(),eC(28,ye,2,0,"span",12),vs(29,"span",13),WC(30," The message sent to the agent when the scheduled prompt fires. "),fl()(),vs(31,"fieldset",19)(32,"legend",20),WC(33,"Recurrence"),fl(),vs(34,"div",8)(35,"label",21),WC(36," Unit "),vs(37,"span",10),WC(38,"*"),fl()(),vs(39,"select",22),oC(40,be,2,2,"option",23,A),fl(),HI(),fl(),eC(42,Se,8,0,"div",8),vs(43,"div",8)(44,"label",24),WC(45," Time (UTC) "),vs(46,"span",10),WC(47,"*"),fl()(),vs(48,"div",25),bg(49,"input",26),HI(),vs(50,"span",27),WC(51,"UTC"),fl()(),eC(52,Pe,2,0,"span",12),fl()(),vs(53,"fieldset",19)(54,"legend",20),WC(55,"Planning"),fl(),vs(56,"div",8)(57,"label",28),WC(58," Start date "),vs(59,"span",10),WC(60,"*"),fl()(),bg(61,"input",29),HI(),eC(62,Ee,2,0,"span",12),fl(),vs(63,"div",8)(64,"label",30),WC(65," Ends "),vs(66,"span",10),WC(67,"*"),fl()(),vs(68,"select",31),oC(69,Me,2,2,"option",23,A),fl(),HI(),fl(),eC(71,De,7,4,"div",8),eC(72,we,7,4,"div",8),fl(),vs(73,"div",8)(74,"label",32),bg(75,"input",33),HI(),vs(76,"span",34),WC(77,"Enabled"),fl()(),vs(78,"p",35),WC(79," When disabled, the scheduled prompt is saved but will not run on schedule. "),fl()(),eC(80,ke,2,1,"p",36),vs(81,"div",37)(82,"button",38),WC(83),fl(),vs(84,"button",39),Ag("click",function(){If(e);let h=mC();return wf(h.cancel())}),WC(85,"Cancel"),fl()()();}if(n&2){let e=mC();Tg("formGroup",e.form),XE(6),Hg("scheduled-prompt-form__input--invalid",e.nameControl.invalid&&e.nameControl.touched),Tg("formControl",e.nameControl),$I(),XE(),tC(e.nameControl.invalid&&e.nameControl.touched?7:-1),XE(6),Tg("formControl",e.descriptionControl),$I(),XE(6),tC(e.isEditMode()?19:e.availableAgentConfigs().length===0?20:21),XE(8),Hg("scheduled-prompt-form__textarea--invalid",e.promptContentControl.invalid&&e.promptContentControl.touched),Tg("formControl",e.promptContentControl),$I(),XE(),tC(e.promptContentControl.invalid&&e.promptContentControl.touched?28:-1),XE(11),Tg("formControl",e.unitControl),$I(),XE(),iC(e.schedulerUnits),XE(2),tC(e.showDayFilter()?42:-1),XE(7),Tg("formControl",e.timeUtcControl),$I(),XE(3),tC(e.timeUtcControl.invalid&&e.timeUtcControl.touched?52:-1),XE(9),Hg("scheduled-prompt-form__input--invalid",e.startDateControl.invalid&&e.startDateControl.touched),Tg("formControl",e.startDateControl),$I(),XE(),tC(e.startDateControl.invalid&&e.startDateControl.touched?62:-1),XE(6),Tg("formControl",e.endTypeControl),$I(),XE(),iC(e.endTypes),XE(2),tC(e.showEndDate()?71:-1),XE(),tC(e.showOccurrenceCount()?72:-1),XE(3),Tg("formControl",e.enabledControl),$I(),XE(5),tC(e.errorMessage()?80:-1),XE(2),Tg("disabled",e.form.invalid||e.isSubmitting()),XE(),yl(" ",e.isEditMode()?"Save changes":"Create scheduled prompt"," ");}}var me=class n{route=g(V);router=g(G);destroyRef=g(we$1);state=g(c);agentConfigController=g(M);namespaceId=this.route.snapshot.params.namespaceId;isPlatformMode=!this.namespaceId;form=new z({name:new _t("",{nonNullable:true,validators:[_e$1.required]}),description:new _t(null),agentConfigId:new _t("",{nonNullable:true,validators:[_e$1.required]}),promptContent:new _t("",{nonNullable:true,validators:[_e$1.required]}),unit:new _t(fe$1.WEEK,{nonNullable:true,validators:[_e$1.required]}),days:new _t([],{nonNullable:true}),timeUtc:new _t("09:00",{nonNullable:true,validators:[_e$1.required,_e$1.pattern(/^([01]\d|2[0-3]):[0-5]\d$/)]}),startDate:new _t("",{nonNullable:true,validators:[_e$1.required]}),endType:new _t(he$1.NEVER,{nonNullable:true,validators:[_e$1.required]}),endDate:new _t(null),occurrenceCount:new _t(null),enabled:new _t(true,{nonNullable:true})},{validators:[Ne,Ie]});get nameControl(){return this.form.controls.name}get descriptionControl(){return this.form.controls.description}get agentConfigIdControl(){return this.form.controls.agentConfigId}get promptContentControl(){return this.form.controls.promptContent}get unitControl(){return this.form.controls.unit}get daysControl(){return this.form.controls.days}get timeUtcControl(){return this.form.controls.timeUtc}get startDateControl(){return this.form.controls.startDate}get endTypeControl(){return this.form.controls.endType}get endDateControl(){return this.form.controls.endDate}get occurrenceCountControl(){return this.form.controls.occurrenceCount}get enabledControl(){return this.form.controls.enabled}isEditMode=Hi(false);isSubmitting=Hi(false);isLoading=Hi(false);errorMessage=Hi(null);SchedulerUnit=fe$1;SchedulerEndType=he$1;schedulerUnits=[{value:fe$1.WEEK,label:"Week(s)"},{value:fe$1.MONTH,label:"Month(s)"}];endTypes=[{value:he$1.NEVER,label:"Never"},{value:he$1.ON_DATE,label:"On date"},{value:he$1.OCCURRENCES,label:"After N occurrences"}];dayOptions=Object.entries(ge$1).map(([t,e])=>({value:t,label:e}));unitSignal=F(this.unitControl.valueChanges.pipe(bd(this.unitControl.value)));endTypeSignal=F(this.endTypeControl.valueChanges.pipe(bd(this.endTypeControl.value)));showDayFilter=mT(()=>this.unitSignal()===fe$1.WEEK);showEndDate=mT(()=>this.endTypeSignal()===he$1.ON_DATE);showOccurrenceCount=mT(()=>this.endTypeSignal()===he$1.OCCURRENCES);agentConfigs=Hi([]);availableAgentConfigs=this.agentConfigs.asReadonly();existingPrompt=null;ngOnInit(){this.startDateControl.setValue(Ve());let t=this.route.snapshot.paramMap.get("scheduledPromptId");t?(this.isEditMode.set(true),this.loadPromptAndResources(t)):this.loadResources();}loadPromptAndResources(t){this.isLoading.set(true),By({prompt:this.state.getById(t),agentConfigs:this.agentConfigs$()}).pipe(U(this.destroyRef)).subscribe({next:({prompt:e,agentConfigs:l})=>{this.existingPrompt=e,this.agentConfigs.set(l),this.hydrateForm(e),this.isLoading.set(false);},error:()=>{this.isLoading.set(false),this.navigateBack();}});}loadResources(){this.agentConfigs$().pipe(U(this.destroyRef)).subscribe(t=>this.agentConfigs.set(t));}agentConfigs$(){return (this.isPlatformMode?this.agentConfigController.listPlatformAgentsAgentConfig():this.agentConfigController.listByParentAgentConfig(this.namespaceId)).pipe(ga(()=>ha([])))}hydrateForm(t){this.nameControl.setValue(t.name),this.descriptionControl.setValue(t.description??null),this.agentConfigIdControl.setValue(t.agentConfigId),this.promptContentControl.setValue(t.promptContent),this.unitControl.setValue(t.recurrence.unit),this.daysControl.setValue(t.recurrence.days??[]),this.timeUtcControl.setValue(t.recurrence.timeUtc),this.startDateControl.setValue(t.planning.startDate),this.endTypeControl.setValue(t.planning.endType),this.endDateControl.setValue(t.planning.endDate??null),this.occurrenceCountControl.setValue(t.planning.maxOccurrenceCount??null),this.enabledControl.setValue(t.enabled);}isDaySelected(t){return this.daysControl.value.includes(t)}toggleDay(t){let e=this.daysControl.value,l=e.includes(t)?e.filter(h=>h!==t):[...e,t];this.daysControl.setValue(l);}resolveAgentConfigName(t){return this.agentConfigs().find(e=>e.id===t)?.name??t}submit(){if(this.form.invalid||this.isSubmitting())return;this.isSubmitting.set(true),this.errorMessage.set(null);let t=this.isEditMode()&&!!this.existingPrompt?.id,e=this.endTypeControl.value,l=z$1(P({},this.existingPrompt??{}),{namespaceId:this.namespaceId??null,name:this.nameControl.value.trim(),description:this.descriptionControl.value?.trim()||void 0,agentConfigId:t?this.existingPrompt.agentConfigId:this.agentConfigIdControl.value,promptContent:this.promptContentControl.value.trim(),recurrence:{unit:this.unitControl.value,days:this.daysControl.value,timeUtc:this.timeUtcControl.value},planning:{startDate:this.startDateControl.value,endType:e,endDate:e===he$1.ON_DATE?this.endDateControl.value??void 0:void 0,maxOccurrenceCount:e===he$1.OCCURRENCES?this.occurrenceCountControl.value??void 0:void 0},enabled:this.enabledControl.value});(t?this.state.update(this.existingPrompt.id,l):this.state.create(l)).pipe(U(this.destroyRef)).subscribe({next:()=>this.navigateBack(),error:P=>{this.isSubmitting.set(false),P.status===409?this.errorMessage.set(`A scheduled prompt named "${l.name}" already exists in this scope.`):P.status===400?this.errorMessage.set(P.error?.message??"Invalid scheduled prompt data."):this.errorMessage.set("An unexpected error occurred. Please try again.");}});}cancel(){this.navigateBack();}navigateBack(){this.isPlatformMode?this.router.navigate(["/agentos","admin","scheduled-prompts"]):this.router.navigate(["/agentos",this.namespaceId,"scheduled-prompts"]);}static \u0275fac=function(e){return new(e||n)};static \u0275cmp=Aw({type:n,selectors:[["agentos-scheduled-prompt-form"]],decls:10,vars:3,consts:[[1,"scheduled-prompt-form"],[1,"scheduled-prompt-form__header"],["type","button","title","Back to scheduled prompts",1,"scheduled-prompt-form__back",3,"click"],[1,"scheduled-prompt-form__back-icon"],[1,"scheduled-prompt-form__title"],[1,"scheduled-prompt-form__loading"],[1,"scheduled-prompt-form__form",3,"formGroup"],[1,"scheduled-prompt-form__form",3,"ngSubmit","formGroup"],[1,"scheduled-prompt-form__field"],["for","sp-name",1,"scheduled-prompt-form__label"],["aria-hidden","true"],["id","sp-name","type","text","placeholder","e.g. Weekly Report","autocomplete","off",1,"scheduled-prompt-form__input",3,"formControl"],[1,"scheduled-prompt-form__field-error"],[1,"scheduled-prompt-form__field-hint"],["for","sp-description",1,"scheduled-prompt-form__label"],["id","sp-description","type","text","placeholder","Optional \u2014 short description","autocomplete","off",1,"scheduled-prompt-form__input",3,"formControl"],["for","sp-agent-config",1,"scheduled-prompt-form__label"],["for","sp-prompt-content",1,"scheduled-prompt-form__label"],["id","sp-prompt-content","rows","6","placeholder","Enter the message sent to the agent when the scheduled prompt fires\u2026",1,"scheduled-prompt-form__textarea",3,"formControl"],[1,"scheduled-prompt-form__fieldset"],[1,"scheduled-prompt-form__legend"],["for","sp-unit",1,"scheduled-prompt-form__label"],["id","sp-unit",1,"scheduled-prompt-form__select",3,"formControl"],[3,"value"],["for","sp-time",1,"scheduled-prompt-form__label"],[1,"scheduled-prompt-form__time-wrapper"],["id","sp-time","type","time",1,"scheduled-prompt-form__input","scheduled-prompt-form__input--time",3,"formControl"],[1,"scheduled-prompt-form__utc-badge"],["for","sp-start-date",1,"scheduled-prompt-form__label"],["id","sp-start-date","type","date",1,"scheduled-prompt-form__input",3,"formControl"],["for","sp-end-type",1,"scheduled-prompt-form__label"],["id","sp-end-type",1,"scheduled-prompt-form__select",3,"formControl"],[1,"scheduled-prompt-form__toggle-label"],["type","checkbox",1,"scheduled-prompt-form__toggle-checkbox",3,"formControl"],[1,"scheduled-prompt-form__toggle-text"],[1,"scheduled-prompt-form__toggle-hint"],[1,"scheduled-prompt-form__error"],[1,"scheduled-prompt-form__actions"],["type","submit",1,"scheduled-prompt-form__btn","scheduled-prompt-form__btn--primary",3,"disabled"],["type","button",1,"scheduled-prompt-form__btn",3,"click"],[1,"scheduled-prompt-form__readonly-value"],[3,"href"],["id","sp-agent-config",1,"scheduled-prompt-form__select",3,"formControl"],["value","","disabled",""],[1,"scheduled-prompt-form__label"],[1,"scheduled-prompt-form__day-grid"],[1,"scheduled-prompt-form__day-label"],["type","checkbox",1,"scheduled-prompt-form__day-checkbox",3,"change","checked"],[1,"scheduled-prompt-form__day-text"],["for","sp-end-date",1,"scheduled-prompt-form__label"],["id","sp-end-date","type","date",1,"scheduled-prompt-form__input",3,"formControl"],["for","sp-occurrence-count",1,"scheduled-prompt-form__label"],["id","sp-occurrence-count","type","number","min","1",1,"scheduled-prompt-form__input","scheduled-prompt-form__input--number",3,"formControl"]],template:function(e,l){e&1&&(vs(0,"div",0)(1,"header",1)(2,"button",2),Ag("click",function(){return l.cancel()}),vs(3,"span",3),WC(4,"\u2190"),fl(),WC(5),fl(),vs(6,"h1",4),WC(7),fl()(),eC(8,pe,2,0,"p",5)(9,Fe,86,26,"form",6),fl()),e&2&&(XE(5),yl(" ",l.isPlatformMode?"Platform Scheduled Prompts":"Scheduled Prompts"," "),XE(2),yl(" ",l.isEditMode()?"Edit scheduled prompt":"New scheduled prompt"," "),XE(),tC(l.isLoading()?8:9));},dependencies:[ni,Jn,Qn,ei,Ye,fn,wt,At,Zn,Xn,$t,Cn,En],styles:[".scheduled-prompt-form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:2rem;max-width:560px;margin:0 auto;padding:2rem 1rem}.scheduled-prompt-form__header[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.5rem}.scheduled-prompt-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}.scheduled-prompt-form__back[_ngcontent-%COMP%]:hover{text-decoration:underline}.scheduled-prompt-form__back-icon[_ngcontent-%COMP%]{font-size:1rem;line-height:1}.scheduled-prompt-form__title[_ngcontent-%COMP%]{margin:0;font-size:1.5rem;font-weight:600;color:var(--color-text, #1d1d1f);letter-spacing:-.02em}.scheduled-prompt-form__loading[_ngcontent-%COMP%]{color:var(--color-text-secondary, #6e6e73);font-size:.9rem;margin:0}.scheduled-prompt-form__form[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:1.25rem}.scheduled-prompt-form__field[_ngcontent-%COMP%]{display:flex;flex-direction:column;gap:.375rem}.scheduled-prompt-form__row[_ngcontent-%COMP%]{display:grid;grid-template-columns:1fr 1fr;gap:1rem}.scheduled-prompt-form__label[_ngcontent-%COMP%]{font-size:.875rem;font-weight:500;color:var(--color-text, #1d1d1f)}.scheduled-prompt-form__input[_ngcontent-%COMP%], .scheduled-prompt-form__select[_ngcontent-%COMP%], .scheduled-prompt-form__textarea[_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}.scheduled-prompt-form__input[_ngcontent-%COMP%]:focus, .scheduled-prompt-form__select[_ngcontent-%COMP%]:focus, .scheduled-prompt-form__textarea[_ngcontent-%COMP%]:focus{border-color:var(--color-primary, #007aff)}.scheduled-prompt-form__input[_ngcontent-%COMP%]::placeholder, .scheduled-prompt-form__select[_ngcontent-%COMP%]::placeholder, .scheduled-prompt-form__textarea[_ngcontent-%COMP%]::placeholder{color:var(--color-text-secondary, #6e6e73)}.scheduled-prompt-form__select[_ngcontent-%COMP%]{cursor:pointer;appearance:auto}.scheduled-prompt-form__textarea[_ngcontent-%COMP%]{resize:vertical;min-height:100px;line-height:1.5}.scheduled-prompt-form__input--time[_ngcontent-%COMP%]{flex:1;min-width:0}.scheduled-prompt-form__input--number[_ngcontent-%COMP%]{max-width:120px}.scheduled-prompt-form__time-wrapper[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem}.scheduled-prompt-form__utc-badge[_ngcontent-%COMP%]{flex-shrink:0;font-size:.75rem;font-weight:600;font-family:monospace;color:var(--color-text-secondary, #6e6e73);background:var(--color-surface, rgba(0, 0, 0, .05));padding:.25rem .5rem;border-radius:4px;text-transform:uppercase;letter-spacing:.06em}.scheduled-prompt-form__fieldset[_ngcontent-%COMP%]{border:1px solid var(--color-border, rgba(0, 0, 0, .1));border-radius:8px;padding:1rem 1.25rem 1.25rem;margin:0;display:flex;flex-direction:column;gap:1.25rem}.scheduled-prompt-form__legend[_ngcontent-%COMP%]{font-size:.8125rem;font-weight:600;text-transform:uppercase;letter-spacing:.06em;color:var(--color-text-secondary, #6e6e73);padding:0 .375rem}.scheduled-prompt-form__day-grid[_ngcontent-%COMP%]{display:flex;flex-wrap:wrap;gap:.5rem}.scheduled-prompt-form__day-label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.375rem;cursor:pointer;-webkit-user-select:none;user-select:none}.scheduled-prompt-form__day-checkbox[_ngcontent-%COMP%]{width:1rem;height:1rem;flex-shrink:0;accent-color:var(--color-primary, #007aff);cursor:pointer}.scheduled-prompt-form__day-text[_ngcontent-%COMP%]{font-size:.875rem;color:var(--color-text, #1d1d1f)}.scheduled-prompt-form__hint[_ngcontent-%COMP%]{margin:0;font-size:.875rem;color:var(--color-text-secondary, #6e6e73)}.scheduled-prompt-form__hint[_ngcontent-%COMP%] a[_ngcontent-%COMP%]{color:var(--color-primary, #007aff);text-decoration:none}.scheduled-prompt-form__hint[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:hover{text-decoration:underline}.scheduled-prompt-form__error[_ngcontent-%COMP%]{font-size:.8rem;color:var(--color-error, #ff3b30);margin:0}.scheduled-prompt-form__field-error[_ngcontent-%COMP%]{font-size:.8rem;color:var(--color-error, #ff3b30)}.scheduled-prompt-form__field-hint[_ngcontent-%COMP%]{font-size:.8rem;color:var(--color-text-secondary, #6e6e73);line-height:1.4}.scheduled-prompt-form__field-hint[_ngcontent-%COMP%] a[_ngcontent-%COMP%]{color:var(--color-primary, #007aff);text-decoration:none}.scheduled-prompt-form__field-hint[_ngcontent-%COMP%] a[_ngcontent-%COMP%]:hover{text-decoration:underline}.scheduled-prompt-form__readonly-value[_ngcontent-%COMP%]{margin:0;font-size:.9375rem;color:var(--color-text, #1d1d1f);padding:.625rem .875rem;border-radius:8px;border:1px solid var(--color-border, rgba(0, 0, 0, .08));background:var(--color-surface, rgba(0, 0, 0, .03))}.scheduled-prompt-form__input--invalid[_ngcontent-%COMP%], .scheduled-prompt-form__textarea--invalid[_ngcontent-%COMP%]{border-color:var(--color-error, #ff3b30)}.scheduled-prompt-form__toggle-label[_ngcontent-%COMP%]{display:flex;align-items:center;gap:.5rem;cursor:pointer;-webkit-user-select:none;user-select:none}.scheduled-prompt-form__toggle-checkbox[_ngcontent-%COMP%]{width:1rem;height:1rem;flex-shrink:0;accent-color:var(--color-primary, #007aff);cursor:pointer}.scheduled-prompt-form__toggle-text[_ngcontent-%COMP%]{font-size:.9rem;font-weight:500;color:var(--color-text, #1d1d1f)}.scheduled-prompt-form__toggle-hint[_ngcontent-%COMP%]{margin:.25rem 0 0 1.5rem;font-size:.8rem;color:var(--color-text-secondary, #6e6e73);line-height:1.4}.scheduled-prompt-form__actions[_ngcontent-%COMP%]{display:flex;gap:.75rem;padding-top:.5rem}.scheduled-prompt-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}.scheduled-prompt-form__btn[_ngcontent-%COMP%]:hover:not(:disabled){background:var(--color-surface-hover, rgba(0, 0, 0, .04))}.scheduled-prompt-form__btn[_ngcontent-%COMP%]:disabled{opacity:.45;cursor:not-allowed}.scheduled-prompt-form__btn--primary[_ngcontent-%COMP%]{background:var(--color-primary, #007aff);border-color:var(--color-primary, #007aff);color:#fff}.scheduled-prompt-form__btn--primary[_ngcontent-%COMP%]:hover:not(:disabled){background:var(--color-primary-hover, #0051d5);border-color:var(--color-primary-hover, #0051d5)}"]})};function Ne(n){let t=n.get("endType")?.value,e=n.get("endDate")?.value;return t===he$1.ON_DATE&&!e?{endDateRequired:true}:null}function Ie(n){let t=n.get("endType")?.value,e=n.get("occurrenceCount")?.value;return t===he$1.OCCURRENCES&&(e==null||e<1)?{occurrenceCountRequired:true}:null}function Ve(){let n=new Date,t=n.getFullYear(),e=String(n.getMonth()+1).padStart(2,"0"),l=String(n.getDate()).padStart(2,"0");return `${t}-${e}-${l}`}export{me as ScheduledPromptFormComponent};
@@ -31,5 +31,5 @@
31
31
  <style>:root{--color-bg:#f5f6f8;--color-bg-solid:#f5f6f8;--color-bg-secondary:rgba(255, 255, 255, .7);--color-bg-secondary-rgb:255 255 255;--color-text:#1d1d1f;--color-text-secondary:#6e6e73;--color-text-inverse:#ffffff;--color-text-tertiary:#a1a1a6;--color-primary:#007aff;--color-primary-hover:#0051d5;--color-accent:#8b5cf6;--color-link:#007aff;--color-border:rgba(0, 0, 0, .1);--color-border-light:rgba(40, 40, 40, .08);--color-input-bg:rgba(255, 255, 255, .8);--color-bg-hover:rgba(0, 0, 0, .04);--color-success:#34c759;--color-success-bg:#e3f5e1;--color-error:#ff3b30;--color-warning:#ff9500;--color-info:#5ac8fa;--color-message-user:rgba(0, 122, 255, .1);--color-message-ai:rgba(255, 255, 255, .8);--color-code-bg:rgba(142, 142, 147, .12);--color-code-text:#ff375f;--glass-bg:rgba(255, 255, 255, .72);--glass-border:rgba(255, 255, 255, .18);--glass-shadow:0 8px 32px 0 rgba(31, 38, 135, .15);--glass-backdrop-blur:blur(20px);--color-modal-bg:#ffffff;--color-surface:#ffffff;--color-modal-border:rgba(0, 0, 0, .12);--color-modal-shadow:0 8px 40px rgba(0, 0, 0, .18), 0 2px 8px rgba(0, 0, 0, .1);--color-shadow:rgba(0, 0, 0, .08);--color-overlay:rgba(0, 0, 0, .4);--color-surface-hover:var(--color-bg-hover);--color-surface-secondary:rgba(0, 0, 0, .03);--color-surface-muted:rgba(0, 0, 0, .05);--color-divider:rgba(0, 0, 0, .1)}@media print{html,body,app-root{height:auto!important;max-height:none!important;min-height:auto!important;overflow:visible!important;position:static!important}body{background:#fff!important;color:#000!important;font-family:-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,sans-serif!important;font-size:11pt;line-height:1.6;padding:1rem!important}*{animation:none!important;transition:none!important;box-shadow:none!important;text-shadow:none!important}}*{box-sizing:border-box}html{color-scheme:light}html{--mat-sys-background:light-dark(#faf9fd, #121316);--mat-sys-error:light-dark(#ba1a1a, #ffb4ab);--mat-sys-error-container:light-dark(#ffdad6, #93000a);--mat-sys-inverse-on-surface:light-dark(#f2f0f4, #2f3033);--mat-sys-inverse-primary:light-dark(#abc7ff, #005cbb);--mat-sys-inverse-surface:light-dark(#2f3033, #e3e2e6);--mat-sys-on-background:light-dark(#1a1b1f, #e3e2e6);--mat-sys-on-error:light-dark(#ffffff, #690005);--mat-sys-on-error-container:light-dark(#93000a, #ffdad6);--mat-sys-on-primary:light-dark(#ffffff, #002f65);--mat-sys-on-primary-container:light-dark(#00458f, #d7e3ff);--mat-sys-on-primary-fixed:light-dark(#001b3f, #001b3f);--mat-sys-on-primary-fixed-variant:light-dark(#00458f, #00458f);--mat-sys-on-secondary:light-dark(#ffffff, #283041);--mat-sys-on-secondary-container:light-dark(#3e4759, #dae2f9);--mat-sys-on-secondary-fixed:light-dark(#131c2b, #131c2b);--mat-sys-on-secondary-fixed-variant:light-dark(#3e4759, #3e4759);--mat-sys-on-surface:light-dark(#1a1b1f, #e3e2e6);--mat-sys-on-surface-variant:light-dark(#44474e, #e0e2ec);--mat-sys-on-tertiary:light-dark(#ffffff, #002f65);--mat-sys-on-tertiary-container:light-dark(#00458f, #d7e3ff);--mat-sys-on-tertiary-fixed:light-dark(#001b3f, #001b3f);--mat-sys-on-tertiary-fixed-variant:light-dark(#00458f, #00458f);--mat-sys-outline:light-dark(#74777f, #8e9099);--mat-sys-outline-variant:light-dark(#c4c6d0, #44474e);--mat-sys-primary:light-dark(#005cbb, #abc7ff);--mat-sys-primary-container:light-dark(#d7e3ff, #00458f);--mat-sys-primary-fixed:light-dark(#d7e3ff, #d7e3ff);--mat-sys-primary-fixed-dim:light-dark(#abc7ff, #abc7ff);--mat-sys-scrim:light-dark(#000000, #000000);--mat-sys-secondary:light-dark(#565e71, #bec6dc);--mat-sys-secondary-container:light-dark(#dae2f9, #3e4759);--mat-sys-secondary-fixed:light-dark(#dae2f9, #dae2f9);--mat-sys-secondary-fixed-dim:light-dark(#bec6dc, #bec6dc);--mat-sys-shadow:light-dark(#000000, #000000);--mat-sys-surface:light-dark(#faf9fd, #121316);--mat-sys-surface-bright:light-dark(#faf9fd, #38393c);--mat-sys-surface-container:light-dark(#efedf0, #1f2022);--mat-sys-surface-container-high:light-dark(#e9e7eb, #292a2c);--mat-sys-surface-container-highest:light-dark(#e3e2e6, #343537);--mat-sys-surface-container-low:light-dark(#f4f3f6, #1a1b1f);--mat-sys-surface-container-lowest:light-dark(#ffffff, #0d0e11);--mat-sys-surface-dim:light-dark(#dbd9dd, #121316);--mat-sys-surface-tint:light-dark(#005cbb, #abc7ff);--mat-sys-surface-variant:light-dark(#e0e2ec, #44474e);--mat-sys-tertiary:light-dark(#005cbb, #abc7ff);--mat-sys-tertiary-container:light-dark(#d7e3ff, #00458f);--mat-sys-tertiary-fixed:light-dark(#d7e3ff, #d7e3ff);--mat-sys-tertiary-fixed-dim:light-dark(#abc7ff, #abc7ff);--mat-sys-neutral-variant20:#2d3038;--mat-sys-neutral10:#1a1b1f;--mat-sys-level0:0px 0px 0px 0px rgba(0, 0, 0, .2), 0px 0px 0px 0px rgba(0, 0, 0, .14), 0px 0px 0px 0px rgba(0, 0, 0, .12);--mat-sys-level1:0px 2px 1px -1px rgba(0, 0, 0, .2), 0px 1px 1px 0px rgba(0, 0, 0, .14), 0px 1px 3px 0px rgba(0, 0, 0, .12);--mat-sys-level2:0px 3px 3px -2px rgba(0, 0, 0, .2), 0px 3px 4px 0px rgba(0, 0, 0, .14), 0px 1px 8px 0px rgba(0, 0, 0, .12);--mat-sys-level3:0px 3px 5px -1px rgba(0, 0, 0, .2), 0px 6px 10px 0px rgba(0, 0, 0, .14), 0px 1px 18px 0px rgba(0, 0, 0, .12);--mat-sys-level4:0px 5px 5px -3px rgba(0, 0, 0, .2), 0px 8px 10px 1px rgba(0, 0, 0, .14), 0px 3px 14px 2px rgba(0, 0, 0, .12);--mat-sys-level5:0px 7px 8px -4px rgba(0, 0, 0, .2), 0px 12px 17px 2px rgba(0, 0, 0, .14), 0px 5px 22px 4px rgba(0, 0, 0, .12);--mat-sys-body-large:400 1rem / 1.5rem -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-body-large-font:-apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-body-large-line-height:1.5rem;--mat-sys-body-large-size:1rem;--mat-sys-body-large-tracking:.031rem;--mat-sys-body-large-weight:400;--mat-sys-body-medium:400 .875rem / 1.25rem -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-body-medium-font:-apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-body-medium-line-height:1.25rem;--mat-sys-body-medium-size:.875rem;--mat-sys-body-medium-tracking:.016rem;--mat-sys-body-medium-weight:400;--mat-sys-body-small:400 .75rem / 1rem -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-body-small-font:-apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-body-small-line-height:1rem;--mat-sys-body-small-size:.75rem;--mat-sys-body-small-tracking:.025rem;--mat-sys-body-small-weight:400;--mat-sys-display-large:400 3.562rem / 4rem -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-display-large-font:-apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-display-large-line-height:4rem;--mat-sys-display-large-size:3.562rem;--mat-sys-display-large-tracking:-.016rem;--mat-sys-display-large-weight:400;--mat-sys-display-medium:400 2.812rem / 3.25rem -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-display-medium-font:-apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-display-medium-line-height:3.25rem;--mat-sys-display-medium-size:2.812rem;--mat-sys-display-medium-tracking:0;--mat-sys-display-medium-weight:400;--mat-sys-display-small:400 2.25rem / 2.75rem -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-display-small-font:-apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-display-small-line-height:2.75rem;--mat-sys-display-small-size:2.25rem;--mat-sys-display-small-tracking:0;--mat-sys-display-small-weight:400;--mat-sys-headline-large:400 2rem / 2.5rem -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-headline-large-font:-apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-headline-large-line-height:2.5rem;--mat-sys-headline-large-size:2rem;--mat-sys-headline-large-tracking:0;--mat-sys-headline-large-weight:400;--mat-sys-headline-medium:400 1.75rem / 2.25rem -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-headline-medium-font:-apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-headline-medium-line-height:2.25rem;--mat-sys-headline-medium-size:1.75rem;--mat-sys-headline-medium-tracking:0;--mat-sys-headline-medium-weight:400;--mat-sys-headline-small:400 1.5rem / 2rem -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-headline-small-font:-apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-headline-small-line-height:2rem;--mat-sys-headline-small-size:1.5rem;--mat-sys-headline-small-tracking:0;--mat-sys-headline-small-weight:400;--mat-sys-label-large:500 .875rem / 1.25rem -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-label-large-font:-apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-label-large-line-height:1.25rem;--mat-sys-label-large-size:.875rem;--mat-sys-label-large-tracking:.006rem;--mat-sys-label-large-weight:500;--mat-sys-label-large-weight-prominent:700;--mat-sys-label-medium:500 .75rem / 1rem -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-label-medium-font:-apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-label-medium-line-height:1rem;--mat-sys-label-medium-size:.75rem;--mat-sys-label-medium-tracking:.031rem;--mat-sys-label-medium-weight:500;--mat-sys-label-medium-weight-prominent:700;--mat-sys-label-small:500 .688rem / 1rem -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-label-small-font:-apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-label-small-line-height:1rem;--mat-sys-label-small-size:.688rem;--mat-sys-label-small-tracking:.031rem;--mat-sys-label-small-weight:500;--mat-sys-title-large:400 1.375rem / 1.75rem -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-title-large-font:-apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-title-large-line-height:1.75rem;--mat-sys-title-large-size:1.375rem;--mat-sys-title-large-tracking:0;--mat-sys-title-large-weight:400;--mat-sys-title-medium:500 1rem / 1.5rem -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-title-medium-font:-apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-title-medium-line-height:1.5rem;--mat-sys-title-medium-size:1rem;--mat-sys-title-medium-tracking:.009rem;--mat-sys-title-medium-weight:500;--mat-sys-title-small:500 .875rem / 1.25rem -apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-title-small-font:-apple-system, BlinkMacSystemFont, "SF Pro Display", "Segoe UI", "Helvetica Neue", Arial, sans-serif;--mat-sys-title-small-line-height:1.25rem;--mat-sys-title-small-size:.875rem;--mat-sys-title-small-tracking:.006rem;--mat-sys-title-small-weight:500;--mat-sys-corner-extra-large:28px;--mat-sys-corner-extra-large-top:28px 28px 0 0;--mat-sys-corner-extra-small:4px;--mat-sys-corner-extra-small-top:4px 4px 0 0;--mat-sys-corner-full:9999px;--mat-sys-corner-large:16px;--mat-sys-corner-large-end:0 16px 16px 0;--mat-sys-corner-large-start:16px 0 0 16px;--mat-sys-corner-large-top:16px 16px 0 0;--mat-sys-corner-medium:12px;--mat-sys-corner-none:0;--mat-sys-corner-small:8px;--mat-sys-dragged-state-layer-opacity:.16;--mat-sys-focus-state-layer-opacity:.12;--mat-sys-hover-state-layer-opacity:.08;--mat-sys-pressed-state-layer-opacity:.12;--mat-snack-bar-container-shape:transparent;--mat-snack-bar-container-color:transparent;--mat-snack-bar-supporting-text-color:var(--color-text)}html,body{margin:0;padding:0;width:100%;height:100%}body{background:var(--color-bg);color:var(--color-text);font-family:-apple-system,BlinkMacSystemFont,SF Pro Display,Segoe UI,Helvetica Neue,Arial,sans-serif;transition:background .3s ease,color .3s ease;-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale;padding:0!important}</style><link rel="stylesheet" href="styles-HDA2O7OH.css" media="print" onload="this.media='all'"><noscript><link rel="stylesheet" href="styles-HDA2O7OH.css"></noscript></head>
32
32
  <body>
33
33
  <app-root></app-root>
34
- <script src="polyfills-2FSRUXKO.js" type="module"></script><script src="main-XVJVH4GF.js" type="module"></script></body>
34
+ <script src="polyfills-2FSRUXKO.js" type="module"></script><script src="main-FEA3BAHM.js" type="module"></script></body>
35
35
  </html>
@@ -1808,4 +1808,4 @@ var m$1="coday_oauth_callback",d=class r{route=g$3(V$3);message="Authentication
1808
1808
  .mat-mdc-dialog-component-host {
1809
1809
  display: contents;
1810
1810
  }
1811
- `],encapsulation:2,changeDetection:1})}return i})(),Fe$1="--mat-dialog-transition-duration";function Le$1(i){return i==null?null:typeof i=="number"?i:i.endsWith("ms")?fn$1(i.substring(0,i.length-2)):i.endsWith("s")?fn$1(i.substring(0,i.length-1))*1e3:i==="0"?0:null}var N=(function(i){return i[i.OPEN=0]="OPEN",i[i.CLOSING=1]="CLOSING",i[i.CLOSED=2]="CLOSED",i})(N||{}),z=class{_ref;_config;_containerInstance;componentInstance;componentRef=null;disableClose;id;_afterOpened=new Mr(1);_beforeClosed=new Mr(1);_result;_closeFallbackTimeout;_state=N.OPEN;_closeInteractionType;constructor(a,e,t){this._ref=a,this._config=e,this._containerInstance=t,this.disableClose=e.disableClose,this.id=a.id,a.addPanelClass("mat-mdc-dialog-panel"),t._animationStateChanged.pipe(Ot$3(n=>n.state==="opened"),sn$2(1)).subscribe(()=>{this._afterOpened.next(),this._afterOpened.complete();}),t._animationStateChanged.pipe(Ot$3(n=>n.state==="closed"),sn$2(1)).subscribe(()=>{clearTimeout(this._closeFallbackTimeout),this._finishDialogClose();}),a.overlayRef.detachments().subscribe(()=>{this._beforeClosed.next(this._result),this._beforeClosed.complete(),this._finishDialogClose();}),Yy(this.backdropClick(),this.keydownEvents().pipe(Ot$3(n=>n.keyCode===27&&!this.disableClose&&!Ve$2(n)))).subscribe(n=>{this.disableClose||(n.preventDefault(),qe$1(this,n.type==="keydown"?"keyboard":"mouse"));});}close(a){let e=this._config.closePredicate;e&&!e(a,this._config,this.componentInstance)||(this._result=a,this._containerInstance._animationStateChanged.pipe(Ot$3(t=>t.state==="closing"),sn$2(1)).subscribe(t=>{this._beforeClosed.next(a),this._beforeClosed.complete(),this._ref.overlayRef.detachBackdrop(),this._closeFallbackTimeout=setTimeout(()=>this._finishDialogClose(),t.totalTime+100);}),this._state=N.CLOSING,this._containerInstance._startExitAnimation());}afterOpened(){return this._afterOpened}afterClosed(){return this._ref.closed}beforeClosed(){return this._beforeClosed}backdropClick(){return this._ref.backdropClick}keydownEvents(){return this._ref.keydownEvents}updatePosition(a){let e=this._ref.config.positionStrategy;return a&&(a.left||a.right)?a.left?e.left(a.left):e.right(a.right):e.centerHorizontally(),a&&(a.top||a.bottom)?a.top?e.top(a.top):e.bottom(a.bottom):e.centerVertically(),this._ref.updatePosition(),this}updateSize(a="",e=""){return this._ref.updateSize(a,e),this}addPanelClass(a){return this._ref.addPanelClass(a),this}removePanelClass(a){return this._ref.removePanelClass(a),this}getState(){return this._state}_finishDialogClose(){this._state=N.CLOSED,this._ref.close(this._result,{focusOrigin:this._closeInteractionType}),this.componentInstance=null;}};function qe$1(i,a,e){return i._closeInteractionType=a,i.close(e)}var Ue$1=new w("MatMdcDialogData"),Ye=new w("mat-mdc-dialog-default-options"),Ze$1=new w("mat-mdc-dialog-scroll-strategy",{providedIn:"root",factory:()=>{let i=g$3(pe$3);return ()=>Kt(i)}}),Re$1=(()=>{class i{_defaultOptions=g$3(Ye,{optional:true});_scrollStrategy=g$3(Ze$1);_parentDialog=g$3(i,{optional:true,skipSelf:true});_idGenerator=g$3(Ut$1);_injector=g$3(pe$3);_dialog=g$3(X);_animationsDisabled=K$1();_openDialogsAtThisLevel=[];_afterAllClosedAtThisLevel=new ce$3;_afterOpenedAtThisLevel=new ce$3;dialogConfigClass=V$1;_dialogRefConstructor;_dialogContainerType;_dialogDataToken;get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}_getAfterAllClosed(){let e=this._parentDialog;return e?e._getAfterAllClosed():this._afterAllClosedAtThisLevel}afterAllClosed=Zy(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe(bd(void 0)));constructor(){this._dialogRefConstructor=z,this._dialogContainerType=Qe$1,this._dialogDataToken=Ue$1;}open(e,t){let n;t=P$2(P$2({},this._defaultOptions||new V$1),t),t.id=t.id||this._idGenerator.getId("mat-mdc-dialog-"),t.scrollStrategy=t.scrollStrategy||this._scrollStrategy();let o=this._dialog.open(e,z$3(P$2({},t),{positionStrategy:oe$1(this._injector).centerHorizontally().centerVertically(),disableClose:true,closePredicate:void 0,closeOnDestroy:false,closeOnOverlayDetachments:false,disableAnimations:this._animationsDisabled||t.enterAnimationDuration?.toLocaleString()==="0"||t.exitAnimationDuration?.toString()==="0",container:{type:this._dialogContainerType,providers:()=>[{provide:this.dialogConfigClass,useValue:t},{provide:g,useValue:t}]},templateContext:()=>({dialogRef:n}),providers:(l,r,d)=>(n=new this._dialogRefConstructor(l,t,d),n.updatePosition(t?.position),[{provide:this._dialogContainerType,useValue:d},{provide:this._dialogDataToken,useValue:r.data},{provide:this._dialogRefConstructor,useValue:n}])}));return n.componentRef=o.componentRef,n.componentInstance=o.componentInstance,this.openDialogs.push(n),this.afterOpened.next(n),n.afterClosed().subscribe(()=>{let l=this.openDialogs.indexOf(n);l>-1&&(this.openDialogs.splice(l,1),this.openDialogs.length||this._getAfterAllClosed().next());}),n}closeAll(){this._closeDialogs(this.openDialogs);}getDialogById(e){return this.openDialogs.find(t=>t.id===e)}ngOnDestroy(){this._closeDialogs(this._openDialogsAtThisLevel),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete();}_closeDialogs(e){let t=e.length;for(;t--;)e[t].close();}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Ce$4({token:i,factory:i.\u0275fac})}return i})();var Pe$1=(()=>{class i{_dialogRef=g$3(z,{optional:true});_elementRef=g$3(Qt$1);_dialog=g$3(Re$1);ngOnInit(){this._dialogRef||(this._dialogRef=$e$1(this._elementRef,this._dialog.openDialogs)),this._dialogRef&&Promise.resolve().then(()=>{this._onAdd();});}ngOnDestroy(){this._dialogRef?._containerInstance&&Promise.resolve().then(()=>{this._onRemove();});}static \u0275fac=function(t){return new(t||i)};static \u0275dir=ks({type:i})}return i})(),jt=(()=>{class i extends Pe$1{id=g$3(Ut$1).getId("mat-mdc-dialog-title-");_onAdd(){this._dialogRef._containerInstance?._addAriaLabelledBy?.(this.id);}_onRemove(){this._dialogRef?._containerInstance?._removeAriaLabelledBy?.(this.id);}static \u0275fac=(()=>{let e;return function(n){return (e||(e=Gp(i)))(n||i)}})();static \u0275dir=ks({type:i,selectors:[["","mat-dialog-title",""],["","matDialogTitle",""]],hostAttrs:[1,"mat-mdc-dialog-title","mdc-dialog__title"],hostVars:1,hostBindings:function(t,n){t&2&&Ng("id",n.id);},inputs:{id:"id"},exportAs:["matDialogTitle"],features:[yg]})}return i})(),Nt=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=ks({type:i,selectors:[["","mat-dialog-content",""],["mat-dialog-content"],["","matDialogContent",""]],hostAttrs:[1,"mat-mdc-dialog-content","mdc-dialog__content"],features:[jw([he$1])]})}return i})(),Vt=(()=>{class i extends Pe$1{align;_onAdd(){this._dialogRef._containerInstance?._updateActionSectionCount?.(1);}_onRemove(){this._dialogRef._containerInstance?._updateActionSectionCount?.(-1);}static \u0275fac=(()=>{let e;return function(n){return (e||(e=Gp(i)))(n||i)}})();static \u0275dir=ks({type:i,selectors:[["","mat-dialog-actions",""],["mat-dialog-actions"],["","matDialogActions",""]],hostAttrs:[1,"mat-mdc-dialog-actions","mdc-dialog__actions"],hostVars:6,hostBindings:function(t,n){t&2&&Hg("mat-mdc-dialog-actions-align-start",n.align==="start")("mat-mdc-dialog-actions-align-center",n.align==="center")("mat-mdc-dialog-actions-align-end",n.align==="end");},inputs:{align:"align"},features:[yg]})}return i})();function $e$1(i,a){let e=i.nativeElement.parentElement;for(;e&&!e.classList.contains("mat-mdc-dialog-container");)e=e.parentElement;return e?a.find(t=>t.id===e.id):null}var zt=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=Do$1({type:i});static \u0275inj=qn$3({providers:[Re$1],imports:[Se,ge$1,Yt,wt$3]})}return i})();function U$1(n){n||(n=g$3(we$1));let e=new A$1(t=>{if(n.destroyed){t.next();return}return n.onDestroy(t.next.bind(t))});return t=>t.pipe(Vy(e))}function T(n,e){let t=g$3(pe$3),o=new Mr(1),c=Hf(()=>{let r;try{r=n();}catch(i){Rn$3(()=>o.error(i));return}Rn$3(()=>o.next(r));},{injector:t,manualCleanup:true});return t.get(we$1).onDestroy(()=>{c.destroy(),o.complete();}),o.asObservable()}function F(n,e){let o=!e?.manualCleanup?e?.injector?.get(we$1)??g$3(we$1):null,c=h(e?.equal),r;e?.requireSync?r=Hi$2({kind:0},{equal:c}):r=Hi$2({kind:1,value:e?.initialValue},{equal:c});let i,v=n.subscribe({next:s=>r.set({kind:1,value:s}),error:s=>{r.set({kind:2,error:s}),i?.();},complete:()=>{i?.();}});if(e?.requireSync&&r().kind===0)throw new m$4(601,false);return i=o?.onDestroy(v.unsubscribe.bind(v)),mT(()=>{let s=r();switch(s.kind){case 1:return s.value;case 2:throw s.error;case 0:throw new m$4(601,false)}},{equal:e?.equal})}function h(n=Object.is){return (e,t)=>e.kind===1&&t.kind===1&&n(e.value,t.value)}function ui(s){return new m$4(3e3,false)}function mn(){return new m$4(3100,false)}function fn(){return new m$4(3101,false)}function pn(s){return new m$4(3001,false)}function gn(s){return new m$4(3003,false)}function yn(s){return new m$4(3004,false)}function di(s,e){return new m$4(3005,false)}function mi(){return new m$4(3006,false)}function fi(){return new m$4(3007,false)}function pi(s,e){return new m$4(3008,false)}function gi(s){return new m$4(3002,false)}function yi(s,e,t,i,n){return new m$4(3010,false)}function _i(){return new m$4(3011,false)}function Si(){return new m$4(3012,false)}function Ei(){return new m$4(3200,false)}function vi(){return new m$4(3202,false)}function Ti(){return new m$4(3013,false)}function Ai(s){return new m$4(3014,false)}function wi(s){return new m$4(3015,false)}function bi(s){return new m$4(3016,false)}function Pi(s,e){return new m$4(3404,false)}function _n(s){return new m$4(3502,false)}function Ni(s){return new m$4(3503,false)}function Ci(){return new m$4(3300,false)}function Mi(s){return new m$4(3504,false)}function Di(s){return new m$4(3301,false)}function Ri(s,e){return new m$4(3302,false)}function ki(s){return new m$4(3303,false)}function Oi(s,e){return new m$4(3400,false)}function Ii(s){return new m$4(3401,false)}function Fi(s){return new m$4(3402,false)}function Li(s,e){return new m$4(3505,false)}function V(s){switch(s.length){case 0:return new l;case 1:return s[0];default:return new u$1(s)}}function tt(s,e,t=new Map,i=new Map){let n=[],r=[],o=-1,a=null;if(e.forEach(l=>{let c=l.get("offset"),h=c==o,u=h&&a||new Map;l.forEach((_,y)=>{let m=y,g=_;if(y!=="offset")switch(m=s.normalizePropertyName(m,n),g){case g$2:g=t.get(y);break;case _$2:g=i.get(y);break;default:g=s.normalizeStyleValue(y,m,g,n);break}u.set(m,g);}),h||r.push(u),a=u,o=c;}),n.length)throw _n();return r}function Pe(s,e,t,i){switch(e){case "start":s.onStart(()=>i(t&&Ze(t,"start",s)));break;case "done":s.onDone(()=>i(t&&Ze(t,"done",s)));break;case "destroy":s.onDestroy(()=>i(t&&Ze(t,"destroy",s)));break}}function Ze(s,e,t){let i=t.totalTime,n=!!t.disabled,r=Ne(s.element,s.triggerName,s.fromState,s.toState,e||s.phaseName,i??s.totalTime,n),o=s._data;return o!=null&&(r._data=o),r}function Ne(s,e,t,i,n="",r=0,o){return {element:s,triggerName:e,fromState:t,toState:i,phaseName:n,totalTime:r,disabled:!!o}}function k(s,e,t){let i=s.get(e);return i||s.set(e,i=t),i}function it(s){let e=s.indexOf(":"),t=s.substring(1,e),i=s.slice(e+1);return [t,i]}var Sn=typeof document>"u"?null:document.documentElement;function Ce(s){let e=s.parentNode||s.host||null;return e===Sn?null:e}function En(s){return s.substring(1,6)=="ebkit"}var Z=null,hi=false;function zi(s){Z||(Z=vn()||{},hi=Z.style?"WebkitAppearance"in Z.style:false);let e=true;return Z.style&&!En(s)&&(e=s in Z.style,!e&&hi&&(e="Webkit"+s.charAt(0).toUpperCase()+s.slice(1)in Z.style)),e}function vn(){return typeof document<"u"?document.body:null}function nt(s,e){for(;e;){if(e===s)return true;e=Ce(e);}return false}function st(s,e,t){if(t)return Array.from(s.querySelectorAll(e));let i=s.querySelector(e);return i?[i]:[]}var Tn=1e3,rt="{{",An="}}",ot="ng-enter",Me="ng-leave",ue="ng-trigger",he=".ng-trigger",at="ng-animating",De=".ng-animating";function U(s){if(typeof s=="number")return s;let e=s.match(/^(-?[\.\d]+)(m?s)/);return !e||e.length<2?0:Je(parseFloat(e[1]),e[2])}function Je(s,e){return e==="s"?s*Tn:s}function de(s,e,t){return s.hasOwnProperty("duration")?s:bn(s,e,t)}var wn=/^(-?[\.\d]+)(m?s)(?:\s+(-?[\.\d]+)(m?s))?(?:\s+([-a-z]+(?:\(.+?\))?))?$/i;function bn(s,e,t){let i,n=0,r="";if(typeof s=="string"){let o=s.match(wn);if(o===null)return e.push(ui()),{duration:0,delay:0,easing:""};i=Je(parseFloat(o[1]),o[2]);let a=o[3];a!=null&&(n=Je(parseFloat(a),o[4]));let l=o[5];l&&(r=l);}else i=s;if(!t){let o=false,a=e.length;i<0&&(e.push(mn()),o=true),n<0&&(e.push(fn()),o=true),o&&e.splice(a,0,ui());}return {duration:i,delay:n,easing:r}}function Ki(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=Re(n);t&&!t.has(n)&&t.set(n,s.style[r]),s.style[r]=i;});}function W(s,e){e.forEach((t,i)=>{let n=Re(i);s.style[n]="";});}function re(s){return Array.isArray(s)?s.length==1?s[0]:y$1(s):s}function ji(s,e,t){let i=e.params||{},n=lt(s);n.length&&n.forEach(r=>{i.hasOwnProperty(r)||t.push(pn());});}var et=new RegExp(`${rt}\\s*(.+?)\\s*${An}`,"g");function lt(s){let e=[];if(typeof s=="string"){let t;for(;t=et.exec(s);)e.push(t[1]);et.lastIndex=0;}return e}function oe(s,e,t){let i=`${s}`,n=i.replace(et,(r,o)=>{let a=e[o];return a==null&&(t.push(gn()),a=""),a.toString()});return n==i?s:n}var Pn=/-+([a-z0-9])/g;function Re(s){return s.replace(Pn,(...e)=>e[1].toUpperCase())}function Bi(s,e){return s===0||e===0}function qi(s,e,t){if(t.size&&e.length){let i=e[0],n=[];if(t.forEach((r,o)=>{i.has(o)||n.push(o),i.set(o,r);}),n.length)for(let r=1;r<e.length;r++){let o=e[r];n.forEach(a=>o.set(a,ke(s,a)));}}return e}function O(s,e,t){switch(e.type){case r.Trigger:return s.visitTrigger(e,t);case r.State:return s.visitState(e,t);case r.Transition:return s.visitTransition(e,t);case r.Sequence:return s.visitSequence(e,t);case r.Group:return s.visitGroup(e,t);case r.Animate:return s.visitAnimate(e,t);case r.Keyframes:return s.visitKeyframes(e,t);case r.Style:return s.visitStyle(e,t);case r.Reference:return s.visitReference(e,t);case r.AnimateChild:return s.visitAnimateChild(e,t);case r.AnimateRef:return s.visitAnimateRef(e,t);case r.Query:return s.visitQuery(e,t);case r.Stagger:return s.visitStagger(e,t);default:throw yn(e.type)}}function ke(s,e){return window.getComputedStyle(s)[e]}var bt=(()=>{class s{validateStyleProperty(t){return zi(t)}containsElement(t,i){return nt(t,i)}getParentElement(t){return Ce(t)}query(t,i,n){return st(t,i,n)}computeStyle(t,i,n){return n||""}animate(t,i,n,r,o,a=[],l$1){return new l(n,r)}static \u0275fac=function(i){return new(i||s)};static \u0275prov=x({token:s,factory:s.\u0275fac})}return s})(),ee=class{static NOOP=new bt},te=class{};var Nn=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"]),ze=class extends te{normalizePropertyName(e,t){return Re(e)}normalizeStyleValue(e,t,i,n){let r="",o=i.toString().trim();if(Nn.has(t)&&i!==0&&i!=="0")if(typeof i=="number")r="px";else {let a=i.match(/^[+-]?[\d\.]+([a-z]*)$/);a&&a[1].length==0&&n.push(di());}return o+r}};var Ke="*";function Cn(s,e){let t=[];return typeof s=="string"?s.split(/\s*,\s*/).forEach(i=>Mn(i,t,e)):t.push(s),t}function Mn(s,e,t){if(s[0]==":"){let l=Dn(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(wi()),e;let n=i[1],r=i[2],o=i[3];e.push(Qi(n,o));let a=n==Ke&&o==Ke;r[0]=="<"&&!a&&e.push(Qi(o,n));}function Dn(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(bi()),"* => *"}}var Oe=new Set(["true","1"]),Ie=new Set(["false","0"]);function Qi(s,e){let t=Oe.has(s)||Ie.has(s),i=Oe.has(e)||Ie.has(e);return (n,r)=>{let o=s==Ke||s==n,a=e==Ke||e==r;return !o&&t&&typeof n=="boolean"&&(o=n?Oe.has(s):Ie.has(s)),!a&&i&&typeof r=="boolean"&&(a=r?Oe.has(e):Ie.has(e)),o&&a}}var Ji=":self",Rn=new RegExp(`s*${Ji}s*,?`,"g");function en(s,e,t,i){return new ft(s).build(e,t,i)}var Ui="",ft=class{_driver;constructor(e){this._driver=e;}build(e,t,i){let n=new pt(t);return this._resetContextStyleTimingState(n),O(this,re(e),n)}_resetContextStyleTimingState(e){e.currentQuerySelector=Ui,e.collectedStyles=new Map,e.collectedStyles.set(Ui,new Map),e.currentTime=0;}visitTrigger(e,t){let i=t.queryCount=0,n=t.depCount=0,r$1=[],o=[];return e.name.charAt(0)=="@"&&t.errors.push(mi()),e.definitions.forEach(a=>{if(this._resetContextStyleTimingState(t),a.type==r.State){let l=a,c=l.name;c.toString().split(/\s*,\s*/).forEach(h=>{l.name=h,r$1.push(this.visitState(l,t));}),l.name=c;}else if(a.type==r.Transition){let l=this.visitTransition(a,t);i+=l.queryCount,n+=l.depCount,o.push(l);}else t.errors.push(fi());}),{type:r.Trigger,name:e.name,states:r$1,transitions:o,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,o=n||{};i.styles.forEach(a=>{a instanceof Map&&a.forEach(l=>{lt(l).forEach(c=>{o.hasOwnProperty(c)||r.add(c);});});}),r.size&&t.errors.push(pi(e.name,[...r.values()]));}return {type:r.State,name:e.name,style:i,options:n?{params:n}:null}}visitTransition(e,t){t.queryCount=0,t.depCount=0;let i=O(this,re(e.animation),t),n=Cn(e.expr,t.errors);return {type:r.Transition,matchers:n,animation:i,queryCount:t.queryCount,depCount:t.depCount,options:J(e.options)}}visitSequence(e,t){return {type:r.Sequence,steps:e.steps.map(i=>O(this,i,t)),options:J(e.options)}}visitGroup(e,t){let i=t.currentTime,n=0,r$1=e.steps.map(o=>{t.currentTime=i;let a=O(this,o,t);return n=Math.max(n,t.currentTime),a});return t.currentTime=n,{type:r.Group,steps:r$1,options:J(e.options)}}visitAnimate(e,t){let i=Fn(e.timings,t.errors);t.currentAnimateTimings=i;let n,r$1=e.styles?e.styles:F$4({});if(r$1.type==r.Keyframes)n=this.visitKeyframes(r$1,t);else {let o=e.styles,a=false;if(!o){a=true;let c={};i.easing&&(c.easing=i.easing),o=F$4(c);}t.currentTime+=i.duration+i.delay;let l=this.visitStyle(o,t);l.isEmptyStep=a,n=l;}return t.currentAnimateTimings=null,{type:r.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 a of n)typeof a=="string"?a===_$2?i.push(a):t.errors.push(gi()):i.push(new Map(Object.entries(a)));let r$1=false,o=null;return i.forEach(a=>{if(a instanceof Map&&(a.has("easing")&&(o=a.get("easing"),a.delete("easing")),!r$1)){for(let l of a.values())if(l.toString().indexOf(rt)>=0){r$1=true;break}}}),{type:r.Style,styles:i,easing:o,offset:e.offset,containsDynamicStyles:r$1,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(o=>{typeof o!="string"&&o.forEach((a,l)=>{let c=t.collectedStyles.get(t.currentQuerySelector),h=c.get(l),u=true;h&&(r!=n&&r>=h.startTime&&n<=h.endTime&&(t.errors.push(yi(l,h.startTime,h.endTime)),u=false),r=h.startTime),u&&c.set(l,{startTime:r,endTime:n}),t.options&&ji(a,t.options,t.errors);});});}visitKeyframes(e,t){let i={type:r.Keyframes,styles:[],options:null};if(!t.currentAnimateTimings)return t.errors.push(_i()),i;let n=1,r$1=0,o=[],a=false,l=false,c=0,h=e.steps.map(w=>{let b=this._makeStyleAst(w,t),M=b.offset!=null?b.offset:In(b.styles),N=0;return M!=null&&(r$1++,N=b.offset=M),l=l||N<0||N>1,a=a||N<c,c=N,o.push(N),b});l&&t.errors.push(Si()),a&&t.errors.push(Ei());let u=e.steps.length,_=0;r$1>0&&r$1<u?t.errors.push(vi()):r$1==0&&(_=n/(u-1));let y=u-1,m=t.currentTime,g=t.currentAnimateTimings,T=g.duration;return h.forEach((w,b)=>{let M=_>0?b==y?1:_*b:o[b],N=M*T;t.currentTime=m+g.delay+N,g.duration=N,this._validateStyleAst(w,t),w.offset=M,i.styles.push(w);}),i}visitReference(e,t){return {type:r.Reference,animation:O(this,re(e.animation),t),options:J(e.options)}}visitAnimateChild(e,t){return t.depCount++,{type:r.AnimateChild,options:J(e.options)}}visitAnimateRef(e,t){return {type:r.AnimateRef,animation:this.visitReference(e.animation,t),options:J(e.options)}}visitQuery(e,t){let i=t.currentQuerySelector,n=e.options||{};t.queryCount++,t.currentQuery=e;let[r$1,o]=kn(e.selector);t.currentQuerySelector=i.length?i+" "+r$1:r$1,k(t.collectedStyles,t.currentQuerySelector,new Map);let a=O(this,re(e.animation),t);return t.currentQuery=null,t.currentQuerySelector=i,{type:r.Query,selector:r$1,limit:n.limit||0,optional:!!n.optional,includeSelf:o,animation:a,originalSelector:e.selector,options:J(e.options)}}visitStagger(e,t){t.currentQuery||t.errors.push(Ti());let i=e.timings==="full"?{duration:0,delay:0,easing:"full"}:de(e.timings,t.errors,true);return {type:r.Stagger,animation:O(this,re(e.animation),t),timings:i,options:null}}};function kn(s){let e=!!s.split(/\s*,\s*/).find(t=>t==Ji);return e&&(s=s.replace(Rn,"")),s=s.replace(/@\*/g,he).replace(/@\w+/g,t=>he+"-"+t.slice(1)).replace(/:animating/g,De),[s,e]}function On(s){return s?P$2({},s):null}var pt=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 In(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 Fn(s,e){if(s.hasOwnProperty("duration"))return s;if(typeof s=="number"){let r=de(s,e).duration;return ct(r,0,"")}let t=s;if(t.split(/\s+/).some(r=>r.charAt(0)=="{"&&r.charAt(1)=="{")){let r=ct(0,0,"");return r.dynamic=true,r.strValue=t,r}let n=de(t,e);return ct(n.duration,n.delay,n.easing)}function J(s){return s?(s=P$2({},s),s.params&&(s.params=On(s.params))):s={},s}function ct(s,e,t){return {duration:s,delay:e,easing:t}}function Pt(s,e,t,i,n,r,o=null,a=false){return {type:1,element:s,keyframes:e,preStyleProps:t,postStyleProps:i,duration:n,delay:r,totalTime:n+r,easing:o,subTimeline:a}}var fe=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();}},Ln=1,zn=":enter",Kn=new RegExp(zn,"g"),jn=":leave",Bn=new RegExp(jn,"g");function tn(s,e,t,i,n,r=new Map,o=new Map,a,l,c=[]){return new gt().buildKeyframes(s,e,t,i,n,r,o,a,l,c)}var gt=class{buildKeyframes(e,t,i,n,r,o,a,l,c,h=[]){c=c||new fe;let u=new yt(e,t,c,n,r,h,[]);u.options=l;let _=l.delay?U(l.delay):0;u.currentTimeline.delayNextStep(_),u.currentTimeline.setStyles([o],null,u.errors,l),O(this,i,u);let y=u.timelines.filter(m=>m.containsAnimation());if(y.length&&a.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([a],null,u.errors,l);}return y.length?y.map(m=>m.buildKeyframes()):[Pt(t,[],[],[],0,_,"",false)]}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,o=this._visitSubInstructions(i,n,n.options);r!=o&&t.transformIntoNewTimeline(o);}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 o=typeof r=="number"?r:U(oe(r,n?.params??{},t.errors));i.delayNextStep(o);}}}_visitSubInstructions(e,t,i){let r=t.currentTimeline.currentTime,o=i.duration!=null?U(i.duration):null,a=i.delay!=null?U(i.delay):null;return o!==0&&e.forEach(l=>{let c=t.appendInstructionToTimeline(l,o,a);r=Math.max(r,c.duration+c.delay);}),r}visitReference(e,t){t.updateOptions(e.options,true),O(this,e.animation,t),t.previousNode=e;}visitSequence(e,t){let i=t.subContextCount,n=t,r$1=e.options;if(r$1&&(r$1.params||r$1.delay)&&(n=t.createSubContext(r$1),n.transformIntoNewTimeline(),r$1.delay!=null)){n.previousNode.type==r.Style&&(n.currentTimeline.snapshotCurrentStyles(),n.previousNode=je);let o=U(r$1.delay);n.delayNextStep(o);}e.steps.length&&(e.steps.forEach(o=>O(this,o,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(o=>{let a=t.createSubContext(e.options);r&&a.delayNextStep(r),O(this,o,a),n=Math.max(n,a.currentTimeline.currentTime),i.push(a.currentTimeline);}),i.forEach(o=>t.currentTimeline.mergeTimelineCollectedStyles(o)),t.transformIntoNewTimeline(n),t.previousNode=e;}_visitTiming(e,t){if(e.dynamic){let i=e.strValue,n=t.params?oe(i,t.params,t.errors):i;return de(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$1=e.style;r$1.type==r.Keyframes?this.visitKeyframes(r$1,t):(t.incrementTime(i.duration),this.visitStyle(r$1,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,a=t.createSubContext().currentTimeline;a.easing=i.easing,e.styles.forEach(l=>{let c=l.offset||0;a.forwardTime(c*r),a.setStyles(l.styles,l.easing,t.errors,t.options),a.applyStylesToKeyframe();}),t.currentTimeline.mergeTimelineCollectedStyles(a),t.transformIntoNewTimeline(n+r),t.previousNode=e;}visitQuery(e,t){let i=t.currentTimeline.currentTime,n=e.options||{},r$1=n.delay?U(n.delay):0;r$1&&(t.previousNode.type===r.Style||i==0&&t.currentTimeline.hasCurrentStyleProperties())&&(t.currentTimeline.snapshotCurrentStyles(),t.previousNode=je);let o=i,a=t.invokeQuery(e.selector,e.originalSelector,e.limit,e.includeSelf,!!n.optional,t.errors);t.currentQueryTotal=a.length;let l=null;a.forEach((c,h)=>{t.currentQueryIndex=h;let u=t.createSubContext(e.options,c);r$1&&u.delayNextStep(r$1),c===t.element&&(l=u.currentTimeline),O(this,e.animation,u),u.currentTimeline.applyStylesToKeyframe();let _=u.currentTimeline.currentTime;o=Math.max(o,_);}),t.currentQueryIndex=0,t.currentQueryTotal=0,t.transformIntoNewTimeline(o),l&&(t.currentTimeline.mergeTimelineCollectedStyles(l),t.currentTimeline.snapshotCurrentStyles()),t.previousNode=e;}visitStagger(e,t){let i=t.parentContext,n=t.currentTimeline,r=e.timings,o=Math.abs(r.duration),a=o*(t.currentQueryTotal-1),l=o*t.currentQueryIndex;switch(r.duration<0?"reverse":r.easing){case "reverse":l=a-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);}},je={},yt=class s{_driver;element;subInstructions;_enterClassName;_leaveClassName;errors;timelines;parentContext=null;currentTimeline;currentAnimateTimings=null;previousNode=je;subContextCount=0;options={};currentQueryIndex=0;currentQueryTotal=0;currentStaggerTime=0;constructor(e,t,i,n,r,o,a,l){this._driver=e,this.element=t,this.subInstructions=i,this._enterClassName=n,this._leaveClassName=r,this.errors=o,this.timelines=a,this.currentTimeline=l||new Be(this._driver,t,0),a.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 o=n.params;o||(o=this.options.params={}),Object.keys(r).forEach(a=>{(!t||!o.hasOwnProperty(a))&&(o[a]=oe(r[a],o,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=je,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 _t(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,o){let a=[];if(n&&a.push(this.element),e.length>0){e=e.replace(Kn,"."+this._enterClassName),e=e.replace(Bn,"."+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)),a.push(...c);}return !r&&a.length==0&&o.push(Ai()),a}},Be=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 false;case 1:return this.hasCurrentStyleProperties();default:return true}}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+=Ln,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||_$2),this._currentKeyframe.set(t,_$2);this._currentEmptyStepKeyframe=this._currentKeyframe;}setStyles(e,t,i,n){t&&this._previousKeyframe.set("easing",t);let r=n&&n.params||{},o=qn(e,this._globalTimelineStyles);for(let[a,l]of o){let c=oe(l,r,i);this._pendingStyles.set(a,c),this._localTimelineStyles.has(a)||this._backFill.set(a,this._globalTimelineStyles.get(a)??_$2),this._updateStyle(a,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((a,l)=>{let c=new Map([...this._backFill,...a]);c.forEach((h,u)=>{h===g$2?e.add(u):h===_$2&&t.add(u);}),i||c.set("offset",l/this.duration),n.push(c);});let r=[...e.values()],o=[...t.values()];if(i){let a=n[0],l=new Map(a);a.set("offset",0),l.set("offset",1),n=[a,l];}return Pt(this.element,n,r,o,this.duration,this.startTime,this.easing,false)}},_t=class extends Be{keyframes;preStyleProps;postStyleProps;_stretchStartingKeyframe;timings;constructor(e,t,i,n,r,o,a=false){super(e,t,o.delay),this.keyframes=i,this.preStyleProps=n,this.postStyleProps=r,this._stretchStartingKeyframe=a,this.timings={duration:o.duration,delay:o.delay,easing:o.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=[],o=i+t,a=t/o,l=new Map(e[0]);l.set("offset",0),r.push(l);let c=new Map(e[0]);c.set("offset",Vi(a)),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",Vi(m/o)),r.push(_);}i=o,t=0,n="",e=r;}return Pt(this.element,e,this.preStyleProps,this.postStyleProps,i,t,n,true)}};function Vi(s,e=3){let t=Math.pow(10,e-1);return Math.round(s*t)/t}function qn(s,e){let t=new Map,i;return s.forEach(n=>{if(n==="*"){i??=e.keys();for(let r of i)t.set(r,_$2);}else for(let[r,o]of n)t.set(r,o);}),t}function $i(s,e,t,i,n,r,o,a,l,c,h,u,_){return {type:0,element:s,triggerName:e,isRemovalTransition:n,fromState:t,fromStyles:r,toState:i,toStyles:o,timelines:a,queriedElements:l,preStyleProps:c,postStyleProps:h,totalTime:u,errors:_}}var ut={},qe=class{_triggerName;ast;_stateStyles;constructor(e,t,i){this._triggerName=e,this.ast=t,this._stateStyles=i;}match(e,t,i,n){return Qn(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,o,a,l,c,h){let u=[],_=this.ast.options&&this.ast.options.params||ut,y=a&&a.params||ut,m=this.buildStyles(i,y,u),g=l&&l.params||ut,T=this.buildStyles(n,g,u),w=new Set,b=new Map,M=new Map,N=n==="void",ne={params:nn(g,_),delay:this.ast.options?.delay},q=h?[]:tn(e,t,this.ast.animation,r,o,m,T,ne,c,u),D=0;return q.forEach(R=>{D=Math.max(R.duration+R.delay,D);}),u.length?$i(t,this._triggerName,i,n,N,m,T,[],[],b,M,D,u):(q.forEach(R=>{let H=R.element,se=k(b,H,new Set);R.preStyleProps.forEach(Y=>se.add(Y));let Nt=k(M,H,new Set);R.postStyleProps.forEach(Y=>Nt.add(Y)),H!==t&&w.add(H);}),$i(t,this._triggerName,i,n,N,m,T,q,[...w.values()],b,M,D))}};function Qn(s,e,t,i,n){return s.some(r=>r(e,t,i,n))}function nn(s,e){let t=P$2({},e);return Object.entries(s).forEach(([i,n])=>{n!=null&&(t[i]=n);}),t}var St=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=nn(e,this.defaultParams);return this.styles.styles.forEach(r=>{typeof r!="string"&&r.forEach((o,a)=>{o&&(o=oe(o,n,t));let l=this.normalizer.normalizePropertyName(a,t);o=this.normalizer.normalizeStyleValue(a,l,o,t),i.set(a,o);});}),i}};function Un(s,e,t){return new Et(s,e,t)}var Et=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 St(n.style,r,i));}),Gi(this.states,"true","1"),Gi(this.states,"false","0"),t.transitions.forEach(n=>{this.transitionFactories.push(new qe(e,n,this.states));}),this.fallbackTransition=Vn(e,this.states);}get containsQueries(){return this.ast.queryCount>0}matchTransition(e,t,i,n){return this.transitionFactories.find(o=>o.match(e,t,i,n))||null}matchStyles(e,t,i){return this.fallbackTransition.buildStyles(e,t,i)}};function Vn(s,e,t){let i=[(o,a)=>true],n={type:r.Sequence,steps:[],options:null},r$1={type:r.Transition,animation:n,matchers:i,options:null,queryCount:0,depCount:0};return new qe(s,r$1,e)}function Gi(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 $n=new fe,vt=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=en(this._driver,t,i,n);if(i.length)throw Ni();this._animations.set(e,r);}_buildPlayer(e,t,i){let n=e.element,r=tt(this._normalizer,e.keyframes,t,i);return this._driver.animate(n,r,e.duration,e.delay,e.easing,[],true)}create(e,t,i={}){let n=[],r=this._animations.get(e),o,a=new Map;if(r?(o=tn(this._driver,t,r,ot,Me,new Map,new Map,i,$n,n),o.forEach(h=>{let u=k(a,h.element,new Map);h.postStyleProps.forEach(_=>u.set(_,null));})):(n.push(Ci()),o=[]),n.length)throw Mi();a.forEach((h,u)=>{h.forEach((_,y)=>{h.set(y,this._driver.computeStyle(u,y,_$2));});});let l=o.map(h=>{let u=a.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 Di();return t}listen(e,t,i,n){let r=Ne(t,"","","");return Pe(this._getPlayer(e),i,r,n),()=>{}}command(e,t,i,n){if(i=="register"){this.register(e,n[0]);return}if(i=="create"){let o=n[0]||{};this.create(e,t,o);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}}},Wi="ng-animate-queued",Gn=".ng-animate-queued",ht="ng-animate-disabled",Wn=".ng-animate-disabled",Hn="ng-star-inserted",Yn=".ng-star-inserted",Xn=[],sn={namespaceId:"",setForRemoval:false,setForMove:false,hasAnimation:false,removedBeforeQueried:false},xn={namespaceId:"",setForMove:false,setForRemoval:false,hasAnimation:false,removedBeforeQueried:true},B="__ng_removed",pe=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=Jn(n),i){let r=e,{value:o}=r,a=Jl(r,["value"]);this.options=a;}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]);});}}},me="void",dt=new pe(me),Tt=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 Ri();if(i==null||i.length==0)throw ki();if(!es(i))throw Oi();let r=k(this._elementListeners,e,[]),o={name:t,phase:i,callback:n};r.push(o);let a=k(this._engine.statesByElement,e,new Map);return a.has(t)||(L(e,ue),L(e,ue+"-"+t),a.set(t,dt)),()=>{this._engine.afterFlush(()=>{let l=r.indexOf(o);l>=0&&r.splice(l,1),this._triggers.has(t)||a.delete(t);});}}register(e,t){return this._triggers.has(e)?false:(this._triggers.set(e,t),true)}_getTrigger(e){let t=this._triggers.get(e);if(!t)throw Ii();return t}trigger(e,t,i,n=true){let r=this._getTrigger(t),o=new ge(this.id,t,e),a=this._engine.statesByElement.get(e);a||(L(e,ue),L(e,ue+"-"+t),this._engine.statesByElement.set(e,a=new Map));let l=a.get(t),c=new pe(i,this.id);if(!(i&&i.hasOwnProperty("value"))&&l&&c.absorbOptions(l.options),a.set(t,c),l||(l=dt),!(c.value===me)&&l.value===c.value){if(!ns(l.params,c.params)){let g=[],T=r.matchStyles(l.value,l.params,g),w=r.matchStyles(c.value,c.params,g);g.length?this._engine.reportError(g):this._engine.afterFlush(()=>{W(e,T),j(e,w);});}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=false;if(!y){if(!n)return;y=r.fallbackTransition,m=true;}return this._engine.totalQueuedPlayers++,this._queue.push({element:e,triggerName:t,transition:y,fromState:l,toState:c,player:o,isFallbackTransition:m}),m||(L(e,Wi),o.onStart(()=>{ae(e,Wi);})),o.onDone(()=>{let g=this.players.indexOf(o);g>=0&&this.players.splice(g,1);let T=this._engine.playersByElement.get(e);if(T){let w=T.indexOf(o);w>=0&&T.splice(w,1);}}),this.players.push(o),_.push(o),o}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,he,true);i.forEach(n=>{if(n[B])return;let r=this._engine.fetchNamespacesByElement(n);r.size?r.forEach(o=>o.triggerLeaveAnimation(n,t,false,true)):this.clearElementCache(n);}),this._engine.afterFlushAnimationsDone(()=>i.forEach(n=>this.clearElementCache(n)));}triggerLeaveAnimation(e,t,i,n){let r=this._engine.statesByElement.get(e),o=new Map;if(r){let a=[];if(r.forEach((l,c)=>{if(o.set(c,l.value),this._triggers.has(c)){let h=this.trigger(e,c,me,n);h&&a.push(h);}}),a.length)return this._engine.markElementAsRemoved(this.id,e,true,t,o),i&&V(a).onDone(()=>this._engine.processLeaveNode(e)),true}return false}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 o=r.name;if(n.has(o))return;n.add(o);let l=this._triggers.get(o).fallbackTransition,c=i.get(o)||dt,h=new pe(me),u=new ge(this.id,o,e);this._engine.totalQueuedPlayers++,this._queue.push({element:e,triggerName:o,transition:l,fromState:c,toState:h,player:u,isFallbackTransition:true});});}}removeNode(e,t){let i=this._engine;if(e.childElementCount&&this._signalRemovalForInnerTriggers(e,t),this.triggerLeaveAnimation(e,t,true))return;let n=false;if(i.totalAnimations){let r=i.players.length?i.playersByQueriedElement.get(e):[];if(r&&r.length)n=true;else {let o=e;for(;o=o.parentNode;)if(i.statesByElement.get(o)){n=true;break}}}if(this.prepareLeaveAnimationListeners(e),n)i.markElementAsRemoved(this.id,e,false,t);else {let r=e[B];(!r||r===sn)&&(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,o=this._elementListeners.get(r);o&&o.forEach(a=>{if(a.name==i.triggerName){let l=Ne(r,i.triggerName,i.fromState.value,i.toState.value);l._data=e,Pe(i.player,a.phase,l,a.callback);}}),n.markedForDestroy?this._engine.afterFlush(()=>{n.destroy();}):t.push(i);}),this._queue=[],t.sort((i,n)=>{let r=i.transition.ast.depCount,o=n.transition.ast.depCount;return r==0||o==0?r-o:this._engine.driver.containsElement(i.element,n.element)?1:-1})}destroy(e){this.players.forEach(t=>t.destroy()),this._signalRemovalForInnerTriggers(this.hostElement,e);}},At=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 Tt(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 o=false,a=this.driver.getParentElement(t);for(;a;){let l=n.get(a);if(l){let c=i.indexOf(l);i.splice(c+1,0,e),o=true;break}a=this.driver.getParentElement(a);}o||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(Fe(t)){let r=this._fetchNamespace(e);if(r)return r.trigger(t,i,n),true}return false}insertNode(e,t,i,n){if(!Fe(t))return;let r=t[B];if(r&&r.setForRemoval){r.setForRemoval=false,r.setForMove=true;let o=this.collectedLeaveElements.indexOf(t);o>=0&&this.collectedLeaveElements.splice(o,1);}if(e){let o=this._fetchNamespace(e);o&&o.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,ht)):this.disabledNodes.has(e)&&(this.disabledNodes.delete(e),ae(e,ht));}removeNode(e,t,i){if(Fe(t)){let n=e?this._fetchNamespace(e):null;n?n.removeNode(t,i):this.markElementAsRemoved(e,t,false,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:false,previousTriggersValues:r};}listen(e,t,i,n,r){return Fe(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,he,true);t.forEach(i=>this.destroyActiveAnimationsForElement(i)),this.playersByQueriedElement.size!=0&&(t=this.driver.query(e,De,true),t.forEach(i=>this.finishActiveQueriedAnimationOnElement(i)));}destroyActiveAnimationsForElement(e){let t=this.playersByElement.get(e);t&&t.forEach(i=>{i.queued?i.markedForDestroy=true: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]=sn,t.namespaceId){this.destroyInnerAnimations(e);let i=this._fetchNamespace(t.namespaceId);i&&i.clearElementCache(e);}this._onRemovalComplete(e,t.setForRemoval);}e.classList?.contains(ht)&&this.markElementAsDisabled(e,false),this.driver.query(e,Wn,true).forEach(i=>{this.markElementAsDisabled(i,false);});}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,Hn);}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 Fi()}_flushAnimations(e,t){let i=new fe,n=[],r=new Map,o=[],a=new Map,l=new Map,c=new Map,h=new Set;this.disabledNodes.forEach(d=>{h.add(d);let f=this.driver.query(d,Gn,true);for(let p=0;p<f.length;p++)h.add(f[p]);});let u=this.bodyNode,_=Array.from(this.statesByElement.keys()),y=Xi(_,this.collectedEnterElements),m=new Map,g=0;y.forEach((d,f)=>{let p=ot+g++;m.set(f,p),d.forEach(E=>L(E,p));});let T=[],w=new Set,b=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),w.add(f),p.hasAnimation?this.driver.query(f,Yn,true).forEach(E=>w.add(E)):b.add(f));}let M=new Map,N=Xi(_,Array.from(w));N.forEach((d,f)=>{let p=Me+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 ne=[],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(ne.push(E),this.collectedEnterElements.length){let C=P[B];if(C&&C.setForMove){if(C.previousTriggersValues&&C.previousTriggersValues.has(p.triggerName)){let X=C.previousTriggersValues.get(p.triggerName),F=this.statesByElement.get(p.element);if(F&&F.has(p.triggerName)){let ye=F.get(p.triggerName);ye.value=X,F.set(p.triggerName,ye);}}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(()=>W(P,A.fromStyles)),E.onDestroy(()=>j(P,A.toStyles)),n.push(E);return}if(p.isFallbackTransition){E.onStart(()=>W(P,A.fromStyles)),E.onDestroy(()=>j(P,A.toStyles)),n.push(E);return}let Dt=[];A.timelines.forEach(C=>{C.stretchStartingKeyframe=true,this.disabledNodes.has(C.element)||Dt.push(C);}),A.timelines=Dt,i.append(P,A.timelines);let dn={instruction:A,player:E,element:P};o.push(dn),A.queriedElements.forEach(C=>k(a,C,[]).push(E)),A.preStyleProps.forEach((C,X)=>{if(C.size){let F=l.get(X);F||l.set(X,F=new Set),C.forEach((ye,He)=>F.add(He));}}),A.postStyleProps.forEach((C,X)=>{let F=c.get(X);F||c.set(X,F=new Set),C.forEach((ye,He)=>F.add(He));});});if(q.length){let d=[];q.forEach(f=>{d.push(Li(f.triggerName,f.errors));}),ne.forEach(f=>f.destroy()),this.reportError(d);}let D=new Map,R=new Map;o.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,false,d.namespaceId,d.triggerName,null).forEach(E=>{k(D,f,[]).push(E),E.destroy();});});let H=T.filter(d=>xi(d,l,c)),se=new Map;Yi(se,this.driver,b,c,_$2).forEach(d=>{xi(d,l,c)&&H.push(d);});let Y=new Map;y.forEach((d,f)=>{Yi(Y,this.driver,new Set(d),l,g$2);}),H.forEach(d=>{let f=se.get(d),p=Y.get(d);se.set(d,new Map([...f?.entries()??[],...p?.entries()??[]]));});let We=[],Ct=[],Mt={};o.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=true,p.overrideTotalTime(E.totalTime),n.push(p);return}let P=Mt;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,Y,se);if(p.setRealPlayer(Q),P===Mt)We.push(p);else {let I=this.playersByElement.get(P);I&&I.length&&(p.parentPlayer=V(I)),n.push(p);}}else W(f,E.fromStyles),p.onDestroy(()=>j(f,E.toStyles)),Ct.push(p),h.has(f)&&n.push(p);}),Ct.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,Me),p&&p.hasAnimation)continue;let E=[];if(a.size){let Q=a.get(f);Q&&Q.length&&E.push(...Q);let I=this.driver.query(f,De,true);for(let $=0;$<I.length;$++){let A=a.get(I[$]);A&&A.length&&E.push(...A);}}let P=E.filter(Q=>!Q.destroyed);P.length?ts(this,f,P):this.processLeaveNode(f);}return T.length=0,We.forEach(d=>{this.players.push(d),d.onDone(()=>{d.destroy();let f=this.players.indexOf(d);this.players.splice(f,1);}),d.play();}),We}afterFlush(e){this._flushFns.push(e);}afterFlushAnimationsDone(e){this._whenQuietFns.push(e);}_getPreviousPlayers(e,t,i,n,r){let o=[];if(t){let a=this.playersByQueriedElement.get(e);a&&(o=a);}else {let a=this.playersByElement.get(e);if(a){let l=!r||r==me;a.forEach(c=>{c.queued||!l&&c.triggerName!=n||o.push(c);});}}return (i||n)&&(o=o.filter(a=>!(i&&i!=a.namespaceId||n&&n!=a.triggerName))),o}_beforeAnimationBuild(e,t,i){let n=t.triggerName,r=t.element,o=t.isRemovalTransition?void 0:e,a=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,o,a,t.toState).forEach(y=>{let m=y.getRealPlayer();m.beforeDestroy&&m.beforeDestroy(),y.destroy(),u.push(y);});}W(r,t.fromStyles);}_buildAnimation(e,t,i,n,r,o){let a=t.triggerName,l$1=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 l(m.duration,m.delay);let w=g!==l$1,b=is((i.get(g)||Xn).map(D=>D.getRealPlayer())).filter(D=>{let R=D;return R.element?R.element===g:false}),M=r.get(g),N=o.get(g),ne=tt(this._normalizer,m.keyframes,M,N),q=this._buildPlayer(m,ne,b);if(m.subTimeline&&n&&u.add(g),w){let D=new ge(e,a,g);D.setRealPlayer(q),c.push(D);}return q});c.forEach(m=>{k(this.playersByQueriedElement,m.element,[]).push(m),m.onDone(()=>Zn(this.playersByQueriedElement,m.element,m));}),h.forEach(m=>L(m,at));let y=V(_);return y.onDestroy(()=>{h.forEach(m=>ae(m,at)),j(l$1,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 l(e.duration,e.delay)}},ge=class{namespaceId;triggerName;element;_player=new l;_containsRealPlayer=false;_queuedCallbacks=new Map;destroyed=false;parentPlayer=null;markedForDestroy=false;disabled=false;queued=true;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=>Pe(e,i,void 0,n));}),this._queuedCallbacks.clear(),this._containsRealPlayer=true,this.overrideTotalTime(e.totalTime),this.queued=false);}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?false: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=true,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 Zn(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 Jn(s){return s??null}function Fe(s){return s&&s.nodeType===1}function es(s){return s=="start"||s=="done"}function Hi(s,e){let t=s.style.display;return s.style.display=e??"none",t}function Yi(s,e,t,i,n){let r=[];t.forEach(l=>r.push(Hi(l)));let o=[];i.forEach((l,c)=>{let h=new Map;l.forEach(u=>{let _=e.computeStyle(c,u,n);h.set(u,_),(!_||_.length==0)&&(c[B]=xn,o.push(c));}),s.set(c,h);});let a=0;return t.forEach(l=>Hi(l,r[a++])),o}function Xi(s,e){let t=new Map;if(s.forEach(a=>t.set(a,[])),e.length==0)return t;let i=1,n=new Set(e),r=new Map;function o(a){if(!a)return i;let l=r.get(a);if(l)return l;let c=a.parentNode;return t.has(c)?l=c:n.has(c)?l=i:l=o(c),r.set(a,l),l}return e.forEach(a=>{let l=o(a);l!==i&&t.get(l).push(a);}),t}function L(s,e){s.classList?.add(e);}function ae(s,e){s.classList?.remove(e);}function ts(s,e,t){V(t).onDone(()=>s.processLeaveNode(e));}function is(s){let e=[];return rn(s,e),e}function rn(s,e){for(let t=0;t<s.length;t++){let i=s[t];i instanceof u$1?rn(i.players,e):e.push(i);}}function ns(s,e){let t=Object.keys(s),i=Object.keys(e);if(t.length!=i.length)return false;for(let n=0;n<t.length;n++){let r=t[n];if(!e.hasOwnProperty(r)||s[r]!==e[r])return false}return true}function xi(s,e,t){let i=t.get(s);if(!i)return false;let n=e.get(s);return n?i.forEach(r=>n.add(r)):e.set(s,i),t.delete(s),true}var le=class{_driver;_normalizer;_transitionEngine;_timelineEngine;_triggerCache={};onRemovalComplete=(e,t)=>{};constructor(e,t,i){this._driver=t,this._normalizer=i,this._transitionEngine=new At(e.body,t,i),this._timelineEngine=new vt(e.body,t,i),this._transitionEngine.onRemovalComplete=(n,r)=>this.onRemovalComplete(n,r);}registerTrigger(e,t,i,n,r){let o=e+"-"+n,a=this._triggerCache[o];if(!a){let l=[],c=[],h=en(this._driver,r,l,c);if(l.length)throw Pi();a=Un(n,h,this._normalizer),this._triggerCache[o]=a;}this._transitionEngine.registerTrigger(t,n,a);}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,o]=it(i),a=n;this._timelineEngine.command(r,t,o,a);}else this._transitionEngine.trigger(e,t,i,n);}listen(e,t,i,n,r){if(i.charAt(0)=="@"){let[o,a]=it(i);return this._timelineEngine.listen(o,t,a,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 ss(s,e){let t=null,i=null;return Array.isArray(e)&&e.length?(t=mt(e[0]),e.length>1&&(i=mt(e[e.length-1]))):e instanceof Map&&(t=mt(e)),t||i?new rs(s,t,i):null}var rs=(()=>{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&&(W(this._element,this._startStyles),this._endStyles=null),this._endStyles&&(W(this._element,this._endStyles),this._endStyles=null),j(this._element,this._initialStyles),this._state=3);}}return s})();function mt(s){let e=null;return s.forEach((t,i)=>{os(i)&&(e=e||new Map,e.set(i,t));}),e}function os(s){return s==="display"||s==="position"}var Qe=class{element;keyframes;options;_specialStyles;_onDoneFns=[];_onStartFns=[];_onDestroyFns=[];_duration;_delay;_initialized=false;_finished=false;_started=false;_destroyed=false;_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=true,this._onDoneFns.forEach(e=>e()),this._onDoneFns=[]);}init(){this._buildPlayer()&&this._preparePlayerBeforeStart();}_buildPlayer(){if(this._initialized)return this.domPlayer;this._initialized=true;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=true,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=false,this._finished=false,this._started=false,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=true,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:ke(this.element,n));}),this.currentSnapshot=e;}triggerCallback(e){let t=e==="start"?this._onStartFns:this._onDoneFns;t.forEach(i=>i()),t.length=0;}},Ue=class{validateStyleProperty(e){return true}validateAnimatableStyleProperty(e){return true}containsElement(e,t){return nt(e,t)}getParentElement(e){return Ce(e)}query(e,t,i){return st(e,t,i)}computeStyle(e,t,i){return ke(e,t)}animate(e,t,i,n,r,o=[]){let a=n==0?"both":"forwards",l={duration:i,delay:n,fill:a};r&&(l.easing=r);let c=new Map,h=o.filter(y=>y instanceof Qe);Bi(i,n)&&h.forEach(y=>{y.currentSnapshot.forEach((m,g)=>c.set(g,m));});let u=Ki(t).map(y=>new Map(y));u=qi(e,u,c);let _=ss(e,u);return new Qe(e,u,l,_)}};var Le="@",on="@.disabled",Ve=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,false);}insertBefore(e,t,i,n=true){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)==Le&&t==on?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);}},wt=class extends Ve{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)==Le?t.charAt(1)=="."&&t==on?(i=i===void 0?true:!!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)==Le){let r=as(e),o=t.slice(1),a="";return o.charAt(0)!=Le&&([o,a]=ls(o)),this.engine.listen(this.namespaceId,r,o,a,l=>{let c=l._data||-1;this.factory.scheduleListenerCallback(c,i,l);})}return this.delegate.listen(e,t,i,n)}};function as(s){switch(s){case "body":return document.body;case "document":return document;case "window":return window;default:return s}}function ls(s){let e=s.indexOf("."),t=s.substring(0,e),i=s.slice(e+1);return [t,i]}var $e=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 Ve("",n,this.engine,u),c.set(n,h);}return h}let r=t.id,o=t.id+"-"+this._currentId;this._currentId++,this.engine.register(o,e);let a=c=>{Array.isArray(c)?c.forEach(a):this.engine.registerTrigger(r,o,e,c.name,c);};return t.data.animation.forEach(a),new wt(this,o,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[o,a]=r;o(a);}),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 us=(()=>{class s extends le{constructor(t,i,n){super(t,i,n);}ngOnDestroy(){this.flush();}static \u0275fac=function(i){return new(i||s)(C$1(U$6),C$1(ee),C$1(te))};static \u0275prov=x({token:s,factory:s.\u0275fac})}return s})();function hs(){return new ze}function ds(){return new $e(g$3(Ul),g$3(le),g$3(G$2))}var an=[{provide:te,useFactory:hs},{provide:le,useClass:us},{provide:Sn$3,useFactory:ds}],ms=[{provide:ee,useFactory:()=>new Ue},{provide:zv,useFactory:()=>"BrowserAnimations"},...an];function ln(){return ut$3("NgEagerAnimations"),[...ms]}var ie=s=>dt$2(null,null,function*(){let e=g$3(P),t=s.params.projectName;return t?e.getSelectedProjectId()===t?true:(e.selectProject(t),(yield zy(e.selectedProject$.pipe(Ad(n=>n?.name===t))))?.name===t):(console.log("[PROJECT GUARD] no project id in route"),false)});var cn=s=>dt$2(null,null,function*(){let e=g$3(U$4),t=g$3(he$3),i=s.params.threadId;if(!t.getUsername())try{yield $y(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"),false;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"),true;console.log("[THREAD GUARD] Selecting thread:",i),e.selectThread(i);try{let n=yield $y(Ly([e.isLoading$,e.selectedThread$]).pipe(Od(([o,a])=>console.log(`\u{1F43C} [${o?"loading":"loaded"}]`,a?.id)),Ot$3(([o,a])=>!o&&!!a),sn$2(1),ue$4(([o,a])=>a?.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),false}});var un=[{path:"",loadComponent:()=>import('./chunk-Bd0IiMsO.js').then(s=>s.GlobalTaskControlComponent)},{path:"projects",loadComponent:()=>import('./chunk-okzlJmPZ.js').then(s=>s.ProjectListComponent)},{path:"oauth/callback",loadComponent:()=>Promise.resolve().then(function(){return chunkCYRG77X6}).then(s=>s.OAuthCallbackComponent)},{path:"project/new",loadComponent:()=>import('./chunk-PH-PuPg1.js').then(s=>s.ProjectNewComponent)},{path:"project/:projectName",loadComponent:()=>import('./chunk-fxaq06d7.js').then(s=>s.MainAppComponent),canActivate:[ie]},{path:"project/:projectName/prompts",loadComponent:()=>import('./chunk-DRAFMqKn.js').then(s=>s.PromptListComponent),canActivate:[ie]},{path:"project/:projectName/schedulers",loadComponent:()=>import('./chunk-CNPdPW3v.js').then(s=>s.SchedulerListComponent),canActivate:[ie]},{path:"project/:projectName/agents",loadComponent:()=>import('./chunk-B_DNrrfb.js').then(s=>s.AgentListComponent),canActivate:[ie]},{path:"project/:projectName/tasks",loadComponent:()=>import('./chunk-TwL6unik.js').then(s=>s.TaskControlComponent),canActivate:[ie]},{path:"project/:projectName/missions",redirectTo:"project/:projectName/tasks"},{path:"project/:projectName/thread/:threadId",loadComponent:()=>import('./chunk-fxaq06d7.js').then(s=>s.MainAppComponent),canActivate:[ie,cn]},{path:"token-usage",loadComponent:()=>import('./chunk-LNTSOB-k.js').then(s=>s.TokenUsageComponent)},{path:"agentos",loadChildren:()=>dt$2(null,null,function*(){let{AGENTOS_ROUTES:s,THEME_PORT:e}=yield import('./chunk-DHse9w28.js').then(function(n){return n.c});return [{path:"",providers:[{provide:e,useFactory:t=>({theme:F(t.currentTheme$,{initialValue:t.getCurrentTheme()}),setTheme:i=>t.setTheme(i)}),deps:[ge$2]}],children:s}]})},{path:"**",redirectTo:""}];function fs(s){return ()=>s.initializeDefaultProject()}function ps(s){return ()=>{console.log("[APP_INIT] OAuthService initialized");}}function gs(s){return ()=>dt$2(null,null,function*(){let{UserStateService:e}=yield import('./chunk-DHse9w28.js').then(function(n){return n.c}),t=s.get(e);yield zy(t.loadMe().pipe(ga(i=>(console.warn("Failed to load current user",i),ha(null)))));})}var hn={providers:[Uv(),wB({eventCoalescing:true}),Xo(un),CS(),ln(),{provide:wt$1,useValue:{duration:3e3}},{provide:al,useFactory:fs,deps:[P],multi:true},{provide:al,useFactory:ps,deps:[O$1],multi:true},{provide:al,useFactory:gs,deps:[pe$3],multi:true},qs({basePath:"/api/agentos"}),{provide:Ye,useValue:{width:"80vw",maxWidth:"80vw",maxHeight:"80vh"}}]};var Ge=class s{title="client";themeService=g$3(ge$2);ngOnInit(){console.log("[APP] Application initialized with theme:",this.themeService.getCurrentTheme());}static \u0275fac=function(t){return new(t||s)};static \u0275cmp=Aw({type:s,selectors:[["app-root"]],decls:1,vars:0,template:function(t,i){t&1&&bg(0,"router-outlet");},dependencies:[ea,mr],encapsulation:2,changeDetection:1})};Xb(Ge,hn).catch(s=>console.error(s));"serviceWorker"in navigator&&true&&window.addEventListener("load",()=>{navigator.serviceWorker.register("/sw.js").catch(s=>console.error("[SW] Registration failed:",s));});var chunkCYRG77X6=/*#__PURE__*/Object.freeze({__proto__:null,OAUTH_CALLBACK_STORAGE_KEY:m$1,OAuthCallbackComponent:d});export{zt as $,Aw as A,dE as B,Cg as C,Fg as D,wC as E,F,G,Hi$2 as H,IC as I,dy as J,c as K,L$1 as L,Wy as M,N$1 as N,Ot$1 as O,P,By as Q,Re$1 as R,ha as S,TC as T,U$4 as U,V$4 as V,WC as W,XE as X,x as Y,z as Z,Ue$1 as _,P$2 as a,Yg as a$,jt as a0,Vt as a1,Nt as a2,HI as a3,rC as a4,yl as a5,$I as a6,ga as a7,Zg as a8,dC as a9,sn$2 as aA,fr as aB,Cu as aC,Ly as aD,A$1 as aE,me$1 as aF,z$2 as aG,TS as aH,Tr as aI,Nb as aJ,Do$1 as aK,qn$3 as aL,Nn$1 as aM,wt$3 as aN,G$2 as aO,$a as aP,As as aQ,K$1 as aR,Ut$1 as aS,Ue$2 as aT,U$6 as aU,w as aV,D as aW,ft$1 as aX,ks as aY,YT as aZ,XC as a_,If as aa,wf as ab,mC as ac,Vg as ad,Ot$3 as ae,Dg as af,fT as ag,rT as ah,Jg as ai,KC as aj,Xg as ak,yt$5 as al,Gm as am,ce$3 as an,V$3 as ao,Vy as ap,a as aq,S$1 as ar,F$4 as as,c$1 as at,tv as au,dt$2 as av,pl as aw,hl as ax,O$1 as ay,Qt$1 as az,U$1 as b,Ng as b$,An$3 as b0,Ob as b1,bb as b2,oT as b3,nT as b4,Sg as b5,u as b6,B$3 as b7,T$2 as b8,v as b9,DC as bA,Ii$2 as bB,ge$1 as bC,vt$2 as bD,X$5 as bE,p$1 as bF,Pt$2 as bG,Eg as bH,dr$1 as bI,fe$5 as bJ,pe$3 as bK,mr$1 as bL,F$1 as bM,mt$1 as bN,Yy as bO,Zy as bP,bd as bQ,ma as bR,pn$1 as bS,Od as bT,Ky as bU,Y as bV,Pt$1 as bW,po as bX,X$1 as bY,xt$1 as bZ,FC as b_,m$3 as ba,R$2 as bb,h$1 as bc,A as bd,aT as be,uT as bf,Hy as bg,lT as bh,aE as bi,yh as bj,Mt as bk,Sm as bl,Xt as bm,nC as bn,gl as bo,ml as bp,sn$1 as bq,Cl as br,Qn$1 as bs,Ve$2 as bt,kg as bu,St$3 as bv,on$1 as bw,am as bx,Oi$1 as by,vC as bz,ce$2 as c,va as c$,E as c0,ME as c1,kt as c2,On$1 as c3,Et$1 as c4,Rt as c5,_e as c6,QT as c7,kf as c8,We$3 as c9,on$2 as cA,R$1 as cB,Ce$4 as cC,Rd as cD,Fb as cE,dT as cF,Xw as cG,Nt$3 as cH,Rg as cI,yB as cJ,Id as cK,Nd as cL,Rn$3 as cM,is$1 as cN,Bt$1 as cO,q as cP,X$2 as cQ,Yt as cR,Gp as cS,pi$1 as cT,yg as cU,YI as cV,yr$1 as cW,tt$1 as cX,fn$1 as cY,he$1 as cZ,kn$1 as c_,mB as ca,gB as cb,Hf as cc,Sb as cd,W$2 as ce,iT as cf,Mg as cg,ge$2 as ch,Pn$1 as ci,Ff as cj,fe$3 as ck,M as cl,F$3 as cm,H$3 as cn,_$1 as co,Se$1 as cp,vB as cq,EB as cr,vi$1 as cs,CB as ct,Lg as cu,CC as cv,Pg as cw,si as cx,Xr as cy,Sn$3 as cz,b as d,lt$1 as d0,wt$2 as d1,I as d2,y$2 as d3,N$2 as d4,F$5 as d5,U$5 as d6,M$1 as d7,he$4 as d8,fe$4 as d9,oe$2 as dA,mr as dB,ee$3 as dC,ie$2 as dD,zy as dE,He$3 as dF,kb as dG,xe$1 as dH,wd as dI,Y$1 as dJ,_$3 as dK,DB as dL,xb as dM,me$2 as dN,L$2 as dO,Kg as dP,X$4 as dQ,ge$3 as da,ue$3 as db,$$2 as dc,B$4 as dd,se$1 as de,Q$1 as df,T as dg,J$4 as dh,te$3 as di,Ce$3 as dj,G$1 as dk,ge$4 as dl,_t$4 as dm,vo$1 as dn,Ke$2 as dp,Lw as dq,m$4 as dr,Se$3 as ds,ke$3 as dt,vn$1 as du,Ea as dv,wa as dw,C$1 as dx,re$3 as dy,Qg as dz,O$3 as e,f$1 as f,g$3 as g,he$3 as h,hr as i,Gn$1 as j,fl as k,Ag as l,mT as m,eC as n,bg as o,pr as p,oC as q,Tg as r,si$1 as s,tC as t,ue$4 as u,vs as v,we$1 as w,iC as x,Hg as y,z$3 as z};
1811
+ `],encapsulation:2,changeDetection:1})}return i})(),Fe$1="--mat-dialog-transition-duration";function Le$1(i){return i==null?null:typeof i=="number"?i:i.endsWith("ms")?fn$1(i.substring(0,i.length-2)):i.endsWith("s")?fn$1(i.substring(0,i.length-1))*1e3:i==="0"?0:null}var N=(function(i){return i[i.OPEN=0]="OPEN",i[i.CLOSING=1]="CLOSING",i[i.CLOSED=2]="CLOSED",i})(N||{}),z=class{_ref;_config;_containerInstance;componentInstance;componentRef=null;disableClose;id;_afterOpened=new Mr(1);_beforeClosed=new Mr(1);_result;_closeFallbackTimeout;_state=N.OPEN;_closeInteractionType;constructor(a,e,t){this._ref=a,this._config=e,this._containerInstance=t,this.disableClose=e.disableClose,this.id=a.id,a.addPanelClass("mat-mdc-dialog-panel"),t._animationStateChanged.pipe(Ot$3(n=>n.state==="opened"),sn$2(1)).subscribe(()=>{this._afterOpened.next(),this._afterOpened.complete();}),t._animationStateChanged.pipe(Ot$3(n=>n.state==="closed"),sn$2(1)).subscribe(()=>{clearTimeout(this._closeFallbackTimeout),this._finishDialogClose();}),a.overlayRef.detachments().subscribe(()=>{this._beforeClosed.next(this._result),this._beforeClosed.complete(),this._finishDialogClose();}),Yy(this.backdropClick(),this.keydownEvents().pipe(Ot$3(n=>n.keyCode===27&&!this.disableClose&&!Ve$2(n)))).subscribe(n=>{this.disableClose||(n.preventDefault(),qe$1(this,n.type==="keydown"?"keyboard":"mouse"));});}close(a){let e=this._config.closePredicate;e&&!e(a,this._config,this.componentInstance)||(this._result=a,this._containerInstance._animationStateChanged.pipe(Ot$3(t=>t.state==="closing"),sn$2(1)).subscribe(t=>{this._beforeClosed.next(a),this._beforeClosed.complete(),this._ref.overlayRef.detachBackdrop(),this._closeFallbackTimeout=setTimeout(()=>this._finishDialogClose(),t.totalTime+100);}),this._state=N.CLOSING,this._containerInstance._startExitAnimation());}afterOpened(){return this._afterOpened}afterClosed(){return this._ref.closed}beforeClosed(){return this._beforeClosed}backdropClick(){return this._ref.backdropClick}keydownEvents(){return this._ref.keydownEvents}updatePosition(a){let e=this._ref.config.positionStrategy;return a&&(a.left||a.right)?a.left?e.left(a.left):e.right(a.right):e.centerHorizontally(),a&&(a.top||a.bottom)?a.top?e.top(a.top):e.bottom(a.bottom):e.centerVertically(),this._ref.updatePosition(),this}updateSize(a="",e=""){return this._ref.updateSize(a,e),this}addPanelClass(a){return this._ref.addPanelClass(a),this}removePanelClass(a){return this._ref.removePanelClass(a),this}getState(){return this._state}_finishDialogClose(){this._state=N.CLOSED,this._ref.close(this._result,{focusOrigin:this._closeInteractionType}),this.componentInstance=null;}};function qe$1(i,a,e){return i._closeInteractionType=a,i.close(e)}var Ue$1=new w("MatMdcDialogData"),Ye=new w("mat-mdc-dialog-default-options"),Ze$1=new w("mat-mdc-dialog-scroll-strategy",{providedIn:"root",factory:()=>{let i=g$3(pe$3);return ()=>Kt(i)}}),Re$1=(()=>{class i{_defaultOptions=g$3(Ye,{optional:true});_scrollStrategy=g$3(Ze$1);_parentDialog=g$3(i,{optional:true,skipSelf:true});_idGenerator=g$3(Ut$1);_injector=g$3(pe$3);_dialog=g$3(X);_animationsDisabled=K$1();_openDialogsAtThisLevel=[];_afterAllClosedAtThisLevel=new ce$3;_afterOpenedAtThisLevel=new ce$3;dialogConfigClass=V$1;_dialogRefConstructor;_dialogContainerType;_dialogDataToken;get openDialogs(){return this._parentDialog?this._parentDialog.openDialogs:this._openDialogsAtThisLevel}get afterOpened(){return this._parentDialog?this._parentDialog.afterOpened:this._afterOpenedAtThisLevel}_getAfterAllClosed(){let e=this._parentDialog;return e?e._getAfterAllClosed():this._afterAllClosedAtThisLevel}afterAllClosed=Zy(()=>this.openDialogs.length?this._getAfterAllClosed():this._getAfterAllClosed().pipe(bd(void 0)));constructor(){this._dialogRefConstructor=z,this._dialogContainerType=Qe$1,this._dialogDataToken=Ue$1;}open(e,t){let n;t=P$2(P$2({},this._defaultOptions||new V$1),t),t.id=t.id||this._idGenerator.getId("mat-mdc-dialog-"),t.scrollStrategy=t.scrollStrategy||this._scrollStrategy();let o=this._dialog.open(e,z$3(P$2({},t),{positionStrategy:oe$1(this._injector).centerHorizontally().centerVertically(),disableClose:true,closePredicate:void 0,closeOnDestroy:false,closeOnOverlayDetachments:false,disableAnimations:this._animationsDisabled||t.enterAnimationDuration?.toLocaleString()==="0"||t.exitAnimationDuration?.toString()==="0",container:{type:this._dialogContainerType,providers:()=>[{provide:this.dialogConfigClass,useValue:t},{provide:g,useValue:t}]},templateContext:()=>({dialogRef:n}),providers:(l,r,d)=>(n=new this._dialogRefConstructor(l,t,d),n.updatePosition(t?.position),[{provide:this._dialogContainerType,useValue:d},{provide:this._dialogDataToken,useValue:r.data},{provide:this._dialogRefConstructor,useValue:n}])}));return n.componentRef=o.componentRef,n.componentInstance=o.componentInstance,this.openDialogs.push(n),this.afterOpened.next(n),n.afterClosed().subscribe(()=>{let l=this.openDialogs.indexOf(n);l>-1&&(this.openDialogs.splice(l,1),this.openDialogs.length||this._getAfterAllClosed().next());}),n}closeAll(){this._closeDialogs(this.openDialogs);}getDialogById(e){return this.openDialogs.find(t=>t.id===e)}ngOnDestroy(){this._closeDialogs(this._openDialogsAtThisLevel),this._afterAllClosedAtThisLevel.complete(),this._afterOpenedAtThisLevel.complete();}_closeDialogs(e){let t=e.length;for(;t--;)e[t].close();}static \u0275fac=function(t){return new(t||i)};static \u0275prov=Ce$4({token:i,factory:i.\u0275fac})}return i})();var Pe$1=(()=>{class i{_dialogRef=g$3(z,{optional:true});_elementRef=g$3(Qt$1);_dialog=g$3(Re$1);ngOnInit(){this._dialogRef||(this._dialogRef=$e$1(this._elementRef,this._dialog.openDialogs)),this._dialogRef&&Promise.resolve().then(()=>{this._onAdd();});}ngOnDestroy(){this._dialogRef?._containerInstance&&Promise.resolve().then(()=>{this._onRemove();});}static \u0275fac=function(t){return new(t||i)};static \u0275dir=ks({type:i})}return i})(),jt=(()=>{class i extends Pe$1{id=g$3(Ut$1).getId("mat-mdc-dialog-title-");_onAdd(){this._dialogRef._containerInstance?._addAriaLabelledBy?.(this.id);}_onRemove(){this._dialogRef?._containerInstance?._removeAriaLabelledBy?.(this.id);}static \u0275fac=(()=>{let e;return function(n){return (e||(e=Gp(i)))(n||i)}})();static \u0275dir=ks({type:i,selectors:[["","mat-dialog-title",""],["","matDialogTitle",""]],hostAttrs:[1,"mat-mdc-dialog-title","mdc-dialog__title"],hostVars:1,hostBindings:function(t,n){t&2&&Ng("id",n.id);},inputs:{id:"id"},exportAs:["matDialogTitle"],features:[yg]})}return i})(),Nt=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275dir=ks({type:i,selectors:[["","mat-dialog-content",""],["mat-dialog-content"],["","matDialogContent",""]],hostAttrs:[1,"mat-mdc-dialog-content","mdc-dialog__content"],features:[jw([he$1])]})}return i})(),Vt=(()=>{class i extends Pe$1{align;_onAdd(){this._dialogRef._containerInstance?._updateActionSectionCount?.(1);}_onRemove(){this._dialogRef._containerInstance?._updateActionSectionCount?.(-1);}static \u0275fac=(()=>{let e;return function(n){return (e||(e=Gp(i)))(n||i)}})();static \u0275dir=ks({type:i,selectors:[["","mat-dialog-actions",""],["mat-dialog-actions"],["","matDialogActions",""]],hostAttrs:[1,"mat-mdc-dialog-actions","mdc-dialog__actions"],hostVars:6,hostBindings:function(t,n){t&2&&Hg("mat-mdc-dialog-actions-align-start",n.align==="start")("mat-mdc-dialog-actions-align-center",n.align==="center")("mat-mdc-dialog-actions-align-end",n.align==="end");},inputs:{align:"align"},features:[yg]})}return i})();function $e$1(i,a){let e=i.nativeElement.parentElement;for(;e&&!e.classList.contains("mat-mdc-dialog-container");)e=e.parentElement;return e?a.find(t=>t.id===e.id):null}var zt=(()=>{class i{static \u0275fac=function(t){return new(t||i)};static \u0275mod=Do$1({type:i});static \u0275inj=qn$3({providers:[Re$1],imports:[Se,ge$1,Yt,wt$3]})}return i})();function U$1(n){n||(n=g$3(we$1));let e=new A$1(t=>{if(n.destroyed){t.next();return}return n.onDestroy(t.next.bind(t))});return t=>t.pipe(Vy(e))}function T(n,e){let t=g$3(pe$3),o=new Mr(1),c=Hf(()=>{let r;try{r=n();}catch(i){Rn$3(()=>o.error(i));return}Rn$3(()=>o.next(r));},{injector:t,manualCleanup:true});return t.get(we$1).onDestroy(()=>{c.destroy(),o.complete();}),o.asObservable()}function F(n,e){let o=!e?.manualCleanup?e?.injector?.get(we$1)??g$3(we$1):null,c=h(e?.equal),r;e?.requireSync?r=Hi$2({kind:0},{equal:c}):r=Hi$2({kind:1,value:e?.initialValue},{equal:c});let i,v=n.subscribe({next:s=>r.set({kind:1,value:s}),error:s=>{r.set({kind:2,error:s}),i?.();},complete:()=>{i?.();}});if(e?.requireSync&&r().kind===0)throw new m$4(601,false);return i=o?.onDestroy(v.unsubscribe.bind(v)),mT(()=>{let s=r();switch(s.kind){case 1:return s.value;case 2:throw s.error;case 0:throw new m$4(601,false)}},{equal:e?.equal})}function h(n=Object.is){return (e,t)=>e.kind===1&&t.kind===1&&n(e.value,t.value)}function ui(s){return new m$4(3e3,false)}function mn(){return new m$4(3100,false)}function fn(){return new m$4(3101,false)}function pn(s){return new m$4(3001,false)}function gn(s){return new m$4(3003,false)}function yn(s){return new m$4(3004,false)}function di(s,e){return new m$4(3005,false)}function mi(){return new m$4(3006,false)}function fi(){return new m$4(3007,false)}function pi(s,e){return new m$4(3008,false)}function gi(s){return new m$4(3002,false)}function yi(s,e,t,i,n){return new m$4(3010,false)}function _i(){return new m$4(3011,false)}function Si(){return new m$4(3012,false)}function Ei(){return new m$4(3200,false)}function vi(){return new m$4(3202,false)}function Ti(){return new m$4(3013,false)}function Ai(s){return new m$4(3014,false)}function wi(s){return new m$4(3015,false)}function bi(s){return new m$4(3016,false)}function Pi(s,e){return new m$4(3404,false)}function _n(s){return new m$4(3502,false)}function Ni(s){return new m$4(3503,false)}function Ci(){return new m$4(3300,false)}function Mi(s){return new m$4(3504,false)}function Di(s){return new m$4(3301,false)}function Ri(s,e){return new m$4(3302,false)}function ki(s){return new m$4(3303,false)}function Oi(s,e){return new m$4(3400,false)}function Ii(s){return new m$4(3401,false)}function Fi(s){return new m$4(3402,false)}function Li(s,e){return new m$4(3505,false)}function V(s){switch(s.length){case 0:return new l;case 1:return s[0];default:return new u$1(s)}}function tt(s,e,t=new Map,i=new Map){let n=[],r=[],o=-1,a=null;if(e.forEach(l=>{let c=l.get("offset"),h=c==o,u=h&&a||new Map;l.forEach((_,y)=>{let m=y,g=_;if(y!=="offset")switch(m=s.normalizePropertyName(m,n),g){case g$2:g=t.get(y);break;case _$2:g=i.get(y);break;default:g=s.normalizeStyleValue(y,m,g,n);break}u.set(m,g);}),h||r.push(u),a=u,o=c;}),n.length)throw _n();return r}function Pe(s,e,t,i){switch(e){case "start":s.onStart(()=>i(t&&Ze(t,"start",s)));break;case "done":s.onDone(()=>i(t&&Ze(t,"done",s)));break;case "destroy":s.onDestroy(()=>i(t&&Ze(t,"destroy",s)));break}}function Ze(s,e,t){let i=t.totalTime,n=!!t.disabled,r=Ne(s.element,s.triggerName,s.fromState,s.toState,e||s.phaseName,i??s.totalTime,n),o=s._data;return o!=null&&(r._data=o),r}function Ne(s,e,t,i,n="",r=0,o){return {element:s,triggerName:e,fromState:t,toState:i,phaseName:n,totalTime:r,disabled:!!o}}function k(s,e,t){let i=s.get(e);return i||s.set(e,i=t),i}function it(s){let e=s.indexOf(":"),t=s.substring(1,e),i=s.slice(e+1);return [t,i]}var Sn=typeof document>"u"?null:document.documentElement;function Ce(s){let e=s.parentNode||s.host||null;return e===Sn?null:e}function En(s){return s.substring(1,6)=="ebkit"}var Z=null,hi=false;function zi(s){Z||(Z=vn()||{},hi=Z.style?"WebkitAppearance"in Z.style:false);let e=true;return Z.style&&!En(s)&&(e=s in Z.style,!e&&hi&&(e="Webkit"+s.charAt(0).toUpperCase()+s.slice(1)in Z.style)),e}function vn(){return typeof document<"u"?document.body:null}function nt(s,e){for(;e;){if(e===s)return true;e=Ce(e);}return false}function st(s,e,t){if(t)return Array.from(s.querySelectorAll(e));let i=s.querySelector(e);return i?[i]:[]}var Tn=1e3,rt="{{",An="}}",ot="ng-enter",Me="ng-leave",ue="ng-trigger",he=".ng-trigger",at="ng-animating",De=".ng-animating";function U(s){if(typeof s=="number")return s;let e=s.match(/^(-?[\.\d]+)(m?s)/);return !e||e.length<2?0:Je(parseFloat(e[1]),e[2])}function Je(s,e){return e==="s"?s*Tn:s}function de(s,e,t){return s.hasOwnProperty("duration")?s:bn(s,e,t)}var wn=/^(-?[\.\d]+)(m?s)(?:\s+(-?[\.\d]+)(m?s))?(?:\s+([-a-z]+(?:\(.+?\))?))?$/i;function bn(s,e,t){let i,n=0,r="";if(typeof s=="string"){let o=s.match(wn);if(o===null)return e.push(ui()),{duration:0,delay:0,easing:""};i=Je(parseFloat(o[1]),o[2]);let a=o[3];a!=null&&(n=Je(parseFloat(a),o[4]));let l=o[5];l&&(r=l);}else i=s;if(!t){let o=false,a=e.length;i<0&&(e.push(mn()),o=true),n<0&&(e.push(fn()),o=true),o&&e.splice(a,0,ui());}return {duration:i,delay:n,easing:r}}function Ki(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=Re(n);t&&!t.has(n)&&t.set(n,s.style[r]),s.style[r]=i;});}function W(s,e){e.forEach((t,i)=>{let n=Re(i);s.style[n]="";});}function re(s){return Array.isArray(s)?s.length==1?s[0]:y$1(s):s}function ji(s,e,t){let i=e.params||{},n=lt(s);n.length&&n.forEach(r=>{i.hasOwnProperty(r)||t.push(pn());});}var et=new RegExp(`${rt}\\s*(.+?)\\s*${An}`,"g");function lt(s){let e=[];if(typeof s=="string"){let t;for(;t=et.exec(s);)e.push(t[1]);et.lastIndex=0;}return e}function oe(s,e,t){let i=`${s}`,n=i.replace(et,(r,o)=>{let a=e[o];return a==null&&(t.push(gn()),a=""),a.toString()});return n==i?s:n}var Pn=/-+([a-z0-9])/g;function Re(s){return s.replace(Pn,(...e)=>e[1].toUpperCase())}function Bi(s,e){return s===0||e===0}function qi(s,e,t){if(t.size&&e.length){let i=e[0],n=[];if(t.forEach((r,o)=>{i.has(o)||n.push(o),i.set(o,r);}),n.length)for(let r=1;r<e.length;r++){let o=e[r];n.forEach(a=>o.set(a,ke(s,a)));}}return e}function O(s,e,t){switch(e.type){case r.Trigger:return s.visitTrigger(e,t);case r.State:return s.visitState(e,t);case r.Transition:return s.visitTransition(e,t);case r.Sequence:return s.visitSequence(e,t);case r.Group:return s.visitGroup(e,t);case r.Animate:return s.visitAnimate(e,t);case r.Keyframes:return s.visitKeyframes(e,t);case r.Style:return s.visitStyle(e,t);case r.Reference:return s.visitReference(e,t);case r.AnimateChild:return s.visitAnimateChild(e,t);case r.AnimateRef:return s.visitAnimateRef(e,t);case r.Query:return s.visitQuery(e,t);case r.Stagger:return s.visitStagger(e,t);default:throw yn(e.type)}}function ke(s,e){return window.getComputedStyle(s)[e]}var bt=(()=>{class s{validateStyleProperty(t){return zi(t)}containsElement(t,i){return nt(t,i)}getParentElement(t){return Ce(t)}query(t,i,n){return st(t,i,n)}computeStyle(t,i,n){return n||""}animate(t,i,n,r,o,a=[],l$1){return new l(n,r)}static \u0275fac=function(i){return new(i||s)};static \u0275prov=x({token:s,factory:s.\u0275fac})}return s})(),ee=class{static NOOP=new bt},te=class{};var Nn=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"]),ze=class extends te{normalizePropertyName(e,t){return Re(e)}normalizeStyleValue(e,t,i,n){let r="",o=i.toString().trim();if(Nn.has(t)&&i!==0&&i!=="0")if(typeof i=="number")r="px";else {let a=i.match(/^[+-]?[\d\.]+([a-z]*)$/);a&&a[1].length==0&&n.push(di());}return o+r}};var Ke="*";function Cn(s,e){let t=[];return typeof s=="string"?s.split(/\s*,\s*/).forEach(i=>Mn(i,t,e)):t.push(s),t}function Mn(s,e,t){if(s[0]==":"){let l=Dn(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(wi()),e;let n=i[1],r=i[2],o=i[3];e.push(Qi(n,o));let a=n==Ke&&o==Ke;r[0]=="<"&&!a&&e.push(Qi(o,n));}function Dn(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(bi()),"* => *"}}var Oe=new Set(["true","1"]),Ie=new Set(["false","0"]);function Qi(s,e){let t=Oe.has(s)||Ie.has(s),i=Oe.has(e)||Ie.has(e);return (n,r)=>{let o=s==Ke||s==n,a=e==Ke||e==r;return !o&&t&&typeof n=="boolean"&&(o=n?Oe.has(s):Ie.has(s)),!a&&i&&typeof r=="boolean"&&(a=r?Oe.has(e):Ie.has(e)),o&&a}}var Ji=":self",Rn=new RegExp(`s*${Ji}s*,?`,"g");function en(s,e,t,i){return new ft(s).build(e,t,i)}var Ui="",ft=class{_driver;constructor(e){this._driver=e;}build(e,t,i){let n=new pt(t);return this._resetContextStyleTimingState(n),O(this,re(e),n)}_resetContextStyleTimingState(e){e.currentQuerySelector=Ui,e.collectedStyles=new Map,e.collectedStyles.set(Ui,new Map),e.currentTime=0;}visitTrigger(e,t){let i=t.queryCount=0,n=t.depCount=0,r$1=[],o=[];return e.name.charAt(0)=="@"&&t.errors.push(mi()),e.definitions.forEach(a=>{if(this._resetContextStyleTimingState(t),a.type==r.State){let l=a,c=l.name;c.toString().split(/\s*,\s*/).forEach(h=>{l.name=h,r$1.push(this.visitState(l,t));}),l.name=c;}else if(a.type==r.Transition){let l=this.visitTransition(a,t);i+=l.queryCount,n+=l.depCount,o.push(l);}else t.errors.push(fi());}),{type:r.Trigger,name:e.name,states:r$1,transitions:o,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,o=n||{};i.styles.forEach(a=>{a instanceof Map&&a.forEach(l=>{lt(l).forEach(c=>{o.hasOwnProperty(c)||r.add(c);});});}),r.size&&t.errors.push(pi(e.name,[...r.values()]));}return {type:r.State,name:e.name,style:i,options:n?{params:n}:null}}visitTransition(e,t){t.queryCount=0,t.depCount=0;let i=O(this,re(e.animation),t),n=Cn(e.expr,t.errors);return {type:r.Transition,matchers:n,animation:i,queryCount:t.queryCount,depCount:t.depCount,options:J(e.options)}}visitSequence(e,t){return {type:r.Sequence,steps:e.steps.map(i=>O(this,i,t)),options:J(e.options)}}visitGroup(e,t){let i=t.currentTime,n=0,r$1=e.steps.map(o=>{t.currentTime=i;let a=O(this,o,t);return n=Math.max(n,t.currentTime),a});return t.currentTime=n,{type:r.Group,steps:r$1,options:J(e.options)}}visitAnimate(e,t){let i=Fn(e.timings,t.errors);t.currentAnimateTimings=i;let n,r$1=e.styles?e.styles:F$4({});if(r$1.type==r.Keyframes)n=this.visitKeyframes(r$1,t);else {let o=e.styles,a=false;if(!o){a=true;let c={};i.easing&&(c.easing=i.easing),o=F$4(c);}t.currentTime+=i.duration+i.delay;let l=this.visitStyle(o,t);l.isEmptyStep=a,n=l;}return t.currentAnimateTimings=null,{type:r.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 a of n)typeof a=="string"?a===_$2?i.push(a):t.errors.push(gi()):i.push(new Map(Object.entries(a)));let r$1=false,o=null;return i.forEach(a=>{if(a instanceof Map&&(a.has("easing")&&(o=a.get("easing"),a.delete("easing")),!r$1)){for(let l of a.values())if(l.toString().indexOf(rt)>=0){r$1=true;break}}}),{type:r.Style,styles:i,easing:o,offset:e.offset,containsDynamicStyles:r$1,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(o=>{typeof o!="string"&&o.forEach((a,l)=>{let c=t.collectedStyles.get(t.currentQuerySelector),h=c.get(l),u=true;h&&(r!=n&&r>=h.startTime&&n<=h.endTime&&(t.errors.push(yi(l,h.startTime,h.endTime)),u=false),r=h.startTime),u&&c.set(l,{startTime:r,endTime:n}),t.options&&ji(a,t.options,t.errors);});});}visitKeyframes(e,t){let i={type:r.Keyframes,styles:[],options:null};if(!t.currentAnimateTimings)return t.errors.push(_i()),i;let n=1,r$1=0,o=[],a=false,l=false,c=0,h=e.steps.map(w=>{let b=this._makeStyleAst(w,t),M=b.offset!=null?b.offset:In(b.styles),N=0;return M!=null&&(r$1++,N=b.offset=M),l=l||N<0||N>1,a=a||N<c,c=N,o.push(N),b});l&&t.errors.push(Si()),a&&t.errors.push(Ei());let u=e.steps.length,_=0;r$1>0&&r$1<u?t.errors.push(vi()):r$1==0&&(_=n/(u-1));let y=u-1,m=t.currentTime,g=t.currentAnimateTimings,T=g.duration;return h.forEach((w,b)=>{let M=_>0?b==y?1:_*b:o[b],N=M*T;t.currentTime=m+g.delay+N,g.duration=N,this._validateStyleAst(w,t),w.offset=M,i.styles.push(w);}),i}visitReference(e,t){return {type:r.Reference,animation:O(this,re(e.animation),t),options:J(e.options)}}visitAnimateChild(e,t){return t.depCount++,{type:r.AnimateChild,options:J(e.options)}}visitAnimateRef(e,t){return {type:r.AnimateRef,animation:this.visitReference(e.animation,t),options:J(e.options)}}visitQuery(e,t){let i=t.currentQuerySelector,n=e.options||{};t.queryCount++,t.currentQuery=e;let[r$1,o]=kn(e.selector);t.currentQuerySelector=i.length?i+" "+r$1:r$1,k(t.collectedStyles,t.currentQuerySelector,new Map);let a=O(this,re(e.animation),t);return t.currentQuery=null,t.currentQuerySelector=i,{type:r.Query,selector:r$1,limit:n.limit||0,optional:!!n.optional,includeSelf:o,animation:a,originalSelector:e.selector,options:J(e.options)}}visitStagger(e,t){t.currentQuery||t.errors.push(Ti());let i=e.timings==="full"?{duration:0,delay:0,easing:"full"}:de(e.timings,t.errors,true);return {type:r.Stagger,animation:O(this,re(e.animation),t),timings:i,options:null}}};function kn(s){let e=!!s.split(/\s*,\s*/).find(t=>t==Ji);return e&&(s=s.replace(Rn,"")),s=s.replace(/@\*/g,he).replace(/@\w+/g,t=>he+"-"+t.slice(1)).replace(/:animating/g,De),[s,e]}function On(s){return s?P$2({},s):null}var pt=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 In(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 Fn(s,e){if(s.hasOwnProperty("duration"))return s;if(typeof s=="number"){let r=de(s,e).duration;return ct(r,0,"")}let t=s;if(t.split(/\s+/).some(r=>r.charAt(0)=="{"&&r.charAt(1)=="{")){let r=ct(0,0,"");return r.dynamic=true,r.strValue=t,r}let n=de(t,e);return ct(n.duration,n.delay,n.easing)}function J(s){return s?(s=P$2({},s),s.params&&(s.params=On(s.params))):s={},s}function ct(s,e,t){return {duration:s,delay:e,easing:t}}function Pt(s,e,t,i,n,r,o=null,a=false){return {type:1,element:s,keyframes:e,preStyleProps:t,postStyleProps:i,duration:n,delay:r,totalTime:n+r,easing:o,subTimeline:a}}var fe=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();}},Ln=1,zn=":enter",Kn=new RegExp(zn,"g"),jn=":leave",Bn=new RegExp(jn,"g");function tn(s,e,t,i,n,r=new Map,o=new Map,a,l,c=[]){return new gt().buildKeyframes(s,e,t,i,n,r,o,a,l,c)}var gt=class{buildKeyframes(e,t,i,n,r,o,a,l,c,h=[]){c=c||new fe;let u=new yt(e,t,c,n,r,h,[]);u.options=l;let _=l.delay?U(l.delay):0;u.currentTimeline.delayNextStep(_),u.currentTimeline.setStyles([o],null,u.errors,l),O(this,i,u);let y=u.timelines.filter(m=>m.containsAnimation());if(y.length&&a.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([a],null,u.errors,l);}return y.length?y.map(m=>m.buildKeyframes()):[Pt(t,[],[],[],0,_,"",false)]}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,o=this._visitSubInstructions(i,n,n.options);r!=o&&t.transformIntoNewTimeline(o);}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 o=typeof r=="number"?r:U(oe(r,n?.params??{},t.errors));i.delayNextStep(o);}}}_visitSubInstructions(e,t,i){let r=t.currentTimeline.currentTime,o=i.duration!=null?U(i.duration):null,a=i.delay!=null?U(i.delay):null;return o!==0&&e.forEach(l=>{let c=t.appendInstructionToTimeline(l,o,a);r=Math.max(r,c.duration+c.delay);}),r}visitReference(e,t){t.updateOptions(e.options,true),O(this,e.animation,t),t.previousNode=e;}visitSequence(e,t){let i=t.subContextCount,n=t,r$1=e.options;if(r$1&&(r$1.params||r$1.delay)&&(n=t.createSubContext(r$1),n.transformIntoNewTimeline(),r$1.delay!=null)){n.previousNode.type==r.Style&&(n.currentTimeline.snapshotCurrentStyles(),n.previousNode=je);let o=U(r$1.delay);n.delayNextStep(o);}e.steps.length&&(e.steps.forEach(o=>O(this,o,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(o=>{let a=t.createSubContext(e.options);r&&a.delayNextStep(r),O(this,o,a),n=Math.max(n,a.currentTimeline.currentTime),i.push(a.currentTimeline);}),i.forEach(o=>t.currentTimeline.mergeTimelineCollectedStyles(o)),t.transformIntoNewTimeline(n),t.previousNode=e;}_visitTiming(e,t){if(e.dynamic){let i=e.strValue,n=t.params?oe(i,t.params,t.errors):i;return de(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$1=e.style;r$1.type==r.Keyframes?this.visitKeyframes(r$1,t):(t.incrementTime(i.duration),this.visitStyle(r$1,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,a=t.createSubContext().currentTimeline;a.easing=i.easing,e.styles.forEach(l=>{let c=l.offset||0;a.forwardTime(c*r),a.setStyles(l.styles,l.easing,t.errors,t.options),a.applyStylesToKeyframe();}),t.currentTimeline.mergeTimelineCollectedStyles(a),t.transformIntoNewTimeline(n+r),t.previousNode=e;}visitQuery(e,t){let i=t.currentTimeline.currentTime,n=e.options||{},r$1=n.delay?U(n.delay):0;r$1&&(t.previousNode.type===r.Style||i==0&&t.currentTimeline.hasCurrentStyleProperties())&&(t.currentTimeline.snapshotCurrentStyles(),t.previousNode=je);let o=i,a=t.invokeQuery(e.selector,e.originalSelector,e.limit,e.includeSelf,!!n.optional,t.errors);t.currentQueryTotal=a.length;let l=null;a.forEach((c,h)=>{t.currentQueryIndex=h;let u=t.createSubContext(e.options,c);r$1&&u.delayNextStep(r$1),c===t.element&&(l=u.currentTimeline),O(this,e.animation,u),u.currentTimeline.applyStylesToKeyframe();let _=u.currentTimeline.currentTime;o=Math.max(o,_);}),t.currentQueryIndex=0,t.currentQueryTotal=0,t.transformIntoNewTimeline(o),l&&(t.currentTimeline.mergeTimelineCollectedStyles(l),t.currentTimeline.snapshotCurrentStyles()),t.previousNode=e;}visitStagger(e,t){let i=t.parentContext,n=t.currentTimeline,r=e.timings,o=Math.abs(r.duration),a=o*(t.currentQueryTotal-1),l=o*t.currentQueryIndex;switch(r.duration<0?"reverse":r.easing){case "reverse":l=a-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);}},je={},yt=class s{_driver;element;subInstructions;_enterClassName;_leaveClassName;errors;timelines;parentContext=null;currentTimeline;currentAnimateTimings=null;previousNode=je;subContextCount=0;options={};currentQueryIndex=0;currentQueryTotal=0;currentStaggerTime=0;constructor(e,t,i,n,r,o,a,l){this._driver=e,this.element=t,this.subInstructions=i,this._enterClassName=n,this._leaveClassName=r,this.errors=o,this.timelines=a,this.currentTimeline=l||new Be(this._driver,t,0),a.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 o=n.params;o||(o=this.options.params={}),Object.keys(r).forEach(a=>{(!t||!o.hasOwnProperty(a))&&(o[a]=oe(r[a],o,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=je,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 _t(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,o){let a=[];if(n&&a.push(this.element),e.length>0){e=e.replace(Kn,"."+this._enterClassName),e=e.replace(Bn,"."+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)),a.push(...c);}return !r&&a.length==0&&o.push(Ai()),a}},Be=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 false;case 1:return this.hasCurrentStyleProperties();default:return true}}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+=Ln,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||_$2),this._currentKeyframe.set(t,_$2);this._currentEmptyStepKeyframe=this._currentKeyframe;}setStyles(e,t,i,n){t&&this._previousKeyframe.set("easing",t);let r=n&&n.params||{},o=qn(e,this._globalTimelineStyles);for(let[a,l]of o){let c=oe(l,r,i);this._pendingStyles.set(a,c),this._localTimelineStyles.has(a)||this._backFill.set(a,this._globalTimelineStyles.get(a)??_$2),this._updateStyle(a,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((a,l)=>{let c=new Map([...this._backFill,...a]);c.forEach((h,u)=>{h===g$2?e.add(u):h===_$2&&t.add(u);}),i||c.set("offset",l/this.duration),n.push(c);});let r=[...e.values()],o=[...t.values()];if(i){let a=n[0],l=new Map(a);a.set("offset",0),l.set("offset",1),n=[a,l];}return Pt(this.element,n,r,o,this.duration,this.startTime,this.easing,false)}},_t=class extends Be{keyframes;preStyleProps;postStyleProps;_stretchStartingKeyframe;timings;constructor(e,t,i,n,r,o,a=false){super(e,t,o.delay),this.keyframes=i,this.preStyleProps=n,this.postStyleProps=r,this._stretchStartingKeyframe=a,this.timings={duration:o.duration,delay:o.delay,easing:o.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=[],o=i+t,a=t/o,l=new Map(e[0]);l.set("offset",0),r.push(l);let c=new Map(e[0]);c.set("offset",Vi(a)),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",Vi(m/o)),r.push(_);}i=o,t=0,n="",e=r;}return Pt(this.element,e,this.preStyleProps,this.postStyleProps,i,t,n,true)}};function Vi(s,e=3){let t=Math.pow(10,e-1);return Math.round(s*t)/t}function qn(s,e){let t=new Map,i;return s.forEach(n=>{if(n==="*"){i??=e.keys();for(let r of i)t.set(r,_$2);}else for(let[r,o]of n)t.set(r,o);}),t}function $i(s,e,t,i,n,r,o,a,l,c,h,u,_){return {type:0,element:s,triggerName:e,isRemovalTransition:n,fromState:t,fromStyles:r,toState:i,toStyles:o,timelines:a,queriedElements:l,preStyleProps:c,postStyleProps:h,totalTime:u,errors:_}}var ut={},qe=class{_triggerName;ast;_stateStyles;constructor(e,t,i){this._triggerName=e,this.ast=t,this._stateStyles=i;}match(e,t,i,n){return Qn(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,o,a,l,c,h){let u=[],_=this.ast.options&&this.ast.options.params||ut,y=a&&a.params||ut,m=this.buildStyles(i,y,u),g=l&&l.params||ut,T=this.buildStyles(n,g,u),w=new Set,b=new Map,M=new Map,N=n==="void",ne={params:nn(g,_),delay:this.ast.options?.delay},q=h?[]:tn(e,t,this.ast.animation,r,o,m,T,ne,c,u),D=0;return q.forEach(R=>{D=Math.max(R.duration+R.delay,D);}),u.length?$i(t,this._triggerName,i,n,N,m,T,[],[],b,M,D,u):(q.forEach(R=>{let H=R.element,se=k(b,H,new Set);R.preStyleProps.forEach(Y=>se.add(Y));let Nt=k(M,H,new Set);R.postStyleProps.forEach(Y=>Nt.add(Y)),H!==t&&w.add(H);}),$i(t,this._triggerName,i,n,N,m,T,q,[...w.values()],b,M,D))}};function Qn(s,e,t,i,n){return s.some(r=>r(e,t,i,n))}function nn(s,e){let t=P$2({},e);return Object.entries(s).forEach(([i,n])=>{n!=null&&(t[i]=n);}),t}var St=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=nn(e,this.defaultParams);return this.styles.styles.forEach(r=>{typeof r!="string"&&r.forEach((o,a)=>{o&&(o=oe(o,n,t));let l=this.normalizer.normalizePropertyName(a,t);o=this.normalizer.normalizeStyleValue(a,l,o,t),i.set(a,o);});}),i}};function Un(s,e,t){return new Et(s,e,t)}var Et=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 St(n.style,r,i));}),Gi(this.states,"true","1"),Gi(this.states,"false","0"),t.transitions.forEach(n=>{this.transitionFactories.push(new qe(e,n,this.states));}),this.fallbackTransition=Vn(e,this.states);}get containsQueries(){return this.ast.queryCount>0}matchTransition(e,t,i,n){return this.transitionFactories.find(o=>o.match(e,t,i,n))||null}matchStyles(e,t,i){return this.fallbackTransition.buildStyles(e,t,i)}};function Vn(s,e,t){let i=[(o,a)=>true],n={type:r.Sequence,steps:[],options:null},r$1={type:r.Transition,animation:n,matchers:i,options:null,queryCount:0,depCount:0};return new qe(s,r$1,e)}function Gi(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 $n=new fe,vt=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=en(this._driver,t,i,n);if(i.length)throw Ni();this._animations.set(e,r);}_buildPlayer(e,t,i){let n=e.element,r=tt(this._normalizer,e.keyframes,t,i);return this._driver.animate(n,r,e.duration,e.delay,e.easing,[],true)}create(e,t,i={}){let n=[],r=this._animations.get(e),o,a=new Map;if(r?(o=tn(this._driver,t,r,ot,Me,new Map,new Map,i,$n,n),o.forEach(h=>{let u=k(a,h.element,new Map);h.postStyleProps.forEach(_=>u.set(_,null));})):(n.push(Ci()),o=[]),n.length)throw Mi();a.forEach((h,u)=>{h.forEach((_,y)=>{h.set(y,this._driver.computeStyle(u,y,_$2));});});let l=o.map(h=>{let u=a.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 Di();return t}listen(e,t,i,n){let r=Ne(t,"","","");return Pe(this._getPlayer(e),i,r,n),()=>{}}command(e,t,i,n){if(i=="register"){this.register(e,n[0]);return}if(i=="create"){let o=n[0]||{};this.create(e,t,o);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}}},Wi="ng-animate-queued",Gn=".ng-animate-queued",ht="ng-animate-disabled",Wn=".ng-animate-disabled",Hn="ng-star-inserted",Yn=".ng-star-inserted",Xn=[],sn={namespaceId:"",setForRemoval:false,setForMove:false,hasAnimation:false,removedBeforeQueried:false},xn={namespaceId:"",setForMove:false,setForRemoval:false,hasAnimation:false,removedBeforeQueried:true},B="__ng_removed",pe=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=Jn(n),i){let r=e,{value:o}=r,a=Jl(r,["value"]);this.options=a;}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]);});}}},me="void",dt=new pe(me),Tt=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 Ri();if(i==null||i.length==0)throw ki();if(!es(i))throw Oi();let r=k(this._elementListeners,e,[]),o={name:t,phase:i,callback:n};r.push(o);let a=k(this._engine.statesByElement,e,new Map);return a.has(t)||(L(e,ue),L(e,ue+"-"+t),a.set(t,dt)),()=>{this._engine.afterFlush(()=>{let l=r.indexOf(o);l>=0&&r.splice(l,1),this._triggers.has(t)||a.delete(t);});}}register(e,t){return this._triggers.has(e)?false:(this._triggers.set(e,t),true)}_getTrigger(e){let t=this._triggers.get(e);if(!t)throw Ii();return t}trigger(e,t,i,n=true){let r=this._getTrigger(t),o=new ge(this.id,t,e),a=this._engine.statesByElement.get(e);a||(L(e,ue),L(e,ue+"-"+t),this._engine.statesByElement.set(e,a=new Map));let l=a.get(t),c=new pe(i,this.id);if(!(i&&i.hasOwnProperty("value"))&&l&&c.absorbOptions(l.options),a.set(t,c),l||(l=dt),!(c.value===me)&&l.value===c.value){if(!ns(l.params,c.params)){let g=[],T=r.matchStyles(l.value,l.params,g),w=r.matchStyles(c.value,c.params,g);g.length?this._engine.reportError(g):this._engine.afterFlush(()=>{W(e,T),j(e,w);});}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=false;if(!y){if(!n)return;y=r.fallbackTransition,m=true;}return this._engine.totalQueuedPlayers++,this._queue.push({element:e,triggerName:t,transition:y,fromState:l,toState:c,player:o,isFallbackTransition:m}),m||(L(e,Wi),o.onStart(()=>{ae(e,Wi);})),o.onDone(()=>{let g=this.players.indexOf(o);g>=0&&this.players.splice(g,1);let T=this._engine.playersByElement.get(e);if(T){let w=T.indexOf(o);w>=0&&T.splice(w,1);}}),this.players.push(o),_.push(o),o}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,he,true);i.forEach(n=>{if(n[B])return;let r=this._engine.fetchNamespacesByElement(n);r.size?r.forEach(o=>o.triggerLeaveAnimation(n,t,false,true)):this.clearElementCache(n);}),this._engine.afterFlushAnimationsDone(()=>i.forEach(n=>this.clearElementCache(n)));}triggerLeaveAnimation(e,t,i,n){let r=this._engine.statesByElement.get(e),o=new Map;if(r){let a=[];if(r.forEach((l,c)=>{if(o.set(c,l.value),this._triggers.has(c)){let h=this.trigger(e,c,me,n);h&&a.push(h);}}),a.length)return this._engine.markElementAsRemoved(this.id,e,true,t,o),i&&V(a).onDone(()=>this._engine.processLeaveNode(e)),true}return false}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 o=r.name;if(n.has(o))return;n.add(o);let l=this._triggers.get(o).fallbackTransition,c=i.get(o)||dt,h=new pe(me),u=new ge(this.id,o,e);this._engine.totalQueuedPlayers++,this._queue.push({element:e,triggerName:o,transition:l,fromState:c,toState:h,player:u,isFallbackTransition:true});});}}removeNode(e,t){let i=this._engine;if(e.childElementCount&&this._signalRemovalForInnerTriggers(e,t),this.triggerLeaveAnimation(e,t,true))return;let n=false;if(i.totalAnimations){let r=i.players.length?i.playersByQueriedElement.get(e):[];if(r&&r.length)n=true;else {let o=e;for(;o=o.parentNode;)if(i.statesByElement.get(o)){n=true;break}}}if(this.prepareLeaveAnimationListeners(e),n)i.markElementAsRemoved(this.id,e,false,t);else {let r=e[B];(!r||r===sn)&&(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,o=this._elementListeners.get(r);o&&o.forEach(a=>{if(a.name==i.triggerName){let l=Ne(r,i.triggerName,i.fromState.value,i.toState.value);l._data=e,Pe(i.player,a.phase,l,a.callback);}}),n.markedForDestroy?this._engine.afterFlush(()=>{n.destroy();}):t.push(i);}),this._queue=[],t.sort((i,n)=>{let r=i.transition.ast.depCount,o=n.transition.ast.depCount;return r==0||o==0?r-o:this._engine.driver.containsElement(i.element,n.element)?1:-1})}destroy(e){this.players.forEach(t=>t.destroy()),this._signalRemovalForInnerTriggers(this.hostElement,e);}},At=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 Tt(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 o=false,a=this.driver.getParentElement(t);for(;a;){let l=n.get(a);if(l){let c=i.indexOf(l);i.splice(c+1,0,e),o=true;break}a=this.driver.getParentElement(a);}o||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(Fe(t)){let r=this._fetchNamespace(e);if(r)return r.trigger(t,i,n),true}return false}insertNode(e,t,i,n){if(!Fe(t))return;let r=t[B];if(r&&r.setForRemoval){r.setForRemoval=false,r.setForMove=true;let o=this.collectedLeaveElements.indexOf(t);o>=0&&this.collectedLeaveElements.splice(o,1);}if(e){let o=this._fetchNamespace(e);o&&o.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,ht)):this.disabledNodes.has(e)&&(this.disabledNodes.delete(e),ae(e,ht));}removeNode(e,t,i){if(Fe(t)){let n=e?this._fetchNamespace(e):null;n?n.removeNode(t,i):this.markElementAsRemoved(e,t,false,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:false,previousTriggersValues:r};}listen(e,t,i,n,r){return Fe(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,he,true);t.forEach(i=>this.destroyActiveAnimationsForElement(i)),this.playersByQueriedElement.size!=0&&(t=this.driver.query(e,De,true),t.forEach(i=>this.finishActiveQueriedAnimationOnElement(i)));}destroyActiveAnimationsForElement(e){let t=this.playersByElement.get(e);t&&t.forEach(i=>{i.queued?i.markedForDestroy=true: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]=sn,t.namespaceId){this.destroyInnerAnimations(e);let i=this._fetchNamespace(t.namespaceId);i&&i.clearElementCache(e);}this._onRemovalComplete(e,t.setForRemoval);}e.classList?.contains(ht)&&this.markElementAsDisabled(e,false),this.driver.query(e,Wn,true).forEach(i=>{this.markElementAsDisabled(i,false);});}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,Hn);}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 Fi()}_flushAnimations(e,t){let i=new fe,n=[],r=new Map,o=[],a=new Map,l=new Map,c=new Map,h=new Set;this.disabledNodes.forEach(d=>{h.add(d);let f=this.driver.query(d,Gn,true);for(let p=0;p<f.length;p++)h.add(f[p]);});let u=this.bodyNode,_=Array.from(this.statesByElement.keys()),y=Xi(_,this.collectedEnterElements),m=new Map,g=0;y.forEach((d,f)=>{let p=ot+g++;m.set(f,p),d.forEach(E=>L(E,p));});let T=[],w=new Set,b=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),w.add(f),p.hasAnimation?this.driver.query(f,Yn,true).forEach(E=>w.add(E)):b.add(f));}let M=new Map,N=Xi(_,Array.from(w));N.forEach((d,f)=>{let p=Me+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 ne=[],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(ne.push(E),this.collectedEnterElements.length){let C=P[B];if(C&&C.setForMove){if(C.previousTriggersValues&&C.previousTriggersValues.has(p.triggerName)){let X=C.previousTriggersValues.get(p.triggerName),F=this.statesByElement.get(p.element);if(F&&F.has(p.triggerName)){let ye=F.get(p.triggerName);ye.value=X,F.set(p.triggerName,ye);}}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(()=>W(P,A.fromStyles)),E.onDestroy(()=>j(P,A.toStyles)),n.push(E);return}if(p.isFallbackTransition){E.onStart(()=>W(P,A.fromStyles)),E.onDestroy(()=>j(P,A.toStyles)),n.push(E);return}let Dt=[];A.timelines.forEach(C=>{C.stretchStartingKeyframe=true,this.disabledNodes.has(C.element)||Dt.push(C);}),A.timelines=Dt,i.append(P,A.timelines);let dn={instruction:A,player:E,element:P};o.push(dn),A.queriedElements.forEach(C=>k(a,C,[]).push(E)),A.preStyleProps.forEach((C,X)=>{if(C.size){let F=l.get(X);F||l.set(X,F=new Set),C.forEach((ye,He)=>F.add(He));}}),A.postStyleProps.forEach((C,X)=>{let F=c.get(X);F||c.set(X,F=new Set),C.forEach((ye,He)=>F.add(He));});});if(q.length){let d=[];q.forEach(f=>{d.push(Li(f.triggerName,f.errors));}),ne.forEach(f=>f.destroy()),this.reportError(d);}let D=new Map,R=new Map;o.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,false,d.namespaceId,d.triggerName,null).forEach(E=>{k(D,f,[]).push(E),E.destroy();});});let H=T.filter(d=>xi(d,l,c)),se=new Map;Yi(se,this.driver,b,c,_$2).forEach(d=>{xi(d,l,c)&&H.push(d);});let Y=new Map;y.forEach((d,f)=>{Yi(Y,this.driver,new Set(d),l,g$2);}),H.forEach(d=>{let f=se.get(d),p=Y.get(d);se.set(d,new Map([...f?.entries()??[],...p?.entries()??[]]));});let We=[],Ct=[],Mt={};o.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=true,p.overrideTotalTime(E.totalTime),n.push(p);return}let P=Mt;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,Y,se);if(p.setRealPlayer(Q),P===Mt)We.push(p);else {let I=this.playersByElement.get(P);I&&I.length&&(p.parentPlayer=V(I)),n.push(p);}}else W(f,E.fromStyles),p.onDestroy(()=>j(f,E.toStyles)),Ct.push(p),h.has(f)&&n.push(p);}),Ct.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,Me),p&&p.hasAnimation)continue;let E=[];if(a.size){let Q=a.get(f);Q&&Q.length&&E.push(...Q);let I=this.driver.query(f,De,true);for(let $=0;$<I.length;$++){let A=a.get(I[$]);A&&A.length&&E.push(...A);}}let P=E.filter(Q=>!Q.destroyed);P.length?ts(this,f,P):this.processLeaveNode(f);}return T.length=0,We.forEach(d=>{this.players.push(d),d.onDone(()=>{d.destroy();let f=this.players.indexOf(d);this.players.splice(f,1);}),d.play();}),We}afterFlush(e){this._flushFns.push(e);}afterFlushAnimationsDone(e){this._whenQuietFns.push(e);}_getPreviousPlayers(e,t,i,n,r){let o=[];if(t){let a=this.playersByQueriedElement.get(e);a&&(o=a);}else {let a=this.playersByElement.get(e);if(a){let l=!r||r==me;a.forEach(c=>{c.queued||!l&&c.triggerName!=n||o.push(c);});}}return (i||n)&&(o=o.filter(a=>!(i&&i!=a.namespaceId||n&&n!=a.triggerName))),o}_beforeAnimationBuild(e,t,i){let n=t.triggerName,r=t.element,o=t.isRemovalTransition?void 0:e,a=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,o,a,t.toState).forEach(y=>{let m=y.getRealPlayer();m.beforeDestroy&&m.beforeDestroy(),y.destroy(),u.push(y);});}W(r,t.fromStyles);}_buildAnimation(e,t,i,n,r,o){let a=t.triggerName,l$1=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 l(m.duration,m.delay);let w=g!==l$1,b=is((i.get(g)||Xn).map(D=>D.getRealPlayer())).filter(D=>{let R=D;return R.element?R.element===g:false}),M=r.get(g),N=o.get(g),ne=tt(this._normalizer,m.keyframes,M,N),q=this._buildPlayer(m,ne,b);if(m.subTimeline&&n&&u.add(g),w){let D=new ge(e,a,g);D.setRealPlayer(q),c.push(D);}return q});c.forEach(m=>{k(this.playersByQueriedElement,m.element,[]).push(m),m.onDone(()=>Zn(this.playersByQueriedElement,m.element,m));}),h.forEach(m=>L(m,at));let y=V(_);return y.onDestroy(()=>{h.forEach(m=>ae(m,at)),j(l$1,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 l(e.duration,e.delay)}},ge=class{namespaceId;triggerName;element;_player=new l;_containsRealPlayer=false;_queuedCallbacks=new Map;destroyed=false;parentPlayer=null;markedForDestroy=false;disabled=false;queued=true;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=>Pe(e,i,void 0,n));}),this._queuedCallbacks.clear(),this._containsRealPlayer=true,this.overrideTotalTime(e.totalTime),this.queued=false);}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?false: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=true,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 Zn(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 Jn(s){return s??null}function Fe(s){return s&&s.nodeType===1}function es(s){return s=="start"||s=="done"}function Hi(s,e){let t=s.style.display;return s.style.display=e??"none",t}function Yi(s,e,t,i,n){let r=[];t.forEach(l=>r.push(Hi(l)));let o=[];i.forEach((l,c)=>{let h=new Map;l.forEach(u=>{let _=e.computeStyle(c,u,n);h.set(u,_),(!_||_.length==0)&&(c[B]=xn,o.push(c));}),s.set(c,h);});let a=0;return t.forEach(l=>Hi(l,r[a++])),o}function Xi(s,e){let t=new Map;if(s.forEach(a=>t.set(a,[])),e.length==0)return t;let i=1,n=new Set(e),r=new Map;function o(a){if(!a)return i;let l=r.get(a);if(l)return l;let c=a.parentNode;return t.has(c)?l=c:n.has(c)?l=i:l=o(c),r.set(a,l),l}return e.forEach(a=>{let l=o(a);l!==i&&t.get(l).push(a);}),t}function L(s,e){s.classList?.add(e);}function ae(s,e){s.classList?.remove(e);}function ts(s,e,t){V(t).onDone(()=>s.processLeaveNode(e));}function is(s){let e=[];return rn(s,e),e}function rn(s,e){for(let t=0;t<s.length;t++){let i=s[t];i instanceof u$1?rn(i.players,e):e.push(i);}}function ns(s,e){let t=Object.keys(s),i=Object.keys(e);if(t.length!=i.length)return false;for(let n=0;n<t.length;n++){let r=t[n];if(!e.hasOwnProperty(r)||s[r]!==e[r])return false}return true}function xi(s,e,t){let i=t.get(s);if(!i)return false;let n=e.get(s);return n?i.forEach(r=>n.add(r)):e.set(s,i),t.delete(s),true}var le=class{_driver;_normalizer;_transitionEngine;_timelineEngine;_triggerCache={};onRemovalComplete=(e,t)=>{};constructor(e,t,i){this._driver=t,this._normalizer=i,this._transitionEngine=new At(e.body,t,i),this._timelineEngine=new vt(e.body,t,i),this._transitionEngine.onRemovalComplete=(n,r)=>this.onRemovalComplete(n,r);}registerTrigger(e,t,i,n,r){let o=e+"-"+n,a=this._triggerCache[o];if(!a){let l=[],c=[],h=en(this._driver,r,l,c);if(l.length)throw Pi();a=Un(n,h,this._normalizer),this._triggerCache[o]=a;}this._transitionEngine.registerTrigger(t,n,a);}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,o]=it(i),a=n;this._timelineEngine.command(r,t,o,a);}else this._transitionEngine.trigger(e,t,i,n);}listen(e,t,i,n,r){if(i.charAt(0)=="@"){let[o,a]=it(i);return this._timelineEngine.listen(o,t,a,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 ss(s,e){let t=null,i=null;return Array.isArray(e)&&e.length?(t=mt(e[0]),e.length>1&&(i=mt(e[e.length-1]))):e instanceof Map&&(t=mt(e)),t||i?new rs(s,t,i):null}var rs=(()=>{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&&(W(this._element,this._startStyles),this._endStyles=null),this._endStyles&&(W(this._element,this._endStyles),this._endStyles=null),j(this._element,this._initialStyles),this._state=3);}}return s})();function mt(s){let e=null;return s.forEach((t,i)=>{os(i)&&(e=e||new Map,e.set(i,t));}),e}function os(s){return s==="display"||s==="position"}var Qe=class{element;keyframes;options;_specialStyles;_onDoneFns=[];_onStartFns=[];_onDestroyFns=[];_duration;_delay;_initialized=false;_finished=false;_started=false;_destroyed=false;_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=true,this._onDoneFns.forEach(e=>e()),this._onDoneFns=[]);}init(){this._buildPlayer()&&this._preparePlayerBeforeStart();}_buildPlayer(){if(this._initialized)return this.domPlayer;this._initialized=true;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=true,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=false,this._finished=false,this._started=false,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=true,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:ke(this.element,n));}),this.currentSnapshot=e;}triggerCallback(e){let t=e==="start"?this._onStartFns:this._onDoneFns;t.forEach(i=>i()),t.length=0;}},Ue=class{validateStyleProperty(e){return true}validateAnimatableStyleProperty(e){return true}containsElement(e,t){return nt(e,t)}getParentElement(e){return Ce(e)}query(e,t,i){return st(e,t,i)}computeStyle(e,t,i){return ke(e,t)}animate(e,t,i,n,r,o=[]){let a=n==0?"both":"forwards",l={duration:i,delay:n,fill:a};r&&(l.easing=r);let c=new Map,h=o.filter(y=>y instanceof Qe);Bi(i,n)&&h.forEach(y=>{y.currentSnapshot.forEach((m,g)=>c.set(g,m));});let u=Ki(t).map(y=>new Map(y));u=qi(e,u,c);let _=ss(e,u);return new Qe(e,u,l,_)}};var Le="@",on="@.disabled",Ve=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,false);}insertBefore(e,t,i,n=true){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)==Le&&t==on?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);}},wt=class extends Ve{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)==Le?t.charAt(1)=="."&&t==on?(i=i===void 0?true:!!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)==Le){let r=as(e),o=t.slice(1),a="";return o.charAt(0)!=Le&&([o,a]=ls(o)),this.engine.listen(this.namespaceId,r,o,a,l=>{let c=l._data||-1;this.factory.scheduleListenerCallback(c,i,l);})}return this.delegate.listen(e,t,i,n)}};function as(s){switch(s){case "body":return document.body;case "document":return document;case "window":return window;default:return s}}function ls(s){let e=s.indexOf("."),t=s.substring(0,e),i=s.slice(e+1);return [t,i]}var $e=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 Ve("",n,this.engine,u),c.set(n,h);}return h}let r=t.id,o=t.id+"-"+this._currentId;this._currentId++,this.engine.register(o,e);let a=c=>{Array.isArray(c)?c.forEach(a):this.engine.registerTrigger(r,o,e,c.name,c);};return t.data.animation.forEach(a),new wt(this,o,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[o,a]=r;o(a);}),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 us=(()=>{class s extends le{constructor(t,i,n){super(t,i,n);}ngOnDestroy(){this.flush();}static \u0275fac=function(i){return new(i||s)(C$1(U$6),C$1(ee),C$1(te))};static \u0275prov=x({token:s,factory:s.\u0275fac})}return s})();function hs(){return new ze}function ds(){return new $e(g$3(Ul),g$3(le),g$3(G$2))}var an=[{provide:te,useFactory:hs},{provide:le,useClass:us},{provide:Sn$3,useFactory:ds}],ms=[{provide:ee,useFactory:()=>new Ue},{provide:zv,useFactory:()=>"BrowserAnimations"},...an];function ln(){return ut$3("NgEagerAnimations"),[...ms]}var ie=s=>dt$2(null,null,function*(){let e=g$3(P),t=s.params.projectName;return t?e.getSelectedProjectId()===t?true:(e.selectProject(t),(yield zy(e.selectedProject$.pipe(Ad(n=>n?.name===t))))?.name===t):(console.log("[PROJECT GUARD] no project id in route"),false)});var cn=s=>dt$2(null,null,function*(){let e=g$3(U$4),t=g$3(he$3),i=s.params.threadId;if(!t.getUsername())try{yield $y(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"),false;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"),true;console.log("[THREAD GUARD] Selecting thread:",i),e.selectThread(i);try{let n=yield $y(Ly([e.isLoading$,e.selectedThread$]).pipe(Od(([o,a])=>console.log(`\u{1F43C} [${o?"loading":"loaded"}]`,a?.id)),Ot$3(([o,a])=>!o&&!!a),sn$2(1),ue$4(([o,a])=>a?.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),false}});var un=[{path:"",loadComponent:()=>import('./chunk-X4zIHpcE.js').then(s=>s.GlobalTaskControlComponent)},{path:"projects",loadComponent:()=>import('./chunk-xk_bqNV0.js').then(s=>s.ProjectListComponent)},{path:"oauth/callback",loadComponent:()=>Promise.resolve().then(function(){return chunkCYRG77X6}).then(s=>s.OAuthCallbackComponent)},{path:"project/new",loadComponent:()=>import('./chunk-vkYtcaIT.js').then(s=>s.ProjectNewComponent)},{path:"project/:projectName",loadComponent:()=>import('./chunk-Cek4dv2K.js').then(s=>s.MainAppComponent),canActivate:[ie]},{path:"project/:projectName/prompts",loadComponent:()=>import('./chunk-S_TYzsa6.js').then(s=>s.PromptListComponent),canActivate:[ie]},{path:"project/:projectName/schedulers",loadComponent:()=>import('./chunk-NPBU5yIa.js').then(s=>s.SchedulerListComponent),canActivate:[ie]},{path:"project/:projectName/agents",loadComponent:()=>import('./chunk-OpV-oEpT.js').then(s=>s.AgentListComponent),canActivate:[ie]},{path:"project/:projectName/tasks",loadComponent:()=>import('./chunk-i62b6Gtt.js').then(s=>s.TaskControlComponent),canActivate:[ie]},{path:"project/:projectName/missions",redirectTo:"project/:projectName/tasks"},{path:"project/:projectName/thread/:threadId",loadComponent:()=>import('./chunk-Cek4dv2K.js').then(s=>s.MainAppComponent),canActivate:[ie,cn]},{path:"token-usage",loadComponent:()=>import('./chunk-DLhvPTZP.js').then(s=>s.TokenUsageComponent)},{path:"agentos",loadChildren:()=>dt$2(null,null,function*(){let{AGENTOS_ROUTES:s,THEME_PORT:e}=yield import('./chunk-Cb82rqle.js').then(function(n){return n.c});return [{path:"",providers:[{provide:e,useFactory:t=>({theme:F(t.currentTheme$,{initialValue:t.getCurrentTheme()}),setTheme:i=>t.setTheme(i)}),deps:[ge$2]}],children:s}]})},{path:"**",redirectTo:""}];function fs(s){return ()=>s.initializeDefaultProject()}function ps(s){return ()=>{console.log("[APP_INIT] OAuthService initialized");}}function gs(s){return ()=>dt$2(null,null,function*(){let{UserStateService:e}=yield import('./chunk-Cb82rqle.js').then(function(n){return n.c}),t=s.get(e);yield zy(t.loadMe().pipe(ga(i=>(console.warn("Failed to load current user",i),ha(null)))));})}var hn={providers:[Uv(),wB({eventCoalescing:true}),Xo(un),CS(),ln(),{provide:wt$1,useValue:{duration:3e3}},{provide:al,useFactory:fs,deps:[P],multi:true},{provide:al,useFactory:ps,deps:[O$1],multi:true},{provide:al,useFactory:gs,deps:[pe$3],multi:true},qs({basePath:"/api/agentos"}),{provide:Ye,useValue:{width:"80vw",maxWidth:"80vw",maxHeight:"80vh"}}]};var Ge=class s{title="client";themeService=g$3(ge$2);ngOnInit(){console.log("[APP] Application initialized with theme:",this.themeService.getCurrentTheme());}static \u0275fac=function(t){return new(t||s)};static \u0275cmp=Aw({type:s,selectors:[["app-root"]],decls:1,vars:0,template:function(t,i){t&1&&bg(0,"router-outlet");},dependencies:[ea,mr],encapsulation:2,changeDetection:1})};Xb(Ge,hn).catch(s=>console.error(s));"serviceWorker"in navigator&&true&&window.addEventListener("load",()=>{navigator.serviceWorker.register("/sw.js").catch(s=>console.error("[SW] Registration failed:",s));});var chunkCYRG77X6=/*#__PURE__*/Object.freeze({__proto__:null,OAUTH_CALLBACK_STORAGE_KEY:m$1,OAuthCallbackComponent:d});export{zt as $,Aw as A,dE as B,Cg as C,Fg as D,wC as E,F,G,Hi$2 as H,IC as I,dy as J,c as K,L$1 as L,Wy as M,N$1 as N,Ot$1 as O,P,By as Q,Re$1 as R,ha as S,TC as T,U$4 as U,V$4 as V,WC as W,XE as X,x as Y,z as Z,Ue$1 as _,P$2 as a,Yg as a$,jt as a0,Vt as a1,Nt as a2,HI as a3,rC as a4,yl as a5,$I as a6,ga as a7,Zg as a8,dC as a9,sn$2 as aA,fr as aB,Cu as aC,Ly as aD,A$1 as aE,me$1 as aF,z$2 as aG,TS as aH,Tr as aI,Nb as aJ,Do$1 as aK,qn$3 as aL,Nn$1 as aM,wt$3 as aN,G$2 as aO,$a as aP,As as aQ,K$1 as aR,Ut$1 as aS,Ue$2 as aT,U$6 as aU,w as aV,D as aW,ft$1 as aX,ks as aY,YT as aZ,XC as a_,If as aa,wf as ab,mC as ac,Vg as ad,Ot$3 as ae,Dg as af,fT as ag,rT as ah,Jg as ai,KC as aj,Xg as ak,yt$5 as al,Gm as am,ce$3 as an,V$3 as ao,Vy as ap,a as aq,S$1 as ar,F$4 as as,c$1 as at,tv as au,dt$2 as av,pl as aw,hl as ax,O$1 as ay,Qt$1 as az,U$1 as b,Ng as b$,An$3 as b0,Ob as b1,bb as b2,oT as b3,nT as b4,Sg as b5,u as b6,B$3 as b7,T$2 as b8,v as b9,DC as bA,Ii$2 as bB,ge$1 as bC,vt$2 as bD,X$5 as bE,p$1 as bF,Pt$2 as bG,Eg as bH,dr$1 as bI,fe$5 as bJ,pe$3 as bK,mr$1 as bL,F$1 as bM,mt$1 as bN,Yy as bO,Zy as bP,bd as bQ,ma as bR,pn$1 as bS,Od as bT,Ky as bU,Y as bV,Pt$1 as bW,po as bX,X$1 as bY,xt$1 as bZ,FC as b_,m$3 as ba,R$2 as bb,h$1 as bc,A as bd,aT as be,uT as bf,Hy as bg,lT as bh,aE as bi,yh as bj,Mt as bk,Sm as bl,Xt as bm,nC as bn,gl as bo,ml as bp,sn$1 as bq,Cl as br,Qn$1 as bs,Ve$2 as bt,kg as bu,St$3 as bv,on$1 as bw,am as bx,Oi$1 as by,vC as bz,ce$2 as c,va as c$,E as c0,ME as c1,kt as c2,On$1 as c3,Et$1 as c4,Rt as c5,_e as c6,QT as c7,kf as c8,We$3 as c9,on$2 as cA,R$1 as cB,Ce$4 as cC,Rd as cD,Fb as cE,dT as cF,Xw as cG,Nt$3 as cH,Rg as cI,yB as cJ,Id as cK,Nd as cL,Rn$3 as cM,is$1 as cN,Bt$1 as cO,q as cP,X$2 as cQ,Yt as cR,Gp as cS,pi$1 as cT,yg as cU,YI as cV,yr$1 as cW,tt$1 as cX,fn$1 as cY,he$1 as cZ,kn$1 as c_,mB as ca,gB as cb,Hf as cc,Sb as cd,W$2 as ce,iT as cf,Mg as cg,ge$2 as ch,Pn$1 as ci,Ff as cj,fe$3 as ck,M as cl,F$3 as cm,H$3 as cn,_$1 as co,Se$1 as cp,vB as cq,EB as cr,vi$1 as cs,CB as ct,Lg as cu,CC as cv,Pg as cw,si as cx,Xr as cy,Sn$3 as cz,b as d,lt$1 as d0,wt$2 as d1,I as d2,y$2 as d3,N$2 as d4,F$5 as d5,U$5 as d6,M$1 as d7,he$4 as d8,fe$4 as d9,oe$2 as dA,mr as dB,ee$3 as dC,ie$2 as dD,zy as dE,He$3 as dF,kb as dG,xe$1 as dH,wd as dI,Y$1 as dJ,_$3 as dK,DB as dL,xb as dM,me$2 as dN,L$2 as dO,Kg as dP,X$4 as dQ,ge$3 as da,ue$3 as db,$$2 as dc,B$4 as dd,Q$1 as de,T as df,J$4 as dg,se$1 as dh,te$3 as di,Ce$3 as dj,G$1 as dk,ge$4 as dl,_t$4 as dm,vo$1 as dn,Ke$2 as dp,Lw as dq,m$4 as dr,Se$3 as ds,ke$3 as dt,vn$1 as du,Ea as dv,wa as dw,C$1 as dx,re$3 as dy,Qg as dz,O$3 as e,f$1 as f,g$3 as g,he$3 as h,hr as i,Gn$1 as j,fl as k,Ag as l,mT as m,eC as n,bg as o,pr as p,oC as q,Tg as r,si$1 as s,tC as t,ue$4 as u,vs as v,we$1 as w,iC as x,Hg as y,z$3 as z};
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@whoz-oss/coday-client",
3
- "version": "1.3.3",
3
+ "version": "1.3.4",
4
4
  "repository": "https://github.com/whoz-oss/coday",
5
5
  "type": "module",
6
6
  "dependencies": {