| import"../chunks/DsnmJJEf.js";import{a5 as B,b as M,f as te,c as Ee,aO as Me,h as F,C as ce,O as W,Y as Ce,P as Te,z as V,M as E,k as xe,d as Ae,aP as ze,Q as re,$ as g,_ as Ie,u as ue,az as T,g as d,ai as _,ah as N,aB as L,aQ as Q,W as J,a4 as O,Z as Y,a8 as le}from"../chunks/C3_5CtcH.js";import{b as ne,m as Pe,o as S,d as de,c as v,f as x}from"../chunks/BqMQvsrN.js";import{b as Z,s as Be}from"../chunks/xulJ-fEs.js";import{c as R}from"../chunks/Bil_ebOF.js";import{o as Ne}from"../chunks/CV1tziH8.js";import{i as U,p as m}from"../chunks/cDqZYZlc.js";function Le(t,e,r=!1,n=!1,i=!1){var o=t,s="";B(()=>{var a=Ee;if(s===(s=e()??"")){M&&te();return}if(a.nodes_start!==null&&(Me(a.nodes_start,a.nodes_end),a.nodes_start=a.nodes_end=null),s!==""){if(M){F.data;for(var c=te(),l=c;c!==null&&(c.nodeType!==ce||c.data!=="");)l=c,c=W(c);if(c===null)throw Ce(),Te;ne(F,l),o=V(c);return}var f=s+"";r?f=`<svg>${f}</svg>`:n&&(f=`<math>${f}</math>`);var h=Pe(f);if((r||n)&&(h=E(h)),ne(E(h),h.lastChild),r||n)for(;E(h);)o.before(E(h));else o.before(h)}})}function fe(t,e){let r=null,n=M;var i;if(M){r=F;for(var o=E(document.head);o!==null&&(o.nodeType!==ce||o.data!==t);)o=W(o);if(o===null)re(!1);else{var s=W(o);o.remove(),V(s)}}M||(i=document.head.appendChild(xe()));try{Ae(()=>e(i),ze)}finally{n&&(re(!0),V(r))}}const he=typeof window<"u"?window:void 0;function Oe(t){let e=t.activeElement;for(;e?.shadowRoot;){const r=e.shadowRoot.activeElement;if(r===e)break;e=r}return e}class Re{#t;#e;constructor(e,r){this.#t=e,this.#e=R(r)}get current(){return this.#e(),this.#t()}}const Fe=/\(.+\)/,We=new Set(["all","print","screen","and","or","not","only"]);class Ve extends Re{constructor(e,r){let n=Fe.test(e)||e.split(/[\s,]+/).some(o=>We.has(o.trim()))?e:`(${e})`;const i=window.matchMedia(n);super(()=>i.matches,o=>S(i,"change",o))}}let qe=class{#t;#e;constructor(e={}){const{window:r=he,document:n=r?.document}=e;r!==void 0&&(this.#t=n,this.#e=R(i=>{const o=S(r,"focusin",i),s=S(r,"focusout",i);return()=>{o(),s()}}))}get current(){return this.#e?.(),this.#t?Oe(this.#t):null}};new qe;function je(t,e){switch(t){case"post":Ie(e);break;case"pre":g(e);break}}function me(t,e,r,n={}){const{lazy:i=!1}=n;let o=!i,s=Array.isArray(t)?[]:void 0;je(e,()=>{const a=Array.isArray(t)?t.map(l=>l()):t();if(!o){o=!0,s=a;return}const c=ue(()=>r(a,s));return s=a,c})}function X(t,e,r){me(t,"post",e,r)}function De(t,e,r){me(t,"pre",e,r)}X.pre=De;function Ke(t,e){switch(t){case"local":return e.localStorage;case"session":return e.sessionStorage}}class ge{#t;#e;#n;#r;#i;#o=T(0);constructor(e,r,n={}){const{storage:i="local",serializer:o={serialize:JSON.stringify,deserialize:JSON.parse},syncTabs:s=!0,window:a=he}=n;if(this.#t=r,this.#e=e,this.#n=o,a===void 0)return;const c=Ke(i,a);this.#r=c;const l=c.getItem(e);l!==null?this.#t=this.#s(l):this.#a(r),s&&i==="local"&&(this.#i=R(()=>S(a,"storage",this.#c)))}get current(){this.#i?.(),d(this.#o);const e=this.#s(this.#r?.getItem(this.#e))??this.#t,r=new WeakMap,n=i=>{if(i===null||i?.constructor.name==="Date"||typeof i!="object")return i;let o=r.get(i);return o||(o=new Proxy(i,{get:(s,a)=>(d(this.#o),n(Reflect.get(s,a))),set:(s,a,c)=>(_(this.#o,d(this.#o)+1),Reflect.set(s,a,c),this.#a(e),!0)}),r.set(i,o)),o};return n(e)}set current(e){this.#a(e),_(this.#o,d(this.#o)+1)}#c=e=>{e.key!==this.#e||e.newValue===null||(this.#t=this.#s(e.newValue),_(this.#o,d(this.#o)+1))};#s(e){try{return this.#n.deserialize(e)}catch(r){console.error(`Error when parsing "${e}" from persisted store "${this.#e}"`,r);return}}#a(e){try{e!=null&&this.#r?.setItem(this.#e,this.#n.serialize(e))}catch(r){console.error(`Error when writing value from persisted store "${this.#e}" to ${this.#r}`,r)}}}function oe(t){return t.filter(e=>e.length>0)}const we={getItem:t=>null,setItem:(t,e)=>{}},A=typeof document<"u";function He(t){return typeof t=="function"}function Qe(t){return t!==null&&typeof t=="object"}const C=Symbol("box"),G=Symbol("is-writable");function Je(t){return Qe(t)&&C in t}function Ye(t){return u.isBox(t)&&G in t}function u(t){let e=T(N(t));return{[C]:!0,[G]:!0,get current(){return d(e)},set current(r){_(e,r,!0)}}}function Ze(t,e){const r=L(t);return e?{[C]:!0,[G]:!0,get current(){return d(r)},set current(n){e(n)}}:{[C]:!0,get current(){return t()}}}function Ue(t){return u.isBox(t)?t:He(t)?u.with(t):u(t)}function Xe(t){return Object.entries(t).reduce((e,[r,n])=>u.isBox(n)?(u.isWritableBox(n)?Object.defineProperty(e,r,{get(){return n.current},set(i){n.current=i}}):Object.defineProperty(e,r,{get(){return n.current}}),e):Object.assign(e,{[r]:n}),{})}function Ge(t){return u.isWritableBox(t)?{[C]:!0,get current(){return t.current}}:t}u.from=Ue;u.with=Ze;u.flatten=Xe;u.readonly=Ge;u.isBox=Je;u.isWritableBox=Ye;function $e(t,e){const r=RegExp(t,"g");return n=>{if(typeof n!="string")throw new TypeError(`expected an argument of type string, but got ${typeof n}`);return n.match(r)?n.replace(r,e):n}}const et=$e(/[A-Z]/,t=>`-${t.toLowerCase()}`);function tt(t){if(!t||typeof t!="object"||Array.isArray(t))throw new TypeError(`expected an argument of type object, but got ${typeof t}`);return Object.keys(t).map(e=>`${et(e)}: ${t[e]};`).join(` | |
| `)}function rt(t={}){return tt(t).replace(` | |
| `," ")}const nt={position:"absolute",width:"1px",height:"1px",padding:"0",margin:"-1px",overflow:"hidden",clip:"rect(0, 0, 0, 0)",whiteSpace:"nowrap",borderWidth:"0",transform:"translateX(-100%)"};rt(nt);const ot=typeof window<"u"?window:void 0;function it(t){let e=t.activeElement;for(;e?.shadowRoot;){const r=e.shadowRoot.activeElement;if(r===e)break;e=r}return e}class st{#t;#e;constructor(e={}){const{window:r=ot,document:n=r?.document}=e;r!==void 0&&(this.#t=n,this.#e=R(i=>{const o=S(r,"focusin",i),s=S(r,"focusout",i);return()=>{o(),s()}}))}get current(){return this.#e?.(),this.#t?it(this.#t):null}}new st;const p=u("mode-watcher-mode"),b=u("mode-watcher-theme"),at=["dark","light","system"];function q(t){return typeof t!="string"?!1:at.includes(t)}class ct{#t="system";#e=A?localStorage:we;#n=this.#e.getItem(p.current);#r=q(this.#n)?this.#n:this.#t;#i=T(N(this.#o()));#o(e=this.#r){return new ge(p.current,e,{serializer:{serialize:r=>r,deserialize:r=>q(r)?r:this.#t}})}constructor(){Q(()=>X.pre(()=>p.current,(e,r)=>{const n=d(this.#i).current;_(this.#i,this.#o(n),!0),r&&localStorage.removeItem(r)}))}get current(){return d(this.#i).current}set current(e){d(this.#i).current=e}}class ut{#t=void 0;#e=!0;#n=T(N(this.#t));#r=typeof window<"u"&&typeof window.matchMedia=="function"?new Ve("prefers-color-scheme: light"):{current:!1};query(){A&&_(this.#n,this.#r.current?"light":"dark",!0)}tracking(e){this.#e=e}constructor(){Q(()=>{g(()=>{this.#e&&this.query()})}),this.query=this.query.bind(this),this.tracking=this.tracking.bind(this)}get current(){return d(this.#n)}}const j=new ct,D=new ut;class lt{#t=A?localStorage:we;#e=this.#t.getItem(b.current);#n=this.#e===null||this.#e===void 0?"":this.#e;#r=T(N(this.#i()));#i(e=this.#n){return new ge(b.current,e,{serializer:{serialize:r=>typeof r!="string"?"":r,deserialize:r=>r}})}constructor(){Q(()=>X.pre(()=>b.current,(e,r)=>{const n=d(this.#r).current;_(this.#r,this.#i(n),!0),r&&localStorage.removeItem(r)}))}get current(){return d(this.#r).current}set current(e){d(this.#r).current=e}}const z=new lt;let ie,se,ae=!1,k=null;function dt(){return k||(k=document.createElement("style"),k.appendChild(document.createTextNode(`* { | |
| -webkit-transition: none !important; | |
| -moz-transition: none !important; | |
| -o-transition: none !important; | |
| -ms-transition: none !important; | |
| transition: none !important; | |
| }`)),k)}function ye(t,e=!1){if(typeof document>"u")return;if(!ae){ae=!0,t();return}if(typeof window<"u"&&window.__vitest_worker__){t();return}clearTimeout(ie),clearTimeout(se);const n=dt(),i=()=>document.head.appendChild(n),o=()=>{n.parentNode&&document.head.removeChild(n)};function s(){t(),window.requestAnimationFrame(o)}if(typeof window.requestAnimationFrame<"u"){i(),e?s():window.requestAnimationFrame(()=>{s()});return}i(),ie=window.setTimeout(()=>{t(),se=window.setTimeout(o,16)},16)}const y=u(void 0),I=u(!0),P=u(!1),K=u([]),H=u([]);function ft(){const t=L(()=>{if(!A)return;const e=j.current==="system"?D.current:j.current,r=oe(K.current),n=oe(H.current);function i(){const o=document.documentElement,s=document.querySelector('meta[name="theme-color"]');e==="light"?(r.length&&o.classList.remove(...r),n.length&&o.classList.add(...n),o.style.colorScheme="light",s&&y.current&&s.setAttribute("content",y.current.light)):(n.length&&o.classList.remove(...n),r.length&&o.classList.add(...r),o.style.colorScheme="dark",s&&y.current&&s.setAttribute("content",y.current.dark))}return I.current?ye(i,P.current):i(),e});return{get current(){return d(t)}}}function ht(){const t=L(()=>{if(z.current,!A)return;function e(){document.documentElement.setAttribute("data-theme",z.current)}return I.current?ye(e,ue(()=>P.current)):e(),z.current});return{get current(){return d(t)}}}const mt=ft(),gt=ht();function wt(t){j.current=t}function yt(t){z.current=t}function pt({defaultMode:t="system",themeColors:e,darkClassNames:r=["dark"],lightClassNames:n=[],defaultTheme:i="",modeStorageKey:o="mode-watcher-mode",themeStorageKey:s="mode-watcher-theme"}){const a=document.documentElement,c=localStorage.getItem(o)??t,l=localStorage.getItem(s)??i,f=c==="light"||c==="system"&&window.matchMedia("(prefers-color-scheme: light)").matches;if(f?(r.length&&a.classList.remove(...r.filter(Boolean)),n.length&&a.classList.add(...n.filter(Boolean))):(n.length&&a.classList.remove(...n.filter(Boolean)),r.length&&a.classList.add(...r.filter(Boolean))),a.style.colorScheme=f?"light":"dark",e){const h=document.querySelector('meta[name="theme-color"]');h&&h.setAttribute("content",c==="light"?e.light:e.dark)}l&&(a.setAttribute("data-theme",l),localStorage.setItem(s,l)),localStorage.setItem(o,c)}var bt=x('<meta name="theme-color"/>');function _t(t,e){J(e,!0);var r=de(),n=O(r);{var i=o=>{var s=bt();B(()=>Z(s,"content",e.themeColors.dark)),v(o,s)};U(n,o=>{e.themeColors&&o(i)})}v(t,r),Y()}var vt=x('<meta name="theme-color"/>'),St=x("<!> <!>",1);function kt(t,e){J(e,!0);let r=m(e,"trueNonce",3,"");fe("1funsus",n=>{var i=St(),o=O(i);{var s=c=>{var l=vt();B(()=>Z(l,"content",e.themeColors.dark)),v(c,l)};U(o,c=>{e.themeColors&&c(s)})}var a=le(o,2);Le(a,()=>`<script${r()?` nonce=${r()}`:""}>(`+pt.toString()+")("+JSON.stringify(e.initConfig)+");<\/script>"),v(n,i)}),Y()}function Et(t,e){J(e,!0);let r=m(e,"track",3,!0),n=m(e,"defaultMode",3,"system"),i=m(e,"disableTransitions",3,!0),o=m(e,"darkClassNames",19,()=>["dark"]),s=m(e,"lightClassNames",19,()=>[]),a=m(e,"defaultTheme",3,""),c=m(e,"nonce",3,""),l=m(e,"themeStorageKey",3,"mode-watcher-theme"),f=m(e,"modeStorageKey",3,"mode-watcher-mode"),h=m(e,"disableHeadScriptInjection",3,!1),$=m(e,"synchronousModeChanges",3,!1);p.current=f(),b.current=l(),K.current=o(),H.current=s(),I.current=i(),y.current=e.themeColors,P.current=$(),g(()=>{P.current=$()}),g(()=>{I.current=i()}),g(()=>{y.current=e.themeColors}),g(()=>{K.current=o()}),g(()=>{H.current=s()}),g(()=>{p.current=f()}),g(()=>{b.current=l()}),g(()=>{mt.current,p.current,b.current,gt.current}),Ne(()=>{D.tracking(r()),D.query();const w=localStorage.getItem(p.current);wt(q(w)?w:n());const ke=localStorage.getItem(b.current);yt(ke||a())});const pe={defaultMode:n(),themeColors:e.themeColors,darkClassNames:o(),lightClassNames:s(),defaultTheme:a(),modeStorageKey:f(),themeStorageKey:l()},be=L(()=>typeof window>"u"?c():"");var ee=de(),_e=O(ee);{var ve=w=>{_t(w,{get themeColors(){return y.current}})},Se=w=>{kt(w,{get trueNonce(){return d(be)},get initConfig(){return pe},get themeColors(){return y.current}})};U(_e,w=>{h()?w(ve):w(Se,!1)})}v(t,ee),Y()}const Mt="data:image/svg+xml,%3csvg%20xmlns='http://www.w3.org/2000/svg'%20width='107'%20height='128'%20viewBox='0%200%20107%20128'%3e%3ctitle%3esvelte-logo%3c/title%3e%3cpath%20d='M94.157%2022.819c-10.4-14.885-30.94-19.297-45.792-9.835L22.282%2029.608A29.92%2029.92%200%200%200%208.764%2049.65a31.5%2031.5%200%200%200%203.108%2020.231%2030%2030%200%200%200-4.477%2011.183%2031.9%2031.9%200%200%200%205.448%2024.116c10.402%2014.887%2030.942%2019.297%2045.791%209.835l26.083-16.624A29.92%2029.92%200%200%200%2098.235%2078.35a31.53%2031.53%200%200%200-3.105-20.232%2030%2030%200%200%200%204.474-11.182%2031.88%2031.88%200%200%200-5.447-24.116'%20style='fill:%23ff3e00'/%3e%3cpath%20d='M45.817%20106.582a20.72%2020.72%200%200%201-22.237-8.243%2019.17%2019.17%200%200%201-3.277-14.503%2018%2018%200%200%201%20.624-2.435l.49-1.498%201.337.981a33.6%2033.6%200%200%200%2010.203%205.098l.97.294-.09.968a5.85%205.85%200%200%200%201.052%203.878%206.24%206.24%200%200%200%206.695%202.485%205.8%205.8%200%200%200%201.603-.704L69.27%2076.28a5.43%205.43%200%200%200%202.45-3.631%205.8%205.8%200%200%200-.987-4.371%206.24%206.24%200%200%200-6.698-2.487%205.7%205.7%200%200%200-1.6.704l-9.953%206.345a19%2019%200%200%201-5.296%202.326%2020.72%2020.72%200%200%201-22.237-8.243%2019.17%2019.17%200%200%201-3.277-14.502%2017.99%2017.99%200%200%201%208.13-12.052l26.081-16.623a19%2019%200%200%201%205.3-2.329%2020.72%2020.72%200%200%201%2022.237%208.243%2019.17%2019.17%200%200%201%203.277%2014.503%2018%2018%200%200%201-.624%202.435l-.49%201.498-1.337-.98a33.6%2033.6%200%200%200-10.203-5.1l-.97-.294.09-.968a5.86%205.86%200%200%200-1.052-3.878%206.24%206.24%200%200%200-6.696-2.485%205.8%205.8%200%200%200-1.602.704L37.73%2051.72a5.42%205.42%200%200%200-2.449%203.63%205.79%205.79%200%200%200%20.986%204.372%206.24%206.24%200%200%200%206.698%202.486%205.8%205.8%200%200%200%201.602-.704l9.952-6.342a19%2019%200%200%201%205.295-2.328%2020.72%2020.72%200%200%201%2022.237%208.242%2019.17%2019.17%200%200%201%203.277%2014.503%2018%2018%200%200%201-8.13%2012.053l-26.081%2016.622a19%2019%200%200%201-5.3%202.328'%20style='fill:%23fff'/%3e%3c/svg%3e";var Ct=x('<link rel="icon"/>'),Tt=x("<!> <!>",1);function Ot(t,e){var r=Tt();fe("12qhfyh",o=>{var s=Ct();B(()=>Z(s,"href",Mt)),v(o,s)});var n=O(r);Et(n,{});var i=le(n,2);Be(i,()=>e.children),v(t,r)}export{Ot as component}; | |