@htmlbricks/hb-downloader 0.66.1 → 0.66.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/main.iife.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
(function(Nt){"use strict";typeof window<"u"&&((window.__svelte??={}).v??=new Set).add("5");const Bn=1,Un=2,kt="[",At="[!",St="[?",Ct="]",ye={},S=Symbol(),Rt="http://www.w3.org/1999/xhtml",Vn=!1;var Yn=Array.isArray,zn=Array.prototype.indexOf,$e=Array.prototype.includes,Wn=Array.from,Ye=Object.keys,ze=Object.defineProperty,Ee=Object.getOwnPropertyDescriptor,Gn=Object.getOwnPropertyDescriptors,Jn=Object.prototype,Kn=Array.prototype,Ot=Object.getPrototypeOf,Mt=Object.isExtensible;const Xn=()=>{};function Zn(e){for(var t=0;t<e.length;t++)e[t]()}function Lt(){var e,t,n=new Promise((r,i)=>{e=r,t=i});return{promise:n,resolve:e,reject:t}}const A=2,Te=4,We=8,Dt=1<<24,ee=16,Y=32,te=64,st=128,P=512,k=1024,C=2048,z=4096,W=8192,B=16384,ne=32768,jt=1<<25,xe=65536,Pt=1<<17,Qn=1<<18,he=1<<19,er=1<<20,ve=65536,ot=1<<21,lt=1<<22,re=1<<23,at=Symbol("$state"),tr=Symbol("legacy props"),nr=Symbol(""),K=new class extends Error{name="StaleReactionError";message="The reaction that called `getAbortSignal()` was re-run or destroyed"},rr=!!globalThis.document?.contentType&&globalThis.document.contentType.includes("xml"),ft=3,Ge=8;function ir(){throw new Error("https://svelte.dev/e/async_derived_orphan")}function sr(e){throw new Error("https://svelte.dev/e/effect_in_teardown")}function or(){throw new Error("https://svelte.dev/e/effect_in_unowned_derived")}function lr(e){throw new Error("https://svelte.dev/e/effect_orphan")}function ar(){throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}function fr(){throw new Error("https://svelte.dev/e/hydration_failed")}function ur(){throw new Error("https://svelte.dev/e/state_descriptors_fixed")}function cr(){throw new Error("https://svelte.dev/e/state_prototype_fixed")}function dr(){throw new Error("https://svelte.dev/e/state_unsafe_mutation")}function hr(){throw new Error("https://svelte.dev/e/svelte_boundary_reset_onerror")}function Je(e){console.warn("https://svelte.dev/e/hydration_mismatch")}function vr(){console.warn("https://svelte.dev/e/svelte_boundary_reset_noop")}let m=!1;function ie(e){m=e}let T;function G(e){if(e===null)throw Je(),ye;return T=e}function Ke(){return G(fe(T))}function Me(e){if(m){if(fe(T)!==null)throw Je(),ye;T=e}}function It(e=1){if(m){for(var t=e,n=T;t--;)n=fe(n);T=n}}function Ft(e=!0){for(var t=0,n=T;;){if(n.nodeType===Ge){var r=n.data;if(r===Ct){if(t===0)return n;t-=1}else(r===kt||r===At||r[0]==="["&&!isNaN(Number(r.slice(1))))&&(t+=1)}var i=fe(n);e&&n.remove(),n=i}}function _r(e){if(!e||e.nodeType!==Ge)throw Je(),ye;return e.data}function Ht(e){return e===this.v}function pr(e,t){return e!=e?t==t:e!==t||e!==null&&typeof e=="object"||typeof e=="function"}function gr(e){return!pr(e,this.v)}let wr=!1,I=null;function Ne(e){I=e}function qt(e,t=!1,n){I={p:I,i:!1,c:null,e:null,s:e,x:null,r:g,l:null}}function Bt(e){var t=I,n=t.e;if(n!==null){t.e=null;for(var r of n)hn(r)}return e!==void 0&&(t.x=e),t.i=!0,I=t.p,e??{}}function Ut(){return!0}let _e=[];function Vt(){var e=_e;_e=[],Zn(e)}function pe(e){if(_e.length===0&&!Le){var t=_e;queueMicrotask(()=>{t===_e&&Vt()})}_e.push(e)}function br(){for(;_e.length>0;)Vt()}function Yt(e){var t=g;if(t===null)return p.f|=re,e;if((t.f&ne)===0&&(t.f&Te)===0)throw e;se(e,t)}function se(e,t){for(;t!==null;){if((t.f&st)!==0){if((t.f&ne)===0)throw e;try{t.b.error(e);return}catch(n){e=n}}t=t.parent}throw e}const mr=-7169;function x(e,t){e.f=e.f&mr|t}function ut(e){(e.f&P)!==0||e.deps===null?x(e,k):x(e,z)}function zt(e){if(e!==null)for(const t of e)(t.f&A)===0||(t.f&ve)===0||(t.f^=ve,zt(t.deps))}function Wt(e,t,n){(e.f&C)!==0?t.add(e):(e.f&z)!==0&&n.add(e),zt(e.deps),x(e,k)}const oe=new Set;let $=null,U=null,ct=null,Le=!1,dt=!1,ke=null,Xe=null;var Gt=0;let yr=1;class X{id=yr++;current=new Map;previous=new Map;#e=new Set;#n=new Set;#t=new Map;#i=new Map;#s=null;#r=[];#o=new Set;#l=new Set;#a=new Map;is_fork=!1;#c=!1;#f=new Set;#d(){return this.is_fork||this.#i.size>0}#v(){for(const r of this.#f)for(const i of r.#i.keys()){for(var t=!1,n=i;n.parent!==null;){if(this.#a.has(n)){t=!0;break}n=n.parent}if(!t)return!0}return!1}skip_effect(t){this.#a.has(t)||this.#a.set(t,{d:[],m:[]})}unskip_effect(t){var n=this.#a.get(t);if(n){this.#a.delete(t);for(var r of n.d)x(r,C),this.schedule(r);for(r of n.m)x(r,z),this.schedule(r)}}#h(){if(Gt++>1e3&&(oe.delete(this),$r()),!this.#d()){for(const l of this.#o)this.#l.delete(l),x(l,C),this.schedule(l);for(const l of this.#l)x(l,z),this.schedule(l)}const t=this.#r;this.#r=[],this.apply();var n=ke=[],r=[],i=Xe=[];for(const l of t)try{this.#u(l,n,r)}catch(a){throw Qt(l),a}if($=null,i.length>0){var s=X.ensure();for(const l of i)s.schedule(l)}if(ke=null,Xe=null,this.#d()||this.#v()){this.#_(r),this.#_(n);for(const[l,a]of this.#a)Zt(l,a)}else{this.#t.size===0&&oe.delete(this),this.#o.clear(),this.#l.clear();for(const l of this.#e)l(this);this.#e.clear(),Jt(r),Jt(n),this.#s?.resolve()}var o=$;if(this.#r.length>0){const l=o??=this;l.#r.push(...this.#r.filter(a=>!l.#r.includes(a)))}o!==null&&(oe.add(o),o.#h()),oe.has(this)||this.#p()}#u(t,n,r){t.f^=k;for(var i=t.first;i!==null;){var s=i.f,o=(s&(Y|te))!==0,l=o&&(s&k)!==0,a=l||(s&W)!==0||this.#a.has(i);if(!a&&i.fn!==null){o?i.f^=k:(s&Te)!==0?n.push(i):qe(i)&&((s&ee)!==0&&this.#l.add(i),Se(i));var f=i.first;if(f!==null){i=f;continue}}for(;i!==null;){var u=i.next;if(u!==null){i=u;break}i=i.parent}}}#_(t){for(var n=0;n<t.length;n+=1)Wt(t[n],this.#o,this.#l)}capture(t,n,r=!1){n!==S&&!this.previous.has(t)&&this.previous.set(t,n),(t.f&re)===0&&(this.current.set(t,[t.v,r]),U?.set(t,t.v))}activate(){$=this}deactivate(){$=null,U=null}flush(){try{dt=!0,$=this,this.#h()}finally{Gt=0,ct=null,ke=null,Xe=null,dt=!1,$=null,U=null,le.clear()}}discard(){for(const t of this.#n)t(this);this.#n.clear(),oe.delete(this)}#p(){for(const f of oe){var t=f.id<this.id,n=[];for(const[u,[d,c]]of this.current){if(f.current.has(u)){var r=f.current.get(u)[0];if(t&&d!==r)f.current.set(u,[d,c]);else continue}n.push(u)}var i=[...f.current.keys()].filter(u=>!this.current.has(u));if(i.length===0)t&&f.discard();else if(n.length>0){f.activate();var s=new Set,o=new Map;for(var l of n)Kt(l,i,s,o);if(f.#r.length>0){f.apply();for(var a of f.#r)f.#u(a,[],[]);f.#r=[]}f.deactivate()}}for(const f of oe)f.#f.has(this)&&(f.#f.delete(this),f.#f.size===0&&!f.#d()&&(f.activate(),f.#h()))}increment(t,n){let r=this.#t.get(n)??0;if(this.#t.set(n,r+1),t){let i=this.#i.get(n)??0;this.#i.set(n,i+1)}}decrement(t,n,r){let i=this.#t.get(n)??0;if(i===1?this.#t.delete(n):this.#t.set(n,i-1),t){let s=this.#i.get(n)??0;s===1?this.#i.delete(n):this.#i.set(n,s-1)}this.#c||r||(this.#c=!0,pe(()=>{this.#c=!1,this.flush()}))}transfer_effects(t,n){for(const r of t)this.#o.add(r);for(const r of n)this.#l.add(r);t.clear(),n.clear()}oncommit(t){this.#e.add(t)}ondiscard(t){this.#n.add(t)}settled(){return(this.#s??=Lt()).promise}static ensure(){if($===null){const t=$=new X;dt||(oe.add($),Le||pe(()=>{$===t&&t.flush()}))}return $}apply(){{U=null;return}}schedule(t){if(ct=t,t.b?.is_pending&&(t.f&(Te|We|Dt))!==0&&(t.f&ne)===0){t.b.defer_effect(t);return}for(var n=t;n.parent!==null;){n=n.parent;var r=n.f;if(ke!==null&&n===g&&(p===null||(p.f&A)===0))return;if((r&(te|Y))!==0){if((r&k)===0)return;n.f^=k}}this.#r.push(n)}}function Ae(e){var t=Le;Le=!0;try{for(var n;;){if(br(),$===null)return n;$.flush()}}finally{Le=t}}function $r(){try{ar()}catch(e){se(e,ct)}}let Z=null;function Jt(e){var t=e.length;if(t!==0){for(var n=0;n<t;){var r=e[n++];if((r.f&(B|W))===0&&qe(r)&&(Z=new Set,Se(r),r.deps===null&&r.first===null&&r.nodes===null&&r.teardown===null&&r.ac===null&&gn(r),Z?.size>0)){le.clear();for(const i of Z){if((i.f&(B|W))!==0)continue;const s=[i];let o=i.parent;for(;o!==null;)Z.has(o)&&(Z.delete(o),s.push(o)),o=o.parent;for(let l=s.length-1;l>=0;l--){const a=s[l];(a.f&(B|W))===0&&Se(a)}}Z.clear()}}Z=null}}function Kt(e,t,n,r){if(!n.has(e)&&(n.add(e),e.reactions!==null))for(const i of e.reactions){const s=i.f;(s&A)!==0?Kt(i,t,n,r):(s&(lt|ee))!==0&&(s&C)===0&&Xt(i,t,r)&&(x(i,C),ht(i))}}function Xt(e,t,n){const r=n.get(e);if(r!==void 0)return r;if(e.deps!==null)for(const i of e.deps){if($e.call(t,i))return!0;if((i.f&A)!==0&&Xt(i,t,n))return n.set(i,!0),!0}return n.set(e,!1),!1}function ht(e){$.schedule(e)}function Zt(e,t){if(!((e.f&Y)!==0&&(e.f&k)!==0)){(e.f&C)!==0?t.d.push(e):(e.f&z)!==0&&t.m.push(e),x(e,k);for(var n=e.first;n!==null;)Zt(n,t),n=n.next}}function Qt(e){x(e,k);for(var t=e.first;t!==null;)Qt(t),t=t.next}function Er(e){let t=0,n=De(0),r;return()=>{bt()&&(_(n),vn(()=>(t===0&&(r=Xr(()=>e(()=>je(n)))),t+=1,()=>{pe(()=>{t-=1,t===0&&(r?.(),r=void 0,je(n))})})))}}var Tr=xe|he;function xr(e,t,n,r){new Nr(e,t,n,r)}class Nr{parent;is_pending=!1;transform_error;#e;#n=m?T:null;#t;#i;#s;#r=null;#o=null;#l=null;#a=null;#c=0;#f=0;#d=!1;#v=new Set;#h=new Set;#u=null;#_=Er(()=>(this.#u=De(this.#c),()=>{this.#u=null}));constructor(t,n,r,i){this.#e=t,this.#t=n,this.#i=s=>{var o=g;o.b=this,o.f|=st,r(s)},this.parent=g.b,this.transform_error=i??this.parent?.transform_error??(s=>s),this.#s=_n(()=>{if(m){const s=this.#n;Ke();const o=s.data===At;if(s.data.startsWith(St)){const a=JSON.parse(s.data.slice(St.length));this.#y(a)}else o?this.#$():this.#p()}else this.#b()},Tr),m&&(this.#e=T)}#p(){try{this.#r=Q(()=>this.#i(this.#e))}catch(t){this.error(t)}}#y(t){const n=this.#t.failed;n&&(this.#l=Q(()=>{n(this.#e,()=>t,()=>()=>{})}))}#$(){const t=this.#t.pending;t&&(this.is_pending=!0,this.#o=Q(()=>t(this.#e)),pe(()=>{var n=this.#a=document.createDocumentFragment(),r=ae();n.append(r),this.#r=this.#w(()=>Q(()=>this.#i(r))),this.#f===0&&(this.#e.before(n),this.#a=null,He(this.#o,()=>{this.#o=null}),this.#g($))}))}#b(){try{if(this.is_pending=this.has_pending_snippet(),this.#f=0,this.#c=0,this.#r=Q(()=>{this.#i(this.#e)}),this.#f>0){var t=this.#a=document.createDocumentFragment();mn(this.#r,t);const n=this.#t.pending;this.#o=Q(()=>n(this.#e))}else this.#g($)}catch(n){this.error(n)}}#g(t){this.is_pending=!1,t.transfer_effects(this.#v,this.#h)}defer_effect(t){Wt(t,this.#v,this.#h)}is_rendered(){return!this.is_pending&&(!this.parent||this.parent.is_rendered())}has_pending_snippet(){return!!this.#t.pending}#w(t){var n=g,r=p,i=I;F(this.#s),M(this.#s),Ne(this.#s.ctx);try{return X.ensure(),t()}catch(s){return Yt(s),null}finally{F(n),M(r),Ne(i)}}#m(t,n){if(!this.has_pending_snippet()){this.parent&&this.parent.#m(t,n);return}this.#f+=t,this.#f===0&&(this.#g(n),this.#o&&He(this.#o,()=>{this.#o=null}),this.#a&&(this.#e.before(this.#a),this.#a=null))}update_pending_count(t,n){this.#m(t,n),this.#c+=t,!(!this.#u||this.#d)&&(this.#d=!0,pe(()=>{this.#d=!1,this.#u&&Qe(this.#u,this.#c)}))}get_effect_pending(){return this.#_(),_(this.#u)}error(t){var n=this.#t.onerror;let r=this.#t.failed;if(!n&&!r)throw t;this.#r&&(O(this.#r),this.#r=null),this.#o&&(O(this.#o),this.#o=null),this.#l&&(O(this.#l),this.#l=null),m&&(G(this.#n),It(),G(Ft()));var i=!1,s=!1;const o=()=>{if(i){vr();return}i=!0,s&&hr(),this.#l!==null&&He(this.#l,()=>{this.#l=null}),this.#w(()=>{this.#b()})},l=a=>{try{s=!0,n?.(a,o),s=!1}catch(f){se(f,this.#s&&this.#s.parent)}r&&(this.#l=this.#w(()=>{try{return Q(()=>{var f=g;f.b=this,f.f|=st,r(this.#e,()=>a,()=>o)})}catch(f){return se(f,this.#s.parent),null}}))};pe(()=>{var a;try{a=this.transform_error(t)}catch(f){se(f,this.#s&&this.#s.parent);return}a!==null&&typeof a=="object"&&typeof a.then=="function"?a.then(l,f=>se(f,this.#s&&this.#s.parent)):l(a)})}}function kr(e,t,n,r){const i=tn;var s=e.filter(c=>!c.settled);if(n.length===0&&s.length===0){r(t.map(i));return}var o=g,l=Ar(),a=s.length===1?s[0].promise:s.length>1?Promise.all(s.map(c=>c.promise)):null;function f(c){l();try{r(c)}catch(v){(o.f&B)===0&&se(v,o)}Ze()}if(n.length===0){a.then(()=>f(t.map(i)));return}var u=en();function d(){Promise.all(n.map(c=>Sr(c))).then(c=>f([...t.map(i),...c])).catch(c=>se(c,o)).finally(()=>u())}a?a.then(()=>{l(),d(),Ze()}):d()}function Ar(){var e=g,t=p,n=I,r=$;return function(s=!0){F(e),M(t),Ne(n),s&&(e.f&B)===0&&(r?.activate(),r?.apply())}}function Ze(e=!0){F(null),M(null),Ne(null),e&&$?.deactivate()}function en(){var e=g,t=e.b,n=$,r=t.is_rendered();return t.update_pending_count(1,n),n.increment(r,e),(i=!1)=>{t.update_pending_count(-1,n),n.decrement(r,e,i)}}function tn(e){var t=A|C,n=p!==null&&(p.f&A)!==0?p:null;return g!==null&&(g.f|=he),{ctx:I,deps:null,effects:null,equals:Ht,f:t,fn:e,reactions:null,rv:0,v:S,wv:0,parent:n??g,ac:null}}function Sr(e,t,n){let r=g;r===null&&ir();var i=void 0,s=De(S),o=!p,l=new Map;return Vr(()=>{var a=g,f=Lt();i=f.promise;try{Promise.resolve(e()).then(f.resolve,f.reject).finally(Ze)}catch(v){f.reject(v),Ze()}var u=$;if(o){if((a.f&ne)!==0)var d=en();if(r.b.is_rendered())l.get(u)?.reject(K),l.delete(u);else{for(const v of l.values())v.reject(K);l.clear()}l.set(u,f)}const c=(v,h=void 0)=>{if(d){var y=h===K;d(y)}if(!(h===K||(a.f&B)!==0)){if(u.activate(),h)s.f|=re,Qe(s,h);else{(s.f&re)!==0&&(s.f^=re),Qe(s,v);for(const[E,R]of l){if(l.delete(E),E===u)break;R.reject(K)}}u.deactivate()}};f.promise.then(c,v=>c(null,v||"unknown"))}),dn(()=>{for(const a of l.values())a.reject(K)}),new Promise(a=>{function f(u){function d(){u===i?a(s):f(i)}u.then(d,d)}f(i)})}function Cr(e){var t=e.effects;if(t!==null){e.effects=null;for(var n=0;n<t.length;n+=1)O(t[n])}}function Rr(e){for(var t=e.parent;t!==null;){if((t.f&A)===0)return(t.f&B)===0?t:null;t=t.parent}return null}function vt(e){var t,n=g;F(Rr(e));try{e.f&=~ve,Cr(e),t=Nn(e)}finally{F(n)}return t}function nn(e){var t=e.v,n=vt(e);if(!e.equals(n)&&(e.wv=Tn(),(!$?.is_fork||e.deps===null)&&(e.v=n,$?.capture(e,t,!0),e.deps===null))){x(e,k);return}ue||(U!==null?(bt()||$?.is_fork)&&U.set(e,n):ut(e))}function Or(e){if(e.effects!==null)for(const t of e.effects)(t.teardown||t.ac)&&(t.teardown?.(),t.ac?.abort(K),t.teardown=Xn,t.ac=null,Be(t,0),mt(t))}function rn(e){if(e.effects!==null)for(const t of e.effects)t.teardown&&Se(t)}let _t=new Set;const le=new Map;let sn=!1;function De(e,t){var n={f:0,v:e,reactions:null,equals:Ht,rv:0,wv:0};return n}function D(e,t){const n=De(e);return Gr(n),n}function Mr(e,t=!1,n=!0){const r=De(e);return t||(r.equals=gr),r}function N(e,t,n=!1){p!==null&&(!V||(p.f&Pt)!==0)&&Ut()&&(p.f&(A|ee|lt|Pt))!==0&&(H===null||!$e.call(H,e))&&dr();let r=n?Pe(t):t;return Qe(e,r,Xe)}function Qe(e,t,n=null){if(!e.equals(t)){var r=e.v;ue?le.set(e,t):le.set(e,r),e.v=t;var i=X.ensure();if(i.capture(e,r),(e.f&A)!==0){const s=e;(e.f&C)!==0&&vt(s),U===null&&ut(s)}e.wv=Tn(),on(e,C,n),g!==null&&(g.f&k)!==0&&(g.f&(Y|te))===0&&(q===null?Jr([e]):q.push(e)),!i.is_fork&&_t.size>0&&!sn&&Lr()}return t}function Lr(){sn=!1;for(const e of _t)(e.f&k)!==0&&x(e,z),qe(e)&&Se(e);_t.clear()}function je(e){N(e,e.v+1)}function on(e,t,n){var r=e.reactions;if(r!==null)for(var i=r.length,s=0;s<i;s++){var o=r[s],l=o.f,a=(l&C)===0;if(a&&x(o,t),(l&A)!==0){var f=o;U?.delete(f),(l&ve)===0&&(l&P&&(o.f|=ve),on(f,z,n))}else if(a){var u=o;(l&ee)!==0&&Z!==null&&Z.add(u),n!==null?n.push(u):ht(u)}}}function Pe(e){if(typeof e!="object"||e===null||at in e)return e;const t=Ot(e);if(t!==Jn&&t!==Kn)return e;var n=new Map,r=Yn(e),i=D(0),s=we,o=l=>{if(we===s)return l();var a=p,f=we;M(null),En(s);var u=l();return M(a),En(f),u};return r&&n.set("length",D(e.length)),new Proxy(e,{defineProperty(l,a,f){(!("value"in f)||f.configurable===!1||f.enumerable===!1||f.writable===!1)&&ur();var u=n.get(a);return u===void 0?o(()=>{var d=D(f.value);return n.set(a,d),d}):N(u,f.value,!0),!0},deleteProperty(l,a){var f=n.get(a);if(f===void 0){if(a in l){const u=o(()=>D(S));n.set(a,u),je(i)}}else N(f,S),je(i);return!0},get(l,a,f){if(a===at)return e;var u=n.get(a),d=a in l;if(u===void 0&&(!d||Ee(l,a)?.writable)&&(u=o(()=>{var v=Pe(d?l[a]:S),h=D(v);return h}),n.set(a,u)),u!==void 0){var c=_(u);return c===S?void 0:c}return Reflect.get(l,a,f)},getOwnPropertyDescriptor(l,a){var f=Reflect.getOwnPropertyDescriptor(l,a);if(f&&"value"in f){var u=n.get(a);u&&(f.value=_(u))}else if(f===void 0){var d=n.get(a),c=d?.v;if(d!==void 0&&c!==S)return{enumerable:!0,configurable:!0,value:c,writable:!0}}return f},has(l,a){if(a===at)return!0;var f=n.get(a),u=f!==void 0&&f.v!==S||Reflect.has(l,a);if(f!==void 0||g!==null&&(!u||Ee(l,a)?.writable)){f===void 0&&(f=o(()=>{var c=u?Pe(l[a]):S,v=D(c);return v}),n.set(a,f));var d=_(f);if(d===S)return!1}return u},set(l,a,f,u){var d=n.get(a),c=a in l;if(r&&a==="length")for(var v=f;v<d.v;v+=1){var h=n.get(v+"");h!==void 0?N(h,S):v in l&&(h=o(()=>D(S)),n.set(v+"",h))}if(d===void 0)(!c||Ee(l,a)?.writable)&&(d=o(()=>D(void 0)),N(d,Pe(f)),n.set(a,d));else{c=d.v!==S;var y=o(()=>Pe(f));N(d,y)}var E=Reflect.getOwnPropertyDescriptor(l,a);if(E?.set&&E.set.call(u,f),!c){if(r&&typeof a=="string"){var R=n.get("length"),ce=Number(a);Number.isInteger(ce)&&ce>=R.v&&N(R,ce+1)}je(i)}return!0},ownKeys(l){_(i);var a=Reflect.ownKeys(l).filter(d=>{var c=n.get(d);return c===void 0||c.v!==S});for(var[f,u]of n)u.v!==S&&!(f in l)&&a.push(f);return a},setPrototypeOf(){cr()}})}var ln,an,fn,un;function pt(){if(ln===void 0){ln=window,an=/Firefox/.test(navigator.userAgent);var e=Element.prototype,t=Node.prototype,n=Text.prototype;fn=Ee(t,"firstChild").get,un=Ee(t,"nextSibling").get,Mt(e)&&(e.__click=void 0,e.__className=void 0,e.__attributes=null,e.__style=void 0,e.__e=void 0),Mt(n)&&(n.__t=void 0)}}function ae(e=""){return document.createTextNode(e)}function Ie(e){return fn.call(e)}function fe(e){return un.call(e)}function Fe(e,t){if(!m)return Ie(e);var n=Ie(T);return n===null&&(n=T.appendChild(ae())),G(n),n}function Dr(e,t=1,n=!1){let r=m?T:e;for(var i;t--;)i=r,r=fe(r);if(!m)return r;if(n){if(r?.nodeType!==ft){var s=ae();return r===null?i?.after(s):r.before(s),G(s),s}cn(r)}return G(r),r}function jr(e){e.textContent=""}function Pr(){return!1}function gt(e,t,n){return document.createElementNS(Rt,e,void 0)}function cn(e){if(e.nodeValue.length<65536)return;let t=e.nextSibling;for(;t!==null&&t.nodeType===ft;)t.remove(),e.nodeValue+=t.nodeValue,t=e.nextSibling}function wt(e){var t=p,n=g;M(null),F(null);try{return e()}finally{M(t),F(n)}}function Ir(e){g===null&&(p===null&&lr(),or()),ue&&sr()}function Fr(e,t){var n=t.last;n===null?t.last=t.first=e:(n.next=e,e.prev=n,t.last=e)}function J(e,t){var n=g;n!==null&&(n.f&W)!==0&&(e|=W);var r={ctx:I,deps:null,nodes:null,f:e|C|P,first:null,fn:t,last:null,next:null,parent:n,b:n&&n.b,prev:null,teardown:null,wv:0,ac:null},i=r;if((e&Te)!==0)ke!==null?ke.push(r):X.ensure().schedule(r);else if(t!==null){try{Se(r)}catch(o){throw O(r),o}i.deps===null&&i.teardown===null&&i.nodes===null&&i.first===i.last&&(i.f&he)===0&&(i=i.first,(e&ee)!==0&&(e&xe)!==0&&i!==null&&(i.f|=xe))}if(i!==null&&(i.parent=n,n!==null&&Fr(i,n),p!==null&&(p.f&A)!==0&&(e&te)===0)){var s=p;(s.effects??=[]).push(i)}return r}function bt(){return p!==null&&!V}function dn(e){const t=J(We,null);return x(t,k),t.teardown=e,t}function Hr(e){Ir();var t=g.f,n=!p&&(t&Y)!==0&&(t&ne)===0;if(n){var r=I;(r.e??=[]).push(e)}else return hn(e)}function hn(e){return J(Te|er,e)}function qr(e){X.ensure();const t=J(te|he,e);return()=>{O(t)}}function Br(e){X.ensure();const t=J(te|he,e);return(n={})=>new Promise(r=>{n.outro?He(t,()=>{O(t),r(void 0)}):(O(t),r(void 0))})}function Ur(e){return J(Te,e)}function Vr(e){return J(lt|he,e)}function vn(e,t=0){return J(We|t,e)}function et(e,t=[],n=[],r=[]){kr(r,t,n,i=>{J(We,()=>e(...i.map(_)))})}function _n(e,t=0){var n=J(ee|t,e);return n}function Q(e){return J(Y|he,e)}function pn(e){var t=e.teardown;if(t!==null){const n=ue,r=p;yn(!0),M(null);try{t.call(null)}finally{yn(n),M(r)}}}function mt(e,t=!1){var n=e.first;for(e.first=e.last=null;n!==null;){const i=n.ac;i!==null&&wt(()=>{i.abort(K)});var r=n.next;(n.f&te)!==0?n.parent=null:O(n,t),n=r}}function Yr(e){for(var t=e.first;t!==null;){var n=t.next;(t.f&Y)===0&&O(t),t=n}}function O(e,t=!0){var n=!1;(t||(e.f&Qn)!==0)&&e.nodes!==null&&e.nodes.end!==null&&(zr(e.nodes.start,e.nodes.end),n=!0),x(e,jt),mt(e,t&&!n),Be(e,0);var r=e.nodes&&e.nodes.t;if(r!==null)for(const s of r)s.stop();pn(e),e.f^=jt,e.f|=B;var i=e.parent;i!==null&&i.first!==null&&gn(e),e.next=e.prev=e.teardown=e.ctx=e.deps=e.fn=e.nodes=e.ac=e.b=null}function zr(e,t){for(;e!==null;){var n=e===t?null:fe(e);e.remove(),e=n}}function gn(e){var t=e.parent,n=e.prev,r=e.next;n!==null&&(n.next=r),r!==null&&(r.prev=n),t!==null&&(t.first===e&&(t.first=r),t.last===e&&(t.last=n))}function He(e,t,n=!0){var r=[];wn(e,r,!0);var i=()=>{n&&O(e),t&&t()},s=r.length;if(s>0){var o=()=>--s||i();for(var l of r)l.out(o)}else i()}function wn(e,t,n){if((e.f&W)===0){e.f^=W;var r=e.nodes&&e.nodes.t;if(r!==null)for(const l of r)(l.is_global||n)&&t.push(l);for(var i=e.first;i!==null;){var s=i.next,o=(i.f&xe)!==0||(i.f&Y)!==0&&(e.f&ee)!==0;wn(i,t,o?n:!1),i=s}}}function Wr(e){bn(e,!0)}function bn(e,t){if((e.f&W)!==0){e.f^=W,(e.f&k)===0&&(x(e,C),X.ensure().schedule(e));for(var n=e.first;n!==null;){var r=n.next,i=(n.f&xe)!==0||(n.f&Y)!==0;bn(n,i?t:!1),n=r}var s=e.nodes&&e.nodes.t;if(s!==null)for(const o of s)(o.is_global||t)&&o.in()}}function mn(e,t){if(e.nodes)for(var n=e.nodes.start,r=e.nodes.end;n!==null;){var i=n===r?null:fe(n);t.append(n),n=i}}let tt=!1,ue=!1;function yn(e){ue=e}let p=null,V=!1;function M(e){p=e}let g=null;function F(e){g=e}let H=null;function Gr(e){p!==null&&(H===null?H=[e]:H.push(e))}let L=null,j=0,q=null;function Jr(e){q=e}let $n=1,ge=0,we=ge;function En(e){we=e}function Tn(){return++$n}function qe(e){var t=e.f;if((t&C)!==0)return!0;if(t&A&&(e.f&=~ve),(t&z)!==0){for(var n=e.deps,r=n.length,i=0;i<r;i++){var s=n[i];if(qe(s)&&nn(s),s.wv>e.wv)return!0}(t&P)!==0&&U===null&&x(e,k)}return!1}function xn(e,t,n=!0){var r=e.reactions;if(r!==null&&!(H!==null&&$e.call(H,e)))for(var i=0;i<r.length;i++){var s=r[i];(s.f&A)!==0?xn(s,t,!1):t===s&&(n?x(s,C):(s.f&k)!==0&&x(s,z),ht(s))}}function Nn(e){var t=L,n=j,r=q,i=p,s=H,o=I,l=V,a=we,f=e.f;L=null,j=0,q=null,p=(f&(Y|te))===0?e:null,H=null,Ne(e.ctx),V=!1,we=++ge,e.ac!==null&&(wt(()=>{e.ac.abort(K)}),e.ac=null);try{e.f|=ot;var u=e.fn,d=u();e.f|=ne;var c=e.deps,v=$?.is_fork;if(L!==null){var h;if(v||Be(e,j),c!==null&&j>0)for(c.length=j+L.length,h=0;h<L.length;h++)c[j+h]=L[h];else e.deps=c=L;if(bt()&&(e.f&P)!==0)for(h=j;h<c.length;h++)(c[h].reactions??=[]).push(e)}else!v&&c!==null&&j<c.length&&(Be(e,j),c.length=j);if(Ut()&&q!==null&&!V&&c!==null&&(e.f&(A|z|C))===0)for(h=0;h<q.length;h++)xn(q[h],e);if(i!==null&&i!==e){if(ge++,i.deps!==null)for(let y=0;y<n;y+=1)i.deps[y].rv=ge;if(t!==null)for(const y of t)y.rv=ge;q!==null&&(r===null?r=q:r.push(...q))}return(e.f&re)!==0&&(e.f^=re),d}catch(y){return Yt(y)}finally{e.f^=ot,L=t,j=n,q=r,p=i,H=s,Ne(o),V=l,we=a}}function Kr(e,t){let n=t.reactions;if(n!==null){var r=zn.call(n,e);if(r!==-1){var i=n.length-1;i===0?n=t.reactions=null:(n[r]=n[i],n.pop())}}if(n===null&&(t.f&A)!==0&&(L===null||!$e.call(L,t))){var s=t;(s.f&P)!==0&&(s.f^=P,s.f&=~ve),ut(s),Or(s),Be(s,0)}}function Be(e,t){var n=e.deps;if(n!==null)for(var r=t;r<n.length;r++)Kr(e,n[r])}function Se(e){var t=e.f;if((t&B)===0){x(e,k);var n=g,r=tt;g=e,tt=!0;try{(t&(ee|Dt))!==0?Yr(e):mt(e),pn(e);var i=Nn(e);e.teardown=typeof i=="function"?i:null,e.wv=$n;var s;Vn&&wr&&(e.f&C)!==0&&e.deps}finally{tt=r,g=n}}}function _(e){var t=e.f,n=(t&A)!==0;if(p!==null&&!V){var r=g!==null&&(g.f&B)!==0;if(!r&&(H===null||!$e.call(H,e))){var i=p.deps;if((p.f&ot)!==0)e.rv<ge&&(e.rv=ge,L===null&&i!==null&&i[j]===e?j++:L===null?L=[e]:L.push(e));else{(p.deps??=[]).push(e);var s=e.reactions;s===null?e.reactions=[p]:$e.call(s,p)||s.push(p)}}}if(ue&&le.has(e))return le.get(e);if(n){var o=e;if(ue){var l=o.v;return((o.f&k)===0&&o.reactions!==null||An(o))&&(l=vt(o)),le.set(o,l),l}var a=(o.f&P)===0&&!V&&p!==null&&(tt||(p.f&P)!==0),f=(o.f&ne)===0;qe(o)&&(a&&(o.f|=P),nn(o)),a&&!f&&(rn(o),kn(o))}if(U?.has(e))return U.get(e);if((e.f&re)!==0)throw e.v;return e.v}function kn(e){if(e.f|=P,e.deps!==null)for(const t of e.deps)(t.reactions??=[]).push(e),(t.f&A)!==0&&(t.f&P)===0&&(rn(t),kn(t))}function An(e){if(e.v===S)return!0;if(e.deps===null)return!1;for(const t of e.deps)if(le.has(t)||(t.f&A)!==0&&An(t))return!0;return!1}function Xr(e){var t=V;try{return V=!0,e()}finally{V=t}}const nt=Symbol("events"),Zr=new Set,Sn=new Set;function Qr(e,t,n,r={}){function i(s){if(r.capture||yt.call(t,s),!s.cancelBubble)return wt(()=>n?.call(this,s))}return e.startsWith("pointer")||e.startsWith("touch")||e==="wheel"?pe(()=>{t.addEventListener(e,i,r)}):t.addEventListener(e,i,r),i}function ei(e,t,n,r,i){var s={capture:r,passive:i},o=Qr(e,t,n,s);(t===document.body||t===window||t===document||t instanceof HTMLMediaElement)&&dn(()=>{t.removeEventListener(e,o,s)})}let Cn=null;function yt(e){var t=this,n=t.ownerDocument,r=e.type,i=e.composedPath?.()||[],s=i[0]||e.target;Cn=e;var o=0,l=Cn===e&&e[nt];if(l){var a=i.indexOf(l);if(a!==-1&&(t===document||t===window)){e[nt]=t;return}var f=i.indexOf(t);if(f===-1)return;a<=f&&(o=a)}if(s=i[o]||e.target,s!==t){ze(e,"currentTarget",{configurable:!0,get(){return s||n}});var u=p,d=g;M(null),F(null);try{for(var c,v=[];s!==null;){var h=s.assignedSlot||s.parentNode||s.host||null;try{var y=s[nt]?.[r];y!=null&&(!s.disabled||e.target===s)&&y.call(s,e)}catch(E){c?v.push(E):c=E}if(e.cancelBubble||h===t||h===null)break;s=h}if(c){for(let E of v)queueMicrotask(()=>{throw E});throw c}}finally{e[nt]=t,delete e.currentTarget,M(u),F(d)}}}const ti=globalThis?.window?.trustedTypes&&globalThis.window.trustedTypes.createPolicy("svelte-trusted-html",{createHTML:e=>e});function ni(e){return ti?.createHTML(e)??e}function ri(e){var t=gt("template");return t.innerHTML=ni(e.replaceAll("<!>","<!---->")),t.content}function Ce(e,t){var n=g;n.nodes===null&&(n.nodes={start:e,end:t,a:null,t:null})}function $t(e,t){var n=(t&Bn)!==0,r=(t&Un)!==0,i,s=!e.startsWith("<!>");return()=>{if(m)return Ce(T,null),T;i===void 0&&(i=ri(s?e:"<!>"+e),n||(i=Ie(i)));var o=r||an?document.importNode(i,!0):i.cloneNode(!0);if(n){var l=Ie(o),a=o.lastChild;Ce(l,a)}else Ce(o,o);return o}}function Rn(e=""){if(!m){var t=ae(e+"");return Ce(t,t),t}var n=T;return n.nodeType!==ft?(n.before(n=ae()),G(n)):cn(n),Ce(n,n),n}function Re(e,t){if(m){var n=g;((n.f&ne)===0||n.nodes.end===null)&&(n.nodes.end=T),Ke();return}e!==null&&e.before(t)}const ii=["touchstart","touchmove"];function si(e){return ii.includes(e)}function On(e,t){var n=t==null?"":typeof t=="object"?`${t}`:t;n!==(e.__t??=e.nodeValue)&&(e.__t=n,e.nodeValue=`${n}`)}function Mn(e,t){return Ln(e,t)}function oi(e,t){pt(),t.intro=t.intro??!1;const n=t.target,r=m,i=T;try{for(var s=Ie(n);s&&(s.nodeType!==Ge||s.data!==kt);)s=fe(s);if(!s)throw ye;ie(!0),G(s);const o=Ln(e,{...t,anchor:s});return ie(!1),o}catch(o){if(o instanceof Error&&o.message.split(`
|
|
2
|
-
`).some(l=>l.startsWith("https://svelte.dev/e/")))throw o;return o!==ye&&console.warn("Failed to hydrate: ",o),t.recover===!1&&fr(),pt(),jr(n),ie(!1),Mn(e,t)}finally{ie(r),G(i)}}const rt=new Map;function Ln(e,{target:t,anchor:n,props:r={},events:i,context:s,intro:o=!0,transformError:l}){pt();var a=void 0,f=Br(()=>{var u=n??t.appendChild(ae());xr(u,{pending:()=>{}},v=>{qt({});var h=I;if(s&&(h.c=s),i&&(r.$$events=i),m&&Ce(v,null),a=e(v,r)||{},m&&(g.nodes.end=T,T===null||T.nodeType!==Ge||T.data!==Ct))throw Je(),ye;Bt()},l);var d=new Set,c=v=>{for(var h=0;h<v.length;h++){var y=v[h];if(!d.has(y)){d.add(y);var E=si(y);for(const Oe of[t,document]){var R=rt.get(Oe);R===void 0&&(R=new Map,rt.set(Oe,R));var ce=R.get(y);ce===void 0?(Oe.addEventListener(y,yt,{passive:E}),R.set(y,1)):R.set(y,ce+1)}}}};return c(Wn(Zr)),Sn.add(c),()=>{for(var v of d)for(const E of[t,document]){var h=rt.get(E),y=h.get(v);--y==0?(E.removeEventListener(v,yt),h.delete(v),h.size===0&&rt.delete(E)):h.set(v,y)}Sn.delete(c),u!==n&&u.parentNode?.removeChild(u)}});return Et.set(a,f),a}let Et=new WeakMap;function li(e,t){const n=Et.get(e);return n?(Et.delete(e),n(t)):Promise.resolve()}class ai{anchor;#e=new Map;#n=new Map;#t=new Map;#i=new Set;#s=!0;constructor(t,n=!0){this.anchor=t,this.#s=n}#r=t=>{if(this.#e.has(t)){var n=this.#e.get(t),r=this.#n.get(n);if(r)Wr(r),this.#i.delete(n);else{var i=this.#t.get(n);i&&(this.#n.set(n,i.effect),this.#t.delete(n),i.fragment.lastChild.remove(),this.anchor.before(i.fragment),r=i.effect)}for(const[s,o]of this.#e){if(this.#e.delete(s),s===t)break;const l=this.#t.get(o);l&&(O(l.effect),this.#t.delete(o))}for(const[s,o]of this.#n){if(s===n||this.#i.has(s))continue;const l=()=>{if(Array.from(this.#e.values()).includes(s)){var f=document.createDocumentFragment();mn(o,f),f.append(ae()),this.#t.set(s,{effect:o,fragment:f})}else O(o);this.#i.delete(s),this.#n.delete(s)};this.#s||!r?(this.#i.add(s),He(o,l,!1)):l()}}};#o=t=>{this.#e.delete(t);const n=Array.from(this.#e.values());for(const[r,i]of this.#t)n.includes(r)||(O(i.effect),this.#t.delete(r))};ensure(t,n){var r=$,i=Pr();if(n&&!this.#n.has(t)&&!this.#t.has(t))if(i){var s=document.createDocumentFragment(),o=ae();s.append(o),this.#t.set(t,{effect:Q(()=>n(o)),fragment:s})}else this.#n.set(t,Q(()=>n(this.anchor)));if(this.#e.set(r,t),i){for(const[l,a]of this.#n)l===t?r.unskip_effect(a):r.skip_effect(a);for(const[l,a]of this.#t)l===t?r.unskip_effect(a.effect):r.skip_effect(a.effect);r.oncommit(this.#r),r.ondiscard(this.#o)}else m&&(this.anchor=T),this.#r(r)}}function fi(e,t,n=!1){var r;m&&(r=T,Ke());var i=new ai(e),s=n?xe:0;function o(l,a){if(m){var f=_r(r);if(l!==parseInt(f.substring(1))){var u=Ft();G(u),i.anchor=u,ie(!1),i.ensure(l,a),ie(!0);return}}i.ensure(l,a)}_n(()=>{var l=!1;t((a,f=0)=>{l=!0,o(f,a)}),l||o(-1,null)},s)}function ui(e,t,n,r,i){m&&Ke();var s=t.$$slots?.[n],o=!1;s===!0&&(s=t[n],o=!0),s===void 0?i!==null&&i(e):s(e,o?()=>r:r)}function ci(e,t){Ur(()=>{var n=e.getRootNode(),r=n.host?n:n.head??n.ownerDocument.head;if(!r.querySelector("#"+t.hash)){const i=gt("style");i.id=t.hash,i.textContent=t.code,r.appendChild(i)}})}function di(e,t,n){var r=""+e;return r}function hi(e,t){return e==null?null:String(e)}function vi(e,t,n,r,i,s){var o=e.__className;if(m||o!==n||o===void 0){var l=di(n);(!m||l!==e.getAttribute("class"))&&(l==null?e.removeAttribute("class"):e.className=l),e.__className=n}return s}function _i(e,t,n,r){var i=e.__style;if(m||i!==t){var s=hi(t);(!m||s!==e.getAttribute("style"))&&(s==null?e.removeAttribute("style"):e.style.cssText=s),e.__style=t}return r}const pi=Symbol("is custom element"),gi=Symbol("is html"),wi=rr?"link":"LINK";function Dn(e,t,n,r){var i=bi(e);m&&(i[t]=e.getAttribute(t),t==="src"||t==="srcset"||t==="href"&&e.nodeName===wi)||i[t]!==(i[t]=n)&&(t==="loading"&&(e[nr]=n),n==null?e.removeAttribute(t):typeof n!="string"&&Pn(e).includes(t)?e[t]=n:e.setAttribute(t,n))}function jn(e,t,n){var r=p,i=g;let s=m;m&&ie(!1),M(null),F(null);try{t!=="style"&&(Tt.has(e.getAttribute("is")||e.nodeName)||!customElements||customElements.get(e.getAttribute("is")||e.nodeName.toLowerCase())?Pn(e).includes(t):n&&typeof n=="object")?e[t]=n:Dn(e,t,n==null?n:String(n))}finally{M(r),F(i),s&&ie(!0)}}function bi(e){return e.__attributes??={[pi]:e.nodeName.includes("-"),[gi]:e.namespaceURI===Rt}}var Tt=new Map;function Pn(e){var t=e.getAttribute("is")||e.nodeName,n=Tt.get(t);if(n)return n;Tt.set(t,n=[]);for(var r,i=e,s=Element.prototype;s!==i;){r=Gn(i);for(var o in r)r[o].set&&n.push(o);i=Ot(i)}return n}function Ue(e,t,n,r){var i=r,s=!0,o=()=>(s&&(s=!1,i=r),i),l;l=e[t],l===void 0&&r!==void 0&&(l=o());var a;a=()=>{var c=e[t];return c===void 0?o():(s=!0,c)};var f=!1,u=tn(()=>(f=!1,a())),d=g;return(function(c,v){if(arguments.length>0){const h=v?_(u):c;return N(u,h),f=!0,i!==void 0&&(i=h),c}return ue&&f||(d.f&B)!==0?u.v:_(u)})}function mi(e){return new yi(e)}class yi{#e;#n;constructor(t){var n=new Map,r=(s,o)=>{var l=Mr(o,!1,!1);return n.set(s,l),l};const i=new Proxy({...t.props||{},$$events:{}},{get(s,o){return _(n.get(o)??r(o,Reflect.get(s,o)))},has(s,o){return o===tr?!0:(_(n.get(o)??r(o,Reflect.get(s,o))),Reflect.has(s,o))},set(s,o,l){return N(n.get(o)??r(o,l),l),Reflect.set(s,o,l)}});this.#n=(t.hydrate?oi:Mn)(t.component,{target:t.target,anchor:t.anchor,props:i,context:t.context,intro:t.intro??!1,recover:t.recover,transformError:t.transformError}),(!t?.props?.$$host||t.sync===!1)&&Ae(),this.#e=i.$$events;for(const s of Object.keys(this.#n))s==="$set"||s==="$destroy"||s==="$on"||ze(this,s,{get(){return this.#n[s]},set(o){this.#n[s]=o},enumerable:!0});this.#n.$set=s=>{Object.assign(i,s)},this.#n.$destroy=()=>{li(this.#n)}}$set(t){this.#n.$set(t)}$on(t,n){this.#e[t]=this.#e[t]||[];const r=(...i)=>n.call(this,...i);return this.#e[t].push(r),()=>{this.#e[t]=this.#e[t].filter(i=>i!==r)}}$destroy(){this.#n.$destroy()}}let In;typeof HTMLElement=="function"&&(In=class extends HTMLElement{$$ctor;$$s;$$c;$$cn=!1;$$d={};$$r=!1;$$p_d={};$$l={};$$l_u=new Map;$$me;$$shadowRoot=null;constructor(e,t,n){super(),this.$$ctor=e,this.$$s=t,n&&(this.$$shadowRoot=this.attachShadow(n))}addEventListener(e,t,n){if(this.$$l[e]=this.$$l[e]||[],this.$$l[e].push(t),this.$$c){const r=this.$$c.$on(e,t);this.$$l_u.set(t,r)}super.addEventListener(e,t,n)}removeEventListener(e,t,n){if(super.removeEventListener(e,t,n),this.$$c){const r=this.$$l_u.get(t);r&&(r(),this.$$l_u.delete(t))}}async connectedCallback(){if(this.$$cn=!0,!this.$$c){let e=function(r){return i=>{const s=gt("slot");r!=="default"&&(s.name=r),Re(i,s)}};if(await Promise.resolve(),!this.$$cn||this.$$c)return;const t={},n=$i(this);for(const r of this.$$s)r in n&&(r==="default"&&!this.$$d.children?(this.$$d.children=e(r),t.default=!0):t[r]=e(r));for(const r of this.attributes){const i=this.$$g_p(r.name);i in this.$$d||(this.$$d[i]=it(i,r.value,this.$$p_d,"toProp"))}for(const r in this.$$p_d)!(r in this.$$d)&&this[r]!==void 0&&(this.$$d[r]=this[r],delete this[r]);this.$$c=mi({component:this.$$ctor,target:this.$$shadowRoot||this,props:{...this.$$d,$$slots:t,$$host:this}}),this.$$me=qr(()=>{vn(()=>{this.$$r=!0;for(const r of Ye(this.$$c)){if(!this.$$p_d[r]?.reflect)continue;this.$$d[r]=this.$$c[r];const i=it(r,this.$$d[r],this.$$p_d,"toAttribute");i==null?this.removeAttribute(this.$$p_d[r].attribute||r):this.setAttribute(this.$$p_d[r].attribute||r,i)}this.$$r=!1})});for(const r in this.$$l)for(const i of this.$$l[r]){const s=this.$$c.$on(r,i);this.$$l_u.set(i,s)}this.$$l={}}}attributeChangedCallback(e,t,n){this.$$r||(e=this.$$g_p(e),this.$$d[e]=it(e,n,this.$$p_d,"toProp"),this.$$c?.$set({[e]:this.$$d[e]}))}disconnectedCallback(){this.$$cn=!1,Promise.resolve().then(()=>{!this.$$cn&&this.$$c&&(this.$$c.$destroy(),this.$$me(),this.$$c=void 0)})}$$g_p(e){return Ye(this.$$p_d).find(t=>this.$$p_d[t].attribute===e||!this.$$p_d[t].attribute&&t.toLowerCase()===e)||e}});function it(e,t,n,r){const i=n[e]?.type;if(t=i==="Boolean"&&typeof t!="boolean"?t!=null:t,!r||!n[e])return t;if(r==="toAttribute")switch(i){case"Object":case"Array":return t==null?null:JSON.stringify(t);case"Boolean":return t?"":null;case"Number":return t??null;default:return t}else switch(i){case"Object":case"Array":return t&&JSON.parse(t);case"Boolean":return t;case"Number":return t!=null?+t:t;default:return t}}function $i(e){const t={};return e.childNodes.forEach(n=>{t[n.slot||"default"]=!0}),t}function Ei(e,t,n,r,i,s){let o=class extends In{constructor(){super(e,n,i),this.$$p_d=t}static get observedAttributes(){return Ye(t).map(l=>(t[l].attribute||l).toLowerCase())}};return Ye(t).forEach(l=>{ze(o.prototype,l,{get(){return this.$$c&&l in this.$$c?this.$$c[l]:this.$$d[l]},set(a){a=it(l,a,t),this.$$d[l]=a;var f=this.$$c;if(f){var u=Ee(f,l)?.get;u?f[l]=a:f.$set({[l]:a})}}})}),r.forEach(l=>{ze(o.prototype,l,{get(){return this.$$c?.[l]}})}),e.element=o,o}const Ti={version:"0.66.1"};var be={},Fn;function xi(){if(Fn)return be;Fn=1,Object.defineProperty(be,"__esModule",{value:!0}),be.LanguageTranslator=void 0,be.getChildStyleToPass=e,be.addComponent=t;function e(r,i){var s,o,l="";try{if(r&&i?.length&&(!((s=Object.keys(r))===null||s===void 0)&&s.length)&&(!((o=i?.filter(function(c){return Object.keys(r).includes(c.name)}))===null||o===void 0)&&o.length))for(var a=function(c){var v=i?.filter(function(h){return h.name===c&&h.defaultValue!==r[c]});v&&(l+="".concat(c,":").concat(r[c],";"))},f=0,u=Object.keys(r);f<u.length;f++){var d=u[f];a(d)}}catch(c){console.error("error getting child style to pass",c)}finally{return l}}function t(r){var i,s=((i=r?.repoName.split("/"))===null||i===void 0?void 0:i[1])||r?.repoName;if(!s)throw new Error("wrong componentPath "+r?.repoName);if(!r?.version)throw new Error("wrong version "+r?.version);var o=r?.iifePath||"main.iife.js";if(!document.getElementById(s+"-script"))try{var l=document.createElement("script");if(l.id=s+"-script",l.src="https://cdn.jsdelivr.net/npm/".concat(r.repoName,"@").concat(r.version,"/").concat(o),r?.local)l.src="".concat(r.local);else if(location.href.includes("localhost:6006")){var a=s.split("-")[0];l.src="http://localhost:6006/webcomponents/".concat(s.replace(a+"-",""),"/").concat(o)}document.head.appendChild(l)}catch(f){console.warn(f)}}var n=(function(){function r(i){if(this.lang="",!i?.dictionary)throw new Error("no dictionary provided");this.dictionary=i.dictionary,this.setLang(i?.lang)}return r.prototype.setLang=function(i){i||(i=r.getDefaultLang()),this.lang=i},r.prototype.translateWord=function(i,s){return r.getDictionaryWord(i,this.dictionary,s||this.lang)},r.prototype.translateDate=function(i,s,o){return r.formatDate(i,s,o||this.lang)},r.getDefaultLang=function(){var i,s,o,l="en";return navigator?.languages&&(!((o=(s=(i=navigator.languages[0])===null||i===void 0?void 0:i.split("-")[0])===null||s===void 0?void 0:s.toLowerCase())===null||o===void 0)&&o.length)&&(l=navigator.languages[0].split("-")[0].toLowerCase()),l},r.getDictionaryWord=function(i,s,o){var l;if(!i)throw new Error("no wordKey provided");if(!s)throw new Error("no dictionary provided");if(o&&(!((l=s[o])===null||l===void 0)&&l[i]))return s[o][i];var a="",f=r.getDefaultLang();if(!o||f!==o){var u=s?.[f];u?.[i]&&(a=u[i])}return a},r.formatDate=function(i,s,o){if(!i)throw new Error("no date provided");if(typeof i.getMonth!="function")throw new Error("wrong date format");var l=new Intl.DateTimeFormat(o||r.getDefaultLang(),s);return l.format(i)},r})();return be.LanguageTranslator=n,be}var Ni=xi(),ki=$t('<div class="progress svelte-vj77ev"><div class="progress-bar progress-bar-striped progress-bar-animated svelte-vj77ev" role="progressbar" aria-valuenow="100" aria-valuemin="0" aria-valuemax="100" style="width: 100%"></div></div>'),Ai=$t('<div class="progress svelte-vj77ev"><div class="progress-bar svelte-vj77ev" role="progressbar" aria-valuemin="0" aria-valuemax="100"> </div></div>'),Si=$t('<hb-dialog><span slot="title" class="svelte-vj77ev"><!></span> <div slot="body-content" class="svelte-vj77ev"><!></div> <span slot="modal-footer" class="svelte-vj77ev"></span></hb-dialog>',2);const Ci={hash:"svelte-vj77ev",code:`@import url("https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap");
|
|
2
|
+
`).some(l=>l.startsWith("https://svelte.dev/e/")))throw o;return o!==ye&&console.warn("Failed to hydrate: ",o),t.recover===!1&&fr(),pt(),jr(n),ie(!1),Mn(e,t)}finally{ie(r),G(i)}}const rt=new Map;function Ln(e,{target:t,anchor:n,props:r={},events:i,context:s,intro:o=!0,transformError:l}){pt();var a=void 0,f=Br(()=>{var u=n??t.appendChild(ae());xr(u,{pending:()=>{}},v=>{qt({});var h=I;if(s&&(h.c=s),i&&(r.$$events=i),m&&Ce(v,null),a=e(v,r)||{},m&&(g.nodes.end=T,T===null||T.nodeType!==Ge||T.data!==Ct))throw Je(),ye;Bt()},l);var d=new Set,c=v=>{for(var h=0;h<v.length;h++){var y=v[h];if(!d.has(y)){d.add(y);var E=si(y);for(const Oe of[t,document]){var R=rt.get(Oe);R===void 0&&(R=new Map,rt.set(Oe,R));var ce=R.get(y);ce===void 0?(Oe.addEventListener(y,yt,{passive:E}),R.set(y,1)):R.set(y,ce+1)}}}};return c(Wn(Zr)),Sn.add(c),()=>{for(var v of d)for(const E of[t,document]){var h=rt.get(E),y=h.get(v);--y==0?(E.removeEventListener(v,yt),h.delete(v),h.size===0&&rt.delete(E)):h.set(v,y)}Sn.delete(c),u!==n&&u.parentNode?.removeChild(u)}});return Et.set(a,f),a}let Et=new WeakMap;function li(e,t){const n=Et.get(e);return n?(Et.delete(e),n(t)):Promise.resolve()}class ai{anchor;#e=new Map;#n=new Map;#t=new Map;#i=new Set;#s=!0;constructor(t,n=!0){this.anchor=t,this.#s=n}#r=t=>{if(this.#e.has(t)){var n=this.#e.get(t),r=this.#n.get(n);if(r)Wr(r),this.#i.delete(n);else{var i=this.#t.get(n);i&&(this.#n.set(n,i.effect),this.#t.delete(n),i.fragment.lastChild.remove(),this.anchor.before(i.fragment),r=i.effect)}for(const[s,o]of this.#e){if(this.#e.delete(s),s===t)break;const l=this.#t.get(o);l&&(O(l.effect),this.#t.delete(o))}for(const[s,o]of this.#n){if(s===n||this.#i.has(s))continue;const l=()=>{if(Array.from(this.#e.values()).includes(s)){var f=document.createDocumentFragment();mn(o,f),f.append(ae()),this.#t.set(s,{effect:o,fragment:f})}else O(o);this.#i.delete(s),this.#n.delete(s)};this.#s||!r?(this.#i.add(s),He(o,l,!1)):l()}}};#o=t=>{this.#e.delete(t);const n=Array.from(this.#e.values());for(const[r,i]of this.#t)n.includes(r)||(O(i.effect),this.#t.delete(r))};ensure(t,n){var r=$,i=Pr();if(n&&!this.#n.has(t)&&!this.#t.has(t))if(i){var s=document.createDocumentFragment(),o=ae();s.append(o),this.#t.set(t,{effect:Q(()=>n(o)),fragment:s})}else this.#n.set(t,Q(()=>n(this.anchor)));if(this.#e.set(r,t),i){for(const[l,a]of this.#n)l===t?r.unskip_effect(a):r.skip_effect(a);for(const[l,a]of this.#t)l===t?r.unskip_effect(a.effect):r.skip_effect(a.effect);r.oncommit(this.#r),r.ondiscard(this.#o)}else m&&(this.anchor=T),this.#r(r)}}function fi(e,t,n=!1){var r;m&&(r=T,Ke());var i=new ai(e),s=n?xe:0;function o(l,a){if(m){var f=_r(r);if(l!==parseInt(f.substring(1))){var u=Ft();G(u),i.anchor=u,ie(!1),i.ensure(l,a),ie(!0);return}}i.ensure(l,a)}_n(()=>{var l=!1;t((a,f=0)=>{l=!0,o(f,a)}),l||o(-1,null)},s)}function ui(e,t,n,r,i){m&&Ke();var s=t.$$slots?.[n],o=!1;s===!0&&(s=t[n],o=!0),s===void 0?i!==null&&i(e):s(e,o?()=>r:r)}function ci(e,t){Ur(()=>{var n=e.getRootNode(),r=n.host?n:n.head??n.ownerDocument.head;if(!r.querySelector("#"+t.hash)){const i=gt("style");i.id=t.hash,i.textContent=t.code,r.appendChild(i)}})}function di(e,t,n){var r=""+e;return r}function hi(e,t){return e==null?null:String(e)}function vi(e,t,n,r,i,s){var o=e.__className;if(m||o!==n||o===void 0){var l=di(n);(!m||l!==e.getAttribute("class"))&&(l==null?e.removeAttribute("class"):e.className=l),e.__className=n}return s}function _i(e,t,n,r){var i=e.__style;if(m||i!==t){var s=hi(t);(!m||s!==e.getAttribute("style"))&&(s==null?e.removeAttribute("style"):e.style.cssText=s),e.__style=t}return r}const pi=Symbol("is custom element"),gi=Symbol("is html"),wi=rr?"link":"LINK";function Dn(e,t,n,r){var i=bi(e);m&&(i[t]=e.getAttribute(t),t==="src"||t==="srcset"||t==="href"&&e.nodeName===wi)||i[t]!==(i[t]=n)&&(t==="loading"&&(e[nr]=n),n==null?e.removeAttribute(t):typeof n!="string"&&Pn(e).includes(t)?e[t]=n:e.setAttribute(t,n))}function jn(e,t,n){var r=p,i=g;let s=m;m&&ie(!1),M(null),F(null);try{t!=="style"&&(Tt.has(e.getAttribute("is")||e.nodeName)||!customElements||customElements.get(e.getAttribute("is")||e.nodeName.toLowerCase())?Pn(e).includes(t):n&&typeof n=="object")?e[t]=n:Dn(e,t,n==null?n:String(n))}finally{M(r),F(i),s&&ie(!0)}}function bi(e){return e.__attributes??={[pi]:e.nodeName.includes("-"),[gi]:e.namespaceURI===Rt}}var Tt=new Map;function Pn(e){var t=e.getAttribute("is")||e.nodeName,n=Tt.get(t);if(n)return n;Tt.set(t,n=[]);for(var r,i=e,s=Element.prototype;s!==i;){r=Gn(i);for(var o in r)r[o].set&&n.push(o);i=Ot(i)}return n}function Ue(e,t,n,r){var i=r,s=!0,o=()=>(s&&(s=!1,i=r),i),l;l=e[t],l===void 0&&r!==void 0&&(l=o());var a;a=()=>{var c=e[t];return c===void 0?o():(s=!0,c)};var f=!1,u=tn(()=>(f=!1,a())),d=g;return(function(c,v){if(arguments.length>0){const h=v?_(u):c;return N(u,h),f=!0,i!==void 0&&(i=h),c}return ue&&f||(d.f&B)!==0?u.v:_(u)})}function mi(e){return new yi(e)}class yi{#e;#n;constructor(t){var n=new Map,r=(s,o)=>{var l=Mr(o,!1,!1);return n.set(s,l),l};const i=new Proxy({...t.props||{},$$events:{}},{get(s,o){return _(n.get(o)??r(o,Reflect.get(s,o)))},has(s,o){return o===tr?!0:(_(n.get(o)??r(o,Reflect.get(s,o))),Reflect.has(s,o))},set(s,o,l){return N(n.get(o)??r(o,l),l),Reflect.set(s,o,l)}});this.#n=(t.hydrate?oi:Mn)(t.component,{target:t.target,anchor:t.anchor,props:i,context:t.context,intro:t.intro??!1,recover:t.recover,transformError:t.transformError}),(!t?.props?.$$host||t.sync===!1)&&Ae(),this.#e=i.$$events;for(const s of Object.keys(this.#n))s==="$set"||s==="$destroy"||s==="$on"||ze(this,s,{get(){return this.#n[s]},set(o){this.#n[s]=o},enumerable:!0});this.#n.$set=s=>{Object.assign(i,s)},this.#n.$destroy=()=>{li(this.#n)}}$set(t){this.#n.$set(t)}$on(t,n){this.#e[t]=this.#e[t]||[];const r=(...i)=>n.call(this,...i);return this.#e[t].push(r),()=>{this.#e[t]=this.#e[t].filter(i=>i!==r)}}$destroy(){this.#n.$destroy()}}let In;typeof HTMLElement=="function"&&(In=class extends HTMLElement{$$ctor;$$s;$$c;$$cn=!1;$$d={};$$r=!1;$$p_d={};$$l={};$$l_u=new Map;$$me;$$shadowRoot=null;constructor(e,t,n){super(),this.$$ctor=e,this.$$s=t,n&&(this.$$shadowRoot=this.attachShadow(n))}addEventListener(e,t,n){if(this.$$l[e]=this.$$l[e]||[],this.$$l[e].push(t),this.$$c){const r=this.$$c.$on(e,t);this.$$l_u.set(t,r)}super.addEventListener(e,t,n)}removeEventListener(e,t,n){if(super.removeEventListener(e,t,n),this.$$c){const r=this.$$l_u.get(t);r&&(r(),this.$$l_u.delete(t))}}async connectedCallback(){if(this.$$cn=!0,!this.$$c){let e=function(r){return i=>{const s=gt("slot");r!=="default"&&(s.name=r),Re(i,s)}};if(await Promise.resolve(),!this.$$cn||this.$$c)return;const t={},n=$i(this);for(const r of this.$$s)r in n&&(r==="default"&&!this.$$d.children?(this.$$d.children=e(r),t.default=!0):t[r]=e(r));for(const r of this.attributes){const i=this.$$g_p(r.name);i in this.$$d||(this.$$d[i]=it(i,r.value,this.$$p_d,"toProp"))}for(const r in this.$$p_d)!(r in this.$$d)&&this[r]!==void 0&&(this.$$d[r]=this[r],delete this[r]);this.$$c=mi({component:this.$$ctor,target:this.$$shadowRoot||this,props:{...this.$$d,$$slots:t,$$host:this}}),this.$$me=qr(()=>{vn(()=>{this.$$r=!0;for(const r of Ye(this.$$c)){if(!this.$$p_d[r]?.reflect)continue;this.$$d[r]=this.$$c[r];const i=it(r,this.$$d[r],this.$$p_d,"toAttribute");i==null?this.removeAttribute(this.$$p_d[r].attribute||r):this.setAttribute(this.$$p_d[r].attribute||r,i)}this.$$r=!1})});for(const r in this.$$l)for(const i of this.$$l[r]){const s=this.$$c.$on(r,i);this.$$l_u.set(i,s)}this.$$l={}}}attributeChangedCallback(e,t,n){this.$$r||(e=this.$$g_p(e),this.$$d[e]=it(e,n,this.$$p_d,"toProp"),this.$$c?.$set({[e]:this.$$d[e]}))}disconnectedCallback(){this.$$cn=!1,Promise.resolve().then(()=>{!this.$$cn&&this.$$c&&(this.$$c.$destroy(),this.$$me(),this.$$c=void 0)})}$$g_p(e){return Ye(this.$$p_d).find(t=>this.$$p_d[t].attribute===e||!this.$$p_d[t].attribute&&t.toLowerCase()===e)||e}});function it(e,t,n,r){const i=n[e]?.type;if(t=i==="Boolean"&&typeof t!="boolean"?t!=null:t,!r||!n[e])return t;if(r==="toAttribute")switch(i){case"Object":case"Array":return t==null?null:JSON.stringify(t);case"Boolean":return t?"":null;case"Number":return t??null;default:return t}else switch(i){case"Object":case"Array":return t&&JSON.parse(t);case"Boolean":return t;case"Number":return t!=null?+t:t;default:return t}}function $i(e){const t={};return e.childNodes.forEach(n=>{t[n.slot||"default"]=!0}),t}function Ei(e,t,n,r,i,s){let o=class extends In{constructor(){super(e,n,i),this.$$p_d=t}static get observedAttributes(){return Ye(t).map(l=>(t[l].attribute||l).toLowerCase())}};return Ye(t).forEach(l=>{ze(o.prototype,l,{get(){return this.$$c&&l in this.$$c?this.$$c[l]:this.$$d[l]},set(a){a=it(l,a,t),this.$$d[l]=a;var f=this.$$c;if(f){var u=Ee(f,l)?.get;u?f[l]=a:f.$set({[l]:a})}}})}),r.forEach(l=>{ze(o.prototype,l,{get(){return this.$$c?.[l]}})}),e.element=o,o}const Ti={version:"0.66.2"};var be={},Fn;function xi(){if(Fn)return be;Fn=1,Object.defineProperty(be,"__esModule",{value:!0}),be.LanguageTranslator=void 0,be.getChildStyleToPass=e,be.addComponent=t;function e(r,i){var s,o,l="";try{if(r&&i?.length&&(!((s=Object.keys(r))===null||s===void 0)&&s.length)&&(!((o=i?.filter(function(c){return Object.keys(r).includes(c.name)}))===null||o===void 0)&&o.length))for(var a=function(c){var v=i?.filter(function(h){return h.name===c&&h.defaultValue!==r[c]});v&&(l+="".concat(c,":").concat(r[c],";"))},f=0,u=Object.keys(r);f<u.length;f++){var d=u[f];a(d)}}catch(c){console.error("error getting child style to pass",c)}finally{return l}}function t(r){var i,s=((i=r?.repoName.split("/"))===null||i===void 0?void 0:i[1])||r?.repoName;if(!s)throw new Error("wrong componentPath "+r?.repoName);if(!r?.version)throw new Error("wrong version "+r?.version);var o=r?.iifePath||"main.iife.js";if(!document.getElementById(s+"-script"))try{var l=document.createElement("script");if(l.id=s+"-script",l.src="https://cdn.jsdelivr.net/npm/".concat(r.repoName,"@").concat(r.version,"/").concat(o),r?.local)l.src="".concat(r.local);else if(location.href.includes("localhost:6006")){var a=s.split("-")[0];l.src="http://localhost:6006/webcomponents/".concat(s.replace(a+"-",""),"/").concat(o)}document.head.appendChild(l)}catch(f){console.warn(f)}}var n=(function(){function r(i){if(this.lang="",!i?.dictionary)throw new Error("no dictionary provided");this.dictionary=i.dictionary,this.setLang(i?.lang)}return r.prototype.setLang=function(i){i||(i=r.getDefaultLang()),this.lang=i},r.prototype.translateWord=function(i,s){return r.getDictionaryWord(i,this.dictionary,s||this.lang)},r.prototype.translateDate=function(i,s,o){return r.formatDate(i,s,o||this.lang)},r.getDefaultLang=function(){var i,s,o,l="en";return navigator?.languages&&(!((o=(s=(i=navigator.languages[0])===null||i===void 0?void 0:i.split("-")[0])===null||s===void 0?void 0:s.toLowerCase())===null||o===void 0)&&o.length)&&(l=navigator.languages[0].split("-")[0].toLowerCase()),l},r.getDictionaryWord=function(i,s,o){var l;if(!i)throw new Error("no wordKey provided");if(!s)throw new Error("no dictionary provided");if(o&&(!((l=s[o])===null||l===void 0)&&l[i]))return s[o][i];var a="",f=r.getDefaultLang();if(!o||f!==o){var u=s?.[f];u?.[i]&&(a=u[i])}return a},r.formatDate=function(i,s,o){if(!i)throw new Error("no date provided");if(typeof i.getMonth!="function")throw new Error("wrong date format");var l=new Intl.DateTimeFormat(o||r.getDefaultLang(),s);return l.format(i)},r})();return be.LanguageTranslator=n,be}var Ni=xi(),ki=$t('<div class="progress svelte-vj77ev"><div class="progress-bar progress-bar-striped progress-bar-animated svelte-vj77ev" role="progressbar" aria-valuenow="100" aria-valuemin="0" aria-valuemax="100" style="width: 100%"></div></div>'),Ai=$t('<div class="progress svelte-vj77ev"><div class="progress-bar svelte-vj77ev" role="progressbar" aria-valuemin="0" aria-valuemax="100"> </div></div>'),Si=$t('<hb-dialog><span slot="title" class="svelte-vj77ev"><!></span> <div slot="body-content" class="svelte-vj77ev"><!></div> <span slot="modal-footer" class="svelte-vj77ev"></span></hb-dialog>',2);const Ci={hash:"svelte-vj77ev",code:`@import url("https://fonts.googleapis.com/css2?family=Roboto:ital,wght@0,100;0,300;0,400;0,500;0,700;0,900;1,100;1,300;1,400;1,500;1,700;1,900&display=swap");
|
|
3
3
|
/*!
|
|
4
4
|
* Bootstrap v5.1.2 (https://getbootstrap.com/)
|
|
5
5
|
* Copyright 2011-2021 The Bootstrap Authors
|
package/manifest.json
CHANGED
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@htmlbricks/hb-downloader",
|
|
3
|
-
"version": "0.66.
|
|
3
|
+
"version": "0.66.2",
|
|
4
4
|
"contributors": [],
|
|
5
5
|
"description": "Opens `hb-dialog` while `uri` is set and downloads the resource with `XMLHttpRequest` as a blob: optional JSON `headers`, inferred or explicit `targetfilename`, `Content-Disposition` parsing when exposed by CORS, progress bar from `onprogress`, then triggers a browser file save. Dispatches `downloadComplete` or `downloadError` (with `downloadid`) and propagates `modalShow`; clears/aborts when the dialog closes.",
|
|
6
6
|
"licenses": [
|