@selfeesas/shared-components 1.8.0 → 1.9.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,4 +1,4 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const v=require("vue"),pi={xs:18,sm:24,md:32,lg:38,xl:46},Fr={size:String};function jr(l,B=pi){return v.computed(()=>l.size!==void 0?{fontSize:l.size in B?`${B[l.size]}px`:l.size}:null)}function Lt(l,B,t,b){return Object.defineProperty(l,B,{get:t,set:b,enumerable:!0}),l}function Cs(l,B){for(const t in B)Lt(l,t,B[t]);return l}function $e(l){return v.markRaw(v.defineComponent(l))}function Ti(l){return v.markRaw(l)}const As=(l,B)=>{const t=v.reactive(l);for(const b in l)Lt(B,b,()=>t[b],m=>{t[b]=m});return B};function bt(l,B){return l!==void 0&&l()||B}function Ri(l,B){if(l!==void 0){const t=l();if(t!=null)return t.slice()}return B}function It(l,B){return l!==void 0?B.concat(l()):B}function la(l,B){return l===void 0?B:B!==void 0?B.concat(l()):l()}function Es(l,B,t,b,m,c){B.key=b+m;const i=v.h(l,B,t);return m===!0?v.withDirectives(i,c()):i}const lo="0 0 24 24",Kn=l=>l,Xn=l=>`ionicons ${l}`,ua={"mdi-":l=>`mdi ${l}`,"icon-":Kn,"bt-":l=>`bt ${l}`,"eva-":l=>`eva ${l}`,"ion-md":Xn,"ion-ios":Xn,"ion-logo":Xn,"iconfont ":Kn,"ti-":l=>`themify-icon ${l}`,"bi-":l=>`bootstrap-icons ${l}`,"i-":Kn},ca={o_:"-outlined",r_:"-round",s_:"-sharp"},da={sym_o_:"-outlined",sym_r_:"-rounded",sym_s_:"-sharp"},Ms=new RegExp("^("+Object.keys(ua).join("|")+")"),Ts=new RegExp("^("+Object.keys(ca).join("|")+")"),uo=new RegExp("^("+Object.keys(da).join("|")+")"),Rs=/^[Mm]\s?[-+]?\.?\d/,Bs=/^img:/,Is=/^svguse:/,Os=/^ion-/,Fs=/^(fa-(classic|sharp|solid|regular|light|brands|duotone|thin)|[lf]a[srlbdk]?) /,dt=$e({name:"QIcon",props:{...Fr,tag:{type:String,default:"i"},name:String,color:String,left:Boolean,right:Boolean},setup(l,{slots:B}){const{proxy:{$q:t}}=v.getCurrentInstance(),b=jr(l),m=v.computed(()=>"q-icon"+(l.left===!0?" on-left":"")+(l.right===!0?" on-right":"")+(l.color!==void 0?` text-${l.color}`:"")),c=v.computed(()=>{let i,s=l.name;if(s==="none"||!s)return{none:!0};if(t.iconMapFn!==null){const r=t.iconMapFn(s);if(r!==void 0)if(r.icon!==void 0){if(s=r.icon,s==="none"||!s)return{none:!0}}else return{cls:r.cls,content:r.content!==void 0?r.content:" "}}if(Rs.test(s)===!0){const[r,u=lo]=s.split("|");return{svg:!0,viewBox:u,nodes:r.split("&&").map(a=>{const[o,f,h]=a.split("@@");return v.h("path",{style:f,d:o,transform:h})})}}if(Bs.test(s)===!0)return{img:!0,src:s.substring(4)};if(Is.test(s)===!0){const[r,u=lo]=s.split("|");return{svguse:!0,src:r.substring(7),viewBox:u}}let n=" ";const e=s.match(Ms);if(e!==null)i=ua[e[1]](s);else if(Fs.test(s)===!0)i=s;else if(Os.test(s)===!0)i=`ionicons ion-${t.platform.is.ios===!0?"ios":"md"}${s.substring(3)}`;else if(uo.test(s)===!0){i="notranslate material-symbols";const r=s.match(uo);r!==null&&(s=s.substring(6),i+=da[r[1]]),n=s}else{i="notranslate material-icons";const r=s.match(Ts);r!==null&&(s=s.substring(2),i+=ca[r[1]]),n=s}return{cls:i,content:n}});return()=>{const i={class:m.value,style:b.value,"aria-hidden":"true"};return c.value.none===!0?v.h(l.tag,i,bt(B.default)):c.value.img===!0?v.h(l.tag,i,It(B.default,[v.h("img",{src:c.value.src})])):c.value.svg===!0?v.h(l.tag,i,It(B.default,[v.h("svg",{viewBox:c.value.viewBox||"0 0 24 24"},c.value.nodes)])):c.value.svguse===!0?v.h(l.tag,i,It(B.default,[v.h("svg",{viewBox:c.value.viewBox},[v.h("use",{"xlink:href":c.value.src})])])):(c.value.cls!==void 0&&(i.class+=" "+c.value.cls),v.h(l.tag,i,It(B.default,[c.value.content])))}}});function xn(l){if(Object(l.$parent)===l.$parent)return l.$parent;let{parent:B}=l.$;for(;Object(B)===B;){if(Object(B.proxy)===B.proxy)return B.proxy;B=B.parent}}function fa(l,B){typeof B.type=="symbol"?Array.isArray(B.children)===!0&&B.children.forEach(t=>{fa(l,t)}):l.add(B)}function js(l){const B=new Set;return l.forEach(t=>{fa(B,t)}),Array.from(B)}function Bi(l){return l.appContext.config.globalProperties.$router!==void 0}function Ii(l){return l.isUnmounted===!0||l.isDeactivated===!0}function co(l){return l?l.aliasOf?l.aliasOf.path:l.path:""}function fo(l,B){return(l.aliasOf||l)===(B.aliasOf||B)}function Ds(l,B){for(const t in B){const b=B[t],m=l[t];if(typeof b=="string"){if(b!==m)return!1}else if(Array.isArray(m)===!1||m.length!==b.length||b.some((c,i)=>c!==m[i]))return!1}return!0}function ho(l,B){return Array.isArray(B)===!0?l.length===B.length&&l.every((t,b)=>t===B[b]):l.length===1&&l[0]===B}function Ps(l,B){return Array.isArray(l)===!0?ho(l,B):Array.isArray(B)===!0?ho(B,l):l===B}function Ns(l,B){if(Object.keys(l).length!==Object.keys(B).length)return!1;for(const t in l)if(Ps(l[t],B[t])===!1)return!1;return!0}const ha={to:[String,Object],replace:Boolean,href:String,target:String,disable:Boolean},pa={...ha,exact:Boolean,activeClass:{type:String,default:"q-router-link--active"},exactActiveClass:{type:String,default:"q-router-link--exact-active"}};function Oi({fallbackTag:l,useDisableForRouterLinkProps:B=!0}={}){const t=v.getCurrentInstance(),{props:b,proxy:m,emit:c}=t,i=Bi(t),s=v.computed(()=>b.disable!==!0&&b.href!==void 0),n=B===!0?v.computed(()=>i===!0&&b.disable!==!0&&s.value!==!0&&b.to!==void 0&&b.to!==null&&b.to!==""):v.computed(()=>i===!0&&s.value!==!0&&b.to!==void 0&&b.to!==null&&b.to!==""),e=v.computed(()=>n.value===!0?p(b.to):null),r=v.computed(()=>e.value!==null),u=v.computed(()=>s.value===!0||r.value===!0),a=v.computed(()=>b.type==="a"||u.value===!0?"a":b.tag||l||"div"),o=v.computed(()=>s.value===!0?{href:b.href,target:b.target}:r.value===!0?{href:e.value.href,target:b.target}:{}),f=v.computed(()=>{if(r.value===!1)return-1;const{matched:T}=e.value,{length:D}=T,V=T[D-1];if(V===void 0)return-1;const P=m.$route.matched;if(P.length===0)return-1;const N=P.findIndex(fo.bind(null,V));if(N!==-1)return N;const q=co(T[D-2]);return D>1&&co(V)===q&&P[P.length-1].path!==q?P.findIndex(fo.bind(null,T[D-2])):N}),h=v.computed(()=>r.value===!0&&f.value!==-1&&Ds(m.$route.params,e.value.params)),d=v.computed(()=>h.value===!0&&f.value===m.$route.matched.length-1&&Ns(m.$route.params,e.value.params)),g=v.computed(()=>r.value===!0?d.value===!0?` ${b.exactActiveClass} ${b.activeClass}`:b.exact===!0?"":h.value===!0?` ${b.activeClass}`:"":"");function p(T){try{return m.$router.resolve(T)}catch{}return null}function k(T,{returnRouterError:D,to:V=b.to,replace:P=b.replace}={}){if(b.disable===!0)return T.preventDefault(),Promise.resolve(!1);if(T.metaKey||T.altKey||T.ctrlKey||T.shiftKey||T.button!==void 0&&T.button!==0||b.target==="_blank")return Promise.resolve(!1);T.preventDefault();const N=m.$router[P===!0?"replace":"push"](V);return D===!0?N:N.then(()=>{}).catch(()=>{})}function C(T){if(r.value===!0){const D=V=>k(T,V);c("click",T,D),T.defaultPrevented!==!0&&D()}else c("click",T)}return{hasRouterLink:r,hasHrefLink:s,hasLink:u,linkTag:a,resolvedLink:e,linkIsActive:h,linkIsExactActive:d,linkClass:g,linkAttrs:o,getLink:p,navigateToRouterLink:k,navigateOnClick:C}}const Ls=$e({name:"QBreadcrumbsEl",props:{...pa,label:String,icon:String,tag:{type:String,default:"span"}},emits:["click"],setup(l,{slots:B}){const{linkTag:t,linkAttrs:b,linkClass:m,navigateOnClick:c}=Oi(),i=v.computed(()=>({class:"q-breadcrumbs__el q-link flex inline items-center relative-position "+(l.disable!==!0?"q-link--focusable"+m.value:"q-breadcrumbs__el--disable"),...b.value,onClick:c})),s=v.computed(()=>"q-breadcrumbs__el-icon"+(l.label!==void 0?" q-breadcrumbs__el-icon--with-label":""));return()=>{const n=[];return l.icon!==void 0&&n.push(v.h(dt,{class:s.value,name:l.icon})),l.label!==void 0&&n.push(l.label),v.h(t.value,{...i.value},It(B.default,n))}}}),ma={left:"start",center:"center",right:"end",between:"between",around:"around",evenly:"evenly",stretch:"stretch"},Vs=Object.keys(ma),Fi={align:{type:String,validator:l=>Vs.includes(l)}};function ji(l){return v.computed(()=>{const B=l.align===void 0?l.vertical===!0?"stretch":"left":l.align;return`${l.vertical===!0?"items":"justify"}-${ma[B]}`})}const qs=["",!0],zs=$e({name:"QBreadcrumbs",props:{...Fi,separator:{type:String,default:"/"},separatorColor:String,activeColor:{type:String,default:"primary"},gutter:{type:String,validator:l=>["none","xs","sm","md","lg","xl"].includes(l),default:"sm"}},setup(l,{slots:B}){const t=ji(l),b=v.computed(()=>`flex items-center ${t.value}${l.gutter==="none"?"":` q-gutter-${l.gutter}`}`),m=v.computed(()=>l.separatorColor?` text-${l.separatorColor}`:""),c=v.computed(()=>` text-${l.activeColor}`);return()=>{if(B.default===void 0)return;const i=js(bt(B.default));if(i.length===0)return;let s=1;const n=[],e=i.filter(u=>u.type?.name==="QBreadcrumbsEl").length,r=B.separator!==void 0?B.separator:()=>l.separator;return i.forEach(u=>{if(u.type?.name==="QBreadcrumbsEl"){const a=s<e,o=u.props!==null&&qs.includes(u.props.disable),f=(a===!0?"":" q-breadcrumbs--last")+(o!==!0&&a===!0?c.value:"");s++,n.push(v.h("div",{class:`flex items-center${f}`},[u])),a===!0&&n.push(v.h("div",{class:"q-breadcrumbs__separator"+m.value},r()))}else n.push(u)}),v.h("div",{class:"q-breadcrumbs"},[v.h("div",{class:b.value},n)])}}}),Us=v.defineComponent({inheritAttrs:!1,__name:"Breadcrumbs",props:{activeColor:{},separatorIcon:{},separatorSize:{},separatorColor:{},store:{},navStore:{},route:{},router:{},breadcrumbConfig:{},separator:{},gutter:{},align:{}},setup(l){const B=l,t=v.useAttrs(),b=v.computed(()=>{const{activeColor:a,separatorIcon:o,separatorSize:f,separatorColor:h,...d}=t;return d}),m=a=>({"data-cy":a.dataCy,class:"cursor-pointer text-h5",color:a.color}),c=v.computed(()=>B.activeColor||"primary"),i=v.computed(()=>B.separatorIcon||"chevron_right"),s=v.computed(()=>B.separatorSize||"2em"),n=v.computed(()=>B.separatorColor||"primary"),e=v.computed(()=>({store:B.store,route:B.route,navStore:B.navStore||{}})),r=v.computed(()=>{const a=[];return B.breadcrumbConfig.forEach(o=>{if(!o.shouldRender(e.value))return;const f=o.getLabel?o.getLabel(e.value):o.defaultLabel,h=o.getColor?o.getColor(e.value):"dark",d={name:o.routeName,...o.getRouteParams&&{params:o.getRouteParams(e.value)}},g=o.clearActions?o.clearActions.map(p=>()=>p(e.value)):[];a.push({label:f,dataCy:o.dataCy,color:h,route:d,clearActions:g})}),a}),u=a=>{a.clearActions&&a.clearActions.forEach(o=>o()),B.router.push(a.route)};return(a,o)=>(v.openBlock(),v.createBlock(zs,v.mergeProps({"active-color":c.value,class:"text-brown"},b.value),{separator:v.withCtx(()=>[v.createVNode(dt,{size:s.value,name:i.value,color:n.value},null,8,["size","name","color"])]),default:v.withCtx(()=>[(v.openBlock(!0),v.createElementBlock(v.Fragment,null,v.renderList(r.value,(f,h)=>(v.openBlock(),v.createBlock(Ls,v.mergeProps({key:h,to:f.route},{ref_for:!0},m(f),{label:f.label,onClick:d=>u(f)}),null,16,["to","label","onClick"]))),128))]),_:1},16,["active-color"]))}}),Ws={size:{type:[String,Number],default:"1em"},color:String};function Hs(l){return{cSize:v.computed(()=>l.size in pi?`${pi[l.size]}px`:l.size),classes:v.computed(()=>"q-spinner"+(l.color?` text-${l.color}`:""))}}const ga=$e({name:"QSpinner",props:{...Ws,thickness:{type:Number,default:5}},setup(l){const{cSize:B,classes:t}=Hs(l);return()=>v.h("svg",{class:t.value+" q-spinner-mat",width:B.value,height:B.value,viewBox:"25 25 50 50"},[v.h("circle",{class:"path",cx:"50",cy:"50",r:"20",fill:"none",stroke:"currentColor","stroke-width":l.thickness,"stroke-miterlimit":"10"})])}});function mi(l,B){const t=l.style;for(const b in B)t[b]=B[b]}function Ys(l){if(l==null)return;if(typeof l=="string")try{return document.querySelector(l)||void 0}catch{return}const B=v.unref(l);if(B)return B.$el||B}function ba(l,B){if(l==null||l.contains(B)===!0)return!0;for(let t=l.nextElementSibling;t!==null;t=t.nextElementSibling)if(t.contains(B))return!0;return!1}const _t={hasPassive:!1,passiveCapture:!0,notPassiveCapture:!0};try{const l=Object.defineProperty({},"passive",{get(){Object.assign(_t,{hasPassive:!0,passive:{passive:!0},notPassive:{passive:!1},passiveCapture:{passive:!0,capture:!0},notPassiveCapture:{passive:!1,capture:!0}})}});window.addEventListener("qtest",null,l),window.removeEventListener("qtest",null,l)}catch{}function Ln(){}function Qs(l){return l.button===0}function Qr(l){return l.touches&&l.touches[0]?l=l.touches[0]:l.changedTouches&&l.changedTouches[0]?l=l.changedTouches[0]:l.targetTouches&&l.targetTouches[0]&&(l=l.targetTouches[0]),{top:l.clientY,left:l.clientX}}function Ks(l){if(l.path)return l.path;if(l.composedPath)return l.composedPath();const B=[];let t=l.target;for(;t;){if(B.push(t),t.tagName==="HTML")return B.push(document),B.push(window),B;t=t.parentElement}}function Dt(l){l.stopPropagation()}function Bt(l){l.cancelable!==!1&&l.preventDefault()}function St(l){l.cancelable!==!1&&l.preventDefault(),l.stopPropagation()}function Gn(l,B){if(l===void 0||B===!0&&l.__dragPrevented===!0)return;const t=B===!0?b=>{b.__dragPrevented=!0,b.addEventListener("dragstart",Bt,_t.notPassiveCapture)}:b=>{delete b.__dragPrevented,b.removeEventListener("dragstart",Bt,_t.notPassiveCapture)};l.querySelectorAll("a, img").forEach(t)}function Xt(l,B,t){const b=`__q_${B}_evt`;l[b]=l[b]!==void 0?l[b].concat(t):t,t.forEach(m=>{m[0].addEventListener(m[1],l[m[2]],_t[m[3]])})}function pr(l,B){const t=`__q_${B}_evt`;l[t]!==void 0&&(l[t].forEach(b=>{b[0].removeEventListener(b[1],l[b[2]],_t[b[3]])}),l[t]=void 0)}function Di(l){return l!==Object(l)||l.isComposing===!0||l.qKeyEvent===!0}function or(l,B){return Di(l)===!0?!1:[].concat(B).includes(l.keyCode)}function Xs(l,B=250){let t=!1,b;return function(){return t===!1&&(t=!0,setTimeout(()=>{t=!1},B),b=l.apply(this,arguments)),b}}function po(l,B,t,b){t.modifiers.stop===!0&&Dt(l);const m=t.modifiers.color;let c=t.modifiers.center;c=c===!0||b===!0;const i=document.createElement("span"),s=document.createElement("span"),n=Qr(l),{left:e,top:r,width:u,height:a}=B.getBoundingClientRect(),o=Math.sqrt(u*u+a*a),f=o/2,h=`${(u-o)/2}px`,d=c?h:`${n.left-e-f}px`,g=`${(a-o)/2}px`,p=c?g:`${n.top-r-f}px`;s.className="q-ripple__inner",mi(s,{height:`${o}px`,width:`${o}px`,transform:`translate3d(${d},${p},0) scale3d(.2,.2,1)`,opacity:0}),i.className=`q-ripple${m?" text-"+m:""}`,i.setAttribute("dir","ltr"),i.appendChild(s),B.appendChild(i);const k=()=>{i.remove(),clearTimeout(C)};t.abort.push(k);let C=setTimeout(()=>{s.classList.add("q-ripple__inner--enter"),s.style.transform=`translate3d(${h},${g},0) scale3d(1,1,1)`,s.style.opacity=.2,C=setTimeout(()=>{s.classList.remove("q-ripple__inner--enter"),s.classList.add("q-ripple__inner--leave"),s.style.opacity=0,C=setTimeout(()=>{i.remove(),t.abort.splice(t.abort.indexOf(k),1)},275)},250)},50)}function mo(l,{modifiers:B,value:t,arg:b}){const m=Object.assign({},l.cfg.ripple,B,t);l.modifiers={early:m.early===!0,stop:m.stop===!0,center:m.center===!0,color:m.color||b,keyCodes:[].concat(m.keyCodes||13)}}const va=Ti({name:"ripple",beforeMount(l,B){const t=B.instance.$.appContext.config.globalProperties.$q.config||{};if(t.ripple===!1)return;const b={cfg:t,enabled:B.value!==!1,modifiers:{},abort:[],start(m){b.enabled===!0&&m.qSkipRipple!==!0&&m.type===(b.modifiers.early===!0?"pointerdown":"click")&&po(m,l,b,m.qKeyEvent===!0)},keystart:Xs(m=>{b.enabled===!0&&m.qSkipRipple!==!0&&or(m,b.modifiers.keyCodes)===!0&&m.type===`key${b.modifiers.early===!0?"down":"up"}`&&po(m,l,b,!0)},300)};mo(b,B),l.__qripple=b,Xt(b,"main",[[l,"pointerdown","start","passive"],[l,"click","start","passive"],[l,"keydown","keystart","passive"],[l,"keyup","keystart","passive"]])},updated(l,B){if(B.oldValue!==B.value){const t=l.__qripple;t!==void 0&&(t.enabled=B.value!==!1,t.enabled===!0&&Object(B.value)===B.value&&mo(t,B))}},beforeUnmount(l){const B=l.__qripple;B!==void 0&&(B.abort.forEach(t=>{t()}),pr(B,"main"),delete l._qripple)}}),go={none:0,xs:4,sm:8,md:16,lg:24,xl:32},Gs={xs:8,sm:10,md:14,lg:20,xl:24},Js=["button","submit","reset"],Zs=/[^\s]\/[^\s]/,$s=["flat","outline","push","unelevated"];function el(l,B){return l.flat===!0?"flat":l.outline===!0?"outline":l.push===!0?"push":l.unelevated===!0?"unelevated":B}const tl={...Fr,...ha,type:{type:String,default:"button"},label:[Number,String],icon:String,iconRight:String,...$s.reduce((l,B)=>(l[B]=Boolean)&&l,{}),square:Boolean,rounded:Boolean,glossy:Boolean,size:String,fab:Boolean,fabMini:Boolean,padding:String,color:String,textColor:String,noCaps:Boolean,noWrap:Boolean,dense:Boolean,tabindex:[Number,String],ripple:{type:[Boolean,Object],default:!0},align:{...Fi.align,default:"center"},stack:Boolean,stretch:Boolean,loading:{type:Boolean,default:null},disable:Boolean},rl={...tl,round:Boolean};function nl(l){const B=jr(l,Gs),t=ji(l),{hasRouterLink:b,hasLink:m,linkTag:c,linkAttrs:i,navigateOnClick:s}=Oi({fallbackTag:"button"}),n=v.computed(()=>{const d=l.fab===!1&&l.fabMini===!1?B.value:{};return l.padding!==void 0?Object.assign({},d,{padding:l.padding.split(/\s+/).map(g=>g in go?go[g]+"px":g).join(" "),minWidth:"0",minHeight:"0"}):d}),e=v.computed(()=>l.rounded===!0||l.fab===!0||l.fabMini===!0),r=v.computed(()=>l.disable!==!0&&l.loading!==!0),u=v.computed(()=>r.value===!0?l.tabindex||0:-1),a=v.computed(()=>el(l,"standard")),o=v.computed(()=>{const d={tabindex:u.value};return m.value===!0?Object.assign(d,i.value):Js.includes(l.type)===!0&&(d.type=l.type),c.value==="a"?(l.disable===!0?d["aria-disabled"]="true":d.href===void 0&&(d.role="button"),b.value!==!0&&Zs.test(l.type)===!0&&(d.type=l.type)):l.disable===!0&&(d.disabled="",d["aria-disabled"]="true"),l.loading===!0&&l.percentage!==void 0&&Object.assign(d,{role:"progressbar","aria-valuemin":0,"aria-valuemax":100,"aria-valuenow":l.percentage}),d}),f=v.computed(()=>{let d;l.color!==void 0?l.flat===!0||l.outline===!0?d=`text-${l.textColor||l.color}`:d=`bg-${l.color} text-${l.textColor||"white"}`:l.textColor&&(d=`text-${l.textColor}`);const g=l.round===!0?"round":`rectangle${e.value===!0?" q-btn--rounded":l.square===!0?" q-btn--square":""}`;return`q-btn--${a.value} q-btn--${g}`+(d!==void 0?" "+d:"")+(r.value===!0?" q-btn--actionable q-focusable q-hoverable":l.disable===!0?" disabled":"")+(l.fab===!0?" q-btn--fab":l.fabMini===!0?" q-btn--fab-mini":"")+(l.noCaps===!0?" q-btn--no-uppercase":"")+(l.dense===!0?" q-btn--dense":"")+(l.stretch===!0?" no-border-radius self-stretch":"")+(l.glossy===!0?" glossy":"")+(l.square?" q-btn--square":"")}),h=v.computed(()=>t.value+(l.stack===!0?" column":" row")+(l.noWrap===!0?" no-wrap text-no-wrap":"")+(l.loading===!0?" q-btn__content--hidden":""));return{classes:f,style:n,innerClasses:h,attributes:o,hasLink:m,linkTag:c,navigateOnClick:s,isActionable:r}}const{passiveCapture:Nt}=_t;let Sr=null,kr=null,_r=null;const at=$e({name:"QBtn",props:{...rl,percentage:Number,darkPercentage:Boolean,onTouchstart:[Function,Array]},emits:["click","keydown","mousedown","keyup"],setup(l,{slots:B,emit:t}){const{proxy:b}=v.getCurrentInstance(),{classes:m,style:c,innerClasses:i,attributes:s,hasLink:n,linkTag:e,navigateOnClick:r,isActionable:u}=nl(l),a=v.ref(null),o=v.ref(null);let f=null,h,d=null;const g=v.computed(()=>l.label!==void 0&&l.label!==null&&l.label!==""),p=v.computed(()=>l.disable===!0||l.ripple===!1?!1:{keyCodes:n.value===!0?[13,32]:[13],...l.ripple===!0?{}:l.ripple}),k=v.computed(()=>({center:l.round})),C=v.computed(()=>{const M=Math.max(0,Math.min(100,l.percentage));return M>0?{transition:"transform 0.6s",transform:`translateX(${M-100}%)`}:{}}),T=v.computed(()=>{if(l.loading===!0)return{onMousedown:A,onTouchstart:A,onClick:A,onKeydown:A,onKeyup:A};if(u.value===!0){const M={onClick:V,onKeydown:P,onMousedown:q};if(b.$q.platform.has.touch===!0){const _=l.onTouchstart!==void 0?"":"Passive";M[`onTouchstart${_}`]=N}return M}return{onClick:St}}),D=v.computed(()=>({ref:a,class:"q-btn q-btn-item non-selectable no-outline "+m.value,style:c.value,...s.value,...T.value}));function V(M){if(a.value!==null){if(M!==void 0){if(M.defaultPrevented===!0)return;const _=document.activeElement;if(l.type==="submit"&&_!==document.body&&a.value.contains(_)===!1&&_.contains(a.value)===!1){M.qAvoidFocus!==!0&&a.value.focus();const y=()=>{document.removeEventListener("keydown",St,!0),document.removeEventListener("keyup",y,Nt),a.value?.removeEventListener("blur",y,Nt)};document.addEventListener("keydown",St,!0),document.addEventListener("keyup",y,Nt),a.value.addEventListener("blur",y,Nt)}}r(M)}}function P(M){a.value!==null&&(t("keydown",M),or(M,[13,32])===!0&&kr!==a.value&&(kr!==null&&L(),M.defaultPrevented!==!0&&(M.qAvoidFocus!==!0&&a.value.focus(),kr=a.value,a.value.classList.add("q-btn--active"),document.addEventListener("keyup",W,!0),a.value.addEventListener("blur",W,Nt)),St(M)))}function N(M){a.value!==null&&(t("touchstart",M),M.defaultPrevented!==!0&&(Sr!==a.value&&(Sr!==null&&L(),Sr=a.value,f=M.target,f.addEventListener("touchcancel",W,Nt),f.addEventListener("touchend",W,Nt)),h=!0,d!==null&&clearTimeout(d),d=setTimeout(()=>{d=null,h=!1},200)))}function q(M){a.value!==null&&(M.qSkipRipple=h===!0,t("mousedown",M),M.defaultPrevented!==!0&&_r!==a.value&&(_r!==null&&L(),_r=a.value,a.value.classList.add("q-btn--active"),document.addEventListener("mouseup",W,Nt)))}function W(M){if(a.value!==null&&!(M?.type==="blur"&&document.activeElement===a.value)){if(M?.type==="keyup"){if(kr===a.value&&or(M,[13,32])===!0){const _=new MouseEvent("click",M);_.qKeyEvent=!0,M.defaultPrevented===!0&&Bt(_),M.cancelBubble===!0&&Dt(_),a.value.dispatchEvent(_),St(M),M.qKeyEvent=!0}t("keyup",M)}L()}}function L(M){const _=o.value;M!==!0&&(Sr===a.value||_r===a.value)&&_!==null&&_!==document.activeElement&&(_.setAttribute("tabindex",-1),_.focus()),Sr===a.value&&(f!==null&&(f.removeEventListener("touchcancel",W,Nt),f.removeEventListener("touchend",W,Nt)),Sr=f=null),_r===a.value&&(document.removeEventListener("mouseup",W,Nt),_r=null),kr===a.value&&(document.removeEventListener("keyup",W,!0),a.value?.removeEventListener("blur",W,Nt),kr=null),a.value?.classList.remove("q-btn--active")}function A(M){St(M),M.qSkipRipple=!0}return v.onBeforeUnmount(()=>{L(!0)}),Object.assign(b,{click:M=>{u.value===!0&&V(M)}}),()=>{let M=[];l.icon!==void 0&&M.push(v.h(dt,{name:l.icon,left:l.stack!==!0&&g.value===!0,role:"img"})),g.value===!0&&M.push(v.h("span",{class:"block"},[l.label])),M=It(B.default,M),l.iconRight!==void 0&&l.round===!1&&M.push(v.h(dt,{name:l.iconRight,right:l.stack!==!0&&g.value===!0,role:"img"}));const _=[v.h("span",{class:"q-focus-helper",ref:o})];return l.loading===!0&&l.percentage!==void 0&&_.push(v.h("span",{class:"q-btn__progress absolute-full overflow-hidden"+(l.darkPercentage===!0?" q-btn__progress--dark":"")},[v.h("span",{class:"q-btn__progress-indicator fit block",style:C.value})])),_.push(v.h("span",{class:"q-btn__content text-center col items-center q-anchor--skip "+i.value},M)),l.loading!==null&&_.push(v.h(v.Transition,{name:"q-transition--fade"},()=>l.loading===!0?[v.h("span",{key:"loading",class:"absolute-full flex flex-center"},B.loading!==void 0?B.loading():[v.h(ga)])]:null)),v.withDirectives(v.h(e.value,D.value,_),[[va,p.value,void 0,k.value]])}}}),il={class:"row justify-between"},ol=v.defineComponent({__name:"NavButton",props:{from:{},to:{default:void 0},labelFrom:{},labelTo:{default:void 0},params:{default:()=>({})},query:{default:()=>({})}},setup(l){const B=l,t=v.inject("navContext",null),b=v.inject("router");function m(c){if(!b){console.warn("Dependencies not available:",{router:b});return}t?.setTabs();const i=c==="back"?B.from:B.to;if(!i){console.warn("Destination not provided:",c);return}b.push({name:i,params:B.params,query:B.query})}return(c,i)=>(v.openBlock(),v.createElementBlock("div",il,[v.createVNode(at,{icon:"chevron_left","rounded-sm":"",label:c.labelFrom,"data-cy":"go-back","data-testid":"go-back",onClick:i[0]||(i[0]=s=>m("back"))},null,8,["label"]),c.labelTo?(v.openBlock(),v.createBlock(at,{key:0,label:c.labelTo,color:"primary","text-color":"white","icon-right":"chevron_right","rounded-sm":"","data-cy":"go-next","data-testid":"go-next",onClick:i[1]||(i[1]=s=>m("next"))},null,8,["label"])):v.createCommentVNode("",!0)]))}}),Vt=(l,B)=>{const t=l.__vccOpts||l;for(const[b,m]of B)t[b]=m;return t},al=Vt(ol,[["__scopeId","data-v-8dd99f80"]]),Ot={dark:{type:Boolean,default:null}};function Ft(l,B){return v.computed(()=>l.dark===null?B.dark.isActive:l.dark)}function sl(l,B){const t=v.ref(null),b=v.computed(()=>l.disable===!0?null:v.h("span",{ref:t,class:"no-outline",tabindex:-1}));function m(c){const i=B.value;c?.qAvoidFocus!==!0&&(c?.type.indexOf("key")===0?document.activeElement!==i&&i?.contains(document.activeElement)===!0&&i.focus():t.value!==null&&(c===void 0||i?.contains(c.target)===!0)&&t.value.focus())}return{refocusTargetEl:b,refocusTarget:m}}const Vn={name:String};function ll(l){return v.computed(()=>({type:"hidden",name:l.name,value:l.modelValue}))}function ya(l={}){return(B,t,b)=>{B[t](v.h("input",{class:"hidden"+(b||""),...l.value}))}}function wa(l){return v.computed(()=>l.name||l.for)}const ul={xs:30,sm:35,md:40,lg:50,xl:60},xa={...Ot,...Fr,...Vn,modelValue:{required:!0,default:null},val:{},trueValue:{default:!0},falseValue:{default:!1},indeterminateValue:{default:null},checkedIcon:String,uncheckedIcon:String,indeterminateIcon:String,toggleOrder:{type:String,validator:l=>l==="tf"||l==="ft"},toggleIndeterminate:Boolean,label:String,leftLabel:Boolean,color:String,keepColor:Boolean,dense:Boolean,disable:Boolean,tabindex:[String,Number]},Sa=["update:modelValue"];function ka(l,B){const{props:t,slots:b,emit:m,proxy:c}=v.getCurrentInstance(),{$q:i}=c,s=Ft(t,i),n=v.ref(null),{refocusTargetEl:e,refocusTarget:r}=sl(t,n),u=jr(t,ul),a=v.computed(()=>t.val!==void 0&&Array.isArray(t.modelValue)),o=v.computed(()=>{const L=v.toRaw(t.val);return a.value===!0?t.modelValue.findIndex(A=>v.toRaw(A)===L):-1}),f=v.computed(()=>a.value===!0?o.value!==-1:v.toRaw(t.modelValue)===v.toRaw(t.trueValue)),h=v.computed(()=>a.value===!0?o.value===-1:v.toRaw(t.modelValue)===v.toRaw(t.falseValue)),d=v.computed(()=>f.value===!1&&h.value===!1),g=v.computed(()=>t.disable===!0?-1:t.tabindex||0),p=v.computed(()=>`q-${l} cursor-pointer no-outline row inline no-wrap items-center`+(t.disable===!0?" disabled":"")+(s.value===!0?` q-${l}--dark`:"")+(t.dense===!0?` q-${l}--dense`:"")+(t.leftLabel===!0?" reverse":"")),k=v.computed(()=>{const L=f.value===!0?"truthy":h.value===!0?"falsy":"indet",A=t.color!==void 0&&(t.keepColor===!0||(l==="toggle"?f.value===!0:h.value!==!0))?` text-${t.color}`:"";return`q-${l}__inner relative-position non-selectable q-${l}__inner--${L}${A}`}),C=v.computed(()=>{const L={type:"checkbox"};return t.name!==void 0&&Object.assign(L,{".checked":f.value,"^checked":f.value===!0?"checked":void 0,name:t.name,value:a.value===!0?t.val:t.trueValue}),L}),T=ya(C),D=v.computed(()=>{const L={tabindex:g.value,role:l==="toggle"?"switch":"checkbox","aria-label":t.label,"aria-checked":d.value===!0?"mixed":f.value===!0?"true":"false"};return t.disable===!0&&(L["aria-disabled"]="true"),L});function V(L){L!==void 0&&(St(L),r(L)),t.disable!==!0&&m("update:modelValue",P(),L)}function P(){if(a.value===!0){if(f.value===!0){const L=t.modelValue.slice();return L.splice(o.value,1),L}return t.modelValue.concat([t.val])}if(f.value===!0){if(t.toggleOrder!=="ft"||t.toggleIndeterminate===!1)return t.falseValue}else if(h.value===!0){if(t.toggleOrder==="ft"||t.toggleIndeterminate===!1)return t.trueValue}else return t.toggleOrder!=="ft"?t.trueValue:t.falseValue;return t.indeterminateValue}function N(L){(L.keyCode===13||L.keyCode===32)&&St(L)}function q(L){(L.keyCode===13||L.keyCode===32)&&V(L)}const W=B(f,d);return Object.assign(c,{toggle:V}),()=>{const L=W();t.disable!==!0&&T(L,"unshift",` q-${l}__native absolute q-ma-none q-pa-none`);const A=[v.h("div",{class:k.value,style:u.value,"aria-hidden":"true"},L)];e.value!==null&&A.push(e.value);const M=t.label!==void 0?It(b.default,[t.label]):bt(b.default);return M!==void 0&&A.push(v.h("div",{class:`q-${l}__label q-anchor--skip`},M)),v.h("div",{ref:n,class:p.value,...D.value,onClick:V,onKeydown:N,onKeyup:q},A)}}const cl=()=>v.h("div",{key:"svg",class:"q-checkbox__bg absolute"},[v.h("svg",{class:"q-checkbox__svg fit absolute-full",viewBox:"0 0 24 24"},[v.h("path",{class:"q-checkbox__truthy",fill:"none",d:"M1.73,12.91 8.1,19.28 22.79,4.59"}),v.h("path",{class:"q-checkbox__indet",d:"M4,14H20V10H4"})])]),Mr=$e({name:"QCheckbox",props:xa,emits:Sa,setup(l){const B=cl();function t(b,m){const c=v.computed(()=>(b.value===!0?l.checkedIcon:m.value===!0?l.indeterminateIcon:l.uncheckedIcon)||null);return()=>c.value!==null?[v.h("div",{key:"icon",class:"q-checkbox__icon-container absolute-full flex flex-center no-wrap"},[v.h(dt,{class:"q-checkbox__icon",name:c.value})])]:[B]}return ka("checkbox",t)}}),dl=$e({props:["store","barStyle","verticalBarStyle","horizontalBarStyle"],setup(l){return()=>[v.h("div",{class:l.store.scroll.vertical.barClass.value,style:[l.barStyle,l.verticalBarStyle],"aria-hidden":"true",onMousedown:l.store.onVerticalMousedown}),v.h("div",{class:l.store.scroll.horizontal.barClass.value,style:[l.barStyle,l.horizontalBarStyle],"aria-hidden":"true",onMousedown:l.store.onHorizontalMousedown}),v.withDirectives(v.h("div",{ref:l.store.scroll.vertical.ref,class:l.store.scroll.vertical.thumbClass.value,style:l.store.scroll.vertical.style.value,"aria-hidden":"true"}),l.store.thumbVertDir),v.withDirectives(v.h("div",{ref:l.store.scroll.horizontal.ref,class:l.store.scroll.horizontal.thumbClass.value,style:l.store.scroll.horizontal.style.value,"aria-hidden":"true"}),l.store.thumbHorizDir)]}}),ar=v.ref(!1);let gi;function fl(l,B){const t=/(edg|edge|edga|edgios)\/([\w.]+)/.exec(l)||/(opr)[\/]([\w.]+)/.exec(l)||/(vivaldi)[\/]([\w.]+)/.exec(l)||/(chrome|crios)[\/]([\w.]+)/.exec(l)||/(version)(applewebkit)[\/]([\w.]+).*(safari)[\/]([\w.]+)/.exec(l)||/(webkit)[\/]([\w.]+).*(version)[\/]([\w.]+).*(safari)[\/]([\w.]+)/.exec(l)||/(firefox|fxios)[\/]([\w.]+)/.exec(l)||/(webkit)[\/]([\w.]+)/.exec(l)||/(opera)(?:.*version|)[\/]([\w.]+)/.exec(l)||[];return{browser:t[5]||t[3]||t[1]||"",version:t[4]||t[2]||"0",platform:B[0]||""}}function hl(l){return/(ipad)/.exec(l)||/(ipod)/.exec(l)||/(windows phone)/.exec(l)||/(iphone)/.exec(l)||/(kindle)/.exec(l)||/(silk)/.exec(l)||/(android)/.exec(l)||/(win)/.exec(l)||/(mac)/.exec(l)||/(linux)/.exec(l)||/(cros)/.exec(l)||/(playbook)/.exec(l)||/(bb)/.exec(l)||/(blackberry)/.exec(l)||[]}const _a="ontouchstart"in window||window.navigator.maxTouchPoints>0;function pl(l){const B=l.toLowerCase(),t=hl(B),b=fl(B,t),m={mobile:!1,desktop:!1,cordova:!1,capacitor:!1,nativeMobile:!1,electron:!1,bex:!1,linux:!1,mac:!1,win:!1,cros:!1,chrome:!1,firefox:!1,opera:!1,safari:!1,vivaldi:!1,edge:!1,edgeChromium:!1,ie:!1,webkit:!1,android:!1,ios:!1,ipad:!1,iphone:!1,ipod:!1,kindle:!1,winphone:!1,blackberry:!1,playbook:!1,silk:!1};b.browser&&(m[b.browser]=!0,m.version=b.version,m.versionNumber=parseInt(b.version,10)),b.platform&&(m[b.platform]=!0);const c=m.android||m.ios||m.bb||m.blackberry||m.ipad||m.iphone||m.ipod||m.kindle||m.playbook||m.silk||m["windows phone"];if(c===!0||B.indexOf("mobile")!==-1?m.mobile=!0:m.desktop=!0,m["windows phone"]&&(m.winphone=!0,delete m["windows phone"]),m.edga||m.edgios||m.edg?(m.edge=!0,b.browser="edge"):m.crios?(m.chrome=!0,b.browser="chrome"):m.fxios&&(m.firefox=!0,b.browser="firefox"),(m.ipod||m.ipad||m.iphone)&&(m.ios=!0),m.vivaldi&&(b.browser="vivaldi",m.vivaldi=!0),(m.chrome||m.opr||m.safari||m.vivaldi||m.mobile===!0&&m.ios!==!0&&c!==!0)&&(m.webkit=!0),m.opr&&(b.browser="opera",m.opera=!0),m.safari&&(m.blackberry||m.bb?(b.browser="blackberry",m.blackberry=!0):m.playbook?(b.browser="playbook",m.playbook=!0):m.android?(b.browser="android",m.android=!0):m.kindle?(b.browser="kindle",m.kindle=!0):m.silk&&(b.browser="silk",m.silk=!0)),m.name=b.browser,m.platform=b.platform,B.indexOf("electron")!==-1)m.electron=!0;else if(document.location.href.indexOf("-extension://")!==-1)m.bex=!0;else{if(window.Capacitor!==void 0?(m.capacitor=!0,m.nativeMobile=!0,m.nativeMobileWrapper="capacitor"):(window._cordovaNative!==void 0||window.cordova!==void 0)&&(m.cordova=!0,m.nativeMobile=!0,m.nativeMobileWrapper="cordova"),ar.value===!0&&(gi={is:{...m}}),_a===!0&&m.mac===!0&&(m.desktop===!0&&m.safari===!0||m.nativeMobile===!0&&m.android!==!0&&m.ios!==!0&&m.ipad!==!0)){delete m.mac,delete m.desktop;const i=Math.min(window.innerHeight,window.innerWidth)>414?"ipad":"iphone";Object.assign(m,{mobile:!0,ios:!0,platform:i,[i]:!0})}m.mobile!==!0&&window.navigator.userAgentData&&window.navigator.userAgentData.mobile&&(delete m.desktop,m.mobile=!0)}return m}const bo=navigator.userAgent||navigator.vendor||window.opera,ml={has:{touch:!1,webStorage:!1},within:{iframe:!1}},Et={userAgent:bo,is:pl(bo),has:{touch:_a},within:{iframe:window.self!==window.top}},bi={install(l){const{$q:B}=l;ar.value===!0?(l.onSSRHydrated.push(()=>{Object.assign(B.platform,Et),ar.value=!1}),B.platform=v.reactive(this)):B.platform=this}};{let l;Lt(Et.has,"webStorage",()=>{if(l!==void 0)return l;try{if(window.localStorage)return l=!0,!0}catch{}return l=!1,!1}),Object.assign(bi,Et),ar.value===!0&&(Object.assign(bi,gi,ml),gi=null)}function gl(){const l=v.ref(!ar.value);return l.value===!1&&v.onMounted(()=>{l.value=!0}),{isHydrated:l}}const Ca=typeof ResizeObserver<"u",vo=Ca===!0?{}:{style:"display:block;position:absolute;top:0;left:0;right:0;bottom:0;height:100%;width:100%;overflow:hidden;pointer-events:none;z-index:-1;",url:"about:blank"},Ir=$e({name:"QResizeObserver",props:{debounce:{type:[String,Number],default:100}},emits:["resize"],setup(l,{emit:B}){let t=null,b,m={width:-1,height:-1};function c(n){n===!0||l.debounce===0||l.debounce==="0"?i():t===null&&(t=setTimeout(i,l.debounce))}function i(){if(t!==null&&(clearTimeout(t),t=null),b){const{offsetWidth:n,offsetHeight:e}=b;(n!==m.width||e!==m.height)&&(m={width:n,height:e},B("resize",m))}}const{proxy:s}=v.getCurrentInstance();if(s.trigger=c,Ca===!0){let n;const e=r=>{b=s.$el.parentNode,b?(n=new ResizeObserver(c),n.observe(b),i()):r!==!0&&v.nextTick(()=>{e(!0)})};return v.onMounted(()=>{e()}),v.onBeforeUnmount(()=>{t!==null&&clearTimeout(t),n!==void 0&&(n.disconnect!==void 0?n.disconnect():b&&n.unobserve(b))}),Ln}else{let n=function(){t!==null&&(clearTimeout(t),t=null),u!==void 0&&(u.removeEventListener!==void 0&&u.removeEventListener("resize",c,_t.passive),u=void 0)},e=function(){n(),b?.contentDocument&&(u=b.contentDocument.defaultView,u.addEventListener("resize",c,_t.passive),i())};const{isHydrated:r}=gl();let u;return v.onMounted(()=>{v.nextTick(()=>{b=s.$el,b&&e()})}),v.onBeforeUnmount(n),()=>{if(r.value===!0)return v.h("object",{class:"q--avoid-card-border",style:vo.style,tabindex:-1,type:"text/html",data:vo.url,"aria-hidden":"true",onLoad:e})}}}}),qn=[Element,String],bl=[null,document,document.body,document.scrollingElement,document.documentElement];function zn(l,B){let t=Ys(B);if(t===void 0){if(l==null)return window;t=l.closest(".scroll,.scroll-y,.overflow-auto")}return bl.includes(t)?window:t}function Pi(l){return l===window?window.pageYOffset||window.scrollY||document.body.scrollTop||0:l.scrollTop}function Ni(l){return l===window?window.pageXOffset||window.scrollX||document.body.scrollLeft||0:l.scrollLeft}function Aa(l,B,t=0){const b=arguments[3]===void 0?performance.now():arguments[3],m=Pi(l);if(t<=0){m!==B&&vi(l,B);return}requestAnimationFrame(c=>{const i=c-b,s=m+(B-m)/Math.max(i,t)*i;vi(l,s),s!==B&&Aa(l,B,t-i,c)})}function Ea(l,B,t=0){const b=arguments[3]===void 0?performance.now():arguments[3],m=Ni(l);if(t<=0){m!==B&&yi(l,B);return}requestAnimationFrame(c=>{const i=c-b,s=m+(B-m)/Math.max(i,t)*i;yi(l,s),s!==B&&Ea(l,B,t-i,c)})}function vi(l,B){if(l===window){window.scrollTo(window.pageXOffset||window.scrollX||document.body.scrollLeft||0,B);return}l.scrollTop=B}function yi(l,B){if(l===window){window.scrollTo(B,window.pageYOffset||window.scrollY||document.body.scrollTop||0);return}l.scrollLeft=B}function yo(l,B,t){if(t){Aa(l,B,t);return}vi(l,B)}function Jn(l,B,t){if(t){Ea(l,B,t);return}yi(l,B)}let un;function Sn(){if(un!==void 0)return un;const l=document.createElement("p"),B=document.createElement("div");mi(l,{width:"100%",height:"200px"}),mi(B,{position:"absolute",top:"0px",left:"0px",visibility:"hidden",width:"200px",height:"150px",overflow:"hidden"}),B.appendChild(l),document.body.appendChild(B);const t=l.offsetWidth;B.style.overflow="scroll";let b=l.offsetWidth;return t===b&&(b=B.clientWidth),B.remove(),un=t-b,un}function vl(l,B=!0){return!l||l.nodeType!==Node.ELEMENT_NODE?!1:B?l.scrollHeight>l.clientHeight&&(l.classList.contains("scroll")||l.classList.contains("overflow-auto")||["auto","scroll"].includes(window.getComputedStyle(l)["overflow-y"])):l.scrollWidth>l.clientWidth&&(l.classList.contains("scroll")||l.classList.contains("overflow-auto")||["auto","scroll"].includes(window.getComputedStyle(l)["overflow-x"]))}const{passive:wo}=_t,yl=["both","horizontal","vertical"],Ma=$e({name:"QScrollObserver",props:{axis:{type:String,validator:l=>yl.includes(l),default:"vertical"},debounce:[String,Number],scrollTarget:qn},emits:["scroll"],setup(l,{emit:B}){const t={position:{top:0,left:0},direction:"down",directionChanged:!1,delta:{top:0,left:0},inflectionPoint:{top:0,left:0}};let b=null,m,c;v.watch(()=>l.scrollTarget,()=>{n(),s()});function i(){b?.();const u=Math.max(0,Pi(m)),a=Ni(m),o={top:u-t.position.top,left:a-t.position.left};if(l.axis==="vertical"&&o.top===0||l.axis==="horizontal"&&o.left===0)return;const f=Math.abs(o.top)>=Math.abs(o.left)?o.top<0?"up":"down":o.left<0?"left":"right";t.position={top:u,left:a},t.directionChanged=t.direction!==f,t.delta=o,t.directionChanged===!0&&(t.direction=f,t.inflectionPoint=t.position),B("scroll",{...t})}function s(){m=zn(c,l.scrollTarget),m.addEventListener("scroll",e,wo),e(!0)}function n(){m!==void 0&&(m.removeEventListener("scroll",e,wo),m=void 0)}function e(u){if(u===!0||l.debounce===0||l.debounce==="0")i();else if(b===null){const[a,o]=l.debounce?[setTimeout(i,l.debounce),clearTimeout]:[requestAnimationFrame(i),cancelAnimationFrame];b=()=>{o(a),b=null}}}const{proxy:r}=v.getCurrentInstance();return v.watch(()=>r.$q.lang.rtl,i),v.onMounted(()=>{c=r.$el.parentNode,s()}),v.onBeforeUnmount(()=>{b?.(),n()}),Object.assign(r,{trigger:e,getPosition:()=>t}),Ln}}),Li={left:!0,right:!0,up:!0,down:!0,horizontal:!0,vertical:!0},wl=Object.keys(Li);Li.all=!0;function xo(l){const B={};for(const t of wl)l[t]===!0&&(B[t]=!0);return Object.keys(B).length===0?Li:(B.horizontal===!0?B.left=B.right=!0:B.left===!0&&B.right===!0&&(B.horizontal=!0),B.vertical===!0?B.up=B.down=!0:B.up===!0&&B.down===!0&&(B.vertical=!0),B.horizontal===!0&&B.vertical===!0&&(B.all=!0),B)}const xl=["INPUT","TEXTAREA"];function So(l,B){return B.event===void 0&&l.target!==void 0&&l.target.draggable!==!0&&typeof B.handler=="function"&&xl.includes(l.target.nodeName.toUpperCase())===!1&&(l.qClonedBy===void 0||l.qClonedBy.indexOf(B.uid)===-1)}function An(){if(window.getSelection!==void 0){const l=window.getSelection();l.empty!==void 0?l.empty():l.removeAllRanges!==void 0&&(l.removeAllRanges(),bi.is.mobile!==!0&&l.addRange(document.createRange()))}else document.selection!==void 0&&document.selection.empty()}function Zn(l,B,t){const b=Qr(l);let m,c=b.left-B.event.x,i=b.top-B.event.y,s=Math.abs(c),n=Math.abs(i);const e=B.direction;e.horizontal===!0&&e.vertical!==!0?m=c<0?"left":"right":e.horizontal!==!0&&e.vertical===!0?m=i<0?"up":"down":e.up===!0&&i<0?(m="up",s>n&&(e.left===!0&&c<0?m="left":e.right===!0&&c>0&&(m="right"))):e.down===!0&&i>0?(m="down",s>n&&(e.left===!0&&c<0?m="left":e.right===!0&&c>0&&(m="right"))):e.left===!0&&c<0?(m="left",s<n&&(e.up===!0&&i<0?m="up":e.down===!0&&i>0&&(m="down"))):e.right===!0&&c>0&&(m="right",s<n&&(e.up===!0&&i<0?m="up":e.down===!0&&i>0&&(m="down")));let r=!1;if(m===void 0&&t===!1){if(B.event.isFirst===!0||B.event.lastDir===void 0)return{};m=B.event.lastDir,r=!0,m==="left"||m==="right"?(b.left-=c,s=0,c=0):(b.top-=i,n=0,i=0)}return{synthetic:r,payload:{evt:l,touch:B.event.mouse!==!0,mouse:B.event.mouse===!0,position:b,direction:m,isFirst:B.event.isFirst,isFinal:t===!0,duration:Date.now()-B.event.time,distance:{x:s,y:n},offset:{x:c,y:i},delta:{x:b.left-B.event.lastX,y:b.top-B.event.lastY}}}}let Sl=0;const ko=Ti({name:"touch-pan",beforeMount(l,{value:B,modifiers:t}){if(t.mouse!==!0&&Et.has.touch!==!0)return;function b(c,i){t.mouse===!0&&i===!0?St(c):(t.stop===!0&&Dt(c),t.prevent===!0&&Bt(c))}const m={uid:"qvtp_"+Sl++,handler:B,modifiers:t,direction:xo(t),noop:Ln,mouseStart(c){So(c,m)&&Qs(c)&&(Xt(m,"temp",[[document,"mousemove","move","notPassiveCapture"],[document,"mouseup","end","passiveCapture"]]),m.start(c,!0))},touchStart(c){if(So(c,m)){const i=c.target;Xt(m,"temp",[[i,"touchmove","move","notPassiveCapture"],[i,"touchcancel","end","passiveCapture"],[i,"touchend","end","passiveCapture"]]),m.start(c)}},start(c,i){if(Et.is.firefox===!0&&Gn(l,!0),m.lastEvt=c,i===!0||t.stop===!0){if(m.direction.all!==!0&&(i!==!0||m.modifiers.mouseAllDir!==!0&&m.modifiers.mousealldir!==!0)){const e=c.type.indexOf("mouse")!==-1?new MouseEvent(c.type,c):new TouchEvent(c.type,c);c.defaultPrevented===!0&&Bt(e),c.cancelBubble===!0&&Dt(e),Object.assign(e,{qKeyEvent:c.qKeyEvent,qClickOutside:c.qClickOutside,qAnchorHandled:c.qAnchorHandled,qClonedBy:c.qClonedBy===void 0?[m.uid]:c.qClonedBy.concat(m.uid)}),m.initialEvent={target:c.target,event:e}}Dt(c)}const{left:s,top:n}=Qr(c);m.event={x:s,y:n,time:Date.now(),mouse:i===!0,detected:!1,isFirst:!0,isFinal:!1,lastX:s,lastY:n}},move(c){if(m.event===void 0)return;const i=Qr(c),s=i.left-m.event.x,n=i.top-m.event.y;if(s===0&&n===0)return;m.lastEvt=c;const e=m.event.mouse===!0,r=()=>{b(c,e);let o;t.preserveCursor!==!0&&t.preservecursor!==!0&&(o=document.documentElement.style.cursor||"",document.documentElement.style.cursor="grabbing"),e===!0&&document.body.classList.add("no-pointer-events--children"),document.body.classList.add("non-selectable"),An(),m.styleCleanup=f=>{if(m.styleCleanup=void 0,o!==void 0&&(document.documentElement.style.cursor=o),document.body.classList.remove("non-selectable"),e===!0){const h=()=>{document.body.classList.remove("no-pointer-events--children")};f!==void 0?setTimeout(()=>{h(),f()},50):h()}else f!==void 0&&f()}};if(m.event.detected===!0){m.event.isFirst!==!0&&b(c,m.event.mouse);const{payload:o,synthetic:f}=Zn(c,m,!1);o!==void 0&&(m.handler(o)===!1?m.end(c):(m.styleCleanup===void 0&&m.event.isFirst===!0&&r(),m.event.lastX=o.position.left,m.event.lastY=o.position.top,m.event.lastDir=f===!0?void 0:o.direction,m.event.isFirst=!1));return}if(m.direction.all===!0||e===!0&&(m.modifiers.mouseAllDir===!0||m.modifiers.mousealldir===!0)){r(),m.event.detected=!0,m.move(c);return}const u=Math.abs(s),a=Math.abs(n);u!==a&&(m.direction.horizontal===!0&&u>a||m.direction.vertical===!0&&u<a||m.direction.up===!0&&u<a&&n<0||m.direction.down===!0&&u<a&&n>0||m.direction.left===!0&&u>a&&s<0||m.direction.right===!0&&u>a&&s>0?(m.event.detected=!0,m.move(c)):m.end(c,!0))},end(c,i){if(m.event!==void 0){if(pr(m,"temp"),Et.is.firefox===!0&&Gn(l,!1),i===!0)m.styleCleanup?.(),m.event.detected!==!0&&m.initialEvent!==void 0&&m.initialEvent.target.dispatchEvent(m.initialEvent.event);else if(m.event.detected===!0){m.event.isFirst===!0&&m.handler(Zn(c===void 0?m.lastEvt:c,m).payload);const{payload:s}=Zn(c===void 0?m.lastEvt:c,m,!0),n=()=>{m.handler(s)};m.styleCleanup!==void 0?m.styleCleanup(n):n()}m.event=void 0,m.initialEvent=void 0,m.lastEvt=void 0}}};if(l.__qtouchpan=m,t.mouse===!0){const c=t.mouseCapture===!0||t.mousecapture===!0?"Capture":"";Xt(m,"main",[[l,"mousedown","mouseStart",`passive${c}`]])}Et.has.touch===!0&&Xt(m,"main",[[l,"touchstart","touchStart",`passive${t.capture===!0?"Capture":""}`],[l,"touchmove","noop","notPassiveCapture"]])},updated(l,B){const t=l.__qtouchpan;t!==void 0&&(B.oldValue!==B.value&&(typeof value!="function"&&t.end(),t.handler=B.value),t.direction=xo(B.modifiers))},beforeUnmount(l){const B=l.__qtouchpan;B!==void 0&&(B.event!==void 0&&B.end(),pr(B,"main"),pr(B,"temp"),Et.is.firefox===!0&&Gn(l,!1),B.styleCleanup?.(),delete l.__qtouchpan)}});function kl(l){return l.charAt(0).toUpperCase()+l.slice(1)}function Nr(l,B,t){return t<=B?B:Math.min(t,Math.max(B,l))}function _o(l,B,t){if(t<=B)return B;const b=t-B+1;let m=B+(l-B)%b;return m<B&&(m=b+m),m===0?0:m}function vt(l,B=2,t="0"){if(l==null)return l;const b=""+l;return b.length>=B?b:new Array(B-b.length+1).join(t)+b}function Vi(l,B=250,t){let b=null;function m(){const c=arguments,i=()=>{b=null,l.apply(this,c)};b!==null&&clearTimeout(b),b=setTimeout(i,B)}return m.cancel=()=>{b!==null&&clearTimeout(b)},m}const Co=["vertical","horizontal"],$n={vertical:{offset:"offsetY",scroll:"scrollTop",dir:"down",dist:"y"},horizontal:{offset:"offsetX",scroll:"scrollLeft",dir:"right",dist:"x"}},Ao={prevent:!0,mouse:!0,mouseAllDir:!0},Eo=l=>l>=250?50:Math.ceil(l/5),_l=$e({name:"QScrollArea",props:{...Ot,thumbStyle:Object,verticalThumbStyle:Object,horizontalThumbStyle:Object,barStyle:[Array,String,Object],verticalBarStyle:[Array,String,Object],horizontalBarStyle:[Array,String,Object],verticalOffset:{type:Array,default:[0,0]},horizontalOffset:{type:Array,default:[0,0]},contentStyle:[Array,String,Object],contentActiveStyle:[Array,String,Object],delay:{type:[String,Number],default:1e3},visible:{type:Boolean,default:null},tabindex:[String,Number],onScroll:Function},setup(l,{slots:B,emit:t}){const b=v.ref(!1),m=v.ref(!1),c=v.ref(!1),i={vertical:v.ref(0),horizontal:v.ref(0)},s={vertical:{ref:v.ref(null),position:v.ref(0),size:v.ref(0)},horizontal:{ref:v.ref(null),position:v.ref(0),size:v.ref(0)}},{proxy:n}=v.getCurrentInstance(),e=Ft(l,n.$q);let r=null,u;const a=v.ref(null),o=v.computed(()=>"q-scrollarea"+(e.value===!0?" q-scrollarea--dark":""));Object.assign(i,{verticalInner:v.computed(()=>i.vertical.value-l.verticalOffset[0]-l.verticalOffset[1]),horizontalInner:v.computed(()=>i.horizontal.value-l.horizontalOffset[0]-l.horizontalOffset[1])}),s.vertical.percentage=v.computed(()=>{const M=s.vertical.size.value-i.vertical.value;if(M<=0)return 0;const _=Nr(s.vertical.position.value/M,0,1);return Math.round(_*1e4)/1e4}),s.vertical.thumbHidden=v.computed(()=>(l.visible===null?c.value:l.visible)!==!0&&b.value===!1&&m.value===!1||s.vertical.size.value<=i.vertical.value+1),s.vertical.thumbStart=v.computed(()=>l.verticalOffset[0]+s.vertical.percentage.value*(i.verticalInner.value-s.vertical.thumbSize.value)),s.vertical.thumbSize=v.computed(()=>Math.round(Nr(i.verticalInner.value*i.verticalInner.value/s.vertical.size.value,Eo(i.verticalInner.value),i.verticalInner.value))),s.vertical.style=v.computed(()=>({...l.thumbStyle,...l.verticalThumbStyle,top:`${s.vertical.thumbStart.value}px`,height:`${s.vertical.thumbSize.value}px`,right:`${l.horizontalOffset[1]}px`})),s.vertical.thumbClass=v.computed(()=>"q-scrollarea__thumb q-scrollarea__thumb--v absolute-right"+(s.vertical.thumbHidden.value===!0?" q-scrollarea__thumb--invisible":"")),s.vertical.barClass=v.computed(()=>"q-scrollarea__bar q-scrollarea__bar--v absolute-right"+(s.vertical.thumbHidden.value===!0?" q-scrollarea__bar--invisible":"")),s.horizontal.percentage=v.computed(()=>{const M=s.horizontal.size.value-i.horizontal.value;if(M<=0)return 0;const _=Nr(Math.abs(s.horizontal.position.value)/M,0,1);return Math.round(_*1e4)/1e4}),s.horizontal.thumbHidden=v.computed(()=>(l.visible===null?c.value:l.visible)!==!0&&b.value===!1&&m.value===!1||s.horizontal.size.value<=i.horizontal.value+1),s.horizontal.thumbStart=v.computed(()=>l.horizontalOffset[0]+s.horizontal.percentage.value*(i.horizontalInner.value-s.horizontal.thumbSize.value)),s.horizontal.thumbSize=v.computed(()=>Math.round(Nr(i.horizontalInner.value*i.horizontalInner.value/s.horizontal.size.value,Eo(i.horizontalInner.value),i.horizontalInner.value))),s.horizontal.style=v.computed(()=>({...l.thumbStyle,...l.horizontalThumbStyle,[n.$q.lang.rtl===!0?"right":"left"]:`${s.horizontal.thumbStart.value}px`,width:`${s.horizontal.thumbSize.value}px`,bottom:`${l.verticalOffset[1]}px`})),s.horizontal.thumbClass=v.computed(()=>"q-scrollarea__thumb q-scrollarea__thumb--h absolute-bottom"+(s.horizontal.thumbHidden.value===!0?" q-scrollarea__thumb--invisible":"")),s.horizontal.barClass=v.computed(()=>"q-scrollarea__bar q-scrollarea__bar--h absolute-bottom"+(s.horizontal.thumbHidden.value===!0?" q-scrollarea__bar--invisible":""));const f=v.computed(()=>s.vertical.thumbHidden.value===!0&&s.horizontal.thumbHidden.value===!0?l.contentStyle:l.contentActiveStyle);function h(){const M={};return Co.forEach(_=>{const y=s[_];Object.assign(M,{[_+"Position"]:y.position.value,[_+"Percentage"]:y.percentage.value,[_+"Size"]:y.size.value,[_+"ContainerSize"]:i[_].value,[_+"ContainerInnerSize"]:i[_+"Inner"].value})}),M}const d=Vi(()=>{const M=h();M.ref=n,t("scroll",M)},0);function g(M,_,y){if(Co.includes(M)===!1){console.error("[QScrollArea]: wrong first param of setScrollPosition (vertical/horizontal)");return}(M==="vertical"?yo:Jn)(a.value,_,y)}function p({height:M,width:_}){let y=!1;i.vertical.value!==M&&(i.vertical.value=M,y=!0),i.horizontal.value!==_&&(i.horizontal.value=_,y=!0),y===!0&&V()}function k({position:M}){let _=!1;s.vertical.position.value!==M.top&&(s.vertical.position.value=M.top,_=!0),s.horizontal.position.value!==M.left&&(s.horizontal.position.value=M.left,_=!0),_===!0&&V()}function C({height:M,width:_}){s.horizontal.size.value!==_&&(s.horizontal.size.value=_,V()),s.vertical.size.value!==M&&(s.vertical.size.value=M,V())}function T(M,_){const y=s[_];if(M.isFirst===!0){if(y.thumbHidden.value===!0)return;u=y.position.value,m.value=!0}else if(m.value!==!0)return;M.isFinal===!0&&(m.value=!1);const x=$n[_],w=(y.size.value-i[_].value)/(i[_+"Inner"].value-y.thumbSize.value),S=M.distance[x.dist],E=u+(M.direction===x.dir?1:-1)*S*w;P(E,_)}function D(M,_){const y=s[_];if(y.thumbHidden.value!==!0){const x=_==="vertical"?l.verticalOffset[0]:l.horizontalOffset[0],w=M[$n[_].offset]-x,S=y.thumbStart.value-x;if(w<S||w>S+y.thumbSize.value){const E=w-y.thumbSize.value/2,O=Nr(E/(i[_+"Inner"].value-y.thumbSize.value),0,1);P(O*Math.max(0,y.size.value-i[_].value),_)}y.ref.value!==null&&y.ref.value.dispatchEvent(new MouseEvent(M.type,M))}}function V(){b.value=!0,r!==null&&clearTimeout(r),r=setTimeout(()=>{r=null,b.value=!1},l.delay),l.onScroll!==void 0&&d()}function P(M,_){a.value[$n[_].scroll]=M}let N=null;function q(){N!==null&&clearTimeout(N),N=setTimeout(()=>{N=null,c.value=!0},n.$q.platform.is.ios?50:0)}function W(){N!==null&&(clearTimeout(N),N=null),c.value=!1}let L=null;v.watch(()=>n.$q.lang.rtl,M=>{a.value!==null&&Jn(a.value,Math.abs(s.horizontal.position.value)*(M===!0?-1:1))}),v.onDeactivated(()=>{L={top:s.vertical.position.value,left:s.horizontal.position.value}}),v.onActivated(()=>{if(L===null)return;const M=a.value;M!==null&&(Jn(M,L.left),yo(M,L.top))}),v.onBeforeUnmount(d.cancel),Object.assign(n,{getScrollTarget:()=>a.value,getScroll:h,getScrollPosition:()=>({top:s.vertical.position.value,left:s.horizontal.position.value}),getScrollPercentage:()=>({top:s.vertical.percentage.value,left:s.horizontal.percentage.value}),setScrollPosition:g,setScrollPercentage(M,_,y){g(M,_*(s[M].size.value-i[M].value)*(M==="horizontal"&&n.$q.lang.rtl===!0?-1:1),y)}});const A={scroll:s,thumbVertDir:[[ko,M=>{T(M,"vertical")},void 0,{vertical:!0,...Ao}]],thumbHorizDir:[[ko,M=>{T(M,"horizontal")},void 0,{horizontal:!0,...Ao}]],onVerticalMousedown(M){D(M,"vertical")},onHorizontalMousedown(M){D(M,"horizontal")}};return()=>v.h("div",{class:o.value,onMouseenter:q,onMouseleave:W},[v.h("div",{ref:a,class:"q-scrollarea__container scroll relative-position fit hide-scrollbar",tabindex:l.tabindex!==void 0?l.tabindex:void 0},[v.h("div",{class:"q-scrollarea__content absolute",style:f.value},It(B.default,[v.h(Ir,{debounce:0,onResize:C})])),v.h(Ma,{axis:"both",onScroll:k})]),v.h(Ir,{debounce:0,onResize:p}),v.h(dl,{store:A,barStyle:l.barStyle,verticalBarStyle:l.verticalBarStyle,horizontalBarStyle:l.horizontalBarStyle})])}}),Dr=$e({name:"QCard",props:{...Ot,tag:{type:String,default:"div"},square:Boolean,flat:Boolean,bordered:Boolean},setup(l,{slots:B}){const{proxy:{$q:t}}=v.getCurrentInstance(),b=Ft(l,t),m=v.computed(()=>"q-card"+(b.value===!0?" q-card--dark q-dark":"")+(l.bordered===!0?" q-card--bordered":"")+(l.square===!0?" q-card--square no-border-radius":"")+(l.flat===!0?" q-card--flat no-shadow":""));return()=>v.h(l.tag,{class:m.value},bt(B.default))}}),Ta={target:{type:[Boolean,String,Element],default:!0},noParentEvent:Boolean},Ra={...Ta,contextMenu:Boolean};function qi({showing:l,avoidEmit:B,configureAnchorEl:t}){const{props:b,proxy:m,emit:c}=v.getCurrentInstance(),i=v.ref(null);let s=null;function n(o){return i.value===null?!1:o===void 0||o.touches===void 0||o.touches.length<=1}const e={};t===void 0&&(Object.assign(e,{hide(o){m.hide(o)},toggle(o){m.toggle(o),o.qAnchorHandled=!0},toggleKey(o){or(o,13)===!0&&e.toggle(o)},contextClick(o){m.hide(o),Bt(o),v.nextTick(()=>{m.show(o),o.qAnchorHandled=!0})},prevent:Bt,mobileTouch(o){if(e.mobileCleanup(o),n(o)!==!0)return;m.hide(o),i.value.classList.add("non-selectable");const f=o.target;Xt(e,"anchor",[[f,"touchmove","mobileCleanup","passive"],[f,"touchend","mobileCleanup","passive"],[f,"touchcancel","mobileCleanup","passive"],[i.value,"contextmenu","prevent","notPassive"]]),s=setTimeout(()=>{s=null,m.show(o),o.qAnchorHandled=!0},300)},mobileCleanup(o){i.value.classList.remove("non-selectable"),s!==null&&(clearTimeout(s),s=null),l.value===!0&&o!==void 0&&An()}}),t=function(o=b.contextMenu){if(b.noParentEvent===!0||i.value===null)return;let f;o===!0?m.$q.platform.is.mobile===!0?f=[[i.value,"touchstart","mobileTouch","passive"]]:f=[[i.value,"mousedown","hide","passive"],[i.value,"contextmenu","contextClick","notPassive"]]:f=[[i.value,"click","toggle","passive"],[i.value,"keyup","toggleKey","passive"]],Xt(e,"anchor",f)});function r(){pr(e,"anchor")}function u(o){for(i.value=o;i.value.classList.contains("q-anchor--skip");)i.value=i.value.parentNode;t()}function a(){if(b.target===!1||b.target===""||m.$el.parentNode===null)i.value=null;else if(b.target===!0)u(m.$el.parentNode);else{let o=b.target;if(typeof b.target=="string")try{o=document.querySelector(b.target)}catch{o=void 0}o!=null?(i.value=o.$el||o,t()):(i.value=null,console.error(`Anchor: target "${b.target}" not found`))}}return v.watch(()=>b.contextMenu,o=>{i.value!==null&&(r(),t(o))}),v.watch(()=>b.target,()=>{i.value!==null&&r(),a()}),v.watch(()=>b.noParentEvent,o=>{i.value!==null&&(o===!0?r():t())}),v.onMounted(()=>{a(),B!==!0&&b.modelValue===!0&&i.value===null&&c("update:modelValue",!1)}),v.onBeforeUnmount(()=>{s!==null&&clearTimeout(s),r()}),{anchorEl:i,canShow:n,anchorEvents:e}}function Ba(l,B){const t=v.ref(null);let b;function m(s,n){const e=`${n!==void 0?"add":"remove"}EventListener`,r=n!==void 0?n:b;s!==window&&s[e]("scroll",r,_t.passive),window[e]("scroll",r,_t.passive),b=n}function c(){t.value!==null&&(m(t.value),t.value=null)}const i=v.watch(()=>l.noParentEvent,()=>{t.value!==null&&(c(),B())});return v.onBeforeUnmount(i),{localScrollTarget:t,unconfigureScrollTarget:c,changeScrollEvent:m}}const zi={modelValue:{type:Boolean,default:null},"onUpdate:modelValue":[Function,Array]},Ui=["beforeShow","show","beforeHide","hide"];function Wi({showing:l,canShow:B,hideOnRouteChange:t,handleShow:b,handleHide:m,processOnMount:c}){const i=v.getCurrentInstance(),{props:s,emit:n,proxy:e}=i;let r;function u(p){l.value===!0?f(p):a(p)}function a(p){if(s.disable===!0||p?.qAnchorHandled===!0||B!==void 0&&B(p)!==!0)return;const k=s["onUpdate:modelValue"]!==void 0;k===!0&&(n("update:modelValue",!0),r=p,v.nextTick(()=>{r===p&&(r=void 0)})),(s.modelValue===null||k===!1)&&o(p)}function o(p){l.value!==!0&&(l.value=!0,n("beforeShow",p),b!==void 0?b(p):n("show",p))}function f(p){if(s.disable===!0)return;const k=s["onUpdate:modelValue"]!==void 0;k===!0&&(n("update:modelValue",!1),r=p,v.nextTick(()=>{r===p&&(r=void 0)})),(s.modelValue===null||k===!1)&&h(p)}function h(p){l.value!==!1&&(l.value=!1,n("beforeHide",p),m!==void 0?m(p):n("hide",p))}function d(p){s.disable===!0&&p===!0?s["onUpdate:modelValue"]!==void 0&&n("update:modelValue",!1):p===!0!==l.value&&(p===!0?o:h)(r)}v.watch(()=>s.modelValue,d),t!==void 0&&Bi(i)===!0&&v.watch(()=>e.$route.fullPath,()=>{t.value===!0&&l.value===!0&&f()}),v.onMounted(()=>{d(s.modelValue)});const g={show:a,hide:f,toggle:u};return Object.assign(e,g),g}let fr=[],Kr=[];function Ia(l){Kr=Kr.filter(B=>B!==l)}function Cl(l){Ia(l),Kr.push(l)}function Mo(l){Ia(l),Kr.length===0&&fr.length!==0&&(fr[fr.length-1](),fr=[])}function Jr(l){Kr.length===0?l():fr.push(l)}function Al(l){fr=fr.filter(B=>B!==l)}const To={};let El=1,Ml=document.body;function Tl(l,B){const t=document.createElement("div");if(t.id=B!==void 0?`q-portal--${B}--${El++}`:l,To.globalNodes!==void 0){const b=To.globalNodes.class;b!==void 0&&(t.className=b)}return Ml.appendChild(t),t}function Rl(l){l.remove()}const Tr=[];function Bl(l){return Tr.find(B=>B.contentEl!==null&&B.contentEl.contains(l))}function Oa(l,B){do{if(l.$options.name==="QMenu"){if(l.hide(B),l.$props.separateClosePopup===!0)return xn(l)}else if(l.__qPortal===!0){const t=xn(l);return t?.$options.name==="QPopupProxy"?(l.hide(B),t):l}l=xn(l)}while(l!=null)}function Il(l,B,t){for(;t!==0&&l!==void 0&&l!==null;){if(l.__qPortal===!0){if(t--,l.$options.name==="QMenu"){l=Oa(l,B);continue}l.hide(B)}l=xn(l)}}const Ol=$e({name:"QPortal",setup(l,{slots:B}){return()=>B.default()}});function Fl(l){for(l=l.parent;l!=null;){if(l.type.name==="QGlobalDialog")return!0;if(l.type.name==="QDialog"||l.type.name==="QMenu")return!1;l=l.parent}return!1}function Hi(l,B,t,b){const m=v.ref(!1),c=v.ref(!1);let i=null;const s={},n=b==="dialog"&&Fl(l);function e(u){if(u===!0){Mo(s),c.value=!0;return}c.value=!1,m.value===!1&&(n===!1&&i===null&&(i=Tl(!1,b)),m.value=!0,Tr.push(l.proxy),Cl(s))}function r(u){if(c.value=!1,u!==!0)return;Mo(s),m.value=!1;const a=Tr.indexOf(l.proxy);a!==-1&&Tr.splice(a,1),i!==null&&(Rl(i),i=null)}return v.onUnmounted(()=>{r(!0)}),l.proxy.__qPortal=!0,Lt(l.proxy,"contentEl",()=>B.value),{showPortal:e,hidePortal:r,portalIsActive:m,portalIsAccessible:c,renderPortal:()=>n===!0?t():m.value===!0?[v.h(v.Teleport,{to:i},v.h(Ol,t))]:void 0}}const Yr={transitionShow:{type:String,default:"fade"},transitionHide:{type:String,default:"fade"},transitionDuration:{type:[String,Number],default:300}};function Yi(l,B=()=>{},t=()=>{}){return{transitionProps:v.computed(()=>{const b=`q-transition--${l.transitionShow||B()}`,m=`q-transition--${l.transitionHide||t()}`;return{appear:!0,enterFromClass:`${b}-enter-from`,enterActiveClass:`${b}-enter-active`,enterToClass:`${b}-enter-to`,leaveFromClass:`${m}-leave-from`,leaveActiveClass:`${m}-leave-active`,leaveToClass:`${m}-leave-to`}}),transitionStyle:v.computed(()=>`--q-transition-duration: ${l.transitionDuration}ms`)}}function Qi(){let l;const B=v.getCurrentInstance();function t(){l=void 0}return v.onDeactivated(t),v.onBeforeUnmount(t),{removeTick:t,registerTick(b){l=b,v.nextTick(()=>{l===b&&(Ii(B)===!1&&l(),l=void 0)})}}}function Ki(){let l=null;const B=v.getCurrentInstance();function t(){l!==null&&(clearTimeout(l),l=null)}return v.onDeactivated(t),v.onBeforeUnmount(t),{removeTimeout:t,registerTimeout(b,m){t(),Ii(B)===!1&&(l=setTimeout(()=>{l=null,b()},m))}}}const mr=[];let Or;function jl(l){Or=l.keyCode===27}function Dl(){Or===!0&&(Or=!1)}function Pl(l){Or===!0&&(Or=!1,or(l,27)===!0&&mr[mr.length-1](l))}function Fa(l){window[l]("keydown",jl),window[l]("blur",Dl),window[l]("keyup",Pl),Or=!1}function ja(l){Et.is.desktop===!0&&(mr.push(l),mr.length===1&&Fa("addEventListener"))}function En(l){const B=mr.indexOf(l);B!==-1&&(mr.splice(B,1),mr.length===0&&Fa("removeEventListener"))}const gr=[];function Da(l){gr[gr.length-1](l)}function Pa(l){Et.is.desktop===!0&&(gr.push(l),gr.length===1&&document.body.addEventListener("focusin",Da))}function wi(l){const B=gr.indexOf(l);B!==-1&&(gr.splice(B,1),gr.length===0&&document.body.removeEventListener("focusin",Da))}const{notPassiveCapture:Mn}=_t,br=[];function Tn(l){const B=l.target;if(B===void 0||B.nodeType===8||B.classList.contains("no-pointer-events")===!0)return;let t=Tr.length-1;for(;t>=0;){const b=Tr[t].$;if(b.type.name==="QTooltip"){t--;continue}if(b.type.name!=="QDialog")break;if(b.props.seamless!==!0)return;t--}for(let b=br.length-1;b>=0;b--){const m=br[b];if((m.anchorEl.value===null||m.anchorEl.value.contains(B)===!1)&&(B===document.body||m.innerRef.value!==null&&m.innerRef.value.contains(B)===!1))l.qClickOutside=!0,m.onClickOutside(l);else return}}function Na(l){br.push(l),br.length===1&&(document.addEventListener("mousedown",Tn,Mn),document.addEventListener("touchstart",Tn,Mn))}function Rn(l){const B=br.findIndex(t=>t===l);B!==-1&&(br.splice(B,1),br.length===0&&(document.removeEventListener("mousedown",Tn,Mn),document.removeEventListener("touchstart",Tn,Mn)))}let Ro,Bo;function Bn(l){const B=l.split(" ");return B.length!==2?!1:["top","center","bottom"].includes(B[0])!==!0?(console.error("Anchor/Self position must start with one of top/center/bottom"),!1):["left","middle","right","start","end"].includes(B[1])!==!0?(console.error("Anchor/Self position must end with one of left/middle/right/start/end"),!1):!0}function La(l){return l?!(l.length!==2||typeof l[0]!="number"||typeof l[1]!="number"):!0}const xi={"start#ltr":"left","start#rtl":"right","end#ltr":"right","end#rtl":"left"};["left","middle","right"].forEach(l=>{xi[`${l}#ltr`]=l,xi[`${l}#rtl`]=l});function In(l,B){const t=l.split(" ");return{vertical:t[0],horizontal:xi[`${t[1]}#${B===!0?"rtl":"ltr"}`]}}function Nl(l,B){let{top:t,left:b,right:m,bottom:c,width:i,height:s}=l.getBoundingClientRect();return B!==void 0&&(t-=B[1],b-=B[0],c+=B[1],m+=B[0],i+=B[0],s+=B[1]),{top:t,bottom:c,height:s,left:b,right:m,width:i,middle:b+(m-b)/2,center:t+(c-t)/2}}function Ll(l,B,t){let{top:b,left:m}=l.getBoundingClientRect();return b+=B.top,m+=B.left,t!==void 0&&(b+=t[1],m+=t[0]),{top:b,bottom:b+1,height:1,left:m,right:m+1,width:1,middle:m,center:b}}function Vl(l,B){return{top:0,center:B/2,bottom:B,left:0,middle:l/2,right:l}}function Io(l,B,t,b){return{top:l[t.vertical]-B[b.vertical],left:l[t.horizontal]-B[b.horizontal]}}function Xi(l,B=0){if(l.targetEl===null||l.anchorEl===null||B>5)return;if(l.targetEl.offsetHeight===0||l.targetEl.offsetWidth===0){setTimeout(()=>{Xi(l,B+1)},10);return}const{targetEl:t,offset:b,anchorEl:m,anchorOrigin:c,selfOrigin:i,absoluteOffset:s,fit:n,cover:e,maxHeight:r,maxWidth:u}=l;if(Et.is.ios===!0&&window.visualViewport!==void 0){const D=document.body.style,{offsetLeft:V,offsetTop:P}=window.visualViewport;V!==Ro&&(D.setProperty("--q-pe-left",V+"px"),Ro=V),P!==Bo&&(D.setProperty("--q-pe-top",P+"px"),Bo=P)}const{scrollLeft:a,scrollTop:o}=t,f=s===void 0?Nl(m,e===!0?[0,0]:b):Ll(m,s,b);Object.assign(t.style,{top:0,left:0,minWidth:null,minHeight:null,maxWidth:u,maxHeight:r,visibility:"visible"});const{offsetWidth:h,offsetHeight:d}=t,{elWidth:g,elHeight:p}=n===!0||e===!0?{elWidth:Math.max(f.width,h),elHeight:e===!0?Math.max(f.height,d):d}:{elWidth:h,elHeight:d};let k={maxWidth:u,maxHeight:r};(n===!0||e===!0)&&(k.minWidth=f.width+"px",e===!0&&(k.minHeight=f.height+"px")),Object.assign(t.style,k);const C=Vl(g,p);let T=Io(f,C,c,i);if(s===void 0||b===void 0)ei(T,f,C,c,i);else{const{top:D,left:V}=T;ei(T,f,C,c,i);let P=!1;if(T.top!==D){P=!0;const N=2*b[1];f.center=f.top-=N,f.bottom-=N+2}if(T.left!==V){P=!0;const N=2*b[0];f.middle=f.left-=N,f.right-=N+2}P===!0&&(T=Io(f,C,c,i),ei(T,f,C,c,i))}k={top:T.top+"px",left:T.left+"px"},T.maxHeight!==void 0&&(k.maxHeight=T.maxHeight+"px",f.height>T.maxHeight&&(k.minHeight=k.maxHeight)),T.maxWidth!==void 0&&(k.maxWidth=T.maxWidth+"px",f.width>T.maxWidth&&(k.minWidth=k.maxWidth)),Object.assign(t.style,k),t.scrollTop!==o&&(t.scrollTop=o),t.scrollLeft!==a&&(t.scrollLeft=a)}function ei(l,B,t,b,m){const c=t.bottom,i=t.right,s=Sn(),n=window.innerHeight-s,e=document.body.clientWidth;if(l.top<0||l.top+c>n)if(m.vertical==="center")l.top=B[b.vertical]>n/2?Math.max(0,n-c):0,l.maxHeight=Math.min(c,n);else if(B[b.vertical]>n/2){const r=Math.min(n,b.vertical==="center"?B.center:b.vertical===m.vertical?B.bottom:B.top);l.maxHeight=Math.min(c,r),l.top=Math.max(0,r-c)}else l.top=Math.max(0,b.vertical==="center"?B.center:b.vertical===m.vertical?B.top:B.bottom),l.maxHeight=Math.min(c,n-l.top);if(l.left<0||l.left+i>e)if(l.maxWidth=Math.min(i,e),m.horizontal==="middle")l.left=B[b.horizontal]>e/2?Math.max(0,e-i):0;else if(B[b.horizontal]>e/2){const r=Math.min(e,b.horizontal==="middle"?B.middle:b.horizontal===m.horizontal?B.right:B.left);l.maxWidth=Math.min(i,r),l.left=Math.max(0,r-l.maxWidth)}else l.left=Math.max(0,b.horizontal==="middle"?B.middle:b.horizontal===m.horizontal?B.left:B.right),l.maxWidth=Math.min(i,e-l.left)}const Zr=$e({name:"QMenu",inheritAttrs:!1,props:{...Ra,...zi,...Ot,...Yr,persistent:Boolean,autoClose:Boolean,separateClosePopup:Boolean,noEscDismiss:Boolean,noRouteDismiss:Boolean,noRefocus:Boolean,noFocus:Boolean,fit:Boolean,cover:Boolean,square:Boolean,anchor:{type:String,validator:Bn},self:{type:String,validator:Bn},offset:{type:Array,validator:La},scrollTarget:qn,touchPosition:Boolean,maxHeight:{type:String,default:null},maxWidth:{type:String,default:null}},emits:[...Ui,"click","escapeKey"],setup(l,{slots:B,emit:t,attrs:b}){let m=null,c,i,s;const n=v.getCurrentInstance(),{proxy:e}=n,{$q:r}=e,u=v.ref(null),a=v.ref(!1),o=v.computed(()=>l.persistent!==!0&&l.noRouteDismiss!==!0),f=Ft(l,r),{registerTick:h,removeTick:d}=Qi(),{registerTimeout:g}=Ki(),{transitionProps:p,transitionStyle:k}=Yi(l),{localScrollTarget:C,changeScrollEvent:T,unconfigureScrollTarget:D}=Ba(l,z),{anchorEl:V,canShow:P}=qi({showing:a}),{hide:N}=Wi({showing:a,canShow:P,handleShow:E,handleHide:O,hideOnRouteChange:o,processOnMount:!0}),{showPortal:q,hidePortal:W,renderPortal:L}=Hi(n,u,F,"menu"),A={anchorEl:V,innerRef:u,onClickOutside(I){if(l.persistent!==!0&&a.value===!0)return N(I),(I.type==="touchstart"||I.target.classList.contains("q-dialog__backdrop"))&&St(I),!0}},M=v.computed(()=>In(l.anchor||(l.cover===!0?"center middle":"bottom start"),r.lang.rtl)),_=v.computed(()=>l.cover===!0?M.value:In(l.self||"top start",r.lang.rtl)),y=v.computed(()=>(l.square===!0?" q-menu--square":"")+(f.value===!0?" q-menu--dark q-dark":"")),x=v.computed(()=>l.autoClose===!0?{onClick:U}:{}),w=v.computed(()=>a.value===!0&&l.persistent!==!0);v.watch(w,I=>{I===!0?(ja(j),Na(A)):(En(j),Rn(A))});function S(){Jr(()=>{let I=u.value;I&&I.contains(document.activeElement)!==!0&&(I=I.querySelector("[autofocus][tabindex], [data-autofocus][tabindex]")||I.querySelector("[autofocus] [tabindex], [data-autofocus] [tabindex]")||I.querySelector("[autofocus], [data-autofocus]")||I,I.focus({preventScroll:!0}))})}function E(I){if(m=l.noRefocus===!1?document.activeElement:null,Pa(Q),q(),z(),c=void 0,I!==void 0&&(l.touchPosition||l.contextMenu)){const H=Qr(I);if(H.left!==void 0){const{top:K,left:ee}=V.value.getBoundingClientRect();c={left:H.left-ee,top:H.top-K}}}i===void 0&&(i=v.watch(()=>r.screen.width+"|"+r.screen.height+"|"+l.self+"|"+l.anchor+"|"+r.lang.rtl,Y)),l.noFocus!==!0&&document.activeElement.blur(),h(()=>{Y(),l.noFocus!==!0&&S()}),g(()=>{r.platform.is.ios===!0&&(s=l.autoClose,u.value.click()),Y(),q(!0),t("show",I)},l.transitionDuration)}function O(I){d(),W(),R(!0),m!==null&&(I===void 0||I.qClickOutside!==!0)&&(((I?.type.indexOf("key")===0?m.closest('[tabindex]:not([tabindex^="-"])'):void 0)||m).focus(),m=null),g(()=>{W(!0),t("hide",I)},l.transitionDuration)}function R(I){c=void 0,i!==void 0&&(i(),i=void 0),(I===!0||a.value===!0)&&(wi(Q),D(),Rn(A),En(j)),I!==!0&&(m=null)}function z(){(V.value!==null||l.scrollTarget!==void 0)&&(C.value=zn(V.value,l.scrollTarget),T(C.value,Y))}function U(I){s!==!0?(Oa(e,I),t("click",I)):s=!1}function Q(I){w.value===!0&&l.noFocus!==!0&&ba(u.value,I.target)!==!0&&S()}function j(I){l.noEscDismiss!==!0&&(t("escapeKey"),N(I))}function Y(){Xi({targetEl:u.value,offset:l.offset,anchorEl:V.value,anchorOrigin:M.value,selfOrigin:_.value,absoluteOffset:c,fit:l.fit,cover:l.cover,maxHeight:l.maxHeight,maxWidth:l.maxWidth})}function F(){return v.h(v.Transition,p.value,()=>a.value===!0?v.h("div",{role:"menu",...b,ref:u,tabindex:-1,class:["q-menu q-position-engine scroll"+y.value,b.class],style:[b.style,k.value],...x.value},bt(B.default)):null)}return v.onBeforeUnmount(R),Object.assign(e,{focus:S,updatePosition:Y}),L}});let ti,cn=0;const Mt=new Array(256);for(let l=0;l<256;l++)Mt[l]=(l+256).toString(16).substring(1);const ql=(()=>{const l=typeof crypto<"u"?crypto:typeof window<"u"?window.crypto||window.msCrypto:void 0;if(l!==void 0){if(l.randomBytes!==void 0)return l.randomBytes;if(l.getRandomValues!==void 0)return B=>{const t=new Uint8Array(B);return l.getRandomValues(t),t}}return B=>{const t=[];for(let b=B;b>0;b--)t.push(Math.floor(Math.random()*256));return t}})(),Oo=4096;function Si(){(ti===void 0||cn+16>Oo)&&(cn=0,ti=ql(Oo));const l=Array.prototype.slice.call(ti,cn,cn+=16);return l[6]=l[6]&15|64,l[8]=l[8]&63|128,Mt[l[0]]+Mt[l[1]]+Mt[l[2]]+Mt[l[3]]+"-"+Mt[l[4]]+Mt[l[5]]+"-"+Mt[l[6]]+Mt[l[7]]+"-"+Mt[l[8]]+Mt[l[9]]+"-"+Mt[l[10]]+Mt[l[11]]+Mt[l[12]]+Mt[l[13]]+Mt[l[14]]+Mt[l[15]]}function zl(l){return l??null}function Fo(l,B){return l??(B===!0?`f_${Si()}`:null)}function Ul({getValue:l,required:B=!0}={}){if(ar.value===!0){const t=l!==void 0?v.ref(zl(l())):v.ref(null);return B===!0&&t.value===null&&v.onMounted(()=>{t.value=`f_${Si()}`}),l!==void 0&&v.watch(l,b=>{t.value=Fo(b,B)}),t}return l!==void 0?v.computed(()=>Fo(l(),B)):v.ref(`f_${Si()}`)}const jo=/^on[A-Z]/;function Wl(){const{attrs:l,vnode:B}=v.getCurrentInstance(),t={listeners:v.ref({}),attributes:v.ref({})};function b(){const m={},c={};for(const i in l)i!=="class"&&i!=="style"&&jo.test(i)===!1&&(m[i]=l[i]);for(const i in B.props)jo.test(i)===!0&&(c[i]=B.props[i]);t.attributes.value=m,t.listeners.value=c}return v.onBeforeUpdate(b),b(),t}const Hl="_q_",$r="_q_l_",Va="_q_pc_",qa="_q_fo_";function Rt(){}function Yl({validate:l,resetValidation:B,requiresQForm:t}){const b=v.inject(qa,!1);if(b!==!1){const{props:m,proxy:c}=v.getCurrentInstance();Object.assign(c,{validate:l,resetValidation:B}),v.watch(()=>m.disable,i=>{i===!0?(typeof B=="function"&&B(),b.unbindComponent(c)):b.bindComponent(c)}),v.onMounted(()=>{m.disable!==!0&&b.bindComponent(c)}),v.onBeforeUnmount(()=>{m.disable!==!0&&b.unbindComponent(c)})}else t===!0&&console.error("Parent QForm not found on useFormChild()!")}const Do=/^#[0-9a-fA-F]{3}([0-9a-fA-F]{3})?$/,Po=/^#[0-9a-fA-F]{4}([0-9a-fA-F]{4})?$/,No=/^#([0-9a-fA-F]{3}|[0-9a-fA-F]{4}|[0-9a-fA-F]{6}|[0-9a-fA-F]{8})$/,dn=/^rgb\(((0|[1-9][\d]?|1[\d]{0,2}|2[\d]?|2[0-4][\d]|25[0-5]),){2}(0|[1-9][\d]?|1[\d]{0,2}|2[\d]?|2[0-4][\d]|25[0-5])\)$/,fn=/^rgba\(((0|[1-9][\d]?|1[\d]{0,2}|2[\d]?|2[0-4][\d]|25[0-5]),){2}(0|[1-9][\d]?|1[\d]{0,2}|2[\d]?|2[0-4][\d]|25[0-5]),(0|0\.[0-9]+[1-9]|0\.[1-9]+|1)\)$/,ri={date:l=>/^-?[\d]+\/[0-1]\d\/[0-3]\d$/.test(l),time:l=>/^([0-1]?\d|2[0-3]):[0-5]\d$/.test(l),fulltime:l=>/^([0-1]?\d|2[0-3]):[0-5]\d:[0-5]\d$/.test(l),timeOrFulltime:l=>/^([0-1]?\d|2[0-3]):[0-5]\d(:[0-5]\d)?$/.test(l),email:l=>/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(l),hexColor:l=>Do.test(l),hexaColor:l=>Po.test(l),hexOrHexaColor:l=>No.test(l),rgbColor:l=>dn.test(l),rgbaColor:l=>fn.test(l),rgbOrRgbaColor:l=>dn.test(l)||fn.test(l),hexOrRgbColor:l=>Do.test(l)||dn.test(l),hexaOrRgbaColor:l=>Po.test(l)||fn.test(l),anyColor:l=>No.test(l)||dn.test(l)||fn.test(l)},Ql=[!0,!1,"ondemand"],Kl={modelValue:{},error:{type:Boolean,default:null},errorMessage:String,noErrorIcon:Boolean,rules:Array,reactiveRules:Boolean,lazyRules:{type:[Boolean,String],default:!1,validator:l=>Ql.includes(l)}};function Xl(l,B){const{props:t,proxy:b}=v.getCurrentInstance(),m=v.ref(!1),c=v.ref(null),i=v.ref(!1);Yl({validate:h,resetValidation:f});let s=0,n;const e=v.computed(()=>t.rules!==void 0&&t.rules!==null&&t.rules.length!==0),r=v.computed(()=>t.disable!==!0&&e.value===!0&&B.value===!1),u=v.computed(()=>t.error===!0||m.value===!0),a=v.computed(()=>typeof t.errorMessage=="string"&&t.errorMessage.length!==0?t.errorMessage:c.value);v.watch(()=>t.modelValue,()=>{i.value=!0,r.value===!0&&t.lazyRules===!1&&d()});function o(){t.lazyRules!=="ondemand"&&r.value===!0&&i.value===!0&&d()}v.watch(()=>t.reactiveRules,g=>{g===!0?n===void 0&&(n=v.watch(()=>t.rules,o,{immediate:!0,deep:!0})):n!==void 0&&(n(),n=void 0)},{immediate:!0}),v.watch(()=>t.lazyRules,o),v.watch(l,g=>{g===!0?i.value=!0:r.value===!0&&t.lazyRules!=="ondemand"&&d()});function f(){s++,B.value=!1,i.value=!1,m.value=!1,c.value=null,d.cancel()}function h(g=t.modelValue){if(t.disable===!0||e.value===!1)return!0;const p=++s,k=B.value!==!0?()=>{i.value=!0}:()=>{},C=(D,V)=>{D===!0&&k(),m.value=D,c.value=V||null,B.value=!1},T=[];for(let D=0;D<t.rules.length;D++){const V=t.rules[D];let P;if(typeof V=="function"?P=V(g,ri):typeof V=="string"&&ri[V]!==void 0&&(P=ri[V](g)),P===!1||typeof P=="string")return C(!0,P),!1;P!==!0&&P!==void 0&&T.push(P)}return T.length===0?(C(!1),!0):(B.value=!0,Promise.all(T).then(D=>{if(D===void 0||Array.isArray(D)===!1||D.length===0)return p===s&&C(!1),!0;const V=D.find(P=>P===!1||typeof P=="string");return p===s&&C(V!==void 0,V),V===void 0},D=>(p===s&&(console.error(D),C(!0)),!1)))}const d=Vi(h,0);return v.onBeforeUnmount(()=>{n?.(),d.cancel()}),Object.assign(b,{resetValidation:f,validate:h}),Lt(b,"hasError",()=>u.value),{isDirtyModel:i,hasRules:e,hasError:u,errorMessage:a,validate:h,resetValidation:f}}function Xr(l){return l!=null&&(""+l).length!==0}const Gl={...Ot,...Kl,label:String,stackLabel:Boolean,hint:String,hideHint:Boolean,prefix:String,suffix:String,labelColor:String,color:String,bgColor:String,filled:Boolean,outlined:Boolean,borderless:Boolean,standout:[Boolean,String],square:Boolean,loading:Boolean,labelSlot:Boolean,bottomSlots:Boolean,hideBottomSpace:Boolean,rounded:Boolean,dense:Boolean,itemAligned:Boolean,counter:Boolean,clearable:Boolean,clearIcon:String,disable:Boolean,readonly:Boolean,autofocus:Boolean,for:String},Un={...Gl,maxlength:[Number,String]},Gi=["update:modelValue","clear","focus","blur"];function Ji({requiredForAttr:l=!0,tagProp:B,changeEvent:t=!1}={}){const{props:b,proxy:m}=v.getCurrentInstance(),c=Ft(b,m.$q),i=Ul({required:l,getValue:()=>b.for});return{requiredForAttr:l,changeEvent:t,tag:B===!0?v.computed(()=>b.tag):{value:"label"},isDark:c,editable:v.computed(()=>b.disable!==!0&&b.readonly!==!0),innerLoading:v.ref(!1),focused:v.ref(!1),hasPopupOpen:!1,splitAttrs:Wl(),targetUid:i,rootRef:v.ref(null),targetRef:v.ref(null),controlRef:v.ref(null)}}function Zi(l){const{props:B,emit:t,slots:b,attrs:m,proxy:c}=v.getCurrentInstance(),{$q:i}=c;let s=null;l.hasValue===void 0&&(l.hasValue=v.computed(()=>Xr(B.modelValue))),l.emitValue===void 0&&(l.emitValue=w=>{t("update:modelValue",w)}),l.controlEvents===void 0&&(l.controlEvents={onFocusin:N,onFocusout:q}),Object.assign(l,{clearValue:W,onControlFocusin:N,onControlFocusout:q,focus:V}),l.computedCounter===void 0&&(l.computedCounter=v.computed(()=>{if(B.counter!==!1){const w=typeof B.modelValue=="string"||typeof B.modelValue=="number"?(""+B.modelValue).length:Array.isArray(B.modelValue)===!0?B.modelValue.length:0,S=B.maxlength!==void 0?B.maxlength:B.maxValues;return w+(S!==void 0?" / "+S:"")}}));const{isDirtyModel:n,hasRules:e,hasError:r,errorMessage:u,resetValidation:a}=Xl(l.focused,l.innerLoading),o=l.floatingLabel!==void 0?v.computed(()=>B.stackLabel===!0||l.focused.value===!0||l.floatingLabel.value===!0):v.computed(()=>B.stackLabel===!0||l.focused.value===!0||l.hasValue.value===!0),f=v.computed(()=>B.bottomSlots===!0||B.hint!==void 0||e.value===!0||B.counter===!0||B.error!==null),h=v.computed(()=>B.filled===!0?"filled":B.outlined===!0?"outlined":B.borderless===!0?"borderless":B.standout?"standout":"standard"),d=v.computed(()=>`q-field row no-wrap items-start q-field--${h.value}`+(l.fieldClass!==void 0?` ${l.fieldClass.value}`:"")+(B.rounded===!0?" q-field--rounded":"")+(B.square===!0?" q-field--square":"")+(o.value===!0?" q-field--float":"")+(p.value===!0?" q-field--labeled":"")+(B.dense===!0?" q-field--dense":"")+(B.itemAligned===!0?" q-field--item-aligned q-item-type":"")+(l.isDark.value===!0?" q-field--dark":"")+(l.getControl===void 0?" q-field--auto-height":"")+(l.focused.value===!0?" q-field--focused":"")+(r.value===!0?" q-field--error":"")+(r.value===!0||l.focused.value===!0?" q-field--highlighted":"")+(B.hideBottomSpace!==!0&&f.value===!0?" q-field--with-bottom":"")+(B.disable===!0?" q-field--disabled":B.readonly===!0?" q-field--readonly":"")),g=v.computed(()=>"q-field__control relative-position row no-wrap"+(B.bgColor!==void 0?` bg-${B.bgColor}`:"")+(r.value===!0?" text-negative":typeof B.standout=="string"&&B.standout.length!==0&&l.focused.value===!0?` ${B.standout}`:B.color!==void 0?` text-${B.color}`:"")),p=v.computed(()=>B.labelSlot===!0||B.label!==void 0),k=v.computed(()=>"q-field__label no-pointer-events absolute ellipsis"+(B.labelColor!==void 0&&r.value!==!0?` text-${B.labelColor}`:"")),C=v.computed(()=>({id:l.targetUid.value,editable:l.editable.value,focused:l.focused.value,floatingLabel:o.value,modelValue:B.modelValue,emitValue:l.emitValue})),T=v.computed(()=>{const w={};return l.targetUid.value&&(w.for=l.targetUid.value),B.disable===!0&&(w["aria-disabled"]="true"),w});function D(){const w=document.activeElement;let S=l.targetRef?.value;S&&(w===null||w.id!==l.targetUid.value)&&(S.hasAttribute("tabindex")===!0||(S=S.querySelector("[tabindex]")),S!==w&&S?.focus({preventScroll:!0}))}function V(){Jr(D)}function P(){Al(D);const w=document.activeElement;w!==null&&l.rootRef.value.contains(w)&&w.blur()}function N(w){s!==null&&(clearTimeout(s),s=null),l.editable.value===!0&&l.focused.value===!1&&(l.focused.value=!0,t("focus",w))}function q(w,S){s!==null&&clearTimeout(s),s=setTimeout(()=>{s=null,!(document.hasFocus()===!0&&(l.hasPopupOpen===!0||l.controlRef===void 0||l.controlRef.value===null||l.controlRef.value.contains(document.activeElement)!==!1))&&(l.focused.value===!0&&(l.focused.value=!1,t("blur",w)),S?.())})}function W(w){St(w),i.platform.is.mobile!==!0?(l.targetRef?.value||l.rootRef.value).focus():l.rootRef.value.contains(document.activeElement)===!0&&document.activeElement.blur(),B.type==="file"&&(l.inputRef.value.value=null),t("update:modelValue",null),l.changeEvent===!0&&t("change",null),t("clear",B.modelValue),v.nextTick(()=>{const S=n.value;a(),n.value=S})}function L(w){[13,32].includes(w.keyCode)&&W(w)}function A(){const w=[];return b.prepend!==void 0&&w.push(v.h("div",{class:"q-field__prepend q-field__marginal row no-wrap items-center",key:"prepend",onClick:Bt},b.prepend())),w.push(v.h("div",{class:"q-field__control-container col relative-position row no-wrap q-anchor--skip"},M())),r.value===!0&&B.noErrorIcon===!1&&w.push(y("error",[v.h(dt,{name:i.iconSet.field.error,color:"negative"})])),B.loading===!0||l.innerLoading.value===!0?w.push(y("inner-loading-append",b.loading!==void 0?b.loading():[v.h(ga,{color:B.color})])):B.clearable===!0&&l.hasValue.value===!0&&l.editable.value===!0&&w.push(y("inner-clearable-append",[v.h(dt,{class:"q-field__focusable-action",name:B.clearIcon||i.iconSet.field.clear,tabindex:0,role:"button","aria-hidden":"false","aria-label":i.lang.label.clear,onKeyup:L,onClick:W})])),b.append!==void 0&&w.push(v.h("div",{class:"q-field__append q-field__marginal row no-wrap items-center",key:"append",onClick:Bt},b.append())),l.getInnerAppend!==void 0&&w.push(y("inner-append",l.getInnerAppend())),l.getControlChild!==void 0&&w.push(l.getControlChild()),w}function M(){const w=[];return B.prefix!==void 0&&B.prefix!==null&&w.push(v.h("div",{class:"q-field__prefix no-pointer-events row items-center"},B.prefix)),l.getShadowControl!==void 0&&l.hasShadow.value===!0&&w.push(l.getShadowControl()),l.getControl!==void 0?w.push(l.getControl()):b.rawControl!==void 0?w.push(b.rawControl()):b.control!==void 0&&w.push(v.h("div",{ref:l.targetRef,class:"q-field__native row",tabindex:-1,...l.splitAttrs.attributes.value,"data-autofocus":B.autofocus===!0||void 0},b.control(C.value))),p.value===!0&&w.push(v.h("div",{class:k.value},bt(b.label,B.label))),B.suffix!==void 0&&B.suffix!==null&&w.push(v.h("div",{class:"q-field__suffix no-pointer-events row items-center"},B.suffix)),w.concat(bt(b.default))}function _(){let w,S;r.value===!0?u.value!==null?(w=[v.h("div",{role:"alert"},u.value)],S=`q--slot-error-${u.value}`):(w=bt(b.error),S="q--slot-error"):(B.hideHint!==!0||l.focused.value===!0)&&(B.hint!==void 0?(w=[v.h("div",B.hint)],S=`q--slot-hint-${B.hint}`):(w=bt(b.hint),S="q--slot-hint"));const E=B.counter===!0||b.counter!==void 0;if(B.hideBottomSpace===!0&&E===!1&&w===void 0)return;const O=v.h("div",{key:S,class:"q-field__messages col"},w);return v.h("div",{class:"q-field__bottom row items-start q-field__bottom--"+(B.hideBottomSpace!==!0?"animated":"stale"),onClick:Bt},[B.hideBottomSpace===!0?O:v.h(v.Transition,{name:"q-transition--field-message"},()=>O),E===!0?v.h("div",{class:"q-field__counter"},b.counter!==void 0?b.counter():l.computedCounter.value):null])}function y(w,S){return S===null?null:v.h("div",{key:w,class:"q-field__append q-field__marginal row no-wrap items-center q-anchor--skip"},S)}let x=!1;return v.onDeactivated(()=>{x=!0}),v.onActivated(()=>{x===!0&&B.autofocus===!0&&c.focus()}),B.autofocus===!0&&v.onMounted(()=>{c.focus()}),v.onBeforeUnmount(()=>{s!==null&&clearTimeout(s)}),Object.assign(c,{focus:V,blur:P}),function(){const S=l.getControl===void 0&&b.control===void 0?{...l.splitAttrs.attributes.value,"data-autofocus":B.autofocus===!0||void 0,...T.value}:T.value;return v.h(l.tag.value,{ref:l.rootRef,class:[d.value,m.class],style:m.style,...S},[b.before!==void 0?v.h("div",{class:"q-field__before q-field__marginal row no-wrap items-center",onClick:Bt},b.before()):null,v.h("div",{class:"q-field__inner relative-position col self-stretch"},[v.h("div",{ref:l.controlRef,class:g.value,tabindex:-1,...l.controlEvents},A()),f.value===!0?_():null]),b.after!==void 0?v.h("div",{class:"q-field__after q-field__marginal row no-wrap items-center",onClick:Bt},b.after()):null])}}const Jl=$e({name:"QField",inheritAttrs:!1,props:{...Un,tag:{type:String,default:"label"}},emits:Gi,setup(){return Zi(Ji({tagProp:!0}))}}),Zl={xs:8,sm:10,md:14,lg:20,xl:24},za=$e({name:"QChip",props:{...Ot,...Fr,dense:Boolean,icon:String,iconRight:String,iconRemove:String,iconSelected:String,label:[String,Number],color:String,textColor:String,modelValue:{type:Boolean,default:!0},selected:{type:Boolean,default:null},square:Boolean,outline:Boolean,clickable:Boolean,removable:Boolean,removeAriaLabel:String,tabindex:[String,Number],disable:Boolean,ripple:{type:[Boolean,Object],default:!0}},emits:["update:modelValue","update:selected","remove","click"],setup(l,{slots:B,emit:t}){const{proxy:{$q:b}}=v.getCurrentInstance(),m=Ft(l,b),c=jr(l,Zl),i=v.computed(()=>l.selected===!0||l.icon!==void 0),s=v.computed(()=>l.selected===!0?l.iconSelected||b.iconSet.chip.selected:l.icon),n=v.computed(()=>l.iconRemove||b.iconSet.chip.remove),e=v.computed(()=>l.disable===!1&&(l.clickable===!0||l.selected!==null)),r=v.computed(()=>{const d=l.outline===!0&&l.color||l.textColor;return"q-chip row inline no-wrap items-center"+(l.outline===!1&&l.color!==void 0?` bg-${l.color}`:"")+(d?` text-${d} q-chip--colored`:"")+(l.disable===!0?" disabled":"")+(l.dense===!0?" q-chip--dense":"")+(l.outline===!0?" q-chip--outline":"")+(l.selected===!0?" q-chip--selected":"")+(e.value===!0?" q-chip--clickable cursor-pointer non-selectable q-hoverable":"")+(l.square===!0?" q-chip--square":"")+(m.value===!0?" q-chip--dark q-dark":"")}),u=v.computed(()=>{const d=l.disable===!0?{tabindex:-1,"aria-disabled":"true"}:{tabindex:l.tabindex||0},g={...d,role:"button","aria-hidden":"false","aria-label":l.removeAriaLabel||b.lang.label.remove};return{chip:d,remove:g}});function a(d){d.keyCode===13&&o(d)}function o(d){l.disable||(t("update:selected",!l.selected),t("click",d))}function f(d){(d.keyCode===void 0||d.keyCode===13)&&(St(d),l.disable===!1&&(t("update:modelValue",!1),t("remove")))}function h(){const d=[];e.value===!0&&d.push(v.h("div",{class:"q-focus-helper"})),i.value===!0&&d.push(v.h(dt,{class:"q-chip__icon q-chip__icon--left",name:s.value}));const g=l.label!==void 0?[v.h("div",{class:"ellipsis"},[l.label])]:void 0;return d.push(v.h("div",{class:"q-chip__content col row no-wrap items-center q-anchor--skip"},la(B.default,g))),l.iconRight&&d.push(v.h(dt,{class:"q-chip__icon q-chip__icon--right",name:l.iconRight})),l.removable===!0&&d.push(v.h(dt,{class:"q-chip__icon q-chip__icon--remove cursor-pointer",name:n.value,...u.value.remove,onClick:f,onKeyup:f})),d}return()=>{if(l.modelValue===!1)return;const d={class:r.value,style:c.value};return e.value===!0&&Object.assign(d,u.value.chip,{onClick:o,onKeyup:a}),Es("div",d,h(),"ripple",l.ripple!==!1&&l.disable!==!0,()=>[[va,l.ripple]])}}}),hr=$e({name:"QItem",props:{...Ot,...pa,tag:{type:String,default:"div"},active:{type:Boolean,default:null},clickable:Boolean,dense:Boolean,insetLevel:Number,tabindex:[String,Number],focused:Boolean,manualFocus:Boolean},emits:["click","keyup"],setup(l,{slots:B,emit:t}){const{proxy:{$q:b}}=v.getCurrentInstance(),m=Ft(l,b),{hasLink:c,linkAttrs:i,linkClass:s,linkTag:n,navigateOnClick:e}=Oi(),r=v.ref(null),u=v.ref(null),a=v.computed(()=>l.clickable===!0||c.value===!0||l.tag==="label"),o=v.computed(()=>l.disable!==!0&&a.value===!0),f=v.computed(()=>"q-item q-item-type row no-wrap"+(l.dense===!0?" q-item--dense":"")+(m.value===!0?" q-item--dark":"")+(c.value===!0&&l.active===null?s.value:l.active===!0?` q-item--active${l.activeClass!==void 0?` ${l.activeClass}`:""}`:"")+(l.disable===!0?" disabled":"")+(o.value===!0?" q-item--clickable q-link cursor-pointer "+(l.manualFocus===!0?"q-manual-focusable":"q-focusable q-hoverable")+(l.focused===!0?" q-manual-focusable--focused":""):"")),h=v.computed(()=>l.insetLevel===void 0?null:{["padding"+(b.lang.rtl===!0?"Right":"Left")]:16+l.insetLevel*56+"px"});function d(k){o.value===!0&&(u.value!==null&&k.qAvoidFocus!==!0&&(k.qKeyEvent!==!0&&document.activeElement===r.value?u.value.focus():document.activeElement===u.value&&r.value.focus()),e(k))}function g(k){if(o.value===!0&&or(k,[13,32])===!0){St(k),k.qKeyEvent=!0;const C=new MouseEvent("click",k);C.qKeyEvent=!0,r.value.dispatchEvent(C)}t("keyup",k)}function p(){const k=Ri(B.default,[]);return o.value===!0&&k.unshift(v.h("div",{class:"q-focus-helper",tabindex:-1,ref:u})),k}return()=>{const k={ref:r,class:f.value,style:h.value,role:"listitem",onClick:d,onKeyup:g};return o.value===!0?(k.tabindex=l.tabindex||"0",Object.assign(k,i.value)):a.value===!0&&(k["aria-disabled"]="true"),v.h(n.value,k,p())}}}),nr=$e({name:"QItemSection",props:{avatar:Boolean,thumbnail:Boolean,side:Boolean,top:Boolean,noWrap:Boolean},setup(l,{slots:B}){const t=v.computed(()=>`q-item__section column q-item__section--${l.avatar===!0||l.side===!0||l.thumbnail===!0?"side":"main"}`+(l.top===!0?" q-item__section--top justify-start":" justify-center")+(l.avatar===!0?" q-item__section--avatar":"")+(l.thumbnail===!0?" q-item__section--thumbnail":"")+(l.noWrap===!0?" q-item__section--nowrap":""));return()=>v.h("div",{class:t.value},bt(B.default))}}),ki=$e({name:"QItemLabel",props:{overline:Boolean,caption:Boolean,header:Boolean,lines:[Number,String]},setup(l,{slots:B}){const t=v.computed(()=>parseInt(l.lines,10)),b=v.computed(()=>"q-item__label"+(l.overline===!0?" q-item__label--overline text-overline":"")+(l.caption===!0?" q-item__label--caption text-caption":"")+(l.header===!0?" q-item__label--header":"")+(t.value===1?" ellipsis":"")),m=v.computed(()=>l.lines!==void 0&&t.value>1?{overflow:"hidden",display:"-webkit-box","-webkit-box-orient":"vertical","-webkit-line-clamp":t.value}:null);return()=>v.h("div",{style:m.value,class:b.value},bt(B.default))}});function $l(l,B,t){function b(){}return v.onBeforeUnmount(()=>{l.value===!0&&void 0}),{removeFromHistory:b,addToHistory(){}}}let Lr=0,ni,ii,zr,oi=!1,Lo,Vo,qo,cr=null;function eu(l){tu(l)&&St(l)}function tu(l){if(l.target===document.body||l.target.classList.contains("q-layout__backdrop"))return!0;const B=Ks(l),t=l.shiftKey&&!l.deltaX,b=!t&&Math.abs(l.deltaX)<=Math.abs(l.deltaY),m=t||b?l.deltaY:l.deltaX;for(let c=0;c<B.length;c++){const i=B[c];if(vl(i,b))return b?m<0&&i.scrollTop===0?!0:m>0&&i.scrollTop+i.clientHeight===i.scrollHeight:m<0&&i.scrollLeft===0?!0:m>0&&i.scrollLeft+i.clientWidth===i.scrollWidth}return!0}function zo(l){l.target===document&&(document.scrollingElement.scrollTop=document.scrollingElement.scrollTop)}function hn(l){oi!==!0&&(oi=!0,requestAnimationFrame(()=>{oi=!1;const{height:B}=l.target,{clientHeight:t,scrollTop:b}=document.scrollingElement;(zr===void 0||B!==window.innerHeight)&&(zr=t-B,document.scrollingElement.scrollTop=b),b>zr&&(document.scrollingElement.scrollTop-=Math.ceil((b-zr)/8))}))}function Uo(l){const B=document.body,t=window.visualViewport!==void 0;if(l==="add"){const{overflowY:b,overflowX:m}=window.getComputedStyle(B);ni=Ni(window),ii=Pi(window),Lo=B.style.left,Vo=B.style.top,qo=window.location.href,B.style.left=`-${ni}px`,B.style.top=`-${ii}px`,m!=="hidden"&&(m==="scroll"||B.scrollWidth>window.innerWidth)&&B.classList.add("q-body--force-scrollbar-x"),b!=="hidden"&&(b==="scroll"||B.scrollHeight>window.innerHeight)&&B.classList.add("q-body--force-scrollbar-y"),B.classList.add("q-body--prevent-scroll"),document.qScrollPrevented=!0,Et.is.ios===!0&&(t===!0?(window.scrollTo(0,0),window.visualViewport.addEventListener("resize",hn,_t.passiveCapture),window.visualViewport.addEventListener("scroll",hn,_t.passiveCapture),window.scrollTo(0,0)):window.addEventListener("scroll",zo,_t.passiveCapture))}Et.is.desktop===!0&&Et.is.mac===!0&&window[`${l}EventListener`]("wheel",eu,_t.notPassive),l==="remove"&&(Et.is.ios===!0&&(t===!0?(window.visualViewport.removeEventListener("resize",hn,_t.passiveCapture),window.visualViewport.removeEventListener("scroll",hn,_t.passiveCapture)):window.removeEventListener("scroll",zo,_t.passiveCapture)),B.classList.remove("q-body--prevent-scroll"),B.classList.remove("q-body--force-scrollbar-x"),B.classList.remove("q-body--force-scrollbar-y"),document.qScrollPrevented=!1,B.style.left=Lo,B.style.top=Vo,window.location.href===qo&&window.scrollTo(ni,ii),zr=void 0)}function ru(l){let B="add";if(l===!0){if(Lr++,cr!==null){clearTimeout(cr),cr=null;return}if(Lr>1)return}else{if(Lr===0||(Lr--,Lr>0))return;if(B="remove",Et.is.ios===!0&&Et.is.nativeMobile===!0){cr!==null&&clearTimeout(cr),cr=setTimeout(()=>{Uo(B),cr=null},100);return}}Uo(B)}function nu(){let l;return{preventBodyScroll(B){B!==l&&(l!==void 0||B===!0)&&(l=B,ru(B))}}}let pn=0;const iu={standard:"fixed-full flex-center",top:"fixed-top justify-center",bottom:"fixed-bottom justify-center",right:"fixed-right items-center",left:"fixed-left items-center"},Wo={standard:["scale","scale"],top:["slide-down","slide-up"],bottom:["slide-up","slide-down"],right:["slide-left","slide-right"],left:["slide-right","slide-left"]},en=$e({name:"QDialog",inheritAttrs:!1,props:{...zi,...Yr,transitionShow:String,transitionHide:String,persistent:Boolean,autoClose:Boolean,allowFocusOutside:Boolean,noEscDismiss:Boolean,noBackdropDismiss:Boolean,noRouteDismiss:Boolean,noRefocus:Boolean,noFocus:Boolean,noShake:Boolean,seamless:Boolean,maximized:Boolean,fullWidth:Boolean,fullHeight:Boolean,square:Boolean,backdropFilter:String,position:{type:String,default:"standard",validator:l=>["standard","top","bottom","left","right"].includes(l)}},emits:[...Ui,"shake","click","escapeKey"],setup(l,{slots:B,emit:t,attrs:b}){const m=v.getCurrentInstance(),c=v.ref(null),i=v.ref(!1),s=v.ref(!1);let n=null,e=null,r,u;const a=v.computed(()=>l.persistent!==!0&&l.noRouteDismiss!==!0&&l.seamless!==!0),{preventBodyScroll:o}=nu(),{registerTimeout:f}=Ki(),{registerTick:h,removeTick:d}=Qi(),{transitionProps:g,transitionStyle:p}=Yi(l,()=>Wo[l.position][0],()=>Wo[l.position][1]),k=v.computed(()=>p.value+(l.backdropFilter!==void 0?`;backdrop-filter:${l.backdropFilter};-webkit-backdrop-filter:${l.backdropFilter}`:"")),{showPortal:C,hidePortal:T,portalIsAccessible:D,renderPortal:V}=Hi(m,c,z,"dialog"),{hide:P}=Wi({showing:i,hideOnRouteChange:a,handleShow:A,handleHide:M,processOnMount:!0});$l(i);const N=v.computed(()=>`q-dialog__inner flex no-pointer-events q-dialog__inner--${l.maximized===!0?"maximized":"minimized"} q-dialog__inner--${l.position} ${iu[l.position]}`+(s.value===!0?" q-dialog__inner--animating":"")+(l.fullWidth===!0?" q-dialog__inner--fullwidth":"")+(l.fullHeight===!0?" q-dialog__inner--fullheight":"")+(l.square===!0?" q-dialog__inner--square":"")),q=v.computed(()=>i.value===!0&&l.seamless!==!0),W=v.computed(()=>l.autoClose===!0?{onClick:E}:{}),L=v.computed(()=>[`q-dialog fullscreen no-pointer-events q-dialog--${q.value===!0?"modal":"seamless"}`,b.class]);v.watch(()=>l.maximized,U=>{i.value===!0&&S(U)}),v.watch(q,U=>{o(U),U===!0?(Pa(R),ja(x)):(wi(R),En(x))});function A(U){e=l.noRefocus===!1&&document.activeElement!==null?document.activeElement:null,S(l.maximized),C(),s.value=!0,l.noFocus!==!0?(document.activeElement?.blur(),h(_)):d(),f(()=>{if(m.proxy.$q.platform.is.ios===!0){if(l.seamless!==!0&&document.activeElement){const{top:Q,bottom:j}=document.activeElement.getBoundingClientRect(),{innerHeight:Y}=window,F=window.visualViewport!==void 0?window.visualViewport.height:Y;Q>0&&j>F/2&&(document.scrollingElement.scrollTop=Math.min(document.scrollingElement.scrollHeight-F,j>=Y?1/0:Math.ceil(document.scrollingElement.scrollTop+j-F/2))),document.activeElement.scrollIntoView()}u=!0,c.value.click(),u=!1}C(!0),s.value=!1,t("show",U)},l.transitionDuration)}function M(U){d(),w(!0),s.value=!0,T(),e!==null&&(((U?.type.indexOf("key")===0?e.closest('[tabindex]:not([tabindex^="-"])'):void 0)||e).focus(),e=null),f(()=>{T(!0),s.value=!1,t("hide",U)},l.transitionDuration)}function _(U){Jr(()=>{let Q=c.value;if(Q!==null){if(U!==void 0){const j=Q.querySelector(U);if(j!==null){j.focus({preventScroll:!0});return}}Q.contains(document.activeElement)!==!0&&(Q=Q.querySelector("[autofocus][tabindex], [data-autofocus][tabindex]")||Q.querySelector("[autofocus] [tabindex], [data-autofocus] [tabindex]")||Q.querySelector("[autofocus], [data-autofocus]")||Q,Q.focus({preventScroll:!0}))}})}function y(U){U&&typeof U.focus=="function"?U.focus({preventScroll:!0}):_(),t("shake");const Q=c.value;Q!==null&&(Q.classList.remove("q-animate--scale"),Q.classList.add("q-animate--scale"),n!==null&&clearTimeout(n),n=setTimeout(()=>{n=null,c.value!==null&&(Q.classList.remove("q-animate--scale"),_())},170))}function x(){l.seamless!==!0&&(l.persistent===!0||l.noEscDismiss===!0?l.maximized!==!0&&l.noShake!==!0&&y():(t("escapeKey"),P()))}function w(U){n!==null&&(clearTimeout(n),n=null),(U===!0||i.value===!0)&&(S(!1),l.seamless!==!0&&(o(!1),wi(R),En(x))),U!==!0&&(e=null)}function S(U){U===!0?r!==!0&&(pn<1&&document.body.classList.add("q-body--dialog"),pn++,r=!0):r===!0&&(pn<2&&document.body.classList.remove("q-body--dialog"),pn--,r=!1)}function E(U){u!==!0&&(P(U),t("click",U))}function O(U){l.persistent!==!0&&l.noBackdropDismiss!==!0?P(U):l.noShake!==!0&&y()}function R(U){l.allowFocusOutside!==!0&&D.value===!0&&ba(c.value,U.target)!==!0&&_('[tabindex]:not([tabindex="-1"])')}Object.assign(m.proxy,{focus:_,shake:y,__updateRefocusTarget(U){e=U||null}}),v.onBeforeUnmount(w);function z(){return v.h("div",{role:"dialog","aria-modal":q.value===!0?"true":"false",...b,class:L.value},[v.h(v.Transition,{name:"q-transition--fade",appear:!0},()=>q.value===!0?v.h("div",{class:"q-dialog__backdrop fixed-full",style:k.value,"aria-hidden":"true",tabindex:-1,onClick:O}):null),v.h(v.Transition,g.value,()=>i.value===!0?v.h("div",{ref:c,class:N.value,style:p.value,tabindex:-1,...W.value},bt(B.default)):null)])}return V}});let On=!1;{const l=document.createElement("div");l.setAttribute("dir","rtl"),Object.assign(l.style,{width:"1px",height:"1px",overflow:"auto"});const B=document.createElement("div");Object.assign(B.style,{width:"1000px",height:"1px"}),document.body.appendChild(l),l.appendChild(B),l.scrollLeft=-1e3,On=l.scrollLeft>=0,l.remove()}const Wt=1e3,ou=["start","center","end","start-force","center-force","end-force"],Ua=Array.prototype.filter,au=window.getComputedStyle(document.body).overflowAnchor===void 0?Ln:function(l,B){l!==null&&(l._qOverflowAnimationFrame!==void 0&&cancelAnimationFrame(l._qOverflowAnimationFrame),l._qOverflowAnimationFrame=requestAnimationFrame(()=>{if(l===null)return;l._qOverflowAnimationFrame=void 0;const t=l.children||[];Ua.call(t,m=>m.dataset&&m.dataset.qVsAnchor!==void 0).forEach(m=>{delete m.dataset.qVsAnchor});const b=t[B];b?.dataset&&(b.dataset.qVsAnchor="")}))};function Rr(l,B){return l+B}function ai(l,B,t,b,m,c,i,s){const n=l===window?document.scrollingElement||document.documentElement:l,e=m===!0?"offsetWidth":"offsetHeight",r={scrollStart:0,scrollViewSize:-i-s,scrollMaxSize:0,offsetStart:-i,offsetEnd:-s};if(m===!0?(l===window?(r.scrollStart=window.pageXOffset||window.scrollX||document.body.scrollLeft||0,r.scrollViewSize+=document.documentElement.clientWidth):(r.scrollStart=n.scrollLeft,r.scrollViewSize+=n.clientWidth),r.scrollMaxSize=n.scrollWidth,c===!0&&(r.scrollStart=(On===!0?r.scrollMaxSize-r.scrollViewSize:0)-r.scrollStart)):(l===window?(r.scrollStart=window.pageYOffset||window.scrollY||document.body.scrollTop||0,r.scrollViewSize+=document.documentElement.clientHeight):(r.scrollStart=n.scrollTop,r.scrollViewSize+=n.clientHeight),r.scrollMaxSize=n.scrollHeight),t!==null)for(let u=t.previousElementSibling;u!==null;u=u.previousElementSibling)u.classList.contains("q-virtual-scroll--skip")===!1&&(r.offsetStart+=u[e]);if(b!==null)for(let u=b.nextElementSibling;u!==null;u=u.nextElementSibling)u.classList.contains("q-virtual-scroll--skip")===!1&&(r.offsetEnd+=u[e]);if(B!==l){const u=n.getBoundingClientRect(),a=B.getBoundingClientRect();m===!0?(r.offsetStart+=a.left-u.left,r.offsetEnd-=a.width):(r.offsetStart+=a.top-u.top,r.offsetEnd-=a.height),l!==window&&(r.offsetStart+=r.scrollStart),r.offsetEnd+=r.scrollMaxSize-r.offsetStart}return r}function Ho(l,B,t,b){B==="end"&&(B=(l===window?document.body:l)[t===!0?"scrollWidth":"scrollHeight"]),l===window?t===!0?(b===!0&&(B=(On===!0?document.body.scrollWidth-document.documentElement.clientWidth:0)-B),window.scrollTo(B,window.pageYOffset||window.scrollY||document.body.scrollTop||0)):window.scrollTo(window.pageXOffset||window.scrollX||document.body.scrollLeft||0,B):t===!0?(b===!0&&(B=(On===!0?l.scrollWidth-l.offsetWidth:0)-B),l.scrollLeft=B):l.scrollTop=B}function Vr(l,B,t,b){if(t>=b)return 0;const m=B.length,c=Math.floor(t/Wt),i=Math.floor((b-1)/Wt)+1;let s=l.slice(c,i).reduce(Rr,0);return t%Wt!==0&&(s-=B.slice(c*Wt,t).reduce(Rr,0)),b%Wt!==0&&b!==m&&(s-=B.slice(b,i*Wt).reduce(Rr,0)),s}const Wa={virtualScrollSliceSize:{type:[Number,String],default:10},virtualScrollSliceRatioBefore:{type:[Number,String],default:1},virtualScrollSliceRatioAfter:{type:[Number,String],default:1},virtualScrollItemSize:{type:[Number,String],default:24},virtualScrollStickySizeStart:{type:[Number,String],default:0},virtualScrollStickySizeEnd:{type:[Number,String],default:0},tableColspan:[Number,String]},Ha=Object.keys(Wa),_i={virtualScrollHorizontal:Boolean,onVirtualScroll:Function,...Wa};function Ya({virtualScrollLength:l,getVirtualScrollTarget:B,getVirtualScrollEl:t,virtualScrollItemSizeComputed:b}){const m=v.getCurrentInstance(),{props:c,emit:i,proxy:s}=m,{$q:n}=s;let e,r,u,a=[],o;const f=v.ref(0),h=v.ref(0),d=v.ref({}),g=v.ref(null),p=v.ref(null),k=v.ref(null),C=v.ref({from:0,to:0}),T=v.computed(()=>c.tableColspan!==void 0?c.tableColspan:100);b===void 0&&(b=v.computed(()=>c.virtualScrollItemSize));const D=v.computed(()=>b.value+";"+c.virtualScrollHorizontal),V=v.computed(()=>D.value+";"+c.virtualScrollSliceRatioBefore+";"+c.virtualScrollSliceRatioAfter);v.watch(V,()=>{y()}),v.watch(D,P);function P(){_(r,!0)}function N(O){_(O===void 0?r:O)}function q(O,R){const z=B();if(z==null||z.nodeType===8)return;const U=ai(z,t(),g.value,p.value,c.virtualScrollHorizontal,n.lang.rtl,c.virtualScrollStickySizeStart,c.virtualScrollStickySizeEnd);u!==U.scrollViewSize&&y(U.scrollViewSize),L(z,U,Math.min(l.value-1,Math.max(0,parseInt(O,10)||0)),0,ou.indexOf(R)!==-1?R:r!==-1&&O>r?"end":"start")}function W(){const O=B();if(O==null||O.nodeType===8)return;const R=ai(O,t(),g.value,p.value,c.virtualScrollHorizontal,n.lang.rtl,c.virtualScrollStickySizeStart,c.virtualScrollStickySizeEnd),z=l.value-1,U=R.scrollMaxSize-R.offsetStart-R.offsetEnd-h.value;if(e===R.scrollStart)return;if(R.scrollMaxSize<=0){L(O,R,0,0);return}u!==R.scrollViewSize&&y(R.scrollViewSize),A(C.value.from);const Q=Math.floor(R.scrollMaxSize-Math.max(R.scrollViewSize,R.offsetEnd)-Math.min(o[z],R.scrollViewSize/2));if(Q>0&&Math.ceil(R.scrollStart)>=Q){L(O,R,z,R.scrollMaxSize-R.offsetEnd-a.reduce(Rr,0));return}let j=0,Y=R.scrollStart-R.offsetStart,F=Y;if(Y<=U&&Y+R.scrollViewSize>=f.value)Y-=f.value,j=C.value.from,F=Y;else for(let I=0;Y>=a[I]&&j<z;I++)Y-=a[I],j+=Wt;for(;Y>0&&j<z;)Y-=o[j],Y>-R.scrollViewSize?(j++,F=Y):F=o[j]+Y;L(O,R,j,F)}function L(O,R,z,U,Q){const j=typeof Q=="string"&&Q.indexOf("-force")!==-1,Y=j===!0?Q.replace("-force",""):Q,F=Y!==void 0?Y:"start";let I=Math.max(0,z-d.value[F]),H=I+d.value.total;H>l.value&&(H=l.value,I=Math.max(0,H-d.value.total)),e=R.scrollStart;const K=I!==C.value.from||H!==C.value.to;if(K===!1&&Y===void 0){w(z);return}const{activeElement:ee}=document,G=k.value;K===!0&&G!==null&&G!==ee&&G.contains(ee)===!0&&(G.addEventListener("focusout",M),setTimeout(()=>{G?.removeEventListener("focusout",M)})),au(G,z-I);const te=Y!==void 0?o.slice(I,z).reduce(Rr,0):0;if(K===!0){const ce=H>=C.value.from&&I<=C.value.to?C.value.to:H;C.value={from:I,to:ce},f.value=Vr(a,o,0,I),h.value=Vr(a,o,H,l.value),requestAnimationFrame(()=>{C.value.to!==H&&e===R.scrollStart&&(C.value={from:C.value.from,to:H},h.value=Vr(a,o,H,l.value))})}requestAnimationFrame(()=>{if(e!==R.scrollStart)return;K===!0&&A(I);const ce=o.slice(I,z).reduce(Rr,0),ue=ce+R.offsetStart+f.value,J=ue+o[z];let ae=ue+U;if(Y!==void 0){const se=ce-te,pe=R.scrollStart+se;ae=j!==!0&&pe<ue&&J<pe+R.scrollViewSize?pe:Y==="end"?J-R.scrollViewSize:ue-(Y==="start"?0:Math.round((R.scrollViewSize-o[z])/2))}e=ae,Ho(O,ae,c.virtualScrollHorizontal,n.lang.rtl),w(z)})}function A(O){const R=k.value;if(R){const z=Ua.call(R.children,I=>I.classList&&I.classList.contains("q-virtual-scroll--skip")===!1),U=z.length,Q=c.virtualScrollHorizontal===!0?I=>I.getBoundingClientRect().width:I=>I.offsetHeight;let j=O,Y,F;for(let I=0;I<U;){for(Y=Q(z[I]),I++;I<U&&z[I].classList.contains("q-virtual-scroll--with-prev")===!0;)Y+=Q(z[I]),I++;F=Y-o[j],F!==0&&(o[j]+=F,a[Math.floor(j/Wt)]+=F),j++}}}function M(){k.value?.focus()}function _(O,R){const z=1*b.value;(R===!0||Array.isArray(o)===!1)&&(o=[]);const U=o.length;o.length=l.value;for(let j=l.value-1;j>=U;j--)o[j]=z;const Q=Math.floor((l.value-1)/Wt);a=[];for(let j=0;j<=Q;j++){let Y=0;const F=Math.min((j+1)*Wt,l.value);for(let I=j*Wt;I<F;I++)Y+=o[I];a.push(Y)}r=-1,e=void 0,f.value=Vr(a,o,0,C.value.from),h.value=Vr(a,o,C.value.to,l.value),O>=0?(A(C.value.from),v.nextTick(()=>{q(O)})):S()}function y(O){if(O===void 0&&typeof window<"u"){const Y=B();Y!=null&&Y.nodeType!==8&&(O=ai(Y,t(),g.value,p.value,c.virtualScrollHorizontal,n.lang.rtl,c.virtualScrollStickySizeStart,c.virtualScrollStickySizeEnd).scrollViewSize)}u=O;const R=parseFloat(c.virtualScrollSliceRatioBefore)||0,z=parseFloat(c.virtualScrollSliceRatioAfter)||0,U=1+R+z,Q=O===void 0||O<=0?1:Math.ceil(O/b.value),j=Math.max(1,Q,Math.ceil((c.virtualScrollSliceSize>0?c.virtualScrollSliceSize:10)/U));d.value={total:Math.ceil(j*U),start:Math.ceil(j*R),center:Math.ceil(j*(.5+R)),end:Math.ceil(j*(1+R)),view:Q}}function x(O,R){const z=c.virtualScrollHorizontal===!0?"width":"height",U={["--q-virtual-scroll-item-"+z]:b.value+"px"};return[O==="tbody"?v.h(O,{class:"q-virtual-scroll__padding",key:"before",ref:g},[v.h("tr",[v.h("td",{style:{[z]:`${f.value}px`,...U},colspan:T.value})])]):v.h(O,{class:"q-virtual-scroll__padding",key:"before",ref:g,style:{[z]:`${f.value}px`,...U}}),v.h(O,{class:"q-virtual-scroll__content",key:"content",ref:k,tabindex:-1},R.flat()),O==="tbody"?v.h(O,{class:"q-virtual-scroll__padding",key:"after",ref:p},[v.h("tr",[v.h("td",{style:{[z]:`${h.value}px`,...U},colspan:T.value})])]):v.h(O,{class:"q-virtual-scroll__padding",key:"after",ref:p,style:{[z]:`${h.value}px`,...U}})]}function w(O){r!==O&&(c.onVirtualScroll!==void 0&&i("virtualScroll",{index:O,from:C.value.from,to:C.value.to-1,direction:O<r?"decrease":"increase",ref:s}),r=O)}y();const S=Vi(W,n.platform.is.ios===!0?120:35);v.onBeforeMount(()=>{y()});let E=!1;return v.onDeactivated(()=>{E=!0}),v.onActivated(()=>{if(E!==!0)return;const O=B();e!==void 0&&O!==void 0&&O!==null&&O.nodeType!==8?Ho(O,e,c.virtualScrollHorizontal,n.lang.rtl):q(r)}),v.onBeforeUnmount(()=>{S.cancel()}),Object.assign(s,{scrollTo:q,reset:P,refresh:N}),{virtualScrollSliceRange:C,virtualScrollSliceSizeComputed:d,setVirtualScrollSize:y,onVirtualScrollEvt:S,localResetVirtualScroll:_,padVirtualScroll:x,scrollTo:q,reset:P,refresh:N}}const su=/[\u3000-\u303f\u3040-\u309f\u30a0-\u30ff\uff00-\uff9f\u4e00-\u9faf\u3400-\u4dbf]/,lu=/[\u4e00-\u9fff\u3400-\u4dbf\u{20000}-\u{2a6df}\u{2a700}-\u{2b73f}\u{2b740}-\u{2b81f}\u{2b820}-\u{2ceaf}\uf900-\ufaff\u3300-\u33ff\ufe30-\ufe4f\uf900-\ufaff\u{2f800}-\u{2fa1f}]/u,uu=/[\u3131-\u314e\u314f-\u3163\uac00-\ud7a3]/,cu=/[a-z0-9_ -]$/i;function Qa(l){return function(t){if(t.type==="compositionend"||t.type==="change"){if(t.target.qComposing!==!0)return;t.target.qComposing=!1,l(t)}else t.type==="compositionupdate"&&t.target.qComposing!==!0&&typeof t.data=="string"&&(Et.is.firefox===!0?cu.test(t.data)===!1:su.test(t.data)===!0||lu.test(t.data)===!0||uu.test(t.data)===!0)===!0&&(t.target.qComposing=!0)}}function rr(l,B){if(l===B)return!0;if(l!==null&&B!==null&&typeof l=="object"&&typeof B=="object"){if(l.constructor!==B.constructor)return!1;let t,b;if(l.constructor===Array){if(t=l.length,t!==B.length)return!1;for(b=t;b--!==0;)if(rr(l[b],B[b])!==!0)return!1;return!0}if(l.constructor===Map){if(l.size!==B.size)return!1;let c=l.entries();for(b=c.next();b.done!==!0;){if(B.has(b.value[0])!==!0)return!1;b=c.next()}for(c=l.entries(),b=c.next();b.done!==!0;){if(rr(b.value[1],B.get(b.value[0]))!==!0)return!1;b=c.next()}return!0}if(l.constructor===Set){if(l.size!==B.size)return!1;const c=l.entries();for(b=c.next();b.done!==!0;){if(B.has(b.value[0])!==!0)return!1;b=c.next()}return!0}if(l.buffer!=null&&l.buffer.constructor===ArrayBuffer){if(t=l.length,t!==B.length)return!1;for(b=t;b--!==0;)if(l[b]!==B[b])return!1;return!0}if(l.constructor===RegExp)return l.source===B.source&&l.flags===B.flags;if(l.valueOf!==Object.prototype.valueOf)return l.valueOf()===B.valueOf();if(l.toString!==Object.prototype.toString)return l.toString()===B.toString();const m=Object.keys(l).filter(c=>l[c]!==void 0);if(t=m.length,t!==Object.keys(B).filter(c=>B[c]!==void 0).length)return!1;for(b=t;b--!==0;){const c=m[b];if(rr(l[c],B[c])!==!0)return!1}return!0}return l!==l&&B!==B}function Ka(l){return l!==null&&typeof l=="object"&&Array.isArray(l)!==!0}function Fn(l){return Object.prototype.toString.call(l)==="[object Date]"}function Ci(l){return typeof l=="number"&&isFinite(l)}const Yo=l=>["add","add-unique","toggle"].includes(l),du=".*+?^${}()|[]\\",fu=Object.keys(Un);function si(l,B){if(typeof l=="function")return l;const t=l!==void 0?l:B;return b=>b!==null&&typeof b=="object"&&t in b?b[t]:b}const Wn=$e({name:"QSelect",inheritAttrs:!1,props:{..._i,...Vn,...Un,modelValue:{required:!0},multiple:Boolean,displayValue:[String,Number],displayValueHtml:Boolean,dropdownIcon:String,options:{type:Array,default:()=>[]},optionValue:[Function,String],optionLabel:[Function,String],optionDisable:[Function,String],hideSelected:Boolean,hideDropdownIcon:Boolean,fillInput:Boolean,maxValues:[Number,String],optionsDense:Boolean,optionsDark:{type:Boolean,default:null},optionsSelectedClass:String,optionsHtml:Boolean,optionsCover:Boolean,menuShrink:Boolean,menuAnchor:String,menuSelf:String,menuOffset:Array,popupContentClass:String,popupContentStyle:[String,Array,Object],popupNoRouteDismiss:Boolean,useInput:Boolean,useChips:Boolean,newValueMode:{type:String,validator:Yo},mapOptions:Boolean,emitValue:Boolean,disableTabSelection:Boolean,inputDebounce:{type:[Number,String],default:500},inputClass:[Array,String,Object],inputStyle:[Array,String,Object],tabindex:{type:[String,Number],default:0},autocomplete:String,transitionShow:{},transitionHide:{},transitionDuration:{},behavior:{type:String,validator:l=>["default","menu","dialog"].includes(l),default:"default"},virtualScrollItemSize:_i.virtualScrollItemSize.type,onNewValue:Function,onFilter:Function},emits:[...Gi,"add","remove","inputValue","keyup","keypress","keydown","popupShow","popupHide","filterAbort"],setup(l,{slots:B,emit:t}){const{proxy:b}=v.getCurrentInstance(),{$q:m}=b,c=v.ref(!1),i=v.ref(!1),s=v.ref(-1),n=v.ref(""),e=v.ref(!1),r=v.ref(!1);let u=null,a=null,o,f,h,d=null,g,p,k,C;const T=v.ref(null),D=v.ref(null),V=v.ref(null),P=v.ref(null),N=v.ref(null),q=wa(l),W=Qa(me),L=v.computed(()=>Array.isArray(l.options)?l.options.length:0),A=v.computed(()=>l.virtualScrollItemSize===void 0?l.optionsDense===!0?24:48:l.virtualScrollItemSize),{virtualScrollSliceRange:M,virtualScrollSliceSizeComputed:_,localResetVirtualScroll:y,padVirtualScroll:x,onVirtualScrollEvt:w,scrollTo:S,setVirtualScrollSize:E}=Ya({virtualScrollLength:L,getVirtualScrollTarget:nt,getVirtualScrollEl:He,virtualScrollItemSizeComputed:A}),O=Ji(),R=v.computed(()=>{const de=l.mapOptions===!0&&l.multiple!==!0,je=l.modelValue!==void 0&&(l.modelValue!==null||de===!0)?l.multiple===!0&&Array.isArray(l.modelValue)?l.modelValue:[l.modelValue]:[];if(l.mapOptions===!0&&Array.isArray(l.options)===!0){const Z=l.mapOptions===!0&&o!==void 0?o:[],he=je.map(ye=>Fe(ye,Z));return l.modelValue===null&&de===!0?he.filter(ye=>ye!==null):he}return je}),z=v.computed(()=>{const de={};return fu.forEach(je=>{const Z=l[je];Z!==void 0&&(de[je]=Z)}),de}),U=v.computed(()=>l.optionsDark===null?O.isDark.value:l.optionsDark),Q=v.computed(()=>Xr(R.value)),j=v.computed(()=>{let de="q-field__input q-placeholder col";return l.hideSelected===!0||R.value.length===0?[de,l.inputClass]:(de+=" q-field__input--padding",l.inputClass===void 0?de:[de,l.inputClass])}),Y=v.computed(()=>(l.virtualScrollHorizontal===!0?"q-virtual-scroll--horizontal":"")+(l.popupContentClass?" "+l.popupContentClass:"")),F=v.computed(()=>L.value===0),I=v.computed(()=>R.value.map(de=>ie.value(de)).join(", ")),H=v.computed(()=>l.displayValue!==void 0?l.displayValue:I.value),K=v.computed(()=>l.optionsHtml===!0?()=>!0:de=>de?.html===!0),ee=v.computed(()=>l.displayValueHtml===!0||l.displayValue===void 0&&(l.optionsHtml===!0||R.value.some(K.value))),G=v.computed(()=>O.focused.value===!0?l.tabindex:-1),te=v.computed(()=>{const de={tabindex:l.tabindex,role:"combobox","aria-label":l.label,"aria-readonly":l.readonly===!0?"true":"false","aria-autocomplete":l.useInput===!0?"list":"none","aria-expanded":c.value===!0?"true":"false","aria-controls":`${O.targetUid.value}_lb`};return s.value>=0&&(de["aria-activedescendant"]=`${O.targetUid.value}_${s.value}`),de}),ce=v.computed(()=>({id:`${O.targetUid.value}_lb`,role:"listbox","aria-multiselectable":l.multiple===!0?"true":"false"})),ue=v.computed(()=>R.value.map((de,je)=>({index:je,opt:de,html:K.value(de),selected:!0,removeAtIndex:Te,toggleOption:Ne,tabindex:G.value}))),J=v.computed(()=>{if(L.value===0)return[];const{from:de,to:je}=M.value;return l.options.slice(de,je).map((Z,he)=>{const ye=oe.value(Z)===!0,we=ke(Z)===!0,Pe=de+he,Se={clickable:!0,active:we,activeClass:pe.value,manualFocus:!0,focused:!1,disable:ye,tabindex:-1,dense:l.optionsDense,dark:U.value,role:"option","aria-selected":we===!0?"true":"false",id:`${O.targetUid.value}_${Pe}`,onClick:()=>{Ne(Z)}};return ye!==!0&&(s.value===Pe&&(Se.focused=!0),m.platform.is.desktop===!0&&(Se.onMousemove=()=>{c.value===!0&&Le(Pe)})),{index:Pe,opt:Z,html:K.value(Z),label:ie.value(Z),selected:Se.active,focused:Se.focused,toggleOption:Ne,setOptionIndex:Le,itemProps:Se}})}),ae=v.computed(()=>l.dropdownIcon!==void 0?l.dropdownIcon:m.iconSet.arrow.dropdown),se=v.computed(()=>l.optionsCover===!1&&l.outlined!==!0&&l.standout!==!0&&l.borderless!==!0&&l.rounded!==!0),pe=v.computed(()=>l.optionsSelectedClass!==void 0?l.optionsSelectedClass:l.color!==void 0?`text-${l.color}`:""),$=v.computed(()=>si(l.optionValue,"value")),ie=v.computed(()=>si(l.optionLabel,"label")),oe=v.computed(()=>si(l.optionDisable,"disable")),le=v.computed(()=>R.value.map($.value)),ge=v.computed(()=>{const de={onInput:me,onChange:W,onKeydown:et,onKeyup:Ve,onKeypress:Ge,onFocus:De,onClick(je){f===!0&&Dt(je)}};return de.onCompositionstart=de.onCompositionupdate=de.onCompositionend=W,de});v.watch(R,de=>{o=de,l.useInput===!0&&l.fillInput===!0&&l.multiple!==!0&&O.innerLoading.value!==!0&&(i.value!==!0&&c.value!==!0||Q.value!==!0)&&(h!==!0&&ze(),(i.value===!0||c.value===!0)&&Oe(""))},{immediate:!0}),v.watch(()=>l.fillInput,ze),v.watch(c,Je),v.watch(L,Ze);function Ce(de){return l.emitValue===!0?$.value(de):de}function Ae(de){if(de!==-1&&de<R.value.length)if(l.multiple===!0){const je=l.modelValue.slice();t("remove",{index:de,value:je.splice(de,1)[0]}),t("update:modelValue",je)}else t("update:modelValue",null)}function Te(de){Ae(de),O.focus()}function Ue(de,je){const Z=Ce(de);if(l.multiple!==!0){l.fillInput===!0&&Re(ie.value(de),!0,!0),t("update:modelValue",Z);return}if(R.value.length===0){t("add",{index:0,value:Z}),t("update:modelValue",l.multiple===!0?[Z]:Z);return}if(je===!0&&ke(de)===!0||l.maxValues!==void 0&&l.modelValue.length>=l.maxValues)return;const he=l.modelValue.slice();t("add",{index:he.length,value:Z}),he.push(Z),t("update:modelValue",he)}function Ne(de,je){if(O.editable.value!==!0||de===void 0||oe.value(de)===!0)return;const Z=$.value(de);if(l.multiple!==!0){je!==!0&&(Re(l.fillInput===!0?ie.value(de):"",!0,!0),Be()),D.value?.focus(),(R.value.length===0||rr($.value(R.value[0]),Z)!==!0)&&t("update:modelValue",l.emitValue===!0?Z:de);return}if((f!==!0||e.value===!0)&&O.focus(),De(),R.value.length===0){const we=l.emitValue===!0?Z:de;t("add",{index:0,value:we}),t("update:modelValue",l.multiple===!0?[we]:we);return}const he=l.modelValue.slice(),ye=le.value.findIndex(we=>rr(we,Z));if(ye!==-1)t("remove",{index:ye,value:he.splice(ye,1)[0]});else{if(l.maxValues!==void 0&&he.length>=l.maxValues)return;const we=l.emitValue===!0?Z:de;t("add",{index:he.length,value:we}),he.push(we)}t("update:modelValue",he)}function Le(de){if(m.platform.is.desktop!==!0)return;const je=de!==-1&&de<L.value?de:-1;s.value!==je&&(s.value=je)}function qe(de=1,je){if(c.value===!0){let Z=s.value;do Z=_o(Z+de,-1,L.value-1);while(Z!==-1&&Z!==s.value&&oe.value(l.options[Z])===!0);s.value!==Z&&(Le(Z),S(Z),je!==!0&&l.useInput===!0&&l.fillInput===!0&&xe(Z>=0?ie.value(l.options[Z]):g,!0))}}function Fe(de,je){const Z=he=>rr($.value(he),de);return l.options.find(Z)||je.find(Z)||de}function ke(de){const je=$.value(de);return le.value.find(Z=>rr(Z,je))!==void 0}function De(de){l.useInput===!0&&D.value!==null&&(de===void 0||D.value===de.target&&de.target.value===I.value)&&D.value.select()}function We(de){or(de,27)===!0&&c.value===!0&&(Dt(de),Be(),ze()),t("keyup",de)}function Ve(de){const{value:je}=de.target;if(de.keyCode!==void 0){We(de);return}if(de.target.value="",u!==null&&(clearTimeout(u),u=null),a!==null&&(clearTimeout(a),a=null),ze(),typeof je=="string"&&je.length!==0){const Z=je.toLocaleLowerCase(),he=we=>{const Pe=l.options.find(Se=>String(we.value(Se)).toLocaleLowerCase()===Z);return Pe===void 0?!1:(R.value.indexOf(Pe)===-1?Ne(Pe):Be(),!0)},ye=we=>{he($)!==!0&&we!==!0&&he(ie)!==!0&&Oe(je,!0,()=>ye(!0))};ye()}else O.clearValue(de)}function Ge(de){t("keypress",de)}function et(de){if(t("keydown",de),Di(de)===!0)return;const je=n.value.length!==0&&(l.newValueMode!==void 0||l.onNewValue!==void 0),Z=de.shiftKey!==!0&&l.disableTabSelection!==!0&&l.multiple!==!0&&(s.value!==-1||je===!0);if(de.keyCode===27){Bt(de);return}if(de.keyCode===9&&Z===!1){ve();return}if(de.target===void 0||de.target.id!==O.targetUid.value||O.editable.value!==!0)return;if(de.keyCode===40&&O.innerLoading.value!==!0&&c.value===!1){St(de),_e();return}if(de.keyCode===8&&(l.useChips===!0||l.clearable===!0)&&l.hideSelected!==!0&&n.value.length===0){l.multiple===!0&&Array.isArray(l.modelValue)===!0?Ae(l.modelValue.length-1):l.multiple!==!0&&l.modelValue!==null&&t("update:modelValue",null);return}(de.keyCode===35||de.keyCode===36)&&(typeof n.value!="string"||n.value.length===0)&&(St(de),s.value=-1,qe(de.keyCode===36?1:-1,l.multiple)),(de.keyCode===33||de.keyCode===34)&&_.value!==void 0&&(St(de),s.value=Math.max(-1,Math.min(L.value,s.value+(de.keyCode===33?-1:1)*_.value.view)),qe(de.keyCode===33?1:-1,l.multiple)),(de.keyCode===38||de.keyCode===40)&&(St(de),qe(de.keyCode===38?-1:1,l.multiple));const he=L.value;if((k===void 0||C<Date.now())&&(k=""),he>0&&l.useInput!==!0&&de.key!==void 0&&de.key.length===1&&de.altKey===!1&&de.ctrlKey===!1&&de.metaKey===!1&&(de.keyCode!==32||k.length!==0)){c.value!==!0&&_e(de);const ye=de.key.toLocaleLowerCase(),we=k.length===1&&k[0]===ye;C=Date.now()+1500,we===!1&&(St(de),k+=ye);const Pe=new RegExp("^"+k.split("").map(Ie=>du.indexOf(Ie)!==-1?"\\"+Ie:Ie).join(".*"),"i");let Se=s.value;if(we===!0||Se<0||Pe.test(ie.value(l.options[Se]))!==!0)do Se=_o(Se+1,-1,he-1);while(Se!==s.value&&(oe.value(l.options[Se])===!0||Pe.test(ie.value(l.options[Se]))!==!0));s.value!==Se&&v.nextTick(()=>{Le(Se),S(Se),Se>=0&&l.useInput===!0&&l.fillInput===!0&&xe(ie.value(l.options[Se]),!0)});return}if(!(de.keyCode!==13&&(de.keyCode!==32||l.useInput===!0||k!=="")&&(de.keyCode!==9||Z===!1))){if(de.keyCode!==9&&St(de),s.value!==-1&&s.value<he){Ne(l.options[s.value]);return}if(je===!0){const ye=(we,Pe)=>{if(Pe){if(Yo(Pe)!==!0)return}else Pe=l.newValueMode;if(Re("",l.multiple!==!0,!0),we==null)return;(Pe==="toggle"?Ne:Ue)(we,Pe==="add-unique"),l.multiple!==!0&&(D.value?.focus(),Be())};if(l.onNewValue!==void 0?t("newValue",n.value,ye):ye(n.value),l.multiple!==!0)return}c.value===!0?ve():O.innerLoading.value!==!0&&_e()}}function He(){return f===!0?N.value:V.value!==null&&V.value.contentEl!==null?V.value.contentEl:void 0}function nt(){return He()}function tt(){return l.hideSelected===!0?[]:B["selected-item"]!==void 0?ue.value.map(de=>B["selected-item"](de)).slice():B.selected!==void 0?[].concat(B.selected()):l.useChips===!0?ue.value.map((de,je)=>v.h(za,{key:"option-"+je,removable:O.editable.value===!0&&oe.value(de.opt)!==!0,dense:!0,textColor:l.color,tabindex:G.value,onRemove(){de.removeAtIndex(je)}},()=>v.h("span",{class:"ellipsis",[de.html===!0?"innerHTML":"textContent"]:ie.value(de.opt)}))):[v.h("span",{class:"ellipsis",[ee.value===!0?"innerHTML":"textContent"]:H.value})]}function Ye(){if(F.value===!0)return B["no-option"]!==void 0?B["no-option"]({inputValue:n.value}):void 0;const de=B.option!==void 0?B.option:Z=>v.h(hr,{key:Z.index,...Z.itemProps},()=>v.h(nr,()=>v.h(ki,()=>v.h("span",{[Z.html===!0?"innerHTML":"textContent"]:Z.label}))));let je=x("div",J.value.map(de));return B["before-options"]!==void 0&&(je=B["before-options"]().concat(je)),It(B["after-options"],je)}function st(de,je){const Z=je===!0?{...te.value,...O.splitAttrs.attributes.value}:void 0,he={ref:je===!0?D:void 0,key:"i_t",class:j.value,style:l.inputStyle,value:n.value!==void 0?n.value:"",type:"search",...Z,id:je===!0?O.targetUid.value:void 0,maxlength:l.maxlength,autocomplete:l.autocomplete,"data-autofocus":de===!0||l.autofocus===!0||void 0,disabled:l.disable===!0,readonly:l.readonly===!0,...ge.value};return de!==!0&&f===!0&&(Array.isArray(he.class)===!0?he.class=[...he.class,"no-pointer-events"]:he.class+=" no-pointer-events"),v.h("input",he)}function me(de){u!==null&&(clearTimeout(u),u=null),a!==null&&(clearTimeout(a),a=null),!(de&&de.target&&de.target.qComposing===!0)&&(xe(de.target.value||""),h=!0,g=n.value,O.focused.value!==!0&&(f!==!0||e.value===!0)&&O.focus(),l.onFilter!==void 0&&(u=setTimeout(()=>{u=null,Oe(n.value)},l.inputDebounce)))}function xe(de,je){n.value!==de&&(n.value=de,je===!0||l.inputDebounce===0||l.inputDebounce==="0"?t("inputValue",de):a=setTimeout(()=>{a=null,t("inputValue",de)},l.inputDebounce))}function Re(de,je,Z){h=Z!==!0,l.useInput===!0&&(xe(de,!0),(je===!0||Z!==!0)&&(g=de),je!==!0&&Oe(de))}function Oe(de,je,Z){if(l.onFilter===void 0||je!==!0&&O.focused.value!==!0)return;O.innerLoading.value===!0?t("filterAbort"):(O.innerLoading.value=!0,r.value=!0),de!==""&&l.multiple!==!0&&R.value.length!==0&&h!==!0&&de===ie.value(R.value[0])&&(de="");const he=setTimeout(()=>{c.value===!0&&(c.value=!1)},10);d!==null&&clearTimeout(d),d=he,t("filter",de,(ye,we)=>{(je===!0||O.focused.value===!0)&&d===he&&(clearTimeout(d),typeof ye=="function"&&ye(),r.value=!1,v.nextTick(()=>{O.innerLoading.value=!1,O.editable.value===!0&&(je===!0?c.value===!0&&Be():c.value===!0?Je(!0):c.value=!0),typeof we=="function"&&v.nextTick(()=>{we(b)}),typeof Z=="function"&&v.nextTick(()=>{Z(b)})}))},()=>{O.focused.value===!0&&d===he&&(clearTimeout(d),O.innerLoading.value=!1,r.value=!1),c.value===!0&&(c.value=!1)})}function Ee(){return v.h(Zr,{ref:V,class:Y.value,style:l.popupContentStyle,modelValue:c.value,fit:l.menuShrink!==!0,cover:l.optionsCover===!0&&F.value!==!0&&l.useInput!==!0,anchor:l.menuAnchor,self:l.menuSelf,offset:l.menuOffset,dark:U.value,noParentEvent:!0,noRefocus:!0,noFocus:!0,noRouteDismiss:l.popupNoRouteDismiss,square:se.value,transitionShow:l.transitionShow,transitionHide:l.transitionHide,transitionDuration:l.transitionDuration,separateClosePopup:!0,...ce.value,onScrollPassive:w,onBeforeShow:yt,onBeforeHide:Qe,onShow:Ke},Ye)}function Qe(de){ft(de),ve()}function Ke(){E()}function re(de){Dt(de),D.value?.focus(),e.value=!0,window.scrollTo(window.pageXOffset||window.scrollX||document.body.scrollLeft||0,0)}function X(de){Dt(de),v.nextTick(()=>{e.value=!1})}function ne(){const de=[v.h(Jl,{class:`col-auto ${O.fieldClass.value}`,...z.value,for:O.targetUid.value,dark:U.value,square:!0,loading:r.value,itemAligned:!1,filled:!0,stackLabel:n.value.length!==0,...O.splitAttrs.listeners.value,onFocus:re,onBlur:X},{...B,rawControl:()=>O.getControl(!0),before:void 0,after:void 0})];return c.value===!0&&de.push(v.h("div",{ref:N,class:Y.value+" scroll",style:l.popupContentStyle,...ce.value,onClick:Bt,onScrollPassive:w},Ye())),v.h(en,{ref:P,modelValue:i.value,position:l.useInput===!0?"top":void 0,transitionShow:p,transitionHide:l.transitionHide,transitionDuration:l.transitionDuration,noRouteDismiss:l.popupNoRouteDismiss,onBeforeShow:yt,onBeforeHide:fe,onHide:be,onShow:Me},()=>v.h("div",{class:"q-select__dialog"+(U.value===!0?" q-select__dialog--dark q-dark":"")+(e.value===!0?" q-select__dialog--focused":"")},de))}function fe(de){ft(de),P.value!==null&&P.value.__updateRefocusTarget(O.rootRef.value.querySelector(".q-field__native > [tabindex]:last-child")),O.focused.value=!1}function be(de){Be(),O.focused.value===!1&&t("blur",de),ze()}function Me(){const de=document.activeElement;(de===null||de.id!==O.targetUid.value)&&D.value!==null&&D.value!==de&&D.value.focus(),E()}function ve(){i.value!==!0&&(s.value=-1,c.value===!0&&(c.value=!1),O.focused.value===!1&&(d!==null&&(clearTimeout(d),d=null),O.innerLoading.value===!0&&(t("filterAbort"),O.innerLoading.value=!1,r.value=!1)))}function _e(de){O.editable.value===!0&&(f===!0?(O.onControlFocusin(de),i.value=!0,v.nextTick(()=>{O.focus()})):O.focus(),l.onFilter!==void 0?Oe(n.value):(F.value!==!0||B["no-option"]!==void 0)&&(c.value=!0))}function Be(){i.value=!1,ve()}function ze(){l.useInput===!0&&Re(l.multiple!==!0&&l.fillInput===!0&&R.value.length!==0&&ie.value(R.value[0])||"",!0,!0)}function Je(de){let je=-1;if(de===!0){if(R.value.length!==0){const Z=$.value(R.value[0]);je=l.options.findIndex(he=>rr($.value(he),Z))}y(je)}Le(je)}function Ze(de,je){c.value===!0&&O.innerLoading.value===!1&&(y(-1,!0),v.nextTick(()=>{c.value===!0&&O.innerLoading.value===!1&&(de>je?y():Je(!0))}))}function rt(){i.value===!1&&V.value!==null&&V.value.updatePosition()}function yt(de){de!==void 0&&Dt(de),t("popupShow",de),O.hasPopupOpen=!0,O.onControlFocusin(de)}function ft(de){de!==void 0&&Dt(de),t("popupHide",de),O.hasPopupOpen=!1,O.onControlFocusout(de)}function kt(){f=m.platform.is.mobile!==!0&&l.behavior!=="dialog"?!1:l.behavior!=="menu"&&(l.useInput===!0?B["no-option"]!==void 0||l.onFilter!==void 0||F.value===!1:!0),p=m.platform.is.ios===!0&&f===!0&&l.useInput===!0?"fade":l.transitionShow}return v.onBeforeUpdate(kt),v.onUpdated(rt),kt(),v.onBeforeUnmount(()=>{u!==null&&clearTimeout(u),a!==null&&clearTimeout(a)}),Object.assign(b,{showPopup:_e,hidePopup:Be,removeAtIndex:Ae,add:Ue,toggleOption:Ne,getOptionIndex:()=>s.value,setOptionIndex:Le,moveOptionSelection:qe,filter:Oe,updateMenuPosition:rt,updateInputValue:Re,isOptionSelected:ke,getEmittingOptionValue:Ce,isOptionDisabled:(...de)=>oe.value.apply(null,de)===!0,getOptionValue:(...de)=>$.value.apply(null,de),getOptionLabel:(...de)=>ie.value.apply(null,de)}),Object.assign(O,{innerValue:R,fieldClass:v.computed(()=>`q-select q-field--auto-height q-select--with${l.useInput!==!0?"out":""}-input q-select--with${l.useChips!==!0?"out":""}-chips q-select--${l.multiple===!0?"multiple":"single"}`),inputRef:T,targetRef:D,hasValue:Q,showPopup:_e,floatingLabel:v.computed(()=>l.hideSelected!==!0&&Q.value===!0||typeof n.value=="number"||n.value.length!==0||Xr(l.displayValue)),getControlChild:()=>{if(O.editable.value!==!1&&(i.value===!0||F.value!==!0||B["no-option"]!==void 0))return f===!0?ne():Ee();O.hasPopupOpen===!0&&(O.hasPopupOpen=!1)},controlEvents:{onFocusin(de){O.onControlFocusin(de)},onFocusout(de){O.onControlFocusout(de,()=>{ze(),ve()})},onClick(de){if(Bt(de),f!==!0&&c.value===!0){ve(),D.value?.focus();return}_e(de)}},getControl:de=>{const je=tt(),Z=de===!0||i.value!==!0||f!==!0;if(l.useInput===!0)je.push(st(de,Z));else if(O.editable.value===!0){const ye=Z===!0?te.value:void 0;je.push(v.h("input",{ref:Z===!0?D:void 0,key:"d_t",class:"q-select__focus-target",id:Z===!0?O.targetUid.value:void 0,value:H.value,readonly:!0,"data-autofocus":de===!0||l.autofocus===!0||void 0,...ye,onKeydown:et,onKeyup:We,onKeypress:Ge})),Z===!0&&typeof l.autocomplete=="string"&&l.autocomplete.length!==0&&je.push(v.h("input",{class:"q-select__autocomplete-input",autocomplete:l.autocomplete,tabindex:-1,onKeyup:Ve}))}if(q.value!==void 0&&l.disable!==!0&&le.value.length!==0){const ye=le.value.map(we=>v.h("option",{value:we,selected:!0}));je.push(v.h("select",{class:"hidden",name:q.value,multiple:l.multiple},ye))}const he=l.useInput===!0||Z!==!0?void 0:O.splitAttrs.attributes.value;return v.h("div",{class:"q-field__native row items-center",...he,...O.splitAttrs.listeners.value},je)},getInnerAppend:()=>l.loading!==!0&&r.value!==!0&&l.hideDropdownIcon!==!0?[v.h(dt,{class:"q-select__dropdown-icon"+(c.value===!0?" rotate-180":""),name:ae.value})]:null}),Zi(O)}}),hu={class:"q-pa-none"},pu=v.defineComponent({__name:"CheckboxFilter",props:{options:{},label:{default:"Sélectionner les options"},modelValue:{default:()=>[]},scrollAreaHeight:{default:"200px"},scrollAreaWidth:{default:"250px"},dataCy:{default:"checkbox-filter"}},emits:["update:modelValue"],setup(l,{emit:B}){const t=l,b=B,m=v.ref(!1),c=v.ref(t.modelValue||[]),i=v.computed(()=>({height:t.scrollAreaHeight,width:t.scrollAreaWidth})),s=v.computed(()=>t.dataCy||"checkbox-filter");return v.watch(c,n=>{b("update:modelValue",n)}),v.watch(()=>t.modelValue,n=>{n&&(c.value=n)},{immediate:!0}),(n,e)=>(v.openBlock(),v.createElementBlock("div",hu,[v.createVNode(Wn,v.mergeProps({outlined:"",dense:"",label:t.label,class:["full-width","cursor-pointer"],"data-cy":s.value,"model-value":null,options:[],"hide-dropdown-icon":""},n.$attrs),{append:v.withCtx(()=>[v.createVNode(dt,{name:"arrow_drop_down",class:v.normalizeClass(["cursor-pointer smooth-rotate",{"rotate-180":m.value}])},null,8,["class"])]),default:v.withCtx(()=>[v.createVNode(Zr,{modelValue:m.value,"onUpdate:modelValue":e[1]||(e[1]=r=>m.value=r),anchor:"bottom left",self:"top left",offset:[0,8],"transition-show":"scale","transition-hide":"scale"},{default:v.withCtx(()=>[v.createVNode(Dr,{class:"q-pa-sm"},{default:v.withCtx(()=>[v.createVNode(_l,{style:v.normalizeStyle(i.value)},{default:v.withCtx(()=>[(v.openBlock(!0),v.createElementBlock(v.Fragment,null,v.renderList(t.options,r=>(v.openBlock(),v.createBlock(Mr,{key:r.value,modelValue:c.value,"onUpdate:modelValue":e[0]||(e[0]=u=>c.value=u),val:r,disable:r.disabled,color:"primary",class:"q-mb-sm q-ml-sm q-mr-sm","data-cy":`${s.value}-option-${r.label}`},{default:v.withCtx(()=>[v.createElementVNode("span",{class:v.normalizeClass({"text-italic":r.italic})},v.toDisplayString(r.label),3)]),_:2},1032,["modelValue","val","disable","data-cy"]))),128))]),_:1},8,["style"])]),_:1})]),_:1},8,["modelValue"])]),_:1},16,["label","data-cy"])]))}}),mu=Vt(pu,[["__scopeId","data-v-b83ebff3"]]),gu=v.defineComponent({__name:"SelectSearch",props:{options:{default:()=>[]},fetchOptions:{},label:{default:"Selectionner un option"},modelValue:{default:null},rules:{},updateInputOnModelChange:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(l,{emit:B}){const t=l,b=B,m=v.ref(),c=v.ref(t.modelValue??null),i=v.ref(""),s=v.ref(t.options??[]),n=v.ref(!1),e=v.ref(!0),r=v.ref(!1);v.watch(()=>t.options,g=>{s.value=g??[],u()},{immediate:!0}),v.watch(()=>t.modelValue,async g=>{if(t.updateInputOnModelChange){if(r.value=!0,t.fetchOptions&&g){const p=await t.fetchOptions("");s.value=p}c.value=g,u(),n.value=!1,await v.nextTick(),m.value?.updateInputValue(i.value,!0),setTimeout(()=>{r.value=!1},100)}else c.value=g});function u(){const g=s.value.find(p=>p.value===c.value);i.value=g?.label??""}function a(g){r.value||(c.value=g,b("update:modelValue",g),u(),n.value=!1)}function o(g){i.value=g,g===""&&(n.value=!0)}function f(){if(e.value){e.value=!1;return}c.value!==null&&!n.value?(i.value="",n.value=!0,m.value?.showPopup()):n.value&&(i.value="")}function h(){e.value=!0;const g=i.value.trim();if(g==="")n.value&&(c.value=null,b("update:modelValue",null));else{const p=s.value.find(k=>k.label.toLowerCase()===g.toLowerCase());p?(c.value=p.value,b("update:modelValue",p.value),i.value=p.label):u()}n.value=!1}function d(g,p,k){if(t.fetchOptions)t.fetchOptions(g).then(C=>{s.value=C,p(()=>{})}).catch(k).finally(()=>{});else{const C=t.options??[];s.value=C.filter(T=>T.label.toLowerCase().includes(g.toLowerCase())),p(()=>{})}}return v.onMounted(async()=>{if(t.fetchOptions&&t.modelValue){const g=await t.fetchOptions("");s.value=g,u()}}),(g,p)=>(v.openBlock(),v.createBlock(Wn,v.mergeProps({ref_key:"selectRef",ref:m,"model-value":c.value,"input-value":i.value,"use-input":"","fill-input":"","hide-selected":"","input-debounce":"300",label:g.label,options:s.value,"map-options":"",dense:"",outlined:"",class:"full-width cursor-pointer"},g.$attrs,{"onUpdate:modelValue":a,"onUpdate:inputValue":o,onFocus:f,onBlur:h,onFilter:d}),null,16,["model-value","input-value","label","options"]))}}),bu=v.defineComponent({__name:"SelectYear",props:{modelValue:{},label:{default:"Sélectionner une année"},startYear:{default:2015},endYear:{default:void 0}},emits:["update:modelValue"],setup(l,{emit:B}){const t=l,b=B,m=v.computed(()=>{const s=t.startYear??new Date().getFullYear()-5,n=t.endYear??new Date().getFullYear(),e=[];for(let r=n;r>=s;r--)e.push({label:String(r),value:r});return e});function c(s){b("update:modelValue",s)}function i(){t.modelValue!==null&&b("update:modelValue",null)}return(s,n)=>(v.openBlock(),v.createBlock(Wn,v.mergeProps({"model-value":s.modelValue,options:m.value,"option-value":"value","option-label":"label",label:s.label,dense:"","emit-value":"",outlined:"",class:"full-width cursor-pointer"},s.$attrs,{"onUpdate:modelValue":c,onFocus:i}),null,16,["model-value","options","label"]))}}),Xa=$e({name:"QAvatar",props:{...Fr,fontSize:String,color:String,textColor:String,icon:String,square:Boolean,rounded:Boolean},setup(l,{slots:B}){const t=jr(l),b=v.computed(()=>"q-avatar"+(l.color?` bg-${l.color}`:"")+(l.textColor?` text-${l.textColor} q-chip--colored`:"")+(l.square===!0?" q-avatar--square":l.rounded===!0?" rounded-borders":"")),m=v.computed(()=>l.fontSize?{fontSize:l.fontSize}:null);return()=>{const c=l.icon!==void 0?[v.h(dt,{name:l.icon})]:void 0;return v.h("div",{class:b.value,style:t.value},[v.h("div",{class:"q-avatar__content row flex-center overflow-hidden",style:m.value},la(B.default,c))])}}}),vu=$e({name:"QSpace",setup(){const l=v.h("div",{class:"q-space"});return()=>l}}),yu=["ul","ol"],Hn=$e({name:"QList",props:{...Ot,bordered:Boolean,dense:Boolean,separator:Boolean,padding:Boolean,tag:{type:String,default:"div"}},setup(l,{slots:B}){const t=v.getCurrentInstance(),b=Ft(l,t.proxy.$q),m=v.computed(()=>yu.includes(l.tag)?null:"list"),c=v.computed(()=>"q-list"+(l.bordered===!0?" q-list--bordered":"")+(l.dense===!0?" q-list--dense":"")+(l.separator===!0?" q-list--separator":"")+(b.value===!0?" q-list--dark":"")+(l.padding===!0?" q-list--padding":""));return()=>v.h(l.tag,{class:c.value,role:m.value},bt(B.default))}}),Ga=$e({name:"QToolbar",props:{inset:Boolean},setup(l,{slots:B}){const t=v.computed(()=>"q-toolbar row no-wrap items-center"+(l.inset===!0?" q-toolbar--inset":""));return()=>v.h("div",{class:t.value,role:"toolbar"},bt(B.default))}}),wu=$e({name:"QHeader",props:{modelValue:{type:Boolean,default:!0},reveal:Boolean,revealOffset:{type:Number,default:250},bordered:Boolean,elevated:Boolean,heightHint:{type:[String,Number],default:50}},emits:["reveal","focusin"],setup(l,{slots:B,emit:t}){const{proxy:{$q:b}}=v.getCurrentInstance(),m=v.inject($r,Rt);if(m===Rt)return console.error("QHeader needs to be child of QLayout"),Rt;const c=v.ref(parseInt(l.heightHint,10)),i=v.ref(!0),s=v.computed(()=>l.reveal===!0||m.view.value.indexOf("H")!==-1||b.platform.is.ios&&m.isContainer.value===!0),n=v.computed(()=>{if(l.modelValue!==!0)return 0;if(s.value===!0)return i.value===!0?c.value:0;const p=c.value-m.scroll.value.position;return p>0?p:0}),e=v.computed(()=>l.modelValue!==!0||s.value===!0&&i.value!==!0),r=v.computed(()=>l.modelValue===!0&&e.value===!0&&l.reveal===!0),u=v.computed(()=>"q-header q-layout__section--marginal "+(s.value===!0?"fixed":"absolute")+"-top"+(l.bordered===!0?" q-header--bordered":"")+(e.value===!0?" q-header--hidden":"")+(l.modelValue!==!0?" q-layout--prevent-focus":"")),a=v.computed(()=>{const p=m.rows.value.top,k={};return p[0]==="l"&&m.left.space===!0&&(k[b.lang.rtl===!0?"right":"left"]=`${m.left.size}px`),p[2]==="r"&&m.right.space===!0&&(k[b.lang.rtl===!0?"left":"right"]=`${m.right.size}px`),k});function o(p,k){m.update("header",p,k)}function f(p,k){p.value!==k&&(p.value=k)}function h({height:p}){f(c,p),o("size",p)}function d(p){r.value===!0&&f(i,!0),t("focusin",p)}v.watch(()=>l.modelValue,p=>{o("space",p),f(i,!0),m.animate()}),v.watch(n,p=>{o("offset",p)}),v.watch(()=>l.reveal,p=>{p===!1&&f(i,l.modelValue)}),v.watch(i,p=>{m.animate(),t("reveal",p)}),v.watch(m.scroll,p=>{l.reveal===!0&&f(i,p.direction==="up"||p.position<=l.revealOffset||p.position-p.inflectionPoint<100)});const g={};return m.instances.header=g,l.modelValue===!0&&o("size",c.value),o("space",l.modelValue),o("offset",n.value),v.onBeforeUnmount(()=>{m.instances.header===g&&(m.instances.header=void 0,o("size",0),o("offset",0),o("space",!1))}),()=>{const p=Ri(B.default,[]);return l.elevated===!0&&p.push(v.h("div",{class:"q-layout__shadow absolute-full overflow-hidden no-pointer-events"})),p.push(v.h(Ir,{debounce:0,onResize:h})),v.h("header",{class:u.value,style:a.value,onFocusin:d},p)}}});function Qo(l){if(l===!1)return 0;if(l===!0||l===void 0)return 1;const B=parseInt(l,10);return isNaN(B)?0:B}const $i=Ti({name:"close-popup",beforeMount(l,{value:B}){const t={depth:Qo(B),handler(b){t.depth!==0&&setTimeout(()=>{const m=Bl(l);m!==void 0&&Il(m,b,t.depth)})},handlerKey(b){or(b,13)===!0&&t.handler(b)}};l.__qclosepopup=t,l.addEventListener("click",t.handler),l.addEventListener("keyup",t.handlerKey)},updated(l,{value:B,oldValue:t}){B!==t&&(l.__qclosepopup.depth=Qo(B))},beforeUnmount(l){const B=l.__qclosepopup;l.removeEventListener("click",B.handler),l.removeEventListener("keyup",B.handlerKey),delete l.__qclosepopup}}),xu=["src","alt"],Su={key:0,class:"project-environment-container row items-center q-mr-md"},ku=v.defineComponent({__name:"SelfeeHeader",props:{logoSrc:{},logoAlt:{},logoTo:{},showProjectSwitch:{type:Boolean},currentProjectLabel:{},availableProjects:{},currentPath:{},environment:{}},emits:["project-change"],setup(l,{emit:B}){const t=l,b=t.logoAlt??"Logo",m=t.logoTo??"/",c=v.computed(()=>({width:"260px",height:"auto",borderRadius:"0"})),i=v.computed(()=>t.environment?t.environment.toUpperCase()!=="PROD":!1),s=v.computed(()=>`environment-badge--${t.environment?.toUpperCase()?.toLowerCase()}`),n=e=>t.currentPath?.startsWith(e);return(e,r)=>{const u=v.resolveComponent("router-link");return v.openBlock(),v.createBlock(wu,v.mergeProps({elevated:""},e.$attrs),{default:v.withCtx(()=>[v.createVNode(Ga,null,{default:v.withCtx(()=>[v.createVNode(u,{to:v.unref(m),class:"q-mr-lg"},{default:v.withCtx(()=>[v.createVNode(Xa,{class:"logo",style:v.normalizeStyle(c.value),"data-testid":"header-logo"},{default:v.withCtx(()=>[v.createElementVNode("img",{src:e.logoSrc,alt:v.unref(b)},null,8,xu)]),_:1},8,["style"])]),_:1},8,["to"]),v.createVNode(vu),e.showProjectSwitch||i.value?(v.openBlock(),v.createElementBlock("div",Su,[i.value?(v.openBlock(),v.createElementBlock("div",{key:0,class:v.normalizeClass(["environment-badge",s.value]),"data-testid":"environment-badge"},v.toDisplayString(e.environment),3)):v.createCommentVNode("",!0),e.showProjectSwitch?(v.openBlock(),v.createBlock(at,{key:1,dense:"",unelevated:"",color:"primary",label:e.currentProjectLabel,"data-testid":"project-switch-btn",class:"project-switch-btn q-mr-md bg-info"},{default:v.withCtx(()=>[v.createVNode(Zr,{anchor:"bottom right",self:"top right"},{default:v.withCtx(()=>[v.createVNode(Hn,{dense:"",class:"project-menu"},{default:v.withCtx(()=>[(v.openBlock(!0),v.createElementBlock(v.Fragment,null,v.renderList(e.availableProjects,a=>v.withDirectives((v.openBlock(),v.createBlock(hr,{key:a.path,clickable:"",disable:n(a.path),onClick:o=>e.$emit("project-change",a.path)},{default:v.withCtx(()=>[v.createVNode(nr,{class:"q-mr-lg"},{default:v.withCtx(()=>[v.createVNode(ki,null,{default:v.withCtx(()=>[v.createTextVNode(v.toDisplayString(a.label),1)]),_:2},1024),n(a.path)?(v.openBlock(),v.createBlock(ki,{key:0,caption:""},{default:v.withCtx(()=>r[0]||(r[0]=[v.createTextVNode(" Actuel ")])),_:1,__:[0]})):v.createCommentVNode("",!0)]),_:2},1024)]),_:2},1032,["disable","onClick"])),[[$i]])),128))]),_:1})]),_:1})]),_:1},8,["label"])):v.createCommentVNode("",!0)])):v.createCommentVNode("",!0),v.renderSlot(e.$slots,"user-avatar",{},void 0,!0)]),_:3})]),_:3},16)}}}),_u=Vt(ku,[["__scopeId","data-v-a4df46a4"]]),Cu=$e({name:"QFooter",props:{modelValue:{type:Boolean,default:!0},reveal:Boolean,bordered:Boolean,elevated:Boolean,heightHint:{type:[String,Number],default:50}},emits:["reveal","focusin"],setup(l,{slots:B,emit:t}){const{proxy:{$q:b}}=v.getCurrentInstance(),m=v.inject($r,Rt);if(m===Rt)return console.error("QFooter needs to be child of QLayout"),Rt;const c=v.ref(parseInt(l.heightHint,10)),i=v.ref(!0),s=v.ref(ar.value===!0||m.isContainer.value===!0?0:window.innerHeight),n=v.computed(()=>l.reveal===!0||m.view.value.indexOf("F")!==-1||b.platform.is.ios&&m.isContainer.value===!0),e=v.computed(()=>m.isContainer.value===!0?m.containerHeight.value:s.value),r=v.computed(()=>{if(l.modelValue!==!0)return 0;if(n.value===!0)return i.value===!0?c.value:0;const T=m.scroll.value.position+e.value+c.value-m.height.value;return T>0?T:0}),u=v.computed(()=>l.modelValue!==!0||n.value===!0&&i.value!==!0),a=v.computed(()=>l.modelValue===!0&&u.value===!0&&l.reveal===!0),o=v.computed(()=>"q-footer q-layout__section--marginal "+(n.value===!0?"fixed":"absolute")+"-bottom"+(l.bordered===!0?" q-footer--bordered":"")+(u.value===!0?" q-footer--hidden":"")+(l.modelValue!==!0?" q-layout--prevent-focus"+(n.value!==!0?" hidden":""):"")),f=v.computed(()=>{const T=m.rows.value.bottom,D={};return T[0]==="l"&&m.left.space===!0&&(D[b.lang.rtl===!0?"right":"left"]=`${m.left.size}px`),T[2]==="r"&&m.right.space===!0&&(D[b.lang.rtl===!0?"left":"right"]=`${m.right.size}px`),D});function h(T,D){m.update("footer",T,D)}function d(T,D){T.value!==D&&(T.value=D)}function g({height:T}){d(c,T),h("size",T)}function p(){if(l.reveal!==!0)return;const{direction:T,position:D,inflectionPoint:V}=m.scroll.value;d(i,T==="up"||D-V<100||m.height.value-e.value-D-c.value<300)}function k(T){a.value===!0&&d(i,!0),t("focusin",T)}v.watch(()=>l.modelValue,T=>{h("space",T),d(i,!0),m.animate()}),v.watch(r,T=>{h("offset",T)}),v.watch(()=>l.reveal,T=>{T===!1&&d(i,l.modelValue)}),v.watch(i,T=>{m.animate(),t("reveal",T)}),v.watch([c,m.scroll,m.height],p),v.watch(()=>b.screen.height,T=>{m.isContainer.value!==!0&&d(s,T)});const C={};return m.instances.footer=C,l.modelValue===!0&&h("size",c.value),h("space",l.modelValue),h("offset",r.value),v.onBeforeUnmount(()=>{m.instances.footer===C&&(m.instances.footer=void 0,h("size",0),h("offset",0),h("space",!1))}),()=>{const T=It(B.default,[v.h(Ir,{debounce:0,onResize:g})]);return l.elevated===!0&&T.push(v.h("div",{class:"q-layout__shadow absolute-full overflow-hidden no-pointer-events"})),v.h("footer",{class:o.value,style:f.value,onFocusin:k},T)}}}),Au={class:"row justify-between"},Eu={class:"col-3 q-py-md flex justify-center"},Mu={class:"col-3 q-py-md flex justify-center"},Tu={class:"col-3 q-py-md flex justify-center"},Ru=v.defineComponent({__name:"SelfeeFooter",props:{frontVersion:{},backVersion:{},platform:{}},setup(l){return(B,t)=>(v.openBlock(),v.createBlock(Cu,v.mergeProps({elevated:""},B.$attrs),{default:v.withCtx(()=>[v.createElementVNode("div",Au,[v.createElementVNode("div",Eu," Front: "+v.toDisplayString(B.frontVersion),1),v.createElementVNode("div",Mu," Back: "+v.toDisplayString(B.backVersion),1),v.createElementVNode("div",Tu," Platform: "+v.toDisplayString(B.platform),1)])]),_:1},16))}}),Bu={true:"inset",item:"item-inset","item-thumbnail":"item-thumbnail-inset"},li={xs:2,sm:4,md:8,lg:16,xl:24},Br=$e({name:"QSeparator",props:{...Ot,spaced:[Boolean,String],inset:[Boolean,String],vertical:Boolean,color:String,size:String},setup(l){const B=v.getCurrentInstance(),t=Ft(l,B.proxy.$q),b=v.computed(()=>l.vertical===!0?"vertical":"horizontal"),m=v.computed(()=>` q-separator--${b.value}`),c=v.computed(()=>l.inset!==!1?`${m.value}-${Bu[l.inset]}`:""),i=v.computed(()=>`q-separator${m.value}${c.value}`+(l.color!==void 0?` bg-${l.color}`:"")+(t.value===!0?" q-separator--dark":"")),s=v.computed(()=>{const n={};if(l.size!==void 0&&(n[l.vertical===!0?"width":"height"]=l.size),l.spaced!==!1){const e=l.spaced===!0?`${li.md}px`:l.spaced in li?`${li[l.spaced]}px`:l.spaced,r=l.vertical===!0?["Left","Right"]:["Top","Bottom"];n[`margin${r[0]}`]=n[`margin${r[1]}`]=e}return n});return()=>v.h("hr",{class:i.value,style:s.value,"aria-orientation":b.value})}}),Iu=$e({name:"QToggle",props:{...xa,icon:String,iconColor:String},emits:Sa,setup(l){function B(t,b){const m=v.computed(()=>(t.value===!0?l.checkedIcon:b.value===!0?l.indeterminateIcon:l.uncheckedIcon)||l.icon),c=v.computed(()=>t.value===!0?l.iconColor:null);return()=>[v.h("div",{class:"q-toggle__track"}),v.h("div",{class:"q-toggle__thumb absolute flex flex-center no-wrap"},m.value!==void 0?[v.h(dt,{name:m.value,color:c.value})]:void 0)]}return ka("toggle",B)}}),Ou={class:"text-h6 text-primary","data-testid":"avatar-initial"},Fu={class:"text-weight-bold"},ju={class:"row items-center q-gutter-sm"},Du={class:"version-info"},Pu={class:"text-caption"},Nu={class:"text-caption"},Lu={class:"text-caption"},Vu=v.defineComponent({__name:"UserAvatar",props:{username:{},onLogout:{},logoutLabel:{default:"Déconnexion"},frontVersion:{default:"N/A"},backVersion:{default:"N/A"},platform:{default:"N/A"},showVersionInfo:{type:Boolean,default:!0},showFilterToggle:{type:Boolean,default:!1},persistFilters:{type:Boolean,default:!1}},emits:["toggle-filter-persistence"],setup(l,{emit:B}){const t=l,b=v.computed(()=>t.username?.charAt(0).toUpperCase()??"");return(m,c)=>(v.openBlock(),v.createElementBlock("div",null,[v.createVNode(Xa,{class:"cursor-pointer",size:"40px",color:"white","data-cy":"cy-avatar","data-testid":"cy-avatar"},{default:v.withCtx(()=>[v.createElementVNode("span",Ou,v.toDisplayString(b.value),1),v.createVNode(Zr,{"transition-show":"flip-right","transition-hide":"flip-left",class:"user-avatar-menu"},{default:v.withCtx(()=>[v.createVNode(Hn,{class:"user-menu-list"},{default:v.withCtx(()=>[v.createVNode(hr,{class:"user-info-section"},{default:v.withCtx(()=>[v.createVNode(nr,null,{default:v.withCtx(()=>[v.createElementVNode("div",Fu,v.toDisplayString(m.username),1)]),_:1})]),_:1}),v.createVNode(Br),m.showFilterToggle?(v.openBlock(),v.createBlock(hr,{key:0,class:"filter-toggle-section"},{default:v.withCtx(()=>[v.createVNode(nr,null,{default:v.withCtx(()=>[v.createElementVNode("div",ju,[c[1]||(c[1]=v.createElementVNode("span",{class:"text-caption"},"Filtres persistants",-1)),v.createVNode(Iu,{"model-value":m.persistFilters,"onUpdate:modelValue":c[0]||(c[0]=i=>m.$emit("toggle-filter-persistence",i)),size:"sm","data-cy":"filter-persistence-toggle"},null,8,["model-value"])])]),_:1})]),_:1})):v.createCommentVNode("",!0),m.showFilterToggle?(v.openBlock(),v.createBlock(Br,{key:1})):v.createCommentVNode("",!0),m.showVersionInfo?(v.openBlock(),v.createBlock(hr,{key:2,class:"version-info-section"},{default:v.withCtx(()=>[v.createVNode(nr,null,{default:v.withCtx(()=>[v.createElementVNode("div",Du,[c[2]||(c[2]=v.createElementVNode("div",{class:"text-caption text-grey-7"},"Informations de version",-1)),v.createElementVNode("div",Pu,"Front: "+v.toDisplayString(m.frontVersion),1),v.createElementVNode("div",Nu,"Back: "+v.toDisplayString(m.backVersion),1),v.createElementVNode("div",Lu,"Plateforme: "+v.toDisplayString(m.platform),1)])]),_:1})]),_:1})):v.createCommentVNode("",!0),m.showVersionInfo?(v.openBlock(),v.createBlock(Br,{key:3})):v.createCommentVNode("",!0),v.createVNode(hr,{clickable:"",class:"logout-section","data-cy":"cy-logout-button","data-testid":"cy-logout-button",onClick:m.onLogout},{default:v.withCtx(()=>[v.createVNode(nr,null,{default:v.withCtx(()=>[v.createElementVNode("div",null,v.toDisplayString(m.logoutLabel),1)]),_:1})]),_:1},8,["onClick"])]),_:1})]),_:1})]),_:1})]))}}),qu=Vt(Vu,[["__scopeId","data-v-d9b256cf"]]),zu=$e({name:"QPageContainer",setup(l,{slots:B}){const{proxy:{$q:t}}=v.getCurrentInstance(),b=v.inject($r,Rt);if(b===Rt)return console.error("QPageContainer needs to be child of QLayout"),Rt;v.provide(Va,!0);const m=v.computed(()=>{const c={};return b.header.space===!0&&(c.paddingTop=`${b.header.size}px`),b.right.space===!0&&(c[`padding${t.lang.rtl===!0?"Left":"Right"}`]=`${b.right.size}px`),b.footer.space===!0&&(c.paddingBottom=`${b.footer.size}px`),b.left.space===!0&&(c[`padding${t.lang.rtl===!0?"Right":"Left"}`]=`${b.left.size}px`),c});return()=>v.h("div",{class:"q-page-container",style:m.value},bt(B.default))}}),Uu=$e({name:"QLayout",props:{container:Boolean,view:{type:String,default:"hhh lpr fff",validator:l=>/^(h|l)h(h|r) lpr (f|l)f(f|r)$/.test(l.toLowerCase())},onScroll:Function,onScrollHeight:Function,onResize:Function},setup(l,{slots:B,emit:t}){const{proxy:{$q:b}}=v.getCurrentInstance(),m=v.ref(null),c=v.ref(b.screen.height),i=v.ref(l.container===!0?0:b.screen.width),s=v.ref({position:0,direction:"down",inflectionPoint:0}),n=v.ref(0),e=v.ref(ar.value===!0?0:Sn()),r=v.computed(()=>"q-layout q-layout--"+(l.container===!0?"containerized":"standard")),u=v.computed(()=>l.container===!1?{minHeight:b.screen.height+"px"}:null),a=v.computed(()=>e.value!==0?{[b.lang.rtl===!0?"left":"right"]:`${e.value}px`}:null),o=v.computed(()=>e.value!==0?{[b.lang.rtl===!0?"right":"left"]:0,[b.lang.rtl===!0?"left":"right"]:`-${e.value}px`,width:`calc(100% + ${e.value}px)`}:null);function f(C){if(l.container===!0||document.qScrollPrevented!==!0){const T={position:C.position.top,direction:C.direction,directionChanged:C.directionChanged,inflectionPoint:C.inflectionPoint.top,delta:C.delta.top};s.value=T,l.onScroll!==void 0&&t("scroll",T)}}function h(C){const{height:T,width:D}=C;let V=!1;c.value!==T&&(V=!0,c.value=T,l.onScrollHeight!==void 0&&t("scrollHeight",T),g()),i.value!==D&&(V=!0,i.value=D),V===!0&&l.onResize!==void 0&&t("resize",C)}function d({height:C}){n.value!==C&&(n.value=C,g())}function g(){if(l.container===!0){const C=c.value>n.value?Sn():0;e.value!==C&&(e.value=C)}}let p=null;const k={instances:{},view:v.computed(()=>l.view),isContainer:v.computed(()=>l.container),rootRef:m,height:c,containerHeight:n,scrollbarWidth:e,totalWidth:v.computed(()=>i.value+e.value),rows:v.computed(()=>{const C=l.view.toLowerCase().split(" ");return{top:C[0].split(""),middle:C[1].split(""),bottom:C[2].split("")}}),header:v.reactive({size:0,offset:0,space:!1}),right:v.reactive({size:300,offset:0,space:!1}),footer:v.reactive({size:0,offset:0,space:!1}),left:v.reactive({size:300,offset:0,space:!1}),scroll:s,animate(){p!==null?clearTimeout(p):document.body.classList.add("q-body--layout-animate"),p=setTimeout(()=>{p=null,document.body.classList.remove("q-body--layout-animate")},155)},update(C,T,D){k[C][T]=D}};if(v.provide($r,k),Sn()>0){let C=function(){V=null,P.classList.remove("hide-scrollbar")},T=function(){if(V===null){if(P.scrollHeight>b.screen.height)return;P.classList.add("hide-scrollbar")}else clearTimeout(V);V=setTimeout(C,300)},D=function(N){V!==null&&N==="remove"&&(clearTimeout(V),C()),window[`${N}EventListener`]("resize",T)},V=null;const P=document.body;v.watch(()=>l.container!==!0?"add":"remove",D),l.container!==!0&&D("add"),v.onUnmounted(()=>{D("remove")})}return()=>{const C=It(B.default,[v.h(Ma,{onScroll:f}),v.h(Ir,{onResize:h})]),T=v.h("div",{class:r.value,style:u.value,ref:l.container===!0?void 0:m,tabindex:-1},C);return l.container===!0?v.h("div",{class:"q-layout-container overflow-hidden",ref:m},[v.h(Ir,{onResize:d}),v.h("div",{class:"absolute-full",style:a.value},[v.h("div",{class:"scroll",style:o.value},[T])])]):T}}}),eo=v.defineComponent({name:"Layout",__name:"Layout",props:{view:{default:"HHh Lpr Fff"},layoutClass:{default:"bg-white"},pageContainerClass:{default:""}},setup(l){return(B,t)=>(v.openBlock(),v.createBlock(Uu,{view:B.view,class:v.normalizeClass(B.layoutClass),style:{minHeight:"auto !important"}},{default:v.withCtx(()=>[v.renderSlot(B.$slots,"header"),v.createVNode(zu,{class:v.normalizeClass(B.pageContainerClass),style:{paddingBottom:"0 !important"}},{default:v.withCtx(()=>[v.renderSlot(B.$slots,"default")]),_:3},8,["class"]),v.renderSlot(B.$slots,"footer")]),_:3},8,["view","class"]))}});function Wu(){let l=Object.create(null);return{getCache:(B,t)=>l[B]===void 0?l[B]=typeof t=="function"?t():t:l[B],setCache(B,t){l[B]=t},hasCache(B){return Object.hasOwnProperty.call(l,B)},clearCache(B){B!==void 0?delete l[B]:l=Object.create(null)}}}const ir=[-61,9,38,199,426,686,756,818,1111,1181,1210,1635,2060,2097,2192,2262,2324,2394,2456,3178];function Hu(l,B,t){return Object.prototype.toString.call(l)==="[object Date]"&&(t=l.getDate(),B=l.getMonth()+1,l=l.getFullYear()),Xu(to(l,B,t))}function Ko(l,B,t){return Za(Ku(l,B,t))}function Yu(l){return Qu(l)===0}function kn(l,B){return B<=6?31:B<=11||Yu(l)?30:29}function Qu(l){const B=ir.length;let t=ir[0],b,m,c,i,s;if(l<t||l>=ir[B-1])throw new Error("Invalid Jalaali year "+l);for(s=1;s<B&&(b=ir[s],m=b-t,!(l<b));s+=1)t=b;return i=l-t,m-i<6&&(i=i-m+wt(m+4,33)*33),c=Pt(Pt(i+1,33)-1,4),c===-1&&(c=4),c}function Ja(l,B){const t=ir.length,b=l+621;let m=-14,c=ir[0],i,s,n,e,r;if(l<c||l>=ir[t-1])throw new Error("Invalid Jalaali year "+l);for(r=1;r<t&&(i=ir[r],s=i-c,!(l<i));r+=1)m=m+wt(s,33)*8+wt(Pt(s,33),4),c=i;e=l-c,m=m+wt(e,33)*8+wt(Pt(e,33)+3,4),Pt(s,33)===4&&s-e===4&&(m+=1);const u=wt(b,4)-wt((wt(b,100)+1)*3,4)-150,a=20+m-u;return B||(s-e<6&&(e=e-s+wt(s+4,33)*33),n=Pt(Pt(e+1,33)-1,4),n===-1&&(n=4)),{leap:n,gy:b,march:a}}function Ku(l,B,t){const b=Ja(l,!0);return to(b.gy,3,b.march)+(B-1)*31-wt(B,7)*(B-7)+t-1}function Xu(l){const B=Za(l).gy;let t=B-621,b,m,c;const i=Ja(t,!1),s=to(B,3,i.march);if(c=l-s,c>=0){if(c<=185)return m=1+wt(c,31),b=Pt(c,31)+1,{jy:t,jm:m,jd:b};c-=186}else t-=1,c+=179,i.leap===1&&(c+=1);return m=7+wt(c,30),b=Pt(c,30)+1,{jy:t,jm:m,jd:b}}function to(l,B,t){let b=wt((l+wt(B-8,6)+100100)*1461,4)+wt(153*Pt(B+9,12)+2,5)+t-34840408;return b=b-wt(wt(l+100100+wt(B-8,6),100)*3,4)+752,b}function Za(l){let B=4*l+139361631;B=B+wt(wt(4*l+183187720,146097)*3,4)*4-3908;const t=wt(Pt(B,1461),4)*5+308,b=wt(Pt(t,153),5)+1,m=Pt(wt(t,153),12)+1;return{gy:wt(B,1461)-100100+wt(8-m,6),gm:m,gd:b}}function wt(l,B){return~~(l/B)}function Pt(l,B){return l-~~(l/B)*B}const Gu=["gregorian","persian"],Xo={mask:{type:String},locale:Object,calendar:{type:String,validator:l=>Gu.includes(l),default:"gregorian"},landscape:Boolean,color:String,textColor:String,square:Boolean,flat:Boolean,bordered:Boolean,readonly:Boolean,disable:Boolean},Ju=["update:modelValue"];function $t(l){return l.year+"/"+vt(l.month)+"/"+vt(l.day)}function Zu(l,B){const t=v.computed(()=>l.disable!==!0&&l.readonly!==!0),b=v.computed(()=>t.value===!0?0:-1),m=v.computed(()=>{const s=[];return l.color!==void 0&&s.push(`bg-${l.color}`),l.textColor!==void 0&&s.push(`text-${l.textColor}`),s.join(" ")});function c(){return l.locale!==void 0?{...B.lang.date,...l.locale}:B.lang.date}function i(s){const n=new Date,e=s===!0?null:0;if(l.calendar==="persian"){const r=Hu(n);return{year:r.jy,month:r.jm,day:r.jd}}return{year:n.getFullYear(),month:n.getMonth()+1,day:n.getDate(),hour:e,minute:e,second:e,millisecond:e}}return{editable:t,tabindex:b,headerClass:m,getLocale:c,getCurrentDate:i}}const Ai={isoName:"en-US",nativeName:"English (US)",label:{clear:"Clear",ok:"OK",cancel:"Cancel",close:"Close",set:"Set",select:"Select",reset:"Reset",remove:"Remove",update:"Update",create:"Create",search:"Search",filter:"Filter",refresh:"Refresh",expand:l=>l?`Expand "${l}"`:"Expand",collapse:l=>l?`Collapse "${l}"`:"Collapse"},date:{days:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),daysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),firstDayOfWeek:0,format24h:!1,pluralDay:"days",prevMonth:"Previous month",nextMonth:"Next month",prevYear:"Previous year",nextYear:"Next year",today:"Today",prevRangeYears:l=>`Previous ${l} years`,nextRangeYears:l=>`Next ${l} years`},table:{noData:"No data available",noResults:"No matching records found",loading:"Loading...",selectedRecords:l=>l===1?"1 record selected.":(l===0?"No":l)+" records selected.",recordsPerPage:"Records per page:",allRows:"All",pagination:(l,B,t)=>l+"-"+B+" of "+t,columns:"Columns"},pagination:{first:"First page",prev:"Previous page",next:"Next page",last:"Last page"},editor:{url:"URL",bold:"Bold",italic:"Italic",strikethrough:"Strikethrough",underline:"Underline",unorderedList:"Unordered List",orderedList:"Ordered List",subscript:"Subscript",superscript:"Superscript",hyperlink:"Hyperlink",toggleFullscreen:"Toggle Fullscreen",quote:"Quote",left:"Left align",center:"Center align",right:"Right align",justify:"Justify align",print:"Print",outdent:"Decrease indentation",indent:"Increase indentation",removeFormat:"Remove formatting",formatting:"Formatting",fontSize:"Font Size",align:"Align",hr:"Insert Horizontal Rule",undo:"Undo",redo:"Redo",heading1:"Heading 1",heading2:"Heading 2",heading3:"Heading 3",heading4:"Heading 4",heading5:"Heading 5",heading6:"Heading 6",paragraph:"Paragraph",code:"Code",size1:"Very small",size2:"A bit small",size3:"Normal",size4:"Medium-large",size5:"Big",size6:"Very big",size7:"Maximum",defaultFont:"Default Font",viewSource:"View Source"},tree:{noNodes:"No nodes available",noResults:"No matching nodes found"}};function Go(){const l=Array.isArray(navigator.languages)===!0&&navigator.languages.length!==0?navigator.languages[0]:navigator.language;if(typeof l=="string")return l.split(/[-_]/).map((B,t)=>t===0?B.toLowerCase():t>1||B.length<4?B.toUpperCase():B[0].toUpperCase()+B.slice(1).toLowerCase()).join("-")}const tr=As({__qLang:{}},{getLocale:Go,set(l=Ai,B){const t={...l,rtl:l.rtl===!0,getLocale:Go};{if(t.set=tr.set,tr.__langConfig===void 0||tr.__langConfig.noHtmlAttrs!==!0){const b=document.documentElement;b.setAttribute("dir",t.rtl===!0?"rtl":"ltr"),b.setAttribute("lang",t.isoName)}Object.assign(tr.__qLang,t)}},install({$q:l,lang:B,ssrContext:t}){l.lang=tr.__qLang,tr.__langConfig=l.config.lang,this.__installed===!0?B!==void 0&&this.set(B):(this.props=new Proxy(this.__qLang,{get(){return Reflect.get(...arguments)},ownKeys(b){return Reflect.ownKeys(b).filter(m=>m!=="set"&&m!=="getLocale")}}),this.set(B||Ai))}}),$a=864e5,$u=36e5,Ei=6e4,es="YYYY-MM-DDTHH:mm:ss.SSSZ",ec=/\[((?:[^\]\\]|\\]|\\)*)\]|do|d{1,4}|Mo|M{1,4}|m{1,2}|wo|w{1,2}|Qo|Do|DDDo|D{1,4}|YY(?:YY)?|H{1,2}|h{1,2}|s{1,2}|S{1,3}|Z{1,2}|a{1,2}|[AQExX]/g,tc=/(\[[^\]]*\])|do|d{1,4}|Mo|M{1,4}|m{1,2}|wo|w{1,2}|Qo|Do|DDDo|D{1,4}|YY(?:YY)?|H{1,2}|h{1,2}|s{1,2}|S{1,3}|Z{1,2}|a{1,2}|[AQExX]|([.*+:?^,\s${}()|\\]+)/g,ui={};function rc(l,B){const t="("+B.days.join("|")+")",b=l+t;if(ui[b]!==void 0)return ui[b];const m="("+B.daysShort.join("|")+")",c="("+B.months.join("|")+")",i="("+B.monthsShort.join("|")+")",s={};let n=0;const e=l.replace(tc,u=>{switch(n++,u){case"YY":return s.YY=n,"(-?\\d{1,2})";case"YYYY":return s.YYYY=n,"(-?\\d{1,4})";case"M":return s.M=n,"(\\d{1,2})";case"Mo":return s.M=n++,"(\\d{1,2}(st|nd|rd|th))";case"MM":return s.M=n,"(\\d{2})";case"MMM":return s.MMM=n,i;case"MMMM":return s.MMMM=n,c;case"D":return s.D=n,"(\\d{1,2})";case"Do":return s.D=n++,"(\\d{1,2}(st|nd|rd|th))";case"DD":return s.D=n,"(\\d{2})";case"H":return s.H=n,"(\\d{1,2})";case"HH":return s.H=n,"(\\d{2})";case"h":return s.h=n,"(\\d{1,2})";case"hh":return s.h=n,"(\\d{2})";case"m":return s.m=n,"(\\d{1,2})";case"mm":return s.m=n,"(\\d{2})";case"s":return s.s=n,"(\\d{1,2})";case"ss":return s.s=n,"(\\d{2})";case"S":return s.S=n,"(\\d{1})";case"SS":return s.S=n,"(\\d{2})";case"SSS":return s.S=n,"(\\d{3})";case"A":return s.A=n,"(AM|PM)";case"a":return s.a=n,"(am|pm)";case"aa":return s.aa=n,"(a\\.m\\.|p\\.m\\.)";case"ddd":return m;case"dddd":return t;case"Q":case"d":case"E":return"(\\d{1})";case"do":return n++,"(\\d{1}(st|nd|rd|th))";case"Qo":return"(1st|2nd|3rd|4th)";case"DDD":case"DDDD":return"(\\d{1,3})";case"DDDo":return n++,"(\\d{1,3}(st|nd|rd|th))";case"w":return"(\\d{1,2})";case"wo":return n++,"(\\d{1,2}(st|nd|rd|th))";case"ww":return"(\\d{2})";case"Z":return s.Z=n,"(Z|[+-]\\d{2}:\\d{2})";case"ZZ":return s.ZZ=n,"(Z|[+-]\\d{2}\\d{2})";case"X":return s.X=n,"(-?\\d+)";case"x":return s.x=n,"(-?\\d{4,})";default:return n--,u[0]==="["&&(u=u.substring(1,u.length-1)),u.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}}),r={map:s,regex:new RegExp("^"+e)};return ui[b]=r,r}function ts(l,B){return l!==void 0?l:B!==void 0?B.date:Ai.date}function Jo(l,B=""){const t=l>0?"-":"+",b=Math.abs(l),m=Math.floor(b/60),c=b%60;return t+vt(m)+B+vt(c)}function nc(l,B,t){let b=l.getFullYear(),m=l.getMonth();const c=l.getDate();return B.year!==void 0&&(b+=t*B.year,delete B.year),B.month!==void 0&&(m+=t*B.month,delete B.month),l.setDate(1),l.setMonth(2),l.setFullYear(b),l.setMonth(m),l.setDate(Math.min(c,io(l))),B.date!==void 0&&(l.setDate(l.getDate()+t*B.date),delete B.date),l}function ic(l,B,t){const b=B.year!==void 0?B.year:l[`get${t}FullYear`](),m=B.month!==void 0?B.month-1:l[`get${t}Month`](),c=new Date(b,m+1,0).getDate(),i=Math.min(c,B.date!==void 0?B.date:l[`get${t}Date`]());return l[`set${t}Date`](1),l[`set${t}Month`](2),l[`set${t}FullYear`](b),l[`set${t}Month`](m),l[`set${t}Date`](i),delete B.year,delete B.month,delete B.date,l}function ro(l,B,t){const b=rs(B),m=new Date(l),c=b.year!==void 0||b.month!==void 0||b.date!==void 0?nc(m,b,t):m;for(const i in b){const s=kl(i);c[`set${s}`](c[`get${s}`]()+t*b[i])}return c}function rs(l){const B={...l};return l.years!==void 0&&(B.year=l.years,delete B.years),l.months!==void 0&&(B.month=l.months,delete B.months),l.days!==void 0&&(B.date=l.days,delete B.days),l.day!==void 0&&(B.date=l.day,delete B.day),l.hour!==void 0&&(B.hours=l.hour,delete B.hour),l.minute!==void 0&&(B.minutes=l.minute,delete B.minute),l.second!==void 0&&(B.seconds=l.second,delete B.second),l.millisecond!==void 0&&(B.milliseconds=l.millisecond,delete B.millisecond),B}function ns(l,B,t){const b=rs(B),m=t===!0?"UTC":"",c=new Date(l),i=b.year!==void 0||b.month!==void 0||b.date!==void 0?ic(c,b,m):c;for(const s in b){const n=s.charAt(0).toUpperCase()+s.slice(1);i[`set${m}${n}`](b[s])}return i}function oc(l,B,t){const b=is(l,B,t),m=new Date(b.year,b.month===null?null:b.month-1,b.day===null?1:b.day,b.hour,b.minute,b.second,b.millisecond),c=m.getTimezoneOffset();return b.timezoneOffset===null||b.timezoneOffset===c?m:ro(m,{minutes:b.timezoneOffset-c},1)}function is(l,B,t,b,m){const c={year:null,month:null,day:null,hour:null,minute:null,second:null,millisecond:null,timezoneOffset:null,dateHash:null,timeHash:null};if(m!==void 0&&Object.assign(c,m),l==null||l===""||typeof l!="string")return c;B===void 0&&(B=es);const i=ts(t,tr.props),s=i.months,n=i.monthsShort,{regex:e,map:r}=rc(B,i),u=l.match(e);if(u===null)return c;let a="";if(r.X!==void 0||r.x!==void 0){const o=parseInt(u[r.X!==void 0?r.X:r.x],10);if(isNaN(o)===!0||o<0)return c;const f=new Date(o*(r.X!==void 0?1e3:1));c.year=f.getFullYear(),c.month=f.getMonth()+1,c.day=f.getDate(),c.hour=f.getHours(),c.minute=f.getMinutes(),c.second=f.getSeconds(),c.millisecond=f.getMilliseconds()}else{if(r.YYYY!==void 0)c.year=parseInt(u[r.YYYY],10);else if(r.YY!==void 0){const o=parseInt(u[r.YY],10);c.year=o<0?o:2e3+o}if(r.M!==void 0){if(c.month=parseInt(u[r.M],10),c.month<1||c.month>12)return c}else r.MMM!==void 0?c.month=n.indexOf(u[r.MMM])+1:r.MMMM!==void 0&&(c.month=s.indexOf(u[r.MMMM])+1);if(r.D!==void 0){if(c.day=parseInt(u[r.D],10),c.year===null||c.month===null||c.day<1)return c;const o=b!=="persian"?new Date(c.year,c.month,0).getDate():kn(c.year,c.month);if(c.day>o)return c}r.H!==void 0?c.hour=parseInt(u[r.H],10)%24:r.h!==void 0&&(c.hour=parseInt(u[r.h],10)%12,(r.A&&u[r.A]==="PM"||r.a&&u[r.a]==="pm"||r.aa&&u[r.aa]==="p.m.")&&(c.hour+=12),c.hour=c.hour%24),r.m!==void 0&&(c.minute=parseInt(u[r.m],10)%60),r.s!==void 0&&(c.second=parseInt(u[r.s],10)%60),r.S!==void 0&&(c.millisecond=parseInt(u[r.S],10)*10**(3-u[r.S].length)),(r.Z!==void 0||r.ZZ!==void 0)&&(a=r.Z!==void 0?u[r.Z].replace(":",""):u[r.ZZ],c.timezoneOffset=(a[0]==="+"?-1:1)*(60*a.slice(1,3)+1*a.slice(3,5)))}return c.dateHash=vt(c.year,4)+"/"+vt(c.month)+"/"+vt(c.day),c.timeHash=vt(c.hour)+":"+vt(c.minute)+":"+vt(c.second)+a,c}function ac(l){return typeof l=="number"?!0:isNaN(Date.parse(l))===!1}function sc(l,B){return ns(new Date,l,B)}function lc(l){const B=new Date(l).getDay();return B===0?7:B}function _n(l){const B=new Date(l.getFullYear(),l.getMonth(),l.getDate());B.setDate(B.getDate()-(B.getDay()+6)%7+3);const t=new Date(B.getFullYear(),0,4);t.setDate(t.getDate()-(t.getDay()+6)%7+3);const b=B.getTimezoneOffset()-t.getTimezoneOffset();B.setHours(B.getHours()-b);const m=(B-t)/($a*7);return 1+Math.floor(m)}function uc(l){return l.getFullYear()*1e4+l.getMonth()*100+l.getDate()}function ci(l,B){const t=new Date(l);return B===!0?uc(t):t.getTime()}function cc(l,B,t,b={}){const m=ci(B,b.onlyDate),c=ci(t,b.onlyDate),i=ci(l,b.onlyDate);return(i>m||b.inclusiveFrom===!0&&i===m)&&(i<c||b.inclusiveTo===!0&&i===c)}function dc(l,B){return ro(l,B,1)}function fc(l,B){return ro(l,B,-1)}function Ht(l,B,t){const b=new Date(l),m=`set${t===!0?"UTC":""}`;switch(B){case"year":case"years":b[`${m}Month`](0);case"month":case"months":b[`${m}Date`](1);case"day":case"days":case"date":b[`${m}Hours`](0);case"hour":case"hours":b[`${m}Minutes`](0);case"minute":case"minutes":b[`${m}Seconds`](0);case"second":case"seconds":b[`${m}Milliseconds`](0)}return b}function hc(l,B,t){const b=new Date(l),m=`set${t===!0?"UTC":""}`;switch(B){case"year":case"years":b[`${m}Month`](11);case"month":case"months":b[`${m}Date`](io(b));case"day":case"days":case"date":b[`${m}Hours`](23);case"hour":case"hours":b[`${m}Minutes`](59);case"minute":case"minutes":b[`${m}Seconds`](59);case"second":case"seconds":b[`${m}Milliseconds`](999)}return b}function pc(l){let B=new Date(l);return Array.prototype.slice.call(arguments,1).forEach(t=>{B=Math.max(B,new Date(t))}),B}function mc(l){let B=new Date(l);return Array.prototype.slice.call(arguments,1).forEach(t=>{B=Math.min(B,new Date(t))}),B}function mn(l,B,t){return(l.getTime()-l.getTimezoneOffset()*Ei-(B.getTime()-B.getTimezoneOffset()*Ei))/t}function no(l,B,t="days"){const b=new Date(l),m=new Date(B);switch(t){case"years":case"year":return b.getFullYear()-m.getFullYear();case"months":case"month":return(b.getFullYear()-m.getFullYear())*12+b.getMonth()-m.getMonth();case"days":case"day":case"date":return mn(Ht(b,"day"),Ht(m,"day"),$a);case"hours":case"hour":return mn(Ht(b,"hour"),Ht(m,"hour"),$u);case"minutes":case"minute":return mn(Ht(b,"minute"),Ht(m,"minute"),Ei);case"seconds":case"second":return mn(Ht(b,"second"),Ht(m,"second"),1e3)}}function Cn(l){return no(l,Ht(l,"year"),"days")+1}function gc(l){return Fn(l)===!0?"date":typeof l=="number"?"number":"string"}function bc(l,B,t){const b=new Date(l);if(B){const m=new Date(B);if(b<m)return m}if(t){const m=new Date(t);if(b>m)return m}return b}function vc(l,B,t){const b=new Date(l),m=new Date(B);if(t===void 0)return b.getTime()===m.getTime();switch(t){case"second":case"seconds":if(b.getSeconds()!==m.getSeconds())return!1;case"minute":case"minutes":if(b.getMinutes()!==m.getMinutes())return!1;case"hour":case"hours":if(b.getHours()!==m.getHours())return!1;case"day":case"days":case"date":if(b.getDate()!==m.getDate())return!1;case"month":case"months":if(b.getMonth()!==m.getMonth())return!1;case"year":case"years":if(b.getFullYear()!==m.getFullYear())return!1;break;default:throw new Error(`date isSameDate unknown unit ${t}`)}return!0}function io(l){return new Date(l.getFullYear(),l.getMonth()+1,0).getDate()}function Cr(l){if(l>=11&&l<=13)return`${l}th`;switch(l%10){case 1:return`${l}st`;case 2:return`${l}nd`;case 3:return`${l}rd`}return`${l}th`}const Zo={YY(l,B,t){const b=this.YYYY(l,B,t)%100;return b>=0?vt(b):"-"+vt(Math.abs(b))},YYYY(l,B,t){return t??l.getFullYear()},M(l){return l.getMonth()+1},Mo(l){return Cr(l.getMonth()+1)},MM(l){return vt(l.getMonth()+1)},MMM(l,B){return B.monthsShort[l.getMonth()]},MMMM(l,B){return B.months[l.getMonth()]},Q(l){return Math.ceil((l.getMonth()+1)/3)},Qo(l){return Cr(this.Q(l))},D(l){return l.getDate()},Do(l){return Cr(l.getDate())},DD(l){return vt(l.getDate())},DDD(l){return Cn(l)},DDDo(l){return Cr(Cn(l))},DDDD(l){return vt(Cn(l),3)},d(l){return l.getDay()},do(l){return Cr(l.getDay())},dd(l,B){return B.days[l.getDay()].slice(0,2)},ddd(l,B){return B.daysShort[l.getDay()]},dddd(l,B){return B.days[l.getDay()]},E(l){return l.getDay()||7},w(l){return _n(l)},wo(l){return Cr(_n(l))},ww(l){return vt(_n(l))},H(l){return l.getHours()},HH(l){return vt(l.getHours())},h(l){const B=l.getHours();return B===0?12:B>12?B%12:B},hh(l){return vt(this.h(l))},m(l){return l.getMinutes()},mm(l){return vt(l.getMinutes())},s(l){return l.getSeconds()},ss(l){return vt(l.getSeconds())},S(l){return Math.floor(l.getMilliseconds()/100)},SS(l){return vt(Math.floor(l.getMilliseconds()/10))},SSS(l){return vt(l.getMilliseconds(),3)},A(l){return l.getHours()<12?"AM":"PM"},a(l){return l.getHours()<12?"am":"pm"},aa(l){return l.getHours()<12?"a.m.":"p.m."},Z(l,B,t,b){const m=b??l.getTimezoneOffset();return Jo(m,":")},ZZ(l,B,t,b){const m=b??l.getTimezoneOffset();return Jo(m)},X(l){return Math.floor(l.getTime()/1e3)},x(l){return l.getTime()}};function os(l,B,t,b,m){if(l!==0&&!l||l===1/0||l===-1/0)return;const c=new Date(l);if(isNaN(c))return;B===void 0&&(B=es);const i=ts(t,tr.props);return B.replace(ec,(s,n)=>s in Zo?Zo[s](c,i,b,m):n===void 0?s:n.split("\\]").join("]"))}function yc(l){return Fn(l)===!0?new Date(l.getTime()):l}const as={isValid:ac,extractDate:oc,buildDate:sc,getDayOfWeek:lc,getWeekOfYear:_n,isBetweenDates:cc,addToDate:dc,subtractFromDate:fc,adjustDate:ns,startOfDate:Ht,endOfDate:hc,getMaxDate:pc,getMinDate:mc,getDateDiff:no,getDayOfYear:Cn,inferDateFormat:gc,getDateBetween:bc,isSameDate:vc,daysInMonth:io,formatDate:os,clone:yc},Qt=20,wc=["Calendar","Years","Months"],$o=l=>wc.includes(l),di=l=>/^-?[\d]+\/[0-1]\d$/.test(l),Ar=" — ";function er(l){return l.year+"/"+vt(l.month)}const ss=$e({name:"QDate",props:{...Xo,...Vn,...Ot,modelValue:{required:!0,validator:l=>typeof l=="string"||Array.isArray(l)===!0||Object(l)===l||l===null},multiple:Boolean,range:Boolean,title:String,subtitle:String,mask:{...Xo.mask,default:"YYYY/MM/DD"},defaultYearMonth:{type:String,validator:di},yearsInMonthView:Boolean,events:[Array,Function],eventColor:[String,Function],emitImmediately:Boolean,options:[Array,Function],navigationMinYearMonth:{type:String,validator:di},navigationMaxYearMonth:{type:String,validator:di},noUnset:Boolean,firstDayOfWeek:[String,Number],todayBtn:Boolean,minimal:Boolean,defaultView:{type:String,default:"Calendar",validator:$o}},emits:[...Ju,"rangeStart","rangeEnd","navigation"],setup(l,{slots:B,emit:t}){const{proxy:b}=v.getCurrentInstance(),{$q:m}=b,c=Ft(l,m),{getCache:i}=Wu(),{tabindex:s,headerClass:n,getLocale:e,getCurrentDate:r}=Zu(l,m);let u;const a=ll(l),o=ya(a),f=v.ref(null),h=v.ref(Ue()),d=v.ref(e()),g=v.computed(()=>Ue()),p=v.computed(()=>e()),k=v.computed(()=>r()),C=v.ref(Le(h.value,d.value)),T=v.ref(l.defaultView),D=v.computed(()=>m.lang.rtl===!0?"right":"left"),V=v.ref(D.value),P=v.ref(D.value),N=C.value.year,q=v.ref(N-N%Qt-(N<0?Qt:0)),W=v.ref(null),L=v.computed(()=>{const re=l.landscape===!0?"landscape":"portrait";return`q-date q-date--${re} q-date--${re}-${l.minimal===!0?"minimal":"standard"}`+(c.value===!0?" q-date--dark q-dark":"")+(l.bordered===!0?" q-date--bordered":"")+(l.square===!0?" q-date--square no-border-radius":"")+(l.flat===!0?" q-date--flat no-shadow":"")+(l.disable===!0?" disabled":l.readonly===!0?" q-date--readonly":"")}),A=v.computed(()=>l.color||"primary"),M=v.computed(()=>l.textColor||"white"),_=v.computed(()=>l.emitImmediately===!0&&l.multiple!==!0&&l.range!==!0),y=v.computed(()=>Array.isArray(l.modelValue)===!0?l.modelValue:l.modelValue!==null&&l.modelValue!==void 0?[l.modelValue]:[]),x=v.computed(()=>y.value.filter(re=>typeof re=="string").map(re=>Ne(re,h.value,d.value)).filter(re=>re.dateHash!==null&&re.day!==null&&re.month!==null&&re.year!==null)),w=v.computed(()=>{const re=X=>Ne(X,h.value,d.value);return y.value.filter(X=>Ka(X)===!0&&X.from!==void 0&&X.to!==void 0).map(X=>({from:re(X.from),to:re(X.to)})).filter(X=>X.from.dateHash!==null&&X.to.dateHash!==null&&X.from.dateHash<X.to.dateHash)}),S=v.computed(()=>l.calendar!=="persian"?re=>new Date(re.year,re.month-1,re.day):re=>{const X=Ko(re.year,re.month,re.day);return new Date(X.gy,X.gm-1,X.gd)}),E=v.computed(()=>l.calendar==="persian"?$t:(re,X,ne)=>os(new Date(re.year,re.month-1,re.day,re.hour,re.minute,re.second,re.millisecond),X===void 0?h.value:X,ne===void 0?d.value:ne,re.year,re.timezoneOffset)),O=v.computed(()=>x.value.length+w.value.reduce((re,X)=>re+1+no(S.value(X.to),S.value(X.from)),0)),R=v.computed(()=>{if(l.title!==void 0&&l.title!==null&&l.title.length!==0)return l.title;if(W.value!==null){const ne=W.value.init,fe=S.value(ne);return d.value.daysShort[fe.getDay()]+", "+d.value.monthsShort[ne.month-1]+" "+ne.day+Ar+"?"}if(O.value===0)return Ar;if(O.value>1)return`${O.value} ${d.value.pluralDay}`;const re=x.value[0],X=S.value(re);return isNaN(X.valueOf())===!0?Ar:d.value.headerTitle!==void 0?d.value.headerTitle(X,re):d.value.daysShort[X.getDay()]+", "+d.value.monthsShort[re.month-1]+" "+re.day}),z=v.computed(()=>x.value.concat(w.value.map(X=>X.from)).sort((X,ne)=>X.year-ne.year||X.month-ne.month)[0]),U=v.computed(()=>x.value.concat(w.value.map(X=>X.to)).sort((X,ne)=>ne.year-X.year||ne.month-X.month)[0]),Q=v.computed(()=>{if(l.subtitle!==void 0&&l.subtitle!==null&&l.subtitle.length!==0)return l.subtitle;if(O.value===0)return Ar;if(O.value>1){const re=z.value,X=U.value,ne=d.value.monthsShort;return ne[re.month-1]+(re.year!==X.year?" "+re.year+Ar+ne[X.month-1]+" ":re.month!==X.month?Ar+ne[X.month-1]:"")+" "+X.year}return x.value[0].year}),j=v.computed(()=>{const re=[m.iconSet.datetime.arrowLeft,m.iconSet.datetime.arrowRight];return m.lang.rtl===!0?re.reverse():re}),Y=v.computed(()=>l.firstDayOfWeek!==void 0?Number(l.firstDayOfWeek):d.value.firstDayOfWeek),F=v.computed(()=>{const re=d.value.daysShort,X=Y.value;return X>0?re.slice(X,7).concat(re.slice(0,X)):re}),I=v.computed(()=>{const re=C.value;return l.calendar!=="persian"?new Date(re.year,re.month,0).getDate():kn(re.year,re.month)}),H=v.computed(()=>typeof l.eventColor=="function"?l.eventColor:()=>l.eventColor),K=v.computed(()=>{if(l.navigationMinYearMonth===void 0)return null;const re=l.navigationMinYearMonth.split("/");return{year:parseInt(re[0],10),month:parseInt(re[1],10)}}),ee=v.computed(()=>{if(l.navigationMaxYearMonth===void 0)return null;const re=l.navigationMaxYearMonth.split("/");return{year:parseInt(re[0],10),month:parseInt(re[1],10)}}),G=v.computed(()=>{const re={month:{prev:!0,next:!0},year:{prev:!0,next:!0}};return K.value!==null&&K.value.year>=C.value.year&&(re.year.prev=!1,K.value.year===C.value.year&&K.value.month>=C.value.month&&(re.month.prev=!1)),ee.value!==null&&ee.value.year<=C.value.year&&(re.year.next=!1,ee.value.year===C.value.year&&ee.value.month<=C.value.month&&(re.month.next=!1)),re}),te=v.computed(()=>{const re={};return x.value.forEach(X=>{const ne=er(X);re[ne]===void 0&&(re[ne]=[]),re[ne].push(X.day)}),re}),ce=v.computed(()=>{const re={};return w.value.forEach(X=>{const ne=er(X.from),fe=er(X.to);if(re[ne]===void 0&&(re[ne]=[]),re[ne].push({from:X.from.day,to:ne===fe?X.to.day:void 0,range:X}),ne<fe){let be;const{year:Me,month:ve}=X.from,_e=ve<12?{year:Me,month:ve+1}:{year:Me+1,month:1};for(;(be=er(_e))<=fe;)re[be]===void 0&&(re[be]=[]),re[be].push({from:void 0,to:be===fe?X.to.day:void 0,range:X}),_e.month++,_e.month>12&&(_e.year++,_e.month=1)}}),re}),ue=v.computed(()=>{if(W.value===null)return;const{init:re,initHash:X,final:ne,finalHash:fe}=W.value,[be,Me]=X<=fe?[re,ne]:[ne,re],ve=er(be),_e=er(Me);if(ve!==J.value&&_e!==J.value)return;const Be={};return ve===J.value?(Be.from=be.day,Be.includeFrom=!0):Be.from=1,_e===J.value?(Be.to=Me.day,Be.includeTo=!0):Be.to=I.value,Be}),J=v.computed(()=>er(C.value)),ae=v.computed(()=>{const re={};if(l.options===void 0){for(let ne=1;ne<=I.value;ne++)re[ne]=!0;return re}const X=typeof l.options=="function"?l.options:ne=>l.options.includes(ne);for(let ne=1;ne<=I.value;ne++){const fe=J.value+"/"+vt(ne);re[ne]=X(fe)}return re}),se=v.computed(()=>{const re={};if(l.events===void 0)for(let X=1;X<=I.value;X++)re[X]=!1;else{const X=typeof l.events=="function"?l.events:ne=>l.events.includes(ne);for(let ne=1;ne<=I.value;ne++){const fe=J.value+"/"+vt(ne);re[ne]=X(fe)===!0&&H.value(fe)}}return re}),pe=v.computed(()=>{let re,X;const{year:ne,month:fe}=C.value;if(l.calendar!=="persian")re=new Date(ne,fe-1,1),X=new Date(ne,fe-1,0).getDate();else{const be=Ko(ne,fe,1);re=new Date(be.gy,be.gm-1,be.gd);let Me=fe-1,ve=ne;Me===0&&(Me=12,ve--),X=kn(ve,Me)}return{days:re.getDay()-Y.value-1,endDay:X}}),$=v.computed(()=>{const re=[],{days:X,endDay:ne}=pe.value,fe=X<0?X+7:X;if(fe<6)for(let ve=ne-fe;ve<=ne;ve++)re.push({i:ve,fill:!0});const be=re.length;for(let ve=1;ve<=I.value;ve++){const _e={i:ve,event:se.value[ve],classes:[]};ae.value[ve]===!0&&(_e.in=!0,_e.flat=!0),re.push(_e)}if(te.value[J.value]!==void 0&&te.value[J.value].forEach(ve=>{const _e=be+ve-1;Object.assign(re[_e],{selected:!0,unelevated:!0,flat:!1,color:A.value,textColor:M.value})}),ce.value[J.value]!==void 0&&ce.value[J.value].forEach(ve=>{if(ve.from!==void 0){const _e=be+ve.from-1,Be=be+(ve.to||I.value)-1;for(let ze=_e;ze<=Be;ze++)Object.assign(re[ze],{range:ve.range,unelevated:!0,color:A.value,textColor:M.value});Object.assign(re[_e],{rangeFrom:!0,flat:!1}),ve.to!==void 0&&Object.assign(re[Be],{rangeTo:!0,flat:!1})}else if(ve.to!==void 0){const _e=be+ve.to-1;for(let Be=be;Be<=_e;Be++)Object.assign(re[Be],{range:ve.range,unelevated:!0,color:A.value,textColor:M.value});Object.assign(re[_e],{flat:!1,rangeTo:!0})}else{const _e=be+I.value-1;for(let Be=be;Be<=_e;Be++)Object.assign(re[Be],{range:ve.range,unelevated:!0,color:A.value,textColor:M.value})}}),ue.value!==void 0){const ve=be+ue.value.from-1,_e=be+ue.value.to-1;for(let Be=ve;Be<=_e;Be++)re[Be].color=A.value,re[Be].editRange=!0;ue.value.includeFrom===!0&&(re[ve].editRangeFrom=!0),ue.value.includeTo===!0&&(re[_e].editRangeTo=!0)}C.value.year===k.value.year&&C.value.month===k.value.month&&(re[be+k.value.day-1].today=!0);const Me=re.length%7;if(Me>0){const ve=7-Me;for(let _e=1;_e<=ve;_e++)re.push({i:_e,fill:!0})}return re.forEach(ve=>{let _e="q-date__calendar-item ";ve.fill===!0?_e+="q-date__calendar-item--fill":(_e+=`q-date__calendar-item--${ve.in===!0?"in":"out"}`,ve.range!==void 0&&(_e+=` q-date__range${ve.rangeTo===!0?"-to":ve.rangeFrom===!0?"-from":""}`),ve.editRange===!0&&(_e+=` q-date__edit-range${ve.editRangeFrom===!0?"-from":""}${ve.editRangeTo===!0?"-to":""}`),(ve.range!==void 0||ve.editRange===!0)&&(_e+=` text-${ve.color}`)),ve.classes=_e}),re}),ie=v.computed(()=>l.disable===!0?{"aria-disabled":"true"}:{});v.watch(()=>l.modelValue,re=>{if(u===JSON.stringify(re))u=0;else{const X=Le(h.value,d.value);et(X.year,X.month,X)}}),v.watch(T,()=>{f.value!==null&&b.$el.contains(document.activeElement)===!0&&f.value.focus()}),v.watch(()=>C.value.year+"|"+C.value.month,()=>{t("navigation",{year:C.value.year,month:C.value.month})}),v.watch(g,re=>{xe(re,d.value,"mask"),h.value=re}),v.watch(p,re=>{xe(h.value,re,"locale"),d.value=re});function oe(re){u=JSON.stringify(re)}function le(){const{year:re,month:X,day:ne}=k.value,fe={...C.value,year:re,month:X,day:ne},be=te.value[er(fe)];(be===void 0||be.includes(fe.day)===!1)&&st(fe),Ae(fe.year,fe.month)}function ge(re){$o(re)===!0&&(T.value=re)}function Ce(re,X){["month","year"].includes(re)&&(re==="month"?Fe:ke)(X===!0?-1:1)}function Ae(re,X){T.value="Calendar",et(re,X)}function Te(re,X){if(l.range===!1||!re){W.value=null;return}const ne=Object.assign({...C.value},re),fe=X!==void 0?Object.assign({...C.value},X):ne;W.value={init:ne,initHash:$t(ne),final:fe,finalHash:$t(fe)},Ae(ne.year,ne.month)}function Ue(){return l.calendar==="persian"?"YYYY/MM/DD":l.mask}function Ne(re,X,ne){return is(re,X,ne,l.calendar,{hour:0,minute:0,second:0,millisecond:0})}function Le(re,X){const ne=Array.isArray(l.modelValue)===!0?l.modelValue:l.modelValue?[l.modelValue]:[];if(ne.length===0)return qe();const fe=ne[ne.length-1],be=Ne(fe.from!==void 0?fe.from:fe,re,X);return be.dateHash===null?qe():be}function qe(){let re,X;if(l.defaultYearMonth!==void 0){const ne=l.defaultYearMonth.split("/");re=parseInt(ne[0],10),X=parseInt(ne[1],10)}else{const ne=k.value!==void 0?k.value:r();re=ne.year,X=ne.month}return{year:re,month:X,day:1,hour:0,minute:0,second:0,millisecond:0,dateHash:re+"/"+vt(X)+"/01"}}function Fe(re){let X=C.value.year,ne=Number(C.value.month)+re;ne===13?(ne=1,X++):ne===0&&(ne=12,X--),et(X,ne),_.value===!0&&nt("month")}function ke(re){const X=Number(C.value.year)+re;et(X,C.value.month),_.value===!0&&nt("year")}function De(re){et(re,C.value.month),T.value=l.defaultView==="Years"?"Months":"Calendar",_.value===!0&&nt("year")}function We(re){et(C.value.year,re),T.value="Calendar",_.value===!0&&nt("month")}function Ve(re,X){(te.value[X]?.includes(re.day)===!0?me:st)(re)}function Ge(re){return{year:re.year,month:re.month,day:re.day}}function et(re,X,ne){if(K.value!==null&&re<=K.value.year&&((X<K.value.month||re<K.value.year)&&(X=K.value.month),re=K.value.year),ee.value!==null&&re>=ee.value.year&&((X>ee.value.month||re>ee.value.year)&&(X=ee.value.month),re=ee.value.year),ne!==void 0){const{hour:be,minute:Me,second:ve,millisecond:_e,timezoneOffset:Be,timeHash:ze}=ne;Object.assign(C.value,{hour:be,minute:Me,second:ve,millisecond:_e,timezoneOffset:Be,timeHash:ze})}const fe=re+"/"+vt(X)+"/01";fe!==C.value.dateHash&&(V.value=C.value.dateHash<fe==(m.lang.rtl!==!0)?"left":"right",re!==C.value.year&&(P.value=V.value),v.nextTick(()=>{q.value=re-re%Qt-(re<0?Qt:0),Object.assign(C.value,{year:re,month:X,day:1,dateHash:fe})}))}function He(re,X,ne){const fe=re!==null&&re.length===1&&l.multiple===!1?re[0]:re,{reason:be,details:Me}=tt(X,ne);oe(fe),t("update:modelValue",fe,be,Me)}function nt(re){const X=x.value[0]!==void 0&&x.value[0].dateHash!==null?{...x.value[0]}:{...C.value};v.nextTick(()=>{X.year=C.value.year,X.month=C.value.month;const ne=l.calendar!=="persian"?new Date(X.year,X.month,0).getDate():kn(X.year,X.month);X.day=Math.min(Math.max(1,X.day),ne);const fe=Ye(X),{details:be}=tt("",X);oe(fe),t("update:modelValue",fe,re,be)})}function tt(re,X){return X.from!==void 0?{reason:`${re}-range`,details:{...Ge(X.target),from:Ge(X.from),to:Ge(X.to)}}:{reason:`${re}-day`,details:Ge(X)}}function Ye(re,X,ne){return re.from!==void 0?{from:E.value(re.from,X,ne),to:E.value(re.to,X,ne)}:E.value(re,X,ne)}function st(re){let X;if(l.multiple===!0)if(re.from!==void 0){const ne=$t(re.from),fe=$t(re.to),be=x.value.filter(ve=>ve.dateHash<ne||ve.dateHash>fe),Me=w.value.filter(({from:ve,to:_e})=>_e.dateHash<ne||ve.dateHash>fe);X=be.concat(Me).concat(re).map(ve=>Ye(ve))}else{const ne=y.value.slice();ne.push(Ye(re)),X=ne}else X=Ye(re);He(X,"add",re)}function me(re){if(l.noUnset===!0)return;let X=null;if(l.multiple===!0&&Array.isArray(l.modelValue)===!0){const ne=Ye(re);re.from!==void 0?X=l.modelValue.filter(fe=>fe.from!==void 0?fe.from!==ne.from&&fe.to!==ne.to:!0):X=l.modelValue.filter(fe=>fe!==ne),X.length===0&&(X=null)}He(X,"remove",re)}function xe(re,X,ne){const fe=x.value.concat(w.value).map(Me=>Ye(Me,re,X)).filter(Me=>Me.from!==void 0?Me.from.dateHash!==null&&Me.to.dateHash!==null:Me.dateHash!==null),be=(l.multiple===!0?fe:fe[0])||null;oe(be),t("update:modelValue",be,ne)}function Re(){if(l.minimal!==!0)return v.h("div",{class:"q-date__header "+n.value},[v.h("div",{class:"relative-position"},[v.h(v.Transition,{name:"q-transition--fade"},()=>v.h("div",{key:"h-yr-"+Q.value,class:"q-date__header-subtitle q-date__header-link "+(T.value==="Years"?"q-date__header-link--active":"cursor-pointer"),tabindex:s.value,...i("vY",{onClick(){T.value="Years"},onKeyup(re){re.keyCode===13&&(T.value="Years")}})},[Q.value]))]),v.h("div",{class:"q-date__header-title relative-position flex no-wrap"},[v.h("div",{class:"relative-position col"},[v.h(v.Transition,{name:"q-transition--fade"},()=>v.h("div",{key:"h-sub"+R.value,class:"q-date__header-title-label q-date__header-link "+(T.value==="Calendar"?"q-date__header-link--active":"cursor-pointer"),tabindex:s.value,...i("vC",{onClick(){T.value="Calendar"},onKeyup(re){re.keyCode===13&&(T.value="Calendar")}})},[R.value]))]),l.todayBtn===!0?v.h(at,{class:"q-date__header-today self-start",icon:m.iconSet.datetime.today,"aria-label":m.lang.date.today,flat:!0,size:"sm",round:!0,tabindex:s.value,onClick:le}):null])])}function Oe({label:re,type:X,key:ne,dir:fe,goTo:be,boundaries:Me,cls:ve}){return[v.h("div",{class:"row items-center q-date__arrow"},[v.h(at,{round:!0,dense:!0,size:"sm",flat:!0,icon:j.value[0],"aria-label":X==="Years"?m.lang.date.prevYear:m.lang.date.prevMonth,tabindex:s.value,disable:Me.prev===!1,...i("go-#"+X,{onClick(){be(-1)}})})]),v.h("div",{class:"relative-position overflow-hidden flex flex-center"+ve},[v.h(v.Transition,{name:"q-transition--jump-"+fe},()=>v.h("div",{key:ne},[v.h(at,{flat:!0,dense:!0,noCaps:!0,label:re,tabindex:s.value,...i("view#"+X,{onClick:()=>{T.value=X}})})]))]),v.h("div",{class:"row items-center q-date__arrow"},[v.h(at,{round:!0,dense:!0,size:"sm",flat:!0,icon:j.value[1],"aria-label":X==="Years"?m.lang.date.nextYear:m.lang.date.nextMonth,tabindex:s.value,disable:Me.next===!1,...i("go+#"+X,{onClick(){be(1)}})})])]}const Ee={Calendar:()=>[v.h("div",{key:"calendar-view",class:"q-date__view q-date__calendar"},[v.h("div",{class:"q-date__navigation row items-center no-wrap"},Oe({label:d.value.months[C.value.month-1],type:"Months",key:C.value.month,dir:V.value,goTo:Fe,boundaries:G.value.month,cls:" col"}).concat(Oe({label:C.value.year,type:"Years",key:C.value.year,dir:P.value,goTo:ke,boundaries:G.value.year,cls:""}))),v.h("div",{class:"q-date__calendar-weekdays row items-center no-wrap"},F.value.map(re=>v.h("div",{class:"q-date__calendar-item"},[v.h("div",re)]))),v.h("div",{class:"q-date__calendar-days-container relative-position overflow-hidden"},[v.h(v.Transition,{name:"q-transition--slide-"+V.value},()=>v.h("div",{key:J.value,class:"q-date__calendar-days fit"},$.value.map(re=>v.h("div",{class:re.classes},[re.in===!0?v.h(at,{class:re.today===!0?"q-date__today":"",dense:!0,flat:re.flat,unelevated:re.unelevated,color:re.color,textColor:re.textColor,label:re.i,tabindex:s.value,...i("day#"+re.i,{onClick:()=>{Qe(re.i)},onMouseover:()=>{Ke(re.i)}})},re.event!==!1?()=>v.h("div",{class:"q-date__event bg-"+re.event}):null):v.h("div",""+re.i)]))))])])],Months(){const re=C.value.year===k.value.year,X=fe=>K.value!==null&&C.value.year===K.value.year&&K.value.month>fe||ee.value!==null&&C.value.year===ee.value.year&&ee.value.month<fe,ne=d.value.monthsShort.map((fe,be)=>{const Me=C.value.month===be+1;return v.h("div",{class:"q-date__months-item flex flex-center"},[v.h(at,{class:re===!0&&k.value.month===be+1?"q-date__today":null,flat:Me!==!0,label:fe,unelevated:Me,color:Me===!0?A.value:null,textColor:Me===!0?M.value:null,tabindex:s.value,disable:X(be+1),...i("month#"+be,{onClick:()=>{We(be+1)}})})])});return l.yearsInMonthView===!0&&ne.unshift(v.h("div",{class:"row no-wrap full-width"},[Oe({label:C.value.year,type:"Years",key:C.value.year,dir:P.value,goTo:ke,boundaries:G.value.year,cls:" col"})])),v.h("div",{key:"months-view",class:"q-date__view q-date__months flex flex-center"},ne)},Years(){const re=q.value,X=re+Qt,ne=[],fe=be=>K.value!==null&&K.value.year>be||ee.value!==null&&ee.value.year<be;for(let be=re;be<=X;be++){const Me=C.value.year===be;ne.push(v.h("div",{class:"q-date__years-item flex flex-center"},[v.h(at,{key:"yr"+be,class:k.value.year===be?"q-date__today":null,flat:!Me,label:be,dense:!0,unelevated:Me,color:Me===!0?A.value:null,textColor:Me===!0?M.value:null,tabindex:s.value,disable:fe(be),...i("yr#"+be,{onClick:()=>{De(be)}})})]))}return v.h("div",{class:"q-date__view q-date__years flex flex-center"},[v.h("div",{class:"col-auto"},[v.h(at,{round:!0,dense:!0,flat:!0,icon:j.value[0],"aria-label":m.lang.date.prevRangeYears(Qt),tabindex:s.value,disable:fe(re),...i("y-",{onClick:()=>{q.value-=Qt}})})]),v.h("div",{class:"q-date__years-content col self-stretch row items-center"},ne),v.h("div",{class:"col-auto"},[v.h(at,{round:!0,dense:!0,flat:!0,icon:j.value[1],"aria-label":m.lang.date.nextRangeYears(Qt),tabindex:s.value,disable:fe(X),...i("y+",{onClick:()=>{q.value+=Qt}})})])])}};function Qe(re){const X={...C.value,day:re};if(l.range===!1){Ve(X,J.value);return}if(W.value===null){const ne=$.value.find(be=>be.fill!==!0&&be.i===re);if(l.noUnset!==!0&&ne.range!==void 0){me({target:X,from:ne.range.from,to:ne.range.to});return}if(ne.selected===!0){me(X);return}const fe=$t(X);W.value={init:X,initHash:fe,final:X,finalHash:fe},t("rangeStart",Ge(X))}else{const ne=W.value.initHash,fe=$t(X),be=ne<=fe?{from:W.value.init,to:X}:{from:X,to:W.value.init};W.value=null,st(ne===fe?X:{target:X,...be}),t("rangeEnd",{from:Ge(be.from),to:Ge(be.to)})}}function Ke(re){if(W.value!==null){const X={...C.value,day:re};Object.assign(W.value,{final:X,finalHash:$t(X)})}}return Object.assign(b,{setToday:le,setView:ge,offsetCalendar:Ce,setCalendarTo:Ae,setEditingRange:Te}),()=>{const re=[v.h("div",{class:"q-date__content col relative-position"},[v.h(v.Transition,{name:"q-transition--fade"},Ee[T.value])])],X=bt(B.default);return X!==void 0&&re.push(v.h("div",{class:"q-date__actions"},X)),l.name!==void 0&&l.disable!==!0&&o(re,"push"),v.h("div",{class:L.value,...ie.value},[Re(),v.h("div",{ref:f,class:"q-date__main col column",tabindex:-1},re)])}}}),ls=$e({name:"QPopupProxy",props:{...Ra,breakpoint:{type:[String,Number],default:450}},emits:["show","hide"],setup(l,{slots:B,emit:t,attrs:b}){const{proxy:m}=v.getCurrentInstance(),{$q:c}=m,i=v.ref(!1),s=v.ref(null),n=v.computed(()=>parseInt(l.breakpoint,10)),{canShow:e}=qi({showing:i});function r(){return c.screen.width<n.value||c.screen.height<n.value?"dialog":"menu"}const u=v.ref(r()),a=v.computed(()=>u.value==="menu"?{maxHeight:"99vh"}:{});v.watch(()=>r(),h=>{i.value!==!0&&(u.value=h)});function o(h){i.value=!0,t("show",h)}function f(h){i.value=!1,u.value=r(),t("hide",h)}return Object.assign(m,{show(h){e(h)===!0&&s.value.show(h)},hide(h){s.value.hide(h)},toggle(h){s.value.toggle(h)}}),Lt(m,"currentComponent",()=>({type:u.value,ref:s.value})),()=>{const h={ref:s,...a.value,...b,onShow:o,onHide:f};let d;return u.value==="dialog"?d=en:(d=Zr,Object.assign(h,{target:l.target,contextMenu:l.contextMenu,noParentEvent:!0,separateClosePopup:!0})),v.h(d,h,B.default)}}}),ea={date:"####/##/##",datetime:"####/##/## ##:##",time:"##:##",fulltime:"##:##:##",phone:"(###) ### - ####",card:"#### #### #### ####"},jn={"#":{pattern:"[\\d]",negate:"[^\\d]"},S:{pattern:"[a-zA-Z]",negate:"[^a-zA-Z]"},N:{pattern:"[0-9a-zA-Z]",negate:"[^0-9a-zA-Z]"},A:{pattern:"[a-zA-Z]",negate:"[^a-zA-Z]",transform:l=>l.toLocaleUpperCase()},a:{pattern:"[a-zA-Z]",negate:"[^a-zA-Z]",transform:l=>l.toLocaleLowerCase()},X:{pattern:"[0-9a-zA-Z]",negate:"[^0-9a-zA-Z]",transform:l=>l.toLocaleUpperCase()},x:{pattern:"[0-9a-zA-Z]",negate:"[^0-9a-zA-Z]",transform:l=>l.toLocaleLowerCase()}},us=Object.keys(jn);us.forEach(l=>{jn[l].regex=new RegExp(jn[l].pattern)});const xc=new RegExp("\\\\([^.*+?^${}()|([\\]])|([.*+?^${}()|[\\]])|(["+us.join("")+"])|(.)","g"),ta=/[.*+?^${}()|[\]\\]/g,Ct="",Sc={mask:String,reverseFillMask:Boolean,fillMask:[Boolean,String],unmaskedValue:Boolean};function kc(l,B,t,b){let m,c,i,s,n,e;const r=v.ref(null),u=v.ref(o());function a(){return l.autogrow===!0||["textarea","text","search","url","tel","password"].includes(l.type)}v.watch(()=>l.type+l.autogrow,h),v.watch(()=>l.mask,N=>{if(N!==void 0)d(u.value,!0);else{const q=V(u.value);h(),l.modelValue!==q&&B("update:modelValue",q)}}),v.watch(()=>l.fillMask+l.reverseFillMask,()=>{r.value===!0&&d(u.value,!0)}),v.watch(()=>l.unmaskedValue,()=>{r.value===!0&&d(u.value)});function o(){if(h(),r.value===!0){const N=T(V(l.modelValue));return l.fillMask!==!1?P(N):N}return l.modelValue}function f(N){if(N<m.length)return m.slice(-N);let q="",W=m;const L=W.indexOf(Ct);if(L!==-1){for(let A=N-W.length;A>0;A--)q+=Ct;W=W.slice(0,L)+q+W.slice(L)}return W}function h(){if(r.value=l.mask!==void 0&&l.mask.length!==0&&a(),r.value===!1){s=void 0,m="",c="";return}const N=ea[l.mask]===void 0?l.mask:ea[l.mask],q=typeof l.fillMask=="string"&&l.fillMask.length!==0?l.fillMask.slice(0,1):"_",W=q.replace(ta,"\\$&"),L=[],A=[],M=[];let _=l.reverseFillMask===!0,y="",x="";N.replace(xc,(O,R,z,U,Q)=>{if(U!==void 0){const j=jn[U];M.push(j),x=j.negate,_===!0&&(A.push("(?:"+x+"+)?("+j.pattern+"+)?(?:"+x+"+)?("+j.pattern+"+)?"),_=!1),A.push("(?:"+x+"+)?("+j.pattern+")?")}else if(z!==void 0)y="\\"+(z==="\\"?"":z),M.push(z),L.push("([^"+y+"]+)?"+y+"?");else{const j=R!==void 0?R:Q;y=j==="\\"?"\\\\\\\\":j.replace(ta,"\\\\$&"),M.push(j),L.push("([^"+y+"]+)?"+y+"?")}});const w=new RegExp("^"+L.join("")+"("+(y===""?".":"[^"+y+"]")+"+)?"+(y===""?"":"["+y+"]*")+"$"),S=A.length-1,E=A.map((O,R)=>R===0&&l.reverseFillMask===!0?new RegExp("^"+W+"*"+O):R===S?new RegExp("^"+O+"("+(x===""?".":x)+"+)?"+(l.reverseFillMask===!0?"$":W+"*")):new RegExp("^"+O));i=M,s=O=>{const R=w.exec(l.reverseFillMask===!0?O:O.slice(0,M.length+1));R!==null&&(O=R.slice(1).join(""));const z=[],U=E.length;for(let Q=0,j=O;Q<U;Q++){const Y=E[Q].exec(j);if(Y===null)break;j=j.slice(Y.shift().length),z.push(...Y)}return z.length!==0?z.join(""):O},m=M.map(O=>typeof O=="string"?O:Ct).join(""),c=m.split(Ct).join(q)}function d(N,q,W){const L=b.value,A=L.selectionEnd,M=L.value.length-A,_=V(N);q===!0&&h();const y=T(_),x=l.fillMask!==!1?P(y):y,w=u.value!==x;L.value!==x&&(L.value=x),w===!0&&(u.value=x),document.activeElement===L&&v.nextTick(()=>{if(x===c){const E=l.reverseFillMask===!0?c.length:0;L.setSelectionRange(E,E,"forward");return}if(W==="insertFromPaste"&&l.reverseFillMask!==!0){const E=L.selectionEnd;let O=A-1;for(let R=n;R<=O&&R<E;R++)m[R]!==Ct&&O++;p.right(L,O);return}if(["deleteContentBackward","deleteContentForward"].indexOf(W)!==-1){const E=l.reverseFillMask===!0?A===0?x.length>y.length?1:0:Math.max(0,x.length-(x===c?0:Math.min(y.length,M)+1))+1:A;L.setSelectionRange(E,E,"forward");return}if(l.reverseFillMask===!0)if(w===!0){const E=Math.max(0,x.length-(x===c?0:Math.min(y.length,M+1)));E===1&&A===1?L.setSelectionRange(E,E,"forward"):p.rightReverse(L,E)}else{const E=x.length-M;L.setSelectionRange(E,E,"backward")}else if(w===!0){const E=Math.max(0,m.indexOf(Ct),Math.min(y.length,A)-1);p.right(L,E)}else{const E=A-1;p.right(L,E)}});const S=l.unmaskedValue===!0?V(x):x;String(l.modelValue)!==S&&(l.modelValue!==null||S!=="")&&t(S,!0)}function g(N,q,W){const L=T(V(N.value));q=Math.max(0,m.indexOf(Ct),Math.min(L.length,q)),n=q,N.setSelectionRange(q,W,"forward")}const p={left(N,q){const W=m.slice(q-1).indexOf(Ct)===-1;let L=Math.max(0,q-1);for(;L>=0;L--)if(m[L]===Ct){q=L,W===!0&&q++;break}if(L<0&&m[q]!==void 0&&m[q]!==Ct)return p.right(N,0);q>=0&&N.setSelectionRange(q,q,"backward")},right(N,q){const W=N.value.length;let L=Math.min(W,q+1);for(;L<=W;L++)if(m[L]===Ct){q=L;break}else m[L-1]===Ct&&(q=L);if(L>W&&m[q-1]!==void 0&&m[q-1]!==Ct)return p.left(N,W);N.setSelectionRange(q,q,"forward")},leftReverse(N,q){const W=f(N.value.length);let L=Math.max(0,q-1);for(;L>=0;L--)if(W[L-1]===Ct){q=L;break}else if(W[L]===Ct&&(q=L,L===0))break;if(L<0&&W[q]!==void 0&&W[q]!==Ct)return p.rightReverse(N,0);q>=0&&N.setSelectionRange(q,q,"backward")},rightReverse(N,q){const W=N.value.length,L=f(W),A=L.slice(0,q+1).indexOf(Ct)===-1;let M=Math.min(W,q+1);for(;M<=W;M++)if(L[M-1]===Ct){q=M,q>0&&A===!0&&q--;break}if(M>W&&L[q-1]!==void 0&&L[q-1]!==Ct)return p.leftReverse(N,W);N.setSelectionRange(q,q,"forward")}};function k(N){B("click",N),e=void 0}function C(N){if(B("keydown",N),Di(N)===!0||N.altKey===!0)return;const q=b.value,W=q.selectionStart,L=q.selectionEnd;if(N.shiftKey||(e=void 0),N.keyCode===37||N.keyCode===39){N.shiftKey&&e===void 0&&(e=q.selectionDirection==="forward"?W:L);const A=p[(N.keyCode===39?"right":"left")+(l.reverseFillMask===!0?"Reverse":"")];if(N.preventDefault(),A(q,e===W?L:W),N.shiftKey){const M=q.selectionStart;q.setSelectionRange(Math.min(e,M),Math.max(e,M),"forward")}}else N.keyCode===8&&l.reverseFillMask!==!0&&W===L?(p.left(q,W),q.setSelectionRange(q.selectionStart,L,"backward")):N.keyCode===46&&l.reverseFillMask===!0&&W===L&&(p.rightReverse(q,L),q.setSelectionRange(W,q.selectionEnd,"forward"))}function T(N){if(N==null||N==="")return"";if(l.reverseFillMask===!0)return D(N);const q=i;let W=0,L="";for(let A=0;A<q.length;A++){const M=N[W],_=q[A];if(typeof _=="string")L+=_;else if(M!==void 0&&_.regex.test(M))L+=_.transform!==void 0?_.transform(M):M,W++;else return L}return L}function D(N){const q=i,W=m.indexOf(Ct);let L=N.length-1,A="";for(let M=q.length-1;M>=0&&L!==-1;M--){const _=q[M];let y=N[L];if(typeof _=="string")A=_+A;else if(y!==void 0&&_.regex.test(y))do A=(_.transform!==void 0?_.transform(y):y)+A,L--,y=N[L];while(W===M&&y!==void 0&&_.regex.test(y));else return A}return A}function V(N){return typeof N!="string"||s===void 0?typeof N=="number"?s(""+N):N:s(N)}function P(N){return c.length-N.length<=0?N:l.reverseFillMask===!0&&N.length!==0?c.slice(0,-N.length)+N:N+c.slice(N.length)}return{innerValue:u,hasMask:r,moveCursorForPaste:g,updateMaskValue:d,onMaskedKeydown:C,onMaskedClick:k}}function _c(l,B){function t(){const b=l.modelValue;try{const m="DataTransfer"in window?new DataTransfer:"ClipboardEvent"in window?new ClipboardEvent("").clipboardData:void 0;return Object(b)===b&&("length"in b?Array.from(b):[b]).forEach(c=>{m.items.add(c)}),{files:m.files}}catch{return{files:void 0}}}return v.computed(()=>{if(l.type==="file")return t()})}const Gr=$e({name:"QInput",inheritAttrs:!1,props:{...Un,...Sc,...Vn,modelValue:[String,Number,FileList],shadowText:String,type:{type:String,default:"text"},debounce:[String,Number],autogrow:Boolean,inputClass:[Array,String,Object],inputStyle:[Array,String,Object]},emits:[...Gi,"paste","change","keydown","click","animationend"],setup(l,{emit:B,attrs:t}){const{proxy:b}=v.getCurrentInstance(),{$q:m}=b,c={};let i=NaN,s,n,e=null,r;const u=v.ref(null),a=wa(l),{innerValue:o,hasMask:f,moveCursorForPaste:h,updateMaskValue:d,onMaskedKeydown:g,onMaskedClick:p}=kc(l,B,y,u),k=_c(l),C=v.computed(()=>Xr(o.value)),T=Qa(M),D=Ji({changeEvent:!0}),V=v.computed(()=>l.type==="textarea"||l.autogrow===!0),P=v.computed(()=>V.value===!0||["text","search","url","tel","password"].includes(l.type)),N=v.computed(()=>{const R={...D.splitAttrs.listeners.value,onInput:M,onPaste:A,onChange:w,onBlur:S,onFocus:Dt};return R.onCompositionstart=R.onCompositionupdate=R.onCompositionend=T,f.value===!0&&(R.onKeydown=g,R.onClick=p),l.autogrow===!0&&(R.onAnimationend=_),R}),q=v.computed(()=>{const R={tabindex:0,"data-autofocus":l.autofocus===!0||void 0,rows:l.type==="textarea"?6:void 0,"aria-label":l.label,name:a.value,...D.splitAttrs.attributes.value,id:D.targetUid.value,maxlength:l.maxlength,disabled:l.disable===!0,readonly:l.readonly===!0};return V.value===!1&&(R.type=l.type),l.autogrow===!0&&(R.rows=1),R});v.watch(()=>l.type,()=>{u.value&&(u.value.value=l.modelValue)}),v.watch(()=>l.modelValue,R=>{if(f.value===!0){if(n===!0&&(n=!1,String(R)===i))return;d(R)}else o.value!==R&&(o.value=R,l.type==="number"&&c.hasOwnProperty("value")===!0&&(s===!0?s=!1:delete c.value));l.autogrow===!0&&v.nextTick(x)}),v.watch(()=>l.autogrow,R=>{R===!0?v.nextTick(x):u.value!==null&&t.rows>0&&(u.value.style.height="auto")}),v.watch(()=>l.dense,()=>{l.autogrow===!0&&v.nextTick(x)});function W(){Jr(()=>{const R=document.activeElement;u.value!==null&&u.value!==R&&(R===null||R.id!==D.targetUid.value)&&u.value.focus({preventScroll:!0})})}function L(){u.value?.select()}function A(R){if(f.value===!0&&l.reverseFillMask!==!0){const z=R.target;h(z,z.selectionStart,z.selectionEnd)}B("paste",R)}function M(R){if(!R||!R.target)return;if(l.type==="file"){B("update:modelValue",R.target.files);return}const z=R.target.value;if(R.target.qComposing===!0){c.value=z;return}if(f.value===!0)d(z,!1,R.inputType);else if(y(z),P.value===!0&&R.target===document.activeElement){const{selectionStart:U,selectionEnd:Q}=R.target;U!==void 0&&Q!==void 0&&v.nextTick(()=>{R.target===document.activeElement&&z.indexOf(R.target.value)===0&&R.target.setSelectionRange(U,Q)})}l.autogrow===!0&&x()}function _(R){B("animationend",R),x()}function y(R,z){r=()=>{e=null,l.type!=="number"&&c.hasOwnProperty("value")===!0&&delete c.value,l.modelValue!==R&&i!==R&&(i=R,z===!0&&(n=!0),B("update:modelValue",R),v.nextTick(()=>{i===R&&(i=NaN)})),r=void 0},l.type==="number"&&(s=!0,c.value=R),l.debounce!==void 0?(e!==null&&clearTimeout(e),c.value=R,e=setTimeout(r,l.debounce)):r()}function x(){requestAnimationFrame(()=>{const R=u.value;if(R!==null){const z=R.parentNode.style,{scrollTop:U}=R,{overflowY:Q,maxHeight:j}=m.platform.is.firefox===!0?{}:window.getComputedStyle(R),Y=Q!==void 0&&Q!=="scroll";Y===!0&&(R.style.overflowY="hidden"),z.marginBottom=R.scrollHeight-1+"px",R.style.height="1px",R.style.height=R.scrollHeight+"px",Y===!0&&(R.style.overflowY=parseInt(j,10)<R.scrollHeight?"auto":"hidden"),z.marginBottom="",R.scrollTop=U}})}function w(R){T(R),e!==null&&(clearTimeout(e),e=null),r?.(),B("change",R.target.value)}function S(R){R!==void 0&&Dt(R),e!==null&&(clearTimeout(e),e=null),r?.(),s=!1,n=!1,delete c.value,l.type!=="file"&&setTimeout(()=>{u.value!==null&&(u.value.value=o.value!==void 0?o.value:"")})}function E(){return c.hasOwnProperty("value")===!0?c.value:o.value!==void 0?o.value:""}v.onBeforeUnmount(()=>{S()}),v.onMounted(()=>{l.autogrow===!0&&x()}),Object.assign(D,{innerValue:o,fieldClass:v.computed(()=>`q-${V.value===!0?"textarea":"input"}`+(l.autogrow===!0?" q-textarea--autogrow":"")),hasShadow:v.computed(()=>l.type!=="file"&&typeof l.shadowText=="string"&&l.shadowText.length!==0),inputRef:u,emitValue:y,hasValue:C,floatingLabel:v.computed(()=>C.value===!0&&(l.type!=="number"||isNaN(o.value)===!1)||Xr(l.displayValue)),getControl:()=>v.h(V.value===!0?"textarea":"input",{ref:u,class:["q-field__native q-placeholder",l.inputClass],style:l.inputStyle,...q.value,...N.value,...l.type!=="file"?{value:E()}:k.value}),getShadowControl:()=>v.h("div",{class:"q-field__native q-field__shadow absolute-bottom no-pointer-events"+(V.value===!0?"":" text-no-wrap")},[v.h("span",{class:"invisible"},E()),v.h("span",l.shadowText)])});const O=Zi(D);return Object.assign(b,{focus:W,select:L,getNativeElement:()=>u.value}),Lt(b,"nativeEl",()=>u.value),O}});function Cc(l){return{entity:l.entity,dataCy:l.dataCy,defaultLabel:l.defaultLabel,routeName:l.routeName,shouldRender:l.customShouldRender||(({store:B})=>l.storeField?!!B[l.storeField]:!0),getLabel:l.getLabel||(l.labelField?({store:B})=>l.storeField&&B[l.storeField]?.[l.labelField]||l.defaultLabel:void 0),getColor:l.customGetColor||(({store:B})=>l.storeField&&B[l.storeField]?"primary":"dark"),getRouteParams:l.routeParamKey&&l.routeParamField?({store:B})=>({[l.routeParamKey]:l.storeField&&B[l.storeField]?.[l.routeParamField]}):void 0,clearActions:[...l.clearMethods?.map(B=>({store:t})=>t[B]?.())||[],...l.navActions?.map(B=>({navStore:t})=>B(t))||[]]}}const cs=/^\d{2}-\d{2}-\d{4}$/;function Ac(l){const B=l.getTimezoneOffset()*6e4;return new Date(l.getTime()+B)}function Ur(l){const B=/^\d{4}-\d{2}-\d{2}$/,t=/^\d{2}-\d{2}-\d{4}$/;if(B.test(l))return l;if(t.test(l)){const b=l.split("-");return`${b[2]}-${b[1]}-${b[0]}`}return console.warn("'Invalid date format. Expected DD-MM-YYYY' or 'YYYY-MM-DD' but got: "+l),""}function oo(l,B,t,b=[]){const m=typeof l=="string"?new Date(Ur(l)):new Date(l);if(Number.isNaN(m.getTime()))return!1;if(B){const s=typeof B=="string"?new Date(Ur(B)):new Date(B);if(m<s)return!1}if(t){const s=typeof t=="string"?new Date(Ur(t)):new Date(t);if(m>s)return!1}return b.some(s=>{if(typeof s=="string"){const n=new Date(Ur(s));return m.getFullYear()===n.getFullYear()&&m.getMonth()===n.getMonth()&&m.getDate()===n.getDate()}else{if(s instanceof Date)return m.getFullYear()===s.getFullYear()&&m.getMonth()===s.getMonth()&&m.getDate()===s.getDate();{const n=new Date(s.start_date),e=new Date(s.end_date);return m>=n&&m<=e}}})?!1:!b.some(s=>{if(typeof s=="object"&&!(s instanceof Date)&&s.start_date&&s.end_date){const n=new Date(s.start_date),e=new Date(s.end_date);if(n.getTime()===e.getTime())return m.getTime()===n.getTime()||m.getTime()===e.getTime()}return!1})}const Kt={validateAndUpdate(l,B,t){return cs.test(B)?{...l,[t?"from":"to"]:B}:l},isEndDateValid(l,B,t=!1){if(!l||!B)return!0;try{const[b,m,c]=l.split("-"),[i,s,n]=B.split("-"),e=new Date(Number(c),Number(m)-1,Number(b)),r=new Date(Number(n),Number(s)-1,Number(i));return t?r>=e:r>e}catch{return!1}},handlePickerUpdate(l){return l===null?{from:"",to:""}:typeof l=="string"?{from:l,to:l}:l},reset(){return{from:"",to:""}},handleInput(l,B){typeof l=="string"&&B(l)}},ds={days:["Dimanche","Lundi","Mardi","Mercredi","Jeudi","Vendredi","Samedi"],daysShort:["Dim","Lun","Mar","Mer","Jeu","Ven","Sam"],months:["Janvier","Février","Mars","Avril","Mai","Juin","Juillet","Août","Septembre","Octobre","Novembre","Décembre"],monthsShort:["Janv","Févr","Mars","Avr","Mai","Juin","Juil","Août","Sept","Oct","Nov","Dec"],firstDayOfWeek:1,format24h:!0,pluralDay:"jours"};function Ec(l){if(!l||!/^\d{2}-\d{2}-\d{4}$/.test(l))return new Date(Number.NaN);const[B,t,b]=l.split("-").map(Number);return new Date(b,t-1,B)}function Ut(l){if(!l)return"";const B=new Date(l),t=B.getFullYear(),b=String(B.getMonth()+1).padStart(2,"0");return`${String(B.getDate()).padStart(2,"0")}-${b}-${t}`}function Dn(l,B){return new Date(l,B-1,1)}function Pn(l,B){return new Date(l,B,0)}function fs(l=new Date){const B=l.getFullYear(),t=l.getMonth()+1;let b=t-3,m=B;b<=0&&(b+=12,m-=1);const c=Dn(m,b);let i=t-1,s=B;i<=0&&(i+=12,s-=1);const n=Pn(s,i);return{from:Ut(c),to:Ut(n)}}const hs={currentMonth:(l=new Date)=>{const B=l.getFullYear(),t=l.getMonth()+1;return{from:Ut(Dn(B,t)),to:Ut(Pn(B,t))}},previousMonth:(l=new Date)=>{const B=l.getFullYear();let b=l.getMonth()+1-1,m=B;return b===0&&(b=12,m=B-1),{from:Ut(Dn(m,b)),to:Ut(Pn(m,b))}},last3Months:fs,currentYear:(l=new Date)=>{const B=l.getFullYear();return{from:Ut(new Date(B,0,1)),to:Ut(new Date(B,11,31))}},previousYear:(l=new Date)=>{const B=l.getFullYear()-1;return{from:Ut(new Date(B,0,1)),to:Ut(new Date(B,11,31))}}};function Mc(l){if(!l)return{date:"",time:""};try{const B=new Date(l);if(Number.isNaN(B.getTime()))return console.error("Invalid date:",l),{date:"",time:""};const b=new Intl.DateTimeFormat("fr-FR",{timeZone:"Europe/Paris",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",hour12:!1}).formatToParts(B),m=f=>b.find(h=>h.type===f)?.value||"",c=m("day"),i=m("month"),s=m("year"),n=m("hour"),e=m("minute"),r=m("second"),u=`${c}-${i}-${s}`,o=l.includes("T")&&l.split("T")[1]?.split(":").length>=3&&l.split("T")[1].split(":")[2]!=="00"?`${n}:${e}:${r}`:`${n}:${e}`;return{date:u,time:o}}catch(B){return console.error("Error parsing ISO datetime:",B,"Input:",l),{date:"",time:""}}}function Tc(l){if(!l)return"";if(new RegExp(/^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}/).exec(l))return l;if(new RegExp(/^\d{4}-\d{2}-\d{2}$/).exec(l))return`${l}T00:00:00Z`;if(new RegExp(/^\d{2}-\d{2}-\d{4}$/).exec(l)){const[t,b,m]=l.split("-");return`${m}-${b}-${t}T00:00:00Z`}if(new RegExp(/^\d{2}\/\d{2}\/\d{4}$/).exec(l)){const[t,b,m]=l.split("/");return`${m}-${b}-${t}T00:00:00Z`}if(new RegExp(/^\d{2}\.\d{2}\.\d{4}$/).exec(l)){const[t,b,m]=l.split(".");return`${m}-${b}-${t}T00:00:00Z`}const B=new Date(l);return Number.isNaN(B.getTime())?l:B.toISOString()}const Rc={class:"columns justify-end"},Bc=v.defineComponent({__name:"DatePicker",props:{label:{default:"Date"},date:{default:""},required:{type:Boolean,default:!1},minDate:{default:void 0},maxDate:{default:void 0},datesDisabled:{default:()=>[]},requiredErrorMessage:{default:"Ce champ est obligatoire !"},invalidDateErrorMessage:{default:"Date invalide!"},disabled:{type:Boolean,default:!1},outlined:{type:Boolean,default:!1},placeholder:{default:void 0},closeLabel:{default:"Close"},rules:{default:()=>[]}},emits:["update:modelValue","update:date"],setup(l,{emit:B}){const t=l,b=B,m=v.useAttrs(),c=v.ref(),i=v.ref(t.date),s=v.ref(null),n=v.computed(()=>i.value),e=C=>{if(!C||C.length!==10)return!1;const T=/^(\d{2})-(\d{2})-(\d{4})$/,D=C.match(T);if(!D)return!1;const V=Number.parseInt(D[1],10),P=Number.parseInt(D[2],10),N=Number.parseInt(D[3],10);if(P<1||P>12||V<1||V>31)return!1;const q=new Date(N,P-1,V);return q.getFullYear()===N&&q.getMonth()===P-1&&q.getDate()===V},r=C=>{if(!C)return null;if(C.length!==10)return"Le format doit être JJ-MM-AAAA";const T=/^(\d{2})-(\d{2})-(\d{4})$/,D=C.match(T);if(!D)return"Format invalide. Utilisez JJ-MM-AAAA";const V=Number.parseInt(D[1],10),P=Number.parseInt(D[2],10),N=Number.parseInt(D[3],10),q=u(P);if(q)return q;const W=a(V,P,N);return W||(f(V,P,N)?null:"Date inexistante")},u=C=>C<1||C>12?"Le mois doit être entre 01 et 12":null,a=(C,T,D)=>C<1||C>31?"Le jour doit être entre 01 et 31":[4,6,9,11].includes(T)&&C>30?`Le mois ${T} n'a que 30 jours`:T===2?o(C,D):null,o=(C,T)=>{const D=T%4===0&&T%100!==0||T%400===0;return D&&C>29?"Février a maximum 29 jours pour les années bissextiles":!D&&C>28?"Février a maximum 28 jours":null},f=(C,T,D)=>{const V=new Date(D,T-1,C);return V.getFullYear()===D&&V.getMonth()===T-1&&V.getDate()===C},h=()=>{n.value?s.value=r(n.value):s.value=null},d=v.computed(()=>C=>{const T=C.replaceAll("/","-");return oo(T,t.minDate,t.maxDate,t.datesDisabled)}),g=C=>{e(C)&&(i.value=C,s.value=null,b("update:date",C),b("update:modelValue",C),setTimeout(()=>{c.value?.hide?.()},0))},p=C=>{if(typeof C=="string")if(i.value=C,b("update:date",C),b("update:modelValue",C),C.length===10){const T=r(C);s.value=T}else C===""&&(s.value=null);else C===null&&(i.value="",s.value=null,b("update:date",""),b("update:modelValue",""))},k=v.computed(()=>{const C=[...t.rules];return t.required&&C.push(T=>!!T||t.requiredErrorMessage),C.push(T=>T?e(T)||s.value||t.invalidDateErrorMessage:!0),C});return v.watch(()=>[t.date],([C,T])=>{const D=T??C;D&&D!==i.value&&(i.value=D,h())}),(C,T)=>(v.openBlock(),v.createElementBlock("div",Rc,[v.createVNode(Gr,v.mergeProps(v.unref(m),{class:"full-width","model-value":n.value,mask:"##-##-####",dense:"",label:C.label,"data-cy":"datePick",rules:k.value,disable:C.disabled,required:C.required,outlined:C.outlined,placeholder:C.placeholder,"onUpdate:modelValue":p,onBlur:h}),{append:v.withCtx(()=>[v.createVNode(dt,{name:"event",class:"cursor-pointer","data-testid":"calendar-icon-picker"},{default:v.withCtx(()=>[v.createVNode(ls,{ref_key:"popupRef",ref:c,cover:"","transition-show":"scale","transition-hide":"scale","no-focus":""},{default:v.withCtx(()=>[v.createVNode(ss,{mask:"DD-MM-YYYY","model-value":i.value,options:d.value,disable:C.disabled,"onUpdate:modelValue":g},null,8,["model-value","options","disable"])]),_:1},512)]),_:1})]),_:1},16,["model-value","label","rules","disable","required","outlined","placeholder"])]))}}),Ic={class:"date-range-wrapper"},Oc={class:"date-range-flex"},Fc={key:0,class:"actions-group"},jc={class:"date-range-popup"},Dc={key:0,class:"presets-section"},Pc={class:"presets-grid"},Nc={class:"presets-row"},Lc={class:"presets-row"},Vc={class:"calendar-container"},qc={class:"popup-actions"},zc={key:0,class:"hint"},Uc={class:"text-warning text-caption q-mb-none"},Wc=v.defineComponent({__name:"DateRange",props:{allowSameDate:{type:Boolean,default:!0},from:{default:""},to:{default:""},labelStart:{default:"De"},labelEnd:{default:"À"},startDateHint:{default:""},resetLabel:{default:"Reinitialiser"},closeLabel:{default:"Fermer"},locale:{default:()=>ds},required:{type:Boolean,default:!1},requiredErrorMessage:{default:"Ce champ est obligatoire !"},invalidDateErrorMessage:{default:"Date invalide!"},rules:{default:()=>[]},minDate:{default:void 0},maxDate:{default:void 0},datesDisabled:{default:()=>[]},highlightEvents:{default:()=>[]},disabled:{type:Boolean,default:!1},idCy:{default:"dateRange"},isIconCalendar:{type:Boolean},resetPosition:{},hideActions:{type:Boolean,default:!1},hideShortcuts:{type:Boolean,default:!1},shortcuts:{default:()=>[{id:"currentMonth",label:"Mois courant"},{id:"previousMonth",label:"Mois précédent"},{id:"last3Months",label:"3 derniers mois"},{id:"currentYear",label:"Année courante"},{id:"previousYear",label:"Année précédente"}]}},emits:["update:dateRange","clear"],setup(l,{expose:B,emit:t}){const b=l,m=t,c=v.ref({from:b.from,to:b.to}),i=v.ref(null),s=v.computed(()=>`from-date-${b.idCy}`),n=v.computed(()=>`to-date-${b.idCy}`),e=v.ref(null),r=v.computed(()=>b.shortcuts.map(R=>({...R,getRange:hs[R.id]}))),u=v.computed(()=>r.value.slice(0,3)),a=v.computed(()=>r.value.slice(3)),o=()=>{c.value=Kt.reset(),D.value=null,V.value=null,e.value=null,w(),m("clear")},f=()=>{i.value&&i.value.hide()},h=()=>{if(e.value=null,!(!c.value.from||!c.value.to))for(const R of r.value)try{const z=R.getRange(new Date);if(z.from===c.value.from&&z.to===c.value.to){e.value=R.id;break}}catch(z){console.error("Error checking preset:",z)}},d=R=>{if(!R||R.length!==10)return!1;const z=/^(\d{2})-(\d{2})-(\d{4})$/,U=R.match(z);if(!U)return!1;const Q=Number.parseInt(U[1],10),j=Number.parseInt(U[2],10),Y=Number.parseInt(U[3],10);if(j<1||j>12||Q<1||Q>31)return!1;const F=new Date(Y,j-1,Q);return F.getFullYear()===Y&&F.getMonth()===j-1&&F.getDate()===Q},g=R=>{if(!R)return null;if(R.length!==10)return"Le format doit être JJ-MM-AAAA";const z=/^(\d{2})-(\d{2})-(\d{4})$/,U=R.match(z);if(!U)return"Format invalide. Utilisez JJ-MM-AAAA";const Q=Number.parseInt(U[1],10),j=Number.parseInt(U[2],10),Y=Number.parseInt(U[3],10),F=p(j);if(F)return F;const I=k(Q,j,Y);return I||(T(Q,j,Y)?null:"Date inexistante")},p=R=>R<1||R>12?"Le mois doit être entre 01 et 12":null,k=(R,z,U)=>R<1||R>31?"Le jour doit être entre 01 et 31":[4,6,9,11].includes(z)&&R>30?`Le mois ${z} n'a que 30 jours`:z===2?C(R,U):null,C=(R,z)=>{const U=z%4===0&&z%100!==0||z%400===0;return U&&R>29?"Février a maximum 29 jours pour les années bissextiles":!U&&R>28?"Février a maximum 28 jours":null},T=(R,z,U)=>{const Q=new Date(U,z-1,R);return Q.getFullYear()===U&&Q.getMonth()===z-1&&Q.getDate()===R},D=v.ref(null),V=v.ref(null),P=()=>{c.value.from?D.value=g(c.value.from):D.value=null},N=()=>{c.value.to?V.value=g(c.value.to):V.value=null},q=v.computed(()=>R=>{const z=R.replaceAll("/","-");return oo(z,b.minDate,b.maxDate,b.datesDisabled)});let W=!1;const L=()=>{W=!0,c.value.from="",D.value=null,e.value=null,w(),setTimeout(()=>{W=!1},100)},A=()=>{W=!0,c.value.to="",V.value=null,e.value=null,w(),setTimeout(()=>{W=!1},100)},M=R=>{if(R===null||R===""){const z=c.value.from;c.value.from="",D.value=null,e.value=null,w(),!c.value.to&&z&&!c.value.from&&m("clear");return}Kt.handleInput(R,z=>{const U=c.value.from;if(z&&z.length===10){const Q=g(z);if(D.value=Q,Q){c.value.from=z,w();return}}else D.value=null;c.value=Kt.validateAndUpdate(c.value,z,!0),h(),w(),!z&&!c.value.to&&U&&m("clear")})},_=R=>{if(R===null||R===""){const z=c.value.to;c.value.to="",V.value=null,e.value=null,w(),!c.value.from&&z&&!c.value.to&&m("clear");return}Kt.handleInput(R,z=>{const U=c.value.to;if(z&&z.length===10){const Q=g(z);if(V.value=Q,Q){c.value.to=z,w();return}}else V.value=null;c.value=Kt.validateAndUpdate(c.value,z,!1),h(),w(),!z&&!c.value.from&&U&&m("clear")})},y=()=>{setTimeout(()=>{c.value.from&&c.value.from.length===10?D.value=g(c.value.from):D.value=null,c.value.to&&c.value.to.length===10?V.value=g(c.value.to):V.value=null,!b.allowSameDate&&c.value.from&&c.value.to&&c.value.from===c.value.to&&(c.value.to=""),h()},10)},x=R=>{const z=Kt.handlePickerUpdate(R);(z.from!==c.value.from||z.to!==c.value.to)&&(e.value=null),c.value=z,w(),h()},w=()=>{m("update:dateRange",{...c.value})},S=v.computed(()=>[...b.required?[R=>!!R||b.requiredErrorMessage]:[],...b.rules,R=>{if(R&&!d(R))return D.value||b.invalidDateErrorMessage||"Date invalide!";const z=c.value.to;if(!R||!z)return!0;const U=Kt.isEndDateValid(R,z,b.allowSameDate);return b.allowSameDate?U||"La date de début doit être avant ou égale à la date de fin":U||"La date de début doit être strictement avant la date de fin"}]),E=v.computed(()=>[...b.required?[R=>!!R||b.requiredErrorMessage]:[],...b.rules,R=>{if(R&&!d(R))return V.value||b.invalidDateErrorMessage||"Date invalide!";const z=c.value.from;if(!R||!z)return!0;const U=Kt.isEndDateValid(z,R,b.allowSameDate);return b.allowSameDate?U||"La date de fin doit être après ou égale à la date de début":U||"La date de fin doit être strictement après la date de début"}]);v.watch([()=>c.value.from,()=>c.value.to],([R,z],[U,Q])=>{!R&&!z&&(U||Q)&&!W&&(D.value=null,V.value=null,e.value=null,m("clear"))}),v.watch(()=>b.from,R=>{R!==c.value.from&&(c.value.from=R,P(),h())}),v.watch(()=>b.to,R=>{R!==c.value.to&&(c.value.to=R,N(),h())}),B({setDateRange:R=>{c.value={from:R.from,to:R.to},P(),N(),h(),w()},getCurrentRange:()=>({from:c.value.from,to:c.value.to}),resetDate:()=>{o()}});const O=R=>{try{const z=R.getRange(new Date);c.value={from:z.from,to:z.to},e.value=R.id,P(),N(),w()}catch(z){console.error("Error applying date preset:",z)}};return v.onMounted(()=>{P(),N(),h()}),(R,z)=>(v.openBlock(),v.createElementBlock("div",Ic,[v.createElementVNode("div",Oc,[v.createVNode(Gr,v.mergeProps(R.$attrs,{"data-cy":s.value,"model-value":c.value.from,mask:"##-##-####",label:R.labelStart,rules:S.value,disable:R.disabled,required:R.required,"hide-bottom-space":"","onUpdate:modelValue":M,onClear:L,onBlur:P,class:"date-input",clearable:""}),null,16,["data-cy","model-value","label","rules","disable","required"]),v.createVNode(Gr,v.mergeProps(R.$attrs,{"model-value":c.value.to,mask:"##-##-####",label:R.labelEnd,"hide-bottom-space":"","data-cy":n.value,rules:E.value,disable:R.disabled,required:R.required,"onUpdate:modelValue":_,onClear:A,onBlur:N,class:"date-input",clearable:""}),null,16,["model-value","label","data-cy","rules","disable","required"]),R.hideActions?v.createCommentVNode("",!0):(v.openBlock(),v.createElementBlock("div",Fc,[v.createVNode(dt,{name:"event",size:"30px",class:"cursor-pointer calendar-icon",style:{opacity:"0.55"},"data-cy":"calendar-icon-range"},{default:v.withCtx(()=>[v.createVNode(ls,{cover:"","transition-show":"scale","transition-hide":"scale",ref_key:"popupRef",ref:i,"no-focus":""},{default:v.withCtx(()=>[v.createElementVNode("div",jc,[R.hideShortcuts?v.createCommentVNode("",!0):(v.openBlock(),v.createElementBlock("div",Dc,[z[0]||(z[0]=v.createElementVNode("div",{class:"presets-title"},"Périodes rapides :",-1)),v.createElementVNode("div",Pc,[v.createElementVNode("div",Nc,[(v.openBlock(!0),v.createElementBlock(v.Fragment,null,v.renderList(u.value,U=>(v.openBlock(),v.createBlock(at,{key:U.id,label:U.label,color:e.value===U.id?"primary":"grey-7",outline:e.value!==U.id,flat:"",dense:"",size:"sm",class:"preset-btn",onClick:Q=>O(U),"data-cy":`date-preset-${U.id}`},null,8,["label","color","outline","onClick","data-cy"]))),128))]),v.createElementVNode("div",Lc,[(v.openBlock(!0),v.createElementBlock(v.Fragment,null,v.renderList(a.value,U=>(v.openBlock(),v.createBlock(at,{key:U.id,label:U.label,color:e.value===U.id?"primary":"grey-7",outline:e.value!==U.id,flat:"",dense:"",size:"sm",class:"preset-btn",onClick:Q=>O(U),"data-cy":`date-preset-${U.id}`},null,8,["label","color","outline","onClick","data-cy"]))),128))])])])),v.createElementVNode("div",Vc,[v.createVNode(ss,{"model-value":c.value,mask:"DD-MM-YYYY","today-btn":"",range:"","data-cy":"date-picker-range",locale:R.locale,options:q.value,events:R.highlightEvents,"event-color":"warning",disable:R.disabled,"onUpdate:modelValue":x,onRangeEnd:y,"no-unset":""},null,8,["model-value","locale","options","events","disable"])]),v.createElementVNode("div",qc,[v.createVNode(at,{label:R.resetLabel,color:"grey-7",flat:"",dense:"",onClick:o,class:"q-mr-sm"},null,8,["label"]),v.createVNode(at,{label:R.closeLabel,color:"primary",flat:"",dense:"",onClick:f},null,8,["label"])])])]),_:1},512)]),_:1})]))]),R.startDateHint?(v.openBlock(),v.createElementBlock("div",zc,[v.createElementVNode("p",Uc,v.toDisplayString(R.startDateHint),1)])):v.createCommentVNode("",!0)]))}}),ps=Vt(Wc,[["__scopeId","data-v-3ec8c453"]]);var ut=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Hc(l){return l&&l.__esModule&&Object.prototype.hasOwnProperty.call(l,"default")?l.default:l}function gn(l){throw new Error('Could not dynamically require "'+l+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var fi={exports:{}};/*! ExcelJS 19-10-2023 */var ra;function Yc(){return ra||(ra=1,function(l,B){(function(t){l.exports=t()})(function(){return function t(b,m,c){function i(e,r){if(!m[e]){if(!b[e]){var u=typeof gn=="function"&&gn;if(!r&&u)return u(e,!0);if(s)return s(e,!0);var a=new Error("Cannot find module '"+e+"'");throw a.code="MODULE_NOT_FOUND",a}var o=m[e]={exports:{}};b[e][0].call(o.exports,function(f){return i(b[e][1][f]||f)},o,o.exports,t,b,m,c)}return m[e].exports}for(var s=typeof gn=="function"&&gn,n=0;n<c.length;n++)i(c[n]);return i}({1:[function(t,b,m){const c=t("fs"),i=t("fast-csv"),s=t("dayjs/plugin/customParseFormat"),n=t("dayjs/plugin/utc"),e=t("dayjs").extend(s).extend(n),r=t("../utils/stream-buf"),{fs:{exists:u}}=t("../utils/utils"),a={true:!0,false:!1,"#N/A":{error:"#N/A"},"#REF!":{error:"#REF!"},"#NAME?":{error:"#NAME?"},"#DIV/0!":{error:"#DIV/0!"},"#NULL!":{error:"#NULL!"},"#VALUE!":{error:"#VALUE!"},"#NUM!":{error:"#NUM!"}};b.exports=class{constructor(o){this.workbook=o,this.worksheet=null}async readFile(o,f){if(f=f||{},!await u(o))throw new Error("File not found: "+o);const h=c.createReadStream(o),d=await this.read(h,f);return h.close(),d}read(o,f){return f=f||{},new Promise((h,d)=>{const g=this.workbook.addWorksheet(f.sheetName),p=f.dateFormats||["YYYY-MM-DD[T]HH:mm:ssZ","YYYY-MM-DD[T]HH:mm:ss","MM-DD-YYYY","YYYY-MM-DD"],k=f.map||function(T){if(T==="")return null;const D=Number(T);if(!Number.isNaN(D)&&D!==1/0)return D;const V=p.reduce((N,q)=>{if(N)return N;const W=e(T,q,!0);return W.isValid()?W:null},null);if(V)return new Date(V.valueOf());const P=a[T];return P!==void 0?P:T},C=i.parse(f.parserOptions).on("data",T=>{g.addRow(T.map(k))}).on("end",()=>{C.emit("worksheet",g)});C.on("worksheet",h).on("error",d),o.pipe(C)})}createInputStream(){throw new Error("`CSV#createInputStream` is deprecated. You should use `CSV#read` instead. This method will be removed in version 5.0. Please follow upgrade instruction: https://github.com/exceljs/exceljs/blob/master/UPGRADE-4.0.md")}write(o,f){return new Promise((h,d)=>{f=f||{};const g=this.workbook.getWorksheet(f.sheetName||f.sheetId),p=i.format(f.formatterOptions);o.on("finish",()=>{h()}),p.on("error",d),p.pipe(o);const{dateFormat:k,dateUTC:C}=f,T=f.map||(P=>{if(P){if(P.text||P.hyperlink)return P.hyperlink||P.text||"";if(P.formula||P.result)return P.result||"";if(P instanceof Date)return k?C?e.utc(P).format(k):e(P).format(k):C?e.utc(P).format():e(P).format();if(P.error)return P.error;if(typeof P=="object")return JSON.stringify(P)}return P}),D=f.includeEmptyRows===void 0||f.includeEmptyRows;let V=1;g&&g.eachRow((P,N)=>{if(D)for(;V++<N-1;)p.write([]);const{values:q}=P;q.shift(),p.write(q.map(T)),V=N}),p.end()})}writeFile(o,f){const h={encoding:(f=f||{}).encoding||"utf8"},d=c.createWriteStream(o,h);return this.write(d,f)}async writeBuffer(o){const f=new r;return await this.write(f,o),f.read()}}},{"../utils/stream-buf":24,"../utils/utils":27,dayjs:391,"dayjs/plugin/customParseFormat":392,"dayjs/plugin/utc":393,"fast-csv":424,fs:216}],2:[function(t,b,m){const c=t("../utils/col-cache");class i{constructor(n,e){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0;if(this.worksheet=n,e)if(typeof e=="string"){const u=c.decodeAddress(e);this.nativeCol=u.col+r,this.nativeColOff=0,this.nativeRow=u.row+r,this.nativeRowOff=0}else e.nativeCol!==void 0?(this.nativeCol=e.nativeCol||0,this.nativeColOff=e.nativeColOff||0,this.nativeRow=e.nativeRow||0,this.nativeRowOff=e.nativeRowOff||0):e.col!==void 0?(this.col=e.col+r,this.row=e.row+r):(this.nativeCol=0,this.nativeColOff=0,this.nativeRow=0,this.nativeRowOff=0);else this.nativeCol=0,this.nativeColOff=0,this.nativeRow=0,this.nativeRowOff=0}static asInstance(n){return n instanceof i||n==null?n:new i(n)}get col(){return this.nativeCol+Math.min(this.colWidth-1,this.nativeColOff)/this.colWidth}set col(n){this.nativeCol=Math.floor(n),this.nativeColOff=Math.floor((n-this.nativeCol)*this.colWidth)}get row(){return this.nativeRow+Math.min(this.rowHeight-1,this.nativeRowOff)/this.rowHeight}set row(n){this.nativeRow=Math.floor(n),this.nativeRowOff=Math.floor((n-this.nativeRow)*this.rowHeight)}get colWidth(){return this.worksheet&&this.worksheet.getColumn(this.nativeCol+1)&&this.worksheet.getColumn(this.nativeCol+1).isCustomWidth?Math.floor(1e4*this.worksheet.getColumn(this.nativeCol+1).width):64e4}get rowHeight(){return this.worksheet&&this.worksheet.getRow(this.nativeRow+1)&&this.worksheet.getRow(this.nativeRow+1).height?Math.floor(1e4*this.worksheet.getRow(this.nativeRow+1).height):18e4}get model(){return{nativeCol:this.nativeCol,nativeColOff:this.nativeColOff,nativeRow:this.nativeRow,nativeRowOff:this.nativeRowOff}}set model(n){this.nativeCol=n.nativeCol,this.nativeColOff=n.nativeColOff,this.nativeRow=n.nativeRow,this.nativeRowOff=n.nativeRowOff}}b.exports=i},{"../utils/col-cache":19}],3:[function(t,b,m){const c=t("../utils/col-cache"),i=t("../utils/under-dash"),s=t("./enums"),{slideFormula:n}=t("../utils/shared-formula"),e=t("./note");class r{constructor(o,f,h){if(!o||!f)throw new Error("A Cell needs a Row");this._row=o,this._column=f,c.validateAddress(h),this._address=h,this._value=u.create(r.Types.Null,this),this.style=this._mergeStyle(o.style,f.style,{}),this._mergeCount=0}get worksheet(){return this._row.worksheet}get workbook(){return this._row.worksheet.workbook}destroy(){delete this.style,delete this._value,delete this._row,delete this._column,delete this._address}get numFmt(){return this.style.numFmt}set numFmt(o){this.style.numFmt=o}get font(){return this.style.font}set font(o){this.style.font=o}get alignment(){return this.style.alignment}set alignment(o){this.style.alignment=o}get border(){return this.style.border}set border(o){this.style.border=o}get fill(){return this.style.fill}set fill(o){this.style.fill=o}get protection(){return this.style.protection}set protection(o){this.style.protection=o}_mergeStyle(o,f,h){const d=o&&o.numFmt||f&&f.numFmt;d&&(h.numFmt=d);const g=o&&o.font||f&&f.font;g&&(h.font=g);const p=o&&o.alignment||f&&f.alignment;p&&(h.alignment=p);const k=o&&o.border||f&&f.border;k&&(h.border=k);const C=o&&o.fill||f&&f.fill;C&&(h.fill=C);const T=o&&o.protection||f&&f.protection;return T&&(h.protection=T),h}get address(){return this._address}get row(){return this._row.number}get col(){return this._column.number}get $col$row(){return`$${this._column.letter}$${this.row}`}get type(){return this._value.type}get effectiveType(){return this._value.effectiveType}toCsvString(){return this._value.toCsvString()}addMergeRef(){this._mergeCount++}releaseMergeRef(){this._mergeCount--}get isMerged(){return this._mergeCount>0||this.type===r.Types.Merge}merge(o,f){this._value.release(),this._value=u.create(r.Types.Merge,this,o),f||(this.style=o.style)}unmerge(){this.type===r.Types.Merge&&(this._value.release(),this._value=u.create(r.Types.Null,this),this.style=this._mergeStyle(this._row.style,this._column.style,{}))}isMergedTo(o){return this._value.type===r.Types.Merge&&this._value.isMergedTo(o)}get master(){return this.type===r.Types.Merge?this._value.master:this}get isHyperlink(){return this._value.type===r.Types.Hyperlink}get hyperlink(){return this._value.hyperlink}get value(){return this._value.value}set value(o){this.type!==r.Types.Merge?(this._value.release(),this._value=u.create(u.getType(o),this,o)):this._value.master.value=o}get note(){return this._comment&&this._comment.note}set note(o){this._comment=new e(o)}get text(){return this._value.toString()}get html(){return i.escapeHtml(this.text)}toString(){return this.text}_upgradeToHyperlink(o){this.type===r.Types.String&&(this._value=u.create(r.Types.Hyperlink,this,{text:this._value.value,hyperlink:o}))}get formula(){return this._value.formula}get result(){return this._value.result}get formulaType(){return this._value.formulaType}get fullAddress(){const{worksheet:o}=this._row;return{sheetName:o.name,address:this.address,row:this.row,col:this.col}}get name(){return this.names[0]}set name(o){this.names=[o]}get names(){return this.workbook.definedNames.getNamesEx(this.fullAddress)}set names(o){const{definedNames:f}=this.workbook;f.removeAllNames(this.fullAddress),o.forEach(h=>{f.addEx(this.fullAddress,h)})}addName(o){this.workbook.definedNames.addEx(this.fullAddress,o)}removeName(o){this.workbook.definedNames.removeEx(this.fullAddress,o)}removeAllNames(){this.workbook.definedNames.removeAllNames(this.fullAddress)}get _dataValidations(){return this.worksheet.dataValidations}get dataValidation(){return this._dataValidations.find(this.address)}set dataValidation(o){this._dataValidations.add(this.address,o)}get model(){const{model:o}=this._value;return o.style=this.style,this._comment&&(o.comment=this._comment.model),o}set model(o){if(this._value.release(),this._value=u.create(o.type,this),this._value.model=o,o.comment)switch(o.comment.type){case"note":this._comment=e.fromModel(o.comment)}o.style?this.style=o.style:this.style={}}}r.Types=s.ValueType;const u={getType:a=>a==null?r.Types.Null:a instanceof String||typeof a=="string"?r.Types.String:typeof a=="number"?r.Types.Number:typeof a=="boolean"?r.Types.Boolean:a instanceof Date?r.Types.Date:a.text&&a.hyperlink?r.Types.Hyperlink:a.formula||a.sharedFormula?r.Types.Formula:a.richText?r.Types.RichText:a.sharedString?r.Types.SharedString:a.error?r.Types.Error:r.Types.JSON,types:[{t:r.Types.Null,f:class{constructor(a){this.model={address:a.address,type:r.Types.Null}}get value(){return null}set value(a){}get type(){return r.Types.Null}get effectiveType(){return r.Types.Null}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return""}release(){}toString(){return""}}},{t:r.Types.Number,f:class{constructor(a,o){this.model={address:a.address,type:r.Types.Number,value:o}}get value(){return this.model.value}set value(a){this.model.value=a}get type(){return r.Types.Number}get effectiveType(){return r.Types.Number}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return this.model.value.toString()}release(){}toString(){return this.model.value.toString()}}},{t:r.Types.String,f:class{constructor(a,o){this.model={address:a.address,type:r.Types.String,value:o}}get value(){return this.model.value}set value(a){this.model.value=a}get type(){return r.Types.String}get effectiveType(){return r.Types.String}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return`"${this.model.value.replace(/"/g,'""')}"`}release(){}toString(){return this.model.value}}},{t:r.Types.Date,f:class{constructor(a,o){this.model={address:a.address,type:r.Types.Date,value:o}}get value(){return this.model.value}set value(a){this.model.value=a}get type(){return r.Types.Date}get effectiveType(){return r.Types.Date}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return this.model.value.toISOString()}release(){}toString(){return this.model.value.toString()}}},{t:r.Types.Hyperlink,f:class{constructor(a,o){this.model={address:a.address,type:r.Types.Hyperlink,text:o?o.text:void 0,hyperlink:o?o.hyperlink:void 0},o&&o.tooltip&&(this.model.tooltip=o.tooltip)}get value(){const a={text:this.model.text,hyperlink:this.model.hyperlink};return this.model.tooltip&&(a.tooltip=this.model.tooltip),a}set value(a){this.model={text:a.text,hyperlink:a.hyperlink},a.tooltip&&(this.model.tooltip=a.tooltip)}get text(){return this.model.text}set text(a){this.model.text=a}get hyperlink(){return this.model.hyperlink}set hyperlink(a){this.model.hyperlink=a}get type(){return r.Types.Hyperlink}get effectiveType(){return r.Types.Hyperlink}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return this.model.hyperlink}release(){}toString(){return this.model.text}}},{t:r.Types.Formula,f:class{constructor(a,o){this.cell=a,this.model={address:a.address,type:r.Types.Formula,shareType:o?o.shareType:void 0,ref:o?o.ref:void 0,formula:o?o.formula:void 0,sharedFormula:o?o.sharedFormula:void 0,result:o?o.result:void 0}}_copyModel(a){const o={},f=h=>{const d=a[h];d&&(o[h]=d)};return f("formula"),f("result"),f("ref"),f("shareType"),f("sharedFormula"),o}get value(){return this._copyModel(this.model)}set value(a){this.model=this._copyModel(a)}validate(a){switch(u.getType(a)){case r.Types.Null:case r.Types.String:case r.Types.Number:case r.Types.Date:break;case r.Types.Hyperlink:case r.Types.Formula:default:throw new Error("Cannot process that type of result value")}}get dependencies(){return{ranges:this.formula.match(/([a-zA-Z0-9]+!)?[A-Z]{1,3}\d{1,4}:[A-Z]{1,3}\d{1,4}/g),cells:this.formula.replace(/([a-zA-Z0-9]+!)?[A-Z]{1,3}\d{1,4}:[A-Z]{1,3}\d{1,4}/g,"").match(/([a-zA-Z0-9]+!)?[A-Z]{1,3}\d{1,4}/g)}}get formula(){return this.model.formula||this._getTranslatedFormula()}set formula(a){this.model.formula=a}get formulaType(){return this.model.formula?s.FormulaType.Master:this.model.sharedFormula?s.FormulaType.Shared:s.FormulaType.None}get result(){return this.model.result}set result(a){this.model.result=a}get type(){return r.Types.Formula}get effectiveType(){const a=this.model.result;return a==null?s.ValueType.Null:a instanceof String||typeof a=="string"?s.ValueType.String:typeof a=="number"?s.ValueType.Number:a instanceof Date?s.ValueType.Date:a.text&&a.hyperlink?s.ValueType.Hyperlink:a.formula?s.ValueType.Formula:s.ValueType.Null}get address(){return this.model.address}set address(a){this.model.address=a}_getTranslatedFormula(){if(!this._translatedFormula&&this.model.sharedFormula){const{worksheet:a}=this.cell,o=a.findCell(this.model.sharedFormula);this._translatedFormula=o&&n(o.formula,o.address,this.model.address)}return this._translatedFormula}toCsvString(){return""+(this.model.result||"")}release(){}toString(){return this.model.result?this.model.result.toString():""}}},{t:r.Types.Merge,f:class{constructor(a,o){this.model={address:a.address,type:r.Types.Merge,master:o?o.address:void 0},this._master=o,o&&o.addMergeRef()}get value(){return this._master.value}set value(a){a instanceof r?(this._master&&this._master.releaseMergeRef(),a.addMergeRef(),this._master=a):this._master.value=a}isMergedTo(a){return a===this._master}get master(){return this._master}get type(){return r.Types.Merge}get effectiveType(){return this._master.effectiveType}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return""}release(){this._master.releaseMergeRef()}toString(){return this.value.toString()}}},{t:r.Types.JSON,f:class{constructor(a,o){this.model={address:a.address,type:r.Types.String,value:JSON.stringify(o),rawValue:o}}get value(){return this.model.rawValue}set value(a){this.model.rawValue=a,this.model.value=JSON.stringify(a)}get type(){return r.Types.String}get effectiveType(){return r.Types.String}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return this.model.value}release(){}toString(){return this.model.value}}},{t:r.Types.SharedString,f:class{constructor(a,o){this.model={address:a.address,type:r.Types.SharedString,value:o}}get value(){return this.model.value}set value(a){this.model.value=a}get type(){return r.Types.SharedString}get effectiveType(){return r.Types.SharedString}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return this.model.value.toString()}release(){}toString(){return this.model.value.toString()}}},{t:r.Types.RichText,f:class{constructor(a,o){this.model={address:a.address,type:r.Types.String,value:o}}get value(){return this.model.value}set value(a){this.model.value=a}toString(){return this.model.value.richText.map(a=>a.text).join("")}get type(){return r.Types.RichText}get effectiveType(){return r.Types.RichText}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return`"${this.text.replace(/"/g,'""')}"`}release(){}}},{t:r.Types.Boolean,f:class{constructor(a,o){this.model={address:a.address,type:r.Types.Boolean,value:o}}get value(){return this.model.value}set value(a){this.model.value=a}get type(){return r.Types.Boolean}get effectiveType(){return r.Types.Boolean}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return this.model.value?1:0}release(){}toString(){return this.model.value.toString()}}},{t:r.Types.Error,f:class{constructor(a,o){this.model={address:a.address,type:r.Types.Error,value:o}}get value(){return this.model.value}set value(a){this.model.value=a}get type(){return r.Types.Error}get effectiveType(){return r.Types.Error}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return this.toString()}release(){}toString(){return this.model.value.error.toString()}}}].reduce((a,o)=>(a[o.t]=o.f,a),[]),create(a,o,f){const h=this.types[a];if(!h)throw new Error("Could not create Value of type "+a);return new h(o,f)}};b.exports=r},{"../utils/col-cache":19,"../utils/shared-formula":23,"../utils/under-dash":26,"./enums":7,"./note":9}],4:[function(t,b,m){const c=t("../utils/under-dash"),i=t("./enums"),s=t("../utils/col-cache");class n{constructor(r,u,a){this._worksheet=r,this._number=u,a!==!1&&(this.defn=a)}get number(){return this._number}get worksheet(){return this._worksheet}get letter(){return s.n2l(this._number)}get isCustomWidth(){return this.width!==void 0&&this.width!==9}get defn(){return{header:this._header,key:this.key,width:this.width,style:this.style,hidden:this.hidden,outlineLevel:this.outlineLevel}}set defn(r){r?(this.key=r.key,this.width=r.width!==void 0?r.width:9,this.outlineLevel=r.outlineLevel,r.style?this.style=r.style:this.style={},this.header=r.header,this._hidden=!!r.hidden):(delete this._header,delete this._key,delete this.width,this.style={},this.outlineLevel=0)}get headers(){return this._header&&this._header instanceof Array?this._header:[this._header]}get header(){return this._header}set header(r){r!==void 0?(this._header=r,this.headers.forEach((u,a)=>{this._worksheet.getCell(a+1,this.number).value=u})):this._header=void 0}get key(){return this._key}set key(r){(this._key&&this._worksheet.getColumnKey(this._key))===this&&this._worksheet.deleteColumnKey(this._key),this._key=r,r&&this._worksheet.setColumnKey(this._key,this)}get hidden(){return!!this._hidden}set hidden(r){this._hidden=r}get outlineLevel(){return this._outlineLevel||0}set outlineLevel(r){this._outlineLevel=r}get collapsed(){return!!(this._outlineLevel&&this._outlineLevel>=this._worksheet.properties.outlineLevelCol)}toString(){return JSON.stringify({key:this.key,width:this.width,headers:this.headers.length?this.headers:void 0})}equivalentTo(r){return this.width===r.width&&this.hidden===r.hidden&&this.outlineLevel===r.outlineLevel&&c.isEqual(this.style,r.style)}get isDefault(){if(this.isCustomWidth||this.hidden||this.outlineLevel)return!1;const r=this.style;return!r||!(r.font||r.numFmt||r.alignment||r.border||r.fill||r.protection)}get headerCount(){return this.headers.length}eachCell(r,u){const a=this.number;u||(u=r,r=null),this._worksheet.eachRow(r,(o,f)=>{u(o.getCell(a),f)})}get values(){const r=[];return this.eachCell((u,a)=>{u&&u.type!==i.ValueType.Null&&(r[a]=u.value)}),r}set values(r){if(!r)return;const u=this.number;let a=0;r.hasOwnProperty("0")&&(a=1),r.forEach((o,f)=>{this._worksheet.getCell(f+a,u).value=o})}_applyStyle(r,u){return this.style[r]=u,this.eachCell(a=>{a[r]=u}),u}get numFmt(){return this.style.numFmt}set numFmt(r){this._applyStyle("numFmt",r)}get font(){return this.style.font}set font(r){this._applyStyle("font",r)}get alignment(){return this.style.alignment}set alignment(r){this._applyStyle("alignment",r)}get protection(){return this.style.protection}set protection(r){this._applyStyle("protection",r)}get border(){return this.style.border}set border(r){this._applyStyle("border",r)}get fill(){return this.style.fill}set fill(r){this._applyStyle("fill",r)}static toModel(r){const u=[];let a=null;return r&&r.forEach((o,f)=>{o.isDefault?a&&(a=null):a&&o.equivalentTo(a)?a.max=f+1:(a={min:f+1,max:f+1,width:o.width!==void 0?o.width:9,style:o.style,isCustomWidth:o.isCustomWidth,hidden:o.hidden,outlineLevel:o.outlineLevel,collapsed:o.collapsed},u.push(a))}),u.length?u:void 0}static fromModel(r,u){const a=[];let o=1,f=0;for(u=(u=u||[]).sort(function(h,d){return h.min-d.min});f<u.length;){const h=u[f++];for(;o<h.min;)a.push(new n(r,o++));for(;o<=h.max;)a.push(new n(r,o++,h))}return a.length?a:null}}b.exports=n},{"../utils/col-cache":19,"../utils/under-dash":26,"./enums":7}],5:[function(t,b,m){b.exports=class{constructor(c){this.model=c||{}}add(c,i){return this.model[c]=i}find(c){return this.model[c]}remove(c){this.model[c]=void 0}}},{}],6:[function(t,b,m){const c=t("../utils/under-dash"),i=t("../utils/col-cache"),s=t("../utils/cell-matrix"),n=t("./range"),e=/[$](\w+)[$](\d+)(:[$](\w+)[$](\d+))?/;b.exports=class{constructor(){this.matrixMap={}}getMatrix(r){return this.matrixMap[r]||(this.matrixMap[r]=new s)}add(r,u){const a=i.decodeEx(r);this.addEx(a,u)}addEx(r,u){const a=this.getMatrix(u);if(r.top)for(let o=r.left;o<=r.right;o++)for(let f=r.top;f<=r.bottom;f++){const h={sheetName:r.sheetName,address:i.n2l(o)+f,row:f,col:o};a.addCellEx(h)}else a.addCellEx(r)}remove(r,u){const a=i.decodeEx(r);this.removeEx(a,u)}removeEx(r,u){this.getMatrix(u).removeCellEx(r)}removeAllNames(r){c.each(this.matrixMap,u=>{u.removeCellEx(r)})}forEach(r){c.each(this.matrixMap,(u,a)=>{u.forEach(o=>{r(a,o)})})}getNames(r){return this.getNamesEx(i.decodeEx(r))}getNamesEx(r){return c.map(this.matrixMap,(u,a)=>u.findCellEx(r)&&a).filter(Boolean)}_explore(r,u){u.mark=!1;const{sheetName:a}=u,o=new n(u.row,u.col,u.row,u.col,a);let f,h;function d(p,k){const C=r.findCellAt(a,p,u.col);return!(!C||!C.mark)&&(o[k]=p,C.mark=!1,!0)}for(h=u.row-1;d(h,"top");h--);for(h=u.row+1;d(h,"bottom");h++);function g(p,k){const C=[];for(h=o.top;h<=o.bottom;h++){const T=r.findCellAt(a,h,p);if(!T||!T.mark)return!1;C.push(T)}o[k]=p;for(let T=0;T<C.length;T++)C[T].mark=!1;return!0}for(f=u.col-1;g(f,"left");f--);for(f=u.col+1;g(f,"right");f++);return o}getRanges(r,u){return(u=u||this.matrixMap[r])?(u.forEach(a=>{a.mark=!0}),{name:r,ranges:u.map(a=>a.mark&&this._explore(u,a)).filter(Boolean).map(a=>a.$shortRange)}):{name:r,ranges:[]}}normaliseMatrix(r,u){r.forEachInSheet(u,(a,o,f)=>{a&&(a.row===o&&a.col===f||(a.row=o,a.col=f,a.address=i.n2l(f)+o))})}spliceRows(r,u,a,o){c.each(this.matrixMap,f=>{f.spliceRows(r,u,a,o),this.normaliseMatrix(f,r)})}spliceColumns(r,u,a,o){c.each(this.matrixMap,f=>{f.spliceColumns(r,u,a,o),this.normaliseMatrix(f,r)})}get model(){return c.map(this.matrixMap,(r,u)=>this.getRanges(u,r)).filter(r=>r.ranges.length)}set model(r){const u=this.matrixMap={};r.forEach(a=>{const o=u[a.name]=new s;a.ranges.forEach(f=>{e.test(f.split("!").pop()||"")&&o.addCell(f)})})}}},{"../utils/cell-matrix":18,"../utils/col-cache":19,"../utils/under-dash":26,"./range":10}],7:[function(t,b,m){b.exports={ValueType:{Null:0,Merge:1,Number:2,String:3,Date:4,Hyperlink:5,Formula:6,SharedString:7,RichText:8,Boolean:9,Error:10},FormulaType:{None:0,Master:1,Shared:2},RelationshipType:{None:0,OfficeDocument:1,Worksheet:2,CalcChain:3,SharedStrings:4,Styles:5,Theme:6,Hyperlink:7},DocumentType:{Xlsx:1},ReadingOrder:{LeftToRight:1,RightToLeft:2},ErrorValue:{NotApplicable:"#N/A",Ref:"#REF!",Name:"#NAME?",DivZero:"#DIV/0!",Null:"#NULL!",Value:"#VALUE!",Num:"#NUM!"}}},{}],8:[function(t,b,m){const c=t("../utils/col-cache"),i=t("./anchor");b.exports=class{constructor(s,n){this.worksheet=s,this.model=n}get model(){switch(this.type){case"background":return{type:this.type,imageId:this.imageId};case"image":return{type:this.type,imageId:this.imageId,hyperlinks:this.range.hyperlinks,range:{tl:this.range.tl.model,br:this.range.br&&this.range.br.model,ext:this.range.ext,editAs:this.range.editAs}};default:throw new Error("Invalid Image Type")}}set model(s){let{type:n,imageId:e,range:r,hyperlinks:u}=s;if(this.type=n,this.imageId=e,n==="image")if(typeof r=="string"){const a=c.decode(r);this.range={tl:new i(this.worksheet,{col:a.left,row:a.top},-1),br:new i(this.worksheet,{col:a.right,row:a.bottom},0),editAs:"oneCell"}}else this.range={tl:new i(this.worksheet,r.tl,0),br:r.br&&new i(this.worksheet,r.br,0),ext:r.ext,editAs:r.editAs,hyperlinks:u||r.hyperlinks}}}},{"../utils/col-cache":19,"./anchor":2}],9:[function(t,b,m){const c=t("../utils/under-dash");class i{constructor(n){this.note=n}get model(){let n=null;switch(typeof this.note){case"string":n={type:"note",note:{texts:[{text:this.note}]}};break;default:n={type:"note",note:this.note}}return c.deepMerge({},i.DEFAULT_CONFIGS,n)}set model(n){const{note:e}=n,{texts:r}=e;r.length===1&&Object.keys(r[0]).length===1?this.note=r[0].text:this.note=e}static fromModel(n){const e=new i;return e.model=n,e}}i.DEFAULT_CONFIGS={note:{margins:{insetmode:"auto",inset:[.13,.13,.25,.25]},protection:{locked:"True",lockText:"True"},editAs:"absolute"}},b.exports=i},{"../utils/under-dash":26}],10:[function(t,b,m){const c=t("../utils/col-cache");class i{constructor(){this.decode(arguments)}setTLBR(n,e,r,u,a){if(arguments.length<4){const o=c.decodeAddress(n),f=c.decodeAddress(e);this.model={top:Math.min(o.row,f.row),left:Math.min(o.col,f.col),bottom:Math.max(o.row,f.row),right:Math.max(o.col,f.col),sheetName:r},this.setTLBR(o.row,o.col,f.row,f.col,a)}else this.model={top:Math.min(n,r),left:Math.min(e,u),bottom:Math.max(n,r),right:Math.max(e,u),sheetName:a}}decode(n){switch(n.length){case 5:this.setTLBR(n[0],n[1],n[2],n[3],n[4]);break;case 4:this.setTLBR(n[0],n[1],n[2],n[3]);break;case 3:this.setTLBR(n[0],n[1],n[2]);break;case 2:this.setTLBR(n[0],n[1]);break;case 1:{const e=n[0];if(e instanceof i)this.model={top:e.model.top,left:e.model.left,bottom:e.model.bottom,right:e.model.right,sheetName:e.sheetName};else if(e instanceof Array)this.decode(e);else if(e.top&&e.left&&e.bottom&&e.right)this.model={top:e.top,left:e.left,bottom:e.bottom,right:e.right,sheetName:e.sheetName};else{const r=c.decodeEx(e);r.top?this.model={top:r.top,left:r.left,bottom:r.bottom,right:r.right,sheetName:r.sheetName}:this.model={top:r.row,left:r.col,bottom:r.row,right:r.col,sheetName:r.sheetName}}break}case 0:this.model={top:0,left:0,bottom:0,right:0};break;default:throw new Error("Invalid number of arguments to _getDimensions() - "+n.length)}}get top(){return this.model.top||1}set top(n){this.model.top=n}get left(){return this.model.left||1}set left(n){this.model.left=n}get bottom(){return this.model.bottom||1}set bottom(n){this.model.bottom=n}get right(){return this.model.right||1}set right(n){this.model.right=n}get sheetName(){return this.model.sheetName}set sheetName(n){this.model.sheetName=n}get _serialisedSheetName(){const{sheetName:n}=this.model;return n?/^[a-zA-Z0-9]*$/.test(n)?n+"!":`'${n}'!`:""}expand(n,e,r,u){(!this.model.top||n<this.top)&&(this.top=n),(!this.model.left||e<this.left)&&(this.left=e),(!this.model.bottom||r>this.bottom)&&(this.bottom=r),(!this.model.right||u>this.right)&&(this.right=u)}expandRow(n){if(n){const{dimensions:e,number:r}=n;e&&this.expand(r,e.min,r,e.max)}}expandToAddress(n){const e=c.decodeEx(n);this.expand(e.row,e.col,e.row,e.col)}get tl(){return c.n2l(this.left)+this.top}get $t$l(){return`$${c.n2l(this.left)}$${this.top}`}get br(){return c.n2l(this.right)+this.bottom}get $b$r(){return`$${c.n2l(this.right)}$${this.bottom}`}get range(){return`${this._serialisedSheetName+this.tl}:${this.br}`}get $range(){return`${this._serialisedSheetName+this.$t$l}:${this.$b$r}`}get shortRange(){return this.count>1?this.range:this._serialisedSheetName+this.tl}get $shortRange(){return this.count>1?this.$range:this._serialisedSheetName+this.$t$l}get count(){return(1+this.bottom-this.top)*(1+this.right-this.left)}toString(){return this.range}intersects(n){return(!n.sheetName||!this.sheetName||n.sheetName===this.sheetName)&&!(n.bottom<this.top)&&!(n.top>this.bottom)&&!(n.right<this.left)&&!(n.left>this.right)}contains(n){const e=c.decodeEx(n);return this.containsEx(e)}containsEx(n){return(!n.sheetName||!this.sheetName||n.sheetName===this.sheetName)&&n.row>=this.top&&n.row<=this.bottom&&n.col>=this.left&&n.col<=this.right}forEachAddress(n){for(let e=this.left;e<=this.right;e++)for(let r=this.top;r<=this.bottom;r++)n(c.encodeAddress(r,e),r,e)}}b.exports=i},{"../utils/col-cache":19}],11:[function(t,b,m){const c=t("../utils/under-dash"),i=t("./enums"),s=t("../utils/col-cache"),n=t("./cell");b.exports=class{constructor(e,r){this._worksheet=e,this._number=r,this._cells=[],this.style={},this.outlineLevel=0}get number(){return this._number}get worksheet(){return this._worksheet}commit(){this._worksheet._commitRow(this)}destroy(){delete this._worksheet,delete this._cells,delete this.style}findCell(e){return this._cells[e-1]}getCellEx(e){let r=this._cells[e.col-1];if(!r){const u=this._worksheet.getColumn(e.col);r=new n(this,u,e.address),this._cells[e.col-1]=r}return r}getCell(e){if(typeof e=="string"){const r=this._worksheet.getColumnKey(e);e=r?r.number:s.l2n(e)}return this._cells[e-1]||this.getCellEx({address:s.encodeAddress(this._number,e),row:this._number,col:e})}splice(e,r){const u=e+r;for(var a=arguments.length,o=new Array(a>2?a-2:0),f=2;f<a;f++)o[f-2]=arguments[f];const h=o.length-r,d=this._cells.length;let g,p,k;if(h<0)for(g=e+o.length;g<=d;g++)k=this._cells[g-1],p=this._cells[g-h-1],p?(k=this.getCell(g),k.value=p.value,k.style=p.style,k._comment=p._comment):k&&(k.value=null,k.style={},k._comment=void 0);else if(h>0)for(g=d;g>=u;g--)p=this._cells[g-1],p?(k=this.getCell(g+h),k.value=p.value,k.style=p.style,k._comment=p._comment):this._cells[g+h-1]=void 0;for(g=0;g<o.length;g++)k=this.getCell(e+g),k.value=o[g],k.style={},k._comment=void 0}eachCell(e,r){if(r||(r=e,e=null),e&&e.includeEmpty){const u=this._cells.length;for(let a=1;a<=u;a++)r(this.getCell(a),a)}else this._cells.forEach((u,a)=>{u&&u.type!==i.ValueType.Null&&r(u,a+1)})}addPageBreak(e,r){const u=this._worksheet,a=Math.max(0,e-1)||0,o=Math.max(0,r-1)||16838,f={id:this._number,max:o,man:1};a&&(f.min=a),u.rowBreaks.push(f)}get values(){const e=[];return this._cells.forEach(r=>{r&&r.type!==i.ValueType.Null&&(e[r.col]=r.value)}),e}set values(e){if(this._cells=[],e)if(e instanceof Array){let r=0;e.hasOwnProperty("0")&&(r=1),e.forEach((u,a)=>{u!==void 0&&(this.getCellEx({address:s.encodeAddress(this._number,a+r),row:this._number,col:a+r}).value=u)})}else this._worksheet.eachColumnKey((r,u)=>{e[u]!==void 0&&(this.getCellEx({address:s.encodeAddress(this._number,r.number),row:this._number,col:r.number}).value=e[u])})}get hasValues(){return c.some(this._cells,e=>e&&e.type!==i.ValueType.Null)}get cellCount(){return this._cells.length}get actualCellCount(){let e=0;return this.eachCell(()=>{e++}),e}get dimensions(){let e=0,r=0;return this._cells.forEach(u=>{u&&u.type!==i.ValueType.Null&&((!e||e>u.col)&&(e=u.col),r<u.col&&(r=u.col))}),e>0?{min:e,max:r}:null}_applyStyle(e,r){return this.style[e]=r,this._cells.forEach(u=>{u&&(u[e]=r)}),r}get numFmt(){return this.style.numFmt}set numFmt(e){this._applyStyle("numFmt",e)}get font(){return this.style.font}set font(e){this._applyStyle("font",e)}get alignment(){return this.style.alignment}set alignment(e){this._applyStyle("alignment",e)}get protection(){return this.style.protection}set protection(e){this._applyStyle("protection",e)}get border(){return this.style.border}set border(e){this._applyStyle("border",e)}get fill(){return this.style.fill}set fill(e){this._applyStyle("fill",e)}get hidden(){return!!this._hidden}set hidden(e){this._hidden=e}get outlineLevel(){return this._outlineLevel||0}set outlineLevel(e){this._outlineLevel=e}get collapsed(){return!!(this._outlineLevel&&this._outlineLevel>=this._worksheet.properties.outlineLevelRow)}get model(){const e=[];let r=0,u=0;return this._cells.forEach(a=>{if(a){const o=a.model;o&&((!r||r>a.col)&&(r=a.col),u<a.col&&(u=a.col),e.push(o))}}),this.height||e.length?{cells:e,number:this.number,min:r,max:u,height:this.height,style:this.style,hidden:this.hidden,outlineLevel:this.outlineLevel,collapsed:this.collapsed}:null}set model(e){if(e.number!==this._number)throw new Error("Invalid row number in model");let r;this._cells=[],e.cells.forEach(u=>{switch(u.type){case n.Types.Merge:break;default:{let a;if(u.address)a=s.decodeAddress(u.address);else if(r){const{row:o}=r,f=r.col+1;a={row:o,col:f,address:s.encodeAddress(o,f),$col$row:`$${s.n2l(f)}$${o}`}}r=a,this.getCellEx(a).model=u;break}}}),e.height?this.height=e.height:delete this.height,this.hidden=e.hidden,this.outlineLevel=e.outlineLevel||0,this.style=e.style&&JSON.parse(JSON.stringify(e.style))||{}}}},{"../utils/col-cache":19,"../utils/under-dash":26,"./cell":3,"./enums":7}],12:[function(t,b,m){const c=t("../utils/col-cache");class i{constructor(n,e,r){this.table=n,this.column=e,this.index=r}_set(n,e){this.table.cacheState(),this.column[n]=e}get name(){return this.column.name}set name(n){this._set("name",n)}get filterButton(){return this.column.filterButton}set filterButton(n){this.column.filterButton=n}get style(){return this.column.style}set style(n){this.column.style=n}get totalsRowLabel(){return this.column.totalsRowLabel}set totalsRowLabel(n){this._set("totalsRowLabel",n)}get totalsRowFunction(){return this.column.totalsRowFunction}set totalsRowFunction(n){this._set("totalsRowFunction",n)}get totalsRowResult(){return this.column.totalsRowResult}set totalsRowResult(n){this._set("totalsRowResult",n)}get totalsRowFormula(){return this.column.totalsRowFormula}set totalsRowFormula(n){this._set("totalsRowFormula",n)}}b.exports=class{constructor(s,n){this.worksheet=s,n&&(this.table=n,this.validate(),this.store())}getFormula(s){switch(s.totalsRowFunction){case"none":return null;case"average":return`SUBTOTAL(101,${this.table.name}[${s.name}])`;case"countNums":return`SUBTOTAL(102,${this.table.name}[${s.name}])`;case"count":return`SUBTOTAL(103,${this.table.name}[${s.name}])`;case"max":return`SUBTOTAL(104,${this.table.name}[${s.name}])`;case"min":return`SUBTOTAL(105,${this.table.name}[${s.name}])`;case"stdDev":return`SUBTOTAL(106,${this.table.name}[${s.name}])`;case"var":return`SUBTOTAL(107,${this.table.name}[${s.name}])`;case"sum":return`SUBTOTAL(109,${this.table.name}[${s.name}])`;case"custom":return s.totalsRowFormula;default:throw new Error("Invalid Totals Row Function: "+s.totalsRowFunction)}}get width(){return this.table.columns.length}get height(){return this.table.rows.length}get filterHeight(){return this.height+(this.table.headerRow?1:0)}get tableHeight(){return this.filterHeight+(this.table.totalsRow?1:0)}validate(){const{table:s}=this,n=(h,d,g)=>{h[d]===void 0&&(h[d]=g)};n(s,"headerRow",!0),n(s,"totalsRow",!1),n(s,"style",{}),n(s.style,"theme","TableStyleMedium2"),n(s.style,"showFirstColumn",!1),n(s.style,"showLastColumn",!1),n(s.style,"showRowStripes",!1),n(s.style,"showColumnStripes",!1);const e=(h,d)=>{if(!h)throw new Error(d)};e(s.ref,"Table must have ref"),e(s.columns,"Table must have column definitions"),e(s.rows,"Table must have row definitions"),s.tl=c.decodeAddress(s.ref);const{row:r,col:u}=s.tl;e(r>0,"Table must be on valid row"),e(u>0,"Table must be on valid col");const{width:a,filterHeight:o,tableHeight:f}=this;s.autoFilterRef=c.encode(r,u,r+o-1,u+a-1),s.tableRef=c.encode(r,u,r+f-1,u+a-1),s.columns.forEach((h,d)=>{e(h.name,`Column ${d} must have a name`),d===0?n(h,"totalsRowLabel","Total"):(n(h,"totalsRowFunction","none"),h.totalsRowFormula=this.getFormula(h))})}store(){const s=(o,f)=>{f&&Object.keys(f).forEach(h=>{o[h]=f[h]})},{worksheet:n,table:e}=this,{row:r,col:u}=e.tl;let a=0;if(e.headerRow){const o=n.getRow(r+a++);e.columns.forEach((f,h)=>{const{style:d,name:g}=f,p=o.getCell(u+h);p.value=g,s(p,d)})}if(e.rows.forEach(o=>{const f=n.getRow(r+a++);o.forEach((h,d)=>{const g=f.getCell(u+d);g.value=h,s(g,e.columns[d].style)})}),e.totalsRow){const o=n.getRow(r+a++);e.columns.forEach((f,h)=>{const d=o.getCell(u+h);if(h===0)d.value=f.totalsRowLabel;else{const g=this.getFormula(f);d.value=g?{formula:f.totalsRowFormula,result:f.totalsRowResult}:null}s(d,f.style)})}}load(s){const{table:n}=this,{row:e,col:r}=n.tl;let u=0;if(n.headerRow){const a=s.getRow(e+u++);n.columns.forEach((o,f)=>{a.getCell(r+f).value=o.name})}if(n.rows.forEach(a=>{const o=s.getRow(e+u++);a.forEach((f,h)=>{o.getCell(r+h).value=f})}),n.totalsRow){const a=s.getRow(e+u++);n.columns.forEach((o,f)=>{const h=a.getCell(r+f);f===0?h.value=o.totalsRowLabel:this.getFormula(o)&&(h.value={formula:o.totalsRowFormula,result:o.totalsRowResult})})}}get model(){return this.table}set model(s){this.table=s}cacheState(){this._cache||(this._cache={ref:this.ref,width:this.width,tableHeight:this.tableHeight})}commit(){if(!this._cache)return;this.validate();const s=c.decodeAddress(this._cache.ref);if(this.ref!==this._cache.ref)for(let n=0;n<this._cache.tableHeight;n++){const e=this.worksheet.getRow(s.row+n);for(let r=0;r<this._cache.width;r++)e.getCell(s.col+r).value=null}else{for(let n=this.tableHeight;n<this._cache.tableHeight;n++){const e=this.worksheet.getRow(s.row+n);for(let r=0;r<this._cache.width;r++)e.getCell(s.col+r).value=null}for(let n=0;n<this.tableHeight;n++){const e=this.worksheet.getRow(s.row+n);for(let r=this.width;r<this._cache.width;r++)e.getCell(s.col+r).value=null}}this.store()}addRow(s,n){this.cacheState(),n===void 0?this.table.rows.push(s):this.table.rows.splice(n,0,s)}removeRows(s){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;this.cacheState(),this.table.rows.splice(s,n)}getColumn(s){const n=this.table.columns[s];return new i(this,n,s)}addColumn(s,n,e){this.cacheState(),e===void 0?(this.table.columns.push(s),this.table.rows.forEach((r,u)=>{r.push(n[u])})):(this.table.columns.splice(e,0,s),this.table.rows.forEach((r,u)=>{r.splice(e,0,n[u])}))}removeColumns(s){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;this.cacheState(),this.table.columns.splice(s,n),this.table.rows.forEach(e=>{e.splice(s,n)})}_assign(s,n,e){this.cacheState(),s[n]=e}get ref(){return this.table.ref}set ref(s){this._assign(this.table,"ref",s)}get name(){return this.table.name}set name(s){this.table.name=s}get displayName(){return this.table.displyName||this.table.name}set displayNamename(s){this.table.displayName=s}get headerRow(){return this.table.headerRow}set headerRow(s){this._assign(this.table,"headerRow",s)}get totalsRow(){return this.table.totalsRow}set totalsRow(s){this._assign(this.table,"totalsRow",s)}get theme(){return this.table.style.name}set theme(s){this.table.style.name=s}get showFirstColumn(){return this.table.style.showFirstColumn}set showFirstColumn(s){this.table.style.showFirstColumn=s}get showLastColumn(){return this.table.style.showLastColumn}set showLastColumn(s){this.table.style.showLastColumn=s}get showRowStripes(){return this.table.style.showRowStripes}set showRowStripes(s){this.table.style.showRowStripes=s}get showColumnStripes(){return this.table.style.showColumnStripes}set showColumnStripes(s){this.table.style.showColumnStripes=s}}},{"../utils/col-cache":19}],13:[function(t,b,m){const c=t("./worksheet"),i=t("./defined-names"),s=t("../xlsx/xlsx"),n=t("../csv/csv");b.exports=class{constructor(){this.category="",this.company="",this.created=new Date,this.description="",this.keywords="",this.manager="",this.modified=this.created,this.properties={},this.calcProperties={},this._worksheets=[],this.subject="",this.title="",this.views=[],this.media=[],this._definedNames=new i}get xlsx(){return this._xlsx||(this._xlsx=new s(this)),this._xlsx}get csv(){return this._csv||(this._csv=new n(this)),this._csv}get nextId(){for(let e=1;e<this._worksheets.length;e++)if(!this._worksheets[e])return e;return this._worksheets.length||1}addWorksheet(e,r){const u=this.nextId;r&&(typeof r=="string"?(console.trace('tabColor argument is now deprecated. Please use workbook.addWorksheet(name, {properties: { tabColor: { argb: "rbg value" } }'),r={properties:{tabColor:{argb:r}}}):(r.argb||r.theme||r.indexed)&&(console.trace("tabColor argument is now deprecated. Please use workbook.addWorksheet(name, {properties: { tabColor: { ... } }"),r={properties:{tabColor:r}}));const a=this._worksheets.reduce((h,d)=>(d&&d.orderNo)>h?d.orderNo:h,0),o=Object.assign({},r,{id:u,name:e,orderNo:a+1,workbook:this}),f=new c(o);return this._worksheets[u]=f,f}removeWorksheetEx(e){delete this._worksheets[e.id]}removeWorksheet(e){const r=this.getWorksheet(e);r&&r.destroy()}getWorksheet(e){return e===void 0?this._worksheets.find(Boolean):typeof e=="number"?this._worksheets[e]:typeof e=="string"?this._worksheets.find(r=>r&&r.name===e):void 0}get worksheets(){return this._worksheets.slice(1).sort((e,r)=>e.orderNo-r.orderNo).filter(Boolean)}eachSheet(e){this.worksheets.forEach(r=>{e(r,r.id)})}get definedNames(){return this._definedNames}clearThemes(){this._themes=void 0}addImage(e){const r=this.media.length;return this.media.push(Object.assign({},e,{type:"image"})),r}getImage(e){return this.media[e]}get model(){return{creator:this.creator||"Unknown",lastModifiedBy:this.lastModifiedBy||"Unknown",lastPrinted:this.lastPrinted,created:this.created,modified:this.modified,properties:this.properties,worksheets:this.worksheets.map(e=>e.model),sheets:this.worksheets.map(e=>e.model).filter(Boolean),definedNames:this._definedNames.model,views:this.views,company:this.company,manager:this.manager,title:this.title,subject:this.subject,keywords:this.keywords,category:this.category,description:this.description,language:this.language,revision:this.revision,contentStatus:this.contentStatus,themes:this._themes,media:this.media,calcProperties:this.calcProperties}}set model(e){this.creator=e.creator,this.lastModifiedBy=e.lastModifiedBy,this.lastPrinted=e.lastPrinted,this.created=e.created,this.modified=e.modified,this.company=e.company,this.manager=e.manager,this.title=e.title,this.subject=e.subject,this.keywords=e.keywords,this.category=e.category,this.description=e.description,this.language=e.language,this.revision=e.revision,this.contentStatus=e.contentStatus,this.properties=e.properties,this.calcProperties=e.calcProperties,this._worksheets=[],e.worksheets.forEach(r=>{const{id:u,name:a,state:o}=r,f=e.sheets&&e.sheets.findIndex(h=>h.id===u);(this._worksheets[u]=new c({id:u,name:a,orderNo:f,state:o,workbook:this})).model=r}),this._definedNames.model=e.definedNames,this.views=e.views,this._themes=e.themes,this.media=e.media||[]}}},{"../csv/csv":1,"../xlsx/xlsx":144,"./defined-names":6,"./worksheet":14}],14:[function(t,b,m){const c=t("../utils/under-dash"),i=t("../utils/col-cache"),s=t("./range"),n=t("./row"),e=t("./column"),r=t("./enums"),u=t("./image"),a=t("./table"),o=t("./data-validations"),f=t("../utils/encryptor"),{copyStyle:h}=t("../utils/copy-style");b.exports=class{constructor(d){d=d||{},this._workbook=d.workbook,this.id=d.id,this.orderNo=d.orderNo,this.name=d.name,this.state=d.state||"visible",this._rows=[],this._columns=null,this._keys={},this._merges={},this.rowBreaks=[],this.properties=Object.assign({},{defaultRowHeight:15,dyDescent:55,outlineLevelCol:0,outlineLevelRow:0},d.properties),this.pageSetup=Object.assign({},{margins:{left:.7,right:.7,top:.75,bottom:.75,header:.3,footer:.3},orientation:"portrait",horizontalDpi:4294967295,verticalDpi:4294967295,fitToPage:!(!d.pageSetup||!d.pageSetup.fitToWidth&&!d.pageSetup.fitToHeight||d.pageSetup.scale),pageOrder:"downThenOver",blackAndWhite:!1,draft:!1,cellComments:"None",errors:"displayed",scale:100,fitToWidth:1,fitToHeight:1,paperSize:void 0,showRowColHeaders:!1,showGridLines:!1,firstPageNumber:void 0,horizontalCentered:!1,verticalCentered:!1,rowBreaks:null,colBreaks:null},d.pageSetup),this.headerFooter=Object.assign({},{differentFirst:!1,differentOddEven:!1,oddHeader:null,oddFooter:null,evenHeader:null,evenFooter:null,firstHeader:null,firstFooter:null},d.headerFooter),this.dataValidations=new o,this.views=d.views||[],this.autoFilter=d.autoFilter||null,this._media=[],this.sheetProtection=null,this.tables={},this.conditionalFormattings=[]}get name(){return this._name}set name(d){if(d===void 0&&(d="sheet"+this.id),this._name!==d){if(typeof d!="string")throw new Error("The name has to be a string.");if(d==="")throw new Error("The name can't be empty.");if(d==="History")throw new Error('The name "History" is protected. Please use a different name.');if(/[*?:/\\[\]]/.test(d))throw new Error(`Worksheet name ${d} cannot include any of the following characters: * ? : \\ / [ ]`);if(/(^')|('$)/.test(d))throw new Error("The first or last character of worksheet name cannot be a single quotation mark: "+d);if(d&&d.length>31&&(console.warn(`Worksheet name ${d} exceeds 31 chars. This will be truncated`),d=d.substring(0,31)),this._workbook._worksheets.find(g=>g&&g.name.toLowerCase()===d.toLowerCase()))throw new Error("Worksheet name already exists: "+d);this._name=d}}get workbook(){return this._workbook}destroy(){this._workbook.removeWorksheetEx(this)}get dimensions(){const d=new s;return this._rows.forEach(g=>{if(g){const p=g.dimensions;p&&d.expand(g.number,p.min,g.number,p.max)}}),d}get columns(){return this._columns}set columns(d){this._headerRowCount=d.reduce((k,C)=>{const T=(C.header?1:C.headers&&C.headers.length)||0;return Math.max(k,T)},0);let g=1;const p=this._columns=[];d.forEach(k=>{const C=new e(this,g++,!1);p.push(C),C.defn=k})}getColumnKey(d){return this._keys[d]}setColumnKey(d,g){this._keys[d]=g}deleteColumnKey(d){delete this._keys[d]}eachColumnKey(d){c.each(this._keys,d)}getColumn(d){if(typeof d=="string"){const g=this._keys[d];if(g)return g;d=i.l2n(d)}if(this._columns||(this._columns=[]),d>this._columns.length){let g=this._columns.length+1;for(;g<=d;)this._columns.push(new e(this,g++))}return this._columns[d-1]}spliceColumns(d,g){const p=this._rows.length;for(var k=arguments.length,C=new Array(k>2?k-2:0),T=2;T<k;T++)C[T-2]=arguments[T];if(C.length>0)for(let N=0;N<p;N++){const q=[d,g];C.forEach(L=>{q.push(L[N]||null)});const W=this.getRow(N+1);W.splice.apply(W,q)}else this._rows.forEach(N=>{N&&N.splice(d,g)});const D=C.length-g,V=d+g,P=this._columns.length;if(D<0)for(let N=d+C.length;N<=P;N++)this.getColumn(N).defn=this.getColumn(N-D).defn;else if(D>0)for(let N=P;N>=V;N--)this.getColumn(N+D).defn=this.getColumn(N).defn;for(let N=d;N<d+C.length;N++)this.getColumn(N).defn=null;this.workbook.definedNames.spliceColumns(this.name,d,g,C.length)}get lastColumn(){return this.getColumn(this.columnCount)}get columnCount(){let d=0;return this.eachRow(g=>{d=Math.max(d,g.cellCount)}),d}get actualColumnCount(){const d=[];let g=0;return this.eachRow(p=>{p.eachCell(k=>{let{col:C}=k;d[C]||(d[C]=!0,g++)})}),g}_commitRow(){}get _lastRowNumber(){const d=this._rows;let g=d.length;for(;g>0&&d[g-1]===void 0;)g--;return g}get _nextRow(){return this._lastRowNumber+1}get lastRow(){if(this._rows.length)return this._rows[this._rows.length-1]}findRow(d){return this._rows[d-1]}findRows(d,g){return this._rows.slice(d-1,d-1+g)}get rowCount(){return this._lastRowNumber}get actualRowCount(){let d=0;return this.eachRow(()=>{d++}),d}getRow(d){let g=this._rows[d-1];return g||(g=this._rows[d-1]=new n(this,d)),g}getRows(d,g){if(g<1)return;const p=[];for(let k=d;k<d+g;k++)p.push(this.getRow(k));return p}addRow(d){let g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"n";const p=this._nextRow,k=this.getRow(p);return k.values=d,this._setStyleOption(p,g[0]==="i"?g:"n"),k}addRows(d){let g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"n";const p=[];return d.forEach(k=>{p.push(this.addRow(k,g))}),p}insertRow(d,g){let p=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"n";return this.spliceRows(d,0,g),this._setStyleOption(d,p),this.getRow(d)}insertRows(d,g){let p=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"n";if(this.spliceRows(d,0,...g),p!=="n")for(let k=0;k<g.length;k++)p[0]==="o"&&this.findRow(g.length+d+k)!==void 0?this._copyStyle(g.length+d+k,d+k,p[1]==="+"):p[0]==="i"&&this.findRow(d-1)!==void 0&&this._copyStyle(d-1,d+k,p[1]==="+");return this.getRows(d,g.length)}_setStyleOption(d){let g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"n";g[0]==="o"&&this.findRow(d+1)!==void 0?this._copyStyle(d+1,d,g[1]==="+"):g[0]==="i"&&this.findRow(d-1)!==void 0&&this._copyStyle(d-1,d,g[1]==="+")}_copyStyle(d,g){let p=arguments.length>2&&arguments[2]!==void 0&&arguments[2];const k=this.getRow(d),C=this.getRow(g);C.style=h(k.style),k.eachCell({includeEmpty:p},(T,D)=>{C.getCell(D).style=h(T.style)}),C.height=k.height}duplicateRow(d,g){let p=arguments.length>2&&arguments[2]!==void 0&&arguments[2];const k=this._rows[d-1],C=new Array(g).fill(k.values);this.spliceRows(d+1,p?0:g,...C);for(let T=0;T<g;T++){const D=this._rows[d+T];D.style=k.style,D.height=k.height,k.eachCell({includeEmpty:!0},(V,P)=>{D.getCell(P).style=V.style})}}spliceRows(d,g){const p=d+g;for(var k=arguments.length,C=new Array(k>2?k-2:0),T=2;T<k;T++)C[T-2]=arguments[T];const D=C.length,V=D-g,P=this._rows.length;let N,q;if(V<0)for(d===P&&(this._rows[P-1]=void 0),N=p;N<=P;N++)if(q=this._rows[N-1],q){const W=this.getRow(N+V);W.values=q.values,W.style=q.style,W.height=q.height,q.eachCell({includeEmpty:!0},(L,A)=>{W.getCell(A).style=L.style}),this._rows[N-1]=void 0}else this._rows[N+V-1]=void 0;else if(V>0)for(N=P;N>=p;N--)if(q=this._rows[N-1],q){const W=this.getRow(N+V);W.values=q.values,W.style=q.style,W.height=q.height,q.eachCell({includeEmpty:!0},(L,A)=>{if(W.getCell(A).style=L.style,L._value.constructor.name==="MergeValue"){const M=this.getRow(L._row._number+D).getCell(A),_=L._value._master,y=this.getRow(_._row._number+D).getCell(_._column._number);M.merge(y)}})}else this._rows[N+V-1]=void 0;for(N=0;N<D;N++){const W=this.getRow(d+N);W.style={},W.values=C[N]}this.workbook.definedNames.spliceRows(this.name,d,g,D)}eachRow(d,g){if(g||(g=d,d=void 0),d&&d.includeEmpty){const p=this._rows.length;for(let k=1;k<=p;k++)g(this.getRow(k),k)}else this._rows.forEach(p=>{p&&p.hasValues&&g(p,p.number)})}getSheetValues(){const d=[];return this._rows.forEach(g=>{g&&(d[g.number]=g.values)}),d}findCell(d,g){const p=i.getAddress(d,g),k=this._rows[p.row-1];return k?k.findCell(p.col):void 0}getCell(d,g){const p=i.getAddress(d,g);return this.getRow(p.row).getCellEx(p)}mergeCells(){for(var d=arguments.length,g=new Array(d),p=0;p<d;p++)g[p]=arguments[p];const k=new s(g);this._mergeCellsInternal(k)}mergeCellsWithoutStyle(){for(var d=arguments.length,g=new Array(d),p=0;p<d;p++)g[p]=arguments[p];const k=new s(g);this._mergeCellsInternal(k,!0)}_mergeCellsInternal(d,g){c.each(this._merges,k=>{if(k.intersects(d))throw new Error("Cannot merge already merged cells")});const p=this.getCell(d.top,d.left);for(let k=d.top;k<=d.bottom;k++)for(let C=d.left;C<=d.right;C++)(k>d.top||C>d.left)&&this.getCell(k,C).merge(p,g);this._merges[p.address]=d}_unMergeMaster(d){const g=this._merges[d.address];if(g){for(let p=g.top;p<=g.bottom;p++)for(let k=g.left;k<=g.right;k++)this.getCell(p,k).unmerge();delete this._merges[d.address]}}get hasMerges(){return c.some(this._merges,Boolean)}unMergeCells(){for(var d=arguments.length,g=new Array(d),p=0;p<d;p++)g[p]=arguments[p];const k=new s(g);for(let C=k.top;C<=k.bottom;C++)for(let T=k.left;T<=k.right;T++){const D=this.findCell(C,T);D&&(D.type===r.ValueType.Merge?this._unMergeMaster(D.master):this._merges[D.address]&&this._unMergeMaster(D))}}fillFormula(d,g,p){let k=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"shared";const C=i.decode(d),{top:T,left:D,bottom:V,right:P}=C,N=P-D+1,q=i.encodeAddress(T,D),W=k==="shared";let L;L=typeof p=="function"?p:Array.isArray(p)?Array.isArray(p[0])?(M,_)=>p[M-T][_-D]:(M,_)=>p[(M-T)*N+(_-D)]:()=>{};let A=!0;for(let M=T;M<=V;M++)for(let _=D;_<=P;_++)A?(this.getCell(M,_).value={shareType:k,formula:g,ref:d,result:L(M,_)},A=!1):this.getCell(M,_).value=W?{sharedFormula:q,result:L(M,_)}:L(M,_)}addImage(d,g){const p={type:"image",imageId:d,range:g};this._media.push(new u(this,p))}getImages(){return this._media.filter(d=>d.type==="image")}addBackgroundImage(d){const g={type:"background",imageId:d};this._media.push(new u(this,g))}getBackgroundImageId(){const d=this._media.find(g=>g.type==="background");return d&&d.imageId}protect(d,g){return new Promise(p=>{this.sheetProtection={sheet:!0},g&&"spinCount"in g&&(g.spinCount=Number.isFinite(g.spinCount)?Math.round(Math.max(0,g.spinCount)):1e5),d&&(this.sheetProtection.algorithmName="SHA-512",this.sheetProtection.saltValue=f.randomBytes(16).toString("base64"),this.sheetProtection.spinCount=g&&"spinCount"in g?g.spinCount:1e5,this.sheetProtection.hashValue=f.convertPasswordToHash(d,"SHA512",this.sheetProtection.saltValue,this.sheetProtection.spinCount)),g&&(this.sheetProtection=Object.assign(this.sheetProtection,g),!d&&"spinCount"in g&&delete this.sheetProtection.spinCount),p()})}unprotect(){this.sheetProtection=null}addTable(d){const g=new a(this,d);return this.tables[d.name]=g,g}getTable(d){return this.tables[d]}removeTable(d){delete this.tables[d]}getTables(){return Object.values(this.tables)}addConditionalFormatting(d){this.conditionalFormattings.push(d)}removeConditionalFormatting(d){typeof d=="number"?this.conditionalFormattings.splice(d,1):this.conditionalFormattings=d instanceof Function?this.conditionalFormattings.filter(d):[]}get tabColor(){return console.trace("worksheet.tabColor property is now deprecated. Please use worksheet.properties.tabColor"),this.properties.tabColor}set tabColor(d){console.trace("worksheet.tabColor property is now deprecated. Please use worksheet.properties.tabColor"),this.properties.tabColor=d}get model(){const d={id:this.id,name:this.name,dataValidations:this.dataValidations.model,properties:this.properties,state:this.state,pageSetup:this.pageSetup,headerFooter:this.headerFooter,rowBreaks:this.rowBreaks,views:this.views,autoFilter:this.autoFilter,media:this._media.map(k=>k.model),sheetProtection:this.sheetProtection,tables:Object.values(this.tables).map(k=>k.model),conditionalFormattings:this.conditionalFormattings};d.cols=e.toModel(this.columns);const g=d.rows=[],p=d.dimensions=new s;return this._rows.forEach(k=>{const C=k&&k.model;C&&(p.expand(C.number,C.min,C.number,C.max),g.push(C))}),d.merges=[],c.each(this._merges,k=>{d.merges.push(k.range)}),d}_parseRows(d){this._rows=[],d.rows.forEach(g=>{const p=new n(this,g.number);this._rows[p.number-1]=p,p.model=g})}_parseMergeCells(d){c.each(d.mergeCells,g=>{this.mergeCellsWithoutStyle(g)})}set model(d){this.name=d.name,this._columns=e.fromModel(this,d.cols),this._parseRows(d),this._parseMergeCells(d),this.dataValidations=new o(d.dataValidations),this.properties=d.properties,this.pageSetup=d.pageSetup,this.headerFooter=d.headerFooter,this.views=d.views,this.autoFilter=d.autoFilter,this._media=d.media.map(g=>new u(this,g)),this.sheetProtection=d.sheetProtection,this.tables=d.tables.reduce((g,p)=>{const k=new a;return k.model=p,g[p.name]=k,g},{}),this.conditionalFormattings=d.conditionalFormattings}}},{"../utils/col-cache":19,"../utils/copy-style":20,"../utils/encryptor":21,"../utils/under-dash":26,"./column":4,"./data-validations":5,"./enums":7,"./image":8,"./range":10,"./row":11,"./table":12}],15:[function(t,b,m){t("core-js/modules/es.promise"),t("core-js/modules/es.promise.finally"),t("core-js/modules/es.object.assign"),t("core-js/modules/es.object.keys"),t("core-js/modules/es.object.values"),t("core-js/modules/es.symbol"),t("core-js/modules/es.symbol.async-iterator"),t("core-js/modules/es.array.iterator"),t("core-js/modules/es.array.includes"),t("core-js/modules/es.array.find-index"),t("core-js/modules/es.array.find"),t("core-js/modules/es.string.from-code-point"),t("core-js/modules/es.string.includes"),t("core-js/modules/es.number.is-nan"),t("regenerator-runtime/runtime");const c={Workbook:t("./doc/workbook")},i=t("./doc/enums");Object.keys(i).forEach(s=>{c[s]=i[s]}),b.exports=c},{"./doc/enums":7,"./doc/workbook":13,"core-js/modules/es.array.find":359,"core-js/modules/es.array.find-index":358,"core-js/modules/es.array.includes":360,"core-js/modules/es.array.iterator":361,"core-js/modules/es.number.is-nan":363,"core-js/modules/es.object.assign":364,"core-js/modules/es.object.keys":366,"core-js/modules/es.object.values":367,"core-js/modules/es.promise":372,"core-js/modules/es.promise.finally":371,"core-js/modules/es.string.from-code-point":376,"core-js/modules/es.string.includes":377,"core-js/modules/es.symbol":381,"core-js/modules/es.symbol.async-iterator":378,"regenerator-runtime/runtime":492}],16:[function(t,b,m){const c=typeof TextDecoder>"u"?null:new TextDecoder("utf-8");m.bufferToString=function(i){return typeof i=="string"?i:c?c.decode(i):i.toString()}},{}],17:[function(t,b,m){const c=typeof TextEncoder>"u"?null:new TextEncoder("utf-8"),{Buffer:i}=t("buffer");m.stringToBuffer=function(s){return typeof s!="string"?s:c?i.from(c.encode(s).buffer):i.from(s)}},{buffer:220}],18:[function(t,b,m){const c=t("./under-dash"),i=t("./col-cache");b.exports=class{constructor(s){this.template=s,this.sheets={}}addCell(s){this.addCellEx(i.decodeEx(s))}getCell(s){return this.findCellEx(i.decodeEx(s),!0)}findCell(s){return this.findCellEx(i.decodeEx(s),!1)}findCellAt(s,n,e){const r=this.sheets[s],u=r&&r[n];return u&&u[e]}addCellEx(s){if(s.top)for(let n=s.top;n<=s.bottom;n++)for(let e=s.left;e<=s.right;e++)this.getCellAt(s.sheetName,n,e);else this.findCellEx(s,!0)}getCellEx(s){return this.findCellEx(s,!0)}findCellEx(s,n){const e=this.findSheet(s,n),r=this.findSheetRow(e,s,n);return this.findRowCell(r,s,n)}getCellAt(s,n,e){const r=this.sheets[s]||(this.sheets[s]=[]),u=r[n]||(r[n]=[]);return u[e]||(u[e]={sheetName:s,address:i.n2l(e)+n,row:n,col:e})}removeCellEx(s){const n=this.findSheet(s);if(!n)return;const e=this.findSheetRow(n,s);e&&delete e[s.col]}forEachInSheet(s,n){const e=this.sheets[s];e&&e.forEach((r,u)=>{r&&r.forEach((a,o)=>{a&&n(a,u,o)})})}forEach(s){c.each(this.sheets,(n,e)=>{this.forEachInSheet(e,s)})}map(s){const n=[];return this.forEach(e=>{n.push(s(e))}),n}findSheet(s,n){const e=s.sheetName;return this.sheets[e]?this.sheets[e]:n?this.sheets[e]=[]:void 0}findSheetRow(s,n,e){const{row:r}=n;return s&&s[r]?s[r]:e?s[r]=[]:void 0}findRowCell(s,n,e){const{col:r}=n;return s&&s[r]?s[r]:e?s[r]=this.template?Object.assign(n,JSON.parse(JSON.stringify(this.template))):n:void 0}spliceRows(s,n,e,r){const u=this.sheets[s];if(u){const a=[];for(let o=0;o<r;o++)a.push([]);u.splice(n,e,...a)}}spliceColumns(s,n,e,r){const u=this.sheets[s];if(u){const a=[];for(let o=0;o<r;o++)a.push(null);c.each(u,o=>{o.splice(n,e,...a)})}}}},{"./col-cache":19,"./under-dash":26}],19:[function(t,b,m){const c=/^[A-Z]+\d+$/,i={_dictionary:["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"],_l2nFill:0,_l2n:{},_n2l:[],_level:s=>s<=26?1:s<=676?2:3,_fill(s){let n,e,r,u,a,o=1;if(s>=4)throw new Error("Out of bounds. Excel supports columns from 1 to 16384");if(this._l2nFill<1&&s>=1){for(;o<=26;)n=this._dictionary[o-1],this._n2l[o]=n,this._l2n[n]=o,o++;this._l2nFill=1}if(this._l2nFill<2&&s>=2){for(o=27;o<=702;)e=o-27,r=e%26,u=Math.floor(e/26),n=this._dictionary[u]+this._dictionary[r],this._n2l[o]=n,this._l2n[n]=o,o++;this._l2nFill=2}if(this._l2nFill<3&&s>=3){for(o=703;o<=16384;)e=o-703,r=e%26,u=Math.floor(e/26)%26,a=Math.floor(e/676),n=this._dictionary[a]+this._dictionary[u]+this._dictionary[r],this._n2l[o]=n,this._l2n[n]=o,o++;this._l2nFill=3}},l2n(s){if(this._l2n[s]||this._fill(s.length),!this._l2n[s])throw new Error("Out of bounds. Invalid column letter: "+s);return this._l2n[s]},n2l(s){if(s<1||s>16384)throw new Error(s+" is out of bounds. Excel supports columns from 1 to 16384");return this._n2l[s]||this._fill(this._level(s)),this._n2l[s]},_hash:{},validateAddress(s){if(!c.test(s))throw new Error("Invalid Address: "+s);return!0},decodeAddress(s){const n=s.length<5&&this._hash[s];if(n)return n;let e=!1,r="",u=0,a=!1,o="",f=0;for(let d,g=0;g<s.length;g++)if(d=s.charCodeAt(g),!a&&d>=65&&d<=90)e=!0,r+=s[g],u=26*u+d-64;else if(d>=48&&d<=57)a=!0,o+=s[g],f=10*f+d-48;else if(a&&e&&d!==36)break;if(e){if(u>16384)throw new Error("Out of bounds. Invalid column letter: "+r)}else u=void 0;a||(f=void 0);const h={address:s=r+o,col:u,row:f,$col$row:`$${r}$${o}`};return u<=100&&f<=100&&(this._hash[s]=h,this._hash[h.$col$row]=h),h},getAddress(s,n){if(n){const e=this.n2l(n)+s;return this.decodeAddress(e)}return this.decodeAddress(s)},decode(s){const n=s.split(":");if(n.length===2){const e=this.decodeAddress(n[0]),r=this.decodeAddress(n[1]),u={top:Math.min(e.row,r.row),left:Math.min(e.col,r.col),bottom:Math.max(e.row,r.row),right:Math.max(e.col,r.col)};return u.tl=this.n2l(u.left)+u.top,u.br=this.n2l(u.right)+u.bottom,u.dimensions=`${u.tl}:${u.br}`,u}return this.decodeAddress(s)},decodeEx(s){const n=s.match(/(?:(?:(?:'((?:[^']|'')*)')|([^'^ !]*))!)?(.*)/),e=n[1]||n[2],r=n[3],u=r.split(":");if(u.length>1){let o=this.decodeAddress(u[0]),f=this.decodeAddress(u[1]);const h=Math.min(o.row,f.row),d=Math.min(o.col,f.col),g=Math.max(o.row,f.row),p=Math.max(o.col,f.col);return o=this.n2l(d)+h,f=this.n2l(p)+g,{top:h,left:d,bottom:g,right:p,sheetName:e,tl:{address:o,col:d,row:h,$col$row:`$${this.n2l(d)}$${h}`,sheetName:e},br:{address:f,col:p,row:g,$col$row:`$${this.n2l(p)}$${g}`,sheetName:e},dimensions:`${o}:${f}`}}if(r.startsWith("#"))return e?{sheetName:e,error:r}:{error:r};const a=this.decodeAddress(r);return e?{sheetName:e,...a}:a},encodeAddress:(s,n)=>i.n2l(n)+s,encode(){switch(arguments.length){case 2:return i.encodeAddress(arguments[0],arguments[1]);case 4:return`${i.encodeAddress(arguments[0],arguments[1])}:${i.encodeAddress(arguments[2],arguments[3])}`;default:throw new Error("Can only encode with 2 or 4 arguments")}},inRange(s,n){const[e,r,,u,a]=s,[o,f]=n;return o>=e&&o<=u&&f>=r&&f<=a}};b.exports=i},{}],20:[function(t,b,m){const c=(s,n)=>({...s,...n.reduce((e,r)=>(s[r]&&(e[r]={...s[r]}),e),{})}),i=function(s,n,e){let r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:[];s[e]&&(n[e]=c(s[e],r))};m.copyStyle=s=>{if(!s)return s;if(n=s,Object.keys(n).length===0)return{};var n;const e={...s};return i(s,e,"font",["color"]),i(s,e,"alignment"),i(s,e,"protection"),s.border&&(i(s,e,"border"),i(s.border,e.border,"top",["color"]),i(s.border,e.border,"left",["color"]),i(s.border,e.border,"bottom",["color"]),i(s.border,e.border,"right",["color"]),i(s.border,e.border,"diagonal",["color"])),s.fill&&(i(s,e,"fill",["fgColor","bgColor","center"]),s.fill.stops&&(e.fill.stops=s.fill.stops.map(r=>c(r,["color"])))),e}},{}],21:[function(t,b,m){(function(c){(function(){const i=t("crypto"),s={hash(n){const e=i.createHash(n);for(var r=arguments.length,u=new Array(r>1?r-1:0),a=1;a<r;a++)u[a-1]=arguments[a];return e.update(c.concat(u)),e.digest()},convertPasswordToHash(n,e,r,u){if(e=e.toLowerCase(),i.getHashes().indexOf(e)<0)throw new Error(`Hash algorithm '${e}' not supported!`);const a=c.from(n,"utf16le");let o=this.hash(e,c.from(r,"base64"),a);for(let f=0;f<u;f++){const h=c.alloc(4);h.writeUInt32LE(f,0),o=this.hash(e,o,h)}return o.toString("base64")},randomBytes:n=>i.randomBytes(n)};b.exports=s}).call(this)}).call(this,t("buffer").Buffer)},{buffer:220,crypto:390}],22:[function(t,b,m){const{SaxesParser:c}=t("saxes"),{PassThrough:i}=t("readable-stream"),{bufferToString:s}=t("./browser-buffer-decode");b.exports=async function*(n){n.pipe&&!n[Symbol.asyncIterator]&&(n=n.pipe(new i));const e=new c;let r;e.on("error",a=>{r=a});let u=[];e.on("opentag",a=>u.push({eventType:"opentag",value:a})),e.on("text",a=>u.push({eventType:"text",value:a})),e.on("closetag",a=>u.push({eventType:"closetag",value:a}));for await(const a of n){if(e.write(s(a)),r)throw r;yield u,u=[]}}},{"./browser-buffer-decode":16,"readable-stream":491,saxes:496}],23:[function(t,b,m){const c=t("./col-cache"),i=/(([a-z_\-0-9]*)!)?([a-z0-9_$]{2,})([(])?/gi,s=/^([$])?([a-z]+)([$])?([1-9][0-9]*)$/i;b.exports={slideFormula:function(n,e,r){const u=c.decode(e),a=c.decode(r);return n.replace(i,(o,f,h,d,g)=>{if(g)return o;const p=s.exec(d);if(p){const k=p[1],C=p[2].toUpperCase(),T=p[3],D=p[4];if(C.length>3||C.length===3&&C>"XFD")return o;let V=c.l2n(C),P=parseInt(D,10);return k||(V+=a.col-u.col),T||(P+=a.row-u.row),(f||"")+(k||"")+c.n2l(V)+(T||"")+P}return o})}}},{"./col-cache":19}],24:[function(t,b,m){(function(c,i){(function(){const s=t("readable-stream"),n=t("./utils"),e=t("./string-buf");class r{constructor(d,g){this._data=d,this._encoding=g}get length(){return this.toBuffer().length}copy(d,g,p,k){return this.toBuffer().copy(d,g,p,k)}toBuffer(){return this._buffer||(this._buffer=i.from(this._data,this._encoding)),this._buffer}}class u{constructor(d){this._data=d}get length(){return this._data.length}copy(d,g,p,k){return this._data._buf.copy(d,g,p,k)}toBuffer(){return this._data.toBuffer()}}class a{constructor(d){this._data=d}get length(){return this._data.length}copy(d,g,p,k){this._data.copy(d,g,p,k)}toBuffer(){return this._data}}class o{constructor(d){this.size=d,this.buffer=i.alloc(d),this.iRead=0,this.iWrite=0}toBuffer(){if(this.iRead===0&&this.iWrite===this.size)return this.buffer;const d=i.alloc(this.iWrite-this.iRead);return this.buffer.copy(d,0,this.iRead,this.iWrite),d}get length(){return this.iWrite-this.iRead}get eod(){return this.iRead===this.iWrite}get full(){return this.iWrite===this.size}read(d){let g;return d===0?null:d===void 0||d>=this.length?(g=this.toBuffer(),this.iRead=this.iWrite,g):(g=i.alloc(d),this.buffer.copy(g,0,this.iRead,d),this.iRead+=d,g)}write(d,g,p){const k=Math.min(p,this.size-this.iWrite);return d.copy(this.buffer,this.iWrite,g,g+k),this.iWrite+=k,k}}const f=function(h){h=h||{},this.bufSize=h.bufSize||1048576,this.buffers=[],this.batch=h.batch||!1,this.corked=!1,this.inPos=0,this.outPos=0,this.pipes=[],this.paused=!1,this.encoding=null};n.inherits(f,s.Duplex,{toBuffer(){switch(this.buffers.length){case 0:return null;case 1:return this.buffers[0].toBuffer();default:return i.concat(this.buffers.map(h=>h.toBuffer()))}},_getWritableBuffer(){if(this.buffers.length){const d=this.buffers[this.buffers.length-1];if(!d.full)return d}const h=new o(this.bufSize);return this.buffers.push(h),h},async _pipe(h){await Promise.all(this.pipes.map(function(d){return new Promise(g=>{d.write(h.toBuffer(),()=>{g()})})}))},_writeToBuffers(h){let d=0;const g=h.length;for(;d<g;)d+=this._getWritableBuffer().write(h,d,g-d)},async write(h,d,g){let p;if(d instanceof Function&&(g=d,d="utf8"),g=g||n.nop,h instanceof e)p=new u(h);else if(h instanceof i)p=new a(h);else{if(!(typeof h=="string"||h instanceof String||h instanceof ArrayBuffer))throw new Error("Chunk must be one of type String, Buffer or StringBuf.");p=new r(h,d)}if(this.pipes.length)if(this.batch)for(this._writeToBuffers(p);!this.corked&&this.buffers.length>1;)this._pipe(this.buffers.shift());else this.corked?(this._writeToBuffers(p),c.nextTick(g)):(await this._pipe(p),g());else this.paused||this.emit("data",p.toBuffer()),this._writeToBuffers(p),this.emit("readable");return!0},cork(){this.corked=!0},_flush(){if(this.pipes.length)for(;this.buffers.length;)this._pipe(this.buffers.shift())},uncork(){this.corked=!1,this._flush()},end(h,d,g){const p=k=>{k?g(k):(this._flush(),this.pipes.forEach(C=>{C.end()}),this.emit("finish"))};h?this.write(h,d,p):p()},read(h){let d;if(h){for(d=[];h&&this.buffers.length&&!this.buffers[0].eod;){const g=this.buffers[0],p=g.read(h);h-=p.length,d.push(p),g.eod&&g.full&&this.buffers.shift()}return i.concat(d)}return d=this.buffers.map(g=>g.toBuffer()).filter(Boolean),this.buffers=[],i.concat(d)},setEncoding(h){this.encoding=h},pause(){this.paused=!0},resume(){this.paused=!1},isPaused(){return!!this.paused},pipe(h){this.pipes.push(h),!this.paused&&this.buffers.length&&this.end()},unpipe(h){this.pipes=this.pipes.filter(d=>d!==h)},unshift(){throw new Error("Not Implemented")},wrap(){throw new Error("Not Implemented")}}),b.exports=f}).call(this)}).call(this,t("_process"),t("buffer").Buffer)},{"./string-buf":25,"./utils":27,_process:467,buffer:220,"readable-stream":491}],25:[function(t,b,m){(function(c){(function(){b.exports=class{constructor(i){this._buf=c.alloc(i&&i.size||16384),this._encoding=i&&i.encoding||"utf8",this._inPos=0,this._buffer=void 0}get length(){return this._inPos}get capacity(){return this._buf.length}get buffer(){return this._buf}toBuffer(){return this._buffer||(this._buffer=c.alloc(this.length),this._buf.copy(this._buffer,0,0,this.length)),this._buffer}reset(i){i=i||0,this._buffer=void 0,this._inPos=i}_grow(i){let s=2*this._buf.length;for(;s<i;)s*=2;const n=c.alloc(s);this._buf.copy(n,0),this._buf=n}addText(i){this._buffer=void 0;let s=this._inPos+this._buf.write(i,this._inPos,this._encoding);for(;s>=this._buf.length-4;)this._grow(this._inPos+i.length),s=this._inPos+this._buf.write(i,this._inPos,this._encoding);this._inPos=s}addStringBuf(i){i.length&&(this._buffer=void 0,this.length+i.length>this.capacity&&this._grow(this.length+i.length),i._buf.copy(this._buf,this._inPos,0,i.length),this._inPos+=i.length)}}}).call(this)}).call(this,t("buffer").Buffer)},{buffer:220}],26:[function(t,b,m){const{toString:c}=Object.prototype,i=/["&<>]/,s={each:function(n,e){n&&(Array.isArray(n)?n.forEach(e):Object.keys(n).forEach(r=>{e(n[r],r)}))},some:function(n,e){return!!n&&(Array.isArray(n)?n.some(e):Object.keys(n).some(r=>e(n[r],r)))},every:function(n,e){return!n||(Array.isArray(n)?n.every(e):Object.keys(n).every(r=>e(n[r],r)))},map:function(n,e){return n?Array.isArray(n)?n.map(e):Object.keys(n).map(r=>e(n[r],r)):[]},keyBy:(n,e)=>n.reduce((r,u)=>(r[u[e]]=u,r),{}),isEqual:function(n,e){const r=typeof n,u=typeof e,a=Array.isArray(n),o=Array.isArray(e);let f;if(r!==u)return!1;switch(typeof n){case"object":if(a||o)return!(!a||!o)&&n.length===e.length&&n.every((h,d)=>{const g=e[d];return s.isEqual(h,g)});if(n===null||e===null)return n===e;if(f=Object.keys(n),Object.keys(e).length!==f.length)return!1;for(const h of f)if(!e.hasOwnProperty(h))return!1;return s.every(n,(h,d)=>{const g=e[d];return s.isEqual(h,g)});default:return n===e}},escapeHtml(n){const e=i.exec(n);if(!e)return n;let r="",u="",a=0,o=e.index;for(;o<n.length;o++){switch(n.charAt(o)){case'"':u="&quot;";break;case"&":u="&amp;";break;case"'":u="&apos;";break;case"<":u="&lt;";break;case">":u="&gt;";break;default:continue}a!==o&&(r+=n.substring(a,o)),a=o+1,r+=u}return a!==o?r+n.substring(a,o):r},strcmp:(n,e)=>n<e?-1:n>e?1:0,isUndefined:n=>c.call(n)==="[object Undefined]",isObject:n=>c.call(n)==="[object Object]",deepMerge(){const n=arguments[0]||{},{length:e}=arguments;let r,u,a;function o(f,h){r=n[h],a=Array.isArray(f),s.isObject(f)||a?(a?(a=!1,u=r&&Array.isArray(r)?r:[]):u=r&&s.isObject(r)?r:{},n[h]=s.deepMerge(u,f)):s.isUndefined(f)||(n[h]=f)}for(let f=0;f<e;f++)s.each(arguments[f],o);return n}};b.exports=s},{}],27:[function(t,b,m){(function(c,i){(function(){const s=t("fs"),n=/[<>&'"\x7F\x00-\x08\x0B-\x0C\x0E-\x1F]/,e={nop(){},promiseImmediate:r=>new Promise(u=>{c.setImmediate?i(()=>{u(r)}):setTimeout(()=>{u(r)},1)}),inherits:function(r,u,a,o){r.super_=u,o||(o=a,a=null),a&&Object.keys(a).forEach(h=>{Object.defineProperty(r,h,Object.getOwnPropertyDescriptor(a,h))});const f={constructor:{value:r,enumerable:!1,writable:!1,configurable:!0}};o&&Object.keys(o).forEach(h=>{f[h]=Object.getOwnPropertyDescriptor(o,h)}),r.prototype=Object.create(u.prototype,f)},dateToExcel:(r,u)=>25569+r.getTime()/864e5-(u?1462:0),excelToDate(r,u){const a=Math.round(24*(r-25569+(u?1462:0))*3600*1e3);return new Date(a)},parsePath(r){const u=r.lastIndexOf("/");return{path:r.substring(0,u),name:r.substring(u+1)}},getRelsPath(r){const u=e.parsePath(r);return`${u.path}/_rels/${u.name}.rels`},xmlEncode(r){const u=n.exec(r);if(!u)return r;let a="",o="",f=0,h=u.index;for(;h<r.length;h++){const d=r.charCodeAt(h);switch(d){case 34:o="&quot;";break;case 38:o="&amp;";break;case 39:o="&apos;";break;case 60:o="&lt;";break;case 62:o="&gt;";break;case 127:o="";break;default:if(d<=31&&(d<=8||d>=11&&d!==13)){o="";break}continue}f!==h&&(a+=r.substring(f,h)),f=h+1,o&&(a+=o)}return f!==h?a+r.substring(f,h):a},xmlDecode:r=>r.replace(/&([a-z]*);/g,u=>{switch(u){case"&lt;":return"<";case"&gt;":return">";case"&amp;":return"&";case"&apos;":return"'";case"&quot;":return'"';default:return u}}),validInt(r){const u=parseInt(r,10);return Number.isNaN(u)?0:u},isDateFmt(r){return r?(r=(r=r.replace(/\[[^\]]*]/g,"")).replace(/"[^"]*"/g,"")).match(/[ymdhMsb]+/)!==null:!1},fs:{exists:r=>new Promise(u=>{s.access(r,s.constants.F_OK,a=>{u(!a)})})},toIsoDateString:r=>r.toIsoString().subsstr(0,10),parseBoolean:r=>r===!0||r==="true"||r===1||r==="1"};b.exports=e}).call(this)}).call(this,typeof ut<"u"?ut:typeof self<"u"?self:typeof window<"u"?window:{},t("timers").setImmediate)},{fs:216,timers:523}],28:[function(t,b,m){const c=t("./under-dash"),i=t("./utils");function s(r,u,a){r.push(` ${u}="${i.xmlEncode(a.toString())}"`)}function n(r,u){if(u){const a=[];c.each(u,(o,f)=>{o!==void 0&&s(a,f,o)}),r.push(a.join(""))}}class e{constructor(){this._xml=[],this._stack=[],this._rollbacks=[]}get tos(){return this._stack.length?this._stack[this._stack.length-1]:void 0}get cursor(){return this._xml.length}openXml(u){const a=this._xml;a.push("<?xml"),n(a,u),a.push(`?>
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const v=require("vue"),pi={xs:18,sm:24,md:32,lg:38,xl:46},Fr={size:String};function jr(l,B=pi){return v.computed(()=>l.size!==void 0?{fontSize:l.size in B?`${B[l.size]}px`:l.size}:null)}function Lt(l,B,t,b){return Object.defineProperty(l,B,{get:t,set:b,enumerable:!0}),l}function Cs(l,B){for(const t in B)Lt(l,t,B[t]);return l}function $e(l){return v.markRaw(v.defineComponent(l))}function Ti(l){return v.markRaw(l)}const As=(l,B)=>{const t=v.reactive(l);for(const b in l)Lt(B,b,()=>t[b],m=>{t[b]=m});return B};function bt(l,B){return l!==void 0&&l()||B}function Ri(l,B){if(l!==void 0){const t=l();if(t!=null)return t.slice()}return B}function It(l,B){return l!==void 0?B.concat(l()):B}function la(l,B){return l===void 0?B:B!==void 0?B.concat(l()):l()}function Es(l,B,t,b,m,c){B.key=b+m;const i=v.h(l,B,t);return m===!0?v.withDirectives(i,c()):i}const lo="0 0 24 24",Kn=l=>l,Xn=l=>`ionicons ${l}`,ua={"mdi-":l=>`mdi ${l}`,"icon-":Kn,"bt-":l=>`bt ${l}`,"eva-":l=>`eva ${l}`,"ion-md":Xn,"ion-ios":Xn,"ion-logo":Xn,"iconfont ":Kn,"ti-":l=>`themify-icon ${l}`,"bi-":l=>`bootstrap-icons ${l}`,"i-":Kn},ca={o_:"-outlined",r_:"-round",s_:"-sharp"},da={sym_o_:"-outlined",sym_r_:"-rounded",sym_s_:"-sharp"},Ms=new RegExp("^("+Object.keys(ua).join("|")+")"),Ts=new RegExp("^("+Object.keys(ca).join("|")+")"),uo=new RegExp("^("+Object.keys(da).join("|")+")"),Rs=/^[Mm]\s?[-+]?\.?\d/,Bs=/^img:/,Is=/^svguse:/,Os=/^ion-/,Fs=/^(fa-(classic|sharp|solid|regular|light|brands|duotone|thin)|[lf]a[srlbdk]?) /,dt=$e({name:"QIcon",props:{...Fr,tag:{type:String,default:"i"},name:String,color:String,left:Boolean,right:Boolean},setup(l,{slots:B}){const{proxy:{$q:t}}=v.getCurrentInstance(),b=jr(l),m=v.computed(()=>"q-icon"+(l.left===!0?" on-left":"")+(l.right===!0?" on-right":"")+(l.color!==void 0?` text-${l.color}`:"")),c=v.computed(()=>{let i,s=l.name;if(s==="none"||!s)return{none:!0};if(t.iconMapFn!==null){const r=t.iconMapFn(s);if(r!==void 0)if(r.icon!==void 0){if(s=r.icon,s==="none"||!s)return{none:!0}}else return{cls:r.cls,content:r.content!==void 0?r.content:" "}}if(Rs.test(s)===!0){const[r,u=lo]=s.split("|");return{svg:!0,viewBox:u,nodes:r.split("&&").map(a=>{const[o,f,h]=a.split("@@");return v.h("path",{style:f,d:o,transform:h})})}}if(Bs.test(s)===!0)return{img:!0,src:s.substring(4)};if(Is.test(s)===!0){const[r,u=lo]=s.split("|");return{svguse:!0,src:r.substring(7),viewBox:u}}let n=" ";const e=s.match(Ms);if(e!==null)i=ua[e[1]](s);else if(Fs.test(s)===!0)i=s;else if(Os.test(s)===!0)i=`ionicons ion-${t.platform.is.ios===!0?"ios":"md"}${s.substring(3)}`;else if(uo.test(s)===!0){i="notranslate material-symbols";const r=s.match(uo);r!==null&&(s=s.substring(6),i+=da[r[1]]),n=s}else{i="notranslate material-icons";const r=s.match(Ts);r!==null&&(s=s.substring(2),i+=ca[r[1]]),n=s}return{cls:i,content:n}});return()=>{const i={class:m.value,style:b.value,"aria-hidden":"true"};return c.value.none===!0?v.h(l.tag,i,bt(B.default)):c.value.img===!0?v.h(l.tag,i,It(B.default,[v.h("img",{src:c.value.src})])):c.value.svg===!0?v.h(l.tag,i,It(B.default,[v.h("svg",{viewBox:c.value.viewBox||"0 0 24 24"},c.value.nodes)])):c.value.svguse===!0?v.h(l.tag,i,It(B.default,[v.h("svg",{viewBox:c.value.viewBox},[v.h("use",{"xlink:href":c.value.src})])])):(c.value.cls!==void 0&&(i.class+=" "+c.value.cls),v.h(l.tag,i,It(B.default,[c.value.content])))}}});function xn(l){if(Object(l.$parent)===l.$parent)return l.$parent;let{parent:B}=l.$;for(;Object(B)===B;){if(Object(B.proxy)===B.proxy)return B.proxy;B=B.parent}}function fa(l,B){typeof B.type=="symbol"?Array.isArray(B.children)===!0&&B.children.forEach(t=>{fa(l,t)}):l.add(B)}function js(l){const B=new Set;return l.forEach(t=>{fa(B,t)}),Array.from(B)}function Bi(l){return l.appContext.config.globalProperties.$router!==void 0}function Ii(l){return l.isUnmounted===!0||l.isDeactivated===!0}function co(l){return l?l.aliasOf?l.aliasOf.path:l.path:""}function fo(l,B){return(l.aliasOf||l)===(B.aliasOf||B)}function Ds(l,B){for(const t in B){const b=B[t],m=l[t];if(typeof b=="string"){if(b!==m)return!1}else if(Array.isArray(m)===!1||m.length!==b.length||b.some((c,i)=>c!==m[i]))return!1}return!0}function ho(l,B){return Array.isArray(B)===!0?l.length===B.length&&l.every((t,b)=>t===B[b]):l.length===1&&l[0]===B}function Ps(l,B){return Array.isArray(l)===!0?ho(l,B):Array.isArray(B)===!0?ho(B,l):l===B}function Ns(l,B){if(Object.keys(l).length!==Object.keys(B).length)return!1;for(const t in l)if(Ps(l[t],B[t])===!1)return!1;return!0}const ha={to:[String,Object],replace:Boolean,href:String,target:String,disable:Boolean},pa={...ha,exact:Boolean,activeClass:{type:String,default:"q-router-link--active"},exactActiveClass:{type:String,default:"q-router-link--exact-active"}};function Oi({fallbackTag:l,useDisableForRouterLinkProps:B=!0}={}){const t=v.getCurrentInstance(),{props:b,proxy:m,emit:c}=t,i=Bi(t),s=v.computed(()=>b.disable!==!0&&b.href!==void 0),n=B===!0?v.computed(()=>i===!0&&b.disable!==!0&&s.value!==!0&&b.to!==void 0&&b.to!==null&&b.to!==""):v.computed(()=>i===!0&&s.value!==!0&&b.to!==void 0&&b.to!==null&&b.to!==""),e=v.computed(()=>n.value===!0?p(b.to):null),r=v.computed(()=>e.value!==null),u=v.computed(()=>s.value===!0||r.value===!0),a=v.computed(()=>b.type==="a"||u.value===!0?"a":b.tag||l||"div"),o=v.computed(()=>s.value===!0?{href:b.href,target:b.target}:r.value===!0?{href:e.value.href,target:b.target}:{}),f=v.computed(()=>{if(r.value===!1)return-1;const{matched:T}=e.value,{length:D}=T,V=T[D-1];if(V===void 0)return-1;const P=m.$route.matched;if(P.length===0)return-1;const N=P.findIndex(fo.bind(null,V));if(N!==-1)return N;const q=co(T[D-2]);return D>1&&co(V)===q&&P[P.length-1].path!==q?P.findIndex(fo.bind(null,T[D-2])):N}),h=v.computed(()=>r.value===!0&&f.value!==-1&&Ds(m.$route.params,e.value.params)),d=v.computed(()=>h.value===!0&&f.value===m.$route.matched.length-1&&Ns(m.$route.params,e.value.params)),g=v.computed(()=>r.value===!0?d.value===!0?` ${b.exactActiveClass} ${b.activeClass}`:b.exact===!0?"":h.value===!0?` ${b.activeClass}`:"":"");function p(T){try{return m.$router.resolve(T)}catch{}return null}function k(T,{returnRouterError:D,to:V=b.to,replace:P=b.replace}={}){if(b.disable===!0)return T.preventDefault(),Promise.resolve(!1);if(T.metaKey||T.altKey||T.ctrlKey||T.shiftKey||T.button!==void 0&&T.button!==0||b.target==="_blank")return Promise.resolve(!1);T.preventDefault();const N=m.$router[P===!0?"replace":"push"](V);return D===!0?N:N.then(()=>{}).catch(()=>{})}function C(T){if(r.value===!0){const D=V=>k(T,V);c("click",T,D),T.defaultPrevented!==!0&&D()}else c("click",T)}return{hasRouterLink:r,hasHrefLink:s,hasLink:u,linkTag:a,resolvedLink:e,linkIsActive:h,linkIsExactActive:d,linkClass:g,linkAttrs:o,getLink:p,navigateToRouterLink:k,navigateOnClick:C}}const Ls=$e({name:"QBreadcrumbsEl",props:{...pa,label:String,icon:String,tag:{type:String,default:"span"}},emits:["click"],setup(l,{slots:B}){const{linkTag:t,linkAttrs:b,linkClass:m,navigateOnClick:c}=Oi(),i=v.computed(()=>({class:"q-breadcrumbs__el q-link flex inline items-center relative-position "+(l.disable!==!0?"q-link--focusable"+m.value:"q-breadcrumbs__el--disable"),...b.value,onClick:c})),s=v.computed(()=>"q-breadcrumbs__el-icon"+(l.label!==void 0?" q-breadcrumbs__el-icon--with-label":""));return()=>{const n=[];return l.icon!==void 0&&n.push(v.h(dt,{class:s.value,name:l.icon})),l.label!==void 0&&n.push(l.label),v.h(t.value,{...i.value},It(B.default,n))}}}),ma={left:"start",center:"center",right:"end",between:"between",around:"around",evenly:"evenly",stretch:"stretch"},Vs=Object.keys(ma),Fi={align:{type:String,validator:l=>Vs.includes(l)}};function ji(l){return v.computed(()=>{const B=l.align===void 0?l.vertical===!0?"stretch":"left":l.align;return`${l.vertical===!0?"items":"justify"}-${ma[B]}`})}const qs=["",!0],zs=$e({name:"QBreadcrumbs",props:{...Fi,separator:{type:String,default:"/"},separatorColor:String,activeColor:{type:String,default:"primary"},gutter:{type:String,validator:l=>["none","xs","sm","md","lg","xl"].includes(l),default:"sm"}},setup(l,{slots:B}){const t=ji(l),b=v.computed(()=>`flex items-center ${t.value}${l.gutter==="none"?"":` q-gutter-${l.gutter}`}`),m=v.computed(()=>l.separatorColor?` text-${l.separatorColor}`:""),c=v.computed(()=>` text-${l.activeColor}`);return()=>{if(B.default===void 0)return;const i=js(bt(B.default));if(i.length===0)return;let s=1;const n=[],e=i.filter(u=>u.type?.name==="QBreadcrumbsEl").length,r=B.separator!==void 0?B.separator:()=>l.separator;return i.forEach(u=>{if(u.type?.name==="QBreadcrumbsEl"){const a=s<e,o=u.props!==null&&qs.includes(u.props.disable),f=(a===!0?"":" q-breadcrumbs--last")+(o!==!0&&a===!0?c.value:"");s++,n.push(v.h("div",{class:`flex items-center${f}`},[u])),a===!0&&n.push(v.h("div",{class:"q-breadcrumbs__separator"+m.value},r()))}else n.push(u)}),v.h("div",{class:"q-breadcrumbs"},[v.h("div",{class:b.value},n)])}}}),Us=v.defineComponent({inheritAttrs:!1,__name:"Breadcrumbs",props:{activeColor:{},separatorIcon:{},separatorSize:{},separatorColor:{},store:{},navStore:{},route:{},router:{},breadcrumbConfig:{},separator:{},gutter:{},align:{}},setup(l){const B=l,t=v.useAttrs(),b=v.computed(()=>{const{activeColor:a,separatorIcon:o,separatorSize:f,separatorColor:h,...d}=t;return d}),m=a=>({"data-cy":a.dataCy,class:"cursor-pointer text-h5",color:a.color}),c=v.computed(()=>B.activeColor||"primary"),i=v.computed(()=>B.separatorIcon||"chevron_right"),s=v.computed(()=>B.separatorSize||"2em"),n=v.computed(()=>B.separatorColor||"primary"),e=v.computed(()=>({store:B.store,route:B.route,navStore:B.navStore||{}})),r=v.computed(()=>{const a=[];return B.breadcrumbConfig.forEach(o=>{if(!o.shouldRender(e.value))return;const f=o.getLabel?o.getLabel(e.value):o.defaultLabel,h=o.getColor?o.getColor(e.value):"dark",d={name:o.routeName,...o.getRouteParams&&{params:o.getRouteParams(e.value)}},g=o.clearActions?o.clearActions.map(p=>()=>p(e.value)):[];a.push({label:f,dataCy:o.dataCy,color:h,route:d,clearActions:g})}),a}),u=a=>{a.clearActions&&a.clearActions.forEach(o=>o()),B.router.push(a.route)};return(a,o)=>(v.openBlock(),v.createBlock(zs,v.mergeProps({"active-color":c.value,class:"text-brown"},b.value),{separator:v.withCtx(()=>[v.createVNode(dt,{size:s.value,name:i.value,color:n.value},null,8,["size","name","color"])]),default:v.withCtx(()=>[(v.openBlock(!0),v.createElementBlock(v.Fragment,null,v.renderList(r.value,(f,h)=>(v.openBlock(),v.createBlock(Ls,v.mergeProps({key:h,to:f.route},{ref_for:!0},m(f),{label:f.label,onClick:d=>u(f)}),null,16,["to","label","onClick"]))),128))]),_:1},16,["active-color"]))}}),Ws={size:{type:[String,Number],default:"1em"},color:String};function Hs(l){return{cSize:v.computed(()=>l.size in pi?`${pi[l.size]}px`:l.size),classes:v.computed(()=>"q-spinner"+(l.color?` text-${l.color}`:""))}}const ga=$e({name:"QSpinner",props:{...Ws,thickness:{type:Number,default:5}},setup(l){const{cSize:B,classes:t}=Hs(l);return()=>v.h("svg",{class:t.value+" q-spinner-mat",width:B.value,height:B.value,viewBox:"25 25 50 50"},[v.h("circle",{class:"path",cx:"50",cy:"50",r:"20",fill:"none",stroke:"currentColor","stroke-width":l.thickness,"stroke-miterlimit":"10"})])}});function mi(l,B){const t=l.style;for(const b in B)t[b]=B[b]}function Ys(l){if(l==null)return;if(typeof l=="string")try{return document.querySelector(l)||void 0}catch{return}const B=v.unref(l);if(B)return B.$el||B}function ba(l,B){if(l==null||l.contains(B)===!0)return!0;for(let t=l.nextElementSibling;t!==null;t=t.nextElementSibling)if(t.contains(B))return!0;return!1}const _t={hasPassive:!1,passiveCapture:!0,notPassiveCapture:!0};try{const l=Object.defineProperty({},"passive",{get(){Object.assign(_t,{hasPassive:!0,passive:{passive:!0},notPassive:{passive:!1},passiveCapture:{passive:!0,capture:!0},notPassiveCapture:{passive:!1,capture:!0}})}});window.addEventListener("qtest",null,l),window.removeEventListener("qtest",null,l)}catch{}function Ln(){}function Qs(l){return l.button===0}function Qr(l){return l.touches&&l.touches[0]?l=l.touches[0]:l.changedTouches&&l.changedTouches[0]?l=l.changedTouches[0]:l.targetTouches&&l.targetTouches[0]&&(l=l.targetTouches[0]),{top:l.clientY,left:l.clientX}}function Ks(l){if(l.path)return l.path;if(l.composedPath)return l.composedPath();const B=[];let t=l.target;for(;t;){if(B.push(t),t.tagName==="HTML")return B.push(document),B.push(window),B;t=t.parentElement}}function Dt(l){l.stopPropagation()}function Bt(l){l.cancelable!==!1&&l.preventDefault()}function St(l){l.cancelable!==!1&&l.preventDefault(),l.stopPropagation()}function Gn(l,B){if(l===void 0||B===!0&&l.__dragPrevented===!0)return;const t=B===!0?b=>{b.__dragPrevented=!0,b.addEventListener("dragstart",Bt,_t.notPassiveCapture)}:b=>{delete b.__dragPrevented,b.removeEventListener("dragstart",Bt,_t.notPassiveCapture)};l.querySelectorAll("a, img").forEach(t)}function Xt(l,B,t){const b=`__q_${B}_evt`;l[b]=l[b]!==void 0?l[b].concat(t):t,t.forEach(m=>{m[0].addEventListener(m[1],l[m[2]],_t[m[3]])})}function pr(l,B){const t=`__q_${B}_evt`;l[t]!==void 0&&(l[t].forEach(b=>{b[0].removeEventListener(b[1],l[b[2]],_t[b[3]])}),l[t]=void 0)}function Di(l){return l!==Object(l)||l.isComposing===!0||l.qKeyEvent===!0}function or(l,B){return Di(l)===!0?!1:[].concat(B).includes(l.keyCode)}function Xs(l,B=250){let t=!1,b;return function(){return t===!1&&(t=!0,setTimeout(()=>{t=!1},B),b=l.apply(this,arguments)),b}}function po(l,B,t,b){t.modifiers.stop===!0&&Dt(l);const m=t.modifiers.color;let c=t.modifiers.center;c=c===!0||b===!0;const i=document.createElement("span"),s=document.createElement("span"),n=Qr(l),{left:e,top:r,width:u,height:a}=B.getBoundingClientRect(),o=Math.sqrt(u*u+a*a),f=o/2,h=`${(u-o)/2}px`,d=c?h:`${n.left-e-f}px`,g=`${(a-o)/2}px`,p=c?g:`${n.top-r-f}px`;s.className="q-ripple__inner",mi(s,{height:`${o}px`,width:`${o}px`,transform:`translate3d(${d},${p},0) scale3d(.2,.2,1)`,opacity:0}),i.className=`q-ripple${m?" text-"+m:""}`,i.setAttribute("dir","ltr"),i.appendChild(s),B.appendChild(i);const k=()=>{i.remove(),clearTimeout(C)};t.abort.push(k);let C=setTimeout(()=>{s.classList.add("q-ripple__inner--enter"),s.style.transform=`translate3d(${h},${g},0) scale3d(1,1,1)`,s.style.opacity=.2,C=setTimeout(()=>{s.classList.remove("q-ripple__inner--enter"),s.classList.add("q-ripple__inner--leave"),s.style.opacity=0,C=setTimeout(()=>{i.remove(),t.abort.splice(t.abort.indexOf(k),1)},275)},250)},50)}function mo(l,{modifiers:B,value:t,arg:b}){const m=Object.assign({},l.cfg.ripple,B,t);l.modifiers={early:m.early===!0,stop:m.stop===!0,center:m.center===!0,color:m.color||b,keyCodes:[].concat(m.keyCodes||13)}}const va=Ti({name:"ripple",beforeMount(l,B){const t=B.instance.$.appContext.config.globalProperties.$q.config||{};if(t.ripple===!1)return;const b={cfg:t,enabled:B.value!==!1,modifiers:{},abort:[],start(m){b.enabled===!0&&m.qSkipRipple!==!0&&m.type===(b.modifiers.early===!0?"pointerdown":"click")&&po(m,l,b,m.qKeyEvent===!0)},keystart:Xs(m=>{b.enabled===!0&&m.qSkipRipple!==!0&&or(m,b.modifiers.keyCodes)===!0&&m.type===`key${b.modifiers.early===!0?"down":"up"}`&&po(m,l,b,!0)},300)};mo(b,B),l.__qripple=b,Xt(b,"main",[[l,"pointerdown","start","passive"],[l,"click","start","passive"],[l,"keydown","keystart","passive"],[l,"keyup","keystart","passive"]])},updated(l,B){if(B.oldValue!==B.value){const t=l.__qripple;t!==void 0&&(t.enabled=B.value!==!1,t.enabled===!0&&Object(B.value)===B.value&&mo(t,B))}},beforeUnmount(l){const B=l.__qripple;B!==void 0&&(B.abort.forEach(t=>{t()}),pr(B,"main"),delete l._qripple)}}),go={none:0,xs:4,sm:8,md:16,lg:24,xl:32},Gs={xs:8,sm:10,md:14,lg:20,xl:24},Js=["button","submit","reset"],Zs=/[^\s]\/[^\s]/,$s=["flat","outline","push","unelevated"];function el(l,B){return l.flat===!0?"flat":l.outline===!0?"outline":l.push===!0?"push":l.unelevated===!0?"unelevated":B}const tl={...Fr,...ha,type:{type:String,default:"button"},label:[Number,String],icon:String,iconRight:String,...$s.reduce((l,B)=>(l[B]=Boolean)&&l,{}),square:Boolean,rounded:Boolean,glossy:Boolean,size:String,fab:Boolean,fabMini:Boolean,padding:String,color:String,textColor:String,noCaps:Boolean,noWrap:Boolean,dense:Boolean,tabindex:[Number,String],ripple:{type:[Boolean,Object],default:!0},align:{...Fi.align,default:"center"},stack:Boolean,stretch:Boolean,loading:{type:Boolean,default:null},disable:Boolean},rl={...tl,round:Boolean};function nl(l){const B=jr(l,Gs),t=ji(l),{hasRouterLink:b,hasLink:m,linkTag:c,linkAttrs:i,navigateOnClick:s}=Oi({fallbackTag:"button"}),n=v.computed(()=>{const d=l.fab===!1&&l.fabMini===!1?B.value:{};return l.padding!==void 0?Object.assign({},d,{padding:l.padding.split(/\s+/).map(g=>g in go?go[g]+"px":g).join(" "),minWidth:"0",minHeight:"0"}):d}),e=v.computed(()=>l.rounded===!0||l.fab===!0||l.fabMini===!0),r=v.computed(()=>l.disable!==!0&&l.loading!==!0),u=v.computed(()=>r.value===!0?l.tabindex||0:-1),a=v.computed(()=>el(l,"standard")),o=v.computed(()=>{const d={tabindex:u.value};return m.value===!0?Object.assign(d,i.value):Js.includes(l.type)===!0&&(d.type=l.type),c.value==="a"?(l.disable===!0?d["aria-disabled"]="true":d.href===void 0&&(d.role="button"),b.value!==!0&&Zs.test(l.type)===!0&&(d.type=l.type)):l.disable===!0&&(d.disabled="",d["aria-disabled"]="true"),l.loading===!0&&l.percentage!==void 0&&Object.assign(d,{role:"progressbar","aria-valuemin":0,"aria-valuemax":100,"aria-valuenow":l.percentage}),d}),f=v.computed(()=>{let d;l.color!==void 0?l.flat===!0||l.outline===!0?d=`text-${l.textColor||l.color}`:d=`bg-${l.color} text-${l.textColor||"white"}`:l.textColor&&(d=`text-${l.textColor}`);const g=l.round===!0?"round":`rectangle${e.value===!0?" q-btn--rounded":l.square===!0?" q-btn--square":""}`;return`q-btn--${a.value} q-btn--${g}`+(d!==void 0?" "+d:"")+(r.value===!0?" q-btn--actionable q-focusable q-hoverable":l.disable===!0?" disabled":"")+(l.fab===!0?" q-btn--fab":l.fabMini===!0?" q-btn--fab-mini":"")+(l.noCaps===!0?" q-btn--no-uppercase":"")+(l.dense===!0?" q-btn--dense":"")+(l.stretch===!0?" no-border-radius self-stretch":"")+(l.glossy===!0?" glossy":"")+(l.square?" q-btn--square":"")}),h=v.computed(()=>t.value+(l.stack===!0?" column":" row")+(l.noWrap===!0?" no-wrap text-no-wrap":"")+(l.loading===!0?" q-btn__content--hidden":""));return{classes:f,style:n,innerClasses:h,attributes:o,hasLink:m,linkTag:c,navigateOnClick:s,isActionable:r}}const{passiveCapture:Nt}=_t;let Sr=null,kr=null,_r=null;const at=$e({name:"QBtn",props:{...rl,percentage:Number,darkPercentage:Boolean,onTouchstart:[Function,Array]},emits:["click","keydown","mousedown","keyup"],setup(l,{slots:B,emit:t}){const{proxy:b}=v.getCurrentInstance(),{classes:m,style:c,innerClasses:i,attributes:s,hasLink:n,linkTag:e,navigateOnClick:r,isActionable:u}=nl(l),a=v.ref(null),o=v.ref(null);let f=null,h,d=null;const g=v.computed(()=>l.label!==void 0&&l.label!==null&&l.label!==""),p=v.computed(()=>l.disable===!0||l.ripple===!1?!1:{keyCodes:n.value===!0?[13,32]:[13],...l.ripple===!0?{}:l.ripple}),k=v.computed(()=>({center:l.round})),C=v.computed(()=>{const M=Math.max(0,Math.min(100,l.percentage));return M>0?{transition:"transform 0.6s",transform:`translateX(${M-100}%)`}:{}}),T=v.computed(()=>{if(l.loading===!0)return{onMousedown:A,onTouchstart:A,onClick:A,onKeydown:A,onKeyup:A};if(u.value===!0){const M={onClick:V,onKeydown:P,onMousedown:q};if(b.$q.platform.has.touch===!0){const _=l.onTouchstart!==void 0?"":"Passive";M[`onTouchstart${_}`]=N}return M}return{onClick:St}}),D=v.computed(()=>({ref:a,class:"q-btn q-btn-item non-selectable no-outline "+m.value,style:c.value,...s.value,...T.value}));function V(M){if(a.value!==null){if(M!==void 0){if(M.defaultPrevented===!0)return;const _=document.activeElement;if(l.type==="submit"&&_!==document.body&&a.value.contains(_)===!1&&_.contains(a.value)===!1){M.qAvoidFocus!==!0&&a.value.focus();const y=()=>{document.removeEventListener("keydown",St,!0),document.removeEventListener("keyup",y,Nt),a.value?.removeEventListener("blur",y,Nt)};document.addEventListener("keydown",St,!0),document.addEventListener("keyup",y,Nt),a.value.addEventListener("blur",y,Nt)}}r(M)}}function P(M){a.value!==null&&(t("keydown",M),or(M,[13,32])===!0&&kr!==a.value&&(kr!==null&&L(),M.defaultPrevented!==!0&&(M.qAvoidFocus!==!0&&a.value.focus(),kr=a.value,a.value.classList.add("q-btn--active"),document.addEventListener("keyup",W,!0),a.value.addEventListener("blur",W,Nt)),St(M)))}function N(M){a.value!==null&&(t("touchstart",M),M.defaultPrevented!==!0&&(Sr!==a.value&&(Sr!==null&&L(),Sr=a.value,f=M.target,f.addEventListener("touchcancel",W,Nt),f.addEventListener("touchend",W,Nt)),h=!0,d!==null&&clearTimeout(d),d=setTimeout(()=>{d=null,h=!1},200)))}function q(M){a.value!==null&&(M.qSkipRipple=h===!0,t("mousedown",M),M.defaultPrevented!==!0&&_r!==a.value&&(_r!==null&&L(),_r=a.value,a.value.classList.add("q-btn--active"),document.addEventListener("mouseup",W,Nt)))}function W(M){if(a.value!==null&&!(M?.type==="blur"&&document.activeElement===a.value)){if(M?.type==="keyup"){if(kr===a.value&&or(M,[13,32])===!0){const _=new MouseEvent("click",M);_.qKeyEvent=!0,M.defaultPrevented===!0&&Bt(_),M.cancelBubble===!0&&Dt(_),a.value.dispatchEvent(_),St(M),M.qKeyEvent=!0}t("keyup",M)}L()}}function L(M){const _=o.value;M!==!0&&(Sr===a.value||_r===a.value)&&_!==null&&_!==document.activeElement&&(_.setAttribute("tabindex",-1),_.focus()),Sr===a.value&&(f!==null&&(f.removeEventListener("touchcancel",W,Nt),f.removeEventListener("touchend",W,Nt)),Sr=f=null),_r===a.value&&(document.removeEventListener("mouseup",W,Nt),_r=null),kr===a.value&&(document.removeEventListener("keyup",W,!0),a.value?.removeEventListener("blur",W,Nt),kr=null),a.value?.classList.remove("q-btn--active")}function A(M){St(M),M.qSkipRipple=!0}return v.onBeforeUnmount(()=>{L(!0)}),Object.assign(b,{click:M=>{u.value===!0&&V(M)}}),()=>{let M=[];l.icon!==void 0&&M.push(v.h(dt,{name:l.icon,left:l.stack!==!0&&g.value===!0,role:"img"})),g.value===!0&&M.push(v.h("span",{class:"block"},[l.label])),M=It(B.default,M),l.iconRight!==void 0&&l.round===!1&&M.push(v.h(dt,{name:l.iconRight,right:l.stack!==!0&&g.value===!0,role:"img"}));const _=[v.h("span",{class:"q-focus-helper",ref:o})];return l.loading===!0&&l.percentage!==void 0&&_.push(v.h("span",{class:"q-btn__progress absolute-full overflow-hidden"+(l.darkPercentage===!0?" q-btn__progress--dark":"")},[v.h("span",{class:"q-btn__progress-indicator fit block",style:C.value})])),_.push(v.h("span",{class:"q-btn__content text-center col items-center q-anchor--skip "+i.value},M)),l.loading!==null&&_.push(v.h(v.Transition,{name:"q-transition--fade"},()=>l.loading===!0?[v.h("span",{key:"loading",class:"absolute-full flex flex-center"},B.loading!==void 0?B.loading():[v.h(ga)])]:null)),v.withDirectives(v.h(e.value,D.value,_),[[va,p.value,void 0,k.value]])}}}),il={class:"row justify-between"},ol=v.defineComponent({__name:"NavButton",props:{from:{},to:{default:void 0},labelFrom:{},labelTo:{default:void 0},params:{default:()=>({})},query:{default:()=>({})}},setup(l){const B=l,t=v.inject("navContext",null),b=v.inject("router");function m(c){if(!b){console.warn("Dependencies not available:",{router:b});return}t?.setTabs();const i=c==="back"?B.from:B.to;if(!i){console.warn("Destination not provided:",c);return}b.push({name:i,params:B.params,query:B.query})}return(c,i)=>(v.openBlock(),v.createElementBlock("div",il,[v.createVNode(at,{icon:"chevron_left","rounded-sm":"",label:c.labelFrom,"data-cy":"go-back","data-testid":"go-back",onClick:i[0]||(i[0]=s=>m("back"))},null,8,["label"]),c.labelTo?(v.openBlock(),v.createBlock(at,{key:0,label:c.labelTo,color:"primary","text-color":"white","icon-right":"chevron_right","rounded-sm":"","data-cy":"go-next","data-testid":"go-next",onClick:i[1]||(i[1]=s=>m("next"))},null,8,["label"])):v.createCommentVNode("",!0)]))}}),Vt=(l,B)=>{const t=l.__vccOpts||l;for(const[b,m]of B)t[b]=m;return t},al=Vt(ol,[["__scopeId","data-v-8dd99f80"]]),Ot={dark:{type:Boolean,default:null}};function Ft(l,B){return v.computed(()=>l.dark===null?B.dark.isActive:l.dark)}function sl(l,B){const t=v.ref(null),b=v.computed(()=>l.disable===!0?null:v.h("span",{ref:t,class:"no-outline",tabindex:-1}));function m(c){const i=B.value;c?.qAvoidFocus!==!0&&(c?.type.indexOf("key")===0?document.activeElement!==i&&i?.contains(document.activeElement)===!0&&i.focus():t.value!==null&&(c===void 0||i?.contains(c.target)===!0)&&t.value.focus())}return{refocusTargetEl:b,refocusTarget:m}}const Vn={name:String};function ll(l){return v.computed(()=>({type:"hidden",name:l.name,value:l.modelValue}))}function ya(l={}){return(B,t,b)=>{B[t](v.h("input",{class:"hidden"+(b||""),...l.value}))}}function wa(l){return v.computed(()=>l.name||l.for)}const ul={xs:30,sm:35,md:40,lg:50,xl:60},xa={...Ot,...Fr,...Vn,modelValue:{required:!0,default:null},val:{},trueValue:{default:!0},falseValue:{default:!1},indeterminateValue:{default:null},checkedIcon:String,uncheckedIcon:String,indeterminateIcon:String,toggleOrder:{type:String,validator:l=>l==="tf"||l==="ft"},toggleIndeterminate:Boolean,label:String,leftLabel:Boolean,color:String,keepColor:Boolean,dense:Boolean,disable:Boolean,tabindex:[String,Number]},Sa=["update:modelValue"];function ka(l,B){const{props:t,slots:b,emit:m,proxy:c}=v.getCurrentInstance(),{$q:i}=c,s=Ft(t,i),n=v.ref(null),{refocusTargetEl:e,refocusTarget:r}=sl(t,n),u=jr(t,ul),a=v.computed(()=>t.val!==void 0&&Array.isArray(t.modelValue)),o=v.computed(()=>{const L=v.toRaw(t.val);return a.value===!0?t.modelValue.findIndex(A=>v.toRaw(A)===L):-1}),f=v.computed(()=>a.value===!0?o.value!==-1:v.toRaw(t.modelValue)===v.toRaw(t.trueValue)),h=v.computed(()=>a.value===!0?o.value===-1:v.toRaw(t.modelValue)===v.toRaw(t.falseValue)),d=v.computed(()=>f.value===!1&&h.value===!1),g=v.computed(()=>t.disable===!0?-1:t.tabindex||0),p=v.computed(()=>`q-${l} cursor-pointer no-outline row inline no-wrap items-center`+(t.disable===!0?" disabled":"")+(s.value===!0?` q-${l}--dark`:"")+(t.dense===!0?` q-${l}--dense`:"")+(t.leftLabel===!0?" reverse":"")),k=v.computed(()=>{const L=f.value===!0?"truthy":h.value===!0?"falsy":"indet",A=t.color!==void 0&&(t.keepColor===!0||(l==="toggle"?f.value===!0:h.value!==!0))?` text-${t.color}`:"";return`q-${l}__inner relative-position non-selectable q-${l}__inner--${L}${A}`}),C=v.computed(()=>{const L={type:"checkbox"};return t.name!==void 0&&Object.assign(L,{".checked":f.value,"^checked":f.value===!0?"checked":void 0,name:t.name,value:a.value===!0?t.val:t.trueValue}),L}),T=ya(C),D=v.computed(()=>{const L={tabindex:g.value,role:l==="toggle"?"switch":"checkbox","aria-label":t.label,"aria-checked":d.value===!0?"mixed":f.value===!0?"true":"false"};return t.disable===!0&&(L["aria-disabled"]="true"),L});function V(L){L!==void 0&&(St(L),r(L)),t.disable!==!0&&m("update:modelValue",P(),L)}function P(){if(a.value===!0){if(f.value===!0){const L=t.modelValue.slice();return L.splice(o.value,1),L}return t.modelValue.concat([t.val])}if(f.value===!0){if(t.toggleOrder!=="ft"||t.toggleIndeterminate===!1)return t.falseValue}else if(h.value===!0){if(t.toggleOrder==="ft"||t.toggleIndeterminate===!1)return t.trueValue}else return t.toggleOrder!=="ft"?t.trueValue:t.falseValue;return t.indeterminateValue}function N(L){(L.keyCode===13||L.keyCode===32)&&St(L)}function q(L){(L.keyCode===13||L.keyCode===32)&&V(L)}const W=B(f,d);return Object.assign(c,{toggle:V}),()=>{const L=W();t.disable!==!0&&T(L,"unshift",` q-${l}__native absolute q-ma-none q-pa-none`);const A=[v.h("div",{class:k.value,style:u.value,"aria-hidden":"true"},L)];e.value!==null&&A.push(e.value);const M=t.label!==void 0?It(b.default,[t.label]):bt(b.default);return M!==void 0&&A.push(v.h("div",{class:`q-${l}__label q-anchor--skip`},M)),v.h("div",{ref:n,class:p.value,...D.value,onClick:V,onKeydown:N,onKeyup:q},A)}}const cl=()=>v.h("div",{key:"svg",class:"q-checkbox__bg absolute"},[v.h("svg",{class:"q-checkbox__svg fit absolute-full",viewBox:"0 0 24 24"},[v.h("path",{class:"q-checkbox__truthy",fill:"none",d:"M1.73,12.91 8.1,19.28 22.79,4.59"}),v.h("path",{class:"q-checkbox__indet",d:"M4,14H20V10H4"})])]),Mr=$e({name:"QCheckbox",props:xa,emits:Sa,setup(l){const B=cl();function t(b,m){const c=v.computed(()=>(b.value===!0?l.checkedIcon:m.value===!0?l.indeterminateIcon:l.uncheckedIcon)||null);return()=>c.value!==null?[v.h("div",{key:"icon",class:"q-checkbox__icon-container absolute-full flex flex-center no-wrap"},[v.h(dt,{class:"q-checkbox__icon",name:c.value})])]:[B]}return ka("checkbox",t)}}),dl=$e({props:["store","barStyle","verticalBarStyle","horizontalBarStyle"],setup(l){return()=>[v.h("div",{class:l.store.scroll.vertical.barClass.value,style:[l.barStyle,l.verticalBarStyle],"aria-hidden":"true",onMousedown:l.store.onVerticalMousedown}),v.h("div",{class:l.store.scroll.horizontal.barClass.value,style:[l.barStyle,l.horizontalBarStyle],"aria-hidden":"true",onMousedown:l.store.onHorizontalMousedown}),v.withDirectives(v.h("div",{ref:l.store.scroll.vertical.ref,class:l.store.scroll.vertical.thumbClass.value,style:l.store.scroll.vertical.style.value,"aria-hidden":"true"}),l.store.thumbVertDir),v.withDirectives(v.h("div",{ref:l.store.scroll.horizontal.ref,class:l.store.scroll.horizontal.thumbClass.value,style:l.store.scroll.horizontal.style.value,"aria-hidden":"true"}),l.store.thumbHorizDir)]}}),ar=v.ref(!1);let gi;function fl(l,B){const t=/(edg|edge|edga|edgios)\/([\w.]+)/.exec(l)||/(opr)[\/]([\w.]+)/.exec(l)||/(vivaldi)[\/]([\w.]+)/.exec(l)||/(chrome|crios)[\/]([\w.]+)/.exec(l)||/(version)(applewebkit)[\/]([\w.]+).*(safari)[\/]([\w.]+)/.exec(l)||/(webkit)[\/]([\w.]+).*(version)[\/]([\w.]+).*(safari)[\/]([\w.]+)/.exec(l)||/(firefox|fxios)[\/]([\w.]+)/.exec(l)||/(webkit)[\/]([\w.]+)/.exec(l)||/(opera)(?:.*version|)[\/]([\w.]+)/.exec(l)||[];return{browser:t[5]||t[3]||t[1]||"",version:t[4]||t[2]||"0",platform:B[0]||""}}function hl(l){return/(ipad)/.exec(l)||/(ipod)/.exec(l)||/(windows phone)/.exec(l)||/(iphone)/.exec(l)||/(kindle)/.exec(l)||/(silk)/.exec(l)||/(android)/.exec(l)||/(win)/.exec(l)||/(mac)/.exec(l)||/(linux)/.exec(l)||/(cros)/.exec(l)||/(playbook)/.exec(l)||/(bb)/.exec(l)||/(blackberry)/.exec(l)||[]}const _a="ontouchstart"in window||window.navigator.maxTouchPoints>0;function pl(l){const B=l.toLowerCase(),t=hl(B),b=fl(B,t),m={mobile:!1,desktop:!1,cordova:!1,capacitor:!1,nativeMobile:!1,electron:!1,bex:!1,linux:!1,mac:!1,win:!1,cros:!1,chrome:!1,firefox:!1,opera:!1,safari:!1,vivaldi:!1,edge:!1,edgeChromium:!1,ie:!1,webkit:!1,android:!1,ios:!1,ipad:!1,iphone:!1,ipod:!1,kindle:!1,winphone:!1,blackberry:!1,playbook:!1,silk:!1};b.browser&&(m[b.browser]=!0,m.version=b.version,m.versionNumber=parseInt(b.version,10)),b.platform&&(m[b.platform]=!0);const c=m.android||m.ios||m.bb||m.blackberry||m.ipad||m.iphone||m.ipod||m.kindle||m.playbook||m.silk||m["windows phone"];if(c===!0||B.indexOf("mobile")!==-1?m.mobile=!0:m.desktop=!0,m["windows phone"]&&(m.winphone=!0,delete m["windows phone"]),m.edga||m.edgios||m.edg?(m.edge=!0,b.browser="edge"):m.crios?(m.chrome=!0,b.browser="chrome"):m.fxios&&(m.firefox=!0,b.browser="firefox"),(m.ipod||m.ipad||m.iphone)&&(m.ios=!0),m.vivaldi&&(b.browser="vivaldi",m.vivaldi=!0),(m.chrome||m.opr||m.safari||m.vivaldi||m.mobile===!0&&m.ios!==!0&&c!==!0)&&(m.webkit=!0),m.opr&&(b.browser="opera",m.opera=!0),m.safari&&(m.blackberry||m.bb?(b.browser="blackberry",m.blackberry=!0):m.playbook?(b.browser="playbook",m.playbook=!0):m.android?(b.browser="android",m.android=!0):m.kindle?(b.browser="kindle",m.kindle=!0):m.silk&&(b.browser="silk",m.silk=!0)),m.name=b.browser,m.platform=b.platform,B.indexOf("electron")!==-1)m.electron=!0;else if(document.location.href.indexOf("-extension://")!==-1)m.bex=!0;else{if(window.Capacitor!==void 0?(m.capacitor=!0,m.nativeMobile=!0,m.nativeMobileWrapper="capacitor"):(window._cordovaNative!==void 0||window.cordova!==void 0)&&(m.cordova=!0,m.nativeMobile=!0,m.nativeMobileWrapper="cordova"),ar.value===!0&&(gi={is:{...m}}),_a===!0&&m.mac===!0&&(m.desktop===!0&&m.safari===!0||m.nativeMobile===!0&&m.android!==!0&&m.ios!==!0&&m.ipad!==!0)){delete m.mac,delete m.desktop;const i=Math.min(window.innerHeight,window.innerWidth)>414?"ipad":"iphone";Object.assign(m,{mobile:!0,ios:!0,platform:i,[i]:!0})}m.mobile!==!0&&window.navigator.userAgentData&&window.navigator.userAgentData.mobile&&(delete m.desktop,m.mobile=!0)}return m}const bo=navigator.userAgent||navigator.vendor||window.opera,ml={has:{touch:!1,webStorage:!1},within:{iframe:!1}},Et={userAgent:bo,is:pl(bo),has:{touch:_a},within:{iframe:window.self!==window.top}},bi={install(l){const{$q:B}=l;ar.value===!0?(l.onSSRHydrated.push(()=>{Object.assign(B.platform,Et),ar.value=!1}),B.platform=v.reactive(this)):B.platform=this}};{let l;Lt(Et.has,"webStorage",()=>{if(l!==void 0)return l;try{if(window.localStorage)return l=!0,!0}catch{}return l=!1,!1}),Object.assign(bi,Et),ar.value===!0&&(Object.assign(bi,gi,ml),gi=null)}function gl(){const l=v.ref(!ar.value);return l.value===!1&&v.onMounted(()=>{l.value=!0}),{isHydrated:l}}const Ca=typeof ResizeObserver<"u",vo=Ca===!0?{}:{style:"display:block;position:absolute;top:0;left:0;right:0;bottom:0;height:100%;width:100%;overflow:hidden;pointer-events:none;z-index:-1;",url:"about:blank"},Ir=$e({name:"QResizeObserver",props:{debounce:{type:[String,Number],default:100}},emits:["resize"],setup(l,{emit:B}){let t=null,b,m={width:-1,height:-1};function c(n){n===!0||l.debounce===0||l.debounce==="0"?i():t===null&&(t=setTimeout(i,l.debounce))}function i(){if(t!==null&&(clearTimeout(t),t=null),b){const{offsetWidth:n,offsetHeight:e}=b;(n!==m.width||e!==m.height)&&(m={width:n,height:e},B("resize",m))}}const{proxy:s}=v.getCurrentInstance();if(s.trigger=c,Ca===!0){let n;const e=r=>{b=s.$el.parentNode,b?(n=new ResizeObserver(c),n.observe(b),i()):r!==!0&&v.nextTick(()=>{e(!0)})};return v.onMounted(()=>{e()}),v.onBeforeUnmount(()=>{t!==null&&clearTimeout(t),n!==void 0&&(n.disconnect!==void 0?n.disconnect():b&&n.unobserve(b))}),Ln}else{let n=function(){t!==null&&(clearTimeout(t),t=null),u!==void 0&&(u.removeEventListener!==void 0&&u.removeEventListener("resize",c,_t.passive),u=void 0)},e=function(){n(),b?.contentDocument&&(u=b.contentDocument.defaultView,u.addEventListener("resize",c,_t.passive),i())};const{isHydrated:r}=gl();let u;return v.onMounted(()=>{v.nextTick(()=>{b=s.$el,b&&e()})}),v.onBeforeUnmount(n),()=>{if(r.value===!0)return v.h("object",{class:"q--avoid-card-border",style:vo.style,tabindex:-1,type:"text/html",data:vo.url,"aria-hidden":"true",onLoad:e})}}}}),qn=[Element,String],bl=[null,document,document.body,document.scrollingElement,document.documentElement];function zn(l,B){let t=Ys(B);if(t===void 0){if(l==null)return window;t=l.closest(".scroll,.scroll-y,.overflow-auto")}return bl.includes(t)?window:t}function Pi(l){return l===window?window.pageYOffset||window.scrollY||document.body.scrollTop||0:l.scrollTop}function Ni(l){return l===window?window.pageXOffset||window.scrollX||document.body.scrollLeft||0:l.scrollLeft}function Aa(l,B,t=0){const b=arguments[3]===void 0?performance.now():arguments[3],m=Pi(l);if(t<=0){m!==B&&vi(l,B);return}requestAnimationFrame(c=>{const i=c-b,s=m+(B-m)/Math.max(i,t)*i;vi(l,s),s!==B&&Aa(l,B,t-i,c)})}function Ea(l,B,t=0){const b=arguments[3]===void 0?performance.now():arguments[3],m=Ni(l);if(t<=0){m!==B&&yi(l,B);return}requestAnimationFrame(c=>{const i=c-b,s=m+(B-m)/Math.max(i,t)*i;yi(l,s),s!==B&&Ea(l,B,t-i,c)})}function vi(l,B){if(l===window){window.scrollTo(window.pageXOffset||window.scrollX||document.body.scrollLeft||0,B);return}l.scrollTop=B}function yi(l,B){if(l===window){window.scrollTo(B,window.pageYOffset||window.scrollY||document.body.scrollTop||0);return}l.scrollLeft=B}function yo(l,B,t){if(t){Aa(l,B,t);return}vi(l,B)}function Jn(l,B,t){if(t){Ea(l,B,t);return}yi(l,B)}let un;function Sn(){if(un!==void 0)return un;const l=document.createElement("p"),B=document.createElement("div");mi(l,{width:"100%",height:"200px"}),mi(B,{position:"absolute",top:"0px",left:"0px",visibility:"hidden",width:"200px",height:"150px",overflow:"hidden"}),B.appendChild(l),document.body.appendChild(B);const t=l.offsetWidth;B.style.overflow="scroll";let b=l.offsetWidth;return t===b&&(b=B.clientWidth),B.remove(),un=t-b,un}function vl(l,B=!0){return!l||l.nodeType!==Node.ELEMENT_NODE?!1:B?l.scrollHeight>l.clientHeight&&(l.classList.contains("scroll")||l.classList.contains("overflow-auto")||["auto","scroll"].includes(window.getComputedStyle(l)["overflow-y"])):l.scrollWidth>l.clientWidth&&(l.classList.contains("scroll")||l.classList.contains("overflow-auto")||["auto","scroll"].includes(window.getComputedStyle(l)["overflow-x"]))}const{passive:wo}=_t,yl=["both","horizontal","vertical"],Ma=$e({name:"QScrollObserver",props:{axis:{type:String,validator:l=>yl.includes(l),default:"vertical"},debounce:[String,Number],scrollTarget:qn},emits:["scroll"],setup(l,{emit:B}){const t={position:{top:0,left:0},direction:"down",directionChanged:!1,delta:{top:0,left:0},inflectionPoint:{top:0,left:0}};let b=null,m,c;v.watch(()=>l.scrollTarget,()=>{n(),s()});function i(){b?.();const u=Math.max(0,Pi(m)),a=Ni(m),o={top:u-t.position.top,left:a-t.position.left};if(l.axis==="vertical"&&o.top===0||l.axis==="horizontal"&&o.left===0)return;const f=Math.abs(o.top)>=Math.abs(o.left)?o.top<0?"up":"down":o.left<0?"left":"right";t.position={top:u,left:a},t.directionChanged=t.direction!==f,t.delta=o,t.directionChanged===!0&&(t.direction=f,t.inflectionPoint=t.position),B("scroll",{...t})}function s(){m=zn(c,l.scrollTarget),m.addEventListener("scroll",e,wo),e(!0)}function n(){m!==void 0&&(m.removeEventListener("scroll",e,wo),m=void 0)}function e(u){if(u===!0||l.debounce===0||l.debounce==="0")i();else if(b===null){const[a,o]=l.debounce?[setTimeout(i,l.debounce),clearTimeout]:[requestAnimationFrame(i),cancelAnimationFrame];b=()=>{o(a),b=null}}}const{proxy:r}=v.getCurrentInstance();return v.watch(()=>r.$q.lang.rtl,i),v.onMounted(()=>{c=r.$el.parentNode,s()}),v.onBeforeUnmount(()=>{b?.(),n()}),Object.assign(r,{trigger:e,getPosition:()=>t}),Ln}}),Li={left:!0,right:!0,up:!0,down:!0,horizontal:!0,vertical:!0},wl=Object.keys(Li);Li.all=!0;function xo(l){const B={};for(const t of wl)l[t]===!0&&(B[t]=!0);return Object.keys(B).length===0?Li:(B.horizontal===!0?B.left=B.right=!0:B.left===!0&&B.right===!0&&(B.horizontal=!0),B.vertical===!0?B.up=B.down=!0:B.up===!0&&B.down===!0&&(B.vertical=!0),B.horizontal===!0&&B.vertical===!0&&(B.all=!0),B)}const xl=["INPUT","TEXTAREA"];function So(l,B){return B.event===void 0&&l.target!==void 0&&l.target.draggable!==!0&&typeof B.handler=="function"&&xl.includes(l.target.nodeName.toUpperCase())===!1&&(l.qClonedBy===void 0||l.qClonedBy.indexOf(B.uid)===-1)}function An(){if(window.getSelection!==void 0){const l=window.getSelection();l.empty!==void 0?l.empty():l.removeAllRanges!==void 0&&(l.removeAllRanges(),bi.is.mobile!==!0&&l.addRange(document.createRange()))}else document.selection!==void 0&&document.selection.empty()}function Zn(l,B,t){const b=Qr(l);let m,c=b.left-B.event.x,i=b.top-B.event.y,s=Math.abs(c),n=Math.abs(i);const e=B.direction;e.horizontal===!0&&e.vertical!==!0?m=c<0?"left":"right":e.horizontal!==!0&&e.vertical===!0?m=i<0?"up":"down":e.up===!0&&i<0?(m="up",s>n&&(e.left===!0&&c<0?m="left":e.right===!0&&c>0&&(m="right"))):e.down===!0&&i>0?(m="down",s>n&&(e.left===!0&&c<0?m="left":e.right===!0&&c>0&&(m="right"))):e.left===!0&&c<0?(m="left",s<n&&(e.up===!0&&i<0?m="up":e.down===!0&&i>0&&(m="down"))):e.right===!0&&c>0&&(m="right",s<n&&(e.up===!0&&i<0?m="up":e.down===!0&&i>0&&(m="down")));let r=!1;if(m===void 0&&t===!1){if(B.event.isFirst===!0||B.event.lastDir===void 0)return{};m=B.event.lastDir,r=!0,m==="left"||m==="right"?(b.left-=c,s=0,c=0):(b.top-=i,n=0,i=0)}return{synthetic:r,payload:{evt:l,touch:B.event.mouse!==!0,mouse:B.event.mouse===!0,position:b,direction:m,isFirst:B.event.isFirst,isFinal:t===!0,duration:Date.now()-B.event.time,distance:{x:s,y:n},offset:{x:c,y:i},delta:{x:b.left-B.event.lastX,y:b.top-B.event.lastY}}}}let Sl=0;const ko=Ti({name:"touch-pan",beforeMount(l,{value:B,modifiers:t}){if(t.mouse!==!0&&Et.has.touch!==!0)return;function b(c,i){t.mouse===!0&&i===!0?St(c):(t.stop===!0&&Dt(c),t.prevent===!0&&Bt(c))}const m={uid:"qvtp_"+Sl++,handler:B,modifiers:t,direction:xo(t),noop:Ln,mouseStart(c){So(c,m)&&Qs(c)&&(Xt(m,"temp",[[document,"mousemove","move","notPassiveCapture"],[document,"mouseup","end","passiveCapture"]]),m.start(c,!0))},touchStart(c){if(So(c,m)){const i=c.target;Xt(m,"temp",[[i,"touchmove","move","notPassiveCapture"],[i,"touchcancel","end","passiveCapture"],[i,"touchend","end","passiveCapture"]]),m.start(c)}},start(c,i){if(Et.is.firefox===!0&&Gn(l,!0),m.lastEvt=c,i===!0||t.stop===!0){if(m.direction.all!==!0&&(i!==!0||m.modifiers.mouseAllDir!==!0&&m.modifiers.mousealldir!==!0)){const e=c.type.indexOf("mouse")!==-1?new MouseEvent(c.type,c):new TouchEvent(c.type,c);c.defaultPrevented===!0&&Bt(e),c.cancelBubble===!0&&Dt(e),Object.assign(e,{qKeyEvent:c.qKeyEvent,qClickOutside:c.qClickOutside,qAnchorHandled:c.qAnchorHandled,qClonedBy:c.qClonedBy===void 0?[m.uid]:c.qClonedBy.concat(m.uid)}),m.initialEvent={target:c.target,event:e}}Dt(c)}const{left:s,top:n}=Qr(c);m.event={x:s,y:n,time:Date.now(),mouse:i===!0,detected:!1,isFirst:!0,isFinal:!1,lastX:s,lastY:n}},move(c){if(m.event===void 0)return;const i=Qr(c),s=i.left-m.event.x,n=i.top-m.event.y;if(s===0&&n===0)return;m.lastEvt=c;const e=m.event.mouse===!0,r=()=>{b(c,e);let o;t.preserveCursor!==!0&&t.preservecursor!==!0&&(o=document.documentElement.style.cursor||"",document.documentElement.style.cursor="grabbing"),e===!0&&document.body.classList.add("no-pointer-events--children"),document.body.classList.add("non-selectable"),An(),m.styleCleanup=f=>{if(m.styleCleanup=void 0,o!==void 0&&(document.documentElement.style.cursor=o),document.body.classList.remove("non-selectable"),e===!0){const h=()=>{document.body.classList.remove("no-pointer-events--children")};f!==void 0?setTimeout(()=>{h(),f()},50):h()}else f!==void 0&&f()}};if(m.event.detected===!0){m.event.isFirst!==!0&&b(c,m.event.mouse);const{payload:o,synthetic:f}=Zn(c,m,!1);o!==void 0&&(m.handler(o)===!1?m.end(c):(m.styleCleanup===void 0&&m.event.isFirst===!0&&r(),m.event.lastX=o.position.left,m.event.lastY=o.position.top,m.event.lastDir=f===!0?void 0:o.direction,m.event.isFirst=!1));return}if(m.direction.all===!0||e===!0&&(m.modifiers.mouseAllDir===!0||m.modifiers.mousealldir===!0)){r(),m.event.detected=!0,m.move(c);return}const u=Math.abs(s),a=Math.abs(n);u!==a&&(m.direction.horizontal===!0&&u>a||m.direction.vertical===!0&&u<a||m.direction.up===!0&&u<a&&n<0||m.direction.down===!0&&u<a&&n>0||m.direction.left===!0&&u>a&&s<0||m.direction.right===!0&&u>a&&s>0?(m.event.detected=!0,m.move(c)):m.end(c,!0))},end(c,i){if(m.event!==void 0){if(pr(m,"temp"),Et.is.firefox===!0&&Gn(l,!1),i===!0)m.styleCleanup?.(),m.event.detected!==!0&&m.initialEvent!==void 0&&m.initialEvent.target.dispatchEvent(m.initialEvent.event);else if(m.event.detected===!0){m.event.isFirst===!0&&m.handler(Zn(c===void 0?m.lastEvt:c,m).payload);const{payload:s}=Zn(c===void 0?m.lastEvt:c,m,!0),n=()=>{m.handler(s)};m.styleCleanup!==void 0?m.styleCleanup(n):n()}m.event=void 0,m.initialEvent=void 0,m.lastEvt=void 0}}};if(l.__qtouchpan=m,t.mouse===!0){const c=t.mouseCapture===!0||t.mousecapture===!0?"Capture":"";Xt(m,"main",[[l,"mousedown","mouseStart",`passive${c}`]])}Et.has.touch===!0&&Xt(m,"main",[[l,"touchstart","touchStart",`passive${t.capture===!0?"Capture":""}`],[l,"touchmove","noop","notPassiveCapture"]])},updated(l,B){const t=l.__qtouchpan;t!==void 0&&(B.oldValue!==B.value&&(typeof value!="function"&&t.end(),t.handler=B.value),t.direction=xo(B.modifiers))},beforeUnmount(l){const B=l.__qtouchpan;B!==void 0&&(B.event!==void 0&&B.end(),pr(B,"main"),pr(B,"temp"),Et.is.firefox===!0&&Gn(l,!1),B.styleCleanup?.(),delete l.__qtouchpan)}});function kl(l){return l.charAt(0).toUpperCase()+l.slice(1)}function Nr(l,B,t){return t<=B?B:Math.min(t,Math.max(B,l))}function _o(l,B,t){if(t<=B)return B;const b=t-B+1;let m=B+(l-B)%b;return m<B&&(m=b+m),m===0?0:m}function vt(l,B=2,t="0"){if(l==null)return l;const b=""+l;return b.length>=B?b:new Array(B-b.length+1).join(t)+b}function Vi(l,B=250,t){let b=null;function m(){const c=arguments,i=()=>{b=null,l.apply(this,c)};b!==null&&clearTimeout(b),b=setTimeout(i,B)}return m.cancel=()=>{b!==null&&clearTimeout(b)},m}const Co=["vertical","horizontal"],$n={vertical:{offset:"offsetY",scroll:"scrollTop",dir:"down",dist:"y"},horizontal:{offset:"offsetX",scroll:"scrollLeft",dir:"right",dist:"x"}},Ao={prevent:!0,mouse:!0,mouseAllDir:!0},Eo=l=>l>=250?50:Math.ceil(l/5),_l=$e({name:"QScrollArea",props:{...Ot,thumbStyle:Object,verticalThumbStyle:Object,horizontalThumbStyle:Object,barStyle:[Array,String,Object],verticalBarStyle:[Array,String,Object],horizontalBarStyle:[Array,String,Object],verticalOffset:{type:Array,default:[0,0]},horizontalOffset:{type:Array,default:[0,0]},contentStyle:[Array,String,Object],contentActiveStyle:[Array,String,Object],delay:{type:[String,Number],default:1e3},visible:{type:Boolean,default:null},tabindex:[String,Number],onScroll:Function},setup(l,{slots:B,emit:t}){const b=v.ref(!1),m=v.ref(!1),c=v.ref(!1),i={vertical:v.ref(0),horizontal:v.ref(0)},s={vertical:{ref:v.ref(null),position:v.ref(0),size:v.ref(0)},horizontal:{ref:v.ref(null),position:v.ref(0),size:v.ref(0)}},{proxy:n}=v.getCurrentInstance(),e=Ft(l,n.$q);let r=null,u;const a=v.ref(null),o=v.computed(()=>"q-scrollarea"+(e.value===!0?" q-scrollarea--dark":""));Object.assign(i,{verticalInner:v.computed(()=>i.vertical.value-l.verticalOffset[0]-l.verticalOffset[1]),horizontalInner:v.computed(()=>i.horizontal.value-l.horizontalOffset[0]-l.horizontalOffset[1])}),s.vertical.percentage=v.computed(()=>{const M=s.vertical.size.value-i.vertical.value;if(M<=0)return 0;const _=Nr(s.vertical.position.value/M,0,1);return Math.round(_*1e4)/1e4}),s.vertical.thumbHidden=v.computed(()=>(l.visible===null?c.value:l.visible)!==!0&&b.value===!1&&m.value===!1||s.vertical.size.value<=i.vertical.value+1),s.vertical.thumbStart=v.computed(()=>l.verticalOffset[0]+s.vertical.percentage.value*(i.verticalInner.value-s.vertical.thumbSize.value)),s.vertical.thumbSize=v.computed(()=>Math.round(Nr(i.verticalInner.value*i.verticalInner.value/s.vertical.size.value,Eo(i.verticalInner.value),i.verticalInner.value))),s.vertical.style=v.computed(()=>({...l.thumbStyle,...l.verticalThumbStyle,top:`${s.vertical.thumbStart.value}px`,height:`${s.vertical.thumbSize.value}px`,right:`${l.horizontalOffset[1]}px`})),s.vertical.thumbClass=v.computed(()=>"q-scrollarea__thumb q-scrollarea__thumb--v absolute-right"+(s.vertical.thumbHidden.value===!0?" q-scrollarea__thumb--invisible":"")),s.vertical.barClass=v.computed(()=>"q-scrollarea__bar q-scrollarea__bar--v absolute-right"+(s.vertical.thumbHidden.value===!0?" q-scrollarea__bar--invisible":"")),s.horizontal.percentage=v.computed(()=>{const M=s.horizontal.size.value-i.horizontal.value;if(M<=0)return 0;const _=Nr(Math.abs(s.horizontal.position.value)/M,0,1);return Math.round(_*1e4)/1e4}),s.horizontal.thumbHidden=v.computed(()=>(l.visible===null?c.value:l.visible)!==!0&&b.value===!1&&m.value===!1||s.horizontal.size.value<=i.horizontal.value+1),s.horizontal.thumbStart=v.computed(()=>l.horizontalOffset[0]+s.horizontal.percentage.value*(i.horizontalInner.value-s.horizontal.thumbSize.value)),s.horizontal.thumbSize=v.computed(()=>Math.round(Nr(i.horizontalInner.value*i.horizontalInner.value/s.horizontal.size.value,Eo(i.horizontalInner.value),i.horizontalInner.value))),s.horizontal.style=v.computed(()=>({...l.thumbStyle,...l.horizontalThumbStyle,[n.$q.lang.rtl===!0?"right":"left"]:`${s.horizontal.thumbStart.value}px`,width:`${s.horizontal.thumbSize.value}px`,bottom:`${l.verticalOffset[1]}px`})),s.horizontal.thumbClass=v.computed(()=>"q-scrollarea__thumb q-scrollarea__thumb--h absolute-bottom"+(s.horizontal.thumbHidden.value===!0?" q-scrollarea__thumb--invisible":"")),s.horizontal.barClass=v.computed(()=>"q-scrollarea__bar q-scrollarea__bar--h absolute-bottom"+(s.horizontal.thumbHidden.value===!0?" q-scrollarea__bar--invisible":""));const f=v.computed(()=>s.vertical.thumbHidden.value===!0&&s.horizontal.thumbHidden.value===!0?l.contentStyle:l.contentActiveStyle);function h(){const M={};return Co.forEach(_=>{const y=s[_];Object.assign(M,{[_+"Position"]:y.position.value,[_+"Percentage"]:y.percentage.value,[_+"Size"]:y.size.value,[_+"ContainerSize"]:i[_].value,[_+"ContainerInnerSize"]:i[_+"Inner"].value})}),M}const d=Vi(()=>{const M=h();M.ref=n,t("scroll",M)},0);function g(M,_,y){if(Co.includes(M)===!1){console.error("[QScrollArea]: wrong first param of setScrollPosition (vertical/horizontal)");return}(M==="vertical"?yo:Jn)(a.value,_,y)}function p({height:M,width:_}){let y=!1;i.vertical.value!==M&&(i.vertical.value=M,y=!0),i.horizontal.value!==_&&(i.horizontal.value=_,y=!0),y===!0&&V()}function k({position:M}){let _=!1;s.vertical.position.value!==M.top&&(s.vertical.position.value=M.top,_=!0),s.horizontal.position.value!==M.left&&(s.horizontal.position.value=M.left,_=!0),_===!0&&V()}function C({height:M,width:_}){s.horizontal.size.value!==_&&(s.horizontal.size.value=_,V()),s.vertical.size.value!==M&&(s.vertical.size.value=M,V())}function T(M,_){const y=s[_];if(M.isFirst===!0){if(y.thumbHidden.value===!0)return;u=y.position.value,m.value=!0}else if(m.value!==!0)return;M.isFinal===!0&&(m.value=!1);const x=$n[_],w=(y.size.value-i[_].value)/(i[_+"Inner"].value-y.thumbSize.value),S=M.distance[x.dist],E=u+(M.direction===x.dir?1:-1)*S*w;P(E,_)}function D(M,_){const y=s[_];if(y.thumbHidden.value!==!0){const x=_==="vertical"?l.verticalOffset[0]:l.horizontalOffset[0],w=M[$n[_].offset]-x,S=y.thumbStart.value-x;if(w<S||w>S+y.thumbSize.value){const E=w-y.thumbSize.value/2,O=Nr(E/(i[_+"Inner"].value-y.thumbSize.value),0,1);P(O*Math.max(0,y.size.value-i[_].value),_)}y.ref.value!==null&&y.ref.value.dispatchEvent(new MouseEvent(M.type,M))}}function V(){b.value=!0,r!==null&&clearTimeout(r),r=setTimeout(()=>{r=null,b.value=!1},l.delay),l.onScroll!==void 0&&d()}function P(M,_){a.value[$n[_].scroll]=M}let N=null;function q(){N!==null&&clearTimeout(N),N=setTimeout(()=>{N=null,c.value=!0},n.$q.platform.is.ios?50:0)}function W(){N!==null&&(clearTimeout(N),N=null),c.value=!1}let L=null;v.watch(()=>n.$q.lang.rtl,M=>{a.value!==null&&Jn(a.value,Math.abs(s.horizontal.position.value)*(M===!0?-1:1))}),v.onDeactivated(()=>{L={top:s.vertical.position.value,left:s.horizontal.position.value}}),v.onActivated(()=>{if(L===null)return;const M=a.value;M!==null&&(Jn(M,L.left),yo(M,L.top))}),v.onBeforeUnmount(d.cancel),Object.assign(n,{getScrollTarget:()=>a.value,getScroll:h,getScrollPosition:()=>({top:s.vertical.position.value,left:s.horizontal.position.value}),getScrollPercentage:()=>({top:s.vertical.percentage.value,left:s.horizontal.percentage.value}),setScrollPosition:g,setScrollPercentage(M,_,y){g(M,_*(s[M].size.value-i[M].value)*(M==="horizontal"&&n.$q.lang.rtl===!0?-1:1),y)}});const A={scroll:s,thumbVertDir:[[ko,M=>{T(M,"vertical")},void 0,{vertical:!0,...Ao}]],thumbHorizDir:[[ko,M=>{T(M,"horizontal")},void 0,{horizontal:!0,...Ao}]],onVerticalMousedown(M){D(M,"vertical")},onHorizontalMousedown(M){D(M,"horizontal")}};return()=>v.h("div",{class:o.value,onMouseenter:q,onMouseleave:W},[v.h("div",{ref:a,class:"q-scrollarea__container scroll relative-position fit hide-scrollbar",tabindex:l.tabindex!==void 0?l.tabindex:void 0},[v.h("div",{class:"q-scrollarea__content absolute",style:f.value},It(B.default,[v.h(Ir,{debounce:0,onResize:C})])),v.h(Ma,{axis:"both",onScroll:k})]),v.h(Ir,{debounce:0,onResize:p}),v.h(dl,{store:A,barStyle:l.barStyle,verticalBarStyle:l.verticalBarStyle,horizontalBarStyle:l.horizontalBarStyle})])}}),Dr=$e({name:"QCard",props:{...Ot,tag:{type:String,default:"div"},square:Boolean,flat:Boolean,bordered:Boolean},setup(l,{slots:B}){const{proxy:{$q:t}}=v.getCurrentInstance(),b=Ft(l,t),m=v.computed(()=>"q-card"+(b.value===!0?" q-card--dark q-dark":"")+(l.bordered===!0?" q-card--bordered":"")+(l.square===!0?" q-card--square no-border-radius":"")+(l.flat===!0?" q-card--flat no-shadow":""));return()=>v.h(l.tag,{class:m.value},bt(B.default))}}),Ta={target:{type:[Boolean,String,Element],default:!0},noParentEvent:Boolean},Ra={...Ta,contextMenu:Boolean};function qi({showing:l,avoidEmit:B,configureAnchorEl:t}){const{props:b,proxy:m,emit:c}=v.getCurrentInstance(),i=v.ref(null);let s=null;function n(o){return i.value===null?!1:o===void 0||o.touches===void 0||o.touches.length<=1}const e={};t===void 0&&(Object.assign(e,{hide(o){m.hide(o)},toggle(o){m.toggle(o),o.qAnchorHandled=!0},toggleKey(o){or(o,13)===!0&&e.toggle(o)},contextClick(o){m.hide(o),Bt(o),v.nextTick(()=>{m.show(o),o.qAnchorHandled=!0})},prevent:Bt,mobileTouch(o){if(e.mobileCleanup(o),n(o)!==!0)return;m.hide(o),i.value.classList.add("non-selectable");const f=o.target;Xt(e,"anchor",[[f,"touchmove","mobileCleanup","passive"],[f,"touchend","mobileCleanup","passive"],[f,"touchcancel","mobileCleanup","passive"],[i.value,"contextmenu","prevent","notPassive"]]),s=setTimeout(()=>{s=null,m.show(o),o.qAnchorHandled=!0},300)},mobileCleanup(o){i.value.classList.remove("non-selectable"),s!==null&&(clearTimeout(s),s=null),l.value===!0&&o!==void 0&&An()}}),t=function(o=b.contextMenu){if(b.noParentEvent===!0||i.value===null)return;let f;o===!0?m.$q.platform.is.mobile===!0?f=[[i.value,"touchstart","mobileTouch","passive"]]:f=[[i.value,"mousedown","hide","passive"],[i.value,"contextmenu","contextClick","notPassive"]]:f=[[i.value,"click","toggle","passive"],[i.value,"keyup","toggleKey","passive"]],Xt(e,"anchor",f)});function r(){pr(e,"anchor")}function u(o){for(i.value=o;i.value.classList.contains("q-anchor--skip");)i.value=i.value.parentNode;t()}function a(){if(b.target===!1||b.target===""||m.$el.parentNode===null)i.value=null;else if(b.target===!0)u(m.$el.parentNode);else{let o=b.target;if(typeof b.target=="string")try{o=document.querySelector(b.target)}catch{o=void 0}o!=null?(i.value=o.$el||o,t()):(i.value=null,console.error(`Anchor: target "${b.target}" not found`))}}return v.watch(()=>b.contextMenu,o=>{i.value!==null&&(r(),t(o))}),v.watch(()=>b.target,()=>{i.value!==null&&r(),a()}),v.watch(()=>b.noParentEvent,o=>{i.value!==null&&(o===!0?r():t())}),v.onMounted(()=>{a(),B!==!0&&b.modelValue===!0&&i.value===null&&c("update:modelValue",!1)}),v.onBeforeUnmount(()=>{s!==null&&clearTimeout(s),r()}),{anchorEl:i,canShow:n,anchorEvents:e}}function Ba(l,B){const t=v.ref(null);let b;function m(s,n){const e=`${n!==void 0?"add":"remove"}EventListener`,r=n!==void 0?n:b;s!==window&&s[e]("scroll",r,_t.passive),window[e]("scroll",r,_t.passive),b=n}function c(){t.value!==null&&(m(t.value),t.value=null)}const i=v.watch(()=>l.noParentEvent,()=>{t.value!==null&&(c(),B())});return v.onBeforeUnmount(i),{localScrollTarget:t,unconfigureScrollTarget:c,changeScrollEvent:m}}const zi={modelValue:{type:Boolean,default:null},"onUpdate:modelValue":[Function,Array]},Ui=["beforeShow","show","beforeHide","hide"];function Wi({showing:l,canShow:B,hideOnRouteChange:t,handleShow:b,handleHide:m,processOnMount:c}){const i=v.getCurrentInstance(),{props:s,emit:n,proxy:e}=i;let r;function u(p){l.value===!0?f(p):a(p)}function a(p){if(s.disable===!0||p?.qAnchorHandled===!0||B!==void 0&&B(p)!==!0)return;const k=s["onUpdate:modelValue"]!==void 0;k===!0&&(n("update:modelValue",!0),r=p,v.nextTick(()=>{r===p&&(r=void 0)})),(s.modelValue===null||k===!1)&&o(p)}function o(p){l.value!==!0&&(l.value=!0,n("beforeShow",p),b!==void 0?b(p):n("show",p))}function f(p){if(s.disable===!0)return;const k=s["onUpdate:modelValue"]!==void 0;k===!0&&(n("update:modelValue",!1),r=p,v.nextTick(()=>{r===p&&(r=void 0)})),(s.modelValue===null||k===!1)&&h(p)}function h(p){l.value!==!1&&(l.value=!1,n("beforeHide",p),m!==void 0?m(p):n("hide",p))}function d(p){s.disable===!0&&p===!0?s["onUpdate:modelValue"]!==void 0&&n("update:modelValue",!1):p===!0!==l.value&&(p===!0?o:h)(r)}v.watch(()=>s.modelValue,d),t!==void 0&&Bi(i)===!0&&v.watch(()=>e.$route.fullPath,()=>{t.value===!0&&l.value===!0&&f()}),v.onMounted(()=>{d(s.modelValue)});const g={show:a,hide:f,toggle:u};return Object.assign(e,g),g}let fr=[],Kr=[];function Ia(l){Kr=Kr.filter(B=>B!==l)}function Cl(l){Ia(l),Kr.push(l)}function Mo(l){Ia(l),Kr.length===0&&fr.length!==0&&(fr[fr.length-1](),fr=[])}function Jr(l){Kr.length===0?l():fr.push(l)}function Al(l){fr=fr.filter(B=>B!==l)}const To={};let El=1,Ml=document.body;function Tl(l,B){const t=document.createElement("div");if(t.id=B!==void 0?`q-portal--${B}--${El++}`:l,To.globalNodes!==void 0){const b=To.globalNodes.class;b!==void 0&&(t.className=b)}return Ml.appendChild(t),t}function Rl(l){l.remove()}const Tr=[];function Bl(l){return Tr.find(B=>B.contentEl!==null&&B.contentEl.contains(l))}function Oa(l,B){do{if(l.$options.name==="QMenu"){if(l.hide(B),l.$props.separateClosePopup===!0)return xn(l)}else if(l.__qPortal===!0){const t=xn(l);return t?.$options.name==="QPopupProxy"?(l.hide(B),t):l}l=xn(l)}while(l!=null)}function Il(l,B,t){for(;t!==0&&l!==void 0&&l!==null;){if(l.__qPortal===!0){if(t--,l.$options.name==="QMenu"){l=Oa(l,B);continue}l.hide(B)}l=xn(l)}}const Ol=$e({name:"QPortal",setup(l,{slots:B}){return()=>B.default()}});function Fl(l){for(l=l.parent;l!=null;){if(l.type.name==="QGlobalDialog")return!0;if(l.type.name==="QDialog"||l.type.name==="QMenu")return!1;l=l.parent}return!1}function Hi(l,B,t,b){const m=v.ref(!1),c=v.ref(!1);let i=null;const s={},n=b==="dialog"&&Fl(l);function e(u){if(u===!0){Mo(s),c.value=!0;return}c.value=!1,m.value===!1&&(n===!1&&i===null&&(i=Tl(!1,b)),m.value=!0,Tr.push(l.proxy),Cl(s))}function r(u){if(c.value=!1,u!==!0)return;Mo(s),m.value=!1;const a=Tr.indexOf(l.proxy);a!==-1&&Tr.splice(a,1),i!==null&&(Rl(i),i=null)}return v.onUnmounted(()=>{r(!0)}),l.proxy.__qPortal=!0,Lt(l.proxy,"contentEl",()=>B.value),{showPortal:e,hidePortal:r,portalIsActive:m,portalIsAccessible:c,renderPortal:()=>n===!0?t():m.value===!0?[v.h(v.Teleport,{to:i},v.h(Ol,t))]:void 0}}const Yr={transitionShow:{type:String,default:"fade"},transitionHide:{type:String,default:"fade"},transitionDuration:{type:[String,Number],default:300}};function Yi(l,B=()=>{},t=()=>{}){return{transitionProps:v.computed(()=>{const b=`q-transition--${l.transitionShow||B()}`,m=`q-transition--${l.transitionHide||t()}`;return{appear:!0,enterFromClass:`${b}-enter-from`,enterActiveClass:`${b}-enter-active`,enterToClass:`${b}-enter-to`,leaveFromClass:`${m}-leave-from`,leaveActiveClass:`${m}-leave-active`,leaveToClass:`${m}-leave-to`}}),transitionStyle:v.computed(()=>`--q-transition-duration: ${l.transitionDuration}ms`)}}function Qi(){let l;const B=v.getCurrentInstance();function t(){l=void 0}return v.onDeactivated(t),v.onBeforeUnmount(t),{removeTick:t,registerTick(b){l=b,v.nextTick(()=>{l===b&&(Ii(B)===!1&&l(),l=void 0)})}}}function Ki(){let l=null;const B=v.getCurrentInstance();function t(){l!==null&&(clearTimeout(l),l=null)}return v.onDeactivated(t),v.onBeforeUnmount(t),{removeTimeout:t,registerTimeout(b,m){t(),Ii(B)===!1&&(l=setTimeout(()=>{l=null,b()},m))}}}const mr=[];let Or;function jl(l){Or=l.keyCode===27}function Dl(){Or===!0&&(Or=!1)}function Pl(l){Or===!0&&(Or=!1,or(l,27)===!0&&mr[mr.length-1](l))}function Fa(l){window[l]("keydown",jl),window[l]("blur",Dl),window[l]("keyup",Pl),Or=!1}function ja(l){Et.is.desktop===!0&&(mr.push(l),mr.length===1&&Fa("addEventListener"))}function En(l){const B=mr.indexOf(l);B!==-1&&(mr.splice(B,1),mr.length===0&&Fa("removeEventListener"))}const gr=[];function Da(l){gr[gr.length-1](l)}function Pa(l){Et.is.desktop===!0&&(gr.push(l),gr.length===1&&document.body.addEventListener("focusin",Da))}function wi(l){const B=gr.indexOf(l);B!==-1&&(gr.splice(B,1),gr.length===0&&document.body.removeEventListener("focusin",Da))}const{notPassiveCapture:Mn}=_t,br=[];function Tn(l){const B=l.target;if(B===void 0||B.nodeType===8||B.classList.contains("no-pointer-events")===!0)return;let t=Tr.length-1;for(;t>=0;){const b=Tr[t].$;if(b.type.name==="QTooltip"){t--;continue}if(b.type.name!=="QDialog")break;if(b.props.seamless!==!0)return;t--}for(let b=br.length-1;b>=0;b--){const m=br[b];if((m.anchorEl.value===null||m.anchorEl.value.contains(B)===!1)&&(B===document.body||m.innerRef.value!==null&&m.innerRef.value.contains(B)===!1))l.qClickOutside=!0,m.onClickOutside(l);else return}}function Na(l){br.push(l),br.length===1&&(document.addEventListener("mousedown",Tn,Mn),document.addEventListener("touchstart",Tn,Mn))}function Rn(l){const B=br.findIndex(t=>t===l);B!==-1&&(br.splice(B,1),br.length===0&&(document.removeEventListener("mousedown",Tn,Mn),document.removeEventListener("touchstart",Tn,Mn)))}let Ro,Bo;function Bn(l){const B=l.split(" ");return B.length!==2?!1:["top","center","bottom"].includes(B[0])!==!0?(console.error("Anchor/Self position must start with one of top/center/bottom"),!1):["left","middle","right","start","end"].includes(B[1])!==!0?(console.error("Anchor/Self position must end with one of left/middle/right/start/end"),!1):!0}function La(l){return l?!(l.length!==2||typeof l[0]!="number"||typeof l[1]!="number"):!0}const xi={"start#ltr":"left","start#rtl":"right","end#ltr":"right","end#rtl":"left"};["left","middle","right"].forEach(l=>{xi[`${l}#ltr`]=l,xi[`${l}#rtl`]=l});function In(l,B){const t=l.split(" ");return{vertical:t[0],horizontal:xi[`${t[1]}#${B===!0?"rtl":"ltr"}`]}}function Nl(l,B){let{top:t,left:b,right:m,bottom:c,width:i,height:s}=l.getBoundingClientRect();return B!==void 0&&(t-=B[1],b-=B[0],c+=B[1],m+=B[0],i+=B[0],s+=B[1]),{top:t,bottom:c,height:s,left:b,right:m,width:i,middle:b+(m-b)/2,center:t+(c-t)/2}}function Ll(l,B,t){let{top:b,left:m}=l.getBoundingClientRect();return b+=B.top,m+=B.left,t!==void 0&&(b+=t[1],m+=t[0]),{top:b,bottom:b+1,height:1,left:m,right:m+1,width:1,middle:m,center:b}}function Vl(l,B){return{top:0,center:B/2,bottom:B,left:0,middle:l/2,right:l}}function Io(l,B,t,b){return{top:l[t.vertical]-B[b.vertical],left:l[t.horizontal]-B[b.horizontal]}}function Xi(l,B=0){if(l.targetEl===null||l.anchorEl===null||B>5)return;if(l.targetEl.offsetHeight===0||l.targetEl.offsetWidth===0){setTimeout(()=>{Xi(l,B+1)},10);return}const{targetEl:t,offset:b,anchorEl:m,anchorOrigin:c,selfOrigin:i,absoluteOffset:s,fit:n,cover:e,maxHeight:r,maxWidth:u}=l;if(Et.is.ios===!0&&window.visualViewport!==void 0){const D=document.body.style,{offsetLeft:V,offsetTop:P}=window.visualViewport;V!==Ro&&(D.setProperty("--q-pe-left",V+"px"),Ro=V),P!==Bo&&(D.setProperty("--q-pe-top",P+"px"),Bo=P)}const{scrollLeft:a,scrollTop:o}=t,f=s===void 0?Nl(m,e===!0?[0,0]:b):Ll(m,s,b);Object.assign(t.style,{top:0,left:0,minWidth:null,minHeight:null,maxWidth:u,maxHeight:r,visibility:"visible"});const{offsetWidth:h,offsetHeight:d}=t,{elWidth:g,elHeight:p}=n===!0||e===!0?{elWidth:Math.max(f.width,h),elHeight:e===!0?Math.max(f.height,d):d}:{elWidth:h,elHeight:d};let k={maxWidth:u,maxHeight:r};(n===!0||e===!0)&&(k.minWidth=f.width+"px",e===!0&&(k.minHeight=f.height+"px")),Object.assign(t.style,k);const C=Vl(g,p);let T=Io(f,C,c,i);if(s===void 0||b===void 0)ei(T,f,C,c,i);else{const{top:D,left:V}=T;ei(T,f,C,c,i);let P=!1;if(T.top!==D){P=!0;const N=2*b[1];f.center=f.top-=N,f.bottom-=N+2}if(T.left!==V){P=!0;const N=2*b[0];f.middle=f.left-=N,f.right-=N+2}P===!0&&(T=Io(f,C,c,i),ei(T,f,C,c,i))}k={top:T.top+"px",left:T.left+"px"},T.maxHeight!==void 0&&(k.maxHeight=T.maxHeight+"px",f.height>T.maxHeight&&(k.minHeight=k.maxHeight)),T.maxWidth!==void 0&&(k.maxWidth=T.maxWidth+"px",f.width>T.maxWidth&&(k.minWidth=k.maxWidth)),Object.assign(t.style,k),t.scrollTop!==o&&(t.scrollTop=o),t.scrollLeft!==a&&(t.scrollLeft=a)}function ei(l,B,t,b,m){const c=t.bottom,i=t.right,s=Sn(),n=window.innerHeight-s,e=document.body.clientWidth;if(l.top<0||l.top+c>n)if(m.vertical==="center")l.top=B[b.vertical]>n/2?Math.max(0,n-c):0,l.maxHeight=Math.min(c,n);else if(B[b.vertical]>n/2){const r=Math.min(n,b.vertical==="center"?B.center:b.vertical===m.vertical?B.bottom:B.top);l.maxHeight=Math.min(c,r),l.top=Math.max(0,r-c)}else l.top=Math.max(0,b.vertical==="center"?B.center:b.vertical===m.vertical?B.top:B.bottom),l.maxHeight=Math.min(c,n-l.top);if(l.left<0||l.left+i>e)if(l.maxWidth=Math.min(i,e),m.horizontal==="middle")l.left=B[b.horizontal]>e/2?Math.max(0,e-i):0;else if(B[b.horizontal]>e/2){const r=Math.min(e,b.horizontal==="middle"?B.middle:b.horizontal===m.horizontal?B.right:B.left);l.maxWidth=Math.min(i,r),l.left=Math.max(0,r-l.maxWidth)}else l.left=Math.max(0,b.horizontal==="middle"?B.middle:b.horizontal===m.horizontal?B.left:B.right),l.maxWidth=Math.min(i,e-l.left)}const Zr=$e({name:"QMenu",inheritAttrs:!1,props:{...Ra,...zi,...Ot,...Yr,persistent:Boolean,autoClose:Boolean,separateClosePopup:Boolean,noEscDismiss:Boolean,noRouteDismiss:Boolean,noRefocus:Boolean,noFocus:Boolean,fit:Boolean,cover:Boolean,square:Boolean,anchor:{type:String,validator:Bn},self:{type:String,validator:Bn},offset:{type:Array,validator:La},scrollTarget:qn,touchPosition:Boolean,maxHeight:{type:String,default:null},maxWidth:{type:String,default:null}},emits:[...Ui,"click","escapeKey"],setup(l,{slots:B,emit:t,attrs:b}){let m=null,c,i,s;const n=v.getCurrentInstance(),{proxy:e}=n,{$q:r}=e,u=v.ref(null),a=v.ref(!1),o=v.computed(()=>l.persistent!==!0&&l.noRouteDismiss!==!0),f=Ft(l,r),{registerTick:h,removeTick:d}=Qi(),{registerTimeout:g}=Ki(),{transitionProps:p,transitionStyle:k}=Yi(l),{localScrollTarget:C,changeScrollEvent:T,unconfigureScrollTarget:D}=Ba(l,z),{anchorEl:V,canShow:P}=qi({showing:a}),{hide:N}=Wi({showing:a,canShow:P,handleShow:E,handleHide:O,hideOnRouteChange:o,processOnMount:!0}),{showPortal:q,hidePortal:W,renderPortal:L}=Hi(n,u,F,"menu"),A={anchorEl:V,innerRef:u,onClickOutside(I){if(l.persistent!==!0&&a.value===!0)return N(I),(I.type==="touchstart"||I.target.classList.contains("q-dialog__backdrop"))&&St(I),!0}},M=v.computed(()=>In(l.anchor||(l.cover===!0?"center middle":"bottom start"),r.lang.rtl)),_=v.computed(()=>l.cover===!0?M.value:In(l.self||"top start",r.lang.rtl)),y=v.computed(()=>(l.square===!0?" q-menu--square":"")+(f.value===!0?" q-menu--dark q-dark":"")),x=v.computed(()=>l.autoClose===!0?{onClick:U}:{}),w=v.computed(()=>a.value===!0&&l.persistent!==!0);v.watch(w,I=>{I===!0?(ja(j),Na(A)):(En(j),Rn(A))});function S(){Jr(()=>{let I=u.value;I&&I.contains(document.activeElement)!==!0&&(I=I.querySelector("[autofocus][tabindex], [data-autofocus][tabindex]")||I.querySelector("[autofocus] [tabindex], [data-autofocus] [tabindex]")||I.querySelector("[autofocus], [data-autofocus]")||I,I.focus({preventScroll:!0}))})}function E(I){if(m=l.noRefocus===!1?document.activeElement:null,Pa(Q),q(),z(),c=void 0,I!==void 0&&(l.touchPosition||l.contextMenu)){const H=Qr(I);if(H.left!==void 0){const{top:K,left:ee}=V.value.getBoundingClientRect();c={left:H.left-ee,top:H.top-K}}}i===void 0&&(i=v.watch(()=>r.screen.width+"|"+r.screen.height+"|"+l.self+"|"+l.anchor+"|"+r.lang.rtl,Y)),l.noFocus!==!0&&document.activeElement.blur(),h(()=>{Y(),l.noFocus!==!0&&S()}),g(()=>{r.platform.is.ios===!0&&(s=l.autoClose,u.value.click()),Y(),q(!0),t("show",I)},l.transitionDuration)}function O(I){d(),W(),R(!0),m!==null&&(I===void 0||I.qClickOutside!==!0)&&(((I?.type.indexOf("key")===0?m.closest('[tabindex]:not([tabindex^="-"])'):void 0)||m).focus(),m=null),g(()=>{W(!0),t("hide",I)},l.transitionDuration)}function R(I){c=void 0,i!==void 0&&(i(),i=void 0),(I===!0||a.value===!0)&&(wi(Q),D(),Rn(A),En(j)),I!==!0&&(m=null)}function z(){(V.value!==null||l.scrollTarget!==void 0)&&(C.value=zn(V.value,l.scrollTarget),T(C.value,Y))}function U(I){s!==!0?(Oa(e,I),t("click",I)):s=!1}function Q(I){w.value===!0&&l.noFocus!==!0&&ba(u.value,I.target)!==!0&&S()}function j(I){l.noEscDismiss!==!0&&(t("escapeKey"),N(I))}function Y(){Xi({targetEl:u.value,offset:l.offset,anchorEl:V.value,anchorOrigin:M.value,selfOrigin:_.value,absoluteOffset:c,fit:l.fit,cover:l.cover,maxHeight:l.maxHeight,maxWidth:l.maxWidth})}function F(){return v.h(v.Transition,p.value,()=>a.value===!0?v.h("div",{role:"menu",...b,ref:u,tabindex:-1,class:["q-menu q-position-engine scroll"+y.value,b.class],style:[b.style,k.value],...x.value},bt(B.default)):null)}return v.onBeforeUnmount(R),Object.assign(e,{focus:S,updatePosition:Y}),L}});let ti,cn=0;const Mt=new Array(256);for(let l=0;l<256;l++)Mt[l]=(l+256).toString(16).substring(1);const ql=(()=>{const l=typeof crypto<"u"?crypto:typeof window<"u"?window.crypto||window.msCrypto:void 0;if(l!==void 0){if(l.randomBytes!==void 0)return l.randomBytes;if(l.getRandomValues!==void 0)return B=>{const t=new Uint8Array(B);return l.getRandomValues(t),t}}return B=>{const t=[];for(let b=B;b>0;b--)t.push(Math.floor(Math.random()*256));return t}})(),Oo=4096;function Si(){(ti===void 0||cn+16>Oo)&&(cn=0,ti=ql(Oo));const l=Array.prototype.slice.call(ti,cn,cn+=16);return l[6]=l[6]&15|64,l[8]=l[8]&63|128,Mt[l[0]]+Mt[l[1]]+Mt[l[2]]+Mt[l[3]]+"-"+Mt[l[4]]+Mt[l[5]]+"-"+Mt[l[6]]+Mt[l[7]]+"-"+Mt[l[8]]+Mt[l[9]]+"-"+Mt[l[10]]+Mt[l[11]]+Mt[l[12]]+Mt[l[13]]+Mt[l[14]]+Mt[l[15]]}function zl(l){return l??null}function Fo(l,B){return l??(B===!0?`f_${Si()}`:null)}function Ul({getValue:l,required:B=!0}={}){if(ar.value===!0){const t=l!==void 0?v.ref(zl(l())):v.ref(null);return B===!0&&t.value===null&&v.onMounted(()=>{t.value=`f_${Si()}`}),l!==void 0&&v.watch(l,b=>{t.value=Fo(b,B)}),t}return l!==void 0?v.computed(()=>Fo(l(),B)):v.ref(`f_${Si()}`)}const jo=/^on[A-Z]/;function Wl(){const{attrs:l,vnode:B}=v.getCurrentInstance(),t={listeners:v.ref({}),attributes:v.ref({})};function b(){const m={},c={};for(const i in l)i!=="class"&&i!=="style"&&jo.test(i)===!1&&(m[i]=l[i]);for(const i in B.props)jo.test(i)===!0&&(c[i]=B.props[i]);t.attributes.value=m,t.listeners.value=c}return v.onBeforeUpdate(b),b(),t}const Hl="_q_",$r="_q_l_",Va="_q_pc_",qa="_q_fo_";function Rt(){}function Yl({validate:l,resetValidation:B,requiresQForm:t}){const b=v.inject(qa,!1);if(b!==!1){const{props:m,proxy:c}=v.getCurrentInstance();Object.assign(c,{validate:l,resetValidation:B}),v.watch(()=>m.disable,i=>{i===!0?(typeof B=="function"&&B(),b.unbindComponent(c)):b.bindComponent(c)}),v.onMounted(()=>{m.disable!==!0&&b.bindComponent(c)}),v.onBeforeUnmount(()=>{m.disable!==!0&&b.unbindComponent(c)})}else t===!0&&console.error("Parent QForm not found on useFormChild()!")}const Do=/^#[0-9a-fA-F]{3}([0-9a-fA-F]{3})?$/,Po=/^#[0-9a-fA-F]{4}([0-9a-fA-F]{4})?$/,No=/^#([0-9a-fA-F]{3}|[0-9a-fA-F]{4}|[0-9a-fA-F]{6}|[0-9a-fA-F]{8})$/,dn=/^rgb\(((0|[1-9][\d]?|1[\d]{0,2}|2[\d]?|2[0-4][\d]|25[0-5]),){2}(0|[1-9][\d]?|1[\d]{0,2}|2[\d]?|2[0-4][\d]|25[0-5])\)$/,fn=/^rgba\(((0|[1-9][\d]?|1[\d]{0,2}|2[\d]?|2[0-4][\d]|25[0-5]),){2}(0|[1-9][\d]?|1[\d]{0,2}|2[\d]?|2[0-4][\d]|25[0-5]),(0|0\.[0-9]+[1-9]|0\.[1-9]+|1)\)$/,ri={date:l=>/^-?[\d]+\/[0-1]\d\/[0-3]\d$/.test(l),time:l=>/^([0-1]?\d|2[0-3]):[0-5]\d$/.test(l),fulltime:l=>/^([0-1]?\d|2[0-3]):[0-5]\d:[0-5]\d$/.test(l),timeOrFulltime:l=>/^([0-1]?\d|2[0-3]):[0-5]\d(:[0-5]\d)?$/.test(l),email:l=>/^(([^<>()\[\]\\.,;:\s@"]+(\.[^<>()\[\]\\.,;:\s@"]+)*)|(".+"))@((\[[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}])|(([a-zA-Z\-0-9]+\.)+[a-zA-Z]{2,}))$/.test(l),hexColor:l=>Do.test(l),hexaColor:l=>Po.test(l),hexOrHexaColor:l=>No.test(l),rgbColor:l=>dn.test(l),rgbaColor:l=>fn.test(l),rgbOrRgbaColor:l=>dn.test(l)||fn.test(l),hexOrRgbColor:l=>Do.test(l)||dn.test(l),hexaOrRgbaColor:l=>Po.test(l)||fn.test(l),anyColor:l=>No.test(l)||dn.test(l)||fn.test(l)},Ql=[!0,!1,"ondemand"],Kl={modelValue:{},error:{type:Boolean,default:null},errorMessage:String,noErrorIcon:Boolean,rules:Array,reactiveRules:Boolean,lazyRules:{type:[Boolean,String],default:!1,validator:l=>Ql.includes(l)}};function Xl(l,B){const{props:t,proxy:b}=v.getCurrentInstance(),m=v.ref(!1),c=v.ref(null),i=v.ref(!1);Yl({validate:h,resetValidation:f});let s=0,n;const e=v.computed(()=>t.rules!==void 0&&t.rules!==null&&t.rules.length!==0),r=v.computed(()=>t.disable!==!0&&e.value===!0&&B.value===!1),u=v.computed(()=>t.error===!0||m.value===!0),a=v.computed(()=>typeof t.errorMessage=="string"&&t.errorMessage.length!==0?t.errorMessage:c.value);v.watch(()=>t.modelValue,()=>{i.value=!0,r.value===!0&&t.lazyRules===!1&&d()});function o(){t.lazyRules!=="ondemand"&&r.value===!0&&i.value===!0&&d()}v.watch(()=>t.reactiveRules,g=>{g===!0?n===void 0&&(n=v.watch(()=>t.rules,o,{immediate:!0,deep:!0})):n!==void 0&&(n(),n=void 0)},{immediate:!0}),v.watch(()=>t.lazyRules,o),v.watch(l,g=>{g===!0?i.value=!0:r.value===!0&&t.lazyRules!=="ondemand"&&d()});function f(){s++,B.value=!1,i.value=!1,m.value=!1,c.value=null,d.cancel()}function h(g=t.modelValue){if(t.disable===!0||e.value===!1)return!0;const p=++s,k=B.value!==!0?()=>{i.value=!0}:()=>{},C=(D,V)=>{D===!0&&k(),m.value=D,c.value=V||null,B.value=!1},T=[];for(let D=0;D<t.rules.length;D++){const V=t.rules[D];let P;if(typeof V=="function"?P=V(g,ri):typeof V=="string"&&ri[V]!==void 0&&(P=ri[V](g)),P===!1||typeof P=="string")return C(!0,P),!1;P!==!0&&P!==void 0&&T.push(P)}return T.length===0?(C(!1),!0):(B.value=!0,Promise.all(T).then(D=>{if(D===void 0||Array.isArray(D)===!1||D.length===0)return p===s&&C(!1),!0;const V=D.find(P=>P===!1||typeof P=="string");return p===s&&C(V!==void 0,V),V===void 0},D=>(p===s&&(console.error(D),C(!0)),!1)))}const d=Vi(h,0);return v.onBeforeUnmount(()=>{n?.(),d.cancel()}),Object.assign(b,{resetValidation:f,validate:h}),Lt(b,"hasError",()=>u.value),{isDirtyModel:i,hasRules:e,hasError:u,errorMessage:a,validate:h,resetValidation:f}}function Xr(l){return l!=null&&(""+l).length!==0}const Gl={...Ot,...Kl,label:String,stackLabel:Boolean,hint:String,hideHint:Boolean,prefix:String,suffix:String,labelColor:String,color:String,bgColor:String,filled:Boolean,outlined:Boolean,borderless:Boolean,standout:[Boolean,String],square:Boolean,loading:Boolean,labelSlot:Boolean,bottomSlots:Boolean,hideBottomSpace:Boolean,rounded:Boolean,dense:Boolean,itemAligned:Boolean,counter:Boolean,clearable:Boolean,clearIcon:String,disable:Boolean,readonly:Boolean,autofocus:Boolean,for:String},Un={...Gl,maxlength:[Number,String]},Gi=["update:modelValue","clear","focus","blur"];function Ji({requiredForAttr:l=!0,tagProp:B,changeEvent:t=!1}={}){const{props:b,proxy:m}=v.getCurrentInstance(),c=Ft(b,m.$q),i=Ul({required:l,getValue:()=>b.for});return{requiredForAttr:l,changeEvent:t,tag:B===!0?v.computed(()=>b.tag):{value:"label"},isDark:c,editable:v.computed(()=>b.disable!==!0&&b.readonly!==!0),innerLoading:v.ref(!1),focused:v.ref(!1),hasPopupOpen:!1,splitAttrs:Wl(),targetUid:i,rootRef:v.ref(null),targetRef:v.ref(null),controlRef:v.ref(null)}}function Zi(l){const{props:B,emit:t,slots:b,attrs:m,proxy:c}=v.getCurrentInstance(),{$q:i}=c;let s=null;l.hasValue===void 0&&(l.hasValue=v.computed(()=>Xr(B.modelValue))),l.emitValue===void 0&&(l.emitValue=w=>{t("update:modelValue",w)}),l.controlEvents===void 0&&(l.controlEvents={onFocusin:N,onFocusout:q}),Object.assign(l,{clearValue:W,onControlFocusin:N,onControlFocusout:q,focus:V}),l.computedCounter===void 0&&(l.computedCounter=v.computed(()=>{if(B.counter!==!1){const w=typeof B.modelValue=="string"||typeof B.modelValue=="number"?(""+B.modelValue).length:Array.isArray(B.modelValue)===!0?B.modelValue.length:0,S=B.maxlength!==void 0?B.maxlength:B.maxValues;return w+(S!==void 0?" / "+S:"")}}));const{isDirtyModel:n,hasRules:e,hasError:r,errorMessage:u,resetValidation:a}=Xl(l.focused,l.innerLoading),o=l.floatingLabel!==void 0?v.computed(()=>B.stackLabel===!0||l.focused.value===!0||l.floatingLabel.value===!0):v.computed(()=>B.stackLabel===!0||l.focused.value===!0||l.hasValue.value===!0),f=v.computed(()=>B.bottomSlots===!0||B.hint!==void 0||e.value===!0||B.counter===!0||B.error!==null),h=v.computed(()=>B.filled===!0?"filled":B.outlined===!0?"outlined":B.borderless===!0?"borderless":B.standout?"standout":"standard"),d=v.computed(()=>`q-field row no-wrap items-start q-field--${h.value}`+(l.fieldClass!==void 0?` ${l.fieldClass.value}`:"")+(B.rounded===!0?" q-field--rounded":"")+(B.square===!0?" q-field--square":"")+(o.value===!0?" q-field--float":"")+(p.value===!0?" q-field--labeled":"")+(B.dense===!0?" q-field--dense":"")+(B.itemAligned===!0?" q-field--item-aligned q-item-type":"")+(l.isDark.value===!0?" q-field--dark":"")+(l.getControl===void 0?" q-field--auto-height":"")+(l.focused.value===!0?" q-field--focused":"")+(r.value===!0?" q-field--error":"")+(r.value===!0||l.focused.value===!0?" q-field--highlighted":"")+(B.hideBottomSpace!==!0&&f.value===!0?" q-field--with-bottom":"")+(B.disable===!0?" q-field--disabled":B.readonly===!0?" q-field--readonly":"")),g=v.computed(()=>"q-field__control relative-position row no-wrap"+(B.bgColor!==void 0?` bg-${B.bgColor}`:"")+(r.value===!0?" text-negative":typeof B.standout=="string"&&B.standout.length!==0&&l.focused.value===!0?` ${B.standout}`:B.color!==void 0?` text-${B.color}`:"")),p=v.computed(()=>B.labelSlot===!0||B.label!==void 0),k=v.computed(()=>"q-field__label no-pointer-events absolute ellipsis"+(B.labelColor!==void 0&&r.value!==!0?` text-${B.labelColor}`:"")),C=v.computed(()=>({id:l.targetUid.value,editable:l.editable.value,focused:l.focused.value,floatingLabel:o.value,modelValue:B.modelValue,emitValue:l.emitValue})),T=v.computed(()=>{const w={};return l.targetUid.value&&(w.for=l.targetUid.value),B.disable===!0&&(w["aria-disabled"]="true"),w});function D(){const w=document.activeElement;let S=l.targetRef?.value;S&&(w===null||w.id!==l.targetUid.value)&&(S.hasAttribute("tabindex")===!0||(S=S.querySelector("[tabindex]")),S!==w&&S?.focus({preventScroll:!0}))}function V(){Jr(D)}function P(){Al(D);const w=document.activeElement;w!==null&&l.rootRef.value.contains(w)&&w.blur()}function N(w){s!==null&&(clearTimeout(s),s=null),l.editable.value===!0&&l.focused.value===!1&&(l.focused.value=!0,t("focus",w))}function q(w,S){s!==null&&clearTimeout(s),s=setTimeout(()=>{s=null,!(document.hasFocus()===!0&&(l.hasPopupOpen===!0||l.controlRef===void 0||l.controlRef.value===null||l.controlRef.value.contains(document.activeElement)!==!1))&&(l.focused.value===!0&&(l.focused.value=!1,t("blur",w)),S?.())})}function W(w){St(w),i.platform.is.mobile!==!0?(l.targetRef?.value||l.rootRef.value).focus():l.rootRef.value.contains(document.activeElement)===!0&&document.activeElement.blur(),B.type==="file"&&(l.inputRef.value.value=null),t("update:modelValue",null),l.changeEvent===!0&&t("change",null),t("clear",B.modelValue),v.nextTick(()=>{const S=n.value;a(),n.value=S})}function L(w){[13,32].includes(w.keyCode)&&W(w)}function A(){const w=[];return b.prepend!==void 0&&w.push(v.h("div",{class:"q-field__prepend q-field__marginal row no-wrap items-center",key:"prepend",onClick:Bt},b.prepend())),w.push(v.h("div",{class:"q-field__control-container col relative-position row no-wrap q-anchor--skip"},M())),r.value===!0&&B.noErrorIcon===!1&&w.push(y("error",[v.h(dt,{name:i.iconSet.field.error,color:"negative"})])),B.loading===!0||l.innerLoading.value===!0?w.push(y("inner-loading-append",b.loading!==void 0?b.loading():[v.h(ga,{color:B.color})])):B.clearable===!0&&l.hasValue.value===!0&&l.editable.value===!0&&w.push(y("inner-clearable-append",[v.h(dt,{class:"q-field__focusable-action",name:B.clearIcon||i.iconSet.field.clear,tabindex:0,role:"button","aria-hidden":"false","aria-label":i.lang.label.clear,onKeyup:L,onClick:W})])),b.append!==void 0&&w.push(v.h("div",{class:"q-field__append q-field__marginal row no-wrap items-center",key:"append",onClick:Bt},b.append())),l.getInnerAppend!==void 0&&w.push(y("inner-append",l.getInnerAppend())),l.getControlChild!==void 0&&w.push(l.getControlChild()),w}function M(){const w=[];return B.prefix!==void 0&&B.prefix!==null&&w.push(v.h("div",{class:"q-field__prefix no-pointer-events row items-center"},B.prefix)),l.getShadowControl!==void 0&&l.hasShadow.value===!0&&w.push(l.getShadowControl()),l.getControl!==void 0?w.push(l.getControl()):b.rawControl!==void 0?w.push(b.rawControl()):b.control!==void 0&&w.push(v.h("div",{ref:l.targetRef,class:"q-field__native row",tabindex:-1,...l.splitAttrs.attributes.value,"data-autofocus":B.autofocus===!0||void 0},b.control(C.value))),p.value===!0&&w.push(v.h("div",{class:k.value},bt(b.label,B.label))),B.suffix!==void 0&&B.suffix!==null&&w.push(v.h("div",{class:"q-field__suffix no-pointer-events row items-center"},B.suffix)),w.concat(bt(b.default))}function _(){let w,S;r.value===!0?u.value!==null?(w=[v.h("div",{role:"alert"},u.value)],S=`q--slot-error-${u.value}`):(w=bt(b.error),S="q--slot-error"):(B.hideHint!==!0||l.focused.value===!0)&&(B.hint!==void 0?(w=[v.h("div",B.hint)],S=`q--slot-hint-${B.hint}`):(w=bt(b.hint),S="q--slot-hint"));const E=B.counter===!0||b.counter!==void 0;if(B.hideBottomSpace===!0&&E===!1&&w===void 0)return;const O=v.h("div",{key:S,class:"q-field__messages col"},w);return v.h("div",{class:"q-field__bottom row items-start q-field__bottom--"+(B.hideBottomSpace!==!0?"animated":"stale"),onClick:Bt},[B.hideBottomSpace===!0?O:v.h(v.Transition,{name:"q-transition--field-message"},()=>O),E===!0?v.h("div",{class:"q-field__counter"},b.counter!==void 0?b.counter():l.computedCounter.value):null])}function y(w,S){return S===null?null:v.h("div",{key:w,class:"q-field__append q-field__marginal row no-wrap items-center q-anchor--skip"},S)}let x=!1;return v.onDeactivated(()=>{x=!0}),v.onActivated(()=>{x===!0&&B.autofocus===!0&&c.focus()}),B.autofocus===!0&&v.onMounted(()=>{c.focus()}),v.onBeforeUnmount(()=>{s!==null&&clearTimeout(s)}),Object.assign(c,{focus:V,blur:P}),function(){const S=l.getControl===void 0&&b.control===void 0?{...l.splitAttrs.attributes.value,"data-autofocus":B.autofocus===!0||void 0,...T.value}:T.value;return v.h(l.tag.value,{ref:l.rootRef,class:[d.value,m.class],style:m.style,...S},[b.before!==void 0?v.h("div",{class:"q-field__before q-field__marginal row no-wrap items-center",onClick:Bt},b.before()):null,v.h("div",{class:"q-field__inner relative-position col self-stretch"},[v.h("div",{ref:l.controlRef,class:g.value,tabindex:-1,...l.controlEvents},A()),f.value===!0?_():null]),b.after!==void 0?v.h("div",{class:"q-field__after q-field__marginal row no-wrap items-center",onClick:Bt},b.after()):null])}}const Jl=$e({name:"QField",inheritAttrs:!1,props:{...Un,tag:{type:String,default:"label"}},emits:Gi,setup(){return Zi(Ji({tagProp:!0}))}}),Zl={xs:8,sm:10,md:14,lg:20,xl:24},za=$e({name:"QChip",props:{...Ot,...Fr,dense:Boolean,icon:String,iconRight:String,iconRemove:String,iconSelected:String,label:[String,Number],color:String,textColor:String,modelValue:{type:Boolean,default:!0},selected:{type:Boolean,default:null},square:Boolean,outline:Boolean,clickable:Boolean,removable:Boolean,removeAriaLabel:String,tabindex:[String,Number],disable:Boolean,ripple:{type:[Boolean,Object],default:!0}},emits:["update:modelValue","update:selected","remove","click"],setup(l,{slots:B,emit:t}){const{proxy:{$q:b}}=v.getCurrentInstance(),m=Ft(l,b),c=jr(l,Zl),i=v.computed(()=>l.selected===!0||l.icon!==void 0),s=v.computed(()=>l.selected===!0?l.iconSelected||b.iconSet.chip.selected:l.icon),n=v.computed(()=>l.iconRemove||b.iconSet.chip.remove),e=v.computed(()=>l.disable===!1&&(l.clickable===!0||l.selected!==null)),r=v.computed(()=>{const d=l.outline===!0&&l.color||l.textColor;return"q-chip row inline no-wrap items-center"+(l.outline===!1&&l.color!==void 0?` bg-${l.color}`:"")+(d?` text-${d} q-chip--colored`:"")+(l.disable===!0?" disabled":"")+(l.dense===!0?" q-chip--dense":"")+(l.outline===!0?" q-chip--outline":"")+(l.selected===!0?" q-chip--selected":"")+(e.value===!0?" q-chip--clickable cursor-pointer non-selectable q-hoverable":"")+(l.square===!0?" q-chip--square":"")+(m.value===!0?" q-chip--dark q-dark":"")}),u=v.computed(()=>{const d=l.disable===!0?{tabindex:-1,"aria-disabled":"true"}:{tabindex:l.tabindex||0},g={...d,role:"button","aria-hidden":"false","aria-label":l.removeAriaLabel||b.lang.label.remove};return{chip:d,remove:g}});function a(d){d.keyCode===13&&o(d)}function o(d){l.disable||(t("update:selected",!l.selected),t("click",d))}function f(d){(d.keyCode===void 0||d.keyCode===13)&&(St(d),l.disable===!1&&(t("update:modelValue",!1),t("remove")))}function h(){const d=[];e.value===!0&&d.push(v.h("div",{class:"q-focus-helper"})),i.value===!0&&d.push(v.h(dt,{class:"q-chip__icon q-chip__icon--left",name:s.value}));const g=l.label!==void 0?[v.h("div",{class:"ellipsis"},[l.label])]:void 0;return d.push(v.h("div",{class:"q-chip__content col row no-wrap items-center q-anchor--skip"},la(B.default,g))),l.iconRight&&d.push(v.h(dt,{class:"q-chip__icon q-chip__icon--right",name:l.iconRight})),l.removable===!0&&d.push(v.h(dt,{class:"q-chip__icon q-chip__icon--remove cursor-pointer",name:n.value,...u.value.remove,onClick:f,onKeyup:f})),d}return()=>{if(l.modelValue===!1)return;const d={class:r.value,style:c.value};return e.value===!0&&Object.assign(d,u.value.chip,{onClick:o,onKeyup:a}),Es("div",d,h(),"ripple",l.ripple!==!1&&l.disable!==!0,()=>[[va,l.ripple]])}}}),hr=$e({name:"QItem",props:{...Ot,...pa,tag:{type:String,default:"div"},active:{type:Boolean,default:null},clickable:Boolean,dense:Boolean,insetLevel:Number,tabindex:[String,Number],focused:Boolean,manualFocus:Boolean},emits:["click","keyup"],setup(l,{slots:B,emit:t}){const{proxy:{$q:b}}=v.getCurrentInstance(),m=Ft(l,b),{hasLink:c,linkAttrs:i,linkClass:s,linkTag:n,navigateOnClick:e}=Oi(),r=v.ref(null),u=v.ref(null),a=v.computed(()=>l.clickable===!0||c.value===!0||l.tag==="label"),o=v.computed(()=>l.disable!==!0&&a.value===!0),f=v.computed(()=>"q-item q-item-type row no-wrap"+(l.dense===!0?" q-item--dense":"")+(m.value===!0?" q-item--dark":"")+(c.value===!0&&l.active===null?s.value:l.active===!0?` q-item--active${l.activeClass!==void 0?` ${l.activeClass}`:""}`:"")+(l.disable===!0?" disabled":"")+(o.value===!0?" q-item--clickable q-link cursor-pointer "+(l.manualFocus===!0?"q-manual-focusable":"q-focusable q-hoverable")+(l.focused===!0?" q-manual-focusable--focused":""):"")),h=v.computed(()=>l.insetLevel===void 0?null:{["padding"+(b.lang.rtl===!0?"Right":"Left")]:16+l.insetLevel*56+"px"});function d(k){o.value===!0&&(u.value!==null&&k.qAvoidFocus!==!0&&(k.qKeyEvent!==!0&&document.activeElement===r.value?u.value.focus():document.activeElement===u.value&&r.value.focus()),e(k))}function g(k){if(o.value===!0&&or(k,[13,32])===!0){St(k),k.qKeyEvent=!0;const C=new MouseEvent("click",k);C.qKeyEvent=!0,r.value.dispatchEvent(C)}t("keyup",k)}function p(){const k=Ri(B.default,[]);return o.value===!0&&k.unshift(v.h("div",{class:"q-focus-helper",tabindex:-1,ref:u})),k}return()=>{const k={ref:r,class:f.value,style:h.value,role:"listitem",onClick:d,onKeyup:g};return o.value===!0?(k.tabindex=l.tabindex||"0",Object.assign(k,i.value)):a.value===!0&&(k["aria-disabled"]="true"),v.h(n.value,k,p())}}}),nr=$e({name:"QItemSection",props:{avatar:Boolean,thumbnail:Boolean,side:Boolean,top:Boolean,noWrap:Boolean},setup(l,{slots:B}){const t=v.computed(()=>`q-item__section column q-item__section--${l.avatar===!0||l.side===!0||l.thumbnail===!0?"side":"main"}`+(l.top===!0?" q-item__section--top justify-start":" justify-center")+(l.avatar===!0?" q-item__section--avatar":"")+(l.thumbnail===!0?" q-item__section--thumbnail":"")+(l.noWrap===!0?" q-item__section--nowrap":""));return()=>v.h("div",{class:t.value},bt(B.default))}}),ki=$e({name:"QItemLabel",props:{overline:Boolean,caption:Boolean,header:Boolean,lines:[Number,String]},setup(l,{slots:B}){const t=v.computed(()=>parseInt(l.lines,10)),b=v.computed(()=>"q-item__label"+(l.overline===!0?" q-item__label--overline text-overline":"")+(l.caption===!0?" q-item__label--caption text-caption":"")+(l.header===!0?" q-item__label--header":"")+(t.value===1?" ellipsis":"")),m=v.computed(()=>l.lines!==void 0&&t.value>1?{overflow:"hidden",display:"-webkit-box","-webkit-box-orient":"vertical","-webkit-line-clamp":t.value}:null);return()=>v.h("div",{style:m.value,class:b.value},bt(B.default))}});function $l(l,B,t){function b(){}return v.onBeforeUnmount(()=>{l.value===!0&&void 0}),{removeFromHistory:b,addToHistory(){}}}let Lr=0,ni,ii,zr,oi=!1,Lo,Vo,qo,cr=null;function eu(l){tu(l)&&St(l)}function tu(l){if(l.target===document.body||l.target.classList.contains("q-layout__backdrop"))return!0;const B=Ks(l),t=l.shiftKey&&!l.deltaX,b=!t&&Math.abs(l.deltaX)<=Math.abs(l.deltaY),m=t||b?l.deltaY:l.deltaX;for(let c=0;c<B.length;c++){const i=B[c];if(vl(i,b))return b?m<0&&i.scrollTop===0?!0:m>0&&i.scrollTop+i.clientHeight===i.scrollHeight:m<0&&i.scrollLeft===0?!0:m>0&&i.scrollLeft+i.clientWidth===i.scrollWidth}return!0}function zo(l){l.target===document&&(document.scrollingElement.scrollTop=document.scrollingElement.scrollTop)}function hn(l){oi!==!0&&(oi=!0,requestAnimationFrame(()=>{oi=!1;const{height:B}=l.target,{clientHeight:t,scrollTop:b}=document.scrollingElement;(zr===void 0||B!==window.innerHeight)&&(zr=t-B,document.scrollingElement.scrollTop=b),b>zr&&(document.scrollingElement.scrollTop-=Math.ceil((b-zr)/8))}))}function Uo(l){const B=document.body,t=window.visualViewport!==void 0;if(l==="add"){const{overflowY:b,overflowX:m}=window.getComputedStyle(B);ni=Ni(window),ii=Pi(window),Lo=B.style.left,Vo=B.style.top,qo=window.location.href,B.style.left=`-${ni}px`,B.style.top=`-${ii}px`,m!=="hidden"&&(m==="scroll"||B.scrollWidth>window.innerWidth)&&B.classList.add("q-body--force-scrollbar-x"),b!=="hidden"&&(b==="scroll"||B.scrollHeight>window.innerHeight)&&B.classList.add("q-body--force-scrollbar-y"),B.classList.add("q-body--prevent-scroll"),document.qScrollPrevented=!0,Et.is.ios===!0&&(t===!0?(window.scrollTo(0,0),window.visualViewport.addEventListener("resize",hn,_t.passiveCapture),window.visualViewport.addEventListener("scroll",hn,_t.passiveCapture),window.scrollTo(0,0)):window.addEventListener("scroll",zo,_t.passiveCapture))}Et.is.desktop===!0&&Et.is.mac===!0&&window[`${l}EventListener`]("wheel",eu,_t.notPassive),l==="remove"&&(Et.is.ios===!0&&(t===!0?(window.visualViewport.removeEventListener("resize",hn,_t.passiveCapture),window.visualViewport.removeEventListener("scroll",hn,_t.passiveCapture)):window.removeEventListener("scroll",zo,_t.passiveCapture)),B.classList.remove("q-body--prevent-scroll"),B.classList.remove("q-body--force-scrollbar-x"),B.classList.remove("q-body--force-scrollbar-y"),document.qScrollPrevented=!1,B.style.left=Lo,B.style.top=Vo,window.location.href===qo&&window.scrollTo(ni,ii),zr=void 0)}function ru(l){let B="add";if(l===!0){if(Lr++,cr!==null){clearTimeout(cr),cr=null;return}if(Lr>1)return}else{if(Lr===0||(Lr--,Lr>0))return;if(B="remove",Et.is.ios===!0&&Et.is.nativeMobile===!0){cr!==null&&clearTimeout(cr),cr=setTimeout(()=>{Uo(B),cr=null},100);return}}Uo(B)}function nu(){let l;return{preventBodyScroll(B){B!==l&&(l!==void 0||B===!0)&&(l=B,ru(B))}}}let pn=0;const iu={standard:"fixed-full flex-center",top:"fixed-top justify-center",bottom:"fixed-bottom justify-center",right:"fixed-right items-center",left:"fixed-left items-center"},Wo={standard:["scale","scale"],top:["slide-down","slide-up"],bottom:["slide-up","slide-down"],right:["slide-left","slide-right"],left:["slide-right","slide-left"]},en=$e({name:"QDialog",inheritAttrs:!1,props:{...zi,...Yr,transitionShow:String,transitionHide:String,persistent:Boolean,autoClose:Boolean,allowFocusOutside:Boolean,noEscDismiss:Boolean,noBackdropDismiss:Boolean,noRouteDismiss:Boolean,noRefocus:Boolean,noFocus:Boolean,noShake:Boolean,seamless:Boolean,maximized:Boolean,fullWidth:Boolean,fullHeight:Boolean,square:Boolean,backdropFilter:String,position:{type:String,default:"standard",validator:l=>["standard","top","bottom","left","right"].includes(l)}},emits:[...Ui,"shake","click","escapeKey"],setup(l,{slots:B,emit:t,attrs:b}){const m=v.getCurrentInstance(),c=v.ref(null),i=v.ref(!1),s=v.ref(!1);let n=null,e=null,r,u;const a=v.computed(()=>l.persistent!==!0&&l.noRouteDismiss!==!0&&l.seamless!==!0),{preventBodyScroll:o}=nu(),{registerTimeout:f}=Ki(),{registerTick:h,removeTick:d}=Qi(),{transitionProps:g,transitionStyle:p}=Yi(l,()=>Wo[l.position][0],()=>Wo[l.position][1]),k=v.computed(()=>p.value+(l.backdropFilter!==void 0?`;backdrop-filter:${l.backdropFilter};-webkit-backdrop-filter:${l.backdropFilter}`:"")),{showPortal:C,hidePortal:T,portalIsAccessible:D,renderPortal:V}=Hi(m,c,z,"dialog"),{hide:P}=Wi({showing:i,hideOnRouteChange:a,handleShow:A,handleHide:M,processOnMount:!0});$l(i);const N=v.computed(()=>`q-dialog__inner flex no-pointer-events q-dialog__inner--${l.maximized===!0?"maximized":"minimized"} q-dialog__inner--${l.position} ${iu[l.position]}`+(s.value===!0?" q-dialog__inner--animating":"")+(l.fullWidth===!0?" q-dialog__inner--fullwidth":"")+(l.fullHeight===!0?" q-dialog__inner--fullheight":"")+(l.square===!0?" q-dialog__inner--square":"")),q=v.computed(()=>i.value===!0&&l.seamless!==!0),W=v.computed(()=>l.autoClose===!0?{onClick:E}:{}),L=v.computed(()=>[`q-dialog fullscreen no-pointer-events q-dialog--${q.value===!0?"modal":"seamless"}`,b.class]);v.watch(()=>l.maximized,U=>{i.value===!0&&S(U)}),v.watch(q,U=>{o(U),U===!0?(Pa(R),ja(x)):(wi(R),En(x))});function A(U){e=l.noRefocus===!1&&document.activeElement!==null?document.activeElement:null,S(l.maximized),C(),s.value=!0,l.noFocus!==!0?(document.activeElement?.blur(),h(_)):d(),f(()=>{if(m.proxy.$q.platform.is.ios===!0){if(l.seamless!==!0&&document.activeElement){const{top:Q,bottom:j}=document.activeElement.getBoundingClientRect(),{innerHeight:Y}=window,F=window.visualViewport!==void 0?window.visualViewport.height:Y;Q>0&&j>F/2&&(document.scrollingElement.scrollTop=Math.min(document.scrollingElement.scrollHeight-F,j>=Y?1/0:Math.ceil(document.scrollingElement.scrollTop+j-F/2))),document.activeElement.scrollIntoView()}u=!0,c.value.click(),u=!1}C(!0),s.value=!1,t("show",U)},l.transitionDuration)}function M(U){d(),w(!0),s.value=!0,T(),e!==null&&(((U?.type.indexOf("key")===0?e.closest('[tabindex]:not([tabindex^="-"])'):void 0)||e).focus(),e=null),f(()=>{T(!0),s.value=!1,t("hide",U)},l.transitionDuration)}function _(U){Jr(()=>{let Q=c.value;if(Q!==null){if(U!==void 0){const j=Q.querySelector(U);if(j!==null){j.focus({preventScroll:!0});return}}Q.contains(document.activeElement)!==!0&&(Q=Q.querySelector("[autofocus][tabindex], [data-autofocus][tabindex]")||Q.querySelector("[autofocus] [tabindex], [data-autofocus] [tabindex]")||Q.querySelector("[autofocus], [data-autofocus]")||Q,Q.focus({preventScroll:!0}))}})}function y(U){U&&typeof U.focus=="function"?U.focus({preventScroll:!0}):_(),t("shake");const Q=c.value;Q!==null&&(Q.classList.remove("q-animate--scale"),Q.classList.add("q-animate--scale"),n!==null&&clearTimeout(n),n=setTimeout(()=>{n=null,c.value!==null&&(Q.classList.remove("q-animate--scale"),_())},170))}function x(){l.seamless!==!0&&(l.persistent===!0||l.noEscDismiss===!0?l.maximized!==!0&&l.noShake!==!0&&y():(t("escapeKey"),P()))}function w(U){n!==null&&(clearTimeout(n),n=null),(U===!0||i.value===!0)&&(S(!1),l.seamless!==!0&&(o(!1),wi(R),En(x))),U!==!0&&(e=null)}function S(U){U===!0?r!==!0&&(pn<1&&document.body.classList.add("q-body--dialog"),pn++,r=!0):r===!0&&(pn<2&&document.body.classList.remove("q-body--dialog"),pn--,r=!1)}function E(U){u!==!0&&(P(U),t("click",U))}function O(U){l.persistent!==!0&&l.noBackdropDismiss!==!0?P(U):l.noShake!==!0&&y()}function R(U){l.allowFocusOutside!==!0&&D.value===!0&&ba(c.value,U.target)!==!0&&_('[tabindex]:not([tabindex="-1"])')}Object.assign(m.proxy,{focus:_,shake:y,__updateRefocusTarget(U){e=U||null}}),v.onBeforeUnmount(w);function z(){return v.h("div",{role:"dialog","aria-modal":q.value===!0?"true":"false",...b,class:L.value},[v.h(v.Transition,{name:"q-transition--fade",appear:!0},()=>q.value===!0?v.h("div",{class:"q-dialog__backdrop fixed-full",style:k.value,"aria-hidden":"true",tabindex:-1,onClick:O}):null),v.h(v.Transition,g.value,()=>i.value===!0?v.h("div",{ref:c,class:N.value,style:p.value,tabindex:-1,...W.value},bt(B.default)):null)])}return V}});let On=!1;{const l=document.createElement("div");l.setAttribute("dir","rtl"),Object.assign(l.style,{width:"1px",height:"1px",overflow:"auto"});const B=document.createElement("div");Object.assign(B.style,{width:"1000px",height:"1px"}),document.body.appendChild(l),l.appendChild(B),l.scrollLeft=-1e3,On=l.scrollLeft>=0,l.remove()}const Wt=1e3,ou=["start","center","end","start-force","center-force","end-force"],Ua=Array.prototype.filter,au=window.getComputedStyle(document.body).overflowAnchor===void 0?Ln:function(l,B){l!==null&&(l._qOverflowAnimationFrame!==void 0&&cancelAnimationFrame(l._qOverflowAnimationFrame),l._qOverflowAnimationFrame=requestAnimationFrame(()=>{if(l===null)return;l._qOverflowAnimationFrame=void 0;const t=l.children||[];Ua.call(t,m=>m.dataset&&m.dataset.qVsAnchor!==void 0).forEach(m=>{delete m.dataset.qVsAnchor});const b=t[B];b?.dataset&&(b.dataset.qVsAnchor="")}))};function Rr(l,B){return l+B}function ai(l,B,t,b,m,c,i,s){const n=l===window?document.scrollingElement||document.documentElement:l,e=m===!0?"offsetWidth":"offsetHeight",r={scrollStart:0,scrollViewSize:-i-s,scrollMaxSize:0,offsetStart:-i,offsetEnd:-s};if(m===!0?(l===window?(r.scrollStart=window.pageXOffset||window.scrollX||document.body.scrollLeft||0,r.scrollViewSize+=document.documentElement.clientWidth):(r.scrollStart=n.scrollLeft,r.scrollViewSize+=n.clientWidth),r.scrollMaxSize=n.scrollWidth,c===!0&&(r.scrollStart=(On===!0?r.scrollMaxSize-r.scrollViewSize:0)-r.scrollStart)):(l===window?(r.scrollStart=window.pageYOffset||window.scrollY||document.body.scrollTop||0,r.scrollViewSize+=document.documentElement.clientHeight):(r.scrollStart=n.scrollTop,r.scrollViewSize+=n.clientHeight),r.scrollMaxSize=n.scrollHeight),t!==null)for(let u=t.previousElementSibling;u!==null;u=u.previousElementSibling)u.classList.contains("q-virtual-scroll--skip")===!1&&(r.offsetStart+=u[e]);if(b!==null)for(let u=b.nextElementSibling;u!==null;u=u.nextElementSibling)u.classList.contains("q-virtual-scroll--skip")===!1&&(r.offsetEnd+=u[e]);if(B!==l){const u=n.getBoundingClientRect(),a=B.getBoundingClientRect();m===!0?(r.offsetStart+=a.left-u.left,r.offsetEnd-=a.width):(r.offsetStart+=a.top-u.top,r.offsetEnd-=a.height),l!==window&&(r.offsetStart+=r.scrollStart),r.offsetEnd+=r.scrollMaxSize-r.offsetStart}return r}function Ho(l,B,t,b){B==="end"&&(B=(l===window?document.body:l)[t===!0?"scrollWidth":"scrollHeight"]),l===window?t===!0?(b===!0&&(B=(On===!0?document.body.scrollWidth-document.documentElement.clientWidth:0)-B),window.scrollTo(B,window.pageYOffset||window.scrollY||document.body.scrollTop||0)):window.scrollTo(window.pageXOffset||window.scrollX||document.body.scrollLeft||0,B):t===!0?(b===!0&&(B=(On===!0?l.scrollWidth-l.offsetWidth:0)-B),l.scrollLeft=B):l.scrollTop=B}function Vr(l,B,t,b){if(t>=b)return 0;const m=B.length,c=Math.floor(t/Wt),i=Math.floor((b-1)/Wt)+1;let s=l.slice(c,i).reduce(Rr,0);return t%Wt!==0&&(s-=B.slice(c*Wt,t).reduce(Rr,0)),b%Wt!==0&&b!==m&&(s-=B.slice(b,i*Wt).reduce(Rr,0)),s}const Wa={virtualScrollSliceSize:{type:[Number,String],default:10},virtualScrollSliceRatioBefore:{type:[Number,String],default:1},virtualScrollSliceRatioAfter:{type:[Number,String],default:1},virtualScrollItemSize:{type:[Number,String],default:24},virtualScrollStickySizeStart:{type:[Number,String],default:0},virtualScrollStickySizeEnd:{type:[Number,String],default:0},tableColspan:[Number,String]},Ha=Object.keys(Wa),_i={virtualScrollHorizontal:Boolean,onVirtualScroll:Function,...Wa};function Ya({virtualScrollLength:l,getVirtualScrollTarget:B,getVirtualScrollEl:t,virtualScrollItemSizeComputed:b}){const m=v.getCurrentInstance(),{props:c,emit:i,proxy:s}=m,{$q:n}=s;let e,r,u,a=[],o;const f=v.ref(0),h=v.ref(0),d=v.ref({}),g=v.ref(null),p=v.ref(null),k=v.ref(null),C=v.ref({from:0,to:0}),T=v.computed(()=>c.tableColspan!==void 0?c.tableColspan:100);b===void 0&&(b=v.computed(()=>c.virtualScrollItemSize));const D=v.computed(()=>b.value+";"+c.virtualScrollHorizontal),V=v.computed(()=>D.value+";"+c.virtualScrollSliceRatioBefore+";"+c.virtualScrollSliceRatioAfter);v.watch(V,()=>{y()}),v.watch(D,P);function P(){_(r,!0)}function N(O){_(O===void 0?r:O)}function q(O,R){const z=B();if(z==null||z.nodeType===8)return;const U=ai(z,t(),g.value,p.value,c.virtualScrollHorizontal,n.lang.rtl,c.virtualScrollStickySizeStart,c.virtualScrollStickySizeEnd);u!==U.scrollViewSize&&y(U.scrollViewSize),L(z,U,Math.min(l.value-1,Math.max(0,parseInt(O,10)||0)),0,ou.indexOf(R)!==-1?R:r!==-1&&O>r?"end":"start")}function W(){const O=B();if(O==null||O.nodeType===8)return;const R=ai(O,t(),g.value,p.value,c.virtualScrollHorizontal,n.lang.rtl,c.virtualScrollStickySizeStart,c.virtualScrollStickySizeEnd),z=l.value-1,U=R.scrollMaxSize-R.offsetStart-R.offsetEnd-h.value;if(e===R.scrollStart)return;if(R.scrollMaxSize<=0){L(O,R,0,0);return}u!==R.scrollViewSize&&y(R.scrollViewSize),A(C.value.from);const Q=Math.floor(R.scrollMaxSize-Math.max(R.scrollViewSize,R.offsetEnd)-Math.min(o[z],R.scrollViewSize/2));if(Q>0&&Math.ceil(R.scrollStart)>=Q){L(O,R,z,R.scrollMaxSize-R.offsetEnd-a.reduce(Rr,0));return}let j=0,Y=R.scrollStart-R.offsetStart,F=Y;if(Y<=U&&Y+R.scrollViewSize>=f.value)Y-=f.value,j=C.value.from,F=Y;else for(let I=0;Y>=a[I]&&j<z;I++)Y-=a[I],j+=Wt;for(;Y>0&&j<z;)Y-=o[j],Y>-R.scrollViewSize?(j++,F=Y):F=o[j]+Y;L(O,R,j,F)}function L(O,R,z,U,Q){const j=typeof Q=="string"&&Q.indexOf("-force")!==-1,Y=j===!0?Q.replace("-force",""):Q,F=Y!==void 0?Y:"start";let I=Math.max(0,z-d.value[F]),H=I+d.value.total;H>l.value&&(H=l.value,I=Math.max(0,H-d.value.total)),e=R.scrollStart;const K=I!==C.value.from||H!==C.value.to;if(K===!1&&Y===void 0){w(z);return}const{activeElement:ee}=document,G=k.value;K===!0&&G!==null&&G!==ee&&G.contains(ee)===!0&&(G.addEventListener("focusout",M),setTimeout(()=>{G?.removeEventListener("focusout",M)})),au(G,z-I);const te=Y!==void 0?o.slice(I,z).reduce(Rr,0):0;if(K===!0){const ce=H>=C.value.from&&I<=C.value.to?C.value.to:H;C.value={from:I,to:ce},f.value=Vr(a,o,0,I),h.value=Vr(a,o,H,l.value),requestAnimationFrame(()=>{C.value.to!==H&&e===R.scrollStart&&(C.value={from:C.value.from,to:H},h.value=Vr(a,o,H,l.value))})}requestAnimationFrame(()=>{if(e!==R.scrollStart)return;K===!0&&A(I);const ce=o.slice(I,z).reduce(Rr,0),ue=ce+R.offsetStart+f.value,J=ue+o[z];let ae=ue+U;if(Y!==void 0){const se=ce-te,pe=R.scrollStart+se;ae=j!==!0&&pe<ue&&J<pe+R.scrollViewSize?pe:Y==="end"?J-R.scrollViewSize:ue-(Y==="start"?0:Math.round((R.scrollViewSize-o[z])/2))}e=ae,Ho(O,ae,c.virtualScrollHorizontal,n.lang.rtl),w(z)})}function A(O){const R=k.value;if(R){const z=Ua.call(R.children,I=>I.classList&&I.classList.contains("q-virtual-scroll--skip")===!1),U=z.length,Q=c.virtualScrollHorizontal===!0?I=>I.getBoundingClientRect().width:I=>I.offsetHeight;let j=O,Y,F;for(let I=0;I<U;){for(Y=Q(z[I]),I++;I<U&&z[I].classList.contains("q-virtual-scroll--with-prev")===!0;)Y+=Q(z[I]),I++;F=Y-o[j],F!==0&&(o[j]+=F,a[Math.floor(j/Wt)]+=F),j++}}}function M(){k.value?.focus()}function _(O,R){const z=1*b.value;(R===!0||Array.isArray(o)===!1)&&(o=[]);const U=o.length;o.length=l.value;for(let j=l.value-1;j>=U;j--)o[j]=z;const Q=Math.floor((l.value-1)/Wt);a=[];for(let j=0;j<=Q;j++){let Y=0;const F=Math.min((j+1)*Wt,l.value);for(let I=j*Wt;I<F;I++)Y+=o[I];a.push(Y)}r=-1,e=void 0,f.value=Vr(a,o,0,C.value.from),h.value=Vr(a,o,C.value.to,l.value),O>=0?(A(C.value.from),v.nextTick(()=>{q(O)})):S()}function y(O){if(O===void 0&&typeof window<"u"){const Y=B();Y!=null&&Y.nodeType!==8&&(O=ai(Y,t(),g.value,p.value,c.virtualScrollHorizontal,n.lang.rtl,c.virtualScrollStickySizeStart,c.virtualScrollStickySizeEnd).scrollViewSize)}u=O;const R=parseFloat(c.virtualScrollSliceRatioBefore)||0,z=parseFloat(c.virtualScrollSliceRatioAfter)||0,U=1+R+z,Q=O===void 0||O<=0?1:Math.ceil(O/b.value),j=Math.max(1,Q,Math.ceil((c.virtualScrollSliceSize>0?c.virtualScrollSliceSize:10)/U));d.value={total:Math.ceil(j*U),start:Math.ceil(j*R),center:Math.ceil(j*(.5+R)),end:Math.ceil(j*(1+R)),view:Q}}function x(O,R){const z=c.virtualScrollHorizontal===!0?"width":"height",U={["--q-virtual-scroll-item-"+z]:b.value+"px"};return[O==="tbody"?v.h(O,{class:"q-virtual-scroll__padding",key:"before",ref:g},[v.h("tr",[v.h("td",{style:{[z]:`${f.value}px`,...U},colspan:T.value})])]):v.h(O,{class:"q-virtual-scroll__padding",key:"before",ref:g,style:{[z]:`${f.value}px`,...U}}),v.h(O,{class:"q-virtual-scroll__content",key:"content",ref:k,tabindex:-1},R.flat()),O==="tbody"?v.h(O,{class:"q-virtual-scroll__padding",key:"after",ref:p},[v.h("tr",[v.h("td",{style:{[z]:`${h.value}px`,...U},colspan:T.value})])]):v.h(O,{class:"q-virtual-scroll__padding",key:"after",ref:p,style:{[z]:`${h.value}px`,...U}})]}function w(O){r!==O&&(c.onVirtualScroll!==void 0&&i("virtualScroll",{index:O,from:C.value.from,to:C.value.to-1,direction:O<r?"decrease":"increase",ref:s}),r=O)}y();const S=Vi(W,n.platform.is.ios===!0?120:35);v.onBeforeMount(()=>{y()});let E=!1;return v.onDeactivated(()=>{E=!0}),v.onActivated(()=>{if(E!==!0)return;const O=B();e!==void 0&&O!==void 0&&O!==null&&O.nodeType!==8?Ho(O,e,c.virtualScrollHorizontal,n.lang.rtl):q(r)}),v.onBeforeUnmount(()=>{S.cancel()}),Object.assign(s,{scrollTo:q,reset:P,refresh:N}),{virtualScrollSliceRange:C,virtualScrollSliceSizeComputed:d,setVirtualScrollSize:y,onVirtualScrollEvt:S,localResetVirtualScroll:_,padVirtualScroll:x,scrollTo:q,reset:P,refresh:N}}const su=/[\u3000-\u303f\u3040-\u309f\u30a0-\u30ff\uff00-\uff9f\u4e00-\u9faf\u3400-\u4dbf]/,lu=/[\u4e00-\u9fff\u3400-\u4dbf\u{20000}-\u{2a6df}\u{2a700}-\u{2b73f}\u{2b740}-\u{2b81f}\u{2b820}-\u{2ceaf}\uf900-\ufaff\u3300-\u33ff\ufe30-\ufe4f\uf900-\ufaff\u{2f800}-\u{2fa1f}]/u,uu=/[\u3131-\u314e\u314f-\u3163\uac00-\ud7a3]/,cu=/[a-z0-9_ -]$/i;function Qa(l){return function(t){if(t.type==="compositionend"||t.type==="change"){if(t.target.qComposing!==!0)return;t.target.qComposing=!1,l(t)}else t.type==="compositionupdate"&&t.target.qComposing!==!0&&typeof t.data=="string"&&(Et.is.firefox===!0?cu.test(t.data)===!1:su.test(t.data)===!0||lu.test(t.data)===!0||uu.test(t.data)===!0)===!0&&(t.target.qComposing=!0)}}function rr(l,B){if(l===B)return!0;if(l!==null&&B!==null&&typeof l=="object"&&typeof B=="object"){if(l.constructor!==B.constructor)return!1;let t,b;if(l.constructor===Array){if(t=l.length,t!==B.length)return!1;for(b=t;b--!==0;)if(rr(l[b],B[b])!==!0)return!1;return!0}if(l.constructor===Map){if(l.size!==B.size)return!1;let c=l.entries();for(b=c.next();b.done!==!0;){if(B.has(b.value[0])!==!0)return!1;b=c.next()}for(c=l.entries(),b=c.next();b.done!==!0;){if(rr(b.value[1],B.get(b.value[0]))!==!0)return!1;b=c.next()}return!0}if(l.constructor===Set){if(l.size!==B.size)return!1;const c=l.entries();for(b=c.next();b.done!==!0;){if(B.has(b.value[0])!==!0)return!1;b=c.next()}return!0}if(l.buffer!=null&&l.buffer.constructor===ArrayBuffer){if(t=l.length,t!==B.length)return!1;for(b=t;b--!==0;)if(l[b]!==B[b])return!1;return!0}if(l.constructor===RegExp)return l.source===B.source&&l.flags===B.flags;if(l.valueOf!==Object.prototype.valueOf)return l.valueOf()===B.valueOf();if(l.toString!==Object.prototype.toString)return l.toString()===B.toString();const m=Object.keys(l).filter(c=>l[c]!==void 0);if(t=m.length,t!==Object.keys(B).filter(c=>B[c]!==void 0).length)return!1;for(b=t;b--!==0;){const c=m[b];if(rr(l[c],B[c])!==!0)return!1}return!0}return l!==l&&B!==B}function Ka(l){return l!==null&&typeof l=="object"&&Array.isArray(l)!==!0}function Fn(l){return Object.prototype.toString.call(l)==="[object Date]"}function Ci(l){return typeof l=="number"&&isFinite(l)}const Yo=l=>["add","add-unique","toggle"].includes(l),du=".*+?^${}()|[]\\",fu=Object.keys(Un);function si(l,B){if(typeof l=="function")return l;const t=l!==void 0?l:B;return b=>b!==null&&typeof b=="object"&&t in b?b[t]:b}const Wn=$e({name:"QSelect",inheritAttrs:!1,props:{..._i,...Vn,...Un,modelValue:{required:!0},multiple:Boolean,displayValue:[String,Number],displayValueHtml:Boolean,dropdownIcon:String,options:{type:Array,default:()=>[]},optionValue:[Function,String],optionLabel:[Function,String],optionDisable:[Function,String],hideSelected:Boolean,hideDropdownIcon:Boolean,fillInput:Boolean,maxValues:[Number,String],optionsDense:Boolean,optionsDark:{type:Boolean,default:null},optionsSelectedClass:String,optionsHtml:Boolean,optionsCover:Boolean,menuShrink:Boolean,menuAnchor:String,menuSelf:String,menuOffset:Array,popupContentClass:String,popupContentStyle:[String,Array,Object],popupNoRouteDismiss:Boolean,useInput:Boolean,useChips:Boolean,newValueMode:{type:String,validator:Yo},mapOptions:Boolean,emitValue:Boolean,disableTabSelection:Boolean,inputDebounce:{type:[Number,String],default:500},inputClass:[Array,String,Object],inputStyle:[Array,String,Object],tabindex:{type:[String,Number],default:0},autocomplete:String,transitionShow:{},transitionHide:{},transitionDuration:{},behavior:{type:String,validator:l=>["default","menu","dialog"].includes(l),default:"default"},virtualScrollItemSize:_i.virtualScrollItemSize.type,onNewValue:Function,onFilter:Function},emits:[...Gi,"add","remove","inputValue","keyup","keypress","keydown","popupShow","popupHide","filterAbort"],setup(l,{slots:B,emit:t}){const{proxy:b}=v.getCurrentInstance(),{$q:m}=b,c=v.ref(!1),i=v.ref(!1),s=v.ref(-1),n=v.ref(""),e=v.ref(!1),r=v.ref(!1);let u=null,a=null,o,f,h,d=null,g,p,k,C;const T=v.ref(null),D=v.ref(null),V=v.ref(null),P=v.ref(null),N=v.ref(null),q=wa(l),W=Qa(me),L=v.computed(()=>Array.isArray(l.options)?l.options.length:0),A=v.computed(()=>l.virtualScrollItemSize===void 0?l.optionsDense===!0?24:48:l.virtualScrollItemSize),{virtualScrollSliceRange:M,virtualScrollSliceSizeComputed:_,localResetVirtualScroll:y,padVirtualScroll:x,onVirtualScrollEvt:w,scrollTo:S,setVirtualScrollSize:E}=Ya({virtualScrollLength:L,getVirtualScrollTarget:nt,getVirtualScrollEl:He,virtualScrollItemSizeComputed:A}),O=Ji(),R=v.computed(()=>{const de=l.mapOptions===!0&&l.multiple!==!0,je=l.modelValue!==void 0&&(l.modelValue!==null||de===!0)?l.multiple===!0&&Array.isArray(l.modelValue)?l.modelValue:[l.modelValue]:[];if(l.mapOptions===!0&&Array.isArray(l.options)===!0){const Z=l.mapOptions===!0&&o!==void 0?o:[],he=je.map(ye=>Fe(ye,Z));return l.modelValue===null&&de===!0?he.filter(ye=>ye!==null):he}return je}),z=v.computed(()=>{const de={};return fu.forEach(je=>{const Z=l[je];Z!==void 0&&(de[je]=Z)}),de}),U=v.computed(()=>l.optionsDark===null?O.isDark.value:l.optionsDark),Q=v.computed(()=>Xr(R.value)),j=v.computed(()=>{let de="q-field__input q-placeholder col";return l.hideSelected===!0||R.value.length===0?[de,l.inputClass]:(de+=" q-field__input--padding",l.inputClass===void 0?de:[de,l.inputClass])}),Y=v.computed(()=>(l.virtualScrollHorizontal===!0?"q-virtual-scroll--horizontal":"")+(l.popupContentClass?" "+l.popupContentClass:"")),F=v.computed(()=>L.value===0),I=v.computed(()=>R.value.map(de=>ie.value(de)).join(", ")),H=v.computed(()=>l.displayValue!==void 0?l.displayValue:I.value),K=v.computed(()=>l.optionsHtml===!0?()=>!0:de=>de?.html===!0),ee=v.computed(()=>l.displayValueHtml===!0||l.displayValue===void 0&&(l.optionsHtml===!0||R.value.some(K.value))),G=v.computed(()=>O.focused.value===!0?l.tabindex:-1),te=v.computed(()=>{const de={tabindex:l.tabindex,role:"combobox","aria-label":l.label,"aria-readonly":l.readonly===!0?"true":"false","aria-autocomplete":l.useInput===!0?"list":"none","aria-expanded":c.value===!0?"true":"false","aria-controls":`${O.targetUid.value}_lb`};return s.value>=0&&(de["aria-activedescendant"]=`${O.targetUid.value}_${s.value}`),de}),ce=v.computed(()=>({id:`${O.targetUid.value}_lb`,role:"listbox","aria-multiselectable":l.multiple===!0?"true":"false"})),ue=v.computed(()=>R.value.map((de,je)=>({index:je,opt:de,html:K.value(de),selected:!0,removeAtIndex:Te,toggleOption:Ne,tabindex:G.value}))),J=v.computed(()=>{if(L.value===0)return[];const{from:de,to:je}=M.value;return l.options.slice(de,je).map((Z,he)=>{const ye=oe.value(Z)===!0,we=ke(Z)===!0,Pe=de+he,Se={clickable:!0,active:we,activeClass:pe.value,manualFocus:!0,focused:!1,disable:ye,tabindex:-1,dense:l.optionsDense,dark:U.value,role:"option","aria-selected":we===!0?"true":"false",id:`${O.targetUid.value}_${Pe}`,onClick:()=>{Ne(Z)}};return ye!==!0&&(s.value===Pe&&(Se.focused=!0),m.platform.is.desktop===!0&&(Se.onMousemove=()=>{c.value===!0&&Le(Pe)})),{index:Pe,opt:Z,html:K.value(Z),label:ie.value(Z),selected:Se.active,focused:Se.focused,toggleOption:Ne,setOptionIndex:Le,itemProps:Se}})}),ae=v.computed(()=>l.dropdownIcon!==void 0?l.dropdownIcon:m.iconSet.arrow.dropdown),se=v.computed(()=>l.optionsCover===!1&&l.outlined!==!0&&l.standout!==!0&&l.borderless!==!0&&l.rounded!==!0),pe=v.computed(()=>l.optionsSelectedClass!==void 0?l.optionsSelectedClass:l.color!==void 0?`text-${l.color}`:""),$=v.computed(()=>si(l.optionValue,"value")),ie=v.computed(()=>si(l.optionLabel,"label")),oe=v.computed(()=>si(l.optionDisable,"disable")),le=v.computed(()=>R.value.map($.value)),ge=v.computed(()=>{const de={onInput:me,onChange:W,onKeydown:et,onKeyup:Ve,onKeypress:Ge,onFocus:De,onClick(je){f===!0&&Dt(je)}};return de.onCompositionstart=de.onCompositionupdate=de.onCompositionend=W,de});v.watch(R,de=>{o=de,l.useInput===!0&&l.fillInput===!0&&l.multiple!==!0&&O.innerLoading.value!==!0&&(i.value!==!0&&c.value!==!0||Q.value!==!0)&&(h!==!0&&ze(),(i.value===!0||c.value===!0)&&Oe(""))},{immediate:!0}),v.watch(()=>l.fillInput,ze),v.watch(c,Je),v.watch(L,Ze);function Ce(de){return l.emitValue===!0?$.value(de):de}function Ae(de){if(de!==-1&&de<R.value.length)if(l.multiple===!0){const je=l.modelValue.slice();t("remove",{index:de,value:je.splice(de,1)[0]}),t("update:modelValue",je)}else t("update:modelValue",null)}function Te(de){Ae(de),O.focus()}function Ue(de,je){const Z=Ce(de);if(l.multiple!==!0){l.fillInput===!0&&Re(ie.value(de),!0,!0),t("update:modelValue",Z);return}if(R.value.length===0){t("add",{index:0,value:Z}),t("update:modelValue",l.multiple===!0?[Z]:Z);return}if(je===!0&&ke(de)===!0||l.maxValues!==void 0&&l.modelValue.length>=l.maxValues)return;const he=l.modelValue.slice();t("add",{index:he.length,value:Z}),he.push(Z),t("update:modelValue",he)}function Ne(de,je){if(O.editable.value!==!0||de===void 0||oe.value(de)===!0)return;const Z=$.value(de);if(l.multiple!==!0){je!==!0&&(Re(l.fillInput===!0?ie.value(de):"",!0,!0),Be()),D.value?.focus(),(R.value.length===0||rr($.value(R.value[0]),Z)!==!0)&&t("update:modelValue",l.emitValue===!0?Z:de);return}if((f!==!0||e.value===!0)&&O.focus(),De(),R.value.length===0){const we=l.emitValue===!0?Z:de;t("add",{index:0,value:we}),t("update:modelValue",l.multiple===!0?[we]:we);return}const he=l.modelValue.slice(),ye=le.value.findIndex(we=>rr(we,Z));if(ye!==-1)t("remove",{index:ye,value:he.splice(ye,1)[0]});else{if(l.maxValues!==void 0&&he.length>=l.maxValues)return;const we=l.emitValue===!0?Z:de;t("add",{index:he.length,value:we}),he.push(we)}t("update:modelValue",he)}function Le(de){if(m.platform.is.desktop!==!0)return;const je=de!==-1&&de<L.value?de:-1;s.value!==je&&(s.value=je)}function qe(de=1,je){if(c.value===!0){let Z=s.value;do Z=_o(Z+de,-1,L.value-1);while(Z!==-1&&Z!==s.value&&oe.value(l.options[Z])===!0);s.value!==Z&&(Le(Z),S(Z),je!==!0&&l.useInput===!0&&l.fillInput===!0&&xe(Z>=0?ie.value(l.options[Z]):g,!0))}}function Fe(de,je){const Z=he=>rr($.value(he),de);return l.options.find(Z)||je.find(Z)||de}function ke(de){const je=$.value(de);return le.value.find(Z=>rr(Z,je))!==void 0}function De(de){l.useInput===!0&&D.value!==null&&(de===void 0||D.value===de.target&&de.target.value===I.value)&&D.value.select()}function We(de){or(de,27)===!0&&c.value===!0&&(Dt(de),Be(),ze()),t("keyup",de)}function Ve(de){const{value:je}=de.target;if(de.keyCode!==void 0){We(de);return}if(de.target.value="",u!==null&&(clearTimeout(u),u=null),a!==null&&(clearTimeout(a),a=null),ze(),typeof je=="string"&&je.length!==0){const Z=je.toLocaleLowerCase(),he=we=>{const Pe=l.options.find(Se=>String(we.value(Se)).toLocaleLowerCase()===Z);return Pe===void 0?!1:(R.value.indexOf(Pe)===-1?Ne(Pe):Be(),!0)},ye=we=>{he($)!==!0&&we!==!0&&he(ie)!==!0&&Oe(je,!0,()=>ye(!0))};ye()}else O.clearValue(de)}function Ge(de){t("keypress",de)}function et(de){if(t("keydown",de),Di(de)===!0)return;const je=n.value.length!==0&&(l.newValueMode!==void 0||l.onNewValue!==void 0),Z=de.shiftKey!==!0&&l.disableTabSelection!==!0&&l.multiple!==!0&&(s.value!==-1||je===!0);if(de.keyCode===27){Bt(de);return}if(de.keyCode===9&&Z===!1){ve();return}if(de.target===void 0||de.target.id!==O.targetUid.value||O.editable.value!==!0)return;if(de.keyCode===40&&O.innerLoading.value!==!0&&c.value===!1){St(de),_e();return}if(de.keyCode===8&&(l.useChips===!0||l.clearable===!0)&&l.hideSelected!==!0&&n.value.length===0){l.multiple===!0&&Array.isArray(l.modelValue)===!0?Ae(l.modelValue.length-1):l.multiple!==!0&&l.modelValue!==null&&t("update:modelValue",null);return}(de.keyCode===35||de.keyCode===36)&&(typeof n.value!="string"||n.value.length===0)&&(St(de),s.value=-1,qe(de.keyCode===36?1:-1,l.multiple)),(de.keyCode===33||de.keyCode===34)&&_.value!==void 0&&(St(de),s.value=Math.max(-1,Math.min(L.value,s.value+(de.keyCode===33?-1:1)*_.value.view)),qe(de.keyCode===33?1:-1,l.multiple)),(de.keyCode===38||de.keyCode===40)&&(St(de),qe(de.keyCode===38?-1:1,l.multiple));const he=L.value;if((k===void 0||C<Date.now())&&(k=""),he>0&&l.useInput!==!0&&de.key!==void 0&&de.key.length===1&&de.altKey===!1&&de.ctrlKey===!1&&de.metaKey===!1&&(de.keyCode!==32||k.length!==0)){c.value!==!0&&_e(de);const ye=de.key.toLocaleLowerCase(),we=k.length===1&&k[0]===ye;C=Date.now()+1500,we===!1&&(St(de),k+=ye);const Pe=new RegExp("^"+k.split("").map(Ie=>du.indexOf(Ie)!==-1?"\\"+Ie:Ie).join(".*"),"i");let Se=s.value;if(we===!0||Se<0||Pe.test(ie.value(l.options[Se]))!==!0)do Se=_o(Se+1,-1,he-1);while(Se!==s.value&&(oe.value(l.options[Se])===!0||Pe.test(ie.value(l.options[Se]))!==!0));s.value!==Se&&v.nextTick(()=>{Le(Se),S(Se),Se>=0&&l.useInput===!0&&l.fillInput===!0&&xe(ie.value(l.options[Se]),!0)});return}if(!(de.keyCode!==13&&(de.keyCode!==32||l.useInput===!0||k!=="")&&(de.keyCode!==9||Z===!1))){if(de.keyCode!==9&&St(de),s.value!==-1&&s.value<he){Ne(l.options[s.value]);return}if(je===!0){const ye=(we,Pe)=>{if(Pe){if(Yo(Pe)!==!0)return}else Pe=l.newValueMode;if(Re("",l.multiple!==!0,!0),we==null)return;(Pe==="toggle"?Ne:Ue)(we,Pe==="add-unique"),l.multiple!==!0&&(D.value?.focus(),Be())};if(l.onNewValue!==void 0?t("newValue",n.value,ye):ye(n.value),l.multiple!==!0)return}c.value===!0?ve():O.innerLoading.value!==!0&&_e()}}function He(){return f===!0?N.value:V.value!==null&&V.value.contentEl!==null?V.value.contentEl:void 0}function nt(){return He()}function tt(){return l.hideSelected===!0?[]:B["selected-item"]!==void 0?ue.value.map(de=>B["selected-item"](de)).slice():B.selected!==void 0?[].concat(B.selected()):l.useChips===!0?ue.value.map((de,je)=>v.h(za,{key:"option-"+je,removable:O.editable.value===!0&&oe.value(de.opt)!==!0,dense:!0,textColor:l.color,tabindex:G.value,onRemove(){de.removeAtIndex(je)}},()=>v.h("span",{class:"ellipsis",[de.html===!0?"innerHTML":"textContent"]:ie.value(de.opt)}))):[v.h("span",{class:"ellipsis",[ee.value===!0?"innerHTML":"textContent"]:H.value})]}function Ye(){if(F.value===!0)return B["no-option"]!==void 0?B["no-option"]({inputValue:n.value}):void 0;const de=B.option!==void 0?B.option:Z=>v.h(hr,{key:Z.index,...Z.itemProps},()=>v.h(nr,()=>v.h(ki,()=>v.h("span",{[Z.html===!0?"innerHTML":"textContent"]:Z.label}))));let je=x("div",J.value.map(de));return B["before-options"]!==void 0&&(je=B["before-options"]().concat(je)),It(B["after-options"],je)}function st(de,je){const Z=je===!0?{...te.value,...O.splitAttrs.attributes.value}:void 0,he={ref:je===!0?D:void 0,key:"i_t",class:j.value,style:l.inputStyle,value:n.value!==void 0?n.value:"",type:"search",...Z,id:je===!0?O.targetUid.value:void 0,maxlength:l.maxlength,autocomplete:l.autocomplete,"data-autofocus":de===!0||l.autofocus===!0||void 0,disabled:l.disable===!0,readonly:l.readonly===!0,...ge.value};return de!==!0&&f===!0&&(Array.isArray(he.class)===!0?he.class=[...he.class,"no-pointer-events"]:he.class+=" no-pointer-events"),v.h("input",he)}function me(de){u!==null&&(clearTimeout(u),u=null),a!==null&&(clearTimeout(a),a=null),!(de&&de.target&&de.target.qComposing===!0)&&(xe(de.target.value||""),h=!0,g=n.value,O.focused.value!==!0&&(f!==!0||e.value===!0)&&O.focus(),l.onFilter!==void 0&&(u=setTimeout(()=>{u=null,Oe(n.value)},l.inputDebounce)))}function xe(de,je){n.value!==de&&(n.value=de,je===!0||l.inputDebounce===0||l.inputDebounce==="0"?t("inputValue",de):a=setTimeout(()=>{a=null,t("inputValue",de)},l.inputDebounce))}function Re(de,je,Z){h=Z!==!0,l.useInput===!0&&(xe(de,!0),(je===!0||Z!==!0)&&(g=de),je!==!0&&Oe(de))}function Oe(de,je,Z){if(l.onFilter===void 0||je!==!0&&O.focused.value!==!0)return;O.innerLoading.value===!0?t("filterAbort"):(O.innerLoading.value=!0,r.value=!0),de!==""&&l.multiple!==!0&&R.value.length!==0&&h!==!0&&de===ie.value(R.value[0])&&(de="");const he=setTimeout(()=>{c.value===!0&&(c.value=!1)},10);d!==null&&clearTimeout(d),d=he,t("filter",de,(ye,we)=>{(je===!0||O.focused.value===!0)&&d===he&&(clearTimeout(d),typeof ye=="function"&&ye(),r.value=!1,v.nextTick(()=>{O.innerLoading.value=!1,O.editable.value===!0&&(je===!0?c.value===!0&&Be():c.value===!0?Je(!0):c.value=!0),typeof we=="function"&&v.nextTick(()=>{we(b)}),typeof Z=="function"&&v.nextTick(()=>{Z(b)})}))},()=>{O.focused.value===!0&&d===he&&(clearTimeout(d),O.innerLoading.value=!1,r.value=!1),c.value===!0&&(c.value=!1)})}function Ee(){return v.h(Zr,{ref:V,class:Y.value,style:l.popupContentStyle,modelValue:c.value,fit:l.menuShrink!==!0,cover:l.optionsCover===!0&&F.value!==!0&&l.useInput!==!0,anchor:l.menuAnchor,self:l.menuSelf,offset:l.menuOffset,dark:U.value,noParentEvent:!0,noRefocus:!0,noFocus:!0,noRouteDismiss:l.popupNoRouteDismiss,square:se.value,transitionShow:l.transitionShow,transitionHide:l.transitionHide,transitionDuration:l.transitionDuration,separateClosePopup:!0,...ce.value,onScrollPassive:w,onBeforeShow:yt,onBeforeHide:Qe,onShow:Ke},Ye)}function Qe(de){ft(de),ve()}function Ke(){E()}function re(de){Dt(de),D.value?.focus(),e.value=!0,window.scrollTo(window.pageXOffset||window.scrollX||document.body.scrollLeft||0,0)}function X(de){Dt(de),v.nextTick(()=>{e.value=!1})}function ne(){const de=[v.h(Jl,{class:`col-auto ${O.fieldClass.value}`,...z.value,for:O.targetUid.value,dark:U.value,square:!0,loading:r.value,itemAligned:!1,filled:!0,stackLabel:n.value.length!==0,...O.splitAttrs.listeners.value,onFocus:re,onBlur:X},{...B,rawControl:()=>O.getControl(!0),before:void 0,after:void 0})];return c.value===!0&&de.push(v.h("div",{ref:N,class:Y.value+" scroll",style:l.popupContentStyle,...ce.value,onClick:Bt,onScrollPassive:w},Ye())),v.h(en,{ref:P,modelValue:i.value,position:l.useInput===!0?"top":void 0,transitionShow:p,transitionHide:l.transitionHide,transitionDuration:l.transitionDuration,noRouteDismiss:l.popupNoRouteDismiss,onBeforeShow:yt,onBeforeHide:fe,onHide:be,onShow:Me},()=>v.h("div",{class:"q-select__dialog"+(U.value===!0?" q-select__dialog--dark q-dark":"")+(e.value===!0?" q-select__dialog--focused":"")},de))}function fe(de){ft(de),P.value!==null&&P.value.__updateRefocusTarget(O.rootRef.value.querySelector(".q-field__native > [tabindex]:last-child")),O.focused.value=!1}function be(de){Be(),O.focused.value===!1&&t("blur",de),ze()}function Me(){const de=document.activeElement;(de===null||de.id!==O.targetUid.value)&&D.value!==null&&D.value!==de&&D.value.focus(),E()}function ve(){i.value!==!0&&(s.value=-1,c.value===!0&&(c.value=!1),O.focused.value===!1&&(d!==null&&(clearTimeout(d),d=null),O.innerLoading.value===!0&&(t("filterAbort"),O.innerLoading.value=!1,r.value=!1)))}function _e(de){O.editable.value===!0&&(f===!0?(O.onControlFocusin(de),i.value=!0,v.nextTick(()=>{O.focus()})):O.focus(),l.onFilter!==void 0?Oe(n.value):(F.value!==!0||B["no-option"]!==void 0)&&(c.value=!0))}function Be(){i.value=!1,ve()}function ze(){l.useInput===!0&&Re(l.multiple!==!0&&l.fillInput===!0&&R.value.length!==0&&ie.value(R.value[0])||"",!0,!0)}function Je(de){let je=-1;if(de===!0){if(R.value.length!==0){const Z=$.value(R.value[0]);je=l.options.findIndex(he=>rr($.value(he),Z))}y(je)}Le(je)}function Ze(de,je){c.value===!0&&O.innerLoading.value===!1&&(y(-1,!0),v.nextTick(()=>{c.value===!0&&O.innerLoading.value===!1&&(de>je?y():Je(!0))}))}function rt(){i.value===!1&&V.value!==null&&V.value.updatePosition()}function yt(de){de!==void 0&&Dt(de),t("popupShow",de),O.hasPopupOpen=!0,O.onControlFocusin(de)}function ft(de){de!==void 0&&Dt(de),t("popupHide",de),O.hasPopupOpen=!1,O.onControlFocusout(de)}function kt(){f=m.platform.is.mobile!==!0&&l.behavior!=="dialog"?!1:l.behavior!=="menu"&&(l.useInput===!0?B["no-option"]!==void 0||l.onFilter!==void 0||F.value===!1:!0),p=m.platform.is.ios===!0&&f===!0&&l.useInput===!0?"fade":l.transitionShow}return v.onBeforeUpdate(kt),v.onUpdated(rt),kt(),v.onBeforeUnmount(()=>{u!==null&&clearTimeout(u),a!==null&&clearTimeout(a)}),Object.assign(b,{showPopup:_e,hidePopup:Be,removeAtIndex:Ae,add:Ue,toggleOption:Ne,getOptionIndex:()=>s.value,setOptionIndex:Le,moveOptionSelection:qe,filter:Oe,updateMenuPosition:rt,updateInputValue:Re,isOptionSelected:ke,getEmittingOptionValue:Ce,isOptionDisabled:(...de)=>oe.value.apply(null,de)===!0,getOptionValue:(...de)=>$.value.apply(null,de),getOptionLabel:(...de)=>ie.value.apply(null,de)}),Object.assign(O,{innerValue:R,fieldClass:v.computed(()=>`q-select q-field--auto-height q-select--with${l.useInput!==!0?"out":""}-input q-select--with${l.useChips!==!0?"out":""}-chips q-select--${l.multiple===!0?"multiple":"single"}`),inputRef:T,targetRef:D,hasValue:Q,showPopup:_e,floatingLabel:v.computed(()=>l.hideSelected!==!0&&Q.value===!0||typeof n.value=="number"||n.value.length!==0||Xr(l.displayValue)),getControlChild:()=>{if(O.editable.value!==!1&&(i.value===!0||F.value!==!0||B["no-option"]!==void 0))return f===!0?ne():Ee();O.hasPopupOpen===!0&&(O.hasPopupOpen=!1)},controlEvents:{onFocusin(de){O.onControlFocusin(de)},onFocusout(de){O.onControlFocusout(de,()=>{ze(),ve()})},onClick(de){if(Bt(de),f!==!0&&c.value===!0){ve(),D.value?.focus();return}_e(de)}},getControl:de=>{const je=tt(),Z=de===!0||i.value!==!0||f!==!0;if(l.useInput===!0)je.push(st(de,Z));else if(O.editable.value===!0){const ye=Z===!0?te.value:void 0;je.push(v.h("input",{ref:Z===!0?D:void 0,key:"d_t",class:"q-select__focus-target",id:Z===!0?O.targetUid.value:void 0,value:H.value,readonly:!0,"data-autofocus":de===!0||l.autofocus===!0||void 0,...ye,onKeydown:et,onKeyup:We,onKeypress:Ge})),Z===!0&&typeof l.autocomplete=="string"&&l.autocomplete.length!==0&&je.push(v.h("input",{class:"q-select__autocomplete-input",autocomplete:l.autocomplete,tabindex:-1,onKeyup:Ve}))}if(q.value!==void 0&&l.disable!==!0&&le.value.length!==0){const ye=le.value.map(we=>v.h("option",{value:we,selected:!0}));je.push(v.h("select",{class:"hidden",name:q.value,multiple:l.multiple},ye))}const he=l.useInput===!0||Z!==!0?void 0:O.splitAttrs.attributes.value;return v.h("div",{class:"q-field__native row items-center",...he,...O.splitAttrs.listeners.value},je)},getInnerAppend:()=>l.loading!==!0&&r.value!==!0&&l.hideDropdownIcon!==!0?[v.h(dt,{class:"q-select__dropdown-icon"+(c.value===!0?" rotate-180":""),name:ae.value})]:null}),Zi(O)}}),hu={class:"q-pa-none"},pu=v.defineComponent({__name:"CheckboxFilter",props:{options:{},label:{default:"Sélectionner les options"},modelValue:{default:()=>[]},scrollAreaHeight:{default:"200px"},scrollAreaWidth:{default:"250px"},dataCy:{default:"checkbox-filter"}},emits:["update:modelValue"],setup(l,{emit:B}){const t=l,b=B,m=v.ref(!1),c=v.ref(t.modelValue||[]),i=v.computed(()=>({height:t.scrollAreaHeight,width:t.scrollAreaWidth})),s=v.computed(()=>t.dataCy||"checkbox-filter");return v.watch(c,n=>{b("update:modelValue",n)}),v.watch(()=>t.modelValue,n=>{n&&(c.value=n)},{immediate:!0}),(n,e)=>(v.openBlock(),v.createElementBlock("div",hu,[v.createVNode(Wn,v.mergeProps({outlined:"",dense:"",label:t.label,class:["full-width","cursor-pointer"],"data-cy":s.value,"model-value":null,options:[],"hide-dropdown-icon":""},n.$attrs),{append:v.withCtx(()=>[v.createVNode(dt,{name:"arrow_drop_down",class:v.normalizeClass(["cursor-pointer smooth-rotate",{"rotate-180":m.value}])},null,8,["class"])]),default:v.withCtx(()=>[v.createVNode(Zr,{modelValue:m.value,"onUpdate:modelValue":e[1]||(e[1]=r=>m.value=r),anchor:"bottom left",self:"top left",offset:[0,8],"transition-show":"scale","transition-hide":"scale"},{default:v.withCtx(()=>[v.createVNode(Dr,{class:"q-pa-sm"},{default:v.withCtx(()=>[v.createVNode(_l,{style:v.normalizeStyle(i.value)},{default:v.withCtx(()=>[(v.openBlock(!0),v.createElementBlock(v.Fragment,null,v.renderList(t.options,r=>(v.openBlock(),v.createBlock(Mr,{key:r.value,modelValue:c.value,"onUpdate:modelValue":e[0]||(e[0]=u=>c.value=u),val:r,disable:r.disabled,color:"primary",class:"q-mb-sm q-ml-sm q-mr-sm","data-cy":`${s.value}-option-${r.label}`},{default:v.withCtx(()=>[v.createElementVNode("span",{class:v.normalizeClass({"text-italic":r.italic})},v.toDisplayString(r.label),3)]),_:2},1032,["modelValue","val","disable","data-cy"]))),128))]),_:1},8,["style"])]),_:1})]),_:1},8,["modelValue"])]),_:1},16,["label","data-cy"])]))}}),mu=Vt(pu,[["__scopeId","data-v-b83ebff3"]]),gu=v.defineComponent({__name:"SelectSearch",props:{options:{default:()=>[]},fetchOptions:{},label:{default:"Selectionner un option"},modelValue:{default:null},rules:{},updateInputOnModelChange:{type:Boolean,default:!1}},emits:["update:modelValue"],setup(l,{emit:B}){const t=l,b=B,m=v.ref(),c=v.ref(t.modelValue??null),i=v.ref(""),s=v.ref(t.options??[]),n=v.ref(!1),e=v.ref(!0),r=v.ref(!1);v.watch(()=>t.options,g=>{s.value=g??[],u()},{immediate:!0}),v.watch(()=>t.modelValue,async g=>{if(t.updateInputOnModelChange){if(r.value=!0,t.fetchOptions&&g){const p=await t.fetchOptions("");s.value=p}c.value=g,u(),n.value=!1,await v.nextTick(),m.value?.updateInputValue(i.value,!0),setTimeout(()=>{r.value=!1},100)}else c.value=g});function u(){const g=s.value.find(p=>p.value===c.value);i.value=g?.label??""}function a(g){r.value||(c.value=g,b("update:modelValue",g),u(),n.value=!1)}function o(g){i.value=g,g===""&&(n.value=!0)}function f(){if(e.value){e.value=!1;return}c.value!==null&&!n.value?(i.value="",n.value=!0,m.value?.showPopup()):n.value&&(i.value="")}function h(){e.value=!0;const g=i.value.trim();if(g==="")n.value&&(c.value=null,b("update:modelValue",null));else{const p=s.value.find(k=>k.label.toLowerCase()===g.toLowerCase());p?(c.value=p.value,b("update:modelValue",p.value),i.value=p.label):u()}n.value=!1}function d(g,p,k){if(t.fetchOptions)t.fetchOptions(g).then(C=>{s.value=C,p(()=>{})}).catch(k).finally(()=>{});else{const C=t.options??[];s.value=C.filter(T=>T.label.toLowerCase().includes(g.toLowerCase())),p(()=>{})}}return v.onMounted(async()=>{if(t.fetchOptions&&t.modelValue){const g=await t.fetchOptions("");s.value=g,u()}}),(g,p)=>(v.openBlock(),v.createBlock(Wn,v.mergeProps({ref_key:"selectRef",ref:m,"model-value":c.value,"input-value":i.value,"use-input":"","fill-input":"","hide-selected":"","input-debounce":"300",label:g.label,options:s.value,"map-options":"",dense:"",outlined:"",class:"full-width cursor-pointer"},g.$attrs,{"onUpdate:modelValue":a,"onUpdate:inputValue":o,onFocus:f,onBlur:h,onFilter:d}),null,16,["model-value","input-value","label","options"]))}}),bu=v.defineComponent({__name:"SelectYear",props:{modelValue:{},label:{default:"Sélectionner une année"},startYear:{default:2015},endYear:{default:void 0}},emits:["update:modelValue"],setup(l,{emit:B}){const t=l,b=B,m=v.computed(()=>{const s=t.startYear??new Date().getFullYear()-5,n=t.endYear??new Date().getFullYear(),e=[];for(let r=n;r>=s;r--)e.push({label:String(r),value:r});return e});function c(s){b("update:modelValue",s)}function i(){t.modelValue!==null&&b("update:modelValue",null)}return(s,n)=>(v.openBlock(),v.createBlock(Wn,v.mergeProps({"model-value":s.modelValue,options:m.value,"option-value":"value","option-label":"label",label:s.label,dense:"","emit-value":"",outlined:"",class:"full-width cursor-pointer"},s.$attrs,{"onUpdate:modelValue":c,onFocus:i}),null,16,["model-value","options","label"]))}}),Xa=$e({name:"QAvatar",props:{...Fr,fontSize:String,color:String,textColor:String,icon:String,square:Boolean,rounded:Boolean},setup(l,{slots:B}){const t=jr(l),b=v.computed(()=>"q-avatar"+(l.color?` bg-${l.color}`:"")+(l.textColor?` text-${l.textColor} q-chip--colored`:"")+(l.square===!0?" q-avatar--square":l.rounded===!0?" rounded-borders":"")),m=v.computed(()=>l.fontSize?{fontSize:l.fontSize}:null);return()=>{const c=l.icon!==void 0?[v.h(dt,{name:l.icon})]:void 0;return v.h("div",{class:b.value,style:t.value},[v.h("div",{class:"q-avatar__content row flex-center overflow-hidden",style:m.value},la(B.default,c))])}}}),vu=$e({name:"QSpace",setup(){const l=v.h("div",{class:"q-space"});return()=>l}}),yu=["ul","ol"],Hn=$e({name:"QList",props:{...Ot,bordered:Boolean,dense:Boolean,separator:Boolean,padding:Boolean,tag:{type:String,default:"div"}},setup(l,{slots:B}){const t=v.getCurrentInstance(),b=Ft(l,t.proxy.$q),m=v.computed(()=>yu.includes(l.tag)?null:"list"),c=v.computed(()=>"q-list"+(l.bordered===!0?" q-list--bordered":"")+(l.dense===!0?" q-list--dense":"")+(l.separator===!0?" q-list--separator":"")+(b.value===!0?" q-list--dark":"")+(l.padding===!0?" q-list--padding":""));return()=>v.h(l.tag,{class:c.value,role:m.value},bt(B.default))}}),Ga=$e({name:"QToolbar",props:{inset:Boolean},setup(l,{slots:B}){const t=v.computed(()=>"q-toolbar row no-wrap items-center"+(l.inset===!0?" q-toolbar--inset":""));return()=>v.h("div",{class:t.value,role:"toolbar"},bt(B.default))}}),wu=$e({name:"QHeader",props:{modelValue:{type:Boolean,default:!0},reveal:Boolean,revealOffset:{type:Number,default:250},bordered:Boolean,elevated:Boolean,heightHint:{type:[String,Number],default:50}},emits:["reveal","focusin"],setup(l,{slots:B,emit:t}){const{proxy:{$q:b}}=v.getCurrentInstance(),m=v.inject($r,Rt);if(m===Rt)return console.error("QHeader needs to be child of QLayout"),Rt;const c=v.ref(parseInt(l.heightHint,10)),i=v.ref(!0),s=v.computed(()=>l.reveal===!0||m.view.value.indexOf("H")!==-1||b.platform.is.ios&&m.isContainer.value===!0),n=v.computed(()=>{if(l.modelValue!==!0)return 0;if(s.value===!0)return i.value===!0?c.value:0;const p=c.value-m.scroll.value.position;return p>0?p:0}),e=v.computed(()=>l.modelValue!==!0||s.value===!0&&i.value!==!0),r=v.computed(()=>l.modelValue===!0&&e.value===!0&&l.reveal===!0),u=v.computed(()=>"q-header q-layout__section--marginal "+(s.value===!0?"fixed":"absolute")+"-top"+(l.bordered===!0?" q-header--bordered":"")+(e.value===!0?" q-header--hidden":"")+(l.modelValue!==!0?" q-layout--prevent-focus":"")),a=v.computed(()=>{const p=m.rows.value.top,k={};return p[0]==="l"&&m.left.space===!0&&(k[b.lang.rtl===!0?"right":"left"]=`${m.left.size}px`),p[2]==="r"&&m.right.space===!0&&(k[b.lang.rtl===!0?"left":"right"]=`${m.right.size}px`),k});function o(p,k){m.update("header",p,k)}function f(p,k){p.value!==k&&(p.value=k)}function h({height:p}){f(c,p),o("size",p)}function d(p){r.value===!0&&f(i,!0),t("focusin",p)}v.watch(()=>l.modelValue,p=>{o("space",p),f(i,!0),m.animate()}),v.watch(n,p=>{o("offset",p)}),v.watch(()=>l.reveal,p=>{p===!1&&f(i,l.modelValue)}),v.watch(i,p=>{m.animate(),t("reveal",p)}),v.watch(m.scroll,p=>{l.reveal===!0&&f(i,p.direction==="up"||p.position<=l.revealOffset||p.position-p.inflectionPoint<100)});const g={};return m.instances.header=g,l.modelValue===!0&&o("size",c.value),o("space",l.modelValue),o("offset",n.value),v.onBeforeUnmount(()=>{m.instances.header===g&&(m.instances.header=void 0,o("size",0),o("offset",0),o("space",!1))}),()=>{const p=Ri(B.default,[]);return l.elevated===!0&&p.push(v.h("div",{class:"q-layout__shadow absolute-full overflow-hidden no-pointer-events"})),p.push(v.h(Ir,{debounce:0,onResize:h})),v.h("header",{class:u.value,style:a.value,onFocusin:d},p)}}});function Qo(l){if(l===!1)return 0;if(l===!0||l===void 0)return 1;const B=parseInt(l,10);return isNaN(B)?0:B}const $i=Ti({name:"close-popup",beforeMount(l,{value:B}){const t={depth:Qo(B),handler(b){t.depth!==0&&setTimeout(()=>{const m=Bl(l);m!==void 0&&Il(m,b,t.depth)})},handlerKey(b){or(b,13)===!0&&t.handler(b)}};l.__qclosepopup=t,l.addEventListener("click",t.handler),l.addEventListener("keyup",t.handlerKey)},updated(l,{value:B,oldValue:t}){B!==t&&(l.__qclosepopup.depth=Qo(B))},beforeUnmount(l){const B=l.__qclosepopup;l.removeEventListener("click",B.handler),l.removeEventListener("keyup",B.handlerKey),delete l.__qclosepopup}}),xu=["src","alt"],Su={key:1,class:"project-environment-container row items-center q-mr-md"},ku=v.defineComponent({__name:"SelfeeHeader",props:{logoSrc:{},logoAlt:{},logoTo:{},showProjectSwitch:{type:Boolean},currentProjectLabel:{},availableProjects:{},currentPath:{},environment:{},showMenuToggle:{type:Boolean}},emits:["project-change","menu-toggle"],setup(l,{emit:B}){const t=l,b=t.logoAlt??"Logo",m=t.logoTo??"/",c=v.computed(()=>({width:"170px",height:"auto",borderRadius:"0"})),i=v.computed(()=>t.environment?t.environment.toUpperCase()!=="PROD":!1),s=v.computed(()=>`environment-badge--${t.environment?.toUpperCase()?.toLowerCase()}`),n=e=>t.currentPath?.startsWith(e);return(e,r)=>{const u=v.resolveComponent("router-link");return v.openBlock(),v.createBlock(wu,v.mergeProps({elevated:""},e.$attrs),{default:v.withCtx(()=>[v.createVNode(Ga,null,{default:v.withCtx(()=>[e.showMenuToggle?(v.openBlock(),v.createBlock(at,{key:0,flat:"",dense:"",icon:"menu",class:"q-mr-sm","data-testid":"menu-toggle-btn",onClick:r[0]||(r[0]=a=>e.$emit("menu-toggle"))})):v.createCommentVNode("",!0),v.createVNode(u,{to:v.unref(m),class:"q-mr-lg"},{default:v.withCtx(()=>[v.createVNode(Xa,{class:"logo",style:v.normalizeStyle(c.value),"data-testid":"header-logo"},{default:v.withCtx(()=>[v.createElementVNode("img",{src:e.logoSrc,alt:v.unref(b)},null,8,xu)]),_:1},8,["style"])]),_:1},8,["to"]),v.createVNode(vu),e.showProjectSwitch||i.value?(v.openBlock(),v.createElementBlock("div",Su,[i.value?(v.openBlock(),v.createElementBlock("div",{key:0,class:v.normalizeClass(["environment-badge",s.value]),"data-testid":"environment-badge"},v.toDisplayString(e.environment),3)):v.createCommentVNode("",!0),e.showProjectSwitch?(v.openBlock(),v.createBlock(at,{key:1,dense:"",unelevated:"",color:"primary",label:e.currentProjectLabel,"data-testid":"project-switch-btn",class:"project-switch-btn q-mr-md bg-info"},{default:v.withCtx(()=>[v.createVNode(Zr,{anchor:"bottom right",self:"top right"},{default:v.withCtx(()=>[v.createVNode(Hn,{dense:"",class:"project-menu"},{default:v.withCtx(()=>[(v.openBlock(!0),v.createElementBlock(v.Fragment,null,v.renderList(e.availableProjects,a=>v.withDirectives((v.openBlock(),v.createBlock(hr,{key:a.path,clickable:"",disable:n(a.path),onClick:o=>e.$emit("project-change",a.path)},{default:v.withCtx(()=>[v.createVNode(nr,{class:"q-mr-lg"},{default:v.withCtx(()=>[v.createVNode(ki,null,{default:v.withCtx(()=>[v.createTextVNode(v.toDisplayString(a.label),1)]),_:2},1024),n(a.path)?(v.openBlock(),v.createBlock(ki,{key:0,caption:""},{default:v.withCtx(()=>r[1]||(r[1]=[v.createTextVNode(" Actuel ")])),_:1,__:[1]})):v.createCommentVNode("",!0)]),_:2},1024)]),_:2},1032,["disable","onClick"])),[[$i]])),128))]),_:1})]),_:1})]),_:1},8,["label"])):v.createCommentVNode("",!0)])):v.createCommentVNode("",!0),v.renderSlot(e.$slots,"user-avatar",{},void 0,!0)]),_:3})]),_:3},16)}}}),_u=Vt(ku,[["__scopeId","data-v-a7cc4135"]]),Cu=$e({name:"QFooter",props:{modelValue:{type:Boolean,default:!0},reveal:Boolean,bordered:Boolean,elevated:Boolean,heightHint:{type:[String,Number],default:50}},emits:["reveal","focusin"],setup(l,{slots:B,emit:t}){const{proxy:{$q:b}}=v.getCurrentInstance(),m=v.inject($r,Rt);if(m===Rt)return console.error("QFooter needs to be child of QLayout"),Rt;const c=v.ref(parseInt(l.heightHint,10)),i=v.ref(!0),s=v.ref(ar.value===!0||m.isContainer.value===!0?0:window.innerHeight),n=v.computed(()=>l.reveal===!0||m.view.value.indexOf("F")!==-1||b.platform.is.ios&&m.isContainer.value===!0),e=v.computed(()=>m.isContainer.value===!0?m.containerHeight.value:s.value),r=v.computed(()=>{if(l.modelValue!==!0)return 0;if(n.value===!0)return i.value===!0?c.value:0;const T=m.scroll.value.position+e.value+c.value-m.height.value;return T>0?T:0}),u=v.computed(()=>l.modelValue!==!0||n.value===!0&&i.value!==!0),a=v.computed(()=>l.modelValue===!0&&u.value===!0&&l.reveal===!0),o=v.computed(()=>"q-footer q-layout__section--marginal "+(n.value===!0?"fixed":"absolute")+"-bottom"+(l.bordered===!0?" q-footer--bordered":"")+(u.value===!0?" q-footer--hidden":"")+(l.modelValue!==!0?" q-layout--prevent-focus"+(n.value!==!0?" hidden":""):"")),f=v.computed(()=>{const T=m.rows.value.bottom,D={};return T[0]==="l"&&m.left.space===!0&&(D[b.lang.rtl===!0?"right":"left"]=`${m.left.size}px`),T[2]==="r"&&m.right.space===!0&&(D[b.lang.rtl===!0?"left":"right"]=`${m.right.size}px`),D});function h(T,D){m.update("footer",T,D)}function d(T,D){T.value!==D&&(T.value=D)}function g({height:T}){d(c,T),h("size",T)}function p(){if(l.reveal!==!0)return;const{direction:T,position:D,inflectionPoint:V}=m.scroll.value;d(i,T==="up"||D-V<100||m.height.value-e.value-D-c.value<300)}function k(T){a.value===!0&&d(i,!0),t("focusin",T)}v.watch(()=>l.modelValue,T=>{h("space",T),d(i,!0),m.animate()}),v.watch(r,T=>{h("offset",T)}),v.watch(()=>l.reveal,T=>{T===!1&&d(i,l.modelValue)}),v.watch(i,T=>{m.animate(),t("reveal",T)}),v.watch([c,m.scroll,m.height],p),v.watch(()=>b.screen.height,T=>{m.isContainer.value!==!0&&d(s,T)});const C={};return m.instances.footer=C,l.modelValue===!0&&h("size",c.value),h("space",l.modelValue),h("offset",r.value),v.onBeforeUnmount(()=>{m.instances.footer===C&&(m.instances.footer=void 0,h("size",0),h("offset",0),h("space",!1))}),()=>{const T=It(B.default,[v.h(Ir,{debounce:0,onResize:g})]);return l.elevated===!0&&T.push(v.h("div",{class:"q-layout__shadow absolute-full overflow-hidden no-pointer-events"})),v.h("footer",{class:o.value,style:f.value,onFocusin:k},T)}}}),Au={class:"row justify-between"},Eu={class:"col-3 q-py-md flex justify-center"},Mu={class:"col-3 q-py-md flex justify-center"},Tu={class:"col-3 q-py-md flex justify-center"},Ru=v.defineComponent({__name:"SelfeeFooter",props:{frontVersion:{},backVersion:{},platform:{}},setup(l){return(B,t)=>(v.openBlock(),v.createBlock(Cu,v.mergeProps({elevated:""},B.$attrs),{default:v.withCtx(()=>[v.createElementVNode("div",Au,[v.createElementVNode("div",Eu," Front: "+v.toDisplayString(B.frontVersion),1),v.createElementVNode("div",Mu," Back: "+v.toDisplayString(B.backVersion),1),v.createElementVNode("div",Tu," Platform: "+v.toDisplayString(B.platform),1)])]),_:1},16))}}),Bu={true:"inset",item:"item-inset","item-thumbnail":"item-thumbnail-inset"},li={xs:2,sm:4,md:8,lg:16,xl:24},Br=$e({name:"QSeparator",props:{...Ot,spaced:[Boolean,String],inset:[Boolean,String],vertical:Boolean,color:String,size:String},setup(l){const B=v.getCurrentInstance(),t=Ft(l,B.proxy.$q),b=v.computed(()=>l.vertical===!0?"vertical":"horizontal"),m=v.computed(()=>` q-separator--${b.value}`),c=v.computed(()=>l.inset!==!1?`${m.value}-${Bu[l.inset]}`:""),i=v.computed(()=>`q-separator${m.value}${c.value}`+(l.color!==void 0?` bg-${l.color}`:"")+(t.value===!0?" q-separator--dark":"")),s=v.computed(()=>{const n={};if(l.size!==void 0&&(n[l.vertical===!0?"width":"height"]=l.size),l.spaced!==!1){const e=l.spaced===!0?`${li.md}px`:l.spaced in li?`${li[l.spaced]}px`:l.spaced,r=l.vertical===!0?["Left","Right"]:["Top","Bottom"];n[`margin${r[0]}`]=n[`margin${r[1]}`]=e}return n});return()=>v.h("hr",{class:i.value,style:s.value,"aria-orientation":b.value})}}),Iu=$e({name:"QToggle",props:{...xa,icon:String,iconColor:String},emits:Sa,setup(l){function B(t,b){const m=v.computed(()=>(t.value===!0?l.checkedIcon:b.value===!0?l.indeterminateIcon:l.uncheckedIcon)||l.icon),c=v.computed(()=>t.value===!0?l.iconColor:null);return()=>[v.h("div",{class:"q-toggle__track"}),v.h("div",{class:"q-toggle__thumb absolute flex flex-center no-wrap"},m.value!==void 0?[v.h(dt,{name:m.value,color:c.value})]:void 0)]}return ka("toggle",B)}}),Ou={class:"text-h6 text-primary","data-testid":"avatar-initial"},Fu={class:"text-weight-bold"},ju={class:"row items-center q-gutter-sm"},Du={class:"version-info"},Pu={class:"text-caption"},Nu={class:"text-caption"},Lu={class:"text-caption"},Vu=v.defineComponent({__name:"UserAvatar",props:{username:{},onLogout:{},logoutLabel:{default:"Déconnexion"},frontVersion:{default:"N/A"},backVersion:{default:"N/A"},platform:{default:"N/A"},showVersionInfo:{type:Boolean,default:!0},showFilterToggle:{type:Boolean,default:!1},persistFilters:{type:Boolean,default:!1}},emits:["toggle-filter-persistence"],setup(l,{emit:B}){const t=l,b=v.computed(()=>t.username?.charAt(0).toUpperCase()??"");return(m,c)=>(v.openBlock(),v.createElementBlock("div",null,[v.createVNode(Xa,{class:"cursor-pointer",size:"40px",color:"white","data-cy":"cy-avatar","data-testid":"cy-avatar"},{default:v.withCtx(()=>[v.createElementVNode("span",Ou,v.toDisplayString(b.value),1),v.createVNode(Zr,{"transition-show":"flip-right","transition-hide":"flip-left",class:"user-avatar-menu"},{default:v.withCtx(()=>[v.createVNode(Hn,{class:"user-menu-list"},{default:v.withCtx(()=>[v.createVNode(hr,{class:"user-info-section"},{default:v.withCtx(()=>[v.createVNode(nr,null,{default:v.withCtx(()=>[v.createElementVNode("div",Fu,v.toDisplayString(m.username),1)]),_:1})]),_:1}),v.createVNode(Br),m.showFilterToggle?(v.openBlock(),v.createBlock(hr,{key:0,class:"filter-toggle-section"},{default:v.withCtx(()=>[v.createVNode(nr,null,{default:v.withCtx(()=>[v.createElementVNode("div",ju,[c[1]||(c[1]=v.createElementVNode("span",{class:"text-caption"},"Filtres persistants",-1)),v.createVNode(Iu,{"model-value":m.persistFilters,"onUpdate:modelValue":c[0]||(c[0]=i=>m.$emit("toggle-filter-persistence",i)),size:"sm","data-cy":"filter-persistence-toggle"},null,8,["model-value"])])]),_:1})]),_:1})):v.createCommentVNode("",!0),m.showFilterToggle?(v.openBlock(),v.createBlock(Br,{key:1})):v.createCommentVNode("",!0),m.showVersionInfo?(v.openBlock(),v.createBlock(hr,{key:2,class:"version-info-section"},{default:v.withCtx(()=>[v.createVNode(nr,null,{default:v.withCtx(()=>[v.createElementVNode("div",Du,[c[2]||(c[2]=v.createElementVNode("div",{class:"text-caption text-grey-7"},"Informations de version",-1)),v.createElementVNode("div",Pu,"Front: "+v.toDisplayString(m.frontVersion),1),v.createElementVNode("div",Nu,"Back: "+v.toDisplayString(m.backVersion),1),v.createElementVNode("div",Lu,"Plateforme: "+v.toDisplayString(m.platform),1)])]),_:1})]),_:1})):v.createCommentVNode("",!0),m.showVersionInfo?(v.openBlock(),v.createBlock(Br,{key:3})):v.createCommentVNode("",!0),v.createVNode(hr,{clickable:"",class:"logout-section","data-cy":"cy-logout-button","data-testid":"cy-logout-button",onClick:m.onLogout},{default:v.withCtx(()=>[v.createVNode(nr,null,{default:v.withCtx(()=>[v.createElementVNode("div",null,v.toDisplayString(m.logoutLabel),1)]),_:1})]),_:1},8,["onClick"])]),_:1})]),_:1})]),_:1})]))}}),qu=Vt(Vu,[["__scopeId","data-v-d9b256cf"]]),zu=$e({name:"QPageContainer",setup(l,{slots:B}){const{proxy:{$q:t}}=v.getCurrentInstance(),b=v.inject($r,Rt);if(b===Rt)return console.error("QPageContainer needs to be child of QLayout"),Rt;v.provide(Va,!0);const m=v.computed(()=>{const c={};return b.header.space===!0&&(c.paddingTop=`${b.header.size}px`),b.right.space===!0&&(c[`padding${t.lang.rtl===!0?"Left":"Right"}`]=`${b.right.size}px`),b.footer.space===!0&&(c.paddingBottom=`${b.footer.size}px`),b.left.space===!0&&(c[`padding${t.lang.rtl===!0?"Right":"Left"}`]=`${b.left.size}px`),c});return()=>v.h("div",{class:"q-page-container",style:m.value},bt(B.default))}}),Uu=$e({name:"QLayout",props:{container:Boolean,view:{type:String,default:"hhh lpr fff",validator:l=>/^(h|l)h(h|r) lpr (f|l)f(f|r)$/.test(l.toLowerCase())},onScroll:Function,onScrollHeight:Function,onResize:Function},setup(l,{slots:B,emit:t}){const{proxy:{$q:b}}=v.getCurrentInstance(),m=v.ref(null),c=v.ref(b.screen.height),i=v.ref(l.container===!0?0:b.screen.width),s=v.ref({position:0,direction:"down",inflectionPoint:0}),n=v.ref(0),e=v.ref(ar.value===!0?0:Sn()),r=v.computed(()=>"q-layout q-layout--"+(l.container===!0?"containerized":"standard")),u=v.computed(()=>l.container===!1?{minHeight:b.screen.height+"px"}:null),a=v.computed(()=>e.value!==0?{[b.lang.rtl===!0?"left":"right"]:`${e.value}px`}:null),o=v.computed(()=>e.value!==0?{[b.lang.rtl===!0?"right":"left"]:0,[b.lang.rtl===!0?"left":"right"]:`-${e.value}px`,width:`calc(100% + ${e.value}px)`}:null);function f(C){if(l.container===!0||document.qScrollPrevented!==!0){const T={position:C.position.top,direction:C.direction,directionChanged:C.directionChanged,inflectionPoint:C.inflectionPoint.top,delta:C.delta.top};s.value=T,l.onScroll!==void 0&&t("scroll",T)}}function h(C){const{height:T,width:D}=C;let V=!1;c.value!==T&&(V=!0,c.value=T,l.onScrollHeight!==void 0&&t("scrollHeight",T),g()),i.value!==D&&(V=!0,i.value=D),V===!0&&l.onResize!==void 0&&t("resize",C)}function d({height:C}){n.value!==C&&(n.value=C,g())}function g(){if(l.container===!0){const C=c.value>n.value?Sn():0;e.value!==C&&(e.value=C)}}let p=null;const k={instances:{},view:v.computed(()=>l.view),isContainer:v.computed(()=>l.container),rootRef:m,height:c,containerHeight:n,scrollbarWidth:e,totalWidth:v.computed(()=>i.value+e.value),rows:v.computed(()=>{const C=l.view.toLowerCase().split(" ");return{top:C[0].split(""),middle:C[1].split(""),bottom:C[2].split("")}}),header:v.reactive({size:0,offset:0,space:!1}),right:v.reactive({size:300,offset:0,space:!1}),footer:v.reactive({size:0,offset:0,space:!1}),left:v.reactive({size:300,offset:0,space:!1}),scroll:s,animate(){p!==null?clearTimeout(p):document.body.classList.add("q-body--layout-animate"),p=setTimeout(()=>{p=null,document.body.classList.remove("q-body--layout-animate")},155)},update(C,T,D){k[C][T]=D}};if(v.provide($r,k),Sn()>0){let C=function(){V=null,P.classList.remove("hide-scrollbar")},T=function(){if(V===null){if(P.scrollHeight>b.screen.height)return;P.classList.add("hide-scrollbar")}else clearTimeout(V);V=setTimeout(C,300)},D=function(N){V!==null&&N==="remove"&&(clearTimeout(V),C()),window[`${N}EventListener`]("resize",T)},V=null;const P=document.body;v.watch(()=>l.container!==!0?"add":"remove",D),l.container!==!0&&D("add"),v.onUnmounted(()=>{D("remove")})}return()=>{const C=It(B.default,[v.h(Ma,{onScroll:f}),v.h(Ir,{onResize:h})]),T=v.h("div",{class:r.value,style:u.value,ref:l.container===!0?void 0:m,tabindex:-1},C);return l.container===!0?v.h("div",{class:"q-layout-container overflow-hidden",ref:m},[v.h(Ir,{onResize:d}),v.h("div",{class:"absolute-full",style:a.value},[v.h("div",{class:"scroll",style:o.value},[T])])]):T}}}),eo=v.defineComponent({name:"Layout",__name:"Layout",props:{view:{default:"HHh Lpr Fff"},layoutClass:{default:"bg-white"},pageContainerClass:{default:""}},setup(l){return(B,t)=>(v.openBlock(),v.createBlock(Uu,{view:B.view,class:v.normalizeClass(B.layoutClass),style:{minHeight:"auto !important"}},{default:v.withCtx(()=>[v.renderSlot(B.$slots,"header"),v.createVNode(zu,{class:v.normalizeClass(B.pageContainerClass),style:{paddingBottom:"0 !important"}},{default:v.withCtx(()=>[v.renderSlot(B.$slots,"default")]),_:3},8,["class"]),v.renderSlot(B.$slots,"footer")]),_:3},8,["view","class"]))}});function Wu(){let l=Object.create(null);return{getCache:(B,t)=>l[B]===void 0?l[B]=typeof t=="function"?t():t:l[B],setCache(B,t){l[B]=t},hasCache(B){return Object.hasOwnProperty.call(l,B)},clearCache(B){B!==void 0?delete l[B]:l=Object.create(null)}}}const ir=[-61,9,38,199,426,686,756,818,1111,1181,1210,1635,2060,2097,2192,2262,2324,2394,2456,3178];function Hu(l,B,t){return Object.prototype.toString.call(l)==="[object Date]"&&(t=l.getDate(),B=l.getMonth()+1,l=l.getFullYear()),Xu(to(l,B,t))}function Ko(l,B,t){return Za(Ku(l,B,t))}function Yu(l){return Qu(l)===0}function kn(l,B){return B<=6?31:B<=11||Yu(l)?30:29}function Qu(l){const B=ir.length;let t=ir[0],b,m,c,i,s;if(l<t||l>=ir[B-1])throw new Error("Invalid Jalaali year "+l);for(s=1;s<B&&(b=ir[s],m=b-t,!(l<b));s+=1)t=b;return i=l-t,m-i<6&&(i=i-m+wt(m+4,33)*33),c=Pt(Pt(i+1,33)-1,4),c===-1&&(c=4),c}function Ja(l,B){const t=ir.length,b=l+621;let m=-14,c=ir[0],i,s,n,e,r;if(l<c||l>=ir[t-1])throw new Error("Invalid Jalaali year "+l);for(r=1;r<t&&(i=ir[r],s=i-c,!(l<i));r+=1)m=m+wt(s,33)*8+wt(Pt(s,33),4),c=i;e=l-c,m=m+wt(e,33)*8+wt(Pt(e,33)+3,4),Pt(s,33)===4&&s-e===4&&(m+=1);const u=wt(b,4)-wt((wt(b,100)+1)*3,4)-150,a=20+m-u;return B||(s-e<6&&(e=e-s+wt(s+4,33)*33),n=Pt(Pt(e+1,33)-1,4),n===-1&&(n=4)),{leap:n,gy:b,march:a}}function Ku(l,B,t){const b=Ja(l,!0);return to(b.gy,3,b.march)+(B-1)*31-wt(B,7)*(B-7)+t-1}function Xu(l){const B=Za(l).gy;let t=B-621,b,m,c;const i=Ja(t,!1),s=to(B,3,i.march);if(c=l-s,c>=0){if(c<=185)return m=1+wt(c,31),b=Pt(c,31)+1,{jy:t,jm:m,jd:b};c-=186}else t-=1,c+=179,i.leap===1&&(c+=1);return m=7+wt(c,30),b=Pt(c,30)+1,{jy:t,jm:m,jd:b}}function to(l,B,t){let b=wt((l+wt(B-8,6)+100100)*1461,4)+wt(153*Pt(B+9,12)+2,5)+t-34840408;return b=b-wt(wt(l+100100+wt(B-8,6),100)*3,4)+752,b}function Za(l){let B=4*l+139361631;B=B+wt(wt(4*l+183187720,146097)*3,4)*4-3908;const t=wt(Pt(B,1461),4)*5+308,b=wt(Pt(t,153),5)+1,m=Pt(wt(t,153),12)+1;return{gy:wt(B,1461)-100100+wt(8-m,6),gm:m,gd:b}}function wt(l,B){return~~(l/B)}function Pt(l,B){return l-~~(l/B)*B}const Gu=["gregorian","persian"],Xo={mask:{type:String},locale:Object,calendar:{type:String,validator:l=>Gu.includes(l),default:"gregorian"},landscape:Boolean,color:String,textColor:String,square:Boolean,flat:Boolean,bordered:Boolean,readonly:Boolean,disable:Boolean},Ju=["update:modelValue"];function $t(l){return l.year+"/"+vt(l.month)+"/"+vt(l.day)}function Zu(l,B){const t=v.computed(()=>l.disable!==!0&&l.readonly!==!0),b=v.computed(()=>t.value===!0?0:-1),m=v.computed(()=>{const s=[];return l.color!==void 0&&s.push(`bg-${l.color}`),l.textColor!==void 0&&s.push(`text-${l.textColor}`),s.join(" ")});function c(){return l.locale!==void 0?{...B.lang.date,...l.locale}:B.lang.date}function i(s){const n=new Date,e=s===!0?null:0;if(l.calendar==="persian"){const r=Hu(n);return{year:r.jy,month:r.jm,day:r.jd}}return{year:n.getFullYear(),month:n.getMonth()+1,day:n.getDate(),hour:e,minute:e,second:e,millisecond:e}}return{editable:t,tabindex:b,headerClass:m,getLocale:c,getCurrentDate:i}}const Ai={isoName:"en-US",nativeName:"English (US)",label:{clear:"Clear",ok:"OK",cancel:"Cancel",close:"Close",set:"Set",select:"Select",reset:"Reset",remove:"Remove",update:"Update",create:"Create",search:"Search",filter:"Filter",refresh:"Refresh",expand:l=>l?`Expand "${l}"`:"Expand",collapse:l=>l?`Collapse "${l}"`:"Collapse"},date:{days:"Sunday_Monday_Tuesday_Wednesday_Thursday_Friday_Saturday".split("_"),daysShort:"Sun_Mon_Tue_Wed_Thu_Fri_Sat".split("_"),months:"January_February_March_April_May_June_July_August_September_October_November_December".split("_"),monthsShort:"Jan_Feb_Mar_Apr_May_Jun_Jul_Aug_Sep_Oct_Nov_Dec".split("_"),firstDayOfWeek:0,format24h:!1,pluralDay:"days",prevMonth:"Previous month",nextMonth:"Next month",prevYear:"Previous year",nextYear:"Next year",today:"Today",prevRangeYears:l=>`Previous ${l} years`,nextRangeYears:l=>`Next ${l} years`},table:{noData:"No data available",noResults:"No matching records found",loading:"Loading...",selectedRecords:l=>l===1?"1 record selected.":(l===0?"No":l)+" records selected.",recordsPerPage:"Records per page:",allRows:"All",pagination:(l,B,t)=>l+"-"+B+" of "+t,columns:"Columns"},pagination:{first:"First page",prev:"Previous page",next:"Next page",last:"Last page"},editor:{url:"URL",bold:"Bold",italic:"Italic",strikethrough:"Strikethrough",underline:"Underline",unorderedList:"Unordered List",orderedList:"Ordered List",subscript:"Subscript",superscript:"Superscript",hyperlink:"Hyperlink",toggleFullscreen:"Toggle Fullscreen",quote:"Quote",left:"Left align",center:"Center align",right:"Right align",justify:"Justify align",print:"Print",outdent:"Decrease indentation",indent:"Increase indentation",removeFormat:"Remove formatting",formatting:"Formatting",fontSize:"Font Size",align:"Align",hr:"Insert Horizontal Rule",undo:"Undo",redo:"Redo",heading1:"Heading 1",heading2:"Heading 2",heading3:"Heading 3",heading4:"Heading 4",heading5:"Heading 5",heading6:"Heading 6",paragraph:"Paragraph",code:"Code",size1:"Very small",size2:"A bit small",size3:"Normal",size4:"Medium-large",size5:"Big",size6:"Very big",size7:"Maximum",defaultFont:"Default Font",viewSource:"View Source"},tree:{noNodes:"No nodes available",noResults:"No matching nodes found"}};function Go(){const l=Array.isArray(navigator.languages)===!0&&navigator.languages.length!==0?navigator.languages[0]:navigator.language;if(typeof l=="string")return l.split(/[-_]/).map((B,t)=>t===0?B.toLowerCase():t>1||B.length<4?B.toUpperCase():B[0].toUpperCase()+B.slice(1).toLowerCase()).join("-")}const tr=As({__qLang:{}},{getLocale:Go,set(l=Ai,B){const t={...l,rtl:l.rtl===!0,getLocale:Go};{if(t.set=tr.set,tr.__langConfig===void 0||tr.__langConfig.noHtmlAttrs!==!0){const b=document.documentElement;b.setAttribute("dir",t.rtl===!0?"rtl":"ltr"),b.setAttribute("lang",t.isoName)}Object.assign(tr.__qLang,t)}},install({$q:l,lang:B,ssrContext:t}){l.lang=tr.__qLang,tr.__langConfig=l.config.lang,this.__installed===!0?B!==void 0&&this.set(B):(this.props=new Proxy(this.__qLang,{get(){return Reflect.get(...arguments)},ownKeys(b){return Reflect.ownKeys(b).filter(m=>m!=="set"&&m!=="getLocale")}}),this.set(B||Ai))}}),$a=864e5,$u=36e5,Ei=6e4,es="YYYY-MM-DDTHH:mm:ss.SSSZ",ec=/\[((?:[^\]\\]|\\]|\\)*)\]|do|d{1,4}|Mo|M{1,4}|m{1,2}|wo|w{1,2}|Qo|Do|DDDo|D{1,4}|YY(?:YY)?|H{1,2}|h{1,2}|s{1,2}|S{1,3}|Z{1,2}|a{1,2}|[AQExX]/g,tc=/(\[[^\]]*\])|do|d{1,4}|Mo|M{1,4}|m{1,2}|wo|w{1,2}|Qo|Do|DDDo|D{1,4}|YY(?:YY)?|H{1,2}|h{1,2}|s{1,2}|S{1,3}|Z{1,2}|a{1,2}|[AQExX]|([.*+:?^,\s${}()|\\]+)/g,ui={};function rc(l,B){const t="("+B.days.join("|")+")",b=l+t;if(ui[b]!==void 0)return ui[b];const m="("+B.daysShort.join("|")+")",c="("+B.months.join("|")+")",i="("+B.monthsShort.join("|")+")",s={};let n=0;const e=l.replace(tc,u=>{switch(n++,u){case"YY":return s.YY=n,"(-?\\d{1,2})";case"YYYY":return s.YYYY=n,"(-?\\d{1,4})";case"M":return s.M=n,"(\\d{1,2})";case"Mo":return s.M=n++,"(\\d{1,2}(st|nd|rd|th))";case"MM":return s.M=n,"(\\d{2})";case"MMM":return s.MMM=n,i;case"MMMM":return s.MMMM=n,c;case"D":return s.D=n,"(\\d{1,2})";case"Do":return s.D=n++,"(\\d{1,2}(st|nd|rd|th))";case"DD":return s.D=n,"(\\d{2})";case"H":return s.H=n,"(\\d{1,2})";case"HH":return s.H=n,"(\\d{2})";case"h":return s.h=n,"(\\d{1,2})";case"hh":return s.h=n,"(\\d{2})";case"m":return s.m=n,"(\\d{1,2})";case"mm":return s.m=n,"(\\d{2})";case"s":return s.s=n,"(\\d{1,2})";case"ss":return s.s=n,"(\\d{2})";case"S":return s.S=n,"(\\d{1})";case"SS":return s.S=n,"(\\d{2})";case"SSS":return s.S=n,"(\\d{3})";case"A":return s.A=n,"(AM|PM)";case"a":return s.a=n,"(am|pm)";case"aa":return s.aa=n,"(a\\.m\\.|p\\.m\\.)";case"ddd":return m;case"dddd":return t;case"Q":case"d":case"E":return"(\\d{1})";case"do":return n++,"(\\d{1}(st|nd|rd|th))";case"Qo":return"(1st|2nd|3rd|4th)";case"DDD":case"DDDD":return"(\\d{1,3})";case"DDDo":return n++,"(\\d{1,3}(st|nd|rd|th))";case"w":return"(\\d{1,2})";case"wo":return n++,"(\\d{1,2}(st|nd|rd|th))";case"ww":return"(\\d{2})";case"Z":return s.Z=n,"(Z|[+-]\\d{2}:\\d{2})";case"ZZ":return s.ZZ=n,"(Z|[+-]\\d{2}\\d{2})";case"X":return s.X=n,"(-?\\d+)";case"x":return s.x=n,"(-?\\d{4,})";default:return n--,u[0]==="["&&(u=u.substring(1,u.length-1)),u.replace(/[.*+?^${}()|[\]\\]/g,"\\$&")}}),r={map:s,regex:new RegExp("^"+e)};return ui[b]=r,r}function ts(l,B){return l!==void 0?l:B!==void 0?B.date:Ai.date}function Jo(l,B=""){const t=l>0?"-":"+",b=Math.abs(l),m=Math.floor(b/60),c=b%60;return t+vt(m)+B+vt(c)}function nc(l,B,t){let b=l.getFullYear(),m=l.getMonth();const c=l.getDate();return B.year!==void 0&&(b+=t*B.year,delete B.year),B.month!==void 0&&(m+=t*B.month,delete B.month),l.setDate(1),l.setMonth(2),l.setFullYear(b),l.setMonth(m),l.setDate(Math.min(c,io(l))),B.date!==void 0&&(l.setDate(l.getDate()+t*B.date),delete B.date),l}function ic(l,B,t){const b=B.year!==void 0?B.year:l[`get${t}FullYear`](),m=B.month!==void 0?B.month-1:l[`get${t}Month`](),c=new Date(b,m+1,0).getDate(),i=Math.min(c,B.date!==void 0?B.date:l[`get${t}Date`]());return l[`set${t}Date`](1),l[`set${t}Month`](2),l[`set${t}FullYear`](b),l[`set${t}Month`](m),l[`set${t}Date`](i),delete B.year,delete B.month,delete B.date,l}function ro(l,B,t){const b=rs(B),m=new Date(l),c=b.year!==void 0||b.month!==void 0||b.date!==void 0?nc(m,b,t):m;for(const i in b){const s=kl(i);c[`set${s}`](c[`get${s}`]()+t*b[i])}return c}function rs(l){const B={...l};return l.years!==void 0&&(B.year=l.years,delete B.years),l.months!==void 0&&(B.month=l.months,delete B.months),l.days!==void 0&&(B.date=l.days,delete B.days),l.day!==void 0&&(B.date=l.day,delete B.day),l.hour!==void 0&&(B.hours=l.hour,delete B.hour),l.minute!==void 0&&(B.minutes=l.minute,delete B.minute),l.second!==void 0&&(B.seconds=l.second,delete B.second),l.millisecond!==void 0&&(B.milliseconds=l.millisecond,delete B.millisecond),B}function ns(l,B,t){const b=rs(B),m=t===!0?"UTC":"",c=new Date(l),i=b.year!==void 0||b.month!==void 0||b.date!==void 0?ic(c,b,m):c;for(const s in b){const n=s.charAt(0).toUpperCase()+s.slice(1);i[`set${m}${n}`](b[s])}return i}function oc(l,B,t){const b=is(l,B,t),m=new Date(b.year,b.month===null?null:b.month-1,b.day===null?1:b.day,b.hour,b.minute,b.second,b.millisecond),c=m.getTimezoneOffset();return b.timezoneOffset===null||b.timezoneOffset===c?m:ro(m,{minutes:b.timezoneOffset-c},1)}function is(l,B,t,b,m){const c={year:null,month:null,day:null,hour:null,minute:null,second:null,millisecond:null,timezoneOffset:null,dateHash:null,timeHash:null};if(m!==void 0&&Object.assign(c,m),l==null||l===""||typeof l!="string")return c;B===void 0&&(B=es);const i=ts(t,tr.props),s=i.months,n=i.monthsShort,{regex:e,map:r}=rc(B,i),u=l.match(e);if(u===null)return c;let a="";if(r.X!==void 0||r.x!==void 0){const o=parseInt(u[r.X!==void 0?r.X:r.x],10);if(isNaN(o)===!0||o<0)return c;const f=new Date(o*(r.X!==void 0?1e3:1));c.year=f.getFullYear(),c.month=f.getMonth()+1,c.day=f.getDate(),c.hour=f.getHours(),c.minute=f.getMinutes(),c.second=f.getSeconds(),c.millisecond=f.getMilliseconds()}else{if(r.YYYY!==void 0)c.year=parseInt(u[r.YYYY],10);else if(r.YY!==void 0){const o=parseInt(u[r.YY],10);c.year=o<0?o:2e3+o}if(r.M!==void 0){if(c.month=parseInt(u[r.M],10),c.month<1||c.month>12)return c}else r.MMM!==void 0?c.month=n.indexOf(u[r.MMM])+1:r.MMMM!==void 0&&(c.month=s.indexOf(u[r.MMMM])+1);if(r.D!==void 0){if(c.day=parseInt(u[r.D],10),c.year===null||c.month===null||c.day<1)return c;const o=b!=="persian"?new Date(c.year,c.month,0).getDate():kn(c.year,c.month);if(c.day>o)return c}r.H!==void 0?c.hour=parseInt(u[r.H],10)%24:r.h!==void 0&&(c.hour=parseInt(u[r.h],10)%12,(r.A&&u[r.A]==="PM"||r.a&&u[r.a]==="pm"||r.aa&&u[r.aa]==="p.m.")&&(c.hour+=12),c.hour=c.hour%24),r.m!==void 0&&(c.minute=parseInt(u[r.m],10)%60),r.s!==void 0&&(c.second=parseInt(u[r.s],10)%60),r.S!==void 0&&(c.millisecond=parseInt(u[r.S],10)*10**(3-u[r.S].length)),(r.Z!==void 0||r.ZZ!==void 0)&&(a=r.Z!==void 0?u[r.Z].replace(":",""):u[r.ZZ],c.timezoneOffset=(a[0]==="+"?-1:1)*(60*a.slice(1,3)+1*a.slice(3,5)))}return c.dateHash=vt(c.year,4)+"/"+vt(c.month)+"/"+vt(c.day),c.timeHash=vt(c.hour)+":"+vt(c.minute)+":"+vt(c.second)+a,c}function ac(l){return typeof l=="number"?!0:isNaN(Date.parse(l))===!1}function sc(l,B){return ns(new Date,l,B)}function lc(l){const B=new Date(l).getDay();return B===0?7:B}function _n(l){const B=new Date(l.getFullYear(),l.getMonth(),l.getDate());B.setDate(B.getDate()-(B.getDay()+6)%7+3);const t=new Date(B.getFullYear(),0,4);t.setDate(t.getDate()-(t.getDay()+6)%7+3);const b=B.getTimezoneOffset()-t.getTimezoneOffset();B.setHours(B.getHours()-b);const m=(B-t)/($a*7);return 1+Math.floor(m)}function uc(l){return l.getFullYear()*1e4+l.getMonth()*100+l.getDate()}function ci(l,B){const t=new Date(l);return B===!0?uc(t):t.getTime()}function cc(l,B,t,b={}){const m=ci(B,b.onlyDate),c=ci(t,b.onlyDate),i=ci(l,b.onlyDate);return(i>m||b.inclusiveFrom===!0&&i===m)&&(i<c||b.inclusiveTo===!0&&i===c)}function dc(l,B){return ro(l,B,1)}function fc(l,B){return ro(l,B,-1)}function Ht(l,B,t){const b=new Date(l),m=`set${t===!0?"UTC":""}`;switch(B){case"year":case"years":b[`${m}Month`](0);case"month":case"months":b[`${m}Date`](1);case"day":case"days":case"date":b[`${m}Hours`](0);case"hour":case"hours":b[`${m}Minutes`](0);case"minute":case"minutes":b[`${m}Seconds`](0);case"second":case"seconds":b[`${m}Milliseconds`](0)}return b}function hc(l,B,t){const b=new Date(l),m=`set${t===!0?"UTC":""}`;switch(B){case"year":case"years":b[`${m}Month`](11);case"month":case"months":b[`${m}Date`](io(b));case"day":case"days":case"date":b[`${m}Hours`](23);case"hour":case"hours":b[`${m}Minutes`](59);case"minute":case"minutes":b[`${m}Seconds`](59);case"second":case"seconds":b[`${m}Milliseconds`](999)}return b}function pc(l){let B=new Date(l);return Array.prototype.slice.call(arguments,1).forEach(t=>{B=Math.max(B,new Date(t))}),B}function mc(l){let B=new Date(l);return Array.prototype.slice.call(arguments,1).forEach(t=>{B=Math.min(B,new Date(t))}),B}function mn(l,B,t){return(l.getTime()-l.getTimezoneOffset()*Ei-(B.getTime()-B.getTimezoneOffset()*Ei))/t}function no(l,B,t="days"){const b=new Date(l),m=new Date(B);switch(t){case"years":case"year":return b.getFullYear()-m.getFullYear();case"months":case"month":return(b.getFullYear()-m.getFullYear())*12+b.getMonth()-m.getMonth();case"days":case"day":case"date":return mn(Ht(b,"day"),Ht(m,"day"),$a);case"hours":case"hour":return mn(Ht(b,"hour"),Ht(m,"hour"),$u);case"minutes":case"minute":return mn(Ht(b,"minute"),Ht(m,"minute"),Ei);case"seconds":case"second":return mn(Ht(b,"second"),Ht(m,"second"),1e3)}}function Cn(l){return no(l,Ht(l,"year"),"days")+1}function gc(l){return Fn(l)===!0?"date":typeof l=="number"?"number":"string"}function bc(l,B,t){const b=new Date(l);if(B){const m=new Date(B);if(b<m)return m}if(t){const m=new Date(t);if(b>m)return m}return b}function vc(l,B,t){const b=new Date(l),m=new Date(B);if(t===void 0)return b.getTime()===m.getTime();switch(t){case"second":case"seconds":if(b.getSeconds()!==m.getSeconds())return!1;case"minute":case"minutes":if(b.getMinutes()!==m.getMinutes())return!1;case"hour":case"hours":if(b.getHours()!==m.getHours())return!1;case"day":case"days":case"date":if(b.getDate()!==m.getDate())return!1;case"month":case"months":if(b.getMonth()!==m.getMonth())return!1;case"year":case"years":if(b.getFullYear()!==m.getFullYear())return!1;break;default:throw new Error(`date isSameDate unknown unit ${t}`)}return!0}function io(l){return new Date(l.getFullYear(),l.getMonth()+1,0).getDate()}function Cr(l){if(l>=11&&l<=13)return`${l}th`;switch(l%10){case 1:return`${l}st`;case 2:return`${l}nd`;case 3:return`${l}rd`}return`${l}th`}const Zo={YY(l,B,t){const b=this.YYYY(l,B,t)%100;return b>=0?vt(b):"-"+vt(Math.abs(b))},YYYY(l,B,t){return t??l.getFullYear()},M(l){return l.getMonth()+1},Mo(l){return Cr(l.getMonth()+1)},MM(l){return vt(l.getMonth()+1)},MMM(l,B){return B.monthsShort[l.getMonth()]},MMMM(l,B){return B.months[l.getMonth()]},Q(l){return Math.ceil((l.getMonth()+1)/3)},Qo(l){return Cr(this.Q(l))},D(l){return l.getDate()},Do(l){return Cr(l.getDate())},DD(l){return vt(l.getDate())},DDD(l){return Cn(l)},DDDo(l){return Cr(Cn(l))},DDDD(l){return vt(Cn(l),3)},d(l){return l.getDay()},do(l){return Cr(l.getDay())},dd(l,B){return B.days[l.getDay()].slice(0,2)},ddd(l,B){return B.daysShort[l.getDay()]},dddd(l,B){return B.days[l.getDay()]},E(l){return l.getDay()||7},w(l){return _n(l)},wo(l){return Cr(_n(l))},ww(l){return vt(_n(l))},H(l){return l.getHours()},HH(l){return vt(l.getHours())},h(l){const B=l.getHours();return B===0?12:B>12?B%12:B},hh(l){return vt(this.h(l))},m(l){return l.getMinutes()},mm(l){return vt(l.getMinutes())},s(l){return l.getSeconds()},ss(l){return vt(l.getSeconds())},S(l){return Math.floor(l.getMilliseconds()/100)},SS(l){return vt(Math.floor(l.getMilliseconds()/10))},SSS(l){return vt(l.getMilliseconds(),3)},A(l){return l.getHours()<12?"AM":"PM"},a(l){return l.getHours()<12?"am":"pm"},aa(l){return l.getHours()<12?"a.m.":"p.m."},Z(l,B,t,b){const m=b??l.getTimezoneOffset();return Jo(m,":")},ZZ(l,B,t,b){const m=b??l.getTimezoneOffset();return Jo(m)},X(l){return Math.floor(l.getTime()/1e3)},x(l){return l.getTime()}};function os(l,B,t,b,m){if(l!==0&&!l||l===1/0||l===-1/0)return;const c=new Date(l);if(isNaN(c))return;B===void 0&&(B=es);const i=ts(t,tr.props);return B.replace(ec,(s,n)=>s in Zo?Zo[s](c,i,b,m):n===void 0?s:n.split("\\]").join("]"))}function yc(l){return Fn(l)===!0?new Date(l.getTime()):l}const as={isValid:ac,extractDate:oc,buildDate:sc,getDayOfWeek:lc,getWeekOfYear:_n,isBetweenDates:cc,addToDate:dc,subtractFromDate:fc,adjustDate:ns,startOfDate:Ht,endOfDate:hc,getMaxDate:pc,getMinDate:mc,getDateDiff:no,getDayOfYear:Cn,inferDateFormat:gc,getDateBetween:bc,isSameDate:vc,daysInMonth:io,formatDate:os,clone:yc},Qt=20,wc=["Calendar","Years","Months"],$o=l=>wc.includes(l),di=l=>/^-?[\d]+\/[0-1]\d$/.test(l),Ar=" — ";function er(l){return l.year+"/"+vt(l.month)}const ss=$e({name:"QDate",props:{...Xo,...Vn,...Ot,modelValue:{required:!0,validator:l=>typeof l=="string"||Array.isArray(l)===!0||Object(l)===l||l===null},multiple:Boolean,range:Boolean,title:String,subtitle:String,mask:{...Xo.mask,default:"YYYY/MM/DD"},defaultYearMonth:{type:String,validator:di},yearsInMonthView:Boolean,events:[Array,Function],eventColor:[String,Function],emitImmediately:Boolean,options:[Array,Function],navigationMinYearMonth:{type:String,validator:di},navigationMaxYearMonth:{type:String,validator:di},noUnset:Boolean,firstDayOfWeek:[String,Number],todayBtn:Boolean,minimal:Boolean,defaultView:{type:String,default:"Calendar",validator:$o}},emits:[...Ju,"rangeStart","rangeEnd","navigation"],setup(l,{slots:B,emit:t}){const{proxy:b}=v.getCurrentInstance(),{$q:m}=b,c=Ft(l,m),{getCache:i}=Wu(),{tabindex:s,headerClass:n,getLocale:e,getCurrentDate:r}=Zu(l,m);let u;const a=ll(l),o=ya(a),f=v.ref(null),h=v.ref(Ue()),d=v.ref(e()),g=v.computed(()=>Ue()),p=v.computed(()=>e()),k=v.computed(()=>r()),C=v.ref(Le(h.value,d.value)),T=v.ref(l.defaultView),D=v.computed(()=>m.lang.rtl===!0?"right":"left"),V=v.ref(D.value),P=v.ref(D.value),N=C.value.year,q=v.ref(N-N%Qt-(N<0?Qt:0)),W=v.ref(null),L=v.computed(()=>{const re=l.landscape===!0?"landscape":"portrait";return`q-date q-date--${re} q-date--${re}-${l.minimal===!0?"minimal":"standard"}`+(c.value===!0?" q-date--dark q-dark":"")+(l.bordered===!0?" q-date--bordered":"")+(l.square===!0?" q-date--square no-border-radius":"")+(l.flat===!0?" q-date--flat no-shadow":"")+(l.disable===!0?" disabled":l.readonly===!0?" q-date--readonly":"")}),A=v.computed(()=>l.color||"primary"),M=v.computed(()=>l.textColor||"white"),_=v.computed(()=>l.emitImmediately===!0&&l.multiple!==!0&&l.range!==!0),y=v.computed(()=>Array.isArray(l.modelValue)===!0?l.modelValue:l.modelValue!==null&&l.modelValue!==void 0?[l.modelValue]:[]),x=v.computed(()=>y.value.filter(re=>typeof re=="string").map(re=>Ne(re,h.value,d.value)).filter(re=>re.dateHash!==null&&re.day!==null&&re.month!==null&&re.year!==null)),w=v.computed(()=>{const re=X=>Ne(X,h.value,d.value);return y.value.filter(X=>Ka(X)===!0&&X.from!==void 0&&X.to!==void 0).map(X=>({from:re(X.from),to:re(X.to)})).filter(X=>X.from.dateHash!==null&&X.to.dateHash!==null&&X.from.dateHash<X.to.dateHash)}),S=v.computed(()=>l.calendar!=="persian"?re=>new Date(re.year,re.month-1,re.day):re=>{const X=Ko(re.year,re.month,re.day);return new Date(X.gy,X.gm-1,X.gd)}),E=v.computed(()=>l.calendar==="persian"?$t:(re,X,ne)=>os(new Date(re.year,re.month-1,re.day,re.hour,re.minute,re.second,re.millisecond),X===void 0?h.value:X,ne===void 0?d.value:ne,re.year,re.timezoneOffset)),O=v.computed(()=>x.value.length+w.value.reduce((re,X)=>re+1+no(S.value(X.to),S.value(X.from)),0)),R=v.computed(()=>{if(l.title!==void 0&&l.title!==null&&l.title.length!==0)return l.title;if(W.value!==null){const ne=W.value.init,fe=S.value(ne);return d.value.daysShort[fe.getDay()]+", "+d.value.monthsShort[ne.month-1]+" "+ne.day+Ar+"?"}if(O.value===0)return Ar;if(O.value>1)return`${O.value} ${d.value.pluralDay}`;const re=x.value[0],X=S.value(re);return isNaN(X.valueOf())===!0?Ar:d.value.headerTitle!==void 0?d.value.headerTitle(X,re):d.value.daysShort[X.getDay()]+", "+d.value.monthsShort[re.month-1]+" "+re.day}),z=v.computed(()=>x.value.concat(w.value.map(X=>X.from)).sort((X,ne)=>X.year-ne.year||X.month-ne.month)[0]),U=v.computed(()=>x.value.concat(w.value.map(X=>X.to)).sort((X,ne)=>ne.year-X.year||ne.month-X.month)[0]),Q=v.computed(()=>{if(l.subtitle!==void 0&&l.subtitle!==null&&l.subtitle.length!==0)return l.subtitle;if(O.value===0)return Ar;if(O.value>1){const re=z.value,X=U.value,ne=d.value.monthsShort;return ne[re.month-1]+(re.year!==X.year?" "+re.year+Ar+ne[X.month-1]+" ":re.month!==X.month?Ar+ne[X.month-1]:"")+" "+X.year}return x.value[0].year}),j=v.computed(()=>{const re=[m.iconSet.datetime.arrowLeft,m.iconSet.datetime.arrowRight];return m.lang.rtl===!0?re.reverse():re}),Y=v.computed(()=>l.firstDayOfWeek!==void 0?Number(l.firstDayOfWeek):d.value.firstDayOfWeek),F=v.computed(()=>{const re=d.value.daysShort,X=Y.value;return X>0?re.slice(X,7).concat(re.slice(0,X)):re}),I=v.computed(()=>{const re=C.value;return l.calendar!=="persian"?new Date(re.year,re.month,0).getDate():kn(re.year,re.month)}),H=v.computed(()=>typeof l.eventColor=="function"?l.eventColor:()=>l.eventColor),K=v.computed(()=>{if(l.navigationMinYearMonth===void 0)return null;const re=l.navigationMinYearMonth.split("/");return{year:parseInt(re[0],10),month:parseInt(re[1],10)}}),ee=v.computed(()=>{if(l.navigationMaxYearMonth===void 0)return null;const re=l.navigationMaxYearMonth.split("/");return{year:parseInt(re[0],10),month:parseInt(re[1],10)}}),G=v.computed(()=>{const re={month:{prev:!0,next:!0},year:{prev:!0,next:!0}};return K.value!==null&&K.value.year>=C.value.year&&(re.year.prev=!1,K.value.year===C.value.year&&K.value.month>=C.value.month&&(re.month.prev=!1)),ee.value!==null&&ee.value.year<=C.value.year&&(re.year.next=!1,ee.value.year===C.value.year&&ee.value.month<=C.value.month&&(re.month.next=!1)),re}),te=v.computed(()=>{const re={};return x.value.forEach(X=>{const ne=er(X);re[ne]===void 0&&(re[ne]=[]),re[ne].push(X.day)}),re}),ce=v.computed(()=>{const re={};return w.value.forEach(X=>{const ne=er(X.from),fe=er(X.to);if(re[ne]===void 0&&(re[ne]=[]),re[ne].push({from:X.from.day,to:ne===fe?X.to.day:void 0,range:X}),ne<fe){let be;const{year:Me,month:ve}=X.from,_e=ve<12?{year:Me,month:ve+1}:{year:Me+1,month:1};for(;(be=er(_e))<=fe;)re[be]===void 0&&(re[be]=[]),re[be].push({from:void 0,to:be===fe?X.to.day:void 0,range:X}),_e.month++,_e.month>12&&(_e.year++,_e.month=1)}}),re}),ue=v.computed(()=>{if(W.value===null)return;const{init:re,initHash:X,final:ne,finalHash:fe}=W.value,[be,Me]=X<=fe?[re,ne]:[ne,re],ve=er(be),_e=er(Me);if(ve!==J.value&&_e!==J.value)return;const Be={};return ve===J.value?(Be.from=be.day,Be.includeFrom=!0):Be.from=1,_e===J.value?(Be.to=Me.day,Be.includeTo=!0):Be.to=I.value,Be}),J=v.computed(()=>er(C.value)),ae=v.computed(()=>{const re={};if(l.options===void 0){for(let ne=1;ne<=I.value;ne++)re[ne]=!0;return re}const X=typeof l.options=="function"?l.options:ne=>l.options.includes(ne);for(let ne=1;ne<=I.value;ne++){const fe=J.value+"/"+vt(ne);re[ne]=X(fe)}return re}),se=v.computed(()=>{const re={};if(l.events===void 0)for(let X=1;X<=I.value;X++)re[X]=!1;else{const X=typeof l.events=="function"?l.events:ne=>l.events.includes(ne);for(let ne=1;ne<=I.value;ne++){const fe=J.value+"/"+vt(ne);re[ne]=X(fe)===!0&&H.value(fe)}}return re}),pe=v.computed(()=>{let re,X;const{year:ne,month:fe}=C.value;if(l.calendar!=="persian")re=new Date(ne,fe-1,1),X=new Date(ne,fe-1,0).getDate();else{const be=Ko(ne,fe,1);re=new Date(be.gy,be.gm-1,be.gd);let Me=fe-1,ve=ne;Me===0&&(Me=12,ve--),X=kn(ve,Me)}return{days:re.getDay()-Y.value-1,endDay:X}}),$=v.computed(()=>{const re=[],{days:X,endDay:ne}=pe.value,fe=X<0?X+7:X;if(fe<6)for(let ve=ne-fe;ve<=ne;ve++)re.push({i:ve,fill:!0});const be=re.length;for(let ve=1;ve<=I.value;ve++){const _e={i:ve,event:se.value[ve],classes:[]};ae.value[ve]===!0&&(_e.in=!0,_e.flat=!0),re.push(_e)}if(te.value[J.value]!==void 0&&te.value[J.value].forEach(ve=>{const _e=be+ve-1;Object.assign(re[_e],{selected:!0,unelevated:!0,flat:!1,color:A.value,textColor:M.value})}),ce.value[J.value]!==void 0&&ce.value[J.value].forEach(ve=>{if(ve.from!==void 0){const _e=be+ve.from-1,Be=be+(ve.to||I.value)-1;for(let ze=_e;ze<=Be;ze++)Object.assign(re[ze],{range:ve.range,unelevated:!0,color:A.value,textColor:M.value});Object.assign(re[_e],{rangeFrom:!0,flat:!1}),ve.to!==void 0&&Object.assign(re[Be],{rangeTo:!0,flat:!1})}else if(ve.to!==void 0){const _e=be+ve.to-1;for(let Be=be;Be<=_e;Be++)Object.assign(re[Be],{range:ve.range,unelevated:!0,color:A.value,textColor:M.value});Object.assign(re[_e],{flat:!1,rangeTo:!0})}else{const _e=be+I.value-1;for(let Be=be;Be<=_e;Be++)Object.assign(re[Be],{range:ve.range,unelevated:!0,color:A.value,textColor:M.value})}}),ue.value!==void 0){const ve=be+ue.value.from-1,_e=be+ue.value.to-1;for(let Be=ve;Be<=_e;Be++)re[Be].color=A.value,re[Be].editRange=!0;ue.value.includeFrom===!0&&(re[ve].editRangeFrom=!0),ue.value.includeTo===!0&&(re[_e].editRangeTo=!0)}C.value.year===k.value.year&&C.value.month===k.value.month&&(re[be+k.value.day-1].today=!0);const Me=re.length%7;if(Me>0){const ve=7-Me;for(let _e=1;_e<=ve;_e++)re.push({i:_e,fill:!0})}return re.forEach(ve=>{let _e="q-date__calendar-item ";ve.fill===!0?_e+="q-date__calendar-item--fill":(_e+=`q-date__calendar-item--${ve.in===!0?"in":"out"}`,ve.range!==void 0&&(_e+=` q-date__range${ve.rangeTo===!0?"-to":ve.rangeFrom===!0?"-from":""}`),ve.editRange===!0&&(_e+=` q-date__edit-range${ve.editRangeFrom===!0?"-from":""}${ve.editRangeTo===!0?"-to":""}`),(ve.range!==void 0||ve.editRange===!0)&&(_e+=` text-${ve.color}`)),ve.classes=_e}),re}),ie=v.computed(()=>l.disable===!0?{"aria-disabled":"true"}:{});v.watch(()=>l.modelValue,re=>{if(u===JSON.stringify(re))u=0;else{const X=Le(h.value,d.value);et(X.year,X.month,X)}}),v.watch(T,()=>{f.value!==null&&b.$el.contains(document.activeElement)===!0&&f.value.focus()}),v.watch(()=>C.value.year+"|"+C.value.month,()=>{t("navigation",{year:C.value.year,month:C.value.month})}),v.watch(g,re=>{xe(re,d.value,"mask"),h.value=re}),v.watch(p,re=>{xe(h.value,re,"locale"),d.value=re});function oe(re){u=JSON.stringify(re)}function le(){const{year:re,month:X,day:ne}=k.value,fe={...C.value,year:re,month:X,day:ne},be=te.value[er(fe)];(be===void 0||be.includes(fe.day)===!1)&&st(fe),Ae(fe.year,fe.month)}function ge(re){$o(re)===!0&&(T.value=re)}function Ce(re,X){["month","year"].includes(re)&&(re==="month"?Fe:ke)(X===!0?-1:1)}function Ae(re,X){T.value="Calendar",et(re,X)}function Te(re,X){if(l.range===!1||!re){W.value=null;return}const ne=Object.assign({...C.value},re),fe=X!==void 0?Object.assign({...C.value},X):ne;W.value={init:ne,initHash:$t(ne),final:fe,finalHash:$t(fe)},Ae(ne.year,ne.month)}function Ue(){return l.calendar==="persian"?"YYYY/MM/DD":l.mask}function Ne(re,X,ne){return is(re,X,ne,l.calendar,{hour:0,minute:0,second:0,millisecond:0})}function Le(re,X){const ne=Array.isArray(l.modelValue)===!0?l.modelValue:l.modelValue?[l.modelValue]:[];if(ne.length===0)return qe();const fe=ne[ne.length-1],be=Ne(fe.from!==void 0?fe.from:fe,re,X);return be.dateHash===null?qe():be}function qe(){let re,X;if(l.defaultYearMonth!==void 0){const ne=l.defaultYearMonth.split("/");re=parseInt(ne[0],10),X=parseInt(ne[1],10)}else{const ne=k.value!==void 0?k.value:r();re=ne.year,X=ne.month}return{year:re,month:X,day:1,hour:0,minute:0,second:0,millisecond:0,dateHash:re+"/"+vt(X)+"/01"}}function Fe(re){let X=C.value.year,ne=Number(C.value.month)+re;ne===13?(ne=1,X++):ne===0&&(ne=12,X--),et(X,ne),_.value===!0&&nt("month")}function ke(re){const X=Number(C.value.year)+re;et(X,C.value.month),_.value===!0&&nt("year")}function De(re){et(re,C.value.month),T.value=l.defaultView==="Years"?"Months":"Calendar",_.value===!0&&nt("year")}function We(re){et(C.value.year,re),T.value="Calendar",_.value===!0&&nt("month")}function Ve(re,X){(te.value[X]?.includes(re.day)===!0?me:st)(re)}function Ge(re){return{year:re.year,month:re.month,day:re.day}}function et(re,X,ne){if(K.value!==null&&re<=K.value.year&&((X<K.value.month||re<K.value.year)&&(X=K.value.month),re=K.value.year),ee.value!==null&&re>=ee.value.year&&((X>ee.value.month||re>ee.value.year)&&(X=ee.value.month),re=ee.value.year),ne!==void 0){const{hour:be,minute:Me,second:ve,millisecond:_e,timezoneOffset:Be,timeHash:ze}=ne;Object.assign(C.value,{hour:be,minute:Me,second:ve,millisecond:_e,timezoneOffset:Be,timeHash:ze})}const fe=re+"/"+vt(X)+"/01";fe!==C.value.dateHash&&(V.value=C.value.dateHash<fe==(m.lang.rtl!==!0)?"left":"right",re!==C.value.year&&(P.value=V.value),v.nextTick(()=>{q.value=re-re%Qt-(re<0?Qt:0),Object.assign(C.value,{year:re,month:X,day:1,dateHash:fe})}))}function He(re,X,ne){const fe=re!==null&&re.length===1&&l.multiple===!1?re[0]:re,{reason:be,details:Me}=tt(X,ne);oe(fe),t("update:modelValue",fe,be,Me)}function nt(re){const X=x.value[0]!==void 0&&x.value[0].dateHash!==null?{...x.value[0]}:{...C.value};v.nextTick(()=>{X.year=C.value.year,X.month=C.value.month;const ne=l.calendar!=="persian"?new Date(X.year,X.month,0).getDate():kn(X.year,X.month);X.day=Math.min(Math.max(1,X.day),ne);const fe=Ye(X),{details:be}=tt("",X);oe(fe),t("update:modelValue",fe,re,be)})}function tt(re,X){return X.from!==void 0?{reason:`${re}-range`,details:{...Ge(X.target),from:Ge(X.from),to:Ge(X.to)}}:{reason:`${re}-day`,details:Ge(X)}}function Ye(re,X,ne){return re.from!==void 0?{from:E.value(re.from,X,ne),to:E.value(re.to,X,ne)}:E.value(re,X,ne)}function st(re){let X;if(l.multiple===!0)if(re.from!==void 0){const ne=$t(re.from),fe=$t(re.to),be=x.value.filter(ve=>ve.dateHash<ne||ve.dateHash>fe),Me=w.value.filter(({from:ve,to:_e})=>_e.dateHash<ne||ve.dateHash>fe);X=be.concat(Me).concat(re).map(ve=>Ye(ve))}else{const ne=y.value.slice();ne.push(Ye(re)),X=ne}else X=Ye(re);He(X,"add",re)}function me(re){if(l.noUnset===!0)return;let X=null;if(l.multiple===!0&&Array.isArray(l.modelValue)===!0){const ne=Ye(re);re.from!==void 0?X=l.modelValue.filter(fe=>fe.from!==void 0?fe.from!==ne.from&&fe.to!==ne.to:!0):X=l.modelValue.filter(fe=>fe!==ne),X.length===0&&(X=null)}He(X,"remove",re)}function xe(re,X,ne){const fe=x.value.concat(w.value).map(Me=>Ye(Me,re,X)).filter(Me=>Me.from!==void 0?Me.from.dateHash!==null&&Me.to.dateHash!==null:Me.dateHash!==null),be=(l.multiple===!0?fe:fe[0])||null;oe(be),t("update:modelValue",be,ne)}function Re(){if(l.minimal!==!0)return v.h("div",{class:"q-date__header "+n.value},[v.h("div",{class:"relative-position"},[v.h(v.Transition,{name:"q-transition--fade"},()=>v.h("div",{key:"h-yr-"+Q.value,class:"q-date__header-subtitle q-date__header-link "+(T.value==="Years"?"q-date__header-link--active":"cursor-pointer"),tabindex:s.value,...i("vY",{onClick(){T.value="Years"},onKeyup(re){re.keyCode===13&&(T.value="Years")}})},[Q.value]))]),v.h("div",{class:"q-date__header-title relative-position flex no-wrap"},[v.h("div",{class:"relative-position col"},[v.h(v.Transition,{name:"q-transition--fade"},()=>v.h("div",{key:"h-sub"+R.value,class:"q-date__header-title-label q-date__header-link "+(T.value==="Calendar"?"q-date__header-link--active":"cursor-pointer"),tabindex:s.value,...i("vC",{onClick(){T.value="Calendar"},onKeyup(re){re.keyCode===13&&(T.value="Calendar")}})},[R.value]))]),l.todayBtn===!0?v.h(at,{class:"q-date__header-today self-start",icon:m.iconSet.datetime.today,"aria-label":m.lang.date.today,flat:!0,size:"sm",round:!0,tabindex:s.value,onClick:le}):null])])}function Oe({label:re,type:X,key:ne,dir:fe,goTo:be,boundaries:Me,cls:ve}){return[v.h("div",{class:"row items-center q-date__arrow"},[v.h(at,{round:!0,dense:!0,size:"sm",flat:!0,icon:j.value[0],"aria-label":X==="Years"?m.lang.date.prevYear:m.lang.date.prevMonth,tabindex:s.value,disable:Me.prev===!1,...i("go-#"+X,{onClick(){be(-1)}})})]),v.h("div",{class:"relative-position overflow-hidden flex flex-center"+ve},[v.h(v.Transition,{name:"q-transition--jump-"+fe},()=>v.h("div",{key:ne},[v.h(at,{flat:!0,dense:!0,noCaps:!0,label:re,tabindex:s.value,...i("view#"+X,{onClick:()=>{T.value=X}})})]))]),v.h("div",{class:"row items-center q-date__arrow"},[v.h(at,{round:!0,dense:!0,size:"sm",flat:!0,icon:j.value[1],"aria-label":X==="Years"?m.lang.date.nextYear:m.lang.date.nextMonth,tabindex:s.value,disable:Me.next===!1,...i("go+#"+X,{onClick(){be(1)}})})])]}const Ee={Calendar:()=>[v.h("div",{key:"calendar-view",class:"q-date__view q-date__calendar"},[v.h("div",{class:"q-date__navigation row items-center no-wrap"},Oe({label:d.value.months[C.value.month-1],type:"Months",key:C.value.month,dir:V.value,goTo:Fe,boundaries:G.value.month,cls:" col"}).concat(Oe({label:C.value.year,type:"Years",key:C.value.year,dir:P.value,goTo:ke,boundaries:G.value.year,cls:""}))),v.h("div",{class:"q-date__calendar-weekdays row items-center no-wrap"},F.value.map(re=>v.h("div",{class:"q-date__calendar-item"},[v.h("div",re)]))),v.h("div",{class:"q-date__calendar-days-container relative-position overflow-hidden"},[v.h(v.Transition,{name:"q-transition--slide-"+V.value},()=>v.h("div",{key:J.value,class:"q-date__calendar-days fit"},$.value.map(re=>v.h("div",{class:re.classes},[re.in===!0?v.h(at,{class:re.today===!0?"q-date__today":"",dense:!0,flat:re.flat,unelevated:re.unelevated,color:re.color,textColor:re.textColor,label:re.i,tabindex:s.value,...i("day#"+re.i,{onClick:()=>{Qe(re.i)},onMouseover:()=>{Ke(re.i)}})},re.event!==!1?()=>v.h("div",{class:"q-date__event bg-"+re.event}):null):v.h("div",""+re.i)]))))])])],Months(){const re=C.value.year===k.value.year,X=fe=>K.value!==null&&C.value.year===K.value.year&&K.value.month>fe||ee.value!==null&&C.value.year===ee.value.year&&ee.value.month<fe,ne=d.value.monthsShort.map((fe,be)=>{const Me=C.value.month===be+1;return v.h("div",{class:"q-date__months-item flex flex-center"},[v.h(at,{class:re===!0&&k.value.month===be+1?"q-date__today":null,flat:Me!==!0,label:fe,unelevated:Me,color:Me===!0?A.value:null,textColor:Me===!0?M.value:null,tabindex:s.value,disable:X(be+1),...i("month#"+be,{onClick:()=>{We(be+1)}})})])});return l.yearsInMonthView===!0&&ne.unshift(v.h("div",{class:"row no-wrap full-width"},[Oe({label:C.value.year,type:"Years",key:C.value.year,dir:P.value,goTo:ke,boundaries:G.value.year,cls:" col"})])),v.h("div",{key:"months-view",class:"q-date__view q-date__months flex flex-center"},ne)},Years(){const re=q.value,X=re+Qt,ne=[],fe=be=>K.value!==null&&K.value.year>be||ee.value!==null&&ee.value.year<be;for(let be=re;be<=X;be++){const Me=C.value.year===be;ne.push(v.h("div",{class:"q-date__years-item flex flex-center"},[v.h(at,{key:"yr"+be,class:k.value.year===be?"q-date__today":null,flat:!Me,label:be,dense:!0,unelevated:Me,color:Me===!0?A.value:null,textColor:Me===!0?M.value:null,tabindex:s.value,disable:fe(be),...i("yr#"+be,{onClick:()=>{De(be)}})})]))}return v.h("div",{class:"q-date__view q-date__years flex flex-center"},[v.h("div",{class:"col-auto"},[v.h(at,{round:!0,dense:!0,flat:!0,icon:j.value[0],"aria-label":m.lang.date.prevRangeYears(Qt),tabindex:s.value,disable:fe(re),...i("y-",{onClick:()=>{q.value-=Qt}})})]),v.h("div",{class:"q-date__years-content col self-stretch row items-center"},ne),v.h("div",{class:"col-auto"},[v.h(at,{round:!0,dense:!0,flat:!0,icon:j.value[1],"aria-label":m.lang.date.nextRangeYears(Qt),tabindex:s.value,disable:fe(X),...i("y+",{onClick:()=>{q.value+=Qt}})})])])}};function Qe(re){const X={...C.value,day:re};if(l.range===!1){Ve(X,J.value);return}if(W.value===null){const ne=$.value.find(be=>be.fill!==!0&&be.i===re);if(l.noUnset!==!0&&ne.range!==void 0){me({target:X,from:ne.range.from,to:ne.range.to});return}if(ne.selected===!0){me(X);return}const fe=$t(X);W.value={init:X,initHash:fe,final:X,finalHash:fe},t("rangeStart",Ge(X))}else{const ne=W.value.initHash,fe=$t(X),be=ne<=fe?{from:W.value.init,to:X}:{from:X,to:W.value.init};W.value=null,st(ne===fe?X:{target:X,...be}),t("rangeEnd",{from:Ge(be.from),to:Ge(be.to)})}}function Ke(re){if(W.value!==null){const X={...C.value,day:re};Object.assign(W.value,{final:X,finalHash:$t(X)})}}return Object.assign(b,{setToday:le,setView:ge,offsetCalendar:Ce,setCalendarTo:Ae,setEditingRange:Te}),()=>{const re=[v.h("div",{class:"q-date__content col relative-position"},[v.h(v.Transition,{name:"q-transition--fade"},Ee[T.value])])],X=bt(B.default);return X!==void 0&&re.push(v.h("div",{class:"q-date__actions"},X)),l.name!==void 0&&l.disable!==!0&&o(re,"push"),v.h("div",{class:L.value,...ie.value},[Re(),v.h("div",{ref:f,class:"q-date__main col column",tabindex:-1},re)])}}}),ls=$e({name:"QPopupProxy",props:{...Ra,breakpoint:{type:[String,Number],default:450}},emits:["show","hide"],setup(l,{slots:B,emit:t,attrs:b}){const{proxy:m}=v.getCurrentInstance(),{$q:c}=m,i=v.ref(!1),s=v.ref(null),n=v.computed(()=>parseInt(l.breakpoint,10)),{canShow:e}=qi({showing:i});function r(){return c.screen.width<n.value||c.screen.height<n.value?"dialog":"menu"}const u=v.ref(r()),a=v.computed(()=>u.value==="menu"?{maxHeight:"99vh"}:{});v.watch(()=>r(),h=>{i.value!==!0&&(u.value=h)});function o(h){i.value=!0,t("show",h)}function f(h){i.value=!1,u.value=r(),t("hide",h)}return Object.assign(m,{show(h){e(h)===!0&&s.value.show(h)},hide(h){s.value.hide(h)},toggle(h){s.value.toggle(h)}}),Lt(m,"currentComponent",()=>({type:u.value,ref:s.value})),()=>{const h={ref:s,...a.value,...b,onShow:o,onHide:f};let d;return u.value==="dialog"?d=en:(d=Zr,Object.assign(h,{target:l.target,contextMenu:l.contextMenu,noParentEvent:!0,separateClosePopup:!0})),v.h(d,h,B.default)}}}),ea={date:"####/##/##",datetime:"####/##/## ##:##",time:"##:##",fulltime:"##:##:##",phone:"(###) ### - ####",card:"#### #### #### ####"},jn={"#":{pattern:"[\\d]",negate:"[^\\d]"},S:{pattern:"[a-zA-Z]",negate:"[^a-zA-Z]"},N:{pattern:"[0-9a-zA-Z]",negate:"[^0-9a-zA-Z]"},A:{pattern:"[a-zA-Z]",negate:"[^a-zA-Z]",transform:l=>l.toLocaleUpperCase()},a:{pattern:"[a-zA-Z]",negate:"[^a-zA-Z]",transform:l=>l.toLocaleLowerCase()},X:{pattern:"[0-9a-zA-Z]",negate:"[^0-9a-zA-Z]",transform:l=>l.toLocaleUpperCase()},x:{pattern:"[0-9a-zA-Z]",negate:"[^0-9a-zA-Z]",transform:l=>l.toLocaleLowerCase()}},us=Object.keys(jn);us.forEach(l=>{jn[l].regex=new RegExp(jn[l].pattern)});const xc=new RegExp("\\\\([^.*+?^${}()|([\\]])|([.*+?^${}()|[\\]])|(["+us.join("")+"])|(.)","g"),ta=/[.*+?^${}()|[\]\\]/g,Ct="",Sc={mask:String,reverseFillMask:Boolean,fillMask:[Boolean,String],unmaskedValue:Boolean};function kc(l,B,t,b){let m,c,i,s,n,e;const r=v.ref(null),u=v.ref(o());function a(){return l.autogrow===!0||["textarea","text","search","url","tel","password"].includes(l.type)}v.watch(()=>l.type+l.autogrow,h),v.watch(()=>l.mask,N=>{if(N!==void 0)d(u.value,!0);else{const q=V(u.value);h(),l.modelValue!==q&&B("update:modelValue",q)}}),v.watch(()=>l.fillMask+l.reverseFillMask,()=>{r.value===!0&&d(u.value,!0)}),v.watch(()=>l.unmaskedValue,()=>{r.value===!0&&d(u.value)});function o(){if(h(),r.value===!0){const N=T(V(l.modelValue));return l.fillMask!==!1?P(N):N}return l.modelValue}function f(N){if(N<m.length)return m.slice(-N);let q="",W=m;const L=W.indexOf(Ct);if(L!==-1){for(let A=N-W.length;A>0;A--)q+=Ct;W=W.slice(0,L)+q+W.slice(L)}return W}function h(){if(r.value=l.mask!==void 0&&l.mask.length!==0&&a(),r.value===!1){s=void 0,m="",c="";return}const N=ea[l.mask]===void 0?l.mask:ea[l.mask],q=typeof l.fillMask=="string"&&l.fillMask.length!==0?l.fillMask.slice(0,1):"_",W=q.replace(ta,"\\$&"),L=[],A=[],M=[];let _=l.reverseFillMask===!0,y="",x="";N.replace(xc,(O,R,z,U,Q)=>{if(U!==void 0){const j=jn[U];M.push(j),x=j.negate,_===!0&&(A.push("(?:"+x+"+)?("+j.pattern+"+)?(?:"+x+"+)?("+j.pattern+"+)?"),_=!1),A.push("(?:"+x+"+)?("+j.pattern+")?")}else if(z!==void 0)y="\\"+(z==="\\"?"":z),M.push(z),L.push("([^"+y+"]+)?"+y+"?");else{const j=R!==void 0?R:Q;y=j==="\\"?"\\\\\\\\":j.replace(ta,"\\\\$&"),M.push(j),L.push("([^"+y+"]+)?"+y+"?")}});const w=new RegExp("^"+L.join("")+"("+(y===""?".":"[^"+y+"]")+"+)?"+(y===""?"":"["+y+"]*")+"$"),S=A.length-1,E=A.map((O,R)=>R===0&&l.reverseFillMask===!0?new RegExp("^"+W+"*"+O):R===S?new RegExp("^"+O+"("+(x===""?".":x)+"+)?"+(l.reverseFillMask===!0?"$":W+"*")):new RegExp("^"+O));i=M,s=O=>{const R=w.exec(l.reverseFillMask===!0?O:O.slice(0,M.length+1));R!==null&&(O=R.slice(1).join(""));const z=[],U=E.length;for(let Q=0,j=O;Q<U;Q++){const Y=E[Q].exec(j);if(Y===null)break;j=j.slice(Y.shift().length),z.push(...Y)}return z.length!==0?z.join(""):O},m=M.map(O=>typeof O=="string"?O:Ct).join(""),c=m.split(Ct).join(q)}function d(N,q,W){const L=b.value,A=L.selectionEnd,M=L.value.length-A,_=V(N);q===!0&&h();const y=T(_),x=l.fillMask!==!1?P(y):y,w=u.value!==x;L.value!==x&&(L.value=x),w===!0&&(u.value=x),document.activeElement===L&&v.nextTick(()=>{if(x===c){const E=l.reverseFillMask===!0?c.length:0;L.setSelectionRange(E,E,"forward");return}if(W==="insertFromPaste"&&l.reverseFillMask!==!0){const E=L.selectionEnd;let O=A-1;for(let R=n;R<=O&&R<E;R++)m[R]!==Ct&&O++;p.right(L,O);return}if(["deleteContentBackward","deleteContentForward"].indexOf(W)!==-1){const E=l.reverseFillMask===!0?A===0?x.length>y.length?1:0:Math.max(0,x.length-(x===c?0:Math.min(y.length,M)+1))+1:A;L.setSelectionRange(E,E,"forward");return}if(l.reverseFillMask===!0)if(w===!0){const E=Math.max(0,x.length-(x===c?0:Math.min(y.length,M+1)));E===1&&A===1?L.setSelectionRange(E,E,"forward"):p.rightReverse(L,E)}else{const E=x.length-M;L.setSelectionRange(E,E,"backward")}else if(w===!0){const E=Math.max(0,m.indexOf(Ct),Math.min(y.length,A)-1);p.right(L,E)}else{const E=A-1;p.right(L,E)}});const S=l.unmaskedValue===!0?V(x):x;String(l.modelValue)!==S&&(l.modelValue!==null||S!=="")&&t(S,!0)}function g(N,q,W){const L=T(V(N.value));q=Math.max(0,m.indexOf(Ct),Math.min(L.length,q)),n=q,N.setSelectionRange(q,W,"forward")}const p={left(N,q){const W=m.slice(q-1).indexOf(Ct)===-1;let L=Math.max(0,q-1);for(;L>=0;L--)if(m[L]===Ct){q=L,W===!0&&q++;break}if(L<0&&m[q]!==void 0&&m[q]!==Ct)return p.right(N,0);q>=0&&N.setSelectionRange(q,q,"backward")},right(N,q){const W=N.value.length;let L=Math.min(W,q+1);for(;L<=W;L++)if(m[L]===Ct){q=L;break}else m[L-1]===Ct&&(q=L);if(L>W&&m[q-1]!==void 0&&m[q-1]!==Ct)return p.left(N,W);N.setSelectionRange(q,q,"forward")},leftReverse(N,q){const W=f(N.value.length);let L=Math.max(0,q-1);for(;L>=0;L--)if(W[L-1]===Ct){q=L;break}else if(W[L]===Ct&&(q=L,L===0))break;if(L<0&&W[q]!==void 0&&W[q]!==Ct)return p.rightReverse(N,0);q>=0&&N.setSelectionRange(q,q,"backward")},rightReverse(N,q){const W=N.value.length,L=f(W),A=L.slice(0,q+1).indexOf(Ct)===-1;let M=Math.min(W,q+1);for(;M<=W;M++)if(L[M-1]===Ct){q=M,q>0&&A===!0&&q--;break}if(M>W&&L[q-1]!==void 0&&L[q-1]!==Ct)return p.leftReverse(N,W);N.setSelectionRange(q,q,"forward")}};function k(N){B("click",N),e=void 0}function C(N){if(B("keydown",N),Di(N)===!0||N.altKey===!0)return;const q=b.value,W=q.selectionStart,L=q.selectionEnd;if(N.shiftKey||(e=void 0),N.keyCode===37||N.keyCode===39){N.shiftKey&&e===void 0&&(e=q.selectionDirection==="forward"?W:L);const A=p[(N.keyCode===39?"right":"left")+(l.reverseFillMask===!0?"Reverse":"")];if(N.preventDefault(),A(q,e===W?L:W),N.shiftKey){const M=q.selectionStart;q.setSelectionRange(Math.min(e,M),Math.max(e,M),"forward")}}else N.keyCode===8&&l.reverseFillMask!==!0&&W===L?(p.left(q,W),q.setSelectionRange(q.selectionStart,L,"backward")):N.keyCode===46&&l.reverseFillMask===!0&&W===L&&(p.rightReverse(q,L),q.setSelectionRange(W,q.selectionEnd,"forward"))}function T(N){if(N==null||N==="")return"";if(l.reverseFillMask===!0)return D(N);const q=i;let W=0,L="";for(let A=0;A<q.length;A++){const M=N[W],_=q[A];if(typeof _=="string")L+=_;else if(M!==void 0&&_.regex.test(M))L+=_.transform!==void 0?_.transform(M):M,W++;else return L}return L}function D(N){const q=i,W=m.indexOf(Ct);let L=N.length-1,A="";for(let M=q.length-1;M>=0&&L!==-1;M--){const _=q[M];let y=N[L];if(typeof _=="string")A=_+A;else if(y!==void 0&&_.regex.test(y))do A=(_.transform!==void 0?_.transform(y):y)+A,L--,y=N[L];while(W===M&&y!==void 0&&_.regex.test(y));else return A}return A}function V(N){return typeof N!="string"||s===void 0?typeof N=="number"?s(""+N):N:s(N)}function P(N){return c.length-N.length<=0?N:l.reverseFillMask===!0&&N.length!==0?c.slice(0,-N.length)+N:N+c.slice(N.length)}return{innerValue:u,hasMask:r,moveCursorForPaste:g,updateMaskValue:d,onMaskedKeydown:C,onMaskedClick:k}}function _c(l,B){function t(){const b=l.modelValue;try{const m="DataTransfer"in window?new DataTransfer:"ClipboardEvent"in window?new ClipboardEvent("").clipboardData:void 0;return Object(b)===b&&("length"in b?Array.from(b):[b]).forEach(c=>{m.items.add(c)}),{files:m.files}}catch{return{files:void 0}}}return v.computed(()=>{if(l.type==="file")return t()})}const Gr=$e({name:"QInput",inheritAttrs:!1,props:{...Un,...Sc,...Vn,modelValue:[String,Number,FileList],shadowText:String,type:{type:String,default:"text"},debounce:[String,Number],autogrow:Boolean,inputClass:[Array,String,Object],inputStyle:[Array,String,Object]},emits:[...Gi,"paste","change","keydown","click","animationend"],setup(l,{emit:B,attrs:t}){const{proxy:b}=v.getCurrentInstance(),{$q:m}=b,c={};let i=NaN,s,n,e=null,r;const u=v.ref(null),a=wa(l),{innerValue:o,hasMask:f,moveCursorForPaste:h,updateMaskValue:d,onMaskedKeydown:g,onMaskedClick:p}=kc(l,B,y,u),k=_c(l),C=v.computed(()=>Xr(o.value)),T=Qa(M),D=Ji({changeEvent:!0}),V=v.computed(()=>l.type==="textarea"||l.autogrow===!0),P=v.computed(()=>V.value===!0||["text","search","url","tel","password"].includes(l.type)),N=v.computed(()=>{const R={...D.splitAttrs.listeners.value,onInput:M,onPaste:A,onChange:w,onBlur:S,onFocus:Dt};return R.onCompositionstart=R.onCompositionupdate=R.onCompositionend=T,f.value===!0&&(R.onKeydown=g,R.onClick=p),l.autogrow===!0&&(R.onAnimationend=_),R}),q=v.computed(()=>{const R={tabindex:0,"data-autofocus":l.autofocus===!0||void 0,rows:l.type==="textarea"?6:void 0,"aria-label":l.label,name:a.value,...D.splitAttrs.attributes.value,id:D.targetUid.value,maxlength:l.maxlength,disabled:l.disable===!0,readonly:l.readonly===!0};return V.value===!1&&(R.type=l.type),l.autogrow===!0&&(R.rows=1),R});v.watch(()=>l.type,()=>{u.value&&(u.value.value=l.modelValue)}),v.watch(()=>l.modelValue,R=>{if(f.value===!0){if(n===!0&&(n=!1,String(R)===i))return;d(R)}else o.value!==R&&(o.value=R,l.type==="number"&&c.hasOwnProperty("value")===!0&&(s===!0?s=!1:delete c.value));l.autogrow===!0&&v.nextTick(x)}),v.watch(()=>l.autogrow,R=>{R===!0?v.nextTick(x):u.value!==null&&t.rows>0&&(u.value.style.height="auto")}),v.watch(()=>l.dense,()=>{l.autogrow===!0&&v.nextTick(x)});function W(){Jr(()=>{const R=document.activeElement;u.value!==null&&u.value!==R&&(R===null||R.id!==D.targetUid.value)&&u.value.focus({preventScroll:!0})})}function L(){u.value?.select()}function A(R){if(f.value===!0&&l.reverseFillMask!==!0){const z=R.target;h(z,z.selectionStart,z.selectionEnd)}B("paste",R)}function M(R){if(!R||!R.target)return;if(l.type==="file"){B("update:modelValue",R.target.files);return}const z=R.target.value;if(R.target.qComposing===!0){c.value=z;return}if(f.value===!0)d(z,!1,R.inputType);else if(y(z),P.value===!0&&R.target===document.activeElement){const{selectionStart:U,selectionEnd:Q}=R.target;U!==void 0&&Q!==void 0&&v.nextTick(()=>{R.target===document.activeElement&&z.indexOf(R.target.value)===0&&R.target.setSelectionRange(U,Q)})}l.autogrow===!0&&x()}function _(R){B("animationend",R),x()}function y(R,z){r=()=>{e=null,l.type!=="number"&&c.hasOwnProperty("value")===!0&&delete c.value,l.modelValue!==R&&i!==R&&(i=R,z===!0&&(n=!0),B("update:modelValue",R),v.nextTick(()=>{i===R&&(i=NaN)})),r=void 0},l.type==="number"&&(s=!0,c.value=R),l.debounce!==void 0?(e!==null&&clearTimeout(e),c.value=R,e=setTimeout(r,l.debounce)):r()}function x(){requestAnimationFrame(()=>{const R=u.value;if(R!==null){const z=R.parentNode.style,{scrollTop:U}=R,{overflowY:Q,maxHeight:j}=m.platform.is.firefox===!0?{}:window.getComputedStyle(R),Y=Q!==void 0&&Q!=="scroll";Y===!0&&(R.style.overflowY="hidden"),z.marginBottom=R.scrollHeight-1+"px",R.style.height="1px",R.style.height=R.scrollHeight+"px",Y===!0&&(R.style.overflowY=parseInt(j,10)<R.scrollHeight?"auto":"hidden"),z.marginBottom="",R.scrollTop=U}})}function w(R){T(R),e!==null&&(clearTimeout(e),e=null),r?.(),B("change",R.target.value)}function S(R){R!==void 0&&Dt(R),e!==null&&(clearTimeout(e),e=null),r?.(),s=!1,n=!1,delete c.value,l.type!=="file"&&setTimeout(()=>{u.value!==null&&(u.value.value=o.value!==void 0?o.value:"")})}function E(){return c.hasOwnProperty("value")===!0?c.value:o.value!==void 0?o.value:""}v.onBeforeUnmount(()=>{S()}),v.onMounted(()=>{l.autogrow===!0&&x()}),Object.assign(D,{innerValue:o,fieldClass:v.computed(()=>`q-${V.value===!0?"textarea":"input"}`+(l.autogrow===!0?" q-textarea--autogrow":"")),hasShadow:v.computed(()=>l.type!=="file"&&typeof l.shadowText=="string"&&l.shadowText.length!==0),inputRef:u,emitValue:y,hasValue:C,floatingLabel:v.computed(()=>C.value===!0&&(l.type!=="number"||isNaN(o.value)===!1)||Xr(l.displayValue)),getControl:()=>v.h(V.value===!0?"textarea":"input",{ref:u,class:["q-field__native q-placeholder",l.inputClass],style:l.inputStyle,...q.value,...N.value,...l.type!=="file"?{value:E()}:k.value}),getShadowControl:()=>v.h("div",{class:"q-field__native q-field__shadow absolute-bottom no-pointer-events"+(V.value===!0?"":" text-no-wrap")},[v.h("span",{class:"invisible"},E()),v.h("span",l.shadowText)])});const O=Zi(D);return Object.assign(b,{focus:W,select:L,getNativeElement:()=>u.value}),Lt(b,"nativeEl",()=>u.value),O}});function Cc(l){return{entity:l.entity,dataCy:l.dataCy,defaultLabel:l.defaultLabel,routeName:l.routeName,shouldRender:l.customShouldRender||(({store:B})=>l.storeField?!!B[l.storeField]:!0),getLabel:l.getLabel||(l.labelField?({store:B})=>l.storeField&&B[l.storeField]?.[l.labelField]||l.defaultLabel:void 0),getColor:l.customGetColor||(({store:B})=>l.storeField&&B[l.storeField]?"primary":"dark"),getRouteParams:l.routeParamKey&&l.routeParamField?({store:B})=>({[l.routeParamKey]:l.storeField&&B[l.storeField]?.[l.routeParamField]}):void 0,clearActions:[...l.clearMethods?.map(B=>({store:t})=>t[B]?.())||[],...l.navActions?.map(B=>({navStore:t})=>B(t))||[]]}}const cs=/^\d{2}-\d{2}-\d{4}$/;function Ac(l){const B=l.getTimezoneOffset()*6e4;return new Date(l.getTime()+B)}function Ur(l){const B=/^\d{4}-\d{2}-\d{2}$/,t=/^\d{2}-\d{2}-\d{4}$/;if(B.test(l))return l;if(t.test(l)){const b=l.split("-");return`${b[2]}-${b[1]}-${b[0]}`}return console.warn("'Invalid date format. Expected DD-MM-YYYY' or 'YYYY-MM-DD' but got: "+l),""}function oo(l,B,t,b=[]){const m=typeof l=="string"?new Date(Ur(l)):new Date(l);if(Number.isNaN(m.getTime()))return!1;if(B){const s=typeof B=="string"?new Date(Ur(B)):new Date(B);if(m<s)return!1}if(t){const s=typeof t=="string"?new Date(Ur(t)):new Date(t);if(m>s)return!1}return b.some(s=>{if(typeof s=="string"){const n=new Date(Ur(s));return m.getFullYear()===n.getFullYear()&&m.getMonth()===n.getMonth()&&m.getDate()===n.getDate()}else{if(s instanceof Date)return m.getFullYear()===s.getFullYear()&&m.getMonth()===s.getMonth()&&m.getDate()===s.getDate();{const n=new Date(s.start_date),e=new Date(s.end_date);return m>=n&&m<=e}}})?!1:!b.some(s=>{if(typeof s=="object"&&!(s instanceof Date)&&s.start_date&&s.end_date){const n=new Date(s.start_date),e=new Date(s.end_date);if(n.getTime()===e.getTime())return m.getTime()===n.getTime()||m.getTime()===e.getTime()}return!1})}const Kt={validateAndUpdate(l,B,t){return cs.test(B)?{...l,[t?"from":"to"]:B}:l},isEndDateValid(l,B,t=!1){if(!l||!B)return!0;try{const[b,m,c]=l.split("-"),[i,s,n]=B.split("-"),e=new Date(Number(c),Number(m)-1,Number(b)),r=new Date(Number(n),Number(s)-1,Number(i));return t?r>=e:r>e}catch{return!1}},handlePickerUpdate(l){return l===null?{from:"",to:""}:typeof l=="string"?{from:l,to:l}:l},reset(){return{from:"",to:""}},handleInput(l,B){typeof l=="string"&&B(l)}},ds={days:["Dimanche","Lundi","Mardi","Mercredi","Jeudi","Vendredi","Samedi"],daysShort:["Dim","Lun","Mar","Mer","Jeu","Ven","Sam"],months:["Janvier","Février","Mars","Avril","Mai","Juin","Juillet","Août","Septembre","Octobre","Novembre","Décembre"],monthsShort:["Janv","Févr","Mars","Avr","Mai","Juin","Juil","Août","Sept","Oct","Nov","Dec"],firstDayOfWeek:1,format24h:!0,pluralDay:"jours"};function Ec(l){if(!l||!/^\d{2}-\d{2}-\d{4}$/.test(l))return new Date(Number.NaN);const[B,t,b]=l.split("-").map(Number);return new Date(b,t-1,B)}function Ut(l){if(!l)return"";const B=new Date(l),t=B.getFullYear(),b=String(B.getMonth()+1).padStart(2,"0");return`${String(B.getDate()).padStart(2,"0")}-${b}-${t}`}function Dn(l,B){return new Date(l,B-1,1)}function Pn(l,B){return new Date(l,B,0)}function fs(l=new Date){const B=l.getFullYear(),t=l.getMonth()+1;let b=t-3,m=B;b<=0&&(b+=12,m-=1);const c=Dn(m,b);let i=t-1,s=B;i<=0&&(i+=12,s-=1);const n=Pn(s,i);return{from:Ut(c),to:Ut(n)}}const hs={currentMonth:(l=new Date)=>{const B=l.getFullYear(),t=l.getMonth()+1;return{from:Ut(Dn(B,t)),to:Ut(Pn(B,t))}},previousMonth:(l=new Date)=>{const B=l.getFullYear();let b=l.getMonth()+1-1,m=B;return b===0&&(b=12,m=B-1),{from:Ut(Dn(m,b)),to:Ut(Pn(m,b))}},last3Months:fs,currentYear:(l=new Date)=>{const B=l.getFullYear();return{from:Ut(new Date(B,0,1)),to:Ut(new Date(B,11,31))}},previousYear:(l=new Date)=>{const B=l.getFullYear()-1;return{from:Ut(new Date(B,0,1)),to:Ut(new Date(B,11,31))}}};function Mc(l){if(!l)return{date:"",time:""};try{const B=new Date(l);if(Number.isNaN(B.getTime()))return console.error("Invalid date:",l),{date:"",time:""};const b=new Intl.DateTimeFormat("fr-FR",{timeZone:"Europe/Paris",year:"numeric",month:"2-digit",day:"2-digit",hour:"2-digit",minute:"2-digit",second:"2-digit",hour12:!1}).formatToParts(B),m=f=>b.find(h=>h.type===f)?.value||"",c=m("day"),i=m("month"),s=m("year"),n=m("hour"),e=m("minute"),r=m("second"),u=`${c}-${i}-${s}`,o=l.includes("T")&&l.split("T")[1]?.split(":").length>=3&&l.split("T")[1].split(":")[2]!=="00"?`${n}:${e}:${r}`:`${n}:${e}`;return{date:u,time:o}}catch(B){return console.error("Error parsing ISO datetime:",B,"Input:",l),{date:"",time:""}}}function Tc(l){if(!l)return"";if(new RegExp(/^\d{4}-\d{2}-\d{2}T\d{2}:\d{2}:\d{2}/).exec(l))return l;if(new RegExp(/^\d{4}-\d{2}-\d{2}$/).exec(l))return`${l}T00:00:00Z`;if(new RegExp(/^\d{2}-\d{2}-\d{4}$/).exec(l)){const[t,b,m]=l.split("-");return`${m}-${b}-${t}T00:00:00Z`}if(new RegExp(/^\d{2}\/\d{2}\/\d{4}$/).exec(l)){const[t,b,m]=l.split("/");return`${m}-${b}-${t}T00:00:00Z`}if(new RegExp(/^\d{2}\.\d{2}\.\d{4}$/).exec(l)){const[t,b,m]=l.split(".");return`${m}-${b}-${t}T00:00:00Z`}const B=new Date(l);return Number.isNaN(B.getTime())?l:B.toISOString()}const Rc={class:"columns justify-end"},Bc=v.defineComponent({__name:"DatePicker",props:{label:{default:"Date"},date:{default:""},required:{type:Boolean,default:!1},minDate:{default:void 0},maxDate:{default:void 0},datesDisabled:{default:()=>[]},requiredErrorMessage:{default:"Ce champ est obligatoire !"},invalidDateErrorMessage:{default:"Date invalide!"},disabled:{type:Boolean,default:!1},outlined:{type:Boolean,default:!1},placeholder:{default:void 0},closeLabel:{default:"Close"},rules:{default:()=>[]}},emits:["update:modelValue","update:date"],setup(l,{emit:B}){const t=l,b=B,m=v.useAttrs(),c=v.ref(),i=v.ref(t.date),s=v.ref(null),n=v.computed(()=>i.value),e=C=>{if(!C||C.length!==10)return!1;const T=/^(\d{2})-(\d{2})-(\d{4})$/,D=C.match(T);if(!D)return!1;const V=Number.parseInt(D[1],10),P=Number.parseInt(D[2],10),N=Number.parseInt(D[3],10);if(P<1||P>12||V<1||V>31)return!1;const q=new Date(N,P-1,V);return q.getFullYear()===N&&q.getMonth()===P-1&&q.getDate()===V},r=C=>{if(!C)return null;if(C.length!==10)return"Le format doit être JJ-MM-AAAA";const T=/^(\d{2})-(\d{2})-(\d{4})$/,D=C.match(T);if(!D)return"Format invalide. Utilisez JJ-MM-AAAA";const V=Number.parseInt(D[1],10),P=Number.parseInt(D[2],10),N=Number.parseInt(D[3],10),q=u(P);if(q)return q;const W=a(V,P,N);return W||(f(V,P,N)?null:"Date inexistante")},u=C=>C<1||C>12?"Le mois doit être entre 01 et 12":null,a=(C,T,D)=>C<1||C>31?"Le jour doit être entre 01 et 31":[4,6,9,11].includes(T)&&C>30?`Le mois ${T} n'a que 30 jours`:T===2?o(C,D):null,o=(C,T)=>{const D=T%4===0&&T%100!==0||T%400===0;return D&&C>29?"Février a maximum 29 jours pour les années bissextiles":!D&&C>28?"Février a maximum 28 jours":null},f=(C,T,D)=>{const V=new Date(D,T-1,C);return V.getFullYear()===D&&V.getMonth()===T-1&&V.getDate()===C},h=()=>{n.value?s.value=r(n.value):s.value=null},d=v.computed(()=>C=>{const T=C.replaceAll("/","-");return oo(T,t.minDate,t.maxDate,t.datesDisabled)}),g=C=>{e(C)&&(i.value=C,s.value=null,b("update:date",C),b("update:modelValue",C),setTimeout(()=>{c.value?.hide?.()},0))},p=C=>{if(typeof C=="string")if(i.value=C,b("update:date",C),b("update:modelValue",C),C.length===10){const T=r(C);s.value=T}else C===""&&(s.value=null);else C===null&&(i.value="",s.value=null,b("update:date",""),b("update:modelValue",""))},k=v.computed(()=>{const C=[...t.rules];return t.required&&C.push(T=>!!T||t.requiredErrorMessage),C.push(T=>T?e(T)||s.value||t.invalidDateErrorMessage:!0),C});return v.watch(()=>[t.date],([C,T])=>{const D=T??C;D&&D!==i.value&&(i.value=D,h())}),(C,T)=>(v.openBlock(),v.createElementBlock("div",Rc,[v.createVNode(Gr,v.mergeProps(v.unref(m),{class:"full-width","model-value":n.value,mask:"##-##-####",dense:"",label:C.label,"data-cy":"datePick",rules:k.value,disable:C.disabled,required:C.required,outlined:C.outlined,placeholder:C.placeholder,"onUpdate:modelValue":p,onBlur:h}),{append:v.withCtx(()=>[v.createVNode(dt,{name:"event",class:"cursor-pointer","data-testid":"calendar-icon-picker"},{default:v.withCtx(()=>[v.createVNode(ls,{ref_key:"popupRef",ref:c,cover:"","transition-show":"scale","transition-hide":"scale","no-focus":""},{default:v.withCtx(()=>[v.createVNode(ss,{mask:"DD-MM-YYYY","model-value":i.value,options:d.value,disable:C.disabled,"onUpdate:modelValue":g},null,8,["model-value","options","disable"])]),_:1},512)]),_:1})]),_:1},16,["model-value","label","rules","disable","required","outlined","placeholder"])]))}}),Ic={class:"date-range-wrapper"},Oc={class:"date-range-flex"},Fc={key:0,class:"actions-group"},jc={class:"date-range-popup"},Dc={key:0,class:"presets-section"},Pc={class:"presets-grid"},Nc={class:"presets-row"},Lc={class:"presets-row"},Vc={class:"calendar-container"},qc={class:"popup-actions"},zc={key:0,class:"hint"},Uc={class:"text-warning text-caption q-mb-none"},Wc=v.defineComponent({__name:"DateRange",props:{allowSameDate:{type:Boolean,default:!0},from:{default:""},to:{default:""},labelStart:{default:"De"},labelEnd:{default:"À"},startDateHint:{default:""},resetLabel:{default:"Reinitialiser"},closeLabel:{default:"Fermer"},locale:{default:()=>ds},required:{type:Boolean,default:!1},requiredErrorMessage:{default:"Ce champ est obligatoire !"},invalidDateErrorMessage:{default:"Date invalide!"},rules:{default:()=>[]},minDate:{default:void 0},maxDate:{default:void 0},datesDisabled:{default:()=>[]},highlightEvents:{default:()=>[]},disabled:{type:Boolean,default:!1},idCy:{default:"dateRange"},isIconCalendar:{type:Boolean},resetPosition:{},hideActions:{type:Boolean,default:!1},hideShortcuts:{type:Boolean,default:!1},shortcuts:{default:()=>[{id:"currentMonth",label:"Mois courant"},{id:"previousMonth",label:"Mois précédent"},{id:"last3Months",label:"3 derniers mois"},{id:"currentYear",label:"Année courante"},{id:"previousYear",label:"Année précédente"}]}},emits:["update:dateRange","clear"],setup(l,{expose:B,emit:t}){const b=l,m=t,c=v.ref({from:b.from,to:b.to}),i=v.ref(null),s=v.computed(()=>`from-date-${b.idCy}`),n=v.computed(()=>`to-date-${b.idCy}`),e=v.ref(null),r=v.computed(()=>b.shortcuts.map(R=>({...R,getRange:hs[R.id]}))),u=v.computed(()=>r.value.slice(0,3)),a=v.computed(()=>r.value.slice(3)),o=()=>{c.value=Kt.reset(),D.value=null,V.value=null,e.value=null,w(),m("clear")},f=()=>{i.value&&i.value.hide()},h=()=>{if(e.value=null,!(!c.value.from||!c.value.to))for(const R of r.value)try{const z=R.getRange(new Date);if(z.from===c.value.from&&z.to===c.value.to){e.value=R.id;break}}catch(z){console.error("Error checking preset:",z)}},d=R=>{if(!R||R.length!==10)return!1;const z=/^(\d{2})-(\d{2})-(\d{4})$/,U=R.match(z);if(!U)return!1;const Q=Number.parseInt(U[1],10),j=Number.parseInt(U[2],10),Y=Number.parseInt(U[3],10);if(j<1||j>12||Q<1||Q>31)return!1;const F=new Date(Y,j-1,Q);return F.getFullYear()===Y&&F.getMonth()===j-1&&F.getDate()===Q},g=R=>{if(!R)return null;if(R.length!==10)return"Le format doit être JJ-MM-AAAA";const z=/^(\d{2})-(\d{2})-(\d{4})$/,U=R.match(z);if(!U)return"Format invalide. Utilisez JJ-MM-AAAA";const Q=Number.parseInt(U[1],10),j=Number.parseInt(U[2],10),Y=Number.parseInt(U[3],10),F=p(j);if(F)return F;const I=k(Q,j,Y);return I||(T(Q,j,Y)?null:"Date inexistante")},p=R=>R<1||R>12?"Le mois doit être entre 01 et 12":null,k=(R,z,U)=>R<1||R>31?"Le jour doit être entre 01 et 31":[4,6,9,11].includes(z)&&R>30?`Le mois ${z} n'a que 30 jours`:z===2?C(R,U):null,C=(R,z)=>{const U=z%4===0&&z%100!==0||z%400===0;return U&&R>29?"Février a maximum 29 jours pour les années bissextiles":!U&&R>28?"Février a maximum 28 jours":null},T=(R,z,U)=>{const Q=new Date(U,z-1,R);return Q.getFullYear()===U&&Q.getMonth()===z-1&&Q.getDate()===R},D=v.ref(null),V=v.ref(null),P=()=>{c.value.from?D.value=g(c.value.from):D.value=null},N=()=>{c.value.to?V.value=g(c.value.to):V.value=null},q=v.computed(()=>R=>{const z=R.replaceAll("/","-");return oo(z,b.minDate,b.maxDate,b.datesDisabled)});let W=!1;const L=()=>{W=!0,c.value.from="",D.value=null,e.value=null,w(),setTimeout(()=>{W=!1},100)},A=()=>{W=!0,c.value.to="",V.value=null,e.value=null,w(),setTimeout(()=>{W=!1},100)},M=R=>{if(R===null||R===""){const z=c.value.from;c.value.from="",D.value=null,e.value=null,w(),!c.value.to&&z&&!c.value.from&&m("clear");return}Kt.handleInput(R,z=>{const U=c.value.from;if(z&&z.length===10){const Q=g(z);if(D.value=Q,Q){c.value.from=z,w();return}}else D.value=null;c.value=Kt.validateAndUpdate(c.value,z,!0),h(),w(),!z&&!c.value.to&&U&&m("clear")})},_=R=>{if(R===null||R===""){const z=c.value.to;c.value.to="",V.value=null,e.value=null,w(),!c.value.from&&z&&!c.value.to&&m("clear");return}Kt.handleInput(R,z=>{const U=c.value.to;if(z&&z.length===10){const Q=g(z);if(V.value=Q,Q){c.value.to=z,w();return}}else V.value=null;c.value=Kt.validateAndUpdate(c.value,z,!1),h(),w(),!z&&!c.value.from&&U&&m("clear")})},y=()=>{setTimeout(()=>{c.value.from&&c.value.from.length===10?D.value=g(c.value.from):D.value=null,c.value.to&&c.value.to.length===10?V.value=g(c.value.to):V.value=null,!b.allowSameDate&&c.value.from&&c.value.to&&c.value.from===c.value.to&&(c.value.to=""),h()},10)},x=R=>{const z=Kt.handlePickerUpdate(R);(z.from!==c.value.from||z.to!==c.value.to)&&(e.value=null),c.value=z,w(),h()},w=()=>{m("update:dateRange",{...c.value})},S=v.computed(()=>[...b.required?[R=>!!R||b.requiredErrorMessage]:[],...b.rules,R=>{if(R&&!d(R))return D.value||b.invalidDateErrorMessage||"Date invalide!";const z=c.value.to;if(!R||!z)return!0;const U=Kt.isEndDateValid(R,z,b.allowSameDate);return b.allowSameDate?U||"La date de début doit être avant ou égale à la date de fin":U||"La date de début doit être strictement avant la date de fin"}]),E=v.computed(()=>[...b.required?[R=>!!R||b.requiredErrorMessage]:[],...b.rules,R=>{if(R&&!d(R))return V.value||b.invalidDateErrorMessage||"Date invalide!";const z=c.value.from;if(!R||!z)return!0;const U=Kt.isEndDateValid(z,R,b.allowSameDate);return b.allowSameDate?U||"La date de fin doit être après ou égale à la date de début":U||"La date de fin doit être strictement après la date de début"}]);v.watch([()=>c.value.from,()=>c.value.to],([R,z],[U,Q])=>{!R&&!z&&(U||Q)&&!W&&(D.value=null,V.value=null,e.value=null,m("clear"))}),v.watch(()=>b.from,R=>{R!==c.value.from&&(c.value.from=R,P(),h())}),v.watch(()=>b.to,R=>{R!==c.value.to&&(c.value.to=R,N(),h())}),B({setDateRange:R=>{c.value={from:R.from,to:R.to},P(),N(),h(),w()},getCurrentRange:()=>({from:c.value.from,to:c.value.to}),resetDate:()=>{o()}});const O=R=>{try{const z=R.getRange(new Date);c.value={from:z.from,to:z.to},e.value=R.id,P(),N(),w()}catch(z){console.error("Error applying date preset:",z)}};return v.onMounted(()=>{P(),N(),h()}),(R,z)=>(v.openBlock(),v.createElementBlock("div",Ic,[v.createElementVNode("div",Oc,[v.createVNode(Gr,v.mergeProps(R.$attrs,{"data-cy":s.value,"model-value":c.value.from,mask:"##-##-####",label:R.labelStart,rules:S.value,disable:R.disabled,required:R.required,"hide-bottom-space":"","onUpdate:modelValue":M,onClear:L,onBlur:P,class:"date-input",clearable:""}),null,16,["data-cy","model-value","label","rules","disable","required"]),v.createVNode(Gr,v.mergeProps(R.$attrs,{"model-value":c.value.to,mask:"##-##-####",label:R.labelEnd,"hide-bottom-space":"","data-cy":n.value,rules:E.value,disable:R.disabled,required:R.required,"onUpdate:modelValue":_,onClear:A,onBlur:N,class:"date-input",clearable:""}),null,16,["model-value","label","data-cy","rules","disable","required"]),R.hideActions?v.createCommentVNode("",!0):(v.openBlock(),v.createElementBlock("div",Fc,[v.createVNode(dt,{name:"event",size:"30px",class:"cursor-pointer calendar-icon",style:{opacity:"0.55"},"data-cy":"calendar-icon-range"},{default:v.withCtx(()=>[v.createVNode(ls,{cover:"","transition-show":"scale","transition-hide":"scale",ref_key:"popupRef",ref:i,"no-focus":""},{default:v.withCtx(()=>[v.createElementVNode("div",jc,[R.hideShortcuts?v.createCommentVNode("",!0):(v.openBlock(),v.createElementBlock("div",Dc,[z[0]||(z[0]=v.createElementVNode("div",{class:"presets-title"},"Périodes rapides :",-1)),v.createElementVNode("div",Pc,[v.createElementVNode("div",Nc,[(v.openBlock(!0),v.createElementBlock(v.Fragment,null,v.renderList(u.value,U=>(v.openBlock(),v.createBlock(at,{key:U.id,label:U.label,color:e.value===U.id?"primary":"grey-7",outline:e.value!==U.id,flat:"",dense:"",size:"sm",class:"preset-btn",onClick:Q=>O(U),"data-cy":`date-preset-${U.id}`},null,8,["label","color","outline","onClick","data-cy"]))),128))]),v.createElementVNode("div",Lc,[(v.openBlock(!0),v.createElementBlock(v.Fragment,null,v.renderList(a.value,U=>(v.openBlock(),v.createBlock(at,{key:U.id,label:U.label,color:e.value===U.id?"primary":"grey-7",outline:e.value!==U.id,flat:"",dense:"",size:"sm",class:"preset-btn",onClick:Q=>O(U),"data-cy":`date-preset-${U.id}`},null,8,["label","color","outline","onClick","data-cy"]))),128))])])])),v.createElementVNode("div",Vc,[v.createVNode(ss,{"model-value":c.value,mask:"DD-MM-YYYY","today-btn":"",range:"","data-cy":"date-picker-range",locale:R.locale,options:q.value,events:R.highlightEvents,"event-color":"warning",disable:R.disabled,"onUpdate:modelValue":x,onRangeEnd:y,"no-unset":""},null,8,["model-value","locale","options","events","disable"])]),v.createElementVNode("div",qc,[v.createVNode(at,{label:R.resetLabel,color:"grey-7",flat:"",dense:"",onClick:o,class:"q-mr-sm"},null,8,["label"]),v.createVNode(at,{label:R.closeLabel,color:"primary",flat:"",dense:"",onClick:f},null,8,["label"])])])]),_:1},512)]),_:1})]))]),R.startDateHint?(v.openBlock(),v.createElementBlock("div",zc,[v.createElementVNode("p",Uc,v.toDisplayString(R.startDateHint),1)])):v.createCommentVNode("",!0)]))}}),ps=Vt(Wc,[["__scopeId","data-v-3ec8c453"]]);var ut=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Hc(l){return l&&l.__esModule&&Object.prototype.hasOwnProperty.call(l,"default")?l.default:l}function gn(l){throw new Error('Could not dynamically require "'+l+'". Please configure the dynamicRequireTargets or/and ignoreDynamicRequires option of @rollup/plugin-commonjs appropriately for this require call to work.')}var fi={exports:{}};/*! ExcelJS 19-10-2023 */var ra;function Yc(){return ra||(ra=1,function(l,B){(function(t){l.exports=t()})(function(){return function t(b,m,c){function i(e,r){if(!m[e]){if(!b[e]){var u=typeof gn=="function"&&gn;if(!r&&u)return u(e,!0);if(s)return s(e,!0);var a=new Error("Cannot find module '"+e+"'");throw a.code="MODULE_NOT_FOUND",a}var o=m[e]={exports:{}};b[e][0].call(o.exports,function(f){return i(b[e][1][f]||f)},o,o.exports,t,b,m,c)}return m[e].exports}for(var s=typeof gn=="function"&&gn,n=0;n<c.length;n++)i(c[n]);return i}({1:[function(t,b,m){const c=t("fs"),i=t("fast-csv"),s=t("dayjs/plugin/customParseFormat"),n=t("dayjs/plugin/utc"),e=t("dayjs").extend(s).extend(n),r=t("../utils/stream-buf"),{fs:{exists:u}}=t("../utils/utils"),a={true:!0,false:!1,"#N/A":{error:"#N/A"},"#REF!":{error:"#REF!"},"#NAME?":{error:"#NAME?"},"#DIV/0!":{error:"#DIV/0!"},"#NULL!":{error:"#NULL!"},"#VALUE!":{error:"#VALUE!"},"#NUM!":{error:"#NUM!"}};b.exports=class{constructor(o){this.workbook=o,this.worksheet=null}async readFile(o,f){if(f=f||{},!await u(o))throw new Error("File not found: "+o);const h=c.createReadStream(o),d=await this.read(h,f);return h.close(),d}read(o,f){return f=f||{},new Promise((h,d)=>{const g=this.workbook.addWorksheet(f.sheetName),p=f.dateFormats||["YYYY-MM-DD[T]HH:mm:ssZ","YYYY-MM-DD[T]HH:mm:ss","MM-DD-YYYY","YYYY-MM-DD"],k=f.map||function(T){if(T==="")return null;const D=Number(T);if(!Number.isNaN(D)&&D!==1/0)return D;const V=p.reduce((N,q)=>{if(N)return N;const W=e(T,q,!0);return W.isValid()?W:null},null);if(V)return new Date(V.valueOf());const P=a[T];return P!==void 0?P:T},C=i.parse(f.parserOptions).on("data",T=>{g.addRow(T.map(k))}).on("end",()=>{C.emit("worksheet",g)});C.on("worksheet",h).on("error",d),o.pipe(C)})}createInputStream(){throw new Error("`CSV#createInputStream` is deprecated. You should use `CSV#read` instead. This method will be removed in version 5.0. Please follow upgrade instruction: https://github.com/exceljs/exceljs/blob/master/UPGRADE-4.0.md")}write(o,f){return new Promise((h,d)=>{f=f||{};const g=this.workbook.getWorksheet(f.sheetName||f.sheetId),p=i.format(f.formatterOptions);o.on("finish",()=>{h()}),p.on("error",d),p.pipe(o);const{dateFormat:k,dateUTC:C}=f,T=f.map||(P=>{if(P){if(P.text||P.hyperlink)return P.hyperlink||P.text||"";if(P.formula||P.result)return P.result||"";if(P instanceof Date)return k?C?e.utc(P).format(k):e(P).format(k):C?e.utc(P).format():e(P).format();if(P.error)return P.error;if(typeof P=="object")return JSON.stringify(P)}return P}),D=f.includeEmptyRows===void 0||f.includeEmptyRows;let V=1;g&&g.eachRow((P,N)=>{if(D)for(;V++<N-1;)p.write([]);const{values:q}=P;q.shift(),p.write(q.map(T)),V=N}),p.end()})}writeFile(o,f){const h={encoding:(f=f||{}).encoding||"utf8"},d=c.createWriteStream(o,h);return this.write(d,f)}async writeBuffer(o){const f=new r;return await this.write(f,o),f.read()}}},{"../utils/stream-buf":24,"../utils/utils":27,dayjs:391,"dayjs/plugin/customParseFormat":392,"dayjs/plugin/utc":393,"fast-csv":424,fs:216}],2:[function(t,b,m){const c=t("../utils/col-cache");class i{constructor(n,e){let r=arguments.length>2&&arguments[2]!==void 0?arguments[2]:0;if(this.worksheet=n,e)if(typeof e=="string"){const u=c.decodeAddress(e);this.nativeCol=u.col+r,this.nativeColOff=0,this.nativeRow=u.row+r,this.nativeRowOff=0}else e.nativeCol!==void 0?(this.nativeCol=e.nativeCol||0,this.nativeColOff=e.nativeColOff||0,this.nativeRow=e.nativeRow||0,this.nativeRowOff=e.nativeRowOff||0):e.col!==void 0?(this.col=e.col+r,this.row=e.row+r):(this.nativeCol=0,this.nativeColOff=0,this.nativeRow=0,this.nativeRowOff=0);else this.nativeCol=0,this.nativeColOff=0,this.nativeRow=0,this.nativeRowOff=0}static asInstance(n){return n instanceof i||n==null?n:new i(n)}get col(){return this.nativeCol+Math.min(this.colWidth-1,this.nativeColOff)/this.colWidth}set col(n){this.nativeCol=Math.floor(n),this.nativeColOff=Math.floor((n-this.nativeCol)*this.colWidth)}get row(){return this.nativeRow+Math.min(this.rowHeight-1,this.nativeRowOff)/this.rowHeight}set row(n){this.nativeRow=Math.floor(n),this.nativeRowOff=Math.floor((n-this.nativeRow)*this.rowHeight)}get colWidth(){return this.worksheet&&this.worksheet.getColumn(this.nativeCol+1)&&this.worksheet.getColumn(this.nativeCol+1).isCustomWidth?Math.floor(1e4*this.worksheet.getColumn(this.nativeCol+1).width):64e4}get rowHeight(){return this.worksheet&&this.worksheet.getRow(this.nativeRow+1)&&this.worksheet.getRow(this.nativeRow+1).height?Math.floor(1e4*this.worksheet.getRow(this.nativeRow+1).height):18e4}get model(){return{nativeCol:this.nativeCol,nativeColOff:this.nativeColOff,nativeRow:this.nativeRow,nativeRowOff:this.nativeRowOff}}set model(n){this.nativeCol=n.nativeCol,this.nativeColOff=n.nativeColOff,this.nativeRow=n.nativeRow,this.nativeRowOff=n.nativeRowOff}}b.exports=i},{"../utils/col-cache":19}],3:[function(t,b,m){const c=t("../utils/col-cache"),i=t("../utils/under-dash"),s=t("./enums"),{slideFormula:n}=t("../utils/shared-formula"),e=t("./note");class r{constructor(o,f,h){if(!o||!f)throw new Error("A Cell needs a Row");this._row=o,this._column=f,c.validateAddress(h),this._address=h,this._value=u.create(r.Types.Null,this),this.style=this._mergeStyle(o.style,f.style,{}),this._mergeCount=0}get worksheet(){return this._row.worksheet}get workbook(){return this._row.worksheet.workbook}destroy(){delete this.style,delete this._value,delete this._row,delete this._column,delete this._address}get numFmt(){return this.style.numFmt}set numFmt(o){this.style.numFmt=o}get font(){return this.style.font}set font(o){this.style.font=o}get alignment(){return this.style.alignment}set alignment(o){this.style.alignment=o}get border(){return this.style.border}set border(o){this.style.border=o}get fill(){return this.style.fill}set fill(o){this.style.fill=o}get protection(){return this.style.protection}set protection(o){this.style.protection=o}_mergeStyle(o,f,h){const d=o&&o.numFmt||f&&f.numFmt;d&&(h.numFmt=d);const g=o&&o.font||f&&f.font;g&&(h.font=g);const p=o&&o.alignment||f&&f.alignment;p&&(h.alignment=p);const k=o&&o.border||f&&f.border;k&&(h.border=k);const C=o&&o.fill||f&&f.fill;C&&(h.fill=C);const T=o&&o.protection||f&&f.protection;return T&&(h.protection=T),h}get address(){return this._address}get row(){return this._row.number}get col(){return this._column.number}get $col$row(){return`$${this._column.letter}$${this.row}`}get type(){return this._value.type}get effectiveType(){return this._value.effectiveType}toCsvString(){return this._value.toCsvString()}addMergeRef(){this._mergeCount++}releaseMergeRef(){this._mergeCount--}get isMerged(){return this._mergeCount>0||this.type===r.Types.Merge}merge(o,f){this._value.release(),this._value=u.create(r.Types.Merge,this,o),f||(this.style=o.style)}unmerge(){this.type===r.Types.Merge&&(this._value.release(),this._value=u.create(r.Types.Null,this),this.style=this._mergeStyle(this._row.style,this._column.style,{}))}isMergedTo(o){return this._value.type===r.Types.Merge&&this._value.isMergedTo(o)}get master(){return this.type===r.Types.Merge?this._value.master:this}get isHyperlink(){return this._value.type===r.Types.Hyperlink}get hyperlink(){return this._value.hyperlink}get value(){return this._value.value}set value(o){this.type!==r.Types.Merge?(this._value.release(),this._value=u.create(u.getType(o),this,o)):this._value.master.value=o}get note(){return this._comment&&this._comment.note}set note(o){this._comment=new e(o)}get text(){return this._value.toString()}get html(){return i.escapeHtml(this.text)}toString(){return this.text}_upgradeToHyperlink(o){this.type===r.Types.String&&(this._value=u.create(r.Types.Hyperlink,this,{text:this._value.value,hyperlink:o}))}get formula(){return this._value.formula}get result(){return this._value.result}get formulaType(){return this._value.formulaType}get fullAddress(){const{worksheet:o}=this._row;return{sheetName:o.name,address:this.address,row:this.row,col:this.col}}get name(){return this.names[0]}set name(o){this.names=[o]}get names(){return this.workbook.definedNames.getNamesEx(this.fullAddress)}set names(o){const{definedNames:f}=this.workbook;f.removeAllNames(this.fullAddress),o.forEach(h=>{f.addEx(this.fullAddress,h)})}addName(o){this.workbook.definedNames.addEx(this.fullAddress,o)}removeName(o){this.workbook.definedNames.removeEx(this.fullAddress,o)}removeAllNames(){this.workbook.definedNames.removeAllNames(this.fullAddress)}get _dataValidations(){return this.worksheet.dataValidations}get dataValidation(){return this._dataValidations.find(this.address)}set dataValidation(o){this._dataValidations.add(this.address,o)}get model(){const{model:o}=this._value;return o.style=this.style,this._comment&&(o.comment=this._comment.model),o}set model(o){if(this._value.release(),this._value=u.create(o.type,this),this._value.model=o,o.comment)switch(o.comment.type){case"note":this._comment=e.fromModel(o.comment)}o.style?this.style=o.style:this.style={}}}r.Types=s.ValueType;const u={getType:a=>a==null?r.Types.Null:a instanceof String||typeof a=="string"?r.Types.String:typeof a=="number"?r.Types.Number:typeof a=="boolean"?r.Types.Boolean:a instanceof Date?r.Types.Date:a.text&&a.hyperlink?r.Types.Hyperlink:a.formula||a.sharedFormula?r.Types.Formula:a.richText?r.Types.RichText:a.sharedString?r.Types.SharedString:a.error?r.Types.Error:r.Types.JSON,types:[{t:r.Types.Null,f:class{constructor(a){this.model={address:a.address,type:r.Types.Null}}get value(){return null}set value(a){}get type(){return r.Types.Null}get effectiveType(){return r.Types.Null}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return""}release(){}toString(){return""}}},{t:r.Types.Number,f:class{constructor(a,o){this.model={address:a.address,type:r.Types.Number,value:o}}get value(){return this.model.value}set value(a){this.model.value=a}get type(){return r.Types.Number}get effectiveType(){return r.Types.Number}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return this.model.value.toString()}release(){}toString(){return this.model.value.toString()}}},{t:r.Types.String,f:class{constructor(a,o){this.model={address:a.address,type:r.Types.String,value:o}}get value(){return this.model.value}set value(a){this.model.value=a}get type(){return r.Types.String}get effectiveType(){return r.Types.String}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return`"${this.model.value.replace(/"/g,'""')}"`}release(){}toString(){return this.model.value}}},{t:r.Types.Date,f:class{constructor(a,o){this.model={address:a.address,type:r.Types.Date,value:o}}get value(){return this.model.value}set value(a){this.model.value=a}get type(){return r.Types.Date}get effectiveType(){return r.Types.Date}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return this.model.value.toISOString()}release(){}toString(){return this.model.value.toString()}}},{t:r.Types.Hyperlink,f:class{constructor(a,o){this.model={address:a.address,type:r.Types.Hyperlink,text:o?o.text:void 0,hyperlink:o?o.hyperlink:void 0},o&&o.tooltip&&(this.model.tooltip=o.tooltip)}get value(){const a={text:this.model.text,hyperlink:this.model.hyperlink};return this.model.tooltip&&(a.tooltip=this.model.tooltip),a}set value(a){this.model={text:a.text,hyperlink:a.hyperlink},a.tooltip&&(this.model.tooltip=a.tooltip)}get text(){return this.model.text}set text(a){this.model.text=a}get hyperlink(){return this.model.hyperlink}set hyperlink(a){this.model.hyperlink=a}get type(){return r.Types.Hyperlink}get effectiveType(){return r.Types.Hyperlink}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return this.model.hyperlink}release(){}toString(){return this.model.text}}},{t:r.Types.Formula,f:class{constructor(a,o){this.cell=a,this.model={address:a.address,type:r.Types.Formula,shareType:o?o.shareType:void 0,ref:o?o.ref:void 0,formula:o?o.formula:void 0,sharedFormula:o?o.sharedFormula:void 0,result:o?o.result:void 0}}_copyModel(a){const o={},f=h=>{const d=a[h];d&&(o[h]=d)};return f("formula"),f("result"),f("ref"),f("shareType"),f("sharedFormula"),o}get value(){return this._copyModel(this.model)}set value(a){this.model=this._copyModel(a)}validate(a){switch(u.getType(a)){case r.Types.Null:case r.Types.String:case r.Types.Number:case r.Types.Date:break;case r.Types.Hyperlink:case r.Types.Formula:default:throw new Error("Cannot process that type of result value")}}get dependencies(){return{ranges:this.formula.match(/([a-zA-Z0-9]+!)?[A-Z]{1,3}\d{1,4}:[A-Z]{1,3}\d{1,4}/g),cells:this.formula.replace(/([a-zA-Z0-9]+!)?[A-Z]{1,3}\d{1,4}:[A-Z]{1,3}\d{1,4}/g,"").match(/([a-zA-Z0-9]+!)?[A-Z]{1,3}\d{1,4}/g)}}get formula(){return this.model.formula||this._getTranslatedFormula()}set formula(a){this.model.formula=a}get formulaType(){return this.model.formula?s.FormulaType.Master:this.model.sharedFormula?s.FormulaType.Shared:s.FormulaType.None}get result(){return this.model.result}set result(a){this.model.result=a}get type(){return r.Types.Formula}get effectiveType(){const a=this.model.result;return a==null?s.ValueType.Null:a instanceof String||typeof a=="string"?s.ValueType.String:typeof a=="number"?s.ValueType.Number:a instanceof Date?s.ValueType.Date:a.text&&a.hyperlink?s.ValueType.Hyperlink:a.formula?s.ValueType.Formula:s.ValueType.Null}get address(){return this.model.address}set address(a){this.model.address=a}_getTranslatedFormula(){if(!this._translatedFormula&&this.model.sharedFormula){const{worksheet:a}=this.cell,o=a.findCell(this.model.sharedFormula);this._translatedFormula=o&&n(o.formula,o.address,this.model.address)}return this._translatedFormula}toCsvString(){return""+(this.model.result||"")}release(){}toString(){return this.model.result?this.model.result.toString():""}}},{t:r.Types.Merge,f:class{constructor(a,o){this.model={address:a.address,type:r.Types.Merge,master:o?o.address:void 0},this._master=o,o&&o.addMergeRef()}get value(){return this._master.value}set value(a){a instanceof r?(this._master&&this._master.releaseMergeRef(),a.addMergeRef(),this._master=a):this._master.value=a}isMergedTo(a){return a===this._master}get master(){return this._master}get type(){return r.Types.Merge}get effectiveType(){return this._master.effectiveType}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return""}release(){this._master.releaseMergeRef()}toString(){return this.value.toString()}}},{t:r.Types.JSON,f:class{constructor(a,o){this.model={address:a.address,type:r.Types.String,value:JSON.stringify(o),rawValue:o}}get value(){return this.model.rawValue}set value(a){this.model.rawValue=a,this.model.value=JSON.stringify(a)}get type(){return r.Types.String}get effectiveType(){return r.Types.String}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return this.model.value}release(){}toString(){return this.model.value}}},{t:r.Types.SharedString,f:class{constructor(a,o){this.model={address:a.address,type:r.Types.SharedString,value:o}}get value(){return this.model.value}set value(a){this.model.value=a}get type(){return r.Types.SharedString}get effectiveType(){return r.Types.SharedString}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return this.model.value.toString()}release(){}toString(){return this.model.value.toString()}}},{t:r.Types.RichText,f:class{constructor(a,o){this.model={address:a.address,type:r.Types.String,value:o}}get value(){return this.model.value}set value(a){this.model.value=a}toString(){return this.model.value.richText.map(a=>a.text).join("")}get type(){return r.Types.RichText}get effectiveType(){return r.Types.RichText}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return`"${this.text.replace(/"/g,'""')}"`}release(){}}},{t:r.Types.Boolean,f:class{constructor(a,o){this.model={address:a.address,type:r.Types.Boolean,value:o}}get value(){return this.model.value}set value(a){this.model.value=a}get type(){return r.Types.Boolean}get effectiveType(){return r.Types.Boolean}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return this.model.value?1:0}release(){}toString(){return this.model.value.toString()}}},{t:r.Types.Error,f:class{constructor(a,o){this.model={address:a.address,type:r.Types.Error,value:o}}get value(){return this.model.value}set value(a){this.model.value=a}get type(){return r.Types.Error}get effectiveType(){return r.Types.Error}get address(){return this.model.address}set address(a){this.model.address=a}toCsvString(){return this.toString()}release(){}toString(){return this.model.value.error.toString()}}}].reduce((a,o)=>(a[o.t]=o.f,a),[]),create(a,o,f){const h=this.types[a];if(!h)throw new Error("Could not create Value of type "+a);return new h(o,f)}};b.exports=r},{"../utils/col-cache":19,"../utils/shared-formula":23,"../utils/under-dash":26,"./enums":7,"./note":9}],4:[function(t,b,m){const c=t("../utils/under-dash"),i=t("./enums"),s=t("../utils/col-cache");class n{constructor(r,u,a){this._worksheet=r,this._number=u,a!==!1&&(this.defn=a)}get number(){return this._number}get worksheet(){return this._worksheet}get letter(){return s.n2l(this._number)}get isCustomWidth(){return this.width!==void 0&&this.width!==9}get defn(){return{header:this._header,key:this.key,width:this.width,style:this.style,hidden:this.hidden,outlineLevel:this.outlineLevel}}set defn(r){r?(this.key=r.key,this.width=r.width!==void 0?r.width:9,this.outlineLevel=r.outlineLevel,r.style?this.style=r.style:this.style={},this.header=r.header,this._hidden=!!r.hidden):(delete this._header,delete this._key,delete this.width,this.style={},this.outlineLevel=0)}get headers(){return this._header&&this._header instanceof Array?this._header:[this._header]}get header(){return this._header}set header(r){r!==void 0?(this._header=r,this.headers.forEach((u,a)=>{this._worksheet.getCell(a+1,this.number).value=u})):this._header=void 0}get key(){return this._key}set key(r){(this._key&&this._worksheet.getColumnKey(this._key))===this&&this._worksheet.deleteColumnKey(this._key),this._key=r,r&&this._worksheet.setColumnKey(this._key,this)}get hidden(){return!!this._hidden}set hidden(r){this._hidden=r}get outlineLevel(){return this._outlineLevel||0}set outlineLevel(r){this._outlineLevel=r}get collapsed(){return!!(this._outlineLevel&&this._outlineLevel>=this._worksheet.properties.outlineLevelCol)}toString(){return JSON.stringify({key:this.key,width:this.width,headers:this.headers.length?this.headers:void 0})}equivalentTo(r){return this.width===r.width&&this.hidden===r.hidden&&this.outlineLevel===r.outlineLevel&&c.isEqual(this.style,r.style)}get isDefault(){if(this.isCustomWidth||this.hidden||this.outlineLevel)return!1;const r=this.style;return!r||!(r.font||r.numFmt||r.alignment||r.border||r.fill||r.protection)}get headerCount(){return this.headers.length}eachCell(r,u){const a=this.number;u||(u=r,r=null),this._worksheet.eachRow(r,(o,f)=>{u(o.getCell(a),f)})}get values(){const r=[];return this.eachCell((u,a)=>{u&&u.type!==i.ValueType.Null&&(r[a]=u.value)}),r}set values(r){if(!r)return;const u=this.number;let a=0;r.hasOwnProperty("0")&&(a=1),r.forEach((o,f)=>{this._worksheet.getCell(f+a,u).value=o})}_applyStyle(r,u){return this.style[r]=u,this.eachCell(a=>{a[r]=u}),u}get numFmt(){return this.style.numFmt}set numFmt(r){this._applyStyle("numFmt",r)}get font(){return this.style.font}set font(r){this._applyStyle("font",r)}get alignment(){return this.style.alignment}set alignment(r){this._applyStyle("alignment",r)}get protection(){return this.style.protection}set protection(r){this._applyStyle("protection",r)}get border(){return this.style.border}set border(r){this._applyStyle("border",r)}get fill(){return this.style.fill}set fill(r){this._applyStyle("fill",r)}static toModel(r){const u=[];let a=null;return r&&r.forEach((o,f)=>{o.isDefault?a&&(a=null):a&&o.equivalentTo(a)?a.max=f+1:(a={min:f+1,max:f+1,width:o.width!==void 0?o.width:9,style:o.style,isCustomWidth:o.isCustomWidth,hidden:o.hidden,outlineLevel:o.outlineLevel,collapsed:o.collapsed},u.push(a))}),u.length?u:void 0}static fromModel(r,u){const a=[];let o=1,f=0;for(u=(u=u||[]).sort(function(h,d){return h.min-d.min});f<u.length;){const h=u[f++];for(;o<h.min;)a.push(new n(r,o++));for(;o<=h.max;)a.push(new n(r,o++,h))}return a.length?a:null}}b.exports=n},{"../utils/col-cache":19,"../utils/under-dash":26,"./enums":7}],5:[function(t,b,m){b.exports=class{constructor(c){this.model=c||{}}add(c,i){return this.model[c]=i}find(c){return this.model[c]}remove(c){this.model[c]=void 0}}},{}],6:[function(t,b,m){const c=t("../utils/under-dash"),i=t("../utils/col-cache"),s=t("../utils/cell-matrix"),n=t("./range"),e=/[$](\w+)[$](\d+)(:[$](\w+)[$](\d+))?/;b.exports=class{constructor(){this.matrixMap={}}getMatrix(r){return this.matrixMap[r]||(this.matrixMap[r]=new s)}add(r,u){const a=i.decodeEx(r);this.addEx(a,u)}addEx(r,u){const a=this.getMatrix(u);if(r.top)for(let o=r.left;o<=r.right;o++)for(let f=r.top;f<=r.bottom;f++){const h={sheetName:r.sheetName,address:i.n2l(o)+f,row:f,col:o};a.addCellEx(h)}else a.addCellEx(r)}remove(r,u){const a=i.decodeEx(r);this.removeEx(a,u)}removeEx(r,u){this.getMatrix(u).removeCellEx(r)}removeAllNames(r){c.each(this.matrixMap,u=>{u.removeCellEx(r)})}forEach(r){c.each(this.matrixMap,(u,a)=>{u.forEach(o=>{r(a,o)})})}getNames(r){return this.getNamesEx(i.decodeEx(r))}getNamesEx(r){return c.map(this.matrixMap,(u,a)=>u.findCellEx(r)&&a).filter(Boolean)}_explore(r,u){u.mark=!1;const{sheetName:a}=u,o=new n(u.row,u.col,u.row,u.col,a);let f,h;function d(p,k){const C=r.findCellAt(a,p,u.col);return!(!C||!C.mark)&&(o[k]=p,C.mark=!1,!0)}for(h=u.row-1;d(h,"top");h--);for(h=u.row+1;d(h,"bottom");h++);function g(p,k){const C=[];for(h=o.top;h<=o.bottom;h++){const T=r.findCellAt(a,h,p);if(!T||!T.mark)return!1;C.push(T)}o[k]=p;for(let T=0;T<C.length;T++)C[T].mark=!1;return!0}for(f=u.col-1;g(f,"left");f--);for(f=u.col+1;g(f,"right");f++);return o}getRanges(r,u){return(u=u||this.matrixMap[r])?(u.forEach(a=>{a.mark=!0}),{name:r,ranges:u.map(a=>a.mark&&this._explore(u,a)).filter(Boolean).map(a=>a.$shortRange)}):{name:r,ranges:[]}}normaliseMatrix(r,u){r.forEachInSheet(u,(a,o,f)=>{a&&(a.row===o&&a.col===f||(a.row=o,a.col=f,a.address=i.n2l(f)+o))})}spliceRows(r,u,a,o){c.each(this.matrixMap,f=>{f.spliceRows(r,u,a,o),this.normaliseMatrix(f,r)})}spliceColumns(r,u,a,o){c.each(this.matrixMap,f=>{f.spliceColumns(r,u,a,o),this.normaliseMatrix(f,r)})}get model(){return c.map(this.matrixMap,(r,u)=>this.getRanges(u,r)).filter(r=>r.ranges.length)}set model(r){const u=this.matrixMap={};r.forEach(a=>{const o=u[a.name]=new s;a.ranges.forEach(f=>{e.test(f.split("!").pop()||"")&&o.addCell(f)})})}}},{"../utils/cell-matrix":18,"../utils/col-cache":19,"../utils/under-dash":26,"./range":10}],7:[function(t,b,m){b.exports={ValueType:{Null:0,Merge:1,Number:2,String:3,Date:4,Hyperlink:5,Formula:6,SharedString:7,RichText:8,Boolean:9,Error:10},FormulaType:{None:0,Master:1,Shared:2},RelationshipType:{None:0,OfficeDocument:1,Worksheet:2,CalcChain:3,SharedStrings:4,Styles:5,Theme:6,Hyperlink:7},DocumentType:{Xlsx:1},ReadingOrder:{LeftToRight:1,RightToLeft:2},ErrorValue:{NotApplicable:"#N/A",Ref:"#REF!",Name:"#NAME?",DivZero:"#DIV/0!",Null:"#NULL!",Value:"#VALUE!",Num:"#NUM!"}}},{}],8:[function(t,b,m){const c=t("../utils/col-cache"),i=t("./anchor");b.exports=class{constructor(s,n){this.worksheet=s,this.model=n}get model(){switch(this.type){case"background":return{type:this.type,imageId:this.imageId};case"image":return{type:this.type,imageId:this.imageId,hyperlinks:this.range.hyperlinks,range:{tl:this.range.tl.model,br:this.range.br&&this.range.br.model,ext:this.range.ext,editAs:this.range.editAs}};default:throw new Error("Invalid Image Type")}}set model(s){let{type:n,imageId:e,range:r,hyperlinks:u}=s;if(this.type=n,this.imageId=e,n==="image")if(typeof r=="string"){const a=c.decode(r);this.range={tl:new i(this.worksheet,{col:a.left,row:a.top},-1),br:new i(this.worksheet,{col:a.right,row:a.bottom},0),editAs:"oneCell"}}else this.range={tl:new i(this.worksheet,r.tl,0),br:r.br&&new i(this.worksheet,r.br,0),ext:r.ext,editAs:r.editAs,hyperlinks:u||r.hyperlinks}}}},{"../utils/col-cache":19,"./anchor":2}],9:[function(t,b,m){const c=t("../utils/under-dash");class i{constructor(n){this.note=n}get model(){let n=null;switch(typeof this.note){case"string":n={type:"note",note:{texts:[{text:this.note}]}};break;default:n={type:"note",note:this.note}}return c.deepMerge({},i.DEFAULT_CONFIGS,n)}set model(n){const{note:e}=n,{texts:r}=e;r.length===1&&Object.keys(r[0]).length===1?this.note=r[0].text:this.note=e}static fromModel(n){const e=new i;return e.model=n,e}}i.DEFAULT_CONFIGS={note:{margins:{insetmode:"auto",inset:[.13,.13,.25,.25]},protection:{locked:"True",lockText:"True"},editAs:"absolute"}},b.exports=i},{"../utils/under-dash":26}],10:[function(t,b,m){const c=t("../utils/col-cache");class i{constructor(){this.decode(arguments)}setTLBR(n,e,r,u,a){if(arguments.length<4){const o=c.decodeAddress(n),f=c.decodeAddress(e);this.model={top:Math.min(o.row,f.row),left:Math.min(o.col,f.col),bottom:Math.max(o.row,f.row),right:Math.max(o.col,f.col),sheetName:r},this.setTLBR(o.row,o.col,f.row,f.col,a)}else this.model={top:Math.min(n,r),left:Math.min(e,u),bottom:Math.max(n,r),right:Math.max(e,u),sheetName:a}}decode(n){switch(n.length){case 5:this.setTLBR(n[0],n[1],n[2],n[3],n[4]);break;case 4:this.setTLBR(n[0],n[1],n[2],n[3]);break;case 3:this.setTLBR(n[0],n[1],n[2]);break;case 2:this.setTLBR(n[0],n[1]);break;case 1:{const e=n[0];if(e instanceof i)this.model={top:e.model.top,left:e.model.left,bottom:e.model.bottom,right:e.model.right,sheetName:e.sheetName};else if(e instanceof Array)this.decode(e);else if(e.top&&e.left&&e.bottom&&e.right)this.model={top:e.top,left:e.left,bottom:e.bottom,right:e.right,sheetName:e.sheetName};else{const r=c.decodeEx(e);r.top?this.model={top:r.top,left:r.left,bottom:r.bottom,right:r.right,sheetName:r.sheetName}:this.model={top:r.row,left:r.col,bottom:r.row,right:r.col,sheetName:r.sheetName}}break}case 0:this.model={top:0,left:0,bottom:0,right:0};break;default:throw new Error("Invalid number of arguments to _getDimensions() - "+n.length)}}get top(){return this.model.top||1}set top(n){this.model.top=n}get left(){return this.model.left||1}set left(n){this.model.left=n}get bottom(){return this.model.bottom||1}set bottom(n){this.model.bottom=n}get right(){return this.model.right||1}set right(n){this.model.right=n}get sheetName(){return this.model.sheetName}set sheetName(n){this.model.sheetName=n}get _serialisedSheetName(){const{sheetName:n}=this.model;return n?/^[a-zA-Z0-9]*$/.test(n)?n+"!":`'${n}'!`:""}expand(n,e,r,u){(!this.model.top||n<this.top)&&(this.top=n),(!this.model.left||e<this.left)&&(this.left=e),(!this.model.bottom||r>this.bottom)&&(this.bottom=r),(!this.model.right||u>this.right)&&(this.right=u)}expandRow(n){if(n){const{dimensions:e,number:r}=n;e&&this.expand(r,e.min,r,e.max)}}expandToAddress(n){const e=c.decodeEx(n);this.expand(e.row,e.col,e.row,e.col)}get tl(){return c.n2l(this.left)+this.top}get $t$l(){return`$${c.n2l(this.left)}$${this.top}`}get br(){return c.n2l(this.right)+this.bottom}get $b$r(){return`$${c.n2l(this.right)}$${this.bottom}`}get range(){return`${this._serialisedSheetName+this.tl}:${this.br}`}get $range(){return`${this._serialisedSheetName+this.$t$l}:${this.$b$r}`}get shortRange(){return this.count>1?this.range:this._serialisedSheetName+this.tl}get $shortRange(){return this.count>1?this.$range:this._serialisedSheetName+this.$t$l}get count(){return(1+this.bottom-this.top)*(1+this.right-this.left)}toString(){return this.range}intersects(n){return(!n.sheetName||!this.sheetName||n.sheetName===this.sheetName)&&!(n.bottom<this.top)&&!(n.top>this.bottom)&&!(n.right<this.left)&&!(n.left>this.right)}contains(n){const e=c.decodeEx(n);return this.containsEx(e)}containsEx(n){return(!n.sheetName||!this.sheetName||n.sheetName===this.sheetName)&&n.row>=this.top&&n.row<=this.bottom&&n.col>=this.left&&n.col<=this.right}forEachAddress(n){for(let e=this.left;e<=this.right;e++)for(let r=this.top;r<=this.bottom;r++)n(c.encodeAddress(r,e),r,e)}}b.exports=i},{"../utils/col-cache":19}],11:[function(t,b,m){const c=t("../utils/under-dash"),i=t("./enums"),s=t("../utils/col-cache"),n=t("./cell");b.exports=class{constructor(e,r){this._worksheet=e,this._number=r,this._cells=[],this.style={},this.outlineLevel=0}get number(){return this._number}get worksheet(){return this._worksheet}commit(){this._worksheet._commitRow(this)}destroy(){delete this._worksheet,delete this._cells,delete this.style}findCell(e){return this._cells[e-1]}getCellEx(e){let r=this._cells[e.col-1];if(!r){const u=this._worksheet.getColumn(e.col);r=new n(this,u,e.address),this._cells[e.col-1]=r}return r}getCell(e){if(typeof e=="string"){const r=this._worksheet.getColumnKey(e);e=r?r.number:s.l2n(e)}return this._cells[e-1]||this.getCellEx({address:s.encodeAddress(this._number,e),row:this._number,col:e})}splice(e,r){const u=e+r;for(var a=arguments.length,o=new Array(a>2?a-2:0),f=2;f<a;f++)o[f-2]=arguments[f];const h=o.length-r,d=this._cells.length;let g,p,k;if(h<0)for(g=e+o.length;g<=d;g++)k=this._cells[g-1],p=this._cells[g-h-1],p?(k=this.getCell(g),k.value=p.value,k.style=p.style,k._comment=p._comment):k&&(k.value=null,k.style={},k._comment=void 0);else if(h>0)for(g=d;g>=u;g--)p=this._cells[g-1],p?(k=this.getCell(g+h),k.value=p.value,k.style=p.style,k._comment=p._comment):this._cells[g+h-1]=void 0;for(g=0;g<o.length;g++)k=this.getCell(e+g),k.value=o[g],k.style={},k._comment=void 0}eachCell(e,r){if(r||(r=e,e=null),e&&e.includeEmpty){const u=this._cells.length;for(let a=1;a<=u;a++)r(this.getCell(a),a)}else this._cells.forEach((u,a)=>{u&&u.type!==i.ValueType.Null&&r(u,a+1)})}addPageBreak(e,r){const u=this._worksheet,a=Math.max(0,e-1)||0,o=Math.max(0,r-1)||16838,f={id:this._number,max:o,man:1};a&&(f.min=a),u.rowBreaks.push(f)}get values(){const e=[];return this._cells.forEach(r=>{r&&r.type!==i.ValueType.Null&&(e[r.col]=r.value)}),e}set values(e){if(this._cells=[],e)if(e instanceof Array){let r=0;e.hasOwnProperty("0")&&(r=1),e.forEach((u,a)=>{u!==void 0&&(this.getCellEx({address:s.encodeAddress(this._number,a+r),row:this._number,col:a+r}).value=u)})}else this._worksheet.eachColumnKey((r,u)=>{e[u]!==void 0&&(this.getCellEx({address:s.encodeAddress(this._number,r.number),row:this._number,col:r.number}).value=e[u])})}get hasValues(){return c.some(this._cells,e=>e&&e.type!==i.ValueType.Null)}get cellCount(){return this._cells.length}get actualCellCount(){let e=0;return this.eachCell(()=>{e++}),e}get dimensions(){let e=0,r=0;return this._cells.forEach(u=>{u&&u.type!==i.ValueType.Null&&((!e||e>u.col)&&(e=u.col),r<u.col&&(r=u.col))}),e>0?{min:e,max:r}:null}_applyStyle(e,r){return this.style[e]=r,this._cells.forEach(u=>{u&&(u[e]=r)}),r}get numFmt(){return this.style.numFmt}set numFmt(e){this._applyStyle("numFmt",e)}get font(){return this.style.font}set font(e){this._applyStyle("font",e)}get alignment(){return this.style.alignment}set alignment(e){this._applyStyle("alignment",e)}get protection(){return this.style.protection}set protection(e){this._applyStyle("protection",e)}get border(){return this.style.border}set border(e){this._applyStyle("border",e)}get fill(){return this.style.fill}set fill(e){this._applyStyle("fill",e)}get hidden(){return!!this._hidden}set hidden(e){this._hidden=e}get outlineLevel(){return this._outlineLevel||0}set outlineLevel(e){this._outlineLevel=e}get collapsed(){return!!(this._outlineLevel&&this._outlineLevel>=this._worksheet.properties.outlineLevelRow)}get model(){const e=[];let r=0,u=0;return this._cells.forEach(a=>{if(a){const o=a.model;o&&((!r||r>a.col)&&(r=a.col),u<a.col&&(u=a.col),e.push(o))}}),this.height||e.length?{cells:e,number:this.number,min:r,max:u,height:this.height,style:this.style,hidden:this.hidden,outlineLevel:this.outlineLevel,collapsed:this.collapsed}:null}set model(e){if(e.number!==this._number)throw new Error("Invalid row number in model");let r;this._cells=[],e.cells.forEach(u=>{switch(u.type){case n.Types.Merge:break;default:{let a;if(u.address)a=s.decodeAddress(u.address);else if(r){const{row:o}=r,f=r.col+1;a={row:o,col:f,address:s.encodeAddress(o,f),$col$row:`$${s.n2l(f)}$${o}`}}r=a,this.getCellEx(a).model=u;break}}}),e.height?this.height=e.height:delete this.height,this.hidden=e.hidden,this.outlineLevel=e.outlineLevel||0,this.style=e.style&&JSON.parse(JSON.stringify(e.style))||{}}}},{"../utils/col-cache":19,"../utils/under-dash":26,"./cell":3,"./enums":7}],12:[function(t,b,m){const c=t("../utils/col-cache");class i{constructor(n,e,r){this.table=n,this.column=e,this.index=r}_set(n,e){this.table.cacheState(),this.column[n]=e}get name(){return this.column.name}set name(n){this._set("name",n)}get filterButton(){return this.column.filterButton}set filterButton(n){this.column.filterButton=n}get style(){return this.column.style}set style(n){this.column.style=n}get totalsRowLabel(){return this.column.totalsRowLabel}set totalsRowLabel(n){this._set("totalsRowLabel",n)}get totalsRowFunction(){return this.column.totalsRowFunction}set totalsRowFunction(n){this._set("totalsRowFunction",n)}get totalsRowResult(){return this.column.totalsRowResult}set totalsRowResult(n){this._set("totalsRowResult",n)}get totalsRowFormula(){return this.column.totalsRowFormula}set totalsRowFormula(n){this._set("totalsRowFormula",n)}}b.exports=class{constructor(s,n){this.worksheet=s,n&&(this.table=n,this.validate(),this.store())}getFormula(s){switch(s.totalsRowFunction){case"none":return null;case"average":return`SUBTOTAL(101,${this.table.name}[${s.name}])`;case"countNums":return`SUBTOTAL(102,${this.table.name}[${s.name}])`;case"count":return`SUBTOTAL(103,${this.table.name}[${s.name}])`;case"max":return`SUBTOTAL(104,${this.table.name}[${s.name}])`;case"min":return`SUBTOTAL(105,${this.table.name}[${s.name}])`;case"stdDev":return`SUBTOTAL(106,${this.table.name}[${s.name}])`;case"var":return`SUBTOTAL(107,${this.table.name}[${s.name}])`;case"sum":return`SUBTOTAL(109,${this.table.name}[${s.name}])`;case"custom":return s.totalsRowFormula;default:throw new Error("Invalid Totals Row Function: "+s.totalsRowFunction)}}get width(){return this.table.columns.length}get height(){return this.table.rows.length}get filterHeight(){return this.height+(this.table.headerRow?1:0)}get tableHeight(){return this.filterHeight+(this.table.totalsRow?1:0)}validate(){const{table:s}=this,n=(h,d,g)=>{h[d]===void 0&&(h[d]=g)};n(s,"headerRow",!0),n(s,"totalsRow",!1),n(s,"style",{}),n(s.style,"theme","TableStyleMedium2"),n(s.style,"showFirstColumn",!1),n(s.style,"showLastColumn",!1),n(s.style,"showRowStripes",!1),n(s.style,"showColumnStripes",!1);const e=(h,d)=>{if(!h)throw new Error(d)};e(s.ref,"Table must have ref"),e(s.columns,"Table must have column definitions"),e(s.rows,"Table must have row definitions"),s.tl=c.decodeAddress(s.ref);const{row:r,col:u}=s.tl;e(r>0,"Table must be on valid row"),e(u>0,"Table must be on valid col");const{width:a,filterHeight:o,tableHeight:f}=this;s.autoFilterRef=c.encode(r,u,r+o-1,u+a-1),s.tableRef=c.encode(r,u,r+f-1,u+a-1),s.columns.forEach((h,d)=>{e(h.name,`Column ${d} must have a name`),d===0?n(h,"totalsRowLabel","Total"):(n(h,"totalsRowFunction","none"),h.totalsRowFormula=this.getFormula(h))})}store(){const s=(o,f)=>{f&&Object.keys(f).forEach(h=>{o[h]=f[h]})},{worksheet:n,table:e}=this,{row:r,col:u}=e.tl;let a=0;if(e.headerRow){const o=n.getRow(r+a++);e.columns.forEach((f,h)=>{const{style:d,name:g}=f,p=o.getCell(u+h);p.value=g,s(p,d)})}if(e.rows.forEach(o=>{const f=n.getRow(r+a++);o.forEach((h,d)=>{const g=f.getCell(u+d);g.value=h,s(g,e.columns[d].style)})}),e.totalsRow){const o=n.getRow(r+a++);e.columns.forEach((f,h)=>{const d=o.getCell(u+h);if(h===0)d.value=f.totalsRowLabel;else{const g=this.getFormula(f);d.value=g?{formula:f.totalsRowFormula,result:f.totalsRowResult}:null}s(d,f.style)})}}load(s){const{table:n}=this,{row:e,col:r}=n.tl;let u=0;if(n.headerRow){const a=s.getRow(e+u++);n.columns.forEach((o,f)=>{a.getCell(r+f).value=o.name})}if(n.rows.forEach(a=>{const o=s.getRow(e+u++);a.forEach((f,h)=>{o.getCell(r+h).value=f})}),n.totalsRow){const a=s.getRow(e+u++);n.columns.forEach((o,f)=>{const h=a.getCell(r+f);f===0?h.value=o.totalsRowLabel:this.getFormula(o)&&(h.value={formula:o.totalsRowFormula,result:o.totalsRowResult})})}}get model(){return this.table}set model(s){this.table=s}cacheState(){this._cache||(this._cache={ref:this.ref,width:this.width,tableHeight:this.tableHeight})}commit(){if(!this._cache)return;this.validate();const s=c.decodeAddress(this._cache.ref);if(this.ref!==this._cache.ref)for(let n=0;n<this._cache.tableHeight;n++){const e=this.worksheet.getRow(s.row+n);for(let r=0;r<this._cache.width;r++)e.getCell(s.col+r).value=null}else{for(let n=this.tableHeight;n<this._cache.tableHeight;n++){const e=this.worksheet.getRow(s.row+n);for(let r=0;r<this._cache.width;r++)e.getCell(s.col+r).value=null}for(let n=0;n<this.tableHeight;n++){const e=this.worksheet.getRow(s.row+n);for(let r=this.width;r<this._cache.width;r++)e.getCell(s.col+r).value=null}}this.store()}addRow(s,n){this.cacheState(),n===void 0?this.table.rows.push(s):this.table.rows.splice(n,0,s)}removeRows(s){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;this.cacheState(),this.table.rows.splice(s,n)}getColumn(s){const n=this.table.columns[s];return new i(this,n,s)}addColumn(s,n,e){this.cacheState(),e===void 0?(this.table.columns.push(s),this.table.rows.forEach((r,u)=>{r.push(n[u])})):(this.table.columns.splice(e,0,s),this.table.rows.forEach((r,u)=>{r.splice(e,0,n[u])}))}removeColumns(s){let n=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;this.cacheState(),this.table.columns.splice(s,n),this.table.rows.forEach(e=>{e.splice(s,n)})}_assign(s,n,e){this.cacheState(),s[n]=e}get ref(){return this.table.ref}set ref(s){this._assign(this.table,"ref",s)}get name(){return this.table.name}set name(s){this.table.name=s}get displayName(){return this.table.displyName||this.table.name}set displayNamename(s){this.table.displayName=s}get headerRow(){return this.table.headerRow}set headerRow(s){this._assign(this.table,"headerRow",s)}get totalsRow(){return this.table.totalsRow}set totalsRow(s){this._assign(this.table,"totalsRow",s)}get theme(){return this.table.style.name}set theme(s){this.table.style.name=s}get showFirstColumn(){return this.table.style.showFirstColumn}set showFirstColumn(s){this.table.style.showFirstColumn=s}get showLastColumn(){return this.table.style.showLastColumn}set showLastColumn(s){this.table.style.showLastColumn=s}get showRowStripes(){return this.table.style.showRowStripes}set showRowStripes(s){this.table.style.showRowStripes=s}get showColumnStripes(){return this.table.style.showColumnStripes}set showColumnStripes(s){this.table.style.showColumnStripes=s}}},{"../utils/col-cache":19}],13:[function(t,b,m){const c=t("./worksheet"),i=t("./defined-names"),s=t("../xlsx/xlsx"),n=t("../csv/csv");b.exports=class{constructor(){this.category="",this.company="",this.created=new Date,this.description="",this.keywords="",this.manager="",this.modified=this.created,this.properties={},this.calcProperties={},this._worksheets=[],this.subject="",this.title="",this.views=[],this.media=[],this._definedNames=new i}get xlsx(){return this._xlsx||(this._xlsx=new s(this)),this._xlsx}get csv(){return this._csv||(this._csv=new n(this)),this._csv}get nextId(){for(let e=1;e<this._worksheets.length;e++)if(!this._worksheets[e])return e;return this._worksheets.length||1}addWorksheet(e,r){const u=this.nextId;r&&(typeof r=="string"?(console.trace('tabColor argument is now deprecated. Please use workbook.addWorksheet(name, {properties: { tabColor: { argb: "rbg value" } }'),r={properties:{tabColor:{argb:r}}}):(r.argb||r.theme||r.indexed)&&(console.trace("tabColor argument is now deprecated. Please use workbook.addWorksheet(name, {properties: { tabColor: { ... } }"),r={properties:{tabColor:r}}));const a=this._worksheets.reduce((h,d)=>(d&&d.orderNo)>h?d.orderNo:h,0),o=Object.assign({},r,{id:u,name:e,orderNo:a+1,workbook:this}),f=new c(o);return this._worksheets[u]=f,f}removeWorksheetEx(e){delete this._worksheets[e.id]}removeWorksheet(e){const r=this.getWorksheet(e);r&&r.destroy()}getWorksheet(e){return e===void 0?this._worksheets.find(Boolean):typeof e=="number"?this._worksheets[e]:typeof e=="string"?this._worksheets.find(r=>r&&r.name===e):void 0}get worksheets(){return this._worksheets.slice(1).sort((e,r)=>e.orderNo-r.orderNo).filter(Boolean)}eachSheet(e){this.worksheets.forEach(r=>{e(r,r.id)})}get definedNames(){return this._definedNames}clearThemes(){this._themes=void 0}addImage(e){const r=this.media.length;return this.media.push(Object.assign({},e,{type:"image"})),r}getImage(e){return this.media[e]}get model(){return{creator:this.creator||"Unknown",lastModifiedBy:this.lastModifiedBy||"Unknown",lastPrinted:this.lastPrinted,created:this.created,modified:this.modified,properties:this.properties,worksheets:this.worksheets.map(e=>e.model),sheets:this.worksheets.map(e=>e.model).filter(Boolean),definedNames:this._definedNames.model,views:this.views,company:this.company,manager:this.manager,title:this.title,subject:this.subject,keywords:this.keywords,category:this.category,description:this.description,language:this.language,revision:this.revision,contentStatus:this.contentStatus,themes:this._themes,media:this.media,calcProperties:this.calcProperties}}set model(e){this.creator=e.creator,this.lastModifiedBy=e.lastModifiedBy,this.lastPrinted=e.lastPrinted,this.created=e.created,this.modified=e.modified,this.company=e.company,this.manager=e.manager,this.title=e.title,this.subject=e.subject,this.keywords=e.keywords,this.category=e.category,this.description=e.description,this.language=e.language,this.revision=e.revision,this.contentStatus=e.contentStatus,this.properties=e.properties,this.calcProperties=e.calcProperties,this._worksheets=[],e.worksheets.forEach(r=>{const{id:u,name:a,state:o}=r,f=e.sheets&&e.sheets.findIndex(h=>h.id===u);(this._worksheets[u]=new c({id:u,name:a,orderNo:f,state:o,workbook:this})).model=r}),this._definedNames.model=e.definedNames,this.views=e.views,this._themes=e.themes,this.media=e.media||[]}}},{"../csv/csv":1,"../xlsx/xlsx":144,"./defined-names":6,"./worksheet":14}],14:[function(t,b,m){const c=t("../utils/under-dash"),i=t("../utils/col-cache"),s=t("./range"),n=t("./row"),e=t("./column"),r=t("./enums"),u=t("./image"),a=t("./table"),o=t("./data-validations"),f=t("../utils/encryptor"),{copyStyle:h}=t("../utils/copy-style");b.exports=class{constructor(d){d=d||{},this._workbook=d.workbook,this.id=d.id,this.orderNo=d.orderNo,this.name=d.name,this.state=d.state||"visible",this._rows=[],this._columns=null,this._keys={},this._merges={},this.rowBreaks=[],this.properties=Object.assign({},{defaultRowHeight:15,dyDescent:55,outlineLevelCol:0,outlineLevelRow:0},d.properties),this.pageSetup=Object.assign({},{margins:{left:.7,right:.7,top:.75,bottom:.75,header:.3,footer:.3},orientation:"portrait",horizontalDpi:4294967295,verticalDpi:4294967295,fitToPage:!(!d.pageSetup||!d.pageSetup.fitToWidth&&!d.pageSetup.fitToHeight||d.pageSetup.scale),pageOrder:"downThenOver",blackAndWhite:!1,draft:!1,cellComments:"None",errors:"displayed",scale:100,fitToWidth:1,fitToHeight:1,paperSize:void 0,showRowColHeaders:!1,showGridLines:!1,firstPageNumber:void 0,horizontalCentered:!1,verticalCentered:!1,rowBreaks:null,colBreaks:null},d.pageSetup),this.headerFooter=Object.assign({},{differentFirst:!1,differentOddEven:!1,oddHeader:null,oddFooter:null,evenHeader:null,evenFooter:null,firstHeader:null,firstFooter:null},d.headerFooter),this.dataValidations=new o,this.views=d.views||[],this.autoFilter=d.autoFilter||null,this._media=[],this.sheetProtection=null,this.tables={},this.conditionalFormattings=[]}get name(){return this._name}set name(d){if(d===void 0&&(d="sheet"+this.id),this._name!==d){if(typeof d!="string")throw new Error("The name has to be a string.");if(d==="")throw new Error("The name can't be empty.");if(d==="History")throw new Error('The name "History" is protected. Please use a different name.');if(/[*?:/\\[\]]/.test(d))throw new Error(`Worksheet name ${d} cannot include any of the following characters: * ? : \\ / [ ]`);if(/(^')|('$)/.test(d))throw new Error("The first or last character of worksheet name cannot be a single quotation mark: "+d);if(d&&d.length>31&&(console.warn(`Worksheet name ${d} exceeds 31 chars. This will be truncated`),d=d.substring(0,31)),this._workbook._worksheets.find(g=>g&&g.name.toLowerCase()===d.toLowerCase()))throw new Error("Worksheet name already exists: "+d);this._name=d}}get workbook(){return this._workbook}destroy(){this._workbook.removeWorksheetEx(this)}get dimensions(){const d=new s;return this._rows.forEach(g=>{if(g){const p=g.dimensions;p&&d.expand(g.number,p.min,g.number,p.max)}}),d}get columns(){return this._columns}set columns(d){this._headerRowCount=d.reduce((k,C)=>{const T=(C.header?1:C.headers&&C.headers.length)||0;return Math.max(k,T)},0);let g=1;const p=this._columns=[];d.forEach(k=>{const C=new e(this,g++,!1);p.push(C),C.defn=k})}getColumnKey(d){return this._keys[d]}setColumnKey(d,g){this._keys[d]=g}deleteColumnKey(d){delete this._keys[d]}eachColumnKey(d){c.each(this._keys,d)}getColumn(d){if(typeof d=="string"){const g=this._keys[d];if(g)return g;d=i.l2n(d)}if(this._columns||(this._columns=[]),d>this._columns.length){let g=this._columns.length+1;for(;g<=d;)this._columns.push(new e(this,g++))}return this._columns[d-1]}spliceColumns(d,g){const p=this._rows.length;for(var k=arguments.length,C=new Array(k>2?k-2:0),T=2;T<k;T++)C[T-2]=arguments[T];if(C.length>0)for(let N=0;N<p;N++){const q=[d,g];C.forEach(L=>{q.push(L[N]||null)});const W=this.getRow(N+1);W.splice.apply(W,q)}else this._rows.forEach(N=>{N&&N.splice(d,g)});const D=C.length-g,V=d+g,P=this._columns.length;if(D<0)for(let N=d+C.length;N<=P;N++)this.getColumn(N).defn=this.getColumn(N-D).defn;else if(D>0)for(let N=P;N>=V;N--)this.getColumn(N+D).defn=this.getColumn(N).defn;for(let N=d;N<d+C.length;N++)this.getColumn(N).defn=null;this.workbook.definedNames.spliceColumns(this.name,d,g,C.length)}get lastColumn(){return this.getColumn(this.columnCount)}get columnCount(){let d=0;return this.eachRow(g=>{d=Math.max(d,g.cellCount)}),d}get actualColumnCount(){const d=[];let g=0;return this.eachRow(p=>{p.eachCell(k=>{let{col:C}=k;d[C]||(d[C]=!0,g++)})}),g}_commitRow(){}get _lastRowNumber(){const d=this._rows;let g=d.length;for(;g>0&&d[g-1]===void 0;)g--;return g}get _nextRow(){return this._lastRowNumber+1}get lastRow(){if(this._rows.length)return this._rows[this._rows.length-1]}findRow(d){return this._rows[d-1]}findRows(d,g){return this._rows.slice(d-1,d-1+g)}get rowCount(){return this._lastRowNumber}get actualRowCount(){let d=0;return this.eachRow(()=>{d++}),d}getRow(d){let g=this._rows[d-1];return g||(g=this._rows[d-1]=new n(this,d)),g}getRows(d,g){if(g<1)return;const p=[];for(let k=d;k<d+g;k++)p.push(this.getRow(k));return p}addRow(d){let g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"n";const p=this._nextRow,k=this.getRow(p);return k.values=d,this._setStyleOption(p,g[0]==="i"?g:"n"),k}addRows(d){let g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"n";const p=[];return d.forEach(k=>{p.push(this.addRow(k,g))}),p}insertRow(d,g){let p=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"n";return this.spliceRows(d,0,g),this._setStyleOption(d,p),this.getRow(d)}insertRows(d,g){let p=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"n";if(this.spliceRows(d,0,...g),p!=="n")for(let k=0;k<g.length;k++)p[0]==="o"&&this.findRow(g.length+d+k)!==void 0?this._copyStyle(g.length+d+k,d+k,p[1]==="+"):p[0]==="i"&&this.findRow(d-1)!==void 0&&this._copyStyle(d-1,d+k,p[1]==="+");return this.getRows(d,g.length)}_setStyleOption(d){let g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"n";g[0]==="o"&&this.findRow(d+1)!==void 0?this._copyStyle(d+1,d,g[1]==="+"):g[0]==="i"&&this.findRow(d-1)!==void 0&&this._copyStyle(d-1,d,g[1]==="+")}_copyStyle(d,g){let p=arguments.length>2&&arguments[2]!==void 0&&arguments[2];const k=this.getRow(d),C=this.getRow(g);C.style=h(k.style),k.eachCell({includeEmpty:p},(T,D)=>{C.getCell(D).style=h(T.style)}),C.height=k.height}duplicateRow(d,g){let p=arguments.length>2&&arguments[2]!==void 0&&arguments[2];const k=this._rows[d-1],C=new Array(g).fill(k.values);this.spliceRows(d+1,p?0:g,...C);for(let T=0;T<g;T++){const D=this._rows[d+T];D.style=k.style,D.height=k.height,k.eachCell({includeEmpty:!0},(V,P)=>{D.getCell(P).style=V.style})}}spliceRows(d,g){const p=d+g;for(var k=arguments.length,C=new Array(k>2?k-2:0),T=2;T<k;T++)C[T-2]=arguments[T];const D=C.length,V=D-g,P=this._rows.length;let N,q;if(V<0)for(d===P&&(this._rows[P-1]=void 0),N=p;N<=P;N++)if(q=this._rows[N-1],q){const W=this.getRow(N+V);W.values=q.values,W.style=q.style,W.height=q.height,q.eachCell({includeEmpty:!0},(L,A)=>{W.getCell(A).style=L.style}),this._rows[N-1]=void 0}else this._rows[N+V-1]=void 0;else if(V>0)for(N=P;N>=p;N--)if(q=this._rows[N-1],q){const W=this.getRow(N+V);W.values=q.values,W.style=q.style,W.height=q.height,q.eachCell({includeEmpty:!0},(L,A)=>{if(W.getCell(A).style=L.style,L._value.constructor.name==="MergeValue"){const M=this.getRow(L._row._number+D).getCell(A),_=L._value._master,y=this.getRow(_._row._number+D).getCell(_._column._number);M.merge(y)}})}else this._rows[N+V-1]=void 0;for(N=0;N<D;N++){const W=this.getRow(d+N);W.style={},W.values=C[N]}this.workbook.definedNames.spliceRows(this.name,d,g,D)}eachRow(d,g){if(g||(g=d,d=void 0),d&&d.includeEmpty){const p=this._rows.length;for(let k=1;k<=p;k++)g(this.getRow(k),k)}else this._rows.forEach(p=>{p&&p.hasValues&&g(p,p.number)})}getSheetValues(){const d=[];return this._rows.forEach(g=>{g&&(d[g.number]=g.values)}),d}findCell(d,g){const p=i.getAddress(d,g),k=this._rows[p.row-1];return k?k.findCell(p.col):void 0}getCell(d,g){const p=i.getAddress(d,g);return this.getRow(p.row).getCellEx(p)}mergeCells(){for(var d=arguments.length,g=new Array(d),p=0;p<d;p++)g[p]=arguments[p];const k=new s(g);this._mergeCellsInternal(k)}mergeCellsWithoutStyle(){for(var d=arguments.length,g=new Array(d),p=0;p<d;p++)g[p]=arguments[p];const k=new s(g);this._mergeCellsInternal(k,!0)}_mergeCellsInternal(d,g){c.each(this._merges,k=>{if(k.intersects(d))throw new Error("Cannot merge already merged cells")});const p=this.getCell(d.top,d.left);for(let k=d.top;k<=d.bottom;k++)for(let C=d.left;C<=d.right;C++)(k>d.top||C>d.left)&&this.getCell(k,C).merge(p,g);this._merges[p.address]=d}_unMergeMaster(d){const g=this._merges[d.address];if(g){for(let p=g.top;p<=g.bottom;p++)for(let k=g.left;k<=g.right;k++)this.getCell(p,k).unmerge();delete this._merges[d.address]}}get hasMerges(){return c.some(this._merges,Boolean)}unMergeCells(){for(var d=arguments.length,g=new Array(d),p=0;p<d;p++)g[p]=arguments[p];const k=new s(g);for(let C=k.top;C<=k.bottom;C++)for(let T=k.left;T<=k.right;T++){const D=this.findCell(C,T);D&&(D.type===r.ValueType.Merge?this._unMergeMaster(D.master):this._merges[D.address]&&this._unMergeMaster(D))}}fillFormula(d,g,p){let k=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"shared";const C=i.decode(d),{top:T,left:D,bottom:V,right:P}=C,N=P-D+1,q=i.encodeAddress(T,D),W=k==="shared";let L;L=typeof p=="function"?p:Array.isArray(p)?Array.isArray(p[0])?(M,_)=>p[M-T][_-D]:(M,_)=>p[(M-T)*N+(_-D)]:()=>{};let A=!0;for(let M=T;M<=V;M++)for(let _=D;_<=P;_++)A?(this.getCell(M,_).value={shareType:k,formula:g,ref:d,result:L(M,_)},A=!1):this.getCell(M,_).value=W?{sharedFormula:q,result:L(M,_)}:L(M,_)}addImage(d,g){const p={type:"image",imageId:d,range:g};this._media.push(new u(this,p))}getImages(){return this._media.filter(d=>d.type==="image")}addBackgroundImage(d){const g={type:"background",imageId:d};this._media.push(new u(this,g))}getBackgroundImageId(){const d=this._media.find(g=>g.type==="background");return d&&d.imageId}protect(d,g){return new Promise(p=>{this.sheetProtection={sheet:!0},g&&"spinCount"in g&&(g.spinCount=Number.isFinite(g.spinCount)?Math.round(Math.max(0,g.spinCount)):1e5),d&&(this.sheetProtection.algorithmName="SHA-512",this.sheetProtection.saltValue=f.randomBytes(16).toString("base64"),this.sheetProtection.spinCount=g&&"spinCount"in g?g.spinCount:1e5,this.sheetProtection.hashValue=f.convertPasswordToHash(d,"SHA512",this.sheetProtection.saltValue,this.sheetProtection.spinCount)),g&&(this.sheetProtection=Object.assign(this.sheetProtection,g),!d&&"spinCount"in g&&delete this.sheetProtection.spinCount),p()})}unprotect(){this.sheetProtection=null}addTable(d){const g=new a(this,d);return this.tables[d.name]=g,g}getTable(d){return this.tables[d]}removeTable(d){delete this.tables[d]}getTables(){return Object.values(this.tables)}addConditionalFormatting(d){this.conditionalFormattings.push(d)}removeConditionalFormatting(d){typeof d=="number"?this.conditionalFormattings.splice(d,1):this.conditionalFormattings=d instanceof Function?this.conditionalFormattings.filter(d):[]}get tabColor(){return console.trace("worksheet.tabColor property is now deprecated. Please use worksheet.properties.tabColor"),this.properties.tabColor}set tabColor(d){console.trace("worksheet.tabColor property is now deprecated. Please use worksheet.properties.tabColor"),this.properties.tabColor=d}get model(){const d={id:this.id,name:this.name,dataValidations:this.dataValidations.model,properties:this.properties,state:this.state,pageSetup:this.pageSetup,headerFooter:this.headerFooter,rowBreaks:this.rowBreaks,views:this.views,autoFilter:this.autoFilter,media:this._media.map(k=>k.model),sheetProtection:this.sheetProtection,tables:Object.values(this.tables).map(k=>k.model),conditionalFormattings:this.conditionalFormattings};d.cols=e.toModel(this.columns);const g=d.rows=[],p=d.dimensions=new s;return this._rows.forEach(k=>{const C=k&&k.model;C&&(p.expand(C.number,C.min,C.number,C.max),g.push(C))}),d.merges=[],c.each(this._merges,k=>{d.merges.push(k.range)}),d}_parseRows(d){this._rows=[],d.rows.forEach(g=>{const p=new n(this,g.number);this._rows[p.number-1]=p,p.model=g})}_parseMergeCells(d){c.each(d.mergeCells,g=>{this.mergeCellsWithoutStyle(g)})}set model(d){this.name=d.name,this._columns=e.fromModel(this,d.cols),this._parseRows(d),this._parseMergeCells(d),this.dataValidations=new o(d.dataValidations),this.properties=d.properties,this.pageSetup=d.pageSetup,this.headerFooter=d.headerFooter,this.views=d.views,this.autoFilter=d.autoFilter,this._media=d.media.map(g=>new u(this,g)),this.sheetProtection=d.sheetProtection,this.tables=d.tables.reduce((g,p)=>{const k=new a;return k.model=p,g[p.name]=k,g},{}),this.conditionalFormattings=d.conditionalFormattings}}},{"../utils/col-cache":19,"../utils/copy-style":20,"../utils/encryptor":21,"../utils/under-dash":26,"./column":4,"./data-validations":5,"./enums":7,"./image":8,"./range":10,"./row":11,"./table":12}],15:[function(t,b,m){t("core-js/modules/es.promise"),t("core-js/modules/es.promise.finally"),t("core-js/modules/es.object.assign"),t("core-js/modules/es.object.keys"),t("core-js/modules/es.object.values"),t("core-js/modules/es.symbol"),t("core-js/modules/es.symbol.async-iterator"),t("core-js/modules/es.array.iterator"),t("core-js/modules/es.array.includes"),t("core-js/modules/es.array.find-index"),t("core-js/modules/es.array.find"),t("core-js/modules/es.string.from-code-point"),t("core-js/modules/es.string.includes"),t("core-js/modules/es.number.is-nan"),t("regenerator-runtime/runtime");const c={Workbook:t("./doc/workbook")},i=t("./doc/enums");Object.keys(i).forEach(s=>{c[s]=i[s]}),b.exports=c},{"./doc/enums":7,"./doc/workbook":13,"core-js/modules/es.array.find":359,"core-js/modules/es.array.find-index":358,"core-js/modules/es.array.includes":360,"core-js/modules/es.array.iterator":361,"core-js/modules/es.number.is-nan":363,"core-js/modules/es.object.assign":364,"core-js/modules/es.object.keys":366,"core-js/modules/es.object.values":367,"core-js/modules/es.promise":372,"core-js/modules/es.promise.finally":371,"core-js/modules/es.string.from-code-point":376,"core-js/modules/es.string.includes":377,"core-js/modules/es.symbol":381,"core-js/modules/es.symbol.async-iterator":378,"regenerator-runtime/runtime":492}],16:[function(t,b,m){const c=typeof TextDecoder>"u"?null:new TextDecoder("utf-8");m.bufferToString=function(i){return typeof i=="string"?i:c?c.decode(i):i.toString()}},{}],17:[function(t,b,m){const c=typeof TextEncoder>"u"?null:new TextEncoder("utf-8"),{Buffer:i}=t("buffer");m.stringToBuffer=function(s){return typeof s!="string"?s:c?i.from(c.encode(s).buffer):i.from(s)}},{buffer:220}],18:[function(t,b,m){const c=t("./under-dash"),i=t("./col-cache");b.exports=class{constructor(s){this.template=s,this.sheets={}}addCell(s){this.addCellEx(i.decodeEx(s))}getCell(s){return this.findCellEx(i.decodeEx(s),!0)}findCell(s){return this.findCellEx(i.decodeEx(s),!1)}findCellAt(s,n,e){const r=this.sheets[s],u=r&&r[n];return u&&u[e]}addCellEx(s){if(s.top)for(let n=s.top;n<=s.bottom;n++)for(let e=s.left;e<=s.right;e++)this.getCellAt(s.sheetName,n,e);else this.findCellEx(s,!0)}getCellEx(s){return this.findCellEx(s,!0)}findCellEx(s,n){const e=this.findSheet(s,n),r=this.findSheetRow(e,s,n);return this.findRowCell(r,s,n)}getCellAt(s,n,e){const r=this.sheets[s]||(this.sheets[s]=[]),u=r[n]||(r[n]=[]);return u[e]||(u[e]={sheetName:s,address:i.n2l(e)+n,row:n,col:e})}removeCellEx(s){const n=this.findSheet(s);if(!n)return;const e=this.findSheetRow(n,s);e&&delete e[s.col]}forEachInSheet(s,n){const e=this.sheets[s];e&&e.forEach((r,u)=>{r&&r.forEach((a,o)=>{a&&n(a,u,o)})})}forEach(s){c.each(this.sheets,(n,e)=>{this.forEachInSheet(e,s)})}map(s){const n=[];return this.forEach(e=>{n.push(s(e))}),n}findSheet(s,n){const e=s.sheetName;return this.sheets[e]?this.sheets[e]:n?this.sheets[e]=[]:void 0}findSheetRow(s,n,e){const{row:r}=n;return s&&s[r]?s[r]:e?s[r]=[]:void 0}findRowCell(s,n,e){const{col:r}=n;return s&&s[r]?s[r]:e?s[r]=this.template?Object.assign(n,JSON.parse(JSON.stringify(this.template))):n:void 0}spliceRows(s,n,e,r){const u=this.sheets[s];if(u){const a=[];for(let o=0;o<r;o++)a.push([]);u.splice(n,e,...a)}}spliceColumns(s,n,e,r){const u=this.sheets[s];if(u){const a=[];for(let o=0;o<r;o++)a.push(null);c.each(u,o=>{o.splice(n,e,...a)})}}}},{"./col-cache":19,"./under-dash":26}],19:[function(t,b,m){const c=/^[A-Z]+\d+$/,i={_dictionary:["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"],_l2nFill:0,_l2n:{},_n2l:[],_level:s=>s<=26?1:s<=676?2:3,_fill(s){let n,e,r,u,a,o=1;if(s>=4)throw new Error("Out of bounds. Excel supports columns from 1 to 16384");if(this._l2nFill<1&&s>=1){for(;o<=26;)n=this._dictionary[o-1],this._n2l[o]=n,this._l2n[n]=o,o++;this._l2nFill=1}if(this._l2nFill<2&&s>=2){for(o=27;o<=702;)e=o-27,r=e%26,u=Math.floor(e/26),n=this._dictionary[u]+this._dictionary[r],this._n2l[o]=n,this._l2n[n]=o,o++;this._l2nFill=2}if(this._l2nFill<3&&s>=3){for(o=703;o<=16384;)e=o-703,r=e%26,u=Math.floor(e/26)%26,a=Math.floor(e/676),n=this._dictionary[a]+this._dictionary[u]+this._dictionary[r],this._n2l[o]=n,this._l2n[n]=o,o++;this._l2nFill=3}},l2n(s){if(this._l2n[s]||this._fill(s.length),!this._l2n[s])throw new Error("Out of bounds. Invalid column letter: "+s);return this._l2n[s]},n2l(s){if(s<1||s>16384)throw new Error(s+" is out of bounds. Excel supports columns from 1 to 16384");return this._n2l[s]||this._fill(this._level(s)),this._n2l[s]},_hash:{},validateAddress(s){if(!c.test(s))throw new Error("Invalid Address: "+s);return!0},decodeAddress(s){const n=s.length<5&&this._hash[s];if(n)return n;let e=!1,r="",u=0,a=!1,o="",f=0;for(let d,g=0;g<s.length;g++)if(d=s.charCodeAt(g),!a&&d>=65&&d<=90)e=!0,r+=s[g],u=26*u+d-64;else if(d>=48&&d<=57)a=!0,o+=s[g],f=10*f+d-48;else if(a&&e&&d!==36)break;if(e){if(u>16384)throw new Error("Out of bounds. Invalid column letter: "+r)}else u=void 0;a||(f=void 0);const h={address:s=r+o,col:u,row:f,$col$row:`$${r}$${o}`};return u<=100&&f<=100&&(this._hash[s]=h,this._hash[h.$col$row]=h),h},getAddress(s,n){if(n){const e=this.n2l(n)+s;return this.decodeAddress(e)}return this.decodeAddress(s)},decode(s){const n=s.split(":");if(n.length===2){const e=this.decodeAddress(n[0]),r=this.decodeAddress(n[1]),u={top:Math.min(e.row,r.row),left:Math.min(e.col,r.col),bottom:Math.max(e.row,r.row),right:Math.max(e.col,r.col)};return u.tl=this.n2l(u.left)+u.top,u.br=this.n2l(u.right)+u.bottom,u.dimensions=`${u.tl}:${u.br}`,u}return this.decodeAddress(s)},decodeEx(s){const n=s.match(/(?:(?:(?:'((?:[^']|'')*)')|([^'^ !]*))!)?(.*)/),e=n[1]||n[2],r=n[3],u=r.split(":");if(u.length>1){let o=this.decodeAddress(u[0]),f=this.decodeAddress(u[1]);const h=Math.min(o.row,f.row),d=Math.min(o.col,f.col),g=Math.max(o.row,f.row),p=Math.max(o.col,f.col);return o=this.n2l(d)+h,f=this.n2l(p)+g,{top:h,left:d,bottom:g,right:p,sheetName:e,tl:{address:o,col:d,row:h,$col$row:`$${this.n2l(d)}$${h}`,sheetName:e},br:{address:f,col:p,row:g,$col$row:`$${this.n2l(p)}$${g}`,sheetName:e},dimensions:`${o}:${f}`}}if(r.startsWith("#"))return e?{sheetName:e,error:r}:{error:r};const a=this.decodeAddress(r);return e?{sheetName:e,...a}:a},encodeAddress:(s,n)=>i.n2l(n)+s,encode(){switch(arguments.length){case 2:return i.encodeAddress(arguments[0],arguments[1]);case 4:return`${i.encodeAddress(arguments[0],arguments[1])}:${i.encodeAddress(arguments[2],arguments[3])}`;default:throw new Error("Can only encode with 2 or 4 arguments")}},inRange(s,n){const[e,r,,u,a]=s,[o,f]=n;return o>=e&&o<=u&&f>=r&&f<=a}};b.exports=i},{}],20:[function(t,b,m){const c=(s,n)=>({...s,...n.reduce((e,r)=>(s[r]&&(e[r]={...s[r]}),e),{})}),i=function(s,n,e){let r=arguments.length>3&&arguments[3]!==void 0?arguments[3]:[];s[e]&&(n[e]=c(s[e],r))};m.copyStyle=s=>{if(!s)return s;if(n=s,Object.keys(n).length===0)return{};var n;const e={...s};return i(s,e,"font",["color"]),i(s,e,"alignment"),i(s,e,"protection"),s.border&&(i(s,e,"border"),i(s.border,e.border,"top",["color"]),i(s.border,e.border,"left",["color"]),i(s.border,e.border,"bottom",["color"]),i(s.border,e.border,"right",["color"]),i(s.border,e.border,"diagonal",["color"])),s.fill&&(i(s,e,"fill",["fgColor","bgColor","center"]),s.fill.stops&&(e.fill.stops=s.fill.stops.map(r=>c(r,["color"])))),e}},{}],21:[function(t,b,m){(function(c){(function(){const i=t("crypto"),s={hash(n){const e=i.createHash(n);for(var r=arguments.length,u=new Array(r>1?r-1:0),a=1;a<r;a++)u[a-1]=arguments[a];return e.update(c.concat(u)),e.digest()},convertPasswordToHash(n,e,r,u){if(e=e.toLowerCase(),i.getHashes().indexOf(e)<0)throw new Error(`Hash algorithm '${e}' not supported!`);const a=c.from(n,"utf16le");let o=this.hash(e,c.from(r,"base64"),a);for(let f=0;f<u;f++){const h=c.alloc(4);h.writeUInt32LE(f,0),o=this.hash(e,o,h)}return o.toString("base64")},randomBytes:n=>i.randomBytes(n)};b.exports=s}).call(this)}).call(this,t("buffer").Buffer)},{buffer:220,crypto:390}],22:[function(t,b,m){const{SaxesParser:c}=t("saxes"),{PassThrough:i}=t("readable-stream"),{bufferToString:s}=t("./browser-buffer-decode");b.exports=async function*(n){n.pipe&&!n[Symbol.asyncIterator]&&(n=n.pipe(new i));const e=new c;let r;e.on("error",a=>{r=a});let u=[];e.on("opentag",a=>u.push({eventType:"opentag",value:a})),e.on("text",a=>u.push({eventType:"text",value:a})),e.on("closetag",a=>u.push({eventType:"closetag",value:a}));for await(const a of n){if(e.write(s(a)),r)throw r;yield u,u=[]}}},{"./browser-buffer-decode":16,"readable-stream":491,saxes:496}],23:[function(t,b,m){const c=t("./col-cache"),i=/(([a-z_\-0-9]*)!)?([a-z0-9_$]{2,})([(])?/gi,s=/^([$])?([a-z]+)([$])?([1-9][0-9]*)$/i;b.exports={slideFormula:function(n,e,r){const u=c.decode(e),a=c.decode(r);return n.replace(i,(o,f,h,d,g)=>{if(g)return o;const p=s.exec(d);if(p){const k=p[1],C=p[2].toUpperCase(),T=p[3],D=p[4];if(C.length>3||C.length===3&&C>"XFD")return o;let V=c.l2n(C),P=parseInt(D,10);return k||(V+=a.col-u.col),T||(P+=a.row-u.row),(f||"")+(k||"")+c.n2l(V)+(T||"")+P}return o})}}},{"./col-cache":19}],24:[function(t,b,m){(function(c,i){(function(){const s=t("readable-stream"),n=t("./utils"),e=t("./string-buf");class r{constructor(d,g){this._data=d,this._encoding=g}get length(){return this.toBuffer().length}copy(d,g,p,k){return this.toBuffer().copy(d,g,p,k)}toBuffer(){return this._buffer||(this._buffer=i.from(this._data,this._encoding)),this._buffer}}class u{constructor(d){this._data=d}get length(){return this._data.length}copy(d,g,p,k){return this._data._buf.copy(d,g,p,k)}toBuffer(){return this._data.toBuffer()}}class a{constructor(d){this._data=d}get length(){return this._data.length}copy(d,g,p,k){this._data.copy(d,g,p,k)}toBuffer(){return this._data}}class o{constructor(d){this.size=d,this.buffer=i.alloc(d),this.iRead=0,this.iWrite=0}toBuffer(){if(this.iRead===0&&this.iWrite===this.size)return this.buffer;const d=i.alloc(this.iWrite-this.iRead);return this.buffer.copy(d,0,this.iRead,this.iWrite),d}get length(){return this.iWrite-this.iRead}get eod(){return this.iRead===this.iWrite}get full(){return this.iWrite===this.size}read(d){let g;return d===0?null:d===void 0||d>=this.length?(g=this.toBuffer(),this.iRead=this.iWrite,g):(g=i.alloc(d),this.buffer.copy(g,0,this.iRead,d),this.iRead+=d,g)}write(d,g,p){const k=Math.min(p,this.size-this.iWrite);return d.copy(this.buffer,this.iWrite,g,g+k),this.iWrite+=k,k}}const f=function(h){h=h||{},this.bufSize=h.bufSize||1048576,this.buffers=[],this.batch=h.batch||!1,this.corked=!1,this.inPos=0,this.outPos=0,this.pipes=[],this.paused=!1,this.encoding=null};n.inherits(f,s.Duplex,{toBuffer(){switch(this.buffers.length){case 0:return null;case 1:return this.buffers[0].toBuffer();default:return i.concat(this.buffers.map(h=>h.toBuffer()))}},_getWritableBuffer(){if(this.buffers.length){const d=this.buffers[this.buffers.length-1];if(!d.full)return d}const h=new o(this.bufSize);return this.buffers.push(h),h},async _pipe(h){await Promise.all(this.pipes.map(function(d){return new Promise(g=>{d.write(h.toBuffer(),()=>{g()})})}))},_writeToBuffers(h){let d=0;const g=h.length;for(;d<g;)d+=this._getWritableBuffer().write(h,d,g-d)},async write(h,d,g){let p;if(d instanceof Function&&(g=d,d="utf8"),g=g||n.nop,h instanceof e)p=new u(h);else if(h instanceof i)p=new a(h);else{if(!(typeof h=="string"||h instanceof String||h instanceof ArrayBuffer))throw new Error("Chunk must be one of type String, Buffer or StringBuf.");p=new r(h,d)}if(this.pipes.length)if(this.batch)for(this._writeToBuffers(p);!this.corked&&this.buffers.length>1;)this._pipe(this.buffers.shift());else this.corked?(this._writeToBuffers(p),c.nextTick(g)):(await this._pipe(p),g());else this.paused||this.emit("data",p.toBuffer()),this._writeToBuffers(p),this.emit("readable");return!0},cork(){this.corked=!0},_flush(){if(this.pipes.length)for(;this.buffers.length;)this._pipe(this.buffers.shift())},uncork(){this.corked=!1,this._flush()},end(h,d,g){const p=k=>{k?g(k):(this._flush(),this.pipes.forEach(C=>{C.end()}),this.emit("finish"))};h?this.write(h,d,p):p()},read(h){let d;if(h){for(d=[];h&&this.buffers.length&&!this.buffers[0].eod;){const g=this.buffers[0],p=g.read(h);h-=p.length,d.push(p),g.eod&&g.full&&this.buffers.shift()}return i.concat(d)}return d=this.buffers.map(g=>g.toBuffer()).filter(Boolean),this.buffers=[],i.concat(d)},setEncoding(h){this.encoding=h},pause(){this.paused=!0},resume(){this.paused=!1},isPaused(){return!!this.paused},pipe(h){this.pipes.push(h),!this.paused&&this.buffers.length&&this.end()},unpipe(h){this.pipes=this.pipes.filter(d=>d!==h)},unshift(){throw new Error("Not Implemented")},wrap(){throw new Error("Not Implemented")}}),b.exports=f}).call(this)}).call(this,t("_process"),t("buffer").Buffer)},{"./string-buf":25,"./utils":27,_process:467,buffer:220,"readable-stream":491}],25:[function(t,b,m){(function(c){(function(){b.exports=class{constructor(i){this._buf=c.alloc(i&&i.size||16384),this._encoding=i&&i.encoding||"utf8",this._inPos=0,this._buffer=void 0}get length(){return this._inPos}get capacity(){return this._buf.length}get buffer(){return this._buf}toBuffer(){return this._buffer||(this._buffer=c.alloc(this.length),this._buf.copy(this._buffer,0,0,this.length)),this._buffer}reset(i){i=i||0,this._buffer=void 0,this._inPos=i}_grow(i){let s=2*this._buf.length;for(;s<i;)s*=2;const n=c.alloc(s);this._buf.copy(n,0),this._buf=n}addText(i){this._buffer=void 0;let s=this._inPos+this._buf.write(i,this._inPos,this._encoding);for(;s>=this._buf.length-4;)this._grow(this._inPos+i.length),s=this._inPos+this._buf.write(i,this._inPos,this._encoding);this._inPos=s}addStringBuf(i){i.length&&(this._buffer=void 0,this.length+i.length>this.capacity&&this._grow(this.length+i.length),i._buf.copy(this._buf,this._inPos,0,i.length),this._inPos+=i.length)}}}).call(this)}).call(this,t("buffer").Buffer)},{buffer:220}],26:[function(t,b,m){const{toString:c}=Object.prototype,i=/["&<>]/,s={each:function(n,e){n&&(Array.isArray(n)?n.forEach(e):Object.keys(n).forEach(r=>{e(n[r],r)}))},some:function(n,e){return!!n&&(Array.isArray(n)?n.some(e):Object.keys(n).some(r=>e(n[r],r)))},every:function(n,e){return!n||(Array.isArray(n)?n.every(e):Object.keys(n).every(r=>e(n[r],r)))},map:function(n,e){return n?Array.isArray(n)?n.map(e):Object.keys(n).map(r=>e(n[r],r)):[]},keyBy:(n,e)=>n.reduce((r,u)=>(r[u[e]]=u,r),{}),isEqual:function(n,e){const r=typeof n,u=typeof e,a=Array.isArray(n),o=Array.isArray(e);let f;if(r!==u)return!1;switch(typeof n){case"object":if(a||o)return!(!a||!o)&&n.length===e.length&&n.every((h,d)=>{const g=e[d];return s.isEqual(h,g)});if(n===null||e===null)return n===e;if(f=Object.keys(n),Object.keys(e).length!==f.length)return!1;for(const h of f)if(!e.hasOwnProperty(h))return!1;return s.every(n,(h,d)=>{const g=e[d];return s.isEqual(h,g)});default:return n===e}},escapeHtml(n){const e=i.exec(n);if(!e)return n;let r="",u="",a=0,o=e.index;for(;o<n.length;o++){switch(n.charAt(o)){case'"':u="&quot;";break;case"&":u="&amp;";break;case"'":u="&apos;";break;case"<":u="&lt;";break;case">":u="&gt;";break;default:continue}a!==o&&(r+=n.substring(a,o)),a=o+1,r+=u}return a!==o?r+n.substring(a,o):r},strcmp:(n,e)=>n<e?-1:n>e?1:0,isUndefined:n=>c.call(n)==="[object Undefined]",isObject:n=>c.call(n)==="[object Object]",deepMerge(){const n=arguments[0]||{},{length:e}=arguments;let r,u,a;function o(f,h){r=n[h],a=Array.isArray(f),s.isObject(f)||a?(a?(a=!1,u=r&&Array.isArray(r)?r:[]):u=r&&s.isObject(r)?r:{},n[h]=s.deepMerge(u,f)):s.isUndefined(f)||(n[h]=f)}for(let f=0;f<e;f++)s.each(arguments[f],o);return n}};b.exports=s},{}],27:[function(t,b,m){(function(c,i){(function(){const s=t("fs"),n=/[<>&'"\x7F\x00-\x08\x0B-\x0C\x0E-\x1F]/,e={nop(){},promiseImmediate:r=>new Promise(u=>{c.setImmediate?i(()=>{u(r)}):setTimeout(()=>{u(r)},1)}),inherits:function(r,u,a,o){r.super_=u,o||(o=a,a=null),a&&Object.keys(a).forEach(h=>{Object.defineProperty(r,h,Object.getOwnPropertyDescriptor(a,h))});const f={constructor:{value:r,enumerable:!1,writable:!1,configurable:!0}};o&&Object.keys(o).forEach(h=>{f[h]=Object.getOwnPropertyDescriptor(o,h)}),r.prototype=Object.create(u.prototype,f)},dateToExcel:(r,u)=>25569+r.getTime()/864e5-(u?1462:0),excelToDate(r,u){const a=Math.round(24*(r-25569+(u?1462:0))*3600*1e3);return new Date(a)},parsePath(r){const u=r.lastIndexOf("/");return{path:r.substring(0,u),name:r.substring(u+1)}},getRelsPath(r){const u=e.parsePath(r);return`${u.path}/_rels/${u.name}.rels`},xmlEncode(r){const u=n.exec(r);if(!u)return r;let a="",o="",f=0,h=u.index;for(;h<r.length;h++){const d=r.charCodeAt(h);switch(d){case 34:o="&quot;";break;case 38:o="&amp;";break;case 39:o="&apos;";break;case 60:o="&lt;";break;case 62:o="&gt;";break;case 127:o="";break;default:if(d<=31&&(d<=8||d>=11&&d!==13)){o="";break}continue}f!==h&&(a+=r.substring(f,h)),f=h+1,o&&(a+=o)}return f!==h?a+r.substring(f,h):a},xmlDecode:r=>r.replace(/&([a-z]*);/g,u=>{switch(u){case"&lt;":return"<";case"&gt;":return">";case"&amp;":return"&";case"&apos;":return"'";case"&quot;":return'"';default:return u}}),validInt(r){const u=parseInt(r,10);return Number.isNaN(u)?0:u},isDateFmt(r){return r?(r=(r=r.replace(/\[[^\]]*]/g,"")).replace(/"[^"]*"/g,"")).match(/[ymdhMsb]+/)!==null:!1},fs:{exists:r=>new Promise(u=>{s.access(r,s.constants.F_OK,a=>{u(!a)})})},toIsoDateString:r=>r.toIsoString().subsstr(0,10),parseBoolean:r=>r===!0||r==="true"||r===1||r==="1"};b.exports=e}).call(this)}).call(this,typeof ut<"u"?ut:typeof self<"u"?self:typeof window<"u"?window:{},t("timers").setImmediate)},{fs:216,timers:523}],28:[function(t,b,m){const c=t("./under-dash"),i=t("./utils");function s(r,u,a){r.push(` ${u}="${i.xmlEncode(a.toString())}"`)}function n(r,u){if(u){const a=[];c.each(u,(o,f)=>{o!==void 0&&s(a,f,o)}),r.push(a.join(""))}}class e{constructor(){this._xml=[],this._stack=[],this._rollbacks=[]}get tos(){return this._stack.length?this._stack[this._stack.length-1]:void 0}get cursor(){return this._xml.length}openXml(u){const a=this._xml;a.push("<?xml"),n(a,u),a.push(`?>
2
2
  `)}openNode(u,a){const o=this.tos,f=this._xml;o&&this.open&&f.push(">"),this._stack.push(u),f.push("<"),f.push(u),n(f,a),this.leaf=!0,this.open=!0}addAttribute(u,a){if(!this.open)throw new Error("Cannot write attributes to node if it is not open");a!==void 0&&s(this._xml,u,a)}addAttributes(u){if(!this.open)throw new Error("Cannot write attributes to node if it is not open");n(this._xml,u)}writeText(u){const a=this._xml;this.open&&(a.push(">"),this.open=!1),this.leaf=!1,a.push(i.xmlEncode(u.toString()))}writeXml(u){this.open&&(this._xml.push(">"),this.open=!1),this.leaf=!1,this._xml.push(u)}closeNode(){const u=this._stack.pop(),a=this._xml;this.leaf?a.push("/>"):(a.push("</"),a.push(u),a.push(">")),this.open=!1,this.leaf=!1}leafNode(u,a,o){this.openNode(u,a),o!==void 0&&this.writeText(o),this.closeNode()}closeAll(){for(;this._stack.length;)this.closeNode()}addRollback(){return this._rollbacks.push({xml:this._xml.length,stack:this._stack.length,leaf:this.leaf,open:this.open}),this.cursor}commit(){this._rollbacks.pop()}rollback(){const u=this._rollbacks.pop();this._xml.length>u.xml&&this._xml.splice(u.xml,this._xml.length-u.xml),this._stack.length>u.stack&&this._stack.splice(u.stack,this._stack.length-u.stack),this.leaf=u.leaf,this.open=u.open}get xml(){return this.closeAll(),this._xml.join("")}}e.StdDocAttributes={version:"1.0",encoding:"UTF-8",standalone:"yes"},b.exports=e},{"./under-dash":26,"./utils":27}],29:[function(t,b,m){(function(c){(function(){const i=t("events"),s=t("jszip"),n=t("./stream-buf"),{stringToBuffer:e}=t("./browser-buffer-encode");class r extends i.EventEmitter{constructor(a){super(),this.options=Object.assign({type:"nodebuffer",compression:"DEFLATE"},a),this.zip=new s,this.stream=new n}append(a,o){o.hasOwnProperty("base64")&&o.base64?this.zip.file(o.name,a,{base64:!0}):(c.browser&&typeof a=="string"&&(a=e(a)),this.zip.file(o.name,a))}async finalize(){const a=await this.zip.generateAsync(this.options);this.stream.end(a),this.emit("finish")}read(a){return this.stream.read(a)}setEncoding(a){return this.stream.setEncoding(a)}pause(){return this.stream.pause()}resume(){return this.stream.resume()}isPaused(){return this.stream.isPaused()}pipe(a,o){return this.stream.pipe(a,o)}unpipe(a){return this.stream.unpipe(a)}unshift(a){return this.stream.unshift(a)}wrap(a){return this.stream.wrap(a)}}b.exports={ZipWriter:r}}).call(this)}).call(this,t("_process"))},{"./browser-buffer-encode":17,"./stream-buf":24,_process:467,events:422,jszip:441}],30:[function(t,b,m){b.exports={0:{f:"General"},1:{f:"0"},2:{f:"0.00"},3:{f:"#,##0"},4:{f:"#,##0.00"},9:{f:"0%"},10:{f:"0.00%"},11:{f:"0.00E+00"},12:{f:"# ?/?"},13:{f:"# ??/??"},14:{f:"mm-dd-yy"},15:{f:"d-mmm-yy"},16:{f:"d-mmm"},17:{f:"mmm-yy"},18:{f:"h:mm AM/PM"},19:{f:"h:mm:ss AM/PM"},20:{f:"h:mm"},21:{f:"h:mm:ss"},22:{f:'m/d/yy "h":mm'},27:{"zh-tw":"[$-404]e/m/d","zh-cn":'yyyy"年"m"月"',"ja-jp":"[$-411]ge.m.d","ko-kr":'yyyy"年" mm"月" dd"日"'},28:{"zh-tw":'[$-404]e"年"m"月"d"日"',"zh-cn":'m"月"d"日"',"ja-jp":'[$-411]ggge"年"m"月"d"日"',"ko-kr":"mm-dd"},29:{"zh-tw":'[$-404]e"年"m"月"d"日"',"zh-cn":'m"月"d"日"',"ja-jp":'[$-411]ggge"年"m"月"d"日"',"ko-kr":"mm-dd"},30:{"zh-tw":"m/d/yy ","zh-cn":"m-d-yy","ja-jp":"m/d/yy","ko-kr":"mm-dd-yy"},31:{"zh-tw":'yyyy"年"m"月"d"日"',"zh-cn":'yyyy"年"m"月"d"日"',"ja-jp":'yyyy"年"m"月"d"日"',"ko-kr":'yyyy"년" mm"월" dd"일"'},32:{"zh-tw":'hh"時"mm"分"',"zh-cn":'h"时"mm"分"',"ja-jp":'h"時"mm"分"',"ko-kr":'h"시" mm"분"'},33:{"zh-tw":'hh"時"mm"分"ss"秒"',"zh-cn":'h"时"mm"分"ss"秒"',"ja-jp":'h"時"mm"分"ss"秒"',"ko-kr":'h"시" mm"분" ss"초"'},34:{"zh-tw":'上午/下午 hh"時"mm"分"',"zh-cn":'上午/下午 h"时"mm"分"',"ja-jp":'yyyy"年"m"月"',"ko-kr":"yyyy-mm-dd"},35:{"zh-tw":'上午/下午 hh"時"mm"分"ss"秒"',"zh-cn":'上午/下午 h"时"mm"分"ss"秒"',"ja-jp":'m"月"d"日"',"ko-kr":"yyyy-mm-dd"},36:{"zh-tw":"[$-404]e/m/d","zh-cn":'yyyy"年"m"月"',"ja-jp":"[$-411]ge.m.d","ko-kr":'yyyy"年" mm"月" dd"日"'},37:{f:"#,##0 ;(#,##0)"},38:{f:"#,##0 ;[Red](#,##0)"},39:{f:"#,##0.00 ;(#,##0.00)"},40:{f:"#,##0.00 ;[Red](#,##0.00)"},45:{f:"mm:ss"},46:{f:"[h]:mm:ss"},47:{f:"mmss.0"},48:{f:"##0.0E+0"},49:{f:"@"},50:{"zh-tw":"[$-404]e/m/d","zh-cn":'yyyy"年"m"月"',"ja-jp":"[$-411]ge.m.d","ko-kr":'yyyy"年" mm"月" dd"日"'},51:{"zh-tw":'[$-404]e"年"m"月"d"日"',"zh-cn":'m"月"d"日"',"ja-jp":'[$-411]ggge"年"m"月"d"日"',"ko-kr":"mm-dd"},52:{"zh-tw":'上午/下午 hh"時"mm"分"',"zh-cn":'yyyy"年"m"月"',"ja-jp":'yyyy"年"m"月"',"ko-kr":"yyyy-mm-dd"},53:{"zh-tw":'上午/下午 hh"時"mm"分"ss"秒"',"zh-cn":'m"月"d"日"',"ja-jp":'m"月"d"日"',"ko-kr":"yyyy-mm-dd"},54:{"zh-tw":'[$-404]e"年"m"月"d"日"',"zh-cn":'m"月"d"日"',"ja-jp":'[$-411]ggge"年"m"月"d"日"',"ko-kr":"mm-dd"},55:{"zh-tw":'上午/下午 hh"時"mm"分"',"zh-cn":'上午/下午 h"时"mm"分"',"ja-jp":'yyyy"年"m"月"',"ko-kr":"yyyy-mm-dd"},56:{"zh-tw":'上午/下午 hh"時"mm"分"ss"秒"',"zh-cn":'上午/下午 h"时"mm"分"ss"秒"',"ja-jp":'m"月"d"日"',"ko-kr":"yyyy-mm-dd"},57:{"zh-tw":"[$-404]e/m/d","zh-cn":'yyyy"年"m"月"',"ja-jp":"[$-411]ge.m.d","ko-kr":'yyyy"年" mm"月" dd"日"'},58:{"zh-tw":'[$-404]e"年"m"月"d"日"',"zh-cn":'m"月"d"日"',"ja-jp":'[$-411]ggge"年"m"月"d"日"',"ko-kr":"mm-dd"},59:{"th-th":"t0"},60:{"th-th":"t0.00"},61:{"th-th":"t#,##0"},62:{"th-th":"t#,##0.00"},67:{"th-th":"t0%"},68:{"th-th":"t0.00%"},69:{"th-th":"t# ?/?"},70:{"th-th":"t# ??/??"},81:{"th-th":"d/m/bb"}}},{}],31:[function(t,b,m){b.exports={OfficeDocument:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/officeDocument",Worksheet:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/worksheet",CalcChain:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/calcChain",SharedStrings:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/sharedStrings",Styles:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/styles",Theme:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/theme",Hyperlink:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/hyperlink",Image:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/image",CoreProperties:"http://schemas.openxmlformats.org/package/2006/relationships/metadata/core-properties",ExtenderProperties:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/extended-properties",Comments:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/comments",VmlDrawing:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/vmlDrawing",Table:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/table"}},{}],32:[function(t,b,m){const c=t("../../utils/parse-sax"),i=t("../../utils/xml-stream");class s{prepare(){}render(){}parseOpen(e){}parseText(e){}parseClose(e){}reconcile(e,r){}reset(){this.model=null,this.map&&Object.values(this.map).forEach(e=>{e instanceof s?e.reset():e.xform&&e.xform.reset()})}mergeModel(e){this.model=Object.assign(this.model||{},e)}async parse(e){for await(const r of e)for(const{eventType:u,value:a}of r)if(u==="opentag")this.parseOpen(a);else if(u==="text")this.parseText(a);else if(u==="closetag"&&!this.parseClose(a.name))return this.model;return this.model}async parseStream(e){return this.parse(c(e))}get xml(){return this.toXml(this.model)}toXml(e){const r=new i;return this.render(r,e),r.xml}static toAttribute(e,r){let u=arguments.length>2&&arguments[2]!==void 0&&arguments[2];if(e===void 0){if(u)return r}else if(u||e!==r)return e.toString()}static toStringAttribute(e,r){let u=arguments.length>2&&arguments[2]!==void 0&&arguments[2];return s.toAttribute(e,r,u)}static toStringValue(e,r){return e===void 0?r:e}static toBoolAttribute(e,r){let u=arguments.length>2&&arguments[2]!==void 0&&arguments[2];if(e===void 0){if(u)return r}else if(u||e!==r)return e?"1":"0"}static toBoolValue(e,r){return e===void 0?r:e==="1"}static toIntAttribute(e,r){let u=arguments.length>2&&arguments[2]!==void 0&&arguments[2];return s.toAttribute(e,r,u)}static toIntValue(e,r){return e===void 0?r:parseInt(e,10)}static toFloatAttribute(e,r){let u=arguments.length>2&&arguments[2]!==void 0&&arguments[2];return s.toAttribute(e,r,u)}static toFloatValue(e,r){return e===void 0?r:parseFloat(e)}}b.exports=s},{"../../utils/parse-sax":22,"../../utils/xml-stream":28}],33:[function(t,b,m){const c=t("../base-xform"),i=t("../../../utils/col-cache");function s(e){try{return i.decodeEx(e),!0}catch{return!1}}function n(e){const r=[];let u=!1,a="";return e.split(",").forEach(o=>{if(!o)return;const f=(o.match(/'/g)||[]).length;if(!f)return void(u?a+=o+",":s(o)&&r.push(o));const h=f%2==0;!u&&h&&s(o)?r.push(o):u&&!h?(u=!1,s(a+o)&&r.push(a+o),a=""):(u=!0,a+=o+",")}),r}b.exports=class extends c{render(e,r){e.openNode("definedName",{name:r.name,localSheetId:r.localSheetId}),e.writeText(r.ranges.join(",")),e.closeNode()}parseOpen(e){switch(e.name){case"definedName":return this._parsedName=e.attributes.name,this._parsedLocalSheetId=e.attributes.localSheetId,this._parsedText=[],!0;default:return!1}}parseText(e){this._parsedText.push(e)}parseClose(){return this.model={name:this._parsedName,ranges:n(this._parsedText.join(""))},this._parsedLocalSheetId!==void 0&&(this.model.localSheetId=parseInt(this._parsedLocalSheetId,10)),!1}}},{"../../../utils/col-cache":19,"../base-xform":32}],34:[function(t,b,m){const c=t("../../../utils/utils"),i=t("../base-xform");b.exports=class extends i{render(s,n){s.leafNode("sheet",{sheetId:n.id,name:n.name,state:n.state,"r:id":n.rId})}parseOpen(s){return s.name==="sheet"&&(this.model={name:c.xmlDecode(s.attributes.name),id:parseInt(s.attributes.sheetId,10),state:s.attributes.state,rId:s.attributes["r:id"]},!0)}parseText(){}parseClose(){return!1}}},{"../../../utils/utils":27,"../base-xform":32}],35:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{render(i,s){i.leafNode("calcPr",{calcId:171027,fullCalcOnLoad:s.fullCalcOnLoad?1:void 0})}parseOpen(i){return i.name==="calcPr"&&(this.model={},!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],36:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{render(i,s){i.leafNode("workbookPr",{date1904:s.date1904?1:void 0,defaultThemeVersion:164011,filterPrivacy:1})}parseOpen(i){return i.name==="workbookPr"&&(this.model={date1904:i.attributes.date1904==="1"},!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],37:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{render(i,s){const n={xWindow:s.x||0,yWindow:s.y||0,windowWidth:s.width||12e3,windowHeight:s.height||24e3,firstSheet:s.firstSheet,activeTab:s.activeTab};s.visibility&&s.visibility!=="visible"&&(n.visibility=s.visibility),i.leafNode("workbookView",n)}parseOpen(i){if(i.name==="workbookView"){const s=this.model={},n=function(r,u,a){const o=u!==void 0?s[r]=u:a;o!==void 0&&(s[r]=o)},e=function(r,u,a){const o=u!==void 0?s[r]=parseInt(u,10):a;o!==void 0&&(s[r]=o)};return e("x",i.attributes.xWindow,0),e("y",i.attributes.yWindow,0),e("width",i.attributes.windowWidth,25e3),e("height",i.attributes.windowHeight,1e4),n("visibility",i.attributes.visibility,"visible"),e("activeTab",i.attributes.activeTab,void 0),e("firstSheet",i.attributes.firstSheet,void 0),!0}return!1}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],38:[function(t,b,m){const c=t("../../../utils/under-dash"),i=t("../../../utils/col-cache"),s=t("../../../utils/xml-stream"),n=t("../base-xform"),e=t("../static-xform"),r=t("../list-xform"),u=t("./defined-name-xform"),a=t("./sheet-xform"),o=t("./workbook-view-xform"),f=t("./workbook-properties-xform"),h=t("./workbook-calc-properties-xform");class d extends n{constructor(){super(),this.map={fileVersion:d.STATIC_XFORMS.fileVersion,workbookPr:new f,bookViews:new r({tag:"bookViews",count:!1,childXform:new o}),sheets:new r({tag:"sheets",count:!1,childXform:new a}),definedNames:new r({tag:"definedNames",count:!1,childXform:new u}),calcPr:new h}}prepare(p){p.sheets=p.worksheets;const k=[];let C=0;p.sheets.forEach(T=>{if(T.pageSetup&&T.pageSetup.printArea&&T.pageSetup.printArea.split("&&").forEach(D=>{const V=D.split(":"),P={name:"_xlnm.Print_Area",ranges:[`'${T.name}'!$${V[0]}:$${V[1]}`],localSheetId:C};k.push(P)}),T.pageSetup&&(T.pageSetup.printTitlesRow||T.pageSetup.printTitlesColumn)){const D=[];if(T.pageSetup.printTitlesColumn){const P=T.pageSetup.printTitlesColumn.split(":");D.push(`'${T.name}'!$${P[0]}:$${P[1]}`)}if(T.pageSetup.printTitlesRow){const P=T.pageSetup.printTitlesRow.split(":");D.push(`'${T.name}'!$${P[0]}:$${P[1]}`)}const V={name:"_xlnm.Print_Titles",ranges:D,localSheetId:C};k.push(V)}C++}),k.length&&(p.definedNames=p.definedNames.concat(k)),(p.media||[]).forEach((T,D)=>{T.name=T.type+(D+1)})}render(p,k){p.openXml(s.StdDocAttributes),p.openNode("workbook",d.WORKBOOK_ATTRIBUTES),this.map.fileVersion.render(p),this.map.workbookPr.render(p,k.properties),this.map.bookViews.render(p,k.views),this.map.sheets.render(p,k.sheets),this.map.definedNames.render(p,k.definedNames),this.map.calcPr.render(p,k.calcProperties),p.closeNode()}parseOpen(p){if(this.parser)return this.parser.parseOpen(p),!0;switch(p.name){case"workbook":return!0;default:return this.parser=this.map[p.name],this.parser&&this.parser.parseOpen(p),!0}}parseText(p){this.parser&&this.parser.parseText(p)}parseClose(p){if(this.parser)return this.parser.parseClose(p)||(this.parser=void 0),!0;switch(p){case"workbook":return this.model={sheets:this.map.sheets.model,properties:this.map.workbookPr.model||{},views:this.map.bookViews.model,calcProperties:{}},this.map.definedNames.model&&(this.model.definedNames=this.map.definedNames.model),!1;default:return!0}}reconcile(p){const k=(p.workbookRels||[]).reduce((P,N)=>(P[N.Id]=N,P),{}),C=[];let T,D=0;(p.sheets||[]).forEach(P=>{const N=k[P.rId];N&&(T=p.worksheetHash["xl/"+N.Target.replace(/^(\s|\/xl\/)+/,"")],T&&(T.name=P.name,T.id=P.id,T.state=P.state,C[D++]=T))});const V=[];c.each(p.definedNames,P=>{if(P.name==="_xlnm.Print_Area"){if(T=C[P.localSheetId],T){T.pageSetup||(T.pageSetup={});const N=i.decodeEx(P.ranges[0]);T.pageSetup.printArea=T.pageSetup.printArea?`${T.pageSetup.printArea}&&${N.dimensions}`:N.dimensions}}else if(P.name==="_xlnm.Print_Titles"){if(T=C[P.localSheetId],T){T.pageSetup||(T.pageSetup={});const N=P.ranges.join(","),q=/\$/g,W=/\$\d+:\$\d+/,L=N.match(W);if(L&&L.length){const _=L[0];T.pageSetup.printTitlesRow=_.replace(q,"")}const A=/\$[A-Z]+:\$[A-Z]+/,M=N.match(A);if(M&&M.length){const _=M[0];T.pageSetup.printTitlesColumn=_.replace(q,"")}}}else V.push(P)}),p.definedNames=V,p.media.forEach((P,N)=>{P.index=N})}}d.WORKBOOK_ATTRIBUTES={xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main","xmlns:r":"http://schemas.openxmlformats.org/officeDocument/2006/relationships","xmlns:mc":"http://schemas.openxmlformats.org/markup-compatibility/2006","mc:Ignorable":"x15","xmlns:x15":"http://schemas.microsoft.com/office/spreadsheetml/2010/11/main"},d.STATIC_XFORMS={fileVersion:new e({tag:"fileVersion",$:{appName:"xl",lastEdited:5,lowestEdited:5,rupBuild:9303}})},b.exports=d},{"../../../utils/col-cache":19,"../../../utils/under-dash":26,"../../../utils/xml-stream":28,"../base-xform":32,"../list-xform":71,"../static-xform":120,"./defined-name-xform":33,"./sheet-xform":34,"./workbook-calc-properties-xform":35,"./workbook-properties-xform":36,"./workbook-view-xform":37}],39:[function(t,b,m){const c=t("../strings/rich-text-xform"),i=t("../../../utils/utils"),s=t("../base-xform"),n=b.exports=function(e){this.model=e};i.inherits(n,s,{get tag(){return"r"},get richTextXform(){return this._richTextXform||(this._richTextXform=new c),this._richTextXform},render(e,r){r=r||this.model,e.openNode("comment",{ref:r.ref,authorId:0}),e.openNode("text"),r&&r.note&&r.note.texts&&r.note.texts.forEach(u=>{this.richTextXform.render(e,u)}),e.closeNode(),e.closeNode()},parseOpen(e){if(this.parser)return this.parser.parseOpen(e),!0;switch(e.name){case"comment":return this.model={type:"note",note:{texts:[]},...e.attributes},!0;case"r":return this.parser=this.richTextXform,this.parser.parseOpen(e),!0;default:return!1}},parseText(e){this.parser&&this.parser.parseText(e)},parseClose(e){switch(e){case"comment":return!1;case"r":return this.model.note.texts.push(this.parser.model),this.parser=void 0,!0;default:return this.parser&&this.parser.parseClose(e),!0}}})},{"../../../utils/utils":27,"../base-xform":32,"../strings/rich-text-xform":122}],40:[function(t,b,m){const c=t("../../../utils/xml-stream"),i=t("../../../utils/utils"),s=t("../base-xform"),n=t("./comment-xform"),e=b.exports=function(){this.map={comment:new n}};i.inherits(e,s,{COMMENTS_ATTRIBUTES:{xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main"}},{render(r,u){u=u||this.model,r.openXml(c.StdDocAttributes),r.openNode("comments",e.COMMENTS_ATTRIBUTES),r.openNode("authors"),r.leafNode("author",null,"Author"),r.closeNode(),r.openNode("commentList"),u.comments.forEach(a=>{this.map.comment.render(r,a)}),r.closeNode(),r.closeNode()},parseOpen(r){if(this.parser)return this.parser.parseOpen(r),!0;switch(r.name){case"commentList":return this.model={comments:[]},!0;case"comment":return this.parser=this.map.comment,this.parser.parseOpen(r),!0;default:return!1}},parseText(r){this.parser&&this.parser.parseText(r)},parseClose(r){switch(r){case"commentList":return!1;case"comment":return this.model.comments.push(this.parser.model),this.parser=void 0,!0;default:return this.parser&&this.parser.parseClose(r),!0}}})},{"../../../utils/utils":27,"../../../utils/xml-stream":28,"../base-xform":32,"./comment-xform":39}],41:[function(t,b,m){const c=t("../../base-xform");b.exports=class extends c{constructor(i){super(),this._model=i}get tag(){return this._model&&this._model.tag}render(i,s,n){(s===n[2]||this.tag==="x:SizeWithCells"&&s===n[1])&&i.leafNode(this.tag)}parseOpen(i){switch(i.name){case this.tag:return this.model={},this.model[this.tag]=!0,!0;default:return!1}}parseText(){}parseClose(){return!1}}},{"../../base-xform":32}],42:[function(t,b,m){const c=t("../../base-xform");b.exports=class extends c{constructor(i){super(),this._model=i}get tag(){return this._model&&this._model.tag}render(i,s){i.leafNode(this.tag,null,s)}parseOpen(i){switch(i.name){case this.tag:return this.text="",!0;default:return!1}}parseText(i){this.text=i}parseClose(){return!1}}},{"../../base-xform":32}],43:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"x:Anchor"}getAnchorRect(i){const s=Math.floor(i.left),n=Math.floor(68*(i.left-s)),e=Math.floor(i.top),r=Math.floor(18*(i.top-e)),u=Math.floor(i.right),a=Math.floor(68*(i.right-u)),o=Math.floor(i.bottom);return[s,n,e,r,u,a,o,Math.floor(18*(i.bottom-o))]}getDefaultRect(i){const s=i.col,n=Math.max(i.row-2,0);return[s,6,n,14,s+2,2,n+4,16]}render(i,s){const n=s.anchor?this.getAnchorRect(s.anchor):this.getDefaultRect(s.refAddress);i.leafNode("x:Anchor",null,n.join(", "))}parseOpen(i){switch(i.name){case this.tag:return this.text="",!0;default:return!1}}parseText(i){this.text=i}parseClose(){return!1}}},{"../base-xform":32}],44:[function(t,b,m){const c=t("../base-xform"),i=t("./vml-anchor-xform"),s=t("./style/vml-protection-xform"),n=t("./style/vml-position-xform"),e=["twoCells","oneCells","absolute"];b.exports=class extends c{constructor(){super(),this.map={"x:Anchor":new i,"x:Locked":new s({tag:"x:Locked"}),"x:LockText":new s({tag:"x:LockText"}),"x:SizeWithCells":new n({tag:"x:SizeWithCells"}),"x:MoveWithCells":new n({tag:"x:MoveWithCells"})}}get tag(){return"x:ClientData"}render(r,u){const{protection:a,editAs:o}=u.note;r.openNode(this.tag,{ObjectType:"Note"}),this.map["x:MoveWithCells"].render(r,o,e),this.map["x:SizeWithCells"].render(r,o,e),this.map["x:Anchor"].render(r,u),this.map["x:Locked"].render(r,a.locked),r.leafNode("x:AutoFill",null,"False"),this.map["x:LockText"].render(r,a.lockText),r.leafNode("x:Row",null,u.refAddress.row-1),r.leafNode("x:Column",null,u.refAddress.col-1),r.closeNode()}parseOpen(r){switch(r.name){case this.tag:this.reset(),this.model={anchor:[],protection:{},editAs:""};break;default:this.parser=this.map[r.name],this.parser&&this.parser.parseOpen(r)}return!0}parseText(r){this.parser&&this.parser.parseText(r)}parseClose(r){if(this.parser)return this.parser.parseClose(r)||(this.parser=void 0),!0;switch(r){case this.tag:return this.normalizeModel(),!1;default:return!0}}normalizeModel(){const r=Object.assign({},this.map["x:MoveWithCells"].model,this.map["x:SizeWithCells"].model),u=Object.keys(r).length;this.model.editAs=e[u],this.model.anchor=this.map["x:Anchor"].text,this.model.protection.locked=this.map["x:Locked"].text,this.model.protection.lockText=this.map["x:LockText"].text}}},{"../base-xform":32,"./style/vml-position-xform":41,"./style/vml-protection-xform":42,"./vml-anchor-xform":43}],45:[function(t,b,m){const c=t("../../../utils/xml-stream"),i=t("../base-xform"),s=t("./vml-shape-xform");class n extends i{constructor(){super(),this.map={"v:shape":new s}}get tag(){return"xml"}render(r,u){r.openXml(c.StdDocAttributes),r.openNode(this.tag,n.DRAWING_ATTRIBUTES),r.openNode("o:shapelayout",{"v:ext":"edit"}),r.leafNode("o:idmap",{"v:ext":"edit",data:1}),r.closeNode(),r.openNode("v:shapetype",{id:"_x0000_t202",coordsize:"21600,21600","o:spt":202,path:"m,l,21600r21600,l21600,xe"}),r.leafNode("v:stroke",{joinstyle:"miter"}),r.leafNode("v:path",{gradientshapeok:"t","o:connecttype":"rect"}),r.closeNode(),u.comments.forEach((a,o)=>{this.map["v:shape"].render(r,a,o)}),r.closeNode()}parseOpen(r){if(this.parser)return this.parser.parseOpen(r),!0;switch(r.name){case this.tag:this.reset(),this.model={comments:[]};break;default:this.parser=this.map[r.name],this.parser&&this.parser.parseOpen(r)}return!0}parseText(r){this.parser&&this.parser.parseText(r)}parseClose(r){if(this.parser)return this.parser.parseClose(r)||(this.model.comments.push(this.parser.model),this.parser=void 0),!0;switch(r){case this.tag:return!1;default:return!0}}reconcile(r,u){r.anchors.forEach(a=>{a.br?this.map["xdr:twoCellAnchor"].reconcile(a,u):this.map["xdr:oneCellAnchor"].reconcile(a,u)})}}n.DRAWING_ATTRIBUTES={"xmlns:v":"urn:schemas-microsoft-com:vml","xmlns:o":"urn:schemas-microsoft-com:office:office","xmlns:x":"urn:schemas-microsoft-com:office:excel"},b.exports=n},{"../../../utils/xml-stream":28,"../base-xform":32,"./vml-shape-xform":46}],46:[function(t,b,m){const c=t("../base-xform"),i=t("./vml-textbox-xform"),s=t("./vml-client-data-xform");class n extends c{constructor(){super(),this.map={"v:textbox":new i,"x:ClientData":new s}}get tag(){return"v:shape"}render(r,u,a){r.openNode("v:shape",n.V_SHAPE_ATTRIBUTES(u,a)),r.leafNode("v:fill",{color2:"infoBackground [80]"}),r.leafNode("v:shadow",{color:"none [81]",obscured:"t"}),r.leafNode("v:path",{"o:connecttype":"none"}),this.map["v:textbox"].render(r,u),this.map["x:ClientData"].render(r,u),r.closeNode()}parseOpen(r){if(this.parser)return this.parser.parseOpen(r),!0;switch(r.name){case this.tag:this.reset(),this.model={margins:{insetmode:r.attributes["o:insetmode"]},anchor:"",editAs:"",protection:{}};break;default:this.parser=this.map[r.name],this.parser&&this.parser.parseOpen(r)}return!0}parseText(r){this.parser&&this.parser.parseText(r)}parseClose(r){if(this.parser)return this.parser.parseClose(r)||(this.parser=void 0),!0;switch(r){case this.tag:return this.model.margins.inset=this.map["v:textbox"].model&&this.map["v:textbox"].model.inset,this.model.protection=this.map["x:ClientData"].model&&this.map["x:ClientData"].model.protection,this.model.anchor=this.map["x:ClientData"].model&&this.map["x:ClientData"].model.anchor,this.model.editAs=this.map["x:ClientData"].model&&this.map["x:ClientData"].model.editAs,!1;default:return!0}}}n.V_SHAPE_ATTRIBUTES=(e,r)=>({id:"_x0000_s"+(1025+r),type:"#_x0000_t202",style:"position:absolute; margin-left:105.3pt;margin-top:10.5pt;width:97.8pt;height:59.1pt;z-index:1;visibility:hidden",fillcolor:"infoBackground [80]",strokecolor:"none [81]","o:insetmode":e.note.margins&&e.note.margins.insetmode}),b.exports=n},{"../base-xform":32,"./vml-client-data-xform":44,"./vml-textbox-xform":47}],47:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"v:textbox"}conversionUnit(i,s,n){return`${parseFloat(i)*s.toFixed(2)}${n}`}reverseConversionUnit(i){return(i||"").split(",").map(s=>Number(parseFloat(this.conversionUnit(parseFloat(s),.1,"")).toFixed(2)))}render(i,s){const n={style:"mso-direction-alt:auto"};if(s&&s.note){let{inset:e}=s.note&&s.note.margins;Array.isArray(e)&&(e=e.map(r=>this.conversionUnit(r,10,"mm")).join(",")),e&&(n.inset=e)}i.openNode("v:textbox",n),i.leafNode("div",{style:"text-align:left"}),i.closeNode()}parseOpen(i){switch(i.name){case this.tag:return this.model={inset:this.reverseConversionUnit(i.attributes.inset)},!0;default:return!0}}parseText(){}parseClose(i){switch(i){case this.tag:return!1;default:return!0}}}},{"../base-xform":32}],48:[function(t,b,m){const c=t("./base-xform");b.exports=class extends c{createNewModel(i){return{}}parseOpen(i){return this.parser=this.parser||this.map[i.name],this.parser?(this.parser.parseOpen(i),!0):i.name===this.tag&&(this.model=this.createNewModel(i),!0)}parseText(i){this.parser&&this.parser.parseText(i)}onParserClose(i,s){this.model[i]=s.model}parseClose(i){return this.parser?(this.parser.parseClose(i)||(this.onParserClose(i,this.parser),this.parser=void 0),!0):i!==this.tag}}},{"./base-xform":32}],49:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{render(i,s){i.openNode("HeadingPairs"),i.openNode("vt:vector",{size:2,baseType:"variant"}),i.openNode("vt:variant"),i.leafNode("vt:lpstr",void 0,"Worksheets"),i.closeNode(),i.openNode("vt:variant"),i.leafNode("vt:i4",void 0,s.length),i.closeNode(),i.closeNode(),i.closeNode()}parseOpen(i){return i.name==="HeadingPairs"}parseText(){}parseClose(i){return i!=="HeadingPairs"}}},{"../base-xform":32}],50:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{render(i,s){i.openNode("TitlesOfParts"),i.openNode("vt:vector",{size:s.length,baseType:"lpstr"}),s.forEach(n=>{i.leafNode("vt:lpstr",void 0,n.name)}),i.closeNode(),i.closeNode()}parseOpen(i){return i.name==="TitlesOfParts"}parseText(){}parseClose(i){return i!=="TitlesOfParts"}}},{"../base-xform":32}],51:[function(t,b,m){const c=t("../../../utils/xml-stream"),i=t("../base-xform"),s=t("../simple/string-xform"),n=t("./app-heading-pairs-xform"),e=t("./app-titles-of-parts-xform");class r extends i{constructor(){super(),this.map={Company:new s({tag:"Company"}),Manager:new s({tag:"Manager"}),HeadingPairs:new n,TitleOfParts:new e}}render(a,o){a.openXml(c.StdDocAttributes),a.openNode("Properties",r.PROPERTY_ATTRIBUTES),a.leafNode("Application",void 0,"Microsoft Excel"),a.leafNode("DocSecurity",void 0,"0"),a.leafNode("ScaleCrop",void 0,"false"),this.map.HeadingPairs.render(a,o.worksheets),this.map.TitleOfParts.render(a,o.worksheets),this.map.Company.render(a,o.company||""),this.map.Manager.render(a,o.manager),a.leafNode("LinksUpToDate",void 0,"false"),a.leafNode("SharedDoc",void 0,"false"),a.leafNode("HyperlinksChanged",void 0,"false"),a.leafNode("AppVersion",void 0,"16.0300"),a.closeNode()}parseOpen(a){if(this.parser)return this.parser.parseOpen(a),!0;switch(a.name){case"Properties":return!0;default:return this.parser=this.map[a.name],!!this.parser&&(this.parser.parseOpen(a),!0)}}parseText(a){this.parser&&this.parser.parseText(a)}parseClose(a){if(this.parser)return this.parser.parseClose(a)||(this.parser=void 0),!0;switch(a){case"Properties":return this.model={worksheets:this.map.TitleOfParts.model,company:this.map.Company.model,manager:this.map.Manager.model},!1;default:return!0}}}r.DateFormat=function(u){return u.toISOString().replace(/[.]\d{3,6}/,"")},r.DateAttrs={"xsi:type":"dcterms:W3CDTF"},r.PROPERTY_ATTRIBUTES={xmlns:"http://schemas.openxmlformats.org/officeDocument/2006/extended-properties","xmlns:vt":"http://schemas.openxmlformats.org/officeDocument/2006/docPropsVTypes"},b.exports=r},{"../../../utils/xml-stream":28,"../base-xform":32,"../simple/string-xform":119,"./app-heading-pairs-xform":49,"./app-titles-of-parts-xform":50}],52:[function(t,b,m){const c=t("../../../utils/xml-stream"),i=t("../base-xform");class s extends i{render(e,r){e.openXml(c.StdDocAttributes),e.openNode("Types",s.PROPERTY_ATTRIBUTES);const u={};(r.media||[]).forEach(a=>{if(a.type==="image"){const o=a.extension;u[o]||(u[o]=!0,e.leafNode("Default",{Extension:o,ContentType:"image/"+o}))}}),e.leafNode("Default",{Extension:"rels",ContentType:"application/vnd.openxmlformats-package.relationships+xml"}),e.leafNode("Default",{Extension:"xml",ContentType:"application/xml"}),e.leafNode("Override",{PartName:"/xl/workbook.xml",ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.sheet.main+xml"}),r.worksheets.forEach(a=>{const o=`/xl/worksheets/sheet${a.id}.xml`;e.leafNode("Override",{PartName:o,ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.worksheet+xml"})}),e.leafNode("Override",{PartName:"/xl/theme/theme1.xml",ContentType:"application/vnd.openxmlformats-officedocument.theme+xml"}),e.leafNode("Override",{PartName:"/xl/styles.xml",ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.styles+xml"}),r.sharedStrings&&r.sharedStrings.count&&e.leafNode("Override",{PartName:"/xl/sharedStrings.xml",ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.sharedStrings+xml"}),r.tables&&r.tables.forEach(a=>{e.leafNode("Override",{PartName:"/xl/tables/"+a.target,ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.table+xml"})}),r.drawings&&r.drawings.forEach(a=>{e.leafNode("Override",{PartName:`/xl/drawings/${a.name}.xml`,ContentType:"application/vnd.openxmlformats-officedocument.drawing+xml"})}),r.commentRefs&&(e.leafNode("Default",{Extension:"vml",ContentType:"application/vnd.openxmlformats-officedocument.vmlDrawing"}),r.commentRefs.forEach(a=>{let{commentName:o}=a;e.leafNode("Override",{PartName:`/xl/${o}.xml`,ContentType:"application/vnd.openxmlformats-officedocument.spreadsheetml.comments+xml"})})),e.leafNode("Override",{PartName:"/docProps/core.xml",ContentType:"application/vnd.openxmlformats-package.core-properties+xml"}),e.leafNode("Override",{PartName:"/docProps/app.xml",ContentType:"application/vnd.openxmlformats-officedocument.extended-properties+xml"}),e.closeNode()}parseOpen(){return!1}parseText(){}parseClose(){return!1}}s.PROPERTY_ATTRIBUTES={xmlns:"http://schemas.openxmlformats.org/package/2006/content-types"},b.exports=s},{"../../../utils/xml-stream":28,"../base-xform":32}],53:[function(t,b,m){const c=t("../../../utils/xml-stream"),i=t("../base-xform"),s=t("../simple/date-xform"),n=t("../simple/string-xform"),e=t("../simple/integer-xform");class r extends i{constructor(){super(),this.map={"dc:creator":new n({tag:"dc:creator"}),"dc:title":new n({tag:"dc:title"}),"dc:subject":new n({tag:"dc:subject"}),"dc:description":new n({tag:"dc:description"}),"dc:identifier":new n({tag:"dc:identifier"}),"dc:language":new n({tag:"dc:language"}),"cp:keywords":new n({tag:"cp:keywords"}),"cp:category":new n({tag:"cp:category"}),"cp:lastModifiedBy":new n({tag:"cp:lastModifiedBy"}),"cp:lastPrinted":new s({tag:"cp:lastPrinted",format:r.DateFormat}),"cp:revision":new e({tag:"cp:revision"}),"cp:version":new n({tag:"cp:version"}),"cp:contentStatus":new n({tag:"cp:contentStatus"}),"cp:contentType":new n({tag:"cp:contentType"}),"dcterms:created":new s({tag:"dcterms:created",attrs:r.DateAttrs,format:r.DateFormat}),"dcterms:modified":new s({tag:"dcterms:modified",attrs:r.DateAttrs,format:r.DateFormat})}}render(a,o){a.openXml(c.StdDocAttributes),a.openNode("cp:coreProperties",r.CORE_PROPERTY_ATTRIBUTES),this.map["dc:creator"].render(a,o.creator),this.map["dc:title"].render(a,o.title),this.map["dc:subject"].render(a,o.subject),this.map["dc:description"].render(a,o.description),this.map["dc:identifier"].render(a,o.identifier),this.map["dc:language"].render(a,o.language),this.map["cp:keywords"].render(a,o.keywords),this.map["cp:category"].render(a,o.category),this.map["cp:lastModifiedBy"].render(a,o.lastModifiedBy),this.map["cp:lastPrinted"].render(a,o.lastPrinted),this.map["cp:revision"].render(a,o.revision),this.map["cp:version"].render(a,o.version),this.map["cp:contentStatus"].render(a,o.contentStatus),this.map["cp:contentType"].render(a,o.contentType),this.map["dcterms:created"].render(a,o.created),this.map["dcterms:modified"].render(a,o.modified),a.closeNode()}parseOpen(a){if(this.parser)return this.parser.parseOpen(a),!0;switch(a.name){case"cp:coreProperties":case"coreProperties":return!0;default:if(this.parser=this.map[a.name],this.parser)return this.parser.parseOpen(a),!0;throw new Error("Unexpected xml node in parseOpen: "+JSON.stringify(a))}}parseText(a){this.parser&&this.parser.parseText(a)}parseClose(a){if(this.parser)return this.parser.parseClose(a)||(this.parser=void 0),!0;switch(a){case"cp:coreProperties":case"coreProperties":return this.model={creator:this.map["dc:creator"].model,title:this.map["dc:title"].model,subject:this.map["dc:subject"].model,description:this.map["dc:description"].model,identifier:this.map["dc:identifier"].model,language:this.map["dc:language"].model,keywords:this.map["cp:keywords"].model,category:this.map["cp:category"].model,lastModifiedBy:this.map["cp:lastModifiedBy"].model,lastPrinted:this.map["cp:lastPrinted"].model,revision:this.map["cp:revision"].model,contentStatus:this.map["cp:contentStatus"].model,contentType:this.map["cp:contentType"].model,created:this.map["dcterms:created"].model,modified:this.map["dcterms:modified"].model},!1;default:throw new Error("Unexpected xml node in parseClose: "+a)}}}r.DateFormat=function(u){return u.toISOString().replace(/[.]\d{3}/,"")},r.DateAttrs={"xsi:type":"dcterms:W3CDTF"},r.CORE_PROPERTY_ATTRIBUTES={"xmlns:cp":"http://schemas.openxmlformats.org/package/2006/metadata/core-properties","xmlns:dc":"http://purl.org/dc/elements/1.1/","xmlns:dcterms":"http://purl.org/dc/terms/","xmlns:dcmitype":"http://purl.org/dc/dcmitype/","xmlns:xsi":"http://www.w3.org/2001/XMLSchema-instance"},b.exports=r},{"../../../utils/xml-stream":28,"../base-xform":32,"../simple/date-xform":117,"../simple/integer-xform":118,"../simple/string-xform":119}],54:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{render(i,s){i.leafNode("Relationship",s)}parseOpen(i){switch(i.name){case"Relationship":return this.model=i.attributes,!0;default:return!1}}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],55:[function(t,b,m){const c=t("../../../utils/xml-stream"),i=t("../base-xform"),s=t("./relationship-xform");class n extends i{constructor(){super(),this.map={Relationship:new s}}render(r,u){u=u||this._values,r.openXml(c.StdDocAttributes),r.openNode("Relationships",n.RELATIONSHIPS_ATTRIBUTES),u.forEach(a=>{this.map.Relationship.render(r,a)}),r.closeNode()}parseOpen(r){if(this.parser)return this.parser.parseOpen(r),!0;switch(r.name){case"Relationships":return this.model=[],!0;default:if(this.parser=this.map[r.name],this.parser)return this.parser.parseOpen(r),!0;throw new Error("Unexpected xml node in parseOpen: "+JSON.stringify(r))}}parseText(r){this.parser&&this.parser.parseText(r)}parseClose(r){if(this.parser)return this.parser.parseClose(r)||(this.model.push(this.parser.model),this.parser=void 0),!0;switch(r){case"Relationships":return!1;default:throw new Error("Unexpected xml node in parseClose: "+r)}}}n.RELATIONSHIPS_ATTRIBUTES={xmlns:"http://schemas.openxmlformats.org/package/2006/relationships"},b.exports=n},{"../../../utils/xml-stream":28,"../base-xform":32,"./relationship-xform":54}],56:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{parseOpen(i){if(this.parser)return this.parser.parseOpen(i),!0;switch(i.name){case this.tag:this.reset(),this.model={range:{editAs:i.attributes.editAs||"oneCell"}};break;default:this.parser=this.map[i.name],this.parser&&this.parser.parseOpen(i)}return!0}parseText(i){this.parser&&this.parser.parseText(i)}reconcilePicture(i,s){if(i&&i.rId){const n=s.rels[i.rId].Target.match(/.*\/media\/(.+[.][a-zA-Z]{3,4})/);if(n){const e=n[1],r=s.mediaIndex[e];return s.media[r]}}}}},{"../base-xform":32}],57:[function(t,b,m){const c=t("../base-xform"),i=t("./blip-xform");b.exports=class extends c{constructor(){super(),this.map={"a:blip":new i}}get tag(){return"xdr:blipFill"}render(s,n){s.openNode(this.tag),this.map["a:blip"].render(s,n),s.openNode("a:stretch"),s.leafNode("a:fillRect"),s.closeNode(),s.closeNode()}parseOpen(s){if(this.parser)return this.parser.parseOpen(s),!0;switch(s.name){case this.tag:this.reset();break;default:this.parser=this.map[s.name],this.parser&&this.parser.parseOpen(s)}return!0}parseText(){}parseClose(s){if(this.parser)return this.parser.parseClose(s)||(this.parser=void 0),!0;switch(s){case this.tag:return this.model=this.map["a:blip"].model,!1;default:return!0}}}},{"../base-xform":32,"./blip-xform":58}],58:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"a:blip"}render(i,s){i.leafNode(this.tag,{"xmlns:r":"http://schemas.openxmlformats.org/officeDocument/2006/relationships","r:embed":s.rId,cstate:"print"})}parseOpen(i){switch(i.name){case this.tag:return this.model={rId:i.attributes["r:embed"]},!0;default:return!0}}parseText(){}parseClose(i){switch(i){case this.tag:return!1;default:return!0}}}},{"../base-xform":32}],59:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"xdr:cNvPicPr"}render(i){i.openNode(this.tag),i.leafNode("a:picLocks",{noChangeAspect:"1"}),i.closeNode()}parseOpen(i){switch(i.name){case this.tag:default:return!0}}parseText(){}parseClose(i){switch(i){case this.tag:return!1;default:return!0}}}},{"../base-xform":32}],60:[function(t,b,m){const c=t("../base-xform"),i=t("./hlink-click-xform"),s=t("./ext-lst-xform");b.exports=class extends c{constructor(){super(),this.map={"a:hlinkClick":new i,"a:extLst":new s}}get tag(){return"xdr:cNvPr"}render(n,e){n.openNode(this.tag,{id:e.index,name:"Picture "+e.index}),this.map["a:hlinkClick"].render(n,e),this.map["a:extLst"].render(n,e),n.closeNode()}parseOpen(n){if(this.parser)return this.parser.parseOpen(n),!0;switch(n.name){case this.tag:this.reset();break;default:this.parser=this.map[n.name],this.parser&&this.parser.parseOpen(n)}return!0}parseText(){}parseClose(n){if(this.parser)return this.parser.parseClose(n)||(this.parser=void 0),!0;switch(n){case this.tag:return this.model=this.map["a:hlinkClick"].model,!1;default:return!0}}}},{"../base-xform":32,"./ext-lst-xform":63,"./hlink-click-xform":65}],61:[function(t,b,m){const c=t("../base-xform"),i=t("../simple/integer-xform");b.exports=class extends c{constructor(s){super(),this.tag=s.tag,this.map={"xdr:col":new i({tag:"xdr:col",zero:!0}),"xdr:colOff":new i({tag:"xdr:colOff",zero:!0}),"xdr:row":new i({tag:"xdr:row",zero:!0}),"xdr:rowOff":new i({tag:"xdr:rowOff",zero:!0})}}render(s,n){s.openNode(this.tag),this.map["xdr:col"].render(s,n.nativeCol),this.map["xdr:colOff"].render(s,n.nativeColOff),this.map["xdr:row"].render(s,n.nativeRow),this.map["xdr:rowOff"].render(s,n.nativeRowOff),s.closeNode()}parseOpen(s){if(this.parser)return this.parser.parseOpen(s),!0;switch(s.name){case this.tag:this.reset();break;default:this.parser=this.map[s.name],this.parser&&this.parser.parseOpen(s)}return!0}parseText(s){this.parser&&this.parser.parseText(s)}parseClose(s){if(this.parser)return this.parser.parseClose(s)||(this.parser=void 0),!0;switch(s){case this.tag:return this.model={nativeCol:this.map["xdr:col"].model,nativeColOff:this.map["xdr:colOff"].model,nativeRow:this.map["xdr:row"].model,nativeRowOff:this.map["xdr:rowOff"].model},!1;default:return!0}}}},{"../base-xform":32,"../simple/integer-xform":118}],62:[function(t,b,m){const c=t("../../../utils/col-cache"),i=t("../../../utils/xml-stream"),s=t("../base-xform"),n=t("./two-cell-anchor-xform"),e=t("./one-cell-anchor-xform");class r extends s{constructor(){super(),this.map={"xdr:twoCellAnchor":new n,"xdr:oneCellAnchor":new e}}prepare(a){a.anchors.forEach((o,f)=>{o.anchorType=function(h){return(typeof h.range=="string"?c.decode(h.range):h.range).br?"xdr:twoCellAnchor":"xdr:oneCellAnchor"}(o),this.map[o.anchorType].prepare(o,{index:f})})}get tag(){return"xdr:wsDr"}render(a,o){a.openXml(i.StdDocAttributes),a.openNode(this.tag,r.DRAWING_ATTRIBUTES),o.anchors.forEach(f=>{this.map[f.anchorType].render(a,f)}),a.closeNode()}parseOpen(a){if(this.parser)return this.parser.parseOpen(a),!0;switch(a.name){case this.tag:this.reset(),this.model={anchors:[]};break;default:this.parser=this.map[a.name],this.parser&&this.parser.parseOpen(a)}return!0}parseText(a){this.parser&&this.parser.parseText(a)}parseClose(a){if(this.parser)return this.parser.parseClose(a)||(this.model.anchors.push(this.parser.model),this.parser=void 0),!0;switch(a){case this.tag:return!1;default:return!0}}reconcile(a,o){a.anchors.forEach(f=>{f.br?this.map["xdr:twoCellAnchor"].reconcile(f,o):this.map["xdr:oneCellAnchor"].reconcile(f,o)})}}r.DRAWING_ATTRIBUTES={"xmlns:xdr":"http://schemas.openxmlformats.org/drawingml/2006/spreadsheetDrawing","xmlns:a":"http://schemas.openxmlformats.org/drawingml/2006/main"},b.exports=r},{"../../../utils/col-cache":19,"../../../utils/xml-stream":28,"../base-xform":32,"./one-cell-anchor-xform":67,"./two-cell-anchor-xform":70}],63:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"a:extLst"}render(i){i.openNode(this.tag),i.openNode("a:ext",{uri:"{FF2B5EF4-FFF2-40B4-BE49-F238E27FC236}"}),i.leafNode("a16:creationId",{"xmlns:a16":"http://schemas.microsoft.com/office/drawing/2014/main",id:"{00000000-0008-0000-0000-000002000000}"}),i.closeNode(),i.closeNode()}parseOpen(i){switch(i.name){case this.tag:default:return!0}}parseText(){}parseClose(i){switch(i){case this.tag:return!1;default:return!0}}}},{"../base-xform":32}],64:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{constructor(i){super(),this.tag=i.tag,this.map={}}render(i,s){i.openNode(this.tag);const n=Math.floor(9525*s.width),e=Math.floor(9525*s.height);i.addAttribute("cx",n),i.addAttribute("cy",e),i.closeNode()}parseOpen(i){return i.name===this.tag&&(this.model={width:parseInt(i.attributes.cx||"0",10)/9525,height:parseInt(i.attributes.cy||"0",10)/9525},!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],65:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"a:hlinkClick"}render(i,s){s.hyperlinks&&s.hyperlinks.rId&&i.leafNode(this.tag,{"xmlns:r":"http://schemas.openxmlformats.org/officeDocument/2006/relationships","r:id":s.hyperlinks.rId,tooltip:s.hyperlinks.tooltip})}parseOpen(i){switch(i.name){case this.tag:return this.model={hyperlinks:{rId:i.attributes["r:id"],tooltip:i.attributes.tooltip}},!0;default:return!0}}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],66:[function(t,b,m){const c=t("../base-xform"),i=t("./c-nv-pr-xform"),s=t("./c-nv-pic-pr-xform");b.exports=class extends c{constructor(){super(),this.map={"xdr:cNvPr":new i,"xdr:cNvPicPr":new s}}get tag(){return"xdr:nvPicPr"}render(n,e){n.openNode(this.tag),this.map["xdr:cNvPr"].render(n,e),this.map["xdr:cNvPicPr"].render(n,e),n.closeNode()}parseOpen(n){if(this.parser)return this.parser.parseOpen(n),!0;switch(n.name){case this.tag:this.reset();break;default:this.parser=this.map[n.name],this.parser&&this.parser.parseOpen(n)}return!0}parseText(){}parseClose(n){if(this.parser)return this.parser.parseClose(n)||(this.parser=void 0),!0;switch(n){case this.tag:return this.model=this.map["xdr:cNvPr"].model,!1;default:return!0}}}},{"../base-xform":32,"./c-nv-pic-pr-xform":59,"./c-nv-pr-xform":60}],67:[function(t,b,m){const c=t("./base-cell-anchor-xform"),i=t("../static-xform"),s=t("./cell-position-xform"),n=t("./ext-xform"),e=t("./pic-xform");b.exports=class extends c{constructor(){super(),this.map={"xdr:from":new s({tag:"xdr:from"}),"xdr:ext":new n({tag:"xdr:ext"}),"xdr:pic":new e,"xdr:clientData":new i({tag:"xdr:clientData"})}}get tag(){return"xdr:oneCellAnchor"}prepare(r,u){this.map["xdr:pic"].prepare(r.picture,u)}render(r,u){r.openNode(this.tag,{editAs:u.range.editAs||"oneCell"}),this.map["xdr:from"].render(r,u.range.tl),this.map["xdr:ext"].render(r,u.range.ext),this.map["xdr:pic"].render(r,u.picture),this.map["xdr:clientData"].render(r,{}),r.closeNode()}parseClose(r){if(this.parser)return this.parser.parseClose(r)||(this.parser=void 0),!0;switch(r){case this.tag:return this.model.range.tl=this.map["xdr:from"].model,this.model.range.ext=this.map["xdr:ext"].model,this.model.picture=this.map["xdr:pic"].model,!1;default:return!0}}reconcile(r,u){r.medium=this.reconcilePicture(r.picture,u)}}},{"../static-xform":120,"./base-cell-anchor-xform":56,"./cell-position-xform":61,"./ext-xform":64,"./pic-xform":68}],68:[function(t,b,m){const c=t("../base-xform"),i=t("../static-xform"),s=t("./blip-fill-xform"),n=t("./nv-pic-pr-xform"),e=t("./sp-pr");b.exports=class extends c{constructor(){super(),this.map={"xdr:nvPicPr":new n,"xdr:blipFill":new s,"xdr:spPr":new i(e)}}get tag(){return"xdr:pic"}prepare(r,u){r.index=u.index+1}render(r,u){r.openNode(this.tag),this.map["xdr:nvPicPr"].render(r,u),this.map["xdr:blipFill"].render(r,u),this.map["xdr:spPr"].render(r,u),r.closeNode()}parseOpen(r){if(this.parser)return this.parser.parseOpen(r),!0;switch(r.name){case this.tag:this.reset();break;default:this.parser=this.map[r.name],this.parser&&this.parser.parseOpen(r)}return!0}parseText(){}parseClose(r){if(this.parser)return this.parser.parseClose(r)||(this.mergeModel(this.parser.model),this.parser=void 0),!0;switch(r){case this.tag:return!1;default:return!0}}}},{"../base-xform":32,"../static-xform":120,"./blip-fill-xform":57,"./nv-pic-pr-xform":66,"./sp-pr":69}],69:[function(t,b,m){b.exports={tag:"xdr:spPr",c:[{tag:"a:xfrm",c:[{tag:"a:off",$:{x:"0",y:"0"}},{tag:"a:ext",$:{cx:"0",cy:"0"}}]},{tag:"a:prstGeom",$:{prst:"rect"},c:[{tag:"a:avLst"}]}]}},{}],70:[function(t,b,m){const c=t("./base-cell-anchor-xform"),i=t("../static-xform"),s=t("./cell-position-xform"),n=t("./pic-xform");b.exports=class extends c{constructor(){super(),this.map={"xdr:from":new s({tag:"xdr:from"}),"xdr:to":new s({tag:"xdr:to"}),"xdr:pic":new n,"xdr:clientData":new i({tag:"xdr:clientData"})}}get tag(){return"xdr:twoCellAnchor"}prepare(e,r){this.map["xdr:pic"].prepare(e.picture,r)}render(e,r){e.openNode(this.tag,{editAs:r.range.editAs||"oneCell"}),this.map["xdr:from"].render(e,r.range.tl),this.map["xdr:to"].render(e,r.range.br),this.map["xdr:pic"].render(e,r.picture),this.map["xdr:clientData"].render(e,{}),e.closeNode()}parseClose(e){if(this.parser)return this.parser.parseClose(e)||(this.parser=void 0),!0;switch(e){case this.tag:return this.model.range.tl=this.map["xdr:from"].model,this.model.range.br=this.map["xdr:to"].model,this.model.picture=this.map["xdr:pic"].model,!1;default:return!0}}reconcile(e,r){e.medium=this.reconcilePicture(e.picture,r)}}},{"../static-xform":120,"./base-cell-anchor-xform":56,"./cell-position-xform":61,"./pic-xform":68}],71:[function(t,b,m){const c=t("./base-xform");b.exports=class extends c{constructor(i){super(),this.tag=i.tag,this.always=!!i.always,this.count=i.count,this.empty=i.empty,this.$count=i.$count||"count",this.$=i.$,this.childXform=i.childXform,this.maxItems=i.maxItems}prepare(i,s){const{childXform:n}=this;i&&i.forEach((e,r)=>{s.index=r,n.prepare(e,s)})}render(i,s){if(this.always||s&&s.length){i.openNode(this.tag,this.$),this.count&&i.addAttribute(this.$count,s&&s.length||0);const{childXform:n}=this;(s||[]).forEach((e,r)=>{n.render(i,e,r)}),i.closeNode()}else this.empty&&i.leafNode(this.tag)}parseOpen(i){if(this.parser)return this.parser.parseOpen(i),!0;switch(i.name){case this.tag:return this.model=[],!0;default:return!!this.childXform.parseOpen(i)&&(this.parser=this.childXform,!0)}}parseText(i){this.parser&&this.parser.parseText(i)}parseClose(i){if(this.parser){if(!this.parser.parseClose(i)&&(this.model.push(this.parser.model),this.parser=void 0,this.maxItems&&this.model.length>this.maxItems))throw new Error(`Max ${this.childXform.tag} count (${this.maxItems}) exceeded`);return!0}return!1}reconcile(i,s){if(i){const{childXform:n}=this;i.forEach(e=>{n.reconcile(e,s)})}}}},{"./base-xform":32}],72:[function(t,b,m){const c=t("../../../utils/col-cache"),i=t("../base-xform");b.exports=class extends i{get tag(){return"autoFilter"}render(s,n){if(n)if(typeof n=="string")s.leafNode("autoFilter",{ref:n});else{const e=function(a){return typeof a=="string"?a:c.getAddress(a.row,a.column).address},r=e(n.from),u=e(n.to);r&&u&&s.leafNode("autoFilter",{ref:`${r}:${u}`})}}parseOpen(s){s.name==="autoFilter"&&(this.model=s.attributes.ref)}}},{"../../../utils/col-cache":19,"../base-xform":32}],73:[function(t,b,m){const c=t("../../../utils/utils"),i=t("../base-xform"),s=t("../../../doc/range"),n=t("../../../doc/enums"),e=t("../strings/rich-text-xform");function r(u){if(u==null)return n.ValueType.Null;if(u instanceof String||typeof u=="string")return n.ValueType.String;if(typeof u=="number")return n.ValueType.Number;if(typeof u=="boolean")return n.ValueType.Boolean;if(u instanceof Date)return n.ValueType.Date;if(u.text&&u.hyperlink)return n.ValueType.Hyperlink;if(u.formula)return n.ValueType.Formula;if(u.error)return n.ValueType.Error;throw new Error("I could not understand type of value")}b.exports=class extends i{constructor(){super(),this.richTextXForm=new e}get tag(){return"c"}prepare(u,a){const o=a.styles.addStyleModel(u.style||{},function(f){switch(f.type){case n.ValueType.Formula:return r(f.result);default:return f.type}}(u));switch(o&&(u.styleId=o),u.comment&&a.comments.push({...u.comment,ref:u.address}),u.type){case n.ValueType.String:case n.ValueType.RichText:a.sharedStrings&&(u.ssId=a.sharedStrings.add(u.value));break;case n.ValueType.Date:a.date1904&&(u.date1904=!0);break;case n.ValueType.Hyperlink:a.sharedStrings&&u.text!==void 0&&u.text!==null&&(u.ssId=a.sharedStrings.add(u.text)),a.hyperlinks.push({address:u.address,target:u.hyperlink,tooltip:u.tooltip});break;case n.ValueType.Merge:a.merges.add(u);break;case n.ValueType.Formula:if(a.date1904&&(u.date1904=!0),u.shareType==="shared"&&(u.si=a.siFormulae++),u.formula)a.formulae[u.address]=u;else if(u.sharedFormula){const f=a.formulae[u.sharedFormula];if(!f)throw new Error("Shared Formula master must exist above and or left of clone for cell "+u.address);f.si===void 0?(f.shareType="shared",f.si=a.siFormulae++,f.range=new s(f.address,u.address)):f.range&&f.range.expandToAddress(u.address),u.si=f.si}}}renderFormula(u,a){let o=null;switch(a.shareType){case"shared":o={t:"shared",ref:a.ref||a.range.range,si:a.si};break;case"array":o={t:"array",ref:a.ref};break;default:a.si!==void 0&&(o={t:"shared",si:a.si})}switch(r(a.result)){case n.ValueType.Null:u.leafNode("f",o,a.formula);break;case n.ValueType.String:u.addAttribute("t","str"),u.leafNode("f",o,a.formula),u.leafNode("v",null,a.result);break;case n.ValueType.Number:u.leafNode("f",o,a.formula),u.leafNode("v",null,a.result);break;case n.ValueType.Boolean:u.addAttribute("t","b"),u.leafNode("f",o,a.formula),u.leafNode("v",null,a.result?1:0);break;case n.ValueType.Error:u.addAttribute("t","e"),u.leafNode("f",o,a.formula),u.leafNode("v",null,a.result.error);break;case n.ValueType.Date:u.leafNode("f",o,a.formula),u.leafNode("v",null,c.dateToExcel(a.result,a.date1904));break;default:throw new Error("I could not understand type of value")}}render(u,a){if(a.type!==n.ValueType.Null||a.styleId){switch(u.openNode("c"),u.addAttribute("r",a.address),a.styleId&&u.addAttribute("s",a.styleId),a.type){case n.ValueType.Null:break;case n.ValueType.Number:u.leafNode("v",null,a.value);break;case n.ValueType.Boolean:u.addAttribute("t","b"),u.leafNode("v",null,a.value?"1":"0");break;case n.ValueType.Error:u.addAttribute("t","e"),u.leafNode("v",null,a.value.error);break;case n.ValueType.String:case n.ValueType.RichText:a.ssId!==void 0?(u.addAttribute("t","s"),u.leafNode("v",null,a.ssId)):a.value&&a.value.richText?(u.addAttribute("t","inlineStr"),u.openNode("is"),a.value.richText.forEach(o=>{this.richTextXForm.render(u,o)}),u.closeNode("is")):(u.addAttribute("t","str"),u.leafNode("v",null,a.value));break;case n.ValueType.Date:u.leafNode("v",null,c.dateToExcel(a.value,a.date1904));break;case n.ValueType.Hyperlink:a.ssId!==void 0?(u.addAttribute("t","s"),u.leafNode("v",null,a.ssId)):(u.addAttribute("t","str"),u.leafNode("v",null,a.text));break;case n.ValueType.Formula:this.renderFormula(u,a);break;case n.ValueType.Merge:}u.closeNode()}}parseOpen(u){if(this.parser)return this.parser.parseOpen(u),!0;switch(u.name){case"c":return this.model={address:u.attributes.r},this.t=u.attributes.t,u.attributes.s&&(this.model.styleId=parseInt(u.attributes.s,10)),!0;case"f":return this.currentNode="f",this.model.si=u.attributes.si,this.model.shareType=u.attributes.t,this.model.ref=u.attributes.ref,!0;case"v":return this.currentNode="v",!0;case"t":return this.currentNode="t",!0;case"r":return this.parser=this.richTextXForm,this.parser.parseOpen(u),!0;default:return!1}}parseText(u){if(this.parser)this.parser.parseText(u);else switch(this.currentNode){case"f":this.model.formula=this.model.formula?this.model.formula+u:u;break;case"v":case"t":this.model.value&&this.model.value.richText?this.model.value.richText.text=this.model.value.richText.text?this.model.value.richText.text+u:u:this.model.value=this.model.value?this.model.value+u:u}}parseClose(u){switch(u){case"c":{const{model:a}=this;if(a.formula||a.shareType)a.type=n.ValueType.Formula,a.value&&(this.t==="str"?a.result=c.xmlDecode(a.value):this.t==="b"?a.result=parseInt(a.value,10)!==0:this.t==="e"?a.result={error:a.value}:a.result=parseFloat(a.value),a.value=void 0);else if(a.value!==void 0)switch(this.t){case"s":a.type=n.ValueType.String,a.value=parseInt(a.value,10);break;case"str":a.type=n.ValueType.String,a.value=c.xmlDecode(a.value);break;case"inlineStr":a.type=n.ValueType.String;break;case"b":a.type=n.ValueType.Boolean,a.value=parseInt(a.value,10)!==0;break;case"e":a.type=n.ValueType.Error,a.value={error:a.value};break;default:a.type=n.ValueType.Number,a.value=parseFloat(a.value)}else a.styleId?a.type=n.ValueType.Null:a.type=n.ValueType.Merge;return!1}case"f":case"v":case"is":return this.currentNode=void 0,!0;case"t":return this.parser?(this.parser.parseClose(u),!0):(this.currentNode=void 0,!0);case"r":return this.model.value=this.model.value||{},this.model.value.richText=this.model.value.richText||[],this.model.value.richText.push(this.parser.model),this.parser=void 0,this.currentNode=void 0,!0;default:return!!this.parser&&(this.parser.parseClose(u),!0)}}reconcile(u,a){const o=u.styleId&&a.styles&&a.styles.getStyleModel(u.styleId);switch(o&&(u.style=o),u.styleId!==void 0&&(u.styleId=void 0),u.type){case n.ValueType.String:typeof u.value=="number"&&a.sharedStrings&&(u.value=a.sharedStrings.getString(u.value)),u.value.richText&&(u.type=n.ValueType.RichText);break;case n.ValueType.Number:o&&c.isDateFmt(o.numFmt)&&(u.type=n.ValueType.Date,u.value=c.excelToDate(u.value,a.date1904));break;case n.ValueType.Formula:u.result!==void 0&&o&&c.isDateFmt(o.numFmt)&&(u.result=c.excelToDate(u.result,a.date1904)),u.shareType==="shared"&&(u.ref?a.formulae[u.si]=u.address:(u.sharedFormula=a.formulae[u.si],delete u.shareType),delete u.si)}const f=a.hyperlinkMap[u.address];f&&(u.type===n.ValueType.Formula?(u.text=u.result,u.result=void 0):(u.text=u.value,u.value=void 0),u.type=n.ValueType.Hyperlink,u.hyperlink=f);const h=a.commentsMap&&a.commentsMap[u.address];h&&(u.comment=h)}}},{"../../../doc/enums":7,"../../../doc/range":10,"../../../utils/utils":27,"../base-xform":32,"../strings/rich-text-xform":122}],74:[function(t,b,m){const c=t("../../base-xform");b.exports=class extends c{get tag(){return"x14:cfIcon"}render(i,s){i.leafNode(this.tag,{iconSet:s.iconSet,iconId:s.iconId})}parseOpen(i){let{attributes:s}=i;this.model={iconSet:s.iconSet,iconId:c.toIntValue(s.iconId)}}parseClose(i){return i!==this.tag}}},{"../../base-xform":32}],75:[function(t,b,m){const{v4:c}=t("uuid"),i=t("../../base-xform"),s=t("../../composite-xform"),n=t("./databar-ext-xform"),e=t("./icon-set-ext-xform"),r={"3Triangles":!0,"3Stars":!0,"5Boxes":!0};class u extends s{constructor(){super(),this.map={"x14:dataBar":this.databarXform=new n,"x14:iconSet":this.iconSetXform=new e}}get tag(){return"x14:cfRule"}static isExt(o){return o.type==="dataBar"?n.isExt(o):!(o.type!=="iconSet"||!o.custom&&!r[o.iconSet])}prepare(o){u.isExt(o)&&(o.x14Id=`{${c()}}`.toUpperCase())}render(o,f){if(u.isExt(f))switch(f.type){case"dataBar":this.renderDataBar(o,f);break;case"iconSet":this.renderIconSet(o,f)}}renderDataBar(o,f){o.openNode(this.tag,{type:"dataBar",id:f.x14Id}),this.databarXform.render(o,f),o.closeNode()}renderIconSet(o,f){o.openNode(this.tag,{type:"iconSet",priority:f.priority,id:f.x14Id||`{${c()}}`}),this.iconSetXform.render(o,f),o.closeNode()}createNewModel(o){let{attributes:f}=o;return{type:f.type,x14Id:f.id,priority:i.toIntValue(f.priority)}}onParserClose(o,f){Object.assign(this.model,f.model)}}b.exports=u},{"../../base-xform":32,"../../composite-xform":48,"./databar-ext-xform":79,"./icon-set-ext-xform":81,uuid:528}],76:[function(t,b,m){const c=t("../../composite-xform"),i=t("./f-ext-xform");b.exports=class extends c{constructor(){super(),this.map={"xm:f":this.fExtXform=new i}}get tag(){return"x14:cfvo"}render(s,n){s.openNode(this.tag,{type:n.type}),n.value!==void 0&&this.fExtXform.render(s,n.value),s.closeNode()}createNewModel(s){return{type:s.attributes.type}}onParserClose(s,n){switch(s){case"xm:f":this.model.value=n.model?parseFloat(n.model):0}}}},{"../../composite-xform":48,"./f-ext-xform":80}],77:[function(t,b,m){const c=t("../../composite-xform"),i=t("./sqref-ext-xform"),s=t("./cf-rule-ext-xform");b.exports=class extends c{constructor(){super(),this.map={"xm:sqref":this.sqRef=new i,"x14:cfRule":this.cfRule=new s}}get tag(){return"x14:conditionalFormatting"}prepare(n,e){n.rules.forEach(r=>{this.cfRule.prepare(r,e)})}render(n,e){e.rules.some(s.isExt)&&(n.openNode(this.tag,{"xmlns:xm":"http://schemas.microsoft.com/office/excel/2006/main"}),e.rules.filter(s.isExt).forEach(r=>this.cfRule.render(n,r)),this.sqRef.render(n,e.ref),n.closeNode())}createNewModel(){return{rules:[]}}onParserClose(n,e){switch(n){case"xm:sqref":this.model.ref=e.model;break;case"x14:cfRule":this.model.rules.push(e.model)}}}},{"../../composite-xform":48,"./cf-rule-ext-xform":75,"./sqref-ext-xform":82}],78:[function(t,b,m){const c=t("../../composite-xform"),i=t("./cf-rule-ext-xform"),s=t("./conditional-formatting-ext-xform");b.exports=class extends c{constructor(){super(),this.map={"x14:conditionalFormatting":this.cfXform=new s}}get tag(){return"x14:conditionalFormattings"}hasContent(n){return n.hasExtContent===void 0&&(n.hasExtContent=n.some(e=>e.rules.some(i.isExt))),n.hasExtContent}prepare(n,e){n.forEach(r=>{this.cfXform.prepare(r,e)})}render(n,e){this.hasContent(e)&&(n.openNode(this.tag),e.forEach(r=>this.cfXform.render(n,r)),n.closeNode())}createNewModel(){return[]}onParserClose(n,e){this.model.push(e.model)}}},{"../../composite-xform":48,"./cf-rule-ext-xform":75,"./conditional-formatting-ext-xform":77}],79:[function(t,b,m){const c=t("../../base-xform"),i=t("../../composite-xform"),s=t("../../style/color-xform"),n=t("./cfvo-ext-xform");b.exports=class extends i{constructor(){super(),this.map={"x14:cfvo":this.cfvoXform=new n,"x14:borderColor":this.borderColorXform=new s("x14:borderColor"),"x14:negativeBorderColor":this.negativeBorderColorXform=new s("x14:negativeBorderColor"),"x14:negativeFillColor":this.negativeFillColorXform=new s("x14:negativeFillColor"),"x14:axisColor":this.axisColorXform=new s("x14:axisColor")}}static isExt(e){return!e.gradient}get tag(){return"x14:dataBar"}render(e,r){e.openNode(this.tag,{minLength:c.toIntAttribute(r.minLength,0,!0),maxLength:c.toIntAttribute(r.maxLength,100,!0),border:c.toBoolAttribute(r.border,!1),gradient:c.toBoolAttribute(r.gradient,!0),negativeBarColorSameAsPositive:c.toBoolAttribute(r.negativeBarColorSameAsPositive,!0),negativeBarBorderColorSameAsPositive:c.toBoolAttribute(r.negativeBarBorderColorSameAsPositive,!0),axisPosition:c.toAttribute(r.axisPosition,"auto"),direction:c.toAttribute(r.direction,"leftToRight")}),r.cfvo.forEach(u=>{this.cfvoXform.render(e,u)}),this.borderColorXform.render(e,r.borderColor),this.negativeBorderColorXform.render(e,r.negativeBorderColor),this.negativeFillColorXform.render(e,r.negativeFillColor),this.axisColorXform.render(e,r.axisColor),e.closeNode()}createNewModel(e){let{attributes:r}=e;return{cfvo:[],minLength:c.toIntValue(r.minLength,0),maxLength:c.toIntValue(r.maxLength,100),border:c.toBoolValue(r.border,!1),gradient:c.toBoolValue(r.gradient,!0),negativeBarColorSameAsPositive:c.toBoolValue(r.negativeBarColorSameAsPositive,!0),negativeBarBorderColorSameAsPositive:c.toBoolValue(r.negativeBarBorderColorSameAsPositive,!0),axisPosition:c.toStringValue(r.axisPosition,"auto"),direction:c.toStringValue(r.direction,"leftToRight")}}onParserClose(e,r){const[,u]=e.split(":");switch(u){case"cfvo":this.model.cfvo.push(r.model);break;default:this.model[u]=r.model}}}},{"../../base-xform":32,"../../composite-xform":48,"../../style/color-xform":128,"./cfvo-ext-xform":76}],80:[function(t,b,m){const c=t("../../base-xform");b.exports=class extends c{get tag(){return"xm:f"}render(i,s){i.leafNode(this.tag,null,s)}parseOpen(){this.model=""}parseText(i){this.model+=i}parseClose(i){return i!==this.tag}}},{"../../base-xform":32}],81:[function(t,b,m){const c=t("../../base-xform"),i=t("../../composite-xform"),s=t("./cfvo-ext-xform"),n=t("./cf-icon-ext-xform");b.exports=class extends i{constructor(){super(),this.map={"x14:cfvo":this.cfvoXform=new s,"x14:cfIcon":this.cfIconXform=new n}}get tag(){return"x14:iconSet"}render(e,r){e.openNode(this.tag,{iconSet:c.toStringAttribute(r.iconSet),reverse:c.toBoolAttribute(r.reverse,!1),showValue:c.toBoolAttribute(r.showValue,!0),custom:c.toBoolAttribute(r.icons,!1)}),r.cfvo.forEach(u=>{this.cfvoXform.render(e,u)}),r.icons&&r.icons.forEach((u,a)=>{u.iconId=a,this.cfIconXform.render(e,u)}),e.closeNode()}createNewModel(e){let{attributes:r}=e;return{cfvo:[],iconSet:c.toStringValue(r.iconSet,"3TrafficLights"),reverse:c.toBoolValue(r.reverse,!1),showValue:c.toBoolValue(r.showValue,!0)}}onParserClose(e,r){const[,u]=e.split(":");switch(u){case"cfvo":this.model.cfvo.push(r.model);break;case"cfIcon":this.model.icons||(this.model.icons=[]),this.model.icons.push(r.model);break;default:this.model[u]=r.model}}}},{"../../base-xform":32,"../../composite-xform":48,"./cf-icon-ext-xform":74,"./cfvo-ext-xform":76}],82:[function(t,b,m){const c=t("../../base-xform");b.exports=class extends c{get tag(){return"xm:sqref"}render(i,s){i.leafNode(this.tag,null,s)}parseOpen(){this.model=""}parseText(i){this.model+=i}parseClose(i){return i!==this.tag}}},{"../../base-xform":32}],83:[function(t,b,m){const c=t("../../base-xform"),i=t("../../composite-xform"),s=t("../../../../doc/range"),n=t("./databar-xform"),e=t("./ext-lst-ref-xform"),r=t("./formula-xform"),u=t("./color-scale-xform"),a=t("./icon-set-xform"),o={"3Triangles":!0,"3Stars":!0,"5Boxes":!0},f=d=>{const{type:g,operator:p}=d;switch(g){case"containsText":case"containsBlanks":case"notContainsBlanks":case"containsErrors":case"notContainsErrors":return{type:"containsText",operator:g};default:return{type:g,operator:p}}};class h extends i{constructor(){super(),this.map={dataBar:this.databarXform=new n,extLst:this.extLstRefXform=new e,formula:this.formulaXform=new r,colorScale:this.colorScaleXform=new u,iconSet:this.iconSetXform=new a}}get tag(){return"cfRule"}static isPrimitive(g){return g.type!=="iconSet"||!g.custom&&!o[g.iconSet]}render(g,p){switch(p.type){case"expression":this.renderExpression(g,p);break;case"cellIs":this.renderCellIs(g,p);break;case"top10":this.renderTop10(g,p);break;case"aboveAverage":this.renderAboveAverage(g,p);break;case"dataBar":this.renderDataBar(g,p);break;case"colorScale":this.renderColorScale(g,p);break;case"iconSet":this.renderIconSet(g,p);break;case"containsText":this.renderText(g,p);break;case"timePeriod":this.renderTimePeriod(g,p)}}renderExpression(g,p){g.openNode(this.tag,{type:"expression",dxfId:p.dxfId,priority:p.priority}),this.formulaXform.render(g,p.formulae[0]),g.closeNode()}renderCellIs(g,p){g.openNode(this.tag,{type:"cellIs",dxfId:p.dxfId,priority:p.priority,operator:p.operator}),p.formulae.forEach(k=>{this.formulaXform.render(g,k)}),g.closeNode()}renderTop10(g,p){g.leafNode(this.tag,{type:"top10",dxfId:p.dxfId,priority:p.priority,percent:c.toBoolAttribute(p.percent,!1),bottom:c.toBoolAttribute(p.bottom,!1),rank:c.toIntValue(p.rank,10,!0)})}renderAboveAverage(g,p){g.leafNode(this.tag,{type:"aboveAverage",dxfId:p.dxfId,priority:p.priority,aboveAverage:c.toBoolAttribute(p.aboveAverage,!0)})}renderDataBar(g,p){g.openNode(this.tag,{type:"dataBar",priority:p.priority}),this.databarXform.render(g,p),this.extLstRefXform.render(g,p),g.closeNode()}renderColorScale(g,p){g.openNode(this.tag,{type:"colorScale",priority:p.priority}),this.colorScaleXform.render(g,p),g.closeNode()}renderIconSet(g,p){h.isPrimitive(p)&&(g.openNode(this.tag,{type:"iconSet",priority:p.priority}),this.iconSetXform.render(g,p),g.closeNode())}renderText(g,p){g.openNode(this.tag,{type:p.operator,dxfId:p.dxfId,priority:p.priority,operator:c.toStringAttribute(p.operator,"containsText")});const k=(C=>{if(C.formulae&&C.formulae[0])return C.formulae[0];const T=new s(C.ref),{tl:D}=T;switch(C.operator){case"containsText":return`NOT(ISERROR(SEARCH("${C.text}",${D})))`;case"containsBlanks":return`LEN(TRIM(${D}))=0`;case"notContainsBlanks":return`LEN(TRIM(${D}))>0`;case"containsErrors":return`ISERROR(${D})`;case"notContainsErrors":return`NOT(ISERROR(${D}))`;default:return}})(p);k&&this.formulaXform.render(g,k),g.closeNode()}renderTimePeriod(g,p){g.openNode(this.tag,{type:"timePeriod",dxfId:p.dxfId,priority:p.priority,timePeriod:p.timePeriod});const k=(C=>{if(C.formulae&&C.formulae[0])return C.formulae[0];const T=new s(C.ref),{tl:D}=T;switch(C.timePeriod){case"thisWeek":return`AND(TODAY()-ROUNDDOWN(${D},0)<=WEEKDAY(TODAY())-1,ROUNDDOWN(${D},0)-TODAY()<=7-WEEKDAY(TODAY()))`;case"lastWeek":return`AND(TODAY()-ROUNDDOWN(${D},0)>=(WEEKDAY(TODAY())),TODAY()-ROUNDDOWN(${D},0)<(WEEKDAY(TODAY())+7))`;case"nextWeek":return`AND(ROUNDDOWN(${D},0)-TODAY()>(7-WEEKDAY(TODAY())),ROUNDDOWN(${D},0)-TODAY()<(15-WEEKDAY(TODAY())))`;case"yesterday":return`FLOOR(${D},1)=TODAY()-1`;case"today":return`FLOOR(${D},1)=TODAY()`;case"tomorrow":return`FLOOR(${D},1)=TODAY()+1`;case"last7Days":return`AND(TODAY()-FLOOR(${D},1)<=6,FLOOR(${D},1)<=TODAY())`;case"lastMonth":return`AND(MONTH(${D})=MONTH(EDATE(TODAY(),0-1)),YEAR(${D})=YEAR(EDATE(TODAY(),0-1)))`;case"thisMonth":return`AND(MONTH(${D})=MONTH(TODAY()),YEAR(${D})=YEAR(TODAY()))`;case"nextMonth":return`AND(MONTH(${D})=MONTH(EDATE(TODAY(),0+1)),YEAR(${D})=YEAR(EDATE(TODAY(),0+1)))`;default:return}})(p);k&&this.formulaXform.render(g,k),g.closeNode()}createNewModel(g){let{attributes:p}=g;return{...f(p),dxfId:c.toIntValue(p.dxfId),priority:c.toIntValue(p.priority),timePeriod:p.timePeriod,percent:c.toBoolValue(p.percent),bottom:c.toBoolValue(p.bottom),rank:c.toIntValue(p.rank),aboveAverage:c.toBoolValue(p.aboveAverage)}}onParserClose(g,p){switch(g){case"dataBar":case"extLst":case"colorScale":case"iconSet":Object.assign(this.model,p.model);break;case"formula":this.model.formulae=this.model.formulae||[],this.model.formulae.push(p.model)}}}b.exports=h},{"../../../../doc/range":10,"../../base-xform":32,"../../composite-xform":48,"./color-scale-xform":85,"./databar-xform":88,"./ext-lst-ref-xform":89,"./formula-xform":90,"./icon-set-xform":91}],84:[function(t,b,m){const c=t("../../base-xform");b.exports=class extends c{get tag(){return"cfvo"}render(i,s){i.leafNode(this.tag,{type:s.type,val:s.value})}parseOpen(i){this.model={type:i.attributes.type,value:c.toFloatValue(i.attributes.val)}}parseClose(i){return i!==this.tag}}},{"../../base-xform":32}],85:[function(t,b,m){const c=t("../../composite-xform"),i=t("../../style/color-xform"),s=t("./cfvo-xform");b.exports=class extends c{constructor(){super(),this.map={cfvo:this.cfvoXform=new s,color:this.colorXform=new i}}get tag(){return"colorScale"}render(n,e){n.openNode(this.tag),e.cfvo.forEach(r=>{this.cfvoXform.render(n,r)}),e.color.forEach(r=>{this.colorXform.render(n,r)}),n.closeNode()}createNewModel(n){return{cfvo:[],color:[]}}onParserClose(n,e){this.model[n].push(e.model)}}},{"../../composite-xform":48,"../../style/color-xform":128,"./cfvo-xform":84}],86:[function(t,b,m){const c=t("../../composite-xform"),i=t("./cf-rule-xform");b.exports=class extends c{constructor(){super(),this.map={cfRule:new i}}get tag(){return"conditionalFormatting"}render(s,n){n.rules.some(i.isPrimitive)&&(s.openNode(this.tag,{sqref:n.ref}),n.rules.forEach(e=>{i.isPrimitive(e)&&(e.ref=n.ref,this.map.cfRule.render(s,e))}),s.closeNode())}createNewModel(s){let{attributes:n}=s;return{ref:n.sqref,rules:[]}}onParserClose(s,n){this.model.rules.push(n.model)}}},{"../../composite-xform":48,"./cf-rule-xform":83}],87:[function(t,b,m){const c=t("../../base-xform"),i=t("./conditional-formatting-xform");b.exports=class extends c{constructor(){super(),this.cfXform=new i}get tag(){return"conditionalFormatting"}reset(){this.model=[]}prepare(s,n){let e=s.reduce((r,u)=>Math.max(r,...u.rules.map(a=>a.priority||0)),1);s.forEach(r=>{r.rules.forEach(u=>{u.priority||(u.priority=e++),u.style&&(u.dxfId=n.styles.addDxfStyle(u.style))})})}render(s,n){n.forEach(e=>{this.cfXform.render(s,e)})}parseOpen(s){if(this.parser)return this.parser.parseOpen(s),!0;switch(s.name){case"conditionalFormatting":return this.parser=this.cfXform,this.parser.parseOpen(s),!0;default:return!1}}parseText(s){this.parser&&this.parser.parseText(s)}parseClose(s){return!!this.parser&&(!!this.parser.parseClose(s)||(this.model.push(this.parser.model),this.parser=void 0,!1))}reconcile(s,n){s.forEach(e=>{e.rules.forEach(r=>{r.dxfId!==void 0&&(r.style=n.styles.getDxfStyle(r.dxfId),delete r.dxfId)})})}}},{"../../base-xform":32,"./conditional-formatting-xform":86}],88:[function(t,b,m){const c=t("../../composite-xform"),i=t("../../style/color-xform"),s=t("./cfvo-xform");b.exports=class extends c{constructor(){super(),this.map={cfvo:this.cfvoXform=new s,color:this.colorXform=new i}}get tag(){return"dataBar"}render(n,e){n.openNode(this.tag),e.cfvo.forEach(r=>{this.cfvoXform.render(n,r)}),this.colorXform.render(n,e.color),n.closeNode()}createNewModel(){return{cfvo:[]}}onParserClose(n,e){switch(n){case"cfvo":this.model.cfvo.push(e.model);break;case"color":this.model.color=e.model}}}},{"../../composite-xform":48,"../../style/color-xform":128,"./cfvo-xform":84}],89:[function(t,b,m){const c=t("../../base-xform"),i=t("../../composite-xform");class s extends c{get tag(){return"x14:id"}render(r,u){r.leafNode(this.tag,null,u)}parseOpen(){this.model=""}parseText(r){this.model+=r}parseClose(r){return r!==this.tag}}class n extends i{constructor(){super(),this.map={"x14:id":this.idXform=new s}}get tag(){return"ext"}render(r,u){r.openNode(this.tag,{uri:"{B025F937-C7B1-47D3-B67F-A62EFF666E3E}","xmlns:x14":"http://schemas.microsoft.com/office/spreadsheetml/2009/9/main"}),this.idXform.render(r,u.x14Id),r.closeNode()}createNewModel(){return{}}onParserClose(r,u){this.model.x14Id=u.model}}b.exports=class extends i{constructor(){super(),this.map={ext:new n}}get tag(){return"extLst"}render(e,r){e.openNode(this.tag),this.map.ext.render(e,r),e.closeNode()}createNewModel(){return{}}onParserClose(e,r){Object.assign(this.model,r.model)}}},{"../../base-xform":32,"../../composite-xform":48}],90:[function(t,b,m){const c=t("../../base-xform");b.exports=class extends c{get tag(){return"formula"}render(i,s){i.leafNode(this.tag,null,s)}parseOpen(){this.model=""}parseText(i){this.model+=i}parseClose(i){return i!==this.tag}}},{"../../base-xform":32}],91:[function(t,b,m){const c=t("../../base-xform"),i=t("../../composite-xform"),s=t("./cfvo-xform");b.exports=class extends i{constructor(){super(),this.map={cfvo:this.cfvoXform=new s}}get tag(){return"iconSet"}render(n,e){n.openNode(this.tag,{iconSet:c.toStringAttribute(e.iconSet,"3TrafficLights"),reverse:c.toBoolAttribute(e.reverse,!1),showValue:c.toBoolAttribute(e.showValue,!0)}),e.cfvo.forEach(r=>{this.cfvoXform.render(n,r)}),n.closeNode()}createNewModel(n){let{attributes:e}=n;return{iconSet:c.toStringValue(e.iconSet,"3TrafficLights"),reverse:c.toBoolValue(e.reverse),showValue:c.toBoolValue(e.showValue),cfvo:[]}}onParserClose(n,e){this.model[n].push(e.model)}}},{"../../base-xform":32,"../../composite-xform":48,"./cfvo-xform":84}],92:[function(t,b,m){const c=t("../../../utils/utils"),i=t("../base-xform");b.exports=class extends i{get tag(){return"col"}prepare(s,n){const e=n.styles.addStyleModel(s.style||{});e&&(s.styleId=e)}render(s,n){s.openNode("col"),s.addAttribute("min",n.min),s.addAttribute("max",n.max),n.width&&s.addAttribute("width",n.width),n.styleId&&s.addAttribute("style",n.styleId),n.hidden&&s.addAttribute("hidden","1"),n.bestFit&&s.addAttribute("bestFit","1"),n.outlineLevel&&s.addAttribute("outlineLevel",n.outlineLevel),n.collapsed&&s.addAttribute("collapsed","1"),s.addAttribute("customWidth","1"),s.closeNode()}parseOpen(s){if(s.name==="col"){const n=this.model={min:parseInt(s.attributes.min||"0",10),max:parseInt(s.attributes.max||"0",10),width:s.attributes.width===void 0?void 0:parseFloat(s.attributes.width||"0")};return s.attributes.style&&(n.styleId=parseInt(s.attributes.style,10)),c.parseBoolean(s.attributes.hidden)&&(n.hidden=!0),c.parseBoolean(s.attributes.bestFit)&&(n.bestFit=!0),s.attributes.outlineLevel&&(n.outlineLevel=parseInt(s.attributes.outlineLevel,10)),c.parseBoolean(s.attributes.collapsed)&&(n.collapsed=!0),!0}return!1}parseText(){}parseClose(){return!1}reconcile(s,n){s.styleId&&(s.style=n.styles.getStyleModel(s.styleId))}}},{"../../../utils/utils":27,"../base-xform":32}],93:[function(t,b,m){const c=t("../../../utils/under-dash"),i=t("../../../utils/utils"),s=t("../../../utils/col-cache"),n=t("../base-xform"),e=t("../../../doc/range");function r(a,o,f,h){const d=o[f];d!==void 0?a[f]=d:h!==void 0&&(a[f]=h)}function u(a,o,f,h){const d=o[f];d!==void 0&&(a[f]=i.parseBoolean(d))}b.exports=class extends n{get tag(){return"dataValidations"}render(a,o){const f=function(h){const d=c.map(h,(k,C)=>({address:C,dataValidation:k,marked:!1})).sort((k,C)=>c.strcmp(k.address,C.address)),g=c.keyBy(d,"address"),p=(k,C,T)=>{for(let D=0;D<C;D++){const V=s.encodeAddress(k.row+D,T);if(!h[V]||!c.isEqual(h[k.address],h[V]))return!1}return!0};return d.map(k=>{if(!k.marked){const C=s.decodeEx(k.address);if(C.dimensions)return g[C.dimensions].marked=!0,{...k.dataValidation,sqref:k.address};let T=1,D=s.encodeAddress(C.row+T,C.col);for(;h[D]&&c.isEqual(k.dataValidation,h[D]);)T++,D=s.encodeAddress(C.row+T,C.col);let V=1;for(;p(C,T,C.col+V);)V++;for(let P=0;P<T;P++)for(let N=0;N<V;N++)D=s.encodeAddress(C.row+P,C.col+N),g[D].marked=!0;if(T>1||V>1){const P=C.row+(T-1),N=C.col+(V-1);return{...k.dataValidation,sqref:`${k.address}:${s.encodeAddress(P,N)}`}}return{...k.dataValidation,sqref:k.address}}return null}).filter(Boolean)}(o);f.length&&(a.openNode("dataValidations",{count:f.length}),f.forEach(h=>{a.openNode("dataValidation"),h.type!=="any"&&(a.addAttribute("type",h.type),h.operator&&h.type!=="list"&&h.operator!=="between"&&a.addAttribute("operator",h.operator),h.allowBlank&&a.addAttribute("allowBlank","1")),h.showInputMessage&&a.addAttribute("showInputMessage","1"),h.promptTitle&&a.addAttribute("promptTitle",h.promptTitle),h.prompt&&a.addAttribute("prompt",h.prompt),h.showErrorMessage&&a.addAttribute("showErrorMessage","1"),h.errorStyle&&a.addAttribute("errorStyle",h.errorStyle),h.errorTitle&&a.addAttribute("errorTitle",h.errorTitle),h.error&&a.addAttribute("error",h.error),a.addAttribute("sqref",h.sqref),(h.formulae||[]).forEach((d,g)=>{a.openNode("formula"+(g+1)),h.type==="date"?a.writeText(i.dateToExcel(new Date(d))):a.writeText(d),a.closeNode()}),a.closeNode()}),a.closeNode())}parseOpen(a){switch(a.name){case"dataValidations":return this.model={},!0;case"dataValidation":{this._address=a.attributes.sqref;const o={type:a.attributes.type||"any",formulae:[]};switch(a.attributes.type&&u(o,a.attributes,"allowBlank"),u(o,a.attributes,"showInputMessage"),u(o,a.attributes,"showErrorMessage"),o.type){case"any":case"list":case"custom":break;default:r(o,a.attributes,"operator","between")}return r(o,a.attributes,"promptTitle"),r(o,a.attributes,"prompt"),r(o,a.attributes,"errorStyle"),r(o,a.attributes,"errorTitle"),r(o,a.attributes,"error"),this._dataValidation=o,!0}case"formula1":case"formula2":return this._formula=[],!0;default:return!1}}parseText(a){this._formula&&this._formula.push(a)}parseClose(a){switch(a){case"dataValidations":return!1;case"dataValidation":return this._dataValidation.formulae&&this._dataValidation.formulae.length||(delete this._dataValidation.formulae,delete this._dataValidation.operator),(this._address.split(/\s+/g)||[]).forEach(o=>{o.includes(":")?new e(o).forEachAddress(f=>{this.model[f]=this._dataValidation}):this.model[o]=this._dataValidation}),!0;case"formula1":case"formula2":{let o=this._formula.join("");switch(this._dataValidation.type){case"whole":case"textLength":o=parseInt(o,10);break;case"decimal":o=parseFloat(o);break;case"date":o=i.excelToDate(parseFloat(o))}return this._dataValidation.formulae.push(o),this._formula=void 0,!0}default:return!0}}}},{"../../../doc/range":10,"../../../utils/col-cache":19,"../../../utils/under-dash":26,"../../../utils/utils":27,"../base-xform":32}],94:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"dimension"}render(i,s){s&&i.leafNode("dimension",{ref:s})}parseOpen(i){return i.name==="dimension"&&(this.model=i.attributes.ref,!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],95:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"drawing"}render(i,s){s&&i.leafNode(this.tag,{"r:id":s.rId})}parseOpen(i){switch(i.name){case this.tag:return this.model={rId:i.attributes["r:id"]},!0;default:return!1}}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],96:[function(t,b,m){const c=t("../composite-xform"),i=t("./cf-ext/conditional-formattings-ext-xform");class s extends c{constructor(){super(),this.map={"x14:conditionalFormattings":this.conditionalFormattings=new i}}get tag(){return"ext"}hasContent(e){return this.conditionalFormattings.hasContent(e.conditionalFormattings)}prepare(e,r){this.conditionalFormattings.prepare(e.conditionalFormattings,r)}render(e,r){e.openNode("ext",{uri:"{78C0D931-6437-407d-A8EE-F0AAD7539E65}","xmlns:x14":"http://schemas.microsoft.com/office/spreadsheetml/2009/9/main"}),this.conditionalFormattings.render(e,r.conditionalFormattings),e.closeNode()}createNewModel(){return{}}onParserClose(e,r){this.model[e]=r.model}}b.exports=class extends c{constructor(){super(),this.map={ext:this.ext=new s}}get tag(){return"extLst"}prepare(n,e){this.ext.prepare(n,e)}hasContent(n){return this.ext.hasContent(n)}render(n,e){this.hasContent(e)&&(n.openNode("extLst"),this.ext.render(n,e),n.closeNode())}createNewModel(){return{}}onParserClose(n,e){Object.assign(this.model,e.model)}}},{"../composite-xform":48,"./cf-ext/conditional-formattings-ext-xform":78}],97:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"headerFooter"}render(i,s){if(s){i.addRollback();let n=!1;i.openNode("headerFooter"),s.differentFirst&&(i.addAttribute("differentFirst","1"),n=!0),s.differentOddEven&&(i.addAttribute("differentOddEven","1"),n=!0),s.oddHeader&&typeof s.oddHeader=="string"&&(i.leafNode("oddHeader",null,s.oddHeader),n=!0),s.oddFooter&&typeof s.oddFooter=="string"&&(i.leafNode("oddFooter",null,s.oddFooter),n=!0),s.evenHeader&&typeof s.evenHeader=="string"&&(i.leafNode("evenHeader",null,s.evenHeader),n=!0),s.evenFooter&&typeof s.evenFooter=="string"&&(i.leafNode("evenFooter",null,s.evenFooter),n=!0),s.firstHeader&&typeof s.firstHeader=="string"&&(i.leafNode("firstHeader",null,s.firstHeader),n=!0),s.firstFooter&&typeof s.firstFooter=="string"&&(i.leafNode("firstFooter",null,s.firstFooter),n=!0),n?(i.closeNode(),i.commit()):i.rollback()}}parseOpen(i){switch(i.name){case"headerFooter":return this.model={},i.attributes.differentFirst&&(this.model.differentFirst=parseInt(i.attributes.differentFirst,0)===1),i.attributes.differentOddEven&&(this.model.differentOddEven=parseInt(i.attributes.differentOddEven,0)===1),!0;case"oddHeader":return this.currentNode="oddHeader",!0;case"oddFooter":return this.currentNode="oddFooter",!0;case"evenHeader":return this.currentNode="evenHeader",!0;case"evenFooter":return this.currentNode="evenFooter",!0;case"firstHeader":return this.currentNode="firstHeader",!0;case"firstFooter":return this.currentNode="firstFooter",!0;default:return!1}}parseText(i){switch(this.currentNode){case"oddHeader":this.model.oddHeader=i;break;case"oddFooter":this.model.oddFooter=i;break;case"evenHeader":this.model.evenHeader=i;break;case"evenFooter":this.model.evenFooter=i;break;case"firstHeader":this.model.firstHeader=i;break;case"firstFooter":this.model.firstFooter=i}}parseClose(){switch(this.currentNode){case"oddHeader":case"oddFooter":case"evenHeader":case"evenFooter":case"firstHeader":case"firstFooter":return this.currentNode=void 0,!0;default:return!1}}}},{"../base-xform":32}],98:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"hyperlink"}render(i,s){this.isInternalLink(s)?i.leafNode("hyperlink",{ref:s.address,"r:id":s.rId,tooltip:s.tooltip,location:s.target}):i.leafNode("hyperlink",{ref:s.address,"r:id":s.rId,tooltip:s.tooltip})}parseOpen(i){return i.name==="hyperlink"&&(this.model={address:i.attributes.ref,rId:i.attributes["r:id"],tooltip:i.attributes.tooltip},i.attributes.location&&(this.model.target=i.attributes.location),!0)}parseText(){}parseClose(){return!1}isInternalLink(i){return i.target&&/^[^!]+![a-zA-Z]+[\d]+$/.test(i.target)}}},{"../base-xform":32}],99:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"mergeCell"}render(i,s){i.leafNode("mergeCell",{ref:s})}parseOpen(i){return i.name==="mergeCell"&&(this.model=i.attributes.ref,!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],100:[function(t,b,m){const c=t("../../../utils/under-dash"),i=t("../../../doc/range"),s=t("../../../utils/col-cache"),n=t("../../../doc/enums");b.exports=class{constructor(){this.merges={}}add(e){if(this.merges[e.master])this.merges[e.master].expandToAddress(e.address);else{const r=`${e.master}:${e.address}`;this.merges[e.master]=new i(r)}}get mergeCells(){return c.map(this.merges,e=>e.range)}reconcile(e,r){c.each(e,u=>{const a=s.decode(u);for(let o=a.top;o<=a.bottom;o++){const f=r[o-1];for(let h=a.left;h<=a.right;h++){const d=f.cells[h-1];d?d.type===n.ValueType.Merge&&(d.master=a.tl):f.cells[h]={type:n.ValueType.Null,address:s.encodeAddress(o,h)}}}})}getMasterAddress(e){const r=this.hash[e];return r&&r.tl}}},{"../../../doc/enums":7,"../../../doc/range":10,"../../../utils/col-cache":19,"../../../utils/under-dash":26}],101:[function(t,b,m){const c=t("../base-xform"),i=s=>s!==void 0;b.exports=class extends c{get tag(){return"outlinePr"}render(s,n){return!(!n||!i(n.summaryBelow)&&!i(n.summaryRight))&&(s.leafNode(this.tag,{summaryBelow:i(n.summaryBelow)?Number(n.summaryBelow):void 0,summaryRight:i(n.summaryRight)?Number(n.summaryRight):void 0}),!0)}parseOpen(s){return s.name===this.tag&&(this.model={summaryBelow:i(s.attributes.summaryBelow)?!!Number(s.attributes.summaryBelow):void 0,summaryRight:i(s.attributes.summaryRight)?!!Number(s.attributes.summaryRight):void 0},!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],102:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"brk"}render(i,s){i.leafNode("brk",s)}parseOpen(i){return i.name==="brk"&&(this.model=i.attributes.ref,!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],103:[function(t,b,m){const c=t("../../../utils/under-dash"),i=t("../base-xform");b.exports=class extends i{get tag(){return"pageMargins"}render(s,n){if(n){const e={left:n.left,right:n.right,top:n.top,bottom:n.bottom,header:n.header,footer:n.footer};c.some(e,r=>r!==void 0)&&s.leafNode(this.tag,e)}}parseOpen(s){switch(s.name){case this.tag:return this.model={left:parseFloat(s.attributes.left||.7),right:parseFloat(s.attributes.right||.7),top:parseFloat(s.attributes.top||.75),bottom:parseFloat(s.attributes.bottom||.75),header:parseFloat(s.attributes.header||.3),footer:parseFloat(s.attributes.footer||.3)},!0;default:return!1}}parseText(){}parseClose(){return!1}}},{"../../../utils/under-dash":26,"../base-xform":32}],104:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"pageSetUpPr"}render(i,s){return!(!s||!s.fitToPage)&&(i.leafNode(this.tag,{fitToPage:s.fitToPage?"1":void 0}),!0)}parseOpen(i){return i.name===this.tag&&(this.model={fitToPage:i.attributes.fitToPage==="1"},!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],105:[function(t,b,m){const c=t("../../../utils/under-dash"),i=t("../base-xform");function s(u){return u?"1":void 0}function n(u){switch(u){case"overThenDown":return u;default:return}}function e(u){switch(u){case"atEnd":case"asDisplyed":return u;default:return}}function r(u){switch(u){case"dash":case"blank":case"NA":return u;default:return}}b.exports=class extends i{get tag(){return"pageSetup"}render(u,a){if(a){const o={paperSize:a.paperSize,orientation:a.orientation,horizontalDpi:a.horizontalDpi,verticalDpi:a.verticalDpi,pageOrder:n(a.pageOrder),blackAndWhite:s(a.blackAndWhite),draft:s(a.draft),cellComments:e(a.cellComments),errors:r(a.errors),scale:a.scale,fitToWidth:a.fitToWidth,fitToHeight:a.fitToHeight,firstPageNumber:a.firstPageNumber,useFirstPageNumber:s(a.firstPageNumber),usePrinterDefaults:s(a.usePrinterDefaults),copies:a.copies};c.some(o,f=>f!==void 0)&&u.leafNode(this.tag,o)}}parseOpen(u){switch(u.name){case this.tag:return this.model={paperSize:(a=u.attributes.paperSize,a!==void 0?parseInt(a,10):void 0),orientation:u.attributes.orientation||"portrait",horizontalDpi:parseInt(u.attributes.horizontalDpi||"4294967295",10),verticalDpi:parseInt(u.attributes.verticalDpi||"4294967295",10),pageOrder:u.attributes.pageOrder||"downThenOver",blackAndWhite:u.attributes.blackAndWhite==="1",draft:u.attributes.draft==="1",cellComments:u.attributes.cellComments||"None",errors:u.attributes.errors||"displayed",scale:parseInt(u.attributes.scale||"100",10),fitToWidth:parseInt(u.attributes.fitToWidth||"1",10),fitToHeight:parseInt(u.attributes.fitToHeight||"1",10),firstPageNumber:parseInt(u.attributes.firstPageNumber||"1",10),useFirstPageNumber:u.attributes.useFirstPageNumber==="1",usePrinterDefaults:u.attributes.usePrinterDefaults==="1",copies:parseInt(u.attributes.copies||"1",10)},!0;default:return!1}var a}parseText(){}parseClose(){return!1}}},{"../../../utils/under-dash":26,"../base-xform":32}],106:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"picture"}render(i,s){s&&i.leafNode(this.tag,{"r:id":s.rId})}parseOpen(i){switch(i.name){case this.tag:return this.model={rId:i.attributes["r:id"]},!0;default:return!1}}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],107:[function(t,b,m){const c=t("../../../utils/under-dash"),i=t("../base-xform");function s(n){return n?"1":void 0}b.exports=class extends i{get tag(){return"printOptions"}render(n,e){if(e){const r={headings:s(e.showRowColHeaders),gridLines:s(e.showGridLines),horizontalCentered:s(e.horizontalCentered),verticalCentered:s(e.verticalCentered)};c.some(r,u=>u!==void 0)&&n.leafNode(this.tag,r)}}parseOpen(n){switch(n.name){case this.tag:return this.model={showRowColHeaders:n.attributes.headings==="1",showGridLines:n.attributes.gridLines==="1",horizontalCentered:n.attributes.horizontalCentered==="1",verticalCentered:n.attributes.verticalCentered==="1"},!0;default:return!1}}parseText(){}parseClose(){return!1}}},{"../../../utils/under-dash":26,"../base-xform":32}],108:[function(t,b,m){const c=t("./page-breaks-xform"),i=t("../list-xform");b.exports=class extends i{constructor(){super({tag:"rowBreaks",count:!0,childXform:new c})}render(s,n){if(n&&n.length){s.openNode(this.tag,this.$),this.count&&(s.addAttribute(this.$count,n.length),s.addAttribute("manualBreakCount",n.length));const{childXform:e}=this;n.forEach(r=>{e.render(s,r)}),s.closeNode()}else this.empty&&s.leafNode(this.tag)}}},{"../list-xform":71,"./page-breaks-xform":102}],109:[function(t,b,m){const c=t("../base-xform"),i=t("../../../utils/utils"),s=t("./cell-xform");b.exports=class extends c{constructor(n){super(),this.maxItems=n&&n.maxItems,this.map={c:new s}}get tag(){return"row"}prepare(n,e){const r=e.styles.addStyleModel(n.style);r&&(n.styleId=r);const u=this.map.c;n.cells.forEach(a=>{u.prepare(a,e)})}render(n,e,r){n.openNode("row"),n.addAttribute("r",e.number),e.height&&(n.addAttribute("ht",e.height),n.addAttribute("customHeight","1")),e.hidden&&n.addAttribute("hidden","1"),e.min>0&&e.max>0&&e.min<=e.max&&n.addAttribute("spans",`${e.min}:${e.max}`),e.styleId&&(n.addAttribute("s",e.styleId),n.addAttribute("customFormat","1")),n.addAttribute("x14ac:dyDescent","0.25"),e.outlineLevel&&n.addAttribute("outlineLevel",e.outlineLevel),e.collapsed&&n.addAttribute("collapsed","1");const u=this.map.c;e.cells.forEach(a=>{u.render(n,a,r)}),n.closeNode()}parseOpen(n){if(this.parser)return this.parser.parseOpen(n),!0;if(n.name==="row"){this.numRowsSeen+=1;const e=n.attributes.spans?n.attributes.spans.split(":").map(u=>parseInt(u,10)):[void 0,void 0],r=this.model={number:parseInt(n.attributes.r,10),min:e[0],max:e[1],cells:[]};return n.attributes.s&&(r.styleId=parseInt(n.attributes.s,10)),i.parseBoolean(n.attributes.hidden)&&(r.hidden=!0),i.parseBoolean(n.attributes.bestFit)&&(r.bestFit=!0),n.attributes.ht&&(r.height=parseFloat(n.attributes.ht)),n.attributes.outlineLevel&&(r.outlineLevel=parseInt(n.attributes.outlineLevel,10)),i.parseBoolean(n.attributes.collapsed)&&(r.collapsed=!0),!0}return this.parser=this.map[n.name],!!this.parser&&(this.parser.parseOpen(n),!0)}parseText(n){this.parser&&this.parser.parseText(n)}parseClose(n){if(this.parser){if(!this.parser.parseClose(n)){if(this.model.cells.push(this.parser.model),this.maxItems&&this.model.cells.length>this.maxItems)throw new Error(`Max column count (${this.maxItems}) exceeded`);this.parser=void 0}return!0}return!1}reconcile(n,e){n.style=n.styleId?e.styles.getStyleModel(n.styleId):{},n.styleId!==void 0&&(n.styleId=void 0);const r=this.map.c;n.cells.forEach(u=>{r.reconcile(u,e)})}}},{"../../../utils/utils":27,"../base-xform":32,"./cell-xform":73}],110:[function(t,b,m){const c=t("../../../utils/under-dash"),i=t("../base-xform");b.exports=class extends i{get tag(){return"sheetFormatPr"}render(s,n){if(n){const e={defaultRowHeight:n.defaultRowHeight,outlineLevelRow:n.outlineLevelRow,outlineLevelCol:n.outlineLevelCol,"x14ac:dyDescent":n.dyDescent};n.defaultColWidth&&(e.defaultColWidth=n.defaultColWidth),n.defaultRowHeight&&n.defaultRowHeight===15||(e.customHeight="1"),c.some(e,r=>r!==void 0)&&s.leafNode("sheetFormatPr",e)}}parseOpen(s){return s.name==="sheetFormatPr"&&(this.model={defaultRowHeight:parseFloat(s.attributes.defaultRowHeight||"0"),dyDescent:parseFloat(s.attributes["x14ac:dyDescent"]||"0"),outlineLevelRow:parseInt(s.attributes.outlineLevelRow||"0",10),outlineLevelCol:parseInt(s.attributes.outlineLevelCol||"0",10)},s.attributes.defaultColWidth&&(this.model.defaultColWidth=parseFloat(s.attributes.defaultColWidth)),!0)}parseText(){}parseClose(){return!1}}},{"../../../utils/under-dash":26,"../base-xform":32}],111:[function(t,b,m){const c=t("../base-xform"),i=t("../style/color-xform"),s=t("./page-setup-properties-xform"),n=t("./outline-properties-xform");b.exports=class extends c{constructor(){super(),this.map={tabColor:new i("tabColor"),pageSetUpPr:new s,outlinePr:new n}}get tag(){return"sheetPr"}render(e,r){if(r){e.addRollback(),e.openNode("sheetPr");let u=!1;u=this.map.tabColor.render(e,r.tabColor)||u,u=this.map.pageSetUpPr.render(e,r.pageSetup)||u,u=this.map.outlinePr.render(e,r.outlineProperties)||u,u?(e.closeNode(),e.commit()):e.rollback()}}parseOpen(e){return this.parser?(this.parser.parseOpen(e),!0):e.name===this.tag?(this.reset(),!0):!!this.map[e.name]&&(this.parser=this.map[e.name],this.parser.parseOpen(e),!0)}parseText(e){return!!this.parser&&(this.parser.parseText(e),!0)}parseClose(e){return this.parser?(this.parser.parseClose(e)||(this.parser=void 0),!0):(this.map.tabColor.model||this.map.pageSetUpPr.model||this.map.outlinePr.model?(this.model={},this.map.tabColor.model&&(this.model.tabColor=this.map.tabColor.model),this.map.pageSetUpPr.model&&(this.model.pageSetup=this.map.pageSetUpPr.model),this.map.outlinePr.model&&(this.model.outlineProperties=this.map.outlinePr.model)):this.model=null,!1)}}},{"../base-xform":32,"../style/color-xform":128,"./outline-properties-xform":101,"./page-setup-properties-xform":104}],112:[function(t,b,m){const c=t("../../../utils/under-dash"),i=t("../base-xform");function s(e,r){return e?r:void 0}function n(e,r){return e===r||void 0}b.exports=class extends i{get tag(){return"sheetProtection"}render(e,r){if(r){const u={sheet:s(r.sheet,"1"),selectLockedCells:r.selectLockedCells===!1?"1":void 0,selectUnlockedCells:r.selectUnlockedCells===!1?"1":void 0,formatCells:s(r.formatCells,"0"),formatColumns:s(r.formatColumns,"0"),formatRows:s(r.formatRows,"0"),insertColumns:s(r.insertColumns,"0"),insertRows:s(r.insertRows,"0"),insertHyperlinks:s(r.insertHyperlinks,"0"),deleteColumns:s(r.deleteColumns,"0"),deleteRows:s(r.deleteRows,"0"),sort:s(r.sort,"0"),autoFilter:s(r.autoFilter,"0"),pivotTables:s(r.pivotTables,"0")};r.sheet&&(u.algorithmName=r.algorithmName,u.hashValue=r.hashValue,u.saltValue=r.saltValue,u.spinCount=r.spinCount,u.objects=s(r.objects===!1,"1"),u.scenarios=s(r.scenarios===!1,"1")),c.some(u,a=>a!==void 0)&&e.leafNode(this.tag,u)}}parseOpen(e){switch(e.name){case this.tag:return this.model={sheet:n(e.attributes.sheet,"1"),objects:e.attributes.objects!=="1"&&void 0,scenarios:e.attributes.scenarios!=="1"&&void 0,selectLockedCells:e.attributes.selectLockedCells!=="1"&&void 0,selectUnlockedCells:e.attributes.selectUnlockedCells!=="1"&&void 0,formatCells:n(e.attributes.formatCells,"0"),formatColumns:n(e.attributes.formatColumns,"0"),formatRows:n(e.attributes.formatRows,"0"),insertColumns:n(e.attributes.insertColumns,"0"),insertRows:n(e.attributes.insertRows,"0"),insertHyperlinks:n(e.attributes.insertHyperlinks,"0"),deleteColumns:n(e.attributes.deleteColumns,"0"),deleteRows:n(e.attributes.deleteRows,"0"),sort:n(e.attributes.sort,"0"),autoFilter:n(e.attributes.autoFilter,"0"),pivotTables:n(e.attributes.pivotTables,"0")},e.attributes.algorithmName&&(this.model.algorithmName=e.attributes.algorithmName,this.model.hashValue=e.attributes.hashValue,this.model.saltValue=e.attributes.saltValue,this.model.spinCount=parseInt(e.attributes.spinCount,10)),!0;default:return!1}}parseText(){}parseClose(){return!1}}},{"../../../utils/under-dash":26,"../base-xform":32}],113:[function(t,b,m){const c=t("../../../utils/col-cache"),i=t("../base-xform"),s={frozen:"frozen",frozenSplit:"frozen",split:"split"};b.exports=class extends i{get tag(){return"sheetView"}prepare(n){switch(n.state){case"frozen":case"split":break;default:n.state="normal"}}render(n,e){n.openNode("sheetView",{workbookViewId:e.workbookViewId||0});const r=function(h,d,g){g&&n.addAttribute(h,d)};let u,a,o,f;switch(r("rightToLeft","1",e.rightToLeft===!0),r("tabSelected","1",e.tabSelected),r("showRuler","0",e.showRuler===!1),r("showRowColHeaders","0",e.showRowColHeaders===!1),r("showGridLines","0",e.showGridLines===!1),r("zoomScale",e.zoomScale,e.zoomScale),r("zoomScaleNormal",e.zoomScaleNormal,e.zoomScaleNormal),r("view",e.style,e.style),e.state){case"frozen":a=e.xSplit||0,o=e.ySplit||0,u=e.topLeftCell||c.getAddress(o+1,a+1).address,f=(e.xSplit&&e.ySplit?"bottomRight":e.xSplit&&"topRight")||"bottomLeft",n.leafNode("pane",{xSplit:e.xSplit||void 0,ySplit:e.ySplit||void 0,topLeftCell:u,activePane:f,state:"frozen"}),n.leafNode("selection",{pane:f,activeCell:e.activeCell,sqref:e.activeCell});break;case"split":e.activePane==="topLeft"&&(e.activePane=void 0),n.leafNode("pane",{xSplit:e.xSplit||void 0,ySplit:e.ySplit||void 0,topLeftCell:e.topLeftCell,activePane:e.activePane}),n.leafNode("selection",{pane:e.activePane,activeCell:e.activeCell,sqref:e.activeCell});break;case"normal":e.activeCell&&n.leafNode("selection",{activeCell:e.activeCell,sqref:e.activeCell})}n.closeNode()}parseOpen(n){switch(n.name){case"sheetView":return this.sheetView={workbookViewId:parseInt(n.attributes.workbookViewId,10),rightToLeft:n.attributes.rightToLeft==="1",tabSelected:n.attributes.tabSelected==="1",showRuler:n.attributes.showRuler!=="0",showRowColHeaders:n.attributes.showRowColHeaders!=="0",showGridLines:n.attributes.showGridLines!=="0",zoomScale:parseInt(n.attributes.zoomScale||"100",10),zoomScaleNormal:parseInt(n.attributes.zoomScaleNormal||"100",10),style:n.attributes.view},this.pane=void 0,this.selections={},!0;case"pane":return this.pane={xSplit:parseInt(n.attributes.xSplit||"0",10),ySplit:parseInt(n.attributes.ySplit||"0",10),topLeftCell:n.attributes.topLeftCell,activePane:n.attributes.activePane||"topLeft",state:n.attributes.state},!0;case"selection":{const e=n.attributes.pane||"topLeft";return this.selections[e]={pane:e,activeCell:n.attributes.activeCell},!0}default:return!1}}parseText(){}parseClose(n){let e,r;switch(n){case"sheetView":return this.sheetView&&this.pane?(e=this.model={workbookViewId:this.sheetView.workbookViewId,rightToLeft:this.sheetView.rightToLeft,state:s[this.pane.state]||"split",xSplit:this.pane.xSplit,ySplit:this.pane.ySplit,topLeftCell:this.pane.topLeftCell,showRuler:this.sheetView.showRuler,showRowColHeaders:this.sheetView.showRowColHeaders,showGridLines:this.sheetView.showGridLines,zoomScale:this.sheetView.zoomScale,zoomScaleNormal:this.sheetView.zoomScaleNormal},this.model.state==="split"&&(e.activePane=this.pane.activePane),r=this.selections[this.pane.activePane],r&&r.activeCell&&(e.activeCell=r.activeCell),this.sheetView.style&&(e.style=this.sheetView.style)):(e=this.model={workbookViewId:this.sheetView.workbookViewId,rightToLeft:this.sheetView.rightToLeft,state:"normal",showRuler:this.sheetView.showRuler,showRowColHeaders:this.sheetView.showRowColHeaders,showGridLines:this.sheetView.showGridLines,zoomScale:this.sheetView.zoomScale,zoomScaleNormal:this.sheetView.zoomScaleNormal},r=this.selections.topLeft,r&&r.activeCell&&(e.activeCell=r.activeCell),this.sheetView.style&&(e.style=this.sheetView.style)),!1;default:return!0}}reconcile(){}}},{"../../../utils/col-cache":19,"../base-xform":32}],114:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"tablePart"}render(i,s){s&&i.leafNode(this.tag,{"r:id":s.rId})}parseOpen(i){switch(i.name){case this.tag:return this.model={rId:i.attributes["r:id"]},!0;default:return!1}}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],115:[function(t,b,m){const c=t("../../../utils/under-dash"),i=t("../../../utils/col-cache"),s=t("../../../utils/xml-stream"),n=t("../../rel-type"),e=t("./merges"),r=t("../base-xform"),u=t("../list-xform"),a=t("./row-xform"),o=t("./col-xform"),f=t("./dimension-xform"),h=t("./hyperlink-xform"),d=t("./merge-cell-xform"),g=t("./data-validations-xform"),p=t("./sheet-properties-xform"),k=t("./sheet-format-properties-xform"),C=t("./sheet-view-xform"),T=t("./sheet-protection-xform"),D=t("./page-margins-xform"),V=t("./page-setup-xform"),P=t("./print-options-xform"),N=t("./auto-filter-xform"),q=t("./picture-xform"),W=t("./drawing-xform"),L=t("./table-part-xform"),A=t("./row-breaks-xform"),M=t("./header-footer-xform"),_=t("./cf/conditional-formattings-xform"),y=t("./ext-lst-xform"),x=(S,E)=>{if(!E||!E.length)return S;if(!S||!S.length)return E;const O={},R={};return S.forEach(z=>{O[z.ref]=z,z.rules.forEach(U=>{const{x14Id:Q}=U;Q&&(R[Q]=U)})}),E.forEach(z=>{z.rules.forEach(U=>{const Q=R[U.x14Id];Q?((j,Y)=>{Object.keys(Y).forEach(F=>{const I=j[F],H=Y[F];I===void 0&&H!==void 0&&(j[F]=H)})})(Q,U):O[z.ref]?O[z.ref].rules.push(U):S.push({ref:z.ref,rules:[U]})})}),S};class w extends r{constructor(E){super();const{maxRows:O,maxCols:R,ignoreNodes:z}=E||{};this.ignoreNodes=z||[],this.map={sheetPr:new p,dimension:new f,sheetViews:new u({tag:"sheetViews",count:!1,childXform:new C}),sheetFormatPr:new k,cols:new u({tag:"cols",count:!1,childXform:new o}),sheetData:new u({tag:"sheetData",count:!1,empty:!0,childXform:new a({maxItems:R}),maxItems:O}),autoFilter:new N,mergeCells:new u({tag:"mergeCells",count:!0,childXform:new d}),rowBreaks:new A,hyperlinks:new u({tag:"hyperlinks",count:!1,childXform:new h}),pageMargins:new D,dataValidations:new g,pageSetup:new V,headerFooter:new M,printOptions:new P,picture:new q,drawing:new W,sheetProtection:new T,tableParts:new u({tag:"tableParts",count:!0,childXform:new L}),conditionalFormatting:new _,extLst:new y}}prepare(E,O){O.merges=new e,E.hyperlinks=O.hyperlinks=[],E.comments=O.comments=[],O.formulae={},O.siFormulae=0,this.map.cols.prepare(E.cols,O),this.map.sheetData.prepare(E.rows,O),this.map.conditionalFormatting.prepare(E.conditionalFormattings,O),E.mergeCells=O.merges.mergeCells;const R=E.rels=[];function z(j){return"rId"+(j.length+1)}if(E.hyperlinks.forEach(j=>{const Y=z(R);j.rId=Y,R.push({Id:Y,Type:n.Hyperlink,Target:j.target,TargetMode:"External"})}),E.comments.length>0){const j={Id:z(R),Type:n.Comments,Target:`../comments${E.id}.xml`};R.push(j);const Y={Id:z(R),Type:n.VmlDrawing,Target:`../drawings/vmlDrawing${E.id}.vml`};R.push(Y),E.comments.forEach(F=>{F.refAddress=i.decodeAddress(F.ref)}),O.commentRefs.push({commentName:"comments"+E.id,vmlDrawing:"vmlDrawing"+E.id})}const U=[];let Q;E.media.forEach(j=>{if(j.type==="background"){const Y=z(R);Q=O.media[j.imageId],R.push({Id:Y,Type:n.Image,Target:`../media/${Q.name}.${Q.extension}`}),E.background={rId:Y},E.image=O.media[j.imageId]}else if(j.type==="image"){let{drawing:Y}=E;Q=O.media[j.imageId],Y||(Y=E.drawing={rId:z(R),name:"drawing"+ ++O.drawingsCount,anchors:[],rels:[]},O.drawings.push(Y),R.push({Id:Y.rId,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/drawing",Target:`../drawings/${Y.name}.xml`}));let F=this.preImageId===j.imageId?U[j.imageId]:U[Y.rels.length];F||(F=z(Y.rels),U[Y.rels.length]=F,Y.rels.push({Id:F,Type:"http://schemas.openxmlformats.org/officeDocument/2006/relationships/image",Target:`../media/${Q.name}.${Q.extension}`}));const I={picture:{rId:F},range:j.range};if(j.hyperlinks&&j.hyperlinks.hyperlink){const H=z(Y.rels);U[Y.rels.length]=H,I.picture.hyperlinks={tooltip:j.hyperlinks.tooltip,rId:H},Y.rels.push({Id:H,Type:n.Hyperlink,Target:j.hyperlinks.hyperlink,TargetMode:"External"})}this.preImageId=j.imageId,Y.anchors.push(I)}}),E.tables.forEach(j=>{const Y=z(R);j.rId=Y,R.push({Id:Y,Type:n.Table,Target:"../tables/"+j.target}),j.columns.forEach(F=>{const{style:I}=F;I&&(F.dxfId=O.styles.addDxfStyle(I))})}),this.map.extLst.prepare(E,O)}render(E,O){E.openXml(s.StdDocAttributes),E.openNode("worksheet",w.WORKSHEET_ATTRIBUTES);const R=O.properties?{defaultRowHeight:O.properties.defaultRowHeight,dyDescent:O.properties.dyDescent,outlineLevelCol:O.properties.outlineLevelCol,outlineLevelRow:O.properties.outlineLevelRow}:void 0;O.properties&&O.properties.defaultColWidth&&(R.defaultColWidth=O.properties.defaultColWidth);const z={outlineProperties:O.properties&&O.properties.outlineProperties,tabColor:O.properties&&O.properties.tabColor,pageSetup:O.pageSetup&&O.pageSetup.fitToPage?{fitToPage:O.pageSetup.fitToPage}:void 0},U=O.pageSetup&&O.pageSetup.margins,Q={showRowColHeaders:O.pageSetup&&O.pageSetup.showRowColHeaders,showGridLines:O.pageSetup&&O.pageSetup.showGridLines,horizontalCentered:O.pageSetup&&O.pageSetup.horizontalCentered,verticalCentered:O.pageSetup&&O.pageSetup.verticalCentered},j=O.sheetProtection;this.map.sheetPr.render(E,z),this.map.dimension.render(E,O.dimensions),this.map.sheetViews.render(E,O.views),this.map.sheetFormatPr.render(E,R),this.map.cols.render(E,O.cols),this.map.sheetData.render(E,O.rows),this.map.sheetProtection.render(E,j),this.map.autoFilter.render(E,O.autoFilter),this.map.mergeCells.render(E,O.mergeCells),this.map.conditionalFormatting.render(E,O.conditionalFormattings),this.map.dataValidations.render(E,O.dataValidations),this.map.hyperlinks.render(E,O.hyperlinks),this.map.printOptions.render(E,Q),this.map.pageMargins.render(E,U),this.map.pageSetup.render(E,O.pageSetup),this.map.headerFooter.render(E,O.headerFooter),this.map.rowBreaks.render(E,O.rowBreaks),this.map.drawing.render(E,O.drawing),this.map.picture.render(E,O.background),this.map.tableParts.render(E,O.tables),this.map.extLst.render(E,O),O.rels&&O.rels.forEach(Y=>{Y.Type===n.VmlDrawing&&E.leafNode("legacyDrawing",{"r:id":Y.Id})}),E.closeNode()}parseOpen(E){return this.parser?(this.parser.parseOpen(E),!0):E.name==="worksheet"?(c.each(this.map,O=>{O.reset()}),!0):(this.map[E.name]&&!this.ignoreNodes.includes(E.name)&&(this.parser=this.map[E.name],this.parser.parseOpen(E)),!0)}parseText(E){this.parser&&this.parser.parseText(E)}parseClose(E){if(this.parser)return this.parser.parseClose(E)||(this.parser=void 0),!0;switch(E){case"worksheet":{const O=this.map.sheetFormatPr.model||{};this.map.sheetPr.model&&this.map.sheetPr.model.tabColor&&(O.tabColor=this.map.sheetPr.model.tabColor),this.map.sheetPr.model&&this.map.sheetPr.model.outlineProperties&&(O.outlineProperties=this.map.sheetPr.model.outlineProperties);const R={fitToPage:this.map.sheetPr.model&&this.map.sheetPr.model.pageSetup&&this.map.sheetPr.model.pageSetup.fitToPage||!1,margins:this.map.pageMargins.model},z=Object.assign(R,this.map.pageSetup.model,this.map.printOptions.model),U=x(this.map.conditionalFormatting.model,this.map.extLst.model&&this.map.extLst.model["x14:conditionalFormattings"]);return this.model={dimensions:this.map.dimension.model,cols:this.map.cols.model,rows:this.map.sheetData.model,mergeCells:this.map.mergeCells.model,hyperlinks:this.map.hyperlinks.model,dataValidations:this.map.dataValidations.model,properties:O,views:this.map.sheetViews.model,pageSetup:z,headerFooter:this.map.headerFooter.model,background:this.map.picture.model,drawing:this.map.drawing.model,tables:this.map.tableParts.model,conditionalFormattings:U},this.map.autoFilter.model&&(this.model.autoFilter=this.map.autoFilter.model),this.map.sheetProtection.model&&(this.model.sheetProtection=this.map.sheetProtection.model),!1}default:return!0}}reconcile(E,O){const R=(E.relationships||[]).reduce((U,Q)=>{if(U[Q.Id]=Q,Q.Type===n.Comments&&(E.comments=O.comments[Q.Target].comments),Q.Type===n.VmlDrawing&&E.comments&&E.comments.length){const j=O.vmlDrawings[Q.Target].comments;E.comments.forEach((Y,F)=>{Y.note=Object.assign({},Y.note,j[F])})}return U},{});if(O.commentsMap=(E.comments||[]).reduce((U,Q)=>(Q.ref&&(U[Q.ref]=Q),U),{}),O.hyperlinkMap=(E.hyperlinks||[]).reduce((U,Q)=>(Q.rId&&(U[Q.address]=R[Q.rId].Target),U),{}),O.formulae={},E.rows=E.rows&&E.rows.filter(Boolean)||[],E.rows.forEach(U=>{U.cells=U.cells&&U.cells.filter(Boolean)||[]}),this.map.cols.reconcile(E.cols,O),this.map.sheetData.reconcile(E.rows,O),this.map.conditionalFormatting.reconcile(E.conditionalFormattings,O),E.media=[],E.drawing){const U=R[E.drawing.rId].Target.match(/\/drawings\/([a-zA-Z0-9]+)[.][a-zA-Z]{3,4}$/);if(U){const Q=U[1];O.drawings[Q].anchors.forEach(j=>{if(j.medium){const Y={type:"image",imageId:j.medium.index,range:j.range,hyperlinks:j.picture.hyperlinks};E.media.push(Y)}})}}const z=E.background&&R[E.background.rId];if(z){const U=z.Target.split("/media/")[1],Q=O.mediaIndex&&O.mediaIndex[U];Q!==void 0&&E.media.push({type:"background",imageId:Q})}E.tables=(E.tables||[]).map(U=>{const Q=R[U.rId];return O.tables[Q.Target]}),delete E.relationships,delete E.hyperlinks,delete E.comments}}w.WORKSHEET_ATTRIBUTES={xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main","xmlns:r":"http://schemas.openxmlformats.org/officeDocument/2006/relationships","xmlns:mc":"http://schemas.openxmlformats.org/markup-compatibility/2006","mc:Ignorable":"x14ac","xmlns:x14ac":"http://schemas.microsoft.com/office/spreadsheetml/2009/9/ac"},b.exports=w},{"../../../utils/col-cache":19,"../../../utils/under-dash":26,"../../../utils/xml-stream":28,"../../rel-type":31,"../base-xform":32,"../list-xform":71,"./auto-filter-xform":72,"./cf/conditional-formattings-xform":87,"./col-xform":92,"./data-validations-xform":93,"./dimension-xform":94,"./drawing-xform":95,"./ext-lst-xform":96,"./header-footer-xform":97,"./hyperlink-xform":98,"./merge-cell-xform":99,"./merges":100,"./page-margins-xform":103,"./page-setup-xform":105,"./picture-xform":106,"./print-options-xform":107,"./row-breaks-xform":108,"./row-xform":109,"./sheet-format-properties-xform":110,"./sheet-properties-xform":111,"./sheet-protection-xform":112,"./sheet-view-xform":113,"./table-part-xform":114}],116:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{constructor(i){super(),this.tag=i.tag,this.attr=i.attr}render(i,s){s&&(i.openNode(this.tag),i.closeNode())}parseOpen(i){i.name===this.tag&&(this.model=!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],117:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{constructor(i){super(),this.tag=i.tag,this.attr=i.attr,this.attrs=i.attrs,this._format=i.format||function(s){try{return Number.isNaN(s.getTime())?"":s.toISOString()}catch{return""}},this._parse=i.parse||function(s){return new Date(s)}}render(i,s){s&&(i.openNode(this.tag),this.attrs&&i.addAttributes(this.attrs),this.attr?i.addAttribute(this.attr,this._format(s)):i.writeText(this._format(s)),i.closeNode())}parseOpen(i){i.name===this.tag&&(this.attr?this.model=this._parse(i.attributes[this.attr]):this.text=[])}parseText(i){this.attr||this.text.push(i)}parseClose(){return this.attr||(this.model=this._parse(this.text.join(""))),!1}}},{"../base-xform":32}],118:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{constructor(i){super(),this.tag=i.tag,this.attr=i.attr,this.attrs=i.attrs,this.zero=i.zero}render(i,s){(s||this.zero)&&(i.openNode(this.tag),this.attrs&&i.addAttributes(this.attrs),this.attr?i.addAttribute(this.attr,s):i.writeText(s),i.closeNode())}parseOpen(i){return i.name===this.tag&&(this.attr?this.model=parseInt(i.attributes[this.attr],10):this.text=[],!0)}parseText(i){this.attr||this.text.push(i)}parseClose(){return this.attr||(this.model=parseInt(this.text.join("")||0,10)),!1}}},{"../base-xform":32}],119:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{constructor(i){super(),this.tag=i.tag,this.attr=i.attr,this.attrs=i.attrs}render(i,s){s!==void 0&&(i.openNode(this.tag),this.attrs&&i.addAttributes(this.attrs),this.attr?i.addAttribute(this.attr,s):i.writeText(s),i.closeNode())}parseOpen(i){i.name===this.tag&&(this.attr?this.model=i.attributes[this.attr]:this.text=[])}parseText(i){this.attr||this.text.push(i)}parseClose(){return this.attr||(this.model=this.text.join("")),!1}}},{"../base-xform":32}],120:[function(t,b,m){const c=t("./base-xform"),i=t("../../utils/xml-stream");b.exports=class extends c{constructor(s){super(),this._model=s}render(s){if(!this._xml){const n=new i;(function e(r,u){r.openNode(u.tag,u.$),u.c&&u.c.forEach(a=>{e(r,a)}),u.t&&r.writeText(u.t),r.closeNode()})(n,this._model),this._xml=n.xml}s.writeXml(this._xml)}parseOpen(){return!0}parseText(){}parseClose(s){switch(s){case this._model.tag:return!1;default:return!0}}}},{"../../utils/xml-stream":28,"./base-xform":32}],121:[function(t,b,m){const c=t("./text-xform"),i=t("./rich-text-xform"),s=t("../base-xform");b.exports=class extends s{constructor(){super(),this.map={r:new i,t:new c}}get tag(){return"rPh"}render(n,e){if(n.openNode(this.tag,{sb:e.sb||0,eb:e.eb||0}),e&&e.hasOwnProperty("richText")&&e.richText){const{r}=this.map;e.richText.forEach(u=>{r.render(n,u)})}else e&&this.map.t.render(n,e.text);n.closeNode()}parseOpen(n){const{name:e}=n;return this.parser?(this.parser.parseOpen(n),!0):e===this.tag?(this.model={sb:parseInt(n.attributes.sb,10),eb:parseInt(n.attributes.eb,10)},!0):(this.parser=this.map[e],!!this.parser&&(this.parser.parseOpen(n),!0))}parseText(n){this.parser&&this.parser.parseText(n)}parseClose(n){if(this.parser){if(!this.parser.parseClose(n)){switch(n){case"r":{let e=this.model.richText;e||(e=this.model.richText=[]),e.push(this.parser.model);break}case"t":this.model.text=this.parser.model}this.parser=void 0}return!0}switch(n){case this.tag:return!1;default:return!0}}}},{"../base-xform":32,"./rich-text-xform":122,"./text-xform":125}],122:[function(t,b,m){const c=t("./text-xform"),i=t("../style/font-xform"),s=t("../base-xform");class n extends s{constructor(r){super(),this.model=r}get tag(){return"r"}get textXform(){return this._textXform||(this._textXform=new c)}get fontXform(){return this._fontXform||(this._fontXform=new i(n.FONT_OPTIONS))}render(r,u){u=u||this.model,r.openNode("r"),u.font&&this.fontXform.render(r,u.font),this.textXform.render(r,u.text),r.closeNode()}parseOpen(r){if(this.parser)return this.parser.parseOpen(r),!0;switch(r.name){case"r":return this.model={},!0;case"t":return this.parser=this.textXform,this.parser.parseOpen(r),!0;case"rPr":return this.parser=this.fontXform,this.parser.parseOpen(r),!0;default:return!1}}parseText(r){this.parser&&this.parser.parseText(r)}parseClose(r){switch(r){case"r":return!1;case"t":return this.model.text=this.parser.model,this.parser=void 0,!0;case"rPr":return this.model.font=this.parser.model,this.parser=void 0,!0;default:return this.parser&&this.parser.parseClose(r),!0}}}n.FONT_OPTIONS={tagName:"rPr",fontNameTag:"rFont"},b.exports=n},{"../base-xform":32,"../style/font-xform":131,"./text-xform":125}],123:[function(t,b,m){const c=t("./text-xform"),i=t("./rich-text-xform"),s=t("./phonetic-text-xform"),n=t("../base-xform");b.exports=class extends n{constructor(e){super(),this.model=e,this.map={r:new i,t:new c,rPh:new s}}get tag(){return"si"}render(e,r){e.openNode(this.tag),r&&r.hasOwnProperty("richText")&&r.richText?r.richText.length?r.richText.forEach(u=>{this.map.r.render(e,u)}):this.map.t.render(e,""):r!=null&&this.map.t.render(e,r),e.closeNode()}parseOpen(e){const{name:r}=e;return this.parser?(this.parser.parseOpen(e),!0):r===this.tag?(this.model={},!0):(this.parser=this.map[r],!!this.parser&&(this.parser.parseOpen(e),!0))}parseText(e){this.parser&&this.parser.parseText(e)}parseClose(e){if(this.parser){if(!this.parser.parseClose(e)){switch(e){case"r":{let r=this.model.richText;r||(r=this.model.richText=[]),r.push(this.parser.model);break}case"t":this.model=this.parser.model}this.parser=void 0}return!0}switch(e){case this.tag:return!1;default:return!0}}}},{"../base-xform":32,"./phonetic-text-xform":121,"./rich-text-xform":122,"./text-xform":125}],124:[function(t,b,m){const c=t("../../../utils/xml-stream"),i=t("../base-xform"),s=t("./shared-string-xform");b.exports=class extends i{constructor(n){super(),this.model=n||{values:[],count:0},this.hash=Object.create(null),this.rich=Object.create(null)}get sharedStringXform(){return this._sharedStringXform||(this._sharedStringXform=new s)}get values(){return this.model.values}get uniqueCount(){return this.model.values.length}get count(){return this.model.count}getString(n){return this.model.values[n]}add(n){return n.richText?this.addRichText(n):this.addText(n)}addText(n){let e=this.hash[n];return e===void 0&&(e=this.hash[n]=this.model.values.length,this.model.values.push(n)),this.model.count++,e}addRichText(n){const e=this.sharedStringXform.toXml(n);let r=this.rich[e];return r===void 0&&(r=this.rich[e]=this.model.values.length,this.model.values.push(n)),this.model.count++,r}render(n,e){e=e||this._values,n.openXml(c.StdDocAttributes),n.openNode("sst",{xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main",count:e.count,uniqueCount:e.values.length});const r=this.sharedStringXform;e.values.forEach(u=>{r.render(n,u)}),n.closeNode()}parseOpen(n){if(this.parser)return this.parser.parseOpen(n),!0;switch(n.name){case"sst":return!0;case"si":return this.parser=this.sharedStringXform,this.parser.parseOpen(n),!0;default:throw new Error("Unexpected xml node in parseOpen: "+JSON.stringify(n))}}parseText(n){this.parser&&this.parser.parseText(n)}parseClose(n){if(this.parser)return this.parser.parseClose(n)||(this.model.values.push(this.parser.model),this.model.count++,this.parser=void 0),!0;switch(n){case"sst":return!1;default:throw new Error("Unexpected xml node in parseClose: "+n)}}}},{"../../../utils/xml-stream":28,"../base-xform":32,"./shared-string-xform":123}],125:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"t"}render(i,s){i.openNode("t"),/^\s|\n|\s$/.test(s)&&i.addAttribute("xml:space","preserve"),i.writeText(s),i.closeNode()}get model(){return this._text.join("").replace(/_x([0-9A-F]{4})_/g,(i,s)=>String.fromCharCode(parseInt(s,16)))}parseOpen(i){switch(i.name){case"t":return this._text=[],!0;default:return!1}}parseText(i){this._text.push(i)}parseClose(){return!1}}},{"../base-xform":32}],126:[function(t,b,m){const c=t("../../../doc/enums"),i=t("../../../utils/utils"),s=t("../base-xform"),n={horizontalValues:["left","center","right","fill","centerContinuous","distributed","justify"].reduce((r,u)=>(r[u]=!0,r),{}),horizontal(r){return this.horizontalValues[r]?r:void 0},verticalValues:["top","middle","bottom","distributed","justify"].reduce((r,u)=>(r[u]=!0,r),{}),vertical(r){return r==="middle"?"center":this.verticalValues[r]?r:void 0},wrapText:r=>!!r||void 0,shrinkToFit:r=>!!r||void 0,textRotation(r){switch(r){case"vertical":return r;default:return(r=i.validInt(r))>=-90&&r<=90?r:void 0}},indent:r=>(r=i.validInt(r),Math.max(0,r)),readingOrder(r){switch(r){case"ltr":return c.ReadingOrder.LeftToRight;case"rtl":return c.ReadingOrder.RightToLeft;default:return}}},e={toXml(r){if(r=n.textRotation(r)){if(r==="vertical")return 255;const u=Math.round(r);if(u>=0&&u<=90)return u;if(u<0&&u>=-90)return 90-u}},toModel(r){const u=i.validInt(r);if(u!==void 0){if(u===255)return"vertical";if(u>=0&&u<=90)return u;if(u>90&&u<=180)return 90-u}}};b.exports=class extends s{get tag(){return"alignment"}render(r,u){r.addRollback(),r.openNode("alignment");let a=!1;function o(f,h){h&&(r.addAttribute(f,h),a=!0)}o("horizontal",n.horizontal(u.horizontal)),o("vertical",n.vertical(u.vertical)),o("wrapText",!!n.wrapText(u.wrapText)&&"1"),o("shrinkToFit",!!n.shrinkToFit(u.shrinkToFit)&&"1"),o("indent",n.indent(u.indent)),o("textRotation",e.toXml(u.textRotation)),o("readingOrder",n.readingOrder(u.readingOrder)),r.closeNode(),a?r.commit():r.rollback()}parseOpen(r){const u={};let a=!1;function o(f,h,d){f&&(u[h]=d,a=!0)}o(r.attributes.horizontal,"horizontal",r.attributes.horizontal),o(r.attributes.vertical,"vertical",r.attributes.vertical==="center"?"middle":r.attributes.vertical),o(r.attributes.wrapText,"wrapText",i.parseBoolean(r.attributes.wrapText)),o(r.attributes.shrinkToFit,"shrinkToFit",i.parseBoolean(r.attributes.shrinkToFit)),o(r.attributes.indent,"indent",parseInt(r.attributes.indent,10)),o(r.attributes.textRotation,"textRotation",e.toModel(r.attributes.textRotation)),o(r.attributes.readingOrder,"readingOrder",r.attributes.readingOrder==="2"?"rtl":"ltr"),this.model=a?u:null}parseText(){}parseClose(){return!1}}},{"../../../doc/enums":7,"../../../utils/utils":27,"../base-xform":32}],127:[function(t,b,m){const c=t("../base-xform"),i=t("../../../utils/utils"),s=t("./color-xform");class n extends c{constructor(r){super(),this.name=r,this.map={color:new s}}get tag(){return this.name}render(r,u,a){const o=u&&u.color||a||this.defaultColor;r.openNode(this.name),u&&u.style&&(r.addAttribute("style",u.style),o&&this.map.color.render(r,o)),r.closeNode()}parseOpen(r){if(this.parser)return this.parser.parseOpen(r),!0;switch(r.name){case this.name:{const{style:u}=r.attributes;return this.model=u?{style:u}:void 0,!0}case"color":return this.parser=this.map.color,this.parser.parseOpen(r),!0;default:return!1}}parseText(r){this.parser&&this.parser.parseText(r)}parseClose(r){return this.parser?(this.parser.parseClose(r)||(this.parser=void 0),!0):(r===this.name&&this.map.color.model&&(this.model||(this.model={}),this.model.color=this.map.color.model),!1)}validStyle(r){return n.validStyleValues[r]}}n.validStyleValues=["thin","dashed","dotted","dashDot","hair","dashDotDot","slantDashDot","mediumDashed","mediumDashDotDot","mediumDashDot","medium","double","thick"].reduce((e,r)=>(e[r]=!0,e),{}),b.exports=class extends c{constructor(){super(),this.map={top:new n("top"),left:new n("left"),bottom:new n("bottom"),right:new n("right"),diagonal:new n("diagonal")}}render(e,r){const{color:u}=r;function a(o,f){o&&!o.color&&r.color&&(o={...o,color:r.color}),f.render(e,o,u)}e.openNode("border"),r.diagonal&&r.diagonal.style&&(r.diagonal.up&&e.addAttribute("diagonalUp","1"),r.diagonal.down&&e.addAttribute("diagonalDown","1")),a(r.left,this.map.left),a(r.right,this.map.right),a(r.top,this.map.top),a(r.bottom,this.map.bottom),a(r.diagonal,this.map.diagonal),e.closeNode()}parseOpen(e){if(this.parser)return this.parser.parseOpen(e),!0;switch(e.name){case"border":return this.reset(),this.diagonalUp=i.parseBoolean(e.attributes.diagonalUp),this.diagonalDown=i.parseBoolean(e.attributes.diagonalDown),!0;default:return this.parser=this.map[e.name],!!this.parser&&(this.parser.parseOpen(e),!0)}}parseText(e){this.parser&&this.parser.parseText(e)}parseClose(e){if(this.parser)return this.parser.parseClose(e)||(this.parser=void 0),!0;if(e==="border"){const r=this.model={},u=function(a,o,f){o&&(f&&Object.assign(o,f),r[a]=o)};u("left",this.map.left.model),u("right",this.map.right.model),u("top",this.map.top.model),u("bottom",this.map.bottom.model),u("diagonal",this.map.diagonal.model,{up:this.diagonalUp,down:this.diagonalDown})}return!1}}},{"../../../utils/utils":27,"../base-xform":32,"./color-xform":128}],128:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{constructor(i){super(),this.name=i||"color"}get tag(){return this.name}render(i,s){return!!s&&(i.openNode(this.name),s.argb?i.addAttribute("rgb",s.argb):s.theme!==void 0?(i.addAttribute("theme",s.theme),s.tint!==void 0&&i.addAttribute("tint",s.tint)):s.indexed!==void 0?i.addAttribute("indexed",s.indexed):i.addAttribute("auto","1"),i.closeNode(),!0)}parseOpen(i){return i.name===this.name&&(i.attributes.rgb?this.model={argb:i.attributes.rgb}:i.attributes.theme?(this.model={theme:parseInt(i.attributes.theme,10)},i.attributes.tint&&(this.model.tint=parseFloat(i.attributes.tint))):i.attributes.indexed?this.model={indexed:parseInt(i.attributes.indexed,10)}:this.model=void 0,!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],129:[function(t,b,m){const c=t("../base-xform"),i=t("./alignment-xform"),s=t("./border-xform"),n=t("./fill-xform"),e=t("./font-xform"),r=t("./numfmt-xform"),u=t("./protection-xform");b.exports=class extends c{constructor(){super(),this.map={alignment:new i,border:new s,fill:new n,font:new e,numFmt:new r,protection:new u}}get tag(){return"dxf"}render(a,o){if(a.openNode(this.tag),o.font&&this.map.font.render(a,o.font),o.numFmt&&o.numFmtId){const f={id:o.numFmtId,formatCode:o.numFmt};this.map.numFmt.render(a,f)}o.fill&&this.map.fill.render(a,o.fill),o.alignment&&this.map.alignment.render(a,o.alignment),o.border&&this.map.border.render(a,o.border),o.protection&&this.map.protection.render(a,o.protection),a.closeNode()}parseOpen(a){if(this.parser)return this.parser.parseOpen(a),!0;switch(a.name){case this.tag:return this.reset(),!0;default:return this.parser=this.map[a.name],this.parser&&this.parser.parseOpen(a),!0}}parseText(a){this.parser&&this.parser.parseText(a)}parseClose(a){return this.parser?(this.parser.parseClose(a)||(this.parser=void 0),!0):a!==this.tag||(this.model={alignment:this.map.alignment.model,border:this.map.border.model,fill:this.map.fill.model,font:this.map.font.model,numFmt:this.map.numFmt.model,protection:this.map.protection.model},!1)}}},{"../base-xform":32,"./alignment-xform":126,"./border-xform":127,"./fill-xform":130,"./font-xform":131,"./numfmt-xform":132,"./protection-xform":133}],130:[function(t,b,m){const c=t("../base-xform"),i=t("./color-xform");class s extends c{constructor(){super(),this.map={color:new i}}get tag(){return"stop"}render(a,o){a.openNode("stop"),a.addAttribute("position",o.position),this.map.color.render(a,o.color),a.closeNode()}parseOpen(a){if(this.parser)return this.parser.parseOpen(a),!0;switch(a.name){case"stop":return this.model={position:parseFloat(a.attributes.position)},!0;case"color":return this.parser=this.map.color,this.parser.parseOpen(a),!0;default:return!1}}parseText(){}parseClose(a){return!!this.parser&&(this.parser.parseClose(a)||(this.model.color=this.parser.model,this.parser=void 0),!0)}}class n extends c{constructor(){super(),this.map={fgColor:new i("fgColor"),bgColor:new i("bgColor")}}get name(){return"pattern"}get tag(){return"patternFill"}render(a,o){a.openNode("patternFill"),a.addAttribute("patternType",o.pattern),o.fgColor&&this.map.fgColor.render(a,o.fgColor),o.bgColor&&this.map.bgColor.render(a,o.bgColor),a.closeNode()}parseOpen(a){if(this.parser)return this.parser.parseOpen(a),!0;switch(a.name){case"patternFill":return this.model={type:"pattern",pattern:a.attributes.patternType},!0;default:return this.parser=this.map[a.name],!!this.parser&&(this.parser.parseOpen(a),!0)}}parseText(a){this.parser&&this.parser.parseText(a)}parseClose(a){return!!this.parser&&(this.parser.parseClose(a)||(this.parser.model&&(this.model[a]=this.parser.model),this.parser=void 0),!0)}}class e extends c{constructor(){super(),this.map={stop:new s}}get name(){return"gradient"}get tag(){return"gradientFill"}render(a,o){switch(a.openNode("gradientFill"),o.gradient){case"angle":a.addAttribute("degree",o.degree);break;case"path":a.addAttribute("type","path"),o.center.left&&(a.addAttribute("left",o.center.left),o.center.right===void 0&&a.addAttribute("right",o.center.left)),o.center.right&&a.addAttribute("right",o.center.right),o.center.top&&(a.addAttribute("top",o.center.top),o.center.bottom===void 0&&a.addAttribute("bottom",o.center.top)),o.center.bottom&&a.addAttribute("bottom",o.center.bottom)}const f=this.map.stop;o.stops.forEach(h=>{f.render(a,h)}),a.closeNode()}parseOpen(a){if(this.parser)return this.parser.parseOpen(a),!0;switch(a.name){case"gradientFill":{const o=this.model={stops:[]};return a.attributes.degree?(o.gradient="angle",o.degree=parseInt(a.attributes.degree,10)):a.attributes.type==="path"&&(o.gradient="path",o.center={left:a.attributes.left?parseFloat(a.attributes.left):0,top:a.attributes.top?parseFloat(a.attributes.top):0},a.attributes.right!==a.attributes.left&&(o.center.right=a.attributes.right?parseFloat(a.attributes.right):0),a.attributes.bottom!==a.attributes.top&&(o.center.bottom=a.attributes.bottom?parseFloat(a.attributes.bottom):0)),!0}case"stop":return this.parser=this.map.stop,this.parser.parseOpen(a),!0;default:return!1}}parseText(a){this.parser&&this.parser.parseText(a)}parseClose(a){return!!this.parser&&(this.parser.parseClose(a)||(this.model.stops.push(this.parser.model),this.parser=void 0),!0)}}class r extends c{constructor(){super(),this.map={patternFill:new n,gradientFill:new e}}get tag(){return"fill"}render(a,o){switch(a.addRollback(),a.openNode("fill"),o.type){case"pattern":this.map.patternFill.render(a,o);break;case"gradient":this.map.gradientFill.render(a,o);break;default:return void a.rollback()}a.closeNode(),a.commit()}parseOpen(a){if(this.parser)return this.parser.parseOpen(a),!0;switch(a.name){case"fill":return this.model={},!0;default:return this.parser=this.map[a.name],!!this.parser&&(this.parser.parseOpen(a),!0)}}parseText(a){this.parser&&this.parser.parseText(a)}parseClose(a){return!!this.parser&&(this.parser.parseClose(a)||(this.model=this.parser.model,this.model.type=this.parser.name,this.parser=void 0),!0)}validStyle(a){return r.validPatternValues[a]}}r.validPatternValues=["none","solid","darkVertical","darkGray","mediumGray","lightGray","gray125","gray0625","darkHorizontal","darkVertical","darkDown","darkUp","darkGrid","darkTrellis","lightHorizontal","lightVertical","lightDown","lightUp","lightGrid","lightTrellis","lightGrid"].reduce((u,a)=>(u[a]=!0,u),{}),r.StopXform=s,r.PatternFillXform=n,r.GradientFillXform=e,b.exports=r},{"../base-xform":32,"./color-xform":128}],131:[function(t,b,m){const c=t("./color-xform"),i=t("../simple/boolean-xform"),s=t("../simple/integer-xform"),n=t("../simple/string-xform"),e=t("./underline-xform"),r=t("../../../utils/under-dash"),u=t("../base-xform");class a extends u{constructor(f){super(),this.options=f||a.OPTIONS,this.map={b:{prop:"bold",xform:new i({tag:"b",attr:"val"})},i:{prop:"italic",xform:new i({tag:"i",attr:"val"})},u:{prop:"underline",xform:new e},charset:{prop:"charset",xform:new s({tag:"charset",attr:"val"})},color:{prop:"color",xform:new c},condense:{prop:"condense",xform:new i({tag:"condense",attr:"val"})},extend:{prop:"extend",xform:new i({tag:"extend",attr:"val"})},family:{prop:"family",xform:new s({tag:"family",attr:"val"})},outline:{prop:"outline",xform:new i({tag:"outline",attr:"val"})},vertAlign:{prop:"vertAlign",xform:new n({tag:"vertAlign",attr:"val"})},scheme:{prop:"scheme",xform:new n({tag:"scheme",attr:"val"})},shadow:{prop:"shadow",xform:new i({tag:"shadow",attr:"val"})},strike:{prop:"strike",xform:new i({tag:"strike",attr:"val"})},sz:{prop:"size",xform:new s({tag:"sz",attr:"val"})}},this.map[this.options.fontNameTag]={prop:"name",xform:new n({tag:this.options.fontNameTag,attr:"val"})}}get tag(){return this.options.tagName}render(f,h){const{map:d}=this;f.openNode(this.options.tagName),r.each(this.map,(g,p)=>{d[p].xform.render(f,h[g.prop])}),f.closeNode()}parseOpen(f){if(this.parser)return this.parser.parseOpen(f),!0;if(this.map[f.name])return this.parser=this.map[f.name].xform,this.parser.parseOpen(f);switch(f.name){case this.options.tagName:return this.model={},!0;default:return!1}}parseText(f){this.parser&&this.parser.parseText(f)}parseClose(f){if(this.parser&&!this.parser.parseClose(f)){const h=this.map[f];return this.parser.model&&(this.model[h.prop]=this.parser.model),this.parser=void 0,!0}switch(f){case this.options.tagName:return!1;default:return!0}}}a.OPTIONS={tagName:"font",fontNameTag:"name"},b.exports=a},{"../../../utils/under-dash":26,"../base-xform":32,"../simple/boolean-xform":116,"../simple/integer-xform":118,"../simple/string-xform":119,"./color-xform":128,"./underline-xform":136}],132:[function(t,b,m){const c=t("../../../utils/under-dash"),i=t("../../defaultnumformats"),s=t("../base-xform"),n=function(){const r={};return c.each(i,(u,a)=>{u.f&&(r[u.f]=parseInt(a,10))}),r}();class e extends s{constructor(u,a){super(),this.id=u,this.formatCode=a}get tag(){return"numFmt"}render(u,a){u.leafNode("numFmt",{numFmtId:a.id,formatCode:a.formatCode})}parseOpen(u){switch(u.name){case"numFmt":return this.model={id:parseInt(u.attributes.numFmtId,10),formatCode:u.attributes.formatCode.replace(/[\\](.)/g,"$1")},!0;default:return!1}}parseText(){}parseClose(){return!1}}e.getDefaultFmtId=function(r){return n[r]},e.getDefaultFmtCode=function(r){return i[r]&&i[r].f},b.exports=e},{"../../../utils/under-dash":26,"../../defaultnumformats":30,"../base-xform":32}],133:[function(t,b,m){const c=t("../base-xform"),i={boolean:(s,n)=>s===void 0?n:s};b.exports=class extends c{get tag(){return"protection"}render(s,n){s.addRollback(),s.openNode("protection");let e=!1;function r(u,a){a!==void 0&&(s.addAttribute(u,a),e=!0)}r("locked",i.boolean(n.locked,!0)?void 0:"0"),r("hidden",i.boolean(n.hidden,!1)?"1":void 0),s.closeNode(),e?s.commit():s.rollback()}parseOpen(s){const n={locked:s.attributes.locked!=="0",hidden:s.attributes.hidden==="1"},e=!n.locked||n.hidden;this.model=e?n:null}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],134:[function(t,b,m){const c=t("../base-xform"),i=t("./alignment-xform"),s=t("./protection-xform");b.exports=class extends c{constructor(n){super(),this.xfId=!(!n||!n.xfId),this.map={alignment:new i,protection:new s}}get tag(){return"xf"}render(n,e){n.openNode("xf",{numFmtId:e.numFmtId||0,fontId:e.fontId||0,fillId:e.fillId||0,borderId:e.borderId||0}),this.xfId&&n.addAttribute("xfId",e.xfId||0),e.numFmtId&&n.addAttribute("applyNumberFormat","1"),e.fontId&&n.addAttribute("applyFont","1"),e.fillId&&n.addAttribute("applyFill","1"),e.borderId&&n.addAttribute("applyBorder","1"),e.alignment&&n.addAttribute("applyAlignment","1"),e.protection&&n.addAttribute("applyProtection","1"),e.alignment&&this.map.alignment.render(n,e.alignment),e.protection&&this.map.protection.render(n,e.protection),n.closeNode()}parseOpen(n){if(this.parser)return this.parser.parseOpen(n),!0;switch(n.name){case"xf":return this.model={numFmtId:parseInt(n.attributes.numFmtId,10),fontId:parseInt(n.attributes.fontId,10),fillId:parseInt(n.attributes.fillId,10),borderId:parseInt(n.attributes.borderId,10)},this.xfId&&(this.model.xfId=parseInt(n.attributes.xfId,10)),!0;case"alignment":return this.parser=this.map.alignment,this.parser.parseOpen(n),!0;case"protection":return this.parser=this.map.protection,this.parser.parseOpen(n),!0;default:return!1}}parseText(n){this.parser&&this.parser.parseText(n)}parseClose(n){return this.parser?(this.parser.parseClose(n)||(this.map.protection===this.parser?this.model.protection=this.parser.model:this.model.alignment=this.parser.model,this.parser=void 0),!0):n!=="xf"}}},{"../base-xform":32,"./alignment-xform":126,"./protection-xform":133}],135:[function(t,b,m){const c=t("../../../doc/enums"),i=t("../../../utils/xml-stream"),s=t("../base-xform"),n=t("../static-xform"),e=t("../list-xform"),r=t("./font-xform"),u=t("./fill-xform"),a=t("./border-xform"),o=t("./numfmt-xform"),f=t("./style-xform"),h=t("./dxf-xform");class d extends s{constructor(p){super(),this.map={numFmts:new e({tag:"numFmts",count:!0,childXform:new o}),fonts:new e({tag:"fonts",count:!0,childXform:new r,$:{"x14ac:knownFonts":1}}),fills:new e({tag:"fills",count:!0,childXform:new u}),borders:new e({tag:"borders",count:!0,childXform:new a}),cellStyleXfs:new e({tag:"cellStyleXfs",count:!0,childXform:new f}),cellXfs:new e({tag:"cellXfs",count:!0,childXform:new f({xfId:!0})}),dxfs:new e({tag:"dxfs",always:!0,count:!0,childXform:new h}),numFmt:new o,font:new r,fill:new u,border:new a,style:new f({xfId:!0}),cellStyles:d.STATIC_XFORMS.cellStyles,tableStyles:d.STATIC_XFORMS.tableStyles,extLst:d.STATIC_XFORMS.extLst},p&&this.init()}initIndex(){this.index={style:{},numFmt:{},numFmtNextId:164,font:{},border:{},fill:{}}}init(){this.model={styles:[],numFmts:[],fonts:[],borders:[],fills:[],dxfs:[]},this.initIndex(),this._addBorder({}),this._addStyle({numFmtId:0,fontId:0,fillId:0,borderId:0,xfId:0}),this._addFill({type:"pattern",pattern:"none"}),this._addFill({type:"pattern",pattern:"gray125"}),this.weakMap=new WeakMap}render(p,k){k=k||this.model,p.openXml(i.StdDocAttributes),p.openNode("styleSheet",d.STYLESHEET_ATTRIBUTES),this.index?(k.numFmts&&k.numFmts.length&&(p.openNode("numFmts",{count:k.numFmts.length}),k.numFmts.forEach(C=>{p.writeXml(C)}),p.closeNode()),k.fonts.length||this._addFont({size:11,color:{theme:1},name:"Calibri",family:2,scheme:"minor"}),p.openNode("fonts",{count:k.fonts.length,"x14ac:knownFonts":1}),k.fonts.forEach(C=>{p.writeXml(C)}),p.closeNode(),p.openNode("fills",{count:k.fills.length}),k.fills.forEach(C=>{p.writeXml(C)}),p.closeNode(),p.openNode("borders",{count:k.borders.length}),k.borders.forEach(C=>{p.writeXml(C)}),p.closeNode(),this.map.cellStyleXfs.render(p,[{numFmtId:0,fontId:0,fillId:0,borderId:0,xfId:0}]),p.openNode("cellXfs",{count:k.styles.length}),k.styles.forEach(C=>{p.writeXml(C)}),p.closeNode()):(this.map.numFmts.render(p,k.numFmts),this.map.fonts.render(p,k.fonts),this.map.fills.render(p,k.fills),this.map.borders.render(p,k.borders),this.map.cellStyleXfs.render(p,[{numFmtId:0,fontId:0,fillId:0,borderId:0,xfId:0}]),this.map.cellXfs.render(p,k.styles)),d.STATIC_XFORMS.cellStyles.render(p),this.map.dxfs.render(p,k.dxfs),d.STATIC_XFORMS.tableStyles.render(p),d.STATIC_XFORMS.extLst.render(p),p.closeNode()}parseOpen(p){if(this.parser)return this.parser.parseOpen(p),!0;switch(p.name){case"styleSheet":return this.initIndex(),!0;default:return this.parser=this.map[p.name],this.parser&&this.parser.parseOpen(p),!0}}parseText(p){this.parser&&this.parser.parseText(p)}parseClose(p){if(this.parser)return this.parser.parseClose(p)||(this.parser=void 0),!0;switch(p){case"styleSheet":{this.model={};const k=(C,T)=>{T.model&&T.model.length&&(this.model[C]=T.model)};if(k("numFmts",this.map.numFmts),k("fonts",this.map.fonts),k("fills",this.map.fills),k("borders",this.map.borders),k("styles",this.map.cellXfs),k("dxfs",this.map.dxfs),this.index={model:[],numFmt:[]},this.model.numFmts){const C=this.index.numFmt;this.model.numFmts.forEach(T=>{C[T.id]=T.formatCode})}return!1}default:return!0}}addStyleModel(p,k){if(!p)return 0;if(this.model.fonts.length||this._addFont({size:11,color:{theme:1},name:"Calibri",family:2,scheme:"minor"}),this.weakMap&&this.weakMap.has(p))return this.weakMap.get(p);const C={};if(k=k||c.ValueType.Number,p.numFmt)C.numFmtId=this._addNumFmtStr(p.numFmt);else switch(k){case c.ValueType.Number:C.numFmtId=this._addNumFmtStr("General");break;case c.ValueType.Date:C.numFmtId=this._addNumFmtStr("mm-dd-yy")}p.font&&(C.fontId=this._addFont(p.font)),p.border&&(C.borderId=this._addBorder(p.border)),p.fill&&(C.fillId=this._addFill(p.fill)),p.alignment&&(C.alignment=p.alignment),p.protection&&(C.protection=p.protection);const T=this._addStyle(C);return this.weakMap&&this.weakMap.set(p,T),T}getStyleModel(p){const k=this.model.styles[p];if(!k)return null;let C=this.index.model[p];if(C)return C;if(C=this.index.model[p]={},k.numFmtId){const D=this.index.numFmt[k.numFmtId]||o.getDefaultFmtCode(k.numFmtId);D&&(C.numFmt=D)}function T(D,V,P){if(P||P===0){const N=V[P];N&&(C[D]=N)}}return T("font",this.model.fonts,k.fontId),T("border",this.model.borders,k.borderId),T("fill",this.model.fills,k.fillId),k.alignment&&(C.alignment=k.alignment),k.protection&&(C.protection=k.protection),C}addDxfStyle(p){return p.numFmt&&(p.numFmtId=this._addNumFmtStr(p.numFmt)),this.model.dxfs.push(p),this.model.dxfs.length-1}getDxfStyle(p){return this.model.dxfs[p]}_addStyle(p){const k=this.map.style.toXml(p);let C=this.index.style[k];return C===void 0&&(C=this.index.style[k]=this.model.styles.length,this.model.styles.push(k)),C}_addNumFmtStr(p){let k=o.getDefaultFmtId(p);if(k!==void 0||(k=this.index.numFmt[p],k!==void 0))return k;k=this.index.numFmt[p]=164+this.model.numFmts.length;const C=this.map.numFmt.toXml({id:k,formatCode:p});return this.model.numFmts.push(C),k}_addFont(p){const k=this.map.font.toXml(p);let C=this.index.font[k];return C===void 0&&(C=this.index.font[k]=this.model.fonts.length,this.model.fonts.push(k)),C}_addBorder(p){const k=this.map.border.toXml(p);let C=this.index.border[k];return C===void 0&&(C=this.index.border[k]=this.model.borders.length,this.model.borders.push(k)),C}_addFill(p){const k=this.map.fill.toXml(p);let C=this.index.fill[k];return C===void 0&&(C=this.index.fill[k]=this.model.fills.length,this.model.fills.push(k)),C}}d.STYLESHEET_ATTRIBUTES={xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main","xmlns:mc":"http://schemas.openxmlformats.org/markup-compatibility/2006","mc:Ignorable":"x14ac x16r2","xmlns:x14ac":"http://schemas.microsoft.com/office/spreadsheetml/2009/9/ac","xmlns:x16r2":"http://schemas.microsoft.com/office/spreadsheetml/2015/02/main"},d.STATIC_XFORMS={cellStyles:new n({tag:"cellStyles",$:{count:1},c:[{tag:"cellStyle",$:{name:"Normal",xfId:0,builtinId:0}}]}),dxfs:new n({tag:"dxfs",$:{count:0}}),tableStyles:new n({tag:"tableStyles",$:{count:0,defaultTableStyle:"TableStyleMedium2",defaultPivotStyle:"PivotStyleLight16"}}),extLst:new n({tag:"extLst",c:[{tag:"ext",$:{uri:"{EB79DEF2-80B8-43e5-95BD-54CBDDF9020C}","xmlns:x14":"http://schemas.microsoft.com/office/spreadsheetml/2009/9/main"},c:[{tag:"x14:slicerStyles",$:{defaultSlicerStyle:"SlicerStyleLight1"}}]},{tag:"ext",$:{uri:"{9260A510-F301-46a8-8635-F512D64BE5F5}","xmlns:x15":"http://schemas.microsoft.com/office/spreadsheetml/2010/11/main"},c:[{tag:"x15:timelineStyles",$:{defaultTimelineStyle:"TimeSlicerStyleLight1"}}]}]})},d.Mock=class extends d{constructor(){super(),this.model={styles:[{numFmtId:0,fontId:0,fillId:0,borderId:0,xfId:0}],numFmts:[],fonts:[{size:11,color:{theme:1},name:"Calibri",family:2,scheme:"minor"}],borders:[{}],fills:[{type:"pattern",pattern:"none"},{type:"pattern",pattern:"gray125"}]}}parseStream(g){return g.autodrain(),Promise.resolve()}addStyleModel(g,p){switch(p){case c.ValueType.Date:return this.dateStyleId;default:return 0}}get dateStyleId(){if(!this._dateStyleId){const g={numFmtId:o.getDefaultFmtId("mm-dd-yy")};this._dateStyleId=this.model.styles.length,this.model.styles.push(g)}return this._dateStyleId}getStyleModel(){return{}}},b.exports=d},{"../../../doc/enums":7,"../../../utils/xml-stream":28,"../base-xform":32,"../list-xform":71,"../static-xform":120,"./border-xform":127,"./dxf-xform":129,"./fill-xform":130,"./font-xform":131,"./numfmt-xform":132,"./style-xform":134}],136:[function(t,b,m){const c=t("../base-xform");class i extends c{constructor(n){super(),this.model=n}get tag(){return"u"}render(n,e){if((e=e||this.model)===!0)n.leafNode("u");else{const r=i.Attributes[e];r&&n.leafNode("u",r)}}parseOpen(n){n.name==="u"&&(this.model=n.attributes.val||!0)}parseText(){}parseClose(){return!1}}i.Attributes={single:{},double:{val:"double"},singleAccounting:{val:"singleAccounting"},doubleAccounting:{val:"doubleAccounting"}},b.exports=i},{"../base-xform":32}],137:[function(t,b,m){const c=t("../base-xform"),i=t("./filter-column-xform");b.exports=class extends c{constructor(){super(),this.map={filterColumn:new i}}get tag(){return"autoFilter"}prepare(s){s.columns.forEach((n,e)=>{this.map.filterColumn.prepare(n,{index:e})})}render(s,n){return s.openNode(this.tag,{ref:n.autoFilterRef}),n.columns.forEach(e=>{this.map.filterColumn.render(s,e)}),s.closeNode(),!0}parseOpen(s){if(this.parser)return this.parser.parseOpen(s),!0;switch(s.name){case this.tag:return this.model={autoFilterRef:s.attributes.ref,columns:[]},!0;default:if(this.parser=this.map[s.name],this.parser)return this.parseOpen(s),!0;throw new Error("Unexpected xml node in parseOpen: "+JSON.stringify(s))}}parseText(s){this.parser&&this.parser.parseText(s)}parseClose(s){if(this.parser)return this.parser.parseClose(s)||(this.model.columns.push(this.parser.model),this.parser=void 0),!0;switch(s){case this.tag:return!1;default:throw new Error("Unexpected xml node in parseClose: "+s)}}}},{"../base-xform":32,"./filter-column-xform":139}],138:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"customFilter"}render(i,s){i.leafNode(this.tag,{val:s.val,operator:s.operator})}parseOpen(i){return i.name===this.tag&&(this.model={val:i.attributes.val,operator:i.attributes.operator},!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],139:[function(t,b,m){const c=t("../base-xform"),i=t("../list-xform"),s=t("./custom-filter-xform"),n=t("./filter-xform");b.exports=class extends c{constructor(){super(),this.map={customFilters:new i({tag:"customFilters",count:!1,empty:!0,childXform:new s}),filters:new i({tag:"filters",count:!1,empty:!0,childXform:new n})}}get tag(){return"filterColumn"}prepare(e,r){e.colId=r.index.toString()}render(e,r){return r.customFilters?(e.openNode(this.tag,{colId:r.colId,hiddenButton:r.filterButton?"0":"1"}),this.map.customFilters.render(e,r.customFilters),e.closeNode(),!0):(e.leafNode(this.tag,{colId:r.colId,hiddenButton:r.filterButton?"0":"1"}),!0)}parseOpen(e){if(this.parser)return this.parser.parseOpen(e),!0;const{attributes:r}=e;switch(e.name){case this.tag:return this.model={filterButton:r.hiddenButton==="0"},!0;default:if(this.parser=this.map[e.name],this.parser)return this.parseOpen(e),!0;throw new Error("Unexpected xml node in parseOpen: "+JSON.stringify(e))}}parseText(){}parseClose(e){if(this.parser)return this.parser.parseClose(e)||(this.parser=void 0),!0;switch(e){case this.tag:return this.model.customFilters=this.map.customFilters.model,!1;default:return!0}}}},{"../base-xform":32,"../list-xform":71,"./custom-filter-xform":138,"./filter-xform":140}],140:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"filter"}render(i,s){i.leafNode(this.tag,{val:s.val})}parseOpen(i){return i.name===this.tag&&(this.model={val:i.attributes.val},!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],141:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"tableColumn"}prepare(i,s){i.id=s.index+1}render(i,s){return i.leafNode(this.tag,{id:s.id.toString(),name:s.name,totalsRowLabel:s.totalsRowLabel,totalsRowFunction:s.totalsRowFunction,dxfId:s.dxfId}),!0}parseOpen(i){if(i.name===this.tag){const{attributes:s}=i;return this.model={name:s.name,totalsRowLabel:s.totalsRowLabel,totalsRowFunction:s.totalsRowFunction,dxfId:s.dxfId},!0}return!1}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],142:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"tableStyleInfo"}render(i,s){return i.leafNode(this.tag,{name:s.theme?s.theme:void 0,showFirstColumn:s.showFirstColumn?"1":"0",showLastColumn:s.showLastColumn?"1":"0",showRowStripes:s.showRowStripes?"1":"0",showColumnStripes:s.showColumnStripes?"1":"0"}),!0}parseOpen(i){if(i.name===this.tag){const{attributes:s}=i;return this.model={theme:s.name?s.name:null,showFirstColumn:s.showFirstColumn==="1",showLastColumn:s.showLastColumn==="1",showRowStripes:s.showRowStripes==="1",showColumnStripes:s.showColumnStripes==="1"},!0}return!1}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],143:[function(t,b,m){const c=t("../../../utils/xml-stream"),i=t("../base-xform"),s=t("../list-xform"),n=t("./auto-filter-xform"),e=t("./table-column-xform"),r=t("./table-style-info-xform");class u extends i{constructor(){super(),this.map={autoFilter:new n,tableColumns:new s({tag:"tableColumns",count:!0,empty:!0,childXform:new e}),tableStyleInfo:new r}}prepare(o,f){this.map.autoFilter.prepare(o),this.map.tableColumns.prepare(o.columns,f)}get tag(){return"table"}render(o,f){o.openXml(c.StdDocAttributes),o.openNode(this.tag,{...u.TABLE_ATTRIBUTES,id:f.id,name:f.name,displayName:f.displayName||f.name,ref:f.tableRef,totalsRowCount:f.totalsRow?"1":void 0,totalsRowShown:f.totalsRow?void 0:"1",headerRowCount:f.headerRow?"1":"0"}),this.map.autoFilter.render(o,f),this.map.tableColumns.render(o,f.columns),this.map.tableStyleInfo.render(o,f.style),o.closeNode()}parseOpen(o){if(this.parser)return this.parser.parseOpen(o),!0;const{name:f,attributes:h}=o;switch(f){case this.tag:this.reset(),this.model={name:h.name,displayName:h.displayName||h.name,tableRef:h.ref,totalsRow:h.totalsRowCount==="1",headerRow:h.headerRowCount==="1"};break;default:this.parser=this.map[o.name],this.parser&&this.parser.parseOpen(o)}return!0}parseText(o){this.parser&&this.parser.parseText(o)}parseClose(o){if(this.parser)return this.parser.parseClose(o)||(this.parser=void 0),!0;switch(o){case this.tag:return this.model.columns=this.map.tableColumns.model,this.map.autoFilter.model&&(this.model.autoFilterRef=this.map.autoFilter.model.autoFilterRef,this.map.autoFilter.model.columns.forEach((f,h)=>{this.model.columns[h].filterButton=f.filterButton})),this.model.style=this.map.tableStyleInfo.model,!1;default:return!0}}reconcile(o,f){o.columns.forEach(h=>{h.dxfId!==void 0&&(h.style=f.styles.getDxfStyle(h.dxfId))})}}u.TABLE_ATTRIBUTES={xmlns:"http://schemas.openxmlformats.org/spreadsheetml/2006/main","xmlns:mc":"http://schemas.openxmlformats.org/markup-compatibility/2006","mc:Ignorable":"xr xr3","xmlns:xr":"http://schemas.microsoft.com/office/spreadsheetml/2014/revision","xmlns:xr3":"http://schemas.microsoft.com/office/spreadsheetml/2016/revision3"},b.exports=u},{"../../../utils/xml-stream":28,"../base-xform":32,"../list-xform":71,"./auto-filter-xform":137,"./table-column-xform":141,"./table-style-info-xform":142}],144:[function(t,b,m){(function(c,i){(function(){const s=t("fs"),n=t("jszip"),{PassThrough:e}=t("readable-stream"),r=t("../utils/zip-stream"),u=t("../utils/stream-buf"),a=t("../utils/utils"),o=t("../utils/xml-stream"),{bufferToString:f}=t("../utils/browser-buffer-decode"),h=t("./xform/style/styles-xform"),d=t("./xform/core/core-xform"),g=t("./xform/strings/shared-strings-xform"),p=t("./xform/core/relationships-xform"),k=t("./xform/core/content-types-xform"),C=t("./xform/core/app-xform"),T=t("./xform/book/workbook-xform"),D=t("./xform/sheet/worksheet-xform"),V=t("./xform/drawing/drawing-xform"),P=t("./xform/table/table-xform"),N=t("./xform/comment/comments-xform"),q=t("./xform/comment/vml-notes-xform"),W=t("./xml/theme1");class L{constructor(M){this.workbook=M}async readFile(M,_){if(!await a.fs.exists(M))throw new Error("File not found: "+M);const y=s.createReadStream(M);try{const x=await this.read(y,_);return y.close(),x}catch(x){throw y.close(),x}}parseRels(M){return new p().parseStream(M)}parseWorkbook(M){return new T().parseStream(M)}parseSharedStrings(M){return new g().parseStream(M)}reconcile(M,_){const y=new T,x=new D(_),w=new V,S=new P;y.reconcile(M);const E={media:M.media,mediaIndex:M.mediaIndex};Object.keys(M.drawings).forEach(z=>{const U=M.drawings[z],Q=M.drawingRels[z];Q&&(E.rels=Q.reduce((j,Y)=>(j[Y.Id]=Y,j),{}),(U.anchors||[]).forEach(j=>{const Y=j.picture&&j.picture.hyperlinks;Y&&E.rels[Y.rId]&&(Y.hyperlink=E.rels[Y.rId].Target,delete Y.rId)}),w.reconcile(U,E))});const O={styles:M.styles};Object.values(M.tables).forEach(z=>{S.reconcile(z,O)});const R={styles:M.styles,sharedStrings:M.sharedStrings,media:M.media,mediaIndex:M.mediaIndex,date1904:M.properties&&M.properties.date1904,drawings:M.drawings,comments:M.comments,tables:M.tables,vmlDrawings:M.vmlDrawings};M.worksheets.forEach(z=>{z.relationships=M.worksheetRels[z.sheetNo],x.reconcile(z,R)}),delete M.worksheetHash,delete M.worksheetRels,delete M.globalRels,delete M.sharedStrings,delete M.workbookRels,delete M.sheetDefs,delete M.styles,delete M.mediaIndex,delete M.drawings,delete M.drawingRels,delete M.vmlDrawings}async _processWorksheetEntry(M,_,y,x,w){const S=new D(x),E=await S.parseStream(M);E.sheetNo=y,_.worksheetHash[w]=E,_.worksheets.push(E)}async _processCommentEntry(M,_,y){const x=new N,w=await x.parseStream(M);_.comments[`../${y}.xml`]=w}async _processTableEntry(M,_,y){const x=new P,w=await x.parseStream(M);_.tables[`../tables/${y}.xml`]=w}async _processWorksheetRelsEntry(M,_,y){const x=new p,w=await x.parseStream(M);_.worksheetRels[y]=w}async _processMediaEntry(M,_,y){const x=y.lastIndexOf(".");if(x>=1){const w=y.substr(x+1),S=y.substr(0,x);await new Promise((E,O)=>{const R=new u;R.on("finish",()=>{_.mediaIndex[y]=_.media.length,_.mediaIndex[S]=_.media.length;const z={type:"image",name:S,extension:w,buffer:R.toBuffer()};_.media.push(z),E()}),M.on("error",z=>{O(z)}),M.pipe(R)})}}async _processDrawingEntry(M,_,y){const x=new V,w=await x.parseStream(M);_.drawings[y]=w}async _processDrawingRelsEntry(M,_,y){const x=new p,w=await x.parseStream(M);_.drawingRels[y]=w}async _processVmlDrawingEntry(M,_,y){const x=new q,w=await x.parseStream(M);_.vmlDrawings[`../drawings/${y}.vml`]=w}async _processThemeEntry(M,_,y){await new Promise((x,w)=>{const S=new u;M.on("error",w),S.on("error",w),S.on("finish",()=>{_.themes[y]=S.read().toString(),x()}),M.pipe(S)})}createInputStream(){throw new Error("`XLSX#createInputStream` is deprecated. You should use `XLSX#read` instead. This method will be removed in version 5.0. Please follow upgrade instruction: https://github.com/exceljs/exceljs/blob/master/UPGRADE-4.0.md")}async read(M,_){!M[Symbol.asyncIterator]&&M.pipe&&(M=M.pipe(new e));const y=[];for await(const x of M)y.push(x);return this.load(i.concat(y),_)}async load(M,_){let y;y=_&&_.base64?i.from(M.toString(),"base64"):M;const x={worksheets:[],worksheetHash:{},worksheetRels:[],themes:{},media:[],mediaIndex:{},drawings:{},drawingRels:{},comments:{},tables:{},vmlDrawings:{}},w=await n.loadAsync(y);for(const S of Object.values(w.files))if(!S.dir){let E,O=S.name;if(O[0]==="/"&&(O=O.substr(1)),O.match(/xl\/media\//)||O.match(/xl\/theme\/([a-zA-Z0-9]+)[.]xml/))E=new e,E.write(await S.async("nodebuffer"));else{let R;E=new e({writableObjectMode:!0,readableObjectMode:!0}),R=c.browser?f(await S.async("nodebuffer")):await S.async("string");const z=16384;for(let U=0;U<R.length;U+=z)E.write(R.substring(U,U+z))}switch(E.end(),O){case"_rels/.rels":x.globalRels=await this.parseRels(E);break;case"xl/workbook.xml":{const R=await this.parseWorkbook(E);x.sheets=R.sheets,x.definedNames=R.definedNames,x.views=R.views,x.properties=R.properties,x.calcProperties=R.calcProperties;break}case"xl/_rels/workbook.xml.rels":x.workbookRels=await this.parseRels(E);break;case"xl/sharedStrings.xml":x.sharedStrings=new g,await x.sharedStrings.parseStream(E);break;case"xl/styles.xml":x.styles=new h,await x.styles.parseStream(E);break;case"docProps/app.xml":{const R=new C,z=await R.parseStream(E);x.company=z.company,x.manager=z.manager;break}case"docProps/core.xml":{const R=new d,z=await R.parseStream(E);Object.assign(x,z);break}default:{let R=O.match(/xl\/worksheets\/sheet(\d+)[.]xml/);if(R){await this._processWorksheetEntry(E,x,R[1],_,O);break}if(R=O.match(/xl\/worksheets\/_rels\/sheet(\d+)[.]xml.rels/),R){await this._processWorksheetRelsEntry(E,x,R[1]);break}if(R=O.match(/xl\/theme\/([a-zA-Z0-9]+)[.]xml/),R){await this._processThemeEntry(E,x,R[1]);break}if(R=O.match(/xl\/media\/([a-zA-Z0-9]+[.][a-zA-Z0-9]{3,4})$/),R){await this._processMediaEntry(E,x,R[1]);break}if(R=O.match(/xl\/drawings\/([a-zA-Z0-9]+)[.]xml/),R){await this._processDrawingEntry(E,x,R[1]);break}if(R=O.match(/xl\/(comments\d+)[.]xml/),R){await this._processCommentEntry(E,x,R[1]);break}if(R=O.match(/xl\/tables\/(table\d+)[.]xml/),R){await this._processTableEntry(E,x,R[1]);break}if(R=O.match(/xl\/drawings\/_rels\/([a-zA-Z0-9]+)[.]xml[.]rels/),R){await this._processDrawingRelsEntry(E,x,R[1]);break}if(R=O.match(/xl\/drawings\/(vmlDrawing\d+)[.]vml/),R){await this._processVmlDrawingEntry(E,x,R[1]);break}}}}return this.reconcile(x,_),this.workbook.model=x,this.workbook}async addMedia(M,_){await Promise.all(_.media.map(async y=>{if(y.type==="image"){const x=`xl/media/${y.name}.${y.extension}`;if(y.filename){const w=await function(S,E){return new Promise((O,R)=>{s.readFile(S,E,(z,U)=>{z?R(z):O(U)})})}(y.filename);return M.append(w,{name:x})}if(y.buffer)return M.append(y.buffer,{name:x});if(y.base64){const w=y.base64,S=w.substring(w.indexOf(",")+1);return M.append(S,{name:x,base64:!0})}}throw new Error("Unsupported media")}))}addDrawings(M,_){const y=new V,x=new p;_.worksheets.forEach(w=>{const{drawing:S}=w;if(S){y.prepare(S,{});let E=y.toXml(S);M.append(E,{name:`xl/drawings/${S.name}.xml`}),E=x.toXml(S.rels),M.append(E,{name:`xl/drawings/_rels/${S.name}.xml.rels`})}})}addTables(M,_){const y=new P;_.worksheets.forEach(x=>{const{tables:w}=x;w.forEach(S=>{y.prepare(S,{});const E=y.toXml(S);M.append(E,{name:"xl/tables/"+S.target})})})}async addContentTypes(M,_){const y=new k().toXml(_);M.append(y,{name:"[Content_Types].xml"})}async addApp(M,_){const y=new C().toXml(_);M.append(y,{name:"docProps/app.xml"})}async addCore(M,_){const y=new d;M.append(y.toXml(_),{name:"docProps/core.xml"})}async addThemes(M,_){const y=_.themes||{theme1:W};Object.keys(y).forEach(x=>{const w=y[x],S=`xl/theme/${x}.xml`;M.append(w,{name:S})})}async addOfficeRels(M){const _=new p().toXml([{Id:"rId1",Type:L.RelType.OfficeDocument,Target:"xl/workbook.xml"},{Id:"rId2",Type:L.RelType.CoreProperties,Target:"docProps/core.xml"},{Id:"rId3",Type:L.RelType.ExtenderProperties,Target:"docProps/app.xml"}]);M.append(_,{name:"_rels/.rels"})}async addWorkbookRels(M,_){let y=1;const x=[{Id:"rId"+y++,Type:L.RelType.Styles,Target:"styles.xml"},{Id:"rId"+y++,Type:L.RelType.Theme,Target:"theme/theme1.xml"}];_.sharedStrings.count&&x.push({Id:"rId"+y++,Type:L.RelType.SharedStrings,Target:"sharedStrings.xml"}),_.worksheets.forEach(S=>{S.rId="rId"+y++,x.push({Id:S.rId,Type:L.RelType.Worksheet,Target:`worksheets/sheet${S.id}.xml`})});const w=new p().toXml(x);M.append(w,{name:"xl/_rels/workbook.xml.rels"})}async addSharedStrings(M,_){_.sharedStrings&&_.sharedStrings.count&&M.append(_.sharedStrings.xml,{name:"xl/sharedStrings.xml"})}async addStyles(M,_){const{xml:y}=_.styles;y&&M.append(y,{name:"xl/styles.xml"})}async addWorkbook(M,_){const y=new T;M.append(y.toXml(_),{name:"xl/workbook.xml"})}async addWorksheets(M,_){const y=new D,x=new p,w=new N,S=new q;_.worksheets.forEach(E=>{let O=new o;y.render(O,E),M.append(O.xml,{name:`xl/worksheets/sheet${E.id}.xml`}),E.rels&&E.rels.length&&(O=new o,x.render(O,E.rels),M.append(O.xml,{name:`xl/worksheets/_rels/sheet${E.id}.xml.rels`})),E.comments.length>0&&(O=new o,w.render(O,E),M.append(O.xml,{name:`xl/comments${E.id}.xml`}),O=new o,S.render(O,E),M.append(O.xml,{name:`xl/drawings/vmlDrawing${E.id}.vml`}))})}_finalize(M){return new Promise((_,y)=>{M.on("finish",()=>{_(this)}),M.on("error",y),M.finalize()})}prepareModel(M,_){M.creator=M.creator||"ExcelJS",M.lastModifiedBy=M.lastModifiedBy||"ExcelJS",M.created=M.created||new Date,M.modified=M.modified||new Date,M.useSharedStrings=_.useSharedStrings===void 0||_.useSharedStrings,M.useStyles=_.useStyles===void 0||_.useStyles,M.sharedStrings=new g,M.styles=M.useStyles?new h(!0):new h.Mock;const y=new T,x=new D;y.prepare(M);const w={sharedStrings:M.sharedStrings,styles:M.styles,date1904:M.properties.date1904,drawingsCount:0,media:M.media};w.drawings=M.drawings=[],w.commentRefs=M.commentRefs=[];let S=0;M.tables=[],M.worksheets.forEach(E=>{E.tables.forEach(O=>{S++,O.target=`table${S}.xml`,O.id=S,M.tables.push(O)}),x.prepare(E,w)})}async write(M,_){_=_||{};const{model:y}=this.workbook,x=new r.ZipWriter(_.zip);return x.pipe(M),this.prepareModel(y,_),await this.addContentTypes(x,y),await this.addOfficeRels(x,y),await this.addWorkbookRels(x,y),await this.addWorksheets(x,y),await this.addSharedStrings(x,y),await this.addDrawings(x,y),await this.addTables(x,y),await Promise.all([this.addThemes(x,y),this.addStyles(x,y)]),await this.addMedia(x,y),await Promise.all([this.addApp(x,y),this.addCore(x,y)]),await this.addWorkbook(x,y),this._finalize(x)}writeFile(M,_){const y=s.createWriteStream(M);return new Promise((x,w)=>{y.on("finish",()=>{x()}),y.on("error",S=>{w(S)}),this.write(y,_).then(()=>{y.end()}).catch(S=>{w(S)})})}async writeBuffer(M){const _=new u;return await this.write(_,M),_.read()}}L.RelType=t("./rel-type"),b.exports=L}).call(this)}).call(this,t("_process"),t("buffer").Buffer)},{"../utils/browser-buffer-decode":16,"../utils/stream-buf":24,"../utils/utils":27,"../utils/xml-stream":28,"../utils/zip-stream":29,"./rel-type":31,"./xform/book/workbook-xform":38,"./xform/comment/comments-xform":40,"./xform/comment/vml-notes-xform":45,"./xform/core/app-xform":51,"./xform/core/content-types-xform":52,"./xform/core/core-xform":53,"./xform/core/relationships-xform":55,"./xform/drawing/drawing-xform":62,"./xform/sheet/worksheet-xform":115,"./xform/strings/shared-strings-xform":124,"./xform/style/styles-xform":135,"./xform/table/table-xform":143,"./xml/theme1":145,_process:467,buffer:220,fs:216,jszip:441,"readable-stream":491}],145:[function(t,b,m){b.exports=`<?xml version="1.0" encoding="UTF-8" standalone="yes"?>
3
3
  <a:theme xmlns:a="http://schemas.openxmlformats.org/drawingml/2006/main" name="Office Theme"> <a:themeElements> <a:clrScheme name="Office"> <a:dk1> <a:sysClr val="windowText" lastClr="000000"/> </a:dk1> <a:lt1> <a:sysClr val="window" lastClr="FFFFFF"/> </a:lt1> <a:dk2> <a:srgbClr val="1F497D"/> </a:dk2> <a:lt2> <a:srgbClr val="EEECE1"/> </a:lt2> <a:accent1> <a:srgbClr val="4F81BD"/> </a:accent1> <a:accent2> <a:srgbClr val="C0504D"/> </a:accent2> <a:accent3> <a:srgbClr val="9BBB59"/> </a:accent3> <a:accent4> <a:srgbClr val="8064A2"/> </a:accent4> <a:accent5> <a:srgbClr val="4BACC6"/> </a:accent5> <a:accent6> <a:srgbClr val="F79646"/> </a:accent6> <a:hlink> <a:srgbClr val="0000FF"/> </a:hlink> <a:folHlink> <a:srgbClr val="800080"/> </a:folHlink> </a:clrScheme> <a:fontScheme name="Office"> <a:majorFont> <a:latin typeface="Cambria"/> <a:ea typeface=""/> <a:cs typeface=""/> <a:font script="Jpan" typeface="MS Pゴシック"/> <a:font script="Hang" typeface="맑은 고딕"/> <a:font script="Hans" typeface="宋体"/> <a:font script="Hant" typeface="新細明體"/> <a:font script="Arab" typeface="Times New Roman"/> <a:font script="Hebr" typeface="Times New Roman"/> <a:font script="Thai" typeface="Tahoma"/> <a:font script="Ethi" typeface="Nyala"/> <a:font script="Beng" typeface="Vrinda"/> <a:font script="Gujr" typeface="Shruti"/> <a:font script="Khmr" typeface="MoolBoran"/> <a:font script="Knda" typeface="Tunga"/> <a:font script="Guru" typeface="Raavi"/> <a:font script="Cans" typeface="Euphemia"/> <a:font script="Cher" typeface="Plantagenet Cherokee"/> <a:font script="Yiii" typeface="Microsoft Yi Baiti"/> <a:font script="Tibt" typeface="Microsoft Himalaya"/> <a:font script="Thaa" typeface="MV Boli"/> <a:font script="Deva" typeface="Mangal"/> <a:font script="Telu" typeface="Gautami"/> <a:font script="Taml" typeface="Latha"/> <a:font script="Syrc" typeface="Estrangelo Edessa"/> <a:font script="Orya" typeface="Kalinga"/> <a:font script="Mlym" typeface="Kartika"/> <a:font script="Laoo" typeface="DokChampa"/> <a:font script="Sinh" typeface="Iskoola Pota"/> <a:font script="Mong" typeface="Mongolian Baiti"/> <a:font script="Viet" typeface="Times New Roman"/> <a:font script="Uigh" typeface="Microsoft Uighur"/> <a:font script="Geor" typeface="Sylfaen"/> </a:majorFont> <a:minorFont> <a:latin typeface="Calibri"/> <a:ea typeface=""/> <a:cs typeface=""/> <a:font script="Jpan" typeface="MS Pゴシック"/> <a:font script="Hang" typeface="맑은 고딕"/> <a:font script="Hans" typeface="宋体"/> <a:font script="Hant" typeface="新細明體"/> <a:font script="Arab" typeface="Arial"/> <a:font script="Hebr" typeface="Arial"/> <a:font script="Thai" typeface="Tahoma"/> <a:font script="Ethi" typeface="Nyala"/> <a:font script="Beng" typeface="Vrinda"/> <a:font script="Gujr" typeface="Shruti"/> <a:font script="Khmr" typeface="DaunPenh"/> <a:font script="Knda" typeface="Tunga"/> <a:font script="Guru" typeface="Raavi"/> <a:font script="Cans" typeface="Euphemia"/> <a:font script="Cher" typeface="Plantagenet Cherokee"/> <a:font script="Yiii" typeface="Microsoft Yi Baiti"/> <a:font script="Tibt" typeface="Microsoft Himalaya"/> <a:font script="Thaa" typeface="MV Boli"/> <a:font script="Deva" typeface="Mangal"/> <a:font script="Telu" typeface="Gautami"/> <a:font script="Taml" typeface="Latha"/> <a:font script="Syrc" typeface="Estrangelo Edessa"/> <a:font script="Orya" typeface="Kalinga"/> <a:font script="Mlym" typeface="Kartika"/> <a:font script="Laoo" typeface="DokChampa"/> <a:font script="Sinh" typeface="Iskoola Pota"/> <a:font script="Mong" typeface="Mongolian Baiti"/> <a:font script="Viet" typeface="Arial"/> <a:font script="Uigh" typeface="Microsoft Uighur"/> <a:font script="Geor" typeface="Sylfaen"/> </a:minorFont> </a:fontScheme> <a:fmtScheme name="Office"> <a:fillStyleLst> <a:solidFill> <a:schemeClr val="phClr"/> </a:solidFill> <a:gradFill rotWithShape="1"> <a:gsLst> <a:gs pos="0"> <a:schemeClr val="phClr"> <a:tint val="50000"/> <a:satMod val="300000"/> </a:schemeClr> </a:gs> <a:gs pos="35000"> <a:schemeClr val="phClr"> <a:tint val="37000"/> <a:satMod val="300000"/> </a:schemeClr> </a:gs> <a:gs pos="100000"> <a:schemeClr val="phClr"> <a:tint val="15000"/> <a:satMod val="350000"/> </a:schemeClr> </a:gs> </a:gsLst> <a:lin ang="16200000" scaled="1"/> </a:gradFill> <a:gradFill rotWithShape="1"> <a:gsLst> <a:gs pos="0"> <a:schemeClr val="phClr"> <a:tint val="100000"/> <a:shade val="100000"/> <a:satMod val="130000"/> </a:schemeClr> </a:gs> <a:gs pos="100000"> <a:schemeClr val="phClr"> <a:tint val="50000"/> <a:shade val="100000"/> <a:satMod val="350000"/> </a:schemeClr> </a:gs> </a:gsLst> <a:lin ang="16200000" scaled="0"/> </a:gradFill> </a:fillStyleLst> <a:lnStyleLst> <a:ln w="9525" cap="flat" cmpd="sng" algn="ctr"> <a:solidFill> <a:schemeClr val="phClr"> <a:shade val="95000"/> <a:satMod val="105000"/> </a:schemeClr> </a:solidFill> <a:prstDash val="solid"/> </a:ln> <a:ln w="25400" cap="flat" cmpd="sng" algn="ctr"> <a:solidFill> <a:schemeClr val="phClr"/> </a:solidFill> <a:prstDash val="solid"/> </a:ln> <a:ln w="38100" cap="flat" cmpd="sng" algn="ctr"> <a:solidFill> <a:schemeClr val="phClr"/> </a:solidFill> <a:prstDash val="solid"/> </a:ln> </a:lnStyleLst> <a:effectStyleLst> <a:effectStyle> <a:effectLst> <a:outerShdw blurRad="40000" dist="20000" dir="5400000" rotWithShape="0"> <a:srgbClr val="000000"> <a:alpha val="38000"/> </a:srgbClr> </a:outerShdw> </a:effectLst> </a:effectStyle> <a:effectStyle> <a:effectLst> <a:outerShdw blurRad="40000" dist="23000" dir="5400000" rotWithShape="0"> <a:srgbClr val="000000"> <a:alpha val="35000"/> </a:srgbClr> </a:outerShdw> </a:effectLst> </a:effectStyle> <a:effectStyle> <a:effectLst> <a:outerShdw blurRad="40000" dist="23000" dir="5400000" rotWithShape="0"> <a:srgbClr val="000000"> <a:alpha val="35000"/> </a:srgbClr> </a:outerShdw> </a:effectLst> <a:scene3d> <a:camera prst="orthographicFront"> <a:rot lat="0" lon="0" rev="0"/> </a:camera> <a:lightRig rig="threePt" dir="t"> <a:rot lat="0" lon="0" rev="1200000"/> </a:lightRig> </a:scene3d> <a:sp3d> <a:bevelT w="63500" h="25400"/> </a:sp3d> </a:effectStyle> </a:effectStyleLst> <a:bgFillStyleLst> <a:solidFill> <a:schemeClr val="phClr"/> </a:solidFill> <a:gradFill rotWithShape="1"> <a:gsLst> <a:gs pos="0"> <a:schemeClr val="phClr"> <a:tint val="40000"/> <a:satMod val="350000"/> </a:schemeClr> </a:gs> <a:gs pos="40000"> <a:schemeClr val="phClr"> <a:tint val="45000"/> <a:shade val="99000"/> <a:satMod val="350000"/> </a:schemeClr> </a:gs> <a:gs pos="100000"> <a:schemeClr val="phClr"> <a:shade val="20000"/> <a:satMod val="255000"/> </a:schemeClr> </a:gs> </a:gsLst> <a:path path="circle"> <a:fillToRect l="50000" t="-80000" r="50000" b="180000"/> </a:path> </a:gradFill> <a:gradFill rotWithShape="1"> <a:gsLst> <a:gs pos="0"> <a:schemeClr val="phClr"> <a:tint val="80000"/> <a:satMod val="300000"/> </a:schemeClr> </a:gs> <a:gs pos="100000"> <a:schemeClr val="phClr"> <a:shade val="30000"/> <a:satMod val="200000"/> </a:schemeClr> </a:gs> </a:gsLst> <a:path path="circle"> <a:fillToRect l="50000" t="50000" r="50000" b="50000"/> </a:path> </a:gradFill> </a:bgFillStyleLst> </a:fmtScheme> </a:themeElements> <a:objectDefaults> <a:spDef> <a:spPr/> <a:bodyPr/> <a:lstStyle/> <a:style> <a:lnRef idx="1"> <a:schemeClr val="accent1"/> </a:lnRef> <a:fillRef idx="3"> <a:schemeClr val="accent1"/> </a:fillRef> <a:effectRef idx="2"> <a:schemeClr val="accent1"/> </a:effectRef> <a:fontRef idx="minor"> <a:schemeClr val="lt1"/> </a:fontRef> </a:style> </a:spDef> <a:lnDef> <a:spPr/> <a:bodyPr/> <a:lstStyle/> <a:style> <a:lnRef idx="2"> <a:schemeClr val="accent1"/> </a:lnRef> <a:fillRef idx="0"> <a:schemeClr val="accent1"/> </a:fillRef> <a:effectRef idx="1"> <a:schemeClr val="accent1"/> </a:effectRef> <a:fontRef idx="minor"> <a:schemeClr val="tx1"/> </a:fontRef> </a:style> </a:lnDef> </a:objectDefaults> <a:extraClrSchemeLst/> </a:theme>`},{}],146:[function(t,b,m){(function(c){(function(){Object.defineProperty(m,"__esModule",{value:!0}),m.CsvFormatterStream=void 0;const i=t("stream"),s=t("./formatter");class n extends i.Transform{constructor(r){super({writableObjectMode:r.objectMode}),this.hasWrittenBOM=!1,this.formatterOptions=r,this.rowFormatter=new s.RowFormatter(r),this.hasWrittenBOM=!r.writeBOM}transform(r){return this.rowFormatter.rowTransform=r,this}_transform(r,u,a){let o=!1;try{this.hasWrittenBOM||(this.push(this.formatterOptions.BOM),this.hasWrittenBOM=!0),this.rowFormatter.format(r,(f,h)=>f?(o=!0,a(f)):(h&&h.forEach(d=>{this.push(c.from(d,"utf8"))}),o=!0,a()))}catch(f){if(o)throw f;a(f)}}_flush(r){this.rowFormatter.finish((u,a)=>u?r(u):(a&&a.forEach(o=>{this.push(c.from(o,"utf8"))}),r()))}}m.CsvFormatterStream=n}).call(this)}).call(this,t("buffer").Buffer)},{"./formatter":150,buffer:220,stream:505}],147:[function(t,b,m){Object.defineProperty(m,"__esModule",{value:!0}),m.FormatterOptions=void 0,m.FormatterOptions=class{constructor(){let c=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{};var i;this.objectMode=!0,this.delimiter=",",this.rowDelimiter=`
4
4
  `,this.quote='"',this.escape=this.quote,this.quoteColumns=!1,this.quoteHeaders=this.quoteColumns,this.headers=null,this.includeEndRowDelimiter=!1,this.writeBOM=!1,this.BOM="\uFEFF",this.alwaysWriteHeaders=!1,Object.assign(this,c||{}),c?.quoteHeaders===void 0&&(this.quoteHeaders=this.quoteColumns),c?.quote===!0?this.quote='"':c?.quote===!1&&(this.quote=""),typeof c?.escape!="string"&&(this.escape=this.quote),this.shouldWriteHeaders=!!this.headers&&((i=c.writeHeaders)===null||i===void 0||i),this.headers=Array.isArray(this.headers)?this.headers:null,this.escapedQuote=`${this.escape}${this.quote}`}}},{}],148:[function(t,b,m){var c=function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(m,"__esModule",{value:!0}),m.FieldFormatter=void 0;const i=c(t("lodash.isboolean")),s=c(t("lodash.isnil")),n=c(t("lodash.escaperegexp"));m.FieldFormatter=class{constructor(e){this._headers=null,this.formatterOptions=e,e.headers!==null&&(this.headers=e.headers),this.REPLACE_REGEXP=new RegExp(e.quote,"g");const r=`[${e.delimiter}${n.default(e.rowDelimiter)}|\r|