@luizleon/sf.prefeiturasp.vuecomponents 0.0.46 → 0.0.48

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.
@@ -1,4 +1,4 @@
1
- (function(Z,c){typeof exports=="object"&&typeof module<"u"?c(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],c):(Z=typeof globalThis<"u"?globalThis:Z||self,c((Z.sf=Z.sf||{},Z.sf.prefeiturasp=Z.sf.prefeiturasp||{},Z.sf.prefeiturasp.vuecomponents={}),Z.Vue))})(this,function(Z,c){"use strict";var ud=Object.defineProperty;var dd=(Z,c,Xe)=>c in Z?ud(Z,c,{enumerable:!0,configurable:!0,writable:!0,value:Xe}):Z[c]=Xe;var Be=(Z,c,Xe)=>(dd(Z,typeof c!="symbol"?c+"":c,Xe),Xe);class Xe{constructor(){Be(this,"_visible",c.ref(!1))}get IsVisible(){return this._visible.value===!0}Toggle(){this._visible.value=!this._visible.value}Close(){this._visible.value=!1}Open(){this._visible.value=!0}}const Cs=new Xe,fn=()=>Cs;class Ke{constructor(e){Be(this,"retorno");this.retorno=e??""}Concat(e){return e&&e.trim().length&&(this.retorno+=` ${e}`),this}AddClass(e,n=!0){return n?this.Concat(e):this}Build(){return this.retorno.trim()}}function fo(t=[]){let e="body *:not(style)";for(const n of t)e+=`, ${n}`;return Math.max(...Array.from(document.querySelectorAll(e)).map(n=>{const o=getComputedStyle(n).zIndex;return+o==+o?+o:0}))}let xs=(t=21)=>crypto.getRandomValues(new Uint8Array(t)).reduce((e,n)=>(n&=63,n<36?e+=n.toString(36):n<62?e+=(n-26).toString(36).toUpperCase():n>62?e+="-":e+="_",e),"");const po=(t,e)=>{const n=t.__vccOpts||t;for(const[o,r]of e)n[o]=r;return n},Ss={},_s={class:"sf-loading-circle"},vs=[c.createElementVNode("div",null,[c.createElementVNode("svg",{viewBox:"25 25 50 50"},[c.createElementVNode("circle",{cx:"50",cy:"50",r:"20",fill:"none","stroke-width":"4","stroke-miterlimit":"10"})])],-1)];function Ts(t,e){return c.openBlock(),c.createElementBlock("div",_s,vs)}const Ps=po(Ss,[["render",Ts]]),pn=c.defineComponent({__name:"Tooltip",props:{text:{}},setup(t){const e=t;class n{constructor(){Be(this,"zIndex");Be(this,"wrapper");Be(this,"inner");this.zIndex=fo()+1,this.Render()}Render(){this.wrapper=document.createElement("div"),this.wrapper.classList.add("sf-tooltip-wrapper"),this.wrapper.style.zIndex=`${this.zIndex??0}`,this.inner=document.createElement("div"),this.inner.classList.add("sf-tooltip-inner"),this.wrapper.appendChild(this.inner)}Show(s){this.inner.textContent=e.text;const i=s.target;document.body.appendChild(this.wrapper),this.Position(i.getBoundingClientRect()),this.wrapper.classList.add("visible")}Hide(){this.wrapper.classList.remove("visible"),this.wrapper.remove()}Position(s){const f=s.top,u=s.bottom,w=s.left,E=s.right,b=s.width/2-15,j=this.wrapper;j.style.top=`${u+10}px`,j.style.left=`${w}px`,j.style.marginLeft=`${b}px`,this.OutOfBottom()&&(j.style.top=`${f-j.clientHeight-10}px`,j.classList.add("top")),this.OutOfRight()&&(j.style.left=`${E-j.clientWidth}px`,j.style.marginLeft=`-${b}px`,j.classList.add("left"))}OutOfBottom(){return this.wrapper.getBoundingClientRect().bottom>(window.innerHeight||document.documentElement.clientHeight)}OutOfRight(){return this.wrapper.getBoundingClientRect().right>(window.innerWidth||document.documentElement.clientWidth)}}const o=new n;return c.onBeforeUnmount(()=>{o.Hide()}),(r,s)=>(c.openBlock(),c.createElementBlock("div",{class:"sf-tooltip-anchor",onMouseenter:s[0]||(s[0]=(...i)=>c.unref(o).Show&&c.unref(o).Show(...i)),onMouseleave:s[1]||(s[1]=(...i)=>c.unref(o).Hide&&c.unref(o).Hide(...i)),onMousedown:s[2]||(s[2]=(...i)=>c.unref(o).Hide&&c.unref(o).Hide(...i))},[c.renderSlot(r.$slots,"default")],32))}}),Rs=["disabled","tabindex"],Ls=["data-color"],wt=c.defineComponent({__name:"Icon",props:{icon:{},visible:{type:Boolean,default:!0},class:{default:""},style:{default:""},disabled:{type:Boolean},loading:{type:Boolean},button:{type:Boolean},size:{default:"md"},dot:{type:Boolean},dotColor:{default:"error"},filled:{type:Boolean},buttonProps:{},tooltip:{}},setup(t){const e=t,n=c.computed(()=>e.tooltip?pn:"div"),o=c.computed(()=>new Ke(`${e.class} sf-icon`).AddClass("sf-component-loading",e.loading).AddClass("sf-component-disabled",e.disabled).AddClass("sf-icon-button",e.button).AddClass("sf-icon-small",e.size==="sm").AddClass("sf-icon-medium",e.size==="md").AddClass("sf-icon-large",e.size==="lg").AddClass("sf-ripple",e.button===!0).Build());return(r,s)=>(c.openBlock(),c.createBlock(c.resolveDynamicComponent(n.value),{text:e.tooltip},{default:c.withCtx(()=>[e.visible?(c.openBlock(),c.createElementBlock("div",{key:0,style:c.normalizeStyle(e.style),class:c.normalizeClass(o.value)},[c.createElementVNode("button",c.mergeProps({class:["material-symbols-outlined",{"icon-filled":!!e.filled}],disabled:e.disabled||e.loading},e.buttonProps,{tabindex:e.button?void 0:-1}),[e.loading?(c.openBlock(),c.createBlock(Ps,{key:0})):(c.openBlock(),c.createElementBlock(c.Fragment,{key:1},[c.createTextVNode(c.toDisplayString(e.icon),1)],64))],16,Rs),e.dot?(c.openBlock(),c.createElementBlock("span",{key:0,"data-color":e.dotColor},null,8,Ls)):c.createCommentVNode("",!0)],6)):c.createCommentVNode("",!0)]),_:1},8,["text"]))}}),Os=["id","onClick"],Is={class:"sf-drawer-header"},Bs={class:"sf-drawer-title"},Ns={class:"sf-drawer-content"},Fs={key:0,class:"sf-drawer-footer"},ho=c.defineComponent({__name:"Drawer",props:{visible:{type:Boolean,default:!1},position:{default:"left"},style:{}},emits:["update:visible","open","before-close"],setup(t,{emit:e}){const n=t,o=e,r=c.useSlots(),s=c.ref(n.visible),i=c.ref(!1),f=c.ref(0),u=xs();function w(){s.value=!1}function E(D){(D.key==="Escape"||D.code==="Escape")&&w()}function b(){o("open"),window.document.addEventListener("keydown",E,!0)}function j(D){f.value=fo(),D.style.zIndex=`${f.value}`}function $(D){var ee;o("before-close"),(ee=D==null?void 0:D.parentElement)==null||ee.classList.add("sf-mask-overlay-leave")}function B(){window.document.removeEventListener("keydown",E,!0),i.value=!1}function N(){return new Ke("sf-mask sf-mask-overlay").AddClass("right",n.position==="right").AddClass("bottom",n.position==="bottom").AddClass("full",n.position==="full").AddClass("sf-mask-overlay-enter",n.visible===!0).Build()}return c.watch(()=>n.visible,D=>{s.value=D}),c.watch(()=>s.value,D=>{o("update:visible",D),D&&(i.value=!0)}),(D,ee)=>(c.openBlock(),c.createBlock(c.Teleport,{to:"body"},[i.value?(c.openBlock(),c.createElementBlock("div",{key:0,id:c.unref(u),class:c.normalizeClass(N()),style:c.normalizeStyle({zIndex:f.value-1}),onClick:c.withModifiers(w,["stop"])},[c.createVNode(c.Transition,{name:"sf-drawer",appear:"",onBeforeEnter:j,onEnter:b,onBeforeLeave:$,onAfterLeave:B},{default:c.withCtx(()=>[s.value?(c.openBlock(),c.createElementBlock("div",{key:0,class:c.normalizeClass(["sf-drawer",{"sf-drawer-with-footer":!!c.unref(r).footer}]),style:c.normalizeStyle(n.style),role:"dialog",onClick:ee[0]||(ee[0]=c.withModifiers(oe=>D.void,["stop"]))},[c.createElementVNode("div",Is,[c.createElementVNode("span",Bs,[c.renderSlot(D.$slots,"title")]),c.createVNode(wt,{button:!0,icon:"close",onClick:c.withModifiers(w,["stop"])},null,8,["onClick"])]),c.createElementVNode("div",Ns,[c.renderSlot(D.$slots,"default")]),c.unref(r).footer?(c.openBlock(),c.createElementBlock("div",Fs,[c.renderSlot(D.$slots,"footer")])):c.createCommentVNode("",!0)],6)):c.createCommentVNode("",!0)]),_:3})],14,Os)):c.createCommentVNode("",!0)]))}}),Us=["id","name","disabled","data-color","form","type"],Ms={class:"sf-button-label"},mo=c.defineComponent({__name:"Button",props:{icon:{},visible:{type:Boolean,default:!0},class:{},style:{},disabled:{type:Boolean},loading:{type:Boolean},color:{default:"primary"},size:{default:"md"},variant:{default:"filled"},autofocus:{type:Boolean},form:{},name:{},id:{},type:{default:"button"},value:{}},setup(t){const e=t;function n(){return new Ke(`${e.class??""} sf-button`).AddClass("sf-component-loading",e.loading).AddClass("sf-component-disabled",e.disabled).AddClass("sf-button-small",e.size==="sm").AddClass("sf-button-medium",e.size==="md").AddClass("sf-button-large",e.size==="lg").AddClass("sf-button-filled",e.variant==="filled").AddClass("sf-button-text",e.variant==="text").AddClass("sf-button-outlined",e.variant==="outlined").AddClass("sf-button-with-icon",!!e.icon).AddClass("sf-ripple").Build()}return(o,r)=>e.visible?(c.openBlock(),c.createElementBlock("button",{key:0,id:e.id,name:e.name,class:c.normalizeClass(n()),style:c.normalizeStyle(e.style),disabled:e.disabled||e.loading,"data-color":e.color,form:e.form,type:e.type},[e.icon?(c.openBlock(),c.createBlock(wt,{key:0,filled:e.variant==="filled",icon:e.icon,loading:e.loading,size:e.size,"button-props":{tabindex:-1}},null,8,["filled","icon","loading","size"])):e.loading?(c.openBlock(),c.createBlock(wt,{key:1,loading:!0,size:e.size,"button-props":{tabindex:-1}},null,8,["size"])):c.createCommentVNode("",!0),c.createElementVNode("span",Ms,[c.renderSlot(o.$slots,"default")])],14,Us)):c.createCommentVNode("",!0)}}),go="SweetAlert2:",Ds=t=>{const e=[];for(let n=0;n<t.length;n++)e.indexOf(t[n])===-1&&e.push(t[n]);return e},hn=t=>t.charAt(0).toUpperCase()+t.slice(1),_e=t=>Array.prototype.slice.call(t),Ee=t=>{console.warn(`${go} ${typeof t=="object"?t.join(" "):t}`)},Ze=t=>{console.error(`${go} ${t}`)},yo=[],$s=t=>{yo.includes(t)||(yo.push(t),Ee(t))},Hs=(t,e)=>{$s(`"${t}" is deprecated and will be removed in the next major release. Please use "${e}" instead.`)},Ht=t=>typeof t=="function"?t():t,mn=t=>t&&typeof t.toPromise=="function",Et=t=>mn(t)?t.toPromise():Promise.resolve(t),gn=t=>t&&Promise.resolve(t)===t,st={title:"",titleText:"",text:"",html:"",footer:"",icon:void 0,iconColor:void 0,iconHtml:void 0,template:void 0,toast:!1,showClass:{popup:"swal2-show",backdrop:"swal2-backdrop-show",icon:"swal2-icon-show"},hideClass:{popup:"swal2-hide",backdrop:"swal2-backdrop-hide",icon:"swal2-icon-hide"},customClass:{},target:"body",color:void 0,backdrop:!0,heightAuto:!0,allowOutsideClick:!0,allowEscapeKey:!0,allowEnterKey:!0,stopKeydownPropagation:!0,keydownListenerCapture:!1,showConfirmButton:!0,showDenyButton:!1,showCancelButton:!1,preConfirm:void 0,preDeny:void 0,confirmButtonText:"OK",confirmButtonAriaLabel:"",confirmButtonColor:void 0,denyButtonText:"No",denyButtonAriaLabel:"",denyButtonColor:void 0,cancelButtonText:"Cancel",cancelButtonAriaLabel:"",cancelButtonColor:void 0,buttonsStyling:!0,reverseButtons:!1,focusConfirm:!0,focusDeny:!1,focusCancel:!1,returnFocus:!0,showCloseButton:!1,closeButtonHtml:"&times;",closeButtonAriaLabel:"Close this dialog",loaderHtml:"",showLoaderOnConfirm:!1,showLoaderOnDeny:!1,imageUrl:void 0,imageWidth:void 0,imageHeight:void 0,imageAlt:"",timer:void 0,timerProgressBar:!1,width:void 0,padding:void 0,background:void 0,input:void 0,inputPlaceholder:"",inputLabel:"",inputValue:"",inputOptions:{},inputAutoTrim:!0,inputAttributes:{},inputValidator:void 0,returnInputValueOnDeny:!1,validationMessage:void 0,grow:!1,position:"center",progressSteps:[],currentProgressStep:void 0,progressStepsDistance:void 0,willOpen:void 0,didOpen:void 0,didRender:void 0,willClose:void 0,didClose:void 0,didDestroy:void 0,scrollbarPadding:!0},js=["allowEscapeKey","allowOutsideClick","background","buttonsStyling","cancelButtonAriaLabel","cancelButtonColor","cancelButtonText","closeButtonAriaLabel","closeButtonHtml","color","confirmButtonAriaLabel","confirmButtonColor","confirmButtonText","currentProgressStep","customClass","denyButtonAriaLabel","denyButtonColor","denyButtonText","didClose","didDestroy","footer","hideClass","html","icon","iconColor","iconHtml","imageAlt","imageHeight","imageUrl","imageWidth","preConfirm","preDeny","progressSteps","returnFocus","reverseButtons","showCancelButton","showCloseButton","showConfirmButton","showDenyButton","text","title","titleText","willClose"],Vs={},zs=["allowOutsideClick","allowEnterKey","backdrop","focusConfirm","focusDeny","focusCancel","returnFocus","heightAuto","keydownListenerCapture"],bo=t=>Object.prototype.hasOwnProperty.call(st,t),wo=t=>js.indexOf(t)!==-1,yn=t=>Vs[t],Ws=t=>{bo(t)||Ee(`Unknown parameter "${t}"`)},qs=t=>{zs.includes(t)&&Ee(`The parameter "${t}" is incompatible with toasts`)},Ks=t=>{yn(t)&&Hs(t,yn(t))},Gs=t=>{!t.backdrop&&t.allowOutsideClick&&Ee('"allowOutsideClick" parameter requires `backdrop` parameter to be set to `true`');for(const e in t)Ws(e),t.toast&&qs(e),Ks(e)},Js="swal2-",Eo=t=>{const e={};for(const n in t)e[t[n]]=Js+t[n];return e},p=Eo(["container","shown","height-auto","iosfix","popup","modal","no-backdrop","no-transition","toast","toast-shown","show","hide","close","title","html-container","actions","confirm","deny","cancel","default-outline","footer","icon","icon-content","image","input","file","range","select","radio","checkbox","label","textarea","inputerror","input-label","validation-message","progress-steps","active-progress-step","progress-step","progress-step-line","loader","loading","styled","top","top-start","top-end","top-left","top-right","center","center-start","center-end","center-left","center-right","bottom","bottom-start","bottom-end","bottom-left","bottom-right","grow-row","grow-column","grow-fullscreen","rtl","timer-progress-bar","timer-progress-bar-container","scrollbar-measure","icon-success","icon-warning","icon-info","icon-question","icon-error"]),At=Eo(["success","warning","info","question","error"]),de=()=>document.body.querySelector(`.${p.container}`),kt=t=>{const e=de();return e?e.querySelector(t):null},Re=t=>kt(`.${t}`),Q=()=>Re(p.popup),Ct=()=>Re(p.icon),Ao=()=>Re(p.title),jt=()=>Re(p["html-container"]),ko=()=>Re(p.image),Co=()=>Re(p["progress-steps"]),Vt=()=>Re(p["validation-message"]),Ne=()=>kt(`.${p.actions} .${p.confirm}`),Ge=()=>kt(`.${p.actions} .${p.deny}`),Ys=()=>Re(p["input-label"]),it=()=>kt(`.${p.loader}`),Qe=()=>kt(`.${p.actions} .${p.cancel}`),xt=()=>Re(p.actions),xo=()=>Re(p.footer),zt=()=>Re(p["timer-progress-bar"]),bn=()=>Re(p.close),Xs=`
1
+ (function(ne,l){typeof exports=="object"&&typeof module<"u"?l(exports,require("vue")):typeof define=="function"&&define.amd?define(["exports","vue"],l):(ne=typeof globalThis<"u"?globalThis:ne||self,l((ne.sf=ne.sf||{},ne.sf.prefeiturasp=ne.sf.prefeiturasp||{},ne.sf.prefeiturasp.vuecomponents={}),ne.Vue))})(this,function(ne,l){"use strict";var im=Object.defineProperty;var sm=(ne,l,rt)=>l in ne?im(ne,l,{enumerable:!0,configurable:!0,writable:!0,value:rt}):ne[l]=rt;var Me=(ne,l,rt)=>(sm(ne,typeof l!="symbol"?l+"":l,rt),rt);class rt{constructor(){Me(this,"_visible",l.ref(!1))}get IsVisible(){return this._visible.value===!0}Toggle(){this._visible.value=!this._visible.value}Close(){this._visible.value=!1}Open(){this._visible.value=!0}}const Ps=new rt,Tn=()=>Ps;class Ze{constructor(e){Me(this,"retorno");this.retorno=e??""}Concat(e){return e&&e.trim().length&&(this.retorno+=` ${e}`),this}AddClass(e,n=!0){return n?this.Concat(e):this}Build(){return this.retorno.trim()}}function jr(t=[]){let e="body *:not(style)";for(const n of t)e+=`, ${n}`;return Math.max(...Array.from(document.querySelectorAll(e)).map(n=>{const r=getComputedStyle(n).zIndex;return+r==+r?+r:0}))}let Ts=(t=21)=>crypto.getRandomValues(new Uint8Array(t)).reduce((e,n)=>(n&=63,n<36?e+=n.toString(36):n<62?e+=(n-26).toString(36).toUpperCase():n>62?e+="-":e+="_",e),"");const Vr=(t,e)=>{const n=t.__vccOpts||t;for(const[r,o]of e)n[r]=o;return n},Os={},Ls={class:"sf-loading-circle"},Bs=[l.createElementVNode("div",null,[l.createElementVNode("svg",{viewBox:"25 25 50 50"},[l.createElementVNode("circle",{cx:"50",cy:"50",r:"20",fill:"none","stroke-width":"4","stroke-miterlimit":"10"})])],-1)];function Rs(t,e){return l.openBlock(),l.createElementBlock("div",Ls,Bs)}const Fs=Vr(Os,[["render",Rs]]),On=l.defineComponent({__name:"Tooltip",props:{text:{}},setup(t){const e=t;class n{constructor(){Me(this,"zIndex");Me(this,"wrapper");Me(this,"inner");this.zIndex=jr()+1,this.Render()}Render(){this.wrapper=document.createElement("div"),this.wrapper.classList.add("sf-tooltip-wrapper"),this.wrapper.style.zIndex=`${this.zIndex??0}`,this.inner=document.createElement("div"),this.inner.classList.add("sf-tooltip-inner"),this.wrapper.appendChild(this.inner)}Show(i){this.inner.textContent=e.text;const s=i.target;document.body.appendChild(this.wrapper),this.Position(s.getBoundingClientRect()),this.wrapper.classList.add("visible")}Hide(){this.wrapper.classList.remove("visible"),this.wrapper.remove()}Position(i){const c=i.top,a=i.bottom,u=i.left,f=i.right,p=i.width/2-15,v=this.wrapper;v.style.top=`${a+10}px`,v.style.left=`${u}px`,v.style.marginLeft=`${p}px`,this.OutOfBottom()&&(v.style.top=`${c-v.clientHeight-10}px`,v.classList.add("top")),this.OutOfRight()&&(v.style.left=`${f-v.clientWidth}px`,v.style.marginLeft=`-${p}px`,v.classList.add("left"))}OutOfBottom(){return this.wrapper.getBoundingClientRect().bottom>(window.innerHeight||document.documentElement.clientHeight)}OutOfRight(){return this.wrapper.getBoundingClientRect().right>(window.innerWidth||document.documentElement.clientWidth)}}const r=new n;return l.onBeforeUnmount(()=>{r.Hide()}),(o,i)=>(l.openBlock(),l.createElementBlock("div",{class:"sf-tooltip-anchor",onMouseenter:i[0]||(i[0]=(...s)=>l.unref(r).Show&&l.unref(r).Show(...s)),onMouseleave:i[1]||(i[1]=(...s)=>l.unref(r).Hide&&l.unref(r).Hide(...s)),onMousedown:i[2]||(i[2]=(...s)=>l.unref(r).Hide&&l.unref(r).Hide(...s))},[l.renderSlot(o.$slots,"default")],32))}}),$s=["disabled","tabindex"],Ns=["data-color"],Qe=l.defineComponent({__name:"Icon",props:{icon:{},visible:{type:Boolean,default:!0},class:{default:""},style:{default:""},disabled:{type:Boolean},loading:{type:Boolean},button:{type:Boolean},size:{default:"md"},dot:{type:Boolean},dotColor:{default:"error"},filled:{type:Boolean},buttonProps:{},tooltip:{}},setup(t){const e=t,n=l.computed(()=>e.tooltip?On:"div"),r=l.computed(()=>new Ze(`${e.class} sf-icon`).AddClass("sf-component-loading",e.loading).AddClass("sf-component-disabled",e.disabled).AddClass("sf-icon-button",e.button).AddClass("sf-icon-small",e.size==="sm").AddClass("sf-icon-medium",e.size==="md").AddClass("sf-icon-large",e.size==="lg").AddClass("sf-ripple",e.button===!0).Build());return(o,i)=>(l.openBlock(),l.createBlock(l.resolveDynamicComponent(n.value),{text:e.tooltip},{default:l.withCtx(()=>[e.visible?(l.openBlock(),l.createElementBlock("div",{key:0,style:l.normalizeStyle(e.style),class:l.normalizeClass(r.value)},[l.createElementVNode("button",l.mergeProps({class:["material-symbols-outlined",{"icon-filled":!!e.filled}],disabled:e.disabled||e.loading},e.buttonProps,{tabindex:e.button?void 0:-1}),[e.loading?(l.openBlock(),l.createBlock(Fs,{key:0})):(l.openBlock(),l.createElementBlock(l.Fragment,{key:1},[l.createTextVNode(l.toDisplayString(e.icon),1)],64))],16,$s),e.dot?(l.openBlock(),l.createElementBlock("span",{key:0,"data-color":e.dotColor},null,8,Ns)):l.createCommentVNode("",!0)],6)):l.createCommentVNode("",!0)]),_:1},8,["text"]))}}),Ds=["id","onClick"],Ms={class:"sf-drawer-header"},Us={class:"sf-drawer-title"},Hs={class:"sf-drawer-content"},js={key:0,class:"sf-drawer-footer"},Kr=l.defineComponent({__name:"Drawer",props:{visible:{type:Boolean,default:!1},position:{default:"left"},style:{}},emits:["update:visible","open","before-close"],setup(t,{emit:e}){const n=t,r=e,o=l.useSlots(),i=l.ref(n.visible),s=l.ref(!1),c=l.ref(0),a=Ts();function u(){i.value=!1}function f(_){(_.key==="Escape"||_.code==="Escape")&&u()}function p(){r("open"),window.document.addEventListener("keydown",f,!0)}function v(_){c.value=jr(),_.style.zIndex=`${c.value}`}function w(_){var $;r("before-close"),($=_==null?void 0:_.parentElement)==null||$.classList.add("sf-mask-overlay-leave")}function C(){window.document.removeEventListener("keydown",f,!0),s.value=!1}function x(){return new Ze("sf-mask sf-mask-overlay").AddClass("right",n.position==="right").AddClass("bottom",n.position==="bottom").AddClass("full",n.position==="full").AddClass("sf-mask-overlay-enter",n.visible===!0).Build()}return l.watch(()=>n.visible,_=>{i.value=_}),l.watch(()=>i.value,_=>{r("update:visible",_),_&&(s.value=!0)}),(_,$)=>(l.openBlock(),l.createBlock(l.Teleport,{to:"body"},[s.value?(l.openBlock(),l.createElementBlock("div",{key:0,id:l.unref(a),class:l.normalizeClass(x()),style:l.normalizeStyle({zIndex:c.value-1}),onClick:l.withModifiers(u,["stop"])},[l.createVNode(l.Transition,{name:"sf-drawer",appear:"",onBeforeEnter:v,onEnter:p,onBeforeLeave:w,onAfterLeave:C},{default:l.withCtx(()=>[i.value?(l.openBlock(),l.createElementBlock("div",{key:0,class:l.normalizeClass(["sf-drawer",{"sf-drawer-with-footer":!!l.unref(o).footer}]),style:l.normalizeStyle(n.style),role:"dialog",onClick:$[0]||($[0]=l.withModifiers(q=>_.void,["stop"]))},[l.createElementVNode("div",Ms,[l.createElementVNode("span",Us,[l.renderSlot(_.$slots,"title")]),l.createVNode(Qe,{button:!0,icon:"close",onClick:l.withModifiers(u,["stop"])},null,8,["onClick"])]),l.createElementVNode("div",Hs,[l.renderSlot(_.$slots,"default")]),l.unref(o).footer?(l.openBlock(),l.createElementBlock("div",js,[l.renderSlot(_.$slots,"footer")])):l.createCommentVNode("",!0)],6)):l.createCommentVNode("",!0)]),_:3})],14,Ds)):l.createCommentVNode("",!0)]))}}),Vs=["id","name","disabled","data-color","form","type"],Ks={class:"sf-button-label"},zr=l.defineComponent({__name:"Button",props:{icon:{},visible:{type:Boolean,default:!0},class:{},style:{},disabled:{type:Boolean},loading:{type:Boolean},color:{default:"primary"},size:{default:"md"},variant:{default:"filled"},autofocus:{type:Boolean},form:{},name:{},id:{},type:{default:"button"},value:{}},setup(t){const e=t;function n(){return new Ze(`${e.class??""} sf-button`).AddClass("sf-component-loading",e.loading).AddClass("sf-component-disabled",e.disabled).AddClass("sf-button-small",e.size==="sm").AddClass("sf-button-medium",e.size==="md").AddClass("sf-button-large",e.size==="lg").AddClass("sf-button-filled",e.variant==="filled").AddClass("sf-button-text",e.variant==="text").AddClass("sf-button-outlined",e.variant==="outlined").AddClass("sf-button-with-icon",!!e.icon).AddClass("sf-ripple").Build()}return(r,o)=>e.visible?(l.openBlock(),l.createElementBlock("button",{key:0,id:e.id,name:e.name,class:l.normalizeClass(n()),style:l.normalizeStyle(e.style),disabled:e.disabled||e.loading,"data-color":e.color,form:e.form,type:e.type},[e.icon?(l.openBlock(),l.createBlock(Qe,{key:0,filled:e.variant==="filled",icon:e.icon,loading:e.loading,size:e.size,"button-props":{tabindex:-1}},null,8,["filled","icon","loading","size"])):e.loading?(l.openBlock(),l.createBlock(Qe,{key:1,loading:!0,size:e.size,"button-props":{tabindex:-1}},null,8,["size"])):l.createCommentVNode("",!0),l.createElementVNode("span",Ks,[l.renderSlot(r.$slots,"default")])],14,Vs)):l.createCommentVNode("",!0)}}),Wr="SweetAlert2:",zs=t=>{const e=[];for(let n=0;n<t.length;n++)e.indexOf(t[n])===-1&&e.push(t[n]);return e},Ln=t=>t.charAt(0).toUpperCase()+t.slice(1),Oe=t=>Array.prototype.slice.call(t),Ae=t=>{console.warn(`${Wr} ${typeof t=="object"?t.join(" "):t}`)},ot=t=>{console.error(`${Wr} ${t}`)},qr=[],Ws=t=>{qr.includes(t)||(qr.push(t),Ae(t))},qs=(t,e)=>{Ws(`"${t}" is deprecated and will be removed in the next major release. Please use "${e}" instead.`)},nn=t=>typeof t=="function"?t():t,Bn=t=>t&&typeof t.toPromise=="function",kt=t=>Bn(t)?t.toPromise():Promise.resolve(t),Rn=t=>t&&Promise.resolve(t)===t,ft={title:"",titleText:"",text:"",html:"",footer:"",icon:void 0,iconColor:void 0,iconHtml:void 0,template:void 0,toast:!1,showClass:{popup:"swal2-show",backdrop:"swal2-backdrop-show",icon:"swal2-icon-show"},hideClass:{popup:"swal2-hide",backdrop:"swal2-backdrop-hide",icon:"swal2-icon-hide"},customClass:{},target:"body",color:void 0,backdrop:!0,heightAuto:!0,allowOutsideClick:!0,allowEscapeKey:!0,allowEnterKey:!0,stopKeydownPropagation:!0,keydownListenerCapture:!1,showConfirmButton:!0,showDenyButton:!1,showCancelButton:!1,preConfirm:void 0,preDeny:void 0,confirmButtonText:"OK",confirmButtonAriaLabel:"",confirmButtonColor:void 0,denyButtonText:"No",denyButtonAriaLabel:"",denyButtonColor:void 0,cancelButtonText:"Cancel",cancelButtonAriaLabel:"",cancelButtonColor:void 0,buttonsStyling:!0,reverseButtons:!1,focusConfirm:!0,focusDeny:!1,focusCancel:!1,returnFocus:!0,showCloseButton:!1,closeButtonHtml:"&times;",closeButtonAriaLabel:"Close this dialog",loaderHtml:"",showLoaderOnConfirm:!1,showLoaderOnDeny:!1,imageUrl:void 0,imageWidth:void 0,imageHeight:void 0,imageAlt:"",timer:void 0,timerProgressBar:!1,width:void 0,padding:void 0,background:void 0,input:void 0,inputPlaceholder:"",inputLabel:"",inputValue:"",inputOptions:{},inputAutoTrim:!0,inputAttributes:{},inputValidator:void 0,returnInputValueOnDeny:!1,validationMessage:void 0,grow:!1,position:"center",progressSteps:[],currentProgressStep:void 0,progressStepsDistance:void 0,willOpen:void 0,didOpen:void 0,didRender:void 0,willClose:void 0,didClose:void 0,didDestroy:void 0,scrollbarPadding:!0},Gs=["allowEscapeKey","allowOutsideClick","background","buttonsStyling","cancelButtonAriaLabel","cancelButtonColor","cancelButtonText","closeButtonAriaLabel","closeButtonHtml","color","confirmButtonAriaLabel","confirmButtonColor","confirmButtonText","currentProgressStep","customClass","denyButtonAriaLabel","denyButtonColor","denyButtonText","didClose","didDestroy","footer","hideClass","html","icon","iconColor","iconHtml","imageAlt","imageHeight","imageUrl","imageWidth","preConfirm","preDeny","progressSteps","returnFocus","reverseButtons","showCancelButton","showCloseButton","showConfirmButton","showDenyButton","text","title","titleText","willClose"],Js={},Ys=["allowOutsideClick","allowEnterKey","backdrop","focusConfirm","focusDeny","focusCancel","returnFocus","heightAuto","keydownListenerCapture"],Gr=t=>Object.prototype.hasOwnProperty.call(ft,t),Jr=t=>Gs.indexOf(t)!==-1,Fn=t=>Js[t],Xs=t=>{Gr(t)||Ae(`Unknown parameter "${t}"`)},Zs=t=>{Ys.includes(t)&&Ae(`The parameter "${t}" is incompatible with toasts`)},Qs=t=>{Fn(t)&&qs(t,Fn(t))},ea=t=>{!t.backdrop&&t.allowOutsideClick&&Ae('"allowOutsideClick" parameter requires `backdrop` parameter to be set to `true`');for(const e in t)Xs(e),t.toast&&Zs(e),Qs(e)},ta="swal2-",Yr=t=>{const e={};for(const n in t)e[t[n]]=ta+t[n];return e},g=Yr(["container","shown","height-auto","iosfix","popup","modal","no-backdrop","no-transition","toast","toast-shown","show","hide","close","title","html-container","actions","confirm","deny","cancel","default-outline","footer","icon","icon-content","image","input","file","range","select","radio","checkbox","label","textarea","inputerror","input-label","validation-message","progress-steps","active-progress-step","progress-step","progress-step-line","loader","loading","styled","top","top-start","top-end","top-left","top-right","center","center-start","center-end","center-left","center-right","bottom","bottom-start","bottom-end","bottom-left","bottom-right","grow-row","grow-column","grow-fullscreen","rtl","timer-progress-bar","timer-progress-bar-container","scrollbar-measure","icon-success","icon-warning","icon-info","icon-question","icon-error"]),xt=Yr(["success","warning","info","question","error"]),ye=()=>document.body.querySelector(`.${g.container}`),It=t=>{const e=ye();return e?e.querySelector(t):null},Fe=t=>It(`.${t}`),oe=()=>Fe(g.popup),Pt=()=>Fe(g.icon),Xr=()=>Fe(g.title),rn=()=>Fe(g["html-container"]),Zr=()=>Fe(g.image),Qr=()=>Fe(g["progress-steps"]),on=()=>Fe(g["validation-message"]),Ue=()=>It(`.${g.actions} .${g.confirm}`),et=()=>It(`.${g.actions} .${g.deny}`),na=()=>Fe(g["input-label"]),pt=()=>It(`.${g.loader}`),it=()=>It(`.${g.actions} .${g.cancel}`),Tt=()=>Fe(g.actions),eo=()=>Fe(g.footer),sn=()=>Fe(g["timer-progress-bar"]),$n=()=>Fe(g.close),ra=`
2
2
  a[href],
3
3
  area[href],
4
4
  input:not([disabled]),
@@ -13,70 +13,152 @@
13
13
  audio[controls],
14
14
  video[controls],
15
15
  summary
16
- `,wn=()=>{const t=_e(Q().querySelectorAll('[tabindex]:not([tabindex="-1"]):not([tabindex="0"])')).sort((n,o)=>{const r=parseInt(n.getAttribute("tabindex")),s=parseInt(o.getAttribute("tabindex"));return r>s?1:r<s?-1:0}),e=_e(Q().querySelectorAll(Xs)).filter(n=>n.getAttribute("tabindex")!=="-1");return Ds(t.concat(e)).filter(n=>ve(n))},En=()=>Ve(document.body,p.shown)&&!Ve(document.body,p["toast-shown"])&&!Ve(document.body,p["no-backdrop"]),Wt=()=>Q()&&Ve(Q(),p.toast),Zs=()=>Q().hasAttribute("data-loading"),at={previousBodyPadding:null},fe=(t,e)=>{if(t.textContent="",e){const o=new DOMParser().parseFromString(e,"text/html");_e(o.querySelector("head").childNodes).forEach(r=>{t.appendChild(r)}),_e(o.querySelector("body").childNodes).forEach(r=>{t.appendChild(r)})}},Ve=(t,e)=>{if(!e)return!1;const n=e.split(/\s+/);for(let o=0;o<n.length;o++)if(!t.classList.contains(n[o]))return!1;return!0},Qs=(t,e)=>{_e(t.classList).forEach(n=>{!Object.values(p).includes(n)&&!Object.values(At).includes(n)&&!Object.values(e.showClass).includes(n)&&t.classList.remove(n)})},Le=(t,e,n)=>{if(Qs(t,e),e.customClass&&e.customClass[n]){if(typeof e.customClass[n]!="string"&&!e.customClass[n].forEach)return Ee(`Invalid type of customClass.${n}! Expected string or iterable object, got "${typeof e.customClass[n]}"`);Y(t,e.customClass[n])}},An=(t,e)=>{if(!e)return null;switch(e){case"select":case"textarea":case"file":return t.querySelector(`.${p.popup} > .${p[e]}`);case"checkbox":return t.querySelector(`.${p.popup} > .${p.checkbox} input`);case"radio":return t.querySelector(`.${p.popup} > .${p.radio} input:checked`)||t.querySelector(`.${p.popup} > .${p.radio} input:first-child`);case"range":return t.querySelector(`.${p.popup} > .${p.range} input`);default:return t.querySelector(`.${p.popup} > .${p.input}`)}},So=t=>{if(t.focus(),t.type!=="file"){const e=t.value;t.value="",t.value=e}},_o=(t,e,n)=>{!t||!e||(typeof e=="string"&&(e=e.split(/\s+/).filter(Boolean)),e.forEach(o=>{Array.isArray(t)?t.forEach(r=>{n?r.classList.add(o):r.classList.remove(o)}):n?t.classList.add(o):t.classList.remove(o)}))},Y=(t,e)=>{_o(t,e,!0)},Me=(t,e)=>{_o(t,e,!1)},Je=(t,e)=>{const n=_e(t.childNodes);for(let o=0;o<n.length;o++)if(Ve(n[o],e))return n[o]},St=(t,e,n)=>{n===`${parseInt(n)}`&&(n=parseInt(n)),n||parseInt(n)===0?t.style[e]=typeof n=="number"?`${n}px`:n:t.style.removeProperty(e)},le=(t,e="flex")=>{t.style.display=e},pe=t=>{t.style.display="none"},vo=(t,e,n,o)=>{const r=t.querySelector(e);r&&(r.style[n]=o)},qt=(t,e,n)=>{e?le(t,n):pe(t)},ve=t=>!!(t&&(t.offsetWidth||t.offsetHeight||t.getClientRects().length)),ei=()=>!ve(Ne())&&!ve(Ge())&&!ve(Qe()),To=t=>t.scrollHeight>t.clientHeight,Po=t=>{const e=window.getComputedStyle(t),n=parseFloat(e.getPropertyValue("animation-duration")||"0"),o=parseFloat(e.getPropertyValue("transition-duration")||"0");return n>0||o>0},kn=(t,e=!1)=>{const n=zt();ve(n)&&(e&&(n.style.transition="none",n.style.width="100%"),setTimeout(()=>{n.style.transition=`width ${t/1e3}s linear`,n.style.width="0%"},10))},ti=()=>{const t=zt(),e=parseInt(window.getComputedStyle(t).width);t.style.removeProperty("transition"),t.style.width="100%";const n=parseInt(window.getComputedStyle(t).width),o=e/n*100;t.style.removeProperty("transition"),t.style.width=`${o}%`},Ro=()=>typeof window>"u"||typeof document>"u",ni=100,q={},oi=()=>{q.previousActiveElement&&q.previousActiveElement.focus?(q.previousActiveElement.focus(),q.previousActiveElement=null):document.body&&document.body.focus()},ri=t=>new Promise(e=>{if(!t)return e();const n=window.scrollX,o=window.scrollY;q.restoreFocusTimeout=setTimeout(()=>{oi(),e()},ni),window.scrollTo(n,o)}),si=`
17
- <div aria-labelledby="${p.title}" aria-describedby="${p["html-container"]}" class="${p.popup}" tabindex="-1">
18
- <button type="button" class="${p.close}"></button>
19
- <ul class="${p["progress-steps"]}"></ul>
20
- <div class="${p.icon}"></div>
21
- <img class="${p.image}" />
22
- <h2 class="${p.title}" id="${p.title}"></h2>
23
- <div class="${p["html-container"]}" id="${p["html-container"]}"></div>
24
- <input class="${p.input}" />
25
- <input type="file" class="${p.file}" />
26
- <div class="${p.range}">
16
+ `,Nn=()=>{const t=Oe(oe().querySelectorAll('[tabindex]:not([tabindex="-1"]):not([tabindex="0"])')).sort((n,r)=>{const o=parseInt(n.getAttribute("tabindex")),i=parseInt(r.getAttribute("tabindex"));return o>i?1:o<i?-1:0}),e=Oe(oe().querySelectorAll(ra)).filter(n=>n.getAttribute("tabindex")!=="-1");return zs(t.concat(e)).filter(n=>Le(n))},Dn=()=>Ge(document.body,g.shown)&&!Ge(document.body,g["toast-shown"])&&!Ge(document.body,g["no-backdrop"]),an=()=>oe()&&Ge(oe(),g.toast),oa=()=>oe().hasAttribute("data-loading"),mt={previousBodyPadding:null},be=(t,e)=>{if(t.textContent="",e){const r=new DOMParser().parseFromString(e,"text/html");Oe(r.querySelector("head").childNodes).forEach(o=>{t.appendChild(o)}),Oe(r.querySelector("body").childNodes).forEach(o=>{t.appendChild(o)})}},Ge=(t,e)=>{if(!e)return!1;const n=e.split(/\s+/);for(let r=0;r<n.length;r++)if(!t.classList.contains(n[r]))return!1;return!0},ia=(t,e)=>{Oe(t.classList).forEach(n=>{!Object.values(g).includes(n)&&!Object.values(xt).includes(n)&&!Object.values(e.showClass).includes(n)&&t.classList.remove(n)})},$e=(t,e,n)=>{if(ia(t,e),e.customClass&&e.customClass[n]){if(typeof e.customClass[n]!="string"&&!e.customClass[n].forEach)return Ae(`Invalid type of customClass.${n}! Expected string or iterable object, got "${typeof e.customClass[n]}"`);ee(t,e.customClass[n])}},Mn=(t,e)=>{if(!e)return null;switch(e){case"select":case"textarea":case"file":return t.querySelector(`.${g.popup} > .${g[e]}`);case"checkbox":return t.querySelector(`.${g.popup} > .${g.checkbox} input`);case"radio":return t.querySelector(`.${g.popup} > .${g.radio} input:checked`)||t.querySelector(`.${g.popup} > .${g.radio} input:first-child`);case"range":return t.querySelector(`.${g.popup} > .${g.range} input`);default:return t.querySelector(`.${g.popup} > .${g.input}`)}},to=t=>{if(t.focus(),t.type!=="file"){const e=t.value;t.value="",t.value=e}},no=(t,e,n)=>{!t||!e||(typeof e=="string"&&(e=e.split(/\s+/).filter(Boolean)),e.forEach(r=>{Array.isArray(t)?t.forEach(o=>{n?o.classList.add(r):o.classList.remove(r)}):n?t.classList.add(r):t.classList.remove(r)}))},ee=(t,e)=>{no(t,e,!0)},Ve=(t,e)=>{no(t,e,!1)},tt=(t,e)=>{const n=Oe(t.childNodes);for(let r=0;r<n.length;r++)if(Ge(n[r],e))return n[r]},Ot=(t,e,n)=>{n===`${parseInt(n)}`&&(n=parseInt(n)),n||parseInt(n)===0?t.style[e]=typeof n=="number"?`${n}px`:n:t.style.removeProperty(e)},he=(t,e="flex")=>{t.style.display=e},ve=t=>{t.style.display="none"},ro=(t,e,n,r)=>{const o=t.querySelector(e);o&&(o.style[n]=r)},ln=(t,e,n)=>{e?he(t,n):ve(t)},Le=t=>!!(t&&(t.offsetWidth||t.offsetHeight||t.getClientRects().length)),sa=()=>!Le(Ue())&&!Le(et())&&!Le(it()),oo=t=>t.scrollHeight>t.clientHeight,io=t=>{const e=window.getComputedStyle(t),n=parseFloat(e.getPropertyValue("animation-duration")||"0"),r=parseFloat(e.getPropertyValue("transition-duration")||"0");return n>0||r>0},Un=(t,e=!1)=>{const n=sn();Le(n)&&(e&&(n.style.transition="none",n.style.width="100%"),setTimeout(()=>{n.style.transition=`width ${t/1e3}s linear`,n.style.width="0%"},10))},aa=()=>{const t=sn(),e=parseInt(window.getComputedStyle(t).width);t.style.removeProperty("transition"),t.style.width="100%";const n=parseInt(window.getComputedStyle(t).width),r=e/n*100;t.style.removeProperty("transition"),t.style.width=`${r}%`},so=()=>typeof window>"u"||typeof document>"u",la=100,J={},ca=()=>{J.previousActiveElement&&J.previousActiveElement.focus?(J.previousActiveElement.focus(),J.previousActiveElement=null):document.body&&document.body.focus()},ua=t=>new Promise(e=>{if(!t)return e();const n=window.scrollX,r=window.scrollY;J.restoreFocusTimeout=setTimeout(()=>{ca(),e()},la),window.scrollTo(n,r)}),da=`
17
+ <div aria-labelledby="${g.title}" aria-describedby="${g["html-container"]}" class="${g.popup}" tabindex="-1">
18
+ <button type="button" class="${g.close}"></button>
19
+ <ul class="${g["progress-steps"]}"></ul>
20
+ <div class="${g.icon}"></div>
21
+ <img class="${g.image}" />
22
+ <h2 class="${g.title}" id="${g.title}"></h2>
23
+ <div class="${g["html-container"]}" id="${g["html-container"]}"></div>
24
+ <input class="${g.input}" />
25
+ <input type="file" class="${g.file}" />
26
+ <div class="${g.range}">
27
27
  <input type="range" />
28
28
  <output></output>
29
29
  </div>
30
- <select class="${p.select}"></select>
31
- <div class="${p.radio}"></div>
32
- <label for="${p.checkbox}" class="${p.checkbox}">
30
+ <select class="${g.select}"></select>
31
+ <div class="${g.radio}"></div>
32
+ <label for="${g.checkbox}" class="${g.checkbox}">
33
33
  <input type="checkbox" />
34
- <span class="${p.label}"></span>
34
+ <span class="${g.label}"></span>
35
35
  </label>
36
- <textarea class="${p.textarea}"></textarea>
37
- <div class="${p["validation-message"]}" id="${p["validation-message"]}"></div>
38
- <div class="${p.actions}">
39
- <div class="${p.loader}"></div>
40
- <button type="button" class="${p.confirm}"></button>
41
- <button type="button" class="${p.deny}"></button>
42
- <button type="button" class="${p.cancel}"></button>
36
+ <textarea class="${g.textarea}"></textarea>
37
+ <div class="${g["validation-message"]}" id="${g["validation-message"]}"></div>
38
+ <div class="${g.actions}">
39
+ <div class="${g.loader}"></div>
40
+ <button type="button" class="${g.confirm}"></button>
41
+ <button type="button" class="${g.deny}"></button>
42
+ <button type="button" class="${g.cancel}"></button>
43
43
  </div>
44
- <div class="${p.footer}"></div>
45
- <div class="${p["timer-progress-bar-container"]}">
46
- <div class="${p["timer-progress-bar"]}"></div>
44
+ <div class="${g.footer}"></div>
45
+ <div class="${g["timer-progress-bar-container"]}">
46
+ <div class="${g["timer-progress-bar"]}"></div>
47
47
  </div>
48
48
  </div>
49
- `.replace(/(^|\n)\s*/g,""),ii=()=>{const t=de();return t?(t.remove(),Me([document.documentElement,document.body],[p["no-backdrop"],p["toast-shown"],p["has-column"]]),!0):!1},et=()=>{q.currentInstance.resetValidationMessage()},ai=()=>{const t=Q(),e=Je(t,p.input),n=Je(t,p.file),o=t.querySelector(`.${p.range} input`),r=t.querySelector(`.${p.range} output`),s=Je(t,p.select),i=t.querySelector(`.${p.checkbox} input`),f=Je(t,p.textarea);e.oninput=et,n.onchange=et,s.onchange=et,i.onchange=et,f.oninput=et,o.oninput=()=>{et(),r.value=o.value},o.onchange=()=>{et(),o.nextSibling.value=o.value}},ci=t=>typeof t=="string"?document.querySelector(t):t,li=t=>{const e=Q();e.setAttribute("role",t.toast?"alert":"dialog"),e.setAttribute("aria-live",t.toast?"polite":"assertive"),t.toast||e.setAttribute("aria-modal","true")},ui=t=>{window.getComputedStyle(t).direction==="rtl"&&Y(de(),p.rtl)},di=t=>{const e=ii();if(Ro()){Ze("SweetAlert2 requires document to initialize");return}const n=document.createElement("div");n.className=p.container,e&&Y(n,p["no-transition"]),fe(n,si);const o=ci(t.target);o.appendChild(n),li(t),ui(o),ai()},Cn=(t,e)=>{t instanceof HTMLElement?e.appendChild(t):typeof t=="object"?fi(t,e):t&&fe(e,t)},fi=(t,e)=>{t.jquery?pi(e,t):fe(e,t.toString())},pi=(t,e)=>{if(t.textContent="",0 in e)for(let n=0;n in e;n++)t.appendChild(e[n].cloneNode(!0));else t.appendChild(e.cloneNode(!0))},_t=(()=>{if(Ro())return!1;const t=document.createElement("div"),e={WebkitAnimation:"webkitAnimationEnd",animation:"animationend"};for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&typeof t.style[n]<"u")return e[n];return!1})(),hi=()=>{const t=document.createElement("div");t.className=p["scrollbar-measure"],document.body.appendChild(t);const e=t.getBoundingClientRect().width-t.clientWidth;return document.body.removeChild(t),e},mi=(t,e)=>{const n=xt(),o=it();!e.showConfirmButton&&!e.showDenyButton&&!e.showCancelButton?pe(n):le(n),Le(n,e,"actions"),gi(n,o,e),fe(o,e.loaderHtml),Le(o,e,"loader")};function gi(t,e,n){const o=Ne(),r=Ge(),s=Qe();xn(o,"confirm",n),xn(r,"deny",n),xn(s,"cancel",n),yi(o,r,s,n),n.reverseButtons&&(n.toast?(t.insertBefore(s,o),t.insertBefore(r,o)):(t.insertBefore(s,e),t.insertBefore(r,e),t.insertBefore(o,e)))}function yi(t,e,n,o){if(!o.buttonsStyling)return Me([t,e,n],p.styled);Y([t,e,n],p.styled),o.confirmButtonColor&&(t.style.backgroundColor=o.confirmButtonColor,Y(t,p["default-outline"])),o.denyButtonColor&&(e.style.backgroundColor=o.denyButtonColor,Y(e,p["default-outline"])),o.cancelButtonColor&&(n.style.backgroundColor=o.cancelButtonColor,Y(n,p["default-outline"]))}function xn(t,e,n){qt(t,n[`show${hn(e)}Button`],"inline-block"),fe(t,n[`${e}ButtonText`]),t.setAttribute("aria-label",n[`${e}ButtonAriaLabel`]),t.className=p[e],Le(t,n,`${e}Button`),Y(t,n[`${e}ButtonClass`])}function bi(t,e){typeof e=="string"?t.style.background=e:e||Y([document.documentElement,document.body],p["no-backdrop"])}function wi(t,e){e in p?Y(t,p[e]):(Ee('The "position" parameter is not valid, defaulting to "center"'),Y(t,p.center))}function Ei(t,e){if(e&&typeof e=="string"){const n=`grow-${e}`;n in p&&Y(t,p[n])}}const Ai=(t,e)=>{const n=de();n&&(bi(n,e.backdrop),wi(n,e.position),Ei(n,e.grow),Le(n,e,"container"))},K={awaitingPromise:new WeakMap,promise:new WeakMap,innerParams:new WeakMap,domCache:new WeakMap},ki=["input","file","range","select","radio","checkbox","textarea"],Ci=(t,e)=>{const n=Q(),o=K.innerParams.get(t),r=!o||e.input!==o.input;ki.forEach(s=>{const i=p[s],f=Je(n,i);_i(s,e.inputAttributes),f.className=i,r&&pe(f)}),e.input&&(r&&xi(e),vi(e))},xi=t=>{if(!Ae[t.input])return Ze(`Unexpected type of input! Expected "text", "email", "password", "number", "tel", "select", "radio", "checkbox", "textarea", "file" or "url", got "${t.input}"`);const e=Lo(t.input),n=Ae[t.input](e,t);le(n),setTimeout(()=>{So(n)})},Si=t=>{for(let e=0;e<t.attributes.length;e++){const n=t.attributes[e].name;["type","value","style"].includes(n)||t.removeAttribute(n)}},_i=(t,e)=>{const n=An(Q(),t);if(n){Si(n);for(const o in e)n.setAttribute(o,e[o])}},vi=t=>{const e=Lo(t.input);t.customClass&&Y(e,t.customClass.input)},Sn=(t,e)=>{(!t.placeholder||e.inputPlaceholder)&&(t.placeholder=e.inputPlaceholder)},vt=(t,e,n)=>{if(n.inputLabel){t.id=p.input;const o=document.createElement("label"),r=p["input-label"];o.setAttribute("for",t.id),o.className=r,Y(o,n.customClass.inputLabel),o.innerText=n.inputLabel,e.insertAdjacentElement("beforebegin",o)}},Lo=t=>{const e=p[t]?p[t]:p.input;return Je(Q(),e)},Ae={};Ae.text=Ae.email=Ae.password=Ae.number=Ae.tel=Ae.url=(t,e)=>(typeof e.inputValue=="string"||typeof e.inputValue=="number"?t.value=e.inputValue:gn(e.inputValue)||Ee(`Unexpected type of inputValue! Expected "string", "number" or "Promise", got "${typeof e.inputValue}"`),vt(t,t,e),Sn(t,e),t.type=e.input,t),Ae.file=(t,e)=>(vt(t,t,e),Sn(t,e),t),Ae.range=(t,e)=>{const n=t.querySelector("input"),o=t.querySelector("output");return n.value=e.inputValue,n.type=e.input,o.value=e.inputValue,vt(n,t,e),t},Ae.select=(t,e)=>{if(t.textContent="",e.inputPlaceholder){const n=document.createElement("option");fe(n,e.inputPlaceholder),n.value="",n.disabled=!0,n.selected=!0,t.appendChild(n)}return vt(t,t,e),t},Ae.radio=t=>(t.textContent="",t),Ae.checkbox=(t,e)=>{const n=An(Q(),"checkbox");n.value="1",n.id=p.checkbox,n.checked=!!e.inputValue;const o=t.querySelector("span");return fe(o,e.inputPlaceholder),t},Ae.textarea=(t,e)=>{t.value=e.inputValue,Sn(t,e),vt(t,t,e);const n=o=>parseInt(window.getComputedStyle(o).marginLeft)+parseInt(window.getComputedStyle(o).marginRight);return setTimeout(()=>{if("MutationObserver"in window){const o=parseInt(window.getComputedStyle(Q()).width),r=()=>{const s=t.offsetWidth+n(t);s>o?Q().style.width=`${s}px`:Q().style.width=null};new MutationObserver(r).observe(t,{attributes:!0,attributeFilter:["style"]})}}),t};const Ti=(t,e)=>{const n=jt();Le(n,e,"htmlContainer"),e.html?(Cn(e.html,n),le(n,"block")):e.text?(n.textContent=e.text,le(n,"block")):pe(n),Ci(t,e)},Pi=(t,e)=>{const n=xo();qt(n,e.footer),e.footer&&Cn(e.footer,n),Le(n,e,"footer")},Ri=(t,e)=>{const n=bn();fe(n,e.closeButtonHtml),Le(n,e,"closeButton"),qt(n,e.showCloseButton),n.setAttribute("aria-label",e.closeButtonAriaLabel)},Li=(t,e)=>{const n=K.innerParams.get(t),o=Ct();if(n&&e.icon===n.icon){Io(o,e),Oo(o,e);return}if(!e.icon&&!e.iconHtml)return pe(o);if(e.icon&&Object.keys(At).indexOf(e.icon)===-1)return Ze(`Unknown icon! Expected "success", "error", "warning", "info" or "question", got "${e.icon}"`),pe(o);le(o),Io(o,e),Oo(o,e),Y(o,e.showClass.icon)},Oo=(t,e)=>{for(const n in At)e.icon!==n&&Me(t,At[n]);Y(t,At[e.icon]),Ni(t,e),Oi(),Le(t,e,"icon")},Oi=()=>{const t=Q(),e=window.getComputedStyle(t).getPropertyValue("background-color"),n=t.querySelectorAll("[class^=swal2-success-circular-line], .swal2-success-fix");for(let o=0;o<n.length;o++)n[o].style.backgroundColor=e},Ii=`
49
+ `.replace(/(^|\n)\s*/g,""),fa=()=>{const t=ye();return t?(t.remove(),Ve([document.documentElement,document.body],[g["no-backdrop"],g["toast-shown"],g["has-column"]]),!0):!1},st=()=>{J.currentInstance.resetValidationMessage()},pa=()=>{const t=oe(),e=tt(t,g.input),n=tt(t,g.file),r=t.querySelector(`.${g.range} input`),o=t.querySelector(`.${g.range} output`),i=tt(t,g.select),s=t.querySelector(`.${g.checkbox} input`),c=tt(t,g.textarea);e.oninput=st,n.onchange=st,i.onchange=st,s.onchange=st,c.oninput=st,r.oninput=()=>{st(),o.value=r.value},r.onchange=()=>{st(),r.nextSibling.value=r.value}},ma=t=>typeof t=="string"?document.querySelector(t):t,ha=t=>{const e=oe();e.setAttribute("role",t.toast?"alert":"dialog"),e.setAttribute("aria-live",t.toast?"polite":"assertive"),t.toast||e.setAttribute("aria-modal","true")},ga=t=>{window.getComputedStyle(t).direction==="rtl"&&ee(ye(),g.rtl)},ya=t=>{const e=fa();if(so()){ot("SweetAlert2 requires document to initialize");return}const n=document.createElement("div");n.className=g.container,e&&ee(n,g["no-transition"]),be(n,da);const r=ma(t.target);r.appendChild(n),ha(t),ga(r),pa()},Hn=(t,e)=>{t instanceof HTMLElement?e.appendChild(t):typeof t=="object"?ba(t,e):t&&be(e,t)},ba=(t,e)=>{t.jquery?va(e,t):be(e,t.toString())},va=(t,e)=>{if(t.textContent="",0 in e)for(let n=0;n in e;n++)t.appendChild(e[n].cloneNode(!0));else t.appendChild(e.cloneNode(!0))},Lt=(()=>{if(so())return!1;const t=document.createElement("div"),e={WebkitAnimation:"webkitAnimationEnd",animation:"animationend"};for(const n in e)if(Object.prototype.hasOwnProperty.call(e,n)&&typeof t.style[n]<"u")return e[n];return!1})(),wa=()=>{const t=document.createElement("div");t.className=g["scrollbar-measure"],document.body.appendChild(t);const e=t.getBoundingClientRect().width-t.clientWidth;return document.body.removeChild(t),e},Ea=(t,e)=>{const n=Tt(),r=pt();!e.showConfirmButton&&!e.showDenyButton&&!e.showCancelButton?ve(n):he(n),$e(n,e,"actions"),Sa(n,r,e),be(r,e.loaderHtml),$e(r,e,"loader")};function Sa(t,e,n){const r=Ue(),o=et(),i=it();jn(r,"confirm",n),jn(o,"deny",n),jn(i,"cancel",n),_a(r,o,i,n),n.reverseButtons&&(n.toast?(t.insertBefore(i,r),t.insertBefore(o,r)):(t.insertBefore(i,e),t.insertBefore(o,e),t.insertBefore(r,e)))}function _a(t,e,n,r){if(!r.buttonsStyling)return Ve([t,e,n],g.styled);ee([t,e,n],g.styled),r.confirmButtonColor&&(t.style.backgroundColor=r.confirmButtonColor,ee(t,g["default-outline"])),r.denyButtonColor&&(e.style.backgroundColor=r.denyButtonColor,ee(e,g["default-outline"])),r.cancelButtonColor&&(n.style.backgroundColor=r.cancelButtonColor,ee(n,g["default-outline"]))}function jn(t,e,n){ln(t,n[`show${Ln(e)}Button`],"inline-block"),be(t,n[`${e}ButtonText`]),t.setAttribute("aria-label",n[`${e}ButtonAriaLabel`]),t.className=g[e],$e(t,n,`${e}Button`),ee(t,n[`${e}ButtonClass`])}function Ca(t,e){typeof e=="string"?t.style.background=e:e||ee([document.documentElement,document.body],g["no-backdrop"])}function Aa(t,e){e in g?ee(t,g[e]):(Ae('The "position" parameter is not valid, defaulting to "center"'),ee(t,g.center))}function ka(t,e){if(e&&typeof e=="string"){const n=`grow-${e}`;n in g&&ee(t,g[n])}}const xa=(t,e)=>{const n=ye();n&&(Ca(n,e.backdrop),Aa(n,e.position),ka(n,e.grow),$e(n,e,"container"))},Y={awaitingPromise:new WeakMap,promise:new WeakMap,innerParams:new WeakMap,domCache:new WeakMap},Ia=["input","file","range","select","radio","checkbox","textarea"],Pa=(t,e)=>{const n=oe(),r=Y.innerParams.get(t),o=!r||e.input!==r.input;Ia.forEach(i=>{const s=g[i],c=tt(n,s);La(i,e.inputAttributes),c.className=s,o&&ve(c)}),e.input&&(o&&Ta(e),Ba(e))},Ta=t=>{if(!ke[t.input])return ot(`Unexpected type of input! Expected "text", "email", "password", "number", "tel", "select", "radio", "checkbox", "textarea", "file" or "url", got "${t.input}"`);const e=ao(t.input),n=ke[t.input](e,t);he(n),setTimeout(()=>{to(n)})},Oa=t=>{for(let e=0;e<t.attributes.length;e++){const n=t.attributes[e].name;["type","value","style"].includes(n)||t.removeAttribute(n)}},La=(t,e)=>{const n=Mn(oe(),t);if(n){Oa(n);for(const r in e)n.setAttribute(r,e[r])}},Ba=t=>{const e=ao(t.input);t.customClass&&ee(e,t.customClass.input)},Vn=(t,e)=>{(!t.placeholder||e.inputPlaceholder)&&(t.placeholder=e.inputPlaceholder)},Bt=(t,e,n)=>{if(n.inputLabel){t.id=g.input;const r=document.createElement("label"),o=g["input-label"];r.setAttribute("for",t.id),r.className=o,ee(r,n.customClass.inputLabel),r.innerText=n.inputLabel,e.insertAdjacentElement("beforebegin",r)}},ao=t=>{const e=g[t]?g[t]:g.input;return tt(oe(),e)},ke={};ke.text=ke.email=ke.password=ke.number=ke.tel=ke.url=(t,e)=>(typeof e.inputValue=="string"||typeof e.inputValue=="number"?t.value=e.inputValue:Rn(e.inputValue)||Ae(`Unexpected type of inputValue! Expected "string", "number" or "Promise", got "${typeof e.inputValue}"`),Bt(t,t,e),Vn(t,e),t.type=e.input,t),ke.file=(t,e)=>(Bt(t,t,e),Vn(t,e),t),ke.range=(t,e)=>{const n=t.querySelector("input"),r=t.querySelector("output");return n.value=e.inputValue,n.type=e.input,r.value=e.inputValue,Bt(n,t,e),t},ke.select=(t,e)=>{if(t.textContent="",e.inputPlaceholder){const n=document.createElement("option");be(n,e.inputPlaceholder),n.value="",n.disabled=!0,n.selected=!0,t.appendChild(n)}return Bt(t,t,e),t},ke.radio=t=>(t.textContent="",t),ke.checkbox=(t,e)=>{const n=Mn(oe(),"checkbox");n.value="1",n.id=g.checkbox,n.checked=!!e.inputValue;const r=t.querySelector("span");return be(r,e.inputPlaceholder),t},ke.textarea=(t,e)=>{t.value=e.inputValue,Vn(t,e),Bt(t,t,e);const n=r=>parseInt(window.getComputedStyle(r).marginLeft)+parseInt(window.getComputedStyle(r).marginRight);return setTimeout(()=>{if("MutationObserver"in window){const r=parseInt(window.getComputedStyle(oe()).width),o=()=>{const i=t.offsetWidth+n(t);i>r?oe().style.width=`${i}px`:oe().style.width=null};new MutationObserver(o).observe(t,{attributes:!0,attributeFilter:["style"]})}}),t};const Ra=(t,e)=>{const n=rn();$e(n,e,"htmlContainer"),e.html?(Hn(e.html,n),he(n,"block")):e.text?(n.textContent=e.text,he(n,"block")):ve(n),Pa(t,e)},Fa=(t,e)=>{const n=eo();ln(n,e.footer),e.footer&&Hn(e.footer,n),$e(n,e,"footer")},$a=(t,e)=>{const n=$n();be(n,e.closeButtonHtml),$e(n,e,"closeButton"),ln(n,e.showCloseButton),n.setAttribute("aria-label",e.closeButtonAriaLabel)},Na=(t,e)=>{const n=Y.innerParams.get(t),r=Pt();if(n&&e.icon===n.icon){co(r,e),lo(r,e);return}if(!e.icon&&!e.iconHtml)return ve(r);if(e.icon&&Object.keys(xt).indexOf(e.icon)===-1)return ot(`Unknown icon! Expected "success", "error", "warning", "info" or "question", got "${e.icon}"`),ve(r);he(r),co(r,e),lo(r,e),ee(r,e.showClass.icon)},lo=(t,e)=>{for(const n in xt)e.icon!==n&&Ve(t,xt[n]);ee(t,xt[e.icon]),Ha(t,e),Da(),$e(t,e,"icon")},Da=()=>{const t=oe(),e=window.getComputedStyle(t).getPropertyValue("background-color"),n=t.querySelectorAll("[class^=swal2-success-circular-line], .swal2-success-fix");for(let r=0;r<n.length;r++)n[r].style.backgroundColor=e},Ma=`
50
50
  <div class="swal2-success-circular-line-left"></div>
51
51
  <span class="swal2-success-line-tip"></span> <span class="swal2-success-line-long"></span>
52
52
  <div class="swal2-success-ring"></div> <div class="swal2-success-fix"></div>
53
53
  <div class="swal2-success-circular-line-right"></div>
54
- `,Bi=`
54
+ `,Ua=`
55
55
  <span class="swal2-x-mark">
56
56
  <span class="swal2-x-mark-line-left"></span>
57
57
  <span class="swal2-x-mark-line-right"></span>
58
58
  </span>
59
- `,Io=(t,e)=>{t.textContent="",e.iconHtml?fe(t,Bo(e.iconHtml)):e.icon==="success"?fe(t,Ii):e.icon==="error"?fe(t,Bi):fe(t,Bo({question:"?",warning:"!",info:"i"}[e.icon]))},Ni=(t,e)=>{if(e.iconColor){t.style.color=e.iconColor,t.style.borderColor=e.iconColor;for(const n of[".swal2-success-line-tip",".swal2-success-line-long",".swal2-x-mark-line-left",".swal2-x-mark-line-right"])vo(t,n,"backgroundColor",e.iconColor);vo(t,".swal2-success-ring","borderColor",e.iconColor)}},Bo=t=>`<div class="${p["icon-content"]}">${t}</div>`,Fi=(t,e)=>{const n=ko();if(!e.imageUrl)return pe(n);le(n,""),n.setAttribute("src",e.imageUrl),n.setAttribute("alt",e.imageAlt),St(n,"width",e.imageWidth),St(n,"height",e.imageHeight),n.className=p.image,Le(n,e,"image")},Ui=t=>{const e=document.createElement("li");return Y(e,p["progress-step"]),fe(e,t),e},Mi=t=>{const e=document.createElement("li");return Y(e,p["progress-step-line"]),t.progressStepsDistance&&(e.style.width=t.progressStepsDistance),e},Di=(t,e)=>{const n=Co();if(!e.progressSteps||e.progressSteps.length===0)return pe(n);le(n),n.textContent="",e.currentProgressStep>=e.progressSteps.length&&Ee("Invalid currentProgressStep parameter, it should be less than progressSteps.length (currentProgressStep like JS arrays starts from 0)"),e.progressSteps.forEach((o,r)=>{const s=Ui(o);if(n.appendChild(s),r===e.currentProgressStep&&Y(s,p["active-progress-step"]),r!==e.progressSteps.length-1){const i=Mi(e);n.appendChild(i)}})},$i=(t,e)=>{const n=Ao();qt(n,e.title||e.titleText,"block"),e.title&&Cn(e.title,n),e.titleText&&(n.innerText=e.titleText),Le(n,e,"title")},Hi=(t,e)=>{const n=de(),o=Q();e.toast?(St(n,"width",e.width),o.style.width="100%",o.insertBefore(it(),Ct())):St(o,"width",e.width),St(o,"padding",e.padding),e.color&&(o.style.color=e.color),e.background&&(o.style.background=e.background),pe(Vt()),ji(o,e)},ji=(t,e)=>{t.className=`${p.popup} ${ve(t)?e.showClass.popup:""}`,e.toast?(Y([document.documentElement,document.body],p["toast-shown"]),Y(t,p.toast)):Y(t,p.modal),Le(t,e,"popup"),typeof e.customClass=="string"&&Y(t,e.customClass),e.icon&&Y(t,p[`icon-${e.icon}`])},No=(t,e)=>{Hi(t,e),Ai(t,e),Di(t,e),Li(t,e),Fi(t,e),$i(t,e),Ri(t,e),Ti(t,e),mi(t,e),Pi(t,e),typeof e.didRender=="function"&&e.didRender(Q())},ct=Object.freeze({cancel:"cancel",backdrop:"backdrop",close:"close",esc:"esc",timer:"timer"}),Vi=()=>{_e(document.body.children).forEach(e=>{e===de()||e.contains(de())||(e.hasAttribute("aria-hidden")&&e.setAttribute("data-previous-aria-hidden",e.getAttribute("aria-hidden")),e.setAttribute("aria-hidden","true"))})},Fo=()=>{_e(document.body.children).forEach(e=>{e.hasAttribute("data-previous-aria-hidden")?(e.setAttribute("aria-hidden",e.getAttribute("data-previous-aria-hidden")),e.removeAttribute("data-previous-aria-hidden")):e.removeAttribute("aria-hidden")})},Uo=["swal-title","swal-html","swal-footer"],zi=t=>{const e=typeof t.template=="string"?document.querySelector(t.template):t.template;if(!e)return{};const n=e.content;return Xi(n),Object.assign(Wi(n),qi(n),Ki(n),Gi(n),Ji(n),Yi(n,Uo))},Wi=t=>{const e={};return _e(t.querySelectorAll("swal-param")).forEach(n=>{tt(n,["name","value"]);const o=n.getAttribute("name"),r=n.getAttribute("value");typeof st[o]=="boolean"&&r==="false"&&(e[o]=!1),typeof st[o]=="object"&&(e[o]=JSON.parse(r))}),e},qi=t=>{const e={};return _e(t.querySelectorAll("swal-button")).forEach(n=>{tt(n,["type","color","aria-label"]);const o=n.getAttribute("type");e[`${o}ButtonText`]=n.innerHTML,e[`show${hn(o)}Button`]=!0,n.hasAttribute("color")&&(e[`${o}ButtonColor`]=n.getAttribute("color")),n.hasAttribute("aria-label")&&(e[`${o}ButtonAriaLabel`]=n.getAttribute("aria-label"))}),e},Ki=t=>{const e={},n=t.querySelector("swal-image");return n&&(tt(n,["src","width","height","alt"]),n.hasAttribute("src")&&(e.imageUrl=n.getAttribute("src")),n.hasAttribute("width")&&(e.imageWidth=n.getAttribute("width")),n.hasAttribute("height")&&(e.imageHeight=n.getAttribute("height")),n.hasAttribute("alt")&&(e.imageAlt=n.getAttribute("alt"))),e},Gi=t=>{const e={},n=t.querySelector("swal-icon");return n&&(tt(n,["type","color"]),n.hasAttribute("type")&&(e.icon=n.getAttribute("type")),n.hasAttribute("color")&&(e.iconColor=n.getAttribute("color")),e.iconHtml=n.innerHTML),e},Ji=t=>{const e={},n=t.querySelector("swal-input");n&&(tt(n,["type","label","placeholder","value"]),e.input=n.getAttribute("type")||"text",n.hasAttribute("label")&&(e.inputLabel=n.getAttribute("label")),n.hasAttribute("placeholder")&&(e.inputPlaceholder=n.getAttribute("placeholder")),n.hasAttribute("value")&&(e.inputValue=n.getAttribute("value")));const o=t.querySelectorAll("swal-input-option");return o.length&&(e.inputOptions={},_e(o).forEach(r=>{tt(r,["value"]);const s=r.getAttribute("value"),i=r.innerHTML;e.inputOptions[s]=i})),e},Yi=(t,e)=>{const n={};for(const o in e){const r=e[o],s=t.querySelector(r);s&&(tt(s,[]),n[r.replace(/^swal-/,"")]=s.innerHTML.trim())}return n},Xi=t=>{const e=Uo.concat(["swal-param","swal-button","swal-image","swal-icon","swal-input","swal-input-option"]);_e(t.children).forEach(n=>{const o=n.tagName.toLowerCase();e.indexOf(o)===-1&&Ee(`Unrecognized element <${o}>`)})},tt=(t,e)=>{_e(t.attributes).forEach(n=>{e.indexOf(n.name)===-1&&Ee([`Unrecognized attribute "${n.name}" on <${t.tagName.toLowerCase()}>.`,`${e.length?`Allowed attributes are: ${e.join(", ")}`:"To set the value, use HTML within the element."}`])})},Mo={email:(t,e)=>/^[a-zA-Z0-9.+_-]+@[a-zA-Z0-9.-]+\.[a-zA-Z0-9-]{2,24}$/.test(t)?Promise.resolve():Promise.resolve(e||"Invalid email address"),url:(t,e)=>/^https?:\/\/(www\.)?[-a-zA-Z0-9@:%._+~#=]{1,256}\.[a-z]{2,63}\b([-a-zA-Z0-9@:%_+.~#?&/=]*)$/.test(t)?Promise.resolve():Promise.resolve(e||"Invalid URL")};function Zi(t){t.inputValidator||Object.keys(Mo).forEach(e=>{t.input===e&&(t.inputValidator=Mo[e])})}function Qi(t){(!t.target||typeof t.target=="string"&&!document.querySelector(t.target)||typeof t.target!="string"&&!t.target.appendChild)&&(Ee('Target parameter is not valid, defaulting to "body"'),t.target="body")}function ea(t){Zi(t),t.showLoaderOnConfirm&&!t.preConfirm&&Ee(`showLoaderOnConfirm is set to true, but preConfirm is not defined.
59
+ `,co=(t,e)=>{t.textContent="",e.iconHtml?be(t,uo(e.iconHtml)):e.icon==="success"?be(t,Ma):e.icon==="error"?be(t,Ua):be(t,uo({question:"?",warning:"!",info:"i"}[e.icon]))},Ha=(t,e)=>{if(e.iconColor){t.style.color=e.iconColor,t.style.borderColor=e.iconColor;for(const n of[".swal2-success-line-tip",".swal2-success-line-long",".swal2-x-mark-line-left",".swal2-x-mark-line-right"])ro(t,n,"backgroundColor",e.iconColor);ro(t,".swal2-success-ring","borderColor",e.iconColor)}},uo=t=>`<div class="${g["icon-content"]}">${t}</div>`,ja=(t,e)=>{const n=Zr();if(!e.imageUrl)return ve(n);he(n,""),n.setAttribute("src",e.imageUrl),n.setAttribute("alt",e.imageAlt),Ot(n,"width",e.imageWidth),Ot(n,"height",e.imageHeight),n.className=g.image,$e(n,e,"image")},Va=t=>{const e=document.createElement("li");return ee(e,g["progress-step"]),be(e,t),e},Ka=t=>{const e=document.createElement("li");return ee(e,g["progress-step-line"]),t.progressStepsDistance&&(e.style.width=t.progressStepsDistance),e},za=(t,e)=>{const n=Qr();if(!e.progressSteps||e.progressSteps.length===0)return ve(n);he(n),n.textContent="",e.currentProgressStep>=e.progressSteps.length&&Ae("Invalid currentProgressStep parameter, it should be less than progressSteps.length (currentProgressStep like JS arrays starts from 0)"),e.progressSteps.forEach((r,o)=>{const i=Va(r);if(n.appendChild(i),o===e.currentProgressStep&&ee(i,g["active-progress-step"]),o!==e.progressSteps.length-1){const s=Ka(e);n.appendChild(s)}})},Wa=(t,e)=>{const n=Xr();ln(n,e.title||e.titleText,"block"),e.title&&Hn(e.title,n),e.titleText&&(n.innerText=e.titleText),$e(n,e,"title")},qa=(t,e)=>{const n=ye(),r=oe();e.toast?(Ot(n,"width",e.width),r.style.width="100%",r.insertBefore(pt(),Pt())):Ot(r,"width",e.width),Ot(r,"padding",e.padding),e.color&&(r.style.color=e.color),e.background&&(r.style.background=e.background),ve(on()),Ga(r,e)},Ga=(t,e)=>{t.className=`${g.popup} ${Le(t)?e.showClass.popup:""}`,e.toast?(ee([document.documentElement,document.body],g["toast-shown"]),ee(t,g.toast)):ee(t,g.modal),$e(t,e,"popup"),typeof e.customClass=="string"&&ee(t,e.customClass),e.icon&&ee(t,g[`icon-${e.icon}`])},fo=(t,e)=>{qa(t,e),xa(t,e),za(t,e),Na(t,e),ja(t,e),Wa(t,e),$a(t,e),Ra(t,e),Ea(t,e),Fa(t,e),typeof e.didRender=="function"&&e.didRender(oe())},ht=Object.freeze({cancel:"cancel",backdrop:"backdrop",close:"close",esc:"esc",timer:"timer"}),Ja=()=>{Oe(document.body.children).forEach(e=>{e===ye()||e.contains(ye())||(e.hasAttribute("aria-hidden")&&e.setAttribute("data-previous-aria-hidden",e.getAttribute("aria-hidden")),e.setAttribute("aria-hidden","true"))})},po=()=>{Oe(document.body.children).forEach(e=>{e.hasAttribute("data-previous-aria-hidden")?(e.setAttribute("aria-hidden",e.getAttribute("data-previous-aria-hidden")),e.removeAttribute("data-previous-aria-hidden")):e.removeAttribute("aria-hidden")})},mo=["swal-title","swal-html","swal-footer"],Ya=t=>{const e=typeof t.template=="string"?document.querySelector(t.template):t.template;if(!e)return{};const n=e.content;return rl(n),Object.assign(Xa(n),Za(n),Qa(n),el(n),tl(n),nl(n,mo))},Xa=t=>{const e={};return Oe(t.querySelectorAll("swal-param")).forEach(n=>{at(n,["name","value"]);const r=n.getAttribute("name"),o=n.getAttribute("value");typeof ft[r]=="boolean"&&o==="false"&&(e[r]=!1),typeof ft[r]=="object"&&(e[r]=JSON.parse(o))}),e},Za=t=>{const e={};return Oe(t.querySelectorAll("swal-button")).forEach(n=>{at(n,["type","color","aria-label"]);const r=n.getAttribute("type");e[`${r}ButtonText`]=n.innerHTML,e[`show${Ln(r)}Button`]=!0,n.hasAttribute("color")&&(e[`${r}ButtonColor`]=n.getAttribute("color")),n.hasAttribute("aria-label")&&(e[`${r}ButtonAriaLabel`]=n.getAttribute("aria-label"))}),e},Qa=t=>{const e={},n=t.querySelector("swal-image");return n&&(at(n,["src","width","height","alt"]),n.hasAttribute("src")&&(e.imageUrl=n.getAttribute("src")),n.hasAttribute("width")&&(e.imageWidth=n.getAttribute("width")),n.hasAttribute("height")&&(e.imageHeight=n.getAttribute("height")),n.hasAttribute("alt")&&(e.imageAlt=n.getAttribute("alt"))),e},el=t=>{const e={},n=t.querySelector("swal-icon");return n&&(at(n,["type","color"]),n.hasAttribute("type")&&(e.icon=n.getAttribute("type")),n.hasAttribute("color")&&(e.iconColor=n.getAttribute("color")),e.iconHtml=n.innerHTML),e},tl=t=>{const e={},n=t.querySelector("swal-input");n&&(at(n,["type","label","placeholder","value"]),e.input=n.getAttribute("type")||"text",n.hasAttribute("label")&&(e.inputLabel=n.getAttribute("label")),n.hasAttribute("placeholder")&&(e.inputPlaceholder=n.getAttribute("placeholder")),n.hasAttribute("value")&&(e.inputValue=n.getAttribute("value")));const r=t.querySelectorAll("swal-input-option");return r.length&&(e.inputOptions={},Oe(r).forEach(o=>{at(o,["value"]);const i=o.getAttribute("value"),s=o.innerHTML;e.inputOptions[i]=s})),e},nl=(t,e)=>{const n={};for(const r in e){const o=e[r],i=t.querySelector(o);i&&(at(i,[]),n[o.replace(/^swal-/,"")]=i.innerHTML.trim())}return n},rl=t=>{const e=mo.concat(["swal-param","swal-button","swal-image","swal-icon","swal-input","swal-input-option"]);Oe(t.children).forEach(n=>{const r=n.tagName.toLowerCase();e.indexOf(r)===-1&&Ae(`Unrecognized element <${r}>`)})},at=(t,e)=>{Oe(t.attributes).forEach(n=>{e.indexOf(n.name)===-1&&Ae([`Unrecognized attribute "${n.name}" on <${t.tagName.toLowerCase()}>.`,`${e.length?`Allowed attributes are: ${e.join(", ")}`:"To set the value, use HTML within the element."}`])})},ho={email:(t,e)=>/^[a-zA-Z0-9.+_-]+@[a-zA-Z0-9.-]+\.[a-zA-Z0-9-]{2,24}$/.test(t)?Promise.resolve():Promise.resolve(e||"Invalid email address"),url:(t,e)=>/^https?:\/\/(www\.)?[-a-zA-Z0-9@:%._+~#=]{1,256}\.[a-z]{2,63}\b([-a-zA-Z0-9@:%_+.~#?&/=]*)$/.test(t)?Promise.resolve():Promise.resolve(e||"Invalid URL")};function ol(t){t.inputValidator||Object.keys(ho).forEach(e=>{t.input===e&&(t.inputValidator=ho[e])})}function il(t){(!t.target||typeof t.target=="string"&&!document.querySelector(t.target)||typeof t.target!="string"&&!t.target.appendChild)&&(Ae('Target parameter is not valid, defaulting to "body"'),t.target="body")}function sl(t){ol(t),t.showLoaderOnConfirm&&!t.preConfirm&&Ae(`showLoaderOnConfirm is set to true, but preConfirm is not defined.
60
60
  showLoaderOnConfirm should be used together with preConfirm, see usage example:
61
- https://sweetalert2.github.io/#ajax-request`),Qi(t),typeof t.title=="string"&&(t.title=t.title.split(`
62
- `).join("<br />")),di(t)}class ta{constructor(e,n){this.callback=e,this.remaining=n,this.running=!1,this.start()}start(){return this.running||(this.running=!0,this.started=new Date,this.id=setTimeout(this.callback,this.remaining)),this.remaining}stop(){return this.running&&(this.running=!1,clearTimeout(this.id),this.remaining-=new Date().getTime()-this.started.getTime()),this.remaining}increase(e){const n=this.running;return n&&this.stop(),this.remaining+=e,n&&this.start(),this.remaining}getTimerLeft(){return this.running&&(this.stop(),this.start()),this.remaining}isRunning(){return this.running}}const na=()=>{at.previousBodyPadding===null&&document.body.scrollHeight>window.innerHeight&&(at.previousBodyPadding=parseInt(window.getComputedStyle(document.body).getPropertyValue("padding-right")),document.body.style.paddingRight=`${at.previousBodyPadding+hi()}px`)},oa=()=>{at.previousBodyPadding!==null&&(document.body.style.paddingRight=`${at.previousBodyPadding}px`,at.previousBodyPadding=null)},ra=()=>{if((/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream||navigator.platform==="MacIntel"&&navigator.maxTouchPoints>1)&&!Ve(document.body,p.iosfix)){const e=document.body.scrollTop;document.body.style.top=`${e*-1}px`,Y(document.body,p.iosfix),ia(),sa()}},sa=()=>{const t=navigator.userAgent,e=!!t.match(/iPad/i)||!!t.match(/iPhone/i),n=!!t.match(/WebKit/i);e&&n&&!t.match(/CriOS/i)&&Q().scrollHeight>window.innerHeight-44&&(de().style.paddingBottom="44px")},ia=()=>{const t=de();let e;t.ontouchstart=n=>{e=aa(n)},t.ontouchmove=n=>{e&&(n.preventDefault(),n.stopPropagation())}},aa=t=>{const e=t.target,n=de();return ca(t)||la(t)?!1:e===n||!To(n)&&e.tagName!=="INPUT"&&e.tagName!=="TEXTAREA"&&!(To(jt())&&jt().contains(e))},ca=t=>t.touches&&t.touches.length&&t.touches[0].touchType==="stylus",la=t=>t.touches&&t.touches.length>1,ua=()=>{if(Ve(document.body,p.iosfix)){const t=parseInt(document.body.style.top,10);Me(document.body,p.iosfix),document.body.style.top="",document.body.scrollTop=t*-1}},Do=10,da=t=>{const e=de(),n=Q();typeof t.willOpen=="function"&&t.willOpen(n);const r=window.getComputedStyle(document.body).overflowY;ha(e,n,t),setTimeout(()=>{fa(e,n)},Do),En()&&(pa(e,t.scrollbarPadding,r),Vi()),!Wt()&&!q.previousActiveElement&&(q.previousActiveElement=document.activeElement),typeof t.didOpen=="function"&&setTimeout(()=>t.didOpen(n)),Me(e,p["no-transition"])},$o=t=>{const e=Q();if(t.target!==e)return;const n=de();e.removeEventListener(_t,$o),n.style.overflowY="auto"},fa=(t,e)=>{_t&&Po(e)?(t.style.overflowY="hidden",e.addEventListener(_t,$o)):t.style.overflowY="auto"},pa=(t,e,n)=>{ra(),e&&n!=="hidden"&&na(),setTimeout(()=>{t.scrollTop=0})},ha=(t,e,n)=>{Y(t,n.showClass.backdrop),e.style.setProperty("opacity","0","important"),le(e,"grid"),setTimeout(()=>{Y(e,n.showClass.popup),e.style.removeProperty("opacity")},Do),Y([document.documentElement,document.body],p.shown),n.heightAuto&&n.backdrop&&!n.toast&&Y([document.documentElement,document.body],p["height-auto"])},lt=t=>{let e=Q();e||new dt,e=Q();const n=it();Wt()?pe(Ct()):ma(e,t),le(n),e.setAttribute("data-loading",!0),e.setAttribute("aria-busy",!0),e.focus()},ma=(t,e)=>{const n=xt(),o=it();!e&&ve(Ne())&&(e=Ne()),le(n),e&&(pe(e),o.setAttribute("data-button-to-replace",e.className)),o.parentNode.insertBefore(o,e),Y([t,n],p.loading)},ga=(t,e)=>{e.input==="select"||e.input==="radio"?Aa(t,e):["text","email","number","tel","textarea"].includes(e.input)&&(mn(e.inputValue)||gn(e.inputValue))&&(lt(Ne()),ka(t,e))},ya=(t,e)=>{const n=t.getInput();if(!n)return null;switch(e.input){case"checkbox":return ba(n);case"radio":return wa(n);case"file":return Ea(n);default:return e.inputAutoTrim?n.value.trim():n.value}},ba=t=>t.checked?1:0,wa=t=>t.checked?t.value:null,Ea=t=>t.files.length?t.getAttribute("multiple")!==null?t.files:t.files[0]:null,Aa=(t,e)=>{const n=Q(),o=r=>Ca[e.input](n,_n(r),e);mn(e.inputOptions)||gn(e.inputOptions)?(lt(Ne()),Et(e.inputOptions).then(r=>{t.hideLoading(),o(r)})):typeof e.inputOptions=="object"?o(e.inputOptions):Ze(`Unexpected type of inputOptions! Expected object, Map or Promise, got ${typeof e.inputOptions}`)},ka=(t,e)=>{const n=t.getInput();pe(n),Et(e.inputValue).then(o=>{n.value=e.input==="number"?parseFloat(o)||0:`${o}`,le(n),n.focus(),t.hideLoading()}).catch(o=>{Ze(`Error in inputValue promise: ${o}`),n.value="",le(n),n.focus(),t.hideLoading()})},Ca={select:(t,e,n)=>{const o=Je(t,p.select),r=(s,i,f)=>{const u=document.createElement("option");u.value=f,fe(u,i),u.selected=Ho(f,n.inputValue),s.appendChild(u)};e.forEach(s=>{const i=s[0],f=s[1];if(Array.isArray(f)){const u=document.createElement("optgroup");u.label=i,u.disabled=!1,o.appendChild(u),f.forEach(w=>r(u,w[1],w[0]))}else r(o,f,i)}),o.focus()},radio:(t,e,n)=>{const o=Je(t,p.radio);e.forEach(s=>{const i=s[0],f=s[1],u=document.createElement("input"),w=document.createElement("label");u.type="radio",u.name=p.radio,u.value=i,Ho(i,n.inputValue)&&(u.checked=!0);const E=document.createElement("span");fe(E,f),E.className=p.label,w.appendChild(u),w.appendChild(E),o.appendChild(w)});const r=o.querySelectorAll("input");r.length&&r[0].focus()}},_n=t=>{const e=[];return typeof Map<"u"&&t instanceof Map?t.forEach((n,o)=>{let r=n;typeof r=="object"&&(r=_n(r)),e.push([o,r])}):Object.keys(t).forEach(n=>{let o=t[n];typeof o=="object"&&(o=_n(o)),e.push([n,o])}),e},Ho=(t,e)=>e&&e.toString()===t.toString();function jo(){const t=K.innerParams.get(this);if(!t)return;const e=K.domCache.get(this);pe(e.loader),Wt()?t.icon&&le(Ct()):xa(e),Me([e.popup,e.actions],p.loading),e.popup.removeAttribute("aria-busy"),e.popup.removeAttribute("data-loading"),e.confirmButton.disabled=!1,e.denyButton.disabled=!1,e.cancelButton.disabled=!1}const xa=t=>{const e=t.popup.getElementsByClassName(t.loader.getAttribute("data-button-to-replace"));e.length?le(e[0],"inline-block"):ei()&&pe(t.actions)};function Sa(t){const e=K.innerParams.get(t||this),n=K.domCache.get(t||this);return n?An(n.popup,e.input):null}const Tt={swalPromiseResolve:new WeakMap,swalPromiseReject:new WeakMap},_a=()=>ve(Q()),Vo=()=>Ne()&&Ne().click(),va=()=>Ge()&&Ge().click(),Ta=()=>Qe()&&Qe().click(),zo=t=>{t.keydownTarget&&t.keydownHandlerAdded&&(t.keydownTarget.removeEventListener("keydown",t.keydownHandler,{capture:t.keydownListenerCapture}),t.keydownHandlerAdded=!1)},Pa=(t,e,n,o)=>{zo(e),n.toast||(e.keydownHandler=r=>La(t,r,o),e.keydownTarget=n.keydownListenerCapture?window:Q(),e.keydownListenerCapture=n.keydownListenerCapture,e.keydownTarget.addEventListener("keydown",e.keydownHandler,{capture:e.keydownListenerCapture}),e.keydownHandlerAdded=!0)},vn=(t,e,n)=>{const o=wn();if(o.length)return e=e+n,e===o.length?e=0:e===-1&&(e=o.length-1),o[e].focus();Q().focus()},Wo=["ArrowRight","ArrowDown"],Ra=["ArrowLeft","ArrowUp"],La=(t,e,n)=>{const o=K.innerParams.get(t);o&&(e.isComposing||e.keyCode===229||(o.stopKeydownPropagation&&e.stopPropagation(),e.key==="Enter"?Oa(t,e,o):e.key==="Tab"?Ia(e,o):[...Wo,...Ra].includes(e.key)?Ba(e.key):e.key==="Escape"&&Na(e,o,n)))},Oa=(t,e,n)=>{if(Ht(n.allowEnterKey)&&e.target&&t.getInput()&&e.target.outerHTML===t.getInput().outerHTML){if(["textarea","file"].includes(n.input))return;Vo(),e.preventDefault()}},Ia=(t,e)=>{const n=t.target,o=wn();let r=-1;for(let s=0;s<o.length;s++)if(n===o[s]){r=s;break}t.shiftKey?vn(e,r,-1):vn(e,r,1),t.stopPropagation(),t.preventDefault()},Ba=t=>{const e=Ne(),n=Ge(),o=Qe();if(![e,n,o].includes(document.activeElement))return;const r=Wo.includes(t)?"nextElementSibling":"previousElementSibling";let s=document.activeElement;for(let i=0;i<xt().children.length;i++){if(s=s[r],!s)return;if(ve(s)&&s instanceof HTMLButtonElement)break}s instanceof HTMLButtonElement&&s.focus()},Na=(t,e,n)=>{Ht(e.allowEscapeKey)&&(t.preventDefault(),n(ct.esc))};function qo(t,e,n,o){Wt()?Ko(t,o):(ri(n).then(()=>Ko(t,o)),zo(q)),/^((?!chrome|android).)*safari/i.test(navigator.userAgent)?(e.setAttribute("style","display:none !important"),e.removeAttribute("class"),e.innerHTML=""):e.remove(),En()&&(oa(),ua(),Fo()),Fa()}function Fa(){Me([document.documentElement,document.body],[p.shown,p["height-auto"],p["no-backdrop"],p["toast-shown"]])}function Kt(t){t=$a(t);const e=Tt.swalPromiseResolve.get(this),n=Ma(this);this.isAwaitingPromise()?t.isDismissed||(Pt(this),e(t)):n&&e(t)}function Ua(){return!!K.awaitingPromise.get(this)}const Ma=t=>{const e=Q();if(!e)return!1;const n=K.innerParams.get(t);if(!n||Ve(e,n.hideClass.popup))return!1;Me(e,n.showClass.popup),Y(e,n.hideClass.popup);const o=de();return Me(o,n.showClass.backdrop),Y(o,n.hideClass.backdrop),Ha(t,e,n),!0};function Da(t){const e=Tt.swalPromiseReject.get(this);Pt(this),e&&e(t)}const Pt=t=>{t.isAwaitingPromise()&&(K.awaitingPromise.delete(t),K.innerParams.get(t)||t._destroy())},$a=t=>typeof t>"u"?{isConfirmed:!1,isDenied:!1,isDismissed:!0}:Object.assign({isConfirmed:!1,isDenied:!1,isDismissed:!1},t),Ha=(t,e,n)=>{const o=de(),r=_t&&Po(e);typeof n.willClose=="function"&&n.willClose(e),r?ja(t,e,o,n.returnFocus,n.didClose):qo(t,o,n.returnFocus,n.didClose)},ja=(t,e,n,o,r)=>{q.swalCloseEventFinishedCallback=qo.bind(null,t,n,o,r),e.addEventListener(_t,function(s){s.target===e&&(q.swalCloseEventFinishedCallback(),delete q.swalCloseEventFinishedCallback)})},Ko=(t,e)=>{setTimeout(()=>{typeof e=="function"&&e.bind(t.params)(),t._destroy()})};function Go(t,e,n){const o=K.domCache.get(t);e.forEach(r=>{o[r].disabled=n})}function Jo(t,e){if(!t)return!1;if(t.type==="radio"){const o=t.parentNode.parentNode.querySelectorAll("input");for(let r=0;r<o.length;r++)o[r].disabled=e}else t.disabled=e}function Va(){Go(this,["confirmButton","denyButton","cancelButton"],!1)}function za(){Go(this,["confirmButton","denyButton","cancelButton"],!0)}function Wa(){return Jo(this.getInput(),!1)}function qa(){return Jo(this.getInput(),!0)}function Ka(t){const e=K.domCache.get(this),n=K.innerParams.get(this);fe(e.validationMessage,t),e.validationMessage.className=p["validation-message"],n.customClass&&n.customClass.validationMessage&&Y(e.validationMessage,n.customClass.validationMessage),le(e.validationMessage);const o=this.getInput();o&&(o.setAttribute("aria-invalid",!0),o.setAttribute("aria-describedby",p["validation-message"]),So(o),Y(o,p.inputerror))}function Ga(){const t=K.domCache.get(this);t.validationMessage&&pe(t.validationMessage);const e=this.getInput();e&&(e.removeAttribute("aria-invalid"),e.removeAttribute("aria-describedby"),Me(e,p.inputerror))}function Ja(){return K.domCache.get(this).progressSteps}function Ya(t){const e=Q(),n=K.innerParams.get(this);if(!e||Ve(e,n.hideClass.popup))return Ee("You're trying to update the closed or closing popup, that won't work. Use the update() method in preConfirm parameter or show a new popup.");const o=Xa(t),r=Object.assign({},n,o);No(this,r),K.innerParams.set(this,r),Object.defineProperties(this,{params:{value:Object.assign({},this.params,t),writable:!1,enumerable:!0}})}const Xa=t=>{const e={};return Object.keys(t).forEach(n=>{wo(n)?e[n]=t[n]:Ee(`Invalid parameter to update: "${n}". Updatable params are listed here: https://github.com/sweetalert2/sweetalert2/blob/master/src/utils/params.js
61
+ https://sweetalert2.github.io/#ajax-request`),il(t),typeof t.title=="string"&&(t.title=t.title.split(`
62
+ `).join("<br />")),ya(t)}class al{constructor(e,n){this.callback=e,this.remaining=n,this.running=!1,this.start()}start(){return this.running||(this.running=!0,this.started=new Date,this.id=setTimeout(this.callback,this.remaining)),this.remaining}stop(){return this.running&&(this.running=!1,clearTimeout(this.id),this.remaining-=new Date().getTime()-this.started.getTime()),this.remaining}increase(e){const n=this.running;return n&&this.stop(),this.remaining+=e,n&&this.start(),this.remaining}getTimerLeft(){return this.running&&(this.stop(),this.start()),this.remaining}isRunning(){return this.running}}const ll=()=>{mt.previousBodyPadding===null&&document.body.scrollHeight>window.innerHeight&&(mt.previousBodyPadding=parseInt(window.getComputedStyle(document.body).getPropertyValue("padding-right")),document.body.style.paddingRight=`${mt.previousBodyPadding+wa()}px`)},cl=()=>{mt.previousBodyPadding!==null&&(document.body.style.paddingRight=`${mt.previousBodyPadding}px`,mt.previousBodyPadding=null)},ul=()=>{if((/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream||navigator.platform==="MacIntel"&&navigator.maxTouchPoints>1)&&!Ge(document.body,g.iosfix)){const e=document.body.scrollTop;document.body.style.top=`${e*-1}px`,ee(document.body,g.iosfix),fl(),dl()}},dl=()=>{const t=navigator.userAgent,e=!!t.match(/iPad/i)||!!t.match(/iPhone/i),n=!!t.match(/WebKit/i);e&&n&&!t.match(/CriOS/i)&&oe().scrollHeight>window.innerHeight-44&&(ye().style.paddingBottom="44px")},fl=()=>{const t=ye();let e;t.ontouchstart=n=>{e=pl(n)},t.ontouchmove=n=>{e&&(n.preventDefault(),n.stopPropagation())}},pl=t=>{const e=t.target,n=ye();return ml(t)||hl(t)?!1:e===n||!oo(n)&&e.tagName!=="INPUT"&&e.tagName!=="TEXTAREA"&&!(oo(rn())&&rn().contains(e))},ml=t=>t.touches&&t.touches.length&&t.touches[0].touchType==="stylus",hl=t=>t.touches&&t.touches.length>1,gl=()=>{if(Ge(document.body,g.iosfix)){const t=parseInt(document.body.style.top,10);Ve(document.body,g.iosfix),document.body.style.top="",document.body.scrollTop=t*-1}},go=10,yl=t=>{const e=ye(),n=oe();typeof t.willOpen=="function"&&t.willOpen(n);const o=window.getComputedStyle(document.body).overflowY;wl(e,n,t),setTimeout(()=>{bl(e,n)},go),Dn()&&(vl(e,t.scrollbarPadding,o),Ja()),!an()&&!J.previousActiveElement&&(J.previousActiveElement=document.activeElement),typeof t.didOpen=="function"&&setTimeout(()=>t.didOpen(n)),Ve(e,g["no-transition"])},yo=t=>{const e=oe();if(t.target!==e)return;const n=ye();e.removeEventListener(Lt,yo),n.style.overflowY="auto"},bl=(t,e)=>{Lt&&io(e)?(t.style.overflowY="hidden",e.addEventListener(Lt,yo)):t.style.overflowY="auto"},vl=(t,e,n)=>{ul(),e&&n!=="hidden"&&ll(),setTimeout(()=>{t.scrollTop=0})},wl=(t,e,n)=>{ee(t,n.showClass.backdrop),e.style.setProperty("opacity","0","important"),he(e,"grid"),setTimeout(()=>{ee(e,n.showClass.popup),e.style.removeProperty("opacity")},go),ee([document.documentElement,document.body],g.shown),n.heightAuto&&n.backdrop&&!n.toast&&ee([document.documentElement,document.body],g["height-auto"])},gt=t=>{let e=oe();e||new bt,e=oe();const n=pt();an()?ve(Pt()):El(e,t),he(n),e.setAttribute("data-loading",!0),e.setAttribute("aria-busy",!0),e.focus()},El=(t,e)=>{const n=Tt(),r=pt();!e&&Le(Ue())&&(e=Ue()),he(n),e&&(ve(e),r.setAttribute("data-button-to-replace",e.className)),r.parentNode.insertBefore(r,e),ee([t,n],g.loading)},Sl=(t,e)=>{e.input==="select"||e.input==="radio"?xl(t,e):["text","email","number","tel","textarea"].includes(e.input)&&(Bn(e.inputValue)||Rn(e.inputValue))&&(gt(Ue()),Il(t,e))},_l=(t,e)=>{const n=t.getInput();if(!n)return null;switch(e.input){case"checkbox":return Cl(n);case"radio":return Al(n);case"file":return kl(n);default:return e.inputAutoTrim?n.value.trim():n.value}},Cl=t=>t.checked?1:0,Al=t=>t.checked?t.value:null,kl=t=>t.files.length?t.getAttribute("multiple")!==null?t.files:t.files[0]:null,xl=(t,e)=>{const n=oe(),r=o=>Pl[e.input](n,Kn(o),e);Bn(e.inputOptions)||Rn(e.inputOptions)?(gt(Ue()),kt(e.inputOptions).then(o=>{t.hideLoading(),r(o)})):typeof e.inputOptions=="object"?r(e.inputOptions):ot(`Unexpected type of inputOptions! Expected object, Map or Promise, got ${typeof e.inputOptions}`)},Il=(t,e)=>{const n=t.getInput();ve(n),kt(e.inputValue).then(r=>{n.value=e.input==="number"?parseFloat(r)||0:`${r}`,he(n),n.focus(),t.hideLoading()}).catch(r=>{ot(`Error in inputValue promise: ${r}`),n.value="",he(n),n.focus(),t.hideLoading()})},Pl={select:(t,e,n)=>{const r=tt(t,g.select),o=(i,s,c)=>{const a=document.createElement("option");a.value=c,be(a,s),a.selected=bo(c,n.inputValue),i.appendChild(a)};e.forEach(i=>{const s=i[0],c=i[1];if(Array.isArray(c)){const a=document.createElement("optgroup");a.label=s,a.disabled=!1,r.appendChild(a),c.forEach(u=>o(a,u[1],u[0]))}else o(r,c,s)}),r.focus()},radio:(t,e,n)=>{const r=tt(t,g.radio);e.forEach(i=>{const s=i[0],c=i[1],a=document.createElement("input"),u=document.createElement("label");a.type="radio",a.name=g.radio,a.value=s,bo(s,n.inputValue)&&(a.checked=!0);const f=document.createElement("span");be(f,c),f.className=g.label,u.appendChild(a),u.appendChild(f),r.appendChild(u)});const o=r.querySelectorAll("input");o.length&&o[0].focus()}},Kn=t=>{const e=[];return typeof Map<"u"&&t instanceof Map?t.forEach((n,r)=>{let o=n;typeof o=="object"&&(o=Kn(o)),e.push([r,o])}):Object.keys(t).forEach(n=>{let r=t[n];typeof r=="object"&&(r=Kn(r)),e.push([n,r])}),e},bo=(t,e)=>e&&e.toString()===t.toString();function vo(){const t=Y.innerParams.get(this);if(!t)return;const e=Y.domCache.get(this);ve(e.loader),an()?t.icon&&he(Pt()):Tl(e),Ve([e.popup,e.actions],g.loading),e.popup.removeAttribute("aria-busy"),e.popup.removeAttribute("data-loading"),e.confirmButton.disabled=!1,e.denyButton.disabled=!1,e.cancelButton.disabled=!1}const Tl=t=>{const e=t.popup.getElementsByClassName(t.loader.getAttribute("data-button-to-replace"));e.length?he(e[0],"inline-block"):sa()&&ve(t.actions)};function Ol(t){const e=Y.innerParams.get(t||this),n=Y.domCache.get(t||this);return n?Mn(n.popup,e.input):null}const Rt={swalPromiseResolve:new WeakMap,swalPromiseReject:new WeakMap},Ll=()=>Le(oe()),wo=()=>Ue()&&Ue().click(),Bl=()=>et()&&et().click(),Rl=()=>it()&&it().click(),Eo=t=>{t.keydownTarget&&t.keydownHandlerAdded&&(t.keydownTarget.removeEventListener("keydown",t.keydownHandler,{capture:t.keydownListenerCapture}),t.keydownHandlerAdded=!1)},Fl=(t,e,n,r)=>{Eo(e),n.toast||(e.keydownHandler=o=>Nl(t,o,r),e.keydownTarget=n.keydownListenerCapture?window:oe(),e.keydownListenerCapture=n.keydownListenerCapture,e.keydownTarget.addEventListener("keydown",e.keydownHandler,{capture:e.keydownListenerCapture}),e.keydownHandlerAdded=!0)},zn=(t,e,n)=>{const r=Nn();if(r.length)return e=e+n,e===r.length?e=0:e===-1&&(e=r.length-1),r[e].focus();oe().focus()},So=["ArrowRight","ArrowDown"],$l=["ArrowLeft","ArrowUp"],Nl=(t,e,n)=>{const r=Y.innerParams.get(t);r&&(e.isComposing||e.keyCode===229||(r.stopKeydownPropagation&&e.stopPropagation(),e.key==="Enter"?Dl(t,e,r):e.key==="Tab"?Ml(e,r):[...So,...$l].includes(e.key)?Ul(e.key):e.key==="Escape"&&Hl(e,r,n)))},Dl=(t,e,n)=>{if(nn(n.allowEnterKey)&&e.target&&t.getInput()&&e.target.outerHTML===t.getInput().outerHTML){if(["textarea","file"].includes(n.input))return;wo(),e.preventDefault()}},Ml=(t,e)=>{const n=t.target,r=Nn();let o=-1;for(let i=0;i<r.length;i++)if(n===r[i]){o=i;break}t.shiftKey?zn(e,o,-1):zn(e,o,1),t.stopPropagation(),t.preventDefault()},Ul=t=>{const e=Ue(),n=et(),r=it();if(![e,n,r].includes(document.activeElement))return;const o=So.includes(t)?"nextElementSibling":"previousElementSibling";let i=document.activeElement;for(let s=0;s<Tt().children.length;s++){if(i=i[o],!i)return;if(Le(i)&&i instanceof HTMLButtonElement)break}i instanceof HTMLButtonElement&&i.focus()},Hl=(t,e,n)=>{nn(e.allowEscapeKey)&&(t.preventDefault(),n(ht.esc))};function _o(t,e,n,r){an()?Co(t,r):(ua(n).then(()=>Co(t,r)),Eo(J)),/^((?!chrome|android).)*safari/i.test(navigator.userAgent)?(e.setAttribute("style","display:none !important"),e.removeAttribute("class"),e.innerHTML=""):e.remove(),Dn()&&(cl(),gl(),po()),jl()}function jl(){Ve([document.documentElement,document.body],[g.shown,g["height-auto"],g["no-backdrop"],g["toast-shown"]])}function cn(t){t=Wl(t);const e=Rt.swalPromiseResolve.get(this),n=Kl(this);this.isAwaitingPromise()?t.isDismissed||(Ft(this),e(t)):n&&e(t)}function Vl(){return!!Y.awaitingPromise.get(this)}const Kl=t=>{const e=oe();if(!e)return!1;const n=Y.innerParams.get(t);if(!n||Ge(e,n.hideClass.popup))return!1;Ve(e,n.showClass.popup),ee(e,n.hideClass.popup);const r=ye();return Ve(r,n.showClass.backdrop),ee(r,n.hideClass.backdrop),ql(t,e,n),!0};function zl(t){const e=Rt.swalPromiseReject.get(this);Ft(this),e&&e(t)}const Ft=t=>{t.isAwaitingPromise()&&(Y.awaitingPromise.delete(t),Y.innerParams.get(t)||t._destroy())},Wl=t=>typeof t>"u"?{isConfirmed:!1,isDenied:!1,isDismissed:!0}:Object.assign({isConfirmed:!1,isDenied:!1,isDismissed:!1},t),ql=(t,e,n)=>{const r=ye(),o=Lt&&io(e);typeof n.willClose=="function"&&n.willClose(e),o?Gl(t,e,r,n.returnFocus,n.didClose):_o(t,r,n.returnFocus,n.didClose)},Gl=(t,e,n,r,o)=>{J.swalCloseEventFinishedCallback=_o.bind(null,t,n,r,o),e.addEventListener(Lt,function(i){i.target===e&&(J.swalCloseEventFinishedCallback(),delete J.swalCloseEventFinishedCallback)})},Co=(t,e)=>{setTimeout(()=>{typeof e=="function"&&e.bind(t.params)(),t._destroy()})};function Ao(t,e,n){const r=Y.domCache.get(t);e.forEach(o=>{r[o].disabled=n})}function ko(t,e){if(!t)return!1;if(t.type==="radio"){const r=t.parentNode.parentNode.querySelectorAll("input");for(let o=0;o<r.length;o++)r[o].disabled=e}else t.disabled=e}function Jl(){Ao(this,["confirmButton","denyButton","cancelButton"],!1)}function Yl(){Ao(this,["confirmButton","denyButton","cancelButton"],!0)}function Xl(){return ko(this.getInput(),!1)}function Zl(){return ko(this.getInput(),!0)}function Ql(t){const e=Y.domCache.get(this),n=Y.innerParams.get(this);be(e.validationMessage,t),e.validationMessage.className=g["validation-message"],n.customClass&&n.customClass.validationMessage&&ee(e.validationMessage,n.customClass.validationMessage),he(e.validationMessage);const r=this.getInput();r&&(r.setAttribute("aria-invalid",!0),r.setAttribute("aria-describedby",g["validation-message"]),to(r),ee(r,g.inputerror))}function ec(){const t=Y.domCache.get(this);t.validationMessage&&ve(t.validationMessage);const e=this.getInput();e&&(e.removeAttribute("aria-invalid"),e.removeAttribute("aria-describedby"),Ve(e,g.inputerror))}function tc(){return Y.domCache.get(this).progressSteps}function nc(t){const e=oe(),n=Y.innerParams.get(this);if(!e||Ge(e,n.hideClass.popup))return Ae("You're trying to update the closed or closing popup, that won't work. Use the update() method in preConfirm parameter or show a new popup.");const r=rc(t),o=Object.assign({},n,r);fo(this,o),Y.innerParams.set(this,o),Object.defineProperties(this,{params:{value:Object.assign({},this.params,t),writable:!1,enumerable:!0}})}const rc=t=>{const e={};return Object.keys(t).forEach(n=>{Jr(n)?e[n]=t[n]:Ae(`Invalid parameter to update: "${n}". Updatable params are listed here: https://github.com/sweetalert2/sweetalert2/blob/master/src/utils/params.js
63
63
 
64
- If you think this parameter should be updatable, request it here: https://github.com/sweetalert2/sweetalert2/issues/new?template=02_feature_request.md`)}),e};function Za(){const t=K.domCache.get(this),e=K.innerParams.get(this);if(!e){Yo(this);return}t.popup&&q.swalCloseEventFinishedCallback&&(q.swalCloseEventFinishedCallback(),delete q.swalCloseEventFinishedCallback),q.deferDisposalTimer&&(clearTimeout(q.deferDisposalTimer),delete q.deferDisposalTimer),typeof e.didDestroy=="function"&&e.didDestroy(),Qa(this)}const Qa=t=>{Yo(t),delete t.params,delete q.keydownHandler,delete q.keydownTarget,delete q.currentInstance},Yo=t=>{t.isAwaitingPromise()?(Tn(K,t),K.awaitingPromise.set(t,!0)):(Tn(Tt,t),Tn(K,t))},Tn=(t,e)=>{for(const n in t)t[n].delete(e)},Xo=Object.freeze(Object.defineProperty({__proto__:null,_destroy:Za,close:Kt,closeModal:Kt,closePopup:Kt,closeToast:Kt,disableButtons:za,disableInput:qa,disableLoading:jo,enableButtons:Va,enableInput:Wa,getInput:Sa,getProgressSteps:Ja,handleAwaitingPromise:Pt,hideLoading:jo,isAwaitingPromise:Ua,rejectPromise:Da,resetValidationMessage:Ga,showValidationMessage:Ka,update:Ya},Symbol.toStringTag,{value:"Module"})),ec=t=>{const e=K.innerParams.get(t);t.disableButtons(),e.input?Zo(t,"confirm"):Rn(t,!0)},tc=t=>{const e=K.innerParams.get(t);t.disableButtons(),e.returnInputValueOnDeny?Zo(t,"deny"):Pn(t,!1)},nc=(t,e)=>{t.disableButtons(),e(ct.cancel)},Zo=(t,e)=>{const n=K.innerParams.get(t);if(!n.input)return Ze(`The "input" parameter is needed to be set when using returnInputValueOn${hn(e)}`);const o=ya(t,n);n.inputValidator?oc(t,o,e):t.getInput().checkValidity()?e==="deny"?Pn(t,o):Rn(t,o):(t.enableButtons(),t.showValidationMessage(n.validationMessage))},oc=(t,e,n)=>{const o=K.innerParams.get(t);t.disableInput(),Promise.resolve().then(()=>Et(o.inputValidator(e,o.validationMessage))).then(s=>{t.enableButtons(),t.enableInput(),s?t.showValidationMessage(s):n==="deny"?Pn(t,e):Rn(t,e)})},Pn=(t,e)=>{const n=K.innerParams.get(t||void 0);n.showLoaderOnDeny&&lt(Ge()),n.preDeny?(K.awaitingPromise.set(t||void 0,!0),Promise.resolve().then(()=>Et(n.preDeny(e,n.validationMessage))).then(r=>{r===!1?(t.hideLoading(),Pt(t)):t.closePopup({isDenied:!0,value:typeof r>"u"?e:r})}).catch(r=>er(t||void 0,r))):t.closePopup({isDenied:!0,value:e})},Qo=(t,e)=>{t.closePopup({isConfirmed:!0,value:e})},er=(t,e)=>{t.rejectPromise(e)},Rn=(t,e)=>{const n=K.innerParams.get(t||void 0);n.showLoaderOnConfirm&&lt(),n.preConfirm?(t.resetValidationMessage(),K.awaitingPromise.set(t||void 0,!0),Promise.resolve().then(()=>Et(n.preConfirm(e,n.validationMessage))).then(r=>{ve(Vt())||r===!1?(t.hideLoading(),Pt(t)):Qo(t,typeof r>"u"?e:r)}).catch(r=>er(t||void 0,r))):Qo(t,e)},rc=(t,e,n)=>{K.innerParams.get(t).toast?sc(t,e,n):(ac(e),cc(e),lc(t,e,n))},sc=(t,e,n)=>{e.popup.onclick=()=>{const o=K.innerParams.get(t);o&&(ic(o)||o.timer||o.input)||n(ct.close)}},ic=t=>t.showConfirmButton||t.showDenyButton||t.showCancelButton||t.showCloseButton;let Gt=!1;const ac=t=>{t.popup.onmousedown=()=>{t.container.onmouseup=function(e){t.container.onmouseup=void 0,e.target===t.container&&(Gt=!0)}}},cc=t=>{t.container.onmousedown=()=>{t.popup.onmouseup=function(e){t.popup.onmouseup=void 0,(e.target===t.popup||t.popup.contains(e.target))&&(Gt=!0)}}},lc=(t,e,n)=>{e.container.onclick=o=>{const r=K.innerParams.get(t);if(Gt){Gt=!1;return}o.target===e.container&&Ht(r.allowOutsideClick)&&n(ct.backdrop)}},uc=t=>typeof t=="object"&&t.jquery,tr=t=>t instanceof Element||uc(t),dc=t=>{const e={};return typeof t[0]=="object"&&!tr(t[0])?Object.assign(e,t[0]):["title","html","icon"].forEach((n,o)=>{const r=t[o];typeof r=="string"||tr(r)?e[n]=r:r!==void 0&&Ze(`Unexpected type of ${n}! Expected "string" or "Element", got ${typeof r}`)}),e};function fc(...t){const e=this;return new e(...t)}function pc(t){class e extends this{_main(o,r){return super._main(o,Object.assign({},t,r))}}return e}const hc=()=>q.timeout&&q.timeout.getTimerLeft(),nr=()=>{if(q.timeout)return ti(),q.timeout.stop()},or=()=>{if(q.timeout){const t=q.timeout.start();return kn(t),t}},mc=()=>{const t=q.timeout;return t&&(t.running?nr():or())},gc=t=>{if(q.timeout){const e=q.timeout.increase(t);return kn(e,!0),e}},yc=()=>q.timeout&&q.timeout.isRunning();let rr=!1;const Ln={};function bc(t="data-swal-template"){Ln[t]=this,rr||(document.body.addEventListener("click",wc),rr=!0)}const wc=t=>{for(let e=t.target;e&&e!==document;e=e.parentNode)for(const n in Ln){const o=e.getAttribute(n);if(o){Ln[n].fire({template:o});return}}},Ec=Object.freeze(Object.defineProperty({__proto__:null,argsToParams:dc,bindClickHandler:bc,clickCancel:Ta,clickConfirm:Vo,clickDeny:va,enableLoading:lt,fire:fc,getActions:xt,getCancelButton:Qe,getCloseButton:bn,getConfirmButton:Ne,getContainer:de,getDenyButton:Ge,getFocusableElements:wn,getFooter:xo,getHtmlContainer:jt,getIcon:Ct,getImage:ko,getInputLabel:Ys,getLoader:it,getPopup:Q,getTimerLeft:hc,getTimerProgressBar:zt,getTitle:Ao,getValidationMessage:Vt,increaseTimer:gc,isDeprecatedParameter:yn,isLoading:Zs,isTimerRunning:yc,isUpdatableParameter:wo,isValidParameter:bo,isVisible:_a,mixin:pc,resumeTimer:or,showLoading:lt,stopTimer:nr,toggleTimer:mc},Symbol.toStringTag,{value:"Module"}));let On;class ut{constructor(...e){if(typeof window>"u")return;On=this;const n=Object.freeze(this.constructor.argsToParams(e));Object.defineProperties(this,{params:{value:n,writable:!1,enumerable:!0,configurable:!0}});const o=this._main(this.params);K.promise.set(this,o)}_main(e,n={}){Gs(Object.assign({},n,e)),q.currentInstance&&(q.currentInstance._destroy(),En()&&Fo()),q.currentInstance=this;const o=kc(e,n);ea(o),Object.freeze(o),q.timeout&&(q.timeout.stop(),delete q.timeout),clearTimeout(q.restoreFocusTimeout);const r=Cc(this);return No(this,o),K.innerParams.set(this,o),Ac(this,r,o)}then(e){return K.promise.get(this).then(e)}finally(e){return K.promise.get(this).finally(e)}}const Ac=(t,e,n)=>new Promise((o,r)=>{const s=i=>{t.closePopup({isDismissed:!0,dismiss:i})};Tt.swalPromiseResolve.set(t,o),Tt.swalPromiseReject.set(t,r),e.confirmButton.onclick=()=>ec(t),e.denyButton.onclick=()=>tc(t),e.cancelButton.onclick=()=>nc(t,s),e.closeButton.onclick=()=>s(ct.close),rc(t,e,s),Pa(t,q,n,s),ga(t,n),da(n),xc(q,n,s),Sc(e,n),setTimeout(()=>{e.container.scrollTop=0})}),kc=(t,e)=>{const n=zi(t),o=Object.assign({},st,e,n,t);return o.showClass=Object.assign({},st.showClass,o.showClass),o.hideClass=Object.assign({},st.hideClass,o.hideClass),o},Cc=t=>{const e={popup:Q(),container:de(),actions:xt(),confirmButton:Ne(),denyButton:Ge(),cancelButton:Qe(),loader:it(),closeButton:bn(),validationMessage:Vt(),progressSteps:Co()};return K.domCache.set(t,e),e},xc=(t,e,n)=>{const o=zt();pe(o),e.timer&&(t.timeout=new ta(()=>{n("timer"),delete t.timeout},e.timer),e.timerProgressBar&&(le(o),Le(o,e,"timerProgressBar"),setTimeout(()=>{t.timeout&&t.timeout.running&&kn(e.timer)})))},Sc=(t,e)=>{if(!e.toast){if(!Ht(e.allowEnterKey))return vc();_c(t,e)||vn(e,-1,1)}},_c=(t,e)=>e.focusDeny&&ve(t.denyButton)?(t.denyButton.focus(),!0):e.focusCancel&&ve(t.cancelButton)?(t.cancelButton.focus(),!0):e.focusConfirm&&ve(t.confirmButton)?(t.confirmButton.focus(),!0):!1,vc=()=>{document.activeElement instanceof HTMLElement&&typeof document.activeElement.blur=="function"&&document.activeElement.blur()};Object.assign(ut.prototype,Xo),Object.assign(ut,Ec),Object.keys(Xo).forEach(t=>{ut[t]=function(...e){if(On)return On[t](...e)}}),ut.DismissReason=ct,ut.version="11.4.8";const dt=ut;dt.default=dt;/*! @license DOMPurify 3.0.9 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.0.9/LICENSE */const{entries:sr,setPrototypeOf:ir,isFrozen:Tc,getPrototypeOf:Pc,getOwnPropertyDescriptor:Rc}=Object;let{freeze:ge,seal:Fe,create:ar}=Object,{apply:In,construct:Bn}=typeof Reflect<"u"&&Reflect;ge||(ge=function(e){return e}),Fe||(Fe=function(e){return e}),In||(In=function(e,n,o){return e.apply(n,o)}),Bn||(Bn=function(e,n){return new e(...n)});const Jt=Pe(Array.prototype.forEach),cr=Pe(Array.prototype.pop),Rt=Pe(Array.prototype.push),Yt=Pe(String.prototype.toLowerCase),Nn=Pe(String.prototype.toString),Lc=Pe(String.prototype.match),Lt=Pe(String.prototype.replace),Oc=Pe(String.prototype.indexOf),Ic=Pe(String.prototype.trim),Ue=Pe(Object.prototype.hasOwnProperty),Te=Pe(RegExp.prototype.test),Ot=Bc(TypeError);function Pe(t){return function(e){for(var n=arguments.length,o=new Array(n>1?n-1:0),r=1;r<n;r++)o[r-1]=arguments[r];return In(t,e,o)}}function Bc(t){return function(){for(var e=arguments.length,n=new Array(e),o=0;o<e;o++)n[o]=arguments[o];return Bn(t,n)}}function G(t,e){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:Yt;ir&&ir(t,null);let o=e.length;for(;o--;){let r=e[o];if(typeof r=="string"){const s=n(r);s!==r&&(Tc(e)||(e[o]=s),r=s)}t[r]=!0}return t}function Nc(t){for(let e=0;e<t.length;e++)Ue(t,e)||(t[e]=null);return t}function nt(t){const e=ar(null);for(const[n,o]of sr(t))Ue(t,n)&&(Array.isArray(o)?e[n]=Nc(o):o&&typeof o=="object"&&o.constructor===Object?e[n]=nt(o):e[n]=o);return e}function Xt(t,e){for(;t!==null;){const o=Rc(t,e);if(o){if(o.get)return Pe(o.get);if(typeof o.value=="function")return Pe(o.value)}t=Pc(t)}function n(){return null}return n}const lr=ge(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),Fn=ge(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),Un=ge(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),Fc=ge(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),Mn=ge(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),Uc=ge(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),ur=ge(["#text"]),dr=ge(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","xmlns","slot"]),Dn=ge(["accent-height","accumulate","additive","alignment-baseline","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),fr=ge(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),Zt=ge(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),Mc=Fe(/\{\{[\w\W]*|[\w\W]*\}\}/gm),Dc=Fe(/<%[\w\W]*|[\w\W]*%>/gm),$c=Fe(/\${[\w\W]*}/gm),Hc=Fe(/^data-[\-\w.\u00B7-\uFFFF]/),jc=Fe(/^aria-[\-\w]+$/),pr=Fe(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Vc=Fe(/^(?:\w+script|data):/i),zc=Fe(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),hr=Fe(/^html$/i);var mr=Object.freeze({__proto__:null,MUSTACHE_EXPR:Mc,ERB_EXPR:Dc,TMPLIT_EXPR:$c,DATA_ATTR:Hc,ARIA_ATTR:jc,IS_ALLOWED_URI:pr,IS_SCRIPT_OR_DATA:Vc,ATTR_WHITESPACE:zc,DOCTYPE_NAME:hr});const Wc=function(){return typeof window>"u"?null:window},qc=function(e,n){if(typeof e!="object"||typeof e.createPolicy!="function")return null;let o=null;const r="data-tt-policy-suffix";n&&n.hasAttribute(r)&&(o=n.getAttribute(r));const s="dompurify"+(o?"#"+o:"");try{return e.createPolicy(s,{createHTML(i){return i},createScriptURL(i){return i}})}catch{return console.warn("TrustedTypes policy "+s+" could not be created."),null}};function gr(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Wc();const e=F=>gr(F);if(e.version="3.0.9",e.removed=[],!t||!t.document||t.document.nodeType!==9)return e.isSupported=!1,e;let{document:n}=t;const o=n,r=o.currentScript,{DocumentFragment:s,HTMLTemplateElement:i,Node:f,Element:u,NodeFilter:w,NamedNodeMap:E=t.NamedNodeMap||t.MozNamedAttrMap,HTMLFormElement:b,DOMParser:j,trustedTypes:$}=t,B=u.prototype,N=Xt(B,"cloneNode"),D=Xt(B,"nextSibling"),ee=Xt(B,"childNodes"),oe=Xt(B,"parentNode");if(typeof i=="function"){const F=n.createElement("template");F.content&&F.content.ownerDocument&&(n=F.content.ownerDocument)}let V,ye="";const{implementation:ae,createNodeIterator:g,createDocumentFragment:T,getElementsByTagName:U}=n,{importNode:P}=o;let v={};e.isSupported=typeof sr=="function"&&typeof oe=="function"&&ae&&ae.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:_,ERB_EXPR:z,TMPLIT_EXPR:A,DATA_ATTR:W,ARIA_ATTR:te,IS_SCRIPT_OR_DATA:ie,ATTR_WHITESPACE:se}=mr;let{IS_ALLOWED_URI:be}=mr,M=null;const ke=G({},[...lr,...Fn,...Un,...Mn,...ur]);let a=null;const d=G({},[...dr,...Dn,...fr,...Zt]);let m=Object.seal(ar(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),C=null,y=null,R=!0,k=!0,x=!1,O=!0,L=!1,H=!1,J=!1,Ce=!1,we=!1,ue=!1,je=!1,os=!0,rs=!1;const td="user-content-";let so=!0,Mt=!1,mt={},gt=null;const ss=G({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let is=null;const as=G({},["audio","video","img","source","image","track"]);let io=null;const cs=G({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),un="http://www.w3.org/1998/Math/MathML",dn="http://www.w3.org/2000/svg",We="http://www.w3.org/1999/xhtml";let yt=We,ao=!1,co=null;const nd=G({},[un,dn,We],Nn);let Dt=null;const od=["application/xhtml+xml","text/html"],rd="text/html";let ce=null,bt=null;const sd=n.createElement("form"),ls=function(l){return l instanceof RegExp||l instanceof Function},lo=function(){let l=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(bt&&bt===l)){if((!l||typeof l!="object")&&(l={}),l=nt(l),Dt=od.indexOf(l.PARSER_MEDIA_TYPE)===-1?rd:l.PARSER_MEDIA_TYPE,ce=Dt==="application/xhtml+xml"?Nn:Yt,M=Ue(l,"ALLOWED_TAGS")?G({},l.ALLOWED_TAGS,ce):ke,a=Ue(l,"ALLOWED_ATTR")?G({},l.ALLOWED_ATTR,ce):d,co=Ue(l,"ALLOWED_NAMESPACES")?G({},l.ALLOWED_NAMESPACES,Nn):nd,io=Ue(l,"ADD_URI_SAFE_ATTR")?G(nt(cs),l.ADD_URI_SAFE_ATTR,ce):cs,is=Ue(l,"ADD_DATA_URI_TAGS")?G(nt(as),l.ADD_DATA_URI_TAGS,ce):as,gt=Ue(l,"FORBID_CONTENTS")?G({},l.FORBID_CONTENTS,ce):ss,C=Ue(l,"FORBID_TAGS")?G({},l.FORBID_TAGS,ce):{},y=Ue(l,"FORBID_ATTR")?G({},l.FORBID_ATTR,ce):{},mt=Ue(l,"USE_PROFILES")?l.USE_PROFILES:!1,R=l.ALLOW_ARIA_ATTR!==!1,k=l.ALLOW_DATA_ATTR!==!1,x=l.ALLOW_UNKNOWN_PROTOCOLS||!1,O=l.ALLOW_SELF_CLOSE_IN_ATTR!==!1,L=l.SAFE_FOR_TEMPLATES||!1,H=l.WHOLE_DOCUMENT||!1,we=l.RETURN_DOM||!1,ue=l.RETURN_DOM_FRAGMENT||!1,je=l.RETURN_TRUSTED_TYPE||!1,Ce=l.FORCE_BODY||!1,os=l.SANITIZE_DOM!==!1,rs=l.SANITIZE_NAMED_PROPS||!1,so=l.KEEP_CONTENT!==!1,Mt=l.IN_PLACE||!1,be=l.ALLOWED_URI_REGEXP||pr,yt=l.NAMESPACE||We,m=l.CUSTOM_ELEMENT_HANDLING||{},l.CUSTOM_ELEMENT_HANDLING&&ls(l.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(m.tagNameCheck=l.CUSTOM_ELEMENT_HANDLING.tagNameCheck),l.CUSTOM_ELEMENT_HANDLING&&ls(l.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(m.attributeNameCheck=l.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),l.CUSTOM_ELEMENT_HANDLING&&typeof l.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(m.allowCustomizedBuiltInElements=l.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),L&&(k=!1),ue&&(we=!0),mt&&(M=G({},ur),a=[],mt.html===!0&&(G(M,lr),G(a,dr)),mt.svg===!0&&(G(M,Fn),G(a,Dn),G(a,Zt)),mt.svgFilters===!0&&(G(M,Un),G(a,Dn),G(a,Zt)),mt.mathMl===!0&&(G(M,Mn),G(a,fr),G(a,Zt))),l.ADD_TAGS&&(M===ke&&(M=nt(M)),G(M,l.ADD_TAGS,ce)),l.ADD_ATTR&&(a===d&&(a=nt(a)),G(a,l.ADD_ATTR,ce)),l.ADD_URI_SAFE_ATTR&&G(io,l.ADD_URI_SAFE_ATTR,ce),l.FORBID_CONTENTS&&(gt===ss&&(gt=nt(gt)),G(gt,l.FORBID_CONTENTS,ce)),so&&(M["#text"]=!0),H&&G(M,["html","head","body"]),M.table&&(G(M,["tbody"]),delete C.tbody),l.TRUSTED_TYPES_POLICY){if(typeof l.TRUSTED_TYPES_POLICY.createHTML!="function")throw Ot('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof l.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw Ot('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');V=l.TRUSTED_TYPES_POLICY,ye=V.createHTML("")}else V===void 0&&(V=qc($,r)),V!==null&&typeof ye=="string"&&(ye=V.createHTML(""));ge&&ge(l),bt=l}},us=G({},["mi","mo","mn","ms","mtext"]),ds=G({},["foreignobject","desc","title","annotation-xml"]),id=G({},["title","style","font","a","script"]),fs=G({},[...Fn,...Un,...Fc]),ps=G({},[...Mn,...Uc]),ad=function(l){let S=oe(l);(!S||!S.tagName)&&(S={namespaceURI:yt,tagName:"template"});const I=Yt(l.tagName),ne=Yt(S.tagName);return co[l.namespaceURI]?l.namespaceURI===dn?S.namespaceURI===We?I==="svg":S.namespaceURI===un?I==="svg"&&(ne==="annotation-xml"||us[ne]):!!fs[I]:l.namespaceURI===un?S.namespaceURI===We?I==="math":S.namespaceURI===dn?I==="math"&&ds[ne]:!!ps[I]:l.namespaceURI===We?S.namespaceURI===dn&&!ds[ne]||S.namespaceURI===un&&!us[ne]?!1:!ps[I]&&(id[I]||!fs[I]):!!(Dt==="application/xhtml+xml"&&co[l.namespaceURI]):!1},ot=function(l){Rt(e.removed,{element:l});try{l.parentNode.removeChild(l)}catch{l.remove()}},uo=function(l,S){try{Rt(e.removed,{attribute:S.getAttributeNode(l),from:S})}catch{Rt(e.removed,{attribute:null,from:S})}if(S.removeAttribute(l),l==="is"&&!a[l])if(we||ue)try{ot(S)}catch{}else try{S.setAttribute(l,"")}catch{}},hs=function(l){let S=null,I=null;if(Ce)l="<remove></remove>"+l;else{const me=Lc(l,/^[\r\n\t ]+/);I=me&&me[0]}Dt==="application/xhtml+xml"&&yt===We&&(l='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+l+"</body></html>");const ne=V?V.createHTML(l):l;if(yt===We)try{S=new j().parseFromString(ne,Dt)}catch{}if(!S||!S.documentElement){S=ae.createDocument(yt,"template",null);try{S.documentElement.innerHTML=ao?ye:ne}catch{}}const he=S.body||S.documentElement;return l&&I&&he.insertBefore(n.createTextNode(I),he.childNodes[0]||null),yt===We?U.call(S,H?"html":"body")[0]:H?S.documentElement:he},ms=function(l){return g.call(l.ownerDocument||l,l,w.SHOW_ELEMENT|w.SHOW_COMMENT|w.SHOW_TEXT,null)},cd=function(l){return l instanceof b&&(typeof l.nodeName!="string"||typeof l.textContent!="string"||typeof l.removeChild!="function"||!(l.attributes instanceof E)||typeof l.removeAttribute!="function"||typeof l.setAttribute!="function"||typeof l.namespaceURI!="string"||typeof l.insertBefore!="function"||typeof l.hasChildNodes!="function")},gs=function(l){return typeof f=="function"&&l instanceof f},qe=function(l,S,I){v[l]&&Jt(v[l],ne=>{ne.call(e,S,I,bt)})},ys=function(l){let S=null;if(qe("beforeSanitizeElements",l,null),cd(l))return ot(l),!0;const I=ce(l.nodeName);if(qe("uponSanitizeElement",l,{tagName:I,allowedTags:M}),l.hasChildNodes()&&!gs(l.firstElementChild)&&Te(/<[/\w]/g,l.innerHTML)&&Te(/<[/\w]/g,l.textContent))return ot(l),!0;if(!M[I]||C[I]){if(!C[I]&&ws(I)&&(m.tagNameCheck instanceof RegExp&&Te(m.tagNameCheck,I)||m.tagNameCheck instanceof Function&&m.tagNameCheck(I)))return!1;if(so&&!gt[I]){const ne=oe(l)||l.parentNode,he=ee(l)||l.childNodes;if(he&&ne){const me=he.length;for(let xe=me-1;xe>=0;--xe)ne.insertBefore(N(he[xe],!0),D(l))}}return ot(l),!0}return l instanceof u&&!ad(l)||(I==="noscript"||I==="noembed"||I==="noframes")&&Te(/<\/no(script|embed|frames)/i,l.innerHTML)?(ot(l),!0):(L&&l.nodeType===3&&(S=l.textContent,Jt([_,z,A],ne=>{S=Lt(S,ne," ")}),l.textContent!==S&&(Rt(e.removed,{element:l.cloneNode()}),l.textContent=S)),qe("afterSanitizeElements",l,null),!1)},bs=function(l,S,I){if(os&&(S==="id"||S==="name")&&(I in n||I in sd))return!1;if(!(k&&!y[S]&&Te(W,S))){if(!(R&&Te(te,S))){if(!a[S]||y[S]){if(!(ws(l)&&(m.tagNameCheck instanceof RegExp&&Te(m.tagNameCheck,l)||m.tagNameCheck instanceof Function&&m.tagNameCheck(l))&&(m.attributeNameCheck instanceof RegExp&&Te(m.attributeNameCheck,S)||m.attributeNameCheck instanceof Function&&m.attributeNameCheck(S))||S==="is"&&m.allowCustomizedBuiltInElements&&(m.tagNameCheck instanceof RegExp&&Te(m.tagNameCheck,I)||m.tagNameCheck instanceof Function&&m.tagNameCheck(I))))return!1}else if(!io[S]){if(!Te(be,Lt(I,se,""))){if(!((S==="src"||S==="xlink:href"||S==="href")&&l!=="script"&&Oc(I,"data:")===0&&is[l])){if(!(x&&!Te(ie,Lt(I,se,"")))){if(I)return!1}}}}}}return!0},ws=function(l){return l!=="annotation-xml"&&l.indexOf("-")>0},Es=function(l){qe("beforeSanitizeAttributes",l,null);const{attributes:S}=l;if(!S)return;const I={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:a};let ne=S.length;for(;ne--;){const he=S[ne],{name:me,namespaceURI:xe,value:rt}=he,$t=ce(me);let Se=me==="value"?rt:Ic(rt);if(I.attrName=$t,I.attrValue=Se,I.keepAttr=!0,I.forceKeepAttr=void 0,qe("uponSanitizeAttribute",l,I),Se=I.attrValue,I.forceKeepAttr||(uo(me,l),!I.keepAttr))continue;if(!O&&Te(/\/>/i,Se)){uo(me,l);continue}L&&Jt([_,z,A],ks=>{Se=Lt(Se,ks," ")});const As=ce(l.nodeName);if(bs(As,$t,Se)){if(rs&&($t==="id"||$t==="name")&&(uo(me,l),Se=td+Se),V&&typeof $=="object"&&typeof $.getAttributeType=="function"&&!xe)switch($.getAttributeType(As,$t)){case"TrustedHTML":{Se=V.createHTML(Se);break}case"TrustedScriptURL":{Se=V.createScriptURL(Se);break}}try{xe?l.setAttributeNS(xe,me,Se):l.setAttribute(me,Se),cr(e.removed)}catch{}}}qe("afterSanitizeAttributes",l,null)},ld=function F(l){let S=null;const I=ms(l);for(qe("beforeSanitizeShadowDOM",l,null);S=I.nextNode();)qe("uponSanitizeShadowNode",S,null),!ys(S)&&(S.content instanceof s&&F(S.content),Es(S));qe("afterSanitizeShadowDOM",l,null)};return e.sanitize=function(F){let l=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},S=null,I=null,ne=null,he=null;if(ao=!F,ao&&(F="<!-->"),typeof F!="string"&&!gs(F))if(typeof F.toString=="function"){if(F=F.toString(),typeof F!="string")throw Ot("dirty is not a string, aborting")}else throw Ot("toString is not a function");if(!e.isSupported)return F;if(J||lo(l),e.removed=[],typeof F=="string"&&(Mt=!1),Mt){if(F.nodeName){const rt=ce(F.nodeName);if(!M[rt]||C[rt])throw Ot("root node is forbidden and cannot be sanitized in-place")}}else if(F instanceof f)S=hs("<!---->"),I=S.ownerDocument.importNode(F,!0),I.nodeType===1&&I.nodeName==="BODY"||I.nodeName==="HTML"?S=I:S.appendChild(I);else{if(!we&&!L&&!H&&F.indexOf("<")===-1)return V&&je?V.createHTML(F):F;if(S=hs(F),!S)return we?null:je?ye:""}S&&Ce&&ot(S.firstChild);const me=ms(Mt?F:S);for(;ne=me.nextNode();)ys(ne)||(ne.content instanceof s&&ld(ne.content),Es(ne));if(Mt)return F;if(we){if(ue)for(he=T.call(S.ownerDocument);S.firstChild;)he.appendChild(S.firstChild);else he=S;return(a.shadowroot||a.shadowrootmode)&&(he=P.call(o,he,!0)),he}let xe=H?S.outerHTML:S.innerHTML;return H&&M["!doctype"]&&S.ownerDocument&&S.ownerDocument.doctype&&S.ownerDocument.doctype.name&&Te(hr,S.ownerDocument.doctype.name)&&(xe="<!DOCTYPE "+S.ownerDocument.doctype.name+`>
65
- `+xe),L&&Jt([_,z,A],rt=>{xe=Lt(xe,rt," ")}),V&&je?V.createHTML(xe):xe},e.setConfig=function(){let F=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};lo(F),J=!0},e.clearConfig=function(){bt=null,J=!1},e.isValidAttribute=function(F,l,S){bt||lo({});const I=ce(F),ne=ce(l);return bs(I,ne,S)},e.addHook=function(F,l){typeof l=="function"&&(v[F]=v[F]||[],Rt(v[F],l))},e.removeHook=function(F){if(v[F])return cr(v[F])},e.removeHooks=function(F){v[F]&&(v[F]=[])},e.removeAllHooks=function(){v={}},e}var yr=gr();class br{get IsVisible(){return dt.isVisible()}}class Kc extends br{constructor(){super()}async CreateAlertAsync(e){let n="info",o,r;return typeof e=="string"||Array.isArray(e)?o=Array.isArray(e)?e.join("<br />"):e:(n=e.icon??"info",r=e.title??"",o=Array.isArray(e.text)?e.text.join("<br />"):e.text),new Promise(s=>{dt.fire({allowEscapeKey:!1,allowOutsideClick:!1,icon:n,title:r,html:`<div style="max-height: 50vh; overflow: auto">${yr.sanitize(o)}</div>`}).then(()=>s(!0))})}async AlertAsync(e){return this.CreateAlertAsync({text:e,icon:"info"})}async AlertErrorAsync(e){return this.CreateAlertAsync({text:e,icon:"error"})}async AlertSuccessAsync(e){return this.CreateAlertAsync({text:e,icon:"success"})}}class Gc extends br{async CreateConfirmAsync(e){return new Promise(n=>{dt.fire({showCancelButton:!0,allowEscapeKey:!1,allowOutsideClick:!1,icon:"question",title:e.title,html:yr.sanitize(e.text),confirmButtonText:e.confirmLabel??"confirmar",cancelButtonText:e.rejectLabel??"cancelar"}).then(o=>{n(o.isConfirmed===!0)})})}async ConfirmAsync(e){return this.CreateConfirmAsync({text:e})}}const Jc=()=>new Kc,wr=()=>new Gc,Yc=["data-cor"],Xc={class:"sf-p-4"},Zc=c.defineComponent({__name:"HeaderAvatar",emits:["logout"],setup(t,{emit:e}){const n=wr(),o=c.ref("?"),r=e;async function s(){await n.CreateConfirmAsync({text:"Você deseja sair da conta?",confirmLabel:"sair"})&&r("logout")}function i(){const w=sessionStorage.getItem("name");let E="?";if(!w)return E;const b=w.split(" ").filter($=>$.length>0).map($=>$[0].toUpperCase()),j=Math.min(2,b.length);return E=b.slice(0,j).join(""),E.length>0?E:"?"}const f=c.computed(()=>{const w=o.value[0],E=w==="?"?0:(w.charCodeAt(0)-64)%19;return Math.max(E,0)}),u=c.ref(!1);return c.onMounted(()=>{o.value=i()}),(w,E)=>(c.openBlock(),c.createElementBlock(c.Fragment,null,[c.createElementVNode("div",{id:"sf-header-avatar","data-cor":f.value,onClick:E[0]||(E[0]=b=>u.value=!0)},c.toDisplayString(o.value),9,Yc),c.createVNode(ho,{visible:u.value,"onUpdate:visible":E[1]||(E[1]=b=>u.value=b),position:"right"},{title:c.withCtx(()=>[c.createTextVNode("Minha conta")]),default:c.withCtx(()=>[c.createElementVNode("div",Xc,[c.createVNode(mo,{color:"error",onClick:s},{default:c.withCtx(()=>[c.createTextVNode("Sair")]),_:1})])]),_:1},8,["visible"])],64))}}),Qc={},el={xmlns:"http://www.w3.org/2000/svg",height:"48",viewBox:"0 -960 960 960",width:"48",class:"sf-svg-icon"},tl=[c.createElementVNode("path",{d:"m307.231-83.463-54.999-55.23 343.923-343.922-343.923-343.539 54.999-54.614 398.153 398.153L307.231-83.462Z"},null,-1)];function nl(t,e){return c.openBlock(),c.createElementBlock("svg",el,tl)}const ol=po(Qc,[["render",nl]]);class rl{get storedTheme(){return localStorage.getItem("color-scheme")}get IsDark(){return document.documentElement.classList.contains("dark")}Toggle(){this.IsDark?this.EnableLightMode():this.EnableDarkMode()}EnableDarkMode(){document.documentElement.classList.add("dark"),document.documentElement.classList.remove("light"),localStorage.setItem("color-scheme","dark")}EnableLightMode(){document.documentElement.classList.remove("dark"),document.documentElement.classList.add("light"),localStorage.setItem("color-scheme","light")}SetInitialTheme(){if(this.storedTheme==="light")return this.EnableLightMode();if(this.storedTheme==="dark")return this.EnableDarkMode();if(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches)return this.EnableDarkMode();this.EnableLightMode()}}const $n=new rl,sl=[c.createStaticVNode('<svg xmlns="http://www.w3.org/2000/svg" width="472.39" height="472.39" viewBox="0 0 472.39 472.39"><g class="toggle-sun"><path d="M403.21,167V69.18H305.38L236.2,0,167,69.18H69.18V167L0,236.2l69.18,69.18v97.83H167l69.18,69.18,69.18-69.18h97.83V305.38l69.18-69.18Zm-167,198.17a129,129,0,1,1,129-129A129,129,0,0,1,236.2,365.19Z"></path></g><g class="toggle-circle"><circle class="cls-1" cx="236.2" cy="236.2" r="103.78"></circle></g></svg>',1)],il=c.defineComponent({__name:"ThemeToggle",setup(t){return(e,n)=>(c.openBlock(),c.createElementBlock("button",{id:"sf-theme-toggle",onClick:n[0]||(n[0]=(...o)=>c.unref($n).Toggle&&c.unref($n).Toggle(...o))},sl))}}),al={id:"sf-layout"},cl=c.createElementVNode("div",{class:"sf-layout-menu-toggler-logo"},null,-1),ll={class:"title"},ul={class:"sf-layout-nav-content"},dl=c.createElementVNode("section",{id:"sf-layout-page-title"},null,-1),fl={id:"sf-layout-content"},pl=c.defineComponent({__name:"Layout",emits:["mounted","logout"],setup(t,{emit:e}){const n=fn(),o=e;return c.onMounted(()=>{o("mounted")}),(r,s)=>(c.openBlock(),c.createElementBlock("div",al,[c.createElementVNode("header",null,[c.createElementVNode("div",{class:c.normalizeClass(["sf-layout-menu-toggler",{invert:c.unref(n).IsVisible}]),onClick:s[0]||(s[0]=i=>c.unref(n).Toggle())},[cl,c.createVNode(ol)],2),c.createElementVNode("div",ll,[c.renderSlot(r.$slots,"title")]),c.renderSlot(r.$slots,"action"),c.createVNode(pn,{text:"alternar tema"},{default:c.withCtx(()=>[c.createVNode(il)]),_:1}),c.createVNode(Zc,{onLogout:s[1]||(s[1]=i=>o("logout"))})]),c.createElementVNode("nav",{class:c.normalizeClass({visible:c.unref(n).IsVisible})},[c.createElementVNode("div",ul,[c.renderSlot(r.$slots,"menu")])],2),c.createElementVNode("main",{class:c.normalizeClass({"menu-visible":c.unref(n).IsVisible})},[dl,c.createElementVNode("section",fl,[c.renderSlot(r.$slots,"content")])],2)]))}}),hl=["href","data-active","onClick"],ml={class:"sf-navmenulink-text"},gl=c.defineComponent({__name:"NavMenuLink",props:{href:{},text:{},icon:{},iconFilled:{type:Boolean},exact:{type:Boolean}},setup(t){const e=t,n=fn();function o(r,s){r.preventDefault();const f=r.target.closest(".sf-layout-nav-content");s(),f&&f.clientWidth+10>document.body.clientWidth&&n.Close()}return(r,s)=>{const i=c.resolveComponent("router-link");return c.openBlock(),c.createBlock(i,{to:e.href,custom:""},{default:c.withCtx(({href:f,navigate:u,isExactActive:w,isActive:E})=>[c.createElementVNode("a",{class:"sf-navmenulink",href:f,"data-active":e.exact?w:E,onClick:b=>o(b,u)},[e.icon?(c.openBlock(),c.createBlock(wt,{key:0,icon:e.icon,filled:e.iconFilled,"button-props":{tabindex:-1}},null,8,["icon","filled"])):c.createCommentVNode("",!0),c.createElementVNode("span",ml,c.toDisplayString(e.text),1)],8,hl)]),_:1},8,["to"])}}}),yl=c.defineComponent({__name:"ScrollToTop",setup(t){const e=c.ref(!1),n=`--${+new Date}`;let o=null;function r(){o==null||o.scrollTo(0,0)}return c.onMounted(()=>{var s;o=((s=document.getElementById(n))==null?void 0:s.parentElement)??null,o&&o.addEventListener("scroll",function(){e.value=this.scrollTop-this.clientHeight>0})}),(s,i)=>(c.openBlock(),c.createElementBlock("button",{id:n,class:c.normalizeClass(["sf-scrollToTop",{"sf-scrollToTop-visible":e.value}]),onClick:r},null,2))}}),bl=c.defineComponent({__name:"Content",props:{class:{},style:{},disableBodyPadding:{type:Boolean},disableHeaderPadding:{type:Boolean},disableFooterPadding:{type:Boolean}},setup(t){const e=t;function n(){return new Ke("sf-content").AddClass(e.class,!!e.class).Build()}function o(){return new Ke("sf-content-body").AddClass("sf-content-no-padding",e.disableBodyPadding).Build()}function r(){return new Ke("sf-content-header").AddClass("sf-content-no-padding",e.disableHeaderPadding).Build()}function s(){return new Ke("sf-content-footer").AddClass("sf-content-no-padding",e.disableFooterPadding).Build()}return(i,f)=>(c.openBlock(),c.createElementBlock("div",{class:c.normalizeClass(n()),style:c.normalizeStyle(e.style)},[c.createElementVNode("div",{class:c.normalizeClass(r())},[c.renderSlot(i.$slots,"header")],2),c.createElementVNode("div",{class:c.normalizeClass(o())},[c.renderSlot(i.$slots,"default"),c.createVNode(yl)],2),c.createElementVNode("div",{class:c.normalizeClass(s())},[c.renderSlot(i.$slots,"footer")],2)],6))}}),wl={class:"sf-tab-navigation"},El=[c.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"w-6 h-6"},[c.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M15.75 19.5L8.25 12l7.5-7.5"})],-1)],Al=["data-active"],kl=["href","onClick"],Cl=[c.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"w-6 h-6"},[c.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M8.25 4.5l7.5 7.5-7.5 7.5"})],-1)],xl=c.defineComponent({__name:"TabNavigation",props:{tabs:{}},setup(t){const e=t,n=c.ref(null),o=new ResizeObserver(u=>{f()}),r=c.ref(!1),s=c.ref(!1);function i(u=!1){const w=n.value.clientWidth;n.value.scrollLeft+=u?-w:w}function f(){const u=n.value.scrollWidth-n.value.clientWidth;r.value=n.value.scrollLeft>10,s.value=n.value.scrollLeft<u-10}return c.onMounted(()=>{n.value.addEventListener("scroll",f),o.observe(n.value)}),c.onBeforeUnmount(()=>{var u;try{(u=n.value)==null||u.removeEventListener("scroll",f),o.unobserve(n.value),o.disconnect()}catch{}}),(u,w)=>{const E=c.resolveComponent("RouterLink");return c.openBlock(),c.createElementBlock("div",wl,[c.createElementVNode("div",{class:c.normalizeClass(["left-arrow",{active:r.value}]),onClick:w[0]||(w[0]=b=>i(!0))},El,2),c.createElementVNode("ul",{ref_key:"trackerContainer",ref:n},[(c.openBlock(!0),c.createElementBlock(c.Fragment,null,c.renderList(e.tabs,b=>(c.openBlock(),c.createBlock(E,{to:b.route,custom:!0},{default:c.withCtx(({navigate:j,isActive:$})=>[c.createElementVNode("li",{"data-active":$},[c.renderSlot(u.$slots,"item",{item:b,navigate:j,isActive:$},()=>[c.createElementVNode("a",{href:b.route,class:c.normalizeClass({active:$}),onClick:j},c.toDisplayString(b.text),11,kl)])],8,Al)]),_:2},1032,["to"]))),256))],512),c.createElementVNode("div",{class:c.normalizeClass(["right-arrow",{active:s.value}]),onClick:w[1]||(w[1]=b=>i())},Cl,2)])}}}),Sl=["data-icon"],_l=c.defineComponent({__name:"Message",props:{color:{default:"info"},class:{},style:{},icon:{}},setup(t){const e=t,n=c.computed(()=>{if(e.icon)return e.icon;switch(e.color){case"error":return"cancel";case"info":return"info";case"warn":return"warning";case"success":return"check";case"help":return"help";default:return null}}),o=c.computed(()=>new Ke("sf-message").AddClass("sf-message-error",e.color==="error").AddClass("sf-message-info",e.color==="info").AddClass("sf-message-warning",e.color==="warn").AddClass("sf-message-success",e.color==="success").AddClass("sf-message-help",e.color==="help").AddClass("sf-message-primary",e.color==="primary").AddClass("sf-message-secondary",e.color==="secondary").AddClass(e.class).Build());return(r,s)=>(c.openBlock(),c.createElementBlock("div",{class:c.normalizeClass(o.value),"data-icon":n.value},[c.renderSlot(r.$slots,"default")],10,Sl))}});var vl=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Tl(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function Pl(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var n=function o(){return this instanceof o?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};n.prototype=e.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(t).forEach(function(o){var r=Object.getOwnPropertyDescriptor(t,o);Object.defineProperty(n,o,r.get?r:{enumerable:!0,get:function(){return t[o]}})}),n}var Qt={};Qt.byteLength=Ol,Qt.toByteArray=Bl,Qt.fromByteArray=Ul;for(var De=[],Oe=[],Rl=typeof Uint8Array<"u"?Uint8Array:Array,Hn="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",ft=0,Ll=Hn.length;ft<Ll;++ft)De[ft]=Hn[ft],Oe[Hn.charCodeAt(ft)]=ft;Oe[45]=62,Oe[95]=63;function Er(t){var e=t.length;if(e%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=t.indexOf("=");n===-1&&(n=e);var o=n===e?0:4-n%4;return[n,o]}function Ol(t){var e=Er(t),n=e[0],o=e[1];return(n+o)*3/4-o}function Il(t,e,n){return(e+n)*3/4-n}function Bl(t){var e,n=Er(t),o=n[0],r=n[1],s=new Rl(Il(t,o,r)),i=0,f=r>0?o-4:o,u;for(u=0;u<f;u+=4)e=Oe[t.charCodeAt(u)]<<18|Oe[t.charCodeAt(u+1)]<<12|Oe[t.charCodeAt(u+2)]<<6|Oe[t.charCodeAt(u+3)],s[i++]=e>>16&255,s[i++]=e>>8&255,s[i++]=e&255;return r===2&&(e=Oe[t.charCodeAt(u)]<<2|Oe[t.charCodeAt(u+1)]>>4,s[i++]=e&255),r===1&&(e=Oe[t.charCodeAt(u)]<<10|Oe[t.charCodeAt(u+1)]<<4|Oe[t.charCodeAt(u+2)]>>2,s[i++]=e>>8&255,s[i++]=e&255),s}function Nl(t){return De[t>>18&63]+De[t>>12&63]+De[t>>6&63]+De[t&63]}function Fl(t,e,n){for(var o,r=[],s=e;s<n;s+=3)o=(t[s]<<16&16711680)+(t[s+1]<<8&65280)+(t[s+2]&255),r.push(Nl(o));return r.join("")}function Ul(t){for(var e,n=t.length,o=n%3,r=[],s=16383,i=0,f=n-o;i<f;i+=s)r.push(Fl(t,i,i+s>f?f:i+s));return o===1?(e=t[n-1],r.push(De[e>>2]+De[e<<4&63]+"==")):o===2&&(e=(t[n-2]<<8)+t[n-1],r.push(De[e>>10]+De[e>>4&63]+De[e<<2&63]+"=")),r.join("")}var Ar={exports:{}};const kr=Pl(Object.freeze(Object.defineProperty({__proto__:null,default:{}},Symbol.toStringTag,{value:"Module"})));/**
64
+ If you think this parameter should be updatable, request it here: https://github.com/sweetalert2/sweetalert2/issues/new?template=02_feature_request.md`)}),e};function oc(){const t=Y.domCache.get(this),e=Y.innerParams.get(this);if(!e){xo(this);return}t.popup&&J.swalCloseEventFinishedCallback&&(J.swalCloseEventFinishedCallback(),delete J.swalCloseEventFinishedCallback),J.deferDisposalTimer&&(clearTimeout(J.deferDisposalTimer),delete J.deferDisposalTimer),typeof e.didDestroy=="function"&&e.didDestroy(),ic(this)}const ic=t=>{xo(t),delete t.params,delete J.keydownHandler,delete J.keydownTarget,delete J.currentInstance},xo=t=>{t.isAwaitingPromise()?(Wn(Y,t),Y.awaitingPromise.set(t,!0)):(Wn(Rt,t),Wn(Y,t))},Wn=(t,e)=>{for(const n in t)t[n].delete(e)},Io=Object.freeze(Object.defineProperty({__proto__:null,_destroy:oc,close:cn,closeModal:cn,closePopup:cn,closeToast:cn,disableButtons:Yl,disableInput:Zl,disableLoading:vo,enableButtons:Jl,enableInput:Xl,getInput:Ol,getProgressSteps:tc,handleAwaitingPromise:Ft,hideLoading:vo,isAwaitingPromise:Vl,rejectPromise:zl,resetValidationMessage:ec,showValidationMessage:Ql,update:nc},Symbol.toStringTag,{value:"Module"})),sc=t=>{const e=Y.innerParams.get(t);t.disableButtons(),e.input?Po(t,"confirm"):Gn(t,!0)},ac=t=>{const e=Y.innerParams.get(t);t.disableButtons(),e.returnInputValueOnDeny?Po(t,"deny"):qn(t,!1)},lc=(t,e)=>{t.disableButtons(),e(ht.cancel)},Po=(t,e)=>{const n=Y.innerParams.get(t);if(!n.input)return ot(`The "input" parameter is needed to be set when using returnInputValueOn${Ln(e)}`);const r=_l(t,n);n.inputValidator?cc(t,r,e):t.getInput().checkValidity()?e==="deny"?qn(t,r):Gn(t,r):(t.enableButtons(),t.showValidationMessage(n.validationMessage))},cc=(t,e,n)=>{const r=Y.innerParams.get(t);t.disableInput(),Promise.resolve().then(()=>kt(r.inputValidator(e,r.validationMessage))).then(i=>{t.enableButtons(),t.enableInput(),i?t.showValidationMessage(i):n==="deny"?qn(t,e):Gn(t,e)})},qn=(t,e)=>{const n=Y.innerParams.get(t||void 0);n.showLoaderOnDeny&&gt(et()),n.preDeny?(Y.awaitingPromise.set(t||void 0,!0),Promise.resolve().then(()=>kt(n.preDeny(e,n.validationMessage))).then(o=>{o===!1?(t.hideLoading(),Ft(t)):t.closePopup({isDenied:!0,value:typeof o>"u"?e:o})}).catch(o=>Oo(t||void 0,o))):t.closePopup({isDenied:!0,value:e})},To=(t,e)=>{t.closePopup({isConfirmed:!0,value:e})},Oo=(t,e)=>{t.rejectPromise(e)},Gn=(t,e)=>{const n=Y.innerParams.get(t||void 0);n.showLoaderOnConfirm&&gt(),n.preConfirm?(t.resetValidationMessage(),Y.awaitingPromise.set(t||void 0,!0),Promise.resolve().then(()=>kt(n.preConfirm(e,n.validationMessage))).then(o=>{Le(on())||o===!1?(t.hideLoading(),Ft(t)):To(t,typeof o>"u"?e:o)}).catch(o=>Oo(t||void 0,o))):To(t,e)},uc=(t,e,n)=>{Y.innerParams.get(t).toast?dc(t,e,n):(pc(e),mc(e),hc(t,e,n))},dc=(t,e,n)=>{e.popup.onclick=()=>{const r=Y.innerParams.get(t);r&&(fc(r)||r.timer||r.input)||n(ht.close)}},fc=t=>t.showConfirmButton||t.showDenyButton||t.showCancelButton||t.showCloseButton;let un=!1;const pc=t=>{t.popup.onmousedown=()=>{t.container.onmouseup=function(e){t.container.onmouseup=void 0,e.target===t.container&&(un=!0)}}},mc=t=>{t.container.onmousedown=()=>{t.popup.onmouseup=function(e){t.popup.onmouseup=void 0,(e.target===t.popup||t.popup.contains(e.target))&&(un=!0)}}},hc=(t,e,n)=>{e.container.onclick=r=>{const o=Y.innerParams.get(t);if(un){un=!1;return}r.target===e.container&&nn(o.allowOutsideClick)&&n(ht.backdrop)}},gc=t=>typeof t=="object"&&t.jquery,Lo=t=>t instanceof Element||gc(t),yc=t=>{const e={};return typeof t[0]=="object"&&!Lo(t[0])?Object.assign(e,t[0]):["title","html","icon"].forEach((n,r)=>{const o=t[r];typeof o=="string"||Lo(o)?e[n]=o:o!==void 0&&ot(`Unexpected type of ${n}! Expected "string" or "Element", got ${typeof o}`)}),e};function bc(...t){const e=this;return new e(...t)}function vc(t){class e extends this{_main(r,o){return super._main(r,Object.assign({},t,o))}}return e}const wc=()=>J.timeout&&J.timeout.getTimerLeft(),Bo=()=>{if(J.timeout)return aa(),J.timeout.stop()},Ro=()=>{if(J.timeout){const t=J.timeout.start();return Un(t),t}},Ec=()=>{const t=J.timeout;return t&&(t.running?Bo():Ro())},Sc=t=>{if(J.timeout){const e=J.timeout.increase(t);return Un(e,!0),e}},_c=()=>J.timeout&&J.timeout.isRunning();let Fo=!1;const Jn={};function Cc(t="data-swal-template"){Jn[t]=this,Fo||(document.body.addEventListener("click",Ac),Fo=!0)}const Ac=t=>{for(let e=t.target;e&&e!==document;e=e.parentNode)for(const n in Jn){const r=e.getAttribute(n);if(r){Jn[n].fire({template:r});return}}},kc=Object.freeze(Object.defineProperty({__proto__:null,argsToParams:yc,bindClickHandler:Cc,clickCancel:Rl,clickConfirm:wo,clickDeny:Bl,enableLoading:gt,fire:bc,getActions:Tt,getCancelButton:it,getCloseButton:$n,getConfirmButton:Ue,getContainer:ye,getDenyButton:et,getFocusableElements:Nn,getFooter:eo,getHtmlContainer:rn,getIcon:Pt,getImage:Zr,getInputLabel:na,getLoader:pt,getPopup:oe,getTimerLeft:wc,getTimerProgressBar:sn,getTitle:Xr,getValidationMessage:on,increaseTimer:Sc,isDeprecatedParameter:Fn,isLoading:oa,isTimerRunning:_c,isUpdatableParameter:Jr,isValidParameter:Gr,isVisible:Ll,mixin:vc,resumeTimer:Ro,showLoading:gt,stopTimer:Bo,toggleTimer:Ec},Symbol.toStringTag,{value:"Module"}));let Yn;class yt{constructor(...e){if(typeof window>"u")return;Yn=this;const n=Object.freeze(this.constructor.argsToParams(e));Object.defineProperties(this,{params:{value:n,writable:!1,enumerable:!0,configurable:!0}});const r=this._main(this.params);Y.promise.set(this,r)}_main(e,n={}){ea(Object.assign({},n,e)),J.currentInstance&&(J.currentInstance._destroy(),Dn()&&po()),J.currentInstance=this;const r=Ic(e,n);sl(r),Object.freeze(r),J.timeout&&(J.timeout.stop(),delete J.timeout),clearTimeout(J.restoreFocusTimeout);const o=Pc(this);return fo(this,r),Y.innerParams.set(this,r),xc(this,o,r)}then(e){return Y.promise.get(this).then(e)}finally(e){return Y.promise.get(this).finally(e)}}const xc=(t,e,n)=>new Promise((r,o)=>{const i=s=>{t.closePopup({isDismissed:!0,dismiss:s})};Rt.swalPromiseResolve.set(t,r),Rt.swalPromiseReject.set(t,o),e.confirmButton.onclick=()=>sc(t),e.denyButton.onclick=()=>ac(t),e.cancelButton.onclick=()=>lc(t,i),e.closeButton.onclick=()=>i(ht.close),uc(t,e,i),Fl(t,J,n,i),Sl(t,n),yl(n),Tc(J,n,i),Oc(e,n),setTimeout(()=>{e.container.scrollTop=0})}),Ic=(t,e)=>{const n=Ya(t),r=Object.assign({},ft,e,n,t);return r.showClass=Object.assign({},ft.showClass,r.showClass),r.hideClass=Object.assign({},ft.hideClass,r.hideClass),r},Pc=t=>{const e={popup:oe(),container:ye(),actions:Tt(),confirmButton:Ue(),denyButton:et(),cancelButton:it(),loader:pt(),closeButton:$n(),validationMessage:on(),progressSteps:Qr()};return Y.domCache.set(t,e),e},Tc=(t,e,n)=>{const r=sn();ve(r),e.timer&&(t.timeout=new al(()=>{n("timer"),delete t.timeout},e.timer),e.timerProgressBar&&(he(r),$e(r,e,"timerProgressBar"),setTimeout(()=>{t.timeout&&t.timeout.running&&Un(e.timer)})))},Oc=(t,e)=>{if(!e.toast){if(!nn(e.allowEnterKey))return Bc();Lc(t,e)||zn(e,-1,1)}},Lc=(t,e)=>e.focusDeny&&Le(t.denyButton)?(t.denyButton.focus(),!0):e.focusCancel&&Le(t.cancelButton)?(t.cancelButton.focus(),!0):e.focusConfirm&&Le(t.confirmButton)?(t.confirmButton.focus(),!0):!1,Bc=()=>{document.activeElement instanceof HTMLElement&&typeof document.activeElement.blur=="function"&&document.activeElement.blur()};Object.assign(yt.prototype,Io),Object.assign(yt,kc),Object.keys(Io).forEach(t=>{yt[t]=function(...e){if(Yn)return Yn[t](...e)}}),yt.DismissReason=ht,yt.version="11.4.8";const bt=yt;bt.default=bt;/*! @license DOMPurify 3.0.9 | (c) Cure53 and other contributors | Released under the Apache license 2.0 and Mozilla Public License 2.0 | github.com/cure53/DOMPurify/blob/3.0.9/LICENSE */const{entries:$o,setPrototypeOf:No,isFrozen:Rc,getPrototypeOf:Fc,getOwnPropertyDescriptor:$c}=Object;let{freeze:Se,seal:He,create:Do}=Object,{apply:Xn,construct:Zn}=typeof Reflect<"u"&&Reflect;Se||(Se=function(e){return e}),He||(He=function(e){return e}),Xn||(Xn=function(e,n,r){return e.apply(n,r)}),Zn||(Zn=function(e,n){return new e(...n)});const dn=Re(Array.prototype.forEach),Mo=Re(Array.prototype.pop),$t=Re(Array.prototype.push),fn=Re(String.prototype.toLowerCase),Qn=Re(String.prototype.toString),Nc=Re(String.prototype.match),Nt=Re(String.prototype.replace),Dc=Re(String.prototype.indexOf),Mc=Re(String.prototype.trim),je=Re(Object.prototype.hasOwnProperty),Be=Re(RegExp.prototype.test),Dt=Uc(TypeError);function Re(t){return function(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return Xn(t,e,r)}}function Uc(t){return function(){for(var e=arguments.length,n=new Array(e),r=0;r<e;r++)n[r]=arguments[r];return Zn(t,n)}}function X(t,e){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:fn;No&&No(t,null);let r=e.length;for(;r--;){let o=e[r];if(typeof o=="string"){const i=n(o);i!==o&&(Rc(e)||(e[r]=i),o=i)}t[o]=!0}return t}function Hc(t){for(let e=0;e<t.length;e++)je(t,e)||(t[e]=null);return t}function lt(t){const e=Do(null);for(const[n,r]of $o(t))je(t,n)&&(Array.isArray(r)?e[n]=Hc(r):r&&typeof r=="object"&&r.constructor===Object?e[n]=lt(r):e[n]=r);return e}function pn(t,e){for(;t!==null;){const r=$c(t,e);if(r){if(r.get)return Re(r.get);if(typeof r.value=="function")return Re(r.value)}t=Fc(t)}function n(){return null}return n}const Uo=Se(["a","abbr","acronym","address","area","article","aside","audio","b","bdi","bdo","big","blink","blockquote","body","br","button","canvas","caption","center","cite","code","col","colgroup","content","data","datalist","dd","decorator","del","details","dfn","dialog","dir","div","dl","dt","element","em","fieldset","figcaption","figure","font","footer","form","h1","h2","h3","h4","h5","h6","head","header","hgroup","hr","html","i","img","input","ins","kbd","label","legend","li","main","map","mark","marquee","menu","menuitem","meter","nav","nobr","ol","optgroup","option","output","p","picture","pre","progress","q","rp","rt","ruby","s","samp","section","select","shadow","small","source","spacer","span","strike","strong","style","sub","summary","sup","table","tbody","td","template","textarea","tfoot","th","thead","time","tr","track","tt","u","ul","var","video","wbr"]),er=Se(["svg","a","altglyph","altglyphdef","altglyphitem","animatecolor","animatemotion","animatetransform","circle","clippath","defs","desc","ellipse","filter","font","g","glyph","glyphref","hkern","image","line","lineargradient","marker","mask","metadata","mpath","path","pattern","polygon","polyline","radialgradient","rect","stop","style","switch","symbol","text","textpath","title","tref","tspan","view","vkern"]),tr=Se(["feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence"]),jc=Se(["animate","color-profile","cursor","discard","font-face","font-face-format","font-face-name","font-face-src","font-face-uri","foreignobject","hatch","hatchpath","mesh","meshgradient","meshpatch","meshrow","missing-glyph","script","set","solidcolor","unknown","use"]),nr=Se(["math","menclose","merror","mfenced","mfrac","mglyph","mi","mlabeledtr","mmultiscripts","mn","mo","mover","mpadded","mphantom","mroot","mrow","ms","mspace","msqrt","mstyle","msub","msup","msubsup","mtable","mtd","mtext","mtr","munder","munderover","mprescripts"]),Vc=Se(["maction","maligngroup","malignmark","mlongdiv","mscarries","mscarry","msgroup","mstack","msline","msrow","semantics","annotation","annotation-xml","mprescripts","none"]),Ho=Se(["#text"]),jo=Se(["accept","action","align","alt","autocapitalize","autocomplete","autopictureinpicture","autoplay","background","bgcolor","border","capture","cellpadding","cellspacing","checked","cite","class","clear","color","cols","colspan","controls","controlslist","coords","crossorigin","datetime","decoding","default","dir","disabled","disablepictureinpicture","disableremoteplayback","download","draggable","enctype","enterkeyhint","face","for","headers","height","hidden","high","href","hreflang","id","inputmode","integrity","ismap","kind","label","lang","list","loading","loop","low","max","maxlength","media","method","min","minlength","multiple","muted","name","nonce","noshade","novalidate","nowrap","open","optimum","pattern","placeholder","playsinline","poster","preload","pubdate","radiogroup","readonly","rel","required","rev","reversed","role","rows","rowspan","spellcheck","scope","selected","shape","size","sizes","span","srclang","start","src","srcset","step","style","summary","tabindex","title","translate","type","usemap","valign","value","width","xmlns","slot"]),rr=Se(["accent-height","accumulate","additive","alignment-baseline","ascent","attributename","attributetype","azimuth","basefrequency","baseline-shift","begin","bias","by","class","clip","clippathunits","clip-path","clip-rule","color","color-interpolation","color-interpolation-filters","color-profile","color-rendering","cx","cy","d","dx","dy","diffuseconstant","direction","display","divisor","dur","edgemode","elevation","end","fill","fill-opacity","fill-rule","filter","filterunits","flood-color","flood-opacity","font-family","font-size","font-size-adjust","font-stretch","font-style","font-variant","font-weight","fx","fy","g1","g2","glyph-name","glyphref","gradientunits","gradienttransform","height","href","id","image-rendering","in","in2","k","k1","k2","k3","k4","kerning","keypoints","keysplines","keytimes","lang","lengthadjust","letter-spacing","kernelmatrix","kernelunitlength","lighting-color","local","marker-end","marker-mid","marker-start","markerheight","markerunits","markerwidth","maskcontentunits","maskunits","max","mask","media","method","mode","min","name","numoctaves","offset","operator","opacity","order","orient","orientation","origin","overflow","paint-order","path","pathlength","patterncontentunits","patterntransform","patternunits","points","preservealpha","preserveaspectratio","primitiveunits","r","rx","ry","radius","refx","refy","repeatcount","repeatdur","restart","result","rotate","scale","seed","shape-rendering","specularconstant","specularexponent","spreadmethod","startoffset","stddeviation","stitchtiles","stop-color","stop-opacity","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke","stroke-width","style","surfacescale","systemlanguage","tabindex","targetx","targety","transform","transform-origin","text-anchor","text-decoration","text-rendering","textlength","type","u1","u2","unicode","values","viewbox","visibility","version","vert-adv-y","vert-origin-x","vert-origin-y","width","word-spacing","wrap","writing-mode","xchannelselector","ychannelselector","x","x1","x2","xmlns","y","y1","y2","z","zoomandpan"]),Vo=Se(["accent","accentunder","align","bevelled","close","columnsalign","columnlines","columnspan","denomalign","depth","dir","display","displaystyle","encoding","fence","frame","height","href","id","largeop","length","linethickness","lspace","lquote","mathbackground","mathcolor","mathsize","mathvariant","maxsize","minsize","movablelimits","notation","numalign","open","rowalign","rowlines","rowspacing","rowspan","rspace","rquote","scriptlevel","scriptminsize","scriptsizemultiplier","selection","separator","separators","stretchy","subscriptshift","supscriptshift","symmetric","voffset","width","xmlns"]),mn=Se(["xlink:href","xml:id","xlink:title","xml:space","xmlns:xlink"]),Kc=He(/\{\{[\w\W]*|[\w\W]*\}\}/gm),zc=He(/<%[\w\W]*|[\w\W]*%>/gm),Wc=He(/\${[\w\W]*}/gm),qc=He(/^data-[\-\w.\u00B7-\uFFFF]/),Gc=He(/^aria-[\-\w]+$/),Ko=He(/^(?:(?:(?:f|ht)tps?|mailto|tel|callto|sms|cid|xmpp):|[^a-z]|[a-z+.\-]+(?:[^a-z+.\-:]|$))/i),Jc=He(/^(?:\w+script|data):/i),Yc=He(/[\u0000-\u0020\u00A0\u1680\u180E\u2000-\u2029\u205F\u3000]/g),zo=He(/^html$/i);var Wo=Object.freeze({__proto__:null,MUSTACHE_EXPR:Kc,ERB_EXPR:zc,TMPLIT_EXPR:Wc,DATA_ATTR:qc,ARIA_ATTR:Gc,IS_ALLOWED_URI:Ko,IS_SCRIPT_OR_DATA:Jc,ATTR_WHITESPACE:Yc,DOCTYPE_NAME:zo});const Xc=function(){return typeof window>"u"?null:window},Zc=function(e,n){if(typeof e!="object"||typeof e.createPolicy!="function")return null;let r=null;const o="data-tt-policy-suffix";n&&n.hasAttribute(o)&&(r=n.getAttribute(o));const i="dompurify"+(r?"#"+r:"");try{return e.createPolicy(i,{createHTML(s){return s},createScriptURL(s){return s}})}catch{return console.warn("TrustedTypes policy "+i+" could not be created."),null}};function qo(){let t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:Xc();const e=H=>qo(H);if(e.version="3.0.9",e.removed=[],!t||!t.document||t.document.nodeType!==9)return e.isSupported=!1,e;let{document:n}=t;const r=n,o=r.currentScript,{DocumentFragment:i,HTMLTemplateElement:s,Node:c,Element:a,NodeFilter:u,NamedNodeMap:f=t.NamedNodeMap||t.MozNamedAttrMap,HTMLFormElement:p,DOMParser:v,trustedTypes:w}=t,C=a.prototype,x=pn(C,"cloneNode"),_=pn(C,"nextSibling"),$=pn(C,"childNodes"),q=pn(C,"parentNode");if(typeof s=="function"){const H=n.createElement("template");H.content&&H.content.ownerDocument&&(n=H.content.ownerDocument)}let V,pe="";const{implementation:de,createNodeIterator:y,createDocumentFragment:L,getElementsByTagName:j}=n,{importNode:R}=r;let B={};e.isSupported=typeof $o=="function"&&typeof q=="function"&&de&&de.createHTMLDocument!==void 0;const{MUSTACHE_EXPR:O,ERB_EXPR:W,TMPLIT_EXPR:A,DATA_ATTR:G,ARIA_ATTR:ie,IS_SCRIPT_OR_DATA:ce,ATTR_WHITESPACE:fe}=Wo;let{IS_ALLOWED_URI:_e}=Wo,K=null;const xe=X({},[...Uo,...er,...tr,...nr,...Ho]);let d=null;const h=X({},[...jo,...rr,...Vo,...mn]);let E=Object.seal(Do(null,{tagNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},attributeNameCheck:{writable:!0,configurable:!1,enumerable:!0,value:null},allowCustomizedBuiltInElements:{writable:!0,configurable:!1,enumerable:!0,value:!1}})),I=null,S=null,F=!0,k=!0,P=!1,M=!0,N=!1,z=!1,Q=!1,Ie=!1,Ce=!1,ge=!1,qe=!1,cs=!0,us=!1;const Yp="user-content-";let $r=!0,Qt=!1,St={},_t=null;const ds=X({},["annotation-xml","audio","colgroup","desc","foreignobject","head","iframe","math","mi","mn","mo","ms","mtext","noembed","noframes","noscript","plaintext","script","style","svg","template","thead","title","video","xmp"]);let fs=null;const ps=X({},["audio","video","img","source","image","track"]);let Nr=null;const ms=X({},["alt","class","for","id","label","name","pattern","placeholder","role","summary","title","value","style","xmlns"]),In="http://www.w3.org/1998/Math/MathML",Pn="http://www.w3.org/2000/svg",Ye="http://www.w3.org/1999/xhtml";let Ct=Ye,Dr=!1,Mr=null;const Xp=X({},[In,Pn,Ye],Qn);let en=null;const Zp=["application/xhtml+xml","text/html"],Qp="text/html";let me=null,At=null;const em=n.createElement("form"),hs=function(m){return m instanceof RegExp||m instanceof Function},Ur=function(){let m=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};if(!(At&&At===m)){if((!m||typeof m!="object")&&(m={}),m=lt(m),en=Zp.indexOf(m.PARSER_MEDIA_TYPE)===-1?Qp:m.PARSER_MEDIA_TYPE,me=en==="application/xhtml+xml"?Qn:fn,K=je(m,"ALLOWED_TAGS")?X({},m.ALLOWED_TAGS,me):xe,d=je(m,"ALLOWED_ATTR")?X({},m.ALLOWED_ATTR,me):h,Mr=je(m,"ALLOWED_NAMESPACES")?X({},m.ALLOWED_NAMESPACES,Qn):Xp,Nr=je(m,"ADD_URI_SAFE_ATTR")?X(lt(ms),m.ADD_URI_SAFE_ATTR,me):ms,fs=je(m,"ADD_DATA_URI_TAGS")?X(lt(ps),m.ADD_DATA_URI_TAGS,me):ps,_t=je(m,"FORBID_CONTENTS")?X({},m.FORBID_CONTENTS,me):ds,I=je(m,"FORBID_TAGS")?X({},m.FORBID_TAGS,me):{},S=je(m,"FORBID_ATTR")?X({},m.FORBID_ATTR,me):{},St=je(m,"USE_PROFILES")?m.USE_PROFILES:!1,F=m.ALLOW_ARIA_ATTR!==!1,k=m.ALLOW_DATA_ATTR!==!1,P=m.ALLOW_UNKNOWN_PROTOCOLS||!1,M=m.ALLOW_SELF_CLOSE_IN_ATTR!==!1,N=m.SAFE_FOR_TEMPLATES||!1,z=m.WHOLE_DOCUMENT||!1,Ce=m.RETURN_DOM||!1,ge=m.RETURN_DOM_FRAGMENT||!1,qe=m.RETURN_TRUSTED_TYPE||!1,Ie=m.FORCE_BODY||!1,cs=m.SANITIZE_DOM!==!1,us=m.SANITIZE_NAMED_PROPS||!1,$r=m.KEEP_CONTENT!==!1,Qt=m.IN_PLACE||!1,_e=m.ALLOWED_URI_REGEXP||Ko,Ct=m.NAMESPACE||Ye,E=m.CUSTOM_ELEMENT_HANDLING||{},m.CUSTOM_ELEMENT_HANDLING&&hs(m.CUSTOM_ELEMENT_HANDLING.tagNameCheck)&&(E.tagNameCheck=m.CUSTOM_ELEMENT_HANDLING.tagNameCheck),m.CUSTOM_ELEMENT_HANDLING&&hs(m.CUSTOM_ELEMENT_HANDLING.attributeNameCheck)&&(E.attributeNameCheck=m.CUSTOM_ELEMENT_HANDLING.attributeNameCheck),m.CUSTOM_ELEMENT_HANDLING&&typeof m.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements=="boolean"&&(E.allowCustomizedBuiltInElements=m.CUSTOM_ELEMENT_HANDLING.allowCustomizedBuiltInElements),N&&(k=!1),ge&&(Ce=!0),St&&(K=X({},Ho),d=[],St.html===!0&&(X(K,Uo),X(d,jo)),St.svg===!0&&(X(K,er),X(d,rr),X(d,mn)),St.svgFilters===!0&&(X(K,tr),X(d,rr),X(d,mn)),St.mathMl===!0&&(X(K,nr),X(d,Vo),X(d,mn))),m.ADD_TAGS&&(K===xe&&(K=lt(K)),X(K,m.ADD_TAGS,me)),m.ADD_ATTR&&(d===h&&(d=lt(d)),X(d,m.ADD_ATTR,me)),m.ADD_URI_SAFE_ATTR&&X(Nr,m.ADD_URI_SAFE_ATTR,me),m.FORBID_CONTENTS&&(_t===ds&&(_t=lt(_t)),X(_t,m.FORBID_CONTENTS,me)),$r&&(K["#text"]=!0),z&&X(K,["html","head","body"]),K.table&&(X(K,["tbody"]),delete I.tbody),m.TRUSTED_TYPES_POLICY){if(typeof m.TRUSTED_TYPES_POLICY.createHTML!="function")throw Dt('TRUSTED_TYPES_POLICY configuration option must provide a "createHTML" hook.');if(typeof m.TRUSTED_TYPES_POLICY.createScriptURL!="function")throw Dt('TRUSTED_TYPES_POLICY configuration option must provide a "createScriptURL" hook.');V=m.TRUSTED_TYPES_POLICY,pe=V.createHTML("")}else V===void 0&&(V=Zc(w,o)),V!==null&&typeof pe=="string"&&(pe=V.createHTML(""));Se&&Se(m),At=m}},gs=X({},["mi","mo","mn","ms","mtext"]),ys=X({},["foreignobject","desc","title","annotation-xml"]),tm=X({},["title","style","font","a","script"]),bs=X({},[...er,...tr,...jc]),vs=X({},[...nr,...Vc]),nm=function(m){let T=q(m);(!T||!T.tagName)&&(T={namespaceURI:Ct,tagName:"template"});const U=fn(m.tagName),se=fn(T.tagName);return Mr[m.namespaceURI]?m.namespaceURI===Pn?T.namespaceURI===Ye?U==="svg":T.namespaceURI===In?U==="svg"&&(se==="annotation-xml"||gs[se]):!!bs[U]:m.namespaceURI===In?T.namespaceURI===Ye?U==="math":T.namespaceURI===Pn?U==="math"&&ys[se]:!!vs[U]:m.namespaceURI===Ye?T.namespaceURI===Pn&&!ys[se]||T.namespaceURI===In&&!gs[se]?!1:!vs[U]&&(tm[U]||!bs[U]):!!(en==="application/xhtml+xml"&&Mr[m.namespaceURI]):!1},ut=function(m){$t(e.removed,{element:m});try{m.parentNode.removeChild(m)}catch{m.remove()}},Hr=function(m,T){try{$t(e.removed,{attribute:T.getAttributeNode(m),from:T})}catch{$t(e.removed,{attribute:null,from:T})}if(T.removeAttribute(m),m==="is"&&!d[m])if(Ce||ge)try{ut(T)}catch{}else try{T.setAttribute(m,"")}catch{}},ws=function(m){let T=null,U=null;if(Ie)m="<remove></remove>"+m;else{const Ee=Nc(m,/^[\r\n\t ]+/);U=Ee&&Ee[0]}en==="application/xhtml+xml"&&Ct===Ye&&(m='<html xmlns="http://www.w3.org/1999/xhtml"><head></head><body>'+m+"</body></html>");const se=V?V.createHTML(m):m;if(Ct===Ye)try{T=new v().parseFromString(se,en)}catch{}if(!T||!T.documentElement){T=de.createDocument(Ct,"template",null);try{T.documentElement.innerHTML=Dr?pe:se}catch{}}const we=T.body||T.documentElement;return m&&U&&we.insertBefore(n.createTextNode(U),we.childNodes[0]||null),Ct===Ye?j.call(T,z?"html":"body")[0]:z?T.documentElement:we},Es=function(m){return y.call(m.ownerDocument||m,m,u.SHOW_ELEMENT|u.SHOW_COMMENT|u.SHOW_TEXT,null)},rm=function(m){return m instanceof p&&(typeof m.nodeName!="string"||typeof m.textContent!="string"||typeof m.removeChild!="function"||!(m.attributes instanceof f)||typeof m.removeAttribute!="function"||typeof m.setAttribute!="function"||typeof m.namespaceURI!="string"||typeof m.insertBefore!="function"||typeof m.hasChildNodes!="function")},Ss=function(m){return typeof c=="function"&&m instanceof c},Xe=function(m,T,U){B[m]&&dn(B[m],se=>{se.call(e,T,U,At)})},_s=function(m){let T=null;if(Xe("beforeSanitizeElements",m,null),rm(m))return ut(m),!0;const U=me(m.nodeName);if(Xe("uponSanitizeElement",m,{tagName:U,allowedTags:K}),m.hasChildNodes()&&!Ss(m.firstElementChild)&&Be(/<[/\w]/g,m.innerHTML)&&Be(/<[/\w]/g,m.textContent))return ut(m),!0;if(!K[U]||I[U]){if(!I[U]&&As(U)&&(E.tagNameCheck instanceof RegExp&&Be(E.tagNameCheck,U)||E.tagNameCheck instanceof Function&&E.tagNameCheck(U)))return!1;if($r&&!_t[U]){const se=q(m)||m.parentNode,we=$(m)||m.childNodes;if(we&&se){const Ee=we.length;for(let Pe=Ee-1;Pe>=0;--Pe)se.insertBefore(x(we[Pe],!0),_(m))}}return ut(m),!0}return m instanceof a&&!nm(m)||(U==="noscript"||U==="noembed"||U==="noframes")&&Be(/<\/no(script|embed|frames)/i,m.innerHTML)?(ut(m),!0):(N&&m.nodeType===3&&(T=m.textContent,dn([O,W,A],se=>{T=Nt(T,se," ")}),m.textContent!==T&&($t(e.removed,{element:m.cloneNode()}),m.textContent=T)),Xe("afterSanitizeElements",m,null),!1)},Cs=function(m,T,U){if(cs&&(T==="id"||T==="name")&&(U in n||U in em))return!1;if(!(k&&!S[T]&&Be(G,T))){if(!(F&&Be(ie,T))){if(!d[T]||S[T]){if(!(As(m)&&(E.tagNameCheck instanceof RegExp&&Be(E.tagNameCheck,m)||E.tagNameCheck instanceof Function&&E.tagNameCheck(m))&&(E.attributeNameCheck instanceof RegExp&&Be(E.attributeNameCheck,T)||E.attributeNameCheck instanceof Function&&E.attributeNameCheck(T))||T==="is"&&E.allowCustomizedBuiltInElements&&(E.tagNameCheck instanceof RegExp&&Be(E.tagNameCheck,U)||E.tagNameCheck instanceof Function&&E.tagNameCheck(U))))return!1}else if(!Nr[T]){if(!Be(_e,Nt(U,fe,""))){if(!((T==="src"||T==="xlink:href"||T==="href")&&m!=="script"&&Dc(U,"data:")===0&&fs[m])){if(!(P&&!Be(ce,Nt(U,fe,"")))){if(U)return!1}}}}}}return!0},As=function(m){return m!=="annotation-xml"&&m.indexOf("-")>0},ks=function(m){Xe("beforeSanitizeAttributes",m,null);const{attributes:T}=m;if(!T)return;const U={attrName:"",attrValue:"",keepAttr:!0,allowedAttributes:d};let se=T.length;for(;se--;){const we=T[se],{name:Ee,namespaceURI:Pe,value:dt}=we,tn=me(Ee);let Te=Ee==="value"?dt:Mc(dt);if(U.attrName=tn,U.attrValue=Te,U.keepAttr=!0,U.forceKeepAttr=void 0,Xe("uponSanitizeAttribute",m,U),Te=U.attrValue,U.forceKeepAttr||(Hr(Ee,m),!U.keepAttr))continue;if(!M&&Be(/\/>/i,Te)){Hr(Ee,m);continue}N&&dn([O,W,A],Is=>{Te=Nt(Te,Is," ")});const xs=me(m.nodeName);if(Cs(xs,tn,Te)){if(us&&(tn==="id"||tn==="name")&&(Hr(Ee,m),Te=Yp+Te),V&&typeof w=="object"&&typeof w.getAttributeType=="function"&&!Pe)switch(w.getAttributeType(xs,tn)){case"TrustedHTML":{Te=V.createHTML(Te);break}case"TrustedScriptURL":{Te=V.createScriptURL(Te);break}}try{Pe?m.setAttributeNS(Pe,Ee,Te):m.setAttribute(Ee,Te),Mo(e.removed)}catch{}}}Xe("afterSanitizeAttributes",m,null)},om=function H(m){let T=null;const U=Es(m);for(Xe("beforeSanitizeShadowDOM",m,null);T=U.nextNode();)Xe("uponSanitizeShadowNode",T,null),!_s(T)&&(T.content instanceof i&&H(T.content),ks(T));Xe("afterSanitizeShadowDOM",m,null)};return e.sanitize=function(H){let m=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},T=null,U=null,se=null,we=null;if(Dr=!H,Dr&&(H="<!-->"),typeof H!="string"&&!Ss(H))if(typeof H.toString=="function"){if(H=H.toString(),typeof H!="string")throw Dt("dirty is not a string, aborting")}else throw Dt("toString is not a function");if(!e.isSupported)return H;if(Q||Ur(m),e.removed=[],typeof H=="string"&&(Qt=!1),Qt){if(H.nodeName){const dt=me(H.nodeName);if(!K[dt]||I[dt])throw Dt("root node is forbidden and cannot be sanitized in-place")}}else if(H instanceof c)T=ws("<!---->"),U=T.ownerDocument.importNode(H,!0),U.nodeType===1&&U.nodeName==="BODY"||U.nodeName==="HTML"?T=U:T.appendChild(U);else{if(!Ce&&!N&&!z&&H.indexOf("<")===-1)return V&&qe?V.createHTML(H):H;if(T=ws(H),!T)return Ce?null:qe?pe:""}T&&Ie&&ut(T.firstChild);const Ee=Es(Qt?H:T);for(;se=Ee.nextNode();)_s(se)||(se.content instanceof i&&om(se.content),ks(se));if(Qt)return H;if(Ce){if(ge)for(we=L.call(T.ownerDocument);T.firstChild;)we.appendChild(T.firstChild);else we=T;return(d.shadowroot||d.shadowrootmode)&&(we=R.call(r,we,!0)),we}let Pe=z?T.outerHTML:T.innerHTML;return z&&K["!doctype"]&&T.ownerDocument&&T.ownerDocument.doctype&&T.ownerDocument.doctype.name&&Be(zo,T.ownerDocument.doctype.name)&&(Pe="<!DOCTYPE "+T.ownerDocument.doctype.name+`>
65
+ `+Pe),N&&dn([O,W,A],dt=>{Pe=Nt(Pe,dt," ")}),V&&qe?V.createHTML(Pe):Pe},e.setConfig=function(){let H=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};Ur(H),Q=!0},e.clearConfig=function(){At=null,Q=!1},e.isValidAttribute=function(H,m,T){At||Ur({});const U=me(H),se=me(m);return Cs(U,se,T)},e.addHook=function(H,m){typeof m=="function"&&(B[H]=B[H]||[],$t(B[H],m))},e.removeHook=function(H){if(B[H])return Mo(B[H])},e.removeHooks=function(H){B[H]&&(B[H]=[])},e.removeAllHooks=function(){B={}},e}var Go=qo();class Jo{get IsVisible(){return bt.isVisible()}}class Qc extends Jo{constructor(){super()}async CreateAlertAsync(e){let n="info",r,o;return typeof e=="string"||Array.isArray(e)?r=Array.isArray(e)?e.join("<br />"):e:(n=e.icon??"info",o=e.title??"",r=Array.isArray(e.text)?e.text.join("<br />"):e.text),new Promise(i=>{bt.fire({allowEscapeKey:!1,allowOutsideClick:!1,icon:n,title:o,html:`<div style="max-height: 50vh; overflow: auto">${Go.sanitize(r)}</div>`}).then(()=>i(!0))})}async AlertAsync(e){return this.CreateAlertAsync({text:e,icon:"info"})}async AlertErrorAsync(e){return this.CreateAlertAsync({text:e,icon:"error"})}async AlertSuccessAsync(e){return this.CreateAlertAsync({text:e,icon:"success"})}}class eu extends Jo{async CreateConfirmAsync(e){return new Promise(n=>{bt.fire({showCancelButton:!0,allowEscapeKey:!1,allowOutsideClick:!1,icon:"question",title:e.title,html:Go.sanitize(e.text),confirmButtonText:e.confirmLabel??"confirmar",cancelButtonText:e.rejectLabel??"cancelar"}).then(r=>{n(r.isConfirmed===!0)})})}async ConfirmAsync(e){return this.CreateConfirmAsync({text:e})}}const tu=()=>new Qc,Yo=()=>new eu,nu=["data-cor"],ru={class:"sf-p-4"},ou=l.defineComponent({__name:"HeaderAvatar",emits:["logout"],setup(t,{emit:e}){const n=Yo(),r=l.ref("?"),o=e;async function i(){await n.CreateConfirmAsync({text:"Você deseja sair da conta?",confirmLabel:"sair"})&&o("logout")}function s(){const u=sessionStorage.getItem("name");let f="?";if(!u)return f;const p=u.split(" ").filter(w=>w.length>0).map(w=>w[0].toUpperCase()),v=Math.min(2,p.length);return f=p.slice(0,v).join(""),f.length>0?f:"?"}const c=l.computed(()=>{const u=r.value[0],f=u==="?"?0:(u.charCodeAt(0)-64)%19;return Math.max(f,0)}),a=l.ref(!1);return l.onMounted(()=>{r.value=s()}),(u,f)=>(l.openBlock(),l.createElementBlock(l.Fragment,null,[l.createElementVNode("div",{id:"sf-header-avatar","data-cor":c.value,onClick:f[0]||(f[0]=p=>a.value=!0)},l.toDisplayString(r.value),9,nu),l.createVNode(Kr,{visible:a.value,"onUpdate:visible":f[1]||(f[1]=p=>a.value=p),position:"right"},{title:l.withCtx(()=>[l.createTextVNode("Minha conta")]),default:l.withCtx(()=>[l.createElementVNode("div",ru,[l.createVNode(zr,{color:"error",onClick:i},{default:l.withCtx(()=>[l.createTextVNode("Sair")]),_:1})])]),_:1},8,["visible"])],64))}}),iu={},su={xmlns:"http://www.w3.org/2000/svg",height:"48",viewBox:"0 -960 960 960",width:"48",class:"sf-svg-icon"},au=[l.createElementVNode("path",{d:"m307.231-83.463-54.999-55.23 343.923-343.922-343.923-343.539 54.999-54.614 398.153 398.153L307.231-83.462Z"},null,-1)];function lu(t,e){return l.openBlock(),l.createElementBlock("svg",su,au)}const cu=Vr(iu,[["render",lu]]);class uu{get storedTheme(){return localStorage.getItem("color-scheme")}get IsDark(){return document.documentElement.classList.contains("dark")}Toggle(){this.IsDark?this.EnableLightMode():this.EnableDarkMode()}EnableDarkMode(){document.documentElement.classList.add("dark"),document.documentElement.classList.remove("light"),localStorage.setItem("color-scheme","dark")}EnableLightMode(){document.documentElement.classList.remove("dark"),document.documentElement.classList.add("light"),localStorage.setItem("color-scheme","light")}SetInitialTheme(){if(this.storedTheme==="light")return this.EnableLightMode();if(this.storedTheme==="dark")return this.EnableDarkMode();if(window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches)return this.EnableDarkMode();this.EnableLightMode()}}const or=new uu,du=[l.createStaticVNode('<svg xmlns="http://www.w3.org/2000/svg" width="472.39" height="472.39" viewBox="0 0 472.39 472.39"><g class="toggle-sun"><path d="M403.21,167V69.18H305.38L236.2,0,167,69.18H69.18V167L0,236.2l69.18,69.18v97.83H167l69.18,69.18,69.18-69.18h97.83V305.38l69.18-69.18Zm-167,198.17a129,129,0,1,1,129-129A129,129,0,0,1,236.2,365.19Z"></path></g><g class="toggle-circle"><circle class="cls-1" cx="236.2" cy="236.2" r="103.78"></circle></g></svg>',1)],fu=l.defineComponent({__name:"ThemeToggle",setup(t){return(e,n)=>(l.openBlock(),l.createElementBlock("button",{id:"sf-theme-toggle",onClick:n[0]||(n[0]=(...r)=>l.unref(or).Toggle&&l.unref(or).Toggle(...r))},du))}}),pu={id:"sf-layout"},mu=l.createElementVNode("div",{class:"sf-layout-menu-toggler-logo"},null,-1),hu={class:"title"},gu={class:"sf-layout-nav-content"},yu=l.createElementVNode("div",{class:"sf-layout-nav-footer"},[l.createElementVNode("div",{class:"sf-layout-nav-footer-logo"})],-1),bu=l.createElementVNode("section",{id:"sf-layout-page-title"},null,-1),vu={id:"sf-layout-content"},wu=l.defineComponent({__name:"Layout",emits:["mounted","logout"],setup(t,{emit:e}){const n=Tn(),r=e;return l.onMounted(()=>{r("mounted")}),(o,i)=>(l.openBlock(),l.createElementBlock("div",pu,[l.createElementVNode("header",null,[l.createElementVNode("div",{class:l.normalizeClass(["sf-layout-menu-toggler",{invert:l.unref(n).IsVisible}]),onClick:i[0]||(i[0]=s=>l.unref(n).Toggle())},[mu,l.createVNode(cu)],2),l.createElementVNode("div",hu,[l.renderSlot(o.$slots,"title")]),l.renderSlot(o.$slots,"action"),l.createVNode(On,{text:"alternar tema"},{default:l.withCtx(()=>[l.createVNode(fu)]),_:1}),l.createVNode(ou,{onLogout:i[1]||(i[1]=s=>r("logout"))})]),l.createElementVNode("nav",{class:l.normalizeClass({visible:l.unref(n).IsVisible})},[l.createElementVNode("div",gu,[l.renderSlot(o.$slots,"menu")]),yu],2),l.createElementVNode("main",{class:l.normalizeClass({"menu-visible":l.unref(n).IsVisible})},[bu,l.createElementVNode("section",vu,[l.renderSlot(o.$slots,"content")])],2)]))}}),Eu=["href","data-active","onClick"],Su={class:"sf-navmenulink-text"},_u=l.defineComponent({__name:"NavMenuLink",props:{href:{},text:{},icon:{},iconFilled:{type:Boolean},exact:{type:Boolean}},setup(t){const e=t,n=Tn();function r(o,i){o.preventDefault();const c=o.target.closest(".sf-layout-nav-content");i(),c&&c.clientWidth+10>document.body.clientWidth&&n.Close()}return(o,i)=>{const s=l.resolveComponent("router-link");return l.openBlock(),l.createBlock(s,{to:e.href,custom:""},{default:l.withCtx(({href:c,navigate:a,isExactActive:u,isActive:f})=>[l.createElementVNode("a",{class:"sf-navmenulink",href:c,"data-active":e.exact?u:f,onClick:p=>r(p,a)},[e.icon?(l.openBlock(),l.createBlock(Qe,{key:0,icon:e.icon,filled:e.iconFilled,"button-props":{tabindex:-1}},null,8,["icon","filled"])):l.createCommentVNode("",!0),l.createElementVNode("span",Su,l.toDisplayString(e.text),1)],8,Eu)]),_:1},8,["to"])}}}),Cu=l.defineComponent({__name:"ScrollToTop",setup(t){const e=l.ref(!1),n=`--${+new Date}`;let r=null;function o(){r==null||r.scrollTo(0,0)}return l.onMounted(()=>{var i;r=((i=document.getElementById(n))==null?void 0:i.parentElement)??null,r&&r.addEventListener("scroll",function(){e.value=this.scrollTop-this.clientHeight>0})}),(i,s)=>(l.openBlock(),l.createElementBlock("button",{id:n,class:l.normalizeClass(["sf-scrollToTop",{"sf-scrollToTop-visible":e.value}]),onClick:o},null,2))}}),Au=l.defineComponent({__name:"Content",props:{class:{},style:{},disableBodyPadding:{type:Boolean},disableHeaderPadding:{type:Boolean},disableFooterPadding:{type:Boolean}},setup(t){const e=t;function n(){return new Ze("sf-content").AddClass(e.class,!!e.class).Build()}function r(){return new Ze("sf-content-body").AddClass("sf-content-no-padding",e.disableBodyPadding).Build()}function o(){return new Ze("sf-content-header").AddClass("sf-content-no-padding",e.disableHeaderPadding).Build()}function i(){return new Ze("sf-content-footer").AddClass("sf-content-no-padding",e.disableFooterPadding).Build()}return(s,c)=>(l.openBlock(),l.createElementBlock("div",{class:l.normalizeClass(n()),style:l.normalizeStyle(e.style)},[l.createElementVNode("div",{class:l.normalizeClass(o())},[l.renderSlot(s.$slots,"header")],2),l.createElementVNode("div",{class:l.normalizeClass(r())},[l.renderSlot(s.$slots,"default"),l.createVNode(Cu)],2),l.createElementVNode("div",{class:l.normalizeClass(i())},[l.renderSlot(s.$slots,"footer")],2)],6))}}),ku={class:"sf-tab-navigation"},xu=[l.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"w-6 h-6"},[l.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M15.75 19.5L8.25 12l7.5-7.5"})],-1)],Iu=["data-active"],Pu=["href","onClick"],Tu=[l.createElementVNode("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24","stroke-width":"1.5",stroke:"currentColor",class:"w-6 h-6"},[l.createElementVNode("path",{"stroke-linecap":"round","stroke-linejoin":"round",d:"M8.25 4.5l7.5 7.5-7.5 7.5"})],-1)],Ou=l.defineComponent({__name:"TabNavigation",props:{tabs:{}},setup(t){const e=t,n=l.ref(null),r=new ResizeObserver(a=>{c()}),o=l.ref(!1),i=l.ref(!1);function s(a=!1){const u=n.value.clientWidth;n.value.scrollLeft+=a?-u:u}function c(){const a=n.value.scrollWidth-n.value.clientWidth;o.value=n.value.scrollLeft>10,i.value=n.value.scrollLeft<a-10}return l.onMounted(()=>{n.value.addEventListener("scroll",c),r.observe(n.value)}),l.onBeforeUnmount(()=>{var a;try{(a=n.value)==null||a.removeEventListener("scroll",c),r.unobserve(n.value),r.disconnect()}catch{}}),(a,u)=>{const f=l.resolveComponent("RouterLink");return l.openBlock(),l.createElementBlock("div",ku,[l.createElementVNode("div",{class:l.normalizeClass(["left-arrow",{active:o.value}]),onClick:u[0]||(u[0]=p=>s(!0))},xu,2),l.createElementVNode("ul",{ref_key:"trackerContainer",ref:n},[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(e.tabs,p=>(l.openBlock(),l.createBlock(f,{to:p.route,custom:!0},{default:l.withCtx(({navigate:v,isActive:w})=>[l.createElementVNode("li",{"data-active":w},[l.renderSlot(a.$slots,"item",{item:p,navigate:v,isActive:w},()=>[l.createElementVNode("a",{href:p.route,class:l.normalizeClass({active:w}),onClick:v},l.toDisplayString(p.text),11,Pu)])],8,Iu)]),_:2},1032,["to"]))),256))],512),l.createElementVNode("div",{class:l.normalizeClass(["right-arrow",{active:i.value}]),onClick:u[1]||(u[1]=p=>s())},Tu,2)])}}}),Lu=["data-icon"],Bu=l.defineComponent({__name:"Message",props:{color:{default:"info"},class:{},style:{},icon:{}},setup(t){const e=t,n=l.computed(()=>{if(e.icon)return e.icon;switch(e.color){case"error":return"cancel";case"info":return"info";case"warn":return"warning";case"success":return"check";case"help":return"help";default:return null}}),r=l.computed(()=>new Ze("sf-message").AddClass("sf-message-error",e.color==="error").AddClass("sf-message-info",e.color==="info").AddClass("sf-message-warning",e.color==="warn").AddClass("sf-message-success",e.color==="success").AddClass("sf-message-help",e.color==="help").AddClass("sf-message-primary",e.color==="primary").AddClass("sf-message-secondary",e.color==="secondary").AddClass(e.class).Build());return(o,i)=>(l.openBlock(),l.createElementBlock("div",{class:l.normalizeClass(r.value),"data-icon":n.value},[l.renderSlot(o.$slots,"default")],10,Lu))}});/*!
66
+ * vue-router v4.3.0
67
+ * (c) 2024 Eduardo San Martin Morote
68
+ * @license MIT
69
+ */var Xo;(function(t){t.pop="pop",t.push="push"})(Xo||(Xo={}));var Zo;(function(t){t.back="back",t.forward="forward",t.unknown=""})(Zo||(Zo={})),Symbol(process.env.NODE_ENV!=="production"?"navigation failure":"");var Qo;(function(t){t[t.aborted=4]="aborted",t[t.cancelled=8]="cancelled",t[t.duplicated=16]="duplicated"})(Qo||(Qo={})),Symbol(process.env.NODE_ENV!=="production"?"router view location matched":""),Symbol(process.env.NODE_ENV!=="production"?"router view depth":""),Symbol(process.env.NODE_ENV!=="production"?"router":"");const Ru=Symbol(process.env.NODE_ENV!=="production"?"route location":"");Symbol(process.env.NODE_ENV!=="production"?"router view location":"");function Fu(){return l.inject(Ru)}function ir(t,e){var n=typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=ar(t))||e&&t&&typeof t.length=="number"){n&&(t=n);var r=0,o=function(){};return{s:o,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(u){throw u},f:o}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
70
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var i=!0,s=!1,c;return{s:function(){n=n.call(t)},n:function(){var u=n.next();return i=u.done,u},e:function(u){s=!0,c=u},f:function(){try{!i&&n.return!=null&&n.return()}finally{if(s)throw c}}}}function $u(t){return Mu(t)||Du(t)||ar(t)||Nu()}function Nu(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
71
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Du(t){if(typeof Symbol<"u"&&t[Symbol.iterator]!=null||t["@@iterator"]!=null)return Array.from(t)}function Mu(t){if(Array.isArray(t))return lr(t)}function Mt(t){"@babel/helpers - typeof";return Mt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Mt(t)}function sr(t,e){return ju(t)||Hu(t,e)||ar(t,e)||Uu()}function Uu(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
72
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function ar(t,e){if(t){if(typeof t=="string")return lr(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);if(n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set")return Array.from(t);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return lr(t,e)}}function lr(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function Hu(t,e){var n=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var r,o,i,s,c=[],a=!0,u=!1;try{if(i=(n=n.call(t)).next,e===0){if(Object(n)!==n)return;a=!1}else for(;!(a=(r=i.call(n)).done)&&(c.push(r.value),c.length!==e);a=!0);}catch(f){u=!0,o=f}finally{try{if(!a&&n.return!=null&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw o}}return c}}function ju(t){if(Array.isArray(t))return t}var Z={innerWidth:function(e){if(e){var n=e.offsetWidth,r=getComputedStyle(e);return n+=parseFloat(r.paddingLeft)+parseFloat(r.paddingRight),n}return 0},width:function(e){if(e){var n=e.offsetWidth,r=getComputedStyle(e);return n-=parseFloat(r.paddingLeft)+parseFloat(r.paddingRight),n}return 0},getWindowScrollTop:function(){var e=document.documentElement;return(window.pageYOffset||e.scrollTop)-(e.clientTop||0)},getWindowScrollLeft:function(){var e=document.documentElement;return(window.pageXOffset||e.scrollLeft)-(e.clientLeft||0)},getOuterWidth:function(e,n){if(e){var r=e.offsetWidth;if(n){var o=getComputedStyle(e);r+=parseFloat(o.marginLeft)+parseFloat(o.marginRight)}return r}return 0},getOuterHeight:function(e,n){if(e){var r=e.offsetHeight;if(n){var o=getComputedStyle(e);r+=parseFloat(o.marginTop)+parseFloat(o.marginBottom)}return r}return 0},getClientHeight:function(e,n){if(e){var r=e.clientHeight;if(n){var o=getComputedStyle(e);r+=parseFloat(o.marginTop)+parseFloat(o.marginBottom)}return r}return 0},getViewport:function(){var e=window,n=document,r=n.documentElement,o=n.getElementsByTagName("body")[0],i=e.innerWidth||r.clientWidth||o.clientWidth,s=e.innerHeight||r.clientHeight||o.clientHeight;return{width:i,height:s}},getOffset:function(e){if(e){var n=e.getBoundingClientRect();return{top:n.top+(window.pageYOffset||document.documentElement.scrollTop||document.body.scrollTop||0),left:n.left+(window.pageXOffset||document.documentElement.scrollLeft||document.body.scrollLeft||0)}}return{top:"auto",left:"auto"}},index:function(e){if(e)for(var n,r=(n=this.getParentNode(e))===null||n===void 0?void 0:n.childNodes,o=0,i=0;i<r.length;i++){if(r[i]===e)return o;r[i].nodeType===1&&o++}return-1},addMultipleClasses:function(e,n){var r=this;e&&n&&[n].flat().filter(Boolean).forEach(function(o){return o.split(" ").forEach(function(i){return r.addClass(e,i)})})},removeMultipleClasses:function(e,n){var r=this;e&&n&&[n].flat().filter(Boolean).forEach(function(o){return o.split(" ").forEach(function(i){return r.removeClass(e,i)})})},addClass:function(e,n){e&&n&&!this.hasClass(e,n)&&(e.classList?e.classList.add(n):e.className+=" "+n)},removeClass:function(e,n){e&&n&&(e.classList?e.classList.remove(n):e.className=e.className.replace(new RegExp("(^|\\b)"+n.split(" ").join("|")+"(\\b|$)","gi")," "))},hasClass:function(e,n){return e?e.classList?e.classList.contains(n):new RegExp("(^| )"+n+"( |$)","gi").test(e.className):!1},addStyles:function(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};e&&Object.entries(n).forEach(function(r){var o=sr(r,2),i=o[0],s=o[1];return e.style[i]=s})},find:function(e,n){return this.isElement(e)?e.querySelectorAll(n):[]},findSingle:function(e,n){return this.isElement(e)?e.querySelector(n):null},createElement:function(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(e){var r=document.createElement(e);this.setAttributes(r,n);for(var o=arguments.length,i=new Array(o>2?o-2:0),s=2;s<o;s++)i[s-2]=arguments[s];return r.append.apply(r,i),r}},setAttribute:function(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",r=arguments.length>2?arguments[2]:void 0;this.isElement(e)&&r!==null&&r!==void 0&&e.setAttribute(n,r)},setAttributes:function(e){var n=this,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(this.isElement(e)){var o=function i(s,c){var a,u,f=e!=null&&(a=e.$attrs)!==null&&a!==void 0&&a[s]?[e==null||(u=e.$attrs)===null||u===void 0?void 0:u[s]]:[];return[c].flat().reduce(function(p,v){if(v!=null){var w=Mt(v);if(w==="string"||w==="number")p.push(v);else if(w==="object"){var C=Array.isArray(v)?i(s,v):Object.entries(v).map(function(x){var _=sr(x,2),$=_[0],q=_[1];return s==="style"&&(q||q===0)?"".concat($.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),":").concat(q):q?$:void 0});p=C.length?p.concat(C.filter(function(x){return!!x})):p}}return p},f)};Object.entries(r).forEach(function(i){var s=sr(i,2),c=s[0],a=s[1];if(a!=null){var u=c.match(/^on(.+)/);u?e.addEventListener(u[1].toLowerCase(),a):c==="p-bind"?n.setAttributes(e,a):(a=c==="class"?$u(new Set(o("class",a))).join(" ").trim():c==="style"?o("style",a).join(";").trim():a,(e.$attrs=e.$attrs||{})&&(e.$attrs[c]=a),e.setAttribute(c,a))}})}},getAttribute:function(e,n){if(this.isElement(e)){var r=e.getAttribute(n);return isNaN(r)?r==="true"||r==="false"?r==="true":r:+r}},isAttributeEquals:function(e,n,r){return this.isElement(e)?this.getAttribute(e,n)===r:!1},isAttributeNotEquals:function(e,n,r){return!this.isAttributeEquals(e,n,r)},getHeight:function(e){if(e){var n=e.offsetHeight,r=getComputedStyle(e);return n-=parseFloat(r.paddingTop)+parseFloat(r.paddingBottom)+parseFloat(r.borderTopWidth)+parseFloat(r.borderBottomWidth),n}return 0},getWidth:function(e){if(e){var n=e.offsetWidth,r=getComputedStyle(e);return n-=parseFloat(r.paddingLeft)+parseFloat(r.paddingRight)+parseFloat(r.borderLeftWidth)+parseFloat(r.borderRightWidth),n}return 0},absolutePosition:function(e,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(e){var o=e.offsetParent?{width:e.offsetWidth,height:e.offsetHeight}:this.getHiddenElementDimensions(e),i=o.height,s=o.width,c=n.offsetHeight,a=n.offsetWidth,u=n.getBoundingClientRect(),f=this.getWindowScrollTop(),p=this.getWindowScrollLeft(),v=this.getViewport(),w,C,x="top";u.top+c+i>v.height?(w=u.top+f-i,x="bottom",w<0&&(w=f)):w=c+u.top+f,u.left+s>v.width?C=Math.max(0,u.left+p+a-s):C=u.left+p,e.style.top=w+"px",e.style.left=C+"px",e.style.transformOrigin=x,r&&(e.style.marginTop=x==="bottom"?"calc(var(--p-anchor-gutter) * -1)":"calc(var(--p-anchor-gutter))")}},relativePosition:function(e,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;if(e){var o=e.offsetParent?{width:e.offsetWidth,height:e.offsetHeight}:this.getHiddenElementDimensions(e),i=n.offsetHeight,s=n.getBoundingClientRect(),c=this.getViewport(),a,u,f="top";s.top+i+o.height>c.height?(a=-1*o.height,f="bottom",s.top+a<0&&(a=-1*s.top)):a=i,o.width>c.width?u=s.left*-1:s.left+o.width>c.width?u=(s.left+o.width-c.width)*-1:u=0,e.style.top=a+"px",e.style.left=u+"px",e.style.transformOrigin=f,r&&(e.style.marginTop=f==="bottom"?"calc(var(--p-anchor-gutter) * -1)":"calc(var(--p-anchor-gutter))")}},nestedPosition:function(e,n){if(e){var r=e.parentElement,o=this.getOffset(r),i=this.getViewport(),s=e.offsetParent?e.offsetWidth:this.getHiddenElementOuterWidth(e),c=this.getOuterWidth(r.children[0]),a;parseInt(o.left,10)+c+s>i.width-this.calculateScrollbarWidth()?parseInt(o.left,10)<s?n%2===1?a=parseInt(o.left,10)?"-"+parseInt(o.left,10)+"px":"100%":n%2===0&&(a=i.width-s-this.calculateScrollbarWidth()+"px"):a="-100%":a="100%",e.style.top="0px",e.style.left=a}},getParentNode:function(e){var n=e==null?void 0:e.parentNode;return n&&n instanceof ShadowRoot&&n.host&&(n=n.host),n},getParents:function(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[],r=this.getParentNode(e);return r===null?n:this.getParents(r,n.concat([r]))},getScrollableParents:function(e){var n=[];if(e){var r=this.getParents(e),o=/(auto|scroll)/,i=function(_){try{var $=window.getComputedStyle(_,null);return o.test($.getPropertyValue("overflow"))||o.test($.getPropertyValue("overflowX"))||o.test($.getPropertyValue("overflowY"))}catch{return!1}},s=ir(r),c;try{for(s.s();!(c=s.n()).done;){var a=c.value,u=a.nodeType===1&&a.dataset.scrollselectors;if(u){var f=u.split(","),p=ir(f),v;try{for(p.s();!(v=p.n()).done;){var w=v.value,C=this.findSingle(a,w);C&&i(C)&&n.push(C)}}catch(x){p.e(x)}finally{p.f()}}a.nodeType!==9&&i(a)&&n.push(a)}}catch(x){s.e(x)}finally{s.f()}}return n},getHiddenElementOuterHeight:function(e){if(e){e.style.visibility="hidden",e.style.display="block";var n=e.offsetHeight;return e.style.display="none",e.style.visibility="visible",n}return 0},getHiddenElementOuterWidth:function(e){if(e){e.style.visibility="hidden",e.style.display="block";var n=e.offsetWidth;return e.style.display="none",e.style.visibility="visible",n}return 0},getHiddenElementDimensions:function(e){if(e){var n={};return e.style.visibility="hidden",e.style.display="block",n.width=e.offsetWidth,n.height=e.offsetHeight,e.style.display="none",e.style.visibility="visible",n}return 0},fadeIn:function(e,n){if(e){e.style.opacity=0;var r=+new Date,o=0,i=function s(){o=+e.style.opacity+(new Date().getTime()-r)/n,e.style.opacity=o,r=+new Date,+o<1&&(window.requestAnimationFrame&&requestAnimationFrame(s)||setTimeout(s,16))};i()}},fadeOut:function(e,n){if(e)var r=1,o=50,i=n,s=o/i,c=setInterval(function(){r-=s,r<=0&&(r=0,clearInterval(c)),e.style.opacity=r},o)},getUserAgent:function(){return navigator.userAgent},appendChild:function(e,n){if(this.isElement(n))n.appendChild(e);else if(n.el&&n.elElement)n.elElement.appendChild(e);else throw new Error("Cannot append "+n+" to "+e)},isElement:function(e){return(typeof HTMLElement>"u"?"undefined":Mt(HTMLElement))==="object"?e instanceof HTMLElement:e&&Mt(e)==="object"&&e!==null&&e.nodeType===1&&typeof e.nodeName=="string"},scrollInView:function(e,n){var r=getComputedStyle(e).getPropertyValue("borderTopWidth"),o=r?parseFloat(r):0,i=getComputedStyle(e).getPropertyValue("paddingTop"),s=i?parseFloat(i):0,c=e.getBoundingClientRect(),a=n.getBoundingClientRect(),u=a.top+document.body.scrollTop-(c.top+document.body.scrollTop)-o-s,f=e.scrollTop,p=e.clientHeight,v=this.getOuterHeight(n);u<0?e.scrollTop=f+u:u+v>p&&(e.scrollTop=f+u-p+v)},clearSelection:function(){if(window.getSelection)window.getSelection().empty?window.getSelection().empty():window.getSelection().removeAllRanges&&window.getSelection().rangeCount>0&&window.getSelection().getRangeAt(0).getClientRects().length>0&&window.getSelection().removeAllRanges();else if(document.selection&&document.selection.empty)try{document.selection.empty()}catch{}},getSelection:function(){return window.getSelection?window.getSelection().toString():document.getSelection?document.getSelection().toString():document.selection?document.selection.createRange().text:null},calculateScrollbarWidth:function(){if(this.calculatedScrollbarWidth!=null)return this.calculatedScrollbarWidth;var e=document.createElement("div");this.addStyles(e,{width:"100px",height:"100px",overflow:"scroll",position:"absolute",top:"-9999px"}),document.body.appendChild(e);var n=e.offsetWidth-e.clientWidth;return document.body.removeChild(e),this.calculatedScrollbarWidth=n,n},calculateBodyScrollbarWidth:function(){return window.innerWidth-document.documentElement.offsetWidth},getBrowser:function(){if(!this.browser){var e=this.resolveUserAgent();this.browser={},e.browser&&(this.browser[e.browser]=!0,this.browser.version=e.version),this.browser.chrome?this.browser.webkit=!0:this.browser.webkit&&(this.browser.safari=!0)}return this.browser},resolveUserAgent:function(){var e=navigator.userAgent.toLowerCase(),n=/(chrome)[ ]([\w.]+)/.exec(e)||/(webkit)[ ]([\w.]+)/.exec(e)||/(opera)(?:.*version|)[ ]([\w.]+)/.exec(e)||/(msie) ([\w.]+)/.exec(e)||e.indexOf("compatible")<0&&/(mozilla)(?:.*? rv:([\w.]+)|)/.exec(e)||[];return{browser:n[1]||"",version:n[2]||"0"}},isVisible:function(e){return e&&e.offsetParent!=null},invokeElementMethod:function(e,n,r){e[n].apply(e,r)},isExist:function(e){return!!(e!==null&&typeof e<"u"&&e.nodeName&&this.getParentNode(e))},isClient:function(){return!!(typeof window<"u"&&window.document&&window.document.createElement)},focus:function(e,n){e&&document.activeElement!==e&&e.focus(n)},isFocusableElement:function(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";return this.isElement(e)?e.matches('button:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])'.concat(n,`,
73
+ [href][clientHeight][clientWidth]:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])`).concat(n,`,
74
+ input:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])`).concat(n,`,
75
+ select:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])`).concat(n,`,
76
+ textarea:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])`).concat(n,`,
77
+ [tabIndex]:not([tabIndex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])`).concat(n,`,
78
+ [contenteditable]:not([tabIndex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])`).concat(n)):!1},getFocusableElements:function(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",r=this.find(e,'button:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])'.concat(n,`,
79
+ [href][clientHeight][clientWidth]:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])`).concat(n,`,
80
+ input:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])`).concat(n,`,
81
+ select:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])`).concat(n,`,
82
+ textarea:not([tabindex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])`).concat(n,`,
83
+ [tabIndex]:not([tabIndex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])`).concat(n,`,
84
+ [contenteditable]:not([tabIndex = "-1"]):not([disabled]):not([style*="display:none"]):not([hidden])`).concat(n)),o=[],i=ir(r),s;try{for(i.s();!(s=i.n()).done;){var c=s.value;getComputedStyle(c).display!="none"&&getComputedStyle(c).visibility!="hidden"&&o.push(c)}}catch(a){i.e(a)}finally{i.f()}return o},getFirstFocusableElement:function(e,n){var r=this.getFocusableElements(e,n);return r.length>0?r[0]:null},getLastFocusableElement:function(e,n){var r=this.getFocusableElements(e,n);return r.length>0?r[r.length-1]:null},getNextFocusableElement:function(e,n,r){var o=this.getFocusableElements(e,r),i=o.length>0?o.findIndex(function(c){return c===n}):-1,s=i>-1&&o.length>=i+1?i+1:-1;return s>-1?o[s]:null},getPreviousElementSibling:function(e,n){for(var r=e.previousElementSibling;r;){if(r.matches(n))return r;r=r.previousElementSibling}return null},getNextElementSibling:function(e,n){for(var r=e.nextElementSibling;r;){if(r.matches(n))return r;r=r.nextElementSibling}return null},isClickable:function(e){if(e){var n=e.nodeName,r=e.parentElement&&e.parentElement.nodeName;return n==="INPUT"||n==="TEXTAREA"||n==="BUTTON"||n==="A"||r==="INPUT"||r==="TEXTAREA"||r==="BUTTON"||r==="A"||!!e.closest(".p-button, .p-checkbox, .p-radiobutton")}return!1},applyStyle:function(e,n){if(typeof n=="string")e.style.cssText=n;else for(var r in n)e.style[r]=n[r]},isIOS:function(){return/iPad|iPhone|iPod/.test(navigator.userAgent)&&!window.MSStream},isAndroid:function(){return/(android)/i.test(navigator.userAgent)},isTouchDevice:function(){return"ontouchstart"in window||navigator.maxTouchPoints>0||navigator.msMaxTouchPoints>0},hasCSSAnimation:function(e){if(e){var n=getComputedStyle(e),r=parseFloat(n.getPropertyValue("animation-duration")||"0");return r>0}return!1},hasCSSTransition:function(e){if(e){var n=getComputedStyle(e),r=parseFloat(n.getPropertyValue("transition-duration")||"0");return r>0}return!1},exportCSV:function(e,n){var r=new Blob([e],{type:"application/csv;charset=utf-8;"});if(window.navigator.msSaveOrOpenBlob)navigator.msSaveOrOpenBlob(r,n+".csv");else{var o=document.createElement("a");o.download!==void 0?(o.setAttribute("href",URL.createObjectURL(r)),o.setAttribute("download",n+".csv"),o.style.display="none",document.body.appendChild(o),o.click(),document.body.removeChild(o)):(e="data:text/csv;charset=utf-8,"+e,window.open(encodeURI(e)))}},blockBodyScroll:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"p-overflow-hidden";document.body.style.setProperty("--scrollbar-width",this.calculateBodyScrollbarWidth()+"px"),this.addClass(document.body,e)},unblockBodyScroll:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"p-overflow-hidden";document.body.style.removeProperty("--scrollbar-width"),this.removeClass(document.body,e)}};function ei(t,e){return zu(t)||Ku(t,e)||ur(t,e)||Vu()}function Vu(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
85
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Ku(t,e){var n=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var r,o,i,s,c=[],a=!0,u=!1;try{if(i=(n=n.call(t)).next,e===0){if(Object(n)!==n)return;a=!1}else for(;!(a=(r=i.call(n)).done)&&(c.push(r.value),c.length!==e);a=!0);}catch(f){u=!0,o=f}finally{try{if(!a&&n.return!=null&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw o}}return c}}function zu(t){if(Array.isArray(t))return t}function ti(t){return Gu(t)||qu(t)||ur(t)||Wu()}function Wu(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
86
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function qu(t){if(typeof Symbol<"u"&&t[Symbol.iterator]!=null||t["@@iterator"]!=null)return Array.from(t)}function Gu(t){if(Array.isArray(t))return dr(t)}function cr(t,e){var n=typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(!n){if(Array.isArray(t)||(n=ur(t))||e&&t&&typeof t.length=="number"){n&&(t=n);var r=0,o=function(){};return{s:o,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(u){throw u},f:o}}throw new TypeError(`Invalid attempt to iterate non-iterable instance.
87
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}var i=!0,s=!1,c;return{s:function(){n=n.call(t)},n:function(){var u=n.next();return i=u.done,u},e:function(u){s=!0,c=u},f:function(){try{!i&&n.return!=null&&n.return()}finally{if(s)throw c}}}}function ur(t,e){if(t){if(typeof t=="string")return dr(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);if(n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set")return Array.from(t);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return dr(t,e)}}function dr(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function Ut(t){"@babel/helpers - typeof";return Ut=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ut(t)}var D={equals:function(e,n,r){return r?this.resolveFieldData(e,r)===this.resolveFieldData(n,r):this.deepEquals(e,n)},deepEquals:function(e,n){if(e===n)return!0;if(e&&n&&Ut(e)=="object"&&Ut(n)=="object"){var r=Array.isArray(e),o=Array.isArray(n),i,s,c;if(r&&o){if(s=e.length,s!=n.length)return!1;for(i=s;i--!==0;)if(!this.deepEquals(e[i],n[i]))return!1;return!0}if(r!=o)return!1;var a=e instanceof Date,u=n instanceof Date;if(a!=u)return!1;if(a&&u)return e.getTime()==n.getTime();var f=e instanceof RegExp,p=n instanceof RegExp;if(f!=p)return!1;if(f&&p)return e.toString()==n.toString();var v=Object.keys(e);if(s=v.length,s!==Object.keys(n).length)return!1;for(i=s;i--!==0;)if(!Object.prototype.hasOwnProperty.call(n,v[i]))return!1;for(i=s;i--!==0;)if(c=v[i],!this.deepEquals(e[c],n[c]))return!1;return!0}return e!==e&&n!==n},resolveFieldData:function(e,n){if(!e||!n)return null;try{var r=e[n];if(this.isNotEmpty(r))return r}catch{}if(Object.keys(e).length){if(this.isFunction(n))return n(e);if(n.indexOf(".")===-1)return e[n];for(var o=n.split("."),i=e,s=0,c=o.length;s<c;++s){if(i==null)return null;i=i[o[s]]}return i}return null},getItemValue:function(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return this.isFunction(e)?e.apply(void 0,r):e},filter:function(e,n,r){var o=[];if(e){var i=cr(e),s;try{for(i.s();!(s=i.n()).done;){var c=s.value,a=cr(n),u;try{for(a.s();!(u=a.n()).done;){var f=u.value;if(String(this.resolveFieldData(c,f)).toLowerCase().indexOf(r.toLowerCase())>-1){o.push(c);break}}}catch(p){a.e(p)}finally{a.f()}}}catch(p){i.e(p)}finally{i.f()}}return o},reorderArray:function(e,n,r){e&&n!==r&&(r>=e.length&&(r%=e.length,n%=e.length),e.splice(r,0,e.splice(n,1)[0]))},findIndexInList:function(e,n){var r=-1;if(n){for(var o=0;o<n.length;o++)if(n[o]===e){r=o;break}}return r},contains:function(e,n){if(e!=null&&n&&n.length){var r=cr(n),o;try{for(r.s();!(o=r.n()).done;){var i=o.value;if(this.equals(e,i))return!0}}catch(s){r.e(s)}finally{r.f()}}return!1},insertIntoOrderedArray:function(e,n,r,o){if(r.length>0){for(var i=!1,s=0;s<r.length;s++){var c=this.findIndexInList(r[s],o);if(c>n){r.splice(s,0,e),i=!0;break}}i||r.push(e)}else r.push(e)},removeAccents:function(e){return e&&e.search(/[\xC0-\xFF]/g)>-1&&(e=e.replace(/[\xC0-\xC5]/g,"A").replace(/[\xC6]/g,"AE").replace(/[\xC7]/g,"C").replace(/[\xC8-\xCB]/g,"E").replace(/[\xCC-\xCF]/g,"I").replace(/[\xD0]/g,"D").replace(/[\xD1]/g,"N").replace(/[\xD2-\xD6\xD8]/g,"O").replace(/[\xD9-\xDC]/g,"U").replace(/[\xDD]/g,"Y").replace(/[\xDE]/g,"P").replace(/[\xE0-\xE5]/g,"a").replace(/[\xE6]/g,"ae").replace(/[\xE7]/g,"c").replace(/[\xE8-\xEB]/g,"e").replace(/[\xEC-\xEF]/g,"i").replace(/[\xF1]/g,"n").replace(/[\xF2-\xF6\xF8]/g,"o").replace(/[\xF9-\xFC]/g,"u").replace(/[\xFE]/g,"p").replace(/[\xFD\xFF]/g,"y")),e},getVNodeProp:function(e,n){if(e){var r=e.props;if(r){var o=n.replace(/([a-z])([A-Z])/g,"$1-$2").toLowerCase(),i=Object.prototype.hasOwnProperty.call(r,o)?o:n;return e.type.extends.props[n].type===Boolean&&r[i]===""?!0:r[i]}}return null},toFlatCase:function(e){return this.isString(e)?e.replace(/(-|_)/g,"").toLowerCase():e},toKebabCase:function(e){return this.isString(e)?e.replace(/(_)/g,"-").replace(/[A-Z]/g,function(n,r){return r===0?n:"-"+n.toLowerCase()}).toLowerCase():e},toCapitalCase:function(e){return this.isString(e,{empty:!1})?e[0].toUpperCase()+e.slice(1):e},isEmpty:function(e){return e==null||e===""||Array.isArray(e)&&e.length===0||!(e instanceof Date)&&Ut(e)==="object"&&Object.keys(e).length===0},isNotEmpty:function(e){return!this.isEmpty(e)},isFunction:function(e){return!!(e&&e.constructor&&e.call&&e.apply)},isObject:function(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;return e instanceof Object&&e.constructor===Object&&(n||Object.keys(e).length!==0)},isDate:function(e){return e instanceof Date&&e.constructor===Date},isArray:function(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;return Array.isArray(e)&&(n||e.length!==0)},isString:function(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;return typeof e=="string"&&(n||e!=="")},isPrintableCharacter:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";return this.isNotEmpty(e)&&e.length===1&&e.match(/\S| /)},findLast:function(e,n){var r;if(this.isNotEmpty(e))try{r=e.findLast(n)}catch{r=ti(e).reverse().find(n)}return r},findLastIndex:function(e,n){var r=-1;if(this.isNotEmpty(e))try{r=e.findLastIndex(n)}catch{r=e.lastIndexOf(ti(e).reverse().find(n))}return r},sort:function(e,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1,o=arguments.length>3?arguments[3]:void 0,i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:1,s=this.compare(e,n,o,r),c=r;return(this.isEmpty(e)||this.isEmpty(n))&&(c=i===1?r:i),c*s},compare:function(e,n,r){var o=arguments.length>3&&arguments[3]!==void 0?arguments[3]:1,i=-1,s=this.isEmpty(e),c=this.isEmpty(n);return s&&c?i=0:s?i=o:c?i=-o:typeof e=="string"&&typeof n=="string"?i=r(e,n):i=e<n?-1:e>n?1:0,i},localeComparator:function(){return new Intl.Collator(void 0,{numeric:!0}).compare},nestedKeys:function(){var e=this,n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"";return Object.entries(n).reduce(function(o,i){var s=ei(i,2),c=s[0],a=s[1],u=r?"".concat(r,".").concat(c):c;return e.isObject(a)?o=o.concat(e.nestedKeys(a,u)):o.push(u),o},[])},stringify:function(e){var n=this,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:2,o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0,i=" ".repeat(o),s=" ".repeat(o+r);return this.isArray(e)?"["+e.map(function(c){return n.stringify(c,r,o+r)}).join(", ")+"]":this.isDate(e)?e.toISOString():this.isFunction(e)?e.toString():this.isObject(e)?`{
88
+ `+Object.entries(e).map(function(c){var a=ei(c,2),u=a[0],f=a[1];return"".concat(s).concat(u,": ").concat(n.stringify(f,r,o+r))}).join(`,
89
+ `)+`
90
+ `.concat(i)+"}":JSON.stringify(e)}},ni=0;function ri(){var t=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"pv_id_";return ni++,"".concat(t).concat(ni)}function Ht(t){"@babel/helpers - typeof";return Ht=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Ht(t)}function oi(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,r)}return n}function ii(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?oi(Object(n),!0).forEach(function(r){Ju(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):oi(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Ju(t,e,n){return e=Yu(e),e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Yu(t){var e=Xu(t,"string");return Ht(e)=="symbol"?e:String(e)}function Xu(t,e){if(Ht(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e||"default");if(Ht(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}function Zu(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0;l.getCurrentInstance()?l.onMounted(t):e?t():l.nextTick(t)}var Qu=0;function si(t){var e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=l.ref(!1),r=l.ref(t),o=l.ref(null),i=Z.isClient()?window.document:void 0,s=e.document,c=s===void 0?i:s,a=e.immediate,u=a===void 0?!0:a,f=e.manual,p=f===void 0?!1:f,v=e.name,w=v===void 0?"style_".concat(++Qu):v,C=e.id,x=C===void 0?void 0:C,_=e.media,$=_===void 0?void 0:_,q=e.nonce,V=q===void 0?void 0:q,pe=e.props,de=pe===void 0?{}:pe,y=function(){},L=function(B){var O=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(c){var W=ii(ii({},de),O),A=W.name||w,G=W.id||x,ie=W.nonce||V;o.value=c.querySelector('style[data-primevue-style-id="'.concat(A,'"]'))||c.getElementById(G)||c.createElement("style"),o.value.isConnected||(r.value=B||t,Z.setAttributes(o.value,{type:"text/css",id:G,media:$,nonce:ie}),c.head.appendChild(o.value),Z.setAttribute(o.value,"data-primevue-style-id",w),Z.setAttributes(o.value,W)),!n.value&&(y=l.watch(r,function(ce){o.value.textContent=ce},{immediate:!0}),n.value=!0)}},j=function(){!c||!n.value||(y(),Z.isExist(o.value)&&c.head.removeChild(o.value),n.value=!1)};return u&&!p&&Zu(L),{id:x,name:w,css:r,unload:j,load:L,isLoaded:l.readonly(n)}}function jt(t){"@babel/helpers - typeof";return jt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},jt(t)}function ed(t,e){return od(t)||rd(t,e)||nd(t,e)||td()}function td(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
91
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function nd(t,e){if(t){if(typeof t=="string")return ai(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);if(n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set")return Array.from(t);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return ai(t,e)}}function ai(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function rd(t,e){var n=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var r,o,i,s,c=[],a=!0,u=!1;try{if(i=(n=n.call(t)).next,e===0){if(Object(n)!==n)return;a=!1}else for(;!(a=(r=i.call(n)).done)&&(c.push(r.value),c.length!==e);a=!0);}catch(f){u=!0,o=f}finally{try{if(!a&&n.return!=null&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw o}}return c}}function od(t){if(Array.isArray(t))return t}function li(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,r)}return n}function fr(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?li(Object(n),!0).forEach(function(r){id(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):li(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function id(t,e,n){return e=sd(e),e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function sd(t){var e=ad(t,"string");return jt(e)=="symbol"?e:String(e)}function ad(t,e){if(jt(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e||"default");if(jt(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var ld=`
92
+ .p-hidden-accessible {
93
+ border: 0;
94
+ clip: rect(0 0 0 0);
95
+ height: 1px;
96
+ margin: -1px;
97
+ overflow: hidden;
98
+ padding: 0;
99
+ position: absolute;
100
+ width: 1px;
101
+ }
102
+
103
+ .p-hidden-accessible input,
104
+ .p-hidden-accessible select {
105
+ transform: scale(0);
106
+ }
107
+
108
+ .p-overflow-hidden {
109
+ overflow: hidden;
110
+ padding-right: var(--scrollbar-width);
111
+ }
112
+ `,cd={},ud={},ct={name:"base",css:ld,classes:cd,inlineStyles:ud,loadStyle:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};return this.css?si(this.css,fr({name:this.name},e)):{}},getStyleSheet:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};if(this.css){var r=Object.entries(n).reduce(function(o,i){var s=ed(i,2),c=s[0],a=s[1];return o.push("".concat(c,'="').concat(a,'"'))&&o},[]).join(" ");return'<style type="text/css" data-primevue-style-id="'.concat(this.name,'" ').concat(r,">").concat(this.css).concat(e,"</style>")}return""},extend:function(e){return fr(fr({},this),{},{css:void 0},e)}};function Vt(t){"@babel/helpers - typeof";return Vt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Vt(t)}function ci(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,r)}return n}function dd(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?ci(Object(n),!0).forEach(function(r){fd(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):ci(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function fd(t,e,n){return e=pd(e),e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function pd(t){var e=md(t,"string");return Vt(e)=="symbol"?e:String(e)}function md(t,e){if(Vt(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e||"default");if(Vt(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var pr=ct.extend({name:"common",loadGlobalStyle:function(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return si(e,dd({name:"global"},n))}});function Kt(t){"@babel/helpers - typeof";return Kt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Kt(t)}function hd(t){return pi(t)||gd(t)||di(t)||ui()}function gd(t){if(typeof Symbol<"u"&&t[Symbol.iterator]!=null||t["@@iterator"]!=null)return Array.from(t)}function hn(t,e){return pi(t)||yd(t,e)||di(t,e)||ui()}function ui(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
113
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function di(t,e){if(t){if(typeof t=="string")return fi(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);if(n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set")return Array.from(t);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return fi(t,e)}}function fi(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function yd(t,e){var n=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var r,o,i,s,c=[],a=!0,u=!1;try{if(i=(n=n.call(t)).next,e===0){if(Object(n)!==n)return;a=!1}else for(;!(a=(r=i.call(n)).done)&&(c.push(r.value),c.length!==e);a=!0);}catch(f){u=!0,o=f}finally{try{if(!a&&n.return!=null&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw o}}return c}}function pi(t){if(Array.isArray(t))return t}function mi(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,r)}return n}function ae(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?mi(Object(n),!0).forEach(function(r){gn(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):mi(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function gn(t,e,n){return e=bd(e),e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function bd(t){var e=vd(t,"string");return Kt(e)=="symbol"?e:String(e)}function vd(t,e){if(Kt(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e||"default");if(Kt(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var yn={name:"BaseComponent",props:{pt:{type:Object,default:void 0},ptOptions:{type:Object,default:void 0},unstyled:{type:Boolean,default:void 0}},inject:{$parentInstance:{default:void 0}},watch:{isUnstyled:{immediate:!0,handler:function(e){if(!e){var n,r;pr.loadStyle({nonce:(n=this.$config)===null||n===void 0||(n=n.csp)===null||n===void 0?void 0:n.nonce}),this.$options.style&&this.$style.loadStyle({nonce:(r=this.$config)===null||r===void 0||(r=r.csp)===null||r===void 0?void 0:r.nonce})}}}},beforeCreate:function(){var e,n,r,o,i,s,c,a,u,f,p,v=(e=this.pt)===null||e===void 0?void 0:e._usept,w=v?(n=this.pt)===null||n===void 0||(n=n.originalValue)===null||n===void 0?void 0:n[this.$.type.name]:void 0,C=v?(r=this.pt)===null||r===void 0||(r=r.value)===null||r===void 0?void 0:r[this.$.type.name]:this.pt;(o=C||w)===null||o===void 0||(o=o.hooks)===null||o===void 0||(i=o.onBeforeCreate)===null||i===void 0||i.call(o);var x=(s=this.$config)===null||s===void 0||(s=s.pt)===null||s===void 0?void 0:s._usept,_=x?(c=this.$primevue)===null||c===void 0||(c=c.config)===null||c===void 0||(c=c.pt)===null||c===void 0?void 0:c.originalValue:void 0,$=x?(a=this.$primevue)===null||a===void 0||(a=a.config)===null||a===void 0||(a=a.pt)===null||a===void 0?void 0:a.value:(u=this.$primevue)===null||u===void 0||(u=u.config)===null||u===void 0?void 0:u.pt;(f=$||_)===null||f===void 0||(f=f[this.$.type.name])===null||f===void 0||(f=f.hooks)===null||f===void 0||(p=f.onBeforeCreate)===null||p===void 0||p.call(f)},created:function(){this._hook("onCreated")},beforeMount:function(){var e;ct.loadStyle({nonce:(e=this.$config)===null||e===void 0||(e=e.csp)===null||e===void 0?void 0:e.nonce}),this._loadGlobalStyles(),this._hook("onBeforeMount")},mounted:function(){this._hook("onMounted")},beforeUpdate:function(){this._hook("onBeforeUpdate")},updated:function(){this._hook("onUpdated")},beforeUnmount:function(){this._hook("onBeforeUnmount")},unmounted:function(){this._hook("onUnmounted")},methods:{_hook:function(e){if(!this.$options.hostName){var n=this._usePT(this._getPT(this.pt,this.$.type.name),this._getOptionValue,"hooks.".concat(e)),r=this._useDefaultPT(this._getOptionValue,"hooks.".concat(e));n==null||n(),r==null||r()}},_mergeProps:function(e){for(var n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return D.isFunction(e)?e.apply(void 0,r):l.mergeProps.apply(void 0,r)},_loadGlobalStyles:function(){var e,n=this._useGlobalPT(this._getOptionValue,"global.css",this.$params);D.isNotEmpty(n)&&pr.loadGlobalStyle(n,{nonce:(e=this.$config)===null||e===void 0||(e=e.csp)===null||e===void 0?void 0:e.nonce})},_getHostInstance:function(e){return e?this.$options.hostName?e.$.type.name===this.$options.hostName?e:this._getHostInstance(e.$parentInstance):e.$parentInstance:void 0},_getPropValue:function(e){var n;return this[e]||((n=this._getHostInstance(this))===null||n===void 0?void 0:n[e])},_getOptionValue:function(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=D.toFlatCase(n).split("."),i=o.shift();return i?D.isObject(e)?this._getOptionValue(D.getItemValue(e[Object.keys(e).find(function(s){return D.toFlatCase(s)===i})||""],r),o.join("."),r):void 0:D.getItemValue(e,r)},_getPTValue:function(){var e,n=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:!0,s=/./g.test(r)&&!!o[r.split(".")[0]],c=this._getPropValue("ptOptions")||((e=this.$config)===null||e===void 0?void 0:e.ptOptions)||{},a=c.mergeSections,u=a===void 0?!0:a,f=c.mergeProps,p=f===void 0?!1:f,v=i?s?this._useGlobalPT(this._getPTClassValue,r,o):this._useDefaultPT(this._getPTClassValue,r,o):void 0,w=s?void 0:this._getPTSelf(n,this._getPTClassValue,r,ae(ae({},o),{},{global:v||{}})),C=this._getPTDatasets(r);return u||!u&&w?p?this._mergeProps(p,v,w,C):ae(ae(ae({},v),w),C):ae(ae({},w),C)},_getPTSelf:function(){for(var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=arguments.length,r=new Array(n>1?n-1:0),o=1;o<n;o++)r[o-1]=arguments[o];return l.mergeProps(this._usePT.apply(this,[this._getPT(e,this.$name)].concat(r)),this._usePT.apply(this,[this.$_attrsPT].concat(r)))},_getPTDatasets:function(){var e,n,r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",o="data-pc-",i=r==="root"&&D.isNotEmpty((e=this.pt)===null||e===void 0?void 0:e["data-pc-section"]);return r!=="transition"&&ae(ae({},r==="root"&&ae(gn({},"".concat(o,"name"),D.toFlatCase(i?(n=this.pt)===null||n===void 0?void 0:n["data-pc-section"]:this.$.type.name)),i&&gn({},"".concat(o,"extend"),D.toFlatCase(this.$.type.name)))),{},gn({},"".concat(o,"section"),D.toFlatCase(r)))},_getPTClassValue:function(){var e=this._getOptionValue.apply(this,arguments);return D.isString(e)||D.isArray(e)?{class:e}:e},_getPT:function(e){var n=this,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",o=arguments.length>2?arguments[2]:void 0,i=function(c){var a,u=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,f=o?o(c):c,p=D.toFlatCase(r),v=D.toFlatCase(n.$name);return(a=u?p!==v?f==null?void 0:f[p]:void 0:f==null?void 0:f[p])!==null&&a!==void 0?a:f};return e!=null&&e.hasOwnProperty("_usept")?{_usept:e._usept,originalValue:i(e.originalValue),value:i(e.value)}:i(e,!0)},_usePT:function(e,n,r,o){var i=function(x){return n(x,r,o)};if(e!=null&&e.hasOwnProperty("_usept")){var s,c=e._usept||((s=this.$config)===null||s===void 0?void 0:s.ptOptions)||{},a=c.mergeSections,u=a===void 0?!0:a,f=c.mergeProps,p=f===void 0?!1:f,v=i(e.originalValue),w=i(e.value);return v===void 0&&w===void 0?void 0:D.isString(w)?w:D.isString(v)?v:u||!u&&w?p?this._mergeProps(p,v,w):ae(ae({},v),w):w}return i(e)},_useGlobalPT:function(e,n,r){return this._usePT(this.globalPT,e,n,r)},_useDefaultPT:function(e,n,r){return this._usePT(this.defaultPT,e,n,r)},ptm:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return this._getPTValue(this.pt,e,ae(ae({},this.$params),n))},ptmi:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return l.mergeProps(this.$_attrsNoPT,this.ptm(e,n))},ptmo:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return this._getPTValue(e,n,ae({instance:this},r),!1)},cx:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return this.isUnstyled?void 0:this._getOptionValue(this.$style.classes,e,ae(ae({},this.$params),n))},sx:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(n){var o=this._getOptionValue(this.$style.inlineStyles,e,ae(ae({},this.$params),r)),i=this._getOptionValue(pr.inlineStyles,e,ae(ae({},this.$params),r));return[i,o]}}},computed:{globalPT:function(){var e,n=this;return this._getPT((e=this.$config)===null||e===void 0?void 0:e.pt,void 0,function(r){return D.getItemValue(r,{instance:n})})},defaultPT:function(){var e,n=this;return this._getPT((e=this.$config)===null||e===void 0?void 0:e.pt,void 0,function(r){return n._getOptionValue(r,n.$name,ae({},n.$params))||D.getItemValue(r,ae({},n.$params))})},isUnstyled:function(){var e;return this.unstyled!==void 0?this.unstyled:(e=this.$config)===null||e===void 0?void 0:e.unstyled},$params:function(){var e=this._getHostInstance(this)||this.$parent;return{instance:this,props:this.$props,state:this.$data,attrs:this.$attrs,parent:{instance:e,props:e==null?void 0:e.$props,state:e==null?void 0:e.$data,attrs:e==null?void 0:e.$attrs},parentInstance:e}},$style:function(){return ae(ae({classes:void 0,inlineStyles:void 0,loadStyle:function(){},loadCustomStyle:function(){}},(this._getHostInstance(this)||{}).$style),this.$options.style)},$config:function(){var e;return(e=this.$primevue)===null||e===void 0?void 0:e.config},$name:function(){return this.$options.hostName||this.$.type.name},$_attrsPT:function(){return Object.entries(this.$attrs||{}).filter(function(e){var n=hn(e,1),r=n[0];return r==null?void 0:r.startsWith("pt:")}).reduce(function(e,n){var r=hn(n,2),o=r[0],i=r[1],s=o.split(":"),c=hd(s),a=c.slice(1);return a==null||a.reduce(function(u,f,p,v){return!u[f]&&(u[f]=p===v.length-1?i:{}),u[f]},e),e},{})},$_attrsNoPT:function(){return Object.entries(this.$attrs||{}).filter(function(e){var n=hn(e,1),r=n[0];return!(r!=null&&r.startsWith("pt:"))}).reduce(function(e,n){var r=hn(n,2),o=r[0],i=r[1];return e[o]=i,e},{})}}},wd=`
114
+ .p-icon {
115
+ display: inline-block;
116
+ }
117
+
118
+ .p-icon-spin {
119
+ -webkit-animation: p-icon-spin 2s infinite linear;
120
+ animation: p-icon-spin 2s infinite linear;
121
+ }
122
+
123
+ @-webkit-keyframes p-icon-spin {
124
+ 0% {
125
+ -webkit-transform: rotate(0deg);
126
+ transform: rotate(0deg);
127
+ }
128
+ 100% {
129
+ -webkit-transform: rotate(359deg);
130
+ transform: rotate(359deg);
131
+ }
132
+ }
133
+
134
+ @keyframes p-icon-spin {
135
+ 0% {
136
+ -webkit-transform: rotate(0deg);
137
+ transform: rotate(0deg);
138
+ }
139
+ 100% {
140
+ -webkit-transform: rotate(359deg);
141
+ transform: rotate(359deg);
142
+ }
143
+ }
144
+ `,Ed=ct.extend({name:"baseicon",css:wd});function zt(t){"@babel/helpers - typeof";return zt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},zt(t)}function hi(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,r)}return n}function gi(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?hi(Object(n),!0).forEach(function(r){Sd(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):hi(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function Sd(t,e,n){return e=_d(e),e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function _d(t){var e=Cd(t,"string");return zt(e)=="symbol"?e:String(e)}function Cd(t,e){if(zt(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e||"default");if(zt(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var yi={name:"BaseIcon",extends:yn,props:{label:{type:String,default:void 0},spin:{type:Boolean,default:!1}},style:Ed,methods:{pti:function(){var e=D.isEmpty(this.label);return gi(gi({},!this.isUnstyled&&{class:["p-icon",{"p-icon-spin":this.spin}]}),{},{role:e?void 0:"img","aria-label":e?void 0:this.label,"aria-hidden":e})}}},mr={name:"ChevronDownIcon",extends:yi},Ad=l.createElementVNode("path",{d:"M7.01744 10.398C6.91269 10.3985 6.8089 10.378 6.71215 10.3379C6.61541 10.2977 6.52766 10.2386 6.45405 10.1641L1.13907 4.84913C1.03306 4.69404 0.985221 4.5065 1.00399 4.31958C1.02276 4.13266 1.10693 3.95838 1.24166 3.82747C1.37639 3.69655 1.55301 3.61742 1.74039 3.60402C1.92777 3.59062 2.11386 3.64382 2.26584 3.75424L7.01744 8.47394L11.769 3.75424C11.9189 3.65709 12.097 3.61306 12.2748 3.62921C12.4527 3.64535 12.6199 3.72073 12.7498 3.84328C12.8797 3.96582 12.9647 4.12842 12.9912 4.30502C13.0177 4.48162 12.9841 4.662 12.8958 4.81724L7.58083 10.1322C7.50996 10.2125 7.42344 10.2775 7.32656 10.3232C7.22968 10.3689 7.12449 10.3944 7.01744 10.398Z",fill:"currentColor"},null,-1),kd=[Ad];function xd(t,e,n,r,o,i){return l.openBlock(),l.createElementBlock("svg",l.mergeProps({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t.pti()),kd,16)}mr.render=xd;var hr={name:"ChevronRightIcon",extends:yi},Id=l.createElementVNode("path",{d:"M4.38708 13C4.28408 13.0005 4.18203 12.9804 4.08691 12.9409C3.99178 12.9014 3.9055 12.8433 3.83313 12.7701C3.68634 12.6231 3.60388 12.4238 3.60388 12.2161C3.60388 12.0084 3.68634 11.8091 3.83313 11.6622L8.50507 6.99022L3.83313 2.31827C3.69467 2.16968 3.61928 1.97313 3.62287 1.77005C3.62645 1.56698 3.70872 1.37322 3.85234 1.22959C3.99596 1.08597 4.18972 1.00371 4.3928 1.00012C4.59588 0.996539 4.79242 1.07192 4.94102 1.21039L10.1669 6.43628C10.3137 6.58325 10.3962 6.78249 10.3962 6.99022C10.3962 7.19795 10.3137 7.39718 10.1669 7.54416L4.94102 12.7701C4.86865 12.8433 4.78237 12.9014 4.68724 12.9409C4.59212 12.9804 4.49007 13.0005 4.38708 13Z",fill:"currentColor"},null,-1),Pd=[Id];function Td(t,e,n,r,o,i){return l.openBlock(),l.createElementBlock("svg",l.mergeProps({width:"14",height:"14",viewBox:"0 0 14 14",fill:"none",xmlns:"http://www.w3.org/2000/svg"},t.pti()),Pd,16)}hr.render=Td;var Od={root:"p-panelmenu p-component",panel:"p-panelmenu-panel",header:function(e){var n=e.instance,r=e.item;return["p-panelmenu-header",{"p-highlight":n.isItemActive(r)&&!!r.items,"p-disabled":n.isItemDisabled(r)}]},headerContent:"p-panelmenu-header-content",headerAction:"p-panelmenu-header-action",headerIcon:"p-menuitem-icon",headerLabel:"p-menuitem-text",toggleableContent:"p-toggleable-content",menuContent:"p-panelmenu-content",menu:"p-panelmenu-root-list",menuitem:function(e){var n=e.instance,r=e.processedItem;return["p-menuitem",{"p-focus":n.isItemFocused(r),"p-disabled":n.isItemDisabled(r)}]},content:"p-menuitem-content",action:"p-menuitem-link",icon:"p-menuitem-icon",label:"p-menuitem-text",submenuIcon:"p-submenu-icon",submenu:"p-submenu-list",separator:"p-menuitem-separator"},Ld=ct.extend({name:"panelmenu",classes:Od});function Wt(t){"@babel/helpers - typeof";return Wt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},Wt(t)}function bi(t,e){return $d(t)||Fd(t,e)||Rd(t,e)||Bd()}function Bd(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
145
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Rd(t,e){if(t){if(typeof t=="string")return vi(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);if(n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set")return Array.from(t);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return vi(t,e)}}function vi(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function Fd(t,e){var n=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var r,o,i,s,c=[],a=!0,u=!1;try{if(i=(n=n.call(t)).next,e===0){if(Object(n)!==n)return;a=!1}else for(;!(a=(r=i.call(n)).done)&&(c.push(r.value),c.length!==e);a=!0);}catch(f){u=!0,o=f}finally{try{if(!a&&n.return!=null&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw o}}return c}}function $d(t){if(Array.isArray(t))return t}function wi(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,r)}return n}function le(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?wi(Object(n),!0).forEach(function(r){gr(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):wi(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function gr(t,e,n){return e=Nd(e),e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function Nd(t){var e=Dd(t,"string");return Wt(e)=="symbol"?e:String(e)}function Dd(t,e){if(Wt(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e||"default");if(Wt(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var re={_getMeta:function(){return[D.isObject(arguments.length<=0?void 0:arguments[0])||arguments.length<=0?void 0:arguments[0],D.getItemValue(D.isObject(arguments.length<=0?void 0:arguments[0])?arguments.length<=0?void 0:arguments[0]:arguments.length<=1?void 0:arguments[1])]},_getConfig:function(e,n){var r,o,i;return(r=(e==null||(o=e.instance)===null||o===void 0?void 0:o.$primevue)||(n==null||(i=n.ctx)===null||i===void 0||(i=i.appContext)===null||i===void 0||(i=i.config)===null||i===void 0||(i=i.globalProperties)===null||i===void 0?void 0:i.$primevue))===null||r===void 0?void 0:r.config},_getOptionValue:function(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=D.toFlatCase(n).split("."),i=o.shift();return i?D.isObject(e)?re._getOptionValue(D.getItemValue(e[Object.keys(e).find(function(s){return D.toFlatCase(s)===i})||""],r),o.join("."),r):void 0:D.getItemValue(e,r)},_getPTValue:function(){var e,n,r=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},o=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},i=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"",s=arguments.length>3&&arguments[3]!==void 0?arguments[3]:{},c=arguments.length>4&&arguments[4]!==void 0?arguments[4]:!0,a=function(){var q=re._getOptionValue.apply(re,arguments);return D.isString(q)||D.isArray(q)?{class:q}:q},u=((e=r.binding)===null||e===void 0||(e=e.value)===null||e===void 0?void 0:e.ptOptions)||((n=r.$config)===null||n===void 0?void 0:n.ptOptions)||{},f=u.mergeSections,p=f===void 0?!0:f,v=u.mergeProps,w=v===void 0?!1:v,C=c?re._useDefaultPT(r,r.defaultPT(),a,i,s):void 0,x=re._usePT(r,re._getPT(o,r.$name),a,i,le(le({},s),{},{global:C||{}})),_=re._getPTDatasets(r,i);return p||!p&&x?w?re._mergeProps(r,w,C,x,_):le(le(le({},C),x),_):le(le({},x),_)},_getPTDatasets:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",r="data-pc-";return le(le({},n==="root"&&gr({},"".concat(r,"name"),D.toFlatCase(e.$name))),{},gr({},"".concat(r,"section"),D.toFlatCase(n)))},_getPT:function(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",r=arguments.length>2?arguments[2]:void 0,o=function(s){var c,a=r?r(s):s,u=D.toFlatCase(n);return(c=a==null?void 0:a[u])!==null&&c!==void 0?c:a};return e!=null&&e.hasOwnProperty("_usept")?{_usept:e._usept,originalValue:o(e.originalValue),value:o(e.value)}:o(e)},_usePT:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=arguments.length>1?arguments[1]:void 0,r=arguments.length>2?arguments[2]:void 0,o=arguments.length>3?arguments[3]:void 0,i=arguments.length>4?arguments[4]:void 0,s=function(_){return r(_,o,i)};if(n!=null&&n.hasOwnProperty("_usept")){var c,a=n._usept||((c=e.$config)===null||c===void 0?void 0:c.ptOptions)||{},u=a.mergeSections,f=u===void 0?!0:u,p=a.mergeProps,v=p===void 0?!1:p,w=s(n.originalValue),C=s(n.value);return w===void 0&&C===void 0?void 0:D.isString(C)?C:D.isString(w)?w:f||!f&&C?v?re._mergeProps(e,v,w,C):le(le({},w),C):C}return s(n)},_useDefaultPT:function(){var e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=arguments.length>2?arguments[2]:void 0,o=arguments.length>3?arguments[3]:void 0,i=arguments.length>4?arguments[4]:void 0;return re._usePT(e,n,r,o,i)},_hook:function(e,n,r,o,i,s){var c,a,u="on".concat(D.toCapitalCase(n)),f=re._getConfig(o,i),p=r==null?void 0:r.$instance,v=re._usePT(p,re._getPT(o==null||(c=o.value)===null||c===void 0?void 0:c.pt,e),re._getOptionValue,"hooks.".concat(u)),w=re._useDefaultPT(p,f==null||(a=f.pt)===null||a===void 0||(a=a.directives)===null||a===void 0?void 0:a[e],re._getOptionValue,"hooks.".concat(u)),C={el:r,binding:o,vnode:i,prevVnode:s};v==null||v(p,C),w==null||w(p,C)},_mergeProps:function(){for(var e=arguments.length>1?arguments[1]:void 0,n=arguments.length,r=new Array(n>2?n-2:0),o=2;o<n;o++)r[o-2]=arguments[o];return D.isFunction(e)?e.apply(void 0,r):l.mergeProps.apply(void 0,r)},_extend:function(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},r=function(i,s,c,a,u){var f,p;s._$instances=s._$instances||{};var v=re._getConfig(c,a),w=s._$instances[e]||{},C=D.isEmpty(w)?le(le({},n),n==null?void 0:n.methods):{};s._$instances[e]=le(le({},w),{},{$name:e,$host:s,$binding:c,$modifiers:c==null?void 0:c.modifiers,$value:c==null?void 0:c.value,$el:w.$el||s||void 0,$style:le({classes:void 0,inlineStyles:void 0,loadStyle:function(){}},n==null?void 0:n.style),$config:v,defaultPT:function(){return re._getPT(v==null?void 0:v.pt,void 0,function(_){var $;return _==null||($=_.directives)===null||$===void 0?void 0:$[e]})},isUnstyled:function(){var _,$;return((_=s.$instance)===null||_===void 0||(_=_.$binding)===null||_===void 0||(_=_.value)===null||_===void 0?void 0:_.unstyled)!==void 0?($=s.$instance)===null||$===void 0||($=$.$binding)===null||$===void 0||($=$.value)===null||$===void 0?void 0:$.unstyled:v==null?void 0:v.unstyled},ptm:function(){var _,$=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return re._getPTValue(s.$instance,(_=s.$instance)===null||_===void 0||(_=_.$binding)===null||_===void 0||(_=_.value)===null||_===void 0?void 0:_.pt,$,le({},q))},ptmo:function(){var _=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},$=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"",q=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return re._getPTValue(s.$instance,_,$,q,!1)},cx:function(){var _,$,q=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",V=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{};return(_=s.$instance)!==null&&_!==void 0&&_.isUnstyled()?void 0:re._getOptionValue(($=s.$instance)===null||$===void 0||($=$.$style)===null||$===void 0?void 0:$.classes,q,le({},V))},sx:function(){var _,$=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"",q=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!0,V=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};return q?re._getOptionValue((_=s.$instance)===null||_===void 0||(_=_.$style)===null||_===void 0?void 0:_.inlineStyles,$,le({},V)):void 0}},C),s.$instance=s._$instances[e],(f=(p=s.$instance)[i])===null||f===void 0||f.call(p,s,c,a,u),s["$".concat(e)]=s.$instance,re._hook(e,i,s,c,a,u)};return{created:function(i,s,c,a){r("created",i,s,c,a)},beforeMount:function(i,s,c,a){var u,f,p,v,w=re._getConfig(s,c);ct.loadStyle({nonce:w==null||(u=w.csp)===null||u===void 0?void 0:u.nonce}),!((f=i.$instance)!==null&&f!==void 0&&f.isUnstyled())&&((p=i.$instance)===null||p===void 0||(p=p.$style)===null||p===void 0||p.loadStyle({nonce:w==null||(v=w.csp)===null||v===void 0?void 0:v.nonce})),r("beforeMount",i,s,c,a)},mounted:function(i,s,c,a){var u,f,p,v,w=re._getConfig(s,c);ct.loadStyle({nonce:w==null||(u=w.csp)===null||u===void 0?void 0:u.nonce}),!((f=i.$instance)!==null&&f!==void 0&&f.isUnstyled())&&((p=i.$instance)===null||p===void 0||(p=p.$style)===null||p===void 0||p.loadStyle({nonce:w==null||(v=w.csp)===null||v===void 0?void 0:v.nonce})),r("mounted",i,s,c,a)},beforeUpdate:function(i,s,c,a){r("beforeUpdate",i,s,c,a)},updated:function(i,s,c,a){r("updated",i,s,c,a)},beforeUnmount:function(i,s,c,a){r("beforeUnmount",i,s,c,a)},unmounted:function(i,s,c,a){r("unmounted",i,s,c,a)}}},extend:function(){var e=re._getMeta.apply(re,arguments),n=bi(e,2),r=n[0],o=n[1];return le({extend:function(){var s=re._getMeta.apply(re,arguments),c=bi(s,2),a=c[0],u=c[1];return re.extend(a,le(le(le({},o),o==null?void 0:o.methods),u))}},re._extend(r,o))}},Md={root:"p-ink"},Ud=ct.extend({name:"ripple",classes:Md}),Hd=re.extend({style:Ud});function jd(t){return Wd(t)||zd(t)||Kd(t)||Vd()}function Vd(){throw new TypeError(`Invalid attempt to spread non-iterable instance.
146
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function Kd(t,e){if(t){if(typeof t=="string")return yr(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);if(n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set")return Array.from(t);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return yr(t,e)}}function zd(t){if(typeof Symbol<"u"&&t[Symbol.iterator]!=null||t["@@iterator"]!=null)return Array.from(t)}function Wd(t){if(Array.isArray(t))return yr(t)}function yr(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}var qd=Hd.extend("ripple",{mounted:function(e){var n,r=e==null||(n=e.$instance)===null||n===void 0?void 0:n.$config;r&&r.ripple&&(this.create(e),this.bindEvents(e),e.setAttribute("data-pd-ripple",!0))},unmounted:function(e){this.remove(e)},timeout:void 0,methods:{bindEvents:function(e){e.addEventListener("mousedown",this.onMouseDown.bind(this))},unbindEvents:function(e){e.removeEventListener("mousedown",this.onMouseDown.bind(this))},create:function(e){var n=Z.createElement("span",{role:"presentation","aria-hidden":!0,"data-p-ink":!0,"data-p-ink-active":!1,class:!this.isUnstyled()&&this.cx("root"),onAnimationEnd:this.onAnimationEnd.bind(this),"p-bind":this.ptm("root")});e.appendChild(n),this.$el=n},remove:function(e){var n=this.getInk(e);n&&(this.unbindEvents(e),n.removeEventListener("animationend",this.onAnimationEnd),n.remove())},onMouseDown:function(e){var n=this,r=e.currentTarget,o=this.getInk(r);if(!(!o||getComputedStyle(o,null).display==="none")){if(!this.isUnstyled()&&Z.removeClass(o,"p-ink-active"),o.setAttribute("data-p-ink-active","false"),!Z.getHeight(o)&&!Z.getWidth(o)){var i=Math.max(Z.getOuterWidth(r),Z.getOuterHeight(r));o.style.height=i+"px",o.style.width=i+"px"}var s=Z.getOffset(r),c=e.pageX-s.left+document.body.scrollTop-Z.getWidth(o)/2,a=e.pageY-s.top+document.body.scrollLeft-Z.getHeight(o)/2;o.style.top=a+"px",o.style.left=c+"px",!this.isUnstyled()&&Z.addClass(o,"p-ink-active"),o.setAttribute("data-p-ink-active","true"),this.timeout=setTimeout(function(){o&&(!n.isUnstyled()&&Z.removeClass(o,"p-ink-active"),o.setAttribute("data-p-ink-active","false"))},401)}},onAnimationEnd:function(e){this.timeout&&clearTimeout(this.timeout),!this.isUnstyled()&&Z.removeClass(e.currentTarget,"p-ink-active"),e.currentTarget.setAttribute("data-p-ink-active","false")},getInk:function(e){return e&&e.children?jd(e.children).find(function(n){return Z.getAttribute(n,"data-pc-name")==="ripple"}):void 0}}}),Gd={name:"BasePanelMenu",extends:yn,props:{model:{type:Array,default:null},expandedKeys:{type:Object,default:null},multiple:{type:Boolean,default:!1},tabindex:{type:Number,default:0}},style:Ld,provide:function(){return{$parentInstance:this}}},Ei={name:"PanelMenuSub",hostName:"PanelMenu",extends:yn,emits:["item-toggle","item-mousemove"],props:{panelId:{type:String,default:null},focusedItemId:{type:String,default:null},items:{type:Array,default:null},level:{type:Number,default:0},templates:{type:Object,default:null},activeItemPath:{type:Object,default:null},tabindex:{type:Number,default:-1}},methods:{getItemId:function(e){return"".concat(this.panelId,"_").concat(e.key)},getItemKey:function(e){return this.getItemId(e)},getItemProp:function(e,n,r){return e&&e.item?D.getItemValue(e.item[n],r):void 0},getItemLabel:function(e){return this.getItemProp(e,"label")},getPTOptions:function(e,n,r){return this.ptm(e,{context:{item:n,index:r,active:this.isItemActive(n),focused:this.isItemFocused(n),disabled:this.isItemDisabled(n)}})},isItemActive:function(e){return this.activeItemPath.some(function(n){return n.key===e.key})},isItemVisible:function(e){return this.getItemProp(e,"visible")!==!1},isItemDisabled:function(e){return this.getItemProp(e,"disabled")},isItemFocused:function(e){return this.focusedItemId===this.getItemId(e)},isItemGroup:function(e){return D.isNotEmpty(e.items)},onItemClick:function(e,n){this.getItemProp(n,"command",{originalEvent:e,item:n.item}),this.$emit("item-toggle",{processedItem:n,expanded:!this.isItemActive(n)})},onItemToggle:function(e){this.$emit("item-toggle",e)},onItemMouseMove:function(e,n){this.$emit("item-mousemove",{originalEvent:e,processedItem:n})},getAriaSetSize:function(){var e=this;return this.items.filter(function(n){return e.isItemVisible(n)&&!e.getItemProp(n,"separator")}).length},getAriaPosInset:function(e){var n=this;return e-this.items.slice(0,e).filter(function(r){return n.isItemVisible(r)&&n.getItemProp(r,"separator")}).length+1},getMenuItemProps:function(e,n){return{action:l.mergeProps({class:this.cx("action"),tabindex:-1,"aria-hidden":!0},this.getPTOptions("action",e,n)),icon:l.mergeProps({class:[this.cx("icon"),this.getItemProp(e,"icon")]},this.getPTOptions("icon",e,n)),label:l.mergeProps({class:this.cx("label")},this.getPTOptions("label",e,n)),submenuicon:l.mergeProps({class:this.cx("submenuIcon")},this.getPTOptions("submenuicon",e,n))}}},components:{ChevronRightIcon:hr,ChevronDownIcon:mr},directives:{ripple:qd}},Jd=["tabindex"],Yd=["id","aria-label","aria-expanded","aria-level","aria-setsize","aria-posinset","data-p-focused","data-p-disabled"],Xd=["onClick","onMousemove"],Zd=["href","target"];function Qd(t,e,n,r,o,i){var s=l.resolveComponent("PanelMenuSub",!0),c=l.resolveDirective("ripple");return l.openBlock(),l.createElementBlock("ul",{class:l.normalizeClass(t.cx("submenu")),tabindex:n.tabindex},[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(n.items,function(a,u){return l.openBlock(),l.createElementBlock(l.Fragment,{key:i.getItemKey(a)},[i.isItemVisible(a)&&!i.getItemProp(a,"separator")?(l.openBlock(),l.createElementBlock("li",l.mergeProps({key:0,id:i.getItemId(a),class:[t.cx("menuitem",{processedItem:a}),i.getItemProp(a,"class")],style:i.getItemProp(a,"style"),role:"treeitem","aria-label":i.getItemLabel(a),"aria-expanded":i.isItemGroup(a)?i.isItemActive(a):void 0,"aria-level":n.level+1,"aria-setsize":i.getAriaSetSize(),"aria-posinset":i.getAriaPosInset(u)},i.getPTOptions("menuitem",a,u),{"data-p-focused":i.isItemFocused(a),"data-p-disabled":i.isItemDisabled(a)}),[l.createElementVNode("div",l.mergeProps({class:t.cx("content"),onClick:function(p){return i.onItemClick(p,a)},onMousemove:function(p){return i.onItemMouseMove(p,a)}},i.getPTOptions("content",a,u)),[n.templates.item?(l.openBlock(),l.createBlock(l.resolveDynamicComponent(n.templates.item),{key:1,item:a.item,root:!1,active:i.isItemActive(a),hasSubmenu:i.isItemGroup(a),label:i.getItemLabel(a),props:i.getMenuItemProps(a,u)},null,8,["item","active","hasSubmenu","label","props"])):l.withDirectives((l.openBlock(),l.createElementBlock("a",l.mergeProps({key:0,href:i.getItemProp(a,"url"),class:t.cx("action"),target:i.getItemProp(a,"target"),tabindex:"-1","aria-hidden":"true"},i.getPTOptions("action",a,u)),[i.isItemGroup(a)?(l.openBlock(),l.createElementBlock(l.Fragment,{key:0},[n.templates.submenuicon?(l.openBlock(),l.createBlock(l.resolveDynamicComponent(n.templates.submenuicon),l.mergeProps({key:0,class:t.cx("submenuIcon"),active:i.isItemActive(a)},i.getPTOptions("submenuIcon",a,u)),null,16,["class","active"])):(l.openBlock(),l.createBlock(l.resolveDynamicComponent(i.isItemActive(a)?"ChevronDownIcon":"ChevronRightIcon"),l.mergeProps({key:1,class:t.cx("submenuIcon")},i.getPTOptions("submenuIcon",a,u)),null,16,["class"]))],64)):l.createCommentVNode("",!0),n.templates.itemicon?(l.openBlock(),l.createBlock(l.resolveDynamicComponent(n.templates.itemicon),{key:1,item:a.item,class:l.normalizeClass(t.cx("icon"))},null,8,["item","class"])):i.getItemProp(a,"icon")?(l.openBlock(),l.createElementBlock("span",l.mergeProps({key:2,class:[t.cx("icon"),i.getItemProp(a,"icon")]},i.getPTOptions("icon",a,u)),null,16)):l.createCommentVNode("",!0),l.createElementVNode("span",l.mergeProps({class:t.cx("label")},i.getPTOptions("label",a,u)),l.toDisplayString(i.getItemLabel(a)),17)],16,Zd)),[[c]])],16,Xd),l.createVNode(l.Transition,l.mergeProps({name:"p-toggleable-content"},t.ptm("transition")),{default:l.withCtx(function(){return[l.withDirectives(l.createElementVNode("div",l.mergeProps({class:t.cx("toggleableContent")},t.ptm("toggleableContent")),[i.isItemVisible(a)&&i.isItemGroup(a)?(l.openBlock(),l.createBlock(s,l.mergeProps({key:0,id:i.getItemId(a)+"_list",role:"group",panelId:n.panelId,focusedItemId:n.focusedItemId,items:a.items,level:n.level+1,templates:n.templates,activeItemPath:n.activeItemPath,onItemToggle:i.onItemToggle,onItemMousemove:e[0]||(e[0]=function(f){return t.$emit("item-mousemove",f)}),pt:t.pt,unstyled:t.unstyled},t.ptm("submenu")),null,16,["id","panelId","focusedItemId","items","level","templates","activeItemPath","onItemToggle","pt","unstyled"])):l.createCommentVNode("",!0)],16),[[l.vShow,i.isItemActive(a)]])]}),_:2},1040)],16,Yd)):l.createCommentVNode("",!0),i.isItemVisible(a)&&i.getItemProp(a,"separator")?(l.openBlock(),l.createElementBlock("li",l.mergeProps({key:1,style:i.getItemProp(a,"style"),class:[t.cx("separator"),i.getItemProp(a,"class")],role:"separator"},t.ptm("separator")),null,16)):l.createCommentVNode("",!0)],64)}),128))],10,Jd)}Ei.render=Qd;function ef(t,e){return of(t)||rf(t,e)||nf(t,e)||tf()}function tf(){throw new TypeError(`Invalid attempt to destructure non-iterable instance.
147
+ In order to be iterable, non-array objects must have a [Symbol.iterator]() method.`)}function nf(t,e){if(t){if(typeof t=="string")return Si(t,e);var n=Object.prototype.toString.call(t).slice(8,-1);if(n==="Object"&&t.constructor&&(n=t.constructor.name),n==="Map"||n==="Set")return Array.from(t);if(n==="Arguments"||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Si(t,e)}}function Si(t,e){(e==null||e>t.length)&&(e=t.length);for(var n=0,r=new Array(e);n<e;n++)r[n]=t[n];return r}function rf(t,e){var n=t==null?null:typeof Symbol<"u"&&t[Symbol.iterator]||t["@@iterator"];if(n!=null){var r,o,i,s,c=[],a=!0,u=!1;try{if(i=(n=n.call(t)).next,e===0){if(Object(n)!==n)return;a=!1}else for(;!(a=(r=i.call(n)).done)&&(c.push(r.value),c.length!==e);a=!0);}catch(f){u=!0,o=f}finally{try{if(!a&&n.return!=null&&(s=n.return(),Object(s)!==s))return}finally{if(u)throw o}}return c}}function of(t){if(Array.isArray(t))return t}var _i={name:"PanelMenuList",hostName:"PanelMenu",extends:yn,emits:["item-toggle","header-focus"],props:{panelId:{type:String,default:null},items:{type:Array,default:null},templates:{type:Object,default:null},expandedKeys:{type:Object,default:null}},searchTimeout:null,searchValue:null,data:function(){return{focused:!1,focusedItem:null,activeItemPath:[]}},watch:{expandedKeys:function(e){this.autoUpdateActiveItemPath(e)}},mounted:function(){this.autoUpdateActiveItemPath(this.expandedKeys)},methods:{getItemProp:function(e,n){return e&&e.item?D.getItemValue(e.item[n]):void 0},getItemLabel:function(e){return this.getItemProp(e,"label")},isItemVisible:function(e){return this.getItemProp(e,"visible")!==!1},isItemDisabled:function(e){return this.getItemProp(e,"disabled")},isItemActive:function(e){return this.activeItemPath.some(function(n){return n.key===e.parentKey})},isItemGroup:function(e){return D.isNotEmpty(e.items)},onFocus:function(e){this.focused=!0,this.focusedItem=this.focusedItem||(this.isElementInPanel(e,e.relatedTarget)?this.findFirstItem():this.findLastItem())},onBlur:function(){this.focused=!1,this.focusedItem=null,this.searchValue=""},onKeyDown:function(e){var n=e.metaKey||e.ctrlKey;switch(e.code){case"ArrowDown":this.onArrowDownKey(e);break;case"ArrowUp":this.onArrowUpKey(e);break;case"ArrowLeft":this.onArrowLeftKey(e);break;case"ArrowRight":this.onArrowRightKey(e);break;case"Home":this.onHomeKey(e);break;case"End":this.onEndKey(e);break;case"Space":this.onSpaceKey(e);break;case"Enter":case"NumpadEnter":this.onEnterKey(e);break;case"Escape":case"Tab":case"PageDown":case"PageUp":case"Backspace":case"ShiftLeft":case"ShiftRight":break;default:!n&&D.isPrintableCharacter(e.key)&&this.searchItems(e,e.key);break}},onArrowDownKey:function(e){var n=D.isNotEmpty(this.focusedItem)?this.findNextItem(this.focusedItem):this.findFirstItem();this.changeFocusedItem({originalEvent:e,processedItem:n,focusOnNext:!0}),e.preventDefault()},onArrowUpKey:function(e){var n=D.isNotEmpty(this.focusedItem)?this.findPrevItem(this.focusedItem):this.findLastItem();this.changeFocusedItem({originalEvent:e,processedItem:n,selfCheck:!0}),e.preventDefault()},onArrowLeftKey:function(e){var n=this;if(D.isNotEmpty(this.focusedItem)){var r=this.activeItemPath.some(function(o){return o.key===n.focusedItem.key});r?this.activeItemPath=this.activeItemPath.filter(function(o){return o.key!==n.focusedItem.key}):this.focusedItem=D.isNotEmpty(this.focusedItem.parent)?this.focusedItem.parent:this.focusedItem,e.preventDefault()}},onArrowRightKey:function(e){var n=this;if(D.isNotEmpty(this.focusedItem)){var r=this.isItemGroup(this.focusedItem);if(r){var o=this.activeItemPath.some(function(i){return i.key===n.focusedItem.key});o?this.onArrowDownKey(e):(this.activeItemPath=this.activeItemPath.filter(function(i){return i.parentKey!==n.focusedItem.parentKey}),this.activeItemPath.push(this.focusedItem))}e.preventDefault()}},onHomeKey:function(e){this.changeFocusedItem({originalEvent:e,processedItem:this.findFirstItem(),allowHeaderFocus:!1}),e.preventDefault()},onEndKey:function(e){this.changeFocusedItem({originalEvent:e,processedItem:this.findLastItem(),focusOnNext:!0,allowHeaderFocus:!1}),e.preventDefault()},onEnterKey:function(e){if(D.isNotEmpty(this.focusedItem)){var n=Z.findSingle(this.$el,'li[id="'.concat("".concat(this.focusedItemId),'"]')),r=n&&(Z.findSingle(n,'[data-pc-section="action"]')||Z.findSingle(n,"a,button"));r?r.click():n&&n.click()}e.preventDefault()},onSpaceKey:function(e){this.onEnterKey(e)},onItemToggle:function(e){var n=e.processedItem,r=e.expanded;this.expandedKeys?this.$emit("item-toggle",{item:n.item,expanded:r}):(this.activeItemPath=this.activeItemPath.filter(function(o){return o.parentKey!==n.parentKey}),r&&this.activeItemPath.push(n)),this.focusedItem=n,Z.focus(this.$el)},onItemMouseMove:function(e){this.focused&&(this.focusedItem=e.processedItem)},isElementInPanel:function(e,n){var r=e.currentTarget.closest('[data-pc-section="panel"]');return r&&r.contains(n)},isItemMatched:function(e){var n;return this.isValidItem(e)&&((n=this.getItemLabel(e))===null||n===void 0?void 0:n.toLocaleLowerCase(this.searchLocale).startsWith(this.searchValue.toLocaleLowerCase(this.searchLocale)))},isVisibleItem:function(e){return!!e&&(e.level===0||this.isItemActive(e))&&this.isItemVisible(e)},isValidItem:function(e){return!!e&&!this.isItemDisabled(e)&&!this.getItemProp(e,"separator")},findFirstItem:function(){var e=this;return this.visibleItems.find(function(n){return e.isValidItem(n)})},findLastItem:function(){var e=this;return D.findLast(this.visibleItems,function(n){return e.isValidItem(n)})},findNextItem:function(e){var n=this,r=this.visibleItems.findIndex(function(i){return i.key===e.key}),o=r<this.visibleItems.length-1?this.visibleItems.slice(r+1).find(function(i){return n.isValidItem(i)}):void 0;return o||e},findPrevItem:function(e){var n=this,r=this.visibleItems.findIndex(function(i){return i.key===e.key}),o=r>0?D.findLast(this.visibleItems.slice(0,r),function(i){return n.isValidItem(i)}):void 0;return o||e},searchItems:function(e,n){var r=this;this.searchValue=(this.searchValue||"")+n;var o=null,i=!1;if(D.isNotEmpty(this.focusedItem)){var s=this.visibleItems.findIndex(function(c){return c.key===r.focusedItem.key});o=this.visibleItems.slice(s).find(function(c){return r.isItemMatched(c)}),o=D.isEmpty(o)?this.visibleItems.slice(0,s).find(function(c){return r.isItemMatched(c)}):o}else o=this.visibleItems.find(function(c){return r.isItemMatched(c)});return D.isNotEmpty(o)&&(i=!0),D.isEmpty(o)&&D.isEmpty(this.focusedItem)&&(o=this.findFirstItem()),D.isNotEmpty(o)&&this.changeFocusedItem({originalEvent:e,processedItem:o,allowHeaderFocus:!1}),this.searchTimeout&&clearTimeout(this.searchTimeout),this.searchTimeout=setTimeout(function(){r.searchValue="",r.searchTimeout=null},500),i},changeFocusedItem:function(e){var n=e.originalEvent,r=e.processedItem,o=e.focusOnNext,i=e.selfCheck,s=e.allowHeaderFocus,c=s===void 0?!0:s;D.isNotEmpty(this.focusedItem)&&this.focusedItem.key!==r.key?(this.focusedItem=r,this.scrollInView()):c&&this.$emit("header-focus",{originalEvent:n,focusOnNext:o,selfCheck:i})},scrollInView:function(){var e=Z.findSingle(this.$el,'li[id="'.concat("".concat(this.focusedItemId),'"]'));e&&e.scrollIntoView&&e.scrollIntoView({block:"nearest",inline:"start"})},autoUpdateActiveItemPath:function(e){var n=this;this.activeItemPath=Object.entries(e||{}).reduce(function(r,o){var i=ef(o,2),s=i[0],c=i[1];if(c){var a=n.findProcessedItemByItemKey(s);a&&r.push(a)}return r},[])},findProcessedItemByItemKey:function(e,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0;if(n=n||r===0&&this.processedItems,!n)return null;for(var o=0;o<n.length;o++){var i=n[o];if(this.getItemProp(i,"key")===e)return i;var s=this.findProcessedItemByItemKey(e,i.items,r+1);if(s)return s}},createProcessedItems:function(e){var n=this,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,o=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},i=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"",s=[];return e&&e.forEach(function(c,a){var u=(i!==""?i+"_":"")+a,f={item:c,index:a,level:r,key:u,parent:o,parentKey:i};f.items=n.createProcessedItems(c.items,r+1,f,u),s.push(f)}),s},flatItems:function(e){var n=this,r=arguments.length>1&&arguments[1]!==void 0?arguments[1]:[];return e&&e.forEach(function(o){n.isVisibleItem(o)&&(r.push(o),n.flatItems(o.items,r))}),r}},computed:{processedItems:function(){return this.createProcessedItems(this.items||[])},visibleItems:function(){return this.flatItems(this.processedItems)},focusedItemId:function(){return D.isNotEmpty(this.focusedItem)?"".concat(this.panelId,"_").concat(this.focusedItem.key):null}},components:{PanelMenuSub:Ei}};function sf(t,e,n,r,o,i){var s=l.resolveComponent("PanelMenuSub");return l.openBlock(),l.createBlock(s,l.mergeProps({id:n.panelId+"_list",class:t.cx("menu"),role:"tree",tabindex:-1,"aria-activedescendant":o.focused?i.focusedItemId:void 0,panelId:n.panelId,focusedItemId:o.focused?i.focusedItemId:void 0,items:i.processedItems,templates:n.templates,activeItemPath:o.activeItemPath,onFocus:i.onFocus,onBlur:i.onBlur,onKeydown:i.onKeyDown,onItemToggle:i.onItemToggle,onItemMousemove:i.onItemMouseMove,pt:t.pt,unstyled:t.unstyled},t.ptm("menu")),null,16,["id","class","aria-activedescendant","panelId","focusedItemId","items","templates","activeItemPath","onFocus","onBlur","onKeydown","onItemToggle","onItemMousemove","pt","unstyled"])}_i.render=sf;function qt(t){"@babel/helpers - typeof";return qt=typeof Symbol=="function"&&typeof Symbol.iterator=="symbol"?function(e){return typeof e}:function(e){return e&&typeof Symbol=="function"&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},qt(t)}function Ci(t,e){var n=Object.keys(t);if(Object.getOwnPropertySymbols){var r=Object.getOwnPropertySymbols(t);e&&(r=r.filter(function(o){return Object.getOwnPropertyDescriptor(t,o).enumerable})),n.push.apply(n,r)}return n}function af(t){for(var e=1;e<arguments.length;e++){var n=arguments[e]!=null?arguments[e]:{};e%2?Ci(Object(n),!0).forEach(function(r){lf(t,r,n[r])}):Object.getOwnPropertyDescriptors?Object.defineProperties(t,Object.getOwnPropertyDescriptors(n)):Ci(Object(n)).forEach(function(r){Object.defineProperty(t,r,Object.getOwnPropertyDescriptor(n,r))})}return t}function lf(t,e,n){return e=cf(e),e in t?Object.defineProperty(t,e,{value:n,enumerable:!0,configurable:!0,writable:!0}):t[e]=n,t}function cf(t){var e=uf(t,"string");return qt(e)=="symbol"?e:String(e)}function uf(t,e){if(qt(t)!="object"||!t)return t;var n=t[Symbol.toPrimitive];if(n!==void 0){var r=n.call(t,e||"default");if(qt(r)!="object")return r;throw new TypeError("@@toPrimitive must return a primitive value.")}return(e==="string"?String:Number)(t)}var Ai={name:"PanelMenu",extends:Gd,inheritAttrs:!1,emits:["update:expandedKeys","panel-open","panel-close"],data:function(){return{id:this.$attrs.id,activeItem:null,activeItems:[]}},watch:{"$attrs.id":function(e){this.id=e||ri()}},mounted:function(){this.id=this.id||ri()},methods:{getItemProp:function(e,n){return e?D.getItemValue(e[n]):void 0},getItemLabel:function(e){return this.getItemProp(e,"label")},getPTOptions:function(e,n,r){return this.ptm(e,{context:{index:r,active:this.isItemActive(n),focused:this.isItemFocused(n),disabled:this.isItemDisabled(n)}})},isItemActive:function(e){return this.expandedKeys?this.expandedKeys[this.getItemProp(e,"key")]:this.multiple?this.activeItems.some(function(n){return D.equals(e,n)}):D.equals(e,this.activeItem)},isItemVisible:function(e){return this.getItemProp(e,"visible")!==!1},isItemDisabled:function(e){return this.getItemProp(e,"disabled")},isItemFocused:function(e){return D.equals(e,this.activeItem)},getPanelId:function(e){return"".concat(this.id,"_").concat(e)},getPanelKey:function(e){return this.getPanelId(e)},getHeaderId:function(e){return"".concat(this.getPanelId(e),"_header")},getContentId:function(e){return"".concat(this.getPanelId(e),"_content")},onHeaderClick:function(e,n){if(this.isItemDisabled(n)){e.preventDefault();return}n.command&&n.command({originalEvent:e,item:n}),this.changeActiveItem(e,n),Z.focus(e.currentTarget)},onHeaderKeyDown:function(e,n){switch(e.code){case"ArrowDown":this.onHeaderArrowDownKey(e);break;case"ArrowUp":this.onHeaderArrowUpKey(e);break;case"Home":this.onHeaderHomeKey(e);break;case"End":this.onHeaderEndKey(e);break;case"Enter":case"NumpadEnter":case"Space":this.onHeaderEnterKey(e,n);break}},onHeaderArrowDownKey:function(e){var n=Z.getAttribute(e.currentTarget,"data-p-highlight")===!0?Z.findSingle(e.currentTarget.nextElementSibling,'[data-pc-section="menu"]'):null;n?Z.focus(n):this.updateFocusedHeader({originalEvent:e,focusOnNext:!0}),e.preventDefault()},onHeaderArrowUpKey:function(e){var n=this.findPrevHeader(e.currentTarget.parentElement)||this.findLastHeader(),r=Z.getAttribute(n,"data-p-highlight")===!0?Z.findSingle(n.nextElementSibling,'[data-pc-section="menu"]'):null;r?Z.focus(r):this.updateFocusedHeader({originalEvent:e,focusOnNext:!1}),e.preventDefault()},onHeaderHomeKey:function(e){this.changeFocusedHeader(e,this.findFirstHeader()),e.preventDefault()},onHeaderEndKey:function(e){this.changeFocusedHeader(e,this.findLastHeader()),e.preventDefault()},onHeaderEnterKey:function(e,n){var r=Z.findSingle(e.currentTarget,'[data-pc-section="headeraction"]');r?r.click():this.onHeaderClick(e,n),e.preventDefault()},findNextHeader:function(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,r=n?e:e.nextElementSibling,o=Z.findSingle(r,'[data-pc-section="header"]');return o?Z.getAttribute(o,"data-p-disabled")?this.findNextHeader(o.parentElement):o:null},findPrevHeader:function(e){var n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,r=n?e:e.previousElementSibling,o=Z.findSingle(r,'[data-pc-section="header"]');return o?Z.getAttribute(o,"data-p-disabled")?this.findPrevHeader(o.parentElement):o:null},findFirstHeader:function(){return this.findNextHeader(this.$el.firstElementChild,!0)},findLastHeader:function(){return this.findPrevHeader(this.$el.lastElementChild,!0)},updateFocusedHeader:function(e){var n=e.originalEvent,r=e.focusOnNext,o=e.selfCheck,i=n.currentTarget.closest('[data-pc-section="panel"]'),s=o?Z.findSingle(i,'[data-pc-section="header"]'):r?this.findNextHeader(i):this.findPrevHeader(i);s?this.changeFocusedHeader(n,s):r?this.onHeaderHomeKey(n):this.onHeaderEndKey(n)},changeActiveItem:function(e,n){var r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!1;if(!this.isItemDisabled(n)){var o=this.isItemActive(n),i=o?"panel-close":"panel-open";this.activeItem=r?n:this.activeItem&&D.equals(n,this.activeItem)?null:n,this.multiple&&(this.activeItems.some(function(s){return D.equals(n,s)})?this.activeItems=this.activeItems.filter(function(s){return!D.equals(n,s)}):this.activeItems.push(n)),this.changeExpandedKeys({item:n,expanded:!o}),this.$emit(i,{originalEvent:e,item:n})}},changeExpandedKeys:function(e){var n=e.item,r=e.expanded,o=r===void 0?!1:r;if(this.expandedKeys){var i=af({},this.expandedKeys);o?i[n.key]=!0:delete i[n.key],this.$emit("update:expandedKeys",i)}},changeFocusedHeader:function(e,n){n&&Z.focus(n)},getMenuItemProps:function(e,n){return{icon:l.mergeProps({class:[this.cx("headerIcon"),this.getItemProp(e,"icon")]},this.getPTOptions("headerIcon",e,n)),label:l.mergeProps({class:this.cx("headerLabel")},this.getPTOptions("headerLabel",e,n))}}},components:{PanelMenuList:_i,ChevronRightIcon:hr,ChevronDownIcon:mr}},df=["id"],ff=["id","tabindex","aria-label","aria-expanded","aria-controls","aria-disabled","onClick","onKeydown","data-p-highlight","data-p-disabled"],pf=["href"],mf=["id","aria-labelledby"];function hf(t,e,n,r,o,i){var s=l.resolveComponent("PanelMenuList");return l.openBlock(),l.createElementBlock("div",l.mergeProps({id:o.id,class:t.cx("root")},t.ptmi("root")),[(l.openBlock(!0),l.createElementBlock(l.Fragment,null,l.renderList(t.model,function(c,a){return l.openBlock(),l.createElementBlock(l.Fragment,{key:i.getPanelKey(a)},[i.isItemVisible(c)?(l.openBlock(),l.createElementBlock("div",l.mergeProps({key:0,style:i.getItemProp(c,"style"),class:[t.cx("panel"),i.getItemProp(c,"class")]},t.ptm("panel")),[l.createElementVNode("div",l.mergeProps({id:i.getHeaderId(a),class:[t.cx("header",{item:c}),i.getItemProp(c,"headerClass")],tabindex:i.isItemDisabled(c)?-1:t.tabindex,role:"button","aria-label":i.getItemLabel(c),"aria-expanded":i.isItemActive(c),"aria-controls":i.getContentId(a),"aria-disabled":i.isItemDisabled(c),onClick:function(f){return i.onHeaderClick(f,c)},onKeydown:function(f){return i.onHeaderKeyDown(f,c)}},i.getPTOptions("header",c,a),{"data-p-highlight":i.isItemActive(c),"data-p-disabled":i.isItemDisabled(c)}),[l.createElementVNode("div",l.mergeProps({class:t.cx("headerContent")},i.getPTOptions("headerContent",c,a)),[t.$slots.item?(l.openBlock(),l.createBlock(l.resolveDynamicComponent(t.$slots.item),{key:1,item:c,root:!0,active:i.isItemActive(c),hasSubmenu:i.getItemProp(c,"items"),label:i.getItemLabel(c),props:i.getMenuItemProps(c,a)},null,8,["item","active","hasSubmenu","label","props"])):(l.openBlock(),l.createElementBlock("a",l.mergeProps({key:0,href:i.getItemProp(c,"url"),class:t.cx("headerAction"),tabindex:-1},i.getPTOptions("headerAction",c,a)),[i.getItemProp(c,"items")?l.renderSlot(t.$slots,"submenuicon",{key:0,active:i.isItemActive(c)},function(){return[(l.openBlock(),l.createBlock(l.resolveDynamicComponent(i.isItemActive(c)?"ChevronDownIcon":"ChevronRightIcon"),l.mergeProps({class:t.cx("submenuIcon")},i.getPTOptions("submenuIcon",c,a)),null,16,["class"]))]}):l.createCommentVNode("",!0),t.$slots.headericon?(l.openBlock(),l.createBlock(l.resolveDynamicComponent(t.$slots.headericon),{key:1,item:c,class:l.normalizeClass([t.cx("headerIcon"),i.getItemProp(c,"icon")])},null,8,["item","class"])):i.getItemProp(c,"icon")?(l.openBlock(),l.createElementBlock("span",l.mergeProps({key:2,class:[t.cx("headerIcon"),i.getItemProp(c,"icon")]},i.getPTOptions("headerIcon",c,a)),null,16)):l.createCommentVNode("",!0),l.createElementVNode("span",l.mergeProps({class:t.cx("headerLabel")},i.getPTOptions("headerLabel",c,a)),l.toDisplayString(i.getItemLabel(c)),17)],16,pf))],16)],16,ff),l.createVNode(l.Transition,l.mergeProps({name:"p-toggleable-content"},t.ptm("transition")),{default:l.withCtx(function(){return[l.withDirectives(l.createElementVNode("div",l.mergeProps({id:i.getContentId(a),class:t.cx("toggleableContent"),role:"region","aria-labelledby":i.getHeaderId(a)},t.ptm("toggleableContent")),[i.getItemProp(c,"items")?(l.openBlock(),l.createElementBlock("div",l.mergeProps({key:0,class:t.cx("menuContent")},t.ptm("menuContent")),[l.createVNode(s,{panelId:i.getPanelId(a),items:i.getItemProp(c,"items"),templates:t.$slots,expandedKeys:t.expandedKeys,onItemToggle:i.changeExpandedKeys,onHeaderFocus:i.updateFocusedHeader,pt:t.pt,unstyled:t.unstyled},null,8,["panelId","items","templates","expandedKeys","onItemToggle","onHeaderFocus","pt","unstyled"])],16)):l.createCommentVNode("",!0)],16,mf),[[l.vShow,i.isItemActive(c)]])]}),_:2},1040)],16)):l.createCommentVNode("",!0)],64)}),128))],16,df)}Ai.render=hf;const gf=["data-active","href","onClick"],yf={class:"sf-ml-2"},bf=["href","target"],vf={class:"sf-ml-2"},wf=l.createElementVNode("div",{class:"sf-flex-grow-1"},null,-1),Ef=l.defineComponent({__name:"PanelMenu",props:{items:{}},setup(t){const e=t,n=Fu();r(e.items);function r(s,c=void 0){s.forEach(a=>{c&&(a.sourceKey=c),a.items&&r(a.items,a.key)})}const o=l.ref({});function i(s,c,a=void 0){s.forEach(u=>{u.route&&u.route===c&&a&&(o.value[a]=a===u.sourceKey),u.items&&i(u.items,c,u.key)})}return l.watch(()=>n.name,s=>{s&&i(e.items,s.toString())}),(s,c)=>{const a=l.resolveComponent("router-link");return l.openBlock(),l.createBlock(l.unref(Ai),{model:e.items,expandedKeys:o.value,"onUpdate:expandedKeys":c[0]||(c[0]=u=>o.value=u),multiple:!0,class:l.normalizeClass("sf-p-2")},{item:l.withCtx(({item:u,active:f})=>[u.route?(l.openBlock(),l.createBlock(a,{key:0,to:{name:u.route},custom:""},{default:l.withCtx(({href:p,navigate:v,isActive:w})=>[l.createElementVNode("a",{class:"sf-flex sf-align-items-center sf-px-3 sf-py-2 sf-ripple","data-active":w,href:p,onClick:v},[l.createVNode(Qe,{icon:u.icon??"chevron_right"},null,8,["icon"]),l.createElementVNode("span",yf,l.toDisplayString(u.label),1)],8,gf)]),_:2},1032,["to"])):(l.openBlock(),l.createElementBlock("a",{key:1,class:"sf-flex sf-align-items-center sf-pl-3 sf-py-2",href:u.url,target:u.target},[u.icon?(l.openBlock(),l.createBlock(Qe,{key:0,icon:u.icon},null,8,["icon"])):l.createCommentVNode("",!0),l.createElementVNode("span",vf,l.toDisplayString(u.label),1),wf,l.createVNode(Qe,{icon:f?"expand_less":"expand_more"},null,8,["icon"])],8,bf))]),_:1},8,["model","expandedKeys"])}}});var Sf=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function _f(t){return t&&t.__esModule&&Object.prototype.hasOwnProperty.call(t,"default")?t.default:t}function Cf(t){if(t.__esModule)return t;var e=t.default;if(typeof e=="function"){var n=function r(){return this instanceof r?Reflect.construct(e,arguments,this.constructor):e.apply(this,arguments)};n.prototype=e.prototype}else n={};return Object.defineProperty(n,"__esModule",{value:!0}),Object.keys(t).forEach(function(r){var o=Object.getOwnPropertyDescriptor(t,r);Object.defineProperty(n,r,o.get?o:{enumerable:!0,get:function(){return t[r]}})}),n}var bn={};bn.byteLength=xf,bn.toByteArray=Pf,bn.fromByteArray=Lf;for(var Ke=[],Ne=[],Af=typeof Uint8Array<"u"?Uint8Array:Array,br="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/",vt=0,kf=br.length;vt<kf;++vt)Ke[vt]=br[vt],Ne[br.charCodeAt(vt)]=vt;Ne[45]=62,Ne[95]=63;function ki(t){var e=t.length;if(e%4>0)throw new Error("Invalid string. Length must be a multiple of 4");var n=t.indexOf("=");n===-1&&(n=e);var r=n===e?0:4-n%4;return[n,r]}function xf(t){var e=ki(t),n=e[0],r=e[1];return(n+r)*3/4-r}function If(t,e,n){return(e+n)*3/4-n}function Pf(t){var e,n=ki(t),r=n[0],o=n[1],i=new Af(If(t,r,o)),s=0,c=o>0?r-4:r,a;for(a=0;a<c;a+=4)e=Ne[t.charCodeAt(a)]<<18|Ne[t.charCodeAt(a+1)]<<12|Ne[t.charCodeAt(a+2)]<<6|Ne[t.charCodeAt(a+3)],i[s++]=e>>16&255,i[s++]=e>>8&255,i[s++]=e&255;return o===2&&(e=Ne[t.charCodeAt(a)]<<2|Ne[t.charCodeAt(a+1)]>>4,i[s++]=e&255),o===1&&(e=Ne[t.charCodeAt(a)]<<10|Ne[t.charCodeAt(a+1)]<<4|Ne[t.charCodeAt(a+2)]>>2,i[s++]=e>>8&255,i[s++]=e&255),i}function Tf(t){return Ke[t>>18&63]+Ke[t>>12&63]+Ke[t>>6&63]+Ke[t&63]}function Of(t,e,n){for(var r,o=[],i=e;i<n;i+=3)r=(t[i]<<16&16711680)+(t[i+1]<<8&65280)+(t[i+2]&255),o.push(Tf(r));return o.join("")}function Lf(t){for(var e,n=t.length,r=n%3,o=[],i=16383,s=0,c=n-r;s<c;s+=i)o.push(Of(t,s,s+i>c?c:s+i));return r===1?(e=t[n-1],o.push(Ke[e>>2]+Ke[e<<4&63]+"==")):r===2&&(e=(t[n-2]<<8)+t[n-1],o.push(Ke[e>>10]+Ke[e>>4&63]+Ke[e<<2&63]+"=")),o.join("")}var xi={exports:{}};const Ii=Cf(Object.freeze(Object.defineProperty({__proto__:null,default:{}},Symbol.toStringTag,{value:"Module"})));/**
66
148
  * [js-sha256]{@link https://github.com/emn178/js-sha256}
67
149
  *
68
150
  * @version 0.10.1
69
151
  * @author Chen, Yi-Cyuan [emn178@gmail.com]
70
152
  * @copyright Chen, Yi-Cyuan 2014-2023
71
153
  * @license MIT
72
- */(function(t){(function(){var e="input is invalid type",n=typeof window=="object",o=n?window:{};o.JS_SHA256_NO_WINDOW&&(n=!1);var r=!n&&typeof self=="object",s=!o.JS_SHA256_NO_NODE_JS&&typeof process=="object"&&process.versions&&process.versions.node;s?o=vl:r&&(o=self);var i=!o.JS_SHA256_NO_COMMON_JS&&!0&&t.exports,f=!o.JS_SHA256_NO_ARRAY_BUFFER&&typeof ArrayBuffer<"u",u="0123456789abcdef".split(""),w=[-2147483648,8388608,32768,128],E=[24,16,8,0],b=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],j=["hex","array","digest","arrayBuffer"],$=[];(o.JS_SHA256_NO_NODE_JS||!Array.isArray)&&(Array.isArray=function(g){return Object.prototype.toString.call(g)==="[object Array]"}),f&&(o.JS_SHA256_NO_ARRAY_BUFFER_IS_VIEW||!ArrayBuffer.isView)&&(ArrayBuffer.isView=function(g){return typeof g=="object"&&g.buffer&&g.buffer.constructor===ArrayBuffer});var B=function(g,T){return function(U){return new V(T,!0).update(U)[g]()}},N=function(g){var T=B("hex",g);s&&(T=D(T,g)),T.create=function(){return new V(g)},T.update=function(v){return T.create().update(v)};for(var U=0;U<j.length;++U){var P=j[U];T[P]=B(P,g)}return T},D=function(g,T){var U=kr,P=kr.Buffer,v=T?"sha224":"sha256",_;P.from&&!o.JS_SHA256_NO_BUFFER_FROM?_=P.from:_=function(A){return new P(A)};var z=function(A){if(typeof A=="string")return U.createHash(v).update(A,"utf8").digest("hex");if(A==null)throw new Error(e);return A.constructor===ArrayBuffer&&(A=new Uint8Array(A)),Array.isArray(A)||ArrayBuffer.isView(A)||A.constructor===P?U.createHash(v).update(_(A)).digest("hex"):g(A)};return z},ee=function(g,T){return function(U,P){return new ye(U,T,!0).update(P)[g]()}},oe=function(g){var T=ee("hex",g);T.create=function(v){return new ye(v,g)},T.update=function(v,_){return T.create(v).update(_)};for(var U=0;U<j.length;++U){var P=j[U];T[P]=ee(P,g)}return T};function V(g,T){T?($[0]=$[16]=$[1]=$[2]=$[3]=$[4]=$[5]=$[6]=$[7]=$[8]=$[9]=$[10]=$[11]=$[12]=$[13]=$[14]=$[15]=0,this.blocks=$):this.blocks=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],g?(this.h0=3238371032,this.h1=914150663,this.h2=812702999,this.h3=4144912697,this.h4=4290775857,this.h5=1750603025,this.h6=1694076839,this.h7=3204075428):(this.h0=1779033703,this.h1=3144134277,this.h2=1013904242,this.h3=2773480762,this.h4=1359893119,this.h5=2600822924,this.h6=528734635,this.h7=1541459225),this.block=this.start=this.bytes=this.hBytes=0,this.finalized=this.hashed=!1,this.first=!0,this.is224=g}V.prototype.update=function(g){if(!this.finalized){var T,U=typeof g;if(U!=="string"){if(U==="object"){if(g===null)throw new Error(e);if(f&&g.constructor===ArrayBuffer)g=new Uint8Array(g);else if(!Array.isArray(g)&&(!f||!ArrayBuffer.isView(g)))throw new Error(e)}else throw new Error(e);T=!0}for(var P,v=0,_,z=g.length,A=this.blocks;v<z;){if(this.hashed&&(this.hashed=!1,A[0]=this.block,A[16]=A[1]=A[2]=A[3]=A[4]=A[5]=A[6]=A[7]=A[8]=A[9]=A[10]=A[11]=A[12]=A[13]=A[14]=A[15]=0),T)for(_=this.start;v<z&&_<64;++v)A[_>>2]|=g[v]<<E[_++&3];else for(_=this.start;v<z&&_<64;++v)P=g.charCodeAt(v),P<128?A[_>>2]|=P<<E[_++&3]:P<2048?(A[_>>2]|=(192|P>>6)<<E[_++&3],A[_>>2]|=(128|P&63)<<E[_++&3]):P<55296||P>=57344?(A[_>>2]|=(224|P>>12)<<E[_++&3],A[_>>2]|=(128|P>>6&63)<<E[_++&3],A[_>>2]|=(128|P&63)<<E[_++&3]):(P=65536+((P&1023)<<10|g.charCodeAt(++v)&1023),A[_>>2]|=(240|P>>18)<<E[_++&3],A[_>>2]|=(128|P>>12&63)<<E[_++&3],A[_>>2]|=(128|P>>6&63)<<E[_++&3],A[_>>2]|=(128|P&63)<<E[_++&3]);this.lastByteIndex=_,this.bytes+=_-this.start,_>=64?(this.block=A[16],this.start=_-64,this.hash(),this.hashed=!0):this.start=_}return this.bytes>4294967295&&(this.hBytes+=this.bytes/4294967296<<0,this.bytes=this.bytes%4294967296),this}},V.prototype.finalize=function(){if(!this.finalized){this.finalized=!0;var g=this.blocks,T=this.lastByteIndex;g[16]=this.block,g[T>>2]|=w[T&3],this.block=g[16],T>=56&&(this.hashed||this.hash(),g[0]=this.block,g[16]=g[1]=g[2]=g[3]=g[4]=g[5]=g[6]=g[7]=g[8]=g[9]=g[10]=g[11]=g[12]=g[13]=g[14]=g[15]=0),g[14]=this.hBytes<<3|this.bytes>>>29,g[15]=this.bytes<<3,this.hash()}},V.prototype.hash=function(){var g=this.h0,T=this.h1,U=this.h2,P=this.h3,v=this.h4,_=this.h5,z=this.h6,A=this.h7,W=this.blocks,te,ie,se,be,M,ke,a,d,m,C,y;for(te=16;te<64;++te)M=W[te-15],ie=(M>>>7|M<<25)^(M>>>18|M<<14)^M>>>3,M=W[te-2],se=(M>>>17|M<<15)^(M>>>19|M<<13)^M>>>10,W[te]=W[te-16]+ie+W[te-7]+se<<0;for(y=T&U,te=0;te<64;te+=4)this.first?(this.is224?(d=300032,M=W[0]-1413257819,A=M-150054599<<0,P=M+24177077<<0):(d=704751109,M=W[0]-210244248,A=M-1521486534<<0,P=M+143694565<<0),this.first=!1):(ie=(g>>>2|g<<30)^(g>>>13|g<<19)^(g>>>22|g<<10),se=(v>>>6|v<<26)^(v>>>11|v<<21)^(v>>>25|v<<7),d=g&T,be=d^g&U^y,a=v&_^~v&z,M=A+se+a+b[te]+W[te],ke=ie+be,A=P+M<<0,P=M+ke<<0),ie=(P>>>2|P<<30)^(P>>>13|P<<19)^(P>>>22|P<<10),se=(A>>>6|A<<26)^(A>>>11|A<<21)^(A>>>25|A<<7),m=P&g,be=m^P&T^d,a=A&v^~A&_,M=z+se+a+b[te+1]+W[te+1],ke=ie+be,z=U+M<<0,U=M+ke<<0,ie=(U>>>2|U<<30)^(U>>>13|U<<19)^(U>>>22|U<<10),se=(z>>>6|z<<26)^(z>>>11|z<<21)^(z>>>25|z<<7),C=U&P,be=C^U&g^m,a=z&A^~z&v,M=_+se+a+b[te+2]+W[te+2],ke=ie+be,_=T+M<<0,T=M+ke<<0,ie=(T>>>2|T<<30)^(T>>>13|T<<19)^(T>>>22|T<<10),se=(_>>>6|_<<26)^(_>>>11|_<<21)^(_>>>25|_<<7),y=T&U,be=y^T&P^C,a=_&z^~_&A,M=v+se+a+b[te+3]+W[te+3],ke=ie+be,v=g+M<<0,g=M+ke<<0,this.chromeBugWorkAround=!0;this.h0=this.h0+g<<0,this.h1=this.h1+T<<0,this.h2=this.h2+U<<0,this.h3=this.h3+P<<0,this.h4=this.h4+v<<0,this.h5=this.h5+_<<0,this.h6=this.h6+z<<0,this.h7=this.h7+A<<0},V.prototype.hex=function(){this.finalize();var g=this.h0,T=this.h1,U=this.h2,P=this.h3,v=this.h4,_=this.h5,z=this.h6,A=this.h7,W=u[g>>28&15]+u[g>>24&15]+u[g>>20&15]+u[g>>16&15]+u[g>>12&15]+u[g>>8&15]+u[g>>4&15]+u[g&15]+u[T>>28&15]+u[T>>24&15]+u[T>>20&15]+u[T>>16&15]+u[T>>12&15]+u[T>>8&15]+u[T>>4&15]+u[T&15]+u[U>>28&15]+u[U>>24&15]+u[U>>20&15]+u[U>>16&15]+u[U>>12&15]+u[U>>8&15]+u[U>>4&15]+u[U&15]+u[P>>28&15]+u[P>>24&15]+u[P>>20&15]+u[P>>16&15]+u[P>>12&15]+u[P>>8&15]+u[P>>4&15]+u[P&15]+u[v>>28&15]+u[v>>24&15]+u[v>>20&15]+u[v>>16&15]+u[v>>12&15]+u[v>>8&15]+u[v>>4&15]+u[v&15]+u[_>>28&15]+u[_>>24&15]+u[_>>20&15]+u[_>>16&15]+u[_>>12&15]+u[_>>8&15]+u[_>>4&15]+u[_&15]+u[z>>28&15]+u[z>>24&15]+u[z>>20&15]+u[z>>16&15]+u[z>>12&15]+u[z>>8&15]+u[z>>4&15]+u[z&15];return this.is224||(W+=u[A>>28&15]+u[A>>24&15]+u[A>>20&15]+u[A>>16&15]+u[A>>12&15]+u[A>>8&15]+u[A>>4&15]+u[A&15]),W},V.prototype.toString=V.prototype.hex,V.prototype.digest=function(){this.finalize();var g=this.h0,T=this.h1,U=this.h2,P=this.h3,v=this.h4,_=this.h5,z=this.h6,A=this.h7,W=[g>>24&255,g>>16&255,g>>8&255,g&255,T>>24&255,T>>16&255,T>>8&255,T&255,U>>24&255,U>>16&255,U>>8&255,U&255,P>>24&255,P>>16&255,P>>8&255,P&255,v>>24&255,v>>16&255,v>>8&255,v&255,_>>24&255,_>>16&255,_>>8&255,_&255,z>>24&255,z>>16&255,z>>8&255,z&255];return this.is224||W.push(A>>24&255,A>>16&255,A>>8&255,A&255),W},V.prototype.array=V.prototype.digest,V.prototype.arrayBuffer=function(){this.finalize();var g=new ArrayBuffer(this.is224?28:32),T=new DataView(g);return T.setUint32(0,this.h0),T.setUint32(4,this.h1),T.setUint32(8,this.h2),T.setUint32(12,this.h3),T.setUint32(16,this.h4),T.setUint32(20,this.h5),T.setUint32(24,this.h6),this.is224||T.setUint32(28,this.h7),g};function ye(g,T,U){var P,v=typeof g;if(v==="string"){var _=[],z=g.length,A=0,W;for(P=0;P<z;++P)W=g.charCodeAt(P),W<128?_[A++]=W:W<2048?(_[A++]=192|W>>6,_[A++]=128|W&63):W<55296||W>=57344?(_[A++]=224|W>>12,_[A++]=128|W>>6&63,_[A++]=128|W&63):(W=65536+((W&1023)<<10|g.charCodeAt(++P)&1023),_[A++]=240|W>>18,_[A++]=128|W>>12&63,_[A++]=128|W>>6&63,_[A++]=128|W&63);g=_}else if(v==="object"){if(g===null)throw new Error(e);if(f&&g.constructor===ArrayBuffer)g=new Uint8Array(g);else if(!Array.isArray(g)&&(!f||!ArrayBuffer.isView(g)))throw new Error(e)}else throw new Error(e);g.length>64&&(g=new V(T,!0).update(g).array());var te=[],ie=[];for(P=0;P<64;++P){var se=g[P]||0;te[P]=92^se,ie[P]=54^se}V.call(this,T,U),this.update(ie),this.oKeyPad=te,this.inner=!0,this.sharedMemory=U}ye.prototype=new V,ye.prototype.finalize=function(){if(V.prototype.finalize.call(this),this.inner){this.inner=!1;var g=this.array();V.call(this,this.is224,this.sharedMemory),this.update(this.oKeyPad),this.update(g),V.prototype.finalize.call(this)}};var ae=N();ae.sha256=ae,ae.sha224=N(!0),ae.sha256.hmac=oe(),ae.sha224.hmac=oe(!0),i?t.exports=ae:(o.sha256=ae.sha256,o.sha224=ae.sha224)})()})(Ar);var Ml=Ar.exports;const Dl=Tl(Ml);class It extends Error{}It.prototype.name="InvalidTokenError";function $l(t){return decodeURIComponent(atob(t).replace(/(.)/g,(e,n)=>{let o=n.charCodeAt(0).toString(16).toUpperCase();return o.length<2&&(o="0"+o),"%"+o}))}function Hl(t){let e=t.replace(/-/g,"+").replace(/_/g,"/");switch(e.length%4){case 0:break;case 2:e+="==";break;case 3:e+="=";break;default:throw new Error("base64 string is not of the correct length")}try{return $l(e)}catch{return atob(e)}}function jn(t,e){if(typeof t!="string")throw new It("Invalid token specified: must be a string");e||(e={});const n=e.header===!0?0:1,o=t.split(".")[n];if(typeof o!="string")throw new It(`Invalid token specified: missing part #${n+1}`);let r;try{r=Hl(o)}catch(s){throw new It(`Invalid token specified: invalid base64 for part #${n+1} (${s.message})`)}try{return JSON.parse(r)}catch(s){throw new It(`Invalid token specified: invalid json for part #${n+1} (${s.message})`)}}if(typeof Promise>"u")throw Error("Keycloak requires an environment that supports Promises. Make sure that you include the appropriate polyfill.");function Cr(t){if(!(this instanceof Cr))throw new Error("The 'Keycloak' constructor must be invoked with 'new'.");for(var e=this,n,o=[],r,s={enable:!0,callbackList:[],interval:5},i=document.getElementsByTagName("script"),f=0;f<i.length;f++)(i[f].src.indexOf("keycloak.js")!==-1||i[f].src.indexOf("keycloak.min.js")!==-1)&&i[f].src.indexOf("version=")!==-1&&(e.iframeVersion=i[f].src.substring(i[f].src.indexOf("version=")+8).split("&")[0]);var u=!0,w=ke(console.info),E=ke(console.warn);e.init=function(a){if(e.didInitialize)throw new Error("A 'Keycloak' instance can only be initialized once.");e.didInitialize=!0,e.authenticated=!1,r=M();var d=["default","cordova","cordova-native"];if(a&&d.indexOf(a.adapter)>-1?n=ie(a.adapter):a&&typeof a.adapter=="object"?n=a.adapter:window.Cordova||window.cordova?n=ie("cordova"):n=ie(),a){if(typeof a.useNonce<"u"&&(u=a.useNonce),typeof a.checkLoginIframe<"u"&&(s.enable=a.checkLoginIframe),a.checkLoginIframeInterval&&(s.interval=a.checkLoginIframeInterval),a.onLoad==="login-required"&&(e.loginRequired=!0),a.responseMode)if(a.responseMode==="query"||a.responseMode==="fragment")e.responseMode=a.responseMode;else throw"Invalid value for responseMode";if(a.flow){switch(a.flow){case"standard":e.responseType="code";break;case"implicit":e.responseType="id_token token";break;case"hybrid":e.responseType="code id_token token";break;default:throw"Invalid value for flow"}e.flow=a.flow}if(a.timeSkew!=null&&(e.timeSkew=a.timeSkew),a.redirectUri&&(e.redirectUri=a.redirectUri),a.silentCheckSsoRedirectUri&&(e.silentCheckSsoRedirectUri=a.silentCheckSsoRedirectUri),typeof a.silentCheckSsoFallback=="boolean"?e.silentCheckSsoFallback=a.silentCheckSsoFallback:e.silentCheckSsoFallback=!0,a.pkceMethod){if(a.pkceMethod!=="S256")throw"Invalid value for pkceMethod";e.pkceMethod=a.pkceMethod}typeof a.enableLogging=="boolean"?e.enableLogging=a.enableLogging:e.enableLogging=!1,typeof a.scope=="string"&&(e.scope=a.scope),typeof a.acrValues=="string"&&(e.acrValues=a.acrValues),typeof a.messageReceiveTimeout=="number"&&a.messageReceiveTimeout>0?e.messageReceiveTimeout=a.messageReceiveTimeout:e.messageReceiveTimeout=1e4}e.responseMode||(e.responseMode="fragment"),e.responseType||(e.responseType="code",e.flow="standard");var m=v(),C=v();C.promise.then(function(){e.onReady&&e.onReady(e.authenticated),m.setSuccess(e.authenticated)}).catch(function(O){m.setError(O)});var y=V();function R(){var O=function(J){J||(H.prompt="none"),a&&a.locale&&(H.locale=a.locale),e.login(H).then(function(){C.setSuccess()}).catch(function(Ce){C.setError(Ce)})},L=function(){var J=document.createElement("iframe"),Ce=e.createLoginUrl({prompt:"none",redirectUri:e.silentCheckSsoRedirectUri});J.setAttribute("src",Ce),J.setAttribute("sandbox","allow-scripts allow-same-origin"),J.setAttribute("title","keycloak-silent-check-sso"),J.style.display="none",document.body.appendChild(J);var we=function(ue){if(!(ue.origin!==window.location.origin||J.contentWindow!==ue.source)){var je=T(ue.data);oe(je,C),document.body.removeChild(J),window.removeEventListener("message",we)}};window.addEventListener("message",we)},H={};switch(a.onLoad){case"check-sso":s.enable?z().then(function(){W().then(function(J){J?C.setSuccess():e.silentCheckSsoRedirectUri?L():O(!1)}).catch(function(J){C.setError(J)})}):e.silentCheckSsoRedirectUri?L():O(!1);break;case"login-required":O(!0);break;default:throw"Invalid value for onLoad"}}function k(){var O=T(window.location.href);if(O&&window.history.replaceState(window.history.state,null,O.newUrl),O&&O.valid)return z().then(function(){oe(O,C)}).catch(function(L){C.setError(L)});a?a.token&&a.refreshToken?(ae(a.token,a.refreshToken,a.idToken),s.enable?z().then(function(){W().then(function(L){L?(e.onAuthSuccess&&e.onAuthSuccess(),C.setSuccess(),A()):C.setSuccess()}).catch(function(L){C.setError(L)})}):e.updateToken(-1).then(function(){e.onAuthSuccess&&e.onAuthSuccess(),C.setSuccess()}).catch(function(L){e.onAuthError&&e.onAuthError(),a.onLoad?R():C.setError(L)})):a.onLoad?R():C.setSuccess():C.setSuccess()}function x(){var O=v(),L=function(){(document.readyState==="interactive"||document.readyState==="complete")&&(document.removeEventListener("readystatechange",L),O.setSuccess())};return document.addEventListener("readystatechange",L),L(),O.promise}return y.then(function(){x().then(te).then(k).catch(function(O){m.setError(O)})}),y.catch(function(O){m.setError(O)}),m.promise},e.login=function(a){return n.login(a)};function b(a){var d=null,m=window.crypto||window.msCrypto;if(m&&m.getRandomValues&&window.Uint8Array)return d=new Uint8Array(a),m.getRandomValues(d),d;d=new Array(a);for(var C=0;C<d.length;C++)d[C]=Math.floor(256*Math.random());return d}function j(a){return $(a,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789")}function $(a,d){for(var m=b(a),C=new Array(a),y=0;y<a;y++)C[y]=d.charCodeAt(m[y]%d.length);return String.fromCharCode.apply(null,C)}function B(a,d){switch(a){case"S256":var m=new Uint8Array(Dl.arrayBuffer(d)),C=Qt.fromByteArray(m).replace(/\+/g,"-").replace(/\//g,"_").replace(/\=/g,"");return C;default:throw"Invalid value for pkceMethod"}}function N(a){var d={id_token:{acr:a}};return JSON.stringify(d)}e.createLoginUrl=function(a){var d=g(),m=g(),C=n.redirectUri(a),y={state:d,nonce:m,redirectUri:encodeURIComponent(C)};a&&a.prompt&&(y.prompt=a.prompt);var R;a&&a.action=="register"?R=e.endpoints.register():R=e.endpoints.authorize();var k=a&&a.scope||e.scope;k?k.indexOf("openid")===-1&&(k="openid "+k):k="openid";var x=R+"?client_id="+encodeURIComponent(e.clientId)+"&redirect_uri="+encodeURIComponent(C)+"&state="+encodeURIComponent(d)+"&response_mode="+encodeURIComponent(e.responseMode)+"&response_type="+encodeURIComponent(e.responseType)+"&scope="+encodeURIComponent(k);if(u&&(x=x+"&nonce="+encodeURIComponent(m)),a&&a.prompt&&(x+="&prompt="+encodeURIComponent(a.prompt)),a&&a.maxAge&&(x+="&max_age="+encodeURIComponent(a.maxAge)),a&&a.loginHint&&(x+="&login_hint="+encodeURIComponent(a.loginHint)),a&&a.idpHint&&(x+="&kc_idp_hint="+encodeURIComponent(a.idpHint)),a&&a.action&&a.action!="register"&&(x+="&kc_action="+encodeURIComponent(a.action)),a&&a.locale&&(x+="&ui_locales="+encodeURIComponent(a.locale)),a&&a.acr){var O=N(a.acr);x+="&claims="+encodeURIComponent(O)}if((a&&a.acrValues||e.acrValues)&&(x+="&acr_values="+encodeURIComponent(a.acrValues||e.acrValues)),e.pkceMethod){var L=j(96);y.pkceCodeVerifier=L;var H=B(e.pkceMethod,L);x+="&code_challenge="+H,x+="&code_challenge_method="+e.pkceMethod}return r.add(y),x},e.logout=function(a){return n.logout(a)},e.createLogoutUrl=function(a){var d=e.endpoints.logout()+"?client_id="+encodeURIComponent(e.clientId)+"&post_logout_redirect_uri="+encodeURIComponent(n.redirectUri(a,!1));return e.idToken&&(d+="&id_token_hint="+encodeURIComponent(e.idToken)),d},e.register=function(a){return n.register(a)},e.createRegisterUrl=function(a){return a||(a={}),a.action="register",e.createLoginUrl(a)},e.createAccountUrl=function(a){var d=D(),m=void 0;return typeof d<"u"&&(m=d+"/account?referrer="+encodeURIComponent(e.clientId)+"&referrer_uri="+encodeURIComponent(n.redirectUri(a))),m},e.accountManagement=function(){return n.accountManagement()},e.hasRealmRole=function(a){var d=e.realmAccess;return!!d&&d.roles.indexOf(a)>=0},e.hasResourceRole=function(a,d){if(!e.resourceAccess)return!1;var m=e.resourceAccess[d||e.clientId];return!!m&&m.roles.indexOf(a)>=0},e.loadUserProfile=function(){var a=D()+"/account",d=new XMLHttpRequest;d.open("GET",a,!0),d.setRequestHeader("Accept","application/json"),d.setRequestHeader("Authorization","bearer "+e.token);var m=v();return d.onreadystatechange=function(){d.readyState==4&&(d.status==200?(e.profile=JSON.parse(d.responseText),m.setSuccess(e.profile)):m.setError())},d.send(),m.promise},e.loadUserInfo=function(){var a=e.endpoints.userinfo(),d=new XMLHttpRequest;d.open("GET",a,!0),d.setRequestHeader("Accept","application/json"),d.setRequestHeader("Authorization","bearer "+e.token);var m=v();return d.onreadystatechange=function(){d.readyState==4&&(d.status==200?(e.userInfo=JSON.parse(d.responseText),m.setSuccess(e.userInfo)):m.setError())},d.send(),m.promise},e.isTokenExpired=function(a){if(!e.tokenParsed||!e.refreshToken&&e.flow!="implicit")throw"Not authenticated";if(e.timeSkew==null)return w("[KEYCLOAK] Unable to determine if token is expired as timeskew is not set"),!0;var d=e.tokenParsed.exp-Math.ceil(new Date().getTime()/1e3)+e.timeSkew;if(a){if(isNaN(a))throw"Invalid minValidity";d-=a}return d<0},e.updateToken=function(a){var d=v();if(!e.refreshToken)return d.setError(),d.promise;a=a||5;var m=function(){var y=!1;if(a==-1?(y=!0,w("[KEYCLOAK] Refreshing token: forced refresh")):(!e.tokenParsed||e.isTokenExpired(a))&&(y=!0,w("[KEYCLOAK] Refreshing token: token expired")),!y)d.setSuccess(!1);else{var R="grant_type=refresh_token&refresh_token="+e.refreshToken,k=e.endpoints.token();if(o.push(d),o.length==1){var x=new XMLHttpRequest;x.open("POST",k,!0),x.setRequestHeader("Content-type","application/x-www-form-urlencoded"),x.withCredentials=!0,R+="&client_id="+encodeURIComponent(e.clientId);var O=new Date().getTime();x.onreadystatechange=function(){if(x.readyState==4)if(x.status==200){w("[KEYCLOAK] Token refreshed"),O=(O+new Date().getTime())/2;var L=JSON.parse(x.responseText);ae(L.access_token,L.refresh_token,L.id_token,O),e.onAuthRefreshSuccess&&e.onAuthRefreshSuccess();for(var H=o.pop();H!=null;H=o.pop())H.setSuccess(!0)}else{E("[KEYCLOAK] Failed to refresh token"),x.status==400&&e.clearToken(),e.onAuthRefreshError&&e.onAuthRefreshError();for(var H=o.pop();H!=null;H=o.pop())H.setError(!0)}},x.send(R)}}};if(s.enable){var C=W();C.then(function(){m()}).catch(function(y){d.setError(y)})}else m();return d.promise},e.clearToken=function(){e.token&&(ae(null,null,null),e.onAuthLogout&&e.onAuthLogout(),e.loginRequired&&e.login())},e.setToken=ae;function D(){if(typeof e.authServerUrl<"u")return e.authServerUrl.charAt(e.authServerUrl.length-1)=="/"?e.authServerUrl+"realms/"+encodeURIComponent(e.realm):e.authServerUrl+"/realms/"+encodeURIComponent(e.realm)}function ee(){return window.location.origin?window.location.origin:window.location.protocol+"//"+window.location.hostname+(window.location.port?":"+window.location.port:"")}function oe(a,d){var m=a.code,C=a.error,y=a.prompt,R=new Date().getTime();if(a.kc_action_status&&e.onActionUpdate&&e.onActionUpdate(a.kc_action_status),C){if(y!="none"){var k={error:C,error_description:a.error_description};e.onAuthError&&e.onAuthError(k),d&&d.setError(k)}else d&&d.setSuccess();return}else e.flow!="standard"&&(a.access_token||a.id_token)&&H(a.access_token,null,a.id_token,!0);if(e.flow!="implicit"&&m){var x="code="+m+"&grant_type=authorization_code",O=e.endpoints.token(),L=new XMLHttpRequest;L.open("POST",O,!0),L.setRequestHeader("Content-type","application/x-www-form-urlencoded"),x+="&client_id="+encodeURIComponent(e.clientId),x+="&redirect_uri="+a.redirectUri,a.pkceCodeVerifier&&(x+="&code_verifier="+a.pkceCodeVerifier),L.withCredentials=!0,L.onreadystatechange=function(){if(L.readyState==4)if(L.status==200){var J=JSON.parse(L.responseText);H(J.access_token,J.refresh_token,J.id_token,e.flow==="standard"),A()}else e.onAuthError&&e.onAuthError(),d&&d.setError()},L.send(x)}function H(J,Ce,we,ue){R=(R+new Date().getTime())/2,ae(J,Ce,we,R),u&&(e.tokenParsed&&e.tokenParsed.nonce!=a.storedNonce||e.refreshTokenParsed&&e.refreshTokenParsed.nonce!=a.storedNonce||e.idTokenParsed&&e.idTokenParsed.nonce!=a.storedNonce)?(w("[KEYCLOAK] Invalid nonce, clearing token"),e.clearToken(),d&&d.setError()):ue&&(e.onAuthSuccess&&e.onAuthSuccess(),d&&d.setSuccess())}}function V(a){var d=v(),m;t?typeof t=="string"&&(m=t):m=location.origin+"/keycloak.json";function C(L){L?e.endpoints={authorize:function(){return L.authorization_endpoint},token:function(){return L.token_endpoint},logout:function(){if(!L.end_session_endpoint)throw"Not supported by the OIDC server";return L.end_session_endpoint},checkSessionIframe:function(){if(!L.check_session_iframe)throw"Not supported by the OIDC server";return L.check_session_iframe},register:function(){throw'Redirection to "Register user" page not supported in standard OIDC mode'},userinfo:function(){if(!L.userinfo_endpoint)throw"Not supported by the OIDC server";return L.userinfo_endpoint}}:e.endpoints={authorize:function(){return D()+"/protocol/openid-connect/auth"},token:function(){return D()+"/protocol/openid-connect/token"},logout:function(){return D()+"/protocol/openid-connect/logout"},checkSessionIframe:function(){var H=D()+"/protocol/openid-connect/login-status-iframe.html";return e.iframeVersion&&(H=H+"?version="+e.iframeVersion),H},thirdPartyCookiesIframe:function(){var H=D()+"/protocol/openid-connect/3p-cookies/step1.html";return e.iframeVersion&&(H=H+"?version="+e.iframeVersion),H},register:function(){return D()+"/protocol/openid-connect/registrations"},userinfo:function(){return D()+"/protocol/openid-connect/userinfo"}}}if(m){var y=new XMLHttpRequest;y.open("GET",m,!0),y.setRequestHeader("Accept","application/json"),y.onreadystatechange=function(){if(y.readyState==4)if(y.status==200||ye(y)){var L=JSON.parse(y.responseText);e.authServerUrl=L["auth-server-url"],e.realm=L.realm,e.clientId=L.resource,C(null),d.setSuccess()}else d.setError()},y.send()}else{if(!t.clientId)throw"clientId missing";e.clientId=t.clientId;var R=t.oidcProvider;if(R)if(typeof R=="string"){var O;R.charAt(R.length-1)=="/"?O=R+".well-known/openid-configuration":O=R+"/.well-known/openid-configuration";var y=new XMLHttpRequest;y.open("GET",O,!0),y.setRequestHeader("Accept","application/json"),y.onreadystatechange=function(){if(y.readyState==4)if(y.status==200||ye(y)){var H=JSON.parse(y.responseText);C(H),d.setSuccess()}else d.setError()},y.send()}else C(R),d.setSuccess();else{if(!t.url){for(var k=document.getElementsByTagName("script"),x=0;x<k.length;x++)if(k[x].src.match(/.*keycloak\.js/)){t.url=k[x].src.substr(0,k[x].src.indexOf("/js/keycloak.js"));break}}if(!t.realm)throw"realm missing";e.authServerUrl=t.url,e.realm=t.realm,C(null),d.setSuccess()}}return d.promise}function ye(a){return a.status==0&&a.responseText&&a.responseURL.startsWith("file:")}function ae(a,d,m,C){if(e.tokenTimeoutHandle&&(clearTimeout(e.tokenTimeoutHandle),e.tokenTimeoutHandle=null),d?(e.refreshToken=d,e.refreshTokenParsed=jn(d)):(delete e.refreshToken,delete e.refreshTokenParsed),m?(e.idToken=m,e.idTokenParsed=jn(m)):(delete e.idToken,delete e.idTokenParsed),a){if(e.token=a,e.tokenParsed=jn(a),e.sessionId=e.tokenParsed.session_state,e.authenticated=!0,e.subject=e.tokenParsed.sub,e.realmAccess=e.tokenParsed.realm_access,e.resourceAccess=e.tokenParsed.resource_access,C&&(e.timeSkew=Math.floor(C/1e3)-e.tokenParsed.iat),e.timeSkew!=null&&(w("[KEYCLOAK] Estimated time difference between browser and server is "+e.timeSkew+" seconds"),e.onTokenExpired)){var y=(e.tokenParsed.exp-new Date().getTime()/1e3+e.timeSkew)*1e3;w("[KEYCLOAK] Token expires in "+Math.round(y/1e3)+" s"),y<=0?e.onTokenExpired():e.tokenTimeoutHandle=setTimeout(e.onTokenExpired,y)}}else delete e.token,delete e.tokenParsed,delete e.subject,delete e.realmAccess,delete e.resourceAccess,e.authenticated=!1}function g(){var a="0123456789abcdef",d=$(36,a).split("");d[14]="4",d[19]=a.substr(d[19]&3|8,1),d[8]=d[13]=d[18]=d[23]="-";var m=d.join("");return m}function T(a){var d=U(a);if(d){var m=r.get(d.state);return m&&(d.valid=!0,d.redirectUri=m.redirectUri,d.storedNonce=m.nonce,d.prompt=m.prompt,d.pkceCodeVerifier=m.pkceCodeVerifier),d}}function U(a){var d;switch(e.flow){case"standard":d=["code","state","session_state","kc_action_status","iss"];break;case"implicit":d=["access_token","token_type","id_token","state","session_state","expires_in","kc_action_status","iss"];break;case"hybrid":d=["access_token","token_type","id_token","code","state","session_state","expires_in","kc_action_status","iss"];break}d.push("error"),d.push("error_description"),d.push("error_uri");var m=a.indexOf("?"),C=a.indexOf("#"),y,R;if(e.responseMode==="query"&&m!==-1?(y=a.substring(0,m),R=P(a.substring(m+1,C!==-1?C:a.length),d),R.paramsString!==""&&(y+="?"+R.paramsString),C!==-1&&(y+=a.substring(C))):e.responseMode==="fragment"&&C!==-1&&(y=a.substring(0,C),R=P(a.substring(C+1),d),R.paramsString!==""&&(y+="#"+R.paramsString)),R&&R.oauthParams){if(e.flow==="standard"||e.flow==="hybrid"){if((R.oauthParams.code||R.oauthParams.error)&&R.oauthParams.state)return R.oauthParams.newUrl=y,R.oauthParams}else if(e.flow==="implicit"&&(R.oauthParams.access_token||R.oauthParams.error)&&R.oauthParams.state)return R.oauthParams.newUrl=y,R.oauthParams}}function P(a,d){for(var m=a.split("&"),C={paramsString:"",oauthParams:{}},y=0;y<m.length;y++){var R=m[y].indexOf("="),k=m[y].slice(0,R);d.indexOf(k)!==-1?C.oauthParams[k]=m[y].slice(R+1):(C.paramsString!==""&&(C.paramsString+="&"),C.paramsString+=m[y])}return C}function v(){var a={setSuccess:function(d){a.resolve(d)},setError:function(d){a.reject(d)}};return a.promise=new Promise(function(d,m){a.resolve=d,a.reject=m}),a}function _(a,d,m){var C=null,y=new Promise(function(R,k){C=setTimeout(function(){k({error:m||"Promise is not settled within timeout of "+d+"ms"})},d)});return Promise.race([a,y]).finally(function(){clearTimeout(C)})}function z(){var a=v();if(!s.enable||s.iframe)return a.setSuccess(),a.promise;var d=document.createElement("iframe");s.iframe=d,d.onload=function(){var y=e.endpoints.authorize();y.charAt(0)==="/"?s.iframeOrigin=ee():s.iframeOrigin=y.substring(0,y.indexOf("/",8)),a.setSuccess()};var m=e.endpoints.checkSessionIframe();d.setAttribute("src",m),d.setAttribute("sandbox","allow-scripts allow-same-origin"),d.setAttribute("title","keycloak-session-iframe"),d.style.display="none",document.body.appendChild(d);var C=function(y){if(!(y.origin!==s.iframeOrigin||s.iframe.contentWindow!==y.source)&&(y.data=="unchanged"||y.data=="changed"||y.data=="error")){y.data!="unchanged"&&e.clearToken();for(var R=s.callbackList.splice(0,s.callbackList.length),k=R.length-1;k>=0;--k){var x=R[k];y.data=="error"?x.setError():x.setSuccess(y.data=="unchanged")}}};return window.addEventListener("message",C,!1),a.promise}function A(){s.enable&&e.token&&setTimeout(function(){W().then(function(a){a&&A()})},s.interval*1e3)}function W(){var a=v();if(s.iframe&&s.iframeOrigin){var d=e.clientId+" "+(e.sessionId?e.sessionId:"");s.callbackList.push(a);var m=s.iframeOrigin;s.callbackList.length==1&&s.iframe.contentWindow.postMessage(d,m)}else a.setSuccess();return a.promise}function te(){var a=v();if(s.enable||e.silentCheckSsoRedirectUri){var d=document.createElement("iframe");d.setAttribute("src",e.endpoints.thirdPartyCookiesIframe()),d.setAttribute("sandbox","allow-scripts allow-same-origin"),d.setAttribute("title","keycloak-3p-check-iframe"),d.style.display="none",document.body.appendChild(d);var m=function(C){d.contentWindow===C.source&&(C.data!=="supported"&&C.data!=="unsupported"||(C.data==="unsupported"&&(E(`[KEYCLOAK] Your browser is blocking access to 3rd-party cookies, this means:
154
+ */(function(t){(function(){var e="input is invalid type",n=typeof window=="object",r=n?window:{};r.JS_SHA256_NO_WINDOW&&(n=!1);var o=!n&&typeof self=="object",i=!r.JS_SHA256_NO_NODE_JS&&typeof process=="object"&&process.versions&&process.versions.node;i?r=Sf:o&&(r=self);var s=!r.JS_SHA256_NO_COMMON_JS&&!0&&t.exports,c=!r.JS_SHA256_NO_ARRAY_BUFFER&&typeof ArrayBuffer<"u",a="0123456789abcdef".split(""),u=[-2147483648,8388608,32768,128],f=[24,16,8,0],p=[1116352408,1899447441,3049323471,3921009573,961987163,1508970993,2453635748,2870763221,3624381080,310598401,607225278,1426881987,1925078388,2162078206,2614888103,3248222580,3835390401,4022224774,264347078,604807628,770255983,1249150122,1555081692,1996064986,2554220882,2821834349,2952996808,3210313671,3336571891,3584528711,113926993,338241895,666307205,773529912,1294757372,1396182291,1695183700,1986661051,2177026350,2456956037,2730485921,2820302411,3259730800,3345764771,3516065817,3600352804,4094571909,275423344,430227734,506948616,659060556,883997877,958139571,1322822218,1537002063,1747873779,1955562222,2024104815,2227730452,2361852424,2428436474,2756734187,3204031479,3329325298],v=["hex","array","digest","arrayBuffer"],w=[];(r.JS_SHA256_NO_NODE_JS||!Array.isArray)&&(Array.isArray=function(y){return Object.prototype.toString.call(y)==="[object Array]"}),c&&(r.JS_SHA256_NO_ARRAY_BUFFER_IS_VIEW||!ArrayBuffer.isView)&&(ArrayBuffer.isView=function(y){return typeof y=="object"&&y.buffer&&y.buffer.constructor===ArrayBuffer});var C=function(y,L){return function(j){return new V(L,!0).update(j)[y]()}},x=function(y){var L=C("hex",y);i&&(L=_(L,y)),L.create=function(){return new V(y)},L.update=function(B){return L.create().update(B)};for(var j=0;j<v.length;++j){var R=v[j];L[R]=C(R,y)}return L},_=function(y,L){var j=Ii,R=Ii.Buffer,B=L?"sha224":"sha256",O;R.from&&!r.JS_SHA256_NO_BUFFER_FROM?O=R.from:O=function(A){return new R(A)};var W=function(A){if(typeof A=="string")return j.createHash(B).update(A,"utf8").digest("hex");if(A==null)throw new Error(e);return A.constructor===ArrayBuffer&&(A=new Uint8Array(A)),Array.isArray(A)||ArrayBuffer.isView(A)||A.constructor===R?j.createHash(B).update(O(A)).digest("hex"):y(A)};return W},$=function(y,L){return function(j,R){return new pe(j,L,!0).update(R)[y]()}},q=function(y){var L=$("hex",y);L.create=function(B){return new pe(B,y)},L.update=function(B,O){return L.create(B).update(O)};for(var j=0;j<v.length;++j){var R=v[j];L[R]=$(R,y)}return L};function V(y,L){L?(w[0]=w[16]=w[1]=w[2]=w[3]=w[4]=w[5]=w[6]=w[7]=w[8]=w[9]=w[10]=w[11]=w[12]=w[13]=w[14]=w[15]=0,this.blocks=w):this.blocks=[0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0],y?(this.h0=3238371032,this.h1=914150663,this.h2=812702999,this.h3=4144912697,this.h4=4290775857,this.h5=1750603025,this.h6=1694076839,this.h7=3204075428):(this.h0=1779033703,this.h1=3144134277,this.h2=1013904242,this.h3=2773480762,this.h4=1359893119,this.h5=2600822924,this.h6=528734635,this.h7=1541459225),this.block=this.start=this.bytes=this.hBytes=0,this.finalized=this.hashed=!1,this.first=!0,this.is224=y}V.prototype.update=function(y){if(!this.finalized){var L,j=typeof y;if(j!=="string"){if(j==="object"){if(y===null)throw new Error(e);if(c&&y.constructor===ArrayBuffer)y=new Uint8Array(y);else if(!Array.isArray(y)&&(!c||!ArrayBuffer.isView(y)))throw new Error(e)}else throw new Error(e);L=!0}for(var R,B=0,O,W=y.length,A=this.blocks;B<W;){if(this.hashed&&(this.hashed=!1,A[0]=this.block,A[16]=A[1]=A[2]=A[3]=A[4]=A[5]=A[6]=A[7]=A[8]=A[9]=A[10]=A[11]=A[12]=A[13]=A[14]=A[15]=0),L)for(O=this.start;B<W&&O<64;++B)A[O>>2]|=y[B]<<f[O++&3];else for(O=this.start;B<W&&O<64;++B)R=y.charCodeAt(B),R<128?A[O>>2]|=R<<f[O++&3]:R<2048?(A[O>>2]|=(192|R>>6)<<f[O++&3],A[O>>2]|=(128|R&63)<<f[O++&3]):R<55296||R>=57344?(A[O>>2]|=(224|R>>12)<<f[O++&3],A[O>>2]|=(128|R>>6&63)<<f[O++&3],A[O>>2]|=(128|R&63)<<f[O++&3]):(R=65536+((R&1023)<<10|y.charCodeAt(++B)&1023),A[O>>2]|=(240|R>>18)<<f[O++&3],A[O>>2]|=(128|R>>12&63)<<f[O++&3],A[O>>2]|=(128|R>>6&63)<<f[O++&3],A[O>>2]|=(128|R&63)<<f[O++&3]);this.lastByteIndex=O,this.bytes+=O-this.start,O>=64?(this.block=A[16],this.start=O-64,this.hash(),this.hashed=!0):this.start=O}return this.bytes>4294967295&&(this.hBytes+=this.bytes/4294967296<<0,this.bytes=this.bytes%4294967296),this}},V.prototype.finalize=function(){if(!this.finalized){this.finalized=!0;var y=this.blocks,L=this.lastByteIndex;y[16]=this.block,y[L>>2]|=u[L&3],this.block=y[16],L>=56&&(this.hashed||this.hash(),y[0]=this.block,y[16]=y[1]=y[2]=y[3]=y[4]=y[5]=y[6]=y[7]=y[8]=y[9]=y[10]=y[11]=y[12]=y[13]=y[14]=y[15]=0),y[14]=this.hBytes<<3|this.bytes>>>29,y[15]=this.bytes<<3,this.hash()}},V.prototype.hash=function(){var y=this.h0,L=this.h1,j=this.h2,R=this.h3,B=this.h4,O=this.h5,W=this.h6,A=this.h7,G=this.blocks,ie,ce,fe,_e,K,xe,d,h,E,I,S;for(ie=16;ie<64;++ie)K=G[ie-15],ce=(K>>>7|K<<25)^(K>>>18|K<<14)^K>>>3,K=G[ie-2],fe=(K>>>17|K<<15)^(K>>>19|K<<13)^K>>>10,G[ie]=G[ie-16]+ce+G[ie-7]+fe<<0;for(S=L&j,ie=0;ie<64;ie+=4)this.first?(this.is224?(h=300032,K=G[0]-1413257819,A=K-150054599<<0,R=K+24177077<<0):(h=704751109,K=G[0]-210244248,A=K-1521486534<<0,R=K+143694565<<0),this.first=!1):(ce=(y>>>2|y<<30)^(y>>>13|y<<19)^(y>>>22|y<<10),fe=(B>>>6|B<<26)^(B>>>11|B<<21)^(B>>>25|B<<7),h=y&L,_e=h^y&j^S,d=B&O^~B&W,K=A+fe+d+p[ie]+G[ie],xe=ce+_e,A=R+K<<0,R=K+xe<<0),ce=(R>>>2|R<<30)^(R>>>13|R<<19)^(R>>>22|R<<10),fe=(A>>>6|A<<26)^(A>>>11|A<<21)^(A>>>25|A<<7),E=R&y,_e=E^R&L^h,d=A&B^~A&O,K=W+fe+d+p[ie+1]+G[ie+1],xe=ce+_e,W=j+K<<0,j=K+xe<<0,ce=(j>>>2|j<<30)^(j>>>13|j<<19)^(j>>>22|j<<10),fe=(W>>>6|W<<26)^(W>>>11|W<<21)^(W>>>25|W<<7),I=j&R,_e=I^j&y^E,d=W&A^~W&B,K=O+fe+d+p[ie+2]+G[ie+2],xe=ce+_e,O=L+K<<0,L=K+xe<<0,ce=(L>>>2|L<<30)^(L>>>13|L<<19)^(L>>>22|L<<10),fe=(O>>>6|O<<26)^(O>>>11|O<<21)^(O>>>25|O<<7),S=L&j,_e=S^L&R^I,d=O&W^~O&A,K=B+fe+d+p[ie+3]+G[ie+3],xe=ce+_e,B=y+K<<0,y=K+xe<<0,this.chromeBugWorkAround=!0;this.h0=this.h0+y<<0,this.h1=this.h1+L<<0,this.h2=this.h2+j<<0,this.h3=this.h3+R<<0,this.h4=this.h4+B<<0,this.h5=this.h5+O<<0,this.h6=this.h6+W<<0,this.h7=this.h7+A<<0},V.prototype.hex=function(){this.finalize();var y=this.h0,L=this.h1,j=this.h2,R=this.h3,B=this.h4,O=this.h5,W=this.h6,A=this.h7,G=a[y>>28&15]+a[y>>24&15]+a[y>>20&15]+a[y>>16&15]+a[y>>12&15]+a[y>>8&15]+a[y>>4&15]+a[y&15]+a[L>>28&15]+a[L>>24&15]+a[L>>20&15]+a[L>>16&15]+a[L>>12&15]+a[L>>8&15]+a[L>>4&15]+a[L&15]+a[j>>28&15]+a[j>>24&15]+a[j>>20&15]+a[j>>16&15]+a[j>>12&15]+a[j>>8&15]+a[j>>4&15]+a[j&15]+a[R>>28&15]+a[R>>24&15]+a[R>>20&15]+a[R>>16&15]+a[R>>12&15]+a[R>>8&15]+a[R>>4&15]+a[R&15]+a[B>>28&15]+a[B>>24&15]+a[B>>20&15]+a[B>>16&15]+a[B>>12&15]+a[B>>8&15]+a[B>>4&15]+a[B&15]+a[O>>28&15]+a[O>>24&15]+a[O>>20&15]+a[O>>16&15]+a[O>>12&15]+a[O>>8&15]+a[O>>4&15]+a[O&15]+a[W>>28&15]+a[W>>24&15]+a[W>>20&15]+a[W>>16&15]+a[W>>12&15]+a[W>>8&15]+a[W>>4&15]+a[W&15];return this.is224||(G+=a[A>>28&15]+a[A>>24&15]+a[A>>20&15]+a[A>>16&15]+a[A>>12&15]+a[A>>8&15]+a[A>>4&15]+a[A&15]),G},V.prototype.toString=V.prototype.hex,V.prototype.digest=function(){this.finalize();var y=this.h0,L=this.h1,j=this.h2,R=this.h3,B=this.h4,O=this.h5,W=this.h6,A=this.h7,G=[y>>24&255,y>>16&255,y>>8&255,y&255,L>>24&255,L>>16&255,L>>8&255,L&255,j>>24&255,j>>16&255,j>>8&255,j&255,R>>24&255,R>>16&255,R>>8&255,R&255,B>>24&255,B>>16&255,B>>8&255,B&255,O>>24&255,O>>16&255,O>>8&255,O&255,W>>24&255,W>>16&255,W>>8&255,W&255];return this.is224||G.push(A>>24&255,A>>16&255,A>>8&255,A&255),G},V.prototype.array=V.prototype.digest,V.prototype.arrayBuffer=function(){this.finalize();var y=new ArrayBuffer(this.is224?28:32),L=new DataView(y);return L.setUint32(0,this.h0),L.setUint32(4,this.h1),L.setUint32(8,this.h2),L.setUint32(12,this.h3),L.setUint32(16,this.h4),L.setUint32(20,this.h5),L.setUint32(24,this.h6),this.is224||L.setUint32(28,this.h7),y};function pe(y,L,j){var R,B=typeof y;if(B==="string"){var O=[],W=y.length,A=0,G;for(R=0;R<W;++R)G=y.charCodeAt(R),G<128?O[A++]=G:G<2048?(O[A++]=192|G>>6,O[A++]=128|G&63):G<55296||G>=57344?(O[A++]=224|G>>12,O[A++]=128|G>>6&63,O[A++]=128|G&63):(G=65536+((G&1023)<<10|y.charCodeAt(++R)&1023),O[A++]=240|G>>18,O[A++]=128|G>>12&63,O[A++]=128|G>>6&63,O[A++]=128|G&63);y=O}else if(B==="object"){if(y===null)throw new Error(e);if(c&&y.constructor===ArrayBuffer)y=new Uint8Array(y);else if(!Array.isArray(y)&&(!c||!ArrayBuffer.isView(y)))throw new Error(e)}else throw new Error(e);y.length>64&&(y=new V(L,!0).update(y).array());var ie=[],ce=[];for(R=0;R<64;++R){var fe=y[R]||0;ie[R]=92^fe,ce[R]=54^fe}V.call(this,L,j),this.update(ce),this.oKeyPad=ie,this.inner=!0,this.sharedMemory=j}pe.prototype=new V,pe.prototype.finalize=function(){if(V.prototype.finalize.call(this),this.inner){this.inner=!1;var y=this.array();V.call(this,this.is224,this.sharedMemory),this.update(this.oKeyPad),this.update(y),V.prototype.finalize.call(this)}};var de=x();de.sha256=de,de.sha224=x(!0),de.sha256.hmac=q(),de.sha224.hmac=q(!0),s?t.exports=de:(r.sha256=de.sha256,r.sha224=de.sha224)})()})(xi);var Bf=xi.exports;const Rf=_f(Bf);class Gt extends Error{}Gt.prototype.name="InvalidTokenError";function Ff(t){return decodeURIComponent(atob(t).replace(/(.)/g,(e,n)=>{let r=n.charCodeAt(0).toString(16).toUpperCase();return r.length<2&&(r="0"+r),"%"+r}))}function $f(t){let e=t.replace(/-/g,"+").replace(/_/g,"/");switch(e.length%4){case 0:break;case 2:e+="==";break;case 3:e+="=";break;default:throw new Error("base64 string is not of the correct length")}try{return Ff(e)}catch{return atob(e)}}function vr(t,e){if(typeof t!="string")throw new Gt("Invalid token specified: must be a string");e||(e={});const n=e.header===!0?0:1,r=t.split(".")[n];if(typeof r!="string")throw new Gt(`Invalid token specified: missing part #${n+1}`);let o;try{o=$f(r)}catch(i){throw new Gt(`Invalid token specified: invalid base64 for part #${n+1} (${i.message})`)}try{return JSON.parse(o)}catch(i){throw new Gt(`Invalid token specified: invalid json for part #${n+1} (${i.message})`)}}if(typeof Promise>"u")throw Error("Keycloak requires an environment that supports Promises. Make sure that you include the appropriate polyfill.");function Pi(t){if(!(this instanceof Pi))throw new Error("The 'Keycloak' constructor must be invoked with 'new'.");for(var e=this,n,r=[],o,i={enable:!0,callbackList:[],interval:5},s=document.getElementsByTagName("script"),c=0;c<s.length;c++)(s[c].src.indexOf("keycloak.js")!==-1||s[c].src.indexOf("keycloak.min.js")!==-1)&&s[c].src.indexOf("version=")!==-1&&(e.iframeVersion=s[c].src.substring(s[c].src.indexOf("version=")+8).split("&")[0]);var a=!0,u=xe(console.info),f=xe(console.warn);e.init=function(d){if(e.didInitialize)throw new Error("A 'Keycloak' instance can only be initialized once.");e.didInitialize=!0,e.authenticated=!1,o=K();var h=["default","cordova","cordova-native"];if(d&&h.indexOf(d.adapter)>-1?n=ce(d.adapter):d&&typeof d.adapter=="object"?n=d.adapter:window.Cordova||window.cordova?n=ce("cordova"):n=ce(),d){if(typeof d.useNonce<"u"&&(a=d.useNonce),typeof d.checkLoginIframe<"u"&&(i.enable=d.checkLoginIframe),d.checkLoginIframeInterval&&(i.interval=d.checkLoginIframeInterval),d.onLoad==="login-required"&&(e.loginRequired=!0),d.responseMode)if(d.responseMode==="query"||d.responseMode==="fragment")e.responseMode=d.responseMode;else throw"Invalid value for responseMode";if(d.flow){switch(d.flow){case"standard":e.responseType="code";break;case"implicit":e.responseType="id_token token";break;case"hybrid":e.responseType="code id_token token";break;default:throw"Invalid value for flow"}e.flow=d.flow}if(d.timeSkew!=null&&(e.timeSkew=d.timeSkew),d.redirectUri&&(e.redirectUri=d.redirectUri),d.silentCheckSsoRedirectUri&&(e.silentCheckSsoRedirectUri=d.silentCheckSsoRedirectUri),typeof d.silentCheckSsoFallback=="boolean"?e.silentCheckSsoFallback=d.silentCheckSsoFallback:e.silentCheckSsoFallback=!0,d.pkceMethod){if(d.pkceMethod!=="S256")throw"Invalid value for pkceMethod";e.pkceMethod=d.pkceMethod}typeof d.enableLogging=="boolean"?e.enableLogging=d.enableLogging:e.enableLogging=!1,typeof d.scope=="string"&&(e.scope=d.scope),typeof d.acrValues=="string"&&(e.acrValues=d.acrValues),typeof d.messageReceiveTimeout=="number"&&d.messageReceiveTimeout>0?e.messageReceiveTimeout=d.messageReceiveTimeout:e.messageReceiveTimeout=1e4}e.responseMode||(e.responseMode="fragment"),e.responseType||(e.responseType="code",e.flow="standard");var E=B(),I=B();I.promise.then(function(){e.onReady&&e.onReady(e.authenticated),E.setSuccess(e.authenticated)}).catch(function(M){E.setError(M)});var S=V();function F(){var M=function(Q){Q||(z.prompt="none"),d&&d.locale&&(z.locale=d.locale),e.login(z).then(function(){I.setSuccess()}).catch(function(Ie){I.setError(Ie)})},N=function(){var Q=document.createElement("iframe"),Ie=e.createLoginUrl({prompt:"none",redirectUri:e.silentCheckSsoRedirectUri});Q.setAttribute("src",Ie),Q.setAttribute("sandbox","allow-scripts allow-same-origin"),Q.setAttribute("title","keycloak-silent-check-sso"),Q.style.display="none",document.body.appendChild(Q);var Ce=function(ge){if(!(ge.origin!==window.location.origin||Q.contentWindow!==ge.source)){var qe=L(ge.data);q(qe,I),document.body.removeChild(Q),window.removeEventListener("message",Ce)}};window.addEventListener("message",Ce)},z={};switch(d.onLoad){case"check-sso":i.enable?W().then(function(){G().then(function(Q){Q?I.setSuccess():e.silentCheckSsoRedirectUri?N():M(!1)}).catch(function(Q){I.setError(Q)})}):e.silentCheckSsoRedirectUri?N():M(!1);break;case"login-required":M(!0);break;default:throw"Invalid value for onLoad"}}function k(){var M=L(window.location.href);if(M&&window.history.replaceState(window.history.state,null,M.newUrl),M&&M.valid)return W().then(function(){q(M,I)}).catch(function(N){I.setError(N)});d?d.token&&d.refreshToken?(de(d.token,d.refreshToken,d.idToken),i.enable?W().then(function(){G().then(function(N){N?(e.onAuthSuccess&&e.onAuthSuccess(),I.setSuccess(),A()):I.setSuccess()}).catch(function(N){I.setError(N)})}):e.updateToken(-1).then(function(){e.onAuthSuccess&&e.onAuthSuccess(),I.setSuccess()}).catch(function(N){e.onAuthError&&e.onAuthError(),d.onLoad?F():I.setError(N)})):d.onLoad?F():I.setSuccess():I.setSuccess()}function P(){var M=B(),N=function(){(document.readyState==="interactive"||document.readyState==="complete")&&(document.removeEventListener("readystatechange",N),M.setSuccess())};return document.addEventListener("readystatechange",N),N(),M.promise}return S.then(function(){P().then(ie).then(k).catch(function(M){E.setError(M)})}),S.catch(function(M){E.setError(M)}),E.promise},e.login=function(d){return n.login(d)};function p(d){var h=null,E=window.crypto||window.msCrypto;if(E&&E.getRandomValues&&window.Uint8Array)return h=new Uint8Array(d),E.getRandomValues(h),h;h=new Array(d);for(var I=0;I<h.length;I++)h[I]=Math.floor(256*Math.random());return h}function v(d){return w(d,"ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789")}function w(d,h){for(var E=p(d),I=new Array(d),S=0;S<d;S++)I[S]=h.charCodeAt(E[S]%h.length);return String.fromCharCode.apply(null,I)}function C(d,h){switch(d){case"S256":var E=new Uint8Array(Rf.arrayBuffer(h)),I=bn.fromByteArray(E).replace(/\+/g,"-").replace(/\//g,"_").replace(/\=/g,"");return I;default:throw"Invalid value for pkceMethod"}}function x(d){var h={id_token:{acr:d}};return JSON.stringify(h)}e.createLoginUrl=function(d){var h=y(),E=y(),I=n.redirectUri(d),S={state:h,nonce:E,redirectUri:encodeURIComponent(I)};d&&d.prompt&&(S.prompt=d.prompt);var F;d&&d.action=="register"?F=e.endpoints.register():F=e.endpoints.authorize();var k=d&&d.scope||e.scope;k?k.indexOf("openid")===-1&&(k="openid "+k):k="openid";var P=F+"?client_id="+encodeURIComponent(e.clientId)+"&redirect_uri="+encodeURIComponent(I)+"&state="+encodeURIComponent(h)+"&response_mode="+encodeURIComponent(e.responseMode)+"&response_type="+encodeURIComponent(e.responseType)+"&scope="+encodeURIComponent(k);if(a&&(P=P+"&nonce="+encodeURIComponent(E)),d&&d.prompt&&(P+="&prompt="+encodeURIComponent(d.prompt)),d&&d.maxAge&&(P+="&max_age="+encodeURIComponent(d.maxAge)),d&&d.loginHint&&(P+="&login_hint="+encodeURIComponent(d.loginHint)),d&&d.idpHint&&(P+="&kc_idp_hint="+encodeURIComponent(d.idpHint)),d&&d.action&&d.action!="register"&&(P+="&kc_action="+encodeURIComponent(d.action)),d&&d.locale&&(P+="&ui_locales="+encodeURIComponent(d.locale)),d&&d.acr){var M=x(d.acr);P+="&claims="+encodeURIComponent(M)}if((d&&d.acrValues||e.acrValues)&&(P+="&acr_values="+encodeURIComponent(d.acrValues||e.acrValues)),e.pkceMethod){var N=v(96);S.pkceCodeVerifier=N;var z=C(e.pkceMethod,N);P+="&code_challenge="+z,P+="&code_challenge_method="+e.pkceMethod}return o.add(S),P},e.logout=function(d){return n.logout(d)},e.createLogoutUrl=function(d){var h=e.endpoints.logout()+"?client_id="+encodeURIComponent(e.clientId)+"&post_logout_redirect_uri="+encodeURIComponent(n.redirectUri(d,!1));return e.idToken&&(h+="&id_token_hint="+encodeURIComponent(e.idToken)),h},e.register=function(d){return n.register(d)},e.createRegisterUrl=function(d){return d||(d={}),d.action="register",e.createLoginUrl(d)},e.createAccountUrl=function(d){var h=_(),E=void 0;return typeof h<"u"&&(E=h+"/account?referrer="+encodeURIComponent(e.clientId)+"&referrer_uri="+encodeURIComponent(n.redirectUri(d))),E},e.accountManagement=function(){return n.accountManagement()},e.hasRealmRole=function(d){var h=e.realmAccess;return!!h&&h.roles.indexOf(d)>=0},e.hasResourceRole=function(d,h){if(!e.resourceAccess)return!1;var E=e.resourceAccess[h||e.clientId];return!!E&&E.roles.indexOf(d)>=0},e.loadUserProfile=function(){var d=_()+"/account",h=new XMLHttpRequest;h.open("GET",d,!0),h.setRequestHeader("Accept","application/json"),h.setRequestHeader("Authorization","bearer "+e.token);var E=B();return h.onreadystatechange=function(){h.readyState==4&&(h.status==200?(e.profile=JSON.parse(h.responseText),E.setSuccess(e.profile)):E.setError())},h.send(),E.promise},e.loadUserInfo=function(){var d=e.endpoints.userinfo(),h=new XMLHttpRequest;h.open("GET",d,!0),h.setRequestHeader("Accept","application/json"),h.setRequestHeader("Authorization","bearer "+e.token);var E=B();return h.onreadystatechange=function(){h.readyState==4&&(h.status==200?(e.userInfo=JSON.parse(h.responseText),E.setSuccess(e.userInfo)):E.setError())},h.send(),E.promise},e.isTokenExpired=function(d){if(!e.tokenParsed||!e.refreshToken&&e.flow!="implicit")throw"Not authenticated";if(e.timeSkew==null)return u("[KEYCLOAK] Unable to determine if token is expired as timeskew is not set"),!0;var h=e.tokenParsed.exp-Math.ceil(new Date().getTime()/1e3)+e.timeSkew;if(d){if(isNaN(d))throw"Invalid minValidity";h-=d}return h<0},e.updateToken=function(d){var h=B();if(!e.refreshToken)return h.setError(),h.promise;d=d||5;var E=function(){var S=!1;if(d==-1?(S=!0,u("[KEYCLOAK] Refreshing token: forced refresh")):(!e.tokenParsed||e.isTokenExpired(d))&&(S=!0,u("[KEYCLOAK] Refreshing token: token expired")),!S)h.setSuccess(!1);else{var F="grant_type=refresh_token&refresh_token="+e.refreshToken,k=e.endpoints.token();if(r.push(h),r.length==1){var P=new XMLHttpRequest;P.open("POST",k,!0),P.setRequestHeader("Content-type","application/x-www-form-urlencoded"),P.withCredentials=!0,F+="&client_id="+encodeURIComponent(e.clientId);var M=new Date().getTime();P.onreadystatechange=function(){if(P.readyState==4)if(P.status==200){u("[KEYCLOAK] Token refreshed"),M=(M+new Date().getTime())/2;var N=JSON.parse(P.responseText);de(N.access_token,N.refresh_token,N.id_token,M),e.onAuthRefreshSuccess&&e.onAuthRefreshSuccess();for(var z=r.pop();z!=null;z=r.pop())z.setSuccess(!0)}else{f("[KEYCLOAK] Failed to refresh token"),P.status==400&&e.clearToken(),e.onAuthRefreshError&&e.onAuthRefreshError();for(var z=r.pop();z!=null;z=r.pop())z.setError(!0)}},P.send(F)}}};if(i.enable){var I=G();I.then(function(){E()}).catch(function(S){h.setError(S)})}else E();return h.promise},e.clearToken=function(){e.token&&(de(null,null,null),e.onAuthLogout&&e.onAuthLogout(),e.loginRequired&&e.login())},e.setToken=de;function _(){if(typeof e.authServerUrl<"u")return e.authServerUrl.charAt(e.authServerUrl.length-1)=="/"?e.authServerUrl+"realms/"+encodeURIComponent(e.realm):e.authServerUrl+"/realms/"+encodeURIComponent(e.realm)}function $(){return window.location.origin?window.location.origin:window.location.protocol+"//"+window.location.hostname+(window.location.port?":"+window.location.port:"")}function q(d,h){var E=d.code,I=d.error,S=d.prompt,F=new Date().getTime();if(d.kc_action_status&&e.onActionUpdate&&e.onActionUpdate(d.kc_action_status),I){if(S!="none"){var k={error:I,error_description:d.error_description};e.onAuthError&&e.onAuthError(k),h&&h.setError(k)}else h&&h.setSuccess();return}else e.flow!="standard"&&(d.access_token||d.id_token)&&z(d.access_token,null,d.id_token,!0);if(e.flow!="implicit"&&E){var P="code="+E+"&grant_type=authorization_code",M=e.endpoints.token(),N=new XMLHttpRequest;N.open("POST",M,!0),N.setRequestHeader("Content-type","application/x-www-form-urlencoded"),P+="&client_id="+encodeURIComponent(e.clientId),P+="&redirect_uri="+d.redirectUri,d.pkceCodeVerifier&&(P+="&code_verifier="+d.pkceCodeVerifier),N.withCredentials=!0,N.onreadystatechange=function(){if(N.readyState==4)if(N.status==200){var Q=JSON.parse(N.responseText);z(Q.access_token,Q.refresh_token,Q.id_token,e.flow==="standard"),A()}else e.onAuthError&&e.onAuthError(),h&&h.setError()},N.send(P)}function z(Q,Ie,Ce,ge){F=(F+new Date().getTime())/2,de(Q,Ie,Ce,F),a&&(e.tokenParsed&&e.tokenParsed.nonce!=d.storedNonce||e.refreshTokenParsed&&e.refreshTokenParsed.nonce!=d.storedNonce||e.idTokenParsed&&e.idTokenParsed.nonce!=d.storedNonce)?(u("[KEYCLOAK] Invalid nonce, clearing token"),e.clearToken(),h&&h.setError()):ge&&(e.onAuthSuccess&&e.onAuthSuccess(),h&&h.setSuccess())}}function V(d){var h=B(),E;t?typeof t=="string"&&(E=t):E=location.origin+"/keycloak.json";function I(N){N?e.endpoints={authorize:function(){return N.authorization_endpoint},token:function(){return N.token_endpoint},logout:function(){if(!N.end_session_endpoint)throw"Not supported by the OIDC server";return N.end_session_endpoint},checkSessionIframe:function(){if(!N.check_session_iframe)throw"Not supported by the OIDC server";return N.check_session_iframe},register:function(){throw'Redirection to "Register user" page not supported in standard OIDC mode'},userinfo:function(){if(!N.userinfo_endpoint)throw"Not supported by the OIDC server";return N.userinfo_endpoint}}:e.endpoints={authorize:function(){return _()+"/protocol/openid-connect/auth"},token:function(){return _()+"/protocol/openid-connect/token"},logout:function(){return _()+"/protocol/openid-connect/logout"},checkSessionIframe:function(){var z=_()+"/protocol/openid-connect/login-status-iframe.html";return e.iframeVersion&&(z=z+"?version="+e.iframeVersion),z},thirdPartyCookiesIframe:function(){var z=_()+"/protocol/openid-connect/3p-cookies/step1.html";return e.iframeVersion&&(z=z+"?version="+e.iframeVersion),z},register:function(){return _()+"/protocol/openid-connect/registrations"},userinfo:function(){return _()+"/protocol/openid-connect/userinfo"}}}if(E){var S=new XMLHttpRequest;S.open("GET",E,!0),S.setRequestHeader("Accept","application/json"),S.onreadystatechange=function(){if(S.readyState==4)if(S.status==200||pe(S)){var N=JSON.parse(S.responseText);e.authServerUrl=N["auth-server-url"],e.realm=N.realm,e.clientId=N.resource,I(null),h.setSuccess()}else h.setError()},S.send()}else{if(!t.clientId)throw"clientId missing";e.clientId=t.clientId;var F=t.oidcProvider;if(F)if(typeof F=="string"){var M;F.charAt(F.length-1)=="/"?M=F+".well-known/openid-configuration":M=F+"/.well-known/openid-configuration";var S=new XMLHttpRequest;S.open("GET",M,!0),S.setRequestHeader("Accept","application/json"),S.onreadystatechange=function(){if(S.readyState==4)if(S.status==200||pe(S)){var z=JSON.parse(S.responseText);I(z),h.setSuccess()}else h.setError()},S.send()}else I(F),h.setSuccess();else{if(!t.url){for(var k=document.getElementsByTagName("script"),P=0;P<k.length;P++)if(k[P].src.match(/.*keycloak\.js/)){t.url=k[P].src.substr(0,k[P].src.indexOf("/js/keycloak.js"));break}}if(!t.realm)throw"realm missing";e.authServerUrl=t.url,e.realm=t.realm,I(null),h.setSuccess()}}return h.promise}function pe(d){return d.status==0&&d.responseText&&d.responseURL.startsWith("file:")}function de(d,h,E,I){if(e.tokenTimeoutHandle&&(clearTimeout(e.tokenTimeoutHandle),e.tokenTimeoutHandle=null),h?(e.refreshToken=h,e.refreshTokenParsed=vr(h)):(delete e.refreshToken,delete e.refreshTokenParsed),E?(e.idToken=E,e.idTokenParsed=vr(E)):(delete e.idToken,delete e.idTokenParsed),d){if(e.token=d,e.tokenParsed=vr(d),e.sessionId=e.tokenParsed.session_state,e.authenticated=!0,e.subject=e.tokenParsed.sub,e.realmAccess=e.tokenParsed.realm_access,e.resourceAccess=e.tokenParsed.resource_access,I&&(e.timeSkew=Math.floor(I/1e3)-e.tokenParsed.iat),e.timeSkew!=null&&(u("[KEYCLOAK] Estimated time difference between browser and server is "+e.timeSkew+" seconds"),e.onTokenExpired)){var S=(e.tokenParsed.exp-new Date().getTime()/1e3+e.timeSkew)*1e3;u("[KEYCLOAK] Token expires in "+Math.round(S/1e3)+" s"),S<=0?e.onTokenExpired():e.tokenTimeoutHandle=setTimeout(e.onTokenExpired,S)}}else delete e.token,delete e.tokenParsed,delete e.subject,delete e.realmAccess,delete e.resourceAccess,e.authenticated=!1}function y(){var d="0123456789abcdef",h=w(36,d).split("");h[14]="4",h[19]=d.substr(h[19]&3|8,1),h[8]=h[13]=h[18]=h[23]="-";var E=h.join("");return E}function L(d){var h=j(d);if(h){var E=o.get(h.state);return E&&(h.valid=!0,h.redirectUri=E.redirectUri,h.storedNonce=E.nonce,h.prompt=E.prompt,h.pkceCodeVerifier=E.pkceCodeVerifier),h}}function j(d){var h;switch(e.flow){case"standard":h=["code","state","session_state","kc_action_status","iss"];break;case"implicit":h=["access_token","token_type","id_token","state","session_state","expires_in","kc_action_status","iss"];break;case"hybrid":h=["access_token","token_type","id_token","code","state","session_state","expires_in","kc_action_status","iss"];break}h.push("error"),h.push("error_description"),h.push("error_uri");var E=d.indexOf("?"),I=d.indexOf("#"),S,F;if(e.responseMode==="query"&&E!==-1?(S=d.substring(0,E),F=R(d.substring(E+1,I!==-1?I:d.length),h),F.paramsString!==""&&(S+="?"+F.paramsString),I!==-1&&(S+=d.substring(I))):e.responseMode==="fragment"&&I!==-1&&(S=d.substring(0,I),F=R(d.substring(I+1),h),F.paramsString!==""&&(S+="#"+F.paramsString)),F&&F.oauthParams){if(e.flow==="standard"||e.flow==="hybrid"){if((F.oauthParams.code||F.oauthParams.error)&&F.oauthParams.state)return F.oauthParams.newUrl=S,F.oauthParams}else if(e.flow==="implicit"&&(F.oauthParams.access_token||F.oauthParams.error)&&F.oauthParams.state)return F.oauthParams.newUrl=S,F.oauthParams}}function R(d,h){for(var E=d.split("&"),I={paramsString:"",oauthParams:{}},S=0;S<E.length;S++){var F=E[S].indexOf("="),k=E[S].slice(0,F);h.indexOf(k)!==-1?I.oauthParams[k]=E[S].slice(F+1):(I.paramsString!==""&&(I.paramsString+="&"),I.paramsString+=E[S])}return I}function B(){var d={setSuccess:function(h){d.resolve(h)},setError:function(h){d.reject(h)}};return d.promise=new Promise(function(h,E){d.resolve=h,d.reject=E}),d}function O(d,h,E){var I=null,S=new Promise(function(F,k){I=setTimeout(function(){k({error:E||"Promise is not settled within timeout of "+h+"ms"})},h)});return Promise.race([d,S]).finally(function(){clearTimeout(I)})}function W(){var d=B();if(!i.enable||i.iframe)return d.setSuccess(),d.promise;var h=document.createElement("iframe");i.iframe=h,h.onload=function(){var S=e.endpoints.authorize();S.charAt(0)==="/"?i.iframeOrigin=$():i.iframeOrigin=S.substring(0,S.indexOf("/",8)),d.setSuccess()};var E=e.endpoints.checkSessionIframe();h.setAttribute("src",E),h.setAttribute("sandbox","allow-scripts allow-same-origin"),h.setAttribute("title","keycloak-session-iframe"),h.style.display="none",document.body.appendChild(h);var I=function(S){if(!(S.origin!==i.iframeOrigin||i.iframe.contentWindow!==S.source)&&(S.data=="unchanged"||S.data=="changed"||S.data=="error")){S.data!="unchanged"&&e.clearToken();for(var F=i.callbackList.splice(0,i.callbackList.length),k=F.length-1;k>=0;--k){var P=F[k];S.data=="error"?P.setError():P.setSuccess(S.data=="unchanged")}}};return window.addEventListener("message",I,!1),d.promise}function A(){i.enable&&e.token&&setTimeout(function(){G().then(function(d){d&&A()})},i.interval*1e3)}function G(){var d=B();if(i.iframe&&i.iframeOrigin){var h=e.clientId+" "+(e.sessionId?e.sessionId:"");i.callbackList.push(d);var E=i.iframeOrigin;i.callbackList.length==1&&i.iframe.contentWindow.postMessage(h,E)}else d.setSuccess();return d.promise}function ie(){var d=B();if(i.enable||e.silentCheckSsoRedirectUri){var h=document.createElement("iframe");h.setAttribute("src",e.endpoints.thirdPartyCookiesIframe()),h.setAttribute("sandbox","allow-scripts allow-same-origin"),h.setAttribute("title","keycloak-3p-check-iframe"),h.style.display="none",document.body.appendChild(h);var E=function(I){h.contentWindow===I.source&&(I.data!=="supported"&&I.data!=="unsupported"||(I.data==="unsupported"&&(f(`[KEYCLOAK] Your browser is blocking access to 3rd-party cookies, this means:
73
155
 
74
156
  - It is not possible to retrieve tokens without redirecting to the Keycloak server (a.k.a. no support for silent authentication).
75
157
  - It is not possible to automatically detect changes to the session status (such as the user logging out in another tab).
76
158
 
77
- For more information see: https://www.keycloak.org/docs/latest/securing_apps/#_modern_browsers`),s.enable=!1,e.silentCheckSsoFallback&&(e.silentCheckSsoRedirectUri=!1)),document.body.removeChild(d),window.removeEventListener("message",m),a.setSuccess()))};window.addEventListener("message",m,!1)}else a.setSuccess();return _(a.promise,e.messageReceiveTimeout,"Timeout when waiting for 3rd party check iframe message.")}function ie(a){if(!a||a=="default")return{login:function(k){return window.location.assign(e.createLoginUrl(k)),v().promise},logout:function(k){return window.location.replace(e.createLogoutUrl(k)),v().promise},register:function(k){return window.location.assign(e.createRegisterUrl(k)),v().promise},accountManagement:function(){var k=e.createAccountUrl();if(typeof k<"u")window.location.href=k;else throw"Not supported by the OIDC server";return v().promise},redirectUri:function(k,x){return k&&k.redirectUri?k.redirectUri:e.redirectUri?e.redirectUri:location.href}};if(a=="cordova"){s.enable=!1;var d=function(k,x,O){return window.cordova&&window.cordova.InAppBrowser?window.cordova.InAppBrowser.open(k,x,O):window.open(k,x,O)},m=function(k){return k&&k.cordovaOptions?Object.keys(k.cordovaOptions).reduce(function(x,O){return x[O]=k.cordovaOptions[O],x},{}):{}},C=function(k){return Object.keys(k).reduce(function(x,O){return x.push(O+"="+k[O]),x},[]).join(",")},y=function(k){var x=m(k);return x.location="no",k&&k.prompt=="none"&&(x.hidden="yes"),C(x)},R=function(){return e.redirectUri||"http://localhost"};return{login:function(k){var x=v(),O=y(k),L=e.createLoginUrl(k),H=d(L,"_blank",O),J=!1,Ce=!1,we=function(){Ce=!0,H.close()};return H.addEventListener("loadstart",function(ue){if(ue.url.indexOf(R())==0){var je=T(ue.url);oe(je,x),we(),J=!0}}),H.addEventListener("loaderror",function(ue){if(!J)if(ue.url.indexOf(R())==0){var je=T(ue.url);oe(je,x),we(),J=!0}else x.setError(),we()}),H.addEventListener("exit",function(ue){Ce||x.setError({reason:"closed_by_user"})}),x.promise},logout:function(k){var x=v(),O=e.createLogoutUrl(k),L=d(O,"_blank","location=no,hidden=yes,clearcache=yes"),H;return L.addEventListener("loadstart",function(J){J.url.indexOf(R())==0&&L.close()}),L.addEventListener("loaderror",function(J){J.url.indexOf(R())==0||(H=!0),L.close()}),L.addEventListener("exit",function(J){H?x.setError():(e.clearToken(),x.setSuccess())}),x.promise},register:function(k){var x=v(),O=e.createRegisterUrl(),L=y(k),H=d(O,"_blank",L);return H.addEventListener("loadstart",function(J){if(J.url.indexOf(R())==0){H.close();var Ce=T(J.url);oe(Ce,x)}}),x.promise},accountManagement:function(){var k=e.createAccountUrl();if(typeof k<"u"){var x=d(k,"_blank","location=no");x.addEventListener("loadstart",function(O){O.url.indexOf(R())==0&&x.close()})}else throw"Not supported by the OIDC server"},redirectUri:function(k){return R()}}}if(a=="cordova-native")return s.enable=!1,{login:function(k){var x=v(),O=e.createLoginUrl(k);return universalLinks.subscribe("keycloak",function(L){universalLinks.unsubscribe("keycloak"),window.cordova.plugins.browsertab.close();var H=T(L.url);oe(H,x)}),window.cordova.plugins.browsertab.openUrl(O),x.promise},logout:function(k){var x=v(),O=e.createLogoutUrl(k);return universalLinks.subscribe("keycloak",function(L){universalLinks.unsubscribe("keycloak"),window.cordova.plugins.browsertab.close(),e.clearToken(),x.setSuccess()}),window.cordova.plugins.browsertab.openUrl(O),x.promise},register:function(k){var x=v(),O=e.createRegisterUrl(k);return universalLinks.subscribe("keycloak",function(L){universalLinks.unsubscribe("keycloak"),window.cordova.plugins.browsertab.close();var H=T(L.url);oe(H,x)}),window.cordova.plugins.browsertab.openUrl(O),x.promise},accountManagement:function(){var k=e.createAccountUrl();if(typeof k<"u")window.cordova.plugins.browsertab.openUrl(k);else throw"Not supported by the OIDC server"},redirectUri:function(k){return k&&k.redirectUri?k.redirectUri:e.redirectUri?e.redirectUri:"http://localhost"}};throw"invalid adapter type: "+a}var se=function(){if(!(this instanceof se))return new se;localStorage.setItem("kc-test","test"),localStorage.removeItem("kc-test");var a=this;function d(){for(var m=new Date().getTime(),C=0;C<localStorage.length;C++){var y=localStorage.key(C);if(y&&y.indexOf("kc-callback-")==0){var R=localStorage.getItem(y);if(R)try{var k=JSON.parse(R).expires;(!k||k<m)&&localStorage.removeItem(y)}catch{localStorage.removeItem(y)}}}}a.get=function(m){if(m){var C="kc-callback-"+m,y=localStorage.getItem(C);return y&&(localStorage.removeItem(C),y=JSON.parse(y)),d(),y}},a.add=function(m){d();var C="kc-callback-"+m.state;m.expires=new Date().getTime()+60*60*1e3,localStorage.setItem(C,JSON.stringify(m))}},be=function(){if(!(this instanceof be))return new be;var a=this;a.get=function(y){if(y){var R=m("kc-callback-"+y);if(C("kc-callback-"+y,"",d(-100)),R)return JSON.parse(R)}},a.add=function(y){C("kc-callback-"+y.state,JSON.stringify(y),d(60))},a.removeItem=function(y){C(y,"",d(-100))};var d=function(y){var R=new Date;return R.setTime(R.getTime()+y*60*1e3),R},m=function(y){for(var R=y+"=",k=document.cookie.split(";"),x=0;x<k.length;x++){for(var O=k[x];O.charAt(0)==" ";)O=O.substring(1);if(O.indexOf(R)==0)return O.substring(R.length,O.length)}return""},C=function(y,R,k){var x=y+"="+R+"; expires="+k.toUTCString()+"; ";document.cookie=x}};function M(){try{return new se}catch{}return new be}function ke(a){return function(){e.enableLogging&&a.apply(console,Array.prototype.slice.call(arguments))}}}async function jl(){const t="silent-login.html",e=await fetch(location.origin+"/"+t).then(async n=>n.status!==200?!1:(await n.text()).includes("silent-login-iframe-result")).catch(()=>!1);if(!e){const n=`O arquivo ${t} não foi localizado no projeto ou não possui o conteúdo correto!`;console.warn(n),document.documentElement.setAttribute("data-app-message",n)}return e}function Vl(t){const e=new Cr(t),n={},o=async(i={},f)=>{if(await jl())return i.onLoad==="login-required"&&document.documentElement.setAttribute("data-app-message","Autorizando..."),e.init(i).then(async w=>{w&&await r(),f&&typeof f=="function"&&f(),document.documentElement.classList.add("app-mounted")}).catch(w=>{console.error(w),document.documentElement.setAttribute("data-app-message","Não foi possível conectar no servidor de autenticação.")})},r=async()=>{const i=await e.loadUserInfo();n.email=i.email??"",n.emailVerified=i.email_verified===!0,n.firstName=i.given_name??"",n.lastName=i.family_name??"",n.name=i.name??"",n.sub=i.sub??"",n.username=i.preferred_username??"",n.roles=[...i.role??[]],n.groups=[...i.group??[]],n.IsInRole=f=>n.roles.includes(f),sessionStorage.setItem("name",n.name)};return{Instance:e,User:n,Init:o,Logout:()=>{e.logout({redirectUri:location.origin}).then(()=>{sessionStorage.removeItem("name")})}}}const zl=t=>Vl(t);class Vn{constructor(e=null){Be(this,"errors",[]);Be(this,"_value",null);Be(this,"_httpStatusCode");this._value=e,this._httpStatusCode=200}get value(){return this._value}set value(e){this._value=e}get hasSuccess(){return!this.hasError}get hasError(){return this.errors.length>0}get httpStatusCode(){return this._httpStatusCode}set httpStatusCode(e){this._httpStatusCode=e}WithError(e){this.errors.push(e),this._httpStatusCode===200&&(this._httpStatusCode=400)}WithErrors(e){e.forEach(n=>this.WithError(n))}}function xr(t,e){return function(){return t.apply(e,arguments)}}const{toString:Wl}=Object.prototype,{getPrototypeOf:zn}=Object,en=(t=>e=>{const n=Wl.call(e);return t[n]||(t[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),$e=t=>(t=t.toLowerCase(),e=>en(e)===t),tn=t=>e=>typeof e===t,{isArray:pt}=Array,Bt=tn("undefined");function ql(t){return t!==null&&!Bt(t)&&t.constructor!==null&&!Bt(t.constructor)&&Ie(t.constructor.isBuffer)&&t.constructor.isBuffer(t)}const Sr=$e("ArrayBuffer");function Kl(t){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(t):e=t&&t.buffer&&Sr(t.buffer),e}const Gl=tn("string"),Ie=tn("function"),_r=tn("number"),nn=t=>t!==null&&typeof t=="object",Jl=t=>t===!0||t===!1,on=t=>{if(en(t)!=="object")return!1;const e=zn(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Symbol.toStringTag in t)&&!(Symbol.iterator in t)},Yl=$e("Date"),Xl=$e("File"),Zl=$e("Blob"),Ql=$e("FileList"),eu=t=>nn(t)&&Ie(t.pipe),tu=t=>{let e;return t&&(typeof FormData=="function"&&t instanceof FormData||Ie(t.append)&&((e=en(t))==="formdata"||e==="object"&&Ie(t.toString)&&t.toString()==="[object FormData]"))},nu=$e("URLSearchParams"),ou=t=>t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Nt(t,e,{allOwnKeys:n=!1}={}){if(t===null||typeof t>"u")return;let o,r;if(typeof t!="object"&&(t=[t]),pt(t))for(o=0,r=t.length;o<r;o++)e.call(null,t[o],o,t);else{const s=n?Object.getOwnPropertyNames(t):Object.keys(t),i=s.length;let f;for(o=0;o<i;o++)f=s[o],e.call(null,t[f],f,t)}}function vr(t,e){e=e.toLowerCase();const n=Object.keys(t);let o=n.length,r;for(;o-- >0;)if(r=n[o],e===r.toLowerCase())return r;return null}const Tr=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Pr=t=>!Bt(t)&&t!==Tr;function Wn(){const{caseless:t}=Pr(this)&&this||{},e={},n=(o,r)=>{const s=t&&vr(e,r)||r;on(e[s])&&on(o)?e[s]=Wn(e[s],o):on(o)?e[s]=Wn({},o):pt(o)?e[s]=o.slice():e[s]=o};for(let o=0,r=arguments.length;o<r;o++)arguments[o]&&Nt(arguments[o],n);return e}const ru=(t,e,n,{allOwnKeys:o}={})=>(Nt(e,(r,s)=>{n&&Ie(r)?t[s]=xr(r,n):t[s]=r},{allOwnKeys:o}),t),su=t=>(t.charCodeAt(0)===65279&&(t=t.slice(1)),t),iu=(t,e,n,o)=>{t.prototype=Object.create(e.prototype,o),t.prototype.constructor=t,Object.defineProperty(t,"super",{value:e.prototype}),n&&Object.assign(t.prototype,n)},au=(t,e,n,o)=>{let r,s,i;const f={};if(e=e||{},t==null)return e;do{for(r=Object.getOwnPropertyNames(t),s=r.length;s-- >0;)i=r[s],(!o||o(i,t,e))&&!f[i]&&(e[i]=t[i],f[i]=!0);t=n!==!1&&zn(t)}while(t&&(!n||n(t,e))&&t!==Object.prototype);return e},cu=(t,e,n)=>{t=String(t),(n===void 0||n>t.length)&&(n=t.length),n-=e.length;const o=t.indexOf(e,n);return o!==-1&&o===n},lu=t=>{if(!t)return null;if(pt(t))return t;let e=t.length;if(!_r(e))return null;const n=new Array(e);for(;e-- >0;)n[e]=t[e];return n},uu=(t=>e=>t&&e instanceof t)(typeof Uint8Array<"u"&&zn(Uint8Array)),du=(t,e)=>{const o=(t&&t[Symbol.iterator]).call(t);let r;for(;(r=o.next())&&!r.done;){const s=r.value;e.call(t,s[0],s[1])}},fu=(t,e)=>{let n;const o=[];for(;(n=t.exec(e))!==null;)o.push(n);return o},pu=$e("HTMLFormElement"),hu=t=>t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,o,r){return o.toUpperCase()+r}),Rr=(({hasOwnProperty:t})=>(e,n)=>t.call(e,n))(Object.prototype),mu=$e("RegExp"),Lr=(t,e)=>{const n=Object.getOwnPropertyDescriptors(t),o={};Nt(n,(r,s)=>{let i;(i=e(r,s,t))!==!1&&(o[s]=i||r)}),Object.defineProperties(t,o)},gu=t=>{Lr(t,(e,n)=>{if(Ie(t)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const o=t[n];if(Ie(o)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},yu=(t,e)=>{const n={},o=r=>{r.forEach(s=>{n[s]=!0})};return pt(t)?o(t):o(String(t).split(e)),n},bu=()=>{},wu=(t,e)=>(t=+t,Number.isFinite(t)?t:e),qn="abcdefghijklmnopqrstuvwxyz",Or="0123456789",Ir={DIGIT:Or,ALPHA:qn,ALPHA_DIGIT:qn+qn.toUpperCase()+Or},Eu=(t=16,e=Ir.ALPHA_DIGIT)=>{let n="";const{length:o}=e;for(;t--;)n+=e[Math.random()*o|0];return n};function Au(t){return!!(t&&Ie(t.append)&&t[Symbol.toStringTag]==="FormData"&&t[Symbol.iterator])}const ku=t=>{const e=new Array(10),n=(o,r)=>{if(nn(o)){if(e.indexOf(o)>=0)return;if(!("toJSON"in o)){e[r]=o;const s=pt(o)?[]:{};return Nt(o,(i,f)=>{const u=n(i,r+1);!Bt(u)&&(s[f]=u)}),e[r]=void 0,s}}return o};return n(t,0)},Cu=$e("AsyncFunction"),h={isArray:pt,isArrayBuffer:Sr,isBuffer:ql,isFormData:tu,isArrayBufferView:Kl,isString:Gl,isNumber:_r,isBoolean:Jl,isObject:nn,isPlainObject:on,isUndefined:Bt,isDate:Yl,isFile:Xl,isBlob:Zl,isRegExp:mu,isFunction:Ie,isStream:eu,isURLSearchParams:nu,isTypedArray:uu,isFileList:Ql,forEach:Nt,merge:Wn,extend:ru,trim:ou,stripBOM:su,inherits:iu,toFlatObject:au,kindOf:en,kindOfTest:$e,endsWith:cu,toArray:lu,forEachEntry:du,matchAll:fu,isHTMLForm:pu,hasOwnProperty:Rr,hasOwnProp:Rr,reduceDescriptors:Lr,freezeMethods:gu,toObjectSet:yu,toCamelCase:hu,noop:bu,toFiniteNumber:wu,findKey:vr,global:Tr,isContextDefined:Pr,ALPHABET:Ir,generateString:Eu,isSpecCompliantForm:Au,toJSONObject:ku,isAsyncFn:Cu,isThenable:t=>t&&(nn(t)||Ie(t))&&Ie(t.then)&&Ie(t.catch)};function X(t,e,n,o,r){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=t,this.name="AxiosError",e&&(this.code=e),n&&(this.config=n),o&&(this.request=o),r&&(this.response=r)}h.inherits(X,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:h.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const Br=X.prototype,Nr={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(t=>{Nr[t]={value:t}}),Object.defineProperties(X,Nr),Object.defineProperty(Br,"isAxiosError",{value:!0}),X.from=(t,e,n,o,r,s)=>{const i=Object.create(Br);return h.toFlatObject(t,i,function(u){return u!==Error.prototype},f=>f!=="isAxiosError"),X.call(i,t.message,e,n,o,r),i.cause=t,i.name=t.name,s&&Object.assign(i,s),i};const xu=null;function Kn(t){return h.isPlainObject(t)||h.isArray(t)}function Fr(t){return h.endsWith(t,"[]")?t.slice(0,-2):t}function Ur(t,e,n){return t?t.concat(e).map(function(r,s){return r=Fr(r),!n&&s?"["+r+"]":r}).join(n?".":""):e}function Su(t){return h.isArray(t)&&!t.some(Kn)}const _u=h.toFlatObject(h,{},null,function(e){return/^is[A-Z]/.test(e)});function rn(t,e,n){if(!h.isObject(t))throw new TypeError("target must be an object");e=e||new FormData,n=h.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(N,D){return!h.isUndefined(D[N])});const o=n.metaTokens,r=n.visitor||E,s=n.dots,i=n.indexes,u=(n.Blob||typeof Blob<"u"&&Blob)&&h.isSpecCompliantForm(e);if(!h.isFunction(r))throw new TypeError("visitor must be a function");function w(B){if(B===null)return"";if(h.isDate(B))return B.toISOString();if(!u&&h.isBlob(B))throw new X("Blob is not supported. Use a Buffer instead.");return h.isArrayBuffer(B)||h.isTypedArray(B)?u&&typeof Blob=="function"?new Blob([B]):Buffer.from(B):B}function E(B,N,D){let ee=B;if(B&&!D&&typeof B=="object"){if(h.endsWith(N,"{}"))N=o?N:N.slice(0,-2),B=JSON.stringify(B);else if(h.isArray(B)&&Su(B)||(h.isFileList(B)||h.endsWith(N,"[]"))&&(ee=h.toArray(B)))return N=Fr(N),ee.forEach(function(V,ye){!(h.isUndefined(V)||V===null)&&e.append(i===!0?Ur([N],ye,s):i===null?N:N+"[]",w(V))}),!1}return Kn(B)?!0:(e.append(Ur(D,N,s),w(B)),!1)}const b=[],j=Object.assign(_u,{defaultVisitor:E,convertValue:w,isVisitable:Kn});function $(B,N){if(!h.isUndefined(B)){if(b.indexOf(B)!==-1)throw Error("Circular reference detected in "+N.join("."));b.push(B),h.forEach(B,function(ee,oe){(!(h.isUndefined(ee)||ee===null)&&r.call(e,ee,h.isString(oe)?oe.trim():oe,N,j))===!0&&$(ee,N?N.concat(oe):[oe])}),b.pop()}}if(!h.isObject(t))throw new TypeError("data must be an object");return $(t),e}function Mr(t){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(t).replace(/[!'()~]|%20|%00/g,function(o){return e[o]})}function Gn(t,e){this._pairs=[],t&&rn(t,this,e)}const Dr=Gn.prototype;Dr.append=function(e,n){this._pairs.push([e,n])},Dr.toString=function(e){const n=e?function(o){return e.call(this,o,Mr)}:Mr;return this._pairs.map(function(r){return n(r[0])+"="+n(r[1])},"").join("&")};function vu(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function $r(t,e,n){if(!e)return t;const o=n&&n.encode||vu,r=n&&n.serialize;let s;if(r?s=r(e,n):s=h.isURLSearchParams(e)?e.toString():new Gn(e,n).toString(o),s){const i=t.indexOf("#");i!==-1&&(t=t.slice(0,i)),t+=(t.indexOf("?")===-1?"?":"&")+s}return t}class Hr{constructor(){this.handlers=[]}use(e,n,o){return this.handlers.push({fulfilled:e,rejected:n,synchronous:o?o.synchronous:!1,runWhen:o?o.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){h.forEach(this.handlers,function(o){o!==null&&e(o)})}}const jr={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},Tu={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams<"u"?URLSearchParams:Gn,FormData:typeof FormData<"u"?FormData:null,Blob:typeof Blob<"u"?Blob:null},protocols:["http","https","file","blob","url","data"]},Vr=typeof window<"u"&&typeof document<"u",Pu=(t=>Vr&&["ReactNative","NativeScript","NS"].indexOf(t)<0)(typeof navigator<"u"&&navigator.product),Ru=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",He={...Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:Vr,hasStandardBrowserEnv:Pu,hasStandardBrowserWebWorkerEnv:Ru},Symbol.toStringTag,{value:"Module"})),...Tu};function Lu(t,e){return rn(t,new He.classes.URLSearchParams,Object.assign({visitor:function(n,o,r,s){return He.isNode&&h.isBuffer(n)?(this.append(o,n.toString("base64")),!1):s.defaultVisitor.apply(this,arguments)}},e))}function Ou(t){return h.matchAll(/\w+|\[(\w*)]/g,t).map(e=>e[0]==="[]"?"":e[1]||e[0])}function Iu(t){const e={},n=Object.keys(t);let o;const r=n.length;let s;for(o=0;o<r;o++)s=n[o],e[s]=t[s];return e}function zr(t){function e(n,o,r,s){let i=n[s++];if(i==="__proto__")return!0;const f=Number.isFinite(+i),u=s>=n.length;return i=!i&&h.isArray(r)?r.length:i,u?(h.hasOwnProp(r,i)?r[i]=[r[i],o]:r[i]=o,!f):((!r[i]||!h.isObject(r[i]))&&(r[i]=[]),e(n,o,r[i],s)&&h.isArray(r[i])&&(r[i]=Iu(r[i])),!f)}if(h.isFormData(t)&&h.isFunction(t.entries)){const n={};return h.forEachEntry(t,(o,r)=>{e(Ou(o),r,n,0)}),n}return null}function Bu(t,e,n){if(h.isString(t))try{return(e||JSON.parse)(t),h.trim(t)}catch(o){if(o.name!=="SyntaxError")throw o}return(n||JSON.stringify)(t)}const Jn={transitional:jr,adapter:["xhr","http"],transformRequest:[function(e,n){const o=n.getContentType()||"",r=o.indexOf("application/json")>-1,s=h.isObject(e);if(s&&h.isHTMLForm(e)&&(e=new FormData(e)),h.isFormData(e))return r&&r?JSON.stringify(zr(e)):e;if(h.isArrayBuffer(e)||h.isBuffer(e)||h.isStream(e)||h.isFile(e)||h.isBlob(e))return e;if(h.isArrayBufferView(e))return e.buffer;if(h.isURLSearchParams(e))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let f;if(s){if(o.indexOf("application/x-www-form-urlencoded")>-1)return Lu(e,this.formSerializer).toString();if((f=h.isFileList(e))||o.indexOf("multipart/form-data")>-1){const u=this.env&&this.env.FormData;return rn(f?{"files[]":e}:e,u&&new u,this.formSerializer)}}return s||r?(n.setContentType("application/json",!1),Bu(e)):e}],transformResponse:[function(e){const n=this.transitional||Jn.transitional,o=n&&n.forcedJSONParsing,r=this.responseType==="json";if(e&&h.isString(e)&&(o&&!this.responseType||r)){const i=!(n&&n.silentJSONParsing)&&r;try{return JSON.parse(e)}catch(f){if(i)throw f.name==="SyntaxError"?X.from(f,X.ERR_BAD_RESPONSE,this,null,this.response):f}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:He.classes.FormData,Blob:He.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};h.forEach(["delete","get","head","post","put","patch"],t=>{Jn.headers[t]={}});const Yn=Jn,Nu=h.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),Fu=t=>{const e={};let n,o,r;return t&&t.split(`
78
- `).forEach(function(i){r=i.indexOf(":"),n=i.substring(0,r).trim().toLowerCase(),o=i.substring(r+1).trim(),!(!n||e[n]&&Nu[n])&&(n==="set-cookie"?e[n]?e[n].push(o):e[n]=[o]:e[n]=e[n]?e[n]+", "+o:o)}),e},Wr=Symbol("internals");function Ft(t){return t&&String(t).trim().toLowerCase()}function sn(t){return t===!1||t==null?t:h.isArray(t)?t.map(sn):String(t)}function Uu(t){const e=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let o;for(;o=n.exec(t);)e[o[1]]=o[2];return e}const Mu=t=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());function Xn(t,e,n,o,r){if(h.isFunction(o))return o.call(this,e,n);if(r&&(e=n),!!h.isString(e)){if(h.isString(o))return e.indexOf(o)!==-1;if(h.isRegExp(o))return o.test(e)}}function Du(t){return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,n,o)=>n.toUpperCase()+o)}function $u(t,e){const n=h.toCamelCase(" "+e);["get","set","has"].forEach(o=>{Object.defineProperty(t,o+n,{value:function(r,s,i){return this[o].call(this,e,r,s,i)},configurable:!0})})}class an{constructor(e){e&&this.set(e)}set(e,n,o){const r=this;function s(f,u,w){const E=Ft(u);if(!E)throw new Error("header name must be a non-empty string");const b=h.findKey(r,E);(!b||r[b]===void 0||w===!0||w===void 0&&r[b]!==!1)&&(r[b||u]=sn(f))}const i=(f,u)=>h.forEach(f,(w,E)=>s(w,E,u));return h.isPlainObject(e)||e instanceof this.constructor?i(e,n):h.isString(e)&&(e=e.trim())&&!Mu(e)?i(Fu(e),n):e!=null&&s(n,e,o),this}get(e,n){if(e=Ft(e),e){const o=h.findKey(this,e);if(o){const r=this[o];if(!n)return r;if(n===!0)return Uu(r);if(h.isFunction(n))return n.call(this,r,o);if(h.isRegExp(n))return n.exec(r);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,n){if(e=Ft(e),e){const o=h.findKey(this,e);return!!(o&&this[o]!==void 0&&(!n||Xn(this,this[o],o,n)))}return!1}delete(e,n){const o=this;let r=!1;function s(i){if(i=Ft(i),i){const f=h.findKey(o,i);f&&(!n||Xn(o,o[f],f,n))&&(delete o[f],r=!0)}}return h.isArray(e)?e.forEach(s):s(e),r}clear(e){const n=Object.keys(this);let o=n.length,r=!1;for(;o--;){const s=n[o];(!e||Xn(this,this[s],s,e,!0))&&(delete this[s],r=!0)}return r}normalize(e){const n=this,o={};return h.forEach(this,(r,s)=>{const i=h.findKey(o,s);if(i){n[i]=sn(r),delete n[s];return}const f=e?Du(s):String(s).trim();f!==s&&delete n[s],n[f]=sn(r),o[f]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const n=Object.create(null);return h.forEach(this,(o,r)=>{o!=null&&o!==!1&&(n[r]=e&&h.isArray(o)?o.join(", "):o)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,n])=>e+": "+n).join(`
79
- `)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...n){const o=new this(e);return n.forEach(r=>o.set(r)),o}static accessor(e){const o=(this[Wr]=this[Wr]={accessors:{}}).accessors,r=this.prototype;function s(i){const f=Ft(i);o[f]||($u(r,i),o[f]=!0)}return h.isArray(e)?e.forEach(s):s(e),this}}an.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),h.reduceDescriptors(an.prototype,({value:t},e)=>{let n=e[0].toUpperCase()+e.slice(1);return{get:()=>t,set(o){this[n]=o}}}),h.freezeMethods(an);const ze=an;function Zn(t,e){const n=this||Yn,o=e||n,r=ze.from(o.headers);let s=o.data;return h.forEach(t,function(f){s=f.call(n,s,r.normalize(),e?e.status:void 0)}),r.normalize(),s}function qr(t){return!!(t&&t.__CANCEL__)}function Ut(t,e,n){X.call(this,t??"canceled",X.ERR_CANCELED,e,n),this.name="CanceledError"}h.inherits(Ut,X,{__CANCEL__:!0});function Hu(t,e,n){const o=n.config.validateStatus;!n.status||!o||o(n.status)?t(n):e(new X("Request failed with status code "+n.status,[X.ERR_BAD_REQUEST,X.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}const ju=He.hasStandardBrowserEnv?{write(t,e,n,o,r,s){const i=[t+"="+encodeURIComponent(e)];h.isNumber(n)&&i.push("expires="+new Date(n).toGMTString()),h.isString(o)&&i.push("path="+o),h.isString(r)&&i.push("domain="+r),s===!0&&i.push("secure"),document.cookie=i.join("; ")},read(t){const e=document.cookie.match(new RegExp("(^|;\\s*)("+t+")=([^;]*)"));return e?decodeURIComponent(e[3]):null},remove(t){this.write(t,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function Vu(t){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}function zu(t,e){return e?t.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):t}function Kr(t,e){return t&&!Vu(e)?zu(t,e):e}const Wu=He.hasStandardBrowserEnv?function(){const e=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");let o;function r(s){let i=s;return e&&(n.setAttribute("href",i),i=n.href),n.setAttribute("href",i),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:n.pathname.charAt(0)==="/"?n.pathname:"/"+n.pathname}}return o=r(window.location.href),function(i){const f=h.isString(i)?r(i):i;return f.protocol===o.protocol&&f.host===o.host}}():function(){return function(){return!0}}();function qu(t){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(t);return e&&e[1]||""}function Ku(t,e){t=t||10;const n=new Array(t),o=new Array(t);let r=0,s=0,i;return e=e!==void 0?e:1e3,function(u){const w=Date.now(),E=o[s];i||(i=w),n[r]=u,o[r]=w;let b=s,j=0;for(;b!==r;)j+=n[b++],b=b%t;if(r=(r+1)%t,r===s&&(s=(s+1)%t),w-i<e)return;const $=E&&w-E;return $?Math.round(j*1e3/$):void 0}}function Gr(t,e){let n=0;const o=Ku(50,250);return r=>{const s=r.loaded,i=r.lengthComputable?r.total:void 0,f=s-n,u=o(f),w=s<=i;n=s;const E={loaded:s,total:i,progress:i?s/i:void 0,bytes:f,rate:u||void 0,estimated:u&&i&&w?(i-s)/u:void 0,event:r};E[e?"download":"upload"]=!0,t(E)}}const Qn={http:xu,xhr:typeof XMLHttpRequest<"u"&&function(t){return new Promise(function(n,o){let r=t.data;const s=ze.from(t.headers).normalize();let{responseType:i,withXSRFToken:f}=t,u;function w(){t.cancelToken&&t.cancelToken.unsubscribe(u),t.signal&&t.signal.removeEventListener("abort",u)}let E;if(h.isFormData(r)){if(He.hasStandardBrowserEnv||He.hasStandardBrowserWebWorkerEnv)s.setContentType(!1);else if((E=s.getContentType())!==!1){const[N,...D]=E?E.split(";").map(ee=>ee.trim()).filter(Boolean):[];s.setContentType([N||"multipart/form-data",...D].join("; "))}}let b=new XMLHttpRequest;if(t.auth){const N=t.auth.username||"",D=t.auth.password?unescape(encodeURIComponent(t.auth.password)):"";s.set("Authorization","Basic "+btoa(N+":"+D))}const j=Kr(t.baseURL,t.url);b.open(t.method.toUpperCase(),$r(j,t.params,t.paramsSerializer),!0),b.timeout=t.timeout;function $(){if(!b)return;const N=ze.from("getAllResponseHeaders"in b&&b.getAllResponseHeaders()),ee={data:!i||i==="text"||i==="json"?b.responseText:b.response,status:b.status,statusText:b.statusText,headers:N,config:t,request:b};Hu(function(V){n(V),w()},function(V){o(V),w()},ee),b=null}if("onloadend"in b?b.onloadend=$:b.onreadystatechange=function(){!b||b.readyState!==4||b.status===0&&!(b.responseURL&&b.responseURL.indexOf("file:")===0)||setTimeout($)},b.onabort=function(){b&&(o(new X("Request aborted",X.ECONNABORTED,t,b)),b=null)},b.onerror=function(){o(new X("Network Error",X.ERR_NETWORK,t,b)),b=null},b.ontimeout=function(){let D=t.timeout?"timeout of "+t.timeout+"ms exceeded":"timeout exceeded";const ee=t.transitional||jr;t.timeoutErrorMessage&&(D=t.timeoutErrorMessage),o(new X(D,ee.clarifyTimeoutError?X.ETIMEDOUT:X.ECONNABORTED,t,b)),b=null},He.hasStandardBrowserEnv&&(f&&h.isFunction(f)&&(f=f(t)),f||f!==!1&&Wu(j))){const N=t.xsrfHeaderName&&t.xsrfCookieName&&ju.read(t.xsrfCookieName);N&&s.set(t.xsrfHeaderName,N)}r===void 0&&s.setContentType(null),"setRequestHeader"in b&&h.forEach(s.toJSON(),function(D,ee){b.setRequestHeader(ee,D)}),h.isUndefined(t.withCredentials)||(b.withCredentials=!!t.withCredentials),i&&i!=="json"&&(b.responseType=t.responseType),typeof t.onDownloadProgress=="function"&&b.addEventListener("progress",Gr(t.onDownloadProgress,!0)),typeof t.onUploadProgress=="function"&&b.upload&&b.upload.addEventListener("progress",Gr(t.onUploadProgress)),(t.cancelToken||t.signal)&&(u=N=>{b&&(o(!N||N.type?new Ut(null,t,b):N),b.abort(),b=null)},t.cancelToken&&t.cancelToken.subscribe(u),t.signal&&(t.signal.aborted?u():t.signal.addEventListener("abort",u)));const B=qu(j);if(B&&He.protocols.indexOf(B)===-1){o(new X("Unsupported protocol "+B+":",X.ERR_BAD_REQUEST,t));return}b.send(r||null)})}};h.forEach(Qn,(t,e)=>{if(t){try{Object.defineProperty(t,"name",{value:e})}catch{}Object.defineProperty(t,"adapterName",{value:e})}});const Jr=t=>`- ${t}`,Gu=t=>h.isFunction(t)||t===null||t===!1,Yr={getAdapter:t=>{t=h.isArray(t)?t:[t];const{length:e}=t;let n,o;const r={};for(let s=0;s<e;s++){n=t[s];let i;if(o=n,!Gu(n)&&(o=Qn[(i=String(n)).toLowerCase()],o===void 0))throw new X(`Unknown adapter '${i}'`);if(o)break;r[i||"#"+s]=o}if(!o){const s=Object.entries(r).map(([f,u])=>`adapter ${f} `+(u===!1?"is not supported by the environment":"is not available in the build"));let i=e?s.length>1?`since :
80
- `+s.map(Jr).join(`
81
- `):" "+Jr(s[0]):"as no adapter specified";throw new X("There is no suitable adapter to dispatch the request "+i,"ERR_NOT_SUPPORT")}return o},adapters:Qn};function eo(t){if(t.cancelToken&&t.cancelToken.throwIfRequested(),t.signal&&t.signal.aborted)throw new Ut(null,t)}function Xr(t){return eo(t),t.headers=ze.from(t.headers),t.data=Zn.call(t,t.transformRequest),["post","put","patch"].indexOf(t.method)!==-1&&t.headers.setContentType("application/x-www-form-urlencoded",!1),Yr.getAdapter(t.adapter||Yn.adapter)(t).then(function(o){return eo(t),o.data=Zn.call(t,t.transformResponse,o),o.headers=ze.from(o.headers),o},function(o){return qr(o)||(eo(t),o&&o.response&&(o.response.data=Zn.call(t,t.transformResponse,o.response),o.response.headers=ze.from(o.response.headers))),Promise.reject(o)})}const Zr=t=>t instanceof ze?t.toJSON():t;function ht(t,e){e=e||{};const n={};function o(w,E,b){return h.isPlainObject(w)&&h.isPlainObject(E)?h.merge.call({caseless:b},w,E):h.isPlainObject(E)?h.merge({},E):h.isArray(E)?E.slice():E}function r(w,E,b){if(h.isUndefined(E)){if(!h.isUndefined(w))return o(void 0,w,b)}else return o(w,E,b)}function s(w,E){if(!h.isUndefined(E))return o(void 0,E)}function i(w,E){if(h.isUndefined(E)){if(!h.isUndefined(w))return o(void 0,w)}else return o(void 0,E)}function f(w,E,b){if(b in e)return o(w,E);if(b in t)return o(void 0,w)}const u={url:s,method:s,data:s,baseURL:i,transformRequest:i,transformResponse:i,paramsSerializer:i,timeout:i,timeoutMessage:i,withCredentials:i,withXSRFToken:i,adapter:i,responseType:i,xsrfCookieName:i,xsrfHeaderName:i,onUploadProgress:i,onDownloadProgress:i,decompress:i,maxContentLength:i,maxBodyLength:i,beforeRedirect:i,transport:i,httpAgent:i,httpsAgent:i,cancelToken:i,socketPath:i,responseEncoding:i,validateStatus:f,headers:(w,E)=>r(Zr(w),Zr(E),!0)};return h.forEach(Object.keys(Object.assign({},t,e)),function(E){const b=u[E]||r,j=b(t[E],e[E],E);h.isUndefined(j)&&b!==f||(n[E]=j)}),n}const Qr="1.6.5",to={};["object","boolean","number","function","string","symbol"].forEach((t,e)=>{to[t]=function(o){return typeof o===t||"a"+(e<1?"n ":" ")+t}});const es={};to.transitional=function(e,n,o){function r(s,i){return"[Axios v"+Qr+"] Transitional option '"+s+"'"+i+(o?". "+o:"")}return(s,i,f)=>{if(e===!1)throw new X(r(i," has been removed"+(n?" in "+n:"")),X.ERR_DEPRECATED);return n&&!es[i]&&(es[i]=!0,console.warn(r(i," has been deprecated since v"+n+" and will be removed in the near future"))),e?e(s,i,f):!0}};function Ju(t,e,n){if(typeof t!="object")throw new X("options must be an object",X.ERR_BAD_OPTION_VALUE);const o=Object.keys(t);let r=o.length;for(;r-- >0;){const s=o[r],i=e[s];if(i){const f=t[s],u=f===void 0||i(f,s,t);if(u!==!0)throw new X("option "+s+" must be "+u,X.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new X("Unknown option "+s,X.ERR_BAD_OPTION)}}const no={assertOptions:Ju,validators:to},Ye=no.validators;class cn{constructor(e){this.defaults=e,this.interceptors={request:new Hr,response:new Hr}}request(e,n){typeof e=="string"?(n=n||{},n.url=e):n=e||{},n=ht(this.defaults,n);const{transitional:o,paramsSerializer:r,headers:s}=n;o!==void 0&&no.assertOptions(o,{silentJSONParsing:Ye.transitional(Ye.boolean),forcedJSONParsing:Ye.transitional(Ye.boolean),clarifyTimeoutError:Ye.transitional(Ye.boolean)},!1),r!=null&&(h.isFunction(r)?n.paramsSerializer={serialize:r}:no.assertOptions(r,{encode:Ye.function,serialize:Ye.function},!0)),n.method=(n.method||this.defaults.method||"get").toLowerCase();let i=s&&h.merge(s.common,s[n.method]);s&&h.forEach(["delete","get","head","post","put","patch","common"],B=>{delete s[B]}),n.headers=ze.concat(i,s);const f=[];let u=!0;this.interceptors.request.forEach(function(N){typeof N.runWhen=="function"&&N.runWhen(n)===!1||(u=u&&N.synchronous,f.unshift(N.fulfilled,N.rejected))});const w=[];this.interceptors.response.forEach(function(N){w.push(N.fulfilled,N.rejected)});let E,b=0,j;if(!u){const B=[Xr.bind(this),void 0];for(B.unshift.apply(B,f),B.push.apply(B,w),j=B.length,E=Promise.resolve(n);b<j;)E=E.then(B[b++],B[b++]);return E}j=f.length;let $=n;for(b=0;b<j;){const B=f[b++],N=f[b++];try{$=B($)}catch(D){N.call(this,D);break}}try{E=Xr.call(this,$)}catch(B){return Promise.reject(B)}for(b=0,j=w.length;b<j;)E=E.then(w[b++],w[b++]);return E}getUri(e){e=ht(this.defaults,e);const n=Kr(e.baseURL,e.url);return $r(n,e.params,e.paramsSerializer)}}h.forEach(["delete","get","head","options"],function(e){cn.prototype[e]=function(n,o){return this.request(ht(o||{},{method:e,url:n,data:(o||{}).data}))}}),h.forEach(["post","put","patch"],function(e){function n(o){return function(s,i,f){return this.request(ht(f||{},{method:e,headers:o?{"Content-Type":"multipart/form-data"}:{},url:s,data:i}))}}cn.prototype[e]=n(),cn.prototype[e+"Form"]=n(!0)});const ln=cn;class oo{constructor(e){if(typeof e!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(s){n=s});const o=this;this.promise.then(r=>{if(!o._listeners)return;let s=o._listeners.length;for(;s-- >0;)o._listeners[s](r);o._listeners=null}),this.promise.then=r=>{let s;const i=new Promise(f=>{o.subscribe(f),s=f}).then(r);return i.cancel=function(){o.unsubscribe(s)},i},e(function(s,i,f){o.reason||(o.reason=new Ut(s,i,f),n(o.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const n=this._listeners.indexOf(e);n!==-1&&this._listeners.splice(n,1)}static source(){let e;return{token:new oo(function(r){e=r}),cancel:e}}}const Yu=oo;function Xu(t){return function(n){return t.apply(null,n)}}function Zu(t){return h.isObject(t)&&t.isAxiosError===!0}const ro={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(ro).forEach(([t,e])=>{ro[e]=t});const Qu=ro;function ts(t){const e=new ln(t),n=xr(ln.prototype.request,e);return h.extend(n,ln.prototype,e,{allOwnKeys:!0}),h.extend(n,e,null,{allOwnKeys:!0}),n.create=function(r){return ts(ht(t,r))},n}const re=ts(Yn);re.Axios=ln,re.CanceledError=Ut,re.CancelToken=Yu,re.isCancel=qr,re.VERSION=Qr,re.toFormData=rn,re.AxiosError=X,re.Cancel=re.CanceledError,re.all=function(e){return Promise.all(e)},re.spread=Xu,re.isAxiosError=Zu,re.mergeConfig=ht,re.AxiosHeaders=ze,re.formToJSON=t=>zr(h.isHTMLForm(t)?new FormData(t):t),re.getAdapter=Yr.getAdapter,re.HttpStatusCode=Qu,re.default=re;class ns{constructor(e){Be(this,"keycloak");Be(this,"axios");Be(this,"fileName","silent-login.html");this.keycloak=e,this.axios=re.create(),this.axios.defaults.baseURL="https://localhost:5001/api",this.axios.defaults.headers.common["content-type"]="application/json",this.axios.defaults.timeout=1e3*60*5,this.axios.interceptors.request.use(async n=>{await this.SilentLogin();const o=this.keycloak.token;return n.headers.Authorization=`Bearer ${o}`,n})}ParseAppResult(e){try{const n=typeof e.hasSuccess=="boolean",o=typeof e.hasError=="boolean",r=typeof e.httpStatusCode=="number",s=Array.isArray(e.errors);return n&&o&&r&&s?e:null}catch{return null}}HandleThen(e){const n=new Vn,o=this.ParseAppResult(e.data);return o===null?(n.value=e.data,n):o.hasError?(o.errors.forEach(r=>n.WithError(r)),n.httpStatusCode=o.httpStatusCode,n):(n.value=e.data.value,n)}HandleCatch(e){var r;const n=new Vn,o=this.ParseAppResult((r=e.response)==null?void 0:r.data);return o===null?n.WithError(e.message):(n.WithErrors(o.errors),n.httpStatusCode=o.httpStatusCode),n}async SilentLogin(){return new Promise(async e=>{if(!this.isTokenExpired){e(!0);return}const n=this.GenerateIframe(),o=r=>{if(document.body.removeChild(n),window.removeEventListener("message",o),r.origin!==location.origin){e(!1);return}const s=r.data.action,i=r.data.code,f=r.data.state,u=r.data.error;if(s!=="silent-login-iframe-result"||u==="login_required"||!i){e(!1);return}const w=new XMLHttpRequest;w.open("POST",this.tokenExchangeUrl,!0),w.setRequestHeader("Content-type","application/x-www-form-urlencoded"),w.onreadystatechange=()=>{if(w.readyState===4){if(w.status===200){const E=JSON.parse(w.responseText);this.keycloak.setToken(E.access_token,null,E.id_token,new Date().getTime()),e(!0);return}e(!1)}},w.send(this.TokenExchangeParams(i,f))};window.addEventListener("message",o)}).then(e=>(e||(this.keycloak.clearToken(),this.keycloak.login()),e))}GetCodeVerifierFromState(e){const n=`kc-callback-${e}`,o=localStorage.getItem(n);if(o)return localStorage.removeItem(n),JSON.parse(o).pkceCodeVerifier}TokenExchangeParams(e,n){let o=`code=${e}&grant_type=authorization_code`;return o+=`&client_id=${encodeURIComponent(this.keycloak.clientId)}`,o+=`&redirect_uri=${this.silentLoginRedirectUrl}`,o+=`&code_verifier=${this.GetCodeVerifierFromState(n)}`,o}GenerateIframe(){const e=document.createElement("iframe");return e.src=this.keycloak.createLoginUrl({prompt:"none",redirectUri:this.silentLoginRedirectUrl})??"",document.body.appendChild(e),e}get silentLoginRedirectUrl(){return`${location.origin}/${this.fileName}`}get tokenExchangeUrl(){return`${this.keycloak.authServerUrl}/realms/${this.keycloak.realm}/protocol/openid-connect/token`}get isTokenExpired(){const e=this.keycloak.tokenParsed,n=e?e.exp:null;return!e||!n?!0:n-Math.ceil(new Date().getTime()/1e3)+(this.keycloak.timeSkew??0)<10}}const ed=t=>new ns(t);$n.SetInitialTheme(),Z.AppResult=Vn,Z.AxiosClient=ns,Z.SfButton=mo,Z.SfContent=bl,Z.SfDrawer=ho,Z.SfIcon=wt,Z.SfLayout=pl,Z.SfMessage=_l,Z.SfNavMenuLink=gl,Z.SfTabNavigation=xl,Z.SfTooltip=pn,Z.UseAlertService=Jc,Z.UseAuthService=zl,Z.UseAxiosClient=ed,Z.UseConfirmService=wr,Z.UseNavMenuService=fn,Object.defineProperty(Z,Symbol.toStringTag,{value:"Module"})});
159
+ For more information see: https://www.keycloak.org/docs/latest/securing_apps/#_modern_browsers`),i.enable=!1,e.silentCheckSsoFallback&&(e.silentCheckSsoRedirectUri=!1)),document.body.removeChild(h),window.removeEventListener("message",E),d.setSuccess()))};window.addEventListener("message",E,!1)}else d.setSuccess();return O(d.promise,e.messageReceiveTimeout,"Timeout when waiting for 3rd party check iframe message.")}function ce(d){if(!d||d=="default")return{login:function(k){return window.location.assign(e.createLoginUrl(k)),B().promise},logout:function(k){return window.location.replace(e.createLogoutUrl(k)),B().promise},register:function(k){return window.location.assign(e.createRegisterUrl(k)),B().promise},accountManagement:function(){var k=e.createAccountUrl();if(typeof k<"u")window.location.href=k;else throw"Not supported by the OIDC server";return B().promise},redirectUri:function(k,P){return k&&k.redirectUri?k.redirectUri:e.redirectUri?e.redirectUri:location.href}};if(d=="cordova"){i.enable=!1;var h=function(k,P,M){return window.cordova&&window.cordova.InAppBrowser?window.cordova.InAppBrowser.open(k,P,M):window.open(k,P,M)},E=function(k){return k&&k.cordovaOptions?Object.keys(k.cordovaOptions).reduce(function(P,M){return P[M]=k.cordovaOptions[M],P},{}):{}},I=function(k){return Object.keys(k).reduce(function(P,M){return P.push(M+"="+k[M]),P},[]).join(",")},S=function(k){var P=E(k);return P.location="no",k&&k.prompt=="none"&&(P.hidden="yes"),I(P)},F=function(){return e.redirectUri||"http://localhost"};return{login:function(k){var P=B(),M=S(k),N=e.createLoginUrl(k),z=h(N,"_blank",M),Q=!1,Ie=!1,Ce=function(){Ie=!0,z.close()};return z.addEventListener("loadstart",function(ge){if(ge.url.indexOf(F())==0){var qe=L(ge.url);q(qe,P),Ce(),Q=!0}}),z.addEventListener("loaderror",function(ge){if(!Q)if(ge.url.indexOf(F())==0){var qe=L(ge.url);q(qe,P),Ce(),Q=!0}else P.setError(),Ce()}),z.addEventListener("exit",function(ge){Ie||P.setError({reason:"closed_by_user"})}),P.promise},logout:function(k){var P=B(),M=e.createLogoutUrl(k),N=h(M,"_blank","location=no,hidden=yes,clearcache=yes"),z;return N.addEventListener("loadstart",function(Q){Q.url.indexOf(F())==0&&N.close()}),N.addEventListener("loaderror",function(Q){Q.url.indexOf(F())==0||(z=!0),N.close()}),N.addEventListener("exit",function(Q){z?P.setError():(e.clearToken(),P.setSuccess())}),P.promise},register:function(k){var P=B(),M=e.createRegisterUrl(),N=S(k),z=h(M,"_blank",N);return z.addEventListener("loadstart",function(Q){if(Q.url.indexOf(F())==0){z.close();var Ie=L(Q.url);q(Ie,P)}}),P.promise},accountManagement:function(){var k=e.createAccountUrl();if(typeof k<"u"){var P=h(k,"_blank","location=no");P.addEventListener("loadstart",function(M){M.url.indexOf(F())==0&&P.close()})}else throw"Not supported by the OIDC server"},redirectUri:function(k){return F()}}}if(d=="cordova-native")return i.enable=!1,{login:function(k){var P=B(),M=e.createLoginUrl(k);return universalLinks.subscribe("keycloak",function(N){universalLinks.unsubscribe("keycloak"),window.cordova.plugins.browsertab.close();var z=L(N.url);q(z,P)}),window.cordova.plugins.browsertab.openUrl(M),P.promise},logout:function(k){var P=B(),M=e.createLogoutUrl(k);return universalLinks.subscribe("keycloak",function(N){universalLinks.unsubscribe("keycloak"),window.cordova.plugins.browsertab.close(),e.clearToken(),P.setSuccess()}),window.cordova.plugins.browsertab.openUrl(M),P.promise},register:function(k){var P=B(),M=e.createRegisterUrl(k);return universalLinks.subscribe("keycloak",function(N){universalLinks.unsubscribe("keycloak"),window.cordova.plugins.browsertab.close();var z=L(N.url);q(z,P)}),window.cordova.plugins.browsertab.openUrl(M),P.promise},accountManagement:function(){var k=e.createAccountUrl();if(typeof k<"u")window.cordova.plugins.browsertab.openUrl(k);else throw"Not supported by the OIDC server"},redirectUri:function(k){return k&&k.redirectUri?k.redirectUri:e.redirectUri?e.redirectUri:"http://localhost"}};throw"invalid adapter type: "+d}var fe=function(){if(!(this instanceof fe))return new fe;localStorage.setItem("kc-test","test"),localStorage.removeItem("kc-test");var d=this;function h(){for(var E=new Date().getTime(),I=0;I<localStorage.length;I++){var S=localStorage.key(I);if(S&&S.indexOf("kc-callback-")==0){var F=localStorage.getItem(S);if(F)try{var k=JSON.parse(F).expires;(!k||k<E)&&localStorage.removeItem(S)}catch{localStorage.removeItem(S)}}}}d.get=function(E){if(E){var I="kc-callback-"+E,S=localStorage.getItem(I);return S&&(localStorage.removeItem(I),S=JSON.parse(S)),h(),S}},d.add=function(E){h();var I="kc-callback-"+E.state;E.expires=new Date().getTime()+60*60*1e3,localStorage.setItem(I,JSON.stringify(E))}},_e=function(){if(!(this instanceof _e))return new _e;var d=this;d.get=function(S){if(S){var F=E("kc-callback-"+S);if(I("kc-callback-"+S,"",h(-100)),F)return JSON.parse(F)}},d.add=function(S){I("kc-callback-"+S.state,JSON.stringify(S),h(60))},d.removeItem=function(S){I(S,"",h(-100))};var h=function(S){var F=new Date;return F.setTime(F.getTime()+S*60*1e3),F},E=function(S){for(var F=S+"=",k=document.cookie.split(";"),P=0;P<k.length;P++){for(var M=k[P];M.charAt(0)==" ";)M=M.substring(1);if(M.indexOf(F)==0)return M.substring(F.length,M.length)}return""},I=function(S,F,k){var P=S+"="+F+"; expires="+k.toUTCString()+"; ";document.cookie=P}};function K(){try{return new fe}catch{}return new _e}function xe(d){return function(){e.enableLogging&&d.apply(console,Array.prototype.slice.call(arguments))}}}async function Nf(){const t="silent-login.html",e=await fetch(location.origin+"/"+t).then(async n=>n.status!==200?!1:(await n.text()).includes("silent-login-iframe-result")).catch(()=>!1);if(!e){const n=`O arquivo ${t} não foi localizado no projeto ou não possui o conteúdo correto!`;console.warn(n),document.documentElement.setAttribute("data-app-message",n)}return e}function Df(t){const e=new Pi(t),n={},r=async(s={},c)=>{if(await Nf())return s.onLoad==="login-required"&&document.documentElement.setAttribute("data-app-message","Autorizando..."),e.init(s).then(async u=>{u&&await o(),c&&typeof c=="function"&&c(),document.documentElement.classList.add("app-mounted")}).catch(u=>{console.error(u),document.documentElement.setAttribute("data-app-message","Não foi possível conectar no servidor de autenticação.")})},o=async()=>{const s=await e.loadUserInfo();n.email=s.email??"",n.emailVerified=s.email_verified===!0,n.firstName=s.given_name??"",n.lastName=s.family_name??"",n.name=s.name??"",n.sub=s.sub??"",n.username=s.preferred_username??"",n.roles=[...s.role??[]],n.groups=[...s.group??[]],n.IsInRole=c=>n.roles.includes(c),sessionStorage.setItem("name",n.name)};return{Instance:e,User:n,Init:r,Logout:()=>{e.logout({redirectUri:location.origin}).then(()=>{sessionStorage.removeItem("name")})}}}const Mf=t=>Df(t);class wr{constructor(e=null){Me(this,"errors",[]);Me(this,"_value",null);Me(this,"_httpStatusCode");this._value=e,this._httpStatusCode=200}get value(){return this._value}set value(e){this._value=e}get hasSuccess(){return!this.hasError}get hasError(){return this.errors.length>0}get httpStatusCode(){return this._httpStatusCode}set httpStatusCode(e){this._httpStatusCode=e}WithError(e){this.errors.push(e),this._httpStatusCode===200&&(this._httpStatusCode=400)}WithErrors(e){e.forEach(n=>this.WithError(n))}}function Ti(t,e){return function(){return t.apply(e,arguments)}}const{toString:Uf}=Object.prototype,{getPrototypeOf:Er}=Object,vn=(t=>e=>{const n=Uf.call(e);return t[n]||(t[n]=n.slice(8,-1).toLowerCase())})(Object.create(null)),ze=t=>(t=t.toLowerCase(),e=>vn(e)===t),wn=t=>e=>typeof e===t,{isArray:wt}=Array,Jt=wn("undefined");function Hf(t){return t!==null&&!Jt(t)&&t.constructor!==null&&!Jt(t.constructor)&&De(t.constructor.isBuffer)&&t.constructor.isBuffer(t)}const Oi=ze("ArrayBuffer");function jf(t){let e;return typeof ArrayBuffer<"u"&&ArrayBuffer.isView?e=ArrayBuffer.isView(t):e=t&&t.buffer&&Oi(t.buffer),e}const Vf=wn("string"),De=wn("function"),Li=wn("number"),En=t=>t!==null&&typeof t=="object",Kf=t=>t===!0||t===!1,Sn=t=>{if(vn(t)!=="object")return!1;const e=Er(t);return(e===null||e===Object.prototype||Object.getPrototypeOf(e)===null)&&!(Symbol.toStringTag in t)&&!(Symbol.iterator in t)},zf=ze("Date"),Wf=ze("File"),qf=ze("Blob"),Gf=ze("FileList"),Jf=t=>En(t)&&De(t.pipe),Yf=t=>{let e;return t&&(typeof FormData=="function"&&t instanceof FormData||De(t.append)&&((e=vn(t))==="formdata"||e==="object"&&De(t.toString)&&t.toString()==="[object FormData]"))},Xf=ze("URLSearchParams"),Zf=t=>t.trim?t.trim():t.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"");function Yt(t,e,{allOwnKeys:n=!1}={}){if(t===null||typeof t>"u")return;let r,o;if(typeof t!="object"&&(t=[t]),wt(t))for(r=0,o=t.length;r<o;r++)e.call(null,t[r],r,t);else{const i=n?Object.getOwnPropertyNames(t):Object.keys(t),s=i.length;let c;for(r=0;r<s;r++)c=i[r],e.call(null,t[c],c,t)}}function Bi(t,e){e=e.toLowerCase();const n=Object.keys(t);let r=n.length,o;for(;r-- >0;)if(o=n[r],e===o.toLowerCase())return o;return null}const Ri=typeof globalThis<"u"?globalThis:typeof self<"u"?self:typeof window<"u"?window:global,Fi=t=>!Jt(t)&&t!==Ri;function Sr(){const{caseless:t}=Fi(this)&&this||{},e={},n=(r,o)=>{const i=t&&Bi(e,o)||o;Sn(e[i])&&Sn(r)?e[i]=Sr(e[i],r):Sn(r)?e[i]=Sr({},r):wt(r)?e[i]=r.slice():e[i]=r};for(let r=0,o=arguments.length;r<o;r++)arguments[r]&&Yt(arguments[r],n);return e}const Qf=(t,e,n,{allOwnKeys:r}={})=>(Yt(e,(o,i)=>{n&&De(o)?t[i]=Ti(o,n):t[i]=o},{allOwnKeys:r}),t),ep=t=>(t.charCodeAt(0)===65279&&(t=t.slice(1)),t),tp=(t,e,n,r)=>{t.prototype=Object.create(e.prototype,r),t.prototype.constructor=t,Object.defineProperty(t,"super",{value:e.prototype}),n&&Object.assign(t.prototype,n)},np=(t,e,n,r)=>{let o,i,s;const c={};if(e=e||{},t==null)return e;do{for(o=Object.getOwnPropertyNames(t),i=o.length;i-- >0;)s=o[i],(!r||r(s,t,e))&&!c[s]&&(e[s]=t[s],c[s]=!0);t=n!==!1&&Er(t)}while(t&&(!n||n(t,e))&&t!==Object.prototype);return e},rp=(t,e,n)=>{t=String(t),(n===void 0||n>t.length)&&(n=t.length),n-=e.length;const r=t.indexOf(e,n);return r!==-1&&r===n},op=t=>{if(!t)return null;if(wt(t))return t;let e=t.length;if(!Li(e))return null;const n=new Array(e);for(;e-- >0;)n[e]=t[e];return n},ip=(t=>e=>t&&e instanceof t)(typeof Uint8Array<"u"&&Er(Uint8Array)),sp=(t,e)=>{const r=(t&&t[Symbol.iterator]).call(t);let o;for(;(o=r.next())&&!o.done;){const i=o.value;e.call(t,i[0],i[1])}},ap=(t,e)=>{let n;const r=[];for(;(n=t.exec(e))!==null;)r.push(n);return r},lp=ze("HTMLFormElement"),cp=t=>t.toLowerCase().replace(/[-_\s]([a-z\d])(\w*)/g,function(n,r,o){return r.toUpperCase()+o}),$i=(({hasOwnProperty:t})=>(e,n)=>t.call(e,n))(Object.prototype),up=ze("RegExp"),Ni=(t,e)=>{const n=Object.getOwnPropertyDescriptors(t),r={};Yt(n,(o,i)=>{let s;(s=e(o,i,t))!==!1&&(r[i]=s||o)}),Object.defineProperties(t,r)},dp=t=>{Ni(t,(e,n)=>{if(De(t)&&["arguments","caller","callee"].indexOf(n)!==-1)return!1;const r=t[n];if(De(r)){if(e.enumerable=!1,"writable"in e){e.writable=!1;return}e.set||(e.set=()=>{throw Error("Can not rewrite read-only method '"+n+"'")})}})},fp=(t,e)=>{const n={},r=o=>{o.forEach(i=>{n[i]=!0})};return wt(t)?r(t):r(String(t).split(e)),n},pp=()=>{},mp=(t,e)=>(t=+t,Number.isFinite(t)?t:e),_r="abcdefghijklmnopqrstuvwxyz",Di="0123456789",Mi={DIGIT:Di,ALPHA:_r,ALPHA_DIGIT:_r+_r.toUpperCase()+Di},hp=(t=16,e=Mi.ALPHA_DIGIT)=>{let n="";const{length:r}=e;for(;t--;)n+=e[Math.random()*r|0];return n};function gp(t){return!!(t&&De(t.append)&&t[Symbol.toStringTag]==="FormData"&&t[Symbol.iterator])}const yp=t=>{const e=new Array(10),n=(r,o)=>{if(En(r)){if(e.indexOf(r)>=0)return;if(!("toJSON"in r)){e[o]=r;const i=wt(r)?[]:{};return Yt(r,(s,c)=>{const a=n(s,o+1);!Jt(a)&&(i[c]=a)}),e[o]=void 0,i}}return r};return n(t,0)},bp=ze("AsyncFunction"),b={isArray:wt,isArrayBuffer:Oi,isBuffer:Hf,isFormData:Yf,isArrayBufferView:jf,isString:Vf,isNumber:Li,isBoolean:Kf,isObject:En,isPlainObject:Sn,isUndefined:Jt,isDate:zf,isFile:Wf,isBlob:qf,isRegExp:up,isFunction:De,isStream:Jf,isURLSearchParams:Xf,isTypedArray:ip,isFileList:Gf,forEach:Yt,merge:Sr,extend:Qf,trim:Zf,stripBOM:ep,inherits:tp,toFlatObject:np,kindOf:vn,kindOfTest:ze,endsWith:rp,toArray:op,forEachEntry:sp,matchAll:ap,isHTMLForm:lp,hasOwnProperty:$i,hasOwnProp:$i,reduceDescriptors:Ni,freezeMethods:dp,toObjectSet:fp,toCamelCase:cp,noop:pp,toFiniteNumber:mp,findKey:Bi,global:Ri,isContextDefined:Fi,ALPHABET:Mi,generateString:hp,isSpecCompliantForm:gp,toJSONObject:yp,isAsyncFn:bp,isThenable:t=>t&&(En(t)||De(t))&&De(t.then)&&De(t.catch)};function te(t,e,n,r,o){Error.call(this),Error.captureStackTrace?Error.captureStackTrace(this,this.constructor):this.stack=new Error().stack,this.message=t,this.name="AxiosError",e&&(this.code=e),n&&(this.config=n),r&&(this.request=r),o&&(this.response=o)}b.inherits(te,Error,{toJSON:function(){return{message:this.message,name:this.name,description:this.description,number:this.number,fileName:this.fileName,lineNumber:this.lineNumber,columnNumber:this.columnNumber,stack:this.stack,config:b.toJSONObject(this.config),code:this.code,status:this.response&&this.response.status?this.response.status:null}}});const Ui=te.prototype,Hi={};["ERR_BAD_OPTION_VALUE","ERR_BAD_OPTION","ECONNABORTED","ETIMEDOUT","ERR_NETWORK","ERR_FR_TOO_MANY_REDIRECTS","ERR_DEPRECATED","ERR_BAD_RESPONSE","ERR_BAD_REQUEST","ERR_CANCELED","ERR_NOT_SUPPORT","ERR_INVALID_URL"].forEach(t=>{Hi[t]={value:t}}),Object.defineProperties(te,Hi),Object.defineProperty(Ui,"isAxiosError",{value:!0}),te.from=(t,e,n,r,o,i)=>{const s=Object.create(Ui);return b.toFlatObject(t,s,function(a){return a!==Error.prototype},c=>c!=="isAxiosError"),te.call(s,t.message,e,n,r,o),s.cause=t,s.name=t.name,i&&Object.assign(s,i),s};const vp=null;function Cr(t){return b.isPlainObject(t)||b.isArray(t)}function ji(t){return b.endsWith(t,"[]")?t.slice(0,-2):t}function Vi(t,e,n){return t?t.concat(e).map(function(o,i){return o=ji(o),!n&&i?"["+o+"]":o}).join(n?".":""):e}function wp(t){return b.isArray(t)&&!t.some(Cr)}const Ep=b.toFlatObject(b,{},null,function(e){return/^is[A-Z]/.test(e)});function _n(t,e,n){if(!b.isObject(t))throw new TypeError("target must be an object");e=e||new FormData,n=b.toFlatObject(n,{metaTokens:!0,dots:!1,indexes:!1},!1,function(x,_){return!b.isUndefined(_[x])});const r=n.metaTokens,o=n.visitor||f,i=n.dots,s=n.indexes,a=(n.Blob||typeof Blob<"u"&&Blob)&&b.isSpecCompliantForm(e);if(!b.isFunction(o))throw new TypeError("visitor must be a function");function u(C){if(C===null)return"";if(b.isDate(C))return C.toISOString();if(!a&&b.isBlob(C))throw new te("Blob is not supported. Use a Buffer instead.");return b.isArrayBuffer(C)||b.isTypedArray(C)?a&&typeof Blob=="function"?new Blob([C]):Buffer.from(C):C}function f(C,x,_){let $=C;if(C&&!_&&typeof C=="object"){if(b.endsWith(x,"{}"))x=r?x:x.slice(0,-2),C=JSON.stringify(C);else if(b.isArray(C)&&wp(C)||(b.isFileList(C)||b.endsWith(x,"[]"))&&($=b.toArray(C)))return x=ji(x),$.forEach(function(V,pe){!(b.isUndefined(V)||V===null)&&e.append(s===!0?Vi([x],pe,i):s===null?x:x+"[]",u(V))}),!1}return Cr(C)?!0:(e.append(Vi(_,x,i),u(C)),!1)}const p=[],v=Object.assign(Ep,{defaultVisitor:f,convertValue:u,isVisitable:Cr});function w(C,x){if(!b.isUndefined(C)){if(p.indexOf(C)!==-1)throw Error("Circular reference detected in "+x.join("."));p.push(C),b.forEach(C,function($,q){(!(b.isUndefined($)||$===null)&&o.call(e,$,b.isString(q)?q.trim():q,x,v))===!0&&w($,x?x.concat(q):[q])}),p.pop()}}if(!b.isObject(t))throw new TypeError("data must be an object");return w(t),e}function Ki(t){const e={"!":"%21","'":"%27","(":"%28",")":"%29","~":"%7E","%20":"+","%00":"\0"};return encodeURIComponent(t).replace(/[!'()~]|%20|%00/g,function(r){return e[r]})}function Ar(t,e){this._pairs=[],t&&_n(t,this,e)}const zi=Ar.prototype;zi.append=function(e,n){this._pairs.push([e,n])},zi.toString=function(e){const n=e?function(r){return e.call(this,r,Ki)}:Ki;return this._pairs.map(function(o){return n(o[0])+"="+n(o[1])},"").join("&")};function Sp(t){return encodeURIComponent(t).replace(/%3A/gi,":").replace(/%24/g,"$").replace(/%2C/gi,",").replace(/%20/g,"+").replace(/%5B/gi,"[").replace(/%5D/gi,"]")}function Wi(t,e,n){if(!e)return t;const r=n&&n.encode||Sp,o=n&&n.serialize;let i;if(o?i=o(e,n):i=b.isURLSearchParams(e)?e.toString():new Ar(e,n).toString(r),i){const s=t.indexOf("#");s!==-1&&(t=t.slice(0,s)),t+=(t.indexOf("?")===-1?"?":"&")+i}return t}class qi{constructor(){this.handlers=[]}use(e,n,r){return this.handlers.push({fulfilled:e,rejected:n,synchronous:r?r.synchronous:!1,runWhen:r?r.runWhen:null}),this.handlers.length-1}eject(e){this.handlers[e]&&(this.handlers[e]=null)}clear(){this.handlers&&(this.handlers=[])}forEach(e){b.forEach(this.handlers,function(r){r!==null&&e(r)})}}const Gi={silentJSONParsing:!0,forcedJSONParsing:!0,clarifyTimeoutError:!1},_p={isBrowser:!0,classes:{URLSearchParams:typeof URLSearchParams<"u"?URLSearchParams:Ar,FormData:typeof FormData<"u"?FormData:null,Blob:typeof Blob<"u"?Blob:null},protocols:["http","https","file","blob","url","data"]},Ji=typeof window<"u"&&typeof document<"u",Cp=(t=>Ji&&["ReactNative","NativeScript","NS"].indexOf(t)<0)(typeof navigator<"u"&&navigator.product),Ap=typeof WorkerGlobalScope<"u"&&self instanceof WorkerGlobalScope&&typeof self.importScripts=="function",We={...Object.freeze(Object.defineProperty({__proto__:null,hasBrowserEnv:Ji,hasStandardBrowserEnv:Cp,hasStandardBrowserWebWorkerEnv:Ap},Symbol.toStringTag,{value:"Module"})),..._p};function kp(t,e){return _n(t,new We.classes.URLSearchParams,Object.assign({visitor:function(n,r,o,i){return We.isNode&&b.isBuffer(n)?(this.append(r,n.toString("base64")),!1):i.defaultVisitor.apply(this,arguments)}},e))}function xp(t){return b.matchAll(/\w+|\[(\w*)]/g,t).map(e=>e[0]==="[]"?"":e[1]||e[0])}function Ip(t){const e={},n=Object.keys(t);let r;const o=n.length;let i;for(r=0;r<o;r++)i=n[r],e[i]=t[i];return e}function Yi(t){function e(n,r,o,i){let s=n[i++];if(s==="__proto__")return!0;const c=Number.isFinite(+s),a=i>=n.length;return s=!s&&b.isArray(o)?o.length:s,a?(b.hasOwnProp(o,s)?o[s]=[o[s],r]:o[s]=r,!c):((!o[s]||!b.isObject(o[s]))&&(o[s]=[]),e(n,r,o[s],i)&&b.isArray(o[s])&&(o[s]=Ip(o[s])),!c)}if(b.isFormData(t)&&b.isFunction(t.entries)){const n={};return b.forEachEntry(t,(r,o)=>{e(xp(r),o,n,0)}),n}return null}function Pp(t,e,n){if(b.isString(t))try{return(e||JSON.parse)(t),b.trim(t)}catch(r){if(r.name!=="SyntaxError")throw r}return(n||JSON.stringify)(t)}const kr={transitional:Gi,adapter:["xhr","http"],transformRequest:[function(e,n){const r=n.getContentType()||"",o=r.indexOf("application/json")>-1,i=b.isObject(e);if(i&&b.isHTMLForm(e)&&(e=new FormData(e)),b.isFormData(e))return o&&o?JSON.stringify(Yi(e)):e;if(b.isArrayBuffer(e)||b.isBuffer(e)||b.isStream(e)||b.isFile(e)||b.isBlob(e))return e;if(b.isArrayBufferView(e))return e.buffer;if(b.isURLSearchParams(e))return n.setContentType("application/x-www-form-urlencoded;charset=utf-8",!1),e.toString();let c;if(i){if(r.indexOf("application/x-www-form-urlencoded")>-1)return kp(e,this.formSerializer).toString();if((c=b.isFileList(e))||r.indexOf("multipart/form-data")>-1){const a=this.env&&this.env.FormData;return _n(c?{"files[]":e}:e,a&&new a,this.formSerializer)}}return i||o?(n.setContentType("application/json",!1),Pp(e)):e}],transformResponse:[function(e){const n=this.transitional||kr.transitional,r=n&&n.forcedJSONParsing,o=this.responseType==="json";if(e&&b.isString(e)&&(r&&!this.responseType||o)){const s=!(n&&n.silentJSONParsing)&&o;try{return JSON.parse(e)}catch(c){if(s)throw c.name==="SyntaxError"?te.from(c,te.ERR_BAD_RESPONSE,this,null,this.response):c}}return e}],timeout:0,xsrfCookieName:"XSRF-TOKEN",xsrfHeaderName:"X-XSRF-TOKEN",maxContentLength:-1,maxBodyLength:-1,env:{FormData:We.classes.FormData,Blob:We.classes.Blob},validateStatus:function(e){return e>=200&&e<300},headers:{common:{Accept:"application/json, text/plain, */*","Content-Type":void 0}}};b.forEach(["delete","get","head","post","put","patch"],t=>{kr.headers[t]={}});const xr=kr,Tp=b.toObjectSet(["age","authorization","content-length","content-type","etag","expires","from","host","if-modified-since","if-unmodified-since","last-modified","location","max-forwards","proxy-authorization","referer","retry-after","user-agent"]),Op=t=>{const e={};let n,r,o;return t&&t.split(`
160
+ `).forEach(function(s){o=s.indexOf(":"),n=s.substring(0,o).trim().toLowerCase(),r=s.substring(o+1).trim(),!(!n||e[n]&&Tp[n])&&(n==="set-cookie"?e[n]?e[n].push(r):e[n]=[r]:e[n]=e[n]?e[n]+", "+r:r)}),e},Xi=Symbol("internals");function Xt(t){return t&&String(t).trim().toLowerCase()}function Cn(t){return t===!1||t==null?t:b.isArray(t)?t.map(Cn):String(t)}function Lp(t){const e=Object.create(null),n=/([^\s,;=]+)\s*(?:=\s*([^,;]+))?/g;let r;for(;r=n.exec(t);)e[r[1]]=r[2];return e}const Bp=t=>/^[-_a-zA-Z0-9^`|~,!#$%&'*+.]+$/.test(t.trim());function Ir(t,e,n,r,o){if(b.isFunction(r))return r.call(this,e,n);if(o&&(e=n),!!b.isString(e)){if(b.isString(r))return e.indexOf(r)!==-1;if(b.isRegExp(r))return r.test(e)}}function Rp(t){return t.trim().toLowerCase().replace(/([a-z\d])(\w*)/g,(e,n,r)=>n.toUpperCase()+r)}function Fp(t,e){const n=b.toCamelCase(" "+e);["get","set","has"].forEach(r=>{Object.defineProperty(t,r+n,{value:function(o,i,s){return this[r].call(this,e,o,i,s)},configurable:!0})})}class An{constructor(e){e&&this.set(e)}set(e,n,r){const o=this;function i(c,a,u){const f=Xt(a);if(!f)throw new Error("header name must be a non-empty string");const p=b.findKey(o,f);(!p||o[p]===void 0||u===!0||u===void 0&&o[p]!==!1)&&(o[p||a]=Cn(c))}const s=(c,a)=>b.forEach(c,(u,f)=>i(u,f,a));return b.isPlainObject(e)||e instanceof this.constructor?s(e,n):b.isString(e)&&(e=e.trim())&&!Bp(e)?s(Op(e),n):e!=null&&i(n,e,r),this}get(e,n){if(e=Xt(e),e){const r=b.findKey(this,e);if(r){const o=this[r];if(!n)return o;if(n===!0)return Lp(o);if(b.isFunction(n))return n.call(this,o,r);if(b.isRegExp(n))return n.exec(o);throw new TypeError("parser must be boolean|regexp|function")}}}has(e,n){if(e=Xt(e),e){const r=b.findKey(this,e);return!!(r&&this[r]!==void 0&&(!n||Ir(this,this[r],r,n)))}return!1}delete(e,n){const r=this;let o=!1;function i(s){if(s=Xt(s),s){const c=b.findKey(r,s);c&&(!n||Ir(r,r[c],c,n))&&(delete r[c],o=!0)}}return b.isArray(e)?e.forEach(i):i(e),o}clear(e){const n=Object.keys(this);let r=n.length,o=!1;for(;r--;){const i=n[r];(!e||Ir(this,this[i],i,e,!0))&&(delete this[i],o=!0)}return o}normalize(e){const n=this,r={};return b.forEach(this,(o,i)=>{const s=b.findKey(r,i);if(s){n[s]=Cn(o),delete n[i];return}const c=e?Rp(i):String(i).trim();c!==i&&delete n[i],n[c]=Cn(o),r[c]=!0}),this}concat(...e){return this.constructor.concat(this,...e)}toJSON(e){const n=Object.create(null);return b.forEach(this,(r,o)=>{r!=null&&r!==!1&&(n[o]=e&&b.isArray(r)?r.join(", "):r)}),n}[Symbol.iterator](){return Object.entries(this.toJSON())[Symbol.iterator]()}toString(){return Object.entries(this.toJSON()).map(([e,n])=>e+": "+n).join(`
161
+ `)}get[Symbol.toStringTag](){return"AxiosHeaders"}static from(e){return e instanceof this?e:new this(e)}static concat(e,...n){const r=new this(e);return n.forEach(o=>r.set(o)),r}static accessor(e){const r=(this[Xi]=this[Xi]={accessors:{}}).accessors,o=this.prototype;function i(s){const c=Xt(s);r[c]||(Fp(o,s),r[c]=!0)}return b.isArray(e)?e.forEach(i):i(e),this}}An.accessor(["Content-Type","Content-Length","Accept","Accept-Encoding","User-Agent","Authorization"]),b.reduceDescriptors(An.prototype,({value:t},e)=>{let n=e[0].toUpperCase()+e.slice(1);return{get:()=>t,set(r){this[n]=r}}}),b.freezeMethods(An);const Je=An;function Pr(t,e){const n=this||xr,r=e||n,o=Je.from(r.headers);let i=r.data;return b.forEach(t,function(c){i=c.call(n,i,o.normalize(),e?e.status:void 0)}),o.normalize(),i}function Zi(t){return!!(t&&t.__CANCEL__)}function Zt(t,e,n){te.call(this,t??"canceled",te.ERR_CANCELED,e,n),this.name="CanceledError"}b.inherits(Zt,te,{__CANCEL__:!0});function $p(t,e,n){const r=n.config.validateStatus;!n.status||!r||r(n.status)?t(n):e(new te("Request failed with status code "+n.status,[te.ERR_BAD_REQUEST,te.ERR_BAD_RESPONSE][Math.floor(n.status/100)-4],n.config,n.request,n))}const Np=We.hasStandardBrowserEnv?{write(t,e,n,r,o,i){const s=[t+"="+encodeURIComponent(e)];b.isNumber(n)&&s.push("expires="+new Date(n).toGMTString()),b.isString(r)&&s.push("path="+r),b.isString(o)&&s.push("domain="+o),i===!0&&s.push("secure"),document.cookie=s.join("; ")},read(t){const e=document.cookie.match(new RegExp("(^|;\\s*)("+t+")=([^;]*)"));return e?decodeURIComponent(e[3]):null},remove(t){this.write(t,"",Date.now()-864e5)}}:{write(){},read(){return null},remove(){}};function Dp(t){return/^([a-z][a-z\d+\-.]*:)?\/\//i.test(t)}function Mp(t,e){return e?t.replace(/\/?\/$/,"")+"/"+e.replace(/^\/+/,""):t}function Qi(t,e){return t&&!Dp(e)?Mp(t,e):e}const Up=We.hasStandardBrowserEnv?function(){const e=/(msie|trident)/i.test(navigator.userAgent),n=document.createElement("a");let r;function o(i){let s=i;return e&&(n.setAttribute("href",s),s=n.href),n.setAttribute("href",s),{href:n.href,protocol:n.protocol?n.protocol.replace(/:$/,""):"",host:n.host,search:n.search?n.search.replace(/^\?/,""):"",hash:n.hash?n.hash.replace(/^#/,""):"",hostname:n.hostname,port:n.port,pathname:n.pathname.charAt(0)==="/"?n.pathname:"/"+n.pathname}}return r=o(window.location.href),function(s){const c=b.isString(s)?o(s):s;return c.protocol===r.protocol&&c.host===r.host}}():function(){return function(){return!0}}();function Hp(t){const e=/^([-+\w]{1,25})(:?\/\/|:)/.exec(t);return e&&e[1]||""}function jp(t,e){t=t||10;const n=new Array(t),r=new Array(t);let o=0,i=0,s;return e=e!==void 0?e:1e3,function(a){const u=Date.now(),f=r[i];s||(s=u),n[o]=a,r[o]=u;let p=i,v=0;for(;p!==o;)v+=n[p++],p=p%t;if(o=(o+1)%t,o===i&&(i=(i+1)%t),u-s<e)return;const w=f&&u-f;return w?Math.round(v*1e3/w):void 0}}function es(t,e){let n=0;const r=jp(50,250);return o=>{const i=o.loaded,s=o.lengthComputable?o.total:void 0,c=i-n,a=r(c),u=i<=s;n=i;const f={loaded:i,total:s,progress:s?i/s:void 0,bytes:c,rate:a||void 0,estimated:a&&s&&u?(s-i)/a:void 0,event:o};f[e?"download":"upload"]=!0,t(f)}}const Tr={http:vp,xhr:typeof XMLHttpRequest<"u"&&function(t){return new Promise(function(n,r){let o=t.data;const i=Je.from(t.headers).normalize();let{responseType:s,withXSRFToken:c}=t,a;function u(){t.cancelToken&&t.cancelToken.unsubscribe(a),t.signal&&t.signal.removeEventListener("abort",a)}let f;if(b.isFormData(o)){if(We.hasStandardBrowserEnv||We.hasStandardBrowserWebWorkerEnv)i.setContentType(!1);else if((f=i.getContentType())!==!1){const[x,..._]=f?f.split(";").map($=>$.trim()).filter(Boolean):[];i.setContentType([x||"multipart/form-data",..._].join("; "))}}let p=new XMLHttpRequest;if(t.auth){const x=t.auth.username||"",_=t.auth.password?unescape(encodeURIComponent(t.auth.password)):"";i.set("Authorization","Basic "+btoa(x+":"+_))}const v=Qi(t.baseURL,t.url);p.open(t.method.toUpperCase(),Wi(v,t.params,t.paramsSerializer),!0),p.timeout=t.timeout;function w(){if(!p)return;const x=Je.from("getAllResponseHeaders"in p&&p.getAllResponseHeaders()),$={data:!s||s==="text"||s==="json"?p.responseText:p.response,status:p.status,statusText:p.statusText,headers:x,config:t,request:p};$p(function(V){n(V),u()},function(V){r(V),u()},$),p=null}if("onloadend"in p?p.onloadend=w:p.onreadystatechange=function(){!p||p.readyState!==4||p.status===0&&!(p.responseURL&&p.responseURL.indexOf("file:")===0)||setTimeout(w)},p.onabort=function(){p&&(r(new te("Request aborted",te.ECONNABORTED,t,p)),p=null)},p.onerror=function(){r(new te("Network Error",te.ERR_NETWORK,t,p)),p=null},p.ontimeout=function(){let _=t.timeout?"timeout of "+t.timeout+"ms exceeded":"timeout exceeded";const $=t.transitional||Gi;t.timeoutErrorMessage&&(_=t.timeoutErrorMessage),r(new te(_,$.clarifyTimeoutError?te.ETIMEDOUT:te.ECONNABORTED,t,p)),p=null},We.hasStandardBrowserEnv&&(c&&b.isFunction(c)&&(c=c(t)),c||c!==!1&&Up(v))){const x=t.xsrfHeaderName&&t.xsrfCookieName&&Np.read(t.xsrfCookieName);x&&i.set(t.xsrfHeaderName,x)}o===void 0&&i.setContentType(null),"setRequestHeader"in p&&b.forEach(i.toJSON(),function(_,$){p.setRequestHeader($,_)}),b.isUndefined(t.withCredentials)||(p.withCredentials=!!t.withCredentials),s&&s!=="json"&&(p.responseType=t.responseType),typeof t.onDownloadProgress=="function"&&p.addEventListener("progress",es(t.onDownloadProgress,!0)),typeof t.onUploadProgress=="function"&&p.upload&&p.upload.addEventListener("progress",es(t.onUploadProgress)),(t.cancelToken||t.signal)&&(a=x=>{p&&(r(!x||x.type?new Zt(null,t,p):x),p.abort(),p=null)},t.cancelToken&&t.cancelToken.subscribe(a),t.signal&&(t.signal.aborted?a():t.signal.addEventListener("abort",a)));const C=Hp(v);if(C&&We.protocols.indexOf(C)===-1){r(new te("Unsupported protocol "+C+":",te.ERR_BAD_REQUEST,t));return}p.send(o||null)})}};b.forEach(Tr,(t,e)=>{if(t){try{Object.defineProperty(t,"name",{value:e})}catch{}Object.defineProperty(t,"adapterName",{value:e})}});const ts=t=>`- ${t}`,Vp=t=>b.isFunction(t)||t===null||t===!1,ns={getAdapter:t=>{t=b.isArray(t)?t:[t];const{length:e}=t;let n,r;const o={};for(let i=0;i<e;i++){n=t[i];let s;if(r=n,!Vp(n)&&(r=Tr[(s=String(n)).toLowerCase()],r===void 0))throw new te(`Unknown adapter '${s}'`);if(r)break;o[s||"#"+i]=r}if(!r){const i=Object.entries(o).map(([c,a])=>`adapter ${c} `+(a===!1?"is not supported by the environment":"is not available in the build"));let s=e?i.length>1?`since :
162
+ `+i.map(ts).join(`
163
+ `):" "+ts(i[0]):"as no adapter specified";throw new te("There is no suitable adapter to dispatch the request "+s,"ERR_NOT_SUPPORT")}return r},adapters:Tr};function Or(t){if(t.cancelToken&&t.cancelToken.throwIfRequested(),t.signal&&t.signal.aborted)throw new Zt(null,t)}function rs(t){return Or(t),t.headers=Je.from(t.headers),t.data=Pr.call(t,t.transformRequest),["post","put","patch"].indexOf(t.method)!==-1&&t.headers.setContentType("application/x-www-form-urlencoded",!1),ns.getAdapter(t.adapter||xr.adapter)(t).then(function(r){return Or(t),r.data=Pr.call(t,t.transformResponse,r),r.headers=Je.from(r.headers),r},function(r){return Zi(r)||(Or(t),r&&r.response&&(r.response.data=Pr.call(t,t.transformResponse,r.response),r.response.headers=Je.from(r.response.headers))),Promise.reject(r)})}const os=t=>t instanceof Je?t.toJSON():t;function Et(t,e){e=e||{};const n={};function r(u,f,p){return b.isPlainObject(u)&&b.isPlainObject(f)?b.merge.call({caseless:p},u,f):b.isPlainObject(f)?b.merge({},f):b.isArray(f)?f.slice():f}function o(u,f,p){if(b.isUndefined(f)){if(!b.isUndefined(u))return r(void 0,u,p)}else return r(u,f,p)}function i(u,f){if(!b.isUndefined(f))return r(void 0,f)}function s(u,f){if(b.isUndefined(f)){if(!b.isUndefined(u))return r(void 0,u)}else return r(void 0,f)}function c(u,f,p){if(p in e)return r(u,f);if(p in t)return r(void 0,u)}const a={url:i,method:i,data:i,baseURL:s,transformRequest:s,transformResponse:s,paramsSerializer:s,timeout:s,timeoutMessage:s,withCredentials:s,withXSRFToken:s,adapter:s,responseType:s,xsrfCookieName:s,xsrfHeaderName:s,onUploadProgress:s,onDownloadProgress:s,decompress:s,maxContentLength:s,maxBodyLength:s,beforeRedirect:s,transport:s,httpAgent:s,httpsAgent:s,cancelToken:s,socketPath:s,responseEncoding:s,validateStatus:c,headers:(u,f)=>o(os(u),os(f),!0)};return b.forEach(Object.keys(Object.assign({},t,e)),function(f){const p=a[f]||o,v=p(t[f],e[f],f);b.isUndefined(v)&&p!==c||(n[f]=v)}),n}const is="1.6.5",Lr={};["object","boolean","number","function","string","symbol"].forEach((t,e)=>{Lr[t]=function(r){return typeof r===t||"a"+(e<1?"n ":" ")+t}});const ss={};Lr.transitional=function(e,n,r){function o(i,s){return"[Axios v"+is+"] Transitional option '"+i+"'"+s+(r?". "+r:"")}return(i,s,c)=>{if(e===!1)throw new te(o(s," has been removed"+(n?" in "+n:"")),te.ERR_DEPRECATED);return n&&!ss[s]&&(ss[s]=!0,console.warn(o(s," has been deprecated since v"+n+" and will be removed in the near future"))),e?e(i,s,c):!0}};function Kp(t,e,n){if(typeof t!="object")throw new te("options must be an object",te.ERR_BAD_OPTION_VALUE);const r=Object.keys(t);let o=r.length;for(;o-- >0;){const i=r[o],s=e[i];if(s){const c=t[i],a=c===void 0||s(c,i,t);if(a!==!0)throw new te("option "+i+" must be "+a,te.ERR_BAD_OPTION_VALUE);continue}if(n!==!0)throw new te("Unknown option "+i,te.ERR_BAD_OPTION)}}const Br={assertOptions:Kp,validators:Lr},nt=Br.validators;class kn{constructor(e){this.defaults=e,this.interceptors={request:new qi,response:new qi}}request(e,n){typeof e=="string"?(n=n||{},n.url=e):n=e||{},n=Et(this.defaults,n);const{transitional:r,paramsSerializer:o,headers:i}=n;r!==void 0&&Br.assertOptions(r,{silentJSONParsing:nt.transitional(nt.boolean),forcedJSONParsing:nt.transitional(nt.boolean),clarifyTimeoutError:nt.transitional(nt.boolean)},!1),o!=null&&(b.isFunction(o)?n.paramsSerializer={serialize:o}:Br.assertOptions(o,{encode:nt.function,serialize:nt.function},!0)),n.method=(n.method||this.defaults.method||"get").toLowerCase();let s=i&&b.merge(i.common,i[n.method]);i&&b.forEach(["delete","get","head","post","put","patch","common"],C=>{delete i[C]}),n.headers=Je.concat(s,i);const c=[];let a=!0;this.interceptors.request.forEach(function(x){typeof x.runWhen=="function"&&x.runWhen(n)===!1||(a=a&&x.synchronous,c.unshift(x.fulfilled,x.rejected))});const u=[];this.interceptors.response.forEach(function(x){u.push(x.fulfilled,x.rejected)});let f,p=0,v;if(!a){const C=[rs.bind(this),void 0];for(C.unshift.apply(C,c),C.push.apply(C,u),v=C.length,f=Promise.resolve(n);p<v;)f=f.then(C[p++],C[p++]);return f}v=c.length;let w=n;for(p=0;p<v;){const C=c[p++],x=c[p++];try{w=C(w)}catch(_){x.call(this,_);break}}try{f=rs.call(this,w)}catch(C){return Promise.reject(C)}for(p=0,v=u.length;p<v;)f=f.then(u[p++],u[p++]);return f}getUri(e){e=Et(this.defaults,e);const n=Qi(e.baseURL,e.url);return Wi(n,e.params,e.paramsSerializer)}}b.forEach(["delete","get","head","options"],function(e){kn.prototype[e]=function(n,r){return this.request(Et(r||{},{method:e,url:n,data:(r||{}).data}))}}),b.forEach(["post","put","patch"],function(e){function n(r){return function(i,s,c){return this.request(Et(c||{},{method:e,headers:r?{"Content-Type":"multipart/form-data"}:{},url:i,data:s}))}}kn.prototype[e]=n(),kn.prototype[e+"Form"]=n(!0)});const xn=kn;class Rr{constructor(e){if(typeof e!="function")throw new TypeError("executor must be a function.");let n;this.promise=new Promise(function(i){n=i});const r=this;this.promise.then(o=>{if(!r._listeners)return;let i=r._listeners.length;for(;i-- >0;)r._listeners[i](o);r._listeners=null}),this.promise.then=o=>{let i;const s=new Promise(c=>{r.subscribe(c),i=c}).then(o);return s.cancel=function(){r.unsubscribe(i)},s},e(function(i,s,c){r.reason||(r.reason=new Zt(i,s,c),n(r.reason))})}throwIfRequested(){if(this.reason)throw this.reason}subscribe(e){if(this.reason){e(this.reason);return}this._listeners?this._listeners.push(e):this._listeners=[e]}unsubscribe(e){if(!this._listeners)return;const n=this._listeners.indexOf(e);n!==-1&&this._listeners.splice(n,1)}static source(){let e;return{token:new Rr(function(o){e=o}),cancel:e}}}const zp=Rr;function Wp(t){return function(n){return t.apply(null,n)}}function qp(t){return b.isObject(t)&&t.isAxiosError===!0}const Fr={Continue:100,SwitchingProtocols:101,Processing:102,EarlyHints:103,Ok:200,Created:201,Accepted:202,NonAuthoritativeInformation:203,NoContent:204,ResetContent:205,PartialContent:206,MultiStatus:207,AlreadyReported:208,ImUsed:226,MultipleChoices:300,MovedPermanently:301,Found:302,SeeOther:303,NotModified:304,UseProxy:305,Unused:306,TemporaryRedirect:307,PermanentRedirect:308,BadRequest:400,Unauthorized:401,PaymentRequired:402,Forbidden:403,NotFound:404,MethodNotAllowed:405,NotAcceptable:406,ProxyAuthenticationRequired:407,RequestTimeout:408,Conflict:409,Gone:410,LengthRequired:411,PreconditionFailed:412,PayloadTooLarge:413,UriTooLong:414,UnsupportedMediaType:415,RangeNotSatisfiable:416,ExpectationFailed:417,ImATeapot:418,MisdirectedRequest:421,UnprocessableEntity:422,Locked:423,FailedDependency:424,TooEarly:425,UpgradeRequired:426,PreconditionRequired:428,TooManyRequests:429,RequestHeaderFieldsTooLarge:431,UnavailableForLegalReasons:451,InternalServerError:500,NotImplemented:501,BadGateway:502,ServiceUnavailable:503,GatewayTimeout:504,HttpVersionNotSupported:505,VariantAlsoNegotiates:506,InsufficientStorage:507,LoopDetected:508,NotExtended:510,NetworkAuthenticationRequired:511};Object.entries(Fr).forEach(([t,e])=>{Fr[e]=t});const Gp=Fr;function as(t){const e=new xn(t),n=Ti(xn.prototype.request,e);return b.extend(n,xn.prototype,e,{allOwnKeys:!0}),b.extend(n,e,null,{allOwnKeys:!0}),n.create=function(o){return as(Et(t,o))},n}const ue=as(xr);ue.Axios=xn,ue.CanceledError=Zt,ue.CancelToken=zp,ue.isCancel=Zi,ue.VERSION=is,ue.toFormData=_n,ue.AxiosError=te,ue.Cancel=ue.CanceledError,ue.all=function(e){return Promise.all(e)},ue.spread=Wp,ue.isAxiosError=qp,ue.mergeConfig=Et,ue.AxiosHeaders=Je,ue.formToJSON=t=>Yi(b.isHTMLForm(t)?new FormData(t):t),ue.getAdapter=ns.getAdapter,ue.HttpStatusCode=Gp,ue.default=ue;class ls{constructor(e){Me(this,"keycloak");Me(this,"axios");Me(this,"fileName","silent-login.html");this.keycloak=e,this.axios=ue.create(),this.axios.defaults.baseURL="https://localhost:5001/api",this.axios.defaults.headers.common["content-type"]="application/json",this.axios.defaults.timeout=1e3*60*5,this.axios.interceptors.request.use(async n=>{await this.SilentLogin();const r=this.keycloak.token;return n.headers.Authorization=`Bearer ${r}`,n})}ParseAppResult(e){try{const n=typeof e.hasSuccess=="boolean",r=typeof e.hasError=="boolean",o=typeof e.httpStatusCode=="number",i=Array.isArray(e.errors);return n&&r&&o&&i?e:null}catch{return null}}HandleThen(e){const n=new wr,r=this.ParseAppResult(e.data);return r===null?(n.value=e.data,n):r.hasError?(r.errors.forEach(o=>n.WithError(o)),n.httpStatusCode=r.httpStatusCode,n):(n.value=e.data.value,n)}HandleCatch(e){var o;const n=new wr,r=this.ParseAppResult((o=e.response)==null?void 0:o.data);return r===null?n.WithError(e.message):(n.WithErrors(r.errors),n.httpStatusCode=r.httpStatusCode),n}async SilentLogin(){return new Promise(async e=>{if(!this.isTokenExpired){e(!0);return}const n=this.GenerateIframe(),r=o=>{if(document.body.removeChild(n),window.removeEventListener("message",r),o.origin!==location.origin){e(!1);return}const i=o.data.action,s=o.data.code,c=o.data.state,a=o.data.error;if(i!=="silent-login-iframe-result"||a==="login_required"||!s){e(!1);return}const u=new XMLHttpRequest;u.open("POST",this.tokenExchangeUrl,!0),u.setRequestHeader("Content-type","application/x-www-form-urlencoded"),u.onreadystatechange=()=>{if(u.readyState===4){if(u.status===200){const f=JSON.parse(u.responseText);this.keycloak.setToken(f.access_token,null,f.id_token,new Date().getTime()),e(!0);return}e(!1)}},u.send(this.TokenExchangeParams(s,c))};window.addEventListener("message",r)}).then(e=>(e||(this.keycloak.clearToken(),this.keycloak.login()),e))}GetCodeVerifierFromState(e){const n=`kc-callback-${e}`,r=localStorage.getItem(n);if(r)return localStorage.removeItem(n),JSON.parse(r).pkceCodeVerifier}TokenExchangeParams(e,n){let r=`code=${e}&grant_type=authorization_code`;return r+=`&client_id=${encodeURIComponent(this.keycloak.clientId)}`,r+=`&redirect_uri=${this.silentLoginRedirectUrl}`,r+=`&code_verifier=${this.GetCodeVerifierFromState(n)}`,r}GenerateIframe(){const e=document.createElement("iframe");return e.src=this.keycloak.createLoginUrl({prompt:"none",redirectUri:this.silentLoginRedirectUrl})??"",document.body.appendChild(e),e}get silentLoginRedirectUrl(){return`${location.origin}/${this.fileName}`}get tokenExchangeUrl(){return`${this.keycloak.authServerUrl}/realms/${this.keycloak.realm}/protocol/openid-connect/token`}get isTokenExpired(){const e=this.keycloak.tokenParsed,n=e?e.exp:null;return!e||!n?!0:n-Math.ceil(new Date().getTime()/1e3)+(this.keycloak.timeSkew??0)<10}}const Jp=t=>new ls(t);or.SetInitialTheme(),ne.AppResult=wr,ne.AxiosClient=ls,ne.SfButton=zr,ne.SfContent=Au,ne.SfDrawer=Kr,ne.SfIcon=Qe,ne.SfLayout=wu,ne.SfMessage=Bu,ne.SfNavMenuLink=_u,ne.SfPanelMenu=Ef,ne.SfTabNavigation=Ou,ne.SfTooltip=On,ne.UseAlertService=tu,ne.UseAuthService=Mf,ne.UseAxiosClient=Jp,ne.UseConfirmService=Yo,ne.UseNavMenuService=Tn,Object.defineProperty(ne,Symbol.toStringTag,{value:"Module"})});
82
164
  //# sourceMappingURL=sf.prefeiturasp.vuecomponents.umd.js.map