function w(){}function U(t){return t()}function z(){return Object.create(null)}function K(t){t.forEach(U)}function st(t){return typeof t=="function"}function ot(t,e){return t!=t?e==e:t!==e||t&&typeof t=="object"||typeof t=="function"}function ft(t){return Object.keys(t).length===0}function at(t,...e){if(t==null)return w;const n=t.subscribe(...e);return n.unsubscribe?()=>n.unsubscribe():n}function At(t,e,n){t.$$.on_destroy.push(at(e,n))}function St(t,e){t.appendChild(e)}function ut(t,e,n){t.insertBefore(e,n||null)}function F(t){t.parentNode.removeChild(t)}function jt(t,e){for(let n=0;nt.removeEventListener(e,n,r)}function Lt(t){return function(e){return e.preventDefault(),t.call(this,e)}}function Tt(t,e,n){n==null?t.removeAttribute(e):t.getAttribute(e)!==n&&t.setAttribute(e,n)}function Bt(t){return t===""?null:+t}function lt(t){return Array.from(t.childNodes)}function Dt(t,e){e=""+e,t.wholeText!==e&&(t.data=e)}function Ht(t,e){t.value=e==null?"":e}function Nt(t,e,n,r){t.style.setProperty(e,n,r?"important":"")}function qt(t,e){for(let n=0;n{S.delete(t),r&&(n&&t.d(1),r())}),t.o(e)}}function Xt(t){t&&t.c()}function mt(t,e,n,r){const{fragment:i,on_mount:c,on_destroy:f,after_update:o}=t.$$;i&&i.m(e,n),r||M(()=>{const s=c.map(U).filter(st);f?f.push(...s):K(s),t.$$.on_mount=[]}),o.forEach(M)}function gt(t,e){const n=t.$$;n.fragment!==null&&(K(n.on_destroy),n.fragment&&n.fragment.d(e),n.on_destroy=n.fragment=null,n.ctx=[])}function _t(t,e){t.$$.dirty[0]===-1&&(O.push(t),pt(),t.$$.dirty.fill(0)),t.$$.dirty[e/31|0]|=1<{const m=y.length?y[0]:h;return s.ctx&&i(s.ctx[a],s.ctx[a]=m)&&(!s.skip_bound&&s.bound[a]&&s.bound[a](m),l&&_t(t,a)),h}):[],s.update(),l=!0,K(s.before_update),s.fragment=r?r(s.ctx):!1,e.target){if(e.hydrate){const a=lt(e.target);s.fragment&&s.fragment.l(a),a.forEach(F)}else s.fragment&&s.fragment.c();e.intro&&yt(t.$$.fragment),mt(t,e.target,e.anchor,e.customElement),X()}C(o)}class Wt{$destroy(){gt(this,1),this.$destroy=w}$on(e,n){const r=this.$$.callbacks[e]||(this.$$.callbacks[e]=[]);return r.push(n),()=>{const i=r.indexOf(n);i!==-1&&r.splice(i,1)}}$set(e){this.$$set&&!ft(e)&&(this.$$.skip_bound=!0,this.$$set(e),this.$$.skip_bound=!1)}}const x=[];function Yt(t,e=w){let n;const r=[];function i(o){if(ot(t,o)&&(t=o,n)){const s=!x.length;for(let l=0;l{const a=r.indexOf(l);a!==-1&&r.splice(a,1),r.length===0&&(n(),n=null)}}return{set:i,update:c,subscribe:f}}/*! * hotkeys-js v3.8.5 * A simple micro-library for defining and dispatching keyboard shortcuts. It has no dependencies. * * Copyright (c) 2021 kenny wong * http://jaywcjlove.github.io/hotkeys * * Licensed under the MIT license. */var B=typeof navigator!="undefined"?navigator.userAgent.toLowerCase().indexOf("firefox")>0:!1;function D(t,e,n){t.addEventListener?t.addEventListener(e,n,!1):t.attachEvent&&t.attachEvent("on".concat(e),function(){n(window.event)})}function Q(t,e){for(var n=e.slice(0,e.length-1),r=0;r=0;)e[n-1]+=",",e.splice(n,1),n=e.lastIndexOf("");return e}function bt(t,e){for(var n=t.length>=e.length?t:e,r=t.length>=e.length?e:t,i=!0,c=0;c=0&&u.splice(n,1),t.key&&t.key.toLowerCase()==="meta"&&u.splice(0,u.length),(e===93||e===224)&&(e=91),e in p){p[e]=!1;for(var r in v)v[r]===e&&(_[r]=!1)}}function $t(t){if(!t)Object.keys(d).forEach(function(f){return delete d[f]});else if(Array.isArray(t))t.forEach(function(f){f.key&&H(f)});else if(typeof t=="object")t.key&&H(t);else if(typeof t=="string"){for(var e=arguments.length,n=new Array(e>1?e-1:0),r=1;r1?Q(v,l):[];d[y]=d[y].map(function(g){var it=i?g.method===i:!0;return it&&g.scope===r&&bt(g.mods,m)?{}:g})}})};function nt(t,e,n){var r;if(e.scope===n||e.scope==="all"){r=e.mods.length>0;for(var i in p)Object.prototype.hasOwnProperty.call(p,i)&&(!p[i]&&e.mods.indexOf(+i)>-1||p[i]&&e.mods.indexOf(+i)===-1)&&(r=!1);(e.mods.length===0&&!p[16]&&!p[18]&&!p[17]&&!p[91]||r||e.shortcut==="*")&&e.method(t,e)===!1&&(t.preventDefault?t.preventDefault():t.returnValue=!1,t.stopPropagation&&t.stopPropagation(),t.cancelBubble&&(t.cancelBubble=!0))}}function rt(t){var e=d["*"],n=t.keyCode||t.which||t.charCode;if(!!_.filter.call(this,t)){if((n===93||n===224)&&(n=91),u.indexOf(n)===-1&&n!==229&&u.push(n),["ctrlKey","altKey","shiftKey","metaKey"].forEach(function(m){var g=Z[m];t[m]&&u.indexOf(g)===-1?u.push(g):!t[m]&&u.indexOf(g)>-1?u.splice(u.indexOf(g),1):m==="metaKey"&&t[m]&&u.length===3&&(t.ctrlKey||t.shiftKey||t.altKey||(u=u.slice(u.indexOf(g))))}),n in p){p[n]=!0;for(var r in v)v[r]===n&&(_[r]=!0);if(!e)return}for(var i in p)Object.prototype.hasOwnProperty.call(p,i)&&(p[i]=t[Z[i]]);t.getModifierState&&!(t.altKey&&!t.ctrlKey)&&t.getModifierState("AltGraph")&&(u.indexOf(17)===-1&&u.push(17),u.indexOf(18)===-1&&u.push(18),p[17]=!0,p[18]=!0);var c=$();if(e)for(var f=0;f-1}function _(t,e,n){u=[];var r=W(t),i=[],c="all",f=document,o=0,s=!1,l=!0,a="+";for(n===void 0&&typeof e=="function"&&(n=e),Object.prototype.toString.call(e)==="[object Object]"&&(e.scope&&(c=e.scope),e.element&&(f=e.element),e.keyup&&(s=e.keyup),e.keydown!==void 0&&(l=e.keydown),typeof e.splitKey=="string"&&(a=e.splitKey)),typeof e=="string"&&(c=e);o1&&(i=Q(v,t)),t=t[t.length-1],t=t==="*"?"*":k(t),t in d||(d[t]=[]),d[t].push({keyup:s,keydown:l,scope:c,mods:i,shortcut:r[o],method:n,key:r[o],splitKey:a});typeof f!="undefined"&&!Et(f)&&window&&(tt.push(f),D(f,"keydown",function(h){rt(h)}),D(window,"focus",function(){u=[]}),D(f,"keyup",function(h){rt(h),Ot(h)}))}var N={setScope:et,getScope:$,deleteScope:Kt,getPressedKeyCodes:vt,isPressed:xt,filter:wt,unbind:$t};for(var q in N)Object.prototype.hasOwnProperty.call(N,q)&&(_[q]=N[q]);if(typeof window!="undefined"){var Ct=window.hotkeys;_.noConflict=function(t){return t&&window.hotkeys===_&&(window.hotkeys=Ct),_},window.hotkeys=_}export{Pt as A,Xt as B,mt as C,Vt as D,Rt as E,yt as F,gt as G,Jt as H,_ as I,zt as J,Wt as S,kt as a,Tt as b,ut as c,St as d,ct as e,Dt as f,F as g,Gt as h,Qt as i,Ht as j,jt as k,Mt as l,R as m,w as n,Ft as o,Lt as p,M as q,K as r,ot as s,G as t,Nt as u,qt as v,Ut as w,Bt as x,At as y,Yt as z};