@htmlbricks/hb-input-array-tags 0.65.11 → 0.65.16

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
- (function(nr){"use strict";typeof window<"u"&&((window.__svelte??={}).v??=new Set).add("5");const _n=1,bn=2,pn=16,gn=1,mn=2,ir="[",ot="[!",St="]",Re={},S=Symbol(),yn="http://www.w3.org/1999/xhtml",jt=!1;var At=Array.isArray,wn=Array.prototype.indexOf,Nt=Array.from,ft=Object.keys,ut=Object.defineProperty,Le=Object.getOwnPropertyDescriptor,$n=Object.prototype,En=Array.prototype,xn=Object.getPrototypeOf,sr=Object.isExtensible;function kn(e){for(var t=0;t<e.length;t++)e[t]()}function ar(){var e,t,r=new Promise((n,i)=>{e=n,t=i});return{promise:r,resolve:e,reject:t}}const T=2,Ct=4,Rt=8,ie=16,se=32,de=64,ct=128,z=512,j=1024,L=2048,ae=4096,I=8192,le=16384,dt=32768,Me=65536,lr=1<<17,or=1<<18,we=1<<19,Tn=1<<20,$e=32768,Lt=1<<21,Mt=1<<22,ve=1<<23,Ue=Symbol("$state"),Sn=Symbol("legacy props"),jn=Symbol(""),Oe=new class extends Error{name="StaleReactionError";message="The reaction that called `getAbortSignal()` was re-run or destroyed"},vt=3,De=8;function An(e){throw new Error("https://svelte.dev/e/lifecycle_outside_component")}function Nn(){throw new Error("https://svelte.dev/e/async_derived_orphan")}function Cn(e){throw new Error("https://svelte.dev/e/effect_in_teardown")}function Rn(){throw new Error("https://svelte.dev/e/effect_in_unowned_derived")}function Ln(e){throw new Error("https://svelte.dev/e/effect_orphan")}function Mn(){throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}function On(){throw new Error("https://svelte.dev/e/hydration_failed")}function Dn(){throw new Error("https://svelte.dev/e/state_descriptors_fixed")}function In(){throw new Error("https://svelte.dev/e/state_prototype_fixed")}function Pn(){throw new Error("https://svelte.dev/e/state_unsafe_mutation")}function Fn(){throw new Error("https://svelte.dev/e/svelte_boundary_reset_onerror")}function ht(e){console.warn("https://svelte.dev/e/hydration_mismatch")}function Vn(){console.warn("https://svelte.dev/e/select_multiple_invalid_value")}function qn(){console.warn("https://svelte.dev/e/svelte_boundary_reset_noop")}let p=!1;function oe(e){p=e}let m;function M(e){if(e===null)throw ht(),Re;return m=e}function Ye(){return M(Z(m))}function Ie(e){if(p){if(Z(m)!==null)throw ht(),Re;m=e}}function Bn(e=1){if(p){for(var t=e,r=m;t--;)r=Z(r);m=r}}function _t(e=!0){for(var t=0,r=m;;){if(r.nodeType===De){var n=r.data;if(n===St){if(t===0)return r;t-=1}else(n===ir||n===ot)&&(t+=1)}var i=Z(r);e&&r.remove(),r=i}}function fr(e){if(!e||e.nodeType!==De)throw ht(),Re;return e.data}function ur(e){return e===this.v}function Hn(e,t){return e!=e?t==t:e!==t||e!==null&&typeof e=="object"||typeof e=="function"}function cr(e){return!Hn(e,this.v)}let Un=!1,P=null;function Pe(e){P=e}function dr(e,t=!1,r){P={p:P,i:!1,c:null,e:null,s:e,x:null,l:null}}function vr(e){var t=P,r=t.e;if(r!==null){t.e=null;for(var n of r)Fr(n)}return e!==void 0&&(t.x=e),t.i=!0,P=t.p,e??{}}function hr(){return!0}let Ee=[];function _r(){var e=Ee;Ee=[],kn(e)}function We(e){if(Ee.length===0&&!Ge){var t=Ee;queueMicrotask(()=>{t===Ee&&_r()})}Ee.push(e)}function Yn(){for(;Ee.length>0;)_r()}function br(e){var t=y;if(t===null)return g.f|=ve,e;if((t.f&dt)===0){if((t.f&ct)===0)throw e;t.b.error(e)}else Fe(e,t)}function Fe(e,t){for(;t!==null;){if((t.f&ct)!==0)try{t.b.error(e);return}catch(r){e=r}t=t.parent}throw e}const bt=new Set;let w=null,ze=null,H=null,U=[],pt=null,Ot=!1,Ge=!1;class G{committed=!1;current=new Map;previous=new Map;#t=new Set;#e=new Set;#r=0;#n=0;#o=null;#s=[];#i=[];skipped_effects=new Set;is_fork=!1;is_deferred(){return this.is_fork||this.#n>0}process(t){U=[],ze=null,this.apply();var r={parent:null,effect:null,effects:[],render_effects:[],block_effects:[]};for(const n of t)this.#a(n,r);this.is_fork||this.#u(),this.is_deferred()?(this.#l(r.effects),this.#l(r.render_effects),this.#l(r.block_effects)):(ze=this,w=null,gr(r.render_effects),gr(r.effects),ze=null,this.#o?.resolve()),H=null}#a(t,r){t.f^=j;for(var n=t.first;n!==null;){var i=n.f,s=(i&(se|de))!==0,l=s&&(i&j)!==0,a=l||(i&I)!==0||this.skipped_effects.has(n);if((n.f&ct)!==0&&n.b?.is_pending()&&(r={parent:r,effect:n,effects:[],render_effects:[],block_effects:[]}),!a&&n.fn!==null){s?n.f^=j:(i&Ct)!==0?r.effects.push(n):et(n)&&((n.f&ie)!==0&&r.block_effects.push(n),tt(n));var o=n.first;if(o!==null){n=o;continue}}var f=n.parent;for(n=n.next;n===null&&f!==null;)f===r.effect&&(this.#l(r.effects),this.#l(r.render_effects),this.#l(r.block_effects),r=r.parent),n=f.next,f=f.parent}}#l(t){for(const r of t)((r.f&L)!==0?this.#s:this.#i).push(r),this.#f(r.deps),A(r,j)}#f(t){if(t!==null)for(const r of t)(r.f&T)===0||(r.f&$e)===0||(r.f^=$e,this.#f(r.deps))}capture(t,r){this.previous.has(t)||this.previous.set(t,r),(t.f&ve)===0&&(this.current.set(t,t.v),H?.set(t,t.v))}activate(){w=this,this.apply()}deactivate(){w===this&&(w=null,H=null)}flush(){if(this.activate(),U.length>0){if(pr(),w!==null&&w!==this)return}else this.#r===0&&this.process([]);this.deactivate()}discard(){for(const t of this.#e)t(this);this.#e.clear()}#u(){if(this.#n===0){for(const t of this.#t)t();this.#t.clear()}this.#r===0&&this.#c()}#c(){if(bt.size>1){this.previous.clear();var t=H,r=!0,n={parent:null,effect:null,effects:[],render_effects:[],block_effects:[]};for(const s of bt){if(s===this){r=!1;continue}const l=[];for(const[o,f]of this.current){if(s.current.has(o))if(r&&f!==s.current.get(o))s.current.set(o,f);else continue;l.push(o)}if(l.length===0)continue;const a=[...s.current.keys()].filter(o=>!this.current.has(o));if(a.length>0){var i=U;U=[];const o=new Set,f=new Map;for(const u of l)mr(u,a,o,f);if(U.length>0){w=s,s.apply();for(const u of U)s.#a(u,n);s.deactivate()}U=i}}w=null,H=t}this.committed=!0,bt.delete(this)}increment(t){this.#r+=1,t&&(this.#n+=1)}decrement(t){this.#r-=1,t&&(this.#n-=1),this.revive()}revive(){for(const t of this.#s)A(t,L),xe(t);for(const t of this.#i)A(t,ae),xe(t);this.#s=[],this.#i=[],this.flush()}oncommit(t){this.#t.add(t)}ondiscard(t){this.#e.add(t)}settled(){return(this.#o??=ar()).promise}static ensure(){if(w===null){const t=w=new G;bt.add(w),Ge||G.enqueue(()=>{w===t&&t.flush()})}return w}static enqueue(t){We(t)}apply(){}}function Je(e){var t=Ge;Ge=!0;try{for(var r;;){if(Yn(),U.length===0&&(w?.flush(),U.length===0))return pt=null,r;pr()}}finally{Ge=t}}function pr(){var e=_e;Ot=!0;var t=null;try{var r=0;for(Et(!0);U.length>0;){var n=G.ensure();if(r++>1e3){var i,s;Wn()}n.process(U),he.clear()}}finally{Ot=!1,Et(e),pt=null}}function Wn(){try{Mn()}catch(e){Fe(e,pt)}}let fe=null;function gr(e){var t=e.length;if(t!==0){for(var r=0;r<t;){var n=e[r++];if((n.f&(le|I))===0&&et(n)&&(fe=new Set,tt(n),n.deps===null&&n.first===null&&n.nodes_start===null&&(n.teardown===null&&n.ac===null?Hr(n):n.fn=null),fe?.size>0)){he.clear();for(const i of fe){if((i.f&(le|I))!==0)continue;const s=[i];let l=i.parent;for(;l!==null;)fe.has(l)&&(fe.delete(l),s.push(l)),l=l.parent;for(let a=s.length-1;a>=0;a--){const o=s[a];(o.f&(le|I))===0&&tt(o)}}fe.clear()}}fe=null}}function mr(e,t,r,n){if(!r.has(e)&&(r.add(e),e.reactions!==null))for(const i of e.reactions){const s=i.f;(s&T)!==0?mr(i,t,r,n):(s&(Mt|ie))!==0&&(s&L)===0&&yr(i,t,n)&&(A(i,L),xe(i))}}function yr(e,t,r){const n=r.get(e);if(n!==void 0)return n;if(e.deps!==null)for(const i of e.deps){if(t.includes(i))return!0;if((i.f&T)!==0&&yr(i,t,r))return r.set(i,!0),!0}return r.set(e,!1),!1}function xe(e){for(var t=pt=e;t.parent!==null;){t=t.parent;var r=t.f;if(Ot&&t===y&&(r&ie)!==0&&(r&or)===0)return;if((r&(de|se))!==0){if((r&j)===0)return;t.f^=j}}U.push(t)}function zn(e){let t=0,r=ke(0),n;return()=>{wt()&&(v(r),Bt(()=>(t===0&&(n=Wt(()=>e(()=>Xe(r)))),t+=1,()=>{We(()=>{t-=1,t===0&&(n?.(),n=void 0,Xe(r))})})))}}var Gn=Me|we|ct;function Jn(e,t,r){new Kn(e,t,r)}class Kn{parent;#t=!1;#e;#r=p?m:null;#n;#o;#s;#i=null;#a=null;#l=null;#f=null;#u=null;#c=0;#d=0;#h=!1;#v=null;#m=zn(()=>(this.#v=ke(this.#c),()=>{this.#v=null}));constructor(t,r,n){this.#e=t,this.#n=r,this.#o=n,this.parent=y.b,this.#t=!!this.#n.pending,this.#s=Ht(()=>{if(y.b=this,p){const s=this.#r;Ye(),s.nodeType===De&&s.data===ot?this.#w():this.#y()}else{var i=this.#p();try{this.#i=Y(()=>n(i))}catch(s){this.error(s)}this.#d>0?this.#b():this.#t=!1}return()=>{this.#u?.remove()}},Gn),p&&(this.#e=m)}#y(){try{this.#i=Y(()=>this.#o(this.#e))}catch(t){this.error(t)}this.#t=!1}#w(){const t=this.#n.pending;t&&(this.#a=Y(()=>t(this.#e)),G.enqueue(()=>{var r=this.#p();this.#i=this.#_(()=>(G.ensure(),Y(()=>this.#o(r)))),this.#d>0?this.#b():(Be(this.#a,()=>{this.#a=null}),this.#t=!1)}))}#p(){var t=this.#e;return this.#t&&(this.#u=V(),this.#e.before(this.#u),t=this.#u),t}is_pending(){return this.#t||!!this.parent&&this.parent.is_pending()}has_pending_snippet(){return!!this.#n.pending}#_(t){var r=y,n=g,i=P;te(this.#s),O(this.#s),Pe(this.#s.ctx);try{return t()}catch(s){return br(s),null}finally{te(r),O(n),Pe(i)}}#b(){const t=this.#n.pending;this.#i!==null&&(this.#f=document.createDocumentFragment(),this.#f.append(this.#u),Wr(this.#i,this.#f)),this.#a===null&&(this.#a=Y(()=>t(this.#e)))}#g(t){if(!this.has_pending_snippet()){this.parent&&this.parent.#g(t);return}this.#d+=t,this.#d===0&&(this.#t=!1,this.#a&&Be(this.#a,()=>{this.#a=null}),this.#f&&(this.#e.before(this.#f),this.#f=null))}update_pending_count(t){this.#g(t),this.#c+=t,this.#v&&Ke(this.#v,this.#c)}get_effect_pending(){return this.#m(),v(this.#v)}error(t){var r=this.#n.onerror;let n=this.#n.failed;if(this.#h||!r&&!n)throw t;this.#i&&(C(this.#i),this.#i=null),this.#a&&(C(this.#a),this.#a=null),this.#l&&(C(this.#l),this.#l=null),p&&(M(this.#r),Bn(),M(_t()));var i=!1,s=!1;const l=()=>{if(i){qn();return}i=!0,s&&Fn(),G.ensure(),this.#c=0,this.#l!==null&&Be(this.#l,()=>{this.#l=null}),this.#t=this.has_pending_snippet(),this.#i=this.#_(()=>(this.#h=!1,Y(()=>this.#o(this.#e)))),this.#d>0?this.#b():this.#t=!1};var a=g;try{O(null),s=!0,r?.(t,l),s=!1}catch(o){Fe(o,this.#s&&this.#s.parent)}finally{O(a)}n&&We(()=>{this.#l=this.#_(()=>{G.ensure(),this.#h=!0;try{return Y(()=>{n(this.#e,()=>t,()=>l)})}catch(o){return Fe(o,this.#s.parent),null}finally{this.#h=!1}})})}}function Xn(e,t,r){for(var n=[],i=t.length,s=0;s<i;s++)Ut(t[s].e,n,!0);Ur(n,()=>{var l=n.length===0&&r!==null;if(l){var a=r,o=a.parentNode;Mr(o),o.append(a),e.items.clear(),X(e,t[0].prev,t[i-1].next)}for(var f=0;f<i;f++){var u=t[f];l||(e.items.delete(u.k),X(e,u.prev,u.next)),C(u.e,!l)}e.first===t[0]&&(e.first=t[0].prev)})}function wr(e,t,r,n,i,s=null){var l=e,a=new Map,o=null;p&&Ye();var f=null,u=ni(()=>{var x=r();return At(x)?x:x==null?[]:Nt(x)}),d,c=!0;function h(){Zn(k,d,l,t,n),f!==null&&(d.length===0?(f.fragment?(l.before(f.fragment),f.fragment=null):Yt(f.effect),_.first=f.effect):Be(f.effect,()=>{f=null}))}var _=Ht(()=>{d=v(u);var x=d.length;let B=!1;if(p){var N=fr(l)===ot;N!==(x===0)&&(l=_t(),M(l),oe(!1),B=!0)}for(var ge=new Set,J=w,re=null,K=Or(),ne=0;ne<x;ne+=1){p&&m.nodeType===De&&m.data===St&&(l=m,B=!0,oe(!1));var me=d[ne],ce=n(me,ne),D=c?null:a.get(ce);D?(Ke(D.v,me),D.i=ne,K&&J.skipped_effects.delete(D.e)):(D=Qn(c?l:null,re,me,ce,ne,i,t,r),c&&(D.o=!0,re===null?o=D:re.next=D,re=D),a.set(ce,D)),ge.add(ce)}if(x===0&&s&&!f)if(c)f={fragment:null,effect:Y(()=>s(l))};else{var Ne=document.createDocumentFragment(),st=V();Ne.append(st),f={fragment:Ne,effect:Y(()=>s(st))}}if(p&&x>0&&M(_t()),!c)if(K){for(const[er,tr]of a)ge.has(er)||J.skipped_effects.add(tr.e);J.oncommit(h),J.ondiscard(()=>{})}else h();B&&oe(!0),v(u)}),k={effect:_,items:a,first:o};c=!1,p&&(l=m)}function Zn(e,t,r,n,i){var s=t.length,l=e.items,a=e.first,o,f=null,u=[],d=[],c,h,_,k;for(k=0;k<s;k+=1){if(c=t[k],h=i(c,k),_=l.get(h),e.first??=_,!_.o){_.o=!0;var x=f?f.next:a;X(e,f,_),X(e,_,x),Dt(_,x,r),f=_,u=[],d=[],a=f.next;continue}if((_.e.f&I)!==0&&Yt(_.e),_!==a){if(o!==void 0&&o.has(_)){if(u.length<d.length){var B=d[0],N;f=B.prev;var ge=u[0],J=u[u.length-1];for(N=0;N<u.length;N+=1)Dt(u[N],B,r);for(N=0;N<d.length;N+=1)o.delete(d[N]);X(e,ge.prev,J.next),X(e,f,ge),X(e,J,B),a=B,f=J,k-=1,u=[],d=[]}else o.delete(_),Dt(_,a,r),X(e,_.prev,_.next),X(e,_,f===null?e.first:f.next),X(e,f,_),f=_;continue}for(u=[],d=[];a!==null&&a.k!==h;)(a.e.f&I)===0&&(o??=new Set).add(a),d.push(a),a=a.next;if(a===null)continue;_=a}u.push(_),f=_,a=_.next}if(a!==null||o!==void 0){for(var re=o===void 0?[]:Nt(o);a!==null;)(a.e.f&I)===0&&re.push(a),a=a.next;var K=re.length;if(K>0){var ne=null;Xn(e,re,ne)}}}function Qn(e,t,r,n,i,s,l,a){var o=(l&_n)!==0,f=(l&pn)===0,u=o?f?Tr(r,!1,!1):ke(r):r,d=(l&bn)===0?i:ke(i),c={i:d,v:u,k:n,a:null,e:null,o:!1,prev:t,next:null};try{if(e===null){var h=document.createDocumentFragment();h.append(e=V())}return c.e=Y(()=>s(e,u,d,a)),t!==null&&(t.next=c),c}finally{}}function Dt(e,t,r){for(var n=e.next?e.next.e.nodes_start:r,i=t?t.e.nodes_start:r,s=e.e.nodes_start;s!==null&&s!==n;){var l=Z(s);i.before(s),s=l}}function X(e,t,r){t===null?(e.first=r,e.effect.first=r&&r.e):(t.e.next&&(t.e.next.prev=null),t.next=r,t.e.next=r&&r.e),r===null?e.effect.last=t&&t.e:(r.e.prev&&(r.e.prev.next=null),r.prev=t,r.e.prev=t&&t.e)}function ei(e,t,r,n){const i=mt;if(r.length===0&&e.length===0){n(t.map(i));return}var s=w,l=y,a=ti();function o(){Promise.all(r.map(f=>ri(f))).then(f=>{a();try{n([...t.map(i),...f])}catch(u){(l.f&le)===0&&Fe(u,l)}s?.deactivate(),gt()}).catch(f=>{Fe(f,l)})}e.length>0?Promise.all(e).then(()=>{a();try{return o()}finally{s?.deactivate(),gt()}}):o()}function ti(){var e=y,t=g,r=P,n=w;return function(s=!0){te(e),O(t),Pe(r),s&&n?.activate()}}function gt(){te(null),O(null),Pe(null)}function mt(e){var t=T|L,r=g!==null&&(g.f&T)!==0?g:null;return y!==null&&(y.f|=we),{ctx:P,deps:null,effects:null,equals:ur,f:t,fn:e,reactions:null,rv:0,v:S,wv:0,parent:r??y,ac:null}}function ri(e,t){let r=y;r===null&&Nn();var n=r.b,i=void 0,s=ke(S),l=!g,a=new Map;return ci(()=>{var o=ar();i=o.promise;try{Promise.resolve(e()).then(o.resolve,o.reject).then(()=>{f===w&&f.committed&&f.deactivate(),gt()})}catch(c){o.reject(c),gt()}var f=w;if(l){var u=!n.is_pending();n.update_pending_count(1),f.increment(u),a.get(f)?.reject(Oe),a.delete(f),a.set(f,o)}const d=(c,h=void 0)=>{if(f.activate(),h)h!==Oe&&(s.f|=ve,Ke(s,h));else{(s.f&ve)!==0&&(s.f^=ve),Ke(s,c);for(const[_,k]of a){if(a.delete(_),_===f)break;k.reject(Oe)}}l&&(n.update_pending_count(-1),f.decrement(u))};o.promise.then(d,c=>d(null,c||"unknown"))}),Vt(()=>{for(const o of a.values())o.reject(Oe)}),new Promise(o=>{function f(u){function d(){u===i?o(s):f(i)}u.then(d,d)}f(i)})}function $r(e){const t=mt(e);return Gr(t),t}function ni(e){const t=mt(e);return t.equals=cr,t}function Er(e){var t=e.effects;if(t!==null){e.effects=null;for(var r=0;r<t.length;r+=1)C(t[r])}}function ii(e){for(var t=e.parent;t!==null;){if((t.f&T)===0)return(t.f&le)===0?t:null;t=t.parent}return null}function It(e){var t,r=y;te(ii(e));try{e.f&=~$e,Er(e),t=Qr(e)}finally{te(r)}return t}function xr(e){var t=It(e);if(e.equals(t)||(w?.is_fork||(e.v=t),e.wv=Xr()),!Se)if(H!==null)wt()&&H.set(e,t);else{var r=(e.f&z)===0?ae:j;A(e,r)}}let Pt=new Set;const he=new Map;let kr=!1;function ke(e,t){var r={f:0,v:e,reactions:null,equals:ur,rv:0,wv:0};return r}function F(e,t){const r=ke(e);return Gr(r),r}function Tr(e,t=!1,r=!0){const n=ke(e);return t||(n.equals=cr),n}function E(e,t,r=!1){g!==null&&(!ee||(g.f&lr)!==0)&&hr()&&(g.f&(T|ie|Mt|lr))!==0&&!ue?.includes(e)&&Pn();let n=r?Te(t):t;return Ke(e,n)}function Ke(e,t){if(!e.equals(t)){var r=e.v;Se?he.set(e,t):he.set(e,r),e.v=t;var n=G.ensure();n.capture(e,r),(e.f&T)!==0&&((e.f&L)!==0&&It(e),A(e,(e.f&z)!==0?j:ae)),e.wv=Xr(),Sr(e,L),y!==null&&(y.f&j)!==0&&(y.f&(se|de))===0&&(W===null?hi([e]):W.push(e)),!n.is_fork&&Pt.size>0&&!kr&&si()}return t}function si(){kr=!1;var e=_e;Et(!0);const t=Array.from(Pt);try{for(const r of t)(r.f&j)!==0&&A(r,ae),et(r)&&tt(r)}finally{Et(e)}Pt.clear()}function Xe(e){E(e,e.v+1)}function Sr(e,t){var r=e.reactions;if(r!==null)for(var n=r.length,i=0;i<n;i++){var s=r[i],l=s.f,a=(l&L)===0;if(a&&A(s,t),(l&T)!==0){var o=s;H?.delete(o),(l&$e)===0&&(l&z&&(s.f|=$e),Sr(o,ae))}else a&&((l&ie)!==0&&fe!==null&&fe.add(s),xe(s))}}function Te(e){if(typeof e!="object"||e===null||Ue in e)return e;const t=xn(e);if(t!==$n&&t!==En)return e;var r=new Map,n=At(e),i=F(0),s=je,l=a=>{if(je===s)return a();var o=g,f=je;O(null),Kr(s);var u=a();return O(o),Kr(f),u};return n&&r.set("length",F(e.length)),new Proxy(e,{defineProperty(a,o,f){(!("value"in f)||f.configurable===!1||f.enumerable===!1||f.writable===!1)&&Dn();var u=r.get(o);return u===void 0?u=l(()=>{var d=F(f.value);return r.set(o,d),d}):E(u,f.value,!0),!0},deleteProperty(a,o){var f=r.get(o);if(f===void 0){if(o in a){const u=l(()=>F(S));r.set(o,u),Xe(i)}}else E(f,S),Xe(i);return!0},get(a,o,f){if(o===Ue)return e;var u=r.get(o),d=o in a;if(u===void 0&&(!d||Le(a,o)?.writable)&&(u=l(()=>{var h=Te(d?a[o]:S),_=F(h);return _}),r.set(o,u)),u!==void 0){var c=v(u);return c===S?void 0:c}return Reflect.get(a,o,f)},getOwnPropertyDescriptor(a,o){var f=Reflect.getOwnPropertyDescriptor(a,o);if(f&&"value"in f){var u=r.get(o);u&&(f.value=v(u))}else if(f===void 0){var d=r.get(o),c=d?.v;if(d!==void 0&&c!==S)return{enumerable:!0,configurable:!0,value:c,writable:!0}}return f},has(a,o){if(o===Ue)return!0;var f=r.get(o),u=f!==void 0&&f.v!==S||Reflect.has(a,o);if(f!==void 0||y!==null&&(!u||Le(a,o)?.writable)){f===void 0&&(f=l(()=>{var c=u?Te(a[o]):S,h=F(c);return h}),r.set(o,f));var d=v(f);if(d===S)return!1}return u},set(a,o,f,u){var d=r.get(o),c=o in a;if(n&&o==="length")for(var h=f;h<d.v;h+=1){var _=r.get(h+"");_!==void 0?E(_,S):h in a&&(_=l(()=>F(S)),r.set(h+"",_))}if(d===void 0)(!c||Le(a,o)?.writable)&&(d=l(()=>F(void 0)),E(d,Te(f)),r.set(o,d));else{c=d.v!==S;var k=l(()=>Te(f));E(d,k)}var x=Reflect.getOwnPropertyDescriptor(a,o);if(x?.set&&x.set.call(u,f),!c){if(n&&typeof o=="string"){var B=r.get("length"),N=Number(o);Number.isInteger(N)&&N>=B.v&&E(B,N+1)}Xe(i)}return!0},ownKeys(a){v(i);var o=Reflect.ownKeys(a).filter(d=>{var c=r.get(d);return c===void 0||c.v!==S});for(var[f,u]of r)u.v!==S&&!(f in a)&&o.push(f);return o},setPrototypeOf(){In()}})}function jr(e){try{if(e!==null&&typeof e=="object"&&Ue in e)return e[Ue]}catch{}return e}function ai(e,t){return Object.is(jr(e),jr(t))}var Ar,Nr,Cr,Rr;function Ft(){if(Ar===void 0){Ar=window,Nr=/Firefox/.test(navigator.userAgent);var e=Element.prototype,t=Node.prototype,r=Text.prototype;Cr=Le(t,"firstChild").get,Rr=Le(t,"nextSibling").get,sr(e)&&(e.__click=void 0,e.__className=void 0,e.__attributes=null,e.__style=void 0,e.__e=void 0),sr(r)&&(r.__t=void 0)}}function V(e=""){return document.createTextNode(e)}function Ve(e){return Cr.call(e)}function Z(e){return Rr.call(e)}function qe(e,t){if(!p)return Ve(e);var r=Ve(m);if(r===null)r=m.appendChild(V());else if(t&&r.nodeType!==vt){var n=V();return r?.before(n),M(n),n}return M(r),r}function Lr(e,t=!1){if(!p){var r=Ve(e);return r instanceof Comment&&r.data===""?Z(r):r}if(t&&m?.nodeType!==vt){var n=V();return m?.before(n),M(n),n}return m}function Ze(e,t=1,r=!1){let n=p?m:e;for(var i;t--;)i=n,n=Z(n);if(!p)return n;if(r&&n?.nodeType!==vt){var s=V();return n===null?i?.after(s):n.before(s),M(s),s}return M(n),n}function Mr(e){e.textContent=""}function Or(){return!1}let Dr=!1;function Ir(){Dr||(Dr=!0,document.addEventListener("reset",e=>{Promise.resolve().then(()=>{if(!e.defaultPrevented)for(const t of e.target.elements)t.__on_r?.()})},{capture:!0}))}function yt(e){var t=g,r=y;O(null),te(null);try{return e()}finally{O(t),te(r)}}function Pr(e,t,r,n=r){e.addEventListener(t,()=>yt(r));const i=e.__on_r;i?e.__on_r=()=>{i(),n(!0)}:e.__on_r=()=>n(!0),Ir()}function li(e){y===null&&(g===null&&Ln(),Rn()),Se&&Cn()}function oi(e,t){var r=t.last;r===null?t.last=t.first=e:(r.next=e,e.prev=r,t.last=e)}function Q(e,t,r){var n=y;n!==null&&(n.f&I)!==0&&(e|=I);var i={ctx:P,deps:null,nodes_start:null,nodes_end:null,f:e|L|z,first:null,fn:t,last:null,next:null,parent:n,b:n&&n.b,prev:null,teardown:null,transitions:null,wv:0,ac:null};if(r)try{tt(i),i.f|=dt}catch(a){throw C(i),a}else t!==null&&xe(i);var s=i;if(r&&s.deps===null&&s.teardown===null&&s.nodes_start===null&&s.first===s.last&&(s.f&we)===0&&(s=s.first,(e&ie)!==0&&(e&Me)!==0&&s!==null&&(s.f|=Me)),s!==null&&(s.parent=n,n!==null&&oi(s,n),g!==null&&(g.f&T)!==0&&(e&de)===0)){var l=g;(l.effects??=[]).push(s)}return i}function wt(){return g!==null&&!ee}function Vt(e){const t=Q(Rt,null,!1);return A(t,j),t.teardown=e,t}function qt(e){li();var t=y.f,r=!g&&(t&se)!==0&&(t&dt)===0;if(r){var n=P;(n.e??=[]).push(e)}else return Fr(e)}function Fr(e){return Q(Ct|Tn,e,!1)}function fi(e){G.ensure();const t=Q(de|we,e,!0);return()=>{C(t)}}function ui(e){G.ensure();const t=Q(de|we,e,!0);return(r={})=>new Promise(n=>{r.outro?Be(t,()=>{C(t),n(void 0)}):(C(t),n(void 0))})}function Vr(e){return Q(Ct,e,!1)}function ci(e){return Q(Mt|we,e,!0)}function Bt(e,t=0){return Q(Rt|t,e,!0)}function $t(e,t=[],r=[],n=[]){ei(n,t,r,i=>{Q(Rt,()=>e(...i.map(v)),!0)})}function Ht(e,t=0){var r=Q(ie|t,e,!0);return r}function Y(e){return Q(se|we,e,!0)}function qr(e){var t=e.teardown;if(t!==null){const r=Se,n=g;zr(!0),O(null);try{t.call(null)}finally{zr(r),O(n)}}}function Br(e,t=!1){var r=e.first;for(e.first=e.last=null;r!==null;){const i=r.ac;i!==null&&yt(()=>{i.abort(Oe)});var n=r.next;(r.f&de)!==0?r.parent=null:C(r,t),r=n}}function di(e){for(var t=e.first;t!==null;){var r=t.next;(t.f&se)===0&&C(t),t=r}}function C(e,t=!0){var r=!1;(t||(e.f&or)!==0)&&e.nodes_start!==null&&e.nodes_end!==null&&(vi(e.nodes_start,e.nodes_end),r=!0),Br(e,t&&!r),xt(e,0),A(e,le);var n=e.transitions;if(n!==null)for(const s of n)s.stop();qr(e);var i=e.parent;i!==null&&i.first!==null&&Hr(e),e.next=e.prev=e.teardown=e.ctx=e.deps=e.fn=e.nodes_start=e.nodes_end=e.ac=null}function vi(e,t){for(;e!==null;){var r=e===t?null:Z(e);e.remove(),e=r}}function Hr(e){var t=e.parent,r=e.prev,n=e.next;r!==null&&(r.next=n),n!==null&&(n.prev=r),t!==null&&(t.first===e&&(t.first=n),t.last===e&&(t.last=r))}function Be(e,t,r=!0){var n=[];Ut(e,n,!0),Ur(n,()=>{r&&C(e),t&&t()})}function Ur(e,t){var r=e.length;if(r>0){var n=()=>--r||t();for(var i of e)i.out(n)}else t()}function Ut(e,t,r){if((e.f&I)===0){if(e.f^=I,e.transitions!==null)for(const l of e.transitions)(l.is_global||r)&&t.push(l);for(var n=e.first;n!==null;){var i=n.next,s=(n.f&Me)!==0||(n.f&se)!==0&&(e.f&ie)!==0;Ut(n,t,s?r:!1),n=i}}}function Yt(e){Yr(e,!0)}function Yr(e,t){if((e.f&I)!==0){e.f^=I,(e.f&j)===0&&(A(e,L),xe(e));for(var r=e.first;r!==null;){var n=r.next,i=(r.f&Me)!==0||(r.f&se)!==0;Yr(r,i?t:!1),r=n}if(e.transitions!==null)for(const s of e.transitions)(s.is_global||t)&&s.in()}}function Wr(e,t){for(var r=e.nodes_start,n=e.nodes_end;r!==null;){var i=r===n?null:Z(r);t.append(r),r=i}}let _e=!1;function Et(e){_e=e}let Se=!1;function zr(e){Se=e}let g=null,ee=!1;function O(e){g=e}let y=null;function te(e){y=e}let ue=null;function Gr(e){g!==null&&(ue===null?ue=[e]:ue.push(e))}let R=null,q=0,W=null;function hi(e){W=e}let Jr=1,Qe=0,je=Qe;function Kr(e){je=e}function Xr(){return++Jr}function et(e){var t=e.f;if((t&L)!==0)return!0;if(t&T&&(e.f&=~$e),(t&ae)!==0){var r=e.deps;if(r!==null)for(var n=r.length,i=0;i<n;i++){var s=r[i];if(et(s)&&xr(s),s.wv>e.wv)return!0}(t&z)!==0&&H===null&&A(e,j)}return!1}function Zr(e,t,r=!0){var n=e.reactions;if(n!==null&&!ue?.includes(e))for(var i=0;i<n.length;i++){var s=n[i];(s.f&T)!==0?Zr(s,t,!1):t===s&&(r?A(s,L):(s.f&j)!==0&&A(s,ae),xe(s))}}function Qr(e){var t=R,r=q,n=W,i=g,s=ue,l=P,a=ee,o=je,f=e.f;R=null,q=0,W=null,g=(f&(se|de))===0?e:null,ue=null,Pe(e.ctx),ee=!1,je=++Qe,e.ac!==null&&(yt(()=>{e.ac.abort(Oe)}),e.ac=null);try{e.f|=Lt;var u=e.fn,d=u(),c=e.deps;if(R!==null){var h;if(xt(e,q),c!==null&&q>0)for(c.length=q+R.length,h=0;h<R.length;h++)c[q+h]=R[h];else e.deps=c=R;if(_e&&wt()&&(e.f&z)!==0)for(h=q;h<c.length;h++)(c[h].reactions??=[]).push(e)}else c!==null&&q<c.length&&(xt(e,q),c.length=q);if(hr()&&W!==null&&!ee&&c!==null&&(e.f&(T|ae|L))===0)for(h=0;h<W.length;h++)Zr(W[h],e);return i!==null&&i!==e&&(Qe++,W!==null&&(n===null?n=W:n.push(...W))),(e.f&ve)!==0&&(e.f^=ve),d}catch(_){return br(_)}finally{e.f^=Lt,R=t,q=r,W=n,g=i,ue=s,Pe(l),ee=a,je=o}}function _i(e,t){let r=t.reactions;if(r!==null){var n=wn.call(r,e);if(n!==-1){var i=r.length-1;i===0?r=t.reactions=null:(r[n]=r[i],r.pop())}}r===null&&(t.f&T)!==0&&(R===null||!R.includes(t))&&(A(t,ae),(t.f&z)!==0&&(t.f^=z,t.f&=~$e),Er(t),xt(t,0))}function xt(e,t){var r=e.deps;if(r!==null)for(var n=t;n<r.length;n++)_i(e,r[n])}function tt(e){var t=e.f;if((t&le)===0){A(e,j);var r=y,n=_e;y=e,_e=!0;try{(t&ie)!==0?di(e):Br(e),qr(e);var i=Qr(e);e.teardown=typeof i=="function"?i:null,e.wv=Jr;var s;jt&&Un&&(e.f&L)!==0&&e.deps}finally{_e=n,y=r}}}async function bi(){await Promise.resolve(),Je()}function v(e){var t=e.f,r=(t&T)!==0;if(g!==null&&!ee){var n=y!==null&&(y.f&le)!==0;if(!n&&!ue?.includes(e)){var i=g.deps;if((g.f&Lt)!==0)e.rv<Qe&&(e.rv=Qe,R===null&&i!==null&&i[q]===e?q++:R===null?R=[e]:R.includes(e)||R.push(e));else{(g.deps??=[]).push(e);var s=e.reactions;s===null?e.reactions=[g]:s.includes(g)||s.push(g)}}}if(Se){if(he.has(e))return he.get(e);if(r){var l=e,a=l.v;return((l.f&j)===0&&l.reactions!==null||tn(l))&&(a=It(l)),he.set(l,a),a}}else r&&!H?.has(e)&&(l=e,et(l)&&xr(l),_e&&wt()&&(l.f&z)===0&&en(l));if(H?.has(e))return H.get(e);if((e.f&ve)!==0)throw e.v;return e.v}function en(e){if(e.deps!==null){e.f^=z;for(const t of e.deps)(t.reactions??=[]).push(e),(t.f&T)!==0&&(t.f&z)===0&&en(t)}}function tn(e){if(e.v===S)return!0;if(e.deps===null)return!1;for(const t of e.deps)if(he.has(t)||(t.f&T)!==0&&tn(t))return!0;return!1}function Wt(e){var t=ee;try{return ee=!0,e()}finally{ee=t}}const pi=-7169;function A(e,t){e.f=e.f&pi|t}const rn=new Set,zt=new Set;function gi(e,t,r,n={}){function i(s){if(n.capture||rt.call(t,s),!s.cancelBubble)return yt(()=>r?.call(this,s))}return e.startsWith("pointer")||e.startsWith("touch")||e==="wheel"?We(()=>{t.addEventListener(e,i,n)}):t.addEventListener(e,i,n),i}function mi(e,t,r,n,i){var s={capture:n,passive:i},l=gi(e,t,r,s);(t===document.body||t===window||t===document||t instanceof HTMLMediaElement)&&Vt(()=>{t.removeEventListener(e,l,s)})}function yi(e){for(var t=0;t<e.length;t++)rn.add(e[t]);for(var r of zt)r(e)}let nn=null;function rt(e){var t=this,r=t.ownerDocument,n=e.type,i=e.composedPath?.()||[],s=i[0]||e.target;nn=e;var l=0,a=nn===e&&e.__root;if(a){var o=i.indexOf(a);if(o!==-1&&(t===document||t===window)){e.__root=t;return}var f=i.indexOf(t);if(f===-1)return;o<=f&&(l=o)}if(s=i[l]||e.target,s!==t){ut(e,"currentTarget",{configurable:!0,get(){return s||r}});var u=g,d=y;O(null),te(null);try{for(var c,h=[];s!==null;){var _=s.assignedSlot||s.parentNode||s.host||null;try{var k=s["__"+n];k!=null&&(!s.disabled||e.target===s)&&k.call(s,e)}catch(x){c?h.push(x):c=x}if(e.cancelBubble||_===t||_===null)break;s=_}if(c){for(let x of h)queueMicrotask(()=>{throw x});throw c}}finally{e.__root=t,delete e.currentTarget,O(u),te(d)}}}function wi(e){var t=document.createElement("template");return t.innerHTML=e.replaceAll("<!>","<!---->"),t.content}function be(e,t){var r=y;r.nodes_start===null&&(r.nodes_start=e,r.nodes_end=t)}function nt(e,t){var r=(t&gn)!==0,n=(t&mn)!==0,i,s=!e.startsWith("<!>");return()=>{if(p)return be(m,null),m;i===void 0&&(i=wi(s?e:"<!>"+e),r||(i=Ve(i)));var l=n||Nr?document.importNode(i,!0):i.cloneNode(!0);if(r){var a=Ve(l),o=l.lastChild;be(a,o)}else be(l,l);return l}}function $i(e=""){if(!p){var t=V(e+"");return be(t,t),t}var r=m;return r.nodeType!==vt&&(r.before(r=V()),M(r)),be(r,r),r}function Ei(){if(p)return be(m,null),m;var e=document.createDocumentFragment(),t=document.createComment(""),r=V();return e.append(t,r),be(t,r),e}function pe(e,t){if(p){var r=y;((r.f&dt)===0||r.nodes_end===null)&&(r.nodes_end=m),Ye();return}e!==null&&e.before(t)}const xi=["touchstart","touchmove"];function ki(e){return xi.includes(e)}function Gt(e,t){var r=t==null?"":typeof t=="object"?t+"":t;r!==(e.__t??=e.nodeValue)&&(e.__t=r,e.nodeValue=r+"")}function sn(e,t){return an(e,t)}function Ti(e,t){Ft(),t.intro=t.intro??!1;const r=t.target,n=p,i=m;try{for(var s=Ve(r);s&&(s.nodeType!==De||s.data!==ir);)s=Z(s);if(!s)throw Re;oe(!0),M(s);const l=an(e,{...t,anchor:s});return oe(!1),l}catch(l){if(l instanceof Error&&l.message.split(`
2
- `).some(a=>a.startsWith("https://svelte.dev/e/")))throw l;return l!==Re&&console.warn("Failed to hydrate: ",l),t.recover===!1&&On(),Ft(),Mr(r),oe(!1),sn(e,t)}finally{oe(n),M(i)}}const He=new Map;function an(e,{target:t,anchor:r,props:n={},events:i,context:s,intro:l=!0}){Ft();var a=new Set,o=d=>{for(var c=0;c<d.length;c++){var h=d[c];if(!a.has(h)){a.add(h);var _=ki(h);t.addEventListener(h,rt,{passive:_});var k=He.get(h);k===void 0?(document.addEventListener(h,rt,{passive:_}),He.set(h,1)):He.set(h,k+1)}}};o(Nt(rn)),zt.add(o);var f=void 0,u=ui(()=>{var d=r??t.appendChild(V());return Jn(d,{pending:()=>{}},c=>{if(s){dr({});var h=P;h.c=s}if(i&&(n.$$events=i),p&&be(c,null),f=e(c,n)||{},p&&(y.nodes_end=m,m===null||m.nodeType!==De||m.data!==St))throw ht(),Re;s&&vr()}),()=>{for(var c of a){t.removeEventListener(c,rt);var h=He.get(c);--h===0?(document.removeEventListener(c,rt),He.delete(c)):He.set(c,h)}zt.delete(o),d!==r&&d.parentNode?.removeChild(d)}});return Jt.set(f,u),f}let Jt=new WeakMap;function Si(e,t){const r=Jt.get(e);return r?(Jt.delete(e),r(t)):Promise.resolve()}class ji{anchor;#t=new Map;#e=new Map;#r=new Map;#n=new Set;#o=!0;constructor(t,r=!0){this.anchor=t,this.#o=r}#s=()=>{var t=w;if(this.#t.has(t)){var r=this.#t.get(t),n=this.#e.get(r);if(n)Yt(n),this.#n.delete(r);else{var i=this.#r.get(r);i&&(this.#e.set(r,i.effect),this.#r.delete(r),i.fragment.lastChild.remove(),this.anchor.before(i.fragment),n=i.effect)}for(const[s,l]of this.#t){if(this.#t.delete(s),s===t)break;const a=this.#r.get(l);a&&(C(a.effect),this.#r.delete(l))}for(const[s,l]of this.#e){if(s===r||this.#n.has(s))continue;const a=()=>{if(Array.from(this.#t.values()).includes(s)){var f=document.createDocumentFragment();Wr(l,f),f.append(V()),this.#r.set(s,{effect:l,fragment:f})}else C(l);this.#n.delete(s),this.#e.delete(s)};this.#o||!n?(this.#n.add(s),Be(l,a,!1)):a()}}};#i=t=>{this.#t.delete(t);const r=Array.from(this.#t.values());for(const[n,i]of this.#r)r.includes(n)||(C(i.effect),this.#r.delete(n))};ensure(t,r){var n=w,i=Or();if(r&&!this.#e.has(t)&&!this.#r.has(t))if(i){var s=document.createDocumentFragment(),l=V();s.append(l),this.#r.set(t,{effect:Y(()=>r(l)),fragment:s})}else this.#e.set(t,Y(()=>r(this.anchor)));if(this.#t.set(n,t),i){for(const[a,o]of this.#e)a===t?n.skipped_effects.delete(o):n.skipped_effects.add(o);for(const[a,o]of this.#r)a===t?n.skipped_effects.delete(o.effect):n.skipped_effects.add(o.effect);n.oncommit(this.#s),n.ondiscard(this.#i)}else p&&(this.anchor=m),this.#s()}}function Ai(e){P===null&&An(),qt(()=>{const t=Wt(e);if(typeof t=="function")return t})}function Kt(e,t,r=!1){p&&Ye();var n=new ji(e),i=r?Me:0;function s(l,a){if(p){const f=fr(e)===ot;if(l===f){var o=_t();M(o),n.anchor=o,oe(!1),n.ensure(l,a),oe(!0);return}}n.ensure(l,a)}Ht(()=>{var l=!1;t((a,o=!0)=>{l=!0,s(o,a)}),l||s(!1,null)},i)}function Ni(e,t,r,n,i){p&&Ye();var s=t.$$slots?.[r],l=!1;s===!0&&(s=t[r],l=!0),s===void 0?i!==null&&i(e):s(e,l?()=>n:n)}function Ci(e,t){Vr(()=>{var r=e.getRootNode(),n=r.host?r:r.head??r.ownerDocument.head;if(!n.querySelector("#"+t.hash)){const i=document.createElement("style");i.id=t.hash,i.textContent=t.code,n.appendChild(i)}})}function Ri(e,t,r){var n=e==null?"":""+e;return n=n?n+" "+t:t,n===""?null:n}function Li(e,t){return e==null?null:String(e)}function ln(e,t,r,n,i,s){var l=e.__className;if(p||l!==r||l===void 0){var a=Ri(r,n);(!p||a!==e.getAttribute("class"))&&(a==null?e.removeAttribute("class"):e.className=a),e.__className=r}return s}function kt(e,t,r,n){var i=e.__style;if(p||i!==t){var s=Li(t);(!p||s!==e.getAttribute("style"))&&(s==null?e.removeAttribute("style"):e.style.cssText=s),e.__style=t}return n}function on(e,t,r=!1){if(e.multiple){if(t==null)return;if(!At(t))return Vn();for(var n of e.options)n.selected=t.includes(it(n));return}for(n of e.options){var i=it(n);if(ai(i,t)){n.selected=!0;return}}(!r||t!==void 0)&&(e.selectedIndex=-1)}function Mi(e){var t=new MutationObserver(()=>{on(e,e.__value)});t.observe(e,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["value"]}),Vt(()=>{t.disconnect()})}function Oi(e,t,r=t){var n=new WeakSet,i=!0;Pr(e,"change",s=>{var l=s?"[selected]":":checked",a;if(e.multiple)a=[].map.call(e.querySelectorAll(l),it);else{var o=e.querySelector(l)??e.querySelector("option:not([disabled])");a=o&&it(o)}r(a),w!==null&&n.add(w)}),Vr(()=>{var s=t();if(e===document.activeElement){var l=ze??w;if(n.has(l))return}if(on(e,s,i),i&&s===void 0){var a=e.querySelector(":checked");a!==null&&(s=it(a),r(s))}e.__value=s,i=!1}),Mi(e)}function it(e){return"__value"in e?e.__value:e.value}const Di=Symbol("is custom element"),Ii=Symbol("is html");function Pi(e){if(p){var t=!1,r=()=>{if(!t){if(t=!0,e.hasAttribute("value")){var n=e.value;fn(e,"value",null),e.value=n}if(e.hasAttribute("checked")){var i=e.checked;fn(e,"checked",null),e.checked=i}}};e.__on_r=r,We(r),Ir()}}function fn(e,t,r,n){var i=Fi(e);p&&(i[t]=e.getAttribute(t),t==="src"||t==="srcset"||t==="href"&&e.nodeName==="LINK")||i[t]!==(i[t]=r)&&(t==="loading"&&(e[jn]=r),e.removeAttribute(t))}function Fi(e){return e.__attributes??={[Di]:e.nodeName.includes("-"),[Ii]:e.namespaceURI===yn}}function Vi(e,t,r=t){var n=new WeakSet;Pr(e,"input",async i=>{var s=i?e.defaultValue:e.value;if(s=Xt(e)?Zt(s):s,r(s),w!==null&&n.add(w),await bi(),s!==(s=t())){var l=e.selectionStart,a=e.selectionEnd,o=e.value.length;if(e.value=s??"",a!==null){var f=e.value.length;l===a&&a===o&&f>o?(e.selectionStart=f,e.selectionEnd=f):(e.selectionStart=l,e.selectionEnd=Math.min(a,f))}}}),(p&&e.defaultValue!==e.value||Wt(t)==null&&e.value)&&(r(Xt(e)?Zt(e.value):e.value),w!==null&&n.add(w)),Bt(()=>{var i=t();if(e===document.activeElement){var s=ze??w;if(n.has(s))return}Xt(e)&&i===Zt(e.value)||e.type==="date"&&!i&&!e.value||i!==e.value&&(e.value=i??"")})}function Xt(e){var t=e.type;return t==="number"||t==="range"}function Zt(e){return e===""?null:+e}function Qt(e,t,r,n){var i=n,s=!0,l=()=>(s&&(s=!1,i=n),i),a;a=e[t],a===void 0&&n!==void 0&&(a=l());var o;o=()=>{var c=e[t];return c===void 0?l():(s=!0,c)};var f=!1,u=mt(()=>(f=!1,o())),d=y;return(function(c,h){if(arguments.length>0){const _=h?v(u):c;return E(u,_),f=!0,i!==void 0&&(i=_),c}return Se&&f||(d.f&le)!==0?u.v:v(u)})}function qi(e){return new Bi(e)}class Bi{#t;#e;constructor(t){var r=new Map,n=(s,l)=>{var a=Tr(l,!1,!1);return r.set(s,a),a};const i=new Proxy({...t.props||{},$$events:{}},{get(s,l){return v(r.get(l)??n(l,Reflect.get(s,l)))},has(s,l){return l===Sn?!0:(v(r.get(l)??n(l,Reflect.get(s,l))),Reflect.has(s,l))},set(s,l,a){return E(r.get(l)??n(l,a),a),Reflect.set(s,l,a)}});this.#e=(t.hydrate?Ti:sn)(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)&&Je(),this.#t=i.$$events;for(const s of Object.keys(this.#e))s==="$set"||s==="$destroy"||s==="$on"||ut(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=()=>{Si(this.#e)}}$set(t){this.#e.$set(t)}$on(t,r){this.#t[t]=this.#t[t]||[];const n=(...i)=>r.call(this,...i);return this.#t[t].push(n),()=>{this.#t[t]=this.#t[t].filter(i=>i!==n)}}$destroy(){this.#e.$destroy()}}let un;typeof HTMLElement=="function"&&(un=class extends HTMLElement{$$ctor;$$s;$$c;$$cn=!1;$$d={};$$r=!1;$$p_d={};$$l={};$$l_u=new Map;$$me;constructor(e,t,r){super(),this.$$ctor=e,this.$$s=t,r&&this.attachShadow({mode:"open"})}addEventListener(e,t,r){if(this.$$l[e]=this.$$l[e]||[],this.$$l[e].push(t),this.$$c){const n=this.$$c.$on(e,t);this.$$l_u.set(t,n)}super.addEventListener(e,t,r)}removeEventListener(e,t,r){if(super.removeEventListener(e,t,r),this.$$c){const n=this.$$l_u.get(t);n&&(n(),this.$$l_u.delete(t))}}async connectedCallback(){if(this.$$cn=!0,!this.$$c){let e=function(n){return i=>{const s=document.createElement("slot");n!=="default"&&(s.name=n),pe(i,s)}};if(await Promise.resolve(),!this.$$cn||this.$$c)return;const t={},r=Hi(this);for(const n of this.$$s)n in r&&(n==="default"&&!this.$$d.children?(this.$$d.children=e(n),t.default=!0):t[n]=e(n));for(const n of this.attributes){const i=this.$$g_p(n.name);i in this.$$d||(this.$$d[i]=Tt(i,n.value,this.$$p_d,"toProp"))}for(const n in this.$$p_d)!(n in this.$$d)&&this[n]!==void 0&&(this.$$d[n]=this[n],delete this[n]);this.$$c=qi({component:this.$$ctor,target:this.shadowRoot||this,props:{...this.$$d,$$slots:t,$$host:this}}),this.$$me=fi(()=>{Bt(()=>{this.$$r=!0;for(const n of ft(this.$$c)){if(!this.$$p_d[n]?.reflect)continue;this.$$d[n]=this.$$c[n];const i=Tt(n,this.$$d[n],this.$$p_d,"toAttribute");i==null?this.removeAttribute(this.$$p_d[n].attribute||n):this.setAttribute(this.$$p_d[n].attribute||n,i)}this.$$r=!1})});for(const n in this.$$l)for(const i of this.$$l[n]){const s=this.$$c.$on(n,i);this.$$l_u.set(i,s)}this.$$l={}}}attributeChangedCallback(e,t,r){this.$$r||(e=this.$$g_p(e),this.$$d[e]=Tt(e,r,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 ft(this.$$p_d).find(t=>this.$$p_d[t].attribute===e||!this.$$p_d[t].attribute&&t.toLowerCase()===e)||e}});function Tt(e,t,r,n){const i=r[e]?.type;if(t=i==="Boolean"&&typeof t!="boolean"?t!=null:t,!n||!r[e])return t;if(n==="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 Hi(e){const t={};return e.childNodes.forEach(r=>{t[r.slot||"default"]=!0}),t}function Ui(e,t,r,n,i,s){let l=class extends un{constructor(){super(e,r,i),this.$$p_d=t}static get observedAttributes(){return ft(t).map(a=>(t[a].attribute||a).toLowerCase())}};return ft(t).forEach(a=>{ut(l.prototype,a,{get(){return this.$$c&&a in this.$$c?this.$$c[a]:this.$$d[a]},set(o){o=Tt(a,o,t),this.$$d[a]=o;var f=this.$$c;if(f){var u=Le(f,a)?.get;u?f[a]=o:f.$set({[a]:o})}}})}),n.forEach(a=>{ut(l.prototype,a,{get(){return this.$$c?.[a]}})}),e.element=l,l}var Ae={},cn;function Yi(){if(cn)return Ae;cn=1,Object.defineProperty(Ae,"__esModule",{value:!0}),Ae.LanguageTranslator=void 0,Ae.getChildStyleToPass=e,Ae.addComponent=t;function e(n,i){var s,l,a="";try{if(n&&i?.length&&(!((s=Object.keys(n))===null||s===void 0)&&s.length)&&(!((l=i?.filter(function(c){return Object.keys(n).includes(c.name)}))===null||l===void 0)&&l.length))for(var o=function(c){var h=i?.filter(function(_){return _.name===c&&_.defaultValue!==n[c]});h&&(a+="".concat(c,":").concat(n[c],";"))},f=0,u=Object.keys(n);f<u.length;f++){var d=u[f];o(d)}}catch(c){console.error("error getting child style to pass",c)}finally{return a}}function t(n){var i,s=((i=n?.repoName.split("/"))===null||i===void 0?void 0:i[1])||n?.repoName;if(!s)throw new Error("wrong componentPath "+n?.repoName);if(!n?.version)throw new Error("wrong version "+n?.version);var l=n?.iifePath||"main.iife.js";if(!document.getElementById(s+"-script"))try{var a=document.createElement("script");if(a.id=s+"-script",a.src="https://cdn.jsdelivr.net/npm/".concat(n.repoName,"@").concat(n.version,"/").concat(l),n?.local)a.src="".concat(n.local);else if(location.href.includes("localhost:6006")){var o=s.split("-")[0];a.src="http://localhost:6006/webcomponents/".concat(s.replace(o+"-",""),"/").concat(l)}document.head.appendChild(a)}catch(f){console.warn(f)}}var r=(function(){function n(i){if(this.lang="",!i?.dictionary)throw new Error("no dictionary provided");this.dictionary=i.dictionary,this.setLang(i?.lang)}return n.prototype.setLang=function(i){i||(i=n.getDefaultLang()),this.lang=i},n.prototype.translateWord=function(i,s){return n.getDictionaryWord(i,this.dictionary,s||this.lang)},n.prototype.translateDate=function(i,s,l){return n.formatDate(i,s,l||this.lang)},n.getDefaultLang=function(){var i,s,l,a="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)&&(a=navigator.languages[0].split("-")[0].toLowerCase()),a},n.getDictionaryWord=function(i,s,l){var a;if(!i)throw new Error("no wordKey provided");if(!s)throw new Error("no dictionary provided");if(l&&(!((a=s[l])===null||a===void 0)&&a[i]))return s[l][i];var o="",f=n.getDefaultLang();if(!l||f!==l){var u=s?.[f];u?.[i]&&(o=u[i])}return o},n.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 a=new Intl.DateTimeFormat(l||n.getDefaultLang(),s);return a.format(i)},n})();return Ae.LanguageTranslator=r,Ae}Yi();var Wi=nt('<button class="remove-tag svelte-jyvf24" type="button" aria-label="remove tag"><span class="circle svelte-jyvf24">x</span></button>'),zi=nt("<span> <!></span>"),Gi=nt('<option class="svelte-jyvf24"> </option>'),Ji=nt('<option class="svelte-jyvf24">New Tag</option>'),Ki=nt('<!> <button type="button"><!></button> <span class="svelte-jyvf24"><input id="input-text-add" class="input-val svelte-jyvf24" type="text"/></span> <span class="svelte-jyvf24"><select id="input-select-add" class="input-val svelte-jyvf24"><!><!></select></span>',1);const Xi={hash:"svelte-jyvf24",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");
1
+ (function(ir){"use strict";typeof window<"u"&&((window.__svelte??={}).v??=new Set).add("5");const bn=1,pn=2,gn=16,mn=1,yn=2,sr="[",ot="[!",jt="]",Re={},S=Symbol(),wn="http://www.w3.org/1999/xhtml",At=!1;var Nt=Array.isArray,$n=Array.prototype.indexOf,Ct=Array.from,ft=Object.keys,ut=Object.defineProperty,Le=Object.getOwnPropertyDescriptor,En=Object.prototype,kn=Array.prototype,xn=Object.getPrototypeOf,ar=Object.isExtensible;function Tn(e){for(var t=0;t<e.length;t++)e[t]()}function lr(){var e,t,r=new Promise((n,i)=>{e=n,t=i});return{promise:r,resolve:e,reject:t}}const T=2,Rt=4,Lt=8,se=16,ae=32,ve=64,ct=128,z=512,j=1024,L=2048,le=4096,I=8192,oe=16384,dt=32768,Me=65536,or=1<<17,fr=1<<18,$e=1<<19,Sn=1<<20,Ee=32768,Mt=1<<21,Ot=1<<22,he=1<<23,We=Symbol("$state"),jn=Symbol("legacy props"),An=Symbol(""),Oe=new class extends Error{name="StaleReactionError";message="The reaction that called `getAbortSignal()` was re-run or destroyed"},vt=3,De=8;function Nn(e){throw new Error("https://svelte.dev/e/lifecycle_outside_component")}function Cn(){throw new Error("https://svelte.dev/e/async_derived_orphan")}function Rn(e){throw new Error("https://svelte.dev/e/effect_in_teardown")}function Ln(){throw new Error("https://svelte.dev/e/effect_in_unowned_derived")}function Mn(e){throw new Error("https://svelte.dev/e/effect_orphan")}function On(){throw new Error("https://svelte.dev/e/effect_update_depth_exceeded")}function Dn(){throw new Error("https://svelte.dev/e/hydration_failed")}function In(){throw new Error("https://svelte.dev/e/state_descriptors_fixed")}function Pn(){throw new Error("https://svelte.dev/e/state_prototype_fixed")}function Fn(){throw new Error("https://svelte.dev/e/state_unsafe_mutation")}function Vn(){throw new Error("https://svelte.dev/e/svelte_boundary_reset_onerror")}function ht(e){console.warn("https://svelte.dev/e/hydration_mismatch")}function qn(){console.warn("https://svelte.dev/e/select_multiple_invalid_value")}function Bn(){console.warn("https://svelte.dev/e/svelte_boundary_reset_noop")}let p=!1;function fe(e){p=e}let m;function M(e){if(e===null)throw ht(),Re;return m=e}function ze(){return M(Z(m))}function Ie(e){if(p){if(Z(m)!==null)throw ht(),Re;m=e}}function Hn(e=1){if(p){for(var t=e,r=m;t--;)r=Z(r);m=r}}function _t(e=!0){for(var t=0,r=m;;){if(r.nodeType===De){var n=r.data;if(n===jt){if(t===0)return r;t-=1}else(n===sr||n===ot)&&(t+=1)}var i=Z(r);e&&r.remove(),r=i}}function ur(e){if(!e||e.nodeType!==De)throw ht(),Re;return e.data}function cr(e){return e===this.v}function Un(e,t){return e!=e?t==t:e!==t||e!==null&&typeof e=="object"||typeof e=="function"}function dr(e){return!Un(e,this.v)}let Yn=!1,P=null;function Pe(e){P=e}function vr(e,t=!1,r){P={p:P,i:!1,c:null,e:null,s:e,x:null,l:null}}function hr(e){var t=P,r=t.e;if(r!==null){t.e=null;for(var n of r)Vr(n)}return e!==void 0&&(t.x=e),t.i=!0,P=t.p,e??{}}function _r(){return!0}let ke=[];function br(){var e=ke;ke=[],Tn(e)}function Ge(e){if(ke.length===0&&!Ke){var t=ke;queueMicrotask(()=>{t===ke&&br()})}ke.push(e)}function Wn(){for(;ke.length>0;)br()}function pr(e){var t=y;if(t===null)return g.f|=he,e;if((t.f&dt)===0){if((t.f&ct)===0)throw e;t.b.error(e)}else Fe(e,t)}function Fe(e,t){for(;t!==null;){if((t.f&ct)!==0)try{t.b.error(e);return}catch(r){e=r}t=t.parent}throw e}const bt=new Set;let w=null,Je=null,H=null,U=[],pt=null,Dt=!1,Ke=!1;class G{committed=!1;current=new Map;previous=new Map;#t=new Set;#e=new Set;#r=0;#n=0;#o=null;#s=[];#i=[];skipped_effects=new Set;is_fork=!1;is_deferred(){return this.is_fork||this.#n>0}process(t){U=[],Je=null,this.apply();var r={parent:null,effect:null,effects:[],render_effects:[],block_effects:[]};for(const n of t)this.#a(n,r);this.is_fork||this.#u(),this.is_deferred()?(this.#l(r.effects),this.#l(r.render_effects),this.#l(r.block_effects)):(Je=this,w=null,mr(r.render_effects),mr(r.effects),Je=null,this.#o?.resolve()),H=null}#a(t,r){t.f^=j;for(var n=t.first;n!==null;){var i=n.f,s=(i&(ae|ve))!==0,l=s&&(i&j)!==0,a=l||(i&I)!==0||this.skipped_effects.has(n);if((n.f&ct)!==0&&n.b?.is_pending()&&(r={parent:r,effect:n,effects:[],render_effects:[],block_effects:[]}),!a&&n.fn!==null){s?n.f^=j:(i&Rt)!==0?r.effects.push(n):tt(n)&&((n.f&se)!==0&&r.block_effects.push(n),rt(n));var o=n.first;if(o!==null){n=o;continue}}var f=n.parent;for(n=n.next;n===null&&f!==null;)f===r.effect&&(this.#l(r.effects),this.#l(r.render_effects),this.#l(r.block_effects),r=r.parent),n=f.next,f=f.parent}}#l(t){for(const r of t)((r.f&L)!==0?this.#s:this.#i).push(r),this.#f(r.deps),A(r,j)}#f(t){if(t!==null)for(const r of t)(r.f&T)===0||(r.f&Ee)===0||(r.f^=Ee,this.#f(r.deps))}capture(t,r){this.previous.has(t)||this.previous.set(t,r),(t.f&he)===0&&(this.current.set(t,t.v),H?.set(t,t.v))}activate(){w=this,this.apply()}deactivate(){w===this&&(w=null,H=null)}flush(){if(this.activate(),U.length>0){if(gr(),w!==null&&w!==this)return}else this.#r===0&&this.process([]);this.deactivate()}discard(){for(const t of this.#e)t(this);this.#e.clear()}#u(){if(this.#n===0){for(const t of this.#t)t();this.#t.clear()}this.#r===0&&this.#c()}#c(){if(bt.size>1){this.previous.clear();var t=H,r=!0,n={parent:null,effect:null,effects:[],render_effects:[],block_effects:[]};for(const s of bt){if(s===this){r=!1;continue}const l=[];for(const[o,f]of this.current){if(s.current.has(o))if(r&&f!==s.current.get(o))s.current.set(o,f);else continue;l.push(o)}if(l.length===0)continue;const a=[...s.current.keys()].filter(o=>!this.current.has(o));if(a.length>0){var i=U;U=[];const o=new Set,f=new Map;for(const u of l)yr(u,a,o,f);if(U.length>0){w=s,s.apply();for(const u of U)s.#a(u,n);s.deactivate()}U=i}}w=null,H=t}this.committed=!0,bt.delete(this)}increment(t){this.#r+=1,t&&(this.#n+=1)}decrement(t){this.#r-=1,t&&(this.#n-=1),this.revive()}revive(){for(const t of this.#s)A(t,L),xe(t);for(const t of this.#i)A(t,le),xe(t);this.#s=[],this.#i=[],this.flush()}oncommit(t){this.#t.add(t)}ondiscard(t){this.#e.add(t)}settled(){return(this.#o??=lr()).promise}static ensure(){if(w===null){const t=w=new G;bt.add(w),Ke||G.enqueue(()=>{w===t&&t.flush()})}return w}static enqueue(t){Ge(t)}apply(){}}function Xe(e){var t=Ke;Ke=!0;try{for(var r;;){if(Wn(),U.length===0&&(w?.flush(),U.length===0))return pt=null,r;gr()}}finally{Ke=t}}function gr(){var e=be;Dt=!0;var t=null;try{var r=0;for(Et(!0);U.length>0;){var n=G.ensure();if(r++>1e3){var i,s;zn()}n.process(U),_e.clear()}}finally{Dt=!1,Et(e),pt=null}}function zn(){try{On()}catch(e){Fe(e,pt)}}let ue=null;function mr(e){var t=e.length;if(t!==0){for(var r=0;r<t;){var n=e[r++];if((n.f&(oe|I))===0&&tt(n)&&(ue=new Set,rt(n),n.deps===null&&n.first===null&&n.nodes_start===null&&(n.teardown===null&&n.ac===null?Ur(n):n.fn=null),ue?.size>0)){_e.clear();for(const i of ue){if((i.f&(oe|I))!==0)continue;const s=[i];let l=i.parent;for(;l!==null;)ue.has(l)&&(ue.delete(l),s.push(l)),l=l.parent;for(let a=s.length-1;a>=0;a--){const o=s[a];(o.f&(oe|I))===0&&rt(o)}}ue.clear()}}ue=null}}function yr(e,t,r,n){if(!r.has(e)&&(r.add(e),e.reactions!==null))for(const i of e.reactions){const s=i.f;(s&T)!==0?yr(i,t,r,n):(s&(Ot|se))!==0&&(s&L)===0&&wr(i,t,n)&&(A(i,L),xe(i))}}function wr(e,t,r){const n=r.get(e);if(n!==void 0)return n;if(e.deps!==null)for(const i of e.deps){if(t.includes(i))return!0;if((i.f&T)!==0&&wr(i,t,r))return r.set(i,!0),!0}return r.set(e,!1),!1}function xe(e){for(var t=pt=e;t.parent!==null;){t=t.parent;var r=t.f;if(Dt&&t===y&&(r&se)!==0&&(r&fr)===0)return;if((r&(ve|ae))!==0){if((r&j)===0)return;t.f^=j}}U.push(t)}function Gn(e){let t=0,r=Te(0),n;return()=>{wt()&&(v(r),Ht(()=>(t===0&&(n=zt(()=>e(()=>Qe(r)))),t+=1,()=>{Ge(()=>{t-=1,t===0&&(n?.(),n=void 0,Qe(r))})})))}}var Jn=Me|$e|ct;function Kn(e,t,r){new Xn(e,t,r)}class Xn{parent;#t=!1;#e;#r=p?m:null;#n;#o;#s;#i=null;#a=null;#l=null;#f=null;#u=null;#c=0;#d=0;#h=!1;#v=null;#m=Gn(()=>(this.#v=Te(this.#c),()=>{this.#v=null}));constructor(t,r,n){this.#e=t,this.#n=r,this.#o=n,this.parent=y.b,this.#t=!!this.#n.pending,this.#s=Ut(()=>{if(y.b=this,p){const s=this.#r;ze(),s.nodeType===De&&s.data===ot?this.#w():this.#y()}else{var i=this.#p();try{this.#i=Y(()=>n(i))}catch(s){this.error(s)}this.#d>0?this.#b():this.#t=!1}return()=>{this.#u?.remove()}},Jn),p&&(this.#e=m)}#y(){try{this.#i=Y(()=>this.#o(this.#e))}catch(t){this.error(t)}this.#t=!1}#w(){const t=this.#n.pending;t&&(this.#a=Y(()=>t(this.#e)),G.enqueue(()=>{var r=this.#p();this.#i=this.#_(()=>(G.ensure(),Y(()=>this.#o(r)))),this.#d>0?this.#b():(He(this.#a,()=>{this.#a=null}),this.#t=!1)}))}#p(){var t=this.#e;return this.#t&&(this.#u=V(),this.#e.before(this.#u),t=this.#u),t}is_pending(){return this.#t||!!this.parent&&this.parent.is_pending()}has_pending_snippet(){return!!this.#n.pending}#_(t){var r=y,n=g,i=P;te(this.#s),O(this.#s),Pe(this.#s.ctx);try{return t()}catch(s){return pr(s),null}finally{te(r),O(n),Pe(i)}}#b(){const t=this.#n.pending;this.#i!==null&&(this.#f=document.createDocumentFragment(),this.#f.append(this.#u),zr(this.#i,this.#f)),this.#a===null&&(this.#a=Y(()=>t(this.#e)))}#g(t){if(!this.has_pending_snippet()){this.parent&&this.parent.#g(t);return}this.#d+=t,this.#d===0&&(this.#t=!1,this.#a&&He(this.#a,()=>{this.#a=null}),this.#f&&(this.#e.before(this.#f),this.#f=null))}update_pending_count(t){this.#g(t),this.#c+=t,this.#v&&Ze(this.#v,this.#c)}get_effect_pending(){return this.#m(),v(this.#v)}error(t){var r=this.#n.onerror;let n=this.#n.failed;if(this.#h||!r&&!n)throw t;this.#i&&(C(this.#i),this.#i=null),this.#a&&(C(this.#a),this.#a=null),this.#l&&(C(this.#l),this.#l=null),p&&(M(this.#r),Hn(),M(_t()));var i=!1,s=!1;const l=()=>{if(i){Bn();return}i=!0,s&&Vn(),G.ensure(),this.#c=0,this.#l!==null&&He(this.#l,()=>{this.#l=null}),this.#t=this.has_pending_snippet(),this.#i=this.#_(()=>(this.#h=!1,Y(()=>this.#o(this.#e)))),this.#d>0?this.#b():this.#t=!1};var a=g;try{O(null),s=!0,r?.(t,l),s=!1}catch(o){Fe(o,this.#s&&this.#s.parent)}finally{O(a)}n&&Ge(()=>{this.#l=this.#_(()=>{G.ensure(),this.#h=!0;try{return Y(()=>{n(this.#e,()=>t,()=>l)})}catch(o){return Fe(o,this.#s.parent),null}finally{this.#h=!1}})})}}function Zn(e,t,r){for(var n=[],i=t.length,s=0;s<i;s++)Yt(t[s].e,n,!0);Yr(n,()=>{var l=n.length===0&&r!==null;if(l){var a=r,o=a.parentNode;Or(o),o.append(a),e.items.clear(),X(e,t[0].prev,t[i-1].next)}for(var f=0;f<i;f++){var u=t[f];l||(e.items.delete(u.k),X(e,u.prev,u.next)),C(u.e,!l)}e.first===t[0]&&(e.first=t[0].prev)})}function $r(e,t,r,n,i,s=null){var l=e,a=new Map,o=null;p&&ze();var f=null,u=ii(()=>{var k=r();return Nt(k)?k:k==null?[]:Ct(k)}),d,c=!0;function h(){Qn(x,d,l,t,n),f!==null&&(d.length===0?(f.fragment?(l.before(f.fragment),f.fragment=null):Wt(f.effect),_.first=f.effect):He(f.effect,()=>{f=null}))}var _=Ut(()=>{d=v(u);var k=d.length;let B=!1;if(p){var N=ur(l)===ot;N!==(k===0)&&(l=_t(),M(l),fe(!1),B=!0)}for(var me=new Set,J=w,re=null,K=Dr(),ne=0;ne<k;ne+=1){p&&m.nodeType===De&&m.data===jt&&(l=m,B=!0,fe(!1));var ye=d[ne],ie=n(ye,ne),D=c?null:a.get(ie);D?(Ze(D.v,ye),D.i=ne,K&&J.skipped_effects.delete(D.e)):(D=ei(c?l:null,re,ye,ie,ne,i,t,r),c&&(D.o=!0,re===null?o=D:re.next=D,re=D),a.set(ie,D)),me.add(ie)}if(k===0&&s&&!f)if(c)f={fragment:null,effect:Y(()=>s(l))};else{var de=document.createDocumentFragment(),Ye=V();de.append(Ye),f={fragment:de,effect:Y(()=>s(Ye))}}if(p&&k>0&&M(_t()),!c)if(K){for(const[St,rr]of a)me.has(St)||J.skipped_effects.add(rr.e);J.oncommit(h),J.ondiscard(()=>{})}else h();B&&fe(!0),v(u)}),x={effect:_,items:a,first:o};c=!1,p&&(l=m)}function Qn(e,t,r,n,i){var s=t.length,l=e.items,a=e.first,o,f=null,u=[],d=[],c,h,_,x;for(x=0;x<s;x+=1){if(c=t[x],h=i(c,x),_=l.get(h),e.first??=_,!_.o){_.o=!0;var k=f?f.next:a;X(e,f,_),X(e,_,k),It(_,k,r),f=_,u=[],d=[],a=f.next;continue}if((_.e.f&I)!==0&&Wt(_.e),_!==a){if(o!==void 0&&o.has(_)){if(u.length<d.length){var B=d[0],N;f=B.prev;var me=u[0],J=u[u.length-1];for(N=0;N<u.length;N+=1)It(u[N],B,r);for(N=0;N<d.length;N+=1)o.delete(d[N]);X(e,me.prev,J.next),X(e,f,me),X(e,J,B),a=B,f=J,x-=1,u=[],d=[]}else o.delete(_),It(_,a,r),X(e,_.prev,_.next),X(e,_,f===null?e.first:f.next),X(e,f,_),f=_;continue}for(u=[],d=[];a!==null&&a.k!==h;)(a.e.f&I)===0&&(o??=new Set).add(a),d.push(a),a=a.next;if(a===null)continue;_=a}u.push(_),f=_,a=_.next}if(a!==null||o!==void 0){for(var re=o===void 0?[]:Ct(o);a!==null;)(a.e.f&I)===0&&re.push(a),a=a.next;var K=re.length;if(K>0){var ne=null;Zn(e,re,ne)}}}function ei(e,t,r,n,i,s,l,a){var o=(l&bn)!==0,f=(l&gn)===0,u=o?f?Sr(r,!1,!1):Te(r):r,d=(l&pn)===0?i:Te(i),c={i:d,v:u,k:n,a:null,e:null,o:!1,prev:t,next:null};try{if(e===null){var h=document.createDocumentFragment();h.append(e=V())}return c.e=Y(()=>s(e,u,d,a)),t!==null&&(t.next=c),c}finally{}}function It(e,t,r){for(var n=e.next?e.next.e.nodes_start:r,i=t?t.e.nodes_start:r,s=e.e.nodes_start;s!==null&&s!==n;){var l=Z(s);i.before(s),s=l}}function X(e,t,r){t===null?(e.first=r,e.effect.first=r&&r.e):(t.e.next&&(t.e.next.prev=null),t.next=r,t.e.next=r&&r.e),r===null?e.effect.last=t&&t.e:(r.e.prev&&(r.e.prev.next=null),r.prev=t,r.e.prev=t&&t.e)}function ti(e,t,r,n){const i=mt;if(r.length===0&&e.length===0){n(t.map(i));return}var s=w,l=y,a=ri();function o(){Promise.all(r.map(f=>ni(f))).then(f=>{a();try{n([...t.map(i),...f])}catch(u){(l.f&oe)===0&&Fe(u,l)}s?.deactivate(),gt()}).catch(f=>{Fe(f,l)})}e.length>0?Promise.all(e).then(()=>{a();try{return o()}finally{s?.deactivate(),gt()}}):o()}function ri(){var e=y,t=g,r=P,n=w;return function(s=!0){te(e),O(t),Pe(r),s&&n?.activate()}}function gt(){te(null),O(null),Pe(null)}function mt(e){var t=T|L,r=g!==null&&(g.f&T)!==0?g:null;return y!==null&&(y.f|=$e),{ctx:P,deps:null,effects:null,equals:cr,f:t,fn:e,reactions:null,rv:0,v:S,wv:0,parent:r??y,ac:null}}function ni(e,t){let r=y;r===null&&Cn();var n=r.b,i=void 0,s=Te(S),l=!g,a=new Map;return di(()=>{var o=lr();i=o.promise;try{Promise.resolve(e()).then(o.resolve,o.reject).then(()=>{f===w&&f.committed&&f.deactivate(),gt()})}catch(c){o.reject(c),gt()}var f=w;if(l){var u=!n.is_pending();n.update_pending_count(1),f.increment(u),a.get(f)?.reject(Oe),a.delete(f),a.set(f,o)}const d=(c,h=void 0)=>{if(f.activate(),h)h!==Oe&&(s.f|=he,Ze(s,h));else{(s.f&he)!==0&&(s.f^=he),Ze(s,c);for(const[_,x]of a){if(a.delete(_),_===f)break;x.reject(Oe)}}l&&(n.update_pending_count(-1),f.decrement(u))};o.promise.then(d,c=>d(null,c||"unknown"))}),qt(()=>{for(const o of a.values())o.reject(Oe)}),new Promise(o=>{function f(u){function d(){u===i?o(s):f(i)}u.then(d,d)}f(i)})}function Er(e){const t=mt(e);return Jr(t),t}function ii(e){const t=mt(e);return t.equals=dr,t}function kr(e){var t=e.effects;if(t!==null){e.effects=null;for(var r=0;r<t.length;r+=1)C(t[r])}}function si(e){for(var t=e.parent;t!==null;){if((t.f&T)===0)return(t.f&oe)===0?t:null;t=t.parent}return null}function Pt(e){var t,r=y;te(si(e));try{e.f&=~Ee,kr(e),t=en(e)}finally{te(r)}return t}function xr(e){var t=Pt(e);if(e.equals(t)||(w?.is_fork||(e.v=t),e.wv=Zr()),!je)if(H!==null)wt()&&H.set(e,t);else{var r=(e.f&z)===0?le:j;A(e,r)}}let Ft=new Set;const _e=new Map;let Tr=!1;function Te(e,t){var r={f:0,v:e,reactions:null,equals:cr,rv:0,wv:0};return r}function F(e,t){const r=Te(e);return Jr(r),r}function Sr(e,t=!1,r=!0){const n=Te(e);return t||(n.equals=dr),n}function $(e,t,r=!1){g!==null&&(!ee||(g.f&or)!==0)&&_r()&&(g.f&(T|se|Ot|or))!==0&&!ce?.includes(e)&&Fn();let n=r?Se(t):t;return Ze(e,n)}function Ze(e,t){if(!e.equals(t)){var r=e.v;je?_e.set(e,t):_e.set(e,r),e.v=t;var n=G.ensure();n.capture(e,r),(e.f&T)!==0&&((e.f&L)!==0&&Pt(e),A(e,(e.f&z)!==0?j:le)),e.wv=Zr(),jr(e,L),y!==null&&(y.f&j)!==0&&(y.f&(ae|ve))===0&&(W===null?_i([e]):W.push(e)),!n.is_fork&&Ft.size>0&&!Tr&&ai()}return t}function ai(){Tr=!1;var e=be;Et(!0);const t=Array.from(Ft);try{for(const r of t)(r.f&j)!==0&&A(r,le),tt(r)&&rt(r)}finally{Et(e)}Ft.clear()}function Qe(e){$(e,e.v+1)}function jr(e,t){var r=e.reactions;if(r!==null)for(var n=r.length,i=0;i<n;i++){var s=r[i],l=s.f,a=(l&L)===0;if(a&&A(s,t),(l&T)!==0){var o=s;H?.delete(o),(l&Ee)===0&&(l&z&&(s.f|=Ee),jr(o,le))}else a&&((l&se)!==0&&ue!==null&&ue.add(s),xe(s))}}function Se(e){if(typeof e!="object"||e===null||We in e)return e;const t=xn(e);if(t!==En&&t!==kn)return e;var r=new Map,n=Nt(e),i=F(0),s=Ae,l=a=>{if(Ae===s)return a();var o=g,f=Ae;O(null),Xr(s);var u=a();return O(o),Xr(f),u};return n&&r.set("length",F(e.length)),new Proxy(e,{defineProperty(a,o,f){(!("value"in f)||f.configurable===!1||f.enumerable===!1||f.writable===!1)&&In();var u=r.get(o);return u===void 0?u=l(()=>{var d=F(f.value);return r.set(o,d),d}):$(u,f.value,!0),!0},deleteProperty(a,o){var f=r.get(o);if(f===void 0){if(o in a){const u=l(()=>F(S));r.set(o,u),Qe(i)}}else $(f,S),Qe(i);return!0},get(a,o,f){if(o===We)return e;var u=r.get(o),d=o in a;if(u===void 0&&(!d||Le(a,o)?.writable)&&(u=l(()=>{var h=Se(d?a[o]:S),_=F(h);return _}),r.set(o,u)),u!==void 0){var c=v(u);return c===S?void 0:c}return Reflect.get(a,o,f)},getOwnPropertyDescriptor(a,o){var f=Reflect.getOwnPropertyDescriptor(a,o);if(f&&"value"in f){var u=r.get(o);u&&(f.value=v(u))}else if(f===void 0){var d=r.get(o),c=d?.v;if(d!==void 0&&c!==S)return{enumerable:!0,configurable:!0,value:c,writable:!0}}return f},has(a,o){if(o===We)return!0;var f=r.get(o),u=f!==void 0&&f.v!==S||Reflect.has(a,o);if(f!==void 0||y!==null&&(!u||Le(a,o)?.writable)){f===void 0&&(f=l(()=>{var c=u?Se(a[o]):S,h=F(c);return h}),r.set(o,f));var d=v(f);if(d===S)return!1}return u},set(a,o,f,u){var d=r.get(o),c=o in a;if(n&&o==="length")for(var h=f;h<d.v;h+=1){var _=r.get(h+"");_!==void 0?$(_,S):h in a&&(_=l(()=>F(S)),r.set(h+"",_))}if(d===void 0)(!c||Le(a,o)?.writable)&&(d=l(()=>F(void 0)),$(d,Se(f)),r.set(o,d));else{c=d.v!==S;var x=l(()=>Se(f));$(d,x)}var k=Reflect.getOwnPropertyDescriptor(a,o);if(k?.set&&k.set.call(u,f),!c){if(n&&typeof o=="string"){var B=r.get("length"),N=Number(o);Number.isInteger(N)&&N>=B.v&&$(B,N+1)}Qe(i)}return!0},ownKeys(a){v(i);var o=Reflect.ownKeys(a).filter(d=>{var c=r.get(d);return c===void 0||c.v!==S});for(var[f,u]of r)u.v!==S&&!(f in a)&&o.push(f);return o},setPrototypeOf(){Pn()}})}function Ar(e){try{if(e!==null&&typeof e=="object"&&We in e)return e[We]}catch{}return e}function li(e,t){return Object.is(Ar(e),Ar(t))}var Nr,Cr,Rr,Lr;function Vt(){if(Nr===void 0){Nr=window,Cr=/Firefox/.test(navigator.userAgent);var e=Element.prototype,t=Node.prototype,r=Text.prototype;Rr=Le(t,"firstChild").get,Lr=Le(t,"nextSibling").get,ar(e)&&(e.__click=void 0,e.__className=void 0,e.__attributes=null,e.__style=void 0,e.__e=void 0),ar(r)&&(r.__t=void 0)}}function V(e=""){return document.createTextNode(e)}function Ve(e){return Rr.call(e)}function Z(e){return Lr.call(e)}function qe(e,t){if(!p)return Ve(e);var r=Ve(m);if(r===null)r=m.appendChild(V());else if(t&&r.nodeType!==vt){var n=V();return r?.before(n),M(n),n}return M(r),r}function Mr(e,t=!1){if(!p){var r=Ve(e);return r instanceof Comment&&r.data===""?Z(r):r}if(t&&m?.nodeType!==vt){var n=V();return m?.before(n),M(n),n}return m}function Be(e,t=1,r=!1){let n=p?m:e;for(var i;t--;)i=n,n=Z(n);if(!p)return n;if(r&&n?.nodeType!==vt){var s=V();return n===null?i?.after(s):n.before(s),M(s),s}return M(n),n}function Or(e){e.textContent=""}function Dr(){return!1}let Ir=!1;function Pr(){Ir||(Ir=!0,document.addEventListener("reset",e=>{Promise.resolve().then(()=>{if(!e.defaultPrevented)for(const t of e.target.elements)t.__on_r?.()})},{capture:!0}))}function yt(e){var t=g,r=y;O(null),te(null);try{return e()}finally{O(t),te(r)}}function Fr(e,t,r,n=r){e.addEventListener(t,()=>yt(r));const i=e.__on_r;i?e.__on_r=()=>{i(),n(!0)}:e.__on_r=()=>n(!0),Pr()}function oi(e){y===null&&(g===null&&Mn(),Ln()),je&&Rn()}function fi(e,t){var r=t.last;r===null?t.last=t.first=e:(r.next=e,e.prev=r,t.last=e)}function Q(e,t,r){var n=y;n!==null&&(n.f&I)!==0&&(e|=I);var i={ctx:P,deps:null,nodes_start:null,nodes_end:null,f:e|L|z,first:null,fn:t,last:null,next:null,parent:n,b:n&&n.b,prev:null,teardown:null,transitions:null,wv:0,ac:null};if(r)try{rt(i),i.f|=dt}catch(a){throw C(i),a}else t!==null&&xe(i);var s=i;if(r&&s.deps===null&&s.teardown===null&&s.nodes_start===null&&s.first===s.last&&(s.f&$e)===0&&(s=s.first,(e&se)!==0&&(e&Me)!==0&&s!==null&&(s.f|=Me)),s!==null&&(s.parent=n,n!==null&&fi(s,n),g!==null&&(g.f&T)!==0&&(e&ve)===0)){var l=g;(l.effects??=[]).push(s)}return i}function wt(){return g!==null&&!ee}function qt(e){const t=Q(Lt,null,!1);return A(t,j),t.teardown=e,t}function Bt(e){oi();var t=y.f,r=!g&&(t&ae)!==0&&(t&dt)===0;if(r){var n=P;(n.e??=[]).push(e)}else return Vr(e)}function Vr(e){return Q(Rt|Sn,e,!1)}function ui(e){G.ensure();const t=Q(ve|$e,e,!0);return()=>{C(t)}}function ci(e){G.ensure();const t=Q(ve|$e,e,!0);return(r={})=>new Promise(n=>{r.outro?He(t,()=>{C(t),n(void 0)}):(C(t),n(void 0))})}function qr(e){return Q(Rt,e,!1)}function di(e){return Q(Ot|$e,e,!0)}function Ht(e,t=0){return Q(Lt|t,e,!0)}function $t(e,t=[],r=[],n=[]){ti(n,t,r,i=>{Q(Lt,()=>e(...i.map(v)),!0)})}function Ut(e,t=0){var r=Q(se|t,e,!0);return r}function Y(e){return Q(ae|$e,e,!0)}function Br(e){var t=e.teardown;if(t!==null){const r=je,n=g;Gr(!0),O(null);try{t.call(null)}finally{Gr(r),O(n)}}}function Hr(e,t=!1){var r=e.first;for(e.first=e.last=null;r!==null;){const i=r.ac;i!==null&&yt(()=>{i.abort(Oe)});var n=r.next;(r.f&ve)!==0?r.parent=null:C(r,t),r=n}}function vi(e){for(var t=e.first;t!==null;){var r=t.next;(t.f&ae)===0&&C(t),t=r}}function C(e,t=!0){var r=!1;(t||(e.f&fr)!==0)&&e.nodes_start!==null&&e.nodes_end!==null&&(hi(e.nodes_start,e.nodes_end),r=!0),Hr(e,t&&!r),kt(e,0),A(e,oe);var n=e.transitions;if(n!==null)for(const s of n)s.stop();Br(e);var i=e.parent;i!==null&&i.first!==null&&Ur(e),e.next=e.prev=e.teardown=e.ctx=e.deps=e.fn=e.nodes_start=e.nodes_end=e.ac=null}function hi(e,t){for(;e!==null;){var r=e===t?null:Z(e);e.remove(),e=r}}function Ur(e){var t=e.parent,r=e.prev,n=e.next;r!==null&&(r.next=n),n!==null&&(n.prev=r),t!==null&&(t.first===e&&(t.first=n),t.last===e&&(t.last=r))}function He(e,t,r=!0){var n=[];Yt(e,n,!0),Yr(n,()=>{r&&C(e),t&&t()})}function Yr(e,t){var r=e.length;if(r>0){var n=()=>--r||t();for(var i of e)i.out(n)}else t()}function Yt(e,t,r){if((e.f&I)===0){if(e.f^=I,e.transitions!==null)for(const l of e.transitions)(l.is_global||r)&&t.push(l);for(var n=e.first;n!==null;){var i=n.next,s=(n.f&Me)!==0||(n.f&ae)!==0&&(e.f&se)!==0;Yt(n,t,s?r:!1),n=i}}}function Wt(e){Wr(e,!0)}function Wr(e,t){if((e.f&I)!==0){e.f^=I,(e.f&j)===0&&(A(e,L),xe(e));for(var r=e.first;r!==null;){var n=r.next,i=(r.f&Me)!==0||(r.f&ae)!==0;Wr(r,i?t:!1),r=n}if(e.transitions!==null)for(const s of e.transitions)(s.is_global||t)&&s.in()}}function zr(e,t){for(var r=e.nodes_start,n=e.nodes_end;r!==null;){var i=r===n?null:Z(r);t.append(r),r=i}}let be=!1;function Et(e){be=e}let je=!1;function Gr(e){je=e}let g=null,ee=!1;function O(e){g=e}let y=null;function te(e){y=e}let ce=null;function Jr(e){g!==null&&(ce===null?ce=[e]:ce.push(e))}let R=null,q=0,W=null;function _i(e){W=e}let Kr=1,et=0,Ae=et;function Xr(e){Ae=e}function Zr(){return++Kr}function tt(e){var t=e.f;if((t&L)!==0)return!0;if(t&T&&(e.f&=~Ee),(t&le)!==0){var r=e.deps;if(r!==null)for(var n=r.length,i=0;i<n;i++){var s=r[i];if(tt(s)&&xr(s),s.wv>e.wv)return!0}(t&z)!==0&&H===null&&A(e,j)}return!1}function Qr(e,t,r=!0){var n=e.reactions;if(n!==null&&!ce?.includes(e))for(var i=0;i<n.length;i++){var s=n[i];(s.f&T)!==0?Qr(s,t,!1):t===s&&(r?A(s,L):(s.f&j)!==0&&A(s,le),xe(s))}}function en(e){var t=R,r=q,n=W,i=g,s=ce,l=P,a=ee,o=Ae,f=e.f;R=null,q=0,W=null,g=(f&(ae|ve))===0?e:null,ce=null,Pe(e.ctx),ee=!1,Ae=++et,e.ac!==null&&(yt(()=>{e.ac.abort(Oe)}),e.ac=null);try{e.f|=Mt;var u=e.fn,d=u(),c=e.deps;if(R!==null){var h;if(kt(e,q),c!==null&&q>0)for(c.length=q+R.length,h=0;h<R.length;h++)c[q+h]=R[h];else e.deps=c=R;if(be&&wt()&&(e.f&z)!==0)for(h=q;h<c.length;h++)(c[h].reactions??=[]).push(e)}else c!==null&&q<c.length&&(kt(e,q),c.length=q);if(_r()&&W!==null&&!ee&&c!==null&&(e.f&(T|le|L))===0)for(h=0;h<W.length;h++)Qr(W[h],e);return i!==null&&i!==e&&(et++,W!==null&&(n===null?n=W:n.push(...W))),(e.f&he)!==0&&(e.f^=he),d}catch(_){return pr(_)}finally{e.f^=Mt,R=t,q=r,W=n,g=i,ce=s,Pe(l),ee=a,Ae=o}}function bi(e,t){let r=t.reactions;if(r!==null){var n=$n.call(r,e);if(n!==-1){var i=r.length-1;i===0?r=t.reactions=null:(r[n]=r[i],r.pop())}}r===null&&(t.f&T)!==0&&(R===null||!R.includes(t))&&(A(t,le),(t.f&z)!==0&&(t.f^=z,t.f&=~Ee),kr(t),kt(t,0))}function kt(e,t){var r=e.deps;if(r!==null)for(var n=t;n<r.length;n++)bi(e,r[n])}function rt(e){var t=e.f;if((t&oe)===0){A(e,j);var r=y,n=be;y=e,be=!0;try{(t&se)!==0?vi(e):Hr(e),Br(e);var i=en(e);e.teardown=typeof i=="function"?i:null,e.wv=Kr;var s;At&&Yn&&(e.f&L)!==0&&e.deps}finally{be=n,y=r}}}async function pi(){await Promise.resolve(),Xe()}function v(e){var t=e.f,r=(t&T)!==0;if(g!==null&&!ee){var n=y!==null&&(y.f&oe)!==0;if(!n&&!ce?.includes(e)){var i=g.deps;if((g.f&Mt)!==0)e.rv<et&&(e.rv=et,R===null&&i!==null&&i[q]===e?q++:R===null?R=[e]:R.includes(e)||R.push(e));else{(g.deps??=[]).push(e);var s=e.reactions;s===null?e.reactions=[g]:s.includes(g)||s.push(g)}}}if(je){if(_e.has(e))return _e.get(e);if(r){var l=e,a=l.v;return((l.f&j)===0&&l.reactions!==null||rn(l))&&(a=Pt(l)),_e.set(l,a),a}}else r&&!H?.has(e)&&(l=e,tt(l)&&xr(l),be&&wt()&&(l.f&z)===0&&tn(l));if(H?.has(e))return H.get(e);if((e.f&he)!==0)throw e.v;return e.v}function tn(e){if(e.deps!==null){e.f^=z;for(const t of e.deps)(t.reactions??=[]).push(e),(t.f&T)!==0&&(t.f&z)===0&&tn(t)}}function rn(e){if(e.v===S)return!0;if(e.deps===null)return!1;for(const t of e.deps)if(_e.has(t)||(t.f&T)!==0&&rn(t))return!0;return!1}function zt(e){var t=ee;try{return ee=!0,e()}finally{ee=t}}const gi=-7169;function A(e,t){e.f=e.f&gi|t}const nn=new Set,Gt=new Set;function mi(e,t,r,n={}){function i(s){if(n.capture||nt.call(t,s),!s.cancelBubble)return yt(()=>r?.call(this,s))}return e.startsWith("pointer")||e.startsWith("touch")||e==="wheel"?Ge(()=>{t.addEventListener(e,i,n)}):t.addEventListener(e,i,n),i}function Jt(e,t,r,n,i){var s={capture:n,passive:i},l=mi(e,t,r,s);(t===document.body||t===window||t===document||t instanceof HTMLMediaElement)&&qt(()=>{t.removeEventListener(e,l,s)})}function yi(e){for(var t=0;t<e.length;t++)nn.add(e[t]);for(var r of Gt)r(e)}let sn=null;function nt(e){var t=this,r=t.ownerDocument,n=e.type,i=e.composedPath?.()||[],s=i[0]||e.target;sn=e;var l=0,a=sn===e&&e.__root;if(a){var o=i.indexOf(a);if(o!==-1&&(t===document||t===window)){e.__root=t;return}var f=i.indexOf(t);if(f===-1)return;o<=f&&(l=o)}if(s=i[l]||e.target,s!==t){ut(e,"currentTarget",{configurable:!0,get(){return s||r}});var u=g,d=y;O(null),te(null);try{for(var c,h=[];s!==null;){var _=s.assignedSlot||s.parentNode||s.host||null;try{var x=s["__"+n];x!=null&&(!s.disabled||e.target===s)&&x.call(s,e)}catch(k){c?h.push(k):c=k}if(e.cancelBubble||_===t||_===null)break;s=_}if(c){for(let k of h)queueMicrotask(()=>{throw k});throw c}}finally{e.__root=t,delete e.currentTarget,O(u),te(d)}}}function wi(e){var t=document.createElement("template");return t.innerHTML=e.replaceAll("<!>","<!---->"),t.content}function pe(e,t){var r=y;r.nodes_start===null&&(r.nodes_start=e,r.nodes_end=t)}function it(e,t){var r=(t&mn)!==0,n=(t&yn)!==0,i,s=!e.startsWith("<!>");return()=>{if(p)return pe(m,null),m;i===void 0&&(i=wi(s?e:"<!>"+e),r||(i=Ve(i)));var l=n||Cr?document.importNode(i,!0):i.cloneNode(!0);if(r){var a=Ve(l),o=l.lastChild;pe(a,o)}else pe(l,l);return l}}function $i(e=""){if(!p){var t=V(e+"");return pe(t,t),t}var r=m;return r.nodeType!==vt&&(r.before(r=V()),M(r)),pe(r,r),r}function Ei(){if(p)return pe(m,null),m;var e=document.createDocumentFragment(),t=document.createComment(""),r=V();return e.append(t,r),pe(t,r),e}function ge(e,t){if(p){var r=y;((r.f&dt)===0||r.nodes_end===null)&&(r.nodes_end=m),ze();return}e!==null&&e.before(t)}const ki=["touchstart","touchmove"];function xi(e){return ki.includes(e)}function Kt(e,t){var r=t==null?"":typeof t=="object"?t+"":t;r!==(e.__t??=e.nodeValue)&&(e.__t=r,e.nodeValue=r+"")}function an(e,t){return ln(e,t)}function Ti(e,t){Vt(),t.intro=t.intro??!1;const r=t.target,n=p,i=m;try{for(var s=Ve(r);s&&(s.nodeType!==De||s.data!==sr);)s=Z(s);if(!s)throw Re;fe(!0),M(s);const l=ln(e,{...t,anchor:s});return fe(!1),l}catch(l){if(l instanceof Error&&l.message.split(`
2
+ `).some(a=>a.startsWith("https://svelte.dev/e/")))throw l;return l!==Re&&console.warn("Failed to hydrate: ",l),t.recover===!1&&Dn(),Vt(),Or(r),fe(!1),an(e,t)}finally{fe(n),M(i)}}const Ue=new Map;function ln(e,{target:t,anchor:r,props:n={},events:i,context:s,intro:l=!0}){Vt();var a=new Set,o=d=>{for(var c=0;c<d.length;c++){var h=d[c];if(!a.has(h)){a.add(h);var _=xi(h);t.addEventListener(h,nt,{passive:_});var x=Ue.get(h);x===void 0?(document.addEventListener(h,nt,{passive:_}),Ue.set(h,1)):Ue.set(h,x+1)}}};o(Ct(nn)),Gt.add(o);var f=void 0,u=ci(()=>{var d=r??t.appendChild(V());return Kn(d,{pending:()=>{}},c=>{if(s){vr({});var h=P;h.c=s}if(i&&(n.$$events=i),p&&pe(c,null),f=e(c,n)||{},p&&(y.nodes_end=m,m===null||m.nodeType!==De||m.data!==jt))throw ht(),Re;s&&hr()}),()=>{for(var c of a){t.removeEventListener(c,nt);var h=Ue.get(c);--h===0?(document.removeEventListener(c,nt),Ue.delete(c)):Ue.set(c,h)}Gt.delete(o),d!==r&&d.parentNode?.removeChild(d)}});return Xt.set(f,u),f}let Xt=new WeakMap;function Si(e,t){const r=Xt.get(e);return r?(Xt.delete(e),r(t)):Promise.resolve()}class ji{anchor;#t=new Map;#e=new Map;#r=new Map;#n=new Set;#o=!0;constructor(t,r=!0){this.anchor=t,this.#o=r}#s=()=>{var t=w;if(this.#t.has(t)){var r=this.#t.get(t),n=this.#e.get(r);if(n)Wt(n),this.#n.delete(r);else{var i=this.#r.get(r);i&&(this.#e.set(r,i.effect),this.#r.delete(r),i.fragment.lastChild.remove(),this.anchor.before(i.fragment),n=i.effect)}for(const[s,l]of this.#t){if(this.#t.delete(s),s===t)break;const a=this.#r.get(l);a&&(C(a.effect),this.#r.delete(l))}for(const[s,l]of this.#e){if(s===r||this.#n.has(s))continue;const a=()=>{if(Array.from(this.#t.values()).includes(s)){var f=document.createDocumentFragment();zr(l,f),f.append(V()),this.#r.set(s,{effect:l,fragment:f})}else C(l);this.#n.delete(s),this.#e.delete(s)};this.#o||!n?(this.#n.add(s),He(l,a,!1)):a()}}};#i=t=>{this.#t.delete(t);const r=Array.from(this.#t.values());for(const[n,i]of this.#r)r.includes(n)||(C(i.effect),this.#r.delete(n))};ensure(t,r){var n=w,i=Dr();if(r&&!this.#e.has(t)&&!this.#r.has(t))if(i){var s=document.createDocumentFragment(),l=V();s.append(l),this.#r.set(t,{effect:Y(()=>r(l)),fragment:s})}else this.#e.set(t,Y(()=>r(this.anchor)));if(this.#t.set(n,t),i){for(const[a,o]of this.#e)a===t?n.skipped_effects.delete(o):n.skipped_effects.add(o);for(const[a,o]of this.#r)a===t?n.skipped_effects.delete(o.effect):n.skipped_effects.add(o.effect);n.oncommit(this.#s),n.ondiscard(this.#i)}else p&&(this.anchor=m),this.#s()}}function Ai(e){P===null&&Nn(),Bt(()=>{const t=zt(e);if(typeof t=="function")return t})}function Zt(e,t,r=!1){p&&ze();var n=new ji(e),i=r?Me:0;function s(l,a){if(p){const f=ur(e)===ot;if(l===f){var o=_t();M(o),n.anchor=o,fe(!1),n.ensure(l,a),fe(!0);return}}n.ensure(l,a)}Ut(()=>{var l=!1;t((a,o=!0)=>{l=!0,s(o,a)}),l||s(!1,null)},i)}function Ni(e,t,r,n,i){p&&ze();var s=t.$$slots?.[r],l=!1;s===!0&&(s=t[r],l=!0),s===void 0?i!==null&&i(e):s(e,l?()=>n:n)}function Ci(e,t){qr(()=>{var r=e.getRootNode(),n=r.host?r:r.head??r.ownerDocument.head;if(!n.querySelector("#"+t.hash)){const i=document.createElement("style");i.id=t.hash,i.textContent=t.code,n.appendChild(i)}})}function Ri(e,t,r){var n=e==null?"":""+e;return n=n?n+" "+t:t,n===""?null:n}function Li(e,t){return e==null?null:String(e)}function on(e,t,r,n,i,s){var l=e.__className;if(p||l!==r||l===void 0){var a=Ri(r,n);(!p||a!==e.getAttribute("class"))&&(a==null?e.removeAttribute("class"):e.className=a),e.__className=r}return s}function xt(e,t,r,n){var i=e.__style;if(p||i!==t){var s=Li(t);(!p||s!==e.getAttribute("style"))&&(s==null?e.removeAttribute("style"):e.style.cssText=s),e.__style=t}return n}function fn(e,t,r=!1){if(e.multiple){if(t==null)return;if(!Nt(t))return qn();for(var n of e.options)n.selected=t.includes(st(n));return}for(n of e.options){var i=st(n);if(li(i,t)){n.selected=!0;return}}(!r||t!==void 0)&&(e.selectedIndex=-1)}function Mi(e){var t=new MutationObserver(()=>{fn(e,e.__value)});t.observe(e,{childList:!0,subtree:!0,attributes:!0,attributeFilter:["value"]}),qt(()=>{t.disconnect()})}function Oi(e,t,r=t){var n=new WeakSet,i=!0;Fr(e,"change",s=>{var l=s?"[selected]":":checked",a;if(e.multiple)a=[].map.call(e.querySelectorAll(l),st);else{var o=e.querySelector(l)??e.querySelector("option:not([disabled])");a=o&&st(o)}r(a),w!==null&&n.add(w)}),qr(()=>{var s=t();if(e===document.activeElement){var l=Je??w;if(n.has(l))return}if(fn(e,s,i),i&&s===void 0){var a=e.querySelector(":checked");a!==null&&(s=st(a),r(s))}e.__value=s,i=!1}),Mi(e)}function st(e){return"__value"in e?e.__value:e.value}const Di=Symbol("is custom element"),Ii=Symbol("is html");function Pi(e){if(p){var t=!1,r=()=>{if(!t){if(t=!0,e.hasAttribute("value")){var n=e.value;un(e,"value",null),e.value=n}if(e.hasAttribute("checked")){var i=e.checked;un(e,"checked",null),e.checked=i}}};e.__on_r=r,Ge(r),Pr()}}function un(e,t,r,n){var i=Fi(e);p&&(i[t]=e.getAttribute(t),t==="src"||t==="srcset"||t==="href"&&e.nodeName==="LINK")||i[t]!==(i[t]=r)&&(t==="loading"&&(e[An]=r),e.removeAttribute(t))}function Fi(e){return e.__attributes??={[Di]:e.nodeName.includes("-"),[Ii]:e.namespaceURI===wn}}function Vi(e,t,r=t){var n=new WeakSet;Fr(e,"input",async i=>{var s=i?e.defaultValue:e.value;if(s=Qt(e)?er(s):s,r(s),w!==null&&n.add(w),await pi(),s!==(s=t())){var l=e.selectionStart,a=e.selectionEnd,o=e.value.length;if(e.value=s??"",a!==null){var f=e.value.length;l===a&&a===o&&f>o?(e.selectionStart=f,e.selectionEnd=f):(e.selectionStart=l,e.selectionEnd=Math.min(a,f))}}}),(p&&e.defaultValue!==e.value||zt(t)==null&&e.value)&&(r(Qt(e)?er(e.value):e.value),w!==null&&n.add(w)),Ht(()=>{var i=t();if(e===document.activeElement){var s=Je??w;if(n.has(s))return}Qt(e)&&i===er(e.value)||e.type==="date"&&!i&&!e.value||i!==e.value&&(e.value=i??"")})}function Qt(e){var t=e.type;return t==="number"||t==="range"}function er(e){return e===""?null:+e}function tr(e,t,r,n){var i=n,s=!0,l=()=>(s&&(s=!1,i=n),i),a;a=e[t],a===void 0&&n!==void 0&&(a=l());var o;o=()=>{var c=e[t];return c===void 0?l():(s=!0,c)};var f=!1,u=mt(()=>(f=!1,o())),d=y;return(function(c,h){if(arguments.length>0){const _=h?v(u):c;return $(u,_),f=!0,i!==void 0&&(i=_),c}return je&&f||(d.f&oe)!==0?u.v:v(u)})}function qi(e){return new Bi(e)}class Bi{#t;#e;constructor(t){var r=new Map,n=(s,l)=>{var a=Sr(l,!1,!1);return r.set(s,a),a};const i=new Proxy({...t.props||{},$$events:{}},{get(s,l){return v(r.get(l)??n(l,Reflect.get(s,l)))},has(s,l){return l===jn?!0:(v(r.get(l)??n(l,Reflect.get(s,l))),Reflect.has(s,l))},set(s,l,a){return $(r.get(l)??n(l,a),a),Reflect.set(s,l,a)}});this.#e=(t.hydrate?Ti:an)(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)&&Xe(),this.#t=i.$$events;for(const s of Object.keys(this.#e))s==="$set"||s==="$destroy"||s==="$on"||ut(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=()=>{Si(this.#e)}}$set(t){this.#e.$set(t)}$on(t,r){this.#t[t]=this.#t[t]||[];const n=(...i)=>r.call(this,...i);return this.#t[t].push(n),()=>{this.#t[t]=this.#t[t].filter(i=>i!==n)}}$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,r){super(),this.$$ctor=e,this.$$s=t,r&&this.attachShadow({mode:"open"})}addEventListener(e,t,r){if(this.$$l[e]=this.$$l[e]||[],this.$$l[e].push(t),this.$$c){const n=this.$$c.$on(e,t);this.$$l_u.set(t,n)}super.addEventListener(e,t,r)}removeEventListener(e,t,r){if(super.removeEventListener(e,t,r),this.$$c){const n=this.$$l_u.get(t);n&&(n(),this.$$l_u.delete(t))}}async connectedCallback(){if(this.$$cn=!0,!this.$$c){let e=function(n){return i=>{const s=document.createElement("slot");n!=="default"&&(s.name=n),ge(i,s)}};if(await Promise.resolve(),!this.$$cn||this.$$c)return;const t={},r=Hi(this);for(const n of this.$$s)n in r&&(n==="default"&&!this.$$d.children?(this.$$d.children=e(n),t.default=!0):t[n]=e(n));for(const n of this.attributes){const i=this.$$g_p(n.name);i in this.$$d||(this.$$d[i]=Tt(i,n.value,this.$$p_d,"toProp"))}for(const n in this.$$p_d)!(n in this.$$d)&&this[n]!==void 0&&(this.$$d[n]=this[n],delete this[n]);this.$$c=qi({component:this.$$ctor,target:this.shadowRoot||this,props:{...this.$$d,$$slots:t,$$host:this}}),this.$$me=ui(()=>{Ht(()=>{this.$$r=!0;for(const n of ft(this.$$c)){if(!this.$$p_d[n]?.reflect)continue;this.$$d[n]=this.$$c[n];const i=Tt(n,this.$$d[n],this.$$p_d,"toAttribute");i==null?this.removeAttribute(this.$$p_d[n].attribute||n):this.setAttribute(this.$$p_d[n].attribute||n,i)}this.$$r=!1})});for(const n in this.$$l)for(const i of this.$$l[n]){const s=this.$$c.$on(n,i);this.$$l_u.set(i,s)}this.$$l={}}}attributeChangedCallback(e,t,r){this.$$r||(e=this.$$g_p(e),this.$$d[e]=Tt(e,r,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 ft(this.$$p_d).find(t=>this.$$p_d[t].attribute===e||!this.$$p_d[t].attribute&&t.toLowerCase()===e)||e}});function Tt(e,t,r,n){const i=r[e]?.type;if(t=i==="Boolean"&&typeof t!="boolean"?t!=null:t,!n||!r[e])return t;if(n==="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 Hi(e){const t={};return e.childNodes.forEach(r=>{t[r.slot||"default"]=!0}),t}function Ui(e,t,r,n,i,s){let l=class extends cn{constructor(){super(e,r,i),this.$$p_d=t}static get observedAttributes(){return ft(t).map(a=>(t[a].attribute||a).toLowerCase())}};return ft(t).forEach(a=>{ut(l.prototype,a,{get(){return this.$$c&&a in this.$$c?this.$$c[a]:this.$$d[a]},set(o){o=Tt(a,o,t),this.$$d[a]=o;var f=this.$$c;if(f){var u=Le(f,a)?.get;u?f[a]=o:f.$set({[a]:o})}}})}),n.forEach(a=>{ut(l.prototype,a,{get(){return this.$$c?.[a]}})}),e.element=l,l}var Ne={},dn;function Yi(){if(dn)return Ne;dn=1,Object.defineProperty(Ne,"__esModule",{value:!0}),Ne.LanguageTranslator=void 0,Ne.getChildStyleToPass=e,Ne.addComponent=t;function e(n,i){var s,l,a="";try{if(n&&i?.length&&(!((s=Object.keys(n))===null||s===void 0)&&s.length)&&(!((l=i?.filter(function(c){return Object.keys(n).includes(c.name)}))===null||l===void 0)&&l.length))for(var o=function(c){var h=i?.filter(function(_){return _.name===c&&_.defaultValue!==n[c]});h&&(a+="".concat(c,":").concat(n[c],";"))},f=0,u=Object.keys(n);f<u.length;f++){var d=u[f];o(d)}}catch(c){console.error("error getting child style to pass",c)}finally{return a}}function t(n){var i,s=((i=n?.repoName.split("/"))===null||i===void 0?void 0:i[1])||n?.repoName;if(!s)throw new Error("wrong componentPath "+n?.repoName);if(!n?.version)throw new Error("wrong version "+n?.version);var l=n?.iifePath||"main.iife.js";if(!document.getElementById(s+"-script"))try{var a=document.createElement("script");if(a.id=s+"-script",a.src="https://cdn.jsdelivr.net/npm/".concat(n.repoName,"@").concat(n.version,"/").concat(l),n?.local)a.src="".concat(n.local);else if(location.href.includes("localhost:6006")){var o=s.split("-")[0];a.src="http://localhost:6006/webcomponents/".concat(s.replace(o+"-",""),"/").concat(l)}document.head.appendChild(a)}catch(f){console.warn(f)}}var r=(function(){function n(i){if(this.lang="",!i?.dictionary)throw new Error("no dictionary provided");this.dictionary=i.dictionary,this.setLang(i?.lang)}return n.prototype.setLang=function(i){i||(i=n.getDefaultLang()),this.lang=i},n.prototype.translateWord=function(i,s){return n.getDictionaryWord(i,this.dictionary,s||this.lang)},n.prototype.translateDate=function(i,s,l){return n.formatDate(i,s,l||this.lang)},n.getDefaultLang=function(){var i,s,l,a="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)&&(a=navigator.languages[0].split("-")[0].toLowerCase()),a},n.getDictionaryWord=function(i,s,l){var a;if(!i)throw new Error("no wordKey provided");if(!s)throw new Error("no dictionary provided");if(l&&(!((a=s[l])===null||a===void 0)&&a[i]))return s[l][i];var o="",f=n.getDefaultLang();if(!l||f!==l){var u=s?.[f];u?.[i]&&(o=u[i])}return o},n.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 a=new Intl.DateTimeFormat(l||n.getDefaultLang(),s);return a.format(i)},n})();return Ne.LanguageTranslator=r,Ne}Yi();var Wi=it('<button class="remove-tag svelte-jyvf24" type="button" aria-label="remove tag"><span class="circle svelte-jyvf24">x</span></button>'),zi=it("<span> <!></span>"),Gi=it('<option class="svelte-jyvf24"> </option>'),Ji=it('<option class="svelte-jyvf24">New Tag</option>'),Ki=it('<!> <button type="button"><!></button> <span class="svelte-jyvf24"><input id="input-text-add" class="input-val svelte-jyvf24" type="text"/></span> <span class="svelte-jyvf24"><select id="input-select-add" class="input-val svelte-jyvf24"><option disabled selected class="svelte-jyvf24">Select...</option><!><!></select></span>',1);const Xi={hash:"svelte-jyvf24",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
@@ -77,5 +77,5 @@ select.svelte-jyvf24 {text-transform:none;}select.svelte-jyvf24 {word-wrap:norma
77
77
  }
78
78
  @media (min-width: 1400px) {
79
79
  }:host {font-family:"Roboto", sans-serif;}.remove-tag.svelte-jyvf24 {background-color:transparent;border:none;color:#000;cursor:pointer;padding:0px 2px 0px 4px;}.tags.svelte-jyvf24 {margin:auto 2px auto 2px;border:none;}.circle.svelte-jyvf24 {width:1em;display:inline-block;height:1em;border-radius:50%;opacity:0.6;background-color:white;}.input-val.svelte-jyvf24 {margin:2px 0px 0px 0px;height:18px;
80
- /* line-height: 18px; */vertical-align:middle;width:80px;}`};function dn(e,t){dr(t,!0),Ci(e,Xi);let r=Qt(t,"schemaentry",7,void 0),n=Qt(t,"show_validation",7,"no"),i=Qt(t,"id",7,void 0);function s(b,$){t.$$host.dispatchEvent(new CustomEvent(b,{detail:$}))}let l=$r(()=>{if(r()&&typeof r()=="object")if(r().required){if(v(a)?.length)return!0}else return!0;else return!1});Te({});let a=F(Te([])),o=F("off"),f=F(""),u=$r(()=>!!(typeof r()=="object"&&r()?.params?.availableTags?.length||r()?.params?.freeTag)),d=F("");function c(b){if(console.log("closeAddingInput",b.target.closest("input")),v(o)!=="input"||b.target.closest("input")||b.target.closest("hb-input-array-tags"))return console.log("not closing adding input");k()}Ai(()=>(window.addEventListener("click",c),()=>{console.log("unmounting input-array-tags"),window.removeEventListener("click",c)})),qt(()=>{if(typeof r()=="string")try{r(JSON.parse(r())),r()?.value&&E(a,r()?.value,!0)}catch(b){console.error("error parsing JSON for schemaentry hb-input-array-objects",b)}console.log(v(l),v(a),"validinput4arrayobjects")}),qt(()=>{s("setVal",{value:v(a),valid:v(l),id:i()})});function h(){v(u)&&(r()?.params?.availableTags?.length?(E(o,"select"),_("input-select-add")):E(o,"input"),console.log("addTag",v(o)))}function _(b){setTimeout(()=>{const $=t.$$host?.shadowRoot?.getElementById(b);console.log("inputElement",$),$&&(console.log("focusing input element",$),$.value="",$.blur(),$.focus())},100)}function k(){if(console.log("addTagInput",v(d)),!(!r()?.params||!v(d)||!v(u))){if(v(a)?.find(b=>b.id===v(d)))return console.log("tag already exists");v(a).push({label:v(d),id:v(d)}),E(d,""),E(o,"off"),console.log("adding tag",v(a))}}function x(){if(console.log("addTagSelect",v(f)),!(!r()?.params||!v(f)||!v(u))){if(v(a)?.find(b=>b.id===v(f)))return console.log("tag already exists");if(v(f)==="_custom")E(o,"input"),_("input-text-add");else{const b=r()?.params?.availableTags?.find($=>$.id===v(f));b&&(!v(a)||v(a)?.indexOf(b)===-1)&&(E(a,[...v(a)||[],b],!0),E(f,""),E(o,"off"),console.log("adding tag",v(a)))}}}function B(b){E(a,v(a)?.filter?.($=>$.id!==b),!0),console.log("removing tag",v(a))}var N={get schemaentry(){return r()},set schemaentry(b=void 0){r(b),Je()},get show_validation(){return n()},set show_validation(b="no"){n(b),Je()},get id(){return i()},set id(b=void 0){i(b),Je()}},ge=Ki(),J=Lr(ge);{var re=b=>{var $=Ei(),Ce=Lr($);wr(Ce,17,()=>v(a),at=>at.id,(at,ye)=>{var lt=zi(),vn=qe(lt),Zi=Ze(vn);{var Qi=rr=>{var hn=Wi();hn.__click=()=>B(v(ye).id),pe(rr,hn)};Kt(Zi,rr=>{r()?.params?.allowRemove&&rr(Qi)})}Ie(lt),$t(()=>{ln(lt,1,`badge rounded-pill ${r()?.params?.colorVarName||v(ye).colorVarName?"":"text-bg-secondary"} tags`,"svelte-jyvf24"),kt(lt,r()?.params?.colorVarName||v(ye).colorVarName?`background-color: var(${v(ye).colorVarName||r()?.params?.colorVarName});`:""),Gt(vn,`${v(ye).label??""} `)}),pe(at,lt)}),pe(b,$)};Kt(J,b=>{v(a)?.length&&b(re)})}var K=Ze(J,2);K.__click=h;var ne=qe(K);Ni(ne,t,"add-tag-label",{},b=>{var $=$i();$t(()=>Gt($,r()?.params?.addTagLabel?r().params.addTagLabel:"+")),pe(b,$)}),Ie(K);var me=Ze(K,2),ce=qe(me);Pi(ce),ce.__keydown=b=>{(b.key==="Escape"||b.key==="Esc")&&(console.log("escape"),E(d,""),E(o,"off"))},Ie(me);var D=Ze(me,2),Ne=qe(D);Ne.__change=b=>{console.log("onchange",v(f)),x()};var st=qe(Ne);wr(st,17,()=>r()?.params?.availableTags,b=>b.id,(b,$)=>{var Ce=Gi(),at=qe(Ce,!0);Ie(Ce);var ye={};$t(()=>{Gt(at,v($).label),ye!==(ye=v($).id)&&(Ce.value=(Ce.__value=v($).id)??"")}),pe(b,Ce)});var er=Ze(st);{var tr=b=>{var $=Ji();$.value=$.__value="_custom",pe(b,$)};Kt(er,b=>{r()?.params?.freeTag&&b(tr)})}return Ie(Ne),Ie(D),$t(()=>{kt(K,`${v(u)&&v(o)==="off"?"display:inline-block;":"display:none;"}${r()?.params?.colorVarName?`background-color: var(${r()?.params?.colorVarName});`:""}`),ln(K,1,`badge rounded-pill ${r()?.params?.colorVarName?"":"text-bg-secondary"} tags`,"svelte-jyvf24"),kt(me,v(u)&&v(o)==="input"?"display:inline-block;":"display:none;"),kt(D,v(u)&&v(o)==="select"?"display:inline-block;":"display:none;")}),mi("keypress",ce,b=>{b.key==="Enter"&&k()}),Vi(ce,()=>v(d),b=>E(d,b)),Oi(Ne,()=>v(f),b=>E(f,b)),pe(e,ge),vr(N)}yi(["click","keydown","change"]),customElements.define("hb-input-array-tags",Ui(dn,{schemaentry:{},show_validation:{},id:{}},["add-tag-label"],[],!0)),nr.Component=dn,Object.defineProperty(nr,Symbol.toStringTag,{value:"Module"})})(this["input-array-tags"]=this["input-array-tags"]||{});
80
+ /* line-height: 18px; */vertical-align:middle;width:80px;}`};function vn(e,t){vr(t,!0),Ci(e,Xi);let r=tr(t,"schemaentry",7,void 0),n=tr(t,"show_validation",7,"no"),i=tr(t,"id",7,void 0);function s(b,E){t.$$host.dispatchEvent(new CustomEvent(b,{detail:E}))}let l=Er(()=>{if(r()&&typeof r()=="object")if(r().required){if(v(a)?.length)return!0}else return!0;else return!1});Se({});let a=F(Se([])),o=F("off"),f=F(""),u=Er(()=>!!(typeof r()=="object"&&r()?.params?.availableTags?.length||r()?.params?.freeTag)),d=F("");function c(b){if(console.log("closeAddingInput",b.target.closest("input")),v(o)!=="input"||b.target.closest("input")||b.target.closest("hb-input-array-tags"))return console.log("not closing adding input");x()}Ai(()=>(window.addEventListener("click",c),()=>{console.log("unmounting input-array-tags"),window.removeEventListener("click",c)})),Bt(()=>{if(typeof r()=="string")try{r(JSON.parse(r())),r()?.value&&$(a,r()?.value,!0)}catch(b){console.error("error parsing JSON for schemaentry hb-input-array-objects",b)}console.log(v(l),v(a),"validinput4arrayobjects")}),Bt(()=>{s("setVal",{value:v(a),valid:v(l),id:i()})});function h(){v(u)&&(r()?.params?.availableTags?.length?($(o,"select"),_("input-select-add")):$(o,"input"),console.log("addTag",v(o)))}function _(b){setTimeout(()=>{const E=t.$$host?.shadowRoot?.getElementById(b);console.log("inputElement",E),E&&(console.log("focusing input element",E),E.value="",E.blur(),E.focus())},100)}function x(){if(console.log("addTagInput",v(d)),!(!r()?.params||!v(d)||!v(u))){if(v(a)?.find(b=>b.id===v(d)))return console.log("tag already exists");v(a).push({label:v(d),id:v(d)}),$(d,""),$(o,"off"),console.log("adding tag",v(a))}}function k(){if(console.log("addTagSelect",v(f)),!(!r()?.params||!v(f)||!v(u))){if(v(a)?.find(b=>b.id===v(f)))return console.log("tag already exists");if(v(f)==="_custom")$(o,"input"),_("input-text-add");else{const b=r()?.params?.availableTags?.find(E=>E.id===v(f));b&&(!v(a)||v(a)?.indexOf(b)===-1)&&($(a,[...v(a)||[],b],!0),$(f,""),$(o,"off"),console.log("adding tag",v(a)))}}}function B(b){$(a,v(a)?.filter?.(E=>E.id!==b),!0),console.log("removing tag",v(a))}var N={get schemaentry(){return r()},set schemaentry(b=void 0){r(b),Xe()},get show_validation(){return n()},set show_validation(b="no"){n(b),Xe()},get id(){return i()},set id(b=void 0){i(b),Xe()}},me=Ki(),J=Mr(me);{var re=b=>{var E=Ei(),Ce=Mr(E);$r(Ce,17,()=>v(a),at=>at.id,(at,we)=>{var lt=zi(),hn=qe(lt),Qi=Be(hn);{var es=nr=>{var _n=Wi();_n.__click=()=>B(v(we).id),ge(nr,_n)};Zt(Qi,nr=>{r()?.params?.allowRemove&&nr(es)})}Ie(lt),$t(()=>{on(lt,1,`badge rounded-pill ${r()?.params?.colorVarName||v(we).colorVarName?"":"text-bg-secondary"} tags`,"svelte-jyvf24"),xt(lt,r()?.params?.colorVarName||v(we).colorVarName?`background-color: var(${v(we).colorVarName||r()?.params?.colorVarName});`:""),Kt(hn,`${v(we).label??""} `)}),ge(at,lt)}),ge(b,E)};Zt(J,b=>{v(a)?.length&&b(re)})}var K=Be(J,2);K.__click=h;var ne=qe(K);Ni(ne,t,"add-tag-label",{},b=>{var E=$i();$t(()=>Kt(E,r()?.params?.addTagLabel?r().params.addTagLabel:"+")),ge(b,E)}),Ie(K);var ye=Be(K,2),ie=qe(ye);Pi(ie),ie.__keydown=b=>{(b.key==="Escape"||b.key==="Esc")&&(console.log("escape"),$(d,""),$(o,"off"))},Ie(ye);var D=Be(ye,2),de=qe(D);de.__keydown=b=>{(b.key==="Escape"||b.key==="Esc")&&($(f,""),$(o,"off"))},de.__change=b=>{console.log("onchange",v(f)),k()};var Ye=qe(de);Ye.value=Ye.__value="";var St=Be(Ye);$r(St,17,()=>r()?.params?.availableTags,b=>b.id,(b,E)=>{var Ce=Gi(),at=qe(Ce,!0);Ie(Ce);var we={};$t(()=>{Kt(at,v(E).label),we!==(we=v(E).id)&&(Ce.value=(Ce.__value=v(E).id)??"")}),ge(b,Ce)});var rr=Be(St);{var Zi=b=>{var E=Ji();E.value=E.__value="_custom",ge(b,E)};Zt(rr,b=>{r()?.params?.freeTag&&b(Zi)})}return Ie(de),Ie(D),$t(()=>{xt(K,`${v(u)&&v(o)==="off"?"display:inline-block;":"display:none;"}${r()?.params?.colorVarName?`background-color: var(${r()?.params?.colorVarName});`:""}`),on(K,1,`badge rounded-pill ${r()?.params?.colorVarName?"":"text-bg-secondary"} tags`,"svelte-jyvf24"),xt(ye,v(u)&&v(o)==="input"?"display:inline-block;":"display:none;"),xt(D,v(u)&&v(o)==="select"?"display:inline-block;":"display:none;")}),Jt("blur",ie,()=>{setTimeout(()=>{$(o,"off"),$(d,"")},100)}),Jt("keypress",ie,b=>{b.key==="Enter"&&x()}),Vi(ie,()=>v(d),b=>$(d,b)),Jt("blur",de,()=>{setTimeout(()=>{$(o,"off"),$(f,"")},100)}),Oi(de,()=>v(f),b=>$(f,b)),ge(e,me),hr(N)}yi(["click","keydown","change"]),customElements.define("hb-input-array-tags",Ui(vn,{schemaentry:{},show_validation:{},id:{}},["add-tag-label"],[],!0)),ir.Component=vn,Object.defineProperty(ir,Symbol.toStringTag,{value:"Module"})})(this["input-array-tags"]=this["input-array-tags"]||{});
81
81
  //# sourceMappingURL=main.iife.js.map