UNPKG

v-toggle-theme

Version:

A Vue 3 and Vuetify 3 compatible component that automatically switches between light and dark themes based on sunrise and sunset times. Includes manual override capabilities and full support for SSR and geolocation.

2 lines 68.5 kB
(function(r,j){typeof exports=="object"&&typeof module<"u"?module.exports=j(require("vue"),require("sunrise-sunset-js"),require("vuetify")):typeof define=="function"&&define.amd?define(["vue","sunrise-sunset-js","vuetify"],j):(r=typeof globalThis<"u"?globalThis:r||self,r.VToggleTheme=j(r.Vue,r.sunriseSunsetJs,r.Vuetify))})(this,function(r,j,bn){"use strict";var wn="M17.75,4.09L15.22,6.03L16.13,9.09L13.5,7.28L10.87,9.09L11.78,6.03L9.25,4.09L12.44,4L13.5,1L14.56,4L17.75,4.09M21.25,11L19.61,12.25L20.2,14.23L18.5,13.06L16.8,14.23L17.39,12.25L15.75,11L17.81,10.95L18.5,9L19.19,10.95L21.25,11M18.97,15.95C19.8,15.87 20.69,17.05 20.16,17.8C19.84,18.25 19.5,18.67 19.08,19.07C15.17,23 8.84,23 4.94,19.07C1.03,15.17 1.03,8.83 4.94,4.93C5.34,4.53 5.76,4.17 6.21,3.85C6.96,3.32 8.14,4.21 8.06,5.04C7.79,7.9 8.75,10.87 10.95,13.06C13.14,15.26 16.1,16.22 18.97,15.95M17.33,17.97C14.5,17.81 11.7,16.64 9.53,14.5C7.36,12.31 6.2,9.5 6.04,6.68C3.23,9.82 3.34,14.64 6.35,17.66C9.37,20.67 14.19,20.78 17.33,17.97Z",Cn="M12,7A5,5 0 0,1 17,12A5,5 0 0,1 12,17A5,5 0 0,1 7,12A5,5 0 0,1 12,7M12,9A3,3 0 0,0 9,12A3,3 0 0,0 12,15A3,3 0 0,0 15,12A3,3 0 0,0 12,9M12,2L14.39,5.42C13.65,5.15 12.84,5 12,5C11.16,5 10.35,5.15 9.61,5.42L12,2M3.34,7L7.5,6.65C6.9,7.16 6.36,7.78 5.94,8.5C5.5,9.24 5.25,10 5.11,10.79L3.34,7M3.36,17L5.12,13.23C5.26,14 5.53,14.78 5.95,15.5C6.37,16.24 6.91,16.86 7.5,17.37L3.36,17M20.65,7L18.88,10.79C18.74,10 18.47,9.23 18.05,8.5C17.63,7.78 17.1,7.15 16.5,6.64L20.65,7M20.64,17L16.5,17.36C17.09,16.85 17.62,16.22 18.04,15.5C18.46,14.77 18.73,14 18.87,13.21L20.64,17M12,22L9.59,18.56C10.33,18.83 11.14,19 12,19C12.82,19 13.63,18.83 14.37,18.56L12,22Z";const D=typeof window<"u",Sn=D&&"IntersectionObserver"in window;function Le(e,t){if(e===t)return!0;if(e instanceof Date&&t instanceof Date&&e.getTime()!==t.getTime()||e!==Object(e)||t!==Object(t))return!1;const n=Object.keys(e);return n.length!==Object.keys(t).length?!1:n.every(o=>Le(e[o],t[o]))}function L(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"px";if(!(e==null||e===""))return isNaN(+e)?String(e):isFinite(+e)?`${Number(e)}${t}`:void 0}function xn(e){return e!==null&&typeof e=="object"&&!Array.isArray(e)}function et(e){let t;return e!==null&&typeof e=="object"&&((t=Object.getPrototypeOf(e))===Object.prototype||t===null)}function kn(e){if(e&&"$el"in e){const t=e.$el;return(t==null?void 0:t.nodeType)===Node.TEXT_NODE?t.nextElementSibling:t}return e}const tt=Object.freeze({enter:13,tab:9,delete:46,esc:27,space:32,up:38,down:40,left:37,right:39,end:35,home:36,del:46,backspace:8,insert:45,pageup:33,pagedown:34,shift:16});function Oe(e,t){return t.every(n=>e.hasOwnProperty(n))}function En(e,t){const n={},o=new Set(Object.keys(e));for(const i of t)o.has(i)&&(n[i]=e[i]);return n}function Pn(e,t){const n={...e};return t.forEach(o=>delete n[o]),n}const Tn=/^on[^a-z]/,nt=e=>Tn.test(e);function Ln(e){return e==null?[]:Array.isArray(e)?e:[e]}function ot(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:1;return Math.max(t,Math.min(n,e))}function rt(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:"0";return e+n.repeat(Math.max(0,t-e.length))}function On(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:1;const n=[];let o=0;for(;o<e.length;)n.push(e.substr(o,t)),o+=t;return n}function Y(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:{},n=arguments.length>2?arguments[2]:void 0;const o={};for(const i in e)o[i]=e[i];for(const i in t){const a=e[i],s=t[i];if(et(a)&&et(s)){o[i]=Y(a,s,n);continue}if(n&&Array.isArray(a)&&Array.isArray(s)){o[i]=n(a,s);continue}o[i]=s}return o}function it(e){return e.map(t=>t.type===r.Fragment?it(t.children):t).flat()}function G(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"";if(G.cache.has(e))return G.cache.get(e);const t=e.replace(/[^a-z]/gi,"-").replace(/\B([A-Z])/g,"-$1").toLowerCase();return G.cache.set(e,t),t}G.cache=new Map;function ee(e,t){if(!t||typeof t!="object")return[];if(Array.isArray(t))return t.map(n=>ee(e,n)).flat(1);if(t.suspense)return ee(e,t.ssContent);if(Array.isArray(t.children))return t.children.map(n=>ee(e,n)).flat(1);if(t.component){if(Object.getOwnPropertySymbols(t.component.provides).includes(e))return[t.component];if(t.component.subTree)return ee(e,t.component.subTree).flat(1)}return[]}function Ve(e){const t=r.reactive({}),n=r.computed(e);return r.watchEffect(()=>{for(const o in n.value)t[o]=n.value[o]},{flush:"sync"}),r.toRefs(t)}function fe(e,t){return e.includes(t)}function at(e){return e[2].toLowerCase()+e.slice(3)}function st(e,t){return t="on"+r.capitalize(t),!!(e[t]||e[`${t}Once`]||e[`${t}Capture`]||e[`${t}OnceCapture`]||e[`${t}CaptureOnce`])}function Vn(e,t){if(!(D&&typeof CSS<"u"&&typeof CSS.supports<"u"&&CSS.supports(`selector(${t})`)))return null;try{return!!e&&e.matches(t)}catch{return null}}function Nn(e,t){if(!D||e===0)return t(),()=>{};const n=window.setTimeout(t,e);return()=>window.clearTimeout(n)}function Ne(){const e=r.shallowRef(),t=n=>{e.value=n};return Object.defineProperty(t,"value",{enumerable:!0,get:()=>e.value,set:n=>e.value=n}),Object.defineProperty(t,"el",{enumerable:!0,get:()=>kn(e.value)}),t}const lt=["top","bottom"],Rn=["start","end","left","right"];function Re(e,t){let[n,o]=e.split(" ");return o||(o=fe(lt,n)?"start":fe(Rn,n)?"top":"center"),{side:ct(n,t),align:ct(o,t)}}function ct(e,t){return e==="start"?t?"right":"left":e==="end"?t?"left":"right":e}function _e(e){return{side:{center:"center",top:"bottom",bottom:"top",left:"right",right:"left"}[e.side],align:e.align}}function Ae(e){return{side:e.side,align:{center:"center",top:"bottom",bottom:"top",left:"right",right:"left"}[e.align]}}function ut(e){return{side:e.align,align:e.side}}function ft(e){return fe(lt,e.side)?"y":"x"}class q{constructor(t){let{x:n,y:o,width:i,height:a}=t;this.x=n,this.y=o,this.width=i,this.height=a}get top(){return this.y}get bottom(){return this.y+this.height}get left(){return this.x}get right(){return this.x+this.width}}function dt(e,t){return{x:{before:Math.max(0,t.left-e.left),after:Math.max(0,e.right-t.right)},y:{before:Math.max(0,t.top-e.top),after:Math.max(0,e.bottom-t.bottom)}}}function _n(e){return Array.isArray(e)?new q({x:e[0],y:e[1],width:0,height:0}):e.getBoundingClientRect()}function An(e){const t=e.getBoundingClientRect(),n=getComputedStyle(e),o=n.transform;if(o){let i,a,s,l,c;if(o.startsWith("matrix3d("))i=o.slice(9,-1).split(/, /),a=+i[0],s=+i[5],l=+i[12],c=+i[13];else if(o.startsWith("matrix("))i=o.slice(7,-1).split(/, /),a=+i[0],s=+i[3],l=+i[4],c=+i[5];else return new q(t);const u=n.transformOrigin,f=t.x-l-(1-a)*parseFloat(u),g=t.y-c-(1-s)*parseFloat(u.slice(u.indexOf(" ")+1)),m=a?t.width/a:e.offsetWidth+1,v=s?t.height/s:e.offsetHeight+1;return new q({x:f,y:g,width:m,height:v})}else return new q(t)}function Bn(e,t,n){if(typeof e.animate>"u")return{finished:Promise.resolve()};let o;try{o=e.animate(t,n)}catch{return{finished:Promise.resolve()}}return typeof o.finished>"u"&&(o.finished=new Promise(i=>{o.onfinish=()=>{i(o)}})),o}const de=new WeakMap;function In(e,t){Object.keys(t).forEach(n=>{if(nt(n)){const o=at(n),i=de.get(e);if(t[n]==null)i==null||i.forEach(a=>{const[s,l]=a;s===o&&(e.removeEventListener(o,l),i.delete(a))});else if(!i||![...i].some(a=>a[0]===o&&a[1]===t[n])){e.addEventListener(o,t[n]);const a=i||new Set;a.add([o,t[n]]),de.has(e)||de.set(e,a)}}else t[n]==null?e.removeAttribute(n):e.setAttribute(n,t[n])})}function Mn(e,t){Object.keys(t).forEach(n=>{if(nt(n)){const o=at(n),i=de.get(e);i==null||i.forEach(a=>{const[s,l]=a;s===o&&(e.removeEventListener(o,l),i.delete(a))})}else e.removeAttribute(n)})}const X=2.4,mt=.2126729,gt=.7151522,ht=.072175,$n=.55,Dn=.58,Fn=.57,jn=.62,me=.03,vt=1.45,Wn=5e-4,zn=1.25,Hn=1.25,yt=.078,pt=12.82051282051282,ge=.06,bt=.001;function wt(e,t){const n=(e.r/255)**X,o=(e.g/255)**X,i=(e.b/255)**X,a=(t.r/255)**X,s=(t.g/255)**X,l=(t.b/255)**X;let c=n*mt+o*gt+i*ht,u=a*mt+s*gt+l*ht;if(c<=me&&(c+=(me-c)**vt),u<=me&&(u+=(me-u)**vt),Math.abs(u-c)<Wn)return 0;let f;if(u>c){const g=(u**$n-c**Dn)*zn;f=g<bt?0:g<yt?g-g*pt*ge:g-ge}else{const g=(u**jn-c**Fn)*Hn;f=g>-bt?0:g>-yt?g-g*pt*ge:g+ge}return f*100}function K(e){r.warn(`Vuetify: ${e}`)}function Gn(e){r.warn(`Vuetify error: ${e}`)}function Be(e){return!!e&&/^(#|var\(--|(rgb|hsl)a?\()/.test(e)}function qn(e){return Be(e)&&!/^((rgb|hsl)a?\()?var\(--/.test(e)}const Ct=/^(?<fn>(?:rgb|hsl)a?)\((?<values>.+)\)/,Un={rgb:(e,t,n,o)=>({r:e,g:t,b:n,a:o}),rgba:(e,t,n,o)=>({r:e,g:t,b:n,a:o}),hsl:(e,t,n,o)=>St({h:e,s:t,l:n,a:o}),hsla:(e,t,n,o)=>St({h:e,s:t,l:n,a:o}),hsv:(e,t,n,o)=>ne({h:e,s:t,v:n,a:o}),hsva:(e,t,n,o)=>ne({h:e,s:t,v:n,a:o})};function te(e){if(typeof e=="number")return(isNaN(e)||e<0||e>16777215)&&K(`'${e}' is not a valid hex color`),{r:(e&16711680)>>16,g:(e&65280)>>8,b:e&255};if(typeof e=="string"&&Ct.test(e)){const{groups:t}=e.match(Ct),{fn:n,values:o}=t,i=o.split(/,\s*/).map(a=>a.endsWith("%")&&["hsl","hsla","hsv","hsva"].includes(n)?parseFloat(a)/100:parseFloat(a));return Un[n](...i)}else if(typeof e=="string"){let t=e.startsWith("#")?e.slice(1):e;[3,4].includes(t.length)?t=t.split("").map(o=>o+o).join(""):[6,8].includes(t.length)||K(`'${e}' is not a valid hex(a) color`);const n=parseInt(t,16);return(isNaN(n)||n<0||n>4294967295)&&K(`'${e}' is not a valid hex(a) color`),Yn(t)}else if(typeof e=="object"){if(Oe(e,["r","g","b"]))return e;if(Oe(e,["h","s","l"]))return ne(xt(e));if(Oe(e,["h","s","v"]))return ne(e)}throw new TypeError(`Invalid color: ${e==null?e:String(e)||e.constructor.name} Expected #hex, #hexa, rgb(), rgba(), hsl(), hsla(), object or number`)}function ne(e){const{h:t,s:n,v:o,a:i}=e,a=l=>{const c=(l+t/60)%6;return o-o*n*Math.max(Math.min(c,4-c,1),0)},s=[a(5),a(3),a(1)].map(l=>Math.round(l*255));return{r:s[0],g:s[1],b:s[2],a:i}}function St(e){return ne(xt(e))}function xt(e){const{h:t,s:n,l:o,a:i}=e,a=o+n*Math.min(o,1-o),s=a===0?0:2-2*o/a;return{h:t,s,v:a,a:i}}function Yn(e){e=Xn(e);let[t,n,o,i]=On(e,2).map(a=>parseInt(a,16));return i=i===void 0?i:i/255,{r:t,g:n,b:o,a:i}}function Xn(e){return e.startsWith("#")&&(e=e.slice(1)),e=e.replace(/([^0-9a-f])/gi,"F"),(e.length===3||e.length===4)&&(e=e.split("").map(t=>t+t).join("")),e.length!==6&&(e=rt(rt(e,6),8,"F")),e}function Kn(e){const t=Math.abs(wt(te(0),te(e)));return Math.abs(wt(te(16777215),te(e)))>Math.min(t,50)?"#fff":"#000"}function w(e,t){return n=>Object.keys(e).reduce((o,i)=>{const s=typeof e[i]=="object"&&e[i]!=null&&!Array.isArray(e[i])?e[i]:{type:e[i]};return n&&i in n?o[i]={...s,default:n[i]}:o[i]=s,t&&!o[i].source&&(o[i].source=t),o},{})}const oe=w({class:[String,Array,Object],style:{type:[String,Array,Object],default:null}},"component");function R(e,t){const n=r.getCurrentInstance();if(!n)throw new Error(`[Vuetify] ${e} must be called from inside a setup function`);return n}function z(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:"composables";const t=R(e).type;return G((t==null?void 0:t.aliasName)||(t==null?void 0:t.name))}let kt=0,he=new WeakMap;function Ie(){const e=R("getUid");if(he.has(e))return he.get(e);{const t=kt++;return he.set(e,t),t}}Ie.reset=()=>{kt=0,he=new WeakMap};function Zn(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:R("injectSelf");const{provides:n}=t;if(n&&e in n)return n[e]}const ve=Symbol.for("vuetify:defaults");function Me(){const e=r.inject(ve);if(!e)throw new Error("[Vuetify] Could not find defaults instance");return e}function Et(e,t){const n=Me(),o=r.ref(e),i=r.computed(()=>{if(r.unref(t==null?void 0:t.disabled))return n.value;const s=r.unref(t==null?void 0:t.scoped),l=r.unref(t==null?void 0:t.reset),c=r.unref(t==null?void 0:t.root);if(o.value==null&&!(s||l||c))return n.value;let u=Y(o.value,{prev:n.value});if(s)return u;if(l||c){const f=Number(l||1/0);for(let g=0;g<=f&&!(!u||!("prev"in u));g++)u=u.prev;return u&&typeof c=="string"&&c in u&&(u=Y(Y(u,{prev:u}),u[c])),u}return u.prev?Y(u.prev,u):u});return r.provide(ve,i),i}function Jn(e,t){var n,o;return typeof((n=e.props)==null?void 0:n[t])<"u"||typeof((o=e.props)==null?void 0:o[G(t)])<"u"}function Qn(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:{},t=arguments.length>1?arguments[1]:void 0,n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:Me();const o=R("useDefaults");if(t=t??o.type.name??o.type.__name,!t)throw new Error("[Vuetify] Could not determine component name");const i=r.computed(()=>{var c;return(c=n.value)==null?void 0:c[e._as??t]}),a=new Proxy(e,{get(c,u){var g,m,v,h,d,p,b;const f=Reflect.get(c,u);return u==="class"||u==="style"?[(g=i.value)==null?void 0:g[u],f].filter(S=>S!=null):typeof u=="string"&&!Jn(o.vnode,u)?((m=i.value)==null?void 0:m[u])!==void 0?(v=i.value)==null?void 0:v[u]:((d=(h=n.value)==null?void 0:h.global)==null?void 0:d[u])!==void 0?(b=(p=n.value)==null?void 0:p.global)==null?void 0:b[u]:f:f}}),s=r.shallowRef();r.watchEffect(()=>{if(i.value){const c=Object.entries(i.value).filter(u=>{let[f]=u;return f.startsWith(f[0].toUpperCase())});s.value=c.length?Object.fromEntries(c):void 0}else s.value=void 0});function l(){const c=Zn(ve,o);r.provide(ve,r.computed(()=>s.value?Y((c==null?void 0:c.value)??{},s.value):c==null?void 0:c.value))}return{props:a,provideSubDefaults:l}}function ye(e){if(e._setup=e._setup??e.setup,!e.name)return K("The component is missing an explicit name, unable to generate default prop value"),e;if(e._setup){e.props=w(e.props??{},e.name)();const t=Object.keys(e.props).filter(n=>n!=="class"&&n!=="style");e.filterProps=function(o){return En(o,t)},e.props._as=String,e.setup=function(o,i){const a=Me();if(!a.value)return e._setup(o,i);const{props:s,provideSubDefaults:l}=Qn(o,o._as??e.name,a),c=e._setup(s,i);return l(),c}}return e}function W(){let e=arguments.length>0&&arguments[0]!==void 0?arguments[0]:!0;return t=>(e?ye:r.defineComponent)(t)}function Pt(e){if(typeof e.getRootNode!="function"){for(;e.parentNode;)e=e.parentNode;return e!==document?null:document}const t=e.getRootNode();return t!==document&&t.getRootNode({composed:!0})!==document?null:t}const eo="cubic-bezier(0.4, 0, 0.2, 1)";function to(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1;for(;e;){if(t?no(e):$e(e))return e;e=e.parentElement}return document.scrollingElement}function pe(e,t){const n=[];if(t&&e&&!t.contains(e))return n;for(;e&&($e(e)&&n.push(e),e!==t);)e=e.parentElement;return n}function $e(e){if(!e||e.nodeType!==Node.ELEMENT_NODE)return!1;const t=window.getComputedStyle(e);return t.overflowY==="scroll"||t.overflowY==="auto"&&e.scrollHeight>e.clientHeight}function no(e){if(!e||e.nodeType!==Node.ELEMENT_NODE)return!1;const t=window.getComputedStyle(e);return["scroll","auto"].includes(t.overflowY)}function oo(e){for(;e;){if(window.getComputedStyle(e).position==="fixed")return!0;e=e.offsetParent}return!1}function U(e){const t=R("useRender");t.render=e}const Tt=w({border:[Boolean,Number,String]},"border");function Lt(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:z();return{borderClasses:r.computed(()=>{const o=r.isRef(e)?e.value:e.border,i=[];if(o===!0||o==="")i.push(`${t}--border`);else if(typeof o=="string"||o===0)for(const a of String(o).split(" "))i.push(`border-${a}`);return i})}}const ro=[null,"default","comfortable","compact"],Ot=w({density:{type:String,default:"default",validator:e=>ro.includes(e)}},"density");function Vt(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:z();return{densityClasses:r.computed(()=>`${t}--density-${e.density}`)}}const Nt=w({elevation:{type:[Number,String],validator(e){const t=parseInt(e);return!isNaN(t)&&t>=0&&t<=24}}},"elevation");function Rt(e){return{elevationClasses:r.computed(()=>{const n=r.isRef(e)?e.value:e.elevation,o=[];return n==null||o.push(`elevation-${n}`),o})}}const _t=w({rounded:{type:[Boolean,Number,String],default:void 0},tile:Boolean},"rounded");function At(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:z();return{roundedClasses:r.computed(()=>{const o=r.isRef(e)?e.value:e.rounded,i=r.isRef(e)?e.value:e.tile,a=[];if(o===!0||o==="")a.push(`${t}--rounded`);else if(typeof o=="string"||o===0)for(const s of String(o).split(" "))a.push(`rounded-${s}`);else(i||o===!1)&&a.push("rounded-0");return a})}}const be=w({tag:{type:String,default:"div"}},"tag"),Bt=Symbol.for("vuetify:theme"),re=w({theme:String},"theme");function ie(e){R("provideTheme");const t=r.inject(Bt,null);if(!t)throw new Error("Could not find Vuetify theme injection");const n=r.computed(()=>e.theme??t.name.value),o=r.computed(()=>t.themes.value[n.value]),i=r.computed(()=>t.isDisabled?void 0:`v-theme--${n.value}`),a={...t,name:n,current:o,themeClasses:i};return r.provide(Bt,a),a}function De(e){return Ve(()=>{const t=[],n={};if(e.value.background)if(Be(e.value.background)){if(n.backgroundColor=e.value.background,!e.value.text&&qn(e.value.background)){const o=te(e.value.background);if(o.a==null||o.a===1){const i=Kn(o);n.color=i,n.caretColor=i}}}else t.push(`bg-${e.value.background}`);return e.value.text&&(Be(e.value.text)?(n.color=e.value.text,n.caretColor=e.value.text):t.push(`text-${e.value.text}`)),{colorClasses:t,colorStyles:n}})}function Fe(e,t){const n=r.computed(()=>({text:r.isRef(e)?e.value:null})),{colorClasses:o,colorStyles:i}=De(n);return{textColorClasses:o,textColorStyles:i}}function io(e,t){const n=r.computed(()=>({background:r.isRef(e)?e.value:null})),{colorClasses:o,colorStyles:i}=De(n);return{backgroundColorClasses:o,backgroundColorStyles:i}}const ao=["elevated","flat","tonal","outlined","text","plain"];function so(e,t){return r.createVNode(r.Fragment,null,[r.createVNode("span",{key:"overlay",class:`${t}__overlay`},null),r.createVNode("span",{key:"underlay",class:`${t}__underlay`},null)])}const It=w({color:String,variant:{type:String,default:"elevated",validator:e=>ao.includes(e)}},"variant");function lo(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:z();const n=r.computed(()=>{const{variant:a}=r.unref(e);return`${t}--variant-${a}`}),{colorClasses:o,colorStyles:i}=De(r.computed(()=>{const{variant:a,color:s}=r.unref(e);return{[["elevated","flat"].includes(a)?"background":"text"]:s}}));return{colorClasses:o,colorStyles:i,variantClasses:n}}const Mt=w({baseColor:String,divided:Boolean,...Tt(),...oe(),...Ot(),...Nt(),..._t(),...be(),...re(),...It()},"VBtnGroup"),$t=W()({name:"VBtnGroup",props:Mt(),setup(e,t){let{slots:n}=t;const{themeClasses:o}=ie(e),{densityClasses:i}=Vt(e),{borderClasses:a}=Lt(e),{elevationClasses:s}=Rt(e),{roundedClasses:l}=At(e);Et({VBtn:{height:"auto",baseColor:r.toRef(e,"baseColor"),color:r.toRef(e,"color"),density:r.toRef(e,"density"),flat:!0,variant:r.toRef(e,"variant")}}),U(()=>r.createVNode(e.tag,{class:["v-btn-group",{"v-btn-group--divided":e.divided},o.value,a.value,i.value,s.value,l.value,e.class],style:e.style},n))}});function we(e,t){let n;function o(){n=r.effectScope(),n.run(()=>t.length?t(()=>{n==null||n.stop(),o()}):t())}r.watch(e,i=>{i&&!n?o():i||(n==null||n.stop(),n=void 0)},{immediate:!0}),r.onScopeDispose(()=>{n==null||n.stop()})}function je(e,t,n){let o=arguments.length>3&&arguments[3]!==void 0?arguments[3]:g=>g,i=arguments.length>4&&arguments[4]!==void 0?arguments[4]:g=>g;const a=R("useProxiedModel"),s=r.ref(e[t]!==void 0?e[t]:n),l=G(t),u=l!==t?r.computed(()=>{var g,m,v,h;return e[t],!!(((g=a.vnode.props)!=null&&g.hasOwnProperty(t)||(m=a.vnode.props)!=null&&m.hasOwnProperty(l))&&((v=a.vnode.props)!=null&&v.hasOwnProperty(`onUpdate:${t}`)||(h=a.vnode.props)!=null&&h.hasOwnProperty(`onUpdate:${l}`)))}):r.computed(()=>{var g,m;return e[t],!!((g=a.vnode.props)!=null&&g.hasOwnProperty(t)&&((m=a.vnode.props)!=null&&m.hasOwnProperty(`onUpdate:${t}`)))});we(()=>!u.value,()=>{r.watch(()=>e[t],g=>{s.value=g})});const f=r.computed({get(){const g=e[t];return o(u.value?g:s.value)},set(g){const m=i(g),v=r.toRaw(u.value?e[t]:s.value);v===m||o(v)===g||(s.value=m,a==null||a.emit(`update:${t}`,m))}});return Object.defineProperty(f,"externalValue",{get:()=>u.value?e[t]:s.value}),f}const co=w({modelValue:{type:null,default:void 0},multiple:Boolean,mandatory:[Boolean,String],max:Number,selectedClass:String,disabled:Boolean},"group"),uo=w({value:null,disabled:Boolean,selectedClass:String},"group-item");function fo(e,t){let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:!0;const o=R("useGroupItem");if(!o)throw new Error("[Vuetify] useGroupItem composable must be used inside a component setup function");const i=Ie();r.provide(Symbol.for(`${t.description}:id`),i);const a=r.inject(t,null);if(!a){if(!n)return a;throw new Error(`[Vuetify] Could not find useGroup injection with symbol ${t.description}`)}const s=r.toRef(e,"value"),l=r.computed(()=>!!(a.disabled.value||e.disabled));a.register({id:i,value:s,disabled:l},o),r.onBeforeUnmount(()=>{a.unregister(i)});const c=r.computed(()=>a.isSelected(i)),u=r.computed(()=>a.items.value[0].id===i),f=r.computed(()=>a.items.value[a.items.value.length-1].id===i),g=r.computed(()=>c.value&&[a.selectedClass.value,e.selectedClass]);return r.watch(c,m=>{o.emit("group:selected",{value:m})},{flush:"sync"}),{id:i,isSelected:c,isFirst:u,isLast:f,toggle:()=>a.select(i,!c.value),select:m=>a.select(i,m),selectedClass:g,value:s,disabled:l,group:a}}function mo(e,t){let n=!1;const o=r.reactive([]),i=je(e,"modelValue",[],m=>m==null?[]:Dt(o,Ln(m)),m=>{const v=ho(o,m);return e.multiple?v:v[0]}),a=R("useGroup");function s(m,v){const h=m,d=Symbol.for(`${t.description}:id`),b=ee(d,a==null?void 0:a.vnode).indexOf(v);r.unref(h.value)==null&&(h.value=b,h.useIndexAsValue=!0),b>-1?o.splice(b,0,h):o.push(h)}function l(m){if(n)return;c();const v=o.findIndex(h=>h.id===m);o.splice(v,1)}function c(){const m=o.find(v=>!v.disabled);m&&e.mandatory==="force"&&!i.value.length&&(i.value=[m.id])}r.onMounted(()=>{c()}),r.onBeforeUnmount(()=>{n=!0}),r.onUpdated(()=>{for(let m=0;m<o.length;m++)o[m].useIndexAsValue&&(o[m].value=m)});function u(m,v){const h=o.find(d=>d.id===m);if(!(v&&(h!=null&&h.disabled)))if(e.multiple){const d=i.value.slice(),p=d.findIndex(S=>S===m),b=~p;if(v=v??!b,b&&e.mandatory&&d.length<=1||!b&&e.max!=null&&d.length+1>e.max)return;p<0&&v?d.push(m):p>=0&&!v&&d.splice(p,1),i.value=d}else{const d=i.value.includes(m);if(e.mandatory&&d)return;i.value=v??!d?[m]:[]}}function f(m){if(e.multiple&&K('This method is not supported when using "multiple" prop'),i.value.length){const v=i.value[0],h=o.findIndex(b=>b.id===v);let d=(h+m)%o.length,p=o[d];for(;p.disabled&&d!==h;)d=(d+m)%o.length,p=o[d];if(p.disabled)return;i.value=[o[d].id]}else{const v=o.find(h=>!h.disabled);v&&(i.value=[v.id])}}const g={register:s,unregister:l,selected:i,select:u,disabled:r.toRef(e,"disabled"),prev:()=>f(o.length-1),next:()=>f(1),isSelected:m=>i.value.includes(m),selectedClass:r.computed(()=>e.selectedClass),items:r.computed(()=>o),getItemIndex:m=>go(o,m)};return r.provide(t,g),g}function go(e,t){const n=Dt(e,[t]);return n.length?e.findIndex(o=>o.id===n[0]):-1}function Dt(e,t){const n=[];return t.forEach(o=>{const i=e.find(s=>Le(o,s.value)),a=e[o];(i==null?void 0:i.value)!=null?n.push(i.id):a!=null&&n.push(a.id)}),n}function ho(e,t){const n=[];return t.forEach(o=>{const i=e.findIndex(a=>a.id===o);if(~i){const a=e[i];n.push(a.value!=null?a.value:i)}}),n}const Ft=Symbol.for("vuetify:v-btn-toggle"),vo=w({...Mt(),...co()},"VBtnToggle");W()({name:"VBtnToggle",props:vo(),emits:{"update:modelValue":e=>!0},setup(e,t){let{slots:n}=t;const{isSelected:o,next:i,prev:a,select:s,selected:l}=mo(e,Ft);return U(()=>{const c=$t.filterProps(e);return r.createVNode($t,r.mergeProps({class:["v-btn-toggle",e.class]},c,{style:e.style}),{default:()=>{var u;return[(u=n.default)==null?void 0:u.call(n,{isSelected:o,next:i,prev:a,select:s,selected:l})]}})}),{next:i,prev:a,select:s}}});const yo=w({defaults:Object,disabled:Boolean,reset:[Number,String],root:[Boolean,String],scoped:Boolean},"VDefaultsProvider"),We=W(!1)({name:"VDefaultsProvider",props:yo(),setup(e,t){let{slots:n}=t;const{defaults:o,disabled:i,reset:a,root:s,scoped:l}=r.toRefs(e);return Et(o,{reset:a,root:s,scoped:l,disabled:i}),()=>{var c;return(c=n.default)==null?void 0:c.call(n)}}}),Ce=[String,Function,Object,Array],po=Symbol.for("vuetify:icons"),Se=w({icon:{type:Ce},tag:{type:String,required:!0}},"icon"),jt=W()({name:"VComponentIcon",props:Se(),setup(e,t){let{slots:n}=t;return()=>{const o=e.icon;return r.createVNode(e.tag,null,{default:()=>{var i;return[e.icon?r.createVNode(o,null,null):(i=n.default)==null?void 0:i.call(n)]}})}}}),bo=ye({name:"VSvgIcon",inheritAttrs:!1,props:Se(),setup(e,t){let{attrs:n}=t;return()=>r.createVNode(e.tag,r.mergeProps(n,{style:null}),{default:()=>[r.createVNode("svg",{class:"v-icon__svg",xmlns:"http://www.w3.org/2000/svg",viewBox:"0 0 24 24",role:"img","aria-hidden":"true"},[Array.isArray(e.icon)?e.icon.map(o=>Array.isArray(o)?r.createVNode("path",{d:o[0],"fill-opacity":o[1]},null):r.createVNode("path",{d:o},null)):r.createVNode("path",{d:e.icon},null)])]})}});ye({name:"VLigatureIcon",props:Se(),setup(e){return()=>r.createVNode(e.tag,null,{default:()=>[e.icon]})}}),ye({name:"VClassIcon",props:Se(),setup(e){return()=>r.createVNode(e.tag,{class:e.icon},null)}});const wo=e=>{const t=r.inject(po);if(!t)throw new Error("Missing Vuetify Icons provide!");return{iconData:r.computed(()=>{var c;const o=r.unref(e);if(!o)return{component:jt};let i=o;if(typeof i=="string"&&(i=i.trim(),i.startsWith("$")&&(i=(c=t.aliases)==null?void 0:c[i.slice(1)])),i||K(`Could not find aliased icon "${o}"`),Array.isArray(i))return{component:bo,icon:i};if(typeof i!="string")return{component:jt,icon:i};const a=Object.keys(t.sets).find(u=>typeof i=="string"&&i.startsWith(`${u}:`)),s=a?i.slice(a.length+1):i;return{component:t.sets[a??t.defaultSet].component,icon:s}})}},Co=["x-small","small","default","large","x-large"],ze=w({size:{type:[String,Number],default:"default"}},"size");function He(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:z();return Ve(()=>{let n,o;return fe(Co,e.size)?n=`${t}--size-${e.size}`:e.size&&(o={width:L(e.size),height:L(e.size)}),{sizeClasses:n,sizeStyles:o}})}const So=w({color:String,disabled:Boolean,start:Boolean,end:Boolean,icon:Ce,...oe(),...ze(),...be({tag:"i"}),...re()},"VIcon"),xe=W()({name:"VIcon",props:So(),setup(e,t){let{attrs:n,slots:o}=t;const i=r.ref(),{themeClasses:a}=ie(e),{iconData:s}=wo(r.computed(()=>i.value||e.icon)),{sizeClasses:l}=He(e),{textColorClasses:c,textColorStyles:u}=Fe(r.toRef(e,"color"));return U(()=>{var m,v;const f=(m=o.default)==null?void 0:m.call(o);f&&(i.value=(v=it(f).filter(h=>h.type===r.Text&&h.children&&typeof h.children=="string")[0])==null?void 0:v.children);const g=!!(n.onClick||n.onClickOnce);return r.createVNode(s.value.component,{tag:e.tag,icon:s.value.icon,class:["v-icon","notranslate",a.value,l.value,c.value,{"v-icon--clickable":g,"v-icon--disabled":e.disabled,"v-icon--start":e.start,"v-icon--end":e.end},e.class],style:[l.value?void 0:{fontSize:L(e.size),height:L(e.size),width:L(e.size)},u.value,e.style],role:g?"button":void 0,"aria-hidden":!g,tabindex:g?e.disabled?-1:0:void 0},{default:()=>[f]})}),{}}});function xo(e,t){const n=r.ref(),o=r.shallowRef(!1);if(Sn){const i=new IntersectionObserver(a=>{o.value=!!a.find(s=>s.isIntersecting)},t);r.onBeforeUnmount(()=>{i.disconnect()}),r.watch(n,(a,s)=>{s&&(i.unobserve(s),o.value=!1),a&&i.observe(a)},{flush:"post"})}return{intersectionRef:n,isIntersecting:o}}function ko(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:"content";const n=Ne(),o=r.ref();if(D){const i=new ResizeObserver(a=>{a.length&&(t==="content"?o.value=a[0].contentRect:o.value=a[0].target.getBoundingClientRect())});r.onBeforeUnmount(()=>{i.disconnect()}),r.watch(()=>n.el,(a,s)=>{s&&(i.unobserve(s),o.value=void 0),a&&i.observe(a)},{flush:"post"})}return{resizeRef:n,contentRect:r.readonly(o)}}const Eo=w({bgColor:String,color:String,indeterminate:[Boolean,String],modelValue:{type:[Number,String],default:0},rotate:{type:[Number,String],default:0},width:{type:[Number,String],default:4},...oe(),...ze(),...be({tag:"div"}),...re()},"VProgressCircular"),Po=W()({name:"VProgressCircular",props:Eo(),setup(e,t){let{slots:n}=t;const o=20,i=2*Math.PI*o,a=r.ref(),{themeClasses:s}=ie(e),{sizeClasses:l,sizeStyles:c}=He(e),{textColorClasses:u,textColorStyles:f}=Fe(r.toRef(e,"color")),{textColorClasses:g,textColorStyles:m}=Fe(r.toRef(e,"bgColor")),{intersectionRef:v,isIntersecting:h}=xo(),{resizeRef:d,contentRect:p}=ko(),b=r.computed(()=>Math.max(0,Math.min(100,parseFloat(e.modelValue)))),S=r.computed(()=>Number(e.width)),E=r.computed(()=>c.value?Number(e.size):p.value?p.value.width:Math.max(S.value,32)),V=r.computed(()=>o/(1-S.value/E.value)*2),N=r.computed(()=>S.value/E.value*V.value),_=r.computed(()=>L((100-b.value)/100*i));return r.watchEffect(()=>{v.value=a.value,d.value=a.value}),U(()=>r.createVNode(e.tag,{ref:a,class:["v-progress-circular",{"v-progress-circular--indeterminate":!!e.indeterminate,"v-progress-circular--visible":h.value,"v-progress-circular--disable-shrink":e.indeterminate==="disable-shrink"},s.value,l.value,u.value,e.class],style:[c.value,f.value,e.style],role:"progressbar","aria-valuemin":"0","aria-valuemax":"100","aria-valuenow":e.indeterminate?void 0:b.value},{default:()=>[r.createVNode("svg",{style:{transform:`rotate(calc(-90deg + ${Number(e.rotate)}deg))`},xmlns:"http://www.w3.org/2000/svg",viewBox:`0 0 ${V.value} ${V.value}`},[r.createVNode("circle",{class:["v-progress-circular__underlay",g.value],style:m.value,fill:"transparent",cx:"50%",cy:"50%",r:o,"stroke-width":N.value,"stroke-dasharray":i,"stroke-dashoffset":0},null),r.createVNode("circle",{class:"v-progress-circular__overlay",fill:"transparent",cx:"50%",cy:"50%",r:o,"stroke-width":N.value,"stroke-dasharray":i,"stroke-dashoffset":_.value},null)]),n.default&&r.createVNode("div",{class:"v-progress-circular__content"},[n.default({value:b.value})])]})),{}}}),Wt=w({height:[Number,String],maxHeight:[Number,String],maxWidth:[Number,String],minHeight:[Number,String],minWidth:[Number,String],width:[Number,String]},"dimension");function zt(e){return{dimensionStyles:r.computed(()=>{const n={},o=L(e.height),i=L(e.maxHeight),a=L(e.maxWidth),s=L(e.minHeight),l=L(e.minWidth),c=L(e.width);return o!=null&&(n.height=o),i!=null&&(n.maxHeight=i),a!=null&&(n.maxWidth=a),s!=null&&(n.minHeight=s),l!=null&&(n.minWidth=l),c!=null&&(n.width=c),n})}}const To=Symbol.for("vuetify:locale");function Ht(){const e=r.inject(To);if(!e)throw new Error("[Vuetify] Could not find injected rtl instance");return{isRtl:e.isRtl,rtlClasses:e.rtlClasses}}const Gt={center:"center",top:"bottom",bottom:"top",left:"right",right:"left"},Lo=w({location:String},"location");function Oo(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:!1,n=arguments.length>2?arguments[2]:void 0;const{isRtl:o}=Ht();return{locationStyles:r.computed(()=>{if(!e.location)return{};const{side:a,align:s}=Re(e.location.split(" ").length>1?e.location:`${e.location} center`,o.value);function l(u){return n?n(u):0}const c={};return a!=="center"&&(t?c[Gt[a]]=`calc(100% - ${l(a)}px)`:c[a]=0),s!=="center"?t?c[Gt[s]]=`calc(100% - ${l(s)}px)`:c[s]=0:(a==="center"?c.top=c.left="50%":c[{top:"left",bottom:"left",left:"top",right:"top"}[a]]="50%",c.transform={top:"translateX(-50%)",bottom:"translateX(-50%)",left:"translateY(-50%)",right:"translateY(-50%)",center:"translate(-50%, -50%)"}[a]),c})}}const Vo=w({loading:[Boolean,String]},"loader");function No(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:z();return{loaderClasses:r.computed(()=>({[`${t}--loading`]:e.loading}))}}const Ro=["static","relative","fixed","absolute","sticky"],_o=w({position:{type:String,validator:e=>Ro.includes(e)}},"position");function Ao(e){let t=arguments.length>1&&arguments[1]!==void 0?arguments[1]:z();return{positionClasses:r.computed(()=>e.position?`${t}--${e.position}`:void 0)}}function Bo(){const e=R("useRoute");return r.computed(()=>{var t;return(t=e==null?void 0:e.proxy)==null?void 0:t.$route})}function Io(){var e,t;return(t=(e=R("useRouter"))==null?void 0:e.proxy)==null?void 0:t.$router}function Mo(e,t){var g,m;const n=r.resolveDynamicComponent("RouterLink"),o=r.computed(()=>!!(e.href||e.to)),i=r.computed(()=>(o==null?void 0:o.value)||st(t,"click")||st(e,"click"));if(typeof n=="string"||!("useLink"in n)){const v=r.toRef(e,"href");return{isLink:o,isClickable:i,href:v,linkProps:r.reactive({href:v})}}const a=r.computed(()=>({...e,to:r.toRef(()=>e.to||"")})),s=n.useLink(a.value),l=r.computed(()=>e.to?s:void 0),c=Bo(),u=r.computed(()=>{var v,h,d;return l.value?e.exact?c.value?((d=l.value.isExactActive)==null?void 0:d.value)&&Le(l.value.route.value.query,c.value.query):((h=l.value.isExactActive)==null?void 0:h.value)??!1:((v=l.value.isActive)==null?void 0:v.value)??!1:!1}),f=r.computed(()=>{var v;return e.to?(v=l.value)==null?void 0:v.route.value.href:e.href});return{isLink:o,isClickable:i,isActive:u,route:(g=l.value)==null?void 0:g.route,navigate:(m=l.value)==null?void 0:m.navigate,href:f,linkProps:r.reactive({href:f,"aria-current":r.computed(()=>u.value?"page":void 0)})}}const $o=w({href:String,replace:Boolean,to:[String,Object],exact:Boolean},"router");let Ge=!1;function Do(e,t){let n=!1,o,i;D&&(r.nextTick(()=>{window.addEventListener("popstate",a),o=e==null?void 0:e.beforeEach((s,l,c)=>{Ge?n?t(c):c():setTimeout(()=>n?t(c):c()),Ge=!0}),i=e==null?void 0:e.afterEach(()=>{Ge=!1})}),r.onScopeDispose(()=>{window.removeEventListener("popstate",a),o==null||o(),i==null||i()}));function a(s){var l;(l=s.state)!=null&&l.replaced||(n=!0,setTimeout(()=>n=!1))}}function Fo(e,t){r.watch(()=>{var n;return(n=e.isActive)==null?void 0:n.value},n=>{e.isLink.value&&n&&t&&r.nextTick(()=>{t(!0)})},{immediate:!0})}const qe=Symbol("rippleStop"),jo=80;function qt(e,t){e.style.transform=t,e.style.webkitTransform=t}function Ue(e){return e.constructor.name==="TouchEvent"}function Ut(e){return e.constructor.name==="KeyboardEvent"}const Wo=function(e,t){var g;let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{},o=0,i=0;if(!Ut(e)){const m=t.getBoundingClientRect(),v=Ue(e)?e.touches[e.touches.length-1]:e;o=v.clientX-m.left,i=v.clientY-m.top}let a=0,s=.3;(g=t._ripple)!=null&&g.circle?(s=.15,a=t.clientWidth/2,a=n.center?a:a+Math.sqrt((o-a)**2+(i-a)**2)/4):a=Math.sqrt(t.clientWidth**2+t.clientHeight**2)/2;const l=`${(t.clientWidth-a*2)/2}px`,c=`${(t.clientHeight-a*2)/2}px`,u=n.center?l:`${o-a}px`,f=n.center?c:`${i-a}px`;return{radius:a,scale:s,x:u,y:f,centerX:l,centerY:c}},ke={show(e,t){var v;let n=arguments.length>2&&arguments[2]!==void 0?arguments[2]:{};if(!((v=t==null?void 0:t._ripple)!=null&&v.enabled))return;const o=document.createElement("span"),i=document.createElement("span");o.appendChild(i),o.className="v-ripple__container",n.class&&(o.className+=` ${n.class}`);const{radius:a,scale:s,x:l,y:c,centerX:u,centerY:f}=Wo(e,t,n),g=`${a*2}px`;i.className="v-ripple__animation",i.style.width=g,i.style.height=g,t.appendChild(o);const m=window.getComputedStyle(t);m&&m.position==="static"&&(t.style.position="relative",t.dataset.previousPosition="static"),i.classList.add("v-ripple__animation--enter"),i.classList.add("v-ripple__animation--visible"),qt(i,`translate(${l}, ${c}) scale3d(${s},${s},${s})`),i.dataset.activated=String(performance.now()),setTimeout(()=>{i.classList.remove("v-ripple__animation--enter"),i.classList.add("v-ripple__animation--in"),qt(i,`translate(${u}, ${f}) scale3d(1,1,1)`)},0)},hide(e){var a;if(!((a=e==null?void 0:e._ripple)!=null&&a.enabled))return;const t=e.getElementsByClassName("v-ripple__animation");if(t.length===0)return;const n=t[t.length-1];if(n.dataset.isHiding)return;n.dataset.isHiding="true";const o=performance.now()-Number(n.dataset.activated),i=Math.max(250-o,0);setTimeout(()=>{n.classList.remove("v-ripple__animation--in"),n.classList.add("v-ripple__animation--out"),setTimeout(()=>{var l;e.getElementsByClassName("v-ripple__animation").length===1&&e.dataset.previousPosition&&(e.style.position=e.dataset.previousPosition,delete e.dataset.previousPosition),((l=n.parentNode)==null?void 0:l.parentNode)===e&&e.removeChild(n.parentNode)},300)},i)}};function Yt(e){return typeof e>"u"||!!e}function ae(e){const t={},n=e.currentTarget;if(!(!(n!=null&&n._ripple)||n._ripple.touched||e[qe])){if(e[qe]=!0,Ue(e))n._ripple.touched=!0,n._ripple.isTouch=!0;else if(n._ripple.isTouch)return;if(t.center=n._ripple.centered||Ut(e),n._ripple.class&&(t.class=n._ripple.class),Ue(e)){if(n._ripple.showTimerCommit)return;n._ripple.showTimerCommit=()=>{ke.show(e,n,t)},n._ripple.showTimer=window.setTimeout(()=>{var o;(o=n==null?void 0:n._ripple)!=null&&o.showTimerCommit&&(n._ripple.showTimerCommit(),n._ripple.showTimerCommit=null)},jo)}else ke.show(e,n,t)}}function Xt(e){e[qe]=!0}function I(e){const t=e.currentTarget;if(t!=null&&t._ripple){if(window.clearTimeout(t._ripple.showTimer),e.type==="touchend"&&t._ripple.showTimerCommit){t._ripple.showTimerCommit(),t._ripple.showTimerCommit=null,t._ripple.showTimer=window.setTimeout(()=>{I(e)});return}window.setTimeout(()=>{t._ripple&&(t._ripple.touched=!1)}),ke.hide(t)}}function Kt(e){const t=e.currentTarget;t!=null&&t._ripple&&(t._ripple.showTimerCommit&&(t._ripple.showTimerCommit=null),window.clearTimeout(t._ripple.showTimer))}let se=!1;function Zt(e){!se&&(e.keyCode===tt.enter||e.keyCode===tt.space)&&(se=!0,ae(e))}function Jt(e){se=!1,I(e)}function Qt(e){se&&(se=!1,I(e))}function en(e,t,n){const{value:o,modifiers:i}=t,a=Yt(o);if(a||ke.hide(e),e._ripple=e._ripple??{},e._ripple.enabled=a,e._ripple.centered=i.center,e._ripple.circle=i.circle,xn(o)&&o.class&&(e._ripple.class=o.class),a&&!n){if(i.stop){e.addEventListener("touchstart",Xt,{passive:!0}),e.addEventListener("mousedown",Xt);return}e.addEventListener("touchstart",ae,{passive:!0}),e.addEventListener("touchend",I,{passive:!0}),e.addEventListener("touchmove",Kt,{passive:!0}),e.addEventListener("touchcancel",I),e.addEventListener("mousedown",ae),e.addEventListener("mouseup",I),e.addEventListener("mouseleave",I),e.addEventListener("keydown",Zt),e.addEventListener("keyup",Jt),e.addEventListener("blur",Qt),e.addEventListener("dragstart",I,{passive:!0})}else!a&&n&&tn(e)}function tn(e){e.removeEventListener("mousedown",ae),e.removeEventListener("touchstart",ae),e.removeEventListener("touchend",I),e.removeEventListener("touchmove",Kt),e.removeEventListener("touchcancel",I),e.removeEventListener("mouseup",I),e.removeEventListener("mouseleave",I),e.removeEventListener("keydown",Zt),e.removeEventListener("keyup",Jt),e.removeEventListener("dragstart",I),e.removeEventListener("blur",Qt)}function zo(e,t){en(e,t,!1)}function Ho(e){delete e._ripple,tn(e)}function Go(e,t){if(t.value===t.oldValue)return;const n=Yt(t.oldValue);en(e,t,n)}const qo={mounted:zo,unmounted:Ho,updated:Go},Uo=w({active:{type:Boolean,default:void 0},activeColor:String,baseColor:String,symbol:{type:null,default:Ft},flat:Boolean,icon:[Boolean,String,Function,Object],prependIcon:Ce,appendIcon:Ce,block:Boolean,readonly:Boolean,slim:Boolean,stacked:Boolean,ripple:{type:[Boolean,Object],default:!0},text:String,...Tt(),...oe(),...Ot(),...Wt(),...Nt(),...uo(),...Vo(),...Lo(),..._o(),..._t(),...$o(),...ze(),...be({tag:"button"}),...re(),...It({variant:"elevated"})},"VBtn"),Yo=W()({name:"VBtn",props:Uo(),emits:{"group:selected":e=>!0},setup(e,t){let{attrs:n,slots:o}=t;const{themeClasses:i}=ie(e),{borderClasses:a}=Lt(e),{densityClasses:s}=Vt(e),{dimensionStyles:l}=zt(e),{elevationClasses:c}=Rt(e),{loaderClasses:u}=No(e),{locationStyles:f}=Oo(e),{positionClasses:g}=Ao(e),{roundedClasses:m}=At(e),{sizeClasses:v,sizeStyles:h}=He(e),d=fo(e,e.symbol,!1),p=Mo(e,n),b=r.computed(()=>{var x;return e.active!==void 0?e.active:p.isLink.value?(x=p.isActive)==null?void 0:x.value:d==null?void 0:d.isSelected.value}),S=r.computed(()=>b.value?e.activeColor??e.color:e.color),E=r.computed(()=>{var k,C;return{color:(d==null?void 0:d.isSelected.value)&&(!p.isLink.value||((k=p.isActive)==null?void 0:k.value))||!d||((C=p.isActive)==null?void 0:C.value)?S.value??e.baseColor:e.baseColor,variant:e.variant}}),{colorClasses:V,colorStyles:N,variantClasses:_}=lo(E),O=r.computed(()=>(d==null?void 0:d.disabled.value)||e.disabled),y=r.computed(()=>e.variant==="elevated"&&!(e.disabled||e.flat||e.border)),A=r.computed(()=>{if(!(e.value===void 0||typeof e.value=="symbol"))return Object(e.value)===e.value?JSON.stringify(e.value,null,0):e.value});function ce(x){var k;O.value||p.isLink.value&&(x.metaKey||x.ctrlKey||x.shiftKey||x.button!==0||n.target==="_blank")||((k=p.navigate)==null||k.call(p,x),d==null||d.toggle())}return Fo(p,d==null?void 0:d.select),U(()=>{const x=p.isLink.value?"a":e.tag,k=!!(e.prependIcon||o.prepend),C=!!(e.appendIcon||o.append),P=!!(e.icon&&e.icon!==!0);return r.withDirectives(r.createVNode(x,r.mergeProps({type:x==="a"?void 0:"button",class:["v-btn",d==null?void 0:d.selectedClass.value,{"v-btn--active":b.value,"v-btn--block":e.block,"v-btn--disabled":O.value,"v-btn--elevated":y.value,"v-btn--flat":e.flat,"v-btn--icon":!!e.icon,"v-btn--loading":e.loading,"v-btn--readonly":e.readonly,"v-btn--slim":e.slim,"v-btn--stacked":e.stacked},i.value,a.value,V.value,s.value,c.value,u.value,g.value,m.value,v.value,_.value,e.class],style:[N.value,l.value,f.value,h.value,e.style],"aria-busy":e.loading?!0:void 0,disabled:O.value||void 0,tabindex:e.loading||e.readonly?-1:void 0,onClick:ce,value:A.value},p.linkProps),{default:()=>{var M;return[so(!0,"v-btn"),!e.icon&&k&&r.createVNode("span",{key:"prepend",class:"v-btn__prepend"},[o.prepend?r.createVNode(We,{key:"prepend-defaults",disabled:!e.prependIcon,defaults:{VIcon:{icon:e.prependIcon}}},o.prepend):r.createVNode(xe,{key:"prepend-icon",icon:e.prependIcon},null)]),r.createVNode("span",{class:"v-btn__content","data-no-activator":""},[!o.default&&P?r.createVNode(xe,{key:"content-icon",icon:e.icon},null):r.createVNode(We,{key:"content-defaults",disabled:!P,defaults:{VIcon:{icon:e.icon}}},{default:()=>{var $;return[(($=o.default)==null?void 0:$.call(o))??e.text]}})]),!e.icon&&C&&r.createVNode("span",{key:"append",class:"v-btn__append"},[o.append?r.createVNode(We,{key:"append-defaults",disabled:!e.appendIcon,defaults:{VIcon:{icon:e.appendIcon}}},o.append):r.createVNode(xe,{key:"append-icon",icon:e.appendIcon},null)]),!!e.loading&&r.createVNode("span",{key:"loader",class:"v-btn__loader"},[((M=o.loader)==null?void 0:M.call(o))??r.createVNode(Po,{color:typeof e.loading=="boolean"?void 0:e.loading,indeterminate:!0,width:"2"},null)])]}}),[[qo,!O.value&&e.ripple,"",{center:!!e.icon}]])}),{group:d}}});function Ye(e,t){return{x:e.x+t.x,y:e.y+t.y}}function Xo(e,t){return{x:e.x-t.x,y:e.y-t.y}}function nn(e,t){if(e.side==="top"||e.side==="bottom"){const{side:n,align:o}=e,i=o==="left"?0:o==="center"?t.width/2:o==="right"?t.width:o,a=n==="top"?0:n==="bottom"?t.height:n;return Ye({x:i,y:a},t)}else if(e.side==="left"||e.side==="right"){const{side:n,align:o}=e,i=n==="left"?0:n==="right"?t.width:n,a=o==="top"?0:o==="center"?t.height/2:o==="bottom"?t.height:o;return Ye({x:i,y:a},t)}return Ye({x:t.width/2,y:t.height/2},t)}const on={static:Jo,connected:er},Ko=w({locationStrategy:{type:[String,Function],default:"static",validator:e=>typeof e=="function"||e in on},location:{type:String,default:"bottom"},origin:{type:String,default:"auto"},offset:[Number,String,Array]},"VOverlay-location-strategies");function Zo(e,t){const n=r.ref({}),o=r.ref();D&&we(()=>!!(t.isActive.value&&e.locationStrategy),a=>{var s,l;r.watch(()=>e.locationStrategy,a),r.onScopeDispose(()=>{window.removeEventListener("resize",i),o.value=void 0}),window.addEventListener("resize",i,{passive:!0}),typeof e.locationStrategy=="function"?o.value=(s=e.locationStrategy(t,e,n))==null?void 0:s.updateLocation:o.value=(l=on[e.locationStrategy](t,e,n))==null?void 0:l.updateLocation});function i(a){var s;(s=o.value)==null||s.call(o,a)}return{contentStyles:n,updateLocation:o}}function Jo(){}function Qo(e,t){const n=An(e);return t?n.x+=parseFloat(e.style.right||0):n.x-=parseFloat(e.style.left||0),n.y-=parseFloat(e.style.top||0),n}function er(e,t,n){(Array.isArray(e.target.value)||oo(e.target.value))&&Object.assign(n.value,{position:"fixed",top:0,[e.isRtl.value?"right":"left"]:0});const{preferredAnchor:i,preferredOrigin:a}=Ve(()=>{const h=Re(t.location,e.isRtl.value),d=t.origin==="overlap"?h:t.origin==="auto"?_e(h):Re(t.origin,e.isRtl.value);return h.side===d.side&&h.align===Ae(d).align?{preferredAnchor:ut(h),preferredOrigin:ut(d)}:{preferredAnchor:h,preferredOrigin:d}}),[s,l,c,u]=["minWidth","minHeight","maxWidth","maxHeight"].map(h=>r.computed(()=>{const d=parseFloat(t[h]);return isNaN(d)?1/0:d})),f=r.computed(()=>{if(Array.isArray(t.offset))return t.offset;if(typeof t.offset=="string"){const h=t.offset.split(" ").map(parseFloat);return h.length<2&&h.push(0),h}return typeof t.offset=="number"?[t.offset,0]:[0,0]});let g=!1;const m=new ResizeObserver(()=>{g&&v()});r.watch([e.target,e.contentEl],(h,d)=>{let[p,b]=h,[S,E]=d;S&&!Array.isArray(S)&&m.unobserve(S),p&&!Array.isArray(p)&&m.observe(p),E&&m.unobserve(E),b&&m.observe(b)},{immediate:!0}),r.onScopeDispose(()=>{m.disconnect()});function v(){if(g=!1,requestAnimationFrame(()=>g=!0),!e.target.value||!e.contentEl.value)return;const h=_n(e.target.value),d=Qo(e.contentEl.value,e.isRtl.value),p=pe(e.contentEl.value),b=12;p.length||(p.push(document.documentElement),e.contentEl.value.style.top&&e.contentEl.value.style.left||(d.x-=parseFloat(document.documentElement.style.getPropertyValue("--v-body-scroll-x")||0),d.y-=parseFloat(document.documentElement.style.getPropertyValue("--v-body-scroll-y")||0)));const S=p.reduce((x,k)=>{const C=k.getBoundingClientRect(),P=new q({x:k===document.documentElement?0:C.x,y:k===document.documentElement?0:C.y,width:k.clientWidth,height:k.clientHeight});return x?new q({x:Math.max(x.left,P.left),y:Math.max(x.top,P.top),width:Math.min(x.right,P.right)-Math.max(x.left,P.left),height:Math.min(x.bottom,P.bottom)-Math.max(x.top,P.top)}):P},void 0);S.x+=b,S.y+=b,S.width-=b*2,S.height-=b*2;let E={anchor:i.value,origin:a.value};function V(x){const k=new q(d),C=nn(x.anchor,h),P=nn(x.origin,k);let{x:M,y:$}=Xo(C,P);switch(x.anchor.side){case"top":$-=f.value[0];break;case"bottom":$+=f.value[0];break;case"left":M-=f.value[0];break;case"right":M+=f.value[0];break}switch(x.anchor.align){case"top":$-=f.value[1];break;case"bottom":$+=f.value[1];break;case"left":M-=f.value[1];break;case"right":M+=f.value[1];break}return k.x+=M,k.y+=$,k.width=Math.min(k.width,c.value),k.height=Math.min(k.height,u.value),{overflows:dt(k,S),x:M,y:$}}let N=0,_=0;const O={x:0,y:0},y={x:!1,y:!1};let A=-1;for(;;){if(A++>10){Gn("Infinite loop detected in connectedLocationStrategy");break}const{x,y:k,overflows:C}=V(E);N+=x,_+=k,d.x+=x,d.y+=k;{const P=ft(E.anchor),M=C.x.before||C.x.after,$=C.y.before||C.y.after;let Z=!1;if(["x","y"].forEach(B=>{if(B==="x"&&M&&!y.x||B==="y"&&$&&!y.y){const H={anchor:{...E.anchor},origin:{...E.origin}},J=B==="x"?P==="y"?Ae:_e:P==="y"?_e:Ae;H.anchor=J(H.anchor),H.origin=J(H.origin);const{overflows:Q}=V(H);(Q[B].before<=C[B].before&&Q[B].after<=C[B].after||Q[B].before+Q[B].after<(C[B].before+C[B].after)/2)&&(E=H,Z=y[B]=!0)}}),Z)continue}C.x.before&&(N+=C.x.before,d.x+=C.x.before),C.x.after&&(N-=C.x.after,d.x-=C.x.after),C.y.before&&(_+=C.y.before,d.y+=C.y.before),C.y.after&&(_-=C.y.after,d.y-=C.y.after);{const P=dt(d,S);O.x=S.width-P.x.before-P.x.after,O.y=S.height-P.y.before-P.y.after,N+=P.x.before,d.x+=P.x.before,_+=P.y.before,d.y+=P.y.before}break}const ce=ft(E.anchor);return Object.assign(n.value,{"--v-overlay-anchor-origin":`${E.anchor.side} ${E.anchor.align}`,transformOrigin:`${E.origin.side} ${E.origin.align}`,top:L(Xe(_)),left:e.isRtl.value?void 0:L(Xe(N)),right:e.isRtl.value?L(Xe(-N)):void 0,minWidth:L(ce==="y"?Math.min(s.value,h.width):s.value),maxWidth:L(rn(ot(O.x,s.value===1/0?0:s.value,c.value))),maxHeight:L(rn(ot(O.y,l.value===1/0?0:l.value,u.value)))}),{available:O,contentBox:d}}return r.watch(()=>[i.value,a.value,t.offset,t.minWidth,t.minHeight,t.maxWidth,t.maxHeight],()=>v()),r.nextTick(()=>{const h=v();if(!h)return;const{available:d,contentBox:p}=h;p.height>d.y&&requestAnimationFrame(()=>{v(),requestAnimationFrame(()=>{v()})})}),{updateLocation:v}}function Xe(e){return Math.round(e*devicePixelRatio)/devicePixelRatio}function rn(e){return Math.ceil(e*devicePixelRatio)/devicePixelRatio}let Ke=!0;const Ee=[];function tr(e){!Ke||Ee.length?(Ee.push(e),Ze()):(Ke=!1,e(),Ze())}let an=-1;function Ze(){cancelAnimationFrame(an),an=requestAnimationFrame(()=>{const e=Ee.shift();e&&e(),Ee.length?Ze():Ke=!0})}const Pe={none:null,close:rr,block:ir,reposition:ar},nr=w({scrollStrategy:{type:[String,Function],default:"block",validator:e=>typeof e=="function"||e in Pe}},"VOverlay-scroll-strategies");function or(e,t){if(!D)return;let n;r.watchEffect(async()=>{n==null||n.stop(),t.isActive.value&&e.scrollStrategy&&(n=r.effectScope(),await new Promise(o=>setTimeout(o)),n.active&&n.run(()=>{var o;typeof e.scrollStrategy=="function"?e.scrollStrategy(t,e,n):(o=Pe[e.scrollStrategy])==null||o.call(Pe,t,e,n)}))}),r.onScopeDispose(()=>{n==null||n.stop()})}function rr(e){function t(n){e.isActive.value=!1}sn(e.targetEl.value??e.contentEl.value,t)}function ir(e,t){var s;const n=(s=e.root.value)==null?void 0:s.offsetParent,o=[...new Set([...pe(e.targetEl.value,t.contained?n:void 0),...pe(e.contentEl.value,t.contained?n:void 0)])].filter(l=>!l.classList.contains("v-overlay-scroll-blocked")),i=window.innerWidth-document.documentElement.offsetWidth,a=(l=>$e(l)&&l)(n||document.documentElement);a&&e.root.value.classList.add("v-overlay--scroll-blocked"),o.forEach((l,c)=>{l.style.setProperty("--v-body-scroll-x",L(-l.scrollLeft)),l.style.setProperty("--v-body-scroll-y",L(-l.scrollTop)),l!==document.documentElement&&l.style.setProperty("--v-scrollbar-offset",L(i)),l.classList.add("v-overlay-scroll-blocked")}),r.onScopeDispose(()=>{o.forEach((l,c)=>{const u=parseFloat(l.style.getPropertyValue("--v-bo