homebridge-config-ui-x 5.0.0-beta.48 → 5.0.0-beta.49
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/CHANGELOG.md +13 -0
- package/config.schema.json +2 -2
- package/dist/core/config/config.service.js +1 -1
- package/dist/core/config/config.service.js.map +1 -1
- package/dist/modules/plugins/plugins.service.js +2 -2
- package/dist/modules/plugins/plugins.service.js.map +1 -1
- package/package.json +1 -1
- package/public/chunk-2DNEBY5E.js +1 -0
- package/public/{chunk-BJXS73LH.js → chunk-2RHVBUWQ.js} +1 -1
- package/public/{chunk-3CLV2FC6.js → chunk-36QWIZI7.js} +1 -1
- package/public/{chunk-VL5X4ZVV.js → chunk-3BDQDK7Z.js} +1 -1
- package/public/chunk-3FYKWBX4.js +1 -0
- package/public/chunk-45EEWPPP.js +1 -0
- package/public/{chunk-JNDUPUWF.js → chunk-467DG7CQ.js} +1 -1
- package/public/{chunk-4YZCE46C.js → chunk-4TLWNUVF.js} +1 -1
- package/public/chunk-4Z3PKFSC.js +1 -0
- package/public/{chunk-Y5UYAX3H.js → chunk-6DI47FXW.js} +1 -1
- package/public/{chunk-KH4HMJDS.js → chunk-6Z26BY4U.js} +1 -1
- package/public/{chunk-MHSSDQTO.js → chunk-7G4JRXOV.js} +1 -1
- package/public/{chunk-U2Z4CAIZ.js → chunk-7WVCMXZM.js} +1 -1
- package/public/{chunk-PPIJN4FF.js → chunk-AYMOJATW.js} +1 -1
- package/public/{chunk-4GRPJB2P.js → chunk-BRLQRDDE.js} +1 -1
- package/public/{chunk-NSTC5R37.js → chunk-C7MCJ3HJ.js} +1 -1
- package/public/{chunk-B3SFDDBL.js → chunk-CTNJDNS2.js} +1 -1
- package/public/chunk-CUJHL6GN.js +1 -0
- package/public/{chunk-EW7XGQVC.js → chunk-DODCDNCH.js} +1 -1
- package/public/{chunk-J3F7NQNQ.js → chunk-DZZJUIUB.js} +1 -1
- package/public/{chunk-LYQLGV7P.js → chunk-EWBJKCV2.js} +1 -1
- package/public/{chunk-AE35FRHM.js → chunk-EWKRKJWP.js} +1 -1
- package/public/{chunk-XZJKL6IB.js → chunk-F3B373TU.js} +1 -1
- package/public/{chunk-JT2YVNQO.js → chunk-FBYMGTFS.js} +1 -1
- package/public/{chunk-EQNG7LF7.js → chunk-HMCIUNTI.js} +1 -1
- package/public/{chunk-BUJWPPEX.js → chunk-IFQZA7AR.js} +1 -1
- package/public/{chunk-YZHG7ES5.js → chunk-IGGAKDGB.js} +1 -1
- package/public/chunk-JJBFROMM.js +1 -0
- package/public/{chunk-DSHTCT55.js → chunk-JMV6GJY6.js} +1 -1
- package/public/{chunk-4QE25OZ3.js → chunk-JS6ONM73.js} +1 -1
- package/public/chunk-JUGLUJ6M.js +1 -0
- package/public/{chunk-QCLWSM3A.js → chunk-JYTZL4JA.js} +1 -1
- package/public/chunk-KA7VEXYP.js +1 -0
- package/public/chunk-KSYVP6OJ.js +1 -0
- package/public/chunk-L4CXAWDO.js +1 -0
- package/public/{chunk-UVJEVV5S.js → chunk-LUOETQYT.js} +1 -1
- package/public/{chunk-T2PNCJ23.js → chunk-LVTTA25W.js} +1 -1
- package/public/{chunk-XFZXTT6K.js → chunk-LWRSZZVK.js} +1 -1
- package/public/{chunk-NUH7RNLW.js → chunk-M5C4PXJK.js} +1 -1
- package/public/chunk-MJNSII2N.js +1 -0
- package/public/{chunk-S35I2PR5.js → chunk-MVBTQKIK.js} +1 -1
- package/public/{chunk-J3HIMDYL.js → chunk-MWYAZTLX.js} +1 -1
- package/public/{chunk-CEJM3DON.js → chunk-O4J5XPML.js} +1 -1
- package/public/{chunk-MILIX2WI.js → chunk-PPT7YV25.js} +1 -1
- package/public/{chunk-XRDJUHD2.js → chunk-QJYOQ4DI.js} +1 -1
- package/public/{chunk-74LYVRCB.js → chunk-QZAASX2P.js} +1 -1
- package/public/{chunk-MJQXPSBD.js → chunk-R3UJDRMY.js} +1 -1
- package/public/{chunk-4UJBJDCP.js → chunk-R5YQXFDB.js} +1 -1
- package/public/{chunk-YB735BBN.js → chunk-ROLRUBFP.js} +1 -1
- package/public/{chunk-C7KRXSEN.js → chunk-RVYIQ5LE.js} +1 -1
- package/public/{chunk-PKEASNFQ.js → chunk-RXVUWQQM.js} +1 -1
- package/public/chunk-S5GONVEN.js +1 -0
- package/public/{chunk-W6XAVTHG.js → chunk-S6FGILT3.js} +1 -1
- package/public/chunk-SDKSMP3B.js +1 -0
- package/public/{chunk-5VYHCBEW.js → chunk-UJ4WWACD.js} +1 -1
- package/public/chunk-UX3DMSLN.js +1 -0
- package/public/{chunk-JDF6IVWH.js → chunk-W7TUYK4G.js} +1 -1
- package/public/{chunk-WJPWJVGI.js → chunk-X2TCWBWH.js} +1 -1
- package/public/{chunk-DFMW6FFT.js → chunk-XKCVC7DK.js} +1 -1
- package/public/{chunk-4ATAMH2X.js → chunk-Z2XEI7AO.js} +1 -1
- package/public/index.html +1 -1
- package/public/{main-IYS2AKC7.js → main-KV6LSW6T.js} +1 -1
- package/public/chunk-2MWHHJEX.js +0 -1
- package/public/chunk-2X3VY4WZ.js +0 -1
- package/public/chunk-3LHQREAI.js +0 -1
- package/public/chunk-52U6LSJN.js +0 -1
- package/public/chunk-6SSSXXI4.js +0 -1
- package/public/chunk-7LYFXCPE.js +0 -1
- package/public/chunk-7UZVY4MV.js +0 -1
- package/public/chunk-EBYWKNCQ.js +0 -1
- package/public/chunk-K7XSITH7.js +0 -1
- package/public/chunk-SIRB6T2U.js +0 -1
- package/public/chunk-VV4A6Q55.js +0 -1
- package/public/chunk-WGYMYQFR.js +0 -1
- package/public/chunk-XALELFFF.js +0 -1
- package/public/chunk-ZRZZMX65.js +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
import{a as ne}from"./chunk-Z2MYOFRS.js";import{g as O,m as G,n as te}from"./chunk-AL4B7SPR.js";import{b as Z,c as M,d as x,e as F,f as z,g as N,j as w,m as q,o as R,p as L,q as j,w as ee,y as V,z as A}from"./chunk-CZTEBDJ7.js";import{b as ie}from"./chunk-3M4FKD4C.js";import{c as Q}from"./chunk-74LYVRCB.js";import{a as ce}from"./chunk-S35I2PR5.js";import{h as U,k}from"./chunk-MILIX2WI.js";import{a as S,b as $}from"./chunk-IJXZOFF2.js";import{Ac as l,Bc as Y,Ib as u,Jb as f,Ob as g,Qb as K,Rb as W,Sb as X,Tb as i,Ub as n,Vb as p,Zb as D,_c as P,ac as b,bc as v,g as de,gb as e,lc as m,ma as c,mc as d,nc as C,sb as E,ua as B,va as T,vc as I,yb as h,zc as s}from"./chunk-N5DHAEO2.js";function ue(r,y){r&1&&(i(0,"ngb-alert",13)(1,"p",20),m(2),s(3,"translate"),n()()),r&2&&(f("dismissible",!1),e(2),d(l(3,2,"login.invalid_password")))}var re=(()=>{class r{$activeModal=c(G);$api=c(k);$toastr=c(U);$translate=c(S);formGroup=new N({password:new w("",[x.required])});invalidCredentials=!1;constructor(){}disable2fa(){this.invalidCredentials=!1,this.$api.post("/users/otp/deactivate",this.formGroup.value).subscribe({next:()=>{this.$activeModal.close(),this.$toastr.success(this.$translate.instant("users.setup_2fa_disable_success"),this.$translate.instant("toast.title_success"))},error:()=>{this.formGroup.setValue({password:""}),this.invalidCredentials=!0}})}static \u0275fac=function(o){return new(o||r)};static \u0275cmp=E({type:r,selectors:[["ng-component"]],decls:34,vars:27,consts:[[1,"modal-content",2,"min-height","300px"],[1,"modal-header"],[1,"modal-title"],["type","button","data-bs-dismiss","modal",1,"btn-close",3,"click"],[1,"modal-body"],[1,"text-center","mb-3"],[1,"fas","fa-fw","fa-key","primary-text",2,"font-size","75px"],[1,"mb-3"],[1,"list-group","list-group-box","mb-0"],[1,"list-group-item","d-flex","flex-column","flex-md-row","align-items-center"],[1,"mb-2","mb-md-0","w-100","w-md-50"],[1,"text-start","text-md-end","w-100","w-md-50"],["type","password","autocomplete","current-password",1,"form-control","custom-input",3,"formControl","placeholder"],["type","error",1,"mt-3","mb-0",3,"dismissible"],[1,"modal-footer","justify-content-between"],[1,"text-start"],["type","button","data-bs-dismiss","modal",1,"btn","btn-elegant",3,"click"],[1,"text-center"],[1,"text-end"],["type","button","data-bs-dismiss","modal",1,"btn","btn-danger",3,"click","disabled"],[1,"mb-0"]],template:function(o,a){o&1&&(i(0,"div",0)(1,"div",1)(2,"h5",2),m(3),s(4,"translate"),n(),i(5,"button",3),s(6,"translate"),b("click",function(){return a.$activeModal.dismiss("Dismiss")}),n()(),i(7,"div",4)(8,"div",5),p(9,"i",6),n(),i(10,"ul",7)(11,"li"),m(12),s(13,"translate"),n()(),i(14,"ul",8)(15,"li",9)(16,"label",10),m(17),s(18,"translate"),n(),i(19,"div",11),p(20,"input",12),s(21,"translate"),n()()(),h(22,ue,4,4,"ngb-alert",13),n(),i(23,"div",14)(24,"div",15)(25,"button",16),s(26,"translate"),b("click",function(){return a.$activeModal.dismiss("Dismiss")}),m(27),s(28,"translate"),n()(),p(29,"div",17),i(30,"div",18)(31,"button",19),b("click",function(){return a.disable2fa()}),m(32),s(33,"translate"),n()()()()),o&2&&(e(3),d(l(4,11,"users.setup_2fa_disable")),e(2),u("aria-label",l(6,13,"form.button_close")),e(7),d(l(13,15,"users.setup_2fa_disable_current_password")),e(5),d(l(18,17,"users.label_password")),e(3),f("formControl",a.formGroup.controls.password)("placeholder",l(21,19,"users.label_password")),e(2),g(a.invalidCredentials&&!a.formGroup.controls.password.value?22:-1),e(3),u("aria-label",l(26,21,"form.button_close")),e(2),C(" ",l(28,23,"form.button_close")," "),e(4),f("disabled",a.formGroup.invalid),e(),C(" ",l(33,25,"form.button_disable")," "))},dependencies:[V,M,F,A,R,$,O],encapsulation:2})}return r})();var ae=de(ce(),1);var fe=r=>({timeDiffError:r});function be(r,y){r&1&&(i(0,"li"),m(1),s(2,"translate"),n()),r&2&&(e(),d(l(2,1,"users.setup_2fa_scan_qr_code")))}function _e(r,y){if(r&1&&(i(0,"ngb-alert",8)(1,"p",16),m(2),s(3,"translate"),n(),i(4,"p",17),m(5),s(6,"translate"),n()()),r&2){let t=v();f("dismissible",!1),e(2),d(l(3,3,"users.setup_2fa_cannot_setup_2fa")),e(3),d(Y(6,5,"users.setup_2fa_server_time_out",I(8,fe,t.timeDiffError)))}}function ve(r,y){if(r&1&&(i(0,"ul",9)(1,"li",18)(2,"div",19),p(3,"app-qrcode",20),n()(),i(4,"li",21)(5,"label",22),m(6),s(7,"translate"),n(),i(8,"div",23),p(9,"input",24),n()()()),r&2){let t=v();e(3),f("data",t.otpString),e(3),d(l(7,3,"users.setup_2fa_enter_code")),e(3),f("formControl",t.formGroup.controls.code)}}function xe(r,y){if(r&1){let t=D();i(0,"button",25),s(1,"translate"),b("click",function(){B(t);let a=v();return T(a.$activeModal.dismiss("Dismiss"))}),m(2),s(3,"translate"),n()}r&2&&(u("aria-label",l(1,2,"form.button_close")),e(2),C(" ",l(3,4,"form.button_close")," "))}function we(r,y){if(r&1){let t=D();i(0,"button",25),s(1,"translate"),b("click",function(){B(t);let a=v();return T(a.$activeModal.dismiss("Dismiss"))}),m(2),s(3,"translate"),n()}r&2&&(u("aria-label",l(1,2,"form.button_close")),e(2),C(" ",l(3,4,"form.button_close")," "))}function Ce(r,y){if(r&1){let t=D();i(0,"button",26),b("click",function(){B(t);let a=v();return T(a.enable2fa())}),m(1),s(2,"translate"),n()}if(r&2){let t=v();f("disabled",t.formGroup.invalid),e(),C(" ",l(2,2,"form.button_enable")," ")}}var oe=(()=>{class r{$activeModal=c(G);$api=c(k);$toastr=c(U);$translate=c(S);user;timeDiffError=null;otpString;formGroup=new N({code:new w("",[x.required,x.minLength(6),x.maxLength(6)])});constructor(){}ngOnInit(){this.$api.post("/users/otp/setup",{}).subscribe({next:t=>{this.checkTimeDiff(t.timestamp),this.timeDiffError||(this.otpString=t.otpauth)},error:t=>{this.$activeModal.dismiss(),console.error(t),this.$toastr.error(this.$translate.instant("users.setup_2fa_enable_error"),this.$translate.instant("toast.title_error"))}})}checkTimeDiff(t){let o=(0,ae.default)(t).diff(new Date,"millisecond");o<-5e3||o>5e3?this.timeDiffError=o:this.timeDiffError=null}enable2fa(){this.$api.post("/users/otp/activate",this.formGroup.value).subscribe({next:()=>{this.$toastr.success(this.$translate.instant("users.setup_2fa_enabled_success"),this.$translate.instant("toast.title_success")),this.$activeModal.close()},error:t=>{console.error(t),this.$toastr.error(this.$translate.instant("users.setup_2fa_activate_error"),this.$translate.instant("toast.title_error"))}})}static \u0275fac=function(o){return new(o||r)};static \u0275cmp=E({type:r,selectors:[["ng-component"]],inputs:{user:"user"},decls:24,vars:15,consts:[[1,"modal-content","setup2fa"],[1,"modal-header"],[1,"modal-title"],["type","button","data-bs-dismiss","modal",1,"btn-close",3,"click"],[1,"modal-body"],[1,"text-center","mb-3"],[1,"fas","fa-fw","fa-key","primary-text",2,"font-size","75px"],[1,"mb-3"],["type","error",1,"mb-0",3,"dismissible"],[1,"list-group","list-group-box","mb-0"],[1,"modal-footer","justify-content-between"],[1,"text-start"],["type","button","data-bs-dismiss","modal",1,"btn","btn-elegant"],[1,"text-center"],[1,"text-end"],["type","button","data-bs-dismiss","modal",1,"btn","btn-primary",3,"disabled"],[1,"fw-bold","mb-1"],[1,"mb-0"],[1,"list-group-item","text-center"],[1,"text-center","w-100","d-flex","justify-content-center"],[1,"mx-auto",2,"width","175px","height","175px",3,"data"],[1,"list-group-item","d-flex","flex-column","flex-md-row","align-items-center"],[1,"mb-2","mb-md-0","w-100","w-md-50"],[1,"text-start","text-md-end","w-100","w-md-50"],["formControlName","username","type","text","placeholder","eg. 123456","autocomplete","one-time-code","autocapitalize","none","inputmode","numeric","pattern","[0-9]*",1,"form-control","custom-input",3,"formControl"],["type","button","data-bs-dismiss","modal",1,"btn","btn-elegant",3,"click"],["type","button","data-bs-dismiss","modal",1,"btn","btn-primary",3,"click","disabled"]],template:function(o,a){o&1&&(i(0,"div",0)(1,"div",1)(2,"h5",2),m(3),s(4,"translate"),n(),i(5,"button",3),s(6,"translate"),b("click",function(){return a.$activeModal.dismiss("Dismiss")}),n()(),i(7,"div",4)(8,"div",5),p(9,"i",6),n(),i(10,"ul",7)(11,"li"),m(12),s(13,"translate"),n(),h(14,be,3,3,"li"),n(),h(15,_e,7,10,"ngb-alert",8)(16,ve,10,5,"ul",9),n(),i(17,"div",10)(18,"div",11),h(19,xe,4,6,"button",12),n(),i(20,"div",13),h(21,we,4,6,"button",12),n(),i(22,"div",14),h(23,Ce,3,4,"button",15),n()()()),o&2&&(e(3),d(l(4,9,"users.setup_2fa")),e(2),u("aria-label",l(6,11,"form.button_close")),e(7),d(l(13,13,"users.setup_2fa_warning")),e(2),g(a.timeDiffError?-1:14),e(),g(a.timeDiffError?15:-1),e(),g(a.timeDiffError?-1:16),e(3),g(a.timeDiffError?-1:19),e(2),g(a.timeDiffError?21:-1),e(2),g(a.timeDiffError?-1:23))},dependencies:[O,ne,V,M,F,ee,A,R,j,$],encapsulation:2})}return r})();var se=r=>({"is-invalid":r}),le=(()=>{class r{$activeModal=c(G);$api=c(k);$toastr=c(U);$translate=c(S);form=new N({username:new w("",[x.required]),name:new w("",[x.required]),password:new w("",[x.compose([x.required,x.minLength(4)])]),passwordConfirm:new w("",[x.required]),admin:new w(!0)},this.matchPassword);page={title:"users.title_add_user",save:"users.button_add_new_user",password:"users.label_password"};constructor(){}matchPassword(t){let o=t.get("password").value,a=t.get("passwordConfirm").value;if(o!==a)t.get("passwordConfirm").setErrors({matchPassword:!0});else return null}onSubmit({value:t}){this.$api.post("/users",t).subscribe({next:()=>{this.$activeModal.close(),this.$toastr.success(this.$translate.instant("users.toast_added_new_user"),this.$translate.instant("toast.title_success"))},error:o=>{this.$toastr.error(o.error.message||this.$translate.instant("users.toast_failed_to_add_user"),this.$translate.instant("toast.title_error"))}})}static \u0275fac=function(o){return new(o||r)};static \u0275cmp=E({type:r,selectors:[["ng-component"]],decls:58,vars:50,consts:[[1,"modal-content"],["novalidate","",3,"ngSubmit","formGroup"],[1,"modal-header"],[1,"modal-title"],["type","button","data-bs-dismiss","modal",1,"btn-close",3,"click"],[1,"modal-body"],[1,"text-center","mb-3"],[1,"fas","fa-fw","fa-user-plus","primary-text",2,"font-size","75px"],[1,"list-group","list-group-box","mb-0"],[1,"list-group-item","d-flex","flex-column","flex-md-row","align-items-center"],["for","form-username",1,"mb-2","mb-md-0","w-100","w-md-50"],[1,"text-start","text-md-end","w-100","w-md-50"],["formControlName","username","type","text","id","form-username","autocomplete","username","autocapitalize","none",1,"form-control","custom-input"],["for","form-name",1,"mb-2","mb-md-0","w-100","w-md-50"],["formControlName","name","type","text","id","form-name","autocomplete","name",1,"form-control","custom-input"],["for","form-pass",1,"mb-2","mb-md-0","w-100","w-md-50"],["formControlName","password","type","password","autocomplete","new-password","id","form-pass",1,"form-control","custom-input",3,"ngClass"],["for","form-pass-confirm",1,"mb-2","mb-md-0","w-100","w-md-50"],["formControlName","passwordConfirm","type","password","autocomplete","new-password","id","form-pass-confirm",1,"form-control","custom-input",3,"ngClass"],[1,"list-group-item","d-flex","justify-content-between","align-items-center","flex-row","pb-2"],[1,"text-start"],[1,"text-end","grey-text"],["type","checkbox","id","isAdmin",1,"rendux-input"],["for","isAdmin",1,"rendux-label","ms-3"],[1,"modal-footer","justify-content-between"],["type","button","data-bs-dismiss","modal",1,"btn","btn-elegant",3,"click"],[1,"text-center"],[1,"text-end"],["type","submit",1,"btn","btn-primary",3,"disabled"]],template:function(o,a){o&1&&(i(0,"div",0)(1,"form",1),b("ngSubmit",function(){return a.onSubmit(a.form)}),i(2,"div",2)(3,"h5",3),m(4),s(5,"translate"),n(),i(6,"button",4),s(7,"translate"),b("click",function(){return a.$activeModal.dismiss("Dismiss")}),n()(),i(8,"div",5)(9,"div",6),p(10,"i",7),n(),i(11,"ul",8)(12,"li",9)(13,"label",10),m(14),s(15,"translate"),n(),i(16,"div",11),p(17,"input",12),s(18,"translate"),n()(),i(19,"li",9)(20,"label",13),m(21),s(22,"translate"),n(),i(23,"div",11),p(24,"input",14),s(25,"translate"),n()(),i(26,"li",9)(27,"label",15),m(28),s(29,"translate"),n(),i(30,"div",11),p(31,"input",16),s(32,"translate"),n()(),i(33,"li",9)(34,"label",17),m(35),s(36,"translate"),n(),i(37,"div",11),p(38,"input",18),s(39,"translate"),n()(),i(40,"li",19)(41,"span",20),m(42),s(43,"translate"),n(),i(44,"div",21),p(45,"input",22),s(46,"translate"),p(47,"label",23),n()()()(),i(48,"div",24)(49,"div",20)(50,"button",25),b("click",function(){return a.$activeModal.dismiss("Dismiss")}),m(51),s(52,"translate"),n()(),p(53,"div",26),i(54,"div",27)(55,"button",28),m(56),s(57,"translate"),n()()()()()),o&2&&(e(),f("formGroup",a.form),e(3),d(l(5,18,"users.title_add_user")),e(2),u("aria-label",l(7,20,"form.button_close")),e(8),d(l(15,22,"users.label_username")),e(3),u("aria-label",l(18,24,"users.label_username")),e(4),d(l(22,26,"users.label_full_name")),e(3),u("aria-label",l(25,28,"users.label_full_name")),e(4),d(l(29,30,a.page.password)),e(3),f("ngClass",I(46,se,a.form.controls.password.dirty&&a.form.controls.password.errors)),u("aria-label",l(32,32,a.page.password)),e(4),d(l(36,34,"users.label_confirm_password")),e(3),f("ngClass",I(48,se,a.form.controls.passwordConfirm.dirty&&a.form.controls.passwordConfirm.errors)),u("aria-label",l(39,36,"users.label_confirm_password")),e(4),d(l(43,38,"users.label_admin_user")),e(3),u("aria-label",l(46,40,"users.label_admin_user")),e(6),C(" ",l(52,42,"form.button_close")," "),e(4),f("disabled",!a.form.valid),e(),C(" ",l(57,44,"form.button_save")," "))},dependencies:[V,q,M,F,z,A,L,j,P,$],encapsulation:2})}return r})();var me=r=>({"is-invalid":r});function ge(r,y){if(r&1&&(i(0,"li",9)(1,"label",27),m(2),s(3,"translate"),n(),i(4,"div",11),p(5,"input",28),s(6,"translate"),n()()),r&2){let t=v();e(2),d(l(3,3,"users.label_confirm_password")),e(3),f("ngClass",I(7,me,t.form.controls.passwordConfirm.dirty&&t.form.controls.passwordConfirm.errors)),u("aria-label",l(6,5,"users.label_confirm_password"))}}var pe=(()=>{class r{$activeModal=c(G);$api=c(k);$auth=c(Q);$toastr=c(U);$translate=c(S);user;form=new N({username:new w("",[x.required]),name:new w("",[x.required]),password:new w(""),passwordConfirm:new w(""),admin:new w(!0)},this.matchPassword);page={title:"users.title_edit_user",save:"form.button_save",password:"users.label_new_password"};isCurrentUser=!1;constructor(){}ngOnInit(){this.isCurrentUser=this.$auth.user.username===this.user.username,this.form.patchValue(this.user)}matchPassword(t){let o=t.get("password").value,a=t.get("passwordConfirm").value;if(o!==a)t.get("passwordConfirm").setErrors({matchPassword:!0});else return null}onSubmit({value:t}){this.$api.patch(`/users/${this.user.id}`,t).subscribe({next:()=>{this.$activeModal.close(),this.$toastr.success(this.$translate.instant("users.toast_updated_user"),this.$translate.instant("toast.title_success")),this.isCurrentUser&&t.username!==this.$auth.user.username&&this.$auth.logout()},error:o=>{console.error(o),this.$toastr.error(o.error.message||this.$translate.instant("users.toast_failed_to_add_user"),this.$translate.instant("toast.title_error"))}})}static \u0275fac=function(o){return new(o||r)};static \u0275cmp=E({type:r,selectors:[["ng-component"]],inputs:{user:"user"},decls:52,vars:42,consts:[[1,"modal-content"],["novalidate","",3,"ngSubmit","formGroup"],[1,"modal-header"],[1,"modal-title"],["type","button","data-bs-dismiss","modal",1,"btn-close",3,"click"],[1,"modal-body"],[1,"text-center","mb-3"],[1,"fas","fa-fw","fa-user-pen","primary-text",2,"font-size","75px"],[1,"list-group","list-group-box","mb-0"],[1,"list-group-item","d-flex","flex-column","flex-md-row","align-items-center"],["for","form-username",1,"mb-2","mb-md-0","w-100","w-md-50"],[1,"text-start","text-md-end","w-100","w-md-50"],["formControlName","username","type","text","id","form-username","autocomplete","off","autocapitalize","none",1,"form-control","custom-input"],["for","form-name",1,"mb-2","mb-md-0","w-100","w-md-50"],["formControlName","name","type","text","id","form-name","autocomplete","name",1,"form-control","custom-input"],["for","form-pass",1,"mb-2","mb-md-0","w-100","w-md-50"],["formControlName","password","type","password","autocomplete","new-password","id","form-pass",1,"form-control","custom-input",3,"ngClass"],[1,"list-group-item","d-flex","justify-content-between","align-items-center","flex-row","pb-2"],[1,"text-start"],[1,"text-end","grey-text"],["type","checkbox","formControlName","admin","id","isAdmin",1,"rendux-input"],["for","isAdmin",1,"rendux-label","ms-3"],[1,"modal-footer","justify-content-between"],["type","button","data-bs-dismiss","modal",1,"btn","btn-elegant",3,"click"],[1,"text-center"],[1,"text-end"],["type","submit",1,"btn","btn-primary",3,"disabled"],["for","form-pass-confirm",1,"mb-2","mb-md-0","w-100","w-md-50"],["formControlName","passwordConfirm","type","password","autocomplete","new-password","id","form-pass-confirm",1,"form-control","custom-input",3,"ngClass"]],template:function(o,a){o&1&&(i(0,"div",0)(1,"form",1),b("ngSubmit",function(){return a.onSubmit(a.form)}),i(2,"div",2)(3,"h5",3),m(4),s(5,"translate"),n(),i(6,"button",4),s(7,"translate"),b("click",function(){return a.$activeModal.dismiss("Dismiss")}),n()(),i(8,"div",5)(9,"div",6),p(10,"i",7),n(),i(11,"ul",8)(12,"li",9)(13,"label",10),m(14),s(15,"translate"),n(),i(16,"div",11),p(17,"input",12),s(18,"translate"),n()(),i(19,"li",9)(20,"label",13),m(21),s(22,"translate"),n(),i(23,"div",11),p(24,"input",14),s(25,"translate"),n()(),i(26,"li",9)(27,"label",15),m(28),s(29,"translate"),n(),i(30,"div",11),p(31,"input",16),s(32,"translate"),n()(),h(33,ge,7,9,"li",9),i(34,"li",17)(35,"span",18),m(36),s(37,"translate"),n(),i(38,"div",19),p(39,"input",20),s(40,"translate"),p(41,"label",21),n()()()(),i(42,"div",22)(43,"div",18)(44,"button",23),b("click",function(){return a.$activeModal.dismiss("Dismiss")}),m(45),s(46,"translate"),n()(),p(47,"div",24),i(48,"div",25)(49,"button",26),m(50),s(51,"translate"),n()()()()()),o&2&&(e(),f("formGroup",a.form),e(3),d(l(5,16,"users.title_edit_user")),e(2),u("aria-label",l(7,18,"form.button_close")),e(8),d(l(15,20,"users.label_username")),e(3),u("aria-label",l(18,22,"users.label_username")),e(4),d(l(22,24,"users.label_full_name")),e(3),u("aria-label",l(25,26,"users.label_full_name")),e(4),d(l(29,28,a.page.password)),e(3),f("ngClass",I(40,me,a.form.controls.password.dirty&&a.form.controls.password.errors)),u("aria-label",l(32,30,a.page.password)),e(2),g(a.form.controls.password.value?33:-1),e(3),d(l(37,32,"users.label_admin_user")),e(3),u("aria-label",l(40,34,"users.label_admin_user")),e(6),C(" ",l(46,36,"form.button_close")," "),e(4),f("disabled",!a.form.valid),e(),C(" ",l(51,38,"form.button_save")," "))},dependencies:[V,q,M,Z,F,z,A,L,j,P,$],encapsulation:2})}return r})();function he(r,y){if(r&1){let t=D();i(0,"button",21),b("click",function(){B(t);let a=v().$implicit,_=v();return T(_.setup2fa(a))}),m(1),s(2,"translate"),n()}r&2&&(e(),d(l(2,1,"users.setup_2fa")))}function ye(r,y){if(r&1){let t=D();i(0,"button",17),b("click",function(){B(t);let a=v().$implicit,_=v();return T(_.disable2fa(a))}),m(1),s(2,"translate"),n()}r&2&&(e(),C(" ",l(2,1,"users.setup_2fa_disable")," "))}function Ee(r,y){if(r&1){let t=D();i(0,"div",7)(1,"div",8)(2,"div",9)(3,"div",10)(4,"span",11),p(5,"h4",12)(6,"h5",13),n()(),i(7,"div",14),h(8,he,3,3,"button",15)(9,ye,3,3,"button",16),i(10,"div")(11,"button",17),s(12,"translate"),b("click",function(){let a=B(t).$implicit,_=v();return T(_.openEditUser(a))}),p(13,"i",18),n(),i(14,"button",19),s(15,"translate"),b("click",function(){let a=B(t).$implicit,_=v();return T(_.deleteUser(a.id))}),p(16,"i",20),n()()()()()()}if(r&2){let t=y.$implicit,o=v();e(5),f("innerText",t.name),e(),f("innerText",t.username),e(2),g(o.$auth.user.username===t.username&&!t.otpActive?8:-1),e(),g(o.$auth.user.username===t.username&&t.otpActive?9:-1),e(2),u("aria-label",l(12,7,"form.button_edit")),e(3),f("disabled",o.$auth.user.username===t.username),u("aria-label",l(15,9,"form.button_delete"))}}var gt=(()=>{class r{$api=c(k);$auth=c(Q);$modal=c(te);$route=c(ie);$toastr=c(U);$translate=c(S);homebridgeUsers;constructor(){}ngOnInit(){this.$route.data.subscribe(t=>{this.homebridgeUsers=t.homebridgeUsers})}reloadUsers(){return this.$api.get("/users").subscribe(t=>{this.homebridgeUsers=t})}openAddNewUser(){this.$modal.open(le,{size:"lg",backdrop:"static"}).result.finally(()=>{this.reloadUsers()})}openEditUser(t){let o=this.$modal.open(pe,{size:"lg",backdrop:"static"});o.componentInstance.user=t,o.result.finally(()=>{this.reloadUsers()})}deleteUser(t){this.$api.delete(`/users/${t}`).subscribe({next:()=>{this.$toastr.success(this.$translate.instant("users.toast_user_deleted"),this.$translate.instant("toast.title_success")),this.reloadUsers()},error:o=>{console.error(o),this.$toastr.error(o.error.message||this.$translate.instant("users.toast_failed_to_delete_user"),this.$translate.instant("toast.title_error"))}})}setup2fa(t){let o=this.$modal.open(oe,{size:"lg",backdrop:"static"});o.componentInstance.user=t,o.result.finally(()=>{this.reloadUsers()})}disable2fa(t){let o=this.$modal.open(re,{size:"lg",backdrop:"static"});o.componentInstance.user=t,o.result.finally(()=>{this.reloadUsers()})}static \u0275fac=function(o){return new(o||r)};static \u0275cmp=E({type:r,selectors:[["app-users"]],decls:12,vars:6,consts:[[1,"row","mb-3"],[1,"col-9"],[1,"primary-text","m-0"],[1,"col-3","text-end"],[1,"btn","btn-elegant","waves-effect","m-0",3,"click"],[1,"fas","fa-fw","fa-user-plus"],[1,"row"],[1,"col-md-6","mb-4"],[1,"card","card-body"],[1,"d-flex","flex-column"],[1,"d-flex","flex-row","mb-3"],[1,"me-auto","my-0"],[3,"innerText"],[1,"small","text-truncate","primary-text",3,"innerText"],[1,"d-flex","flex-row","justify-content-between"],[1,"btn","btn-primary","m-0"],[1,"btn","btn-elegant","m-0"],[1,"btn","btn-elegant","m-0",3,"click"],[1,"fas","fa-fw","fa-user-pen"],[1,"btn","btn-danger","m-0","ms-2",3,"click","disabled"],[1,"fas","fa-fw","fa-trash"],[1,"btn","btn-primary","m-0",3,"click"]],template:function(o,a){o&1&&(i(0,"div",0)(1,"div",1)(2,"h3",2),m(3),s(4,"translate"),n()(),i(5,"div",3)(6,"button",4),s(7,"translate"),b("click",function(){return a.openAddNewUser()}),p(8,"i",5),n()()(),i(9,"div",6),W(10,Ee,17,11,"div",7,K),n()),o&2&&(e(3),d(l(4,2,"users.title_users")),e(3),u("aria-label",l(7,4,"users.button_add_user")),e(4),X(a.homebridgeUsers))},dependencies:[$],encapsulation:2})}return r})();export{re as a,oe as b,le as c,pe as d,gt as e};
|
|
1
|
+
import{a as ne}from"./chunk-Z2MYOFRS.js";import{g as O,m as G,n as te}from"./chunk-AL4B7SPR.js";import{b as Z,c as M,d as x,e as F,f as z,g as N,j as w,m as q,o as R,p as L,q as j,w as ee,y as V,z as A}from"./chunk-CZTEBDJ7.js";import{b as ie}from"./chunk-3M4FKD4C.js";import{c as Q}from"./chunk-QZAASX2P.js";import{a as ce}from"./chunk-MVBTQKIK.js";import{h as U,k}from"./chunk-PPT7YV25.js";import{a as S,b as $}from"./chunk-IJXZOFF2.js";import{Ac as l,Bc as Y,Ib as u,Jb as f,Ob as g,Qb as K,Rb as W,Sb as X,Tb as i,Ub as n,Vb as p,Zb as D,_c as P,ac as b,bc as v,g as de,gb as e,lc as m,ma as c,mc as d,nc as C,sb as E,ua as B,va as T,vc as I,yb as h,zc as s}from"./chunk-N5DHAEO2.js";function ue(r,y){r&1&&(i(0,"ngb-alert",13)(1,"p",20),m(2),s(3,"translate"),n()()),r&2&&(f("dismissible",!1),e(2),d(l(3,2,"login.invalid_password")))}var re=(()=>{class r{$activeModal=c(G);$api=c(k);$toastr=c(U);$translate=c(S);formGroup=new N({password:new w("",[x.required])});invalidCredentials=!1;constructor(){}disable2fa(){this.invalidCredentials=!1,this.$api.post("/users/otp/deactivate",this.formGroup.value).subscribe({next:()=>{this.$activeModal.close(),this.$toastr.success(this.$translate.instant("users.setup_2fa_disable_success"),this.$translate.instant("toast.title_success"))},error:()=>{this.formGroup.setValue({password:""}),this.invalidCredentials=!0}})}static \u0275fac=function(o){return new(o||r)};static \u0275cmp=E({type:r,selectors:[["ng-component"]],decls:34,vars:27,consts:[[1,"modal-content",2,"min-height","300px"],[1,"modal-header"],[1,"modal-title"],["type","button","data-bs-dismiss","modal",1,"btn-close",3,"click"],[1,"modal-body"],[1,"text-center","mb-3"],[1,"fas","fa-fw","fa-key","primary-text",2,"font-size","75px"],[1,"mb-3"],[1,"list-group","list-group-box","mb-0"],[1,"list-group-item","d-flex","flex-column","flex-md-row","align-items-center"],[1,"mb-2","mb-md-0","w-100","w-md-50"],[1,"text-start","text-md-end","w-100","w-md-50"],["type","password","autocomplete","current-password",1,"form-control","custom-input",3,"formControl","placeholder"],["type","error",1,"mt-3","mb-0",3,"dismissible"],[1,"modal-footer","justify-content-between"],[1,"text-start"],["type","button","data-bs-dismiss","modal",1,"btn","btn-elegant",3,"click"],[1,"text-center"],[1,"text-end"],["type","button","data-bs-dismiss","modal",1,"btn","btn-danger",3,"click","disabled"],[1,"mb-0"]],template:function(o,a){o&1&&(i(0,"div",0)(1,"div",1)(2,"h5",2),m(3),s(4,"translate"),n(),i(5,"button",3),s(6,"translate"),b("click",function(){return a.$activeModal.dismiss("Dismiss")}),n()(),i(7,"div",4)(8,"div",5),p(9,"i",6),n(),i(10,"ul",7)(11,"li"),m(12),s(13,"translate"),n()(),i(14,"ul",8)(15,"li",9)(16,"label",10),m(17),s(18,"translate"),n(),i(19,"div",11),p(20,"input",12),s(21,"translate"),n()()(),h(22,ue,4,4,"ngb-alert",13),n(),i(23,"div",14)(24,"div",15)(25,"button",16),s(26,"translate"),b("click",function(){return a.$activeModal.dismiss("Dismiss")}),m(27),s(28,"translate"),n()(),p(29,"div",17),i(30,"div",18)(31,"button",19),b("click",function(){return a.disable2fa()}),m(32),s(33,"translate"),n()()()()),o&2&&(e(3),d(l(4,11,"users.setup_2fa_disable")),e(2),u("aria-label",l(6,13,"form.button_close")),e(7),d(l(13,15,"users.setup_2fa_disable_current_password")),e(5),d(l(18,17,"users.label_password")),e(3),f("formControl",a.formGroup.controls.password)("placeholder",l(21,19,"users.label_password")),e(2),g(a.invalidCredentials&&!a.formGroup.controls.password.value?22:-1),e(3),u("aria-label",l(26,21,"form.button_close")),e(2),C(" ",l(28,23,"form.button_close")," "),e(4),f("disabled",a.formGroup.invalid),e(),C(" ",l(33,25,"form.button_disable")," "))},dependencies:[V,M,F,A,R,$,O],encapsulation:2})}return r})();var ae=de(ce(),1);var fe=r=>({timeDiffError:r});function be(r,y){r&1&&(i(0,"li"),m(1),s(2,"translate"),n()),r&2&&(e(),d(l(2,1,"users.setup_2fa_scan_qr_code")))}function _e(r,y){if(r&1&&(i(0,"ngb-alert",8)(1,"p",16),m(2),s(3,"translate"),n(),i(4,"p",17),m(5),s(6,"translate"),n()()),r&2){let t=v();f("dismissible",!1),e(2),d(l(3,3,"users.setup_2fa_cannot_setup_2fa")),e(3),d(Y(6,5,"users.setup_2fa_server_time_out",I(8,fe,t.timeDiffError)))}}function ve(r,y){if(r&1&&(i(0,"ul",9)(1,"li",18)(2,"div",19),p(3,"app-qrcode",20),n()(),i(4,"li",21)(5,"label",22),m(6),s(7,"translate"),n(),i(8,"div",23),p(9,"input",24),n()()()),r&2){let t=v();e(3),f("data",t.otpString),e(3),d(l(7,3,"users.setup_2fa_enter_code")),e(3),f("formControl",t.formGroup.controls.code)}}function xe(r,y){if(r&1){let t=D();i(0,"button",25),s(1,"translate"),b("click",function(){B(t);let a=v();return T(a.$activeModal.dismiss("Dismiss"))}),m(2),s(3,"translate"),n()}r&2&&(u("aria-label",l(1,2,"form.button_close")),e(2),C(" ",l(3,4,"form.button_close")," "))}function we(r,y){if(r&1){let t=D();i(0,"button",25),s(1,"translate"),b("click",function(){B(t);let a=v();return T(a.$activeModal.dismiss("Dismiss"))}),m(2),s(3,"translate"),n()}r&2&&(u("aria-label",l(1,2,"form.button_close")),e(2),C(" ",l(3,4,"form.button_close")," "))}function Ce(r,y){if(r&1){let t=D();i(0,"button",26),b("click",function(){B(t);let a=v();return T(a.enable2fa())}),m(1),s(2,"translate"),n()}if(r&2){let t=v();f("disabled",t.formGroup.invalid),e(),C(" ",l(2,2,"form.button_enable")," ")}}var oe=(()=>{class r{$activeModal=c(G);$api=c(k);$toastr=c(U);$translate=c(S);user;timeDiffError=null;otpString;formGroup=new N({code:new w("",[x.required,x.minLength(6),x.maxLength(6)])});constructor(){}ngOnInit(){this.$api.post("/users/otp/setup",{}).subscribe({next:t=>{this.checkTimeDiff(t.timestamp),this.timeDiffError||(this.otpString=t.otpauth)},error:t=>{this.$activeModal.dismiss(),console.error(t),this.$toastr.error(this.$translate.instant("users.setup_2fa_enable_error"),this.$translate.instant("toast.title_error"))}})}checkTimeDiff(t){let o=(0,ae.default)(t).diff(new Date,"millisecond");o<-5e3||o>5e3?this.timeDiffError=o:this.timeDiffError=null}enable2fa(){this.$api.post("/users/otp/activate",this.formGroup.value).subscribe({next:()=>{this.$toastr.success(this.$translate.instant("users.setup_2fa_enabled_success"),this.$translate.instant("toast.title_success")),this.$activeModal.close()},error:t=>{console.error(t),this.$toastr.error(this.$translate.instant("users.setup_2fa_activate_error"),this.$translate.instant("toast.title_error"))}})}static \u0275fac=function(o){return new(o||r)};static \u0275cmp=E({type:r,selectors:[["ng-component"]],inputs:{user:"user"},decls:24,vars:15,consts:[[1,"modal-content","setup2fa"],[1,"modal-header"],[1,"modal-title"],["type","button","data-bs-dismiss","modal",1,"btn-close",3,"click"],[1,"modal-body"],[1,"text-center","mb-3"],[1,"fas","fa-fw","fa-key","primary-text",2,"font-size","75px"],[1,"mb-3"],["type","error",1,"mb-0",3,"dismissible"],[1,"list-group","list-group-box","mb-0"],[1,"modal-footer","justify-content-between"],[1,"text-start"],["type","button","data-bs-dismiss","modal",1,"btn","btn-elegant"],[1,"text-center"],[1,"text-end"],["type","button","data-bs-dismiss","modal",1,"btn","btn-primary",3,"disabled"],[1,"fw-bold","mb-1"],[1,"mb-0"],[1,"list-group-item","text-center"],[1,"text-center","w-100","d-flex","justify-content-center"],[1,"mx-auto",2,"width","175px","height","175px",3,"data"],[1,"list-group-item","d-flex","flex-column","flex-md-row","align-items-center"],[1,"mb-2","mb-md-0","w-100","w-md-50"],[1,"text-start","text-md-end","w-100","w-md-50"],["formControlName","username","type","text","placeholder","eg. 123456","autocomplete","one-time-code","autocapitalize","none","inputmode","numeric","pattern","[0-9]*",1,"form-control","custom-input",3,"formControl"],["type","button","data-bs-dismiss","modal",1,"btn","btn-elegant",3,"click"],["type","button","data-bs-dismiss","modal",1,"btn","btn-primary",3,"click","disabled"]],template:function(o,a){o&1&&(i(0,"div",0)(1,"div",1)(2,"h5",2),m(3),s(4,"translate"),n(),i(5,"button",3),s(6,"translate"),b("click",function(){return a.$activeModal.dismiss("Dismiss")}),n()(),i(7,"div",4)(8,"div",5),p(9,"i",6),n(),i(10,"ul",7)(11,"li"),m(12),s(13,"translate"),n(),h(14,be,3,3,"li"),n(),h(15,_e,7,10,"ngb-alert",8)(16,ve,10,5,"ul",9),n(),i(17,"div",10)(18,"div",11),h(19,xe,4,6,"button",12),n(),i(20,"div",13),h(21,we,4,6,"button",12),n(),i(22,"div",14),h(23,Ce,3,4,"button",15),n()()()),o&2&&(e(3),d(l(4,9,"users.setup_2fa")),e(2),u("aria-label",l(6,11,"form.button_close")),e(7),d(l(13,13,"users.setup_2fa_warning")),e(2),g(a.timeDiffError?-1:14),e(),g(a.timeDiffError?15:-1),e(),g(a.timeDiffError?-1:16),e(3),g(a.timeDiffError?-1:19),e(2),g(a.timeDiffError?21:-1),e(2),g(a.timeDiffError?-1:23))},dependencies:[O,ne,V,M,F,ee,A,R,j,$],encapsulation:2})}return r})();var se=r=>({"is-invalid":r}),le=(()=>{class r{$activeModal=c(G);$api=c(k);$toastr=c(U);$translate=c(S);form=new N({username:new w("",[x.required]),name:new w("",[x.required]),password:new w("",[x.compose([x.required,x.minLength(4)])]),passwordConfirm:new w("",[x.required]),admin:new w(!0)},this.matchPassword);page={title:"users.title_add_user",save:"users.button_add_new_user",password:"users.label_password"};constructor(){}matchPassword(t){let o=t.get("password").value,a=t.get("passwordConfirm").value;if(o!==a)t.get("passwordConfirm").setErrors({matchPassword:!0});else return null}onSubmit({value:t}){this.$api.post("/users",t).subscribe({next:()=>{this.$activeModal.close(),this.$toastr.success(this.$translate.instant("users.toast_added_new_user"),this.$translate.instant("toast.title_success"))},error:o=>{this.$toastr.error(o.error.message||this.$translate.instant("users.toast_failed_to_add_user"),this.$translate.instant("toast.title_error"))}})}static \u0275fac=function(o){return new(o||r)};static \u0275cmp=E({type:r,selectors:[["ng-component"]],decls:58,vars:50,consts:[[1,"modal-content"],["novalidate","",3,"ngSubmit","formGroup"],[1,"modal-header"],[1,"modal-title"],["type","button","data-bs-dismiss","modal",1,"btn-close",3,"click"],[1,"modal-body"],[1,"text-center","mb-3"],[1,"fas","fa-fw","fa-user-plus","primary-text",2,"font-size","75px"],[1,"list-group","list-group-box","mb-0"],[1,"list-group-item","d-flex","flex-column","flex-md-row","align-items-center"],["for","form-username",1,"mb-2","mb-md-0","w-100","w-md-50"],[1,"text-start","text-md-end","w-100","w-md-50"],["formControlName","username","type","text","id","form-username","autocomplete","username","autocapitalize","none",1,"form-control","custom-input"],["for","form-name",1,"mb-2","mb-md-0","w-100","w-md-50"],["formControlName","name","type","text","id","form-name","autocomplete","name",1,"form-control","custom-input"],["for","form-pass",1,"mb-2","mb-md-0","w-100","w-md-50"],["formControlName","password","type","password","autocomplete","new-password","id","form-pass",1,"form-control","custom-input",3,"ngClass"],["for","form-pass-confirm",1,"mb-2","mb-md-0","w-100","w-md-50"],["formControlName","passwordConfirm","type","password","autocomplete","new-password","id","form-pass-confirm",1,"form-control","custom-input",3,"ngClass"],[1,"list-group-item","d-flex","justify-content-between","align-items-center","flex-row","pb-2"],[1,"text-start"],[1,"text-end","grey-text"],["type","checkbox","id","isAdmin",1,"rendux-input"],["for","isAdmin",1,"rendux-label","ms-3"],[1,"modal-footer","justify-content-between"],["type","button","data-bs-dismiss","modal",1,"btn","btn-elegant",3,"click"],[1,"text-center"],[1,"text-end"],["type","submit",1,"btn","btn-primary",3,"disabled"]],template:function(o,a){o&1&&(i(0,"div",0)(1,"form",1),b("ngSubmit",function(){return a.onSubmit(a.form)}),i(2,"div",2)(3,"h5",3),m(4),s(5,"translate"),n(),i(6,"button",4),s(7,"translate"),b("click",function(){return a.$activeModal.dismiss("Dismiss")}),n()(),i(8,"div",5)(9,"div",6),p(10,"i",7),n(),i(11,"ul",8)(12,"li",9)(13,"label",10),m(14),s(15,"translate"),n(),i(16,"div",11),p(17,"input",12),s(18,"translate"),n()(),i(19,"li",9)(20,"label",13),m(21),s(22,"translate"),n(),i(23,"div",11),p(24,"input",14),s(25,"translate"),n()(),i(26,"li",9)(27,"label",15),m(28),s(29,"translate"),n(),i(30,"div",11),p(31,"input",16),s(32,"translate"),n()(),i(33,"li",9)(34,"label",17),m(35),s(36,"translate"),n(),i(37,"div",11),p(38,"input",18),s(39,"translate"),n()(),i(40,"li",19)(41,"span",20),m(42),s(43,"translate"),n(),i(44,"div",21),p(45,"input",22),s(46,"translate"),p(47,"label",23),n()()()(),i(48,"div",24)(49,"div",20)(50,"button",25),b("click",function(){return a.$activeModal.dismiss("Dismiss")}),m(51),s(52,"translate"),n()(),p(53,"div",26),i(54,"div",27)(55,"button",28),m(56),s(57,"translate"),n()()()()()),o&2&&(e(),f("formGroup",a.form),e(3),d(l(5,18,"users.title_add_user")),e(2),u("aria-label",l(7,20,"form.button_close")),e(8),d(l(15,22,"users.label_username")),e(3),u("aria-label",l(18,24,"users.label_username")),e(4),d(l(22,26,"users.label_full_name")),e(3),u("aria-label",l(25,28,"users.label_full_name")),e(4),d(l(29,30,a.page.password)),e(3),f("ngClass",I(46,se,a.form.controls.password.dirty&&a.form.controls.password.errors)),u("aria-label",l(32,32,a.page.password)),e(4),d(l(36,34,"users.label_confirm_password")),e(3),f("ngClass",I(48,se,a.form.controls.passwordConfirm.dirty&&a.form.controls.passwordConfirm.errors)),u("aria-label",l(39,36,"users.label_confirm_password")),e(4),d(l(43,38,"users.label_admin_user")),e(3),u("aria-label",l(46,40,"users.label_admin_user")),e(6),C(" ",l(52,42,"form.button_close")," "),e(4),f("disabled",!a.form.valid),e(),C(" ",l(57,44,"form.button_save")," "))},dependencies:[V,q,M,F,z,A,L,j,P,$],encapsulation:2})}return r})();var me=r=>({"is-invalid":r});function ge(r,y){if(r&1&&(i(0,"li",9)(1,"label",27),m(2),s(3,"translate"),n(),i(4,"div",11),p(5,"input",28),s(6,"translate"),n()()),r&2){let t=v();e(2),d(l(3,3,"users.label_confirm_password")),e(3),f("ngClass",I(7,me,t.form.controls.passwordConfirm.dirty&&t.form.controls.passwordConfirm.errors)),u("aria-label",l(6,5,"users.label_confirm_password"))}}var pe=(()=>{class r{$activeModal=c(G);$api=c(k);$auth=c(Q);$toastr=c(U);$translate=c(S);user;form=new N({username:new w("",[x.required]),name:new w("",[x.required]),password:new w(""),passwordConfirm:new w(""),admin:new w(!0)},this.matchPassword);page={title:"users.title_edit_user",save:"form.button_save",password:"users.label_new_password"};isCurrentUser=!1;constructor(){}ngOnInit(){this.isCurrentUser=this.$auth.user.username===this.user.username,this.form.patchValue(this.user)}matchPassword(t){let o=t.get("password").value,a=t.get("passwordConfirm").value;if(o!==a)t.get("passwordConfirm").setErrors({matchPassword:!0});else return null}onSubmit({value:t}){this.$api.patch(`/users/${this.user.id}`,t).subscribe({next:()=>{this.$activeModal.close(),this.$toastr.success(this.$translate.instant("users.toast_updated_user"),this.$translate.instant("toast.title_success")),this.isCurrentUser&&t.username!==this.$auth.user.username&&this.$auth.logout()},error:o=>{console.error(o),this.$toastr.error(o.error.message||this.$translate.instant("users.toast_failed_to_add_user"),this.$translate.instant("toast.title_error"))}})}static \u0275fac=function(o){return new(o||r)};static \u0275cmp=E({type:r,selectors:[["ng-component"]],inputs:{user:"user"},decls:52,vars:42,consts:[[1,"modal-content"],["novalidate","",3,"ngSubmit","formGroup"],[1,"modal-header"],[1,"modal-title"],["type","button","data-bs-dismiss","modal",1,"btn-close",3,"click"],[1,"modal-body"],[1,"text-center","mb-3"],[1,"fas","fa-fw","fa-user-pen","primary-text",2,"font-size","75px"],[1,"list-group","list-group-box","mb-0"],[1,"list-group-item","d-flex","flex-column","flex-md-row","align-items-center"],["for","form-username",1,"mb-2","mb-md-0","w-100","w-md-50"],[1,"text-start","text-md-end","w-100","w-md-50"],["formControlName","username","type","text","id","form-username","autocomplete","off","autocapitalize","none",1,"form-control","custom-input"],["for","form-name",1,"mb-2","mb-md-0","w-100","w-md-50"],["formControlName","name","type","text","id","form-name","autocomplete","name",1,"form-control","custom-input"],["for","form-pass",1,"mb-2","mb-md-0","w-100","w-md-50"],["formControlName","password","type","password","autocomplete","new-password","id","form-pass",1,"form-control","custom-input",3,"ngClass"],[1,"list-group-item","d-flex","justify-content-between","align-items-center","flex-row","pb-2"],[1,"text-start"],[1,"text-end","grey-text"],["type","checkbox","formControlName","admin","id","isAdmin",1,"rendux-input"],["for","isAdmin",1,"rendux-label","ms-3"],[1,"modal-footer","justify-content-between"],["type","button","data-bs-dismiss","modal",1,"btn","btn-elegant",3,"click"],[1,"text-center"],[1,"text-end"],["type","submit",1,"btn","btn-primary",3,"disabled"],["for","form-pass-confirm",1,"mb-2","mb-md-0","w-100","w-md-50"],["formControlName","passwordConfirm","type","password","autocomplete","new-password","id","form-pass-confirm",1,"form-control","custom-input",3,"ngClass"]],template:function(o,a){o&1&&(i(0,"div",0)(1,"form",1),b("ngSubmit",function(){return a.onSubmit(a.form)}),i(2,"div",2)(3,"h5",3),m(4),s(5,"translate"),n(),i(6,"button",4),s(7,"translate"),b("click",function(){return a.$activeModal.dismiss("Dismiss")}),n()(),i(8,"div",5)(9,"div",6),p(10,"i",7),n(),i(11,"ul",8)(12,"li",9)(13,"label",10),m(14),s(15,"translate"),n(),i(16,"div",11),p(17,"input",12),s(18,"translate"),n()(),i(19,"li",9)(20,"label",13),m(21),s(22,"translate"),n(),i(23,"div",11),p(24,"input",14),s(25,"translate"),n()(),i(26,"li",9)(27,"label",15),m(28),s(29,"translate"),n(),i(30,"div",11),p(31,"input",16),s(32,"translate"),n()(),h(33,ge,7,9,"li",9),i(34,"li",17)(35,"span",18),m(36),s(37,"translate"),n(),i(38,"div",19),p(39,"input",20),s(40,"translate"),p(41,"label",21),n()()()(),i(42,"div",22)(43,"div",18)(44,"button",23),b("click",function(){return a.$activeModal.dismiss("Dismiss")}),m(45),s(46,"translate"),n()(),p(47,"div",24),i(48,"div",25)(49,"button",26),m(50),s(51,"translate"),n()()()()()),o&2&&(e(),f("formGroup",a.form),e(3),d(l(5,16,"users.title_edit_user")),e(2),u("aria-label",l(7,18,"form.button_close")),e(8),d(l(15,20,"users.label_username")),e(3),u("aria-label",l(18,22,"users.label_username")),e(4),d(l(22,24,"users.label_full_name")),e(3),u("aria-label",l(25,26,"users.label_full_name")),e(4),d(l(29,28,a.page.password)),e(3),f("ngClass",I(40,me,a.form.controls.password.dirty&&a.form.controls.password.errors)),u("aria-label",l(32,30,a.page.password)),e(2),g(a.form.controls.password.value?33:-1),e(3),d(l(37,32,"users.label_admin_user")),e(3),u("aria-label",l(40,34,"users.label_admin_user")),e(6),C(" ",l(46,36,"form.button_close")," "),e(4),f("disabled",!a.form.valid),e(),C(" ",l(51,38,"form.button_save")," "))},dependencies:[V,q,M,Z,F,z,A,L,j,P,$],encapsulation:2})}return r})();function he(r,y){if(r&1){let t=D();i(0,"button",21),b("click",function(){B(t);let a=v().$implicit,_=v();return T(_.setup2fa(a))}),m(1),s(2,"translate"),n()}r&2&&(e(),d(l(2,1,"users.setup_2fa")))}function ye(r,y){if(r&1){let t=D();i(0,"button",17),b("click",function(){B(t);let a=v().$implicit,_=v();return T(_.disable2fa(a))}),m(1),s(2,"translate"),n()}r&2&&(e(),C(" ",l(2,1,"users.setup_2fa_disable")," "))}function Ee(r,y){if(r&1){let t=D();i(0,"div",7)(1,"div",8)(2,"div",9)(3,"div",10)(4,"span",11),p(5,"h4",12)(6,"h5",13),n()(),i(7,"div",14),h(8,he,3,3,"button",15)(9,ye,3,3,"button",16),i(10,"div")(11,"button",17),s(12,"translate"),b("click",function(){let a=B(t).$implicit,_=v();return T(_.openEditUser(a))}),p(13,"i",18),n(),i(14,"button",19),s(15,"translate"),b("click",function(){let a=B(t).$implicit,_=v();return T(_.deleteUser(a.id))}),p(16,"i",20),n()()()()()()}if(r&2){let t=y.$implicit,o=v();e(5),f("innerText",t.name),e(),f("innerText",t.username),e(2),g(o.$auth.user.username===t.username&&!t.otpActive?8:-1),e(),g(o.$auth.user.username===t.username&&t.otpActive?9:-1),e(2),u("aria-label",l(12,7,"form.button_edit")),e(3),f("disabled",o.$auth.user.username===t.username),u("aria-label",l(15,9,"form.button_delete"))}}var gt=(()=>{class r{$api=c(k);$auth=c(Q);$modal=c(te);$route=c(ie);$toastr=c(U);$translate=c(S);homebridgeUsers;constructor(){}ngOnInit(){this.$route.data.subscribe(t=>{this.homebridgeUsers=t.homebridgeUsers})}reloadUsers(){return this.$api.get("/users").subscribe(t=>{this.homebridgeUsers=t})}openAddNewUser(){this.$modal.open(le,{size:"lg",backdrop:"static"}).result.finally(()=>{this.reloadUsers()})}openEditUser(t){let o=this.$modal.open(pe,{size:"lg",backdrop:"static"});o.componentInstance.user=t,o.result.finally(()=>{this.reloadUsers()})}deleteUser(t){this.$api.delete(`/users/${t}`).subscribe({next:()=>{this.$toastr.success(this.$translate.instant("users.toast_user_deleted"),this.$translate.instant("toast.title_success")),this.reloadUsers()},error:o=>{console.error(o),this.$toastr.error(o.error.message||this.$translate.instant("users.toast_failed_to_delete_user"),this.$translate.instant("toast.title_error"))}})}setup2fa(t){let o=this.$modal.open(oe,{size:"lg",backdrop:"static"});o.componentInstance.user=t,o.result.finally(()=>{this.reloadUsers()})}disable2fa(t){let o=this.$modal.open(re,{size:"lg",backdrop:"static"});o.componentInstance.user=t,o.result.finally(()=>{this.reloadUsers()})}static \u0275fac=function(o){return new(o||r)};static \u0275cmp=E({type:r,selectors:[["app-users"]],decls:12,vars:6,consts:[[1,"row","mb-3"],[1,"col-9"],[1,"primary-text","m-0"],[1,"col-3","text-end"],[1,"btn","btn-elegant","waves-effect","m-0",3,"click"],[1,"fas","fa-fw","fa-user-plus"],[1,"row"],[1,"col-md-6","mb-4"],[1,"card","card-body"],[1,"d-flex","flex-column"],[1,"d-flex","flex-row","mb-3"],[1,"me-auto","my-0"],[3,"innerText"],[1,"small","text-truncate","primary-text",3,"innerText"],[1,"d-flex","flex-row","justify-content-between"],[1,"btn","btn-primary","m-0"],[1,"btn","btn-elegant","m-0"],[1,"btn","btn-elegant","m-0",3,"click"],[1,"fas","fa-fw","fa-user-pen"],[1,"btn","btn-danger","m-0","ms-2",3,"click","disabled"],[1,"fas","fa-fw","fa-trash"],[1,"btn","btn-primary","m-0",3,"click"]],template:function(o,a){o&1&&(i(0,"div",0)(1,"div",1)(2,"h3",2),m(3),s(4,"translate"),n()(),i(5,"div",3)(6,"button",4),s(7,"translate"),b("click",function(){return a.openAddNewUser()}),p(8,"i",5),n()()(),i(9,"div",6),W(10,Ee,17,11,"div",7,K),n()),o&2&&(e(3),d(l(4,2,"users.title_users")),e(3),u("aria-label",l(7,4,"users.button_add_user")),e(4),X(a.homebridgeUsers))},dependencies:[$],encapsulation:2})}return r})();export{re as a,oe as b,le as c,pe as d,gt as e};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as St,b as MC}from"./chunk-5VYHCBEW.js";import{a as Vs}from"./chunk-5EOKPNKK.js";import{a as oi,b as ai}from"./chunk-ASGWDNPK.js";import{a as Hs}from"./chunk-CXFP5Z3Z.js";import{a as Gs}from"./chunk-CEJM3DON.js";import{a as Ws}from"./chunk-Z2MYOFRS.js";import{a as rn}from"./chunk-COKV5KB2.js";import{a as Ls,b as zs}from"./chunk-6RXHLHWG.js";import{a as no}from"./chunk-ZOFET4WQ.js";import{a as Us}from"./chunk-Q5OOH5FM.js";import{a as lf,b as df,c as cf,d as pf,e as mf,f as Ff,g as ni,m as Ce,n as Ue,o as fi}from"./chunk-AL4B7SPR.js";import{a as Ts,b as ei,c as ti,e as ot,f as Ps,h as Os,i as Ms,k as js,l as Du,m as Ns,o as ui,r as ii,s as Pu,t as Ou,x as qs,y as At,z as io}from"./chunk-CZTEBDJ7.js";import{a as ri}from"./chunk-MHSSDQTO.js";import{d as qt}from"./chunk-3M4FKD4C.js";import{a as Rs}from"./chunk-74LYVRCB.js";import{b as $e}from"./chunk-S35I2PR5.js";import{h as pe,j as su,k as se}from"./chunk-MILIX2WI.js";import{e as $s}from"./chunk-A36UOKQM.js";import{a as ce,b as ge}from"./chunk-IJXZOFF2.js";import{$c as Tu,Ac as B,Bc as qe,D as gs,Da as _s,Fa as it,Fc as Ss,Ga as R,Ha as rf,Ib as G,Ja as of,Jb as g,Kb as wt,Lb as Xu,M as nf,Mb as Z,Nb as Bs,Ob as w,Qb as He,Rb as We,Sb as Ge,Tb as d,Ub as c,Vb as I,Wb as xs,Xb as ws,Z as uo,Zb as U,_c as gt,a as Q,aa as nn,ac as P,ad as nt,b as Ee,bc as C,cb as oe,dd as ks,e as F,fa as hs,fb as ys,g as Oe,ga as xt,gb as s,h as W,ha as ff,hd as sf,ic as ru,jb as af,jc as ou,k as ps,la as Es,lc as b,ma as x,mc as L,n as pt,nc as q,ob as $u,oc as Wt,pb as fu,pc as Is,q as ms,qc as Be,rc as xe,sb as J,sc as we,ta as fn,tb as Df,tc as As,ua as j,ub as Qu,uc as Ne,v as Fs,va as N,vb as vs,vc as It,w as ne,wc as au,x as Cs,xa as bs,xc as Gt,yb as k,yc as Yu,zc as _}from"./chunk-N5DHAEO2.js";var Js=F((aV,Ks)=>{function NC(){this.__data__=[],this.size=0}Ks.exports=NC});var Cf=F((DV,Zs)=>{function qC(e,u){return e===u||e!==e&&u!==u}Zs.exports=qC});var on=F((sV,Qs)=>{var VC=Cf();function RC(e,u){for(var t=e.length;t--;)if(VC(e[t][0],u))return t;return-1}Qs.exports=RC});var Ys=F((lV,Xs)=>{var LC=on(),zC=Array.prototype,UC=zC.splice;function HC(e){var u=this.__data__,t=LC(u,e);if(t<0)return!1;var i=u.length-1;return t==i?u.pop():UC.call(u,t,1),--this.size,!0}Xs.exports=HC});var t0=F((dV,e0)=>{var WC=on();function GC(e){var u=this.__data__,t=WC(u,e);return t<0?void 0:u[t][1]}e0.exports=GC});var i0=F((cV,u0)=>{var KC=on();function JC(e){return KC(this.__data__,e)>-1}u0.exports=JC});var f0=F((pV,n0)=>{var ZC=on();function QC(e,u){var t=this.__data__,i=ZC(t,e);return i<0?(++this.size,t.push([e,u])):t[i][1]=u,this}n0.exports=QC});var an=F((mV,r0)=>{var XC=Js(),YC=Ys(),e4=t0(),t4=i0(),u4=f0();function si(e){var u=-1,t=e==null?0:e.length;for(this.clear();++u<t;){var i=e[u];this.set(i[0],i[1])}}si.prototype.clear=XC;si.prototype.delete=YC;si.prototype.get=e4;si.prototype.has=t4;si.prototype.set=u4;r0.exports=si});var a0=F((FV,o0)=>{var i4=an();function n4(){this.__data__=new i4,this.size=0}o0.exports=n4});var s0=F((CV,D0)=>{function f4(e){var u=this.__data__,t=u.delete(e);return this.size=u.size,t}D0.exports=f4});var d0=F((gV,l0)=>{function r4(e){return this.__data__.get(e)}l0.exports=r4});var p0=F((hV,c0)=>{function o4(e){return this.__data__.has(e)}c0.exports=o4});var fo=F((EV,m0)=>{var a4=typeof global=="object"&&global&&global.Object===Object&&global;m0.exports=a4});var kt=F((bV,F0)=>{var D4=fo(),s4=typeof self=="object"&&self&&self.Object===Object&&self,l4=D4||s4||Function("return this")();F0.exports=l4});var li=F((_V,C0)=>{var d4=kt(),c4=d4.Symbol;C0.exports=c4});var b0=F((yV,E0)=>{var g0=li(),h0=Object.prototype,p4=h0.hasOwnProperty,m4=h0.toString,Dn=g0?g0.toStringTag:void 0;function F4(e){var u=p4.call(e,Dn),t=e[Dn];try{e[Dn]=void 0;var i=!0}catch{}var n=m4.call(e);return i&&(u?e[Dn]=t:delete e[Dn]),n}E0.exports=F4});var y0=F((vV,_0)=>{var C4=Object.prototype,g4=C4.toString;function h4(e){return g4.call(e)}_0.exports=h4});var Mu=F((BV,x0)=>{var v0=li(),E4=b0(),b4=y0(),_4="[object Null]",y4="[object Undefined]",B0=v0?v0.toStringTag:void 0;function v4(e){return e==null?e===void 0?y4:_4:B0&&B0 in Object(e)?E4(e):b4(e)}x0.exports=v4});var ju=F((xV,w0)=>{function B4(e){var u=typeof e;return e!=null&&(u=="object"||u=="function")}w0.exports=B4});var ro=F((wV,I0)=>{var x4=Mu(),w4=ju(),I4="[object AsyncFunction]",A4="[object Function]",S4="[object GeneratorFunction]",k4="[object Proxy]";function $4(e){if(!w4(e))return!1;var u=x4(e);return u==A4||u==S4||u==I4||u==k4}I0.exports=$4});var S0=F((IV,A0)=>{var T4=kt(),P4=T4["__core-js_shared__"];A0.exports=P4});var T0=F((AV,$0)=>{var oo=S0(),k0=function(){var e=/[^.]+$/.exec(oo&&oo.keys&&oo.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function O4(e){return!!k0&&k0 in e}$0.exports=O4});var ao=F((SV,P0)=>{var M4=Function.prototype,j4=M4.toString;function N4(e){if(e!=null){try{return j4.call(e)}catch{}try{return e+""}catch{}}return""}P0.exports=N4});var M0=F((kV,O0)=>{var q4=ro(),V4=T0(),R4=ju(),L4=ao(),z4=/[\\^$.*+?()[\]{}|]/g,U4=/^\[object .+?Constructor\]$/,H4=Function.prototype,W4=Object.prototype,G4=H4.toString,K4=W4.hasOwnProperty,J4=RegExp("^"+G4.call(K4).replace(z4,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Z4(e){if(!R4(e)||V4(e))return!1;var u=q4(e)?J4:U4;return u.test(L4(e))}O0.exports=Z4});var N0=F(($V,j0)=>{function Q4(e,u){return e==null?void 0:e[u]}j0.exports=Q4});var lu=F((TV,q0)=>{var X4=M0(),Y4=N0();function e5(e,u){var t=Y4(e,u);return X4(t)?t:void 0}q0.exports=e5});var gf=F((PV,V0)=>{var t5=lu(),u5=kt(),i5=t5(u5,"Map");V0.exports=i5});var sn=F((OV,R0)=>{var n5=lu(),f5=n5(Object,"create");R0.exports=f5});var U0=F((MV,z0)=>{var L0=sn();function r5(){this.__data__=L0?L0(null):{},this.size=0}z0.exports=r5});var W0=F((jV,H0)=>{function o5(e){var u=this.has(e)&&delete this.__data__[e];return this.size-=u?1:0,u}H0.exports=o5});var K0=F((NV,G0)=>{var a5=sn(),D5="__lodash_hash_undefined__",s5=Object.prototype,l5=s5.hasOwnProperty;function d5(e){var u=this.__data__;if(a5){var t=u[e];return t===D5?void 0:t}return l5.call(u,e)?u[e]:void 0}G0.exports=d5});var Z0=F((qV,J0)=>{var c5=sn(),p5=Object.prototype,m5=p5.hasOwnProperty;function F5(e){var u=this.__data__;return c5?u[e]!==void 0:m5.call(u,e)}J0.exports=F5});var X0=F((VV,Q0)=>{var C5=sn(),g5="__lodash_hash_undefined__";function h5(e,u){var t=this.__data__;return this.size+=this.has(e)?0:1,t[e]=C5&&u===void 0?g5:u,this}Q0.exports=h5});var e1=F((RV,Y0)=>{var E5=U0(),b5=W0(),_5=K0(),y5=Z0(),v5=X0();function di(e){var u=-1,t=e==null?0:e.length;for(this.clear();++u<t;){var i=e[u];this.set(i[0],i[1])}}di.prototype.clear=E5;di.prototype.delete=b5;di.prototype.get=_5;di.prototype.has=y5;di.prototype.set=v5;Y0.exports=di});var i1=F((LV,u1)=>{var t1=e1(),B5=an(),x5=gf();function w5(){this.size=0,this.__data__={hash:new t1,map:new(x5||B5),string:new t1}}u1.exports=w5});var f1=F((zV,n1)=>{function I5(e){var u=typeof e;return u=="string"||u=="number"||u=="symbol"||u=="boolean"?e!=="__proto__":e===null}n1.exports=I5});var ln=F((UV,r1)=>{var A5=f1();function S5(e,u){var t=e.__data__;return A5(u)?t[typeof u=="string"?"string":"hash"]:t.map}r1.exports=S5});var a1=F((HV,o1)=>{var k5=ln();function $5(e){var u=k5(this,e).delete(e);return this.size-=u?1:0,u}o1.exports=$5});var s1=F((WV,D1)=>{var T5=ln();function P5(e){return T5(this,e).get(e)}D1.exports=P5});var d1=F((GV,l1)=>{var O5=ln();function M5(e){return O5(this,e).has(e)}l1.exports=M5});var p1=F((KV,c1)=>{var j5=ln();function N5(e,u){var t=j5(this,e),i=t.size;return t.set(e,u),this.size+=t.size==i?0:1,this}c1.exports=N5});var hf=F((JV,m1)=>{var q5=i1(),V5=a1(),R5=s1(),L5=d1(),z5=p1();function ci(e){var u=-1,t=e==null?0:e.length;for(this.clear();++u<t;){var i=e[u];this.set(i[0],i[1])}}ci.prototype.clear=q5;ci.prototype.delete=V5;ci.prototype.get=R5;ci.prototype.has=L5;ci.prototype.set=z5;m1.exports=ci});var C1=F((ZV,F1)=>{var U5=an(),H5=gf(),W5=hf(),G5=200;function K5(e,u){var t=this.__data__;if(t instanceof U5){var i=t.__data__;if(!H5||i.length<G5-1)return i.push([e,u]),this.size=++t.size,this;t=this.__data__=new W5(i)}return t.set(e,u),this.size=t.size,this}F1.exports=K5});var Ef=F((QV,g1)=>{var J5=an(),Z5=a0(),Q5=s0(),X5=d0(),Y5=p0(),eg=C1();function pi(e){var u=this.__data__=new J5(e);this.size=u.size}pi.prototype.clear=Z5;pi.prototype.delete=Q5;pi.prototype.get=X5;pi.prototype.has=Y5;pi.prototype.set=eg;g1.exports=pi});var E1=F((XV,h1)=>{function tg(e,u){for(var t=-1,i=e==null?0:e.length;++t<i&&u(e[t],t,e)!==!1;);return e}h1.exports=tg});var _1=F((YV,b1)=>{var ug=lu(),ig=function(){try{var e=ug(Object,"defineProperty");return e({},"",{}),e}catch{}}();b1.exports=ig});var Do=F((eR,v1)=>{var y1=_1();function ng(e,u,t){u=="__proto__"&&y1?y1(e,u,{configurable:!0,enumerable:!0,value:t,writable:!0}):e[u]=t}v1.exports=ng});var so=F((tR,B1)=>{var fg=Do(),rg=Cf(),og=Object.prototype,ag=og.hasOwnProperty;function Dg(e,u,t){var i=e[u];(!(ag.call(e,u)&&rg(i,t))||t===void 0&&!(u in e))&&fg(e,u,t)}B1.exports=Dg});var dn=F((uR,x1)=>{var sg=so(),lg=Do();function dg(e,u,t,i){var n=!t;t||(t={});for(var f=-1,r=u.length;++f<r;){var o=u[f],a=i?i(t[o],e[o],o,t,e):void 0;a===void 0&&(a=e[o]),n?lg(t,o,a):sg(t,o,a)}return t}x1.exports=dg});var I1=F((iR,w1)=>{function cg(e,u){for(var t=-1,i=Array(e);++t<e;)i[t]=u(t);return i}w1.exports=cg});var Kt=F((nR,A1)=>{function pg(e){return e!=null&&typeof e=="object"}A1.exports=pg});var k1=F((fR,S1)=>{var mg=Mu(),Fg=Kt(),Cg="[object Arguments]";function gg(e){return Fg(e)&&mg(e)==Cg}S1.exports=gg});var lo=F((rR,P1)=>{var $1=k1(),hg=Kt(),T1=Object.prototype,Eg=T1.hasOwnProperty,bg=T1.propertyIsEnumerable,_g=$1(function(){return arguments}())?$1:function(e){return hg(e)&&Eg.call(e,"callee")&&!bg.call(e,"callee")};P1.exports=_g});var mt=F((oR,O1)=>{var yg=Array.isArray;O1.exports=yg});var j1=F((aR,M1)=>{function vg(){return!1}M1.exports=vg});var bf=F((cn,mi)=>{var Bg=kt(),xg=j1(),V1=typeof cn=="object"&&cn&&!cn.nodeType&&cn,N1=V1&&typeof mi=="object"&&mi&&!mi.nodeType&&mi,wg=N1&&N1.exports===V1,q1=wg?Bg.Buffer:void 0,Ig=q1?q1.isBuffer:void 0,Ag=Ig||xg;mi.exports=Ag});var co=F((DR,R1)=>{var Sg=9007199254740991,kg=/^(?:0|[1-9]\d*)$/;function $g(e,u){var t=typeof e;return u=u==null?Sg:u,!!u&&(t=="number"||t!="symbol"&&kg.test(e))&&e>-1&&e%1==0&&e<u}R1.exports=$g});var _f=F((sR,L1)=>{var Tg=9007199254740991;function Pg(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=Tg}L1.exports=Pg});var U1=F((lR,z1)=>{var Og=Mu(),Mg=_f(),jg=Kt(),Ng="[object Arguments]",qg="[object Array]",Vg="[object Boolean]",Rg="[object Date]",Lg="[object Error]",zg="[object Function]",Ug="[object Map]",Hg="[object Number]",Wg="[object Object]",Gg="[object RegExp]",Kg="[object Set]",Jg="[object String]",Zg="[object WeakMap]",Qg="[object ArrayBuffer]",Xg="[object DataView]",Yg="[object Float32Array]",eh="[object Float64Array]",th="[object Int8Array]",uh="[object Int16Array]",ih="[object Int32Array]",nh="[object Uint8Array]",fh="[object Uint8ClampedArray]",rh="[object Uint16Array]",oh="[object Uint32Array]",Ie={};Ie[Yg]=Ie[eh]=Ie[th]=Ie[uh]=Ie[ih]=Ie[nh]=Ie[fh]=Ie[rh]=Ie[oh]=!0;Ie[Ng]=Ie[qg]=Ie[Qg]=Ie[Vg]=Ie[Xg]=Ie[Rg]=Ie[Lg]=Ie[zg]=Ie[Ug]=Ie[Hg]=Ie[Wg]=Ie[Gg]=Ie[Kg]=Ie[Jg]=Ie[Zg]=!1;function ah(e){return jg(e)&&Mg(e.length)&&!!Ie[Og(e)]}z1.exports=ah});var yf=F((dR,H1)=>{function Dh(e){return function(u){return e(u)}}H1.exports=Dh});var vf=F((pn,Fi)=>{var sh=fo(),W1=typeof pn=="object"&&pn&&!pn.nodeType&&pn,mn=W1&&typeof Fi=="object"&&Fi&&!Fi.nodeType&&Fi,lh=mn&&mn.exports===W1,po=lh&&sh.process,dh=function(){try{var e=mn&&mn.require&&mn.require("util").types;return e||po&&po.binding&&po.binding("util")}catch{}}();Fi.exports=dh});var mo=F((cR,J1)=>{var ch=U1(),ph=yf(),G1=vf(),K1=G1&&G1.isTypedArray,mh=K1?ph(K1):ch;J1.exports=mh});var Fo=F((pR,Z1)=>{var Fh=I1(),Ch=lo(),gh=mt(),hh=bf(),Eh=co(),bh=mo(),_h=Object.prototype,yh=_h.hasOwnProperty;function vh(e,u){var t=gh(e),i=!t&&Ch(e),n=!t&&!i&&hh(e),f=!t&&!i&&!n&&bh(e),r=t||i||n||f,o=r?Fh(e.length,String):[],a=o.length;for(var D in e)(u||yh.call(e,D))&&!(r&&(D=="length"||n&&(D=="offset"||D=="parent")||f&&(D=="buffer"||D=="byteLength"||D=="byteOffset")||Eh(D,a)))&&o.push(D);return o}Z1.exports=vh});var Bf=F((mR,Q1)=>{var Bh=Object.prototype;function xh(e){var u=e&&e.constructor,t=typeof u=="function"&&u.prototype||Bh;return e===t}Q1.exports=xh});var Co=F((FR,X1)=>{function wh(e,u){return function(t){return e(u(t))}}X1.exports=wh});var el=F((CR,Y1)=>{var Ih=Co(),Ah=Ih(Object.keys,Object);Y1.exports=Ah});var ul=F((gR,tl)=>{var Sh=Bf(),kh=el(),$h=Object.prototype,Th=$h.hasOwnProperty;function Ph(e){if(!Sh(e))return kh(e);var u=[];for(var t in Object(e))Th.call(e,t)&&t!="constructor"&&u.push(t);return u}tl.exports=Ph});var Fn=F((hR,il)=>{var Oh=ro(),Mh=_f();function jh(e){return e!=null&&Mh(e.length)&&!Oh(e)}il.exports=jh});var Ci=F((ER,nl)=>{var Nh=Fo(),qh=ul(),Vh=Fn();function Rh(e){return Vh(e)?Nh(e):qh(e)}nl.exports=Rh});var rl=F((bR,fl)=>{var Lh=dn(),zh=Ci();function Uh(e,u){return e&&Lh(u,zh(u),e)}fl.exports=Uh});var al=F((_R,ol)=>{function Hh(e){var u=[];if(e!=null)for(var t in Object(e))u.push(t);return u}ol.exports=Hh});var sl=F((yR,Dl)=>{var Wh=ju(),Gh=Bf(),Kh=al(),Jh=Object.prototype,Zh=Jh.hasOwnProperty;function Qh(e){if(!Wh(e))return Kh(e);var u=Gh(e),t=[];for(var i in e)i=="constructor"&&(u||!Zh.call(e,i))||t.push(i);return t}Dl.exports=Qh});var xf=F((vR,ll)=>{var Xh=Fo(),Yh=sl(),e6=Fn();function t6(e){return e6(e)?Xh(e,!0):Yh(e)}ll.exports=t6});var cl=F((BR,dl)=>{var u6=dn(),i6=xf();function n6(e,u){return e&&u6(u,i6(u),e)}dl.exports=n6});var gl=F((Cn,gi)=>{var f6=kt(),Cl=typeof Cn=="object"&&Cn&&!Cn.nodeType&&Cn,pl=Cl&&typeof gi=="object"&&gi&&!gi.nodeType&&gi,r6=pl&&pl.exports===Cl,ml=r6?f6.Buffer:void 0,Fl=ml?ml.allocUnsafe:void 0;function o6(e,u){if(u)return e.slice();var t=e.length,i=Fl?Fl(t):new e.constructor(t);return e.copy(i),i}gi.exports=o6});var El=F((xR,hl)=>{function a6(e,u){var t=-1,i=e.length;for(u||(u=Array(i));++t<i;)u[t]=e[t];return u}hl.exports=a6});var go=F((wR,bl)=>{function D6(e,u){for(var t=-1,i=e==null?0:e.length,n=0,f=[];++t<i;){var r=e[t];u(r,t,e)&&(f[n++]=r)}return f}bl.exports=D6});var ho=F((IR,_l)=>{function s6(){return[]}_l.exports=s6});var wf=F((AR,vl)=>{var l6=go(),d6=ho(),c6=Object.prototype,p6=c6.propertyIsEnumerable,yl=Object.getOwnPropertySymbols,m6=yl?function(e){return e==null?[]:(e=Object(e),l6(yl(e),function(u){return p6.call(e,u)}))}:d6;vl.exports=m6});var xl=F((SR,Bl)=>{var F6=dn(),C6=wf();function g6(e,u){return F6(e,C6(e),u)}Bl.exports=g6});var Eo=F((kR,wl)=>{function h6(e,u){for(var t=-1,i=u.length,n=e.length;++t<i;)e[n+t]=u[t];return e}wl.exports=h6});var If=F(($R,Il)=>{var E6=Co(),b6=E6(Object.getPrototypeOf,Object);Il.exports=b6});var bo=F((TR,Al)=>{var _6=Eo(),y6=If(),v6=wf(),B6=ho(),x6=Object.getOwnPropertySymbols,w6=x6?function(e){for(var u=[];e;)_6(u,v6(e)),e=y6(e);return u}:B6;Al.exports=w6});var kl=F((PR,Sl)=>{var I6=dn(),A6=bo();function S6(e,u){return I6(e,A6(e),u)}Sl.exports=S6});var _o=F((OR,$l)=>{var k6=Eo(),$6=mt();function T6(e,u,t){var i=u(e);return $6(e)?i:k6(i,t(e))}$l.exports=T6});var yo=F((MR,Tl)=>{var P6=_o(),O6=wf(),M6=Ci();function j6(e){return P6(e,M6,O6)}Tl.exports=j6});var Ol=F((jR,Pl)=>{var N6=_o(),q6=bo(),V6=xf();function R6(e){return N6(e,V6,q6)}Pl.exports=R6});var jl=F((NR,Ml)=>{var L6=lu(),z6=kt(),U6=L6(z6,"DataView");Ml.exports=U6});var ql=F((qR,Nl)=>{var H6=lu(),W6=kt(),G6=H6(W6,"Promise");Nl.exports=G6});var Rl=F((VR,Vl)=>{var K6=lu(),J6=kt(),Z6=K6(J6,"Set");Vl.exports=Z6});var zl=F((RR,Ll)=>{var Q6=lu(),X6=kt(),Y6=Q6(X6,"WeakMap");Ll.exports=Y6});var gn=F((LR,Zl)=>{var vo=jl(),Bo=gf(),xo=ql(),wo=Rl(),Io=zl(),Jl=Mu(),hi=ao(),Ul="[object Map]",eE="[object Object]",Hl="[object Promise]",Wl="[object Set]",Gl="[object WeakMap]",Kl="[object DataView]",tE=hi(vo),uE=hi(Bo),iE=hi(xo),nE=hi(wo),fE=hi(Io),Nu=Jl;(vo&&Nu(new vo(new ArrayBuffer(1)))!=Kl||Bo&&Nu(new Bo)!=Ul||xo&&Nu(xo.resolve())!=Hl||wo&&Nu(new wo)!=Wl||Io&&Nu(new Io)!=Gl)&&(Nu=function(e){var u=Jl(e),t=u==eE?e.constructor:void 0,i=t?hi(t):"";if(i)switch(i){case tE:return Kl;case uE:return Ul;case iE:return Hl;case nE:return Wl;case fE:return Gl}return u});Zl.exports=Nu});var Xl=F((zR,Ql)=>{var rE=Object.prototype,oE=rE.hasOwnProperty;function aE(e){var u=e.length,t=new e.constructor(u);return u&&typeof e[0]=="string"&&oE.call(e,"index")&&(t.index=e.index,t.input=e.input),t}Ql.exports=aE});var Ao=F((UR,Yl)=>{var DE=kt(),sE=DE.Uint8Array;Yl.exports=sE});var Af=F((HR,td)=>{var ed=Ao();function lE(e){var u=new e.constructor(e.byteLength);return new ed(u).set(new ed(e)),u}td.exports=lE});var id=F((WR,ud)=>{var dE=Af();function cE(e,u){var t=u?dE(e.buffer):e.buffer;return new e.constructor(t,e.byteOffset,e.byteLength)}ud.exports=cE});var fd=F((GR,nd)=>{var pE=/\w*$/;function mE(e){var u=new e.constructor(e.source,pE.exec(e));return u.lastIndex=e.lastIndex,u}nd.exports=mE});var sd=F((KR,Dd)=>{var rd=li(),od=rd?rd.prototype:void 0,ad=od?od.valueOf:void 0;function FE(e){return ad?Object(ad.call(e)):{}}Dd.exports=FE});var dd=F((JR,ld)=>{var CE=Af();function gE(e,u){var t=u?CE(e.buffer):e.buffer;return new e.constructor(t,e.byteOffset,e.length)}ld.exports=gE});var pd=F((ZR,cd)=>{var hE=Af(),EE=id(),bE=fd(),_E=sd(),yE=dd(),vE="[object Boolean]",BE="[object Date]",xE="[object Map]",wE="[object Number]",IE="[object RegExp]",AE="[object Set]",SE="[object String]",kE="[object Symbol]",$E="[object ArrayBuffer]",TE="[object DataView]",PE="[object Float32Array]",OE="[object Float64Array]",ME="[object Int8Array]",jE="[object Int16Array]",NE="[object Int32Array]",qE="[object Uint8Array]",VE="[object Uint8ClampedArray]",RE="[object Uint16Array]",LE="[object Uint32Array]";function zE(e,u,t){var i=e.constructor;switch(u){case $E:return hE(e);case vE:case BE:return new i(+e);case TE:return EE(e,t);case PE:case OE:case ME:case jE:case NE:case qE:case VE:case RE:case LE:return yE(e,t);case xE:return new i;case wE:case SE:return new i(e);case IE:return bE(e);case AE:return new i;case kE:return _E(e)}}cd.exports=zE});var Cd=F((QR,Fd)=>{var UE=ju(),md=Object.create,HE=function(){function e(){}return function(u){if(!UE(u))return{};if(md)return md(u);e.prototype=u;var t=new e;return e.prototype=void 0,t}}();Fd.exports=HE});var hd=F((XR,gd)=>{var WE=Cd(),GE=If(),KE=Bf();function JE(e){return typeof e.constructor=="function"&&!KE(e)?WE(GE(e)):{}}gd.exports=JE});var bd=F((YR,Ed)=>{var ZE=gn(),QE=Kt(),XE="[object Map]";function YE(e){return QE(e)&&ZE(e)==XE}Ed.exports=YE});var Bd=F((eL,vd)=>{var eb=bd(),tb=yf(),_d=vf(),yd=_d&&_d.isMap,ub=yd?tb(yd):eb;vd.exports=ub});var wd=F((tL,xd)=>{var ib=gn(),nb=Kt(),fb="[object Set]";function rb(e){return nb(e)&&ib(e)==fb}xd.exports=rb});var kd=F((uL,Sd)=>{var ob=wd(),ab=yf(),Id=vf(),Ad=Id&&Id.isSet,Db=Ad?ab(Ad):ob;Sd.exports=Db});var Md=F((iL,Od)=>{var sb=Ef(),lb=E1(),db=so(),cb=rl(),pb=cl(),mb=gl(),Fb=El(),Cb=xl(),gb=kl(),hb=yo(),Eb=Ol(),bb=gn(),_b=Xl(),yb=pd(),vb=hd(),Bb=mt(),xb=bf(),wb=Bd(),Ib=ju(),Ab=kd(),Sb=Ci(),kb=xf(),$b=1,Tb=2,Pb=4,$d="[object Arguments]",Ob="[object Array]",Mb="[object Boolean]",jb="[object Date]",Nb="[object Error]",Td="[object Function]",qb="[object GeneratorFunction]",Vb="[object Map]",Rb="[object Number]",Pd="[object Object]",Lb="[object RegExp]",zb="[object Set]",Ub="[object String]",Hb="[object Symbol]",Wb="[object WeakMap]",Gb="[object ArrayBuffer]",Kb="[object DataView]",Jb="[object Float32Array]",Zb="[object Float64Array]",Qb="[object Int8Array]",Xb="[object Int16Array]",Yb="[object Int32Array]",e_="[object Uint8Array]",t_="[object Uint8ClampedArray]",u_="[object Uint16Array]",i_="[object Uint32Array]",ye={};ye[$d]=ye[Ob]=ye[Gb]=ye[Kb]=ye[Mb]=ye[jb]=ye[Jb]=ye[Zb]=ye[Qb]=ye[Xb]=ye[Yb]=ye[Vb]=ye[Rb]=ye[Pd]=ye[Lb]=ye[zb]=ye[Ub]=ye[Hb]=ye[e_]=ye[t_]=ye[u_]=ye[i_]=!0;ye[Nb]=ye[Td]=ye[Wb]=!1;function Sf(e,u,t,i,n,f){var r,o=u&$b,a=u&Tb,D=u&Pb;if(t&&(r=n?t(e,i,n,f):t(e)),r!==void 0)return r;if(!Ib(e))return e;var l=Bb(e);if(l){if(r=_b(e),!o)return Fb(e,r)}else{var p=bb(e),m=p==Td||p==qb;if(xb(e))return mb(e,o);if(p==Pd||p==$d||m&&!n){if(r=a||m?{}:vb(e),!o)return a?gb(e,pb(r,e)):Cb(e,cb(r,e))}else{if(!ye[p])return n?e:{};r=yb(e,p,o)}}f||(f=new sb);var E=f.get(e);if(E)return E;f.set(e,r),Ab(e)?e.forEach(function(v){r.add(Sf(v,u,t,v,e,f))}):wb(e)&&e.forEach(function(v,S){r.set(S,Sf(v,u,t,S,e,f))});var h=D?a?Eb:hb:a?kb:Sb,y=l?void 0:h(e);return lb(y||e,function(v,S){y&&(S=v,v=e[S]),db(r,S,Sf(v,u,t,S,e,f))}),r}Od.exports=Sf});var Nd=F((nL,jd)=>{var n_=Md(),f_=1,r_=4;function o_(e){return n_(e,f_|r_)}jd.exports=o_});var Vd=F((fL,qd)=>{var a_="__lodash_hash_undefined__";function D_(e){return this.__data__.set(e,a_),this}qd.exports=D_});var Ld=F((rL,Rd)=>{function s_(e){return this.__data__.has(e)}Rd.exports=s_});var Ud=F((oL,zd)=>{var l_=hf(),d_=Vd(),c_=Ld();function kf(e){var u=-1,t=e==null?0:e.length;for(this.__data__=new l_;++u<t;)this.add(e[u])}kf.prototype.add=kf.prototype.push=d_;kf.prototype.has=c_;zd.exports=kf});var Wd=F((aL,Hd)=>{function p_(e,u){for(var t=-1,i=e==null?0:e.length;++t<i;)if(u(e[t],t,e))return!0;return!1}Hd.exports=p_});var Kd=F((DL,Gd)=>{function m_(e,u){return e.has(u)}Gd.exports=m_});var So=F((sL,Jd)=>{var F_=Ud(),C_=Wd(),g_=Kd(),h_=1,E_=2;function b_(e,u,t,i,n,f){var r=t&h_,o=e.length,a=u.length;if(o!=a&&!(r&&a>o))return!1;var D=f.get(e),l=f.get(u);if(D&&l)return D==u&&l==e;var p=-1,m=!0,E=t&E_?new F_:void 0;for(f.set(e,u),f.set(u,e);++p<o;){var h=e[p],y=u[p];if(i)var v=r?i(y,h,p,u,e,f):i(h,y,p,e,u,f);if(v!==void 0){if(v)continue;m=!1;break}if(E){if(!C_(u,function(S,O){if(!g_(E,O)&&(h===S||n(h,S,t,i,f)))return E.push(O)})){m=!1;break}}else if(!(h===y||n(h,y,t,i,f))){m=!1;break}}return f.delete(e),f.delete(u),m}Jd.exports=b_});var Qd=F((lL,Zd)=>{function __(e){var u=-1,t=Array(e.size);return e.forEach(function(i,n){t[++u]=[n,i]}),t}Zd.exports=__});var Yd=F((dL,Xd)=>{function y_(e){var u=-1,t=Array(e.size);return e.forEach(function(i){t[++u]=i}),t}Xd.exports=y_});var n3=F((cL,i3)=>{var e3=li(),t3=Ao(),v_=Cf(),B_=So(),x_=Qd(),w_=Yd(),I_=1,A_=2,S_="[object Boolean]",k_="[object Date]",$_="[object Error]",T_="[object Map]",P_="[object Number]",O_="[object RegExp]",M_="[object Set]",j_="[object String]",N_="[object Symbol]",q_="[object ArrayBuffer]",V_="[object DataView]",u3=e3?e3.prototype:void 0,ko=u3?u3.valueOf:void 0;function R_(e,u,t,i,n,f,r){switch(t){case V_:if(e.byteLength!=u.byteLength||e.byteOffset!=u.byteOffset)return!1;e=e.buffer,u=u.buffer;case q_:return!(e.byteLength!=u.byteLength||!f(new t3(e),new t3(u)));case S_:case k_:case P_:return v_(+e,+u);case $_:return e.name==u.name&&e.message==u.message;case O_:case j_:return e==u+"";case T_:var o=x_;case M_:var a=i&I_;if(o||(o=w_),e.size!=u.size&&!a)return!1;var D=r.get(e);if(D)return D==u;i|=A_,r.set(e,u);var l=B_(o(e),o(u),i,n,f,r);return r.delete(e),l;case N_:if(ko)return ko.call(e)==ko.call(u)}return!1}i3.exports=R_});var o3=F((pL,r3)=>{var f3=yo(),L_=1,z_=Object.prototype,U_=z_.hasOwnProperty;function H_(e,u,t,i,n,f){var r=t&L_,o=f3(e),a=o.length,D=f3(u),l=D.length;if(a!=l&&!r)return!1;for(var p=a;p--;){var m=o[p];if(!(r?m in u:U_.call(u,m)))return!1}var E=f.get(e),h=f.get(u);if(E&&h)return E==u&&h==e;var y=!0;f.set(e,u),f.set(u,e);for(var v=r;++p<a;){m=o[p];var S=e[m],O=u[m];if(i)var z=r?i(O,S,m,u,e,f):i(S,O,m,e,u,f);if(!(z===void 0?S===O||n(S,O,t,i,f):z)){y=!1;break}v||(v=m=="constructor")}if(y&&!v){var H=e.constructor,M=u.constructor;H!=M&&"constructor"in e&&"constructor"in u&&!(typeof H=="function"&&H instanceof H&&typeof M=="function"&&M instanceof M)&&(y=!1)}return f.delete(e),f.delete(u),y}r3.exports=H_});var m3=F((mL,p3)=>{var $o=Ef(),W_=So(),G_=n3(),K_=o3(),a3=gn(),D3=mt(),s3=bf(),J_=mo(),Z_=1,l3="[object Arguments]",d3="[object Array]",$f="[object Object]",Q_=Object.prototype,c3=Q_.hasOwnProperty;function X_(e,u,t,i,n,f){var r=D3(e),o=D3(u),a=r?d3:a3(e),D=o?d3:a3(u);a=a==l3?$f:a,D=D==l3?$f:D;var l=a==$f,p=D==$f,m=a==D;if(m&&s3(e)){if(!s3(u))return!1;r=!0,l=!1}if(m&&!l)return f||(f=new $o),r||J_(e)?W_(e,u,t,i,n,f):G_(e,u,a,t,i,n,f);if(!(t&Z_)){var E=l&&c3.call(e,"__wrapped__"),h=p&&c3.call(u,"__wrapped__");if(E||h){var y=E?e.value():e,v=h?u.value():u;return f||(f=new $o),n(y,v,t,i,f)}}return m?(f||(f=new $o),K_(e,u,t,i,n,f)):!1}p3.exports=X_});var Tf=F((FL,g3)=>{var Y_=m3(),F3=Kt();function C3(e,u,t,i,n){return e===u?!0:e==null||u==null||!F3(e)&&!F3(u)?e!==e&&u!==u:Y_(e,u,t,i,C3,n)}g3.exports=C3});var E3=F((CL,h3)=>{var e9=Tf();function t9(e,u){return e9(e,u)}h3.exports=t9});var bn=F(de=>{"use strict";Object.defineProperty(de,"__esModule",{value:!0});de.regexpCode=de.getEsmExportName=de.getProperty=de.safeStringify=de.stringify=de.strConcat=de.addCodeArg=de.str=de._=de.nil=de._Code=de.Name=de.IDENTIFIER=de._CodeOrName=void 0;var hn=class{};de._CodeOrName=hn;de.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;var qu=class extends hn{constructor(u){if(super(),!de.IDENTIFIER.test(u))throw new Error("CodeGen: name must be a valid identifier");this.str=u}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}};de.Name=qu;var ht=class extends hn{constructor(u){super(),this._items=typeof u=="string"?[u]:u}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;let u=this._items[0];return u===""||u==='""'}get str(){var u;return(u=this._str)!==null&&u!==void 0?u:this._str=this._items.reduce((t,i)=>`${t}${i}`,"")}get names(){var u;return(u=this._names)!==null&&u!==void 0?u:this._names=this._items.reduce((t,i)=>(i instanceof qu&&(t[i.str]=(t[i.str]||0)+1),t),{})}};de._Code=ht;de.nil=new ht("");function b3(e,...u){let t=[e[0]],i=0;for(;i<u.length;)Po(t,u[i]),t.push(e[++i]);return new ht(t)}de._=b3;var To=new ht("+");function _3(e,...u){let t=[En(e[0])],i=0;for(;i<u.length;)t.push(To),Po(t,u[i]),t.push(To,En(e[++i]));return u9(t),new ht(t)}de.str=_3;function Po(e,u){u instanceof ht?e.push(...u._items):u instanceof qu?e.push(u):e.push(f9(u))}de.addCodeArg=Po;function u9(e){let u=1;for(;u<e.length-1;){if(e[u]===To){let t=i9(e[u-1],e[u+1]);if(t!==void 0){e.splice(u-1,3,t);continue}e[u++]="+"}u++}}function i9(e,u){if(u==='""')return e;if(e==='""')return u;if(typeof e=="string")return u instanceof qu||e[e.length-1]!=='"'?void 0:typeof u!="string"?`${e.slice(0,-1)}${u}"`:u[0]==='"'?e.slice(0,-1)+u.slice(1):void 0;if(typeof u=="string"&&u[0]==='"'&&!(e instanceof qu))return`"${e}${u.slice(1)}`}function n9(e,u){return u.emptyStr()?e:e.emptyStr()?u:_3`${e}${u}`}de.strConcat=n9;function f9(e){return typeof e=="number"||typeof e=="boolean"||e===null?e:En(Array.isArray(e)?e.join(","):e)}function r9(e){return new ht(En(e))}de.stringify=r9;function En(e){return JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}de.safeStringify=En;function o9(e){return typeof e=="string"&&de.IDENTIFIER.test(e)?new ht(`.${e}`):b3`[${e}]`}de.getProperty=o9;function a9(e){if(typeof e=="string"&&de.IDENTIFIER.test(e))return new ht(`${e}`);throw new Error(`CodeGen: invalid export name: ${e}, use explicit $id name mapping`)}de.getEsmExportName=a9;function D9(e){return new ht(e.toString())}de.regexpCode=D9});var jo=F(Dt=>{"use strict";Object.defineProperty(Dt,"__esModule",{value:!0});Dt.ValueScope=Dt.ValueScopeName=Dt.Scope=Dt.varKinds=Dt.UsedValueState=void 0;var at=bn(),Oo=class extends Error{constructor(u){super(`CodeGen: "code" for ${u} not defined`),this.value=u.value}},Pf=function(e){return e[e.Started=0]="Started",e[e.Completed=1]="Completed",e}(Pf||(Dt.UsedValueState=Pf={}));Dt.varKinds={const:new at.Name("const"),let:new at.Name("let"),var:new at.Name("var")};var Of=class{constructor({prefixes:u,parent:t}={}){this._names={},this._prefixes=u,this._parent=t}toName(u){return u instanceof at.Name?u:this.name(u)}name(u){return new at.Name(this._newName(u))}_newName(u){let t=this._names[u]||this._nameGroup(u);return`${u}${t.index++}`}_nameGroup(u){var t,i;if(!((i=(t=this._parent)===null||t===void 0?void 0:t._prefixes)===null||i===void 0)&&i.has(u)||this._prefixes&&!this._prefixes.has(u))throw new Error(`CodeGen: prefix "${u}" is not allowed in this scope`);return this._names[u]={prefix:u,index:0}}};Dt.Scope=Of;var Mf=class extends at.Name{constructor(u,t){super(t),this.prefix=u}setValue(u,{property:t,itemIndex:i}){this.value=u,this.scopePath=(0,at._)`.${new at.Name(t)}[${i}]`}};Dt.ValueScopeName=Mf;var s9=(0,at._)`\n`,Mo=class extends Of{constructor(u){super(u),this._values={},this._scope=u.scope,this.opts=Ee(Q({},u),{_n:u.lines?s9:at.nil})}get(){return this._scope}name(u){return new Mf(u,this._newName(u))}value(u,t){var i;if(t.ref===void 0)throw new Error("CodeGen: ref must be passed in value");let n=this.toName(u),{prefix:f}=n,r=(i=t.key)!==null&&i!==void 0?i:t.ref,o=this._values[f];if(o){let l=o.get(r);if(l)return l}else o=this._values[f]=new Map;o.set(r,n);let a=this._scope[f]||(this._scope[f]=[]),D=a.length;return a[D]=t.ref,n.setValue(t,{property:f,itemIndex:D}),n}getValue(u,t){let i=this._values[u];if(i)return i.get(t)}scopeRefs(u,t=this._values){return this._reduceValues(t,i=>{if(i.scopePath===void 0)throw new Error(`CodeGen: name "${i}" has no value`);return(0,at._)`${u}${i.scopePath}`})}scopeCode(u=this._values,t,i){return this._reduceValues(u,n=>{if(n.value===void 0)throw new Error(`CodeGen: name "${n}" has no value`);return n.value.code},t,i)}_reduceValues(u,t,i={},n){let f=at.nil;for(let r in u){let o=u[r];if(!o)continue;let a=i[r]=i[r]||new Map;o.forEach(D=>{if(a.has(D))return;a.set(D,Pf.Started);let l=t(D);if(l){let p=this.opts.es5?Dt.varKinds.var:Dt.varKinds.const;f=(0,at._)`${f}${p} ${D} = ${l};${this.opts._n}`}else if(l=n==null?void 0:n(D))f=(0,at._)`${f}${l}${this.opts._n}`;else throw new Oo(D);a.set(D,Pf.Completed)})}return f}};Dt.ValueScope=Mo});var te=F(ie=>{"use strict";Object.defineProperty(ie,"__esModule",{value:!0});ie.or=ie.and=ie.not=ie.CodeGen=ie.operators=ie.varKinds=ie.ValueScopeName=ie.ValueScope=ie.Scope=ie.Name=ie.regexpCode=ie.stringify=ie.getProperty=ie.nil=ie.strConcat=ie.str=ie._=void 0;var De=bn(),$t=jo(),du=bn();Object.defineProperty(ie,"_",{enumerable:!0,get:function(){return du._}});Object.defineProperty(ie,"str",{enumerable:!0,get:function(){return du.str}});Object.defineProperty(ie,"strConcat",{enumerable:!0,get:function(){return du.strConcat}});Object.defineProperty(ie,"nil",{enumerable:!0,get:function(){return du.nil}});Object.defineProperty(ie,"getProperty",{enumerable:!0,get:function(){return du.getProperty}});Object.defineProperty(ie,"stringify",{enumerable:!0,get:function(){return du.stringify}});Object.defineProperty(ie,"regexpCode",{enumerable:!0,get:function(){return du.regexpCode}});Object.defineProperty(ie,"Name",{enumerable:!0,get:function(){return du.Name}});var Rf=jo();Object.defineProperty(ie,"Scope",{enumerable:!0,get:function(){return Rf.Scope}});Object.defineProperty(ie,"ValueScope",{enumerable:!0,get:function(){return Rf.ValueScope}});Object.defineProperty(ie,"ValueScopeName",{enumerable:!0,get:function(){return Rf.ValueScopeName}});Object.defineProperty(ie,"varKinds",{enumerable:!0,get:function(){return Rf.varKinds}});ie.operators={GT:new De._Code(">"),GTE:new De._Code(">="),LT:new De._Code("<"),LTE:new De._Code("<="),EQ:new De._Code("==="),NEQ:new De._Code("!=="),NOT:new De._Code("!"),OR:new De._Code("||"),AND:new De._Code("&&"),ADD:new De._Code("+")};var Jt=class{optimizeNodes(){return this}optimizeNames(u,t){return this}},No=class extends Jt{constructor(u,t,i){super(),this.varKind=u,this.name=t,this.rhs=i}render({es5:u,_n:t}){let i=u?$t.varKinds.var:this.varKind,n=this.rhs===void 0?"":` = ${this.rhs}`;return`${i} ${this.name}${n};`+t}optimizeNames(u,t){if(u[this.name.str])return this.rhs&&(this.rhs=Ei(this.rhs,u,t)),this}get names(){return this.rhs instanceof De._CodeOrName?this.rhs.names:{}}},Nf=class extends Jt{constructor(u,t,i){super(),this.lhs=u,this.rhs=t,this.sideEffects=i}render({_n:u}){return`${this.lhs} = ${this.rhs};`+u}optimizeNames(u,t){if(!(this.lhs instanceof De.Name&&!u[this.lhs.str]&&!this.sideEffects))return this.rhs=Ei(this.rhs,u,t),this}get names(){let u=this.lhs instanceof De.Name?{}:Q({},this.lhs.names);return Vf(u,this.rhs)}},qo=class extends Nf{constructor(u,t,i,n){super(u,i,n),this.op=t}render({_n:u}){return`${this.lhs} ${this.op}= ${this.rhs};`+u}},Vo=class extends Jt{constructor(u){super(),this.label=u,this.names={}}render({_n:u}){return`${this.label}:`+u}},Ro=class extends Jt{constructor(u){super(),this.label=u,this.names={}}render({_n:u}){return`break${this.label?` ${this.label}`:""};`+u}},Lo=class extends Jt{constructor(u){super(),this.error=u}render({_n:u}){return`throw ${this.error};`+u}get names(){return this.error.names}},zo=class extends Jt{constructor(u){super(),this.code=u}render({_n:u}){return`${this.code};`+u}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(u,t){return this.code=Ei(this.code,u,t),this}get names(){return this.code instanceof De._CodeOrName?this.code.names:{}}},_n=class extends Jt{constructor(u=[]){super(),this.nodes=u}render(u){return this.nodes.reduce((t,i)=>t+i.render(u),"")}optimizeNodes(){let{nodes:u}=this,t=u.length;for(;t--;){let i=u[t].optimizeNodes();Array.isArray(i)?u.splice(t,1,...i):i?u[t]=i:u.splice(t,1)}return u.length>0?this:void 0}optimizeNames(u,t){let{nodes:i}=this,n=i.length;for(;n--;){let f=i[n];f.optimizeNames(u,t)||(l9(u,f.names),i.splice(n,1))}return i.length>0?this:void 0}get names(){return this.nodes.reduce((u,t)=>Vu(u,t.names),{})}},Zt=class extends _n{render(u){return"{"+u._n+super.render(u)+"}"+u._n}},Uo=class extends _n{},Ho=(()=>{class e extends Zt{}return e.kind="else",e})(),jf=(()=>{class e extends Zt{constructor(t,i){super(i),this.condition=t}render(t){let i=`if(${this.condition})`+super.render(t);return this.else&&(i+="else "+this.else.render(t)),i}optimizeNodes(){super.optimizeNodes();let t=this.condition;if(t===!0)return this.nodes;let i=this.else;if(i){let n=i.optimizeNodes();i=this.else=Array.isArray(n)?new Ho(n):n}if(i)return t===!1?i instanceof e?i:i.nodes:this.nodes.length?this:new e(w3(t),i instanceof e?[i]:i.nodes);if(!(t===!1||!this.nodes.length))return this}optimizeNames(t,i){var n;if(this.else=(n=this.else)===null||n===void 0?void 0:n.optimizeNames(t,i),!!(super.optimizeNames(t,i)||this.else))return this.condition=Ei(this.condition,t,i),this}get names(){let t=super.names;return Vf(t,this.condition),this.else&&Vu(t,this.else.names),t}}return e.kind="if",e})(),Lf=(()=>{class e extends Zt{}return e.kind="for",e})(),Wo=class extends Lf{constructor(u){super(),this.iteration=u}render(u){return`for(${this.iteration})`+super.render(u)}optimizeNames(u,t){if(super.optimizeNames(u,t))return this.iteration=Ei(this.iteration,u,t),this}get names(){return Vu(super.names,this.iteration.names)}},Go=class extends Lf{constructor(u,t,i,n){super(),this.varKind=u,this.name=t,this.from=i,this.to=n}render(u){let t=u.es5?$t.varKinds.var:this.varKind,{name:i,from:n,to:f}=this;return`for(${t} ${i}=${n}; ${i}<${f}; ${i}++)`+super.render(u)}get names(){let u=Vf(super.names,this.from);return Vf(u,this.to)}},qf=class extends Lf{constructor(u,t,i,n){super(),this.loop=u,this.varKind=t,this.name=i,this.iterable=n}render(u){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(u)}optimizeNames(u,t){if(super.optimizeNames(u,t))return this.iterable=Ei(this.iterable,u,t),this}get names(){return Vu(super.names,this.iterable.names)}},y3=(()=>{class e extends Zt{constructor(t,i,n){super(),this.name=t,this.args=i,this.async=n}render(t){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(t)}}return e.kind="func",e})(),v3=(()=>{class e extends _n{render(t){return"return "+super.render(t)}}return e.kind="return",e})(),Ko=class extends Zt{render(u){let t="try"+super.render(u);return this.catch&&(t+=this.catch.render(u)),this.finally&&(t+=this.finally.render(u)),t}optimizeNodes(){var u,t;return super.optimizeNodes(),(u=this.catch)===null||u===void 0||u.optimizeNodes(),(t=this.finally)===null||t===void 0||t.optimizeNodes(),this}optimizeNames(u,t){var i,n;return super.optimizeNames(u,t),(i=this.catch)===null||i===void 0||i.optimizeNames(u,t),(n=this.finally)===null||n===void 0||n.optimizeNames(u,t),this}get names(){let u=super.names;return this.catch&&Vu(u,this.catch.names),this.finally&&Vu(u,this.finally.names),u}},B3=(()=>{class e extends Zt{constructor(t){super(),this.error=t}render(t){return`catch(${this.error})`+super.render(t)}}return e.kind="catch",e})(),x3=(()=>{class e extends Zt{render(t){return"finally"+super.render(t)}}return e.kind="finally",e})(),Jo=class{constructor(u,t={}){this._values={},this._blockStarts=[],this._constants={},this.opts=Ee(Q({},t),{_n:t.lines?`
|
|
1
|
+
import{a as St,b as MC}from"./chunk-UJ4WWACD.js";import{a as Vs}from"./chunk-5EOKPNKK.js";import{a as oi,b as ai}from"./chunk-ASGWDNPK.js";import{a as Hs}from"./chunk-CXFP5Z3Z.js";import{a as Gs}from"./chunk-O4J5XPML.js";import{a as Ws}from"./chunk-Z2MYOFRS.js";import{a as rn}from"./chunk-COKV5KB2.js";import{a as Ls,b as zs}from"./chunk-6RXHLHWG.js";import{a as no}from"./chunk-ZOFET4WQ.js";import{a as Us}from"./chunk-Q5OOH5FM.js";import{a as lf,b as df,c as cf,d as pf,e as mf,f as Ff,g as ni,m as Ce,n as Ue,o as fi}from"./chunk-AL4B7SPR.js";import{a as Ts,b as ei,c as ti,e as ot,f as Ps,h as Os,i as Ms,k as js,l as Du,m as Ns,o as ui,r as ii,s as Pu,t as Ou,x as qs,y as At,z as io}from"./chunk-CZTEBDJ7.js";import{a as ri}from"./chunk-7G4JRXOV.js";import{d as qt}from"./chunk-3M4FKD4C.js";import{a as Rs}from"./chunk-QZAASX2P.js";import{b as $e}from"./chunk-MVBTQKIK.js";import{h as pe,j as su,k as se}from"./chunk-PPT7YV25.js";import{e as $s}from"./chunk-A36UOKQM.js";import{a as ce,b as ge}from"./chunk-IJXZOFF2.js";import{$c as Tu,Ac as B,Bc as qe,D as gs,Da as _s,Fa as it,Fc as Ss,Ga as R,Ha as rf,Ib as G,Ja as of,Jb as g,Kb as wt,Lb as Xu,M as nf,Mb as Z,Nb as Bs,Ob as w,Qb as He,Rb as We,Sb as Ge,Tb as d,Ub as c,Vb as I,Wb as xs,Xb as ws,Z as uo,Zb as U,_c as gt,a as Q,aa as nn,ac as P,ad as nt,b as Ee,bc as C,cb as oe,dd as ks,e as F,fa as hs,fb as ys,g as Oe,ga as xt,gb as s,h as W,ha as ff,hd as sf,ic as ru,jb as af,jc as ou,k as ps,la as Es,lc as b,ma as x,mc as L,n as pt,nc as q,ob as $u,oc as Wt,pb as fu,pc as Is,q as ms,qc as Be,rc as xe,sb as J,sc as we,ta as fn,tb as Df,tc as As,ua as j,ub as Qu,uc as Ne,v as Fs,va as N,vb as vs,vc as It,w as ne,wc as au,x as Cs,xa as bs,xc as Gt,yb as k,yc as Yu,zc as _}from"./chunk-N5DHAEO2.js";var Js=F((aV,Ks)=>{function NC(){this.__data__=[],this.size=0}Ks.exports=NC});var Cf=F((DV,Zs)=>{function qC(e,u){return e===u||e!==e&&u!==u}Zs.exports=qC});var on=F((sV,Qs)=>{var VC=Cf();function RC(e,u){for(var t=e.length;t--;)if(VC(e[t][0],u))return t;return-1}Qs.exports=RC});var Ys=F((lV,Xs)=>{var LC=on(),zC=Array.prototype,UC=zC.splice;function HC(e){var u=this.__data__,t=LC(u,e);if(t<0)return!1;var i=u.length-1;return t==i?u.pop():UC.call(u,t,1),--this.size,!0}Xs.exports=HC});var t0=F((dV,e0)=>{var WC=on();function GC(e){var u=this.__data__,t=WC(u,e);return t<0?void 0:u[t][1]}e0.exports=GC});var i0=F((cV,u0)=>{var KC=on();function JC(e){return KC(this.__data__,e)>-1}u0.exports=JC});var f0=F((pV,n0)=>{var ZC=on();function QC(e,u){var t=this.__data__,i=ZC(t,e);return i<0?(++this.size,t.push([e,u])):t[i][1]=u,this}n0.exports=QC});var an=F((mV,r0)=>{var XC=Js(),YC=Ys(),e4=t0(),t4=i0(),u4=f0();function si(e){var u=-1,t=e==null?0:e.length;for(this.clear();++u<t;){var i=e[u];this.set(i[0],i[1])}}si.prototype.clear=XC;si.prototype.delete=YC;si.prototype.get=e4;si.prototype.has=t4;si.prototype.set=u4;r0.exports=si});var a0=F((FV,o0)=>{var i4=an();function n4(){this.__data__=new i4,this.size=0}o0.exports=n4});var s0=F((CV,D0)=>{function f4(e){var u=this.__data__,t=u.delete(e);return this.size=u.size,t}D0.exports=f4});var d0=F((gV,l0)=>{function r4(e){return this.__data__.get(e)}l0.exports=r4});var p0=F((hV,c0)=>{function o4(e){return this.__data__.has(e)}c0.exports=o4});var fo=F((EV,m0)=>{var a4=typeof global=="object"&&global&&global.Object===Object&&global;m0.exports=a4});var kt=F((bV,F0)=>{var D4=fo(),s4=typeof self=="object"&&self&&self.Object===Object&&self,l4=D4||s4||Function("return this")();F0.exports=l4});var li=F((_V,C0)=>{var d4=kt(),c4=d4.Symbol;C0.exports=c4});var b0=F((yV,E0)=>{var g0=li(),h0=Object.prototype,p4=h0.hasOwnProperty,m4=h0.toString,Dn=g0?g0.toStringTag:void 0;function F4(e){var u=p4.call(e,Dn),t=e[Dn];try{e[Dn]=void 0;var i=!0}catch{}var n=m4.call(e);return i&&(u?e[Dn]=t:delete e[Dn]),n}E0.exports=F4});var y0=F((vV,_0)=>{var C4=Object.prototype,g4=C4.toString;function h4(e){return g4.call(e)}_0.exports=h4});var Mu=F((BV,x0)=>{var v0=li(),E4=b0(),b4=y0(),_4="[object Null]",y4="[object Undefined]",B0=v0?v0.toStringTag:void 0;function v4(e){return e==null?e===void 0?y4:_4:B0&&B0 in Object(e)?E4(e):b4(e)}x0.exports=v4});var ju=F((xV,w0)=>{function B4(e){var u=typeof e;return e!=null&&(u=="object"||u=="function")}w0.exports=B4});var ro=F((wV,I0)=>{var x4=Mu(),w4=ju(),I4="[object AsyncFunction]",A4="[object Function]",S4="[object GeneratorFunction]",k4="[object Proxy]";function $4(e){if(!w4(e))return!1;var u=x4(e);return u==A4||u==S4||u==I4||u==k4}I0.exports=$4});var S0=F((IV,A0)=>{var T4=kt(),P4=T4["__core-js_shared__"];A0.exports=P4});var T0=F((AV,$0)=>{var oo=S0(),k0=function(){var e=/[^.]+$/.exec(oo&&oo.keys&&oo.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();function O4(e){return!!k0&&k0 in e}$0.exports=O4});var ao=F((SV,P0)=>{var M4=Function.prototype,j4=M4.toString;function N4(e){if(e!=null){try{return j4.call(e)}catch{}try{return e+""}catch{}}return""}P0.exports=N4});var M0=F((kV,O0)=>{var q4=ro(),V4=T0(),R4=ju(),L4=ao(),z4=/[\\^$.*+?()[\]{}|]/g,U4=/^\[object .+?Constructor\]$/,H4=Function.prototype,W4=Object.prototype,G4=H4.toString,K4=W4.hasOwnProperty,J4=RegExp("^"+G4.call(K4).replace(z4,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Z4(e){if(!R4(e)||V4(e))return!1;var u=q4(e)?J4:U4;return u.test(L4(e))}O0.exports=Z4});var N0=F(($V,j0)=>{function Q4(e,u){return e==null?void 0:e[u]}j0.exports=Q4});var lu=F((TV,q0)=>{var X4=M0(),Y4=N0();function e5(e,u){var t=Y4(e,u);return X4(t)?t:void 0}q0.exports=e5});var gf=F((PV,V0)=>{var t5=lu(),u5=kt(),i5=t5(u5,"Map");V0.exports=i5});var sn=F((OV,R0)=>{var n5=lu(),f5=n5(Object,"create");R0.exports=f5});var U0=F((MV,z0)=>{var L0=sn();function r5(){this.__data__=L0?L0(null):{},this.size=0}z0.exports=r5});var W0=F((jV,H0)=>{function o5(e){var u=this.has(e)&&delete this.__data__[e];return this.size-=u?1:0,u}H0.exports=o5});var K0=F((NV,G0)=>{var a5=sn(),D5="__lodash_hash_undefined__",s5=Object.prototype,l5=s5.hasOwnProperty;function d5(e){var u=this.__data__;if(a5){var t=u[e];return t===D5?void 0:t}return l5.call(u,e)?u[e]:void 0}G0.exports=d5});var Z0=F((qV,J0)=>{var c5=sn(),p5=Object.prototype,m5=p5.hasOwnProperty;function F5(e){var u=this.__data__;return c5?u[e]!==void 0:m5.call(u,e)}J0.exports=F5});var X0=F((VV,Q0)=>{var C5=sn(),g5="__lodash_hash_undefined__";function h5(e,u){var t=this.__data__;return this.size+=this.has(e)?0:1,t[e]=C5&&u===void 0?g5:u,this}Q0.exports=h5});var e1=F((RV,Y0)=>{var E5=U0(),b5=W0(),_5=K0(),y5=Z0(),v5=X0();function di(e){var u=-1,t=e==null?0:e.length;for(this.clear();++u<t;){var i=e[u];this.set(i[0],i[1])}}di.prototype.clear=E5;di.prototype.delete=b5;di.prototype.get=_5;di.prototype.has=y5;di.prototype.set=v5;Y0.exports=di});var i1=F((LV,u1)=>{var t1=e1(),B5=an(),x5=gf();function w5(){this.size=0,this.__data__={hash:new t1,map:new(x5||B5),string:new t1}}u1.exports=w5});var f1=F((zV,n1)=>{function I5(e){var u=typeof e;return u=="string"||u=="number"||u=="symbol"||u=="boolean"?e!=="__proto__":e===null}n1.exports=I5});var ln=F((UV,r1)=>{var A5=f1();function S5(e,u){var t=e.__data__;return A5(u)?t[typeof u=="string"?"string":"hash"]:t.map}r1.exports=S5});var a1=F((HV,o1)=>{var k5=ln();function $5(e){var u=k5(this,e).delete(e);return this.size-=u?1:0,u}o1.exports=$5});var s1=F((WV,D1)=>{var T5=ln();function P5(e){return T5(this,e).get(e)}D1.exports=P5});var d1=F((GV,l1)=>{var O5=ln();function M5(e){return O5(this,e).has(e)}l1.exports=M5});var p1=F((KV,c1)=>{var j5=ln();function N5(e,u){var t=j5(this,e),i=t.size;return t.set(e,u),this.size+=t.size==i?0:1,this}c1.exports=N5});var hf=F((JV,m1)=>{var q5=i1(),V5=a1(),R5=s1(),L5=d1(),z5=p1();function ci(e){var u=-1,t=e==null?0:e.length;for(this.clear();++u<t;){var i=e[u];this.set(i[0],i[1])}}ci.prototype.clear=q5;ci.prototype.delete=V5;ci.prototype.get=R5;ci.prototype.has=L5;ci.prototype.set=z5;m1.exports=ci});var C1=F((ZV,F1)=>{var U5=an(),H5=gf(),W5=hf(),G5=200;function K5(e,u){var t=this.__data__;if(t instanceof U5){var i=t.__data__;if(!H5||i.length<G5-1)return i.push([e,u]),this.size=++t.size,this;t=this.__data__=new W5(i)}return t.set(e,u),this.size=t.size,this}F1.exports=K5});var Ef=F((QV,g1)=>{var J5=an(),Z5=a0(),Q5=s0(),X5=d0(),Y5=p0(),eg=C1();function pi(e){var u=this.__data__=new J5(e);this.size=u.size}pi.prototype.clear=Z5;pi.prototype.delete=Q5;pi.prototype.get=X5;pi.prototype.has=Y5;pi.prototype.set=eg;g1.exports=pi});var E1=F((XV,h1)=>{function tg(e,u){for(var t=-1,i=e==null?0:e.length;++t<i&&u(e[t],t,e)!==!1;);return e}h1.exports=tg});var _1=F((YV,b1)=>{var ug=lu(),ig=function(){try{var e=ug(Object,"defineProperty");return e({},"",{}),e}catch{}}();b1.exports=ig});var Do=F((eR,v1)=>{var y1=_1();function ng(e,u,t){u=="__proto__"&&y1?y1(e,u,{configurable:!0,enumerable:!0,value:t,writable:!0}):e[u]=t}v1.exports=ng});var so=F((tR,B1)=>{var fg=Do(),rg=Cf(),og=Object.prototype,ag=og.hasOwnProperty;function Dg(e,u,t){var i=e[u];(!(ag.call(e,u)&&rg(i,t))||t===void 0&&!(u in e))&&fg(e,u,t)}B1.exports=Dg});var dn=F((uR,x1)=>{var sg=so(),lg=Do();function dg(e,u,t,i){var n=!t;t||(t={});for(var f=-1,r=u.length;++f<r;){var o=u[f],a=i?i(t[o],e[o],o,t,e):void 0;a===void 0&&(a=e[o]),n?lg(t,o,a):sg(t,o,a)}return t}x1.exports=dg});var I1=F((iR,w1)=>{function cg(e,u){for(var t=-1,i=Array(e);++t<e;)i[t]=u(t);return i}w1.exports=cg});var Kt=F((nR,A1)=>{function pg(e){return e!=null&&typeof e=="object"}A1.exports=pg});var k1=F((fR,S1)=>{var mg=Mu(),Fg=Kt(),Cg="[object Arguments]";function gg(e){return Fg(e)&&mg(e)==Cg}S1.exports=gg});var lo=F((rR,P1)=>{var $1=k1(),hg=Kt(),T1=Object.prototype,Eg=T1.hasOwnProperty,bg=T1.propertyIsEnumerable,_g=$1(function(){return arguments}())?$1:function(e){return hg(e)&&Eg.call(e,"callee")&&!bg.call(e,"callee")};P1.exports=_g});var mt=F((oR,O1)=>{var yg=Array.isArray;O1.exports=yg});var j1=F((aR,M1)=>{function vg(){return!1}M1.exports=vg});var bf=F((cn,mi)=>{var Bg=kt(),xg=j1(),V1=typeof cn=="object"&&cn&&!cn.nodeType&&cn,N1=V1&&typeof mi=="object"&&mi&&!mi.nodeType&&mi,wg=N1&&N1.exports===V1,q1=wg?Bg.Buffer:void 0,Ig=q1?q1.isBuffer:void 0,Ag=Ig||xg;mi.exports=Ag});var co=F((DR,R1)=>{var Sg=9007199254740991,kg=/^(?:0|[1-9]\d*)$/;function $g(e,u){var t=typeof e;return u=u==null?Sg:u,!!u&&(t=="number"||t!="symbol"&&kg.test(e))&&e>-1&&e%1==0&&e<u}R1.exports=$g});var _f=F((sR,L1)=>{var Tg=9007199254740991;function Pg(e){return typeof e=="number"&&e>-1&&e%1==0&&e<=Tg}L1.exports=Pg});var U1=F((lR,z1)=>{var Og=Mu(),Mg=_f(),jg=Kt(),Ng="[object Arguments]",qg="[object Array]",Vg="[object Boolean]",Rg="[object Date]",Lg="[object Error]",zg="[object Function]",Ug="[object Map]",Hg="[object Number]",Wg="[object Object]",Gg="[object RegExp]",Kg="[object Set]",Jg="[object String]",Zg="[object WeakMap]",Qg="[object ArrayBuffer]",Xg="[object DataView]",Yg="[object Float32Array]",eh="[object Float64Array]",th="[object Int8Array]",uh="[object Int16Array]",ih="[object Int32Array]",nh="[object Uint8Array]",fh="[object Uint8ClampedArray]",rh="[object Uint16Array]",oh="[object Uint32Array]",Ie={};Ie[Yg]=Ie[eh]=Ie[th]=Ie[uh]=Ie[ih]=Ie[nh]=Ie[fh]=Ie[rh]=Ie[oh]=!0;Ie[Ng]=Ie[qg]=Ie[Qg]=Ie[Vg]=Ie[Xg]=Ie[Rg]=Ie[Lg]=Ie[zg]=Ie[Ug]=Ie[Hg]=Ie[Wg]=Ie[Gg]=Ie[Kg]=Ie[Jg]=Ie[Zg]=!1;function ah(e){return jg(e)&&Mg(e.length)&&!!Ie[Og(e)]}z1.exports=ah});var yf=F((dR,H1)=>{function Dh(e){return function(u){return e(u)}}H1.exports=Dh});var vf=F((pn,Fi)=>{var sh=fo(),W1=typeof pn=="object"&&pn&&!pn.nodeType&&pn,mn=W1&&typeof Fi=="object"&&Fi&&!Fi.nodeType&&Fi,lh=mn&&mn.exports===W1,po=lh&&sh.process,dh=function(){try{var e=mn&&mn.require&&mn.require("util").types;return e||po&&po.binding&&po.binding("util")}catch{}}();Fi.exports=dh});var mo=F((cR,J1)=>{var ch=U1(),ph=yf(),G1=vf(),K1=G1&&G1.isTypedArray,mh=K1?ph(K1):ch;J1.exports=mh});var Fo=F((pR,Z1)=>{var Fh=I1(),Ch=lo(),gh=mt(),hh=bf(),Eh=co(),bh=mo(),_h=Object.prototype,yh=_h.hasOwnProperty;function vh(e,u){var t=gh(e),i=!t&&Ch(e),n=!t&&!i&&hh(e),f=!t&&!i&&!n&&bh(e),r=t||i||n||f,o=r?Fh(e.length,String):[],a=o.length;for(var D in e)(u||yh.call(e,D))&&!(r&&(D=="length"||n&&(D=="offset"||D=="parent")||f&&(D=="buffer"||D=="byteLength"||D=="byteOffset")||Eh(D,a)))&&o.push(D);return o}Z1.exports=vh});var Bf=F((mR,Q1)=>{var Bh=Object.prototype;function xh(e){var u=e&&e.constructor,t=typeof u=="function"&&u.prototype||Bh;return e===t}Q1.exports=xh});var Co=F((FR,X1)=>{function wh(e,u){return function(t){return e(u(t))}}X1.exports=wh});var el=F((CR,Y1)=>{var Ih=Co(),Ah=Ih(Object.keys,Object);Y1.exports=Ah});var ul=F((gR,tl)=>{var Sh=Bf(),kh=el(),$h=Object.prototype,Th=$h.hasOwnProperty;function Ph(e){if(!Sh(e))return kh(e);var u=[];for(var t in Object(e))Th.call(e,t)&&t!="constructor"&&u.push(t);return u}tl.exports=Ph});var Fn=F((hR,il)=>{var Oh=ro(),Mh=_f();function jh(e){return e!=null&&Mh(e.length)&&!Oh(e)}il.exports=jh});var Ci=F((ER,nl)=>{var Nh=Fo(),qh=ul(),Vh=Fn();function Rh(e){return Vh(e)?Nh(e):qh(e)}nl.exports=Rh});var rl=F((bR,fl)=>{var Lh=dn(),zh=Ci();function Uh(e,u){return e&&Lh(u,zh(u),e)}fl.exports=Uh});var al=F((_R,ol)=>{function Hh(e){var u=[];if(e!=null)for(var t in Object(e))u.push(t);return u}ol.exports=Hh});var sl=F((yR,Dl)=>{var Wh=ju(),Gh=Bf(),Kh=al(),Jh=Object.prototype,Zh=Jh.hasOwnProperty;function Qh(e){if(!Wh(e))return Kh(e);var u=Gh(e),t=[];for(var i in e)i=="constructor"&&(u||!Zh.call(e,i))||t.push(i);return t}Dl.exports=Qh});var xf=F((vR,ll)=>{var Xh=Fo(),Yh=sl(),e6=Fn();function t6(e){return e6(e)?Xh(e,!0):Yh(e)}ll.exports=t6});var cl=F((BR,dl)=>{var u6=dn(),i6=xf();function n6(e,u){return e&&u6(u,i6(u),e)}dl.exports=n6});var gl=F((Cn,gi)=>{var f6=kt(),Cl=typeof Cn=="object"&&Cn&&!Cn.nodeType&&Cn,pl=Cl&&typeof gi=="object"&&gi&&!gi.nodeType&&gi,r6=pl&&pl.exports===Cl,ml=r6?f6.Buffer:void 0,Fl=ml?ml.allocUnsafe:void 0;function o6(e,u){if(u)return e.slice();var t=e.length,i=Fl?Fl(t):new e.constructor(t);return e.copy(i),i}gi.exports=o6});var El=F((xR,hl)=>{function a6(e,u){var t=-1,i=e.length;for(u||(u=Array(i));++t<i;)u[t]=e[t];return u}hl.exports=a6});var go=F((wR,bl)=>{function D6(e,u){for(var t=-1,i=e==null?0:e.length,n=0,f=[];++t<i;){var r=e[t];u(r,t,e)&&(f[n++]=r)}return f}bl.exports=D6});var ho=F((IR,_l)=>{function s6(){return[]}_l.exports=s6});var wf=F((AR,vl)=>{var l6=go(),d6=ho(),c6=Object.prototype,p6=c6.propertyIsEnumerable,yl=Object.getOwnPropertySymbols,m6=yl?function(e){return e==null?[]:(e=Object(e),l6(yl(e),function(u){return p6.call(e,u)}))}:d6;vl.exports=m6});var xl=F((SR,Bl)=>{var F6=dn(),C6=wf();function g6(e,u){return F6(e,C6(e),u)}Bl.exports=g6});var Eo=F((kR,wl)=>{function h6(e,u){for(var t=-1,i=u.length,n=e.length;++t<i;)e[n+t]=u[t];return e}wl.exports=h6});var If=F(($R,Il)=>{var E6=Co(),b6=E6(Object.getPrototypeOf,Object);Il.exports=b6});var bo=F((TR,Al)=>{var _6=Eo(),y6=If(),v6=wf(),B6=ho(),x6=Object.getOwnPropertySymbols,w6=x6?function(e){for(var u=[];e;)_6(u,v6(e)),e=y6(e);return u}:B6;Al.exports=w6});var kl=F((PR,Sl)=>{var I6=dn(),A6=bo();function S6(e,u){return I6(e,A6(e),u)}Sl.exports=S6});var _o=F((OR,$l)=>{var k6=Eo(),$6=mt();function T6(e,u,t){var i=u(e);return $6(e)?i:k6(i,t(e))}$l.exports=T6});var yo=F((MR,Tl)=>{var P6=_o(),O6=wf(),M6=Ci();function j6(e){return P6(e,M6,O6)}Tl.exports=j6});var Ol=F((jR,Pl)=>{var N6=_o(),q6=bo(),V6=xf();function R6(e){return N6(e,V6,q6)}Pl.exports=R6});var jl=F((NR,Ml)=>{var L6=lu(),z6=kt(),U6=L6(z6,"DataView");Ml.exports=U6});var ql=F((qR,Nl)=>{var H6=lu(),W6=kt(),G6=H6(W6,"Promise");Nl.exports=G6});var Rl=F((VR,Vl)=>{var K6=lu(),J6=kt(),Z6=K6(J6,"Set");Vl.exports=Z6});var zl=F((RR,Ll)=>{var Q6=lu(),X6=kt(),Y6=Q6(X6,"WeakMap");Ll.exports=Y6});var gn=F((LR,Zl)=>{var vo=jl(),Bo=gf(),xo=ql(),wo=Rl(),Io=zl(),Jl=Mu(),hi=ao(),Ul="[object Map]",eE="[object Object]",Hl="[object Promise]",Wl="[object Set]",Gl="[object WeakMap]",Kl="[object DataView]",tE=hi(vo),uE=hi(Bo),iE=hi(xo),nE=hi(wo),fE=hi(Io),Nu=Jl;(vo&&Nu(new vo(new ArrayBuffer(1)))!=Kl||Bo&&Nu(new Bo)!=Ul||xo&&Nu(xo.resolve())!=Hl||wo&&Nu(new wo)!=Wl||Io&&Nu(new Io)!=Gl)&&(Nu=function(e){var u=Jl(e),t=u==eE?e.constructor:void 0,i=t?hi(t):"";if(i)switch(i){case tE:return Kl;case uE:return Ul;case iE:return Hl;case nE:return Wl;case fE:return Gl}return u});Zl.exports=Nu});var Xl=F((zR,Ql)=>{var rE=Object.prototype,oE=rE.hasOwnProperty;function aE(e){var u=e.length,t=new e.constructor(u);return u&&typeof e[0]=="string"&&oE.call(e,"index")&&(t.index=e.index,t.input=e.input),t}Ql.exports=aE});var Ao=F((UR,Yl)=>{var DE=kt(),sE=DE.Uint8Array;Yl.exports=sE});var Af=F((HR,td)=>{var ed=Ao();function lE(e){var u=new e.constructor(e.byteLength);return new ed(u).set(new ed(e)),u}td.exports=lE});var id=F((WR,ud)=>{var dE=Af();function cE(e,u){var t=u?dE(e.buffer):e.buffer;return new e.constructor(t,e.byteOffset,e.byteLength)}ud.exports=cE});var fd=F((GR,nd)=>{var pE=/\w*$/;function mE(e){var u=new e.constructor(e.source,pE.exec(e));return u.lastIndex=e.lastIndex,u}nd.exports=mE});var sd=F((KR,Dd)=>{var rd=li(),od=rd?rd.prototype:void 0,ad=od?od.valueOf:void 0;function FE(e){return ad?Object(ad.call(e)):{}}Dd.exports=FE});var dd=F((JR,ld)=>{var CE=Af();function gE(e,u){var t=u?CE(e.buffer):e.buffer;return new e.constructor(t,e.byteOffset,e.length)}ld.exports=gE});var pd=F((ZR,cd)=>{var hE=Af(),EE=id(),bE=fd(),_E=sd(),yE=dd(),vE="[object Boolean]",BE="[object Date]",xE="[object Map]",wE="[object Number]",IE="[object RegExp]",AE="[object Set]",SE="[object String]",kE="[object Symbol]",$E="[object ArrayBuffer]",TE="[object DataView]",PE="[object Float32Array]",OE="[object Float64Array]",ME="[object Int8Array]",jE="[object Int16Array]",NE="[object Int32Array]",qE="[object Uint8Array]",VE="[object Uint8ClampedArray]",RE="[object Uint16Array]",LE="[object Uint32Array]";function zE(e,u,t){var i=e.constructor;switch(u){case $E:return hE(e);case vE:case BE:return new i(+e);case TE:return EE(e,t);case PE:case OE:case ME:case jE:case NE:case qE:case VE:case RE:case LE:return yE(e,t);case xE:return new i;case wE:case SE:return new i(e);case IE:return bE(e);case AE:return new i;case kE:return _E(e)}}cd.exports=zE});var Cd=F((QR,Fd)=>{var UE=ju(),md=Object.create,HE=function(){function e(){}return function(u){if(!UE(u))return{};if(md)return md(u);e.prototype=u;var t=new e;return e.prototype=void 0,t}}();Fd.exports=HE});var hd=F((XR,gd)=>{var WE=Cd(),GE=If(),KE=Bf();function JE(e){return typeof e.constructor=="function"&&!KE(e)?WE(GE(e)):{}}gd.exports=JE});var bd=F((YR,Ed)=>{var ZE=gn(),QE=Kt(),XE="[object Map]";function YE(e){return QE(e)&&ZE(e)==XE}Ed.exports=YE});var Bd=F((eL,vd)=>{var eb=bd(),tb=yf(),_d=vf(),yd=_d&&_d.isMap,ub=yd?tb(yd):eb;vd.exports=ub});var wd=F((tL,xd)=>{var ib=gn(),nb=Kt(),fb="[object Set]";function rb(e){return nb(e)&&ib(e)==fb}xd.exports=rb});var kd=F((uL,Sd)=>{var ob=wd(),ab=yf(),Id=vf(),Ad=Id&&Id.isSet,Db=Ad?ab(Ad):ob;Sd.exports=Db});var Md=F((iL,Od)=>{var sb=Ef(),lb=E1(),db=so(),cb=rl(),pb=cl(),mb=gl(),Fb=El(),Cb=xl(),gb=kl(),hb=yo(),Eb=Ol(),bb=gn(),_b=Xl(),yb=pd(),vb=hd(),Bb=mt(),xb=bf(),wb=Bd(),Ib=ju(),Ab=kd(),Sb=Ci(),kb=xf(),$b=1,Tb=2,Pb=4,$d="[object Arguments]",Ob="[object Array]",Mb="[object Boolean]",jb="[object Date]",Nb="[object Error]",Td="[object Function]",qb="[object GeneratorFunction]",Vb="[object Map]",Rb="[object Number]",Pd="[object Object]",Lb="[object RegExp]",zb="[object Set]",Ub="[object String]",Hb="[object Symbol]",Wb="[object WeakMap]",Gb="[object ArrayBuffer]",Kb="[object DataView]",Jb="[object Float32Array]",Zb="[object Float64Array]",Qb="[object Int8Array]",Xb="[object Int16Array]",Yb="[object Int32Array]",e_="[object Uint8Array]",t_="[object Uint8ClampedArray]",u_="[object Uint16Array]",i_="[object Uint32Array]",ye={};ye[$d]=ye[Ob]=ye[Gb]=ye[Kb]=ye[Mb]=ye[jb]=ye[Jb]=ye[Zb]=ye[Qb]=ye[Xb]=ye[Yb]=ye[Vb]=ye[Rb]=ye[Pd]=ye[Lb]=ye[zb]=ye[Ub]=ye[Hb]=ye[e_]=ye[t_]=ye[u_]=ye[i_]=!0;ye[Nb]=ye[Td]=ye[Wb]=!1;function Sf(e,u,t,i,n,f){var r,o=u&$b,a=u&Tb,D=u&Pb;if(t&&(r=n?t(e,i,n,f):t(e)),r!==void 0)return r;if(!Ib(e))return e;var l=Bb(e);if(l){if(r=_b(e),!o)return Fb(e,r)}else{var p=bb(e),m=p==Td||p==qb;if(xb(e))return mb(e,o);if(p==Pd||p==$d||m&&!n){if(r=a||m?{}:vb(e),!o)return a?gb(e,pb(r,e)):Cb(e,cb(r,e))}else{if(!ye[p])return n?e:{};r=yb(e,p,o)}}f||(f=new sb);var E=f.get(e);if(E)return E;f.set(e,r),Ab(e)?e.forEach(function(v){r.add(Sf(v,u,t,v,e,f))}):wb(e)&&e.forEach(function(v,S){r.set(S,Sf(v,u,t,S,e,f))});var h=D?a?Eb:hb:a?kb:Sb,y=l?void 0:h(e);return lb(y||e,function(v,S){y&&(S=v,v=e[S]),db(r,S,Sf(v,u,t,S,e,f))}),r}Od.exports=Sf});var Nd=F((nL,jd)=>{var n_=Md(),f_=1,r_=4;function o_(e){return n_(e,f_|r_)}jd.exports=o_});var Vd=F((fL,qd)=>{var a_="__lodash_hash_undefined__";function D_(e){return this.__data__.set(e,a_),this}qd.exports=D_});var Ld=F((rL,Rd)=>{function s_(e){return this.__data__.has(e)}Rd.exports=s_});var Ud=F((oL,zd)=>{var l_=hf(),d_=Vd(),c_=Ld();function kf(e){var u=-1,t=e==null?0:e.length;for(this.__data__=new l_;++u<t;)this.add(e[u])}kf.prototype.add=kf.prototype.push=d_;kf.prototype.has=c_;zd.exports=kf});var Wd=F((aL,Hd)=>{function p_(e,u){for(var t=-1,i=e==null?0:e.length;++t<i;)if(u(e[t],t,e))return!0;return!1}Hd.exports=p_});var Kd=F((DL,Gd)=>{function m_(e,u){return e.has(u)}Gd.exports=m_});var So=F((sL,Jd)=>{var F_=Ud(),C_=Wd(),g_=Kd(),h_=1,E_=2;function b_(e,u,t,i,n,f){var r=t&h_,o=e.length,a=u.length;if(o!=a&&!(r&&a>o))return!1;var D=f.get(e),l=f.get(u);if(D&&l)return D==u&&l==e;var p=-1,m=!0,E=t&E_?new F_:void 0;for(f.set(e,u),f.set(u,e);++p<o;){var h=e[p],y=u[p];if(i)var v=r?i(y,h,p,u,e,f):i(h,y,p,e,u,f);if(v!==void 0){if(v)continue;m=!1;break}if(E){if(!C_(u,function(S,O){if(!g_(E,O)&&(h===S||n(h,S,t,i,f)))return E.push(O)})){m=!1;break}}else if(!(h===y||n(h,y,t,i,f))){m=!1;break}}return f.delete(e),f.delete(u),m}Jd.exports=b_});var Qd=F((lL,Zd)=>{function __(e){var u=-1,t=Array(e.size);return e.forEach(function(i,n){t[++u]=[n,i]}),t}Zd.exports=__});var Yd=F((dL,Xd)=>{function y_(e){var u=-1,t=Array(e.size);return e.forEach(function(i){t[++u]=i}),t}Xd.exports=y_});var n3=F((cL,i3)=>{var e3=li(),t3=Ao(),v_=Cf(),B_=So(),x_=Qd(),w_=Yd(),I_=1,A_=2,S_="[object Boolean]",k_="[object Date]",$_="[object Error]",T_="[object Map]",P_="[object Number]",O_="[object RegExp]",M_="[object Set]",j_="[object String]",N_="[object Symbol]",q_="[object ArrayBuffer]",V_="[object DataView]",u3=e3?e3.prototype:void 0,ko=u3?u3.valueOf:void 0;function R_(e,u,t,i,n,f,r){switch(t){case V_:if(e.byteLength!=u.byteLength||e.byteOffset!=u.byteOffset)return!1;e=e.buffer,u=u.buffer;case q_:return!(e.byteLength!=u.byteLength||!f(new t3(e),new t3(u)));case S_:case k_:case P_:return v_(+e,+u);case $_:return e.name==u.name&&e.message==u.message;case O_:case j_:return e==u+"";case T_:var o=x_;case M_:var a=i&I_;if(o||(o=w_),e.size!=u.size&&!a)return!1;var D=r.get(e);if(D)return D==u;i|=A_,r.set(e,u);var l=B_(o(e),o(u),i,n,f,r);return r.delete(e),l;case N_:if(ko)return ko.call(e)==ko.call(u)}return!1}i3.exports=R_});var o3=F((pL,r3)=>{var f3=yo(),L_=1,z_=Object.prototype,U_=z_.hasOwnProperty;function H_(e,u,t,i,n,f){var r=t&L_,o=f3(e),a=o.length,D=f3(u),l=D.length;if(a!=l&&!r)return!1;for(var p=a;p--;){var m=o[p];if(!(r?m in u:U_.call(u,m)))return!1}var E=f.get(e),h=f.get(u);if(E&&h)return E==u&&h==e;var y=!0;f.set(e,u),f.set(u,e);for(var v=r;++p<a;){m=o[p];var S=e[m],O=u[m];if(i)var z=r?i(O,S,m,u,e,f):i(S,O,m,e,u,f);if(!(z===void 0?S===O||n(S,O,t,i,f):z)){y=!1;break}v||(v=m=="constructor")}if(y&&!v){var H=e.constructor,M=u.constructor;H!=M&&"constructor"in e&&"constructor"in u&&!(typeof H=="function"&&H instanceof H&&typeof M=="function"&&M instanceof M)&&(y=!1)}return f.delete(e),f.delete(u),y}r3.exports=H_});var m3=F((mL,p3)=>{var $o=Ef(),W_=So(),G_=n3(),K_=o3(),a3=gn(),D3=mt(),s3=bf(),J_=mo(),Z_=1,l3="[object Arguments]",d3="[object Array]",$f="[object Object]",Q_=Object.prototype,c3=Q_.hasOwnProperty;function X_(e,u,t,i,n,f){var r=D3(e),o=D3(u),a=r?d3:a3(e),D=o?d3:a3(u);a=a==l3?$f:a,D=D==l3?$f:D;var l=a==$f,p=D==$f,m=a==D;if(m&&s3(e)){if(!s3(u))return!1;r=!0,l=!1}if(m&&!l)return f||(f=new $o),r||J_(e)?W_(e,u,t,i,n,f):G_(e,u,a,t,i,n,f);if(!(t&Z_)){var E=l&&c3.call(e,"__wrapped__"),h=p&&c3.call(u,"__wrapped__");if(E||h){var y=E?e.value():e,v=h?u.value():u;return f||(f=new $o),n(y,v,t,i,f)}}return m?(f||(f=new $o),K_(e,u,t,i,n,f)):!1}p3.exports=X_});var Tf=F((FL,g3)=>{var Y_=m3(),F3=Kt();function C3(e,u,t,i,n){return e===u?!0:e==null||u==null||!F3(e)&&!F3(u)?e!==e&&u!==u:Y_(e,u,t,i,C3,n)}g3.exports=C3});var E3=F((CL,h3)=>{var e9=Tf();function t9(e,u){return e9(e,u)}h3.exports=t9});var bn=F(de=>{"use strict";Object.defineProperty(de,"__esModule",{value:!0});de.regexpCode=de.getEsmExportName=de.getProperty=de.safeStringify=de.stringify=de.strConcat=de.addCodeArg=de.str=de._=de.nil=de._Code=de.Name=de.IDENTIFIER=de._CodeOrName=void 0;var hn=class{};de._CodeOrName=hn;de.IDENTIFIER=/^[a-z$_][a-z$_0-9]*$/i;var qu=class extends hn{constructor(u){if(super(),!de.IDENTIFIER.test(u))throw new Error("CodeGen: name must be a valid identifier");this.str=u}toString(){return this.str}emptyStr(){return!1}get names(){return{[this.str]:1}}};de.Name=qu;var ht=class extends hn{constructor(u){super(),this._items=typeof u=="string"?[u]:u}toString(){return this.str}emptyStr(){if(this._items.length>1)return!1;let u=this._items[0];return u===""||u==='""'}get str(){var u;return(u=this._str)!==null&&u!==void 0?u:this._str=this._items.reduce((t,i)=>`${t}${i}`,"")}get names(){var u;return(u=this._names)!==null&&u!==void 0?u:this._names=this._items.reduce((t,i)=>(i instanceof qu&&(t[i.str]=(t[i.str]||0)+1),t),{})}};de._Code=ht;de.nil=new ht("");function b3(e,...u){let t=[e[0]],i=0;for(;i<u.length;)Po(t,u[i]),t.push(e[++i]);return new ht(t)}de._=b3;var To=new ht("+");function _3(e,...u){let t=[En(e[0])],i=0;for(;i<u.length;)t.push(To),Po(t,u[i]),t.push(To,En(e[++i]));return u9(t),new ht(t)}de.str=_3;function Po(e,u){u instanceof ht?e.push(...u._items):u instanceof qu?e.push(u):e.push(f9(u))}de.addCodeArg=Po;function u9(e){let u=1;for(;u<e.length-1;){if(e[u]===To){let t=i9(e[u-1],e[u+1]);if(t!==void 0){e.splice(u-1,3,t);continue}e[u++]="+"}u++}}function i9(e,u){if(u==='""')return e;if(e==='""')return u;if(typeof e=="string")return u instanceof qu||e[e.length-1]!=='"'?void 0:typeof u!="string"?`${e.slice(0,-1)}${u}"`:u[0]==='"'?e.slice(0,-1)+u.slice(1):void 0;if(typeof u=="string"&&u[0]==='"'&&!(e instanceof qu))return`"${e}${u.slice(1)}`}function n9(e,u){return u.emptyStr()?e:e.emptyStr()?u:_3`${e}${u}`}de.strConcat=n9;function f9(e){return typeof e=="number"||typeof e=="boolean"||e===null?e:En(Array.isArray(e)?e.join(","):e)}function r9(e){return new ht(En(e))}de.stringify=r9;function En(e){return JSON.stringify(e).replace(/\u2028/g,"\\u2028").replace(/\u2029/g,"\\u2029")}de.safeStringify=En;function o9(e){return typeof e=="string"&&de.IDENTIFIER.test(e)?new ht(`.${e}`):b3`[${e}]`}de.getProperty=o9;function a9(e){if(typeof e=="string"&&de.IDENTIFIER.test(e))return new ht(`${e}`);throw new Error(`CodeGen: invalid export name: ${e}, use explicit $id name mapping`)}de.getEsmExportName=a9;function D9(e){return new ht(e.toString())}de.regexpCode=D9});var jo=F(Dt=>{"use strict";Object.defineProperty(Dt,"__esModule",{value:!0});Dt.ValueScope=Dt.ValueScopeName=Dt.Scope=Dt.varKinds=Dt.UsedValueState=void 0;var at=bn(),Oo=class extends Error{constructor(u){super(`CodeGen: "code" for ${u} not defined`),this.value=u.value}},Pf=function(e){return e[e.Started=0]="Started",e[e.Completed=1]="Completed",e}(Pf||(Dt.UsedValueState=Pf={}));Dt.varKinds={const:new at.Name("const"),let:new at.Name("let"),var:new at.Name("var")};var Of=class{constructor({prefixes:u,parent:t}={}){this._names={},this._prefixes=u,this._parent=t}toName(u){return u instanceof at.Name?u:this.name(u)}name(u){return new at.Name(this._newName(u))}_newName(u){let t=this._names[u]||this._nameGroup(u);return`${u}${t.index++}`}_nameGroup(u){var t,i;if(!((i=(t=this._parent)===null||t===void 0?void 0:t._prefixes)===null||i===void 0)&&i.has(u)||this._prefixes&&!this._prefixes.has(u))throw new Error(`CodeGen: prefix "${u}" is not allowed in this scope`);return this._names[u]={prefix:u,index:0}}};Dt.Scope=Of;var Mf=class extends at.Name{constructor(u,t){super(t),this.prefix=u}setValue(u,{property:t,itemIndex:i}){this.value=u,this.scopePath=(0,at._)`.${new at.Name(t)}[${i}]`}};Dt.ValueScopeName=Mf;var s9=(0,at._)`\n`,Mo=class extends Of{constructor(u){super(u),this._values={},this._scope=u.scope,this.opts=Ee(Q({},u),{_n:u.lines?s9:at.nil})}get(){return this._scope}name(u){return new Mf(u,this._newName(u))}value(u,t){var i;if(t.ref===void 0)throw new Error("CodeGen: ref must be passed in value");let n=this.toName(u),{prefix:f}=n,r=(i=t.key)!==null&&i!==void 0?i:t.ref,o=this._values[f];if(o){let l=o.get(r);if(l)return l}else o=this._values[f]=new Map;o.set(r,n);let a=this._scope[f]||(this._scope[f]=[]),D=a.length;return a[D]=t.ref,n.setValue(t,{property:f,itemIndex:D}),n}getValue(u,t){let i=this._values[u];if(i)return i.get(t)}scopeRefs(u,t=this._values){return this._reduceValues(t,i=>{if(i.scopePath===void 0)throw new Error(`CodeGen: name "${i}" has no value`);return(0,at._)`${u}${i.scopePath}`})}scopeCode(u=this._values,t,i){return this._reduceValues(u,n=>{if(n.value===void 0)throw new Error(`CodeGen: name "${n}" has no value`);return n.value.code},t,i)}_reduceValues(u,t,i={},n){let f=at.nil;for(let r in u){let o=u[r];if(!o)continue;let a=i[r]=i[r]||new Map;o.forEach(D=>{if(a.has(D))return;a.set(D,Pf.Started);let l=t(D);if(l){let p=this.opts.es5?Dt.varKinds.var:Dt.varKinds.const;f=(0,at._)`${f}${p} ${D} = ${l};${this.opts._n}`}else if(l=n==null?void 0:n(D))f=(0,at._)`${f}${l}${this.opts._n}`;else throw new Oo(D);a.set(D,Pf.Completed)})}return f}};Dt.ValueScope=Mo});var te=F(ie=>{"use strict";Object.defineProperty(ie,"__esModule",{value:!0});ie.or=ie.and=ie.not=ie.CodeGen=ie.operators=ie.varKinds=ie.ValueScopeName=ie.ValueScope=ie.Scope=ie.Name=ie.regexpCode=ie.stringify=ie.getProperty=ie.nil=ie.strConcat=ie.str=ie._=void 0;var De=bn(),$t=jo(),du=bn();Object.defineProperty(ie,"_",{enumerable:!0,get:function(){return du._}});Object.defineProperty(ie,"str",{enumerable:!0,get:function(){return du.str}});Object.defineProperty(ie,"strConcat",{enumerable:!0,get:function(){return du.strConcat}});Object.defineProperty(ie,"nil",{enumerable:!0,get:function(){return du.nil}});Object.defineProperty(ie,"getProperty",{enumerable:!0,get:function(){return du.getProperty}});Object.defineProperty(ie,"stringify",{enumerable:!0,get:function(){return du.stringify}});Object.defineProperty(ie,"regexpCode",{enumerable:!0,get:function(){return du.regexpCode}});Object.defineProperty(ie,"Name",{enumerable:!0,get:function(){return du.Name}});var Rf=jo();Object.defineProperty(ie,"Scope",{enumerable:!0,get:function(){return Rf.Scope}});Object.defineProperty(ie,"ValueScope",{enumerable:!0,get:function(){return Rf.ValueScope}});Object.defineProperty(ie,"ValueScopeName",{enumerable:!0,get:function(){return Rf.ValueScopeName}});Object.defineProperty(ie,"varKinds",{enumerable:!0,get:function(){return Rf.varKinds}});ie.operators={GT:new De._Code(">"),GTE:new De._Code(">="),LT:new De._Code("<"),LTE:new De._Code("<="),EQ:new De._Code("==="),NEQ:new De._Code("!=="),NOT:new De._Code("!"),OR:new De._Code("||"),AND:new De._Code("&&"),ADD:new De._Code("+")};var Jt=class{optimizeNodes(){return this}optimizeNames(u,t){return this}},No=class extends Jt{constructor(u,t,i){super(),this.varKind=u,this.name=t,this.rhs=i}render({es5:u,_n:t}){let i=u?$t.varKinds.var:this.varKind,n=this.rhs===void 0?"":` = ${this.rhs}`;return`${i} ${this.name}${n};`+t}optimizeNames(u,t){if(u[this.name.str])return this.rhs&&(this.rhs=Ei(this.rhs,u,t)),this}get names(){return this.rhs instanceof De._CodeOrName?this.rhs.names:{}}},Nf=class extends Jt{constructor(u,t,i){super(),this.lhs=u,this.rhs=t,this.sideEffects=i}render({_n:u}){return`${this.lhs} = ${this.rhs};`+u}optimizeNames(u,t){if(!(this.lhs instanceof De.Name&&!u[this.lhs.str]&&!this.sideEffects))return this.rhs=Ei(this.rhs,u,t),this}get names(){let u=this.lhs instanceof De.Name?{}:Q({},this.lhs.names);return Vf(u,this.rhs)}},qo=class extends Nf{constructor(u,t,i,n){super(u,i,n),this.op=t}render({_n:u}){return`${this.lhs} ${this.op}= ${this.rhs};`+u}},Vo=class extends Jt{constructor(u){super(),this.label=u,this.names={}}render({_n:u}){return`${this.label}:`+u}},Ro=class extends Jt{constructor(u){super(),this.label=u,this.names={}}render({_n:u}){return`break${this.label?` ${this.label}`:""};`+u}},Lo=class extends Jt{constructor(u){super(),this.error=u}render({_n:u}){return`throw ${this.error};`+u}get names(){return this.error.names}},zo=class extends Jt{constructor(u){super(),this.code=u}render({_n:u}){return`${this.code};`+u}optimizeNodes(){return`${this.code}`?this:void 0}optimizeNames(u,t){return this.code=Ei(this.code,u,t),this}get names(){return this.code instanceof De._CodeOrName?this.code.names:{}}},_n=class extends Jt{constructor(u=[]){super(),this.nodes=u}render(u){return this.nodes.reduce((t,i)=>t+i.render(u),"")}optimizeNodes(){let{nodes:u}=this,t=u.length;for(;t--;){let i=u[t].optimizeNodes();Array.isArray(i)?u.splice(t,1,...i):i?u[t]=i:u.splice(t,1)}return u.length>0?this:void 0}optimizeNames(u,t){let{nodes:i}=this,n=i.length;for(;n--;){let f=i[n];f.optimizeNames(u,t)||(l9(u,f.names),i.splice(n,1))}return i.length>0?this:void 0}get names(){return this.nodes.reduce((u,t)=>Vu(u,t.names),{})}},Zt=class extends _n{render(u){return"{"+u._n+super.render(u)+"}"+u._n}},Uo=class extends _n{},Ho=(()=>{class e extends Zt{}return e.kind="else",e})(),jf=(()=>{class e extends Zt{constructor(t,i){super(i),this.condition=t}render(t){let i=`if(${this.condition})`+super.render(t);return this.else&&(i+="else "+this.else.render(t)),i}optimizeNodes(){super.optimizeNodes();let t=this.condition;if(t===!0)return this.nodes;let i=this.else;if(i){let n=i.optimizeNodes();i=this.else=Array.isArray(n)?new Ho(n):n}if(i)return t===!1?i instanceof e?i:i.nodes:this.nodes.length?this:new e(w3(t),i instanceof e?[i]:i.nodes);if(!(t===!1||!this.nodes.length))return this}optimizeNames(t,i){var n;if(this.else=(n=this.else)===null||n===void 0?void 0:n.optimizeNames(t,i),!!(super.optimizeNames(t,i)||this.else))return this.condition=Ei(this.condition,t,i),this}get names(){let t=super.names;return Vf(t,this.condition),this.else&&Vu(t,this.else.names),t}}return e.kind="if",e})(),Lf=(()=>{class e extends Zt{}return e.kind="for",e})(),Wo=class extends Lf{constructor(u){super(),this.iteration=u}render(u){return`for(${this.iteration})`+super.render(u)}optimizeNames(u,t){if(super.optimizeNames(u,t))return this.iteration=Ei(this.iteration,u,t),this}get names(){return Vu(super.names,this.iteration.names)}},Go=class extends Lf{constructor(u,t,i,n){super(),this.varKind=u,this.name=t,this.from=i,this.to=n}render(u){let t=u.es5?$t.varKinds.var:this.varKind,{name:i,from:n,to:f}=this;return`for(${t} ${i}=${n}; ${i}<${f}; ${i}++)`+super.render(u)}get names(){let u=Vf(super.names,this.from);return Vf(u,this.to)}},qf=class extends Lf{constructor(u,t,i,n){super(),this.loop=u,this.varKind=t,this.name=i,this.iterable=n}render(u){return`for(${this.varKind} ${this.name} ${this.loop} ${this.iterable})`+super.render(u)}optimizeNames(u,t){if(super.optimizeNames(u,t))return this.iterable=Ei(this.iterable,u,t),this}get names(){return Vu(super.names,this.iterable.names)}},y3=(()=>{class e extends Zt{constructor(t,i,n){super(),this.name=t,this.args=i,this.async=n}render(t){return`${this.async?"async ":""}function ${this.name}(${this.args})`+super.render(t)}}return e.kind="func",e})(),v3=(()=>{class e extends _n{render(t){return"return "+super.render(t)}}return e.kind="return",e})(),Ko=class extends Zt{render(u){let t="try"+super.render(u);return this.catch&&(t+=this.catch.render(u)),this.finally&&(t+=this.finally.render(u)),t}optimizeNodes(){var u,t;return super.optimizeNodes(),(u=this.catch)===null||u===void 0||u.optimizeNodes(),(t=this.finally)===null||t===void 0||t.optimizeNodes(),this}optimizeNames(u,t){var i,n;return super.optimizeNames(u,t),(i=this.catch)===null||i===void 0||i.optimizeNames(u,t),(n=this.finally)===null||n===void 0||n.optimizeNames(u,t),this}get names(){let u=super.names;return this.catch&&Vu(u,this.catch.names),this.finally&&Vu(u,this.finally.names),u}},B3=(()=>{class e extends Zt{constructor(t){super(),this.error=t}render(t){return`catch(${this.error})`+super.render(t)}}return e.kind="catch",e})(),x3=(()=>{class e extends Zt{render(t){return"finally"+super.render(t)}}return e.kind="finally",e})(),Jo=class{constructor(u,t={}){this._values={},this._blockStarts=[],this._constants={},this.opts=Ee(Q({},t),{_n:t.lines?`
|
|
2
2
|
`:""}),this._extScope=u,this._scope=new $t.Scope({parent:u}),this._nodes=[new Uo]}toString(){return this._root.render(this.opts)}name(u){return this._scope.name(u)}scopeName(u){return this._extScope.name(u)}scopeValue(u,t){let i=this._extScope.value(u,t);return(this._values[i.prefix]||(this._values[i.prefix]=new Set)).add(i),i}getScopeValue(u,t){return this._extScope.getValue(u,t)}scopeRefs(u){return this._extScope.scopeRefs(u,this._values)}scopeCode(){return this._extScope.scopeCode(this._values)}_def(u,t,i,n){let f=this._scope.toName(t);return i!==void 0&&n&&(this._constants[f.str]=i),this._leafNode(new No(u,f,i)),f}const(u,t,i){return this._def($t.varKinds.const,u,t,i)}let(u,t,i){return this._def($t.varKinds.let,u,t,i)}var(u,t,i){return this._def($t.varKinds.var,u,t,i)}assign(u,t,i){return this._leafNode(new Nf(u,t,i))}add(u,t){return this._leafNode(new qo(u,ie.operators.ADD,t))}code(u){return typeof u=="function"?u():u!==De.nil&&this._leafNode(new zo(u)),this}object(...u){let t=["{"];for(let[i,n]of u)t.length>1&&t.push(","),t.push(i),(i!==n||this.opts.es5)&&(t.push(":"),(0,De.addCodeArg)(t,n));return t.push("}"),new De._Code(t)}if(u,t,i){if(this._blockNode(new jf(u)),t&&i)this.code(t).else().code(i).endIf();else if(t)this.code(t).endIf();else if(i)throw new Error('CodeGen: "else" body without "then" body');return this}elseIf(u){return this._elseNode(new jf(u))}else(){return this._elseNode(new Ho)}endIf(){return this._endBlockNode(jf,Ho)}_for(u,t){return this._blockNode(u),t&&this.code(t).endFor(),this}for(u,t){return this._for(new Wo(u),t)}forRange(u,t,i,n,f=this.opts.es5?$t.varKinds.var:$t.varKinds.let){let r=this._scope.toName(u);return this._for(new Go(f,r,t,i),()=>n(r))}forOf(u,t,i,n=$t.varKinds.const){let f=this._scope.toName(u);if(this.opts.es5){let r=t instanceof De.Name?t:this.var("_arr",t);return this.forRange("_i",0,(0,De._)`${r}.length`,o=>{this.var(f,(0,De._)`${r}[${o}]`),i(f)})}return this._for(new qf("of",n,f,t),()=>i(f))}forIn(u,t,i,n=this.opts.es5?$t.varKinds.var:$t.varKinds.const){if(this.opts.ownProperties)return this.forOf(u,(0,De._)`Object.keys(${t})`,i);let f=this._scope.toName(u);return this._for(new qf("in",n,f,t),()=>i(f))}endFor(){return this._endBlockNode(Lf)}label(u){return this._leafNode(new Vo(u))}break(u){return this._leafNode(new Ro(u))}return(u){let t=new v3;if(this._blockNode(t),this.code(u),t.nodes.length!==1)throw new Error('CodeGen: "return" should have one node');return this._endBlockNode(v3)}try(u,t,i){if(!t&&!i)throw new Error('CodeGen: "try" without "catch" and "finally"');let n=new Ko;if(this._blockNode(n),this.code(u),t){let f=this.name("e");this._currNode=n.catch=new B3(f),t(f)}return i&&(this._currNode=n.finally=new x3,this.code(i)),this._endBlockNode(B3,x3)}throw(u){return this._leafNode(new Lo(u))}block(u,t){return this._blockStarts.push(this._nodes.length),u&&this.code(u).endBlock(t),this}endBlock(u){let t=this._blockStarts.pop();if(t===void 0)throw new Error("CodeGen: not in self-balancing block");let i=this._nodes.length-t;if(i<0||u!==void 0&&i!==u)throw new Error(`CodeGen: wrong number of nodes: ${i} vs ${u} expected`);return this._nodes.length=t,this}func(u,t=De.nil,i,n){return this._blockNode(new y3(u,t,i)),n&&this.code(n).endFunc(),this}endFunc(){return this._endBlockNode(y3)}optimize(u=1){for(;u-- >0;)this._root.optimizeNodes(),this._root.optimizeNames(this._root.names,this._constants)}_leafNode(u){return this._currNode.nodes.push(u),this}_blockNode(u){this._currNode.nodes.push(u),this._nodes.push(u)}_endBlockNode(u,t){let i=this._currNode;if(i instanceof u||t&&i instanceof t)return this._nodes.pop(),this;throw new Error(`CodeGen: not in block "${t?`${u.kind}/${t.kind}`:u.kind}"`)}_elseNode(u){let t=this._currNode;if(!(t instanceof jf))throw new Error('CodeGen: "else" without "if"');return this._currNode=t.else=u,this}get _root(){return this._nodes[0]}get _currNode(){let u=this._nodes;return u[u.length-1]}set _currNode(u){let t=this._nodes;t[t.length-1]=u}};ie.CodeGen=Jo;function Vu(e,u){for(let t in u)e[t]=(e[t]||0)+(u[t]||0);return e}function Vf(e,u){return u instanceof De._CodeOrName?Vu(e,u.names):e}function Ei(e,u,t){if(e instanceof De.Name)return i(e);if(!n(e))return e;return new De._Code(e._items.reduce((f,r)=>(r instanceof De.Name&&(r=i(r)),r instanceof De._Code?f.push(...r._items):f.push(r),f),[]));function i(f){let r=t[f.str];return r===void 0||u[f.str]!==1?f:(delete u[f.str],r)}function n(f){return f instanceof De._Code&&f._items.some(r=>r instanceof De.Name&&u[r.str]===1&&t[r.str]!==void 0)}}function l9(e,u){for(let t in u)e[t]=(e[t]||0)-(u[t]||0)}function w3(e){return typeof e=="boolean"||typeof e=="number"||e===null?!e:(0,De._)`!${Zo(e)}`}ie.not=w3;var d9=I3(ie.operators.AND);function c9(...e){return e.reduce(d9)}ie.and=c9;var p9=I3(ie.operators.OR);function m9(...e){return e.reduce(p9)}ie.or=m9;function I3(e){return(u,t)=>u===De.nil?t:t===De.nil?u:(0,De._)`${Zo(u)} ${e} ${Zo(t)}`}function Zo(e){return e instanceof De.Name?e:(0,De._)`(${e})`}});var re=F(fe=>{"use strict";Object.defineProperty(fe,"__esModule",{value:!0});fe.checkStrictMode=fe.getErrorPath=fe.Type=fe.useFunc=fe.setEvaluated=fe.evaluatedPropsToName=fe.mergeEvaluated=fe.eachItem=fe.unescapeJsonPointer=fe.escapeJsonPointer=fe.escapeFragment=fe.unescapeFragment=fe.schemaRefOrVal=fe.schemaHasRulesButRef=fe.schemaHasRules=fe.checkUnknownRules=fe.alwaysValidSchema=fe.toHash=void 0;var be=te(),F9=bn();function C9(e){let u={};for(let t of e)u[t]=!0;return u}fe.toHash=C9;function g9(e,u){return typeof u=="boolean"?u:Object.keys(u).length===0?!0:(k3(e,u),!$3(u,e.self.RULES.all))}fe.alwaysValidSchema=g9;function k3(e,u=e.schema){let{opts:t,self:i}=e;if(!t.strictSchema||typeof u=="boolean")return;let n=i.RULES.keywords;for(let f in u)n[f]||O3(e,`unknown keyword: "${f}"`)}fe.checkUnknownRules=k3;function $3(e,u){if(typeof e=="boolean")return!e;for(let t in e)if(u[t])return!0;return!1}fe.schemaHasRules=$3;function h9(e,u){if(typeof e=="boolean")return!e;for(let t in e)if(t!=="$ref"&&u.all[t])return!0;return!1}fe.schemaHasRulesButRef=h9;function E9({topSchemaRef:e,schemaPath:u},t,i,n){if(!n){if(typeof t=="number"||typeof t=="boolean")return t;if(typeof t=="string")return(0,be._)`${t}`}return(0,be._)`${e}${u}${(0,be.getProperty)(i)}`}fe.schemaRefOrVal=E9;function b9(e){return T3(decodeURIComponent(e))}fe.unescapeFragment=b9;function _9(e){return encodeURIComponent(Xo(e))}fe.escapeFragment=_9;function Xo(e){return typeof e=="number"?`${e}`:e.replace(/~/g,"~0").replace(/\//g,"~1")}fe.escapeJsonPointer=Xo;function T3(e){return e.replace(/~1/g,"/").replace(/~0/g,"~")}fe.unescapeJsonPointer=T3;function y9(e,u){if(Array.isArray(e))for(let t of e)u(t);else u(e)}fe.eachItem=y9;function A3({mergeNames:e,mergeToName:u,mergeValues:t,resultToName:i}){return(n,f,r,o)=>{let a=r===void 0?f:r instanceof be.Name?(f instanceof be.Name?e(n,f,r):u(n,f,r),r):f instanceof be.Name?(u(n,r,f),f):t(f,r);return o===be.Name&&!(a instanceof be.Name)?i(n,a):a}}fe.mergeEvaluated={props:A3({mergeNames:(e,u,t)=>e.if((0,be._)`${t} !== true && ${u} !== undefined`,()=>{e.if((0,be._)`${u} === true`,()=>e.assign(t,!0),()=>e.assign(t,(0,be._)`${t} || {}`).code((0,be._)`Object.assign(${t}, ${u})`))}),mergeToName:(e,u,t)=>e.if((0,be._)`${t} !== true`,()=>{u===!0?e.assign(t,!0):(e.assign(t,(0,be._)`${t} || {}`),Yo(e,t,u))}),mergeValues:(e,u)=>e===!0?!0:Q(Q({},e),u),resultToName:P3}),items:A3({mergeNames:(e,u,t)=>e.if((0,be._)`${t} !== true && ${u} !== undefined`,()=>e.assign(t,(0,be._)`${u} === true ? true : ${t} > ${u} ? ${t} : ${u}`)),mergeToName:(e,u,t)=>e.if((0,be._)`${t} !== true`,()=>e.assign(t,u===!0?!0:(0,be._)`${t} > ${u} ? ${t} : ${u}`)),mergeValues:(e,u)=>e===!0?!0:Math.max(e,u),resultToName:(e,u)=>e.var("items",u)})};function P3(e,u){if(u===!0)return e.var("props",!0);let t=e.var("props",(0,be._)`{}`);return u!==void 0&&Yo(e,t,u),t}fe.evaluatedPropsToName=P3;function Yo(e,u,t){Object.keys(t).forEach(i=>e.assign((0,be._)`${u}${(0,be.getProperty)(i)}`,!0))}fe.setEvaluated=Yo;var S3={};function v9(e,u){return e.scopeValue("func",{ref:u,code:S3[u.code]||(S3[u.code]=new F9._Code(u.code))})}fe.useFunc=v9;var Qo=function(e){return e[e.Num=0]="Num",e[e.Str=1]="Str",e}(Qo||(fe.Type=Qo={}));function B9(e,u,t){if(e instanceof be.Name){let i=u===Qo.Num;return t?i?(0,be._)`"[" + ${e} + "]"`:(0,be._)`"['" + ${e} + "']"`:i?(0,be._)`"/" + ${e}`:(0,be._)`"/" + ${e}.replace(/~/g, "~0").replace(/\\//g, "~1")`}return t?(0,be.getProperty)(e).toString():"/"+Xo(e)}fe.getErrorPath=B9;function O3(e,u,t=e.opts.strictSchema){if(t){if(u=`strict mode: ${u}`,t===!0)throw new Error(u);e.self.logger.warn(u)}}fe.checkStrictMode=O3});var Et=F(ea=>{"use strict";Object.defineProperty(ea,"__esModule",{value:!0});var Qe=te(),x9={data:new Qe.Name("data"),valCxt:new Qe.Name("valCxt"),instancePath:new Qe.Name("instancePath"),parentData:new Qe.Name("parentData"),parentDataProperty:new Qe.Name("parentDataProperty"),rootData:new Qe.Name("rootData"),dynamicAnchors:new Qe.Name("dynamicAnchors"),vErrors:new Qe.Name("vErrors"),errors:new Qe.Name("errors"),this:new Qe.Name("this"),self:new Qe.Name("self"),scope:new Qe.Name("scope"),json:new Qe.Name("json"),jsonPos:new Qe.Name("jsonPos"),jsonLen:new Qe.Name("jsonLen"),jsonPart:new Qe.Name("jsonPart")};ea.default=x9});var yn=F(Xe=>{"use strict";Object.defineProperty(Xe,"__esModule",{value:!0});Xe.extendErrors=Xe.resetErrorsCount=Xe.reportExtraError=Xe.reportError=Xe.keyword$DataError=Xe.keywordError=void 0;var le=te(),zf=re(),ft=Et();Xe.keywordError={message:({keyword:e})=>(0,le.str)`must pass "${e}" keyword validation`};Xe.keyword$DataError={message:({keyword:e,schemaType:u})=>u?(0,le.str)`"${e}" keyword must be ${u} ($data)`:(0,le.str)`"${e}" keyword is invalid ($data)`};function w9(e,u=Xe.keywordError,t,i){let{it:n}=e,{gen:f,compositeRule:r,allErrors:o}=n,a=N3(e,u,t);(i!=null?i:r||o)?M3(f,a):j3(n,(0,le._)`[${a}]`)}Xe.reportError=w9;function I9(e,u=Xe.keywordError,t){let{it:i}=e,{gen:n,compositeRule:f,allErrors:r}=i,o=N3(e,u,t);M3(n,o),f||r||j3(i,ft.default.vErrors)}Xe.reportExtraError=I9;function A9(e,u){e.assign(ft.default.errors,u),e.if((0,le._)`${ft.default.vErrors} !== null`,()=>e.if(u,()=>e.assign((0,le._)`${ft.default.vErrors}.length`,u),()=>e.assign(ft.default.vErrors,null)))}Xe.resetErrorsCount=A9;function S9({gen:e,keyword:u,schemaValue:t,data:i,errsCount:n,it:f}){if(n===void 0)throw new Error("ajv implementation error");let r=e.name("err");e.forRange("i",n,ft.default.errors,o=>{e.const(r,(0,le._)`${ft.default.vErrors}[${o}]`),e.if((0,le._)`${r}.instancePath === undefined`,()=>e.assign((0,le._)`${r}.instancePath`,(0,le.strConcat)(ft.default.instancePath,f.errorPath))),e.assign((0,le._)`${r}.schemaPath`,(0,le.str)`${f.errSchemaPath}/${u}`),f.opts.verbose&&(e.assign((0,le._)`${r}.schema`,t),e.assign((0,le._)`${r}.data`,i))})}Xe.extendErrors=S9;function M3(e,u){let t=e.const("err",u);e.if((0,le._)`${ft.default.vErrors} === null`,()=>e.assign(ft.default.vErrors,(0,le._)`[${t}]`),(0,le._)`${ft.default.vErrors}.push(${t})`),e.code((0,le._)`${ft.default.errors}++`)}function j3(e,u){let{gen:t,validateName:i,schemaEnv:n}=e;n.$async?t.throw((0,le._)`new ${e.ValidationError}(${u})`):(t.assign((0,le._)`${i}.errors`,u),t.return(!1))}var Ru={keyword:new le.Name("keyword"),schemaPath:new le.Name("schemaPath"),params:new le.Name("params"),propertyName:new le.Name("propertyName"),message:new le.Name("message"),schema:new le.Name("schema"),parentSchema:new le.Name("parentSchema")};function N3(e,u,t){let{createErrors:i}=e.it;return i===!1?(0,le._)`{}`:k9(e,u,t)}function k9(e,u,t={}){let{gen:i,it:n}=e,f=[$9(n,t),T9(e,t)];return P9(e,u,f),i.object(...f)}function $9({errorPath:e},{instancePath:u}){let t=u?(0,le.str)`${e}${(0,zf.getErrorPath)(u,zf.Type.Str)}`:e;return[ft.default.instancePath,(0,le.strConcat)(ft.default.instancePath,t)]}function T9({keyword:e,it:{errSchemaPath:u}},{schemaPath:t,parentSchema:i}){let n=i?u:(0,le.str)`${u}/${e}`;return t&&(n=(0,le.str)`${n}${(0,zf.getErrorPath)(t,zf.Type.Str)}`),[Ru.schemaPath,n]}function P9(e,{params:u,message:t},i){let{keyword:n,data:f,schemaValue:r,it:o}=e,{opts:a,propertyName:D,topSchemaRef:l,schemaPath:p}=o;i.push([Ru.keyword,n],[Ru.params,typeof u=="function"?u(e):u||(0,le._)`{}`]),a.messages&&i.push([Ru.message,typeof t=="function"?t(e):t]),a.verbose&&i.push([Ru.schema,r],[Ru.parentSchema,(0,le._)`${l}${p}`],[ft.default.data,f]),D&&i.push([Ru.propertyName,D])}});var V3=F(bi=>{"use strict";Object.defineProperty(bi,"__esModule",{value:!0});bi.boolOrEmptySchema=bi.topBoolOrEmptySchema=void 0;var O9=yn(),M9=te(),j9=Et(),N9={message:"boolean schema is false"};function q9(e){let{gen:u,schema:t,validateName:i}=e;t===!1?q3(e,!1):typeof t=="object"&&t.$async===!0?u.return(j9.default.data):(u.assign((0,M9._)`${i}.errors`,null),u.return(!0))}bi.topBoolOrEmptySchema=q9;function V9(e,u){let{gen:t,schema:i}=e;i===!1?(t.var(u,!1),q3(e)):t.var(u,!0)}bi.boolOrEmptySchema=V9;function q3(e,u){let{gen:t,data:i}=e,n={gen:t,keyword:"false schema",data:i,schema:!1,schemaCode:!1,schemaValue:!1,params:{},it:e};(0,O9.reportError)(n,N9,void 0,u)}});var ta=F(_i=>{"use strict";Object.defineProperty(_i,"__esModule",{value:!0});_i.getRules=_i.isJSONType=void 0;var R9=["string","number","integer","boolean","null","object","array"],L9=new Set(R9);function z9(e){return typeof e=="string"&&L9.has(e)}_i.isJSONType=z9;function U9(){let e={number:{type:"number",rules:[]},string:{type:"string",rules:[]},array:{type:"array",rules:[]},object:{type:"object",rules:[]}};return{types:Ee(Q({},e),{integer:!0,boolean:!0,null:!0}),rules:[{rules:[]},e.number,e.string,e.array,e.object],post:{rules:[]},all:{},keywords:{}}}_i.getRules=U9});var ua=F(cu=>{"use strict";Object.defineProperty(cu,"__esModule",{value:!0});cu.shouldUseRule=cu.shouldUseGroup=cu.schemaHasRulesForType=void 0;function H9({schema:e,self:u},t){let i=u.RULES.types[t];return i&&i!==!0&&R3(e,i)}cu.schemaHasRulesForType=H9;function R3(e,u){return u.rules.some(t=>L3(e,t))}cu.shouldUseGroup=R3;function L3(e,u){var t;return e[u.keyword]!==void 0||((t=u.definition.implements)===null||t===void 0?void 0:t.some(i=>e[i]!==void 0))}cu.shouldUseRule=L3});var vn=F(Ye=>{"use strict";Object.defineProperty(Ye,"__esModule",{value:!0});Ye.reportTypeError=Ye.checkDataTypes=Ye.checkDataType=Ye.coerceAndCheckDataType=Ye.getJSONTypes=Ye.getSchemaTypes=Ye.DataType=void 0;var W9=ta(),G9=ua(),K9=yn(),ue=te(),z3=re(),yi=function(e){return e[e.Correct=0]="Correct",e[e.Wrong=1]="Wrong",e}(yi||(Ye.DataType=yi={}));function J9(e){let u=U3(e.type);if(u.includes("null")){if(e.nullable===!1)throw new Error("type: null contradicts nullable: false")}else{if(!u.length&&e.nullable!==void 0)throw new Error('"nullable" cannot be used without "type"');e.nullable===!0&&u.push("null")}return u}Ye.getSchemaTypes=J9;function U3(e){let u=Array.isArray(e)?e:e?[e]:[];if(u.every(W9.isJSONType))return u;throw new Error("type must be JSONType or JSONType[]: "+u.join(","))}Ye.getJSONTypes=U3;function Z9(e,u){let{gen:t,data:i,opts:n}=e,f=Q9(u,n.coerceTypes),r=u.length>0&&!(f.length===0&&u.length===1&&(0,G9.schemaHasRulesForType)(e,u[0]));if(r){let o=na(u,i,n.strictNumbers,yi.Wrong);t.if(o,()=>{f.length?X9(e,u,f):fa(e)})}return r}Ye.coerceAndCheckDataType=Z9;var H3=new Set(["string","number","integer","boolean","null"]);function Q9(e,u){return u?e.filter(t=>H3.has(t)||u==="array"&&t==="array"):[]}function X9(e,u,t){let{gen:i,data:n,opts:f}=e,r=i.let("dataType",(0,ue._)`typeof ${n}`),o=i.let("coerced",(0,ue._)`undefined`);f.coerceTypes==="array"&&i.if((0,ue._)`${r} == 'object' && Array.isArray(${n}) && ${n}.length == 1`,()=>i.assign(n,(0,ue._)`${n}[0]`).assign(r,(0,ue._)`typeof ${n}`).if(na(u,n,f.strictNumbers),()=>i.assign(o,n))),i.if((0,ue._)`${o} !== undefined`);for(let D of t)(H3.has(D)||D==="array"&&f.coerceTypes==="array")&&a(D);i.else(),fa(e),i.endIf(),i.if((0,ue._)`${o} !== undefined`,()=>{i.assign(n,o),Y9(e,o)});function a(D){switch(D){case"string":i.elseIf((0,ue._)`${r} == "number" || ${r} == "boolean"`).assign(o,(0,ue._)`"" + ${n}`).elseIf((0,ue._)`${n} === null`).assign(o,(0,ue._)`""`);return;case"number":i.elseIf((0,ue._)`${r} == "boolean" || ${n} === null
|
|
3
3
|
|| (${r} == "string" && ${n} && ${n} == +${n})`).assign(o,(0,ue._)`+${n}`);return;case"integer":i.elseIf((0,ue._)`${r} === "boolean" || ${n} === null
|
|
4
4
|
|| (${r} === "string" && ${n} && ${n} == +${n} && !(${n} % 1))`).assign(o,(0,ue._)`+${n}`);return;case"boolean":i.elseIf((0,ue._)`${n} === "false" || ${n} === 0 || ${n} === null`).assign(o,!1).elseIf((0,ue._)`${n} === "true" || ${n} === 1`).assign(o,!0);return;case"null":i.elseIf((0,ue._)`${n} === "" || ${n} === 0 || ${n} === false`),i.assign(o,null);return;case"array":i.elseIf((0,ue._)`${r} === "string" || ${r} === "number"
|