@selfeesas/shared-components 1.4.6 → 1.4.7
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 y=require("vue"),fi={xs:18,sm:24,md:32,lg:38,xl:46},Or={size:String};function Fr(l,I=fi){return y.computed(()=>l.size!==void 0?{fontSize:l.size in I?`${I[l.size]}px`:l.size}:null)}function Lt(l,I,t,b){return Object.defineProperty(l,I,{get:t,set:b,enumerable:!0}),l}function ks(l,I){for(const t in I)Lt(l,t,I[t]);return l}function $e(l){return y.markRaw(y.defineComponent(l))}function Ei(l){return y.markRaw(l)}const _s=(l,I)=>{const t=y.reactive(l);for(const b in l)Lt(I,b,()=>t[b],m=>{t[b]=m});return I};function gt(l,I){return l!==void 0&&l()||I}function Mi(l,I){if(l!==void 0){const t=l();if(t!=null)return t.slice()}return I}function It(l,I){return l!==void 0?I.concat(l()):I}function sa(l,I){return l===void 0?I:I!==void 0?I.concat(l()):l()}function Cs(l,I,t,b,m,c){I.key=b+m;const o=y.h(l,I,t);return m===!0?y.withDirectives(o,c()):o}const so="0 0 24 24",Hn=l=>l,Yn=l=>`ionicons ${l}`,la={"mdi-":l=>`mdi ${l}`,"icon-":Hn,"bt-":l=>`bt ${l}`,"eva-":l=>`eva ${l}`,"ion-md":Yn,"ion-ios":Yn,"ion-logo":Yn,"iconfont ":Hn,"ti-":l=>`themify-icon ${l}`,"bi-":l=>`bootstrap-icons ${l}`,"i-":Hn},ua={o_:"-outlined",r_:"-round",s_:"-sharp"},ca={sym_o_:"-outlined",sym_r_:"-rounded",sym_s_:"-sharp"},As=new RegExp("^("+Object.keys(la).join("|")+")"),Es=new RegExp("^("+Object.keys(ua).join("|")+")"),lo=new RegExp("^("+Object.keys(ca).join("|")+")"),Ms=/^[Mm]\s?[-+]?\.?\d/,Ts=/^img:/,Rs=/^svguse:/,Bs=/^ion-/,Is=/^(fa-(classic|sharp|solid|regular|light|brands|duotone|thin)|[lf]a[srlbdk]?) /,bt=$e({name:"QIcon",props:{...Or,tag:{type:String,default:"i"},name:String,color:String,left:Boolean,right:Boolean},setup(l,{slots:I}){const{proxy:{$q:t}}=y.getCurrentInstance(),b=Fr(l),m=y.computed(()=>"q-icon"+(l.left===!0?" on-left":"")+(l.right===!0?" on-right":"")+(l.color!==void 0?` text-${l.color}`:"")),c=y.computed(()=>{let o,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(Ms.test(s)===!0){const[r,u=so]=s.split("|");return{svg:!0,viewBox:u,nodes:r.split("&&").map(a=>{const[i,d,h]=a.split("@@");return y.h("path",{style:d,d:i,transform:h})})}}if(Ts.test(s)===!0)return{img:!0,src:s.substring(4)};if(Rs.test(s)===!0){const[r,u=so]=s.split("|");return{svguse:!0,src:r.substring(7),viewBox:u}}let n=" ";const e=s.match(As);if(e!==null)o=la[e[1]](s);else if(Is.test(s)===!0)o=s;else if(Bs.test(s)===!0)o=`ionicons ion-${t.platform.is.ios===!0?"ios":"md"}${s.substring(3)}`;else if(lo.test(s)===!0){o="notranslate material-symbols";const r=s.match(lo);r!==null&&(s=s.substring(6),o+=ca[r[1]]),n=s}else{o="notranslate material-icons";const r=s.match(Es);r!==null&&(s=s.substring(2),o+=ua[r[1]]),n=s}return{cls:o,content:n}});return()=>{const o={class:m.value,style:b.value,"aria-hidden":"true"};return c.value.none===!0?y.h(l.tag,o,gt(I.default)):c.value.img===!0?y.h(l.tag,o,It(I.default,[y.h("img",{src:c.value.src})])):c.value.svg===!0?y.h(l.tag,o,It(I.default,[y.h("svg",{viewBox:c.value.viewBox||"0 0 24 24"},c.value.nodes)])):c.value.svguse===!0?y.h(l.tag,o,It(I.default,[y.h("svg",{viewBox:c.value.viewBox},[y.h("use",{"xlink:href":c.value.src})])])):(c.value.cls!==void 0&&(o.class+=" "+c.value.cls),y.h(l.tag,o,It(I.default,[c.value.content])))}}});function wn(l){if(Object(l.$parent)===l.$parent)return l.$parent;let{parent:I}=l.$;for(;Object(I)===I;){if(Object(I.proxy)===I.proxy)return I.proxy;I=I.parent}}function fa(l,I){typeof I.type=="symbol"?Array.isArray(I.children)===!0&&I.children.forEach(t=>{fa(l,t)}):l.add(I)}function Os(l){const I=new Set;return l.forEach(t=>{fa(I,t)}),Array.from(I)}function Ti(l){return l.appContext.config.globalProperties.$router!==void 0}function Ri(l){return l.isUnmounted===!0||l.isDeactivated===!0}function uo(l){return l?l.aliasOf?l.aliasOf.path:l.path:""}function co(l,I){return(l.aliasOf||l)===(I.aliasOf||I)}function Fs(l,I){for(const t in I){const b=I[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,o)=>c!==m[o]))return!1}return!0}function fo(l,I){return Array.isArray(I)===!0?l.length===I.length&&l.every((t,b)=>t===I[b]):l.length===1&&l[0]===I}function js(l,I){return Array.isArray(l)===!0?fo(l,I):Array.isArray(I)===!0?fo(I,l):l===I}function Ds(l,I){if(Object.keys(l).length!==Object.keys(I).length)return!1;for(const t in l)if(js(l[t],I[t])===!1)return!1;return!0}const da={to:[String,Object],replace:Boolean,href:String,target:String,disable:Boolean},ha={...da,exact:Boolean,activeClass:{type:String,default:"q-router-link--active"},exactActiveClass:{type:String,default:"q-router-link--exact-active"}};function Bi({fallbackTag:l,useDisableForRouterLinkProps:I=!0}={}){const t=y.getCurrentInstance(),{props:b,proxy:m,emit:c}=t,o=Ti(t),s=y.computed(()=>b.disable!==!0&&b.href!==void 0),n=I===!0?y.computed(()=>o===!0&&b.disable!==!0&&s.value!==!0&&b.to!==void 0&&b.to!==null&&b.to!==""):y.computed(()=>o===!0&&s.value!==!0&&b.to!==void 0&&b.to!==null&&b.to!==""),e=y.computed(()=>n.value===!0?p(b.to):null),r=y.computed(()=>e.value!==null),u=y.computed(()=>s.value===!0||r.value===!0),a=y.computed(()=>b.type==="a"||u.value===!0?"a":b.tag||l||"div"),i=y.computed(()=>s.value===!0?{href:b.href,target:b.target}:r.value===!0?{href:e.value.href,target:b.target}:{}),d=y.computed(()=>{if(r.value===!1)return-1;const{matched:T}=e.value,{length:j}=T,q=T[j-1];if(q===void 0)return-1;const P=m.$route.matched;if(P.length===0)return-1;const N=P.findIndex(co.bind(null,q));if(N!==-1)return N;const V=uo(T[j-2]);return j>1&&uo(q)===V&&P[P.length-1].path!==V?P.findIndex(co.bind(null,T[j-2])):N}),h=y.computed(()=>r.value===!0&&d.value!==-1&&Fs(m.$route.params,e.value.params)),f=y.computed(()=>h.value===!0&&d.value===m.$route.matched.length-1&&Ds(m.$route.params,e.value.params)),g=y.computed(()=>r.value===!0?f.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:j,to:q=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"](q);return j===!0?N:N.then(()=>{}).catch(()=>{})}function C(T){if(r.value===!0){const j=q=>k(T,q);c("click",T,j),T.defaultPrevented!==!0&&j()}else c("click",T)}return{hasRouterLink:r,hasHrefLink:s,hasLink:u,linkTag:a,resolvedLink:e,linkIsActive:h,linkIsExactActive:f,linkClass:g,linkAttrs:i,getLink:p,navigateToRouterLink:k,navigateOnClick:C}}const Ps=$e({name:"QBreadcrumbsEl",props:{...ha,label:String,icon:String,tag:{type:String,default:"span"}},emits:["click"],setup(l,{slots:I}){const{linkTag:t,linkAttrs:b,linkClass:m,navigateOnClick:c}=Bi(),o=y.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=y.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(y.h(bt,{class:s.value,name:l.icon})),l.label!==void 0&&n.push(l.label),y.h(t.value,{...o.value},It(I.default,n))}}}),pa={left:"start",center:"center",right:"end",between:"between",around:"around",evenly:"evenly",stretch:"stretch"},Ns=Object.keys(pa),Ii={align:{type:String,validator:l=>Ns.includes(l)}};function Oi(l){return y.computed(()=>{const I=l.align===void 0?l.vertical===!0?"stretch":"left":l.align;return`${l.vertical===!0?"items":"justify"}-${pa[I]}`})}const Ls=["",!0],Vs=$e({name:"QBreadcrumbs",props:{...Ii,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:I}){const t=Oi(l),b=y.computed(()=>`flex items-center ${t.value}${l.gutter==="none"?"":` q-gutter-${l.gutter}`}`),m=y.computed(()=>l.separatorColor?` text-${l.separatorColor}`:""),c=y.computed(()=>` text-${l.activeColor}`);return()=>{if(I.default===void 0)return;const o=Os(gt(I.default));if(o.length===0)return;let s=1;const n=[],e=o.filter(u=>u.type?.name==="QBreadcrumbsEl").length,r=I.separator!==void 0?I.separator:()=>l.separator;return o.forEach(u=>{if(u.type?.name==="QBreadcrumbsEl"){const a=s<e,i=u.props!==null&&Ls.includes(u.props.disable),d=(a===!0?"":" q-breadcrumbs--last")+(i!==!0&&a===!0?c.value:"");s++,n.push(y.h("div",{class:`flex items-center${d}`},[u])),a===!0&&n.push(y.h("div",{class:"q-breadcrumbs__separator"+m.value},r()))}else n.push(u)}),y.h("div",{class:"q-breadcrumbs"},[y.h("div",{class:b.value},n)])}}}),qs=y.defineComponent({inheritAttrs:!1,__name:"Breadcrumbs",props:{activeColor:{},separatorIcon:{},separatorSize:{},separatorColor:{},store:{},navStore:{},route:{},router:{},breadcrumbConfig:{},separator:{},gutter:{},align:{}},setup(l){const I=l,t=y.useAttrs(),b=y.computed(()=>{const{activeColor:a,separatorIcon:i,separatorSize:d,separatorColor:h,...f}=t;return f}),m=a=>({"data-cy":a.dataCy,class:"cursor-pointer text-h5",color:a.color}),c=y.computed(()=>I.activeColor||"primary"),o=y.computed(()=>I.separatorIcon||"chevron_right"),s=y.computed(()=>I.separatorSize||"2em"),n=y.computed(()=>I.separatorColor||"primary"),e=y.computed(()=>({store:I.store,route:I.route,navStore:I.navStore||{}})),r=y.computed(()=>{const a=[];return I.breadcrumbConfig.forEach(i=>{if(!i.shouldRender(e.value))return;const d=i.getLabel?i.getLabel(e.value):i.defaultLabel,h=i.getColor?i.getColor(e.value):"dark",f={name:i.routeName,...i.getRouteParams&&{params:i.getRouteParams(e.value)}},g=i.clearActions?i.clearActions.map(p=>()=>p(e.value)):[];a.push({label:d,dataCy:i.dataCy,color:h,route:f,clearActions:g})}),a}),u=a=>{a.clearActions&&a.clearActions.forEach(i=>i()),I.router.push(a.route)};return(a,i)=>(y.openBlock(),y.createBlock(Vs,y.mergeProps({"active-color":c.value,class:"text-brown"},b.value),{separator:y.withCtx(()=>[y.createVNode(bt,{size:s.value,name:o.value,color:n.value},null,8,["size","name","color"])]),default:y.withCtx(()=>[(y.openBlock(!0),y.createElementBlock(y.Fragment,null,y.renderList(r.value,(d,h)=>(y.openBlock(),y.createBlock(Ps,y.mergeProps({key:h,to:d.route},{ref_for:!0},m(d),{label:d.label,onClick:f=>u(d)}),null,16,["to","label","onClick"]))),128))]),_:1},16,["active-color"]))}}),zs={size:{type:[String,Number],default:"1em"},color:String};function Us(l){return{cSize:y.computed(()=>l.size in fi?`${fi[l.size]}px`:l.size),classes:y.computed(()=>"q-spinner"+(l.color?` text-${l.color}`:""))}}const ma=$e({name:"QSpinner",props:{...zs,thickness:{type:Number,default:5}},setup(l){const{cSize:I,classes:t}=Us(l);return()=>y.h("svg",{class:t.value+" q-spinner-mat",width:I.value,height:I.value,viewBox:"25 25 50 50"},[y.h("circle",{class:"path",cx:"50",cy:"50",r:"20",fill:"none",stroke:"currentColor","stroke-width":l.thickness,"stroke-miterlimit":"10"})])}});function di(l,I){const t=l.style;for(const b in I)t[b]=I[b]}function Ws(l){if(l==null)return;if(typeof l=="string")try{return document.querySelector(l)||void 0}catch{return}const I=y.unref(l);if(I)return I.$el||I}function ga(l,I){if(l==null||l.contains(I)===!0)return!0;for(let t=l.nextElementSibling;t!==null;t=t.nextElementSibling)if(t.contains(I))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 Pn(){}function Hs(l){return l.button===0}function Hr(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 Ys(l){if(l.path)return l.path;if(l.composedPath)return l.composedPath();const I=[];let t=l.target;for(;t;){if(I.push(t),t.tagName==="HTML")return I.push(document),I.push(window),I;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 Qn(l,I){if(l===void 0||I===!0&&l.__dragPrevented===!0)return;const t=I===!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 Kt(l,I,t){const b=`__q_${I}_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 fr(l,I){const t=`__q_${I}_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 Fi(l){return l!==Object(l)||l.isComposing===!0||l.qKeyEvent===!0}function ir(l,I){return Fi(l)===!0?!1:[].concat(I).includes(l.keyCode)}function Qs(l,I=250){let t=!1,b;return function(){return t===!1&&(t=!0,setTimeout(()=>{t=!1},I),b=l.apply(this,arguments)),b}}function ho(l,I,t,b){t.modifiers.stop===!0&&Dt(l);const m=t.modifiers.color;let c=t.modifiers.center;c=c===!0||b===!0;const o=document.createElement("span"),s=document.createElement("span"),n=Hr(l),{left:e,top:r,width:u,height:a}=I.getBoundingClientRect(),i=Math.sqrt(u*u+a*a),d=i/2,h=`${(u-i)/2}px`,f=c?h:`${n.left-e-d}px`,g=`${(a-i)/2}px`,p=c?g:`${n.top-r-d}px`;s.className="q-ripple__inner",di(s,{height:`${i}px`,width:`${i}px`,transform:`translate3d(${f},${p},0) scale3d(.2,.2,1)`,opacity:0}),o.className=`q-ripple${m?" text-"+m:""}`,o.setAttribute("dir","ltr"),o.appendChild(s),I.appendChild(o);const k=()=>{o.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(()=>{o.remove(),t.abort.splice(t.abort.indexOf(k),1)},275)},250)},50)}function po(l,{modifiers:I,value:t,arg:b}){const m=Object.assign({},l.cfg.ripple,I,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 ba=Ei({name:"ripple",beforeMount(l,I){const t=I.instance.$.appContext.config.globalProperties.$q.config||{};if(t.ripple===!1)return;const b={cfg:t,enabled:I.value!==!1,modifiers:{},abort:[],start(m){b.enabled===!0&&m.qSkipRipple!==!0&&m.type===(b.modifiers.early===!0?"pointerdown":"click")&&ho(m,l,b,m.qKeyEvent===!0)},keystart:Qs(m=>{b.enabled===!0&&m.qSkipRipple!==!0&&ir(m,b.modifiers.keyCodes)===!0&&m.type===`key${b.modifiers.early===!0?"down":"up"}`&&ho(m,l,b,!0)},300)};po(b,I),l.__qripple=b,Kt(b,"main",[[l,"pointerdown","start","passive"],[l,"click","start","passive"],[l,"keydown","keystart","passive"],[l,"keyup","keystart","passive"]])},updated(l,I){if(I.oldValue!==I.value){const t=l.__qripple;t!==void 0&&(t.enabled=I.value!==!1,t.enabled===!0&&Object(I.value)===I.value&&po(t,I))}},beforeUnmount(l){const I=l.__qripple;I!==void 0&&(I.abort.forEach(t=>{t()}),fr(I,"main"),delete l._qripple)}}),mo={none:0,xs:4,sm:8,md:16,lg:24,xl:32},Ks={xs:8,sm:10,md:14,lg:20,xl:24},Xs=["button","submit","reset"],Gs=/[^\s]\/[^\s]/,Js=["flat","outline","push","unelevated"];function Zs(l,I){return l.flat===!0?"flat":l.outline===!0?"outline":l.push===!0?"push":l.unelevated===!0?"unelevated":I}const $s={...Or,...da,type:{type:String,default:"button"},label:[Number,String],icon:String,iconRight:String,...Js.reduce((l,I)=>(l[I]=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:{...Ii.align,default:"center"},stack:Boolean,stretch:Boolean,loading:{type:Boolean,default:null},disable:Boolean},el={...$s,round:Boolean};function tl(l){const I=Fr(l,Ks),t=Oi(l),{hasRouterLink:b,hasLink:m,linkTag:c,linkAttrs:o,navigateOnClick:s}=Bi({fallbackTag:"button"}),n=y.computed(()=>{const f=l.fab===!1&&l.fabMini===!1?I.value:{};return l.padding!==void 0?Object.assign({},f,{padding:l.padding.split(/\s+/).map(g=>g in mo?mo[g]+"px":g).join(" "),minWidth:"0",minHeight:"0"}):f}),e=y.computed(()=>l.rounded===!0||l.fab===!0||l.fabMini===!0),r=y.computed(()=>l.disable!==!0&&l.loading!==!0),u=y.computed(()=>r.value===!0?l.tabindex||0:-1),a=y.computed(()=>Zs(l,"standard")),i=y.computed(()=>{const f={tabindex:u.value};return m.value===!0?Object.assign(f,o.value):Xs.includes(l.type)===!0&&(f.type=l.type),c.value==="a"?(l.disable===!0?f["aria-disabled"]="true":f.href===void 0&&(f.role="button"),b.value!==!0&&Gs.test(l.type)===!0&&(f.type=l.type)):l.disable===!0&&(f.disabled="",f["aria-disabled"]="true"),l.loading===!0&&l.percentage!==void 0&&Object.assign(f,{role:"progressbar","aria-valuemin":0,"aria-valuemax":100,"aria-valuenow":l.percentage}),f}),d=y.computed(()=>{let f;l.color!==void 0?l.flat===!0||l.outline===!0?f=`text-${l.textColor||l.color}`:f=`bg-${l.color} text-${l.textColor||"white"}`:l.textColor&&(f=`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}`+(f!==void 0?" "+f:"")+(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=y.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:d,style:n,innerClasses:h,attributes:i,hasLink:m,linkTag:c,navigateOnClick:s,isActionable:r}}const{passiveCapture:Nt}=_t;let yr=null,wr=null,xr=null;const ct=$e({name:"QBtn",props:{...el,percentage:Number,darkPercentage:Boolean,onTouchstart:[Function,Array]},emits:["click","keydown","mousedown","keyup"],setup(l,{slots:I,emit:t}){const{proxy:b}=y.getCurrentInstance(),{classes:m,style:c,innerClasses:o,attributes:s,hasLink:n,linkTag:e,navigateOnClick:r,isActionable:u}=tl(l),a=y.ref(null),i=y.ref(null);let d=null,h,f=null;const g=y.computed(()=>l.label!==void 0&&l.label!==null&&l.label!==""),p=y.computed(()=>l.disable===!0||l.ripple===!1?!1:{keyCodes:n.value===!0?[13,32]:[13],...l.ripple===!0?{}:l.ripple}),k=y.computed(()=>({center:l.round})),C=y.computed(()=>{const M=Math.max(0,Math.min(100,l.percentage));return M>0?{transition:"transform 0.6s",transform:`translateX(${M-100}%)`}:{}}),T=y.computed(()=>{if(l.loading===!0)return{onMousedown:A,onTouchstart:A,onClick:A,onKeydown:A,onKeyup:A};if(u.value===!0){const M={onClick:q,onKeydown:P,onMousedown:V};if(b.$q.platform.has.touch===!0){const _=l.onTouchstart!==void 0?"":"Passive";M[`onTouchstart${_}`]=N}return M}return{onClick:St}}),j=y.computed(()=>({ref:a,class:"q-btn q-btn-item non-selectable no-outline "+m.value,style:c.value,...s.value,...T.value}));function q(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 v=()=>{document.removeEventListener("keydown",St,!0),document.removeEventListener("keyup",v,Nt),a.value?.removeEventListener("blur",v,Nt)};document.addEventListener("keydown",St,!0),document.addEventListener("keyup",v,Nt),a.value.addEventListener("blur",v,Nt)}}r(M)}}function P(M){a.value!==null&&(t("keydown",M),ir(M,[13,32])===!0&&wr!==a.value&&(wr!==null&&L(),M.defaultPrevented!==!0&&(M.qAvoidFocus!==!0&&a.value.focus(),wr=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&&(yr!==a.value&&(yr!==null&&L(),yr=a.value,d=M.target,d.addEventListener("touchcancel",W,Nt),d.addEventListener("touchend",W,Nt)),h=!0,f!==null&&clearTimeout(f),f=setTimeout(()=>{f=null,h=!1},200)))}function V(M){a.value!==null&&(M.qSkipRipple=h===!0,t("mousedown",M),M.defaultPrevented!==!0&&xr!==a.value&&(xr!==null&&L(),xr=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(wr===a.value&&ir(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 _=i.value;M!==!0&&(yr===a.value||xr===a.value)&&_!==null&&_!==document.activeElement&&(_.setAttribute("tabindex",-1),_.focus()),yr===a.value&&(d!==null&&(d.removeEventListener("touchcancel",W,Nt),d.removeEventListener("touchend",W,Nt)),yr=d=null),xr===a.value&&(document.removeEventListener("mouseup",W,Nt),xr=null),wr===a.value&&(document.removeEventListener("keyup",W,!0),a.value?.removeEventListener("blur",W,Nt),wr=null),a.value?.classList.remove("q-btn--active")}function A(M){St(M),M.qSkipRipple=!0}return y.onBeforeUnmount(()=>{L(!0)}),Object.assign(b,{click:M=>{u.value===!0&&q(M)}}),()=>{let M=[];l.icon!==void 0&&M.push(y.h(bt,{name:l.icon,left:l.stack!==!0&&g.value===!0,role:"img"})),g.value===!0&&M.push(y.h("span",{class:"block"},[l.label])),M=It(I.default,M),l.iconRight!==void 0&&l.round===!1&&M.push(y.h(bt,{name:l.iconRight,right:l.stack!==!0&&g.value===!0,role:"img"}));const _=[y.h("span",{class:"q-focus-helper",ref:i})];return l.loading===!0&&l.percentage!==void 0&&_.push(y.h("span",{class:"q-btn__progress absolute-full overflow-hidden"+(l.darkPercentage===!0?" q-btn__progress--dark":"")},[y.h("span",{class:"q-btn__progress-indicator fit block",style:C.value})])),_.push(y.h("span",{class:"q-btn__content text-center col items-center q-anchor--skip "+o.value},M)),l.loading!==null&&_.push(y.h(y.Transition,{name:"q-transition--fade"},()=>l.loading===!0?[y.h("span",{key:"loading",class:"absolute-full flex flex-center"},I.loading!==void 0?I.loading():[y.h(ma)])]:null)),y.withDirectives(y.h(e.value,j.value,_),[[ba,p.value,void 0,k.value]])}}}),rl={class:"row justify-between"},nl=y.defineComponent({__name:"NavButton",props:{from:{},to:{default:void 0},labelFrom:{},labelTo:{default:void 0},params:{default:()=>({})},query:{default:()=>({})}},setup(l){const I=l,t=y.inject("navContext",null),b=y.inject("router");function m(c){if(!b){console.warn("Dependencies not available:",{router:b});return}t?.setTabs();const o=c==="back"?I.from:I.to;if(!o){console.warn("Destination not provided:",c);return}b.push({name:o,params:I.params,query:I.query})}return(c,o)=>(y.openBlock(),y.createElementBlock("div",rl,[y.createVNode(ct,{icon:"chevron_left","rounded-sm":"",label:c.labelFrom,"data-cy":"go-back","data-testid":"go-back",onClick:o[0]||(o[0]=s=>m("back"))},null,8,["label"]),c.labelTo?(y.openBlock(),y.createBlock(ct,{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:o[1]||(o[1]=s=>m("next"))},null,8,["label"])):y.createCommentVNode("",!0)]))}}),Xt=(l,I)=>{const t=l.__vccOpts||l;for(const[b,m]of I)t[b]=m;return t},il=Xt(nl,[["__scopeId","data-v-8dd99f80"]]),Ot={dark:{type:Boolean,default:null}};function Ft(l,I){return y.computed(()=>l.dark===null?I.dark.isActive:l.dark)}function ol(l,I){const t=y.ref(null),b=y.computed(()=>l.disable===!0?null:y.h("span",{ref:t,class:"no-outline",tabindex:-1}));function m(c){const o=I.value;c?.qAvoidFocus!==!0&&(c?.type.indexOf("key")===0?document.activeElement!==o&&o?.contains(document.activeElement)===!0&&o.focus():t.value!==null&&(c===void 0||o?.contains(c.target)===!0)&&t.value.focus())}return{refocusTargetEl:b,refocusTarget:m}}const Nn={name:String};function al(l){return y.computed(()=>({type:"hidden",name:l.name,value:l.modelValue}))}function va(l={}){return(I,t,b)=>{I[t](y.h("input",{class:"hidden"+(b||""),...l.value}))}}function ya(l){return y.computed(()=>l.name||l.for)}const sl={xs:30,sm:35,md:40,lg:50,xl:60},wa={...Ot,...Or,...Nn,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]},xa=["update:modelValue"];function Sa(l,I){const{props:t,slots:b,emit:m,proxy:c}=y.getCurrentInstance(),{$q:o}=c,s=Ft(t,o),n=y.ref(null),{refocusTargetEl:e,refocusTarget:r}=ol(t,n),u=Fr(t,sl),a=y.computed(()=>t.val!==void 0&&Array.isArray(t.modelValue)),i=y.computed(()=>{const L=y.toRaw(t.val);return a.value===!0?t.modelValue.findIndex(A=>y.toRaw(A)===L):-1}),d=y.computed(()=>a.value===!0?i.value!==-1:y.toRaw(t.modelValue)===y.toRaw(t.trueValue)),h=y.computed(()=>a.value===!0?i.value===-1:y.toRaw(t.modelValue)===y.toRaw(t.falseValue)),f=y.computed(()=>d.value===!1&&h.value===!1),g=y.computed(()=>t.disable===!0?-1:t.tabindex||0),p=y.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=y.computed(()=>{const L=d.value===!0?"truthy":h.value===!0?"falsy":"indet",A=t.color!==void 0&&(t.keepColor===!0||(l==="toggle"?d.value===!0:h.value!==!0))?` text-${t.color}`:"";return`q-${l}__inner relative-position non-selectable q-${l}__inner--${L}${A}`}),C=y.computed(()=>{const L={type:"checkbox"};return t.name!==void 0&&Object.assign(L,{".checked":d.value,"^checked":d.value===!0?"checked":void 0,name:t.name,value:a.value===!0?t.val:t.trueValue}),L}),T=va(C),j=y.computed(()=>{const L={tabindex:g.value,role:l==="toggle"?"switch":"checkbox","aria-label":t.label,"aria-checked":f.value===!0?"mixed":d.value===!0?"true":"false"};return t.disable===!0&&(L["aria-disabled"]="true"),L});function q(L){L!==void 0&&(St(L),r(L)),t.disable!==!0&&m("update:modelValue",P(),L)}function P(){if(a.value===!0){if(d.value===!0){const L=t.modelValue.slice();return L.splice(i.value,1),L}return t.modelValue.concat([t.val])}if(d.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 V(L){(L.keyCode===13||L.keyCode===32)&&q(L)}const W=I(d,f);return Object.assign(c,{toggle:q}),()=>{const L=W();t.disable!==!0&&T(L,"unshift",` q-${l}__native absolute q-ma-none q-pa-none`);const A=[y.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]):gt(b.default);return M!==void 0&&A.push(y.h("div",{class:`q-${l}__label q-anchor--skip`},M)),y.h("div",{ref:n,class:p.value,...j.value,onClick:q,onKeydown:N,onKeyup:V},A)}}const ll=()=>y.h("div",{key:"svg",class:"q-checkbox__bg absolute"},[y.h("svg",{class:"q-checkbox__svg fit absolute-full",viewBox:"0 0 24 24"},[y.h("path",{class:"q-checkbox__truthy",fill:"none",d:"M1.73,12.91 8.1,19.28 22.79,4.59"}),y.h("path",{class:"q-checkbox__indet",d:"M4,14H20V10H4"})])]),Er=$e({name:"QCheckbox",props:wa,emits:xa,setup(l){const I=ll();function t(b,m){const c=y.computed(()=>(b.value===!0?l.checkedIcon:m.value===!0?l.indeterminateIcon:l.uncheckedIcon)||null);return()=>c.value!==null?[y.h("div",{key:"icon",class:"q-checkbox__icon-container absolute-full flex flex-center no-wrap"},[y.h(bt,{class:"q-checkbox__icon",name:c.value})])]:[I]}return Sa("checkbox",t)}}),ul=$e({props:["store","barStyle","verticalBarStyle","horizontalBarStyle"],setup(l){return()=>[y.h("div",{class:l.store.scroll.vertical.barClass.value,style:[l.barStyle,l.verticalBarStyle],"aria-hidden":"true",onMousedown:l.store.onVerticalMousedown}),y.h("div",{class:l.store.scroll.horizontal.barClass.value,style:[l.barStyle,l.horizontalBarStyle],"aria-hidden":"true",onMousedown:l.store.onHorizontalMousedown}),y.withDirectives(y.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),y.withDirectives(y.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)]}}),or=y.ref(!1);let hi;function cl(l,I){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:I[0]||""}}function fl(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 ka="ontouchstart"in window||window.navigator.maxTouchPoints>0;function dl(l){const I=l.toLowerCase(),t=fl(I),b=cl(I,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||I.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,I.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"),or.value===!0&&(hi={is:{...m}}),ka===!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 o=Math.min(window.innerHeight,window.innerWidth)>414?"ipad":"iphone";Object.assign(m,{mobile:!0,ios:!0,platform:o,[o]:!0})}m.mobile!==!0&&window.navigator.userAgentData&&window.navigator.userAgentData.mobile&&(delete m.desktop,m.mobile=!0)}return m}const go=navigator.userAgent||navigator.vendor||window.opera,hl={has:{touch:!1,webStorage:!1},within:{iframe:!1}},Et={userAgent:go,is:dl(go),has:{touch:ka},within:{iframe:window.self!==window.top}},pi={install(l){const{$q:I}=l;or.value===!0?(l.onSSRHydrated.push(()=>{Object.assign(I.platform,Et),or.value=!1}),I.platform=y.reactive(this)):I.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(pi,Et),or.value===!0&&(Object.assign(pi,hi,hl),hi=null)}function pl(){const l=y.ref(!or.value);return l.value===!1&&y.onMounted(()=>{l.value=!0}),{isHydrated:l}}const _a=typeof ResizeObserver<"u",bo=_a===!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"},Rr=$e({name:"QResizeObserver",props:{debounce:{type:[String,Number],default:100}},emits:["resize"],setup(l,{emit:I}){let t=null,b,m={width:-1,height:-1};function c(n){n===!0||l.debounce===0||l.debounce==="0"?o():t===null&&(t=setTimeout(o,l.debounce))}function o(){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},I("resize",m))}}const{proxy:s}=y.getCurrentInstance();if(s.trigger=c,_a===!0){let n;const e=r=>{b=s.$el.parentNode,b?(n=new ResizeObserver(c),n.observe(b),o()):r!==!0&&y.nextTick(()=>{e(!0)})};return y.onMounted(()=>{e()}),y.onBeforeUnmount(()=>{t!==null&&clearTimeout(t),n!==void 0&&(n.disconnect!==void 0?n.disconnect():b&&n.unobserve(b))}),Pn}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),o())};const{isHydrated:r}=pl();let u;return y.onMounted(()=>{y.nextTick(()=>{b=s.$el,b&&e()})}),y.onBeforeUnmount(n),()=>{if(r.value===!0)return y.h("object",{class:"q--avoid-card-border",style:bo.style,tabindex:-1,type:"text/html",data:bo.url,"aria-hidden":"true",onLoad:e})}}}}),Ln=[Element,String],ml=[null,document,document.body,document.scrollingElement,document.documentElement];function Vn(l,I){let t=Ws(I);if(t===void 0){if(l==null)return window;t=l.closest(".scroll,.scroll-y,.overflow-auto")}return ml.includes(t)?window:t}function ji(l){return l===window?window.pageYOffset||window.scrollY||document.body.scrollTop||0:l.scrollTop}function Di(l){return l===window?window.pageXOffset||window.scrollX||document.body.scrollLeft||0:l.scrollLeft}function Ca(l,I,t=0){const b=arguments[3]===void 0?performance.now():arguments[3],m=ji(l);if(t<=0){m!==I&&mi(l,I);return}requestAnimationFrame(c=>{const o=c-b,s=m+(I-m)/Math.max(o,t)*o;mi(l,s),s!==I&&Ca(l,I,t-o,c)})}function Aa(l,I,t=0){const b=arguments[3]===void 0?performance.now():arguments[3],m=Di(l);if(t<=0){m!==I&&gi(l,I);return}requestAnimationFrame(c=>{const o=c-b,s=m+(I-m)/Math.max(o,t)*o;gi(l,s),s!==I&&Aa(l,I,t-o,c)})}function mi(l,I){if(l===window){window.scrollTo(window.pageXOffset||window.scrollX||document.body.scrollLeft||0,I);return}l.scrollTop=I}function gi(l,I){if(l===window){window.scrollTo(I,window.pageYOffset||window.scrollY||document.body.scrollTop||0);return}l.scrollLeft=I}function vo(l,I,t){if(t){Ca(l,I,t);return}mi(l,I)}function Kn(l,I,t){if(t){Aa(l,I,t);return}gi(l,I)}let sn;function xn(){if(sn!==void 0)return sn;const l=document.createElement("p"),I=document.createElement("div");di(l,{width:"100%",height:"200px"}),di(I,{position:"absolute",top:"0px",left:"0px",visibility:"hidden",width:"200px",height:"150px",overflow:"hidden"}),I.appendChild(l),document.body.appendChild(I);const t=l.offsetWidth;I.style.overflow="scroll";let b=l.offsetWidth;return t===b&&(b=I.clientWidth),I.remove(),sn=t-b,sn}function gl(l,I=!0){return!l||l.nodeType!==Node.ELEMENT_NODE?!1:I?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:yo}=_t,bl=["both","horizontal","vertical"],Ea=$e({name:"QScrollObserver",props:{axis:{type:String,validator:l=>bl.includes(l),default:"vertical"},debounce:[String,Number],scrollTarget:Ln},emits:["scroll"],setup(l,{emit:I}){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;y.watch(()=>l.scrollTarget,()=>{n(),s()});function o(){b?.();const u=Math.max(0,ji(m)),a=Di(m),i={top:u-t.position.top,left:a-t.position.left};if(l.axis==="vertical"&&i.top===0||l.axis==="horizontal"&&i.left===0)return;const d=Math.abs(i.top)>=Math.abs(i.left)?i.top<0?"up":"down":i.left<0?"left":"right";t.position={top:u,left:a},t.directionChanged=t.direction!==d,t.delta=i,t.directionChanged===!0&&(t.direction=d,t.inflectionPoint=t.position),I("scroll",{...t})}function s(){m=Vn(c,l.scrollTarget),m.addEventListener("scroll",e,yo),e(!0)}function n(){m!==void 0&&(m.removeEventListener("scroll",e,yo),m=void 0)}function e(u){if(u===!0||l.debounce===0||l.debounce==="0")o();else if(b===null){const[a,i]=l.debounce?[setTimeout(o,l.debounce),clearTimeout]:[requestAnimationFrame(o),cancelAnimationFrame];b=()=>{i(a),b=null}}}const{proxy:r}=y.getCurrentInstance();return y.watch(()=>r.$q.lang.rtl,o),y.onMounted(()=>{c=r.$el.parentNode,s()}),y.onBeforeUnmount(()=>{b?.(),n()}),Object.assign(r,{trigger:e,getPosition:()=>t}),Pn}}),Pi={left:!0,right:!0,up:!0,down:!0,horizontal:!0,vertical:!0},vl=Object.keys(Pi);Pi.all=!0;function wo(l){const I={};for(const t of vl)l[t]===!0&&(I[t]=!0);return Object.keys(I).length===0?Pi:(I.horizontal===!0?I.left=I.right=!0:I.left===!0&&I.right===!0&&(I.horizontal=!0),I.vertical===!0?I.up=I.down=!0:I.up===!0&&I.down===!0&&(I.vertical=!0),I.horizontal===!0&&I.vertical===!0&&(I.all=!0),I)}const yl=["INPUT","TEXTAREA"];function xo(l,I){return I.event===void 0&&l.target!==void 0&&l.target.draggable!==!0&&typeof I.handler=="function"&&yl.includes(l.target.nodeName.toUpperCase())===!1&&(l.qClonedBy===void 0||l.qClonedBy.indexOf(I.uid)===-1)}function Cn(){if(window.getSelection!==void 0){const l=window.getSelection();l.empty!==void 0?l.empty():l.removeAllRanges!==void 0&&(l.removeAllRanges(),pi.is.mobile!==!0&&l.addRange(document.createRange()))}else document.selection!==void 0&&document.selection.empty()}function Xn(l,I,t){const b=Hr(l);let m,c=b.left-I.event.x,o=b.top-I.event.y,s=Math.abs(c),n=Math.abs(o);const e=I.direction;e.horizontal===!0&&e.vertical!==!0?m=c<0?"left":"right":e.horizontal!==!0&&e.vertical===!0?m=o<0?"up":"down":e.up===!0&&o<0?(m="up",s>n&&(e.left===!0&&c<0?m="left":e.right===!0&&c>0&&(m="right"))):e.down===!0&&o>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&&o<0?m="up":e.down===!0&&o>0&&(m="down"))):e.right===!0&&c>0&&(m="right",s<n&&(e.up===!0&&o<0?m="up":e.down===!0&&o>0&&(m="down")));let r=!1;if(m===void 0&&t===!1){if(I.event.isFirst===!0||I.event.lastDir===void 0)return{};m=I.event.lastDir,r=!0,m==="left"||m==="right"?(b.left-=c,s=0,c=0):(b.top-=o,n=0,o=0)}return{synthetic:r,payload:{evt:l,touch:I.event.mouse!==!0,mouse:I.event.mouse===!0,position:b,direction:m,isFirst:I.event.isFirst,isFinal:t===!0,duration:Date.now()-I.event.time,distance:{x:s,y:n},offset:{x:c,y:o},delta:{x:b.left-I.event.lastX,y:b.top-I.event.lastY}}}}let wl=0;const So=Ei({name:"touch-pan",beforeMount(l,{value:I,modifiers:t}){if(t.mouse!==!0&&Et.has.touch!==!0)return;function b(c,o){t.mouse===!0&&o===!0?St(c):(t.stop===!0&&Dt(c),t.prevent===!0&&Bt(c))}const m={uid:"qvtp_"+wl++,handler:I,modifiers:t,direction:wo(t),noop:Pn,mouseStart(c){xo(c,m)&&Hs(c)&&(Kt(m,"temp",[[document,"mousemove","move","notPassiveCapture"],[document,"mouseup","end","passiveCapture"]]),m.start(c,!0))},touchStart(c){if(xo(c,m)){const o=c.target;Kt(m,"temp",[[o,"touchmove","move","notPassiveCapture"],[o,"touchcancel","end","passiveCapture"],[o,"touchend","end","passiveCapture"]]),m.start(c)}},start(c,o){if(Et.is.firefox===!0&&Qn(l,!0),m.lastEvt=c,o===!0||t.stop===!0){if(m.direction.all!==!0&&(o!==!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}=Hr(c);m.event={x:s,y:n,time:Date.now(),mouse:o===!0,detected:!1,isFirst:!0,isFinal:!1,lastX:s,lastY:n}},move(c){if(m.event===void 0)return;const o=Hr(c),s=o.left-m.event.x,n=o.top-m.event.y;if(s===0&&n===0)return;m.lastEvt=c;const e=m.event.mouse===!0,r=()=>{b(c,e);let i;t.preserveCursor!==!0&&t.preservecursor!==!0&&(i=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"),Cn(),m.styleCleanup=d=>{if(m.styleCleanup=void 0,i!==void 0&&(document.documentElement.style.cursor=i),document.body.classList.remove("non-selectable"),e===!0){const h=()=>{document.body.classList.remove("no-pointer-events--children")};d!==void 0?setTimeout(()=>{h(),d()},50):h()}else d!==void 0&&d()}};if(m.event.detected===!0){m.event.isFirst!==!0&&b(c,m.event.mouse);const{payload:i,synthetic:d}=Xn(c,m,!1);i!==void 0&&(m.handler(i)===!1?m.end(c):(m.styleCleanup===void 0&&m.event.isFirst===!0&&r(),m.event.lastX=i.position.left,m.event.lastY=i.position.top,m.event.lastDir=d===!0?void 0:i.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,o){if(m.event!==void 0){if(fr(m,"temp"),Et.is.firefox===!0&&Qn(l,!1),o===!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(Xn(c===void 0?m.lastEvt:c,m).payload);const{payload:s}=Xn(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":"";Kt(m,"main",[[l,"mousedown","mouseStart",`passive${c}`]])}Et.has.touch===!0&&Kt(m,"main",[[l,"touchstart","touchStart",`passive${t.capture===!0?"Capture":""}`],[l,"touchmove","noop","notPassiveCapture"]])},updated(l,I){const t=l.__qtouchpan;t!==void 0&&(I.oldValue!==I.value&&(typeof value!="function"&&t.end(),t.handler=I.value),t.direction=wo(I.modifiers))},beforeUnmount(l){const I=l.__qtouchpan;I!==void 0&&(I.event!==void 0&&I.end(),fr(I,"main"),fr(I,"temp"),Et.is.firefox===!0&&Qn(l,!1),I.styleCleanup?.(),delete l.__qtouchpan)}});function xl(l){return l.charAt(0).toUpperCase()+l.slice(1)}function Dr(l,I,t){return t<=I?I:Math.min(t,Math.max(I,l))}function ko(l,I,t){if(t<=I)return I;const b=t-I+1;let m=I+(l-I)%b;return m<I&&(m=b+m),m===0?0:m}function vt(l,I=2,t="0"){if(l==null)return l;const b=""+l;return b.length>=I?b:new Array(I-b.length+1).join(t)+b}function Ni(l,I=250,t){let b=null;function m(){const c=arguments,o=()=>{b=null,l.apply(this,c)};b!==null&&clearTimeout(b),b=setTimeout(o,I)}return m.cancel=()=>{b!==null&&clearTimeout(b)},m}const _o=["vertical","horizontal"],Gn={vertical:{offset:"offsetY",scroll:"scrollTop",dir:"down",dist:"y"},horizontal:{offset:"offsetX",scroll:"scrollLeft",dir:"right",dist:"x"}},Co={prevent:!0,mouse:!0,mouseAllDir:!0},Ao=l=>l>=250?50:Math.ceil(l/5),Sl=$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:I,emit:t}){const b=y.ref(!1),m=y.ref(!1),c=y.ref(!1),o={vertical:y.ref(0),horizontal:y.ref(0)},s={vertical:{ref:y.ref(null),position:y.ref(0),size:y.ref(0)},horizontal:{ref:y.ref(null),position:y.ref(0),size:y.ref(0)}},{proxy:n}=y.getCurrentInstance(),e=Ft(l,n.$q);let r=null,u;const a=y.ref(null),i=y.computed(()=>"q-scrollarea"+(e.value===!0?" q-scrollarea--dark":""));Object.assign(o,{verticalInner:y.computed(()=>o.vertical.value-l.verticalOffset[0]-l.verticalOffset[1]),horizontalInner:y.computed(()=>o.horizontal.value-l.horizontalOffset[0]-l.horizontalOffset[1])}),s.vertical.percentage=y.computed(()=>{const M=s.vertical.size.value-o.vertical.value;if(M<=0)return 0;const _=Dr(s.vertical.position.value/M,0,1);return Math.round(_*1e4)/1e4}),s.vertical.thumbHidden=y.computed(()=>(l.visible===null?c.value:l.visible)!==!0&&b.value===!1&&m.value===!1||s.vertical.size.value<=o.vertical.value+1),s.vertical.thumbStart=y.computed(()=>l.verticalOffset[0]+s.vertical.percentage.value*(o.verticalInner.value-s.vertical.thumbSize.value)),s.vertical.thumbSize=y.computed(()=>Math.round(Dr(o.verticalInner.value*o.verticalInner.value/s.vertical.size.value,Ao(o.verticalInner.value),o.verticalInner.value))),s.vertical.style=y.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=y.computed(()=>"q-scrollarea__thumb q-scrollarea__thumb--v absolute-right"+(s.vertical.thumbHidden.value===!0?" q-scrollarea__thumb--invisible":"")),s.vertical.barClass=y.computed(()=>"q-scrollarea__bar q-scrollarea__bar--v absolute-right"+(s.vertical.thumbHidden.value===!0?" q-scrollarea__bar--invisible":"")),s.horizontal.percentage=y.computed(()=>{const M=s.horizontal.size.value-o.horizontal.value;if(M<=0)return 0;const _=Dr(Math.abs(s.horizontal.position.value)/M,0,1);return Math.round(_*1e4)/1e4}),s.horizontal.thumbHidden=y.computed(()=>(l.visible===null?c.value:l.visible)!==!0&&b.value===!1&&m.value===!1||s.horizontal.size.value<=o.horizontal.value+1),s.horizontal.thumbStart=y.computed(()=>l.horizontalOffset[0]+s.horizontal.percentage.value*(o.horizontalInner.value-s.horizontal.thumbSize.value)),s.horizontal.thumbSize=y.computed(()=>Math.round(Dr(o.horizontalInner.value*o.horizontalInner.value/s.horizontal.size.value,Ao(o.horizontalInner.value),o.horizontalInner.value))),s.horizontal.style=y.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=y.computed(()=>"q-scrollarea__thumb q-scrollarea__thumb--h absolute-bottom"+(s.horizontal.thumbHidden.value===!0?" q-scrollarea__thumb--invisible":"")),s.horizontal.barClass=y.computed(()=>"q-scrollarea__bar q-scrollarea__bar--h absolute-bottom"+(s.horizontal.thumbHidden.value===!0?" q-scrollarea__bar--invisible":""));const d=y.computed(()=>s.vertical.thumbHidden.value===!0&&s.horizontal.thumbHidden.value===!0?l.contentStyle:l.contentActiveStyle);function h(){const M={};return _o.forEach(_=>{const v=s[_];Object.assign(M,{[_+"Position"]:v.position.value,[_+"Percentage"]:v.percentage.value,[_+"Size"]:v.size.value,[_+"ContainerSize"]:o[_].value,[_+"ContainerInnerSize"]:o[_+"Inner"].value})}),M}const f=Ni(()=>{const M=h();M.ref=n,t("scroll",M)},0);function g(M,_,v){if(_o.includes(M)===!1){console.error("[QScrollArea]: wrong first param of setScrollPosition (vertical/horizontal)");return}(M==="vertical"?vo:Kn)(a.value,_,v)}function p({height:M,width:_}){let v=!1;o.vertical.value!==M&&(o.vertical.value=M,v=!0),o.horizontal.value!==_&&(o.horizontal.value=_,v=!0),v===!0&&q()}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&&q()}function C({height:M,width:_}){s.horizontal.size.value!==_&&(s.horizontal.size.value=_,q()),s.vertical.size.value!==M&&(s.vertical.size.value=M,q())}function T(M,_){const v=s[_];if(M.isFirst===!0){if(v.thumbHidden.value===!0)return;u=v.position.value,m.value=!0}else if(m.value!==!0)return;M.isFinal===!0&&(m.value=!1);const x=Gn[_],w=(v.size.value-o[_].value)/(o[_+"Inner"].value-v.thumbSize.value),S=M.distance[x.dist],E=u+(M.direction===x.dir?1:-1)*S*w;P(E,_)}function j(M,_){const v=s[_];if(v.thumbHidden.value!==!0){const x=_==="vertical"?l.verticalOffset[0]:l.horizontalOffset[0],w=M[Gn[_].offset]-x,S=v.thumbStart.value-x;if(w<S||w>S+v.thumbSize.value){const E=w-v.thumbSize.value/2,O=Dr(E/(o[_+"Inner"].value-v.thumbSize.value),0,1);P(O*Math.max(0,v.size.value-o[_].value),_)}v.ref.value!==null&&v.ref.value.dispatchEvent(new MouseEvent(M.type,M))}}function q(){b.value=!0,r!==null&&clearTimeout(r),r=setTimeout(()=>{r=null,b.value=!1},l.delay),l.onScroll!==void 0&&f()}function P(M,_){a.value[Gn[_].scroll]=M}let N=null;function V(){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;y.watch(()=>n.$q.lang.rtl,M=>{a.value!==null&&Kn(a.value,Math.abs(s.horizontal.position.value)*(M===!0?-1:1))}),y.onDeactivated(()=>{L={top:s.vertical.position.value,left:s.horizontal.position.value}}),y.onActivated(()=>{if(L===null)return;const M=a.value;M!==null&&(Kn(M,L.left),vo(M,L.top))}),y.onBeforeUnmount(f.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,_,v){g(M,_*(s[M].size.value-o[M].value)*(M==="horizontal"&&n.$q.lang.rtl===!0?-1:1),v)}});const A={scroll:s,thumbVertDir:[[So,M=>{T(M,"vertical")},void 0,{vertical:!0,...Co}]],thumbHorizDir:[[So,M=>{T(M,"horizontal")},void 0,{horizontal:!0,...Co}]],onVerticalMousedown(M){j(M,"vertical")},onHorizontalMousedown(M){j(M,"horizontal")}};return()=>y.h("div",{class:i.value,onMouseenter:V,onMouseleave:W},[y.h("div",{ref:a,class:"q-scrollarea__container scroll relative-position fit hide-scrollbar",tabindex:l.tabindex!==void 0?l.tabindex:void 0},[y.h("div",{class:"q-scrollarea__content absolute",style:d.value},It(I.default,[y.h(Rr,{debounce:0,onResize:C})])),y.h(Ea,{axis:"both",onScroll:k})]),y.h(Rr,{debounce:0,onResize:p}),y.h(ul,{store:A,barStyle:l.barStyle,verticalBarStyle:l.verticalBarStyle,horizontalBarStyle:l.horizontalBarStyle})])}}),Xr=$e({name:"QCard",props:{...Ot,tag:{type:String,default:"div"},square:Boolean,flat:Boolean,bordered:Boolean},setup(l,{slots:I}){const{proxy:{$q:t}}=y.getCurrentInstance(),b=Ft(l,t),m=y.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()=>y.h(l.tag,{class:m.value},gt(I.default))}}),Ma={target:{type:[Boolean,String,Element],default:!0},noParentEvent:Boolean},Ta={...Ma,contextMenu:Boolean};function Li({showing:l,avoidEmit:I,configureAnchorEl:t}){const{props:b,proxy:m,emit:c}=y.getCurrentInstance(),o=y.ref(null);let s=null;function n(i){return o.value===null?!1:i===void 0||i.touches===void 0||i.touches.length<=1}const e={};t===void 0&&(Object.assign(e,{hide(i){m.hide(i)},toggle(i){m.toggle(i),i.qAnchorHandled=!0},toggleKey(i){ir(i,13)===!0&&e.toggle(i)},contextClick(i){m.hide(i),Bt(i),y.nextTick(()=>{m.show(i),i.qAnchorHandled=!0})},prevent:Bt,mobileTouch(i){if(e.mobileCleanup(i),n(i)!==!0)return;m.hide(i),o.value.classList.add("non-selectable");const d=i.target;Kt(e,"anchor",[[d,"touchmove","mobileCleanup","passive"],[d,"touchend","mobileCleanup","passive"],[d,"touchcancel","mobileCleanup","passive"],[o.value,"contextmenu","prevent","notPassive"]]),s=setTimeout(()=>{s=null,m.show(i),i.qAnchorHandled=!0},300)},mobileCleanup(i){o.value.classList.remove("non-selectable"),s!==null&&(clearTimeout(s),s=null),l.value===!0&&i!==void 0&&Cn()}}),t=function(i=b.contextMenu){if(b.noParentEvent===!0||o.value===null)return;let d;i===!0?m.$q.platform.is.mobile===!0?d=[[o.value,"touchstart","mobileTouch","passive"]]:d=[[o.value,"mousedown","hide","passive"],[o.value,"contextmenu","contextClick","notPassive"]]:d=[[o.value,"click","toggle","passive"],[o.value,"keyup","toggleKey","passive"]],Kt(e,"anchor",d)});function r(){fr(e,"anchor")}function u(i){for(o.value=i;o.value.classList.contains("q-anchor--skip");)o.value=o.value.parentNode;t()}function a(){if(b.target===!1||b.target===""||m.$el.parentNode===null)o.value=null;else if(b.target===!0)u(m.$el.parentNode);else{let i=b.target;if(typeof b.target=="string")try{i=document.querySelector(b.target)}catch{i=void 0}i!=null?(o.value=i.$el||i,t()):(o.value=null,console.error(`Anchor: target "${b.target}" not found`))}}return y.watch(()=>b.contextMenu,i=>{o.value!==null&&(r(),t(i))}),y.watch(()=>b.target,()=>{o.value!==null&&r(),a()}),y.watch(()=>b.noParentEvent,i=>{o.value!==null&&(i===!0?r():t())}),y.onMounted(()=>{a(),I!==!0&&b.modelValue===!0&&o.value===null&&c("update:modelValue",!1)}),y.onBeforeUnmount(()=>{s!==null&&clearTimeout(s),r()}),{anchorEl:o,canShow:n,anchorEvents:e}}function Ra(l,I){const t=y.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 o=y.watch(()=>l.noParentEvent,()=>{t.value!==null&&(c(),I())});return y.onBeforeUnmount(o),{localScrollTarget:t,unconfigureScrollTarget:c,changeScrollEvent:m}}const Vi={modelValue:{type:Boolean,default:null},"onUpdate:modelValue":[Function,Array]},qi=["beforeShow","show","beforeHide","hide"];function zi({showing:l,canShow:I,hideOnRouteChange:t,handleShow:b,handleHide:m,processOnMount:c}){const o=y.getCurrentInstance(),{props:s,emit:n,proxy:e}=o;let r;function u(p){l.value===!0?d(p):a(p)}function a(p){if(s.disable===!0||p?.qAnchorHandled===!0||I!==void 0&&I(p)!==!0)return;const k=s["onUpdate:modelValue"]!==void 0;k===!0&&(n("update:modelValue",!0),r=p,y.nextTick(()=>{r===p&&(r=void 0)})),(s.modelValue===null||k===!1)&&i(p)}function i(p){l.value!==!0&&(l.value=!0,n("beforeShow",p),b!==void 0?b(p):n("show",p))}function d(p){if(s.disable===!0)return;const k=s["onUpdate:modelValue"]!==void 0;k===!0&&(n("update:modelValue",!1),r=p,y.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 f(p){s.disable===!0&&p===!0?s["onUpdate:modelValue"]!==void 0&&n("update:modelValue",!1):p===!0!==l.value&&(p===!0?i:h)(r)}y.watch(()=>s.modelValue,f),t!==void 0&&Ti(o)===!0&&y.watch(()=>e.$route.fullPath,()=>{t.value===!0&&l.value===!0&&d()}),y.onMounted(()=>{f(s.modelValue)});const g={show:a,hide:d,toggle:u};return Object.assign(e,g),g}let cr=[],Yr=[];function Ba(l){Yr=Yr.filter(I=>I!==l)}function kl(l){Ba(l),Yr.push(l)}function Eo(l){Ba(l),Yr.length===0&&cr.length!==0&&(cr[cr.length-1](),cr=[])}function Gr(l){Yr.length===0?l():cr.push(l)}function _l(l){cr=cr.filter(I=>I!==l)}const Mo={};let Cl=1,Al=document.body;function El(l,I){const t=document.createElement("div");if(t.id=I!==void 0?`q-portal--${I}--${Cl++}`:l,Mo.globalNodes!==void 0){const b=Mo.globalNodes.class;b!==void 0&&(t.className=b)}return Al.appendChild(t),t}function Ml(l){l.remove()}const Mr=[];function Tl(l){return Mr.find(I=>I.contentEl!==null&&I.contentEl.contains(l))}function Ia(l,I){do{if(l.$options.name==="QMenu"){if(l.hide(I),l.$props.separateClosePopup===!0)return wn(l)}else if(l.__qPortal===!0){const t=wn(l);return t?.$options.name==="QPopupProxy"?(l.hide(I),t):l}l=wn(l)}while(l!=null)}function Rl(l,I,t){for(;t!==0&&l!==void 0&&l!==null;){if(l.__qPortal===!0){if(t--,l.$options.name==="QMenu"){l=Ia(l,I);continue}l.hide(I)}l=wn(l)}}const Bl=$e({name:"QPortal",setup(l,{slots:I}){return()=>I.default()}});function Il(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 Ui(l,I,t,b){const m=y.ref(!1),c=y.ref(!1);let o=null;const s={},n=b==="dialog"&&Il(l);function e(u){if(u===!0){Eo(s),c.value=!0;return}c.value=!1,m.value===!1&&(n===!1&&o===null&&(o=El(!1,b)),m.value=!0,Mr.push(l.proxy),kl(s))}function r(u){if(c.value=!1,u!==!0)return;Eo(s),m.value=!1;const a=Mr.indexOf(l.proxy);a!==-1&&Mr.splice(a,1),o!==null&&(Ml(o),o=null)}return y.onUnmounted(()=>{r(!0)}),l.proxy.__qPortal=!0,Lt(l.proxy,"contentEl",()=>I.value),{showPortal:e,hidePortal:r,portalIsActive:m,portalIsAccessible:c,renderPortal:()=>n===!0?t():m.value===!0?[y.h(y.Teleport,{to:o},y.h(Bl,t))]:void 0}}const Ur={transitionShow:{type:String,default:"fade"},transitionHide:{type:String,default:"fade"},transitionDuration:{type:[String,Number],default:300}};function Wi(l,I=()=>{},t=()=>{}){return{transitionProps:y.computed(()=>{const b=`q-transition--${l.transitionShow||I()}`,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:y.computed(()=>`--q-transition-duration: ${l.transitionDuration}ms`)}}function Hi(){let l;const I=y.getCurrentInstance();function t(){l=void 0}return y.onDeactivated(t),y.onBeforeUnmount(t),{removeTick:t,registerTick(b){l=b,y.nextTick(()=>{l===b&&(Ri(I)===!1&&l(),l=void 0)})}}}function Yi(){let l=null;const I=y.getCurrentInstance();function t(){l!==null&&(clearTimeout(l),l=null)}return y.onDeactivated(t),y.onBeforeUnmount(t),{removeTimeout:t,registerTimeout(b,m){t(),Ri(I)===!1&&(l=setTimeout(()=>{l=null,b()},m))}}}const dr=[];let Br;function Ol(l){Br=l.keyCode===27}function Fl(){Br===!0&&(Br=!1)}function jl(l){Br===!0&&(Br=!1,ir(l,27)===!0&&dr[dr.length-1](l))}function Oa(l){window[l]("keydown",Ol),window[l]("blur",Fl),window[l]("keyup",jl),Br=!1}function Fa(l){Et.is.desktop===!0&&(dr.push(l),dr.length===1&&Oa("addEventListener"))}function An(l){const I=dr.indexOf(l);I!==-1&&(dr.splice(I,1),dr.length===0&&Oa("removeEventListener"))}const hr=[];function ja(l){hr[hr.length-1](l)}function Da(l){Et.is.desktop===!0&&(hr.push(l),hr.length===1&&document.body.addEventListener("focusin",ja))}function bi(l){const I=hr.indexOf(l);I!==-1&&(hr.splice(I,1),hr.length===0&&document.body.removeEventListener("focusin",ja))}const{notPassiveCapture:En}=_t,pr=[];function Mn(l){const I=l.target;if(I===void 0||I.nodeType===8||I.classList.contains("no-pointer-events")===!0)return;let t=Mr.length-1;for(;t>=0;){const b=Mr[t].$;if(b.type.name==="QTooltip"){t--;continue}if(b.type.name!=="QDialog")break;if(b.props.seamless!==!0)return;t--}for(let b=pr.length-1;b>=0;b--){const m=pr[b];if((m.anchorEl.value===null||m.anchorEl.value.contains(I)===!1)&&(I===document.body||m.innerRef.value!==null&&m.innerRef.value.contains(I)===!1))l.qClickOutside=!0,m.onClickOutside(l);else return}}function Pa(l){pr.push(l),pr.length===1&&(document.addEventListener("mousedown",Mn,En),document.addEventListener("touchstart",Mn,En))}function Tn(l){const I=pr.findIndex(t=>t===l);I!==-1&&(pr.splice(I,1),pr.length===0&&(document.removeEventListener("mousedown",Mn,En),document.removeEventListener("touchstart",Mn,En)))}let To,Ro;function Rn(l){const I=l.split(" ");return I.length!==2?!1:["top","center","bottom"].includes(I[0])!==!0?(console.error("Anchor/Self position must start with one of top/center/bottom"),!1):["left","middle","right","start","end"].includes(I[1])!==!0?(console.error("Anchor/Self position must end with one of left/middle/right/start/end"),!1):!0}function Na(l){return l?!(l.length!==2||typeof l[0]!="number"||typeof l[1]!="number"):!0}const vi={"start#ltr":"left","start#rtl":"right","end#ltr":"right","end#rtl":"left"};["left","middle","right"].forEach(l=>{vi[`${l}#ltr`]=l,vi[`${l}#rtl`]=l});function Bn(l,I){const t=l.split(" ");return{vertical:t[0],horizontal:vi[`${t[1]}#${I===!0?"rtl":"ltr"}`]}}function Dl(l,I){let{top:t,left:b,right:m,bottom:c,width:o,height:s}=l.getBoundingClientRect();return I!==void 0&&(t-=I[1],b-=I[0],c+=I[1],m+=I[0],o+=I[0],s+=I[1]),{top:t,bottom:c,height:s,left:b,right:m,width:o,middle:b+(m-b)/2,center:t+(c-t)/2}}function Pl(l,I,t){let{top:b,left:m}=l.getBoundingClientRect();return b+=I.top,m+=I.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 Nl(l,I){return{top:0,center:I/2,bottom:I,left:0,middle:l/2,right:l}}function Bo(l,I,t,b){return{top:l[t.vertical]-I[b.vertical],left:l[t.horizontal]-I[b.horizontal]}}function Qi(l,I=0){if(l.targetEl===null||l.anchorEl===null||I>5)return;if(l.targetEl.offsetHeight===0||l.targetEl.offsetWidth===0){setTimeout(()=>{Qi(l,I+1)},10);return}const{targetEl:t,offset:b,anchorEl:m,anchorOrigin:c,selfOrigin:o,absoluteOffset:s,fit:n,cover:e,maxHeight:r,maxWidth:u}=l;if(Et.is.ios===!0&&window.visualViewport!==void 0){const j=document.body.style,{offsetLeft:q,offsetTop:P}=window.visualViewport;q!==To&&(j.setProperty("--q-pe-left",q+"px"),To=q),P!==Ro&&(j.setProperty("--q-pe-top",P+"px"),Ro=P)}const{scrollLeft:a,scrollTop:i}=t,d=s===void 0?Dl(m,e===!0?[0,0]:b):Pl(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:f}=t,{elWidth:g,elHeight:p}=n===!0||e===!0?{elWidth:Math.max(d.width,h),elHeight:e===!0?Math.max(d.height,f):f}:{elWidth:h,elHeight:f};let k={maxWidth:u,maxHeight:r};(n===!0||e===!0)&&(k.minWidth=d.width+"px",e===!0&&(k.minHeight=d.height+"px")),Object.assign(t.style,k);const C=Nl(g,p);let T=Bo(d,C,c,o);if(s===void 0||b===void 0)Jn(T,d,C,c,o);else{const{top:j,left:q}=T;Jn(T,d,C,c,o);let P=!1;if(T.top!==j){P=!0;const N=2*b[1];d.center=d.top-=N,d.bottom-=N+2}if(T.left!==q){P=!0;const N=2*b[0];d.middle=d.left-=N,d.right-=N+2}P===!0&&(T=Bo(d,C,c,o),Jn(T,d,C,c,o))}k={top:T.top+"px",left:T.left+"px"},T.maxHeight!==void 0&&(k.maxHeight=T.maxHeight+"px",d.height>T.maxHeight&&(k.minHeight=k.maxHeight)),T.maxWidth!==void 0&&(k.maxWidth=T.maxWidth+"px",d.width>T.maxWidth&&(k.minWidth=k.maxWidth)),Object.assign(t.style,k),t.scrollTop!==i&&(t.scrollTop=i),t.scrollLeft!==a&&(t.scrollLeft=a)}function Jn(l,I,t,b,m){const c=t.bottom,o=t.right,s=xn(),n=window.innerHeight-s,e=document.body.clientWidth;if(l.top<0||l.top+c>n)if(m.vertical==="center")l.top=I[b.vertical]>n/2?Math.max(0,n-c):0,l.maxHeight=Math.min(c,n);else if(I[b.vertical]>n/2){const r=Math.min(n,b.vertical==="center"?I.center:b.vertical===m.vertical?I.bottom:I.top);l.maxHeight=Math.min(c,r),l.top=Math.max(0,r-c)}else l.top=Math.max(0,b.vertical==="center"?I.center:b.vertical===m.vertical?I.top:I.bottom),l.maxHeight=Math.min(c,n-l.top);if(l.left<0||l.left+o>e)if(l.maxWidth=Math.min(o,e),m.horizontal==="middle")l.left=I[b.horizontal]>e/2?Math.max(0,e-o):0;else if(I[b.horizontal]>e/2){const r=Math.min(e,b.horizontal==="middle"?I.middle:b.horizontal===m.horizontal?I.right:I.left);l.maxWidth=Math.min(o,r),l.left=Math.max(0,r-l.maxWidth)}else l.left=Math.max(0,b.horizontal==="middle"?I.middle:b.horizontal===m.horizontal?I.left:I.right),l.maxWidth=Math.min(o,e-l.left)}const Jr=$e({name:"QMenu",inheritAttrs:!1,props:{...Ta,...Vi,...Ot,...Ur,persistent:Boolean,autoClose:Boolean,separateClosePopup:Boolean,noEscDismiss:Boolean,noRouteDismiss:Boolean,noRefocus:Boolean,noFocus:Boolean,fit:Boolean,cover:Boolean,square:Boolean,anchor:{type:String,validator:Rn},self:{type:String,validator:Rn},offset:{type:Array,validator:Na},scrollTarget:Ln,touchPosition:Boolean,maxHeight:{type:String,default:null},maxWidth:{type:String,default:null}},emits:[...qi,"click","escapeKey"],setup(l,{slots:I,emit:t,attrs:b}){let m=null,c,o,s;const n=y.getCurrentInstance(),{proxy:e}=n,{$q:r}=e,u=y.ref(null),a=y.ref(!1),i=y.computed(()=>l.persistent!==!0&&l.noRouteDismiss!==!0),d=Ft(l,r),{registerTick:h,removeTick:f}=Hi(),{registerTimeout:g}=Yi(),{transitionProps:p,transitionStyle:k}=Wi(l),{localScrollTarget:C,changeScrollEvent:T,unconfigureScrollTarget:j}=Ra(l,z),{anchorEl:q,canShow:P}=Li({showing:a}),{hide:N}=zi({showing:a,canShow:P,handleShow:E,handleHide:O,hideOnRouteChange:i,processOnMount:!0}),{showPortal:V,hidePortal:W,renderPortal:L}=Ui(n,u,F,"menu"),A={anchorEl:q,innerRef:u,onClickOutside(B){if(l.persistent!==!0&&a.value===!0)return N(B),(B.type==="touchstart"||B.target.classList.contains("q-dialog__backdrop"))&&St(B),!0}},M=y.computed(()=>Bn(l.anchor||(l.cover===!0?"center middle":"bottom start"),r.lang.rtl)),_=y.computed(()=>l.cover===!0?M.value:Bn(l.self||"top start",r.lang.rtl)),v=y.computed(()=>(l.square===!0?" q-menu--square":"")+(d.value===!0?" q-menu--dark q-dark":"")),x=y.computed(()=>l.autoClose===!0?{onClick:U}:{}),w=y.computed(()=>a.value===!0&&l.persistent!==!0);y.watch(w,B=>{B===!0?(Fa(D),Pa(A)):(An(D),Tn(A))});function S(){Gr(()=>{let B=u.value;B&&B.contains(document.activeElement)!==!0&&(B=B.querySelector("[autofocus][tabindex], [data-autofocus][tabindex]")||B.querySelector("[autofocus] [tabindex], [data-autofocus] [tabindex]")||B.querySelector("[autofocus], [data-autofocus]")||B,B.focus({preventScroll:!0}))})}function E(B){if(m=l.noRefocus===!1?document.activeElement:null,Da(Q),V(),z(),c=void 0,B!==void 0&&(l.touchPosition||l.contextMenu)){const H=Hr(B);if(H.left!==void 0){const{top:K,left:$}=q.value.getBoundingClientRect();c={left:H.left-$,top:H.top-K}}}o===void 0&&(o=y.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(),V(!0),t("show",B)},l.transitionDuration)}function O(B){f(),W(),R(!0),m!==null&&(B===void 0||B.qClickOutside!==!0)&&(((B?.type.indexOf("key")===0?m.closest('[tabindex]:not([tabindex^="-"])'):void 0)||m).focus(),m=null),g(()=>{W(!0),t("hide",B)},l.transitionDuration)}function R(B){c=void 0,o!==void 0&&(o(),o=void 0),(B===!0||a.value===!0)&&(bi(Q),j(),Tn(A),An(D)),B!==!0&&(m=null)}function z(){(q.value!==null||l.scrollTarget!==void 0)&&(C.value=Vn(q.value,l.scrollTarget),T(C.value,Y))}function U(B){s!==!0?(Ia(e,B),t("click",B)):s=!1}function Q(B){w.value===!0&&l.noFocus!==!0&&ga(u.value,B.target)!==!0&&S()}function D(B){l.noEscDismiss!==!0&&(t("escapeKey"),N(B))}function Y(){Qi({targetEl:u.value,offset:l.offset,anchorEl:q.value,anchorOrigin:M.value,selfOrigin:_.value,absoluteOffset:c,fit:l.fit,cover:l.cover,maxHeight:l.maxHeight,maxWidth:l.maxWidth})}function F(){return y.h(y.Transition,p.value,()=>a.value===!0?y.h("div",{role:"menu",...b,ref:u,tabindex:-1,class:["q-menu q-position-engine scroll"+v.value,b.class],style:[b.style,k.value],...x.value},gt(I.default)):null)}return y.onBeforeUnmount(R),Object.assign(e,{focus:S,updatePosition:Y}),L}});let Zn,ln=0;const Mt=new Array(256);for(let l=0;l<256;l++)Mt[l]=(l+256).toString(16).substring(1);const Ll=(()=>{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 I=>{const t=new Uint8Array(I);return l.getRandomValues(t),t}}return I=>{const t=[];for(let b=I;b>0;b--)t.push(Math.floor(Math.random()*256));return t}})(),Io=4096;function yi(){(Zn===void 0||ln+16>Io)&&(ln=0,Zn=Ll(Io));const l=Array.prototype.slice.call(Zn,ln,ln+=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 Vl(l){return l??null}function Oo(l,I){return l??(I===!0?`f_${yi()}`:null)}function ql({getValue:l,required:I=!0}={}){if(or.value===!0){const t=l!==void 0?y.ref(Vl(l())):y.ref(null);return I===!0&&t.value===null&&y.onMounted(()=>{t.value=`f_${yi()}`}),l!==void 0&&y.watch(l,b=>{t.value=Oo(b,I)}),t}return l!==void 0?y.computed(()=>Oo(l(),I)):y.ref(`f_${yi()}`)}const Fo=/^on[A-Z]/;function zl(){const{attrs:l,vnode:I}=y.getCurrentInstance(),t={listeners:y.ref({}),attributes:y.ref({})};function b(){const m={},c={};for(const o in l)o!=="class"&&o!=="style"&&Fo.test(o)===!1&&(m[o]=l[o]);for(const o in I.props)Fo.test(o)===!0&&(c[o]=I.props[o]);t.attributes.value=m,t.listeners.value=c}return y.onBeforeUpdate(b),b(),t}const Ul="_q_",Zr="_q_l_",La="_q_pc_",Va="_q_fo_";function Rt(){}function Wl({validate:l,resetValidation:I,requiresQForm:t}){const b=y.inject(Va,!1);if(b!==!1){const{props:m,proxy:c}=y.getCurrentInstance();Object.assign(c,{validate:l,resetValidation:I}),y.watch(()=>m.disable,o=>{o===!0?(typeof I=="function"&&I(),b.unbindComponent(c)):b.bindComponent(c)}),y.onMounted(()=>{m.disable!==!0&&b.bindComponent(c)}),y.onBeforeUnmount(()=>{m.disable!==!0&&b.unbindComponent(c)})}else t===!0&&console.error("Parent QForm not found on useFormChild()!")}const jo=/^#[0-9a-fA-F]{3}([0-9a-fA-F]{3})?$/,Do=/^#[0-9a-fA-F]{4}([0-9a-fA-F]{4})?$/,Po=/^#([0-9a-fA-F]{3}|[0-9a-fA-F]{4}|[0-9a-fA-F]{6}|[0-9a-fA-F]{8})$/,un=/^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])\)$/,cn=/^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)\)$/,$n={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=>jo.test(l),hexaColor:l=>Do.test(l),hexOrHexaColor:l=>Po.test(l),rgbColor:l=>un.test(l),rgbaColor:l=>cn.test(l),rgbOrRgbaColor:l=>un.test(l)||cn.test(l),hexOrRgbColor:l=>jo.test(l)||un.test(l),hexaOrRgbaColor:l=>Do.test(l)||cn.test(l),anyColor:l=>Po.test(l)||un.test(l)||cn.test(l)},Hl=[!0,!1,"ondemand"],Yl={modelValue:{},error:{type:Boolean,default:null},errorMessage:String,noErrorIcon:Boolean,rules:Array,reactiveRules:Boolean,lazyRules:{type:[Boolean,String],default:!1,validator:l=>Hl.includes(l)}};function Ql(l,I){const{props:t,proxy:b}=y.getCurrentInstance(),m=y.ref(!1),c=y.ref(null),o=y.ref(!1);Wl({validate:h,resetValidation:d});let s=0,n;const e=y.computed(()=>t.rules!==void 0&&t.rules!==null&&t.rules.length!==0),r=y.computed(()=>t.disable!==!0&&e.value===!0&&I.value===!1),u=y.computed(()=>t.error===!0||m.value===!0),a=y.computed(()=>typeof t.errorMessage=="string"&&t.errorMessage.length!==0?t.errorMessage:c.value);y.watch(()=>t.modelValue,()=>{o.value=!0,r.value===!0&&t.lazyRules===!1&&f()});function i(){t.lazyRules!=="ondemand"&&r.value===!0&&o.value===!0&&f()}y.watch(()=>t.reactiveRules,g=>{g===!0?n===void 0&&(n=y.watch(()=>t.rules,i,{immediate:!0,deep:!0})):n!==void 0&&(n(),n=void 0)},{immediate:!0}),y.watch(()=>t.lazyRules,i),y.watch(l,g=>{g===!0?o.value=!0:r.value===!0&&t.lazyRules!=="ondemand"&&f()});function d(){s++,I.value=!1,o.value=!1,m.value=!1,c.value=null,f.cancel()}function h(g=t.modelValue){if(t.disable===!0||e.value===!1)return!0;const p=++s,k=I.value!==!0?()=>{o.value=!0}:()=>{},C=(j,q)=>{j===!0&&k(),m.value=j,c.value=q||null,I.value=!1},T=[];for(let j=0;j<t.rules.length;j++){const q=t.rules[j];let P;if(typeof q=="function"?P=q(g,$n):typeof q=="string"&&$n[q]!==void 0&&(P=$n[q](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):(I.value=!0,Promise.all(T).then(j=>{if(j===void 0||Array.isArray(j)===!1||j.length===0)return p===s&&C(!1),!0;const q=j.find(P=>P===!1||typeof P=="string");return p===s&&C(q!==void 0,q),q===void 0},j=>(p===s&&(console.error(j),C(!0)),!1)))}const f=Ni(h,0);return y.onBeforeUnmount(()=>{n?.(),f.cancel()}),Object.assign(b,{resetValidation:d,validate:h}),Lt(b,"hasError",()=>u.value),{isDirtyModel:o,hasRules:e,hasError:u,errorMessage:a,validate:h,resetValidation:d}}function Qr(l){return l!=null&&(""+l).length!==0}const Kl={...Ot,...Yl,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},qn={...Kl,maxlength:[Number,String]},Ki=["update:modelValue","clear","focus","blur"];function Xi({requiredForAttr:l=!0,tagProp:I,changeEvent:t=!1}={}){const{props:b,proxy:m}=y.getCurrentInstance(),c=Ft(b,m.$q),o=ql({required:l,getValue:()=>b.for});return{requiredForAttr:l,changeEvent:t,tag:I===!0?y.computed(()=>b.tag):{value:"label"},isDark:c,editable:y.computed(()=>b.disable!==!0&&b.readonly!==!0),innerLoading:y.ref(!1),focused:y.ref(!1),hasPopupOpen:!1,splitAttrs:zl(),targetUid:o,rootRef:y.ref(null),targetRef:y.ref(null),controlRef:y.ref(null)}}function Gi(l){const{props:I,emit:t,slots:b,attrs:m,proxy:c}=y.getCurrentInstance(),{$q:o}=c;let s=null;l.hasValue===void 0&&(l.hasValue=y.computed(()=>Qr(I.modelValue))),l.emitValue===void 0&&(l.emitValue=w=>{t("update:modelValue",w)}),l.controlEvents===void 0&&(l.controlEvents={onFocusin:N,onFocusout:V}),Object.assign(l,{clearValue:W,onControlFocusin:N,onControlFocusout:V,focus:q}),l.computedCounter===void 0&&(l.computedCounter=y.computed(()=>{if(I.counter!==!1){const w=typeof I.modelValue=="string"||typeof I.modelValue=="number"?(""+I.modelValue).length:Array.isArray(I.modelValue)===!0?I.modelValue.length:0,S=I.maxlength!==void 0?I.maxlength:I.maxValues;return w+(S!==void 0?" / "+S:"")}}));const{isDirtyModel:n,hasRules:e,hasError:r,errorMessage:u,resetValidation:a}=Ql(l.focused,l.innerLoading),i=l.floatingLabel!==void 0?y.computed(()=>I.stackLabel===!0||l.focused.value===!0||l.floatingLabel.value===!0):y.computed(()=>I.stackLabel===!0||l.focused.value===!0||l.hasValue.value===!0),d=y.computed(()=>I.bottomSlots===!0||I.hint!==void 0||e.value===!0||I.counter===!0||I.error!==null),h=y.computed(()=>I.filled===!0?"filled":I.outlined===!0?"outlined":I.borderless===!0?"borderless":I.standout?"standout":"standard"),f=y.computed(()=>`q-field row no-wrap items-start q-field--${h.value}`+(l.fieldClass!==void 0?` ${l.fieldClass.value}`:"")+(I.rounded===!0?" q-field--rounded":"")+(I.square===!0?" q-field--square":"")+(i.value===!0?" q-field--float":"")+(p.value===!0?" q-field--labeled":"")+(I.dense===!0?" q-field--dense":"")+(I.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":"")+(I.hideBottomSpace!==!0&&d.value===!0?" q-field--with-bottom":"")+(I.disable===!0?" q-field--disabled":I.readonly===!0?" q-field--readonly":"")),g=y.computed(()=>"q-field__control relative-position row no-wrap"+(I.bgColor!==void 0?` bg-${I.bgColor}`:"")+(r.value===!0?" text-negative":typeof I.standout=="string"&&I.standout.length!==0&&l.focused.value===!0?` ${I.standout}`:I.color!==void 0?` text-${I.color}`:"")),p=y.computed(()=>I.labelSlot===!0||I.label!==void 0),k=y.computed(()=>"q-field__label no-pointer-events absolute ellipsis"+(I.labelColor!==void 0&&r.value!==!0?` text-${I.labelColor}`:"")),C=y.computed(()=>({id:l.targetUid.value,editable:l.editable.value,focused:l.focused.value,floatingLabel:i.value,modelValue:I.modelValue,emitValue:l.emitValue})),T=y.computed(()=>{const w={};return l.targetUid.value&&(w.for=l.targetUid.value),I.disable===!0&&(w["aria-disabled"]="true"),w});function j(){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 q(){Gr(j)}function P(){_l(j);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 V(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),o.platform.is.mobile!==!0?(l.targetRef?.value||l.rootRef.value).focus():l.rootRef.value.contains(document.activeElement)===!0&&document.activeElement.blur(),I.type==="file"&&(l.inputRef.value.value=null),t("update:modelValue",null),l.changeEvent===!0&&t("change",null),t("clear",I.modelValue),y.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(y.h("div",{class:"q-field__prepend q-field__marginal row no-wrap items-center",key:"prepend",onClick:Bt},b.prepend())),w.push(y.h("div",{class:"q-field__control-container col relative-position row no-wrap q-anchor--skip"},M())),r.value===!0&&I.noErrorIcon===!1&&w.push(v("error",[y.h(bt,{name:o.iconSet.field.error,color:"negative"})])),I.loading===!0||l.innerLoading.value===!0?w.push(v("inner-loading-append",b.loading!==void 0?b.loading():[y.h(ma,{color:I.color})])):I.clearable===!0&&l.hasValue.value===!0&&l.editable.value===!0&&w.push(v("inner-clearable-append",[y.h(bt,{class:"q-field__focusable-action",name:I.clearIcon||o.iconSet.field.clear,tabindex:0,role:"button","aria-hidden":"false","aria-label":o.lang.label.clear,onKeyup:L,onClick:W})])),b.append!==void 0&&w.push(y.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(v("inner-append",l.getInnerAppend())),l.getControlChild!==void 0&&w.push(l.getControlChild()),w}function M(){const w=[];return I.prefix!==void 0&&I.prefix!==null&&w.push(y.h("div",{class:"q-field__prefix no-pointer-events row items-center"},I.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(y.h("div",{ref:l.targetRef,class:"q-field__native row",tabindex:-1,...l.splitAttrs.attributes.value,"data-autofocus":I.autofocus===!0||void 0},b.control(C.value))),p.value===!0&&w.push(y.h("div",{class:k.value},gt(b.label,I.label))),I.suffix!==void 0&&I.suffix!==null&&w.push(y.h("div",{class:"q-field__suffix no-pointer-events row items-center"},I.suffix)),w.concat(gt(b.default))}function _(){let w,S;r.value===!0?u.value!==null?(w=[y.h("div",{role:"alert"},u.value)],S=`q--slot-error-${u.value}`):(w=gt(b.error),S="q--slot-error"):(I.hideHint!==!0||l.focused.value===!0)&&(I.hint!==void 0?(w=[y.h("div",I.hint)],S=`q--slot-hint-${I.hint}`):(w=gt(b.hint),S="q--slot-hint"));const E=I.counter===!0||b.counter!==void 0;if(I.hideBottomSpace===!0&&E===!1&&w===void 0)return;const O=y.h("div",{key:S,class:"q-field__messages col"},w);return y.h("div",{class:"q-field__bottom row items-start q-field__bottom--"+(I.hideBottomSpace!==!0?"animated":"stale"),onClick:Bt},[I.hideBottomSpace===!0?O:y.h(y.Transition,{name:"q-transition--field-message"},()=>O),E===!0?y.h("div",{class:"q-field__counter"},b.counter!==void 0?b.counter():l.computedCounter.value):null])}function v(w,S){return S===null?null:y.h("div",{key:w,class:"q-field__append q-field__marginal row no-wrap items-center q-anchor--skip"},S)}let x=!1;return y.onDeactivated(()=>{x=!0}),y.onActivated(()=>{x===!0&&I.autofocus===!0&&c.focus()}),I.autofocus===!0&&y.onMounted(()=>{c.focus()}),y.onBeforeUnmount(()=>{s!==null&&clearTimeout(s)}),Object.assign(c,{focus:q,blur:P}),function(){const S=l.getControl===void 0&&b.control===void 0?{...l.splitAttrs.attributes.value,"data-autofocus":I.autofocus===!0||void 0,...T.value}:T.value;return y.h(l.tag.value,{ref:l.rootRef,class:[f.value,m.class],style:m.style,...S},[b.before!==void 0?y.h("div",{class:"q-field__before q-field__marginal row no-wrap items-center",onClick:Bt},b.before()):null,y.h("div",{class:"q-field__inner relative-position col self-stretch"},[y.h("div",{ref:l.controlRef,class:g.value,tabindex:-1,...l.controlEvents},A()),d.value===!0?_():null]),b.after!==void 0?y.h("div",{class:"q-field__after q-field__marginal row no-wrap items-center",onClick:Bt},b.after()):null])}}const Xl=$e({name:"QField",inheritAttrs:!1,props:{...qn,tag:{type:String,default:"label"}},emits:Ki,setup(){return Gi(Xi({tagProp:!0}))}}),Gl={xs:8,sm:10,md:14,lg:20,xl:24},qa=$e({name:"QChip",props:{...Ot,...Or,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:I,emit:t}){const{proxy:{$q:b}}=y.getCurrentInstance(),m=Ft(l,b),c=Fr(l,Gl),o=y.computed(()=>l.selected===!0||l.icon!==void 0),s=y.computed(()=>l.selected===!0?l.iconSelected||b.iconSet.chip.selected:l.icon),n=y.computed(()=>l.iconRemove||b.iconSet.chip.remove),e=y.computed(()=>l.disable===!1&&(l.clickable===!0||l.selected!==null)),r=y.computed(()=>{const f=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}`:"")+(f?` text-${f} 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=y.computed(()=>{const f=l.disable===!0?{tabindex:-1,"aria-disabled":"true"}:{tabindex:l.tabindex||0},g={...f,role:"button","aria-hidden":"false","aria-label":l.removeAriaLabel||b.lang.label.remove};return{chip:f,remove:g}});function a(f){f.keyCode===13&&i(f)}function i(f){l.disable||(t("update:selected",!l.selected),t("click",f))}function d(f){(f.keyCode===void 0||f.keyCode===13)&&(St(f),l.disable===!1&&(t("update:modelValue",!1),t("remove")))}function h(){const f=[];e.value===!0&&f.push(y.h("div",{class:"q-focus-helper"})),o.value===!0&&f.push(y.h(bt,{class:"q-chip__icon q-chip__icon--left",name:s.value}));const g=l.label!==void 0?[y.h("div",{class:"ellipsis"},[l.label])]:void 0;return f.push(y.h("div",{class:"q-chip__content col row no-wrap items-center q-anchor--skip"},sa(I.default,g))),l.iconRight&&f.push(y.h(bt,{class:"q-chip__icon q-chip__icon--right",name:l.iconRight})),l.removable===!0&&f.push(y.h(bt,{class:"q-chip__icon q-chip__icon--remove cursor-pointer",name:n.value,...u.value.remove,onClick:d,onKeyup:d})),f}return()=>{if(l.modelValue===!1)return;const f={class:r.value,style:c.value};return e.value===!0&&Object.assign(f,u.value.chip,{onClick:i,onKeyup:a}),Cs("div",f,h(),"ripple",l.ripple!==!1&&l.disable!==!0,()=>[[ba,l.ripple]])}}}),Cr=$e({name:"QItem",props:{...Ot,...ha,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:I,emit:t}){const{proxy:{$q:b}}=y.getCurrentInstance(),m=Ft(l,b),{hasLink:c,linkAttrs:o,linkClass:s,linkTag:n,navigateOnClick:e}=Bi(),r=y.ref(null),u=y.ref(null),a=y.computed(()=>l.clickable===!0||c.value===!0||l.tag==="label"),i=y.computed(()=>l.disable!==!0&&a.value===!0),d=y.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":"")+(i.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=y.computed(()=>l.insetLevel===void 0?null:{["padding"+(b.lang.rtl===!0?"Right":"Left")]:16+l.insetLevel*56+"px"});function f(k){i.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(i.value===!0&&ir(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=Mi(I.default,[]);return i.value===!0&&k.unshift(y.h("div",{class:"q-focus-helper",tabindex:-1,ref:u})),k}return()=>{const k={ref:r,class:d.value,style:h.value,role:"listitem",onClick:f,onKeyup:g};return i.value===!0?(k.tabindex=l.tabindex||"0",Object.assign(k,o.value)):a.value===!0&&(k["aria-disabled"]="true"),y.h(n.value,k,p())}}}),Ar=$e({name:"QItemSection",props:{avatar:Boolean,thumbnail:Boolean,side:Boolean,top:Boolean,noWrap:Boolean},setup(l,{slots:I}){const t=y.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()=>y.h("div",{class:t.value},gt(I.default))}}),wi=$e({name:"QItemLabel",props:{overline:Boolean,caption:Boolean,header:Boolean,lines:[Number,String]},setup(l,{slots:I}){const t=y.computed(()=>parseInt(l.lines,10)),b=y.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=y.computed(()=>l.lines!==void 0&&t.value>1?{overflow:"hidden",display:"-webkit-box","-webkit-box-orient":"vertical","-webkit-line-clamp":t.value}:null);return()=>y.h("div",{style:m.value,class:b.value},gt(I.default))}});function Jl(l,I,t){function b(){}return y.onBeforeUnmount(()=>{l.value===!0&&void 0}),{removeFromHistory:b,addToHistory(){}}}let Pr=0,ei,ti,Vr,ri=!1,No,Lo,Vo,lr=null;function Zl(l){$l(l)&&St(l)}function $l(l){if(l.target===document.body||l.target.classList.contains("q-layout__backdrop"))return!0;const I=Ys(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<I.length;c++){const o=I[c];if(gl(o,b))return b?m<0&&o.scrollTop===0?!0:m>0&&o.scrollTop+o.clientHeight===o.scrollHeight:m<0&&o.scrollLeft===0?!0:m>0&&o.scrollLeft+o.clientWidth===o.scrollWidth}return!0}function qo(l){l.target===document&&(document.scrollingElement.scrollTop=document.scrollingElement.scrollTop)}function fn(l){ri!==!0&&(ri=!0,requestAnimationFrame(()=>{ri=!1;const{height:I}=l.target,{clientHeight:t,scrollTop:b}=document.scrollingElement;(Vr===void 0||I!==window.innerHeight)&&(Vr=t-I,document.scrollingElement.scrollTop=b),b>Vr&&(document.scrollingElement.scrollTop-=Math.ceil((b-Vr)/8))}))}function zo(l){const I=document.body,t=window.visualViewport!==void 0;if(l==="add"){const{overflowY:b,overflowX:m}=window.getComputedStyle(I);ei=Di(window),ti=ji(window),No=I.style.left,Lo=I.style.top,Vo=window.location.href,I.style.left=`-${ei}px`,I.style.top=`-${ti}px`,m!=="hidden"&&(m==="scroll"||I.scrollWidth>window.innerWidth)&&I.classList.add("q-body--force-scrollbar-x"),b!=="hidden"&&(b==="scroll"||I.scrollHeight>window.innerHeight)&&I.classList.add("q-body--force-scrollbar-y"),I.classList.add("q-body--prevent-scroll"),document.qScrollPrevented=!0,Et.is.ios===!0&&(t===!0?(window.scrollTo(0,0),window.visualViewport.addEventListener("resize",fn,_t.passiveCapture),window.visualViewport.addEventListener("scroll",fn,_t.passiveCapture),window.scrollTo(0,0)):window.addEventListener("scroll",qo,_t.passiveCapture))}Et.is.desktop===!0&&Et.is.mac===!0&&window[`${l}EventListener`]("wheel",Zl,_t.notPassive),l==="remove"&&(Et.is.ios===!0&&(t===!0?(window.visualViewport.removeEventListener("resize",fn,_t.passiveCapture),window.visualViewport.removeEventListener("scroll",fn,_t.passiveCapture)):window.removeEventListener("scroll",qo,_t.passiveCapture)),I.classList.remove("q-body--prevent-scroll"),I.classList.remove("q-body--force-scrollbar-x"),I.classList.remove("q-body--force-scrollbar-y"),document.qScrollPrevented=!1,I.style.left=No,I.style.top=Lo,window.location.href===Vo&&window.scrollTo(ei,ti),Vr=void 0)}function eu(l){let I="add";if(l===!0){if(Pr++,lr!==null){clearTimeout(lr),lr=null;return}if(Pr>1)return}else{if(Pr===0||(Pr--,Pr>0))return;if(I="remove",Et.is.ios===!0&&Et.is.nativeMobile===!0){lr!==null&&clearTimeout(lr),lr=setTimeout(()=>{zo(I),lr=null},100);return}}zo(I)}function tu(){let l;return{preventBodyScroll(I){I!==l&&(l!==void 0||I===!0)&&(l=I,eu(I))}}}let dn=0;const ru={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"},Uo={standard:["scale","scale"],top:["slide-down","slide-up"],bottom:["slide-up","slide-down"],right:["slide-left","slide-right"],left:["slide-right","slide-left"]},zn=$e({name:"QDialog",inheritAttrs:!1,props:{...Vi,...Ur,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:[...qi,"shake","click","escapeKey"],setup(l,{slots:I,emit:t,attrs:b}){const m=y.getCurrentInstance(),c=y.ref(null),o=y.ref(!1),s=y.ref(!1);let n=null,e=null,r,u;const a=y.computed(()=>l.persistent!==!0&&l.noRouteDismiss!==!0&&l.seamless!==!0),{preventBodyScroll:i}=tu(),{registerTimeout:d}=Yi(),{registerTick:h,removeTick:f}=Hi(),{transitionProps:g,transitionStyle:p}=Wi(l,()=>Uo[l.position][0],()=>Uo[l.position][1]),k=y.computed(()=>p.value+(l.backdropFilter!==void 0?`;backdrop-filter:${l.backdropFilter};-webkit-backdrop-filter:${l.backdropFilter}`:"")),{showPortal:C,hidePortal:T,portalIsAccessible:j,renderPortal:q}=Ui(m,c,z,"dialog"),{hide:P}=zi({showing:o,hideOnRouteChange:a,handleShow:A,handleHide:M,processOnMount:!0});Jl(o);const N=y.computed(()=>`q-dialog__inner flex no-pointer-events q-dialog__inner--${l.maximized===!0?"maximized":"minimized"} q-dialog__inner--${l.position} ${ru[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":"")),V=y.computed(()=>o.value===!0&&l.seamless!==!0),W=y.computed(()=>l.autoClose===!0?{onClick:E}:{}),L=y.computed(()=>[`q-dialog fullscreen no-pointer-events q-dialog--${V.value===!0?"modal":"seamless"}`,b.class]);y.watch(()=>l.maximized,U=>{o.value===!0&&S(U)}),y.watch(V,U=>{i(U),U===!0?(Da(R),Fa(x)):(bi(R),An(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(_)):f(),d(()=>{if(m.proxy.$q.platform.is.ios===!0){if(l.seamless!==!0&&document.activeElement){const{top:Q,bottom:D}=document.activeElement.getBoundingClientRect(),{innerHeight:Y}=window,F=window.visualViewport!==void 0?window.visualViewport.height:Y;Q>0&&D>F/2&&(document.scrollingElement.scrollTop=Math.min(document.scrollingElement.scrollHeight-F,D>=Y?1/0:Math.ceil(document.scrollingElement.scrollTop+D-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){f(),w(!0),s.value=!0,T(),e!==null&&(((U?.type.indexOf("key")===0?e.closest('[tabindex]:not([tabindex^="-"])'):void 0)||e).focus(),e=null),d(()=>{T(!0),s.value=!1,t("hide",U)},l.transitionDuration)}function _(U){Gr(()=>{let Q=c.value;if(Q!==null){if(U!==void 0){const D=Q.querySelector(U);if(D!==null){D.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 v(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&&v():(t("escapeKey"),P()))}function w(U){n!==null&&(clearTimeout(n),n=null),(U===!0||o.value===!0)&&(S(!1),l.seamless!==!0&&(i(!1),bi(R),An(x))),U!==!0&&(e=null)}function S(U){U===!0?r!==!0&&(dn<1&&document.body.classList.add("q-body--dialog"),dn++,r=!0):r===!0&&(dn<2&&document.body.classList.remove("q-body--dialog"),dn--,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&&v()}function R(U){l.allowFocusOutside!==!0&&j.value===!0&&ga(c.value,U.target)!==!0&&_('[tabindex]:not([tabindex="-1"])')}Object.assign(m.proxy,{focus:_,shake:v,__updateRefocusTarget(U){e=U||null}}),y.onBeforeUnmount(w);function z(){return y.h("div",{role:"dialog","aria-modal":V.value===!0?"true":"false",...b,class:L.value},[y.h(y.Transition,{name:"q-transition--fade",appear:!0},()=>V.value===!0?y.h("div",{class:"q-dialog__backdrop fixed-full",style:k.value,"aria-hidden":"true",tabindex:-1,onClick:O}):null),y.h(y.Transition,g.value,()=>o.value===!0?y.h("div",{ref:c,class:N.value,style:p.value,tabindex:-1,...W.value},gt(I.default)):null)])}return q}});let In=!1;{const l=document.createElement("div");l.setAttribute("dir","rtl"),Object.assign(l.style,{width:"1px",height:"1px",overflow:"auto"});const I=document.createElement("div");Object.assign(I.style,{width:"1000px",height:"1px"}),document.body.appendChild(l),l.appendChild(I),l.scrollLeft=-1e3,In=l.scrollLeft>=0,l.remove()}const Ut=1e3,nu=["start","center","end","start-force","center-force","end-force"],za=Array.prototype.filter,iu=window.getComputedStyle(document.body).overflowAnchor===void 0?Pn:function(l,I){l!==null&&(l._qOverflowAnimationFrame!==void 0&&cancelAnimationFrame(l._qOverflowAnimationFrame),l._qOverflowAnimationFrame=requestAnimationFrame(()=>{if(l===null)return;l._qOverflowAnimationFrame=void 0;const t=l.children||[];za.call(t,m=>m.dataset&&m.dataset.qVsAnchor!==void 0).forEach(m=>{delete m.dataset.qVsAnchor});const b=t[I];b?.dataset&&(b.dataset.qVsAnchor="")}))};function Tr(l,I){return l+I}function ni(l,I,t,b,m,c,o,s){const n=l===window?document.scrollingElement||document.documentElement:l,e=m===!0?"offsetWidth":"offsetHeight",r={scrollStart:0,scrollViewSize:-o-s,scrollMaxSize:0,offsetStart:-o,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=(In===!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(I!==l){const u=n.getBoundingClientRect(),a=I.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 Wo(l,I,t,b){I==="end"&&(I=(l===window?document.body:l)[t===!0?"scrollWidth":"scrollHeight"]),l===window?t===!0?(b===!0&&(I=(In===!0?document.body.scrollWidth-document.documentElement.clientWidth:0)-I),window.scrollTo(I,window.pageYOffset||window.scrollY||document.body.scrollTop||0)):window.scrollTo(window.pageXOffset||window.scrollX||document.body.scrollLeft||0,I):t===!0?(b===!0&&(I=(In===!0?l.scrollWidth-l.offsetWidth:0)-I),l.scrollLeft=I):l.scrollTop=I}function Nr(l,I,t,b){if(t>=b)return 0;const m=I.length,c=Math.floor(t/Ut),o=Math.floor((b-1)/Ut)+1;let s=l.slice(c,o).reduce(Tr,0);return t%Ut!==0&&(s-=I.slice(c*Ut,t).reduce(Tr,0)),b%Ut!==0&&b!==m&&(s-=I.slice(b,o*Ut).reduce(Tr,0)),s}const Ua={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]},Wa=Object.keys(Ua),xi={virtualScrollHorizontal:Boolean,onVirtualScroll:Function,...Ua};function Ha({virtualScrollLength:l,getVirtualScrollTarget:I,getVirtualScrollEl:t,virtualScrollItemSizeComputed:b}){const m=y.getCurrentInstance(),{props:c,emit:o,proxy:s}=m,{$q:n}=s;let e,r,u,a=[],i;const d=y.ref(0),h=y.ref(0),f=y.ref({}),g=y.ref(null),p=y.ref(null),k=y.ref(null),C=y.ref({from:0,to:0}),T=y.computed(()=>c.tableColspan!==void 0?c.tableColspan:100);b===void 0&&(b=y.computed(()=>c.virtualScrollItemSize));const j=y.computed(()=>b.value+";"+c.virtualScrollHorizontal),q=y.computed(()=>j.value+";"+c.virtualScrollSliceRatioBefore+";"+c.virtualScrollSliceRatioAfter);y.watch(q,()=>{v()}),y.watch(j,P);function P(){_(r,!0)}function N(O){_(O===void 0?r:O)}function V(O,R){const z=I();if(z==null||z.nodeType===8)return;const U=ni(z,t(),g.value,p.value,c.virtualScrollHorizontal,n.lang.rtl,c.virtualScrollStickySizeStart,c.virtualScrollStickySizeEnd);u!==U.scrollViewSize&&v(U.scrollViewSize),L(z,U,Math.min(l.value-1,Math.max(0,parseInt(O,10)||0)),0,nu.indexOf(R)!==-1?R:r!==-1&&O>r?"end":"start")}function W(){const O=I();if(O==null||O.nodeType===8)return;const R=ni(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&&v(R.scrollViewSize),A(C.value.from);const Q=Math.floor(R.scrollMaxSize-Math.max(R.scrollViewSize,R.offsetEnd)-Math.min(i[z],R.scrollViewSize/2));if(Q>0&&Math.ceil(R.scrollStart)>=Q){L(O,R,z,R.scrollMaxSize-R.offsetEnd-a.reduce(Tr,0));return}let D=0,Y=R.scrollStart-R.offsetStart,F=Y;if(Y<=U&&Y+R.scrollViewSize>=d.value)Y-=d.value,D=C.value.from,F=Y;else for(let B=0;Y>=a[B]&&D<z;B++)Y-=a[B],D+=Ut;for(;Y>0&&D<z;)Y-=i[D],Y>-R.scrollViewSize?(D++,F=Y):F=i[D]+Y;L(O,R,D,F)}function L(O,R,z,U,Q){const D=typeof Q=="string"&&Q.indexOf("-force")!==-1,Y=D===!0?Q.replace("-force",""):Q,F=Y!==void 0?Y:"start";let B=Math.max(0,z-f.value[F]),H=B+f.value.total;H>l.value&&(H=l.value,B=Math.max(0,H-f.value.total)),e=R.scrollStart;const K=B!==C.value.from||H!==C.value.to;if(K===!1&&Y===void 0){w(z);return}const{activeElement:$}=document,G=k.value;K===!0&&G!==null&&G!==$&&G.contains($)===!0&&(G.addEventListener("focusout",M),setTimeout(()=>{G?.removeEventListener("focusout",M)})),iu(G,z-B);const ee=Y!==void 0?i.slice(B,z).reduce(Tr,0):0;if(K===!0){const ce=H>=C.value.from&&B<=C.value.to?C.value.to:H;C.value={from:B,to:ce},d.value=Nr(a,i,0,B),h.value=Nr(a,i,H,l.value),requestAnimationFrame(()=>{C.value.to!==H&&e===R.scrollStart&&(C.value={from:C.value.from,to:H},h.value=Nr(a,i,H,l.value))})}requestAnimationFrame(()=>{if(e!==R.scrollStart)return;K===!0&&A(B);const ce=i.slice(B,z).reduce(Tr,0),ue=ce+R.offsetStart+d.value,J=ue+i[z];let le=ue+U;if(Y!==void 0){const ae=ce-ee,te=R.scrollStart+ae;le=D!==!0&&te<ue&&J<te+R.scrollViewSize?te:Y==="end"?J-R.scrollViewSize:ue-(Y==="start"?0:Math.round((R.scrollViewSize-i[z])/2))}e=le,Wo(O,le,c.virtualScrollHorizontal,n.lang.rtl),w(z)})}function A(O){const R=k.value;if(R){const z=za.call(R.children,B=>B.classList&&B.classList.contains("q-virtual-scroll--skip")===!1),U=z.length,Q=c.virtualScrollHorizontal===!0?B=>B.getBoundingClientRect().width:B=>B.offsetHeight;let D=O,Y,F;for(let B=0;B<U;){for(Y=Q(z[B]),B++;B<U&&z[B].classList.contains("q-virtual-scroll--with-prev")===!0;)Y+=Q(z[B]),B++;F=Y-i[D],F!==0&&(i[D]+=F,a[Math.floor(D/Ut)]+=F),D++}}}function M(){k.value?.focus()}function _(O,R){const z=1*b.value;(R===!0||Array.isArray(i)===!1)&&(i=[]);const U=i.length;i.length=l.value;for(let D=l.value-1;D>=U;D--)i[D]=z;const Q=Math.floor((l.value-1)/Ut);a=[];for(let D=0;D<=Q;D++){let Y=0;const F=Math.min((D+1)*Ut,l.value);for(let B=D*Ut;B<F;B++)Y+=i[B];a.push(Y)}r=-1,e=void 0,d.value=Nr(a,i,0,C.value.from),h.value=Nr(a,i,C.value.to,l.value),O>=0?(A(C.value.from),y.nextTick(()=>{V(O)})):S()}function v(O){if(O===void 0&&typeof window<"u"){const Y=I();Y!=null&&Y.nodeType!==8&&(O=ni(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),D=Math.max(1,Q,Math.ceil((c.virtualScrollSliceSize>0?c.virtualScrollSliceSize:10)/U));f.value={total:Math.ceil(D*U),start:Math.ceil(D*R),center:Math.ceil(D*(.5+R)),end:Math.ceil(D*(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"?y.h(O,{class:"q-virtual-scroll__padding",key:"before",ref:g},[y.h("tr",[y.h("td",{style:{[z]:`${d.value}px`,...U},colspan:T.value})])]):y.h(O,{class:"q-virtual-scroll__padding",key:"before",ref:g,style:{[z]:`${d.value}px`,...U}}),y.h(O,{class:"q-virtual-scroll__content",key:"content",ref:k,tabindex:-1},R.flat()),O==="tbody"?y.h(O,{class:"q-virtual-scroll__padding",key:"after",ref:p},[y.h("tr",[y.h("td",{style:{[z]:`${h.value}px`,...U},colspan:T.value})])]):y.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&&o("virtualScroll",{index:O,from:C.value.from,to:C.value.to-1,direction:O<r?"decrease":"increase",ref:s}),r=O)}v();const S=Ni(W,n.platform.is.ios===!0?120:35);y.onBeforeMount(()=>{v()});let E=!1;return y.onDeactivated(()=>{E=!0}),y.onActivated(()=>{if(E!==!0)return;const O=I();e!==void 0&&O!==void 0&&O!==null&&O.nodeType!==8?Wo(O,e,c.virtualScrollHorizontal,n.lang.rtl):V(r)}),y.onBeforeUnmount(()=>{S.cancel()}),Object.assign(s,{scrollTo:V,reset:P,refresh:N}),{virtualScrollSliceRange:C,virtualScrollSliceSizeComputed:f,setVirtualScrollSize:v,onVirtualScrollEvt:S,localResetVirtualScroll:_,padVirtualScroll:x,scrollTo:V,reset:P,refresh:N}}const ou=/[\u3000-\u303f\u3040-\u309f\u30a0-\u30ff\uff00-\uff9f\u4e00-\u9faf\u3400-\u4dbf]/,au=/[\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,su=/[\u3131-\u314e\u314f-\u3163\uac00-\ud7a3]/,lu=/[a-z0-9_ -]$/i;function Ya(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?lu.test(t.data)===!1:ou.test(t.data)===!0||au.test(t.data)===!0||su.test(t.data)===!0)===!0&&(t.target.qComposing=!0)}}function rr(l,I){if(l===I)return!0;if(l!==null&&I!==null&&typeof l=="object"&&typeof I=="object"){if(l.constructor!==I.constructor)return!1;let t,b;if(l.constructor===Array){if(t=l.length,t!==I.length)return!1;for(b=t;b--!==0;)if(rr(l[b],I[b])!==!0)return!1;return!0}if(l.constructor===Map){if(l.size!==I.size)return!1;let c=l.entries();for(b=c.next();b.done!==!0;){if(I.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],I.get(b.value[0]))!==!0)return!1;b=c.next()}return!0}if(l.constructor===Set){if(l.size!==I.size)return!1;const c=l.entries();for(b=c.next();b.done!==!0;){if(I.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!==I.length)return!1;for(b=t;b--!==0;)if(l[b]!==I[b])return!1;return!0}if(l.constructor===RegExp)return l.source===I.source&&l.flags===I.flags;if(l.valueOf!==Object.prototype.valueOf)return l.valueOf()===I.valueOf();if(l.toString!==Object.prototype.toString)return l.toString()===I.toString();const m=Object.keys(l).filter(c=>l[c]!==void 0);if(t=m.length,t!==Object.keys(I).filter(c=>I[c]!==void 0).length)return!1;for(b=t;b--!==0;){const c=m[b];if(rr(l[c],I[c])!==!0)return!1}return!0}return l!==l&&I!==I}function Qa(l){return l!==null&&typeof l=="object"&&Array.isArray(l)!==!0}function On(l){return Object.prototype.toString.call(l)==="[object Date]"}function Si(l){return typeof l=="number"&&isFinite(l)}const Ho=l=>["add","add-unique","toggle"].includes(l),uu=".*+?^${}()|[]\\",cu=Object.keys(qn);function ii(l,I){if(typeof l=="function")return l;const t=l!==void 0?l:I;return b=>b!==null&&typeof b=="object"&&t in b?b[t]:b}const Un=$e({name:"QSelect",inheritAttrs:!1,props:{...xi,...Nn,...qn,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:Ho},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:xi.virtualScrollItemSize.type,onNewValue:Function,onFilter:Function},emits:[...Ki,"add","remove","inputValue","keyup","keypress","keydown","popupShow","popupHide","filterAbort"],setup(l,{slots:I,emit:t}){const{proxy:b}=y.getCurrentInstance(),{$q:m}=b,c=y.ref(!1),o=y.ref(!1),s=y.ref(-1),n=y.ref(""),e=y.ref(!1),r=y.ref(!1);let u=null,a=null,i,d,h,f=null,g,p,k,C;const T=y.ref(null),j=y.ref(null),q=y.ref(null),P=y.ref(null),N=y.ref(null),V=ya(l),W=Ya(me),L=y.computed(()=>Array.isArray(l.options)?l.options.length:0),A=y.computed(()=>l.virtualScrollItemSize===void 0?l.optionsDense===!0?24:48:l.virtualScrollItemSize),{virtualScrollSliceRange:M,virtualScrollSliceSizeComputed:_,localResetVirtualScroll:v,padVirtualScroll:x,onVirtualScrollEvt:w,scrollTo:S,setVirtualScrollSize:E}=Ha({virtualScrollLength:L,getVirtualScrollTarget:nt,getVirtualScrollEl:He,virtualScrollItemSizeComputed:A}),O=Xi(),R=y.computed(()=>{const fe=l.mapOptions===!0&&l.multiple!==!0,je=l.modelValue!==void 0&&(l.modelValue!==null||fe===!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&&i!==void 0?i:[],he=je.map(ve=>Fe(ve,Z));return l.modelValue===null&&fe===!0?he.filter(ve=>ve!==null):he}return je}),z=y.computed(()=>{const fe={};return cu.forEach(je=>{const Z=l[je];Z!==void 0&&(fe[je]=Z)}),fe}),U=y.computed(()=>l.optionsDark===null?O.isDark.value:l.optionsDark),Q=y.computed(()=>Qr(R.value)),D=y.computed(()=>{let fe="q-field__input q-placeholder col";return l.hideSelected===!0||R.value.length===0?[fe,l.inputClass]:(fe+=" q-field__input--padding",l.inputClass===void 0?fe:[fe,l.inputClass])}),Y=y.computed(()=>(l.virtualScrollHorizontal===!0?"q-virtual-scroll--horizontal":"")+(l.popupContentClass?" "+l.popupContentClass:"")),F=y.computed(()=>L.value===0),B=y.computed(()=>R.value.map(fe=>ie.value(fe)).join(", ")),H=y.computed(()=>l.displayValue!==void 0?l.displayValue:B.value),K=y.computed(()=>l.optionsHtml===!0?()=>!0:fe=>fe?.html===!0),$=y.computed(()=>l.displayValueHtml===!0||l.displayValue===void 0&&(l.optionsHtml===!0||R.value.some(K.value))),G=y.computed(()=>O.focused.value===!0?l.tabindex:-1),ee=y.computed(()=>{const fe={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&&(fe["aria-activedescendant"]=`${O.targetUid.value}_${s.value}`),fe}),ce=y.computed(()=>({id:`${O.targetUid.value}_lb`,role:"listbox","aria-multiselectable":l.multiple===!0?"true":"false"})),ue=y.computed(()=>R.value.map((fe,je)=>({index:je,opt:fe,html:K.value(fe),selected:!0,removeAtIndex:Me,toggleOption:Ve,tabindex:G.value}))),J=y.computed(()=>{if(L.value===0)return[];const{from:fe,to:je}=M.value;return l.options.slice(fe,je).map((Z,he)=>{const ve=se.value(Z)===!0,ye=ke(Z)===!0,Pe=fe+he,Se={clickable:!0,active:ye,activeClass:te.value,manualFocus:!0,focused:!1,disable:ve,tabindex:-1,dense:l.optionsDense,dark:U.value,role:"option","aria-selected":ye===!0?"true":"false",id:`${O.targetUid.value}_${Pe}`,onClick:()=>{Ve(Z)}};return ve!==!0&&(s.value===Pe&&(Se.focused=!0),m.platform.is.desktop===!0&&(Se.onMousemove=()=>{c.value===!0&&Ne(Pe)})),{index:Pe,opt:Z,html:K.value(Z),label:ie.value(Z),selected:Se.active,focused:Se.focused,toggleOption:Ve,setOptionIndex:Ne,itemProps:Se}})}),le=y.computed(()=>l.dropdownIcon!==void 0?l.dropdownIcon:m.iconSet.arrow.dropdown),ae=y.computed(()=>l.optionsCover===!1&&l.outlined!==!0&&l.standout!==!0&&l.borderless!==!0&&l.rounded!==!0),te=y.computed(()=>l.optionsSelectedClass!==void 0?l.optionsSelectedClass:l.color!==void 0?`text-${l.color}`:""),oe=y.computed(()=>ii(l.optionValue,"value")),ie=y.computed(()=>ii(l.optionLabel,"label")),se=y.computed(()=>ii(l.optionDisable,"disable")),pe=y.computed(()=>R.value.map(oe.value)),xe=y.computed(()=>{const fe={onInput:me,onChange:W,onKeydown:et,onKeyup:Le,onKeypress:Ge,onFocus:De,onClick(je){d===!0&&Dt(je)}};return fe.onCompositionstart=fe.onCompositionupdate=fe.onCompositionend=W,fe});y.watch(R,fe=>{i=fe,l.useInput===!0&&l.fillInput===!0&&l.multiple!==!0&&O.innerLoading.value!==!0&&(o.value!==!0&&c.value!==!0||Q.value!==!0)&&(h!==!0&&ze(),(o.value===!0||c.value===!0)&&Oe(""))},{immediate:!0}),y.watch(()=>l.fillInput,ze),y.watch(c,Je),y.watch(L,Ze);function Re(fe){return l.emitValue===!0?oe.value(fe):fe}function Ce(fe){if(fe!==-1&&fe<R.value.length)if(l.multiple===!0){const je=l.modelValue.slice();t("remove",{index:fe,value:je.splice(fe,1)[0]}),t("update:modelValue",je)}else t("update:modelValue",null)}function Me(fe){Ce(fe),O.focus()}function Ue(fe,je){const Z=Re(fe);if(l.multiple!==!0){l.fillInput===!0&&Te(ie.value(fe),!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(fe)===!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 Ve(fe,je){if(O.editable.value!==!0||fe===void 0||se.value(fe)===!0)return;const Z=oe.value(fe);if(l.multiple!==!0){je!==!0&&(Te(l.fillInput===!0?ie.value(fe):"",!0,!0),Be()),j.value?.focus(),(R.value.length===0||rr(oe.value(R.value[0]),Z)!==!0)&&t("update:modelValue",l.emitValue===!0?Z:fe);return}if((d!==!0||e.value===!0)&&O.focus(),De(),R.value.length===0){const ye=l.emitValue===!0?Z:fe;t("add",{index:0,value:ye}),t("update:modelValue",l.multiple===!0?[ye]:ye);return}const he=l.modelValue.slice(),ve=pe.value.findIndex(ye=>rr(ye,Z));if(ve!==-1)t("remove",{index:ve,value:he.splice(ve,1)[0]});else{if(l.maxValues!==void 0&&he.length>=l.maxValues)return;const ye=l.emitValue===!0?Z:fe;t("add",{index:he.length,value:ye}),he.push(ye)}t("update:modelValue",he)}function Ne(fe){if(m.platform.is.desktop!==!0)return;const je=fe!==-1&&fe<L.value?fe:-1;s.value!==je&&(s.value=je)}function qe(fe=1,je){if(c.value===!0){let Z=s.value;do Z=ko(Z+fe,-1,L.value-1);while(Z!==-1&&Z!==s.value&&se.value(l.options[Z])===!0);s.value!==Z&&(Ne(Z),S(Z),je!==!0&&l.useInput===!0&&l.fillInput===!0&&we(Z>=0?ie.value(l.options[Z]):g,!0))}}function Fe(fe,je){const Z=he=>rr(oe.value(he),fe);return l.options.find(Z)||je.find(Z)||fe}function ke(fe){const je=oe.value(fe);return pe.value.find(Z=>rr(Z,je))!==void 0}function De(fe){l.useInput===!0&&j.value!==null&&(fe===void 0||j.value===fe.target&&fe.target.value===B.value)&&j.value.select()}function We(fe){ir(fe,27)===!0&&c.value===!0&&(Dt(fe),Be(),ze()),t("keyup",fe)}function Le(fe){const{value:je}=fe.target;if(fe.keyCode!==void 0){We(fe);return}if(fe.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=ye=>{const Pe=l.options.find(Se=>String(ye.value(Se)).toLocaleLowerCase()===Z);return Pe===void 0?!1:(R.value.indexOf(Pe)===-1?Ve(Pe):Be(),!0)},ve=ye=>{he(oe)!==!0&&ye!==!0&&he(ie)!==!0&&Oe(je,!0,()=>ve(!0))};ve()}else O.clearValue(fe)}function Ge(fe){t("keypress",fe)}function et(fe){if(t("keydown",fe),Fi(fe)===!0)return;const je=n.value.length!==0&&(l.newValueMode!==void 0||l.onNewValue!==void 0),Z=fe.shiftKey!==!0&&l.disableTabSelection!==!0&&l.multiple!==!0&&(s.value!==-1||je===!0);if(fe.keyCode===27){Bt(fe);return}if(fe.keyCode===9&&Z===!1){be();return}if(fe.target===void 0||fe.target.id!==O.targetUid.value||O.editable.value!==!0)return;if(fe.keyCode===40&&O.innerLoading.value!==!0&&c.value===!1){St(fe),_e();return}if(fe.keyCode===8&&(l.useChips===!0||l.clearable===!0)&&l.hideSelected!==!0&&n.value.length===0){l.multiple===!0&&Array.isArray(l.modelValue)===!0?Ce(l.modelValue.length-1):l.multiple!==!0&&l.modelValue!==null&&t("update:modelValue",null);return}(fe.keyCode===35||fe.keyCode===36)&&(typeof n.value!="string"||n.value.length===0)&&(St(fe),s.value=-1,qe(fe.keyCode===36?1:-1,l.multiple)),(fe.keyCode===33||fe.keyCode===34)&&_.value!==void 0&&(St(fe),s.value=Math.max(-1,Math.min(L.value,s.value+(fe.keyCode===33?-1:1)*_.value.view)),qe(fe.keyCode===33?1:-1,l.multiple)),(fe.keyCode===38||fe.keyCode===40)&&(St(fe),qe(fe.keyCode===38?-1:1,l.multiple));const he=L.value;if((k===void 0||C<Date.now())&&(k=""),he>0&&l.useInput!==!0&&fe.key!==void 0&&fe.key.length===1&&fe.altKey===!1&&fe.ctrlKey===!1&&fe.metaKey===!1&&(fe.keyCode!==32||k.length!==0)){c.value!==!0&&_e(fe);const ve=fe.key.toLocaleLowerCase(),ye=k.length===1&&k[0]===ve;C=Date.now()+1500,ye===!1&&(St(fe),k+=ve);const Pe=new RegExp("^"+k.split("").map(Ie=>uu.indexOf(Ie)!==-1?"\\"+Ie:Ie).join(".*"),"i");let Se=s.value;if(ye===!0||Se<0||Pe.test(ie.value(l.options[Se]))!==!0)do Se=ko(Se+1,-1,he-1);while(Se!==s.value&&(se.value(l.options[Se])===!0||Pe.test(ie.value(l.options[Se]))!==!0));s.value!==Se&&y.nextTick(()=>{Ne(Se),S(Se),Se>=0&&l.useInput===!0&&l.fillInput===!0&&we(ie.value(l.options[Se]),!0)});return}if(!(fe.keyCode!==13&&(fe.keyCode!==32||l.useInput===!0||k!=="")&&(fe.keyCode!==9||Z===!1))){if(fe.keyCode!==9&&St(fe),s.value!==-1&&s.value<he){Ve(l.options[s.value]);return}if(je===!0){const ve=(ye,Pe)=>{if(Pe){if(Ho(Pe)!==!0)return}else Pe=l.newValueMode;if(Te("",l.multiple!==!0,!0),ye==null)return;(Pe==="toggle"?Ve:Ue)(ye,Pe==="add-unique"),l.multiple!==!0&&(j.value?.focus(),Be())};if(l.onNewValue!==void 0?t("newValue",n.value,ve):ve(n.value),l.multiple!==!0)return}c.value===!0?be():O.innerLoading.value!==!0&&_e()}}function He(){return d===!0?N.value:q.value!==null&&q.value.contentEl!==null?q.value.contentEl:void 0}function nt(){return He()}function tt(){return l.hideSelected===!0?[]:I["selected-item"]!==void 0?ue.value.map(fe=>I["selected-item"](fe)).slice():I.selected!==void 0?[].concat(I.selected()):l.useChips===!0?ue.value.map((fe,je)=>y.h(qa,{key:"option-"+je,removable:O.editable.value===!0&&se.value(fe.opt)!==!0,dense:!0,textColor:l.color,tabindex:G.value,onRemove(){fe.removeAtIndex(je)}},()=>y.h("span",{class:"ellipsis",[fe.html===!0?"innerHTML":"textContent"]:ie.value(fe.opt)}))):[y.h("span",{class:"ellipsis",[$.value===!0?"innerHTML":"textContent"]:H.value})]}function Ye(){if(F.value===!0)return I["no-option"]!==void 0?I["no-option"]({inputValue:n.value}):void 0;const fe=I.option!==void 0?I.option:Z=>y.h(Cr,{key:Z.index,...Z.itemProps},()=>y.h(Ar,()=>y.h(wi,()=>y.h("span",{[Z.html===!0?"innerHTML":"textContent"]:Z.label}))));let je=x("div",J.value.map(fe));return I["before-options"]!==void 0&&(je=I["before-options"]().concat(je)),It(I["after-options"],je)}function at(fe,je){const Z=je===!0?{...ee.value,...O.splitAttrs.attributes.value}:void 0,he={ref:je===!0?j:void 0,key:"i_t",class:D.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":fe===!0||l.autofocus===!0||void 0,disabled:l.disable===!0,readonly:l.readonly===!0,...xe.value};return fe!==!0&&d===!0&&(Array.isArray(he.class)===!0?he.class=[...he.class,"no-pointer-events"]:he.class+=" no-pointer-events"),y.h("input",he)}function me(fe){u!==null&&(clearTimeout(u),u=null),a!==null&&(clearTimeout(a),a=null),!(fe&&fe.target&&fe.target.qComposing===!0)&&(we(fe.target.value||""),h=!0,g=n.value,O.focused.value!==!0&&(d!==!0||e.value===!0)&&O.focus(),l.onFilter!==void 0&&(u=setTimeout(()=>{u=null,Oe(n.value)},l.inputDebounce)))}function we(fe,je){n.value!==fe&&(n.value=fe,je===!0||l.inputDebounce===0||l.inputDebounce==="0"?t("inputValue",fe):a=setTimeout(()=>{a=null,t("inputValue",fe)},l.inputDebounce))}function Te(fe,je,Z){h=Z!==!0,l.useInput===!0&&(we(fe,!0),(je===!0||Z!==!0)&&(g=fe),je!==!0&&Oe(fe))}function Oe(fe,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),fe!==""&&l.multiple!==!0&&R.value.length!==0&&h!==!0&&fe===ie.value(R.value[0])&&(fe="");const he=setTimeout(()=>{c.value===!0&&(c.value=!1)},10);f!==null&&clearTimeout(f),f=he,t("filter",fe,(ve,ye)=>{(je===!0||O.focused.value===!0)&&f===he&&(clearTimeout(f),typeof ve=="function"&&ve(),r.value=!1,y.nextTick(()=>{O.innerLoading.value=!1,O.editable.value===!0&&(je===!0?c.value===!0&&Be():c.value===!0?Je(!0):c.value=!0),typeof ye=="function"&&y.nextTick(()=>{ye(b)}),typeof Z=="function"&&y.nextTick(()=>{Z(b)})}))},()=>{O.focused.value===!0&&f===he&&(clearTimeout(f),O.innerLoading.value=!1,r.value=!1),c.value===!0&&(c.value=!1)})}function Ae(){return y.h(Jr,{ref:q,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:ae.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(fe){ft(fe),be()}function Ke(){E()}function re(fe){Dt(fe),j.value?.focus(),e.value=!0,window.scrollTo(window.pageXOffset||window.scrollX||document.body.scrollLeft||0,0)}function X(fe){Dt(fe),y.nextTick(()=>{e.value=!1})}function ne(){const fe=[y.h(Xl,{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},{...I,rawControl:()=>O.getControl(!0),before:void 0,after:void 0})];return c.value===!0&&fe.push(y.h("div",{ref:N,class:Y.value+" scroll",style:l.popupContentStyle,...ce.value,onClick:Bt,onScrollPassive:w},Ye())),y.h(zn,{ref:P,modelValue:o.value,position:l.useInput===!0?"top":void 0,transitionShow:p,transitionHide:l.transitionHide,transitionDuration:l.transitionDuration,noRouteDismiss:l.popupNoRouteDismiss,onBeforeShow:yt,onBeforeHide:de,onHide:ge,onShow:Ee},()=>y.h("div",{class:"q-select__dialog"+(U.value===!0?" q-select__dialog--dark q-dark":"")+(e.value===!0?" q-select__dialog--focused":"")},fe))}function de(fe){ft(fe),P.value!==null&&P.value.__updateRefocusTarget(O.rootRef.value.querySelector(".q-field__native > [tabindex]:last-child")),O.focused.value=!1}function ge(fe){Be(),O.focused.value===!1&&t("blur",fe),ze()}function Ee(){const fe=document.activeElement;(fe===null||fe.id!==O.targetUid.value)&&j.value!==null&&j.value!==fe&&j.value.focus(),E()}function be(){o.value!==!0&&(s.value=-1,c.value===!0&&(c.value=!1),O.focused.value===!1&&(f!==null&&(clearTimeout(f),f=null),O.innerLoading.value===!0&&(t("filterAbort"),O.innerLoading.value=!1,r.value=!1)))}function _e(fe){O.editable.value===!0&&(d===!0?(O.onControlFocusin(fe),o.value=!0,y.nextTick(()=>{O.focus()})):O.focus(),l.onFilter!==void 0?Oe(n.value):(F.value!==!0||I["no-option"]!==void 0)&&(c.value=!0))}function Be(){o.value=!1,be()}function ze(){l.useInput===!0&&Te(l.multiple!==!0&&l.fillInput===!0&&R.value.length!==0&&ie.value(R.value[0])||"",!0,!0)}function Je(fe){let je=-1;if(fe===!0){if(R.value.length!==0){const Z=oe.value(R.value[0]);je=l.options.findIndex(he=>rr(oe.value(he),Z))}v(je)}Ne(je)}function Ze(fe,je){c.value===!0&&O.innerLoading.value===!1&&(v(-1,!0),y.nextTick(()=>{c.value===!0&&O.innerLoading.value===!1&&(fe>je?v():Je(!0))}))}function rt(){o.value===!1&&q.value!==null&&q.value.updatePosition()}function yt(fe){fe!==void 0&&Dt(fe),t("popupShow",fe),O.hasPopupOpen=!0,O.onControlFocusin(fe)}function ft(fe){fe!==void 0&&Dt(fe),t("popupHide",fe),O.hasPopupOpen=!1,O.onControlFocusout(fe)}function kt(){d=m.platform.is.mobile!==!0&&l.behavior!=="dialog"?!1:l.behavior!=="menu"&&(l.useInput===!0?I["no-option"]!==void 0||l.onFilter!==void 0||F.value===!1:!0),p=m.platform.is.ios===!0&&d===!0&&l.useInput===!0?"fade":l.transitionShow}return y.onBeforeUpdate(kt),y.onUpdated(rt),kt(),y.onBeforeUnmount(()=>{u!==null&&clearTimeout(u),a!==null&&clearTimeout(a)}),Object.assign(b,{showPopup:_e,hidePopup:Be,removeAtIndex:Ce,add:Ue,toggleOption:Ve,getOptionIndex:()=>s.value,setOptionIndex:Ne,moveOptionSelection:qe,filter:Oe,updateMenuPosition:rt,updateInputValue:Te,isOptionSelected:ke,getEmittingOptionValue:Re,isOptionDisabled:(...fe)=>se.value.apply(null,fe)===!0,getOptionValue:(...fe)=>oe.value.apply(null,fe),getOptionLabel:(...fe)=>ie.value.apply(null,fe)}),Object.assign(O,{innerValue:R,fieldClass:y.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:j,hasValue:Q,showPopup:_e,floatingLabel:y.computed(()=>l.hideSelected!==!0&&Q.value===!0||typeof n.value=="number"||n.value.length!==0||Qr(l.displayValue)),getControlChild:()=>{if(O.editable.value!==!1&&(o.value===!0||F.value!==!0||I["no-option"]!==void 0))return d===!0?ne():Ae();O.hasPopupOpen===!0&&(O.hasPopupOpen=!1)},controlEvents:{onFocusin(fe){O.onControlFocusin(fe)},onFocusout(fe){O.onControlFocusout(fe,()=>{ze(),be()})},onClick(fe){if(Bt(fe),d!==!0&&c.value===!0){be(),j.value?.focus();return}_e(fe)}},getControl:fe=>{const je=tt(),Z=fe===!0||o.value!==!0||d!==!0;if(l.useInput===!0)je.push(at(fe,Z));else if(O.editable.value===!0){const ve=Z===!0?ee.value:void 0;je.push(y.h("input",{ref:Z===!0?j: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":fe===!0||l.autofocus===!0||void 0,...ve,onKeydown:et,onKeyup:We,onKeypress:Ge})),Z===!0&&typeof l.autocomplete=="string"&&l.autocomplete.length!==0&&je.push(y.h("input",{class:"q-select__autocomplete-input",autocomplete:l.autocomplete,tabindex:-1,onKeyup:Le}))}if(V.value!==void 0&&l.disable!==!0&&pe.value.length!==0){const ve=pe.value.map(ye=>y.h("option",{value:ye,selected:!0}));je.push(y.h("select",{class:"hidden",name:V.value,multiple:l.multiple},ve))}const he=l.useInput===!0||Z!==!0?void 0:O.splitAttrs.attributes.value;return y.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?[y.h(bt,{class:"q-select__dropdown-icon"+(c.value===!0?" rotate-180":""),name:le.value})]:null}),Gi(O)}}),fu={class:"q-pa-none"},du=y.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:I}){const t=l,b=I,m=y.ref(!1),c=y.ref(t.modelValue||[]),o=y.computed(()=>({height:t.scrollAreaHeight,width:t.scrollAreaWidth})),s=y.computed(()=>t.dataCy||"checkbox-filter");return y.watch(c,n=>{b("update:modelValue",n)}),y.watch(()=>t.modelValue,n=>{n&&(c.value=n)},{immediate:!0}),(n,e)=>(y.openBlock(),y.createElementBlock("div",fu,[y.createVNode(Un,y.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:y.withCtx(()=>[y.createVNode(bt,{name:"arrow_drop_down",class:y.normalizeClass(["cursor-pointer smooth-rotate",{"rotate-180":m.value}])},null,8,["class"])]),default:y.withCtx(()=>[y.createVNode(Jr,{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:y.withCtx(()=>[y.createVNode(Xr,{class:"q-pa-sm"},{default:y.withCtx(()=>[y.createVNode(Sl,{style:y.normalizeStyle(o.value)},{default:y.withCtx(()=>[(y.openBlock(!0),y.createElementBlock(y.Fragment,null,y.renderList(t.options,r=>(y.openBlock(),y.createBlock(Er,{key:r.value,modelValue:c.value,"onUpdate:modelValue":e[0]||(e[0]=u=>c.value=u),val:r,label:r.label,disable:r.disabled,color:"primary",class:"q-mb-sm q-ml-sm q-mr-sm","data-cy":`${s.value}-option-${r.label}`},null,8,["modelValue","val","label","disable","data-cy"]))),128))]),_:1},8,["style"])]),_:1})]),_:1},8,["modelValue"])]),_:1},16,["label","data-cy"])]))}}),hu=Xt(du,[["__scopeId","data-v-0e12eb7b"]]),pu=y.defineComponent({__name:"SelectSearch",props:{options:{default:()=>[]},fetchOptions:{},label:{default:"Selectionner un option"},modelValue:{default:null}},emits:["update:modelValue"],setup(l,{emit:I}){const t=l,b=I,m=y.ref(),c=y.ref(t.modelValue??null),o=y.ref(""),s=y.ref(t.options??[]),n=y.ref(!1),e=y.ref(!0);y.watch(()=>t.options,f=>{s.value=f??[],r()},{immediate:!0}),y.watch(()=>t.modelValue,f=>{c.value=f,r(),n.value=!1});function r(){const f=s.value.find(g=>g.value===c.value);o.value=f?.label??""}function u(f){c.value=f,b("update:modelValue",f),r(),n.value=!1}function a(f){o.value=f,f===""&&(n.value=!0)}function i(){if(e.value){e.value=!1;return}c.value!==null&&!n.value?(o.value="",n.value=!0,m.value?.showPopup()):n.value&&(o.value="")}function d(){e.value=!0;const f=o.value.trim();if(f==="")n.value&&(c.value=null,b("update:modelValue",null));else{const g=s.value.find(p=>p.label.toLowerCase()===f.toLowerCase());g?(c.value=g.value,b("update:modelValue",g.value),o.value=g.label):r()}n.value=!1}function h(f,g,p){if(t.fetchOptions)t.fetchOptions(f).then(k=>{s.value=k,g(()=>{})}).catch(p).finally(()=>{});else{const k=t.options??[];s.value=k.filter(C=>C.label.toLowerCase().includes(f.toLowerCase())),g(()=>{})}}return(f,g)=>(y.openBlock(),y.createBlock(Un,y.mergeProps({ref_key:"selectRef",ref:m,"model-value":c.value,"input-value":o.value,"use-input":"","fill-input":"","hide-selected":"","input-debounce":"300",label:f.label,options:s.value,dense:"",outlined:"",class:"full-width cursor-pointer"},f.$attrs,{"onUpdate:modelValue":u,"onUpdate:inputValue":a,onFocus:i,onBlur:d,onFilter:h}),null,16,["model-value","input-value","label","options"]))}}),mu=y.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:I}){const t=l,b=I,m=y.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 o(){t.modelValue!==null&&b("update:modelValue",null)}return(s,n)=>(y.openBlock(),y.createBlock(Un,y.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:o}),null,16,["model-value","options","label"]))}}),Ka=$e({name:"QAvatar",props:{...Or,fontSize:String,color:String,textColor:String,icon:String,square:Boolean,rounded:Boolean},setup(l,{slots:I}){const t=Fr(l),b=y.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=y.computed(()=>l.fontSize?{fontSize:l.fontSize}:null);return()=>{const c=l.icon!==void 0?[y.h(bt,{name:l.icon})]:void 0;return y.h("div",{class:b.value,style:t.value},[y.h("div",{class:"q-avatar__content row flex-center overflow-hidden",style:m.value},sa(I.default,c))])}}}),gu=$e({name:"QSpace",setup(){const l=y.h("div",{class:"q-space"});return()=>l}}),bu=["ul","ol"],Ji=$e({name:"QList",props:{...Ot,bordered:Boolean,dense:Boolean,separator:Boolean,padding:Boolean,tag:{type:String,default:"div"}},setup(l,{slots:I}){const t=y.getCurrentInstance(),b=Ft(l,t.proxy.$q),m=y.computed(()=>bu.includes(l.tag)?null:"list"),c=y.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()=>y.h(l.tag,{class:c.value,role:m.value},gt(I.default))}}),Xa=$e({name:"QToolbar",props:{inset:Boolean},setup(l,{slots:I}){const t=y.computed(()=>"q-toolbar row no-wrap items-center"+(l.inset===!0?" q-toolbar--inset":""));return()=>y.h("div",{class:t.value,role:"toolbar"},gt(I.default))}}),vu=$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:I,emit:t}){const{proxy:{$q:b}}=y.getCurrentInstance(),m=y.inject(Zr,Rt);if(m===Rt)return console.error("QHeader needs to be child of QLayout"),Rt;const c=y.ref(parseInt(l.heightHint,10)),o=y.ref(!0),s=y.computed(()=>l.reveal===!0||m.view.value.indexOf("H")!==-1||b.platform.is.ios&&m.isContainer.value===!0),n=y.computed(()=>{if(l.modelValue!==!0)return 0;if(s.value===!0)return o.value===!0?c.value:0;const p=c.value-m.scroll.value.position;return p>0?p:0}),e=y.computed(()=>l.modelValue!==!0||s.value===!0&&o.value!==!0),r=y.computed(()=>l.modelValue===!0&&e.value===!0&&l.reveal===!0),u=y.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=y.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 i(p,k){m.update("header",p,k)}function d(p,k){p.value!==k&&(p.value=k)}function h({height:p}){d(c,p),i("size",p)}function f(p){r.value===!0&&d(o,!0),t("focusin",p)}y.watch(()=>l.modelValue,p=>{i("space",p),d(o,!0),m.animate()}),y.watch(n,p=>{i("offset",p)}),y.watch(()=>l.reveal,p=>{p===!1&&d(o,l.modelValue)}),y.watch(o,p=>{m.animate(),t("reveal",p)}),y.watch(m.scroll,p=>{l.reveal===!0&&d(o,p.direction==="up"||p.position<=l.revealOffset||p.position-p.inflectionPoint<100)});const g={};return m.instances.header=g,l.modelValue===!0&&i("size",c.value),i("space",l.modelValue),i("offset",n.value),y.onBeforeUnmount(()=>{m.instances.header===g&&(m.instances.header=void 0,i("size",0),i("offset",0),i("space",!1))}),()=>{const p=Mi(I.default,[]);return l.elevated===!0&&p.push(y.h("div",{class:"q-layout__shadow absolute-full overflow-hidden no-pointer-events"})),p.push(y.h(Rr,{debounce:0,onResize:h})),y.h("header",{class:u.value,style:a.value,onFocusin:f},p)}}});function Yo(l){if(l===!1)return 0;if(l===!0||l===void 0)return 1;const I=parseInt(l,10);return isNaN(I)?0:I}const Ga=Ei({name:"close-popup",beforeMount(l,{value:I}){const t={depth:Yo(I),handler(b){t.depth!==0&&setTimeout(()=>{const m=Tl(l);m!==void 0&&Rl(m,b,t.depth)})},handlerKey(b){ir(b,13)===!0&&t.handler(b)}};l.__qclosepopup=t,l.addEventListener("click",t.handler),l.addEventListener("keyup",t.handlerKey)},updated(l,{value:I,oldValue:t}){I!==t&&(l.__qclosepopup.depth=Yo(I))},beforeUnmount(l){const I=l.__qclosepopup;l.removeEventListener("click",I.handler),l.removeEventListener("keyup",I.handlerKey),delete l.__qclosepopup}}),yu=["src","alt"],wu={key:0,class:"project-environment-container row items-center q-mr-md"},xu=y.defineComponent({__name:"SelfeeHeader",props:{logoSrc:{},logoAlt:{},logoTo:{},showProjectSwitch:{type:Boolean},currentProjectLabel:{},availableProjects:{},currentPath:{},environment:{}},emits:["project-change"],setup(l,{emit:I}){const t=l,b=t.logoAlt??"Logo",m=t.logoTo??"/",c=y.computed(()=>({width:"260px",height:"auto",borderRadius:"0"})),o=y.computed(()=>t.environment?t.environment.toUpperCase()!=="PROD":!1),s=y.computed(()=>`environment-badge--${t.environment?.toUpperCase()?.toLowerCase()}`),n=e=>t.currentPath?.startsWith(e);return(e,r)=>{const u=y.resolveComponent("router-link");return y.openBlock(),y.createBlock(vu,y.mergeProps({elevated:""},e.$attrs),{default:y.withCtx(()=>[y.createVNode(Xa,null,{default:y.withCtx(()=>[y.createVNode(u,{to:y.unref(m),class:"q-mr-lg"},{default:y.withCtx(()=>[y.createVNode(Ka,{class:"logo",style:y.normalizeStyle(c.value),"data-testid":"header-logo"},{default:y.withCtx(()=>[y.createElementVNode("img",{src:e.logoSrc,alt:y.unref(b)},null,8,yu)]),_:1},8,["style"])]),_:1},8,["to"]),y.createVNode(gu),e.showProjectSwitch||o.value?(y.openBlock(),y.createElementBlock("div",wu,[o.value?(y.openBlock(),y.createElementBlock("div",{key:0,class:y.normalizeClass(["environment-badge",s.value]),"data-testid":"environment-badge"},y.toDisplayString(e.environment),3)):y.createCommentVNode("",!0),e.showProjectSwitch?(y.openBlock(),y.createBlock(ct,{key:1,dense:"",unelevated:"",color:"primary",label:e.currentProjectLabel,"data-testid":"project-switch-btn",class:"project-switch-btn q-mr-md bg-info"},{default:y.withCtx(()=>[y.createVNode(Jr,{anchor:"bottom right",self:"top right"},{default:y.withCtx(()=>[y.createVNode(Ji,{dense:"",class:"project-menu"},{default:y.withCtx(()=>[(y.openBlock(!0),y.createElementBlock(y.Fragment,null,y.renderList(e.availableProjects,a=>y.withDirectives((y.openBlock(),y.createBlock(Cr,{key:a.path,clickable:"",disable:n(a.path),onClick:i=>e.$emit("project-change",a.path)},{default:y.withCtx(()=>[y.createVNode(Ar,{class:"q-mr-lg"},{default:y.withCtx(()=>[y.createVNode(wi,null,{default:y.withCtx(()=>[y.createTextVNode(y.toDisplayString(a.label),1)]),_:2},1024),n(a.path)?(y.openBlock(),y.createBlock(wi,{key:0,caption:""},{default:y.withCtx(()=>r[0]||(r[0]=[y.createTextVNode(" Actuel ")])),_:1,__:[0]})):y.createCommentVNode("",!0)]),_:2},1024)]),_:2},1032,["disable","onClick"])),[[Ga]])),128))]),_:1})]),_:1})]),_:1},8,["label"])):y.createCommentVNode("",!0)])):y.createCommentVNode("",!0),y.renderSlot(e.$slots,"user-avatar",{},void 0,!0)]),_:3})]),_:3},16)}}}),Su=Xt(xu,[["__scopeId","data-v-a4df46a4"]]),ku=$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:I,emit:t}){const{proxy:{$q:b}}=y.getCurrentInstance(),m=y.inject(Zr,Rt);if(m===Rt)return console.error("QFooter needs to be child of QLayout"),Rt;const c=y.ref(parseInt(l.heightHint,10)),o=y.ref(!0),s=y.ref(or.value===!0||m.isContainer.value===!0?0:window.innerHeight),n=y.computed(()=>l.reveal===!0||m.view.value.indexOf("F")!==-1||b.platform.is.ios&&m.isContainer.value===!0),e=y.computed(()=>m.isContainer.value===!0?m.containerHeight.value:s.value),r=y.computed(()=>{if(l.modelValue!==!0)return 0;if(n.value===!0)return o.value===!0?c.value:0;const T=m.scroll.value.position+e.value+c.value-m.height.value;return T>0?T:0}),u=y.computed(()=>l.modelValue!==!0||n.value===!0&&o.value!==!0),a=y.computed(()=>l.modelValue===!0&&u.value===!0&&l.reveal===!0),i=y.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":""):"")),d=y.computed(()=>{const T=m.rows.value.bottom,j={};return T[0]==="l"&&m.left.space===!0&&(j[b.lang.rtl===!0?"right":"left"]=`${m.left.size}px`),T[2]==="r"&&m.right.space===!0&&(j[b.lang.rtl===!0?"left":"right"]=`${m.right.size}px`),j});function h(T,j){m.update("footer",T,j)}function f(T,j){T.value!==j&&(T.value=j)}function g({height:T}){f(c,T),h("size",T)}function p(){if(l.reveal!==!0)return;const{direction:T,position:j,inflectionPoint:q}=m.scroll.value;f(o,T==="up"||j-q<100||m.height.value-e.value-j-c.value<300)}function k(T){a.value===!0&&f(o,!0),t("focusin",T)}y.watch(()=>l.modelValue,T=>{h("space",T),f(o,!0),m.animate()}),y.watch(r,T=>{h("offset",T)}),y.watch(()=>l.reveal,T=>{T===!1&&f(o,l.modelValue)}),y.watch(o,T=>{m.animate(),t("reveal",T)}),y.watch([c,m.scroll,m.height],p),y.watch(()=>b.screen.height,T=>{m.isContainer.value!==!0&&f(s,T)});const C={};return m.instances.footer=C,l.modelValue===!0&&h("size",c.value),h("space",l.modelValue),h("offset",r.value),y.onBeforeUnmount(()=>{m.instances.footer===C&&(m.instances.footer=void 0,h("size",0),h("offset",0),h("space",!1))}),()=>{const T=It(I.default,[y.h(Rr,{debounce:0,onResize:g})]);return l.elevated===!0&&T.push(y.h("div",{class:"q-layout__shadow absolute-full overflow-hidden no-pointer-events"})),y.h("footer",{class:i.value,style:d.value,onFocusin:k},T)}}}),_u={class:"row justify-between"},Cu={class:"col-3 q-py-md flex justify-center"},Au={class:"col-3 q-py-md flex justify-center"},Eu={class:"col-3 q-py-md flex justify-center"},Mu=y.defineComponent({__name:"SelfeeFooter",props:{frontVersion:{},backVersion:{},platform:{}},setup(l){return(I,t)=>(y.openBlock(),y.createBlock(ku,y.mergeProps({elevated:""},I.$attrs),{default:y.withCtx(()=>[y.createElementVNode("div",_u,[y.createElementVNode("div",Cu," Front: "+y.toDisplayString(I.frontVersion),1),y.createElementVNode("div",Au," Back: "+y.toDisplayString(I.backVersion),1),y.createElementVNode("div",Eu," Platform: "+y.toDisplayString(I.platform),1)])]),_:1},16))}}),Tu={true:"inset",item:"item-inset","item-thumbnail":"item-thumbnail-inset"},oi={xs:2,sm:4,md:8,lg:16,xl:24},Wr=$e({name:"QSeparator",props:{...Ot,spaced:[Boolean,String],inset:[Boolean,String],vertical:Boolean,color:String,size:String},setup(l){const I=y.getCurrentInstance(),t=Ft(l,I.proxy.$q),b=y.computed(()=>l.vertical===!0?"vertical":"horizontal"),m=y.computed(()=>` q-separator--${b.value}`),c=y.computed(()=>l.inset!==!1?`${m.value}-${Tu[l.inset]}`:""),o=y.computed(()=>`q-separator${m.value}${c.value}`+(l.color!==void 0?` bg-${l.color}`:"")+(t.value===!0?" q-separator--dark":"")),s=y.computed(()=>{const n={};if(l.size!==void 0&&(n[l.vertical===!0?"width":"height"]=l.size),l.spaced!==!1){const e=l.spaced===!0?`${oi.md}px`:l.spaced in oi?`${oi[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()=>y.h("hr",{class:o.value,style:s.value,"aria-orientation":b.value})}}),Ru=$e({name:"QToggle",props:{...wa,icon:String,iconColor:String},emits:xa,setup(l){function I(t,b){const m=y.computed(()=>(t.value===!0?l.checkedIcon:b.value===!0?l.indeterminateIcon:l.uncheckedIcon)||l.icon),c=y.computed(()=>t.value===!0?l.iconColor:null);return()=>[y.h("div",{class:"q-toggle__track"}),y.h("div",{class:"q-toggle__thumb absolute flex flex-center no-wrap"},m.value!==void 0?[y.h(bt,{name:m.value,color:c.value})]:void 0)]}return Sa("toggle",I)}}),Bu={class:"text-h6 text-primary","data-testid":"avatar-initial"},Iu={class:"text-weight-bold"},Ou={class:"row items-center q-gutter-sm"},Fu={class:"version-info"},ju={class:"text-caption"},Du={class:"text-caption"},Pu={class:"text-caption"},Nu=y.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:I}){const t=l,b=y.computed(()=>t.username?.charAt(0).toUpperCase()??"");return(m,c)=>(y.openBlock(),y.createElementBlock("div",null,[y.createVNode(Ka,{class:"cursor-pointer",size:"40px",color:"white","data-cy":"cy-avatar","data-testid":"cy-avatar"},{default:y.withCtx(()=>[y.createElementVNode("span",Bu,y.toDisplayString(b.value),1),y.createVNode(Jr,{"transition-show":"flip-right","transition-hide":"flip-left",class:"user-avatar-menu"},{default:y.withCtx(()=>[y.createVNode(Ji,{class:"user-menu-list"},{default:y.withCtx(()=>[y.createVNode(Cr,{class:"user-info-section"},{default:y.withCtx(()=>[y.createVNode(Ar,null,{default:y.withCtx(()=>[y.createElementVNode("div",Iu,y.toDisplayString(m.username),1)]),_:1})]),_:1}),y.createVNode(Wr),m.showFilterToggle?(y.openBlock(),y.createBlock(Cr,{key:0,class:"filter-toggle-section"},{default:y.withCtx(()=>[y.createVNode(Ar,null,{default:y.withCtx(()=>[y.createElementVNode("div",Ou,[c[1]||(c[1]=y.createElementVNode("span",{class:"text-caption"},"Filtres persistants",-1)),y.createVNode(Ru,{"model-value":m.persistFilters,"onUpdate:modelValue":c[0]||(c[0]=o=>m.$emit("toggle-filter-persistence",o)),size:"sm","data-cy":"filter-persistence-toggle"},null,8,["model-value"])])]),_:1})]),_:1})):y.createCommentVNode("",!0),m.showFilterToggle?(y.openBlock(),y.createBlock(Wr,{key:1})):y.createCommentVNode("",!0),m.showVersionInfo?(y.openBlock(),y.createBlock(Cr,{key:2,class:"version-info-section"},{default:y.withCtx(()=>[y.createVNode(Ar,null,{default:y.withCtx(()=>[y.createElementVNode("div",Fu,[c[2]||(c[2]=y.createElementVNode("div",{class:"text-caption text-grey-7"},"Informations de version",-1)),y.createElementVNode("div",ju,"Front: "+y.toDisplayString(m.frontVersion),1),y.createElementVNode("div",Du,"Back: "+y.toDisplayString(m.backVersion),1),y.createElementVNode("div",Pu,"Plateforme: "+y.toDisplayString(m.platform),1)])]),_:1})]),_:1})):y.createCommentVNode("",!0),m.showVersionInfo?(y.openBlock(),y.createBlock(Wr,{key:3})):y.createCommentVNode("",!0),y.createVNode(Cr,{clickable:"",class:"logout-section","data-cy":"cy-logout-button","data-testid":"cy-logout-button",onClick:m.onLogout},{default:y.withCtx(()=>[y.createVNode(Ar,null,{default:y.withCtx(()=>[y.createElementVNode("div",null,y.toDisplayString(m.logoutLabel),1)]),_:1})]),_:1},8,["onClick"])]),_:1})]),_:1})]),_:1})]))}}),Lu=Xt(Nu,[["__scopeId","data-v-d9b256cf"]]),Vu=$e({name:"QPageContainer",setup(l,{slots:I}){const{proxy:{$q:t}}=y.getCurrentInstance(),b=y.inject(Zr,Rt);if(b===Rt)return console.error("QPageContainer needs to be child of QLayout"),Rt;y.provide(La,!0);const m=y.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()=>y.h("div",{class:"q-page-container",style:m.value},gt(I.default))}}),qu=$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:I,emit:t}){const{proxy:{$q:b}}=y.getCurrentInstance(),m=y.ref(null),c=y.ref(b.screen.height),o=y.ref(l.container===!0?0:b.screen.width),s=y.ref({position:0,direction:"down",inflectionPoint:0}),n=y.ref(0),e=y.ref(or.value===!0?0:xn()),r=y.computed(()=>"q-layout q-layout--"+(l.container===!0?"containerized":"standard")),u=y.computed(()=>l.container===!1?{minHeight:b.screen.height+"px"}:null),a=y.computed(()=>e.value!==0?{[b.lang.rtl===!0?"left":"right"]:`${e.value}px`}:null),i=y.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 d(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:j}=C;let q=!1;c.value!==T&&(q=!0,c.value=T,l.onScrollHeight!==void 0&&t("scrollHeight",T),g()),o.value!==j&&(q=!0,o.value=j),q===!0&&l.onResize!==void 0&&t("resize",C)}function f({height:C}){n.value!==C&&(n.value=C,g())}function g(){if(l.container===!0){const C=c.value>n.value?xn():0;e.value!==C&&(e.value=C)}}let p=null;const k={instances:{},view:y.computed(()=>l.view),isContainer:y.computed(()=>l.container),rootRef:m,height:c,containerHeight:n,scrollbarWidth:e,totalWidth:y.computed(()=>o.value+e.value),rows:y.computed(()=>{const C=l.view.toLowerCase().split(" ");return{top:C[0].split(""),middle:C[1].split(""),bottom:C[2].split("")}}),header:y.reactive({size:0,offset:0,space:!1}),right:y.reactive({size:300,offset:0,space:!1}),footer:y.reactive({size:0,offset:0,space:!1}),left:y.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,j){k[C][T]=j}};if(y.provide(Zr,k),xn()>0){let C=function(){q=null,P.classList.remove("hide-scrollbar")},T=function(){if(q===null){if(P.scrollHeight>b.screen.height)return;P.classList.add("hide-scrollbar")}else clearTimeout(q);q=setTimeout(C,300)},j=function(N){q!==null&&N==="remove"&&(clearTimeout(q),C()),window[`${N}EventListener`]("resize",T)},q=null;const P=document.body;y.watch(()=>l.container!==!0?"add":"remove",j),l.container!==!0&&j("add"),y.onUnmounted(()=>{j("remove")})}return()=>{const C=It(I.default,[y.h(Ea,{onScroll:d}),y.h(Rr,{onResize:h})]),T=y.h("div",{class:r.value,style:u.value,ref:l.container===!0?void 0:m,tabindex:-1},C);return l.container===!0?y.h("div",{class:"q-layout-container overflow-hidden",ref:m},[y.h(Rr,{onResize:f}),y.h("div",{class:"absolute-full",style:a.value},[y.h("div",{class:"scroll",style:i.value},[T])])]):T}}}),Zi=y.defineComponent({name:"Layout",__name:"Layout",props:{view:{default:"HHh Lpr Fff"},layoutClass:{default:"bg-white"},pageContainerClass:{default:""}},setup(l){return(I,t)=>(y.openBlock(),y.createBlock(qu,{view:I.view,class:y.normalizeClass(I.layoutClass),style:{minHeight:"auto !important"}},{default:y.withCtx(()=>[y.renderSlot(I.$slots,"header"),y.createVNode(Vu,{class:y.normalizeClass(I.pageContainerClass),style:{paddingBottom:"0 !important"}},{default:y.withCtx(()=>[y.renderSlot(I.$slots,"default")]),_:3},8,["class"]),y.renderSlot(I.$slots,"footer")]),_:3},8,["view","class"]))}});function zu(){let l=Object.create(null);return{getCache:(I,t)=>l[I]===void 0?l[I]=typeof t=="function"?t():t:l[I],setCache(I,t){l[I]=t},hasCache(I){return Object.hasOwnProperty.call(l,I)},clearCache(I){I!==void 0?delete l[I]:l=Object.create(null)}}}const nr=[-61,9,38,199,426,686,756,818,1111,1181,1210,1635,2060,2097,2192,2262,2324,2394,2456,3178];function Uu(l,I,t){return Object.prototype.toString.call(l)==="[object Date]"&&(t=l.getDate(),I=l.getMonth()+1,l=l.getFullYear()),Qu($i(l,I,t))}function Qo(l,I,t){return Za(Yu(l,I,t))}function Wu(l){return Hu(l)===0}function Sn(l,I){return I<=6?31:I<=11||Wu(l)?30:29}function Hu(l){const I=nr.length;let t=nr[0],b,m,c,o,s;if(l<t||l>=nr[I-1])throw new Error("Invalid Jalaali year "+l);for(s=1;s<I&&(b=nr[s],m=b-t,!(l<b));s+=1)t=b;return o=l-t,m-o<6&&(o=o-m+wt(m+4,33)*33),c=Pt(Pt(o+1,33)-1,4),c===-1&&(c=4),c}function Ja(l,I){const t=nr.length,b=l+621;let m=-14,c=nr[0],o,s,n,e,r;if(l<c||l>=nr[t-1])throw new Error("Invalid Jalaali year "+l);for(r=1;r<t&&(o=nr[r],s=o-c,!(l<o));r+=1)m=m+wt(s,33)*8+wt(Pt(s,33),4),c=o;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 I||(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 Yu(l,I,t){const b=Ja(l,!0);return $i(b.gy,3,b.march)+(I-1)*31-wt(I,7)*(I-7)+t-1}function Qu(l){const I=Za(l).gy;let t=I-621,b,m,c;const o=Ja(t,!1),s=$i(I,3,o.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,o.leap===1&&(c+=1);return m=7+wt(c,30),b=Pt(c,30)+1,{jy:t,jm:m,jd:b}}function $i(l,I,t){let b=wt((l+wt(I-8,6)+100100)*1461,4)+wt(153*Pt(I+9,12)+2,5)+t-34840408;return b=b-wt(wt(l+100100+wt(I-8,6),100)*3,4)+752,b}function Za(l){let I=4*l+139361631;I=I+wt(wt(4*l+183187720,146097)*3,4)*4-3908;const t=wt(Pt(I,1461),4)*5+308,b=wt(Pt(t,153),5)+1,m=Pt(wt(t,153),12)+1;return{gy:wt(I,1461)-100100+wt(8-m,6),gm:m,gd:b}}function wt(l,I){return~~(l/I)}function Pt(l,I){return l-~~(l/I)*I}const Ku=["gregorian","persian"],Ko={mask:{type:String},locale:Object,calendar:{type:String,validator:l=>Ku.includes(l),default:"gregorian"},landscape:Boolean,color:String,textColor:String,square:Boolean,flat:Boolean,bordered:Boolean,readonly:Boolean,disable:Boolean},Xu=["update:modelValue"];function $t(l){return l.year+"/"+vt(l.month)+"/"+vt(l.day)}function Gu(l,I){const t=y.computed(()=>l.disable!==!0&&l.readonly!==!0),b=y.computed(()=>t.value===!0?0:-1),m=y.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?{...I.lang.date,...l.locale}:I.lang.date}function o(s){const n=new Date,e=s===!0?null:0;if(l.calendar==="persian"){const r=Uu(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:o}}const ki={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,I,t)=>l+"-"+I+" 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 Xo(){const l=Array.isArray(navigator.languages)===!0&&navigator.languages.length!==0?navigator.languages[0]:navigator.language;if(typeof l=="string")return l.split(/[-_]/).map((I,t)=>t===0?I.toLowerCase():t>1||I.length<4?I.toUpperCase():I[0].toUpperCase()+I.slice(1).toLowerCase()).join("-")}const tr=_s({__qLang:{}},{getLocale:Xo,set(l=ki,I){const t={...l,rtl:l.rtl===!0,getLocale:Xo};{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:I,ssrContext:t}){l.lang=tr.__qLang,tr.__langConfig=l.config.lang,this.__installed===!0?I!==void 0&&this.set(I):(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(I||ki))}}),$a=864e5,Ju=36e5,_i=6e4,es="YYYY-MM-DDTHH:mm:ss.SSSZ",Zu=/\[((?:[^\]\\]|\\]|\\)*)\]|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,$u=/(\[[^\]]*\])|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,ai={};function ec(l,I){const t="("+I.days.join("|")+")",b=l+t;if(ai[b]!==void 0)return ai[b];const m="("+I.daysShort.join("|")+")",c="("+I.months.join("|")+")",o="("+I.monthsShort.join("|")+")",s={};let n=0;const e=l.replace($u,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,o;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 ai[b]=r,r}function ts(l,I){return l!==void 0?l:I!==void 0?I.date:ki.date}function Go(l,I=""){const t=l>0?"-":"+",b=Math.abs(l),m=Math.floor(b/60),c=b%60;return t+vt(m)+I+vt(c)}function tc(l,I,t){let b=l.getFullYear(),m=l.getMonth();const c=l.getDate();return I.year!==void 0&&(b+=t*I.year,delete I.year),I.month!==void 0&&(m+=t*I.month,delete I.month),l.setDate(1),l.setMonth(2),l.setFullYear(b),l.setMonth(m),l.setDate(Math.min(c,ro(l))),I.date!==void 0&&(l.setDate(l.getDate()+t*I.date),delete I.date),l}function rc(l,I,t){const b=I.year!==void 0?I.year:l[`get${t}FullYear`](),m=I.month!==void 0?I.month-1:l[`get${t}Month`](),c=new Date(b,m+1,0).getDate(),o=Math.min(c,I.date!==void 0?I.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`](o),delete I.year,delete I.month,delete I.date,l}function eo(l,I,t){const b=rs(I),m=new Date(l),c=b.year!==void 0||b.month!==void 0||b.date!==void 0?tc(m,b,t):m;for(const o in b){const s=xl(o);c[`set${s}`](c[`get${s}`]()+t*b[o])}return c}function rs(l){const I={...l};return l.years!==void 0&&(I.year=l.years,delete I.years),l.months!==void 0&&(I.month=l.months,delete I.months),l.days!==void 0&&(I.date=l.days,delete I.days),l.day!==void 0&&(I.date=l.day,delete I.day),l.hour!==void 0&&(I.hours=l.hour,delete I.hour),l.minute!==void 0&&(I.minutes=l.minute,delete I.minute),l.second!==void 0&&(I.seconds=l.second,delete I.second),l.millisecond!==void 0&&(I.milliseconds=l.millisecond,delete I.millisecond),I}function ns(l,I,t){const b=rs(I),m=t===!0?"UTC":"",c=new Date(l),o=b.year!==void 0||b.month!==void 0||b.date!==void 0?rc(c,b,m):c;for(const s in b){const n=s.charAt(0).toUpperCase()+s.slice(1);o[`set${m}${n}`](b[s])}return o}function nc(l,I,t){const b=is(l,I,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:eo(m,{minutes:b.timezoneOffset-c},1)}function is(l,I,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;I===void 0&&(I=es);const o=ts(t,tr.props),s=o.months,n=o.monthsShort,{regex:e,map:r}=ec(I,o),u=l.match(e);if(u===null)return c;let a="";if(r.X!==void 0||r.x!==void 0){const i=parseInt(u[r.X!==void 0?r.X:r.x],10);if(isNaN(i)===!0||i<0)return c;const d=new Date(i*(r.X!==void 0?1e3:1));c.year=d.getFullYear(),c.month=d.getMonth()+1,c.day=d.getDate(),c.hour=d.getHours(),c.minute=d.getMinutes(),c.second=d.getSeconds(),c.millisecond=d.getMilliseconds()}else{if(r.YYYY!==void 0)c.year=parseInt(u[r.YYYY],10);else if(r.YY!==void 0){const i=parseInt(u[r.YY],10);c.year=i<0?i:2e3+i}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 i=b!=="persian"?new Date(c.year,c.month,0).getDate():Sn(c.year,c.month);if(c.day>i)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 ic(l){return typeof l=="number"?!0:isNaN(Date.parse(l))===!1}function oc(l,I){return ns(new Date,l,I)}function ac(l){const I=new Date(l).getDay();return I===0?7:I}function kn(l){const I=new Date(l.getFullYear(),l.getMonth(),l.getDate());I.setDate(I.getDate()-(I.getDay()+6)%7+3);const t=new Date(I.getFullYear(),0,4);t.setDate(t.getDate()-(t.getDay()+6)%7+3);const b=I.getTimezoneOffset()-t.getTimezoneOffset();I.setHours(I.getHours()-b);const m=(I-t)/($a*7);return 1+Math.floor(m)}function sc(l){return l.getFullYear()*1e4+l.getMonth()*100+l.getDate()}function si(l,I){const t=new Date(l);return I===!0?sc(t):t.getTime()}function lc(l,I,t,b={}){const m=si(I,b.onlyDate),c=si(t,b.onlyDate),o=si(l,b.onlyDate);return(o>m||b.inclusiveFrom===!0&&o===m)&&(o<c||b.inclusiveTo===!0&&o===c)}function uc(l,I){return eo(l,I,1)}function cc(l,I){return eo(l,I,-1)}function Wt(l,I,t){const b=new Date(l),m=`set${t===!0?"UTC":""}`;switch(I){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 fc(l,I,t){const b=new Date(l),m=`set${t===!0?"UTC":""}`;switch(I){case"year":case"years":b[`${m}Month`](11);case"month":case"months":b[`${m}Date`](ro(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 dc(l){let I=new Date(l);return Array.prototype.slice.call(arguments,1).forEach(t=>{I=Math.max(I,new Date(t))}),I}function hc(l){let I=new Date(l);return Array.prototype.slice.call(arguments,1).forEach(t=>{I=Math.min(I,new Date(t))}),I}function hn(l,I,t){return(l.getTime()-l.getTimezoneOffset()*_i-(I.getTime()-I.getTimezoneOffset()*_i))/t}function to(l,I,t="days"){const b=new Date(l),m=new Date(I);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 hn(Wt(b,"day"),Wt(m,"day"),$a);case"hours":case"hour":return hn(Wt(b,"hour"),Wt(m,"hour"),Ju);case"minutes":case"minute":return hn(Wt(b,"minute"),Wt(m,"minute"),_i);case"seconds":case"second":return hn(Wt(b,"second"),Wt(m,"second"),1e3)}}function _n(l){return to(l,Wt(l,"year"),"days")+1}function pc(l){return On(l)===!0?"date":typeof l=="number"?"number":"string"}function mc(l,I,t){const b=new Date(l);if(I){const m=new Date(I);if(b<m)return m}if(t){const m=new Date(t);if(b>m)return m}return b}function gc(l,I,t){const b=new Date(l),m=new Date(I);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 ro(l){return new Date(l.getFullYear(),l.getMonth()+1,0).getDate()}function Sr(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 Jo={YY(l,I,t){const b=this.YYYY(l,I,t)%100;return b>=0?vt(b):"-"+vt(Math.abs(b))},YYYY(l,I,t){return t??l.getFullYear()},M(l){return l.getMonth()+1},Mo(l){return Sr(l.getMonth()+1)},MM(l){return vt(l.getMonth()+1)},MMM(l,I){return I.monthsShort[l.getMonth()]},MMMM(l,I){return I.months[l.getMonth()]},Q(l){return Math.ceil((l.getMonth()+1)/3)},Qo(l){return Sr(this.Q(l))},D(l){return l.getDate()},Do(l){return Sr(l.getDate())},DD(l){return vt(l.getDate())},DDD(l){return _n(l)},DDDo(l){return Sr(_n(l))},DDDD(l){return vt(_n(l),3)},d(l){return l.getDay()},do(l){return Sr(l.getDay())},dd(l,I){return I.days[l.getDay()].slice(0,2)},ddd(l,I){return I.daysShort[l.getDay()]},dddd(l,I){return I.days[l.getDay()]},E(l){return l.getDay()||7},w(l){return kn(l)},wo(l){return Sr(kn(l))},ww(l){return vt(kn(l))},H(l){return l.getHours()},HH(l){return vt(l.getHours())},h(l){const I=l.getHours();return I===0?12:I>12?I%12:I},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,I,t,b){const m=b??l.getTimezoneOffset();return Go(m,":")},ZZ(l,I,t,b){const m=b??l.getTimezoneOffset();return Go(m)},X(l){return Math.floor(l.getTime()/1e3)},x(l){return l.getTime()}};function os(l,I,t,b,m){if(l!==0&&!l||l===1/0||l===-1/0)return;const c=new Date(l);if(isNaN(c))return;I===void 0&&(I=es);const o=ts(t,tr.props);return I.replace(Zu,(s,n)=>s in Jo?Jo[s](c,o,b,m):n===void 0?s:n.split("\\]").join("]"))}function bc(l){return On(l)===!0?new Date(l.getTime()):l}const as={isValid:ic,extractDate:nc,buildDate:oc,getDayOfWeek:ac,getWeekOfYear:kn,isBetweenDates:lc,addToDate:uc,subtractFromDate:cc,adjustDate:ns,startOfDate:Wt,endOfDate:fc,getMaxDate:dc,getMinDate:hc,getDateDiff:to,getDayOfYear:_n,inferDateFormat:pc,getDateBetween:mc,isSameDate:gc,daysInMonth:ro,formatDate:os,clone:bc},Yt=20,vc=["Calendar","Years","Months"],Zo=l=>vc.includes(l),li=l=>/^-?[\d]+\/[0-1]\d$/.test(l),kr=" — ";function er(l){return l.year+"/"+vt(l.month)}const ss=$e({name:"QDate",props:{...Ko,...Nn,...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:{...Ko.mask,default:"YYYY/MM/DD"},defaultYearMonth:{type:String,validator:li},yearsInMonthView:Boolean,events:[Array,Function],eventColor:[String,Function],emitImmediately:Boolean,options:[Array,Function],navigationMinYearMonth:{type:String,validator:li},navigationMaxYearMonth:{type:String,validator:li},noUnset:Boolean,firstDayOfWeek:[String,Number],todayBtn:Boolean,minimal:Boolean,defaultView:{type:String,default:"Calendar",validator:Zo}},emits:[...Xu,"rangeStart","rangeEnd","navigation"],setup(l,{slots:I,emit:t}){const{proxy:b}=y.getCurrentInstance(),{$q:m}=b,c=Ft(l,m),{getCache:o}=zu(),{tabindex:s,headerClass:n,getLocale:e,getCurrentDate:r}=Gu(l,m);let u;const a=al(l),i=va(a),d=y.ref(null),h=y.ref(Ue()),f=y.ref(e()),g=y.computed(()=>Ue()),p=y.computed(()=>e()),k=y.computed(()=>r()),C=y.ref(Ne(h.value,f.value)),T=y.ref(l.defaultView),j=y.computed(()=>m.lang.rtl===!0?"right":"left"),q=y.ref(j.value),P=y.ref(j.value),N=C.value.year,V=y.ref(N-N%Yt-(N<0?Yt:0)),W=y.ref(null),L=y.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=y.computed(()=>l.color||"primary"),M=y.computed(()=>l.textColor||"white"),_=y.computed(()=>l.emitImmediately===!0&&l.multiple!==!0&&l.range!==!0),v=y.computed(()=>Array.isArray(l.modelValue)===!0?l.modelValue:l.modelValue!==null&&l.modelValue!==void 0?[l.modelValue]:[]),x=y.computed(()=>v.value.filter(re=>typeof re=="string").map(re=>Ve(re,h.value,f.value)).filter(re=>re.dateHash!==null&&re.day!==null&&re.month!==null&&re.year!==null)),w=y.computed(()=>{const re=X=>Ve(X,h.value,f.value);return v.value.filter(X=>Qa(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=y.computed(()=>l.calendar!=="persian"?re=>new Date(re.year,re.month-1,re.day):re=>{const X=Qo(re.year,re.month,re.day);return new Date(X.gy,X.gm-1,X.gd)}),E=y.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?f.value:ne,re.year,re.timezoneOffset)),O=y.computed(()=>x.value.length+w.value.reduce((re,X)=>re+1+to(S.value(X.to),S.value(X.from)),0)),R=y.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,de=S.value(ne);return f.value.daysShort[de.getDay()]+", "+f.value.monthsShort[ne.month-1]+" "+ne.day+kr+"?"}if(O.value===0)return kr;if(O.value>1)return`${O.value} ${f.value.pluralDay}`;const re=x.value[0],X=S.value(re);return isNaN(X.valueOf())===!0?kr:f.value.headerTitle!==void 0?f.value.headerTitle(X,re):f.value.daysShort[X.getDay()]+", "+f.value.monthsShort[re.month-1]+" "+re.day}),z=y.computed(()=>x.value.concat(w.value.map(X=>X.from)).sort((X,ne)=>X.year-ne.year||X.month-ne.month)[0]),U=y.computed(()=>x.value.concat(w.value.map(X=>X.to)).sort((X,ne)=>ne.year-X.year||ne.month-X.month)[0]),Q=y.computed(()=>{if(l.subtitle!==void 0&&l.subtitle!==null&&l.subtitle.length!==0)return l.subtitle;if(O.value===0)return kr;if(O.value>1){const re=z.value,X=U.value,ne=f.value.monthsShort;return ne[re.month-1]+(re.year!==X.year?" "+re.year+kr+ne[X.month-1]+" ":re.month!==X.month?kr+ne[X.month-1]:"")+" "+X.year}return x.value[0].year}),D=y.computed(()=>{const re=[m.iconSet.datetime.arrowLeft,m.iconSet.datetime.arrowRight];return m.lang.rtl===!0?re.reverse():re}),Y=y.computed(()=>l.firstDayOfWeek!==void 0?Number(l.firstDayOfWeek):f.value.firstDayOfWeek),F=y.computed(()=>{const re=f.value.daysShort,X=Y.value;return X>0?re.slice(X,7).concat(re.slice(0,X)):re}),B=y.computed(()=>{const re=C.value;return l.calendar!=="persian"?new Date(re.year,re.month,0).getDate():Sn(re.year,re.month)}),H=y.computed(()=>typeof l.eventColor=="function"?l.eventColor:()=>l.eventColor),K=y.computed(()=>{if(l.navigationMinYearMonth===void 0)return null;const re=l.navigationMinYearMonth.split("/");return{year:parseInt(re[0],10),month:parseInt(re[1],10)}}),$=y.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=y.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)),$.value!==null&&$.value.year<=C.value.year&&(re.year.next=!1,$.value.year===C.value.year&&$.value.month<=C.value.month&&(re.month.next=!1)),re}),ee=y.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=y.computed(()=>{const re={};return w.value.forEach(X=>{const ne=er(X.from),de=er(X.to);if(re[ne]===void 0&&(re[ne]=[]),re[ne].push({from:X.from.day,to:ne===de?X.to.day:void 0,range:X}),ne<de){let ge;const{year:Ee,month:be}=X.from,_e=be<12?{year:Ee,month:be+1}:{year:Ee+1,month:1};for(;(ge=er(_e))<=de;)re[ge]===void 0&&(re[ge]=[]),re[ge].push({from:void 0,to:ge===de?X.to.day:void 0,range:X}),_e.month++,_e.month>12&&(_e.year++,_e.month=1)}}),re}),ue=y.computed(()=>{if(W.value===null)return;const{init:re,initHash:X,final:ne,finalHash:de}=W.value,[ge,Ee]=X<=de?[re,ne]:[ne,re],be=er(ge),_e=er(Ee);if(be!==J.value&&_e!==J.value)return;const Be={};return be===J.value?(Be.from=ge.day,Be.includeFrom=!0):Be.from=1,_e===J.value?(Be.to=Ee.day,Be.includeTo=!0):Be.to=B.value,Be}),J=y.computed(()=>er(C.value)),le=y.computed(()=>{const re={};if(l.options===void 0){for(let ne=1;ne<=B.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<=B.value;ne++){const de=J.value+"/"+vt(ne);re[ne]=X(de)}return re}),ae=y.computed(()=>{const re={};if(l.events===void 0)for(let X=1;X<=B.value;X++)re[X]=!1;else{const X=typeof l.events=="function"?l.events:ne=>l.events.includes(ne);for(let ne=1;ne<=B.value;ne++){const de=J.value+"/"+vt(ne);re[ne]=X(de)===!0&&H.value(de)}}return re}),te=y.computed(()=>{let re,X;const{year:ne,month:de}=C.value;if(l.calendar!=="persian")re=new Date(ne,de-1,1),X=new Date(ne,de-1,0).getDate();else{const ge=Qo(ne,de,1);re=new Date(ge.gy,ge.gm-1,ge.gd);let Ee=de-1,be=ne;Ee===0&&(Ee=12,be--),X=Sn(be,Ee)}return{days:re.getDay()-Y.value-1,endDay:X}}),oe=y.computed(()=>{const re=[],{days:X,endDay:ne}=te.value,de=X<0?X+7:X;if(de<6)for(let be=ne-de;be<=ne;be++)re.push({i:be,fill:!0});const ge=re.length;for(let be=1;be<=B.value;be++){const _e={i:be,event:ae.value[be],classes:[]};le.value[be]===!0&&(_e.in=!0,_e.flat=!0),re.push(_e)}if(ee.value[J.value]!==void 0&&ee.value[J.value].forEach(be=>{const _e=ge+be-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(be=>{if(be.from!==void 0){const _e=ge+be.from-1,Be=ge+(be.to||B.value)-1;for(let ze=_e;ze<=Be;ze++)Object.assign(re[ze],{range:be.range,unelevated:!0,color:A.value,textColor:M.value});Object.assign(re[_e],{rangeFrom:!0,flat:!1}),be.to!==void 0&&Object.assign(re[Be],{rangeTo:!0,flat:!1})}else if(be.to!==void 0){const _e=ge+be.to-1;for(let Be=ge;Be<=_e;Be++)Object.assign(re[Be],{range:be.range,unelevated:!0,color:A.value,textColor:M.value});Object.assign(re[_e],{flat:!1,rangeTo:!0})}else{const _e=ge+B.value-1;for(let Be=ge;Be<=_e;Be++)Object.assign(re[Be],{range:be.range,unelevated:!0,color:A.value,textColor:M.value})}}),ue.value!==void 0){const be=ge+ue.value.from-1,_e=ge+ue.value.to-1;for(let Be=be;Be<=_e;Be++)re[Be].color=A.value,re[Be].editRange=!0;ue.value.includeFrom===!0&&(re[be].editRangeFrom=!0),ue.value.includeTo===!0&&(re[_e].editRangeTo=!0)}C.value.year===k.value.year&&C.value.month===k.value.month&&(re[ge+k.value.day-1].today=!0);const Ee=re.length%7;if(Ee>0){const be=7-Ee;for(let _e=1;_e<=be;_e++)re.push({i:_e,fill:!0})}return re.forEach(be=>{let _e="q-date__calendar-item ";be.fill===!0?_e+="q-date__calendar-item--fill":(_e+=`q-date__calendar-item--${be.in===!0?"in":"out"}`,be.range!==void 0&&(_e+=` q-date__range${be.rangeTo===!0?"-to":be.rangeFrom===!0?"-from":""}`),be.editRange===!0&&(_e+=` q-date__edit-range${be.editRangeFrom===!0?"-from":""}${be.editRangeTo===!0?"-to":""}`),(be.range!==void 0||be.editRange===!0)&&(_e+=` text-${be.color}`)),be.classes=_e}),re}),ie=y.computed(()=>l.disable===!0?{"aria-disabled":"true"}:{});y.watch(()=>l.modelValue,re=>{if(u===JSON.stringify(re))u=0;else{const X=Ne(h.value,f.value);et(X.year,X.month,X)}}),y.watch(T,()=>{d.value!==null&&b.$el.contains(document.activeElement)===!0&&d.value.focus()}),y.watch(()=>C.value.year+"|"+C.value.month,()=>{t("navigation",{year:C.value.year,month:C.value.month})}),y.watch(g,re=>{we(re,f.value,"mask"),h.value=re}),y.watch(p,re=>{we(h.value,re,"locale"),f.value=re});function se(re){u=JSON.stringify(re)}function pe(){const{year:re,month:X,day:ne}=k.value,de={...C.value,year:re,month:X,day:ne},ge=ee.value[er(de)];(ge===void 0||ge.includes(de.day)===!1)&&at(de),Ce(de.year,de.month)}function xe(re){Zo(re)===!0&&(T.value=re)}function Re(re,X){["month","year"].includes(re)&&(re==="month"?Fe:ke)(X===!0?-1:1)}function Ce(re,X){T.value="Calendar",et(re,X)}function Me(re,X){if(l.range===!1||!re){W.value=null;return}const ne=Object.assign({...C.value},re),de=X!==void 0?Object.assign({...C.value},X):ne;W.value={init:ne,initHash:$t(ne),final:de,finalHash:$t(de)},Ce(ne.year,ne.month)}function Ue(){return l.calendar==="persian"?"YYYY/MM/DD":l.mask}function Ve(re,X,ne){return is(re,X,ne,l.calendar,{hour:0,minute:0,second:0,millisecond:0})}function Ne(re,X){const ne=Array.isArray(l.modelValue)===!0?l.modelValue:l.modelValue?[l.modelValue]:[];if(ne.length===0)return qe();const de=ne[ne.length-1],ge=Ve(de.from!==void 0?de.from:de,re,X);return ge.dateHash===null?qe():ge}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 Le(re,X){(ee.value[X]?.includes(re.day)===!0?me:at)(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),$.value!==null&&re>=$.value.year&&((X>$.value.month||re>$.value.year)&&(X=$.value.month),re=$.value.year),ne!==void 0){const{hour:ge,minute:Ee,second:be,millisecond:_e,timezoneOffset:Be,timeHash:ze}=ne;Object.assign(C.value,{hour:ge,minute:Ee,second:be,millisecond:_e,timezoneOffset:Be,timeHash:ze})}const de=re+"/"+vt(X)+"/01";de!==C.value.dateHash&&(q.value=C.value.dateHash<de==(m.lang.rtl!==!0)?"left":"right",re!==C.value.year&&(P.value=q.value),y.nextTick(()=>{V.value=re-re%Yt-(re<0?Yt:0),Object.assign(C.value,{year:re,month:X,day:1,dateHash:de})}))}function He(re,X,ne){const de=re!==null&&re.length===1&&l.multiple===!1?re[0]:re,{reason:ge,details:Ee}=tt(X,ne);se(de),t("update:modelValue",de,ge,Ee)}function nt(re){const X=x.value[0]!==void 0&&x.value[0].dateHash!==null?{...x.value[0]}:{...C.value};y.nextTick(()=>{X.year=C.value.year,X.month=C.value.month;const ne=l.calendar!=="persian"?new Date(X.year,X.month,0).getDate():Sn(X.year,X.month);X.day=Math.min(Math.max(1,X.day),ne);const de=Ye(X),{details:ge}=tt("",X);se(de),t("update:modelValue",de,re,ge)})}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 at(re){let X;if(l.multiple===!0)if(re.from!==void 0){const ne=$t(re.from),de=$t(re.to),ge=x.value.filter(be=>be.dateHash<ne||be.dateHash>de),Ee=w.value.filter(({from:be,to:_e})=>_e.dateHash<ne||be.dateHash>de);X=ge.concat(Ee).concat(re).map(be=>Ye(be))}else{const ne=v.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(de=>de.from!==void 0?de.from!==ne.from&&de.to!==ne.to:!0):X=l.modelValue.filter(de=>de!==ne),X.length===0&&(X=null)}He(X,"remove",re)}function we(re,X,ne){const de=x.value.concat(w.value).map(Ee=>Ye(Ee,re,X)).filter(Ee=>Ee.from!==void 0?Ee.from.dateHash!==null&&Ee.to.dateHash!==null:Ee.dateHash!==null),ge=(l.multiple===!0?de:de[0])||null;se(ge),t("update:modelValue",ge,ne)}function Te(){if(l.minimal!==!0)return y.h("div",{class:"q-date__header "+n.value},[y.h("div",{class:"relative-position"},[y.h(y.Transition,{name:"q-transition--fade"},()=>y.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,...o("vY",{onClick(){T.value="Years"},onKeyup(re){re.keyCode===13&&(T.value="Years")}})},[Q.value]))]),y.h("div",{class:"q-date__header-title relative-position flex no-wrap"},[y.h("div",{class:"relative-position col"},[y.h(y.Transition,{name:"q-transition--fade"},()=>y.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,...o("vC",{onClick(){T.value="Calendar"},onKeyup(re){re.keyCode===13&&(T.value="Calendar")}})},[R.value]))]),l.todayBtn===!0?y.h(ct,{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:pe}):null])])}function Oe({label:re,type:X,key:ne,dir:de,goTo:ge,boundaries:Ee,cls:be}){return[y.h("div",{class:"row items-center q-date__arrow"},[y.h(ct,{round:!0,dense:!0,size:"sm",flat:!0,icon:D.value[0],"aria-label":X==="Years"?m.lang.date.prevYear:m.lang.date.prevMonth,tabindex:s.value,disable:Ee.prev===!1,...o("go-#"+X,{onClick(){ge(-1)}})})]),y.h("div",{class:"relative-position overflow-hidden flex flex-center"+be},[y.h(y.Transition,{name:"q-transition--jump-"+de},()=>y.h("div",{key:ne},[y.h(ct,{flat:!0,dense:!0,noCaps:!0,label:re,tabindex:s.value,...o("view#"+X,{onClick:()=>{T.value=X}})})]))]),y.h("div",{class:"row items-center q-date__arrow"},[y.h(ct,{round:!0,dense:!0,size:"sm",flat:!0,icon:D.value[1],"aria-label":X==="Years"?m.lang.date.nextYear:m.lang.date.nextMonth,tabindex:s.value,disable:Ee.next===!1,...o("go+#"+X,{onClick(){ge(1)}})})])]}const Ae={Calendar:()=>[y.h("div",{key:"calendar-view",class:"q-date__view q-date__calendar"},[y.h("div",{class:"q-date__navigation row items-center no-wrap"},Oe({label:f.value.months[C.value.month-1],type:"Months",key:C.value.month,dir:q.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:""}))),y.h("div",{class:"q-date__calendar-weekdays row items-center no-wrap"},F.value.map(re=>y.h("div",{class:"q-date__calendar-item"},[y.h("div",re)]))),y.h("div",{class:"q-date__calendar-days-container relative-position overflow-hidden"},[y.h(y.Transition,{name:"q-transition--slide-"+q.value},()=>y.h("div",{key:J.value,class:"q-date__calendar-days fit"},oe.value.map(re=>y.h("div",{class:re.classes},[re.in===!0?y.h(ct,{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,...o("day#"+re.i,{onClick:()=>{Qe(re.i)},onMouseover:()=>{Ke(re.i)}})},re.event!==!1?()=>y.h("div",{class:"q-date__event bg-"+re.event}):null):y.h("div",""+re.i)]))))])])],Months(){const re=C.value.year===k.value.year,X=de=>K.value!==null&&C.value.year===K.value.year&&K.value.month>de||$.value!==null&&C.value.year===$.value.year&&$.value.month<de,ne=f.value.monthsShort.map((de,ge)=>{const Ee=C.value.month===ge+1;return y.h("div",{class:"q-date__months-item flex flex-center"},[y.h(ct,{class:re===!0&&k.value.month===ge+1?"q-date__today":null,flat:Ee!==!0,label:de,unelevated:Ee,color:Ee===!0?A.value:null,textColor:Ee===!0?M.value:null,tabindex:s.value,disable:X(ge+1),...o("month#"+ge,{onClick:()=>{We(ge+1)}})})])});return l.yearsInMonthView===!0&&ne.unshift(y.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"})])),y.h("div",{key:"months-view",class:"q-date__view q-date__months flex flex-center"},ne)},Years(){const re=V.value,X=re+Yt,ne=[],de=ge=>K.value!==null&&K.value.year>ge||$.value!==null&&$.value.year<ge;for(let ge=re;ge<=X;ge++){const Ee=C.value.year===ge;ne.push(y.h("div",{class:"q-date__years-item flex flex-center"},[y.h(ct,{key:"yr"+ge,class:k.value.year===ge?"q-date__today":null,flat:!Ee,label:ge,dense:!0,unelevated:Ee,color:Ee===!0?A.value:null,textColor:Ee===!0?M.value:null,tabindex:s.value,disable:de(ge),...o("yr#"+ge,{onClick:()=>{De(ge)}})})]))}return y.h("div",{class:"q-date__view q-date__years flex flex-center"},[y.h("div",{class:"col-auto"},[y.h(ct,{round:!0,dense:!0,flat:!0,icon:D.value[0],"aria-label":m.lang.date.prevRangeYears(Yt),tabindex:s.value,disable:de(re),...o("y-",{onClick:()=>{V.value-=Yt}})})]),y.h("div",{class:"q-date__years-content col self-stretch row items-center"},ne),y.h("div",{class:"col-auto"},[y.h(ct,{round:!0,dense:!0,flat:!0,icon:D.value[1],"aria-label":m.lang.date.nextRangeYears(Yt),tabindex:s.value,disable:de(X),...o("y+",{onClick:()=>{V.value+=Yt}})})])])}};function Qe(re){const X={...C.value,day:re};if(l.range===!1){Le(X,J.value);return}if(W.value===null){const ne=oe.value.find(ge=>ge.fill!==!0&&ge.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 de=$t(X);W.value={init:X,initHash:de,final:X,finalHash:de},t("rangeStart",Ge(X))}else{const ne=W.value.initHash,de=$t(X),ge=ne<=de?{from:W.value.init,to:X}:{from:X,to:W.value.init};W.value=null,at(ne===de?X:{target:X,...ge}),t("rangeEnd",{from:Ge(ge.from),to:Ge(ge.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:pe,setView:xe,offsetCalendar:Re,setCalendarTo:Ce,setEditingRange:Me}),()=>{const re=[y.h("div",{class:"q-date__content col relative-position"},[y.h(y.Transition,{name:"q-transition--fade"},Ae[T.value])])],X=gt(I.default);return X!==void 0&&re.push(y.h("div",{class:"q-date__actions"},X)),l.name!==void 0&&l.disable!==!0&&i(re,"push"),y.h("div",{class:L.value,...ie.value},[Te(),y.h("div",{ref:d,class:"q-date__main col column",tabindex:-1},re)])}}}),ls=$e({name:"QPopupProxy",props:{...Ta,breakpoint:{type:[String,Number],default:450}},emits:["show","hide"],setup(l,{slots:I,emit:t,attrs:b}){const{proxy:m}=y.getCurrentInstance(),{$q:c}=m,o=y.ref(!1),s=y.ref(null),n=y.computed(()=>parseInt(l.breakpoint,10)),{canShow:e}=Li({showing:o});function r(){return c.screen.width<n.value||c.screen.height<n.value?"dialog":"menu"}const u=y.ref(r()),a=y.computed(()=>u.value==="menu"?{maxHeight:"99vh"}:{});y.watch(()=>r(),h=>{o.value!==!0&&(u.value=h)});function i(h){o.value=!0,t("show",h)}function d(h){o.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:i,onHide:d};let f;return u.value==="dialog"?f=zn:(f=Jr,Object.assign(h,{target:l.target,contextMenu:l.contextMenu,noParentEvent:!0,separateClosePopup:!0})),y.h(f,h,I.default)}}}),$o={date:"####/##/##",datetime:"####/##/## ##:##",time:"##:##",fulltime:"##:##:##",phone:"(###) ### - ####",card:"#### #### #### ####"},Fn={"#":{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(Fn);us.forEach(l=>{Fn[l].regex=new RegExp(Fn[l].pattern)});const yc=new RegExp("\\\\([^.*+?^${}()|([\\]])|([.*+?^${}()|[\\]])|(["+us.join("")+"])|(.)","g"),ea=/[.*+?^${}()|[\]\\]/g,Ct="",wc={mask:String,reverseFillMask:Boolean,fillMask:[Boolean,String],unmaskedValue:Boolean};function xc(l,I,t,b){let m,c,o,s,n,e;const r=y.ref(null),u=y.ref(i());function a(){return l.autogrow===!0||["textarea","text","search","url","tel","password"].includes(l.type)}y.watch(()=>l.type+l.autogrow,h),y.watch(()=>l.mask,N=>{if(N!==void 0)f(u.value,!0);else{const V=q(u.value);h(),l.modelValue!==V&&I("update:modelValue",V)}}),y.watch(()=>l.fillMask+l.reverseFillMask,()=>{r.value===!0&&f(u.value,!0)}),y.watch(()=>l.unmaskedValue,()=>{r.value===!0&&f(u.value)});function i(){if(h(),r.value===!0){const N=T(q(l.modelValue));return l.fillMask!==!1?P(N):N}return l.modelValue}function d(N){if(N<m.length)return m.slice(-N);let V="",W=m;const L=W.indexOf(Ct);if(L!==-1){for(let A=N-W.length;A>0;A--)V+=Ct;W=W.slice(0,L)+V+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=$o[l.mask]===void 0?l.mask:$o[l.mask],V=typeof l.fillMask=="string"&&l.fillMask.length!==0?l.fillMask.slice(0,1):"_",W=V.replace(ea,"\\$&"),L=[],A=[],M=[];let _=l.reverseFillMask===!0,v="",x="";N.replace(yc,(O,R,z,U,Q)=>{if(U!==void 0){const D=Fn[U];M.push(D),x=D.negate,_===!0&&(A.push("(?:"+x+"+)?("+D.pattern+"+)?(?:"+x+"+)?("+D.pattern+"+)?"),_=!1),A.push("(?:"+x+"+)?("+D.pattern+")?")}else if(z!==void 0)v="\\"+(z==="\\"?"":z),M.push(z),L.push("([^"+v+"]+)?"+v+"?");else{const D=R!==void 0?R:Q;v=D==="\\"?"\\\\\\\\":D.replace(ea,"\\\\$&"),M.push(D),L.push("([^"+v+"]+)?"+v+"?")}});const w=new RegExp("^"+L.join("")+"("+(v===""?".":"[^"+v+"]")+"+)?"+(v===""?"":"["+v+"]*")+"$"),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));o=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,D=O;Q<U;Q++){const Y=E[Q].exec(D);if(Y===null)break;D=D.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(V)}function f(N,V,W){const L=b.value,A=L.selectionEnd,M=L.value.length-A,_=q(N);V===!0&&h();const v=T(_),x=l.fillMask!==!1?P(v):v,w=u.value!==x;L.value!==x&&(L.value=x),w===!0&&(u.value=x),document.activeElement===L&&y.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>v.length?1:0:Math.max(0,x.length-(x===c?0:Math.min(v.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(v.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(v.length,A)-1);p.right(L,E)}else{const E=A-1;p.right(L,E)}});const S=l.unmaskedValue===!0?q(x):x;String(l.modelValue)!==S&&(l.modelValue!==null||S!=="")&&t(S,!0)}function g(N,V,W){const L=T(q(N.value));V=Math.max(0,m.indexOf(Ct),Math.min(L.length,V)),n=V,N.setSelectionRange(V,W,"forward")}const p={left(N,V){const W=m.slice(V-1).indexOf(Ct)===-1;let L=Math.max(0,V-1);for(;L>=0;L--)if(m[L]===Ct){V=L,W===!0&&V++;break}if(L<0&&m[V]!==void 0&&m[V]!==Ct)return p.right(N,0);V>=0&&N.setSelectionRange(V,V,"backward")},right(N,V){const W=N.value.length;let L=Math.min(W,V+1);for(;L<=W;L++)if(m[L]===Ct){V=L;break}else m[L-1]===Ct&&(V=L);if(L>W&&m[V-1]!==void 0&&m[V-1]!==Ct)return p.left(N,W);N.setSelectionRange(V,V,"forward")},leftReverse(N,V){const W=d(N.value.length);let L=Math.max(0,V-1);for(;L>=0;L--)if(W[L-1]===Ct){V=L;break}else if(W[L]===Ct&&(V=L,L===0))break;if(L<0&&W[V]!==void 0&&W[V]!==Ct)return p.rightReverse(N,0);V>=0&&N.setSelectionRange(V,V,"backward")},rightReverse(N,V){const W=N.value.length,L=d(W),A=L.slice(0,V+1).indexOf(Ct)===-1;let M=Math.min(W,V+1);for(;M<=W;M++)if(L[M-1]===Ct){V=M,V>0&&A===!0&&V--;break}if(M>W&&L[V-1]!==void 0&&L[V-1]!==Ct)return p.leftReverse(N,W);N.setSelectionRange(V,V,"forward")}};function k(N){I("click",N),e=void 0}function C(N){if(I("keydown",N),Fi(N)===!0||N.altKey===!0)return;const V=b.value,W=V.selectionStart,L=V.selectionEnd;if(N.shiftKey||(e=void 0),N.keyCode===37||N.keyCode===39){N.shiftKey&&e===void 0&&(e=V.selectionDirection==="forward"?W:L);const A=p[(N.keyCode===39?"right":"left")+(l.reverseFillMask===!0?"Reverse":"")];if(N.preventDefault(),A(V,e===W?L:W),N.shiftKey){const M=V.selectionStart;V.setSelectionRange(Math.min(e,M),Math.max(e,M),"forward")}}else N.keyCode===8&&l.reverseFillMask!==!0&&W===L?(p.left(V,W),V.setSelectionRange(V.selectionStart,L,"backward")):N.keyCode===46&&l.reverseFillMask===!0&&W===L&&(p.rightReverse(V,L),V.setSelectionRange(W,V.selectionEnd,"forward"))}function T(N){if(N==null||N==="")return"";if(l.reverseFillMask===!0)return j(N);const V=o;let W=0,L="";for(let A=0;A<V.length;A++){const M=N[W],_=V[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 j(N){const V=o,W=m.indexOf(Ct);let L=N.length-1,A="";for(let M=V.length-1;M>=0&&L!==-1;M--){const _=V[M];let v=N[L];if(typeof _=="string")A=_+A;else if(v!==void 0&&_.regex.test(v))do A=(_.transform!==void 0?_.transform(v):v)+A,L--,v=N[L];while(W===M&&v!==void 0&&_.regex.test(v));else return A}return A}function q(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:f,onMaskedKeydown:C,onMaskedClick:k}}function Sc(l,I){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 y.computed(()=>{if(l.type==="file")return t()})}const Kr=$e({name:"QInput",inheritAttrs:!1,props:{...qn,...wc,...Nn,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:[...Ki,"paste","change","keydown","click","animationend"],setup(l,{emit:I,attrs:t}){const{proxy:b}=y.getCurrentInstance(),{$q:m}=b,c={};let o=NaN,s,n,e=null,r;const u=y.ref(null),a=ya(l),{innerValue:i,hasMask:d,moveCursorForPaste:h,updateMaskValue:f,onMaskedKeydown:g,onMaskedClick:p}=xc(l,I,v,u),k=Sc(l),C=y.computed(()=>Qr(i.value)),T=Ya(M),j=Xi({changeEvent:!0}),q=y.computed(()=>l.type==="textarea"||l.autogrow===!0),P=y.computed(()=>q.value===!0||["text","search","url","tel","password"].includes(l.type)),N=y.computed(()=>{const R={...j.splitAttrs.listeners.value,onInput:M,onPaste:A,onChange:w,onBlur:S,onFocus:Dt};return R.onCompositionstart=R.onCompositionupdate=R.onCompositionend=T,d.value===!0&&(R.onKeydown=g,R.onClick=p),l.autogrow===!0&&(R.onAnimationend=_),R}),V=y.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,...j.splitAttrs.attributes.value,id:j.targetUid.value,maxlength:l.maxlength,disabled:l.disable===!0,readonly:l.readonly===!0};return q.value===!1&&(R.type=l.type),l.autogrow===!0&&(R.rows=1),R});y.watch(()=>l.type,()=>{u.value&&(u.value.value=l.modelValue)}),y.watch(()=>l.modelValue,R=>{if(d.value===!0){if(n===!0&&(n=!1,String(R)===o))return;f(R)}else i.value!==R&&(i.value=R,l.type==="number"&&c.hasOwnProperty("value")===!0&&(s===!0?s=!1:delete c.value));l.autogrow===!0&&y.nextTick(x)}),y.watch(()=>l.autogrow,R=>{R===!0?y.nextTick(x):u.value!==null&&t.rows>0&&(u.value.style.height="auto")}),y.watch(()=>l.dense,()=>{l.autogrow===!0&&y.nextTick(x)});function W(){Gr(()=>{const R=document.activeElement;u.value!==null&&u.value!==R&&(R===null||R.id!==j.targetUid.value)&&u.value.focus({preventScroll:!0})})}function L(){u.value?.select()}function A(R){if(d.value===!0&&l.reverseFillMask!==!0){const z=R.target;h(z,z.selectionStart,z.selectionEnd)}I("paste",R)}function M(R){if(!R||!R.target)return;if(l.type==="file"){I("update:modelValue",R.target.files);return}const z=R.target.value;if(R.target.qComposing===!0){c.value=z;return}if(d.value===!0)f(z,!1,R.inputType);else if(v(z),P.value===!0&&R.target===document.activeElement){const{selectionStart:U,selectionEnd:Q}=R.target;U!==void 0&&Q!==void 0&&y.nextTick(()=>{R.target===document.activeElement&&z.indexOf(R.target.value)===0&&R.target.setSelectionRange(U,Q)})}l.autogrow===!0&&x()}function _(R){I("animationend",R),x()}function v(R,z){r=()=>{e=null,l.type!=="number"&&c.hasOwnProperty("value")===!0&&delete c.value,l.modelValue!==R&&o!==R&&(o=R,z===!0&&(n=!0),I("update:modelValue",R),y.nextTick(()=>{o===R&&(o=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:D}=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(D,10)<R.scrollHeight?"auto":"hidden"),z.marginBottom="",R.scrollTop=U}})}function w(R){T(R),e!==null&&(clearTimeout(e),e=null),r?.(),I("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=i.value!==void 0?i.value:"")})}function E(){return c.hasOwnProperty("value")===!0?c.value:i.value!==void 0?i.value:""}y.onBeforeUnmount(()=>{S()}),y.onMounted(()=>{l.autogrow===!0&&x()}),Object.assign(j,{innerValue:i,fieldClass:y.computed(()=>`q-${q.value===!0?"textarea":"input"}`+(l.autogrow===!0?" q-textarea--autogrow":"")),hasShadow:y.computed(()=>l.type!=="file"&&typeof l.shadowText=="string"&&l.shadowText.length!==0),inputRef:u,emitValue:v,hasValue:C,floatingLabel:y.computed(()=>C.value===!0&&(l.type!=="number"||isNaN(i.value)===!1)||Qr(l.displayValue)),getControl:()=>y.h(q.value===!0?"textarea":"input",{ref:u,class:["q-field__native q-placeholder",l.inputClass],style:l.inputStyle,...V.value,...N.value,...l.type!=="file"?{value:E()}:k.value}),getShadowControl:()=>y.h("div",{class:"q-field__native q-field__shadow absolute-bottom no-pointer-events"+(q.value===!0?"":" text-no-wrap")},[y.h("span",{class:"invisible"},E()),y.h("span",l.shadowText)])});const O=Gi(j);return Object.assign(b,{focus:W,select:L,getNativeElement:()=>u.value}),Lt(b,"nativeEl",()=>u.value),O}});function kc(l){return{entity:l.entity,dataCy:l.dataCy,defaultLabel:l.defaultLabel,routeName:l.routeName,shouldRender:l.customShouldRender||(({store:I})=>l.storeField?!!I[l.storeField]:!0),getLabel:l.getLabel||(l.labelField?({store:I})=>l.storeField&&I[l.storeField]?.[l.labelField]||l.defaultLabel:void 0),getColor:l.customGetColor||(({store:I})=>l.storeField&&I[l.storeField]?"primary":"dark"),getRouteParams:l.routeParamKey&&l.routeParamField?({store:I})=>({[l.routeParamKey]:l.storeField&&I[l.storeField]?.[l.routeParamField]}):void 0,clearActions:[...l.clearMethods?.map(I=>({store:t})=>t[I]?.())||[],...l.navActions?.map(I=>({navStore:t})=>I(t))||[]]}}const cs=/^\d{2}-\d{2}-\d{4}$/;function _c(l){const I=l.getTimezoneOffset()*6e4;return new Date(l.getTime()+I)}function qr(l){const I=/^\d{4}-\d{2}-\d{2}$/,t=/^\d{2}-\d{2}-\d{4}$/;if(I.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 no(l,I,t,b=[]){const m=typeof l=="string"?new Date(qr(l)):new Date(l);if(Number.isNaN(m.getTime()))return!1;if(I){const s=typeof I=="string"?new Date(qr(I)):new Date(I);if(m<s)return!1}if(t){const s=typeof t=="string"?new Date(qr(t)):new Date(t);if(m>s)return!1}return b.some(s=>{if(typeof s=="string"){const n=new Date(qr(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 Qt={validateAndUpdate(l,I,t){return cs.test(I)?{...l,[t?"from":"to"]:I}:l},isEndDateValid(l,I,t=!1){if(!l||!I)return!0;try{const[b,m,c]=l.split("-"),[o,s,n]=I.split("-"),e=new Date(Number(c),Number(m)-1,Number(b)),r=new Date(Number(n),Number(s)-1,Number(o));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,I){typeof l=="string"&&I(l)}},fs={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 Cc(l){if(!l||!/^\d{2}-\d{2}-\d{4}$/.test(l))return new Date(Number.NaN);const[I,t,b]=l.split("-").map(Number);return new Date(b,t-1,I)}function zt(l){if(!l)return"";const I=new Date(l),t=I.getFullYear(),b=String(I.getMonth()+1).padStart(2,"0");return`${String(I.getDate()).padStart(2,"0")}-${b}-${t}`}function jn(l,I){return new Date(l,I-1,1)}function Dn(l,I){return new Date(l,I,0)}function ds(l=new Date){const I=l.getFullYear(),t=l.getMonth()+1;let b=t-3,m=I;b<=0&&(b+=12,m-=1);const c=jn(m,b);let o=t-1,s=I;o<=0&&(o+=12,s-=1);const n=Dn(s,o);return{from:zt(c),to:zt(n)}}const hs={currentMonth:(l=new Date)=>{const I=l.getFullYear(),t=l.getMonth()+1;return{from:zt(jn(I,t)),to:zt(Dn(I,t))}},previousMonth:(l=new Date)=>{const I=l.getFullYear();let b=l.getMonth()+1-1,m=I;return b===0&&(b=12,m=I-1),{from:zt(jn(m,b)),to:zt(Dn(m,b))}},last3Months:ds,currentYear:(l=new Date)=>{const I=l.getFullYear();return{from:zt(new Date(I,0,1)),to:zt(new Date(I,11,31))}},previousYear:(l=new Date)=>{const I=l.getFullYear()-1;return{from:zt(new Date(I,0,1)),to:zt(new Date(I,11,31))}}};function Ac(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 I=new Date(l);return Number.isNaN(I.getTime())?l:I.toISOString()}const Ec={class:"columns justify-end"},Mc=y.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:I}){const t=l,b=I,m=y.useAttrs(),c=y.ref(),o=y.ref(t.date),s=y.ref(null),n=y.computed(()=>o.value),e=C=>{if(!C||C.length!==10)return!1;const T=/^(\d{2})-(\d{2})-(\d{4})$/,j=C.match(T);if(!j)return!1;const q=Number.parseInt(j[1],10),P=Number.parseInt(j[2],10),N=Number.parseInt(j[3],10);if(P<1||P>12||q<1||q>31)return!1;const V=new Date(N,P-1,q);return V.getFullYear()===N&&V.getMonth()===P-1&&V.getDate()===q},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})$/,j=C.match(T);if(!j)return"Format invalide. Utilisez JJ-MM-AAAA";const q=Number.parseInt(j[1],10),P=Number.parseInt(j[2],10),N=Number.parseInt(j[3],10),V=u(P);if(V)return V;const W=a(q,P,N);return W||(d(q,P,N)?null:"Date inexistante")},u=C=>C<1||C>12?"Le mois doit être entre 01 et 12":null,a=(C,T,j)=>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?i(C,j):null,i=(C,T)=>{const j=T%4===0&&T%100!==0||T%400===0;return j&&C>29?"Février a maximum 29 jours pour les années bissextiles":!j&&C>28?"Février a maximum 28 jours":null},d=(C,T,j)=>{const q=new Date(j,T-1,C);return q.getFullYear()===j&&q.getMonth()===T-1&&q.getDate()===C},h=()=>{n.value?s.value=r(n.value):s.value=null},f=y.computed(()=>C=>{const T=C.replaceAll("/","-");return no(T,t.minDate,t.maxDate,t.datesDisabled)}),g=C=>{e(C)&&(o.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(o.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&&(o.value="",s.value=null,b("update:date",""),b("update:modelValue",""))},k=y.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 y.watch(()=>[t.date],([C,T])=>{const j=T??C;j&&j!==o.value&&(o.value=j,h())}),(C,T)=>(y.openBlock(),y.createElementBlock("div",Ec,[y.createVNode(Kr,y.mergeProps(y.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:y.withCtx(()=>[y.createVNode(bt,{name:"event",class:"cursor-pointer","data-testid":"calendar-icon-picker"},{default:y.withCtx(()=>[y.createVNode(ls,{ref_key:"popupRef",ref:c,cover:"","transition-show":"scale","transition-hide":"scale"},{default:y.withCtx(()=>[y.createVNode(ss,{mask:"DD-MM-YYYY","model-value":o.value,options:f.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"])]))}}),Tc={class:"date-range-wrapper"},Rc={class:"date-range-flex"},Bc={key:0,class:"actions-group"},Ic={class:"date-range-popup"},Oc={key:0,class:"presets-section"},Fc={class:"presets-grid"},jc={class:"presets-row"},Dc={class:"presets-row"},Pc={class:"calendar-container"},Nc={class:"popup-actions"},Lc={key:0,class:"hint"},Vc={class:"text-warning text-caption q-mb-none"},qc=y.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:()=>fs},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:I,emit:t}){const b=l,m=t,c=y.ref({from:b.from,to:b.to}),o=y.ref(null),s=y.computed(()=>`from-date-${b.idCy}`),n=y.computed(()=>`to-date-${b.idCy}`),e=y.ref(null),r=y.computed(()=>b.shortcuts.map(R=>({...R,getRange:hs[R.id]}))),u=y.computed(()=>r.value.slice(0,3)),a=y.computed(()=>r.value.slice(3)),i=()=>{c.value=Qt.reset(),j.value=null,q.value=null,e.value=null,w(),m("clear")},d=()=>{o.value&&o.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)}},f=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),D=Number.parseInt(U[2],10),Y=Number.parseInt(U[3],10);if(D<1||D>12||Q<1||Q>31)return!1;const F=new Date(Y,D-1,Q);return F.getFullYear()===Y&&F.getMonth()===D-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),D=Number.parseInt(U[2],10),Y=Number.parseInt(U[3],10),F=p(D);if(F)return F;const B=k(Q,D,Y);return B||(T(Q,D,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},j=y.ref(null),q=y.ref(null),P=()=>{c.value.from?j.value=g(c.value.from):j.value=null},N=()=>{c.value.to?q.value=g(c.value.to):q.value=null},V=y.computed(()=>R=>{const z=R.replaceAll("/","-");return no(z,b.minDate,b.maxDate,b.datesDisabled)});let W=!1;const L=()=>{W=!0,c.value.from="",j.value=null,e.value=null,w(),setTimeout(()=>{W=!1},100)},A=()=>{W=!0,c.value.to="",q.value=null,e.value=null,w(),setTimeout(()=>{W=!1},100)},M=R=>{if(R===null||R===""){const z=c.value.from;c.value.from="",j.value=null,e.value=null,w(),!c.value.to&&z&&!c.value.from&&m("clear");return}Qt.handleInput(R,z=>{const U=c.value.from;if(z&&z.length===10){const Q=g(z);if(j.value=Q,Q){c.value.from=z,w();return}}else j.value=null;c.value=Qt.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="",q.value=null,e.value=null,w(),!c.value.from&&z&&!c.value.to&&m("clear");return}Qt.handleInput(R,z=>{const U=c.value.to;if(z&&z.length===10){const Q=g(z);if(q.value=Q,Q){c.value.to=z,w();return}}else q.value=null;c.value=Qt.validateAndUpdate(c.value,z,!1),h(),w(),!z&&!c.value.from&&U&&m("clear")})},v=()=>{setTimeout(()=>{c.value.from&&c.value.from.length===10?j.value=g(c.value.from):j.value=null,c.value.to&&c.value.to.length===10?q.value=g(c.value.to):q.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=Qt.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=y.computed(()=>[...b.required?[R=>!!R||b.requiredErrorMessage]:[],...b.rules,R=>{if(R&&!f(R))return j.value||b.invalidDateErrorMessage||"Date invalide!";const z=c.value.to;if(!R||!z)return!0;const U=Qt.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=y.computed(()=>[...b.required?[R=>!!R||b.requiredErrorMessage]:[],...b.rules,R=>{if(R&&!f(R))return q.value||b.invalidDateErrorMessage||"Date invalide!";const z=c.value.from;if(!R||!z)return!0;const U=Qt.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"}]);y.watch([()=>c.value.from,()=>c.value.to],([R,z],[U,Q])=>{!R&&!z&&(U||Q)&&!W&&(j.value=null,q.value=null,e.value=null,m("clear"))}),y.watch(()=>b.from,R=>{R!==c.value.from&&(c.value.from=R,P(),h())}),y.watch(()=>b.to,R=>{R!==c.value.to&&(c.value.to=R,N(),h())}),I({setDateRange:R=>{c.value={from:R.from,to:R.to},P(),N(),h(),w()},getCurrentRange:()=>({from:c.value.from,to:c.value.to}),resetDate:()=>{i()}});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 y.onMounted(()=>{P(),N(),h()}),(R,z)=>(y.openBlock(),y.createElementBlock("div",Tc,[y.createElementVNode("div",Rc,[y.createVNode(Kr,y.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"]),y.createVNode(Kr,y.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?y.createCommentVNode("",!0):(y.openBlock(),y.createElementBlock("div",Bc,[y.createVNode(bt,{name:"event",size:"30px",class:"cursor-pointer calendar-icon",style:{opacity:"0.55"},"data-cy":"calendar-icon-range"},{default:y.withCtx(()=>[y.createVNode(ls,{cover:"","transition-show":"scale","transition-hide":"scale",ref_key:"popupRef",ref:o},{default:y.withCtx(()=>[y.createElementVNode("div",Ic,[R.hideShortcuts?y.createCommentVNode("",!0):(y.openBlock(),y.createElementBlock("div",Oc,[z[0]||(z[0]=y.createElementVNode("div",{class:"presets-title"},"Périodes rapides :",-1)),y.createElementVNode("div",Fc,[y.createElementVNode("div",jc,[(y.openBlock(!0),y.createElementBlock(y.Fragment,null,y.renderList(u.value,U=>(y.openBlock(),y.createBlock(ct,{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))]),y.createElementVNode("div",Dc,[(y.openBlock(!0),y.createElementBlock(y.Fragment,null,y.renderList(a.value,U=>(y.openBlock(),y.createBlock(ct,{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))])])])),y.createElementVNode("div",Pc,[y.createVNode(ss,{"model-value":c.value,mask:"DD-MM-YYYY","today-btn":"",range:"","data-cy":"date-picker-range",locale:R.locale,options:V.value,events:R.highlightEvents,"event-color":"warning",disable:R.disabled,"onUpdate:modelValue":x,onRangeEnd:v,"no-unset":""},null,8,["model-value","locale","options","events","disable"])]),y.createElementVNode("div",Nc,[y.createVNode(ct,{label:R.resetLabel,color:"grey-7",flat:"",dense:"",onClick:i,class:"q-mr-sm"},null,8,["label"]),y.createVNode(ct,{label:R.closeLabel,color:"primary",flat:"",dense:"",onClick:d},null,8,["label"])])])]),_:1},512)]),_:1})]))]),R.startDateHint?(y.openBlock(),y.createElementBlock("div",Lc,[y.createElementVNode("p",Vc,y.toDisplayString(R.startDateHint),1)])):y.createCommentVNode("",!0)]))}}),ps=Xt(qc,[["__scopeId","data-v-6efc1985"]]);var lt=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function zc(l){return l&&l.__esModule&&Object.prototype.hasOwnProperty.call(l,"default")?l.default:l}function pn(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 ui={exports:{}};/*! ExcelJS 19-10-2023 */var ta;function Uc(){return ta||(ta=1,function(l,I){(function(t){l.exports=t()})(function(){return function t(b,m,c){function o(e,r){if(!m[e]){if(!b[e]){var u=typeof pn=="function"&&pn;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 i=m[e]={exports:{}};b[e][0].call(i.exports,function(d){return o(b[e][1][d]||d)},i,i.exports,t,b,m,c)}return m[e].exports}for(var s=typeof pn=="function"&&pn,n=0;n<c.length;n++)o(c[n]);return o}({1:[function(t,b,m){const c=t("fs"),o=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(i){this.workbook=i,this.worksheet=null}async readFile(i,d){if(d=d||{},!await u(i))throw new Error("File not found: "+i);const h=c.createReadStream(i),f=await this.read(h,d);return h.close(),f}read(i,d){return d=d||{},new Promise((h,f)=>{const g=this.workbook.addWorksheet(d.sheetName),p=d.dateFormats||["YYYY-MM-DD[T]HH:mm:ssZ","YYYY-MM-DD[T]HH:mm:ss","MM-DD-YYYY","YYYY-MM-DD"],k=d.map||function(T){if(T==="")return null;const j=Number(T);if(!Number.isNaN(j)&&j!==1/0)return j;const q=p.reduce((N,V)=>{if(N)return N;const W=e(T,V,!0);return W.isValid()?W:null},null);if(q)return new Date(q.valueOf());const P=a[T];return P!==void 0?P:T},C=o.parse(d.parserOptions).on("data",T=>{g.addRow(T.map(k))}).on("end",()=>{C.emit("worksheet",g)});C.on("worksheet",h).on("error",f),i.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(i,d){return new Promise((h,f)=>{d=d||{};const g=this.workbook.getWorksheet(d.sheetName||d.sheetId),p=o.format(d.formatterOptions);i.on("finish",()=>{h()}),p.on("error",f),p.pipe(i);const{dateFormat:k,dateUTC:C}=d,T=d.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}),j=d.includeEmptyRows===void 0||d.includeEmptyRows;let q=1;g&&g.eachRow((P,N)=>{if(j)for(;q++<N-1;)p.write([]);const{values:V}=P;V.shift(),p.write(V.map(T)),q=N}),p.end()})}writeFile(i,d){const h={encoding:(d=d||{}).encoding||"utf8"},f=c.createWriteStream(i,h);return this.write(f,d)}async writeBuffer(i){const d=new r;return await this.write(d,i),d.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 o{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 o||n==null?n:new o(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=o},{"../utils/col-cache":19}],3:[function(t,b,m){const c=t("../utils/col-cache"),o=t("../utils/under-dash"),s=t("./enums"),{slideFormula:n}=t("../utils/shared-formula"),e=t("./note");class r{constructor(i,d,h){if(!i||!d)throw new Error("A Cell needs a Row");this._row=i,this._column=d,c.validateAddress(h),this._address=h,this._value=u.create(r.Types.Null,this),this.style=this._mergeStyle(i.style,d.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(i){this.style.numFmt=i}get font(){return this.style.font}set font(i){this.style.font=i}get alignment(){return this.style.alignment}set alignment(i){this.style.alignment=i}get border(){return this.style.border}set border(i){this.style.border=i}get fill(){return this.style.fill}set fill(i){this.style.fill=i}get protection(){return this.style.protection}set protection(i){this.style.protection=i}_mergeStyle(i,d,h){const f=i&&i.numFmt||d&&d.numFmt;f&&(h.numFmt=f);const g=i&&i.font||d&&d.font;g&&(h.font=g);const p=i&&i.alignment||d&&d.alignment;p&&(h.alignment=p);const k=i&&i.border||d&&d.border;k&&(h.border=k);const C=i&&i.fill||d&&d.fill;C&&(h.fill=C);const T=i&&i.protection||d&&d.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(i,d){this._value.release(),this._value=u.create(r.Types.Merge,this,i),d||(this.style=i.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(i){return this._value.type===r.Types.Merge&&this._value.isMergedTo(i)}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(i){this.type!==r.Types.Merge?(this._value.release(),this._value=u.create(u.getType(i),this,i)):this._value.master.value=i}get note(){return this._comment&&this._comment.note}set note(i){this._comment=new e(i)}get text(){return this._value.toString()}get html(){return o.escapeHtml(this.text)}toString(){return this.text}_upgradeToHyperlink(i){this.type===r.Types.String&&(this._value=u.create(r.Types.Hyperlink,this,{text:this._value.value,hyperlink:i}))}get formula(){return this._value.formula}get result(){return this._value.result}get formulaType(){return this._value.formulaType}get fullAddress(){const{worksheet:i}=this._row;return{sheetName:i.name,address:this.address,row:this.row,col:this.col}}get name(){return this.names[0]}set name(i){this.names=[i]}get names(){return this.workbook.definedNames.getNamesEx(this.fullAddress)}set names(i){const{definedNames:d}=this.workbook;d.removeAllNames(this.fullAddress),i.forEach(h=>{d.addEx(this.fullAddress,h)})}addName(i){this.workbook.definedNames.addEx(this.fullAddress,i)}removeName(i){this.workbook.definedNames.removeEx(this.fullAddress,i)}removeAllNames(){this.workbook.definedNames.removeAllNames(this.fullAddress)}get _dataValidations(){return this.worksheet.dataValidations}get dataValidation(){return this._dataValidations.find(this.address)}set dataValidation(i){this._dataValidations.add(this.address,i)}get model(){const{model:i}=this._value;return i.style=this.style,this._comment&&(i.comment=this._comment.model),i}set model(i){if(this._value.release(),this._value=u.create(i.type,this),this._value.model=i,i.comment)switch(i.comment.type){case"note":this._comment=e.fromModel(i.comment)}i.style?this.style=i.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,i){this.model={address:a.address,type:r.Types.Number,value:i}}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,i){this.model={address:a.address,type:r.Types.String,value:i}}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,i){this.model={address:a.address,type:r.Types.Date,value:i}}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,i){this.model={address:a.address,type:r.Types.Hyperlink,text:i?i.text:void 0,hyperlink:i?i.hyperlink:void 0},i&&i.tooltip&&(this.model.tooltip=i.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,i){this.cell=a,this.model={address:a.address,type:r.Types.Formula,shareType:i?i.shareType:void 0,ref:i?i.ref:void 0,formula:i?i.formula:void 0,sharedFormula:i?i.sharedFormula:void 0,result:i?i.result:void 0}}_copyModel(a){const i={},d=h=>{const f=a[h];f&&(i[h]=f)};return d("formula"),d("result"),d("ref"),d("shareType"),d("sharedFormula"),i}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,i=a.findCell(this.model.sharedFormula);this._translatedFormula=i&&n(i.formula,i.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,i){this.model={address:a.address,type:r.Types.Merge,master:i?i.address:void 0},this._master=i,i&&i.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,i){this.model={address:a.address,type:r.Types.String,value:JSON.stringify(i),rawValue:i}}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,i){this.model={address:a.address,type:r.Types.SharedString,value:i}}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,i){this.model={address:a.address,type:r.Types.String,value:i}}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,i){this.model={address:a.address,type:r.Types.Boolean,value:i}}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,i){this.model={address:a.address,type:r.Types.Error,value:i}}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,i)=>(a[i.t]=i.f,a),[]),create(a,i,d){const h=this.types[a];if(!h)throw new Error("Could not create Value of type "+a);return new h(i,d)}};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"),o=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,(i,d)=>{u(i.getCell(a),d)})}get values(){const r=[];return this.eachCell((u,a)=>{u&&u.type!==o.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((i,d)=>{this._worksheet.getCell(d+a,u).value=i})}_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((i,d)=>{i.isDefault?a&&(a=null):a&&i.equivalentTo(a)?a.max=d+1:(a={min:d+1,max:d+1,width:i.width!==void 0?i.width:9,style:i.style,isCustomWidth:i.isCustomWidth,hidden:i.hidden,outlineLevel:i.outlineLevel,collapsed:i.collapsed},u.push(a))}),u.length?u:void 0}static fromModel(r,u){const a=[];let i=1,d=0;for(u=(u=u||[]).sort(function(h,f){return h.min-f.min});d<u.length;){const h=u[d++];for(;i<h.min;)a.push(new n(r,i++));for(;i<=h.max;)a.push(new n(r,i++,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,o){return this.model[c]=o}find(c){return this.model[c]}remove(c){this.model[c]=void 0}}},{}],6:[function(t,b,m){const c=t("../utils/under-dash"),o=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=o.decodeEx(r);this.addEx(a,u)}addEx(r,u){const a=this.getMatrix(u);if(r.top)for(let i=r.left;i<=r.right;i++)for(let d=r.top;d<=r.bottom;d++){const h={sheetName:r.sheetName,address:o.n2l(i)+d,row:d,col:i};a.addCellEx(h)}else a.addCellEx(r)}remove(r,u){const a=o.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(i=>{r(a,i)})})}getNames(r){return this.getNamesEx(o.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,i=new n(u.row,u.col,u.row,u.col,a);let d,h;function f(p,k){const C=r.findCellAt(a,p,u.col);return!(!C||!C.mark)&&(i[k]=p,C.mark=!1,!0)}for(h=u.row-1;f(h,"top");h--);for(h=u.row+1;f(h,"bottom");h++);function g(p,k){const C=[];for(h=i.top;h<=i.bottom;h++){const T=r.findCellAt(a,h,p);if(!T||!T.mark)return!1;C.push(T)}i[k]=p;for(let T=0;T<C.length;T++)C[T].mark=!1;return!0}for(d=u.col-1;g(d,"left");d--);for(d=u.col+1;g(d,"right");d++);return i}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,i,d)=>{a&&(a.row===i&&a.col===d||(a.row=i,a.col=d,a.address=o.n2l(d)+i))})}spliceRows(r,u,a,i){c.each(this.matrixMap,d=>{d.spliceRows(r,u,a,i),this.normaliseMatrix(d,r)})}spliceColumns(r,u,a,i){c.each(this.matrixMap,d=>{d.spliceColumns(r,u,a,i),this.normaliseMatrix(d,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 i=u[a.name]=new s;a.ranges.forEach(d=>{e.test(d.split("!").pop()||"")&&i.addCell(d)})})}}},{"../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"),o=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 o(this.worksheet,{col:a.left,row:a.top},-1),br:new o(this.worksheet,{col:a.right,row:a.bottom},0),editAs:"oneCell"}}else this.range={tl:new o(this.worksheet,r.tl,0),br:r.br&&new o(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 o{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({},o.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 o;return e.model=n,e}}o.DEFAULT_CONFIGS={note:{margins:{insetmode:"auto",inset:[.13,.13,.25,.25]},protection:{locked:"True",lockText:"True"},editAs:"absolute"}},b.exports=o},{"../utils/under-dash":26}],10:[function(t,b,m){const c=t("../utils/col-cache");class o{constructor(){this.decode(arguments)}setTLBR(n,e,r,u,a){if(arguments.length<4){const i=c.decodeAddress(n),d=c.decodeAddress(e);this.model={top:Math.min(i.row,d.row),left:Math.min(i.col,d.col),bottom:Math.max(i.row,d.row),right:Math.max(i.col,d.col),sheetName:r},this.setTLBR(i.row,i.col,d.row,d.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 o)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=o},{"../utils/col-cache":19}],11:[function(t,b,m){const c=t("../utils/under-dash"),o=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,i=new Array(a>2?a-2:0),d=2;d<a;d++)i[d-2]=arguments[d];const h=i.length-r,f=this._cells.length;let g,p,k;if(h<0)for(g=e+i.length;g<=f;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=f;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<i.length;g++)k=this.getCell(e+g),k.value=i[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!==o.ValueType.Null&&r(u,a+1)})}addPageBreak(e,r){const u=this._worksheet,a=Math.max(0,e-1)||0,i=Math.max(0,r-1)||16838,d={id:this._number,max:i,man:1};a&&(d.min=a),u.rowBreaks.push(d)}get values(){const e=[];return this._cells.forEach(r=>{r&&r.type!==o.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!==o.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!==o.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 i=a.model;i&&((!r||r>a.col)&&(r=a.col),u<a.col&&(u=a.col),e.push(i))}}),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:i}=r,d=r.col+1;a={row:i,col:d,address:s.encodeAddress(i,d),$col$row:`$${s.n2l(d)}$${i}`}}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 o{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,f,g)=>{h[f]===void 0&&(h[f]=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,f)=>{if(!h)throw new Error(f)};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:i,tableHeight:d}=this;s.autoFilterRef=c.encode(r,u,r+i-1,u+a-1),s.tableRef=c.encode(r,u,r+d-1,u+a-1),s.columns.forEach((h,f)=>{e(h.name,`Column ${f} must have a name`),f===0?n(h,"totalsRowLabel","Total"):(n(h,"totalsRowFunction","none"),h.totalsRowFormula=this.getFormula(h))})}store(){const s=(i,d)=>{d&&Object.keys(d).forEach(h=>{i[h]=d[h]})},{worksheet:n,table:e}=this,{row:r,col:u}=e.tl;let a=0;if(e.headerRow){const i=n.getRow(r+a++);e.columns.forEach((d,h)=>{const{style:f,name:g}=d,p=i.getCell(u+h);p.value=g,s(p,f)})}if(e.rows.forEach(i=>{const d=n.getRow(r+a++);i.forEach((h,f)=>{const g=d.getCell(u+f);g.value=h,s(g,e.columns[f].style)})}),e.totalsRow){const i=n.getRow(r+a++);e.columns.forEach((d,h)=>{const f=i.getCell(u+h);if(h===0)f.value=d.totalsRowLabel;else{const g=this.getFormula(d);f.value=g?{formula:d.totalsRowFormula,result:d.totalsRowResult}:null}s(f,d.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((i,d)=>{a.getCell(r+d).value=i.name})}if(n.rows.forEach(a=>{const i=s.getRow(e+u++);a.forEach((d,h)=>{i.getCell(r+h).value=d})}),n.totalsRow){const a=s.getRow(e+u++);n.columns.forEach((i,d)=>{const h=a.getCell(r+d);d===0?h.value=i.totalsRowLabel:this.getFormula(i)&&(h.value={formula:i.totalsRowFormula,result:i.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 o(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"),o=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 o}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,f)=>(f&&f.orderNo)>h?f.orderNo:h,0),i=Object.assign({},r,{id:u,name:e,orderNo:a+1,workbook:this}),d=new c(i);return this._worksheets[u]=d,d}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:i}=r,d=e.sheets&&e.sheets.findIndex(h=>h.id===u);(this._worksheets[u]=new c({id:u,name:a,orderNo:d,state:i,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"),o=t("../utils/col-cache"),s=t("./range"),n=t("./row"),e=t("./column"),r=t("./enums"),u=t("./image"),a=t("./table"),i=t("./data-validations"),d=t("../utils/encryptor"),{copyStyle:h}=t("../utils/copy-style");b.exports=class{constructor(f){f=f||{},this._workbook=f.workbook,this.id=f.id,this.orderNo=f.orderNo,this.name=f.name,this.state=f.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},f.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:!(!f.pageSetup||!f.pageSetup.fitToWidth&&!f.pageSetup.fitToHeight||f.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},f.pageSetup),this.headerFooter=Object.assign({},{differentFirst:!1,differentOddEven:!1,oddHeader:null,oddFooter:null,evenHeader:null,evenFooter:null,firstHeader:null,firstFooter:null},f.headerFooter),this.dataValidations=new i,this.views=f.views||[],this.autoFilter=f.autoFilter||null,this._media=[],this.sheetProtection=null,this.tables={},this.conditionalFormattings=[]}get name(){return this._name}set name(f){if(f===void 0&&(f="sheet"+this.id),this._name!==f){if(typeof f!="string")throw new Error("The name has to be a string.");if(f==="")throw new Error("The name can't be empty.");if(f==="History")throw new Error('The name "History" is protected. Please use a different name.');if(/[*?:/\\[\]]/.test(f))throw new Error(`Worksheet name ${f} cannot include any of the following characters: * ? : \\ / [ ]`);if(/(^')|('$)/.test(f))throw new Error("The first or last character of worksheet name cannot be a single quotation mark: "+f);if(f&&f.length>31&&(console.warn(`Worksheet name ${f} exceeds 31 chars. This will be truncated`),f=f.substring(0,31)),this._workbook._worksheets.find(g=>g&&g.name.toLowerCase()===f.toLowerCase()))throw new Error("Worksheet name already exists: "+f);this._name=f}}get workbook(){return this._workbook}destroy(){this._workbook.removeWorksheetEx(this)}get dimensions(){const f=new s;return this._rows.forEach(g=>{if(g){const p=g.dimensions;p&&f.expand(g.number,p.min,g.number,p.max)}}),f}get columns(){return this._columns}set columns(f){this._headerRowCount=f.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=[];f.forEach(k=>{const C=new e(this,g++,!1);p.push(C),C.defn=k})}getColumnKey(f){return this._keys[f]}setColumnKey(f,g){this._keys[f]=g}deleteColumnKey(f){delete this._keys[f]}eachColumnKey(f){c.each(this._keys,f)}getColumn(f){if(typeof f=="string"){const g=this._keys[f];if(g)return g;f=o.l2n(f)}if(this._columns||(this._columns=[]),f>this._columns.length){let g=this._columns.length+1;for(;g<=f;)this._columns.push(new e(this,g++))}return this._columns[f-1]}spliceColumns(f,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 V=[f,g];C.forEach(L=>{V.push(L[N]||null)});const W=this.getRow(N+1);W.splice.apply(W,V)}else this._rows.forEach(N=>{N&&N.splice(f,g)});const j=C.length-g,q=f+g,P=this._columns.length;if(j<0)for(let N=f+C.length;N<=P;N++)this.getColumn(N).defn=this.getColumn(N-j).defn;else if(j>0)for(let N=P;N>=q;N--)this.getColumn(N+j).defn=this.getColumn(N).defn;for(let N=f;N<f+C.length;N++)this.getColumn(N).defn=null;this.workbook.definedNames.spliceColumns(this.name,f,g,C.length)}get lastColumn(){return this.getColumn(this.columnCount)}get columnCount(){let f=0;return this.eachRow(g=>{f=Math.max(f,g.cellCount)}),f}get actualColumnCount(){const f=[];let g=0;return this.eachRow(p=>{p.eachCell(k=>{let{col:C}=k;f[C]||(f[C]=!0,g++)})}),g}_commitRow(){}get _lastRowNumber(){const f=this._rows;let g=f.length;for(;g>0&&f[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(f){return this._rows[f-1]}findRows(f,g){return this._rows.slice(f-1,f-1+g)}get rowCount(){return this._lastRowNumber}get actualRowCount(){let f=0;return this.eachRow(()=>{f++}),f}getRow(f){let g=this._rows[f-1];return g||(g=this._rows[f-1]=new n(this,f)),g}getRows(f,g){if(g<1)return;const p=[];for(let k=f;k<f+g;k++)p.push(this.getRow(k));return p}addRow(f){let g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"n";const p=this._nextRow,k=this.getRow(p);return k.values=f,this._setStyleOption(p,g[0]==="i"?g:"n"),k}addRows(f){let g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"n";const p=[];return f.forEach(k=>{p.push(this.addRow(k,g))}),p}insertRow(f,g){let p=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"n";return this.spliceRows(f,0,g),this._setStyleOption(f,p),this.getRow(f)}insertRows(f,g){let p=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"n";if(this.spliceRows(f,0,...g),p!=="n")for(let k=0;k<g.length;k++)p[0]==="o"&&this.findRow(g.length+f+k)!==void 0?this._copyStyle(g.length+f+k,f+k,p[1]==="+"):p[0]==="i"&&this.findRow(f-1)!==void 0&&this._copyStyle(f-1,f+k,p[1]==="+");return this.getRows(f,g.length)}_setStyleOption(f){let g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"n";g[0]==="o"&&this.findRow(f+1)!==void 0?this._copyStyle(f+1,f,g[1]==="+"):g[0]==="i"&&this.findRow(f-1)!==void 0&&this._copyStyle(f-1,f,g[1]==="+")}_copyStyle(f,g){let p=arguments.length>2&&arguments[2]!==void 0&&arguments[2];const k=this.getRow(f),C=this.getRow(g);C.style=h(k.style),k.eachCell({includeEmpty:p},(T,j)=>{C.getCell(j).style=h(T.style)}),C.height=k.height}duplicateRow(f,g){let p=arguments.length>2&&arguments[2]!==void 0&&arguments[2];const k=this._rows[f-1],C=new Array(g).fill(k.values);this.spliceRows(f+1,p?0:g,...C);for(let T=0;T<g;T++){const j=this._rows[f+T];j.style=k.style,j.height=k.height,k.eachCell({includeEmpty:!0},(q,P)=>{j.getCell(P).style=q.style})}}spliceRows(f,g){const p=f+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 j=C.length,q=j-g,P=this._rows.length;let N,V;if(q<0)for(f===P&&(this._rows[P-1]=void 0),N=p;N<=P;N++)if(V=this._rows[N-1],V){const W=this.getRow(N+q);W.values=V.values,W.style=V.style,W.height=V.height,V.eachCell({includeEmpty:!0},(L,A)=>{W.getCell(A).style=L.style}),this._rows[N-1]=void 0}else this._rows[N+q-1]=void 0;else if(q>0)for(N=P;N>=p;N--)if(V=this._rows[N-1],V){const W=this.getRow(N+q);W.values=V.values,W.style=V.style,W.height=V.height,V.eachCell({includeEmpty:!0},(L,A)=>{if(W.getCell(A).style=L.style,L._value.constructor.name==="MergeValue"){const M=this.getRow(L._row._number+j).getCell(A),_=L._value._master,v=this.getRow(_._row._number+j).getCell(_._column._number);M.merge(v)}})}else this._rows[N+q-1]=void 0;for(N=0;N<j;N++){const W=this.getRow(f+N);W.style={},W.values=C[N]}this.workbook.definedNames.spliceRows(this.name,f,g,j)}eachRow(f,g){if(g||(g=f,f=void 0),f&&f.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 f=[];return this._rows.forEach(g=>{g&&(f[g.number]=g.values)}),f}findCell(f,g){const p=o.getAddress(f,g),k=this._rows[p.row-1];return k?k.findCell(p.col):void 0}getCell(f,g){const p=o.getAddress(f,g);return this.getRow(p.row).getCellEx(p)}mergeCells(){for(var f=arguments.length,g=new Array(f),p=0;p<f;p++)g[p]=arguments[p];const k=new s(g);this._mergeCellsInternal(k)}mergeCellsWithoutStyle(){for(var f=arguments.length,g=new Array(f),p=0;p<f;p++)g[p]=arguments[p];const k=new s(g);this._mergeCellsInternal(k,!0)}_mergeCellsInternal(f,g){c.each(this._merges,k=>{if(k.intersects(f))throw new Error("Cannot merge already merged cells")});const p=this.getCell(f.top,f.left);for(let k=f.top;k<=f.bottom;k++)for(let C=f.left;C<=f.right;C++)(k>f.top||C>f.left)&&this.getCell(k,C).merge(p,g);this._merges[p.address]=f}_unMergeMaster(f){const g=this._merges[f.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[f.address]}}get hasMerges(){return c.some(this._merges,Boolean)}unMergeCells(){for(var f=arguments.length,g=new Array(f),p=0;p<f;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 j=this.findCell(C,T);j&&(j.type===r.ValueType.Merge?this._unMergeMaster(j.master):this._merges[j.address]&&this._unMergeMaster(j))}}fillFormula(f,g,p){let k=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"shared";const C=o.decode(f),{top:T,left:j,bottom:q,right:P}=C,N=P-j+1,V=o.encodeAddress(T,j),W=k==="shared";let L;L=typeof p=="function"?p:Array.isArray(p)?Array.isArray(p[0])?(M,_)=>p[M-T][_-j]:(M,_)=>p[(M-T)*N+(_-j)]:()=>{};let A=!0;for(let M=T;M<=q;M++)for(let _=j;_<=P;_++)A?(this.getCell(M,_).value={shareType:k,formula:g,ref:f,result:L(M,_)},A=!1):this.getCell(M,_).value=W?{sharedFormula:V,result:L(M,_)}:L(M,_)}addImage(f,g){const p={type:"image",imageId:f,range:g};this._media.push(new u(this,p))}getImages(){return this._media.filter(f=>f.type==="image")}addBackgroundImage(f){const g={type:"background",imageId:f};this._media.push(new u(this,g))}getBackgroundImageId(){const f=this._media.find(g=>g.type==="background");return f&&f.imageId}protect(f,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),f&&(this.sheetProtection.algorithmName="SHA-512",this.sheetProtection.saltValue=d.randomBytes(16).toString("base64"),this.sheetProtection.spinCount=g&&"spinCount"in g?g.spinCount:1e5,this.sheetProtection.hashValue=d.convertPasswordToHash(f,"SHA512",this.sheetProtection.saltValue,this.sheetProtection.spinCount)),g&&(this.sheetProtection=Object.assign(this.sheetProtection,g),!f&&"spinCount"in g&&delete this.sheetProtection.spinCount),p()})}unprotect(){this.sheetProtection=null}addTable(f){const g=new a(this,f);return this.tables[f.name]=g,g}getTable(f){return this.tables[f]}removeTable(f){delete this.tables[f]}getTables(){return Object.values(this.tables)}addConditionalFormatting(f){this.conditionalFormattings.push(f)}removeConditionalFormatting(f){typeof f=="number"?this.conditionalFormattings.splice(f,1):this.conditionalFormattings=f instanceof Function?this.conditionalFormattings.filter(f):[]}get tabColor(){return console.trace("worksheet.tabColor property is now deprecated. Please use worksheet.properties.tabColor"),this.properties.tabColor}set tabColor(f){console.trace("worksheet.tabColor property is now deprecated. Please use worksheet.properties.tabColor"),this.properties.tabColor=f}get model(){const f={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};f.cols=e.toModel(this.columns);const g=f.rows=[],p=f.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))}),f.merges=[],c.each(this._merges,k=>{f.merges.push(k.range)}),f}_parseRows(f){this._rows=[],f.rows.forEach(g=>{const p=new n(this,g.number);this._rows[p.number-1]=p,p.model=g})}_parseMergeCells(f){c.each(f.mergeCells,g=>{this.mergeCellsWithoutStyle(g)})}set model(f){this.name=f.name,this._columns=e.fromModel(this,f.cols),this._parseRows(f),this._parseMergeCells(f),this.dataValidations=new i(f.dataValidations),this.properties=f.properties,this.pageSetup=f.pageSetup,this.headerFooter=f.headerFooter,this.views=f.views,this.autoFilter=f.autoFilter,this._media=f.media.map(g=>new u(this,g)),this.sheetProtection=f.sheetProtection,this.tables=f.tables.reduce((g,p)=>{const k=new a;return k.model=p,g[p.name]=k,g},{}),this.conditionalFormattings=f.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")},o=t("./doc/enums");Object.keys(o).forEach(s=>{c[s]=o[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(o){return typeof o=="string"?o:c?c.decode(o):o.toString()}},{}],17:[function(t,b,m){const c=typeof TextEncoder>"u"?null:new TextEncoder("utf-8"),{Buffer:o}=t("buffer");m.stringToBuffer=function(s){return typeof s!="string"?s:c?o.from(c.encode(s).buffer):o.from(s)}},{buffer:220}],18:[function(t,b,m){const c=t("./under-dash"),o=t("./col-cache");b.exports=class{constructor(s){this.template=s,this.sheets={}}addCell(s){this.addCellEx(o.decodeEx(s))}getCell(s){return this.findCellEx(o.decodeEx(s),!0)}findCell(s){return this.findCellEx(o.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:o.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,i)=>{a&&n(a,u,i)})})}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 i=0;i<r;i++)a.push([]);u.splice(n,e,...a)}}spliceColumns(s,n,e,r){const u=this.sheets[s];if(u){const a=[];for(let i=0;i<r;i++)a.push(null);c.each(u,i=>{i.splice(n,e,...a)})}}}},{"./col-cache":19,"./under-dash":26}],19:[function(t,b,m){const c=/^[A-Z]+\d+$/,o={_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,i=1;if(s>=4)throw new Error("Out of bounds. Excel supports columns from 1 to 16384");if(this._l2nFill<1&&s>=1){for(;i<=26;)n=this._dictionary[i-1],this._n2l[i]=n,this._l2n[n]=i,i++;this._l2nFill=1}if(this._l2nFill<2&&s>=2){for(i=27;i<=702;)e=i-27,r=e%26,u=Math.floor(e/26),n=this._dictionary[u]+this._dictionary[r],this._n2l[i]=n,this._l2n[n]=i,i++;this._l2nFill=2}if(this._l2nFill<3&&s>=3){for(i=703;i<=16384;)e=i-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[i]=n,this._l2n[n]=i,i++;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,i="",d=0;for(let f,g=0;g<s.length;g++)if(f=s.charCodeAt(g),!a&&f>=65&&f<=90)e=!0,r+=s[g],u=26*u+f-64;else if(f>=48&&f<=57)a=!0,i+=s[g],d=10*d+f-48;else if(a&&e&&f!==36)break;if(e){if(u>16384)throw new Error("Out of bounds. Invalid column letter: "+r)}else u=void 0;a||(d=void 0);const h={address:s=r+i,col:u,row:d,$col$row:`$${r}$${i}`};return u<=100&&d<=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 i=this.decodeAddress(u[0]),d=this.decodeAddress(u[1]);const h=Math.min(i.row,d.row),f=Math.min(i.col,d.col),g=Math.max(i.row,d.row),p=Math.max(i.col,d.col);return i=this.n2l(f)+h,d=this.n2l(p)+g,{top:h,left:f,bottom:g,right:p,sheetName:e,tl:{address:i,col:f,row:h,$col$row:`$${this.n2l(f)}$${h}`,sheetName:e},br:{address:d,col:p,row:g,$col$row:`$${this.n2l(p)}$${g}`,sheetName:e},dimensions:`${i}:${d}`}}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)=>o.n2l(n)+s,encode(){switch(arguments.length){case 2:return o.encodeAddress(arguments[0],arguments[1]);case 4:return`${o.encodeAddress(arguments[0],arguments[1])}:${o.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,[i,d]=n;return i>=e&&i<=u&&d>=r&&d<=a}};b.exports=o},{}],20:[function(t,b,m){const c=(s,n)=>({...s,...n.reduce((e,r)=>(s[r]&&(e[r]={...s[r]}),e),{})}),o=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 o(s,e,"font",["color"]),o(s,e,"alignment"),o(s,e,"protection"),s.border&&(o(s,e,"border"),o(s.border,e.border,"top",["color"]),o(s.border,e.border,"left",["color"]),o(s.border,e.border,"bottom",["color"]),o(s.border,e.border,"right",["color"]),o(s.border,e.border,"diagonal",["color"])),s.fill&&(o(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 o=t("crypto"),s={hash(n){const e=o.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(),o.getHashes().indexOf(e)<0)throw new Error(`Hash algorithm '${e}' not supported!`);const a=c.from(n,"utf16le");let i=this.hash(e,c.from(r,"base64"),a);for(let d=0;d<u;d++){const h=c.alloc(4);h.writeUInt32LE(d,0),i=this.hash(e,i,h)}return i.toString("base64")},randomBytes:n=>o.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:o}=t("readable-stream"),{bufferToString:s}=t("./browser-buffer-decode");b.exports=async function*(n){n.pipe&&!n[Symbol.asyncIterator]&&(n=n.pipe(new o));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"),o=/(([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(o,(i,d,h,f,g)=>{if(g)return i;const p=s.exec(f);if(p){const k=p[1],C=p[2].toUpperCase(),T=p[3],j=p[4];if(C.length>3||C.length===3&&C>"XFD")return i;let q=c.l2n(C),P=parseInt(j,10);return k||(q+=a.col-u.col),T||(P+=a.row-u.row),(d||"")+(k||"")+c.n2l(q)+(T||"")+P}return i})}}},{"./col-cache":19}],24:[function(t,b,m){(function(c,o){(function(){const s=t("readable-stream"),n=t("./utils"),e=t("./string-buf");class r{constructor(f,g){this._data=f,this._encoding=g}get length(){return this.toBuffer().length}copy(f,g,p,k){return this.toBuffer().copy(f,g,p,k)}toBuffer(){return this._buffer||(this._buffer=o.from(this._data,this._encoding)),this._buffer}}class u{constructor(f){this._data=f}get length(){return this._data.length}copy(f,g,p,k){return this._data._buf.copy(f,g,p,k)}toBuffer(){return this._data.toBuffer()}}class a{constructor(f){this._data=f}get length(){return this._data.length}copy(f,g,p,k){this._data.copy(f,g,p,k)}toBuffer(){return this._data}}class i{constructor(f){this.size=f,this.buffer=o.alloc(f),this.iRead=0,this.iWrite=0}toBuffer(){if(this.iRead===0&&this.iWrite===this.size)return this.buffer;const f=o.alloc(this.iWrite-this.iRead);return this.buffer.copy(f,0,this.iRead,this.iWrite),f}get length(){return this.iWrite-this.iRead}get eod(){return this.iRead===this.iWrite}get full(){return this.iWrite===this.size}read(f){let g;return f===0?null:f===void 0||f>=this.length?(g=this.toBuffer(),this.iRead=this.iWrite,g):(g=o.alloc(f),this.buffer.copy(g,0,this.iRead,f),this.iRead+=f,g)}write(f,g,p){const k=Math.min(p,this.size-this.iWrite);return f.copy(this.buffer,this.iWrite,g,g+k),this.iWrite+=k,k}}const d=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(d,s.Duplex,{toBuffer(){switch(this.buffers.length){case 0:return null;case 1:return this.buffers[0].toBuffer();default:return o.concat(this.buffers.map(h=>h.toBuffer()))}},_getWritableBuffer(){if(this.buffers.length){const f=this.buffers[this.buffers.length-1];if(!f.full)return f}const h=new i(this.bufSize);return this.buffers.push(h),h},async _pipe(h){await Promise.all(this.pipes.map(function(f){return new Promise(g=>{f.write(h.toBuffer(),()=>{g()})})}))},_writeToBuffers(h){let f=0;const g=h.length;for(;f<g;)f+=this._getWritableBuffer().write(h,f,g-f)},async write(h,f,g){let p;if(f instanceof Function&&(g=f,f="utf8"),g=g||n.nop,h instanceof e)p=new u(h);else if(h instanceof o)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,f)}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,f,g){const p=k=>{k?g(k):(this._flush(),this.pipes.forEach(C=>{C.end()}),this.emit("finish"))};h?this.write(h,f,p):p()},read(h){let f;if(h){for(f=[];h&&this.buffers.length&&!this.buffers[0].eod;){const g=this.buffers[0],p=g.read(h);h-=p.length,f.push(p),g.eod&&g.full&&this.buffers.shift()}return o.concat(f)}return f=this.buffers.map(g=>g.toBuffer()).filter(Boolean),this.buffers=[],o.concat(f)},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(f=>f!==h)},unshift(){throw new Error("Not Implemented")},wrap(){throw new Error("Not Implemented")}}),b.exports=d}).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(o){this._buf=c.alloc(o&&o.size||16384),this._encoding=o&&o.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(o){o=o||0,this._buffer=void 0,this._inPos=o}_grow(o){let s=2*this._buf.length;for(;s<o;)s*=2;const n=c.alloc(s);this._buf.copy(n,0),this._buf=n}addText(o){this._buffer=void 0;let s=this._inPos+this._buf.write(o,this._inPos,this._encoding);for(;s>=this._buf.length-4;)this._grow(this._inPos+o.length),s=this._inPos+this._buf.write(o,this._inPos,this._encoding);this._inPos=s}addStringBuf(o){o.length&&(this._buffer=void 0,this.length+o.length>this.capacity&&this._grow(this.length+o.length),o._buf.copy(this._buf,this._inPos,0,o.length),this._inPos+=o.length)}}}).call(this)}).call(this,t("buffer").Buffer)},{buffer:220}],26:[function(t,b,m){const{toString:c}=Object.prototype,o=/["&<>]/,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),i=Array.isArray(e);let d;if(r!==u)return!1;switch(typeof n){case"object":if(a||i)return!(!a||!i)&&n.length===e.length&&n.every((h,f)=>{const g=e[f];return s.isEqual(h,g)});if(n===null||e===null)return n===e;if(d=Object.keys(n),Object.keys(e).length!==d.length)return!1;for(const h of d)if(!e.hasOwnProperty(h))return!1;return s.every(n,(h,f)=>{const g=e[f];return s.isEqual(h,g)});default:return n===e}},escapeHtml(n){const e=o.exec(n);if(!e)return n;let r="",u="",a=0,i=e.index;for(;i<n.length;i++){switch(n.charAt(i)){case'"':u=""";break;case"&":u="&";break;case"'":u="'";break;case"<":u="<";break;case">":u=">";break;default:continue}a!==i&&(r+=n.substring(a,i)),a=i+1,r+=u}return a!==i?r+n.substring(a,i):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 i(d,h){r=n[h],a=Array.isArray(d),s.isObject(d)||a?(a?(a=!1,u=r&&Array.isArray(r)?r:[]):u=r&&s.isObject(r)?r:{},n[h]=s.deepMerge(u,d)):s.isUndefined(d)||(n[h]=d)}for(let d=0;d<e;d++)s.each(arguments[d],i);return n}};b.exports=s},{}],27:[function(t,b,m){(function(c,o){(function(){const s=t("fs"),n=/[<>&'"\x7F\x00-\x08\x0B-\x0C\x0E-\x1F]/,e={nop(){},promiseImmediate:r=>new Promise(u=>{c.setImmediate?o(()=>{u(r)}):setTimeout(()=>{u(r)},1)}),inherits:function(r,u,a,i){r.super_=u,i||(i=a,a=null),a&&Object.keys(a).forEach(h=>{Object.defineProperty(r,h,Object.getOwnPropertyDescriptor(a,h))});const d={constructor:{value:r,enumerable:!1,writable:!1,configurable:!0}};i&&Object.keys(i).forEach(h=>{d[h]=Object.getOwnPropertyDescriptor(i,h)}),r.prototype=Object.create(u.prototype,d)},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="",i="",d=0,h=u.index;for(;h<r.length;h++){const f=r.charCodeAt(h);switch(f){case 34:i=""";break;case 38:i="&";break;case 39:i="'";break;case 60:i="<";break;case 62:i=">";break;case 127:i="";break;default:if(f<=31&&(f<=8||f>=11&&f!==13)){i="";break}continue}d!==h&&(a+=r.substring(d,h)),d=h+1,i&&(a+=i)}return d!==h?a+r.substring(d,h):a},xmlDecode:r=>r.replace(/&([a-z]*);/g,u=>{switch(u){case"<":return"<";case">":return">";case"&":return"&";case"'":return"'";case""":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 lt<"u"?lt: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"),o=t("./utils");function s(r,u,a){r.push(` ${u}="${o.xmlEncode(a.toString())}"`)}function n(r,u){if(u){const a=[];c.each(u,(i,d)=>{i!==void 0&&s(a,d,i)}),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 y=require("vue"),fi={xs:18,sm:24,md:32,lg:38,xl:46},Or={size:String};function Fr(l,I=fi){return y.computed(()=>l.size!==void 0?{fontSize:l.size in I?`${I[l.size]}px`:l.size}:null)}function Lt(l,I,t,b){return Object.defineProperty(l,I,{get:t,set:b,enumerable:!0}),l}function ks(l,I){for(const t in I)Lt(l,t,I[t]);return l}function $e(l){return y.markRaw(y.defineComponent(l))}function Ei(l){return y.markRaw(l)}const _s=(l,I)=>{const t=y.reactive(l);for(const b in l)Lt(I,b,()=>t[b],m=>{t[b]=m});return I};function gt(l,I){return l!==void 0&&l()||I}function Mi(l,I){if(l!==void 0){const t=l();if(t!=null)return t.slice()}return I}function It(l,I){return l!==void 0?I.concat(l()):I}function sa(l,I){return l===void 0?I:I!==void 0?I.concat(l()):l()}function Cs(l,I,t,b,m,c){I.key=b+m;const o=y.h(l,I,t);return m===!0?y.withDirectives(o,c()):o}const so="0 0 24 24",Hn=l=>l,Yn=l=>`ionicons ${l}`,la={"mdi-":l=>`mdi ${l}`,"icon-":Hn,"bt-":l=>`bt ${l}`,"eva-":l=>`eva ${l}`,"ion-md":Yn,"ion-ios":Yn,"ion-logo":Yn,"iconfont ":Hn,"ti-":l=>`themify-icon ${l}`,"bi-":l=>`bootstrap-icons ${l}`,"i-":Hn},ua={o_:"-outlined",r_:"-round",s_:"-sharp"},ca={sym_o_:"-outlined",sym_r_:"-rounded",sym_s_:"-sharp"},As=new RegExp("^("+Object.keys(la).join("|")+")"),Es=new RegExp("^("+Object.keys(ua).join("|")+")"),lo=new RegExp("^("+Object.keys(ca).join("|")+")"),Ms=/^[Mm]\s?[-+]?\.?\d/,Ts=/^img:/,Rs=/^svguse:/,Bs=/^ion-/,Is=/^(fa-(classic|sharp|solid|regular|light|brands|duotone|thin)|[lf]a[srlbdk]?) /,bt=$e({name:"QIcon",props:{...Or,tag:{type:String,default:"i"},name:String,color:String,left:Boolean,right:Boolean},setup(l,{slots:I}){const{proxy:{$q:t}}=y.getCurrentInstance(),b=Fr(l),m=y.computed(()=>"q-icon"+(l.left===!0?" on-left":"")+(l.right===!0?" on-right":"")+(l.color!==void 0?` text-${l.color}`:"")),c=y.computed(()=>{let o,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(Ms.test(s)===!0){const[r,u=so]=s.split("|");return{svg:!0,viewBox:u,nodes:r.split("&&").map(a=>{const[i,d,h]=a.split("@@");return y.h("path",{style:d,d:i,transform:h})})}}if(Ts.test(s)===!0)return{img:!0,src:s.substring(4)};if(Rs.test(s)===!0){const[r,u=so]=s.split("|");return{svguse:!0,src:r.substring(7),viewBox:u}}let n=" ";const e=s.match(As);if(e!==null)o=la[e[1]](s);else if(Is.test(s)===!0)o=s;else if(Bs.test(s)===!0)o=`ionicons ion-${t.platform.is.ios===!0?"ios":"md"}${s.substring(3)}`;else if(lo.test(s)===!0){o="notranslate material-symbols";const r=s.match(lo);r!==null&&(s=s.substring(6),o+=ca[r[1]]),n=s}else{o="notranslate material-icons";const r=s.match(Es);r!==null&&(s=s.substring(2),o+=ua[r[1]]),n=s}return{cls:o,content:n}});return()=>{const o={class:m.value,style:b.value,"aria-hidden":"true"};return c.value.none===!0?y.h(l.tag,o,gt(I.default)):c.value.img===!0?y.h(l.tag,o,It(I.default,[y.h("img",{src:c.value.src})])):c.value.svg===!0?y.h(l.tag,o,It(I.default,[y.h("svg",{viewBox:c.value.viewBox||"0 0 24 24"},c.value.nodes)])):c.value.svguse===!0?y.h(l.tag,o,It(I.default,[y.h("svg",{viewBox:c.value.viewBox},[y.h("use",{"xlink:href":c.value.src})])])):(c.value.cls!==void 0&&(o.class+=" "+c.value.cls),y.h(l.tag,o,It(I.default,[c.value.content])))}}});function wn(l){if(Object(l.$parent)===l.$parent)return l.$parent;let{parent:I}=l.$;for(;Object(I)===I;){if(Object(I.proxy)===I.proxy)return I.proxy;I=I.parent}}function fa(l,I){typeof I.type=="symbol"?Array.isArray(I.children)===!0&&I.children.forEach(t=>{fa(l,t)}):l.add(I)}function Os(l){const I=new Set;return l.forEach(t=>{fa(I,t)}),Array.from(I)}function Ti(l){return l.appContext.config.globalProperties.$router!==void 0}function Ri(l){return l.isUnmounted===!0||l.isDeactivated===!0}function uo(l){return l?l.aliasOf?l.aliasOf.path:l.path:""}function co(l,I){return(l.aliasOf||l)===(I.aliasOf||I)}function Fs(l,I){for(const t in I){const b=I[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,o)=>c!==m[o]))return!1}return!0}function fo(l,I){return Array.isArray(I)===!0?l.length===I.length&&l.every((t,b)=>t===I[b]):l.length===1&&l[0]===I}function js(l,I){return Array.isArray(l)===!0?fo(l,I):Array.isArray(I)===!0?fo(I,l):l===I}function Ds(l,I){if(Object.keys(l).length!==Object.keys(I).length)return!1;for(const t in l)if(js(l[t],I[t])===!1)return!1;return!0}const da={to:[String,Object],replace:Boolean,href:String,target:String,disable:Boolean},ha={...da,exact:Boolean,activeClass:{type:String,default:"q-router-link--active"},exactActiveClass:{type:String,default:"q-router-link--exact-active"}};function Bi({fallbackTag:l,useDisableForRouterLinkProps:I=!0}={}){const t=y.getCurrentInstance(),{props:b,proxy:m,emit:c}=t,o=Ti(t),s=y.computed(()=>b.disable!==!0&&b.href!==void 0),n=I===!0?y.computed(()=>o===!0&&b.disable!==!0&&s.value!==!0&&b.to!==void 0&&b.to!==null&&b.to!==""):y.computed(()=>o===!0&&s.value!==!0&&b.to!==void 0&&b.to!==null&&b.to!==""),e=y.computed(()=>n.value===!0?p(b.to):null),r=y.computed(()=>e.value!==null),u=y.computed(()=>s.value===!0||r.value===!0),a=y.computed(()=>b.type==="a"||u.value===!0?"a":b.tag||l||"div"),i=y.computed(()=>s.value===!0?{href:b.href,target:b.target}:r.value===!0?{href:e.value.href,target:b.target}:{}),d=y.computed(()=>{if(r.value===!1)return-1;const{matched:T}=e.value,{length:j}=T,q=T[j-1];if(q===void 0)return-1;const P=m.$route.matched;if(P.length===0)return-1;const N=P.findIndex(co.bind(null,q));if(N!==-1)return N;const V=uo(T[j-2]);return j>1&&uo(q)===V&&P[P.length-1].path!==V?P.findIndex(co.bind(null,T[j-2])):N}),h=y.computed(()=>r.value===!0&&d.value!==-1&&Fs(m.$route.params,e.value.params)),f=y.computed(()=>h.value===!0&&d.value===m.$route.matched.length-1&&Ds(m.$route.params,e.value.params)),g=y.computed(()=>r.value===!0?f.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:j,to:q=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"](q);return j===!0?N:N.then(()=>{}).catch(()=>{})}function C(T){if(r.value===!0){const j=q=>k(T,q);c("click",T,j),T.defaultPrevented!==!0&&j()}else c("click",T)}return{hasRouterLink:r,hasHrefLink:s,hasLink:u,linkTag:a,resolvedLink:e,linkIsActive:h,linkIsExactActive:f,linkClass:g,linkAttrs:i,getLink:p,navigateToRouterLink:k,navigateOnClick:C}}const Ps=$e({name:"QBreadcrumbsEl",props:{...ha,label:String,icon:String,tag:{type:String,default:"span"}},emits:["click"],setup(l,{slots:I}){const{linkTag:t,linkAttrs:b,linkClass:m,navigateOnClick:c}=Bi(),o=y.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=y.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(y.h(bt,{class:s.value,name:l.icon})),l.label!==void 0&&n.push(l.label),y.h(t.value,{...o.value},It(I.default,n))}}}),pa={left:"start",center:"center",right:"end",between:"between",around:"around",evenly:"evenly",stretch:"stretch"},Ns=Object.keys(pa),Ii={align:{type:String,validator:l=>Ns.includes(l)}};function Oi(l){return y.computed(()=>{const I=l.align===void 0?l.vertical===!0?"stretch":"left":l.align;return`${l.vertical===!0?"items":"justify"}-${pa[I]}`})}const Ls=["",!0],Vs=$e({name:"QBreadcrumbs",props:{...Ii,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:I}){const t=Oi(l),b=y.computed(()=>`flex items-center ${t.value}${l.gutter==="none"?"":` q-gutter-${l.gutter}`}`),m=y.computed(()=>l.separatorColor?` text-${l.separatorColor}`:""),c=y.computed(()=>` text-${l.activeColor}`);return()=>{if(I.default===void 0)return;const o=Os(gt(I.default));if(o.length===0)return;let s=1;const n=[],e=o.filter(u=>u.type?.name==="QBreadcrumbsEl").length,r=I.separator!==void 0?I.separator:()=>l.separator;return o.forEach(u=>{if(u.type?.name==="QBreadcrumbsEl"){const a=s<e,i=u.props!==null&&Ls.includes(u.props.disable),d=(a===!0?"":" q-breadcrumbs--last")+(i!==!0&&a===!0?c.value:"");s++,n.push(y.h("div",{class:`flex items-center${d}`},[u])),a===!0&&n.push(y.h("div",{class:"q-breadcrumbs__separator"+m.value},r()))}else n.push(u)}),y.h("div",{class:"q-breadcrumbs"},[y.h("div",{class:b.value},n)])}}}),qs=y.defineComponent({inheritAttrs:!1,__name:"Breadcrumbs",props:{activeColor:{},separatorIcon:{},separatorSize:{},separatorColor:{},store:{},navStore:{},route:{},router:{},breadcrumbConfig:{},separator:{},gutter:{},align:{}},setup(l){const I=l,t=y.useAttrs(),b=y.computed(()=>{const{activeColor:a,separatorIcon:i,separatorSize:d,separatorColor:h,...f}=t;return f}),m=a=>({"data-cy":a.dataCy,class:"cursor-pointer text-h5",color:a.color}),c=y.computed(()=>I.activeColor||"primary"),o=y.computed(()=>I.separatorIcon||"chevron_right"),s=y.computed(()=>I.separatorSize||"2em"),n=y.computed(()=>I.separatorColor||"primary"),e=y.computed(()=>({store:I.store,route:I.route,navStore:I.navStore||{}})),r=y.computed(()=>{const a=[];return I.breadcrumbConfig.forEach(i=>{if(!i.shouldRender(e.value))return;const d=i.getLabel?i.getLabel(e.value):i.defaultLabel,h=i.getColor?i.getColor(e.value):"dark",f={name:i.routeName,...i.getRouteParams&&{params:i.getRouteParams(e.value)}},g=i.clearActions?i.clearActions.map(p=>()=>p(e.value)):[];a.push({label:d,dataCy:i.dataCy,color:h,route:f,clearActions:g})}),a}),u=a=>{a.clearActions&&a.clearActions.forEach(i=>i()),I.router.push(a.route)};return(a,i)=>(y.openBlock(),y.createBlock(Vs,y.mergeProps({"active-color":c.value,class:"text-brown"},b.value),{separator:y.withCtx(()=>[y.createVNode(bt,{size:s.value,name:o.value,color:n.value},null,8,["size","name","color"])]),default:y.withCtx(()=>[(y.openBlock(!0),y.createElementBlock(y.Fragment,null,y.renderList(r.value,(d,h)=>(y.openBlock(),y.createBlock(Ps,y.mergeProps({key:h,to:d.route},{ref_for:!0},m(d),{label:d.label,onClick:f=>u(d)}),null,16,["to","label","onClick"]))),128))]),_:1},16,["active-color"]))}}),zs={size:{type:[String,Number],default:"1em"},color:String};function Us(l){return{cSize:y.computed(()=>l.size in fi?`${fi[l.size]}px`:l.size),classes:y.computed(()=>"q-spinner"+(l.color?` text-${l.color}`:""))}}const ma=$e({name:"QSpinner",props:{...zs,thickness:{type:Number,default:5}},setup(l){const{cSize:I,classes:t}=Us(l);return()=>y.h("svg",{class:t.value+" q-spinner-mat",width:I.value,height:I.value,viewBox:"25 25 50 50"},[y.h("circle",{class:"path",cx:"50",cy:"50",r:"20",fill:"none",stroke:"currentColor","stroke-width":l.thickness,"stroke-miterlimit":"10"})])}});function di(l,I){const t=l.style;for(const b in I)t[b]=I[b]}function Ws(l){if(l==null)return;if(typeof l=="string")try{return document.querySelector(l)||void 0}catch{return}const I=y.unref(l);if(I)return I.$el||I}function ga(l,I){if(l==null||l.contains(I)===!0)return!0;for(let t=l.nextElementSibling;t!==null;t=t.nextElementSibling)if(t.contains(I))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 Pn(){}function Hs(l){return l.button===0}function Hr(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 Ys(l){if(l.path)return l.path;if(l.composedPath)return l.composedPath();const I=[];let t=l.target;for(;t;){if(I.push(t),t.tagName==="HTML")return I.push(document),I.push(window),I;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 Qn(l,I){if(l===void 0||I===!0&&l.__dragPrevented===!0)return;const t=I===!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 Kt(l,I,t){const b=`__q_${I}_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 fr(l,I){const t=`__q_${I}_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 Fi(l){return l!==Object(l)||l.isComposing===!0||l.qKeyEvent===!0}function ir(l,I){return Fi(l)===!0?!1:[].concat(I).includes(l.keyCode)}function Qs(l,I=250){let t=!1,b;return function(){return t===!1&&(t=!0,setTimeout(()=>{t=!1},I),b=l.apply(this,arguments)),b}}function ho(l,I,t,b){t.modifiers.stop===!0&&Dt(l);const m=t.modifiers.color;let c=t.modifiers.center;c=c===!0||b===!0;const o=document.createElement("span"),s=document.createElement("span"),n=Hr(l),{left:e,top:r,width:u,height:a}=I.getBoundingClientRect(),i=Math.sqrt(u*u+a*a),d=i/2,h=`${(u-i)/2}px`,f=c?h:`${n.left-e-d}px`,g=`${(a-i)/2}px`,p=c?g:`${n.top-r-d}px`;s.className="q-ripple__inner",di(s,{height:`${i}px`,width:`${i}px`,transform:`translate3d(${f},${p},0) scale3d(.2,.2,1)`,opacity:0}),o.className=`q-ripple${m?" text-"+m:""}`,o.setAttribute("dir","ltr"),o.appendChild(s),I.appendChild(o);const k=()=>{o.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(()=>{o.remove(),t.abort.splice(t.abort.indexOf(k),1)},275)},250)},50)}function po(l,{modifiers:I,value:t,arg:b}){const m=Object.assign({},l.cfg.ripple,I,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 ba=Ei({name:"ripple",beforeMount(l,I){const t=I.instance.$.appContext.config.globalProperties.$q.config||{};if(t.ripple===!1)return;const b={cfg:t,enabled:I.value!==!1,modifiers:{},abort:[],start(m){b.enabled===!0&&m.qSkipRipple!==!0&&m.type===(b.modifiers.early===!0?"pointerdown":"click")&&ho(m,l,b,m.qKeyEvent===!0)},keystart:Qs(m=>{b.enabled===!0&&m.qSkipRipple!==!0&&ir(m,b.modifiers.keyCodes)===!0&&m.type===`key${b.modifiers.early===!0?"down":"up"}`&&ho(m,l,b,!0)},300)};po(b,I),l.__qripple=b,Kt(b,"main",[[l,"pointerdown","start","passive"],[l,"click","start","passive"],[l,"keydown","keystart","passive"],[l,"keyup","keystart","passive"]])},updated(l,I){if(I.oldValue!==I.value){const t=l.__qripple;t!==void 0&&(t.enabled=I.value!==!1,t.enabled===!0&&Object(I.value)===I.value&&po(t,I))}},beforeUnmount(l){const I=l.__qripple;I!==void 0&&(I.abort.forEach(t=>{t()}),fr(I,"main"),delete l._qripple)}}),mo={none:0,xs:4,sm:8,md:16,lg:24,xl:32},Ks={xs:8,sm:10,md:14,lg:20,xl:24},Xs=["button","submit","reset"],Gs=/[^\s]\/[^\s]/,Js=["flat","outline","push","unelevated"];function Zs(l,I){return l.flat===!0?"flat":l.outline===!0?"outline":l.push===!0?"push":l.unelevated===!0?"unelevated":I}const $s={...Or,...da,type:{type:String,default:"button"},label:[Number,String],icon:String,iconRight:String,...Js.reduce((l,I)=>(l[I]=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:{...Ii.align,default:"center"},stack:Boolean,stretch:Boolean,loading:{type:Boolean,default:null},disable:Boolean},el={...$s,round:Boolean};function tl(l){const I=Fr(l,Ks),t=Oi(l),{hasRouterLink:b,hasLink:m,linkTag:c,linkAttrs:o,navigateOnClick:s}=Bi({fallbackTag:"button"}),n=y.computed(()=>{const f=l.fab===!1&&l.fabMini===!1?I.value:{};return l.padding!==void 0?Object.assign({},f,{padding:l.padding.split(/\s+/).map(g=>g in mo?mo[g]+"px":g).join(" "),minWidth:"0",minHeight:"0"}):f}),e=y.computed(()=>l.rounded===!0||l.fab===!0||l.fabMini===!0),r=y.computed(()=>l.disable!==!0&&l.loading!==!0),u=y.computed(()=>r.value===!0?l.tabindex||0:-1),a=y.computed(()=>Zs(l,"standard")),i=y.computed(()=>{const f={tabindex:u.value};return m.value===!0?Object.assign(f,o.value):Xs.includes(l.type)===!0&&(f.type=l.type),c.value==="a"?(l.disable===!0?f["aria-disabled"]="true":f.href===void 0&&(f.role="button"),b.value!==!0&&Gs.test(l.type)===!0&&(f.type=l.type)):l.disable===!0&&(f.disabled="",f["aria-disabled"]="true"),l.loading===!0&&l.percentage!==void 0&&Object.assign(f,{role:"progressbar","aria-valuemin":0,"aria-valuemax":100,"aria-valuenow":l.percentage}),f}),d=y.computed(()=>{let f;l.color!==void 0?l.flat===!0||l.outline===!0?f=`text-${l.textColor||l.color}`:f=`bg-${l.color} text-${l.textColor||"white"}`:l.textColor&&(f=`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}`+(f!==void 0?" "+f:"")+(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=y.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:d,style:n,innerClasses:h,attributes:i,hasLink:m,linkTag:c,navigateOnClick:s,isActionable:r}}const{passiveCapture:Nt}=_t;let yr=null,wr=null,xr=null;const ct=$e({name:"QBtn",props:{...el,percentage:Number,darkPercentage:Boolean,onTouchstart:[Function,Array]},emits:["click","keydown","mousedown","keyup"],setup(l,{slots:I,emit:t}){const{proxy:b}=y.getCurrentInstance(),{classes:m,style:c,innerClasses:o,attributes:s,hasLink:n,linkTag:e,navigateOnClick:r,isActionable:u}=tl(l),a=y.ref(null),i=y.ref(null);let d=null,h,f=null;const g=y.computed(()=>l.label!==void 0&&l.label!==null&&l.label!==""),p=y.computed(()=>l.disable===!0||l.ripple===!1?!1:{keyCodes:n.value===!0?[13,32]:[13],...l.ripple===!0?{}:l.ripple}),k=y.computed(()=>({center:l.round})),C=y.computed(()=>{const M=Math.max(0,Math.min(100,l.percentage));return M>0?{transition:"transform 0.6s",transform:`translateX(${M-100}%)`}:{}}),T=y.computed(()=>{if(l.loading===!0)return{onMousedown:A,onTouchstart:A,onClick:A,onKeydown:A,onKeyup:A};if(u.value===!0){const M={onClick:q,onKeydown:P,onMousedown:V};if(b.$q.platform.has.touch===!0){const _=l.onTouchstart!==void 0?"":"Passive";M[`onTouchstart${_}`]=N}return M}return{onClick:St}}),j=y.computed(()=>({ref:a,class:"q-btn q-btn-item non-selectable no-outline "+m.value,style:c.value,...s.value,...T.value}));function q(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 v=()=>{document.removeEventListener("keydown",St,!0),document.removeEventListener("keyup",v,Nt),a.value?.removeEventListener("blur",v,Nt)};document.addEventListener("keydown",St,!0),document.addEventListener("keyup",v,Nt),a.value.addEventListener("blur",v,Nt)}}r(M)}}function P(M){a.value!==null&&(t("keydown",M),ir(M,[13,32])===!0&&wr!==a.value&&(wr!==null&&L(),M.defaultPrevented!==!0&&(M.qAvoidFocus!==!0&&a.value.focus(),wr=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&&(yr!==a.value&&(yr!==null&&L(),yr=a.value,d=M.target,d.addEventListener("touchcancel",W,Nt),d.addEventListener("touchend",W,Nt)),h=!0,f!==null&&clearTimeout(f),f=setTimeout(()=>{f=null,h=!1},200)))}function V(M){a.value!==null&&(M.qSkipRipple=h===!0,t("mousedown",M),M.defaultPrevented!==!0&&xr!==a.value&&(xr!==null&&L(),xr=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(wr===a.value&&ir(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 _=i.value;M!==!0&&(yr===a.value||xr===a.value)&&_!==null&&_!==document.activeElement&&(_.setAttribute("tabindex",-1),_.focus()),yr===a.value&&(d!==null&&(d.removeEventListener("touchcancel",W,Nt),d.removeEventListener("touchend",W,Nt)),yr=d=null),xr===a.value&&(document.removeEventListener("mouseup",W,Nt),xr=null),wr===a.value&&(document.removeEventListener("keyup",W,!0),a.value?.removeEventListener("blur",W,Nt),wr=null),a.value?.classList.remove("q-btn--active")}function A(M){St(M),M.qSkipRipple=!0}return y.onBeforeUnmount(()=>{L(!0)}),Object.assign(b,{click:M=>{u.value===!0&&q(M)}}),()=>{let M=[];l.icon!==void 0&&M.push(y.h(bt,{name:l.icon,left:l.stack!==!0&&g.value===!0,role:"img"})),g.value===!0&&M.push(y.h("span",{class:"block"},[l.label])),M=It(I.default,M),l.iconRight!==void 0&&l.round===!1&&M.push(y.h(bt,{name:l.iconRight,right:l.stack!==!0&&g.value===!0,role:"img"}));const _=[y.h("span",{class:"q-focus-helper",ref:i})];return l.loading===!0&&l.percentage!==void 0&&_.push(y.h("span",{class:"q-btn__progress absolute-full overflow-hidden"+(l.darkPercentage===!0?" q-btn__progress--dark":"")},[y.h("span",{class:"q-btn__progress-indicator fit block",style:C.value})])),_.push(y.h("span",{class:"q-btn__content text-center col items-center q-anchor--skip "+o.value},M)),l.loading!==null&&_.push(y.h(y.Transition,{name:"q-transition--fade"},()=>l.loading===!0?[y.h("span",{key:"loading",class:"absolute-full flex flex-center"},I.loading!==void 0?I.loading():[y.h(ma)])]:null)),y.withDirectives(y.h(e.value,j.value,_),[[ba,p.value,void 0,k.value]])}}}),rl={class:"row justify-between"},nl=y.defineComponent({__name:"NavButton",props:{from:{},to:{default:void 0},labelFrom:{},labelTo:{default:void 0},params:{default:()=>({})},query:{default:()=>({})}},setup(l){const I=l,t=y.inject("navContext",null),b=y.inject("router");function m(c){if(!b){console.warn("Dependencies not available:",{router:b});return}t?.setTabs();const o=c==="back"?I.from:I.to;if(!o){console.warn("Destination not provided:",c);return}b.push({name:o,params:I.params,query:I.query})}return(c,o)=>(y.openBlock(),y.createElementBlock("div",rl,[y.createVNode(ct,{icon:"chevron_left","rounded-sm":"",label:c.labelFrom,"data-cy":"go-back","data-testid":"go-back",onClick:o[0]||(o[0]=s=>m("back"))},null,8,["label"]),c.labelTo?(y.openBlock(),y.createBlock(ct,{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:o[1]||(o[1]=s=>m("next"))},null,8,["label"])):y.createCommentVNode("",!0)]))}}),Xt=(l,I)=>{const t=l.__vccOpts||l;for(const[b,m]of I)t[b]=m;return t},il=Xt(nl,[["__scopeId","data-v-8dd99f80"]]),Ot={dark:{type:Boolean,default:null}};function Ft(l,I){return y.computed(()=>l.dark===null?I.dark.isActive:l.dark)}function ol(l,I){const t=y.ref(null),b=y.computed(()=>l.disable===!0?null:y.h("span",{ref:t,class:"no-outline",tabindex:-1}));function m(c){const o=I.value;c?.qAvoidFocus!==!0&&(c?.type.indexOf("key")===0?document.activeElement!==o&&o?.contains(document.activeElement)===!0&&o.focus():t.value!==null&&(c===void 0||o?.contains(c.target)===!0)&&t.value.focus())}return{refocusTargetEl:b,refocusTarget:m}}const Nn={name:String};function al(l){return y.computed(()=>({type:"hidden",name:l.name,value:l.modelValue}))}function va(l={}){return(I,t,b)=>{I[t](y.h("input",{class:"hidden"+(b||""),...l.value}))}}function ya(l){return y.computed(()=>l.name||l.for)}const sl={xs:30,sm:35,md:40,lg:50,xl:60},wa={...Ot,...Or,...Nn,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]},xa=["update:modelValue"];function Sa(l,I){const{props:t,slots:b,emit:m,proxy:c}=y.getCurrentInstance(),{$q:o}=c,s=Ft(t,o),n=y.ref(null),{refocusTargetEl:e,refocusTarget:r}=ol(t,n),u=Fr(t,sl),a=y.computed(()=>t.val!==void 0&&Array.isArray(t.modelValue)),i=y.computed(()=>{const L=y.toRaw(t.val);return a.value===!0?t.modelValue.findIndex(A=>y.toRaw(A)===L):-1}),d=y.computed(()=>a.value===!0?i.value!==-1:y.toRaw(t.modelValue)===y.toRaw(t.trueValue)),h=y.computed(()=>a.value===!0?i.value===-1:y.toRaw(t.modelValue)===y.toRaw(t.falseValue)),f=y.computed(()=>d.value===!1&&h.value===!1),g=y.computed(()=>t.disable===!0?-1:t.tabindex||0),p=y.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=y.computed(()=>{const L=d.value===!0?"truthy":h.value===!0?"falsy":"indet",A=t.color!==void 0&&(t.keepColor===!0||(l==="toggle"?d.value===!0:h.value!==!0))?` text-${t.color}`:"";return`q-${l}__inner relative-position non-selectable q-${l}__inner--${L}${A}`}),C=y.computed(()=>{const L={type:"checkbox"};return t.name!==void 0&&Object.assign(L,{".checked":d.value,"^checked":d.value===!0?"checked":void 0,name:t.name,value:a.value===!0?t.val:t.trueValue}),L}),T=va(C),j=y.computed(()=>{const L={tabindex:g.value,role:l==="toggle"?"switch":"checkbox","aria-label":t.label,"aria-checked":f.value===!0?"mixed":d.value===!0?"true":"false"};return t.disable===!0&&(L["aria-disabled"]="true"),L});function q(L){L!==void 0&&(St(L),r(L)),t.disable!==!0&&m("update:modelValue",P(),L)}function P(){if(a.value===!0){if(d.value===!0){const L=t.modelValue.slice();return L.splice(i.value,1),L}return t.modelValue.concat([t.val])}if(d.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 V(L){(L.keyCode===13||L.keyCode===32)&&q(L)}const W=I(d,f);return Object.assign(c,{toggle:q}),()=>{const L=W();t.disable!==!0&&T(L,"unshift",` q-${l}__native absolute q-ma-none q-pa-none`);const A=[y.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]):gt(b.default);return M!==void 0&&A.push(y.h("div",{class:`q-${l}__label q-anchor--skip`},M)),y.h("div",{ref:n,class:p.value,...j.value,onClick:q,onKeydown:N,onKeyup:V},A)}}const ll=()=>y.h("div",{key:"svg",class:"q-checkbox__bg absolute"},[y.h("svg",{class:"q-checkbox__svg fit absolute-full",viewBox:"0 0 24 24"},[y.h("path",{class:"q-checkbox__truthy",fill:"none",d:"M1.73,12.91 8.1,19.28 22.79,4.59"}),y.h("path",{class:"q-checkbox__indet",d:"M4,14H20V10H4"})])]),Er=$e({name:"QCheckbox",props:wa,emits:xa,setup(l){const I=ll();function t(b,m){const c=y.computed(()=>(b.value===!0?l.checkedIcon:m.value===!0?l.indeterminateIcon:l.uncheckedIcon)||null);return()=>c.value!==null?[y.h("div",{key:"icon",class:"q-checkbox__icon-container absolute-full flex flex-center no-wrap"},[y.h(bt,{class:"q-checkbox__icon",name:c.value})])]:[I]}return Sa("checkbox",t)}}),ul=$e({props:["store","barStyle","verticalBarStyle","horizontalBarStyle"],setup(l){return()=>[y.h("div",{class:l.store.scroll.vertical.barClass.value,style:[l.barStyle,l.verticalBarStyle],"aria-hidden":"true",onMousedown:l.store.onVerticalMousedown}),y.h("div",{class:l.store.scroll.horizontal.barClass.value,style:[l.barStyle,l.horizontalBarStyle],"aria-hidden":"true",onMousedown:l.store.onHorizontalMousedown}),y.withDirectives(y.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),y.withDirectives(y.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)]}}),or=y.ref(!1);let hi;function cl(l,I){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:I[0]||""}}function fl(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 ka="ontouchstart"in window||window.navigator.maxTouchPoints>0;function dl(l){const I=l.toLowerCase(),t=fl(I),b=cl(I,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||I.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,I.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"),or.value===!0&&(hi={is:{...m}}),ka===!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 o=Math.min(window.innerHeight,window.innerWidth)>414?"ipad":"iphone";Object.assign(m,{mobile:!0,ios:!0,platform:o,[o]:!0})}m.mobile!==!0&&window.navigator.userAgentData&&window.navigator.userAgentData.mobile&&(delete m.desktop,m.mobile=!0)}return m}const go=navigator.userAgent||navigator.vendor||window.opera,hl={has:{touch:!1,webStorage:!1},within:{iframe:!1}},Et={userAgent:go,is:dl(go),has:{touch:ka},within:{iframe:window.self!==window.top}},pi={install(l){const{$q:I}=l;or.value===!0?(l.onSSRHydrated.push(()=>{Object.assign(I.platform,Et),or.value=!1}),I.platform=y.reactive(this)):I.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(pi,Et),or.value===!0&&(Object.assign(pi,hi,hl),hi=null)}function pl(){const l=y.ref(!or.value);return l.value===!1&&y.onMounted(()=>{l.value=!0}),{isHydrated:l}}const _a=typeof ResizeObserver<"u",bo=_a===!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"},Rr=$e({name:"QResizeObserver",props:{debounce:{type:[String,Number],default:100}},emits:["resize"],setup(l,{emit:I}){let t=null,b,m={width:-1,height:-1};function c(n){n===!0||l.debounce===0||l.debounce==="0"?o():t===null&&(t=setTimeout(o,l.debounce))}function o(){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},I("resize",m))}}const{proxy:s}=y.getCurrentInstance();if(s.trigger=c,_a===!0){let n;const e=r=>{b=s.$el.parentNode,b?(n=new ResizeObserver(c),n.observe(b),o()):r!==!0&&y.nextTick(()=>{e(!0)})};return y.onMounted(()=>{e()}),y.onBeforeUnmount(()=>{t!==null&&clearTimeout(t),n!==void 0&&(n.disconnect!==void 0?n.disconnect():b&&n.unobserve(b))}),Pn}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),o())};const{isHydrated:r}=pl();let u;return y.onMounted(()=>{y.nextTick(()=>{b=s.$el,b&&e()})}),y.onBeforeUnmount(n),()=>{if(r.value===!0)return y.h("object",{class:"q--avoid-card-border",style:bo.style,tabindex:-1,type:"text/html",data:bo.url,"aria-hidden":"true",onLoad:e})}}}}),Ln=[Element,String],ml=[null,document,document.body,document.scrollingElement,document.documentElement];function Vn(l,I){let t=Ws(I);if(t===void 0){if(l==null)return window;t=l.closest(".scroll,.scroll-y,.overflow-auto")}return ml.includes(t)?window:t}function ji(l){return l===window?window.pageYOffset||window.scrollY||document.body.scrollTop||0:l.scrollTop}function Di(l){return l===window?window.pageXOffset||window.scrollX||document.body.scrollLeft||0:l.scrollLeft}function Ca(l,I,t=0){const b=arguments[3]===void 0?performance.now():arguments[3],m=ji(l);if(t<=0){m!==I&&mi(l,I);return}requestAnimationFrame(c=>{const o=c-b,s=m+(I-m)/Math.max(o,t)*o;mi(l,s),s!==I&&Ca(l,I,t-o,c)})}function Aa(l,I,t=0){const b=arguments[3]===void 0?performance.now():arguments[3],m=Di(l);if(t<=0){m!==I&&gi(l,I);return}requestAnimationFrame(c=>{const o=c-b,s=m+(I-m)/Math.max(o,t)*o;gi(l,s),s!==I&&Aa(l,I,t-o,c)})}function mi(l,I){if(l===window){window.scrollTo(window.pageXOffset||window.scrollX||document.body.scrollLeft||0,I);return}l.scrollTop=I}function gi(l,I){if(l===window){window.scrollTo(I,window.pageYOffset||window.scrollY||document.body.scrollTop||0);return}l.scrollLeft=I}function vo(l,I,t){if(t){Ca(l,I,t);return}mi(l,I)}function Kn(l,I,t){if(t){Aa(l,I,t);return}gi(l,I)}let sn;function xn(){if(sn!==void 0)return sn;const l=document.createElement("p"),I=document.createElement("div");di(l,{width:"100%",height:"200px"}),di(I,{position:"absolute",top:"0px",left:"0px",visibility:"hidden",width:"200px",height:"150px",overflow:"hidden"}),I.appendChild(l),document.body.appendChild(I);const t=l.offsetWidth;I.style.overflow="scroll";let b=l.offsetWidth;return t===b&&(b=I.clientWidth),I.remove(),sn=t-b,sn}function gl(l,I=!0){return!l||l.nodeType!==Node.ELEMENT_NODE?!1:I?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:yo}=_t,bl=["both","horizontal","vertical"],Ea=$e({name:"QScrollObserver",props:{axis:{type:String,validator:l=>bl.includes(l),default:"vertical"},debounce:[String,Number],scrollTarget:Ln},emits:["scroll"],setup(l,{emit:I}){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;y.watch(()=>l.scrollTarget,()=>{n(),s()});function o(){b?.();const u=Math.max(0,ji(m)),a=Di(m),i={top:u-t.position.top,left:a-t.position.left};if(l.axis==="vertical"&&i.top===0||l.axis==="horizontal"&&i.left===0)return;const d=Math.abs(i.top)>=Math.abs(i.left)?i.top<0?"up":"down":i.left<0?"left":"right";t.position={top:u,left:a},t.directionChanged=t.direction!==d,t.delta=i,t.directionChanged===!0&&(t.direction=d,t.inflectionPoint=t.position),I("scroll",{...t})}function s(){m=Vn(c,l.scrollTarget),m.addEventListener("scroll",e,yo),e(!0)}function n(){m!==void 0&&(m.removeEventListener("scroll",e,yo),m=void 0)}function e(u){if(u===!0||l.debounce===0||l.debounce==="0")o();else if(b===null){const[a,i]=l.debounce?[setTimeout(o,l.debounce),clearTimeout]:[requestAnimationFrame(o),cancelAnimationFrame];b=()=>{i(a),b=null}}}const{proxy:r}=y.getCurrentInstance();return y.watch(()=>r.$q.lang.rtl,o),y.onMounted(()=>{c=r.$el.parentNode,s()}),y.onBeforeUnmount(()=>{b?.(),n()}),Object.assign(r,{trigger:e,getPosition:()=>t}),Pn}}),Pi={left:!0,right:!0,up:!0,down:!0,horizontal:!0,vertical:!0},vl=Object.keys(Pi);Pi.all=!0;function wo(l){const I={};for(const t of vl)l[t]===!0&&(I[t]=!0);return Object.keys(I).length===0?Pi:(I.horizontal===!0?I.left=I.right=!0:I.left===!0&&I.right===!0&&(I.horizontal=!0),I.vertical===!0?I.up=I.down=!0:I.up===!0&&I.down===!0&&(I.vertical=!0),I.horizontal===!0&&I.vertical===!0&&(I.all=!0),I)}const yl=["INPUT","TEXTAREA"];function xo(l,I){return I.event===void 0&&l.target!==void 0&&l.target.draggable!==!0&&typeof I.handler=="function"&&yl.includes(l.target.nodeName.toUpperCase())===!1&&(l.qClonedBy===void 0||l.qClonedBy.indexOf(I.uid)===-1)}function Cn(){if(window.getSelection!==void 0){const l=window.getSelection();l.empty!==void 0?l.empty():l.removeAllRanges!==void 0&&(l.removeAllRanges(),pi.is.mobile!==!0&&l.addRange(document.createRange()))}else document.selection!==void 0&&document.selection.empty()}function Xn(l,I,t){const b=Hr(l);let m,c=b.left-I.event.x,o=b.top-I.event.y,s=Math.abs(c),n=Math.abs(o);const e=I.direction;e.horizontal===!0&&e.vertical!==!0?m=c<0?"left":"right":e.horizontal!==!0&&e.vertical===!0?m=o<0?"up":"down":e.up===!0&&o<0?(m="up",s>n&&(e.left===!0&&c<0?m="left":e.right===!0&&c>0&&(m="right"))):e.down===!0&&o>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&&o<0?m="up":e.down===!0&&o>0&&(m="down"))):e.right===!0&&c>0&&(m="right",s<n&&(e.up===!0&&o<0?m="up":e.down===!0&&o>0&&(m="down")));let r=!1;if(m===void 0&&t===!1){if(I.event.isFirst===!0||I.event.lastDir===void 0)return{};m=I.event.lastDir,r=!0,m==="left"||m==="right"?(b.left-=c,s=0,c=0):(b.top-=o,n=0,o=0)}return{synthetic:r,payload:{evt:l,touch:I.event.mouse!==!0,mouse:I.event.mouse===!0,position:b,direction:m,isFirst:I.event.isFirst,isFinal:t===!0,duration:Date.now()-I.event.time,distance:{x:s,y:n},offset:{x:c,y:o},delta:{x:b.left-I.event.lastX,y:b.top-I.event.lastY}}}}let wl=0;const So=Ei({name:"touch-pan",beforeMount(l,{value:I,modifiers:t}){if(t.mouse!==!0&&Et.has.touch!==!0)return;function b(c,o){t.mouse===!0&&o===!0?St(c):(t.stop===!0&&Dt(c),t.prevent===!0&&Bt(c))}const m={uid:"qvtp_"+wl++,handler:I,modifiers:t,direction:wo(t),noop:Pn,mouseStart(c){xo(c,m)&&Hs(c)&&(Kt(m,"temp",[[document,"mousemove","move","notPassiveCapture"],[document,"mouseup","end","passiveCapture"]]),m.start(c,!0))},touchStart(c){if(xo(c,m)){const o=c.target;Kt(m,"temp",[[o,"touchmove","move","notPassiveCapture"],[o,"touchcancel","end","passiveCapture"],[o,"touchend","end","passiveCapture"]]),m.start(c)}},start(c,o){if(Et.is.firefox===!0&&Qn(l,!0),m.lastEvt=c,o===!0||t.stop===!0){if(m.direction.all!==!0&&(o!==!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}=Hr(c);m.event={x:s,y:n,time:Date.now(),mouse:o===!0,detected:!1,isFirst:!0,isFinal:!1,lastX:s,lastY:n}},move(c){if(m.event===void 0)return;const o=Hr(c),s=o.left-m.event.x,n=o.top-m.event.y;if(s===0&&n===0)return;m.lastEvt=c;const e=m.event.mouse===!0,r=()=>{b(c,e);let i;t.preserveCursor!==!0&&t.preservecursor!==!0&&(i=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"),Cn(),m.styleCleanup=d=>{if(m.styleCleanup=void 0,i!==void 0&&(document.documentElement.style.cursor=i),document.body.classList.remove("non-selectable"),e===!0){const h=()=>{document.body.classList.remove("no-pointer-events--children")};d!==void 0?setTimeout(()=>{h(),d()},50):h()}else d!==void 0&&d()}};if(m.event.detected===!0){m.event.isFirst!==!0&&b(c,m.event.mouse);const{payload:i,synthetic:d}=Xn(c,m,!1);i!==void 0&&(m.handler(i)===!1?m.end(c):(m.styleCleanup===void 0&&m.event.isFirst===!0&&r(),m.event.lastX=i.position.left,m.event.lastY=i.position.top,m.event.lastDir=d===!0?void 0:i.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,o){if(m.event!==void 0){if(fr(m,"temp"),Et.is.firefox===!0&&Qn(l,!1),o===!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(Xn(c===void 0?m.lastEvt:c,m).payload);const{payload:s}=Xn(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":"";Kt(m,"main",[[l,"mousedown","mouseStart",`passive${c}`]])}Et.has.touch===!0&&Kt(m,"main",[[l,"touchstart","touchStart",`passive${t.capture===!0?"Capture":""}`],[l,"touchmove","noop","notPassiveCapture"]])},updated(l,I){const t=l.__qtouchpan;t!==void 0&&(I.oldValue!==I.value&&(typeof value!="function"&&t.end(),t.handler=I.value),t.direction=wo(I.modifiers))},beforeUnmount(l){const I=l.__qtouchpan;I!==void 0&&(I.event!==void 0&&I.end(),fr(I,"main"),fr(I,"temp"),Et.is.firefox===!0&&Qn(l,!1),I.styleCleanup?.(),delete l.__qtouchpan)}});function xl(l){return l.charAt(0).toUpperCase()+l.slice(1)}function Dr(l,I,t){return t<=I?I:Math.min(t,Math.max(I,l))}function ko(l,I,t){if(t<=I)return I;const b=t-I+1;let m=I+(l-I)%b;return m<I&&(m=b+m),m===0?0:m}function vt(l,I=2,t="0"){if(l==null)return l;const b=""+l;return b.length>=I?b:new Array(I-b.length+1).join(t)+b}function Ni(l,I=250,t){let b=null;function m(){const c=arguments,o=()=>{b=null,l.apply(this,c)};b!==null&&clearTimeout(b),b=setTimeout(o,I)}return m.cancel=()=>{b!==null&&clearTimeout(b)},m}const _o=["vertical","horizontal"],Gn={vertical:{offset:"offsetY",scroll:"scrollTop",dir:"down",dist:"y"},horizontal:{offset:"offsetX",scroll:"scrollLeft",dir:"right",dist:"x"}},Co={prevent:!0,mouse:!0,mouseAllDir:!0},Ao=l=>l>=250?50:Math.ceil(l/5),Sl=$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:I,emit:t}){const b=y.ref(!1),m=y.ref(!1),c=y.ref(!1),o={vertical:y.ref(0),horizontal:y.ref(0)},s={vertical:{ref:y.ref(null),position:y.ref(0),size:y.ref(0)},horizontal:{ref:y.ref(null),position:y.ref(0),size:y.ref(0)}},{proxy:n}=y.getCurrentInstance(),e=Ft(l,n.$q);let r=null,u;const a=y.ref(null),i=y.computed(()=>"q-scrollarea"+(e.value===!0?" q-scrollarea--dark":""));Object.assign(o,{verticalInner:y.computed(()=>o.vertical.value-l.verticalOffset[0]-l.verticalOffset[1]),horizontalInner:y.computed(()=>o.horizontal.value-l.horizontalOffset[0]-l.horizontalOffset[1])}),s.vertical.percentage=y.computed(()=>{const M=s.vertical.size.value-o.vertical.value;if(M<=0)return 0;const _=Dr(s.vertical.position.value/M,0,1);return Math.round(_*1e4)/1e4}),s.vertical.thumbHidden=y.computed(()=>(l.visible===null?c.value:l.visible)!==!0&&b.value===!1&&m.value===!1||s.vertical.size.value<=o.vertical.value+1),s.vertical.thumbStart=y.computed(()=>l.verticalOffset[0]+s.vertical.percentage.value*(o.verticalInner.value-s.vertical.thumbSize.value)),s.vertical.thumbSize=y.computed(()=>Math.round(Dr(o.verticalInner.value*o.verticalInner.value/s.vertical.size.value,Ao(o.verticalInner.value),o.verticalInner.value))),s.vertical.style=y.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=y.computed(()=>"q-scrollarea__thumb q-scrollarea__thumb--v absolute-right"+(s.vertical.thumbHidden.value===!0?" q-scrollarea__thumb--invisible":"")),s.vertical.barClass=y.computed(()=>"q-scrollarea__bar q-scrollarea__bar--v absolute-right"+(s.vertical.thumbHidden.value===!0?" q-scrollarea__bar--invisible":"")),s.horizontal.percentage=y.computed(()=>{const M=s.horizontal.size.value-o.horizontal.value;if(M<=0)return 0;const _=Dr(Math.abs(s.horizontal.position.value)/M,0,1);return Math.round(_*1e4)/1e4}),s.horizontal.thumbHidden=y.computed(()=>(l.visible===null?c.value:l.visible)!==!0&&b.value===!1&&m.value===!1||s.horizontal.size.value<=o.horizontal.value+1),s.horizontal.thumbStart=y.computed(()=>l.horizontalOffset[0]+s.horizontal.percentage.value*(o.horizontalInner.value-s.horizontal.thumbSize.value)),s.horizontal.thumbSize=y.computed(()=>Math.round(Dr(o.horizontalInner.value*o.horizontalInner.value/s.horizontal.size.value,Ao(o.horizontalInner.value),o.horizontalInner.value))),s.horizontal.style=y.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=y.computed(()=>"q-scrollarea__thumb q-scrollarea__thumb--h absolute-bottom"+(s.horizontal.thumbHidden.value===!0?" q-scrollarea__thumb--invisible":"")),s.horizontal.barClass=y.computed(()=>"q-scrollarea__bar q-scrollarea__bar--h absolute-bottom"+(s.horizontal.thumbHidden.value===!0?" q-scrollarea__bar--invisible":""));const d=y.computed(()=>s.vertical.thumbHidden.value===!0&&s.horizontal.thumbHidden.value===!0?l.contentStyle:l.contentActiveStyle);function h(){const M={};return _o.forEach(_=>{const v=s[_];Object.assign(M,{[_+"Position"]:v.position.value,[_+"Percentage"]:v.percentage.value,[_+"Size"]:v.size.value,[_+"ContainerSize"]:o[_].value,[_+"ContainerInnerSize"]:o[_+"Inner"].value})}),M}const f=Ni(()=>{const M=h();M.ref=n,t("scroll",M)},0);function g(M,_,v){if(_o.includes(M)===!1){console.error("[QScrollArea]: wrong first param of setScrollPosition (vertical/horizontal)");return}(M==="vertical"?vo:Kn)(a.value,_,v)}function p({height:M,width:_}){let v=!1;o.vertical.value!==M&&(o.vertical.value=M,v=!0),o.horizontal.value!==_&&(o.horizontal.value=_,v=!0),v===!0&&q()}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&&q()}function C({height:M,width:_}){s.horizontal.size.value!==_&&(s.horizontal.size.value=_,q()),s.vertical.size.value!==M&&(s.vertical.size.value=M,q())}function T(M,_){const v=s[_];if(M.isFirst===!0){if(v.thumbHidden.value===!0)return;u=v.position.value,m.value=!0}else if(m.value!==!0)return;M.isFinal===!0&&(m.value=!1);const x=Gn[_],w=(v.size.value-o[_].value)/(o[_+"Inner"].value-v.thumbSize.value),S=M.distance[x.dist],E=u+(M.direction===x.dir?1:-1)*S*w;P(E,_)}function j(M,_){const v=s[_];if(v.thumbHidden.value!==!0){const x=_==="vertical"?l.verticalOffset[0]:l.horizontalOffset[0],w=M[Gn[_].offset]-x,S=v.thumbStart.value-x;if(w<S||w>S+v.thumbSize.value){const E=w-v.thumbSize.value/2,O=Dr(E/(o[_+"Inner"].value-v.thumbSize.value),0,1);P(O*Math.max(0,v.size.value-o[_].value),_)}v.ref.value!==null&&v.ref.value.dispatchEvent(new MouseEvent(M.type,M))}}function q(){b.value=!0,r!==null&&clearTimeout(r),r=setTimeout(()=>{r=null,b.value=!1},l.delay),l.onScroll!==void 0&&f()}function P(M,_){a.value[Gn[_].scroll]=M}let N=null;function V(){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;y.watch(()=>n.$q.lang.rtl,M=>{a.value!==null&&Kn(a.value,Math.abs(s.horizontal.position.value)*(M===!0?-1:1))}),y.onDeactivated(()=>{L={top:s.vertical.position.value,left:s.horizontal.position.value}}),y.onActivated(()=>{if(L===null)return;const M=a.value;M!==null&&(Kn(M,L.left),vo(M,L.top))}),y.onBeforeUnmount(f.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,_,v){g(M,_*(s[M].size.value-o[M].value)*(M==="horizontal"&&n.$q.lang.rtl===!0?-1:1),v)}});const A={scroll:s,thumbVertDir:[[So,M=>{T(M,"vertical")},void 0,{vertical:!0,...Co}]],thumbHorizDir:[[So,M=>{T(M,"horizontal")},void 0,{horizontal:!0,...Co}]],onVerticalMousedown(M){j(M,"vertical")},onHorizontalMousedown(M){j(M,"horizontal")}};return()=>y.h("div",{class:i.value,onMouseenter:V,onMouseleave:W},[y.h("div",{ref:a,class:"q-scrollarea__container scroll relative-position fit hide-scrollbar",tabindex:l.tabindex!==void 0?l.tabindex:void 0},[y.h("div",{class:"q-scrollarea__content absolute",style:d.value},It(I.default,[y.h(Rr,{debounce:0,onResize:C})])),y.h(Ea,{axis:"both",onScroll:k})]),y.h(Rr,{debounce:0,onResize:p}),y.h(ul,{store:A,barStyle:l.barStyle,verticalBarStyle:l.verticalBarStyle,horizontalBarStyle:l.horizontalBarStyle})])}}),Xr=$e({name:"QCard",props:{...Ot,tag:{type:String,default:"div"},square:Boolean,flat:Boolean,bordered:Boolean},setup(l,{slots:I}){const{proxy:{$q:t}}=y.getCurrentInstance(),b=Ft(l,t),m=y.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()=>y.h(l.tag,{class:m.value},gt(I.default))}}),Ma={target:{type:[Boolean,String,Element],default:!0},noParentEvent:Boolean},Ta={...Ma,contextMenu:Boolean};function Li({showing:l,avoidEmit:I,configureAnchorEl:t}){const{props:b,proxy:m,emit:c}=y.getCurrentInstance(),o=y.ref(null);let s=null;function n(i){return o.value===null?!1:i===void 0||i.touches===void 0||i.touches.length<=1}const e={};t===void 0&&(Object.assign(e,{hide(i){m.hide(i)},toggle(i){m.toggle(i),i.qAnchorHandled=!0},toggleKey(i){ir(i,13)===!0&&e.toggle(i)},contextClick(i){m.hide(i),Bt(i),y.nextTick(()=>{m.show(i),i.qAnchorHandled=!0})},prevent:Bt,mobileTouch(i){if(e.mobileCleanup(i),n(i)!==!0)return;m.hide(i),o.value.classList.add("non-selectable");const d=i.target;Kt(e,"anchor",[[d,"touchmove","mobileCleanup","passive"],[d,"touchend","mobileCleanup","passive"],[d,"touchcancel","mobileCleanup","passive"],[o.value,"contextmenu","prevent","notPassive"]]),s=setTimeout(()=>{s=null,m.show(i),i.qAnchorHandled=!0},300)},mobileCleanup(i){o.value.classList.remove("non-selectable"),s!==null&&(clearTimeout(s),s=null),l.value===!0&&i!==void 0&&Cn()}}),t=function(i=b.contextMenu){if(b.noParentEvent===!0||o.value===null)return;let d;i===!0?m.$q.platform.is.mobile===!0?d=[[o.value,"touchstart","mobileTouch","passive"]]:d=[[o.value,"mousedown","hide","passive"],[o.value,"contextmenu","contextClick","notPassive"]]:d=[[o.value,"click","toggle","passive"],[o.value,"keyup","toggleKey","passive"]],Kt(e,"anchor",d)});function r(){fr(e,"anchor")}function u(i){for(o.value=i;o.value.classList.contains("q-anchor--skip");)o.value=o.value.parentNode;t()}function a(){if(b.target===!1||b.target===""||m.$el.parentNode===null)o.value=null;else if(b.target===!0)u(m.$el.parentNode);else{let i=b.target;if(typeof b.target=="string")try{i=document.querySelector(b.target)}catch{i=void 0}i!=null?(o.value=i.$el||i,t()):(o.value=null,console.error(`Anchor: target "${b.target}" not found`))}}return y.watch(()=>b.contextMenu,i=>{o.value!==null&&(r(),t(i))}),y.watch(()=>b.target,()=>{o.value!==null&&r(),a()}),y.watch(()=>b.noParentEvent,i=>{o.value!==null&&(i===!0?r():t())}),y.onMounted(()=>{a(),I!==!0&&b.modelValue===!0&&o.value===null&&c("update:modelValue",!1)}),y.onBeforeUnmount(()=>{s!==null&&clearTimeout(s),r()}),{anchorEl:o,canShow:n,anchorEvents:e}}function Ra(l,I){const t=y.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 o=y.watch(()=>l.noParentEvent,()=>{t.value!==null&&(c(),I())});return y.onBeforeUnmount(o),{localScrollTarget:t,unconfigureScrollTarget:c,changeScrollEvent:m}}const Vi={modelValue:{type:Boolean,default:null},"onUpdate:modelValue":[Function,Array]},qi=["beforeShow","show","beforeHide","hide"];function zi({showing:l,canShow:I,hideOnRouteChange:t,handleShow:b,handleHide:m,processOnMount:c}){const o=y.getCurrentInstance(),{props:s,emit:n,proxy:e}=o;let r;function u(p){l.value===!0?d(p):a(p)}function a(p){if(s.disable===!0||p?.qAnchorHandled===!0||I!==void 0&&I(p)!==!0)return;const k=s["onUpdate:modelValue"]!==void 0;k===!0&&(n("update:modelValue",!0),r=p,y.nextTick(()=>{r===p&&(r=void 0)})),(s.modelValue===null||k===!1)&&i(p)}function i(p){l.value!==!0&&(l.value=!0,n("beforeShow",p),b!==void 0?b(p):n("show",p))}function d(p){if(s.disable===!0)return;const k=s["onUpdate:modelValue"]!==void 0;k===!0&&(n("update:modelValue",!1),r=p,y.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 f(p){s.disable===!0&&p===!0?s["onUpdate:modelValue"]!==void 0&&n("update:modelValue",!1):p===!0!==l.value&&(p===!0?i:h)(r)}y.watch(()=>s.modelValue,f),t!==void 0&&Ti(o)===!0&&y.watch(()=>e.$route.fullPath,()=>{t.value===!0&&l.value===!0&&d()}),y.onMounted(()=>{f(s.modelValue)});const g={show:a,hide:d,toggle:u};return Object.assign(e,g),g}let cr=[],Yr=[];function Ba(l){Yr=Yr.filter(I=>I!==l)}function kl(l){Ba(l),Yr.push(l)}function Eo(l){Ba(l),Yr.length===0&&cr.length!==0&&(cr[cr.length-1](),cr=[])}function Gr(l){Yr.length===0?l():cr.push(l)}function _l(l){cr=cr.filter(I=>I!==l)}const Mo={};let Cl=1,Al=document.body;function El(l,I){const t=document.createElement("div");if(t.id=I!==void 0?`q-portal--${I}--${Cl++}`:l,Mo.globalNodes!==void 0){const b=Mo.globalNodes.class;b!==void 0&&(t.className=b)}return Al.appendChild(t),t}function Ml(l){l.remove()}const Mr=[];function Tl(l){return Mr.find(I=>I.contentEl!==null&&I.contentEl.contains(l))}function Ia(l,I){do{if(l.$options.name==="QMenu"){if(l.hide(I),l.$props.separateClosePopup===!0)return wn(l)}else if(l.__qPortal===!0){const t=wn(l);return t?.$options.name==="QPopupProxy"?(l.hide(I),t):l}l=wn(l)}while(l!=null)}function Rl(l,I,t){for(;t!==0&&l!==void 0&&l!==null;){if(l.__qPortal===!0){if(t--,l.$options.name==="QMenu"){l=Ia(l,I);continue}l.hide(I)}l=wn(l)}}const Bl=$e({name:"QPortal",setup(l,{slots:I}){return()=>I.default()}});function Il(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 Ui(l,I,t,b){const m=y.ref(!1),c=y.ref(!1);let o=null;const s={},n=b==="dialog"&&Il(l);function e(u){if(u===!0){Eo(s),c.value=!0;return}c.value=!1,m.value===!1&&(n===!1&&o===null&&(o=El(!1,b)),m.value=!0,Mr.push(l.proxy),kl(s))}function r(u){if(c.value=!1,u!==!0)return;Eo(s),m.value=!1;const a=Mr.indexOf(l.proxy);a!==-1&&Mr.splice(a,1),o!==null&&(Ml(o),o=null)}return y.onUnmounted(()=>{r(!0)}),l.proxy.__qPortal=!0,Lt(l.proxy,"contentEl",()=>I.value),{showPortal:e,hidePortal:r,portalIsActive:m,portalIsAccessible:c,renderPortal:()=>n===!0?t():m.value===!0?[y.h(y.Teleport,{to:o},y.h(Bl,t))]:void 0}}const Ur={transitionShow:{type:String,default:"fade"},transitionHide:{type:String,default:"fade"},transitionDuration:{type:[String,Number],default:300}};function Wi(l,I=()=>{},t=()=>{}){return{transitionProps:y.computed(()=>{const b=`q-transition--${l.transitionShow||I()}`,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:y.computed(()=>`--q-transition-duration: ${l.transitionDuration}ms`)}}function Hi(){let l;const I=y.getCurrentInstance();function t(){l=void 0}return y.onDeactivated(t),y.onBeforeUnmount(t),{removeTick:t,registerTick(b){l=b,y.nextTick(()=>{l===b&&(Ri(I)===!1&&l(),l=void 0)})}}}function Yi(){let l=null;const I=y.getCurrentInstance();function t(){l!==null&&(clearTimeout(l),l=null)}return y.onDeactivated(t),y.onBeforeUnmount(t),{removeTimeout:t,registerTimeout(b,m){t(),Ri(I)===!1&&(l=setTimeout(()=>{l=null,b()},m))}}}const dr=[];let Br;function Ol(l){Br=l.keyCode===27}function Fl(){Br===!0&&(Br=!1)}function jl(l){Br===!0&&(Br=!1,ir(l,27)===!0&&dr[dr.length-1](l))}function Oa(l){window[l]("keydown",Ol),window[l]("blur",Fl),window[l]("keyup",jl),Br=!1}function Fa(l){Et.is.desktop===!0&&(dr.push(l),dr.length===1&&Oa("addEventListener"))}function An(l){const I=dr.indexOf(l);I!==-1&&(dr.splice(I,1),dr.length===0&&Oa("removeEventListener"))}const hr=[];function ja(l){hr[hr.length-1](l)}function Da(l){Et.is.desktop===!0&&(hr.push(l),hr.length===1&&document.body.addEventListener("focusin",ja))}function bi(l){const I=hr.indexOf(l);I!==-1&&(hr.splice(I,1),hr.length===0&&document.body.removeEventListener("focusin",ja))}const{notPassiveCapture:En}=_t,pr=[];function Mn(l){const I=l.target;if(I===void 0||I.nodeType===8||I.classList.contains("no-pointer-events")===!0)return;let t=Mr.length-1;for(;t>=0;){const b=Mr[t].$;if(b.type.name==="QTooltip"){t--;continue}if(b.type.name!=="QDialog")break;if(b.props.seamless!==!0)return;t--}for(let b=pr.length-1;b>=0;b--){const m=pr[b];if((m.anchorEl.value===null||m.anchorEl.value.contains(I)===!1)&&(I===document.body||m.innerRef.value!==null&&m.innerRef.value.contains(I)===!1))l.qClickOutside=!0,m.onClickOutside(l);else return}}function Pa(l){pr.push(l),pr.length===1&&(document.addEventListener("mousedown",Mn,En),document.addEventListener("touchstart",Mn,En))}function Tn(l){const I=pr.findIndex(t=>t===l);I!==-1&&(pr.splice(I,1),pr.length===0&&(document.removeEventListener("mousedown",Mn,En),document.removeEventListener("touchstart",Mn,En)))}let To,Ro;function Rn(l){const I=l.split(" ");return I.length!==2?!1:["top","center","bottom"].includes(I[0])!==!0?(console.error("Anchor/Self position must start with one of top/center/bottom"),!1):["left","middle","right","start","end"].includes(I[1])!==!0?(console.error("Anchor/Self position must end with one of left/middle/right/start/end"),!1):!0}function Na(l){return l?!(l.length!==2||typeof l[0]!="number"||typeof l[1]!="number"):!0}const vi={"start#ltr":"left","start#rtl":"right","end#ltr":"right","end#rtl":"left"};["left","middle","right"].forEach(l=>{vi[`${l}#ltr`]=l,vi[`${l}#rtl`]=l});function Bn(l,I){const t=l.split(" ");return{vertical:t[0],horizontal:vi[`${t[1]}#${I===!0?"rtl":"ltr"}`]}}function Dl(l,I){let{top:t,left:b,right:m,bottom:c,width:o,height:s}=l.getBoundingClientRect();return I!==void 0&&(t-=I[1],b-=I[0],c+=I[1],m+=I[0],o+=I[0],s+=I[1]),{top:t,bottom:c,height:s,left:b,right:m,width:o,middle:b+(m-b)/2,center:t+(c-t)/2}}function Pl(l,I,t){let{top:b,left:m}=l.getBoundingClientRect();return b+=I.top,m+=I.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 Nl(l,I){return{top:0,center:I/2,bottom:I,left:0,middle:l/2,right:l}}function Bo(l,I,t,b){return{top:l[t.vertical]-I[b.vertical],left:l[t.horizontal]-I[b.horizontal]}}function Qi(l,I=0){if(l.targetEl===null||l.anchorEl===null||I>5)return;if(l.targetEl.offsetHeight===0||l.targetEl.offsetWidth===0){setTimeout(()=>{Qi(l,I+1)},10);return}const{targetEl:t,offset:b,anchorEl:m,anchorOrigin:c,selfOrigin:o,absoluteOffset:s,fit:n,cover:e,maxHeight:r,maxWidth:u}=l;if(Et.is.ios===!0&&window.visualViewport!==void 0){const j=document.body.style,{offsetLeft:q,offsetTop:P}=window.visualViewport;q!==To&&(j.setProperty("--q-pe-left",q+"px"),To=q),P!==Ro&&(j.setProperty("--q-pe-top",P+"px"),Ro=P)}const{scrollLeft:a,scrollTop:i}=t,d=s===void 0?Dl(m,e===!0?[0,0]:b):Pl(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:f}=t,{elWidth:g,elHeight:p}=n===!0||e===!0?{elWidth:Math.max(d.width,h),elHeight:e===!0?Math.max(d.height,f):f}:{elWidth:h,elHeight:f};let k={maxWidth:u,maxHeight:r};(n===!0||e===!0)&&(k.minWidth=d.width+"px",e===!0&&(k.minHeight=d.height+"px")),Object.assign(t.style,k);const C=Nl(g,p);let T=Bo(d,C,c,o);if(s===void 0||b===void 0)Jn(T,d,C,c,o);else{const{top:j,left:q}=T;Jn(T,d,C,c,o);let P=!1;if(T.top!==j){P=!0;const N=2*b[1];d.center=d.top-=N,d.bottom-=N+2}if(T.left!==q){P=!0;const N=2*b[0];d.middle=d.left-=N,d.right-=N+2}P===!0&&(T=Bo(d,C,c,o),Jn(T,d,C,c,o))}k={top:T.top+"px",left:T.left+"px"},T.maxHeight!==void 0&&(k.maxHeight=T.maxHeight+"px",d.height>T.maxHeight&&(k.minHeight=k.maxHeight)),T.maxWidth!==void 0&&(k.maxWidth=T.maxWidth+"px",d.width>T.maxWidth&&(k.minWidth=k.maxWidth)),Object.assign(t.style,k),t.scrollTop!==i&&(t.scrollTop=i),t.scrollLeft!==a&&(t.scrollLeft=a)}function Jn(l,I,t,b,m){const c=t.bottom,o=t.right,s=xn(),n=window.innerHeight-s,e=document.body.clientWidth;if(l.top<0||l.top+c>n)if(m.vertical==="center")l.top=I[b.vertical]>n/2?Math.max(0,n-c):0,l.maxHeight=Math.min(c,n);else if(I[b.vertical]>n/2){const r=Math.min(n,b.vertical==="center"?I.center:b.vertical===m.vertical?I.bottom:I.top);l.maxHeight=Math.min(c,r),l.top=Math.max(0,r-c)}else l.top=Math.max(0,b.vertical==="center"?I.center:b.vertical===m.vertical?I.top:I.bottom),l.maxHeight=Math.min(c,n-l.top);if(l.left<0||l.left+o>e)if(l.maxWidth=Math.min(o,e),m.horizontal==="middle")l.left=I[b.horizontal]>e/2?Math.max(0,e-o):0;else if(I[b.horizontal]>e/2){const r=Math.min(e,b.horizontal==="middle"?I.middle:b.horizontal===m.horizontal?I.right:I.left);l.maxWidth=Math.min(o,r),l.left=Math.max(0,r-l.maxWidth)}else l.left=Math.max(0,b.horizontal==="middle"?I.middle:b.horizontal===m.horizontal?I.left:I.right),l.maxWidth=Math.min(o,e-l.left)}const Jr=$e({name:"QMenu",inheritAttrs:!1,props:{...Ta,...Vi,...Ot,...Ur,persistent:Boolean,autoClose:Boolean,separateClosePopup:Boolean,noEscDismiss:Boolean,noRouteDismiss:Boolean,noRefocus:Boolean,noFocus:Boolean,fit:Boolean,cover:Boolean,square:Boolean,anchor:{type:String,validator:Rn},self:{type:String,validator:Rn},offset:{type:Array,validator:Na},scrollTarget:Ln,touchPosition:Boolean,maxHeight:{type:String,default:null},maxWidth:{type:String,default:null}},emits:[...qi,"click","escapeKey"],setup(l,{slots:I,emit:t,attrs:b}){let m=null,c,o,s;const n=y.getCurrentInstance(),{proxy:e}=n,{$q:r}=e,u=y.ref(null),a=y.ref(!1),i=y.computed(()=>l.persistent!==!0&&l.noRouteDismiss!==!0),d=Ft(l,r),{registerTick:h,removeTick:f}=Hi(),{registerTimeout:g}=Yi(),{transitionProps:p,transitionStyle:k}=Wi(l),{localScrollTarget:C,changeScrollEvent:T,unconfigureScrollTarget:j}=Ra(l,z),{anchorEl:q,canShow:P}=Li({showing:a}),{hide:N}=zi({showing:a,canShow:P,handleShow:E,handleHide:O,hideOnRouteChange:i,processOnMount:!0}),{showPortal:V,hidePortal:W,renderPortal:L}=Ui(n,u,F,"menu"),A={anchorEl:q,innerRef:u,onClickOutside(B){if(l.persistent!==!0&&a.value===!0)return N(B),(B.type==="touchstart"||B.target.classList.contains("q-dialog__backdrop"))&&St(B),!0}},M=y.computed(()=>Bn(l.anchor||(l.cover===!0?"center middle":"bottom start"),r.lang.rtl)),_=y.computed(()=>l.cover===!0?M.value:Bn(l.self||"top start",r.lang.rtl)),v=y.computed(()=>(l.square===!0?" q-menu--square":"")+(d.value===!0?" q-menu--dark q-dark":"")),x=y.computed(()=>l.autoClose===!0?{onClick:U}:{}),w=y.computed(()=>a.value===!0&&l.persistent!==!0);y.watch(w,B=>{B===!0?(Fa(D),Pa(A)):(An(D),Tn(A))});function S(){Gr(()=>{let B=u.value;B&&B.contains(document.activeElement)!==!0&&(B=B.querySelector("[autofocus][tabindex], [data-autofocus][tabindex]")||B.querySelector("[autofocus] [tabindex], [data-autofocus] [tabindex]")||B.querySelector("[autofocus], [data-autofocus]")||B,B.focus({preventScroll:!0}))})}function E(B){if(m=l.noRefocus===!1?document.activeElement:null,Da(Q),V(),z(),c=void 0,B!==void 0&&(l.touchPosition||l.contextMenu)){const H=Hr(B);if(H.left!==void 0){const{top:K,left:$}=q.value.getBoundingClientRect();c={left:H.left-$,top:H.top-K}}}o===void 0&&(o=y.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(),V(!0),t("show",B)},l.transitionDuration)}function O(B){f(),W(),R(!0),m!==null&&(B===void 0||B.qClickOutside!==!0)&&(((B?.type.indexOf("key")===0?m.closest('[tabindex]:not([tabindex^="-"])'):void 0)||m).focus(),m=null),g(()=>{W(!0),t("hide",B)},l.transitionDuration)}function R(B){c=void 0,o!==void 0&&(o(),o=void 0),(B===!0||a.value===!0)&&(bi(Q),j(),Tn(A),An(D)),B!==!0&&(m=null)}function z(){(q.value!==null||l.scrollTarget!==void 0)&&(C.value=Vn(q.value,l.scrollTarget),T(C.value,Y))}function U(B){s!==!0?(Ia(e,B),t("click",B)):s=!1}function Q(B){w.value===!0&&l.noFocus!==!0&&ga(u.value,B.target)!==!0&&S()}function D(B){l.noEscDismiss!==!0&&(t("escapeKey"),N(B))}function Y(){Qi({targetEl:u.value,offset:l.offset,anchorEl:q.value,anchorOrigin:M.value,selfOrigin:_.value,absoluteOffset:c,fit:l.fit,cover:l.cover,maxHeight:l.maxHeight,maxWidth:l.maxWidth})}function F(){return y.h(y.Transition,p.value,()=>a.value===!0?y.h("div",{role:"menu",...b,ref:u,tabindex:-1,class:["q-menu q-position-engine scroll"+v.value,b.class],style:[b.style,k.value],...x.value},gt(I.default)):null)}return y.onBeforeUnmount(R),Object.assign(e,{focus:S,updatePosition:Y}),L}});let Zn,ln=0;const Mt=new Array(256);for(let l=0;l<256;l++)Mt[l]=(l+256).toString(16).substring(1);const Ll=(()=>{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 I=>{const t=new Uint8Array(I);return l.getRandomValues(t),t}}return I=>{const t=[];for(let b=I;b>0;b--)t.push(Math.floor(Math.random()*256));return t}})(),Io=4096;function yi(){(Zn===void 0||ln+16>Io)&&(ln=0,Zn=Ll(Io));const l=Array.prototype.slice.call(Zn,ln,ln+=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 Vl(l){return l??null}function Oo(l,I){return l??(I===!0?`f_${yi()}`:null)}function ql({getValue:l,required:I=!0}={}){if(or.value===!0){const t=l!==void 0?y.ref(Vl(l())):y.ref(null);return I===!0&&t.value===null&&y.onMounted(()=>{t.value=`f_${yi()}`}),l!==void 0&&y.watch(l,b=>{t.value=Oo(b,I)}),t}return l!==void 0?y.computed(()=>Oo(l(),I)):y.ref(`f_${yi()}`)}const Fo=/^on[A-Z]/;function zl(){const{attrs:l,vnode:I}=y.getCurrentInstance(),t={listeners:y.ref({}),attributes:y.ref({})};function b(){const m={},c={};for(const o in l)o!=="class"&&o!=="style"&&Fo.test(o)===!1&&(m[o]=l[o]);for(const o in I.props)Fo.test(o)===!0&&(c[o]=I.props[o]);t.attributes.value=m,t.listeners.value=c}return y.onBeforeUpdate(b),b(),t}const Ul="_q_",Zr="_q_l_",La="_q_pc_",Va="_q_fo_";function Rt(){}function Wl({validate:l,resetValidation:I,requiresQForm:t}){const b=y.inject(Va,!1);if(b!==!1){const{props:m,proxy:c}=y.getCurrentInstance();Object.assign(c,{validate:l,resetValidation:I}),y.watch(()=>m.disable,o=>{o===!0?(typeof I=="function"&&I(),b.unbindComponent(c)):b.bindComponent(c)}),y.onMounted(()=>{m.disable!==!0&&b.bindComponent(c)}),y.onBeforeUnmount(()=>{m.disable!==!0&&b.unbindComponent(c)})}else t===!0&&console.error("Parent QForm not found on useFormChild()!")}const jo=/^#[0-9a-fA-F]{3}([0-9a-fA-F]{3})?$/,Do=/^#[0-9a-fA-F]{4}([0-9a-fA-F]{4})?$/,Po=/^#([0-9a-fA-F]{3}|[0-9a-fA-F]{4}|[0-9a-fA-F]{6}|[0-9a-fA-F]{8})$/,un=/^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])\)$/,cn=/^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)\)$/,$n={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=>jo.test(l),hexaColor:l=>Do.test(l),hexOrHexaColor:l=>Po.test(l),rgbColor:l=>un.test(l),rgbaColor:l=>cn.test(l),rgbOrRgbaColor:l=>un.test(l)||cn.test(l),hexOrRgbColor:l=>jo.test(l)||un.test(l),hexaOrRgbaColor:l=>Do.test(l)||cn.test(l),anyColor:l=>Po.test(l)||un.test(l)||cn.test(l)},Hl=[!0,!1,"ondemand"],Yl={modelValue:{},error:{type:Boolean,default:null},errorMessage:String,noErrorIcon:Boolean,rules:Array,reactiveRules:Boolean,lazyRules:{type:[Boolean,String],default:!1,validator:l=>Hl.includes(l)}};function Ql(l,I){const{props:t,proxy:b}=y.getCurrentInstance(),m=y.ref(!1),c=y.ref(null),o=y.ref(!1);Wl({validate:h,resetValidation:d});let s=0,n;const e=y.computed(()=>t.rules!==void 0&&t.rules!==null&&t.rules.length!==0),r=y.computed(()=>t.disable!==!0&&e.value===!0&&I.value===!1),u=y.computed(()=>t.error===!0||m.value===!0),a=y.computed(()=>typeof t.errorMessage=="string"&&t.errorMessage.length!==0?t.errorMessage:c.value);y.watch(()=>t.modelValue,()=>{o.value=!0,r.value===!0&&t.lazyRules===!1&&f()});function i(){t.lazyRules!=="ondemand"&&r.value===!0&&o.value===!0&&f()}y.watch(()=>t.reactiveRules,g=>{g===!0?n===void 0&&(n=y.watch(()=>t.rules,i,{immediate:!0,deep:!0})):n!==void 0&&(n(),n=void 0)},{immediate:!0}),y.watch(()=>t.lazyRules,i),y.watch(l,g=>{g===!0?o.value=!0:r.value===!0&&t.lazyRules!=="ondemand"&&f()});function d(){s++,I.value=!1,o.value=!1,m.value=!1,c.value=null,f.cancel()}function h(g=t.modelValue){if(t.disable===!0||e.value===!1)return!0;const p=++s,k=I.value!==!0?()=>{o.value=!0}:()=>{},C=(j,q)=>{j===!0&&k(),m.value=j,c.value=q||null,I.value=!1},T=[];for(let j=0;j<t.rules.length;j++){const q=t.rules[j];let P;if(typeof q=="function"?P=q(g,$n):typeof q=="string"&&$n[q]!==void 0&&(P=$n[q](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):(I.value=!0,Promise.all(T).then(j=>{if(j===void 0||Array.isArray(j)===!1||j.length===0)return p===s&&C(!1),!0;const q=j.find(P=>P===!1||typeof P=="string");return p===s&&C(q!==void 0,q),q===void 0},j=>(p===s&&(console.error(j),C(!0)),!1)))}const f=Ni(h,0);return y.onBeforeUnmount(()=>{n?.(),f.cancel()}),Object.assign(b,{resetValidation:d,validate:h}),Lt(b,"hasError",()=>u.value),{isDirtyModel:o,hasRules:e,hasError:u,errorMessage:a,validate:h,resetValidation:d}}function Qr(l){return l!=null&&(""+l).length!==0}const Kl={...Ot,...Yl,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},qn={...Kl,maxlength:[Number,String]},Ki=["update:modelValue","clear","focus","blur"];function Xi({requiredForAttr:l=!0,tagProp:I,changeEvent:t=!1}={}){const{props:b,proxy:m}=y.getCurrentInstance(),c=Ft(b,m.$q),o=ql({required:l,getValue:()=>b.for});return{requiredForAttr:l,changeEvent:t,tag:I===!0?y.computed(()=>b.tag):{value:"label"},isDark:c,editable:y.computed(()=>b.disable!==!0&&b.readonly!==!0),innerLoading:y.ref(!1),focused:y.ref(!1),hasPopupOpen:!1,splitAttrs:zl(),targetUid:o,rootRef:y.ref(null),targetRef:y.ref(null),controlRef:y.ref(null)}}function Gi(l){const{props:I,emit:t,slots:b,attrs:m,proxy:c}=y.getCurrentInstance(),{$q:o}=c;let s=null;l.hasValue===void 0&&(l.hasValue=y.computed(()=>Qr(I.modelValue))),l.emitValue===void 0&&(l.emitValue=w=>{t("update:modelValue",w)}),l.controlEvents===void 0&&(l.controlEvents={onFocusin:N,onFocusout:V}),Object.assign(l,{clearValue:W,onControlFocusin:N,onControlFocusout:V,focus:q}),l.computedCounter===void 0&&(l.computedCounter=y.computed(()=>{if(I.counter!==!1){const w=typeof I.modelValue=="string"||typeof I.modelValue=="number"?(""+I.modelValue).length:Array.isArray(I.modelValue)===!0?I.modelValue.length:0,S=I.maxlength!==void 0?I.maxlength:I.maxValues;return w+(S!==void 0?" / "+S:"")}}));const{isDirtyModel:n,hasRules:e,hasError:r,errorMessage:u,resetValidation:a}=Ql(l.focused,l.innerLoading),i=l.floatingLabel!==void 0?y.computed(()=>I.stackLabel===!0||l.focused.value===!0||l.floatingLabel.value===!0):y.computed(()=>I.stackLabel===!0||l.focused.value===!0||l.hasValue.value===!0),d=y.computed(()=>I.bottomSlots===!0||I.hint!==void 0||e.value===!0||I.counter===!0||I.error!==null),h=y.computed(()=>I.filled===!0?"filled":I.outlined===!0?"outlined":I.borderless===!0?"borderless":I.standout?"standout":"standard"),f=y.computed(()=>`q-field row no-wrap items-start q-field--${h.value}`+(l.fieldClass!==void 0?` ${l.fieldClass.value}`:"")+(I.rounded===!0?" q-field--rounded":"")+(I.square===!0?" q-field--square":"")+(i.value===!0?" q-field--float":"")+(p.value===!0?" q-field--labeled":"")+(I.dense===!0?" q-field--dense":"")+(I.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":"")+(I.hideBottomSpace!==!0&&d.value===!0?" q-field--with-bottom":"")+(I.disable===!0?" q-field--disabled":I.readonly===!0?" q-field--readonly":"")),g=y.computed(()=>"q-field__control relative-position row no-wrap"+(I.bgColor!==void 0?` bg-${I.bgColor}`:"")+(r.value===!0?" text-negative":typeof I.standout=="string"&&I.standout.length!==0&&l.focused.value===!0?` ${I.standout}`:I.color!==void 0?` text-${I.color}`:"")),p=y.computed(()=>I.labelSlot===!0||I.label!==void 0),k=y.computed(()=>"q-field__label no-pointer-events absolute ellipsis"+(I.labelColor!==void 0&&r.value!==!0?` text-${I.labelColor}`:"")),C=y.computed(()=>({id:l.targetUid.value,editable:l.editable.value,focused:l.focused.value,floatingLabel:i.value,modelValue:I.modelValue,emitValue:l.emitValue})),T=y.computed(()=>{const w={};return l.targetUid.value&&(w.for=l.targetUid.value),I.disable===!0&&(w["aria-disabled"]="true"),w});function j(){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 q(){Gr(j)}function P(){_l(j);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 V(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),o.platform.is.mobile!==!0?(l.targetRef?.value||l.rootRef.value).focus():l.rootRef.value.contains(document.activeElement)===!0&&document.activeElement.blur(),I.type==="file"&&(l.inputRef.value.value=null),t("update:modelValue",null),l.changeEvent===!0&&t("change",null),t("clear",I.modelValue),y.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(y.h("div",{class:"q-field__prepend q-field__marginal row no-wrap items-center",key:"prepend",onClick:Bt},b.prepend())),w.push(y.h("div",{class:"q-field__control-container col relative-position row no-wrap q-anchor--skip"},M())),r.value===!0&&I.noErrorIcon===!1&&w.push(v("error",[y.h(bt,{name:o.iconSet.field.error,color:"negative"})])),I.loading===!0||l.innerLoading.value===!0?w.push(v("inner-loading-append",b.loading!==void 0?b.loading():[y.h(ma,{color:I.color})])):I.clearable===!0&&l.hasValue.value===!0&&l.editable.value===!0&&w.push(v("inner-clearable-append",[y.h(bt,{class:"q-field__focusable-action",name:I.clearIcon||o.iconSet.field.clear,tabindex:0,role:"button","aria-hidden":"false","aria-label":o.lang.label.clear,onKeyup:L,onClick:W})])),b.append!==void 0&&w.push(y.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(v("inner-append",l.getInnerAppend())),l.getControlChild!==void 0&&w.push(l.getControlChild()),w}function M(){const w=[];return I.prefix!==void 0&&I.prefix!==null&&w.push(y.h("div",{class:"q-field__prefix no-pointer-events row items-center"},I.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(y.h("div",{ref:l.targetRef,class:"q-field__native row",tabindex:-1,...l.splitAttrs.attributes.value,"data-autofocus":I.autofocus===!0||void 0},b.control(C.value))),p.value===!0&&w.push(y.h("div",{class:k.value},gt(b.label,I.label))),I.suffix!==void 0&&I.suffix!==null&&w.push(y.h("div",{class:"q-field__suffix no-pointer-events row items-center"},I.suffix)),w.concat(gt(b.default))}function _(){let w,S;r.value===!0?u.value!==null?(w=[y.h("div",{role:"alert"},u.value)],S=`q--slot-error-${u.value}`):(w=gt(b.error),S="q--slot-error"):(I.hideHint!==!0||l.focused.value===!0)&&(I.hint!==void 0?(w=[y.h("div",I.hint)],S=`q--slot-hint-${I.hint}`):(w=gt(b.hint),S="q--slot-hint"));const E=I.counter===!0||b.counter!==void 0;if(I.hideBottomSpace===!0&&E===!1&&w===void 0)return;const O=y.h("div",{key:S,class:"q-field__messages col"},w);return y.h("div",{class:"q-field__bottom row items-start q-field__bottom--"+(I.hideBottomSpace!==!0?"animated":"stale"),onClick:Bt},[I.hideBottomSpace===!0?O:y.h(y.Transition,{name:"q-transition--field-message"},()=>O),E===!0?y.h("div",{class:"q-field__counter"},b.counter!==void 0?b.counter():l.computedCounter.value):null])}function v(w,S){return S===null?null:y.h("div",{key:w,class:"q-field__append q-field__marginal row no-wrap items-center q-anchor--skip"},S)}let x=!1;return y.onDeactivated(()=>{x=!0}),y.onActivated(()=>{x===!0&&I.autofocus===!0&&c.focus()}),I.autofocus===!0&&y.onMounted(()=>{c.focus()}),y.onBeforeUnmount(()=>{s!==null&&clearTimeout(s)}),Object.assign(c,{focus:q,blur:P}),function(){const S=l.getControl===void 0&&b.control===void 0?{...l.splitAttrs.attributes.value,"data-autofocus":I.autofocus===!0||void 0,...T.value}:T.value;return y.h(l.tag.value,{ref:l.rootRef,class:[f.value,m.class],style:m.style,...S},[b.before!==void 0?y.h("div",{class:"q-field__before q-field__marginal row no-wrap items-center",onClick:Bt},b.before()):null,y.h("div",{class:"q-field__inner relative-position col self-stretch"},[y.h("div",{ref:l.controlRef,class:g.value,tabindex:-1,...l.controlEvents},A()),d.value===!0?_():null]),b.after!==void 0?y.h("div",{class:"q-field__after q-field__marginal row no-wrap items-center",onClick:Bt},b.after()):null])}}const Xl=$e({name:"QField",inheritAttrs:!1,props:{...qn,tag:{type:String,default:"label"}},emits:Ki,setup(){return Gi(Xi({tagProp:!0}))}}),Gl={xs:8,sm:10,md:14,lg:20,xl:24},qa=$e({name:"QChip",props:{...Ot,...Or,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:I,emit:t}){const{proxy:{$q:b}}=y.getCurrentInstance(),m=Ft(l,b),c=Fr(l,Gl),o=y.computed(()=>l.selected===!0||l.icon!==void 0),s=y.computed(()=>l.selected===!0?l.iconSelected||b.iconSet.chip.selected:l.icon),n=y.computed(()=>l.iconRemove||b.iconSet.chip.remove),e=y.computed(()=>l.disable===!1&&(l.clickable===!0||l.selected!==null)),r=y.computed(()=>{const f=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}`:"")+(f?` text-${f} 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=y.computed(()=>{const f=l.disable===!0?{tabindex:-1,"aria-disabled":"true"}:{tabindex:l.tabindex||0},g={...f,role:"button","aria-hidden":"false","aria-label":l.removeAriaLabel||b.lang.label.remove};return{chip:f,remove:g}});function a(f){f.keyCode===13&&i(f)}function i(f){l.disable||(t("update:selected",!l.selected),t("click",f))}function d(f){(f.keyCode===void 0||f.keyCode===13)&&(St(f),l.disable===!1&&(t("update:modelValue",!1),t("remove")))}function h(){const f=[];e.value===!0&&f.push(y.h("div",{class:"q-focus-helper"})),o.value===!0&&f.push(y.h(bt,{class:"q-chip__icon q-chip__icon--left",name:s.value}));const g=l.label!==void 0?[y.h("div",{class:"ellipsis"},[l.label])]:void 0;return f.push(y.h("div",{class:"q-chip__content col row no-wrap items-center q-anchor--skip"},sa(I.default,g))),l.iconRight&&f.push(y.h(bt,{class:"q-chip__icon q-chip__icon--right",name:l.iconRight})),l.removable===!0&&f.push(y.h(bt,{class:"q-chip__icon q-chip__icon--remove cursor-pointer",name:n.value,...u.value.remove,onClick:d,onKeyup:d})),f}return()=>{if(l.modelValue===!1)return;const f={class:r.value,style:c.value};return e.value===!0&&Object.assign(f,u.value.chip,{onClick:i,onKeyup:a}),Cs("div",f,h(),"ripple",l.ripple!==!1&&l.disable!==!0,()=>[[ba,l.ripple]])}}}),Cr=$e({name:"QItem",props:{...Ot,...ha,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:I,emit:t}){const{proxy:{$q:b}}=y.getCurrentInstance(),m=Ft(l,b),{hasLink:c,linkAttrs:o,linkClass:s,linkTag:n,navigateOnClick:e}=Bi(),r=y.ref(null),u=y.ref(null),a=y.computed(()=>l.clickable===!0||c.value===!0||l.tag==="label"),i=y.computed(()=>l.disable!==!0&&a.value===!0),d=y.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":"")+(i.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=y.computed(()=>l.insetLevel===void 0?null:{["padding"+(b.lang.rtl===!0?"Right":"Left")]:16+l.insetLevel*56+"px"});function f(k){i.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(i.value===!0&&ir(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=Mi(I.default,[]);return i.value===!0&&k.unshift(y.h("div",{class:"q-focus-helper",tabindex:-1,ref:u})),k}return()=>{const k={ref:r,class:d.value,style:h.value,role:"listitem",onClick:f,onKeyup:g};return i.value===!0?(k.tabindex=l.tabindex||"0",Object.assign(k,o.value)):a.value===!0&&(k["aria-disabled"]="true"),y.h(n.value,k,p())}}}),Ar=$e({name:"QItemSection",props:{avatar:Boolean,thumbnail:Boolean,side:Boolean,top:Boolean,noWrap:Boolean},setup(l,{slots:I}){const t=y.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()=>y.h("div",{class:t.value},gt(I.default))}}),wi=$e({name:"QItemLabel",props:{overline:Boolean,caption:Boolean,header:Boolean,lines:[Number,String]},setup(l,{slots:I}){const t=y.computed(()=>parseInt(l.lines,10)),b=y.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=y.computed(()=>l.lines!==void 0&&t.value>1?{overflow:"hidden",display:"-webkit-box","-webkit-box-orient":"vertical","-webkit-line-clamp":t.value}:null);return()=>y.h("div",{style:m.value,class:b.value},gt(I.default))}});function Jl(l,I,t){function b(){}return y.onBeforeUnmount(()=>{l.value===!0&&void 0}),{removeFromHistory:b,addToHistory(){}}}let Pr=0,ei,ti,Vr,ri=!1,No,Lo,Vo,lr=null;function Zl(l){$l(l)&&St(l)}function $l(l){if(l.target===document.body||l.target.classList.contains("q-layout__backdrop"))return!0;const I=Ys(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<I.length;c++){const o=I[c];if(gl(o,b))return b?m<0&&o.scrollTop===0?!0:m>0&&o.scrollTop+o.clientHeight===o.scrollHeight:m<0&&o.scrollLeft===0?!0:m>0&&o.scrollLeft+o.clientWidth===o.scrollWidth}return!0}function qo(l){l.target===document&&(document.scrollingElement.scrollTop=document.scrollingElement.scrollTop)}function fn(l){ri!==!0&&(ri=!0,requestAnimationFrame(()=>{ri=!1;const{height:I}=l.target,{clientHeight:t,scrollTop:b}=document.scrollingElement;(Vr===void 0||I!==window.innerHeight)&&(Vr=t-I,document.scrollingElement.scrollTop=b),b>Vr&&(document.scrollingElement.scrollTop-=Math.ceil((b-Vr)/8))}))}function zo(l){const I=document.body,t=window.visualViewport!==void 0;if(l==="add"){const{overflowY:b,overflowX:m}=window.getComputedStyle(I);ei=Di(window),ti=ji(window),No=I.style.left,Lo=I.style.top,Vo=window.location.href,I.style.left=`-${ei}px`,I.style.top=`-${ti}px`,m!=="hidden"&&(m==="scroll"||I.scrollWidth>window.innerWidth)&&I.classList.add("q-body--force-scrollbar-x"),b!=="hidden"&&(b==="scroll"||I.scrollHeight>window.innerHeight)&&I.classList.add("q-body--force-scrollbar-y"),I.classList.add("q-body--prevent-scroll"),document.qScrollPrevented=!0,Et.is.ios===!0&&(t===!0?(window.scrollTo(0,0),window.visualViewport.addEventListener("resize",fn,_t.passiveCapture),window.visualViewport.addEventListener("scroll",fn,_t.passiveCapture),window.scrollTo(0,0)):window.addEventListener("scroll",qo,_t.passiveCapture))}Et.is.desktop===!0&&Et.is.mac===!0&&window[`${l}EventListener`]("wheel",Zl,_t.notPassive),l==="remove"&&(Et.is.ios===!0&&(t===!0?(window.visualViewport.removeEventListener("resize",fn,_t.passiveCapture),window.visualViewport.removeEventListener("scroll",fn,_t.passiveCapture)):window.removeEventListener("scroll",qo,_t.passiveCapture)),I.classList.remove("q-body--prevent-scroll"),I.classList.remove("q-body--force-scrollbar-x"),I.classList.remove("q-body--force-scrollbar-y"),document.qScrollPrevented=!1,I.style.left=No,I.style.top=Lo,window.location.href===Vo&&window.scrollTo(ei,ti),Vr=void 0)}function eu(l){let I="add";if(l===!0){if(Pr++,lr!==null){clearTimeout(lr),lr=null;return}if(Pr>1)return}else{if(Pr===0||(Pr--,Pr>0))return;if(I="remove",Et.is.ios===!0&&Et.is.nativeMobile===!0){lr!==null&&clearTimeout(lr),lr=setTimeout(()=>{zo(I),lr=null},100);return}}zo(I)}function tu(){let l;return{preventBodyScroll(I){I!==l&&(l!==void 0||I===!0)&&(l=I,eu(I))}}}let dn=0;const ru={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"},Uo={standard:["scale","scale"],top:["slide-down","slide-up"],bottom:["slide-up","slide-down"],right:["slide-left","slide-right"],left:["slide-right","slide-left"]},zn=$e({name:"QDialog",inheritAttrs:!1,props:{...Vi,...Ur,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:[...qi,"shake","click","escapeKey"],setup(l,{slots:I,emit:t,attrs:b}){const m=y.getCurrentInstance(),c=y.ref(null),o=y.ref(!1),s=y.ref(!1);let n=null,e=null,r,u;const a=y.computed(()=>l.persistent!==!0&&l.noRouteDismiss!==!0&&l.seamless!==!0),{preventBodyScroll:i}=tu(),{registerTimeout:d}=Yi(),{registerTick:h,removeTick:f}=Hi(),{transitionProps:g,transitionStyle:p}=Wi(l,()=>Uo[l.position][0],()=>Uo[l.position][1]),k=y.computed(()=>p.value+(l.backdropFilter!==void 0?`;backdrop-filter:${l.backdropFilter};-webkit-backdrop-filter:${l.backdropFilter}`:"")),{showPortal:C,hidePortal:T,portalIsAccessible:j,renderPortal:q}=Ui(m,c,z,"dialog"),{hide:P}=zi({showing:o,hideOnRouteChange:a,handleShow:A,handleHide:M,processOnMount:!0});Jl(o);const N=y.computed(()=>`q-dialog__inner flex no-pointer-events q-dialog__inner--${l.maximized===!0?"maximized":"minimized"} q-dialog__inner--${l.position} ${ru[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":"")),V=y.computed(()=>o.value===!0&&l.seamless!==!0),W=y.computed(()=>l.autoClose===!0?{onClick:E}:{}),L=y.computed(()=>[`q-dialog fullscreen no-pointer-events q-dialog--${V.value===!0?"modal":"seamless"}`,b.class]);y.watch(()=>l.maximized,U=>{o.value===!0&&S(U)}),y.watch(V,U=>{i(U),U===!0?(Da(R),Fa(x)):(bi(R),An(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(_)):f(),d(()=>{if(m.proxy.$q.platform.is.ios===!0){if(l.seamless!==!0&&document.activeElement){const{top:Q,bottom:D}=document.activeElement.getBoundingClientRect(),{innerHeight:Y}=window,F=window.visualViewport!==void 0?window.visualViewport.height:Y;Q>0&&D>F/2&&(document.scrollingElement.scrollTop=Math.min(document.scrollingElement.scrollHeight-F,D>=Y?1/0:Math.ceil(document.scrollingElement.scrollTop+D-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){f(),w(!0),s.value=!0,T(),e!==null&&(((U?.type.indexOf("key")===0?e.closest('[tabindex]:not([tabindex^="-"])'):void 0)||e).focus(),e=null),d(()=>{T(!0),s.value=!1,t("hide",U)},l.transitionDuration)}function _(U){Gr(()=>{let Q=c.value;if(Q!==null){if(U!==void 0){const D=Q.querySelector(U);if(D!==null){D.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 v(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&&v():(t("escapeKey"),P()))}function w(U){n!==null&&(clearTimeout(n),n=null),(U===!0||o.value===!0)&&(S(!1),l.seamless!==!0&&(i(!1),bi(R),An(x))),U!==!0&&(e=null)}function S(U){U===!0?r!==!0&&(dn<1&&document.body.classList.add("q-body--dialog"),dn++,r=!0):r===!0&&(dn<2&&document.body.classList.remove("q-body--dialog"),dn--,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&&v()}function R(U){l.allowFocusOutside!==!0&&j.value===!0&&ga(c.value,U.target)!==!0&&_('[tabindex]:not([tabindex="-1"])')}Object.assign(m.proxy,{focus:_,shake:v,__updateRefocusTarget(U){e=U||null}}),y.onBeforeUnmount(w);function z(){return y.h("div",{role:"dialog","aria-modal":V.value===!0?"true":"false",...b,class:L.value},[y.h(y.Transition,{name:"q-transition--fade",appear:!0},()=>V.value===!0?y.h("div",{class:"q-dialog__backdrop fixed-full",style:k.value,"aria-hidden":"true",tabindex:-1,onClick:O}):null),y.h(y.Transition,g.value,()=>o.value===!0?y.h("div",{ref:c,class:N.value,style:p.value,tabindex:-1,...W.value},gt(I.default)):null)])}return q}});let In=!1;{const l=document.createElement("div");l.setAttribute("dir","rtl"),Object.assign(l.style,{width:"1px",height:"1px",overflow:"auto"});const I=document.createElement("div");Object.assign(I.style,{width:"1000px",height:"1px"}),document.body.appendChild(l),l.appendChild(I),l.scrollLeft=-1e3,In=l.scrollLeft>=0,l.remove()}const Ut=1e3,nu=["start","center","end","start-force","center-force","end-force"],za=Array.prototype.filter,iu=window.getComputedStyle(document.body).overflowAnchor===void 0?Pn:function(l,I){l!==null&&(l._qOverflowAnimationFrame!==void 0&&cancelAnimationFrame(l._qOverflowAnimationFrame),l._qOverflowAnimationFrame=requestAnimationFrame(()=>{if(l===null)return;l._qOverflowAnimationFrame=void 0;const t=l.children||[];za.call(t,m=>m.dataset&&m.dataset.qVsAnchor!==void 0).forEach(m=>{delete m.dataset.qVsAnchor});const b=t[I];b?.dataset&&(b.dataset.qVsAnchor="")}))};function Tr(l,I){return l+I}function ni(l,I,t,b,m,c,o,s){const n=l===window?document.scrollingElement||document.documentElement:l,e=m===!0?"offsetWidth":"offsetHeight",r={scrollStart:0,scrollViewSize:-o-s,scrollMaxSize:0,offsetStart:-o,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=(In===!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(I!==l){const u=n.getBoundingClientRect(),a=I.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 Wo(l,I,t,b){I==="end"&&(I=(l===window?document.body:l)[t===!0?"scrollWidth":"scrollHeight"]),l===window?t===!0?(b===!0&&(I=(In===!0?document.body.scrollWidth-document.documentElement.clientWidth:0)-I),window.scrollTo(I,window.pageYOffset||window.scrollY||document.body.scrollTop||0)):window.scrollTo(window.pageXOffset||window.scrollX||document.body.scrollLeft||0,I):t===!0?(b===!0&&(I=(In===!0?l.scrollWidth-l.offsetWidth:0)-I),l.scrollLeft=I):l.scrollTop=I}function Nr(l,I,t,b){if(t>=b)return 0;const m=I.length,c=Math.floor(t/Ut),o=Math.floor((b-1)/Ut)+1;let s=l.slice(c,o).reduce(Tr,0);return t%Ut!==0&&(s-=I.slice(c*Ut,t).reduce(Tr,0)),b%Ut!==0&&b!==m&&(s-=I.slice(b,o*Ut).reduce(Tr,0)),s}const Ua={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]},Wa=Object.keys(Ua),xi={virtualScrollHorizontal:Boolean,onVirtualScroll:Function,...Ua};function Ha({virtualScrollLength:l,getVirtualScrollTarget:I,getVirtualScrollEl:t,virtualScrollItemSizeComputed:b}){const m=y.getCurrentInstance(),{props:c,emit:o,proxy:s}=m,{$q:n}=s;let e,r,u,a=[],i;const d=y.ref(0),h=y.ref(0),f=y.ref({}),g=y.ref(null),p=y.ref(null),k=y.ref(null),C=y.ref({from:0,to:0}),T=y.computed(()=>c.tableColspan!==void 0?c.tableColspan:100);b===void 0&&(b=y.computed(()=>c.virtualScrollItemSize));const j=y.computed(()=>b.value+";"+c.virtualScrollHorizontal),q=y.computed(()=>j.value+";"+c.virtualScrollSliceRatioBefore+";"+c.virtualScrollSliceRatioAfter);y.watch(q,()=>{v()}),y.watch(j,P);function P(){_(r,!0)}function N(O){_(O===void 0?r:O)}function V(O,R){const z=I();if(z==null||z.nodeType===8)return;const U=ni(z,t(),g.value,p.value,c.virtualScrollHorizontal,n.lang.rtl,c.virtualScrollStickySizeStart,c.virtualScrollStickySizeEnd);u!==U.scrollViewSize&&v(U.scrollViewSize),L(z,U,Math.min(l.value-1,Math.max(0,parseInt(O,10)||0)),0,nu.indexOf(R)!==-1?R:r!==-1&&O>r?"end":"start")}function W(){const O=I();if(O==null||O.nodeType===8)return;const R=ni(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&&v(R.scrollViewSize),A(C.value.from);const Q=Math.floor(R.scrollMaxSize-Math.max(R.scrollViewSize,R.offsetEnd)-Math.min(i[z],R.scrollViewSize/2));if(Q>0&&Math.ceil(R.scrollStart)>=Q){L(O,R,z,R.scrollMaxSize-R.offsetEnd-a.reduce(Tr,0));return}let D=0,Y=R.scrollStart-R.offsetStart,F=Y;if(Y<=U&&Y+R.scrollViewSize>=d.value)Y-=d.value,D=C.value.from,F=Y;else for(let B=0;Y>=a[B]&&D<z;B++)Y-=a[B],D+=Ut;for(;Y>0&&D<z;)Y-=i[D],Y>-R.scrollViewSize?(D++,F=Y):F=i[D]+Y;L(O,R,D,F)}function L(O,R,z,U,Q){const D=typeof Q=="string"&&Q.indexOf("-force")!==-1,Y=D===!0?Q.replace("-force",""):Q,F=Y!==void 0?Y:"start";let B=Math.max(0,z-f.value[F]),H=B+f.value.total;H>l.value&&(H=l.value,B=Math.max(0,H-f.value.total)),e=R.scrollStart;const K=B!==C.value.from||H!==C.value.to;if(K===!1&&Y===void 0){w(z);return}const{activeElement:$}=document,G=k.value;K===!0&&G!==null&&G!==$&&G.contains($)===!0&&(G.addEventListener("focusout",M),setTimeout(()=>{G?.removeEventListener("focusout",M)})),iu(G,z-B);const ee=Y!==void 0?i.slice(B,z).reduce(Tr,0):0;if(K===!0){const ce=H>=C.value.from&&B<=C.value.to?C.value.to:H;C.value={from:B,to:ce},d.value=Nr(a,i,0,B),h.value=Nr(a,i,H,l.value),requestAnimationFrame(()=>{C.value.to!==H&&e===R.scrollStart&&(C.value={from:C.value.from,to:H},h.value=Nr(a,i,H,l.value))})}requestAnimationFrame(()=>{if(e!==R.scrollStart)return;K===!0&&A(B);const ce=i.slice(B,z).reduce(Tr,0),ue=ce+R.offsetStart+d.value,J=ue+i[z];let le=ue+U;if(Y!==void 0){const ae=ce-ee,te=R.scrollStart+ae;le=D!==!0&&te<ue&&J<te+R.scrollViewSize?te:Y==="end"?J-R.scrollViewSize:ue-(Y==="start"?0:Math.round((R.scrollViewSize-i[z])/2))}e=le,Wo(O,le,c.virtualScrollHorizontal,n.lang.rtl),w(z)})}function A(O){const R=k.value;if(R){const z=za.call(R.children,B=>B.classList&&B.classList.contains("q-virtual-scroll--skip")===!1),U=z.length,Q=c.virtualScrollHorizontal===!0?B=>B.getBoundingClientRect().width:B=>B.offsetHeight;let D=O,Y,F;for(let B=0;B<U;){for(Y=Q(z[B]),B++;B<U&&z[B].classList.contains("q-virtual-scroll--with-prev")===!0;)Y+=Q(z[B]),B++;F=Y-i[D],F!==0&&(i[D]+=F,a[Math.floor(D/Ut)]+=F),D++}}}function M(){k.value?.focus()}function _(O,R){const z=1*b.value;(R===!0||Array.isArray(i)===!1)&&(i=[]);const U=i.length;i.length=l.value;for(let D=l.value-1;D>=U;D--)i[D]=z;const Q=Math.floor((l.value-1)/Ut);a=[];for(let D=0;D<=Q;D++){let Y=0;const F=Math.min((D+1)*Ut,l.value);for(let B=D*Ut;B<F;B++)Y+=i[B];a.push(Y)}r=-1,e=void 0,d.value=Nr(a,i,0,C.value.from),h.value=Nr(a,i,C.value.to,l.value),O>=0?(A(C.value.from),y.nextTick(()=>{V(O)})):S()}function v(O){if(O===void 0&&typeof window<"u"){const Y=I();Y!=null&&Y.nodeType!==8&&(O=ni(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),D=Math.max(1,Q,Math.ceil((c.virtualScrollSliceSize>0?c.virtualScrollSliceSize:10)/U));f.value={total:Math.ceil(D*U),start:Math.ceil(D*R),center:Math.ceil(D*(.5+R)),end:Math.ceil(D*(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"?y.h(O,{class:"q-virtual-scroll__padding",key:"before",ref:g},[y.h("tr",[y.h("td",{style:{[z]:`${d.value}px`,...U},colspan:T.value})])]):y.h(O,{class:"q-virtual-scroll__padding",key:"before",ref:g,style:{[z]:`${d.value}px`,...U}}),y.h(O,{class:"q-virtual-scroll__content",key:"content",ref:k,tabindex:-1},R.flat()),O==="tbody"?y.h(O,{class:"q-virtual-scroll__padding",key:"after",ref:p},[y.h("tr",[y.h("td",{style:{[z]:`${h.value}px`,...U},colspan:T.value})])]):y.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&&o("virtualScroll",{index:O,from:C.value.from,to:C.value.to-1,direction:O<r?"decrease":"increase",ref:s}),r=O)}v();const S=Ni(W,n.platform.is.ios===!0?120:35);y.onBeforeMount(()=>{v()});let E=!1;return y.onDeactivated(()=>{E=!0}),y.onActivated(()=>{if(E!==!0)return;const O=I();e!==void 0&&O!==void 0&&O!==null&&O.nodeType!==8?Wo(O,e,c.virtualScrollHorizontal,n.lang.rtl):V(r)}),y.onBeforeUnmount(()=>{S.cancel()}),Object.assign(s,{scrollTo:V,reset:P,refresh:N}),{virtualScrollSliceRange:C,virtualScrollSliceSizeComputed:f,setVirtualScrollSize:v,onVirtualScrollEvt:S,localResetVirtualScroll:_,padVirtualScroll:x,scrollTo:V,reset:P,refresh:N}}const ou=/[\u3000-\u303f\u3040-\u309f\u30a0-\u30ff\uff00-\uff9f\u4e00-\u9faf\u3400-\u4dbf]/,au=/[\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,su=/[\u3131-\u314e\u314f-\u3163\uac00-\ud7a3]/,lu=/[a-z0-9_ -]$/i;function Ya(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?lu.test(t.data)===!1:ou.test(t.data)===!0||au.test(t.data)===!0||su.test(t.data)===!0)===!0&&(t.target.qComposing=!0)}}function rr(l,I){if(l===I)return!0;if(l!==null&&I!==null&&typeof l=="object"&&typeof I=="object"){if(l.constructor!==I.constructor)return!1;let t,b;if(l.constructor===Array){if(t=l.length,t!==I.length)return!1;for(b=t;b--!==0;)if(rr(l[b],I[b])!==!0)return!1;return!0}if(l.constructor===Map){if(l.size!==I.size)return!1;let c=l.entries();for(b=c.next();b.done!==!0;){if(I.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],I.get(b.value[0]))!==!0)return!1;b=c.next()}return!0}if(l.constructor===Set){if(l.size!==I.size)return!1;const c=l.entries();for(b=c.next();b.done!==!0;){if(I.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!==I.length)return!1;for(b=t;b--!==0;)if(l[b]!==I[b])return!1;return!0}if(l.constructor===RegExp)return l.source===I.source&&l.flags===I.flags;if(l.valueOf!==Object.prototype.valueOf)return l.valueOf()===I.valueOf();if(l.toString!==Object.prototype.toString)return l.toString()===I.toString();const m=Object.keys(l).filter(c=>l[c]!==void 0);if(t=m.length,t!==Object.keys(I).filter(c=>I[c]!==void 0).length)return!1;for(b=t;b--!==0;){const c=m[b];if(rr(l[c],I[c])!==!0)return!1}return!0}return l!==l&&I!==I}function Qa(l){return l!==null&&typeof l=="object"&&Array.isArray(l)!==!0}function On(l){return Object.prototype.toString.call(l)==="[object Date]"}function Si(l){return typeof l=="number"&&isFinite(l)}const Ho=l=>["add","add-unique","toggle"].includes(l),uu=".*+?^${}()|[]\\",cu=Object.keys(qn);function ii(l,I){if(typeof l=="function")return l;const t=l!==void 0?l:I;return b=>b!==null&&typeof b=="object"&&t in b?b[t]:b}const Un=$e({name:"QSelect",inheritAttrs:!1,props:{...xi,...Nn,...qn,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:Ho},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:xi.virtualScrollItemSize.type,onNewValue:Function,onFilter:Function},emits:[...Ki,"add","remove","inputValue","keyup","keypress","keydown","popupShow","popupHide","filterAbort"],setup(l,{slots:I,emit:t}){const{proxy:b}=y.getCurrentInstance(),{$q:m}=b,c=y.ref(!1),o=y.ref(!1),s=y.ref(-1),n=y.ref(""),e=y.ref(!1),r=y.ref(!1);let u=null,a=null,i,d,h,f=null,g,p,k,C;const T=y.ref(null),j=y.ref(null),q=y.ref(null),P=y.ref(null),N=y.ref(null),V=ya(l),W=Ya(me),L=y.computed(()=>Array.isArray(l.options)?l.options.length:0),A=y.computed(()=>l.virtualScrollItemSize===void 0?l.optionsDense===!0?24:48:l.virtualScrollItemSize),{virtualScrollSliceRange:M,virtualScrollSliceSizeComputed:_,localResetVirtualScroll:v,padVirtualScroll:x,onVirtualScrollEvt:w,scrollTo:S,setVirtualScrollSize:E}=Ha({virtualScrollLength:L,getVirtualScrollTarget:nt,getVirtualScrollEl:He,virtualScrollItemSizeComputed:A}),O=Xi(),R=y.computed(()=>{const fe=l.mapOptions===!0&&l.multiple!==!0,je=l.modelValue!==void 0&&(l.modelValue!==null||fe===!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&&i!==void 0?i:[],he=je.map(ve=>Fe(ve,Z));return l.modelValue===null&&fe===!0?he.filter(ve=>ve!==null):he}return je}),z=y.computed(()=>{const fe={};return cu.forEach(je=>{const Z=l[je];Z!==void 0&&(fe[je]=Z)}),fe}),U=y.computed(()=>l.optionsDark===null?O.isDark.value:l.optionsDark),Q=y.computed(()=>Qr(R.value)),D=y.computed(()=>{let fe="q-field__input q-placeholder col";return l.hideSelected===!0||R.value.length===0?[fe,l.inputClass]:(fe+=" q-field__input--padding",l.inputClass===void 0?fe:[fe,l.inputClass])}),Y=y.computed(()=>(l.virtualScrollHorizontal===!0?"q-virtual-scroll--horizontal":"")+(l.popupContentClass?" "+l.popupContentClass:"")),F=y.computed(()=>L.value===0),B=y.computed(()=>R.value.map(fe=>ie.value(fe)).join(", ")),H=y.computed(()=>l.displayValue!==void 0?l.displayValue:B.value),K=y.computed(()=>l.optionsHtml===!0?()=>!0:fe=>fe?.html===!0),$=y.computed(()=>l.displayValueHtml===!0||l.displayValue===void 0&&(l.optionsHtml===!0||R.value.some(K.value))),G=y.computed(()=>O.focused.value===!0?l.tabindex:-1),ee=y.computed(()=>{const fe={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&&(fe["aria-activedescendant"]=`${O.targetUid.value}_${s.value}`),fe}),ce=y.computed(()=>({id:`${O.targetUid.value}_lb`,role:"listbox","aria-multiselectable":l.multiple===!0?"true":"false"})),ue=y.computed(()=>R.value.map((fe,je)=>({index:je,opt:fe,html:K.value(fe),selected:!0,removeAtIndex:Me,toggleOption:Ve,tabindex:G.value}))),J=y.computed(()=>{if(L.value===0)return[];const{from:fe,to:je}=M.value;return l.options.slice(fe,je).map((Z,he)=>{const ve=se.value(Z)===!0,ye=ke(Z)===!0,Pe=fe+he,Se={clickable:!0,active:ye,activeClass:te.value,manualFocus:!0,focused:!1,disable:ve,tabindex:-1,dense:l.optionsDense,dark:U.value,role:"option","aria-selected":ye===!0?"true":"false",id:`${O.targetUid.value}_${Pe}`,onClick:()=>{Ve(Z)}};return ve!==!0&&(s.value===Pe&&(Se.focused=!0),m.platform.is.desktop===!0&&(Se.onMousemove=()=>{c.value===!0&&Ne(Pe)})),{index:Pe,opt:Z,html:K.value(Z),label:ie.value(Z),selected:Se.active,focused:Se.focused,toggleOption:Ve,setOptionIndex:Ne,itemProps:Se}})}),le=y.computed(()=>l.dropdownIcon!==void 0?l.dropdownIcon:m.iconSet.arrow.dropdown),ae=y.computed(()=>l.optionsCover===!1&&l.outlined!==!0&&l.standout!==!0&&l.borderless!==!0&&l.rounded!==!0),te=y.computed(()=>l.optionsSelectedClass!==void 0?l.optionsSelectedClass:l.color!==void 0?`text-${l.color}`:""),oe=y.computed(()=>ii(l.optionValue,"value")),ie=y.computed(()=>ii(l.optionLabel,"label")),se=y.computed(()=>ii(l.optionDisable,"disable")),pe=y.computed(()=>R.value.map(oe.value)),xe=y.computed(()=>{const fe={onInput:me,onChange:W,onKeydown:et,onKeyup:Le,onKeypress:Ge,onFocus:De,onClick(je){d===!0&&Dt(je)}};return fe.onCompositionstart=fe.onCompositionupdate=fe.onCompositionend=W,fe});y.watch(R,fe=>{i=fe,l.useInput===!0&&l.fillInput===!0&&l.multiple!==!0&&O.innerLoading.value!==!0&&(o.value!==!0&&c.value!==!0||Q.value!==!0)&&(h!==!0&&ze(),(o.value===!0||c.value===!0)&&Oe(""))},{immediate:!0}),y.watch(()=>l.fillInput,ze),y.watch(c,Je),y.watch(L,Ze);function Re(fe){return l.emitValue===!0?oe.value(fe):fe}function Ce(fe){if(fe!==-1&&fe<R.value.length)if(l.multiple===!0){const je=l.modelValue.slice();t("remove",{index:fe,value:je.splice(fe,1)[0]}),t("update:modelValue",je)}else t("update:modelValue",null)}function Me(fe){Ce(fe),O.focus()}function Ue(fe,je){const Z=Re(fe);if(l.multiple!==!0){l.fillInput===!0&&Te(ie.value(fe),!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(fe)===!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 Ve(fe,je){if(O.editable.value!==!0||fe===void 0||se.value(fe)===!0)return;const Z=oe.value(fe);if(l.multiple!==!0){je!==!0&&(Te(l.fillInput===!0?ie.value(fe):"",!0,!0),Be()),j.value?.focus(),(R.value.length===0||rr(oe.value(R.value[0]),Z)!==!0)&&t("update:modelValue",l.emitValue===!0?Z:fe);return}if((d!==!0||e.value===!0)&&O.focus(),De(),R.value.length===0){const ye=l.emitValue===!0?Z:fe;t("add",{index:0,value:ye}),t("update:modelValue",l.multiple===!0?[ye]:ye);return}const he=l.modelValue.slice(),ve=pe.value.findIndex(ye=>rr(ye,Z));if(ve!==-1)t("remove",{index:ve,value:he.splice(ve,1)[0]});else{if(l.maxValues!==void 0&&he.length>=l.maxValues)return;const ye=l.emitValue===!0?Z:fe;t("add",{index:he.length,value:ye}),he.push(ye)}t("update:modelValue",he)}function Ne(fe){if(m.platform.is.desktop!==!0)return;const je=fe!==-1&&fe<L.value?fe:-1;s.value!==je&&(s.value=je)}function qe(fe=1,je){if(c.value===!0){let Z=s.value;do Z=ko(Z+fe,-1,L.value-1);while(Z!==-1&&Z!==s.value&&se.value(l.options[Z])===!0);s.value!==Z&&(Ne(Z),S(Z),je!==!0&&l.useInput===!0&&l.fillInput===!0&&we(Z>=0?ie.value(l.options[Z]):g,!0))}}function Fe(fe,je){const Z=he=>rr(oe.value(he),fe);return l.options.find(Z)||je.find(Z)||fe}function ke(fe){const je=oe.value(fe);return pe.value.find(Z=>rr(Z,je))!==void 0}function De(fe){l.useInput===!0&&j.value!==null&&(fe===void 0||j.value===fe.target&&fe.target.value===B.value)&&j.value.select()}function We(fe){ir(fe,27)===!0&&c.value===!0&&(Dt(fe),Be(),ze()),t("keyup",fe)}function Le(fe){const{value:je}=fe.target;if(fe.keyCode!==void 0){We(fe);return}if(fe.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=ye=>{const Pe=l.options.find(Se=>String(ye.value(Se)).toLocaleLowerCase()===Z);return Pe===void 0?!1:(R.value.indexOf(Pe)===-1?Ve(Pe):Be(),!0)},ve=ye=>{he(oe)!==!0&&ye!==!0&&he(ie)!==!0&&Oe(je,!0,()=>ve(!0))};ve()}else O.clearValue(fe)}function Ge(fe){t("keypress",fe)}function et(fe){if(t("keydown",fe),Fi(fe)===!0)return;const je=n.value.length!==0&&(l.newValueMode!==void 0||l.onNewValue!==void 0),Z=fe.shiftKey!==!0&&l.disableTabSelection!==!0&&l.multiple!==!0&&(s.value!==-1||je===!0);if(fe.keyCode===27){Bt(fe);return}if(fe.keyCode===9&&Z===!1){be();return}if(fe.target===void 0||fe.target.id!==O.targetUid.value||O.editable.value!==!0)return;if(fe.keyCode===40&&O.innerLoading.value!==!0&&c.value===!1){St(fe),_e();return}if(fe.keyCode===8&&(l.useChips===!0||l.clearable===!0)&&l.hideSelected!==!0&&n.value.length===0){l.multiple===!0&&Array.isArray(l.modelValue)===!0?Ce(l.modelValue.length-1):l.multiple!==!0&&l.modelValue!==null&&t("update:modelValue",null);return}(fe.keyCode===35||fe.keyCode===36)&&(typeof n.value!="string"||n.value.length===0)&&(St(fe),s.value=-1,qe(fe.keyCode===36?1:-1,l.multiple)),(fe.keyCode===33||fe.keyCode===34)&&_.value!==void 0&&(St(fe),s.value=Math.max(-1,Math.min(L.value,s.value+(fe.keyCode===33?-1:1)*_.value.view)),qe(fe.keyCode===33?1:-1,l.multiple)),(fe.keyCode===38||fe.keyCode===40)&&(St(fe),qe(fe.keyCode===38?-1:1,l.multiple));const he=L.value;if((k===void 0||C<Date.now())&&(k=""),he>0&&l.useInput!==!0&&fe.key!==void 0&&fe.key.length===1&&fe.altKey===!1&&fe.ctrlKey===!1&&fe.metaKey===!1&&(fe.keyCode!==32||k.length!==0)){c.value!==!0&&_e(fe);const ve=fe.key.toLocaleLowerCase(),ye=k.length===1&&k[0]===ve;C=Date.now()+1500,ye===!1&&(St(fe),k+=ve);const Pe=new RegExp("^"+k.split("").map(Ie=>uu.indexOf(Ie)!==-1?"\\"+Ie:Ie).join(".*"),"i");let Se=s.value;if(ye===!0||Se<0||Pe.test(ie.value(l.options[Se]))!==!0)do Se=ko(Se+1,-1,he-1);while(Se!==s.value&&(se.value(l.options[Se])===!0||Pe.test(ie.value(l.options[Se]))!==!0));s.value!==Se&&y.nextTick(()=>{Ne(Se),S(Se),Se>=0&&l.useInput===!0&&l.fillInput===!0&&we(ie.value(l.options[Se]),!0)});return}if(!(fe.keyCode!==13&&(fe.keyCode!==32||l.useInput===!0||k!=="")&&(fe.keyCode!==9||Z===!1))){if(fe.keyCode!==9&&St(fe),s.value!==-1&&s.value<he){Ve(l.options[s.value]);return}if(je===!0){const ve=(ye,Pe)=>{if(Pe){if(Ho(Pe)!==!0)return}else Pe=l.newValueMode;if(Te("",l.multiple!==!0,!0),ye==null)return;(Pe==="toggle"?Ve:Ue)(ye,Pe==="add-unique"),l.multiple!==!0&&(j.value?.focus(),Be())};if(l.onNewValue!==void 0?t("newValue",n.value,ve):ve(n.value),l.multiple!==!0)return}c.value===!0?be():O.innerLoading.value!==!0&&_e()}}function He(){return d===!0?N.value:q.value!==null&&q.value.contentEl!==null?q.value.contentEl:void 0}function nt(){return He()}function tt(){return l.hideSelected===!0?[]:I["selected-item"]!==void 0?ue.value.map(fe=>I["selected-item"](fe)).slice():I.selected!==void 0?[].concat(I.selected()):l.useChips===!0?ue.value.map((fe,je)=>y.h(qa,{key:"option-"+je,removable:O.editable.value===!0&&se.value(fe.opt)!==!0,dense:!0,textColor:l.color,tabindex:G.value,onRemove(){fe.removeAtIndex(je)}},()=>y.h("span",{class:"ellipsis",[fe.html===!0?"innerHTML":"textContent"]:ie.value(fe.opt)}))):[y.h("span",{class:"ellipsis",[$.value===!0?"innerHTML":"textContent"]:H.value})]}function Ye(){if(F.value===!0)return I["no-option"]!==void 0?I["no-option"]({inputValue:n.value}):void 0;const fe=I.option!==void 0?I.option:Z=>y.h(Cr,{key:Z.index,...Z.itemProps},()=>y.h(Ar,()=>y.h(wi,()=>y.h("span",{[Z.html===!0?"innerHTML":"textContent"]:Z.label}))));let je=x("div",J.value.map(fe));return I["before-options"]!==void 0&&(je=I["before-options"]().concat(je)),It(I["after-options"],je)}function at(fe,je){const Z=je===!0?{...ee.value,...O.splitAttrs.attributes.value}:void 0,he={ref:je===!0?j:void 0,key:"i_t",class:D.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":fe===!0||l.autofocus===!0||void 0,disabled:l.disable===!0,readonly:l.readonly===!0,...xe.value};return fe!==!0&&d===!0&&(Array.isArray(he.class)===!0?he.class=[...he.class,"no-pointer-events"]:he.class+=" no-pointer-events"),y.h("input",he)}function me(fe){u!==null&&(clearTimeout(u),u=null),a!==null&&(clearTimeout(a),a=null),!(fe&&fe.target&&fe.target.qComposing===!0)&&(we(fe.target.value||""),h=!0,g=n.value,O.focused.value!==!0&&(d!==!0||e.value===!0)&&O.focus(),l.onFilter!==void 0&&(u=setTimeout(()=>{u=null,Oe(n.value)},l.inputDebounce)))}function we(fe,je){n.value!==fe&&(n.value=fe,je===!0||l.inputDebounce===0||l.inputDebounce==="0"?t("inputValue",fe):a=setTimeout(()=>{a=null,t("inputValue",fe)},l.inputDebounce))}function Te(fe,je,Z){h=Z!==!0,l.useInput===!0&&(we(fe,!0),(je===!0||Z!==!0)&&(g=fe),je!==!0&&Oe(fe))}function Oe(fe,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),fe!==""&&l.multiple!==!0&&R.value.length!==0&&h!==!0&&fe===ie.value(R.value[0])&&(fe="");const he=setTimeout(()=>{c.value===!0&&(c.value=!1)},10);f!==null&&clearTimeout(f),f=he,t("filter",fe,(ve,ye)=>{(je===!0||O.focused.value===!0)&&f===he&&(clearTimeout(f),typeof ve=="function"&&ve(),r.value=!1,y.nextTick(()=>{O.innerLoading.value=!1,O.editable.value===!0&&(je===!0?c.value===!0&&Be():c.value===!0?Je(!0):c.value=!0),typeof ye=="function"&&y.nextTick(()=>{ye(b)}),typeof Z=="function"&&y.nextTick(()=>{Z(b)})}))},()=>{O.focused.value===!0&&f===he&&(clearTimeout(f),O.innerLoading.value=!1,r.value=!1),c.value===!0&&(c.value=!1)})}function Ae(){return y.h(Jr,{ref:q,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:ae.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(fe){ft(fe),be()}function Ke(){E()}function re(fe){Dt(fe),j.value?.focus(),e.value=!0,window.scrollTo(window.pageXOffset||window.scrollX||document.body.scrollLeft||0,0)}function X(fe){Dt(fe),y.nextTick(()=>{e.value=!1})}function ne(){const fe=[y.h(Xl,{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},{...I,rawControl:()=>O.getControl(!0),before:void 0,after:void 0})];return c.value===!0&&fe.push(y.h("div",{ref:N,class:Y.value+" scroll",style:l.popupContentStyle,...ce.value,onClick:Bt,onScrollPassive:w},Ye())),y.h(zn,{ref:P,modelValue:o.value,position:l.useInput===!0?"top":void 0,transitionShow:p,transitionHide:l.transitionHide,transitionDuration:l.transitionDuration,noRouteDismiss:l.popupNoRouteDismiss,onBeforeShow:yt,onBeforeHide:de,onHide:ge,onShow:Ee},()=>y.h("div",{class:"q-select__dialog"+(U.value===!0?" q-select__dialog--dark q-dark":"")+(e.value===!0?" q-select__dialog--focused":"")},fe))}function de(fe){ft(fe),P.value!==null&&P.value.__updateRefocusTarget(O.rootRef.value.querySelector(".q-field__native > [tabindex]:last-child")),O.focused.value=!1}function ge(fe){Be(),O.focused.value===!1&&t("blur",fe),ze()}function Ee(){const fe=document.activeElement;(fe===null||fe.id!==O.targetUid.value)&&j.value!==null&&j.value!==fe&&j.value.focus(),E()}function be(){o.value!==!0&&(s.value=-1,c.value===!0&&(c.value=!1),O.focused.value===!1&&(f!==null&&(clearTimeout(f),f=null),O.innerLoading.value===!0&&(t("filterAbort"),O.innerLoading.value=!1,r.value=!1)))}function _e(fe){O.editable.value===!0&&(d===!0?(O.onControlFocusin(fe),o.value=!0,y.nextTick(()=>{O.focus()})):O.focus(),l.onFilter!==void 0?Oe(n.value):(F.value!==!0||I["no-option"]!==void 0)&&(c.value=!0))}function Be(){o.value=!1,be()}function ze(){l.useInput===!0&&Te(l.multiple!==!0&&l.fillInput===!0&&R.value.length!==0&&ie.value(R.value[0])||"",!0,!0)}function Je(fe){let je=-1;if(fe===!0){if(R.value.length!==0){const Z=oe.value(R.value[0]);je=l.options.findIndex(he=>rr(oe.value(he),Z))}v(je)}Ne(je)}function Ze(fe,je){c.value===!0&&O.innerLoading.value===!1&&(v(-1,!0),y.nextTick(()=>{c.value===!0&&O.innerLoading.value===!1&&(fe>je?v():Je(!0))}))}function rt(){o.value===!1&&q.value!==null&&q.value.updatePosition()}function yt(fe){fe!==void 0&&Dt(fe),t("popupShow",fe),O.hasPopupOpen=!0,O.onControlFocusin(fe)}function ft(fe){fe!==void 0&&Dt(fe),t("popupHide",fe),O.hasPopupOpen=!1,O.onControlFocusout(fe)}function kt(){d=m.platform.is.mobile!==!0&&l.behavior!=="dialog"?!1:l.behavior!=="menu"&&(l.useInput===!0?I["no-option"]!==void 0||l.onFilter!==void 0||F.value===!1:!0),p=m.platform.is.ios===!0&&d===!0&&l.useInput===!0?"fade":l.transitionShow}return y.onBeforeUpdate(kt),y.onUpdated(rt),kt(),y.onBeforeUnmount(()=>{u!==null&&clearTimeout(u),a!==null&&clearTimeout(a)}),Object.assign(b,{showPopup:_e,hidePopup:Be,removeAtIndex:Ce,add:Ue,toggleOption:Ve,getOptionIndex:()=>s.value,setOptionIndex:Ne,moveOptionSelection:qe,filter:Oe,updateMenuPosition:rt,updateInputValue:Te,isOptionSelected:ke,getEmittingOptionValue:Re,isOptionDisabled:(...fe)=>se.value.apply(null,fe)===!0,getOptionValue:(...fe)=>oe.value.apply(null,fe),getOptionLabel:(...fe)=>ie.value.apply(null,fe)}),Object.assign(O,{innerValue:R,fieldClass:y.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:j,hasValue:Q,showPopup:_e,floatingLabel:y.computed(()=>l.hideSelected!==!0&&Q.value===!0||typeof n.value=="number"||n.value.length!==0||Qr(l.displayValue)),getControlChild:()=>{if(O.editable.value!==!1&&(o.value===!0||F.value!==!0||I["no-option"]!==void 0))return d===!0?ne():Ae();O.hasPopupOpen===!0&&(O.hasPopupOpen=!1)},controlEvents:{onFocusin(fe){O.onControlFocusin(fe)},onFocusout(fe){O.onControlFocusout(fe,()=>{ze(),be()})},onClick(fe){if(Bt(fe),d!==!0&&c.value===!0){be(),j.value?.focus();return}_e(fe)}},getControl:fe=>{const je=tt(),Z=fe===!0||o.value!==!0||d!==!0;if(l.useInput===!0)je.push(at(fe,Z));else if(O.editable.value===!0){const ve=Z===!0?ee.value:void 0;je.push(y.h("input",{ref:Z===!0?j: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":fe===!0||l.autofocus===!0||void 0,...ve,onKeydown:et,onKeyup:We,onKeypress:Ge})),Z===!0&&typeof l.autocomplete=="string"&&l.autocomplete.length!==0&&je.push(y.h("input",{class:"q-select__autocomplete-input",autocomplete:l.autocomplete,tabindex:-1,onKeyup:Le}))}if(V.value!==void 0&&l.disable!==!0&&pe.value.length!==0){const ve=pe.value.map(ye=>y.h("option",{value:ye,selected:!0}));je.push(y.h("select",{class:"hidden",name:V.value,multiple:l.multiple},ve))}const he=l.useInput===!0||Z!==!0?void 0:O.splitAttrs.attributes.value;return y.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?[y.h(bt,{class:"q-select__dropdown-icon"+(c.value===!0?" rotate-180":""),name:le.value})]:null}),Gi(O)}}),fu={class:"q-pa-none"},du=y.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:I}){const t=l,b=I,m=y.ref(!1),c=y.ref(t.modelValue||[]),o=y.computed(()=>({height:t.scrollAreaHeight,width:t.scrollAreaWidth})),s=y.computed(()=>t.dataCy||"checkbox-filter");return y.watch(c,n=>{b("update:modelValue",n)}),y.watch(()=>t.modelValue,n=>{n&&(c.value=n)},{immediate:!0}),(n,e)=>(y.openBlock(),y.createElementBlock("div",fu,[y.createVNode(Un,y.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:y.withCtx(()=>[y.createVNode(bt,{name:"arrow_drop_down",class:y.normalizeClass(["cursor-pointer smooth-rotate",{"rotate-180":m.value}])},null,8,["class"])]),default:y.withCtx(()=>[y.createVNode(Jr,{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:y.withCtx(()=>[y.createVNode(Xr,{class:"q-pa-sm"},{default:y.withCtx(()=>[y.createVNode(Sl,{style:y.normalizeStyle(o.value)},{default:y.withCtx(()=>[(y.openBlock(!0),y.createElementBlock(y.Fragment,null,y.renderList(t.options,r=>(y.openBlock(),y.createBlock(Er,{key:r.value,modelValue:c.value,"onUpdate:modelValue":e[0]||(e[0]=u=>c.value=u),val:r,label:r.label,disable:r.disabled,color:"primary",class:"q-mb-sm q-ml-sm q-mr-sm","data-cy":`${s.value}-option-${r.label}`},null,8,["modelValue","val","label","disable","data-cy"]))),128))]),_:1},8,["style"])]),_:1})]),_:1},8,["modelValue"])]),_:1},16,["label","data-cy"])]))}}),hu=Xt(du,[["__scopeId","data-v-0e12eb7b"]]),pu=y.defineComponent({__name:"SelectSearch",props:{options:{default:()=>[]},fetchOptions:{},label:{default:"Selectionner un option"},modelValue:{default:null}},emits:["update:modelValue"],setup(l,{emit:I}){const t=l,b=I,m=y.ref(),c=y.ref(t.modelValue??null),o=y.ref(""),s=y.ref(t.options??[]),n=y.ref(!1),e=y.ref(!0);y.watch(()=>t.options,f=>{s.value=f??[],r()},{immediate:!0}),y.watch(()=>t.modelValue,f=>{c.value=f,r(),n.value=!1});function r(){const f=s.value.find(g=>g.value===c.value);o.value=f?.label??""}function u(f){c.value=f,b("update:modelValue",f),r(),n.value=!1}function a(f){o.value=f,f===""&&(n.value=!0)}function i(){if(e.value){e.value=!1;return}c.value!==null&&!n.value?(o.value="",n.value=!0,m.value?.showPopup()):n.value&&(o.value="")}function d(){e.value=!0;const f=o.value.trim();if(f==="")n.value&&(c.value=null,b("update:modelValue",null));else{const g=s.value.find(p=>p.label.toLowerCase()===f.toLowerCase());g?(c.value=g.value,b("update:modelValue",g.value),o.value=g.label):r()}n.value=!1}function h(f,g,p){if(t.fetchOptions)t.fetchOptions(f).then(k=>{s.value=k,g(()=>{})}).catch(p).finally(()=>{});else{const k=t.options??[];s.value=k.filter(C=>C.label.toLowerCase().includes(f.toLowerCase())),g(()=>{})}}return(f,g)=>(y.openBlock(),y.createBlock(Un,y.mergeProps({ref_key:"selectRef",ref:m,"model-value":c.value,"input-value":o.value,"use-input":"","fill-input":"","hide-selected":"","input-debounce":"300",label:f.label,options:s.value,dense:"",outlined:"",class:"full-width cursor-pointer"},f.$attrs,{"onUpdate:modelValue":u,"onUpdate:inputValue":a,onFocus:i,onBlur:d,onFilter:h}),null,16,["model-value","input-value","label","options"]))}}),mu=y.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:I}){const t=l,b=I,m=y.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 o(){t.modelValue!==null&&b("update:modelValue",null)}return(s,n)=>(y.openBlock(),y.createBlock(Un,y.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:o}),null,16,["model-value","options","label"]))}}),Ka=$e({name:"QAvatar",props:{...Or,fontSize:String,color:String,textColor:String,icon:String,square:Boolean,rounded:Boolean},setup(l,{slots:I}){const t=Fr(l),b=y.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=y.computed(()=>l.fontSize?{fontSize:l.fontSize}:null);return()=>{const c=l.icon!==void 0?[y.h(bt,{name:l.icon})]:void 0;return y.h("div",{class:b.value,style:t.value},[y.h("div",{class:"q-avatar__content row flex-center overflow-hidden",style:m.value},sa(I.default,c))])}}}),gu=$e({name:"QSpace",setup(){const l=y.h("div",{class:"q-space"});return()=>l}}),bu=["ul","ol"],Ji=$e({name:"QList",props:{...Ot,bordered:Boolean,dense:Boolean,separator:Boolean,padding:Boolean,tag:{type:String,default:"div"}},setup(l,{slots:I}){const t=y.getCurrentInstance(),b=Ft(l,t.proxy.$q),m=y.computed(()=>bu.includes(l.tag)?null:"list"),c=y.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()=>y.h(l.tag,{class:c.value,role:m.value},gt(I.default))}}),Xa=$e({name:"QToolbar",props:{inset:Boolean},setup(l,{slots:I}){const t=y.computed(()=>"q-toolbar row no-wrap items-center"+(l.inset===!0?" q-toolbar--inset":""));return()=>y.h("div",{class:t.value,role:"toolbar"},gt(I.default))}}),vu=$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:I,emit:t}){const{proxy:{$q:b}}=y.getCurrentInstance(),m=y.inject(Zr,Rt);if(m===Rt)return console.error("QHeader needs to be child of QLayout"),Rt;const c=y.ref(parseInt(l.heightHint,10)),o=y.ref(!0),s=y.computed(()=>l.reveal===!0||m.view.value.indexOf("H")!==-1||b.platform.is.ios&&m.isContainer.value===!0),n=y.computed(()=>{if(l.modelValue!==!0)return 0;if(s.value===!0)return o.value===!0?c.value:0;const p=c.value-m.scroll.value.position;return p>0?p:0}),e=y.computed(()=>l.modelValue!==!0||s.value===!0&&o.value!==!0),r=y.computed(()=>l.modelValue===!0&&e.value===!0&&l.reveal===!0),u=y.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=y.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 i(p,k){m.update("header",p,k)}function d(p,k){p.value!==k&&(p.value=k)}function h({height:p}){d(c,p),i("size",p)}function f(p){r.value===!0&&d(o,!0),t("focusin",p)}y.watch(()=>l.modelValue,p=>{i("space",p),d(o,!0),m.animate()}),y.watch(n,p=>{i("offset",p)}),y.watch(()=>l.reveal,p=>{p===!1&&d(o,l.modelValue)}),y.watch(o,p=>{m.animate(),t("reveal",p)}),y.watch(m.scroll,p=>{l.reveal===!0&&d(o,p.direction==="up"||p.position<=l.revealOffset||p.position-p.inflectionPoint<100)});const g={};return m.instances.header=g,l.modelValue===!0&&i("size",c.value),i("space",l.modelValue),i("offset",n.value),y.onBeforeUnmount(()=>{m.instances.header===g&&(m.instances.header=void 0,i("size",0),i("offset",0),i("space",!1))}),()=>{const p=Mi(I.default,[]);return l.elevated===!0&&p.push(y.h("div",{class:"q-layout__shadow absolute-full overflow-hidden no-pointer-events"})),p.push(y.h(Rr,{debounce:0,onResize:h})),y.h("header",{class:u.value,style:a.value,onFocusin:f},p)}}});function Yo(l){if(l===!1)return 0;if(l===!0||l===void 0)return 1;const I=parseInt(l,10);return isNaN(I)?0:I}const Ga=Ei({name:"close-popup",beforeMount(l,{value:I}){const t={depth:Yo(I),handler(b){t.depth!==0&&setTimeout(()=>{const m=Tl(l);m!==void 0&&Rl(m,b,t.depth)})},handlerKey(b){ir(b,13)===!0&&t.handler(b)}};l.__qclosepopup=t,l.addEventListener("click",t.handler),l.addEventListener("keyup",t.handlerKey)},updated(l,{value:I,oldValue:t}){I!==t&&(l.__qclosepopup.depth=Yo(I))},beforeUnmount(l){const I=l.__qclosepopup;l.removeEventListener("click",I.handler),l.removeEventListener("keyup",I.handlerKey),delete l.__qclosepopup}}),yu=["src","alt"],wu={key:0,class:"project-environment-container row items-center q-mr-md"},xu=y.defineComponent({__name:"SelfeeHeader",props:{logoSrc:{},logoAlt:{},logoTo:{},showProjectSwitch:{type:Boolean},currentProjectLabel:{},availableProjects:{},currentPath:{},environment:{}},emits:["project-change"],setup(l,{emit:I}){const t=l,b=t.logoAlt??"Logo",m=t.logoTo??"/",c=y.computed(()=>({width:"260px",height:"auto",borderRadius:"0"})),o=y.computed(()=>t.environment?t.environment.toUpperCase()!=="PROD":!1),s=y.computed(()=>`environment-badge--${t.environment?.toUpperCase()?.toLowerCase()}`),n=e=>t.currentPath?.startsWith(e);return(e,r)=>{const u=y.resolveComponent("router-link");return y.openBlock(),y.createBlock(vu,y.mergeProps({elevated:""},e.$attrs),{default:y.withCtx(()=>[y.createVNode(Xa,null,{default:y.withCtx(()=>[y.createVNode(u,{to:y.unref(m),class:"q-mr-lg"},{default:y.withCtx(()=>[y.createVNode(Ka,{class:"logo",style:y.normalizeStyle(c.value),"data-testid":"header-logo"},{default:y.withCtx(()=>[y.createElementVNode("img",{src:e.logoSrc,alt:y.unref(b)},null,8,yu)]),_:1},8,["style"])]),_:1},8,["to"]),y.createVNode(gu),e.showProjectSwitch||o.value?(y.openBlock(),y.createElementBlock("div",wu,[o.value?(y.openBlock(),y.createElementBlock("div",{key:0,class:y.normalizeClass(["environment-badge",s.value]),"data-testid":"environment-badge"},y.toDisplayString(e.environment),3)):y.createCommentVNode("",!0),e.showProjectSwitch?(y.openBlock(),y.createBlock(ct,{key:1,dense:"",unelevated:"",color:"primary",label:e.currentProjectLabel,"data-testid":"project-switch-btn",class:"project-switch-btn q-mr-md bg-info"},{default:y.withCtx(()=>[y.createVNode(Jr,{anchor:"bottom right",self:"top right"},{default:y.withCtx(()=>[y.createVNode(Ji,{dense:"",class:"project-menu"},{default:y.withCtx(()=>[(y.openBlock(!0),y.createElementBlock(y.Fragment,null,y.renderList(e.availableProjects,a=>y.withDirectives((y.openBlock(),y.createBlock(Cr,{key:a.path,clickable:"",disable:n(a.path),onClick:i=>e.$emit("project-change",a.path)},{default:y.withCtx(()=>[y.createVNode(Ar,{class:"q-mr-lg"},{default:y.withCtx(()=>[y.createVNode(wi,null,{default:y.withCtx(()=>[y.createTextVNode(y.toDisplayString(a.label),1)]),_:2},1024),n(a.path)?(y.openBlock(),y.createBlock(wi,{key:0,caption:""},{default:y.withCtx(()=>r[0]||(r[0]=[y.createTextVNode(" Actuel ")])),_:1,__:[0]})):y.createCommentVNode("",!0)]),_:2},1024)]),_:2},1032,["disable","onClick"])),[[Ga]])),128))]),_:1})]),_:1})]),_:1},8,["label"])):y.createCommentVNode("",!0)])):y.createCommentVNode("",!0),y.renderSlot(e.$slots,"user-avatar",{},void 0,!0)]),_:3})]),_:3},16)}}}),Su=Xt(xu,[["__scopeId","data-v-a4df46a4"]]),ku=$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:I,emit:t}){const{proxy:{$q:b}}=y.getCurrentInstance(),m=y.inject(Zr,Rt);if(m===Rt)return console.error("QFooter needs to be child of QLayout"),Rt;const c=y.ref(parseInt(l.heightHint,10)),o=y.ref(!0),s=y.ref(or.value===!0||m.isContainer.value===!0?0:window.innerHeight),n=y.computed(()=>l.reveal===!0||m.view.value.indexOf("F")!==-1||b.platform.is.ios&&m.isContainer.value===!0),e=y.computed(()=>m.isContainer.value===!0?m.containerHeight.value:s.value),r=y.computed(()=>{if(l.modelValue!==!0)return 0;if(n.value===!0)return o.value===!0?c.value:0;const T=m.scroll.value.position+e.value+c.value-m.height.value;return T>0?T:0}),u=y.computed(()=>l.modelValue!==!0||n.value===!0&&o.value!==!0),a=y.computed(()=>l.modelValue===!0&&u.value===!0&&l.reveal===!0),i=y.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":""):"")),d=y.computed(()=>{const T=m.rows.value.bottom,j={};return T[0]==="l"&&m.left.space===!0&&(j[b.lang.rtl===!0?"right":"left"]=`${m.left.size}px`),T[2]==="r"&&m.right.space===!0&&(j[b.lang.rtl===!0?"left":"right"]=`${m.right.size}px`),j});function h(T,j){m.update("footer",T,j)}function f(T,j){T.value!==j&&(T.value=j)}function g({height:T}){f(c,T),h("size",T)}function p(){if(l.reveal!==!0)return;const{direction:T,position:j,inflectionPoint:q}=m.scroll.value;f(o,T==="up"||j-q<100||m.height.value-e.value-j-c.value<300)}function k(T){a.value===!0&&f(o,!0),t("focusin",T)}y.watch(()=>l.modelValue,T=>{h("space",T),f(o,!0),m.animate()}),y.watch(r,T=>{h("offset",T)}),y.watch(()=>l.reveal,T=>{T===!1&&f(o,l.modelValue)}),y.watch(o,T=>{m.animate(),t("reveal",T)}),y.watch([c,m.scroll,m.height],p),y.watch(()=>b.screen.height,T=>{m.isContainer.value!==!0&&f(s,T)});const C={};return m.instances.footer=C,l.modelValue===!0&&h("size",c.value),h("space",l.modelValue),h("offset",r.value),y.onBeforeUnmount(()=>{m.instances.footer===C&&(m.instances.footer=void 0,h("size",0),h("offset",0),h("space",!1))}),()=>{const T=It(I.default,[y.h(Rr,{debounce:0,onResize:g})]);return l.elevated===!0&&T.push(y.h("div",{class:"q-layout__shadow absolute-full overflow-hidden no-pointer-events"})),y.h("footer",{class:i.value,style:d.value,onFocusin:k},T)}}}),_u={class:"row justify-between"},Cu={class:"col-3 q-py-md flex justify-center"},Au={class:"col-3 q-py-md flex justify-center"},Eu={class:"col-3 q-py-md flex justify-center"},Mu=y.defineComponent({__name:"SelfeeFooter",props:{frontVersion:{},backVersion:{},platform:{}},setup(l){return(I,t)=>(y.openBlock(),y.createBlock(ku,y.mergeProps({elevated:""},I.$attrs),{default:y.withCtx(()=>[y.createElementVNode("div",_u,[y.createElementVNode("div",Cu," Front: "+y.toDisplayString(I.frontVersion),1),y.createElementVNode("div",Au," Back: "+y.toDisplayString(I.backVersion),1),y.createElementVNode("div",Eu," Platform: "+y.toDisplayString(I.platform),1)])]),_:1},16))}}),Tu={true:"inset",item:"item-inset","item-thumbnail":"item-thumbnail-inset"},oi={xs:2,sm:4,md:8,lg:16,xl:24},Wr=$e({name:"QSeparator",props:{...Ot,spaced:[Boolean,String],inset:[Boolean,String],vertical:Boolean,color:String,size:String},setup(l){const I=y.getCurrentInstance(),t=Ft(l,I.proxy.$q),b=y.computed(()=>l.vertical===!0?"vertical":"horizontal"),m=y.computed(()=>` q-separator--${b.value}`),c=y.computed(()=>l.inset!==!1?`${m.value}-${Tu[l.inset]}`:""),o=y.computed(()=>`q-separator${m.value}${c.value}`+(l.color!==void 0?` bg-${l.color}`:"")+(t.value===!0?" q-separator--dark":"")),s=y.computed(()=>{const n={};if(l.size!==void 0&&(n[l.vertical===!0?"width":"height"]=l.size),l.spaced!==!1){const e=l.spaced===!0?`${oi.md}px`:l.spaced in oi?`${oi[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()=>y.h("hr",{class:o.value,style:s.value,"aria-orientation":b.value})}}),Ru=$e({name:"QToggle",props:{...wa,icon:String,iconColor:String},emits:xa,setup(l){function I(t,b){const m=y.computed(()=>(t.value===!0?l.checkedIcon:b.value===!0?l.indeterminateIcon:l.uncheckedIcon)||l.icon),c=y.computed(()=>t.value===!0?l.iconColor:null);return()=>[y.h("div",{class:"q-toggle__track"}),y.h("div",{class:"q-toggle__thumb absolute flex flex-center no-wrap"},m.value!==void 0?[y.h(bt,{name:m.value,color:c.value})]:void 0)]}return Sa("toggle",I)}}),Bu={class:"text-h6 text-primary","data-testid":"avatar-initial"},Iu={class:"text-weight-bold"},Ou={class:"row items-center q-gutter-sm"},Fu={class:"version-info"},ju={class:"text-caption"},Du={class:"text-caption"},Pu={class:"text-caption"},Nu=y.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:I}){const t=l,b=y.computed(()=>t.username?.charAt(0).toUpperCase()??"");return(m,c)=>(y.openBlock(),y.createElementBlock("div",null,[y.createVNode(Ka,{class:"cursor-pointer",size:"40px",color:"white","data-cy":"cy-avatar","data-testid":"cy-avatar"},{default:y.withCtx(()=>[y.createElementVNode("span",Bu,y.toDisplayString(b.value),1),y.createVNode(Jr,{"transition-show":"flip-right","transition-hide":"flip-left",class:"user-avatar-menu"},{default:y.withCtx(()=>[y.createVNode(Ji,{class:"user-menu-list"},{default:y.withCtx(()=>[y.createVNode(Cr,{class:"user-info-section"},{default:y.withCtx(()=>[y.createVNode(Ar,null,{default:y.withCtx(()=>[y.createElementVNode("div",Iu,y.toDisplayString(m.username),1)]),_:1})]),_:1}),y.createVNode(Wr),m.showFilterToggle?(y.openBlock(),y.createBlock(Cr,{key:0,class:"filter-toggle-section"},{default:y.withCtx(()=>[y.createVNode(Ar,null,{default:y.withCtx(()=>[y.createElementVNode("div",Ou,[c[1]||(c[1]=y.createElementVNode("span",{class:"text-caption"},"Filtres persistants",-1)),y.createVNode(Ru,{"model-value":m.persistFilters,"onUpdate:modelValue":c[0]||(c[0]=o=>m.$emit("toggle-filter-persistence",o)),size:"sm","data-cy":"filter-persistence-toggle"},null,8,["model-value"])])]),_:1})]),_:1})):y.createCommentVNode("",!0),m.showFilterToggle?(y.openBlock(),y.createBlock(Wr,{key:1})):y.createCommentVNode("",!0),m.showVersionInfo?(y.openBlock(),y.createBlock(Cr,{key:2,class:"version-info-section"},{default:y.withCtx(()=>[y.createVNode(Ar,null,{default:y.withCtx(()=>[y.createElementVNode("div",Fu,[c[2]||(c[2]=y.createElementVNode("div",{class:"text-caption text-grey-7"},"Informations de version",-1)),y.createElementVNode("div",ju,"Front: "+y.toDisplayString(m.frontVersion),1),y.createElementVNode("div",Du,"Back: "+y.toDisplayString(m.backVersion),1),y.createElementVNode("div",Pu,"Plateforme: "+y.toDisplayString(m.platform),1)])]),_:1})]),_:1})):y.createCommentVNode("",!0),m.showVersionInfo?(y.openBlock(),y.createBlock(Wr,{key:3})):y.createCommentVNode("",!0),y.createVNode(Cr,{clickable:"",class:"logout-section","data-cy":"cy-logout-button","data-testid":"cy-logout-button",onClick:m.onLogout},{default:y.withCtx(()=>[y.createVNode(Ar,null,{default:y.withCtx(()=>[y.createElementVNode("div",null,y.toDisplayString(m.logoutLabel),1)]),_:1})]),_:1},8,["onClick"])]),_:1})]),_:1})]),_:1})]))}}),Lu=Xt(Nu,[["__scopeId","data-v-d9b256cf"]]),Vu=$e({name:"QPageContainer",setup(l,{slots:I}){const{proxy:{$q:t}}=y.getCurrentInstance(),b=y.inject(Zr,Rt);if(b===Rt)return console.error("QPageContainer needs to be child of QLayout"),Rt;y.provide(La,!0);const m=y.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()=>y.h("div",{class:"q-page-container",style:m.value},gt(I.default))}}),qu=$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:I,emit:t}){const{proxy:{$q:b}}=y.getCurrentInstance(),m=y.ref(null),c=y.ref(b.screen.height),o=y.ref(l.container===!0?0:b.screen.width),s=y.ref({position:0,direction:"down",inflectionPoint:0}),n=y.ref(0),e=y.ref(or.value===!0?0:xn()),r=y.computed(()=>"q-layout q-layout--"+(l.container===!0?"containerized":"standard")),u=y.computed(()=>l.container===!1?{minHeight:b.screen.height+"px"}:null),a=y.computed(()=>e.value!==0?{[b.lang.rtl===!0?"left":"right"]:`${e.value}px`}:null),i=y.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 d(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:j}=C;let q=!1;c.value!==T&&(q=!0,c.value=T,l.onScrollHeight!==void 0&&t("scrollHeight",T),g()),o.value!==j&&(q=!0,o.value=j),q===!0&&l.onResize!==void 0&&t("resize",C)}function f({height:C}){n.value!==C&&(n.value=C,g())}function g(){if(l.container===!0){const C=c.value>n.value?xn():0;e.value!==C&&(e.value=C)}}let p=null;const k={instances:{},view:y.computed(()=>l.view),isContainer:y.computed(()=>l.container),rootRef:m,height:c,containerHeight:n,scrollbarWidth:e,totalWidth:y.computed(()=>o.value+e.value),rows:y.computed(()=>{const C=l.view.toLowerCase().split(" ");return{top:C[0].split(""),middle:C[1].split(""),bottom:C[2].split("")}}),header:y.reactive({size:0,offset:0,space:!1}),right:y.reactive({size:300,offset:0,space:!1}),footer:y.reactive({size:0,offset:0,space:!1}),left:y.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,j){k[C][T]=j}};if(y.provide(Zr,k),xn()>0){let C=function(){q=null,P.classList.remove("hide-scrollbar")},T=function(){if(q===null){if(P.scrollHeight>b.screen.height)return;P.classList.add("hide-scrollbar")}else clearTimeout(q);q=setTimeout(C,300)},j=function(N){q!==null&&N==="remove"&&(clearTimeout(q),C()),window[`${N}EventListener`]("resize",T)},q=null;const P=document.body;y.watch(()=>l.container!==!0?"add":"remove",j),l.container!==!0&&j("add"),y.onUnmounted(()=>{j("remove")})}return()=>{const C=It(I.default,[y.h(Ea,{onScroll:d}),y.h(Rr,{onResize:h})]),T=y.h("div",{class:r.value,style:u.value,ref:l.container===!0?void 0:m,tabindex:-1},C);return l.container===!0?y.h("div",{class:"q-layout-container overflow-hidden",ref:m},[y.h(Rr,{onResize:f}),y.h("div",{class:"absolute-full",style:a.value},[y.h("div",{class:"scroll",style:i.value},[T])])]):T}}}),Zi=y.defineComponent({name:"Layout",__name:"Layout",props:{view:{default:"HHh Lpr Fff"},layoutClass:{default:"bg-white"},pageContainerClass:{default:""}},setup(l){return(I,t)=>(y.openBlock(),y.createBlock(qu,{view:I.view,class:y.normalizeClass(I.layoutClass),style:{minHeight:"auto !important"}},{default:y.withCtx(()=>[y.renderSlot(I.$slots,"header"),y.createVNode(Vu,{class:y.normalizeClass(I.pageContainerClass),style:{paddingBottom:"0 !important"}},{default:y.withCtx(()=>[y.renderSlot(I.$slots,"default")]),_:3},8,["class"]),y.renderSlot(I.$slots,"footer")]),_:3},8,["view","class"]))}});function zu(){let l=Object.create(null);return{getCache:(I,t)=>l[I]===void 0?l[I]=typeof t=="function"?t():t:l[I],setCache(I,t){l[I]=t},hasCache(I){return Object.hasOwnProperty.call(l,I)},clearCache(I){I!==void 0?delete l[I]:l=Object.create(null)}}}const nr=[-61,9,38,199,426,686,756,818,1111,1181,1210,1635,2060,2097,2192,2262,2324,2394,2456,3178];function Uu(l,I,t){return Object.prototype.toString.call(l)==="[object Date]"&&(t=l.getDate(),I=l.getMonth()+1,l=l.getFullYear()),Qu($i(l,I,t))}function Qo(l,I,t){return Za(Yu(l,I,t))}function Wu(l){return Hu(l)===0}function Sn(l,I){return I<=6?31:I<=11||Wu(l)?30:29}function Hu(l){const I=nr.length;let t=nr[0],b,m,c,o,s;if(l<t||l>=nr[I-1])throw new Error("Invalid Jalaali year "+l);for(s=1;s<I&&(b=nr[s],m=b-t,!(l<b));s+=1)t=b;return o=l-t,m-o<6&&(o=o-m+wt(m+4,33)*33),c=Pt(Pt(o+1,33)-1,4),c===-1&&(c=4),c}function Ja(l,I){const t=nr.length,b=l+621;let m=-14,c=nr[0],o,s,n,e,r;if(l<c||l>=nr[t-1])throw new Error("Invalid Jalaali year "+l);for(r=1;r<t&&(o=nr[r],s=o-c,!(l<o));r+=1)m=m+wt(s,33)*8+wt(Pt(s,33),4),c=o;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 I||(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 Yu(l,I,t){const b=Ja(l,!0);return $i(b.gy,3,b.march)+(I-1)*31-wt(I,7)*(I-7)+t-1}function Qu(l){const I=Za(l).gy;let t=I-621,b,m,c;const o=Ja(t,!1),s=$i(I,3,o.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,o.leap===1&&(c+=1);return m=7+wt(c,30),b=Pt(c,30)+1,{jy:t,jm:m,jd:b}}function $i(l,I,t){let b=wt((l+wt(I-8,6)+100100)*1461,4)+wt(153*Pt(I+9,12)+2,5)+t-34840408;return b=b-wt(wt(l+100100+wt(I-8,6),100)*3,4)+752,b}function Za(l){let I=4*l+139361631;I=I+wt(wt(4*l+183187720,146097)*3,4)*4-3908;const t=wt(Pt(I,1461),4)*5+308,b=wt(Pt(t,153),5)+1,m=Pt(wt(t,153),12)+1;return{gy:wt(I,1461)-100100+wt(8-m,6),gm:m,gd:b}}function wt(l,I){return~~(l/I)}function Pt(l,I){return l-~~(l/I)*I}const Ku=["gregorian","persian"],Ko={mask:{type:String},locale:Object,calendar:{type:String,validator:l=>Ku.includes(l),default:"gregorian"},landscape:Boolean,color:String,textColor:String,square:Boolean,flat:Boolean,bordered:Boolean,readonly:Boolean,disable:Boolean},Xu=["update:modelValue"];function $t(l){return l.year+"/"+vt(l.month)+"/"+vt(l.day)}function Gu(l,I){const t=y.computed(()=>l.disable!==!0&&l.readonly!==!0),b=y.computed(()=>t.value===!0?0:-1),m=y.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?{...I.lang.date,...l.locale}:I.lang.date}function o(s){const n=new Date,e=s===!0?null:0;if(l.calendar==="persian"){const r=Uu(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:o}}const ki={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,I,t)=>l+"-"+I+" 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 Xo(){const l=Array.isArray(navigator.languages)===!0&&navigator.languages.length!==0?navigator.languages[0]:navigator.language;if(typeof l=="string")return l.split(/[-_]/).map((I,t)=>t===0?I.toLowerCase():t>1||I.length<4?I.toUpperCase():I[0].toUpperCase()+I.slice(1).toLowerCase()).join("-")}const tr=_s({__qLang:{}},{getLocale:Xo,set(l=ki,I){const t={...l,rtl:l.rtl===!0,getLocale:Xo};{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:I,ssrContext:t}){l.lang=tr.__qLang,tr.__langConfig=l.config.lang,this.__installed===!0?I!==void 0&&this.set(I):(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(I||ki))}}),$a=864e5,Ju=36e5,_i=6e4,es="YYYY-MM-DDTHH:mm:ss.SSSZ",Zu=/\[((?:[^\]\\]|\\]|\\)*)\]|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,$u=/(\[[^\]]*\])|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,ai={};function ec(l,I){const t="("+I.days.join("|")+")",b=l+t;if(ai[b]!==void 0)return ai[b];const m="("+I.daysShort.join("|")+")",c="("+I.months.join("|")+")",o="("+I.monthsShort.join("|")+")",s={};let n=0;const e=l.replace($u,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,o;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 ai[b]=r,r}function ts(l,I){return l!==void 0?l:I!==void 0?I.date:ki.date}function Go(l,I=""){const t=l>0?"-":"+",b=Math.abs(l),m=Math.floor(b/60),c=b%60;return t+vt(m)+I+vt(c)}function tc(l,I,t){let b=l.getFullYear(),m=l.getMonth();const c=l.getDate();return I.year!==void 0&&(b+=t*I.year,delete I.year),I.month!==void 0&&(m+=t*I.month,delete I.month),l.setDate(1),l.setMonth(2),l.setFullYear(b),l.setMonth(m),l.setDate(Math.min(c,ro(l))),I.date!==void 0&&(l.setDate(l.getDate()+t*I.date),delete I.date),l}function rc(l,I,t){const b=I.year!==void 0?I.year:l[`get${t}FullYear`](),m=I.month!==void 0?I.month-1:l[`get${t}Month`](),c=new Date(b,m+1,0).getDate(),o=Math.min(c,I.date!==void 0?I.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`](o),delete I.year,delete I.month,delete I.date,l}function eo(l,I,t){const b=rs(I),m=new Date(l),c=b.year!==void 0||b.month!==void 0||b.date!==void 0?tc(m,b,t):m;for(const o in b){const s=xl(o);c[`set${s}`](c[`get${s}`]()+t*b[o])}return c}function rs(l){const I={...l};return l.years!==void 0&&(I.year=l.years,delete I.years),l.months!==void 0&&(I.month=l.months,delete I.months),l.days!==void 0&&(I.date=l.days,delete I.days),l.day!==void 0&&(I.date=l.day,delete I.day),l.hour!==void 0&&(I.hours=l.hour,delete I.hour),l.minute!==void 0&&(I.minutes=l.minute,delete I.minute),l.second!==void 0&&(I.seconds=l.second,delete I.second),l.millisecond!==void 0&&(I.milliseconds=l.millisecond,delete I.millisecond),I}function ns(l,I,t){const b=rs(I),m=t===!0?"UTC":"",c=new Date(l),o=b.year!==void 0||b.month!==void 0||b.date!==void 0?rc(c,b,m):c;for(const s in b){const n=s.charAt(0).toUpperCase()+s.slice(1);o[`set${m}${n}`](b[s])}return o}function nc(l,I,t){const b=is(l,I,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:eo(m,{minutes:b.timezoneOffset-c},1)}function is(l,I,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;I===void 0&&(I=es);const o=ts(t,tr.props),s=o.months,n=o.monthsShort,{regex:e,map:r}=ec(I,o),u=l.match(e);if(u===null)return c;let a="";if(r.X!==void 0||r.x!==void 0){const i=parseInt(u[r.X!==void 0?r.X:r.x],10);if(isNaN(i)===!0||i<0)return c;const d=new Date(i*(r.X!==void 0?1e3:1));c.year=d.getFullYear(),c.month=d.getMonth()+1,c.day=d.getDate(),c.hour=d.getHours(),c.minute=d.getMinutes(),c.second=d.getSeconds(),c.millisecond=d.getMilliseconds()}else{if(r.YYYY!==void 0)c.year=parseInt(u[r.YYYY],10);else if(r.YY!==void 0){const i=parseInt(u[r.YY],10);c.year=i<0?i:2e3+i}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 i=b!=="persian"?new Date(c.year,c.month,0).getDate():Sn(c.year,c.month);if(c.day>i)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 ic(l){return typeof l=="number"?!0:isNaN(Date.parse(l))===!1}function oc(l,I){return ns(new Date,l,I)}function ac(l){const I=new Date(l).getDay();return I===0?7:I}function kn(l){const I=new Date(l.getFullYear(),l.getMonth(),l.getDate());I.setDate(I.getDate()-(I.getDay()+6)%7+3);const t=new Date(I.getFullYear(),0,4);t.setDate(t.getDate()-(t.getDay()+6)%7+3);const b=I.getTimezoneOffset()-t.getTimezoneOffset();I.setHours(I.getHours()-b);const m=(I-t)/($a*7);return 1+Math.floor(m)}function sc(l){return l.getFullYear()*1e4+l.getMonth()*100+l.getDate()}function si(l,I){const t=new Date(l);return I===!0?sc(t):t.getTime()}function lc(l,I,t,b={}){const m=si(I,b.onlyDate),c=si(t,b.onlyDate),o=si(l,b.onlyDate);return(o>m||b.inclusiveFrom===!0&&o===m)&&(o<c||b.inclusiveTo===!0&&o===c)}function uc(l,I){return eo(l,I,1)}function cc(l,I){return eo(l,I,-1)}function Wt(l,I,t){const b=new Date(l),m=`set${t===!0?"UTC":""}`;switch(I){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 fc(l,I,t){const b=new Date(l),m=`set${t===!0?"UTC":""}`;switch(I){case"year":case"years":b[`${m}Month`](11);case"month":case"months":b[`${m}Date`](ro(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 dc(l){let I=new Date(l);return Array.prototype.slice.call(arguments,1).forEach(t=>{I=Math.max(I,new Date(t))}),I}function hc(l){let I=new Date(l);return Array.prototype.slice.call(arguments,1).forEach(t=>{I=Math.min(I,new Date(t))}),I}function hn(l,I,t){return(l.getTime()-l.getTimezoneOffset()*_i-(I.getTime()-I.getTimezoneOffset()*_i))/t}function to(l,I,t="days"){const b=new Date(l),m=new Date(I);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 hn(Wt(b,"day"),Wt(m,"day"),$a);case"hours":case"hour":return hn(Wt(b,"hour"),Wt(m,"hour"),Ju);case"minutes":case"minute":return hn(Wt(b,"minute"),Wt(m,"minute"),_i);case"seconds":case"second":return hn(Wt(b,"second"),Wt(m,"second"),1e3)}}function _n(l){return to(l,Wt(l,"year"),"days")+1}function pc(l){return On(l)===!0?"date":typeof l=="number"?"number":"string"}function mc(l,I,t){const b=new Date(l);if(I){const m=new Date(I);if(b<m)return m}if(t){const m=new Date(t);if(b>m)return m}return b}function gc(l,I,t){const b=new Date(l),m=new Date(I);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 ro(l){return new Date(l.getFullYear(),l.getMonth()+1,0).getDate()}function Sr(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 Jo={YY(l,I,t){const b=this.YYYY(l,I,t)%100;return b>=0?vt(b):"-"+vt(Math.abs(b))},YYYY(l,I,t){return t??l.getFullYear()},M(l){return l.getMonth()+1},Mo(l){return Sr(l.getMonth()+1)},MM(l){return vt(l.getMonth()+1)},MMM(l,I){return I.monthsShort[l.getMonth()]},MMMM(l,I){return I.months[l.getMonth()]},Q(l){return Math.ceil((l.getMonth()+1)/3)},Qo(l){return Sr(this.Q(l))},D(l){return l.getDate()},Do(l){return Sr(l.getDate())},DD(l){return vt(l.getDate())},DDD(l){return _n(l)},DDDo(l){return Sr(_n(l))},DDDD(l){return vt(_n(l),3)},d(l){return l.getDay()},do(l){return Sr(l.getDay())},dd(l,I){return I.days[l.getDay()].slice(0,2)},ddd(l,I){return I.daysShort[l.getDay()]},dddd(l,I){return I.days[l.getDay()]},E(l){return l.getDay()||7},w(l){return kn(l)},wo(l){return Sr(kn(l))},ww(l){return vt(kn(l))},H(l){return l.getHours()},HH(l){return vt(l.getHours())},h(l){const I=l.getHours();return I===0?12:I>12?I%12:I},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,I,t,b){const m=b??l.getTimezoneOffset();return Go(m,":")},ZZ(l,I,t,b){const m=b??l.getTimezoneOffset();return Go(m)},X(l){return Math.floor(l.getTime()/1e3)},x(l){return l.getTime()}};function os(l,I,t,b,m){if(l!==0&&!l||l===1/0||l===-1/0)return;const c=new Date(l);if(isNaN(c))return;I===void 0&&(I=es);const o=ts(t,tr.props);return I.replace(Zu,(s,n)=>s in Jo?Jo[s](c,o,b,m):n===void 0?s:n.split("\\]").join("]"))}function bc(l){return On(l)===!0?new Date(l.getTime()):l}const as={isValid:ic,extractDate:nc,buildDate:oc,getDayOfWeek:ac,getWeekOfYear:kn,isBetweenDates:lc,addToDate:uc,subtractFromDate:cc,adjustDate:ns,startOfDate:Wt,endOfDate:fc,getMaxDate:dc,getMinDate:hc,getDateDiff:to,getDayOfYear:_n,inferDateFormat:pc,getDateBetween:mc,isSameDate:gc,daysInMonth:ro,formatDate:os,clone:bc},Yt=20,vc=["Calendar","Years","Months"],Zo=l=>vc.includes(l),li=l=>/^-?[\d]+\/[0-1]\d$/.test(l),kr=" — ";function er(l){return l.year+"/"+vt(l.month)}const ss=$e({name:"QDate",props:{...Ko,...Nn,...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:{...Ko.mask,default:"YYYY/MM/DD"},defaultYearMonth:{type:String,validator:li},yearsInMonthView:Boolean,events:[Array,Function],eventColor:[String,Function],emitImmediately:Boolean,options:[Array,Function],navigationMinYearMonth:{type:String,validator:li},navigationMaxYearMonth:{type:String,validator:li},noUnset:Boolean,firstDayOfWeek:[String,Number],todayBtn:Boolean,minimal:Boolean,defaultView:{type:String,default:"Calendar",validator:Zo}},emits:[...Xu,"rangeStart","rangeEnd","navigation"],setup(l,{slots:I,emit:t}){const{proxy:b}=y.getCurrentInstance(),{$q:m}=b,c=Ft(l,m),{getCache:o}=zu(),{tabindex:s,headerClass:n,getLocale:e,getCurrentDate:r}=Gu(l,m);let u;const a=al(l),i=va(a),d=y.ref(null),h=y.ref(Ue()),f=y.ref(e()),g=y.computed(()=>Ue()),p=y.computed(()=>e()),k=y.computed(()=>r()),C=y.ref(Ne(h.value,f.value)),T=y.ref(l.defaultView),j=y.computed(()=>m.lang.rtl===!0?"right":"left"),q=y.ref(j.value),P=y.ref(j.value),N=C.value.year,V=y.ref(N-N%Yt-(N<0?Yt:0)),W=y.ref(null),L=y.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=y.computed(()=>l.color||"primary"),M=y.computed(()=>l.textColor||"white"),_=y.computed(()=>l.emitImmediately===!0&&l.multiple!==!0&&l.range!==!0),v=y.computed(()=>Array.isArray(l.modelValue)===!0?l.modelValue:l.modelValue!==null&&l.modelValue!==void 0?[l.modelValue]:[]),x=y.computed(()=>v.value.filter(re=>typeof re=="string").map(re=>Ve(re,h.value,f.value)).filter(re=>re.dateHash!==null&&re.day!==null&&re.month!==null&&re.year!==null)),w=y.computed(()=>{const re=X=>Ve(X,h.value,f.value);return v.value.filter(X=>Qa(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=y.computed(()=>l.calendar!=="persian"?re=>new Date(re.year,re.month-1,re.day):re=>{const X=Qo(re.year,re.month,re.day);return new Date(X.gy,X.gm-1,X.gd)}),E=y.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?f.value:ne,re.year,re.timezoneOffset)),O=y.computed(()=>x.value.length+w.value.reduce((re,X)=>re+1+to(S.value(X.to),S.value(X.from)),0)),R=y.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,de=S.value(ne);return f.value.daysShort[de.getDay()]+", "+f.value.monthsShort[ne.month-1]+" "+ne.day+kr+"?"}if(O.value===0)return kr;if(O.value>1)return`${O.value} ${f.value.pluralDay}`;const re=x.value[0],X=S.value(re);return isNaN(X.valueOf())===!0?kr:f.value.headerTitle!==void 0?f.value.headerTitle(X,re):f.value.daysShort[X.getDay()]+", "+f.value.monthsShort[re.month-1]+" "+re.day}),z=y.computed(()=>x.value.concat(w.value.map(X=>X.from)).sort((X,ne)=>X.year-ne.year||X.month-ne.month)[0]),U=y.computed(()=>x.value.concat(w.value.map(X=>X.to)).sort((X,ne)=>ne.year-X.year||ne.month-X.month)[0]),Q=y.computed(()=>{if(l.subtitle!==void 0&&l.subtitle!==null&&l.subtitle.length!==0)return l.subtitle;if(O.value===0)return kr;if(O.value>1){const re=z.value,X=U.value,ne=f.value.monthsShort;return ne[re.month-1]+(re.year!==X.year?" "+re.year+kr+ne[X.month-1]+" ":re.month!==X.month?kr+ne[X.month-1]:"")+" "+X.year}return x.value[0].year}),D=y.computed(()=>{const re=[m.iconSet.datetime.arrowLeft,m.iconSet.datetime.arrowRight];return m.lang.rtl===!0?re.reverse():re}),Y=y.computed(()=>l.firstDayOfWeek!==void 0?Number(l.firstDayOfWeek):f.value.firstDayOfWeek),F=y.computed(()=>{const re=f.value.daysShort,X=Y.value;return X>0?re.slice(X,7).concat(re.slice(0,X)):re}),B=y.computed(()=>{const re=C.value;return l.calendar!=="persian"?new Date(re.year,re.month,0).getDate():Sn(re.year,re.month)}),H=y.computed(()=>typeof l.eventColor=="function"?l.eventColor:()=>l.eventColor),K=y.computed(()=>{if(l.navigationMinYearMonth===void 0)return null;const re=l.navigationMinYearMonth.split("/");return{year:parseInt(re[0],10),month:parseInt(re[1],10)}}),$=y.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=y.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)),$.value!==null&&$.value.year<=C.value.year&&(re.year.next=!1,$.value.year===C.value.year&&$.value.month<=C.value.month&&(re.month.next=!1)),re}),ee=y.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=y.computed(()=>{const re={};return w.value.forEach(X=>{const ne=er(X.from),de=er(X.to);if(re[ne]===void 0&&(re[ne]=[]),re[ne].push({from:X.from.day,to:ne===de?X.to.day:void 0,range:X}),ne<de){let ge;const{year:Ee,month:be}=X.from,_e=be<12?{year:Ee,month:be+1}:{year:Ee+1,month:1};for(;(ge=er(_e))<=de;)re[ge]===void 0&&(re[ge]=[]),re[ge].push({from:void 0,to:ge===de?X.to.day:void 0,range:X}),_e.month++,_e.month>12&&(_e.year++,_e.month=1)}}),re}),ue=y.computed(()=>{if(W.value===null)return;const{init:re,initHash:X,final:ne,finalHash:de}=W.value,[ge,Ee]=X<=de?[re,ne]:[ne,re],be=er(ge),_e=er(Ee);if(be!==J.value&&_e!==J.value)return;const Be={};return be===J.value?(Be.from=ge.day,Be.includeFrom=!0):Be.from=1,_e===J.value?(Be.to=Ee.day,Be.includeTo=!0):Be.to=B.value,Be}),J=y.computed(()=>er(C.value)),le=y.computed(()=>{const re={};if(l.options===void 0){for(let ne=1;ne<=B.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<=B.value;ne++){const de=J.value+"/"+vt(ne);re[ne]=X(de)}return re}),ae=y.computed(()=>{const re={};if(l.events===void 0)for(let X=1;X<=B.value;X++)re[X]=!1;else{const X=typeof l.events=="function"?l.events:ne=>l.events.includes(ne);for(let ne=1;ne<=B.value;ne++){const de=J.value+"/"+vt(ne);re[ne]=X(de)===!0&&H.value(de)}}return re}),te=y.computed(()=>{let re,X;const{year:ne,month:de}=C.value;if(l.calendar!=="persian")re=new Date(ne,de-1,1),X=new Date(ne,de-1,0).getDate();else{const ge=Qo(ne,de,1);re=new Date(ge.gy,ge.gm-1,ge.gd);let Ee=de-1,be=ne;Ee===0&&(Ee=12,be--),X=Sn(be,Ee)}return{days:re.getDay()-Y.value-1,endDay:X}}),oe=y.computed(()=>{const re=[],{days:X,endDay:ne}=te.value,de=X<0?X+7:X;if(de<6)for(let be=ne-de;be<=ne;be++)re.push({i:be,fill:!0});const ge=re.length;for(let be=1;be<=B.value;be++){const _e={i:be,event:ae.value[be],classes:[]};le.value[be]===!0&&(_e.in=!0,_e.flat=!0),re.push(_e)}if(ee.value[J.value]!==void 0&&ee.value[J.value].forEach(be=>{const _e=ge+be-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(be=>{if(be.from!==void 0){const _e=ge+be.from-1,Be=ge+(be.to||B.value)-1;for(let ze=_e;ze<=Be;ze++)Object.assign(re[ze],{range:be.range,unelevated:!0,color:A.value,textColor:M.value});Object.assign(re[_e],{rangeFrom:!0,flat:!1}),be.to!==void 0&&Object.assign(re[Be],{rangeTo:!0,flat:!1})}else if(be.to!==void 0){const _e=ge+be.to-1;for(let Be=ge;Be<=_e;Be++)Object.assign(re[Be],{range:be.range,unelevated:!0,color:A.value,textColor:M.value});Object.assign(re[_e],{flat:!1,rangeTo:!0})}else{const _e=ge+B.value-1;for(let Be=ge;Be<=_e;Be++)Object.assign(re[Be],{range:be.range,unelevated:!0,color:A.value,textColor:M.value})}}),ue.value!==void 0){const be=ge+ue.value.from-1,_e=ge+ue.value.to-1;for(let Be=be;Be<=_e;Be++)re[Be].color=A.value,re[Be].editRange=!0;ue.value.includeFrom===!0&&(re[be].editRangeFrom=!0),ue.value.includeTo===!0&&(re[_e].editRangeTo=!0)}C.value.year===k.value.year&&C.value.month===k.value.month&&(re[ge+k.value.day-1].today=!0);const Ee=re.length%7;if(Ee>0){const be=7-Ee;for(let _e=1;_e<=be;_e++)re.push({i:_e,fill:!0})}return re.forEach(be=>{let _e="q-date__calendar-item ";be.fill===!0?_e+="q-date__calendar-item--fill":(_e+=`q-date__calendar-item--${be.in===!0?"in":"out"}`,be.range!==void 0&&(_e+=` q-date__range${be.rangeTo===!0?"-to":be.rangeFrom===!0?"-from":""}`),be.editRange===!0&&(_e+=` q-date__edit-range${be.editRangeFrom===!0?"-from":""}${be.editRangeTo===!0?"-to":""}`),(be.range!==void 0||be.editRange===!0)&&(_e+=` text-${be.color}`)),be.classes=_e}),re}),ie=y.computed(()=>l.disable===!0?{"aria-disabled":"true"}:{});y.watch(()=>l.modelValue,re=>{if(u===JSON.stringify(re))u=0;else{const X=Ne(h.value,f.value);et(X.year,X.month,X)}}),y.watch(T,()=>{d.value!==null&&b.$el.contains(document.activeElement)===!0&&d.value.focus()}),y.watch(()=>C.value.year+"|"+C.value.month,()=>{t("navigation",{year:C.value.year,month:C.value.month})}),y.watch(g,re=>{we(re,f.value,"mask"),h.value=re}),y.watch(p,re=>{we(h.value,re,"locale"),f.value=re});function se(re){u=JSON.stringify(re)}function pe(){const{year:re,month:X,day:ne}=k.value,de={...C.value,year:re,month:X,day:ne},ge=ee.value[er(de)];(ge===void 0||ge.includes(de.day)===!1)&&at(de),Ce(de.year,de.month)}function xe(re){Zo(re)===!0&&(T.value=re)}function Re(re,X){["month","year"].includes(re)&&(re==="month"?Fe:ke)(X===!0?-1:1)}function Ce(re,X){T.value="Calendar",et(re,X)}function Me(re,X){if(l.range===!1||!re){W.value=null;return}const ne=Object.assign({...C.value},re),de=X!==void 0?Object.assign({...C.value},X):ne;W.value={init:ne,initHash:$t(ne),final:de,finalHash:$t(de)},Ce(ne.year,ne.month)}function Ue(){return l.calendar==="persian"?"YYYY/MM/DD":l.mask}function Ve(re,X,ne){return is(re,X,ne,l.calendar,{hour:0,minute:0,second:0,millisecond:0})}function Ne(re,X){const ne=Array.isArray(l.modelValue)===!0?l.modelValue:l.modelValue?[l.modelValue]:[];if(ne.length===0)return qe();const de=ne[ne.length-1],ge=Ve(de.from!==void 0?de.from:de,re,X);return ge.dateHash===null?qe():ge}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 Le(re,X){(ee.value[X]?.includes(re.day)===!0?me:at)(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),$.value!==null&&re>=$.value.year&&((X>$.value.month||re>$.value.year)&&(X=$.value.month),re=$.value.year),ne!==void 0){const{hour:ge,minute:Ee,second:be,millisecond:_e,timezoneOffset:Be,timeHash:ze}=ne;Object.assign(C.value,{hour:ge,minute:Ee,second:be,millisecond:_e,timezoneOffset:Be,timeHash:ze})}const de=re+"/"+vt(X)+"/01";de!==C.value.dateHash&&(q.value=C.value.dateHash<de==(m.lang.rtl!==!0)?"left":"right",re!==C.value.year&&(P.value=q.value),y.nextTick(()=>{V.value=re-re%Yt-(re<0?Yt:0),Object.assign(C.value,{year:re,month:X,day:1,dateHash:de})}))}function He(re,X,ne){const de=re!==null&&re.length===1&&l.multiple===!1?re[0]:re,{reason:ge,details:Ee}=tt(X,ne);se(de),t("update:modelValue",de,ge,Ee)}function nt(re){const X=x.value[0]!==void 0&&x.value[0].dateHash!==null?{...x.value[0]}:{...C.value};y.nextTick(()=>{X.year=C.value.year,X.month=C.value.month;const ne=l.calendar!=="persian"?new Date(X.year,X.month,0).getDate():Sn(X.year,X.month);X.day=Math.min(Math.max(1,X.day),ne);const de=Ye(X),{details:ge}=tt("",X);se(de),t("update:modelValue",de,re,ge)})}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 at(re){let X;if(l.multiple===!0)if(re.from!==void 0){const ne=$t(re.from),de=$t(re.to),ge=x.value.filter(be=>be.dateHash<ne||be.dateHash>de),Ee=w.value.filter(({from:be,to:_e})=>_e.dateHash<ne||be.dateHash>de);X=ge.concat(Ee).concat(re).map(be=>Ye(be))}else{const ne=v.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(de=>de.from!==void 0?de.from!==ne.from&&de.to!==ne.to:!0):X=l.modelValue.filter(de=>de!==ne),X.length===0&&(X=null)}He(X,"remove",re)}function we(re,X,ne){const de=x.value.concat(w.value).map(Ee=>Ye(Ee,re,X)).filter(Ee=>Ee.from!==void 0?Ee.from.dateHash!==null&&Ee.to.dateHash!==null:Ee.dateHash!==null),ge=(l.multiple===!0?de:de[0])||null;se(ge),t("update:modelValue",ge,ne)}function Te(){if(l.minimal!==!0)return y.h("div",{class:"q-date__header "+n.value},[y.h("div",{class:"relative-position"},[y.h(y.Transition,{name:"q-transition--fade"},()=>y.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,...o("vY",{onClick(){T.value="Years"},onKeyup(re){re.keyCode===13&&(T.value="Years")}})},[Q.value]))]),y.h("div",{class:"q-date__header-title relative-position flex no-wrap"},[y.h("div",{class:"relative-position col"},[y.h(y.Transition,{name:"q-transition--fade"},()=>y.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,...o("vC",{onClick(){T.value="Calendar"},onKeyup(re){re.keyCode===13&&(T.value="Calendar")}})},[R.value]))]),l.todayBtn===!0?y.h(ct,{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:pe}):null])])}function Oe({label:re,type:X,key:ne,dir:de,goTo:ge,boundaries:Ee,cls:be}){return[y.h("div",{class:"row items-center q-date__arrow"},[y.h(ct,{round:!0,dense:!0,size:"sm",flat:!0,icon:D.value[0],"aria-label":X==="Years"?m.lang.date.prevYear:m.lang.date.prevMonth,tabindex:s.value,disable:Ee.prev===!1,...o("go-#"+X,{onClick(){ge(-1)}})})]),y.h("div",{class:"relative-position overflow-hidden flex flex-center"+be},[y.h(y.Transition,{name:"q-transition--jump-"+de},()=>y.h("div",{key:ne},[y.h(ct,{flat:!0,dense:!0,noCaps:!0,label:re,tabindex:s.value,...o("view#"+X,{onClick:()=>{T.value=X}})})]))]),y.h("div",{class:"row items-center q-date__arrow"},[y.h(ct,{round:!0,dense:!0,size:"sm",flat:!0,icon:D.value[1],"aria-label":X==="Years"?m.lang.date.nextYear:m.lang.date.nextMonth,tabindex:s.value,disable:Ee.next===!1,...o("go+#"+X,{onClick(){ge(1)}})})])]}const Ae={Calendar:()=>[y.h("div",{key:"calendar-view",class:"q-date__view q-date__calendar"},[y.h("div",{class:"q-date__navigation row items-center no-wrap"},Oe({label:f.value.months[C.value.month-1],type:"Months",key:C.value.month,dir:q.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:""}))),y.h("div",{class:"q-date__calendar-weekdays row items-center no-wrap"},F.value.map(re=>y.h("div",{class:"q-date__calendar-item"},[y.h("div",re)]))),y.h("div",{class:"q-date__calendar-days-container relative-position overflow-hidden"},[y.h(y.Transition,{name:"q-transition--slide-"+q.value},()=>y.h("div",{key:J.value,class:"q-date__calendar-days fit"},oe.value.map(re=>y.h("div",{class:re.classes},[re.in===!0?y.h(ct,{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,...o("day#"+re.i,{onClick:()=>{Qe(re.i)},onMouseover:()=>{Ke(re.i)}})},re.event!==!1?()=>y.h("div",{class:"q-date__event bg-"+re.event}):null):y.h("div",""+re.i)]))))])])],Months(){const re=C.value.year===k.value.year,X=de=>K.value!==null&&C.value.year===K.value.year&&K.value.month>de||$.value!==null&&C.value.year===$.value.year&&$.value.month<de,ne=f.value.monthsShort.map((de,ge)=>{const Ee=C.value.month===ge+1;return y.h("div",{class:"q-date__months-item flex flex-center"},[y.h(ct,{class:re===!0&&k.value.month===ge+1?"q-date__today":null,flat:Ee!==!0,label:de,unelevated:Ee,color:Ee===!0?A.value:null,textColor:Ee===!0?M.value:null,tabindex:s.value,disable:X(ge+1),...o("month#"+ge,{onClick:()=>{We(ge+1)}})})])});return l.yearsInMonthView===!0&&ne.unshift(y.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"})])),y.h("div",{key:"months-view",class:"q-date__view q-date__months flex flex-center"},ne)},Years(){const re=V.value,X=re+Yt,ne=[],de=ge=>K.value!==null&&K.value.year>ge||$.value!==null&&$.value.year<ge;for(let ge=re;ge<=X;ge++){const Ee=C.value.year===ge;ne.push(y.h("div",{class:"q-date__years-item flex flex-center"},[y.h(ct,{key:"yr"+ge,class:k.value.year===ge?"q-date__today":null,flat:!Ee,label:ge,dense:!0,unelevated:Ee,color:Ee===!0?A.value:null,textColor:Ee===!0?M.value:null,tabindex:s.value,disable:de(ge),...o("yr#"+ge,{onClick:()=>{De(ge)}})})]))}return y.h("div",{class:"q-date__view q-date__years flex flex-center"},[y.h("div",{class:"col-auto"},[y.h(ct,{round:!0,dense:!0,flat:!0,icon:D.value[0],"aria-label":m.lang.date.prevRangeYears(Yt),tabindex:s.value,disable:de(re),...o("y-",{onClick:()=>{V.value-=Yt}})})]),y.h("div",{class:"q-date__years-content col self-stretch row items-center"},ne),y.h("div",{class:"col-auto"},[y.h(ct,{round:!0,dense:!0,flat:!0,icon:D.value[1],"aria-label":m.lang.date.nextRangeYears(Yt),tabindex:s.value,disable:de(X),...o("y+",{onClick:()=>{V.value+=Yt}})})])])}};function Qe(re){const X={...C.value,day:re};if(l.range===!1){Le(X,J.value);return}if(W.value===null){const ne=oe.value.find(ge=>ge.fill!==!0&&ge.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 de=$t(X);W.value={init:X,initHash:de,final:X,finalHash:de},t("rangeStart",Ge(X))}else{const ne=W.value.initHash,de=$t(X),ge=ne<=de?{from:W.value.init,to:X}:{from:X,to:W.value.init};W.value=null,at(ne===de?X:{target:X,...ge}),t("rangeEnd",{from:Ge(ge.from),to:Ge(ge.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:pe,setView:xe,offsetCalendar:Re,setCalendarTo:Ce,setEditingRange:Me}),()=>{const re=[y.h("div",{class:"q-date__content col relative-position"},[y.h(y.Transition,{name:"q-transition--fade"},Ae[T.value])])],X=gt(I.default);return X!==void 0&&re.push(y.h("div",{class:"q-date__actions"},X)),l.name!==void 0&&l.disable!==!0&&i(re,"push"),y.h("div",{class:L.value,...ie.value},[Te(),y.h("div",{ref:d,class:"q-date__main col column",tabindex:-1},re)])}}}),ls=$e({name:"QPopupProxy",props:{...Ta,breakpoint:{type:[String,Number],default:450}},emits:["show","hide"],setup(l,{slots:I,emit:t,attrs:b}){const{proxy:m}=y.getCurrentInstance(),{$q:c}=m,o=y.ref(!1),s=y.ref(null),n=y.computed(()=>parseInt(l.breakpoint,10)),{canShow:e}=Li({showing:o});function r(){return c.screen.width<n.value||c.screen.height<n.value?"dialog":"menu"}const u=y.ref(r()),a=y.computed(()=>u.value==="menu"?{maxHeight:"99vh"}:{});y.watch(()=>r(),h=>{o.value!==!0&&(u.value=h)});function i(h){o.value=!0,t("show",h)}function d(h){o.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:i,onHide:d};let f;return u.value==="dialog"?f=zn:(f=Jr,Object.assign(h,{target:l.target,contextMenu:l.contextMenu,noParentEvent:!0,separateClosePopup:!0})),y.h(f,h,I.default)}}}),$o={date:"####/##/##",datetime:"####/##/## ##:##",time:"##:##",fulltime:"##:##:##",phone:"(###) ### - ####",card:"#### #### #### ####"},Fn={"#":{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(Fn);us.forEach(l=>{Fn[l].regex=new RegExp(Fn[l].pattern)});const yc=new RegExp("\\\\([^.*+?^${}()|([\\]])|([.*+?^${}()|[\\]])|(["+us.join("")+"])|(.)","g"),ea=/[.*+?^${}()|[\]\\]/g,Ct="",wc={mask:String,reverseFillMask:Boolean,fillMask:[Boolean,String],unmaskedValue:Boolean};function xc(l,I,t,b){let m,c,o,s,n,e;const r=y.ref(null),u=y.ref(i());function a(){return l.autogrow===!0||["textarea","text","search","url","tel","password"].includes(l.type)}y.watch(()=>l.type+l.autogrow,h),y.watch(()=>l.mask,N=>{if(N!==void 0)f(u.value,!0);else{const V=q(u.value);h(),l.modelValue!==V&&I("update:modelValue",V)}}),y.watch(()=>l.fillMask+l.reverseFillMask,()=>{r.value===!0&&f(u.value,!0)}),y.watch(()=>l.unmaskedValue,()=>{r.value===!0&&f(u.value)});function i(){if(h(),r.value===!0){const N=T(q(l.modelValue));return l.fillMask!==!1?P(N):N}return l.modelValue}function d(N){if(N<m.length)return m.slice(-N);let V="",W=m;const L=W.indexOf(Ct);if(L!==-1){for(let A=N-W.length;A>0;A--)V+=Ct;W=W.slice(0,L)+V+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=$o[l.mask]===void 0?l.mask:$o[l.mask],V=typeof l.fillMask=="string"&&l.fillMask.length!==0?l.fillMask.slice(0,1):"_",W=V.replace(ea,"\\$&"),L=[],A=[],M=[];let _=l.reverseFillMask===!0,v="",x="";N.replace(yc,(O,R,z,U,Q)=>{if(U!==void 0){const D=Fn[U];M.push(D),x=D.negate,_===!0&&(A.push("(?:"+x+"+)?("+D.pattern+"+)?(?:"+x+"+)?("+D.pattern+"+)?"),_=!1),A.push("(?:"+x+"+)?("+D.pattern+")?")}else if(z!==void 0)v="\\"+(z==="\\"?"":z),M.push(z),L.push("([^"+v+"]+)?"+v+"?");else{const D=R!==void 0?R:Q;v=D==="\\"?"\\\\\\\\":D.replace(ea,"\\\\$&"),M.push(D),L.push("([^"+v+"]+)?"+v+"?")}});const w=new RegExp("^"+L.join("")+"("+(v===""?".":"[^"+v+"]")+"+)?"+(v===""?"":"["+v+"]*")+"$"),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));o=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,D=O;Q<U;Q++){const Y=E[Q].exec(D);if(Y===null)break;D=D.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(V)}function f(N,V,W){const L=b.value,A=L.selectionEnd,M=L.value.length-A,_=q(N);V===!0&&h();const v=T(_),x=l.fillMask!==!1?P(v):v,w=u.value!==x;L.value!==x&&(L.value=x),w===!0&&(u.value=x),document.activeElement===L&&y.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>v.length?1:0:Math.max(0,x.length-(x===c?0:Math.min(v.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(v.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(v.length,A)-1);p.right(L,E)}else{const E=A-1;p.right(L,E)}});const S=l.unmaskedValue===!0?q(x):x;String(l.modelValue)!==S&&(l.modelValue!==null||S!=="")&&t(S,!0)}function g(N,V,W){const L=T(q(N.value));V=Math.max(0,m.indexOf(Ct),Math.min(L.length,V)),n=V,N.setSelectionRange(V,W,"forward")}const p={left(N,V){const W=m.slice(V-1).indexOf(Ct)===-1;let L=Math.max(0,V-1);for(;L>=0;L--)if(m[L]===Ct){V=L,W===!0&&V++;break}if(L<0&&m[V]!==void 0&&m[V]!==Ct)return p.right(N,0);V>=0&&N.setSelectionRange(V,V,"backward")},right(N,V){const W=N.value.length;let L=Math.min(W,V+1);for(;L<=W;L++)if(m[L]===Ct){V=L;break}else m[L-1]===Ct&&(V=L);if(L>W&&m[V-1]!==void 0&&m[V-1]!==Ct)return p.left(N,W);N.setSelectionRange(V,V,"forward")},leftReverse(N,V){const W=d(N.value.length);let L=Math.max(0,V-1);for(;L>=0;L--)if(W[L-1]===Ct){V=L;break}else if(W[L]===Ct&&(V=L,L===0))break;if(L<0&&W[V]!==void 0&&W[V]!==Ct)return p.rightReverse(N,0);V>=0&&N.setSelectionRange(V,V,"backward")},rightReverse(N,V){const W=N.value.length,L=d(W),A=L.slice(0,V+1).indexOf(Ct)===-1;let M=Math.min(W,V+1);for(;M<=W;M++)if(L[M-1]===Ct){V=M,V>0&&A===!0&&V--;break}if(M>W&&L[V-1]!==void 0&&L[V-1]!==Ct)return p.leftReverse(N,W);N.setSelectionRange(V,V,"forward")}};function k(N){I("click",N),e=void 0}function C(N){if(I("keydown",N),Fi(N)===!0||N.altKey===!0)return;const V=b.value,W=V.selectionStart,L=V.selectionEnd;if(N.shiftKey||(e=void 0),N.keyCode===37||N.keyCode===39){N.shiftKey&&e===void 0&&(e=V.selectionDirection==="forward"?W:L);const A=p[(N.keyCode===39?"right":"left")+(l.reverseFillMask===!0?"Reverse":"")];if(N.preventDefault(),A(V,e===W?L:W),N.shiftKey){const M=V.selectionStart;V.setSelectionRange(Math.min(e,M),Math.max(e,M),"forward")}}else N.keyCode===8&&l.reverseFillMask!==!0&&W===L?(p.left(V,W),V.setSelectionRange(V.selectionStart,L,"backward")):N.keyCode===46&&l.reverseFillMask===!0&&W===L&&(p.rightReverse(V,L),V.setSelectionRange(W,V.selectionEnd,"forward"))}function T(N){if(N==null||N==="")return"";if(l.reverseFillMask===!0)return j(N);const V=o;let W=0,L="";for(let A=0;A<V.length;A++){const M=N[W],_=V[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 j(N){const V=o,W=m.indexOf(Ct);let L=N.length-1,A="";for(let M=V.length-1;M>=0&&L!==-1;M--){const _=V[M];let v=N[L];if(typeof _=="string")A=_+A;else if(v!==void 0&&_.regex.test(v))do A=(_.transform!==void 0?_.transform(v):v)+A,L--,v=N[L];while(W===M&&v!==void 0&&_.regex.test(v));else return A}return A}function q(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:f,onMaskedKeydown:C,onMaskedClick:k}}function Sc(l,I){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 y.computed(()=>{if(l.type==="file")return t()})}const Kr=$e({name:"QInput",inheritAttrs:!1,props:{...qn,...wc,...Nn,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:[...Ki,"paste","change","keydown","click","animationend"],setup(l,{emit:I,attrs:t}){const{proxy:b}=y.getCurrentInstance(),{$q:m}=b,c={};let o=NaN,s,n,e=null,r;const u=y.ref(null),a=ya(l),{innerValue:i,hasMask:d,moveCursorForPaste:h,updateMaskValue:f,onMaskedKeydown:g,onMaskedClick:p}=xc(l,I,v,u),k=Sc(l),C=y.computed(()=>Qr(i.value)),T=Ya(M),j=Xi({changeEvent:!0}),q=y.computed(()=>l.type==="textarea"||l.autogrow===!0),P=y.computed(()=>q.value===!0||["text","search","url","tel","password"].includes(l.type)),N=y.computed(()=>{const R={...j.splitAttrs.listeners.value,onInput:M,onPaste:A,onChange:w,onBlur:S,onFocus:Dt};return R.onCompositionstart=R.onCompositionupdate=R.onCompositionend=T,d.value===!0&&(R.onKeydown=g,R.onClick=p),l.autogrow===!0&&(R.onAnimationend=_),R}),V=y.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,...j.splitAttrs.attributes.value,id:j.targetUid.value,maxlength:l.maxlength,disabled:l.disable===!0,readonly:l.readonly===!0};return q.value===!1&&(R.type=l.type),l.autogrow===!0&&(R.rows=1),R});y.watch(()=>l.type,()=>{u.value&&(u.value.value=l.modelValue)}),y.watch(()=>l.modelValue,R=>{if(d.value===!0){if(n===!0&&(n=!1,String(R)===o))return;f(R)}else i.value!==R&&(i.value=R,l.type==="number"&&c.hasOwnProperty("value")===!0&&(s===!0?s=!1:delete c.value));l.autogrow===!0&&y.nextTick(x)}),y.watch(()=>l.autogrow,R=>{R===!0?y.nextTick(x):u.value!==null&&t.rows>0&&(u.value.style.height="auto")}),y.watch(()=>l.dense,()=>{l.autogrow===!0&&y.nextTick(x)});function W(){Gr(()=>{const R=document.activeElement;u.value!==null&&u.value!==R&&(R===null||R.id!==j.targetUid.value)&&u.value.focus({preventScroll:!0})})}function L(){u.value?.select()}function A(R){if(d.value===!0&&l.reverseFillMask!==!0){const z=R.target;h(z,z.selectionStart,z.selectionEnd)}I("paste",R)}function M(R){if(!R||!R.target)return;if(l.type==="file"){I("update:modelValue",R.target.files);return}const z=R.target.value;if(R.target.qComposing===!0){c.value=z;return}if(d.value===!0)f(z,!1,R.inputType);else if(v(z),P.value===!0&&R.target===document.activeElement){const{selectionStart:U,selectionEnd:Q}=R.target;U!==void 0&&Q!==void 0&&y.nextTick(()=>{R.target===document.activeElement&&z.indexOf(R.target.value)===0&&R.target.setSelectionRange(U,Q)})}l.autogrow===!0&&x()}function _(R){I("animationend",R),x()}function v(R,z){r=()=>{e=null,l.type!=="number"&&c.hasOwnProperty("value")===!0&&delete c.value,l.modelValue!==R&&o!==R&&(o=R,z===!0&&(n=!0),I("update:modelValue",R),y.nextTick(()=>{o===R&&(o=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:D}=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(D,10)<R.scrollHeight?"auto":"hidden"),z.marginBottom="",R.scrollTop=U}})}function w(R){T(R),e!==null&&(clearTimeout(e),e=null),r?.(),I("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=i.value!==void 0?i.value:"")})}function E(){return c.hasOwnProperty("value")===!0?c.value:i.value!==void 0?i.value:""}y.onBeforeUnmount(()=>{S()}),y.onMounted(()=>{l.autogrow===!0&&x()}),Object.assign(j,{innerValue:i,fieldClass:y.computed(()=>`q-${q.value===!0?"textarea":"input"}`+(l.autogrow===!0?" q-textarea--autogrow":"")),hasShadow:y.computed(()=>l.type!=="file"&&typeof l.shadowText=="string"&&l.shadowText.length!==0),inputRef:u,emitValue:v,hasValue:C,floatingLabel:y.computed(()=>C.value===!0&&(l.type!=="number"||isNaN(i.value)===!1)||Qr(l.displayValue)),getControl:()=>y.h(q.value===!0?"textarea":"input",{ref:u,class:["q-field__native q-placeholder",l.inputClass],style:l.inputStyle,...V.value,...N.value,...l.type!=="file"?{value:E()}:k.value}),getShadowControl:()=>y.h("div",{class:"q-field__native q-field__shadow absolute-bottom no-pointer-events"+(q.value===!0?"":" text-no-wrap")},[y.h("span",{class:"invisible"},E()),y.h("span",l.shadowText)])});const O=Gi(j);return Object.assign(b,{focus:W,select:L,getNativeElement:()=>u.value}),Lt(b,"nativeEl",()=>u.value),O}});function kc(l){return{entity:l.entity,dataCy:l.dataCy,defaultLabel:l.defaultLabel,routeName:l.routeName,shouldRender:l.customShouldRender||(({store:I})=>l.storeField?!!I[l.storeField]:!0),getLabel:l.getLabel||(l.labelField?({store:I})=>l.storeField&&I[l.storeField]?.[l.labelField]||l.defaultLabel:void 0),getColor:l.customGetColor||(({store:I})=>l.storeField&&I[l.storeField]?"primary":"dark"),getRouteParams:l.routeParamKey&&l.routeParamField?({store:I})=>({[l.routeParamKey]:l.storeField&&I[l.storeField]?.[l.routeParamField]}):void 0,clearActions:[...l.clearMethods?.map(I=>({store:t})=>t[I]?.())||[],...l.navActions?.map(I=>({navStore:t})=>I(t))||[]]}}const cs=/^\d{2}-\d{2}-\d{4}$/;function _c(l){const I=l.getTimezoneOffset()*6e4;return new Date(l.getTime()+I)}function qr(l){const I=/^\d{4}-\d{2}-\d{2}$/,t=/^\d{2}-\d{2}-\d{4}$/;if(I.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 no(l,I,t,b=[]){const m=typeof l=="string"?new Date(qr(l)):new Date(l);if(Number.isNaN(m.getTime()))return!1;if(I){const s=typeof I=="string"?new Date(qr(I)):new Date(I);if(m<s)return!1}if(t){const s=typeof t=="string"?new Date(qr(t)):new Date(t);if(m>s)return!1}return b.some(s=>{if(typeof s=="string"){const n=new Date(qr(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 Qt={validateAndUpdate(l,I,t){return cs.test(I)?{...l,[t?"from":"to"]:I}:l},isEndDateValid(l,I,t=!1){if(!l||!I)return!0;try{const[b,m,c]=l.split("-"),[o,s,n]=I.split("-"),e=new Date(Number(c),Number(m)-1,Number(b)),r=new Date(Number(n),Number(s)-1,Number(o));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,I){typeof l=="string"&&I(l)}},fs={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 Cc(l){if(!l||!/^\d{2}-\d{2}-\d{4}$/.test(l))return new Date(Number.NaN);const[I,t,b]=l.split("-").map(Number);return new Date(b,t-1,I)}function zt(l){if(!l)return"";const I=new Date(l),t=I.getFullYear(),b=String(I.getMonth()+1).padStart(2,"0");return`${String(I.getDate()).padStart(2,"0")}-${b}-${t}`}function jn(l,I){return new Date(l,I-1,1)}function Dn(l,I){return new Date(l,I,0)}function ds(l=new Date){const I=l.getFullYear(),t=l.getMonth()+1;let b=t-3,m=I;b<=0&&(b+=12,m-=1);const c=jn(m,b);let o=t-1,s=I;o<=0&&(o+=12,s-=1);const n=Dn(s,o);return{from:zt(c),to:zt(n)}}const hs={currentMonth:(l=new Date)=>{const I=l.getFullYear(),t=l.getMonth()+1;return{from:zt(jn(I,t)),to:zt(Dn(I,t))}},previousMonth:(l=new Date)=>{const I=l.getFullYear();let b=l.getMonth()+1-1,m=I;return b===0&&(b=12,m=I-1),{from:zt(jn(m,b)),to:zt(Dn(m,b))}},last3Months:ds,currentYear:(l=new Date)=>{const I=l.getFullYear();return{from:zt(new Date(I,0,1)),to:zt(new Date(I,11,31))}},previousYear:(l=new Date)=>{const I=l.getFullYear()-1;return{from:zt(new Date(I,0,1)),to:zt(new Date(I,11,31))}}};function Ac(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 I=new Date(l);return Number.isNaN(I.getTime())?l:I.toISOString()}const Ec={class:"columns justify-end"},Mc=y.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:I}){const t=l,b=I,m=y.useAttrs(),c=y.ref(),o=y.ref(t.date),s=y.ref(null),n=y.computed(()=>o.value),e=C=>{if(!C||C.length!==10)return!1;const T=/^(\d{2})-(\d{2})-(\d{4})$/,j=C.match(T);if(!j)return!1;const q=Number.parseInt(j[1],10),P=Number.parseInt(j[2],10),N=Number.parseInt(j[3],10);if(P<1||P>12||q<1||q>31)return!1;const V=new Date(N,P-1,q);return V.getFullYear()===N&&V.getMonth()===P-1&&V.getDate()===q},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})$/,j=C.match(T);if(!j)return"Format invalide. Utilisez JJ-MM-AAAA";const q=Number.parseInt(j[1],10),P=Number.parseInt(j[2],10),N=Number.parseInt(j[3],10),V=u(P);if(V)return V;const W=a(q,P,N);return W||(d(q,P,N)?null:"Date inexistante")},u=C=>C<1||C>12?"Le mois doit être entre 01 et 12":null,a=(C,T,j)=>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?i(C,j):null,i=(C,T)=>{const j=T%4===0&&T%100!==0||T%400===0;return j&&C>29?"Février a maximum 29 jours pour les années bissextiles":!j&&C>28?"Février a maximum 28 jours":null},d=(C,T,j)=>{const q=new Date(j,T-1,C);return q.getFullYear()===j&&q.getMonth()===T-1&&q.getDate()===C},h=()=>{n.value?s.value=r(n.value):s.value=null},f=y.computed(()=>C=>{const T=C.replaceAll("/","-");return no(T,t.minDate,t.maxDate,t.datesDisabled)}),g=C=>{e(C)&&(o.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(o.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&&(o.value="",s.value=null,b("update:date",""),b("update:modelValue",""))},k=y.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 y.watch(()=>[t.date],([C,T])=>{const j=T??C;j&&j!==o.value&&(o.value=j,h())}),(C,T)=>(y.openBlock(),y.createElementBlock("div",Ec,[y.createVNode(Kr,y.mergeProps(y.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:y.withCtx(()=>[y.createVNode(bt,{name:"event",class:"cursor-pointer","data-testid":"calendar-icon-picker"},{default:y.withCtx(()=>[y.createVNode(ls,{ref_key:"popupRef",ref:c,cover:"","transition-show":"scale","transition-hide":"scale","no-focus":""},{default:y.withCtx(()=>[y.createVNode(ss,{mask:"DD-MM-YYYY","model-value":o.value,options:f.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"])]))}}),Tc={class:"date-range-wrapper"},Rc={class:"date-range-flex"},Bc={key:0,class:"actions-group"},Ic={class:"date-range-popup"},Oc={key:0,class:"presets-section"},Fc={class:"presets-grid"},jc={class:"presets-row"},Dc={class:"presets-row"},Pc={class:"calendar-container"},Nc={class:"popup-actions"},Lc={key:0,class:"hint"},Vc={class:"text-warning text-caption q-mb-none"},qc=y.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:()=>fs},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:I,emit:t}){const b=l,m=t,c=y.ref({from:b.from,to:b.to}),o=y.ref(null),s=y.computed(()=>`from-date-${b.idCy}`),n=y.computed(()=>`to-date-${b.idCy}`),e=y.ref(null),r=y.computed(()=>b.shortcuts.map(R=>({...R,getRange:hs[R.id]}))),u=y.computed(()=>r.value.slice(0,3)),a=y.computed(()=>r.value.slice(3)),i=()=>{c.value=Qt.reset(),j.value=null,q.value=null,e.value=null,w(),m("clear")},d=()=>{o.value&&o.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)}},f=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),D=Number.parseInt(U[2],10),Y=Number.parseInt(U[3],10);if(D<1||D>12||Q<1||Q>31)return!1;const F=new Date(Y,D-1,Q);return F.getFullYear()===Y&&F.getMonth()===D-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),D=Number.parseInt(U[2],10),Y=Number.parseInt(U[3],10),F=p(D);if(F)return F;const B=k(Q,D,Y);return B||(T(Q,D,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},j=y.ref(null),q=y.ref(null),P=()=>{c.value.from?j.value=g(c.value.from):j.value=null},N=()=>{c.value.to?q.value=g(c.value.to):q.value=null},V=y.computed(()=>R=>{const z=R.replaceAll("/","-");return no(z,b.minDate,b.maxDate,b.datesDisabled)});let W=!1;const L=()=>{W=!0,c.value.from="",j.value=null,e.value=null,w(),setTimeout(()=>{W=!1},100)},A=()=>{W=!0,c.value.to="",q.value=null,e.value=null,w(),setTimeout(()=>{W=!1},100)},M=R=>{if(R===null||R===""){const z=c.value.from;c.value.from="",j.value=null,e.value=null,w(),!c.value.to&&z&&!c.value.from&&m("clear");return}Qt.handleInput(R,z=>{const U=c.value.from;if(z&&z.length===10){const Q=g(z);if(j.value=Q,Q){c.value.from=z,w();return}}else j.value=null;c.value=Qt.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="",q.value=null,e.value=null,w(),!c.value.from&&z&&!c.value.to&&m("clear");return}Qt.handleInput(R,z=>{const U=c.value.to;if(z&&z.length===10){const Q=g(z);if(q.value=Q,Q){c.value.to=z,w();return}}else q.value=null;c.value=Qt.validateAndUpdate(c.value,z,!1),h(),w(),!z&&!c.value.from&&U&&m("clear")})},v=()=>{setTimeout(()=>{c.value.from&&c.value.from.length===10?j.value=g(c.value.from):j.value=null,c.value.to&&c.value.to.length===10?q.value=g(c.value.to):q.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=Qt.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=y.computed(()=>[...b.required?[R=>!!R||b.requiredErrorMessage]:[],...b.rules,R=>{if(R&&!f(R))return j.value||b.invalidDateErrorMessage||"Date invalide!";const z=c.value.to;if(!R||!z)return!0;const U=Qt.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=y.computed(()=>[...b.required?[R=>!!R||b.requiredErrorMessage]:[],...b.rules,R=>{if(R&&!f(R))return q.value||b.invalidDateErrorMessage||"Date invalide!";const z=c.value.from;if(!R||!z)return!0;const U=Qt.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"}]);y.watch([()=>c.value.from,()=>c.value.to],([R,z],[U,Q])=>{!R&&!z&&(U||Q)&&!W&&(j.value=null,q.value=null,e.value=null,m("clear"))}),y.watch(()=>b.from,R=>{R!==c.value.from&&(c.value.from=R,P(),h())}),y.watch(()=>b.to,R=>{R!==c.value.to&&(c.value.to=R,N(),h())}),I({setDateRange:R=>{c.value={from:R.from,to:R.to},P(),N(),h(),w()},getCurrentRange:()=>({from:c.value.from,to:c.value.to}),resetDate:()=>{i()}});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 y.onMounted(()=>{P(),N(),h()}),(R,z)=>(y.openBlock(),y.createElementBlock("div",Tc,[y.createElementVNode("div",Rc,[y.createVNode(Kr,y.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"]),y.createVNode(Kr,y.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?y.createCommentVNode("",!0):(y.openBlock(),y.createElementBlock("div",Bc,[y.createVNode(bt,{name:"event",size:"30px",class:"cursor-pointer calendar-icon",style:{opacity:"0.55"},"data-cy":"calendar-icon-range"},{default:y.withCtx(()=>[y.createVNode(ls,{cover:"","transition-show":"scale","transition-hide":"scale",ref_key:"popupRef",ref:o,"no-focus":""},{default:y.withCtx(()=>[y.createElementVNode("div",Ic,[R.hideShortcuts?y.createCommentVNode("",!0):(y.openBlock(),y.createElementBlock("div",Oc,[z[0]||(z[0]=y.createElementVNode("div",{class:"presets-title"},"Périodes rapides :",-1)),y.createElementVNode("div",Fc,[y.createElementVNode("div",jc,[(y.openBlock(!0),y.createElementBlock(y.Fragment,null,y.renderList(u.value,U=>(y.openBlock(),y.createBlock(ct,{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))]),y.createElementVNode("div",Dc,[(y.openBlock(!0),y.createElementBlock(y.Fragment,null,y.renderList(a.value,U=>(y.openBlock(),y.createBlock(ct,{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))])])])),y.createElementVNode("div",Pc,[y.createVNode(ss,{"model-value":c.value,mask:"DD-MM-YYYY","today-btn":"",range:"","data-cy":"date-picker-range",locale:R.locale,options:V.value,events:R.highlightEvents,"event-color":"warning",disable:R.disabled,"onUpdate:modelValue":x,onRangeEnd:v,"no-unset":""},null,8,["model-value","locale","options","events","disable"])]),y.createElementVNode("div",Nc,[y.createVNode(ct,{label:R.resetLabel,color:"grey-7",flat:"",dense:"",onClick:i,class:"q-mr-sm"},null,8,["label"]),y.createVNode(ct,{label:R.closeLabel,color:"primary",flat:"",dense:"",onClick:d},null,8,["label"])])])]),_:1},512)]),_:1})]))]),R.startDateHint?(y.openBlock(),y.createElementBlock("div",Lc,[y.createElementVNode("p",Vc,y.toDisplayString(R.startDateHint),1)])):y.createCommentVNode("",!0)]))}}),ps=Xt(qc,[["__scopeId","data-v-3ec8c453"]]);var lt=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function zc(l){return l&&l.__esModule&&Object.prototype.hasOwnProperty.call(l,"default")?l.default:l}function pn(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 ui={exports:{}};/*! ExcelJS 19-10-2023 */var ta;function Uc(){return ta||(ta=1,function(l,I){(function(t){l.exports=t()})(function(){return function t(b,m,c){function o(e,r){if(!m[e]){if(!b[e]){var u=typeof pn=="function"&&pn;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 i=m[e]={exports:{}};b[e][0].call(i.exports,function(d){return o(b[e][1][d]||d)},i,i.exports,t,b,m,c)}return m[e].exports}for(var s=typeof pn=="function"&&pn,n=0;n<c.length;n++)o(c[n]);return o}({1:[function(t,b,m){const c=t("fs"),o=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(i){this.workbook=i,this.worksheet=null}async readFile(i,d){if(d=d||{},!await u(i))throw new Error("File not found: "+i);const h=c.createReadStream(i),f=await this.read(h,d);return h.close(),f}read(i,d){return d=d||{},new Promise((h,f)=>{const g=this.workbook.addWorksheet(d.sheetName),p=d.dateFormats||["YYYY-MM-DD[T]HH:mm:ssZ","YYYY-MM-DD[T]HH:mm:ss","MM-DD-YYYY","YYYY-MM-DD"],k=d.map||function(T){if(T==="")return null;const j=Number(T);if(!Number.isNaN(j)&&j!==1/0)return j;const q=p.reduce((N,V)=>{if(N)return N;const W=e(T,V,!0);return W.isValid()?W:null},null);if(q)return new Date(q.valueOf());const P=a[T];return P!==void 0?P:T},C=o.parse(d.parserOptions).on("data",T=>{g.addRow(T.map(k))}).on("end",()=>{C.emit("worksheet",g)});C.on("worksheet",h).on("error",f),i.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(i,d){return new Promise((h,f)=>{d=d||{};const g=this.workbook.getWorksheet(d.sheetName||d.sheetId),p=o.format(d.formatterOptions);i.on("finish",()=>{h()}),p.on("error",f),p.pipe(i);const{dateFormat:k,dateUTC:C}=d,T=d.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}),j=d.includeEmptyRows===void 0||d.includeEmptyRows;let q=1;g&&g.eachRow((P,N)=>{if(j)for(;q++<N-1;)p.write([]);const{values:V}=P;V.shift(),p.write(V.map(T)),q=N}),p.end()})}writeFile(i,d){const h={encoding:(d=d||{}).encoding||"utf8"},f=c.createWriteStream(i,h);return this.write(f,d)}async writeBuffer(i){const d=new r;return await this.write(d,i),d.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 o{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 o||n==null?n:new o(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=o},{"../utils/col-cache":19}],3:[function(t,b,m){const c=t("../utils/col-cache"),o=t("../utils/under-dash"),s=t("./enums"),{slideFormula:n}=t("../utils/shared-formula"),e=t("./note");class r{constructor(i,d,h){if(!i||!d)throw new Error("A Cell needs a Row");this._row=i,this._column=d,c.validateAddress(h),this._address=h,this._value=u.create(r.Types.Null,this),this.style=this._mergeStyle(i.style,d.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(i){this.style.numFmt=i}get font(){return this.style.font}set font(i){this.style.font=i}get alignment(){return this.style.alignment}set alignment(i){this.style.alignment=i}get border(){return this.style.border}set border(i){this.style.border=i}get fill(){return this.style.fill}set fill(i){this.style.fill=i}get protection(){return this.style.protection}set protection(i){this.style.protection=i}_mergeStyle(i,d,h){const f=i&&i.numFmt||d&&d.numFmt;f&&(h.numFmt=f);const g=i&&i.font||d&&d.font;g&&(h.font=g);const p=i&&i.alignment||d&&d.alignment;p&&(h.alignment=p);const k=i&&i.border||d&&d.border;k&&(h.border=k);const C=i&&i.fill||d&&d.fill;C&&(h.fill=C);const T=i&&i.protection||d&&d.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(i,d){this._value.release(),this._value=u.create(r.Types.Merge,this,i),d||(this.style=i.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(i){return this._value.type===r.Types.Merge&&this._value.isMergedTo(i)}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(i){this.type!==r.Types.Merge?(this._value.release(),this._value=u.create(u.getType(i),this,i)):this._value.master.value=i}get note(){return this._comment&&this._comment.note}set note(i){this._comment=new e(i)}get text(){return this._value.toString()}get html(){return o.escapeHtml(this.text)}toString(){return this.text}_upgradeToHyperlink(i){this.type===r.Types.String&&(this._value=u.create(r.Types.Hyperlink,this,{text:this._value.value,hyperlink:i}))}get formula(){return this._value.formula}get result(){return this._value.result}get formulaType(){return this._value.formulaType}get fullAddress(){const{worksheet:i}=this._row;return{sheetName:i.name,address:this.address,row:this.row,col:this.col}}get name(){return this.names[0]}set name(i){this.names=[i]}get names(){return this.workbook.definedNames.getNamesEx(this.fullAddress)}set names(i){const{definedNames:d}=this.workbook;d.removeAllNames(this.fullAddress),i.forEach(h=>{d.addEx(this.fullAddress,h)})}addName(i){this.workbook.definedNames.addEx(this.fullAddress,i)}removeName(i){this.workbook.definedNames.removeEx(this.fullAddress,i)}removeAllNames(){this.workbook.definedNames.removeAllNames(this.fullAddress)}get _dataValidations(){return this.worksheet.dataValidations}get dataValidation(){return this._dataValidations.find(this.address)}set dataValidation(i){this._dataValidations.add(this.address,i)}get model(){const{model:i}=this._value;return i.style=this.style,this._comment&&(i.comment=this._comment.model),i}set model(i){if(this._value.release(),this._value=u.create(i.type,this),this._value.model=i,i.comment)switch(i.comment.type){case"note":this._comment=e.fromModel(i.comment)}i.style?this.style=i.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,i){this.model={address:a.address,type:r.Types.Number,value:i}}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,i){this.model={address:a.address,type:r.Types.String,value:i}}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,i){this.model={address:a.address,type:r.Types.Date,value:i}}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,i){this.model={address:a.address,type:r.Types.Hyperlink,text:i?i.text:void 0,hyperlink:i?i.hyperlink:void 0},i&&i.tooltip&&(this.model.tooltip=i.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,i){this.cell=a,this.model={address:a.address,type:r.Types.Formula,shareType:i?i.shareType:void 0,ref:i?i.ref:void 0,formula:i?i.formula:void 0,sharedFormula:i?i.sharedFormula:void 0,result:i?i.result:void 0}}_copyModel(a){const i={},d=h=>{const f=a[h];f&&(i[h]=f)};return d("formula"),d("result"),d("ref"),d("shareType"),d("sharedFormula"),i}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,i=a.findCell(this.model.sharedFormula);this._translatedFormula=i&&n(i.formula,i.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,i){this.model={address:a.address,type:r.Types.Merge,master:i?i.address:void 0},this._master=i,i&&i.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,i){this.model={address:a.address,type:r.Types.String,value:JSON.stringify(i),rawValue:i}}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,i){this.model={address:a.address,type:r.Types.SharedString,value:i}}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,i){this.model={address:a.address,type:r.Types.String,value:i}}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,i){this.model={address:a.address,type:r.Types.Boolean,value:i}}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,i){this.model={address:a.address,type:r.Types.Error,value:i}}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,i)=>(a[i.t]=i.f,a),[]),create(a,i,d){const h=this.types[a];if(!h)throw new Error("Could not create Value of type "+a);return new h(i,d)}};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"),o=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,(i,d)=>{u(i.getCell(a),d)})}get values(){const r=[];return this.eachCell((u,a)=>{u&&u.type!==o.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((i,d)=>{this._worksheet.getCell(d+a,u).value=i})}_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((i,d)=>{i.isDefault?a&&(a=null):a&&i.equivalentTo(a)?a.max=d+1:(a={min:d+1,max:d+1,width:i.width!==void 0?i.width:9,style:i.style,isCustomWidth:i.isCustomWidth,hidden:i.hidden,outlineLevel:i.outlineLevel,collapsed:i.collapsed},u.push(a))}),u.length?u:void 0}static fromModel(r,u){const a=[];let i=1,d=0;for(u=(u=u||[]).sort(function(h,f){return h.min-f.min});d<u.length;){const h=u[d++];for(;i<h.min;)a.push(new n(r,i++));for(;i<=h.max;)a.push(new n(r,i++,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,o){return this.model[c]=o}find(c){return this.model[c]}remove(c){this.model[c]=void 0}}},{}],6:[function(t,b,m){const c=t("../utils/under-dash"),o=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=o.decodeEx(r);this.addEx(a,u)}addEx(r,u){const a=this.getMatrix(u);if(r.top)for(let i=r.left;i<=r.right;i++)for(let d=r.top;d<=r.bottom;d++){const h={sheetName:r.sheetName,address:o.n2l(i)+d,row:d,col:i};a.addCellEx(h)}else a.addCellEx(r)}remove(r,u){const a=o.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(i=>{r(a,i)})})}getNames(r){return this.getNamesEx(o.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,i=new n(u.row,u.col,u.row,u.col,a);let d,h;function f(p,k){const C=r.findCellAt(a,p,u.col);return!(!C||!C.mark)&&(i[k]=p,C.mark=!1,!0)}for(h=u.row-1;f(h,"top");h--);for(h=u.row+1;f(h,"bottom");h++);function g(p,k){const C=[];for(h=i.top;h<=i.bottom;h++){const T=r.findCellAt(a,h,p);if(!T||!T.mark)return!1;C.push(T)}i[k]=p;for(let T=0;T<C.length;T++)C[T].mark=!1;return!0}for(d=u.col-1;g(d,"left");d--);for(d=u.col+1;g(d,"right");d++);return i}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,i,d)=>{a&&(a.row===i&&a.col===d||(a.row=i,a.col=d,a.address=o.n2l(d)+i))})}spliceRows(r,u,a,i){c.each(this.matrixMap,d=>{d.spliceRows(r,u,a,i),this.normaliseMatrix(d,r)})}spliceColumns(r,u,a,i){c.each(this.matrixMap,d=>{d.spliceColumns(r,u,a,i),this.normaliseMatrix(d,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 i=u[a.name]=new s;a.ranges.forEach(d=>{e.test(d.split("!").pop()||"")&&i.addCell(d)})})}}},{"../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"),o=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 o(this.worksheet,{col:a.left,row:a.top},-1),br:new o(this.worksheet,{col:a.right,row:a.bottom},0),editAs:"oneCell"}}else this.range={tl:new o(this.worksheet,r.tl,0),br:r.br&&new o(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 o{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({},o.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 o;return e.model=n,e}}o.DEFAULT_CONFIGS={note:{margins:{insetmode:"auto",inset:[.13,.13,.25,.25]},protection:{locked:"True",lockText:"True"},editAs:"absolute"}},b.exports=o},{"../utils/under-dash":26}],10:[function(t,b,m){const c=t("../utils/col-cache");class o{constructor(){this.decode(arguments)}setTLBR(n,e,r,u,a){if(arguments.length<4){const i=c.decodeAddress(n),d=c.decodeAddress(e);this.model={top:Math.min(i.row,d.row),left:Math.min(i.col,d.col),bottom:Math.max(i.row,d.row),right:Math.max(i.col,d.col),sheetName:r},this.setTLBR(i.row,i.col,d.row,d.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 o)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=o},{"../utils/col-cache":19}],11:[function(t,b,m){const c=t("../utils/under-dash"),o=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,i=new Array(a>2?a-2:0),d=2;d<a;d++)i[d-2]=arguments[d];const h=i.length-r,f=this._cells.length;let g,p,k;if(h<0)for(g=e+i.length;g<=f;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=f;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<i.length;g++)k=this.getCell(e+g),k.value=i[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!==o.ValueType.Null&&r(u,a+1)})}addPageBreak(e,r){const u=this._worksheet,a=Math.max(0,e-1)||0,i=Math.max(0,r-1)||16838,d={id:this._number,max:i,man:1};a&&(d.min=a),u.rowBreaks.push(d)}get values(){const e=[];return this._cells.forEach(r=>{r&&r.type!==o.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!==o.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!==o.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 i=a.model;i&&((!r||r>a.col)&&(r=a.col),u<a.col&&(u=a.col),e.push(i))}}),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:i}=r,d=r.col+1;a={row:i,col:d,address:s.encodeAddress(i,d),$col$row:`$${s.n2l(d)}$${i}`}}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 o{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,f,g)=>{h[f]===void 0&&(h[f]=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,f)=>{if(!h)throw new Error(f)};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:i,tableHeight:d}=this;s.autoFilterRef=c.encode(r,u,r+i-1,u+a-1),s.tableRef=c.encode(r,u,r+d-1,u+a-1),s.columns.forEach((h,f)=>{e(h.name,`Column ${f} must have a name`),f===0?n(h,"totalsRowLabel","Total"):(n(h,"totalsRowFunction","none"),h.totalsRowFormula=this.getFormula(h))})}store(){const s=(i,d)=>{d&&Object.keys(d).forEach(h=>{i[h]=d[h]})},{worksheet:n,table:e}=this,{row:r,col:u}=e.tl;let a=0;if(e.headerRow){const i=n.getRow(r+a++);e.columns.forEach((d,h)=>{const{style:f,name:g}=d,p=i.getCell(u+h);p.value=g,s(p,f)})}if(e.rows.forEach(i=>{const d=n.getRow(r+a++);i.forEach((h,f)=>{const g=d.getCell(u+f);g.value=h,s(g,e.columns[f].style)})}),e.totalsRow){const i=n.getRow(r+a++);e.columns.forEach((d,h)=>{const f=i.getCell(u+h);if(h===0)f.value=d.totalsRowLabel;else{const g=this.getFormula(d);f.value=g?{formula:d.totalsRowFormula,result:d.totalsRowResult}:null}s(f,d.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((i,d)=>{a.getCell(r+d).value=i.name})}if(n.rows.forEach(a=>{const i=s.getRow(e+u++);a.forEach((d,h)=>{i.getCell(r+h).value=d})}),n.totalsRow){const a=s.getRow(e+u++);n.columns.forEach((i,d)=>{const h=a.getCell(r+d);d===0?h.value=i.totalsRowLabel:this.getFormula(i)&&(h.value={formula:i.totalsRowFormula,result:i.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 o(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"),o=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 o}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,f)=>(f&&f.orderNo)>h?f.orderNo:h,0),i=Object.assign({},r,{id:u,name:e,orderNo:a+1,workbook:this}),d=new c(i);return this._worksheets[u]=d,d}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:i}=r,d=e.sheets&&e.sheets.findIndex(h=>h.id===u);(this._worksheets[u]=new c({id:u,name:a,orderNo:d,state:i,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"),o=t("../utils/col-cache"),s=t("./range"),n=t("./row"),e=t("./column"),r=t("./enums"),u=t("./image"),a=t("./table"),i=t("./data-validations"),d=t("../utils/encryptor"),{copyStyle:h}=t("../utils/copy-style");b.exports=class{constructor(f){f=f||{},this._workbook=f.workbook,this.id=f.id,this.orderNo=f.orderNo,this.name=f.name,this.state=f.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},f.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:!(!f.pageSetup||!f.pageSetup.fitToWidth&&!f.pageSetup.fitToHeight||f.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},f.pageSetup),this.headerFooter=Object.assign({},{differentFirst:!1,differentOddEven:!1,oddHeader:null,oddFooter:null,evenHeader:null,evenFooter:null,firstHeader:null,firstFooter:null},f.headerFooter),this.dataValidations=new i,this.views=f.views||[],this.autoFilter=f.autoFilter||null,this._media=[],this.sheetProtection=null,this.tables={},this.conditionalFormattings=[]}get name(){return this._name}set name(f){if(f===void 0&&(f="sheet"+this.id),this._name!==f){if(typeof f!="string")throw new Error("The name has to be a string.");if(f==="")throw new Error("The name can't be empty.");if(f==="History")throw new Error('The name "History" is protected. Please use a different name.');if(/[*?:/\\[\]]/.test(f))throw new Error(`Worksheet name ${f} cannot include any of the following characters: * ? : \\ / [ ]`);if(/(^')|('$)/.test(f))throw new Error("The first or last character of worksheet name cannot be a single quotation mark: "+f);if(f&&f.length>31&&(console.warn(`Worksheet name ${f} exceeds 31 chars. This will be truncated`),f=f.substring(0,31)),this._workbook._worksheets.find(g=>g&&g.name.toLowerCase()===f.toLowerCase()))throw new Error("Worksheet name already exists: "+f);this._name=f}}get workbook(){return this._workbook}destroy(){this._workbook.removeWorksheetEx(this)}get dimensions(){const f=new s;return this._rows.forEach(g=>{if(g){const p=g.dimensions;p&&f.expand(g.number,p.min,g.number,p.max)}}),f}get columns(){return this._columns}set columns(f){this._headerRowCount=f.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=[];f.forEach(k=>{const C=new e(this,g++,!1);p.push(C),C.defn=k})}getColumnKey(f){return this._keys[f]}setColumnKey(f,g){this._keys[f]=g}deleteColumnKey(f){delete this._keys[f]}eachColumnKey(f){c.each(this._keys,f)}getColumn(f){if(typeof f=="string"){const g=this._keys[f];if(g)return g;f=o.l2n(f)}if(this._columns||(this._columns=[]),f>this._columns.length){let g=this._columns.length+1;for(;g<=f;)this._columns.push(new e(this,g++))}return this._columns[f-1]}spliceColumns(f,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 V=[f,g];C.forEach(L=>{V.push(L[N]||null)});const W=this.getRow(N+1);W.splice.apply(W,V)}else this._rows.forEach(N=>{N&&N.splice(f,g)});const j=C.length-g,q=f+g,P=this._columns.length;if(j<0)for(let N=f+C.length;N<=P;N++)this.getColumn(N).defn=this.getColumn(N-j).defn;else if(j>0)for(let N=P;N>=q;N--)this.getColumn(N+j).defn=this.getColumn(N).defn;for(let N=f;N<f+C.length;N++)this.getColumn(N).defn=null;this.workbook.definedNames.spliceColumns(this.name,f,g,C.length)}get lastColumn(){return this.getColumn(this.columnCount)}get columnCount(){let f=0;return this.eachRow(g=>{f=Math.max(f,g.cellCount)}),f}get actualColumnCount(){const f=[];let g=0;return this.eachRow(p=>{p.eachCell(k=>{let{col:C}=k;f[C]||(f[C]=!0,g++)})}),g}_commitRow(){}get _lastRowNumber(){const f=this._rows;let g=f.length;for(;g>0&&f[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(f){return this._rows[f-1]}findRows(f,g){return this._rows.slice(f-1,f-1+g)}get rowCount(){return this._lastRowNumber}get actualRowCount(){let f=0;return this.eachRow(()=>{f++}),f}getRow(f){let g=this._rows[f-1];return g||(g=this._rows[f-1]=new n(this,f)),g}getRows(f,g){if(g<1)return;const p=[];for(let k=f;k<f+g;k++)p.push(this.getRow(k));return p}addRow(f){let g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"n";const p=this._nextRow,k=this.getRow(p);return k.values=f,this._setStyleOption(p,g[0]==="i"?g:"n"),k}addRows(f){let g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"n";const p=[];return f.forEach(k=>{p.push(this.addRow(k,g))}),p}insertRow(f,g){let p=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"n";return this.spliceRows(f,0,g),this._setStyleOption(f,p),this.getRow(f)}insertRows(f,g){let p=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"n";if(this.spliceRows(f,0,...g),p!=="n")for(let k=0;k<g.length;k++)p[0]==="o"&&this.findRow(g.length+f+k)!==void 0?this._copyStyle(g.length+f+k,f+k,p[1]==="+"):p[0]==="i"&&this.findRow(f-1)!==void 0&&this._copyStyle(f-1,f+k,p[1]==="+");return this.getRows(f,g.length)}_setStyleOption(f){let g=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"n";g[0]==="o"&&this.findRow(f+1)!==void 0?this._copyStyle(f+1,f,g[1]==="+"):g[0]==="i"&&this.findRow(f-1)!==void 0&&this._copyStyle(f-1,f,g[1]==="+")}_copyStyle(f,g){let p=arguments.length>2&&arguments[2]!==void 0&&arguments[2];const k=this.getRow(f),C=this.getRow(g);C.style=h(k.style),k.eachCell({includeEmpty:p},(T,j)=>{C.getCell(j).style=h(T.style)}),C.height=k.height}duplicateRow(f,g){let p=arguments.length>2&&arguments[2]!==void 0&&arguments[2];const k=this._rows[f-1],C=new Array(g).fill(k.values);this.spliceRows(f+1,p?0:g,...C);for(let T=0;T<g;T++){const j=this._rows[f+T];j.style=k.style,j.height=k.height,k.eachCell({includeEmpty:!0},(q,P)=>{j.getCell(P).style=q.style})}}spliceRows(f,g){const p=f+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 j=C.length,q=j-g,P=this._rows.length;let N,V;if(q<0)for(f===P&&(this._rows[P-1]=void 0),N=p;N<=P;N++)if(V=this._rows[N-1],V){const W=this.getRow(N+q);W.values=V.values,W.style=V.style,W.height=V.height,V.eachCell({includeEmpty:!0},(L,A)=>{W.getCell(A).style=L.style}),this._rows[N-1]=void 0}else this._rows[N+q-1]=void 0;else if(q>0)for(N=P;N>=p;N--)if(V=this._rows[N-1],V){const W=this.getRow(N+q);W.values=V.values,W.style=V.style,W.height=V.height,V.eachCell({includeEmpty:!0},(L,A)=>{if(W.getCell(A).style=L.style,L._value.constructor.name==="MergeValue"){const M=this.getRow(L._row._number+j).getCell(A),_=L._value._master,v=this.getRow(_._row._number+j).getCell(_._column._number);M.merge(v)}})}else this._rows[N+q-1]=void 0;for(N=0;N<j;N++){const W=this.getRow(f+N);W.style={},W.values=C[N]}this.workbook.definedNames.spliceRows(this.name,f,g,j)}eachRow(f,g){if(g||(g=f,f=void 0),f&&f.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 f=[];return this._rows.forEach(g=>{g&&(f[g.number]=g.values)}),f}findCell(f,g){const p=o.getAddress(f,g),k=this._rows[p.row-1];return k?k.findCell(p.col):void 0}getCell(f,g){const p=o.getAddress(f,g);return this.getRow(p.row).getCellEx(p)}mergeCells(){for(var f=arguments.length,g=new Array(f),p=0;p<f;p++)g[p]=arguments[p];const k=new s(g);this._mergeCellsInternal(k)}mergeCellsWithoutStyle(){for(var f=arguments.length,g=new Array(f),p=0;p<f;p++)g[p]=arguments[p];const k=new s(g);this._mergeCellsInternal(k,!0)}_mergeCellsInternal(f,g){c.each(this._merges,k=>{if(k.intersects(f))throw new Error("Cannot merge already merged cells")});const p=this.getCell(f.top,f.left);for(let k=f.top;k<=f.bottom;k++)for(let C=f.left;C<=f.right;C++)(k>f.top||C>f.left)&&this.getCell(k,C).merge(p,g);this._merges[p.address]=f}_unMergeMaster(f){const g=this._merges[f.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[f.address]}}get hasMerges(){return c.some(this._merges,Boolean)}unMergeCells(){for(var f=arguments.length,g=new Array(f),p=0;p<f;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 j=this.findCell(C,T);j&&(j.type===r.ValueType.Merge?this._unMergeMaster(j.master):this._merges[j.address]&&this._unMergeMaster(j))}}fillFormula(f,g,p){let k=arguments.length>3&&arguments[3]!==void 0?arguments[3]:"shared";const C=o.decode(f),{top:T,left:j,bottom:q,right:P}=C,N=P-j+1,V=o.encodeAddress(T,j),W=k==="shared";let L;L=typeof p=="function"?p:Array.isArray(p)?Array.isArray(p[0])?(M,_)=>p[M-T][_-j]:(M,_)=>p[(M-T)*N+(_-j)]:()=>{};let A=!0;for(let M=T;M<=q;M++)for(let _=j;_<=P;_++)A?(this.getCell(M,_).value={shareType:k,formula:g,ref:f,result:L(M,_)},A=!1):this.getCell(M,_).value=W?{sharedFormula:V,result:L(M,_)}:L(M,_)}addImage(f,g){const p={type:"image",imageId:f,range:g};this._media.push(new u(this,p))}getImages(){return this._media.filter(f=>f.type==="image")}addBackgroundImage(f){const g={type:"background",imageId:f};this._media.push(new u(this,g))}getBackgroundImageId(){const f=this._media.find(g=>g.type==="background");return f&&f.imageId}protect(f,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),f&&(this.sheetProtection.algorithmName="SHA-512",this.sheetProtection.saltValue=d.randomBytes(16).toString("base64"),this.sheetProtection.spinCount=g&&"spinCount"in g?g.spinCount:1e5,this.sheetProtection.hashValue=d.convertPasswordToHash(f,"SHA512",this.sheetProtection.saltValue,this.sheetProtection.spinCount)),g&&(this.sheetProtection=Object.assign(this.sheetProtection,g),!f&&"spinCount"in g&&delete this.sheetProtection.spinCount),p()})}unprotect(){this.sheetProtection=null}addTable(f){const g=new a(this,f);return this.tables[f.name]=g,g}getTable(f){return this.tables[f]}removeTable(f){delete this.tables[f]}getTables(){return Object.values(this.tables)}addConditionalFormatting(f){this.conditionalFormattings.push(f)}removeConditionalFormatting(f){typeof f=="number"?this.conditionalFormattings.splice(f,1):this.conditionalFormattings=f instanceof Function?this.conditionalFormattings.filter(f):[]}get tabColor(){return console.trace("worksheet.tabColor property is now deprecated. Please use worksheet.properties.tabColor"),this.properties.tabColor}set tabColor(f){console.trace("worksheet.tabColor property is now deprecated. Please use worksheet.properties.tabColor"),this.properties.tabColor=f}get model(){const f={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};f.cols=e.toModel(this.columns);const g=f.rows=[],p=f.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))}),f.merges=[],c.each(this._merges,k=>{f.merges.push(k.range)}),f}_parseRows(f){this._rows=[],f.rows.forEach(g=>{const p=new n(this,g.number);this._rows[p.number-1]=p,p.model=g})}_parseMergeCells(f){c.each(f.mergeCells,g=>{this.mergeCellsWithoutStyle(g)})}set model(f){this.name=f.name,this._columns=e.fromModel(this,f.cols),this._parseRows(f),this._parseMergeCells(f),this.dataValidations=new i(f.dataValidations),this.properties=f.properties,this.pageSetup=f.pageSetup,this.headerFooter=f.headerFooter,this.views=f.views,this.autoFilter=f.autoFilter,this._media=f.media.map(g=>new u(this,g)),this.sheetProtection=f.sheetProtection,this.tables=f.tables.reduce((g,p)=>{const k=new a;return k.model=p,g[p.name]=k,g},{}),this.conditionalFormattings=f.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")},o=t("./doc/enums");Object.keys(o).forEach(s=>{c[s]=o[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(o){return typeof o=="string"?o:c?c.decode(o):o.toString()}},{}],17:[function(t,b,m){const c=typeof TextEncoder>"u"?null:new TextEncoder("utf-8"),{Buffer:o}=t("buffer");m.stringToBuffer=function(s){return typeof s!="string"?s:c?o.from(c.encode(s).buffer):o.from(s)}},{buffer:220}],18:[function(t,b,m){const c=t("./under-dash"),o=t("./col-cache");b.exports=class{constructor(s){this.template=s,this.sheets={}}addCell(s){this.addCellEx(o.decodeEx(s))}getCell(s){return this.findCellEx(o.decodeEx(s),!0)}findCell(s){return this.findCellEx(o.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:o.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,i)=>{a&&n(a,u,i)})})}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 i=0;i<r;i++)a.push([]);u.splice(n,e,...a)}}spliceColumns(s,n,e,r){const u=this.sheets[s];if(u){const a=[];for(let i=0;i<r;i++)a.push(null);c.each(u,i=>{i.splice(n,e,...a)})}}}},{"./col-cache":19,"./under-dash":26}],19:[function(t,b,m){const c=/^[A-Z]+\d+$/,o={_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,i=1;if(s>=4)throw new Error("Out of bounds. Excel supports columns from 1 to 16384");if(this._l2nFill<1&&s>=1){for(;i<=26;)n=this._dictionary[i-1],this._n2l[i]=n,this._l2n[n]=i,i++;this._l2nFill=1}if(this._l2nFill<2&&s>=2){for(i=27;i<=702;)e=i-27,r=e%26,u=Math.floor(e/26),n=this._dictionary[u]+this._dictionary[r],this._n2l[i]=n,this._l2n[n]=i,i++;this._l2nFill=2}if(this._l2nFill<3&&s>=3){for(i=703;i<=16384;)e=i-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[i]=n,this._l2n[n]=i,i++;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,i="",d=0;for(let f,g=0;g<s.length;g++)if(f=s.charCodeAt(g),!a&&f>=65&&f<=90)e=!0,r+=s[g],u=26*u+f-64;else if(f>=48&&f<=57)a=!0,i+=s[g],d=10*d+f-48;else if(a&&e&&f!==36)break;if(e){if(u>16384)throw new Error("Out of bounds. Invalid column letter: "+r)}else u=void 0;a||(d=void 0);const h={address:s=r+i,col:u,row:d,$col$row:`$${r}$${i}`};return u<=100&&d<=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 i=this.decodeAddress(u[0]),d=this.decodeAddress(u[1]);const h=Math.min(i.row,d.row),f=Math.min(i.col,d.col),g=Math.max(i.row,d.row),p=Math.max(i.col,d.col);return i=this.n2l(f)+h,d=this.n2l(p)+g,{top:h,left:f,bottom:g,right:p,sheetName:e,tl:{address:i,col:f,row:h,$col$row:`$${this.n2l(f)}$${h}`,sheetName:e},br:{address:d,col:p,row:g,$col$row:`$${this.n2l(p)}$${g}`,sheetName:e},dimensions:`${i}:${d}`}}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)=>o.n2l(n)+s,encode(){switch(arguments.length){case 2:return o.encodeAddress(arguments[0],arguments[1]);case 4:return`${o.encodeAddress(arguments[0],arguments[1])}:${o.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,[i,d]=n;return i>=e&&i<=u&&d>=r&&d<=a}};b.exports=o},{}],20:[function(t,b,m){const c=(s,n)=>({...s,...n.reduce((e,r)=>(s[r]&&(e[r]={...s[r]}),e),{})}),o=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 o(s,e,"font",["color"]),o(s,e,"alignment"),o(s,e,"protection"),s.border&&(o(s,e,"border"),o(s.border,e.border,"top",["color"]),o(s.border,e.border,"left",["color"]),o(s.border,e.border,"bottom",["color"]),o(s.border,e.border,"right",["color"]),o(s.border,e.border,"diagonal",["color"])),s.fill&&(o(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 o=t("crypto"),s={hash(n){const e=o.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(),o.getHashes().indexOf(e)<0)throw new Error(`Hash algorithm '${e}' not supported!`);const a=c.from(n,"utf16le");let i=this.hash(e,c.from(r,"base64"),a);for(let d=0;d<u;d++){const h=c.alloc(4);h.writeUInt32LE(d,0),i=this.hash(e,i,h)}return i.toString("base64")},randomBytes:n=>o.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:o}=t("readable-stream"),{bufferToString:s}=t("./browser-buffer-decode");b.exports=async function*(n){n.pipe&&!n[Symbol.asyncIterator]&&(n=n.pipe(new o));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"),o=/(([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(o,(i,d,h,f,g)=>{if(g)return i;const p=s.exec(f);if(p){const k=p[1],C=p[2].toUpperCase(),T=p[3],j=p[4];if(C.length>3||C.length===3&&C>"XFD")return i;let q=c.l2n(C),P=parseInt(j,10);return k||(q+=a.col-u.col),T||(P+=a.row-u.row),(d||"")+(k||"")+c.n2l(q)+(T||"")+P}return i})}}},{"./col-cache":19}],24:[function(t,b,m){(function(c,o){(function(){const s=t("readable-stream"),n=t("./utils"),e=t("./string-buf");class r{constructor(f,g){this._data=f,this._encoding=g}get length(){return this.toBuffer().length}copy(f,g,p,k){return this.toBuffer().copy(f,g,p,k)}toBuffer(){return this._buffer||(this._buffer=o.from(this._data,this._encoding)),this._buffer}}class u{constructor(f){this._data=f}get length(){return this._data.length}copy(f,g,p,k){return this._data._buf.copy(f,g,p,k)}toBuffer(){return this._data.toBuffer()}}class a{constructor(f){this._data=f}get length(){return this._data.length}copy(f,g,p,k){this._data.copy(f,g,p,k)}toBuffer(){return this._data}}class i{constructor(f){this.size=f,this.buffer=o.alloc(f),this.iRead=0,this.iWrite=0}toBuffer(){if(this.iRead===0&&this.iWrite===this.size)return this.buffer;const f=o.alloc(this.iWrite-this.iRead);return this.buffer.copy(f,0,this.iRead,this.iWrite),f}get length(){return this.iWrite-this.iRead}get eod(){return this.iRead===this.iWrite}get full(){return this.iWrite===this.size}read(f){let g;return f===0?null:f===void 0||f>=this.length?(g=this.toBuffer(),this.iRead=this.iWrite,g):(g=o.alloc(f),this.buffer.copy(g,0,this.iRead,f),this.iRead+=f,g)}write(f,g,p){const k=Math.min(p,this.size-this.iWrite);return f.copy(this.buffer,this.iWrite,g,g+k),this.iWrite+=k,k}}const d=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(d,s.Duplex,{toBuffer(){switch(this.buffers.length){case 0:return null;case 1:return this.buffers[0].toBuffer();default:return o.concat(this.buffers.map(h=>h.toBuffer()))}},_getWritableBuffer(){if(this.buffers.length){const f=this.buffers[this.buffers.length-1];if(!f.full)return f}const h=new i(this.bufSize);return this.buffers.push(h),h},async _pipe(h){await Promise.all(this.pipes.map(function(f){return new Promise(g=>{f.write(h.toBuffer(),()=>{g()})})}))},_writeToBuffers(h){let f=0;const g=h.length;for(;f<g;)f+=this._getWritableBuffer().write(h,f,g-f)},async write(h,f,g){let p;if(f instanceof Function&&(g=f,f="utf8"),g=g||n.nop,h instanceof e)p=new u(h);else if(h instanceof o)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,f)}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,f,g){const p=k=>{k?g(k):(this._flush(),this.pipes.forEach(C=>{C.end()}),this.emit("finish"))};h?this.write(h,f,p):p()},read(h){let f;if(h){for(f=[];h&&this.buffers.length&&!this.buffers[0].eod;){const g=this.buffers[0],p=g.read(h);h-=p.length,f.push(p),g.eod&&g.full&&this.buffers.shift()}return o.concat(f)}return f=this.buffers.map(g=>g.toBuffer()).filter(Boolean),this.buffers=[],o.concat(f)},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(f=>f!==h)},unshift(){throw new Error("Not Implemented")},wrap(){throw new Error("Not Implemented")}}),b.exports=d}).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(o){this._buf=c.alloc(o&&o.size||16384),this._encoding=o&&o.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(o){o=o||0,this._buffer=void 0,this._inPos=o}_grow(o){let s=2*this._buf.length;for(;s<o;)s*=2;const n=c.alloc(s);this._buf.copy(n,0),this._buf=n}addText(o){this._buffer=void 0;let s=this._inPos+this._buf.write(o,this._inPos,this._encoding);for(;s>=this._buf.length-4;)this._grow(this._inPos+o.length),s=this._inPos+this._buf.write(o,this._inPos,this._encoding);this._inPos=s}addStringBuf(o){o.length&&(this._buffer=void 0,this.length+o.length>this.capacity&&this._grow(this.length+o.length),o._buf.copy(this._buf,this._inPos,0,o.length),this._inPos+=o.length)}}}).call(this)}).call(this,t("buffer").Buffer)},{buffer:220}],26:[function(t,b,m){const{toString:c}=Object.prototype,o=/["&<>]/,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),i=Array.isArray(e);let d;if(r!==u)return!1;switch(typeof n){case"object":if(a||i)return!(!a||!i)&&n.length===e.length&&n.every((h,f)=>{const g=e[f];return s.isEqual(h,g)});if(n===null||e===null)return n===e;if(d=Object.keys(n),Object.keys(e).length!==d.length)return!1;for(const h of d)if(!e.hasOwnProperty(h))return!1;return s.every(n,(h,f)=>{const g=e[f];return s.isEqual(h,g)});default:return n===e}},escapeHtml(n){const e=o.exec(n);if(!e)return n;let r="",u="",a=0,i=e.index;for(;i<n.length;i++){switch(n.charAt(i)){case'"':u=""";break;case"&":u="&";break;case"'":u="'";break;case"<":u="<";break;case">":u=">";break;default:continue}a!==i&&(r+=n.substring(a,i)),a=i+1,r+=u}return a!==i?r+n.substring(a,i):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 i(d,h){r=n[h],a=Array.isArray(d),s.isObject(d)||a?(a?(a=!1,u=r&&Array.isArray(r)?r:[]):u=r&&s.isObject(r)?r:{},n[h]=s.deepMerge(u,d)):s.isUndefined(d)||(n[h]=d)}for(let d=0;d<e;d++)s.each(arguments[d],i);return n}};b.exports=s},{}],27:[function(t,b,m){(function(c,o){(function(){const s=t("fs"),n=/[<>&'"\x7F\x00-\x08\x0B-\x0C\x0E-\x1F]/,e={nop(){},promiseImmediate:r=>new Promise(u=>{c.setImmediate?o(()=>{u(r)}):setTimeout(()=>{u(r)},1)}),inherits:function(r,u,a,i){r.super_=u,i||(i=a,a=null),a&&Object.keys(a).forEach(h=>{Object.defineProperty(r,h,Object.getOwnPropertyDescriptor(a,h))});const d={constructor:{value:r,enumerable:!1,writable:!1,configurable:!0}};i&&Object.keys(i).forEach(h=>{d[h]=Object.getOwnPropertyDescriptor(i,h)}),r.prototype=Object.create(u.prototype,d)},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="",i="",d=0,h=u.index;for(;h<r.length;h++){const f=r.charCodeAt(h);switch(f){case 34:i=""";break;case 38:i="&";break;case 39:i="'";break;case 60:i="<";break;case 62:i=">";break;case 127:i="";break;default:if(f<=31&&(f<=8||f>=11&&f!==13)){i="";break}continue}d!==h&&(a+=r.substring(d,h)),d=h+1,i&&(a+=i)}return d!==h?a+r.substring(d,h):a},xmlDecode:r=>r.replace(/&([a-z]*);/g,u=>{switch(u){case"<":return"<";case">":return">";case"&":return"&";case"'":return"'";case""":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 lt<"u"?lt: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"),o=t("./utils");function s(r,u,a){r.push(` ${u}="${o.xmlEncode(a.toString())}"`)}function n(r,u){if(u){const a=[];c.each(u,(i,d)=>{i!==void 0&&s(a,d,i)}),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 i=this.tos,d=this._xml;i&&this.open&&d.push(">"),this._stack.push(u),d.push("<"),d.push(u),n(d,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(o.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,i){this.openNode(u,a),i!==void 0&&this.writeText(i),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 o=t("events"),s=t("jszip"),n=t("./stream-buf"),{stringToBuffer:e}=t("./browser-buffer-encode");class r extends o.EventEmitter{constructor(a){super(),this.options=Object.assign({type:"nodebuffer",compression:"DEFLATE"},a),this.zip=new s,this.stream=new n}append(a,i){i.hasOwnProperty("base64")&&i.base64?this.zip.file(i.name,a,{base64:!0}):(c.browser&&typeof a=="string"&&(a=e(a)),this.zip.file(i.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,i){return this.stream.pipe(a,i)}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"),o=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 o;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"),o=t("../../../utils/col-cache");function s(e){try{return o.decodeEx(e),!0}catch{return!1}}function n(e){const r=[];let u=!1,a="";return e.split(",").forEach(i=>{if(!i)return;const d=(i.match(/'/g)||[]).length;if(!d)return void(u?a+=i+",":s(i)&&r.push(i));const h=d%2==0;!u&&h&&s(i)?r.push(i):u&&!h?(u=!1,s(a+i)&&r.push(a+i),a=""):(u=!0,a+=i+",")}),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"),o=t("../base-xform");b.exports=class extends o{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(o,s){o.leafNode("calcPr",{calcId:171027,fullCalcOnLoad:s.fullCalcOnLoad?1:void 0})}parseOpen(o){return o.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(o,s){o.leafNode("workbookPr",{date1904:s.date1904?1:void 0,defaultThemeVersion:164011,filterPrivacy:1})}parseOpen(o){return o.name==="workbookPr"&&(this.model={date1904:o.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(o,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),o.leafNode("workbookView",n)}parseOpen(o){if(o.name==="workbookView"){const s=this.model={},n=function(r,u,a){const i=u!==void 0?s[r]=u:a;i!==void 0&&(s[r]=i)},e=function(r,u,a){const i=u!==void 0?s[r]=parseInt(u,10):a;i!==void 0&&(s[r]=i)};return e("x",o.attributes.xWindow,0),e("y",o.attributes.yWindow,0),e("width",o.attributes.windowWidth,25e3),e("height",o.attributes.windowHeight,1e4),n("visibility",o.attributes.visibility,"visible"),e("activeTab",o.attributes.activeTab,void 0),e("firstSheet",o.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"),o=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"),i=t("./workbook-view-xform"),d=t("./workbook-properties-xform"),h=t("./workbook-calc-properties-xform");class f extends n{constructor(){super(),this.map={fileVersion:f.STATIC_XFORMS.fileVersion,workbookPr:new d,bookViews:new r({tag:"bookViews",count:!1,childXform:new i}),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(j=>{const q=j.split(":"),P={name:"_xlnm.Print_Area",ranges:[`'${T.name}'!$${q[0]}:$${q[1]}`],localSheetId:C};k.push(P)}),T.pageSetup&&(T.pageSetup.printTitlesRow||T.pageSetup.printTitlesColumn)){const j=[];if(T.pageSetup.printTitlesColumn){const P=T.pageSetup.printTitlesColumn.split(":");j.push(`'${T.name}'!$${P[0]}:$${P[1]}`)}if(T.pageSetup.printTitlesRow){const P=T.pageSetup.printTitlesRow.split(":");j.push(`'${T.name}'!$${P[0]}:$${P[1]}`)}const q={name:"_xlnm.Print_Titles",ranges:j,localSheetId:C};k.push(q)}C++}),k.length&&(p.definedNames=p.definedNames.concat(k)),(p.media||[]).forEach((T,j)=>{T.name=T.type+(j+1)})}render(p,k){p.openXml(s.StdDocAttributes),p.openNode("workbook",f.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,j=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[j++]=T))});const q=[];c.each(p.definedNames,P=>{if(P.name==="_xlnm.Print_Area"){if(T=C[P.localSheetId],T){T.pageSetup||(T.pageSetup={});const N=o.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(","),V=/\$/g,W=/\$\d+:\$\d+/,L=N.match(W);if(L&&L.length){const _=L[0];T.pageSetup.printTitlesRow=_.replace(V,"")}const A=/\$[A-Z]+:\$[A-Z]+/,M=N.match(A);if(M&&M.length){const _=M[0];T.pageSetup.printTitlesColumn=_.replace(V,"")}}}else q.push(P)}),p.definedNames=q,p.media.forEach((P,N)=>{P.index=N})}}f.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"},f.STATIC_XFORMS={fileVersion:new e({tag:"fileVersion",$:{appName:"xl",lastEdited:5,lowestEdited:5,rupBuild:9303}})},b.exports=f},{"../../../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"),o=t("../../../utils/utils"),s=t("../base-xform"),n=b.exports=function(e){this.model=e};o.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"),o=t("../../../utils/utils"),s=t("../base-xform"),n=t("./comment-xform"),e=b.exports=function(){this.map={comment:new n}};o.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(o){super(),this._model=o}get tag(){return this._model&&this._model.tag}render(o,s,n){(s===n[2]||this.tag==="x:SizeWithCells"&&s===n[1])&&o.leafNode(this.tag)}parseOpen(o){switch(o.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(o){super(),this._model=o}get tag(){return this._model&&this._model.tag}render(o,s){o.leafNode(this.tag,null,s)}parseOpen(o){switch(o.name){case this.tag:return this.text="",!0;default:return!1}}parseText(o){this.text=o}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(o){const s=Math.floor(o.left),n=Math.floor(68*(o.left-s)),e=Math.floor(o.top),r=Math.floor(18*(o.top-e)),u=Math.floor(o.right),a=Math.floor(68*(o.right-u)),i=Math.floor(o.bottom);return[s,n,e,r,u,a,i,Math.floor(18*(o.bottom-i))]}getDefaultRect(o){const s=o.col,n=Math.max(o.row-2,0);return[s,6,n,14,s+2,2,n+4,16]}render(o,s){const n=s.anchor?this.getAnchorRect(s.anchor):this.getDefaultRect(s.refAddress);o.leafNode("x:Anchor",null,n.join(", "))}parseOpen(o){switch(o.name){case this.tag:return this.text="",!0;default:return!1}}parseText(o){this.text=o}parseClose(){return!1}}},{"../base-xform":32}],44:[function(t,b,m){const c=t("../base-xform"),o=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 o,"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:i}=u.note;r.openNode(this.tag,{ObjectType:"Note"}),this.map["x:MoveWithCells"].render(r,i,e),this.map["x:SizeWithCells"].render(r,i,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"),o=t("../base-xform"),s=t("./vml-shape-xform");class n extends o{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,i)=>{this.map["v:shape"].render(r,a,i)}),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"),o=t("./vml-textbox-xform"),s=t("./vml-client-data-xform");class n extends c{constructor(){super(),this.map={"v:textbox":new o,"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(o,s,n){return`${parseFloat(o)*s.toFixed(2)}${n}`}reverseConversionUnit(o){return(o||"").split(",").map(s=>Number(parseFloat(this.conversionUnit(parseFloat(s),.1,"")).toFixed(2)))}render(o,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)}o.openNode("v:textbox",n),o.leafNode("div",{style:"text-align:left"}),o.closeNode()}parseOpen(o){switch(o.name){case this.tag:return this.model={inset:this.reverseConversionUnit(o.attributes.inset)},!0;default:return!0}}parseText(){}parseClose(o){switch(o){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(o){return{}}parseOpen(o){return this.parser=this.parser||this.map[o.name],this.parser?(this.parser.parseOpen(o),!0):o.name===this.tag&&(this.model=this.createNewModel(o),!0)}parseText(o){this.parser&&this.parser.parseText(o)}onParserClose(o,s){this.model[o]=s.model}parseClose(o){return this.parser?(this.parser.parseClose(o)||(this.onParserClose(o,this.parser),this.parser=void 0),!0):o!==this.tag}}},{"./base-xform":32}],49:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{render(o,s){o.openNode("HeadingPairs"),o.openNode("vt:vector",{size:2,baseType:"variant"}),o.openNode("vt:variant"),o.leafNode("vt:lpstr",void 0,"Worksheets"),o.closeNode(),o.openNode("vt:variant"),o.leafNode("vt:i4",void 0,s.length),o.closeNode(),o.closeNode(),o.closeNode()}parseOpen(o){return o.name==="HeadingPairs"}parseText(){}parseClose(o){return o!=="HeadingPairs"}}},{"../base-xform":32}],50:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{render(o,s){o.openNode("TitlesOfParts"),o.openNode("vt:vector",{size:s.length,baseType:"lpstr"}),s.forEach(n=>{o.leafNode("vt:lpstr",void 0,n.name)}),o.closeNode(),o.closeNode()}parseOpen(o){return o.name==="TitlesOfParts"}parseText(){}parseClose(o){return o!=="TitlesOfParts"}}},{"../base-xform":32}],51:[function(t,b,m){const c=t("../../../utils/xml-stream"),o=t("../base-xform"),s=t("../simple/string-xform"),n=t("./app-heading-pairs-xform"),e=t("./app-titles-of-parts-xform");class r extends o{constructor(){super(),this.map={Company:new s({tag:"Company"}),Manager:new s({tag:"Manager"}),HeadingPairs:new n,TitleOfParts:new e}}render(a,i){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,i.worksheets),this.map.TitleOfParts.render(a,i.worksheets),this.map.Company.render(a,i.company||""),this.map.Manager.render(a,i.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"),o=t("../base-xform");class s extends o{render(e,r){e.openXml(c.StdDocAttributes),e.openNode("Types",s.PROPERTY_ATTRIBUTES);const u={};(r.media||[]).forEach(a=>{if(a.type==="image"){const i=a.extension;u[i]||(u[i]=!0,e.leafNode("Default",{Extension:i,ContentType:"image/"+i}))}}),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 i=`/xl/worksheets/sheet${a.id}.xml`;e.leafNode("Override",{PartName:i,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:i}=a;e.leafNode("Override",{PartName:`/xl/${i}.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"),o=t("../base-xform"),s=t("../simple/date-xform"),n=t("../simple/string-xform"),e=t("../simple/integer-xform");class r extends o{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,i){a.openXml(c.StdDocAttributes),a.openNode("cp:coreProperties",r.CORE_PROPERTY_ATTRIBUTES),this.map["dc:creator"].render(a,i.creator),this.map["dc:title"].render(a,i.title),this.map["dc:subject"].render(a,i.subject),this.map["dc:description"].render(a,i.description),this.map["dc:identifier"].render(a,i.identifier),this.map["dc:language"].render(a,i.language),this.map["cp:keywords"].render(a,i.keywords),this.map["cp:category"].render(a,i.category),this.map["cp:lastModifiedBy"].render(a,i.lastModifiedBy),this.map["cp:lastPrinted"].render(a,i.lastPrinted),this.map["cp:revision"].render(a,i.revision),this.map["cp:version"].render(a,i.version),this.map["cp:contentStatus"].render(a,i.contentStatus),this.map["cp:contentType"].render(a,i.contentType),this.map["dcterms:created"].render(a,i.created),this.map["dcterms:modified"].render(a,i.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(o,s){o.leafNode("Relationship",s)}parseOpen(o){switch(o.name){case"Relationship":return this.model=o.attributes,!0;default:return!1}}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],55:[function(t,b,m){const c=t("../../../utils/xml-stream"),o=t("../base-xform"),s=t("./relationship-xform");class n extends o{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(o){if(this.parser)return this.parser.parseOpen(o),!0;switch(o.name){case this.tag:this.reset(),this.model={range:{editAs:o.attributes.editAs||"oneCell"}};break;default:this.parser=this.map[o.name],this.parser&&this.parser.parseOpen(o)}return!0}parseText(o){this.parser&&this.parser.parseText(o)}reconcilePicture(o,s){if(o&&o.rId){const n=s.rels[o.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"),o=t("./blip-xform");b.exports=class extends c{constructor(){super(),this.map={"a:blip":new o}}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(o,s){o.leafNode(this.tag,{"xmlns:r":"http://schemas.openxmlformats.org/officeDocument/2006/relationships","r:embed":s.rId,cstate:"print"})}parseOpen(o){switch(o.name){case this.tag:return this.model={rId:o.attributes["r:embed"]},!0;default:return!0}}parseText(){}parseClose(o){switch(o){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(o){o.openNode(this.tag),o.leafNode("a:picLocks",{noChangeAspect:"1"}),o.closeNode()}parseOpen(o){switch(o.name){case this.tag:default:return!0}}parseText(){}parseClose(o){switch(o){case this.tag:return!1;default:return!0}}}},{"../base-xform":32}],60:[function(t,b,m){const c=t("../base-xform"),o=t("./hlink-click-xform"),s=t("./ext-lst-xform");b.exports=class extends c{constructor(){super(),this.map={"a:hlinkClick":new o,"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"),o=t("../simple/integer-xform");b.exports=class extends c{constructor(s){super(),this.tag=s.tag,this.map={"xdr:col":new o({tag:"xdr:col",zero:!0}),"xdr:colOff":new o({tag:"xdr:colOff",zero:!0}),"xdr:row":new o({tag:"xdr:row",zero:!0}),"xdr:rowOff":new o({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"),o=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((i,d)=>{i.anchorType=function(h){return(typeof h.range=="string"?c.decode(h.range):h.range).br?"xdr:twoCellAnchor":"xdr:oneCellAnchor"}(i),this.map[i.anchorType].prepare(i,{index:d})})}get tag(){return"xdr:wsDr"}render(a,i){a.openXml(o.StdDocAttributes),a.openNode(this.tag,r.DRAWING_ATTRIBUTES),i.anchors.forEach(d=>{this.map[d.anchorType].render(a,d)}),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,i){a.anchors.forEach(d=>{d.br?this.map["xdr:twoCellAnchor"].reconcile(d,i):this.map["xdr:oneCellAnchor"].reconcile(d,i)})}}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(o){o.openNode(this.tag),o.openNode("a:ext",{uri:"{FF2B5EF4-FFF2-40B4-BE49-F238E27FC236}"}),o.leafNode("a16:creationId",{"xmlns:a16":"http://schemas.microsoft.com/office/drawing/2014/main",id:"{00000000-0008-0000-0000-000002000000}"}),o.closeNode(),o.closeNode()}parseOpen(o){switch(o.name){case this.tag:default:return!0}}parseText(){}parseClose(o){switch(o){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(o){super(),this.tag=o.tag,this.map={}}render(o,s){o.openNode(this.tag);const n=Math.floor(9525*s.width),e=Math.floor(9525*s.height);o.addAttribute("cx",n),o.addAttribute("cy",e),o.closeNode()}parseOpen(o){return o.name===this.tag&&(this.model={width:parseInt(o.attributes.cx||"0",10)/9525,height:parseInt(o.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(o,s){s.hyperlinks&&s.hyperlinks.rId&&o.leafNode(this.tag,{"xmlns:r":"http://schemas.openxmlformats.org/officeDocument/2006/relationships","r:id":s.hyperlinks.rId,tooltip:s.hyperlinks.tooltip})}parseOpen(o){switch(o.name){case this.tag:return this.model={hyperlinks:{rId:o.attributes["r:id"],tooltip:o.attributes.tooltip}},!0;default:return!0}}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],66:[function(t,b,m){const c=t("../base-xform"),o=t("./c-nv-pr-xform"),s=t("./c-nv-pic-pr-xform");b.exports=class extends c{constructor(){super(),this.map={"xdr:cNvPr":new o,"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"),o=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 o({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"),o=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 o(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"),o=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 o({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(o){super(),this.tag=o.tag,this.always=!!o.always,this.count=o.count,this.empty=o.empty,this.$count=o.$count||"count",this.$=o.$,this.childXform=o.childXform,this.maxItems=o.maxItems}prepare(o,s){const{childXform:n}=this;o&&o.forEach((e,r)=>{s.index=r,n.prepare(e,s)})}render(o,s){if(this.always||s&&s.length){o.openNode(this.tag,this.$),this.count&&o.addAttribute(this.$count,s&&s.length||0);const{childXform:n}=this;(s||[]).forEach((e,r)=>{n.render(o,e,r)}),o.closeNode()}else this.empty&&o.leafNode(this.tag)}parseOpen(o){if(this.parser)return this.parser.parseOpen(o),!0;switch(o.name){case this.tag:return this.model=[],!0;default:return!!this.childXform.parseOpen(o)&&(this.parser=this.childXform,!0)}}parseText(o){this.parser&&this.parser.parseText(o)}parseClose(o){if(this.parser){if(!this.parser.parseClose(o)&&(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(o,s){if(o){const{childXform:n}=this;o.forEach(e=>{n.reconcile(e,s)})}}}},{"./base-xform":32}],72:[function(t,b,m){const c=t("../../../utils/col-cache"),o=t("../base-xform");b.exports=class extends o{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"),o=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 o{constructor(){super(),this.richTextXForm=new e}get tag(){return"c"}prepare(u,a){const i=a.styles.addStyleModel(u.style||{},function(d){switch(d.type){case n.ValueType.Formula:return r(d.result);default:return d.type}}(u));switch(i&&(u.styleId=i),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 d=a.formulae[u.sharedFormula];if(!d)throw new Error("Shared Formula master must exist above and or left of clone for cell "+u.address);d.si===void 0?(d.shareType="shared",d.si=a.siFormulae++,d.range=new s(d.address,u.address)):d.range&&d.range.expandToAddress(u.address),u.si=d.si}}}renderFormula(u,a){let i=null;switch(a.shareType){case"shared":i={t:"shared",ref:a.ref||a.range.range,si:a.si};break;case"array":i={t:"array",ref:a.ref};break;default:a.si!==void 0&&(i={t:"shared",si:a.si})}switch(r(a.result)){case n.ValueType.Null:u.leafNode("f",i,a.formula);break;case n.ValueType.String:u.addAttribute("t","str"),u.leafNode("f",i,a.formula),u.leafNode("v",null,a.result);break;case n.ValueType.Number:u.leafNode("f",i,a.formula),u.leafNode("v",null,a.result);break;case n.ValueType.Boolean:u.addAttribute("t","b"),u.leafNode("f",i,a.formula),u.leafNode("v",null,a.result?1:0);break;case n.ValueType.Error:u.addAttribute("t","e"),u.leafNode("f",i,a.formula),u.leafNode("v",null,a.result.error);break;case n.ValueType.Date:u.leafNode("f",i,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(i=>{this.richTextXForm.render(u,i)}),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 i=u.styleId&&a.styles&&a.styles.getStyleModel(u.styleId);switch(i&&(u.style=i),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:i&&c.isDateFmt(i.numFmt)&&(u.type=n.ValueType.Date,u.value=c.excelToDate(u.value,a.date1904));break;case n.ValueType.Formula:u.result!==void 0&&i&&c.isDateFmt(i.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 d=a.hyperlinkMap[u.address];d&&(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=d);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(o,s){o.leafNode(this.tag,{iconSet:s.iconSet,iconId:s.iconId})}parseOpen(o){let{attributes:s}=o;this.model={iconSet:s.iconSet,iconId:c.toIntValue(s.iconId)}}parseClose(o){return o!==this.tag}}},{"../../base-xform":32}],75:[function(t,b,m){const{v4:c}=t("uuid"),o=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(i){return i.type==="dataBar"?n.isExt(i):!(i.type!=="iconSet"||!i.custom&&!r[i.iconSet])}prepare(i){u.isExt(i)&&(i.x14Id=`{${c()}}`.toUpperCase())}render(i,d){if(u.isExt(d))switch(d.type){case"dataBar":this.renderDataBar(i,d);break;case"iconSet":this.renderIconSet(i,d)}}renderDataBar(i,d){i.openNode(this.tag,{type:"dataBar",id:d.x14Id}),this.databarXform.render(i,d),i.closeNode()}renderIconSet(i,d){i.openNode(this.tag,{type:"iconSet",priority:d.priority,id:d.x14Id||`{${c()}}`}),this.iconSetXform.render(i,d),i.closeNode()}createNewModel(i){let{attributes:d}=i;return{type:d.type,x14Id:d.id,priority:o.toIntValue(d.priority)}}onParserClose(i,d){Object.assign(this.model,d.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"),o=t("./f-ext-xform");b.exports=class extends c{constructor(){super(),this.map={"xm:f":this.fExtXform=new o}}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"),o=t("./sqref-ext-xform"),s=t("./cf-rule-ext-xform");b.exports=class extends c{constructor(){super(),this.map={"xm:sqref":this.sqRef=new o,"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"),o=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(o.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"),o=t("../../composite-xform"),s=t("../../style/color-xform"),n=t("./cfvo-ext-xform");b.exports=class extends o{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(o,s){o.leafNode(this.tag,null,s)}parseOpen(){this.model=""}parseText(o){this.model+=o}parseClose(o){return o!==this.tag}}},{"../../base-xform":32}],81:[function(t,b,m){const c=t("../../base-xform"),o=t("../../composite-xform"),s=t("./cfvo-ext-xform"),n=t("./cf-icon-ext-xform");b.exports=class extends o{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(o,s){o.leafNode(this.tag,null,s)}parseOpen(){this.model=""}parseText(o){this.model+=o}parseClose(o){return o!==this.tag}}},{"../../base-xform":32}],83:[function(t,b,m){const c=t("../../base-xform"),o=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"),i={"3Triangles":!0,"3Stars":!0,"5Boxes":!0},d=f=>{const{type:g,operator:p}=f;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 o{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&&!i[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:j}=T;switch(C.operator){case"containsText":return`NOT(ISERROR(SEARCH("${C.text}",${j})))`;case"containsBlanks":return`LEN(TRIM(${j}))=0`;case"notContainsBlanks":return`LEN(TRIM(${j}))>0`;case"containsErrors":return`ISERROR(${j})`;case"notContainsErrors":return`NOT(ISERROR(${j}))`;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:j}=T;switch(C.timePeriod){case"thisWeek":return`AND(TODAY()-ROUNDDOWN(${j},0)<=WEEKDAY(TODAY())-1,ROUNDDOWN(${j},0)-TODAY()<=7-WEEKDAY(TODAY()))`;case"lastWeek":return`AND(TODAY()-ROUNDDOWN(${j},0)>=(WEEKDAY(TODAY())),TODAY()-ROUNDDOWN(${j},0)<(WEEKDAY(TODAY())+7))`;case"nextWeek":return`AND(ROUNDDOWN(${j},0)-TODAY()>(7-WEEKDAY(TODAY())),ROUNDDOWN(${j},0)-TODAY()<(15-WEEKDAY(TODAY())))`;case"yesterday":return`FLOOR(${j},1)=TODAY()-1`;case"today":return`FLOOR(${j},1)=TODAY()`;case"tomorrow":return`FLOOR(${j},1)=TODAY()+1`;case"last7Days":return`AND(TODAY()-FLOOR(${j},1)<=6,FLOOR(${j},1)<=TODAY())`;case"lastMonth":return`AND(MONTH(${j})=MONTH(EDATE(TODAY(),0-1)),YEAR(${j})=YEAR(EDATE(TODAY(),0-1)))`;case"thisMonth":return`AND(MONTH(${j})=MONTH(TODAY()),YEAR(${j})=YEAR(TODAY()))`;case"nextMonth":return`AND(MONTH(${j})=MONTH(EDATE(TODAY(),0+1)),YEAR(${j})=YEAR(EDATE(TODAY(),0+1)))`;default:return}})(p);k&&this.formulaXform.render(g,k),g.closeNode()}createNewModel(g){let{attributes:p}=g;return{...d(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(o,s){o.leafNode(this.tag,{type:s.type,val:s.value})}parseOpen(o){this.model={type:o.attributes.type,value:c.toFloatValue(o.attributes.val)}}parseClose(o){return o!==this.tag}}},{"../../base-xform":32}],85:[function(t,b,m){const c=t("../../composite-xform"),o=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 o}}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"),o=t("./cf-rule-xform");b.exports=class extends c{constructor(){super(),this.map={cfRule:new o}}get tag(){return"conditionalFormatting"}render(s,n){n.rules.some(o.isPrimitive)&&(s.openNode(this.tag,{sqref:n.ref}),n.rules.forEach(e=>{o.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"),o=t("./conditional-formatting-xform");b.exports=class extends c{constructor(){super(),this.cfXform=new o}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"),o=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 o}}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"),o=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 o{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 o{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(o,s){o.leafNode(this.tag,null,s)}parseOpen(){this.model=""}parseText(o){this.model+=o}parseClose(o){return o!==this.tag}}},{"../../base-xform":32}],91:[function(t,b,m){const c=t("../../base-xform"),o=t("../../composite-xform"),s=t("./cfvo-xform");b.exports=class extends o{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"),o=t("../base-xform");b.exports=class extends o{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"),o=t("../../../utils/utils"),s=t("../../../utils/col-cache"),n=t("../base-xform"),e=t("../../../doc/range");function r(a,i,d,h){const f=i[d];f!==void 0?a[d]=f:h!==void 0&&(a[d]=h)}function u(a,i,d,h){const f=i[d];f!==void 0&&(a[d]=o.parseBoolean(f))}b.exports=class extends n{get tag(){return"dataValidations"}render(a,i){const d=function(h){const f=c.map(h,(k,C)=>({address:C,dataValidation:k,marked:!1})).sort((k,C)=>c.strcmp(k.address,C.address)),g=c.keyBy(f,"address"),p=(k,C,T)=>{for(let j=0;j<C;j++){const q=s.encodeAddress(k.row+j,T);if(!h[q]||!c.isEqual(h[k.address],h[q]))return!1}return!0};return f.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,j=s.encodeAddress(C.row+T,C.col);for(;h[j]&&c.isEqual(k.dataValidation,h[j]);)T++,j=s.encodeAddress(C.row+T,C.col);let q=1;for(;p(C,T,C.col+q);)q++;for(let P=0;P<T;P++)for(let N=0;N<q;N++)j=s.encodeAddress(C.row+P,C.col+N),g[j].marked=!0;if(T>1||q>1){const P=C.row+(T-1),N=C.col+(q-1);return{...k.dataValidation,sqref:`${k.address}:${s.encodeAddress(P,N)}`}}return{...k.dataValidation,sqref:k.address}}return null}).filter(Boolean)}(i);d.length&&(a.openNode("dataValidations",{count:d.length}),d.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((f,g)=>{a.openNode("formula"+(g+1)),h.type==="date"?a.writeText(o.dateToExcel(new Date(f))):a.writeText(f),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 i={type:a.attributes.type||"any",formulae:[]};switch(a.attributes.type&&u(i,a.attributes,"allowBlank"),u(i,a.attributes,"showInputMessage"),u(i,a.attributes,"showErrorMessage"),i.type){case"any":case"list":case"custom":break;default:r(i,a.attributes,"operator","between")}return r(i,a.attributes,"promptTitle"),r(i,a.attributes,"prompt"),r(i,a.attributes,"errorStyle"),r(i,a.attributes,"errorTitle"),r(i,a.attributes,"error"),this._dataValidation=i,!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(i=>{i.includes(":")?new e(i).forEachAddress(d=>{this.model[d]=this._dataValidation}):this.model[i]=this._dataValidation}),!0;case"formula1":case"formula2":{let i=this._formula.join("");switch(this._dataValidation.type){case"whole":case"textLength":i=parseInt(i,10);break;case"decimal":i=parseFloat(i);break;case"date":i=o.excelToDate(parseFloat(i))}return this._dataValidation.formulae.push(i),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(o,s){s&&o.leafNode("dimension",{ref:s})}parseOpen(o){return o.name==="dimension"&&(this.model=o.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(o,s){s&&o.leafNode(this.tag,{"r:id":s.rId})}parseOpen(o){switch(o.name){case this.tag:return this.model={rId:o.attributes["r:id"]},!0;default:return!1}}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],96:[function(t,b,m){const c=t("../composite-xform"),o=t("./cf-ext/conditional-formattings-ext-xform");class s extends c{constructor(){super(),this.map={"x14:conditionalFormattings":this.conditionalFormattings=new o}}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(o,s){if(s){o.addRollback();let n=!1;o.openNode("headerFooter"),s.differentFirst&&(o.addAttribute("differentFirst","1"),n=!0),s.differentOddEven&&(o.addAttribute("differentOddEven","1"),n=!0),s.oddHeader&&typeof s.oddHeader=="string"&&(o.leafNode("oddHeader",null,s.oddHeader),n=!0),s.oddFooter&&typeof s.oddFooter=="string"&&(o.leafNode("oddFooter",null,s.oddFooter),n=!0),s.evenHeader&&typeof s.evenHeader=="string"&&(o.leafNode("evenHeader",null,s.evenHeader),n=!0),s.evenFooter&&typeof s.evenFooter=="string"&&(o.leafNode("evenFooter",null,s.evenFooter),n=!0),s.firstHeader&&typeof s.firstHeader=="string"&&(o.leafNode("firstHeader",null,s.firstHeader),n=!0),s.firstFooter&&typeof s.firstFooter=="string"&&(o.leafNode("firstFooter",null,s.firstFooter),n=!0),n?(o.closeNode(),o.commit()):o.rollback()}}parseOpen(o){switch(o.name){case"headerFooter":return this.model={},o.attributes.differentFirst&&(this.model.differentFirst=parseInt(o.attributes.differentFirst,0)===1),o.attributes.differentOddEven&&(this.model.differentOddEven=parseInt(o.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(o){switch(this.currentNode){case"oddHeader":this.model.oddHeader=o;break;case"oddFooter":this.model.oddFooter=o;break;case"evenHeader":this.model.evenHeader=o;break;case"evenFooter":this.model.evenFooter=o;break;case"firstHeader":this.model.firstHeader=o;break;case"firstFooter":this.model.firstFooter=o}}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(o,s){this.isInternalLink(s)?o.leafNode("hyperlink",{ref:s.address,"r:id":s.rId,tooltip:s.tooltip,location:s.target}):o.leafNode("hyperlink",{ref:s.address,"r:id":s.rId,tooltip:s.tooltip})}parseOpen(o){return o.name==="hyperlink"&&(this.model={address:o.attributes.ref,rId:o.attributes["r:id"],tooltip:o.attributes.tooltip},o.attributes.location&&(this.model.target=o.attributes.location),!0)}parseText(){}parseClose(){return!1}isInternalLink(o){return o.target&&/^[^!]+![a-zA-Z]+[\d]+$/.test(o.target)}}},{"../base-xform":32}],99:[function(t,b,m){const c=t("../base-xform");b.exports=class extends c{get tag(){return"mergeCell"}render(o,s){o.leafNode("mergeCell",{ref:s})}parseOpen(o){return o.name==="mergeCell"&&(this.model=o.attributes.ref,!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],100:[function(t,b,m){const c=t("../../../utils/under-dash"),o=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 o(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 i=a.top;i<=a.bottom;i++){const d=r[i-1];for(let h=a.left;h<=a.right;h++){const f=d.cells[h-1];f?f.type===n.ValueType.Merge&&(f.master=a.tl):d.cells[h]={type:n.ValueType.Null,address:s.encodeAddress(i,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"),o=s=>s!==void 0;b.exports=class extends c{get tag(){return"outlinePr"}render(s,n){return!(!n||!o(n.summaryBelow)&&!o(n.summaryRight))&&(s.leafNode(this.tag,{summaryBelow:o(n.summaryBelow)?Number(n.summaryBelow):void 0,summaryRight:o(n.summaryRight)?Number(n.summaryRight):void 0}),!0)}parseOpen(s){return s.name===this.tag&&(this.model={summaryBelow:o(s.attributes.summaryBelow)?!!Number(s.attributes.summaryBelow):void 0,summaryRight:o(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(o,s){o.leafNode("brk",s)}parseOpen(o){return o.name==="brk"&&(this.model=o.attributes.ref,!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],103:[function(t,b,m){const c=t("../../../utils/under-dash"),o=t("../base-xform");b.exports=class extends o{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(o,s){return!(!s||!s.fitToPage)&&(o.leafNode(this.tag,{fitToPage:s.fitToPage?"1":void 0}),!0)}parseOpen(o){return o.name===this.tag&&(this.model={fitToPage:o.attributes.fitToPage==="1"},!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],105:[function(t,b,m){const c=t("../../../utils/under-dash"),o=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 o{get tag(){return"pageSetup"}render(u,a){if(a){const i={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(i,d=>d!==void 0)&&u.leafNode(this.tag,i)}}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(o,s){s&&o.leafNode(this.tag,{"r:id":s.rId})}parseOpen(o){switch(o.name){case this.tag:return this.model={rId:o.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"),o=t("../base-xform");function s(n){return n?"1":void 0}b.exports=class extends o{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"),o=t("../list-xform");b.exports=class extends o{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"),o=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)),o.parseBoolean(n.attributes.hidden)&&(r.hidden=!0),o.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)),o.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"),o=t("../base-xform");b.exports=class extends o{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"),o=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 o("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"),o=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 o{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"),o=t("../base-xform"),s={frozen:"frozen",frozenSplit:"frozen",split:"split"};b.exports=class extends o{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,f,g){g&&n.addAttribute(h,f)};let u,a,i,d;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,i=e.ySplit||0,u=e.topLeftCell||c.getAddress(i+1,a+1).address,d=(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:d,state:"frozen"}),n.leafNode("selection",{pane:d,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(o,s){s&&o.leafNode(this.tag,{"r:id":s.rId})}parseOpen(o){switch(o.name){case this.tag:return this.model={rId:o.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"),o=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"),i=t("./col-xform"),d=t("./dimension-xform"),h=t("./hyperlink-xform"),f=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"),j=t("./page-margins-xform"),q=t("./page-setup-xform"),P=t("./print-options-xform"),N=t("./auto-filter-xform"),V=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"),v=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?((D,Y)=>{Object.keys(Y).forEach(F=>{const B=D[F],H=Y[F];B===void 0&&H!==void 0&&(D[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 d,sheetViews:new u({tag:"sheetViews",count:!1,childXform:new C}),sheetFormatPr:new k,cols:new u({tag:"cols",count:!1,childXform:new i}),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 f}),rowBreaks:new A,hyperlinks:new u({tag:"hyperlinks",count:!1,childXform:new h}),pageMargins:new j,dataValidations:new g,pageSetup:new q,headerFooter:new M,printOptions:new P,picture:new V,drawing:new W,sheetProtection:new T,tableParts:new u({tag:"tableParts",count:!0,childXform:new L}),conditionalFormatting:new _,extLst:new v}}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(D){return"rId"+(D.length+1)}if(E.hyperlinks.forEach(D=>{const Y=z(R);D.rId=Y,R.push({Id:Y,Type:n.Hyperlink,Target:D.target,TargetMode:"External"})}),E.comments.length>0){const D={Id:z(R),Type:n.Comments,Target:`../comments${E.id}.xml`};R.push(D);const Y={Id:z(R),Type:n.VmlDrawing,Target:`../drawings/vmlDrawing${E.id}.vml`};R.push(Y),E.comments.forEach(F=>{F.refAddress=o.decodeAddress(F.ref)}),O.commentRefs.push({commentName:"comments"+E.id,vmlDrawing:"vmlDrawing"+E.id})}const U=[];let Q;E.media.forEach(D=>{if(D.type==="background"){const Y=z(R);Q=O.media[D.imageId],R.push({Id:Y,Type:n.Image,Target:`../media/${Q.name}.${Q.extension}`}),E.background={rId:Y},E.image=O.media[D.imageId]}else if(D.type==="image"){let{drawing:Y}=E;Q=O.media[D.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===D.imageId?U[D.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 B={picture:{rId:F},range:D.range};if(D.hyperlinks&&D.hyperlinks.hyperlink){const H=z(Y.rels);U[Y.rels.length]=H,B.picture.hyperlinks={tooltip:D.hyperlinks.tooltip,rId:H},Y.rels.push({Id:H,Type:n.Hyperlink,Target:D.hyperlinks.hyperlink,TargetMode:"External"})}this.preImageId=D.imageId,Y.anchors.push(B)}}),E.tables.forEach(D=>{const Y=z(R);D.rId=Y,R.push({Id:Y,Type:n.Table,Target:"../tables/"+D.target}),D.columns.forEach(F=>{const{style:B}=F;B&&(F.dxfId=O.styles.addDxfStyle(B))})}),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},D=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,D),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 D=O.vmlDrawings[Q.Target].comments;E.comments.forEach((Y,F)=>{Y.note=Object.assign({},Y.note,D[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(D=>{if(D.medium){const Y={type:"image",imageId:D.medium.index,range:D.range,hyperlinks:D.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(o){super(),this.tag=o.tag,this.attr=o.attr}render(o,s){s&&(o.openNode(this.tag),o.closeNode())}parseOpen(o){o.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(o){super(),this.tag=o.tag,this.attr=o.attr,this.attrs=o.attrs,this._format=o.format||function(s){try{return Number.isNaN(s.getTime())?"":s.toISOString()}catch{return""}},this._parse=o.parse||function(s){return new Date(s)}}render(o,s){s&&(o.openNode(this.tag),this.attrs&&o.addAttributes(this.attrs),this.attr?o.addAttribute(this.attr,this._format(s)):o.writeText(this._format(s)),o.closeNode())}parseOpen(o){o.name===this.tag&&(this.attr?this.model=this._parse(o.attributes[this.attr]):this.text=[])}parseText(o){this.attr||this.text.push(o)}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(o){super(),this.tag=o.tag,this.attr=o.attr,this.attrs=o.attrs,this.zero=o.zero}render(o,s){(s||this.zero)&&(o.openNode(this.tag),this.attrs&&o.addAttributes(this.attrs),this.attr?o.addAttribute(this.attr,s):o.writeText(s),o.closeNode())}parseOpen(o){return o.name===this.tag&&(this.attr?this.model=parseInt(o.attributes[this.attr],10):this.text=[],!0)}parseText(o){this.attr||this.text.push(o)}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(o){super(),this.tag=o.tag,this.attr=o.attr,this.attrs=o.attrs}render(o,s){s!==void 0&&(o.openNode(this.tag),this.attrs&&o.addAttributes(this.attrs),this.attr?o.addAttribute(this.attr,s):o.writeText(s),o.closeNode())}parseOpen(o){o.name===this.tag&&(this.attr?this.model=o.attributes[this.attr]:this.text=[])}parseText(o){this.attr||this.text.push(o)}parseClose(){return this.attr||(this.model=this.text.join("")),!1}}},{"../base-xform":32}],120:[function(t,b,m){const c=t("./base-xform"),o=t("../../utils/xml-stream");b.exports=class extends c{constructor(s){super(),this._model=s}render(s){if(!this._xml){const n=new o;(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"),o=t("./rich-text-xform"),s=t("../base-xform");b.exports=class extends s{constructor(){super(),this.map={r:new o,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"),o=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 o(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"),o=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 o,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"),o=t("../base-xform"),s=t("./shared-string-xform");b.exports=class extends o{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(o,s){o.openNode("t"),/^\s|\n|\s$/.test(s)&&o.addAttribute("xml:space","preserve"),o.writeText(s),o.closeNode()}get model(){return this._text.join("").replace(/_x([0-9A-F]{4})_/g,(o,s)=>String.fromCharCode(parseInt(s,16)))}parseOpen(o){switch(o.name){case"t":return this._text=[],!0;default:return!1}}parseText(o){this._text.push(o)}parseClose(){return!1}}},{"../base-xform":32}],126:[function(t,b,m){const c=t("../../../doc/enums"),o=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=o.validInt(r))>=-90&&r<=90?r:void 0}},indent:r=>(r=o.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=o.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 i(d,h){h&&(r.addAttribute(d,h),a=!0)}i("horizontal",n.horizontal(u.horizontal)),i("vertical",n.vertical(u.vertical)),i("wrapText",!!n.wrapText(u.wrapText)&&"1"),i("shrinkToFit",!!n.shrinkToFit(u.shrinkToFit)&&"1"),i("indent",n.indent(u.indent)),i("textRotation",e.toXml(u.textRotation)),i("readingOrder",n.readingOrder(u.readingOrder)),r.closeNode(),a?r.commit():r.rollback()}parseOpen(r){const u={};let a=!1;function i(d,h,f){d&&(u[h]=f,a=!0)}i(r.attributes.horizontal,"horizontal",r.attributes.horizontal),i(r.attributes.vertical,"vertical",r.attributes.vertical==="center"?"middle":r.attributes.vertical),i(r.attributes.wrapText,"wrapText",o.parseBoolean(r.attributes.wrapText)),i(r.attributes.shrinkToFit,"shrinkToFit",o.parseBoolean(r.attributes.shrinkToFit)),i(r.attributes.indent,"indent",parseInt(r.attributes.indent,10)),i(r.attributes.textRotation,"textRotation",e.toModel(r.attributes.textRotation)),i(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"),o=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 i=u&&u.color||a||this.defaultColor;r.openNode(this.name),u&&u.style&&(r.addAttribute("style",u.style),i&&this.map.color.render(r,i)),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(i,d){i&&!i.color&&r.color&&(i={...i,color:r.color}),d.render(e,i,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=o.parseBoolean(e.attributes.diagonalUp),this.diagonalDown=o.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,i,d){i&&(d&&Object.assign(i,d),r[a]=i)};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(o){super(),this.name=o||"color"}get tag(){return this.name}render(o,s){return!!s&&(o.openNode(this.name),s.argb?o.addAttribute("rgb",s.argb):s.theme!==void 0?(o.addAttribute("theme",s.theme),s.tint!==void 0&&o.addAttribute("tint",s.tint)):s.indexed!==void 0?o.addAttribute("indexed",s.indexed):o.addAttribute("auto","1"),o.closeNode(),!0)}parseOpen(o){return o.name===this.name&&(o.attributes.rgb?this.model={argb:o.attributes.rgb}:o.attributes.theme?(this.model={theme:parseInt(o.attributes.theme,10)},o.attributes.tint&&(this.model.tint=parseFloat(o.attributes.tint))):o.attributes.indexed?this.model={indexed:parseInt(o.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"),o=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 o,border:new s,fill:new n,font:new e,numFmt:new r,protection:new u}}get tag(){return"dxf"}render(a,i){if(a.openNode(this.tag),i.font&&this.map.font.render(a,i.font),i.numFmt&&i.numFmtId){const d={id:i.numFmtId,formatCode:i.numFmt};this.map.numFmt.render(a,d)}i.fill&&this.map.fill.render(a,i.fill),i.alignment&&this.map.alignment.render(a,i.alignment),i.border&&this.map.border.render(a,i.border),i.protection&&this.map.protection.render(a,i.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"),o=t("./color-xform");class s extends c{constructor(){super(),this.map={color:new o}}get tag(){return"stop"}render(a,i){a.openNode("stop"),a.addAttribute("position",i.position),this.map.color.render(a,i.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 o("fgColor"),bgColor:new o("bgColor")}}get name(){return"pattern"}get tag(){return"patternFill"}render(a,i){a.openNode("patternFill"),a.addAttribute("patternType",i.pattern),i.fgColor&&this.map.fgColor.render(a,i.fgColor),i.bgColor&&this.map.bgColor.render(a,i.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,i){switch(a.openNode("gradientFill"),i.gradient){case"angle":a.addAttribute("degree",i.degree);break;case"path":a.addAttribute("type","path"),i.center.left&&(a.addAttribute("left",i.center.left),i.center.right===void 0&&a.addAttribute("right",i.center.left)),i.center.right&&a.addAttribute("right",i.center.right),i.center.top&&(a.addAttribute("top",i.center.top),i.center.bottom===void 0&&a.addAttribute("bottom",i.center.top)),i.center.bottom&&a.addAttribute("bottom",i.center.bottom)}const d=this.map.stop;i.stops.forEach(h=>{d.render(a,h)}),a.closeNode()}parseOpen(a){if(this.parser)return this.parser.parseOpen(a),!0;switch(a.name){case"gradientFill":{const i=this.model={stops:[]};return a.attributes.degree?(i.gradient="angle",i.degree=parseInt(a.attributes.degree,10)):a.attributes.type==="path"&&(i.gradient="path",i.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&&(i.center.right=a.attributes.right?parseFloat(a.attributes.right):0),a.attributes.bottom!==a.attributes.top&&(i.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,i){switch(a.addRollback(),a.openNode("fill"),i.type){case"pattern":this.map.patternFill.render(a,i);break;case"gradient":this.map.gradientFill.render(a,i);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"),o=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(d){super(),this.options=d||a.OPTIONS,this.map={b:{prop:"bold",xform:new o({tag:"b",attr:"val"})},i:{prop:"italic",xform:new o({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 o({tag:"condense",attr:"val"})},extend:{prop:"extend",xform:new o({tag:"extend",attr:"val"})},family:{prop:"family",xform:new s({tag:"family",attr:"val"})},outline:{prop:"outline",xform:new o({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 o({tag:"shadow",attr:"val"})},strike:{prop:"strike",xform:new o({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(d,h){const{map:f}=this;d.openNode(this.options.tagName),r.each(this.map,(g,p)=>{f[p].xform.render(d,h[g.prop])}),d.closeNode()}parseOpen(d){if(this.parser)return this.parser.parseOpen(d),!0;if(this.map[d.name])return this.parser=this.map[d.name].xform,this.parser.parseOpen(d);switch(d.name){case this.options.tagName:return this.model={},!0;default:return!1}}parseText(d){this.parser&&this.parser.parseText(d)}parseClose(d){if(this.parser&&!this.parser.parseClose(d)){const h=this.map[d];return this.parser.model&&(this.model[h.prop]=this.parser.model),this.parser=void 0,!0}switch(d){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"),o=t("../../defaultnumformats"),s=t("../base-xform"),n=function(){const r={};return c.each(o,(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 o[r]&&o[r].f},b.exports=e},{"../../../utils/under-dash":26,"../../defaultnumformats":30,"../base-xform":32}],133:[function(t,b,m){const c=t("../base-xform"),o={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",o.boolean(n.locked,!0)?void 0:"0"),r("hidden",o.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"),o=t("./alignment-xform"),s=t("./protection-xform");b.exports=class extends c{constructor(n){super(),this.xfId=!(!n||!n.xfId),this.map={alignment:new o,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"),o=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"),i=t("./numfmt-xform"),d=t("./style-xform"),h=t("./dxf-xform");class f extends s{constructor(p){super(),this.map={numFmts:new e({tag:"numFmts",count:!0,childXform:new i}),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 d}),cellXfs:new e({tag:"cellXfs",count:!0,childXform:new d({xfId:!0})}),dxfs:new e({tag:"dxfs",always:!0,count:!0,childXform:new h}),numFmt:new i,font:new r,fill:new u,border:new a,style:new d({xfId:!0}),cellStyles:f.STATIC_XFORMS.cellStyles,tableStyles:f.STATIC_XFORMS.tableStyles,extLst:f.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(o.StdDocAttributes),p.openNode("styleSheet",f.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)),f.STATIC_XFORMS.cellStyles.render(p),this.map.dxfs.render(p,k.dxfs),f.STATIC_XFORMS.tableStyles.render(p),f.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 j=this.index.numFmt[k.numFmtId]||i.getDefaultFmtCode(k.numFmtId);j&&(C.numFmt=j)}function T(j,q,P){if(P||P===0){const N=q[P];N&&(C[j]=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=i.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}}f.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"},f.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"}}]}]})},f.Mock=class extends f{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:i.getDefaultFmtId("mm-dd-yy")};this._dateStyleId=this.model.styles.length,this.model.styles.push(g)}return this._dateStyleId}getStyleModel(){return{}}},b.exports=f},{"../../../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 o 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=o.Attributes[e];r&&n.leafNode("u",r)}}parseOpen(n){n.name==="u"&&(this.model=n.attributes.val||!0)}parseText(){}parseClose(){return!1}}o.Attributes={single:{},double:{val:"double"},singleAccounting:{val:"singleAccounting"},doubleAccounting:{val:"doubleAccounting"}},b.exports=o},{"../base-xform":32}],137:[function(t,b,m){const c=t("../base-xform"),o=t("./filter-column-xform");b.exports=class extends c{constructor(){super(),this.map={filterColumn:new o}}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(o,s){o.leafNode(this.tag,{val:s.val,operator:s.operator})}parseOpen(o){return o.name===this.tag&&(this.model={val:o.attributes.val,operator:o.attributes.operator},!0)}parseText(){}parseClose(){return!1}}},{"../base-xform":32}],139:[function(t,b,m){const c=t("../base-xform"),o=t("../list-xform"),s=t("./custom-filter-xform"),n=t("./filter-xform");b.exports=class extends c{constructor(){super(),this.map={customFilters:new o({tag:"customFilters",count:!1,empty:!0,childXform:new s}),filters:new o({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(o,s){o.leafNode(this.tag,{val:s.val})}parseOpen(o){return o.name===this.tag&&(this.model={val:o.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(o,s){o.id=s.index+1}render(o,s){return o.leafNode(this.tag,{id:s.id.toString(),name:s.name,totalsRowLabel:s.totalsRowLabel,totalsRowFunction:s.totalsRowFunction,dxfId:s.dxfId}),!0}parseOpen(o){if(o.name===this.tag){const{attributes:s}=o;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(o,s){return o.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(o){if(o.name===this.tag){const{attributes:s}=o;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"),o=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 o{constructor(){super(),this.map={autoFilter:new n,tableColumns:new s({tag:"tableColumns",count:!0,empty:!0,childXform:new e}),tableStyleInfo:new r}}prepare(i,d){this.map.autoFilter.prepare(i),this.map.tableColumns.prepare(i.columns,d)}get tag(){return"table"}render(i,d){i.openXml(c.StdDocAttributes),i.openNode(this.tag,{...u.TABLE_ATTRIBUTES,id:d.id,name:d.name,displayName:d.displayName||d.name,ref:d.tableRef,totalsRowCount:d.totalsRow?"1":void 0,totalsRowShown:d.totalsRow?void 0:"1",headerRowCount:d.headerRow?"1":"0"}),this.map.autoFilter.render(i,d),this.map.tableColumns.render(i,d.columns),this.map.tableStyleInfo.render(i,d.style),i.closeNode()}parseOpen(i){if(this.parser)return this.parser.parseOpen(i),!0;const{name:d,attributes:h}=i;switch(d){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[i.name],this.parser&&this.parser.parseOpen(i)}return!0}parseText(i){this.parser&&this.parser.parseText(i)}parseClose(i){if(this.parser)return this.parser.parseClose(i)||(this.parser=void 0),!0;switch(i){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((d,h)=>{this.model.columns[h].filterButton=d.filterButton})),this.model.style=this.map.tableStyleInfo.model,!1;default:return!0}}reconcile(i,d){i.columns.forEach(h=>{h.dxfId!==void 0&&(h.style=d.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,o){(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"),i=t("../utils/xml-stream"),{bufferToString:d}=t("../utils/browser-buffer-decode"),h=t("./xform/style/styles-xform"),f=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"),j=t("./xform/sheet/worksheet-xform"),q=t("./xform/drawing/drawing-xform"),P=t("./xform/table/table-xform"),N=t("./xform/comment/comments-xform"),V=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 v=s.createReadStream(M);try{const x=await this.read(v,_);return v.close(),x}catch(x){throw v.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 v=new T,x=new j(_),w=new q,S=new P;v.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((D,Y)=>(D[Y.Id]=Y,D),{}),(U.anchors||[]).forEach(D=>{const Y=D.picture&&D.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,_,v,x,w){const S=new j(x),E=await S.parseStream(M);E.sheetNo=v,_.worksheetHash[w]=E,_.worksheets.push(E)}async _processCommentEntry(M,_,v){const x=new N,w=await x.parseStream(M);_.comments[`../${v}.xml`]=w}async _processTableEntry(M,_,v){const x=new P,w=await x.parseStream(M);_.tables[`../tables/${v}.xml`]=w}async _processWorksheetRelsEntry(M,_,v){const x=new p,w=await x.parseStream(M);_.worksheetRels[v]=w}async _processMediaEntry(M,_,v){const x=v.lastIndexOf(".");if(x>=1){const w=v.substr(x+1),S=v.substr(0,x);await new Promise((E,O)=>{const R=new u;R.on("finish",()=>{_.mediaIndex[v]=_.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,_,v){const x=new q,w=await x.parseStream(M);_.drawings[v]=w}async _processDrawingRelsEntry(M,_,v){const x=new p,w=await x.parseStream(M);_.drawingRels[v]=w}async _processVmlDrawingEntry(M,_,v){const x=new V,w=await x.parseStream(M);_.vmlDrawings[`../drawings/${v}.vml`]=w}async _processThemeEntry(M,_,v){await new Promise((x,w)=>{const S=new u;M.on("error",w),S.on("error",w),S.on("finish",()=>{_.themes[v]=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 v=[];for await(const x of M)v.push(x);return this.load(o.concat(v),_)}async load(M,_){let v;v=_&&_.base64?o.from(M.toString(),"base64"):M;const x={worksheets:[],worksheetHash:{},worksheetRels:[],themes:{},media:[],mediaIndex:{},drawings:{},drawingRels:{},comments:{},tables:{},vmlDrawings:{}},w=await n.loadAsync(v);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?d(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 f,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 v=>{if(v.type==="image"){const x=`xl/media/${v.name}.${v.extension}`;if(v.filename){const w=await function(S,E){return new Promise((O,R)=>{s.readFile(S,E,(z,U)=>{z?R(z):O(U)})})}(v.filename);return M.append(w,{name:x})}if(v.buffer)return M.append(v.buffer,{name:x});if(v.base64){const w=v.base64,S=w.substring(w.indexOf(",")+1);return M.append(S,{name:x,base64:!0})}}throw new Error("Unsupported media")}))}addDrawings(M,_){const v=new q,x=new p;_.worksheets.forEach(w=>{const{drawing:S}=w;if(S){v.prepare(S,{});let E=v.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 v=new P;_.worksheets.forEach(x=>{const{tables:w}=x;w.forEach(S=>{v.prepare(S,{});const E=v.toXml(S);M.append(E,{name:"xl/tables/"+S.target})})})}async addContentTypes(M,_){const v=new k().toXml(_);M.append(v,{name:"[Content_Types].xml"})}async addApp(M,_){const v=new C().toXml(_);M.append(v,{name:"docProps/app.xml"})}async addCore(M,_){const v=new f;M.append(v.toXml(_),{name:"docProps/core.xml"})}async addThemes(M,_){const v=_.themes||{theme1:W};Object.keys(v).forEach(x=>{const w=v[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 v=1;const x=[{Id:"rId"+v++,Type:L.RelType.Styles,Target:"styles.xml"},{Id:"rId"+v++,Type:L.RelType.Theme,Target:"theme/theme1.xml"}];_.sharedStrings.count&&x.push({Id:"rId"+v++,Type:L.RelType.SharedStrings,Target:"sharedStrings.xml"}),_.worksheets.forEach(S=>{S.rId="rId"+v++,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:v}=_.styles;v&&M.append(v,{name:"xl/styles.xml"})}async addWorkbook(M,_){const v=new T;M.append(v.toXml(_),{name:"xl/workbook.xml"})}async addWorksheets(M,_){const v=new j,x=new p,w=new N,S=new V;_.worksheets.forEach(E=>{let O=new i;v.render(O,E),M.append(O.xml,{name:`xl/worksheets/sheet${E.id}.xml`}),E.rels&&E.rels.length&&(O=new i,x.render(O,E.rels),M.append(O.xml,{name:`xl/worksheets/_rels/sheet${E.id}.xml.rels`})),E.comments.length>0&&(O=new i,w.render(O,E),M.append(O.xml,{name:`xl/comments${E.id}.xml`}),O=new i,S.render(O,E),M.append(O.xml,{name:`xl/drawings/vmlDrawing${E.id}.vml`}))})}_finalize(M){return new Promise((_,v)=>{M.on("finish",()=>{_(this)}),M.on("error",v),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 v=new T,x=new j;v.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:v}=this.workbook,x=new r.ZipWriter(_.zip);return x.pipe(M),this.prepareModel(v,_),await this.addContentTypes(x,v),await this.addOfficeRels(x,v),await this.addWorkbookRels(x,v),await this.addWorksheets(x,v),await this.addSharedStrings(x,v),await this.addDrawings(x,v),await this.addTables(x,v),await Promise.all([this.addThemes(x,v),this.addStyles(x,v)]),await this.addMedia(x,v),await Promise.all([this.addApp(x,v),this.addCore(x,v)]),await this.addWorkbook(x,v),this._finalize(x)}writeFile(M,_){const v=s.createWriteStream(M);return new Promise((x,w)=>{v.on("finish",()=>{x()}),v.on("error",S=>{w(S)}),this.write(v,_).then(()=>{v.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 o=t("stream"),s=t("./formatter");class n extends o.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 i=!1;try{this.hasWrittenBOM||(this.push(this.formatterOptions.BOM),this.hasWrittenBOM=!0),this.rowFormatter.format(r,(d,h)=>d?(i=!0,a(d)):(h&&h.forEach(f=>{this.push(c.from(f,"utf8"))}),i=!0,a()))}catch(d){if(i)throw d;a(d)}}_flush(r){this.rowFormatter.finish((u,a)=>u?r(u):(a&&a.forEach(i=>{this.push(c.from(i,"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 o;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&&((o=c.writeHeaders)===null||o===void 0||o),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 o=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|
|