zohodealpos 2.4.3 → 2.4.5

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1 +1 @@
1
- {"name":"zohodealpos","version":"2.4.3"}
1
+ {"name":"zohodealpos","version":"2.4.5"}
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkzoho=self.webpackChunkzoho||[]).push([[101],{7101:(P,p,s)=>{s.r(p),s.d(p,{LoginModule:()=>T});var v=s(6814),i=s(95),m=s(4408),c=s(8069),t=s(5879),b=s(9397),y=s(6340);let u=(()=>{var o;class a{get loginResponse(){return this._loginResponse}constructor(e,n){this.httpService=e,this.router=n}login(e,n){return this.httpService.post("/api/Authentication/Login",JSON.stringify({client_id:e,client_secret:n})).pipe((0,b.b)(d=>{this._loginResponse=d,c.g.IsEmpty(d.UserID)&&c.g.IsNotEmpty(d.access_token)&&this.saveLoginResponse(d)}))}saveLoginResponse(e){localStorage.setItem("user",JSON.stringify(e))}redirectAfterLogin(){this.router.navigate(["pages/customer-tab/customer"])}}return(o=a).\u0275fac=function(e){return new(e||o)(t.LFG(y.O),t.LFG(m.F0))},o.\u0275prov=t.Yz7({token:o,factory:o.\u0275fac,providedIn:"root"}),a})();var f=s(9229);let C=(()=>{var o;class a{constructor(e,n,r,d,g){this.router=e,this.formBuilder=n,this.elementRef=r,this.authService=d,this.toastr=g;var h=JSON.parse(window.localStorage.getItem("user"));let _=new Date;null!=h&&new Date(h.expiredAt)>_&&this.router.navigate(["pages/customer-tab/customer"]),this.loginForm=this.formBuilder.group({username:["",i.kI.required],password:["",i.kI.required]})}ngOnInit(){this.elementRef.nativeElement.ownerDocument.body.style.backgroundColor="#c3f3f7"}ngOnDestroy(){this.elementRef.nativeElement.ownerDocument.body.style.backgroundColor="white"}onSubmit(){this.authService.login(this.loginForm.controls.username.value,this.loginForm.controls.password.value).subscribe({next:r=>{this.handlingSuccessLogin(r)},error:r=>{this.toastr.error(r.error,"Error")}})}handlingSuccessLogin(e){localStorage.setItem("username",this.loginForm.controls.username.value),c.g.IsNotEmpty(e.UserID)&&c.g.IsEmpty(e.access_token)?this.router.navigate(["/verify-2fa"]):this.authService.redirectAfterLogin()}}return(o=a).\u0275fac=function(e){return new(e||o)(t.Y36(m.F0),t.Y36(i.QS),t.Y36(t.SBq),t.Y36(u),t.Y36(f._W))},o.\u0275cmp=t.Xpm({type:o,selectors:[["ng-component"]],decls:37,vars:1,consts:[[1,"container"],[1,"row","mt-5","mt-md-0","align-self-center"],[1,"col-12","col-md-7","text-center"],["src","https://res.cloudinary.com/pos/image/upload/w_450/v1603265432/zohobooksxdealpos.png","alt","integration-image",1,"img-fluid"],[1,"col-12","col-md-5","order-first","order-md-last"],[1,"card"],[1,"card-body"],[1,"card-title"],[1,"ms-2","fw-normal","font-xl","robotoslab"],[1,"mt-6",3,"formGroup"],[1,"form-label-group"],["type","text","formControlName","username","name","username","id","inputUsername","placeholder","Username","required","",1,"form-control","text-start"],["for","inputPassword",1,"text-start"],["type","password","formControlName","password","name","password","id","inputPassword","placeholder","Password","required","",1,"form-control","text-start"],["type","submit",1,"btn","btn-lg","btn-primary","w-100",3,"click"],[1,"col-12","d-block","d-md-none","text-center"],[1,"pt-1rem","me-3"],["target","_blank","href","https://www.dealpos.com"],["src","https://res.cloudinary.com/pos/image/upload/POS/Images/Login/dealpos.png","alt","dealpos-logo",1,"img-fluid"],[1,"mx-5","pb-5","mb-5","d-none","d-md-block"],[1,"row","justify-content-between","align-items-center"],[1,"col-auto","d-inline-flex"],[1,"col-auto"],["href","https://changelog.dealpos.com/?categories=cat_V5iwt9cDrwQcE&view=complete","target","_blank"],[1,"pt-1rem","fst-italic"]],template:function(e,n){1&e&&(t.TgZ(0,"div",0)(1,"div",1)(2,"div",2),t._UZ(3,"img",3),t.qZA(),t.TgZ(4,"div",4)(5,"div",5)(6,"div",6)(7,"div",7)(8,"h2",8),t._uU(9,"Sign in"),t.qZA()(),t.TgZ(10,"form",9)(11,"div",10),t._UZ(12,"input",11),t.TgZ(13,"label",12),t._uU(14,"Username"),t.qZA()(),t.TgZ(15,"div",10),t._UZ(16,"input",13),t.TgZ(17,"label",12),t._uU(18,"Password"),t.qZA()(),t.TgZ(19,"button",14),t.NdJ("click",function(){return n.onSubmit()}),t._uU(20,"Sign in"),t.qZA()()()()(),t.TgZ(21,"div",15)(22,"p",16),t._uU(23,"Powered by : "),t.qZA(),t.TgZ(24,"a",17),t._UZ(25,"img",18),t.qZA()()()(),t.TgZ(26,"footer",19)(27,"div",20)(28,"div",21)(29,"p",16),t._uU(30,"Powered by : "),t.qZA(),t.TgZ(31,"a",17),t._UZ(32,"img",18),t.qZA()(),t.TgZ(33,"div",22)(34,"a",23)(35,"p",24),t._uU(36,"Version 2.4.5"),t.qZA()()()()()),2&e&&(t.xp6(10),t.Q6J("formGroup",n.loginForm))},dependencies:[i._Y,i.Fj,i.JJ,i.JL,i.Q7,i.sg,i.u],styles:[".container[_ngcontent-%COMP%]{position:absolute;max-width:100%}.passwordIcon[_ngcontent-%COMP%]{top:1.5rem;right:.5rem;position:absolute;margin:0 auto!important;cursor:pointer}.big-display[_ngcontent-%COMP%]{font-size:2rem;font-weight:500;line-height:1.2}@media (min-width: 768px){.container[_ngcontent-%COMP%]{max-width:90%;top:50%;left:50%;transform:translate(-50%) translateY(-50%)}.big-display[_ngcontent-%COMP%]{font-size:2.5rem}}@media (min-width: 1200px){.container[_ngcontent-%COMP%]{max-width:70%}.big-display[_ngcontent-%COMP%]{font-size:3rem}}html[_ngcontent-%COMP%], body[_ngcontent-%COMP%]{height:100%}body[_ngcontent-%COMP%]{display:flex;align-items:center;padding-top:40px;padding-bottom:40px}footer[_ngcontent-%COMP%]{position:absolute;bottom:0;width:90%;left:3rem}.pt-1rem[_ngcontent-%COMP%]{padding-top:1rem}.form-label-group[_ngcontent-%COMP%] > label[_ngcontent-%COMP%]{color:#666}.font-xl[_ngcontent-%COMP%]{font-size:x-large}.font125rem[_ngcontent-%COMP%]{font-size:1.25rem}.robotoslab[_ngcontent-%COMP%]{font-family:Roboto Slab}"]}),a})();var w=s(8645),x=s(9903);const O=["totpCode"],Z=[{path:"",component:C,data:{title:"Dealpos x ZohoBook"}},{path:"verify-2fa",component:(()=>{var o;class a{constructor(e,n,r,d,g){this.totpService=e,this.authService=n,this.toastrService=r,this.elementRef=d,this.router=g,this.destroy$=new w.x,this.checkOnRefreshPage()}ngOnInit(){this.elementRef.nativeElement.ownerDocument.body.style.backgroundColor="#c3f3f7"}ngAfterViewInit(){this.validationCodeEl.nativeElement.focus()}ngOnDestroy(){this.elementRef.nativeElement.ownerDocument.body.style.backgroundColor="white",this.destroy$.next(!0),this.destroy$.complete()}checkOnRefreshPage(){c.g.IsEmpty(this.authService.loginResponse)&&this.router.navigate(["/"])}onSubmit(){if(!this.validateOnVerfiyCode())return;const e=this.authService.loginResponse?.UserID;this.totpService.validateCode(this.validationCode,e).subscribe(n=>{this.authService.saveLoginResponse(n),this.authService.redirectAfterLogin()})}validateOnVerfiyCode(){let e=!0;return c.g.IsEmpty(this.validationCode)?(e=!1,this.toastrService.warning("You must enter a authentication code.","Warning")):(this.validationCode.length<6||this.validationCode.length>6)&&(e=!1,this.toastrService.warning("The authentication code must be six digits long.","Warning")),e}numberOnly(e){return c.g.numberOnly(e)}}return(o=a).\u0275fac=function(e){return new(e||o)(t.Y36(x.g),t.Y36(u),t.Y36(f._W),t.Y36(t.SBq),t.Y36(m.F0))},o.\u0275cmp=t.Xpm({type:o,selectors:[["app-totp"]],viewQuery:function(e,n){if(1&e&&t.Gf(O,5),2&e){let r;t.iGM(r=t.CRH())&&(n.validationCodeEl=r.first)}},decls:28,vars:1,consts:[[1,"container-fluid"],[1,"row","bg-white","mx-auto","totp-pane"],[1,"col-md-7","order-md-first","order-first","form-pane"],[1,"text-start","fw-bold"],[1,"mt-6","text-start"],[3,"submit"],[1,"row","mt-3"],[1,"col-12","text-start"],["for","totpCode",1,"form-label"],["type","text","data-cy","totp-code","placeholder","6-digit code","aria-label","Username","name","totp-code","id","totpCode",1,"form-control","form-control-lg","rounded","ps-6",2,"height","50px",3,"ngModel","ngModelChange","keypress"],["totpCode",""],[1,"d-md-flex","justify-content-end","mt-6"],[1,"order-md-last"],["type","submit",1,"btn","btn-lg","btn-primary","rounded-1","font-weight-normal","rounded-0"],[1,"col-md-5","order-md-last","order-last","border-start","border-secondary","d-flex","align-items-center","justify-content-center","img-pane"],[1,"d-flex","align-items-center","justify-content-center","mb-6"],["src","//res.cloudinary.com/pos/image/upload/v1666079494/POS/Images/Login/TOTP.png",1,"border-0",2,"width","50%"],[1,"fixed-bottom"],[1,"d-flex","justify-content-start","mb-11","mx-11","footer-mobile"],["target","_blank","href","http://www.dealpos.com"],["src","//res.cloudinary.com/pos/image/upload/POS/Images/Login/dealpos.png",1,"ms-3","border-0"]],template:function(e,n){1&e&&(t.TgZ(0,"div",0)(1,"div",1)(2,"div",2)(3,"h3",3),t._uU(4,"Enter time-based OTP"),t.qZA(),t.TgZ(5,"p",4),t._uU(6,"Enter the OTP generated on your authenticator app"),t.qZA(),t.TgZ(7,"form",5),t.NdJ("submit",function(){return n.onSubmit()}),t.TgZ(8,"div",6)(9,"div",7)(10,"label",8),t._uU(11,"AUTHENTICATION CODE"),t.qZA(),t.TgZ(12,"input",9,10),t.NdJ("ngModelChange",function(d){return n.validationCode=d})("keypress",function(d){return n.numberOnly(d)}),t.qZA()()(),t.TgZ(14,"div",11)(15,"div",12)(16,"button",13),t._uU(17," Verify "),t.qZA()()()()(),t.TgZ(18,"div",14)(19,"div",15),t._UZ(20,"img",16),t.qZA()()(),t.TgZ(21,"div",17)(22,"div",18)(23,"div")(24,"span"),t._uU(25,"powered by :"),t.qZA(),t._UZ(26,"a",19)(27,"img",20),t.qZA()()()()),2&e&&(t.xp6(12),t.Q6J("ngModel",n.validationCode))},dependencies:[i._Y,i.Fj,i.JJ,i.JL,i.On,i.F],styles:["input[type=submit][_ngcontent-%COMP%]{font-size:1.125rem;width:11.25rem;font-family:Roboto Slab,serif}.totp-pane[_ngcontent-%COMP%]{max-width:54rem;height:max-content;margin-top:140px}@media (max-width: 768px){.totp-pane[_ngcontent-%COMP%]{margin-top:0}}.form-pane[_ngcontent-%COMP%]{padding:3rem}@media (max-width: 768px){.form-pane[_ngcontent-%COMP%]{padding:50px 24px 30px}}@media (max-width: 768px){.img-pane[_ngcontent-%COMP%]{border:0px!important}}"]}),a})(),data:{title:"Dealpos x ZohoBook"}}];let S=(()=>{var o;class a{}return(o=a).\u0275fac=function(e){return new(e||o)},o.\u0275mod=t.oAB({type:o}),o.\u0275inj=t.cJS({imports:[m.Bz.forChild(Z),m.Bz]}),a})(),T=(()=>{var o;class a{}return(o=a).\u0275fac=function(e){return new(e||o)},o.\u0275mod=t.oAB({type:o}),o.\u0275inj=t.cJS({imports:[v.ez,i.u5,i.UX,S]}),a})()}}]);
@@ -5,7 +5,7 @@ MIT
5
5
  MIT
6
6
  The MIT License
7
7
 
8
- Copyright (c) 2022 Google LLC.
8
+ Copyright (c) 2023 Google LLC.
9
9
 
10
10
  Permission is hereby granted, free of charge, to any person obtaining a copy
11
11
  of this software and associated documentation files (the "Software"), to deal
@@ -39,7 +39,7 @@ MIT
39
39
  MIT
40
40
  The MIT License
41
41
 
42
- Copyright (c) 2022 Google LLC.
42
+ Copyright (c) 2023 Google LLC.
43
43
 
44
44
  Permission is hereby granted, free of charge, to any person obtaining a copy
45
45
  of this software and associated documentation files (the "Software"), to deal
@@ -64,7 +64,7 @@ THE SOFTWARE.
64
64
  MIT
65
65
  The MIT License
66
66
 
67
- Copyright (c) 2022 Google LLC.
67
+ Copyright (c) 2023 Google LLC.
68
68
 
69
69
  Permission is hereby granted, free of charge, to any person obtaining a copy
70
70
  of this software and associated documentation files (the "Software"), to deal
@@ -292,7 +292,7 @@ ng-http-loader
292
292
  MIT
293
293
  The MIT License (MIT)
294
294
 
295
- Copyright (c) 2017-2021 mpalourdio
295
+ Copyright (c) 2017-2023 mpalourdio
296
296
 
297
297
  Permission is hereby granted, free of charge, to any person obtaining a copy of
298
298
  this software and associated documentation files (the "Software"), to deal in
@@ -565,7 +565,7 @@ zone.js
565
565
  MIT
566
566
  The MIT License
567
567
 
568
- Copyright (c) 2010-2022 Google LLC. https://angular.io/license
568
+ Copyright (c) 2010-2023 Google LLC. https://angular.io/license
569
569
 
570
570
  Permission is hereby granted, free of charge, to any person obtaining a copy
571
571
  of this software and associated documentation files (the "Software"), to deal
@@ -0,0 +1 @@
1
+ "use strict";(self.webpackChunkzoho=self.webpackChunkzoho||[]).push([[442],{9903:(Ee,I,h)=>{h.d(I,{g:()=>l});var s=h(9862),C=h(6232),y=h(6306),V=h(5879),L=h(6340),c=h(9229);let l=(()=>{var u;class d{constructor(_,M,G){this.httpService=_,this.httpClientService=M,this.toastr=G}configure2FA(_){return this.httpService.post("/api/user/setup_2fa",_)}validateCode(_,M){let A=new s.WM({"Content-Type":"application/json","Cache-Control":"no-cache"});return A=A.append("Authorization","Bearer this.authService.loginResponse?.Token"),this.httpClientService.post("/api/authentication/validate_2fa ",{ValidationCode:_,UserID:M},{headers:A}).pipe((0,y.K)(j=>(this.toastr.error(j?.error?.Message,"Error - "+j.status),C.E)))}disableTwoFactorAuthentication(){return this.httpService.post("/api/user/Setup_2FA",{enabled:!1})}}return(u=d).\u0275fac=function(_){return new(_||u)(V.LFG(L.O),V.LFG(s.eN),V.LFG(c._W))},u.\u0275prov=V.Yz7({token:u,factory:u.\u0275fac,providedIn:"root"}),d})()},8069:(Ee,I,h)=>{h.d(I,{g:()=>V});var y,s=function(c){return c.SHOOPE="//res.cloudinary.com/pos/image/upload/v1598262220/icons/marketplace_icons/shopee.png",c.WOOCOMMERCE="//res.cloudinary.com/pos/image/upload/w_50/v1632447439/icons/WooCommerce/woocommerce-icon.webp",c.TOKOPEDIA="//res.cloudinary.com/pos/image/upload/v1598262221/icons/marketplace_icons/tokopedia.png",c.TIKTOK="//res.cloudinary.com/pos/image/upload/w_30/v1645761611/icons/Marketplace%20logo/tiktok.png",c.LAZADA="//res.cloudinary.com/pos/image/upload/w_30/v1641528003/icons/marketplace_icons/lazada.png",c.KALCARE="//res.cloudinary.com/pos/image/upload/v1654230268/icons/marketplace_icons/kalcare.png",c}(s||{}),C=function(c){return c[c.Shopee=0]="Shopee",c[c.Tokopedia=1]="Tokopedia",c[c.WooCommerce=2]="WooCommerce",c[c.None=3]="None",c[c.KalCare=4]="KalCare",c[c.ShopeeV2=5]="ShopeeV2",c[c.Tiktok=6]="Tiktok",c[c.Lazada=7]="Lazada",c}(C||{});class V{static StringFormat(l,...u){for(let d=0;d<u.length;d++)l=l.replace(`{${d}}`,u[d]);return l}static IsNotEmpty(l){return""!=l&&l!=V.GuidEmpty&&null!=l&&null!=l}static IsEmpty(l){return""==l||null==l||null==l||l==V.GuidEmpty}static FilterByID(l,u){try{const d=l.filter(f=>f.ID==u);if(d.length>0)return d[0]}catch{console.log("error filter")}return null}static DateOnly(l){return l?new Date(new Date(l).toDateString()):new Date((new Date).toDateString())}static GenerateYears(l,u,d){var f=-1;(null==u||null==u)&&(u=11),(null==d||null==d||!d)&&(f=1);for(var _=[],M=0;M<u;M++)_.push(l+M*f);return _}static lastXDays(l){let u=new Date;return new Date((new Date).setDate(u.getDate()-l))}static getChannelLogoByTypeId(l){let u;switch(l){case C.Tokopedia:u=s.TOKOPEDIA;break;case C.ShopeeV2:u=s.SHOOPE;break;case C.WooCommerce:u=s.WOOCOMMERCE;break;case C.Lazada:u=s.LAZADA;break;case C.Tiktok:u=s.TIKTOK;break;case C.KalCare:u=s.KALCARE}return u}static compare(l,u,d){return(l<u?-1:1)*(d?1:-1)}static Guid_NewGuid(){var l=(new Date).getTime();return"xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g,function(d){var f=(l+16*Math.random())%16|0;return l=Math.floor(l/16),("x"==d?f:3&f|8).toString(16)})}static numberOnly(l){const u=l.which?l.which:l.keyCode;return!(u>31&&(u<48||u>57))}}(y=V).apiBase="https://"+localStorage.getItem("Domain")+"/API/",y.GuidEmpty="00000000-0000-0000-0000-000000000000",y.DecimalMinValue="-7.922816251426434e+28",y.InputLockTimeSpan=500,y.MinDate="0001-01-01T00:00:00",y.MinTime="00:00:00",y.IntMinValue=-2147483648,y.Month=[{ID:1,Label:"January"},{ID:2,Label:"February"},{ID:3,Label:"March"},{ID:4,Label:"April"},{ID:5,Label:"May"},{ID:6,Label:"June"},{ID:7,Label:"July"},{ID:8,Label:"August"},{ID:9,Label:"September"},{ID:10,Label:"October"},{ID:11,Label:"November"},{ID:12,Label:"December"}]},95:(Ee,I,h)=>{h.d(I,{Wl:()=>ie,Zs:()=>Me,gN:()=>m,Fj:()=>Y,u:()=>Ve,sg:()=>ne,u5:()=>Mn,Cf:()=>g,JU:()=>v,a5:()=>b,JJ:()=>Ke,JL:()=>Ze,F:()=>te,On:()=>me,wV:()=>_e,UX:()=>bn,Q7:()=>re,QS:()=>An,kI:()=>xt,_Y:()=>ct});var s=h(5879),C=h(6814),y=h(7715),V=h(5592),L=h(7453),c=h(4829),l=h(9940),u=h(8251),d=h(7400),f=h(2714),M=h(7398);let G=(()=>{var n;class e{constructor(t,i){this._renderer=t,this._elementRef=i,this.onChange=o=>{},this.onTouched=()=>{}}setProperty(t,i){this._renderer.setProperty(this._elementRef.nativeElement,t,i)}registerOnTouched(t){this.onTouched=t}registerOnChange(t){this.onChange=t}setDisabledState(t){this.setProperty("disabled",t)}}return(n=e).\u0275fac=function(t){return new(t||n)(s.Y36(s.Qsj),s.Y36(s.SBq))},n.\u0275dir=s.lG2({type:n}),e})(),A=(()=>{var n;class e extends G{}return(n=e).\u0275fac=function(){let r;return function(i){return(r||(r=s.n5z(n)))(i||n)}}(),n.\u0275dir=s.lG2({type:n,features:[s.qOj]}),e})();const v=new s.OlP("NgValueAccessor"),j={provide:v,useExisting:(0,s.Gpc)(()=>ie),multi:!0};let ie=(()=>{var n;class e extends A{writeValue(t){this.setProperty("checked",t)}}return(n=e).\u0275fac=function(){let r;return function(i){return(r||(r=s.n5z(n)))(i||n)}}(),n.\u0275dir=s.lG2({type:n,selectors:[["input","type","checkbox","formControlName",""],["input","type","checkbox","formControl",""],["input","type","checkbox","ngModel",""]],hostBindings:function(t,i){1&t&&s.NdJ("change",function(a){return i.onChange(a.target.checked)})("blur",function(){return i.onTouched()})},features:[s._Bn([j]),s.qOj]}),e})();const Ft={provide:v,useExisting:(0,s.Gpc)(()=>Y),multi:!0},Nt=new s.OlP("CompositionEventMode");let Y=(()=>{var n;class e extends G{constructor(t,i,o){super(t,i),this._compositionMode=o,this._composing=!1,null==this._compositionMode&&(this._compositionMode=!function St(){const n=(0,C.q)()?(0,C.q)().getUserAgent():"";return/android (\d+)/.test(n.toLowerCase())}())}writeValue(t){this.setProperty("value",t??"")}_handleInput(t){(!this._compositionMode||this._compositionMode&&!this._composing)&&this.onChange(t)}_compositionStart(){this._composing=!0}_compositionEnd(t){this._composing=!1,this._compositionMode&&this.onChange(t)}}return(n=e).\u0275fac=function(t){return new(t||n)(s.Y36(s.Qsj),s.Y36(s.SBq),s.Y36(Nt,8))},n.\u0275dir=s.lG2({type:n,selectors:[["input","formControlName","",3,"type","checkbox"],["textarea","formControlName",""],["input","formControl","",3,"type","checkbox"],["textarea","formControl",""],["input","ngModel","",3,"type","checkbox"],["textarea","ngModel",""],["","ngDefaultControl",""]],hostBindings:function(t,i){1&t&&s.NdJ("input",function(a){return i._handleInput(a.target.value)})("blur",function(){return i.onTouched()})("compositionstart",function(){return i._compositionStart()})("compositionend",function(a){return i._compositionEnd(a.target.value)})},features:[s._Bn([Ft]),s.qOj]}),e})();function E(n){return null==n||("string"==typeof n||Array.isArray(n))&&0===n.length}function we(n){return null!=n&&"number"==typeof n.length}const g=new s.OlP("NgValidators"),w=new s.OlP("NgAsyncValidators"),Gt=/^(?=.{1,254}$)(?=.{1,64}@)[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-zA-Z0-9!#$%&'*+/=?^_`{|}~-]+)*@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*$/;class xt{static min(e){return function Oe(n){return e=>{if(E(e.value)||E(n))return null;const r=parseFloat(e.value);return!isNaN(r)&&r<n?{min:{min:n,actual:e.value}}:null}}(e)}static max(e){return function Fe(n){return e=>{if(E(e.value)||E(n))return null;const r=parseFloat(e.value);return!isNaN(r)&&r>n?{max:{max:n,actual:e.value}}:null}}(e)}static required(e){return Se(e)}static requiredTrue(e){return Ne(e)}static email(e){return function Ge(n){return E(n.value)||Gt.test(n.value)?null:{email:!0}}(e)}static minLength(e){return function xe(n){return e=>E(e.value)||!we(e.value)?null:e.value.length<n?{minlength:{requiredLength:n,actualLength:e.value.length}}:null}(e)}static maxLength(e){return function Ie(n){return e=>we(e.value)&&e.value.length>n?{maxlength:{requiredLength:n,actualLength:e.value.length}}:null}(e)}static pattern(e){return function ke(n){if(!n)return W;let e,r;return"string"==typeof n?(r="","^"!==n.charAt(0)&&(r+="^"),r+=n,"$"!==n.charAt(n.length-1)&&(r+="$"),e=new RegExp(r)):(r=n.toString(),e=n),t=>{if(E(t.value))return null;const i=t.value;return e.test(i)?null:{pattern:{requiredPattern:r,actualValue:i}}}}(e)}static nullValidator(e){return null}static compose(e){return Re(e)}static composeAsync(e){return Le(e)}}function Se(n){return E(n.value)?{required:!0}:null}function Ne(n){return!0===n.value?null:{required:!0}}function W(n){return null}function Be(n){return null!=n}function Pe(n){return(0,s.QGY)(n)?(0,y.D)(n):n}function Te(n){let e={};return n.forEach(r=>{e=null!=r?{...e,...r}:e}),0===Object.keys(e).length?null:e}function He(n,e){return e.map(r=>r(n))}function Ue(n){return n.map(e=>function It(n){return!n.validate}(e)?e:r=>e.validate(r))}function Re(n){if(!n)return null;const e=n.filter(Be);return 0==e.length?null:function(r){return Te(He(r,e))}}function se(n){return null!=n?Re(Ue(n)):null}function Le(n){if(!n)return null;const e=n.filter(Be);return 0==e.length?null:function(r){return function _(...n){const e=(0,l.jO)(n),{args:r,keys:t}=(0,L.D)(n),i=new V.y(o=>{const{length:a}=r;if(!a)return void o.complete();const p=new Array(a);let D=a,N=a;for(let O=0;O<a;O++){let be=!1;(0,c.Xf)(r[O]).subscribe((0,u.x)(o,En=>{be||(be=!0,N--),p[O]=En},()=>D--,void 0,()=>{(!D||!be)&&(N||o.next(t?(0,f.n)(t,p):p),o.complete())}))}});return e?i.pipe((0,d.Z)(e)):i}(He(r,e).map(Pe)).pipe((0,M.U)(Te))}}function oe(n){return null!=n?Le(Ue(n)):null}function je(n,e){return null===n?[e]:Array.isArray(n)?[...n,e]:[n,e]}function Ye(n){return n._rawValidators}function We(n){return n._rawAsyncValidators}function ae(n){return n?Array.isArray(n)?n:[n]:[]}function z(n,e){return Array.isArray(n)?n.includes(e):n===e}function ze(n,e){const r=ae(e);return ae(n).forEach(i=>{z(r,i)||r.push(i)}),r}function qe(n,e){return ae(e).filter(r=>!z(n,r))}class $e{constructor(){this._rawValidators=[],this._rawAsyncValidators=[],this._onDestroyCallbacks=[]}get value(){return this.control?this.control.value:null}get valid(){return this.control?this.control.valid:null}get invalid(){return this.control?this.control.invalid:null}get pending(){return this.control?this.control.pending:null}get disabled(){return this.control?this.control.disabled:null}get enabled(){return this.control?this.control.enabled:null}get errors(){return this.control?this.control.errors:null}get pristine(){return this.control?this.control.pristine:null}get dirty(){return this.control?this.control.dirty:null}get touched(){return this.control?this.control.touched:null}get status(){return this.control?this.control.status:null}get untouched(){return this.control?this.control.untouched:null}get statusChanges(){return this.control?this.control.statusChanges:null}get valueChanges(){return this.control?this.control.valueChanges:null}get path(){return null}_setValidators(e){this._rawValidators=e||[],this._composedValidatorFn=se(this._rawValidators)}_setAsyncValidators(e){this._rawAsyncValidators=e||[],this._composedAsyncValidatorFn=oe(this._rawAsyncValidators)}get validator(){return this._composedValidatorFn||null}get asyncValidator(){return this._composedAsyncValidatorFn||null}_registerOnDestroy(e){this._onDestroyCallbacks.push(e)}_invokeOnDestroyCallbacks(){this._onDestroyCallbacks.forEach(e=>e()),this._onDestroyCallbacks=[]}reset(e=void 0){this.control&&this.control.reset(e)}hasError(e,r){return!!this.control&&this.control.hasError(e,r)}getError(e,r){return this.control?this.control.getError(e,r):null}}class m extends $e{get formDirective(){return null}get path(){return null}}class b extends $e{constructor(){super(...arguments),this._parent=null,this.name=null,this.valueAccessor=null}}class Je{constructor(e){this._cd=e}get isTouched(){return!!this._cd?.control?.touched}get isUntouched(){return!!this._cd?.control?.untouched}get isPristine(){return!!this._cd?.control?.pristine}get isDirty(){return!!this._cd?.control?.dirty}get isValid(){return!!this._cd?.control?.valid}get isInvalid(){return!!this._cd?.control?.invalid}get isPending(){return!!this._cd?.control?.pending}get isSubmitted(){return!!this._cd?.submitted}}let Ke=(()=>{var n;class e extends Je{constructor(t){super(t)}}return(n=e).\u0275fac=function(t){return new(t||n)(s.Y36(b,2))},n.\u0275dir=s.lG2({type:n,selectors:[["","formControlName",""],["","ngModel",""],["","formControl",""]],hostVars:14,hostBindings:function(t,i){2&t&&s.ekj("ng-untouched",i.isUntouched)("ng-touched",i.isTouched)("ng-pristine",i.isPristine)("ng-dirty",i.isDirty)("ng-valid",i.isValid)("ng-invalid",i.isInvalid)("ng-pending",i.isPending)},features:[s.qOj]}),e})(),Ze=(()=>{var n;class e extends Je{constructor(t){super(t)}}return(n=e).\u0275fac=function(t){return new(t||n)(s.Y36(m,10))},n.\u0275dir=s.lG2({type:n,selectors:[["","formGroupName",""],["","formArrayName",""],["","ngModelGroup",""],["","formGroup",""],["form",3,"ngNoForm",""],["","ngForm",""]],hostVars:16,hostBindings:function(t,i){2&t&&s.ekj("ng-untouched",i.isUntouched)("ng-touched",i.isTouched)("ng-pristine",i.isPristine)("ng-dirty",i.isDirty)("ng-valid",i.isValid)("ng-invalid",i.isInvalid)("ng-pending",i.isPending)("ng-submitted",i.isSubmitted)},features:[s.qOj]}),e})();const k="VALID",$="INVALID",x="PENDING",B="DISABLED";function ce(n){return(J(n)?n.validators:n)||null}function de(n,e){return(J(e)?e.asyncValidators:n)||null}function J(n){return null!=n&&!Array.isArray(n)&&"object"==typeof n}function Xe(n,e,r){const t=n.controls;if(!(e?Object.keys(t):t).length)throw new s.vHH(1e3,"");if(!t[r])throw new s.vHH(1001,"")}function et(n,e,r){n._forEachChild((t,i)=>{if(void 0===r[i])throw new s.vHH(1002,"")})}class K{constructor(e,r){this._pendingDirty=!1,this._hasOwnPendingAsyncValidator=!1,this._pendingTouched=!1,this._onCollectionChange=()=>{},this._parent=null,this.pristine=!0,this.touched=!1,this._onDisabledChange=[],this._assignValidators(e),this._assignAsyncValidators(r)}get validator(){return this._composedValidatorFn}set validator(e){this._rawValidators=this._composedValidatorFn=e}get asyncValidator(){return this._composedAsyncValidatorFn}set asyncValidator(e){this._rawAsyncValidators=this._composedAsyncValidatorFn=e}get parent(){return this._parent}get valid(){return this.status===k}get invalid(){return this.status===$}get pending(){return this.status==x}get disabled(){return this.status===B}get enabled(){return this.status!==B}get dirty(){return!this.pristine}get untouched(){return!this.touched}get updateOn(){return this._updateOn?this._updateOn:this.parent?this.parent.updateOn:"change"}setValidators(e){this._assignValidators(e)}setAsyncValidators(e){this._assignAsyncValidators(e)}addValidators(e){this.setValidators(ze(e,this._rawValidators))}addAsyncValidators(e){this.setAsyncValidators(ze(e,this._rawAsyncValidators))}removeValidators(e){this.setValidators(qe(e,this._rawValidators))}removeAsyncValidators(e){this.setAsyncValidators(qe(e,this._rawAsyncValidators))}hasValidator(e){return z(this._rawValidators,e)}hasAsyncValidator(e){return z(this._rawAsyncValidators,e)}clearValidators(){this.validator=null}clearAsyncValidators(){this.asyncValidator=null}markAsTouched(e={}){this.touched=!0,this._parent&&!e.onlySelf&&this._parent.markAsTouched(e)}markAllAsTouched(){this.markAsTouched({onlySelf:!0}),this._forEachChild(e=>e.markAllAsTouched())}markAsUntouched(e={}){this.touched=!1,this._pendingTouched=!1,this._forEachChild(r=>{r.markAsUntouched({onlySelf:!0})}),this._parent&&!e.onlySelf&&this._parent._updateTouched(e)}markAsDirty(e={}){this.pristine=!1,this._parent&&!e.onlySelf&&this._parent.markAsDirty(e)}markAsPristine(e={}){this.pristine=!0,this._pendingDirty=!1,this._forEachChild(r=>{r.markAsPristine({onlySelf:!0})}),this._parent&&!e.onlySelf&&this._parent._updatePristine(e)}markAsPending(e={}){this.status=x,!1!==e.emitEvent&&this.statusChanges.emit(this.status),this._parent&&!e.onlySelf&&this._parent.markAsPending(e)}disable(e={}){const r=this._parentMarkedDirty(e.onlySelf);this.status=B,this.errors=null,this._forEachChild(t=>{t.disable({...e,onlySelf:!0})}),this._updateValue(),!1!==e.emitEvent&&(this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._updateAncestors({...e,skipPristineCheck:r}),this._onDisabledChange.forEach(t=>t(!0))}enable(e={}){const r=this._parentMarkedDirty(e.onlySelf);this.status=k,this._forEachChild(t=>{t.enable({...e,onlySelf:!0})}),this.updateValueAndValidity({onlySelf:!0,emitEvent:e.emitEvent}),this._updateAncestors({...e,skipPristineCheck:r}),this._onDisabledChange.forEach(t=>t(!1))}_updateAncestors(e){this._parent&&!e.onlySelf&&(this._parent.updateValueAndValidity(e),e.skipPristineCheck||this._parent._updatePristine(),this._parent._updateTouched())}setParent(e){this._parent=e}getRawValue(){return this.value}updateValueAndValidity(e={}){this._setInitialStatus(),this._updateValue(),this.enabled&&(this._cancelExistingSubscription(),this.errors=this._runValidator(),this.status=this._calculateStatus(),(this.status===k||this.status===x)&&this._runAsyncValidator(e.emitEvent)),!1!==e.emitEvent&&(this.valueChanges.emit(this.value),this.statusChanges.emit(this.status)),this._parent&&!e.onlySelf&&this._parent.updateValueAndValidity(e)}_updateTreeValidity(e={emitEvent:!0}){this._forEachChild(r=>r._updateTreeValidity(e)),this.updateValueAndValidity({onlySelf:!0,emitEvent:e.emitEvent})}_setInitialStatus(){this.status=this._allControlsDisabled()?B:k}_runValidator(){return this.validator?this.validator(this):null}_runAsyncValidator(e){if(this.asyncValidator){this.status=x,this._hasOwnPendingAsyncValidator=!0;const r=Pe(this.asyncValidator(this));this._asyncValidationSubscription=r.subscribe(t=>{this._hasOwnPendingAsyncValidator=!1,this.setErrors(t,{emitEvent:e})})}}_cancelExistingSubscription(){this._asyncValidationSubscription&&(this._asyncValidationSubscription.unsubscribe(),this._hasOwnPendingAsyncValidator=!1)}setErrors(e,r={}){this.errors=e,this._updateControlsErrors(!1!==r.emitEvent)}get(e){let r=e;return null==r||(Array.isArray(r)||(r=r.split(".")),0===r.length)?null:r.reduce((t,i)=>t&&t._find(i),this)}getError(e,r){const t=r?this.get(r):this;return t&&t.errors?t.errors[e]:null}hasError(e,r){return!!this.getError(e,r)}get root(){let e=this;for(;e._parent;)e=e._parent;return e}_updateControlsErrors(e){this.status=this._calculateStatus(),e&&this.statusChanges.emit(this.status),this._parent&&this._parent._updateControlsErrors(e)}_initObservables(){this.valueChanges=new s.vpe,this.statusChanges=new s.vpe}_calculateStatus(){return this._allControlsDisabled()?B:this.errors?$:this._hasOwnPendingAsyncValidator||this._anyControlsHaveStatus(x)?x:this._anyControlsHaveStatus($)?$:k}_anyControlsHaveStatus(e){return this._anyControls(r=>r.status===e)}_anyControlsDirty(){return this._anyControls(e=>e.dirty)}_anyControlsTouched(){return this._anyControls(e=>e.touched)}_updatePristine(e={}){this.pristine=!this._anyControlsDirty(),this._parent&&!e.onlySelf&&this._parent._updatePristine(e)}_updateTouched(e={}){this.touched=this._anyControlsTouched(),this._parent&&!e.onlySelf&&this._parent._updateTouched(e)}_registerOnCollectionChange(e){this._onCollectionChange=e}_setUpdateStrategy(e){J(e)&&null!=e.updateOn&&(this._updateOn=e.updateOn)}_parentMarkedDirty(e){return!e&&!(!this._parent||!this._parent.dirty)&&!this._parent._anyControlsDirty()}_find(e){return null}_assignValidators(e){this._rawValidators=Array.isArray(e)?e.slice():e,this._composedValidatorFn=function Tt(n){return Array.isArray(n)?se(n):n||null}(this._rawValidators)}_assignAsyncValidators(e){this._rawAsyncValidators=Array.isArray(e)?e.slice():e,this._composedAsyncValidatorFn=function Ht(n){return Array.isArray(n)?oe(n):n||null}(this._rawAsyncValidators)}}class P extends K{constructor(e,r,t){super(ce(r),de(t,r)),this.controls=e,this._initObservables(),this._setUpdateStrategy(r),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}registerControl(e,r){return this.controls[e]?this.controls[e]:(this.controls[e]=r,r.setParent(this),r._registerOnCollectionChange(this._onCollectionChange),r)}addControl(e,r,t={}){this.registerControl(e,r),this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}removeControl(e,r={}){this.controls[e]&&this.controls[e]._registerOnCollectionChange(()=>{}),delete this.controls[e],this.updateValueAndValidity({emitEvent:r.emitEvent}),this._onCollectionChange()}setControl(e,r,t={}){this.controls[e]&&this.controls[e]._registerOnCollectionChange(()=>{}),delete this.controls[e],r&&this.registerControl(e,r),this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}contains(e){return this.controls.hasOwnProperty(e)&&this.controls[e].enabled}setValue(e,r={}){et(this,0,e),Object.keys(e).forEach(t=>{Xe(this,!0,t),this.controls[t].setValue(e[t],{onlySelf:!0,emitEvent:r.emitEvent})}),this.updateValueAndValidity(r)}patchValue(e,r={}){null!=e&&(Object.keys(e).forEach(t=>{const i=this.controls[t];i&&i.patchValue(e[t],{onlySelf:!0,emitEvent:r.emitEvent})}),this.updateValueAndValidity(r))}reset(e={},r={}){this._forEachChild((t,i)=>{t.reset(e[i],{onlySelf:!0,emitEvent:r.emitEvent})}),this._updatePristine(r),this._updateTouched(r),this.updateValueAndValidity(r)}getRawValue(){return this._reduceChildren({},(e,r,t)=>(e[t]=r.getRawValue(),e))}_syncPendingControls(){let e=this._reduceChildren(!1,(r,t)=>!!t._syncPendingControls()||r);return e&&this.updateValueAndValidity({onlySelf:!0}),e}_forEachChild(e){Object.keys(this.controls).forEach(r=>{const t=this.controls[r];t&&e(t,r)})}_setUpControls(){this._forEachChild(e=>{e.setParent(this),e._registerOnCollectionChange(this._onCollectionChange)})}_updateValue(){this.value=this._reduceValue()}_anyControls(e){for(const[r,t]of Object.entries(this.controls))if(this.contains(r)&&e(t))return!0;return!1}_reduceValue(){return this._reduceChildren({},(r,t,i)=>((t.enabled||this.disabled)&&(r[i]=t.value),r))}_reduceChildren(e,r){let t=e;return this._forEachChild((i,o)=>{t=r(t,i,o)}),t}_allControlsDisabled(){for(const e of Object.keys(this.controls))if(this.controls[e].enabled)return!1;return Object.keys(this.controls).length>0||this.disabled}_find(e){return this.controls.hasOwnProperty(e)?this.controls[e]:null}}class tt extends P{}const F=new s.OlP("CallSetDisabledState",{providedIn:"root",factory:()=>T}),T="always";function Z(n,e){return[...e.path,n]}function H(n,e,r=T){he(n,e),e.valueAccessor.writeValue(n.value),(n.disabled||"always"===r)&&e.valueAccessor.setDisabledState?.(n.disabled),function Rt(n,e){e.valueAccessor.registerOnChange(r=>{n._pendingValue=r,n._pendingChange=!0,n._pendingDirty=!0,"change"===n.updateOn&&nt(n,e)})}(n,e),function jt(n,e){const r=(t,i)=>{e.valueAccessor.writeValue(t),i&&e.viewToModelUpdate(t)};n.registerOnChange(r),e._registerOnDestroy(()=>{n._unregisterOnChange(r)})}(n,e),function Lt(n,e){e.valueAccessor.registerOnTouched(()=>{n._pendingTouched=!0,"blur"===n.updateOn&&n._pendingChange&&nt(n,e),"submit"!==n.updateOn&&n.markAsTouched()})}(n,e),function Ut(n,e){if(e.valueAccessor.setDisabledState){const r=t=>{e.valueAccessor.setDisabledState(t)};n.registerOnDisabledChange(r),e._registerOnDestroy(()=>{n._unregisterOnDisabledChange(r)})}}(n,e)}function Q(n,e,r=!0){const t=()=>{};e.valueAccessor&&(e.valueAccessor.registerOnChange(t),e.valueAccessor.registerOnTouched(t)),ee(n,e),n&&(e._invokeOnDestroyCallbacks(),n._registerOnCollectionChange(()=>{}))}function X(n,e){n.forEach(r=>{r.registerOnValidatorChange&&r.registerOnValidatorChange(e)})}function he(n,e){const r=Ye(n);null!==e.validator?n.setValidators(je(r,e.validator)):"function"==typeof r&&n.setValidators([r]);const t=We(n);null!==e.asyncValidator?n.setAsyncValidators(je(t,e.asyncValidator)):"function"==typeof t&&n.setAsyncValidators([t]);const i=()=>n.updateValueAndValidity();X(e._rawValidators,i),X(e._rawAsyncValidators,i)}function ee(n,e){let r=!1;if(null!==n){if(null!==e.validator){const i=Ye(n);if(Array.isArray(i)&&i.length>0){const o=i.filter(a=>a!==e.validator);o.length!==i.length&&(r=!0,n.setValidators(o))}}if(null!==e.asyncValidator){const i=We(n);if(Array.isArray(i)&&i.length>0){const o=i.filter(a=>a!==e.asyncValidator);o.length!==i.length&&(r=!0,n.setAsyncValidators(o))}}}const t=()=>{};return X(e._rawValidators,t),X(e._rawAsyncValidators,t),r}function nt(n,e){n._pendingDirty&&n.markAsDirty(),n.setValue(n._pendingValue,{emitModelToViewChange:!1}),e.viewToModelUpdate(n._pendingValue),n._pendingChange=!1}function rt(n,e){he(n,e)}function pe(n,e){if(!n.hasOwnProperty("model"))return!1;const r=n.model;return!!r.isFirstChange()||!Object.is(e,r.currentValue)}function it(n,e){n._syncPendingControls(),e.forEach(r=>{const t=r.control;"submit"===t.updateOn&&t._pendingChange&&(r.viewToModelUpdate(t._pendingValue),t._pendingChange=!1)})}function ge(n,e){if(!e)return null;let r,t,i;return Array.isArray(e),e.forEach(o=>{o.constructor===Y?r=o:function zt(n){return Object.getPrototypeOf(n.constructor)===A}(o)?t=o:i=o}),i||t||r||null}const $t={provide:m,useExisting:(0,s.Gpc)(()=>te)},U=(()=>Promise.resolve())();let te=(()=>{var n;class e extends m{constructor(t,i,o){super(),this.callSetDisabledState=o,this.submitted=!1,this._directives=new Set,this.ngSubmit=new s.vpe,this.form=new P({},se(t),oe(i))}ngAfterViewInit(){this._setUpdateStrategy()}get formDirective(){return this}get control(){return this.form}get path(){return[]}get controls(){return this.form.controls}addControl(t){U.then(()=>{const i=this._findContainer(t.path);t.control=i.registerControl(t.name,t.control),H(t.control,t,this.callSetDisabledState),t.control.updateValueAndValidity({emitEvent:!1}),this._directives.add(t)})}getControl(t){return this.form.get(t.path)}removeControl(t){U.then(()=>{const i=this._findContainer(t.path);i&&i.removeControl(t.name),this._directives.delete(t)})}addFormGroup(t){U.then(()=>{const i=this._findContainer(t.path),o=new P({});rt(o,t),i.registerControl(t.name,o),o.updateValueAndValidity({emitEvent:!1})})}removeFormGroup(t){U.then(()=>{const i=this._findContainer(t.path);i&&i.removeControl(t.name)})}getFormGroup(t){return this.form.get(t.path)}updateModel(t,i){U.then(()=>{this.form.get(t.path).setValue(i)})}setValue(t){this.control.setValue(t)}onSubmit(t){return this.submitted=!0,it(this.form,this._directives),this.ngSubmit.emit(t),"dialog"===t?.target?.method}onReset(){this.resetForm()}resetForm(t=void 0){this.form.reset(t),this.submitted=!1}_setUpdateStrategy(){this.options&&null!=this.options.updateOn&&(this.form._updateOn=this.options.updateOn)}_findContainer(t){return t.pop(),t.length?this.form.get(t):this.form}}return(n=e).\u0275fac=function(t){return new(t||n)(s.Y36(g,10),s.Y36(w,10),s.Y36(F,8))},n.\u0275dir=s.lG2({type:n,selectors:[["form",3,"ngNoForm","",3,"formGroup",""],["ng-form"],["","ngForm",""]],hostBindings:function(t,i){1&t&&s.NdJ("submit",function(a){return i.onSubmit(a)})("reset",function(){return i.onReset()})},inputs:{options:["ngFormOptions","options"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],features:[s._Bn([$t]),s.qOj]}),e})();function st(n,e){const r=n.indexOf(e);r>-1&&n.splice(r,1)}function ot(n){return"object"==typeof n&&null!==n&&2===Object.keys(n).length&&"value"in n&&"disabled"in n}const R=class extends K{constructor(e=null,r,t){super(ce(r),de(t,r)),this.defaultValue=null,this._onChange=[],this._pendingChange=!1,this._applyFormState(e),this._setUpdateStrategy(r),this._initObservables(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator}),J(r)&&(r.nonNullable||r.initialValueIsDefault)&&(this.defaultValue=ot(e)?e.value:e)}setValue(e,r={}){this.value=this._pendingValue=e,this._onChange.length&&!1!==r.emitModelToViewChange&&this._onChange.forEach(t=>t(this.value,!1!==r.emitViewToModelChange)),this.updateValueAndValidity(r)}patchValue(e,r={}){this.setValue(e,r)}reset(e=this.defaultValue,r={}){this._applyFormState(e),this.markAsPristine(r),this.markAsUntouched(r),this.setValue(this.value,r),this._pendingChange=!1}_updateValue(){}_anyControls(e){return!1}_allControlsDisabled(){return this.disabled}registerOnChange(e){this._onChange.push(e)}_unregisterOnChange(e){st(this._onChange,e)}registerOnDisabledChange(e){this._onDisabledChange.push(e)}_unregisterOnDisabledChange(e){st(this._onDisabledChange,e)}_forEachChild(e){}_syncPendingControls(){return!("submit"!==this.updateOn||(this._pendingDirty&&this.markAsDirty(),this._pendingTouched&&this.markAsTouched(),!this._pendingChange)||(this.setValue(this._pendingValue,{onlySelf:!0,emitModelToViewChange:!1}),0))}_applyFormState(e){ot(e)?(this.value=this._pendingValue=e.value,e.disabled?this.disable({onlySelf:!0,emitEvent:!1}):this.enable({onlySelf:!0,emitEvent:!1})):this.value=this._pendingValue=e}},Zt={provide:b,useExisting:(0,s.Gpc)(()=>me)},ut=(()=>Promise.resolve())();let me=(()=>{var n;class e extends b{constructor(t,i,o,a,p,D){super(),this._changeDetectorRef=p,this.callSetDisabledState=D,this.control=new R,this._registered=!1,this.name="",this.update=new s.vpe,this._parent=t,this._setValidators(i),this._setAsyncValidators(o),this.valueAccessor=ge(0,a)}ngOnChanges(t){if(this._checkForErrors(),!this._registered||"name"in t){if(this._registered&&(this._checkName(),this.formDirective)){const i=t.name.previousValue;this.formDirective.removeControl({name:i,path:this._getPath(i)})}this._setUpControl()}"isDisabled"in t&&this._updateDisabled(t),pe(t,this.viewModel)&&(this._updateValue(this.model),this.viewModel=this.model)}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}get path(){return this._getPath(this.name)}get formDirective(){return this._parent?this._parent.formDirective:null}viewToModelUpdate(t){this.viewModel=t,this.update.emit(t)}_setUpControl(){this._setUpdateStrategy(),this._isStandalone()?this._setUpStandalone():this.formDirective.addControl(this),this._registered=!0}_setUpdateStrategy(){this.options&&null!=this.options.updateOn&&(this.control._updateOn=this.options.updateOn)}_isStandalone(){return!this._parent||!(!this.options||!this.options.standalone)}_setUpStandalone(){H(this.control,this,this.callSetDisabledState),this.control.updateValueAndValidity({emitEvent:!1})}_checkForErrors(){this._isStandalone()||this._checkParentType(),this._checkName()}_checkParentType(){}_checkName(){this.options&&this.options.name&&(this.name=this.options.name),this._isStandalone()}_updateValue(t){ut.then(()=>{this.control.setValue(t,{emitViewToModelChange:!1}),this._changeDetectorRef?.markForCheck()})}_updateDisabled(t){const i=t.isDisabled.currentValue,o=0!==i&&(0,s.VuI)(i);ut.then(()=>{o&&!this.control.disabled?this.control.disable():!o&&this.control.disabled&&this.control.enable(),this._changeDetectorRef?.markForCheck()})}_getPath(t){return this._parent?Z(t,this._parent):[t]}}return(n=e).\u0275fac=function(t){return new(t||n)(s.Y36(m,9),s.Y36(g,10),s.Y36(w,10),s.Y36(v,10),s.Y36(s.sBO,8),s.Y36(F,8))},n.\u0275dir=s.lG2({type:n,selectors:[["","ngModel","",3,"formControlName","",3,"formControl",""]],inputs:{name:"name",isDisabled:["disabled","isDisabled"],model:["ngModel","model"],options:["ngModelOptions","options"]},outputs:{update:"ngModelChange"},exportAs:["ngModel"],features:[s._Bn([Zt]),s.qOj,s.TTD]}),e})(),ct=(()=>{var n;class e{}return(n=e).\u0275fac=function(t){return new(t||n)},n.\u0275dir=s.lG2({type:n,selectors:[["form",3,"ngNoForm","",3,"ngNativeValidate",""]],hostAttrs:["novalidate",""]}),e})();const Qt={provide:v,useExisting:(0,s.Gpc)(()=>_e),multi:!0};let _e=(()=>{var n;class e extends A{writeValue(t){this.setProperty("value",t??"")}registerOnChange(t){this.onChange=i=>{t(""==i?null:parseFloat(i))}}}return(n=e).\u0275fac=function(){let r;return function(i){return(r||(r=s.n5z(n)))(i||n)}}(),n.\u0275dir=s.lG2({type:n,selectors:[["input","type","number","formControlName",""],["input","type","number","formControl",""],["input","type","number","ngModel",""]],hostBindings:function(t,i){1&t&&s.NdJ("input",function(a){return i.onChange(a.target.value)})("blur",function(){return i.onTouched()})},features:[s._Bn([Qt]),s.qOj]}),e})(),dt=(()=>{var n;class e{}return(n=e).\u0275fac=function(t){return new(t||n)},n.\u0275mod=s.oAB({type:n}),n.\u0275inj=s.cJS({}),e})();const ye=new s.OlP("NgModelWithFormControlWarning"),rn={provide:m,useExisting:(0,s.Gpc)(()=>ne)};let ne=(()=>{var n;class e extends m{constructor(t,i,o){super(),this.callSetDisabledState=o,this.submitted=!1,this._onCollectionChange=()=>this._updateDomValue(),this.directives=[],this.form=null,this.ngSubmit=new s.vpe,this._setValidators(t),this._setAsyncValidators(i)}ngOnChanges(t){this._checkFormPresent(),t.hasOwnProperty("form")&&(this._updateValidators(),this._updateDomValue(),this._updateRegistrations(),this._oldForm=this.form)}ngOnDestroy(){this.form&&(ee(this.form,this),this.form._onCollectionChange===this._onCollectionChange&&this.form._registerOnCollectionChange(()=>{}))}get formDirective(){return this}get control(){return this.form}get path(){return[]}addControl(t){const i=this.form.get(t.path);return H(i,t,this.callSetDisabledState),i.updateValueAndValidity({emitEvent:!1}),this.directives.push(t),i}getControl(t){return this.form.get(t.path)}removeControl(t){Q(t.control||null,t,!1),function qt(n,e){const r=n.indexOf(e);r>-1&&n.splice(r,1)}(this.directives,t)}addFormGroup(t){this._setUpFormContainer(t)}removeFormGroup(t){this._cleanUpFormContainer(t)}getFormGroup(t){return this.form.get(t.path)}addFormArray(t){this._setUpFormContainer(t)}removeFormArray(t){this._cleanUpFormContainer(t)}getFormArray(t){return this.form.get(t.path)}updateModel(t,i){this.form.get(t.path).setValue(i)}onSubmit(t){return this.submitted=!0,it(this.form,this.directives),this.ngSubmit.emit(t),"dialog"===t?.target?.method}onReset(){this.resetForm()}resetForm(t=void 0){this.form.reset(t),this.submitted=!1}_updateDomValue(){this.directives.forEach(t=>{const i=t.control,o=this.form.get(t.path);i!==o&&(Q(i||null,t),(n=>n instanceof R)(o)&&(H(o,t,this.callSetDisabledState),t.control=o))}),this.form._updateTreeValidity({emitEvent:!1})}_setUpFormContainer(t){const i=this.form.get(t.path);rt(i,t),i.updateValueAndValidity({emitEvent:!1})}_cleanUpFormContainer(t){if(this.form){const i=this.form.get(t.path);i&&function Yt(n,e){return ee(n,e)}(i,t)&&i.updateValueAndValidity({emitEvent:!1})}}_updateRegistrations(){this.form._registerOnCollectionChange(this._onCollectionChange),this._oldForm&&this._oldForm._registerOnCollectionChange(()=>{})}_updateValidators(){he(this.form,this),this._oldForm&&ee(this._oldForm,this)}_checkFormPresent(){}}return(n=e).\u0275fac=function(t){return new(t||n)(s.Y36(g,10),s.Y36(w,10),s.Y36(F,8))},n.\u0275dir=s.lG2({type:n,selectors:[["","formGroup",""]],hostBindings:function(t,i){1&t&&s.NdJ("submit",function(a){return i.onSubmit(a)})("reset",function(){return i.onReset()})},inputs:{form:["formGroup","form"]},outputs:{ngSubmit:"ngSubmit"},exportAs:["ngForm"],features:[s._Bn([rn]),s.qOj,s.TTD]}),e})();const an={provide:b,useExisting:(0,s.Gpc)(()=>Ve)};let Ve=(()=>{var n;class e extends b{set isDisabled(t){}constructor(t,i,o,a,p){super(),this._ngModelWarningConfig=p,this._added=!1,this.name=null,this.update=new s.vpe,this._ngModelWarningSent=!1,this._parent=t,this._setValidators(i),this._setAsyncValidators(o),this.valueAccessor=ge(0,a)}ngOnChanges(t){this._added||this._setUpControl(),pe(t,this.viewModel)&&(this.viewModel=this.model,this.formDirective.updateModel(this,this.model))}ngOnDestroy(){this.formDirective&&this.formDirective.removeControl(this)}viewToModelUpdate(t){this.viewModel=t,this.update.emit(t)}get path(){return Z(null==this.name?this.name:this.name.toString(),this._parent)}get formDirective(){return this._parent?this._parent.formDirective:null}_checkParentType(){}_setUpControl(){this._checkParentType(),this.control=this.formDirective.addControl(this),this._added=!0}}return(n=e)._ngModelWarningSentOnce=!1,n.\u0275fac=function(t){return new(t||n)(s.Y36(m,13),s.Y36(g,10),s.Y36(w,10),s.Y36(v,10),s.Y36(ye,8))},n.\u0275dir=s.lG2({type:n,selectors:[["","formControlName",""]],inputs:{name:["formControlName","name"],isDisabled:["disabled","isDisabled"],model:["ngModel","model"]},outputs:{update:"ngModelChange"},features:[s._Bn([an]),s.qOj,s.TTD]}),e})(),S=(()=>{var n;class e{constructor(){this._validator=W}ngOnChanges(t){if(this.inputName in t){const i=this.normalizeInput(t[this.inputName].currentValue);this._enabled=this.enabled(i),this._validator=this._enabled?this.createValidator(i):W,this._onChange&&this._onChange()}}validate(t){return this._validator(t)}registerOnValidatorChange(t){this._onChange=t}enabled(t){return null!=t}}return(n=e).\u0275fac=function(t){return new(t||n)},n.\u0275dir=s.lG2({type:n,features:[s.TTD]}),e})();const mn={provide:g,useExisting:(0,s.Gpc)(()=>re),multi:!0},_n={provide:g,useExisting:(0,s.Gpc)(()=>Me),multi:!0};let re=(()=>{var n;class e extends S{constructor(){super(...arguments),this.inputName="required",this.normalizeInput=s.VuI,this.createValidator=t=>Se}enabled(t){return t}}return(n=e).\u0275fac=function(){let r;return function(i){return(r||(r=s.n5z(n)))(i||n)}}(),n.\u0275dir=s.lG2({type:n,selectors:[["","required","","formControlName","",3,"type","checkbox"],["","required","","formControl","",3,"type","checkbox"],["","required","","ngModel","",3,"type","checkbox"]],hostVars:1,hostBindings:function(t,i){2&t&&s.uIk("required",i._enabled?"":null)},inputs:{required:"required"},features:[s._Bn([mn]),s.qOj]}),e})(),Me=(()=>{var n;class e extends re{constructor(){super(...arguments),this.createValidator=t=>Ne}}return(n=e).\u0275fac=function(){let r;return function(i){return(r||(r=s.n5z(n)))(i||n)}}(),n.\u0275dir=s.lG2({type:n,selectors:[["input","type","checkbox","required","","formControlName",""],["input","type","checkbox","required","","formControl",""],["input","type","checkbox","required","","ngModel",""]],hostVars:1,hostBindings:function(t,i){2&t&&s.uIk("required",i._enabled?"":null)},features:[s._Bn([_n]),s.qOj]}),e})(),Et=(()=>{var n;class e{}return(n=e).\u0275fac=function(t){return new(t||n)},n.\u0275mod=s.oAB({type:n}),n.\u0275inj=s.cJS({imports:[dt]}),e})();class wt extends K{constructor(e,r,t){super(ce(r),de(t,r)),this.controls=e,this._initObservables(),this._setUpdateStrategy(r),this._setUpControls(),this.updateValueAndValidity({onlySelf:!0,emitEvent:!!this.asyncValidator})}at(e){return this.controls[this._adjustIndex(e)]}push(e,r={}){this.controls.push(e),this._registerControl(e),this.updateValueAndValidity({emitEvent:r.emitEvent}),this._onCollectionChange()}insert(e,r,t={}){this.controls.splice(e,0,r),this._registerControl(r),this.updateValueAndValidity({emitEvent:t.emitEvent})}removeAt(e,r={}){let t=this._adjustIndex(e);t<0&&(t=0),this.controls[t]&&this.controls[t]._registerOnCollectionChange(()=>{}),this.controls.splice(t,1),this.updateValueAndValidity({emitEvent:r.emitEvent})}setControl(e,r,t={}){let i=this._adjustIndex(e);i<0&&(i=0),this.controls[i]&&this.controls[i]._registerOnCollectionChange(()=>{}),this.controls.splice(i,1),r&&(this.controls.splice(i,0,r),this._registerControl(r)),this.updateValueAndValidity({emitEvent:t.emitEvent}),this._onCollectionChange()}get length(){return this.controls.length}setValue(e,r={}){et(this,0,e),e.forEach((t,i)=>{Xe(this,!1,i),this.at(i).setValue(t,{onlySelf:!0,emitEvent:r.emitEvent})}),this.updateValueAndValidity(r)}patchValue(e,r={}){null!=e&&(e.forEach((t,i)=>{this.at(i)&&this.at(i).patchValue(t,{onlySelf:!0,emitEvent:r.emitEvent})}),this.updateValueAndValidity(r))}reset(e=[],r={}){this._forEachChild((t,i)=>{t.reset(e[i],{onlySelf:!0,emitEvent:r.emitEvent})}),this._updatePristine(r),this._updateTouched(r),this.updateValueAndValidity(r)}getRawValue(){return this.controls.map(e=>e.getRawValue())}clear(e={}){this.controls.length<1||(this._forEachChild(r=>r._registerOnCollectionChange(()=>{})),this.controls.splice(0),this.updateValueAndValidity({emitEvent:e.emitEvent}))}_adjustIndex(e){return e<0?e+this.length:e}_syncPendingControls(){let e=this.controls.reduce((r,t)=>!!t._syncPendingControls()||r,!1);return e&&this.updateValueAndValidity({onlySelf:!0}),e}_forEachChild(e){this.controls.forEach((r,t)=>{e(r,t)})}_updateValue(){this.value=this.controls.filter(e=>e.enabled||this.disabled).map(e=>e.value)}_anyControls(e){return this.controls.some(r=>r.enabled&&e(r))}_setUpControls(){this._forEachChild(e=>this._registerControl(e))}_allControlsDisabled(){for(const e of this.controls)if(e.enabled)return!1;return this.controls.length>0||this.disabled}_registerControl(e){e.setParent(this),e._registerOnCollectionChange(this._onCollectionChange)}_find(e){return this.at(e)??null}}function Ot(n){return!!n&&(void 0!==n.asyncValidators||void 0!==n.validators||void 0!==n.updateOn)}let Dn=(()=>{var n;class e{constructor(){this.useNonNullable=!1}get nonNullable(){const t=new e;return t.useNonNullable=!0,t}group(t,i=null){const o=this._reduceControls(t);let a={};return Ot(i)?a=i:null!==i&&(a.validators=i.validator,a.asyncValidators=i.asyncValidator),new P(o,a)}record(t,i=null){const o=this._reduceControls(t);return new tt(o,i)}control(t,i,o){let a={};return this.useNonNullable?(Ot(i)?a=i:(a.validators=i,a.asyncValidators=o),new R(t,{...a,nonNullable:!0})):new R(t,i,o)}array(t,i,o){const a=t.map(p=>this._createControl(p));return new wt(a,i,o)}_reduceControls(t){const i={};return Object.keys(t).forEach(o=>{i[o]=this._createControl(t[o])}),i}_createControl(t){return t instanceof R||t instanceof K?t:Array.isArray(t)?this.control(t[0],t.length>1?t[1]:null,t.length>2?t[2]:null):this.control(t)}}return(n=e).\u0275fac=function(t){return new(t||n)},n.\u0275prov=s.Yz7({token:n,factory:n.\u0275fac,providedIn:"root"}),e})(),An=(()=>{var n;class e extends Dn{group(t,i=null){return super.group(t,i)}control(t,i,o){return super.control(t,i,o)}array(t,i,o){return super.array(t,i,o)}}return(n=e).\u0275fac=function(){let r;return function(i){return(r||(r=s.n5z(n)))(i||n)}}(),n.\u0275prov=s.Yz7({token:n,factory:n.\u0275fac,providedIn:"root"}),e})(),Mn=(()=>{var n;class e{static withConfig(t){return{ngModule:e,providers:[{provide:F,useValue:t.callSetDisabledState??T}]}}}return(n=e).\u0275fac=function(t){return new(t||n)},n.\u0275mod=s.oAB({type:n}),n.\u0275inj=s.cJS({imports:[Et]}),e})(),bn=(()=>{var n;class e{static withConfig(t){return{ngModule:e,providers:[{provide:ye,useValue:t.warnOnNgModelWithFormControl??"always"},{provide:F,useValue:t.callSetDisabledState??T}]}}}return(n=e).\u0275fac=function(t){return new(t||n)},n.\u0275mod=s.oAB({type:n}),n.\u0275inj=s.cJS({imports:[Et]}),e})()}}]);