const f={context:void 0,registry:void 0};function B(e){f.context=e}function St(){return{...f.context,id:`${f.context.id}${f.context.count++}-`,count:0}}const Et=(e,t)=>e===t,vt=Symbol("solid-track"),ge={equals:Et};let ie=null,ze=et;const q=1,ce=2,Ye={owned:null,cleanups:null,context:null,owner:null},Se={};var y=null;let d=null,At=null,E=null,I=null,L=null,we=0;function G(e,t){const n=E,r=y,s=e.length===0,o=t===void 0?r:t,l=s?Ye:{owned:null,cleanups:null,context:o?o.context:null,owner:o},i=s?e:()=>e(()=>N(()=>W(l)));y=l,E=null;try{return j(i,!0)}finally{E=n,y=r}}function M(e,t){t=t?Object.assign({},ge,t):ge;const n={value:e,observers:null,observerSlots:null,comparator:t.equals||void 0},r=s=>(typeof s=="function"&&(d&&d.running&&d.sources.has(n)?s=s(n.tValue):s=s(n.value)),Ze(n,s));return[Qe.bind(n),r]}function Le(e,t,n){const r=fe(e,t,!0,q);ee(r)}function F(e,t,n){const r=fe(e,t,!1,q);ee(r)}function Xe(e,t,n){ze=_t;const r=fe(e,t,!1,q),s=z&&U(z);s&&(r.suspense=s),(!n||!n.render)&&(r.user=!0),L?L.push(r):ee(r)}function P(e,t,n){n=n?Object.assign({},ge,n):ge;const r=fe(e,t,!0,0);return r.observers=null,r.observerSlots=null,r.comparator=n.equals||void 0,ee(r),Qe.bind(r)}function Pt(e){return e&&typeof e=="object"&&"then"in e}function Ct(e,t,n){let r,s,o;arguments.length===2&&typeof t=="object"||arguments.length===1?(r=!0,s=e,o=t||{}):(r=e,s=t,o=n||{});let l=null,i=Se,u=null,a=!1,c=!1,h="initialValue"in o,g=typeof r=="function"&&P(r);const w=new Set,[S,b]=(o.storage||M)(o.initialValue),[k,T]=M(void 0),[C,$]=M(void 0,{equals:!1}),[O,R]=M(h?"ready":"unresolved");if(f.context){u=`${f.context.id}${f.context.count++}`;let m;o.ssrLoadFrom==="initial"?i=o.initialValue:f.load&&(m=f.load(u))&&(i=m)}function H(m,x,A,V){return l===m&&(l=null,V!==void 0&&(h=!0),(m===i||x===i)&&o.onHydrated&&queueMicrotask(()=>o.onHydrated(V,{value:x})),i=Se,d&&m&&a?(d.promises.delete(m),a=!1,j(()=>{d.running=!0,te(x,A)},!1)):te(x,A)),x}function te(m,x){j(()=>{x===void 0&&b(()=>m),R(x!==void 0?"errored":h?"ready":"unresolved"),T(x);for(const A of w.keys())A.decrement();w.clear()},!1)}function ne(){const m=z&&U(z),x=S(),A=k();if(A!==void 0&&!l)throw A;return E&&!E.user&&m&&Le(()=>{C(),l&&(m.resolved&&d&&a?d.promises.add(l):w.has(m)||(m.increment(),w.add(m)))}),x}function v(m=!0){if(m!==!1&&c)return;c=!1;const x=g?g():r;if(a=d&&d.running,x==null||x===!1){H(l,N(S));return}d&&l&&d.promises.delete(l);const A=i!==Se?i:N(()=>s(x,{value:S(),refetching:m}));return Pt(A)?(l=A,"value"in A?(A.status==="success"?H(l,A.value,void 0,x):H(l,void 0,void 0,x),A):(c=!0,queueMicrotask(()=>c=!1),j(()=>{R(h?"refreshing":"pending"),$()},!1),A.then(V=>H(A,V,void 0,x),V=>H(A,void 0,rt(V),x)))):(H(l,A,void 0,x),A)}return Object.defineProperties(ne,{state:{get:()=>O()},error:{get:()=>k()},loading:{get(){const m=O();return m==="pending"||m==="refreshing"}},latest:{get(){if(!h)return ne();const m=k();if(m&&!l)throw m;return S()}}}),g?Le(()=>v(!1)):v(!1),[ne,{refetch:v,mutate:b}]}function N(e){if(E===null)return e();const t=E;E=null;try{return e()}finally{E=t}}function Ge(e,t,n){const r=Array.isArray(e);let s,o=n&&n.defer;return l=>{let i;if(r){i=Array(e.length);for(let a=0;at(i,s,l));return s=i,u}}function kt(e){Xe(()=>N(e))}function Q(e){return y===null||(y.cleanups===null?y.cleanups=[e]:y.cleanups.push(e)),e}function Tt(e,t){ie||(ie=Symbol("error")),y=fe(void 0,void 0,!0),y.context={...y.context,[ie]:[t]},d&&d.running&&d.sources.add(y);try{return e()}catch(n){de(n)}finally{y=y.owner}}function Je(){return y}function $t(e,t){const n=y,r=E;y=e,E=null;try{return j(t,!0)}catch(s){de(s)}finally{y=n,E=r}}function Nt(e){if(d&&d.running)return e(),d.done;const t=E,n=y;return Promise.resolve().then(()=>{E=t,y=n;let r;return z&&(r=d||(d={sources:new Set,effects:[],promises:new Set,disposed:new Set,queue:new Set,running:!0}),r.done||(r.done=new Promise(s=>r.resolve=s)),r.running=!0),j(e,!1),E=y=null,r?r.done:void 0})}const[hr,Re]=M(!1);function Ot(e){L.push.apply(L,e),e.length=0}function Z(e,t){const n=Symbol("context");return{id:n,Provider:It(n),defaultValue:e}}function U(e){return y&&y.context&&y.context[e.id]!==void 0?y.context[e.id]:e.defaultValue}function be(e){const t=P(e),n=P(()=>Pe(t()));return n.toArray=()=>{const r=n();return Array.isArray(r)?r:r!=null?[r]:[]},n}let z;function Lt(){return z||(z=Z())}function Qe(){const e=d&&d.running;if(this.sources&&(e?this.tState:this.state))if((e?this.tState:this.state)===q)ee(this);else{const t=I;I=null,j(()=>me(this),!1),I=t}if(E){const t=this.observers?this.observers.length:0;E.sources?(E.sources.push(this),E.sourceSlots.push(t)):(E.sources=[this],E.sourceSlots=[t]),this.observers?(this.observers.push(E),this.observerSlots.push(E.sources.length-1)):(this.observers=[E],this.observerSlots=[E.sources.length-1])}return e&&d.sources.has(this)?this.tValue:this.value}function Ze(e,t,n){let r=d&&d.running&&d.sources.has(e)?e.tValue:e.value;if(!e.comparator||!e.comparator(r,t)){if(d){const s=d.running;(s||!n&&d.sources.has(e))&&(d.sources.add(e),e.tValue=t),s||(e.value=t)}else e.value=t;e.observers&&e.observers.length&&j(()=>{for(let s=0;s1e6)throw I=[],new Error},!1)}return t}function ee(e){if(!e.fn)return;W(e);const t=we;_e(e,d&&d.running&&d.sources.has(e)?e.tValue:e.value,t),d&&!d.running&&d.sources.has(e)&&queueMicrotask(()=>{j(()=>{d&&(d.running=!0),E=y=e,_e(e,e.tValue,t),E=y=null},!1)})}function _e(e,t,n){let r;const s=y,o=E;E=y=e;try{r=e.fn(t)}catch(l){return e.pure&&(d&&d.running?(e.tState=q,e.tOwned&&e.tOwned.forEach(W),e.tOwned=void 0):(e.state=q,e.owned&&e.owned.forEach(W),e.owned=null)),e.updatedAt=n+1,de(l)}finally{E=o,y=s}(!e.updatedAt||e.updatedAt<=n)&&(e.updatedAt!=null&&"observers"in e?Ze(e,r,!0):d&&d.running&&e.pure?(d.sources.add(e),e.tValue=r):e.value=r,e.updatedAt=n)}function fe(e,t,n,r=q,s){const o={fn:e,state:r,updatedAt:null,owned:null,sources:null,sourceSlots:null,cleanups:null,value:t,owner:y,context:y?y.context:null,pure:n};return d&&d.running&&(o.state=0,o.tState=r),y===null||y!==Ye&&(d&&d.running&&y.pure?y.tOwned?y.tOwned.push(o):y.tOwned=[o]:y.owned?y.owned.push(o):y.owned=[o]),o}function pe(e){const t=d&&d.running;if((t?e.tState:e.state)===0)return;if((t?e.tState:e.state)===ce)return me(e);if(e.suspense&&N(e.suspense.inFallback))return e.suspense.effects.push(e);const n=[e];for(;(e=e.owner)&&(!e.updatedAt||e.updatedAt=0;r--){if(e=n[r],t){let s=e,o=n[r+1];for(;(s=s.owner)&&s!==o;)if(d.disposed.has(s))return}if((t?e.tState:e.state)===q)ee(e);else if((t?e.tState:e.state)===ce){const s=I;I=null,j(()=>me(e,n[0]),!1),I=s}}}function j(e,t){if(I)return e();let n=!1;t||(I=[]),L?n=!0:L=[],we++;try{const r=e();return Rt(n),r}catch(r){n||(L=null),I=null,de(r)}}function Rt(e){if(I&&(et(I),I=null),e)return;let t;if(d){if(!d.promises.size&&!d.queue.size){const r=d.sources,s=d.disposed;L.push.apply(L,d.effects),t=d.resolve;for(const o of L)"tState"in o&&(o.state=o.tState),delete o.tState;d=null,j(()=>{for(const o of s)W(o);for(const o of r){if(o.value=o.tValue,o.owned)for(let l=0,i=o.owned.length;lze(n),!1),t&&t()}function et(e){for(let t=0;t=0;t--)W(e.tOwned[t]);delete e.tOwned}nt(e,!0)}else if(e.owned){for(t=e.owned.length-1;t>=0;t--)W(e.owned[t]);e.owned=null}if(e.cleanups){for(t=e.cleanups.length-1;t>=0;t--)e.cleanups[t]();e.cleanups=null}d&&d.running?e.tState=0:e.state=0}function nt(e,t){if(t||(e.tState=0,d.disposed.add(e)),e.owned)for(let n=0;ns=N(()=>(y.context={...y.context,[e]:r.value},be(()=>r.children))),void 0),s}}const Mt=Symbol("fallback");function Me(e){for(let t=0;t1?[]:null;return Q(()=>Me(o)),()=>{let u=e()||[],a,c;return u[vt],N(()=>{let g=u.length,w,S,b,k,T,C,$,O,R;if(g===0)l!==0&&(Me(o),o=[],r=[],s=[],l=0,i&&(i=[])),n.fallback&&(r=[Mt],s[0]=G(H=>(o[0]=H,n.fallback())),l=1);else if(l===0){for(s=new Array(g),c=0;c=C&&O>=C&&r[$]===u[O];$--,O--)b[O]=s[$],k[O]=o[$],i&&(T[O]=i[$]);for(w=new Map,S=new Array(O+1),c=O;c>=C;c--)R=u[c],a=w.get(R),S[c]=a===void 0?-1:a,w.set(R,c);for(a=C;a<=$;a++)R=r[a],c=w.get(R),c!==void 0&&c!==-1?(b[c]=s[a],k[c]=o[a],i&&(T[c]=i[a]),c=S[c],w.set(R,c)):o[a]();for(c=C;ce(t||{}));return B(n),r}return N(()=>e(t||{}))}function Ee(e){let t,n;const r=s=>{const o=f.context;if(o){const[i,u]=M();f.count||(f.count=0),f.count++,(n||(n=e())).then(a=>{B(o),f.count--,u(()=>a.default),B()}),t=i}else if(!t){const[i]=Ct(()=>(n||(n=e())).then(u=>u.default));t=i}let l;return P(()=>(l=t())&&N(()=>{if(!o)return l(s);const i=f.context;B(o);const u=l(s);return B(i),u}))};return r.preload=()=>n||((n=e()).then(s=>t=()=>s.default),n),r}let Ht=0;function Vt(){const e=f.context;return e?`${e.id}${e.count++}`:`cl-${Ht++}`}const ot=e=>`Stale read from <${e}>.`;function gr(e){const t="fallback"in e&&{fallback:()=>e.fallback};return P(jt(()=>e.each,e.children,t||void 0))}function Te(e){const t=e.keyed,n=P(()=>e.when,void 0,{equals:(r,s)=>t?r===s:!r==!s});return P(()=>{const r=n();if(r){const s=e.children;return typeof s=="function"&&s.length>0?N(()=>s(t?r:()=>{if(!N(n))throw ot("Show");return e.when})):s}return e.fallback},void 0,void 0)}function pr(e){let t=!1;const n=(o,l)=>(t?o[1]===l[1]:!o[1]==!l[1])&&o[2]===l[2],r=be(()=>e.children),s=P(()=>{let o=r();Array.isArray(o)||(o=[o]);for(let l=0;l{const[o,l,i]=s();if(o<0)return e.fallback;const u=i.children;return typeof u=="function"&&u.length>0?N(()=>u(t?l:()=>{if(N(s)[0]!==o)throw ot("Match");return i.when})):u},void 0,void 0)}function mr(e){return e}let X;function it(){X&&[...X].forEach(e=>e())}function Bt(e){let t;f.context&&f.load&&(t=f.load(f.context.id+f.context.count));const[n,r]=M(t,void 0);return X||(X=new Set),X.add(r),Q(()=>X.delete(r)),P(()=>{let s;if(s=n()){const o=e.fallback;return typeof o=="function"&&o.length?N(()=>o(s,()=>r())):o}return Tt(()=>e.children,r)},void 0,void 0)}const Ft=Z();function Ut(e){let t=0,n,r,s,o,l;const[i,u]=M(!1),a=Lt(),c={increment:()=>{++t===1&&u(!0)},decrement:()=>{--t===0&&u(!1)},inFallback:i,effects:[],resolved:!1},h=Je();if(f.context&&f.load){const S=f.context.id+f.context.count;let b=f.load(S);if(b&&(typeof b!="object"||b.status!=="success"?s=b:f.gather(S)),s&&s!=="$$f"){const[k,T]=M(void 0,{equals:!1});o=k,s.then(()=>{if(f.done)return T();f.gather(S),B(r),T(),B()},C=>{l=C,T()})}}const g=U(Ft);g&&(n=g.register(c.inFallback));let w;return Q(()=>w&&w()),p(a.Provider,{value:c,get children(){return P(()=>{if(l)throw l;if(r=f.context,o)return o(),o=void 0;r&&s==="$$f"&&B();const S=P(()=>e.children);return P(b=>{const k=c.inFallback(),{showContent:T=!0,showFallback:C=!0}=n?n():{};if((!k||s&&s!=="$$f")&&T)return c.resolved=!0,w&&w(),w=r=s=void 0,Ot(c.effects),S();if(C)return w?b:G($=>(w=$,r&&(B({id:r.id+"f",count:0}),r=void 0),e.fallback),h)})})}})}const Kt=["allowfullscreen","async","autofocus","autoplay","checked","controls","default","disabled","formnovalidate","hidden","indeterminate","inert","ismap","loop","multiple","muted","nomodule","novalidate","open","playsinline","readonly","required","reversed","seamless","selected"],Dt=new Set(["className","value","readOnly","formNoValidate","isMap","noModule","playsInline",...Kt]),Wt=new Set(["innerHTML","textContent","innerText","children"]),zt=Object.assign(Object.create(null),{className:"class",htmlFor:"for"}),Yt=Object.assign(Object.create(null),{class:"className",formnovalidate:{$:"formNoValidate",BUTTON:1,INPUT:1},ismap:{$:"isMap",IMG:1},nomodule:{$:"noModule",SCRIPT:1},playsinline:{$:"playsInline",VIDEO:1},readonly:{$:"readOnly",INPUT:1,TEXTAREA:1}});function Xt(e,t){const n=Yt[e];return typeof n=="object"?n[t]?n.$:void 0:n}const Gt=new Set(["beforeinput","click","dblclick","contextmenu","focusin","focusout","input","keydown","keyup","mousedown","mousemove","mouseout","mouseover","mouseup","pointerdown","pointermove","pointerout","pointerover","pointerup","touchend","touchmove","touchstart"]),Jt={xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace"};function Qt(e,t,n){let r=n.length,s=t.length,o=r,l=0,i=0,u=t[s-1].nextSibling,a=null;for(;lc-i){const S=t[l];for(;i{s=o,t===document?e():ye(t,e(),t.firstChild?null:void 0,n)},r.owner),()=>{s(),t.textContent=""}}function en(e,t,n){let r;const s=()=>{const l=document.createElement("template");return l.innerHTML=e,n?l.content.firstChild.firstChild:l.content.firstChild},o=t?()=>N(()=>document.importNode(r||(r=s()),!0)):()=>(r||(r=s())).cloneNode(!0);return o.cloneNode=o,o}function $e(e,t=window.document){const n=t[je]||(t[je]=new Set);for(let r=0,s=e.length;rs.call(e,n[1],o))}else e.addEventListener(t,n)}function rn(e,t,n={}){const r=Object.keys(t||{}),s=Object.keys(n);let o,l;for(o=0,l=s.length;os.children=J(e,t.children,s.children)),F(()=>t.ref&&t.ref(e)),F(()=>on(e,t,n,!0,s,!0)),s}function ye(e,t,n,r){if(n!==void 0&&!r&&(r=[]),typeof t!="function")return J(e,t,r,n);F(s=>J(e,t(),s,n),r)}function on(e,t,n,r,s={},o=!1){t||(t={});for(const l in s)if(!(l in t)){if(l==="children")continue;s[l]=He(e,l,null,s[l],n,o)}for(const l in t){if(l==="children"){r||J(e,t.children);continue}const i=t[l];s[l]=He(e,l,i,s[l],n,o)}}function ln(e,t,n={}){f.completed=globalThis._$HY.completed,f.events=globalThis._$HY.events,f.load=s=>globalThis._$HY.r[s],f.has=s=>s in globalThis._$HY.r,f.gather=s=>Be(t,s),f.registry=new Map,f.context={id:n.renderId||"",count:0},Be(t,n.renderId);const r=Zt(e,t,[...t.childNodes],n);return f.context=null,r}function cn(e){let t,n;return!f.context||!(t=f.registry.get(n=fn()))?e():(f.completed&&f.completed.add(t),f.registry.delete(n),t)}function yr(e){let t=e,n=0,r=[];if(f.context)for(;t;){if(t.nodeType===8){const s=t.nodeValue;if(s==="$")n++;else if(s==="/"){if(n===0)return[t,r];n--}}r.push(t),t=t.nextSibling}return[t,r]}function un(){f.events&&!f.events.queued&&(queueMicrotask(()=>{const{completed:e,events:t}=f;for(t.queued=!1;t.length;){const[n,r]=t[0];if(!e.has(n))return;ct(r),t.shift()}}),f.events.queued=!0)}function an(e){return e.toLowerCase().replace(/-([a-z])/g,(t,n)=>n.toUpperCase())}function qe(e,t,n){const r=t.trim().split(/\s+/);for(let s=0,o=r.length;s-1&&Jt[t.split(":")[0]];h?tn(e,h,t,n):Ce(e,zt[t]||t,n)}return n}function ct(e){const t=`$$${e.type}`;let n=e.composedPath&&e.composedPath()[0]||e.target;for(e.target!==n&&Object.defineProperty(e,"target",{configurable:!0,value:n}),Object.defineProperty(e,"currentTarget",{configurable:!0,get(){return n||document}}),f.registry&&!f.done&&(f.done=_$HY.done=!0);n;){const r=n[t];if(r&&!n.disabled){const s=n[`${t}Data`];if(s!==void 0?r.call(n,s,e):r.call(n,e),e.cancelBubble)return}n=n._$host||n.parentNode||n.host}}function J(e,t,n,r,s){if(f.context){!n&&(n=[...e.childNodes]);let i=[];for(let u=0;u{let i=t();for(;typeof i=="function";)i=i();n=J(e,i,n,r)}),()=>n;if(Array.isArray(t)){const i=[],u=n&&Array.isArray(n);if(ke(i,t,n,s))return F(()=>n=J(e,i,n,r,!0)),()=>n;if(f.context){if(!i.length)return n;if(r===void 0)return[...e.childNodes];let a=i[0],c=[a];for(;(a=a.nextSibling)!==r;)c.push(a);return n=c}if(i.length===0){if(n=Y(e,n,r),l)return n}else u?n.length===0?Ve(e,i,r):Qt(e,n,i):(n&&Y(e),Ve(e,i));n=i}else if(t.nodeType){if(f.context&&t.parentNode)return n=l?[t]:t;if(Array.isArray(n)){if(l)return n=Y(e,n,r,t);Y(e,n,null,t)}else n==null||n===""||!e.firstChild?e.appendChild(t):e.replaceChild(t,e.firstChild);n=t}}return n}function ke(e,t,n,r){let s=!1;for(let o=0,l=t.length;o=0;l--){const i=t[l];if(s!==i){const u=i.parentNode===e;!o&&!l?u?e.replaceChild(s,i):e.insertBefore(s,n):u&&i.remove()}else o=!0}}else e.insertBefore(s,n);return[s]}function Be(e,t){const n=e.querySelectorAll("*[data-hk]");for(let r=0;r{},ut=!1,gn=(...e)=>(qt(),ln(...e)),pn="modulepreload",mn=function(e){return"/"+e},Fe={},ve=function(t,n,r){if(!n||n.length===0)return t();const s=document.getElementsByTagName("link");return Promise.all(n.map(o=>{if(o=mn(o),o in Fe)return;Fe[o]=!0;const l=o.endsWith(".css"),i=l?'[rel="stylesheet"]':"";if(!!r)for(let c=s.length-1;c>=0;c--){const h=s[c];if(h.href===o&&(!l||h.rel==="stylesheet"))return}else if(document.querySelector(`link[href="proxy.php?url=https%3A%2F%2Fweb-scrobbler.github.io%2F%24%7Bo%7D"]${i}`))return;const a=document.createElement("link");if(a.rel=l?"stylesheet":pn,l||(a.as="script",a.crossOrigin=""),a.href=o,document.head.appendChild(a),l)return new Promise((c,h)=>{a.addEventListener("load",c),a.addEventListener("error",()=>h(new Error(`Unable to preload CSS for ${o}`)))})})).then(()=>t()).catch(o=>{const l=new Event("vite:preloadError",{cancelable:!0});if(l.payload=o,window.dispatchEvent(l),!l.defaultPrevented)throw o})};function yn(e,t){e&&t&&gn(e,t)}const Ne=Z(),wn=["title","meta"],Ue=[],Ke=["name","http-equiv","content","charset","media"].concat(["property"]),De=(e,t)=>{const n=Object.fromEntries(Object.entries(e.props).filter(([r])=>t.includes(r)).sort());return(Object.hasOwn(n,"name")||Object.hasOwn(n,"property"))&&(n.name=n.name||n.property,delete n.property),e.tag+JSON.stringify(n)},bn=e=>{if(!f.context){const s=document.head.querySelectorAll("[data-sm]");Array.prototype.forEach.call(s,o=>o.parentNode.removeChild(o))}const t=new Map;function n(s){if(s.ref)return s.ref;let o=document.querySelector(`[data-sm="${s.id}"]`);return o?(o.tagName.toLowerCase()!==s.tag&&(o.parentNode&&o.parentNode.removeChild(o),o=document.createElement(s.tag)),o.removeAttribute("data-sm")):o=document.createElement(s.tag),o}const r={addClientTag:s=>{if(wn.indexOf(s.tag)!==-1){const l=s.tag==="title"?Ue:Ke,i=De(s,l);t.has(i)||t.set(i,[]);let u=t.get(i),a=u.length;u=[...u,s],t.set(i,u);{let c=n(s);s.ref=c,ue(c,s.props);let h=null;for(var o=a-1;o>=0;o--)if(u[o]!=null){h=u[o];break}c.parentNode!=document.head&&document.head.appendChild(c),h&&h.ref&&document.head.removeChild(h.ref)}return a}{let l=n(s);s.ref=l,ue(l,s.props),l.parentNode!=document.head&&document.head.appendChild(l)}return-1},removeClientTag:(s,o)=>{const l=s.tag==="title"?Ue:Ke,i=De(s,l);if(s.ref){const u=t.get(i);if(u){if(s.ref.parentNode){s.ref.parentNode.removeChild(s.ref);for(let a=o-1;a>=0;a--)u[a]!=null&&document.head.appendChild(u[a].ref)}u[o]=null,t.set(i,u)}else s.ref.parentNode&&s.ref.parentNode.removeChild(s.ref)}}};return p(Ne.Provider,{value:r,get children(){return e.children}})},Oe=(e,t,n)=>{const r=Vt();if(!U(Ne))throw new Error(" should be in the tree");return xn({tag:e,props:t,setting:n,id:r,get name(){return t.name||t.property}}),null};function xn(e){const{addClientTag:t,removeClientTag:n,addServerTag:r}=U(Ne);F(()=>{{let s=t(e);Q(()=>n(e,s))}})}const Sn=e=>Oe("title",e,{escape:!0,close:!0}),_=e=>Oe("meta",e),oe=e=>Oe("link",e);function En(e,t,n){return e.addEventListener(t,n),()=>e.removeEventListener(t,n)}function vn([e,t],n,r){return[n?()=>n(e()):e,r?s=>t(r(s)):t]}function An(e){if(e==="#")return null;try{return document.querySelector(e)}catch{return null}}function Pn(e,t){const n=An(`#${e}`);n?n.scrollIntoView():t&&window.scrollTo(0,0)}function Cn(e,t,n,r){let s=!1;const o=i=>typeof i=="string"?{value:i}:i,l=vn(M(o(e()),{equals:(i,u)=>i.value===u.value}),void 0,i=>(!s&&t(i),i));return n&&Q(n((i=e())=>{s=!0,l[1](o(i)),s=!1})),{signal:l,utils:r}}function kn(e){if(e){if(Array.isArray(e))return{signal:e}}else return{signal:M({value:""})};return e}function Tn(){return Cn(()=>({value:window.location.pathname+window.location.search+window.location.hash,state:history.state}),({value:e,replace:t,scroll:n,state:r})=>{t?window.history.replaceState(r,"",e):window.history.pushState(r,"",e),Pn(window.location.hash.slice(1),n)},e=>En(window,"popstate",()=>e()),{go:e=>window.history.go(e)})}function $n(){let e=new Set;function t(s){return e.add(s),()=>e.delete(s)}let n=!1;function r(s,o){if(n)return!(n=!1);const l={to:s,options:o,defaultPrevented:!1,preventDefault:()=>l.defaultPrevented=!0};for(const i of e)i.listener({...l,from:i.location,retry:u=>{u&&(n=!0),i.navigate(s,o)}});return!l.defaultPrevented}return{subscribe:t,confirm:r}}const Nn=/^(?:[a-z0-9]+:)?\/\//i,On=/^\/+|(\/)\/+$/g;function le(e,t=!1){const n=e.replace(On,"$1");return n?t||/^[?#]/.test(n)?n:"/"+n:""}function he(e,t,n){if(Nn.test(t))return;const r=le(e),s=n&&le(n);let o="";return!s||t.startsWith("/")?o=r:s.toLowerCase().indexOf(r.toLowerCase())!==0?o=r+s:o=s,(o||"/")+le(t,!o)}function Ln(e,t){if(e==null)throw new Error(t);return e}function at(e,t){return le(e).replace(/\/*(\*.*)?$/g,"")+le(t)}function Rn(e){const t={};return e.searchParams.forEach((n,r)=>{t[r]=n}),t}function _n(e,t,n){const[r,s]=e.split("/*",2),o=r.split("/").filter(Boolean),l=o.length;return i=>{const u=i.split("/").filter(Boolean),a=u.length-l;if(a<0||a>0&&s===void 0&&!t)return null;const c={path:l?"":"/",params:{}},h=g=>n===void 0?void 0:n[g];for(let g=0;gr.localeCompare(e,void 0,{sensitivity:"base"})===0;return t===void 0?!0:typeof t=="string"?n(t):typeof t=="function"?t(e):Array.isArray(t)?t.some(n):t instanceof RegExp?t.test(e):!1}function In(e){const[t,n]=e.pattern.split("/*",2),r=t.split("/").filter(Boolean);return r.reduce((s,o)=>s+(o.startsWith(":")?2:3),r.length-(n===void 0?0:1))}function ft(e){const t=new Map,n=Je();return new Proxy({},{get(r,s){return t.has(s)||$t(n,()=>t.set(s,P(()=>e()[s]))),t.get(s)()},getOwnPropertyDescriptor(){return{enumerable:!0,configurable:!0}},ownKeys(){return Reflect.ownKeys(e())}})}function dt(e){let t=/(\/?\:[^\/]+)\?/.exec(e);if(!t)return[e];let n=e.slice(0,t.index),r=e.slice(t.index+t[0].length);const s=[n,n+=t[1]];for(;t=/^(\/\:[^\/]+)\?/.exec(r);)s.push(n+=t[1]),r=r.slice(t[0].length);return dt(r).reduce((o,l)=>[...o,...s.map(i=>i+l)],[])}const Mn=100,ht=Z(),xe=Z(),gt=()=>Ln(U(ht),"Make sure your app is wrapped in a ");let ae;const pt=()=>ae||U(xe)||gt().base;function jn(e,t="",n){const{component:r,data:s,children:o}=e,l=!o||Array.isArray(o)&&!o.length,i={key:e,element:r?()=>p(r,{}):()=>{const{element:u}=e;return u===void 0&&n?p(n,{}):u},preload:e.component?r.preload:e.preload,data:s};return mt(e.path).reduce((u,a)=>{for(const c of dt(a)){const h=at(t,c),g=l?h:h.split("/*",1)[0];u.push({...i,originalPath:c,pattern:g,matcher:_n(g,!l,e.matchFilters)})}return u},[])}function qn(e,t=0){return{routes:e,score:In(e[e.length-1])*1e4-t,matcher(n){const r=[];for(let s=e.length-1;s>=0;s--){const o=e[s],l=o.matcher(n);if(!l)return null;r.unshift({...l,route:o})}return r}}}function mt(e){return Array.isArray(e)?e:[e]}function yt(e,t="",n,r=[],s=[]){const o=mt(e);for(let l=0,i=o.length;li.score-l.score)}function Hn(e,t){for(let n=0,r=e.length;n{const a=e();try{return new URL(a,n)}catch{return console.error(`Invalid path ${a}`),u}},n,{equals:(u,a)=>u.href===a.href}),s=P(()=>r().pathname),o=P(()=>r().search,!0),l=P(()=>r().hash),i=P(()=>"");return{get pathname(){return s()},get search(){return o()},get hash(){return l()},get state(){return t()},get key(){return i()},query:ft(Ge(o,()=>Rn(r())))}}function Bn(e,t="",n,r){const{signal:[s,o],utils:l={}}=kn(e),i=l.parsePath||(v=>v),u=l.renderPath||(v=>v),a=l.beforeLeave||$n(),c=he("",t),h=void 0;if(c===void 0)throw new Error(`${c} is not a valid base path`);c&&!s().value&&o({value:c,replace:!0,scroll:!1});const[g,w]=M(!1),S=async v=>{w(!0);try{await Nt(v)}finally{w(!1)}},[b,k]=M(s().value),[T,C]=M(s().state),$=Vn(b,T),O=[],R={pattern:c,params:{},path:()=>c,outlet:()=>null,resolvePath(v){return he(c,v)}};if(n)try{ae=R,R.data=n({data:void 0,params:{},location:$,navigate:te(R)})}finally{ae=void 0}function H(v,m,x){N(()=>{if(typeof m=="number"){m&&(l.go?a.confirm(m,x)&&l.go(m):console.warn("Router integration does not support relative routing"));return}const{replace:A,resolve:V,scroll:K,state:re}={replace:!1,resolve:!0,scroll:!0,...x},D=V?v.resolvePath(m):he("",m);if(D===void 0)throw new Error(`Path '${m}' is not a routable path`);if(O.length>=Mn)throw new Error("Too many redirects");const se=b();if((D!==se||re!==T())&&!ut){if(a.confirm(D,x)){const xt=O.push({value:se,replace:A,scroll:K,state:T()});S(()=>{k(D),C(re),it()}).then(()=>{O.length===xt&&ne({value:D,state:re})})}}})}function te(v){return v=v||U(xe)||R,(m,x)=>H(v,m,x)}function ne(v){const m=O[0];m&&((v.value!==m.value||v.state!==m.state)&&o({...v,replace:m.replace,scroll:m.scroll}),O.length=0)}F(()=>{const{value:v,state:m}=s();N(()=>{v!==b()&&S(()=>{k(v),C(m)})})});{let v=function(m){if(m.defaultPrevented||m.button!==0||m.metaKey||m.altKey||m.ctrlKey||m.shiftKey)return;const x=m.composedPath().find(se=>se instanceof Node&&se.nodeName.toUpperCase()==="A");if(!x||!x.hasAttribute("link"))return;const A=x.href;if(x.target||!A&&!x.hasAttribute("state"))return;const V=(x.getAttribute("rel")||"").split(/\s+/);if(x.hasAttribute("download")||V&&V.includes("external"))return;const K=new URL(A);if(K.origin!==window.location.origin||c&&K.pathname&&!K.pathname.toLowerCase().startsWith(c.toLowerCase()))return;const re=i(K.pathname+K.search+K.hash),D=x.getAttribute("state");m.preventDefault(),H(R,re,{resolve:!1,replace:x.hasAttribute("replace"),scroll:!x.hasAttribute("noscroll"),state:D&&JSON.parse(D)})};$e(["click"]),document.addEventListener("click",v),Q(()=>document.removeEventListener("click",v))}return{base:R,out:h,location:$,isRouting:g,renderPath:u,parsePath:i,navigatorFactory:te,beforeLeave:a}}function Fn(e,t,n,r,s){const{base:o,location:l,navigatorFactory:i}=e,{pattern:u,element:a,preload:c,data:h}=r().route,g=P(()=>r().path);c&&c();const w={parent:t,pattern:u,get child(){return n()},path:g,params:s,data:t.data,outlet:a,resolvePath(S){return he(o.path(),S,g())}};if(h)try{ae=w,w.data=h({data:t.data,params:s,location:l,navigate:i(w)})}finally{ae=void 0}return w}const Un=e=>{const{source:t,url:n,base:r,data:s,out:o}=e,l=t||Tn(),i=Bn(l,r,s);return p(ht.Provider,{value:i,get children(){return e.children}})},Kn=e=>{const t=gt(),n=pt(),r=be(()=>e.children),s=P(()=>yt(r(),at(n.pattern,e.base||""),Dn)),o=P(()=>Hn(s(),t.location.pathname)),l=ft(()=>{const c=o(),h={};for(let g=0;g({originalPath:c.originalPath,pattern:c.pattern,path:h,params:g})));const i=[];let u;const a=P(Ge(o,(c,h,g)=>{let w=h&&c.length===h.length;const S=[];for(let b=0,k=c.length;b{i[b]=$,S[b]=Fn(t,S[b-1]||n,()=>a()[b+1],()=>o()[b],l)}))}return i.splice(c.length).forEach(b=>b()),g&&w?g:(u=S[0],S)}));return p(Te,{get when(){return a()&&u},keyed:!0,children:c=>p(xe.Provider,{value:c,get children(){return c.outlet()}})})},Dn=()=>{const e=pt();return p(Te,{get when(){return e.child},keyed:!0,children:t=>p(xe.Provider,{value:t,get children(){return t.outlet()}})})},Wn=[{component:Ee(()=>ve(()=>import("./_...404_-680847c9.js"),[])),path:"/*404"},{component:Ee(()=>ve(()=>import("./index-1aa77787.js"),["assets/index-1aa77787.js","assets/styles.module-fb889907.js","assets/styles-0daa483c.css"])),path:"/"},{component:Ee(()=>ve(()=>import("./webhook-b3c6b55f.js"),["assets/webhook-b3c6b55f.js","assets/styles.module-fb889907.js","assets/styles-0daa483c.css"])),path:"/webhook"}],zn=()=>Wn,wt=Z({}),Yn=Kn,Xn="$FETCH",Gn=en('

');function Jn(e){return p(Bt,{fallback:(t,n)=>p(Te,{get when(){return!e.fallback},get fallback(){return P(()=>!!e.fallback)()&&e.fallback(t,n)},get children(){return p(Qn,{error:t})}}),get children(){return e.children}})}function Qn(e){return Xe(()=>console.error(e.error)),(()=>{const t=cn(Gn),n=t.firstChild,r=n.firstChild,s=r.nextSibling,o=s.nextSibling;return t.style.setProperty("padding","16px"),n.style.setProperty("background-color","rgba(252, 165, 165)"),n.style.setProperty("color","rgb(153, 27, 27)"),n.style.setProperty("border-radius","5px"),n.style.setProperty("overflow","scroll"),n.style.setProperty("padding","16px"),n.style.setProperty("margin-bottom","8px"),r.style.setProperty("font-weight","bold"),ye(r,()=>e.error.message),lt(s,"click",it,!0),s.style.setProperty("color","rgba(252, 165, 165)"),s.style.setProperty("background-color","rgb(153, 27, 27)"),s.style.setProperty("border-radius","5px"),s.style.setProperty("padding","4px 8px"),o.style.setProperty("margin-top","8px"),o.style.setProperty("width","100%"),ye(o,()=>e.error.stack),un(),t})()}$e(["click"]);const Zn=!1,er=!1;function tr(){return U(wt),[p(hn,{}),er,p(dn,{get children(){return ut}}),Zn]}function nr(e){return ue(document.documentElement,e,!1,!0),e.children}function rr(e){return ue(document.head,e,!1,!0),e.children}function sr(e){{let t=be(()=>e.children);return ue(document.body,e,!1,!0),ye(document.body,()=>{let n=t();if(n){if(Array.isArray(n)){let r=n.filter(s=>!!s);return r.length?r:null}return n}return null},null,[...document.body.childNodes]),document.body}}function or(){return[p(_,{name:"title",content:"Web Scrobbler — Scrobble music all around the web!"}),p(_,{name:"description",content:"Web Scrobbler helps music listeners to scrobble their online playback history."}),p(_,{property:"og:type",content:"website"}),p(_,{property:"og:url",content:"https://webscrobbler.com/"}),p(_,{property:"og:title",content:"Web Scrobbler — Scrobble music all around the web!"}),p(_,{property:"og:description",content:"Web Scrobbler helps music listeners to scrobble their online playback history."}),p(_,{property:"og:image",content:"https://raw.githubusercontent.com/web-scrobbler/media-resources/master/images/social-media-preview.png"}),p(_,{property:"twitter:card",content:"summary_large_image"}),p(_,{property:"twitter:url",content:"https://webscrobbler.com/"}),p(_,{property:"twitter:title",content:"Web Scrobbler — Scrobble music all around the web!"}),p(_,{property:"twitter:description",content:"Web Scrobbler helps music listeners to scrobble their online playback history."}),p(_,{property:"twitter:image",content:"https://raw.githubusercontent.com/web-scrobbler/media-resources/master/images/social-media-preview.png"})]}function ir(){return[p(oe,{rel:"apple-touch-icon",sizes:"180x180",href:"/apple-touch-icon.png"}),p(oe,{rel:"icon",type:"image/png",sizes:"32x32",href:"/favicon-32x32.png"}),p(oe,{rel:"icon",type:"image/png",sizes:"16x16",href:"/favicon-16x16.png"}),p(oe,{rel:"manifest",href:"/site.webmanifest"}),p(oe,{rel:"mask-icon",href:"/safari-pinned-tab.svg",color:"#5bbad5"}),p(_,{name:"msapplication-TileColor",content:"#fd3148"}),p(_,{name:"theme-color",content:"#fd3148"})]}function lr(){return window.scrollY/(document.body.scrollHeight-window.innerHeight)}function cr(){return kt(()=>{const e=()=>{const t=lr();document.body.style.setProperty("--scrollPct",t.toString())};return e(),document.addEventListener("scroll",e),()=>document.removeEventListener("scroll",e)}),p(nr,{lang:"en",get children(){return[p(rr,{get children(){return[p(Sn,{children:"Web Scrobbler — Scrobble music all around the web!"}),p(or,{}),p(_,{charset:"utf-8"}),p(_,{name:"viewport",content:"initial-scale=1.0,width=device-width"}),p(ir,{})]}}),p(sr,{get children(){return[p(Ut,{get children(){return p(Jn,{get children(){return p(Yn,{get children(){return p(zn,{})}})}})}}),p(tr,{})]}})]}})}const We=Object.values(Object.assign({}))[0],ur=We?We.default:void 0,ar=()=>{let e={get request(){},get clientAddress(){},get locals(){},get prevUrl(){},get responseHeaders(){},get tags(){},get env(){},get routerContext(){},setStatusCode(n){},getStatusCode(){},$type:Xn,fetch};function t(n){return p(Un,n)}return p(wt.Provider,{value:e,get children(){return p(bn,{get children(){return p(t,{get base(){return"/"},data:ur,get children(){return p(cr,{})}})}})}})};function fr(){const e=localStorage.getItem("theme");if(e){document.body.classList.add(bt(e));return}dr("theme-system")}async function dr(e){document.body.className="",document.body.classList.add(await bt(e)),await localStorage.setItem("theme",e)}function bt(e){return e==="theme-system"?window.matchMedia("(prefers-color-scheme: dark)").matches?"theme-dark":"theme-light":e}yn(()=>p(ar,{}),document);fr();export{gr as F,mr as M,wt as S,Sn as T,yr as a,F as b,p as c,M as d,Te as e,$e as f,cn as g,nn as h,ye as i,kt as j,pr as k,Q as o,un as r,Ce as s,en as t,U as u};