@dcodegroup-au/dsg-vue 1.0.10-next → 1.0.11-next

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/dsg-vue.cjs CHANGED
@@ -1,4 +1,4 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const M=require("./DsgTablePerPage.vue_vue_type_style_index_0_lang-DQk8doWV.cjs"),f=require("vue"),Ha=require("./DsgLabel.vue_vue_type_style_index_0_lang-BTfTmByq.cjs"),It=f.defineComponent({__name:"DsgMiscIcon",props:{theme:{default:"brand"},type:{default:"light-outline"},size:{default:"lg"},icon:{}},setup(t){return(e,r)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(`
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const M=require("./DsgTablePerPage.vue_vue_type_style_index_0_lang-CX6n9ht7.cjs"),f=require("vue"),Ha=require("./DsgLabel.vue_vue_type_style_index_0_lang-BTfTmByq.cjs"),It=f.defineComponent({__name:"DsgMiscIcon",props:{theme:{default:"brand"},type:{default:"light-outline"},size:{default:"lg"},icon:{}},setup(t){return(e,r)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(`
2
2
  dsg-misc-icon
3
3
  dsg-misc-icon--${t.theme}
4
4
  dsg-misc-icon--${t.type}
@@ -14,17 +14,17 @@
14
14
  </clipPath>
15
15
  </defs>
16
16
  </svg>
17
- `,Ya=["href","title"],Ka={class:"dsg-avatar__image-wrapper",tabindex:"0",ref:"avatarImageWrapperEl"},Za=["src","alt"],qa={key:1,class:"dsg-avatar__initials"},Qa={class:"dsg-avatar__status"},Ja={key:0,class:"dsg-avatar__activity"},eo=["innerHTML"],to={key:2,class:"dsg-avatar__logo"},ro=["src","alt"],no={key:0,class:"dsg-avatar__info"},io={class:"dsg-avatar__title"},ao={class:"dsg-avatar__subtext"},rr=f.defineComponent({__name:"DsgAvatar",props:{profileUri:{default:""},fullName:{default:""},size:{default:"md"},theme:{default:"activity"},isOnline:{type:Boolean,default:!1},uri:{default:()=>{}},companyLogoUri:{default:()=>{}},preventDefault:{type:Boolean,default:!1},title:{default:""},subText:{default:""},noFocus:{type:Boolean,default:!1}},emits:["avatar-clicked","before-change-status","after-change-status"],setup(t,{expose:e,emit:r}){["profile-photo","profile-photo-verified"].indexOf(t.theme)!==-1&&(["sm","md","lg"].indexOf(t.size)===-1&&new M.DsgPropSyntaxWarning("DsgAvatar: The 'profile-photo' theme only supports the 'sm', 'md', and 'lg' sizes."),(t.fullName||t.title||t.subText)&&new M.DsgWarning("DsgAvatar: The 'profile-photo' theme will not display the 'title' or 'subText' props.")),t.theme==="logo"&&!t.companyLogoUri&&new M.DsgPropSyntaxWarning("DsgAvatar: The 'logo' theme requires a 'companyLogoUri' prop."),["activity","verified","logo"].indexOf(t.theme)!==-1&&t.title?.length&&t.subText?.length&&["xs","sm","md","lg","xl","2xl"].indexOf(t.size)===-1&&new M.DsgPropSyntaxWarning("DsgAvatar: The 'activity', 'verified', and 'logo' themes only support the 'xs', 'sm', 'md', 'lg', and 'xl' sizes when 'title' and 'subText' are provided."),t.theme==="tile"&&!t.title?.length&&!t.fullName&&new M.DsgPropSyntaxWarning("DsgAvatar: The 'tile' theme requires either 'title' or 'fullName' prop."),t.size==="xxs"&&(t.title?.length||t.subText?.length)&&new M.DsgPropSyntaxWarning("DsgAvatar: The 'xxs' size does not support the 'title' or 'subText' props.");const n=d=>{const v=d.split(" ");return(v[0].charAt(0)+v[v.length-1].charAt(0)).toUpperCase()},i=()=>t.fullName?"Avatar of "+t.fullName:"Avatar",a=r,o=f.ref(!1),s=d=>{a("before-change-status",o.value,d),o.value=d,a("after-change-status",o.value)},c=f.useTemplateRef("avatarImageWrapperEl"),u=d=>{t.preventDefault||(a("avatar-clicked",d),c.value&&!t.uri&&c.value.focus())};return e({setUserActiveStatus:s,toggleFocus:d=>{c.value&&(d?c.value.focus():c.value.blur())}}),(d,v)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(["dsg-avatar",`dsg-avatar--${t.size}`,`dsg-avatar--${t.theme}`,`dsg-avatar--${t.isOnline?"online":"offline"}`,`dsg-avatar--${t.title?.length?"has-info":"no-info"}`,`dsg-avatar--${t.uri?"has-link":"no-link"}`,`dsg-avatar--${t.noFocus?"no-focus":"focus"}`,`dsg-avatar--${["profile-photo","profile-photo-verified"].indexOf(t.theme)!==-1?"profile-photo":"non-profile-photo"}`])},[f.createElementVNode("a",{class:"dsg-avatar__link",href:t.uri,title:i(),target:"_blank",ref:"avatarLink",onClick:u},[f.createElementVNode("div",Ka,[f.renderSlot(d.$slots,"dsg-avatar--background",{},()=>[t.profileUri?(f.openBlock(),f.createElementBlock("img",{key:0,class:"dsg-avatar__profile-image",src:t.profileUri,alt:i()},null,8,Za)):f.createCommentVNode("",!0),!t.profileUri&&t.fullName?(f.openBlock(),f.createElementBlock("span",qa,f.toDisplayString(n(t.fullName)),1)):f.createCommentVNode("",!0),!t.profileUri&&!t.fullName?(f.openBlock(),f.createBlock(M._sfc_main,{key:2,class:"dsg-avatar__user-icon",icon:"user-01",size:t.size},null,8,["size"])):f.createCommentVNode("",!0)]),["tile"].indexOf(t.theme)===-1?f.renderSlot(d.$slots,"dsg-avatar--status",{key:0},()=>[f.createElementVNode("div",Qa,[t.theme==="activity"&&t.isOnline?(f.openBlock(),f.createElementBlock("span",Ja)):f.createCommentVNode("",!0),["verified","profile-photo-verified"].indexOf(t.theme)!==-1?(f.openBlock(),f.createElementBlock("span",{key:1,class:"dsg-avatar__verified",innerHTML:f.unref(ja)},null,8,eo)):f.createCommentVNode("",!0),t.theme==="logo"?(f.openBlock(),f.createElementBlock("span",to,[f.createElementVNode("img",{src:t.companyLogoUri,alt:i(),class:"dsg-avatar__company-logo"},null,8,ro)])):f.createCommentVNode("",!0)])]):f.createCommentVNode("",!0)],512),t.title?.length||t.theme==="tile"&&(t.title?.length||t.fullName)?(f.openBlock(),f.createElementBlock("div",no,[t.title?.length||t.theme==="tile"&&(t.title?.length||t.fullName)?f.renderSlot(d.$slots,"dsg-avatar--title",{key:0},()=>[f.createElementVNode("h3",io,f.toDisplayString(t.title?.length?t.title:t.fullName),1)]):f.createCommentVNode("",!0),t.subText?.length?f.renderSlot(d.$slots,"dsg-avatar--subtext",{key:1},()=>[f.createElementVNode("p",ao,f.toDisplayString(t.subText),1)]):f.createCommentVNode("",!0)])):f.createCommentVNode("",!0)],8,Ya)],2))}}),ur={TOP_LEFT:"top-left",TOP_RIGHT:"top-right",TOP_CENTER:"top-center",BOTTOM_LEFT:"bottom-left",BOTTOM_RIGHT:"bottom-right",BOTTOM_CENTER:"bottom-center"},Dt={LIGHT:"light",DARK:"dark",COLORED:"colored",AUTO:"auto"},Se={INFO:"info",SUCCESS:"success",WARNING:"warning",ERROR:"error",DEFAULT:"default"},oo={BOUNCE:"bounce",SLIDE:"slide",FLIP:"flip",ZOOM:"zoom",NONE:"none"},so={dangerouslyHTMLString:!1,multiple:!0,position:ur.TOP_RIGHT,autoClose:5e3,transition:"bounce",hideProgressBar:!1,pauseOnHover:!0,pauseOnFocusLoss:!0,closeOnClick:!0,className:"",bodyClassName:"",style:{},progressClassName:"",progressStyle:{},role:"alert",theme:"light"},co={rtl:!1,newestOnTop:!1,toastClassName:""},Mi={...so,...co};Se.DEFAULT;var W=(t=>(t[t.COLLAPSE_DURATION=300]="COLLAPSE_DURATION",t[t.DEBOUNCE_DURATION=50]="DEBOUNCE_DURATION",t.CSS_NAMESPACE="Toastify",t))(W||{}),hn=(t=>(t.ENTRANCE_ANIMATION_END="d",t))(hn||{});const uo={enter:"Toastify--animate Toastify__bounce-enter",exit:"Toastify--animate Toastify__bounce-exit",appendPosition:!0},fo={enter:"Toastify--animate Toastify__slide-enter",exit:"Toastify--animate Toastify__slide-exit",appendPosition:!0},lo={enter:"Toastify--animate Toastify__zoom-enter",exit:"Toastify--animate Toastify__zoom-exit"},ho={enter:"Toastify--animate Toastify__flip-enter",exit:"Toastify--animate Toastify__flip-exit"},jn="Toastify--animate Toastify__none-enter";function Li(t,e=!1){var r;let n=uo;if(!t||typeof t=="string")switch(t){case"flip":n=ho;break;case"zoom":n=lo;break;case"slide":n=fo;break}else n=t;if(e)n.enter=jn;else if(n.enter===jn){const i=(r=n.exit.split("__")[1])==null?void 0:r.split("-")[0];n.enter=`Toastify--animate Toastify__${i}-enter`}return n}function vo(t){return t.containerId||String(t.position)}const Mr="will-unmount";function po(t=ur.TOP_RIGHT){return!!document.querySelector(`.${W.CSS_NAMESPACE}__toast-container--${t}`)}function go(t=ur.TOP_RIGHT){return`${W.CSS_NAMESPACE}__toast-container--${t}`}function xo(t,e,r=!1){const n=[`${W.CSS_NAMESPACE}__toast-container`,`${W.CSS_NAMESPACE}__toast-container--${t}`,r?`${W.CSS_NAMESPACE}__toast-container--rtl`:null].filter(Boolean).join(" ");return Nt(e)?e({position:t,rtl:r,defaultClassName:n}):`${n} ${e||""}`}function yo(t){var e;const{position:r,containerClassName:n,rtl:i=!1,style:a={}}=t,o=W.CSS_NAMESPACE,s=go(r),c=document.querySelector(`.${o}`),u=document.querySelector(`.${s}`),l=!!u&&!((e=u.className)!=null&&e.includes(Mr)),d=c||document.createElement("div"),v=document.createElement("div");v.className=xo(r,n,i),v.dataset.testid=`${W.CSS_NAMESPACE}__toast-container--${r}`,v.id=vo(t);for(const h in a)if(Object.prototype.hasOwnProperty.call(a,h)){const p=a[h];v.style[h]=p}return c||(d.className=W.CSS_NAMESPACE,document.body.appendChild(d)),l||d.appendChild(v),v}function vn(t){var e,r,n;const i=typeof t=="string"?t:((e=t.currentTarget)==null?void 0:e.id)||((r=t.target)==null?void 0:r.id),a=document.getElementById(i);a&&a.removeEventListener("animationend",vn,!1);try{nr[i].unmount(),(n=document.getElementById(i))==null||n.remove(),delete nr[i],delete pe[i]}catch{}}const nr=f.reactive({});function mo(t,e){const r=document.getElementById(String(e));r&&(nr[r.id]=t)}function pn(t,e=!0){const r=String(t);if(!nr[r])return;const n=document.getElementById(r);n&&n.classList.add(Mr),e?(_o(t),n&&n.addEventListener("animationend",vn,!1)):vn(r),Fe.items=Fe.items.filter(i=>i.containerId!==t)}function wo(t){for(const e in nr)pn(e,t);Fe.items=[]}function Fi(t,e){const r=document.getElementById(t.toastId);if(r){let n=t;n={...n,...Li(n.transition)};const i=n.appendPosition?`${n.exit}--${n.position}`:n.exit;r.className+=` ${i}`,e&&e(r)}}function _o(t){for(const e in pe)if(e===t)for(const r of pe[e]||[])Fi(r)}function Eo(t){const e=Bt().find(r=>r.toastId===t);return e?.containerId}function kn(t){return document.getElementById(t)}function Ao(t){const e=kn(t.containerId);return e&&e.classList.contains(Mr)}function Yn(t){var e;const r=f.isVNode(t.content)?f.toRaw(t.content.props):null;return r??f.toRaw((e=t.data)!=null?e:{})}function Co(t){return t?Fe.items.filter(e=>e.containerId===t).length>0:Fe.items.length>0}function bo(){if(Fe.items.length>0){const t=Fe.items.shift();Er(t?.toastContent,t?.toastProps)}}const pe=f.reactive({}),Fe=f.reactive({items:[]});function Bt(){const t=f.toRaw(pe);return Object.values(t).reduce((e,r)=>[...e,...r],[])}function So(t){return Bt().find(e=>e.toastId===t)}function Er(t,e={}){if(Ao(e)){const r=kn(e.containerId);r&&r.addEventListener("animationend",gn.bind(null,t,e),!1)}else gn(t,e)}function gn(t,e={}){const r=kn(e.containerId);r&&r.removeEventListener("animationend",gn.bind(null,t,e),!1);const n=pe[e.containerId]||[],i=n.length>0;if(!i&&!po(e.position)){const a=yo(e),o=f.createApp(Zo,e);e.useHandler&&e.useHandler(o),o.mount(a),mo(o,a.id)}i&&!e.updateId&&(e.position=n[0].position),f.nextTick(()=>{e.updateId?Pe.update(e):Pe.add(t,e)})}const Pe={add(t,e){const{containerId:r=""}=e;r&&(pe[r]=pe[r]||[],pe[r].find(n=>n.toastId===e.toastId)||setTimeout(()=>{var n,i;e.newestOnTop?(n=pe[r])==null||n.unshift(e):(i=pe[r])==null||i.push(e),e.onOpen&&e.onOpen(Yn(e))},e.delay||0))},remove(t){if(t){const e=Eo(t);if(e){const r=pe[e];let n=r.find(i=>i.toastId===t);pe[e]=r.filter(i=>i.toastId!==t),!pe[e].length&&!Co(e)&&pn(e,!1),bo(),f.nextTick(()=>{n!=null&&n.onClose&&(n.onClose(Yn(n)),n=void 0)})}}},update(t={}){const{containerId:e=""}=t;if(e&&t.updateId){pe[e]=pe[e]||[];const r=pe[e].find(a=>a.toastId===t.toastId),n=r?.position!==t.position||r?.transition!==t.transition,i={...t,disabledEnterTransition:!n,updateId:void 0};Pe.dismissForce(t?.toastId),setTimeout(()=>{ee(i.content,i)},t.delay||0)}},clear(t,e=!0){t?pn(t,e):wo(e)},dismissCallback(t){var e;const r=(e=t.currentTarget)==null?void 0:e.id,n=document.getElementById(r);n&&(n.removeEventListener("animationend",Pe.dismissCallback,!1),setTimeout(()=>{Pe.remove(r)}))},dismiss(t){if(t){const e=Bt();for(const r of e)if(r.toastId===t){Fi(r,n=>{n.addEventListener("animationend",Pe.dismissCallback,!1)});break}}},dismissForce(t){if(t){const e=Bt();for(const r of e)if(r.toastId===t){const n=document.getElementById(t);n&&(n.remove(),n.removeEventListener("animationend",Pe.dismissCallback,!1),Pe.remove(t));break}}}},Io=f.reactive({useHandler:void 0}),Vi=f.reactive({}),Dr=f.reactive({});function Ui(){return Math.random().toString(36).substring(2,9)}function Oo(t){return typeof t=="number"&&!isNaN(t)}function xn(t){return typeof t=="string"}function Nt(t){return typeof t=="function"}function Lr(...t){return f.mergeProps(...t)}function Ar(t){return typeof t=="object"&&(!!(t!=null&&t.render)||!!(t!=null&&t.setup)||typeof t?.type=="object")}function To(t={}){Vi[`${W.CSS_NAMESPACE}-default-options`]=t}function Hi(){return Vi[`${W.CSS_NAMESPACE}-default-options`]||Mi}function No(){const t=window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches;return document.documentElement.classList.contains("dark")||t?"dark":"light"}var Cr=(t=>(t[t.Enter=0]="Enter",t[t.Exit=1]="Exit",t))(Cr||{});const $i={containerId:{type:[String,Number],required:!1,default:""},clearOnUrlChange:{type:Boolean,required:!1,default:!0},disabledEnterTransition:{type:Boolean,required:!1,default:!1},dangerouslyHTMLString:{type:Boolean,required:!1,default:!1},multiple:{type:Boolean,required:!1,default:!0},limit:{type:Number,required:!1,default:void 0},position:{type:String,required:!1,default:ur.TOP_LEFT},bodyClassName:{type:String,required:!1,default:""},autoClose:{type:[Number,Boolean],required:!1,default:!1},closeButton:{type:[Boolean,Function,Object],required:!1,default:void 0},transition:{type:[String,Object],required:!1,default:"bounce"},hideProgressBar:{type:Boolean,required:!1,default:!1},pauseOnHover:{type:Boolean,required:!1,default:!0},pauseOnFocusLoss:{type:Boolean,required:!1,default:!0},closeOnClick:{type:Boolean,required:!1,default:!0},progress:{type:Number,required:!1,default:void 0},progressClassName:{type:String,required:!1,default:""},toastStyle:{type:Object,required:!1,default(){return{}}},progressStyle:{type:Object,required:!1,default(){return{}}},role:{type:String,required:!1,default:"alert"},theme:{type:String,required:!1,default:Dt.AUTO},content:{type:[String,Object,Function],required:!1,default:""},toastId:{type:[String,Number],required:!1,default:""},data:{type:[Object,String],required:!1,default(){return{}}},type:{type:String,required:!1,default:Se.DEFAULT},icon:{type:[Boolean,String,Number,Object,Function],required:!1,default:void 0},delay:{type:Number,required:!1,default:void 0},onOpen:{type:Function,required:!1,default:void 0},onClose:{type:Function,required:!1,default:void 0},onClick:{type:Function,required:!1,default:void 0},isLoading:{type:Boolean,required:!1,default:void 0},rtl:{type:Boolean,required:!1,default:!1},toastClassName:{type:String,required:!1,default:""},updateId:{type:[String,Number],required:!1,default:""},contentProps:{type:Object,required:!1,default:null},expandCustomProps:{type:Boolean,required:!1,default:!1}},Do={autoClose:{type:[Number,Boolean],required:!0},isRunning:{type:Boolean,required:!1,default:void 0},type:{type:String,required:!1,default:Se.DEFAULT},theme:{type:String,required:!1,default:Dt.AUTO},hide:{type:Boolean,required:!1,default:void 0},className:{type:[String,Function],required:!1,default:""},controlledProgress:{type:Boolean,required:!1,default:void 0},rtl:{type:Boolean,required:!1,default:void 0},isIn:{type:Boolean,required:!1,default:void 0},progress:{type:Number,required:!1,default:void 0},closeToast:{type:Function,required:!1,default:void 0}},Bo=f.defineComponent({name:"ProgressBar",props:Do,setup(t,{attrs:e}){const r=f.ref(),n=f.computed(()=>t.hide?"true":"false"),i=f.computed(()=>({...e.style||{},animationDuration:`${t.autoClose===!0?5e3:t.autoClose}ms`,animationPlayState:t.isRunning?"running":"paused",opacity:t.hide||t.autoClose===!1?0:1,transform:t.controlledProgress?`scaleX(${t.progress})`:"none"})),a=f.computed(()=>[`${W.CSS_NAMESPACE}__progress-bar`,t.controlledProgress?`${W.CSS_NAMESPACE}__progress-bar--controlled`:`${W.CSS_NAMESPACE}__progress-bar--animated`,`${W.CSS_NAMESPACE}__progress-bar-theme--${t.theme}`,`${W.CSS_NAMESPACE}__progress-bar--${t.type}`,t.rtl?`${W.CSS_NAMESPACE}__progress-bar--rtl`:null].filter(Boolean).join(" ")),o=f.computed(()=>`${a.value} ${e?.class||""}`),s=()=>{r.value&&(r.value.onanimationend=null,r.value.ontransitionend=null)},c=()=>{t.isIn&&t.closeToast&&t.autoClose!==!1&&(t.closeToast(),s())},u=f.computed(()=>t.controlledProgress?null:c),l=f.computed(()=>t.controlledProgress?c:null);return f.watchEffect(()=>{r.value&&(s(),r.value.onanimationend=u.value,r.value.ontransitionend=l.value)}),()=>f.createVNode("div",{ref:r,role:"progressbar","aria-hidden":n.value,"aria-label":"notification timer",class:o.value,style:i.value},null)}}),Ro=f.defineComponent({name:"CloseButton",inheritAttrs:!1,props:{theme:{type:String,required:!1,default:Dt.AUTO},type:{type:String,required:!1,default:Dt.LIGHT},ariaLabel:{type:String,required:!1,default:"close"},closeToast:{type:Function,required:!1,default:void 0}},setup(t){return()=>f.createVNode("button",{class:`${W.CSS_NAMESPACE}__close-button ${W.CSS_NAMESPACE}__close-button--${t.theme}`,type:"button",onClick:e=>{e.stopPropagation(),t.closeToast&&t.closeToast(e)},"aria-label":t.ariaLabel},[f.createVNode("svg",{"aria-hidden":"true",viewBox:"0 0 14 16"},[f.createVNode("path",{"fill-rule":"evenodd",d:"M7.71 8.23l3.75 3.75-1.48 1.48-3.75-3.75-3.75 3.75L1 11.98l3.75-3.75L1 4.48 2.48 3l3.75 3.75L9.98 3l1.48 1.48-3.75 3.75z"},null)])])}}),Fr=({theme:t,type:e,path:r,...n})=>f.createVNode("svg",f.mergeProps({viewBox:"0 0 24 24",width:"100%",height:"100%",style:{fill:t==="colored"?"currentColor":`var(--toastify-icon-color-${e})`}},n),[f.createVNode("path",{d:r},null)]);function Po(t){return f.createVNode(Fr,f.mergeProps(t,{path:"M23.32 17.191L15.438 2.184C14.728.833 13.416 0 11.996 0c-1.42 0-2.733.833-3.443 2.184L.533 17.448a4.744 4.744 0 000 4.368C1.243 23.167 2.555 24 3.975 24h16.05C22.22 24 24 22.044 24 19.632c0-.904-.251-1.746-.68-2.44zm-9.622 1.46c0 1.033-.724 1.823-1.698 1.823s-1.698-.79-1.698-1.822v-.043c0-1.028.724-1.822 1.698-1.822s1.698.79 1.698 1.822v.043zm.039-12.285l-.84 8.06c-.057.581-.408.943-.897.943-.49 0-.84-.367-.896-.942l-.84-8.065c-.057-.624.25-1.095.779-1.095h1.91c.528.005.84.476.784 1.1z"}),null)}function ko(t){return f.createVNode(Fr,f.mergeProps(t,{path:"M12 0a12 12 0 1012 12A12.013 12.013 0 0012 0zm.25 5a1.5 1.5 0 11-1.5 1.5 1.5 1.5 0 011.5-1.5zm2.25 13.5h-4a1 1 0 010-2h.75a.25.25 0 00.25-.25v-4.5a.25.25 0 00-.25-.25h-.75a1 1 0 010-2h1a2 2 0 012 2v4.75a.25.25 0 00.25.25h.75a1 1 0 110 2z"}),null)}function Mo(t){return f.createVNode(Fr,f.mergeProps(t,{path:"M12 0a12 12 0 1012 12A12.014 12.014 0 0012 0zm6.927 8.2l-6.845 9.289a1.011 1.011 0 01-1.43.188l-4.888-3.908a1 1 0 111.25-1.562l4.076 3.261 6.227-8.451a1 1 0 111.61 1.183z"}),null)}function Lo(t){return f.createVNode(Fr,f.mergeProps(t,{path:"M11.983 0a12.206 12.206 0 00-8.51 3.653A11.8 11.8 0 000 12.207 11.779 11.779 0 0011.8 24h.214A12.111 12.111 0 0024 11.791 11.766 11.766 0 0011.983 0zM10.5 16.542a1.476 1.476 0 011.449-1.53h.027a1.527 1.527 0 011.523 1.47 1.475 1.475 0 01-1.449 1.53h-.027a1.529 1.529 0 01-1.523-1.47zM11 12.5v-6a1 1 0 012 0v6a1 1 0 11-2 0z"}),null)}function Fo(){return f.createVNode("div",{class:`${W.CSS_NAMESPACE}__spinner`},null)}const br={info:ko,warning:Po,success:Mo,error:Lo,spinner:Fo},Vo=t=>t in br;function Uo({theme:t,type:e,isLoading:r,icon:n}){let i;const a=!!r||e==="loading",o={theme:t,type:e};if(a&&(n===void 0||typeof n=="boolean"))return br.spinner();if(n!==!1){if(Ar(n))i=f.toRaw(n);else if(Nt(n)){const s=n;o.type=a?"loading":e,i=s(o),i=!i&&a?br.spinner():i}else f.isVNode(n)?i=f.cloneVNode(n,o):xn(n)||Oo(n)?i=n:Vo(e)&&(i=br[e](o));return i}}const Ho=()=>{};function $o(t,e,r=W.COLLAPSE_DURATION){const{scrollHeight:n,style:i}=t,a=r;requestAnimationFrame(()=>{i.minHeight="initial",i.height=n+"px",i.transition=`all ${a}ms`,requestAnimationFrame(()=>{i.height="0",i.padding="0",i.margin="0",setTimeout(e,a)})})}function Go(t){const e=f.ref(!1),r=f.ref(!1),n=f.ref(!1),i=f.ref(Cr.Enter),a=f.reactive({...t,appendPosition:t.appendPosition||!1,collapse:typeof t.collapse>"u"?!0:t.collapse,collapseDuration:t.collapseDuration||W.COLLAPSE_DURATION}),o=a.done||Ho,s=f.computed(()=>a.appendPosition?`${a.enter}--${a.position}`:a.enter),c=f.computed(()=>a.appendPosition?`${a.exit}--${a.position}`:a.exit),u=f.computed(()=>t.pauseOnHover?{onMouseenter:y,onMouseleave:g}:{});function l(){const m=s.value.split(" ");v().addEventListener(hn.ENTRANCE_ANIMATION_END,g,{once:!0});const _=I=>{const D=v();I.target===D&&(D.dispatchEvent(new Event(hn.ENTRANCE_ANIMATION_END)),D.removeEventListener("animationend",_),D.removeEventListener("animationcancel",_),i.value===Cr.Enter&&I.type!=="animationcancel"&&D.classList.remove(...m))},A=()=>{const I=v();I.classList.add(...m),I.addEventListener("animationend",_),I.addEventListener("animationcancel",_)};t.pauseOnFocusLoss&&h(),A()}function d(){if(!v())return;const m=()=>{const A=v();A.removeEventListener("animationend",m),a.collapse?$o(A,o,a.collapseDuration):o()},_=()=>{const A=v();i.value=Cr.Exit,A&&(A.className+=` ${c.value}`,A.addEventListener("animationend",m))};r.value||(n.value?m():setTimeout(_))}function v(){return t.toastRef.value}function h(){document.hasFocus()||y(),window.addEventListener("focus",g),window.addEventListener("blur",y)}function p(){window.removeEventListener("focus",g),window.removeEventListener("blur",y)}function g(){(!t.loading.value||t.isLoading===void 0)&&(e.value=!0)}function y(){e.value=!1}function w(m){m&&(m.stopPropagation(),m.preventDefault()),r.value=!1}return f.watchEffect(d),f.watchEffect(()=>{const m=Bt();r.value=m.findIndex(_=>_.toastId===a.toastId)>-1}),f.watchEffect(()=>{t.isLoading!==void 0&&(t.loading.value?y():g())}),f.onMounted(l),f.onUnmounted(()=>{t.pauseOnFocusLoss&&p()}),{isIn:r,isRunning:e,hideToast:w,eventHandlers:u}}function zo(t){if(!t||typeof t!="object"||Array.isArray(t)||t.__v_isVNode)return!1;const e=t;return["title","content"].some(r=>r in e)}const Wo=f.defineComponent({name:"ToastItem",inheritAttrs:!1,props:$i,setup(t){const e=f.ref(),r=f.computed(()=>!!t.isLoading),n=f.computed(()=>t.progress!==void 0&&t.progress!==null),i=f.computed(()=>Uo(t)),a=f.computed(()=>[`${W.CSS_NAMESPACE}__toast`,`${W.CSS_NAMESPACE}__toast-theme--${t.theme}`,`${W.CSS_NAMESPACE}__toast--${t.type}`,t.rtl?`${W.CSS_NAMESPACE}__toast--rtl`:void 0,t.toastClassName||""].filter(Boolean).join(" ")),{isRunning:o,isIn:s,hideToast:c,eventHandlers:u}=Go({toastRef:e,loading:r,done:()=>{Pe.remove(t.toastId)},...Li(t.transition,t.disabledEnterTransition),...t});function l(){const d=t.content;if(zo(d)){const v=[];return d.title!==void 0&&v.push(f.createVNode("div",{"data-testid":"toast-text-title",class:`${W.CSS_NAMESPACE}__toast-text-title`},[d.title])),d.content!==void 0&&v.push(f.createVNode("div",{"data-testid":"toast-text-content",class:`${W.CSS_NAMESPACE}__toast-text-content`},[d.content])),f.createVNode("div",{"data-testid":"toast-text-content-wrapper",class:`${W.CSS_NAMESPACE}__toast-text`},[v])}return Ar(d)?f.h(f.toRaw(d),{toastProps:f.toRaw(t),closeToast:c,data:t.data,...t.expandCustomProps?t.contentProps:{contentProps:t.contentProps||{}}}):Nt(d)?d({toastProps:f.toRaw(t),closeToast:c,data:t.data}):t.dangerouslyHTMLString?f.h("div",{innerHTML:d}):d}return()=>f.createVNode("div",f.mergeProps({id:t.toastId,class:a.value,style:t.toastStyle||{},ref:e,"data-testid":`toast-item-${t.toastId}`,onClick:d=>{t.closeOnClick&&c(),t.onClick&&t.onClick(d)}},u.value),[f.createVNode("div",{role:t.role,"data-testid":"toast-body",class:`${W.CSS_NAMESPACE}__toast-body ${t.bodyClassName||""}`},[i.value!=null&&f.createVNode("div",{"data-testid":`toast-icon-${t.type}`,class:[`${W.CSS_NAMESPACE}__toast-icon`,t.isLoading?"":`${W.CSS_NAMESPACE}--animate-icon ${W.CSS_NAMESPACE}__zoom-enter`].join(" ")},[Ar(i.value)?f.h(f.toRaw(i.value),{theme:t.theme,type:t.type}):Nt(i.value)?i.value({theme:t.theme,type:t.type}):i.value]),f.createVNode("div",{"data-testid":"toast-content"},[l()])]),(t.closeButton===void 0||t.closeButton===!0)&&f.createVNode(Ro,{theme:t.theme,closeToast:d=>{d.stopPropagation(),d.preventDefault(),c()}},null),Ar(t.closeButton)?f.h(f.toRaw(t.closeButton),{closeToast:c,type:t.type,theme:t.theme}):Nt(t.closeButton)?t.closeButton({closeToast:c,type:t.type,theme:t.theme}):null,f.createVNode(Bo,{className:t.progressClassName,style:t.progressStyle,rtl:t.rtl,theme:t.theme,isIn:s.value,type:t.type,hide:t.hideProgressBar,isRunning:o.value,autoClose:t.autoClose,controlledProgress:n.value,progress:t.progress,closeToast:t.isLoading?void 0:c},null)])}}),Br="vue3-toastify:url-change";let lr=0,er;function Xo(){if(!(typeof window>"u")&&Dr.lastUrl!==window.location.href){Dr.lastUrl=window.location.href;const t=r=>typeof r.clearOnUrlChange=="boolean"?r.clearOnUrlChange:Hi().clearOnUrlChange!==!1,e=Object.values(pe).reduce((r,n)=>(Array.isArray(n)&&r.push(...n),r),[]);for(const r of e)r.toastId&&t(r)&&Pe.dismiss(r.toastId);Fe.items=Fe.items.filter(r=>!t(r.toastProps))}}function jo(){const{history:t}=window,e=t.pushState,r=t.replaceState;return t.pushState=function(...n){const i=e.apply(this,n);return window.dispatchEvent(new Event(Br)),i},t.replaceState=function(...n){const i=r.apply(this,n);return window.dispatchEvent(new Event(Br)),i},()=>{t.pushState=e,t.replaceState=r}}function Yo(){if(typeof window>"u"||er)return;const t=jo(),e=()=>Xo();window.addEventListener(Br,e),window.addEventListener("popstate",e),window.addEventListener("hashchange",e),er=()=>{t(),window.removeEventListener(Br,e),window.removeEventListener("popstate",e),window.removeEventListener("hashchange",e),er=void 0}}function Ko(){er&&(er(),Dr.lastUrl="")}const Zo=f.defineComponent({name:"ToastifyContainer",inheritAttrs:!1,props:$i,setup(t){const e=f.computed(()=>t.containerId),r=f.computed(()=>pe[e.value]||[]),n=f.computed(()=>r.value.filter(i=>i.position===t.position));return f.onMounted(()=>{typeof window<"u"&&(lr+=1,Yo())}),f.onUnmounted(()=>{typeof window<"u"&&lr>0&&(lr-=1,lr===0&&Ko())}),()=>f.createVNode(f.Fragment,null,[n.value.map(i=>{const{toastId:a=""}=i;return f.createVNode(Wo,f.mergeProps({key:a},i),null)})])}});let jr=!1;const Gi={isLoading:!0,autoClose:!1,closeOnClick:!1,closeButton:!1,draggable:!1};function zi(){const t=[];return Bt().forEach(e=>{const r=document.getElementById(e.containerId);r&&!r.classList.contains(Mr)&&t.push(e)}),t}function qo(t){const e=zi().length,r=t??0;return r>0&&e+Fe.items.length>=r}function Qo(t){qo(t.limit)&&!t.updateId&&Fe.items.push({toastId:t.toastId,containerId:t.containerId,toastContent:t.content,toastProps:t})}function lt(t,e,r={}){if(jr)return;r=Lr(Hi(),{type:e},f.toRaw(r)),(!r.toastId||typeof r.toastId!="string"&&typeof r.toastId!="number")&&(r.toastId=Ui()),r={...r,...r.type==="loading"?Gi:{},content:t,containerId:r.containerId||String(r.position)};const n=Number(r?.progress);return!isNaN(n)&&n<0&&(r.progress=0),n>1&&(r.progress=1),r.theme==="auto"&&(r.theme=No()),Qo(r),Dr.lastUrl=window.location.href,r.multiple?Fe.items.length?r.updateId&&Er(t,r):Er(t,r):(jr=!0,ee.clearAll(void 0,!1),setTimeout(()=>{Er(t,r)},0),setTimeout(()=>{jr=!1},390)),r.toastId}const ee=(t,e)=>lt(t,Se.DEFAULT,e);ee.info=(t,e)=>lt(t,Se.DEFAULT,{...e,type:Se.INFO});ee.error=(t,e)=>lt(t,Se.DEFAULT,{...e,type:Se.ERROR});ee.warning=(t,e)=>lt(t,Se.DEFAULT,{...e,type:Se.WARNING});ee.warn=ee.warning;ee.success=(t,e)=>lt(t,Se.DEFAULT,{...e,type:Se.SUCCESS});ee.loading=(t,e)=>lt(t,Se.DEFAULT,Lr(e,Gi));ee.dark=(t,e)=>lt(t,Se.DEFAULT,Lr(e,{theme:Dt.DARK}));ee.remove=t=>{t?Pe.dismiss(t):Pe.clear()};ee.clearAll=(t,e)=>{f.nextTick(()=>{Pe.clear(t,e)})};ee.isActive=t=>{let e=!1;return e=zi().findIndex(r=>r.toastId===t)>-1,e};ee.update=(t,e={})=>{setTimeout(()=>{const r=So(t);if(r){const n=f.toRaw(r),{content:i}=n,a={...n,...e,toastId:e.toastId||t,updateId:Ui()},o=a.render||i;delete a.render,lt(o,a.type,a)}},0)};ee.done=t=>{ee.update(t,{isLoading:!1,progress:1})};ee.promise=Jo;function Jo(t,{pending:e,error:r,success:n},i){var a,o,s;let c;const u={...i||{},autoClose:!1};e&&(c=xn(e)?ee.loading(e,u):ee.loading(e.render,{...u,...e}));const l={autoClose:(a=i?.autoClose)!=null?a:!0,closeOnClick:(o=i?.closeOnClick)!=null?o:!0,closeButton:(s=i?.autoClose)!=null?s:null,isLoading:void 0,draggable:null,delay:100},d=(h,p,g)=>{if(p==null){ee.remove(c);return}const y={type:h,...l,...i,data:g},w=xn(p)?{render:p}:p;return c?ee.update(c,{...y,...w,isLoading:!1}):ee(w.render,{...y,...w,isLoading:!1}),g},v=Nt(t)?t():t;return v.then(h=>{d("success",n,h)}).catch(h=>{d("error",r,h)}),v}ee.POSITION=ur;ee.THEME=Dt;ee.TYPE=Se;ee.TRANSITIONS=oo;const es={install(t,e={}){Io.useHandler=e.useHandler||(()=>{}),ts(e)}};typeof window<"u"&&(window.Vue3Toastify=es);function ts(t={}){const e=Lr(Mi,t);To(e)}const rs={class:"dsg-alert__wrapper"},ns=["innerHTML"],Wi=f.defineComponent({__name:"DsgAlertComponent",props:{contentProps:{default:()=>({title:"",message:"",type:"gray",hasCloseButton:!0,useToast:!0,timeout:!1})}},setup(t){const r=f.useAttrs().closeToast,n=f.ref(!1);let i=null;const a=()=>{t.contentProps.useToast?r():n.value=!0};return f.onMounted(()=>{t.contentProps.timeout&&t.contentProps.timeout>0&&(i=setTimeout(()=>{a()},t.contentProps.timeout))}),f.onBeforeUnmount(()=>{i&&(clearTimeout(i),i=null)}),(o,s)=>n.value?f.createCommentVNode("",!0):(f.openBlock(),f.createElementBlock("div",{key:0,class:f.normalizeClass(`
17
+ `,Ya=["href","title"],Ka={class:"dsg-avatar__image-wrapper",tabindex:"0",ref:"avatarImageWrapperEl"},Za=["src","alt"],qa={key:1,class:"dsg-avatar__initials"},Qa={class:"dsg-avatar__status"},Ja={key:0,class:"dsg-avatar__activity"},eo=["innerHTML"],to={key:2,class:"dsg-avatar__logo"},ro=["src","alt"],no={key:0,class:"dsg-avatar__info"},io={class:"dsg-avatar__title"},ao={class:"dsg-avatar__subtext"},rr=f.defineComponent({__name:"DsgAvatar",props:{profileUri:{default:""},fullName:{default:""},size:{default:"md"},theme:{default:"activity"},isOnline:{type:Boolean,default:!1},uri:{default:()=>{}},companyLogoUri:{default:()=>{}},preventDefault:{type:Boolean,default:!1},title:{default:""},subText:{default:""},noFocus:{type:Boolean,default:!1}},emits:["avatar-clicked","before-change-status","after-change-status"],setup(t,{expose:e,emit:r}){["profile-photo","profile-photo-verified"].indexOf(t.theme)!==-1&&(["sm","md","lg"].indexOf(t.size)===-1&&new M.DsgPropSyntaxWarning("DsgAvatar: The 'profile-photo' theme only supports the 'sm', 'md', and 'lg' sizes."),(t.fullName||t.title||t.subText)&&new M.DsgWarning("DsgAvatar: The 'profile-photo' theme will not display the 'title' or 'subText' props.")),t.theme==="logo"&&!t.companyLogoUri&&new M.DsgPropSyntaxWarning("DsgAvatar: The 'logo' theme requires a 'companyLogoUri' prop."),["activity","verified","logo"].indexOf(t.theme)!==-1&&t.title?.length&&t.subText?.length&&["xs","sm","md","lg","xl","2xl"].indexOf(t.size)===-1&&new M.DsgPropSyntaxWarning("DsgAvatar: The 'activity', 'verified', and 'logo' themes only support the 'xs', 'sm', 'md', 'lg', and 'xl' sizes when 'title' and 'subText' are provided."),t.theme==="tile"&&!t.title?.length&&!t.fullName&&new M.DsgPropSyntaxWarning("DsgAvatar: The 'tile' theme requires either 'title' or 'fullName' prop."),t.size==="xxs"&&(t.title?.length||t.subText?.length)&&new M.DsgPropSyntaxWarning("DsgAvatar: The 'xxs' size does not support the 'title' or 'subText' props.");const n=d=>{const v=d.split(" ");return(v[0].charAt(0)+v[v.length-1].charAt(0)).toUpperCase()},i=()=>t.fullName?"Avatar of "+t.fullName:"Avatar",a=r,o=f.ref(!1),s=d=>{a("before-change-status",o.value,d),o.value=d,a("after-change-status",o.value)},c=f.useTemplateRef("avatarImageWrapperEl"),u=d=>{t.preventDefault||(a("avatar-clicked",d),c.value&&!t.uri&&c.value.focus())};return e({setUserActiveStatus:s,toggleFocus:d=>{c.value&&(d?c.value.focus():c.value.blur())}}),(d,v)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(["dsg-avatar",`dsg-avatar--${t.size}`,`dsg-avatar--${t.theme}`,`dsg-avatar--${t.isOnline?"online":"offline"}`,`dsg-avatar--${t.title?.length?"has-info":"no-info"}`,`dsg-avatar--${t.uri?"has-link":"no-link"}`,`dsg-avatar--${t.noFocus?"no-focus":"focus"}`,`dsg-avatar--${["profile-photo","profile-photo-verified"].indexOf(t.theme)!==-1?"profile-photo":"non-profile-photo"}`])},[f.createElementVNode("a",{class:"dsg-avatar__link",href:t.uri,title:i(),target:"_blank",ref:"avatarLink",onClick:u},[f.createElementVNode("div",Ka,[f.renderSlot(d.$slots,"dsg-avatar--background",{},()=>[t.profileUri?(f.openBlock(),f.createElementBlock("img",{key:0,class:"dsg-avatar__profile-image",src:t.profileUri,alt:i()},null,8,Za)):f.createCommentVNode("",!0),!t.profileUri&&t.fullName?(f.openBlock(),f.createElementBlock("span",qa,f.toDisplayString(n(t.fullName)),1)):f.createCommentVNode("",!0),!t.profileUri&&!t.fullName?(f.openBlock(),f.createBlock(M._sfc_main,{key:2,class:"dsg-avatar__user-icon",icon:"user-01",size:t.size},null,8,["size"])):f.createCommentVNode("",!0)]),["tile"].indexOf(t.theme)===-1?f.renderSlot(d.$slots,"dsg-avatar--status",{},()=>[f.createElementVNode("div",Qa,[t.theme==="activity"&&t.isOnline?(f.openBlock(),f.createElementBlock("span",Ja)):f.createCommentVNode("",!0),["verified","profile-photo-verified"].indexOf(t.theme)!==-1?(f.openBlock(),f.createElementBlock("span",{key:1,class:"dsg-avatar__verified",innerHTML:f.unref(ja)},null,8,eo)):f.createCommentVNode("",!0),t.theme==="logo"?(f.openBlock(),f.createElementBlock("span",to,[f.createElementVNode("img",{src:t.companyLogoUri,alt:i(),class:"dsg-avatar__company-logo"},null,8,ro)])):f.createCommentVNode("",!0)])],void 0,0):f.createCommentVNode("",!0)],512),t.title?.length||t.theme==="tile"&&(t.title?.length||t.fullName)?(f.openBlock(),f.createElementBlock("div",no,[t.title?.length||t.theme==="tile"&&(t.title?.length||t.fullName)?f.renderSlot(d.$slots,"dsg-avatar--title",{},()=>[f.createElementVNode("h3",io,f.toDisplayString(t.title?.length?t.title:t.fullName),1)],void 0,0):f.createCommentVNode("",!0),t.subText?.length?f.renderSlot(d.$slots,"dsg-avatar--subtext",{},()=>[f.createElementVNode("p",ao,f.toDisplayString(t.subText),1)],void 0,1):f.createCommentVNode("",!0)])):f.createCommentVNode("",!0)],8,Ya)],2))}}),ur={TOP_LEFT:"top-left",TOP_RIGHT:"top-right",TOP_CENTER:"top-center",BOTTOM_LEFT:"bottom-left",BOTTOM_RIGHT:"bottom-right",BOTTOM_CENTER:"bottom-center"},Dt={LIGHT:"light",DARK:"dark",COLORED:"colored",AUTO:"auto"},Se={INFO:"info",SUCCESS:"success",WARNING:"warning",ERROR:"error",DEFAULT:"default"},oo={BOUNCE:"bounce",SLIDE:"slide",FLIP:"flip",ZOOM:"zoom",NONE:"none"},so={dangerouslyHTMLString:!1,multiple:!0,position:ur.TOP_RIGHT,autoClose:5e3,transition:"bounce",hideProgressBar:!1,pauseOnHover:!0,pauseOnFocusLoss:!0,closeOnClick:!0,className:"",bodyClassName:"",style:{},progressClassName:"",progressStyle:{},role:"alert",theme:"light"},co={rtl:!1,newestOnTop:!1,toastClassName:""},Mi={...so,...co};Se.DEFAULT;var W=(t=>(t[t.COLLAPSE_DURATION=300]="COLLAPSE_DURATION",t[t.DEBOUNCE_DURATION=50]="DEBOUNCE_DURATION",t.CSS_NAMESPACE="Toastify",t))(W||{}),hn=(t=>(t.ENTRANCE_ANIMATION_END="d",t))(hn||{});const uo={enter:"Toastify--animate Toastify__bounce-enter",exit:"Toastify--animate Toastify__bounce-exit",appendPosition:!0},fo={enter:"Toastify--animate Toastify__slide-enter",exit:"Toastify--animate Toastify__slide-exit",appendPosition:!0},lo={enter:"Toastify--animate Toastify__zoom-enter",exit:"Toastify--animate Toastify__zoom-exit"},ho={enter:"Toastify--animate Toastify__flip-enter",exit:"Toastify--animate Toastify__flip-exit"},jn="Toastify--animate Toastify__none-enter";function Li(t,e=!1){var r;let n=uo;if(!t||typeof t=="string")switch(t){case"flip":n=ho;break;case"zoom":n=lo;break;case"slide":n=fo;break}else n=t;if(e)n.enter=jn;else if(n.enter===jn){const i=(r=n.exit.split("__")[1])==null?void 0:r.split("-")[0];n.enter=`Toastify--animate Toastify__${i}-enter`}return n}function vo(t){return t.containerId||String(t.position)}const Mr="will-unmount";function po(t=ur.TOP_RIGHT){return!!document.querySelector(`.${W.CSS_NAMESPACE}__toast-container--${t}`)}function go(t=ur.TOP_RIGHT){return`${W.CSS_NAMESPACE}__toast-container--${t}`}function xo(t,e,r=!1){const n=[`${W.CSS_NAMESPACE}__toast-container`,`${W.CSS_NAMESPACE}__toast-container--${t}`,r?`${W.CSS_NAMESPACE}__toast-container--rtl`:null].filter(Boolean).join(" ");return Nt(e)?e({position:t,rtl:r,defaultClassName:n}):`${n} ${e||""}`}function yo(t){var e;const{position:r,containerClassName:n,rtl:i=!1,style:a={}}=t,o=W.CSS_NAMESPACE,s=go(r),c=document.querySelector(`.${o}`),u=document.querySelector(`.${s}`),l=!!u&&!((e=u.className)!=null&&e.includes(Mr)),d=c||document.createElement("div"),v=document.createElement("div");v.className=xo(r,n,i),v.dataset.testid=`${W.CSS_NAMESPACE}__toast-container--${r}`,v.id=vo(t);for(const h in a)if(Object.prototype.hasOwnProperty.call(a,h)){const p=a[h];v.style[h]=p}return c||(d.className=W.CSS_NAMESPACE,document.body.appendChild(d)),l||d.appendChild(v),v}function vn(t){var e,r,n;const i=typeof t=="string"?t:((e=t.currentTarget)==null?void 0:e.id)||((r=t.target)==null?void 0:r.id),a=document.getElementById(i);a&&a.removeEventListener("animationend",vn,!1);try{nr[i].unmount(),(n=document.getElementById(i))==null||n.remove(),delete nr[i],delete pe[i]}catch{}}const nr=f.reactive({});function mo(t,e){const r=document.getElementById(String(e));r&&(nr[r.id]=t)}function pn(t,e=!0){const r=String(t);if(!nr[r])return;const n=document.getElementById(r);n&&n.classList.add(Mr),e?(_o(t),n&&n.addEventListener("animationend",vn,!1)):vn(r),Fe.items=Fe.items.filter(i=>i.containerId!==t)}function wo(t){for(const e in nr)pn(e,t);Fe.items=[]}function Fi(t,e){const r=document.getElementById(t.toastId);if(r){let n=t;n={...n,...Li(n.transition)};const i=n.appendPosition?`${n.exit}--${n.position}`:n.exit;r.className+=` ${i}`,e&&e(r)}}function _o(t){for(const e in pe)if(e===t)for(const r of pe[e]||[])Fi(r)}function Eo(t){const e=Bt().find(r=>r.toastId===t);return e?.containerId}function kn(t){return document.getElementById(t)}function Ao(t){const e=kn(t.containerId);return e&&e.classList.contains(Mr)}function Yn(t){var e;const r=f.isVNode(t.content)?f.toRaw(t.content.props):null;return r??f.toRaw((e=t.data)!=null?e:{})}function Co(t){return t?Fe.items.filter(e=>e.containerId===t).length>0:Fe.items.length>0}function bo(){if(Fe.items.length>0){const t=Fe.items.shift();Er(t?.toastContent,t?.toastProps)}}const pe=f.reactive({}),Fe=f.reactive({items:[]});function Bt(){const t=f.toRaw(pe);return Object.values(t).reduce((e,r)=>[...e,...r],[])}function So(t){return Bt().find(e=>e.toastId===t)}function Er(t,e={}){if(Ao(e)){const r=kn(e.containerId);r&&r.addEventListener("animationend",gn.bind(null,t,e),!1)}else gn(t,e)}function gn(t,e={}){const r=kn(e.containerId);r&&r.removeEventListener("animationend",gn.bind(null,t,e),!1);const n=pe[e.containerId]||[],i=n.length>0;if(!i&&!po(e.position)){const a=yo(e),o=f.createApp(Zo,e);e.useHandler&&e.useHandler(o),o.mount(a),mo(o,a.id)}i&&!e.updateId&&(e.position=n[0].position),f.nextTick(()=>{e.updateId?Pe.update(e):Pe.add(t,e)})}const Pe={add(t,e){const{containerId:r=""}=e;r&&(pe[r]=pe[r]||[],pe[r].find(n=>n.toastId===e.toastId)||setTimeout(()=>{var n,i;e.newestOnTop?(n=pe[r])==null||n.unshift(e):(i=pe[r])==null||i.push(e),e.onOpen&&e.onOpen(Yn(e))},e.delay||0))},remove(t){if(t){const e=Eo(t);if(e){const r=pe[e];let n=r.find(i=>i.toastId===t);pe[e]=r.filter(i=>i.toastId!==t),!pe[e].length&&!Co(e)&&pn(e,!1),bo(),f.nextTick(()=>{n!=null&&n.onClose&&(n.onClose(Yn(n)),n=void 0)})}}},update(t={}){const{containerId:e=""}=t;if(e&&t.updateId){pe[e]=pe[e]||[];const r=pe[e].find(a=>a.toastId===t.toastId),n=r?.position!==t.position||r?.transition!==t.transition,i={...t,disabledEnterTransition:!n,updateId:void 0};Pe.dismissForce(t?.toastId),setTimeout(()=>{ee(i.content,i)},t.delay||0)}},clear(t,e=!0){t?pn(t,e):wo(e)},dismissCallback(t){var e;const r=(e=t.currentTarget)==null?void 0:e.id,n=document.getElementById(r);n&&(n.removeEventListener("animationend",Pe.dismissCallback,!1),setTimeout(()=>{Pe.remove(r)}))},dismiss(t){if(t){const e=Bt();for(const r of e)if(r.toastId===t){Fi(r,n=>{n.addEventListener("animationend",Pe.dismissCallback,!1)});break}}},dismissForce(t){if(t){const e=Bt();for(const r of e)if(r.toastId===t){const n=document.getElementById(t);n&&(n.remove(),n.removeEventListener("animationend",Pe.dismissCallback,!1),Pe.remove(t));break}}}},Io=f.reactive({useHandler:void 0}),Vi=f.reactive({}),Dr=f.reactive({});function Ui(){return Math.random().toString(36).substring(2,9)}function Oo(t){return typeof t=="number"&&!isNaN(t)}function xn(t){return typeof t=="string"}function Nt(t){return typeof t=="function"}function Lr(...t){return f.mergeProps(...t)}function Ar(t){return typeof t=="object"&&(!!(t!=null&&t.render)||!!(t!=null&&t.setup)||typeof t?.type=="object")}function To(t={}){Vi[`${W.CSS_NAMESPACE}-default-options`]=t}function Hi(){return Vi[`${W.CSS_NAMESPACE}-default-options`]||Mi}function No(){const t=window.matchMedia&&window.matchMedia("(prefers-color-scheme: dark)").matches;return document.documentElement.classList.contains("dark")||t?"dark":"light"}var Cr=(t=>(t[t.Enter=0]="Enter",t[t.Exit=1]="Exit",t))(Cr||{});const $i={containerId:{type:[String,Number],required:!1,default:""},clearOnUrlChange:{type:Boolean,required:!1,default:!0},disabledEnterTransition:{type:Boolean,required:!1,default:!1},dangerouslyHTMLString:{type:Boolean,required:!1,default:!1},multiple:{type:Boolean,required:!1,default:!0},limit:{type:Number,required:!1,default:void 0},position:{type:String,required:!1,default:ur.TOP_LEFT},bodyClassName:{type:String,required:!1,default:""},autoClose:{type:[Number,Boolean],required:!1,default:!1},closeButton:{type:[Boolean,Function,Object],required:!1,default:void 0},transition:{type:[String,Object],required:!1,default:"bounce"},hideProgressBar:{type:Boolean,required:!1,default:!1},pauseOnHover:{type:Boolean,required:!1,default:!0},pauseOnFocusLoss:{type:Boolean,required:!1,default:!0},closeOnClick:{type:Boolean,required:!1,default:!0},progress:{type:Number,required:!1,default:void 0},progressClassName:{type:String,required:!1,default:""},toastStyle:{type:Object,required:!1,default(){return{}}},progressStyle:{type:Object,required:!1,default(){return{}}},role:{type:String,required:!1,default:"alert"},theme:{type:String,required:!1,default:Dt.AUTO},content:{type:[String,Object,Function],required:!1,default:""},toastId:{type:[String,Number],required:!1,default:""},data:{type:[Object,String],required:!1,default(){return{}}},type:{type:String,required:!1,default:Se.DEFAULT},icon:{type:[Boolean,String,Number,Object,Function],required:!1,default:void 0},delay:{type:Number,required:!1,default:void 0},onOpen:{type:Function,required:!1,default:void 0},onClose:{type:Function,required:!1,default:void 0},onClick:{type:Function,required:!1,default:void 0},isLoading:{type:Boolean,required:!1,default:void 0},rtl:{type:Boolean,required:!1,default:!1},toastClassName:{type:String,required:!1,default:""},updateId:{type:[String,Number],required:!1,default:""},contentProps:{type:Object,required:!1,default:null},expandCustomProps:{type:Boolean,required:!1,default:!1}},Do={autoClose:{type:[Number,Boolean],required:!0},isRunning:{type:Boolean,required:!1,default:void 0},type:{type:String,required:!1,default:Se.DEFAULT},theme:{type:String,required:!1,default:Dt.AUTO},hide:{type:Boolean,required:!1,default:void 0},className:{type:[String,Function],required:!1,default:""},controlledProgress:{type:Boolean,required:!1,default:void 0},rtl:{type:Boolean,required:!1,default:void 0},isIn:{type:Boolean,required:!1,default:void 0},progress:{type:Number,required:!1,default:void 0},closeToast:{type:Function,required:!1,default:void 0}},Bo=f.defineComponent({name:"ProgressBar",props:Do,setup(t,{attrs:e}){const r=f.ref(),n=f.computed(()=>t.hide?"true":"false"),i=f.computed(()=>({...e.style||{},animationDuration:`${t.autoClose===!0?5e3:t.autoClose}ms`,animationPlayState:t.isRunning?"running":"paused",opacity:t.hide||t.autoClose===!1?0:1,transform:t.controlledProgress?`scaleX(${t.progress})`:"none"})),a=f.computed(()=>[`${W.CSS_NAMESPACE}__progress-bar`,t.controlledProgress?`${W.CSS_NAMESPACE}__progress-bar--controlled`:`${W.CSS_NAMESPACE}__progress-bar--animated`,`${W.CSS_NAMESPACE}__progress-bar-theme--${t.theme}`,`${W.CSS_NAMESPACE}__progress-bar--${t.type}`,t.rtl?`${W.CSS_NAMESPACE}__progress-bar--rtl`:null].filter(Boolean).join(" ")),o=f.computed(()=>`${a.value} ${e?.class||""}`),s=()=>{r.value&&(r.value.onanimationend=null,r.value.ontransitionend=null)},c=()=>{t.isIn&&t.closeToast&&t.autoClose!==!1&&(t.closeToast(),s())},u=f.computed(()=>t.controlledProgress?null:c),l=f.computed(()=>t.controlledProgress?c:null);return f.watchEffect(()=>{r.value&&(s(),r.value.onanimationend=u.value,r.value.ontransitionend=l.value)}),()=>f.createVNode("div",{ref:r,role:"progressbar","aria-hidden":n.value,"aria-label":"notification timer",class:o.value,style:i.value},null)}}),Ro=f.defineComponent({name:"CloseButton",inheritAttrs:!1,props:{theme:{type:String,required:!1,default:Dt.AUTO},type:{type:String,required:!1,default:Dt.LIGHT},ariaLabel:{type:String,required:!1,default:"close"},closeToast:{type:Function,required:!1,default:void 0}},setup(t){return()=>f.createVNode("button",{class:`${W.CSS_NAMESPACE}__close-button ${W.CSS_NAMESPACE}__close-button--${t.theme}`,type:"button",onClick:e=>{e.stopPropagation(),t.closeToast&&t.closeToast(e)},"aria-label":t.ariaLabel},[f.createVNode("svg",{"aria-hidden":"true",viewBox:"0 0 14 16"},[f.createVNode("path",{"fill-rule":"evenodd",d:"M7.71 8.23l3.75 3.75-1.48 1.48-3.75-3.75-3.75 3.75L1 11.98l3.75-3.75L1 4.48 2.48 3l3.75 3.75L9.98 3l1.48 1.48-3.75 3.75z"},null)])])}}),Fr=({theme:t,type:e,path:r,...n})=>f.createVNode("svg",f.mergeProps({viewBox:"0 0 24 24",width:"100%",height:"100%",style:{fill:t==="colored"?"currentColor":`var(--toastify-icon-color-${e})`}},n),[f.createVNode("path",{d:r},null)]);function Po(t){return f.createVNode(Fr,f.mergeProps(t,{path:"M23.32 17.191L15.438 2.184C14.728.833 13.416 0 11.996 0c-1.42 0-2.733.833-3.443 2.184L.533 17.448a4.744 4.744 0 000 4.368C1.243 23.167 2.555 24 3.975 24h16.05C22.22 24 24 22.044 24 19.632c0-.904-.251-1.746-.68-2.44zm-9.622 1.46c0 1.033-.724 1.823-1.698 1.823s-1.698-.79-1.698-1.822v-.043c0-1.028.724-1.822 1.698-1.822s1.698.79 1.698 1.822v.043zm.039-12.285l-.84 8.06c-.057.581-.408.943-.897.943-.49 0-.84-.367-.896-.942l-.84-8.065c-.057-.624.25-1.095.779-1.095h1.91c.528.005.84.476.784 1.1z"}),null)}function ko(t){return f.createVNode(Fr,f.mergeProps(t,{path:"M12 0a12 12 0 1012 12A12.013 12.013 0 0012 0zm.25 5a1.5 1.5 0 11-1.5 1.5 1.5 1.5 0 011.5-1.5zm2.25 13.5h-4a1 1 0 010-2h.75a.25.25 0 00.25-.25v-4.5a.25.25 0 00-.25-.25h-.75a1 1 0 010-2h1a2 2 0 012 2v4.75a.25.25 0 00.25.25h.75a1 1 0 110 2z"}),null)}function Mo(t){return f.createVNode(Fr,f.mergeProps(t,{path:"M12 0a12 12 0 1012 12A12.014 12.014 0 0012 0zm6.927 8.2l-6.845 9.289a1.011 1.011 0 01-1.43.188l-4.888-3.908a1 1 0 111.25-1.562l4.076 3.261 6.227-8.451a1 1 0 111.61 1.183z"}),null)}function Lo(t){return f.createVNode(Fr,f.mergeProps(t,{path:"M11.983 0a12.206 12.206 0 00-8.51 3.653A11.8 11.8 0 000 12.207 11.779 11.779 0 0011.8 24h.214A12.111 12.111 0 0024 11.791 11.766 11.766 0 0011.983 0zM10.5 16.542a1.476 1.476 0 011.449-1.53h.027a1.527 1.527 0 011.523 1.47 1.475 1.475 0 01-1.449 1.53h-.027a1.529 1.529 0 01-1.523-1.47zM11 12.5v-6a1 1 0 012 0v6a1 1 0 11-2 0z"}),null)}function Fo(){return f.createVNode("div",{class:`${W.CSS_NAMESPACE}__spinner`},null)}const br={info:ko,warning:Po,success:Mo,error:Lo,spinner:Fo},Vo=t=>t in br;function Uo({theme:t,type:e,isLoading:r,icon:n}){let i;const a=!!r||e==="loading",o={theme:t,type:e};if(a&&(n===void 0||typeof n=="boolean"))return br.spinner();if(n!==!1){if(Ar(n))i=f.toRaw(n);else if(Nt(n)){const s=n;o.type=a?"loading":e,i=s(o),i=!i&&a?br.spinner():i}else f.isVNode(n)?i=f.cloneVNode(n,o):xn(n)||Oo(n)?i=n:Vo(e)&&(i=br[e](o));return i}}const Ho=()=>{};function $o(t,e,r=W.COLLAPSE_DURATION){const{scrollHeight:n,style:i}=t,a=r;requestAnimationFrame(()=>{i.minHeight="initial",i.height=n+"px",i.transition=`all ${a}ms`,requestAnimationFrame(()=>{i.height="0",i.padding="0",i.margin="0",setTimeout(e,a)})})}function Go(t){const e=f.ref(!1),r=f.ref(!1),n=f.ref(!1),i=f.ref(Cr.Enter),a=f.reactive({...t,appendPosition:t.appendPosition||!1,collapse:typeof t.collapse>"u"?!0:t.collapse,collapseDuration:t.collapseDuration||W.COLLAPSE_DURATION}),o=a.done||Ho,s=f.computed(()=>a.appendPosition?`${a.enter}--${a.position}`:a.enter),c=f.computed(()=>a.appendPosition?`${a.exit}--${a.position}`:a.exit),u=f.computed(()=>t.pauseOnHover?{onMouseenter:y,onMouseleave:g}:{});function l(){const m=s.value.split(" ");v().addEventListener(hn.ENTRANCE_ANIMATION_END,g,{once:!0});const _=I=>{const D=v();I.target===D&&(D.dispatchEvent(new Event(hn.ENTRANCE_ANIMATION_END)),D.removeEventListener("animationend",_),D.removeEventListener("animationcancel",_),i.value===Cr.Enter&&I.type!=="animationcancel"&&D.classList.remove(...m))},A=()=>{const I=v();I.classList.add(...m),I.addEventListener("animationend",_),I.addEventListener("animationcancel",_)};t.pauseOnFocusLoss&&h(),A()}function d(){if(!v())return;const m=()=>{const A=v();A.removeEventListener("animationend",m),a.collapse?$o(A,o,a.collapseDuration):o()},_=()=>{const A=v();i.value=Cr.Exit,A&&(A.className+=` ${c.value}`,A.addEventListener("animationend",m))};r.value||(n.value?m():setTimeout(_))}function v(){return t.toastRef.value}function h(){document.hasFocus()||y(),window.addEventListener("focus",g),window.addEventListener("blur",y)}function p(){window.removeEventListener("focus",g),window.removeEventListener("blur",y)}function g(){(!t.loading.value||t.isLoading===void 0)&&(e.value=!0)}function y(){e.value=!1}function w(m){m&&(m.stopPropagation(),m.preventDefault()),r.value=!1}return f.watchEffect(d),f.watchEffect(()=>{const m=Bt();r.value=m.findIndex(_=>_.toastId===a.toastId)>-1}),f.watchEffect(()=>{t.isLoading!==void 0&&(t.loading.value?y():g())}),f.onMounted(l),f.onUnmounted(()=>{t.pauseOnFocusLoss&&p()}),{isIn:r,isRunning:e,hideToast:w,eventHandlers:u}}function zo(t){if(!t||typeof t!="object"||Array.isArray(t)||t.__v_isVNode)return!1;const e=t;return["title","content"].some(r=>r in e)}const Wo=f.defineComponent({name:"ToastItem",inheritAttrs:!1,props:$i,setup(t){const e=f.ref(),r=f.computed(()=>!!t.isLoading),n=f.computed(()=>t.progress!==void 0&&t.progress!==null),i=f.computed(()=>Uo(t)),a=f.computed(()=>[`${W.CSS_NAMESPACE}__toast`,`${W.CSS_NAMESPACE}__toast-theme--${t.theme}`,`${W.CSS_NAMESPACE}__toast--${t.type}`,t.rtl?`${W.CSS_NAMESPACE}__toast--rtl`:void 0,t.toastClassName||""].filter(Boolean).join(" ")),{isRunning:o,isIn:s,hideToast:c,eventHandlers:u}=Go({toastRef:e,loading:r,done:()=>{Pe.remove(t.toastId)},...Li(t.transition,t.disabledEnterTransition),...t});function l(){const d=t.content;if(zo(d)){const v=[];return d.title!==void 0&&v.push(f.createVNode("div",{"data-testid":"toast-text-title",class:`${W.CSS_NAMESPACE}__toast-text-title`},[d.title])),d.content!==void 0&&v.push(f.createVNode("div",{"data-testid":"toast-text-content",class:`${W.CSS_NAMESPACE}__toast-text-content`},[d.content])),f.createVNode("div",{"data-testid":"toast-text-content-wrapper",class:`${W.CSS_NAMESPACE}__toast-text`},[v])}return Ar(d)?f.h(f.toRaw(d),{toastProps:f.toRaw(t),closeToast:c,data:t.data,...t.expandCustomProps?t.contentProps:{contentProps:t.contentProps||{}}}):Nt(d)?d({toastProps:f.toRaw(t),closeToast:c,data:t.data}):t.dangerouslyHTMLString?f.h("div",{innerHTML:d}):d}return()=>f.createVNode("div",f.mergeProps({id:t.toastId,class:a.value,style:t.toastStyle||{},ref:e,"data-testid":`toast-item-${t.toastId}`,onClick:d=>{t.closeOnClick&&c(),t.onClick&&t.onClick(d)}},u.value),[f.createVNode("div",{role:t.role,"data-testid":"toast-body",class:`${W.CSS_NAMESPACE}__toast-body ${t.bodyClassName||""}`},[i.value!=null&&f.createVNode("div",{"data-testid":`toast-icon-${t.type}`,class:[`${W.CSS_NAMESPACE}__toast-icon`,t.isLoading?"":`${W.CSS_NAMESPACE}--animate-icon ${W.CSS_NAMESPACE}__zoom-enter`].join(" ")},[Ar(i.value)?f.h(f.toRaw(i.value),{theme:t.theme,type:t.type}):Nt(i.value)?i.value({theme:t.theme,type:t.type}):i.value]),f.createVNode("div",{"data-testid":"toast-content"},[l()])]),(t.closeButton===void 0||t.closeButton===!0)&&f.createVNode(Ro,{theme:t.theme,closeToast:d=>{d.stopPropagation(),d.preventDefault(),c()}},null),Ar(t.closeButton)?f.h(f.toRaw(t.closeButton),{closeToast:c,type:t.type,theme:t.theme}):Nt(t.closeButton)?t.closeButton({closeToast:c,type:t.type,theme:t.theme}):null,f.createVNode(Bo,{className:t.progressClassName,style:t.progressStyle,rtl:t.rtl,theme:t.theme,isIn:s.value,type:t.type,hide:t.hideProgressBar,isRunning:o.value,autoClose:t.autoClose,controlledProgress:n.value,progress:t.progress,closeToast:t.isLoading?void 0:c},null)])}}),Br="vue3-toastify:url-change";let lr=0,er;function Xo(){if(!(typeof window>"u")&&Dr.lastUrl!==window.location.href){Dr.lastUrl=window.location.href;const t=r=>typeof r.clearOnUrlChange=="boolean"?r.clearOnUrlChange:Hi().clearOnUrlChange!==!1,e=Object.values(pe).reduce((r,n)=>(Array.isArray(n)&&r.push(...n),r),[]);for(const r of e)r.toastId&&t(r)&&Pe.dismiss(r.toastId);Fe.items=Fe.items.filter(r=>!t(r.toastProps))}}function jo(){const{history:t}=window,e=t.pushState,r=t.replaceState;return t.pushState=function(...n){const i=e.apply(this,n);return window.dispatchEvent(new Event(Br)),i},t.replaceState=function(...n){const i=r.apply(this,n);return window.dispatchEvent(new Event(Br)),i},()=>{t.pushState=e,t.replaceState=r}}function Yo(){if(typeof window>"u"||er)return;const t=jo(),e=()=>Xo();window.addEventListener(Br,e),window.addEventListener("popstate",e),window.addEventListener("hashchange",e),er=()=>{t(),window.removeEventListener(Br,e),window.removeEventListener("popstate",e),window.removeEventListener("hashchange",e),er=void 0}}function Ko(){er&&(er(),Dr.lastUrl="")}const Zo=f.defineComponent({name:"ToastifyContainer",inheritAttrs:!1,props:$i,setup(t){const e=f.computed(()=>t.containerId),r=f.computed(()=>pe[e.value]||[]),n=f.computed(()=>r.value.filter(i=>i.position===t.position));return f.onMounted(()=>{typeof window<"u"&&(lr+=1,Yo())}),f.onUnmounted(()=>{typeof window<"u"&&lr>0&&(lr-=1,lr===0&&Ko())}),()=>f.createVNode(f.Fragment,null,[n.value.map(i=>{const{toastId:a=""}=i;return f.createVNode(Wo,f.mergeProps({key:a},i),null)})])}});let jr=!1;const Gi={isLoading:!0,autoClose:!1,closeOnClick:!1,closeButton:!1,draggable:!1};function zi(){const t=[];return Bt().forEach(e=>{const r=document.getElementById(e.containerId);r&&!r.classList.contains(Mr)&&t.push(e)}),t}function qo(t){const e=zi().length,r=t??0;return r>0&&e+Fe.items.length>=r}function Qo(t){qo(t.limit)&&!t.updateId&&Fe.items.push({toastId:t.toastId,containerId:t.containerId,toastContent:t.content,toastProps:t})}function lt(t,e,r={}){if(jr)return;r=Lr(Hi(),{type:e},f.toRaw(r)),(!r.toastId||typeof r.toastId!="string"&&typeof r.toastId!="number")&&(r.toastId=Ui()),r={...r,...r.type==="loading"?Gi:{},content:t,containerId:r.containerId||String(r.position)};const n=Number(r?.progress);return!isNaN(n)&&n<0&&(r.progress=0),n>1&&(r.progress=1),r.theme==="auto"&&(r.theme=No()),Qo(r),Dr.lastUrl=window.location.href,r.multiple?Fe.items.length?r.updateId&&Er(t,r):Er(t,r):(jr=!0,ee.clearAll(void 0,!1),setTimeout(()=>{Er(t,r)},0),setTimeout(()=>{jr=!1},390)),r.toastId}const ee=(t,e)=>lt(t,Se.DEFAULT,e);ee.info=(t,e)=>lt(t,Se.DEFAULT,{...e,type:Se.INFO});ee.error=(t,e)=>lt(t,Se.DEFAULT,{...e,type:Se.ERROR});ee.warning=(t,e)=>lt(t,Se.DEFAULT,{...e,type:Se.WARNING});ee.warn=ee.warning;ee.success=(t,e)=>lt(t,Se.DEFAULT,{...e,type:Se.SUCCESS});ee.loading=(t,e)=>lt(t,Se.DEFAULT,Lr(e,Gi));ee.dark=(t,e)=>lt(t,Se.DEFAULT,Lr(e,{theme:Dt.DARK}));ee.remove=t=>{t?Pe.dismiss(t):Pe.clear()};ee.clearAll=(t,e)=>{f.nextTick(()=>{Pe.clear(t,e)})};ee.isActive=t=>{let e=!1;return e=zi().findIndex(r=>r.toastId===t)>-1,e};ee.update=(t,e={})=>{setTimeout(()=>{const r=So(t);if(r){const n=f.toRaw(r),{content:i}=n,a={...n,...e,toastId:e.toastId||t,updateId:Ui()},o=a.render||i;delete a.render,lt(o,a.type,a)}},0)};ee.done=t=>{ee.update(t,{isLoading:!1,progress:1})};ee.promise=Jo;function Jo(t,{pending:e,error:r,success:n},i){var a,o,s;let c;const u={...i||{},autoClose:!1};e&&(c=xn(e)?ee.loading(e,u):ee.loading(e.render,{...u,...e}));const l={autoClose:(a=i?.autoClose)!=null?a:!0,closeOnClick:(o=i?.closeOnClick)!=null?o:!0,closeButton:(s=i?.autoClose)!=null?s:null,isLoading:void 0,draggable:null,delay:100},d=(h,p,g)=>{if(p==null){ee.remove(c);return}const y={type:h,...l,...i,data:g},w=xn(p)?{render:p}:p;return c?ee.update(c,{...y,...w,isLoading:!1}):ee(w.render,{...y,...w,isLoading:!1}),g},v=Nt(t)?t():t;return v.then(h=>{d("success",n,h)}).catch(h=>{d("error",r,h)}),v}ee.POSITION=ur;ee.THEME=Dt;ee.TYPE=Se;ee.TRANSITIONS=oo;const es={install(t,e={}){Io.useHandler=e.useHandler||(()=>{}),ts(e)}};typeof window<"u"&&(window.Vue3Toastify=es);function ts(t={}){const e=Lr(Mi,t);To(e)}const rs={class:"dsg-alert__wrapper"},ns=["innerHTML"],Wi=f.defineComponent({__name:"DsgAlertComponent",props:{contentProps:{default:()=>({title:"",message:"",type:"gray",hasCloseButton:!0,useToast:!0,timeout:!1})}},setup(t){const r=f.useAttrs().closeToast,n=f.ref(!1);let i=null;const a=()=>{t.contentProps.useToast?r():n.value=!0};return f.onMounted(()=>{t.contentProps.timeout&&t.contentProps.timeout>0&&(i=setTimeout(()=>{a()},t.contentProps.timeout))}),f.onBeforeUnmount(()=>{i&&(clearTimeout(i),i=null)}),(o,s)=>n.value?f.createCommentVNode("",!0):(f.openBlock(),f.createElementBlock("div",{key:0,class:f.normalizeClass(`
18
18
  dsg-alert
19
19
  dsg-alert--${t.contentProps.type}
20
20
  ${t.contentProps.hasCloseButton?"dsg-alert--has-close":"dsg-alert--no-close"}
21
- `)},[t.contentProps.type==="gray"?(f.openBlock(),f.createBlock(It,{key:0,icon:{icon:"info-circle"},type:"outline",theme:"gray",size:"lg"})):f.createCommentVNode("",!0),t.contentProps.type==="error"?(f.openBlock(),f.createBlock(It,{key:1,icon:{icon:"alert-circle"},type:"outline",theme:"error",size:"lg"})):f.createCommentVNode("",!0),t.contentProps.type==="warning"?(f.openBlock(),f.createBlock(It,{key:2,icon:{icon:"alert-circle"},type:"outline",theme:"warning",size:"lg"})):f.createCommentVNode("",!0),t.contentProps.type==="success"?(f.openBlock(),f.createBlock(It,{key:3,icon:{icon:"check-circle"},type:"outline",theme:"success",size:"lg"})):f.createCommentVNode("",!0),f.createElementVNode("div",rs,[f.createElementVNode("p",{class:f.normalizeClass(["dsg-alert__title",{"dsg-alert__title--with-close-button":t.contentProps.hasCloseButton}])},f.toDisplayString(t.contentProps.title),3),t.contentProps.message?(f.openBlock(),f.createElementBlock("p",{key:0,innerHTML:t.contentProps.message,class:"dsg-alert__message"},null,8,ns)):f.createCommentVNode("",!0)]),t.contentProps.hasCloseButton?(f.openBlock(),f.createElementBlock("button",{key:4,onClick:a,class:"dsg-alert__close-button"},[f.createVNode(M._sfc_main,{icon:"x-close",size:"sm"})])):f.createCommentVNode("",!0)],2))}}),is=new class jt{info(e="",r="",n={}){jt.showToast("gray",e,r,n)}error(e="",r="",n={}){jt.showToast("error",e,r,n)}warning(e="",r="",n={}){jt.showToast("warning",e,r,n)}success(e="",r="",n={}){jt.showToast("success",e,r,n)}static showToast(e,r,n,i){const a={hasCloseButton:!1,timeout:3e3,position:"top-right",maxWidthClass:"",...i};ee(Wi,{autoClose:a.hasCloseButton?!1:a.timeout,closeButton:!1,hideProgressBar:!0,closeOnClick:!a.hasCloseButton,position:a.position,containerClassName:`dsg-alert-container ${a.maxWidthClass}`,toastClassName:"dsg-alert",bodyClassName:"dsg-alert--body",contentProps:{title:r,message:n,type:e,hasCloseButton:a.hasCloseButton,useToast:!0,timeout:a.timeout},onClick:()=>{}})}},as={class:"dsg-icon-select"},os={class:"dsg-icon-select__user-option"},ss=["data-initials"],cs=["src"],us={class:"dsg-icon-select__meta"},fs={class:"dsg-icon-select__name"},ls={key:0,class:"dsg-icon-select__email"},ds={class:"dsg-icon-select__tags"},hs=["data-initials"],vs=["src"],ps={key:0,class:"dsg-icon-select__placeholder-wrapper"},gs={class:"dsg-icon-select__placeholder"},xs={key:0,class:"dsg-icon-select__single-display"},ys=["data-initials"],ms=["src"],ws={key:0,class:"dsg-icon-select__name"},_s={class:"dsg-icon-select__placeholder"},Es=f.defineComponent({__name:"DsgIconSelect",props:{modelValue:{},options:{},endpoint:{},queryParam:{default:"q"},extraParams:{},method:{default:"GET"},minChars:{default:1},delay:{default:300},multiple:{type:Boolean,default:!1},trackBy:{default:"id"},labelKey:{default:"primaryText"},secondaryTextKey:{default:"secondaryText"},iconKey:{default:"iconUrl"},placeholder:{default:"Search..."},clearOnSelect:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},selectLabel:{default:""},selectedLabel:{default:""},hideSelectedLabel:{type:Boolean,default:!1}},emits:["update:modelValue","change","search","loaded","error"],setup(t,{emit:e}){const r=t,n=e,i=f.ref(r.options??[]),a=f.ref(!1),o=f.ref("");let s,c=null;f.watch(()=>r.options,g=>{g&&(i.value=[...g])});const u=(g,y)=>{if(g)return g[y]},l=g=>{if(!g)return"";const y=g.trim().split(/\s+/),w=y[0]?.[0]??"",m=y.length>1?y[y.length-1][0]??"":"";return(w+m).toUpperCase()};f.computed(()=>r.multiple?r.modelValue??[]:r.modelValue?[r.modelValue]:[]);const d=f.computed(()=>!!r.endpoint),v=async g=>{if(d.value&&!((g?.length??0)<r.minChars)){a.value=!0,c?.abort(),c=new AbortController;try{const y=new URL(r.endpoint);if(r.method==="GET"){y.searchParams.set(r.queryParam,g),r.extraParams&&Object.entries(r.extraParams).forEach(([_,A])=>y.searchParams.set(_,String(A)));const w=await fetch(y.toString(),{signal:c.signal});if(!w.ok)throw new Error(`Request failed: ${w.status}`);const m=await w.json();i.value=Array.isArray(m)?m:m?.items??[],n("loaded",i.value)}else{const w={[r.queryParam]:g,...r.extraParams??{}},m=await fetch(y.toString(),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(w),signal:c.signal});if(!m.ok)throw new Error(`Request failed: ${m.status}`);const _=await m.json();i.value=Array.isArray(_)?_:_?.items??[],n("loaded",i.value)}}catch(y){y?.name!=="AbortError"&&(console.error(y),n("error",y))}finally{a.value=!1}}},h=g=>{o.value=g,n("search",g),d.value&&(window.clearTimeout(s),s=window.setTimeout(()=>v(g),r.delay))},p=g=>{n("update:modelValue",g),n("change",g)};return(g,y)=>(f.openBlock(),f.createElementBlock("div",as,[f.createVNode(f.unref(M.script),{"model-value":t.modelValue,"onUpdate:modelValue":p,options:i.value,multiple:t.multiple,"track-by":t.trackBy,searchable:!0,"internal-search":!d.value,loading:a.value,"clear-on-select":!1,"close-on-select":!t.multiple,deselectLabel:"",placeholder:t.placeholder,disabled:t.disabled,label:"name","allow-empty":!0,onSearchChange:h,"select-label":t.selectLabel,"selected-label":t.selectedLabel,class:"dsg-icon-select__multiselect"},{option:f.withCtx(({option:w})=>[f.createElementVNode("div",os,[f.createElementVNode("div",{class:"dsg-icon-select__avatar","data-initials":l(u(w,t.labelKey))},[u(w,t.iconKey)?(f.openBlock(),f.createElementBlock("img",{key:0,src:u(w,t.iconKey),alt:""},null,8,cs)):f.createCommentVNode("",!0)],8,ss),f.createElementVNode("div",us,[f.createElementVNode("div",fs,f.toDisplayString(u(w,t.labelKey)),1),w.secondaryText?(f.openBlock(),f.createElementBlock("div",ls,f.toDisplayString(w.secondaryText),1)):f.createCommentVNode("",!0)])])]),selection:f.withCtx(({values:w,isOpen:m})=>[f.createElementVNode("div",ds,[(f.openBlock(!0),f.createElementBlock(f.Fragment,null,f.renderList(w,_=>(f.openBlock(),f.createElementBlock("div",{class:"dsg-icon-select__avatar","data-initials":l(u(_,t.labelKey))},[u(_,t.iconKey)?(f.openBlock(),f.createElementBlock("img",{key:0,src:u(_,t.iconKey),alt:""},null,8,vs)):f.createCommentVNode("",!0)],8,hs))),256)),t.multiple&&w.length>0?(f.openBlock(),f.createElementBlock("div",ps,[f.createElementVNode("div",gs,[f.createVNode(M._sfc_main,{icon:"plus",size:"xs"})])])):f.createCommentVNode("",!0)])]),singleLabel:f.withCtx(({option:w})=>[w?(f.openBlock(),f.createElementBlock("div",xs,[f.createElementVNode("div",{class:"dsg-icon-select__avatar","data-initials":l(u(w,t.labelKey))},[u(w,t.iconKey)?(f.openBlock(),f.createElementBlock("img",{key:0,src:u(w,t.iconKey),alt:""},null,8,ms)):f.createCommentVNode("",!0)],8,ys),t.hideSelectedLabel?f.createCommentVNode("",!0):(f.openBlock(),f.createElementBlock("span",ws,f.toDisplayString(u(w,t.labelKey)),1))])):f.createCommentVNode("",!0)]),placeholder:f.withCtx(()=>[f.createElementVNode("div",_s,[f.createVNode(M._sfc_main,{icon:"plus",size:"xs"})])]),noResult:f.withCtx(()=>[...y[0]||(y[0]=[f.createElementVNode("div",{class:"dsg-icon-select__empty"},"No results found.",-1)])]),_:1},8,["model-value","options","multiple","track-by","internal-search","loading","close-on-select","placeholder","disabled","select-label","selected-label"])]))}}),As={class:"dsg-badge__before"},Cs={key:2,class:"dsg-badge__dot"},bs={key:1,class:"dsg-badge__label"},Ss={class:"dsg-badge__after"},Is={key:1,class:"dsg-badge__close-wrapper"},Xi=f.defineComponent({__name:"DsgBadge",props:{label:{default:""},type:{default:"standard"},size:{default:"md"},hasClose:{type:Boolean,default:!1},avatarUri:{default:""},iconBefore:{default:""},icon:{default:""},iconAfter:{default:""},iconOnly:{type:Boolean,default:!1},hasDot:{type:Boolean,default:!1},theme:{default:"badge-modern"},themeColor:{default:"gray"},destroyOnClose:{type:Boolean,default:!1}},emits:["before-hide","after-hide","before-destroy","after-destroy","on-click"],setup(t,{expose:e,emit:r}){const n=t.iconBefore||t.iconAfter||t.type==="add"||t.type==="icon-only";(t.type==="add"||t.type==="icon-only")&&(t.label||t.avatarUri||t.hasDot||t.iconBefore||t.iconAfter||t.hasClose)&&t.theme!=="badge-modern"&&t.themeColor&&new M.DsgPropSyntaxWarning("DsgBadge: 'add'/'icon-only' type badges should only be called with 'size', 'theme' and 'themeColor' props. Note that 'themeColor' prop is discarded for theme 'badge-modern'."),[t.avatarUri,t.iconBefore,t.hasDot].filter(Boolean).length>1&&new M.DsgPropSyntaxWarning("DsgBadge: 'avatarUri', 'iconBefore' and 'hasDot' props are mutually exclusive. Please use only one of them."),[t.iconAfter,t.hasClose].filter(Boolean).length>1&&new M.DsgPropSyntaxWarning("DsgBadge: 'iconAfter' and 'hasClose' props are mutually exclusive. Please use only one of them.");const o=r,s=f.useTemplateRef("dsgBadge"),c=l=>{t.destroyOnClose?(o("before-destroy",s.value),s.value?.remove(),o("after-destroy")):(o("before-hide",s.value),s.value&&(s.value.style.display="none"),o("after-hide",s.value))},u=l=>{o("on-click",s.value)};return e({hideOrDestroy:c,clickEvent:u}),(l,d)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(["dsg-badge",`dsg-badge--${t.size}`,`dsg-badge--${t.type}`,`dsg-badge--${t.theme}`,`dsg-badge--${t.themeColor}`,`dsg-badge--${t.iconOnly?"icon-only":"label"}`,t.hasClose?"dsg-badge--has-close":"",t.avatarUri?"dsg-badge--has-avatar":"",t.hasDot?"dsg-badge--has-dot":"",f.unref(n)?"dsg-badge--has-icon":"",t.iconBefore?"dsg-badge--has-icon-before":"",t.iconAfter?"dsg-badge--has-icon-after":""]),ref:"dsgBadge",onClick:u},[t.type==="standard"&&(t.avatarUri||t.iconBefore||t.hasDot)?f.renderSlot(l.$slots,"dsg-badge--before",{key:0},()=>[f.createElementVNode("div",As,[t.avatarUri?(f.openBlock(),f.createBlock(rr,{key:0,"profile-uri":t.avatarUri,class:"dsg-badge__avatar",size:"xxs","no-focus":""},null,8,["profile-uri"])):f.createCommentVNode("",!0),t.iconBefore?(f.openBlock(),f.createBlock(M._sfc_main,{key:1,icon:t.iconBefore,size:"xxs",class:"dsg-badge__icon dsg-badge__icon--before"},null,8,["icon"])):f.createCommentVNode("",!0),t.hasDot?(f.openBlock(),f.createElementBlock("span",Cs)):f.createCommentVNode("",!0)])]):f.createCommentVNode("",!0),t.type==="standard"?(f.openBlock(),f.createElementBlock("label",bs,f.toDisplayString(t.label),1)):f.createCommentVNode("",!0),t.type==="add"?(f.openBlock(),f.createBlock(M._sfc_main,{key:2,icon:"plus",size:"xxs",class:"dsg-badge__icon dsg-badge__icon--add"})):f.createCommentVNode("",!0),t.type==="icon-only"?(f.openBlock(),f.createBlock(M._sfc_main,{key:3,icon:t.icon,size:"xxs",class:"dsg-badge__icon dsg-badge__icon--only"},null,8,["icon"])):f.createCommentVNode("",!0),t.type==="standard"&&(t.iconAfter||t.hasClose)?f.renderSlot(l.$slots,"dsg-badge--after",{key:4},()=>[f.createElementVNode("div",Ss,[t.iconAfter?(f.openBlock(),f.createBlock(M._sfc_main,{key:0,icon:t.iconAfter,size:"xxs",class:"dsg-badge__icon dsg-badge__icon--after"},null,8,["icon"])):f.createCommentVNode("",!0),t.hasClose?(f.openBlock(),f.createElementBlock("span",Is,[t.hasClose?(f.openBlock(),f.createBlock(M._sfc_main,{key:0,icon:"x-close",class:"dsg-badge__close",size:"xxs",onClick:c})):f.createCommentVNode("",!0)])):f.createCommentVNode("",!0)])]):f.createCommentVNode("",!0)],2))}}),Os={class:"dsg-input-number__control"},Ts=["disabled"],Ns=["value","disabled"],Ds=["disabled"],Bs={key:0,class:"dsg-input-number__label"},Rs=f.defineComponent({__name:"DsgInputNumber",props:{modelValue:{},disabled:{type:Boolean},label:{},step:{}},emits:["update:modelValue"],setup(t,{emit:e}){const r=t,n=e,i=()=>{r.disabled||n("update:modelValue",r.modelValue+(r.step??1))},a=()=>{r.disabled||n("update:modelValue",r.modelValue-(r.step??1))},o=s=>{if(r.disabled)return;const c=s.target;n("update:modelValue",Number(c.value))};return(s,c)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(["dsg-input-number",{"dsg-input-number--disabled":r.disabled}])},[f.createElementVNode("div",Os,[f.createElementVNode("button",{type:"button",onClick:a,disabled:r.disabled,class:"dsg-input-number__btn dsg-input-number__btn--decrement"},[r.disabled?f.createCommentVNode("",!0):(f.openBlock(),f.createBlock(M._sfc_main,{key:0,icon:"minus",size:"sm"}))],8,Ts),f.createElementVNode("input",{type:"number",value:t.modelValue,onInput:o,disabled:r.disabled,class:"dsg-input-number__input"},null,40,Ns),f.createElementVNode("button",{type:"button",disabled:r.disabled,onClick:i,class:"dsg-input-number__btn dsg-input-number__btn--increment"},[r.disabled?f.createCommentVNode("",!0):(f.openBlock(),f.createBlock(M._sfc_main,{key:0,icon:"plus",size:"sm"}))],8,Ds)]),t.label!==void 0||s.$slots.label?(f.openBlock(),f.createElementBlock("div",Bs,[f.renderSlot(s.$slots,"label",{},()=>[f.createTextVNode(f.toDisplayString(t.label),1)])])):f.createCommentVNode("",!0)],2))}}),Ps={key:0,class:"dsg-checkbox-group__form-wrapper"},ks={key:0,class:"dsg-checkbox-group__header"},Ms={class:"dsg-checkbox-group__header-title-wrapper"},Ls={class:"dsg-checkbox-group__title"},Fs=["innerHTML"],Vs={class:"dsg-checkbox-group__options"},Us=["onClick"],Hs=["textContent"],$s=["innerHTML","data"],Gs=f.defineComponent({__name:"DsgCheckboxGroup",props:f.mergeModels({size:{default:"md"},theme:{default:"form"},title:{default:""},subtext:{default:""},options:{default:()=>[]},tooltip:{default:null},defaultValue:{type:[String,Number,Boolean,Array,null],default:()=>[]}},{modelValue:{type:[String,Number,Boolean,Array,null],default:[]},modelModifiers:{}}),emits:["update:modelValue"],setup(t){const e=f.useModel(t,"modelValue"),r=(n,i)=>{n.target instanceof HTMLAnchorElement||(e.value=i.value)};return(n,i)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(`dsg-checkbox-group dsg-checkbox-group--${t.size} dsg-checkbox-group--${t.theme}`)},[["form","form-radio"].includes(t.theme)?(f.openBlock(),f.createElementBlock("div",Ps,[t.title||t.subtext?(f.openBlock(),f.createElementBlock("div",ks,[f.renderSlot(n.$slots,"dsg-checkbox-group--header",{},()=>[f.createElementVNode("div",Ms,[f.createElementVNode("h3",Ls,f.toDisplayString(t.title),1),t.tooltip?(f.openBlock(),f.createBlock(M._sfc_main$1,{key:0,label:t.tooltip,position:"top",triggers:["hover"],"auto-hide":!0,theme:"dark",class:"dsg-checkbox-group__tooltip"},null,8,["label"])):f.createCommentVNode("",!0)]),t.subtext?(f.openBlock(),f.createElementBlock("p",{key:0,class:"dsg-checkbox-group__subtext",innerHTML:t.subtext},null,8,Fs)):f.createCommentVNode("",!0)])])):f.createCommentVNode("",!0),f.createElementVNode("div",Vs,[(f.openBlock(!0),f.createElementBlock(f.Fragment,null,f.renderList(t.options,(a,o)=>(f.openBlock(),f.createElementBlock("div",{key:o,class:"dsg-checkbox-group__option"},[f.createVNode(M._sfc_main$2,{label:a.label,value:a.value,disabled:a.disabled,size:"sm",type:["form","panel"].includes(t.theme)?"checkbox":"radio",modelValue:e.value,"onUpdate:modelValue":i[0]||(i[0]=s=>e.value=s)},null,8,["label","value","disabled","type","modelValue"])]))),128))])])):f.createCommentVNode("",!0),["panel","panel-content"].includes(t.theme)?(f.openBlock(!0),f.createElementBlock(f.Fragment,{key:1},f.renderList(t.options,(a,o)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(["dsg-checkbox-group__panel",`dsg-checkbox-group__panel--${e.value===a.value?"selected":"unselected"}`]),onClick:s=>r(s,a)},[(f.openBlock(),f.createElementBlock("div",{class:"dsg-checkbox-group__panel-left",key:o},[f.renderSlot(n.$slots,`dsg-checkbox-group__panel-title--${String(a.value).trim().toLowerCase().replace(/[^0-9a-zA-Z]/g,"-").replace(/-+/g,"-")}`,{data:a},()=>[a.icon?(f.openBlock(),f.createBlock(M._sfc_main,{key:0,icon:a.icon,size:"xl"},null,8,["icon"])):f.createCommentVNode("",!0),f.createElementVNode("h3",{class:"dsg-checkbox-group__panel-title",textContent:f.toDisplayString(a.label)},null,8,Hs)]),f.renderSlot(n.$slots,`dsg-checkbox-group__panel-subtext--${String(a.value).trim().toLowerCase().replace(/[^0-9a-zA-Z]/g,"-").replace(/-+/g,"-")}`,{},()=>[a.subtext?(f.openBlock(),f.createElementBlock("p",{key:0,class:"dsg-checkbox-group__panel-subtext",innerHTML:a.subtext,data:a},null,8,$s)):f.createCommentVNode("",!0)])])),(f.openBlock(),f.createElementBlock("div",{key:o,class:"dsg-checkbox-group__panel-right"},[f.createVNode(M._sfc_main$2,{value:a.value,disabled:a.disabled,type:"radio",modelValue:e.value,"onUpdate:modelValue":i[1]||(i[1]=s=>e.value=s)},null,8,["value","disabled","modelValue"])]))],10,Us))),256)):f.createCommentVNode("",!0)],2))}});var zs="2.0.10",ji=500,Kn="user-agent",Rt="",Zn="?",ue={FUNCTION:"function",OBJECT:"object",STRING:"string",UNDEFINED:"undefined"},De="browser",et="cpu",Ye="device",Ge="engine",ke="os",Pt="result",O="name",C="type",N="vendor",T="version",be="architecture",ir="major",S="model",Sr="console",H="mobile",Z="tablet",fe="smarttv",We="wearable",dr="xr",Yt="embedded",Ws="fetcher",qe="inapp",Mn="brands",yt="formFactors",Ln="fullVersionList",kt="platform",Fn="platformVersion",Vr="bitness",dt="sec-ch-ua",Xs=dt+"-full-version-list",js=dt+"-arch",Ys=dt+"-"+Vr,Ks=dt+"-form-factors",Zs=dt+"-"+H,qs=dt+"-"+S,Yi=dt+"-"+kt,Qs=Yi+"-version",Ki=[Mn,Ln,H,S,kt,Fn,be,yt,Vr],hr="Amazon",Et="Apple",qn="ASUS",Qn="BlackBerry",ht="Google",Yr="Huawei",Kr="Lenovo",Jn="Honor",vr="LG",Zr="Microsoft",qr="Motorola",ei="Nvidia",ti="OnePlus",Qr="OPPO",Ut="Samsung",ri="Sharp",Ht="Sony",Jr="Xiaomi",en="Zebra",ni="Chrome",ii="Chromium",nt="Chromecast",Ir="Edge",$t="Firefox",At="Opera",tn="Facebook",ai="Sogou",Ct="Mobile ",vt=" Browser",yn="Windows",Js=typeof window!==ue.UNDEFINED,Te=Js&&window.navigator?window.navigator:void 0,mt=Te&&Te.userAgentData?Te.userAgentData:void 0,e1=function(t,e){var r={},n=e;if(!Rr(e)){n={};for(var i in e)for(var a in e[i])n[a]=e[i][a].concat(n[a]?n[a]:[])}for(var o in t)r[o]=n[o]&&n[o].length%2===0?n[o].concat(t[o]):t[o];return r},Ur=function(t){for(var e={},r=0;r<t.length;r++)e[t[r].toUpperCase()]=t[r];return e},mn=function(t,e){if(typeof t===ue.OBJECT&&t.length>0){for(var r in t)if(st(e)==st(t[r]))return!0;return!1}return Lt(t)?st(e)==st(t):!1},Rr=function(t,e){for(var r in t)return/^(browser|cpu|device|engine|os)$/.test(r)||(e?Rr(t[r]):!1)},Lt=function(t){return typeof t===ue.STRING},rn=function(t){if(t){for(var e=[],r=St(t).split(","),n=0;n<r.length;n++)if(r[n].indexOf(";")>-1){var i=or(r[n]).split(";v=");e[n]={brand:i[0],version:i[1]}}else e[n]=or(r[n]);return e}},st=function(t){return Lt(t)?t.toLowerCase():t},wn=function(t){return Lt(t)?ar(/[^\d\.]/g,t).split(".")[0]:void 0},St=function(t){return Lt(t)?or(ar(/\\?\"/g,t),ji):void 0},Je=function(t){for(var e in t)if(t.hasOwnProperty(e)){var r=t[e];typeof r==ue.OBJECT&&r.length==2?this[r[0]]=r[1]:this[r]=void 0}return this},ar=function(t,e){return Lt(e)?e.replace(t,Rt):e},or=function(t,e){return t=ar(/^\s\s*/,String(t)),typeof e===ue.UNDEFINED?t:t.substring(0,e)},_n=function(t,e){if(!(!t||!e))for(var r=0,n,i,a,o,s,c;r<e.length&&!s;){var u=e[r],l=e[r+1];for(n=i=0;n<u.length&&!s&&u[n];)if(s=u[n++].exec(t),s)for(a=0;a<l.length;a++)c=s[++i],o=l[a],typeof o===ue.OBJECT&&o.length>0?o.length===2?typeof o[1]==ue.FUNCTION?this[o[0]]=o[1].call(this,c):this[o[0]]=o[1]:o.length>=3&&(typeof o[1]===ue.FUNCTION&&!(o[1].exec&&o[1].test)?o.length>3?this[o[0]]=c?o[1].apply(this,o.slice(2)):void 0:this[o[0]]=c?o[1].call(this,c,o[2]):void 0:o.length==3?this[o[0]]=c?c.replace(o[1],o[2]):void 0:o.length==4?this[o[0]]=c?o[3].call(this,c.replace(o[1],o[2])):void 0:o.length>4&&(this[o[0]]=c?o[3].apply(this,[c.replace(o[1],o[2])].concat(o.slice(4))):void 0)):this[o]=c||void 0;r+=2}},t1=function(t,e){return e.test.test(t)?e.ifTrue:e.ifFalse},He=function(t,e){for(var r in e)if(typeof e[r]===ue.OBJECT&&e[r].length>0){for(var n=0;n<e[r].length;n++)if(mn(e[r][n],t))return r===Zn?void 0:r}else if(mn(e[r],t))return r===Zn?void 0:r;return e.hasOwnProperty("*")?e["*"]:t},oi={ME:"4.90","NT 3.51":"3.51","NT 4.0":"4.0",2e3:["5.0","5.01"],XP:["5.1","5.2"],Vista:"6.0",7:"6.1",8:"6.2","8.1":"6.3",10:["6.4","10.0"],NT:""},si={embedded:"Automotive",mobile:"Mobile",tablet:["Tablet","EInk"],smarttv:"TV",wearable:"Watch",xr:["VR","XR"],"?":["Desktop","Unknown"],"*":void 0},r1={Chrome:"Google Chrome",Edge:"Microsoft Edge","Edge WebView2":"Microsoft Edge WebView2","Chrome WebView":"Android WebView","Chrome Headless":"HeadlessChrome","Huawei Browser":"HuaweiBrowser","MIUI Browser":"Miui Browser","Opera Mobi":"OperaMobile",Yandex:"YaBrowser"},n1={browser:[[/\b(?:crmo|crios)\/([\w\.]+)/i],[T,[O,Ct+"Chrome"]],[/webview.+edge\/([\w\.]+)/i],[T,[O,Ir+" WebView"],[C,qe]],[/edg(?:e|ios|a)?\/([\w\.]+)/i],[T,[O,"Edge"]],[/(opera mini)\/([-\w\.]+)/i,/(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,/(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i],[O,T],[/opios[\/ ]+([\w\.]+)/i],[T,[O,At+" Mini"]],[/\bop(?:rg)?x\/([\w\.]+)/i],[T,[O,At+" GX"]],[/\bopr\/([\w\.]+)/i],[T,[O,At]],[/\bb[ai]*d(?:uhd|[ub]*[aekoprswx]{5,6})[\/ ]?([\w\.]+)/i],[T,[O,"Baidu"]],[/\b(?:mxbrowser|mxios|myie2)\/?([-\w\.]*)\b/i],[T,[O,"Maxthon"]],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer|sleipnir)[\/ ]?([\w\.]*)/i,/(avant|iemobile|slim(?:browser|boat|jet))[\/ ]?([\d\.]*)/i,/(?:ms|\()(ie) ([\w\.]+)/i,/(atlas|flock|rockmelt|midori|epiphany|silk|skyfire|bolt|iron|vivaldi|iridium|phantomjs|bowser|qupzilla|falkon|rekonq|puffin|whale(?!.+naver)|qqbrowserlite|duckduckgo|klar|helio|(?=comodo_)?dragon|otter|dooble|(?:hi|lg |ovi|qute)browser|palemoon)\/v?([-\w\.]+)/i,/(brave)(?: chrome)?\/([\d\.]+)/i,/(aloha|heytap|ovi|115|surf|qwant)browser\/([\d\.]+)/i,/(qwant)(?:ios|mobile)\/([\d\.]+)/i,/(ecosia|weibo)(?:__| \w+@)([\d\.]+)/i],[O,T],[/quark(?:pc)?\/([-\w\.]+)/i],[T,[O,"Quark"]],[/\bddg\/([\w\.]+)/i],[T,[O,"DuckDuckGo"]],[/(?:\buc? ?browser|(?:juc.+)ucweb| ucpc)[\/ ]?([\w\.]+)/i],[T,[O,"UCBrowser"]],[/microm.+\bqbcore\/([\w\.]+)/i,/\bqbcore\/([\w\.]+).+microm/i,/micromessenger\/([\w\.]+)/i],[T,[O,"WeChat"]],[/konqueror\/([\w\.]+)/i],[T,[O,"Konqueror"]],[/trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i],[T,[O,"IE"]],[/ya(?:search)?browser\/([\w\.]+)/i],[T,[O,"Yandex"]],[/slbrowser\/([\w\.]+)/i],[T,[O,"Smart "+Kr+vt]],[/(av(?:ast|g|ira))\/([\w\.]+)/i],[[O,/(.+)/,"$1 Secure"+vt],T],[/norton\/([\w\.]+)/i],[T,[O,"Norton Private"+vt]],[/\bfocus\/([\w\.]+)/i],[T,[O,$t+" Focus"]],[/ mms\/([\w\.]+)$/i],[T,[O,At+" Neon"]],[/ opt\/([\w\.]+)$/i],[T,[O,At+" Touch"]],[/coc_coc\w+\/([\w\.]+)/i],[T,[O,"Coc Coc"]],[/dolfin\/([\w\.]+)/i],[T,[O,"Dolphin"]],[/coast\/([\w\.]+)/i],[T,[O,At+" Coast"]],[/miuibrowser\/([\w\.]+)/i],[T,[O,"MIUI"+vt]],[/fxios\/([\w\.-]+)/i],[T,[O,Ct+$t]],[/\bqihoobrowser\/?([\w\.]*)/i],[T,[O,"360"]],[/\b(qq)\/([\w\.]+)/i],[[O,/(.+)/,"$1Browser"],T],[/(oculus|sailfish|huawei|vivo|pico)browser\/([\w\.]+)/i],[[O,/(.+)/,"$1"+vt],T],[/ HBPC\/([\w\.]+)/],[T,[O,Yr+vt]],[/samsungbrowser\/([\w\.]+)/i],[T,[O,Ut+" Internet"]],[/metasr[\/ ]?([\d\.]+)/i],[T,[O,ai+" Explorer"]],[/(sogou)mo\w+\/([\d\.]+)/i],[[O,ai+" Mobile"],T],[/(electron)\/([\w\.]+) safari/i,/(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,/m?(qqbrowser|2345(?=browser|chrome|explorer))\w*[\/ ]?v?([\w\.]+)/i],[O,T],[/(lbbrowser|luakit|rekonq|steam(?= (clie|tenf|gameo)))/i],[O],[/ome\/([\w\.]+).+(iron(?= saf)|360(?=[es]e$))/i],[T,O],[/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i],[[O,tn],T,[C,qe]],[/(kakao(?:talk|story))[\/ ]([\w\.]+)/i,/(naver)\(.*?(\d+\.[\w\.]+).*\)/i,/(daum)apps[\/ ]([\w\.]+)/i,/safari (line)\/([\w\.]+)/i,/\b(line)\/([\w\.]+)\/iab/i,/(alipay)client\/([\w\.]+)/i,/(twitter)(?:and| f.+e\/([\w\.]+))/i,/(bing)(?:web|sapphire)\/([\w\.]+)/i,/(instagram|snapchat|klarna)[\/ ]([-\w\.]+)/i],[O,T,[C,qe]],[/\bgsa\/([\w\.]+) .*safari\//i],[T,[O,"GSA"],[C,qe]],[/(?:musical_ly|trill)(?:.+app_?version\/|_)([\w\.]+)/i],[T,[O,"TikTok"],[C,qe]],[/\[(linkedin)app\]/i],[O,[C,qe]],[/(zalo(?:app)?)[\/\sa-z]*([\w\.-]+)/i],[[O,/(.+)/,"Zalo"],T,[C,qe]],[/(chromium)[\/ ]([-\w\.]+)/i],[O,T],[/ome-(lighthouse)$/i],[O,[C,Ws]],[/headlesschrome(?:\/([\w\.]+)| )/i],[T,[O,ni+" Headless"]],[/wv\).+chrome\/([\w\.]+).+edgw\//i],[T,[O,Ir+" WebView2"],[C,qe]],[/; wv\).+(chrome)\/([\w\.]+)/i],[[O,ni+" WebView"],T,[C,qe]],[/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i],[T,[O,"Android"+vt]],[/chrome\/([\w\.]+) mobile/i],[T,[O,Ct+"Chrome"]],[/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i],[O,T],[/version\/([\w\.\,]+) .*mobile(?:\/\w+ | ?)safari/i],[T,[O,Ct+"Safari"]],[/iphone .*mobile(?:\/\w+ | ?)safari/i],[[O,Ct+"Safari"]],[/version\/([\w\.\,]+) .*(safari)/i],[T,O],[/webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i],[O,[T,"1"]],[/(webkit|khtml)\/([\w\.]+)/i],[O,T],[/(?:mobile|tablet);.*(firefox)\/([\w\.-]+)/i],[[O,Ct+$t],T],[/(navigator|netscape\d?)\/([-\w\.]+)/i],[[O,"Netscape"],T],[/(wolvic|librewolf)\/([\w\.]+)/i],[O,T],[/mobile vr; rv:([\w\.]+)\).+firefox/i],[T,[O,$t+" Reality"]],[/ekiohf.+(flow)\/([\w\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror)[\/ ]?([\w\.\+]+)/i,/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|basilisk|waterfox)\/([-\w\.]+)$/i,/(firefox)\/([\w\.]+)/i,/(mozilla)\/([\w\.]+(?= .+rv\:.+gecko\/\d+)|[0-4][\w\.]+(?!.+compatible))/i,/(amaya|dillo|doris|icab|ladybird|lynx|mosaic|netsurf|obigo|polaris|w3m|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,/\b(links) \(([\w\.]+)/i],[O,[T,/_/g,"."]],[/(cobalt)\/([\w\.]+)/i],[O,[T,/[^\d\.]+./,Rt]]],cpu:[[/\b((amd|x|x86[-_]?|wow|win)64)\b/i],[[be,"amd64"]],[/(ia32(?=;))/i,/\b((i[346]|x)86)(pc)?\b/i],[[be,"ia32"]],[/\b(aarch64|arm(v?[89]e?l?|_?64))\b/i],[[be,"arm64"]],[/\b(arm(v[67])?ht?n?[fl]p?)\b/i],[[be,"armhf"]],[/( (ce|mobile); ppc;|\/[\w\.]+arm\b)/i],[[be,"arm"]],[/ sun4\w[;\)]/i],[[be,"sparc"]],[/\b(avr32|ia64(?=;)|68k(?=\))|\barm(?=v([1-7]|[5-7]1)l?|;|eabi)|(irix|mips|sparc)(64)?\b|pa-risc)/i,/((ppc|powerpc)(64)?)( mac|;|\))/i,/(?:osf1|[freopnt]{3,4}bsd) (alpha)/i],[[be,/ower/,Rt,st]],[/mc680.0/i],[[be,"68k"]],[/winnt.+\[axp/i],[[be,"alpha"]]],device:[[/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i],[S,[N,Ut],[C,Z]],[/\b((?:s[cgp]h|gt|sm)-(?![lr])\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,/samsung[- ]((?!sm-[lr]|browser)[-\w]+)/i,/sec-(sgh\w+)/i],[S,[N,Ut],[C,H]],[/(?:\/|\()(ip(?:hone|od)[\w, ]*)[\/\);]/i],[S,[N,Et],[C,H]],[/\b(?:ios|apple\w+)\/.+[\(\/](ipad)/i,/\b(ipad)[\d,]*[;\] ].+(mac |i(pad)?)os/i],[S,[N,Et],[C,Z]],[/(macintosh);/i],[S,[N,Et]],[/\b(sh-?[altvz]?\d\d[a-ekm]?)/i],[S,[N,ri],[C,H]],[/\b((?:brt|eln|hey2?|gdi|jdn)-a?[lnw]09|(?:ag[rm]3?|jdn2|kob2)-a?[lw]0[09]hn)(?: bui|\)|;)/i],[S,[N,Jn],[C,Z]],[/honor([-\w ]+)[;\)]/i],[S,[N,Jn],[C,H]],[/\b((?:ag[rs][2356]?k?|bah[234]?|bg[2o]|bt[kv]|cmr|cpn|db[ry]2?|jdn2|got|kob2?k?|mon|pce|scm|sht?|[tw]gr|vrd)-[ad]?[lw][0125][09]b?|605hw|bg2-u03|(?:gem|fdr|m2|ple|t1)-[7a]0[1-4][lu]|t1-a2[13][lw]|mediapad[\w\. ]*(?= bui|\)))\b(?!.+d\/s)/i],[S,[N,Yr],[C,Z]],[/(?:huawei) ?([-\w ]+)[;\)]/i,/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][\dc][adnt]?)\b(?!.+d\/s)/i],[S,[N,Yr],[C,H]],[/oid[^\)]+; (2[\dbc]{4}(182|283|rp\w{2})[cgl]|m2105k81a?c)(?: bui|\))/i,/\b(?:xiao)?((?:red)?mi[-_ ]?pad[\w- ]*)(?: bui|\))/i],[[S,/_/g," "],[N,Jr],[C,Z]],[/\b; (\w+) build\/hm\1/i,/\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,/oid[^\)]+; (redmi[\-_ ]?(?:note|k)?[\w_ ]+|m?[12]\d[01]\d\w{3,6}|poco[\w ]+|(shark )?\w{3}-[ah]0|qin ?[1-3](s\+|ultra| pro)?)( bui|; wv|\))/i,/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note|max|cc)?[_ ]?(?:\d{0,2}\w?)[_ ]?(?:plus|se|lite|pro)?( 5g|lte)?)(?: bui|\))/i,/; ([\w ]+) miui\/v?\d/i],[[S,/_/g," "],[N,Jr],[C,H]],[/droid.+; (cph2[3-6]\d[13579]|((gm|hd)19|(ac|be|in|kb)20|(d[en]|eb|le|mt)21|ne22)[0-2]\d|p[g-l]\w[1m]10)\b/i,/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i],[S,[N,ti],[C,H]],[/; (\w+) bui.+ oppo/i,/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i],[S,[N,Qr],[C,H]],[/\b(opd2(\d{3}a?))(?: bui|\))/i],[S,[N,He,{OnePlus:["203","304","403","404","413","415"],"*":Qr}],[C,Z]],[/(vivo (5r?|6|8l?|go|one|s|x[il]?[2-4]?)[\w\+ ]*)(?: bui|\))/i],[S,[N,"BLU"],[C,H]],[/; vivo (\w+)(?: bui|\))/i,/\b(v[12]\d{3}\w?[at])(?: bui|;)/i],[S,[N,"Vivo"],[C,H]],[/\b(rmx[1-3]\d{3})(?: bui|;|\))/i],[S,[N,"Realme"],[C,H]],[/(ideatab[-\w ]+|602lv|d-42a|a101lv|a2109a|a3500-hv|s[56]000|pb-6505[my]|tb-?x?\d{3,4}(?:f[cu]|xu|[av])|yt\d?-[jx]?\d+[lfmx])( bui|;|\)|\/)/i,/lenovo ?(b[68]0[08]0-?[hf]?|tab(?:[\w- ]+?)|tb[\w-]{6,7})( bui|;|\)|\/)/i],[S,[N,Kr],[C,Z]],[/lenovo[-_ ]?([-\w ]+?)(?: bui|\)|\/)/i],[S,[N,Kr],[C,H]],[/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,/\bmot(?:orola)?[- ]([\w\s]+)(\)| bui)/i,/((?:moto(?! 360)[-\w\(\) ]+|xt\d{3,4}[cgkosw\+]?[-\d]*|nexus 6)(?= bui|\)))/i],[S,[N,qr],[C,H]],[/\b(mz60\d|xoom[2 ]{0,2}) build\//i],[S,[N,qr],[C,Z]],[/\b(?:lg)?([vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i],[S,[N,vr],[C,Z]],[/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,/\blg[-e;\/ ]+(?!.*(?:browser|netcast|android tv|watch|webos))(\w+)/i,/\blg-?([\d\w]+) bui/i],[S,[N,vr],[C,H]],[/(nokia) (t[12][01])/i],[N,S,[C,Z]],[/(?:maemo|nokia).*(n900|lumia \d+|rm-\d+)/i,/nokia[-_ ]?(([-\w\. ]*?))( bui|\)|;|\/)/i],[[S,/_/g," "],[C,H],[N,"Nokia"]],[/(pixel (c|tablet))\b/i],[S,[N,ht],[C,Z]],[/droid.+;(?: google)? (g(01[13]a|020[aem]|025[jn]|1b60|1f8f|2ybb|4s1m|576d|5nz6|8hhn|8vou|a02099|c15s|d1yq|e2ae|ec77|gh2x|kv4x|p4bc|pj41|r83y|tt9q|ur25|wvk6)|pixel[\d ]*a?( pro)?( xl)?( fold)?( \(5g\))?)( bui|\))/i],[S,[N,ht],[C,H]],[/(google) (pixelbook( go)?)/i],[N,S],[/droid.+; (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-\w\w\d\d)(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[S,[N,Ht],[C,H]],[/sony tablet [ps]/i,/\b(?:sony)?sgp\w+(?: bui|\))/i],[[S,"Xperia Tablet"],[N,Ht],[C,Z]],[/(alexa)webm/i,/(kf[a-z]{2}wi|aeo(?!bc)\w\w)( bui|\))/i,/(kf[a-z]+)( bui|\)).+silk\//i],[S,[N,hr],[C,Z]],[/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i],[[S,/(.+)/g,"Fire Phone $1"],[N,hr],[C,H]],[/(playbook);[-\w\),; ]+(rim)/i],[S,N,[C,Z]],[/\b((?:bb[a-f]|st[hv])100-\d)/i,/(?:blackberry|\(bb10;) (\w+)/i],[S,[N,Qn],[C,H]],[/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i],[S,[N,qn],[C,Z]],[/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i],[S,[N,qn],[C,H]],[/(nexus 9)/i],[S,[N,"HTC"],[C,Z]],[/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,/(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i],[N,[S,/_/g," "],[C,H]],[/tcl (xess p17aa)/i,/droid [\w\.]+; ((?:8[14]9[16]|9(?:0(?:48|60|8[01])|1(?:3[27]|66)|2(?:6[69]|9[56])|466))[gqswx])(_\w(\w|\w\w))?(\)| bui)/i],[S,[N,"TCL"],[C,Z]],[/droid [\w\.]+; (418(?:7d|8v)|5087z|5102l|61(?:02[dh]|25[adfh]|27[ai]|56[dh]|59k|65[ah])|a509dl|t(?:43(?:0w|1[adepqu])|50(?:6d|7[adju])|6(?:09dl|10k|12b|71[efho]|76[hjk])|7(?:66[ahju]|67[hw]|7[045][bh]|71[hk]|73o|76[ho]|79w|81[hks]?|82h|90[bhsy]|99b)|810[hs]))(_\w(\w|\w\w))?(\)| bui)/i],[S,[N,"TCL"],[C,H]],[/(itel) ((\w+))/i],[[N,st],S,[C,He,{tablet:["p10001l","w7001"],"*":"mobile"}]],[/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i],[S,[N,"Acer"],[C,Z]],[/droid.+; (m[1-5] note) bui/i,/\bmz-([-\w]{2,})/i],[S,[N,"Meizu"],[C,H]],[/; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i],[S,[N,"Ulefone"],[C,H]],[/; (energy ?\w+)(?: bui|\))/i,/; energizer ([\w ]+)(?: bui|\))/i],[S,[N,"Energizer"],[C,H]],[/; cat (b35);/i,/; (b15q?|s22 flip|s48c|s62 pro)(?: bui|\))/i],[S,[N,"Cat"],[C,H]],[/((?:new )?andromax[\w- ]+)(?: bui|\))/i],[S,[N,"Smartfren"],[C,H]],[/droid.+; (a(in)?(0(15|59|6[35])|142)p?)/i],[S,[N,"Nothing"],[C,H]],[/; (x67 5g|tikeasy \w+|ac[1789]\d\w+)( b|\))/i,/archos ?(5|gamepad2?|([\w ]*[t1789]|hello) ?\d+[\w ]*)( b|\))/i],[S,[N,"Archos"],[C,Z]],[/archos ([\w ]+)( b|\))/i,/; (ac[3-6]\d\w{2,8})( b|\))/i],[S,[N,"Archos"],[C,H]],[/blackview ([-\w ]+)( b|\))/i,/; (bv\d{4}[-\w ]*)( b|\))/i],[S,[N,"Blackview"],[C,H]],[/; (n159v)/i],[S,[N,"HMD"],[C,H]],[/((revvl[ \w\+]+|tm(?:rv|af)\w*[45]g(?:tb)?))( b|\))/i],[S,[C,t1,{test:/ta?b/i,ifTrue:Z,ifFalse:H}],[N,"T-Mobile"]],[/(imo) (tab \w+)/i,/(infinix|tecno) (x1101b?|p904|dp(7c|8d|10a)( pro)?|p70[1-3]a?|p904|t1101)/i],[N,S,[C,Z]],[/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus(?! zenw)|dell|jolla|meizu|motorola|polytron|tecno|micromax|advan)[-_ ]?([-\w]*)/i,/; (blu|coolpad|cubot|hmd|imo|infinix|lava|oneplus|tcl|wiko)[_ ]([-\w\+ ]+?)(?: bui|\)|; r)/i,/(hp) ([\w ]+\w)/i,/(microsoft); (lumia[\w ]+)/i,/(oppo) ?([\w ]+) bui/i,/(hisense) ([ehv][\w ]+)\)/i,/droid[^;]+; (philips)[_ ]([sv-x][\d]{3,4}[xz]?)/i],[N,S,[C,H]],[/(kobo)\s(ereader|touch)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\/([\w\.]+)/i],[N,S,[C,Z]],[/(surface duo)/i],[S,[N,Zr],[C,Z]],[/droid [\d\.]+; (fp\du?)(?: b|\))/i],[S,[N,"Fairphone"],[C,H]],[/((?:tegranote|shield t(?!.+d tv))[\w- ]*?)(?: b|\))/i],[S,[N,ei],[C,Z]],[/(sprint) (\w+)/i],[N,S,[C,H]],[/(kin\.[onetw]{3})/i],[[S,/\./g," "],[N,Zr],[C,H]],[/droid.+; ([c6]+|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i],[S,[N,en],[C,Z]],[/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i],[S,[N,en],[C,H]],[/(philips)[\w ]+tv/i,/smart-tv.+(samsung)/i],[N,[C,fe]],[/hbbtv.+maple;(\d+)/i],[[S,/^/,"SmartTV"],[N,Ut],[C,fe]],[/(vizio)(?: |.+model\/)(\w+-\w+)/i,/tcast.+(lg)e?. ([-\w]+)/i],[N,S,[C,fe]],[/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i],[[N,vr],[C,fe]],[/(apple) ?tv/i],[N,[S,Et+" TV"],[C,fe]],[/crkey.*devicetype\/chromecast/i],[[S,nt+" Third Generation"],[N,ht],[C,fe]],[/crkey.*devicetype\/([^/]*)/i],[[S,/^/,"Chromecast "],[N,ht],[C,fe]],[/fuchsia.*crkey/i],[[S,nt+" Nest Hub"],[N,ht],[C,fe]],[/crkey/i],[[S,nt],[N,ht],[C,fe]],[/(portaltv)/i],[S,[N,tn],[C,fe]],[/droid.+aft(\w+)( bui|\))/i],[S,[N,hr],[C,fe]],[/(shield \w+ tv)/i],[S,[N,ei],[C,fe]],[/\(dtv[\);].+(aquos)/i,/(aquos-tv[\w ]+)\)/i],[S,[N,ri],[C,fe]],[/(bravia[\w ]+)( bui|\))/i],[S,[N,Ht],[C,fe]],[/(mi(tv|box)-?\w+) bui/i],[S,[N,Jr],[C,fe]],[/Hbbtv.*(technisat) (.*);/i],[N,S,[C,fe]],[/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i],[[N,/.+\/(\w+)/,"$1",He,{LG:"lge"}],[S,or],[C,fe]],[/(playstation \w+)/i],[S,[N,Ht],[C,Sr]],[/\b(xbox(?: one)?(?!; xbox))[\); ]/i],[S,[N,Zr],[C,Sr]],[/(ouya)/i,/(nintendo) (\w+)/i,/(retroid) (pocket ([^\)]+))/i,/(valve).+(steam deck)/i,/droid.+; ((shield|rgcube|gr0006))( bui|\))/i],[[N,He,{Nvidia:"Shield",Anbernic:"RGCUBE",Logitech:"GR0006"}],S,[C,Sr]],[/\b(sm-[lr]\d\d[0156][fnuw]?s?|gear live)\b/i],[S,[N,Ut],[C,We]],[/((pebble))app/i,/(asus|google|lg|oppo|xiaomi) ((pixel |zen)?watch[\w ]*)( bui|\))/i],[N,S,[C,We]],[/(ow(?:19|20)?we?[1-3]{1,3})/i],[S,[N,Qr],[C,We]],[/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i],[S,[N,Et],[C,We]],[/(opwwe\d{3})/i],[S,[N,ti],[C,We]],[/(moto 360)/i],[S,[N,qr],[C,We]],[/(smartwatch 3)/i],[S,[N,Ht],[C,We]],[/(g watch r)/i],[S,[N,vr],[C,We]],[/droid.+; (wt63?0{2,3})\)/i],[S,[N,en],[C,We]],[/droid.+; (glass) \d/i],[S,[N,ht],[C,dr]],[/(pico) ([\w ]+) os\d/i],[N,S,[C,dr]],[/(quest( \d| pro)?s?).+vr/i],[S,[N,tn],[C,dr]],[/mobile vr; rv.+firefox/i],[[C,dr]],[/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i],[N,[C,Yt]],[/(aeobc)\b/i],[S,[N,hr],[C,Yt]],[/(homepod).+mac os/i],[S,[N,Et],[C,Yt]],[/windows iot/i],[[C,Yt]],[/droid.+; ([\w- ]+) (4k|android|smart|google)[- ]?tv/i],[S,[C,fe]],[/\b((4k|android|smart|opera)[- ]?tv|tv; rv:|large screen[\w ]+safari)\b/i],[[C,fe]],[/droid .+?; ([^;]+?)(?: bui|; wv\)|\) applew|; hmsc).+?(mobile|vr|\d) safari/i],[S,[C,He,{mobile:"Mobile",xr:"VR","*":Z}]],[/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i],[[C,Z]],[/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i],[[C,H]],[/droid .+?; ([\w\. -]+)( bui|\))/i],[S,[N,"Generic"]]],engine:[[/windows.+ edge\/([\w\.]+)/i],[T,[O,Ir+"HTML"]],[/(arkweb)\/([\w\.]+)/i],[O,T],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[T,[O,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna|servo)\/([\w\.]+)/i,/ekioh(flow)\/([\w\.]+)/i,/(khtml|tasman|links|dillo)[\/ ]\(?([\w\.]+)/i,/(icab)[\/ ]([23]\.[\d\.]+)/i,/\b(libweb)/i],[O,T],[/ladybird\//i],[[O,"LibWeb"]],[/rv\:([\w\.]{1,9})\b.+(gecko)/i],[T,O]],os:[[/(windows nt) (6\.[23]); arm/i],[[O,/N/,"R"],[T,He,oi]],[/(windows (?:phone|mobile|iot))(?: os)?[\/ ]?([\d\.]*( se)?)/i,/(windows)[\/ ](1[01]|2000|3\.1|7|8(\.1)?|9[58]|me|server 20\d\d( r2)?|vista|xp)/i],[O,T],[/windows nt ?([\d\.\)]*)(?!.+xbox)/i,/\bwin(?=3| ?9|n)(?:nt| 9x )?([\d\.;]*)/i],[[T,/(;|\))/g,"",He,oi],[O,yn]],[/(windows ce)\/?([\d\.]*)/i],[O,T],[/[adehimnop]{4,7}\b(?:.*os ([\w]+) like mac|; opera)/i,/(?:ios;fbsv|ios(?=.+ip(?:ad|hone)|.+apple ?tv)|ip(?:ad|hone)(?: |.+i(?:pad)?)os|apple ?tv.+ios)[\/ ]([\w\.]+)/i,/\btvos ?([\w\.]+)/i,/cfnetwork\/.+darwin/i],[[T,/_/g,"."],[O,"iOS"]],[/(mac os x) ?([\w\. ]*)/i,/(macintosh|mac_powerpc\b)(?!.+(haiku|morphos))/i],[[O,"macOS"],[T,/_/g,"."]],[/android ([\d\.]+).*crkey/i],[T,[O,nt+" Android"]],[/fuchsia.*crkey\/([\d\.]+)/i],[T,[O,nt+" Fuchsia"]],[/crkey\/([\d\.]+).*devicetype\/smartspeaker/i],[T,[O,nt+" SmartSpeaker"]],[/linux.*crkey\/([\d\.]+)/i],[T,[O,nt+" Linux"]],[/crkey\/([\d\.]+)/i],[T,[O,nt]],[/droid ([\w\.]+)\b.+(android[- ]x86)/i],[T,O],[/(ubuntu) ([\w\.]+) like android/i],[[O,/(.+)/,"$1 Touch"],T],[/(harmonyos)[\/ ]?([\d\.]*)/i,/(android|bada|blackberry|kaios|maemo|meego|openharmony|qnx|rim tablet os|sailfish|series40|symbian|tizen)\w*[-\/\.; ]?([\d\.]*)/i],[O,T],[/\(bb(10);/i],[T,[O,Qn]],[/(?:symbian ?os|symbos|s60(?=;)|series ?60)[-\/ ]?([\w\.]*)/i],[T,[O,"Symbian"]],[/mozilla\/[\d\.]+ \((?:mobile[;\w ]*|tablet|tv|[^\)]*(?:viera|lg(?:l25|-d300)|alcatel ?o.+|y300-f1)); rv:([\w\.]+)\).+gecko\//i],[T,[O,$t+" OS"]],[/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i,/webos(?:[ \/]?|\.tv-20(?=2[2-9]))(\d[\d\.]*)/i],[T,[O,"webOS"]],[/web0s;.+?(?:chr[o0]me|safari)\/(\d+)/i],[[T,He,{25:"120",24:"108",23:"94",22:"87",6:"79",5:"68",4:"53",3:"38",2:"538",1:"537","*":"TV"}],[O,"webOS"]],[/watch(?: ?os[,\/ ]|\d,\d\/)([\d\.]+)/i],[T,[O,"watchOS"]],[/cros [\w]+(?:\)| ([\w\.]+)\b)/i],[T,[O,"Chrome OS"]],[/kepler ([\w\.]+); (aft|aeo)/i],[T,[O,"Vega OS"]],[/(netrange)mmh/i,/(nettv)\/(\d+\.[\w\.]+)/i,/(nintendo|playstation) (\w+)/i,/(xbox); +xbox ([^\);]+)/i,/(pico) .+os([\w\.]+)/i,/\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,/linux.+(mint)[\/\(\) ]?([\w\.]*)/i,/(mageia|vectorlinux|fuchsia|arcaos|arch(?= ?linux))[;l ]([\d\.]*)/i,/([kxln]?ubuntu|debian|suse|opensuse|gentoo|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire|knoppix)(?: gnu[\/ ]linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,/((?:open)?solaris)[-\/ ]?([\w\.]*)/i,/\b(aix)[; ]([1-9\.]{0,4})/i,/(hurd|linux|morphos)(?: (?:arm|x86|ppc)\w*| ?)([\w\.]*)/i,/(gnu) ?([\w\.]*)/i,/\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,/(haiku) ?(r\d)?/i],[O,T],[/(sunos) ?([\d\.]*)/i],[[O,"Solaris"],T],[/\b(beos|os\/2|amigaos|openvms|hp-ux|serenityos)/i,/(unix) ?([\w\.]*)/i],[O,T]]},pr=(function(){var t={init:{},isIgnore:{},isIgnoreRgx:{},toString:{}};return Je.call(t.init,[[De,[O,T,ir,C]],[et,[be]],[Ye,[C,S,N]],[Ge,[O,T]],[ke,[O,T]]]),Je.call(t.isIgnore,[[De,[T,ir]],[Ge,[T]],[ke,[T]]]),Je.call(t.isIgnoreRgx,[[De,/ ?browser$/i],[ke,/ ?os$/i]]),Je.call(t.toString,[[De,[O,T]],[et,[be]],[Ye,[N,S]],[Ge,[O,T]],[ke,[O,T]]]),t})(),i1=function(t,e){var r=pr.init[e],n=pr.isIgnore[e]||0,i=pr.isIgnoreRgx[e]||0,a=pr.toString[e]||0;function o(){Je.call(this,r)}return o.prototype.getItem=function(){return t},o.prototype.withClientHints=function(){return mt?mt.getHighEntropyValues(Ki).then(function(s){return t.setCH(new Zi(s,!1)).parseCH().get()}):t.parseCH().get()},o.prototype.withFeatureCheck=function(){return t.detectFeature().get()},e!=Pt&&(o.prototype.is=function(s){var c=!1;for(var u in this)if(this.hasOwnProperty(u)&&!mn(n,u)&&st(i?ar(i,this[u]):this[u])==st(i?ar(i,s):s)){if(c=!0,s!=ue.UNDEFINED)break}else if(s==ue.UNDEFINED&&c){c=!c;break}return c},o.prototype.toString=function(){var s=Rt;for(var c in a)typeof this[a[c]]!==ue.UNDEFINED&&(s+=(s?" ":Rt)+this[a[c]]);return s||ue.UNDEFINED}),o.prototype.then=function(s){var c=this,u=function(){for(var d in c)c.hasOwnProperty(d)&&(this[d]=c[d])};u.prototype={is:o.prototype.is,toString:o.prototype.toString,withClientHints:o.prototype.withClientHints,withFeatureCheck:o.prototype.withFeatureCheck};var l=new u;return s(l),l},new o};function Zi(t,e){if(t=t||{},Je.call(this,Ki),e)Je.call(this,[[Mn,rn(t[dt])],[Ln,rn(t[Xs])],[H,/\?1/.test(t[Zs])],[S,St(t[qs])],[kt,St(t[Yi])],[Fn,St(t[Qs])],[be,St(t[js])],[yt,rn(t[Ks])],[Vr,St(t[Ys])]]);else for(var r in t)this.hasOwnProperty(r)&&typeof t[r]!==ue.UNDEFINED&&(this[r]=t[r])}function ft(t,e,r,n){return Je.call(this,[["itemType",t],["ua",e],["uaCH",n],["rgxMap",r],["data",i1(this,t)]]),this}ft.prototype.get=function(t){return t?this.data.hasOwnProperty(t)?this.data[t]:void 0:this.data};ft.prototype.set=function(t,e){return this.data[t]=e,this};ft.prototype.setCH=function(t){return this.uaCH=t,this};ft.prototype.detectFeature=function(){if(Te&&Te.userAgent==this.ua)switch(this.itemType){case De:Te.brave&&typeof Te.brave.isBrave==ue.FUNCTION&&this.set(O,"Brave");break;case Ye:!this.get(C)&&mt&&mt[H]&&this.set(C,H),this.get(S)=="Macintosh"&&Te&&typeof Te.standalone!==ue.UNDEFINED&&Te.maxTouchPoints&&Te.maxTouchPoints>2&&this.set(S,"iPad").set(C,Z);break;case ke:!this.get(O)&&mt&&mt[kt]&&this.set(O,mt[kt]);break;case Pt:var t=this.data,e=function(r){return t[r].getItem().detectFeature().get()};this.set(De,e(De)).set(et,e(et)).set(Ye,e(Ye)).set(Ge,e(Ge)).set(ke,e(ke))}return this};ft.prototype.parseUA=function(){switch(this.itemType!=Pt&&_n.call(this.data,this.ua,this.rgxMap),this.itemType){case De:this.set(ir,wn(this.get(T)));break;case ke:if(this.get(O)=="iOS"&&this.get(T)&&/^1[89][^\d]/.exec(this.get(T))){var t=/\) Version\/((\d+)[\d\.]*)/.exec(this.ua);t&&parseInt(t[2],10)>=26&&this.set(T,t[1])}break}return this};ft.prototype.parseCH=function(){var t=this.uaCH,e=this.rgxMap;switch(this.itemType){case De:case Ge:var r=t[Ln]||t[Mn],n;if(r)for(var i=0;i<r.length;i++){var a=r[i].brand||r[i],o=r[i].version;this.itemType==De&&!/not.a.brand/i.test(a)&&(!n||/Chrom/.test(n)&&a!=ii||n==Ir&&/WebView2/.test(a))&&(a=He(a,r1),n=this.get(O),n&&!/Chrom/.test(n)&&/Chrom/.test(a)||this.set(O,a).set(T,o).set(ir,wn(o)),n=a),this.itemType==Ge&&a==ii&&this.set(T,o)}break;case et:var s=t[be];s&&(s&&t[Vr]=="64"&&(s+="64"),_n.call(this.data,s+";",e));break;case Ye:if(t[H]&&this.set(C,H),t[S]&&(this.set(S,t[S]),!this.get(C)||!this.get(N))){var c={};_n.call(c,"droid 9; "+t[S]+")",e),!this.get(C)&&c.type&&this.set(C,c.type),!this.get(N)&&c.vendor&&this.set(N,c.vendor)}if(t[yt]){var u;if(typeof t[yt]!="string")for(var l=0;!u&&l<t[yt].length;)u=He(t[yt][l++],si);else u=He(t[yt],si);this.set(C,u)}break;case ke:var d=t[kt];if(d){var v=t[Fn];d==yn&&(v=parseInt(wn(v),10)>=13?"11":"10"),this.set(O,d).set(T,v)}this.get(O)==yn&&t[S]=="Xbox"&&this.set(O,"Xbox").set(T,void 0);break;case Pt:var h=this.data,p=function(g){return h[g].getItem().setCH(t).parseCH().get()};this.set(De,p(De)).set(et,p(et)).set(Ye,p(Ye)).set(Ge,p(Ge)).set(ke,p(ke))}return this};function tt(t,e,r){if(typeof t===ue.OBJECT?(Rr(t,!0)?(typeof e===ue.OBJECT&&(r=e),e=t):(r=t,e=void 0),t=void 0):typeof t===ue.STRING&&!Rr(e,!0)&&(r=e,e=void 0),r)if(typeof r.append===ue.FUNCTION){var n={};r.forEach(function(l,d){n[String(d).toLowerCase()]=l}),r=n}else{var i={};for(var a in r)r.hasOwnProperty(a)&&(i[String(a).toLowerCase()]=r[a]);r=i}if(!(this instanceof tt))return new tt(t,e,r).getResult();var o=typeof t===ue.STRING?t:r&&r[Kn]?r[Kn]:Te&&Te.userAgent?Te.userAgent:Rt,s=new Zi(r,!0),c=n1,u=function(l){return l==Pt?function(){return new ft(l,o,c,s).set("ua",o).set(De,this.getBrowser()).set(et,this.getCPU()).set(Ye,this.getDevice()).set(Ge,this.getEngine()).set(ke,this.getOS()).get()}:function(){return new ft(l,o,c[l],s).parseUA().get()}};return Je.call(this,[["getBrowser",u(De)],["getCPU",u(et)],["getDevice",u(Ye)],["getEngine",u(Ge)],["getOS",u(ke)],["getResult",u(Pt)],["getUA",function(){return o}],["setUA",function(l){return Lt(l)&&(o=or(l,ji)),this}],["useExtension",function(l){return l&&(c=e1(c,l)),this}]]).setUA(o).useExtension(e),this}tt.VERSION=zs;tt.BROWSER=Ur([O,T,ir,C]);tt.CPU=Ur([be]);tt.DEVICE=Ur([S,N,C,Sr,H,fe,Z,We,Yt]);tt.ENGINE=tt.OS=Ur([O,T]);const nn=typeof navigator<"u"?navigator.userAgent.toLowerCase().indexOf("firefox")>0:!1;function an(t,e,r,n){t.addEventListener?t.addEventListener(e,r,n):t.attachEvent&&t.attachEvent("on".concat(e),r)}function Gt(t,e,r,n){t.removeEventListener?t.removeEventListener(e,r,n):t.detachEvent&&t.detachEvent("on".concat(e),r)}function qi(t,e){const r=e.slice(0,e.length-1);for(let n=0;n<r.length;n++)r[n]=t[r[n].toLowerCase()];return r}function Qi(t){typeof t!="string"&&(t=""),t=t.replace(/\s/g,"");const e=t.split(",");let r=e.lastIndexOf("");for(;r>=0;)e[r-1]+=",",e.splice(r,1),r=e.lastIndexOf("");return e}function a1(t,e){const r=t.length>=e.length?t:e,n=t.length>=e.length?e:t;let i=!0;for(let a=0;a<r.length;a++)n.indexOf(r[a])===-1&&(i=!1);return i}const sr={backspace:8,"⌫":8,tab:9,clear:12,enter:13,"↩":13,return:13,esc:27,escape:27,space:32,left:37,up:38,right:39,down:40,arrowup:38,arrowdown:40,arrowleft:37,arrowright:39,del:46,delete:46,ins:45,insert:45,home:36,end:35,pageup:33,pagedown:34,capslock:20,num_0:96,num_1:97,num_2:98,num_3:99,num_4:100,num_5:101,num_6:102,num_7:103,num_8:104,num_9:105,num_multiply:106,num_add:107,num_enter:108,num_subtract:109,num_decimal:110,num_divide:111,"⇪":20,",":188,".":190,"/":191,"`":192,"-":nn?173:189,"=":nn?61:187,";":nn?59:186,"'":222,"{":219,"}":221,"[":219,"]":221,"\\":220},ze={"⇧":16,shift:16,"⌥":18,alt:18,option:18,"⌃":17,ctrl:17,control:17,"⌘":91,cmd:91,meta:91,command:91},Kt={16:"shiftKey",18:"altKey",17:"ctrlKey",91:"metaKey",shiftKey:16,ctrlKey:17,altKey:18,metaKey:91},ye={16:!1,18:!1,17:!1,91:!1},se={};for(let t=1;t<20;t++)sr["f".concat(t)]=111+t;let oe=[],tr=null,Ji="all";const Qe=new Map,Ft=t=>sr[t.toLowerCase()]||ze[t.toLowerCase()]||t.toUpperCase().charCodeAt(0),o1=t=>Object.keys(sr).find(e=>sr[e]===t),s1=t=>Object.keys(ze).find(e=>ze[e]===t);function ea(t){Ji=t||"all"}function cr(){return Ji||"all"}function c1(){return oe.slice(0)}function u1(){return oe.map(t=>o1(t)||s1(t)||String.fromCharCode(t))}function f1(){const t=[];return Object.keys(se).forEach(e=>{se[e].forEach(r=>{let{key:n,scope:i,mods:a,shortcut:o}=r;t.push({scope:i,shortcut:o,mods:a,keys:n.split("+").map(s=>Ft(s))})})}),t}function l1(t){const e=t.target||t.srcElement,{tagName:r}=e;let n=!0;const i=r==="INPUT"&&!["checkbox","radio","range","button","file","reset","submit","color"].includes(e.type);return(e.isContentEditable||(i||r==="TEXTAREA"||r==="SELECT")&&!e.readOnly)&&(n=!1),n}function d1(t){return typeof t=="string"&&(t=Ft(t)),oe.indexOf(t)!==-1}function h1(t,e){let r,n;t||(t=cr());for(const i in se)if(Object.prototype.hasOwnProperty.call(se,i))for(r=se[i],n=0;n<r.length;)r[n].scope===t?r.splice(n,1).forEach(o=>{let{element:s}=o;return Vn(s)}):n++;cr()===t&&ea(e||"all")}function v1(t){let e=t.keyCode||t.which||t.charCode;t.key&&t.key.toLowerCase()==="capslock"&&(e=Ft(t.key));const r=oe.indexOf(e);if(r>=0&&oe.splice(r,1),t.key&&t.key.toLowerCase()==="meta"&&oe.splice(0,oe.length),(e===93||e===224)&&(e=91),e in ye){ye[e]=!1;for(const n in ze)ze[n]===e&&(Xe[n]=!1)}}function ta(t){if(typeof t>"u")Object.keys(se).forEach(i=>{Array.isArray(se[i])&&se[i].forEach(a=>gr(a)),delete se[i]}),Vn(null);else if(Array.isArray(t))t.forEach(i=>{i.key&&gr(i)});else if(typeof t=="object")t.key&&gr(t);else if(typeof t=="string"){for(var e=arguments.length,r=new Array(e>1?e-1:0),n=1;n<e;n++)r[n-1]=arguments[n];let[i,a]=r;typeof i=="function"&&(a=i,i=""),gr({key:t,scope:i,method:a,splitKey:"+"})}}const gr=t=>{let{key:e,scope:r,method:n,splitKey:i="+"}=t;Qi(e).forEach(o=>{const s=o.split(i),c=s.length,u=s[c-1],l=u==="*"?"*":Ft(u);if(!se[l])return;r||(r=cr());const d=c>1?qi(ze,s):[],v=[];se[l]=se[l].filter(h=>{const g=(n?h.method===n:!0)&&h.scope===r&&a1(h.mods,d);return g&&v.push(h.element),!g}),v.forEach(h=>Vn(h))})};function ci(t,e,r,n){if(e.element!==n)return;let i;if(e.scope===r||e.scope==="all"){i=e.mods.length>0;for(const a in ye)Object.prototype.hasOwnProperty.call(ye,a)&&(!ye[a]&&e.mods.indexOf(+a)>-1||ye[a]&&e.mods.indexOf(+a)===-1)&&(i=!1);(e.mods.length===0&&!ye[16]&&!ye[18]&&!ye[17]&&!ye[91]||i||e.shortcut==="*")&&(e.keys=[],e.keys=e.keys.concat(oe),e.method(t,e)===!1&&(t.preventDefault?t.preventDefault():t.returnValue=!1,t.stopPropagation&&t.stopPropagation(),t.cancelBubble&&(t.cancelBubble=!0)))}}function ui(t,e){const r=se["*"];let n=t.keyCode||t.which||t.charCode;if(t.key&&t.key.toLowerCase()==="capslock"||!Xe.filter.call(this,t))return;if((n===93||n===224)&&(n=91),oe.indexOf(n)===-1&&n!==229&&oe.push(n),["metaKey","ctrlKey","altKey","shiftKey"].forEach(s=>{const c=Kt[s];t[s]&&oe.indexOf(c)===-1?oe.push(c):!t[s]&&oe.indexOf(c)>-1?oe.splice(oe.indexOf(c),1):s==="metaKey"&&t[s]&&(oe=oe.filter(u=>u in Kt||u===n))}),n in ye){ye[n]=!0;for(const s in ze)if(Object.prototype.hasOwnProperty.call(ze,s)){const c=Kt[ze[s]];Xe[s]=t[c]}if(!r)return}for(const s in ye)Object.prototype.hasOwnProperty.call(ye,s)&&(ye[s]=t[Kt[s]]);t.getModifierState&&!(t.altKey&&!t.ctrlKey)&&t.getModifierState("AltGraph")&&(oe.indexOf(17)===-1&&oe.push(17),oe.indexOf(18)===-1&&oe.push(18),ye[17]=!0,ye[18]=!0);const i=cr();if(r)for(let s=0;s<r.length;s++)r[s].scope===i&&(t.type==="keydown"&&r[s].keydown||t.type==="keyup"&&r[s].keyup)&&ci(t,r[s],i,e);if(!(n in se))return;const a=se[n],o=a.length;for(let s=0;s<o;s++)if((t.type==="keydown"&&a[s].keydown||t.type==="keyup"&&a[s].keyup)&&a[s].key){const c=a[s],{splitKey:u}=c,l=c.key.split(u),d=[];for(let v=0;v<l.length;v++)d.push(Ft(l[v]));d.sort().join("")===oe.sort().join("")&&ci(t,c,i,e)}}function Xe(t,e,r){oe=[];const n=Qi(t);let i=[],a="all",o=document,s=0,c=!1,u=!0,l="+",d=!1,v=!1;for(r===void 0&&typeof e=="function"&&(r=e),Object.prototype.toString.call(e)==="[object Object]"&&(e.scope&&(a=e.scope),e.element&&(o=e.element),e.keyup&&(c=e.keyup),e.keydown!==void 0&&(u=e.keydown),e.capture!==void 0&&(d=e.capture),typeof e.splitKey=="string"&&(l=e.splitKey),e.single===!0&&(v=!0)),typeof e=="string"&&(a=e),v&&ta(t,a);s<n.length;s++)t=n[s].split(l),i=[],t.length>1&&(i=qi(ze,t)),t=t[t.length-1],t=t==="*"?"*":Ft(t),t in se||(se[t]=[]),se[t].push({keyup:c,keydown:u,scope:a,mods:i,shortcut:n[s],method:r,key:n[s],splitKey:l,element:o});if(typeof o<"u"&&window){if(!Qe.has(o)){const h=function(){let g=arguments.length>0&&arguments[0]!==void 0?arguments[0]:window.event;return ui(g,o)},p=function(){let g=arguments.length>0&&arguments[0]!==void 0?arguments[0]:window.event;ui(g,o),v1(g)};Qe.set(o,{keydownListener:h,keyupListenr:p,capture:d}),an(o,"keydown",h,d),an(o,"keyup",p,d)}if(!tr){const h=()=>{oe=[]};tr={listener:h,capture:d},an(window,"focus",h,d)}}}function p1(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"all";Object.keys(se).forEach(r=>{se[r].filter(i=>i.scope===e&&i.shortcut===t).forEach(i=>{i&&i.method&&i.method()})})}function Vn(t){const e=Object.values(se).flat();if(e.findIndex(n=>{let{element:i}=n;return i===t})<0){const{keydownListener:n,keyupListenr:i,capture:a}=Qe.get(t)||{};n&&i&&(Gt(t,"keyup",i,a),Gt(t,"keydown",n,a),Qe.delete(t))}if((e.length<=0||Qe.size<=0)&&(Object.keys(Qe).forEach(i=>{const{keydownListener:a,keyupListenr:o,capture:s}=Qe.get(i)||{};a&&o&&(Gt(i,"keyup",o,s),Gt(i,"keydown",a,s),Qe.delete(i))}),Qe.clear(),Object.keys(se).forEach(i=>delete se[i]),tr)){const{listener:i,capture:a}=tr;Gt(window,"focus",i,a),tr=null}}const on={getPressedKeyString:u1,setScope:ea,getScope:cr,deleteScope:h1,getPressedKeyCodes:c1,getAllKeyCodes:f1,isPressed:d1,filter:l1,trigger:p1,unbind:ta,keyMap:sr,modifier:ze,modifierMap:Kt};for(const t in on)Object.prototype.hasOwnProperty.call(on,t)&&(Xe[t]=on[t]);if(typeof window<"u"){const t=window.hotkeys;Xe.noConflict=e=>(e&&window.hotkeys===Xe&&(window.hotkeys=t),Xe),window.hotkeys=Xe}const g1={class:"dsg-dropdown__trigger",tabindex:"0"},x1={class:"dsg-dropdown__menu"},y1={key:0,class:"dsg-dropdown__menu-header"},m1={key:1,class:"dsg-dropdown__menu-header"},w1={class:"dsg-dropdown__menu-title"},_1={key:2,class:"dsg-dropdown__menu-header dsg-dropdown__menu-header--subsection"},E1={class:"dsg-dropdown__menu-subtitle"},A1=["href","target","tabindex","title","onClick"],C1={key:0,class:"dsg-dropdown__menu-item-content"},b1={key:0,class:"dsg-dropdown__menu-item-icon"},S1={class:"dsg-dropdown__menu-item-label"},I1={class:"dsg-dropdown__menu-item-hotkey"},O1={key:0},T1={key:1,class:"dsg-dropdown__menu-item-content"},N1=f.defineComponent({__name:"DsgDropdown",props:{label:{default:""},type:{default:"button"},icon:{default:"dots-vertical"},iconBefore:{default:()=>{}},buttonTheme:{default:"gray"},menuItems:{default:()=>[]},avatarInfo:{default:null},isOpen:{type:Boolean,default:!1},placement:{default:"bottom-end"},headerType:{default:"none"},headerTitle:{default:""},strategy:{default:"absolute"},skidding:{default:0},distance:{default:0},size:{default:"md"}},setup(t,{expose:e}){const r=f.ref(t.isOpen),n=new tt().getOS().name;t.menuItems.forEach(h=>{});const i=f.useTemplateRef("floatingVueDropdownEl"),a=f.useTemplateRef("dsgDropdownAvatarTriggerEl"),o=f.useTemplateRef("dsgDropdownButtonTriggerEl"),s=h=>{u(),a.value&&setTimeout(()=>{a?.value?.toggleFocus(r.value)},100)},c=h=>{u(),o.value&&setTimeout(()=>{o?.value?.focusButton(r.value)},100)},u=()=>{r.value=!r.value,r.value?i.value?.show():i.value?.hide()},l=(h,p)=>{p.uri||h.preventDefault(),p.action&&(p.action(),i.value?.hide())},d=f.useTemplateRef("dsgDropdown"),v=h=>(h=h.toLowerCase(),h.replace("ctrl","⌃").replace("shift","⇧").replace("alt","⌥").replace("cmd",n==="macOS"?"⌘":"⊞").replace("++","+").replace("+","").toUpperCase());return f.onMounted(()=>{t.menuItems.forEach(h=>{h.hotkey&&Xe(h.hotkey,p=>{h.hotkeyPreventDefault&&h.hotkeyPreventDefault===!0&&p.preventDefault(),h.uri&&window.open(h.uri,h.uriTarget??"_blank"),typeof h.action=="function"&&(h.action(),i.value?.hide())})})}),f.onBeforeUnmount(()=>{Xe.deleteScope("dsgDropdown")}),e({handleTriggerClick:u}),(h,p)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(["dsg-dropdown",`dsg-dropdown--${t.size}`]),ref:"dsgDropdown"},[f.createVNode(f.unref(M.kt),f.mergeProps({triggers:[],placement:t.placement,"handle-resize":!1,strategy:t.strategy,shown:r.value,flip:!1,shift:!1,boundary:d.value,container:d.value,skidding:t.skidding,distance:t.distance,class:"dsg-dropdown__popper",onHide:p[0]||(p[0]=g=>r.value=!1),ref:"floatingVueDropdownEl"},h.$attrs),{popper:f.withCtx(()=>[f.createElementVNode("div",x1,[f.renderSlot(h.$slots,"dsg-dropdown-menu--header",{},()=>[t.headerType==="avatar"?(f.openBlock(),f.createElementBlock("div",y1,[t.avatarInfo?(f.openBlock(),f.createBlock(rr,{key:0,size:"md",profileUri:t.avatarInfo.profileUri,fullName:t.avatarInfo.fullName,isOnline:t.avatarInfo.isOnline,title:t.avatarInfo.title,"sub-text":t.avatarInfo.subText},null,8,["profileUri","fullName","isOnline","title","sub-text"])):f.createCommentVNode("",!0)])):t.headerType==="title"?(f.openBlock(),f.createElementBlock("div",m1,[f.createElementVNode("h3",w1,f.toDisplayString(t.headerTitle),1)])):t.headerType==="subsection"?(f.openBlock(),f.createElementBlock("div",_1,[f.createElementVNode("h4",E1,f.toDisplayString(t.headerTitle),1)])):f.createCommentVNode("",!0)]),f.renderSlot(h.$slots,"dsg-dropdown-menu-content",{},()=>[(f.openBlock(!0),f.createElementBlock(f.Fragment,null,f.renderList(t.menuItems.filter(g=>!g.disabled),(g,y)=>(f.openBlock(),f.createElementBlock("a",{class:f.normalizeClass(["dsg-dropdown__menu-item",{"dsg-dropdown__menu-item--divider":g.type==="divider"}]),href:g.uri,target:g.uriTarget??"_blank",tabindex:!g.uri&&g.type!=="divider"?0:void 0,title:g.label,key:y,onClick:w=>l(w,g)},[g.type==="item"||g.type===void 0?(f.openBlock(),f.createElementBlock("div",C1,[g.icon?(f.openBlock(),f.createElementBlock("div",b1,[f.createVNode(M._sfc_main,{icon:g.icon,size:"xs"},null,8,["icon"])])):f.createCommentVNode("",!0),f.createElementVNode("span",S1,f.toDisplayString(g.label),1),f.createElementVNode("div",I1,[g.hotkey?(f.openBlock(),f.createElementBlock("span",O1,f.toDisplayString(v(g.hotkey)),1)):f.createCommentVNode("",!0)])])):g.type==="divider"?(f.openBlock(),f.createElementBlock("div",T1,[...p[1]||(p[1]=[f.createElementVNode("hr",null,null,-1)])])):f.createCommentVNode("",!0)],10,A1))),128))])])]),default:f.withCtx(()=>[f.createElementVNode("div",g1,[f.renderSlot(h.$slots,"dsg-dropdown--trigger",{},()=>[t.type==="avatar"?(f.openBlock(),f.createElementBlock(f.Fragment,{key:0},[t.avatarInfo?(f.openBlock(),f.createBlock(rr,{key:0,size:"lg",profileUri:t.avatarInfo.profileUri,fullName:t.avatarInfo.fullName,ref:"dsgDropdownAvatarTriggerEl",onClick:s,"prevent-default":!0},null,8,["profileUri","fullName"])):f.createCommentVNode("",!0)],64)):t.type==="button"?(f.openBlock(),f.createBlock(M._sfc_main$3,{key:1,theme:t.buttonTheme,label:t.label,onClick:c,ref:"dsgDropdownButtonTriggerEl","icon-before":t.iconBefore,size:t.size,"icon-after":"chevron-down",class:f.normalizeClass(["dsg-dropdown__trigger-button",{"dsg-dropdown__trigger-button--dropdown-active":r.value}])},null,8,["theme","label","icon-before","size","class"])):t.type==="icon"?(f.openBlock(),f.createBlock(M._sfc_main$3,{key:2,"icon-before":t.icon,size:"sm",theme:t.buttonTheme,class:f.normalizeClass(["dsg-dropdown__trigger-button",{"dsg-dropdown__trigger-button--dropdown-active":r.value}]),onClick:u},null,8,["icon-before","theme","class"])):f.createCommentVNode("",!0)])])]),_:3},16,["placement","strategy","shown","boundary","container","skidding","distance"])],2))}}),D1={key:1,class:"dsg-modal__header-text"},B1={key:0,class:"dsg-modal__header-title"},R1={key:1,class:"dsg-modal__header-description"},P1={key:1,class:"dsg-modal__body"},ra=f.defineComponent({__name:"DsgModal",props:{title:{default:""},description:{default:""},miscIcon:{default:null},hasClosedButton:{type:Boolean,default:!0},initialOpen:{type:Boolean,default:!1},closeClickBackground:{type:Boolean,default:!1},wrapperClasses:{default:""},width:{default:400},type:{default:"left"},footerType:{default:"horizontal-even"},primaryButton:{type:[Object,Boolean],default:!1},secondaryButton:{type:[Object,Boolean],default:!1},hasBackground:{type:Boolean,default:!0}},emits:["before-open","after-open","before-close","after-close","secondary-button-clicked","primary-button-clicked"],setup(t,{expose:e,emit:r}){const n=r,i=f.ref(t.initialOpen),a=()=>{n("before-open"),i.value=!0,n("after-open")},o=()=>{n("before-close"),i.value=!1,n("after-close")},s=()=>{i.value&&t.closeClickBackground&&o()},c=()=>{n("secondary-button-clicked")},u=()=>{n("primary-button-clicked")};return e({open:a,close:o,secondaryButtonClicked:c,primaryButtonClicked:u}),(l,d)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(["dsg-modal",`dsg-modal--${i.value?"open":"closed"}`])},[t.hasBackground?(f.openBlock(),f.createElementBlock("div",{key:0,class:"dsg-modal__background",onDblclick:s},null,32)):f.createCommentVNode("",!0),f.createElementVNode("div",{class:f.normalizeClass(["dsg-modal__wrapper",t.wrapperClasses]),style:f.normalizeStyle({width:`${t.width}px`})},[t.hasClosedButton?(f.openBlock(),f.createBlock(M._sfc_main$3,{key:0,theme:"gray-tertiary",iconBefore:"x",size:"lg",class:f.normalizeClass(["dsg-modal__close-button",`dsg-modal__close-button--${t.type}`]),onClick:o},null,8,["class"])):f.createCommentVNode("",!0),f.renderSlot(l.$slots,"dsg-modal__header",{},()=>[f.createElementVNode("div",{class:f.normalizeClass(["dsg-modal__header",[`dsg-modal__header--${t.type}`,`${l.$slots.default?"dsg-modal__header--with-body":""}`].join(" ")])},[t.miscIcon?(f.openBlock(),f.createBlock(It,f.normalizeProps(f.mergeProps({key:0},t.miscIcon)),null,16)):f.createCommentVNode("",!0),t.title||t.description?(f.openBlock(),f.createElementBlock("div",D1,[t.title?(f.openBlock(),f.createElementBlock("h3",B1,f.toDisplayString(t.title),1)):f.createCommentVNode("",!0),t.description?(f.openBlock(),f.createElementBlock("p",R1,f.toDisplayString(t.description),1)):f.createCommentVNode("",!0)])):f.createCommentVNode("",!0)],2)]),l.$slots.default?(f.openBlock(),f.createElementBlock("div",P1,[f.renderSlot(l.$slots,"default")])):f.createCommentVNode("",!0),f.renderSlot(l.$slots,"dsg-modal__footer",{},()=>[f.createElementVNode("div",{class:f.normalizeClass(["dsg-modal__footer",`dsg-modal__footer--${t.footerType}`])},[t.secondaryButton?(f.openBlock(),f.createBlock(M._sfc_main$3,f.mergeProps({key:0},t.secondaryButton,{onButtonClicked:c,class:"dsg-modal__secondary-button"}),null,16)):f.createCommentVNode("",!0),t.primaryButton?(f.openBlock(),f.createBlock(M._sfc_main$3,f.mergeProps({key:1},t.primaryButton,{onButtonClicked:u,class:"dsg-modal__primary-button"}),null,16)):f.createCommentVNode("",!0)],2)])],6)],2))}}),k1={class:"dsg-tag__before"},M1={class:"dsg-tag__label"},L1={class:"dsg-tag__after"},F1={key:0,class:"dsg-tag__count"},V1=f.defineComponent({__name:"DsgTag",props:{label:{default:""},size:{default:"md"},hasClose:{type:Boolean,default:!1},tagCount:{default:null},avatarUri:{default:""},hasCheckbox:{type:Boolean,default:!1},dotHex:{default:null},destroyOnClose:{type:Boolean,default:!1},value:{default:null}},emits:["before-checked","after-checked","before-hide","after-hide","before-destroy","after-destroy"],setup(t,{expose:e,emit:r}){const n=()=>`tag-${t.size}`;t.hasClose&&t.tagCount!==null&&new M.DsgPropSyntaxWarning("DsgTag: 'hasClose' and 'tagCount' props are mutually exclusive. Please use only one of them."),t.avatarUri&&t.dotHex&&new M.DsgPropSyntaxWarning("DsgTag: 'avatarUri' and 'dotHex' props are mutually exclusive. Please use only one of them.");const i=r,a=f.useTemplateRef("dsgTag"),o=p=>{t.destroyOnClose?(i("before-destroy",a.value),a.value?.remove(),i("after-destroy")):(i("before-hide",a.value),a.value&&(a.value.style.display="none"),i("after-hide",a.value))},s=(p,g)=>{i("before-checked",p,g)},c=p=>{i("after-checked",p)},u=f.ref(t.tagCount),l=p=>{u.value=p},d=f.ref(t.value);return e({setTagCount:l,setValue:p=>{d.value=p},getValue:()=>d.value}),(p,g)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(["dsg-tag",`dsg-tag--${t.size}`,`dsg-tag--${t.hasClose?"has-close":"no-close"}`,`dsg-tag--${t.tagCount?"has-count":"no-count"}`,`dsg-tag--${t.avatarUri?"has-avatar":"no-avatar"}`,`dsg-tag--${t.hasCheckbox?"has-checkbox":"no-checkbox"}`]),ref:"dsgTag"},[f.createElementVNode("div",k1,[t.hasCheckbox?(f.openBlock(),f.createBlock(M._sfc_main$2,{key:0,class:"dsg-tag__checkbox",size:n(),"no-focus":!0,onBeforeChecked:s,onAfterChecked:c},null,8,["size"])):f.createCommentVNode("",!0),t.avatarUri?(f.openBlock(),f.createBlock(rr,{key:1,"profile-uri":t.avatarUri,size:"xxs","no-focus":!0,class:"dsg-tag__avatar"},null,8,["profile-uri"])):f.createCommentVNode("",!0),t.dotHex?(f.openBlock(),f.createElementBlock("span",{key:2,class:"dsg-tag__dot",style:f.normalizeStyle({backgroundColor:t.dotHex})},null,4)):f.createCommentVNode("",!0)]),f.renderSlot(p.$slots,"dsg-tag--label",{},()=>[f.createElementVNode("span",M1,f.toDisplayString(t.label),1)]),f.createElementVNode("div",L1,[u.value&&u.value>0?(f.openBlock(),f.createElementBlock("div",F1,f.toDisplayString(u.value),1)):f.createCommentVNode("",!0),t.hasClose?(f.openBlock(),f.createBlock(M._sfc_main,{key:1,icon:"x-close",class:"dsg-tag__close-icon",onClick:o})):f.createCommentVNode("",!0)])],2))}}),U1={class:"dsg-toggle__element"},H1=["checked","disabled"],$1={key:0,class:"dsg-toggle__label-wrapper"},G1=["innerHTML"],z1=["innerHTML"],W1=f.defineComponent({__name:"DsgToggle",props:{modelValue:{type:Boolean,default:!1},size:{default:"md"},label:{default:""},subText:{default:""},disabled:{type:Boolean,default:!1}},emits:["before-toggle","after-toggle","update:modelValue"],setup(t,{expose:e,emit:r}){const n=f.ref(t.modelValue),i=()=>{t.disabled||(s("before-toggle",n.value,!n.value),n.value=!n.value,s("after-toggle",n.value),s("update:modelValue",n.value))},a=f.useTemplateRef("toggleCheckbox"),o=()=>{a.value&&a.value.focus(),t.disabled||i()},s=r;return e({set:u=>{n.value=u}}),(u,l)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(`
21
+ `)},[t.contentProps.type==="gray"?(f.openBlock(),f.createBlock(It,{key:0,icon:{icon:"info-circle"},type:"outline",theme:"gray",size:"lg"})):f.createCommentVNode("",!0),t.contentProps.type==="error"?(f.openBlock(),f.createBlock(It,{key:1,icon:{icon:"alert-circle"},type:"outline",theme:"error",size:"lg"})):f.createCommentVNode("",!0),t.contentProps.type==="warning"?(f.openBlock(),f.createBlock(It,{key:2,icon:{icon:"alert-circle"},type:"outline",theme:"warning",size:"lg"})):f.createCommentVNode("",!0),t.contentProps.type==="success"?(f.openBlock(),f.createBlock(It,{key:3,icon:{icon:"check-circle"},type:"outline",theme:"success",size:"lg"})):f.createCommentVNode("",!0),f.createElementVNode("div",rs,[f.createElementVNode("p",{class:f.normalizeClass(["dsg-alert__title",{"dsg-alert__title--with-close-button":t.contentProps.hasCloseButton}])},f.toDisplayString(t.contentProps.title),3),t.contentProps.message?(f.openBlock(),f.createElementBlock("p",{key:0,innerHTML:t.contentProps.message,class:"dsg-alert__message"},null,8,ns)):f.createCommentVNode("",!0)]),t.contentProps.hasCloseButton?(f.openBlock(),f.createElementBlock("button",{key:4,onClick:a,class:"dsg-alert__close-button"},[f.createVNode(M._sfc_main,{icon:"x-close",size:"sm"})])):f.createCommentVNode("",!0)],2))}}),is=new class jt{info(e="",r="",n={}){jt.showToast("gray",e,r,n)}error(e="",r="",n={}){jt.showToast("error",e,r,n)}warning(e="",r="",n={}){jt.showToast("warning",e,r,n)}success(e="",r="",n={}){jt.showToast("success",e,r,n)}static showToast(e,r,n,i){const a={hasCloseButton:!1,timeout:3e3,position:"top-right",maxWidthClass:"",...i};ee(Wi,{autoClose:a.hasCloseButton?!1:a.timeout,closeButton:!1,hideProgressBar:!0,closeOnClick:!a.hasCloseButton,position:a.position,containerClassName:`dsg-alert-container ${a.maxWidthClass}`,toastClassName:"dsg-alert",bodyClassName:"dsg-alert--body",contentProps:{title:r,message:n,type:e,hasCloseButton:a.hasCloseButton,useToast:!0,timeout:a.timeout},onClick:()=>{}})}},as={class:"dsg-icon-select"},os={class:"dsg-icon-select__user-option"},ss=["data-initials"],cs=["src"],us={class:"dsg-icon-select__meta"},fs={class:"dsg-icon-select__name"},ls={key:0,class:"dsg-icon-select__email"},ds={class:"dsg-icon-select__tags"},hs=["data-initials"],vs=["src"],ps={key:0,class:"dsg-icon-select__placeholder-wrapper"},gs={class:"dsg-icon-select__placeholder"},xs={key:0,class:"dsg-icon-select__single-display"},ys=["data-initials"],ms=["src"],ws={key:0,class:"dsg-icon-select__name"},_s={class:"dsg-icon-select__placeholder"},Es=f.defineComponent({__name:"DsgIconSelect",props:{modelValue:{},options:{},endpoint:{},queryParam:{default:"q"},extraParams:{},method:{default:"GET"},minChars:{default:1},delay:{default:300},multiple:{type:Boolean,default:!1},trackBy:{default:"id"},labelKey:{default:"primaryText"},secondaryTextKey:{default:"secondaryText"},iconKey:{default:"iconUrl"},placeholder:{default:"Search..."},clearOnSelect:{type:Boolean,default:!1},disabled:{type:Boolean,default:!1},selectLabel:{default:""},selectedLabel:{default:""},hideSelectedLabel:{type:Boolean,default:!1}},emits:["update:modelValue","change","search","loaded","error"],setup(t,{emit:e}){const r=t,n=e,i=f.ref(r.options??[]),a=f.ref(!1),o=f.ref("");let s,c=null;f.watch(()=>r.options,g=>{g&&(i.value=[...g])});const u=(g,y)=>{if(g)return g[y]},l=g=>{if(!g)return"";const y=g.trim().split(/\s+/),w=y[0]?.[0]??"",m=y.length>1?y[y.length-1][0]??"":"";return(w+m).toUpperCase()};f.computed(()=>r.multiple?r.modelValue??[]:r.modelValue?[r.modelValue]:[]);const d=f.computed(()=>!!r.endpoint),v=async g=>{if(d.value&&!((g?.length??0)<r.minChars)){a.value=!0,c?.abort(),c=new AbortController;try{const y=new URL(r.endpoint);if(r.method==="GET"){y.searchParams.set(r.queryParam,g),r.extraParams&&Object.entries(r.extraParams).forEach(([_,A])=>y.searchParams.set(_,String(A)));const w=await fetch(y.toString(),{signal:c.signal});if(!w.ok)throw new Error(`Request failed: ${w.status}`);const m=await w.json();i.value=Array.isArray(m)?m:m?.items??[],n("loaded",i.value)}else{const w={[r.queryParam]:g,...r.extraParams??{}},m=await fetch(y.toString(),{method:"POST",headers:{"Content-Type":"application/json"},body:JSON.stringify(w),signal:c.signal});if(!m.ok)throw new Error(`Request failed: ${m.status}`);const _=await m.json();i.value=Array.isArray(_)?_:_?.items??[],n("loaded",i.value)}}catch(y){y?.name!=="AbortError"&&(console.error(y),n("error",y))}finally{a.value=!1}}},h=g=>{o.value=g,n("search",g),d.value&&(window.clearTimeout(s),s=window.setTimeout(()=>v(g),r.delay))},p=g=>{n("update:modelValue",g),n("change",g)};return(g,y)=>(f.openBlock(),f.createElementBlock("div",as,[f.createVNode(f.unref(M.script),{"model-value":t.modelValue,"onUpdate:modelValue":p,options:i.value,multiple:t.multiple,"track-by":t.trackBy,searchable:!0,"internal-search":!d.value,loading:a.value,"clear-on-select":!1,"close-on-select":!t.multiple,deselectLabel:"",placeholder:t.placeholder,disabled:t.disabled,label:"name","allow-empty":!0,onSearchChange:h,"select-label":t.selectLabel,"selected-label":t.selectedLabel,class:"dsg-icon-select__multiselect"},{option:f.withCtx(({option:w})=>[f.createElementVNode("div",os,[f.createElementVNode("div",{class:"dsg-icon-select__avatar","data-initials":l(u(w,t.labelKey))},[u(w,t.iconKey)?(f.openBlock(),f.createElementBlock("img",{key:0,src:u(w,t.iconKey),alt:""},null,8,cs)):f.createCommentVNode("",!0)],8,ss),f.createElementVNode("div",us,[f.createElementVNode("div",fs,f.toDisplayString(u(w,t.labelKey)),1),w.secondaryText?(f.openBlock(),f.createElementBlock("div",ls,f.toDisplayString(w.secondaryText),1)):f.createCommentVNode("",!0)])])]),selection:f.withCtx(({values:w,isOpen:m})=>[f.createElementVNode("div",ds,[(f.openBlock(!0),f.createElementBlock(f.Fragment,null,f.renderList(w,_=>(f.openBlock(),f.createElementBlock("div",{class:"dsg-icon-select__avatar","data-initials":l(u(_,t.labelKey))},[u(_,t.iconKey)?(f.openBlock(),f.createElementBlock("img",{key:0,src:u(_,t.iconKey),alt:""},null,8,vs)):f.createCommentVNode("",!0)],8,hs))),256)),t.multiple&&w.length>0?(f.openBlock(),f.createElementBlock("div",ps,[f.createElementVNode("div",gs,[f.createVNode(M._sfc_main,{icon:"plus",size:"xs"})])])):f.createCommentVNode("",!0)])]),singleLabel:f.withCtx(({option:w})=>[w?(f.openBlock(),f.createElementBlock("div",xs,[f.createElementVNode("div",{class:"dsg-icon-select__avatar","data-initials":l(u(w,t.labelKey))},[u(w,t.iconKey)?(f.openBlock(),f.createElementBlock("img",{key:0,src:u(w,t.iconKey),alt:""},null,8,ms)):f.createCommentVNode("",!0)],8,ys),t.hideSelectedLabel?f.createCommentVNode("",!0):(f.openBlock(),f.createElementBlock("span",ws,f.toDisplayString(u(w,t.labelKey)),1))])):f.createCommentVNode("",!0)]),placeholder:f.withCtx(()=>[f.createElementVNode("div",_s,[f.createVNode(M._sfc_main,{icon:"plus",size:"xs"})])]),noResult:f.withCtx(()=>[...y[0]||(y[0]=[f.createElementVNode("div",{class:"dsg-icon-select__empty"},"No results found.",-1)])]),_:1},8,["model-value","options","multiple","track-by","internal-search","loading","close-on-select","placeholder","disabled","select-label","selected-label"])]))}}),As={class:"dsg-badge__before"},Cs={key:2,class:"dsg-badge__dot"},bs={key:1,class:"dsg-badge__label"},Ss={class:"dsg-badge__after"},Is={key:1,class:"dsg-badge__close-wrapper"},Xi=f.defineComponent({__name:"DsgBadge",props:{label:{default:""},type:{default:"standard"},size:{default:"md"},hasClose:{type:Boolean,default:!1},avatarUri:{default:""},iconBefore:{default:""},icon:{default:""},iconAfter:{default:""},iconOnly:{type:Boolean,default:!1},hasDot:{type:Boolean,default:!1},theme:{default:"badge-modern"},themeColor:{default:"gray"},destroyOnClose:{type:Boolean,default:!1}},emits:["before-hide","after-hide","before-destroy","after-destroy","on-click"],setup(t,{expose:e,emit:r}){const n=t.iconBefore||t.iconAfter||t.type==="add"||t.type==="icon-only";(t.type==="add"||t.type==="icon-only")&&(t.label||t.avatarUri||t.hasDot||t.iconBefore||t.iconAfter||t.hasClose)&&t.theme!=="badge-modern"&&t.themeColor&&new M.DsgPropSyntaxWarning("DsgBadge: 'add'/'icon-only' type badges should only be called with 'size', 'theme' and 'themeColor' props. Note that 'themeColor' prop is discarded for theme 'badge-modern'."),[t.avatarUri,t.iconBefore,t.hasDot].filter(Boolean).length>1&&new M.DsgPropSyntaxWarning("DsgBadge: 'avatarUri', 'iconBefore' and 'hasDot' props are mutually exclusive. Please use only one of them."),[t.iconAfter,t.hasClose].filter(Boolean).length>1&&new M.DsgPropSyntaxWarning("DsgBadge: 'iconAfter' and 'hasClose' props are mutually exclusive. Please use only one of them.");const o=r,s=f.useTemplateRef("dsgBadge"),c=l=>{t.destroyOnClose?(o("before-destroy",s.value),s.value?.remove(),o("after-destroy")):(o("before-hide",s.value),s.value&&(s.value.style.display="none"),o("after-hide",s.value))},u=l=>{o("on-click",s.value)};return e({hideOrDestroy:c,clickEvent:u}),(l,d)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(["dsg-badge",`dsg-badge--${t.size}`,`dsg-badge--${t.type}`,`dsg-badge--${t.theme}`,`dsg-badge--${t.themeColor}`,`dsg-badge--${t.iconOnly?"icon-only":"label"}`,t.hasClose?"dsg-badge--has-close":"",t.avatarUri?"dsg-badge--has-avatar":"",t.hasDot?"dsg-badge--has-dot":"",f.unref(n)?"dsg-badge--has-icon":"",t.iconBefore?"dsg-badge--has-icon-before":"",t.iconAfter?"dsg-badge--has-icon-after":""]),ref:"dsgBadge",onClick:u},[t.type==="standard"&&(t.avatarUri||t.iconBefore||t.hasDot)?f.renderSlot(l.$slots,"dsg-badge--before",{},()=>[f.createElementVNode("div",As,[t.avatarUri?(f.openBlock(),f.createBlock(rr,{key:0,"profile-uri":t.avatarUri,class:"dsg-badge__avatar",size:"xxs","no-focus":""},null,8,["profile-uri"])):f.createCommentVNode("",!0),t.iconBefore?(f.openBlock(),f.createBlock(M._sfc_main,{key:1,icon:t.iconBefore,size:"xxs",class:"dsg-badge__icon dsg-badge__icon--before"},null,8,["icon"])):f.createCommentVNode("",!0),t.hasDot?(f.openBlock(),f.createElementBlock("span",Cs)):f.createCommentVNode("",!0)])],void 0,0):f.createCommentVNode("",!0),t.type==="standard"?(f.openBlock(),f.createElementBlock("label",bs,f.toDisplayString(t.label),1)):f.createCommentVNode("",!0),t.type==="add"?(f.openBlock(),f.createBlock(M._sfc_main,{key:2,icon:"plus",size:"xxs",class:"dsg-badge__icon dsg-badge__icon--add"})):f.createCommentVNode("",!0),t.type==="icon-only"?(f.openBlock(),f.createBlock(M._sfc_main,{key:3,icon:t.icon,size:"xxs",class:"dsg-badge__icon dsg-badge__icon--only"},null,8,["icon"])):f.createCommentVNode("",!0),t.type==="standard"&&(t.iconAfter||t.hasClose)?f.renderSlot(l.$slots,"dsg-badge--after",{},()=>[f.createElementVNode("div",Ss,[t.iconAfter?(f.openBlock(),f.createBlock(M._sfc_main,{key:0,icon:t.iconAfter,size:"xxs",class:"dsg-badge__icon dsg-badge__icon--after"},null,8,["icon"])):f.createCommentVNode("",!0),t.hasClose?(f.openBlock(),f.createElementBlock("span",Is,[t.hasClose?(f.openBlock(),f.createBlock(M._sfc_main,{key:0,icon:"x-close",class:"dsg-badge__close",size:"xxs",onClick:c})):f.createCommentVNode("",!0)])):f.createCommentVNode("",!0)])],void 0,4):f.createCommentVNode("",!0)],2))}}),Os={class:"dsg-input-number__control"},Ts=["disabled"],Ns=["value","disabled"],Ds=["disabled"],Bs={key:0,class:"dsg-input-number__label"},Rs=f.defineComponent({__name:"DsgInputNumber",props:{modelValue:{},disabled:{type:Boolean},label:{},step:{}},emits:["update:modelValue"],setup(t,{emit:e}){const r=t,n=e,i=()=>{r.disabled||n("update:modelValue",r.modelValue+(r.step??1))},a=()=>{r.disabled||n("update:modelValue",r.modelValue-(r.step??1))},o=s=>{if(r.disabled)return;const c=s.target;n("update:modelValue",Number(c.value))};return(s,c)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(["dsg-input-number",{"dsg-input-number--disabled":r.disabled}])},[f.createElementVNode("div",Os,[f.createElementVNode("button",{type:"button",onClick:a,disabled:r.disabled,class:"dsg-input-number__btn dsg-input-number__btn--decrement"},[r.disabled?f.createCommentVNode("",!0):(f.openBlock(),f.createBlock(M._sfc_main,{key:0,icon:"minus",size:"sm"}))],8,Ts),f.createElementVNode("input",{type:"number",value:t.modelValue,onInput:o,disabled:r.disabled,class:"dsg-input-number__input"},null,40,Ns),f.createElementVNode("button",{type:"button",disabled:r.disabled,onClick:i,class:"dsg-input-number__btn dsg-input-number__btn--increment"},[r.disabled?f.createCommentVNode("",!0):(f.openBlock(),f.createBlock(M._sfc_main,{key:0,icon:"plus",size:"sm"}))],8,Ds)]),t.label!==void 0||s.$slots.label?(f.openBlock(),f.createElementBlock("div",Bs,[f.renderSlot(s.$slots,"label",{},()=>[f.createTextVNode(f.toDisplayString(t.label),1)])])):f.createCommentVNode("",!0)],2))}}),Ps={key:0,class:"dsg-checkbox-group__form-wrapper"},ks={key:0,class:"dsg-checkbox-group__header"},Ms={class:"dsg-checkbox-group__header-title-wrapper"},Ls={class:"dsg-checkbox-group__title"},Fs=["innerHTML"],Vs={class:"dsg-checkbox-group__options"},Us=["onClick"],Hs=["textContent"],$s=["innerHTML","data"],Gs=f.defineComponent({__name:"DsgCheckboxGroup",props:f.mergeModels({size:{default:"md"},theme:{default:"form"},title:{default:""},subtext:{default:""},options:{default:()=>[]},tooltip:{default:null},defaultValue:{type:[String,Number,Boolean,Array,null],default:()=>[]}},{modelValue:{type:[String,Number,Boolean,Array,null],default:[]},modelModifiers:{}}),emits:["update:modelValue"],setup(t){const e=f.useModel(t,"modelValue"),r=(n,i)=>{n.target instanceof HTMLAnchorElement||(e.value=i.value)};return(n,i)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(`dsg-checkbox-group dsg-checkbox-group--${t.size} dsg-checkbox-group--${t.theme}`)},[["form","form-radio"].includes(t.theme)?(f.openBlock(),f.createElementBlock("div",Ps,[t.title||t.subtext?(f.openBlock(),f.createElementBlock("div",ks,[f.renderSlot(n.$slots,"dsg-checkbox-group--header",{},()=>[f.createElementVNode("div",Ms,[f.createElementVNode("h3",Ls,f.toDisplayString(t.title),1),t.tooltip?(f.openBlock(),f.createBlock(M._sfc_main$1,{key:0,label:t.tooltip,position:"top",triggers:["hover"],"auto-hide":!0,theme:"dark",class:"dsg-checkbox-group__tooltip"},null,8,["label"])):f.createCommentVNode("",!0)]),t.subtext?(f.openBlock(),f.createElementBlock("p",{key:0,class:"dsg-checkbox-group__subtext",innerHTML:t.subtext},null,8,Fs)):f.createCommentVNode("",!0)])])):f.createCommentVNode("",!0),f.createElementVNode("div",Vs,[(f.openBlock(!0),f.createElementBlock(f.Fragment,null,f.renderList(t.options,(a,o)=>(f.openBlock(),f.createElementBlock("div",{key:o,class:"dsg-checkbox-group__option"},[f.createVNode(M._sfc_main$2,{label:a.label,value:a.value,disabled:a.disabled,size:"sm",type:["form","panel"].includes(t.theme)?"checkbox":"radio",modelValue:e.value,"onUpdate:modelValue":i[0]||(i[0]=s=>e.value=s)},null,8,["label","value","disabled","type","modelValue"])]))),128))])])):f.createCommentVNode("",!0),["panel","panel-content"].includes(t.theme)?(f.openBlock(!0),f.createElementBlock(f.Fragment,{key:1},f.renderList(t.options,(a,o)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(["dsg-checkbox-group__panel",`dsg-checkbox-group__panel--${e.value===a.value?"selected":"unselected"}`]),onClick:s=>r(s,a)},[(f.openBlock(),f.createElementBlock("div",{class:"dsg-checkbox-group__panel-left",key:o},[f.renderSlot(n.$slots,`dsg-checkbox-group__panel-title--${String(a.value).trim().toLowerCase().replace(/[^0-9a-zA-Z]/g,"-").replace(/-+/g,"-")}`,{data:a},()=>[a.icon?(f.openBlock(),f.createBlock(M._sfc_main,{key:0,icon:a.icon,size:"xl"},null,8,["icon"])):f.createCommentVNode("",!0),f.createElementVNode("h3",{class:"dsg-checkbox-group__panel-title",textContent:f.toDisplayString(a.label)},null,8,Hs)]),f.renderSlot(n.$slots,`dsg-checkbox-group__panel-subtext--${String(a.value).trim().toLowerCase().replace(/[^0-9a-zA-Z]/g,"-").replace(/-+/g,"-")}`,{},()=>[a.subtext?(f.openBlock(),f.createElementBlock("p",{key:0,class:"dsg-checkbox-group__panel-subtext",innerHTML:a.subtext,data:a},null,8,$s)):f.createCommentVNode("",!0)])])),(f.openBlock(),f.createElementBlock("div",{key:o,class:"dsg-checkbox-group__panel-right"},[f.createVNode(M._sfc_main$2,{value:a.value,disabled:a.disabled,type:"radio",modelValue:e.value,"onUpdate:modelValue":i[1]||(i[1]=s=>e.value=s)},null,8,["value","disabled","modelValue"])]))],10,Us))),256)):f.createCommentVNode("",!0)],2))}});var zs="2.0.10",ji=500,Kn="user-agent",Rt="",Zn="?",ue={FUNCTION:"function",OBJECT:"object",STRING:"string",UNDEFINED:"undefined"},De="browser",et="cpu",Ye="device",Ge="engine",ke="os",Pt="result",O="name",C="type",N="vendor",T="version",be="architecture",ir="major",S="model",Sr="console",H="mobile",Z="tablet",fe="smarttv",We="wearable",dr="xr",Yt="embedded",Ws="fetcher",qe="inapp",Mn="brands",yt="formFactors",Ln="fullVersionList",kt="platform",Fn="platformVersion",Vr="bitness",dt="sec-ch-ua",Xs=dt+"-full-version-list",js=dt+"-arch",Ys=dt+"-"+Vr,Ks=dt+"-form-factors",Zs=dt+"-"+H,qs=dt+"-"+S,Yi=dt+"-"+kt,Qs=Yi+"-version",Ki=[Mn,Ln,H,S,kt,Fn,be,yt,Vr],hr="Amazon",Et="Apple",qn="ASUS",Qn="BlackBerry",ht="Google",Yr="Huawei",Kr="Lenovo",Jn="Honor",vr="LG",Zr="Microsoft",qr="Motorola",ei="Nvidia",ti="OnePlus",Qr="OPPO",Ut="Samsung",ri="Sharp",Ht="Sony",Jr="Xiaomi",en="Zebra",ni="Chrome",ii="Chromium",nt="Chromecast",Ir="Edge",$t="Firefox",At="Opera",tn="Facebook",ai="Sogou",Ct="Mobile ",vt=" Browser",yn="Windows",Js=typeof window!==ue.UNDEFINED,Te=Js&&window.navigator?window.navigator:void 0,mt=Te&&Te.userAgentData?Te.userAgentData:void 0,e1=function(t,e){var r={},n=e;if(!Rr(e)){n={};for(var i in e)for(var a in e[i])n[a]=e[i][a].concat(n[a]?n[a]:[])}for(var o in t)r[o]=n[o]&&n[o].length%2===0?n[o].concat(t[o]):t[o];return r},Ur=function(t){for(var e={},r=0;r<t.length;r++)e[t[r].toUpperCase()]=t[r];return e},mn=function(t,e){if(typeof t===ue.OBJECT&&t.length>0){for(var r in t)if(st(e)==st(t[r]))return!0;return!1}return Lt(t)?st(e)==st(t):!1},Rr=function(t,e){for(var r in t)return/^(browser|cpu|device|engine|os)$/.test(r)||(e?Rr(t[r]):!1)},Lt=function(t){return typeof t===ue.STRING},rn=function(t){if(t){for(var e=[],r=St(t).split(","),n=0;n<r.length;n++)if(r[n].indexOf(";")>-1){var i=or(r[n]).split(";v=");e[n]={brand:i[0],version:i[1]}}else e[n]=or(r[n]);return e}},st=function(t){return Lt(t)?t.toLowerCase():t},wn=function(t){return Lt(t)?ar(/[^\d\.]/g,t).split(".")[0]:void 0},St=function(t){return Lt(t)?or(ar(/\\?\"/g,t),ji):void 0},Je=function(t){for(var e in t)if(t.hasOwnProperty(e)){var r=t[e];typeof r==ue.OBJECT&&r.length==2?this[r[0]]=r[1]:this[r]=void 0}return this},ar=function(t,e){return Lt(e)?e.replace(t,Rt):e},or=function(t,e){return t=ar(/^\s\s*/,String(t)),typeof e===ue.UNDEFINED?t:t.substring(0,e)},_n=function(t,e){if(!(!t||!e))for(var r=0,n,i,a,o,s,c;r<e.length&&!s;){var u=e[r],l=e[r+1];for(n=i=0;n<u.length&&!s&&u[n];)if(s=u[n++].exec(t),s)for(a=0;a<l.length;a++)c=s[++i],o=l[a],typeof o===ue.OBJECT&&o.length>0?o.length===2?typeof o[1]==ue.FUNCTION?this[o[0]]=o[1].call(this,c):this[o[0]]=o[1]:o.length>=3&&(typeof o[1]===ue.FUNCTION&&!(o[1].exec&&o[1].test)?o.length>3?this[o[0]]=c?o[1].apply(this,o.slice(2)):void 0:this[o[0]]=c?o[1].call(this,c,o[2]):void 0:o.length==3?this[o[0]]=c?c.replace(o[1],o[2]):void 0:o.length==4?this[o[0]]=c?o[3].call(this,c.replace(o[1],o[2])):void 0:o.length>4&&(this[o[0]]=c?o[3].apply(this,[c.replace(o[1],o[2])].concat(o.slice(4))):void 0)):this[o]=c||void 0;r+=2}},t1=function(t,e){return e.test.test(t)?e.ifTrue:e.ifFalse},He=function(t,e){for(var r in e)if(typeof e[r]===ue.OBJECT&&e[r].length>0){for(var n=0;n<e[r].length;n++)if(mn(e[r][n],t))return r===Zn?void 0:r}else if(mn(e[r],t))return r===Zn?void 0:r;return e.hasOwnProperty("*")?e["*"]:t},oi={ME:"4.90","NT 3.51":"3.51","NT 4.0":"4.0",2e3:["5.0","5.01"],XP:["5.1","5.2"],Vista:"6.0",7:"6.1",8:"6.2","8.1":"6.3",10:["6.4","10.0"],NT:""},si={embedded:"Automotive",mobile:"Mobile",tablet:["Tablet","EInk"],smarttv:"TV",wearable:"Watch",xr:["VR","XR"],"?":["Desktop","Unknown"],"*":void 0},r1={Chrome:"Google Chrome",Edge:"Microsoft Edge","Edge WebView2":"Microsoft Edge WebView2","Chrome WebView":"Android WebView","Chrome Headless":"HeadlessChrome","Huawei Browser":"HuaweiBrowser","MIUI Browser":"Miui Browser","Opera Mobi":"OperaMobile",Yandex:"YaBrowser"},n1={browser:[[/\b(?:crmo|crios)\/([\w\.]+)/i],[T,[O,Ct+"Chrome"]],[/webview.+edge\/([\w\.]+)/i],[T,[O,Ir+" WebView"],[C,qe]],[/edg(?:e|ios|a)?\/([\w\.]+)/i],[T,[O,"Edge"]],[/(opera mini)\/([-\w\.]+)/i,/(opera [mobiletab]{3,6})\b.+version\/([-\w\.]+)/i,/(opera)(?:.+version\/|[\/ ]+)([\w\.]+)/i],[O,T],[/opios[\/ ]+([\w\.]+)/i],[T,[O,At+" Mini"]],[/\bop(?:rg)?x\/([\w\.]+)/i],[T,[O,At+" GX"]],[/\bopr\/([\w\.]+)/i],[T,[O,At]],[/\bb[ai]*d(?:uhd|[ub]*[aekoprswx]{5,6})[\/ ]?([\w\.]+)/i],[T,[O,"Baidu"]],[/\b(?:mxbrowser|mxios|myie2)\/?([-\w\.]*)\b/i],[T,[O,"Maxthon"]],[/(kindle)\/([\w\.]+)/i,/(lunascape|maxthon|netfront|jasmine|blazer|sleipnir)[\/ ]?([\w\.]*)/i,/(avant|iemobile|slim(?:browser|boat|jet))[\/ ]?([\d\.]*)/i,/(?:ms|\()(ie) ([\w\.]+)/i,/(atlas|flock|rockmelt|midori|epiphany|silk|skyfire|bolt|iron|vivaldi|iridium|phantomjs|bowser|qupzilla|falkon|rekonq|puffin|whale(?!.+naver)|qqbrowserlite|duckduckgo|klar|helio|(?=comodo_)?dragon|otter|dooble|(?:hi|lg |ovi|qute)browser|palemoon)\/v?([-\w\.]+)/i,/(brave)(?: chrome)?\/([\d\.]+)/i,/(aloha|heytap|ovi|115|surf|qwant)browser\/([\d\.]+)/i,/(qwant)(?:ios|mobile)\/([\d\.]+)/i,/(ecosia|weibo)(?:__| \w+@)([\d\.]+)/i],[O,T],[/quark(?:pc)?\/([-\w\.]+)/i],[T,[O,"Quark"]],[/\bddg\/([\w\.]+)/i],[T,[O,"DuckDuckGo"]],[/(?:\buc? ?browser|(?:juc.+)ucweb| ucpc)[\/ ]?([\w\.]+)/i],[T,[O,"UCBrowser"]],[/microm.+\bqbcore\/([\w\.]+)/i,/\bqbcore\/([\w\.]+).+microm/i,/micromessenger\/([\w\.]+)/i],[T,[O,"WeChat"]],[/konqueror\/([\w\.]+)/i],[T,[O,"Konqueror"]],[/trident.+rv[: ]([\w\.]{1,9})\b.+like gecko/i],[T,[O,"IE"]],[/ya(?:search)?browser\/([\w\.]+)/i],[T,[O,"Yandex"]],[/slbrowser\/([\w\.]+)/i],[T,[O,"Smart "+Kr+vt]],[/(av(?:ast|g|ira))\/([\w\.]+)/i],[[O,/(.+)/,"$1 Secure"+vt],T],[/norton\/([\w\.]+)/i],[T,[O,"Norton Private"+vt]],[/\bfocus\/([\w\.]+)/i],[T,[O,$t+" Focus"]],[/ mms\/([\w\.]+)$/i],[T,[O,At+" Neon"]],[/ opt\/([\w\.]+)$/i],[T,[O,At+" Touch"]],[/coc_coc\w+\/([\w\.]+)/i],[T,[O,"Coc Coc"]],[/dolfin\/([\w\.]+)/i],[T,[O,"Dolphin"]],[/coast\/([\w\.]+)/i],[T,[O,At+" Coast"]],[/miuibrowser\/([\w\.]+)/i],[T,[O,"MIUI"+vt]],[/fxios\/([\w\.-]+)/i],[T,[O,Ct+$t]],[/\bqihoobrowser\/?([\w\.]*)/i],[T,[O,"360"]],[/\b(qq)\/([\w\.]+)/i],[[O,/(.+)/,"$1Browser"],T],[/(oculus|sailfish|huawei|vivo|pico)browser\/([\w\.]+)/i],[[O,/(.+)/,"$1"+vt],T],[/ HBPC\/([\w\.]+)/],[T,[O,Yr+vt]],[/samsungbrowser\/([\w\.]+)/i],[T,[O,Ut+" Internet"]],[/metasr[\/ ]?([\d\.]+)/i],[T,[O,ai+" Explorer"]],[/(sogou)mo\w+\/([\d\.]+)/i],[[O,ai+" Mobile"],T],[/(electron)\/([\w\.]+) safari/i,/(tesla)(?: qtcarbrowser|\/(20\d\d\.[-\w\.]+))/i,/m?(qqbrowser|2345(?=browser|chrome|explorer))\w*[\/ ]?v?([\w\.]+)/i],[O,T],[/(lbbrowser|luakit|rekonq|steam(?= (clie|tenf|gameo)))/i],[O],[/ome\/([\w\.]+).+(iron(?= saf)|360(?=[es]e$))/i],[T,O],[/((?:fban\/fbios|fb_iab\/fb4a)(?!.+fbav)|;fbav\/([\w\.]+);)/i],[[O,tn],T,[C,qe]],[/(kakao(?:talk|story))[\/ ]([\w\.]+)/i,/(naver)\(.*?(\d+\.[\w\.]+).*\)/i,/(daum)apps[\/ ]([\w\.]+)/i,/safari (line)\/([\w\.]+)/i,/\b(line)\/([\w\.]+)\/iab/i,/(alipay)client\/([\w\.]+)/i,/(twitter)(?:and| f.+e\/([\w\.]+))/i,/(bing)(?:web|sapphire)\/([\w\.]+)/i,/(instagram|snapchat|klarna)[\/ ]([-\w\.]+)/i],[O,T,[C,qe]],[/\bgsa\/([\w\.]+) .*safari\//i],[T,[O,"GSA"],[C,qe]],[/(?:musical_ly|trill)(?:.+app_?version\/|_)([\w\.]+)/i],[T,[O,"TikTok"],[C,qe]],[/\[(linkedin)app\]/i],[O,[C,qe]],[/(zalo(?:app)?)[\/\sa-z]*([\w\.-]+)/i],[[O,/(.+)/,"Zalo"],T,[C,qe]],[/(chromium)[\/ ]([-\w\.]+)/i],[O,T],[/ome-(lighthouse)$/i],[O,[C,Ws]],[/headlesschrome(?:\/([\w\.]+)| )/i],[T,[O,ni+" Headless"]],[/wv\).+chrome\/([\w\.]+).+edgw\//i],[T,[O,Ir+" WebView2"],[C,qe]],[/; wv\).+(chrome)\/([\w\.]+)/i],[[O,ni+" WebView"],T,[C,qe]],[/droid.+ version\/([\w\.]+)\b.+(?:mobile safari|safari)/i],[T,[O,"Android"+vt]],[/chrome\/([\w\.]+) mobile/i],[T,[O,Ct+"Chrome"]],[/(chrome|omniweb|arora|[tizenoka]{5} ?browser)\/v?([\w\.]+)/i],[O,T],[/version\/([\w\.\,]+) .*mobile(?:\/\w+ | ?)safari/i],[T,[O,Ct+"Safari"]],[/iphone .*mobile(?:\/\w+ | ?)safari/i],[[O,Ct+"Safari"]],[/version\/([\w\.\,]+) .*(safari)/i],[T,O],[/webkit.+?(mobile ?safari|safari)(\/[\w\.]+)/i],[O,[T,"1"]],[/(webkit|khtml)\/([\w\.]+)/i],[O,T],[/(?:mobile|tablet);.*(firefox)\/([\w\.-]+)/i],[[O,Ct+$t],T],[/(navigator|netscape\d?)\/([-\w\.]+)/i],[[O,"Netscape"],T],[/(wolvic|librewolf)\/([\w\.]+)/i],[O,T],[/mobile vr; rv:([\w\.]+)\).+firefox/i],[T,[O,$t+" Reality"]],[/ekiohf.+(flow)\/([\w\.]+)/i,/(swiftfox)/i,/(icedragon|iceweasel|camino|chimera|fennec|maemo browser|minimo|conkeror)[\/ ]?([\w\.\+]+)/i,/(seamonkey|k-meleon|icecat|iceape|firebird|phoenix|basilisk|waterfox)\/([-\w\.]+)$/i,/(firefox)\/([\w\.]+)/i,/(mozilla)\/([\w\.]+(?= .+rv\:.+gecko\/\d+)|[0-4][\w\.]+(?!.+compatible))/i,/(amaya|dillo|doris|icab|ladybird|lynx|mosaic|netsurf|obigo|polaris|w3m|(?:go|ice|up)[\. ]?browser)[-\/ ]?v?([\w\.]+)/i,/\b(links) \(([\w\.]+)/i],[O,[T,/_/g,"."]],[/(cobalt)\/([\w\.]+)/i],[O,[T,/[^\d\.]+./,Rt]]],cpu:[[/\b((amd|x|x86[-_]?|wow|win)64)\b/i],[[be,"amd64"]],[/(ia32(?=;))/i,/\b((i[346]|x)86)(pc)?\b/i],[[be,"ia32"]],[/\b(aarch64|arm(v?[89]e?l?|_?64))\b/i],[[be,"arm64"]],[/\b(arm(v[67])?ht?n?[fl]p?)\b/i],[[be,"armhf"]],[/( (ce|mobile); ppc;|\/[\w\.]+arm\b)/i],[[be,"arm"]],[/ sun4\w[;\)]/i],[[be,"sparc"]],[/\b(avr32|ia64(?=;)|68k(?=\))|\barm(?=v([1-7]|[5-7]1)l?|;|eabi)|(irix|mips|sparc)(64)?\b|pa-risc)/i,/((ppc|powerpc)(64)?)( mac|;|\))/i,/(?:osf1|[freopnt]{3,4}bsd) (alpha)/i],[[be,/ower/,Rt,st]],[/mc680.0/i],[[be,"68k"]],[/winnt.+\[axp/i],[[be,"alpha"]]],device:[[/\b(sch-i[89]0\d|shw-m380s|sm-[ptx]\w{2,4}|gt-[pn]\d{2,4}|sgh-t8[56]9|nexus 10)/i],[S,[N,Ut],[C,Z]],[/\b((?:s[cgp]h|gt|sm)-(?![lr])\w+|sc[g-]?[\d]+a?|galaxy nexus)/i,/samsung[- ]((?!sm-[lr]|browser)[-\w]+)/i,/sec-(sgh\w+)/i],[S,[N,Ut],[C,H]],[/(?:\/|\()(ip(?:hone|od)[\w, ]*)[\/\);]/i],[S,[N,Et],[C,H]],[/\b(?:ios|apple\w+)\/.+[\(\/](ipad)/i,/\b(ipad)[\d,]*[;\] ].+(mac |i(pad)?)os/i],[S,[N,Et],[C,Z]],[/(macintosh);/i],[S,[N,Et]],[/\b(sh-?[altvz]?\d\d[a-ekm]?)/i],[S,[N,ri],[C,H]],[/\b((?:brt|eln|hey2?|gdi|jdn)-a?[lnw]09|(?:ag[rm]3?|jdn2|kob2)-a?[lw]0[09]hn)(?: bui|\)|;)/i],[S,[N,Jn],[C,Z]],[/honor([-\w ]+)[;\)]/i],[S,[N,Jn],[C,H]],[/\b((?:ag[rs][2356]?k?|bah[234]?|bg[2o]|bt[kv]|cmr|cpn|db[ry]2?|jdn2|got|kob2?k?|mon|pce|scm|sht?|[tw]gr|vrd)-[ad]?[lw][0125][09]b?|605hw|bg2-u03|(?:gem|fdr|m2|ple|t1)-[7a]0[1-4][lu]|t1-a2[13][lw]|mediapad[\w\. ]*(?= bui|\)))\b(?!.+d\/s)/i],[S,[N,Yr],[C,Z]],[/(?:huawei) ?([-\w ]+)[;\)]/i,/\b(nexus 6p|\w{2,4}e?-[atu]?[ln][\dx][\dc][adnt]?)\b(?!.+d\/s)/i],[S,[N,Yr],[C,H]],[/oid[^\)]+; (2[\dbc]{4}(182|283|rp\w{2})[cgl]|m2105k81a?c)(?: bui|\))/i,/\b(?:xiao)?((?:red)?mi[-_ ]?pad[\w- ]*)(?: bui|\))/i],[[S,/_/g," "],[N,Jr],[C,Z]],[/\b; (\w+) build\/hm\1/i,/\b(hm[-_ ]?note?[_ ]?(?:\d\w)?) bui/i,/oid[^\)]+; (redmi[\-_ ]?(?:note|k)?[\w_ ]+|m?[12]\d[01]\d\w{3,6}|poco[\w ]+|(shark )?\w{3}-[ah]0|qin ?[1-3](s\+|ultra| pro)?)( bui|; wv|\))/i,/\b(mi[-_ ]?(?:a\d|one|one[_ ]plus|note|max|cc)?[_ ]?(?:\d{0,2}\w?)[_ ]?(?:plus|se|lite|pro)?( 5g|lte)?)(?: bui|\))/i,/; ([\w ]+) miui\/v?\d/i],[[S,/_/g," "],[N,Jr],[C,H]],[/droid.+; (cph2[3-6]\d[13579]|((gm|hd)19|(ac|be|in|kb)20|(d[en]|eb|le|mt)21|ne22)[0-2]\d|p[g-l]\w[1m]10)\b/i,/(?:one)?(?:plus)? (a\d0\d\d)(?: b|\))/i],[S,[N,ti],[C,H]],[/; (\w+) bui.+ oppo/i,/\b(cph[12]\d{3}|p(?:af|c[al]|d\w|e[ar])[mt]\d0|x9007|a101op)\b/i],[S,[N,Qr],[C,H]],[/\b(opd2(\d{3}a?))(?: bui|\))/i],[S,[N,He,{OnePlus:["203","304","403","404","413","415"],"*":Qr}],[C,Z]],[/(vivo (5r?|6|8l?|go|one|s|x[il]?[2-4]?)[\w\+ ]*)(?: bui|\))/i],[S,[N,"BLU"],[C,H]],[/; vivo (\w+)(?: bui|\))/i,/\b(v[12]\d{3}\w?[at])(?: bui|;)/i],[S,[N,"Vivo"],[C,H]],[/\b(rmx[1-3]\d{3})(?: bui|;|\))/i],[S,[N,"Realme"],[C,H]],[/(ideatab[-\w ]+|602lv|d-42a|a101lv|a2109a|a3500-hv|s[56]000|pb-6505[my]|tb-?x?\d{3,4}(?:f[cu]|xu|[av])|yt\d?-[jx]?\d+[lfmx])( bui|;|\)|\/)/i,/lenovo ?(b[68]0[08]0-?[hf]?|tab(?:[\w- ]+?)|tb[\w-]{6,7})( bui|;|\)|\/)/i],[S,[N,Kr],[C,Z]],[/lenovo[-_ ]?([-\w ]+?)(?: bui|\)|\/)/i],[S,[N,Kr],[C,H]],[/\b(milestone|droid(?:[2-4x]| (?:bionic|x2|pro|razr))?:?( 4g)?)\b[\w ]+build\//i,/\bmot(?:orola)?[- ]([\w\s]+)(\)| bui)/i,/((?:moto(?! 360)[-\w\(\) ]+|xt\d{3,4}[cgkosw\+]?[-\d]*|nexus 6)(?= bui|\)))/i],[S,[N,qr],[C,H]],[/\b(mz60\d|xoom[2 ]{0,2}) build\//i],[S,[N,qr],[C,Z]],[/\b(?:lg)?([vl]k\-?\d{3}) bui| 3\.[-\w; ]{10}lg?-([06cv9]{3,4})/i],[S,[N,vr],[C,Z]],[/(lm(?:-?f100[nv]?|-[\w\.]+)(?= bui|\))|nexus [45])/i,/\blg[-e;\/ ]+(?!.*(?:browser|netcast|android tv|watch|webos))(\w+)/i,/\blg-?([\d\w]+) bui/i],[S,[N,vr],[C,H]],[/(nokia) (t[12][01])/i],[N,S,[C,Z]],[/(?:maemo|nokia).*(n900|lumia \d+|rm-\d+)/i,/nokia[-_ ]?(([-\w\. ]*?))( bui|\)|;|\/)/i],[[S,/_/g," "],[C,H],[N,"Nokia"]],[/(pixel (c|tablet))\b/i],[S,[N,ht],[C,Z]],[/droid.+;(?: google)? (g(01[13]a|020[aem]|025[jn]|1b60|1f8f|2ybb|4s1m|576d|5nz6|8hhn|8vou|a02099|c15s|d1yq|e2ae|ec77|gh2x|kv4x|p4bc|pj41|r83y|tt9q|ur25|wvk6)|pixel[\d ]*a?( pro)?( xl)?( fold)?( \(5g\))?)( bui|\))/i],[S,[N,ht],[C,H]],[/(google) (pixelbook( go)?)/i],[N,S],[/droid.+; (a?\d[0-2]{2}so|[c-g]\d{4}|so[-gl]\w+|xq-\w\w\d\d)(?= bui|\).+chrome\/(?![1-6]{0,1}\d\.))/i],[S,[N,Ht],[C,H]],[/sony tablet [ps]/i,/\b(?:sony)?sgp\w+(?: bui|\))/i],[[S,"Xperia Tablet"],[N,Ht],[C,Z]],[/(alexa)webm/i,/(kf[a-z]{2}wi|aeo(?!bc)\w\w)( bui|\))/i,/(kf[a-z]+)( bui|\)).+silk\//i],[S,[N,hr],[C,Z]],[/((?:sd|kf)[0349hijorstuw]+)( bui|\)).+silk\//i],[[S,/(.+)/g,"Fire Phone $1"],[N,hr],[C,H]],[/(playbook);[-\w\),; ]+(rim)/i],[S,N,[C,Z]],[/\b((?:bb[a-f]|st[hv])100-\d)/i,/(?:blackberry|\(bb10;) (\w+)/i],[S,[N,Qn],[C,H]],[/(?:\b|asus_)(transfo[prime ]{4,10} \w+|eeepc|slider \w+|nexus 7|padfone|p00[cj])/i],[S,[N,qn],[C,Z]],[/ (z[bes]6[027][012][km][ls]|zenfone \d\w?)\b/i],[S,[N,qn],[C,H]],[/(nexus 9)/i],[S,[N,"HTC"],[C,Z]],[/(htc)[-;_ ]{1,2}([\w ]+(?=\)| bui)|\w+)/i,/(zte)[- ]([\w ]+?)(?: bui|\/|\))/i,/(alcatel|geeksphone|nexian|panasonic(?!(?:;|\.))|sony(?!-bra))[-_ ]?([-\w]*)/i],[N,[S,/_/g," "],[C,H]],[/tcl (xess p17aa)/i,/droid [\w\.]+; ((?:8[14]9[16]|9(?:0(?:48|60|8[01])|1(?:3[27]|66)|2(?:6[69]|9[56])|466))[gqswx])(_\w(\w|\w\w))?(\)| bui)/i],[S,[N,"TCL"],[C,Z]],[/droid [\w\.]+; (418(?:7d|8v)|5087z|5102l|61(?:02[dh]|25[adfh]|27[ai]|56[dh]|59k|65[ah])|a509dl|t(?:43(?:0w|1[adepqu])|50(?:6d|7[adju])|6(?:09dl|10k|12b|71[efho]|76[hjk])|7(?:66[ahju]|67[hw]|7[045][bh]|71[hk]|73o|76[ho]|79w|81[hks]?|82h|90[bhsy]|99b)|810[hs]))(_\w(\w|\w\w))?(\)| bui)/i],[S,[N,"TCL"],[C,H]],[/(itel) ((\w+))/i],[[N,st],S,[C,He,{tablet:["p10001l","w7001"],"*":"mobile"}]],[/droid.+; ([ab][1-7]-?[0178a]\d\d?)/i],[S,[N,"Acer"],[C,Z]],[/droid.+; (m[1-5] note) bui/i,/\bmz-([-\w]{2,})/i],[S,[N,"Meizu"],[C,H]],[/; ((?:power )?armor(?:[\w ]{0,8}))(?: bui|\))/i],[S,[N,"Ulefone"],[C,H]],[/; (energy ?\w+)(?: bui|\))/i,/; energizer ([\w ]+)(?: bui|\))/i],[S,[N,"Energizer"],[C,H]],[/; cat (b35);/i,/; (b15q?|s22 flip|s48c|s62 pro)(?: bui|\))/i],[S,[N,"Cat"],[C,H]],[/((?:new )?andromax[\w- ]+)(?: bui|\))/i],[S,[N,"Smartfren"],[C,H]],[/droid.+; (a(in)?(0(15|59|6[35])|142)p?)/i],[S,[N,"Nothing"],[C,H]],[/; (x67 5g|tikeasy \w+|ac[1789]\d\w+)( b|\))/i,/archos ?(5|gamepad2?|([\w ]*[t1789]|hello) ?\d+[\w ]*)( b|\))/i],[S,[N,"Archos"],[C,Z]],[/archos ([\w ]+)( b|\))/i,/; (ac[3-6]\d\w{2,8})( b|\))/i],[S,[N,"Archos"],[C,H]],[/blackview ([-\w ]+)( b|\))/i,/; (bv\d{4}[-\w ]*)( b|\))/i],[S,[N,"Blackview"],[C,H]],[/; (n159v)/i],[S,[N,"HMD"],[C,H]],[/((revvl[ \w\+]+|tm(?:rv|af)\w*[45]g(?:tb)?))( b|\))/i],[S,[C,t1,{test:/ta?b/i,ifTrue:Z,ifFalse:H}],[N,"T-Mobile"]],[/(imo) (tab \w+)/i,/(infinix|tecno) (x1101b?|p904|dp(7c|8d|10a)( pro)?|p70[1-3]a?|p904|t1101)/i],[N,S,[C,Z]],[/(blackberry|benq|palm(?=\-)|sonyericsson|acer|asus(?! zenw)|dell|jolla|meizu|motorola|polytron|tecno|micromax|advan)[-_ ]?([-\w]*)/i,/; (blu|coolpad|cubot|hmd|imo|infinix|lava|oneplus|tcl|wiko)[_ ]([-\w\+ ]+?)(?: bui|\)|; r)/i,/(hp) ([\w ]+\w)/i,/(microsoft); (lumia[\w ]+)/i,/(oppo) ?([\w ]+) bui/i,/(hisense) ([ehv][\w ]+)\)/i,/droid[^;]+; (philips)[_ ]([sv-x][\d]{3,4}[xz]?)/i],[N,S,[C,H]],[/(kobo)\s(ereader|touch)/i,/(hp).+(touchpad(?!.+tablet)|tablet)/i,/(kindle)\/([\w\.]+)/i],[N,S,[C,Z]],[/(surface duo)/i],[S,[N,Zr],[C,Z]],[/droid [\d\.]+; (fp\du?)(?: b|\))/i],[S,[N,"Fairphone"],[C,H]],[/((?:tegranote|shield t(?!.+d tv))[\w- ]*?)(?: b|\))/i],[S,[N,ei],[C,Z]],[/(sprint) (\w+)/i],[N,S,[C,H]],[/(kin\.[onetw]{3})/i],[[S,/\./g," "],[N,Zr],[C,H]],[/droid.+; ([c6]+|et5[16]|mc[239][23]x?|vc8[03]x?)\)/i],[S,[N,en],[C,Z]],[/droid.+; (ec30|ps20|tc[2-8]\d[kx])\)/i],[S,[N,en],[C,H]],[/(philips)[\w ]+tv/i,/smart-tv.+(samsung)/i],[N,[C,fe]],[/hbbtv.+maple;(\d+)/i],[[S,/^/,"SmartTV"],[N,Ut],[C,fe]],[/(vizio)(?: |.+model\/)(\w+-\w+)/i,/tcast.+(lg)e?. ([-\w]+)/i],[N,S,[C,fe]],[/(nux; netcast.+smarttv|lg (netcast\.tv-201\d|android tv))/i],[[N,vr],[C,fe]],[/(apple) ?tv/i],[N,[S,Et+" TV"],[C,fe]],[/crkey.*devicetype\/chromecast/i],[[S,nt+" Third Generation"],[N,ht],[C,fe]],[/crkey.*devicetype\/([^/]*)/i],[[S,/^/,"Chromecast "],[N,ht],[C,fe]],[/fuchsia.*crkey/i],[[S,nt+" Nest Hub"],[N,ht],[C,fe]],[/crkey/i],[[S,nt],[N,ht],[C,fe]],[/(portaltv)/i],[S,[N,tn],[C,fe]],[/droid.+aft(\w+)( bui|\))/i],[S,[N,hr],[C,fe]],[/(shield \w+ tv)/i],[S,[N,ei],[C,fe]],[/\(dtv[\);].+(aquos)/i,/(aquos-tv[\w ]+)\)/i],[S,[N,ri],[C,fe]],[/(bravia[\w ]+)( bui|\))/i],[S,[N,Ht],[C,fe]],[/(mi(tv|box)-?\w+) bui/i],[S,[N,Jr],[C,fe]],[/Hbbtv.*(technisat) (.*);/i],[N,S,[C,fe]],[/\b(roku)[\dx]*[\)\/]((?:dvp-)?[\d\.]*)/i,/hbbtv\/\d+\.\d+\.\d+ +\([\w\+ ]*; *([\w\d][^;]*);([^;]*)/i],[[N,/.+\/(\w+)/,"$1",He,{LG:"lge"}],[S,or],[C,fe]],[/(playstation \w+)/i],[S,[N,Ht],[C,Sr]],[/\b(xbox(?: one)?(?!; xbox))[\); ]/i],[S,[N,Zr],[C,Sr]],[/(ouya)/i,/(nintendo) (\w+)/i,/(retroid) (pocket ([^\)]+))/i,/(valve).+(steam deck)/i,/droid.+; ((shield|rgcube|gr0006))( bui|\))/i],[[N,He,{Nvidia:"Shield",Anbernic:"RGCUBE",Logitech:"GR0006"}],S,[C,Sr]],[/\b(sm-[lr]\d\d[0156][fnuw]?s?|gear live)\b/i],[S,[N,Ut],[C,We]],[/((pebble))app/i,/(asus|google|lg|oppo|xiaomi) ((pixel |zen)?watch[\w ]*)( bui|\))/i],[N,S,[C,We]],[/(ow(?:19|20)?we?[1-3]{1,3})/i],[S,[N,Qr],[C,We]],[/(watch)(?: ?os[,\/]|\d,\d\/)[\d\.]+/i],[S,[N,Et],[C,We]],[/(opwwe\d{3})/i],[S,[N,ti],[C,We]],[/(moto 360)/i],[S,[N,qr],[C,We]],[/(smartwatch 3)/i],[S,[N,Ht],[C,We]],[/(g watch r)/i],[S,[N,vr],[C,We]],[/droid.+; (wt63?0{2,3})\)/i],[S,[N,en],[C,We]],[/droid.+; (glass) \d/i],[S,[N,ht],[C,dr]],[/(pico) ([\w ]+) os\d/i],[N,S,[C,dr]],[/(quest( \d| pro)?s?).+vr/i],[S,[N,tn],[C,dr]],[/mobile vr; rv.+firefox/i],[[C,dr]],[/(tesla)(?: qtcarbrowser|\/[-\w\.]+)/i],[N,[C,Yt]],[/(aeobc)\b/i],[S,[N,hr],[C,Yt]],[/(homepod).+mac os/i],[S,[N,Et],[C,Yt]],[/windows iot/i],[[C,Yt]],[/droid.+; ([\w- ]+) (4k|android|smart|google)[- ]?tv/i],[S,[C,fe]],[/\b((4k|android|smart|opera)[- ]?tv|tv; rv:|large screen[\w ]+safari)\b/i],[[C,fe]],[/droid .+?; ([^;]+?)(?: bui|; wv\)|\) applew|; hmsc).+?(mobile|vr|\d) safari/i],[S,[C,He,{mobile:"Mobile",xr:"VR","*":Z}]],[/\b((tablet|tab)[;\/]|focus\/\d(?!.+mobile))/i],[[C,Z]],[/(phone|mobile(?:[;\/]| [ \w\/\.]*safari)|pda(?=.+windows ce))/i],[[C,H]],[/droid .+?; ([\w\. -]+)( bui|\))/i],[S,[N,"Generic"]]],engine:[[/windows.+ edge\/([\w\.]+)/i],[T,[O,Ir+"HTML"]],[/(arkweb)\/([\w\.]+)/i],[O,T],[/webkit\/537\.36.+chrome\/(?!27)([\w\.]+)/i],[T,[O,"Blink"]],[/(presto)\/([\w\.]+)/i,/(webkit|trident|netfront|netsurf|amaya|lynx|w3m|goanna|servo)\/([\w\.]+)/i,/ekioh(flow)\/([\w\.]+)/i,/(khtml|tasman|links|dillo)[\/ ]\(?([\w\.]+)/i,/(icab)[\/ ]([23]\.[\d\.]+)/i,/\b(libweb)/i],[O,T],[/ladybird\//i],[[O,"LibWeb"]],[/rv\:([\w\.]{1,9})\b.+(gecko)/i],[T,O]],os:[[/(windows nt) (6\.[23]); arm/i],[[O,/N/,"R"],[T,He,oi]],[/(windows (?:phone|mobile|iot))(?: os)?[\/ ]?([\d\.]*( se)?)/i,/(windows)[\/ ](1[01]|2000|3\.1|7|8(\.1)?|9[58]|me|server 20\d\d( r2)?|vista|xp)/i],[O,T],[/windows nt ?([\d\.\)]*)(?!.+xbox)/i,/\bwin(?=3| ?9|n)(?:nt| 9x )?([\d\.;]*)/i],[[T,/(;|\))/g,"",He,oi],[O,yn]],[/(windows ce)\/?([\d\.]*)/i],[O,T],[/[adehimnop]{4,7}\b(?:.*os ([\w]+) like mac|; opera)/i,/(?:ios;fbsv|ios(?=.+ip(?:ad|hone)|.+apple ?tv)|ip(?:ad|hone)(?: |.+i(?:pad)?)os|apple ?tv.+ios)[\/ ]([\w\.]+)/i,/\btvos ?([\w\.]+)/i,/cfnetwork\/.+darwin/i],[[T,/_/g,"."],[O,"iOS"]],[/(mac os x) ?([\w\. ]*)/i,/(macintosh|mac_powerpc\b)(?!.+(haiku|morphos))/i],[[O,"macOS"],[T,/_/g,"."]],[/android ([\d\.]+).*crkey/i],[T,[O,nt+" Android"]],[/fuchsia.*crkey\/([\d\.]+)/i],[T,[O,nt+" Fuchsia"]],[/crkey\/([\d\.]+).*devicetype\/smartspeaker/i],[T,[O,nt+" SmartSpeaker"]],[/linux.*crkey\/([\d\.]+)/i],[T,[O,nt+" Linux"]],[/crkey\/([\d\.]+)/i],[T,[O,nt]],[/droid ([\w\.]+)\b.+(android[- ]x86)/i],[T,O],[/(ubuntu) ([\w\.]+) like android/i],[[O,/(.+)/,"$1 Touch"],T],[/(harmonyos)[\/ ]?([\d\.]*)/i,/(android|bada|blackberry|kaios|maemo|meego|openharmony|qnx|rim tablet os|sailfish|series40|symbian|tizen)\w*[-\/\.; ]?([\d\.]*)/i],[O,T],[/\(bb(10);/i],[T,[O,Qn]],[/(?:symbian ?os|symbos|s60(?=;)|series ?60)[-\/ ]?([\w\.]*)/i],[T,[O,"Symbian"]],[/mozilla\/[\d\.]+ \((?:mobile[;\w ]*|tablet|tv|[^\)]*(?:viera|lg(?:l25|-d300)|alcatel ?o.+|y300-f1)); rv:([\w\.]+)\).+gecko\//i],[T,[O,$t+" OS"]],[/\b(?:hp)?wos(?:browser)?\/([\w\.]+)/i,/webos(?:[ \/]?|\.tv-20(?=2[2-9]))(\d[\d\.]*)/i],[T,[O,"webOS"]],[/web0s;.+?(?:chr[o0]me|safari)\/(\d+)/i],[[T,He,{25:"120",24:"108",23:"94",22:"87",6:"79",5:"68",4:"53",3:"38",2:"538",1:"537","*":"TV"}],[O,"webOS"]],[/watch(?: ?os[,\/ ]|\d,\d\/)([\d\.]+)/i],[T,[O,"watchOS"]],[/cros [\w]+(?:\)| ([\w\.]+)\b)/i],[T,[O,"Chrome OS"]],[/kepler ([\w\.]+); (aft|aeo)/i],[T,[O,"Vega OS"]],[/(netrange)mmh/i,/(nettv)\/(\d+\.[\w\.]+)/i,/(nintendo|playstation) (\w+)/i,/(xbox); +xbox ([^\);]+)/i,/(pico) .+os([\w\.]+)/i,/\b(joli|palm)\b ?(?:os)?\/?([\w\.]*)/i,/linux.+(mint)[\/\(\) ]?([\w\.]*)/i,/(mageia|vectorlinux|fuchsia|arcaos|arch(?= ?linux))[;l ]([\d\.]*)/i,/([kxln]?ubuntu|debian|suse|opensuse|gentoo|slackware|fedora|mandriva|centos|pclinuxos|red ?hat|zenwalk|linpus|raspbian|plan 9|minix|risc os|contiki|deepin|manjaro|elementary os|sabayon|linspire|knoppix)(?: gnu[\/ ]linux)?(?: enterprise)?(?:[- ]linux)?(?:-gnu)?[-\/ ]?(?!chrom|package)([-\w\.]*)/i,/((?:open)?solaris)[-\/ ]?([\w\.]*)/i,/\b(aix)[; ]([1-9\.]{0,4})/i,/(hurd|linux|morphos)(?: (?:arm|x86|ppc)\w*| ?)([\w\.]*)/i,/(gnu) ?([\w\.]*)/i,/\b([-frentopcghs]{0,5}bsd|dragonfly)[\/ ]?(?!amd|[ix346]{1,2}86)([\w\.]*)/i,/(haiku) ?(r\d)?/i],[O,T],[/(sunos) ?([\d\.]*)/i],[[O,"Solaris"],T],[/\b(beos|os\/2|amigaos|openvms|hp-ux|serenityos)/i,/(unix) ?([\w\.]*)/i],[O,T]]},pr=(function(){var t={init:{},isIgnore:{},isIgnoreRgx:{},toString:{}};return Je.call(t.init,[[De,[O,T,ir,C]],[et,[be]],[Ye,[C,S,N]],[Ge,[O,T]],[ke,[O,T]]]),Je.call(t.isIgnore,[[De,[T,ir]],[Ge,[T]],[ke,[T]]]),Je.call(t.isIgnoreRgx,[[De,/ ?browser$/i],[ke,/ ?os$/i]]),Je.call(t.toString,[[De,[O,T]],[et,[be]],[Ye,[N,S]],[Ge,[O,T]],[ke,[O,T]]]),t})(),i1=function(t,e){var r=pr.init[e],n=pr.isIgnore[e]||0,i=pr.isIgnoreRgx[e]||0,a=pr.toString[e]||0;function o(){Je.call(this,r)}return o.prototype.getItem=function(){return t},o.prototype.withClientHints=function(){return mt?mt.getHighEntropyValues(Ki).then(function(s){return t.setCH(new Zi(s,!1)).parseCH().get()}):t.parseCH().get()},o.prototype.withFeatureCheck=function(){return t.detectFeature().get()},e!=Pt&&(o.prototype.is=function(s){var c=!1;for(var u in this)if(this.hasOwnProperty(u)&&!mn(n,u)&&st(i?ar(i,this[u]):this[u])==st(i?ar(i,s):s)){if(c=!0,s!=ue.UNDEFINED)break}else if(s==ue.UNDEFINED&&c){c=!c;break}return c},o.prototype.toString=function(){var s=Rt;for(var c in a)typeof this[a[c]]!==ue.UNDEFINED&&(s+=(s?" ":Rt)+this[a[c]]);return s||ue.UNDEFINED}),o.prototype.then=function(s){var c=this,u=function(){for(var d in c)c.hasOwnProperty(d)&&(this[d]=c[d])};u.prototype={is:o.prototype.is,toString:o.prototype.toString,withClientHints:o.prototype.withClientHints,withFeatureCheck:o.prototype.withFeatureCheck};var l=new u;return s(l),l},new o};function Zi(t,e){if(t=t||{},Je.call(this,Ki),e)Je.call(this,[[Mn,rn(t[dt])],[Ln,rn(t[Xs])],[H,/\?1/.test(t[Zs])],[S,St(t[qs])],[kt,St(t[Yi])],[Fn,St(t[Qs])],[be,St(t[js])],[yt,rn(t[Ks])],[Vr,St(t[Ys])]]);else for(var r in t)this.hasOwnProperty(r)&&typeof t[r]!==ue.UNDEFINED&&(this[r]=t[r])}function ft(t,e,r,n){return Je.call(this,[["itemType",t],["ua",e],["uaCH",n],["rgxMap",r],["data",i1(this,t)]]),this}ft.prototype.get=function(t){return t?this.data.hasOwnProperty(t)?this.data[t]:void 0:this.data};ft.prototype.set=function(t,e){return this.data[t]=e,this};ft.prototype.setCH=function(t){return this.uaCH=t,this};ft.prototype.detectFeature=function(){if(Te&&Te.userAgent==this.ua)switch(this.itemType){case De:Te.brave&&typeof Te.brave.isBrave==ue.FUNCTION&&this.set(O,"Brave");break;case Ye:!this.get(C)&&mt&&mt[H]&&this.set(C,H),this.get(S)=="Macintosh"&&Te&&typeof Te.standalone!==ue.UNDEFINED&&Te.maxTouchPoints&&Te.maxTouchPoints>2&&this.set(S,"iPad").set(C,Z);break;case ke:!this.get(O)&&mt&&mt[kt]&&this.set(O,mt[kt]);break;case Pt:var t=this.data,e=function(r){return t[r].getItem().detectFeature().get()};this.set(De,e(De)).set(et,e(et)).set(Ye,e(Ye)).set(Ge,e(Ge)).set(ke,e(ke))}return this};ft.prototype.parseUA=function(){switch(this.itemType!=Pt&&_n.call(this.data,this.ua,this.rgxMap),this.itemType){case De:this.set(ir,wn(this.get(T)));break;case ke:if(this.get(O)=="iOS"&&this.get(T)&&/^1[89][^\d]/.exec(this.get(T))){var t=/\) Version\/((\d+)[\d\.]*)/.exec(this.ua);t&&parseInt(t[2],10)>=26&&this.set(T,t[1])}break}return this};ft.prototype.parseCH=function(){var t=this.uaCH,e=this.rgxMap;switch(this.itemType){case De:case Ge:var r=t[Ln]||t[Mn],n;if(r)for(var i=0;i<r.length;i++){var a=r[i].brand||r[i],o=r[i].version;this.itemType==De&&!/not.a.brand/i.test(a)&&(!n||/Chrom/.test(n)&&a!=ii||n==Ir&&/WebView2/.test(a))&&(a=He(a,r1),n=this.get(O),n&&!/Chrom/.test(n)&&/Chrom/.test(a)||this.set(O,a).set(T,o).set(ir,wn(o)),n=a),this.itemType==Ge&&a==ii&&this.set(T,o)}break;case et:var s=t[be];s&&(s&&t[Vr]=="64"&&(s+="64"),_n.call(this.data,s+";",e));break;case Ye:if(t[H]&&this.set(C,H),t[S]&&(this.set(S,t[S]),!this.get(C)||!this.get(N))){var c={};_n.call(c,"droid 9; "+t[S]+")",e),!this.get(C)&&c.type&&this.set(C,c.type),!this.get(N)&&c.vendor&&this.set(N,c.vendor)}if(t[yt]){var u;if(typeof t[yt]!="string")for(var l=0;!u&&l<t[yt].length;)u=He(t[yt][l++],si);else u=He(t[yt],si);this.set(C,u)}break;case ke:var d=t[kt];if(d){var v=t[Fn];d==yn&&(v=parseInt(wn(v),10)>=13?"11":"10"),this.set(O,d).set(T,v)}this.get(O)==yn&&t[S]=="Xbox"&&this.set(O,"Xbox").set(T,void 0);break;case Pt:var h=this.data,p=function(g){return h[g].getItem().setCH(t).parseCH().get()};this.set(De,p(De)).set(et,p(et)).set(Ye,p(Ye)).set(Ge,p(Ge)).set(ke,p(ke))}return this};function tt(t,e,r){if(typeof t===ue.OBJECT?(Rr(t,!0)?(typeof e===ue.OBJECT&&(r=e),e=t):(r=t,e=void 0),t=void 0):typeof t===ue.STRING&&!Rr(e,!0)&&(r=e,e=void 0),r)if(typeof r.append===ue.FUNCTION){var n={};r.forEach(function(l,d){n[String(d).toLowerCase()]=l}),r=n}else{var i={};for(var a in r)r.hasOwnProperty(a)&&(i[String(a).toLowerCase()]=r[a]);r=i}if(!(this instanceof tt))return new tt(t,e,r).getResult();var o=typeof t===ue.STRING?t:r&&r[Kn]?r[Kn]:Te&&Te.userAgent?Te.userAgent:Rt,s=new Zi(r,!0),c=n1,u=function(l){return l==Pt?function(){return new ft(l,o,c,s).set("ua",o).set(De,this.getBrowser()).set(et,this.getCPU()).set(Ye,this.getDevice()).set(Ge,this.getEngine()).set(ke,this.getOS()).get()}:function(){return new ft(l,o,c[l],s).parseUA().get()}};return Je.call(this,[["getBrowser",u(De)],["getCPU",u(et)],["getDevice",u(Ye)],["getEngine",u(Ge)],["getOS",u(ke)],["getResult",u(Pt)],["getUA",function(){return o}],["setUA",function(l){return Lt(l)&&(o=or(l,ji)),this}],["useExtension",function(l){return l&&(c=e1(c,l)),this}]]).setUA(o).useExtension(e),this}tt.VERSION=zs;tt.BROWSER=Ur([O,T,ir,C]);tt.CPU=Ur([be]);tt.DEVICE=Ur([S,N,C,Sr,H,fe,Z,We,Yt]);tt.ENGINE=tt.OS=Ur([O,T]);const nn=typeof navigator<"u"?navigator.userAgent.toLowerCase().indexOf("firefox")>0:!1;function an(t,e,r,n){t.addEventListener?t.addEventListener(e,r,n):t.attachEvent&&t.attachEvent("on".concat(e),r)}function Gt(t,e,r,n){t.removeEventListener?t.removeEventListener(e,r,n):t.detachEvent&&t.detachEvent("on".concat(e),r)}function qi(t,e){const r=e.slice(0,e.length-1);for(let n=0;n<r.length;n++)r[n]=t[r[n].toLowerCase()];return r}function Qi(t){typeof t!="string"&&(t=""),t=t.replace(/\s/g,"");const e=t.split(",");let r=e.lastIndexOf("");for(;r>=0;)e[r-1]+=",",e.splice(r,1),r=e.lastIndexOf("");return e}function a1(t,e){const r=t.length>=e.length?t:e,n=t.length>=e.length?e:t;let i=!0;for(let a=0;a<r.length;a++)n.indexOf(r[a])===-1&&(i=!1);return i}const sr={backspace:8,"⌫":8,tab:9,clear:12,enter:13,"↩":13,return:13,esc:27,escape:27,space:32,left:37,up:38,right:39,down:40,arrowup:38,arrowdown:40,arrowleft:37,arrowright:39,del:46,delete:46,ins:45,insert:45,home:36,end:35,pageup:33,pagedown:34,capslock:20,num_0:96,num_1:97,num_2:98,num_3:99,num_4:100,num_5:101,num_6:102,num_7:103,num_8:104,num_9:105,num_multiply:106,num_add:107,num_enter:108,num_subtract:109,num_decimal:110,num_divide:111,"⇪":20,",":188,".":190,"/":191,"`":192,"-":nn?173:189,"=":nn?61:187,";":nn?59:186,"'":222,"{":219,"}":221,"[":219,"]":221,"\\":220},ze={"⇧":16,shift:16,"⌥":18,alt:18,option:18,"⌃":17,ctrl:17,control:17,"⌘":91,cmd:91,meta:91,command:91},Kt={16:"shiftKey",18:"altKey",17:"ctrlKey",91:"metaKey",shiftKey:16,ctrlKey:17,altKey:18,metaKey:91},ye={16:!1,18:!1,17:!1,91:!1},se={};for(let t=1;t<20;t++)sr["f".concat(t)]=111+t;let oe=[],tr=null,Ji="all";const Qe=new Map,Ft=t=>sr[t.toLowerCase()]||ze[t.toLowerCase()]||t.toUpperCase().charCodeAt(0),o1=t=>Object.keys(sr).find(e=>sr[e]===t),s1=t=>Object.keys(ze).find(e=>ze[e]===t);function ea(t){Ji=t||"all"}function cr(){return Ji||"all"}function c1(){return oe.slice(0)}function u1(){return oe.map(t=>o1(t)||s1(t)||String.fromCharCode(t))}function f1(){const t=[];return Object.keys(se).forEach(e=>{se[e].forEach(r=>{let{key:n,scope:i,mods:a,shortcut:o}=r;t.push({scope:i,shortcut:o,mods:a,keys:n.split("+").map(s=>Ft(s))})})}),t}function l1(t){const e=t.target||t.srcElement,{tagName:r}=e;let n=!0;const i=r==="INPUT"&&!["checkbox","radio","range","button","file","reset","submit","color"].includes(e.type);return(e.isContentEditable||(i||r==="TEXTAREA"||r==="SELECT")&&!e.readOnly)&&(n=!1),n}function d1(t){return typeof t=="string"&&(t=Ft(t)),oe.indexOf(t)!==-1}function h1(t,e){let r,n;t||(t=cr());for(const i in se)if(Object.prototype.hasOwnProperty.call(se,i))for(r=se[i],n=0;n<r.length;)r[n].scope===t?r.splice(n,1).forEach(o=>{let{element:s}=o;return Vn(s)}):n++;cr()===t&&ea(e||"all")}function v1(t){let e=t.keyCode||t.which||t.charCode;t.key&&t.key.toLowerCase()==="capslock"&&(e=Ft(t.key));const r=oe.indexOf(e);if(r>=0&&oe.splice(r,1),t.key&&t.key.toLowerCase()==="meta"&&oe.splice(0,oe.length),(e===93||e===224)&&(e=91),e in ye){ye[e]=!1;for(const n in ze)ze[n]===e&&(Xe[n]=!1)}}function ta(t){if(typeof t>"u")Object.keys(se).forEach(i=>{Array.isArray(se[i])&&se[i].forEach(a=>gr(a)),delete se[i]}),Vn(null);else if(Array.isArray(t))t.forEach(i=>{i.key&&gr(i)});else if(typeof t=="object")t.key&&gr(t);else if(typeof t=="string"){for(var e=arguments.length,r=new Array(e>1?e-1:0),n=1;n<e;n++)r[n-1]=arguments[n];let[i,a]=r;typeof i=="function"&&(a=i,i=""),gr({key:t,scope:i,method:a,splitKey:"+"})}}const gr=t=>{let{key:e,scope:r,method:n,splitKey:i="+"}=t;Qi(e).forEach(o=>{const s=o.split(i),c=s.length,u=s[c-1],l=u==="*"?"*":Ft(u);if(!se[l])return;r||(r=cr());const d=c>1?qi(ze,s):[],v=[];se[l]=se[l].filter(h=>{const g=(n?h.method===n:!0)&&h.scope===r&&a1(h.mods,d);return g&&v.push(h.element),!g}),v.forEach(h=>Vn(h))})};function ci(t,e,r,n){if(e.element!==n)return;let i;if(e.scope===r||e.scope==="all"){i=e.mods.length>0;for(const a in ye)Object.prototype.hasOwnProperty.call(ye,a)&&(!ye[a]&&e.mods.indexOf(+a)>-1||ye[a]&&e.mods.indexOf(+a)===-1)&&(i=!1);(e.mods.length===0&&!ye[16]&&!ye[18]&&!ye[17]&&!ye[91]||i||e.shortcut==="*")&&(e.keys=[],e.keys=e.keys.concat(oe),e.method(t,e)===!1&&(t.preventDefault?t.preventDefault():t.returnValue=!1,t.stopPropagation&&t.stopPropagation(),t.cancelBubble&&(t.cancelBubble=!0)))}}function ui(t,e){const r=se["*"];let n=t.keyCode||t.which||t.charCode;if(t.key&&t.key.toLowerCase()==="capslock"||!Xe.filter.call(this,t))return;if((n===93||n===224)&&(n=91),oe.indexOf(n)===-1&&n!==229&&oe.push(n),["metaKey","ctrlKey","altKey","shiftKey"].forEach(s=>{const c=Kt[s];t[s]&&oe.indexOf(c)===-1?oe.push(c):!t[s]&&oe.indexOf(c)>-1?oe.splice(oe.indexOf(c),1):s==="metaKey"&&t[s]&&(oe=oe.filter(u=>u in Kt||u===n))}),n in ye){ye[n]=!0;for(const s in ze)if(Object.prototype.hasOwnProperty.call(ze,s)){const c=Kt[ze[s]];Xe[s]=t[c]}if(!r)return}for(const s in ye)Object.prototype.hasOwnProperty.call(ye,s)&&(ye[s]=t[Kt[s]]);t.getModifierState&&!(t.altKey&&!t.ctrlKey)&&t.getModifierState("AltGraph")&&(oe.indexOf(17)===-1&&oe.push(17),oe.indexOf(18)===-1&&oe.push(18),ye[17]=!0,ye[18]=!0);const i=cr();if(r)for(let s=0;s<r.length;s++)r[s].scope===i&&(t.type==="keydown"&&r[s].keydown||t.type==="keyup"&&r[s].keyup)&&ci(t,r[s],i,e);if(!(n in se))return;const a=se[n],o=a.length;for(let s=0;s<o;s++)if((t.type==="keydown"&&a[s].keydown||t.type==="keyup"&&a[s].keyup)&&a[s].key){const c=a[s],{splitKey:u}=c,l=c.key.split(u),d=[];for(let v=0;v<l.length;v++)d.push(Ft(l[v]));d.sort().join("")===oe.sort().join("")&&ci(t,c,i,e)}}function Xe(t,e,r){oe=[];const n=Qi(t);let i=[],a="all",o=document,s=0,c=!1,u=!0,l="+",d=!1,v=!1;for(r===void 0&&typeof e=="function"&&(r=e),Object.prototype.toString.call(e)==="[object Object]"&&(e.scope&&(a=e.scope),e.element&&(o=e.element),e.keyup&&(c=e.keyup),e.keydown!==void 0&&(u=e.keydown),e.capture!==void 0&&(d=e.capture),typeof e.splitKey=="string"&&(l=e.splitKey),e.single===!0&&(v=!0)),typeof e=="string"&&(a=e),v&&ta(t,a);s<n.length;s++)t=n[s].split(l),i=[],t.length>1&&(i=qi(ze,t)),t=t[t.length-1],t=t==="*"?"*":Ft(t),t in se||(se[t]=[]),se[t].push({keyup:c,keydown:u,scope:a,mods:i,shortcut:n[s],method:r,key:n[s],splitKey:l,element:o});if(typeof o<"u"&&window){if(!Qe.has(o)){const h=function(){let g=arguments.length>0&&arguments[0]!==void 0?arguments[0]:window.event;return ui(g,o)},p=function(){let g=arguments.length>0&&arguments[0]!==void 0?arguments[0]:window.event;ui(g,o),v1(g)};Qe.set(o,{keydownListener:h,keyupListenr:p,capture:d}),an(o,"keydown",h,d),an(o,"keyup",p,d)}if(!tr){const h=()=>{oe=[]};tr={listener:h,capture:d},an(window,"focus",h,d)}}}function p1(t){let e=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"all";Object.keys(se).forEach(r=>{se[r].filter(i=>i.scope===e&&i.shortcut===t).forEach(i=>{i&&i.method&&i.method()})})}function Vn(t){const e=Object.values(se).flat();if(e.findIndex(n=>{let{element:i}=n;return i===t})<0){const{keydownListener:n,keyupListenr:i,capture:a}=Qe.get(t)||{};n&&i&&(Gt(t,"keyup",i,a),Gt(t,"keydown",n,a),Qe.delete(t))}if((e.length<=0||Qe.size<=0)&&(Object.keys(Qe).forEach(i=>{const{keydownListener:a,keyupListenr:o,capture:s}=Qe.get(i)||{};a&&o&&(Gt(i,"keyup",o,s),Gt(i,"keydown",a,s),Qe.delete(i))}),Qe.clear(),Object.keys(se).forEach(i=>delete se[i]),tr)){const{listener:i,capture:a}=tr;Gt(window,"focus",i,a),tr=null}}const on={getPressedKeyString:u1,setScope:ea,getScope:cr,deleteScope:h1,getPressedKeyCodes:c1,getAllKeyCodes:f1,isPressed:d1,filter:l1,trigger:p1,unbind:ta,keyMap:sr,modifier:ze,modifierMap:Kt};for(const t in on)Object.prototype.hasOwnProperty.call(on,t)&&(Xe[t]=on[t]);if(typeof window<"u"){const t=window.hotkeys;Xe.noConflict=e=>(e&&window.hotkeys===Xe&&(window.hotkeys=t),Xe),window.hotkeys=Xe}const g1={class:"dsg-dropdown__trigger",tabindex:"0"},x1={class:"dsg-dropdown__menu"},y1={key:0,class:"dsg-dropdown__menu-header"},m1={key:1,class:"dsg-dropdown__menu-header"},w1={class:"dsg-dropdown__menu-title"},_1={key:2,class:"dsg-dropdown__menu-header dsg-dropdown__menu-header--subsection"},E1={class:"dsg-dropdown__menu-subtitle"},A1=["href","target","tabindex","title","onClick"],C1={key:0,class:"dsg-dropdown__menu-item-content"},b1={key:0,class:"dsg-dropdown__menu-item-icon"},S1={class:"dsg-dropdown__menu-item-label"},I1={class:"dsg-dropdown__menu-item-hotkey"},O1={key:0},T1={key:1,class:"dsg-dropdown__menu-item-content"},N1=f.defineComponent({__name:"DsgDropdown",props:{label:{default:""},type:{default:"button"},icon:{default:"dots-vertical"},iconBefore:{default:()=>{}},buttonTheme:{default:"gray"},menuItems:{default:()=>[]},avatarInfo:{default:null},isOpen:{type:Boolean,default:!1},placement:{default:"bottom-end"},headerType:{default:"none"},headerTitle:{default:""},strategy:{default:"absolute"},skidding:{default:0},distance:{default:0},size:{default:"md"}},setup(t,{expose:e}){const r=f.ref(t.isOpen),n=new tt().getOS().name;t.menuItems.forEach(h=>{});const i=f.useTemplateRef("floatingVueDropdownEl"),a=f.useTemplateRef("dsgDropdownAvatarTriggerEl"),o=f.useTemplateRef("dsgDropdownButtonTriggerEl"),s=h=>{u(),a.value&&setTimeout(()=>{a?.value?.toggleFocus(r.value)},100)},c=h=>{u(),o.value&&setTimeout(()=>{o?.value?.focusButton(r.value)},100)},u=()=>{r.value=!r.value,r.value?i.value?.show():i.value?.hide()},l=(h,p)=>{p.uri||h.preventDefault(),p.action&&(p.action(),i.value?.hide())},d=f.useTemplateRef("dsgDropdown"),v=h=>(h=h.toLowerCase(),h.replace("ctrl","⌃").replace("shift","⇧").replace("alt","⌥").replace("cmd",n==="macOS"?"⌘":"⊞").replace("++","+").replace("+","").toUpperCase());return f.onMounted(()=>{t.menuItems.forEach(h=>{h.hotkey&&Xe(h.hotkey,p=>{h.hotkeyPreventDefault&&h.hotkeyPreventDefault===!0&&p.preventDefault(),h.uri&&window.open(h.uri,h.uriTarget??"_blank"),typeof h.action=="function"&&(h.action(),i.value?.hide())})})}),f.onBeforeUnmount(()=>{Xe.deleteScope("dsgDropdown")}),e({handleTriggerClick:u}),(h,p)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(["dsg-dropdown",`dsg-dropdown--${t.size}`]),ref:"dsgDropdown"},[f.createVNode(f.unref(M.kt),f.mergeProps({triggers:[],placement:t.placement,"handle-resize":!1,strategy:t.strategy,shown:r.value,flip:!1,shift:!1,boundary:d.value,container:d.value,skidding:t.skidding,distance:t.distance,class:"dsg-dropdown__popper",onHide:p[0]||(p[0]=g=>r.value=!1),ref:"floatingVueDropdownEl"},h.$attrs),{popper:f.withCtx(()=>[f.createElementVNode("div",x1,[f.renderSlot(h.$slots,"dsg-dropdown-menu--header",{},()=>[t.headerType==="avatar"?(f.openBlock(),f.createElementBlock("div",y1,[t.avatarInfo?(f.openBlock(),f.createBlock(rr,{key:0,size:"md",profileUri:t.avatarInfo.profileUri,fullName:t.avatarInfo.fullName,isOnline:t.avatarInfo.isOnline,title:t.avatarInfo.title,"sub-text":t.avatarInfo.subText},null,8,["profileUri","fullName","isOnline","title","sub-text"])):f.createCommentVNode("",!0)])):t.headerType==="title"?(f.openBlock(),f.createElementBlock("div",m1,[f.createElementVNode("h3",w1,f.toDisplayString(t.headerTitle),1)])):t.headerType==="subsection"?(f.openBlock(),f.createElementBlock("div",_1,[f.createElementVNode("h4",E1,f.toDisplayString(t.headerTitle),1)])):f.createCommentVNode("",!0)]),f.renderSlot(h.$slots,"dsg-dropdown-menu-content",{},()=>[(f.openBlock(!0),f.createElementBlock(f.Fragment,null,f.renderList(t.menuItems.filter(g=>!g.disabled),(g,y)=>(f.openBlock(),f.createElementBlock("a",{class:f.normalizeClass(["dsg-dropdown__menu-item",{"dsg-dropdown__menu-item--divider":g.type==="divider"}]),href:g.uri,target:g.uriTarget??"_blank",tabindex:!g.uri&&g.type!=="divider"?0:void 0,title:g.label,key:y,onClick:w=>l(w,g)},[g.type==="item"||g.type===void 0?(f.openBlock(),f.createElementBlock("div",C1,[g.icon?(f.openBlock(),f.createElementBlock("div",b1,[f.createVNode(M._sfc_main,{icon:g.icon,size:"xs"},null,8,["icon"])])):f.createCommentVNode("",!0),f.createElementVNode("span",S1,f.toDisplayString(g.label),1),f.createElementVNode("div",I1,[g.hotkey?(f.openBlock(),f.createElementBlock("span",O1,f.toDisplayString(v(g.hotkey)),1)):f.createCommentVNode("",!0)])])):g.type==="divider"?(f.openBlock(),f.createElementBlock("div",T1,[...p[1]||(p[1]=[f.createElementVNode("hr",null,null,-1)])])):f.createCommentVNode("",!0)],10,A1))),128))])])]),default:f.withCtx(()=>[f.createElementVNode("div",g1,[f.renderSlot(h.$slots,"dsg-dropdown--trigger",{},()=>[t.type==="avatar"?(f.openBlock(),f.createElementBlock(f.Fragment,{key:0},[t.avatarInfo?(f.openBlock(),f.createBlock(rr,{key:0,size:"lg",profileUri:t.avatarInfo.profileUri,fullName:t.avatarInfo.fullName,ref:"dsgDropdownAvatarTriggerEl",onClick:s,"prevent-default":!0},null,8,["profileUri","fullName"])):f.createCommentVNode("",!0)],64)):t.type==="button"?(f.openBlock(),f.createBlock(M._sfc_main$3,{key:1,theme:t.buttonTheme,label:t.label,onClick:c,ref:"dsgDropdownButtonTriggerEl","icon-before":t.iconBefore,size:t.size,"icon-after":"chevron-down",class:f.normalizeClass(["dsg-dropdown__trigger-button",{"dsg-dropdown__trigger-button--dropdown-active":r.value}])},null,8,["theme","label","icon-before","size","class"])):t.type==="icon"?(f.openBlock(),f.createBlock(M._sfc_main$3,{key:2,"icon-before":t.icon,size:"sm",theme:t.buttonTheme,class:f.normalizeClass(["dsg-dropdown__trigger-button",{"dsg-dropdown__trigger-button--dropdown-active":r.value}]),onClick:u},null,8,["icon-before","theme","class"])):f.createCommentVNode("",!0)])])]),_:3},16,["placement","strategy","shown","boundary","container","skidding","distance"])],2))}}),D1={key:1,class:"dsg-modal__header-text"},B1={key:0,class:"dsg-modal__header-title"},R1={key:1,class:"dsg-modal__header-description"},P1={key:1,class:"dsg-modal__body"},ra=f.defineComponent({__name:"DsgModal",props:{title:{default:""},description:{default:""},miscIcon:{default:null},hasClosedButton:{type:Boolean,default:!0},initialOpen:{type:Boolean,default:!1},closeClickBackground:{type:Boolean,default:!1},wrapperClasses:{default:""},width:{default:400},type:{default:"left"},footerType:{default:"horizontal-even"},primaryButton:{type:[Object,Boolean],default:!1},secondaryButton:{type:[Object,Boolean],default:!1},hasBackground:{type:Boolean,default:!0}},emits:["before-open","after-open","before-close","after-close","secondary-button-clicked","primary-button-clicked"],setup(t,{expose:e,emit:r}){const n=r,i=f.ref(t.initialOpen),a=()=>{n("before-open"),i.value=!0,n("after-open")},o=()=>{n("before-close"),i.value=!1,n("after-close")},s=()=>{i.value&&t.closeClickBackground&&o()},c=()=>{n("secondary-button-clicked")},u=()=>{n("primary-button-clicked")};return e({open:a,close:o,secondaryButtonClicked:c,primaryButtonClicked:u}),(l,d)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(["dsg-modal",`dsg-modal--${i.value?"open":"closed"}`])},[t.hasBackground?(f.openBlock(),f.createElementBlock("div",{key:0,class:"dsg-modal__background",onDblclick:s},null,32)):f.createCommentVNode("",!0),f.createElementVNode("div",{class:f.normalizeClass(["dsg-modal__wrapper",t.wrapperClasses]),style:f.normalizeStyle({width:`${t.width}px`})},[t.hasClosedButton?(f.openBlock(),f.createBlock(M._sfc_main$3,{key:0,theme:"gray-tertiary",iconBefore:"x",size:"lg",class:f.normalizeClass(["dsg-modal__close-button",`dsg-modal__close-button--${t.type}`]),onClick:o},null,8,["class"])):f.createCommentVNode("",!0),f.renderSlot(l.$slots,"dsg-modal__header",{},()=>[f.createElementVNode("div",{class:f.normalizeClass(["dsg-modal__header",[`dsg-modal__header--${t.type}`,`${l.$slots.default?"dsg-modal__header--with-body":""}`].join(" ")])},[t.miscIcon?(f.openBlock(),f.createBlock(It,f.normalizeProps(f.mergeProps({key:0},t.miscIcon)),null,16)):f.createCommentVNode("",!0),t.title||t.description?(f.openBlock(),f.createElementBlock("div",D1,[t.title?(f.openBlock(),f.createElementBlock("h3",B1,f.toDisplayString(t.title),1)):f.createCommentVNode("",!0),t.description?(f.openBlock(),f.createElementBlock("p",R1,f.toDisplayString(t.description),1)):f.createCommentVNode("",!0)])):f.createCommentVNode("",!0)],2)]),l.$slots.default?(f.openBlock(),f.createElementBlock("div",P1,[f.renderSlot(l.$slots,"default")])):f.createCommentVNode("",!0),f.renderSlot(l.$slots,"dsg-modal__footer",{},()=>[f.createElementVNode("div",{class:f.normalizeClass(["dsg-modal__footer",`dsg-modal__footer--${t.footerType}`])},[t.secondaryButton?(f.openBlock(),f.createBlock(M._sfc_main$3,f.mergeProps({key:0},t.secondaryButton,{onButtonClicked:c,class:"dsg-modal__secondary-button"}),null,16)):f.createCommentVNode("",!0),t.primaryButton?(f.openBlock(),f.createBlock(M._sfc_main$3,f.mergeProps({key:1},t.primaryButton,{onButtonClicked:u,class:"dsg-modal__primary-button"}),null,16)):f.createCommentVNode("",!0)],2)])],6)],2))}}),k1={class:"dsg-tag__before"},M1={class:"dsg-tag__label"},L1={class:"dsg-tag__after"},F1={key:0,class:"dsg-tag__count"},V1=f.defineComponent({__name:"DsgTag",props:{label:{default:""},size:{default:"md"},hasClose:{type:Boolean,default:!1},tagCount:{default:null},avatarUri:{default:""},hasCheckbox:{type:Boolean,default:!1},dotHex:{default:null},destroyOnClose:{type:Boolean,default:!1},value:{default:null}},emits:["before-checked","after-checked","before-hide","after-hide","before-destroy","after-destroy"],setup(t,{expose:e,emit:r}){const n=()=>`tag-${t.size}`;t.hasClose&&t.tagCount!==null&&new M.DsgPropSyntaxWarning("DsgTag: 'hasClose' and 'tagCount' props are mutually exclusive. Please use only one of them."),t.avatarUri&&t.dotHex&&new M.DsgPropSyntaxWarning("DsgTag: 'avatarUri' and 'dotHex' props are mutually exclusive. Please use only one of them.");const i=r,a=f.useTemplateRef("dsgTag"),o=p=>{t.destroyOnClose?(i("before-destroy",a.value),a.value?.remove(),i("after-destroy")):(i("before-hide",a.value),a.value&&(a.value.style.display="none"),i("after-hide",a.value))},s=(p,g)=>{i("before-checked",p,g)},c=p=>{i("after-checked",p)},u=f.ref(t.tagCount),l=p=>{u.value=p},d=f.ref(t.value);return e({setTagCount:l,setValue:p=>{d.value=p},getValue:()=>d.value}),(p,g)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(["dsg-tag",`dsg-tag--${t.size}`,`dsg-tag--${t.hasClose?"has-close":"no-close"}`,`dsg-tag--${t.tagCount?"has-count":"no-count"}`,`dsg-tag--${t.avatarUri?"has-avatar":"no-avatar"}`,`dsg-tag--${t.hasCheckbox?"has-checkbox":"no-checkbox"}`]),ref:"dsgTag"},[f.createElementVNode("div",k1,[t.hasCheckbox?(f.openBlock(),f.createBlock(M._sfc_main$2,{key:0,class:"dsg-tag__checkbox",size:n(),"no-focus":!0,onBeforeChecked:s,onAfterChecked:c},null,8,["size"])):f.createCommentVNode("",!0),t.avatarUri?(f.openBlock(),f.createBlock(rr,{key:1,"profile-uri":t.avatarUri,size:"xxs","no-focus":!0,class:"dsg-tag__avatar"},null,8,["profile-uri"])):f.createCommentVNode("",!0),t.dotHex?(f.openBlock(),f.createElementBlock("span",{key:2,class:"dsg-tag__dot",style:f.normalizeStyle({backgroundColor:t.dotHex})},null,4)):f.createCommentVNode("",!0)]),f.renderSlot(p.$slots,"dsg-tag--label",{},()=>[f.createElementVNode("span",M1,f.toDisplayString(t.label),1)]),f.createElementVNode("div",L1,[u.value&&u.value>0?(f.openBlock(),f.createElementBlock("div",F1,f.toDisplayString(u.value),1)):f.createCommentVNode("",!0),t.hasClose?(f.openBlock(),f.createBlock(M._sfc_main,{key:1,icon:"x-close",class:"dsg-tag__close-icon",onClick:o})):f.createCommentVNode("",!0)])],2))}}),U1={class:"dsg-toggle__element"},H1=["checked","disabled"],$1={key:0,class:"dsg-toggle__label-wrapper"},G1=["innerHTML"],z1=["innerHTML"],W1=f.defineComponent({__name:"DsgToggle",props:{modelValue:{type:Boolean,default:!1},size:{default:"md"},label:{default:""},subText:{default:""},disabled:{type:Boolean,default:!1}},emits:["before-toggle","after-toggle","update:modelValue"],setup(t,{expose:e,emit:r}){const n=f.ref(t.modelValue),i=()=>{t.disabled||(s("before-toggle",n.value,!n.value),n.value=!n.value,s("after-toggle",n.value),s("update:modelValue",n.value))},a=f.useTemplateRef("toggleCheckbox"),o=()=>{a.value&&a.value.focus(),t.disabled||i()},s=r;return e({set:u=>{n.value=u}}),(u,l)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(`
22
22
  dsg-toggle
23
23
  dsg-toggle--${t.size}
24
24
  dsg-toggle--${t.disabled?"disabled":"enabled"}
25
25
  dsg-toggle--${t.label.length?"has-label":"no-label"}
26
26
  dsg-toggle--${t.subText.length?"has-subtext":"no-subtext"}
27
- `),onClick:o},[f.createElementVNode("label",U1,[f.createElementVNode("input",{type:"checkbox",class:"dsg-toggle__checkbox",checked:n.value,onChange:i,title:"checkbox",ref:"toggleCheckbox",disabled:t.disabled},null,40,H1),l[0]||(l[0]=f.createElementVNode("span",{class:"dsg-toggle__slider"},null,-1))]),t.label.length?(f.openBlock(),f.createElementBlock("div",$1,[f.renderSlot(u.$slots,"dsg-toggle--label",{},()=>[f.createElementVNode("h3",{class:"dsg-toggle__label",innerHTML:t.label},null,8,G1)]),t.label.length&&t.subText.length?f.renderSlot(u.$slots,"dsg-toggle--subtext",{key:0},()=>[f.createElementVNode("p",{class:"dsg-toggle__subtext",innerHTML:t.subText},null,8,z1)]):f.createCommentVNode("",!0)])):f.createCommentVNode("",!0)],2))}}),X1={class:"dsg-progress"},j1={class:"dsg-progress__inner"},Y1={key:0,class:"dsg-progress__text"},K1={key:0},Z1={key:1},q1={key:2},Q1=f.defineComponent({__name:"DsgProgress",props:{value:{},max:{},showText:{},textSuffix:{}},setup(t){const e=t,r=f.computed(()=>{const n=e.value/e.max*100;return isNaN(n)?0:Math.min(Math.max(n,0),100)});return(n,i)=>(f.openBlock(),f.createElementBlock("div",X1,[f.createElementVNode("div",j1,[f.createElementVNode("div",{class:"dsg-progress__inner-progress",style:f.normalizeStyle({width:r.value+"%"})},null,4)]),t.showText!=="none"?(f.openBlock(),f.createElementBlock("div",Y1,[t.showText==="number"?(f.openBlock(),f.createElementBlock("span",K1,f.toDisplayString(t.value)+"/"+f.toDisplayString(t.max),1)):t.showText==="percentage"?(f.openBlock(),f.createElementBlock("span",Z1,f.toDisplayString(r.value.toFixed(2))+"%",1)):f.createCommentVNode("",!0),t.textSuffix?(f.openBlock(),f.createElementBlock("span",q1," "+f.toDisplayString(t.textSuffix),1)):f.createCommentVNode("",!0)])):f.createCommentVNode("",!0)]))}});function J1(t,e){var r=Object.setPrototypeOf;r?r(t,e):t.__proto__=e}function ec(t,e){e===void 0&&(e=t.constructor);var r=Error.captureStackTrace;r&&r(t,e)}var tc=(function(){var t=function(r,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,a){i.__proto__=a}||function(i,a){for(var o in a)Object.prototype.hasOwnProperty.call(a,o)&&(i[o]=a[o])},t(r,n)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),rc=(function(t){tc(e,t);function e(r,n){var i=this.constructor,a=t.call(this,r,n)||this;return Object.defineProperty(a,"name",{value:i.name,enumerable:!1,configurable:!0}),J1(a,i.prototype),ec(a),a}return e})(Error),nc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),Ie=(function(t){nc(e,t);function e(r){r===void 0&&(r=void 0);var n=t.call(this,r)||this;return n.message=r,n}return e.prototype.getKind=function(){var r=this.constructor;return r.kind},e.kind="Exception",e})(rc),ic=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),Ue=(function(t){ic(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.kind="ArgumentException",e})(Ie),ac=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),L=(function(t){ac(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.kind="IllegalArgumentException",e})(Ie),oc=(function(){function t(e){if(this.binarizer=e,e===null)throw new L("Binarizer must be non-null.")}return t.prototype.getWidth=function(){return this.binarizer.getWidth()},t.prototype.getHeight=function(){return this.binarizer.getHeight()},t.prototype.getBlackRow=function(e,r){return this.binarizer.getBlackRow(e,r)},t.prototype.getBlackMatrix=function(){return(this.matrix===null||this.matrix===void 0)&&(this.matrix=this.binarizer.getBlackMatrix()),this.matrix},t.prototype.isCropSupported=function(){return this.binarizer.getLuminanceSource().isCropSupported()},t.prototype.crop=function(e,r,n,i){var a=this.binarizer.getLuminanceSource().crop(e,r,n,i);return new t(this.binarizer.createBinarizer(a))},t.prototype.isRotateSupported=function(){return this.binarizer.getLuminanceSource().isRotateSupported()},t.prototype.rotateCounterClockwise=function(){var e=this.binarizer.getLuminanceSource().rotateCounterClockwise();return new t(this.binarizer.createBinarizer(e))},t.prototype.rotateCounterClockwise45=function(){var e=this.binarizer.getLuminanceSource().rotateCounterClockwise45();return new t(this.binarizer.createBinarizer(e))},t.prototype.toString=function(){try{return this.getBlackMatrix().toString()}catch{return""}},t})(),sc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),me=(function(t){sc(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.getChecksumInstance=function(){return new e},e.kind="ChecksumException",e})(Ie),cc=(function(){function t(e){this.source=e}return t.prototype.getLuminanceSource=function(){return this.source},t.prototype.getWidth=function(){return this.source.getWidth()},t.prototype.getHeight=function(){return this.source.getHeight()},t})(),re=(function(){function t(){}return t.arraycopy=function(e,r,n,i,a){for(;a--;)n[i++]=e[r++]},t.currentTimeMillis=function(){return Date.now()},t})(),uc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),Un=(function(t){uc(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.kind="IndexOutOfBoundsException",e})(Ie),fc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),fi=(function(t){fc(e,t);function e(r,n){r===void 0&&(r=void 0),n===void 0&&(n=void 0);var i=t.call(this,n)||this;return i.index=r,i.message=n,i}return e.kind="ArrayIndexOutOfBoundsException",e})(Un),lc=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],n=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Be=(function(){function t(){}return t.fill=function(e,r){for(var n=0,i=e.length;n<i;n++)e[n]=r},t.fillWithin=function(e,r,n,i){t.rangeCheck(e.length,r,n);for(var a=r;a<n;a++)e[a]=i},t.rangeCheck=function(e,r,n){if(r>n)throw new L("fromIndex("+r+") > toIndex("+n+")");if(r<0)throw new fi(r);if(n>e)throw new fi(n)},t.asList=function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];return e},t.create=function(e,r,n){var i=Array.from({length:e});return i.map(function(a){return Array.from({length:r}).fill(n)})},t.createInt32Array=function(e,r,n){var i=Array.from({length:e});return i.map(function(a){return Int32Array.from({length:r}).fill(n)})},t.equals=function(e,r){if(!e||!r||!e.length||!r.length||e.length!==r.length)return!1;for(var n=0,i=e.length;n<i;n++)if(e[n]!==r[n])return!1;return!0},t.hashCode=function(e){var r,n;if(e===null)return 0;var i=1;try{for(var a=lc(e),o=a.next();!o.done;o=a.next()){var s=o.value;i=31*i+s}}catch(c){r={error:c}}finally{try{o&&!o.done&&(n=a.return)&&n.call(a)}finally{if(r)throw r.error}}return i},t.fillUint8Array=function(e,r){for(var n=0;n!==e.length;n++)e[n]=r},t.copyOf=function(e,r){return e.slice(0,r)},t.copyOfUint8Array=function(e,r){if(e.length<=r){var n=new Uint8Array(r);return n.set(e),n}return e.slice(0,r)},t.copyOfRange=function(e,r,n){var i=n-r,a=new Int32Array(i);return re.arraycopy(e,r,a,0,i),a},t.binarySearch=function(e,r,n){n===void 0&&(n=t.numberComparator);for(var i=0,a=e.length-1;i<=a;){var o=a+i>>1,s=n(r,e[o]);if(s>0)i=o+1;else if(s<0)a=o-1;else return o}return-i-1},t.numberComparator=function(e,r){return e-r},t})(),G=(function(){function t(){}return t.numberOfTrailingZeros=function(e){var r;if(e===0)return 32;var n=31;return r=e<<16,r!==0&&(n-=16,e=r),r=e<<8,r!==0&&(n-=8,e=r),r=e<<4,r!==0&&(n-=4,e=r),r=e<<2,r!==0&&(n-=2,e=r),n-(e<<1>>>31)},t.numberOfLeadingZeros=function(e){if(e===0)return 32;var r=1;return e>>>16||(r+=16,e<<=16),e>>>24||(r+=8,e<<=8),e>>>28||(r+=4,e<<=4),e>>>30||(r+=2,e<<=2),r-=e>>>31,r},t.toHexString=function(e){return e.toString(16)},t.toBinaryString=function(e){return String(parseInt(String(e),2))},t.bitCount=function(e){return e=e-(e>>>1&1431655765),e=(e&858993459)+(e>>>2&858993459),e=e+(e>>>4)&252645135,e=e+(e>>>8),e=e+(e>>>16),e&63},t.truncDivision=function(e,r){return Math.trunc(e/r)},t.parseInt=function(e,r){return r===void 0&&(r=void 0),parseInt(e,r)},t.MIN_VALUE_32_BITS=-2147483648,t.MAX_VALUE=Number.MAX_SAFE_INTEGER,t})(),ge=(function(){function t(e,r){e===void 0?(this.size=0,this.bits=new Int32Array(1)):(this.size=e,r==null?this.bits=t.makeArray(e):this.bits=r)}return t.prototype.getSize=function(){return this.size},t.prototype.getSizeInBytes=function(){return Math.floor((this.size+7)/8)},t.prototype.ensureCapacity=function(e){if(e>this.bits.length*32){var r=t.makeArray(e);re.arraycopy(this.bits,0,r,0,this.bits.length),this.bits=r}},t.prototype.get=function(e){return(this.bits[Math.floor(e/32)]&1<<(e&31))!==0},t.prototype.set=function(e){this.bits[Math.floor(e/32)]|=1<<(e&31)},t.prototype.flip=function(e){this.bits[Math.floor(e/32)]^=1<<(e&31)},t.prototype.getNextSet=function(e){var r=this.size;if(e>=r)return r;var n=this.bits,i=Math.floor(e/32),a=n[i];a&=~((1<<(e&31))-1);for(var o=n.length;a===0;){if(++i===o)return r;a=n[i]}var s=i*32+G.numberOfTrailingZeros(a);return s>r?r:s},t.prototype.getNextUnset=function(e){var r=this.size;if(e>=r)return r;var n=this.bits,i=Math.floor(e/32),a=~n[i];a&=~((1<<(e&31))-1);for(var o=n.length;a===0;){if(++i===o)return r;a=~n[i]}var s=i*32+G.numberOfTrailingZeros(a);return s>r?r:s},t.prototype.setBulk=function(e,r){this.bits[Math.floor(e/32)]=r},t.prototype.setRange=function(e,r){if(r<e||e<0||r>this.size)throw new L;if(r!==e){r--;for(var n=Math.floor(e/32),i=Math.floor(r/32),a=this.bits,o=n;o<=i;o++){var s=o>n?0:e&31,c=o<i?31:r&31,u=(2<<c)-(1<<s);a[o]|=u}}},t.prototype.clear=function(){for(var e=this.bits.length,r=this.bits,n=0;n<e;n++)r[n]=0},t.prototype.isRange=function(e,r,n){if(r<e||e<0||r>this.size)throw new L;if(r===e)return!0;r--;for(var i=Math.floor(e/32),a=Math.floor(r/32),o=this.bits,s=i;s<=a;s++){var c=s>i?0:e&31,u=s<a?31:r&31,l=(2<<u)-(1<<c)&4294967295;if((o[s]&l)!==(n?l:0))return!1}return!0},t.prototype.appendBit=function(e){this.ensureCapacity(this.size+1),e&&(this.bits[Math.floor(this.size/32)]|=1<<(this.size&31)),this.size++},t.prototype.appendBits=function(e,r){if(r<0||r>32)throw new L("Num bits must be between 0 and 32");this.ensureCapacity(this.size+r);for(var n=r;n>0;n--)this.appendBit((e>>n-1&1)===1)},t.prototype.appendBitArray=function(e){var r=e.size;this.ensureCapacity(this.size+r);for(var n=0;n<r;n++)this.appendBit(e.get(n))},t.prototype.xor=function(e){if(this.size!==e.size)throw new L("Sizes don't match");for(var r=this.bits,n=0,i=r.length;n<i;n++)r[n]^=e.bits[n]},t.prototype.toBytes=function(e,r,n,i){for(var a=0;a<i;a++){for(var o=0,s=0;s<8;s++)this.get(e)&&(o|=1<<7-s),e++;r[n+a]=o}},t.prototype.getBitArray=function(){return this.bits},t.prototype.reverse=function(){for(var e=new Int32Array(this.bits.length),r=Math.floor((this.size-1)/32),n=r+1,i=this.bits,a=0;a<n;a++){var o=i[a];o=o>>1&1431655765|(o&1431655765)<<1,o=o>>2&858993459|(o&858993459)<<2,o=o>>4&252645135|(o&252645135)<<4,o=o>>8&16711935|(o&16711935)<<8,o=o>>16&65535|(o&65535)<<16,e[r-a]=o}if(this.size!==n*32){for(var s=n*32-this.size,c=e[0]>>>s,a=1;a<n;a++){var u=e[a];c|=u<<32-s,e[a-1]=c,c=u>>>s}e[n-1]=c}this.bits=e},t.makeArray=function(e){return new Int32Array(Math.floor((e+31)/32))},t.prototype.equals=function(e){if(!(e instanceof t))return!1;var r=e;return this.size===r.size&&Be.equals(this.bits,r.bits)},t.prototype.hashCode=function(){return 31*this.size+Be.hashCode(this.bits)},t.prototype.toString=function(){for(var e="",r=0,n=this.size;r<n;r++)(r&7)===0&&(e+=" "),e+=this.get(r)?"X":".";return e},t.prototype.clone=function(){return new t(this.size,this.bits.slice())},t})(),En;(function(t){t[t.OTHER=0]="OTHER",t[t.PURE_BARCODE=1]="PURE_BARCODE",t[t.POSSIBLE_FORMATS=2]="POSSIBLE_FORMATS",t[t.TRY_HARDER=3]="TRY_HARDER",t[t.CHARACTER_SET=4]="CHARACTER_SET",t[t.ALLOWED_LENGTHS=5]="ALLOWED_LENGTHS",t[t.ASSUME_CODE_39_CHECK_DIGIT=6]="ASSUME_CODE_39_CHECK_DIGIT",t[t.ASSUME_GS1=7]="ASSUME_GS1",t[t.RETURN_CODABAR_START_END=8]="RETURN_CODABAR_START_END",t[t.NEED_RESULT_POINT_CALLBACK=9]="NEED_RESULT_POINT_CALLBACK",t[t.ALLOWED_EAN_EXTENSIONS=10]="ALLOWED_EAN_EXTENSIONS"})(En||(En={}));const ce=En;var dc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),R=(function(t){dc(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.getFormatInstance=function(){return new e},e.kind="FormatException",e})(Ie),hc=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],n=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},q;(function(t){t[t.Cp437=0]="Cp437",t[t.ISO8859_1=1]="ISO8859_1",t[t.ISO8859_2=2]="ISO8859_2",t[t.ISO8859_3=3]="ISO8859_3",t[t.ISO8859_4=4]="ISO8859_4",t[t.ISO8859_5=5]="ISO8859_5",t[t.ISO8859_6=6]="ISO8859_6",t[t.ISO8859_7=7]="ISO8859_7",t[t.ISO8859_8=8]="ISO8859_8",t[t.ISO8859_9=9]="ISO8859_9",t[t.ISO8859_10=10]="ISO8859_10",t[t.ISO8859_11=11]="ISO8859_11",t[t.ISO8859_13=12]="ISO8859_13",t[t.ISO8859_14=13]="ISO8859_14",t[t.ISO8859_15=14]="ISO8859_15",t[t.ISO8859_16=15]="ISO8859_16",t[t.SJIS=16]="SJIS",t[t.Cp1250=17]="Cp1250",t[t.Cp1251=18]="Cp1251",t[t.Cp1252=19]="Cp1252",t[t.Cp1256=20]="Cp1256",t[t.UnicodeBigUnmarked=21]="UnicodeBigUnmarked",t[t.UTF8=22]="UTF8",t[t.ASCII=23]="ASCII",t[t.Big5=24]="Big5",t[t.GB18030=25]="GB18030",t[t.EUC_KR=26]="EUC_KR"})(q||(q={}));var he=(function(){function t(e,r,n){for(var i,a,o=[],s=3;s<arguments.length;s++)o[s-3]=arguments[s];this.valueIdentifier=e,this.name=n,typeof r=="number"?this.values=Int32Array.from([r]):this.values=r,this.otherEncodingNames=o,t.VALUE_IDENTIFIER_TO_ECI.set(e,this),t.NAME_TO_ECI.set(n,this);for(var c=this.values,u=0,l=c.length;u!==l;u++){var d=c[u];t.VALUES_TO_ECI.set(d,this)}try{for(var v=hc(o),h=v.next();!h.done;h=v.next()){var p=h.value;t.NAME_TO_ECI.set(p,this)}}catch(g){i={error:g}}finally{try{h&&!h.done&&(a=v.return)&&a.call(v)}finally{if(i)throw i.error}}}return t.prototype.getValueIdentifier=function(){return this.valueIdentifier},t.prototype.getName=function(){return this.name},t.prototype.getValue=function(){return this.values[0]},t.getCharacterSetECIByValue=function(e){if(e<0||e>=900)throw new R("incorect value");var r=t.VALUES_TO_ECI.get(e);if(r===void 0)throw new R("incorect value");return r},t.getCharacterSetECIByName=function(e){var r=t.NAME_TO_ECI.get(e);if(r===void 0)throw new R("incorect value");return r},t.prototype.equals=function(e){if(!(e instanceof t))return!1;var r=e;return this.getName()===r.getName()},t.VALUE_IDENTIFIER_TO_ECI=new Map,t.VALUES_TO_ECI=new Map,t.NAME_TO_ECI=new Map,t.Cp437=new t(q.Cp437,Int32Array.from([0,2]),"Cp437"),t.ISO8859_1=new t(q.ISO8859_1,Int32Array.from([1,3]),"ISO-8859-1","ISO88591","ISO8859_1"),t.ISO8859_2=new t(q.ISO8859_2,4,"ISO-8859-2","ISO88592","ISO8859_2"),t.ISO8859_3=new t(q.ISO8859_3,5,"ISO-8859-3","ISO88593","ISO8859_3"),t.ISO8859_4=new t(q.ISO8859_4,6,"ISO-8859-4","ISO88594","ISO8859_4"),t.ISO8859_5=new t(q.ISO8859_5,7,"ISO-8859-5","ISO88595","ISO8859_5"),t.ISO8859_6=new t(q.ISO8859_6,8,"ISO-8859-6","ISO88596","ISO8859_6"),t.ISO8859_7=new t(q.ISO8859_7,9,"ISO-8859-7","ISO88597","ISO8859_7"),t.ISO8859_8=new t(q.ISO8859_8,10,"ISO-8859-8","ISO88598","ISO8859_8"),t.ISO8859_9=new t(q.ISO8859_9,11,"ISO-8859-9","ISO88599","ISO8859_9"),t.ISO8859_10=new t(q.ISO8859_10,12,"ISO-8859-10","ISO885910","ISO8859_10"),t.ISO8859_11=new t(q.ISO8859_11,13,"ISO-8859-11","ISO885911","ISO8859_11"),t.ISO8859_13=new t(q.ISO8859_13,15,"ISO-8859-13","ISO885913","ISO8859_13"),t.ISO8859_14=new t(q.ISO8859_14,16,"ISO-8859-14","ISO885914","ISO8859_14"),t.ISO8859_15=new t(q.ISO8859_15,17,"ISO-8859-15","ISO885915","ISO8859_15"),t.ISO8859_16=new t(q.ISO8859_16,18,"ISO-8859-16","ISO885916","ISO8859_16"),t.SJIS=new t(q.SJIS,20,"SJIS","Shift_JIS"),t.Cp1250=new t(q.Cp1250,21,"Cp1250","windows-1250"),t.Cp1251=new t(q.Cp1251,22,"Cp1251","windows-1251"),t.Cp1252=new t(q.Cp1252,23,"Cp1252","windows-1252"),t.Cp1256=new t(q.Cp1256,24,"Cp1256","windows-1256"),t.UnicodeBigUnmarked=new t(q.UnicodeBigUnmarked,25,"UnicodeBigUnmarked","UTF-16BE","UnicodeBig"),t.UTF8=new t(q.UTF8,26,"UTF8","UTF-8"),t.ASCII=new t(q.ASCII,Int32Array.from([27,170]),"ASCII","US-ASCII"),t.Big5=new t(q.Big5,28,"Big5"),t.GB18030=new t(q.GB18030,29,"GB18030","GB2312","EUC_CN","GBK"),t.EUC_KR=new t(q.EUC_KR,30,"EUC_KR","EUC-KR"),t})(),vc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),Or=(function(t){vc(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.kind="UnsupportedOperationException",e})(Ie),Ke=(function(){function t(){}return t.decode=function(e,r){var n=this.encodingName(r);return this.customDecoder?this.customDecoder(e,n):typeof TextDecoder>"u"||this.shouldDecodeOnFallback(n)?this.decodeFallback(e,n):new TextDecoder(n).decode(e)},t.shouldDecodeOnFallback=function(e){return!t.isBrowser()&&e==="ISO-8859-1"},t.encode=function(e,r){var n=this.encodingName(r);return this.customEncoder?this.customEncoder(e,n):typeof TextEncoder>"u"?this.encodeFallback(e):new TextEncoder().encode(e)},t.isBrowser=function(){return typeof window<"u"&&{}.toString.call(window)==="[object Window]"},t.encodingName=function(e){return typeof e=="string"?e:e.getName()},t.encodingCharacterSet=function(e){return e instanceof he?e:he.getCharacterSetECIByName(e)},t.decodeFallback=function(e,r){var n=this.encodingCharacterSet(r);if(t.isDecodeFallbackSupported(n)){for(var i="",a=0,o=e.length;a<o;a++){var s=e[a].toString(16);s.length<2&&(s="0"+s),i+="%"+s}return decodeURIComponent(i)}if(n.equals(he.UnicodeBigUnmarked))return String.fromCharCode.apply(null,new Uint16Array(e.buffer));throw new Or("Encoding "+this.encodingName(r)+" not supported by fallback.")},t.isDecodeFallbackSupported=function(e){return e.equals(he.UTF8)||e.equals(he.ISO8859_1)||e.equals(he.ASCII)},t.encodeFallback=function(e){for(var r=btoa(unescape(encodeURIComponent(e))),n=r.split(""),i=[],a=0;a<n.length;a++)i.push(n[a].charCodeAt(0));return new Uint8Array(i)},t})(),te=(function(){function t(){}return t.castAsNonUtf8Char=function(e,r){r===void 0&&(r=null);var n=r?r.getName():this.ISO88591;return Ke.decode(new Uint8Array([e]),n)},t.guessEncoding=function(e,r){if(r!=null&&r.get(ce.CHARACTER_SET)!==void 0)return r.get(ce.CHARACTER_SET).toString();for(var n=e.length,i=!0,a=!0,o=!0,s=0,c=0,u=0,l=0,d=0,v=0,h=0,p=0,g=0,y=0,w=0,m=e.length>3&&e[0]===239&&e[1]===187&&e[2]===191,_=0;_<n&&(i||a||o);_++){var A=e[_]&255;o&&(s>0?(A&128)===0?o=!1:s--:(A&128)!==0&&((A&64)===0?o=!1:(s++,(A&32)===0?c++:(s++,(A&16)===0?u++:(s++,(A&8)===0?l++:o=!1))))),i&&(A>127&&A<160?i=!1:A>159&&(A<192||A===215||A===247)&&w++),a&&(d>0?A<64||A===127||A>252?a=!1:d--:A===128||A===160||A>239?a=!1:A>160&&A<224?(v++,p=0,h++,h>g&&(g=h)):A>127?(d++,h=0,p++,p>y&&(y=p)):(h=0,p=0))}return o&&s>0&&(o=!1),a&&d>0&&(a=!1),o&&(m||c+u+l>0)?t.UTF8:a&&(t.ASSUME_SHIFT_JIS||g>=3||y>=3)?t.SHIFT_JIS:i&&a?g===2&&v===2||w*10>=n?t.SHIFT_JIS:t.ISO88591:i?t.ISO88591:a?t.SHIFT_JIS:o?t.UTF8:t.PLATFORM_DEFAULT_ENCODING},t.format=function(e){for(var r=[],n=1;n<arguments.length;n++)r[n-1]=arguments[n];var i=-1;function a(s,c,u,l,d,v){if(s==="%%")return"%";if(r[++i]!==void 0){s=l?parseInt(l.substr(1)):void 0;var h=d?parseInt(d.substr(1)):void 0,p;switch(v){case"s":p=r[i];break;case"c":p=r[i][0];break;case"f":p=parseFloat(r[i]).toFixed(s);break;case"p":p=parseFloat(r[i]).toPrecision(s);break;case"e":p=parseFloat(r[i]).toExponential(s);break;case"x":p=parseInt(r[i]).toString(h||16);break;case"d":p=parseFloat(parseInt(r[i],h||10).toPrecision(s)).toFixed(0);break}p=typeof p=="object"?JSON.stringify(p):(+p).toString(h);for(var g=parseInt(u),y=u&&u[0]+""=="0"?"0":" ";p.length<g;)p=c!==void 0?p+y:y+p;return p}}var o=/%(-)?(0?[0-9]+)?([.][0-9]+)?([#][0-9]+)?([scfpexd%])/g;return e.replace(o,a)},t.getBytes=function(e,r){return Ke.encode(e,r)},t.getCharCode=function(e,r){return r===void 0&&(r=0),e.charCodeAt(r)},t.getCharAt=function(e){return String.fromCharCode(e)},t.SHIFT_JIS=he.SJIS.getName(),t.GB2312="GB2312",t.ISO88591=he.ISO8859_1.getName(),t.EUC_JP="EUC_JP",t.UTF8=he.UTF8.getName(),t.PLATFORM_DEFAULT_ENCODING=t.UTF8,t.ASSUME_SHIFT_JIS=!1,t})(),J=(function(){function t(e){e===void 0&&(e=""),this.value=e}return t.prototype.enableDecoding=function(e){return this.encoding=e,this},t.prototype.append=function(e){return typeof e=="string"?this.value+=e.toString():this.encoding?this.value+=te.castAsNonUtf8Char(e,this.encoding):this.value+=String.fromCharCode(e),this},t.prototype.appendChars=function(e,r,n){for(var i=r;r<r+n;i++)this.append(e[i]);return this},t.prototype.length=function(){return this.value.length},t.prototype.charAt=function(e){return this.value.charAt(e)},t.prototype.deleteCharAt=function(e){this.value=this.value.substr(0,e)+this.value.substring(e+1)},t.prototype.setCharAt=function(e,r){this.value=this.value.substr(0,e)+r+this.value.substr(e+1)},t.prototype.substring=function(e,r){return this.value.substring(e,r)},t.prototype.setLengthToZero=function(){this.value=""},t.prototype.toString=function(){return this.value},t.prototype.insert=function(e,r){this.value=this.value.substr(0,e)+r+this.value.substr(e+r.length)},t})(),Ze=(function(){function t(e,r,n,i){if(this.width=e,this.height=r,this.rowSize=n,this.bits=i,r==null&&(r=e),this.height=r,e<1||r<1)throw new L("Both dimensions must be greater than 0");n==null&&(n=Math.floor((e+31)/32)),this.rowSize=n,i==null&&(this.bits=new Int32Array(this.rowSize*this.height))}return t.parseFromBooleanArray=function(e){for(var r=e.length,n=e[0].length,i=new t(n,r),a=0;a<r;a++)for(var o=e[a],s=0;s<n;s++)o[s]&&i.set(s,a);return i},t.parseFromString=function(e,r,n){if(e===null)throw new L("stringRepresentation cannot be null");for(var i=new Array(e.length),a=0,o=0,s=-1,c=0,u=0;u<e.length;)if(e.charAt(u)===`
27
+ `),onClick:o},[f.createElementVNode("label",U1,[f.createElementVNode("input",{type:"checkbox",class:"dsg-toggle__checkbox",checked:n.value,onChange:i,title:"checkbox",ref:"toggleCheckbox",disabled:t.disabled},null,40,H1),l[0]||(l[0]=f.createElementVNode("span",{class:"dsg-toggle__slider"},null,-1))]),t.label.length?(f.openBlock(),f.createElementBlock("div",$1,[f.renderSlot(u.$slots,"dsg-toggle--label",{},()=>[f.createElementVNode("h3",{class:"dsg-toggle__label",innerHTML:t.label},null,8,G1)]),t.label.length&&t.subText.length?f.renderSlot(u.$slots,"dsg-toggle--subtext",{},()=>[f.createElementVNode("p",{class:"dsg-toggle__subtext",innerHTML:t.subText},null,8,z1)],void 0,0):f.createCommentVNode("",!0)])):f.createCommentVNode("",!0)],2))}}),X1={class:"dsg-progress"},j1={class:"dsg-progress__inner"},Y1={key:0,class:"dsg-progress__text"},K1={key:0},Z1={key:1},q1={key:2},Q1=f.defineComponent({__name:"DsgProgress",props:{value:{},max:{},showText:{},textSuffix:{}},setup(t){const e=t,r=f.computed(()=>{const n=e.value/e.max*100;return isNaN(n)?0:Math.min(Math.max(n,0),100)});return(n,i)=>(f.openBlock(),f.createElementBlock("div",X1,[f.createElementVNode("div",j1,[f.createElementVNode("div",{class:"dsg-progress__inner-progress",style:f.normalizeStyle({width:r.value+"%"})},null,4)]),t.showText!=="none"?(f.openBlock(),f.createElementBlock("div",Y1,[t.showText==="number"?(f.openBlock(),f.createElementBlock("span",K1,f.toDisplayString(t.value)+"/"+f.toDisplayString(t.max),1)):t.showText==="percentage"?(f.openBlock(),f.createElementBlock("span",Z1,f.toDisplayString(r.value.toFixed(2))+"%",1)):f.createCommentVNode("",!0),t.textSuffix?(f.openBlock(),f.createElementBlock("span",q1," "+f.toDisplayString(t.textSuffix),1)):f.createCommentVNode("",!0)])):f.createCommentVNode("",!0)]))}});function J1(t,e){var r=Object.setPrototypeOf;r?r(t,e):t.__proto__=e}function ec(t,e){e===void 0&&(e=t.constructor);var r=Error.captureStackTrace;r&&r(t,e)}var tc=(function(){var t=function(r,n){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(i,a){i.__proto__=a}||function(i,a){for(var o in a)Object.prototype.hasOwnProperty.call(a,o)&&(i[o]=a[o])},t(r,n)};return function(e,r){if(typeof r!="function"&&r!==null)throw new TypeError("Class extends value "+String(r)+" is not a constructor or null");t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),rc=(function(t){tc(e,t);function e(r,n){var i=this.constructor,a=t.call(this,r,n)||this;return Object.defineProperty(a,"name",{value:i.name,enumerable:!1,configurable:!0}),J1(a,i.prototype),ec(a),a}return e})(Error),nc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),Ie=(function(t){nc(e,t);function e(r){r===void 0&&(r=void 0);var n=t.call(this,r)||this;return n.message=r,n}return e.prototype.getKind=function(){var r=this.constructor;return r.kind},e.kind="Exception",e})(rc),ic=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),Ue=(function(t){ic(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.kind="ArgumentException",e})(Ie),ac=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),L=(function(t){ac(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.kind="IllegalArgumentException",e})(Ie),oc=(function(){function t(e){if(this.binarizer=e,e===null)throw new L("Binarizer must be non-null.")}return t.prototype.getWidth=function(){return this.binarizer.getWidth()},t.prototype.getHeight=function(){return this.binarizer.getHeight()},t.prototype.getBlackRow=function(e,r){return this.binarizer.getBlackRow(e,r)},t.prototype.getBlackMatrix=function(){return(this.matrix===null||this.matrix===void 0)&&(this.matrix=this.binarizer.getBlackMatrix()),this.matrix},t.prototype.isCropSupported=function(){return this.binarizer.getLuminanceSource().isCropSupported()},t.prototype.crop=function(e,r,n,i){var a=this.binarizer.getLuminanceSource().crop(e,r,n,i);return new t(this.binarizer.createBinarizer(a))},t.prototype.isRotateSupported=function(){return this.binarizer.getLuminanceSource().isRotateSupported()},t.prototype.rotateCounterClockwise=function(){var e=this.binarizer.getLuminanceSource().rotateCounterClockwise();return new t(this.binarizer.createBinarizer(e))},t.prototype.rotateCounterClockwise45=function(){var e=this.binarizer.getLuminanceSource().rotateCounterClockwise45();return new t(this.binarizer.createBinarizer(e))},t.prototype.toString=function(){try{return this.getBlackMatrix().toString()}catch{return""}},t})(),sc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),me=(function(t){sc(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.getChecksumInstance=function(){return new e},e.kind="ChecksumException",e})(Ie),cc=(function(){function t(e){this.source=e}return t.prototype.getLuminanceSource=function(){return this.source},t.prototype.getWidth=function(){return this.source.getWidth()},t.prototype.getHeight=function(){return this.source.getHeight()},t})(),re=(function(){function t(){}return t.arraycopy=function(e,r,n,i,a){for(;a--;)n[i++]=e[r++]},t.currentTimeMillis=function(){return Date.now()},t})(),uc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),Un=(function(t){uc(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.kind="IndexOutOfBoundsException",e})(Ie),fc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),fi=(function(t){fc(e,t);function e(r,n){r===void 0&&(r=void 0),n===void 0&&(n=void 0);var i=t.call(this,n)||this;return i.index=r,i.message=n,i}return e.kind="ArrayIndexOutOfBoundsException",e})(Un),lc=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],n=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Be=(function(){function t(){}return t.fill=function(e,r){for(var n=0,i=e.length;n<i;n++)e[n]=r},t.fillWithin=function(e,r,n,i){t.rangeCheck(e.length,r,n);for(var a=r;a<n;a++)e[a]=i},t.rangeCheck=function(e,r,n){if(r>n)throw new L("fromIndex("+r+") > toIndex("+n+")");if(r<0)throw new fi(r);if(n>e)throw new fi(n)},t.asList=function(){for(var e=[],r=0;r<arguments.length;r++)e[r]=arguments[r];return e},t.create=function(e,r,n){var i=Array.from({length:e});return i.map(function(a){return Array.from({length:r}).fill(n)})},t.createInt32Array=function(e,r,n){var i=Array.from({length:e});return i.map(function(a){return Int32Array.from({length:r}).fill(n)})},t.equals=function(e,r){if(!e||!r||!e.length||!r.length||e.length!==r.length)return!1;for(var n=0,i=e.length;n<i;n++)if(e[n]!==r[n])return!1;return!0},t.hashCode=function(e){var r,n;if(e===null)return 0;var i=1;try{for(var a=lc(e),o=a.next();!o.done;o=a.next()){var s=o.value;i=31*i+s}}catch(c){r={error:c}}finally{try{o&&!o.done&&(n=a.return)&&n.call(a)}finally{if(r)throw r.error}}return i},t.fillUint8Array=function(e,r){for(var n=0;n!==e.length;n++)e[n]=r},t.copyOf=function(e,r){return e.slice(0,r)},t.copyOfUint8Array=function(e,r){if(e.length<=r){var n=new Uint8Array(r);return n.set(e),n}return e.slice(0,r)},t.copyOfRange=function(e,r,n){var i=n-r,a=new Int32Array(i);return re.arraycopy(e,r,a,0,i),a},t.binarySearch=function(e,r,n){n===void 0&&(n=t.numberComparator);for(var i=0,a=e.length-1;i<=a;){var o=a+i>>1,s=n(r,e[o]);if(s>0)i=o+1;else if(s<0)a=o-1;else return o}return-i-1},t.numberComparator=function(e,r){return e-r},t})(),G=(function(){function t(){}return t.numberOfTrailingZeros=function(e){var r;if(e===0)return 32;var n=31;return r=e<<16,r!==0&&(n-=16,e=r),r=e<<8,r!==0&&(n-=8,e=r),r=e<<4,r!==0&&(n-=4,e=r),r=e<<2,r!==0&&(n-=2,e=r),n-(e<<1>>>31)},t.numberOfLeadingZeros=function(e){if(e===0)return 32;var r=1;return e>>>16||(r+=16,e<<=16),e>>>24||(r+=8,e<<=8),e>>>28||(r+=4,e<<=4),e>>>30||(r+=2,e<<=2),r-=e>>>31,r},t.toHexString=function(e){return e.toString(16)},t.toBinaryString=function(e){return String(parseInt(String(e),2))},t.bitCount=function(e){return e=e-(e>>>1&1431655765),e=(e&858993459)+(e>>>2&858993459),e=e+(e>>>4)&252645135,e=e+(e>>>8),e=e+(e>>>16),e&63},t.truncDivision=function(e,r){return Math.trunc(e/r)},t.parseInt=function(e,r){return r===void 0&&(r=void 0),parseInt(e,r)},t.MIN_VALUE_32_BITS=-2147483648,t.MAX_VALUE=Number.MAX_SAFE_INTEGER,t})(),ge=(function(){function t(e,r){e===void 0?(this.size=0,this.bits=new Int32Array(1)):(this.size=e,r==null?this.bits=t.makeArray(e):this.bits=r)}return t.prototype.getSize=function(){return this.size},t.prototype.getSizeInBytes=function(){return Math.floor((this.size+7)/8)},t.prototype.ensureCapacity=function(e){if(e>this.bits.length*32){var r=t.makeArray(e);re.arraycopy(this.bits,0,r,0,this.bits.length),this.bits=r}},t.prototype.get=function(e){return(this.bits[Math.floor(e/32)]&1<<(e&31))!==0},t.prototype.set=function(e){this.bits[Math.floor(e/32)]|=1<<(e&31)},t.prototype.flip=function(e){this.bits[Math.floor(e/32)]^=1<<(e&31)},t.prototype.getNextSet=function(e){var r=this.size;if(e>=r)return r;var n=this.bits,i=Math.floor(e/32),a=n[i];a&=~((1<<(e&31))-1);for(var o=n.length;a===0;){if(++i===o)return r;a=n[i]}var s=i*32+G.numberOfTrailingZeros(a);return s>r?r:s},t.prototype.getNextUnset=function(e){var r=this.size;if(e>=r)return r;var n=this.bits,i=Math.floor(e/32),a=~n[i];a&=~((1<<(e&31))-1);for(var o=n.length;a===0;){if(++i===o)return r;a=~n[i]}var s=i*32+G.numberOfTrailingZeros(a);return s>r?r:s},t.prototype.setBulk=function(e,r){this.bits[Math.floor(e/32)]=r},t.prototype.setRange=function(e,r){if(r<e||e<0||r>this.size)throw new L;if(r!==e){r--;for(var n=Math.floor(e/32),i=Math.floor(r/32),a=this.bits,o=n;o<=i;o++){var s=o>n?0:e&31,c=o<i?31:r&31,u=(2<<c)-(1<<s);a[o]|=u}}},t.prototype.clear=function(){for(var e=this.bits.length,r=this.bits,n=0;n<e;n++)r[n]=0},t.prototype.isRange=function(e,r,n){if(r<e||e<0||r>this.size)throw new L;if(r===e)return!0;r--;for(var i=Math.floor(e/32),a=Math.floor(r/32),o=this.bits,s=i;s<=a;s++){var c=s>i?0:e&31,u=s<a?31:r&31,l=(2<<u)-(1<<c)&4294967295;if((o[s]&l)!==(n?l:0))return!1}return!0},t.prototype.appendBit=function(e){this.ensureCapacity(this.size+1),e&&(this.bits[Math.floor(this.size/32)]|=1<<(this.size&31)),this.size++},t.prototype.appendBits=function(e,r){if(r<0||r>32)throw new L("Num bits must be between 0 and 32");this.ensureCapacity(this.size+r);for(var n=r;n>0;n--)this.appendBit((e>>n-1&1)===1)},t.prototype.appendBitArray=function(e){var r=e.size;this.ensureCapacity(this.size+r);for(var n=0;n<r;n++)this.appendBit(e.get(n))},t.prototype.xor=function(e){if(this.size!==e.size)throw new L("Sizes don't match");for(var r=this.bits,n=0,i=r.length;n<i;n++)r[n]^=e.bits[n]},t.prototype.toBytes=function(e,r,n,i){for(var a=0;a<i;a++){for(var o=0,s=0;s<8;s++)this.get(e)&&(o|=1<<7-s),e++;r[n+a]=o}},t.prototype.getBitArray=function(){return this.bits},t.prototype.reverse=function(){for(var e=new Int32Array(this.bits.length),r=Math.floor((this.size-1)/32),n=r+1,i=this.bits,a=0;a<n;a++){var o=i[a];o=o>>1&1431655765|(o&1431655765)<<1,o=o>>2&858993459|(o&858993459)<<2,o=o>>4&252645135|(o&252645135)<<4,o=o>>8&16711935|(o&16711935)<<8,o=o>>16&65535|(o&65535)<<16,e[r-a]=o}if(this.size!==n*32){for(var s=n*32-this.size,c=e[0]>>>s,a=1;a<n;a++){var u=e[a];c|=u<<32-s,e[a-1]=c,c=u>>>s}e[n-1]=c}this.bits=e},t.makeArray=function(e){return new Int32Array(Math.floor((e+31)/32))},t.prototype.equals=function(e){if(!(e instanceof t))return!1;var r=e;return this.size===r.size&&Be.equals(this.bits,r.bits)},t.prototype.hashCode=function(){return 31*this.size+Be.hashCode(this.bits)},t.prototype.toString=function(){for(var e="",r=0,n=this.size;r<n;r++)(r&7)===0&&(e+=" "),e+=this.get(r)?"X":".";return e},t.prototype.clone=function(){return new t(this.size,this.bits.slice())},t})(),En;(function(t){t[t.OTHER=0]="OTHER",t[t.PURE_BARCODE=1]="PURE_BARCODE",t[t.POSSIBLE_FORMATS=2]="POSSIBLE_FORMATS",t[t.TRY_HARDER=3]="TRY_HARDER",t[t.CHARACTER_SET=4]="CHARACTER_SET",t[t.ALLOWED_LENGTHS=5]="ALLOWED_LENGTHS",t[t.ASSUME_CODE_39_CHECK_DIGIT=6]="ASSUME_CODE_39_CHECK_DIGIT",t[t.ASSUME_GS1=7]="ASSUME_GS1",t[t.RETURN_CODABAR_START_END=8]="RETURN_CODABAR_START_END",t[t.NEED_RESULT_POINT_CALLBACK=9]="NEED_RESULT_POINT_CALLBACK",t[t.ALLOWED_EAN_EXTENSIONS=10]="ALLOWED_EAN_EXTENSIONS"})(En||(En={}));const ce=En;var dc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),R=(function(t){dc(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.getFormatInstance=function(){return new e},e.kind="FormatException",e})(Ie),hc=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],n=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},q;(function(t){t[t.Cp437=0]="Cp437",t[t.ISO8859_1=1]="ISO8859_1",t[t.ISO8859_2=2]="ISO8859_2",t[t.ISO8859_3=3]="ISO8859_3",t[t.ISO8859_4=4]="ISO8859_4",t[t.ISO8859_5=5]="ISO8859_5",t[t.ISO8859_6=6]="ISO8859_6",t[t.ISO8859_7=7]="ISO8859_7",t[t.ISO8859_8=8]="ISO8859_8",t[t.ISO8859_9=9]="ISO8859_9",t[t.ISO8859_10=10]="ISO8859_10",t[t.ISO8859_11=11]="ISO8859_11",t[t.ISO8859_13=12]="ISO8859_13",t[t.ISO8859_14=13]="ISO8859_14",t[t.ISO8859_15=14]="ISO8859_15",t[t.ISO8859_16=15]="ISO8859_16",t[t.SJIS=16]="SJIS",t[t.Cp1250=17]="Cp1250",t[t.Cp1251=18]="Cp1251",t[t.Cp1252=19]="Cp1252",t[t.Cp1256=20]="Cp1256",t[t.UnicodeBigUnmarked=21]="UnicodeBigUnmarked",t[t.UTF8=22]="UTF8",t[t.ASCII=23]="ASCII",t[t.Big5=24]="Big5",t[t.GB18030=25]="GB18030",t[t.EUC_KR=26]="EUC_KR"})(q||(q={}));var he=(function(){function t(e,r,n){for(var i,a,o=[],s=3;s<arguments.length;s++)o[s-3]=arguments[s];this.valueIdentifier=e,this.name=n,typeof r=="number"?this.values=Int32Array.from([r]):this.values=r,this.otherEncodingNames=o,t.VALUE_IDENTIFIER_TO_ECI.set(e,this),t.NAME_TO_ECI.set(n,this);for(var c=this.values,u=0,l=c.length;u!==l;u++){var d=c[u];t.VALUES_TO_ECI.set(d,this)}try{for(var v=hc(o),h=v.next();!h.done;h=v.next()){var p=h.value;t.NAME_TO_ECI.set(p,this)}}catch(g){i={error:g}}finally{try{h&&!h.done&&(a=v.return)&&a.call(v)}finally{if(i)throw i.error}}}return t.prototype.getValueIdentifier=function(){return this.valueIdentifier},t.prototype.getName=function(){return this.name},t.prototype.getValue=function(){return this.values[0]},t.getCharacterSetECIByValue=function(e){if(e<0||e>=900)throw new R("incorect value");var r=t.VALUES_TO_ECI.get(e);if(r===void 0)throw new R("incorect value");return r},t.getCharacterSetECIByName=function(e){var r=t.NAME_TO_ECI.get(e);if(r===void 0)throw new R("incorect value");return r},t.prototype.equals=function(e){if(!(e instanceof t))return!1;var r=e;return this.getName()===r.getName()},t.VALUE_IDENTIFIER_TO_ECI=new Map,t.VALUES_TO_ECI=new Map,t.NAME_TO_ECI=new Map,t.Cp437=new t(q.Cp437,Int32Array.from([0,2]),"Cp437"),t.ISO8859_1=new t(q.ISO8859_1,Int32Array.from([1,3]),"ISO-8859-1","ISO88591","ISO8859_1"),t.ISO8859_2=new t(q.ISO8859_2,4,"ISO-8859-2","ISO88592","ISO8859_2"),t.ISO8859_3=new t(q.ISO8859_3,5,"ISO-8859-3","ISO88593","ISO8859_3"),t.ISO8859_4=new t(q.ISO8859_4,6,"ISO-8859-4","ISO88594","ISO8859_4"),t.ISO8859_5=new t(q.ISO8859_5,7,"ISO-8859-5","ISO88595","ISO8859_5"),t.ISO8859_6=new t(q.ISO8859_6,8,"ISO-8859-6","ISO88596","ISO8859_6"),t.ISO8859_7=new t(q.ISO8859_7,9,"ISO-8859-7","ISO88597","ISO8859_7"),t.ISO8859_8=new t(q.ISO8859_8,10,"ISO-8859-8","ISO88598","ISO8859_8"),t.ISO8859_9=new t(q.ISO8859_9,11,"ISO-8859-9","ISO88599","ISO8859_9"),t.ISO8859_10=new t(q.ISO8859_10,12,"ISO-8859-10","ISO885910","ISO8859_10"),t.ISO8859_11=new t(q.ISO8859_11,13,"ISO-8859-11","ISO885911","ISO8859_11"),t.ISO8859_13=new t(q.ISO8859_13,15,"ISO-8859-13","ISO885913","ISO8859_13"),t.ISO8859_14=new t(q.ISO8859_14,16,"ISO-8859-14","ISO885914","ISO8859_14"),t.ISO8859_15=new t(q.ISO8859_15,17,"ISO-8859-15","ISO885915","ISO8859_15"),t.ISO8859_16=new t(q.ISO8859_16,18,"ISO-8859-16","ISO885916","ISO8859_16"),t.SJIS=new t(q.SJIS,20,"SJIS","Shift_JIS"),t.Cp1250=new t(q.Cp1250,21,"Cp1250","windows-1250"),t.Cp1251=new t(q.Cp1251,22,"Cp1251","windows-1251"),t.Cp1252=new t(q.Cp1252,23,"Cp1252","windows-1252"),t.Cp1256=new t(q.Cp1256,24,"Cp1256","windows-1256"),t.UnicodeBigUnmarked=new t(q.UnicodeBigUnmarked,25,"UnicodeBigUnmarked","UTF-16BE","UnicodeBig"),t.UTF8=new t(q.UTF8,26,"UTF8","UTF-8"),t.ASCII=new t(q.ASCII,Int32Array.from([27,170]),"ASCII","US-ASCII"),t.Big5=new t(q.Big5,28,"Big5"),t.GB18030=new t(q.GB18030,29,"GB18030","GB2312","EUC_CN","GBK"),t.EUC_KR=new t(q.EUC_KR,30,"EUC_KR","EUC-KR"),t})(),vc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),Or=(function(t){vc(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.kind="UnsupportedOperationException",e})(Ie),Ke=(function(){function t(){}return t.decode=function(e,r){var n=this.encodingName(r);return this.customDecoder?this.customDecoder(e,n):typeof TextDecoder>"u"||this.shouldDecodeOnFallback(n)?this.decodeFallback(e,n):new TextDecoder(n).decode(e)},t.shouldDecodeOnFallback=function(e){return!t.isBrowser()&&e==="ISO-8859-1"},t.encode=function(e,r){var n=this.encodingName(r);return this.customEncoder?this.customEncoder(e,n):typeof TextEncoder>"u"?this.encodeFallback(e):new TextEncoder().encode(e)},t.isBrowser=function(){return typeof window<"u"&&{}.toString.call(window)==="[object Window]"},t.encodingName=function(e){return typeof e=="string"?e:e.getName()},t.encodingCharacterSet=function(e){return e instanceof he?e:he.getCharacterSetECIByName(e)},t.decodeFallback=function(e,r){var n=this.encodingCharacterSet(r);if(t.isDecodeFallbackSupported(n)){for(var i="",a=0,o=e.length;a<o;a++){var s=e[a].toString(16);s.length<2&&(s="0"+s),i+="%"+s}return decodeURIComponent(i)}if(n.equals(he.UnicodeBigUnmarked))return String.fromCharCode.apply(null,new Uint16Array(e.buffer));throw new Or("Encoding "+this.encodingName(r)+" not supported by fallback.")},t.isDecodeFallbackSupported=function(e){return e.equals(he.UTF8)||e.equals(he.ISO8859_1)||e.equals(he.ASCII)},t.encodeFallback=function(e){for(var r=btoa(unescape(encodeURIComponent(e))),n=r.split(""),i=[],a=0;a<n.length;a++)i.push(n[a].charCodeAt(0));return new Uint8Array(i)},t})(),te=(function(){function t(){}return t.castAsNonUtf8Char=function(e,r){r===void 0&&(r=null);var n=r?r.getName():this.ISO88591;return Ke.decode(new Uint8Array([e]),n)},t.guessEncoding=function(e,r){if(r!=null&&r.get(ce.CHARACTER_SET)!==void 0)return r.get(ce.CHARACTER_SET).toString();for(var n=e.length,i=!0,a=!0,o=!0,s=0,c=0,u=0,l=0,d=0,v=0,h=0,p=0,g=0,y=0,w=0,m=e.length>3&&e[0]===239&&e[1]===187&&e[2]===191,_=0;_<n&&(i||a||o);_++){var A=e[_]&255;o&&(s>0?(A&128)===0?o=!1:s--:(A&128)!==0&&((A&64)===0?o=!1:(s++,(A&32)===0?c++:(s++,(A&16)===0?u++:(s++,(A&8)===0?l++:o=!1))))),i&&(A>127&&A<160?i=!1:A>159&&(A<192||A===215||A===247)&&w++),a&&(d>0?A<64||A===127||A>252?a=!1:d--:A===128||A===160||A>239?a=!1:A>160&&A<224?(v++,p=0,h++,h>g&&(g=h)):A>127?(d++,h=0,p++,p>y&&(y=p)):(h=0,p=0))}return o&&s>0&&(o=!1),a&&d>0&&(a=!1),o&&(m||c+u+l>0)?t.UTF8:a&&(t.ASSUME_SHIFT_JIS||g>=3||y>=3)?t.SHIFT_JIS:i&&a?g===2&&v===2||w*10>=n?t.SHIFT_JIS:t.ISO88591:i?t.ISO88591:a?t.SHIFT_JIS:o?t.UTF8:t.PLATFORM_DEFAULT_ENCODING},t.format=function(e){for(var r=[],n=1;n<arguments.length;n++)r[n-1]=arguments[n];var i=-1;function a(s,c,u,l,d,v){if(s==="%%")return"%";if(r[++i]!==void 0){s=l?parseInt(l.substr(1)):void 0;var h=d?parseInt(d.substr(1)):void 0,p;switch(v){case"s":p=r[i];break;case"c":p=r[i][0];break;case"f":p=parseFloat(r[i]).toFixed(s);break;case"p":p=parseFloat(r[i]).toPrecision(s);break;case"e":p=parseFloat(r[i]).toExponential(s);break;case"x":p=parseInt(r[i]).toString(h||16);break;case"d":p=parseFloat(parseInt(r[i],h||10).toPrecision(s)).toFixed(0);break}p=typeof p=="object"?JSON.stringify(p):(+p).toString(h);for(var g=parseInt(u),y=u&&u[0]+""=="0"?"0":" ";p.length<g;)p=c!==void 0?p+y:y+p;return p}}var o=/%(-)?(0?[0-9]+)?([.][0-9]+)?([#][0-9]+)?([scfpexd%])/g;return e.replace(o,a)},t.getBytes=function(e,r){return Ke.encode(e,r)},t.getCharCode=function(e,r){return r===void 0&&(r=0),e.charCodeAt(r)},t.getCharAt=function(e){return String.fromCharCode(e)},t.SHIFT_JIS=he.SJIS.getName(),t.GB2312="GB2312",t.ISO88591=he.ISO8859_1.getName(),t.EUC_JP="EUC_JP",t.UTF8=he.UTF8.getName(),t.PLATFORM_DEFAULT_ENCODING=t.UTF8,t.ASSUME_SHIFT_JIS=!1,t})(),J=(function(){function t(e){e===void 0&&(e=""),this.value=e}return t.prototype.enableDecoding=function(e){return this.encoding=e,this},t.prototype.append=function(e){return typeof e=="string"?this.value+=e.toString():this.encoding?this.value+=te.castAsNonUtf8Char(e,this.encoding):this.value+=String.fromCharCode(e),this},t.prototype.appendChars=function(e,r,n){for(var i=r;r<r+n;i++)this.append(e[i]);return this},t.prototype.length=function(){return this.value.length},t.prototype.charAt=function(e){return this.value.charAt(e)},t.prototype.deleteCharAt=function(e){this.value=this.value.substr(0,e)+this.value.substring(e+1)},t.prototype.setCharAt=function(e,r){this.value=this.value.substr(0,e)+r+this.value.substr(e+1)},t.prototype.substring=function(e,r){return this.value.substring(e,r)},t.prototype.setLengthToZero=function(){this.value=""},t.prototype.toString=function(){return this.value},t.prototype.insert=function(e,r){this.value=this.value.substr(0,e)+r+this.value.substr(e+r.length)},t})(),Ze=(function(){function t(e,r,n,i){if(this.width=e,this.height=r,this.rowSize=n,this.bits=i,r==null&&(r=e),this.height=r,e<1||r<1)throw new L("Both dimensions must be greater than 0");n==null&&(n=Math.floor((e+31)/32)),this.rowSize=n,i==null&&(this.bits=new Int32Array(this.rowSize*this.height))}return t.parseFromBooleanArray=function(e){for(var r=e.length,n=e[0].length,i=new t(n,r),a=0;a<r;a++)for(var o=e[a],s=0;s<n;s++)o[s]&&i.set(s,a);return i},t.parseFromString=function(e,r,n){if(e===null)throw new L("stringRepresentation cannot be null");for(var i=new Array(e.length),a=0,o=0,s=-1,c=0,u=0;u<e.length;)if(e.charAt(u)===`
28
28
  `||e.charAt(u)==="\r"){if(a>o){if(s===-1)s=a-o;else if(a-o!==s)throw new L("row lengths do not match");o=a,c++}u++}else if(e.substring(u,u+r.length)===r)u+=r.length,i[a]=!0,a++;else if(e.substring(u,u+n.length)===n)u+=n.length,i[a]=!1,a++;else throw new L("illegal character encountered: "+e.substring(u));if(a>o){if(s===-1)s=a-o;else if(a-o!==s)throw new L("row lengths do not match");c++}for(var l=new t(s,c),d=0;d<a;d++)i[d]&&l.set(Math.floor(d%s),Math.floor(d/s));return l},t.prototype.get=function(e,r){var n=r*this.rowSize+Math.floor(e/32);return(this.bits[n]>>>(e&31)&1)!==0},t.prototype.set=function(e,r){var n=r*this.rowSize+Math.floor(e/32);this.bits[n]|=1<<(e&31)&4294967295},t.prototype.unset=function(e,r){var n=r*this.rowSize+Math.floor(e/32);this.bits[n]&=~(1<<(e&31)&4294967295)},t.prototype.flip=function(e,r){var n=r*this.rowSize+Math.floor(e/32);this.bits[n]^=1<<(e&31)&4294967295},t.prototype.xor=function(e){if(this.width!==e.getWidth()||this.height!==e.getHeight()||this.rowSize!==e.getRowSize())throw new L("input matrix dimensions do not match");for(var r=new ge(Math.floor(this.width/32)+1),n=this.rowSize,i=this.bits,a=0,o=this.height;a<o;a++)for(var s=a*n,c=e.getRow(a,r).getBitArray(),u=0;u<n;u++)i[s+u]^=c[u]},t.prototype.clear=function(){for(var e=this.bits,r=e.length,n=0;n<r;n++)e[n]=0},t.prototype.setRegion=function(e,r,n,i){if(r<0||e<0)throw new L("Left and top must be nonnegative");if(i<1||n<1)throw new L("Height and width must be at least 1");var a=e+n,o=r+i;if(o>this.height||a>this.width)throw new L("The region must fit inside the matrix");for(var s=this.rowSize,c=this.bits,u=r;u<o;u++)for(var l=u*s,d=e;d<a;d++)c[l+Math.floor(d/32)]|=1<<(d&31)&4294967295},t.prototype.getRow=function(e,r){r==null||r.getSize()<this.width?r=new ge(this.width):r.clear();for(var n=this.rowSize,i=this.bits,a=e*n,o=0;o<n;o++)r.setBulk(o*32,i[a+o]);return r},t.prototype.setRow=function(e,r){re.arraycopy(r.getBitArray(),0,this.bits,e*this.rowSize,this.rowSize)},t.prototype.rotate180=function(){for(var e=this.getWidth(),r=this.getHeight(),n=new ge(e),i=new ge(e),a=0,o=Math.floor((r+1)/2);a<o;a++)n=this.getRow(a,n),i=this.getRow(r-1-a,i),n.reverse(),i.reverse(),this.setRow(a,i),this.setRow(r-1-a,n)},t.prototype.getEnclosingRectangle=function(){for(var e=this.width,r=this.height,n=this.rowSize,i=this.bits,a=e,o=r,s=-1,c=-1,u=0;u<r;u++)for(var l=0;l<n;l++){var d=i[u*n+l];if(d!==0){if(u<o&&(o=u),u>c&&(c=u),l*32<a){for(var v=0;(d<<31-v&4294967295)===0;)v++;l*32+v<a&&(a=l*32+v)}if(l*32+31>s){for(var v=31;!(d>>>v);)v--;l*32+v>s&&(s=l*32+v)}}}return s<a||c<o?null:Int32Array.from([a,o,s-a+1,c-o+1])},t.prototype.getTopLeftOnBit=function(){for(var e=this.rowSize,r=this.bits,n=0;n<r.length&&r[n]===0;)n++;if(n===r.length)return null;for(var i=n/e,a=n%e*32,o=r[n],s=0;(o<<31-s&4294967295)===0;)s++;return a+=s,Int32Array.from([a,i])},t.prototype.getBottomRightOnBit=function(){for(var e=this.rowSize,r=this.bits,n=r.length-1;n>=0&&r[n]===0;)n--;if(n<0)return null;for(var i=Math.floor(n/e),a=Math.floor(n%e)*32,o=r[n],s=31;!(o>>>s);)s--;return a+=s,Int32Array.from([a,i])},t.prototype.getWidth=function(){return this.width},t.prototype.getHeight=function(){return this.height},t.prototype.getRowSize=function(){return this.rowSize},t.prototype.equals=function(e){if(!(e instanceof t))return!1;var r=e;return this.width===r.width&&this.height===r.height&&this.rowSize===r.rowSize&&Be.equals(this.bits,r.bits)},t.prototype.hashCode=function(){var e=this.width;return e=31*e+this.width,e=31*e+this.height,e=31*e+this.rowSize,e=31*e+Be.hashCode(this.bits),e},t.prototype.toString=function(e,r,n){return e===void 0&&(e="X "),r===void 0&&(r=" "),n===void 0&&(n=`
29
29
  `),this.buildToString(e,r,n)},t.prototype.buildToString=function(e,r,n){for(var i=new J,a=0,o=this.height;a<o;a++){for(var s=0,c=this.width;s<c;s++)i.append(this.get(s,a)?e:r);i.append(n)}return i.toString()},t.prototype.clone=function(){return new t(this.width,this.height,this.rowSize,this.bits.slice())},t})(),pc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),b=(function(t){pc(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.getNotFoundInstance=function(){return new e},e.kind="NotFoundException",e})(Ie),gc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),xc=(function(t){gc(e,t);function e(r){var n=t.call(this,r)||this;return n.luminances=e.EMPTY,n.buckets=new Int32Array(e.LUMINANCE_BUCKETS),n}return e.prototype.getBlackRow=function(r,n){var i=this.getLuminanceSource(),a=i.getWidth();n==null||n.getSize()<a?n=new ge(a):n.clear(),this.initArrays(a);for(var o=i.getRow(r,this.luminances),s=this.buckets,c=0;c<a;c++)s[(o[c]&255)>>e.LUMINANCE_SHIFT]++;var u=e.estimateBlackPoint(s);if(a<3)for(var c=0;c<a;c++)(o[c]&255)<u&&n.set(c);else for(var l=o[0]&255,d=o[1]&255,c=1;c<a-1;c++){var v=o[c+1]&255;(d*4-l-v)/2<u&&n.set(c),l=d,d=v}return n},e.prototype.getBlackMatrix=function(){var r=this.getLuminanceSource(),n=r.getWidth(),i=r.getHeight(),a=new Ze(n,i);this.initArrays(n);for(var o=this.buckets,s=1;s<5;s++)for(var c=Math.floor(i*s/5),u=r.getRow(c,this.luminances),l=Math.floor(n*4/5),d=Math.floor(n/5);d<l;d++){var v=u[d]&255;o[v>>e.LUMINANCE_SHIFT]++}for(var h=e.estimateBlackPoint(o),p=r.getMatrix(),s=0;s<i;s++)for(var g=s*n,d=0;d<n;d++){var v=p[g+d]&255;v<h&&a.set(d,s)}return a},e.prototype.createBinarizer=function(r){return new e(r)},e.prototype.initArrays=function(r){this.luminances.length<r&&(this.luminances=new Uint8ClampedArray(r));for(var n=this.buckets,i=0;i<e.LUMINANCE_BUCKETS;i++)n[i]=0},e.estimateBlackPoint=function(r){for(var n=r.length,i=0,a=0,o=0,s=0;s<n;s++)r[s]>o&&(a=s,o=r[s]),r[s]>i&&(i=r[s]);for(var c=0,u=0,s=0;s<n;s++){var l=s-a,d=r[s]*l*l;d>u&&(c=s,u=d)}if(a>c){var v=a;a=c,c=v}if(c-a<=n/16)throw new b;for(var h=c-1,p=-1,s=c-1;s>a;s--){var g=s-a,d=g*g*(c-s)*(i-r[s]);d>p&&(h=s,p=d)}return h<<e.LUMINANCE_SHIFT},e.LUMINANCE_BITS=5,e.LUMINANCE_SHIFT=8-e.LUMINANCE_BITS,e.LUMINANCE_BUCKETS=1<<e.LUMINANCE_BITS,e.EMPTY=Uint8ClampedArray.from([0]),e})(cc),yc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),mc=(function(t){yc(e,t);function e(r){var n=t.call(this,r)||this;return n.matrix=null,n}return e.prototype.getBlackMatrix=function(){if(this.matrix!==null)return this.matrix;var r=this.getLuminanceSource(),n=r.getWidth(),i=r.getHeight();if(n>=e.MINIMUM_DIMENSION&&i>=e.MINIMUM_DIMENSION){var a=r.getMatrix(),o=n>>e.BLOCK_SIZE_POWER;(n&e.BLOCK_SIZE_MASK)!==0&&o++;var s=i>>e.BLOCK_SIZE_POWER;(i&e.BLOCK_SIZE_MASK)!==0&&s++;var c=e.calculateBlackPoints(a,o,s,n,i),u=new Ze(n,i);e.calculateThresholdForBlock(a,o,s,n,i,c,u),this.matrix=u}else this.matrix=t.prototype.getBlackMatrix.call(this);return this.matrix},e.prototype.createBinarizer=function(r){return new e(r)},e.calculateThresholdForBlock=function(r,n,i,a,o,s,c){for(var u=o-e.BLOCK_SIZE,l=a-e.BLOCK_SIZE,d=0;d<i;d++){var v=d<<e.BLOCK_SIZE_POWER;v>u&&(v=u);for(var h=e.cap(d,2,i-3),p=0;p<n;p++){var g=p<<e.BLOCK_SIZE_POWER;g>l&&(g=l);for(var y=e.cap(p,2,n-3),w=0,m=-2;m<=2;m++){var _=s[h+m];w+=_[y-2]+_[y-1]+_[y]+_[y+1]+_[y+2]}var A=w/25;e.thresholdBlock(r,g,v,A,a,c)}}},e.cap=function(r,n,i){return r<n?n:r>i?i:r},e.thresholdBlock=function(r,n,i,a,o,s){for(var c=0,u=i*o+n;c<e.BLOCK_SIZE;c++,u+=o)for(var l=0;l<e.BLOCK_SIZE;l++)(r[u+l]&255)<=a&&s.set(n+l,i+c)},e.calculateBlackPoints=function(r,n,i,a,o){for(var s=o-e.BLOCK_SIZE,c=a-e.BLOCK_SIZE,u=new Array(i),l=0;l<i;l++){u[l]=new Int32Array(n);var d=l<<e.BLOCK_SIZE_POWER;d>s&&(d=s);for(var v=0;v<n;v++){var h=v<<e.BLOCK_SIZE_POWER;h>c&&(h=c);for(var p=0,g=255,y=0,w=0,m=d*a+h;w<e.BLOCK_SIZE;w++,m+=a){for(var _=0;_<e.BLOCK_SIZE;_++){var A=r[m+_]&255;p+=A,A<g&&(g=A),A>y&&(y=A)}if(y-g>e.MIN_DYNAMIC_RANGE)for(w++,m+=a;w<e.BLOCK_SIZE;w++,m+=a)for(var _=0;_<e.BLOCK_SIZE;_++)p+=r[m+_]&255}var I=p>>e.BLOCK_SIZE_POWER*2;if(y-g<=e.MIN_DYNAMIC_RANGE&&(I=g/2,l>0&&v>0)){var D=(u[l-1][v]+2*u[l][v-1]+u[l-1][v-1])/4;g<D&&(I=D)}u[l][v]=I}}return u},e.BLOCK_SIZE_POWER=3,e.BLOCK_SIZE=1<<e.BLOCK_SIZE_POWER,e.BLOCK_SIZE_MASK=e.BLOCK_SIZE-1,e.MINIMUM_DIMENSION=e.BLOCK_SIZE*5,e.MIN_DYNAMIC_RANGE=24,e})(xc),Hr=(function(){function t(e,r){this.width=e,this.height=r}return t.prototype.getWidth=function(){return this.width},t.prototype.getHeight=function(){return this.height},t.prototype.isCropSupported=function(){return!1},t.prototype.crop=function(e,r,n,i){throw new Or("This luminance source does not support cropping.")},t.prototype.isRotateSupported=function(){return!1},t.prototype.rotateCounterClockwise=function(){throw new Or("This luminance source does not support rotation by 90 degrees.")},t.prototype.rotateCounterClockwise45=function(){throw new Or("This luminance source does not support rotation by 45 degrees.")},t.prototype.toString=function(){for(var e=new Uint8ClampedArray(this.width),r=new J,n=0;n<this.height;n++){for(var i=this.getRow(n,e),a=0;a<this.width;a++){var o=i[a]&255,s=void 0;o<64?s="#":o<128?s="+":o<192?s=".":s=" ",r.append(s)}r.append(`
30
30
  `)}return r.toString()},t})(),wc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),Hn=(function(t){wc(e,t);function e(r){var n=t.call(this,r.getWidth(),r.getHeight())||this;return n.delegate=r,n}return e.prototype.getRow=function(r,n){for(var i=this.delegate.getRow(r,n),a=this.getWidth(),o=0;o<a;o++)i[o]=255-(i[o]&255);return i},e.prototype.getMatrix=function(){for(var r=this.delegate.getMatrix(),n=this.getWidth()*this.getHeight(),i=new Uint8ClampedArray(n),a=0;a<n;a++)i[a]=255-(r[a]&255);return i},e.prototype.isCropSupported=function(){return this.delegate.isCropSupported()},e.prototype.crop=function(r,n,i,a){return new e(this.delegate.crop(r,n,i,a))},e.prototype.isRotateSupported=function(){return this.delegate.isRotateSupported()},e.prototype.invert=function(){return this.delegate},e.prototype.rotateCounterClockwise=function(){return new e(this.delegate.rotateCounterClockwise())},e.prototype.rotateCounterClockwise45=function(){return new e(this.delegate.rotateCounterClockwise45())},e})(Hr),_c=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),Ec=(function(t){_c(e,t);function e(r){var n=t.call(this,r.width,r.height)||this;return n.canvas=r,n.tempCanvasElement=null,n.buffer=e.makeBufferFromCanvasImageData(r),n}return e.makeBufferFromCanvasImageData=function(r){var n=r.getContext("2d").getImageData(0,0,r.width,r.height);return e.toGrayscaleBuffer(n.data,r.width,r.height)},e.toGrayscaleBuffer=function(r,n,i){for(var a=new Uint8ClampedArray(n*i),o=0,s=0,c=r.length;o<c;o+=4,s++){var u=void 0,l=r[o+3];if(l===0)u=255;else{var d=r[o],v=r[o+1],h=r[o+2];u=306*d+601*v+117*h+512>>10}a[s]=u}return a},e.prototype.getRow=function(r,n){if(r<0||r>=this.getHeight())throw new L("Requested row is outside the image: "+r);var i=this.getWidth(),a=r*i;return n===null?n=this.buffer.slice(a,a+i):(n.length<i&&(n=new Uint8ClampedArray(i)),n.set(this.buffer.slice(a,a+i))),n},e.prototype.getMatrix=function(){return this.buffer},e.prototype.isCropSupported=function(){return!0},e.prototype.crop=function(r,n,i,a){return t.prototype.crop.call(this,r,n,i,a),this},e.prototype.isRotateSupported=function(){return!0},e.prototype.rotateCounterClockwise=function(){return this.rotate(-90),this},e.prototype.rotateCounterClockwise45=function(){return this.rotate(-45),this},e.prototype.getTempCanvasElement=function(){if(this.tempCanvasElement===null){var r=this.canvas.ownerDocument.createElement("canvas");r.width=this.canvas.width,r.height=this.canvas.height,this.tempCanvasElement=r}return this.tempCanvasElement},e.prototype.rotate=function(r){var n=this.getTempCanvasElement(),i=n.getContext("2d"),a=r*e.DEGREE_TO_RADIANS,o=this.canvas.width,s=this.canvas.height,c=Math.ceil(Math.abs(Math.cos(a))*o+Math.abs(Math.sin(a))*s),u=Math.ceil(Math.abs(Math.sin(a))*o+Math.abs(Math.cos(a))*s);return n.width=c,n.height=u,i.translate(c/2,u/2),i.rotate(a),i.drawImage(this.canvas,o/-2,s/-2),this.buffer=e.makeBufferFromCanvasImageData(n),this},e.prototype.invert=function(){return new Hn(this)},e.DEGREE_TO_RADIANS=Math.PI/180,e})(Hr),Ac=(function(){function t(e,r,n){this.deviceId=e,this.label=r,this.kind="videoinput",this.groupId=n||void 0}return t.prototype.toJSON=function(){return{kind:this.kind,groupId:this.groupId,deviceId:this.deviceId,label:this.label}},t})(),Ae=function(t,e,r,n){function i(a){return a instanceof r?a:new r(function(o){o(a)})}return new(r||(r=Promise))(function(a,o){function s(l){try{u(n.next(l))}catch(d){o(d)}}function c(l){try{u(n.throw(l))}catch(d){o(d)}}function u(l){l.done?a(l.value):i(l.value).then(s,c)}u((n=n.apply(t,e||[])).next())})},Ce=function(t,e){var r={label:0,sent:function(){if(a[0]&1)throw a[1];return a[1]},trys:[],ops:[]},n,i,a,o;return o={next:s(0),throw:s(1),return:s(2)},typeof Symbol=="function"&&(o[Symbol.iterator]=function(){return this}),o;function s(u){return function(l){return c([u,l])}}function c(u){if(n)throw new TypeError("Generator is already executing.");for(;r;)try{if(n=1,i&&(a=u[0]&2?i.return:u[0]?i.throw||((a=i.return)&&a.call(i),0):i.next)&&!(a=a.call(i,u[1])).done)return a;switch(i=0,a&&(u=[u[0]&2,a.value]),u[0]){case 0:case 1:a=u;break;case 4:return r.label++,{value:u[1],done:!1};case 5:r.label++,i=u[1],u=[0];continue;case 7:u=r.ops.pop(),r.trys.pop();continue;default:if(a=r.trys,!(a=a.length>0&&a[a.length-1])&&(u[0]===6||u[0]===2)){r=0;continue}if(u[0]===3&&(!a||u[1]>a[0]&&u[1]<a[3])){r.label=u[1];break}if(u[0]===6&&r.label<a[1]){r.label=a[1],a=u;break}if(a&&r.label<a[2]){r.label=a[2],r.ops.push(u);break}a[2]&&r.ops.pop(),r.trys.pop();continue}u=e.call(t,r)}catch(l){u=[6,l],i=0}finally{n=a=0}if(u[0]&5)throw u[1];return{value:u[0]?u[1]:void 0,done:!0}}},Cc=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],n=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},Vt=(function(){function t(e,r,n){r===void 0&&(r=500),this.reader=e,this.timeBetweenScansMillis=r,this._hints=n,this._stopContinuousDecode=!1,this._stopAsyncDecode=!1,this._timeBetweenDecodingAttempts=0}return Object.defineProperty(t.prototype,"hasNavigator",{get:function(){return typeof navigator<"u"},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"isMediaDevicesSuported",{get:function(){return this.hasNavigator&&!!navigator.mediaDevices},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"canEnumerateDevices",{get:function(){return!!(this.isMediaDevicesSuported&&navigator.mediaDevices.enumerateDevices)},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"timeBetweenDecodingAttempts",{get:function(){return this._timeBetweenDecodingAttempts},set:function(e){this._timeBetweenDecodingAttempts=e<0?0:e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"hints",{get:function(){return this._hints},set:function(e){this._hints=e||null},enumerable:!1,configurable:!0}),t.prototype.listVideoInputDevices=function(){return Ae(this,void 0,void 0,function(){var e,r,n,i,a,o,s,c,u,l,d,v;return Ce(this,function(h){switch(h.label){case 0:if(!this.hasNavigator)throw new Error("Can't enumerate devices, navigator is not present.");if(!this.canEnumerateDevices)throw new Error("Can't enumerate devices, method not supported.");return[4,navigator.mediaDevices.enumerateDevices()];case 1:e=h.sent(),r=[];try{for(n=Cc(e),i=n.next();!i.done;i=n.next())a=i.value,o=a.kind==="video"?"videoinput":a.kind,o==="videoinput"&&(s=a.deviceId||a.id,c=a.label||"Video device "+(r.length+1),u=a.groupId,l={deviceId:s,label:c,kind:o,groupId:u},r.push(l))}catch(p){d={error:p}}finally{try{i&&!i.done&&(v=n.return)&&v.call(n)}finally{if(d)throw d.error}}return[2,r]}})})},t.prototype.getVideoInputDevices=function(){return Ae(this,void 0,void 0,function(){var e;return Ce(this,function(r){switch(r.label){case 0:return[4,this.listVideoInputDevices()];case 1:return e=r.sent(),[2,e.map(function(n){return new Ac(n.deviceId,n.label)})]}})})},t.prototype.findDeviceById=function(e){return Ae(this,void 0,void 0,function(){var r;return Ce(this,function(n){switch(n.label){case 0:return[4,this.listVideoInputDevices()];case 1:return r=n.sent(),r?[2,r.find(function(i){return i.deviceId===e})]:[2,null]}})})},t.prototype.decodeFromInputVideoDevice=function(e,r){return Ae(this,void 0,void 0,function(){return Ce(this,function(n){switch(n.label){case 0:return[4,this.decodeOnceFromVideoDevice(e,r)];case 1:return[2,n.sent()]}})})},t.prototype.decodeOnceFromVideoDevice=function(e,r){return Ae(this,void 0,void 0,function(){var n,i;return Ce(this,function(a){switch(a.label){case 0:return this.reset(),e?n={deviceId:{exact:e}}:n={facingMode:"environment"},i={video:n},[4,this.decodeOnceFromConstraints(i,r)];case 1:return[2,a.sent()]}})})},t.prototype.decodeOnceFromConstraints=function(e,r){return Ae(this,void 0,void 0,function(){var n;return Ce(this,function(i){switch(i.label){case 0:return[4,navigator.mediaDevices.getUserMedia(e)];case 1:return n=i.sent(),[4,this.decodeOnceFromStream(n,r)];case 2:return[2,i.sent()]}})})},t.prototype.decodeOnceFromStream=function(e,r){return Ae(this,void 0,void 0,function(){var n,i;return Ce(this,function(a){switch(a.label){case 0:return this.reset(),[4,this.attachStreamToVideo(e,r)];case 1:return n=a.sent(),[4,this.decodeOnce(n)];case 2:return i=a.sent(),[2,i]}})})},t.prototype.decodeFromInputVideoDeviceContinuously=function(e,r,n){return Ae(this,void 0,void 0,function(){return Ce(this,function(i){switch(i.label){case 0:return[4,this.decodeFromVideoDevice(e,r,n)];case 1:return[2,i.sent()]}})})},t.prototype.decodeFromVideoDevice=function(e,r,n){return Ae(this,void 0,void 0,function(){var i,a;return Ce(this,function(o){switch(o.label){case 0:return e?i={deviceId:{exact:e}}:i={facingMode:"environment"},a={video:i},[4,this.decodeFromConstraints(a,r,n)];case 1:return[2,o.sent()]}})})},t.prototype.decodeFromConstraints=function(e,r,n){return Ae(this,void 0,void 0,function(){var i;return Ce(this,function(a){switch(a.label){case 0:return[4,navigator.mediaDevices.getUserMedia(e)];case 1:return i=a.sent(),[4,this.decodeFromStream(i,r,n)];case 2:return[2,a.sent()]}})})},t.prototype.decodeFromStream=function(e,r,n){return Ae(this,void 0,void 0,function(){var i;return Ce(this,function(a){switch(a.label){case 0:return this.reset(),[4,this.attachStreamToVideo(e,r)];case 1:return i=a.sent(),[4,this.decodeContinuously(i,n)];case 2:return[2,a.sent()]}})})},t.prototype.stopAsyncDecode=function(){this._stopAsyncDecode=!0},t.prototype.stopContinuousDecode=function(){this._stopContinuousDecode=!0},t.prototype.attachStreamToVideo=function(e,r){return Ae(this,void 0,void 0,function(){var n;return Ce(this,function(i){switch(i.label){case 0:return n=this.prepareVideoElement(r),this.addVideoSource(n,e),this.videoElement=n,this.stream=e,[4,this.playVideoOnLoadAsync(n)];case 1:return i.sent(),[2,n]}})})},t.prototype.playVideoOnLoadAsync=function(e){var r=this;return new Promise(function(n,i){return r.playVideoOnLoad(e,function(){return n()})})},t.prototype.playVideoOnLoad=function(e,r){var n=this;this.videoEndedListener=function(){return n.stopStreams()},this.videoCanPlayListener=function(){return n.tryPlayVideo(e)},e.addEventListener("ended",this.videoEndedListener),e.addEventListener("canplay",this.videoCanPlayListener),e.addEventListener("playing",r),this.tryPlayVideo(e)},t.prototype.isVideoPlaying=function(e){return e.currentTime>0&&!e.paused&&!e.ended&&e.readyState>2},t.prototype.tryPlayVideo=function(e){return Ae(this,void 0,void 0,function(){return Ce(this,function(r){switch(r.label){case 0:if(this.isVideoPlaying(e))return console.warn("Trying to play video that is already playing."),[2];r.label=1;case 1:return r.trys.push([1,3,,4]),[4,e.play()];case 2:return r.sent(),[3,4];case 3:return r.sent(),console.warn("It was not possible to play the video."),[3,4];case 4:return[2]}})})},t.prototype.getMediaElement=function(e,r){var n=document.getElementById(e);if(!n)throw new Ue("element with id '"+e+"' not found");if(n.nodeName.toLowerCase()!==r.toLowerCase())throw new Ue("element with id '"+e+"' must be an "+r+" element");return n},t.prototype.decodeFromImage=function(e,r){if(!e&&!r)throw new Ue("either imageElement with a src set or an url must be provided");return r&&!e?this.decodeFromImageUrl(r):this.decodeFromImageElement(e)},t.prototype.decodeFromVideo=function(e,r){if(!e&&!r)throw new Ue("Either an element with a src set or an URL must be provided");return r&&!e?this.decodeFromVideoUrl(r):this.decodeFromVideoElement(e)},t.prototype.decodeFromVideoContinuously=function(e,r,n){if(e===void 0&&r===void 0)throw new Ue("Either an element with a src set or an URL must be provided");return r&&!e?this.decodeFromVideoUrlContinuously(r,n):this.decodeFromVideoElementContinuously(e,n)},t.prototype.decodeFromImageElement=function(e){if(!e)throw new Ue("An image element must be provided.");this.reset();var r=this.prepareImageElement(e);this.imageElement=r;var n;return this.isImageLoaded(r)?n=this.decodeOnce(r,!1,!0):n=this._decodeOnLoadImage(r),n},t.prototype.decodeFromVideoElement=function(e){var r=this._decodeFromVideoElementSetup(e);return this._decodeOnLoadVideo(r)},t.prototype.decodeFromVideoElementContinuously=function(e,r){var n=this._decodeFromVideoElementSetup(e);return this._decodeOnLoadVideoContinuously(n,r)},t.prototype._decodeFromVideoElementSetup=function(e){if(!e)throw new Ue("A video element must be provided.");this.reset();var r=this.prepareVideoElement(e);return this.videoElement=r,r},t.prototype.decodeFromImageUrl=function(e){if(!e)throw new Ue("An URL must be provided.");this.reset();var r=this.prepareImageElement();this.imageElement=r;var n=this._decodeOnLoadImage(r);return r.src=e,n},t.prototype.decodeFromVideoUrl=function(e){if(!e)throw new Ue("An URL must be provided.");this.reset();var r=this.prepareVideoElement(),n=this.decodeFromVideoElement(r);return r.src=e,n},t.prototype.decodeFromVideoUrlContinuously=function(e,r){if(!e)throw new Ue("An URL must be provided.");this.reset();var n=this.prepareVideoElement(),i=this.decodeFromVideoElementContinuously(n,r);return n.src=e,i},t.prototype._decodeOnLoadImage=function(e){var r=this;return new Promise(function(n,i){r.imageLoadedListener=function(){return r.decodeOnce(e,!1,!0).then(n,i)},e.addEventListener("load",r.imageLoadedListener)})},t.prototype._decodeOnLoadVideo=function(e){return Ae(this,void 0,void 0,function(){return Ce(this,function(r){switch(r.label){case 0:return[4,this.playVideoOnLoadAsync(e)];case 1:return r.sent(),[4,this.decodeOnce(e)];case 2:return[2,r.sent()]}})})},t.prototype._decodeOnLoadVideoContinuously=function(e,r){return Ae(this,void 0,void 0,function(){return Ce(this,function(n){switch(n.label){case 0:return[4,this.playVideoOnLoadAsync(e)];case 1:return n.sent(),this.decodeContinuously(e,r),[2]}})})},t.prototype.isImageLoaded=function(e){return!(!e.complete||e.naturalWidth===0)},t.prototype.prepareImageElement=function(e){var r;return typeof e>"u"&&(r=document.createElement("img"),r.width=200,r.height=200),typeof e=="string"&&(r=this.getMediaElement(e,"img")),e instanceof HTMLImageElement&&(r=e),r},t.prototype.prepareVideoElement=function(e){var r;return!e&&typeof document<"u"&&(r=document.createElement("video"),r.width=200,r.height=200),typeof e=="string"&&(r=this.getMediaElement(e,"video")),e instanceof HTMLVideoElement&&(r=e),r.setAttribute("autoplay","true"),r.setAttribute("muted","true"),r.setAttribute("playsinline","true"),r},t.prototype.decodeOnce=function(e,r,n){var i=this;r===void 0&&(r=!0),n===void 0&&(n=!0),this._stopAsyncDecode=!1;var a=function(o,s){if(i._stopAsyncDecode){s(new b("Video stream has ended before any code could be detected.")),i._stopAsyncDecode=void 0;return}try{var c=i.decode(e);o(c)}catch(v){var u=r&&v instanceof b,l=v instanceof me||v instanceof R,d=l&&n;if(u||d)return setTimeout(a,i._timeBetweenDecodingAttempts,o,s);s(v)}};return new Promise(function(o,s){return a(o,s)})},t.prototype.decodeContinuously=function(e,r){var n=this;this._stopContinuousDecode=!1;var i=function(){if(n._stopContinuousDecode){n._stopContinuousDecode=void 0;return}try{var a=n.decode(e);r(a,null),setTimeout(i,n.timeBetweenScansMillis)}catch(c){r(null,c);var o=c instanceof me||c instanceof R,s=c instanceof b;(o||s)&&setTimeout(i,n._timeBetweenDecodingAttempts)}};i()},t.prototype.decode=function(e){var r=this.createBinaryBitmap(e);return this.decodeBitmap(r)},t.prototype._isHTMLVideoElement=function(e){var r=e;return r.videoWidth!==0},t.prototype.createBinaryBitmap=function(e){this.getCaptureCanvasContext(e),this._isHTMLVideoElement(e)?this.drawFrameOnCanvas(e):this.drawImageOnCanvas(e);var r=this.getCaptureCanvas(e),n=new Ec(r),i=new mc(n);return new oc(i)},t.prototype.getCaptureCanvasContext=function(e){if(!this.captureCanvasContext){var r=this.getCaptureCanvas(e),n=void 0;try{n=r.getContext("2d",{willReadFrequently:!0})}catch{n=r.getContext("2d")}this.captureCanvasContext=n}return this.captureCanvasContext},t.prototype.getCaptureCanvas=function(e){if(!this.captureCanvas){var r=this.createCaptureCanvas(e);this.captureCanvas=r}return this.captureCanvas},t.prototype.drawFrameOnCanvas=function(e,r,n){r===void 0&&(r={sx:0,sy:0,sWidth:e.videoWidth,sHeight:e.videoHeight,dx:0,dy:0,dWidth:e.videoWidth,dHeight:e.videoHeight}),n===void 0&&(n=this.captureCanvasContext),n.drawImage(e,r.sx,r.sy,r.sWidth,r.sHeight,r.dx,r.dy,r.dWidth,r.dHeight)},t.prototype.drawImageOnCanvas=function(e,r,n){r===void 0&&(r={sx:0,sy:0,sWidth:e.naturalWidth,sHeight:e.naturalHeight,dx:0,dy:0,dWidth:e.naturalWidth,dHeight:e.naturalHeight}),n===void 0&&(n=this.captureCanvasContext),n.drawImage(e,r.sx,r.sy,r.sWidth,r.sHeight,r.dx,r.dy,r.dWidth,r.dHeight)},t.prototype.decodeBitmap=function(e){return this.reader.decode(e,this._hints)},t.prototype.createCaptureCanvas=function(e){if(typeof document>"u")return this._destroyCaptureCanvas(),null;var r=document.createElement("canvas"),n,i;return typeof e<"u"&&(e instanceof HTMLVideoElement?(n=e.videoWidth,i=e.videoHeight):e instanceof HTMLImageElement&&(n=e.naturalWidth||e.width,i=e.naturalHeight||e.height)),r.style.width=n+"px",r.style.height=i+"px",r.width=n,r.height=i,r},t.prototype.stopStreams=function(){this.stream&&(this.stream.getVideoTracks().forEach(function(e){return e.stop()}),this.stream=void 0),this._stopAsyncDecode===!1&&this.stopAsyncDecode(),this._stopContinuousDecode===!1&&this.stopContinuousDecode()},t.prototype.reset=function(){this.stopStreams(),this._destroyVideoElement(),this._destroyImageElement(),this._destroyCaptureCanvas()},t.prototype._destroyVideoElement=function(){this.videoElement&&(typeof this.videoEndedListener<"u"&&this.videoElement.removeEventListener("ended",this.videoEndedListener),typeof this.videoPlayingEventListener<"u"&&this.videoElement.removeEventListener("playing",this.videoPlayingEventListener),typeof this.videoCanPlayListener<"u"&&this.videoElement.removeEventListener("loadedmetadata",this.videoCanPlayListener),this.cleanVideoSource(this.videoElement),this.videoElement=void 0)},t.prototype._destroyImageElement=function(){this.imageElement&&(this.imageLoadedListener!==void 0&&this.imageElement.removeEventListener("load",this.imageLoadedListener),this.imageElement.src=void 0,this.imageElement.removeAttribute("src"),this.imageElement=void 0)},t.prototype._destroyCaptureCanvas=function(){this.captureCanvasContext=void 0,this.captureCanvas=void 0},t.prototype.addVideoSource=function(e,r){try{e.srcObject=r}catch{e.src=URL.createObjectURL(r)}},t.prototype.cleanVideoSource=function(e){try{e.srcObject=null}catch{e.src=""}this.videoElement.removeAttribute("src")},t})(),Re=(function(){function t(e,r,n,i,a,o){n===void 0&&(n=r==null?0:8*r.length),o===void 0&&(o=re.currentTimeMillis()),this.text=e,this.rawBytes=r,this.numBits=n,this.resultPoints=i,this.format=a,this.timestamp=o,this.text=e,this.rawBytes=r,n==null?this.numBits=r==null?0:8*r.length:this.numBits=n,this.resultPoints=i,this.format=a,this.resultMetadata=null,o==null?this.timestamp=re.currentTimeMillis():this.timestamp=o}return t.prototype.getText=function(){return this.text},t.prototype.getRawBytes=function(){return this.rawBytes},t.prototype.getNumBits=function(){return this.numBits},t.prototype.getResultPoints=function(){return this.resultPoints},t.prototype.getBarcodeFormat=function(){return this.format},t.prototype.getResultMetadata=function(){return this.resultMetadata},t.prototype.putMetadata=function(e,r){this.resultMetadata===null&&(this.resultMetadata=new Map),this.resultMetadata.set(e,r)},t.prototype.putAllMetadata=function(e){e!==null&&(this.resultMetadata===null?this.resultMetadata=e:this.resultMetadata=new Map(e))},t.prototype.addResultPoints=function(e){var r=this.resultPoints;if(r===null)this.resultPoints=e;else if(e!==null&&e.length>0){var n=new Array(r.length+e.length);re.arraycopy(r,0,n,0,r.length),re.arraycopy(e,0,n,r.length,e.length),this.resultPoints=n}},t.prototype.getTimestamp=function(){return this.timestamp},t.prototype.toString=function(){return this.text},t})(),An;(function(t){t[t.AZTEC=0]="AZTEC",t[t.CODABAR=1]="CODABAR",t[t.CODE_39=2]="CODE_39",t[t.CODE_93=3]="CODE_93",t[t.CODE_128=4]="CODE_128",t[t.DATA_MATRIX=5]="DATA_MATRIX",t[t.EAN_8=6]="EAN_8",t[t.EAN_13=7]="EAN_13",t[t.ITF=8]="ITF",t[t.MAXICODE=9]="MAXICODE",t[t.PDF_417=10]="PDF_417",t[t.QR_CODE=11]="QR_CODE",t[t.RSS_14=12]="RSS_14",t[t.RSS_EXPANDED=13]="RSS_EXPANDED",t[t.UPC_A=14]="UPC_A",t[t.UPC_E=15]="UPC_E",t[t.UPC_EAN_EXTENSION=16]="UPC_EAN_EXTENSION"})(An||(An={}));const U=An;var Cn;(function(t){t[t.OTHER=0]="OTHER",t[t.ORIENTATION=1]="ORIENTATION",t[t.BYTE_SEGMENTS=2]="BYTE_SEGMENTS",t[t.ERROR_CORRECTION_LEVEL=3]="ERROR_CORRECTION_LEVEL",t[t.ISSUE_NUMBER=4]="ISSUE_NUMBER",t[t.SUGGESTED_PRICE=5]="SUGGESTED_PRICE",t[t.POSSIBLE_COUNTRY=6]="POSSIBLE_COUNTRY",t[t.UPC_EAN_EXTENSION=7]="UPC_EAN_EXTENSION",t[t.PDF417_EXTRA_METADATA=8]="PDF417_EXTRA_METADATA",t[t.STRUCTURED_APPEND_SEQUENCE=9]="STRUCTURED_APPEND_SEQUENCE",t[t.STRUCTURED_APPEND_PARITY=10]="STRUCTURED_APPEND_PARITY"})(Cn||(Cn={}));const we=Cn;var $r=(function(){function t(e,r,n,i,a,o){a===void 0&&(a=-1),o===void 0&&(o=-1),this.rawBytes=e,this.text=r,this.byteSegments=n,this.ecLevel=i,this.structuredAppendSequenceNumber=a,this.structuredAppendParity=o,this.numBits=e==null?0:8*e.length}return t.prototype.getRawBytes=function(){return this.rawBytes},t.prototype.getNumBits=function(){return this.numBits},t.prototype.setNumBits=function(e){this.numBits=e},t.prototype.getText=function(){return this.text},t.prototype.getByteSegments=function(){return this.byteSegments},t.prototype.getECLevel=function(){return this.ecLevel},t.prototype.getErrorsCorrected=function(){return this.errorsCorrected},t.prototype.setErrorsCorrected=function(e){this.errorsCorrected=e},t.prototype.getErasures=function(){return this.erasures},t.prototype.setErasures=function(e){this.erasures=e},t.prototype.getOther=function(){return this.other},t.prototype.setOther=function(e){this.other=e},t.prototype.hasStructuredAppend=function(){return this.structuredAppendParity>=0&&this.structuredAppendSequenceNumber>=0},t.prototype.getStructuredAppendParity=function(){return this.structuredAppendParity},t.prototype.getStructuredAppendSequenceNumber=function(){return this.structuredAppendSequenceNumber},t})(),Zt=(function(){function t(){}return t.prototype.exp=function(e){return this.expTable[e]},t.prototype.log=function(e){if(e===0)throw new L;return this.logTable[e]},t.addOrSubtract=function(e,r){return e^r},t})(),ct=(function(){function t(e,r){if(r.length===0)throw new L;this.field=e;var n=r.length;if(n>1&&r[0]===0){for(var i=1;i<n&&r[i]===0;)i++;i===n?this.coefficients=Int32Array.from([0]):(this.coefficients=new Int32Array(n-i),re.arraycopy(r,i,this.coefficients,0,this.coefficients.length))}else this.coefficients=r}return t.prototype.getCoefficients=function(){return this.coefficients},t.prototype.getDegree=function(){return this.coefficients.length-1},t.prototype.isZero=function(){return this.coefficients[0]===0},t.prototype.getCoefficient=function(e){return this.coefficients[this.coefficients.length-1-e]},t.prototype.evaluateAt=function(e){if(e===0)return this.getCoefficient(0);var r=this.coefficients,n;if(e===1){n=0;for(var i=0,a=r.length;i!==a;i++){var o=r[i];n=Zt.addOrSubtract(n,o)}return n}n=r[0];for(var s=r.length,c=this.field,i=1;i<s;i++)n=Zt.addOrSubtract(c.multiply(e,n),r[i]);return n},t.prototype.addOrSubtract=function(e){if(!this.field.equals(e.field))throw new L("GenericGFPolys do not have same GenericGF field");if(this.isZero())return e;if(e.isZero())return this;var r=this.coefficients,n=e.coefficients;if(r.length>n.length){var i=r;r=n,n=i}var a=new Int32Array(n.length),o=n.length-r.length;re.arraycopy(n,0,a,0,o);for(var s=o;s<n.length;s++)a[s]=Zt.addOrSubtract(r[s-o],n[s]);return new t(this.field,a)},t.prototype.multiply=function(e){if(!this.field.equals(e.field))throw new L("GenericGFPolys do not have same GenericGF field");if(this.isZero()||e.isZero())return this.field.getZero();for(var r=this.coefficients,n=r.length,i=e.coefficients,a=i.length,o=new Int32Array(n+a-1),s=this.field,c=0;c<n;c++)for(var u=r[c],l=0;l<a;l++)o[c+l]=Zt.addOrSubtract(o[c+l],s.multiply(u,i[l]));return new t(s,o)},t.prototype.multiplyScalar=function(e){if(e===0)return this.field.getZero();if(e===1)return this;for(var r=this.coefficients.length,n=this.field,i=new Int32Array(r),a=this.coefficients,o=0;o<r;o++)i[o]=n.multiply(a[o],e);return new t(n,i)},t.prototype.multiplyByMonomial=function(e,r){if(e<0)throw new L;if(r===0)return this.field.getZero();for(var n=this.coefficients,i=n.length,a=new Int32Array(i+e),o=this.field,s=0;s<i;s++)a[s]=o.multiply(n[s],r);return new t(o,a)},t.prototype.divide=function(e){if(!this.field.equals(e.field))throw new L("GenericGFPolys do not have same GenericGF field");if(e.isZero())throw new L("Divide by 0");for(var r=this.field,n=r.getZero(),i=this,a=e.getCoefficient(e.getDegree()),o=r.inverse(a);i.getDegree()>=e.getDegree()&&!i.isZero();){var s=i.getDegree()-e.getDegree(),c=r.multiply(i.getCoefficient(i.getDegree()),o),u=e.multiplyByMonomial(s,c),l=r.buildMonomial(s,c);n=n.addOrSubtract(l),i=i.addOrSubtract(u)}return[n,i]},t.prototype.toString=function(){for(var e="",r=this.getDegree();r>=0;r--){var n=this.getCoefficient(r);if(n!==0){if(n<0?(e+=" - ",n=-n):e.length>0&&(e+=" + "),r===0||n!==1){var i=this.field.log(n);i===0?e+="1":i===1?e+="a":(e+="a^",e+=i)}r!==0&&(r===1?e+="x":(e+="x^",e+=r))}}return e},t})(),bc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),na=(function(t){bc(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.kind="ArithmeticException",e})(Ie),Sc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),Ne=(function(t){Sc(e,t);function e(r,n,i){var a=t.call(this)||this;a.primitive=r,a.size=n,a.generatorBase=i;for(var o=new Int32Array(n),s=1,c=0;c<n;c++)o[c]=s,s*=2,s>=n&&(s^=r,s&=n-1);a.expTable=o;for(var u=new Int32Array(n),c=0;c<n-1;c++)u[o[c]]=c;return a.logTable=u,a.zero=new ct(a,Int32Array.from([0])),a.one=new ct(a,Int32Array.from([1])),a}return e.prototype.getZero=function(){return this.zero},e.prototype.getOne=function(){return this.one},e.prototype.buildMonomial=function(r,n){if(r<0)throw new L;if(n===0)return this.zero;var i=new Int32Array(r+1);return i[0]=n,new ct(this,i)},e.prototype.inverse=function(r){if(r===0)throw new na;return this.expTable[this.size-this.logTable[r]-1]},e.prototype.multiply=function(r,n){return r===0||n===0?0:this.expTable[(this.logTable[r]+this.logTable[n])%(this.size-1)]},e.prototype.getSize=function(){return this.size},e.prototype.getGeneratorBase=function(){return this.generatorBase},e.prototype.toString=function(){return"GF(0x"+G.toHexString(this.primitive)+","+this.size+")"},e.prototype.equals=function(r){return r===this},e.AZTEC_DATA_12=new e(4201,4096,1),e.AZTEC_DATA_10=new e(1033,1024,1),e.AZTEC_DATA_6=new e(67,64,1),e.AZTEC_PARAM=new e(19,16,1),e.QR_CODE_FIELD_256=new e(285,256,0),e.DATA_MATRIX_FIELD_256=new e(301,256,1),e.AZTEC_DATA_8=e.DATA_MATRIX_FIELD_256,e.MAXICODE_FIELD_64=e.AZTEC_DATA_6,e})(Zt),Ic=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),xr=(function(t){Ic(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.kind="ReedSolomonException",e})(Ie),Oc=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),fr=(function(t){Oc(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.kind="IllegalStateException",e})(Ie),Gr=(function(){function t(e){this.field=e}return t.prototype.decode=function(e,r){for(var n=this.field,i=new ct(n,e),a=new Int32Array(r),o=!0,s=0;s<r;s++){var c=i.evaluateAt(n.exp(s+n.getGeneratorBase()));a[a.length-1-s]=c,c!==0&&(o=!1)}if(!o)for(var u=new ct(n,a),l=this.runEuclideanAlgorithm(n.buildMonomial(r,1),u,r),d=l[0],v=l[1],h=this.findErrorLocations(d),p=this.findErrorMagnitudes(v,h),s=0;s<h.length;s++){var g=e.length-1-n.log(h[s]);if(g<0)throw new xr("Bad error location");e[g]=Ne.addOrSubtract(e[g],p[s])}},t.prototype.runEuclideanAlgorithm=function(e,r,n){if(e.getDegree()<r.getDegree()){var i=e;e=r,r=i}for(var a=this.field,o=e,s=r,c=a.getZero(),u=a.getOne();s.getDegree()>=(n/2|0);){var l=o,d=c;if(o=s,c=u,o.isZero())throw new xr("r_{i-1} was zero");s=l;for(var v=a.getZero(),h=o.getCoefficient(o.getDegree()),p=a.inverse(h);s.getDegree()>=o.getDegree()&&!s.isZero();){var g=s.getDegree()-o.getDegree(),y=a.multiply(s.getCoefficient(s.getDegree()),p);v=v.addOrSubtract(a.buildMonomial(g,y)),s=s.addOrSubtract(o.multiplyByMonomial(g,y))}if(u=v.multiply(c).addOrSubtract(d),s.getDegree()>=o.getDegree())throw new fr("Division algorithm failed to reduce polynomial?")}var w=u.getCoefficient(0);if(w===0)throw new xr("sigmaTilde(0) was zero");var m=a.inverse(w),_=u.multiplyScalar(m),A=s.multiplyScalar(m);return[_,A]},t.prototype.findErrorLocations=function(e){var r=e.getDegree();if(r===1)return Int32Array.from([e.getCoefficient(1)]);for(var n=new Int32Array(r),i=0,a=this.field,o=1;o<a.getSize()&&i<r;o++)e.evaluateAt(o)===0&&(n[i]=a.inverse(o),i++);if(i!==r)throw new xr("Error locator degree does not match number of roots");return n},t.prototype.findErrorMagnitudes=function(e,r){for(var n=r.length,i=new Int32Array(n),a=this.field,o=0;o<n;o++){for(var s=a.inverse(r[o]),c=1,u=0;u<n;u++)if(o!==u){var l=a.multiply(r[u],s),d=(l&1)===0?l|1:l&-2;c=a.multiply(c,d)}i[o]=a.multiply(e.evaluateAt(s),a.inverse(c)),a.getGeneratorBase()!==0&&(i[o]=a.multiply(i[o],s))}return i},t})(),xe;(function(t){t[t.UPPER=0]="UPPER",t[t.LOWER=1]="LOWER",t[t.MIXED=2]="MIXED",t[t.DIGIT=3]="DIGIT",t[t.PUNCT=4]="PUNCT",t[t.BINARY=5]="BINARY"})(xe||(xe={}));var li=(function(){function t(){}return t.prototype.decode=function(e){this.ddata=e;var r=e.getBits(),n=this.extractBits(r),i=this.correctBits(n),a=t.convertBoolArrayToByteArray(i),o=t.getEncodedData(i),s=new $r(a,o,null,null);return s.setNumBits(i.length),s},t.highLevelDecode=function(e){return this.getEncodedData(e)},t.getEncodedData=function(e){for(var r=e.length,n=xe.UPPER,i=xe.UPPER,a="",o=0;o<r;)if(i===xe.BINARY){if(r-o<5)break;var s=t.readCode(e,o,5);if(o+=5,s===0){if(r-o<11)break;s=t.readCode(e,o,11)+31,o+=11}for(var c=0;c<s;c++){if(r-o<8){o=r;break}var u=t.readCode(e,o,8);a+=te.castAsNonUtf8Char(u),o+=8}i=n}else{var l=i===xe.DIGIT?4:5;if(r-o<l)break;var u=t.readCode(e,o,l);o+=l;var d=t.getCharacter(i,u);d.startsWith("CTRL_")?(n=i,i=t.getTable(d.charAt(5)),d.charAt(6)==="L"&&(n=i)):(a+=d,i=n)}return a},t.getTable=function(e){switch(e){case"L":return xe.LOWER;case"P":return xe.PUNCT;case"M":return xe.MIXED;case"D":return xe.DIGIT;case"B":return xe.BINARY;case"U":default:return xe.UPPER}},t.getCharacter=function(e,r){switch(e){case xe.UPPER:return t.UPPER_TABLE[r];case xe.LOWER:return t.LOWER_TABLE[r];case xe.MIXED:return t.MIXED_TABLE[r];case xe.PUNCT:return t.PUNCT_TABLE[r];case xe.DIGIT:return t.DIGIT_TABLE[r];default:throw new fr("Bad table")}},t.prototype.correctBits=function(e){var r,n;this.ddata.getNbLayers()<=2?(n=6,r=Ne.AZTEC_DATA_6):this.ddata.getNbLayers()<=8?(n=8,r=Ne.AZTEC_DATA_8):this.ddata.getNbLayers()<=22?(n=10,r=Ne.AZTEC_DATA_10):(n=12,r=Ne.AZTEC_DATA_12);var i=this.ddata.getNbDatablocks(),a=e.length/n;if(a<i)throw new R;for(var o=e.length%n,s=new Int32Array(a),c=0;c<a;c++,o+=n)s[c]=t.readCode(e,o,n);try{var u=new Gr(r);u.decode(s,a-i)}catch(y){throw new R(y)}for(var l=(1<<n)-1,d=0,c=0;c<i;c++){var v=s[c];if(v===0||v===l)throw new R;(v===1||v===l-1)&&d++}for(var h=new Array(i*n-d),p=0,c=0;c<i;c++){var v=s[c];if(v===1||v===l-1)h.fill(v>1,p,p+n-1),p+=n-1;else for(var g=n-1;g>=0;--g)h[p++]=(v&1<<g)!==0}return h},t.prototype.extractBits=function(e){var r=this.ddata.isCompact(),n=this.ddata.getNbLayers(),i=(r?11:14)+n*4,a=new Int32Array(i),o=new Array(this.totalBitsInLayer(n,r));if(r)for(var s=0;s<a.length;s++)a[s]=s;else for(var c=i+1+2*G.truncDivision(G.truncDivision(i,2)-1,15),u=i/2,l=G.truncDivision(c,2),s=0;s<u;s++){var d=s+G.truncDivision(s,15);a[u-s-1]=l-d-1,a[u+s]=l+d+1}for(var s=0,v=0;s<n;s++){for(var h=(n-s)*4+(r?9:12),p=s*2,g=i-1-p,y=0;y<h;y++)for(var w=y*2,m=0;m<2;m++)o[v+w+m]=e.get(a[p+m],a[p+y]),o[v+2*h+w+m]=e.get(a[p+y],a[g-m]),o[v+4*h+w+m]=e.get(a[g-m],a[g-y]),o[v+6*h+w+m]=e.get(a[g-y],a[p+m]);v+=h*8}return o},t.readCode=function(e,r,n){for(var i=0,a=r;a<r+n;a++)i<<=1,e[a]&&(i|=1);return i},t.readByte=function(e,r){var n=e.length-r;return n>=8?t.readCode(e,r,8):t.readCode(e,r,n)<<8-n},t.convertBoolArrayToByteArray=function(e){for(var r=new Uint8Array((e.length+7)/8),n=0;n<r.length;n++)r[n]=t.readByte(e,8*n);return r},t.prototype.totalBitsInLayer=function(e,r){return((r?88:112)+16*e)*e},t.UPPER_TABLE=["CTRL_PS"," ","A","B","C","D","E","F","G","H","I","J","K","L","M","N","O","P","Q","R","S","T","U","V","W","X","Y","Z","CTRL_LL","CTRL_ML","CTRL_DL","CTRL_BS"],t.LOWER_TABLE=["CTRL_PS"," ","a","b","c","d","e","f","g","h","i","j","k","l","m","n","o","p","q","r","s","t","u","v","w","x","y","z","CTRL_US","CTRL_ML","CTRL_DL","CTRL_BS"],t.MIXED_TABLE=["CTRL_PS"," ","\\1","\\2","\\3","\\4","\\5","\\6","\\7","\b"," ",`
@@ -43,4 +43,4 @@
43
43
  `),e.append(`>>
44
44
  `),e.toString()},t.prototype.setMode=function(e){this.mode=e},t.prototype.setECLevel=function(e){this.ecLevel=e},t.prototype.setVersion=function(e){this.version=e},t.prototype.setMaskPattern=function(e){this.maskPattern=e},t.prototype.setMatrix=function(e){this.matrix=e},t.isValidMaskPattern=function(e){return e>=0&&e<t.NUM_MASK_PATTERNS},t.NUM_MASK_PATTERNS=8,t})(),$f=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),ie=(function(t){$f(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.kind="WriterException",e})(Ie),Ri=(function(){function t(){}return t.clearMatrix=function(e){e.clear(255)},t.buildMatrix=function(e,r,n,i,a){t.clearMatrix(a),t.embedBasicPatterns(n,a),t.embedTypeInfo(r,i,a),t.maybeEmbedVersionInfo(n,a),t.embedDataBits(e,i,a)},t.embedBasicPatterns=function(e,r){t.embedPositionDetectionPatternsAndSeparators(r),t.embedDarkDotAtLeftBottomCorner(r),t.maybeEmbedPositionAdjustmentPatterns(e,r),t.embedTimingPatterns(r)},t.embedTypeInfo=function(e,r,n){var i=new ge;t.makeTypeInfoBits(e,r,i);for(var a=0,o=i.getSize();a<o;++a){var s=i.get(i.getSize()-1-a),c=t.TYPE_INFO_COORDINATES[a],u=c[0],l=c[1];if(n.setBoolean(u,l,s),a<8){var d=n.getWidth()-a-1,v=8;n.setBoolean(d,v,s)}else{var d=8,v=n.getHeight()-7+(a-8);n.setBoolean(d,v,s)}}},t.maybeEmbedVersionInfo=function(e,r){if(!(e.getVersionNumber()<7)){var n=new ge;t.makeVersionInfoBits(e,n);for(var i=17,a=0;a<6;++a)for(var o=0;o<3;++o){var s=n.get(i);i--,r.setBoolean(a,r.getHeight()-11+o,s),r.setBoolean(r.getHeight()-11+o,a,s)}}},t.embedDataBits=function(e,r,n){for(var i=0,a=-1,o=n.getWidth()-1,s=n.getHeight()-1;o>0;){for(o===6&&(o-=1);s>=0&&s<n.getHeight();){for(var c=0;c<2;++c){var u=o-c;if(t.isEmpty(n.get(u,s))){var l=void 0;i<e.getSize()?(l=e.get(i),++i):l=!1,r!==255&&Jt.getDataMaskBit(r,u,s)&&(l=!l),n.setBoolean(u,s,l)}}s+=a}a=-a,s+=a,o-=2}if(i!==e.getSize())throw new ie("Not all bits consumed: "+i+"/"+e.getSize())},t.findMSBSet=function(e){return 32-G.numberOfLeadingZeros(e)},t.calculateBCHCode=function(e,r){if(r===0)throw new L("0 polynomial");var n=t.findMSBSet(r);for(e<<=n-1;t.findMSBSet(e)>=n;)e^=r<<t.findMSBSet(e)-n;return e},t.makeTypeInfoBits=function(e,r,n){if(!Pn.isValidMaskPattern(r))throw new ie("Invalid mask pattern");var i=e.getBits()<<3|r;n.appendBits(i,5);var a=t.calculateBCHCode(i,t.TYPE_INFO_POLY);n.appendBits(a,10);var o=new ge;if(o.appendBits(t.TYPE_INFO_MASK_PATTERN,15),n.xor(o),n.getSize()!==15)throw new ie("should not happen but we got: "+n.getSize())},t.makeVersionInfoBits=function(e,r){r.appendBits(e.getVersionNumber(),6);var n=t.calculateBCHCode(e.getVersionNumber(),t.VERSION_INFO_POLY);if(r.appendBits(n,12),r.getSize()!==18)throw new ie("should not happen but we got: "+r.getSize())},t.isEmpty=function(e){return e===255},t.embedTimingPatterns=function(e){for(var r=8;r<e.getWidth()-8;++r){var n=(r+1)%2;t.isEmpty(e.get(r,6))&&e.setNumber(r,6,n),t.isEmpty(e.get(6,r))&&e.setNumber(6,r,n)}},t.embedDarkDotAtLeftBottomCorner=function(e){if(e.get(8,e.getHeight()-8)===0)throw new ie;e.setNumber(8,e.getHeight()-8,1)},t.embedHorizontalSeparationPattern=function(e,r,n){for(var i=0;i<8;++i){if(!t.isEmpty(n.get(e+i,r)))throw new ie;n.setNumber(e+i,r,0)}},t.embedVerticalSeparationPattern=function(e,r,n){for(var i=0;i<7;++i){if(!t.isEmpty(n.get(e,r+i)))throw new ie;n.setNumber(e,r+i,0)}},t.embedPositionAdjustmentPattern=function(e,r,n){for(var i=0;i<5;++i)for(var a=t.POSITION_ADJUSTMENT_PATTERN[i],o=0;o<5;++o)n.setNumber(e+o,r+i,a[o])},t.embedPositionDetectionPattern=function(e,r,n){for(var i=0;i<7;++i)for(var a=t.POSITION_DETECTION_PATTERN[i],o=0;o<7;++o)n.setNumber(e+o,r+i,a[o])},t.embedPositionDetectionPatternsAndSeparators=function(e){var r=t.POSITION_DETECTION_PATTERN[0].length;t.embedPositionDetectionPattern(0,0,e),t.embedPositionDetectionPattern(e.getWidth()-r,0,e),t.embedPositionDetectionPattern(0,e.getWidth()-r,e);var n=8;t.embedHorizontalSeparationPattern(0,n-1,e),t.embedHorizontalSeparationPattern(e.getWidth()-n,n-1,e),t.embedHorizontalSeparationPattern(0,e.getWidth()-n,e);var i=7;t.embedVerticalSeparationPattern(i,0,e),t.embedVerticalSeparationPattern(e.getHeight()-i-1,0,e),t.embedVerticalSeparationPattern(i,e.getHeight()-i,e)},t.maybeEmbedPositionAdjustmentPatterns=function(e,r){if(!(e.getVersionNumber()<2))for(var n=e.getVersionNumber()-1,i=t.POSITION_ADJUSTMENT_PATTERN_COORDINATE_TABLE[n],a=0,o=i.length;a!==o;a++){var s=i[a];if(s>=0)for(var c=0;c!==o;c++){var u=i[c];u>=0&&t.isEmpty(r.get(u,s))&&t.embedPositionAdjustmentPattern(u-2,s-2,r)}}},t.POSITION_DETECTION_PATTERN=Array.from([Int32Array.from([1,1,1,1,1,1,1]),Int32Array.from([1,0,0,0,0,0,1]),Int32Array.from([1,0,1,1,1,0,1]),Int32Array.from([1,0,1,1,1,0,1]),Int32Array.from([1,0,1,1,1,0,1]),Int32Array.from([1,0,0,0,0,0,1]),Int32Array.from([1,1,1,1,1,1,1])]),t.POSITION_ADJUSTMENT_PATTERN=Array.from([Int32Array.from([1,1,1,1,1]),Int32Array.from([1,0,0,0,1]),Int32Array.from([1,0,1,0,1]),Int32Array.from([1,0,0,0,1]),Int32Array.from([1,1,1,1,1])]),t.POSITION_ADJUSTMENT_PATTERN_COORDINATE_TABLE=Array.from([Int32Array.from([-1,-1,-1,-1,-1,-1,-1]),Int32Array.from([6,18,-1,-1,-1,-1,-1]),Int32Array.from([6,22,-1,-1,-1,-1,-1]),Int32Array.from([6,26,-1,-1,-1,-1,-1]),Int32Array.from([6,30,-1,-1,-1,-1,-1]),Int32Array.from([6,34,-1,-1,-1,-1,-1]),Int32Array.from([6,22,38,-1,-1,-1,-1]),Int32Array.from([6,24,42,-1,-1,-1,-1]),Int32Array.from([6,26,46,-1,-1,-1,-1]),Int32Array.from([6,28,50,-1,-1,-1,-1]),Int32Array.from([6,30,54,-1,-1,-1,-1]),Int32Array.from([6,32,58,-1,-1,-1,-1]),Int32Array.from([6,34,62,-1,-1,-1,-1]),Int32Array.from([6,26,46,66,-1,-1,-1]),Int32Array.from([6,26,48,70,-1,-1,-1]),Int32Array.from([6,26,50,74,-1,-1,-1]),Int32Array.from([6,30,54,78,-1,-1,-1]),Int32Array.from([6,30,56,82,-1,-1,-1]),Int32Array.from([6,30,58,86,-1,-1,-1]),Int32Array.from([6,34,62,90,-1,-1,-1]),Int32Array.from([6,28,50,72,94,-1,-1]),Int32Array.from([6,26,50,74,98,-1,-1]),Int32Array.from([6,30,54,78,102,-1,-1]),Int32Array.from([6,28,54,80,106,-1,-1]),Int32Array.from([6,32,58,84,110,-1,-1]),Int32Array.from([6,30,58,86,114,-1,-1]),Int32Array.from([6,34,62,90,118,-1,-1]),Int32Array.from([6,26,50,74,98,122,-1]),Int32Array.from([6,30,54,78,102,126,-1]),Int32Array.from([6,26,52,78,104,130,-1]),Int32Array.from([6,30,56,82,108,134,-1]),Int32Array.from([6,34,60,86,112,138,-1]),Int32Array.from([6,30,58,86,114,142,-1]),Int32Array.from([6,34,62,90,118,146,-1]),Int32Array.from([6,30,54,78,102,126,150]),Int32Array.from([6,24,50,76,102,128,154]),Int32Array.from([6,28,54,80,106,132,158]),Int32Array.from([6,32,58,84,110,136,162]),Int32Array.from([6,26,54,82,110,138,166]),Int32Array.from([6,30,58,86,114,142,170])]),t.TYPE_INFO_COORDINATES=Array.from([Int32Array.from([8,0]),Int32Array.from([8,1]),Int32Array.from([8,2]),Int32Array.from([8,3]),Int32Array.from([8,4]),Int32Array.from([8,5]),Int32Array.from([8,7]),Int32Array.from([8,8]),Int32Array.from([7,8]),Int32Array.from([5,8]),Int32Array.from([4,8]),Int32Array.from([3,8]),Int32Array.from([2,8]),Int32Array.from([1,8]),Int32Array.from([0,8])]),t.VERSION_INFO_POLY=7973,t.TYPE_INFO_POLY=1335,t.TYPE_INFO_MASK_PATTERN=21522,t})(),Gf=(function(){function t(e,r){this.dataBytes=e,this.errorCorrectionBytes=r}return t.prototype.getDataBytes=function(){return this.dataBytes},t.prototype.getErrorCorrectionBytes=function(){return this.errorCorrectionBytes},t})(),Pi=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],n=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")};(function(){function t(){}return t.calculateMaskPenalty=function(e){return Jt.applyMaskPenaltyRule1(e)+Jt.applyMaskPenaltyRule2(e)+Jt.applyMaskPenaltyRule3(e)+Jt.applyMaskPenaltyRule4(e)},t.encode=function(e,r,n){n===void 0&&(n=null);var i=t.DEFAULT_BYTE_MODE_ENCODING,a=n!==null&&n.get(wr.CHARACTER_SET)!==void 0;a&&(i=n.get(wr.CHARACTER_SET).toString());var o=this.chooseMode(e,i),s=new ge;if(o===ae.BYTE&&(a||t.DEFAULT_BYTE_MODE_ENCODING!==i)){var c=he.getCharacterSetECIByName(i);c!==void 0&&this.appendECI(c,s)}this.appendModeInfo(o,s);var u=new ge;this.appendBytes(e,o,u,i);var l;if(n!==null&&n.get(wr.QR_VERSION)!==void 0){var d=Number.parseInt(n.get(wr.QR_VERSION).toString(),10);l=_t.getVersionForNumber(d);var v=this.calculateBitsNeeded(o,s,u,l);if(!this.willFit(v,l,r))throw new ie("Data too big for requested version")}else l=this.recommendVersion(r,o,s,u);var h=new ge;h.appendBitArray(s);var p=o===ae.BYTE?u.getSizeInBytes():e.length;this.appendLengthInfo(p,l,o,h),h.appendBitArray(u);var g=l.getECBlocksForLevel(r),y=l.getTotalCodewords()-g.getTotalECCodewords();this.terminateBits(y,h);var w=this.interleaveWithECBytes(h,l.getTotalCodewords(),y,g.getNumBlocks()),m=new Pn;m.setECLevel(r),m.setMode(o),m.setVersion(l);var _=l.getDimensionForVersion(),A=new Hf(_,_),I=this.chooseMaskPattern(w,r,l,A);return m.setMaskPattern(I),Ri.buildMatrix(w,r,l,I,A),m.setMatrix(A),m},t.recommendVersion=function(e,r,n,i){var a=this.calculateBitsNeeded(r,n,i,_t.getVersionForNumber(1)),o=this.chooseVersion(a,e),s=this.calculateBitsNeeded(r,n,i,o);return this.chooseVersion(s,e)},t.calculateBitsNeeded=function(e,r,n,i){return r.getSize()+e.getCharacterCountBits(i)+n.getSize()},t.getAlphanumericCode=function(e){return e<t.ALPHANUMERIC_TABLE.length?t.ALPHANUMERIC_TABLE[e]:-1},t.chooseMode=function(e,r){if(r===void 0&&(r=null),he.SJIS.getName()===r&&this.isOnlyDoubleByteKanji(e))return ae.KANJI;for(var n=!1,i=!1,a=0,o=e.length;a<o;++a){var s=e.charAt(a);if(t.isDigit(s))n=!0;else if(this.getAlphanumericCode(s.charCodeAt(0))!==-1)i=!0;else return ae.BYTE}return i?ae.ALPHANUMERIC:n?ae.NUMERIC:ae.BYTE},t.isOnlyDoubleByteKanji=function(e){var r;try{r=Ke.encode(e,he.SJIS)}catch{return!1}var n=r.length;if(n%2!==0)return!1;for(var i=0;i<n;i+=2){var a=r[i]&255;if((a<129||a>159)&&(a<224||a>235))return!1}return!0},t.chooseMaskPattern=function(e,r,n,i){for(var a=Number.MAX_SAFE_INTEGER,o=-1,s=0;s<Pn.NUM_MASK_PATTERNS;s++){Ri.buildMatrix(e,r,n,s,i);var c=this.calculateMaskPenalty(i);c<a&&(a=c,o=s)}return o},t.chooseVersion=function(e,r){for(var n=1;n<=40;n++){var i=_t.getVersionForNumber(n);if(t.willFit(e,i,r))return i}throw new ie("Data too big")},t.willFit=function(e,r,n){var i=r.getTotalCodewords(),a=r.getECBlocksForLevel(n),o=a.getTotalECCodewords(),s=i-o,c=(e+7)/8;return s>=c},t.terminateBits=function(e,r){var n=e*8;if(r.getSize()>n)throw new ie("data bits cannot fit in the QR Code"+r.getSize()+" > "+n);for(var i=0;i<4&&r.getSize()<n;++i)r.appendBit(!1);var a=r.getSize()&7;if(a>0)for(var i=a;i<8;i++)r.appendBit(!1);for(var o=e-r.getSizeInBytes(),i=0;i<o;++i)r.appendBits((i&1)===0?236:17,8);if(r.getSize()!==n)throw new ie("Bits size does not equal capacity")},t.getNumDataBytesAndNumECBytesForBlockID=function(e,r,n,i,a,o){if(i>=n)throw new ie("Block ID too large");var s=e%n,c=n-s,u=Math.floor(e/n),l=u+1,d=Math.floor(r/n),v=d+1,h=u-d,p=l-v;if(h!==p)throw new ie("EC bytes mismatch");if(n!==c+s)throw new ie("RS blocks mismatch");if(e!==(d+h)*c+(v+p)*s)throw new ie("Total bytes mismatch");i<c?(a[0]=d,o[0]=h):(a[0]=v,o[0]=p)},t.interleaveWithECBytes=function(e,r,n,i){var a,o,s,c;if(e.getSizeInBytes()!==n)throw new ie("Number of bits and data bytes does not match");for(var u=0,l=0,d=0,v=new Array,h=0;h<i;++h){var p=new Int32Array(1),g=new Int32Array(1);t.getNumDataBytesAndNumECBytesForBlockID(r,n,i,h,p,g);var y=p[0],w=new Uint8Array(y);e.toBytes(8*u,w,0,y);var m=t.generateECBytes(w,g[0]);v.push(new Gf(w,m)),l=Math.max(l,y),d=Math.max(d,m.length),u+=p[0]}if(n!==u)throw new ie("Data bytes does not match offset");for(var _=new ge,h=0;h<l;++h)try{for(var A=(a=void 0,Pi(v)),I=A.next();!I.done;I=A.next()){var D=I.value,w=D.getDataBytes();h<w.length&&_.appendBits(w[h],8)}}catch(F){a={error:F}}finally{try{I&&!I.done&&(o=A.return)&&o.call(A)}finally{if(a)throw a.error}}for(var h=0;h<d;++h)try{for(var B=(s=void 0,Pi(v)),P=B.next();!P.done;P=B.next()){var D=P.value,m=D.getErrorCorrectionBytes();h<m.length&&_.appendBits(m[h],8)}}catch(F){s={error:F}}finally{try{P&&!P.done&&(c=B.return)&&c.call(B)}finally{if(s)throw s.error}}if(r!==_.getSizeInBytes())throw new ie("Interleaving error: "+r+" and "+_.getSizeInBytes()+" differ.");return _},t.generateECBytes=function(e,r){for(var n=e.length,i=new Int32Array(n+r),a=0;a<n;a++)i[a]=e[a]&255;new ha(Ne.QR_CODE_FIELD_256).encode(i,r);for(var o=new Uint8Array(r),a=0;a<r;a++)o[a]=i[n+a];return o},t.appendModeInfo=function(e,r){r.appendBits(e.getBits(),4)},t.appendLengthInfo=function(e,r,n,i){var a=n.getCharacterCountBits(r);if(e>=1<<a)throw new ie(e+" is bigger than "+((1<<a)-1));i.appendBits(e,a)},t.appendBytes=function(e,r,n,i){switch(r){case ae.NUMERIC:t.appendNumericBytes(e,n);break;case ae.ALPHANUMERIC:t.appendAlphanumericBytes(e,n);break;case ae.BYTE:t.append8BitBytes(e,n,i);break;case ae.KANJI:t.appendKanjiBytes(e,n);break;default:throw new ie("Invalid mode: "+r)}},t.getDigit=function(e){return e.charCodeAt(0)-48},t.isDigit=function(e){var r=t.getDigit(e);return r>=0&&r<=9},t.appendNumericBytes=function(e,r){for(var n=e.length,i=0;i<n;){var a=t.getDigit(e.charAt(i));if(i+2<n){var o=t.getDigit(e.charAt(i+1)),s=t.getDigit(e.charAt(i+2));r.appendBits(a*100+o*10+s,10),i+=3}else if(i+1<n){var o=t.getDigit(e.charAt(i+1));r.appendBits(a*10+o,7),i+=2}else r.appendBits(a,4),i++}},t.appendAlphanumericBytes=function(e,r){for(var n=e.length,i=0;i<n;){var a=t.getAlphanumericCode(e.charCodeAt(i));if(a===-1)throw new ie;if(i+1<n){var o=t.getAlphanumericCode(e.charCodeAt(i+1));if(o===-1)throw new ie;r.appendBits(a*45+o,11),i+=2}else r.appendBits(a,6),i++}},t.append8BitBytes=function(e,r,n){var i;try{i=Ke.encode(e,n)}catch(c){throw new ie(c)}for(var a=0,o=i.length;a!==o;a++){var s=i[a];r.appendBits(s,8)}},t.appendKanjiBytes=function(e,r){var n;try{n=Ke.encode(e,he.SJIS)}catch(d){throw new ie(d)}for(var i=n.length,a=0;a<i;a+=2){var o=n[a]&255,s=n[a+1]&255,c=o<<8&4294967295|s,u=-1;if(c>=33088&&c<=40956?u=c-33088:c>=57408&&c<=60351&&(u=c-49472),u===-1)throw new ie("Invalid byte sequence");var l=(u>>8)*192+(u&255);r.appendBits(l,13)}},t.appendECI=function(e,r){r.appendBits(ae.ECI.getBits(),4),r.appendBits(e.getValue(),8)},t.ALPHANUMERIC_TABLE=Int32Array.from([-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,36,-1,-1,-1,37,38,-1,-1,-1,-1,39,40,-1,41,42,43,0,1,2,3,4,5,6,7,8,9,44,-1,-1,-1,-1,-1,-1,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24,25,26,27,28,29,30,31,32,33,34,35,-1,-1,-1,-1,-1]),t.DEFAULT_BYTE_MODE_ENCODING=he.UTF8.getName(),t})();var zf=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})();(function(t){zf(e,t);function e(r,n,i,a,o,s,c,u){var l=t.call(this,s,c)||this;if(l.yuvData=r,l.dataWidth=n,l.dataHeight=i,l.left=a,l.top=o,a+s>n||o+c>i)throw new L("Crop rectangle does not fit within image data.");return u&&l.reverseHorizontal(s,c),l}return e.prototype.getRow=function(r,n){if(r<0||r>=this.getHeight())throw new L("Requested row is outside the image: "+r);var i=this.getWidth();(n==null||n.length<i)&&(n=new Uint8ClampedArray(i));var a=(r+this.top)*this.dataWidth+this.left;return re.arraycopy(this.yuvData,a,n,0,i),n},e.prototype.getMatrix=function(){var r=this.getWidth(),n=this.getHeight();if(r===this.dataWidth&&n===this.dataHeight)return this.yuvData;var i=r*n,a=new Uint8ClampedArray(i),o=this.top*this.dataWidth+this.left;if(r===this.dataWidth)return re.arraycopy(this.yuvData,o,a,0,i),a;for(var s=0;s<n;s++){var c=s*r;re.arraycopy(this.yuvData,o,a,c,r),o+=this.dataWidth}return a},e.prototype.isCropSupported=function(){return!0},e.prototype.crop=function(r,n,i,a){return new e(this.yuvData,this.dataWidth,this.dataHeight,this.left+r,this.top+n,i,a,!1)},e.prototype.renderThumbnail=function(){for(var r=this.getWidth()/e.THUMBNAIL_SCALE_FACTOR,n=this.getHeight()/e.THUMBNAIL_SCALE_FACTOR,i=new Int32Array(r*n),a=this.yuvData,o=this.top*this.dataWidth+this.left,s=0;s<n;s++){for(var c=s*r,u=0;u<r;u++){var l=a[o+u*e.THUMBNAIL_SCALE_FACTOR]&255;i[c+u]=4278190080|l*65793}o+=this.dataWidth*e.THUMBNAIL_SCALE_FACTOR}return i},e.prototype.getThumbnailWidth=function(){return this.getWidth()/e.THUMBNAIL_SCALE_FACTOR},e.prototype.getThumbnailHeight=function(){return this.getHeight()/e.THUMBNAIL_SCALE_FACTOR},e.prototype.reverseHorizontal=function(r,n){for(var i=this.yuvData,a=0,o=this.top*this.dataWidth+this.left;a<n;a++,o+=this.dataWidth)for(var s=o+r/2,c=o,u=o+r-1;c<s;c++,u--){var l=i[c];i[c]=i[u],i[u]=l}},e.prototype.invert=function(){return new Hn(this)},e.THUMBNAIL_SCALE_FACTOR=2,e})(Hr);var Wf=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})();(function(t){Wf(e,t);function e(r,n,i,a,o,s,c){var u=t.call(this,n,i)||this;if(u.dataWidth=a,u.dataHeight=o,u.left=s,u.top=c,r.BYTES_PER_ELEMENT===4){for(var l=n*i,d=new Uint8ClampedArray(l),v=0;v<l;v++){var h=r[v],p=h>>16&255,g=h>>7&510,y=h&255;d[v]=(p+g+y)/4&255}u.luminances=d}else u.luminances=r;if(a===void 0&&(u.dataWidth=n),o===void 0&&(u.dataHeight=i),s===void 0&&(u.left=0),c===void 0&&(u.top=0),u.left+n>u.dataWidth||u.top+i>u.dataHeight)throw new L("Crop rectangle does not fit within image data.");return u}return e.prototype.getRow=function(r,n){if(r<0||r>=this.getHeight())throw new L("Requested row is outside the image: "+r);var i=this.getWidth();(n==null||n.length<i)&&(n=new Uint8ClampedArray(i));var a=(r+this.top)*this.dataWidth+this.left;return re.arraycopy(this.luminances,a,n,0,i),n},e.prototype.getMatrix=function(){var r=this.getWidth(),n=this.getHeight();if(r===this.dataWidth&&n===this.dataHeight)return this.luminances;var i=r*n,a=new Uint8ClampedArray(i),o=this.top*this.dataWidth+this.left;if(r===this.dataWidth)return re.arraycopy(this.luminances,o,a,0,i),a;for(var s=0;s<n;s++){var c=s*r;re.arraycopy(this.luminances,o,a,c,r),o+=this.dataWidth}return a},e.prototype.isCropSupported=function(){return!0},e.prototype.crop=function(r,n,i,a){return new e(this.luminances,i,a,this.dataWidth,this.dataHeight,this.left+r,this.top+n)},e.prototype.invert=function(){return new Hn(this)},e})(Hr);var Xf=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})();(function(t){Xf(e,t);function e(){return t!==null&&t.apply(this,arguments)||this}return e.forName=function(r){return this.getCharacterSetECIByName(r)},e})(he);(function(){function t(){}return t.ISO_8859_1=he.ISO8859_1,t})();var jf=(function(){function t(){}return t.prototype.isCompact=function(){return this.compact},t.prototype.setCompact=function(e){this.compact=e},t.prototype.getSize=function(){return this.size},t.prototype.setSize=function(e){this.size=e},t.prototype.getLayers=function(){return this.layers},t.prototype.setLayers=function(e){this.layers=e},t.prototype.getCodeWords=function(){return this.codeWords},t.prototype.setCodeWords=function(e){this.codeWords=e},t.prototype.getMatrix=function(){return this.matrix},t.prototype.setMatrix=function(e){this.matrix=e},t})(),ki=(function(){function t(){}return t.singletonList=function(e){return[e]},t.min=function(e,r){return e.sort(r)[0]},t})(),Yf=(function(){function t(e){this.previous=e}return t.prototype.getPrevious=function(){return this.previous},t})(),Kf=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),Xn=(function(t){Kf(e,t);function e(r,n,i){var a=t.call(this,r)||this;return a.value=n,a.bitCount=i,a}return e.prototype.appendTo=function(r,n){r.appendBits(this.value,this.bitCount)},e.prototype.add=function(r,n){return new e(this,r,n)},e.prototype.addBinaryShift=function(r,n){return console.warn("addBinaryShift on SimpleToken, this simply returns a copy of this token"),new e(this,r,n)},e.prototype.toString=function(){var r=this.value&(1<<this.bitCount)-1;return r|=1<<this.bitCount,"<"+G.toBinaryString(r|1<<this.bitCount).substring(1)+">"},e})(Yf),Zf=(function(){var t=function(e,r){return t=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(n,i){n.__proto__=i}||function(n,i){for(var a in i)i.hasOwnProperty(a)&&(n[a]=i[a])},t(e,r)};return function(e,r){t(e,r);function n(){this.constructor=e}e.prototype=r===null?Object.create(r):(n.prototype=r.prototype,new n)}})(),qf=(function(t){Zf(e,t);function e(r,n,i){var a=t.call(this,r,0,0)||this;return a.binaryShiftStart=n,a.binaryShiftByteCount=i,a}return e.prototype.appendTo=function(r,n){for(var i=0;i<this.binaryShiftByteCount;i++)(i===0||i===31&&this.binaryShiftByteCount<=62)&&(r.appendBits(31,5),this.binaryShiftByteCount>62?r.appendBits(this.binaryShiftByteCount-31,16):i===0?r.appendBits(Math.min(this.binaryShiftByteCount,31),5):r.appendBits(this.binaryShiftByteCount-31,5)),r.appendBits(n[this.binaryShiftStart+i],8)},e.prototype.addBinaryShift=function(r,n){return new e(this,r,n)},e.prototype.toString=function(){return"<"+this.binaryShiftStart+"::"+(this.binaryShiftStart+this.binaryShiftByteCount-1)+">"},e})(Xn);function Qf(t,e,r){return new qf(t,e,r)}function Xt(t,e,r){return new Xn(t,e,r)}var Jf=["UPPER","LOWER","DIGIT","MIXED","PUNCT"],ut=0,kr=1,Le=2,va=3,je=4,e0=new Xn(null,0,0),ln=[Int32Array.from([0,(5<<16)+28,(5<<16)+30,(5<<16)+29,656318]),Int32Array.from([(9<<16)+480+14,0,(5<<16)+30,(5<<16)+29,656318]),Int32Array.from([(4<<16)+14,(9<<16)+448+28,0,(9<<16)+448+29,932798]),Int32Array.from([(5<<16)+29,(5<<16)+28,656318,0,(5<<16)+30]),Int32Array.from([(5<<16)+31,656380,656382,656381,0])],t0=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],n=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")};function r0(t){var e,r;try{for(var n=t0(t),i=n.next();!i.done;i=n.next()){var a=i.value;Be.fill(a,-1)}}catch(o){e={error:o}}finally{try{i&&!i.done&&(r=n.return)&&r.call(n)}finally{if(e)throw e.error}}return t[ut][je]=0,t[kr][je]=0,t[kr][ut]=28,t[va][je]=0,t[Le][je]=0,t[Le][ut]=15,t}var pa=r0(Be.createInt32Array(6,6)),n0=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],n=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},i0=(function(){function t(e,r,n,i){this.token=e,this.mode=r,this.binaryShiftByteCount=n,this.bitCount=i}return t.prototype.getMode=function(){return this.mode},t.prototype.getToken=function(){return this.token},t.prototype.getBinaryShiftByteCount=function(){return this.binaryShiftByteCount},t.prototype.getBitCount=function(){return this.bitCount},t.prototype.latchAndAppend=function(e,r){var n=this.bitCount,i=this.token;if(e!==this.mode){var a=ln[this.mode][e];i=Xt(i,a&65535,a>>16),n+=a>>16}var o=e===Le?4:5;return i=Xt(i,r,o),new t(i,e,0,n+o)},t.prototype.shiftAndAppend=function(e,r){var n=this.token,i=this.mode===Le?4:5;return n=Xt(n,pa[this.mode][e],i),n=Xt(n,r,5),new t(n,this.mode,0,this.bitCount+i+5)},t.prototype.addBinaryShiftChar=function(e){var r=this.token,n=this.mode,i=this.bitCount;if(this.mode===je||this.mode===Le){var a=ln[n][ut];r=Xt(r,a&65535,a>>16),i+=a>>16,n=ut}var o=this.binaryShiftByteCount===0||this.binaryShiftByteCount===31?18:this.binaryShiftByteCount===62?9:8,s=new t(r,n,this.binaryShiftByteCount+1,i+o);return s.binaryShiftByteCount===2078&&(s=s.endBinaryShift(e+1)),s},t.prototype.endBinaryShift=function(e){if(this.binaryShiftByteCount===0)return this;var r=this.token;return r=Qf(r,e-this.binaryShiftByteCount,this.binaryShiftByteCount),new t(r,this.mode,0,this.bitCount)},t.prototype.isBetterThanOrEqualTo=function(e){var r=this.bitCount+(ln[this.mode][e.mode]>>16);return this.binaryShiftByteCount<e.binaryShiftByteCount?r+=t.calculateBinaryShiftCost(e)-t.calculateBinaryShiftCost(this):this.binaryShiftByteCount>e.binaryShiftByteCount&&e.binaryShiftByteCount>0&&(r+=10),r<=e.bitCount},t.prototype.toBitArray=function(e){for(var r,n,i=[],a=this.endBinaryShift(e.length).token;a!==null;a=a.getPrevious())i.unshift(a);var o=new ge;try{for(var s=n0(i),c=s.next();!c.done;c=s.next()){var u=c.value;u.appendTo(o,e)}}catch(l){r={error:l}}finally{try{c&&!c.done&&(n=s.return)&&n.call(s)}finally{if(r)throw r.error}}return o},t.prototype.toString=function(){return te.format("%s bits=%d bytes=%d",Jf[this.mode],this.bitCount,this.binaryShiftByteCount)},t.calculateBinaryShiftCost=function(e){return e.binaryShiftByteCount>62?21:e.binaryShiftByteCount>31?20:e.binaryShiftByteCount>0?10:0},t.INITIAL_STATE=new t(e0,ut,0,0),t})();function a0(t){var e=te.getCharCode(" "),r=te.getCharCode("."),n=te.getCharCode(",");t[ut][e]=1;for(var i=te.getCharCode("Z"),a=te.getCharCode("A"),o=a;o<=i;o++)t[ut][o]=o-a+2;t[kr][e]=1;for(var s=te.getCharCode("z"),c=te.getCharCode("a"),o=c;o<=s;o++)t[kr][o]=o-c+2;t[Le][e]=1;for(var u=te.getCharCode("9"),l=te.getCharCode("0"),o=l;o<=u;o++)t[Le][o]=o-l+2;t[Le][n]=12,t[Le][r]=13;for(var d=["\0"," ","","","","","","","\x07","\b"," ",`
45
45
  `,"\v","\f","\r","\x1B","","","","","@","\\","^","_","`","|","~",""],v=0;v<d.length;v++)t[va][te.getCharCode(d[v])]=v;for(var h=["\0","\r","\0","\0","\0","\0","!","'","#","$","%","&","'","(",")","*","+",",","-",".","/",":",";","<","=",">","?","[","]","{","}"],v=0;v<h.length;v++)te.getCharCode(h[v])>0&&(t[je][te.getCharCode(h[v])]=v);return t}var dn=a0(Be.createInt32Array(5,256)),_r=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],n=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")},o0=(function(){function t(e){this.text=e}return t.prototype.encode=function(){for(var e=te.getCharCode(" "),r=te.getCharCode(`
46
- `),n=ki.singletonList(i0.INITIAL_STATE),i=0;i<this.text.length;i++){var a=void 0,o=i+1<this.text.length?this.text[i+1]:0;switch(this.text[i]){case te.getCharCode("\r"):a=o===r?2:0;break;case te.getCharCode("."):a=o===e?3:0;break;case te.getCharCode(","):a=o===e?4:0;break;case te.getCharCode(":"):a=o===e?5:0;break;default:a=0}a>0?(n=t.updateStateListForPair(n,i,a),i++):n=this.updateStateListForChar(n,i)}var s=ki.min(n,function(c,u){return c.getBitCount()-u.getBitCount()});return s.toBitArray(this.text)},t.prototype.updateStateListForChar=function(e,r){var n,i,a=[];try{for(var o=_r(e),s=o.next();!s.done;s=o.next()){var c=s.value;this.updateStateForChar(c,r,a)}}catch(u){n={error:u}}finally{try{s&&!s.done&&(i=o.return)&&i.call(o)}finally{if(n)throw n.error}}return t.simplifyStates(a)},t.prototype.updateStateForChar=function(e,r,n){for(var i=this.text[r]&255,a=dn[e.getMode()][i]>0,o=null,s=0;s<=je;s++){var c=dn[s][i];if(c>0){if(o==null&&(o=e.endBinaryShift(r)),!a||s===e.getMode()||s===Le){var u=o.latchAndAppend(s,c);n.push(u)}if(!a&&pa[e.getMode()][s]>=0){var l=o.shiftAndAppend(s,c);n.push(l)}}}if(e.getBinaryShiftByteCount()>0||dn[e.getMode()][i]===0){var d=e.addBinaryShiftChar(r);n.push(d)}},t.updateStateListForPair=function(e,r,n){var i,a,o=[];try{for(var s=_r(e),c=s.next();!c.done;c=s.next()){var u=c.value;this.updateStateForPair(u,r,n,o)}}catch(l){i={error:l}}finally{try{c&&!c.done&&(a=s.return)&&a.call(s)}finally{if(i)throw i.error}}return this.simplifyStates(o)},t.updateStateForPair=function(e,r,n,i){var a=e.endBinaryShift(r);if(i.push(a.latchAndAppend(je,n)),e.getMode()!==je&&i.push(a.shiftAndAppend(je,n)),n===3||n===4){var o=a.latchAndAppend(Le,16-n).latchAndAppend(Le,1);i.push(o)}if(e.getBinaryShiftByteCount()>0){var s=e.addBinaryShiftChar(r).addBinaryShiftChar(r+1);i.push(s)}},t.simplifyStates=function(e){var r,n,i,a,o=[];try{for(var s=_r(e),c=s.next();!c.done;c=s.next()){var u=c.value,l=!0,d=function(y){if(y.isBetterThanOrEqualTo(u))return l=!1,"break";u.isBetterThanOrEqualTo(y)&&(o=o.filter(function(w){return w!==y}))};try{for(var v=(i=void 0,_r(o)),h=v.next();!h.done;h=v.next()){var p=h.value,g=d(p);if(g==="break")break}}catch(y){i={error:y}}finally{try{h&&!h.done&&(a=v.return)&&a.call(v)}finally{if(i)throw i.error}}l&&o.push(u)}}catch(y){r={error:y}}finally{try{c&&!c.done&&(n=s.return)&&n.call(s)}finally{if(r)throw r.error}}return o},t})(),s0=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],n=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")};(function(){function t(){}return t.encodeBytes=function(e){return t.encode(e,t.DEFAULT_EC_PERCENT,t.DEFAULT_AZTEC_LAYERS)},t.encode=function(e,r,n){var i=new o0(e).encode(),a=G.truncDivision(i.getSize()*r,100)+11,o=i.getSize()+a,s,c,u,l,d;if(n!==t.DEFAULT_AZTEC_LAYERS){if(s=n<0,c=Math.abs(n),c>(s?t.MAX_NB_BITS_COMPACT:t.MAX_NB_BITS))throw new L(te.format("Illegal value %s for layers",n));u=t.totalBitsInLayer(c,s),l=t.WORD_SIZE[c];var v=u-u%l;if(d=t.stuffBits(i,l),d.getSize()+a>v)throw new L("Data to large for user specified layer");if(s&&d.getSize()>l*64)throw new L("Data to large for user specified layer")}else{l=0,d=null;for(var h=0;;h++){if(h>t.MAX_NB_BITS)throw new L("Data too large for an Aztec code");if(s=h<=3,c=s?h+1:h,u=t.totalBitsInLayer(c,s),!(o>u)){(d==null||l!==t.WORD_SIZE[c])&&(l=t.WORD_SIZE[c],d=t.stuffBits(i,l));var v=u-u%l;if(!(s&&d.getSize()>l*64)&&d.getSize()+a<=v)break}}}var p=t.generateCheckWords(d,u,l),g=d.getSize()/l,y=t.generateModeMessage(s,c,g),w=(s?11:14)+c*4,m=new Int32Array(w),_;if(s){_=w;for(var h=0;h<m.length;h++)m[h]=h}else{_=w+1+2*G.truncDivision(G.truncDivision(w,2)-1,15);for(var A=G.truncDivision(w,2),I=G.truncDivision(_,2),h=0;h<A;h++){var D=h+G.truncDivision(h,15);m[A-h-1]=I-D-1,m[A+h]=I+D+1}}for(var B=new Ze(_),h=0,P=0;h<c;h++){for(var $=(c-h)*4+(s?9:12),F=0;F<$;F++)for(var ne=F*2,V=0;V<2;V++)p.get(P+ne+V)&&B.set(m[h*2+V],m[h*2+F]),p.get(P+$*2+ne+V)&&B.set(m[h*2+F],m[w-1-h*2-V]),p.get(P+$*4+ne+V)&&B.set(m[w-1-h*2-V],m[w-1-h*2-F]),p.get(P+$*6+ne+V)&&B.set(m[w-1-h*2-F],m[h*2+V]);P+=$*8}if(t.drawModeMessage(B,s,_,y),s)t.drawBullsEye(B,G.truncDivision(_,2),5);else{t.drawBullsEye(B,G.truncDivision(_,2),7);for(var h=0,F=0;h<G.truncDivision(w,2)-1;h+=15,F+=16)for(var V=G.truncDivision(_,2)&1;V<_;V+=2)B.set(G.truncDivision(_,2)-F,V),B.set(G.truncDivision(_,2)+F,V),B.set(V,G.truncDivision(_,2)-F),B.set(V,G.truncDivision(_,2)+F)}var Y=new jf;return Y.setCompact(s),Y.setSize(_),Y.setLayers(c),Y.setCodeWords(g),Y.setMatrix(B),Y},t.drawBullsEye=function(e,r,n){for(var i=0;i<n;i+=2)for(var a=r-i;a<=r+i;a++)e.set(a,r-i),e.set(a,r+i),e.set(r-i,a),e.set(r+i,a);e.set(r-n,r-n),e.set(r-n+1,r-n),e.set(r-n,r-n+1),e.set(r+n,r-n),e.set(r+n,r-n+1),e.set(r+n,r+n-1)},t.generateModeMessage=function(e,r,n){var i=new ge;return e?(i.appendBits(r-1,2),i.appendBits(n-1,6),i=t.generateCheckWords(i,28,4)):(i.appendBits(r-1,5),i.appendBits(n-1,11),i=t.generateCheckWords(i,40,4)),i},t.drawModeMessage=function(e,r,n,i){var a=G.truncDivision(n,2);if(r)for(var o=0;o<7;o++){var s=a-3+o;i.get(o)&&e.set(s,a-5),i.get(o+7)&&e.set(a+5,s),i.get(20-o)&&e.set(s,a+5),i.get(27-o)&&e.set(a-5,s)}else for(var o=0;o<10;o++){var s=a-5+o+G.truncDivision(o,5);i.get(o)&&e.set(s,a-7),i.get(o+10)&&e.set(a+7,s),i.get(29-o)&&e.set(s,a+7),i.get(39-o)&&e.set(a-7,s)}},t.generateCheckWords=function(e,r,n){var i,a,o=e.getSize()/n,s=new ha(t.getGF(n)),c=G.truncDivision(r,n),u=t.bitsToWords(e,n,c);s.encode(u,c-o);var l=r%n,d=new ge;d.appendBits(0,l);try{for(var v=s0(Array.from(u)),h=v.next();!h.done;h=v.next()){var p=h.value;d.appendBits(p,n)}}catch(g){i={error:g}}finally{try{h&&!h.done&&(a=v.return)&&a.call(v)}finally{if(i)throw i.error}}return d},t.bitsToWords=function(e,r,n){var i=new Int32Array(n),a,o;for(a=0,o=e.getSize()/r;a<o;a++){for(var s=0,c=0;c<r;c++)s|=e.get(a*r+c)?1<<r-c-1:0;i[a]=s}return i},t.getGF=function(e){switch(e){case 4:return Ne.AZTEC_PARAM;case 6:return Ne.AZTEC_DATA_6;case 8:return Ne.AZTEC_DATA_8;case 10:return Ne.AZTEC_DATA_10;case 12:return Ne.AZTEC_DATA_12;default:throw new L("Unsupported word size "+e)}},t.stuffBits=function(e,r){for(var n=new ge,i=e.getSize(),a=(1<<r)-2,o=0;o<i;o+=r){for(var s=0,c=0;c<r;c++)(o+c>=i||e.get(o+c))&&(s|=1<<r-1-c);(s&a)===a?(n.appendBits(s&a,r),o--):(s&a)===0?(n.appendBits(s|1,r),o--):n.appendBits(s,r)}return n},t.totalBitsInLayer=function(e,r){return((r?88:112)+16*e)*e},t.DEFAULT_EC_PERCENT=33,t.DEFAULT_AZTEC_LAYERS=0,t.MAX_NB_BITS=32,t.MAX_NB_BITS_COMPACT=4,t.WORD_SIZE=Int32Array.from([4,6,6,8,8,8,8,8,8,10,10,10,10,10,10,10,10,10,10,10,10,10,10,12,12,12,12,12,12,12,12,12,12]),t})();const c0=(t,e)=>{const r=t.__vccOpts||t;for(const[n,i]of e)r[n]=i;return r},u0={name:"stream-barcode-reader",data(){return{isLoading:!0,codeReader:new Lf,isMediaStreamAPISupported:navigator&&navigator.mediaDevices&&"enumerateDevices"in navigator.mediaDevices}},mounted(){if(!this.isMediaStreamAPISupported)throw new Ie("Media Stream API is not supported");this.start(),this.$refs.scanner.oncanplay=t=>{this.isLoading=!1,this.$emit("loaded")}},beforeUnmount(){this.codeReader.reset()},methods:{start(){this.codeReader.decodeFromVideoDevice(void 0,this.$refs.scanner,(t,e)=>{t&&(this.$emit("decode",t.text),this.$emit("result",t))})}}},f0={class:"scanner-container"},l0={poster:"data:image/gif,AAAA",ref:"scanner"};function d0(t,e,r,n,i,a){return f.openBlock(),f.createElementBlock("div",f0,[f.withDirectives(f.createElementVNode("div",null,[f.createElementVNode("video",l0,null,512),e[0]||(e[0]=f.createElementVNode("div",{class:"overlay-element"},null,-1)),e[1]||(e[1]=f.createElementVNode("div",{class:"laser"},null,-1))],512),[[f.vShow,!i.isLoading]])])}const h0=c0(u0,[["render",d0],["__scopeId","data-v-3b725b25"]]),v0={key:0,class:"scanner-modal"},p0={class:"scanner-header"},g0={class:"scanner-title"},x0={key:0,class:"scanner-subtitle"},y0={class:"scanner-stream"},m0={class:"scanner-overlay"},w0={key:0,class:"scanner-slot"},_0={class:"scanner-manual"},E0={key:0},A0=f.defineComponent({__name:"DsgBarcodeScanner",props:{failTitle:{},failSubtitle:{},onScan:{type:Function}},setup(t,{expose:e}){const r=t,n=f.ref(!1),i=f.ref(""),a=f.ref("");f.ref(null);const o=f.ref(""),s=f.ref(!1),c=f.ref(!1),u=f.ref(!1),l=f.ref(r.failTitle??"Scan Failed"),d=f.ref(r.failSubtitle??"Please try again or enter the barcode manually."),v=f.ref(null),h={theme:"error",type:"light",size:"lg",icon:{icon:"alert-circle",size:"sm"}};f.watch(()=>r.failTitle,V=>{V&&(l.value=V)}),f.watch(()=>r.failSubtitle,V=>{V&&(d.value=V)});const p={label:"Re-scan",theme:"destructive"},g={label:"Input manually",theme:"gray"};function y(V){i.value=V.title,a.value=V.subtitle??"",o.value="",s.value=!1,n.value=!0}function w(V){I({type:"scanned",value:V})}function m(){o.value.trim()&&(_(),I({type:"manual",value:o.value.trim()}))}function _(){s.value=!s.value,s.value&&(o.value="")}function A(){I({type:"cancelled"})}function I(V){console.log("Scan result:",V),r.onScan&&r.onScan(V)}function D(){n.value=!1}function B(){c.value=!0,setTimeout(()=>{c.value=!1},3e3)}function P(){v.value?.open()}function $(){u.value=!0}function F(){u.value=!1}e({scan:y,close:D,success:B,error:P,showSlot:$,hideSlot:F});const ne=()=>{document.documentElement.style.setProperty("--vh",`${window.innerHeight*.01}px`)};return f.onMounted(()=>{ne(),window.addEventListener("resize",ne)}),f.onBeforeUnmount(()=>{window.removeEventListener("resize",ne)}),(V,Y)=>(f.openBlock(),f.createBlock(f.Teleport,{to:"body"},[n.value?(f.openBlock(),f.createElementBlock("div",v0,[f.createVNode(ra,{ref_key:"modalRef",ref:v,title:l.value,description:d.value,"misc-icon":h,onClose:A,footerType:"vertical","primary-button":p,"secondary-button":g,onPrimaryButtonClicked:Y[0]||(Y[0]=Ee=>v.value?.close()),onSecondaryButtonClicked:Y[1]||(Y[1]=Ee=>{_(),v.value?.close()}),width:500},null,8,["title","description"]),f.createElementVNode("div",p0,[f.createElementVNode("div",null,[f.createElementVNode("h2",g0,f.toDisplayString(i.value),1),a.value?(f.openBlock(),f.createElementBlock("p",x0,f.toDisplayString(a.value),1)):f.createCommentVNode("",!0)]),f.createElementVNode("button",{class:"scanner-close",onClick:A,"aria-label":"Close"}," × ")]),f.createElementVNode("div",y0,[f.createVNode(f.unref(h0),{class:"scanner-video",onDecode:w}),f.createElementVNode("div",m0,[u.value?(f.openBlock(),f.createElementBlock("div",w0,[f.renderSlot(V.$slots,"default")])):f.createCommentVNode("",!0),f.createElementVNode("div",_0,[s.value?f.createCommentVNode("",!0):(f.openBlock(),f.createElementBlock("span",E0,"No barcode?")),s.value?f.createCommentVNode("",!0):(f.openBlock(),f.createBlock(M._sfc_main$3,{key:1,label:"Input manually",onClick:_,"icon-before":"pencil-01",theme:"gray-secondary"})),s.value?(f.openBlock(),f.createBlock(M._sfc_main$4,{key:2,modelValue:o.value,"onUpdate:modelValue":Y[2]||(Y[2]=Ee=>o.value=Ee),placeholder:"Enter barcode manually",class:"w-full"},null,8,["modelValue"])):f.createCommentVNode("",!0),s.value?(f.openBlock(),f.createBlock(M._sfc_main$3,{key:3,label:"Submit",onClick:m,"icon-before":"check",theme:"gray-secondary"})):f.createCommentVNode("",!0)]),c.value?(f.openBlock(),f.createBlock(M._sfc_main,{key:1,icon:"check",size:"3xl",class:"scanner-success"})):f.createCommentVNode("",!0)])])])):f.createCommentVNode("",!0)]))}}),ga=f.defineComponent({__name:"DsgCard",props:{variant:{default:"default"},hoverable:{type:Boolean,default:!1}},setup(t){return(e,r)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(["dsg-card",[`dsg-card--${t.variant}`,{"dsg-card--hoverable":t.hoverable}]])},[f.renderSlot(e.$slots,"default")],2))}}),C0=f.defineComponent({__name:"DsgCardContainer",props:{columns:{default:1},gap:{},items:{},itemKey:{default:null},cardProps:{default:()=>({})}},setup(t){return(e,r)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(["dsg-card-container",`dsg-card-container--cols-${t.columns} dsg-card-container--gap-${t.gap}`])},[(f.openBlock(!0),f.createElementBlock(f.Fragment,null,f.renderList(t.items,(n,i)=>(f.openBlock(),f.createBlock(ga,f.mergeProps({key:t.itemKey?n[t.itemKey]:i},{ref_for:!0},t.cardProps),{default:f.withCtx(()=>[f.renderSlot(e.$slots,"default",{item:n,index:i})]),_:2},1040))),128))],2))}}),b0={class:"dsg-breadcrumbs"},S0={key:1},I0=f.defineComponent({__name:"DsgBreadcrumb",props:{breadcrumbs:{default:()=>[]},divider:{default:()=>({icon:"slash-divider",size:"sm"})},theme:{default:"text"}},setup(t){return(e,r)=>(f.openBlock(),f.createElementBlock("div",b0,[(f.openBlock(!0),f.createElementBlock(f.Fragment,null,f.renderList(t.breadcrumbs,(n,i)=>(f.openBlock(),f.createElementBlock(f.Fragment,{key:`breadcrumb-item-${i}`},[(f.openBlock(),f.createBlock(f.resolveDynamicComponent(n.url??!1?"a":"span"),{href:n.url??null,disabled:n.disabled,class:f.normalizeClass(["dsg-breadcrumbs__button-base",`dsg-breadcrumbs__button-base--${t.theme}`,`${n.active??i===t.breadcrumbs.length-1?"dsg-breadcrumbs__button-base--active":""}`].join(" "))},{default:f.withCtx(()=>[n.icon&&n.useIcon?(f.openBlock(),f.createBlock(M._sfc_main,{key:0,icon:n.icon,size:"sm",class:"dsg-breadcrumbs__icon"},null,8,["icon"])):(f.openBlock(),f.createElementBlock("span",S0,f.toDisplayString(n.label),1))]),_:2},1032,["href","disabled","class"])),i<t.breadcrumbs.length-1?(f.openBlock(),f.createBlock(M._sfc_main,f.mergeProps({key:0,ref_for:!0},t.divider,{class:"dsg-breadcrumbs__divider"}),null,16)):f.createCommentVNode("",!0)],64))),128))]))}}),O0={class:"dsg-tab__mobile"},T0=["value"],N0=["value","textContent","title"],D0={class:"dsg-tab__desktop"},B0={class:"dsg-tab__desktop-wrapper"},R0=["href","onClick","aria-current"],P0=["textContent"],k0=["textContent"],M0={key:0,class:"dsg-tab--content"},L0=f.defineComponent({__name:"DsgTab",props:{tabs:{default:()=>[]},style:{default:"tabs"},preventVisits:{type:Boolean,default:!0},useWindowLocation:{type:Boolean,default:!1},replaceState:{type:Boolean,default:!1},replaceStrategy:{default:"window"},useSlots:{type:Boolean,default:!1},selfUpdate:{type:Boolean,default:!0},teleportSlotTo:{}},emits:["tab-clicked"],setup(t,{emit:e}){const r=e,n=s=>{t.tabs.forEach(c=>{c.current=s.name===c.name})},i=s=>{if(!s.tooltip)return;const c=s.tooltip.supportingTextHtml&&s.tooltip.supportingText?s.tooltip.supportingText.replace(/<br\s*\/?\s*>/gi," ").replace(/<[^>]*>/g,"").replace(/\s+/g," ").trim():s.tooltip.supportingText;return[s.tooltip.label,c].filter(Boolean).join(" - ")},a=s=>{if(t.useWindowLocation&&s.href&&!t.preventVisits&&(window.location.href=s.href),t.replaceState){const c=new URL(window.location.href),u=new URLSearchParams(c.search);u.set("tab",s.key);const l=`${c.origin}${c.pathname}?${u.toString()}`;t.replaceStrategy==="window"&&window.history.pushState({},"",l)}t.selfUpdate&&n(s),t.preventVisits&&r("tab-clicked",s)},o=s=>{const c=s.target.value,u=t.tabs.find(l=>l.key===c);u&&a(u)};return(s,c)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(["dsg-tab",`dsg-tab--${t.style}`])},[f.createElementVNode("div",O0,[f.createElementVNode("select",{"aria-label":"Select a tab",class:"dsg-tab__mobile-select",value:t.tabs.find(u=>u.current)?.key,onChange:o},[(f.openBlock(!0),f.createElementBlock(f.Fragment,null,f.renderList(t.tabs,u=>(f.openBlock(),f.createElementBlock("option",{key:u.name,value:u.key,textContent:f.toDisplayString(u.name),title:i(u)},null,8,N0))),128))],40,T0),f.createVNode(M._sfc_main,{class:"dsg-tab__mobile-select-icon",icon:"chevron-down","aria-hidden":"true",size:"sm"})]),f.createElementVNode("div",D0,[f.createElementVNode("div",B0,[f.createElementVNode("div",{class:f.normalizeClass(["dsg-tab__desktop-nav",t.style==="pills"?"dsg-tab__desktop-nav--pills":""]),"aria-label":"Tabs"},[(f.openBlock(!0),f.createElementBlock(f.Fragment,null,f.renderList(t.tabs,u=>(f.openBlock(),f.createElementBlock("a",{key:u.name,href:u.href,onClick:f.withModifiers(l=>a(u),["prevent"]),class:f.normalizeClass(["dsg-tab__desktop-link",u.current?"dsg-tab__desktop-link--active":"dsg-tab__desktop-link--inactive"]),"aria-current":u.current?"page":void 0},[u.tooltip?(f.openBlock(),f.createBlock(M._sfc_main$1,f.mergeProps({key:1,ref_for:!0},u.tooltip,{class:"dsg-tab__desktop-tooltip"}),{"dsg-tooltip--trigger":f.withCtx(()=>[f.createElementVNode("span",{class:"dsg-tab__desktop-link-label",textContent:f.toDisplayString(u.name)},null,8,k0),u.tooltip.icon?(f.openBlock(),f.createBlock(M._sfc_main,{key:0,icon:u.tooltip.icon,class:"inline-flex",size:"xs"},null,8,["icon"])):f.createCommentVNode("",!0)]),_:2},1040)):(f.openBlock(),f.createElementBlock("span",{key:0,class:"dsg-tab__desktop-link-label",textContent:f.toDisplayString(u.name)},null,8,P0)),u.badge?(f.openBlock(),f.createBlock(Xi,{key:2,label:u.badge.label,"theme-color":u.current?"brand":"gray",theme:"pill-color",size:"sm"},null,8,["label","theme-color"])):f.createCommentVNode("",!0)],10,R0))),128))],2)])]),t.useSlots?(f.openBlock(),f.createElementBlock("div",M0,[(f.openBlock(!0),f.createElementBlock(f.Fragment,null,f.renderList(t.tabs,(u,l)=>(f.openBlock(),f.createElementBlock(f.Fragment,{key:l},[u.current?f.renderSlot(s.$slots,`dsg-tab--content--${String(u.key).trim().toLowerCase().replace(/[^0-9a-zA-Z]/g,"-").replace(/-+/g,"-")}`,{key:0,data:u}):f.createCommentVNode("",!0)],64))),128))])):f.createCommentVNode("",!0)],2))}}),xa=M._sfc_main,ya=It,ma=M._sfc_main$5,wa=Xa,_a=is,Ea=Wi,Aa=rr,F0=Es,Ca=Xi,ba=M._sfc_main$3,Sa=M._sfc_main$2,Ia=Gs,Oa=N1,Ta=M._sfc_main$4,Na=M._sfc_main$8,Da=M._sfc_main$6,Ba=M._sfc_main$9,Ra=Ha._sfc_main,Pa=ra,ka=V1,Ma=W1,La=M._sfc_main$1,Fa=M._sfc_main$7,V0=Rs,U0=Q1,H0=A0,$0=ga,G0=C0,Va=I0,Ua=L0,z0={DsgIcon:xa,DsgMiscIcon:ya,DsgCreditCardIcon:ma,DsgAlert:_a,DsgAccordion:wa,DsgAnnouncement:Ea,DsgAvatar:Aa,DsgBadge:Ca,DsgButton:ba,DsgCheckbox:Sa,DsgCheckboxGroup:Ia,DsgDropdown:Oa,DsgInput:Ta,DsgInputSelect:Na,DsgDatepicker:Da,DsgSlider:Ba,DsgLabel:Ra,DsgModal:Pa,DsgTag:ka,DsgToggle:Ma,DsgTooltip:La,DsgBreadcrumb:Va,DsgTab:Ua,DsgFilter:Fa};exports.DsgAccordion=wa;exports.DsgAlert=_a;exports.DsgAnnouncement=Ea;exports.DsgAvatar=Aa;exports.DsgBadge=Ca;exports.DsgBarcodeScanner=H0;exports.DsgBreadcrumb=Va;exports.DsgButton=ba;exports.DsgCard=$0;exports.DsgCardContainer=G0;exports.DsgCheckbox=Sa;exports.DsgCheckboxGroup=Ia;exports.DsgCreditCardIcon=ma;exports.DsgDatepicker=Da;exports.DsgDropdown=Oa;exports.DsgFilter=Fa;exports.DsgIcon=xa;exports.DsgIconSelect=F0;exports.DsgInput=Ta;exports.DsgInputNumber=V0;exports.DsgInputSelect=Na;exports.DsgLabel=Ra;exports.DsgMiscIcon=ya;exports.DsgModal=Pa;exports.DsgProgress=U0;exports.DsgSlider=Ba;exports.DsgTab=Ua;exports.DsgTag=ka;exports.DsgToggle=Ma;exports.DsgTooltip=La;exports.default=z0;
46
+ `),n=ki.singletonList(i0.INITIAL_STATE),i=0;i<this.text.length;i++){var a=void 0,o=i+1<this.text.length?this.text[i+1]:0;switch(this.text[i]){case te.getCharCode("\r"):a=o===r?2:0;break;case te.getCharCode("."):a=o===e?3:0;break;case te.getCharCode(","):a=o===e?4:0;break;case te.getCharCode(":"):a=o===e?5:0;break;default:a=0}a>0?(n=t.updateStateListForPair(n,i,a),i++):n=this.updateStateListForChar(n,i)}var s=ki.min(n,function(c,u){return c.getBitCount()-u.getBitCount()});return s.toBitArray(this.text)},t.prototype.updateStateListForChar=function(e,r){var n,i,a=[];try{for(var o=_r(e),s=o.next();!s.done;s=o.next()){var c=s.value;this.updateStateForChar(c,r,a)}}catch(u){n={error:u}}finally{try{s&&!s.done&&(i=o.return)&&i.call(o)}finally{if(n)throw n.error}}return t.simplifyStates(a)},t.prototype.updateStateForChar=function(e,r,n){for(var i=this.text[r]&255,a=dn[e.getMode()][i]>0,o=null,s=0;s<=je;s++){var c=dn[s][i];if(c>0){if(o==null&&(o=e.endBinaryShift(r)),!a||s===e.getMode()||s===Le){var u=o.latchAndAppend(s,c);n.push(u)}if(!a&&pa[e.getMode()][s]>=0){var l=o.shiftAndAppend(s,c);n.push(l)}}}if(e.getBinaryShiftByteCount()>0||dn[e.getMode()][i]===0){var d=e.addBinaryShiftChar(r);n.push(d)}},t.updateStateListForPair=function(e,r,n){var i,a,o=[];try{for(var s=_r(e),c=s.next();!c.done;c=s.next()){var u=c.value;this.updateStateForPair(u,r,n,o)}}catch(l){i={error:l}}finally{try{c&&!c.done&&(a=s.return)&&a.call(s)}finally{if(i)throw i.error}}return this.simplifyStates(o)},t.updateStateForPair=function(e,r,n,i){var a=e.endBinaryShift(r);if(i.push(a.latchAndAppend(je,n)),e.getMode()!==je&&i.push(a.shiftAndAppend(je,n)),n===3||n===4){var o=a.latchAndAppend(Le,16-n).latchAndAppend(Le,1);i.push(o)}if(e.getBinaryShiftByteCount()>0){var s=e.addBinaryShiftChar(r).addBinaryShiftChar(r+1);i.push(s)}},t.simplifyStates=function(e){var r,n,i,a,o=[];try{for(var s=_r(e),c=s.next();!c.done;c=s.next()){var u=c.value,l=!0,d=function(y){if(y.isBetterThanOrEqualTo(u))return l=!1,"break";u.isBetterThanOrEqualTo(y)&&(o=o.filter(function(w){return w!==y}))};try{for(var v=(i=void 0,_r(o)),h=v.next();!h.done;h=v.next()){var p=h.value,g=d(p);if(g==="break")break}}catch(y){i={error:y}}finally{try{h&&!h.done&&(a=v.return)&&a.call(v)}finally{if(i)throw i.error}}l&&o.push(u)}}catch(y){r={error:y}}finally{try{c&&!c.done&&(n=s.return)&&n.call(s)}finally{if(r)throw r.error}}return o},t})(),s0=function(t){var e=typeof Symbol=="function"&&Symbol.iterator,r=e&&t[e],n=0;if(r)return r.call(t);if(t&&typeof t.length=="number")return{next:function(){return t&&n>=t.length&&(t=void 0),{value:t&&t[n++],done:!t}}};throw new TypeError(e?"Object is not iterable.":"Symbol.iterator is not defined.")};(function(){function t(){}return t.encodeBytes=function(e){return t.encode(e,t.DEFAULT_EC_PERCENT,t.DEFAULT_AZTEC_LAYERS)},t.encode=function(e,r,n){var i=new o0(e).encode(),a=G.truncDivision(i.getSize()*r,100)+11,o=i.getSize()+a,s,c,u,l,d;if(n!==t.DEFAULT_AZTEC_LAYERS){if(s=n<0,c=Math.abs(n),c>(s?t.MAX_NB_BITS_COMPACT:t.MAX_NB_BITS))throw new L(te.format("Illegal value %s for layers",n));u=t.totalBitsInLayer(c,s),l=t.WORD_SIZE[c];var v=u-u%l;if(d=t.stuffBits(i,l),d.getSize()+a>v)throw new L("Data to large for user specified layer");if(s&&d.getSize()>l*64)throw new L("Data to large for user specified layer")}else{l=0,d=null;for(var h=0;;h++){if(h>t.MAX_NB_BITS)throw new L("Data too large for an Aztec code");if(s=h<=3,c=s?h+1:h,u=t.totalBitsInLayer(c,s),!(o>u)){(d==null||l!==t.WORD_SIZE[c])&&(l=t.WORD_SIZE[c],d=t.stuffBits(i,l));var v=u-u%l;if(!(s&&d.getSize()>l*64)&&d.getSize()+a<=v)break}}}var p=t.generateCheckWords(d,u,l),g=d.getSize()/l,y=t.generateModeMessage(s,c,g),w=(s?11:14)+c*4,m=new Int32Array(w),_;if(s){_=w;for(var h=0;h<m.length;h++)m[h]=h}else{_=w+1+2*G.truncDivision(G.truncDivision(w,2)-1,15);for(var A=G.truncDivision(w,2),I=G.truncDivision(_,2),h=0;h<A;h++){var D=h+G.truncDivision(h,15);m[A-h-1]=I-D-1,m[A+h]=I+D+1}}for(var B=new Ze(_),h=0,P=0;h<c;h++){for(var $=(c-h)*4+(s?9:12),F=0;F<$;F++)for(var ne=F*2,V=0;V<2;V++)p.get(P+ne+V)&&B.set(m[h*2+V],m[h*2+F]),p.get(P+$*2+ne+V)&&B.set(m[h*2+F],m[w-1-h*2-V]),p.get(P+$*4+ne+V)&&B.set(m[w-1-h*2-V],m[w-1-h*2-F]),p.get(P+$*6+ne+V)&&B.set(m[w-1-h*2-F],m[h*2+V]);P+=$*8}if(t.drawModeMessage(B,s,_,y),s)t.drawBullsEye(B,G.truncDivision(_,2),5);else{t.drawBullsEye(B,G.truncDivision(_,2),7);for(var h=0,F=0;h<G.truncDivision(w,2)-1;h+=15,F+=16)for(var V=G.truncDivision(_,2)&1;V<_;V+=2)B.set(G.truncDivision(_,2)-F,V),B.set(G.truncDivision(_,2)+F,V),B.set(V,G.truncDivision(_,2)-F),B.set(V,G.truncDivision(_,2)+F)}var Y=new jf;return Y.setCompact(s),Y.setSize(_),Y.setLayers(c),Y.setCodeWords(g),Y.setMatrix(B),Y},t.drawBullsEye=function(e,r,n){for(var i=0;i<n;i+=2)for(var a=r-i;a<=r+i;a++)e.set(a,r-i),e.set(a,r+i),e.set(r-i,a),e.set(r+i,a);e.set(r-n,r-n),e.set(r-n+1,r-n),e.set(r-n,r-n+1),e.set(r+n,r-n),e.set(r+n,r-n+1),e.set(r+n,r+n-1)},t.generateModeMessage=function(e,r,n){var i=new ge;return e?(i.appendBits(r-1,2),i.appendBits(n-1,6),i=t.generateCheckWords(i,28,4)):(i.appendBits(r-1,5),i.appendBits(n-1,11),i=t.generateCheckWords(i,40,4)),i},t.drawModeMessage=function(e,r,n,i){var a=G.truncDivision(n,2);if(r)for(var o=0;o<7;o++){var s=a-3+o;i.get(o)&&e.set(s,a-5),i.get(o+7)&&e.set(a+5,s),i.get(20-o)&&e.set(s,a+5),i.get(27-o)&&e.set(a-5,s)}else for(var o=0;o<10;o++){var s=a-5+o+G.truncDivision(o,5);i.get(o)&&e.set(s,a-7),i.get(o+10)&&e.set(a+7,s),i.get(29-o)&&e.set(s,a+7),i.get(39-o)&&e.set(a-7,s)}},t.generateCheckWords=function(e,r,n){var i,a,o=e.getSize()/n,s=new ha(t.getGF(n)),c=G.truncDivision(r,n),u=t.bitsToWords(e,n,c);s.encode(u,c-o);var l=r%n,d=new ge;d.appendBits(0,l);try{for(var v=s0(Array.from(u)),h=v.next();!h.done;h=v.next()){var p=h.value;d.appendBits(p,n)}}catch(g){i={error:g}}finally{try{h&&!h.done&&(a=v.return)&&a.call(v)}finally{if(i)throw i.error}}return d},t.bitsToWords=function(e,r,n){var i=new Int32Array(n),a,o;for(a=0,o=e.getSize()/r;a<o;a++){for(var s=0,c=0;c<r;c++)s|=e.get(a*r+c)?1<<r-c-1:0;i[a]=s}return i},t.getGF=function(e){switch(e){case 4:return Ne.AZTEC_PARAM;case 6:return Ne.AZTEC_DATA_6;case 8:return Ne.AZTEC_DATA_8;case 10:return Ne.AZTEC_DATA_10;case 12:return Ne.AZTEC_DATA_12;default:throw new L("Unsupported word size "+e)}},t.stuffBits=function(e,r){for(var n=new ge,i=e.getSize(),a=(1<<r)-2,o=0;o<i;o+=r){for(var s=0,c=0;c<r;c++)(o+c>=i||e.get(o+c))&&(s|=1<<r-1-c);(s&a)===a?(n.appendBits(s&a,r),o--):(s&a)===0?(n.appendBits(s|1,r),o--):n.appendBits(s,r)}return n},t.totalBitsInLayer=function(e,r){return((r?88:112)+16*e)*e},t.DEFAULT_EC_PERCENT=33,t.DEFAULT_AZTEC_LAYERS=0,t.MAX_NB_BITS=32,t.MAX_NB_BITS_COMPACT=4,t.WORD_SIZE=Int32Array.from([4,6,6,8,8,8,8,8,8,10,10,10,10,10,10,10,10,10,10,10,10,10,10,12,12,12,12,12,12,12,12,12,12]),t})();const c0=(t,e)=>{const r=t.__vccOpts||t;for(const[n,i]of e)r[n]=i;return r},u0={name:"stream-barcode-reader",data(){return{isLoading:!0,codeReader:new Lf,isMediaStreamAPISupported:navigator&&navigator.mediaDevices&&"enumerateDevices"in navigator.mediaDevices}},mounted(){if(!this.isMediaStreamAPISupported)throw new Ie("Media Stream API is not supported");this.start(),this.$refs.scanner.oncanplay=t=>{this.isLoading=!1,this.$emit("loaded")}},beforeUnmount(){this.codeReader.reset()},methods:{start(){this.codeReader.decodeFromVideoDevice(void 0,this.$refs.scanner,(t,e)=>{t&&(this.$emit("decode",t.text),this.$emit("result",t))})}}},f0={class:"scanner-container"},l0={poster:"data:image/gif,AAAA",ref:"scanner"};function d0(t,e,r,n,i,a){return f.openBlock(),f.createElementBlock("div",f0,[f.withDirectives(f.createElementVNode("div",null,[f.createElementVNode("video",l0,null,512),e[0]||(e[0]=f.createElementVNode("div",{class:"overlay-element"},null,-1)),e[1]||(e[1]=f.createElementVNode("div",{class:"laser"},null,-1))],512),[[f.vShow,!i.isLoading]])])}const h0=c0(u0,[["render",d0],["__scopeId","data-v-3b725b25"]]),v0={key:0,class:"scanner-modal"},p0={class:"scanner-header"},g0={class:"scanner-title"},x0={key:0,class:"scanner-subtitle"},y0={class:"scanner-stream"},m0={class:"scanner-overlay"},w0={key:0,class:"scanner-slot"},_0={class:"scanner-manual"},E0={key:0},A0=f.defineComponent({__name:"DsgBarcodeScanner",props:{failTitle:{},failSubtitle:{},onScan:{type:Function}},setup(t,{expose:e}){const r=t,n=f.ref(!1),i=f.ref(""),a=f.ref("");f.ref(null);const o=f.ref(""),s=f.ref(!1),c=f.ref(!1),u=f.ref(!1),l=f.ref(r.failTitle??"Scan Failed"),d=f.ref(r.failSubtitle??"Please try again or enter the barcode manually."),v=f.ref(null),h={theme:"error",type:"light",size:"lg",icon:{icon:"alert-circle",size:"sm"}};f.watch(()=>r.failTitle,V=>{V&&(l.value=V)}),f.watch(()=>r.failSubtitle,V=>{V&&(d.value=V)});const p={label:"Re-scan",theme:"destructive"},g={label:"Input manually",theme:"gray"};function y(V){i.value=V.title,a.value=V.subtitle??"",o.value="",s.value=!1,n.value=!0}function w(V){I({type:"scanned",value:V})}function m(){o.value.trim()&&(_(),I({type:"manual",value:o.value.trim()}))}function _(){s.value=!s.value,s.value&&(o.value="")}function A(){I({type:"cancelled"})}function I(V){console.log("Scan result:",V),r.onScan&&r.onScan(V)}function D(){n.value=!1}function B(){c.value=!0,setTimeout(()=>{c.value=!1},3e3)}function P(){v.value?.open()}function $(){u.value=!0}function F(){u.value=!1}e({scan:y,close:D,success:B,error:P,showSlot:$,hideSlot:F});const ne=()=>{document.documentElement.style.setProperty("--vh",`${window.innerHeight*.01}px`)};return f.onMounted(()=>{ne(),window.addEventListener("resize",ne)}),f.onBeforeUnmount(()=>{window.removeEventListener("resize",ne)}),(V,Y)=>(f.openBlock(),f.createBlock(f.Teleport,{to:"body"},[n.value?(f.openBlock(),f.createElementBlock("div",v0,[f.createVNode(ra,{ref_key:"modalRef",ref:v,title:l.value,description:d.value,"misc-icon":h,onClose:A,footerType:"vertical","primary-button":p,"secondary-button":g,onPrimaryButtonClicked:Y[0]||(Y[0]=Ee=>v.value?.close()),onSecondaryButtonClicked:Y[1]||(Y[1]=Ee=>{_(),v.value?.close()}),width:500},null,8,["title","description"]),f.createElementVNode("div",p0,[f.createElementVNode("div",null,[f.createElementVNode("h2",g0,f.toDisplayString(i.value),1),a.value?(f.openBlock(),f.createElementBlock("p",x0,f.toDisplayString(a.value),1)):f.createCommentVNode("",!0)]),f.createElementVNode("button",{class:"scanner-close",onClick:A,"aria-label":"Close"}," × ")]),f.createElementVNode("div",y0,[f.createVNode(f.unref(h0),{class:"scanner-video",onDecode:w}),f.createElementVNode("div",m0,[u.value?(f.openBlock(),f.createElementBlock("div",w0,[f.renderSlot(V.$slots,"default")])):f.createCommentVNode("",!0),f.createElementVNode("div",_0,[s.value?f.createCommentVNode("",!0):(f.openBlock(),f.createElementBlock("span",E0,"No barcode?")),s.value?f.createCommentVNode("",!0):(f.openBlock(),f.createBlock(M._sfc_main$3,{key:1,label:"Input manually",onClick:_,"icon-before":"pencil-01",theme:"gray-secondary"})),s.value?(f.openBlock(),f.createBlock(M._sfc_main$4,{key:2,modelValue:o.value,"onUpdate:modelValue":Y[2]||(Y[2]=Ee=>o.value=Ee),placeholder:"Enter barcode manually",class:"w-full"},null,8,["modelValue"])):f.createCommentVNode("",!0),s.value?(f.openBlock(),f.createBlock(M._sfc_main$3,{key:3,label:"Submit",onClick:m,"icon-before":"check",theme:"gray-secondary"})):f.createCommentVNode("",!0)]),c.value?(f.openBlock(),f.createBlock(M._sfc_main,{key:1,icon:"check",size:"3xl",class:"scanner-success"})):f.createCommentVNode("",!0)])])])):f.createCommentVNode("",!0)]))}}),ga=f.defineComponent({__name:"DsgCard",props:{variant:{default:"default"},hoverable:{type:Boolean,default:!1}},setup(t){return(e,r)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(["dsg-card",[`dsg-card--${t.variant}`,{"dsg-card--hoverable":t.hoverable}]])},[f.renderSlot(e.$slots,"default")],2))}}),C0=f.defineComponent({__name:"DsgCardContainer",props:{columns:{default:1},gap:{},items:{},itemKey:{default:null},cardProps:{default:()=>({})}},setup(t){return(e,r)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(["dsg-card-container",`dsg-card-container--cols-${t.columns} dsg-card-container--gap-${t.gap}`])},[(f.openBlock(!0),f.createElementBlock(f.Fragment,null,f.renderList(t.items,(n,i)=>(f.openBlock(),f.createBlock(ga,f.mergeProps({key:t.itemKey?n[t.itemKey]:i},{ref_for:!0},t.cardProps),{default:f.withCtx(()=>[f.renderSlot(e.$slots,"default",{item:n,index:i})]),_:2},1040))),128))],2))}}),b0={class:"dsg-breadcrumbs"},S0={key:1},I0=f.defineComponent({__name:"DsgBreadcrumb",props:{breadcrumbs:{default:()=>[]},divider:{default:()=>({icon:"slash-divider",size:"sm"})},theme:{default:"text"}},setup(t){return(e,r)=>(f.openBlock(),f.createElementBlock("div",b0,[(f.openBlock(!0),f.createElementBlock(f.Fragment,null,f.renderList(t.breadcrumbs,(n,i)=>(f.openBlock(),f.createElementBlock(f.Fragment,{key:`breadcrumb-item-${i}`},[(f.openBlock(),f.createBlock(f.resolveDynamicComponent(n.url??!1?"a":"span"),{href:n.url??null,disabled:n.disabled,class:f.normalizeClass(["dsg-breadcrumbs__button-base",`dsg-breadcrumbs__button-base--${t.theme}`,`${n.active??i===t.breadcrumbs.length-1?"dsg-breadcrumbs__button-base--active":""}`].join(" "))},{default:f.withCtx(()=>[n.icon&&n.useIcon?(f.openBlock(),f.createBlock(M._sfc_main,{key:0,icon:n.icon,size:"sm",class:"dsg-breadcrumbs__icon"},null,8,["icon"])):(f.openBlock(),f.createElementBlock("span",S0,f.toDisplayString(n.label),1))]),_:2},1032,["href","disabled","class"])),i<t.breadcrumbs.length-1?(f.openBlock(),f.createBlock(M._sfc_main,f.mergeProps({key:0,ref_for:!0},t.divider,{class:"dsg-breadcrumbs__divider"}),null,16)):f.createCommentVNode("",!0)],64))),128))]))}}),O0={class:"dsg-tab__mobile"},T0=["value"],N0=["value","textContent","title"],D0={class:"dsg-tab__desktop"},B0={class:"dsg-tab__desktop-wrapper"},R0=["href","onClick","aria-current"],P0=["textContent"],k0=["textContent"],M0={key:0,class:"dsg-tab--content"},L0=f.defineComponent({__name:"DsgTab",props:{tabs:{default:()=>[]},style:{default:"tabs"},preventVisits:{type:Boolean,default:!0},useWindowLocation:{type:Boolean,default:!1},replaceState:{type:Boolean,default:!1},replaceStrategy:{default:"window"},useSlots:{type:Boolean,default:!1},selfUpdate:{type:Boolean,default:!0},teleportSlotTo:{}},emits:["tab-clicked"],setup(t,{emit:e}){const r=e,n=s=>{t.tabs.forEach(c=>{c.current=s.name===c.name})},i=s=>{if(!s.tooltip)return;const c=s.tooltip.supportingTextHtml&&s.tooltip.supportingText?s.tooltip.supportingText.replace(/<br\s*\/?\s*>/gi," ").replace(/<[^>]*>/g,"").replace(/\s+/g," ").trim():s.tooltip.supportingText;return[s.tooltip.label,c].filter(Boolean).join(" - ")},a=s=>{if(t.useWindowLocation&&s.href&&!t.preventVisits&&(window.location.href=s.href),t.replaceState){const c=new URL(window.location.href),u=new URLSearchParams(c.search);u.set("tab",s.key);const l=`${c.origin}${c.pathname}?${u.toString()}`;t.replaceStrategy==="window"&&window.history.pushState({},"",l)}t.selfUpdate&&n(s),t.preventVisits&&r("tab-clicked",s)},o=s=>{const c=s.target.value,u=t.tabs.find(l=>l.key===c);u&&a(u)};return(s,c)=>(f.openBlock(),f.createElementBlock("div",{class:f.normalizeClass(["dsg-tab",`dsg-tab--${t.style}`])},[f.createElementVNode("div",O0,[f.createElementVNode("select",{"aria-label":"Select a tab",class:"dsg-tab__mobile-select",value:t.tabs.find(u=>u.current)?.key,onChange:o},[(f.openBlock(!0),f.createElementBlock(f.Fragment,null,f.renderList(t.tabs,u=>(f.openBlock(),f.createElementBlock("option",{key:u.name,value:u.key,textContent:f.toDisplayString(u.name),title:i(u)},null,8,N0))),128))],40,T0),f.createVNode(M._sfc_main,{class:"dsg-tab__mobile-select-icon",icon:"chevron-down","aria-hidden":"true",size:"sm"})]),f.createElementVNode("div",D0,[f.createElementVNode("div",B0,[f.createElementVNode("div",{class:f.normalizeClass(["dsg-tab__desktop-nav",t.style==="pills"?"dsg-tab__desktop-nav--pills":""]),"aria-label":"Tabs"},[(f.openBlock(!0),f.createElementBlock(f.Fragment,null,f.renderList(t.tabs,u=>(f.openBlock(),f.createElementBlock("a",{key:u.name,href:u.href,onClick:f.withModifiers(l=>a(u),["prevent"]),class:f.normalizeClass(["dsg-tab__desktop-link",u.current?"dsg-tab__desktop-link--active":"dsg-tab__desktop-link--inactive"]),"aria-current":u.current?"page":void 0},[u.tooltip?(f.openBlock(),f.createBlock(M._sfc_main$1,f.mergeProps({key:1,ref_for:!0},u.tooltip,{class:"dsg-tab__desktop-tooltip"}),{"dsg-tooltip--trigger":f.withCtx(()=>[f.createElementVNode("span",{class:"dsg-tab__desktop-link-label",textContent:f.toDisplayString(u.name)},null,8,k0),u.tooltip.icon?(f.openBlock(),f.createBlock(M._sfc_main,{key:0,icon:u.tooltip.icon,class:"inline-flex",size:"xs"},null,8,["icon"])):f.createCommentVNode("",!0)]),_:2},1040)):(f.openBlock(),f.createElementBlock("span",{key:0,class:"dsg-tab__desktop-link-label",textContent:f.toDisplayString(u.name)},null,8,P0)),u.badge?(f.openBlock(),f.createBlock(Xi,{key:2,label:u.badge.label,"theme-color":u.current?"brand":"gray",theme:"pill-color",size:"sm"},null,8,["label","theme-color"])):f.createCommentVNode("",!0)],10,R0))),128))],2)])]),t.useSlots?(f.openBlock(),f.createElementBlock("div",M0,[(f.openBlock(!0),f.createElementBlock(f.Fragment,null,f.renderList(t.tabs,(u,l)=>(f.openBlock(),f.createElementBlock(f.Fragment,{key:l},[u.current?f.renderSlot(s.$slots,`dsg-tab--content--${String(u.key).trim().toLowerCase().replace(/[^0-9a-zA-Z]/g,"-").replace(/-+/g,"-")}`,{data:u},void 0,void 0,0):f.createCommentVNode("",!0)],64))),128))])):f.createCommentVNode("",!0)],2))}}),xa=M._sfc_main,ya=It,ma=M._sfc_main$5,wa=Xa,_a=is,Ea=Wi,Aa=rr,F0=Es,Ca=Xi,ba=M._sfc_main$3,Sa=M._sfc_main$2,Ia=Gs,Oa=N1,Ta=M._sfc_main$4,Na=M._sfc_main$8,Da=M._sfc_main$6,Ba=M._sfc_main$9,Ra=Ha._sfc_main,Pa=ra,ka=V1,Ma=W1,La=M._sfc_main$1,Fa=M._sfc_main$7,V0=Rs,U0=Q1,H0=A0,$0=ga,G0=C0,Va=I0,Ua=L0,z0={DsgIcon:xa,DsgMiscIcon:ya,DsgCreditCardIcon:ma,DsgAlert:_a,DsgAccordion:wa,DsgAnnouncement:Ea,DsgAvatar:Aa,DsgBadge:Ca,DsgButton:ba,DsgCheckbox:Sa,DsgCheckboxGroup:Ia,DsgDropdown:Oa,DsgInput:Ta,DsgInputSelect:Na,DsgDatepicker:Da,DsgSlider:Ba,DsgLabel:Ra,DsgModal:Pa,DsgTag:ka,DsgToggle:Ma,DsgTooltip:La,DsgBreadcrumb:Va,DsgTab:Ua,DsgFilter:Fa};exports.DsgAccordion=wa;exports.DsgAlert=_a;exports.DsgAnnouncement=Ea;exports.DsgAvatar=Aa;exports.DsgBadge=Ca;exports.DsgBarcodeScanner=H0;exports.DsgBreadcrumb=Va;exports.DsgButton=ba;exports.DsgCard=$0;exports.DsgCardContainer=G0;exports.DsgCheckbox=Sa;exports.DsgCheckboxGroup=Ia;exports.DsgCreditCardIcon=ma;exports.DsgDatepicker=Da;exports.DsgDropdown=Oa;exports.DsgFilter=Fa;exports.DsgIcon=xa;exports.DsgIconSelect=F0;exports.DsgInput=Ta;exports.DsgInputNumber=V0;exports.DsgInputSelect=Na;exports.DsgLabel=Ra;exports.DsgMiscIcon=ya;exports.DsgModal=Pa;exports.DsgProgress=U0;exports.DsgSlider=Ba;exports.DsgTab=Ua;exports.DsgTag=ka;exports.DsgToggle=Ma;exports.DsgTooltip=La;exports.default=z0;