@htmlbricks/hb-player-input-streaming 0.65.23 → 0.66.0

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,3 +1,3 @@
1
- (function(vt){"use strict";typeof window<"u"&&((window.__svelte??={}).v??=new Set).add("5");const vn=2,_t="[",pt="[!",gt="]",$e={},b=Symbol(),Xe=!1;var _n=Array.isArray,pn=Array.prototype.indexOf,gn=Array.from,Oe=Object.keys,Ne=Object.defineProperty,ae=Object.getOwnPropertyDescriptor,$n=Object.prototype,wn=Array.prototype,mn=Object.getPrototypeOf,$t=Object.isExtensible;function yn(e){for(var t=0;t<e.length;t++)e[t]()}function wt(){var e,t,n=new Promise((r,i)=>{e=r,t=i});return{promise:n,resolve:e,reject:t}}const y=2,Ze=4,Qe=8,H=16,K=32,X=64,Se=128,M=512,E=1024,C=2048,U=4096,Z=8192,W=16384,De=32768,Pe=65536,mt=1<<17,yt=1<<18,re=1<<19,bn=1<<20,ie=32768,et=1<<21,tt=1<<22,Q=1<<23,nt=Symbol("$state"),En=Symbol("legacy props"),ce=new class extends Error{name="StaleReactionError";message="The reaction that called `getAbortSignal()` was re-run or destroyed"},bt=3,Le=8;function Tn(){throw new Error("https://svelte.dev/e/async_derived_orphan")}function kn(e){throw new Error("https://svelte.dev/e/effect_in_teardown")}function xn(){throw new Error("https://svelte.dev/e/effect_in_unowned_derived")}function An(e){throw new Error("https://svelte.dev/e/effect_orphan")}function Rn(){throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}function Cn(){throw new Error("https://svelte.dev/e/hydration_failed")}function On(){throw new Error("https://svelte.dev/e/state_descriptors_fixed")}function Nn(){throw new Error("https://svelte.dev/e/state_prototype_fixed")}function Sn(){throw new Error("https://svelte.dev/e/state_unsafe_mutation")}function Dn(){throw new Error("https://svelte.dev/e/svelte_boundary_reset_onerror")}function rt(e){console.warn("https://svelte.dev/e/hydration_mismatch")}function Pn(){console.warn("https://svelte.dev/e/svelte_boundary_reset_noop")}let T=!1;function je(e){T=e}let g;function z(e){if(e===null)throw rt(),$e;return g=e}function Et(){return z(te(g))}function we(e){if(T){if(te(g)!==null)throw rt(),$e;g=e}}function Ln(e=1){if(T){for(var t=e,n=g;t--;)n=te(n);g=n}}function jn(e=!0){for(var t=0,n=g;;){if(n.nodeType===Le){var r=n.data;if(r===gt){if(t===0)return n;t-=1}else(r===_t||r===pt)&&(t+=1)}var i=te(n);e&&n.remove(),n=i}}function Tt(e){return e===this.v}function Fn(e,t){return e!=e?t==t:e!==t||e!==null&&typeof e=="object"||typeof e=="function"}function Mn(e){return!Fn(e,this.v)}let In=!1,S=null;function de(e){S=e}function kt(e,t=!1,n){S={p:S,i:!1,c:null,e:null,s:e,x:null,l:null}}function xt(e){var t=S,n=t.e;if(n!==null){t.e=null;for(var r of n)Ut(r)}return e!==void 0&&(t.x=e),t.i=!0,S=t.p,e??{}}function At(){return!0}let se=[];function Rt(){var e=se;se=[],yn(e)}function Fe(e){if(se.length===0&&!me){var t=se;queueMicrotask(()=>{t===se&&Rt()})}se.push(e)}function qn(){for(;se.length>0;)Rt()}function Ct(e){var t=_;if(t===null)return v.f|=Q,e;if((t.f&De)===0){if((t.f&Se)===0)throw e;t.b.error(e)}else he(e,t)}function he(e,t){for(;t!==null;){if((t.f&Se)!==0)try{t.b.error(e);return}catch(n){e=n}t=t.parent}throw e}const Me=new Set;let $=null,D=null,P=[],Ie=null,it=!1,me=!1;class I{committed=!1;current=new Map;previous=new Map;#t=new Set;#e=new Set;#o=0;#s=0;#u=null;#l=[];#i=[];skipped_effects=new Set;is_fork=!1;is_deferred(){return this.is_fork||this.#s>0}process(t){P=[],this.apply();var n={parent:null,effect:null,effects:[],render_effects:[],block_effects:[]};for(const r of t)this.#n(r,n);this.is_fork||this.#a(),this.is_deferred()?(this.#r(n.effects),this.#r(n.render_effects),this.#r(n.block_effects)):($=null,St(n.render_effects),St(n.effects),this.#u?.resolve()),D=null}#n(t,n){t.f^=E;for(var r=t.first;r!==null;){var i=r.f,s=(i&(K|X))!==0,l=s&&(i&E)!==0,f=l||(i&Z)!==0||this.skipped_effects.has(r);if((r.f&Se)!==0&&r.b?.is_pending()&&(n={parent:n,effect:r,effects:[],render_effects:[],block_effects:[]}),!f&&r.fn!==null){s?r.f^=E:(i&Ze)!==0?n.effects.push(r):Ae(r)&&((r.f&H)!==0&&n.block_effects.push(r),Re(r));var o=r.first;if(o!==null){r=o;continue}}var u=r.parent;for(r=r.next;r===null&&u!==null;)u===n.effect&&(this.#r(n.effects),this.#r(n.render_effects),this.#r(n.block_effects),n=n.parent),r=u.next,u=u.parent}}#r(t){for(const n of t)((n.f&C)!==0?this.#l:this.#i).push(n),this.#f(n.deps),x(n,E)}#f(t){if(t!==null)for(const n of t)(n.f&y)===0||(n.f&ie)===0||(n.f^=ie,this.#f(n.deps))}capture(t,n){this.previous.has(t)||this.previous.set(t,n),(t.f&Q)===0&&(this.current.set(t,t.v),D?.set(t,t.v))}activate(){$=this,this.apply()}deactivate(){$===this&&($=null,D=null)}flush(){if(this.activate(),P.length>0){if(Nt(),$!==null&&$!==this)return}else this.#o===0&&this.process([]);this.deactivate()}discard(){for(const t of this.#e)t(this);this.#e.clear()}#a(){if(this.#s===0){for(const t of this.#t)t();this.#t.clear()}this.#o===0&&this.#c()}#c(){if(Me.size>1){this.previous.clear();var t=D,n=!0,r={parent:null,effect:null,effects:[],render_effects:[],block_effects:[]};for(const s of Me){if(s===this){n=!1;continue}const l=[];for(const[o,u]of this.current){if(s.current.has(o))if(n&&u!==s.current.get(o))s.current.set(o,u);else continue;l.push(o)}if(l.length===0)continue;const f=[...s.current.keys()].filter(o=>!this.current.has(o));if(f.length>0){var i=P;P=[];const o=new Set,u=new Map;for(const c of l)Dt(c,f,o,u);if(P.length>0){$=s,s.apply();for(const c of P)s.#n(c,r);s.deactivate()}P=i}}$=null,D=t}this.committed=!0,Me.delete(this)}increment(t){this.#o+=1,t&&(this.#s+=1)}decrement(t){this.#o-=1,t&&(this.#s-=1),this.revive()}revive(){for(const t of this.#l)x(t,C),ve(t);for(const t of this.#i)x(t,U),ve(t);this.#l=[],this.#i=[],this.flush()}oncommit(t){this.#t.add(t)}ondiscard(t){this.#e.add(t)}settled(){return(this.#u??=wt()).promise}static ensure(){if($===null){const t=$=new I;Me.add($),me||I.enqueue(()=>{$===t&&t.flush()})}return $}static enqueue(t){Fe(t)}apply(){}}function Ot(e){var t=me;me=!0;try{for(var n;;){if(qn(),P.length===0&&($?.flush(),P.length===0))return Ie=null,n;Nt()}}finally{me=t}}function Nt(){var e=ne;it=!0;var t=null;try{var n=0;for(Ue(!0);P.length>0;){var r=I.ensure();if(n++>1e3){var i,s;Vn()}r.process(P),ee.clear()}}finally{it=!1,Ue(e),Ie=null}}function Vn(){try{Rn()}catch(e){he(e,Ie)}}let G=null;function St(e){var t=e.length;if(t!==0){for(var n=0;n<t;){var r=e[n++];if((r.f&(W|Z))===0&&Ae(r)&&(G=new Set,Re(r),r.deps===null&&r.first===null&&r.nodes_start===null&&(r.teardown===null&&r.ac===null?Jt(r):r.fn=null),G?.size>0)){ee.clear();for(const i of G){if((i.f&(W|Z))!==0)continue;const s=[i];let l=i.parent;for(;l!==null;)G.has(l)&&(G.delete(l),s.push(l)),l=l.parent;for(let f=s.length-1;f>=0;f--){const o=s[f];(o.f&(W|Z))===0&&Re(o)}}G.clear()}}G=null}}function Dt(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&y)!==0?Dt(i,t,n,r):(s&(tt|H))!==0&&(s&C)===0&&Pt(i,t,r)&&(x(i,C),ve(i))}}function Pt(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(t.includes(i))return!0;if((i.f&y)!==0&&Pt(i,t,n))return n.set(i,!0),!0}return n.set(e,!1),!1}function ve(e){for(var t=Ie=e;t.parent!==null;){t=t.parent;var n=t.f;if(it&&t===_&&(n&H)!==0&&(n&yt)===0)return;if((n&(X|K))!==0){if((n&E)===0)return;t.f^=E}}P.push(t)}function Bn(e){let t=0,n=ye(0),r;return()=>{Ye()&&(m(n),Wt(()=>(t===0&&(r=_r(()=>e(()=>be(n)))),t+=1,()=>{Fe(()=>{t-=1,t===0&&(r?.(),r=void 0,be(n))})})))}}var Yn=Pe|re|Se;function Hn(e,t,n){new Un(e,t,n)}class Un{parent;#t=!1;#e;#o=T?g:null;#s;#u;#l;#i=null;#n=null;#r=null;#f=null;#a=null;#c=0;#d=0;#v=!1;#h=null;#w=Bn(()=>(this.#h=ye(this.#c),()=>{this.#h=null}));constructor(t,n,r){this.#e=t,this.#s=n,this.#u=r,this.parent=_.b,this.#t=!!this.#s.pending,this.#l=fr(()=>{if(_.b=this,T){const s=this.#o;Et(),s.nodeType===Le&&s.data===pt?this.#y():this.#m()}else{var i=this.#g();try{this.#i=le(()=>r(i))}catch(s){this.error(s)}this.#d>0?this.#p():this.#t=!1}return()=>{this.#a?.remove()}},Yn),T&&(this.#e=g)}#m(){try{this.#i=le(()=>this.#u(this.#e))}catch(t){this.error(t)}this.#t=!1}#y(){const t=this.#s.pending;t&&(this.#n=le(()=>t(this.#e)),I.enqueue(()=>{var n=this.#g();this.#i=this.#_(()=>(I.ensure(),le(()=>this.#u(n)))),this.#d>0?this.#p():(He(this.#n,()=>{this.#n=null}),this.#t=!1)}))}#g(){var t=this.#e;return this.#t&&(this.#a=Ee(),this.#e.before(this.#a),t=this.#a),t}is_pending(){return this.#t||!!this.parent&&this.parent.is_pending()}has_pending_snippet(){return!!this.#s.pending}#_(t){var n=_,r=v,i=S;Y(this.#l),R(this.#l),de(this.#l.ctx);try{return t()}catch(s){return Ct(s),null}finally{Y(n),R(r),de(i)}}#p(){const t=this.#s.pending;this.#i!==null&&(this.#f=document.createDocumentFragment(),this.#f.append(this.#a),cr(this.#i,this.#f)),this.#n===null&&(this.#n=le(()=>t(this.#e)))}#$(t){if(!this.has_pending_snippet()){this.parent&&this.parent.#$(t);return}this.#d+=t,this.#d===0&&(this.#t=!1,this.#n&&He(this.#n,()=>{this.#n=null}),this.#f&&(this.#e.before(this.#f),this.#f=null))}update_pending_count(t){this.#$(t),this.#c+=t,this.#h&&Ve(this.#h,this.#c)}get_effect_pending(){return this.#w(),m(this.#h)}error(t){var n=this.#s.onerror;let r=this.#s.failed;if(this.#v||!n&&!r)throw t;this.#i&&(q(this.#i),this.#i=null),this.#n&&(q(this.#n),this.#n=null),this.#r&&(q(this.#r),this.#r=null),T&&(z(this.#o),Ln(),z(jn()));var i=!1,s=!1;const l=()=>{if(i){Pn();return}i=!0,s&&Dn(),I.ensure(),this.#c=0,this.#r!==null&&He(this.#r,()=>{this.#r=null}),this.#t=this.has_pending_snippet(),this.#i=this.#_(()=>(this.#v=!1,le(()=>this.#u(this.#e)))),this.#d>0?this.#p():this.#t=!1};var f=v;try{R(null),s=!0,n?.(t,l),s=!1}catch(o){he(o,this.#l&&this.#l.parent)}finally{R(f)}r&&Fe(()=>{this.#r=this.#_(()=>{I.ensure(),this.#v=!0;try{return le(()=>{r(this.#e,()=>t,()=>l)})}catch(o){return he(o,this.#l.parent),null}finally{this.#v=!1}})})}}function Wn(e,t,n,r){const i=Lt;if(n.length===0&&e.length===0){r(t.map(i));return}var s=$,l=_,f=zn();function o(){Promise.all(n.map(u=>Gn(u))).then(u=>{f();try{r([...t.map(i),...u])}catch(c){(l.f&W)===0&&he(c,l)}s?.deactivate(),qe()}).catch(u=>{he(u,l)})}e.length>0?Promise.all(e).then(()=>{f();try{return o()}finally{s?.deactivate(),qe()}}):o()}function zn(){var e=_,t=v,n=S,r=$;return function(s=!0){Y(e),R(t),de(n),s&&r?.activate()}}function qe(){Y(null),R(null),de(null)}function Lt(e){var t=y|C,n=v!==null&&(v.f&y)!==0?v:null;return _!==null&&(_.f|=re),{ctx:S,deps:null,effects:null,equals:Tt,f:t,fn:e,reactions:null,rv:0,v:b,wv:0,parent:n??_,ac:null}}function Gn(e,t){let n=_;n===null&&Tn();var r=n.b,i=void 0,s=ye(b),l=!v,f=new Map;return sr(()=>{var o=wt();i=o.promise;try{Promise.resolve(e()).then(o.resolve,o.reject).then(()=>{u===$&&u.committed&&u.deactivate(),qe()})}catch(a){o.reject(a),qe()}var u=$;if(l){var c=!r.is_pending();r.update_pending_count(1),u.increment(c),f.get(u)?.reject(ce),f.delete(u),f.set(u,o)}const h=(a,d=void 0)=>{if(u.activate(),d)d!==ce&&(s.f|=Q,Ve(s,d));else{(s.f&Q)!==0&&(s.f^=Q),Ve(s,a);for(const[p,j]of f){if(f.delete(p),p===u)break;j.reject(ce)}}l&&(r.update_pending_count(-1),u.decrement(c))};o.promise.then(h,a=>h(null,a||"unknown"))}),Ht(()=>{for(const o of f.values())o.reject(ce)}),new Promise(o=>{function u(c){function h(){c===i?o(s):u(i)}c.then(h,h)}u(i)})}function jt(e){var t=e.effects;if(t!==null){e.effects=null;for(var n=0;n<t.length;n+=1)q(t[n])}}function Jn(e){for(var t=e.parent;t!==null;){if((t.f&y)===0)return(t.f&W)===0?t:null;t=t.parent}return null}function st(e){var t,n=_;Y(Jn(e));try{e.f&=~ie,jt(e),t=nn(e)}finally{Y(n)}return t}function Ft(e){var t=st(e);if(e.equals(t)||($?.is_fork||(e.v=t),e.wv=en()),!fe)if(D!==null)Ye()&&D.set(e,t);else{var n=(e.f&M)===0?U:E;x(e,n)}}let lt=new Set;const ee=new Map;let Mt=!1;function ye(e,t){var n={f:0,v:e,reactions:null,equals:Tt,rv:0,wv:0};return n}function O(e,t){const n=ye(e);return dr(n),n}function Kn(e,t=!1,n=!0){const r=ye(e);return t||(r.equals=Mn),r}function A(e,t,n=!1){v!==null&&(!B||(v.f&mt)!==0)&&At()&&(v.f&(y|H|tt|mt))!==0&&!J?.includes(e)&&Sn();let r=n?_e(t):t;return Ve(e,r)}function Ve(e,t){if(!e.equals(t)){var n=e.v;fe?ee.set(e,t):ee.set(e,n),e.v=t;var r=I.ensure();r.capture(e,n),(e.f&y)!==0&&((e.f&C)!==0&&st(e),x(e,(e.f&M)!==0?E:U)),e.wv=en(),It(e,C),_!==null&&(_.f&E)!==0&&(_.f&(K|X))===0&&(L===null?hr([e]):L.push(e)),!r.is_fork&&lt.size>0&&!Mt&&Xn()}return t}function Xn(){Mt=!1;var e=ne;Ue(!0);const t=Array.from(lt);try{for(const n of t)(n.f&E)!==0&&x(n,U),Ae(n)&&Re(n)}finally{Ue(e)}lt.clear()}function be(e){A(e,e.v+1)}function It(e,t){var n=e.reactions;if(n!==null)for(var r=n.length,i=0;i<r;i++){var s=n[i],l=s.f,f=(l&C)===0;if(f&&x(s,t),(l&y)!==0){var o=s;D?.delete(o),(l&ie)===0&&(l&M&&(s.f|=ie),It(o,U))}else f&&((l&H)!==0&&G!==null&&G.add(s),ve(s))}}function _e(e){if(typeof e!="object"||e===null||nt in e)return e;const t=mn(e);if(t!==$n&&t!==wn)return e;var n=new Map,r=_n(e),i=O(0),s=oe,l=f=>{if(oe===s)return f();var o=v,u=oe;R(null),Qt(s);var c=f();return R(o),Qt(u),c};return r&&n.set("length",O(e.length)),new Proxy(e,{defineProperty(f,o,u){(!("value"in u)||u.configurable===!1||u.enumerable===!1||u.writable===!1)&&On();var c=n.get(o);return c===void 0?c=l(()=>{var h=O(u.value);return n.set(o,h),h}):A(c,u.value,!0),!0},deleteProperty(f,o){var u=n.get(o);if(u===void 0){if(o in f){const c=l(()=>O(b));n.set(o,c),be(i)}}else A(u,b),be(i);return!0},get(f,o,u){if(o===nt)return e;var c=n.get(o),h=o in f;if(c===void 0&&(!h||ae(f,o)?.writable)&&(c=l(()=>{var d=_e(h?f[o]:b),p=O(d);return p}),n.set(o,c)),c!==void 0){var a=m(c);return a===b?void 0:a}return Reflect.get(f,o,u)},getOwnPropertyDescriptor(f,o){var u=Reflect.getOwnPropertyDescriptor(f,o);if(u&&"value"in u){var c=n.get(o);c&&(u.value=m(c))}else if(u===void 0){var h=n.get(o),a=h?.v;if(h!==void 0&&a!==b)return{enumerable:!0,configurable:!0,value:a,writable:!0}}return u},has(f,o){if(o===nt)return!0;var u=n.get(o),c=u!==void 0&&u.v!==b||Reflect.has(f,o);if(u!==void 0||_!==null&&(!c||ae(f,o)?.writable)){u===void 0&&(u=l(()=>{var a=c?_e(f[o]):b,d=O(a);return d}),n.set(o,u));var h=m(u);if(h===b)return!1}return c},set(f,o,u,c){var h=n.get(o),a=o in f;if(r&&o==="length")for(var d=u;d<h.v;d+=1){var p=n.get(d+"");p!==void 0?A(p,b):d in f&&(p=l(()=>O(b)),n.set(d+"",p))}if(h===void 0)(!a||ae(f,o)?.writable)&&(h=l(()=>O(void 0)),A(h,_e(u)),n.set(o,h));else{a=h.v!==b;var j=l(()=>_e(u));A(h,j)}var F=Reflect.getOwnPropertyDescriptor(f,o);if(F?.set&&F.set.call(c,u),!a){if(r&&typeof o=="string"){var Je=n.get("length"),ge=Number(o);Number.isInteger(ge)&&ge>=Je.v&&A(Je,ge+1)}be(i)}return!0},ownKeys(f){m(i);var o=Reflect.ownKeys(f).filter(h=>{var a=n.get(h);return a===void 0||a.v!==b});for(var[u,c]of n)c.v!==b&&!(u in f)&&o.push(u);return o},setPrototypeOf(){Nn()}})}var qt,Vt,Bt,Yt;function ft(){if(qt===void 0){qt=window,Vt=/Firefox/.test(navigator.userAgent);var e=Element.prototype,t=Node.prototype,n=Text.prototype;Bt=ae(t,"firstChild").get,Yt=ae(t,"nextSibling").get,$t(e)&&(e.__click=void 0,e.__className=void 0,e.__attributes=null,e.__style=void 0,e.__e=void 0),$t(n)&&(n.__t=void 0)}}function Ee(e=""){return document.createTextNode(e)}function Be(e){return Bt.call(e)}function te(e){return Yt.call(e)}function Te(e,t){if(!T)return Be(e);var n=Be(g);if(n===null)n=g.appendChild(Ee());else if(t&&n.nodeType!==bt){var r=Ee();return n?.before(r),z(r),r}return z(n),n}function ke(e,t=1,n=!1){let r=T?g:e;for(var i;t--;)i=r,r=te(r);if(!T)return r;if(n&&r?.nodeType!==bt){var s=Ee();return r===null?i?.after(s):r.before(s),z(s),s}return z(r),r}function Zn(e){e.textContent=""}function ot(e){var t=v,n=_;R(null),Y(null);try{return e()}finally{R(t),Y(n)}}function Qn(e){_===null&&(v===null&&An(),xn()),fe&&kn()}function er(e,t){var n=t.last;n===null?t.last=t.first=e:(n.next=e,e.prev=n,t.last=e)}function V(e,t,n){var r=_;r!==null&&(r.f&Z)!==0&&(e|=Z);var i={ctx:S,deps:null,nodes_start:null,nodes_end:null,f:e|C|M,first:null,fn:t,last:null,next:null,parent:r,b:r&&r.b,prev:null,teardown:null,transitions:null,wv:0,ac:null};if(n)try{Re(i),i.f|=De}catch(f){throw q(i),f}else t!==null&&ve(i);var s=i;if(n&&s.deps===null&&s.teardown===null&&s.nodes_start===null&&s.first===s.last&&(s.f&re)===0&&(s=s.first,(e&H)!==0&&(e&Pe)!==0&&s!==null&&(s.f|=Pe)),s!==null&&(s.parent=r,r!==null&&er(s,r),v!==null&&(v.f&y)!==0&&(e&X)===0)){var l=v;(l.effects??=[]).push(s)}return i}function Ye(){return v!==null&&!B}function Ht(e){const t=V(Qe,null,!1);return x(t,E),t.teardown=e,t}function tr(e){Qn();var t=_.f,n=!v&&(t&K)!==0&&(t&De)===0;if(n){var r=S;(r.e??=[]).push(e)}else return Ut(e)}function Ut(e){return V(Ze|bn,e,!1)}function nr(e){I.ensure();const t=V(X|re,e,!0);return()=>{q(t)}}function rr(e){I.ensure();const t=V(X|re,e,!0);return(n={})=>new Promise(r=>{n.outro?He(t,()=>{q(t),r(void 0)}):(q(t),r(void 0))})}function ir(e){return V(Ze,e,!1)}function sr(e){return V(tt|re,e,!0)}function Wt(e,t=0){return V(Qe|t,e,!0)}function lr(e,t=[],n=[],r=[]){Wn(r,t,n,i=>{V(Qe,()=>e(...i.map(m)),!0)})}function fr(e,t=0){var n=V(H|t,e,!0);return n}function le(e){return V(K|re,e,!0)}function zt(e){var t=e.teardown;if(t!==null){const n=fe,r=v;Xt(!0),R(null);try{t.call(null)}finally{Xt(n),R(r)}}}function Gt(e,t=!1){var n=e.first;for(e.first=e.last=null;n!==null;){const i=n.ac;i!==null&&ot(()=>{i.abort(ce)});var r=n.next;(n.f&X)!==0?n.parent=null:q(n,t),n=r}}function or(e){for(var t=e.first;t!==null;){var n=t.next;(t.f&K)===0&&q(t),t=n}}function q(e,t=!0){var n=!1;(t||(e.f&yt)!==0)&&e.nodes_start!==null&&e.nodes_end!==null&&(ur(e.nodes_start,e.nodes_end),n=!0),Gt(e,t&&!n),We(e,0),x(e,W);var r=e.transitions;if(r!==null)for(const s of r)s.stop();zt(e);var i=e.parent;i!==null&&i.first!==null&&Jt(e),e.next=e.prev=e.teardown=e.ctx=e.deps=e.fn=e.nodes_start=e.nodes_end=e.ac=null}function ur(e,t){for(;e!==null;){var n=e===t?null:te(e);e.remove(),e=n}}function Jt(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=[];Kt(e,r,!0),ar(r,()=>{n&&q(e),t&&t()})}function ar(e,t){var n=e.length;if(n>0){var r=()=>--n||t();for(var i of e)i.out(r)}else t()}function Kt(e,t,n){if((e.f&Z)===0){if(e.f^=Z,e.transitions!==null)for(const l of e.transitions)(l.is_global||n)&&t.push(l);for(var r=e.first;r!==null;){var i=r.next,s=(r.f&Pe)!==0||(r.f&K)!==0&&(e.f&H)!==0;Kt(r,t,s?n:!1),r=i}}}function cr(e,t){for(var n=e.nodes_start,r=e.nodes_end;n!==null;){var i=n===r?null:te(n);t.append(n),n=i}}let ne=!1;function Ue(e){ne=e}let fe=!1;function Xt(e){fe=e}let v=null,B=!1;function R(e){v=e}let _=null;function Y(e){_=e}let J=null;function dr(e){v!==null&&(J===null?J=[e]:J.push(e))}let k=null,N=0,L=null;function hr(e){L=e}let Zt=1,xe=0,oe=xe;function Qt(e){oe=e}function en(){return++Zt}function Ae(e){var t=e.f;if((t&C)!==0)return!0;if(t&y&&(e.f&=~ie),(t&U)!==0){var n=e.deps;if(n!==null)for(var r=n.length,i=0;i<r;i++){var s=n[i];if(Ae(s)&&Ft(s),s.wv>e.wv)return!0}(t&M)!==0&&D===null&&x(e,E)}return!1}function tn(e,t,n=!0){var r=e.reactions;if(r!==null&&!J?.includes(e))for(var i=0;i<r.length;i++){var s=r[i];(s.f&y)!==0?tn(s,t,!1):t===s&&(n?x(s,C):(s.f&E)!==0&&x(s,U),ve(s))}}function nn(e){var t=k,n=N,r=L,i=v,s=J,l=S,f=B,o=oe,u=e.f;k=null,N=0,L=null,v=(u&(K|X))===0?e:null,J=null,de(e.ctx),B=!1,oe=++xe,e.ac!==null&&(ot(()=>{e.ac.abort(ce)}),e.ac=null);try{e.f|=et;var c=e.fn,h=c(),a=e.deps;if(k!==null){var d;if(We(e,N),a!==null&&N>0)for(a.length=N+k.length,d=0;d<k.length;d++)a[N+d]=k[d];else e.deps=a=k;if(ne&&Ye()&&(e.f&M)!==0)for(d=N;d<a.length;d++)(a[d].reactions??=[]).push(e)}else a!==null&&N<a.length&&(We(e,N),a.length=N);if(At()&&L!==null&&!B&&a!==null&&(e.f&(y|U|C))===0)for(d=0;d<L.length;d++)tn(L[d],e);return i!==null&&i!==e&&(xe++,L!==null&&(r===null?r=L:r.push(...L))),(e.f&Q)!==0&&(e.f^=Q),h}catch(p){return Ct(p)}finally{e.f^=et,k=t,N=n,L=r,v=i,J=s,de(l),B=f,oe=o}}function vr(e,t){let n=t.reactions;if(n!==null){var r=pn.call(n,e);if(r!==-1){var i=n.length-1;i===0?n=t.reactions=null:(n[r]=n[i],n.pop())}}n===null&&(t.f&y)!==0&&(k===null||!k.includes(t))&&(x(t,U),(t.f&M)!==0&&(t.f^=M,t.f&=~ie),jt(t),We(t,0))}function We(e,t){var n=e.deps;if(n!==null)for(var r=t;r<n.length;r++)vr(e,n[r])}function Re(e){var t=e.f;if((t&W)===0){x(e,E);var n=_,r=ne;_=e,ne=!0;try{(t&H)!==0?or(e):Gt(e),zt(e);var i=nn(e);e.teardown=typeof i=="function"?i:null,e.wv=Zt;var s;Xe&&In&&(e.f&C)!==0&&e.deps}finally{ne=r,_=n}}}function m(e){var t=e.f,n=(t&y)!==0;if(v!==null&&!B){var r=_!==null&&(_.f&W)!==0;if(!r&&!J?.includes(e)){var i=v.deps;if((v.f&et)!==0)e.rv<xe&&(e.rv=xe,k===null&&i!==null&&i[N]===e?N++:k===null?k=[e]:k.includes(e)||k.push(e));else{(v.deps??=[]).push(e);var s=e.reactions;s===null?e.reactions=[v]:s.includes(v)||s.push(v)}}}if(fe){if(ee.has(e))return ee.get(e);if(n){var l=e,f=l.v;return((l.f&E)===0&&l.reactions!==null||sn(l))&&(f=st(l)),ee.set(l,f),f}}else n&&!D?.has(e)&&(l=e,Ae(l)&&Ft(l),ne&&Ye()&&(l.f&M)===0&&rn(l));if(D?.has(e))return D.get(e);if((e.f&Q)!==0)throw e.v;return e.v}function rn(e){if(e.deps!==null){e.f^=M;for(const t of e.deps)(t.reactions??=[]).push(e),(t.f&y)!==0&&(t.f&M)===0&&rn(t)}}function sn(e){if(e.v===b)return!0;if(e.deps===null)return!1;for(const t of e.deps)if(ee.has(t)||(t.f&y)!==0&&sn(t))return!0;return!1}function _r(e){var t=B;try{return B=!0,e()}finally{B=t}}const pr=-7169;function x(e,t){e.f=e.f&pr|t}const ln=new Set,ut=new Set;function gr(e,t,n,r={}){function i(s){if(r.capture||Ce.call(t,s),!s.cancelBubble)return ot(()=>n?.call(this,s))}return e.startsWith("pointer")||e.startsWith("touch")||e==="wheel"?Fe(()=>{t.addEventListener(e,i,r)}):t.addEventListener(e,i,r),i}function at(e,t,n,r,i){var s={capture:r,passive:i},l=gr(e,t,n,s);(t===document.body||t===window||t===document||t instanceof HTMLMediaElement)&&Ht(()=>{t.removeEventListener(e,l,s)})}function $r(e){for(var t=0;t<e.length;t++)ln.add(e[t]);for(var n of ut)n(e)}let fn=null;function Ce(e){var t=this,n=t.ownerDocument,r=e.type,i=e.composedPath?.()||[],s=i[0]||e.target;fn=e;var l=0,f=fn===e&&e.__root;if(f){var o=i.indexOf(f);if(o!==-1&&(t===document||t===window)){e.__root=t;return}var u=i.indexOf(t);if(u===-1)return;o<=u&&(l=o)}if(s=i[l]||e.target,s!==t){Ne(e,"currentTarget",{configurable:!0,get(){return s||n}});var c=v,h=_;R(null),Y(null);try{for(var a,d=[];s!==null;){var p=s.assignedSlot||s.parentNode||s.host||null;try{var j=s["__"+r];j!=null&&(!s.disabled||e.target===s)&&j.call(s,e)}catch(F){a?d.push(F):a=F}if(e.cancelBubble||p===t||p===null)break;s=p}if(a){for(let F of d)queueMicrotask(()=>{throw F});throw a}}finally{e.__root=t,delete e.currentTarget,R(c),Y(h)}}}function wr(e){var t=document.createElement("template");return t.innerHTML=e.replaceAll("<!>","<!---->"),t.content}function ct(e,t){var n=_;n.nodes_start===null&&(n.nodes_start=e,n.nodes_end=t)}function mr(e,t){var n=(t&vn)!==0,r,i=!e.startsWith("<!>");return()=>{if(T)return ct(g,null),g;r===void 0&&(r=wr(i?e:"<!>"+e),r=Be(r));var s=n||Vt?document.importNode(r,!0):r.cloneNode(!0);return ct(s,s),s}}function on(e,t){if(T){var n=_;((n.f&De)===0||n.nodes_end===null)&&(n.nodes_end=g),Et();return}e!==null&&e.before(t)}const yr=["touchstart","touchmove"];function br(e){return yr.includes(e)}function ze(e,t){var n=t==null?"":typeof t=="object"?t+"":t;n!==(e.__t??=e.nodeValue)&&(e.__t=n,e.nodeValue=n+"")}function un(e,t){return an(e,t)}function Er(e,t){ft(),t.intro=t.intro??!1;const n=t.target,r=T,i=g;try{for(var s=Be(n);s&&(s.nodeType!==Le||s.data!==_t);)s=te(s);if(!s)throw $e;je(!0),z(s);const l=an(e,{...t,anchor:s});return je(!1),l}catch(l){if(l instanceof Error&&l.message.split(`
2
- `).some(f=>f.startsWith("https://svelte.dev/e/")))throw l;return l!==$e&&console.warn("Failed to hydrate: ",l),t.recover===!1&&Cn(),ft(),Zn(n),je(!1),un(e,t)}finally{je(r),z(i)}}const pe=new Map;function an(e,{target:t,anchor:n,props:r={},events:i,context:s,intro:l=!0}){ft();var f=new Set,o=h=>{for(var a=0;a<h.length;a++){var d=h[a];if(!f.has(d)){f.add(d);var p=br(d);t.addEventListener(d,Ce,{passive:p});var j=pe.get(d);j===void 0?(document.addEventListener(d,Ce,{passive:p}),pe.set(d,1)):pe.set(d,j+1)}}};o(gn(ln)),ut.add(o);var u=void 0,c=rr(()=>{var h=n??t.appendChild(Ee());return Hn(h,{pending:()=>{}},a=>{if(s){kt({});var d=S;d.c=s}if(i&&(r.$$events=i),T&&ct(a,null),u=e(a,r)||{},T&&(_.nodes_end=g,g===null||g.nodeType!==Le||g.data!==gt))throw rt(),$e;s&&xt()}),()=>{for(var a of f){t.removeEventListener(a,Ce);var d=pe.get(a);--d===0?(document.removeEventListener(a,Ce),pe.delete(a)):pe.set(a,d)}ut.delete(o),h!==n&&h.parentNode?.removeChild(h)}});return dt.set(u,c),u}let dt=new WeakMap;function Tr(e,t){const n=dt.get(e);return n?(dt.delete(e),n(t)):Promise.resolve()}function kr(e,t){ir(()=>{var n=e.getRootNode(),r=n.host?n:n.head??n.ownerDocument.head;if(!r.querySelector("#"+t.hash)){const i=document.createElement("style");i.id=t.hash,i.textContent=t.code,r.appendChild(i)}})}function xr(e,t,n,r){var i=r,s=!0,l=()=>(s&&(s=!1,i=r),i),f;f=e[t],f===void 0&&r!==void 0&&(f=l());var o;o=()=>{var a=e[t];return a===void 0?l():(s=!0,a)};var u=!1,c=Lt(()=>(u=!1,o())),h=_;return(function(a,d){if(arguments.length>0){const p=d?m(c):a;return A(c,p),u=!0,i!==void 0&&(i=p),a}return fe&&u||(h.f&W)!==0?c.v:m(c)})}function Ar(e){return new Rr(e)}class Rr{#t;#e;constructor(t){var n=new Map,r=(s,l)=>{var f=Kn(l,!1,!1);return n.set(s,f),f};const i=new Proxy({...t.props||{},$$events:{}},{get(s,l){return m(n.get(l)??r(l,Reflect.get(s,l)))},has(s,l){return l===En?!0:(m(n.get(l)??r(l,Reflect.get(s,l))),Reflect.has(s,l))},set(s,l,f){return A(n.get(l)??r(l,f),f),Reflect.set(s,l,f)}});this.#e=(t.hydrate?Er:un)(t.component,{target:t.target,anchor:t.anchor,props:i,context:t.context,intro:t.intro??!1,recover:t.recover}),(!t?.props?.$$host||t.sync===!1)&&Ot(),this.#t=i.$$events;for(const s of Object.keys(this.#e))s==="$set"||s==="$destroy"||s==="$on"||Ne(this,s,{get(){return this.#e[s]},set(l){this.#e[s]=l},enumerable:!0});this.#e.$set=s=>{Object.assign(i,s)},this.#e.$destroy=()=>{Tr(this.#e)}}$set(t){this.#e.$set(t)}$on(t,n){this.#t[t]=this.#t[t]||[];const r=(...i)=>n.call(this,...i);return this.#t[t].push(r),()=>{this.#t[t]=this.#t[t].filter(i=>i!==r)}}$destroy(){this.#e.$destroy()}}let cn;typeof HTMLElement=="function"&&(cn=class extends HTMLElement{$$ctor;$$s;$$c;$$cn=!1;$$d={};$$r=!1;$$p_d={};$$l={};$$l_u=new Map;$$me;constructor(e,t,n){super(),this.$$ctor=e,this.$$s=t,n&&this.attachShadow({mode:"open"})}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=document.createElement("slot");r!=="default"&&(s.name=r),on(i,s)}};if(await Promise.resolve(),!this.$$cn||this.$$c)return;const t={},n=Cr(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]=Ge(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=Ar({component:this.$$ctor,target:this.shadowRoot||this,props:{...this.$$d,$$slots:t,$$host:this}}),this.$$me=nr(()=>{Wt(()=>{this.$$r=!0;for(const r of Oe(this.$$c)){if(!this.$$p_d[r]?.reflect)continue;this.$$d[r]=this.$$c[r];const i=Ge(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]=Ge(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 Oe(this.$$p_d).find(t=>this.$$p_d[t].attribute===e||!this.$$p_d[t].attribute&&t.toLowerCase()===e)||e}});function Ge(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 Cr(e){const t={};return e.childNodes.forEach(n=>{t[n.slot||"default"]=!0}),t}function Or(e,t,n,r,i,s){let l=class extends cn{constructor(){super(e,n,i),this.$$p_d=t}static get observedAttributes(){return Oe(t).map(f=>(t[f].attribute||f).toLowerCase())}};return Oe(t).forEach(f=>{Ne(l.prototype,f,{get(){return this.$$c&&f in this.$$c?this.$$c[f]:this.$$d[f]},set(o){o=Ge(f,o,t),this.$$d[f]=o;var u=this.$$c;if(u){var c=ae(u,f)?.get;c?u[f]=o:u.$set({[f]:o})}}})}),r.forEach(f=>{Ne(l.prototype,f,{get(){return this.$$c?.[f]}})}),e.element=l,l}var ue={},dn;function Nr(){if(dn)return ue;dn=1,Object.defineProperty(ue,"__esModule",{value:!0}),ue.LanguageTranslator=void 0,ue.getChildStyleToPass=e,ue.addComponent=t;function e(r,i){var s,l,f="";try{if(r&&i?.length&&(!((s=Object.keys(r))===null||s===void 0)&&s.length)&&(!((l=i?.filter(function(a){return Object.keys(r).includes(a.name)}))===null||l===void 0)&&l.length))for(var o=function(a){var d=i?.filter(function(p){return p.name===a&&p.defaultValue!==r[a]});d&&(f+="".concat(a,":").concat(r[a],";"))},u=0,c=Object.keys(r);u<c.length;u++){var h=c[u];o(h)}}catch(a){console.error("error getting child style to pass",a)}finally{return f}}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 l=r?.iifePath||"main.iife.js";if(!document.getElementById(s+"-script"))try{var f=document.createElement("script");if(f.id=s+"-script",f.src="https://cdn.jsdelivr.net/npm/".concat(r.repoName,"@").concat(r.version,"/").concat(l),r?.local)f.src="".concat(r.local);else if(location.href.includes("localhost:6006")){var o=s.split("-")[0];f.src="http://localhost:6006/webcomponents/".concat(s.replace(o+"-",""),"/").concat(l)}document.head.appendChild(f)}catch(u){console.warn(u)}}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,l){return r.formatDate(i,s,l||this.lang)},r.getDefaultLang=function(){var i,s,l,f="en";return navigator?.languages&&(!((l=(s=(i=navigator.languages[0])===null||i===void 0?void 0:i.split("-")[0])===null||s===void 0?void 0:s.toLowerCase())===null||l===void 0)&&l.length)&&(f=navigator.languages[0].split("-")[0].toLowerCase()),f},r.getDictionaryWord=function(i,s,l){var f;if(!i)throw new Error("no wordKey provided");if(!s)throw new Error("no dictionary provided");if(l&&(!((f=s[l])===null||f===void 0)&&f[i]))return s[l][i];var o="",u=r.getDefaultLang();if(!l||u!==l){var c=s?.[u];c?.[i]&&(o=c[i])}return o},r.formatDate=function(i,s,l){if(!i)throw new Error("no date provided");if(typeof i.getMonth!="function")throw new Error("wrong date format");var f=new Intl.DateTimeFormat(l||r.getDefaultLang(),s);return f.format(i)},r})();return ue.LanguageTranslator=n,ue}Nr();var Sr=mr('<div class="container svelte-110s2rp"><video id="video"><track kind="captions"/></video> <div> <button> </button> <button>FH</button> <button> </button> <button> </button></div></div>',2);const Dr={hash:"svelte-110s2rp",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");:host {font-family:"Roboto", sans-serif;}.container.svelte-110s2rp {position:relative;}'};function hn(e,t){kt(t,!0),kr(e,Dr);function n(w,jr){t.$$host.dispatchEvent(new CustomEvent(w,{detail:jr}))}let r=xr(t,"id",7,""),i,s=O(!1),l=O(!0),f=O(!0),o=O(0);_e({});const u=t.$$host;tr(()=>{});async function c(){try{const w=await navigator.mediaDevices.getUserMedia({video:!0,audio:!0});console.info("access to camera granted"),n("AudioVideoAccess",{granted:!0,id:r()}),i=u.shadowRoot?.querySelector("video"),i.srcObject=w,i.play(),n("VideoInitialized",{videoElement:i,id:r()})}catch(w){throw console.error("error on garantAccessToCamera",w),n("AudioVideoAccess",{granted:!1,id:r()}),new Error("camera access denied")}}c().then(()=>{console.log("camera initialized")}).catch(w=>{console.log("camera access denied",w)});var h={get id(){return r()},set id(w=""){r(w),Ot()}},a=Sr(),d=Te(a),p=ke(d,2),j=Te(p,!0),F=ke(j);F.__click=()=>{m(s)?i.pause():i.play()};var Je=Te(F,!0);we(F);var ge=ke(F,2);ge.__click=()=>{i.requestFullscreen()};var Ke=ke(ge,2);Ke.__click=()=>{i.srcObject.getTracks().filter(w=>w.kind==="video").forEach(w=>{A(l,!w.enabled),w.enabled=m(l)})};var Pr=Te(Ke);we(Ke);var ht=ke(Ke,2);ht.__click=()=>{i.srcObject.getTracks().filter(w=>w.kind==="audio").forEach(w=>{A(f,!w.enabled),w.enabled=m(f)})};var Lr=Te(ht);return we(ht),we(p),we(a),lr(()=>{ze(j,m(o)),ze(Je,m(s)?"pause":"play"),ze(Pr,`${m(l)?"remove":"add"} video`),ze(Lr,`${m(f)?"remove":"add"} audio`)}),at("play",d,()=>{A(s,!0)}),at("pause",d,()=>{A(s,!1)}),at("timeupdate",d,()=>{A(o,i.currentTime,!0)}),on(e,a),xt(h)}$r(["click"]),customElements.define("hb-player-input-streaming",Or(hn,{id:{}},[],[],!0)),vt.Component=hn,Object.defineProperty(vt,Symbol.toStringTag,{value:"Module"})})(this["player-input-streaming"]=this["player-input-streaming"]||{});
1
+ (function(vt){"use strict";typeof window<"u"&&((window.__svelte??={}).v??=new Set).add("5");const vn=2,_t="[",pt="[!",gt="]",ge={},b=Symbol(),Xe=!1;var _n=Array.isArray,pn=Array.prototype.indexOf,gn=Array.from,Oe=Object.keys,Ne=Object.defineProperty,ae=Object.getOwnPropertyDescriptor,$n=Object.prototype,wn=Array.prototype,mn=Object.getPrototypeOf,$t=Object.isExtensible;function yn(e){for(var t=0;t<e.length;t++)e[t]()}function wt(){var e,t,n=new Promise((r,i)=>{e=r,t=i});return{promise:n,resolve:e,reject:t}}const y=2,Ze=4,Qe=8,H=16,K=32,X=64,Se=128,M=512,E=1024,C=2048,U=4096,Z=8192,W=16384,De=32768,Pe=65536,mt=1<<17,yt=1<<18,re=1<<19,bn=1<<20,ie=32768,et=1<<21,tt=1<<22,Q=1<<23,nt=Symbol("$state"),En=Symbol("legacy props"),ce=new class extends Error{name="StaleReactionError";message="The reaction that called `getAbortSignal()` was re-run or destroyed"},bt=3,Le=8;function Tn(){throw new Error("https://svelte.dev/e/async_derived_orphan")}function kn(e){throw new Error("https://svelte.dev/e/effect_in_teardown")}function xn(){throw new Error("https://svelte.dev/e/effect_in_unowned_derived")}function An(e){throw new Error("https://svelte.dev/e/effect_orphan")}function Rn(){throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}function Cn(){throw new Error("https://svelte.dev/e/hydration_failed")}function On(){throw new Error("https://svelte.dev/e/state_descriptors_fixed")}function Nn(){throw new Error("https://svelte.dev/e/state_prototype_fixed")}function Sn(){throw new Error("https://svelte.dev/e/state_unsafe_mutation")}function Dn(){throw new Error("https://svelte.dev/e/svelte_boundary_reset_onerror")}function rt(e){console.warn("https://svelte.dev/e/hydration_mismatch")}function Pn(){console.warn("https://svelte.dev/e/svelte_boundary_reset_noop")}let T=!1;function je(e){T=e}let g;function z(e){if(e===null)throw rt(),ge;return g=e}function Et(){return z(te(g))}function $e(e){if(T){if(te(g)!==null)throw rt(),ge;g=e}}function Ln(e=1){if(T){for(var t=e,n=g;t--;)n=te(n);g=n}}function jn(e=!0){for(var t=0,n=g;;){if(n.nodeType===Le){var r=n.data;if(r===gt){if(t===0)return n;t-=1}else(r===_t||r===pt)&&(t+=1)}var i=te(n);e&&n.remove(),n=i}}function Tt(e){return e===this.v}function Fn(e,t){return e!=e?t==t:e!==t||e!==null&&typeof e=="object"||typeof e=="function"}function Mn(e){return!Fn(e,this.v)}let In=!1,N=null;function de(e){N=e}function kt(e,t=!1,n){N={p:N,i:!1,c:null,e:null,s:e,x:null,l:null}}function xt(e){var t=N,n=t.e;if(n!==null){t.e=null;for(var r of n)Ut(r)}return e!==void 0&&(t.x=e),t.i=!0,N=t.p,e??{}}function At(){return!0}let se=[];function Rt(){var e=se;se=[],yn(e)}function Fe(e){if(se.length===0&&!we){var t=se;queueMicrotask(()=>{t===se&&Rt()})}se.push(e)}function qn(){for(;se.length>0;)Rt()}function Ct(e){var t=_;if(t===null)return v.f|=Q,e;if((t.f&De)===0){if((t.f&Se)===0)throw e;t.b.error(e)}else he(e,t)}function he(e,t){for(;t!==null;){if((t.f&Se)!==0)try{t.b.error(e);return}catch(n){e=n}t=t.parent}throw e}const Me=new Set;let $=null,S=null,D=[],Ie=null,it=!1,we=!1;class I{committed=!1;current=new Map;previous=new Map;#t=new Set;#e=new Set;#o=0;#s=0;#u=null;#l=[];#i=[];skipped_effects=new Set;is_fork=!1;is_deferred(){return this.is_fork||this.#s>0}process(t){D=[],this.apply();var n={parent:null,effect:null,effects:[],render_effects:[],block_effects:[]};for(const r of t)this.#n(r,n);this.is_fork||this.#a(),this.is_deferred()?(this.#r(n.effects),this.#r(n.render_effects),this.#r(n.block_effects)):($=null,St(n.render_effects),St(n.effects),this.#u?.resolve()),S=null}#n(t,n){t.f^=E;for(var r=t.first;r!==null;){var i=r.f,s=(i&(K|X))!==0,l=s&&(i&E)!==0,f=l||(i&Z)!==0||this.skipped_effects.has(r);if((r.f&Se)!==0&&r.b?.is_pending()&&(n={parent:n,effect:r,effects:[],render_effects:[],block_effects:[]}),!f&&r.fn!==null){s?r.f^=E:(i&Ze)!==0?n.effects.push(r):Ae(r)&&((r.f&H)!==0&&n.block_effects.push(r),Re(r));var o=r.first;if(o!==null){r=o;continue}}var u=r.parent;for(r=r.next;r===null&&u!==null;)u===n.effect&&(this.#r(n.effects),this.#r(n.render_effects),this.#r(n.block_effects),n=n.parent),r=u.next,u=u.parent}}#r(t){for(const n of t)((n.f&C)!==0?this.#l:this.#i).push(n),this.#f(n.deps),x(n,E)}#f(t){if(t!==null)for(const n of t)(n.f&y)===0||(n.f&ie)===0||(n.f^=ie,this.#f(n.deps))}capture(t,n){this.previous.has(t)||this.previous.set(t,n),(t.f&Q)===0&&(this.current.set(t,t.v),S?.set(t,t.v))}activate(){$=this,this.apply()}deactivate(){$===this&&($=null,S=null)}flush(){if(this.activate(),D.length>0){if(Nt(),$!==null&&$!==this)return}else this.#o===0&&this.process([]);this.deactivate()}discard(){for(const t of this.#e)t(this);this.#e.clear()}#a(){if(this.#s===0){for(const t of this.#t)t();this.#t.clear()}this.#o===0&&this.#c()}#c(){if(Me.size>1){this.previous.clear();var t=S,n=!0,r={parent:null,effect:null,effects:[],render_effects:[],block_effects:[]};for(const s of Me){if(s===this){n=!1;continue}const l=[];for(const[o,u]of this.current){if(s.current.has(o))if(n&&u!==s.current.get(o))s.current.set(o,u);else continue;l.push(o)}if(l.length===0)continue;const f=[...s.current.keys()].filter(o=>!this.current.has(o));if(f.length>0){var i=D;D=[];const o=new Set,u=new Map;for(const c of l)Dt(c,f,o,u);if(D.length>0){$=s,s.apply();for(const c of D)s.#n(c,r);s.deactivate()}D=i}}$=null,S=t}this.committed=!0,Me.delete(this)}increment(t){this.#o+=1,t&&(this.#s+=1)}decrement(t){this.#o-=1,t&&(this.#s-=1),this.revive()}revive(){for(const t of this.#l)x(t,C),ve(t);for(const t of this.#i)x(t,U),ve(t);this.#l=[],this.#i=[],this.flush()}oncommit(t){this.#t.add(t)}ondiscard(t){this.#e.add(t)}settled(){return(this.#u??=wt()).promise}static ensure(){if($===null){const t=$=new I;Me.add($),we||I.enqueue(()=>{$===t&&t.flush()})}return $}static enqueue(t){Fe(t)}apply(){}}function Ot(e){var t=we;we=!0;try{for(var n;;){if(qn(),D.length===0&&($?.flush(),D.length===0))return Ie=null,n;Nt()}}finally{we=t}}function Nt(){var e=ne;it=!0;var t=null;try{var n=0;for(Ue(!0);D.length>0;){var r=I.ensure();if(n++>1e3){var i,s;Vn()}r.process(D),ee.clear()}}finally{it=!1,Ue(e),Ie=null}}function Vn(){try{Rn()}catch(e){he(e,Ie)}}let G=null;function St(e){var t=e.length;if(t!==0){for(var n=0;n<t;){var r=e[n++];if((r.f&(W|Z))===0&&Ae(r)&&(G=new Set,Re(r),r.deps===null&&r.first===null&&r.nodes_start===null&&(r.teardown===null&&r.ac===null?Jt(r):r.fn=null),G?.size>0)){ee.clear();for(const i of G){if((i.f&(W|Z))!==0)continue;const s=[i];let l=i.parent;for(;l!==null;)G.has(l)&&(G.delete(l),s.push(l)),l=l.parent;for(let f=s.length-1;f>=0;f--){const o=s[f];(o.f&(W|Z))===0&&Re(o)}}G.clear()}}G=null}}function Dt(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&y)!==0?Dt(i,t,n,r):(s&(tt|H))!==0&&(s&C)===0&&Pt(i,t,r)&&(x(i,C),ve(i))}}function Pt(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(t.includes(i))return!0;if((i.f&y)!==0&&Pt(i,t,n))return n.set(i,!0),!0}return n.set(e,!1),!1}function ve(e){for(var t=Ie=e;t.parent!==null;){t=t.parent;var n=t.f;if(it&&t===_&&(n&H)!==0&&(n&yt)===0)return;if((n&(X|K))!==0){if((n&E)===0)return;t.f^=E}}D.push(t)}function Bn(e){let t=0,n=me(0),r;return()=>{Ye()&&(m(n),Wt(()=>(t===0&&(r=_r(()=>e(()=>ye(n)))),t+=1,()=>{Fe(()=>{t-=1,t===0&&(r?.(),r=void 0,ye(n))})})))}}var Yn=Pe|re|Se;function Hn(e,t,n){new Un(e,t,n)}class Un{parent;#t=!1;#e;#o=T?g:null;#s;#u;#l;#i=null;#n=null;#r=null;#f=null;#a=null;#c=0;#d=0;#v=!1;#h=null;#w=Bn(()=>(this.#h=me(this.#c),()=>{this.#h=null}));constructor(t,n,r){this.#e=t,this.#s=n,this.#u=r,this.parent=_.b,this.#t=!!this.#s.pending,this.#l=fr(()=>{if(_.b=this,T){const s=this.#o;Et(),s.nodeType===Le&&s.data===pt?this.#y():this.#m()}else{var i=this.#g();try{this.#i=le(()=>r(i))}catch(s){this.error(s)}this.#d>0?this.#p():this.#t=!1}return()=>{this.#a?.remove()}},Yn),T&&(this.#e=g)}#m(){try{this.#i=le(()=>this.#u(this.#e))}catch(t){this.error(t)}this.#t=!1}#y(){const t=this.#s.pending;t&&(this.#n=le(()=>t(this.#e)),I.enqueue(()=>{var n=this.#g();this.#i=this.#_(()=>(I.ensure(),le(()=>this.#u(n)))),this.#d>0?this.#p():(He(this.#n,()=>{this.#n=null}),this.#t=!1)}))}#g(){var t=this.#e;return this.#t&&(this.#a=Ee(),this.#e.before(this.#a),t=this.#a),t}is_pending(){return this.#t||!!this.parent&&this.parent.is_pending()}has_pending_snippet(){return!!this.#s.pending}#_(t){var n=_,r=v,i=N;Y(this.#l),R(this.#l),de(this.#l.ctx);try{return t()}catch(s){return Ct(s),null}finally{Y(n),R(r),de(i)}}#p(){const t=this.#s.pending;this.#i!==null&&(this.#f=document.createDocumentFragment(),this.#f.append(this.#a),cr(this.#i,this.#f)),this.#n===null&&(this.#n=le(()=>t(this.#e)))}#$(t){if(!this.has_pending_snippet()){this.parent&&this.parent.#$(t);return}this.#d+=t,this.#d===0&&(this.#t=!1,this.#n&&He(this.#n,()=>{this.#n=null}),this.#f&&(this.#e.before(this.#f),this.#f=null))}update_pending_count(t){this.#$(t),this.#c+=t,this.#h&&Ve(this.#h,this.#c)}get_effect_pending(){return this.#w(),m(this.#h)}error(t){var n=this.#s.onerror;let r=this.#s.failed;if(this.#v||!n&&!r)throw t;this.#i&&(q(this.#i),this.#i=null),this.#n&&(q(this.#n),this.#n=null),this.#r&&(q(this.#r),this.#r=null),T&&(z(this.#o),Ln(),z(jn()));var i=!1,s=!1;const l=()=>{if(i){Pn();return}i=!0,s&&Dn(),I.ensure(),this.#c=0,this.#r!==null&&He(this.#r,()=>{this.#r=null}),this.#t=this.has_pending_snippet(),this.#i=this.#_(()=>(this.#v=!1,le(()=>this.#u(this.#e)))),this.#d>0?this.#p():this.#t=!1};var f=v;try{R(null),s=!0,n?.(t,l),s=!1}catch(o){he(o,this.#l&&this.#l.parent)}finally{R(f)}r&&Fe(()=>{this.#r=this.#_(()=>{I.ensure(),this.#v=!0;try{return le(()=>{r(this.#e,()=>t,()=>l)})}catch(o){return he(o,this.#l.parent),null}finally{this.#v=!1}})})}}function Wn(e,t,n,r){const i=Lt;if(n.length===0&&e.length===0){r(t.map(i));return}var s=$,l=_,f=zn();function o(){Promise.all(n.map(u=>Gn(u))).then(u=>{f();try{r([...t.map(i),...u])}catch(c){(l.f&W)===0&&he(c,l)}s?.deactivate(),qe()}).catch(u=>{he(u,l)})}e.length>0?Promise.all(e).then(()=>{f();try{return o()}finally{s?.deactivate(),qe()}}):o()}function zn(){var e=_,t=v,n=N,r=$;return function(s=!0){Y(e),R(t),de(n),s&&r?.activate()}}function qe(){Y(null),R(null),de(null)}function Lt(e){var t=y|C,n=v!==null&&(v.f&y)!==0?v:null;return _!==null&&(_.f|=re),{ctx:N,deps:null,effects:null,equals:Tt,f:t,fn:e,reactions:null,rv:0,v:b,wv:0,parent:n??_,ac:null}}function Gn(e,t){let n=_;n===null&&Tn();var r=n.b,i=void 0,s=me(b),l=!v,f=new Map;return sr(()=>{var o=wt();i=o.promise;try{Promise.resolve(e()).then(o.resolve,o.reject).then(()=>{u===$&&u.committed&&u.deactivate(),qe()})}catch(a){o.reject(a),qe()}var u=$;if(l){var c=!r.is_pending();r.update_pending_count(1),u.increment(c),f.get(u)?.reject(ce),f.delete(u),f.set(u,o)}const h=(a,d=void 0)=>{if(u.activate(),d)d!==ce&&(s.f|=Q,Ve(s,d));else{(s.f&Q)!==0&&(s.f^=Q),Ve(s,a);for(const[p,j]of f){if(f.delete(p),p===u)break;j.reject(ce)}}l&&(r.update_pending_count(-1),u.decrement(c))};o.promise.then(h,a=>h(null,a||"unknown"))}),Ht(()=>{for(const o of f.values())o.reject(ce)}),new Promise(o=>{function u(c){function h(){c===i?o(s):u(i)}c.then(h,h)}u(i)})}function jt(e){var t=e.effects;if(t!==null){e.effects=null;for(var n=0;n<t.length;n+=1)q(t[n])}}function Jn(e){for(var t=e.parent;t!==null;){if((t.f&y)===0)return(t.f&W)===0?t:null;t=t.parent}return null}function st(e){var t,n=_;Y(Jn(e));try{e.f&=~ie,jt(e),t=nn(e)}finally{Y(n)}return t}function Ft(e){var t=st(e);if(e.equals(t)||($?.is_fork||(e.v=t),e.wv=en()),!fe)if(S!==null)Ye()&&S.set(e,t);else{var n=(e.f&M)===0?U:E;x(e,n)}}let lt=new Set;const ee=new Map;let Mt=!1;function me(e,t){var n={f:0,v:e,reactions:null,equals:Tt,rv:0,wv:0};return n}function P(e,t){const n=me(e);return dr(n),n}function Kn(e,t=!1,n=!0){const r=me(e);return t||(r.equals=Mn),r}function A(e,t,n=!1){v!==null&&(!B||(v.f&mt)!==0)&&At()&&(v.f&(y|H|tt|mt))!==0&&!J?.includes(e)&&Sn();let r=n?be(t):t;return Ve(e,r)}function Ve(e,t){if(!e.equals(t)){var n=e.v;fe?ee.set(e,t):ee.set(e,n),e.v=t;var r=I.ensure();r.capture(e,n),(e.f&y)!==0&&((e.f&C)!==0&&st(e),x(e,(e.f&M)!==0?E:U)),e.wv=en(),It(e,C),_!==null&&(_.f&E)!==0&&(_.f&(K|X))===0&&(L===null?hr([e]):L.push(e)),!r.is_fork&&lt.size>0&&!Mt&&Xn()}return t}function Xn(){Mt=!1;var e=ne;Ue(!0);const t=Array.from(lt);try{for(const n of t)(n.f&E)!==0&&x(n,U),Ae(n)&&Re(n)}finally{Ue(e)}lt.clear()}function ye(e){A(e,e.v+1)}function It(e,t){var n=e.reactions;if(n!==null)for(var r=n.length,i=0;i<r;i++){var s=n[i],l=s.f,f=(l&C)===0;if(f&&x(s,t),(l&y)!==0){var o=s;S?.delete(o),(l&ie)===0&&(l&M&&(s.f|=ie),It(o,U))}else f&&((l&H)!==0&&G!==null&&G.add(s),ve(s))}}function be(e){if(typeof e!="object"||e===null||nt in e)return e;const t=mn(e);if(t!==$n&&t!==wn)return e;var n=new Map,r=_n(e),i=P(0),s=oe,l=f=>{if(oe===s)return f();var o=v,u=oe;R(null),Qt(s);var c=f();return R(o),Qt(u),c};return r&&n.set("length",P(e.length)),new Proxy(e,{defineProperty(f,o,u){(!("value"in u)||u.configurable===!1||u.enumerable===!1||u.writable===!1)&&On();var c=n.get(o);return c===void 0?c=l(()=>{var h=P(u.value);return n.set(o,h),h}):A(c,u.value,!0),!0},deleteProperty(f,o){var u=n.get(o);if(u===void 0){if(o in f){const c=l(()=>P(b));n.set(o,c),ye(i)}}else A(u,b),ye(i);return!0},get(f,o,u){if(o===nt)return e;var c=n.get(o),h=o in f;if(c===void 0&&(!h||ae(f,o)?.writable)&&(c=l(()=>{var d=be(h?f[o]:b),p=P(d);return p}),n.set(o,c)),c!==void 0){var a=m(c);return a===b?void 0:a}return Reflect.get(f,o,u)},getOwnPropertyDescriptor(f,o){var u=Reflect.getOwnPropertyDescriptor(f,o);if(u&&"value"in u){var c=n.get(o);c&&(u.value=m(c))}else if(u===void 0){var h=n.get(o),a=h?.v;if(h!==void 0&&a!==b)return{enumerable:!0,configurable:!0,value:a,writable:!0}}return u},has(f,o){if(o===nt)return!0;var u=n.get(o),c=u!==void 0&&u.v!==b||Reflect.has(f,o);if(u!==void 0||_!==null&&(!c||ae(f,o)?.writable)){u===void 0&&(u=l(()=>{var a=c?be(f[o]):b,d=P(a);return d}),n.set(o,u));var h=m(u);if(h===b)return!1}return c},set(f,o,u,c){var h=n.get(o),a=o in f;if(r&&o==="length")for(var d=u;d<h.v;d+=1){var p=n.get(d+"");p!==void 0?A(p,b):d in f&&(p=l(()=>P(b)),n.set(d+"",p))}if(h===void 0)(!a||ae(f,o)?.writable)&&(h=l(()=>P(void 0)),A(h,be(u)),n.set(o,h));else{a=h.v!==b;var j=l(()=>be(u));A(h,j)}var F=Reflect.getOwnPropertyDescriptor(f,o);if(F?.set&&F.set.call(c,u),!a){if(r&&typeof o=="string"){var Je=n.get("length"),pe=Number(o);Number.isInteger(pe)&&pe>=Je.v&&A(Je,pe+1)}ye(i)}return!0},ownKeys(f){m(i);var o=Reflect.ownKeys(f).filter(h=>{var a=n.get(h);return a===void 0||a.v!==b});for(var[u,c]of n)c.v!==b&&!(u in f)&&o.push(u);return o},setPrototypeOf(){Nn()}})}var qt,Vt,Bt,Yt;function ft(){if(qt===void 0){qt=window,Vt=/Firefox/.test(navigator.userAgent);var e=Element.prototype,t=Node.prototype,n=Text.prototype;Bt=ae(t,"firstChild").get,Yt=ae(t,"nextSibling").get,$t(e)&&(e.__click=void 0,e.__className=void 0,e.__attributes=null,e.__style=void 0,e.__e=void 0),$t(n)&&(n.__t=void 0)}}function Ee(e=""){return document.createTextNode(e)}function Be(e){return Bt.call(e)}function te(e){return Yt.call(e)}function Te(e,t){if(!T)return Be(e);var n=Be(g);if(n===null)n=g.appendChild(Ee());else if(t&&n.nodeType!==bt){var r=Ee();return n?.before(r),z(r),r}return z(n),n}function ke(e,t=1,n=!1){let r=T?g:e;for(var i;t--;)i=r,r=te(r);if(!T)return r;if(n&&r?.nodeType!==bt){var s=Ee();return r===null?i?.after(s):r.before(s),z(s),s}return z(r),r}function Zn(e){e.textContent=""}function ot(e){var t=v,n=_;R(null),Y(null);try{return e()}finally{R(t),Y(n)}}function Qn(e){_===null&&(v===null&&An(),xn()),fe&&kn()}function er(e,t){var n=t.last;n===null?t.last=t.first=e:(n.next=e,e.prev=n,t.last=e)}function V(e,t,n){var r=_;r!==null&&(r.f&Z)!==0&&(e|=Z);var i={ctx:N,deps:null,nodes_start:null,nodes_end:null,f:e|C|M,first:null,fn:t,last:null,next:null,parent:r,b:r&&r.b,prev:null,teardown:null,transitions:null,wv:0,ac:null};if(n)try{Re(i),i.f|=De}catch(f){throw q(i),f}else t!==null&&ve(i);var s=i;if(n&&s.deps===null&&s.teardown===null&&s.nodes_start===null&&s.first===s.last&&(s.f&re)===0&&(s=s.first,(e&H)!==0&&(e&Pe)!==0&&s!==null&&(s.f|=Pe)),s!==null&&(s.parent=r,r!==null&&er(s,r),v!==null&&(v.f&y)!==0&&(e&X)===0)){var l=v;(l.effects??=[]).push(s)}return i}function Ye(){return v!==null&&!B}function Ht(e){const t=V(Qe,null,!1);return x(t,E),t.teardown=e,t}function tr(e){Qn();var t=_.f,n=!v&&(t&K)!==0&&(t&De)===0;if(n){var r=N;(r.e??=[]).push(e)}else return Ut(e)}function Ut(e){return V(Ze|bn,e,!1)}function nr(e){I.ensure();const t=V(X|re,e,!0);return()=>{q(t)}}function rr(e){I.ensure();const t=V(X|re,e,!0);return(n={})=>new Promise(r=>{n.outro?He(t,()=>{q(t),r(void 0)}):(q(t),r(void 0))})}function ir(e){return V(Ze,e,!1)}function sr(e){return V(tt|re,e,!0)}function Wt(e,t=0){return V(Qe|t,e,!0)}function lr(e,t=[],n=[],r=[]){Wn(r,t,n,i=>{V(Qe,()=>e(...i.map(m)),!0)})}function fr(e,t=0){var n=V(H|t,e,!0);return n}function le(e){return V(K|re,e,!0)}function zt(e){var t=e.teardown;if(t!==null){const n=fe,r=v;Xt(!0),R(null);try{t.call(null)}finally{Xt(n),R(r)}}}function Gt(e,t=!1){var n=e.first;for(e.first=e.last=null;n!==null;){const i=n.ac;i!==null&&ot(()=>{i.abort(ce)});var r=n.next;(n.f&X)!==0?n.parent=null:q(n,t),n=r}}function or(e){for(var t=e.first;t!==null;){var n=t.next;(t.f&K)===0&&q(t),t=n}}function q(e,t=!0){var n=!1;(t||(e.f&yt)!==0)&&e.nodes_start!==null&&e.nodes_end!==null&&(ur(e.nodes_start,e.nodes_end),n=!0),Gt(e,t&&!n),We(e,0),x(e,W);var r=e.transitions;if(r!==null)for(const s of r)s.stop();zt(e);var i=e.parent;i!==null&&i.first!==null&&Jt(e),e.next=e.prev=e.teardown=e.ctx=e.deps=e.fn=e.nodes_start=e.nodes_end=e.ac=null}function ur(e,t){for(;e!==null;){var n=e===t?null:te(e);e.remove(),e=n}}function Jt(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=[];Kt(e,r,!0),ar(r,()=>{n&&q(e),t&&t()})}function ar(e,t){var n=e.length;if(n>0){var r=()=>--n||t();for(var i of e)i.out(r)}else t()}function Kt(e,t,n){if((e.f&Z)===0){if(e.f^=Z,e.transitions!==null)for(const l of e.transitions)(l.is_global||n)&&t.push(l);for(var r=e.first;r!==null;){var i=r.next,s=(r.f&Pe)!==0||(r.f&K)!==0&&(e.f&H)!==0;Kt(r,t,s?n:!1),r=i}}}function cr(e,t){for(var n=e.nodes_start,r=e.nodes_end;n!==null;){var i=n===r?null:te(n);t.append(n),n=i}}let ne=!1;function Ue(e){ne=e}let fe=!1;function Xt(e){fe=e}let v=null,B=!1;function R(e){v=e}let _=null;function Y(e){_=e}let J=null;function dr(e){v!==null&&(J===null?J=[e]:J.push(e))}let k=null,O=0,L=null;function hr(e){L=e}let Zt=1,xe=0,oe=xe;function Qt(e){oe=e}function en(){return++Zt}function Ae(e){var t=e.f;if((t&C)!==0)return!0;if(t&y&&(e.f&=~ie),(t&U)!==0){var n=e.deps;if(n!==null)for(var r=n.length,i=0;i<r;i++){var s=n[i];if(Ae(s)&&Ft(s),s.wv>e.wv)return!0}(t&M)!==0&&S===null&&x(e,E)}return!1}function tn(e,t,n=!0){var r=e.reactions;if(r!==null&&!J?.includes(e))for(var i=0;i<r.length;i++){var s=r[i];(s.f&y)!==0?tn(s,t,!1):t===s&&(n?x(s,C):(s.f&E)!==0&&x(s,U),ve(s))}}function nn(e){var t=k,n=O,r=L,i=v,s=J,l=N,f=B,o=oe,u=e.f;k=null,O=0,L=null,v=(u&(K|X))===0?e:null,J=null,de(e.ctx),B=!1,oe=++xe,e.ac!==null&&(ot(()=>{e.ac.abort(ce)}),e.ac=null);try{e.f|=et;var c=e.fn,h=c(),a=e.deps;if(k!==null){var d;if(We(e,O),a!==null&&O>0)for(a.length=O+k.length,d=0;d<k.length;d++)a[O+d]=k[d];else e.deps=a=k;if(ne&&Ye()&&(e.f&M)!==0)for(d=O;d<a.length;d++)(a[d].reactions??=[]).push(e)}else a!==null&&O<a.length&&(We(e,O),a.length=O);if(At()&&L!==null&&!B&&a!==null&&(e.f&(y|U|C))===0)for(d=0;d<L.length;d++)tn(L[d],e);return i!==null&&i!==e&&(xe++,L!==null&&(r===null?r=L:r.push(...L))),(e.f&Q)!==0&&(e.f^=Q),h}catch(p){return Ct(p)}finally{e.f^=et,k=t,O=n,L=r,v=i,J=s,de(l),B=f,oe=o}}function vr(e,t){let n=t.reactions;if(n!==null){var r=pn.call(n,e);if(r!==-1){var i=n.length-1;i===0?n=t.reactions=null:(n[r]=n[i],n.pop())}}n===null&&(t.f&y)!==0&&(k===null||!k.includes(t))&&(x(t,U),(t.f&M)!==0&&(t.f^=M,t.f&=~ie),jt(t),We(t,0))}function We(e,t){var n=e.deps;if(n!==null)for(var r=t;r<n.length;r++)vr(e,n[r])}function Re(e){var t=e.f;if((t&W)===0){x(e,E);var n=_,r=ne;_=e,ne=!0;try{(t&H)!==0?or(e):Gt(e),zt(e);var i=nn(e);e.teardown=typeof i=="function"?i:null,e.wv=Zt;var s;Xe&&In&&(e.f&C)!==0&&e.deps}finally{ne=r,_=n}}}function m(e){var t=e.f,n=(t&y)!==0;if(v!==null&&!B){var r=_!==null&&(_.f&W)!==0;if(!r&&!J?.includes(e)){var i=v.deps;if((v.f&et)!==0)e.rv<xe&&(e.rv=xe,k===null&&i!==null&&i[O]===e?O++:k===null?k=[e]:k.includes(e)||k.push(e));else{(v.deps??=[]).push(e);var s=e.reactions;s===null?e.reactions=[v]:s.includes(v)||s.push(v)}}}if(fe){if(ee.has(e))return ee.get(e);if(n){var l=e,f=l.v;return((l.f&E)===0&&l.reactions!==null||sn(l))&&(f=st(l)),ee.set(l,f),f}}else n&&!S?.has(e)&&(l=e,Ae(l)&&Ft(l),ne&&Ye()&&(l.f&M)===0&&rn(l));if(S?.has(e))return S.get(e);if((e.f&Q)!==0)throw e.v;return e.v}function rn(e){if(e.deps!==null){e.f^=M;for(const t of e.deps)(t.reactions??=[]).push(e),(t.f&y)!==0&&(t.f&M)===0&&rn(t)}}function sn(e){if(e.v===b)return!0;if(e.deps===null)return!1;for(const t of e.deps)if(ee.has(t)||(t.f&y)!==0&&sn(t))return!0;return!1}function _r(e){var t=B;try{return B=!0,e()}finally{B=t}}const pr=-7169;function x(e,t){e.f=e.f&pr|t}const ln=new Set,ut=new Set;function gr(e,t,n,r={}){function i(s){if(r.capture||Ce.call(t,s),!s.cancelBubble)return ot(()=>n?.call(this,s))}return e.startsWith("pointer")||e.startsWith("touch")||e==="wheel"?Fe(()=>{t.addEventListener(e,i,r)}):t.addEventListener(e,i,r),i}function at(e,t,n,r,i){var s={capture:r,passive:i},l=gr(e,t,n,s);(t===document.body||t===window||t===document||t instanceof HTMLMediaElement)&&Ht(()=>{t.removeEventListener(e,l,s)})}function $r(e){for(var t=0;t<e.length;t++)ln.add(e[t]);for(var n of ut)n(e)}let fn=null;function Ce(e){var t=this,n=t.ownerDocument,r=e.type,i=e.composedPath?.()||[],s=i[0]||e.target;fn=e;var l=0,f=fn===e&&e.__root;if(f){var o=i.indexOf(f);if(o!==-1&&(t===document||t===window)){e.__root=t;return}var u=i.indexOf(t);if(u===-1)return;o<=u&&(l=o)}if(s=i[l]||e.target,s!==t){Ne(e,"currentTarget",{configurable:!0,get(){return s||n}});var c=v,h=_;R(null),Y(null);try{for(var a,d=[];s!==null;){var p=s.assignedSlot||s.parentNode||s.host||null;try{var j=s["__"+r];j!=null&&(!s.disabled||e.target===s)&&j.call(s,e)}catch(F){a?d.push(F):a=F}if(e.cancelBubble||p===t||p===null)break;s=p}if(a){for(let F of d)queueMicrotask(()=>{throw F});throw a}}finally{e.__root=t,delete e.currentTarget,R(c),Y(h)}}}function wr(e){var t=document.createElement("template");return t.innerHTML=e.replaceAll("<!>","<!---->"),t.content}function ct(e,t){var n=_;n.nodes_start===null&&(n.nodes_start=e,n.nodes_end=t)}function mr(e,t){var n=(t&vn)!==0,r,i=!e.startsWith("<!>");return()=>{if(T)return ct(g,null),g;r===void 0&&(r=wr(i?e:"<!>"+e),r=Be(r));var s=n||Vt?document.importNode(r,!0):r.cloneNode(!0);return ct(s,s),s}}function on(e,t){if(T){var n=_;((n.f&De)===0||n.nodes_end===null)&&(n.nodes_end=g),Et();return}e!==null&&e.before(t)}const yr=["touchstart","touchmove"];function br(e){return yr.includes(e)}function ze(e,t){var n=t==null?"":typeof t=="object"?t+"":t;n!==(e.__t??=e.nodeValue)&&(e.__t=n,e.nodeValue=n+"")}function un(e,t){return an(e,t)}function Er(e,t){ft(),t.intro=t.intro??!1;const n=t.target,r=T,i=g;try{for(var s=Be(n);s&&(s.nodeType!==Le||s.data!==_t);)s=te(s);if(!s)throw ge;je(!0),z(s);const l=an(e,{...t,anchor:s});return je(!1),l}catch(l){if(l instanceof Error&&l.message.split(`
2
+ `).some(f=>f.startsWith("https://svelte.dev/e/")))throw l;return l!==ge&&console.warn("Failed to hydrate: ",l),t.recover===!1&&Cn(),ft(),Zn(n),je(!1),un(e,t)}finally{je(r),z(i)}}const _e=new Map;function an(e,{target:t,anchor:n,props:r={},events:i,context:s,intro:l=!0}){ft();var f=new Set,o=h=>{for(var a=0;a<h.length;a++){var d=h[a];if(!f.has(d)){f.add(d);var p=br(d);t.addEventListener(d,Ce,{passive:p});var j=_e.get(d);j===void 0?(document.addEventListener(d,Ce,{passive:p}),_e.set(d,1)):_e.set(d,j+1)}}};o(gn(ln)),ut.add(o);var u=void 0,c=rr(()=>{var h=n??t.appendChild(Ee());return Hn(h,{pending:()=>{}},a=>{if(s){kt({});var d=N;d.c=s}if(i&&(r.$$events=i),T&&ct(a,null),u=e(a,r)||{},T&&(_.nodes_end=g,g===null||g.nodeType!==Le||g.data!==gt))throw rt(),ge;s&&xt()}),()=>{for(var a of f){t.removeEventListener(a,Ce);var d=_e.get(a);--d===0?(document.removeEventListener(a,Ce),_e.delete(a)):_e.set(a,d)}ut.delete(o),h!==n&&h.parentNode?.removeChild(h)}});return dt.set(u,c),u}let dt=new WeakMap;function Tr(e,t){const n=dt.get(e);return n?(dt.delete(e),n(t)):Promise.resolve()}function kr(e,t){ir(()=>{var n=e.getRootNode(),r=n.host?n:n.head??n.ownerDocument.head;if(!r.querySelector("#"+t.hash)){const i=document.createElement("style");i.id=t.hash,i.textContent=t.code,r.appendChild(i)}})}function xr(e,t,n,r){var i=r,s=!0,l=()=>(s&&(s=!1,i=r),i),f;f=e[t],f===void 0&&r!==void 0&&(f=l());var o;o=()=>{var a=e[t];return a===void 0?l():(s=!0,a)};var u=!1,c=Lt(()=>(u=!1,o())),h=_;return(function(a,d){if(arguments.length>0){const p=d?m(c):a;return A(c,p),u=!0,i!==void 0&&(i=p),a}return fe&&u||(h.f&W)!==0?c.v:m(c)})}function Ar(e){return new Rr(e)}class Rr{#t;#e;constructor(t){var n=new Map,r=(s,l)=>{var f=Kn(l,!1,!1);return n.set(s,f),f};const i=new Proxy({...t.props||{},$$events:{}},{get(s,l){return m(n.get(l)??r(l,Reflect.get(s,l)))},has(s,l){return l===En?!0:(m(n.get(l)??r(l,Reflect.get(s,l))),Reflect.has(s,l))},set(s,l,f){return A(n.get(l)??r(l,f),f),Reflect.set(s,l,f)}});this.#e=(t.hydrate?Er:un)(t.component,{target:t.target,anchor:t.anchor,props:i,context:t.context,intro:t.intro??!1,recover:t.recover}),(!t?.props?.$$host||t.sync===!1)&&Ot(),this.#t=i.$$events;for(const s of Object.keys(this.#e))s==="$set"||s==="$destroy"||s==="$on"||Ne(this,s,{get(){return this.#e[s]},set(l){this.#e[s]=l},enumerable:!0});this.#e.$set=s=>{Object.assign(i,s)},this.#e.$destroy=()=>{Tr(this.#e)}}$set(t){this.#e.$set(t)}$on(t,n){this.#t[t]=this.#t[t]||[];const r=(...i)=>n.call(this,...i);return this.#t[t].push(r),()=>{this.#t[t]=this.#t[t].filter(i=>i!==r)}}$destroy(){this.#e.$destroy()}}let cn;typeof HTMLElement=="function"&&(cn=class extends HTMLElement{$$ctor;$$s;$$c;$$cn=!1;$$d={};$$r=!1;$$p_d={};$$l={};$$l_u=new Map;$$me;constructor(e,t,n){super(),this.$$ctor=e,this.$$s=t,n&&this.attachShadow({mode:"open"})}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=document.createElement("slot");r!=="default"&&(s.name=r),on(i,s)}};if(await Promise.resolve(),!this.$$cn||this.$$c)return;const t={},n=Cr(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]=Ge(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=Ar({component:this.$$ctor,target:this.shadowRoot||this,props:{...this.$$d,$$slots:t,$$host:this}}),this.$$me=nr(()=>{Wt(()=>{this.$$r=!0;for(const r of Oe(this.$$c)){if(!this.$$p_d[r]?.reflect)continue;this.$$d[r]=this.$$c[r];const i=Ge(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]=Ge(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 Oe(this.$$p_d).find(t=>this.$$p_d[t].attribute===e||!this.$$p_d[t].attribute&&t.toLowerCase()===e)||e}});function Ge(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 Cr(e){const t={};return e.childNodes.forEach(n=>{t[n.slot||"default"]=!0}),t}function Or(e,t,n,r,i,s){let l=class extends cn{constructor(){super(e,n,i),this.$$p_d=t}static get observedAttributes(){return Oe(t).map(f=>(t[f].attribute||f).toLowerCase())}};return Oe(t).forEach(f=>{Ne(l.prototype,f,{get(){return this.$$c&&f in this.$$c?this.$$c[f]:this.$$d[f]},set(o){o=Ge(f,o,t),this.$$d[f]=o;var u=this.$$c;if(u){var c=ae(u,f)?.get;c?u[f]=o:u.$set({[f]:o})}}})}),r.forEach(f=>{Ne(l.prototype,f,{get(){return this.$$c?.[f]}})}),e.element=l,l}var ue={},dn;function Nr(){if(dn)return ue;dn=1,Object.defineProperty(ue,"__esModule",{value:!0}),ue.LanguageTranslator=void 0,ue.getChildStyleToPass=e,ue.addComponent=t;function e(r,i){var s,l,f="";try{if(r&&i?.length&&(!((s=Object.keys(r))===null||s===void 0)&&s.length)&&(!((l=i?.filter(function(a){return Object.keys(r).includes(a.name)}))===null||l===void 0)&&l.length))for(var o=function(a){var d=i?.filter(function(p){return p.name===a&&p.defaultValue!==r[a]});d&&(f+="".concat(a,":").concat(r[a],";"))},u=0,c=Object.keys(r);u<c.length;u++){var h=c[u];o(h)}}catch(a){console.error("error getting child style to pass",a)}finally{return f}}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 l=r?.iifePath||"main.iife.js";if(!document.getElementById(s+"-script"))try{var f=document.createElement("script");if(f.id=s+"-script",f.src="https://cdn.jsdelivr.net/npm/".concat(r.repoName,"@").concat(r.version,"/").concat(l),r?.local)f.src="".concat(r.local);else if(location.href.includes("localhost:6006")){var o=s.split("-")[0];f.src="http://localhost:6006/webcomponents/".concat(s.replace(o+"-",""),"/").concat(l)}document.head.appendChild(f)}catch(u){console.warn(u)}}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,l){return r.formatDate(i,s,l||this.lang)},r.getDefaultLang=function(){var i,s,l,f="en";return navigator?.languages&&(!((l=(s=(i=navigator.languages[0])===null||i===void 0?void 0:i.split("-")[0])===null||s===void 0?void 0:s.toLowerCase())===null||l===void 0)&&l.length)&&(f=navigator.languages[0].split("-")[0].toLowerCase()),f},r.getDictionaryWord=function(i,s,l){var f;if(!i)throw new Error("no wordKey provided");if(!s)throw new Error("no dictionary provided");if(l&&(!((f=s[l])===null||f===void 0)&&f[i]))return s[l][i];var o="",u=r.getDefaultLang();if(!l||u!==l){var c=s?.[u];c?.[i]&&(o=c[i])}return o},r.formatDate=function(i,s,l){if(!i)throw new Error("no date provided");if(typeof i.getMonth!="function")throw new Error("wrong date format");var f=new Intl.DateTimeFormat(l||r.getDefaultLang(),s);return f.format(i)},r})();return ue.LanguageTranslator=n,ue}Nr();var Sr=mr('<div class="container svelte-110s2rp"><video id="video"><track kind="captions"/></video> <div> <button> </button> <button>FH</button> <button> </button> <button> </button></div></div>',2);const Dr={hash:"svelte-110s2rp",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");:host {font-family:"Roboto", sans-serif;}.container.svelte-110s2rp {position:relative;}'};function hn(e,t){kt(t,!0),kr(e,Dr);function n(w,jr){t.$$host.dispatchEvent(new CustomEvent(w,{detail:jr}))}let r=xr(t,"id",7,""),i,s=P(!1),l=P(!0),f=P(!0),o=P(0);const u=t.$$host;tr(()=>{});async function c(){try{const w=await navigator.mediaDevices.getUserMedia({video:!0,audio:!0});console.info("access to camera granted"),n("AudioVideoAccess",{granted:!0,id:r()}),i=u.shadowRoot?.querySelector("video"),i.srcObject=w,i.play(),n("VideoInitialized",{videoElement:i,id:r()})}catch(w){throw console.error("error on garantAccessToCamera",w),n("AudioVideoAccess",{granted:!1,id:r()}),new Error("camera access denied")}}c().then(()=>{console.log("camera initialized")}).catch(w=>{console.log("camera access denied",w)});var h={get id(){return r()},set id(w=""){r(w),Ot()}},a=Sr(),d=Te(a),p=ke(d,2),j=Te(p,!0),F=ke(j);F.__click=()=>{m(s)?i.pause():i.play()};var Je=Te(F,!0);$e(F);var pe=ke(F,2);pe.__click=()=>{i.requestFullscreen()};var Ke=ke(pe,2);Ke.__click=()=>{i.srcObject.getTracks().filter(w=>w.kind==="video").forEach(w=>{A(l,!w.enabled),w.enabled=m(l)})};var Pr=Te(Ke);$e(Ke);var ht=ke(Ke,2);ht.__click=()=>{i.srcObject.getTracks().filter(w=>w.kind==="audio").forEach(w=>{A(f,!w.enabled),w.enabled=m(f)})};var Lr=Te(ht);return $e(ht),$e(p),$e(a),lr(()=>{ze(j,m(o)),ze(Je,m(s)?"pause":"play"),ze(Pr,`${m(l)?"remove":"add"} video`),ze(Lr,`${m(f)?"remove":"add"} audio`)}),at("play",d,()=>{A(s,!0)}),at("pause",d,()=>{A(s,!1)}),at("timeupdate",d,()=>{A(o,i.currentTime,!0)}),on(e,a),xt(h)}$r(["click"]),customElements.define("hb-player-input-streaming",Or(hn,{id:{}},[],[],!0)),vt.Component=hn,Object.defineProperty(vt,Symbol.toStringTag,{value:"Module"})})(this["player-input-streaming"]=this["player-input-streaming"]||{});
3
3
  //# sourceMappingURL=main.iife.js.map