1
0
Fork 0
mirror of synced 2024-09-12 15:37:31 +12:00
budibase/packages/server/builder/assets/vendor.3204f606.js
2021-03-31 19:55:55 +01:00

5 lines
1 MiB
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

var e=Object.defineProperty,t=Object.prototype.hasOwnProperty,n=Object.getOwnPropertySymbols,r=Object.prototype.propertyIsEnumerable,i=(t,n,r)=>n in t?e(t,n,{enumerable:!0,configurable:!0,writable:!0,value:r}):t[n]=r,o=(e,o)=>{for(var a in o||(o={}))t.call(o,a)&&i(e,a,o[a]);if(n)for(var a of n(o))r.call(o,a)&&i(e,a,o[a]);return e};function a(){}const s=e=>e;function l(e,t){for(const n in t)e[n]=t[n];return e}function u(e){return e()}function c(){return Object.create(null)}function f(e){e.forEach(u)}function p(e){return"function"==typeof e}function d(e,t){return e!=e?t==t:e!==t||e&&"object"==typeof e||"function"==typeof e}function h(e,...t){if(null==e)return a;const n=e.subscribe(...t);return n.unsubscribe?()=>n.unsubscribe():n}function g(e){let t;return h(e,(e=>t=e))(),t}function m(e,t,n){e.$$.on_destroy.push(h(t,n))}function v(e,t,n,r){if(e){const i=y(e,t,n,r);return e[0](i)}}function y(e,t,n,r){return e[1]&&r?l(n.ctx.slice(),e[1](r(t))):n.ctx}function b(e,t,n,r,i,o,a){const s=function(e,t,n,r){if(e[2]&&r){const i=e[2](r(n));if(void 0===t.dirty)return i;if("object"==typeof i){const e=[],n=Math.max(t.dirty.length,i.length);for(let r=0;r<n;r+=1)e[r]=t.dirty[r]|i[r];return e}return t.dirty|i}return t.dirty}(t,r,i,o);if(s){const i=y(t,n,r,a);e.p(i,s)}}function _(e){const t={};for(const n in e)"$"!==n[0]&&(t[n]=e[n]);return t}function w(e,t){const n={};t=new Set(t);for(const r in e)t.has(r)||"$"===r[0]||(n[r]=e[r]);return n}function x(e){return null==e?"":e}function k(e,t,n=t){return e.set(n),t}function C(e){return e&&p(e.destroy)?e.destroy:a}const E="undefined"!=typeof window;let O=E?()=>window.performance.now():()=>Date.now(),A=E?e=>requestAnimationFrame(e):a;const S=new Set;function j(e){S.forEach((t=>{t.c(e)||(S.delete(t),t.f())})),0!==S.size&&A(j)}function T(e){let t;return 0===S.size&&A(j),{promise:new Promise((n=>{S.add(t={c:e,f:n})})),abort(){S.delete(t)}}}function D(e,t){e.appendChild(t)}function N(e,t,n){e.insertBefore(t,n||null)}function L(e){e.parentNode.removeChild(e)}function M(e,t){for(let n=0;n<e.length;n+=1)e[n]&&e[n].d(t)}function P(e){return document.createElement(e)}function F(e){return document.createElementNS("http://www.w3.org/2000/svg",e)}function q(e){return document.createTextNode(e)}function I(){return q(" ")}function $(){return q("")}function R(e,t,n,r){return e.addEventListener(t,n,r),()=>e.removeEventListener(t,n,r)}function z(e){return function(t){return t.preventDefault(),e.call(this,t)}}function B(e){return function(t){return t.stopPropagation(),e.call(this,t)}}function W(e){return function(t){t.target===this&&e.call(this,t)}}function H(e,t,n){null==n?e.removeAttribute(t):e.getAttribute(t)!==n&&e.setAttribute(t,n)}function U(e,t){const n=Object.getOwnPropertyDescriptors(e.__proto__);for(const r in t)null==t[r]?e.removeAttribute(r):"style"===r?e.style.cssText=t[r]:"__value"===r?e.value=e[r]=t[r]:n[r]&&n[r].set?e[r]=t[r]:H(e,r,t[r])}function V(e){return""===e?null:+e}function K(e){return Array.from(e.childNodes)}function Y(e,t,n,r){for(let i=0;i<e.length;i+=1){const r=e[i];if(r.nodeName===t){let t=0;const o=[];for(;t<r.attributes.length;){const e=r.attributes[t++];n[e.name]||o.push(e.name)}for(let e=0;e<o.length;e++)r.removeAttribute(o[e]);return e.splice(i,1)[0]}}return r?F(t):P(t)}function G(e,t){for(let n=0;n<e.length;n+=1){const r=e[n];if(3===r.nodeType)return r.data=""+t,e.splice(n,1)[0]}return q(t)}function Z(e){return G(e," ")}function X(e,t){t=""+t,e.wholeText!==t&&(e.data=t)}function J(e,t){e.value=null==t?"":t}function Q(e,t,n,r){e.style.setProperty(t,n,r?"important":"")}function ee(e,t){for(let n=0;n<e.options.length;n+=1){const r=e.options[n];if(r.__value===t)return void(r.selected=!0)}}function te(e){const t=e.querySelector(":checked")||e.options[0];return t&&t.__value}let ne;function re(e,t){"static"===getComputedStyle(e).position&&(e.style.position="relative");const n=P("iframe");n.setAttribute("style","display: block; position: absolute; top: 0; left: 0; width: 100%; height: 100%; overflow: hidden; border: 0; opacity: 0; pointer-events: none; z-index: -1;"),n.setAttribute("aria-hidden","true"),n.tabIndex=-1;const r=function(){if(void 0===ne){ne=!1;try{"undefined"!=typeof window&&window.parent&&window.parent.document}catch(Vr){ne=!0}}return ne}();let i;return r?(n.src="data:text/html,<script>onresize=function(){parent.postMessage(0,'*')}<\/script>",i=R(window,"message",(e=>{e.source===n.contentWindow&&t()}))):(n.src="about:blank",n.onload=()=>{i=R(n.contentWindow,"resize",t)}),D(e,n),()=>{(r||i&&n.contentWindow)&&i(),L(n)}}function ie(e,t,n){e.classList[n?"add":"remove"](t)}function oe(e,t){const n=document.createEvent("CustomEvent");return n.initCustomEvent(e,!1,!1,t),n}function ae(e,t=document.body){return Array.from(t.querySelectorAll(e))}const se=new Set;let le,ue=0;function ce(e,t,n,r,i,o,a,s=0){const l=16.666/r;let u="{\n";for(let m=0;m<=1;m+=l){const e=t+(n-t)*o(m);u+=100*m+`%{${a(e,1-e)}}\n`}const c=u+`100% {${a(n,1-n)}}\n}`,f=`__svelte_${function(e){let t=5381,n=e.length;for(;n--;)t=(t<<5)-t^e.charCodeAt(n);return t>>>0}(c)}_${s}`,p=e.ownerDocument;se.add(p);const d=p.__svelte_stylesheet||(p.__svelte_stylesheet=p.head.appendChild(P("style")).sheet),h=p.__svelte_rules||(p.__svelte_rules={});h[f]||(h[f]=!0,d.insertRule(`@keyframes ${f} ${c}`,d.cssRules.length));const g=e.style.animation||"";return e.style.animation=`${g?`${g}, `:""}${f} ${r}ms linear ${i}ms 1 both`,ue+=1,f}function fe(e,t){const n=(e.style.animation||"").split(", "),r=n.filter(t?e=>e.indexOf(t)<0:e=>-1===e.indexOf("__svelte")),i=n.length-r.length;i&&(e.style.animation=r.join(", "),ue-=i,ue||A((()=>{ue||(se.forEach((e=>{const t=e.__svelte_stylesheet;let n=t.cssRules.length;for(;n--;)t.deleteRule(n);e.__svelte_rules={}})),se.clear())})))}function pe(e,t,n,r){if(!t)return a;const i=e.getBoundingClientRect();if(t.left===i.left&&t.right===i.right&&t.top===i.top&&t.bottom===i.bottom)return a;const{delay:o=0,duration:l=300,easing:u=s,start:c=O()+o,end:f=c+l,tick:p=a,css:d}=n(e,{from:t,to:i},r);let h,g=!0,m=!1;function v(){d&&fe(e,h),g=!1}return T((e=>{if(!m&&e>=c&&(m=!0),m&&e>=f&&(p(1,0),v()),!g)return!1;if(m){const t=0+1*u((e-c)/l);p(t,1-t)}return!0})),d&&(h=ce(e,0,1,l,o,u,d)),o||(m=!0),p(0,1),v}function de(e){const t=getComputedStyle(e);if("absolute"!==t.position&&"fixed"!==t.position){const{width:n,height:r}=t,i=e.getBoundingClientRect();e.style.position="absolute",e.style.width=n,e.style.height=r,he(e,i)}}function he(e,t){const n=e.getBoundingClientRect();if(t.left!==n.left||t.top!==n.top){const r=getComputedStyle(e),i="none"===r.transform?"":r.transform;e.style.transform=`${i} translate(${t.left-n.left}px, ${t.top-n.top}px)`}}function ge(e){le=e}function me(){if(!le)throw new Error("Function called outside component initialization");return le}function ve(e){me().$$.on_mount.push(e)}function ye(e){me().$$.after_update.push(e)}function be(e){me().$$.on_destroy.push(e)}function _e(){const e=me();return(t,n)=>{const r=e.$$.callbacks[t];if(r){const i=oe(t,n);r.slice().forEach((t=>{t.call(e,i)}))}}}function we(e,t){me().$$.context.set(e,t)}function xe(e){return me().$$.context.get(e)}function ke(e,t){const n=e.$$.callbacks[t.type];n&&n.slice().forEach((e=>e(t)))}const Ce=[],Ee=[],Oe=[],Ae=[],Se=Promise.resolve();let je=!1;function Te(){je||(je=!0,Se.then(Fe))}function De(){return Te(),Se}function Ne(e){Oe.push(e)}function Le(e){Ae.push(e)}let Me=!1;const Pe=new Set;function Fe(){if(!Me){Me=!0;do{for(let e=0;e<Ce.length;e+=1){const t=Ce[e];ge(t),qe(t.$$)}for(ge(null),Ce.length=0;Ee.length;)Ee.pop()();for(let e=0;e<Oe.length;e+=1){const t=Oe[e];Pe.has(t)||(Pe.add(t),t())}Oe.length=0}while(Ce.length);for(;Ae.length;)Ae.pop()();je=!1,Me=!1,Pe.clear()}}function qe(e){if(null!==e.fragment){e.update(),f(e.before_update);const t=e.dirty;e.dirty=[-1],e.fragment&&e.fragment.p(e.ctx,t),e.after_update.forEach(Ne)}}let Ie;function $e(){return Ie||(Ie=Promise.resolve(),Ie.then((()=>{Ie=null}))),Ie}function Re(e,t,n){e.dispatchEvent(oe(`${t?"intro":"outro"}${n}`))}const ze=new Set;let Be;function We(){Be={r:0,c:[],p:Be}}function He(){Be.r||f(Be.c),Be=Be.p}function Ue(e,t){e&&e.i&&(ze.delete(e),e.i(t))}function Ve(e,t,n,r){if(e&&e.o){if(ze.has(e))return;ze.add(e),Be.c.push((()=>{ze.delete(e),r&&(n&&e.d(1),r())})),e.o(t)}}const Ke={duration:0};function Ye(e,t,n){let r,i,o=t(e,n),l=!1,u=0;function c(){r&&fe(e,r)}function f(){const{delay:t=0,duration:n=300,easing:f=s,tick:p=a,css:d}=o||Ke;d&&(r=ce(e,0,1,n,t,f,d,u++)),p(0,1);const h=O()+t,g=h+n;i&&i.abort(),l=!0,Ne((()=>Re(e,!0,"start"))),i=T((t=>{if(l){if(t>=g)return p(1,0),Re(e,!0,"end"),c(),l=!1;if(t>=h){const e=f((t-h)/n);p(e,1-e)}}return l}))}let d=!1;return{start(){d||(fe(e),p(o)?(o=o(),$e().then(f)):f())},invalidate(){d=!1},end(){l&&(c(),l=!1)}}}function Ge(e,t,n){let r,i=t(e,n),o=!0;const l=Be;function u(){const{delay:t=0,duration:n=300,easing:u=s,tick:c=a,css:p}=i||Ke;p&&(r=ce(e,1,0,n,t,u,p));const d=O()+t,h=d+n;Ne((()=>Re(e,!1,"start"))),T((t=>{if(o){if(t>=h)return c(0,1),Re(e,!1,"end"),--l.r||f(l.c),!1;if(t>=d){const e=u((t-d)/n);c(1-e,e)}}return o}))}return l.r+=1,p(i)?$e().then((()=>{i=i(),u()})):u(),{end(t){t&&i.tick&&i.tick(1,0),o&&(r&&fe(e,r),o=!1)}}}function Ze(e,t,n,r){let i=t(e,n),o=r?0:1,l=null,u=null,c=null;function d(){c&&fe(e,c)}function h(e,t){const n=e.b-o;return t*=Math.abs(n),{a:o,b:e.b,d:n,duration:t,start:e.start,end:e.start+t,group:e.group}}function g(t){const{delay:n=0,duration:r=300,easing:p=s,tick:g=a,css:m}=i||Ke,v={start:O()+n,b:t};t||(v.group=Be,Be.r+=1),l||u?u=v:(m&&(d(),c=ce(e,o,t,r,n,p,m)),t&&g(0,1),l=h(v,r),Ne((()=>Re(e,t,"start"))),T((t=>{if(u&&t>u.start&&(l=h(u,r),u=null,Re(e,l.b,"start"),m&&(d(),c=ce(e,o,l.b,l.duration,0,p,i.css))),l)if(t>=l.end)g(o=l.b,1-o),Re(e,l.b,"end"),u||(l.b?d():--l.group.r||f(l.group.c)),l=null;else if(t>=l.start){const e=t-l.start;o=l.a+l.d*p(e/l.duration),g(o,1-o)}return!(!l&&!u)})))}return{run(e){p(i)?$e().then((()=>{i=i(),g(e)})):g(e)},end(){d(),l=u=null}}}function Xe(e,t){const n=t.token={};function r(e,r,i,o){if(t.token!==n)return;t.resolved=o;let a=t.ctx;void 0!==i&&(a=a.slice(),a[i]=o);const s=e&&(t.current=e)(a);let l=!1;t.block&&(t.blocks?t.blocks.forEach(((e,n)=>{n!==r&&e&&(We(),Ve(e,1,1,(()=>{t.blocks[n]===e&&(t.blocks[n]=null)})),He())})):t.block.d(1),s.c(),Ue(s,1),s.m(t.mount(),t.anchor),l=!0),t.block=s,t.blocks&&(t.blocks[r]=s),l&&Fe()}if((i=e)&&"object"==typeof i&&"function"==typeof i.then){const n=me();if(e.then((e=>{ge(n),r(t.then,1,t.value,e),ge(null)}),(e=>{if(ge(n),r(t.catch,2,t.error,e),ge(null),!t.hasCatch)throw e})),t.current!==t.pending)return r(t.pending,0),!0}else{if(t.current!==t.then)return r(t.then,1,t.value,e),!0;t.resolved=e}var i}const Je="undefined"!=typeof window?window:"undefined"!=typeof globalThis?globalThis:global;function Qe(e,t){e.d(1),t.delete(e.key)}function et(e,t){Ve(e,1,1,(()=>{t.delete(e.key)}))}function tt(e,t){e.f(),Qe(e,t)}function nt(e,t){e.f(),et(e,t)}function rt(e,t,n,r,i,o,a,s,l,u,c,f){let p=e.length,d=o.length,h=p;const g={};for(;h--;)g[e[h].key]=h;const m=[],v=new Map,y=new Map;for(h=d;h--;){const e=f(i,o,h),s=n(e);let l=a.get(s);l?r&&l.p(e,t):(l=u(s,e),l.c()),v.set(s,m[h]=l),s in g&&y.set(s,Math.abs(h-g[s]))}const b=new Set,_=new Set;function w(e){Ue(e,1),e.m(s,c),a.set(e.key,e),c=e.first,d--}for(;p&&d;){const t=m[d-1],n=e[p-1],r=t.key,i=n.key;t===n?(c=t.first,p--,d--):v.has(i)?!a.has(r)||b.has(r)?w(t):_.has(i)?p--:y.get(r)>y.get(i)?(_.add(r),w(t)):(b.add(i),p--):(l(n,a),p--)}for(;p--;){const t=e[p];v.has(t.key)||l(t,a)}for(;d;)w(m[d-1]);return m}function it(e,t){const n={},r={},i={$$scope:1};let o=e.length;for(;o--;){const a=e[o],s=t[o];if(s){for(const e in a)e in s||(r[e]=1);for(const e in s)i[e]||(n[e]=s[e],i[e]=1);e[o]=s}else for(const e in a)i[e]=1}for(const a in r)a in n||(n[a]=void 0);return n}function ot(e){return"object"==typeof e&&null!==e?e:{}}function at(e,t,n){const r=e.$$.props[t];void 0!==r&&(e.$$.bound[r]=n,n(e.$$.ctx[r]))}function st(e){e&&e.c()}function lt(e,t){e&&e.l(t)}function ut(e,t,n,r){const{fragment:i,on_mount:o,on_destroy:a,after_update:s}=e.$$;i&&i.m(t,n),r||Ne((()=>{const t=o.map(u).filter(p);a?a.push(...t):f(t),e.$$.on_mount=[]})),s.forEach(Ne)}function ct(e,t){const n=e.$$;null!==n.fragment&&(f(n.on_destroy),n.fragment&&n.fragment.d(t),n.on_destroy=n.fragment=null,n.ctx=[])}function ft(e,t,n,r,i,o,s=[-1]){const l=le;ge(e);const u=e.$$={fragment:null,ctx:null,props:o,update:a,not_equal:i,bound:c(),on_mount:[],on_destroy:[],on_disconnect:[],before_update:[],after_update:[],context:new Map(l?l.$$.context:[]),callbacks:c(),dirty:s,skip_bound:!1};let p=!1;if(u.ctx=n?n(e,t.props||{},((t,n,...r)=>{const o=r.length?r[0]:n;return u.ctx&&i(u.ctx[t],u.ctx[t]=o)&&(!u.skip_bound&&u.bound[t]&&u.bound[t](o),p&&function(e,t){-1===e.$$.dirty[0]&&(Ce.push(e),Te(),e.$$.dirty.fill(0)),e.$$.dirty[t/31|0]|=1<<t%31}(e,t)),n})):[],u.update(),p=!0,f(u.before_update),u.fragment=!!r&&r(u.ctx),t.target){if(t.hydrate){const e=K(t.target);u.fragment&&u.fragment.l(e),e.forEach(L)}else u.fragment&&u.fragment.c();t.intro&&Ue(e.$$.fragment),ut(e,t.target,t.anchor,t.customElement),Fe()}ge(l)}class pt{$destroy(){ct(this,1),this.$destroy=a}$on(e,t){const n=this.$$.callbacks[e]||(this.$$.callbacks[e]=[]);return n.push(t),()=>{const e=n.indexOf(t);-1!==e&&n.splice(e,1)}}$set(e){var t;this.$$set&&(t=e,0!==Object.keys(t).length)&&(this.$$.skip_bound=!0,this.$$set(e),this.$$.skip_bound=!1)}}var dt={queryHandler:{parse:e=>{return t=new URLSearchParams(e),[...t].reduce(((e,[t,n])=>(e[t]=n,e)),{});var t},stringify:e=>"?"+new URLSearchParams(e).toString()},urlTransform:{apply:e=>e,remove:e=>e},useHash:!1};const ht=RegExp(/\:([^/()]+)/g);function gt(e,t){if(navigator.userAgent.includes("jsdom"))return!1;t&&mt(e),function(){if(navigator.userAgent.includes("jsdom"))return!1;const{hash:e}=window.location;if(e){if(/^[A-Za-z]+[\w\-\:\.]*$/.test(e.substring(1))){const t=document.querySelector(e);t&&t.scrollIntoView()}}}()}function mt(e){e&&e.scrollTo&&"scroll-lock"!==e.dataset.routify&&"lock"!==e.dataset["routify-scroll"]&&(e.style["scroll-behavior"]="auto",e.scrollTo({top:0,behavior:"auto"}),e.style["scroll-behavior"]="",mt(e.parentElement))}const vt=e=>{const t=[];let n;for(;n=ht.exec(e);)t.push(n[1]);return t};function yt(e,t){yt._console=yt._console||{log:console.log,warn:console.warn};const{_console:n}=yt,r=e.componentFile.name.replace(/Proxy<_?(.+)>/,"$1").replace(/^Index$/,e.component.shortPath.split("/").pop()).replace(/^./,(e=>e.toUpperCase())).replace(/\:(.+)/,"U5B$1u5D"),i=[`<${r}> received an unexpected slot "default".`,`<${r}> was created with unknown prop 'scoped'`,`<${r}> was created with unknown prop 'scopedSync'`];for(const o of["log","warn"])console[o]=(...e)=>{i.includes(e[0])||n[o](...e)},t().then((()=>{console[o]=n[o]}))}function bt(){let e=window.location.pathname+window.location.search+window.location.hash;const{url:t,options:n}=function(e){const[t,n]=e.split("__[[routify_url_options]]__"),r=JSON.parse(decodeURIComponent(n||"")||"{}");return window.routify=window.routify||{},window.routify.prefetched=r.prefetch,{url:t,options:r}}(e),r=_t(t);return o(o({},r),{options:n})}function _t(e){dt.useHash&&(e=e.replace(/.*#(.+)/,"$1"));const t=e.startsWith("/")?window.location.origin:void 0,n=new URL(e,t);return{url:n,fullpath:n.pathname+n.search+n.hash}}function wt(e,t,n){const r=dt.useHash?"#":"";let i;return i=function(e,t,n){const r=Object.assign({},n,t),i=function(e,t){if(!dt.queryHandler)return"";const n=vt(e),r={};t&&Object.entries(t).forEach((([e,t])=>{n.includes(e)||(r[e]=t)}));return dt.queryHandler.stringify(r).replace(/\?$/,"")}(e,t);for(const[o,a]of Object.entries(r))e=e.replace(`:${o}`,a);return`${e}${i}`}(e,t,n),i=dt.urlTransform.apply(i),i=r+i,i}function xt(e){let t;const n=e[2].default,r=v(n,e,e[1],null);return{c(){r&&r.c()},l(e){r&&r.l(e)},m(e,n){r&&r.m(e,n),t=!0},p(e,[t]){r&&r.p&&2&t&&b(r,n,e,e[1],t,null,null)},i(e){t||(Ue(r,e),t=!0)},o(e){Ve(r,e),t=!1},d(e){r&&r.d(e)}}}function kt(e,t,n){let{$$slots:r={},$$scope:i}=t,{scoped:o={}}=t;return e.$$set=e=>{"scoped"in e&&n(0,o=e.scoped),"$$scope"in e&&n(1,i=e.$$scope)},[o,i,r]}class Ct extends pt{constructor(e){super(),ft(this,e,kt,xt,d,{scoped:0})}}const Et=[];function Ot(e,t=a){let n;const r=[];function i(t){if(d(e,t)&&(e=t,n)){const t=!Et.length;for(let n=0;n<r.length;n+=1){const t=r[n];t[1](),Et.push(t,e)}if(t){for(let e=0;e<Et.length;e+=2)Et[e][0](Et[e+1]);Et.length=0}}}return{set:i,update:function(t){i(t(e))},subscribe:function(o,s=a){const l=[o,s];return r.push(l),1===r.length&&(n=t(i)||a),o(e),()=>{const e=r.indexOf(l);-1!==e&&r.splice(e,1),0===r.length&&(n(),n=null)}}}}function At(e,t,n){const r=!Array.isArray(e),i=r?[e]:e,o=t.length<2;return{subscribe:Ot(n,(e=>{let n=!1;const s=[];let l=0,u=a;const c=()=>{if(l)return;u();const n=t(r?s[0]:s,e);o?e(n):u=p(n)?n:a},d=i.map(((e,t)=>h(e,(e=>{s[t]=e,l&=~(1<<t),n&&c()}),(()=>{l|=1<<t}))));return n=!0,c(),function(){f(d),u()}})).subscribe}}window.routify=window.routify||{};const St=Ot(null),jt=Ot([]);jt.subscribe((e=>window.routify.routes=e));let Tt=Ot({component:{params:{}}});const Dt=Ot(null),Nt=Ot(!0);function Lt(e,t=!1){e=dt.urlTransform.remove(e);let{pathname:n,search:r}=_t(e).url;const i=g(jt),o=i.find((e=>n===e.meta.name))||i.find((e=>n.match(e.regex)));if(!o)throw new Error(`Route could not be found for "${n}".`);const a=t?Object.create(o):o,{route:s,redirectPath:l,rewritePath:u}=Mt(a,i);return u&&(({pathname:n,search:r}=_t(wt(u,s.params)).url),l&&(s.redirectTo=wt(l,s.params||{}))),dt.queryHandler&&(s.params=Object.assign({},dt.queryHandler.parse(r))),function(e,t){if(e.paramKeys){const n=function(e){const t=[];return e.forEach((e=>{t[e.path.split("/").filter(Boolean).length-1]=e})),t}(e.layouts),r=t.split("/").filter(Boolean);(function(e){return e.split("/").filter(Boolean).map((e=>e.match(/\:(.+)/))).map((e=>e&&e[1]))})(e.path).forEach(((t,i)=>{t&&(e.params[t]=r[i],n[i]?n[i].param={[t]:r[i]}:e.param={[t]:r[i]})}))}}(s,n),s.leftover=e.replace(new RegExp(s.regex),""),s}function Mt(e,t,n,r){const{redirect:i,rewrite:o}=e.meta;if(i||o){n=i?i.path||i:n,r=o?o.path||o:n;const a=i&&i.params,s=o&&o.params,l=t.find((e=>e.path===r));return l===e&&console.error(`${r} is redirecting to itself`),l||console.error(`${e.path} is redirecting to non-existent path: ${r}`),(a||s)&&(l.params=Object.assign({},l.params,a,s)),Mt(l,t,n,r)}return{route:e,redirectPath:n,rewritePath:r}}function Pt(e,t,n){const r=e.slice();return r[1]=t[n],r}function Ft(e,t){let n,r;return{key:e,first:null,c(){n=P("iframe"),this.h()},l(e){n=Y(e,"IFRAME",{src:!0,frameborder:!0,title:!0}),K(n).forEach(L),this.h()},h(){n.src!==(r=t[1].url)&&H(n,"src",r),H(n,"frameborder","0"),H(n,"title","routify prefetcher"),this.first=n},m(e,t){N(e,n,t)},p(e,i){t=e,1&i&&n.src!==(r=t[1].url)&&H(n,"src",r)},d(e){e&&L(n)}}}function qt(e){let t,n=[],r=new Map,i=e[0];const o=e=>e[1].options.prefetch;for(let a=0;a<i.length;a+=1){let t=Pt(e,i,a),s=o(t);r.set(s,n[a]=Ft(s,t))}return{c(){t=P("div");for(let e=0;e<n.length;e+=1)n[e].c();this.h()},l(e){t=Y(e,"DIV",{id:!0,style:!0});var r=K(t);for(let t=0;t<n.length;t+=1)n[t].l(r);r.forEach(L),this.h()},h(){H(t,"id","__routify_iframes"),Q(t,"display","none")},m(e,r){N(e,t,r);for(let i=0;i<n.length;i+=1)n[i].m(t,null)},p(e,[a]){1&a&&(i=e[0],n=rt(n,a,o,1,e,i,r,t,Qe,Ft,null,Pt))},i:a,o:a,d(e){e&&L(t);for(let t=0;t<n.length;t+=1)n[t].d()}}}const It=Ot([]),$t=At(It,(e=>e.slice(0,2)));function Rt(e){const t=e.data?e.data.prefetchId:e;if(!t)return null;const n=g(It).find((e=>e&&e.options.prefetch==t));if(n){const{gracePeriod:e}=n.options,r=new Promise((t=>setTimeout(t,e))),i=new Promise((t=>{window.requestIdleCallback?window.requestIdleCallback(t):setTimeout(t,e+1e3)}));Promise.all([r,i]).then((()=>{It.update((e=>e.filter((e=>e.options.prefetch!=t))))}))}}function zt(e,t,n){let r;return m(e,$t,(e=>n(0,r=e))),[r]}$t.subscribe((e=>e.forEach((({options:e})=>{setTimeout((()=>Rt(e.prefetch)),e.timeout)})))),addEventListener("message",Rt,!1);class Bt extends pt{constructor(e){super(),ft(this,e,zt,qt,d,{})}}function Wt(){return xe("routify")||Tt}const Ht={subscribe:e=>At(Wt(),(e=>e.layout.api)).subscribe(e)},Ut={_hooks:[e=>Nt.set(!1)],subscribe:Kt},Vt={_hooks:[],subscribe:Kt};function Kt(e){const t=this._hooks,n=t.length;return e((e=>{t[n]=e})),()=>delete t[n]}const Yt={subscribe:e=>At(Wt(),(e=>e.route.params)).subscribe(e)},Gt={subscribe:e=>At(St,(e=>e.leftover)).subscribe(e)},Zt={subscribe(e){const t=Wt(),{route:n,routes:r}=g(t);return At(t,(e=>{return t=e,i=n,o=r,function(e,n={},r){const{component:a}=t,s=Object.assign({},i.params,a.params);let l=e&&e.nodeType&&e;l&&(e=e.getAttribute("href")),e=e?f(e):a.shortPath;const u=o.find((t=>[t.shortPath||"/",t.path].includes(e)));if(u&&"proximity"===u.meta.preload&&window.requestIdleCallback){const e=routify.appLoaded?0:1500;setTimeout((()=>{window.requestIdleCallback((()=>u.api.preload()))}),e)}r&&!1!==r.strict||(e=e.replace(/index$/,""));let c=wt(e,n,s);return l?(l.href=c,{update(t){l.href=wt(e,t,s)}}):c;function f(e){if(e.match(/^\.\.?\//)){let[,t,n]=e.match(/^([\.\/]+)(.*)/),r=a.path.replace(/\/$/,"");const i=t.match(/\.\.\//g)||[];a.isPage&&i.push(null),i.forEach((()=>r=r.replace(/\/[^\/]+\/?$/,""))),e=(e=`${r}/${n}`.replace(/\/$/,""))||"/"}else if(e.match(/^\//));else{const t=o.find((t=>t.meta.name===e));t&&(e=t.shortPath)}return e}};var t,i,o})).subscribe(e)}};const Xt={subscribe(e){const t=xe("routifyupdatepage");return At(Zt,(e=>function(n,r,i,o){const a=e(n,r);i?t(a,o):history.pushState({},null,a)})).subscribe(e)}},Jt={subscribe:e=>At([Zt,St],(([e,t])=>function(n="",r={},{strict:i}={strict:!0}){n=e(n,r,{strict:i});const o=e(t.path,null,{strict:i}),a=new RegExp("^"+n+"($|/)");return!!o.match(a)})).subscribe(e)},Qt={props:{},templates:{},services:{plain:{propField:"name",valueField:"content"},twitter:{propField:"name",valueField:"content"},og:{propField:"property",valueField:"content"}},plugins:[{name:"applyTemplate",condition:()=>!0,action:(e,t)=>[e,(Qt.getLongest(Qt.templates,e)||(e=>e))(t)]},{name:"createMeta",condition:()=>!0,action(e,t){Qt.writeMeta(e,t)}},{name:"createOG",condition:e=>!e.match(":"),action(e,t){Qt.writeMeta(`og:${e}`,t)}},{name:"createTitle",condition:e=>"title"===e,action(e,t){document.title=t}}],getLongest(e,t){const n=e[t];if(n){const r=g(St).path;return n[Object.keys(e[t]).filter((e=>r.includes(e))).sort(((e,t)=>t.length-e.length))[0]]}},writeMeta(e,t){const n=document.getElementsByTagName("head")[0],r=e.match(/(.+)\:/),i=r&&r[1]||"plain",{propField:o,valueField:a}=en.services[i]||en.services.plain,s=document.querySelector(`meta[${o}='${e}']`);s&&s.remove();const l=document.createElement("meta");l.setAttribute(o,e),l.setAttribute(a,t),l.setAttribute("data-origin","routify"),n.appendChild(l)},set(e,t){Qt.plugins.forEach((n=>{n.condition(e,t)&&([e,t]=n.action(e,t)||[e,t])}))},clear(){const e=document.querySelector("meta");e&&e.remove()},template(e,t){const n=Qt.getOrigin();Qt.templates[e]=Qt.templates[e]||{},Qt.templates[e][n]=t},update(){Object.keys(Qt.props).forEach((e=>{let t=Qt.getLongest(Qt.props,e);Qt.plugins.forEach((n=>{n.condition(e,t)&&([e,t]=n.action(e,t)||[e,t])}))}))},batchedUpdate(){Qt._pendingUpdate||(Qt._pendingUpdate=!0,setTimeout((()=>{Qt._pendingUpdate=!1,this.update()})))},_updateQueued:!1,getOrigin(){const e=Wt();return e&&g(e).path||"/"},_pendingUpdate:!1},en=new Proxy(Qt,{set(e,t,n,r){const{props:i,getOrigin:o}=e;return Reflect.has(e,t)?Reflect.set(e,t,n,r):(i[t]=i[t]||{},i[t][o()]=n),window.routify.appLoaded&&e.batchedUpdate(),!0}});function tn(e,t,n){const r=e.slice();return r[21]=t[n].component,r[22]=t[n].componentFile,r[2]=t[n].decorator,r[1]=t[n].nodes,r}function nn(e){let t,n,r=[],i=new Map,o=[e[4]];const a=e=>e[6];for(let s=0;s<1;s+=1){let t=tn(e,o,s),n=a(t);i.set(n,r[s]=sn(n,t))}return{c(){for(let e=0;e<1;e+=1)r[e].c();t=$()},l(e){for(let t=0;t<1;t+=1)r[t].l(e);t=$()},m(e,i){for(let t=0;t<1;t+=1)r[t].m(e,i);N(e,t,i),n=!0},p(e,n){33554557&n&&(o=[e[4]],We(),r=rt(r,n,a,1,e,o,i,t.parentNode,et,sn,t,tn),He())},i(e){if(!n){for(let e=0;e<1;e+=1)Ue(r[e]);n=!0}},o(e){for(let t=0;t<1;t+=1)Ve(r[t]);n=!1},d(e){for(let t=0;t<1;t+=1)r[t].d(e);e&&L(t)}}}function rn(e){let t,n;return t=new cn({props:{decorator:e[2],nodes:e[1],scoped:o(o({},e[0]),e[25])}}),{c(){st(t.$$.fragment)},l(e){lt(t.$$.fragment,e)},m(e,r){ut(t,e,r),n=!0},p(e,n){const r={};4&n&&(r.decorator=e[2]),16&n&&(r.nodes=e[1]),33554433&n&&(r.scoped=o(o({},e[0]),e[25])),t.$set(r)},i(e){n||(Ue(t.$$.fragment,e),n=!0)},o(e){Ve(t.$$.fragment,e),n=!1},d(e){ct(t,e)}}}function on(e){let t,n,r=e[21]&&e[1].length&&rn(e);return{c(){r&&r.c(),t=$()},l(e){r&&r.l(e),t=$()},m(e,i){r&&r.m(e,i),N(e,t,i),n=!0},p(e,n){e[21]&&e[1].length?r?(r.p(e,n),16&n&&Ue(r,1)):(r=rn(e),r.c(),Ue(r,1),r.m(t.parentNode,t)):r&&(We(),Ve(r,1,1,(()=>{r=null})),He())},i(e){n||(Ue(r),n=!0)},o(e){Ve(r),n=!1},d(e){r&&r.d(e),e&&L(t)}}}function an(e){let t,n,r;const i=[{scoped:e[0]},{scopedSync:e[5]},e[3].param||{}];var o=e[22];function a(e){let t={$$slots:{default:[on,({scoped:e,decorator:t})=>({25:e,2:t}),({scoped:e,decorator:t})=>(e?33554432:0)|(t?4:0)]},$$scope:{ctx:e}};for(let n=0;n<i.length;n+=1)t=l(t,i[n]);return{props:t}}return o&&(t=new o(a(e))),{c(){t&&st(t.$$.fragment),n=I()},l(e){t&&lt(t.$$.fragment,e),n=Z(e)},m(e,i){t&&ut(t,e,i),N(e,n,i),r=!0},p(e,r){const s=41&r?it(i,[1&r&&{scoped:e[0]},32&r&&{scopedSync:e[5]},8&r&&ot(e[3].param||{})]):{};if(100663317&r&&(s.$$scope={dirty:r,ctx:e}),o!==(o=e[22])){if(t){We();const e=t;Ve(e.$$.fragment,1,0,(()=>{ct(e,1)})),He()}o?(t=new o(a(e)),st(t.$$.fragment),Ue(t.$$.fragment,1),ut(t,n.parentNode,n)):t=null}else o&&t.$set(s)},i(e){r||(t&&Ue(t.$$.fragment,e),r=!0)},o(e){t&&Ve(t.$$.fragment,e),r=!1},d(e){t&&ct(t,e),e&&L(n)}}}function sn(e,t){let n,r,i,o;var a=t[2];function s(e){return{props:{scoped:e[0],$$slots:{default:[an]},$$scope:{ctx:e}}}}return a&&(r=new a(s(t))),{key:e,first:null,c(){n=$(),r&&st(r.$$.fragment),i=$(),this.h()},l(e){n=$(),r&&lt(r.$$.fragment,e),i=$(),this.h()},h(){this.first=n},m(e,t){N(e,n,t),r&&ut(r,e,t),N(e,i,t),o=!0},p(e,n){t=e;const o={};if(1&n&&(o.scoped=t[0]),67108925&n&&(o.$$scope={dirty:n,ctx:t}),a!==(a=t[2])){if(r){We();const e=r;Ve(e.$$.fragment,1,0,(()=>{ct(e,1)})),He()}a?(r=new a(s(t)),st(r.$$.fragment),Ue(r.$$.fragment,1),ut(r,i.parentNode,i)):r=null}else a&&r.$set(o)},i(e){o||(r&&Ue(r.$$.fragment,e),o=!0)},o(e){r&&Ve(r.$$.fragment,e),o=!1},d(e){e&&L(n),e&&L(i),r&&ct(r,e)}}}function ln(e){let t,n,r,i,o,a=e[4]&&nn(e);return{c(){a&&a.c(),t=I(),n=P("span")},l(e){a&&a.l(e),t=Z(e),n=Y(e,"SPAN",{}),K(n).forEach(L)},m(s,l){a&&a.m(s,l),N(s,t,l),N(s,n,l),r=!0,i||(o=C(e[9].call(null,n)),i=!0)},p(e,[n]){e[4]?a?(a.p(e,n),16&n&&Ue(a,1)):(a=nn(e),a.c(),Ue(a,1),a.m(t.parentNode,t)):a&&(We(),Ve(a,1,1,(()=>{a=null})),He())},i(e){r||(Ue(a),r=!0)},o(e){Ve(a),r=!1},d(e){a&&a.d(e),e&&L(t),e&&L(n),i=!1,o()}}}function un(e,t,n){let r,i,a,s,l;m(e,St,(e=>n(15,s=e))),m(e,jt,(e=>n(16,l=e)));let u,{nodes:c=[]}=t,{scoped:f={}}=t,{decorator:p}=t,d=null,h=null,g={},v=1;const y=Ot(null);m(e,y,(e=>n(4,i=e)));const b=xe("routify")||Tt;m(e,b,(e=>n(14,a=e)));we("routify",y);let _=[];function w(e){n(5,g=o({},f));const t=o(o({},i),{nodes:h,decorator:p||Ct,layout:d.isLayout?d:a.layout,component:d,route:s,routes:l,componentFile:e,parentNode:u||a.parentNode});y.set(t),k(b,a.child=d,a),0===h.length&&async function(){await new Promise((e=>setTimeout(e)));const e=i.component.path===s.path;!window.routify.stopAutoReady&&e&&async function({page:e,metatags:t,afterPageLoad:n,parentNode:r}){const i=e.last!==e;setTimeout((()=>gt(r,i)));const{path:o}=e,{options:a}=bt(),s=a.prefetch;for(const l of n._hooks)l&&await l(e.api);t.update(),dispatchEvent(new CustomEvent("app-loaded")),parent.postMessage({msg:"app-loaded",prefetched:window.routify.prefetched,path:o,prefetchId:s},"*"),window.routify.appLoaded=!0,window.routify.stopAutoReady=!1}({page:i.component,metatags:en,afterPageLoad:Ut,parentNode:u})}()}return e.$$set=e=>{"nodes"in e&&n(1,c=e.nodes),"scoped"in e&&n(0,f=e.scoped),"decorator"in e&&n(2,p=e.decorator)},e.$$.update=()=>{3074&e.$$.dirty&&_!==c&&(n(11,_=c),n(3,[d,...h]=[...c],d),n(3,d.api.reset=()=>n(10,v++,v),d)),8&e.$$.dirty&&function(e){let t=e.component();t instanceof Promise?t.then(w):w(t)}(d),1040&e.$$.dirty&&n(6,r=i&&v&&function({meta:e,path:t,param:n,params:r}){return JSON.stringify({path:t,invalidate:v,param:(e["param-is-page"]||e["slug-is-page"])&&n,queryParams:e["query-params-is-page"]&&r})}(i.component)),16&e.$$.dirty&&i&&yt(i,De)},[f,c,p,d,i,g,r,y,b,e=>u=e.parentNode,v,_]}class cn extends pt{constructor(e){super(),ft(this,e,un,ln,d,{nodes:1,scoped:0,decorator:2})}}function fn(e,t){let n=!1;function r(r,i){const o=Lt(r||bt().fullpath);o.redirectTo&&(history.replaceStateNative({},null,o.redirectTo),delete o.redirectTo);const a=[...(i&&Lt(bt().fullpath,e)||o).layouts,o];n&&delete n.last,o.last=n,n=o,r||Dt.set(o),St.set(o),o.api.preload().then((()=>{Nt.set(!0),t(a)}))}const i=function(e){["pushState","replaceState"].forEach((e=>{history[e+"Native"]||(history[e+"Native"]=history[e]),history[e]=async function(t={},n,r){if(r===location.pathname+location.search+location.hash)return!1;const{id:i,path:a,params:s}=g(St);t=o({id:i,path:a,params:s},t);const l=new Event(e.toLowerCase());Object.assign(l,{state:t,title:n,url:r});return await dn(l,r)?(history[e+"Native"].apply(this,[t,n,r]),dispatchEvent(l)):void 0}}));let t=!1;const n={click:pn,pushstate:()=>e(),replacestate:()=>e(),popstate:async n=>{t?t=!1:await dn(n,bt().fullpath)?e():(t=!0,n.preventDefault(),history.go(1))}};Object.entries(n).forEach((e=>addEventListener(...e)));return()=>{Object.entries(n).forEach((e=>removeEventListener(...e)))}}(r);return{updatePage:r,destroy:i}}function pn(e){const t=e.target.closest("a"),n=t&&t.href;if(e.ctrlKey||e.metaKey||e.altKey||e.shiftKey||e.button||e.defaultPrevented)return;if(!n||t.target||t.host!==location.host)return;const r=new URL(n),i=r.pathname+r.search+r.hash;e.preventDefault(),history.pushState({},"",i)}async function dn(e,t){const n=Lt(t).api;for(const r of Vt._hooks.filter(Boolean)){if(!(await r(e,n,{url:t})))return!1}return!0}function hn(e){let t,n;return t=new cn({props:{nodes:e[0]}}),{c(){st(t.$$.fragment)},l(e){lt(t.$$.fragment,e)},m(e,r){ut(t,e,r),n=!0},p(e,n){const r={};1&n&&(r.nodes=e[0]),t.$set(r)},i(e){n||(Ue(t.$$.fragment,e),n=!0)},o(e){Ve(t.$$.fragment,e),n=!1},d(e){ct(t,e)}}}function gn(e){let t,n,r,i=e[0]&&null!==e[1]&&hn(e);return n=new Bt({}),{c(){i&&i.c(),t=I(),st(n.$$.fragment)},l(e){i&&i.l(e),t=Z(e),lt(n.$$.fragment,e)},m(e,o){i&&i.m(e,o),N(e,t,o),ut(n,e,o),r=!0},p(e,[n]){e[0]&&null!==e[1]?i?(i.p(e,n),3&n&&Ue(i,1)):(i=hn(e),i.c(),Ue(i,1),i.m(t.parentNode,t)):i&&(We(),Ve(i,1,1,(()=>{i=null})),He())},i(e){r||(Ue(i),Ue(n.$$.fragment,e),r=!0)},o(e){Ve(i),Ve(n.$$.fragment,e),r=!1},d(e){i&&i.d(e),e&&L(t),ct(n,e)}}}function mn(e,t,n){let r;m(e,St,(e=>n(1,r=e)));let i,o,{routes:a}=t,{config:s={}}=t;window.routify=window.routify||{},window.routify.inBrowser=!window.navigator.userAgent.match("jsdom"),Object.assign(dt,s);we("routifyupdatepage",((...e)=>o&&o.updatePage(...e)));const l=e=>n(0,i=e),u=()=>{o&&(o.destroy(),o=null)};let c=null;return be(u),e.$$set=e=>{"routes"in e&&n(2,a=e.routes),"config"in e&&n(3,s=e.config)},e.$$.update=()=>{4&e.$$.dirty&&a&&(clearTimeout(c),c=setTimeout((()=>{u(),o=fn(a,l),jt.set(a),o.updatePage()})))},[i,r,a,s]}class vn extends pt{constructor(e){super(),ft(this,e,mn,gn,d,{routes:2,config:3})}}function yn(e){const t=async function(t){return await bn(e,{file:t.tree,state:{treePayload:t},scope:{}})};return t.sync=function(t){return _n(e,{file:t.tree,state:{treePayload:t},scope:{}})},t}async function bn(e,t){const n=await e(t);if(!1===n)return!1;const r=n||t.file;if(r.children){const n=await Promise.all(r.children.map((async n=>bn(e,{state:t.state,scope:wn(t.scope||{}),parent:t.file,file:await n}))));r.children=n.filter(Boolean)}return r}function _n(e,t){const n=e(t);if(!1===n)return!1;const r=n||t.file;if(r.children){const n=r.children.map((n=>_n(e,{state:t.state,scope:wn(t.scope||{}),parent:t.file,file:n})));r.children=n.filter(Boolean)}return r}function wn(e){return JSON.parse(JSON.stringify(e))}const xn=yn((({file:e})=>{(e.isPage||e.isFallback)&&(e.regex=((e,t)=>{const n=t?"":"/?$";return`^${e=(e=(e=e.replace(/\/_fallback?$/,"(/|$)")).replace(/\/index$/,"(/index)?")).replace(ht,"([^/]+)")+n}`})(e.path,e.isFallback))})),kn=yn((({file:e})=>{e.paramKeys=vt(e.path)})),Cn=yn((({file:e})=>{e.isFallback||e.isIndex?e.shortPath=e.path.replace(/\/[^/]+$/,""):e.shortPath=e.path})),En=yn((({file:e})=>{e.ranking=(({path:e})=>e.split("/").filter(Boolean).map((e=>"_fallback"===e?"A":e.startsWith(":")?"B":"C")).join(""))(e)})),On=yn((({file:e})=>{const t=e,n=e.meta&&e.meta.children||[];n.length&&(t.children=t.children||[],t.children.push(...n.map((e=>o(o({isMeta:!0},e),{meta:e})))))})),An=yn((e=>{const{file:t}=e,{isFallback:n,meta:r}=t,i=t.path.match("/:"),o=t.path.endsWith("/index"),a=r.index||0===r.index,s=!1===r.index;t.isIndexable=a||!n&&!i&&!o&&!s,t.isNonIndexable=!t.isIndexable})),Sn=yn((({file:e,parent:t})=>{Object.defineProperty(e,"parent",{get:()=>t}),Object.defineProperty(e,"nextSibling",{get:()=>Tn(e,1)}),Object.defineProperty(e,"prevSibling",{get:()=>Tn(e,-1)}),Object.defineProperty(e,"lineage",{get:()=>jn(t)})}));function jn(e,t=[]){return e&&(t.unshift(e),jn(e.parent,t)),t}function Tn(e,t){if(!e.root){const n=e.parent.children.filter((e=>e.isIndexable)),r=n.indexOf(e);return n[r+t]}}const Dn=yn((({file:e,parent:t})=>{e.isIndex&&Object.defineProperty(t,"index",{get:()=>e})})),Nn=yn((({file:e,scope:t})=>{function n(e){if(!e.isLayout&&e.meta.reset)return[];const{parent:t}=e,r=t&&t.component&&t,i=r&&(r.isReset||r.meta.reset),o=t&&!i&&n(t)||[];return r&&o.push(r),o}Object.defineProperty(e,"layouts",{get:()=>n(e)})})),Ln=yn((({file:e})=>{const t=e.root?function(){}:e.children?(e.isPage,function(){}):(e.isReset||e.isLayout||e.isFallback,function(){});Object.setPrototypeOf(e,t.prototype)}));var Mn=Object.freeze({__proto__:null,[Symbol.toStringTag]:"Module",setRegex:xn,setParamKeys:kn,setShortPath:Cn,setRank:En,addMetaChildren:On,setIsIndexable:An,assignRelations:Sn,assignIndex:Dn,assignLayout:Nn,createFlatList:e=>{yn((e=>{(e.file.isPage||e.file.isFallback)&&e.state.treePayload.routes.push(e.file)})).sync(e),e.routes.sort(((e,t)=>e.ranking>=t.ranking?-1:1))},setPrototype:Ln});const Pn={isDir:!1,ext:"svelte",isLayout:!1,isReset:!1,isIndex:!1,isFallback:!1,isPage:!1,ownMeta:{},meta:{recursive:!0,preload:!1,prerender:!0},id:"__fallback"};function Fn(e){return Object.entries(Pn).forEach((([t,n])=>{void 0===e[t]&&(e[t]=n)})),e.children&&(e.children=e.children.map(Fn)),e}const qn=yn((({file:e})=>{e.api=new In(e)}));class In{constructor(e){this.__file=e,Object.defineProperty(this,"__file",{enumerable:!1}),this.isMeta=!!e.isMeta,this.path=e.path,this.title=function(e){return void 0!==e.meta.title?e.meta.title:(e.shortPath||e.path).split("/").pop().replace(/-/g," ")}(e),this.meta=e.meta}get parent(){return!this.__file.root&&this.__file.parent.api}get children(){return(this.__file.children||this.__file.isLayout&&this.__file.parent.children||[]).filter((e=>!e.isNonIndexable)).sort(((e,t)=>e.isMeta&&t.isMeta?0:(e=(e.meta.index||e.meta.title||e.path).toString(),t=(t.meta.index||t.meta.title||t.path).toString(),e.localeCompare(t,void 0,{numeric:!0,sensitivity:"base"})))).map((({api:e})=>e))}get next(){return $n(this,1)}get prev(){return $n(this,-1)}async preload(){const e=[...this.__file.layouts,this.__file,this.index&&this.index.__file].filter(Boolean).map((e=>e.component()));await Promise.all(e)}get component(){return this.__file.component?this.__file.component():!!this.__file.index&&this.__file.index.component()}get componentWithIndex(){return new Promise((e=>Promise.all([this.component,this.index&&this.index.component]).then((t=>e(t)))))}get index(){const e=this.__file.children&&this.__file.children.find((e=>e.isIndex));return e&&e.api}}function $n(e,t){if(!e.__file.root){const n=e.parent.children.indexOf(e);return e.parent.children[n+t]}}const Rn=o(o({},Mn),{restoreDefaults:({tree:e})=>Fn(e),assignAPI:qn});function zn(e){const t=["restoreDefaults","setParamKeys","setRegex","setShortPath","setRank","assignLayout","setPrototype","addMetaChildren","assignRelations","setIsIndexable","assignIndex","assignAPI","createFlatList"],n={tree:e,routes:[]};for(let r of t){(Rn[r].sync||Rn[r])(n)}return n}var Bn="undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof self?self:{};function Wn(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}function Hn(e){if(e.__esModule)return e;var t=Object.defineProperty({},"__esModule",{value:!0});return Object.keys(e).forEach((function(n){var r=Object.getOwnPropertyDescriptor(e,n);Object.defineProperty(t,n,r.get?r:{enumerable:!0,get:function(){return e[n]}})})),t}function Un(e){var t={exports:{}};return e(t,t.exports),t.exports
/**
* @license
* Lodash lodash.com/license | Underscore.js 1.8.3 underscorejs.org/LICENSE
*/}var Vn=Un((function(e,t){(function(){function n(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function r(e,t,n,r){for(var i=-1,o=null==e?0:e.length;++i<o;){var a=e[i];t(r,a,n(a),e)}return r}function i(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););return e}function o(e,t){for(var n=null==e?0:e.length;n--&&!1!==t(e[n],n,e););return e}function a(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(!t(e[n],n,e))return!1;return!0}function s(e,t){for(var n=-1,r=null==e?0:e.length,i=0,o=[];++n<r;){var a=e[n];t(a,n,e)&&(o[i++]=a)}return o}function l(e,t){return!(null==e||!e.length)&&-1<v(e,t,0)}function u(e,t,n){for(var r=-1,i=null==e?0:e.length;++r<i;)if(n(t,e[r]))return!0;return!1}function c(e,t){for(var n=-1,r=null==e?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}function f(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}function p(e,t,n,r){var i=-1,o=null==e?0:e.length;for(r&&o&&(n=e[++i]);++i<o;)n=t(n,e[i],i,e);return n}function d(e,t,n,r){var i=null==e?0:e.length;for(r&&i&&(n=e[--i]);i--;)n=t(n,e[i],i,e);return n}function h(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}function g(e,t,n){var r;return n(e,(function(e,n,i){if(t(e,n,i))return r=n,!1})),r}function m(e,t,n,r){var i=e.length;for(n+=r?1:-1;r?n--:++n<i;)if(t(e[n],n,e))return n;return-1}function v(e,t,n){if(t==t)e:{--n;for(var r=e.length;++n<r;)if(e[n]===t){e=n;break e}e=-1}else e=m(e,b,n);return e}function y(e,t,n,r){--n;for(var i=e.length;++n<i;)if(r(e[n],t))return n;return-1}function b(e){return e!=e}function _(e,t){var n=null==e?0:e.length;return n?C(e,t)/n:R}function w(e){return function(t){return null==t?I:t[e]}}function x(e){return function(t){return null==e?I:e[t]}}function k(e,t,n,r,i){return i(e,(function(e,i,o){n=r?(r=!1,e):t(n,e,i,o)})),n}function C(e,t){for(var n,r=-1,i=e.length;++r<i;){var o=t(e[r]);o!==I&&(n=n===I?o:n+o)}return n}function E(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}function O(e){return function(t){return e(t)}}function A(e,t){return c(t,(function(t){return e[t]}))}function S(e,t){return e.has(t)}function j(e,t){for(var n=-1,r=e.length;++n<r&&-1<v(t,e[n],0););return n}function T(e,t){for(var n=e.length;n--&&-1<v(t,e[n],0););return n}function D(e){return"\\"+Ne[e]}function N(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n}function L(e,t){return function(n){return e(t(n))}}function M(e,t){for(var n=-1,r=e.length,i=0,o=[];++n<r;){var a=e[n];a!==t&&"__lodash_placeholder__"!==a||(e[n]="__lodash_placeholder__",o[i++]=n)}return o}function P(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n}function F(e){if(Ae.test(e)){for(var t=Ee.lastIndex=0;Ee.test(e);)++t;e=t}else e=Ge(e);return e}function q(e){return Ae.test(e)?e.match(Ee)||[]:e.split("")}var I,$=1/0,R=NaN,z=[["ary",128],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",32],["partialRight",64],["rearg",256]],B=/\b__p\+='';/g,W=/\b(__p\+=)''\+/g,H=/(__e\(.*?\)|\b__t\))\+'';/g,U=/&(?:amp|lt|gt|quot|#39);/g,V=/[&<>"']/g,K=RegExp(U.source),Y=RegExp(V.source),G=/<%-([\s\S]+?)%>/g,Z=/<%([\s\S]+?)%>/g,X=/<%=([\s\S]+?)%>/g,J=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,Q=/^\w*$/,ee=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,te=/[\\^$.*+?()[\]{}|]/g,ne=RegExp(te.source),re=/^\s+|\s+$/g,ie=/^\s+/,oe=/\s+$/,ae=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,se=/\{\n\/\* \[wrapped with (.+)\] \*/,le=/,? & /,ue=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,ce=/\\(\\)?/g,fe=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,pe=/\w*$/,de=/^[-+]0x[0-9a-f]+$/i,he=/^0b[01]+$/i,ge=/^\[object .+?Constructor\]$/,me=/^0o[0-7]+$/i,ve=/^(?:0|[1-9]\d*)$/,ye=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,be=/($^)/,_e=/['\n\r\u2028\u2029\\]/g,we="[\\ufe0e\\ufe0f]?(?:[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|\\ud83c[\\udffb-\\udfff])?(?:\\u200d(?:[^\\ud800-\\udfff]|(?:\\ud83c[\\udde6-\\uddff]){2}|[\\ud800-\\udbff][\\udc00-\\udfff])[\\ufe0e\\ufe0f]?(?:[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|\\ud83c[\\udffb-\\udfff])?)*",xe="(?:[\\u2700-\\u27bf]|(?:\\ud83c[\\udde6-\\uddff]){2}|[\\ud800-\\udbff][\\udc00-\\udfff])"+we,ke=RegExp("[']","g"),Ce=RegExp("[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]","g"),Ee=RegExp("\\ud83c[\\udffb-\\udfff](?=\\ud83c[\\udffb-\\udfff])|(?:[^\\ud800-\\udfff][\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]?|[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|(?:\\ud83c[\\udde6-\\uddff]){2}|[\\ud800-\\udbff][\\udc00-\\udfff]|[\\ud800-\\udfff])"+we,"g"),Oe=RegExp(["[A-Z\\xc0-\\xd6\\xd8-\\xde]?[a-z\\xdf-\\xf6\\xf8-\\xff]+(?:['](?:d|ll|m|re|s|t|ve))?(?=[\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000]|[A-Z\\xc0-\\xd6\\xd8-\\xde]|$)|(?:[A-Z\\xc0-\\xd6\\xd8-\\xde]|[^\\ud800-\\udfff\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000\\d+\\u2700-\\u27bfa-z\\xdf-\\xf6\\xf8-\\xffA-Z\\xc0-\\xd6\\xd8-\\xde])+(?:['](?:D|LL|M|RE|S|T|VE))?(?=[\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000]|[A-Z\\xc0-\\xd6\\xd8-\\xde](?:[a-z\\xdf-\\xf6\\xf8-\\xff]|[^\\ud800-\\udfff\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000\\d+\\u2700-\\u27bfa-z\\xdf-\\xf6\\xf8-\\xffA-Z\\xc0-\\xd6\\xd8-\\xde])|$)|[A-Z\\xc0-\\xd6\\xd8-\\xde]?(?:[a-z\\xdf-\\xf6\\xf8-\\xff]|[^\\ud800-\\udfff\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000\\d+\\u2700-\\u27bfa-z\\xdf-\\xf6\\xf8-\\xffA-Z\\xc0-\\xd6\\xd8-\\xde])+(?:['](?:d|ll|m|re|s|t|ve))?|[A-Z\\xc0-\\xd6\\xd8-\\xde]+(?:['](?:D|LL|M|RE|S|T|VE))?|\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])|\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])|\\d+",xe].join("|"),"g"),Ae=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]"),Se=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,je="Array Buffer DataView Date Error Float32Array Float64Array Function Int8Array Int16Array Int32Array Map Math Object Promise RegExp Set String Symbol TypeError Uint8Array Uint8ClampedArray Uint16Array Uint32Array WeakMap _ clearTimeout isFinite parseInt setTimeout".split(" "),Te={};Te["[object Float32Array]"]=Te["[object Float64Array]"]=Te["[object Int8Array]"]=Te["[object Int16Array]"]=Te["[object Int32Array]"]=Te["[object Uint8Array]"]=Te["[object Uint8ClampedArray]"]=Te["[object Uint16Array]"]=Te["[object Uint32Array]"]=!0,Te["[object Arguments]"]=Te["[object Array]"]=Te["[object ArrayBuffer]"]=Te["[object Boolean]"]=Te["[object DataView]"]=Te["[object Date]"]=Te["[object Error]"]=Te["[object Function]"]=Te["[object Map]"]=Te["[object Number]"]=Te["[object Object]"]=Te["[object RegExp]"]=Te["[object Set]"]=Te["[object String]"]=Te["[object WeakMap]"]=!1;var De={};De["[object Arguments]"]=De["[object Array]"]=De["[object ArrayBuffer]"]=De["[object DataView]"]=De["[object Boolean]"]=De["[object Date]"]=De["[object Float32Array]"]=De["[object Float64Array]"]=De["[object Int8Array]"]=De["[object Int16Array]"]=De["[object Int32Array]"]=De["[object Map]"]=De["[object Number]"]=De["[object Object]"]=De["[object RegExp]"]=De["[object Set]"]=De["[object String]"]=De["[object Symbol]"]=De["[object Uint8Array]"]=De["[object Uint8ClampedArray]"]=De["[object Uint16Array]"]=De["[object Uint32Array]"]=!0,De["[object Error]"]=De["[object Function]"]=De["[object WeakMap]"]=!1;var Ne={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},Le=parseFloat,Me=parseInt,Pe="object"==typeof Bn&&Bn&&Bn.Object===Object&&Bn,Fe="object"==typeof self&&self&&self.Object===Object&&self,qe=Pe||Fe||Function("return this")(),Ie=t&&!t.nodeType&&t,$e=Ie&&e&&!e.nodeType&&e,Re=$e&&$e.exports===Ie,ze=Re&&Pe.process,Be=function(){try{var e=$e&&$e.f&&$e.f("util").types;return e||ze&&ze.binding&&ze.binding("util")}catch(t){}}(),We=Be&&Be.isArrayBuffer,He=Be&&Be.isDate,Ue=Be&&Be.isMap,Ve=Be&&Be.isRegExp,Ke=Be&&Be.isSet,Ye=Be&&Be.isTypedArray,Ge=w("length"),Ze=x({"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"}),Xe=x({"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"}),Je=x({"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"}),Qe=function e(t){function x(e){if(Kr(e)&&!Fa(e)&&!(e instanceof Ee)){if(e instanceof xe)return e;if(Fi.call(e,"__wrapped__"))return br(e)}return new xe(e)}function we(){}function xe(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=I}function Ee(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=4294967295,this.__views__=[]}function Ne(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Pe(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Fe(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Ie(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new Fe;++t<n;)this.add(e[t])}function $e(e){this.size=(this.__data__=new Pe(e)).size}function ze(e,t){var n,r=Fa(e),i=!r&&Pa(e),o=!r&&!i&&Ia(e),a=!r&&!i&&!o&&Wa(e),s=(i=(r=r||i||o||a)?E(e.length,Ti):[]).length;for(n in e)!t&&!Fi.call(e,n)||r&&("length"==n||o&&("offset"==n||"parent"==n)||a&&("buffer"==n||"byteLength"==n||"byteOffset"==n)||or(n,s))||i.push(n);return i}function Be(e){var t=e.length;return t?e[Ht(0,t-1)]:I}function Ge(e,t){return gr(wn(e),lt(t,0,e.length))}function et(e){return gr(wn(e))}function tt(e,t,n){(n===I||$r(e[t],n))&&(n!==I||t in e)||at(e,t,n)}function nt(e,t,n){var r=e[t];Fi.call(e,t)&&$r(r,n)&&(n!==I||t in e)||at(e,t,n)}function rt(e,t){for(var n=e.length;n--;)if($r(e[n][0],t))return n;return-1}function it(e,t,n,r){return Po(e,(function(e,i,o){t(r,e,n(e),o)})),r}function ot(e,t){return e&&xn(t,si(t),e)}function at(e,t,n){"__proto__"==t&&eo?eo(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function st(e,t){for(var n=-1,r=t.length,i=ki(r),o=null==e;++n<r;)i[n]=o?I:oi(e,t[n]);return i}function lt(e,t,n){return e==e&&(n!==I&&(e=e<=n?e:n),t!==I&&(e=e>=t?e:t)),e}function ut(e,t,n,r,o,a){var s,l=1&t,u=2&t,c=4&t;if(n&&(s=o?n(e,r,o,a):n(e)),s!==I)return s;if(!Vr(e))return e;if(r=Fa(e)){if(s=function(e){var t=e.length,n=new e.constructor(t);return t&&"string"==typeof e[0]&&Fi.call(e,"index")&&(n.index=e.index,n.input=e.input),n}(e),!l)return wn(e,s)}else{var f=Vo(e),p="[object Function]"==f||"[object GeneratorFunction]"==f;if(Ia(e))return gn(e,l);if("[object Object]"==f||"[object Arguments]"==f||p&&!o){if(s=u||p?{}:rr(e),!l)return u?function(e,t){return xn(e,Uo(e),t)}(e,function(e,t){return e&&xn(t,li(t),e)}(s,e)):function(e,t){return xn(e,Ho(e),t)}(e,ot(s,e))}else{if(!De[f])return o?e:{};s=function(e,t,n){var r=e.constructor;switch(t){case"[object ArrayBuffer]":return mn(e);case"[object Boolean]":case"[object Date]":return new r(+e);case"[object DataView]":return t=n?mn(e.buffer):e.buffer,new e.constructor(t,e.byteOffset,e.byteLength);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return vn(e,n);case"[object Map]":return new r;case"[object Number]":case"[object String]":return new r(e);case"[object RegExp]":return(t=new e.constructor(e.source,pe.exec(e))).lastIndex=e.lastIndex,t;case"[object Set]":return new r;case"[object Symbol]":return No?Si(No.call(e)):{}}}(e,f,l)}}if(a||(a=new $e),o=a.get(e))return o;a.set(e,s),Ba(e)?e.forEach((function(r){s.add(ut(r,t,n,r,e,a))})):Ra(e)&&e.forEach((function(r,i){s.set(i,ut(r,t,n,i,e,a))}));u=c?u?Gn:Yn:u?li:si;var d=r?I:u(e);return i(d||e,(function(r,i){d&&(r=e[i=r]),nt(s,i,ut(r,t,n,i,e,a))})),s}function ct(e,t,n){var r=n.length;if(null==e)return!r;for(e=Si(e);r--;){var i=n[r],o=t[i],a=e[i];if(a===I&&!(i in e)||!o(a))return!1}return!0}function ft(e,t,n){if("function"!=typeof e)throw new Di("Expected a function");return Go((function(){e.apply(I,n)}),t)}function pt(e,t,n,r){var i=-1,o=l,a=!0,s=e.length,f=[],p=t.length;if(!s)return f;n&&(t=c(t,O(n))),r?(o=u,a=!1):200<=t.length&&(o=S,a=!1,t=new Ie(t));e:for(;++i<s;){var d=e[i],h=null==n?d:n(d);d=r||0!==d?d:0;if(a&&h==h){for(var g=p;g--;)if(t[g]===h)continue e;f.push(d)}else o(t,h,r)||f.push(d)}return f}function dt(e,t){var n=!0;return Po(e,(function(e,r,i){return n=!!t(e,r,i)})),n}function ht(e,t,n){for(var r=-1,i=e.length;++r<i;){var o=e[r],a=t(o);if(null!=a&&(s===I?a==a&&!Xr(a):n(a,s)))var s=a,l=o}return l}function gt(e,t){var n=[];return Po(e,(function(e,r,i){t(e,r,i)&&n.push(e)})),n}function mt(e,t,n,r,i){var o=-1,a=e.length;for(n||(n=ir),i||(i=[]);++o<a;){var s=e[o];0<t&&n(s)?1<t?mt(s,t-1,n,r,i):f(i,s):r||(i[i.length]=s)}return i}function vt(e,t){return e&&qo(e,t,si)}function yt(e,t){return e&&Io(e,t,si)}function bt(e,t){return s(t,(function(t){return Wr(e[t])}))}function _t(e,t){for(var n=0,r=(t=dn(t,e)).length;null!=e&&n<r;)e=e[mr(t[n++])];return n&&n==r?e:I}function wt(e,t,n){return t=t(e),Fa(e)?t:f(t,n(e))}function xt(e){if(null==e)e=e===I?"[object Undefined]":"[object Null]";else if(Qi&&Qi in Si(e)){var t=Fi.call(e,Qi),n=e[Qi];try{e[Qi]=I;var r=!0}catch(o){}var i=$i.call(e);r&&(t?e[Qi]=n:delete e[Qi]),e=i}else e=$i.call(e);return e}function kt(e,t){return e>t}function Ct(e,t){return null!=e&&Fi.call(e,t)}function Et(e,t){return null!=e&&t in Si(e)}function Ot(e,t,n){for(var r=n?u:l,i=e[0].length,o=e.length,a=o,s=ki(o),f=1/0,p=[];a--;){var d=e[a];a&&t&&(d=c(d,O(t))),f=po(d.length,f),s[a]=!n&&(t||120<=i&&120<=d.length)?new Ie(a&&d):I}d=e[0];var h=-1,g=s[0];e:for(;++h<i&&p.length<f;){var m=d[h],v=t?t(m):m;m=n||0!==m?m:0;if(g?!S(g,v):!r(p,v,n)){for(a=o;--a;){var y=s[a];if(y?!S(y,v):!r(e[a],v,n))continue e}g&&g.push(v),p.push(m)}}return p}function At(e,t,r){return null==(t=null==(e=2>(t=dn(t,e)).length?e:_t(e,Xt(t,0,-1)))?e:e[mr(Cr(t))])?I:n(t,e,r)}function St(e){return Kr(e)&&"[object Arguments]"==xt(e)}function jt(e,t,n,r,i){if(e===t)t=!0;else if(null==e||null==t||!Kr(e)&&!Kr(t))t=e!=e&&t!=t;else e:{var o,a,s=Fa(e),l=Fa(t),u="[object Object]"==(o="[object Arguments]"==(o=s?"[object Array]":Vo(e))?"[object Object]":o);l="[object Object]"==(a="[object Arguments]"==(a=l?"[object Array]":Vo(t))?"[object Object]":a);if((a=o==a)&&Ia(e)){if(!Ia(t)){t=!1;break e}s=!0,u=!1}if(a&&!u)i||(i=new $e),t=s||Wa(e)?Vn(e,t,n,r,jt,i):function(e,t,n,r,i,o,a){switch(n){case"[object DataView]":if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)break;e=e.buffer,t=t.buffer;case"[object ArrayBuffer]":if(e.byteLength!=t.byteLength||!o(new Ui(e),new Ui(t)))break;return!0;case"[object Boolean]":case"[object Date]":case"[object Number]":return $r(+e,+t);case"[object Error]":return e.name==t.name&&e.message==t.message;case"[object RegExp]":case"[object String]":return e==t+"";case"[object Map]":var s=N;case"[object Set]":if(s||(s=P),e.size!=t.size&&!(1&r))break;return(n=a.get(e))?n==t:(r|=2,a.set(e,t),t=Vn(s(e),s(t),r,i,o,a),a.delete(e),t);case"[object Symbol]":if(No)return No.call(e)==No.call(t)}return!1}(e,t,o,n,r,jt,i);else{if(!(1&n)&&(s=u&&Fi.call(e,"__wrapped__"),o=l&&Fi.call(t,"__wrapped__"),s||o)){e=s?e.value():e,t=o?t.value():t,i||(i=new $e),t=jt(e,t,n,r,i);break e}if(a)t:if(i||(i=new $e),s=1&n,o=Yn(e),l=o.length,a=Yn(t).length,l==a||s){for(u=l;u--;){var c=o[u];if(!(s?c in t:Fi.call(t,c))){t=!1;break t}}if((a=i.get(e))&&i.get(t))t=a==t;else{a=!0,i.set(e,t),i.set(t,e);for(var f=s;++u<l;){var p=e[c=o[u]],d=t[c];if(r)var h=s?r(d,p,c,t,e,i):r(p,d,c,e,t,i);if(h===I?p!==d&&!jt(p,d,n,r,i):!h){a=!1;break}f||(f="constructor"==c)}a&&!f&&((n=e.constructor)!=(r=t.constructor)&&"constructor"in e&&"constructor"in t&&!("function"==typeof n&&n instanceof n&&"function"==typeof r&&r instanceof r)&&(a=!1)),i.delete(e),i.delete(t),t=a}}else t=!1;else t=!1}}return t}function Tt(e,t,n,r){var i=n.length,o=i,a=!r;if(null==e)return!o;for(e=Si(e);i--;){var s=n[i];if(a&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++i<o;){var l=(s=n[i])[0],u=e[l],c=s[1];if(a&&s[2]){if(u===I&&!(l in e))return!1}else{if(s=new $e,r)var f=r(u,c,l,e,t,s);if(f===I?!jt(c,u,3,r,s):!f)return!1}}return!0}function Dt(e){return!(!Vr(e)||Ii&&Ii in e)&&(Wr(e)?Bi:ge).test(vr(e))}function Nt(e){return"function"==typeof e?e:null==e?gi:"object"==typeof e?Fa(e)?qt(e[0],e[1]):Ft(e):bi(e)}function Lt(e){if(!ur(e))return co(e);var t,n=[];for(t in Si(e))Fi.call(e,t)&&"constructor"!=t&&n.push(t);return n}function Mt(e,t){return e<t}function Pt(e,t){var n=-1,r=Rr(e)?ki(e.length):[];return Po(e,(function(e,i,o){r[++n]=t(e,i,o)})),r}function Ft(e){var t=er(e);return 1==t.length&&t[0][2]?cr(t[0][0],t[0][1]):function(n){return n===e||Tt(n,e,t)}}function qt(e,t){return sr(e)&&t==t&&!Vr(t)?cr(mr(e),t):function(n){var r=oi(n,e);return r===I&&r===t?ai(n,e):jt(t,r,3)}}function It(e,t,n,r,i){e!==t&&qo(t,(function(o,a){if(i||(i=new $e),Vr(o)){var s=i,l=pr(e,a),u=pr(t,a);if(h=s.get(u))tt(e,a,h);else{var c=(h=r?r(l,u,a+"",e,t,s):I)===I;if(c){var f=Fa(u),p=!f&&Ia(u),d=!f&&!p&&Wa(u),h=u;f||p||d?Fa(l)?h=l:zr(l)?h=wn(l):p?(c=!1,h=gn(u,!0)):d?(c=!1,h=vn(u,!0)):h=[]:Gr(u)||Pa(u)?(h=l,Pa(l)?h=ri(l):Vr(l)&&!Wr(l)||(h=rr(u))):c=!1}c&&(s.set(u,h),It(h,u,n,r,s),s.delete(u)),tt(e,a,h)}}else(s=r?r(pr(e,a),o,a+"",e,t,i):I)===I&&(s=o),tt(e,a,s)}),li)}function $t(e,t){var n=e.length;if(n)return or(t+=0>t?n:0,n)?e[t]:I}function Rt(e,t,n){var r=-1;return t=c(t.length?t:[gi],O(Jn())),function(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].c;return e}(e=Pt(e,(function(e){return{a:c(t,(function(t){return t(e)})),b:++r,c:e}})),(function(e,t){var r;e:{r=-1;for(var i=e.a,o=t.a,a=i.length,s=n.length;++r<a;){var l=yn(i[r],o[r]);if(l){r=r>=s?l:l*("desc"==n[r]?-1:1);break e}}r=e.b-t.b}return r}))}function zt(e,t,n){for(var r=-1,i=t.length,o={};++r<i;){var a=t[r],s=_t(e,a);n(s,a)&&Gt(o,dn(a,e),s)}return o}function Bt(e,t,n,r){var i=r?y:v,o=-1,a=t.length,s=e;for(e===t&&(t=wn(t)),n&&(s=c(e,O(n)));++o<a;){var l=0,u=t[o];for(u=n?n(u):u;-1<(l=i(s,u,l,r));)s!==e&&Zi.call(s,l,1),Zi.call(e,l,1)}return e}function Wt(e,t){for(var n=e?t.length:0,r=n-1;n--;){var i=t[n];if(n==r||i!==o){var o=i;or(i)?Zi.call(e,i,1):an(e,i)}}}function Ht(e,t){return e+oo(mo()*(t-e+1))}function Ut(e,t){var n="";if(!e||1>t||9007199254740991<t)return n;do{t%2&&(n+=e),(t=oo(t/2))&&(e+=e)}while(t);return n}function Vt(e,t){return Zo(fr(e,t,gi),e+"")}function Kt(e){return Be(ci(e))}function Yt(e,t){var n=ci(e);return gr(n,lt(t,0,n.length))}function Gt(e,t,n,r){if(!Vr(e))return e;for(var i=-1,o=(t=dn(t,e)).length,a=o-1,s=e;null!=s&&++i<o;){var l=mr(t[i]),u=n;if(i!=a){var c=s[l];(u=r?r(c,l,s):I)===I&&(u=Vr(c)?c:or(t[i+1])?[]:{})}nt(s,l,u),s=s[l]}return e}function Zt(e){return gr(ci(e))}function Xt(e,t,n){var r=-1,i=e.length;for(0>t&&(t=-t>i?0:i+t),0>(n=n>i?i:n)&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0,n=ki(i);++r<i;)n[r]=e[r+t];return n}function Jt(e,t){var n;return Po(e,(function(e,r,i){return!(n=t(e,r,i))})),!!n}function Qt(e,t,n){var r=0,i=null==e?r:e.length;if("number"==typeof t&&t==t&&2147483647>=i){for(;r<i;){var o=r+i>>>1,a=e[o];null!==a&&!Xr(a)&&(n?a<=t:a<t)?r=o+1:i=o}return i}return en(e,t,gi,n)}function en(e,t,n,r){t=n(t);for(var i=0,o=null==e?0:e.length,a=t!=t,s=null===t,l=Xr(t),u=t===I;i<o;){var c=oo((i+o)/2),f=n(e[c]),p=f!==I,d=null===f,h=f==f,g=Xr(f);(a?r||h:u?h&&(r||p):s?h&&p&&(r||!d):l?h&&p&&!d&&(r||!g):!d&&!g&&(r?f<=t:f<t))?i=c+1:o=c}return po(o,4294967294)}function tn(e,t){for(var n=-1,r=e.length,i=0,o=[];++n<r;){var a=e[n],s=t?t(a):a;if(!n||!$r(s,l)){var l=s;o[i++]=0===a?0:a}}return o}function nn(e){return"number"==typeof e?e:Xr(e)?R:+e}function rn(e){if("string"==typeof e)return e;if(Fa(e))return c(e,rn)+"";if(Xr(e))return Lo?Lo.call(e):"";var t=e+"";return"0"==t&&1/e==-$?"-0":t}function on(e,t,n){var r=-1,i=l,o=e.length,a=!0,s=[],c=s;if(n)a=!1,i=u;else if(200<=o){if(i=t?null:Bo(e))return P(i);a=!1,i=S,c=new Ie}else c=t?[]:s;e:for(;++r<o;){var f=e[r],p=t?t(f):f;f=n||0!==f?f:0;if(a&&p==p){for(var d=c.length;d--;)if(c[d]===p)continue e;t&&c.push(p),s.push(f)}else i(c,p,n)||(c!==s&&c.push(p),s.push(f))}return s}function an(e,t){return null==(e=2>(t=dn(t,e)).length?e:_t(e,Xt(t,0,-1)))||delete e[mr(Cr(t))]}function sn(e,t,n,r){for(var i=e.length,o=r?i:-1;(r?o--:++o<i)&&t(e[o],o,e););return n?Xt(e,r?0:o,r?o+1:i):Xt(e,r?o+1:0,r?i:o)}function ln(e,t){var n=e;return n instanceof Ee&&(n=n.value()),p(t,(function(e,t){return t.func.apply(t.thisArg,f([e],t.args))}),n)}function un(e,t,n){var r=e.length;if(2>r)return r?on(e[0]):[];for(var i=-1,o=ki(r);++i<r;)for(var a=e[i],s=-1;++s<r;)s!=i&&(o[i]=pt(o[i]||a,e[s],t,n));return on(mt(o,1),t,n)}function cn(e,t,n){for(var r=-1,i=e.length,o=t.length,a={};++r<i;)n(a,e[r],r<o?t[r]:I);return a}function fn(e){return zr(e)?e:[]}function pn(e){return"function"==typeof e?e:gi}function dn(e,t){return Fa(e)?e:sr(e,t)?[e]:Xo(ii(e))}function hn(e,t,n){var r=e.length;return n=n===I?r:n,!t&&n>=r?e:Xt(e,t,n)}function gn(e,t){if(t)return e.slice();var n=e.length;n=Vi?Vi(n):new e.constructor(n);return e.copy(n),n}function mn(e){var t=new e.constructor(e.byteLength);return new Ui(t).set(new Ui(e)),t}function vn(e,t){return new e.constructor(t?mn(e.buffer):e.buffer,e.byteOffset,e.length)}function yn(e,t){if(e!==t){var n=e!==I,r=null===e,i=e==e,o=Xr(e),a=t!==I,s=null===t,l=t==t,u=Xr(t);if(!s&&!u&&!o&&e>t||o&&a&&l&&!s&&!u||r&&a&&l||!n&&l||!i)return 1;if(!r&&!o&&!u&&e<t||u&&n&&i&&!r&&!o||s&&n&&i||!a&&i||!l)return-1}return 0}function bn(e,t,n,r){var i=-1,o=e.length,a=n.length,s=-1,l=t.length,u=fo(o-a,0),c=ki(l+u);for(r=!r;++s<l;)c[s]=t[s];for(;++i<a;)(r||i<o)&&(c[n[i]]=e[i]);for(;u--;)c[s++]=e[i++];return c}function _n(e,t,n,r){var i=-1,o=e.length,a=-1,s=n.length,l=-1,u=t.length,c=fo(o-s,0),f=ki(c+u);for(r=!r;++i<c;)f[i]=e[i];for(c=i;++l<u;)f[c+l]=t[l];for(;++a<s;)(r||i<o)&&(f[c+n[a]]=e[i++]);return f}function wn(e,t){var n=-1,r=e.length;for(t||(t=ki(r));++n<r;)t[n]=e[n];return t}function xn(e,t,n,r){var i=!n;n||(n={});for(var o=-1,a=t.length;++o<a;){var s=t[o],l=r?r(n[s],e[s],s,n,e):I;l===I&&(l=e[s]),i?at(n,s,l):nt(n,s,l)}return n}function kn(e,t){return function(n,i){var o=Fa(n)?r:it,a=t?t():{};return o(n,e,Jn(i,2),a)}}function Cn(e){return Vt((function(t,n){var r=-1,i=n.length,o=1<i?n[i-1]:I,a=2<i?n[2]:I;o=3<e.length&&"function"==typeof o?(i--,o):I;for(a&&ar(n[0],n[1],a)&&(o=3>i?I:o,i=1),t=Si(t);++r<i;)(a=n[r])&&e(t,a,r,o);return t}))}function En(e,t){return function(n,r){if(null==n)return n;if(!Rr(n))return e(n,r);for(var i=n.length,o=t?i:-1,a=Si(n);(t?o--:++o<i)&&!1!==r(a[o],o,a););return n}}function On(e){return function(t,n,r){for(var i=-1,o=Si(t),a=(r=r(t)).length;a--;){var s=r[e?a:++i];if(!1===n(o[s],s,o))break}return t}}function An(e){return function(t){t=ii(t);var n=Ae.test(t)?q(t):I,r=n?n[0]:t.charAt(0);return t=n?hn(n,1).join(""):t.slice(1),r[e]()+t}}function Sn(e){return function(t){return p(di(pi(t).replace(ke,"")),e,"")}}function jn(e){return function(){switch((t=arguments).length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3]);case 5:return new e(t[0],t[1],t[2],t[3],t[4]);case 6:return new e(t[0],t[1],t[2],t[3],t[4],t[5]);case 7:return new e(t[0],t[1],t[2],t[3],t[4],t[5],t[6])}var t,n=Mo(e.prototype);return Vr(t=e.apply(n,t))?t:n}}function Tn(e){return function(t,n,r){var i=Si(t);if(!Rr(t)){var o=Jn(n,3);t=si(t),n=function(e){return o(i[e],e,i)}}return-1<(n=e(t,n,r))?i[o?t[n]:n]:I}}function Dn(e){return Kn((function(t){var n=t.length,r=n,i=xe.prototype.thru;for(e&&t.reverse();r--;){if("function"!=typeof(a=t[r]))throw new Di("Expected a function");if(i&&!o&&"wrapper"==Zn(a))var o=new xe([],!0)}for(r=o?r:n;++r<n;){var a,s="wrapper"==(i=Zn(a=t[r]))?Wo(a):I;o=s&&lr(s[0])&&424==s[1]&&!s[4].length&&1==s[9]?o[Zn(s[0])].apply(o,s[3]):1==a.length&&lr(a)?o[i]():o.thru(a)}return function(){var e=(i=arguments)[0];if(o&&1==i.length&&Fa(e))return o.plant(e).value();for(var r=0,i=n?t[r].apply(this,i):e;++r<n;)i=t[r].call(this,i);return i}}))}function Nn(e,t,n,r,i,o,a,s,l,u){var c=128&t,f=1&t,p=2&t,d=24&t,h=512&t,g=p?I:jn(e);return function m(){for(var v=arguments.length,y=ki(v),b=v;b--;)y[b]=arguments[b];if(d){var _,w=Xn(m);b=y.length;for(_=0;b--;)y[b]===w&&++_}if(r&&(y=bn(y,r,i,d)),o&&(y=_n(y,o,a,d)),v-=_,d&&v<u)return w=M(y,w),$n(e,t,Nn,m.placeholder,n,y,w,s,l,u-v);if(w=f?n:this,b=p?w[e]:e,v=y.length,s){_=y.length;for(var x=po(s.length,_),k=wn(y);x--;){var C=s[x];y[x]=or(C,_)?k[C]:I}}else h&&1<v&&y.reverse();return c&&l<v&&(y.length=l),this&&this!==qe&&this instanceof m&&(b=g||jn(b)),b.apply(w,y)}}function Ln(e,t){return function(n,r){return function(e,t,n){var r={};return vt(e,(function(e,i,o){t(r,n(e),i,o)})),r}(n,e,t(r))}}function Mn(e,t){return function(n,r){var i;if(n===I&&r===I)return t;if(n!==I&&(i=n),r!==I){if(i===I)return r;"string"==typeof n||"string"==typeof r?(n=rn(n),r=rn(r)):(n=nn(n),r=nn(r)),i=e(n,r)}return i}}function Pn(e){return Kn((function(t){return t=c(t,O(Jn())),Vt((function(r){var i=this;return e(t,(function(e){return n(e,i,r)}))}))}))}function Fn(e,t){var n=(t=t===I?" ":rn(t)).length;return 2>n?n?Ut(t,e):t:(n=Ut(t,io(e/F(t))),Ae.test(t)?hn(q(n),0,e).join(""):n.slice(0,e))}function qn(e){return function(t,n,r){r&&"number"!=typeof r&&ar(t,n,r)&&(n=r=I),t=Qr(t),n===I?(n=t,t=0):n=Qr(n),r=r===I?t<n?1:-1:Qr(r);var i=-1;n=fo(io((n-t)/(r||1)),0);for(var o=ki(n);n--;)o[e?n:++i]=t,t+=r;return o}}function In(e){return function(t,n){return"string"==typeof t&&"string"==typeof n||(t=ni(t),n=ni(n)),e(t,n)}}function $n(e,t,n,r,i,o,a,s,l,u){var c=8&t;return 4&(t=(t|(c?32:64))&~(c?64:32))||(t&=-4),i=[e,t,i,c?o:I,c?a:I,o=c?I:o,a=c?I:a,s,l,u],n=n.apply(I,i),lr(e)&&Yo(n,i),n.placeholder=r,dr(n,e,t)}function Rn(e){var t=Ai[e];return function(e,n){if(e=ni(e),(n=null==n?0:po(ei(n),292))&&lo(e)){var r=(ii(e)+"e").split("e");return+((r=(ii(r=t(r[0]+"e"+(+r[1]+n)))+"e").split("e"))[0]+"e"+(+r[1]-n))}return t(e)}}function zn(e){return function(t){var n=Vo(t);return"[object Map]"==n?N(t):"[object Set]"==n?function(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=[e,e]})),n}(t):function(e,t){return c(t,(function(t){return[t,e[t]]}))}(t,e(t))}}function Bn(e,t,r,i,o,a,s,l){var u=2&t;if(!u&&"function"!=typeof e)throw new Di("Expected a function");var c=i?i.length:0;if(c||(t&=-97,i=o=I),s=s===I?s:fo(ei(s),0),l=l===I?l:ei(l),c-=o?o.length:0,64&t){var f=i,p=o;i=o=I}var d=u?I:Wo(e);return a=[e,t,r,i,o,f,p,a,s,l],d&&(t=(r=a[1])|(e=d[1]),i=128==e&&8==r||128==e&&256==r&&a[7].length<=d[8]||384==e&&d[7].length<=d[8]&&8==r,131>t||i)&&(1&e&&(a[2]=d[2],t|=1&r?0:4),(r=d[3])&&(i=a[3],a[3]=i?bn(i,r,d[4]):r,a[4]=i?M(a[3],"__lodash_placeholder__"):d[4]),(r=d[5])&&(i=a[5],a[5]=i?_n(i,r,d[6]):r,a[6]=i?M(a[5],"__lodash_placeholder__"):d[6]),(r=d[7])&&(a[7]=r),128&e&&(a[8]=null==a[8]?d[8]:po(a[8],d[8])),null==a[9]&&(a[9]=d[9]),a[0]=d[0],a[1]=t),e=a[0],t=a[1],r=a[2],i=a[3],o=a[4],!(l=a[9]=a[9]===I?u?0:e.length:fo(a[9]-c,0))&&24&t&&(t&=-25),dr((d?$o:Yo)(t&&1!=t?8==t||16==t?function(e,t,r){var i=jn(e);return function o(){for(var a=arguments.length,s=ki(a),l=a,u=Xn(o);l--;)s[l]=arguments[l];return(a-=(l=3>a&&s[0]!==u&&s[a-1]!==u?[]:M(s,u)).length)<r?$n(e,t,Nn,o.placeholder,I,s,l,I,I,r-a):n(this&&this!==qe&&this instanceof o?i:e,this,s)}}(e,t,l):32!=t&&33!=t||o.length?Nn.apply(I,a):function(e,t,r,i){var o=1&t,a=jn(e);return function t(){for(var s=-1,l=arguments.length,u=-1,c=i.length,f=ki(c+l),p=this&&this!==qe&&this instanceof t?a:e;++u<c;)f[u]=i[u];for(;l--;)f[u++]=arguments[++s];return n(p,o?r:this,f)}}(e,t,r,i):function(e,t,n){var r=1&t,i=jn(e);return function t(){return(this&&this!==qe&&this instanceof t?i:e).apply(r?n:this,arguments)}}(e,t,r),a),e,t)}function Wn(e,t,n,r){return e===I||$r(e,Li[n])&&!Fi.call(r,n)?t:e}function Hn(e,t,n,r,i,o){return Vr(e)&&Vr(t)&&(o.set(t,e),It(e,t,I,Hn,o),o.delete(t)),e}function Un(e){return Gr(e)?I:e}function Vn(e,t,n,r,i,o){var a=1&n,s=e.length;if(s!=(l=t.length)&&!(a&&l>s))return!1;if((l=o.get(e))&&o.get(t))return l==t;var l=-1,u=!0,c=2&n?new Ie:I;for(o.set(e,t),o.set(t,e);++l<s;){var f=e[l],p=t[l];if(r)var d=a?r(p,f,l,t,e,o):r(f,p,l,e,t,o);if(d!==I){if(d)continue;u=!1;break}if(c){if(!h(t,(function(e,t){if(!S(c,t)&&(f===e||i(f,e,n,r,o)))return c.push(t)}))){u=!1;break}}else if(f!==p&&!i(f,p,n,r,o)){u=!1;break}}return o.delete(e),o.delete(t),u}function Kn(e){return Zo(fr(e,I,xr),e+"")}function Yn(e){return wt(e,si,Ho)}function Gn(e){return wt(e,li,Uo)}function Zn(e){for(var t=e.name+"",n=Eo[t],r=Fi.call(Eo,t)?n.length:0;r--;){var i=n[r],o=i.func;if(null==o||o==e)return i.name}return t}function Xn(e){return(Fi.call(x,"placeholder")?x:e).placeholder}function Jn(){var e=(e=x.iteratee||mi)===mi?Nt:e;return arguments.length?e(arguments[0],arguments[1]):e}function Qn(e,t){var n=e.__data__,r=typeof t;return("string"==r||"number"==r||"symbol"==r||"boolean"==r?"__proto__"!==t:null===t)?n["string"==typeof t?"string":"hash"]:n.map}function er(e){for(var t=si(e),n=t.length;n--;){var r=t[n],i=e[r];t[n]=[r,i,i==i&&!Vr(i)]}return t}function tr(e,t){var n=null==e?I:e[t];return Dt(n)?n:I}function nr(e,t,n){for(var r=-1,i=(t=dn(t,e)).length,o=!1;++r<i;){var a=mr(t[r]);if(!(o=null!=e&&n(e,a)))break;e=e[a]}return o||++r!=i?o:!!(i=null==e?0:e.length)&&Ur(i)&&or(a,i)&&(Fa(e)||Pa(e))}function rr(e){return"function"!=typeof e.constructor||ur(e)?{}:Mo(Ki(e))}function ir(e){return Fa(e)||Pa(e)||!!(Xi&&e&&e[Xi])}function or(e,t){var n=typeof e;return!!(t=null==t?9007199254740991:t)&&("number"==n||"symbol"!=n&&ve.test(e))&&-1<e&&e%1==0&&e<t}function ar(e,t,n){if(!Vr(n))return!1;var r=typeof t;return!!("number"==r?Rr(n)&&or(t,n.length):"string"==r&&t in n)&&$r(n[t],e)}function sr(e,t){if(Fa(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!Xr(e))||Q.test(e)||!J.test(e)||null!=t&&e in Si(t)}function lr(e){var t=Zn(e),n=x[t];return"function"==typeof n&&t in Ee.prototype&&(e===n||!!(t=Wo(n))&&e===t[0])}function ur(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||Li)}function cr(e,t){return function(n){return null!=n&&n[e]===t&&(t!==I||e in Si(n))}}function fr(e,t,r){return t=fo(t===I?e.length-1:t,0),function(){for(var i=arguments,o=-1,a=fo(i.length-t,0),s=ki(a);++o<a;)s[o]=i[t+o];for(o=-1,a=ki(t+1);++o<t;)a[o]=i[o];return a[t]=r(s),n(e,this,a)}}function pr(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]}function dr(e,t,n){var r=t+"";t=Zo;var i,o=yr;return n=o(i=(i=r.match(se))?i[1].split(le):[],n),(o=n.length)&&(n[i=o-1]=(1<o?"& ":"")+n[i],n=n.join(2<o?", ":" "),r=r.replace(ae,"{\n/* [wrapped with "+n+"] */\n")),t(e,r)}function hr(e){var t=0,n=0;return function(){var r=ho(),i=16-(r-n);if(n=r,0<i){if(800<=++t)return arguments[0]}else t=0;return e.apply(I,arguments)}}function gr(e,t){var n=-1,r=(i=e.length)-1;for(t=t===I?i:t;++n<t;){var i,o=e[i=Ht(n,r)];e[i]=e[n],e[n]=o}return e.length=t,e}function mr(e){if("string"==typeof e||Xr(e))return e;var t=e+"";return"0"==t&&1/e==-$?"-0":t}function vr(e){if(null!=e){try{return Pi.call(e)}catch(t){}return e+""}return""}function yr(e,t){return i(z,(function(n){var r="_."+n[0];t&n[1]&&!l(e,r)&&e.push(r)})),e.sort()}function br(e){if(e instanceof Ee)return e.clone();var t=new xe(e.__wrapped__,e.__chain__);return t.__actions__=wn(e.__actions__),t.__index__=e.__index__,t.__values__=e.__values__,t}function _r(e,t,n){var r=null==e?0:e.length;return r?(0>(n=null==n?0:ei(n))&&(n=fo(r+n,0)),m(e,Jn(t,3),n)):-1}function wr(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var i=r-1;return n!==I&&(i=ei(n),i=0>n?fo(r+i,0):po(i,r-1)),m(e,Jn(t,3),i,!0)}function xr(e){return null!=e&&e.length?mt(e,1):[]}function kr(e){return e&&e.length?e[0]:I}function Cr(e){var t=null==e?0:e.length;return t?e[t-1]:I}function Er(e,t){return e&&e.length&&t&&t.length?Bt(e,t):e}function Or(e){return null==e?e:vo.call(e)}function Ar(e){if(!e||!e.length)return[];var t=0;return e=s(e,(function(e){if(zr(e))return t=fo(e.length,t),!0})),E(t,(function(t){return c(e,w(t))}))}function Sr(e,t){if(!e||!e.length)return[];var r=Ar(e);return null==t?r:c(r,(function(e){return n(t,I,e)}))}function jr(e){return(e=x(e)).__chain__=!0,e}function Tr(e,t){return t(e)}function Dr(e,t){return(Fa(e)?i:Po)(e,Jn(t,3))}function Nr(e,t){return(Fa(e)?o:Fo)(e,Jn(t,3))}function Lr(e,t){return(Fa(e)?c:Pt)(e,Jn(t,3))}function Mr(e,t,n){return t=n?I:t,t=e&&null==t?e.length:t,Bn(e,128,I,I,I,I,t)}function Pr(e,t){var n;if("function"!=typeof t)throw new Di("Expected a function");return e=ei(e),function(){return 0<--e&&(n=t.apply(this,arguments)),1>=e&&(t=I),n}}function Fr(e,t,n){function r(t){var n=l,r=u;return l=u=I,h=t,f=e.apply(r,n)}function i(e){var n=e-d;return e-=h,d===I||n>=t||0>n||m&&e>=c}function o(){var e=Ca();if(i(e))return a(e);var n,r=Go;n=e-h,e=t-(e-d),n=m?po(e,c-n):e,p=r(o,n)}function a(e){return p=I,v&&l?r(e):(l=u=I,f)}function s(){var e=Ca(),n=i(e);if(l=arguments,u=this,d=e,n){if(p===I)return h=e=d,p=Go(o,t),g?r(e):f;if(m)return zo(p),p=Go(o,t),r(d)}return p===I&&(p=Go(o,t)),f}var l,u,c,f,p,d,h=0,g=!1,m=!1,v=!0;if("function"!=typeof e)throw new Di("Expected a function");return t=ni(t)||0,Vr(n)&&(g=!!n.leading,c=(m="maxWait"in n)?fo(ni(n.maxWait)||0,t):c,v="trailing"in n?!!n.trailing:v),s.cancel=function(){p!==I&&zo(p),h=0,l=d=u=p=I},s.flush=function(){return p===I?f:a(Ca())},s}function qr(e,t){function n(){var r=arguments,i=t?t.apply(this,r):r[0],o=n.cache;return o.has(i)?o.get(i):(r=e.apply(this,r),n.cache=o.set(i,r)||o,r)}if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new Di("Expected a function");return n.cache=new(qr.Cache||Fe),n}function Ir(e){if("function"!=typeof e)throw new Di("Expected a function");return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}function $r(e,t){return e===t||e!=e&&t!=t}function Rr(e){return null!=e&&Ur(e.length)&&!Wr(e)}function zr(e){return Kr(e)&&Rr(e)}function Br(e){if(!Kr(e))return!1;var t=xt(e);return"[object Error]"==t||"[object DOMException]"==t||"string"==typeof e.message&&"string"==typeof e.name&&!Gr(e)}function Wr(e){return!!Vr(e)&&("[object Function]"==(e=xt(e))||"[object GeneratorFunction]"==e||"[object AsyncFunction]"==e||"[object Proxy]"==e)}function Hr(e){return"number"==typeof e&&e==ei(e)}function Ur(e){return"number"==typeof e&&-1<e&&e%1==0&&9007199254740991>=e}function Vr(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function Kr(e){return null!=e&&"object"==typeof e}function Yr(e){return"number"==typeof e||Kr(e)&&"[object Number]"==xt(e)}function Gr(e){return!(!Kr(e)||"[object Object]"!=xt(e))&&(null===(e=Ki(e))||"function"==typeof(e=Fi.call(e,"constructor")&&e.constructor)&&e instanceof e&&Pi.call(e)==Ri)}function Zr(e){return"string"==typeof e||!Fa(e)&&Kr(e)&&"[object String]"==xt(e)}function Xr(e){return"symbol"==typeof e||Kr(e)&&"[object Symbol]"==xt(e)}function Jr(e){if(!e)return[];if(Rr(e))return Zr(e)?q(e):wn(e);if(Ji&&e[Ji]){e=e[Ji]();for(var t,n=[];!(t=e.next()).done;)n.push(t.value);return n}return("[object Map]"==(t=Vo(e))?N:"[object Set]"==t?P:ci)(e)}function Qr(e){return e?(e=ni(e))===$||e===-$?17976931348623157e292*(0>e?-1:1):e==e?e:0:0===e?e:0}function ei(e){var t=(e=Qr(e))%1;return e==e?t?e-t:e:0}function ti(e){return e?lt(ei(e),0,4294967295):0}function ni(e){if("number"==typeof e)return e;if(Xr(e))return R;if(Vr(e)&&(e=Vr(e="function"==typeof e.valueOf?e.valueOf():e)?e+"":e),"string"!=typeof e)return 0===e?e:+e;e=e.replace(re,"");var t=he.test(e);return t||me.test(e)?Me(e.slice(2),t?2:8):de.test(e)?R:+e}function ri(e){return xn(e,li(e))}function ii(e){return null==e?"":rn(e)}function oi(e,t,n){return(e=null==e?I:_t(e,t))===I?n:e}function ai(e,t){return null!=e&&nr(e,t,Et)}function si(e){return Rr(e)?ze(e):Lt(e)}function li(e){if(Rr(e))e=ze(e,!0);else if(Vr(e)){var t,n=ur(e),r=[];for(t in e)("constructor"!=t||!n&&Fi.call(e,t))&&r.push(t);e=r}else{if(t=[],null!=e)for(n in Si(e))t.push(n);e=t}return e}function ui(e,t){if(null==e)return{};var n=c(Gn(e),(function(e){return[e]}));return t=Jn(t),zt(e,n,(function(e,n){return t(e,n[0])}))}function ci(e){return null==e?[]:A(e,si(e))}function fi(e){return gs(ii(e).toLowerCase())}function pi(e){return(e=ii(e))&&e.replace(ye,Ze).replace(Ce,"")}function di(e,t,n){return e=ii(e),(t=n?I:t)===I?Se.test(e)?e.match(Oe)||[]:e.match(ue)||[]:e.match(t)||[]}function hi(e){return function(){return e}}function gi(e){return e}function mi(e){return Nt("function"==typeof e?e:ut(e,1))}function vi(e,t,n){var r=si(t),o=bt(t,r);null!=n||Vr(t)&&(o.length||!r.length)||(n=t,t=e,e=this,o=bt(t,si(t)));var a=!(Vr(n)&&"chain"in n&&!n.chain),s=Wr(e);return i(o,(function(n){var r=t[n];e[n]=r,s&&(e.prototype[n]=function(){var t=this.__chain__;if(a||t){var n=e(this.__wrapped__);return(n.__actions__=wn(this.__actions__)).push({func:r,args:arguments,thisArg:e}),n.__chain__=t,n}return r.apply(e,f([this.value()],arguments))})})),e}function yi(){}function bi(e){return sr(e)?w(mr(e)):function(e){return function(t){return _t(t,e)}}(e)}function _i(){return[]}function wi(){return!1}var xi,ki=(t=null==t?qe:Qe.defaults(qe.Object(),t,Qe.pick(qe,je))).Array,Ci=t.Date,Ei=t.Error,Oi=t.Function,Ai=t.Math,Si=t.Object,ji=t.RegExp,Ti=t.String,Di=t.TypeError,Ni=ki.prototype,Li=Si.prototype,Mi=t["__core-js_shared__"],Pi=Oi.prototype.toString,Fi=Li.hasOwnProperty,qi=0,Ii=(xi=/[^.]+$/.exec(Mi&&Mi.keys&&Mi.keys.IE_PROTO||""))?"Symbol(src)_1."+xi:"",$i=Li.toString,Ri=Pi.call(Si),zi=qe._,Bi=ji("^"+Pi.call(Fi).replace(te,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),Wi=Re?t.Buffer:I,Hi=t.Symbol,Ui=t.Uint8Array,Vi=Wi?Wi.g:I,Ki=L(Si.getPrototypeOf,Si),Yi=Si.create,Gi=Li.propertyIsEnumerable,Zi=Ni.splice,Xi=Hi?Hi.isConcatSpreadable:I,Ji=Hi?Hi.iterator:I,Qi=Hi?Hi.toStringTag:I,eo=function(){try{var e=tr(Si,"defineProperty");return e({},"",{}),e}catch(t){}}(),to=t.clearTimeout!==qe.clearTimeout&&t.clearTimeout,no=Ci&&Ci.now!==qe.Date.now&&Ci.now,ro=t.setTimeout!==qe.setTimeout&&t.setTimeout,io=Ai.ceil,oo=Ai.floor,ao=Si.getOwnPropertySymbols,so=Wi?Wi.isBuffer:I,lo=t.isFinite,uo=Ni.join,co=L(Si.keys,Si),fo=Ai.max,po=Ai.min,ho=Ci.now,go=t.parseInt,mo=Ai.random,vo=Ni.reverse,yo=tr(t,"DataView"),bo=tr(t,"Map"),_o=tr(t,"Promise"),wo=tr(t,"Set"),xo=tr(t,"WeakMap"),ko=tr(Si,"create"),Co=xo&&new xo,Eo={},Oo=vr(yo),Ao=vr(bo),So=vr(_o),jo=vr(wo),To=vr(xo),Do=Hi?Hi.prototype:I,No=Do?Do.valueOf:I,Lo=Do?Do.toString:I,Mo=function(){function e(){}return function(t){return Vr(t)?Yi?Yi(t):(e.prototype=t,t=new e,e.prototype=I,t):{}}}();x.templateSettings={escape:G,evaluate:Z,interpolate:X,variable:"",imports:{_:x}},x.prototype=we.prototype,x.prototype.constructor=x,xe.prototype=Mo(we.prototype),xe.prototype.constructor=xe,Ee.prototype=Mo(we.prototype),Ee.prototype.constructor=Ee,Ne.prototype.clear=function(){this.__data__=ko?ko(null):{},this.size=0},Ne.prototype.delete=function(e){return e=this.has(e)&&delete this.__data__[e],this.size-=e?1:0,e},Ne.prototype.get=function(e){var t=this.__data__;return ko?"__lodash_hash_undefined__"===(e=t[e])?I:e:Fi.call(t,e)?t[e]:I},Ne.prototype.has=function(e){var t=this.__data__;return ko?t[e]!==I:Fi.call(t,e)},Ne.prototype.set=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=ko&&t===I?"__lodash_hash_undefined__":t,this},Pe.prototype.clear=function(){this.__data__=[],this.size=0},Pe.prototype.delete=function(e){var t=this.__data__;return!(0>(e=rt(t,e))||(e==t.length-1?t.pop():Zi.call(t,e,1),--this.size,0))},Pe.prototype.get=function(e){var t=this.__data__;return 0>(e=rt(t,e))?I:t[e][1]},Pe.prototype.has=function(e){return-1<rt(this.__data__,e)},Pe.prototype.set=function(e,t){var n=this.__data__,r=rt(n,e);return 0>r?(++this.size,n.push([e,t])):n[r][1]=t,this},Fe.prototype.clear=function(){this.size=0,this.__data__={hash:new Ne,map:new(bo||Pe),string:new Ne}},Fe.prototype.delete=function(e){return e=Qn(this,e).delete(e),this.size-=e?1:0,e},Fe.prototype.get=function(e){return Qn(this,e).get(e)},Fe.prototype.has=function(e){return Qn(this,e).has(e)},Fe.prototype.set=function(e,t){var n=Qn(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this},Ie.prototype.add=Ie.prototype.push=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this},Ie.prototype.has=function(e){return this.__data__.has(e)},$e.prototype.clear=function(){this.__data__=new Pe,this.size=0},$e.prototype.delete=function(e){var t=this.__data__;return e=t.delete(e),this.size=t.size,e},$e.prototype.get=function(e){return this.__data__.get(e)},$e.prototype.has=function(e){return this.__data__.has(e)},$e.prototype.set=function(e,t){var n=this.__data__;if(n instanceof Pe){var r=n.__data__;if(!bo||199>r.length)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new Fe(r)}return n.set(e,t),this.size=n.size,this};var Po=En(vt),Fo=En(yt,!0),qo=On(),Io=On(!0),$o=Co?function(e,t){return Co.set(e,t),e}:gi,Ro=eo?function(e,t){return eo(e,"toString",{configurable:!0,enumerable:!1,value:hi(t),writable:!0})}:gi,zo=to||function(e){return qe.clearTimeout(e)},Bo=wo&&1/P(new wo([,-0]))[1]==$?function(e){return new wo(e)}:yi,Wo=Co?function(e){return Co.get(e)}:yi,Ho=ao?function(e){return null==e?[]:(e=Si(e),s(ao(e),(function(t){return Gi.call(e,t)})))}:_i,Uo=ao?function(e){for(var t=[];e;)f(t,Ho(e)),e=Ki(e);return t}:_i,Vo=xt;(yo&&"[object DataView]"!=Vo(new yo(new ArrayBuffer(1)))||bo&&"[object Map]"!=Vo(new bo)||_o&&"[object Promise]"!=Vo(_o.resolve())||wo&&"[object Set]"!=Vo(new wo)||xo&&"[object WeakMap]"!=Vo(new xo))&&(Vo=function(e){var t=xt(e);if(e=(e="[object Object]"==t?e.constructor:I)?vr(e):"")switch(e){case Oo:return"[object DataView]";case Ao:return"[object Map]";case So:return"[object Promise]";case jo:return"[object Set]";case To:return"[object WeakMap]"}return t});var Ko=Mi?Wr:wi,Yo=hr($o),Go=ro||function(e,t){return qe.setTimeout(e,t)},Zo=hr(Ro),Xo=function(e){var t=(e=qr(e,(function(e){return 500===t.size&&t.clear(),e}))).cache;return e}((function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(ee,(function(e,n,r,i){t.push(r?i.replace(ce,"$1"):n||e)})),t})),Jo=Vt((function(e,t){return zr(e)?pt(e,mt(t,1,zr,!0)):[]})),Qo=Vt((function(e,t){var n=Cr(t);return zr(n)&&(n=I),zr(e)?pt(e,mt(t,1,zr,!0),Jn(n,2)):[]})),ea=Vt((function(e,t){var n=Cr(t);return zr(n)&&(n=I),zr(e)?pt(e,mt(t,1,zr,!0),I,n):[]})),ta=Vt((function(e){var t=c(e,fn);return t.length&&t[0]===e[0]?Ot(t):[]})),na=Vt((function(e){var t=Cr(e),n=c(e,fn);return t===Cr(n)?t=I:n.pop(),n.length&&n[0]===e[0]?Ot(n,Jn(t,2)):[]})),ra=Vt((function(e){var t=Cr(e),n=c(e,fn);return(t="function"==typeof t?t:I)&&n.pop(),n.length&&n[0]===e[0]?Ot(n,I,t):[]})),ia=Vt(Er),oa=Kn((function(e,t){var n=null==e?0:e.length,r=st(e,t);return Wt(e,c(t,(function(e){return or(e,n)?+e:e})).sort(yn)),r})),aa=Vt((function(e){return on(mt(e,1,zr,!0))})),sa=Vt((function(e){var t=Cr(e);return zr(t)&&(t=I),on(mt(e,1,zr,!0),Jn(t,2))})),la=Vt((function(e){var t="function"==typeof(t=Cr(e))?t:I;return on(mt(e,1,zr,!0),I,t)})),ua=Vt((function(e,t){return zr(e)?pt(e,t):[]})),ca=Vt((function(e){return un(s(e,zr))})),fa=Vt((function(e){var t=Cr(e);return zr(t)&&(t=I),un(s(e,zr),Jn(t,2))})),pa=Vt((function(e){var t="function"==typeof(t=Cr(e))?t:I;return un(s(e,zr),I,t)})),da=Vt(Ar),ha=Vt((function(e){var t="function"==typeof(t=1<(t=e.length)?e[t-1]:I)?(e.pop(),t):I;return Sr(e,t)})),ga=Kn((function(e){function t(t){return st(t,e)}var n=e.length,r=n?e[0]:0,i=this.__wrapped__;return!(1<n||this.__actions__.length)&&i instanceof Ee&&or(r)?((i=i.slice(r,+r+(n?1:0))).__actions__.push({func:Tr,args:[t],thisArg:I}),new xe(i,this.__chain__).thru((function(e){return n&&!e.length&&e.push(I),e}))):this.thru(t)})),ma=kn((function(e,t,n){Fi.call(e,n)?++e[n]:at(e,n,1)})),va=Tn(_r),ya=Tn(wr),ba=kn((function(e,t,n){Fi.call(e,n)?e[n].push(t):at(e,n,[t])})),_a=Vt((function(e,t,r){var i=-1,o="function"==typeof t,a=Rr(e)?ki(e.length):[];return Po(e,(function(e){a[++i]=o?n(t,e,r):At(e,t,r)})),a})),wa=kn((function(e,t,n){at(e,n,t)})),xa=kn((function(e,t,n){e[n?0:1].push(t)}),(function(){return[[],[]]})),ka=Vt((function(e,t){if(null==e)return[];var n=t.length;return 1<n&&ar(e,t[0],t[1])?t=[]:2<n&&ar(t[0],t[1],t[2])&&(t=[t[0]]),Rt(e,mt(t,1),[])})),Ca=no||function(){return qe.Date.now()},Ea=Vt((function(e,t,n){var r=1;if(n.length){var i=M(n,Xn(Ea));r=32|r}return Bn(e,r,t,n,i)})),Oa=Vt((function(e,t,n){var r=3;if(n.length){var i=M(n,Xn(Oa));r=32|r}return Bn(t,r,e,n,i)})),Aa=Vt((function(e,t){return ft(e,1,t)})),Sa=Vt((function(e,t,n){return ft(e,ni(t)||0,n)}));qr.Cache=Fe;var ja=Vt((function(e,t){var r=(t=1==t.length&&Fa(t[0])?c(t[0],O(Jn())):c(mt(t,1),O(Jn()))).length;return Vt((function(i){for(var o=-1,a=po(i.length,r);++o<a;)i[o]=t[o].call(this,i[o]);return n(e,this,i)}))})),Ta=Vt((function(e,t){return Bn(e,32,I,t,M(t,Xn(Ta)))})),Da=Vt((function(e,t){return Bn(e,64,I,t,M(t,Xn(Da)))})),Na=Kn((function(e,t){return Bn(e,256,I,I,I,t)})),La=In(kt),Ma=In((function(e,t){return e>=t})),Pa=St(function(){return arguments}())?St:function(e){return Kr(e)&&Fi.call(e,"callee")&&!Gi.call(e,"callee")},Fa=ki.isArray,qa=We?O(We):function(e){return Kr(e)&&"[object ArrayBuffer]"==xt(e)},Ia=so||wi,$a=He?O(He):function(e){return Kr(e)&&"[object Date]"==xt(e)},Ra=Ue?O(Ue):function(e){return Kr(e)&&"[object Map]"==Vo(e)},za=Ve?O(Ve):function(e){return Kr(e)&&"[object RegExp]"==xt(e)},Ba=Ke?O(Ke):function(e){return Kr(e)&&"[object Set]"==Vo(e)},Wa=Ye?O(Ye):function(e){return Kr(e)&&Ur(e.length)&&!!Te[xt(e)]},Ha=In(Mt),Ua=In((function(e,t){return e<=t})),Va=Cn((function(e,t){if(ur(t)||Rr(t))xn(t,si(t),e);else for(var n in t)Fi.call(t,n)&&nt(e,n,t[n])})),Ka=Cn((function(e,t){xn(t,li(t),e)})),Ya=Cn((function(e,t,n,r){xn(t,li(t),e,r)})),Ga=Cn((function(e,t,n,r){xn(t,si(t),e,r)})),Za=Kn(st),Xa=Vt((function(e,t){e=Si(e);var n=-1,r=t.length;for((i=2<r?t[2]:I)&&ar(t[0],t[1],i)&&(r=1);++n<r;)for(var i,o=li(i=t[n]),a=-1,s=o.length;++a<s;){var l=o[a],u=e[l];(u===I||$r(u,Li[l])&&!Fi.call(e,l))&&(e[l]=i[l])}return e})),Ja=Vt((function(e){return e.push(I,Hn),n(rs,I,e)})),Qa=Ln((function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=$i.call(t)),e[t]=n}),hi(gi)),es=Ln((function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=$i.call(t)),Fi.call(e,t)?e[t].push(n):e[t]=[n]}),Jn),ts=Vt(At),ns=Cn((function(e,t,n){It(e,t,n)})),rs=Cn((function(e,t,n,r){It(e,t,n,r)})),is=Kn((function(e,t){var n={};if(null==e)return n;var r=!1;t=c(t,(function(t){return t=dn(t,e),r||(r=1<t.length),t})),xn(e,Gn(e),n),r&&(n=ut(n,7,Un));for(var i=t.length;i--;)an(n,t[i]);return n})),os=Kn((function(e,t){return null==e?{}:function(e,t){return zt(e,t,(function(t,n){return ai(e,n)}))}(e,t)})),as=zn(si),ss=zn(li),ls=Sn((function(e,t,n){return t=t.toLowerCase(),e+(n?fi(t):t)})),us=Sn((function(e,t,n){return e+(n?"-":"")+t.toLowerCase()})),cs=Sn((function(e,t,n){return e+(n?" ":"")+t.toLowerCase()})),fs=An("toLowerCase"),ps=Sn((function(e,t,n){return e+(n?"_":"")+t.toLowerCase()})),ds=Sn((function(e,t,n){return e+(n?" ":"")+gs(t)})),hs=Sn((function(e,t,n){return e+(n?" ":"")+t.toUpperCase()})),gs=An("toUpperCase"),ms=Vt((function(e,t){try{return n(e,I,t)}catch(xi){return Br(xi)?xi:new Ei(xi)}})),vs=Kn((function(e,t){return i(t,(function(t){t=mr(t),at(e,t,Ea(e[t],e))})),e})),ys=Dn(),bs=Dn(!0),_s=Vt((function(e,t){return function(n){return At(n,e,t)}})),ws=Vt((function(e,t){return function(n){return At(e,n,t)}})),xs=Pn(c),ks=Pn(a),Cs=Pn(h),Es=qn(),Os=qn(!0),As=Mn((function(e,t){return e+t}),0),Ss=Rn("ceil"),js=Mn((function(e,t){return e/t}),1),Ts=Rn("floor"),Ds=Mn((function(e,t){return e*t}),1),Ns=Rn("round"),Ls=Mn((function(e,t){return e-t}),0);return x.after=function(e,t){if("function"!=typeof t)throw new Di("Expected a function");return e=ei(e),function(){if(1>--e)return t.apply(this,arguments)}},x.ary=Mr,x.assign=Va,x.assignIn=Ka,x.assignInWith=Ya,x.assignWith=Ga,x.at=Za,x.before=Pr,x.bind=Ea,x.bindAll=vs,x.bindKey=Oa,x.castArray=function(){if(!arguments.length)return[];var e=arguments[0];return Fa(e)?e:[e]},x.chain=jr,x.chunk=function(e,t,n){if(t=(n?ar(e,t,n):t===I)?1:fo(ei(t),0),!(n=null==e?0:e.length)||1>t)return[];for(var r=0,i=0,o=ki(io(n/t));r<n;)o[i++]=Xt(e,r,r+=t);return o},x.compact=function(e){for(var t=-1,n=null==e?0:e.length,r=0,i=[];++t<n;){var o=e[t];o&&(i[r++]=o)}return i},x.concat=function(){var e=arguments.length;if(!e)return[];for(var t=ki(e-1),n=arguments[0];e--;)t[e-1]=arguments[e];return f(Fa(n)?wn(n):[n],mt(t,1))},x.cond=function(e){var t=null==e?0:e.length,r=Jn();return e=t?c(e,(function(e){if("function"!=typeof e[1])throw new Di("Expected a function");return[r(e[0]),e[1]]})):[],Vt((function(r){for(var i=-1;++i<t;){var o=e[i];if(n(o[0],this,r))return n(o[1],this,r)}}))},x.conforms=function(e){return function(e){var t=si(e);return function(n){return ct(n,e,t)}}(ut(e,1))},x.constant=hi,x.countBy=ma,x.create=function(e,t){var n=Mo(e);return null==t?n:ot(n,t)},x.curry=function e(t,n,r){return(t=Bn(t,8,I,I,I,I,I,n=r?I:n)).placeholder=e.placeholder,t},x.curryRight=function e(t,n,r){return(t=Bn(t,16,I,I,I,I,I,n=r?I:n)).placeholder=e.placeholder,t},x.debounce=Fr,x.defaults=Xa,x.defaultsDeep=Ja,x.defer=Aa,x.delay=Sa,x.difference=Jo,x.differenceBy=Qo,x.differenceWith=ea,x.drop=function(e,t,n){var r=null==e?0:e.length;return r?Xt(e,0>(t=n||t===I?1:ei(t))?0:t,r):[]},x.dropRight=function(e,t,n){var r=null==e?0:e.length;return r?Xt(e,0,0>(t=r-(t=n||t===I?1:ei(t)))?0:t):[]},x.dropRightWhile=function(e,t){return e&&e.length?sn(e,Jn(t,3),!0,!0):[]},x.dropWhile=function(e,t){return e&&e.length?sn(e,Jn(t,3),!0):[]},x.fill=function(e,t,n,r){var i=null==e?0:e.length;if(!i)return[];for(n&&"number"!=typeof n&&ar(e,t,n)&&(n=0,r=i),i=e.length,0>(n=ei(n))&&(n=-n>i?0:i+n),0>(r=r===I||r>i?i:ei(r))&&(r+=i),r=n>r?0:ti(r);n<r;)e[n++]=t;return e},x.filter=function(e,t){return(Fa(e)?s:gt)(e,Jn(t,3))},x.flatMap=function(e,t){return mt(Lr(e,t),1)},x.flatMapDeep=function(e,t){return mt(Lr(e,t),$)},x.flatMapDepth=function(e,t,n){return n=n===I?1:ei(n),mt(Lr(e,t),n)},x.flatten=xr,x.flattenDeep=function(e){return null!=e&&e.length?mt(e,$):[]},x.flattenDepth=function(e,t){return null!=e&&e.length?mt(e,t=t===I?1:ei(t)):[]},x.flip=function(e){return Bn(e,512)},x.flow=ys,x.flowRight=bs,x.fromPairs=function(e){for(var t=-1,n=null==e?0:e.length,r={};++t<n;){var i=e[t];r[i[0]]=i[1]}return r},x.functions=function(e){return null==e?[]:bt(e,si(e))},x.functionsIn=function(e){return null==e?[]:bt(e,li(e))},x.groupBy=ba,x.initial=function(e){return null!=e&&e.length?Xt(e,0,-1):[]},x.intersection=ta,x.intersectionBy=na,x.intersectionWith=ra,x.invert=Qa,x.invertBy=es,x.invokeMap=_a,x.iteratee=mi,x.keyBy=wa,x.keys=si,x.keysIn=li,x.map=Lr,x.mapKeys=function(e,t){var n={};return t=Jn(t,3),vt(e,(function(e,r,i){at(n,t(e,r,i),e)})),n},x.mapValues=function(e,t){var n={};return t=Jn(t,3),vt(e,(function(e,r,i){at(n,r,t(e,r,i))})),n},x.matches=function(e){return Ft(ut(e,1))},x.matchesProperty=function(e,t){return qt(e,ut(t,1))},x.memoize=qr,x.merge=ns,x.mergeWith=rs,x.method=_s,x.methodOf=ws,x.mixin=vi,x.negate=Ir,x.nthArg=function(e){return e=ei(e),Vt((function(t){return $t(t,e)}))},x.omit=is,x.omitBy=function(e,t){return ui(e,Ir(Jn(t)))},x.once=function(e){return Pr(2,e)},x.orderBy=function(e,t,n,r){return null==e?[]:(Fa(t)||(t=null==t?[]:[t]),Fa(n=r?I:n)||(n=null==n?[]:[n]),Rt(e,t,n))},x.over=xs,x.overArgs=ja,x.overEvery=ks,x.overSome=Cs,x.partial=Ta,x.partialRight=Da,x.partition=xa,x.pick=os,x.pickBy=ui,x.property=bi,x.propertyOf=function(e){return function(t){return null==e?I:_t(e,t)}},x.pull=ia,x.pullAll=Er,x.pullAllBy=function(e,t,n){return e&&e.length&&t&&t.length?Bt(e,t,Jn(n,2)):e},x.pullAllWith=function(e,t,n){return e&&e.length&&t&&t.length?Bt(e,t,I,n):e},x.pullAt=oa,x.range=Es,x.rangeRight=Os,x.rearg=Na,x.reject=function(e,t){return(Fa(e)?s:gt)(e,Ir(Jn(t,3)))},x.remove=function(e,t){var n=[];if(!e||!e.length)return n;var r=-1,i=[],o=e.length;for(t=Jn(t,3);++r<o;){var a=e[r];t(a,r,e)&&(n.push(a),i.push(r))}return Wt(e,i),n},x.rest=function(e,t){if("function"!=typeof e)throw new Di("Expected a function");return Vt(e,t=t===I?t:ei(t))},x.reverse=Or,x.sampleSize=function(e,t,n){return t=(n?ar(e,t,n):t===I)?1:ei(t),(Fa(e)?Ge:Yt)(e,t)},x.set=function(e,t,n){return null==e?e:Gt(e,t,n)},x.setWith=function(e,t,n,r){return r="function"==typeof r?r:I,null==e?e:Gt(e,t,n,r)},x.shuffle=function(e){return(Fa(e)?et:Zt)(e)},x.slice=function(e,t,n){var r=null==e?0:e.length;return r?(n&&"number"!=typeof n&&ar(e,t,n)?(t=0,n=r):(t=null==t?0:ei(t),n=n===I?r:ei(n)),Xt(e,t,n)):[]},x.sortBy=ka,x.sortedUniq=function(e){return e&&e.length?tn(e):[]},x.sortedUniqBy=function(e,t){return e&&e.length?tn(e,Jn(t,2)):[]},x.split=function(e,t,n){return n&&"number"!=typeof n&&ar(e,t,n)&&(t=n=I),(n=n===I?4294967295:n>>>0)?(e=ii(e))&&("string"==typeof t||null!=t&&!za(t))&&(!(t=rn(t))&&Ae.test(e))?hn(q(e),0,n):e.split(t,n):[]},x.spread=function(e,t){if("function"!=typeof e)throw new Di("Expected a function");return t=null==t?0:fo(ei(t),0),Vt((function(r){var i=r[t];return r=hn(r,0,t),i&&f(r,i),n(e,this,r)}))},x.tail=function(e){var t=null==e?0:e.length;return t?Xt(e,1,t):[]},x.take=function(e,t,n){return e&&e.length?Xt(e,0,0>(t=n||t===I?1:ei(t))?0:t):[]},x.takeRight=function(e,t,n){var r=null==e?0:e.length;return r?Xt(e,0>(t=r-(t=n||t===I?1:ei(t)))?0:t,r):[]},x.takeRightWhile=function(e,t){return e&&e.length?sn(e,Jn(t,3),!1,!0):[]},x.takeWhile=function(e,t){return e&&e.length?sn(e,Jn(t,3)):[]},x.tap=function(e,t){return t(e),e},x.throttle=function(e,t,n){var r=!0,i=!0;if("function"!=typeof e)throw new Di("Expected a function");return Vr(n)&&(r="leading"in n?!!n.leading:r,i="trailing"in n?!!n.trailing:i),Fr(e,t,{leading:r,maxWait:t,trailing:i})},x.thru=Tr,x.toArray=Jr,x.toPairs=as,x.toPairsIn=ss,x.toPath=function(e){return Fa(e)?c(e,mr):Xr(e)?[e]:wn(Xo(ii(e)))},x.toPlainObject=ri,x.transform=function(e,t,n){var r=Fa(e),o=r||Ia(e)||Wa(e);if(t=Jn(t,4),null==n){var a=e&&e.constructor;n=o?r?new a:[]:Vr(e)&&Wr(a)?Mo(Ki(e)):{}}return(o?i:vt)(e,(function(e,r,i){return t(n,e,r,i)})),n},x.unary=function(e){return Mr(e,1)},x.union=aa,x.unionBy=sa,x.unionWith=la,x.uniq=function(e){return e&&e.length?on(e):[]},x.uniqBy=function(e,t){return e&&e.length?on(e,Jn(t,2)):[]},x.uniqWith=function(e,t){return t="function"==typeof t?t:I,e&&e.length?on(e,I,t):[]},x.unset=function(e,t){return null==e||an(e,t)},x.unzip=Ar,x.unzipWith=Sr,x.update=function(e,t,n){return null==e?e:Gt(e,t,pn(n)(_t(e,t)),void 0)},x.updateWith=function(e,t,n,r){return r="function"==typeof r?r:I,null!=e&&(e=Gt(e,t,pn(n)(_t(e,t)),r)),e},x.values=ci,x.valuesIn=function(e){return null==e?[]:A(e,li(e))},x.without=ua,x.words=di,x.wrap=function(e,t){return Ta(pn(t),e)},x.xor=ca,x.xorBy=fa,x.xorWith=pa,x.zip=da,x.zipObject=function(e,t){return cn(e||[],t||[],nt)},x.zipObjectDeep=function(e,t){return cn(e||[],t||[],Gt)},x.zipWith=ha,x.entries=as,x.entriesIn=ss,x.extend=Ka,x.extendWith=Ya,vi(x,x),x.add=As,x.attempt=ms,x.camelCase=ls,x.capitalize=fi,x.ceil=Ss,x.clamp=function(e,t,n){return n===I&&(n=t,t=I),n!==I&&(n=(n=ni(n))==n?n:0),t!==I&&(t=(t=ni(t))==t?t:0),lt(ni(e),t,n)},x.clone=function(e){return ut(e,4)},x.cloneDeep=function(e){return ut(e,5)},x.cloneDeepWith=function(e,t){return ut(e,5,t="function"==typeof t?t:I)},x.cloneWith=function(e,t){return ut(e,4,t="function"==typeof t?t:I)},x.conformsTo=function(e,t){return null==t||ct(e,t,si(t))},x.deburr=pi,x.defaultTo=function(e,t){return null==e||e!=e?t:e},x.divide=js,x.endsWith=function(e,t,n){e=ii(e),t=rn(t);var r=e.length;r=n=n===I?r:lt(ei(n),0,r);return 0<=(n-=t.length)&&e.slice(n,r)==t},x.eq=$r,x.escape=function(e){return(e=ii(e))&&Y.test(e)?e.replace(V,Xe):e},x.escapeRegExp=function(e){return(e=ii(e))&&ne.test(e)?e.replace(te,"\\$&"):e},x.every=function(e,t,n){var r=Fa(e)?a:dt;return n&&ar(e,t,n)&&(t=I),r(e,Jn(t,3))},x.find=va,x.findIndex=_r,x.findKey=function(e,t){return g(e,Jn(t,3),vt)},x.findLast=ya,x.findLastIndex=wr,x.findLastKey=function(e,t){return g(e,Jn(t,3),yt)},x.floor=Ts,x.forEach=Dr,x.forEachRight=Nr,x.forIn=function(e,t){return null==e?e:qo(e,Jn(t,3),li)},x.forInRight=function(e,t){return null==e?e:Io(e,Jn(t,3),li)},x.forOwn=function(e,t){return e&&vt(e,Jn(t,3))},x.forOwnRight=function(e,t){return e&&yt(e,Jn(t,3))},x.get=oi,x.gt=La,x.gte=Ma,x.has=function(e,t){return null!=e&&nr(e,t,Ct)},x.hasIn=ai,x.head=kr,x.identity=gi,x.includes=function(e,t,n,r){return e=Rr(e)?e:ci(e),n=n&&!r?ei(n):0,r=e.length,0>n&&(n=fo(r+n,0)),Zr(e)?n<=r&&-1<e.indexOf(t,n):!!r&&-1<v(e,t,n)},x.indexOf=function(e,t,n){var r=null==e?0:e.length;return r?(0>(n=null==n?0:ei(n))&&(n=fo(r+n,0)),v(e,t,n)):-1},x.inRange=function(e,t,n){return t=Qr(t),n===I?(n=t,t=0):n=Qr(n),(e=ni(e))>=po(t,n)&&e<fo(t,n)},x.invoke=ts,x.isArguments=Pa,x.isArray=Fa,x.isArrayBuffer=qa,x.isArrayLike=Rr,x.isArrayLikeObject=zr,x.isBoolean=function(e){return!0===e||!1===e||Kr(e)&&"[object Boolean]"==xt(e)},x.isBuffer=Ia,x.isDate=$a,x.isElement=function(e){return Kr(e)&&1===e.nodeType&&!Gr(e)},x.isEmpty=function(e){if(null==e)return!0;if(Rr(e)&&(Fa(e)||"string"==typeof e||"function"==typeof e.splice||Ia(e)||Wa(e)||Pa(e)))return!e.length;var t=Vo(e);if("[object Map]"==t||"[object Set]"==t)return!e.size;if(ur(e))return!Lt(e).length;for(var n in e)if(Fi.call(e,n))return!1;return!0},x.isEqual=function(e,t){return jt(e,t)},x.isEqualWith=function(e,t,n){var r=(n="function"==typeof n?n:I)?n(e,t):I;return r===I?jt(e,t,I,n):!!r},x.isError=Br,x.isFinite=function(e){return"number"==typeof e&&lo(e)},x.isFunction=Wr,x.isInteger=Hr,x.isLength=Ur,x.isMap=Ra,x.isMatch=function(e,t){return e===t||Tt(e,t,er(t))},x.isMatchWith=function(e,t,n){return n="function"==typeof n?n:I,Tt(e,t,er(t),n)},x.isNaN=function(e){return Yr(e)&&e!=+e},x.isNative=function(e){if(Ko(e))throw new Ei("Unsupported core-js use. Try https://npms.io/search?q=ponyfill.");return Dt(e)},x.isNil=function(e){return null==e},x.isNull=function(e){return null===e},x.isNumber=Yr,x.isObject=Vr,x.isObjectLike=Kr,x.isPlainObject=Gr,x.isRegExp=za,x.isSafeInteger=function(e){return Hr(e)&&-9007199254740991<=e&&9007199254740991>=e},x.isSet=Ba,x.isString=Zr,x.isSymbol=Xr,x.isTypedArray=Wa,x.isUndefined=function(e){return e===I},x.isWeakMap=function(e){return Kr(e)&&"[object WeakMap]"==Vo(e)},x.isWeakSet=function(e){return Kr(e)&&"[object WeakSet]"==xt(e)},x.join=function(e,t){return null==e?"":uo.call(e,t)},x.kebabCase=us,x.last=Cr,x.lastIndexOf=function(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var i=r;if(n!==I&&(i=0>(i=ei(n))?fo(r+i,0):po(i,r-1)),t==t){for(n=i+1;n--&&e[n]!==t;);e=n}else e=m(e,b,i,!0);return e},x.lowerCase=cs,x.lowerFirst=fs,x.lt=Ha,x.lte=Ua,x.max=function(e){return e&&e.length?ht(e,gi,kt):I},x.maxBy=function(e,t){return e&&e.length?ht(e,Jn(t,2),kt):I},x.mean=function(e){return _(e,gi)},x.meanBy=function(e,t){return _(e,Jn(t,2))},x.min=function(e){return e&&e.length?ht(e,gi,Mt):I},x.minBy=function(e,t){return e&&e.length?ht(e,Jn(t,2),Mt):I},x.stubArray=_i,x.stubFalse=wi,x.stubObject=function(){return{}},x.stubString=function(){return""},x.stubTrue=function(){return!0},x.multiply=Ds,x.nth=function(e,t){return e&&e.length?$t(e,ei(t)):I},x.noConflict=function(){return qe._===this&&(qe._=zi),this},x.noop=yi,x.now=Ca,x.pad=function(e,t,n){e=ii(e);var r=(t=ei(t))?F(e):0;return!t||r>=t?e:Fn(oo(t=(t-r)/2),n)+e+Fn(io(t),n)},x.padEnd=function(e,t,n){e=ii(e);var r=(t=ei(t))?F(e):0;return t&&r<t?e+Fn(t-r,n):e},x.padStart=function(e,t,n){e=ii(e);var r=(t=ei(t))?F(e):0;return t&&r<t?Fn(t-r,n)+e:e},x.parseInt=function(e,t,n){return n||null==t?t=0:t&&(t=+t),go(ii(e).replace(ie,""),t||0)},x.random=function(e,t,n){if(n&&"boolean"!=typeof n&&ar(e,t,n)&&(t=n=I),n===I&&("boolean"==typeof t?(n=t,t=I):"boolean"==typeof e&&(n=e,e=I)),e===I&&t===I?(e=0,t=1):(e=Qr(e),t===I?(t=e,e=0):t=Qr(t)),e>t){var r=e;e=t,t=r}return n||e%1||t%1?(n=mo(),po(e+n*(t-e+Le("1e-"+((n+"").length-1))),t)):Ht(e,t)},x.reduce=function(e,t,n){var r=Fa(e)?p:k,i=3>arguments.length;return r(e,Jn(t,4),n,i,Po)},x.reduceRight=function(e,t,n){var r=Fa(e)?d:k,i=3>arguments.length;return r(e,Jn(t,4),n,i,Fo)},x.repeat=function(e,t,n){return t=(n?ar(e,t,n):t===I)?1:ei(t),Ut(ii(e),t)},x.replace=function(){var e=arguments,t=ii(e[0]);return 3>e.length?t:t.replace(e[1],e[2])},x.result=function(e,t,n){var r=-1,i=(t=dn(t,e)).length;for(i||(i=1,e=I);++r<i;){var o=null==e?I:e[mr(t[r])];o===I&&(r=i,o=n),e=Wr(o)?o.call(e):o}return e},x.round=Ns,x.runInContext=e,x.sample=function(e){return(Fa(e)?Be:Kt)(e)},x.size=function(e){if(null==e)return 0;if(Rr(e))return Zr(e)?F(e):e.length;var t=Vo(e);return"[object Map]"==t||"[object Set]"==t?e.size:Lt(e).length},x.snakeCase=ps,x.some=function(e,t,n){var r=Fa(e)?h:Jt;return n&&ar(e,t,n)&&(t=I),r(e,Jn(t,3))},x.sortedIndex=function(e,t){return Qt(e,t)},x.sortedIndexBy=function(e,t,n){return en(e,t,Jn(n,2))},x.sortedIndexOf=function(e,t){var n=null==e?0:e.length;if(n){var r=Qt(e,t);if(r<n&&$r(e[r],t))return r}return-1},x.sortedLastIndex=function(e,t){return Qt(e,t,!0)},x.sortedLastIndexBy=function(e,t,n){return en(e,t,Jn(n,2),!0)},x.sortedLastIndexOf=function(e,t){if(null!=e&&e.length){var n=Qt(e,t,!0)-1;if($r(e[n],t))return n}return-1},x.startCase=ds,x.startsWith=function(e,t,n){return e=ii(e),n=null==n?0:lt(ei(n),0,e.length),t=rn(t),e.slice(n,n+t.length)==t},x.subtract=Ls,x.sum=function(e){return e&&e.length?C(e,gi):0},x.sumBy=function(e,t){return e&&e.length?C(e,Jn(t,2)):0},x.template=function(e,t,n){var r=x.templateSettings;n&&ar(e,t,n)&&(t=I),e=ii(e),t=Ya({},t,r,Wn);var i,o,a=si(n=Ya({},t.imports,r.imports,Wn)),s=A(n,a),l=0;n=t.interpolate||be;var u="__p+='";n=ji((t.escape||be).source+"|"+n.source+"|"+(n===X?fe:be).source+"|"+(t.evaluate||be).source+"|$","g");var c=Fi.call(t,"sourceURL")?"//# sourceURL="+(t.sourceURL+"").replace(/[\r\n]/g," ")+"\n":"";if(e.replace(n,(function(t,n,r,a,s,c){return r||(r=a),u+=e.slice(l,c).replace(_e,D),n&&(i=!0,u+="'+__e("+n+")+'"),s&&(o=!0,u+="';"+s+";\n__p+='"),r&&(u+="'+((__t=("+r+"))==null?'':__t)+'"),l=c+t.length,t})),u+="';",(t=Fi.call(t,"variable")&&t.variable)||(u="with(obj){"+u+"}"),u=(o?u.replace(B,""):u).replace(W,"$1").replace(H,"$1;"),u="function("+(t||"obj")+"){"+(t?"":"obj||(obj={});")+"var __t,__p=''"+(i?",__e=_.escape":"")+(o?",__j=Array.prototype.join;function print(){__p+=__j.call(arguments,'')}":";")+u+"return __p}",(t=ms((function(){return Oi(a,c+"return "+u).apply(I,s)}))).source=u,Br(t))throw t;return t},x.times=function(e,t){if(1>(e=ei(e))||9007199254740991<e)return[];var n=4294967295,r=po(e,4294967295);for(e-=4294967295,r=E(r,t=Jn(t));++n<e;)t(n);return r},x.toFinite=Qr,x.toInteger=ei,x.toLength=ti,x.toLower=function(e){return ii(e).toLowerCase()},x.toNumber=ni,x.toSafeInteger=function(e){return e?lt(ei(e),-9007199254740991,9007199254740991):0===e?e:0},x.toString=ii,x.toUpper=function(e){return ii(e).toUpperCase()},x.trim=function(e,t,n){return(e=ii(e))&&(n||t===I)?e.replace(re,""):e&&(t=rn(t))?hn(e=q(e),t=j(e,n=q(t)),n=T(e,n)+1).join(""):e},x.trimEnd=function(e,t,n){return(e=ii(e))&&(n||t===I)?e.replace(oe,""):e&&(t=rn(t))?hn(e=q(e),0,t=T(e,q(t))+1).join(""):e},x.trimStart=function(e,t,n){return(e=ii(e))&&(n||t===I)?e.replace(ie,""):e&&(t=rn(t))?hn(e=q(e),t=j(e,q(t))).join(""):e},x.truncate=function(e,t){var n=30,r="...";if(Vr(t)){var i="separator"in t?t.separator:i;n="length"in t?ei(t.length):n,r="omission"in t?rn(t.omission):r}var o=(e=ii(e)).length;if(Ae.test(e)){var a=q(e);o=a.length}if(n>=o)return e;if(1>(o=n-F(r)))return r;if(n=a?hn(a,0,o).join(""):e.slice(0,o),i===I)return n+r;if(a&&(o+=n.length-o),za(i)){if(e.slice(o).search(i)){var s=n;for(i.global||(i=ji(i.source,ii(pe.exec(i))+"g")),i.lastIndex=0;a=i.exec(s);)var l=a.index;n=n.slice(0,l===I?o:l)}}else e.indexOf(rn(i),o)!=o&&(-1<(i=n.lastIndexOf(i))&&(n=n.slice(0,i)));return n+r},x.unescape=function(e){return(e=ii(e))&&K.test(e)?e.replace(U,Je):e},x.uniqueId=function(e){var t=++qi;return ii(e)+t},x.upperCase=hs,x.upperFirst=gs,x.each=Dr,x.eachRight=Nr,x.first=kr,vi(x,function(){var e={};return vt(x,(function(t,n){Fi.call(x.prototype,n)||(e[n]=t)})),e}(),{chain:!1}),x.VERSION="4.17.13",i("bind bindKey curry curryRight partial partialRight".split(" "),(function(e){x[e].placeholder=x})),i(["drop","take"],(function(e,t){Ee.prototype[e]=function(n){n=n===I?1:fo(ei(n),0);var r=this.__filtered__&&!t?new Ee(this):this.clone();return r.__filtered__?r.__takeCount__=po(n,r.__takeCount__):r.__views__.push({size:po(n,4294967295),type:e+(0>r.__dir__?"Right":"")}),r},Ee.prototype[e+"Right"]=function(t){return this.reverse()[e](t).reverse()}})),i(["filter","map","takeWhile"],(function(e,t){var n=t+1,r=1==n||3==n;Ee.prototype[e]=function(e){var t=this.clone();return t.__iteratees__.push({iteratee:Jn(e,3),type:n}),t.__filtered__=t.__filtered__||r,t}})),i(["head","last"],(function(e,t){var n="take"+(t?"Right":"");Ee.prototype[e]=function(){return this[n](1).value()[0]}})),i(["initial","tail"],(function(e,t){var n="drop"+(t?"":"Right");Ee.prototype[e]=function(){return this.__filtered__?new Ee(this):this[n](1)}})),Ee.prototype.compact=function(){return this.filter(gi)},Ee.prototype.find=function(e){return this.filter(e).head()},Ee.prototype.findLast=function(e){return this.reverse().find(e)},Ee.prototype.invokeMap=Vt((function(e,t){return"function"==typeof e?new Ee(this):this.map((function(n){return At(n,e,t)}))})),Ee.prototype.reject=function(e){return this.filter(Ir(Jn(e)))},Ee.prototype.slice=function(e,t){e=ei(e);var n=this;return n.__filtered__&&(0<e||0>t)?new Ee(n):(0>e?n=n.takeRight(-e):e&&(n=n.drop(e)),t!==I&&(n=0>(t=ei(t))?n.dropRight(-t):n.take(t-e)),n)},Ee.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},Ee.prototype.toArray=function(){return this.take(4294967295)},vt(Ee.prototype,(function(e,t){var n=/^(?:filter|find|map|reject)|While$/.test(t),r=/^(?:head|last)$/.test(t),i=x[r?"take"+("last"==t?"Right":""):t],o=r||/^find/.test(t);i&&(x.prototype[t]=function(){function t(e){return e=i.apply(x,f([e],s)),r&&p?e[0]:e}var a=this.__wrapped__,s=r?[1]:arguments,l=a instanceof Ee,u=s[0],c=l||Fa(a);c&&n&&"function"==typeof u&&1!=u.length&&(l=c=!1);var p=this.__chain__,d=!!this.__actions__.length;u=o&&!p,l=l&&!d;return!o&&c?(a=l?a:new Ee(this),(a=e.apply(a,s)).__actions__.push({func:Tr,args:[t],thisArg:I}),new xe(a,p)):u&&l?e.apply(this,s):(a=this.thru(t),u?r?a.value()[0]:a.value():a)})})),i("pop push shift sort splice unshift".split(" "),(function(e){var t=Ni[e],n=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",r=/^(?:pop|shift)$/.test(e);x.prototype[e]=function(){var e=arguments;if(r&&!this.__chain__){var i=this.value();return t.apply(Fa(i)?i:[],e)}return this[n]((function(n){return t.apply(Fa(n)?n:[],e)}))}})),vt(Ee.prototype,(function(e,t){var n=x[t];if(n){var r=n.name+"";Fi.call(Eo,r)||(Eo[r]=[]),Eo[r].push({name:t,func:n})}})),Eo[Nn(I,2).name]=[{name:"wrapper",func:I}],Ee.prototype.clone=function(){var e=new Ee(this.__wrapped__);return e.__actions__=wn(this.__actions__),e.__dir__=this.__dir__,e.__filtered__=this.__filtered__,e.__iteratees__=wn(this.__iteratees__),e.__takeCount__=this.__takeCount__,e.__views__=wn(this.__views__),e},Ee.prototype.reverse=function(){if(this.__filtered__){var e=new Ee(this);e.__dir__=-1,e.__filtered__=!0}else(e=this.clone()).__dir__*=-1;return e},Ee.prototype.value=function(){var e,t=this.__wrapped__.value(),n=this.__dir__,r=Fa(t),i=0>n,o=r?t.length:0;e=o;for(var a=this.__views__,s=0,l=-1,u=a.length;++l<u;){var c=a[l],f=c.size;switch(c.type){case"drop":s+=f;break;case"dropRight":e-=f;break;case"take":e=po(e,s+f);break;case"takeRight":s=fo(s,e-f)}}if(a=(e={start:s,end:e}).start,e=(s=e.end)-a,a=i?s:a-1,l=(s=this.__iteratees__).length,u=0,c=po(e,this.__takeCount__),!r||!i&&o==e&&c==e)return ln(t,this.__actions__);r=[];e:for(;e--&&u<c;){for(i=-1,o=t[a+=n];++i<l;){f=(p=s[i]).type;var p=(0,p.iteratee)(o);if(2==f)o=p;else if(!p){if(1==f)continue e;break e}}r[u++]=o}return r},x.prototype.at=ga,x.prototype.chain=function(){return jr(this)},x.prototype.commit=function(){return new xe(this.value(),this.__chain__)},x.prototype.next=function(){this.__values__===I&&(this.__values__=Jr(this.value()));var e=this.__index__>=this.__values__.length;return{done:e,value:e?I:this.__values__[this.__index__++]}},x.prototype.plant=function(e){for(var t,n=this;n instanceof we;){var r=br(n);r.__index__=0,r.__values__=I,t?i.__wrapped__=r:t=r;var i=r;n=n.__wrapped__}return i.__wrapped__=e,t},x.prototype.reverse=function(){var e=this.__wrapped__;return e instanceof Ee?(this.__actions__.length&&(e=new Ee(this)),(e=e.reverse()).__actions__.push({func:Tr,args:[Or],thisArg:I}),new xe(e,this.__chain__)):this.thru(Or)},x.prototype.toJSON=x.prototype.valueOf=x.prototype.value=function(){return ln(this.__wrapped__,this.__actions__)},x.prototype.first=x.prototype.head,Ji&&(x.prototype[Ji]=function(){return this}),x}();$e?(($e.exports=Qe)._=Qe,Ie._=Qe):qe._=Qe}).call(Bn)})),Kn=Un((function(e,t){t.aliasToReal={each:"forEach",eachRight:"forEachRight",entries:"toPairs",entriesIn:"toPairsIn",extend:"assignIn",extendAll:"assignInAll",extendAllWith:"assignInAllWith",extendWith:"assignInWith",first:"head",conforms:"conformsTo",matches:"isMatch",property:"get",__:"placeholder",F:"stubFalse",T:"stubTrue",all:"every",allPass:"overEvery",always:"constant",any:"some",anyPass:"overSome",apply:"spread",assoc:"set",assocPath:"set",complement:"negate",compose:"flowRight",contains:"includes",dissoc:"unset",dissocPath:"unset",dropLast:"dropRight",dropLastWhile:"dropRightWhile",equals:"isEqual",identical:"eq",indexBy:"keyBy",init:"initial",invertObj:"invert",juxt:"over",omitAll:"omit",nAry:"ary",path:"get",pathEq:"matchesProperty",pathOr:"getOr",paths:"at",pickAll:"pick",pipe:"flow",pluck:"map",prop:"get",propEq:"matchesProperty",propOr:"getOr",props:"at",symmetricDifference:"xor",symmetricDifferenceBy:"xorBy",symmetricDifferenceWith:"xorWith",takeLast:"takeRight",takeLastWhile:"takeRightWhile",unapply:"rest",unnest:"flatten",useWith:"overArgs",where:"conformsTo",whereEq:"isMatch",zipObj:"zipObject"},t.aryMethod={1:["assignAll","assignInAll","attempt","castArray","ceil","create","curry","curryRight","defaultsAll","defaultsDeepAll","floor","flow","flowRight","fromPairs","invert","iteratee","memoize","method","mergeAll","methodOf","mixin","nthArg","over","overEvery","overSome","rest","reverse","round","runInContext","spread","template","trim","trimEnd","trimStart","uniqueId","words","zipAll"],2:["add","after","ary","assign","assignAllWith","assignIn","assignInAllWith","at","before","bind","bindAll","bindKey","chunk","cloneDeepWith","cloneWith","concat","conformsTo","countBy","curryN","curryRightN","debounce","defaults","defaultsDeep","defaultTo","delay","difference","divide","drop","dropRight","dropRightWhile","dropWhile","endsWith","eq","every","filter","find","findIndex","findKey","findLast","findLastIndex","findLastKey","flatMap","flatMapDeep","flattenDepth","forEach","forEachRight","forIn","forInRight","forOwn","forOwnRight","get","groupBy","gt","gte","has","hasIn","includes","indexOf","intersection","invertBy","invoke","invokeMap","isEqual","isMatch","join","keyBy","lastIndexOf","lt","lte","map","mapKeys","mapValues","matchesProperty","maxBy","meanBy","merge","mergeAllWith","minBy","multiply","nth","omit","omitBy","overArgs","pad","padEnd","padStart","parseInt","partial","partialRight","partition","pick","pickBy","propertyOf","pull","pullAll","pullAt","random","range","rangeRight","rearg","reject","remove","repeat","restFrom","result","sampleSize","some","sortBy","sortedIndex","sortedIndexOf","sortedLastIndex","sortedLastIndexOf","sortedUniqBy","split","spreadFrom","startsWith","subtract","sumBy","take","takeRight","takeRightWhile","takeWhile","tap","throttle","thru","times","trimChars","trimCharsEnd","trimCharsStart","truncate","union","uniqBy","uniqWith","unset","unzipWith","without","wrap","xor","zip","zipObject","zipObjectDeep"],3:["assignInWith","assignWith","clamp","differenceBy","differenceWith","findFrom","findIndexFrom","findLastFrom","findLastIndexFrom","getOr","includesFrom","indexOfFrom","inRange","intersectionBy","intersectionWith","invokeArgs","invokeArgsMap","isEqualWith","isMatchWith","flatMapDepth","lastIndexOfFrom","mergeWith","orderBy","padChars","padCharsEnd","padCharsStart","pullAllBy","pullAllWith","rangeStep","rangeStepRight","reduce","reduceRight","replace","set","slice","sortedIndexBy","sortedLastIndexBy","transform","unionBy","unionWith","update","xorBy","xorWith","zipWith"],4:["fill","setWith","updateWith"]},t.aryRearg={2:[1,0],3:[2,0,1],4:[3,2,0,1]},t.iterateeAry={dropRightWhile:1,dropWhile:1,every:1,filter:1,find:1,findFrom:1,findIndex:1,findIndexFrom:1,findKey:1,findLast:1,findLastFrom:1,findLastIndex:1,findLastIndexFrom:1,findLastKey:1,flatMap:1,flatMapDeep:1,flatMapDepth:1,forEach:1,forEachRight:1,forIn:1,forInRight:1,forOwn:1,forOwnRight:1,map:1,mapKeys:1,mapValues:1,partition:1,reduce:2,reduceRight:2,reject:1,remove:1,some:1,takeRightWhile:1,takeWhile:1,times:1,transform:2},t.iterateeRearg={mapKeys:[1],reduceRight:[1,0]},t.methodRearg={assignInAllWith:[1,0],assignInWith:[1,2,0],assignAllWith:[1,0],assignWith:[1,2,0],differenceBy:[1,2,0],differenceWith:[1,2,0],getOr:[2,1,0],intersectionBy:[1,2,0],intersectionWith:[1,2,0],isEqualWith:[1,2,0],isMatchWith:[2,1,0],mergeAllWith:[1,0],mergeWith:[1,2,0],padChars:[2,1,0],padCharsEnd:[2,1,0],padCharsStart:[2,1,0],pullAllBy:[2,1,0],pullAllWith:[2,1,0],rangeStep:[1,2,0],rangeStepRight:[1,2,0],setWith:[3,1,2,0],sortedIndexBy:[2,1,0],sortedLastIndexBy:[2,1,0],unionBy:[1,2,0],unionWith:[1,2,0],updateWith:[3,1,2,0],xorBy:[1,2,0],xorWith:[1,2,0],zipWith:[1,2,0]},t.methodSpread={assignAll:{start:0},assignAllWith:{start:0},assignInAll:{start:0},assignInAllWith:{start:0},defaultsAll:{start:0},defaultsDeepAll:{start:0},invokeArgs:{start:2},invokeArgsMap:{start:2},mergeAll:{start:0},mergeAllWith:{start:0},partial:{start:1},partialRight:{start:1},without:{start:1},zipAll:{start:0}},t.mutate={array:{fill:!0,pull:!0,pullAll:!0,pullAllBy:!0,pullAllWith:!0,pullAt:!0,remove:!0,reverse:!0},object:{assign:!0,assignAll:!0,assignAllWith:!0,assignIn:!0,assignInAll:!0,assignInAllWith:!0,assignInWith:!0,assignWith:!0,defaults:!0,defaultsAll:!0,defaultsDeep:!0,defaultsDeepAll:!0,merge:!0,mergeAll:!0,mergeAllWith:!0,mergeWith:!0},set:{set:!0,setWith:!0,unset:!0,update:!0,updateWith:!0}},t.realToAlias=function(){var e=Object.prototype.hasOwnProperty,n=t.aliasToReal,r={};for(var i in n){var o=n[i];e.call(r,o)?r[o].push(i):r[o]=[i]}return r}(),t.remap={assignAll:"assign",assignAllWith:"assignWith",assignInAll:"assignIn",assignInAllWith:"assignInWith",curryN:"curry",curryRightN:"curryRight",defaultsAll:"defaults",defaultsDeepAll:"defaultsDeep",findFrom:"find",findIndexFrom:"findIndex",findLastFrom:"findLast",findLastIndexFrom:"findLastIndex",getOr:"get",includesFrom:"includes",indexOfFrom:"indexOf",invokeArgs:"invoke",invokeArgsMap:"invokeMap",lastIndexOfFrom:"lastIndexOf",mergeAll:"merge",mergeAllWith:"mergeWith",padChars:"pad",padCharsEnd:"padEnd",padCharsStart:"padStart",propertyOf:"get",rangeStep:"range",rangeStepRight:"rangeRight",restFrom:"rest",spreadFrom:"spread",trimChars:"trim",trimCharsEnd:"trimEnd",trimCharsStart:"trimStart",zipAll:"zip"},t.skipFixed={castArray:!0,flow:!0,flowRight:!0,iteratee:!0,mixin:!0,rearg:!0,runInContext:!0},t.skipRearg={add:!0,assign:!0,assignIn:!0,bind:!0,bindKey:!0,concat:!0,difference:!0,divide:!0,eq:!0,gt:!0,gte:!0,isEqual:!0,lt:!0,lte:!0,matchesProperty:!0,merge:!0,multiply:!0,overArgs:!0,partial:!0,partialRight:!0,propertyOf:!0,random:!0,range:!0,rangeRight:!0,subtract:!0,zip:!0,zipObject:!0,zipObjectDeep:!0}})),Yn={},Gn=Array.prototype.push;function Zn(e,t){return 2==t?function(t,n){return e(t,n)}:function(t){return e(t)}}function Xn(e){for(var t=e?e.length:0,n=Array(t);t--;)n[t]=e[t];return n}function Jn(e,t){return function(){var n=arguments.length;if(n){for(var r=Array(n);n--;)r[n]=arguments[n];var i=r[0]=t.apply(void 0,r);return e.apply(void 0,r),i}}}var Qn=function e(t,n,r,i){var o="function"==typeof n,a=n===Object(n);if(a&&(i=r,r=n,n=void 0),null==r)throw new TypeError;i||(i={});var s=!("cap"in i)||i.cap,l=!("curry"in i)||i.curry,u=!("fixed"in i)||i.fixed,c=!("immutable"in i)||i.immutable,f=!("rearg"in i)||i.rearg,p=o?r:Yn,d="curry"in i&&i.curry,h="fixed"in i&&i.fixed,g="rearg"in i&&i.rearg,m=o?r.runInContext():void 0,v=o?r:{ary:t.ary,assign:t.assign,clone:t.clone,curry:t.curry,forEach:t.forEach,isArray:t.isArray,isError:t.isError,isFunction:t.isFunction,isWeakMap:t.isWeakMap,iteratee:t.iteratee,keys:t.keys,rearg:t.rearg,toInteger:t.toInteger,toPath:t.toPath},y=v.ary,b=v.assign,_=v.clone,w=v.curry,x=v.forEach,k=v.isArray,C=v.isError,E=v.isFunction,O=v.isWeakMap,A=v.keys,S=v.rearg,j=v.toInteger,T=v.toPath,D=A(Kn.aryMethod),N={castArray:function(e){return function(){var t=arguments[0];return k(t)?e(Xn(t)):e.apply(void 0,arguments)}},iteratee:function(e){return function(){var t=arguments[0],n=arguments[1],r=e(t,n),i=r.length;return s&&"number"==typeof n?(n=n>2?n-2:1,i&&i<=n?r:Zn(r,n)):r}},mixin:function(e){return function(t){var n=this;if(!E(n))return e(n,Object(t));var r=[];return x(A(t),(function(e){E(t[e])&&r.push([e,n.prototype[e]])})),e(n,Object(t)),x(r,(function(e){var t=e[1];E(t)?n.prototype[e[0]]=t:delete n.prototype[e[0]]})),n}},nthArg:function(e){return function(t){var n=t<0?1:j(t)+1;return w(e(t),n)}},rearg:function(e){return function(t,n){var r=n?n.length:0;return w(e(t,n),r)}},runInContext:function(n){return function(r){return e(t,n(r),i)}}};function L(e,t){if(s){var n=Kn.iterateeRearg[e];if(n)return function(e,t){return I(e,(function(e){var n=t.length;return function(e,t){return 2==t?function(t,n){return e.apply(void 0,arguments)}:function(t){return e.apply(void 0,arguments)}}(S(Zn(e,n),t),n)}))}(t,n);var r=!o&&Kn.iterateeAry[e];if(r)return function(e,t){return I(e,(function(e){return"function"==typeof e?Zn(e,t):e}))}(t,r)}return t}function M(e,t,n){if(u&&(h||!Kn.skipFixed[e])){var r=Kn.methodSpread[e],i=r&&r.start;return void 0===i?y(t,n):function(e,t){return function(){for(var n=arguments.length,r=n-1,i=Array(n);n--;)i[n]=arguments[n];var o=i[t],a=i.slice(0,t);return o&&Gn.apply(a,o),t!=r&&Gn.apply(a,i.slice(t+1)),e.apply(this,a)}}(t,i)}return t}function P(e,t,n){return f&&n>1&&(g||!Kn.skipRearg[e])?S(t,Kn.methodRearg[e]||Kn.aryRearg[n]):t}function F(e,t){for(var n=-1,r=(t=T(t)).length,i=r-1,o=_(Object(e)),a=o;null!=a&&++n<r;){var s=t[n],l=a[s];null==l||E(l)||C(l)||O(l)||(a[s]=_(n==i?l:Object(l))),a=a[s]}return o}function q(t,n){var r=Kn.aliasToReal[t]||t,a=Kn.remap[r]||r,s=i;return function(t){var i=o?m:v,l=o?m[a]:n,u=b(b({},s),t);return e(i,r,l,u)}}function I(e,t){return function(){var n=arguments.length;if(!n)return e();for(var r=Array(n);n--;)r[n]=arguments[n];var i=f?0:n-1;return r[i]=t(r[i]),e.apply(void 0,r)}}function $(e,t,n){var r,i=Kn.aliasToReal[e]||e,o=t,a=N[i];return a?o=a(t):c&&(Kn.mutate.array[i]?o=Jn(t,Xn):Kn.mutate.object[i]?o=Jn(t,function(e){return function(t){return e({},t)}}(t)):Kn.mutate.set[i]&&(o=Jn(t,F))),x(D,(function(e){return x(Kn.aryMethod[e],(function(t){if(i==t){var n=Kn.methodSpread[i],a=n&&n.afterRearg;return r=a?M(i,P(i,o,e),e):P(i,M(i,o,e),e),r=function(e,t,n){return d||l&&n>1?w(t,n):t}(0,r=L(i,r),e),!1}})),!r})),r||(r=o),r==t&&(r=d?w(r,1):function(){return t.apply(this,arguments)}),r.convert=q(i,t),r.placeholder=t.placeholder=n,r}if(!a)return $(n,r,p);var R=r,z=[];return x(D,(function(e){x(Kn.aryMethod[e],(function(e){var t=R[Kn.remap[e]||e];t&&z.push([e,$(e,t,R)])}))})),x(A(R),(function(e){var t=R[e];if("function"==typeof t){for(var n=z.length;n--;)if(z[n][0]==e)return;t.convert=q(e,t),z.push([e,t])}})),x(z,(function(e){R[e[0]]=e[1]})),R.convert=function(e){return R.runInContext.convert(e)(void 0)},R.placeholder=R,x(A(R),(function(e){x(Kn.realToAlias[e]||[],(function(t){R[t]=R[e]}))})),R},er=Vn.runInContext(),tr=Qn(er,er),nr=function(){return(nr=Object.assign||function(e){for(var t,n=1,r=arguments.length;n<r;n++)for(var i in t=arguments[n])Object.prototype.hasOwnProperty.call(t,i)&&(e[i]=t[i]);return e}).apply(this,arguments)};function rr(e,t){var n="function"==typeof Symbol&&e[Symbol.iterator];if(!n)return e;var r,i,o=n.call(e),a=[];try{for(;(void 0===t||t-- >0)&&!(r=o.next()).done;)a.push(r.value)}catch(Vr){i={error:Vr}}finally{try{r&&!r.done&&(n=o.return)&&n.call(o)}finally{if(i)throw i.error}}return a}function ir(){for(var e=[],t=0;t<arguments.length;t++)e=e.concat(rr(arguments[t]));return e}function or(e){return Boolean(e&&e.then&&"function"==typeof e.then)}function ar(){return"[object process]"===Object.prototype.toString.call("undefined"!=typeof process?process:0)}var sr={};function lr(){return ar()?global:"undefined"!=typeof window?window:"undefined"!=typeof self?self:sr}function ur(){var e=lr(),t=e.crypto||e.msCrypto;if(void 0!==t&&t.getRandomValues){var n=new Uint16Array(8);t.getRandomValues(n),n[3]=4095&n[3]|16384,n[4]=16383&n[4]|32768;var r=function(e){for(var t=e.toString(16);t.length<4;)t="0"+t;return t};return r(n[0])+r(n[1])+r(n[2])+r(n[3])+r(n[4])+r(n[5])+r(n[6])+r(n[7])}return"xxxxxxxxxxxx4xxxyxxxxxxxxxxxxxxx".replace(/[xy]/g,(function(e){var t=16*Math.random()|0;return("x"===e?t:3&t|8).toString(16)}))}function cr(e){var t=lr();if(!("console"in t))return e();var n=t.console,r={};["debug","info","warn","error","log","assert"].forEach((function(e){e in t.console&&n[e].__sentry_original__&&(r[e]=n[e],n[e]=n[e].__sentry_original__)}));var i=e();return Object.keys(r).forEach((function(e){n[e]=r[e]})),i}var fr=Date.now(),pr=0,dr={now:function(){var e=Date.now()-fr;return e<pr&&(e=pr),pr=e,e},timeOrigin:fr},hr=function(){if(ar())try{return(e=module,t="perf_hooks",e.require(t)).performance}catch(r){return dr}var e,t,n=lr().performance;return n&&n.now?(void 0===n.timeOrigin&&(n.timeOrigin=n.timing&&n.timing.navigationStart||fr),n):dr}();function gr(){return(hr.timeOrigin+hr.now())/1e3}var mr=lr(),vr="Sentry Logger ",yr=function(){function e(){this._enabled=!1}return e.prototype.disable=function(){this._enabled=!1},e.prototype.enable=function(){this._enabled=!0},e.prototype.log=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this._enabled&&cr((function(){mr.console.log(vr+"[Log]: "+e.join(" "))}))},e.prototype.warn=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this._enabled&&cr((function(){mr.console.warn(vr+"[Warn]: "+e.join(" "))}))},e.prototype.error=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this._enabled&&cr((function(){mr.console.error(vr+"[Error]: "+e.join(" "))}))},e}();mr.__SENTRY__=mr.__SENTRY__||{};var br,_r,wr=mr.__SENTRY__.logger||(mr.__SENTRY__.logger=new yr);(_r=br||(br={})).PENDING="PENDING",_r.RESOLVED="RESOLVED",_r.REJECTED="REJECTED";var xr=function(){function e(e){var t=this;this._state=br.PENDING,this._handlers=[],this._resolve=function(e){t._setResult(br.RESOLVED,e)},this._reject=function(e){t._setResult(br.REJECTED,e)},this._setResult=function(e,n){t._state===br.PENDING&&(or(n)?n.then(t._resolve,t._reject):(t._state=e,t._value=n,t._executeHandlers()))},this._attachHandler=function(e){t._handlers=t._handlers.concat(e),t._executeHandlers()},this._executeHandlers=function(){if(t._state!==br.PENDING){var e=t._handlers.slice();t._handlers=[],e.forEach((function(e){e.done||(t._state===br.RESOLVED&&e.onfulfilled&&e.onfulfilled(t._value),t._state===br.REJECTED&&e.onrejected&&e.onrejected(t._value),e.done=!0)}))}};try{e(this._resolve,this._reject)}catch(n){this._reject(n)}}return e.prototype.toString=function(){return"[object SyncPromise]"},e.resolve=function(t){return new e((function(e){e(t)}))},e.reject=function(t){return new e((function(e,n){n(t)}))},e.all=function(t){return new e((function(n,r){if(Array.isArray(t))if(0!==t.length){var i=t.length,o=[];t.forEach((function(t,a){e.resolve(t).then((function(e){o[a]=e,0===(i-=1)&&n(o)})).then(null,r)}))}else n([]);else r(new TypeError("Promise.all requires an array as input."))}))},e.prototype.then=function(t,n){var r=this;return new e((function(e,i){r._attachHandler({done:!1,onfulfilled:function(n){if(t)try{return void e(t(n))}catch(r){return void i(r)}else e(n)},onrejected:function(t){if(n)try{return void e(n(t))}catch(r){return void i(r)}else i(t)}})}))},e.prototype.catch=function(e){return this.then((function(e){return e}),e)},e.prototype.finally=function(t){var n=this;return new e((function(e,r){var i,o;return n.then((function(e){o=!1,i=e,t&&t()}),(function(e){o=!0,i=e,t&&t()})).then((function(){o?r(i):e(i)}))}))},e}(),kr=function(){function e(){this._notifyingListeners=!1,this._scopeListeners=[],this._eventProcessors=[],this._breadcrumbs=[],this._user={},this._tags={},this._extra={},this._contexts={}}return e.prototype.addScopeListener=function(e){this._scopeListeners.push(e)},e.prototype.addEventProcessor=function(e){return this._eventProcessors.push(e),this},e.prototype._notifyScopeListeners=function(){var e=this;this._notifyingListeners||(this._notifyingListeners=!0,setTimeout((function(){e._scopeListeners.forEach((function(t){t(e)})),e._notifyingListeners=!1})))},e.prototype._notifyEventProcessors=function(e,t,n,r){var i=this;return void 0===r&&(r=0),new xr((function(o,a){var s=e[r];if(null===t||"function"!=typeof s)o(t);else{var l=s(nr({},t),n);or(l)?l.then((function(t){return i._notifyEventProcessors(e,t,n,r+1).then(o)})).then(null,a):i._notifyEventProcessors(e,l,n,r+1).then(o).then(null,a)}}))},e.prototype.setUser=function(e){return this._user=e||{},this._notifyScopeListeners(),this},e.prototype.setTags=function(e){return this._tags=nr({},this._tags,e),this._notifyScopeListeners(),this},e.prototype.setTag=function(e,t){var n;return this._tags=nr({},this._tags,((n={})[e]=t,n)),this._notifyScopeListeners(),this},e.prototype.setExtras=function(e){return this._extra=nr({},this._extra,e),this._notifyScopeListeners(),this},e.prototype.setExtra=function(e,t){var n;return this._extra=nr({},this._extra,((n={})[e]=t,n)),this._notifyScopeListeners(),this},e.prototype.setFingerprint=function(e){return this._fingerprint=e,this._notifyScopeListeners(),this},e.prototype.setLevel=function(e){return this._level=e,this._notifyScopeListeners(),this},e.prototype.setTransactionName=function(e){return this._transactionName=e,this._notifyScopeListeners(),this},e.prototype.setTransaction=function(e){return this.setTransactionName(e)},e.prototype.setContext=function(e,t){var n;return this._contexts=nr({},this._contexts,((n={})[e]=t,n)),this._notifyScopeListeners(),this},e.prototype.setSpan=function(e){return this._span=e,this._notifyScopeListeners(),this},e.prototype.getSpan=function(){return this._span},e.prototype.getTransaction=function(){var e=this.getSpan();if(e&&e.spanRecorder&&e.spanRecorder.spans[0])return e.spanRecorder.spans[0]},e.clone=function(t){var n=new e;return t&&(n._breadcrumbs=ir(t._breadcrumbs),n._tags=nr({},t._tags),n._extra=nr({},t._extra),n._contexts=nr({},t._contexts),n._user=t._user,n._level=t._level,n._span=t._span,n._transactionName=t._transactionName,n._fingerprint=t._fingerprint,n._eventProcessors=ir(t._eventProcessors)),n},e.prototype.update=function(t){if(!t)return this;if("function"==typeof t){var n=t(this);return n instanceof e?n:this}var r;return t instanceof e?(this._tags=nr({},this._tags,t._tags),this._extra=nr({},this._extra,t._extra),this._contexts=nr({},this._contexts,t._contexts),t._user&&(this._user=t._user),t._level&&(this._level=t._level),t._fingerprint&&(this._fingerprint=t._fingerprint)):(r=t,"[object Object]"===Object.prototype.toString.call(r)&&(t=t,this._tags=nr({},this._tags,t.tags),this._extra=nr({},this._extra,t.extra),this._contexts=nr({},this._contexts,t.contexts),t.user&&(this._user=t.user),t.level&&(this._level=t.level),t.fingerprint&&(this._fingerprint=t.fingerprint))),this},e.prototype.clear=function(){return this._breadcrumbs=[],this._tags={},this._extra={},this._user={},this._contexts={},this._level=void 0,this._transactionName=void 0,this._fingerprint=void 0,this._span=void 0,this._notifyScopeListeners(),this},e.prototype.addBreadcrumb=function(e,t){var n=nr({timestamp:gr()},e);return this._breadcrumbs=void 0!==t&&t>=0?ir(this._breadcrumbs,[n]).slice(-t):ir(this._breadcrumbs,[n]),this._notifyScopeListeners(),this},e.prototype.clearBreadcrumbs=function(){return this._breadcrumbs=[],this._notifyScopeListeners(),this},e.prototype._applyFingerprint=function(e){e.fingerprint=e.fingerprint?Array.isArray(e.fingerprint)?e.fingerprint:[e.fingerprint]:[],this._fingerprint&&(e.fingerprint=e.fingerprint.concat(this._fingerprint)),e.fingerprint&&!e.fingerprint.length&&delete e.fingerprint},e.prototype.applyToEvent=function(e,t){return this._extra&&Object.keys(this._extra).length&&(e.extra=nr({},this._extra,e.extra)),this._tags&&Object.keys(this._tags).length&&(e.tags=nr({},this._tags,e.tags)),this._user&&Object.keys(this._user).length&&(e.user=nr({},this._user,e.user)),this._contexts&&Object.keys(this._contexts).length&&(e.contexts=nr({},this._contexts,e.contexts)),this._level&&(e.level=this._level),this._transactionName&&(e.transaction=this._transactionName),this._span&&(e.contexts=nr({trace:this._span.getTraceContext()},e.contexts)),this._applyFingerprint(e),e.breadcrumbs=ir(e.breadcrumbs||[],this._breadcrumbs),e.breadcrumbs=e.breadcrumbs.length>0?e.breadcrumbs:void 0,this._notifyEventProcessors(ir(((n=lr()).__SENTRY__=n.__SENTRY__||{},n.__SENTRY__.globalEventProcessors=n.__SENTRY__.globalEventProcessors||[],n.__SENTRY__.globalEventProcessors),this._eventProcessors),e,t);var n},e}();var Cr=function(){function e(e,t,n){void 0===t&&(t=new kr),void 0===n&&(n=3),this._version=n,this._stack=[],this._stack.push({client:e,scope:t}),this.bindClient(e)}return e.prototype._invokeClient=function(e){for(var t,n=[],r=1;r<arguments.length;r++)n[r-1]=arguments[r];var i=this.getStackTop();i&&i.client&&i.client[e]&&(t=i.client)[e].apply(t,ir(n,[i.scope]))},e.prototype.isOlderThan=function(e){return this._version<e},e.prototype.bindClient=function(e){this.getStackTop().client=e,e&&e.setupIntegrations&&e.setupIntegrations()},e.prototype.pushScope=function(){var e=this.getStack(),t=e.length>0?e[e.length-1].scope:void 0,n=kr.clone(t);return this.getStack().push({client:this.getClient(),scope:n}),n},e.prototype.popScope=function(){return void 0!==this.getStack().pop()},e.prototype.withScope=function(e){var t=this.pushScope();try{e(t)}finally{this.popScope()}},e.prototype.getClient=function(){return this.getStackTop().client},e.prototype.getScope=function(){return this.getStackTop().scope},e.prototype.getStack=function(){return this._stack},e.prototype.getStackTop=function(){return this._stack[this._stack.length-1]},e.prototype.captureException=function(e,t){var n=this._lastEventId=ur(),r=t;if(!t){var i=void 0;try{throw new Error("Sentry syntheticException")}catch(o){i=o}r={originalException:e,syntheticException:i}}return this._invokeClient("captureException",e,nr({},r,{event_id:n})),n},e.prototype.captureMessage=function(e,t,n){var r=this._lastEventId=ur(),i=n;if(!n){var o=void 0;try{throw new Error(e)}catch(a){o=a}i={originalException:e,syntheticException:o}}return this._invokeClient("captureMessage",e,t,nr({},i,{event_id:r})),r},e.prototype.captureEvent=function(e,t){var n=this._lastEventId=ur();return this._invokeClient("captureEvent",e,nr({},t,{event_id:n})),n},e.prototype.lastEventId=function(){return this._lastEventId},e.prototype.addBreadcrumb=function(e,t){var n=this.getStackTop();if(n.scope&&n.client){var r=n.client.getOptions&&n.client.getOptions()||{},i=r.beforeBreadcrumb,o=void 0===i?null:i,a=r.maxBreadcrumbs,s=void 0===a?100:a;if(!(s<=0)){var l=gr(),u=nr({timestamp:l},e),c=o?cr((function(){return o(u,t)})):u;null!==c&&n.scope.addBreadcrumb(c,Math.min(s,100))}}},e.prototype.setUser=function(e){var t=this.getStackTop();t.scope&&t.scope.setUser(e)},e.prototype.setTags=function(e){var t=this.getStackTop();t.scope&&t.scope.setTags(e)},e.prototype.setExtras=function(e){var t=this.getStackTop();t.scope&&t.scope.setExtras(e)},e.prototype.setTag=function(e,t){var n=this.getStackTop();n.scope&&n.scope.setTag(e,t)},e.prototype.setExtra=function(e,t){var n=this.getStackTop();n.scope&&n.scope.setExtra(e,t)},e.prototype.setContext=function(e,t){var n=this.getStackTop();n.scope&&n.scope.setContext(e,t)},e.prototype.configureScope=function(e){var t=this.getStackTop();t.scope&&t.client&&e(t.scope)},e.prototype.run=function(e){var t=Or(this);try{e(this)}finally{Or(t)}},e.prototype.getIntegration=function(e){var t=this.getClient();if(!t)return null;try{return t.getIntegration(e)}catch(n){return wr.warn("Cannot retrieve integration "+e.id+" from the current Hub"),null}},e.prototype.startSpan=function(e){return this._callExtensionMethod("startSpan",e)},e.prototype.startTransaction=function(e){return this._callExtensionMethod("startTransaction",e)},e.prototype.traceHeaders=function(){return this._callExtensionMethod("traceHeaders")},e.prototype._callExtensionMethod=function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=Er(),i=r.__SENTRY__;if(i&&i.extensions&&"function"==typeof i.extensions[e])return i.extensions[e].apply(this,t);wr.warn("Extension method "+e+" couldn't be found, doing nothing.")},e}();function Er(){var e=lr();return e.__SENTRY__=e.__SENTRY__||{extensions:{},hub:void 0},e}function Or(e){var t=Er(),n=jr(t);return Tr(t,e),n}function Ar(){var e=Er();return Sr(e)&&!jr(e).isOlderThan(3)||Tr(e,new Cr),ar()?function(e){try{var t="domain",n=Er().__SENTRY__;if(!n||!n.extensions||!n.extensions[t])return jr(e);var r=n.extensions[t].active;if(!r)return jr(e);if(!Sr(r)||jr(r).isOlderThan(3)){var i=jr(e).getStackTop();Tr(r,new Cr(i.client,kr.clone(i.scope)))}return jr(r)}catch(o){return jr(e)}}(e):jr(e)}function Sr(e){return!!(e&&e.__SENTRY__&&e.__SENTRY__.hub)}function jr(e){return e&&e.__SENTRY__&&e.__SENTRY__.hub||(e.__SENTRY__=e.__SENTRY__||{},e.__SENTRY__.hub=new Cr),e.__SENTRY__.hub}function Tr(e,t){return!!e&&(e.__SENTRY__=e.__SENTRY__||{},e.__SENTRY__.hub=t,!0)}function Dr(e,t){var n;try{throw new Error("Sentry syntheticException")}catch(r){n=r}return function(e){for(var t=[],n=1;n<arguments.length;n++)t[n-1]=arguments[n];var r=Ar();if(r&&r[e])return r[e].apply(r,ir(t));throw new Error("No hub defined or "+e+" was not found on the hub, please open a bug report.")}("captureException",e,{captureContext:t,originalException:e,syntheticException:n})}var Nr=String.fromCharCode,Lr="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",Mr="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+-$",Pr={};function Fr(e,t){if(!Pr[e]){Pr[e]={};for(var n=0;n<e.length;n++)Pr[e][e.charAt(n)]=n}return Pr[e][t]}var qr,Ir={compressToBase64:function(e){if(null==e)return"";var t=Ir._compress(e,6,(function(e){return Lr.charAt(e)}));switch(t.length%4){default:case 0:return t;case 1:return t+"===";case 2:return t+"==";case 3:return t+"="}},decompressFromBase64:function(e){return null==e?"":""==e?null:Ir._decompress(e.length,32,(function(t){return Fr(Lr,e.charAt(t))}))},compressToUTF16:function(e){return null==e?"":Ir._compress(e,15,(function(e){return Nr(e+32)}))+" "},decompressFromUTF16:function(e){return null==e?"":""==e?null:Ir._decompress(e.length,16384,(function(t){return e.charCodeAt(t)-32}))},compressToUint8Array:function(e){for(var t=Ir.compress(e),n=new Uint8Array(2*t.length),r=0,i=t.length;r<i;r++){var o=t.charCodeAt(r);n[2*r]=o>>>8,n[2*r+1]=o%256}return n},decompressFromUint8Array:function(e){if(null==e)return Ir.decompress(e);for(var t=new Array(e.length/2),n=0,r=t.length;n<r;n++)t[n]=256*e[2*n]+e[2*n+1];var i=[];return t.forEach((function(e){i.push(Nr(e))})),Ir.decompress(i.join(""))},compressToEncodedURIComponent:function(e){return null==e?"":Ir._compress(e,6,(function(e){return Mr.charAt(e)}))},decompressFromEncodedURIComponent:function(e){return null==e?"":""==e?null:(e=e.replace(/ /g,"+"),Ir._decompress(e.length,32,(function(t){return Fr(Mr,e.charAt(t))})))},compress:function(e){return Ir._compress(e,16,(function(e){return Nr(e)}))},_compress:function(e,t,n){if(null==e)return"";var r,i,o,a={},s={},l="",u="",c="",f=2,p=3,d=2,h=[],g=0,m=0;for(o=0;o<e.length;o+=1)if(l=e.charAt(o),Object.prototype.hasOwnProperty.call(a,l)||(a[l]=p++,s[l]=!0),u=c+l,Object.prototype.hasOwnProperty.call(a,u))c=u;else{if(Object.prototype.hasOwnProperty.call(s,c)){if(c.charCodeAt(0)<256){for(r=0;r<d;r++)g<<=1,m==t-1?(m=0,h.push(n(g)),g=0):m++;for(i=c.charCodeAt(0),r=0;r<8;r++)g=g<<1|1&i,m==t-1?(m=0,h.push(n(g)),g=0):m++,i>>=1}else{for(i=1,r=0;r<d;r++)g=g<<1|i,m==t-1?(m=0,h.push(n(g)),g=0):m++,i=0;for(i=c.charCodeAt(0),r=0;r<16;r++)g=g<<1|1&i,m==t-1?(m=0,h.push(n(g)),g=0):m++,i>>=1}0==--f&&(f=Math.pow(2,d),d++),delete s[c]}else for(i=a[c],r=0;r<d;r++)g=g<<1|1&i,m==t-1?(m=0,h.push(n(g)),g=0):m++,i>>=1;0==--f&&(f=Math.pow(2,d),d++),a[u]=p++,c=String(l)}if(""!==c){if(Object.prototype.hasOwnProperty.call(s,c)){if(c.charCodeAt(0)<256){for(r=0;r<d;r++)g<<=1,m==t-1?(m=0,h.push(n(g)),g=0):m++;for(i=c.charCodeAt(0),r=0;r<8;r++)g=g<<1|1&i,m==t-1?(m=0,h.push(n(g)),g=0):m++,i>>=1}else{for(i=1,r=0;r<d;r++)g=g<<1|i,m==t-1?(m=0,h.push(n(g)),g=0):m++,i=0;for(i=c.charCodeAt(0),r=0;r<16;r++)g=g<<1|1&i,m==t-1?(m=0,h.push(n(g)),g=0):m++,i>>=1}0==--f&&(f=Math.pow(2,d),d++),delete s[c]}else for(i=a[c],r=0;r<d;r++)g=g<<1|1&i,m==t-1?(m=0,h.push(n(g)),g=0):m++,i>>=1;0==--f&&(f=Math.pow(2,d),d++)}for(i=2,r=0;r<d;r++)g=g<<1|1&i,m==t-1?(m=0,h.push(n(g)),g=0):m++,i>>=1;for(;;){if(g<<=1,m==t-1){h.push(n(g));break}m++}return h.join("")},decompress:function(e){return null==e?"":""==e?null:Ir._decompress(e.length,32768,(function(t){return e.charCodeAt(t)}))},_decompress:function(e,t,n){var r,i,o,a,s,l,u,c=[],f=4,p=4,d=3,h="",g=[],m={val:n(0),position:t,index:1};for(r=0;r<3;r+=1)c[r]=r;for(o=0,s=Math.pow(2,2),l=1;l!=s;)a=m.val&m.position,m.position>>=1,0==m.position&&(m.position=t,m.val=n(m.index++)),o|=(a>0?1:0)*l,l<<=1;switch(o){case 0:for(o=0,s=Math.pow(2,8),l=1;l!=s;)a=m.val&m.position,m.position>>=1,0==m.position&&(m.position=t,m.val=n(m.index++)),o|=(a>0?1:0)*l,l<<=1;u=Nr(o);break;case 1:for(o=0,s=Math.pow(2,16),l=1;l!=s;)a=m.val&m.position,m.position>>=1,0==m.position&&(m.position=t,m.val=n(m.index++)),o|=(a>0?1:0)*l,l<<=1;u=Nr(o);break;case 2:return""}for(c[3]=u,i=u,g.push(u);;){if(m.index>e)return"";for(o=0,s=Math.pow(2,d),l=1;l!=s;)a=m.val&m.position,m.position>>=1,0==m.position&&(m.position=t,m.val=n(m.index++)),o|=(a>0?1:0)*l,l<<=1;switch(u=o){case 0:for(o=0,s=Math.pow(2,8),l=1;l!=s;)a=m.val&m.position,m.position>>=1,0==m.position&&(m.position=t,m.val=n(m.index++)),o|=(a>0?1:0)*l,l<<=1;c[p++]=Nr(o),u=p-1,f--;break;case 1:for(o=0,s=Math.pow(2,16),l=1;l!=s;)a=m.val&m.position,m.position>>=1,0==m.position&&(m.position=t,m.val=n(m.index++)),o|=(a>0?1:0)*l,l<<=1;c[p++]=Nr(o),u=p-1,f--;break;case 2:return g.join("")}if(0==f&&(f=Math.pow(2,d),d++),c[u])h=c[u];else{if(u!==p)return null;h=i+i.charAt(0)}g.push(h),c[p++]=i+h.charAt(0),i=h,0==--f&&(f=Math.pow(2,d),d++)}}},$r={DEBUG:!1,LIB_VERSION:"1.0.0"};if("undefined"==typeof window){var Rr={hostname:""};qr={navigator:{userAgent:""},document:{location:Rr,referrer:""},screen:{width:0,height:0},location:Rr}}else qr=window;var zr,Br,Wr,Hr,Ur,Vr,Kr,Yr,Gr,Zr,Xr,Jr=Array.prototype,Qr=Function.prototype,ei=Object.prototype,ti=Jr.slice,ni=ei.toString,ri=ei.hasOwnProperty,ii=qr.console,oi=qr.navigator,ai=qr.document,si=qr.opera,li=qr.screen,ui=oi.userAgent,ci=Qr.bind,fi=Jr.forEach,pi=Jr.indexOf,di=Array.isArray,hi={},gi=/[a-z0-9][a-z0-9-]+\.[a-z.]{2,6}$/i,mi={trim:function(e){return e.replace(/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g,"")}},vi=function(){if($r.DEBUG&&!mi.isUndefined(ii)&&ii)try{ii.log.apply(ii,arguments)}catch(e){mi.each(arguments,(function(e){ii.log(e)}))}},yi=function(){if($r.DEBUG&&!mi.isUndefined(ii)&&ii){var e=["PostHog error:"].concat(mi.toArray(arguments));try{ii.error.apply(ii,e)}catch(t){mi.each(e,(function(e){ii.error(e)}))}}},bi=function(){if(!mi.isUndefined(ii)&&ii){var e=["PostHog error:"].concat(mi.toArray(arguments));try{ii.error.apply(ii,e)}catch(t){mi.each(e,(function(e){ii.error(e)}))}}};mi.bind=function(e,t){var n,r;if(ci&&e.bind===ci)return ci.apply(e,ti.call(arguments,1));if(!mi.isFunction(e))throw new TypeError;return n=ti.call(arguments,2),r=function(){if(!(this instanceof r))return e.apply(t,n.concat(ti.call(arguments)));var i={};i.prototype=e.prototype;var o=new i;i.prototype=null;var a=e.apply(o,n.concat(ti.call(arguments)));return Object(a)===a?a:o}},mi.bind_instance_methods=function(e){for(var t in e)"function"==typeof e[t]&&(e[t]=mi.bind(e[t],e))},mi.each=function(e,t,n){if(null!=e)if(fi&&e.forEach===fi)e.forEach(t,n);else if(e.length===+e.length){for(var r=0,i=e.length;r<i;r++)if(r in e&&t.call(n,e[r],r,e)===hi)return}else for(var o in e)if(ri.call(e,o)&&t.call(n,e[o],o,e)===hi)return},mi.escapeHTML=function(e){var t=e;return t&&mi.isString(t)&&(t=t.replace(/&/g,"&amp;").replace(/</g,"&lt;").replace(/>/g,"&gt;").replace(/"/g,"&quot;").replace(/'/g,"&#039;")),t},mi.extend=function(e){return mi.each(ti.call(arguments,1),(function(t){for(var n in t)void 0!==t[n]&&(e[n]=t[n])})),e},mi.isArray=di||function(e){return"[object Array]"===ni.call(e)},mi.isFunction=function(e){try{return/^\s*\bfunction\b/.test(e)}catch(t){return!1}},mi.isArguments=function(e){return!(!e||!ri.call(e,"callee"))},mi.toArray=function(e){return e?e.toArray?e.toArray():mi.isArray(e)||mi.isArguments(e)?ti.call(e):mi.values(e):[]},mi.keys=function(e){var t=[];return null===e||mi.each(e,(function(e,n){t[t.length]=n})),t},mi.values=function(e){var t=[];return null===e||mi.each(e,(function(e){t[t.length]=e})),t},mi.identity=function(e){return e},mi.include=function(e,t){var n=!1;return null===e?n:pi&&e.indexOf===pi?-1!=e.indexOf(t):(mi.each(e,(function(e){if(n||(n=e===t))return hi})),n)},mi.includes=function(e,t){return-1!==e.indexOf(t)},mi.inherit=function(e,t){return e.prototype=new t,e.prototype.constructor=e,e.superclass=t.prototype,e},mi.isObject=function(e){return e===Object(e)&&!mi.isArray(e)},mi.isEmptyObject=function(e){if(mi.isObject(e)){for(var t in e)if(ri.call(e,t))return!1;return!0}return!1},mi.isUndefined=function(e){return void 0===e},mi.isString=function(e){return"[object String]"==ni.call(e)},mi.isDate=function(e){return"[object Date]"==ni.call(e)},mi.isNumber=function(e){return"[object Number]"==ni.call(e)},mi.isElement=function(e){return!(!e||1!==e.nodeType)},mi.encodeDates=function(e){return mi.each(e,(function(t,n){mi.isDate(t)?e[n]=mi.formatDate(t):mi.isObject(t)&&(e[n]=mi.encodeDates(t))})),e},mi.timestamp=function(){return Date.now=Date.now||function(){return+new Date},Date.now()},mi.formatDate=function(e){function t(e){return e<10?"0"+e:e}return e.getUTCFullYear()+"-"+t(e.getUTCMonth()+1)+"-"+t(e.getUTCDate())+"T"+t(e.getUTCHours())+":"+t(e.getUTCMinutes())+":"+t(e.getUTCSeconds())},mi.safewrap=function(e){return function(){try{return e.apply(this,arguments)}catch(t){bi("Implementation error. Please turn on debug and contact support@posthog.com."),$r.DEBUG&&bi(t)}}},mi.safewrap_class=function(e,t){for(var n=0;n<t.length;n++)e.prototype[t[n]]=mi.safewrap(e.prototype[t[n]])},mi.safewrap_instance_methods=function(e){for(var t in e)"function"==typeof e[t]&&(e[t]=mi.safewrap(e[t]))},mi.strip_empty_properties=function(e){var t={};return mi.each(e,(function(e,n){mi.isString(e)&&e.length>0&&(t[n]=e)})),t},mi.truncate=function(e,t){var n;return"string"==typeof e?n=e.slice(0,t):mi.isArray(e)?(n=[],mi.each(e,(function(e){n.push(mi.truncate(e,t))}))):mi.isObject(e)?(n={},mi.each(e,(function(e,r){n[r]=mi.truncate(e,t)}))):n=e,n},mi.JSONEncode=function(e){var t=function(e){var t=/[\\"\x00-\x1f\x7f-\x9f\u00ad\u0600-\u0604\u070f\u17b4\u17b5\u200c-\u200f\u2028-\u202f\u2060-\u206f\ufeff\ufff0-\uffff]/g,n={"\b":"\\b","\t":"\\t","\n":"\\n","\f":"\\f","\r":"\\r",'"':'\\"',"\\":"\\\\"};return t.lastIndex=0,t.test(e)?'"'+e.replace(t,(function(e){var t=n[e];return"string"==typeof t?t:"\\u"+("0000"+e.charCodeAt(0).toString(16)).slice(-4)}))+'"':'"'+e+'"'},n=function(e,r){var i="",o=0,a="",s="",l=0,u=i,c=[],f=r[e];switch(f&&"object"==typeof f&&"function"==typeof f.toJSON&&(f=f.toJSON(e)),typeof f){case"string":return t(f);case"number":return isFinite(f)?String(f):"null";case"boolean":case"null":return String(f);case"object":if(!f)return"null";if(i+=" ",c=[],"[object Array]"===ni.apply(f)){for(l=f.length,o=0;o<l;o+=1)c[o]=n(o,f)||"null";return s=0===c.length?"[]":i?"[\n"+i+c.join(",\n"+i)+"\n"+u+"]":"["+c.join(",")+"]",i=u,s}for(a in f)ri.call(f,a)&&(s=n(a,f))&&c.push(t(a)+(i?": ":":")+s);return s=0===c.length?"{}":i?"{"+c.join(",")+u+"}":"{"+c.join(",")+"}",i=u,s}};return n("",{"":e})},mi.JSONDecode=(Ur={'"':'"',"\\":"\\","/":"/",b:"\b",f:"\f",n:"\n",r:"\r",t:"\t"},Vr=function(e){var t=new SyntaxError(e);throw t.at=zr,t.text=Wr,t},Kr=function(e){return e&&e!==Br&&Vr("Expected '"+e+"' instead of '"+Br+"'"),Br=Wr.charAt(zr),zr+=1,Br},Yr=function(){var e,t="";for("-"===Br&&(t="-",Kr("-"));Br>="0"&&Br<="9";)t+=Br,Kr();if("."===Br)for(t+=".";Kr()&&Br>="0"&&Br<="9";)t+=Br;if("e"===Br||"E"===Br)for(t+=Br,Kr(),"-"!==Br&&"+"!==Br||(t+=Br,Kr());Br>="0"&&Br<="9";)t+=Br,Kr();if(e=+t,isFinite(e))return e;Vr("Bad number")},Gr=function(){var e,t,n,r="";if('"'===Br)for(;Kr();){if('"'===Br)return Kr(),r;if("\\"===Br)if(Kr(),"u"===Br){for(n=0,t=0;t<4&&(e=parseInt(Kr(),16),isFinite(e));t+=1)n=16*n+e;r+=String.fromCharCode(n)}else{if("string"!=typeof Ur[Br])break;r+=Ur[Br]}else r+=Br}Vr("Bad string")},Zr=function(){for(;Br&&Br<=" ";)Kr()},Hr=function(){switch(Zr(),Br){case"{":return function(){var e,t={};if("{"===Br){if(Kr("{"),Zr(),"}"===Br)return Kr("}"),t;for(;Br;){if(e=Gr(),Zr(),Kr(":"),Object.hasOwnProperty.call(t,e)&&Vr('Duplicate key "'+e+'"'),t[e]=Hr(),Zr(),"}"===Br)return Kr("}"),t;Kr(","),Zr()}}Vr("Bad object")}();case"[":return function(){var e=[];if("["===Br){if(Kr("["),Zr(),"]"===Br)return Kr("]"),e;for(;Br;){if(e.push(Hr()),Zr(),"]"===Br)return Kr("]"),e;Kr(","),Zr()}}Vr("Bad array")}();case'"':return Gr();case"-":return Yr();default:return Br>="0"&&Br<="9"?Yr():function(){switch(Br){case"t":return Kr("t"),Kr("r"),Kr("u"),Kr("e"),!0;case"f":return Kr("f"),Kr("a"),Kr("l"),Kr("s"),Kr("e"),!1;case"n":return Kr("n"),Kr("u"),Kr("l"),Kr("l"),null}Vr('Unexpected "'+Br+'"')}()}},function(e){var t;return Wr=e,zr=0,Br=" ",t=Hr(),Zr(),Br&&Vr("Syntax error"),t}),mi.base64Encode=function(e){var t,n,r,i,o,a="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=",s=0,l=0,u="",c=[];if(!e)return e;e=mi.utf8Encode(e);do{t=(o=e.charCodeAt(s++)<<16|e.charCodeAt(s++)<<8|e.charCodeAt(s++))>>18&63,n=o>>12&63,r=o>>6&63,i=63&o,c[l++]=a.charAt(t)+a.charAt(n)+a.charAt(r)+a.charAt(i)}while(s<e.length);switch(u=c.join(""),e.length%3){case 1:u=u.slice(0,-2)+"==";break;case 2:u=u.slice(0,-1)+"="}return u},mi.utf8Encode=function(e){var t,n,r,i,o="";for(t=n=0,r=(e=(e+"").replace(/\r\n/g,"\n").replace(/\r/g,"\n")).length,i=0;i<r;i++){var a=e.charCodeAt(i),s=null;a<128?n++:s=a>127&&a<2048?String.fromCharCode(a>>6|192,63&a|128):String.fromCharCode(a>>12|224,a>>6&63|128,63&a|128),null!==s&&(n>t&&(o+=e.substring(t,n)),o+=s,t=n=i+1)}return n>t&&(o+=e.substring(t,e.length)),o},mi.UUID=(Xr=function(){for(var e=1*new Date,t=0;e==1*new Date;)t++;return e.toString(16)+t.toString(16)},function(){var e=(li.height*li.width).toString(16);return Xr()+"-"+Math.random().toString(16).replace(".","")+"-"+function(){var e,t,n=ui,r=[],i=0;function o(e,t){var n,i=0;for(n=0;n<t.length;n++)i|=r[n]<<8*n;return e^i}for(e=0;e<n.length;e++)t=n.charCodeAt(e),r.unshift(255&t),r.length>=4&&(i=o(i,r),r=[]);return r.length>0&&(i=o(i,r)),i.toString(16)}()+"-"+e+"-"+Xr()}),mi.isBlockedUA=function(e){return!!/(google web preview|baiduspider|yandexbot|bingbot|googlebot|yahoo! slurp)/i.test(e)},mi.HTTPBuildQuery=function(e,t){var n,r,i=[];return mi.isUndefined(t)&&(t="&"),mi.each(e,(function(e,t){n=encodeURIComponent(e.toString()),r=encodeURIComponent(t),i[i.length]=r+"="+n})),i.join(t)},mi.getQueryParam=function(e,t){t=t.replace(/[[]/,"\\[").replace(/[\]]/,"\\]");var n=new RegExp("[\\?&]"+t+"=([^&#]*)").exec(e);if(null===n||n&&"string"!=typeof n[1]&&n[1].length)return"";var r=n[1];try{r=decodeURIComponent(r)}catch(i){yi("Skipping decoding for malformed query param: "+r)}return r.replace(/\+/g," ")},mi.getHashParam=function(e,t){var n=e.match(new RegExp(t+"=([^&]*)"));return n?n[1]:null},mi.cookie={get:function(e){try{for(var t=e+"=",n=ai.cookie.split(";"),r=0;r<n.length;r++){for(var i=n[r];" "==i.charAt(0);)i=i.substring(1,i.length);if(0===i.indexOf(t))return decodeURIComponent(i.substring(t.length,i.length))}}catch(o){}return null},parse:function(e){var t;try{t=mi.JSONDecode(mi.cookie.get(e))||{}}catch(n){}return t},set_seconds:function(e,t,n,r,i){try{var o="",a="",s="";if(r){var l=ai.location.hostname.match(gi),u=l?l[0]:"";o=u?"; domain=."+u:""}if(n){var c=new Date;c.setTime(c.getTime()+1e3*n),a="; expires="+c.toGMTString()}i&&(s="; secure"),ai.cookie=e+"="+encodeURIComponent(t)+a+"; path=/"+o+s}catch(f){return}},set:function(e,t,n,r,i){try{var o="",a="",s="";if(r){var l=ai.location.hostname.match(gi),u=l?l[0]:"";o=u?"; domain=."+u:""}if(n){var c=new Date;c.setTime(c.getTime()+24*n*60*60*1e3),a="; expires="+c.toGMTString()}i&&(s="; secure");var f=e+"="+encodeURIComponent(t)+a+"; path=/"+o+s;return ai.cookie=f,f}catch(p){return}},remove:function(e,t){try{mi.cookie.set(e,"",-1,t)}catch(n){return}}};var _i=null;mi.localStorage={is_supported:function(){if(null!==_i)return _i;var e=!0;try{var t="__mplssupport__";mi.localStorage.set(t,"xyz"),"xyz"!==mi.localStorage.get(t)&&(e=!1),mi.localStorage.remove(t)}catch(n){e=!1}return e||yi("localStorage unsupported; falling back to cookie store"),_i=e,e},error:function(e){yi("localStorage error: "+e)},get:function(e){try{return window.localStorage.getItem(e)}catch(t){mi.localStorage.error(t)}return null},parse:function(e){try{return mi.JSONDecode(mi.localStorage.get(e))||{}}catch(t){}return null},set:function(e,t){try{window.localStorage.setItem(e,t)}catch(n){mi.localStorage.error(n)}},remove:function(e){try{window.localStorage.removeItem(e)}catch(t){mi.localStorage.error(t)}}},mi.register_event=function(){function e(t){return t&&(t.preventDefault=e.preventDefault,t.stopPropagation=e.stopPropagation),t}return e.preventDefault=function(){this.returnValue=!1},e.stopPropagation=function(){this.cancelBubble=!0},function(t,n,r,i,o){if(t)if(t.addEventListener&&!i)t.addEventListener(n,r,!!o);else{var a="on"+n,s=t[a];t[a]=function(t,n,r){return function(i){if(i=i||e(window.event)){var o,a,s=!0;return mi.isFunction(r)&&(o=r(i)),a=n.call(t,i),!1!==o&&!1!==a||(s=!1),s}}}(t,r,s)}else yi("No valid element provided to register_event")}}();var wi=new RegExp('^(\\w*)\\[(\\w+)([=~\\|\\^\\$\\*]?)=?"?([^\\]"]*)"?\\]$');function xi(e){switch(typeof e.className){case"string":return e.className;case"object":return e.className.baseVal||e.getAttribute("class")||"";default:return""}}function ki(e){var t="";return Si(e)&&!ji(e)&&e.childNodes&&e.childNodes.length&&mi.each(e.childNodes,(function(e){Oi(e)&&e.textContent&&(t+=mi.trim(e.textContent).split(/(\s+)/).filter(Ti).join("").replace(/[\r\n]/g," ").replace(/[ ]+/g," ").substring(0,255))})),mi.trim(t)}function Ci(e){return e&&1===e.nodeType}function Ei(e,t){return e&&e.tagName&&e.tagName.toLowerCase()===t.toLowerCase()}function Oi(e){return e&&3===e.nodeType}mi.dom_query=function(){function e(e){return e.all?e.all:e.getElementsByTagName("*")}var t=/[\t\r\n]/g;function n(e,n){var r=" "+n+" ";return(" "+e.className+" ").replace(t," ").indexOf(r)>=0}function r(t){if(!ai.getElementsByTagName)return[];var r,i,o,a,s,l,u,c,f,p,d=t.split(" "),h=[ai];for(l=0;l<d.length;l++)if((r=d[l].replace(/^\s+/,"").replace(/\s+$/,"")).indexOf("#")>-1){o=(i=r.split("#"))[0];var g=i[1],m=ai.getElementById(g);if(!m||o&&m.nodeName.toLowerCase()!=o)return[];h=[m]}else if(r.indexOf(".")>-1){o=(i=r.split("."))[0];var v=i[1];for(o||(o="*"),a=[],s=0,u=0;u<h.length;u++)for(f="*"==o?e(h[u]):h[u].getElementsByTagName(o),c=0;c<f.length;c++)a[s++]=f[c];for(h=[],p=0,u=0;u<a.length;u++)a[u].className&&mi.isString(a[u].className)&&n(a[u],v)&&(h[p++]=a[u])}else{var y=r.match(wi);if(y){o=y[1];var b,_=y[2],w=y[3],x=y[4];for(o||(o="*"),a=[],s=0,u=0;u<h.length;u++)for(f="*"==o?e(h[u]):h[u].getElementsByTagName(o),c=0;c<f.length;c++)a[s++]=f[c];switch(h=[],p=0,w){case"=":b=function(e){return e.getAttribute(_)==x};break;case"~":b=function(e){return e.getAttribute(_).match(new RegExp("\\b"+x+"\\b"))};break;case"|":b=function(e){return e.getAttribute(_).match(new RegExp("^"+x+"-?"))};break;case"^":b=function(e){return 0===e.getAttribute(_).indexOf(x)};break;case"$":b=function(e){return e.getAttribute(_).lastIndexOf(x)==e.getAttribute(_).length-x.length};break;case"*":b=function(e){return e.getAttribute(_).indexOf(x)>-1};break;default:b=function(e){return e.getAttribute(_)}}for(h=[],p=0,u=0;u<a.length;u++)b(a[u])&&(h[p++]=a[u])}else{for(o=r,a=[],s=0,u=0;u<h.length;u++)for(f=h[u].getElementsByTagName(o),c=0;c<f.length;c++)a[s++]=f[c];h=a}}return h}return function(e){return mi.isElement(e)?[e]:mi.isObject(e)&&!mi.isUndefined(e.length)?e:r.call(this,e)}}(),mi.info={campaignParams:function(){var e="utm_source utm_medium utm_campaign utm_content utm_term".split(" "),t="",n={};return mi.each(e,(function(e){(t=mi.getQueryParam(ai.URL,e)).length&&(n[e]=t)})),n},searchEngine:function(e){return 0===e.search("https?://(.*)google.([^/?]*)")?"google":0===e.search("https?://(.*)bing.com")?"bing":0===e.search("https?://(.*)yahoo.com")?"yahoo":0===e.search("https?://(.*)duckduckgo.com")?"duckduckgo":null},searchInfo:function(e){var t=mi.info.searchEngine(e),n="yahoo"!=t?"q":"p",r={};if(null!==t){r.$search_engine=t;var i=mi.getQueryParam(e,n);i.length&&(r.ph_keyword=i)}return r},browser:function(e,t,n){return t=t||"",n||mi.includes(e," OPR/")?mi.includes(e,"Mini")?"Opera Mini":"Opera":/(BlackBerry|PlayBook|BB10)/i.test(e)?"BlackBerry":mi.includes(e,"IEMobile")||mi.includes(e,"WPDesktop")?"Internet Explorer Mobile":mi.includes(e,"SamsungBrowser/")?"Samsung Internet":mi.includes(e,"Edge")||mi.includes(e,"Edg/")?"Microsoft Edge":mi.includes(e,"FBIOS")?"Facebook Mobile":mi.includes(e,"Chrome")?"Chrome":mi.includes(e,"CriOS")?"Chrome iOS":mi.includes(e,"UCWEB")||mi.includes(e,"UCBrowser")?"UC Browser":mi.includes(e,"FxiOS")?"Firefox iOS":mi.includes(t,"Apple")?mi.includes(e,"Mobile")?"Mobile Safari":"Safari":mi.includes(e,"Android")?"Android Mobile":mi.includes(e,"Konqueror")?"Konqueror":mi.includes(e,"Firefox")?"Firefox":mi.includes(e,"MSIE")||mi.includes(e,"Trident/")?"Internet Explorer":mi.includes(e,"Gecko")?"Mozilla":""},browserVersion:function(e,t,n){var r={"Internet Explorer Mobile":/rv:(\d+(\.\d+)?)/,"Microsoft Edge":/Edge?\/(\d+(\.\d+)?)/,Chrome:/Chrome\/(\d+(\.\d+)?)/,"Chrome iOS":/CriOS\/(\d+(\.\d+)?)/,"UC Browser":/(UCBrowser|UCWEB)\/(\d+(\.\d+)?)/,Safari:/Version\/(\d+(\.\d+)?)/,"Mobile Safari":/Version\/(\d+(\.\d+)?)/,Opera:/(Opera|OPR)\/(\d+(\.\d+)?)/,Firefox:/Firefox\/(\d+(\.\d+)?)/,"Firefox iOS":/FxiOS\/(\d+(\.\d+)?)/,Konqueror:/Konqueror:(\d+(\.\d+)?)/,BlackBerry:/BlackBerry (\d+(\.\d+)?)/,"Android Mobile":/android\s(\d+(\.\d+)?)/,"Samsung Internet":/SamsungBrowser\/(\d+(\.\d+)?)/,"Internet Explorer":/(rv:|MSIE )(\d+(\.\d+)?)/,Mozilla:/rv:(\d+(\.\d+)?)/}[mi.info.browser(e,t,n)];if(void 0===r)return null;var i=e.match(r);return i?parseFloat(i[i.length-2]):null},os:function(){var e=ui;return/Windows/i.test(e)?/Phone/.test(e)||/WPDesktop/.test(e)?"Windows Phone":"Windows":/(iPhone|iPad|iPod)/.test(e)?"iOS":/Android/.test(e)?"Android":/(BlackBerry|PlayBook|BB10)/i.test(e)?"BlackBerry":/Mac/i.test(e)?"Mac OS X":/Linux/.test(e)?"Linux":/CrOS/.test(e)?"Chrome OS":""},device:function(e){return/Windows Phone/i.test(e)||/WPDesktop/.test(e)?"Windows Phone":/iPad/.test(e)?"iPad":/iPod/.test(e)?"iPod Touch":/iPhone/.test(e)?"iPhone":/(BlackBerry|PlayBook|BB10)/i.test(e)?"BlackBerry":/Android/.test(e)?"Android":""},referringDomain:function(e){var t=e.split("/");return t.length>=3?t[2]:""},properties:function(){return mi.extend(mi.strip_empty_properties({$os:mi.info.os(),$browser:mi.info.browser(ui,oi.vendor,si),$referrer:ai.referrer,$referring_domain:mi.info.referringDomain(ai.referrer),$device:mi.info.device(ui)}),{$current_url:qr.location.href,$host:qr.location.host,$pathname:qr.location.pathname,$browser_version:mi.info.browserVersion(ui,oi.vendor,si),$screen_height:li.height,$screen_width:li.width,$lib:"web",$lib_version:$r.LIB_VERSION,$insert_id:Math.random().toString(36).substring(2,10)+Math.random().toString(36).substring(2,10),$time:mi.timestamp()/1e3})},people_properties:function(){return mi.extend(mi.strip_empty_properties({$os:mi.info.os(),$browser:mi.info.browser(ui,oi.vendor,si)}),{$browser_version:mi.info.browserVersion(ui,oi.vendor,si)})}},mi.toArray=mi.toArray,mi.isObject=mi.isObject,mi.JSONEncode=mi.JSONEncode,mi.JSONDecode=mi.JSONDecode,mi.isBlockedUA=mi.isBlockedUA,mi.isEmptyObject=mi.isEmptyObject,mi.info=mi.info,mi.info.device=mi.info.device,mi.info.browser=mi.info.browser,mi.info.browserVersion=mi.info.browserVersion,mi.info.properties=mi.info.properties;var Ai=["a","button","form","input","select","textarea","label"];function Si(e){for(var t=e;t.parentNode&&!Ei(t,"body");t=t.parentNode){var n=xi(t).split(" ");if(mi.includes(n,"ph-sensitive")||mi.includes(n,"ph-no-capture"))return!1}if(mi.includes(xi(e).split(" "),"ph-include"))return!0;var r=e.type||"";if("string"==typeof r)switch(r.toLowerCase()){case"hidden":case"password":return!1}var i=e.name||e.id||"";if("string"==typeof i){if(/^cc|cardnum|ccnum|creditcard|csc|cvc|cvv|exp|pass|pwd|routing|seccode|securitycode|securitynum|socialsec|socsec|ssn/i.test(i.replace(/[^a-zA-Z0-9]/g,"")))return!1}return!0}function ji(e){return!!(Ei(e,"input")&&"button"!=e.type||Ei(e,"select")||Ei(e,"textarea")||"true"===e.getAttribute("contenteditable"))}function Ti(e){if(null===e||mi.isUndefined(e))return!1;if("string"==typeof e){e=mi.trim(e);if(/^(?:(4[0-9]{12}(?:[0-9]{3})?)|(5[1-5][0-9]{14})|(6(?:011|5[0-9]{2})[0-9]{12})|(3[47][0-9]{13})|(3(?:0[0-5]|[68][0-9])[0-9]{11})|((?:2131|1800|35[0-9]{3})[0-9]{11}))$/.test((e||"").replace(/[- ]/g,"")))return!1;if(/(^\d{3}-?\d{2}-?\d{4}$)/.test(e))return!1}return!0}var Di={_initializedTokens:[],_previousElementSibling:function(e){if(e.previousElementSibling)return e.previousElementSibling;do{e=e.previousSibling}while(e&&!Ci(e));return e},_loadScript:function(e,t){var n=document.createElement("script");n.type="text/javascript",n.src=e,n.onload=t;var r=document.getElementsByTagName("script");r.length>0?r[0].parentNode.insertBefore(n,r[0]):document.body.appendChild(n)},_getPropertiesFromElement:function(e){var t=e.tagName.toLowerCase(),n={tag_name:t};Ai.indexOf(t)>-1&&(n.$el_text=ki(e));var r=xi(e);r.length>0&&(n.classes=r.split(" ")),mi.each(e.attributes,(function(t){ji(e)&&-1===["name","id","class"].indexOf(t.name)||Ti(t.value)&&(n["attr__"+t.name]=t.value)}));for(var i=1,o=1,a=e;a=this._previousElementSibling(a);)i++,a.tagName===e.tagName&&o++;return n.nth_child=i,n.nth_of_type=o,n},_getDefaultProperties:function(e){return{$event_type:e,$ce_version:1}},_extractCustomPropertyValue:function(e){var t=[];return mi.each(document.querySelectorAll(e.css_selector),(function(e){var n;["input","select"].indexOf(e.tagName.toLowerCase())>-1?n=e.value:e.textContent&&(n=e.textContent),Ti(n)&&t.push(n)})),t.join(", ")},_getCustomProperties:function(e){var t={};return mi.each(this._customProperties,(function(n){mi.each(n.event_selectors,(function(r){var i=document.querySelectorAll(r);mi.each(i,(function(r){mi.includes(e,r)&&Si(r)&&(t[n.name]=this._extractCustomPropertyValue(n))}),this)}),this)}),this),t},_getEventTarget:function(e){return void 0===e.target?e.srcElement:e.target.shadowRoot?e.composedPath()[0]:e.target},_captureEvent:function(e,t){var n=this._getEventTarget(e);if(Oi(n)&&(n=n.parentNode),function(e,t){if(!e||Ei(e,"html")||!Ci(e))return!1;for(var n=!1,r=[e],i=!0,o=e;o.parentNode&&!Ei(o,"body");)if(11!==o.parentNode.nodeType){if(!(i=o.parentNode))break;if(Ai.indexOf(i.tagName.toLowerCase())>-1)n=!0;else{let e=window.getComputedStyle(i);e&&"pointer"===e.getPropertyValue("cursor")&&(n=!0)}r.push(i),o=i}else r.push(o.parentNode.host),o=o.parentNode.host;let a=window.getComputedStyle(e);if(a&&"pointer"===a.getPropertyValue("cursor")&&"click"===t.type)return!0;var s=e.tagName.toLowerCase();switch(s){case"html":return!1;case"form":return"submit"===t.type;case"input":return"change"===t.type||"click"===t.type;case"select":case"textarea":return"change"===t.type||"click"===t.type;default:return n?"click"===t.type:"click"===t.type&&(Ai.indexOf(s)>-1||"true"===e.getAttribute("contenteditable"))}}(n,e)){for(var r=[n],i=n;i.parentNode&&!Ei(i,"body");)11!==i.parentNode.nodeType?(r.push(i.parentNode),i=i.parentNode):(r.push(i.parentNode.host),i=i.parentNode.host);var o,a=[],s=!1;if(mi.each(r,(function(e){var t=Si(e);"a"===e.tagName.toLowerCase()&&(o=e.getAttribute("href"),o=t&&Ti(o)&&o);var n=xi(e).split(" ");mi.includes(n,"ph-no-capture")&&(s=!0),a.push(this._getPropertiesFromElement(e))}),this),a[0].$el_text=ki(n),o&&(a[0].attr__href=o),s)return!1;var l=ki(n);l&&l.length;var u=mi.extend(this._getDefaultProperties(e.type),{$elements:a},this._getCustomProperties(r));return t.capture("$autocapture",u),!0}},_navigate:function(e){window.location.href=e},_addDomEventHandlers:function(e){var t=mi.bind((function(t){t=t||window.event,this._captureEvent(t,e)}),this);mi.register_event(document,"submit",t,!1,!0),mi.register_event(document,"change",t,!1,!0),mi.register_event(document,"click",t,!1,!0)},_customProperties:{},init:function(e){this._maybeLoadEditor(e);var t=e.get_config("token");if(this._initializedTokens.indexOf(t)>-1)console.log('autocapture already initialized for token "'+t+'"');else{this._initializedTokens.push(t);var n=mi.bind((function(t){if(!document||!document.body)return console.log("document not ready yet, trying again in 500 milliseconds..."),void setTimeout((function(){n(t)}),500);var r=t.editorParams||(t.toolbarVersion?{toolbarVersion:t.toolbarVersion}:{});if(t.isAuthenticated&&r.toolbarVersion&&0===r.toolbarVersion.indexOf("toolbar")&&(this._loadEditor(e,Object.assign({},r,{apiURL:e.get_config("api_host")})),e.set_config({debug:!0})),t&&t.config&&!0===t.config.enable_collect_everything?(t.custom_properties&&(this._customProperties=t.custom_properties),this._addDomEventHandlers(e)):e.__autocapture_enabled=!1,t.featureFlags?e.persistence&&e.persistence.register({$active_feature_flags:t.featureFlags}):e.persistence&&e.persistence.unregister("$active_feature_flags"),t.supportedCompression){let n={};for(const e of t.supportedCompression)n[e]=!0;e.compression=n}else e.compression={}}),this),r=mi.JSONEncode({token:t,distinct_id:e.get_distinct_id()}),i=mi.base64Encode(r);e._send_request(e.get_config("api_host")+"/decide/",{data:i},{method:"POST"},e._prepare_callback(n))}},_maybeLoadEditor:function(e){try{var t,n=mi.getHashParam(window.location.hash,"__posthog")||mi.getHashParam(window.location.hash,"state"),r=n?JSON.parse(decodeURIComponent(n)):null;return r&&("mpeditor"===r.action||"ph_authorize"===r.action)?(t=r)&&Object.keys(t).length>0&&(window.localStorage.setItem("_postHogEditorParams",JSON.stringify(t)),r.desiredHash?window.location.hash=r.desiredHash:window.history?history.replaceState("",document.title,window.location.pathname+window.location.search):window.location.hash=""):delete(t=JSON.parse(window.localStorage.getItem("_postHogEditorParams")||"{}")).userIntent,t.apiURL=e.get_config("api_host"),!(!t.token||e.get_config("token")!==t.token)&&(this._loadEditor(e,t),!0)}catch(i){return!1}},_loadEditor:function(e,t){var n=this;if(!window._postHogToolbarLoaded){window._postHogToolbarLoaded=!0;var r=t.jsURL||t.apiURL||e.get_config("api_host"),i=t.toolbarVersion&&0===t.toolbarVersion.indexOf("toolbar")?"toolbar.js":"editor.js",o=r+(r.endsWith("/")?"":"/")+"static/"+i+"?_ts="+(new Date).getTime();return this._loadScript(o,(function(){window.ph_load_editor(t)})),mi.register_event(window,"turbolinks:load",(function(){window._postHogToolbarLoaded=!1,n._loadEditor(e,t)})),!0}return!1},enabledForProject:function(e,t,n){t=mi.isUndefined(t)?10:t,n=mi.isUndefined(n)?10:n;for(var r=0,i=0;i<e.length;i++)r+=e.charCodeAt(i);return r%t<n},isBrowserSupported:function(){return mi.isFunction(document.querySelectorAll)}};mi.bind_instance_methods(Di),mi.safewrap_instance_methods(Di);var Ni=function(){};Ni.prototype.create_properties=function(){},Ni.prototype.event_handler=function(){},Ni.prototype.after_capture_handler=function(){},Ni.prototype.init=function(e){return this.mp=e,this},Ni.prototype.capture=function(e,t,n,r){var i=this,o=mi.dom_query(e);if(0!==o.length)return mi.each(o,(function(e){mi.register_event(e,this.override_event,(function(e){var o={},a=i.create_properties(n,this),s=i.mp.get_config("capture_links_timeout");i.event_handler(e,this,o),window.setTimeout(i.capture_callback(r,a,o,!0),s),i.mp.capture(t,a,i.capture_callback(r,a,o))}))}),this),!0;yi("The DOM query ("+e+") returned 0 elements")},Ni.prototype.capture_callback=function(e,t,n,r){r=r||!1;var i=this;return function(){n.callback_fired||(n.callback_fired=!0,e&&!1===e(r,t)||i.after_capture_handler(t,n,r))}},Ni.prototype.create_properties=function(e,t){return"function"==typeof e?e(t):mi.extend({},e)};var Li=function(){this.override_event="click"};mi.inherit(Li,Ni),Li.prototype.create_properties=function(e,t){var n=Li.superclass.create_properties.apply(this,arguments);return t.href&&(n.url=t.href),n},Li.prototype.event_handler=function(e,t,n){n.new_tab=2===e.which||e.metaKey||e.ctrlKey||"_blank"===t.target,n.href=t.href,n.new_tab||e.preventDefault()},Li.prototype.after_capture_handler=function(e,t){t.new_tab||setTimeout((function(){window.location=t.href}),0)};var Mi=function(){this.override_event="submit"};mi.inherit(Mi,Ni),Mi.prototype.event_handler=function(e,t,n){n.element=t,e.preventDefault()},Mi.prototype.after_capture_handler=function(e,t){setTimeout((function(){t.element.submit()}),0)};function Pi(e,t){Hi(!0,e,t)}function Fi(e,t){Hi(!1,e,t)}function qi(e,t){return"1"===Wi(e,t)}function Ii(e,t){return!!function(e){if(e&&e.respectDnt){var t=e&&e.window||qr,n=t.navigator||{},r=!1;return mi.each([n.doNotTrack,n.msDoNotTrack,t.doNotTrack],(function(e){mi.includes([!0,1,"1","yes"],e)&&(r=!0)})),r}return!1}(t)||"0"===Wi(e,t)}function $i(e,t){return Ui(e,(function(e){return this._get_config(e)}),t)}function Ri(e,t){zi(t=t||{}).remove(Bi(e,t),!!t.crossSubdomainCookie,t.cookieDomain)}function zi(e){return"localStorage"===(e=e||{}).persistenceType?mi.localStorage:mi.cookie}function Bi(e,t){return((t=t||{}).persistencePrefix||"__ph_opt_in_out_")+e}function Wi(e,t){return zi(t).get(Bi(e,t))}function Hi(e,t,n){mi.isString(t)&&t.length?(zi(n=n||{}).set(Bi(t,n),e?1:0,mi.isNumber(n.cookieExpiration)?n.cookieExpiration:null,!!n.crossSubdomainCookie,!!n.secureCookie,!!n.crossSiteCookie,n.cookieDomain),n.capture&&e&&n.capture(n.captureEventName||"$opt_in",n.captureProperties,{send_immediately:!0})):console.error("gdpr."+(e?"optIn":"optOut")+" called with an invalid token")}function Ui(e,t,n){return function(){var r=!1;try{var i=t.call(this,"token"),o=t.call(this,"respect_dnt"),a=t.call(this,"opt_out_capturing_persistence_type"),s=t.call(this,"opt_out_capturing_cookie_prefix"),l=t.call(this,"window");i&&(r=Ii(i,{respectDnt:o,persistenceType:a,persistencePrefix:s,window:l}))}catch(c){n||console.error("Unexpected error when checking capturing opt-out status: "+c)}if(!r)return e.apply(this,arguments);var u=arguments[arguments.length-1];"function"==typeof u&&u(0)}}var Vi={set_action:function(e,t){var n={},r={};return mi.isObject(e)?mi.each(e,(function(e,t){this._is_reserved_property(t)||(r[t]=e)}),this):r[e]=t,n.$set=r,n},set_once_action:function(e,t){var n={},r={};return mi.isObject(e)?mi.each(e,(function(e,t){this._is_reserved_property(t)||(r[t]=e)}),this):r[e]=t,n.$set_once=r,n}},Ki=function(){};mi.extend(Ki.prototype,Vi),Ki.prototype._init=function(e){this._posthog=e},Ki.prototype.set=$i((function(e,t,n){var r=this.set_action(e,t);return mi.isObject(e)&&(n=t),this._get_config("save_referrer")&&this._posthog.persistence.update_referrer_info(document.referrer),r.$set=mi.extend({},mi.info.people_properties(),this._posthog.persistence.get_referrer_info(),r.$set),this._send_request(r,n)})),Ki.prototype.set_once=$i((function(e,t,n){var r=this.set_once_action(e,t);return mi.isObject(e)&&(n=t),this._send_request(r,n)})),Ki.prototype.toString=function(){return this._posthog.toString()+".people"},Ki.prototype._send_request=function(e,t){e.$token=this._get_config("token"),e.$distinct_id=this._posthog.get_distinct_id();var n=this._posthog.get_property("$device_id"),r=this._posthog.get_property("$user_id"),i=this._posthog.get_property("$had_persisted_distinct_id");n&&(e.$device_id=n),r&&(e.$user_id=r),i&&(e.$had_persisted_distinct_id=i);var o=mi.encodeDates(e),a=mi.truncate(o,255),s=mi.JSONEncode(o),l=mi.base64Encode(s);return this._posthog._send_request(this._get_config("api_host")+"/engage/",{data:l},this._posthog._prepare_callback(t,a)),a},Ki.prototype._get_config=function(e){return this._posthog.get_config(e)},Ki.prototype._identify_called=function(){return!0===this._posthog._flags.identify_called},Ki.prototype._enqueue=function(e){"$set"in e?this._posthog.persistence._add_to_people_queue("$set",e):"$set_once"in e?this._posthog.persistence._add_to_people_queue("$set_once",e):yi("Invalid call to _enqueue():",e)},Ki.prototype._flush_one_queue=function(e,t,n,r){var i=this,o=mi.extend({},this._posthog.persistence._get_queue(e)),a=o;mi.isUndefined(o)||!mi.isObject(o)||mi.isEmptyObject(o)||(i._posthog.persistence._pop_from_people_queue(e,o),r&&(a=r(o)),t.call(i,a,(function(t,r){0===t&&i._posthog.persistence._add_to_people_queue(e,o),mi.isUndefined(n)||n(t,r)})))},Ki.prototype._flush=function(e,t){this._flush_one_queue("$set",this.set,e),this._flush_one_queue("$set_once",this.set_once,t)},Ki.prototype._is_reserved_property=function(e){return"$distinct_id"===e||"$token"===e||"$device_id"===e||"$user_id"===e||"$had_persisted_distinct_id"===e},Ki.prototype.set=Ki.prototype.set,Ki.prototype.set_once=Ki.prototype.set_once,Ki.prototype.toString=Ki.prototype.toString;var Yi=function(){};Yi.prototype._init=function(e){this._posthog=e},Yi.prototype.getFlags=function(){return this._posthog.persistence.props.$override_feature_flags?(this._override_warning||console.warn("[PostHog] Overriding feature flags! Feature flags from server were: "+JSON.stringify(this._posthog.persistence.props.$active_feature_flags)),this._override_warning=!0,this._posthog.persistence.props.$override_feature_flags):this._posthog.persistence.props.$active_feature_flags},Yi.prototype.reloadFeatureFlags=function(){var e=this._posthog,t=mi.bind((function(t){t.featureFlags?e.persistence&&e.persistence.register({$active_feature_flags:t.featureFlags}):e.persistence&&e.persistence.unregister("$active_feature_flags")})),n=e.config.token,r=mi.JSONEncode({token:n,distinct_id:e.get_distinct_id()}),i=mi.base64Encode(r);e._send_request(e.get_config("api_host")+"/decide/",{data:i},{method:"POST"},e._prepare_callback(t))},Yi.prototype.isFeatureEnabled=function(e){return this.getFlags()?this.getFlags().indexOf(e)>-1:(console.warn('isFeatureEnabled for key "'+e+"\" failed. Feature flags didn't load in time."),!1)},Yi.prototype.override=function(e){if(!1===e)return this._posthog.persistence.unregister("$override_feature_flags");this._posthog.persistence.register("$override_feature_flags",e)};var Gi,Zi,Xi=["__mps","__mpso","__mpus","__mpa","__mpap","__mpr","__mpu","$people_distinct_id","__alias","__cmpns","__timers"],Ji=function(e){this.props={},this.campaign_params_saved=!1,this.featureFlagEventHandlers=[],e.persistence_name?this.name="ph_"+e.persistence_name:this.name="ph_"+e.token+"_posthog";var t=e.persistence;"cookie"!==t&&"localStorage"!==t&&(bi("Unknown persistence type "+t+"; falling back to cookie"),t=e.persistence="cookie"),"localStorage"===t&&mi.localStorage.is_supported()?this.storage=mi.localStorage:this.storage=mi.cookie,this.load(),this.update_config(e),this.upgrade(e),this.save()};Ji.prototype.addFeatureFlagsHandler=function(e){return this.featureFlagEventHandlers.push(e),!0},Ji.prototype.receivedFeatureFlags=function(e){this.featureFlagEventHandlers.forEach((t=>t(e)))},Ji.prototype.properties=function(){var e={};return mi.each(this.props,(function(t,n){mi.include(Xi,n)||(e[n]=t)})),e},Ji.prototype.load=function(){if(!this.disabled){var e=this.storage.parse(this.name);e&&(this.props=mi.extend({},e))}},Ji.prototype.upgrade=function(e){var t,n,r=e.upgrade;r&&(t="ph_super_properties","string"==typeof r&&(t=r),n=this.storage.parse(t),this.storage.remove(t),this.storage.remove(t,!0),n&&(this.props=mi.extend(this.props,n.all,n.events))),e.cookie_name||"posthog"===e.name||(t="ph_"+e.token+"_"+e.name,(n=this.storage.parse(t))&&(this.storage.remove(t),this.storage.remove(t,!0),this.register_once(n))),this.storage===mi.localStorage&&(n=mi.cookie.parse(this.name),mi.cookie.remove(this.name),mi.cookie.remove(this.name,!0),n&&this.register_once(n))},Ji.prototype.save=function(){this.disabled||(this._expire_notification_campaigns(),this.storage.set(this.name,mi.JSONEncode(this.props),this.expire_days,this.cross_subdomain,this.secure))},Ji.prototype.remove=function(){this.storage.remove(this.name,!1),this.storage.remove(this.name,!0)},Ji.prototype.clear=function(){this.remove(),this.props={}},Ji.prototype.register_once=function(e,t,n){return!!mi.isObject(e)&&(void 0===t&&(t="None"),this.expire_days=void 0===n?this.default_expiry:n,e&&e.$active_feature_flags&&this.receivedFeatureFlags(e.$active_feature_flags),mi.each(e,(function(e,n){this.props.hasOwnProperty(n)&&this.props[n]!==t||(this.props[n]=e)}),this),this.save(),!0)},Ji.prototype.register=function(e,t){return!!mi.isObject(e)&&(this.expire_days=void 0===t?this.default_expiry:t,e&&e.$active_feature_flags&&this.receivedFeatureFlags(e.$active_feature_flags),mi.extend(this.props,e),this.save(),!0)},Ji.prototype.unregister=function(e){e in this.props&&(delete this.props[e],this.save(),"$active_feature_flags"===e&&this.receivedFeatureFlags([]))},Ji.prototype._expire_notification_campaigns=mi.safewrap((function(){var e=this.props.__cmpns,t=$r.DEBUG?6e4:36e5;if(e){for(var n in e)1*new Date-e[n]>t&&delete e[n];mi.isEmptyObject(e)&&delete this.props.__cmpns}})),Ji.prototype.update_campaign_params=function(){this.campaign_params_saved||(this.register_once(mi.info.campaignParams()),this.campaign_params_saved=!0)},Ji.prototype.update_search_keyword=function(e){this.register(mi.info.searchInfo(e))},Ji.prototype.update_referrer_info=function(e){this.register_once({$initial_referrer:e||"$direct",$initial_referring_domain:mi.info.referringDomain(e)||"$direct"},"")},Ji.prototype.get_referrer_info=function(){return mi.strip_empty_properties({$initial_referrer:this.props.$initial_referrer,$initial_referring_domain:this.props.$initial_referring_domain})},Ji.prototype.safe_merge=function(e){return mi.each(this.props,(function(t,n){n in e||(e[n]=t)})),e},Ji.prototype.update_config=function(e){this.default_expiry=this.expire_days=e.cookie_expiration,this.set_disabled(e.disable_persistence),this.set_cross_subdomain(e.cross_subdomain_cookie),this.set_secure(e.secure_cookie)},Ji.prototype.set_disabled=function(e){this.disabled=e,this.disabled?this.remove():this.save()},Ji.prototype.set_cross_subdomain=function(e){e!==this.cross_subdomain&&(this.cross_subdomain=e,this.remove(),this.save())},Ji.prototype.get_cross_subdomain=function(){return this.cross_subdomain},Ji.prototype.set_secure=function(e){e!==this.secure&&(this.secure=!!e,this.remove(),this.save())},Ji.prototype._add_to_people_queue=function(e,t){var n=this._get_queue_key(e),r=t[e],i=this._get_or_create_queue("$set"),o=this._get_or_create_queue("$set_once");"__mps"===n?mi.extend(i,r):"__mpso"===n&&mi.each(r,(function(e,t){t in o||(o[t]=e)})),this.save()},Ji.prototype._pop_from_people_queue=function(e,t){var n=this._get_queue(e);mi.isUndefined(n)||(mi.each(t,(function(e,t){delete n[t]}),this),this.save())},Ji.prototype._get_queue_key=function(e){return"$set"===e?"__mps":"$set_once"===e?"__mpso":void yi("Invalid queue:",e)},Ji.prototype._get_queue=function(e){return this.props[this._get_queue_key(e)]},Ji.prototype._get_or_create_queue=function(e,t){var n=this._get_queue_key(e);return t=mi.isUndefined(t)?{}:t,this.props[n]||(this.props[n]=t)},Ji.prototype.set_event_timer=function(e,t){var n=this.props.__timers||{};n[e]=t,this.props.__timers=n,this.save()},Ji.prototype.remove_event_timer=function(e){var t=(this.props.__timers||{})[e];return mi.isUndefined(t)||(delete this.props.__timers[e],this.save()),t};var Qi=function(){},eo={},to=qr.XMLHttpRequest&&"withCredentials"in new XMLHttpRequest,no=!to&&-1===ui.indexOf("MSIE")&&-1===ui.indexOf("Mozilla"),ro=qr.navigator.sendBeacon;ro&&(ro=mi.bind(ro,oi));var io,oo={api_host:"https://app.posthog.com",api_method:"POST",api_transport:"XHR",autocapture:!0,cross_subdomain_cookie:-1===ai.location.hostname.indexOf("herokuapp.com"),persistence:"cookie",persistence_name:"",cookie_name:"",loaded:function(){},store_google:!0,save_referrer:!0,test:!1,verbose:!1,img:!1,capture_pageview:!0,debug:!1,capture_links_timeout:300,cookie_expiration:365,upgrade:!1,disable_persistence:!1,disable_cookie:!1,secure_cookie:"https:"===qr.location.protocol,ip:!0,opt_out_capturing_by_default:!1,opt_out_persistence_by_default:!1,opt_out_capturing_persistence_type:"localStorage",opt_out_capturing_cookie_prefix:null,property_blacklist:[],sanitize_properties:null,xhr_headers:{},inapp_protocol:"//",inapp_link_new_window:!1,request_batching:!0},ao=!1,so=function(){},lo=function(e,t,n){var r,i="posthog"===n?Zi:Zi[n];if(i&&0===Gi)r=i;else{if(i&&!mi.isArray(i))return void yi("You have already initialized "+n);r=new so}if(r._cached_groups={},r._user_decide_check_complete=!1,r._events_captureed_before_user_decide_check_complete=[],r._init(e,t,n),r.people=new Ki,r.people._init(r),r.feature_flags=new Yi,r.feature_flags._init(r),$r.DEBUG=$r.DEBUG||r.get_config("debug"),r.__autocapture_enabled=r.get_config("autocapture"),r.get_config("autocapture")){Di.enabledForProject(r.get_config("token"),100,100)?Di.isBrowserSupported()?Di.init(r):(r.__autocapture_enabled=!1,vi("Disabling Automatic Event Collection because this browser is not supported")):(r.__autocapture_enabled=!1,vi("Not in active bucket: disabling Automatic Event Collection."))}return!mi.isUndefined(i)&&mi.isArray(i)&&(r._execute_array.call(r.people,i.people),r._execute_array(i)),r};function uo(e){qr.console.warn("WARNING! posthog."+e+" is deprecated and will be removed soon! Please use posthog."+e.split("captureing").join("capturing")+' instead (without the "e")!')}so.prototype.init=function(e,t,n){if(mi.isUndefined(n))yi("You must name your new library: init(token, config, name)");else{if("posthog"!==n){var r=lo(e,t,n);return Zi[n]=r,r._loaded(),r}yi("You must initialize the main posthog object right after you include the PostHog js snippet")}},so.prototype._init=function(e,t,n){this.__loaded=!0,this.config={},this._triggered_notifs=[],this.compression={},this.set_config(mi.extend({},oo,t,{name:n,token:e,callback_fn:("posthog"===n?n:"posthog."+n)+"._jsc"})),this._jsc=function(){},this._event_queue=[],this._empty_queue_count=0,this._should_poll=!0,this._poller=function(){},this.__dom_loaded_queue=[],this.__request_queue=[],this.__disabled_events=[],this._flags={disable_all_events:!1,identify_called:!1},this.persistence=this.cookie=new Ji(this.config),this._gdpr_init();var r=mi.UUID();this.get_distinct_id()||this.register_once({distinct_id:r,$device_id:r},""),qr.addEventListener&&qr.addEventListener("unload",this._handle_unload.bind(this))},so.prototype._loaded=function(){this.get_config("loaded")(this),this._start_queue_if_opted_in(),this.get_config("capture_pageview")&&this.capture_pageview()},so.prototype._start_queue_if_opted_in=function(){this.has_opted_out_capturing()||this.get_config("request_batching")&&this._event_queue_poll()},so.prototype._dom_loaded=function(){mi.each(this.__dom_loaded_queue,(function(e){this._capture_dom.apply(this,e)}),this),this.has_opted_out_capturing()||mi.each(this.__request_queue,(function(e){this._send_request.apply(this,e)}),this),delete this.__dom_loaded_queue,delete this.__request_queue,this._start_queue_if_opted_in()},so.prototype._capture_dom=function(e,t){if(this.get_config("img"))return yi("You can't use DOM capturing functions with img = true."),!1;if(!ao)return this.__dom_loaded_queue.push([e,t]),!1;var n=(new e).init(this);return n.capture.apply(n,t)},so.prototype._prepare_callback=function(e,t){if(mi.isUndefined(e))return null;if(to){return function(n){e(n,t)}}var n=this._jsc,r=""+Math.floor(1e8*Math.random()),i=this.get_config("callback_fn")+"["+r+"]";return n[r]=function(i){delete n[r],e(i,t)},i},so.prototype._event_enqueue=function(e,t,n,r){this._event_queue.push({url:e,data:t,options:n,callback:r}),this._should_poll||(this._should_poll=!0,this._event_queue_poll())},so.prototype._format_event_queue_data=function(){const e={};return mi.each(this._event_queue,(t=>{const{url:n,data:r}=t;void 0===e[n]&&(e[n]=[]),e[n].push(r)})),e},so.prototype._event_queue_poll=function(){clearInterval(this._poller),this._poller=setTimeout((()=>{if(this._event_queue.length>0){const n=this._format_event_queue_data();for(let r in n){let i=n[r];mi.each(i,(function(e,t){i[t].offset=Math.abs(i[t].timestamp-new Date),delete i[t].timestamp}));var e=mi.JSONEncode(i);if(this.compression.lz64){var t=Ir.compressToBase64(e);this._send_request(r,{data:t,compression:"lz64"},eo,Qi)}else{t=mi.base64Encode(e);this._send_request(r,{data:t},eo,Qi)}}this._event_queue.length=0}else this._empty_queue_count++;this._empty_queue_count>4&&(this._should_poll=!1,this._empty_queue_count=0),this._should_poll&&this._event_queue_poll()}),3e3)},so.prototype._handle_unload=function(){if(!this.get_config("request_batching"))return void this.capture("$pageleave",null,{transport:"sendbeacon"});clearInterval(this._poller),this.capture("$pageleave");let e={};this._event_queue.length>0&&(e=this._format_event_queue_data()),this._event_queue.length=0;for(let t in e)if(this.compression.lz64){const n=Ir.compressToBase64(mi.JSONEncode(e[t]));this._send_request(t,{data:n,compression:"lz64"},{transport:"sendbeacon"},Qi)}else{const n=mi.base64Encode(mi.JSONEncode(e[t]));this._send_request(t,{data:n},{transport:"sendbeacon"},Qi)}},so.prototype._send_request=function(e,t,n,r){if(no)this.__request_queue.push(arguments);else{var i={method:this.get_config("api_method"),transport:this.get_config("api_transport")},o=null;r||!mi.isFunction(n)&&"string"!=typeof n||(r=n,n=null),n=mi.extend(i,n||{}),to||(n.method="GET");var a=ro&&"sendbeacon"===n.transport.toLowerCase(),s=a||"POST"===n.method,l=this.get_config("verbose");t.verbose&&(l=!0),this.get_config("test")&&(t.test=1),l&&(t.verbose=1),this.get_config("img")&&(t.img=1),to||(r?t.callback=r:(l||this.get_config("test"))&&(t.callback="(function(){})"));var u={};if(u.ip=this.get_config("ip")?1:0,u._=(new Date).getTime().toString(),s&&(o=Array.isArray(t)?"data="+encodeURIComponent(t):"data="+encodeURIComponent(t.data),delete t.data,t.compression&&(o+="&compression="+t.compression,delete t.compression)),e+="?"+mi.HTTPBuildQuery(u),"img"in t){var c=ai.createElement("img");c.src=e,ai.body.appendChild(c)}else if(a){const t=new Blob([o],{type:"application/x-www-form-urlencoded"});ro(e,t)}else if(to)try{var f=new XMLHttpRequest;f.open(n.method,e,!0);var p=this.get_config("xhr_headers");s&&(p["Content-Type"]="application/x-www-form-urlencoded"),mi.each(p,(function(e,t){f.setRequestHeader(t,e)})),f.withCredentials=!0,f.onreadystatechange=function(){if(4===f.readyState)if(200===f.status){if(r){var e;try{e=mi.JSONDecode(f.responseText)}catch(n){return void yi(n)}r(e)}}else{var t="Bad HTTP status: "+f.status+" "+f.statusText;yi(t),r&&r(l?{status:0,error:t}:0)}},f.send(o)}catch(g){yi(g)}else{var d=ai.createElement("script");d.type="text/javascript",d.async=!0,d.defer=!0,d.src=e;var h=ai.getElementsByTagName("script")[0];h.parentNode.insertBefore(d,h)}}},so.prototype._execute_array=function(e){var t,n=[],r=[],i=[];mi.each(e,(function(e){e&&(t=e[0],mi.isArray(t)?i.push(e):"function"==typeof e?e.call(this):mi.isArray(e)&&"alias"===t?n.push(e):mi.isArray(e)&&-1!==t.indexOf("capture")&&"function"==typeof this[t]?i.push(e):r.push(e))}),this);var o=function(e,t){mi.each(e,(function(e){if(mi.isArray(e[0])){var n=t;mi.each(e,(function(e){n=n[e[0]].apply(n,e.slice(1))}))}else this[e[0]].apply(this,e.slice(1))}),t)};o(n,this),o(r,this),o(i,this)},so.prototype.push=function(e){this._execute_array([e])},so.prototype.capture=Ui((function(e,t,n,r){r||"function"!=typeof n||(r=n,n=null);var i=(n=n||eo).transport;if(i&&(n.transport=i),"function"!=typeof r&&(r=Qi),mi.isUndefined(e))return void yi("No event name provided to posthog.capture");if(this._event_is_disabled(e))return void r(0);(t=t||{}).token=this.get_config("token");var o=this.persistence.remove_event_timer(e);if(!mi.isUndefined(o)){var a=(new Date).getTime()-o;t.$duration=parseFloat((a/1e3).toFixed(3))}this.persistence.update_search_keyword(ai.referrer),this.get_config("store_google")&&this.persistence.update_campaign_params(),this.get_config("save_referrer")&&this.persistence.update_referrer_info(ai.referrer),t=mi.extend({},mi.info.properties(),this.persistence.properties(),t);var s=this.get_config("property_blacklist");mi.isArray(s)?mi.each(s,(function(e){delete t[e]})):yi("Invalid value for property_blacklist config: "+s);var l=this.get_config("sanitize_properties");l&&(t=l(t,e));var u={event:e,properties:t},c=mi.truncate(u,255),f=mi.JSONEncode(c);const p=this.get_config("api_host")+"/e/",d=this._prepare_callback(r,c),h=r!==Qi||n!==eo;return!this.get_config("request_batching")||h?this.compression.lz64?this._send_request(p,{data:Ir.compressToBase64(f),compression:"lz64"},n,d):this._send_request(p,{data:mi.base64Encode(f)},n,d):(u.timestamp=new Date,this._event_enqueue(p,u,n,d)),c}),(function(e){return this.get_config(e)}),io),so.prototype._create_map_key=function(e,t){return e+"_"+JSON.stringify(t)},so.prototype._remove_group_from_cache=function(e,t){delete this._cached_groups[this._create_map_key(e,t)]},so.prototype.capture_pageview=function(e){mi.isUndefined(e)&&(e=ai.location.href),this.capture("$pageview")},so.prototype.capture_links=function(){return this._capture_dom.call(this,Li,arguments)},so.prototype.capture_forms=function(){return this._capture_dom.call(this,FormCaptureer,arguments)},so.prototype.register=function(e,t){this.persistence.register(e,t)},so.prototype.register_once=function(e,t,n){this.persistence.register_once(e,t,n)},so.prototype.unregister=function(e){this.persistence.unregister(e)},so.prototype._register_single=function(e,t){var n={};n[e]=t,this.register(n)},so.prototype.isFeatureEnabled=function(e){return this.feature_flags.isFeatureEnabled(e)},so.prototype.reloadFeatureFlags=function(){return this.feature_flags.reloadFeatureFlags()},so.prototype.onFeatureFlags=function(e){this.persistence.addFeatureFlagsHandler(e);const t=this.feature_flags.getFlags();t&&e(t)},so.prototype.identify=function(e,t,n){if(e){var r=this.get_distinct_id();if(this.register({$user_id:e}),!this.get_property("$device_id")){var i=r;this.register_once({$had_persisted_distinct_id:!0,$device_id:i},"")}e!==r&&e!==this.get_property("__alias")&&(this.unregister("__alias"),this.register({distinct_id:e})),this._flags.identify_called=!0,this.people._flush(t,n),e!==r&&this.capture("$identify",{distinct_id:e,$anon_distinct_id:r}),this.reloadFeatureFlags()}else yi("Unique user id has not been set in posthog.identify")},so.prototype.reset=function(e){let t=this.get_property("$device_id");this.persistence.clear(),this._flags.identify_called=!1;var n=mi.UUID();this.register_once({distinct_id:n,$device_id:e?n:t},"")},so.prototype.get_distinct_id=function(){return this.get_property("distinct_id")},so.prototype.alias=function(e,t){if(e===this.get_property("$people_distinct_id"))return bi("Attempting to create alias for existing People user - aborting."),-2;var n=this;return mi.isUndefined(t)&&(t=this.get_distinct_id()),e!==t?(this._register_single("__alias",e),this.capture("$create_alias",{alias:e,distinct_id:t},(function(){n.identify(e)}))):(yi("alias matches current distinct_id - skipping api call."),this.identify(e),-1)},so.prototype.set_config=function(e){mi.isObject(e)&&(mi.extend(this.config,e),this.get_config("persistence_name")||(this.config.persistence_name=this.config.cookie_name),this.get_config("disable_persistence")||(this.config.disable_persistence=this.config.disable_cookie),this.persistence&&this.persistence.update_config(this.config),$r.DEBUG=$r.DEBUG||this.get_config("debug"))},so.prototype.get_config=function(e){return this.config[e]},so.prototype.get_property=function(e){return this.persistence.props[e]},so.prototype.toString=function(){var e=this.get_config("name");return"posthog"!==e&&(e="posthog."+e),e},so.prototype._event_is_disabled=function(e){return mi.isBlockedUA(ui)||this._flags.disable_all_events||mi.include(this.__disabled_events,e)},so.prototype._gdpr_init=function(){"localStorage"===this.get_config("opt_out_capturing_persistence_type")&&mi.localStorage.is_supported()&&(!this.has_opted_in_capturing()&&this.has_opted_in_capturing({persistence_type:"cookie"})&&this.opt_in_capturing({enable_persistence:!1}),!this.has_opted_out_capturing()&&this.has_opted_out_capturing({persistence_type:"cookie"})&&this.opt_out_capturing({clear_persistence:!1}),this.clear_opt_in_out_capturing({persistence_type:"cookie",enable_persistence:!1})),this.has_opted_out_capturing()?this._gdpr_update_persistence({clear_persistence:!0}):this.has_opted_in_capturing()||!this.get_config("opt_out_capturing_by_default")&&!mi.cookie.get("ph_optout")||(mi.cookie.remove("ph_optout"),this.opt_out_capturing({clear_persistence:this.get_config("opt_out_persistence_by_default")}))},so.prototype._gdpr_update_persistence=function(e){var t;if(e&&e.clear_persistence)t=!0;else{if(!e||!e.enable_persistence)return;t=!1}this.get_config("disable_persistence")||this.persistence.disabled===t||this.persistence.set_disabled(t)},so.prototype._gdpr_call_func=function(e,t){return t=mi.extend({capture:mi.bind(this.capture,this),persistence_type:this.get_config("opt_out_capturing_persistence_type"),cookie_prefix:this.get_config("opt_out_capturing_cookie_prefix"),cookie_expiration:this.get_config("cookie_expiration"),cross_subdomain_cookie:this.get_config("cross_subdomain_cookie"),secure_cookie:this.get_config("secure_cookie")},t),mi.localStorage.is_supported()||(t.persistence_type="cookie"),e(this.get_config("token"),{capture:t.capture,captureEventName:t.capture_event_name,captureProperties:t.capture_properties,persistenceType:t.persistence_type,persistencePrefix:t.cookie_prefix,cookieExpiration:t.cookie_expiration,crossSubdomainCookie:t.cross_subdomain_cookie,secureCookie:t.secure_cookie})},so.prototype.opt_in_capturing=function(e){e=mi.extend({enable_persistence:!0},e),this._gdpr_call_func(Pi,e),this._gdpr_update_persistence(e)},so.prototype.opt_in_captureing=function(e){uo("opt_in_captureing"),this.opt_in_capturing(e)},so.prototype.opt_out_capturing=function(e){(e=mi.extend({clear_persistence:!0,delete_user:!0},e)).delete_user&&this.people&&this.people._identify_called()&&(this.people.delete_user(),this.people.clear_charges()),this._gdpr_call_func(Fi,e),this._gdpr_update_persistence(e)},so.prototype.opt_out_captureing=function(e){uo("opt_out_captureing"),this.opt_out_capturing(e)},so.prototype.has_opted_in_capturing=function(e){return this._gdpr_call_func(qi,e)},so.prototype.has_opted_in_captureing=function(e){return uo("has_opted_in_captureing"),this.has_opted_in_capturing(e)},so.prototype.has_opted_out_capturing=function(e){return this._gdpr_call_func(Ii,e)},so.prototype.has_opted_out_captureing=function(e){return uo("has_opted_out_captureing"),this.has_opted_out_capturing(e)},so.prototype.clear_opt_in_out_capturing=function(e){e=mi.extend({enable_persistence:!0},e),this._gdpr_call_func(Ri,e),this._gdpr_update_persistence(e)},so.prototype.clear_opt_in_out_captureing=function(e){uo("clear_opt_in_out_captureing"),this.clear_opt_in_out_capturing(e)},so.prototype.decodeLZ64=Ir.decompressFromBase64,so.prototype.init=so.prototype.init,so.prototype.reset=so.prototype.reset,so.prototype.capture=so.prototype.capture,so.prototype.capture_links=so.prototype.capture_links,so.prototype.capture_forms=so.prototype.capture_forms,so.prototype.capture_pageview=so.prototype.capture_pageview,so.prototype.register=so.prototype.register,so.prototype.register_once=so.prototype.register_once,so.prototype.unregister=so.prototype.unregister,so.prototype.identify=so.prototype.identify,so.prototype.alias=so.prototype.alias,so.prototype.set_config=so.prototype.set_config,so.prototype.get_config=so.prototype.get_config,so.prototype.get_property=so.prototype.get_property,so.prototype.get_distinct_id=so.prototype.get_distinct_id,so.prototype.toString=so.prototype.toString,so.prototype.opt_out_captureing=so.prototype.opt_out_captureing,so.prototype.opt_in_captureing=so.prototype.opt_in_captureing,so.prototype.has_opted_out_captureing=so.prototype.has_opted_out_captureing,so.prototype.has_opted_in_captureing=so.prototype.has_opted_in_captureing,so.prototype.clear_opt_in_out_captureing=so.prototype.clear_opt_in_out_captureing,so.prototype.opt_out_capturing=so.prototype.opt_out_capturing,so.prototype.opt_in_capturing=so.prototype.opt_in_capturing,so.prototype.has_opted_out_capturing=so.prototype.has_opted_out_capturing,so.prototype.has_opted_in_capturing=so.prototype.has_opted_in_capturing,so.prototype.clear_opt_in_out_capturing=so.prototype.clear_opt_in_out_capturing,so.prototype.isFeatureEnabled=so.prototype.isFeatureEnabled,so.prototype.reloadFeatureFlags=so.prototype.reloadFeatureFlags,so.prototype.onFeatureFlags=so.prototype.onFeatureFlags,so.prototype.decodeLZ64=so.prototype.decodeLZ64,Ji.prototype.properties=Ji.prototype.properties,Ji.prototype.update_search_keyword=Ji.prototype.update_search_keyword,Ji.prototype.update_referrer_info=Ji.prototype.update_referrer_info,Ji.prototype.get_cross_subdomain=Ji.prototype.get_cross_subdomain,Ji.prototype.clear=Ji.prototype.clear,mi.safewrap_class(so,["identify"]);var co={},fo=function(){Zi.init=function(e,t,n){if(n)return Zi[n]||(Zi[n]=co[n]=lo(e,t,n),Zi[n]._loaded()),Zi[n];var r=Zi;co.posthog?r=co.posthog:e&&((r=lo(e,t,"posthog"))._loaded(),co.posthog=r),Zi=r,1===Gi&&(qr.posthog=Zi),mi.each(co,(function(e,t){"posthog"!==t&&(Zi[t]=e)})),Zi._=mi}};var po=(Gi=0,Zi=new so,fo(),Zi.init(),function(){function e(){e.done||(e.done=!0,ao=!0,no=!1,mi.each(co,(function(e){e._dom_loaded()})))}if(ai.addEventListener)"complete"===ai.readyState?e():ai.addEventListener("DOMContentLoaded",e,!1);else if(ai.attachEvent){ai.attachEvent("onreadystatechange",e);var t=!1;try{t=null===qr.frameElement}catch(n){}ai.documentElement.doScroll&&t&&function t(){try{ai.documentElement.doScroll("left")}catch(n){return void setTimeout(t,1)}e()}()}mi.register_event(qr,"load",e,!0)}(),Zi),ho=1;var go,mo,vo,yo={nextValue:function(){return(ho=(9301*ho+49297)%233280)/233280},seed:function(e){ho=e}},bo="0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ_-";function _o(){vo=!1}function wo(e){if(e){if(e!==go){if(e.length!==bo.length)throw new Error("Custom alphabet for shortid must be "+bo.length+" unique characters. You submitted "+e.length+" characters: "+e);var t=e.split("").filter((function(e,t,n){return t!==n.lastIndexOf(e)}));if(t.length)throw new Error("Custom alphabet for shortid must be "+bo.length+" unique characters. These characters were not unique: "+t.join(", "));go=e,_o()}}else go!==bo&&(go=bo,_o())}function xo(){return vo||(vo=function(){go||wo(bo);for(var e,t=go.split(""),n=[],r=yo.nextValue();t.length>0;)r=yo.nextValue(),e=Math.floor(r*t.length),n.push(t.splice(e,1)[0]);return n.join("")}())}var ko={get:function(){return go||bo},characters:function(e){return wo(e),go},seed:function(e){yo.seed(e),mo!==e&&(_o(),mo=e)},lookup:function(e){return xo()[e]},shuffled:xo},Co="object"==typeof window&&(window.crypto||window.msCrypto),Eo=Co&&Co.getRandomValues?function(e){return Co.getRandomValues(new Uint8Array(e))}:function(e){for(var t=[],n=0;n<e;n++)t.push(Math.floor(256*Math.random()));return t},Oo=function(e,t,n){for(var r=(2<<Math.log(t.length-1)/Math.LN2)-1,i=-~(1.6*r*n/t.length),o="";;)for(var a=e(i),s=i;s--;)if((o+=t[a[s]&r]||"").length===+n)return o};var Ao,So,jo=function(e){for(var t,n=0,r="";!t;)r+=Oo(Eo,ko.get(),1),t=e<Math.pow(16,n+1),n++;return r};var To=function(e){var t="",n=Math.floor(.001*(Date.now()-1567752802062));return n===So?Ao++:(Ao=0,So=n),t+=jo(7),t+=jo(e),Ao>0&&(t+=jo(Ao)),t+=jo(n)};var Do=function(e){return!(!e||"string"!=typeof e||e.length<6)&&!new RegExp("[^"+ko.get().replace(/[|\\{}()[\]^$+*?.-]/g,"\\$&")+"]").test(e)},No=Un((function(e){var t=0;function n(){return To(t)}e.exports=n,e.exports.generate=n,e.exports.seed=function(t){return ko.seed(t),e.exports},e.exports.worker=function(n){return t=n,e.exports},e.exports.characters=function(e){return void 0!==e&&ko.characters(e),ko.shuffled()},e.exports.isValid=Do})),Lo=Un((function(e,t){var n;"undefined"!=typeof self&&self,n=function(){return function(e){var t={};function n(r){if(t[r])return t[r].exports;var i=t[r]={i:r,l:!1,exports:{}};return e[r].call(i.exports,i,i.exports,n),i.l=!0,i.exports}return n.m=e,n.c=t,n.d=function(e,t,r){n.o(e,t)||Object.defineProperty(e,t,{configurable:!1,enumerable:!0,get:r})},n.n=function(e){var t=e&&e.__esModule?function(){return e.default}:function(){return e};return n.d(t,"a",t),t},n.o=function(e,t){return Object.prototype.hasOwnProperty.call(e,t)},n.p="",n(n.s=109)}([function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r=n(17),i=n(18),o=n(19),a=n(45),s=n(46),l=n(47),u=n(48),c=n(49),f=n(12),p=n(32),d=n(33),h=n(31),g=n(1),m={Scope:g.Scope,create:g.create,find:g.find,query:g.query,register:g.register,Container:r.default,Format:i.default,Leaf:o.default,Embed:u.default,Scroll:a.default,Block:l.default,Inline:s.default,Text:c.default,Attributor:{Attribute:f.default,Class:p.default,Style:d.default,Store:h.default}};t.default=m},function(e,t,n){var r,i=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=function(e){function t(t){var n=this;return t="[Parchment] "+t,(n=e.call(this,t)||this).message=t,n.name=n.constructor.name,n}return i(t,e),t}(Error);t.ParchmentError=o;var a,s,l={},u={},c={},f={};function p(e,t){var n;if(void 0===t&&(t=a.ANY),"string"==typeof e)n=f[e]||l[e];else if(e instanceof Text||e.nodeType===Node.TEXT_NODE)n=f.text;else if("number"==typeof e)e&a.LEVEL&a.BLOCK?n=f.block:e&a.LEVEL&a.INLINE&&(n=f.inline);else if(e instanceof HTMLElement){var r=(e.getAttribute("class")||"").split(/\s+/);for(var i in r)if(n=u[r[i]])break;n=n||c[e.tagName]}return null==n?null:t&a.LEVEL&n.scope&&t&a.TYPE&n.scope?n:null}t.DATA_KEY="__blot",(s=a=t.Scope||(t.Scope={}))[s.TYPE=3]="TYPE",s[s.LEVEL=12]="LEVEL",s[s.ATTRIBUTE=13]="ATTRIBUTE",s[s.BLOT=14]="BLOT",s[s.INLINE=7]="INLINE",s[s.BLOCK=11]="BLOCK",s[s.BLOCK_BLOT=10]="BLOCK_BLOT",s[s.INLINE_BLOT=6]="INLINE_BLOT",s[s.BLOCK_ATTRIBUTE=9]="BLOCK_ATTRIBUTE",s[s.INLINE_ATTRIBUTE=5]="INLINE_ATTRIBUTE",s[s.ANY=15]="ANY",t.create=function(e,t){var n=p(e);if(null==n)throw new o("Unable to create "+e+" blot");var r=n,i=e instanceof Node||e.nodeType===Node.TEXT_NODE?e:r.create(t);return new r(i,t)},t.find=function e(n,r){return void 0===r&&(r=!1),null==n?null:null!=n[t.DATA_KEY]?n[t.DATA_KEY].blot:r?e(n.parentNode,r):null},t.query=p,t.register=function e(){for(var t=[],n=0;n<arguments.length;n++)t[n]=arguments[n];if(t.length>1)return t.map((function(t){return e(t)}));var r=t[0];if("string"!=typeof r.blotName&&"string"!=typeof r.attrName)throw new o("Invalid definition");if("abstract"===r.blotName)throw new o("Cannot register abstract class");if(f[r.blotName||r.attrName]=r,"string"==typeof r.keyName)l[r.keyName]=r;else if(null!=r.className&&(u[r.className]=r),null!=r.tagName){Array.isArray(r.tagName)?r.tagName=r.tagName.map((function(e){return e.toUpperCase()})):r.tagName=r.tagName.toUpperCase();var i=Array.isArray(r.tagName)?r.tagName:[r.tagName];i.forEach((function(e){null!=c[e]&&null!=r.className||(c[e]=r)}))}return r}},function(e,t,n){var r=n(51),i=n(11),o=n(3),a=n(20),s=String.fromCharCode(0),l=function(e){Array.isArray(e)?this.ops=e:null!=e&&Array.isArray(e.ops)?this.ops=e.ops:this.ops=[]};l.prototype.insert=function(e,t){var n={};return 0===e.length?this:(n.insert=e,null!=t&&"object"==typeof t&&Object.keys(t).length>0&&(n.attributes=t),this.push(n))},l.prototype.delete=function(e){return e<=0?this:this.push({delete:e})},l.prototype.retain=function(e,t){if(e<=0)return this;var n={retain:e};return null!=t&&"object"==typeof t&&Object.keys(t).length>0&&(n.attributes=t),this.push(n)},l.prototype.push=function(e){var t=this.ops.length,n=this.ops[t-1];if(e=o(!0,{},e),"object"==typeof n){if("number"==typeof e.delete&&"number"==typeof n.delete)return this.ops[t-1]={delete:n.delete+e.delete},this;if("number"==typeof n.delete&&null!=e.insert&&(t-=1,"object"!=typeof(n=this.ops[t-1])))return this.ops.unshift(e),this;if(i(e.attributes,n.attributes)){if("string"==typeof e.insert&&"string"==typeof n.insert)return this.ops[t-1]={insert:n.insert+e.insert},"object"==typeof e.attributes&&(this.ops[t-1].attributes=e.attributes),this;if("number"==typeof e.retain&&"number"==typeof n.retain)return this.ops[t-1]={retain:n.retain+e.retain},"object"==typeof e.attributes&&(this.ops[t-1].attributes=e.attributes),this}}return t===this.ops.length?this.ops.push(e):this.ops.splice(t,0,e),this},l.prototype.chop=function(){var e=this.ops[this.ops.length-1];return e&&e.retain&&!e.attributes&&this.ops.pop(),this},l.prototype.filter=function(e){return this.ops.filter(e)},l.prototype.forEach=function(e){this.ops.forEach(e)},l.prototype.map=function(e){return this.ops.map(e)},l.prototype.partition=function(e){var t=[],n=[];return this.forEach((function(r){(e(r)?t:n).push(r)})),[t,n]},l.prototype.reduce=function(e,t){return this.ops.reduce(e,t)},l.prototype.changeLength=function(){return this.reduce((function(e,t){return t.insert?e+a.length(t):t.delete?e-t.delete:e}),0)},l.prototype.length=function(){return this.reduce((function(e,t){return e+a.length(t)}),0)},l.prototype.slice=function(e,t){e=e||0,"number"!=typeof t&&(t=1/0);for(var n=[],r=a.iterator(this.ops),i=0;i<t&&r.hasNext();){var o;i<e?o=r.next(e-i):(o=r.next(t-i),n.push(o)),i+=a.length(o)}return new l(n)},l.prototype.compose=function(e){var t=a.iterator(this.ops),n=a.iterator(e.ops),r=[],o=n.peek();if(null!=o&&"number"==typeof o.retain&&null==o.attributes){for(var s=o.retain;"insert"===t.peekType()&&t.peekLength()<=s;)s-=t.peekLength(),r.push(t.next());o.retain-s>0&&n.next(o.retain-s)}for(var u=new l(r);t.hasNext()||n.hasNext();)if("insert"===n.peekType())u.push(n.next());else if("delete"===t.peekType())u.push(t.next());else{var c=Math.min(t.peekLength(),n.peekLength()),f=t.next(c),p=n.next(c);if("number"==typeof p.retain){var d={};"number"==typeof f.retain?d.retain=c:d.insert=f.insert;var h=a.attributes.compose(f.attributes,p.attributes,"number"==typeof f.retain);if(h&&(d.attributes=h),u.push(d),!n.hasNext()&&i(u.ops[u.ops.length-1],d)){var g=new l(t.rest());return u.concat(g).chop()}}else"number"==typeof p.delete&&"number"==typeof f.retain&&u.push(p)}return u.chop()},l.prototype.concat=function(e){var t=new l(this.ops.slice());return e.ops.length>0&&(t.push(e.ops[0]),t.ops=t.ops.concat(e.ops.slice(1))),t},l.prototype.diff=function(e,t){if(this.ops===e.ops)return new l;var n=[this,e].map((function(t){return t.map((function(n){if(null!=n.insert)return"string"==typeof n.insert?n.insert:s;throw new Error("diff() called "+(t===e?"on":"with")+" non-document")})).join("")})),o=new l,u=r(n[0],n[1],t),c=a.iterator(this.ops),f=a.iterator(e.ops);return u.forEach((function(e){for(var t=e[1].length;t>0;){var n=0;switch(e[0]){case r.INSERT:n=Math.min(f.peekLength(),t),o.push(f.next(n));break;case r.DELETE:n=Math.min(t,c.peekLength()),c.next(n),o.delete(n);break;case r.EQUAL:n=Math.min(c.peekLength(),f.peekLength(),t);var s=c.next(n),l=f.next(n);i(s.insert,l.insert)?o.retain(n,a.attributes.diff(s.attributes,l.attributes)):o.push(l).delete(n)}t-=n}})),o.chop()},l.prototype.eachLine=function(e,t){t=t||"\n";for(var n=a.iterator(this.ops),r=new l,i=0;n.hasNext();){if("insert"!==n.peekType())return;var o=n.peek(),s=a.length(o)-n.peekLength(),u="string"==typeof o.insert?o.insert.indexOf(t,s)-s:-1;if(u<0)r.push(n.next());else if(u>0)r.push(n.next(u));else{if(!1===e(r,n.next(1).attributes||{},i))return;i+=1,r=new l}}r.length()>0&&e(r,{},i)},l.prototype.transform=function(e,t){if(t=!!t,"number"==typeof e)return this.transformPosition(e,t);for(var n=a.iterator(this.ops),r=a.iterator(e.ops),i=new l;n.hasNext()||r.hasNext();)if("insert"!==n.peekType()||!t&&"insert"===r.peekType())if("insert"===r.peekType())i.push(r.next());else{var o=Math.min(n.peekLength(),r.peekLength()),s=n.next(o),u=r.next(o);if(s.delete)continue;u.delete?i.push(u):i.retain(o,a.attributes.transform(s.attributes,u.attributes,t))}else i.retain(a.length(n.next()));return i.chop()},l.prototype.transformPosition=function(e,t){t=!!t;for(var n=a.iterator(this.ops),r=0;n.hasNext()&&r<=e;){var i=n.peekLength(),o=n.peekType();n.next(),"delete"!==o?("insert"===o&&(r<e||!t)&&(e+=i),r+=i):e-=Math.min(i,e-r)}return e},e.exports=l},function(e,t){var n=Object.prototype.hasOwnProperty,r=Object.prototype.toString,i=Object.defineProperty,o=Object.getOwnPropertyDescriptor,a=function(e){return"function"==typeof Array.isArray?Array.isArray(e):"[object Array]"===r.call(e)},s=function(e){if(!e||"[object Object]"!==r.call(e))return!1;var t,i=n.call(e,"constructor"),o=e.constructor&&e.constructor.prototype&&n.call(e.constructor.prototype,"isPrototypeOf");if(e.constructor&&!i&&!o)return!1;for(t in e);return void 0===t||n.call(e,t)},l=function(e,t){i&&"__proto__"===t.name?i(e,t.name,{enumerable:!0,configurable:!0,value:t.newValue,writable:!0}):e[t.name]=t.newValue},u=function(e,t){if("__proto__"===t){if(!n.call(e,t))return;if(o)return o(e,t).value}return e[t]};e.exports=function e(){var t,n,r,i,o,c,f=arguments[0],p=1,d=arguments.length,h=!1;for("boolean"==typeof f&&(h=f,f=arguments[1]||{},p=2),(null==f||"object"!=typeof f&&"function"!=typeof f)&&(f={});p<d;++p)if(null!=(t=arguments[p]))for(n in t)r=u(f,n),f!==(i=u(t,n))&&(h&&i&&(s(i)||(o=a(i)))?(o?(o=!1,c=r&&a(r)?r:[]):c=r&&s(r)?r:{},l(f,{name:n,newValue:e(h,c,i)})):void 0!==i&&l(f,{name:n,newValue:i}));return f}},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.BlockEmbed=t.bubbleFormats=void 0;var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),i=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},o=f(n(3)),a=f(n(2)),s=f(n(0)),l=f(n(16)),u=f(n(6)),c=f(n(7));function f(e){return e&&e.__esModule?e:{default:e}}function p(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function d(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function h(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var g=function(e){function t(){return p(this,t),d(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return h(t,e),r(t,[{key:"attach",value:function(){i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"attach",this).call(this),this.attributes=new s.default.Attributor.Store(this.domNode)}},{key:"delta",value:function(){return(new a.default).insert(this.value(),(0,o.default)(this.formats(),this.attributes.values()))}},{key:"format",value:function(e,t){var n=s.default.query(e,s.default.Scope.BLOCK_ATTRIBUTE);null!=n&&this.attributes.attribute(n,t)}},{key:"formatAt",value:function(e,t,n,r){this.format(n,r)}},{key:"insertAt",value:function(e,n,r){if("string"==typeof n&&n.endsWith("\n")){var o=s.default.create(m.blotName);this.parent.insertBefore(o,0===e?this:this.next),o.insertAt(0,n.slice(0,-1))}else i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"insertAt",this).call(this,e,n,r)}}]),t}(s.default.Embed);g.scope=s.default.Scope.BLOCK_BLOT;var m=function(e){function t(e){p(this,t);var n=d(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.cache={},n}return h(t,e),r(t,[{key:"delta",value:function(){return null==this.cache.delta&&(this.cache.delta=this.descendants(s.default.Leaf).reduce((function(e,t){return 0===t.length()?e:e.insert(t.value(),v(t))}),new a.default).insert("\n",v(this))),this.cache.delta}},{key:"deleteAt",value:function(e,n){i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"deleteAt",this).call(this,e,n),this.cache={}}},{key:"formatAt",value:function(e,n,r,o){n<=0||(s.default.query(r,s.default.Scope.BLOCK)?e+n===this.length()&&this.format(r,o):i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"formatAt",this).call(this,e,Math.min(n,this.length()-e-1),r,o),this.cache={})}},{key:"insertAt",value:function(e,n,r){if(null!=r)return i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"insertAt",this).call(this,e,n,r);if(0!==n.length){var o=n.split("\n"),a=o.shift();a.length>0&&(e<this.length()-1||null==this.children.tail?i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"insertAt",this).call(this,Math.min(e,this.length()-1),a):this.children.tail.insertAt(this.children.tail.length(),a),this.cache={});var s=this;o.reduce((function(e,t){return(s=s.split(e,!0)).insertAt(0,t),t.length}),e+a.length)}}},{key:"insertBefore",value:function(e,n){var r=this.children.head;i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"insertBefore",this).call(this,e,n),r instanceof l.default&&r.remove(),this.cache={}}},{key:"length",value:function(){return null==this.cache.length&&(this.cache.length=i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"length",this).call(this)+1),this.cache.length}},{key:"moveChildren",value:function(e,n){i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"moveChildren",this).call(this,e,n),this.cache={}}},{key:"optimize",value:function(e){i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"optimize",this).call(this,e),this.cache={}}},{key:"path",value:function(e){return i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"path",this).call(this,e,!0)}},{key:"removeChild",value:function(e){i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"removeChild",this).call(this,e),this.cache={}}},{key:"split",value:function(e){var n=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(n&&(0===e||e>=this.length()-1)){var r=this.clone();return 0===e?(this.parent.insertBefore(r,this),this):(this.parent.insertBefore(r,this.next),r)}var o=i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"split",this).call(this,e,n);return this.cache={},o}}]),t}(s.default.Block);function v(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return null==e?t:("function"==typeof e.formats&&(t=(0,o.default)(t,e.formats())),null==e.parent||"scroll"==e.parent.blotName||e.parent.statics.scope!==e.statics.scope?t:v(e.parent,t))}m.blotName="block",m.tagName="P",m.defaultChild="break",m.allowedChildren=[u.default,s.default.Embed,c.default],t.bubbleFormats=v,t.BlockEmbed=g,t.default=m},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.overload=t.expandConfig=void 0;var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(l){i=!0,o=l}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}();n(50);var a=m(n(2)),s=m(n(14)),l=m(n(8)),u=m(n(9)),c=m(n(0)),f=n(15),p=m(f),d=m(n(3)),h=m(n(10)),g=m(n(34));function m(e){return e&&e.__esModule?e:{default:e}}function v(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}function y(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var b=(0,h.default)("quill"),_=function(){function e(t){var n=this,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};if(y(this,e),this.options=w(t,r),this.container=this.options.container,null==this.container)return b.error("Invalid Quill container",t);this.options.debug&&e.debug(this.options.debug);var i=this.container.innerHTML.trim();this.container.classList.add("ql-container"),this.container.innerHTML="",this.container.__quill=this,this.root=this.addContainer("ql-editor"),this.root.classList.add("ql-blank"),this.root.setAttribute("data-gramm",!1),this.scrollingContainer=this.options.scrollingContainer||this.root,this.emitter=new l.default,this.scroll=c.default.create(this.root,{emitter:this.emitter,whitelist:this.options.formats}),this.editor=new s.default(this.scroll),this.selection=new p.default(this.scroll,this.emitter),this.theme=new this.options.theme(this,this.options),this.keyboard=this.theme.addModule("keyboard"),this.clipboard=this.theme.addModule("clipboard"),this.history=this.theme.addModule("history"),this.theme.init(),this.emitter.on(l.default.events.EDITOR_CHANGE,(function(e){e===l.default.events.TEXT_CHANGE&&n.root.classList.toggle("ql-blank",n.editor.isBlank())})),this.emitter.on(l.default.events.SCROLL_UPDATE,(function(e,t){var r=n.selection.lastRange,i=r&&0===r.length?r.index:void 0;x.call(n,(function(){return n.editor.update(null,t,i)}),e)}));var o=this.clipboard.convert("<div class='ql-editor' style=\"white-space: normal;\">"+i+"<p><br></p></div>");this.setContents(o),this.history.clear(),this.options.placeholder&&this.root.setAttribute("data-placeholder",this.options.placeholder),this.options.readOnly&&this.disable()}return o(e,null,[{key:"debug",value:function(e){!0===e&&(e="log"),h.default.level(e)}},{key:"find",value:function(e){return e.__quill||c.default.find(e)}},{key:"import",value:function(e){return null==this.imports[e]&&b.error("Cannot import "+e+". Are you sure it was registered?"),this.imports[e]}},{key:"register",value:function(e,t){var n=this,r=arguments.length>2&&void 0!==arguments[2]&&arguments[2];if("string"!=typeof e){var i=e.attrName||e.blotName;"string"==typeof i?this.register("formats/"+i,e,t):Object.keys(e).forEach((function(r){n.register(r,e[r],t)}))}else null==this.imports[e]||r||b.warn("Overwriting "+e+" with",t),this.imports[e]=t,(e.startsWith("blots/")||e.startsWith("formats/"))&&"abstract"!==t.blotName?c.default.register(t):e.startsWith("modules")&&"function"==typeof t.register&&t.register()}}]),o(e,[{key:"addContainer",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;if("string"==typeof e){var n=e;(e=document.createElement("div")).classList.add(n)}return this.container.insertBefore(e,t),e}},{key:"blur",value:function(){this.selection.setRange(null)}},{key:"deleteText",value:function(e,t,n){var r=this,o=k(e,t,n),a=i(o,4);return e=a[0],t=a[1],n=a[3],x.call(this,(function(){return r.editor.deleteText(e,t)}),n,e,-1*t)}},{key:"disable",value:function(){this.enable(!1)}},{key:"enable",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this.scroll.enable(e),this.container.classList.toggle("ql-disabled",!e)}},{key:"focus",value:function(){var e=this.scrollingContainer.scrollTop;this.selection.focus(),this.scrollingContainer.scrollTop=e,this.scrollIntoView()}},{key:"format",value:function(e,t){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:l.default.sources.API;return x.call(this,(function(){var r=n.getSelection(!0),i=new a.default;if(null==r)return i;if(c.default.query(e,c.default.Scope.BLOCK))i=n.editor.formatLine(r.index,r.length,v({},e,t));else{if(0===r.length)return n.selection.format(e,t),i;i=n.editor.formatText(r.index,r.length,v({},e,t))}return n.setSelection(r,l.default.sources.SILENT),i}),r)}},{key:"formatLine",value:function(e,t,n,r,o){var a,s=this,l=k(e,t,n,r,o),u=i(l,4);return e=u[0],t=u[1],a=u[2],o=u[3],x.call(this,(function(){return s.editor.formatLine(e,t,a)}),o,e,0)}},{key:"formatText",value:function(e,t,n,r,o){var a,s=this,l=k(e,t,n,r,o),u=i(l,4);return e=u[0],t=u[1],a=u[2],o=u[3],x.call(this,(function(){return s.editor.formatText(e,t,a)}),o,e,0)}},{key:"getBounds",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=void 0;n="number"==typeof e?this.selection.getBounds(e,t):this.selection.getBounds(e.index,e.length);var r=this.container.getBoundingClientRect();return{bottom:n.bottom-r.top,height:n.height,left:n.left-r.left,right:n.right-r.left,top:n.top-r.top,width:n.width}}},{key:"getContents",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.getLength()-e,n=k(e,t),r=i(n,2);return e=r[0],t=r[1],this.editor.getContents(e,t)}},{key:"getFormat",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:this.getSelection(!0),t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;return"number"==typeof e?this.editor.getFormat(e,t):this.editor.getFormat(e.index,e.length)}},{key:"getIndex",value:function(e){return e.offset(this.scroll)}},{key:"getLength",value:function(){return this.scroll.length()}},{key:"getLeaf",value:function(e){return this.scroll.leaf(e)}},{key:"getLine",value:function(e){return this.scroll.line(e)}},{key:"getLines",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Number.MAX_VALUE;return"number"!=typeof e?this.scroll.lines(e.index,e.length):this.scroll.lines(e,t)}},{key:"getModule",value:function(e){return this.theme.modules[e]}},{key:"getSelection",value:function(){var e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];return e&&this.focus(),this.update(),this.selection.getRange()[0]}},{key:"getText",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:this.getLength()-e,n=k(e,t),r=i(n,2);return e=r[0],t=r[1],this.editor.getText(e,t)}},{key:"hasFocus",value:function(){return this.selection.hasFocus()}},{key:"insertEmbed",value:function(t,n,r){var i=this,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:e.sources.API;return x.call(this,(function(){return i.editor.insertEmbed(t,n,r)}),o,t)}},{key:"insertText",value:function(e,t,n,r,o){var a,s=this,l=k(e,0,n,r,o),u=i(l,4);return e=u[0],a=u[2],o=u[3],x.call(this,(function(){return s.editor.insertText(e,t,a)}),o,e,t.length)}},{key:"isEnabled",value:function(){return!this.container.classList.contains("ql-disabled")}},{key:"off",value:function(){return this.emitter.off.apply(this.emitter,arguments)}},{key:"on",value:function(){return this.emitter.on.apply(this.emitter,arguments)}},{key:"once",value:function(){return this.emitter.once.apply(this.emitter,arguments)}},{key:"pasteHTML",value:function(e,t,n){this.clipboard.dangerouslyPasteHTML(e,t,n)}},{key:"removeFormat",value:function(e,t,n){var r=this,o=k(e,t,n),a=i(o,4);return e=a[0],t=a[1],n=a[3],x.call(this,(function(){return r.editor.removeFormat(e,t)}),n,e)}},{key:"scrollIntoView",value:function(){this.selection.scrollIntoView(this.scrollingContainer)}},{key:"setContents",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:l.default.sources.API;return x.call(this,(function(){e=new a.default(e);var n=t.getLength(),r=t.editor.deleteText(0,n),i=t.editor.applyDelta(e),o=i.ops[i.ops.length-1];return null!=o&&"string"==typeof o.insert&&"\n"===o.insert[o.insert.length-1]&&(t.editor.deleteText(t.getLength()-1,1),i.delete(1)),r.compose(i)}),n)}},{key:"setSelection",value:function(t,n,r){if(null==t)this.selection.setRange(null,n||e.sources.API);else{var o=k(t,n,r),a=i(o,4);t=a[0],n=a[1],r=a[3],this.selection.setRange(new f.Range(t,n),r),r!==l.default.sources.SILENT&&this.selection.scrollIntoView(this.scrollingContainer)}}},{key:"setText",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:l.default.sources.API,n=(new a.default).insert(e);return this.setContents(n,t)}},{key:"update",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:l.default.sources.USER,t=this.scroll.update(e);return this.selection.update(e),t}},{key:"updateContents",value:function(e){var t=this,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:l.default.sources.API;return x.call(this,(function(){return e=new a.default(e),t.editor.applyDelta(e,n)}),n,!0)}}]),e}();function w(e,t){if((t=(0,d.default)(!0,{container:e,modules:{clipboard:!0,keyboard:!0,history:!0}},t)).theme&&t.theme!==_.DEFAULTS.theme){if(t.theme=_.import("themes/"+t.theme),null==t.theme)throw new Error("Invalid theme "+t.theme+". Did you register it?")}else t.theme=g.default;var n=(0,d.default)(!0,{},t.theme.DEFAULTS);[n,t].forEach((function(e){e.modules=e.modules||{},Object.keys(e.modules).forEach((function(t){!0===e.modules[t]&&(e.modules[t]={})}))}));var r=Object.keys(n.modules).concat(Object.keys(t.modules)).reduce((function(e,t){var n=_.import("modules/"+t);return null==n?b.error("Cannot load "+t+" module. Are you sure you registered it?"):e[t]=n.DEFAULTS||{},e}),{});return null!=t.modules&&t.modules.toolbar&&t.modules.toolbar.constructor!==Object&&(t.modules.toolbar={container:t.modules.toolbar}),t=(0,d.default)(!0,{},_.DEFAULTS,{modules:r},n,t),["bounds","container","scrollingContainer"].forEach((function(e){"string"==typeof t[e]&&(t[e]=document.querySelector(t[e]))})),t.modules=Object.keys(t.modules).reduce((function(e,n){return t.modules[n]&&(e[n]=t.modules[n]),e}),{}),t}function x(e,t,n,r){if(this.options.strict&&!this.isEnabled()&&t===l.default.sources.USER)return new a.default;var i=null==n?null:this.getSelection(),o=this.editor.delta,s=e();if(null!=i&&(!0===n&&(n=i.index),null==r?i=C(i,s,t):0!==r&&(i=C(i,n,r,t)),this.setSelection(i,l.default.sources.SILENT)),s.length()>0){var u,c,f=[l.default.events.TEXT_CHANGE,s,o,t];(u=this.emitter).emit.apply(u,[l.default.events.EDITOR_CHANGE].concat(f)),t!==l.default.sources.SILENT&&(c=this.emitter).emit.apply(c,f)}return s}function k(e,t,n,i,o){var a={};return"number"==typeof e.index&&"number"==typeof e.length?"number"!=typeof t?(o=i,i=n,n=t,t=e.length,e=e.index):(t=e.length,e=e.index):"number"!=typeof t&&(o=i,i=n,n=t,t=0),"object"===(void 0===n?"undefined":r(n))?(a=n,o=i):"string"==typeof n&&(null!=i?a[n]=i:o=n),[e,t,a,o=o||l.default.sources.API]}function C(e,t,n,r){if(null==e)return null;var o=void 0,s=void 0;if(t instanceof a.default){var u=[e.index,e.index+e.length].map((function(e){return t.transformPosition(e,r!==l.default.sources.USER)})),c=i(u,2);o=c[0],s=c[1]}else{var p=[e.index,e.index+e.length].map((function(e){return e<t||e===t&&r===l.default.sources.USER?e:n>=0?e+n:Math.max(t,e+n)})),d=i(p,2);o=d[0],s=d[1]}return new f.Range(o,s-o)}_.DEFAULTS={bounds:null,formats:null,modules:{},placeholder:"",readOnly:!1,scrollingContainer:null,strict:!0,theme:"default"},_.events=l.default.events,_.sources=l.default.sources,_.version="1.3.7",_.imports={delta:a.default,parchment:c.default,"core/module":u.default,"core/theme":g.default},t.expandConfig=w,t.overload=k,t.default=_},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),i=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},o=s(n(7)),a=s(n(0));function s(e){return e&&e.__esModule?e:{default:e}}function l(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var c=function(e){function t(){return l(this,t),u(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),r(t,[{key:"formatAt",value:function(e,n,r,o){if(t.compare(this.statics.blotName,r)<0&&a.default.query(r,a.default.Scope.BLOT)){var s=this.isolate(e,n);o&&s.wrap(r,o)}else i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"formatAt",this).call(this,e,n,r,o)}},{key:"optimize",value:function(e){if(i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"optimize",this).call(this,e),this.parent instanceof t&&t.compare(this.statics.blotName,this.parent.statics.blotName)>0){var n=this.parent.isolate(this.offset(),this.length());this.moveChildren(n),n.wrap(this)}}}],[{key:"compare",value:function(e,n){var r=t.order.indexOf(e),i=t.order.indexOf(n);return r>=0||i>=0?r-i:e===n?0:e<n?-1:1}}]),t}(a.default.Inline);c.allowedChildren=[c,a.default.Embed,o.default],c.order=["cursor","inline","underline","strike","italic","bold","script","link","code"],t.default=c},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r,i=n(0);function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var s=function(e){function t(){return o(this,t),a(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),t}(((r=i)&&r.__esModule?r:{default:r}).default.Text);t.default=s},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),i=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},o=a(n(54));function a(e){return e&&e.__esModule?e:{default:e}}var s=(0,a(n(10)).default)("quill:events");["selectionchange","mousedown","mouseup","click"].forEach((function(e){document.addEventListener(e,(function(){for(var e=arguments.length,t=Array(e),n=0;n<e;n++)t[n]=arguments[n];[].slice.call(document.querySelectorAll(".ql-container")).forEach((function(e){var n;e.__quill&&e.__quill.emitter&&(n=e.__quill.emitter).handleDOM.apply(n,t)}))}))}));var l=function(e){function t(){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var e=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));return e.listeners={},e.on("error",s.error),e}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),r(t,[{key:"emit",value:function(){s.log.apply(s,arguments),i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"emit",this).apply(this,arguments)}},{key:"handleDOM",value:function(e){for(var t=arguments.length,n=Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];(this.listeners[e.type]||[]).forEach((function(t){var r=t.node,i=t.handler;(e.target===r||r.contains(e.target))&&i.apply(void 0,[e].concat(n))}))}},{key:"listenDOM",value:function(e,t,n){this.listeners[e]||(this.listeners[e]=[]),this.listeners[e].push({node:t,handler:n})}}]),t}(o.default);l.events={EDITOR_CHANGE:"editor-change",SCROLL_BEFORE_UPDATE:"scroll-before-update",SCROLL_OPTIMIZE:"scroll-optimize",SCROLL_UPDATE:"scroll-update",SELECTION_CHANGE:"selection-change",TEXT_CHANGE:"text-change"},l.sources={API:"api",SILENT:"silent",USER:"user"},t.default=l},function(e,t,n){function r(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}Object.defineProperty(t,"__esModule",{value:!0});var i=function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};r(this,e),this.quill=t,this.options=n};i.DEFAULTS={},t.default=i},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r=["error","warn","log","info"],i="warn";function o(e){if(r.indexOf(e)<=r.indexOf(i)){for(var t,n=arguments.length,o=Array(n>1?n-1:0),a=1;a<n;a++)o[a-1]=arguments[a];(t=console)[e].apply(t,o)}}function a(e){return r.reduce((function(t,n){return t[n]=o.bind(console,n,e),t}),{})}o.level=a.level=function(e){i=e},t.default=a},function(e,t,n){var r=Array.prototype.slice,i=n(52),o=n(53),a=e.exports=function(e,t,n){return n||(n={}),e===t||(e instanceof Date&&t instanceof Date?e.getTime()===t.getTime():!e||!t||"object"!=typeof e&&"object"!=typeof t?n.strict?e===t:e==t:function(e,t,n){var u,c;if(s(e)||s(t))return!1;if(e.prototype!==t.prototype)return!1;if(o(e))return!!o(t)&&(e=r.call(e),t=r.call(t),a(e,t,n));if(l(e)){if(!l(t))return!1;if(e.length!==t.length)return!1;for(u=0;u<e.length;u++)if(e[u]!==t[u])return!1;return!0}try{var f=i(e),p=i(t)}catch(d){return!1}if(f.length!=p.length)return!1;for(f.sort(),p.sort(),u=f.length-1;u>=0;u--)if(f[u]!=p[u])return!1;for(u=f.length-1;u>=0;u--)if(c=f[u],!a(e[c],t[c],n))return!1;return typeof e==typeof t}(e,t,n))};function s(e){return null==e}function l(e){return!(!e||"object"!=typeof e||"number"!=typeof e.length||"function"!=typeof e.copy||"function"!=typeof e.slice||e.length>0&&"number"!=typeof e[0])}},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r=n(1),i=function(){function e(e,t,n){void 0===n&&(n={}),this.attrName=e,this.keyName=t;var i=r.Scope.TYPE&r.Scope.ATTRIBUTE;null!=n.scope?this.scope=n.scope&r.Scope.LEVEL|i:this.scope=r.Scope.ATTRIBUTE,null!=n.whitelist&&(this.whitelist=n.whitelist)}return e.keys=function(e){return[].map.call(e.attributes,(function(e){return e.name}))},e.prototype.add=function(e,t){return!!this.canAdd(e,t)&&(e.setAttribute(this.keyName,t),!0)},e.prototype.canAdd=function(e,t){return null!=r.query(e,r.Scope.BLOT&(this.scope|r.Scope.TYPE))&&(null==this.whitelist||("string"==typeof t?this.whitelist.indexOf(t.replace(/["']/g,""))>-1:this.whitelist.indexOf(t)>-1))},e.prototype.remove=function(e){e.removeAttribute(this.keyName)},e.prototype.value=function(e){var t=e.getAttribute(this.keyName);return this.canAdd(e,t)&&t?t:""},e}();t.default=i},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.Code=void 0;var r=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(l){i=!0,o=l}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},a=f(n(2)),s=f(n(0)),l=f(n(4)),u=f(n(6)),c=f(n(7));function f(e){return e&&e.__esModule?e:{default:e}}function p(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function d(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function h(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var g=function(e){function t(){return p(this,t),d(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return h(t,e),t}(u.default);g.blotName="code",g.tagName="CODE";var m=function(e){function t(){return p(this,t),d(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return h(t,e),i(t,[{key:"delta",value:function(){var e=this,t=this.domNode.textContent;return t.endsWith("\n")&&(t=t.slice(0,-1)),t.split("\n").reduce((function(t,n){return t.insert(n).insert("\n",e.formats())}),new a.default)}},{key:"format",value:function(e,n){if(e!==this.statics.blotName||!n){var i=this.descendant(c.default,this.length()-1),a=r(i,1)[0];null!=a&&a.deleteAt(a.length()-1,1),o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"format",this).call(this,e,n)}}},{key:"formatAt",value:function(e,n,r,i){if(0!==n&&null!=s.default.query(r,s.default.Scope.BLOCK)&&(r!==this.statics.blotName||i!==this.statics.formats(this.domNode))){var o=this.newlineIndex(e);if(!(o<0||o>=e+n)){var a=this.newlineIndex(e,!0)+1,l=o-a+1,u=this.isolate(a,l),c=u.next;u.format(r,i),c instanceof t&&c.formatAt(0,e-a+n-l,r,i)}}}},{key:"insertAt",value:function(e,t,n){if(null==n){var i=this.descendant(c.default,e),o=r(i,2),a=o[0],s=o[1];a.insertAt(s,t)}}},{key:"length",value:function(){var e=this.domNode.textContent.length;return this.domNode.textContent.endsWith("\n")?e:e+1}},{key:"newlineIndex",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1];if(t)return this.domNode.textContent.slice(0,e).lastIndexOf("\n");var n=this.domNode.textContent.slice(e).indexOf("\n");return n>-1?e+n:-1}},{key:"optimize",value:function(e){this.domNode.textContent.endsWith("\n")||this.appendChild(s.default.create("text","\n")),o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"optimize",this).call(this,e);var n=this.next;null!=n&&n.prev===this&&n.statics.blotName===this.statics.blotName&&this.statics.formats(this.domNode)===n.statics.formats(n.domNode)&&(n.optimize(e),n.moveChildren(this),n.remove())}},{key:"replace",value:function(e){o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"replace",this).call(this,e),[].slice.call(this.domNode.querySelectorAll("*")).forEach((function(e){var t=s.default.find(e);null==t?e.parentNode.removeChild(e):t instanceof s.default.Embed?t.remove():t.unwrap()}))}}],[{key:"create",value:function(e){var n=o(t.__proto__||Object.getPrototypeOf(t),"create",this).call(this,e);return n.setAttribute("spellcheck",!1),n}},{key:"formats",value:function(){return!0}}]),t}(l.default);m.blotName="code-block",m.tagName="PRE",m.TAB=" ",t.Code=g,t.default=m},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(l){i=!0,o=l}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=v(n(2)),s=v(n(20)),l=v(n(0)),u=v(n(13)),c=v(n(24)),f=n(4),p=v(f),d=v(n(16)),h=v(n(21)),g=v(n(11)),m=v(n(3));function v(e){return e&&e.__esModule?e:{default:e}}var y=/^[ -~]*$/,b=function(){function e(t){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.scroll=t,this.delta=this.getDelta()}return o(e,[{key:"applyDelta",value:function(e){var t=this,n=!1;this.scroll.update();var o=this.scroll.length();return this.scroll.batchStart(),(e=function(e){return e.reduce((function(e,t){if(1===t.insert){var n=(0,h.default)(t.attributes);return delete n.image,e.insert({image:t.attributes.image},n)}if(null==t.attributes||!0!==t.attributes.list&&!0!==t.attributes.bullet||((t=(0,h.default)(t)).attributes.list?t.attributes.list="ordered":(t.attributes.list="bullet",delete t.attributes.bullet)),"string"==typeof t.insert){var r=t.insert.replace(/\r\n/g,"\n").replace(/\r/g,"\n");return e.insert(r,t.attributes)}return e.push(t)}),new a.default)}(e)).reduce((function(e,a){var u=a.retain||a.delete||a.insert.length||1,c=a.attributes||{};if(null!=a.insert){if("string"==typeof a.insert){var d=a.insert;d.endsWith("\n")&&n&&(n=!1,d=d.slice(0,-1)),e>=o&&!d.endsWith("\n")&&(n=!0),t.scroll.insertAt(e,d);var h=t.scroll.line(e),g=i(h,2),v=g[0],y=g[1],b=(0,m.default)({},(0,f.bubbleFormats)(v));if(v instanceof p.default){var _=v.descendant(l.default.Leaf,y),w=i(_,1)[0];b=(0,m.default)(b,(0,f.bubbleFormats)(w))}c=s.default.attributes.diff(b,c)||{}}else if("object"===r(a.insert)){var x=Object.keys(a.insert)[0];if(null==x)return e;t.scroll.insertAt(e,x,a.insert[x])}o+=u}return Object.keys(c).forEach((function(n){t.scroll.formatAt(e,u,n,c[n])})),e+u}),0),e.reduce((function(e,n){return"number"==typeof n.delete?(t.scroll.deleteAt(e,n.delete),e):e+(n.retain||n.insert.length||1)}),0),this.scroll.batchEnd(),this.update(e)}},{key:"deleteText",value:function(e,t){return this.scroll.deleteAt(e,t),this.update((new a.default).retain(e).delete(t))}},{key:"formatLine",value:function(e,t){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return this.scroll.update(),Object.keys(r).forEach((function(i){if(null==n.scroll.whitelist||n.scroll.whitelist[i]){var o=n.scroll.lines(e,Math.max(t,1)),a=t;o.forEach((function(t){var o=t.length();if(t instanceof u.default){var s=e-t.offset(n.scroll),l=t.newlineIndex(s+a)-s+1;t.formatAt(s,l,i,r[i])}else t.format(i,r[i]);a-=o}))}})),this.scroll.optimize(),this.update((new a.default).retain(e).retain(t,(0,h.default)(r)))}},{key:"formatText",value:function(e,t){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return Object.keys(r).forEach((function(i){n.scroll.formatAt(e,t,i,r[i])})),this.update((new a.default).retain(e).retain(t,(0,h.default)(r)))}},{key:"getContents",value:function(e,t){return this.delta.slice(e,e+t)}},{key:"getDelta",value:function(){return this.scroll.lines().reduce((function(e,t){return e.concat(t.delta())}),new a.default)}},{key:"getFormat",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=[],r=[];0===t?this.scroll.path(e).forEach((function(e){var t=i(e,1)[0];t instanceof p.default?n.push(t):t instanceof l.default.Leaf&&r.push(t)})):(n=this.scroll.lines(e,t),r=this.scroll.descendants(l.default.Leaf,e,t));var o=[n,r].map((function(e){if(0===e.length)return{};for(var t=(0,f.bubbleFormats)(e.shift());Object.keys(t).length>0;){var n=e.shift();if(null==n)return t;t=_((0,f.bubbleFormats)(n),t)}return t}));return m.default.apply(m.default,o)}},{key:"getText",value:function(e,t){return this.getContents(e,t).filter((function(e){return"string"==typeof e.insert})).map((function(e){return e.insert})).join("")}},{key:"insertEmbed",value:function(e,t,n){return this.scroll.insertAt(e,t,n),this.update((new a.default).retain(e).insert(function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}({},t,n)))}},{key:"insertText",value:function(e,t){var n=this,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{};return t=t.replace(/\r\n/g,"\n").replace(/\r/g,"\n"),this.scroll.insertAt(e,t),Object.keys(r).forEach((function(i){n.scroll.formatAt(e,t.length,i,r[i])})),this.update((new a.default).retain(e).insert(t,(0,h.default)(r)))}},{key:"isBlank",value:function(){if(0==this.scroll.children.length)return!0;if(this.scroll.children.length>1)return!1;var e=this.scroll.children.head;return e.statics.blotName===p.default.blotName&&!(e.children.length>1)&&e.children.head instanceof d.default}},{key:"removeFormat",value:function(e,t){var n=this.getText(e,t),r=this.scroll.line(e+t),o=i(r,2),s=o[0],l=o[1],c=0,f=new a.default;null!=s&&(c=s instanceof u.default?s.newlineIndex(l)-l+1:s.length()-l,f=s.delta().slice(l,l+c-1).insert("\n"));var p=this.getContents(e,t+c).diff((new a.default).insert(n).concat(f)),d=(new a.default).retain(e).concat(p);return this.applyDelta(d)}},{key:"update",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:[],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:void 0,r=this.delta;if(1===t.length&&"characterData"===t[0].type&&t[0].target.data.match(y)&&l.default.find(t[0].target)){var i=l.default.find(t[0].target),o=(0,f.bubbleFormats)(i),s=i.offset(this.scroll),u=t[0].oldValue.replace(c.default.CONTENTS,""),p=(new a.default).insert(u),d=(new a.default).insert(i.value()),h=(new a.default).retain(s).concat(p.diff(d,n));e=h.reduce((function(e,t){return t.insert?e.insert(t.insert,o):e.push(t)}),new a.default),this.delta=r.compose(e)}else this.delta=this.getDelta(),e&&(0,g.default)(r.compose(e),this.delta)||(e=r.diff(this.delta,n));return e}}]),e}();function _(e,t){return Object.keys(t).reduce((function(n,r){return null==e[r]||(t[r]===e[r]?n[r]=t[r]:Array.isArray(t[r])?t[r].indexOf(e[r])<0&&(n[r]=t[r].concat([e[r]])):n[r]=[t[r],e[r]]),n}),{})}t.default=b},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.Range=void 0;var r=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(l){i=!0,o=l}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=u(n(0)),a=u(n(21)),s=u(n(11)),l=u(n(8));function u(e){return e&&e.__esModule?e:{default:e}}function c(e){if(Array.isArray(e)){for(var t=0,n=Array(e.length);t<e.length;t++)n[t]=e[t];return n}return Array.from(e)}function f(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}var p=(0,u(n(10)).default)("quill:selection"),d=function e(t){var n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;f(this,e),this.index=t,this.length=n},h=function(){function e(t,n){var r=this;f(this,e),this.emitter=n,this.scroll=t,this.composing=!1,this.mouseDown=!1,this.root=this.scroll.domNode,this.cursor=o.default.create("cursor",this),this.lastRange=this.savedRange=new d(0,0),this.handleComposition(),this.handleDragging(),this.emitter.listenDOM("selectionchange",document,(function(){r.mouseDown||setTimeout(r.update.bind(r,l.default.sources.USER),1)})),this.emitter.on(l.default.events.EDITOR_CHANGE,(function(e,t){e===l.default.events.TEXT_CHANGE&&t.length()>0&&r.update(l.default.sources.SILENT)})),this.emitter.on(l.default.events.SCROLL_BEFORE_UPDATE,(function(){if(r.hasFocus()){var e=r.getNativeRange();null!=e&&e.start.node!==r.cursor.textNode&&r.emitter.once(l.default.events.SCROLL_UPDATE,(function(){try{r.setNativeRange(e.start.node,e.start.offset,e.end.node,e.end.offset)}catch(t){}}))}})),this.emitter.on(l.default.events.SCROLL_OPTIMIZE,(function(e,t){if(t.range){var n=t.range,i=n.startNode,o=n.startOffset,a=n.endNode,s=n.endOffset;r.setNativeRange(i,o,a,s)}})),this.update(l.default.sources.SILENT)}return i(e,[{key:"handleComposition",value:function(){var e=this;this.root.addEventListener("compositionstart",(function(){e.composing=!0})),this.root.addEventListener("compositionend",(function(){if(e.composing=!1,e.cursor.parent){var t=e.cursor.restore();if(!t)return;setTimeout((function(){e.setNativeRange(t.startNode,t.startOffset,t.endNode,t.endOffset)}),1)}}))}},{key:"handleDragging",value:function(){var e=this;this.emitter.listenDOM("mousedown",document.body,(function(){e.mouseDown=!0})),this.emitter.listenDOM("mouseup",document.body,(function(){e.mouseDown=!1,e.update(l.default.sources.USER)}))}},{key:"focus",value:function(){this.hasFocus()||(this.root.focus(),this.setRange(this.savedRange))}},{key:"format",value:function(e,t){if(null==this.scroll.whitelist||this.scroll.whitelist[e]){this.scroll.update();var n=this.getNativeRange();if(null!=n&&n.native.collapsed&&!o.default.query(e,o.default.Scope.BLOCK)){if(n.start.node!==this.cursor.textNode){var r=o.default.find(n.start.node,!1);if(null==r)return;if(r instanceof o.default.Leaf){var i=r.split(n.start.offset);r.parent.insertBefore(this.cursor,i)}else r.insertBefore(this.cursor,n.start.node);this.cursor.attach()}this.cursor.format(e,t),this.scroll.optimize(),this.setNativeRange(this.cursor.textNode,this.cursor.textNode.data.length),this.update()}}}},{key:"getBounds",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=this.scroll.length();e=Math.min(e,n-1),t=Math.min(e+t,n-1)-e;var i=void 0,o=this.scroll.leaf(e),a=r(o,2),s=a[0],l=a[1];if(null==s)return null;var u=s.position(l,!0),c=r(u,2);i=c[0],l=c[1];var f=document.createRange();if(t>0){f.setStart(i,l);var p=this.scroll.leaf(e+t),d=r(p,2);if(s=d[0],l=d[1],null==s)return null;var h=s.position(l,!0),g=r(h,2);return i=g[0],l=g[1],f.setEnd(i,l),f.getBoundingClientRect()}var m="left",v=void 0;return i instanceof Text?(l<i.data.length?(f.setStart(i,l),f.setEnd(i,l+1)):(f.setStart(i,l-1),f.setEnd(i,l),m="right"),v=f.getBoundingClientRect()):(v=s.domNode.getBoundingClientRect(),l>0&&(m="right")),{bottom:v.top+v.height,height:v.height,left:v[m],right:v[m],top:v.top,width:0}}},{key:"getNativeRange",value:function(){var e=document.getSelection();if(null==e||e.rangeCount<=0)return null;var t=e.getRangeAt(0);if(null==t)return null;var n=this.normalizeNative(t);return p.info("getNativeRange",n),n}},{key:"getRange",value:function(){var e=this.getNativeRange();return null==e?[null,null]:[this.normalizedToRange(e),e]}},{key:"hasFocus",value:function(){return document.activeElement===this.root}},{key:"normalizedToRange",value:function(e){var t=this,n=[[e.start.node,e.start.offset]];e.native.collapsed||n.push([e.end.node,e.end.offset]);var i=n.map((function(e){var n=r(e,2),i=n[0],a=n[1],s=o.default.find(i,!0),l=s.offset(t.scroll);return 0===a?l:s instanceof o.default.Container?l+s.length():l+s.index(i,a)})),a=Math.min(Math.max.apply(Math,c(i)),this.scroll.length()-1),s=Math.min.apply(Math,[a].concat(c(i)));return new d(s,a-s)}},{key:"normalizeNative",value:function(e){if(!g(this.root,e.startContainer)||!e.collapsed&&!g(this.root,e.endContainer))return null;var t={start:{node:e.startContainer,offset:e.startOffset},end:{node:e.endContainer,offset:e.endOffset},native:e};return[t.start,t.end].forEach((function(e){for(var t=e.node,n=e.offset;!(t instanceof Text)&&t.childNodes.length>0;)if(t.childNodes.length>n)t=t.childNodes[n],n=0;else{if(t.childNodes.length!==n)break;n=(t=t.lastChild)instanceof Text?t.data.length:t.childNodes.length+1}e.node=t,e.offset=n})),t}},{key:"rangeToNative",value:function(e){var t=this,n=e.collapsed?[e.index]:[e.index,e.index+e.length],i=[],o=this.scroll.length();return n.forEach((function(e,n){e=Math.min(o-1,e);var a,s=t.scroll.leaf(e),l=r(s,2),u=l[0],c=l[1],f=u.position(c,0!==n),p=r(f,2);a=p[0],c=p[1],i.push(a,c)})),i.length<2&&(i=i.concat(i)),i}},{key:"scrollIntoView",value:function(e){var t=this.lastRange;if(null!=t){var n=this.getBounds(t.index,t.length);if(null!=n){var i=this.scroll.length()-1,o=this.scroll.line(Math.min(t.index,i)),a=r(o,1)[0],s=a;if(t.length>0){var l=this.scroll.line(Math.min(t.index+t.length,i));s=r(l,1)[0]}if(null!=a&&null!=s){var u=e.getBoundingClientRect();n.top<u.top?e.scrollTop-=u.top-n.top:n.bottom>u.bottom&&(e.scrollTop+=n.bottom-u.bottom)}}}}},{key:"setNativeRange",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:e,r=arguments.length>3&&void 0!==arguments[3]?arguments[3]:t,i=arguments.length>4&&void 0!==arguments[4]&&arguments[4];if(p.info("setNativeRange",e,t,n,r),null==e||null!=this.root.parentNode&&null!=e.parentNode&&null!=n.parentNode){var o=document.getSelection();if(null!=o)if(null!=e){this.hasFocus()||this.root.focus();var a=(this.getNativeRange()||{}).native;if(null==a||i||e!==a.startContainer||t!==a.startOffset||n!==a.endContainer||r!==a.endOffset){"BR"==e.tagName&&(t=[].indexOf.call(e.parentNode.childNodes,e),e=e.parentNode),"BR"==n.tagName&&(r=[].indexOf.call(n.parentNode.childNodes,n),n=n.parentNode);var s=document.createRange();s.setStart(e,t),s.setEnd(n,r),o.removeAllRanges(),o.addRange(s)}}else o.removeAllRanges(),this.root.blur(),document.body.focus()}}},{key:"setRange",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:l.default.sources.API;if("string"==typeof t&&(n=t,t=!1),p.info("setRange",e),null!=e){var r=this.rangeToNative(e);this.setNativeRange.apply(this,c(r).concat([t]))}else this.setNativeRange(null);this.update(n)}},{key:"update",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:l.default.sources.USER,t=this.lastRange,n=this.getRange(),i=r(n,2),o=i[0],u=i[1];if(this.lastRange=o,null!=this.lastRange&&(this.savedRange=this.lastRange),!(0,s.default)(t,this.lastRange)){var c;!this.composing&&null!=u&&u.native.collapsed&&u.start.node!==this.cursor.textNode&&this.cursor.restore();var f,p=[l.default.events.SELECTION_CHANGE,(0,a.default)(this.lastRange),(0,a.default)(t),e];(c=this.emitter).emit.apply(c,[l.default.events.EDITOR_CHANGE].concat(p)),e!==l.default.sources.SILENT&&(f=this.emitter).emit.apply(f,p)}}}]),e}();function g(e,t){try{t.parentNode}catch(n){return!1}return t instanceof Text&&(t=t.parentNode),e.contains(t)}t.Range=d,t.default=h},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r,i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},a=n(0);function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function l(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var u=function(e){function t(){return s(this,t),l(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),i(t,[{key:"insertInto",value:function(e,n){0===e.children.length?o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"insertInto",this).call(this,e,n):this.remove()}},{key:"length",value:function(){return 0}},{key:"value",value:function(){return""}}],[{key:"value",value:function(){}}]),t}(((r=a)&&r.__esModule?r:{default:r}).default.Embed);u.blotName="break",u.tagName="BR",t.default=u},function(e,t,n){var r,i=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(44),a=n(30),s=n(1),l=function(e){function t(t){var n=e.call(this,t)||this;return n.build(),n}return i(t,e),t.prototype.appendChild=function(e){this.insertBefore(e)},t.prototype.attach=function(){e.prototype.attach.call(this),this.children.forEach((function(e){e.attach()}))},t.prototype.build=function(){var e=this;this.children=new o.default,[].slice.call(this.domNode.childNodes).reverse().forEach((function(t){try{var n=u(t);e.insertBefore(n,e.children.head||void 0)}catch(r){if(r instanceof s.ParchmentError)return;throw r}}))},t.prototype.deleteAt=function(e,t){if(0===e&&t===this.length())return this.remove();this.children.forEachAt(e,t,(function(e,t,n){e.deleteAt(t,n)}))},t.prototype.descendant=function(e,n){var r=this.children.find(n),i=r[0],o=r[1];return null==e.blotName&&e(i)||null!=e.blotName&&i instanceof e?[i,o]:i instanceof t?i.descendant(e,o):[null,-1]},t.prototype.descendants=function(e,n,r){void 0===n&&(n=0),void 0===r&&(r=Number.MAX_VALUE);var i=[],o=r;return this.children.forEachAt(n,r,(function(n,r,a){(null==e.blotName&&e(n)||null!=e.blotName&&n instanceof e)&&i.push(n),n instanceof t&&(i=i.concat(n.descendants(e,r,o))),o-=a})),i},t.prototype.detach=function(){this.children.forEach((function(e){e.detach()})),e.prototype.detach.call(this)},t.prototype.formatAt=function(e,t,n,r){this.children.forEachAt(e,t,(function(e,t,i){e.formatAt(t,i,n,r)}))},t.prototype.insertAt=function(e,t,n){var r=this.children.find(e),i=r[0],o=r[1];if(i)i.insertAt(o,t,n);else{var a=null==n?s.create("text",t):s.create(t,n);this.appendChild(a)}},t.prototype.insertBefore=function(e,t){if(null!=this.statics.allowedChildren&&!this.statics.allowedChildren.some((function(t){return e instanceof t})))throw new s.ParchmentError("Cannot insert "+e.statics.blotName+" into "+this.statics.blotName);e.insertInto(this,t)},t.prototype.length=function(){return this.children.reduce((function(e,t){return e+t.length()}),0)},t.prototype.moveChildren=function(e,t){this.children.forEach((function(n){e.insertBefore(n,t)}))},t.prototype.optimize=function(t){if(e.prototype.optimize.call(this,t),0===this.children.length)if(null!=this.statics.defaultChild){var n=s.create(this.statics.defaultChild);this.appendChild(n),n.optimize(t)}else this.remove()},t.prototype.path=function(e,n){void 0===n&&(n=!1);var r=this.children.find(e,n),i=r[0],o=r[1],a=[[this,e]];return i instanceof t?a.concat(i.path(o,n)):(null!=i&&a.push([i,o]),a)},t.prototype.removeChild=function(e){this.children.remove(e)},t.prototype.replace=function(n){n instanceof t&&n.moveChildren(this),e.prototype.replace.call(this,n)},t.prototype.split=function(e,t){if(void 0===t&&(t=!1),!t){if(0===e)return this;if(e===this.length())return this.next}var n=this.clone();return this.parent.insertBefore(n,this.next),this.children.forEachAt(e,this.length(),(function(e,r,i){e=e.split(r,t),n.appendChild(e)})),n},t.prototype.unwrap=function(){this.moveChildren(this.parent,this.next),this.remove()},t.prototype.update=function(e,t){var n=this,r=[],i=[];e.forEach((function(e){e.target===n.domNode&&"childList"===e.type&&(r.push.apply(r,e.addedNodes),i.push.apply(i,e.removedNodes))})),i.forEach((function(e){if(!(null!=e.parentNode&&"IFRAME"!==e.tagName&&document.body.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_CONTAINED_BY)){var t=s.find(e);null!=t&&(null!=t.domNode.parentNode&&t.domNode.parentNode!==n.domNode||t.detach())}})),r.filter((function(e){return e.parentNode==n.domNode})).sort((function(e,t){return e===t?0:e.compareDocumentPosition(t)&Node.DOCUMENT_POSITION_FOLLOWING?1:-1})).forEach((function(e){var t=null;null!=e.nextSibling&&(t=s.find(e.nextSibling));var r=u(e);r.next==t&&null!=r.next||(null!=r.parent&&r.parent.removeChild(n),n.insertBefore(r,t||void 0))}))},t}(a.default);function u(e){var t=s.find(e);if(null==t)try{t=s.create(e)}catch(n){t=s.create(s.Scope.INLINE),[].slice.call(e.childNodes).forEach((function(e){t.domNode.appendChild(e)})),e.parentNode&&e.parentNode.replaceChild(t.domNode,e),t.attach()}return t}t.default=l},function(e,t,n){var r,i=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(12),a=n(31),s=n(17),l=n(1),u=function(e){function t(t){var n=e.call(this,t)||this;return n.attributes=new a.default(n.domNode),n}return i(t,e),t.formats=function(e){return"string"==typeof this.tagName||(Array.isArray(this.tagName)?e.tagName.toLowerCase():void 0)},t.prototype.format=function(e,t){var n=l.query(e);n instanceof o.default?this.attributes.attribute(n,t):t&&(null==n||e===this.statics.blotName&&this.formats()[e]===t||this.replaceWith(e,t))},t.prototype.formats=function(){var e=this.attributes.values(),t=this.statics.formats(this.domNode);return null!=t&&(e[this.statics.blotName]=t),e},t.prototype.replaceWith=function(t,n){var r=e.prototype.replaceWith.call(this,t,n);return this.attributes.copy(r),r},t.prototype.update=function(t,n){var r=this;e.prototype.update.call(this,t,n),t.some((function(e){return e.target===r.domNode&&"attributes"===e.type}))&&this.attributes.build()},t.prototype.wrap=function(n,r){var i=e.prototype.wrap.call(this,n,r);return i instanceof t&&i.statics.scope===this.statics.scope&&this.attributes.move(i),i},t}(s.default);t.default=u},function(e,t,n){var r,i=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(30),a=n(1),s=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.value=function(e){return!0},t.prototype.index=function(e,t){return this.domNode===e||this.domNode.compareDocumentPosition(e)&Node.DOCUMENT_POSITION_CONTAINED_BY?Math.min(t,1):-1},t.prototype.position=function(e,t){var n=[].indexOf.call(this.parent.domNode.childNodes,this.domNode);return e>0&&(n+=1),[this.parent.domNode,n]},t.prototype.value=function(){var e;return(e={})[this.statics.blotName]=this.statics.value(this.domNode)||!0,e},t.scope=a.Scope.INLINE_BLOT,t}(o.default);t.default=s},function(e,t,n){var r=n(11),i=n(3),o={attributes:{compose:function(e,t,n){"object"!=typeof e&&(e={}),"object"!=typeof t&&(t={});var r=i(!0,{},t);for(var o in n||(r=Object.keys(r).reduce((function(e,t){return null!=r[t]&&(e[t]=r[t]),e}),{})),e)void 0!==e[o]&&void 0===t[o]&&(r[o]=e[o]);return Object.keys(r).length>0?r:void 0},diff:function(e,t){"object"!=typeof e&&(e={}),"object"!=typeof t&&(t={});var n=Object.keys(e).concat(Object.keys(t)).reduce((function(n,i){return r(e[i],t[i])||(n[i]=void 0===t[i]?null:t[i]),n}),{});return Object.keys(n).length>0?n:void 0},transform:function(e,t,n){if("object"!=typeof e)return t;if("object"==typeof t){if(!n)return t;var r=Object.keys(t).reduce((function(n,r){return void 0===e[r]&&(n[r]=t[r]),n}),{});return Object.keys(r).length>0?r:void 0}}},iterator:function(e){return new a(e)},length:function(e){return"number"==typeof e.delete?e.delete:"number"==typeof e.retain?e.retain:"string"==typeof e.insert?e.insert.length:1}};function a(e){this.ops=e,this.index=0,this.offset=0}a.prototype.hasNext=function(){return this.peekLength()<1/0},a.prototype.next=function(e){e||(e=1/0);var t=this.ops[this.index];if(t){var n=this.offset,r=o.length(t);if(e>=r-n?(e=r-n,this.index+=1,this.offset=0):this.offset+=e,"number"==typeof t.delete)return{delete:e};var i={};return t.attributes&&(i.attributes=t.attributes),"number"==typeof t.retain?i.retain=e:"string"==typeof t.insert?i.insert=t.insert.substr(n,e):i.insert=t.insert,i}return{retain:1/0}},a.prototype.peek=function(){return this.ops[this.index]},a.prototype.peekLength=function(){return this.ops[this.index]?o.length(this.ops[this.index])-this.offset:1/0},a.prototype.peekType=function(){return this.ops[this.index]?"number"==typeof this.ops[this.index].delete?"delete":"number"==typeof this.ops[this.index].retain?"retain":"insert":"retain"},a.prototype.rest=function(){if(this.hasNext()){if(0===this.offset)return this.ops.slice(this.index);var e=this.offset,t=this.index,n=this.next(),r=this.ops.slice(this.index);return this.offset=e,this.index=t,[n].concat(r)}return[]},e.exports=o},function(e,t){var n=function(){function e(e,t){return null!=t&&e instanceof t}var t,n,r;try{t=Map}catch(s){t=function(){}}try{n=Set}catch(s){n=function(){}}try{r=Promise}catch(s){r=function(){}}function i(o,s,l,u,c){"object"==typeof s&&(l=s.depth,u=s.prototype,c=s.includeNonEnumerable,s=s.circular);var f=[],p=[],d="undefined"!=typeof Buffer;return void 0===s&&(s=!0),void 0===l&&(l=1/0),function o(l,h){if(null===l)return null;if(0===h)return l;var g,m;if("object"!=typeof l)return l;if(e(l,t))g=new t;else if(e(l,n))g=new n;else if(e(l,r))g=new r((function(e,t){l.then((function(t){e(o(t,h-1))}),(function(e){t(o(e,h-1))}))}));else if(i.__isArray(l))g=[];else if(i.__isRegExp(l))g=new RegExp(l.source,a(l)),l.lastIndex&&(g.lastIndex=l.lastIndex);else if(i.__isDate(l))g=new Date(l.getTime());else{if(d&&Buffer.isBuffer(l))return g=Buffer.allocUnsafe?Buffer.allocUnsafe(l.length):new Buffer(l.length),l.copy(g),g;e(l,Error)?g=Object.create(l):void 0===u?(m=Object.getPrototypeOf(l),g=Object.create(m)):(g=Object.create(u),m=u)}if(s){var v=f.indexOf(l);if(-1!=v)return p[v];f.push(l),p.push(g)}for(var y in e(l,t)&&l.forEach((function(e,t){var n=o(t,h-1),r=o(e,h-1);g.set(n,r)})),e(l,n)&&l.forEach((function(e){var t=o(e,h-1);g.add(t)})),l){var b;m&&(b=Object.getOwnPropertyDescriptor(m,y)),b&&null==b.set||(g[y]=o(l[y],h-1))}if(Object.getOwnPropertySymbols){var _=Object.getOwnPropertySymbols(l);for(y=0;y<_.length;y++){var w=_[y];(!(k=Object.getOwnPropertyDescriptor(l,w))||k.enumerable||c)&&(g[w]=o(l[w],h-1),k.enumerable||Object.defineProperty(g,w,{enumerable:!1}))}}if(c){var x=Object.getOwnPropertyNames(l);for(y=0;y<x.length;y++){var k,C=x[y];(k=Object.getOwnPropertyDescriptor(l,C))&&k.enumerable||(g[C]=o(l[C],h-1),Object.defineProperty(g,C,{enumerable:!1}))}}return g}(o,l)}function o(e){return Object.prototype.toString.call(e)}function a(e){var t="";return e.global&&(t+="g"),e.ignoreCase&&(t+="i"),e.multiline&&(t+="m"),t}return i.clonePrototype=function(e){if(null===e)return null;var t=function(){};return t.prototype=e,new t},i.__objToStr=o,i.__isDate=function(e){return"object"==typeof e&&"[object Date]"===o(e)},i.__isArray=function(e){return"object"==typeof e&&"[object Array]"===o(e)},i.__isRegExp=function(e){return"object"==typeof e&&"[object RegExp]"===o(e)},i.__getRegExpFlags=a,i}();"object"==typeof e&&e.exports&&(e.exports=n)},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(l){i=!0,o=l}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},a=d(n(0)),s=d(n(8)),l=n(4),u=d(l),c=d(n(16)),f=d(n(13)),p=d(n(25));function d(e){return e&&e.__esModule?e:{default:e}}function h(e){return e instanceof u.default||e instanceof l.BlockEmbed}var g=function(e){function t(e,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var r=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return r.emitter=n.emitter,Array.isArray(n.whitelist)&&(r.whitelist=n.whitelist.reduce((function(e,t){return e[t]=!0,e}),{})),r.domNode.addEventListener("DOMNodeInserted",(function(){})),r.optimize(),r.enable(),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),i(t,[{key:"batchStart",value:function(){this.batch=!0}},{key:"batchEnd",value:function(){this.batch=!1,this.optimize()}},{key:"deleteAt",value:function(e,n){var i=this.line(e),a=r(i,2),s=a[0],u=a[1],p=this.line(e+n),d=r(p,1)[0];if(o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"deleteAt",this).call(this,e,n),null!=d&&s!==d&&u>0){if(s instanceof l.BlockEmbed||d instanceof l.BlockEmbed)return void this.optimize();if(s instanceof f.default){var h=s.newlineIndex(s.length(),!0);if(h>-1&&(s=s.split(h+1))===d)return void this.optimize()}else if(d instanceof f.default){var g=d.newlineIndex(0);g>-1&&d.split(g+1)}var m=d.children.head instanceof c.default?null:d.children.head;s.moveChildren(d,m),s.remove()}this.optimize()}},{key:"enable",value:function(){var e=!(arguments.length>0&&void 0!==arguments[0])||arguments[0];this.domNode.setAttribute("contenteditable",e)}},{key:"formatAt",value:function(e,n,r,i){(null==this.whitelist||this.whitelist[r])&&(o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"formatAt",this).call(this,e,n,r,i),this.optimize())}},{key:"insertAt",value:function(e,n,r){if(null==r||null==this.whitelist||this.whitelist[n]){if(e>=this.length())if(null==r||null==a.default.query(n,a.default.Scope.BLOCK)){var i=a.default.create(this.statics.defaultChild);this.appendChild(i),null==r&&n.endsWith("\n")&&(n=n.slice(0,-1)),i.insertAt(0,n,r)}else{var s=a.default.create(n,r);this.appendChild(s)}else o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"insertAt",this).call(this,e,n,r);this.optimize()}}},{key:"insertBefore",value:function(e,n){if(e.statics.scope===a.default.Scope.INLINE_BLOT){var r=a.default.create(this.statics.defaultChild);r.appendChild(e),e=r}o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"insertBefore",this).call(this,e,n)}},{key:"leaf",value:function(e){return this.path(e).pop()||[null,-1]}},{key:"line",value:function(e){return e===this.length()?this.line(e-1):this.descendant(h,e)}},{key:"lines",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:Number.MAX_VALUE,n=function e(t,n,r){var i=[],o=r;return t.children.forEachAt(n,r,(function(t,n,r){h(t)?i.push(t):t instanceof a.default.Container&&(i=i.concat(e(t,n,o))),o-=r})),i};return n(this,e,t)}},{key:"optimize",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:[],n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};!0!==this.batch&&(o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"optimize",this).call(this,e,n),e.length>0&&this.emitter.emit(s.default.events.SCROLL_OPTIMIZE,e,n))}},{key:"path",value:function(e){return o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"path",this).call(this,e).slice(1)}},{key:"update",value:function(e){if(!0!==this.batch){var n=s.default.sources.USER;"string"==typeof e&&(n=e),Array.isArray(e)||(e=this.observer.takeRecords()),e.length>0&&this.emitter.emit(s.default.events.SCROLL_BEFORE_UPDATE,n,e),o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"update",this).call(this,e.concat([])),e.length>0&&this.emitter.emit(s.default.events.SCROLL_UPDATE,n,e)}}}]),t}(a.default.Scroll);g.blotName="scroll",g.className="ql-editor",g.tagName="DIV",g.defaultChild="block",g.allowedChildren=[u.default,l.BlockEmbed,p.default],t.default=g},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.SHORTKEY=t.default=void 0;var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(l){i=!0,o=l}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=g(n(21)),s=g(n(11)),l=g(n(3)),u=g(n(2)),c=g(n(20)),f=g(n(0)),p=g(n(5)),d=g(n(10)),h=g(n(9));function g(e){return e&&e.__esModule?e:{default:e}}function m(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var v=(0,d.default)("quill:keyboard"),y=/Mac/i.test(navigator.platform)?"metaKey":"ctrlKey",b=function(e){function t(e,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var r=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,n));return r.bindings={},Object.keys(r.options.bindings).forEach((function(t){("list autofill"!==t||null==e.scroll.whitelist||e.scroll.whitelist.list)&&r.options.bindings[t]&&r.addBinding(r.options.bindings[t])})),r.addBinding({key:t.keys.ENTER,shiftKey:null},C),r.addBinding({key:t.keys.ENTER,metaKey:null,ctrlKey:null,altKey:null},(function(){})),/Firefox/i.test(navigator.userAgent)?(r.addBinding({key:t.keys.BACKSPACE},{collapsed:!0},w),r.addBinding({key:t.keys.DELETE},{collapsed:!0},x)):(r.addBinding({key:t.keys.BACKSPACE},{collapsed:!0,prefix:/^.?$/},w),r.addBinding({key:t.keys.DELETE},{collapsed:!0,suffix:/^.?$/},x)),r.addBinding({key:t.keys.BACKSPACE},{collapsed:!1},k),r.addBinding({key:t.keys.DELETE},{collapsed:!1},k),r.addBinding({key:t.keys.BACKSPACE,altKey:null,ctrlKey:null,metaKey:null,shiftKey:null},{collapsed:!0,offset:0},w),r.listen(),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),o(t,null,[{key:"match",value:function(e,t){return t=A(t),!["altKey","ctrlKey","metaKey","shiftKey"].some((function(n){return!!t[n]!==e[n]&&null!==t[n]}))&&t.key===(e.which||e.keyCode)}}]),o(t,[{key:"addBinding",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{},n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:{},r=A(e);if(null==r||null==r.key)return v.warn("Attempted to add invalid keyboard binding",r);"function"==typeof t&&(t={handler:t}),"function"==typeof n&&(n={handler:n}),r=(0,l.default)(r,t,n),this.bindings[r.key]=this.bindings[r.key]||[],this.bindings[r.key].push(r)}},{key:"listen",value:function(){var e=this;this.quill.root.addEventListener("keydown",(function(n){if(!n.defaultPrevented){var o=n.which||n.keyCode,a=(e.bindings[o]||[]).filter((function(e){return t.match(n,e)}));if(0!==a.length){var l=e.quill.getSelection();if(null!=l&&e.quill.hasFocus()){var u=e.quill.getLine(l.index),c=i(u,2),p=c[0],d=c[1],h=e.quill.getLeaf(l.index),g=i(h,2),m=g[0],v=g[1],y=0===l.length?[m,v]:e.quill.getLeaf(l.index+l.length),b=i(y,2),_=b[0],w=b[1],x=m instanceof f.default.Text?m.value().slice(0,v):"",k=_ instanceof f.default.Text?_.value().slice(w):"",C={collapsed:0===l.length,empty:0===l.length&&p.length()<=1,format:e.quill.getFormat(l),offset:d,prefix:x,suffix:k};a.some((function(t){if(null!=t.collapsed&&t.collapsed!==C.collapsed)return!1;if(null!=t.empty&&t.empty!==C.empty)return!1;if(null!=t.offset&&t.offset!==C.offset)return!1;if(Array.isArray(t.format)){if(t.format.every((function(e){return null==C.format[e]})))return!1}else if("object"===r(t.format)&&!Object.keys(t.format).every((function(e){return!0===t.format[e]?null!=C.format[e]:!1===t.format[e]?null==C.format[e]:(0,s.default)(t.format[e],C.format[e])})))return!1;return!(null!=t.prefix&&!t.prefix.test(C.prefix)||null!=t.suffix&&!t.suffix.test(C.suffix)||!0===t.handler.call(e,l,C))}))&&n.preventDefault()}}}}))}}]),t}(h.default);function _(e,t){var n,r=e===b.keys.LEFT?"prefix":"suffix";return m(n={key:e,shiftKey:t,altKey:null},r,/^$/),m(n,"handler",(function(n){var r=n.index;e===b.keys.RIGHT&&(r+=n.length+1);var o=this.quill.getLeaf(r);return!(i(o,1)[0]instanceof f.default.Embed&&(e===b.keys.LEFT?t?this.quill.setSelection(n.index-1,n.length+1,p.default.sources.USER):this.quill.setSelection(n.index-1,p.default.sources.USER):t?this.quill.setSelection(n.index,n.length+1,p.default.sources.USER):this.quill.setSelection(n.index+n.length+1,p.default.sources.USER),1))})),n}function w(e,t){if(!(0===e.index||this.quill.getLength()<=1)){var n=this.quill.getLine(e.index),r=i(n,1)[0],o={};if(0===t.offset){var a=this.quill.getLine(e.index-1),s=i(a,1)[0];if(null!=s&&s.length()>1){var l=r.formats(),u=this.quill.getFormat(e.index-1,1);o=c.default.attributes.diff(l,u)||{}}}var f=/[\uD800-\uDBFF][\uDC00-\uDFFF]$/.test(t.prefix)?2:1;this.quill.deleteText(e.index-f,f,p.default.sources.USER),Object.keys(o).length>0&&this.quill.formatLine(e.index-f,f,o,p.default.sources.USER),this.quill.focus()}}function x(e,t){var n=/^[\uD800-\uDBFF][\uDC00-\uDFFF]/.test(t.suffix)?2:1;if(!(e.index>=this.quill.getLength()-n)){var r={},o=0,a=this.quill.getLine(e.index),s=i(a,1)[0];if(t.offset>=s.length()-1){var l=this.quill.getLine(e.index+1),u=i(l,1)[0];if(u){var f=s.formats(),d=this.quill.getFormat(e.index,1);r=c.default.attributes.diff(f,d)||{},o=u.length()}}this.quill.deleteText(e.index,n,p.default.sources.USER),Object.keys(r).length>0&&this.quill.formatLine(e.index+o-1,n,r,p.default.sources.USER)}}function k(e){var t=this.quill.getLines(e),n={};if(t.length>1){var r=t[0].formats(),i=t[t.length-1].formats();n=c.default.attributes.diff(i,r)||{}}this.quill.deleteText(e,p.default.sources.USER),Object.keys(n).length>0&&this.quill.formatLine(e.index,1,n,p.default.sources.USER),this.quill.setSelection(e.index,p.default.sources.SILENT),this.quill.focus()}function C(e,t){var n=this;e.length>0&&this.quill.scroll.deleteAt(e.index,e.length);var r=Object.keys(t.format).reduce((function(e,n){return f.default.query(n,f.default.Scope.BLOCK)&&!Array.isArray(t.format[n])&&(e[n]=t.format[n]),e}),{});this.quill.insertText(e.index,"\n",r,p.default.sources.USER),this.quill.setSelection(e.index+1,p.default.sources.SILENT),this.quill.focus(),Object.keys(t.format).forEach((function(e){null==r[e]&&(Array.isArray(t.format[e])||"link"!==e&&n.quill.format(e,t.format[e],p.default.sources.USER))}))}function E(e){return{key:b.keys.TAB,shiftKey:!e,format:{"code-block":!0},handler:function(t){var n=f.default.query("code-block"),r=t.index,o=t.length,a=this.quill.scroll.descendant(n,r),s=i(a,2),l=s[0],u=s[1];if(null!=l){var c=this.quill.getIndex(l),d=l.newlineIndex(u,!0)+1,h=l.newlineIndex(c+u+o),g=l.domNode.textContent.slice(d,h).split("\n");u=0,g.forEach((function(t,i){e?(l.insertAt(d+u,n.TAB),u+=n.TAB.length,0===i?r+=n.TAB.length:o+=n.TAB.length):t.startsWith(n.TAB)&&(l.deleteAt(d+u,n.TAB.length),u-=n.TAB.length,0===i?r-=n.TAB.length:o-=n.TAB.length),u+=t.length+1})),this.quill.update(p.default.sources.USER),this.quill.setSelection(r,o,p.default.sources.SILENT)}}}}function O(e){return{key:e[0].toUpperCase(),shortKey:!0,handler:function(t,n){this.quill.format(e,!n.format[e],p.default.sources.USER)}}}function A(e){if("string"==typeof e||"number"==typeof e)return A({key:e});if("object"===(void 0===e?"undefined":r(e))&&(e=(0,a.default)(e,!1)),"string"==typeof e.key)if(null!=b.keys[e.key.toUpperCase()])e.key=b.keys[e.key.toUpperCase()];else{if(1!==e.key.length)return null;e.key=e.key.toUpperCase().charCodeAt(0)}return e.shortKey&&(e[y]=e.shortKey,delete e.shortKey),e}b.keys={BACKSPACE:8,TAB:9,ENTER:13,ESCAPE:27,LEFT:37,UP:38,RIGHT:39,DOWN:40,DELETE:46},b.DEFAULTS={bindings:{bold:O("bold"),italic:O("italic"),underline:O("underline"),indent:{key:b.keys.TAB,format:["blockquote","indent","list"],handler:function(e,t){if(t.collapsed&&0!==t.offset)return!0;this.quill.format("indent","+1",p.default.sources.USER)}},outdent:{key:b.keys.TAB,shiftKey:!0,format:["blockquote","indent","list"],handler:function(e,t){if(t.collapsed&&0!==t.offset)return!0;this.quill.format("indent","-1",p.default.sources.USER)}},"outdent backspace":{key:b.keys.BACKSPACE,collapsed:!0,shiftKey:null,metaKey:null,ctrlKey:null,altKey:null,format:["indent","list"],offset:0,handler:function(e,t){null!=t.format.indent?this.quill.format("indent","-1",p.default.sources.USER):null!=t.format.list&&this.quill.format("list",!1,p.default.sources.USER)}},"indent code-block":E(!0),"outdent code-block":E(!1),"remove tab":{key:b.keys.TAB,shiftKey:!0,collapsed:!0,prefix:/\t$/,handler:function(e){this.quill.deleteText(e.index-1,1,p.default.sources.USER)}},tab:{key:b.keys.TAB,handler:function(e){this.quill.history.cutoff();var t=(new u.default).retain(e.index).delete(e.length).insert("\t");this.quill.updateContents(t,p.default.sources.USER),this.quill.history.cutoff(),this.quill.setSelection(e.index+1,p.default.sources.SILENT)}},"list empty enter":{key:b.keys.ENTER,collapsed:!0,format:["list"],empty:!0,handler:function(e,t){this.quill.format("list",!1,p.default.sources.USER),t.format.indent&&this.quill.format("indent",!1,p.default.sources.USER)}},"checklist enter":{key:b.keys.ENTER,collapsed:!0,format:{list:"checked"},handler:function(e){var t=this.quill.getLine(e.index),n=i(t,2),r=n[0],o=n[1],a=(0,l.default)({},r.formats(),{list:"checked"}),s=(new u.default).retain(e.index).insert("\n",a).retain(r.length()-o-1).retain(1,{list:"unchecked"});this.quill.updateContents(s,p.default.sources.USER),this.quill.setSelection(e.index+1,p.default.sources.SILENT),this.quill.scrollIntoView()}},"header enter":{key:b.keys.ENTER,collapsed:!0,format:["header"],suffix:/^$/,handler:function(e,t){var n=this.quill.getLine(e.index),r=i(n,2),o=r[0],a=r[1],s=(new u.default).retain(e.index).insert("\n",t.format).retain(o.length()-a-1).retain(1,{header:null});this.quill.updateContents(s,p.default.sources.USER),this.quill.setSelection(e.index+1,p.default.sources.SILENT),this.quill.scrollIntoView()}},"list autofill":{key:" ",collapsed:!0,format:{list:!1},prefix:/^\s*?(\d+\.|-|\*|\[ ?\]|\[x\])$/,handler:function(e,t){var n=t.prefix.length,r=this.quill.getLine(e.index),o=i(r,2),a=o[0],s=o[1];if(s>n)return!0;var l=void 0;switch(t.prefix.trim()){case"[]":case"[ ]":l="unchecked";break;case"[x]":l="checked";break;case"-":case"*":l="bullet";break;default:l="ordered"}this.quill.insertText(e.index," ",p.default.sources.USER),this.quill.history.cutoff();var c=(new u.default).retain(e.index-s).delete(n+1).retain(a.length()-2-s).retain(1,{list:l});this.quill.updateContents(c,p.default.sources.USER),this.quill.history.cutoff(),this.quill.setSelection(e.index-n,p.default.sources.SILENT)}},"code exit":{key:b.keys.ENTER,collapsed:!0,format:["code-block"],prefix:/\n\n$/,suffix:/^\s+$/,handler:function(e){var t=this.quill.getLine(e.index),n=i(t,2),r=n[0],o=n[1],a=(new u.default).retain(e.index+r.length()-o-2).retain(1,{"code-block":null}).delete(1);this.quill.updateContents(a,p.default.sources.USER)}},"embed left":_(b.keys.LEFT,!1),"embed left shift":_(b.keys.LEFT,!0),"embed right":_(b.keys.RIGHT,!1),"embed right shift":_(b.keys.RIGHT,!0)}},t.default=b,t.SHORTKEY=y},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(l){i=!0,o=l}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},i=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=l(n(0)),s=l(n(7));function l(e){return e&&e.__esModule?e:{default:e}}var u=function(e){function t(e,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var r=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return r.selection=n,r.textNode=document.createTextNode(t.CONTENTS),r.domNode.appendChild(r.textNode),r._length=0,r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),o(t,null,[{key:"value",value:function(){}}]),o(t,[{key:"detach",value:function(){null!=this.parent&&this.parent.removeChild(this)}},{key:"format",value:function(e,n){if(0!==this._length)return i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"format",this).call(this,e,n);for(var r=this,o=0;null!=r&&r.statics.scope!==a.default.Scope.BLOCK_BLOT;)o+=r.offset(r.parent),r=r.parent;null!=r&&(this._length=t.CONTENTS.length,r.optimize(),r.formatAt(o,t.CONTENTS.length,e,n),this._length=0)}},{key:"index",value:function(e,n){return e===this.textNode?0:i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"index",this).call(this,e,n)}},{key:"length",value:function(){return this._length}},{key:"position",value:function(){return[this.textNode,this.textNode.data.length]}},{key:"remove",value:function(){i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"remove",this).call(this),this.parent=null}},{key:"restore",value:function(){if(!this.selection.composing&&null!=this.parent){var e=this.textNode,n=this.selection.getNativeRange(),i=void 0,o=void 0,l=void 0;if(null!=n&&n.start.node===e&&n.end.node===e){var u=[e,n.start.offset,n.end.offset];i=u[0],o=u[1],l=u[2]}for(;null!=this.domNode.lastChild&&this.domNode.lastChild!==this.textNode;)this.domNode.parentNode.insertBefore(this.domNode.lastChild,this.domNode);if(this.textNode.data!==t.CONTENTS){var c=this.textNode.data.split(t.CONTENTS).join("");this.next instanceof s.default?(i=this.next.domNode,this.next.insertAt(0,c),this.textNode.data=t.CONTENTS):(this.textNode.data=c,this.parent.insertBefore(a.default.create(this.textNode),this),this.textNode=document.createTextNode(t.CONTENTS),this.domNode.appendChild(this.textNode))}if(this.remove(),null!=o){var f=[o,l].map((function(e){return Math.max(0,Math.min(i.data.length,e-1))})),p=r(f,2);return o=p[0],l=p[1],{startNode:i,startOffset:o,endNode:i,endOffset:l}}}}},{key:"update",value:function(e,t){var n=this;if(e.some((function(e){return"characterData"===e.type&&e.target===n.textNode}))){var r=this.restore();r&&(t.range=r)}}},{key:"value",value:function(){return""}}]),t}(a.default.Embed);u.blotName="cursor",u.className="ql-cursor",u.tagName="span",u.CONTENTS="\ufeff",t.default=u},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r=a(n(0)),i=n(4),o=a(i);function a(e){return e&&e.__esModule?e:{default:e}}function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function l(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var u=function(e){function t(){return s(this,t),l(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),t}(r.default.Container);u.allowedChildren=[o.default,i.BlockEmbed,u],t.default=u},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.ColorStyle=t.ColorClass=t.ColorAttributor=void 0;var r,i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},a=n(0),s=(r=a)&&r.__esModule?r:{default:r};function l(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var c=function(e){function t(){return l(this,t),u(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),i(t,[{key:"value",value:function(e){var n=o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"value",this).call(this,e);return n.startsWith("rgb(")?"#"+(n=n.replace(/^[^\d]+/,"").replace(/[^\d]+$/,"")).split(",").map((function(e){return("00"+parseInt(e).toString(16)).slice(-2)})).join(""):n}}]),t}(s.default.Attributor.Style),f=new s.default.Attributor.Class("color","ql-color",{scope:s.default.Scope.INLINE}),p=new c("color","color",{scope:s.default.Scope.INLINE});t.ColorAttributor=c,t.ColorClass=f,t.ColorStyle=p},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.sanitize=t.default=void 0;var r,i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},a=n(6);function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function l(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var u=function(e){function t(){return s(this,t),l(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),i(t,[{key:"format",value:function(e,n){if(e!==this.statics.blotName||!n)return o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"format",this).call(this,e,n);n=this.constructor.sanitize(n),this.domNode.setAttribute("href",n)}}],[{key:"create",value:function(e){var n=o(t.__proto__||Object.getPrototypeOf(t),"create",this).call(this,e);return e=this.sanitize(e),n.setAttribute("href",e),n.setAttribute("rel","noopener noreferrer"),n.setAttribute("target","_blank"),n}},{key:"formats",value:function(e){return e.getAttribute("href")}},{key:"sanitize",value:function(e){return c(e,this.PROTOCOL_WHITELIST)?e:this.SANITIZED_URL}}]),t}(((r=a)&&r.__esModule?r:{default:r}).default);function c(e,t){var n=document.createElement("a");n.href=e;var r=n.href.slice(0,n.href.indexOf(":"));return t.indexOf(r)>-1}u.blotName="link",u.tagName="A",u.SANITIZED_URL="about:blank",u.PROTOCOL_WHITELIST=["http","https","mailto","tel"],t.default=u,t.sanitize=c},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=s(n(23)),a=s(n(107));function s(e){return e&&e.__esModule?e:{default:e}}var l=0;function u(e,t){e.setAttribute(t,!("true"===e.getAttribute(t)))}var c=function(){function e(t){var n=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.select=t,this.container=document.createElement("span"),this.buildPicker(),this.select.style.display="none",this.select.parentNode.insertBefore(this.container,this.select),this.label.addEventListener("mousedown",(function(){n.togglePicker()})),this.label.addEventListener("keydown",(function(e){switch(e.keyCode){case o.default.keys.ENTER:n.togglePicker();break;case o.default.keys.ESCAPE:n.escape(),e.preventDefault()}})),this.select.addEventListener("change",this.update.bind(this))}return i(e,[{key:"togglePicker",value:function(){this.container.classList.toggle("ql-expanded"),u(this.label,"aria-expanded"),u(this.options,"aria-hidden")}},{key:"buildItem",value:function(e){var t=this,n=document.createElement("span");return n.tabIndex="0",n.setAttribute("role","button"),n.classList.add("ql-picker-item"),e.hasAttribute("value")&&n.setAttribute("data-value",e.getAttribute("value")),e.textContent&&n.setAttribute("data-label",e.textContent),n.addEventListener("click",(function(){t.selectItem(n,!0)})),n.addEventListener("keydown",(function(e){switch(e.keyCode){case o.default.keys.ENTER:t.selectItem(n,!0),e.preventDefault();break;case o.default.keys.ESCAPE:t.escape(),e.preventDefault()}})),n}},{key:"buildLabel",value:function(){var e=document.createElement("span");return e.classList.add("ql-picker-label"),e.innerHTML=a.default,e.tabIndex="0",e.setAttribute("role","button"),e.setAttribute("aria-expanded","false"),this.container.appendChild(e),e}},{key:"buildOptions",value:function(){var e=this,t=document.createElement("span");t.classList.add("ql-picker-options"),t.setAttribute("aria-hidden","true"),t.tabIndex="-1",t.id="ql-picker-options-"+l,l+=1,this.label.setAttribute("aria-controls",t.id),this.options=t,[].slice.call(this.select.options).forEach((function(n){var r=e.buildItem(n);t.appendChild(r),!0===n.selected&&e.selectItem(r)})),this.container.appendChild(t)}},{key:"buildPicker",value:function(){var e=this;[].slice.call(this.select.attributes).forEach((function(t){e.container.setAttribute(t.name,t.value)})),this.container.classList.add("ql-picker"),this.label=this.buildLabel(),this.buildOptions()}},{key:"escape",value:function(){var e=this;this.close(),setTimeout((function(){return e.label.focus()}),1)}},{key:"close",value:function(){this.container.classList.remove("ql-expanded"),this.label.setAttribute("aria-expanded","false"),this.options.setAttribute("aria-hidden","true")}},{key:"selectItem",value:function(e){var t=arguments.length>1&&void 0!==arguments[1]&&arguments[1],n=this.container.querySelector(".ql-selected");if(e!==n&&(null!=n&&n.classList.remove("ql-selected"),null!=e&&(e.classList.add("ql-selected"),this.select.selectedIndex=[].indexOf.call(e.parentNode.children,e),e.hasAttribute("data-value")?this.label.setAttribute("data-value",e.getAttribute("data-value")):this.label.removeAttribute("data-value"),e.hasAttribute("data-label")?this.label.setAttribute("data-label",e.getAttribute("data-label")):this.label.removeAttribute("data-label"),t))){if("function"==typeof Event)this.select.dispatchEvent(new Event("change"));else if("object"===("undefined"==typeof Event?"undefined":r(Event))){var i=document.createEvent("Event");i.initEvent("change",!0,!0),this.select.dispatchEvent(i)}this.close()}}},{key:"update",value:function(){var e=void 0;if(this.select.selectedIndex>-1){var t=this.container.querySelector(".ql-picker-options").children[this.select.selectedIndex];e=this.select.options[this.select.selectedIndex],this.selectItem(t)}else this.selectItem(null);var n=null!=e&&e!==this.select.querySelector("option[selected]");this.label.classList.toggle("ql-active",n)}}]),e}();t.default=c},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r=v(n(0)),i=v(n(5)),o=n(4),a=v(o),s=v(n(16)),l=v(n(25)),u=v(n(24)),c=v(n(35)),f=v(n(6)),p=v(n(22)),d=v(n(7)),h=v(n(55)),g=v(n(42)),m=v(n(23));function v(e){return e&&e.__esModule?e:{default:e}}i.default.register({"blots/block":a.default,"blots/block/embed":o.BlockEmbed,"blots/break":s.default,"blots/container":l.default,"blots/cursor":u.default,"blots/embed":c.default,"blots/inline":f.default,"blots/scroll":p.default,"blots/text":d.default,"modules/clipboard":h.default,"modules/history":g.default,"modules/keyboard":m.default}),r.default.register(a.default,s.default,u.default,f.default,p.default,d.default),t.default=i.default},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r=n(1),i=function(){function e(e){this.domNode=e,this.domNode[r.DATA_KEY]={blot:this}}return Object.defineProperty(e.prototype,"statics",{get:function(){return this.constructor},enumerable:!0,configurable:!0}),e.create=function(e){if(null==this.tagName)throw new r.ParchmentError("Blot definition missing tagName");var t;return Array.isArray(this.tagName)?("string"==typeof e&&(e=e.toUpperCase(),parseInt(e).toString()===e&&(e=parseInt(e))),t="number"==typeof e?document.createElement(this.tagName[e-1]):this.tagName.indexOf(e)>-1?document.createElement(e):document.createElement(this.tagName[0])):t=document.createElement(this.tagName),this.className&&t.classList.add(this.className),t},e.prototype.attach=function(){null!=this.parent&&(this.scroll=this.parent.scroll)},e.prototype.clone=function(){var e=this.domNode.cloneNode(!1);return r.create(e)},e.prototype.detach=function(){null!=this.parent&&this.parent.removeChild(this),delete this.domNode[r.DATA_KEY]},e.prototype.deleteAt=function(e,t){this.isolate(e,t).remove()},e.prototype.formatAt=function(e,t,n,i){var o=this.isolate(e,t);if(null!=r.query(n,r.Scope.BLOT)&&i)o.wrap(n,i);else if(null!=r.query(n,r.Scope.ATTRIBUTE)){var a=r.create(this.statics.scope);o.wrap(a),a.format(n,i)}},e.prototype.insertAt=function(e,t,n){var i=null==n?r.create("text",t):r.create(t,n),o=this.split(e);this.parent.insertBefore(i,o)},e.prototype.insertInto=function(e,t){void 0===t&&(t=null),null!=this.parent&&this.parent.children.remove(this);var n=null;e.children.insertBefore(this,t),null!=t&&(n=t.domNode),this.domNode.parentNode==e.domNode&&this.domNode.nextSibling==n||e.domNode.insertBefore(this.domNode,n),this.parent=e,this.attach()},e.prototype.isolate=function(e,t){var n=this.split(e);return n.split(t),n},e.prototype.length=function(){return 1},e.prototype.offset=function(e){return void 0===e&&(e=this.parent),null==this.parent||this==e?0:this.parent.children.offset(this)+this.parent.offset(e)},e.prototype.optimize=function(e){null!=this.domNode[r.DATA_KEY]&&delete this.domNode[r.DATA_KEY].mutations},e.prototype.remove=function(){null!=this.domNode.parentNode&&this.domNode.parentNode.removeChild(this.domNode),this.detach()},e.prototype.replace=function(e){null!=e.parent&&(e.parent.insertBefore(this,e.next),e.remove())},e.prototype.replaceWith=function(e,t){var n="string"==typeof e?r.create(e,t):e;return n.replace(this),n},e.prototype.split=function(e,t){return 0===e?this:this.next},e.prototype.update=function(e,t){},e.prototype.wrap=function(e,t){var n="string"==typeof e?r.create(e,t):e;return null!=this.parent&&this.parent.insertBefore(n,this.next),n.appendChild(this),n},e.blotName="abstract",e}();t.default=i},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r=n(12),i=n(32),o=n(33),a=n(1),s=function(){function e(e){this.attributes={},this.domNode=e,this.build()}return e.prototype.attribute=function(e,t){t?e.add(this.domNode,t)&&(null!=e.value(this.domNode)?this.attributes[e.attrName]=e:delete this.attributes[e.attrName]):(e.remove(this.domNode),delete this.attributes[e.attrName])},e.prototype.build=function(){var e=this;this.attributes={};var t=r.default.keys(this.domNode),n=i.default.keys(this.domNode),s=o.default.keys(this.domNode);t.concat(n).concat(s).forEach((function(t){var n=a.query(t,a.Scope.ATTRIBUTE);n instanceof r.default&&(e.attributes[n.attrName]=n)}))},e.prototype.copy=function(e){var t=this;Object.keys(this.attributes).forEach((function(n){var r=t.attributes[n].value(t.domNode);e.format(n,r)}))},e.prototype.move=function(e){var t=this;this.copy(e),Object.keys(this.attributes).forEach((function(e){t.attributes[e].remove(t.domNode)})),this.attributes={}},e.prototype.values=function(){var e=this;return Object.keys(this.attributes).reduce((function(t,n){return t[n]=e.attributes[n].value(e.domNode),t}),{})},e}();t.default=s},function(e,t,n){var r,i=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});function o(e,t){return(e.getAttribute("class")||"").split(/\s+/).filter((function(e){return 0===e.indexOf(t+"-")}))}Object.defineProperty(t,"__esModule",{value:!0});var a=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.keys=function(e){return(e.getAttribute("class")||"").split(/\s+/).map((function(e){return e.split("-").slice(0,-1).join("-")}))},t.prototype.add=function(e,t){return!!this.canAdd(e,t)&&(this.remove(e),e.classList.add(this.keyName+"-"+t),!0)},t.prototype.remove=function(e){o(e,this.keyName).forEach((function(t){e.classList.remove(t)})),0===e.classList.length&&e.removeAttribute("class")},t.prototype.value=function(e){var t=(o(e,this.keyName)[0]||"").slice(this.keyName.length+1);return this.canAdd(e,t)?t:""},t}(n(12).default);t.default=a},function(e,t,n){var r,i=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});function o(e){var t=e.split("-"),n=t.slice(1).map((function(e){return e[0].toUpperCase()+e.slice(1)})).join("");return t[0]+n}Object.defineProperty(t,"__esModule",{value:!0});var a=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.keys=function(e){return(e.getAttribute("style")||"").split(";").map((function(e){return e.split(":")[0].trim()}))},t.prototype.add=function(e,t){return!!this.canAdd(e,t)&&(e.style[o(this.keyName)]=t,!0)},t.prototype.remove=function(e){e.style[o(this.keyName)]="",e.getAttribute("style")||e.removeAttribute("style")},t.prototype.value=function(e){var t=e.style[o(this.keyName)];return this.canAdd(e,t)?t:""},t}(n(12).default);t.default=a},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),i=function(){function e(t,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.quill=t,this.options=n,this.modules={}}return r(e,[{key:"init",value:function(){var e=this;Object.keys(this.options.modules).forEach((function(t){null==e.modules[t]&&e.addModule(t)}))}},{key:"addModule",value:function(e){var t=this.quill.constructor.import("modules/"+e);return this.modules[e]=new t(this.quill,this.options.modules[e]||{}),this.modules[e]}}]),e}();i.DEFAULTS={modules:{}},i.themes={default:i},t.default=i},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),i=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},o=s(n(0)),a=s(n(7));function s(e){return e&&e.__esModule?e:{default:e}}var l="\ufeff",u=function(e){function t(e){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var n=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return n.contentNode=document.createElement("span"),n.contentNode.setAttribute("contenteditable",!1),[].slice.call(n.domNode.childNodes).forEach((function(e){n.contentNode.appendChild(e)})),n.leftGuard=document.createTextNode(l),n.rightGuard=document.createTextNode(l),n.domNode.appendChild(n.leftGuard),n.domNode.appendChild(n.contentNode),n.domNode.appendChild(n.rightGuard),n}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),r(t,[{key:"index",value:function(e,n){return e===this.leftGuard?0:e===this.rightGuard?1:i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"index",this).call(this,e,n)}},{key:"restore",value:function(e){var t=void 0,n=void 0,r=e.data.split(l).join("");if(e===this.leftGuard)if(this.prev instanceof a.default){var i=this.prev.length();this.prev.insertAt(i,r),t={startNode:this.prev.domNode,startOffset:i+r.length}}else n=document.createTextNode(r),this.parent.insertBefore(o.default.create(n),this),t={startNode:n,startOffset:r.length};else e===this.rightGuard&&(this.next instanceof a.default?(this.next.insertAt(0,r),t={startNode:this.next.domNode,startOffset:r.length}):(n=document.createTextNode(r),this.parent.insertBefore(o.default.create(n),this.next),t={startNode:n,startOffset:r.length}));return e.data=l,t}},{key:"update",value:function(e,t){var n=this;e.forEach((function(e){if("characterData"===e.type&&(e.target===n.leftGuard||e.target===n.rightGuard)){var r=n.restore(e.target);r&&(t.range=r)}}))}}]),t}(o.default.Embed);t.default=u},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.AlignStyle=t.AlignClass=t.AlignAttribute=void 0;var r,i=n(0),o=(r=i)&&r.__esModule?r:{default:r},a={scope:o.default.Scope.BLOCK,whitelist:["right","center","justify"]},s=new o.default.Attributor.Attribute("align","align",a),l=new o.default.Attributor.Class("align","ql-align",a),u=new o.default.Attributor.Style("align","text-align",a);t.AlignAttribute=s,t.AlignClass=l,t.AlignStyle=u},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.BackgroundStyle=t.BackgroundClass=void 0;var r,i=n(0),o=(r=i)&&r.__esModule?r:{default:r},a=n(26),s=new o.default.Attributor.Class("background","ql-bg",{scope:o.default.Scope.INLINE}),l=new a.ColorAttributor("background","background-color",{scope:o.default.Scope.INLINE});t.BackgroundClass=s,t.BackgroundStyle=l},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.DirectionStyle=t.DirectionClass=t.DirectionAttribute=void 0;var r,i=n(0),o=(r=i)&&r.__esModule?r:{default:r},a={scope:o.default.Scope.BLOCK,whitelist:["rtl"]},s=new o.default.Attributor.Attribute("direction","dir",a),l=new o.default.Attributor.Class("direction","ql-direction",a),u=new o.default.Attributor.Style("direction","direction",a);t.DirectionAttribute=s,t.DirectionClass=l,t.DirectionStyle=u},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.FontClass=t.FontStyle=void 0;var r,i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},a=n(0),s=(r=a)&&r.__esModule?r:{default:r};function l(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var c={scope:s.default.Scope.INLINE,whitelist:["serif","monospace"]},f=new s.default.Attributor.Class("font","ql-font",c),p=new(function(e){function t(){return l(this,t),u(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),i(t,[{key:"value",value:function(e){return o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"value",this).call(this,e).replace(/["']/g,"")}}]),t}(s.default.Attributor.Style))("font","font-family",c);t.FontStyle=p,t.FontClass=f},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.SizeStyle=t.SizeClass=void 0;var r,i=n(0),o=(r=i)&&r.__esModule?r:{default:r},a=new o.default.Attributor.Class("size","ql-size",{scope:o.default.Scope.INLINE,whitelist:["small","large","huge"]}),s=new o.default.Attributor.Style("size","font-size",{scope:o.default.Scope.INLINE,whitelist:["10px","18px","32px"]});t.SizeClass=a,t.SizeStyle=s},function(e,t,n){e.exports={align:{"":n(76),center:n(77),right:n(78),justify:n(79)},background:n(80),blockquote:n(81),bold:n(82),clean:n(83),code:n(58),"code-block":n(58),color:n(84),direction:{"":n(85),rtl:n(86)},float:{center:n(87),full:n(88),left:n(89),right:n(90)},formula:n(91),header:{1:n(92),2:n(93)},italic:n(94),image:n(95),indent:{"+1":n(96),"-1":n(97)},link:n(98),list:{ordered:n(99),bullet:n(100),check:n(101)},script:{sub:n(102),super:n(103)},strike:n(104),underline:n(105),video:n(106)}},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.getLastChangeIndex=t.default=void 0;var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),i=a(n(0)),o=a(n(5));function a(e){return e&&e.__esModule?e:{default:e}}var s=function(e){function t(e,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var r=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,n));return r.lastRecorded=0,r.ignoreChange=!1,r.clear(),r.quill.on(o.default.events.EDITOR_CHANGE,(function(e,t,n,i){e!==o.default.events.TEXT_CHANGE||r.ignoreChange||(r.options.userOnly&&i!==o.default.sources.USER?r.transform(t):r.record(t,n))})),r.quill.keyboard.addBinding({key:"Z",shortKey:!0},r.undo.bind(r)),r.quill.keyboard.addBinding({key:"Z",shortKey:!0,shiftKey:!0},r.redo.bind(r)),/Win/i.test(navigator.platform)&&r.quill.keyboard.addBinding({key:"Y",shortKey:!0},r.redo.bind(r)),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),r(t,[{key:"change",value:function(e,t){if(0!==this.stack[e].length){var n=this.stack[e].pop();this.stack[t].push(n),this.lastRecorded=0,this.ignoreChange=!0,this.quill.updateContents(n[e],o.default.sources.USER),this.ignoreChange=!1;var r=l(n[e]);this.quill.setSelection(r)}}},{key:"clear",value:function(){this.stack={undo:[],redo:[]}}},{key:"cutoff",value:function(){this.lastRecorded=0}},{key:"record",value:function(e,t){if(0!==e.ops.length){this.stack.redo=[];var n=this.quill.getContents().diff(t),r=Date.now();if(this.lastRecorded+this.options.delay>r&&this.stack.undo.length>0){var i=this.stack.undo.pop();n=n.compose(i.undo),e=i.redo.compose(e)}else this.lastRecorded=r;this.stack.undo.push({redo:e,undo:n}),this.stack.undo.length>this.options.maxStack&&this.stack.undo.shift()}}},{key:"redo",value:function(){this.change("redo","undo")}},{key:"transform",value:function(e){this.stack.undo.forEach((function(t){t.undo=e.transform(t.undo,!0),t.redo=e.transform(t.redo,!0)})),this.stack.redo.forEach((function(t){t.undo=e.transform(t.undo,!0),t.redo=e.transform(t.redo,!0)}))}},{key:"undo",value:function(){this.change("undo","redo")}}]),t}(a(n(9)).default);function l(e){var t=e.reduce((function(e,t){return e+=t.delete||0}),0),n=e.length()-t;return function(e){var t=e.ops[e.ops.length-1];return null!=t&&(null!=t.insert?"string"==typeof t.insert&&t.insert.endsWith("\n"):null!=t.attributes&&Object.keys(t.attributes).some((function(e){return null!=i.default.query(e,i.default.Scope.BLOCK)})))}(e)&&(n-=1),n}s.DEFAULTS={delay:1e3,maxStack:100,userOnly:!1},t.default=s,t.getLastChangeIndex=l},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.BaseTooltip=void 0;var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),i=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},o=h(n(3)),a=h(n(2)),s=h(n(8)),l=h(n(23)),u=h(n(34)),c=h(n(59)),f=h(n(60)),p=h(n(28)),d=h(n(61));function h(e){return e&&e.__esModule?e:{default:e}}function g(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function m(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function v(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var y=[!1,"center","right","justify"],b=["#000000","#e60000","#ff9900","#ffff00","#008a00","#0066cc","#9933ff","#ffffff","#facccc","#ffebcc","#ffffcc","#cce8cc","#cce0f5","#ebd6ff","#bbbbbb","#f06666","#ffc266","#ffff66","#66b966","#66a3e0","#c285ff","#888888","#a10000","#b26b00","#b2b200","#006100","#0047b2","#6b24b2","#444444","#5c0000","#663d00","#666600","#003700","#002966","#3d1466"],_=[!1,"serif","monospace"],w=["1","2","3",!1],x=["small",!1,"large","huge"],k=function(e){function t(e,n){g(this,t);var r=m(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,n));return e.emitter.listenDOM("click",document.body,(function t(n){if(!document.body.contains(e.root))return document.body.removeEventListener("click",t);null==r.tooltip||r.tooltip.root.contains(n.target)||document.activeElement===r.tooltip.textbox||r.quill.hasFocus()||r.tooltip.hide(),null!=r.pickers&&r.pickers.forEach((function(e){e.container.contains(n.target)||e.close()}))})),r}return v(t,e),r(t,[{key:"addModule",value:function(e){var n=i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"addModule",this).call(this,e);return"toolbar"===e&&this.extendToolbar(n),n}},{key:"buildButtons",value:function(e,t){e.forEach((function(e){(e.getAttribute("class")||"").split(/\s+/).forEach((function(n){if(n.startsWith("ql-")&&(n=n.slice("ql-".length),null!=t[n]))if("direction"===n)e.innerHTML=t[n][""]+t[n].rtl;else if("string"==typeof t[n])e.innerHTML=t[n];else{var r=e.value||"";null!=r&&t[n][r]&&(e.innerHTML=t[n][r])}}))}))}},{key:"buildPickers",value:function(e,t){var n=this;this.pickers=e.map((function(e){if(e.classList.contains("ql-align"))return null==e.querySelector("option")&&E(e,y),new f.default(e,t.align);if(e.classList.contains("ql-background")||e.classList.contains("ql-color")){var n=e.classList.contains("ql-background")?"background":"color";return null==e.querySelector("option")&&E(e,b,"background"===n?"#ffffff":"#000000"),new c.default(e,t[n])}return null==e.querySelector("option")&&(e.classList.contains("ql-font")?E(e,_):e.classList.contains("ql-header")?E(e,w):e.classList.contains("ql-size")&&E(e,x)),new p.default(e)})),this.quill.on(s.default.events.EDITOR_CHANGE,(function(){n.pickers.forEach((function(e){e.update()}))}))}}]),t}(u.default);k.DEFAULTS=(0,o.default)(!0,{},u.default.DEFAULTS,{modules:{toolbar:{handlers:{formula:function(){this.quill.theme.tooltip.edit("formula")},image:function(){var e=this,t=this.container.querySelector("input.ql-image[type=file]");null==t&&((t=document.createElement("input")).setAttribute("type","file"),t.setAttribute("accept","image/png, image/gif, image/jpeg, image/bmp, image/x-icon"),t.classList.add("ql-image"),t.addEventListener("change",(function(){if(null!=t.files&&null!=t.files[0]){var n=new FileReader;n.onload=function(n){var r=e.quill.getSelection(!0);e.quill.updateContents((new a.default).retain(r.index).delete(r.length).insert({image:n.target.result}),s.default.sources.USER),e.quill.setSelection(r.index+1,s.default.sources.SILENT),t.value=""},n.readAsDataURL(t.files[0])}})),this.container.appendChild(t)),t.click()},video:function(){this.quill.theme.tooltip.edit("video")}}}}});var C=function(e){function t(e,n){g(this,t);var r=m(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,n));return r.textbox=r.root.querySelector('input[type="text"]'),r.listen(),r}return v(t,e),r(t,[{key:"listen",value:function(){var e=this;this.textbox.addEventListener("keydown",(function(t){l.default.match(t,"enter")?(e.save(),t.preventDefault()):l.default.match(t,"escape")&&(e.cancel(),t.preventDefault())}))}},{key:"cancel",value:function(){this.hide()}},{key:"edit",value:function(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"link",t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:null;this.root.classList.remove("ql-hidden"),this.root.classList.add("ql-editing"),null!=t?this.textbox.value=t:e!==this.root.getAttribute("data-mode")&&(this.textbox.value=""),this.position(this.quill.getBounds(this.quill.selection.savedRange)),this.textbox.select(),this.textbox.setAttribute("placeholder",this.textbox.getAttribute("data-"+e)||""),this.root.setAttribute("data-mode",e)}},{key:"restoreFocus",value:function(){var e=this.quill.scrollingContainer.scrollTop;this.quill.focus(),this.quill.scrollingContainer.scrollTop=e}},{key:"save",value:function(){var e,t,n=this.textbox.value;switch(this.root.getAttribute("data-mode")){case"link":var r=this.quill.root.scrollTop;this.linkRange?(this.quill.formatText(this.linkRange,"link",n,s.default.sources.USER),delete this.linkRange):(this.restoreFocus(),this.quill.format("link",n,s.default.sources.USER)),this.quill.root.scrollTop=r;break;case"video":t=(e=n).match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtube\.com\/watch.*v=([a-zA-Z0-9_-]+)/)||e.match(/^(?:(https?):\/\/)?(?:(?:www|m)\.)?youtu\.be\/([a-zA-Z0-9_-]+)/),n=t?(t[1]||"https")+"://www.youtube.com/embed/"+t[2]+"?showinfo=0":(t=e.match(/^(?:(https?):\/\/)?(?:www\.)?vimeo\.com\/(\d+)/))?(t[1]||"https")+"://player.vimeo.com/video/"+t[2]+"/":e;case"formula":if(!n)break;var i=this.quill.getSelection(!0);if(null!=i){var o=i.index+i.length;this.quill.insertEmbed(o,this.root.getAttribute("data-mode"),n,s.default.sources.USER),"formula"===this.root.getAttribute("data-mode")&&this.quill.insertText(o+1," ",s.default.sources.USER),this.quill.setSelection(o+2,s.default.sources.USER)}}this.textbox.value="",this.hide()}}]),t}(d.default);function E(e,t){var n=arguments.length>2&&void 0!==arguments[2]&&arguments[2];t.forEach((function(t){var r=document.createElement("option");t===n?r.setAttribute("selected","selected"):r.setAttribute("value",t),e.appendChild(r)}))}t.BaseTooltip=C,t.default=k},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(){this.head=this.tail=null,this.length=0}return e.prototype.append=function(){for(var e=[],t=0;t<arguments.length;t++)e[t]=arguments[t];this.insertBefore(e[0],null),e.length>1&&this.append.apply(this,e.slice(1))},e.prototype.contains=function(e){for(var t,n=this.iterator();t=n();)if(t===e)return!0;return!1},e.prototype.insertBefore=function(e,t){e&&(e.next=t,null!=t?(e.prev=t.prev,null!=t.prev&&(t.prev.next=e),t.prev=e,t===this.head&&(this.head=e)):null!=this.tail?(this.tail.next=e,e.prev=this.tail,this.tail=e):(e.prev=null,this.head=this.tail=e),this.length+=1)},e.prototype.offset=function(e){for(var t=0,n=this.head;null!=n;){if(n===e)return t;t+=n.length(),n=n.next}return-1},e.prototype.remove=function(e){this.contains(e)&&(null!=e.prev&&(e.prev.next=e.next),null!=e.next&&(e.next.prev=e.prev),e===this.head&&(this.head=e.next),e===this.tail&&(this.tail=e.prev),this.length-=1)},e.prototype.iterator=function(e){return void 0===e&&(e=this.head),function(){var t=e;return null!=e&&(e=e.next),t}},e.prototype.find=function(e,t){void 0===t&&(t=!1);for(var n,r=this.iterator();n=r();){var i=n.length();if(e<i||t&&e===i&&(null==n.next||0!==n.next.length()))return[n,e];e-=i}return[null,0]},e.prototype.forEach=function(e){for(var t,n=this.iterator();t=n();)e(t)},e.prototype.forEachAt=function(e,t,n){if(!(t<=0))for(var r,i=this.find(e),o=i[0],a=e-i[1],s=this.iterator(o);(r=s())&&a<e+t;){var l=r.length();e>a?n(r,e-a,Math.min(t,a+l-e)):n(r,0,Math.min(l,e+t-a)),a+=l}},e.prototype.map=function(e){return this.reduce((function(t,n){return t.push(e(n)),t}),[])},e.prototype.reduce=function(e,t){for(var n,r=this.iterator();n=r();)t=e(t,n);return t},e}();t.default=r},function(e,t,n){var r,i=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(17),a=n(1),s={attributes:!0,characterData:!0,characterDataOldValue:!0,childList:!0,subtree:!0},l=function(e){function t(t){var n=e.call(this,t)||this;return n.scroll=n,n.observer=new MutationObserver((function(e){n.update(e)})),n.observer.observe(n.domNode,s),n.attach(),n}return i(t,e),t.prototype.detach=function(){e.prototype.detach.call(this),this.observer.disconnect()},t.prototype.deleteAt=function(t,n){this.update(),0===t&&n===this.length()?this.children.forEach((function(e){e.remove()})):e.prototype.deleteAt.call(this,t,n)},t.prototype.formatAt=function(t,n,r,i){this.update(),e.prototype.formatAt.call(this,t,n,r,i)},t.prototype.insertAt=function(t,n,r){this.update(),e.prototype.insertAt.call(this,t,n,r)},t.prototype.optimize=function(t,n){var r=this;void 0===t&&(t=[]),void 0===n&&(n={}),e.prototype.optimize.call(this,n);for(var i=[].slice.call(this.observer.takeRecords());i.length>0;)t.push(i.pop());for(var s=function(e,t){void 0===t&&(t=!0),null!=e&&e!==r&&null!=e.domNode.parentNode&&(null==e.domNode[a.DATA_KEY].mutations&&(e.domNode[a.DATA_KEY].mutations=[]),t&&s(e.parent))},l=function(e){null!=e.domNode[a.DATA_KEY]&&null!=e.domNode[a.DATA_KEY].mutations&&(e instanceof o.default&&e.children.forEach(l),e.optimize(n))},u=t,c=0;u.length>0;c+=1){if(c>=100)throw new Error("[Parchment] Maximum optimize iterations reached");for(u.forEach((function(e){var t=a.find(e.target,!0);null!=t&&(t.domNode===e.target&&("childList"===e.type?(s(a.find(e.previousSibling,!1)),[].forEach.call(e.addedNodes,(function(e){var t=a.find(e,!1);s(t,!1),t instanceof o.default&&t.children.forEach((function(e){s(e,!1)}))}))):"attributes"===e.type&&s(t.prev)),s(t))})),this.children.forEach(l),i=(u=[].slice.call(this.observer.takeRecords())).slice();i.length>0;)t.push(i.pop())}},t.prototype.update=function(t,n){var r=this;void 0===n&&(n={}),(t=t||this.observer.takeRecords()).map((function(e){var t=a.find(e.target,!0);return null==t?null:null==t.domNode[a.DATA_KEY].mutations?(t.domNode[a.DATA_KEY].mutations=[e],t):(t.domNode[a.DATA_KEY].mutations.push(e),null)})).forEach((function(e){null!=e&&e!==r&&null!=e.domNode[a.DATA_KEY]&&e.update(e.domNode[a.DATA_KEY].mutations||[],n)})),null!=this.domNode[a.DATA_KEY].mutations&&e.prototype.update.call(this,this.domNode[a.DATA_KEY].mutations,n),this.optimize(t,n)},t.blotName="scroll",t.defaultChild="block",t.scope=a.Scope.BLOCK_BLOT,t.tagName="DIV",t}(o.default);t.default=l},function(e,t,n){var r,i=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(18),a=n(1),s=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.formats=function(n){if(n.tagName!==t.tagName)return e.formats.call(this,n)},t.prototype.format=function(n,r){var i=this;n!==this.statics.blotName||r?e.prototype.format.call(this,n,r):(this.children.forEach((function(e){e instanceof o.default||(e=e.wrap(t.blotName,!0)),i.attributes.copy(e)})),this.unwrap())},t.prototype.formatAt=function(t,n,r,i){null!=this.formats()[r]||a.query(r,a.Scope.ATTRIBUTE)?this.isolate(t,n).format(r,i):e.prototype.formatAt.call(this,t,n,r,i)},t.prototype.optimize=function(n){e.prototype.optimize.call(this,n);var r=this.formats();if(0===Object.keys(r).length)return this.unwrap();var i=this.next;i instanceof t&&i.prev===this&&function(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(var n in e)if(e[n]!==t[n])return!1;return!0}(r,i.formats())&&(i.moveChildren(this),i.remove())},t.blotName="inline",t.scope=a.Scope.INLINE_BLOT,t.tagName="SPAN",t}(o.default);t.default=s},function(e,t,n){var r,i=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(18),a=n(1),s=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.formats=function(n){var r=a.query(t.blotName).tagName;if(n.tagName!==r)return e.formats.call(this,n)},t.prototype.format=function(n,r){null!=a.query(n,a.Scope.BLOCK)&&(n!==this.statics.blotName||r?e.prototype.format.call(this,n,r):this.replaceWith(t.blotName))},t.prototype.formatAt=function(t,n,r,i){null!=a.query(r,a.Scope.BLOCK)?this.format(r,i):e.prototype.formatAt.call(this,t,n,r,i)},t.prototype.insertAt=function(t,n,r){if(null==r||null!=a.query(n,a.Scope.INLINE))e.prototype.insertAt.call(this,t,n,r);else{var i=this.split(t),o=a.create(n,r);i.parent.insertBefore(o,i)}},t.prototype.update=function(t,n){navigator.userAgent.match(/Trident/)?this.build():e.prototype.update.call(this,t,n)},t.blotName="block",t.scope=a.Scope.BLOCK_BLOT,t.tagName="P",t}(o.default);t.default=s},function(e,t,n){var r,i=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=function(e){function t(){return null!==e&&e.apply(this,arguments)||this}return i(t,e),t.formats=function(e){},t.prototype.format=function(t,n){e.prototype.formatAt.call(this,0,this.length(),t,n)},t.prototype.formatAt=function(t,n,r,i){0===t&&n===this.length()?this.format(r,i):e.prototype.formatAt.call(this,t,n,r,i)},t.prototype.formats=function(){return this.statics.formats(this.domNode)},t}(n(19).default);t.default=o},function(e,t,n){var r,i=this&&this.__extends||(r=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)t.hasOwnProperty(n)&&(e[n]=t[n])},function(e,t){function n(){this.constructor=e}r(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)});Object.defineProperty(t,"__esModule",{value:!0});var o=n(19),a=n(1),s=function(e){function t(t){var n=e.call(this,t)||this;return n.text=n.statics.value(n.domNode),n}return i(t,e),t.create=function(e){return document.createTextNode(e)},t.value=function(e){var t=e.data;return t.normalize&&(t=t.normalize()),t},t.prototype.deleteAt=function(e,t){this.domNode.data=this.text=this.text.slice(0,e)+this.text.slice(e+t)},t.prototype.index=function(e,t){return this.domNode===e?t:-1},t.prototype.insertAt=function(t,n,r){null==r?(this.text=this.text.slice(0,t)+n+this.text.slice(t),this.domNode.data=this.text):e.prototype.insertAt.call(this,t,n,r)},t.prototype.length=function(){return this.text.length},t.prototype.optimize=function(n){e.prototype.optimize.call(this,n),this.text=this.statics.value(this.domNode),0===this.text.length?this.remove():this.next instanceof t&&this.next.prev===this&&(this.insertAt(this.length(),this.next.value()),this.next.remove())},t.prototype.position=function(e,t){return[this.domNode,e]},t.prototype.split=function(e,t){if(void 0===t&&(t=!1),!t){if(0===e)return this;if(e===this.length())return this.next}var n=a.create(this.domNode.splitText(e));return this.parent.insertBefore(n,this.next),this.text=this.statics.value(this.domNode),n},t.prototype.update=function(e,t){var n=this;e.some((function(e){return"characterData"===e.type&&e.target===n.domNode}))&&(this.text=this.statics.value(this.domNode))},t.prototype.value=function(){return this.text},t.blotName="text",t.scope=a.Scope.INLINE_BLOT,t}(o.default);t.default=s},function(e,t,n){var r=document.createElement("div");if(r.classList.toggle("test-class",!1),r.classList.contains("test-class")){var i=DOMTokenList.prototype.toggle;DOMTokenList.prototype.toggle=function(e,t){return arguments.length>1&&!this.contains(e)==!t?t:i.call(this,e)}}String.prototype.startsWith||(String.prototype.startsWith=function(e,t){return t=t||0,this.substr(t,e.length)===e}),String.prototype.endsWith||(String.prototype.endsWith=function(e,t){var n=this.toString();("number"!=typeof t||!isFinite(t)||Math.floor(t)!==t||t>n.length)&&(t=n.length),t-=e.length;var r=n.indexOf(e,t);return-1!==r&&r===t}),Array.prototype.find||Object.defineProperty(Array.prototype,"find",{value:function(e){if(null===this)throw new TypeError("Array.prototype.find called on null or undefined");if("function"!=typeof e)throw new TypeError("predicate must be a function");for(var t,n=Object(this),r=n.length>>>0,i=arguments[1],o=0;o<r;o++)if(t=n[o],e.call(i,t,o,n))return t}}),document.addEventListener("DOMContentLoaded",(function(){document.execCommand("enableObjectResizing",!1,!1),document.execCommand("autoUrlDetect",!1,!1)}))},function(e,t){var n=-1;function r(e,t,l){if(e==t)return e?[[0,e]]:[];(l<0||e.length<l)&&(l=null);var c=o(e,t),f=e.substring(0,c);c=a(e=e.substring(c),t=t.substring(c));var p=e.substring(e.length-c),d=function(e,t){var s;if(!e)return[[1,t]];if(!t)return[[n,e]];var l=e.length>t.length?e:t,u=e.length>t.length?t:e,c=l.indexOf(u);if(-1!=c)return s=[[1,l.substring(0,c)],[0,u],[1,l.substring(c+u.length)]],e.length>t.length&&(s[0][0]=s[2][0]=n),s;if(1==u.length)return[[n,e],[1,t]];var f=function(e,t){var n=e.length>t.length?e:t,r=e.length>t.length?t:e;if(n.length<4||2*r.length<n.length)return null;function i(e,t,n){for(var r,i,s,l,u=e.substring(n,n+Math.floor(e.length/4)),c=-1,f="";-1!=(c=t.indexOf(u,c+1));){var p=o(e.substring(n),t.substring(c)),d=a(e.substring(0,n),t.substring(0,c));f.length<d+p&&(f=t.substring(c-d,c)+t.substring(c,c+p),r=e.substring(0,n-d),i=e.substring(n+p),s=t.substring(0,c-d),l=t.substring(c+p))}return 2*f.length>=e.length?[r,i,s,l,f]:null}var s,l,u,c,f,p=i(n,r,Math.ceil(n.length/4)),d=i(n,r,Math.ceil(n.length/2));if(!p&&!d)return null;s=d?p&&p[4].length>d[4].length?p:d:p,e.length>t.length?(l=s[0],u=s[1],c=s[2],f=s[3]):(c=s[0],f=s[1],l=s[2],u=s[3]);var h=s[4];return[l,u,c,f,h]}(e,t);if(f){var p=f[0],d=f[1],h=f[2],g=f[3],m=f[4],v=r(p,h),y=r(d,g);return v.concat([[0,m]],y)}return function(e,t){for(var r=e.length,o=t.length,a=Math.ceil((r+o)/2),s=a,l=2*a,u=new Array(l),c=new Array(l),f=0;f<l;f++)u[f]=-1,c[f]=-1;u[s+1]=0,c[s+1]=0;for(var p=r-o,d=p%2!=0,h=0,g=0,m=0,v=0,y=0;y<a;y++){for(var b=-y+h;b<=y-g;b+=2){for(var _=s+b,w=(O=b==-y||b!=y&&u[_-1]<u[_+1]?u[_+1]:u[_-1]+1)-b;O<r&&w<o&&e.charAt(O)==t.charAt(w);)O++,w++;if(u[_]=O,O>r)g+=2;else if(w>o)h+=2;else if(d&&(C=s+p-b)>=0&&C<l&&-1!=c[C]&&O>=(k=r-c[C]))return i(e,t,O,w)}for(var x=-y+m;x<=y-v;x+=2){for(var k,C=s+x,E=(k=x==-y||x!=y&&c[C-1]<c[C+1]?c[C+1]:c[C-1]+1)-x;k<r&&E<o&&e.charAt(r-k-1)==t.charAt(o-E-1);)k++,E++;if(c[C]=k,k>r)v+=2;else if(E>o)m+=2;else if(!d){var O;if((_=s+p-x)>=0&&_<l&&-1!=u[_])if(w=s+(O=u[_])-_,O>=(k=r-k))return i(e,t,O,w)}}}return[[n,e],[1,t]]}(e,t)}(e=e.substring(0,e.length-c),t=t.substring(0,t.length-c));return f&&d.unshift([0,f]),p&&d.push([0,p]),s(d),null!=l&&(d=function(e,t){var r=function(e,t){if(0===t)return[0,e];for(var r=0,i=0;i<e.length;i++){var o=e[i];if(o[0]===n||0===o[0]){var a=r+o[1].length;if(t===a)return[i+1,e];if(t<a){e=e.slice();var s=t-r,l=[o[0],o[1].slice(0,s)],u=[o[0],o[1].slice(s)];return e.splice(i,1,l,u),[i+1,e]}r=a}}throw new Error("cursor_pos is out of bounds!")}(e,t),i=r[1],o=r[0],a=i[o],s=i[o+1];if(null==a)return e;if(0!==a[0])return e;if(null!=s&&a[1]+s[1]===s[1]+a[1])return i.splice(o,2,s,a),u(i,o,2);if(null!=s&&0===s[1].indexOf(a[1])){i.splice(o,2,[s[0],a[1]],[0,a[1]]);var l=s[1].slice(a[1].length);return l.length>0&&i.splice(o+2,0,[s[0],l]),u(i,o,3)}return e}(d,l)),d=function(e){for(var t=!1,r=function(e){return e.charCodeAt(0)>=56320&&e.charCodeAt(0)<=57343},i=function(e){return e.charCodeAt(e.length-1)>=55296&&e.charCodeAt(e.length-1)<=56319},o=2;o<e.length;o+=1)0===e[o-2][0]&&i(e[o-2][1])&&e[o-1][0]===n&&r(e[o-1][1])&&1===e[o][0]&&r(e[o][1])&&(t=!0,e[o-1][1]=e[o-2][1].slice(-1)+e[o-1][1],e[o][1]=e[o-2][1].slice(-1)+e[o][1],e[o-2][1]=e[o-2][1].slice(0,-1));if(!t)return e;var a=[];for(o=0;o<e.length;o+=1)e[o][1].length>0&&a.push(e[o]);return a}(d)}function i(e,t,n,i){var o=e.substring(0,n),a=t.substring(0,i),s=e.substring(n),l=t.substring(i),u=r(o,a),c=r(s,l);return u.concat(c)}function o(e,t){if(!e||!t||e.charAt(0)!=t.charAt(0))return 0;for(var n=0,r=Math.min(e.length,t.length),i=r,o=0;n<i;)e.substring(o,i)==t.substring(o,i)?o=n=i:r=i,i=Math.floor((r-n)/2+n);return i}function a(e,t){if(!e||!t||e.charAt(e.length-1)!=t.charAt(t.length-1))return 0;for(var n=0,r=Math.min(e.length,t.length),i=r,o=0;n<i;)e.substring(e.length-i,e.length-o)==t.substring(t.length-i,t.length-o)?o=n=i:r=i,i=Math.floor((r-n)/2+n);return i}function s(e){e.push([0,""]);for(var t,r=0,i=0,l=0,u="",c="";r<e.length;)switch(e[r][0]){case 1:l++,c+=e[r][1],r++;break;case n:i++,u+=e[r][1],r++;break;case 0:i+l>1?(0!==i&&0!==l&&(0!==(t=o(c,u))&&(r-i-l>0&&0==e[r-i-l-1][0]?e[r-i-l-1][1]+=c.substring(0,t):(e.splice(0,0,[0,c.substring(0,t)]),r++),c=c.substring(t),u=u.substring(t)),0!==(t=a(c,u))&&(e[r][1]=c.substring(c.length-t)+e[r][1],c=c.substring(0,c.length-t),u=u.substring(0,u.length-t))),0===i?e.splice(r-l,i+l,[1,c]):0===l?e.splice(r-i,i+l,[n,u]):e.splice(r-i-l,i+l,[n,u],[1,c]),r=r-i-l+(i?1:0)+(l?1:0)+1):0!==r&&0==e[r-1][0]?(e[r-1][1]+=e[r][1],e.splice(r,1)):r++,l=0,i=0,u="",c=""}""===e[e.length-1][1]&&e.pop();var f=!1;for(r=1;r<e.length-1;)0==e[r-1][0]&&0==e[r+1][0]&&(e[r][1].substring(e[r][1].length-e[r-1][1].length)==e[r-1][1]?(e[r][1]=e[r-1][1]+e[r][1].substring(0,e[r][1].length-e[r-1][1].length),e[r+1][1]=e[r-1][1]+e[r+1][1],e.splice(r-1,1),f=!0):e[r][1].substring(0,e[r+1][1].length)==e[r+1][1]&&(e[r-1][1]+=e[r+1][1],e[r][1]=e[r][1].substring(e[r+1][1].length)+e[r+1][1],e.splice(r+1,1),f=!0)),r++;f&&s(e)}var l=r;function u(e,t,n){for(var r=t+n-1;r>=0&&r>=t-1;r--)if(r+1<e.length){var i=e[r],o=e[r+1];i[0]===o[1]&&e.splice(r,2,[i[0],i[1]+o[1]])}return e}l.INSERT=1,l.DELETE=n,l.EQUAL=0,e.exports=l},function(e,t){function n(e){var t=[];for(var n in e)t.push(n);return t}(e.exports="function"==typeof Object.keys?Object.keys:n).shim=n},function(e,t){var n="[object Arguments]"==function(){return Object.prototype.toString.call(arguments)}();function r(e){return"[object Arguments]"==Object.prototype.toString.call(e)}function i(e){return e&&"object"==typeof e&&"number"==typeof e.length&&Object.prototype.hasOwnProperty.call(e,"callee")&&!Object.prototype.propertyIsEnumerable.call(e,"callee")||!1}(t=e.exports=n?r:i).supported=r,t.unsupported=i},function(e,t){var n=Object.prototype.hasOwnProperty,r="~";function i(){}function o(e,t,n){this.fn=e,this.context=t,this.once=n||!1}function a(){this._events=new i,this._eventsCount=0}Object.create&&(i.prototype=Object.create(null),(new i).__proto__||(r=!1)),a.prototype.eventNames=function(){var e,t,i=[];if(0===this._eventsCount)return i;for(t in e=this._events)n.call(e,t)&&i.push(r?t.slice(1):t);return Object.getOwnPropertySymbols?i.concat(Object.getOwnPropertySymbols(e)):i},a.prototype.listeners=function(e,t){var n=r?r+e:e,i=this._events[n];if(t)return!!i;if(!i)return[];if(i.fn)return[i.fn];for(var o=0,a=i.length,s=new Array(a);o<a;o++)s[o]=i[o].fn;return s},a.prototype.emit=function(e,t,n,i,o,a){var s=r?r+e:e;if(!this._events[s])return!1;var l,u,c=this._events[s],f=arguments.length;if(c.fn){switch(c.once&&this.removeListener(e,c.fn,void 0,!0),f){case 1:return c.fn.call(c.context),!0;case 2:return c.fn.call(c.context,t),!0;case 3:return c.fn.call(c.context,t,n),!0;case 4:return c.fn.call(c.context,t,n,i),!0;case 5:return c.fn.call(c.context,t,n,i,o),!0;case 6:return c.fn.call(c.context,t,n,i,o,a),!0}for(u=1,l=new Array(f-1);u<f;u++)l[u-1]=arguments[u];c.fn.apply(c.context,l)}else{var p,d=c.length;for(u=0;u<d;u++)switch(c[u].once&&this.removeListener(e,c[u].fn,void 0,!0),f){case 1:c[u].fn.call(c[u].context);break;case 2:c[u].fn.call(c[u].context,t);break;case 3:c[u].fn.call(c[u].context,t,n);break;case 4:c[u].fn.call(c[u].context,t,n,i);break;default:if(!l)for(p=1,l=new Array(f-1);p<f;p++)l[p-1]=arguments[p];c[u].fn.apply(c[u].context,l)}}return!0},a.prototype.on=function(e,t,n){var i=new o(t,n||this),a=r?r+e:e;return this._events[a]?this._events[a].fn?this._events[a]=[this._events[a],i]:this._events[a].push(i):(this._events[a]=i,this._eventsCount++),this},a.prototype.once=function(e,t,n){var i=new o(t,n||this,!0),a=r?r+e:e;return this._events[a]?this._events[a].fn?this._events[a]=[this._events[a],i]:this._events[a].push(i):(this._events[a]=i,this._eventsCount++),this},a.prototype.removeListener=function(e,t,n,o){var a=r?r+e:e;if(!this._events[a])return this;if(!t)return 0==--this._eventsCount?this._events=new i:delete this._events[a],this;var s=this._events[a];if(s.fn)s.fn!==t||o&&!s.once||n&&s.context!==n||(0==--this._eventsCount?this._events=new i:delete this._events[a]);else{for(var l=0,u=[],c=s.length;l<c;l++)(s[l].fn!==t||o&&!s[l].once||n&&s[l].context!==n)&&u.push(s[l]);u.length?this._events[a]=1===u.length?u[0]:u:0==--this._eventsCount?this._events=new i:delete this._events[a]}return this},a.prototype.removeAllListeners=function(e){var t;return e?(t=r?r+e:e,this._events[t]&&(0==--this._eventsCount?this._events=new i:delete this._events[t])):(this._events=new i,this._eventsCount=0),this},a.prototype.off=a.prototype.removeListener,a.prototype.addListener=a.prototype.on,a.prototype.setMaxListeners=function(){return this},a.prefixed=r,a.EventEmitter=a,void 0!==e&&(e.exports=a)},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.matchText=t.matchSpacing=t.matchNewline=t.matchBlot=t.matchAttributor=t.default=void 0;var r="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(e){return typeof e}:function(e){return e&&"function"==typeof Symbol&&e.constructor===Symbol&&e!==Symbol.prototype?"symbol":typeof e},i=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(l){i=!0,o=l}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=b(n(3)),s=b(n(2)),l=b(n(0)),u=b(n(5)),c=b(n(10)),f=b(n(9)),p=n(36),d=n(37),h=b(n(13)),g=n(26),m=n(38),v=n(39),y=n(40);function b(e){return e&&e.__esModule?e:{default:e}}function _(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}var w=(0,c.default)("quill:clipboard"),x="__ql-matcher",k=[[Node.TEXT_NODE,q],[Node.TEXT_NODE,P],["br",function(e,t){return j(t,"\n")||t.insert("\n"),t}],[Node.ELEMENT_NODE,P],[Node.ELEMENT_NODE,M],[Node.ELEMENT_NODE,F],[Node.ELEMENT_NODE,L],[Node.ELEMENT_NODE,function(e,t){var n={},r=e.style||{};return r.fontStyle&&"italic"===S(e).fontStyle&&(n.italic=!0),r.fontWeight&&(S(e).fontWeight.startsWith("bold")||parseInt(S(e).fontWeight)>=700)&&(n.bold=!0),Object.keys(n).length>0&&(t=A(t,n)),parseFloat(r.textIndent||0)>0&&(t=(new s.default).insert("\t").concat(t)),t}],["li",function(e,t){var n=l.default.query(e);if(null==n||"list-item"!==n.blotName||!j(t,"\n"))return t;for(var r=-1,i=e.parentNode;!i.classList.contains("ql-clipboard");)"list"===(l.default.query(i)||{}).blotName&&(r+=1),i=i.parentNode;return r<=0?t:t.compose((new s.default).retain(t.length()-1).retain(1,{indent:r}))}],["b",N.bind(N,"bold")],["i",N.bind(N,"italic")],["style",function(){return new s.default}]],C=[p.AlignAttribute,m.DirectionAttribute].reduce((function(e,t){return e[t.keyName]=t,e}),{}),E=[p.AlignStyle,d.BackgroundStyle,g.ColorStyle,m.DirectionStyle,v.FontStyle,y.SizeStyle].reduce((function(e,t){return e[t.keyName]=t,e}),{}),O=function(e){function t(e,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var r=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,n));return r.quill.root.addEventListener("paste",r.onPaste.bind(r)),r.container=r.quill.addContainer("ql-clipboard"),r.container.setAttribute("contenteditable",!0),r.container.setAttribute("tabindex",-1),r.matchers=[],k.concat(r.options.matchers).forEach((function(e){var t=i(e,2),o=t[0],a=t[1];(n.matchVisual||a!==F)&&r.addMatcher(o,a)})),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),o(t,[{key:"addMatcher",value:function(e,t){this.matchers.push([e,t])}},{key:"convert",value:function(e){if("string"==typeof e)return this.container.innerHTML=e.replace(/\>\r?\n +\</g,"><"),this.convert();var t=this.quill.getFormat(this.quill.selection.savedRange.index);if(t[h.default.blotName]){var n=this.container.innerText;return this.container.innerHTML="",(new s.default).insert(n,_({},h.default.blotName,t[h.default.blotName]))}var r=this.prepareMatching(),o=i(r,2),a=o[0],l=o[1],u=D(this.container,a,l);return j(u,"\n")&&null==u.ops[u.ops.length-1].attributes&&(u=u.compose((new s.default).retain(u.length()-1).delete(1))),w.log("convert",this.container.innerHTML,u),this.container.innerHTML="",u}},{key:"dangerouslyPasteHTML",value:function(e,t){var n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:u.default.sources.API;if("string"==typeof e)this.quill.setContents(this.convert(e),t),this.quill.setSelection(0,u.default.sources.SILENT);else{var r=this.convert(t);this.quill.updateContents((new s.default).retain(e).concat(r),n),this.quill.setSelection(e+r.length(),u.default.sources.SILENT)}}},{key:"onPaste",value:function(e){var t=this;if(!e.defaultPrevented&&this.quill.isEnabled()){var n=this.quill.getSelection(),r=(new s.default).retain(n.index),i=this.quill.scrollingContainer.scrollTop;this.container.focus(),this.quill.selection.update(u.default.sources.SILENT),setTimeout((function(){r=r.concat(t.convert()).delete(n.length),t.quill.updateContents(r,u.default.sources.USER),t.quill.setSelection(r.length()-n.length,u.default.sources.SILENT),t.quill.scrollingContainer.scrollTop=i,t.quill.focus()}),1)}}},{key:"prepareMatching",value:function(){var e=this,t=[],n=[];return this.matchers.forEach((function(r){var o=i(r,2),a=o[0],s=o[1];switch(a){case Node.TEXT_NODE:n.push(s);break;case Node.ELEMENT_NODE:t.push(s);break;default:[].forEach.call(e.container.querySelectorAll(a),(function(e){e[x]=e[x]||[],e[x].push(s)}))}})),[t,n]}}]),t}(f.default);function A(e,t,n){return"object"===(void 0===t?"undefined":r(t))?Object.keys(t).reduce((function(e,n){return A(e,n,t[n])}),e):e.reduce((function(e,r){return r.attributes&&r.attributes[t]?e.push(r):e.insert(r.insert,(0,a.default)({},_({},t,n),r.attributes))}),new s.default)}function S(e){if(e.nodeType!==Node.ELEMENT_NODE)return{};var t="__ql-computed-style";return e[t]||(e[t]=window.getComputedStyle(e))}function j(e,t){for(var n="",r=e.ops.length-1;r>=0&&n.length<t.length;--r){var i=e.ops[r];if("string"!=typeof i.insert)break;n=i.insert+n}return n.slice(-1*t.length)===t}function T(e){if(0===e.childNodes.length)return!1;var t=S(e);return["block","list-item"].indexOf(t.display)>-1}function D(e,t,n){return e.nodeType===e.TEXT_NODE?n.reduce((function(t,n){return n(e,t)}),new s.default):e.nodeType===e.ELEMENT_NODE?[].reduce.call(e.childNodes||[],(function(r,i){var o=D(i,t,n);return i.nodeType===e.ELEMENT_NODE&&(o=t.reduce((function(e,t){return t(i,e)}),o),o=(i[x]||[]).reduce((function(e,t){return t(i,e)}),o)),r.concat(o)}),new s.default):new s.default}function N(e,t,n){return A(n,e,!0)}function L(e,t){var n=l.default.Attributor.Attribute.keys(e),r=l.default.Attributor.Class.keys(e),i=l.default.Attributor.Style.keys(e),o={};return n.concat(r).concat(i).forEach((function(t){var n=l.default.query(t,l.default.Scope.ATTRIBUTE);null!=n&&(o[n.attrName]=n.value(e),o[n.attrName])||(null==(n=C[t])||n.attrName!==t&&n.keyName!==t||(o[n.attrName]=n.value(e)||void 0),null==(n=E[t])||n.attrName!==t&&n.keyName!==t||(n=E[t],o[n.attrName]=n.value(e)||void 0))})),Object.keys(o).length>0&&(t=A(t,o)),t}function M(e,t){var n=l.default.query(e);if(null==n)return t;if(n.prototype instanceof l.default.Embed){var r={},i=n.value(e);null!=i&&(r[n.blotName]=i,t=(new s.default).insert(r,n.formats(e)))}else"function"==typeof n.formats&&(t=A(t,n.blotName,n.formats(e)));return t}function P(e,t){return j(t,"\n")||(T(e)||t.length()>0&&e.nextSibling&&T(e.nextSibling))&&t.insert("\n"),t}function F(e,t){if(T(e)&&null!=e.nextElementSibling&&!j(t,"\n\n")){var n=e.offsetHeight+parseFloat(S(e).marginTop)+parseFloat(S(e).marginBottom);e.nextElementSibling.offsetTop>e.offsetTop+1.5*n&&t.insert("\n")}return t}function q(e,t){var n=e.data;if("O:P"===e.parentNode.tagName)return t.insert(n.trim());if(0===n.trim().length&&e.parentNode.classList.contains("ql-clipboard"))return t;if(!S(e.parentNode).whiteSpace.startsWith("pre")){var r=function(e,t){return(t=t.replace(/[^\u00a0]/g,"")).length<1&&e?" ":t};n=(n=n.replace(/\r\n/g," ").replace(/\n/g," ")).replace(/\s\s+/g,r.bind(r,!0)),(null==e.previousSibling&&T(e.parentNode)||null!=e.previousSibling&&T(e.previousSibling))&&(n=n.replace(/^\s+/,r.bind(r,!1))),(null==e.nextSibling&&T(e.parentNode)||null!=e.nextSibling&&T(e.nextSibling))&&(n=n.replace(/\s+$/,r.bind(r,!1)))}return t.insert(n)}O.DEFAULTS={matchers:[],matchVisual:!0},t.default=O,t.matchAttributor=L,t.matchBlot=M,t.matchNewline=P,t.matchSpacing=F,t.matchText=q},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r,i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},a=n(6);function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function l(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var u=function(e){function t(){return s(this,t),l(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),i(t,[{key:"optimize",value:function(e){o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"optimize",this).call(this,e),this.domNode.tagName!==this.statics.tagName[0]&&this.replaceWith(this.statics.blotName)}}],[{key:"create",value:function(){return o(t.__proto__||Object.getPrototypeOf(t),"create",this).call(this)}},{key:"formats",value:function(){return!0}}]),t}(((r=a)&&r.__esModule?r:{default:r}).default);u.blotName="bold",u.tagName=["STRONG","B"],t.default=u},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.addControls=t.default=void 0;var r=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(l){i=!0,o=l}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=c(n(2)),a=c(n(0)),s=c(n(5)),l=c(n(10)),u=c(n(9));function c(e){return e&&e.__esModule?e:{default:e}}function f(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var p=(0,l.default)("quill:toolbar"),d=function(e){function t(e,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var i,o=f(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,n));if(Array.isArray(o.options.container)){var a=document.createElement("div");g(a,o.options.container),e.container.parentNode.insertBefore(a,e.container),o.container=a}else"string"==typeof o.options.container?o.container=document.querySelector(o.options.container):o.container=o.options.container;return o.container instanceof HTMLElement?(o.container.classList.add("ql-toolbar"),o.controls=[],o.handlers={},Object.keys(o.options.handlers).forEach((function(e){o.addHandler(e,o.options.handlers[e])})),[].forEach.call(o.container.querySelectorAll("button, select"),(function(e){o.attach(e)})),o.quill.on(s.default.events.EDITOR_CHANGE,(function(e,t){e===s.default.events.SELECTION_CHANGE&&o.update(t)})),o.quill.on(s.default.events.SCROLL_OPTIMIZE,(function(){var e=o.quill.selection.getRange(),t=r(e,1)[0];o.update(t)})),o):(i=p.error("Container required for toolbar",o.options),f(o,i))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),i(t,[{key:"addHandler",value:function(e,t){this.handlers[e]=t}},{key:"attach",value:function(e){var t=this,n=[].find.call(e.classList,(function(e){return 0===e.indexOf("ql-")}));if(n){if(n=n.slice("ql-".length),"BUTTON"===e.tagName&&e.setAttribute("type","button"),null==this.handlers[n]){if(null!=this.quill.scroll.whitelist&&null==this.quill.scroll.whitelist[n])return void p.warn("ignoring attaching to disabled format",n,e);if(null==a.default.query(n))return void p.warn("ignoring attaching to nonexistent format",n,e)}var i="SELECT"===e.tagName?"change":"click";e.addEventListener(i,(function(i){var l=void 0;if("SELECT"===e.tagName){if(e.selectedIndex<0)return;var u=e.options[e.selectedIndex];l=!u.hasAttribute("selected")&&(u.value||!1)}else l=!e.classList.contains("ql-active")&&(e.value||!e.hasAttribute("value")),i.preventDefault();t.quill.focus();var c=t.quill.selection.getRange(),f=r(c,1)[0];if(null!=t.handlers[n])t.handlers[n].call(t,l);else if(a.default.query(n).prototype instanceof a.default.Embed){if(!(l=prompt("Enter "+n)))return;t.quill.updateContents((new o.default).retain(f.index).delete(f.length).insert(function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}({},n,l)),s.default.sources.USER)}else t.quill.format(n,l,s.default.sources.USER);t.update(f)})),this.controls.push([n,e])}}},{key:"update",value:function(e){var t=null==e?{}:this.quill.getFormat(e);this.controls.forEach((function(n){var i=r(n,2),o=i[0],a=i[1];if("SELECT"===a.tagName){var s=void 0;if(null==e)s=null;else if(null==t[o])s=a.querySelector("option[selected]");else if(!Array.isArray(t[o])){var l=t[o];"string"==typeof l&&(l=l.replace(/\"/g,'\\"')),s=a.querySelector('option[value="'+l+'"]')}null==s?(a.value="",a.selectedIndex=-1):s.selected=!0}else if(null==e)a.classList.remove("ql-active");else if(a.hasAttribute("value")){var u=t[o]===a.getAttribute("value")||null!=t[o]&&t[o].toString()===a.getAttribute("value")||null==t[o]&&!a.getAttribute("value");a.classList.toggle("ql-active",u)}else a.classList.toggle("ql-active",null!=t[o])}))}}]),t}(u.default);function h(e,t,n){var r=document.createElement("button");r.setAttribute("type","button"),r.classList.add("ql-"+t),null!=n&&(r.value=n),e.appendChild(r)}function g(e,t){Array.isArray(t[0])||(t=[t]),t.forEach((function(t){var n=document.createElement("span");n.classList.add("ql-formats"),t.forEach((function(e){if("string"==typeof e)h(n,e);else{var t=Object.keys(e)[0],r=e[t];Array.isArray(r)?function(e,t,n){var r=document.createElement("select");r.classList.add("ql-"+t),n.forEach((function(e){var t=document.createElement("option");!1!==e?t.setAttribute("value",e):t.setAttribute("selected","selected"),r.appendChild(t)})),e.appendChild(r)}(n,t,r):h(n,t,r)}})),e.appendChild(n)}))}d.DEFAULTS={},d.DEFAULTS={container:null,handlers:{clean:function(){var e=this,t=this.quill.getSelection();if(null!=t)if(0==t.length){var n=this.quill.getFormat();Object.keys(n).forEach((function(t){null!=a.default.query(t,a.default.Scope.INLINE)&&e.quill.format(t,!1)}))}else this.quill.removeFormat(t,s.default.sources.USER)},direction:function(e){var t=this.quill.getFormat().align;"rtl"===e&&null==t?this.quill.format("align","right",s.default.sources.USER):e||"right"!==t||this.quill.format("align",!1,s.default.sources.USER),this.quill.format("direction",e,s.default.sources.USER)},indent:function(e){var t=this.quill.getSelection(),n=this.quill.getFormat(t),r=parseInt(n.indent||0);if("+1"===e||"-1"===e){var i="+1"===e?1:-1;"rtl"===n.direction&&(i*=-1),this.quill.format("indent",r+i,s.default.sources.USER)}},link:function(e){!0===e&&(e=prompt("Enter link URL:")),this.quill.format("link",e,s.default.sources.USER)},list:function(e){var t=this.quill.getSelection(),n=this.quill.getFormat(t);"check"===e?"checked"===n.list||"unchecked"===n.list?this.quill.format("list",!1,s.default.sources.USER):this.quill.format("list","unchecked",s.default.sources.USER):this.quill.format("list",e,s.default.sources.USER)}}},t.default=d,t.addControls=g},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <polyline class="ql-even ql-stroke" points="5 7 3 9 5 11"></polyline> <polyline class="ql-even ql-stroke" points="13 7 15 9 13 11"></polyline> <line class=ql-stroke x1=10 x2=8 y1=5 y2=13></line> </svg>'},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r,i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},a=n(28),s=function(e){function t(e,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var r=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return r.label.innerHTML=n,r.container.classList.add("ql-color-picker"),[].slice.call(r.container.querySelectorAll(".ql-picker-item"),0,7).forEach((function(e){e.classList.add("ql-primary")})),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),i(t,[{key:"buildItem",value:function(e){var n=o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"buildItem",this).call(this,e);return n.style.backgroundColor=e.getAttribute("value")||"",n}},{key:"selectItem",value:function(e,n){o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"selectItem",this).call(this,e,n);var r=this.label.querySelector(".ql-color-label"),i=e&&e.getAttribute("data-value")||"";r&&("line"===r.tagName?r.style.stroke=i:r.style.fill=i)}}]),t}(((r=a)&&r.__esModule?r:{default:r}).default);t.default=s},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r,i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},a=n(28),s=function(e){function t(e,n){!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,t);var r=function(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e));return r.container.classList.add("ql-icon-picker"),[].forEach.call(r.container.querySelectorAll(".ql-picker-item"),(function(e){e.innerHTML=n[e.getAttribute("data-value")||""]})),r.defaultItem=r.container.querySelector(".ql-selected"),r.selectItem(r.defaultItem),r}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),i(t,[{key:"selectItem",value:function(e,n){o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"selectItem",this).call(this,e,n),e=e||this.defaultItem,this.label.innerHTML=e.innerHTML}}]),t}(((r=a)&&r.__esModule?r:{default:r}).default);t.default=s},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),i=function(){function e(t,n){var r=this;!function(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}(this,e),this.quill=t,this.boundsContainer=n||document.body,this.root=t.addContainer("ql-tooltip"),this.root.innerHTML=this.constructor.TEMPLATE,this.quill.root===this.quill.scrollingContainer&&this.quill.root.addEventListener("scroll",(function(){r.root.style.marginTop=-1*r.quill.root.scrollTop+"px"})),this.hide()}return r(e,[{key:"hide",value:function(){this.root.classList.add("ql-hidden")}},{key:"position",value:function(e){var t=e.left+e.width/2-this.root.offsetWidth/2,n=e.bottom+this.quill.root.scrollTop;this.root.style.left=t+"px",this.root.style.top=n+"px",this.root.classList.remove("ql-flip");var r=this.boundsContainer.getBoundingClientRect(),i=this.root.getBoundingClientRect(),o=0;if(i.right>r.right&&(o=r.right-i.right,this.root.style.left=t+o+"px"),i.left<r.left&&(o=r.left-i.left,this.root.style.left=t+o+"px"),i.bottom>r.bottom){var a=i.bottom-i.top,s=e.bottom-e.top+a;this.root.style.top=n-s+"px",this.root.classList.add("ql-flip")}return o}},{key:"show",value:function(){this.root.classList.remove("ql-editing"),this.root.classList.remove("ql-hidden")}}]),e}();t.default=i},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r=function(e,t){if(Array.isArray(e))return e;if(Symbol.iterator in Object(e))return function(e,t){var n=[],r=!0,i=!1,o=void 0;try{for(var a,s=e[Symbol.iterator]();!(r=(a=s.next()).done)&&(n.push(a.value),!t||n.length!==t);r=!0);}catch(l){i=!0,o=l}finally{try{!r&&s.return&&s.return()}finally{if(i)throw o}}return n}(e,t);throw new TypeError("Invalid attempt to destructure non-iterable instance")},i=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},o=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),a=d(n(3)),s=d(n(8)),l=n(43),u=d(l),c=d(n(27)),f=n(15),p=d(n(41));function d(e){return e&&e.__esModule?e:{default:e}}function h(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function g(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function m(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var v=[[{header:["1","2","3",!1]}],["bold","italic","underline","link"],[{list:"ordered"},{list:"bullet"}],["clean"]],y=function(e){function t(e,n){h(this,t),null!=n.modules.toolbar&&null==n.modules.toolbar.container&&(n.modules.toolbar.container=v);var r=g(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,n));return r.quill.container.classList.add("ql-snow"),r}return m(t,e),o(t,[{key:"extendToolbar",value:function(e){e.container.classList.add("ql-snow"),this.buildButtons([].slice.call(e.container.querySelectorAll("button")),p.default),this.buildPickers([].slice.call(e.container.querySelectorAll("select")),p.default),this.tooltip=new b(this.quill,this.options.bounds),e.container.querySelector(".ql-link")&&this.quill.keyboard.addBinding({key:"K",shortKey:!0},(function(t,n){e.handlers.link.call(e,!n.format.link)}))}}]),t}(u.default);y.DEFAULTS=(0,a.default)(!0,{},u.default.DEFAULTS,{modules:{toolbar:{handlers:{link:function(e){if(e){var t=this.quill.getSelection();if(null==t||0==t.length)return;var n=this.quill.getText(t);/^\S+@\S+\.\S+$/.test(n)&&0!==n.indexOf("mailto:")&&(n="mailto:"+n),this.quill.theme.tooltip.edit("link",n)}else this.quill.format("link",!1)}}}}});var b=function(e){function t(e,n){h(this,t);var r=g(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,n));return r.preview=r.root.querySelector("a.ql-preview"),r}return m(t,e),o(t,[{key:"listen",value:function(){var e=this;i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"listen",this).call(this),this.root.querySelector("a.ql-action").addEventListener("click",(function(t){e.root.classList.contains("ql-editing")?e.save():e.edit("link",e.preview.textContent),t.preventDefault()})),this.root.querySelector("a.ql-remove").addEventListener("click",(function(t){if(null!=e.linkRange){var n=e.linkRange;e.restoreFocus(),e.quill.formatText(n,"link",!1,s.default.sources.USER),delete e.linkRange}t.preventDefault(),e.hide()})),this.quill.on(s.default.events.SELECTION_CHANGE,(function(t,n,i){if(null!=t){if(0===t.length&&i===s.default.sources.USER){var o=e.quill.scroll.descendant(c.default,t.index),a=r(o,2),l=a[0],u=a[1];if(null!=l){e.linkRange=new f.Range(t.index-u,l.length());var p=c.default.formats(l.domNode);return e.preview.textContent=p,e.preview.setAttribute("href",p),e.show(),void e.position(e.quill.getBounds(e.linkRange))}}else delete e.linkRange;e.hide()}}))}},{key:"show",value:function(){i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"show",this).call(this),this.root.removeAttribute("data-mode")}}]),t}(l.BaseTooltip);b.TEMPLATE=['<a class="ql-preview" rel="noopener noreferrer" target="_blank" href="about:blank"></a>','<input type="text" data-formula="e=mc^2" data-link="https://quilljs.com" data-video="Embed URL">','<a class="ql-action"></a>','<a class="ql-remove"></a>'].join(""),t.default=y},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r=P(n(29)),i=n(36),o=n(38),a=n(64),s=P(n(65)),l=P(n(66)),u=n(67),c=P(u),f=n(37),p=n(26),d=n(39),h=n(40),g=P(n(56)),m=P(n(68)),v=P(n(27)),y=P(n(69)),b=P(n(70)),_=P(n(71)),w=P(n(72)),x=P(n(73)),k=n(13),C=P(k),E=P(n(74)),O=P(n(75)),A=P(n(57)),S=P(n(41)),j=P(n(28)),T=P(n(59)),D=P(n(60)),N=P(n(61)),L=P(n(108)),M=P(n(62));function P(e){return e&&e.__esModule?e:{default:e}}r.default.register({"attributors/attribute/direction":o.DirectionAttribute,"attributors/class/align":i.AlignClass,"attributors/class/background":f.BackgroundClass,"attributors/class/color":p.ColorClass,"attributors/class/direction":o.DirectionClass,"attributors/class/font":d.FontClass,"attributors/class/size":h.SizeClass,"attributors/style/align":i.AlignStyle,"attributors/style/background":f.BackgroundStyle,"attributors/style/color":p.ColorStyle,"attributors/style/direction":o.DirectionStyle,"attributors/style/font":d.FontStyle,"attributors/style/size":h.SizeStyle},!0),r.default.register({"formats/align":i.AlignClass,"formats/direction":o.DirectionClass,"formats/indent":a.IndentClass,"formats/background":f.BackgroundStyle,"formats/color":p.ColorStyle,"formats/font":d.FontClass,"formats/size":h.SizeClass,"formats/blockquote":s.default,"formats/code-block":C.default,"formats/header":l.default,"formats/list":c.default,"formats/bold":g.default,"formats/code":k.Code,"formats/italic":m.default,"formats/link":v.default,"formats/script":y.default,"formats/strike":b.default,"formats/underline":_.default,"formats/image":w.default,"formats/video":x.default,"formats/list/item":u.ListItem,"modules/formula":E.default,"modules/syntax":O.default,"modules/toolbar":A.default,"themes/bubble":L.default,"themes/snow":M.default,"ui/icons":S.default,"ui/picker":j.default,"ui/icon-picker":D.default,"ui/color-picker":T.default,"ui/tooltip":N.default},!0),t.default=r.default},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.IndentClass=void 0;var r,i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},a=n(0),s=(r=a)&&r.__esModule?r:{default:r};function l(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function u(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var c=new(function(e){function t(){return l(this,t),u(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),i(t,[{key:"add",value:function(e,n){if("+1"===n||"-1"===n){var r=this.value(e)||0;n="+1"===n?r+1:r-1}return 0===n?(this.remove(e),!0):o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"add",this).call(this,e,n)}},{key:"canAdd",value:function(e,n){return o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"canAdd",this).call(this,e,n)||o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"canAdd",this).call(this,e,parseInt(n))}},{key:"value",value:function(e){return parseInt(o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"value",this).call(this,e))||void 0}}]),t}(s.default.Attributor.Class))("indent","ql-indent",{scope:s.default.Scope.BLOCK,whitelist:[1,2,3,4,5,6,7,8]});t.IndentClass=c},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r,i=n(4);function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var s=function(e){function t(){return o(this,t),a(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),t}(((r=i)&&r.__esModule?r:{default:r}).default);s.blotName="blockquote",s.tagName="blockquote",t.default=s},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r,i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=n(4);function a(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function s(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var l=function(e){function t(){return a(this,t),s(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),i(t,null,[{key:"formats",value:function(e){return this.tagName.indexOf(e.tagName)+1}}]),t}(((r=o)&&r.__esModule?r:{default:r}).default);l.blotName="header",l.tagName=["H1","H2","H3","H4","H5","H6"],t.default=l},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.ListItem=void 0;var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),i=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},o=l(n(0)),a=l(n(4)),s=l(n(25));function l(e){return e&&e.__esModule?e:{default:e}}function u(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function c(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function f(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var p=function(e){function t(){return u(this,t),c(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return f(t,e),r(t,[{key:"format",value:function(e,n){e!==d.blotName||n?i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"format",this).call(this,e,n):this.replaceWith(o.default.create(this.statics.scope))}},{key:"remove",value:function(){null==this.prev&&null==this.next?this.parent.remove():i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"remove",this).call(this)}},{key:"replaceWith",value:function(e,n){return this.parent.isolate(this.offset(this.parent),this.length()),e===this.parent.statics.blotName?(this.parent.replaceWith(e,n),this):(this.parent.unwrap(),i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"replaceWith",this).call(this,e,n))}}],[{key:"formats",value:function(e){return e.tagName===this.tagName?void 0:i(t.__proto__||Object.getPrototypeOf(t),"formats",this).call(this,e)}}]),t}(a.default);p.blotName="list-item",p.tagName="LI";var d=function(e){function t(e){u(this,t);var n=c(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e)),r=function(t){if(t.target.parentNode===e){var r=n.statics.formats(e),i=o.default.find(t.target);"checked"===r?i.format("list","unchecked"):"unchecked"===r&&i.format("list","checked")}};return e.addEventListener("touchstart",r),e.addEventListener("mousedown",r),n}return f(t,e),r(t,null,[{key:"create",value:function(e){var n="ordered"===e?"OL":"UL",r=i(t.__proto__||Object.getPrototypeOf(t),"create",this).call(this,n);return"checked"!==e&&"unchecked"!==e||r.setAttribute("data-checked","checked"===e),r}},{key:"formats",value:function(e){return"OL"===e.tagName?"ordered":"UL"===e.tagName?e.hasAttribute("data-checked")?"true"===e.getAttribute("data-checked")?"checked":"unchecked":"bullet":void 0}}]),r(t,[{key:"format",value:function(e,t){this.children.length>0&&this.children.tail.format(e,t)}},{key:"formats",value:function(){return function(e,t,n){return t in e?Object.defineProperty(e,t,{value:n,enumerable:!0,configurable:!0,writable:!0}):e[t]=n,e}({},this.statics.blotName,this.statics.formats(this.domNode))}},{key:"insertBefore",value:function(e,n){if(e instanceof p)i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"insertBefore",this).call(this,e,n);else{var r=null==n?this.length():n.offset(this),o=this.split(r);o.parent.insertBefore(e,o)}}},{key:"optimize",value:function(e){i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"optimize",this).call(this,e);var n=this.next;null!=n&&n.prev===this&&n.statics.blotName===this.statics.blotName&&n.domNode.tagName===this.domNode.tagName&&n.domNode.getAttribute("data-checked")===this.domNode.getAttribute("data-checked")&&(n.moveChildren(this),n.remove())}},{key:"replace",value:function(e){if(e.statics.blotName!==this.statics.blotName){var n=o.default.create(this.statics.defaultChild);e.moveChildren(n),this.appendChild(n)}i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"replace",this).call(this,e)}}]),t}(s.default);d.blotName="list",d.scope=o.default.Scope.BLOCK_BLOT,d.tagName=["OL","UL"],d.defaultChild="list-item",d.allowedChildren=[p],t.ListItem=p,t.default=d},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r,i=n(56);function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var s=function(e){function t(){return o(this,t),a(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),t}(((r=i)&&r.__esModule?r:{default:r}).default);s.blotName="italic",s.tagName=["EM","I"],t.default=s},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r,i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},a=n(6);function s(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function l(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var u=function(e){function t(){return s(this,t),l(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),i(t,null,[{key:"create",value:function(e){return"super"===e?document.createElement("sup"):"sub"===e?document.createElement("sub"):o(t.__proto__||Object.getPrototypeOf(t),"create",this).call(this,e)}},{key:"formats",value:function(e){return"SUB"===e.tagName?"sub":"SUP"===e.tagName?"super":void 0}}]),t}(((r=a)&&r.__esModule?r:{default:r}).default);u.blotName="script",u.tagName=["SUB","SUP"],t.default=u},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r,i=n(6);function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var s=function(e){function t(){return o(this,t),a(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),t}(((r=i)&&r.__esModule?r:{default:r}).default);s.blotName="strike",s.tagName="S",t.default=s},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r,i=n(6);function o(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function a(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var s=function(e){function t(){return o(this,t),a(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),t}(((r=i)&&r.__esModule?r:{default:r}).default);s.blotName="underline",s.tagName="U",t.default=s},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r,i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},a=n(0),s=(r=a)&&r.__esModule?r:{default:r},l=n(27);function u(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function c(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var f=["alt","height","width"],p=function(e){function t(){return u(this,t),c(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),i(t,[{key:"format",value:function(e,n){f.indexOf(e)>-1?n?this.domNode.setAttribute(e,n):this.domNode.removeAttribute(e):o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"format",this).call(this,e,n)}}],[{key:"create",value:function(e){var n=o(t.__proto__||Object.getPrototypeOf(t),"create",this).call(this,e);return"string"==typeof e&&n.setAttribute("src",this.sanitize(e)),n}},{key:"formats",value:function(e){return f.reduce((function(t,n){return e.hasAttribute(n)&&(t[n]=e.getAttribute(n)),t}),{})}},{key:"match",value:function(e){return/\.(jpe?g|gif|png)$/.test(e)||/^data:image\/.+;base64/.test(e)}},{key:"sanitize",value:function(e){return(0,l.sanitize)(e,["http","https","data"])?e:"//:0"}},{key:"value",value:function(e){return e.getAttribute("src")}}]),t}(s.default.Embed);p.blotName="image",p.tagName="IMG",t.default=p},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0});var r,i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},a=n(4),s=n(27),l=(r=s)&&r.__esModule?r:{default:r};function u(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function c(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}var f=["height","width"],p=function(e){function t(){return u(this,t),c(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}(t,e),i(t,[{key:"format",value:function(e,n){f.indexOf(e)>-1?n?this.domNode.setAttribute(e,n):this.domNode.removeAttribute(e):o(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"format",this).call(this,e,n)}}],[{key:"create",value:function(e){var n=o(t.__proto__||Object.getPrototypeOf(t),"create",this).call(this,e);return n.setAttribute("frameborder","0"),n.setAttribute("allowfullscreen",!0),n.setAttribute("src",this.sanitize(e)),n}},{key:"formats",value:function(e){return f.reduce((function(t,n){return e.hasAttribute(n)&&(t[n]=e.getAttribute(n)),t}),{})}},{key:"sanitize",value:function(e){return l.default.sanitize(e)}},{key:"value",value:function(e){return e.getAttribute("src")}}]),t}(a.BlockEmbed);p.blotName="video",p.className="ql-video",p.tagName="IFRAME",t.default=p},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.FormulaBlot=void 0;var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),i=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},o=l(n(35)),a=l(n(5)),s=l(n(9));function l(e){return e&&e.__esModule?e:{default:e}}function u(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function c(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function f(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var p=function(e){function t(){return u(this,t),c(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return f(t,e),r(t,null,[{key:"create",value:function(e){var n=i(t.__proto__||Object.getPrototypeOf(t),"create",this).call(this,e);return"string"==typeof e&&(window.katex.render(e,n,{throwOnError:!1,errorColor:"#f00"}),n.setAttribute("data-value",e)),n}},{key:"value",value:function(e){return e.getAttribute("data-value")}}]),t}(o.default);p.blotName="formula",p.className="ql-formula",p.tagName="SPAN";var d=function(e){function t(){u(this,t);var e=c(this,(t.__proto__||Object.getPrototypeOf(t)).call(this));if(null==window.katex)throw new Error("Formula module requires KaTeX.");return e}return f(t,e),r(t,null,[{key:"register",value:function(){a.default.register(p,!0)}}]),t}(s.default);t.FormulaBlot=p,t.default=d},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.CodeToken=t.CodeBlock=void 0;var r=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),i=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},o=l(n(0)),a=l(n(5)),s=l(n(9));function l(e){return e&&e.__esModule?e:{default:e}}function u(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function c(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function f(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var p=function(e){function t(){return u(this,t),c(this,(t.__proto__||Object.getPrototypeOf(t)).apply(this,arguments))}return f(t,e),r(t,[{key:"replaceWith",value:function(e){this.domNode.textContent=this.domNode.textContent,this.attach(),i(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"replaceWith",this).call(this,e)}},{key:"highlight",value:function(e){var t=this.domNode.textContent;this.cachedText!==t&&((t.trim().length>0||null==this.cachedText)&&(this.domNode.innerHTML=e(t),this.domNode.normalize(),this.attach()),this.cachedText=t)}}]),t}(l(n(13)).default);p.className="ql-syntax";var d=new o.default.Attributor.Class("token","hljs",{scope:o.default.Scope.INLINE}),h=function(e){function t(e,n){u(this,t);var r=c(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,n));if("function"!=typeof r.options.highlight)throw new Error("Syntax module requires highlight.js. Please include the library on the page before Quill.");var i=null;return r.quill.on(a.default.events.SCROLL_OPTIMIZE,(function(){clearTimeout(i),i=setTimeout((function(){r.highlight(),i=null}),r.options.interval)})),r.highlight(),r}return f(t,e),r(t,null,[{key:"register",value:function(){a.default.register(d,!0),a.default.register(p,!0)}}]),r(t,[{key:"highlight",value:function(){var e=this;if(!this.quill.selection.composing){this.quill.update(a.default.sources.USER);var t=this.quill.getSelection();this.quill.scroll.descendants(p).forEach((function(t){t.highlight(e.options.highlight)})),this.quill.update(a.default.sources.SILENT),null!=t&&this.quill.setSelection(t,a.default.sources.SILENT)}}}]),t}(s.default);h.DEFAULTS={highlight:null==window.hljs?null:function(e){return window.hljs.highlightAuto(e).value},interval:1e3},t.CodeBlock=p,t.CodeToken=d,t.default=h},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=3 x2=13 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=9 y1=4 y2=4></line> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=14 x2=4 y1=14 y2=14></line> <line class=ql-stroke x1=12 x2=6 y1=4 y2=4></line> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=15 x2=5 y1=14 y2=14></line> <line class=ql-stroke x1=15 x2=9 y1=4 y2=4></line> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=15 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=15 x2=3 y1=14 y2=14></line> <line class=ql-stroke x1=15 x2=3 y1=4 y2=4></line> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <g class="ql-fill ql-color-label"> <polygon points="6 6.868 6 6 5 6 5 7 5.942 7 6 6.868"></polygon> <rect height=1 width=1 x=4 y=4></rect> <polygon points="6.817 5 6 5 6 6 6.38 6 6.817 5"></polygon> <rect height=1 width=1 x=2 y=6></rect> <rect height=1 width=1 x=3 y=5></rect> <rect height=1 width=1 x=4 y=7></rect> <polygon points="4 11.439 4 11 3 11 3 12 3.755 12 4 11.439"></polygon> <rect height=1 width=1 x=2 y=12></rect> <rect height=1 width=1 x=2 y=9></rect> <rect height=1 width=1 x=2 y=15></rect> <polygon points="4.63 10 4 10 4 11 4.192 11 4.63 10"></polygon> <rect height=1 width=1 x=3 y=8></rect> <path d=M10.832,4.2L11,4.582V4H10.708A1.948,1.948,0,0,1,10.832,4.2Z></path> <path d=M7,4.582L7.168,4.2A1.929,1.929,0,0,1,7.292,4H7V4.582Z></path> <path d=M8,13H7.683l-0.351.8a1.933,1.933,0,0,1-.124.2H8V13Z></path> <rect height=1 width=1 x=12 y=2></rect> <rect height=1 width=1 x=11 y=3></rect> <path d=M9,3H8V3.282A1.985,1.985,0,0,1,9,3Z></path> <rect height=1 width=1 x=2 y=3></rect> <rect height=1 width=1 x=6 y=2></rect> <rect height=1 width=1 x=3 y=2></rect> <rect height=1 width=1 x=5 y=3></rect> <rect height=1 width=1 x=9 y=2></rect> <rect height=1 width=1 x=15 y=14></rect> <polygon points="13.447 10.174 13.469 10.225 13.472 10.232 13.808 11 14 11 14 10 13.37 10 13.447 10.174"></polygon> <rect height=1 width=1 x=13 y=7></rect> <rect height=1 width=1 x=15 y=5></rect> <rect height=1 width=1 x=14 y=6></rect> <rect height=1 width=1 x=15 y=8></rect> <rect height=1 width=1 x=14 y=9></rect> <path d=M3.775,14H3v1H4V14.314A1.97,1.97,0,0,1,3.775,14Z></path> <rect height=1 width=1 x=14 y=3></rect> <polygon points="12 6.868 12 6 11.62 6 12 6.868"></polygon> <rect height=1 width=1 x=15 y=2></rect> <rect height=1 width=1 x=12 y=5></rect> <rect height=1 width=1 x=13 y=4></rect> <polygon points="12.933 9 13 9 13 8 12.495 8 12.933 9"></polygon> <rect height=1 width=1 x=9 y=14></rect> <rect height=1 width=1 x=8 y=15></rect> <path d=M6,14.926V15H7V14.316A1.993,1.993,0,0,1,6,14.926Z></path> <rect height=1 width=1 x=5 y=15></rect> <path d=M10.668,13.8L10.317,13H10v1h0.792A1.947,1.947,0,0,1,10.668,13.8Z></path> <rect height=1 width=1 x=11 y=15></rect> <path d=M14.332,12.2a1.99,1.99,0,0,1,.166.8H15V12H14.245Z></path> <rect height=1 width=1 x=14 y=15></rect> <rect height=1 width=1 x=15 y=11></rect> </g> <polyline class=ql-stroke points="5.5 13 9 5 12.5 13"></polyline> <line class=ql-stroke x1=11.63 x2=6.38 y1=11 y2=11></line> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <rect class="ql-fill ql-stroke" height=3 width=3 x=4 y=5></rect> <rect class="ql-fill ql-stroke" height=3 width=3 x=11 y=5></rect> <path class="ql-even ql-fill ql-stroke" d=M7,8c0,4.031-3,5-3,5></path> <path class="ql-even ql-fill ql-stroke" d=M14,8c0,4.031-3,5-3,5></path> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <path class=ql-stroke d=M5,4H9.5A2.5,2.5,0,0,1,12,6.5v0A2.5,2.5,0,0,1,9.5,9H5A0,0,0,0,1,5,9V4A0,0,0,0,1,5,4Z></path> <path class=ql-stroke d=M5,9h5.5A2.5,2.5,0,0,1,13,11.5v0A2.5,2.5,0,0,1,10.5,14H5a0,0,0,0,1,0,0V9A0,0,0,0,1,5,9Z></path> </svg>'},function(e,t){e.exports='<svg class="" viewbox="0 0 18 18"> <line class=ql-stroke x1=5 x2=13 y1=3 y2=3></line> <line class=ql-stroke x1=6 x2=9.35 y1=12 y2=3></line> <line class=ql-stroke x1=11 x2=15 y1=11 y2=15></line> <line class=ql-stroke x1=15 x2=11 y1=11 y2=15></line> <rect class=ql-fill height=1 rx=0.5 ry=0.5 width=7 x=2 y=14></rect> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <line class="ql-color-label ql-stroke ql-transparent" x1=3 x2=15 y1=15 y2=15></line> <polyline class=ql-stroke points="5.5 11 9 3 12.5 11"></polyline> <line class=ql-stroke x1=11.63 x2=6.38 y1=9 y2=9></line> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <polygon class="ql-stroke ql-fill" points="3 11 5 9 3 7 3 11"></polygon> <line class="ql-stroke ql-fill" x1=15 x2=11 y1=4 y2=4></line> <path class=ql-fill d=M11,3a3,3,0,0,0,0,6h1V3H11Z></path> <rect class=ql-fill height=11 width=1 x=11 y=4></rect> <rect class=ql-fill height=11 width=1 x=13 y=4></rect> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <polygon class="ql-stroke ql-fill" points="15 12 13 10 15 8 15 12"></polygon> <line class="ql-stroke ql-fill" x1=9 x2=5 y1=4 y2=4></line> <path class=ql-fill d=M5,3A3,3,0,0,0,5,9H6V3H5Z></path> <rect class=ql-fill height=11 width=1 x=5 y=4></rect> <rect class=ql-fill height=11 width=1 x=7 y=4></rect> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M14,16H4a1,1,0,0,1,0-2H14A1,1,0,0,1,14,16Z /> <path class=ql-fill d=M14,4H4A1,1,0,0,1,4,2H14A1,1,0,0,1,14,4Z /> <rect class=ql-fill x=3 y=6 width=12 height=6 rx=1 ry=1 /> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M13,16H5a1,1,0,0,1,0-2h8A1,1,0,0,1,13,16Z /> <path class=ql-fill d=M13,4H5A1,1,0,0,1,5,2h8A1,1,0,0,1,13,4Z /> <rect class=ql-fill x=2 y=6 width=14 height=6 rx=1 ry=1 /> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15,8H13a1,1,0,0,1,0-2h2A1,1,0,0,1,15,8Z /> <path class=ql-fill d=M15,12H13a1,1,0,0,1,0-2h2A1,1,0,0,1,15,12Z /> <path class=ql-fill d=M15,16H5a1,1,0,0,1,0-2H15A1,1,0,0,1,15,16Z /> <path class=ql-fill d=M15,4H5A1,1,0,0,1,5,2H15A1,1,0,0,1,15,4Z /> <rect class=ql-fill x=2 y=6 width=8 height=6 rx=1 ry=1 /> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M5,8H3A1,1,0,0,1,3,6H5A1,1,0,0,1,5,8Z /> <path class=ql-fill d=M5,12H3a1,1,0,0,1,0-2H5A1,1,0,0,1,5,12Z /> <path class=ql-fill d=M13,16H3a1,1,0,0,1,0-2H13A1,1,0,0,1,13,16Z /> <path class=ql-fill d=M13,4H3A1,1,0,0,1,3,2H13A1,1,0,0,1,13,4Z /> <rect class=ql-fill x=8 y=6 width=8 height=6 rx=1 ry=1 transform="translate(24 18) rotate(-180)"/> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M11.759,2.482a2.561,2.561,0,0,0-3.53.607A7.656,7.656,0,0,0,6.8,6.2C6.109,9.188,5.275,14.677,4.15,14.927a1.545,1.545,0,0,0-1.3-.933A0.922,0.922,0,0,0,2,15.036S1.954,16,4.119,16s3.091-2.691,3.7-5.553c0.177-.826.36-1.726,0.554-2.6L8.775,6.2c0.381-1.421.807-2.521,1.306-2.676a1.014,1.014,0,0,0,1.02.56A0.966,0.966,0,0,0,11.759,2.482Z></path> <rect class=ql-fill height=1.6 rx=0.8 ry=0.8 width=5 x=5.15 y=6.2></rect> <path class=ql-fill d=M13.663,12.027a1.662,1.662,0,0,1,.266-0.276q0.193,0.069.456,0.138a2.1,2.1,0,0,0,.535.069,1.075,1.075,0,0,0,.767-0.3,1.044,1.044,0,0,0,.314-0.8,0.84,0.84,0,0,0-.238-0.619,0.8,0.8,0,0,0-.594-0.239,1.154,1.154,0,0,0-.781.3,4.607,4.607,0,0,0-.781,1q-0.091.15-.218,0.346l-0.246.38c-0.068-.288-0.137-0.582-0.212-0.885-0.459-1.847-2.494-.984-2.941-0.8-0.482.2-.353,0.647-0.094,0.529a0.869,0.869,0,0,1,1.281.585c0.217,0.751.377,1.436,0.527,2.038a5.688,5.688,0,0,1-.362.467,2.69,2.69,0,0,1-.264.271q-0.221-.08-0.471-0.147a2.029,2.029,0,0,0-.522-0.066,1.079,1.079,0,0,0-.768.3A1.058,1.058,0,0,0,9,15.131a0.82,0.82,0,0,0,.832.852,1.134,1.134,0,0,0,.787-0.3,5.11,5.11,0,0,0,.776-0.993q0.141-.219.215-0.34c0.046-.076.122-0.194,0.223-0.346a2.786,2.786,0,0,0,.918,1.726,2.582,2.582,0,0,0,2.376-.185c0.317-.181.212-0.565,0-0.494A0.807,0.807,0,0,1,14.176,15a5.159,5.159,0,0,1-.913-2.446l0,0Q13.487,12.24,13.663,12.027Z></path> </svg>'},function(e,t){e.exports='<svg viewBox="0 0 18 18"> <path class=ql-fill d=M10,4V14a1,1,0,0,1-2,0V10H3v4a1,1,0,0,1-2,0V4A1,1,0,0,1,3,4V8H8V4a1,1,0,0,1,2,0Zm6.06787,9.209H14.98975V7.59863a.54085.54085,0,0,0-.605-.60547h-.62744a1.01119,1.01119,0,0,0-.748.29688L11.645,8.56641a.5435.5435,0,0,0-.022.8584l.28613.30762a.53861.53861,0,0,0,.84717.0332l.09912-.08789a1.2137,1.2137,0,0,0,.2417-.35254h.02246s-.01123.30859-.01123.60547V13.209H12.041a.54085.54085,0,0,0-.605.60547v.43945a.54085.54085,0,0,0,.605.60547h4.02686a.54085.54085,0,0,0,.605-.60547v-.43945A.54085.54085,0,0,0,16.06787,13.209Z /> </svg>'},function(e,t){e.exports='<svg viewBox="0 0 18 18"> <path class=ql-fill d=M16.73975,13.81445v.43945a.54085.54085,0,0,1-.605.60547H11.855a.58392.58392,0,0,1-.64893-.60547V14.0127c0-2.90527,3.39941-3.42187,3.39941-4.55469a.77675.77675,0,0,0-.84717-.78125,1.17684,1.17684,0,0,0-.83594.38477c-.2749.26367-.561.374-.85791.13184l-.4292-.34082c-.30811-.24219-.38525-.51758-.1543-.81445a2.97155,2.97155,0,0,1,2.45361-1.17676,2.45393,2.45393,0,0,1,2.68408,2.40918c0,2.45312-3.1792,2.92676-3.27832,3.93848h2.79443A.54085.54085,0,0,1,16.73975,13.81445ZM9,3A.99974.99974,0,0,0,8,4V8H3V4A1,1,0,0,0,1,4V14a1,1,0,0,0,2,0V10H8v4a1,1,0,0,0,2,0V4A.99974.99974,0,0,0,9,3Z /> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=13 y1=4 y2=4></line> <line class=ql-stroke x1=5 x2=11 y1=14 y2=14></line> <line class=ql-stroke x1=8 x2=10 y1=14 y2=4></line> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <rect class=ql-stroke height=10 width=12 x=3 y=4></rect> <circle class=ql-fill cx=6 cy=7 r=1></circle> <polyline class="ql-even ql-fill" points="5 12 5 11 7 9 8 10 11 7 13 9 13 12 5 12"></polyline> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class="ql-fill ql-stroke" points="3 7 3 11 5 9 3 7"></polyline> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=3 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class=ql-stroke points="5 7 5 11 3 9 5 7"></polyline> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=11 y1=7 y2=11></line> <path class="ql-even ql-stroke" d=M8.9,4.577a3.476,3.476,0,0,1,.36,4.679A3.476,3.476,0,0,1,4.577,8.9C3.185,7.5,2.035,6.4,4.217,4.217S7.5,3.185,8.9,4.577Z></path> <path class="ql-even ql-stroke" d=M13.423,9.1a3.476,3.476,0,0,0-4.679-.36,3.476,3.476,0,0,0,.36,4.679c1.392,1.392,2.5,2.542,4.679.36S14.815,10.5,13.423,9.1Z></path> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=7 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=7 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=7 x2=15 y1=14 y2=14></line> <line class="ql-stroke ql-thin" x1=2.5 x2=4.5 y1=5.5 y2=5.5></line> <path class=ql-fill d=M3.5,6A0.5,0.5,0,0,1,3,5.5V3.085l-0.276.138A0.5,0.5,0,0,1,2.053,3c-0.124-.247-0.023-0.324.224-0.447l1-.5A0.5,0.5,0,0,1,4,2.5v3A0.5,0.5,0,0,1,3.5,6Z></path> <path class="ql-stroke ql-thin" d=M4.5,10.5h-2c0-.234,1.85-1.076,1.85-2.234A0.959,0.959,0,0,0,2.5,8.156></path> <path class="ql-stroke ql-thin" d=M2.5,14.846a0.959,0.959,0,0,0,1.85-.109A0.7,0.7,0,0,0,3.75,14a0.688,0.688,0,0,0,.6-0.736,0.959,0.959,0,0,0-1.85-.109></path> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <line class=ql-stroke x1=6 x2=15 y1=4 y2=4></line> <line class=ql-stroke x1=6 x2=15 y1=9 y2=9></line> <line class=ql-stroke x1=6 x2=15 y1=14 y2=14></line> <line class=ql-stroke x1=3 x2=3 y1=4 y2=4></line> <line class=ql-stroke x1=3 x2=3 y1=9 y2=9></line> <line class=ql-stroke x1=3 x2=3 y1=14 y2=14></line> </svg>'},function(e,t){e.exports='<svg class="" viewbox="0 0 18 18"> <line class=ql-stroke x1=9 x2=15 y1=4 y2=4></line> <polyline class=ql-stroke points="3 4 4 5 6 3"></polyline> <line class=ql-stroke x1=9 x2=15 y1=14 y2=14></line> <polyline class=ql-stroke points="3 14 4 15 6 13"></polyline> <line class=ql-stroke x1=9 x2=15 y1=9 y2=9></line> <polyline class=ql-stroke points="3 9 4 10 6 8"></polyline> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15.5,15H13.861a3.858,3.858,0,0,0,1.914-2.975,1.8,1.8,0,0,0-1.6-1.751A1.921,1.921,0,0,0,12.021,11.7a0.50013,0.50013,0,1,0,.957.291h0a0.914,0.914,0,0,1,1.053-.725,0.81,0.81,0,0,1,.744.762c0,1.076-1.16971,1.86982-1.93971,2.43082A1.45639,1.45639,0,0,0,12,15.5a0.5,0.5,0,0,0,.5.5h3A0.5,0.5,0,0,0,15.5,15Z /> <path class=ql-fill d=M9.65,5.241a1,1,0,0,0-1.409.108L6,7.964,3.759,5.349A1,1,0,0,0,2.192,6.59178Q2.21541,6.6213,2.241,6.649L4.684,9.5,2.241,12.35A1,1,0,0,0,3.71,13.70722q0.02557-.02768.049-0.05722L6,11.036,8.241,13.65a1,1,0,1,0,1.567-1.24277Q9.78459,12.3777,9.759,12.35L7.316,9.5,9.759,6.651A1,1,0,0,0,9.65,5.241Z /> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <path class=ql-fill d=M15.5,7H13.861a4.015,4.015,0,0,0,1.914-2.975,1.8,1.8,0,0,0-1.6-1.751A1.922,1.922,0,0,0,12.021,3.7a0.5,0.5,0,1,0,.957.291,0.917,0.917,0,0,1,1.053-.725,0.81,0.81,0,0,1,.744.762c0,1.077-1.164,1.925-1.934,2.486A1.423,1.423,0,0,0,12,7.5a0.5,0.5,0,0,0,.5.5h3A0.5,0.5,0,0,0,15.5,7Z /> <path class=ql-fill d=M9.651,5.241a1,1,0,0,0-1.41.108L6,7.964,3.759,5.349a1,1,0,1,0-1.519,1.3L4.683,9.5,2.241,12.35a1,1,0,1,0,1.519,1.3L6,11.036,8.241,13.65a1,1,0,0,0,1.519-1.3L7.317,9.5,9.759,6.651A1,1,0,0,0,9.651,5.241Z /> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <line class="ql-stroke ql-thin" x1=15.5 x2=2.5 y1=8.5 y2=9.5></line> <path class=ql-fill d=M9.007,8C6.542,7.791,6,7.519,6,6.5,6,5.792,7.283,5,9,5c1.571,0,2.765.679,2.969,1.309a1,1,0,0,0,1.9-.617C13.356,4.106,11.354,3,9,3,6.2,3,4,4.538,4,6.5a3.2,3.2,0,0,0,.5,1.843Z></path> <path class=ql-fill d=M8.984,10C11.457,10.208,12,10.479,12,11.5c0,0.708-1.283,1.5-3,1.5-1.571,0-2.765-.679-2.969-1.309a1,1,0,1,0-1.9.617C4.644,13.894,6.646,15,9,15c2.8,0,5-1.538,5-3.5a3.2,3.2,0,0,0-.5-1.843Z></path> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <path class=ql-stroke d=M5,3V9a4.012,4.012,0,0,0,4,4H9a4.012,4.012,0,0,0,4-4V3></path> <rect class=ql-fill height=1 rx=0.5 ry=0.5 width=12 x=3 y=15></rect> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <rect class=ql-stroke height=12 width=12 x=3 y=3></rect> <rect class=ql-fill height=12 width=1 x=5 y=3></rect> <rect class=ql-fill height=12 width=1 x=12 y=3></rect> <rect class=ql-fill height=2 width=8 x=5 y=8></rect> <rect class=ql-fill height=1 width=3 x=3 y=5></rect> <rect class=ql-fill height=1 width=3 x=3 y=7></rect> <rect class=ql-fill height=1 width=3 x=3 y=10></rect> <rect class=ql-fill height=1 width=3 x=3 y=12></rect> <rect class=ql-fill height=1 width=3 x=12 y=5></rect> <rect class=ql-fill height=1 width=3 x=12 y=7></rect> <rect class=ql-fill height=1 width=3 x=12 y=10></rect> <rect class=ql-fill height=1 width=3 x=12 y=12></rect> </svg>'},function(e,t){e.exports='<svg viewbox="0 0 18 18"> <polygon class=ql-stroke points="7 11 9 13 11 11 7 11"></polygon> <polygon class=ql-stroke points="7 7 9 5 11 7 7 7"></polygon> </svg>'},function(e,t,n){Object.defineProperty(t,"__esModule",{value:!0}),t.default=t.BubbleTooltip=void 0;var r=function e(t,n,r){null===t&&(t=Function.prototype);var i=Object.getOwnPropertyDescriptor(t,n);if(void 0===i){var o=Object.getPrototypeOf(t);return null===o?void 0:e(o,n,r)}if("value"in i)return i.value;var a=i.get;return void 0!==a?a.call(r):void 0},i=function(){function e(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}return function(t,n,r){return n&&e(t.prototype,n),r&&e(t,r),t}}(),o=f(n(3)),a=f(n(8)),s=n(43),l=f(s),u=n(15),c=f(n(41));function f(e){return e&&e.__esModule?e:{default:e}}function p(e,t){if(!(e instanceof t))throw new TypeError("Cannot call a class as a function")}function d(e,t){if(!e)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!t||"object"!=typeof t&&"function"!=typeof t?e:t}function h(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Super expression must either be null or a function, not "+typeof t);e.prototype=Object.create(t&&t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),t&&(Object.setPrototypeOf?Object.setPrototypeOf(e,t):e.__proto__=t)}var g=[["bold","italic","link"],[{header:1},{header:2},"blockquote"]],m=function(e){function t(e,n){p(this,t),null!=n.modules.toolbar&&null==n.modules.toolbar.container&&(n.modules.toolbar.container=g);var r=d(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,n));return r.quill.container.classList.add("ql-bubble"),r}return h(t,e),i(t,[{key:"extendToolbar",value:function(e){this.tooltip=new v(this.quill,this.options.bounds),this.tooltip.root.appendChild(e.container),this.buildButtons([].slice.call(e.container.querySelectorAll("button")),c.default),this.buildPickers([].slice.call(e.container.querySelectorAll("select")),c.default)}}]),t}(l.default);m.DEFAULTS=(0,o.default)(!0,{},l.default.DEFAULTS,{modules:{toolbar:{handlers:{link:function(e){e?this.quill.theme.tooltip.edit():this.quill.format("link",!1)}}}}});var v=function(e){function t(e,n){p(this,t);var r=d(this,(t.__proto__||Object.getPrototypeOf(t)).call(this,e,n));return r.quill.on(a.default.events.EDITOR_CHANGE,(function(e,t,n,i){if(e===a.default.events.SELECTION_CHANGE)if(null!=t&&t.length>0&&i===a.default.sources.USER){r.show(),r.root.style.left="0px",r.root.style.width="",r.root.style.width=r.root.offsetWidth+"px";var o=r.quill.getLines(t.index,t.length);if(1===o.length)r.position(r.quill.getBounds(t));else{var s=o[o.length-1],l=r.quill.getIndex(s),c=Math.min(s.length()-1,t.index+t.length-l),f=r.quill.getBounds(new u.Range(l,c));r.position(f)}}else document.activeElement!==r.textbox&&r.quill.hasFocus()&&r.hide()})),r}return h(t,e),i(t,[{key:"listen",value:function(){var e=this;r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"listen",this).call(this),this.root.querySelector(".ql-close").addEventListener("click",(function(){e.root.classList.remove("ql-editing")})),this.quill.on(a.default.events.SCROLL_OPTIMIZE,(function(){setTimeout((function(){if(!e.root.classList.contains("ql-hidden")){var t=e.quill.getSelection();null!=t&&e.position(e.quill.getBounds(t))}}),1)}))}},{key:"cancel",value:function(){this.show()}},{key:"position",value:function(e){var n=r(t.prototype.__proto__||Object.getPrototypeOf(t.prototype),"position",this).call(this,e),i=this.root.querySelector(".ql-tooltip-arrow");if(i.style.marginLeft="",0===n)return n;i.style.marginLeft=-1*n-i.offsetWidth/2+"px"}}]),t}(s.BaseTooltip);v.TEMPLATE=['<span class="ql-tooltip-arrow"></span>','<div class="ql-tooltip-editor">','<input type="text" data-formula="e=mc^2" data-link="https://quilljs.com" data-video="Embed URL">','<a class="ql-close"></a>',"</div>"].join(""),t.BubbleTooltip=v,t.default=m},function(e,t,n){e.exports=n(63)}]).default},e.exports=n()})),Mo=Wn(Lo),Po=Object.freeze(Object.assign(Object.create(null),Lo,{[Symbol.toStringTag]:"Module",default:Mo}));var Fo={Aacute:"Á",aacute:"á",Abreve:"Ă",abreve:"ă",ac:"∾",acd:"∿",acE:"∾̳",Acirc:"Â",acirc:"â",acute:"´",Acy:"А",acy:"а",AElig:"Æ",aelig:"æ",af:"",Afr:"𝔄",afr:"𝔞",Agrave:"À",agrave:"à",alefsym:"ℵ",aleph:"ℵ",Alpha:"Α",alpha:"α",Amacr:"Ā",amacr:"ā",amalg:"⨿",amp:"&",AMP:"&",andand:"⩕",And:"⩓",and:"∧",andd:"⩜",andslope:"⩘",andv:"⩚",ang:"∠",ange:"⦤",angle:"∠",angmsdaa:"⦨",angmsdab:"⦩",angmsdac:"⦪",angmsdad:"⦫",angmsdae:"⦬",angmsdaf:"⦭",angmsdag:"⦮",angmsdah:"⦯",angmsd:"∡",angrt:"∟",angrtvb:"⊾",angrtvbd:"⦝",angsph:"∢",angst:"Å",angzarr:"⍼",Aogon:"Ą",aogon:"ą",Aopf:"𝔸",aopf:"𝕒",apacir:"⩯",ap:"≈",apE:"⩰",ape:"≊",apid:"≋",apos:"'",ApplyFunction:"",approx:"≈",approxeq:"≊",Aring:"Å",aring:"å",Ascr:"𝒜",ascr:"𝒶",Assign:"≔",ast:"*",asymp:"≈",asympeq:"≍",Atilde:"Ã",atilde:"ã",Auml:"Ä",auml:"ä",awconint:"∳",awint:"⨑",backcong:"≌",backepsilon:"϶",backprime:"",backsim:"∽",backsimeq:"⋍",Backslash:"",Barv:"⫧",barvee:"⊽",barwed:"⌅",Barwed:"⌆",barwedge:"⌅",bbrk:"⎵",bbrktbrk:"⎶",bcong:"≌",Bcy:"Б",bcy:"б",bdquo:"„",becaus:"∵",because:"∵",Because:"∵",bemptyv:"⦰",bepsi:"϶",bernou:"",Bernoullis:"",Beta:"Β",beta:"β",beth:"ℶ",between:"≬",Bfr:"𝔅",bfr:"𝔟",bigcap:"⋂",bigcirc:"◯",bigcup:"",bigodot:"⨀",bigoplus:"⨁",bigotimes:"⨂",bigsqcup:"⨆",bigstar:"★",bigtriangledown:"▽",bigtriangleup:"△",biguplus:"⨄",bigvee:"",bigwedge:"⋀",bkarow:"⤍",blacklozenge:"⧫",blacksquare:"▪",blacktriangle:"▴",blacktriangledown:"▾",blacktriangleleft:"◂",blacktriangleright:"▸",blank:"␣",blk12:"▒",blk14:"░",blk34:"▓",block:"█",bne:"=⃥",bnequiv:"≡⃥",bNot:"⫭",bnot:"⌐",Bopf:"𝔹",bopf:"𝕓",bot:"⊥",bottom:"⊥",bowtie:"⋈",boxbox:"⧉",boxdl:"┐",boxdL:"╕",boxDl:"╖",boxDL:"╗",boxdr:"┌",boxdR:"╒",boxDr:"╓",boxDR:"╔",boxh:"─",boxH:"═",boxhd:"┬",boxHd:"╤",boxhD:"╥",boxHD:"╦",boxhu:"┴",boxHu:"╧",boxhU:"╨",boxHU:"╩",boxminus:"⊟",boxplus:"⊞",boxtimes:"⊠",boxul:"┘",boxuL:"╛",boxUl:"╜",boxUL:"╝",boxur:"└",boxuR:"╘",boxUr:"╙",boxUR:"╚",boxv:"│",boxV:"║",boxvh:"┼",boxvH:"╪",boxVh:"╫",boxVH:"╬",boxvl:"┤",boxvL:"╡",boxVl:"╢",boxVL:"╣",boxvr:"├",boxvR:"╞",boxVr:"╟",boxVR:"╠",bprime:"",breve:"˘",Breve:"˘",brvbar:"¦",bscr:"𝒷",Bscr:"",bsemi:"⁏",bsim:"∽",bsime:"⋍",bsolb:"⧅",bsol:"\\",bsolhsub:"⟈",bull:"•",bullet:"•",bump:"≎",bumpE:"⪮",bumpe:"≏",Bumpeq:"≎",bumpeq:"≏",Cacute:"Ć",cacute:"ć",capand:"⩄",capbrcup:"⩉",capcap:"⩋",cap:"∩",Cap:"⋒",capcup:"⩇",capdot:"⩀",CapitalDifferentialD:"",caps:"∩︀",caret:"",caron:"ˇ",Cayleys:"",ccaps:"⩍",Ccaron:"Č",ccaron:"č",Ccedil:"Ç",ccedil:"ç",Ccirc:"Ĉ",ccirc:"ĉ",Cconint:"∰",ccups:"⩌",ccupssm:"⩐",Cdot:"Ċ",cdot:"ċ",cedil:"¸",Cedilla:"¸",cemptyv:"⦲",cent:"¢",centerdot:"·",CenterDot:"·",cfr:"𝔠",Cfr:"",CHcy:"Ч",chcy:"ч",check:"✓",checkmark:"✓",Chi:"Χ",chi:"χ",circ:"ˆ",circeq:"≗",circlearrowleft:"↺",circlearrowright:"↻",circledast:"⊛",circledcirc:"⊚",circleddash:"⊝",CircleDot:"⊙",circledR:"®",circledS:"Ⓢ",CircleMinus:"⊖",CirclePlus:"⊕",CircleTimes:"⊗",cir:"○",cirE:"⧃",cire:"≗",cirfnint:"⨐",cirmid:"⫯",cirscir:"⧂",ClockwiseContourIntegral:"∲",CloseCurlyDoubleQuote:"”",CloseCurlyQuote:"",clubs:"♣",clubsuit:"♣",colon:":",Colon:"∷",Colone:"⩴",colone:"≔",coloneq:"≔",comma:",",commat:"@",comp:"∁",compfn:"∘",complement:"∁",complexes:"",cong:"≅",congdot:"⩭",Congruent:"≡",conint:"∮",Conint:"∯",ContourIntegral:"∮",copf:"𝕔",Copf:"",coprod:"∐",Coproduct:"∐",copy:"©",COPY:"©",copysr:"℗",CounterClockwiseContourIntegral:"∳",crarr:"↵",cross:"✗",Cross:"",Cscr:"𝒞",cscr:"𝒸",csub:"⫏",csube:"⫑",csup:"⫐",csupe:"⫒",ctdot:"⋯",cudarrl:"⤸",cudarrr:"⤵",cuepr:"⋞",cuesc:"⋟",cularr:"↶",cularrp:"⤽",cupbrcap:"⩈",cupcap:"⩆",CupCap:"≍",cup:"",Cup:"⋓",cupcup:"⩊",cupdot:"⊍",cupor:"⩅",cups:"",curarr:"↷",curarrm:"⤼",curlyeqprec:"⋞",curlyeqsucc:"⋟",curlyvee:"⋎",curlywedge:"⋏",curren:"¤",curvearrowleft:"↶",curvearrowright:"↷",cuvee:"⋎",cuwed:"⋏",cwconint:"∲",cwint:"∱",cylcty:"⌭",dagger:"†",Dagger:"‡",daleth:"ℸ",darr:"↓",Darr:"↡",dArr:"⇓",dash:"",Dashv:"⫤",dashv:"⊣",dbkarow:"⤏",dblac:"˝",Dcaron:"Ď",dcaron:"ď",Dcy:"Д",dcy:"д",ddagger:"‡",ddarr:"⇊",DD:"",dd:"",DDotrahd:"⤑",ddotseq:"⩷",deg:"°",Del:"∇",Delta:"Δ",delta:"δ",demptyv:"⦱",dfisht:"⥿",Dfr:"𝔇",dfr:"𝔡",dHar:"⥥",dharl:"⇃",dharr:"⇂",DiacriticalAcute:"´",DiacriticalDot:"˙",DiacriticalDoubleAcute:"˝",DiacriticalGrave:"`",DiacriticalTilde:"˜",diam:"⋄",diamond:"⋄",Diamond:"⋄",diamondsuit:"♦",diams:"♦",die:"¨",DifferentialD:"",digamma:"ϝ",disin:"⋲",div:"÷",divide:"÷",divideontimes:"⋇",divonx:"⋇",DJcy:"Ђ",djcy:"ђ",dlcorn:"⌞",dlcrop:"⌍",dollar:"$",Dopf:"𝔻",dopf:"𝕕",Dot:"¨",dot:"˙",DotDot:"⃜",doteq:"≐",doteqdot:"≑",DotEqual:"≐",dotminus:"∸",dotplus:"∔",dotsquare:"⊡",doublebarwedge:"⌆",DoubleContourIntegral:"∯",DoubleDot:"¨",DoubleDownArrow:"⇓",DoubleLeftArrow:"⇐",DoubleLeftRightArrow:"⇔",DoubleLeftTee:"⫤",DoubleLongLeftArrow:"⟸",DoubleLongLeftRightArrow:"⟺",DoubleLongRightArrow:"⟹",DoubleRightArrow:"⇒",DoubleRightTee:"⊨",DoubleUpArrow:"⇑",DoubleUpDownArrow:"⇕",DoubleVerticalBar:"∥",DownArrowBar:"⤓",downarrow:"↓",DownArrow:"↓",Downarrow:"⇓",DownArrowUpArrow:"⇵",DownBreve:"̑",downdownarrows:"⇊",downharpoonleft:"⇃",downharpoonright:"⇂",DownLeftRightVector:"⥐",DownLeftTeeVector:"⥞",DownLeftVectorBar:"⥖",DownLeftVector:"↽",DownRightTeeVector:"⥟",DownRightVectorBar:"⥗",DownRightVector:"⇁",DownTeeArrow:"↧",DownTee:"",drbkarow:"⤐",drcorn:"⌟",drcrop:"⌌",Dscr:"𝒟",dscr:"𝒹",DScy:"Ѕ",dscy:"ѕ",dsol:"⧶",Dstrok:"Đ",dstrok:"đ",dtdot:"⋱",dtri:"▿",dtrif:"▾",duarr:"⇵",duhar:"⥯",dwangle:"⦦",DZcy:"Џ",dzcy:"џ",dzigrarr:"⟿",Eacute:"É",eacute:"é",easter:"⩮",Ecaron:"Ě",ecaron:"ě",Ecirc:"Ê",ecirc:"ê",ecir:"≖",ecolon:"≕",Ecy:"Э",ecy:"э",eDDot:"⩷",Edot:"Ė",edot:"ė",eDot:"≑",ee:"",efDot:"≒",Efr:"𝔈",efr:"𝔢",eg:"⪚",Egrave:"È",egrave:"è",egs:"⪖",egsdot:"⪘",el:"⪙",Element:"∈",elinters:"⏧",ell:"",els:"⪕",elsdot:"⪗",Emacr:"Ē",emacr:"ē",empty:"∅",emptyset:"∅",EmptySmallSquare:"◻",emptyv:"∅",EmptyVerySmallSquare:"▫",emsp13:"",emsp14:"",emsp:"",ENG:"Ŋ",eng:"ŋ",ensp:"",Eogon:"Ę",eogon:"ę",Eopf:"𝔼",eopf:"𝕖",epar:"⋕",eparsl:"⧣",eplus:"⩱",epsi:"ε",Epsilon:"Ε",epsilon:"ε",epsiv:"ϵ",eqcirc:"≖",eqcolon:"≕",eqsim:"≂",eqslantgtr:"⪖",eqslantless:"⪕",Equal:"⩵",equals:"=",EqualTilde:"≂",equest:"≟",Equilibrium:"⇌",equiv:"≡",equivDD:"⩸",eqvparsl:"⧥",erarr:"⥱",erDot:"≓",escr:"",Escr:"",esdot:"≐",Esim:"⩳",esim:"≂",Eta:"Η",eta:"η",ETH:"Ð",eth:"ð",Euml:"Ë",euml:"ë",euro:"€",excl:"!",exist:"∃",Exists:"∃",expectation:"",exponentiale:"",ExponentialE:"",fallingdotseq:"≒",Fcy:"Ф",fcy:"ф",female:"♀",ffilig:"ffi",fflig:"ff",ffllig:"ffl",Ffr:"𝔉",ffr:"𝔣",filig:"fi",FilledSmallSquare:"◼",FilledVerySmallSquare:"▪",fjlig:"fj",flat:"♭",fllig:"fl",fltns:"▱",fnof:"ƒ",Fopf:"𝔽",fopf:"𝕗",forall:"∀",ForAll:"∀",fork:"⋔",forkv:"⫙",Fouriertrf:"",fpartint:"⨍",frac12:"½",frac13:"⅓",frac14:"¼",frac15:"⅕",frac16:"⅙",frac18:"⅛",frac23:"⅔",frac25:"⅖",frac34:"¾",frac35:"⅗",frac38:"⅜",frac45:"⅘",frac56:"⅚",frac58:"⅝",frac78:"⅞",frasl:"",frown:"⌢",fscr:"𝒻",Fscr:"",gacute:"ǵ",Gamma:"Γ",gamma:"γ",Gammad:"Ϝ",gammad:"ϝ",gap:"⪆",Gbreve:"Ğ",gbreve:"ğ",Gcedil:"Ģ",Gcirc:"Ĝ",gcirc:"ĝ",Gcy:"Г",gcy:"г",Gdot:"Ġ",gdot:"ġ",ge:"≥",gE:"≧",gEl:"⪌",gel:"⋛",geq:"≥",geqq:"≧",geqslant:"⩾",gescc:"⪩",ges:"⩾",gesdot:"⪀",gesdoto:"⪂",gesdotol:"⪄",gesl:"⋛︀",gesles:"⪔",Gfr:"𝔊",gfr:"𝔤",gg:"≫",Gg:"⋙",ggg:"⋙",gimel:"ℷ",GJcy:"Ѓ",gjcy:"ѓ",gla:"⪥",gl:"≷",glE:"⪒",glj:"⪤",gnap:"⪊",gnapprox:"⪊",gne:"⪈",gnE:"≩",gneq:"⪈",gneqq:"≩",gnsim:"⋧",Gopf:"𝔾",gopf:"𝕘",grave:"`",GreaterEqual:"≥",GreaterEqualLess:"⋛",GreaterFullEqual:"≧",GreaterGreater:"⪢",GreaterLess:"≷",GreaterSlantEqual:"⩾",GreaterTilde:"≳",Gscr:"𝒢",gscr:"",gsim:"≳",gsime:"⪎",gsiml:"⪐",gtcc:"⪧",gtcir:"⩺",gt:">",GT:">",Gt:"≫",gtdot:"⋗",gtlPar:"⦕",gtquest:"⩼",gtrapprox:"⪆",gtrarr:"⥸",gtrdot:"⋗",gtreqless:"⋛",gtreqqless:"⪌",gtrless:"≷",gtrsim:"≳",gvertneqq:"≩︀",gvnE:"≩︀",Hacek:"ˇ",hairsp:"",half:"½",hamilt:"",HARDcy:"Ъ",hardcy:"ъ",harrcir:"⥈",harr:"↔",hArr:"⇔",harrw:"↭",Hat:"^",hbar:"ℏ",Hcirc:"Ĥ",hcirc:"ĥ",hearts:"♥",heartsuit:"♥",hellip:"…",hercon:"⊹",hfr:"𝔥",Hfr:"",HilbertSpace:"",hksearow:"⤥",hkswarow:"⤦",hoarr:"⇿",homtht:"∻",hookleftarrow:"↩",hookrightarrow:"↪",hopf:"𝕙",Hopf:"",horbar:"―",HorizontalLine:"─",hscr:"𝒽",Hscr:"",hslash:"ℏ",Hstrok:"Ħ",hstrok:"ħ",HumpDownHump:"≎",HumpEqual:"≏",hybull:"",hyphen:"",Iacute:"Í",iacute:"í",ic:"",Icirc:"Î",icirc:"î",Icy:"И",icy:"и",Idot:"İ",IEcy:"Е",iecy:"е",iexcl:"¡",iff:"⇔",ifr:"𝔦",Ifr:"",Igrave:"Ì",igrave:"ì",ii:"",iiiint:"⨌",iiint:"∭",iinfin:"⧜",iiota:"℩",IJlig:"IJ",ijlig:"ij",Imacr:"Ī",imacr:"ī",image:"",ImaginaryI:"",imagline:"",imagpart:"",imath:"ı",Im:"",imof:"⊷",imped:"Ƶ",Implies:"⇒",incare:"℅",in:"∈",infin:"∞",infintie:"⧝",inodot:"ı",intcal:"⊺",int:"∫",Int:"∬",integers:"",Integral:"∫",intercal:"⊺",Intersection:"⋂",intlarhk:"⨗",intprod:"⨼",InvisibleComma:"",InvisibleTimes:"",IOcy:"Ё",iocy:"ё",Iogon:"Į",iogon:"į",Iopf:"𝕀",iopf:"𝕚",Iota:"Ι",iota:"ι",iprod:"⨼",iquest:"¿",iscr:"𝒾",Iscr:"",isin:"∈",isindot:"⋵",isinE:"⋹",isins:"⋴",isinsv:"⋳",isinv:"∈",it:"",Itilde:"Ĩ",itilde:"ĩ",Iukcy:"І",iukcy:"і",Iuml:"Ï",iuml:"ï",Jcirc:"Ĵ",jcirc:"ĵ",Jcy:"Й",jcy:"й",Jfr:"𝔍",jfr:"𝔧",jmath:"ȷ",Jopf:"𝕁",jopf:"𝕛",Jscr:"𝒥",jscr:"𝒿",Jsercy:"Ј",jsercy:"ј",Jukcy:"Є",jukcy:"є",Kappa:"Κ",kappa:"κ",kappav:"ϰ",Kcedil:"Ķ",kcedil:"ķ",Kcy:"К",kcy:"к",Kfr:"𝔎",kfr:"𝔨",kgreen:"ĸ",KHcy:"Х",khcy:"х",KJcy:"Ќ",kjcy:"ќ",Kopf:"𝕂",kopf:"𝕜",Kscr:"𝒦",kscr:"𝓀",lAarr:"⇚",Lacute:"Ĺ",lacute:"ĺ",laemptyv:"⦴",lagran:"",Lambda:"Λ",lambda:"λ",lang:"⟨",Lang:"⟪",langd:"⦑",langle:"⟨",lap:"⪅",Laplacetrf:"",laquo:"«",larrb:"⇤",larrbfs:"⤟",larr:"←",Larr:"↞",lArr:"⇐",larrfs:"⤝",larrhk:"↩",larrlp:"↫",larrpl:"⤹",larrsim:"⥳",larrtl:"↢",latail:"⤙",lAtail:"⤛",lat:"⪫",late:"⪭",lates:"⪭︀",lbarr:"⤌",lBarr:"⤎",lbbrk:"",lbrace:"{",lbrack:"[",lbrke:"⦋",lbrksld:"⦏",lbrkslu:"⦍",Lcaron:"Ľ",lcaron:"ľ",Lcedil:"Ļ",lcedil:"ļ",lceil:"⌈",lcub:"{",Lcy:"Л",lcy:"л",ldca:"⤶",ldquo:"“",ldquor:"„",ldrdhar:"⥧",ldrushar:"⥋",ldsh:"↲",le:"≤",lE:"≦",LeftAngleBracket:"⟨",LeftArrowBar:"⇤",leftarrow:"←",LeftArrow:"←",Leftarrow:"⇐",LeftArrowRightArrow:"⇆",leftarrowtail:"↢",LeftCeiling:"⌈",LeftDoubleBracket:"⟦",LeftDownTeeVector:"⥡",LeftDownVectorBar:"⥙",LeftDownVector:"⇃",LeftFloor:"⌊",leftharpoondown:"↽",leftharpoonup:"↼",leftleftarrows:"⇇",leftrightarrow:"↔",LeftRightArrow:"↔",Leftrightarrow:"⇔",leftrightarrows:"⇆",leftrightharpoons:"⇋",leftrightsquigarrow:"↭",LeftRightVector:"⥎",LeftTeeArrow:"↤",LeftTee:"⊣",LeftTeeVector:"⥚",leftthreetimes:"⋋",LeftTriangleBar:"⧏",LeftTriangle:"⊲",LeftTriangleEqual:"⊴",LeftUpDownVector:"⥑",LeftUpTeeVector:"⥠",LeftUpVectorBar:"⥘",LeftUpVector:"↿",LeftVectorBar:"⥒",LeftVector:"↼",lEg:"⪋",leg:"⋚",leq:"≤",leqq:"≦",leqslant:"⩽",lescc:"⪨",les:"⩽",lesdot:"⩿",lesdoto:"⪁",lesdotor:"⪃",lesg:"⋚︀",lesges:"⪓",lessapprox:"⪅",lessdot:"⋖",lesseqgtr:"⋚",lesseqqgtr:"⪋",LessEqualGreater:"⋚",LessFullEqual:"≦",LessGreater:"≶",lessgtr:"≶",LessLess:"⪡",lesssim:"≲",LessSlantEqual:"⩽",LessTilde:"≲",lfisht:"⥼",lfloor:"⌊",Lfr:"𝔏",lfr:"𝔩",lg:"≶",lgE:"⪑",lHar:"⥢",lhard:"↽",lharu:"↼",lharul:"⥪",lhblk:"▄",LJcy:"Љ",ljcy:"љ",llarr:"⇇",ll:"≪",Ll:"⋘",llcorner:"⌞",Lleftarrow:"⇚",llhard:"⥫",lltri:"◺",Lmidot:"Ŀ",lmidot:"ŀ",lmoustache:"⎰",lmoust:"⎰",lnap:"⪉",lnapprox:"⪉",lne:"⪇",lnE:"≨",lneq:"⪇",lneqq:"≨",lnsim:"⋦",loang:"⟬",loarr:"⇽",lobrk:"⟦",longleftarrow:"⟵",LongLeftArrow:"⟵",Longleftarrow:"⟸",longleftrightarrow:"⟷",LongLeftRightArrow:"⟷",Longleftrightarrow:"⟺",longmapsto:"⟼",longrightarrow:"⟶",LongRightArrow:"⟶",Longrightarrow:"⟹",looparrowleft:"↫",looparrowright:"↬",lopar:"⦅",Lopf:"𝕃",lopf:"𝕝",loplus:"⨭",lotimes:"⨴",lowast:"",lowbar:"_",LowerLeftArrow:"↙",LowerRightArrow:"↘",loz:"◊",lozenge:"◊",lozf:"⧫",lpar:"(",lparlt:"⦓",lrarr:"⇆",lrcorner:"⌟",lrhar:"⇋",lrhard:"⥭",lrm:"",lrtri:"⊿",lsaquo:"",lscr:"𝓁",Lscr:"",lsh:"↰",Lsh:"↰",lsim:"≲",lsime:"⪍",lsimg:"⪏",lsqb:"[",lsquo:"",lsquor:"",Lstrok:"Ł",lstrok:"ł",ltcc:"⪦",ltcir:"⩹",lt:"<",LT:"<",Lt:"≪",ltdot:"⋖",lthree:"⋋",ltimes:"⋉",ltlarr:"⥶",ltquest:"⩻",ltri:"◃",ltrie:"⊴",ltrif:"◂",ltrPar:"⦖",lurdshar:"⥊",luruhar:"⥦",lvertneqq:"≨︀",lvnE:"≨︀",macr:"¯",male:"♂",malt:"✠",maltese:"✠",Map:"⤅",map:"↦",mapsto:"↦",mapstodown:"↧",mapstoleft:"↤",mapstoup:"↥",marker:"▮",mcomma:"⨩",Mcy:"М",mcy:"м",mdash:"—",mDDot:"∺",measuredangle:"∡",MediumSpace:"",Mellintrf:"",Mfr:"𝔐",mfr:"𝔪",mho:"℧",micro:"µ",midast:"*",midcir:"⫰",mid:"",middot:"·",minusb:"⊟",minus:"",minusd:"∸",minusdu:"⨪",MinusPlus:"∓",mlcp:"⫛",mldr:"…",mnplus:"∓",models:"⊧",Mopf:"𝕄",mopf:"𝕞",mp:"∓",mscr:"𝓂",Mscr:"",mstpos:"∾",Mu:"Μ",mu:"μ",multimap:"⊸",mumap:"⊸",nabla:"∇",Nacute:"Ń",nacute:"ń",nang:"∠⃒",nap:"≉",napE:"⩰̸",napid:"≋̸",napos:"ʼn",napprox:"≉",natural:"♮",naturals:"",natur:"♮",nbsp:" ",nbump:"≎̸",nbumpe:"≏̸",ncap:"⩃",Ncaron:"Ň",ncaron:"ň",Ncedil:"Ņ",ncedil:"ņ",ncong:"≇",ncongdot:"⩭̸",ncup:"⩂",Ncy:"Н",ncy:"н",ndash:"",nearhk:"⤤",nearr:"↗",neArr:"⇗",nearrow:"↗",ne:"≠",nedot:"≐̸",NegativeMediumSpace:"",NegativeThickSpace:"",NegativeThinSpace:"",NegativeVeryThinSpace:"",nequiv:"≢",nesear:"⤨",nesim:"≂̸",NestedGreaterGreater:"≫",NestedLessLess:"≪",NewLine:"\n",nexist:"∄",nexists:"∄",Nfr:"𝔑",nfr:"𝔫",ngE:"≧̸",nge:"≱",ngeq:"≱",ngeqq:"≧̸",ngeqslant:"⩾̸",nges:"⩾̸",nGg:"⋙̸",ngsim:"≵",nGt:"≫⃒",ngt:"≯",ngtr:"≯",nGtv:"≫̸",nharr:"↮",nhArr:"⇎",nhpar:"⫲",ni:"∋",nis:"⋼",nisd:"⋺",niv:"∋",NJcy:"Њ",njcy:"њ",nlarr:"↚",nlArr:"⇍",nldr:"‥",nlE:"≦̸",nle:"≰",nleftarrow:"↚",nLeftarrow:"⇍",nleftrightarrow:"↮",nLeftrightarrow:"⇎",nleq:"≰",nleqq:"≦̸",nleqslant:"⩽̸",nles:"⩽̸",nless:"≮",nLl:"⋘̸",nlsim:"≴",nLt:"≪⃒",nlt:"≮",nltri:"⋪",nltrie:"⋬",nLtv:"≪̸",nmid:"∤",NoBreak:"",NonBreakingSpace:" ",nopf:"𝕟",Nopf:"",Not:"⫬",not:"¬",NotCongruent:"≢",NotCupCap:"≭",NotDoubleVerticalBar:"∦",NotElement:"∉",NotEqual:"≠",NotEqualTilde:"≂̸",NotExists:"∄",NotGreater:"≯",NotGreaterEqual:"≱",NotGreaterFullEqual:"≧̸",NotGreaterGreater:"≫̸",NotGreaterLess:"≹",NotGreaterSlantEqual:"⩾̸",NotGreaterTilde:"≵",NotHumpDownHump:"≎̸",NotHumpEqual:"≏̸",notin:"∉",notindot:"⋵̸",notinE:"⋹̸",notinva:"∉",notinvb:"⋷",notinvc:"⋶",NotLeftTriangleBar:"⧏̸",NotLeftTriangle:"⋪",NotLeftTriangleEqual:"⋬",NotLess:"≮",NotLessEqual:"≰",NotLessGreater:"≸",NotLessLess:"≪̸",NotLessSlantEqual:"⩽̸",NotLessTilde:"≴",NotNestedGreaterGreater:"⪢̸",NotNestedLessLess:"⪡̸",notni:"∌",notniva:"∌",notnivb:"⋾",notnivc:"⋽",NotPrecedes:"⊀",NotPrecedesEqual:"⪯̸",NotPrecedesSlantEqual:"⋠",NotReverseElement:"∌",NotRightTriangleBar:"⧐̸",NotRightTriangle:"⋫",NotRightTriangleEqual:"⋭",NotSquareSubset:"⊏̸",NotSquareSubsetEqual:"⋢",NotSquareSuperset:"⊐̸",NotSquareSupersetEqual:"⋣",NotSubset:"⊂⃒",NotSubsetEqual:"⊈",NotSucceeds:"⊁",NotSucceedsEqual:"⪰̸",NotSucceedsSlantEqual:"⋡",NotSucceedsTilde:"≿̸",NotSuperset:"⊃⃒",NotSupersetEqual:"⊉",NotTilde:"≁",NotTildeEqual:"≄",NotTildeFullEqual:"≇",NotTildeTilde:"≉",NotVerticalBar:"∤",nparallel:"∦",npar:"∦",nparsl:"⫽⃥",npart:"∂̸",npolint:"⨔",npr:"⊀",nprcue:"⋠",nprec:"⊀",npreceq:"⪯̸",npre:"⪯̸",nrarrc:"⤳̸",nrarr:"↛",nrArr:"⇏",nrarrw:"↝̸",nrightarrow:"↛",nRightarrow:"⇏",nrtri:"⋫",nrtrie:"⋭",nsc:"⊁",nsccue:"⋡",nsce:"⪰̸",Nscr:"𝒩",nscr:"𝓃",nshortmid:"∤",nshortparallel:"∦",nsim:"≁",nsime:"≄",nsimeq:"≄",nsmid:"∤",nspar:"∦",nsqsube:"⋢",nsqsupe:"⋣",nsub:"⊄",nsubE:"⫅̸",nsube:"⊈",nsubset:"⊂⃒",nsubseteq:"⊈",nsubseteqq:"⫅̸",nsucc:"⊁",nsucceq:"⪰̸",nsup:"⊅",nsupE:"⫆̸",nsupe:"⊉",nsupset:"⊃⃒",nsupseteq:"⊉",nsupseteqq:"⫆̸",ntgl:"≹",Ntilde:"Ñ",ntilde:"ñ",ntlg:"≸",ntriangleleft:"⋪",ntrianglelefteq:"⋬",ntriangleright:"⋫",ntrianglerighteq:"⋭",Nu:"Ν",nu:"ν",num:"#",numero:"№",numsp:"",nvap:"≍⃒",nvdash:"⊬",nvDash:"⊭",nVdash:"⊮",nVDash:"⊯",nvge:"≥⃒",nvgt:">⃒",nvHarr:"⤄",nvinfin:"⧞",nvlArr:"⤂",nvle:"≤⃒",nvlt:"<⃒",nvltrie:"⊴⃒",nvrArr:"⤃",nvrtrie:"⊵⃒",nvsim:"∼⃒",nwarhk:"⤣",nwarr:"↖",nwArr:"⇖",nwarrow:"↖",nwnear:"⤧",Oacute:"Ó",oacute:"ó",oast:"⊛",Ocirc:"Ô",ocirc:"ô",ocir:"⊚",Ocy:"О",ocy:"о",odash:"⊝",Odblac:"Ő",odblac:"ő",odiv:"⨸",odot:"⊙",odsold:"⦼",OElig:"Œ",oelig:"œ",ofcir:"⦿",Ofr:"𝔒",ofr:"𝔬",ogon:"˛",Ograve:"Ò",ograve:"ò",ogt:"⧁",ohbar:"⦵",ohm:"Ω",oint:"∮",olarr:"↺",olcir:"⦾",olcross:"⦻",oline:"‾",olt:"⧀",Omacr:"Ō",omacr:"ō",Omega:"Ω",omega:"ω",Omicron:"Ο",omicron:"ο",omid:"⦶",ominus:"⊖",Oopf:"𝕆",oopf:"𝕠",opar:"⦷",OpenCurlyDoubleQuote:"“",OpenCurlyQuote:"",operp:"⦹",oplus:"⊕",orarr:"↻",Or:"⩔",or:"",ord:"⩝",order:"",orderof:"",ordf:"ª",ordm:"º",origof:"⊶",oror:"⩖",orslope:"⩗",orv:"⩛",oS:"Ⓢ",Oscr:"𝒪",oscr:"",Oslash:"Ø",oslash:"ø",osol:"⊘",Otilde:"Õ",otilde:"õ",otimesas:"⨶",Otimes:"⨷",otimes:"⊗",Ouml:"Ö",ouml:"ö",ovbar:"⌽",OverBar:"‾",OverBrace:"⏞",OverBracket:"⎴",OverParenthesis:"⏜",para:"¶",parallel:"∥",par:"∥",parsim:"⫳",parsl:"⫽",part:"∂",PartialD:"∂",Pcy:"П",pcy:"п",percnt:"%",period:".",permil:"‰",perp:"⊥",pertenk:"‱",Pfr:"𝔓",pfr:"𝔭",Phi:"Φ",phi:"φ",phiv:"ϕ",phmmat:"",phone:"☎",Pi:"Π",pi:"π",pitchfork:"⋔",piv:"ϖ",planck:"ℏ",planckh:"",plankv:"ℏ",plusacir:"⨣",plusb:"⊞",pluscir:"⨢",plus:"+",plusdo:"∔",plusdu:"⨥",pluse:"⩲",PlusMinus:"±",plusmn:"±",plussim:"⨦",plustwo:"⨧",pm:"±",Poincareplane:"",pointint:"⨕",popf:"𝕡",Popf:"",pound:"£",prap:"⪷",Pr:"⪻",pr:"≺",prcue:"≼",precapprox:"⪷",prec:"≺",preccurlyeq:"≼",Precedes:"≺",PrecedesEqual:"⪯",PrecedesSlantEqual:"≼",PrecedesTilde:"≾",preceq:"⪯",precnapprox:"⪹",precneqq:"⪵",precnsim:"⋨",pre:"⪯",prE:"⪳",precsim:"≾",prime:"",Prime:"″",primes:"",prnap:"⪹",prnE:"⪵",prnsim:"⋨",prod:"∏",Product:"∏",profalar:"⌮",profline:"⌒",profsurf:"⌓",prop:"∝",Proportional:"∝",Proportion:"∷",propto:"∝",prsim:"≾",prurel:"⊰",Pscr:"𝒫",pscr:"𝓅",Psi:"Ψ",psi:"ψ",puncsp:"",Qfr:"𝔔",qfr:"𝔮",qint:"⨌",qopf:"𝕢",Qopf:"",qprime:"⁗",Qscr:"𝒬",qscr:"𝓆",quaternions:"",quatint:"⨖",quest:"?",questeq:"≟",quot:'"',QUOT:'"',rAarr:"⇛",race:"∽̱",Racute:"Ŕ",racute:"ŕ",radic:"√",raemptyv:"⦳",rang:"⟩",Rang:"⟫",rangd:"⦒",range:"⦥",rangle:"⟩",raquo:"»",rarrap:"⥵",rarrb:"⇥",rarrbfs:"⤠",rarrc:"⤳",rarr:"→",Rarr:"↠",rArr:"⇒",rarrfs:"⤞",rarrhk:"↪",rarrlp:"↬",rarrpl:"⥅",rarrsim:"⥴",Rarrtl:"⤖",rarrtl:"↣",rarrw:"↝",ratail:"⤚",rAtail:"⤜",ratio:"",rationals:"",rbarr:"⤍",rBarr:"⤏",RBarr:"⤐",rbbrk:"",rbrace:"}",rbrack:"]",rbrke:"⦌",rbrksld:"⦎",rbrkslu:"⦐",Rcaron:"Ř",rcaron:"ř",Rcedil:"Ŗ",rcedil:"ŗ",rceil:"⌉",rcub:"}",Rcy:"Р",rcy:"р",rdca:"⤷",rdldhar:"⥩",rdquo:"”",rdquor:"”",rdsh:"↳",real:"",realine:"",realpart:"",reals:"",Re:"",rect:"▭",reg:"®",REG:"®",ReverseElement:"∋",ReverseEquilibrium:"⇋",ReverseUpEquilibrium:"⥯",rfisht:"⥽",rfloor:"⌋",rfr:"𝔯",Rfr:"",rHar:"⥤",rhard:"⇁",rharu:"⇀",rharul:"⥬",Rho:"Ρ",rho:"ρ",rhov:"ϱ",RightAngleBracket:"⟩",RightArrowBar:"⇥",rightarrow:"→",RightArrow:"→",Rightarrow:"⇒",RightArrowLeftArrow:"⇄",rightarrowtail:"↣",RightCeiling:"⌉",RightDoubleBracket:"⟧",RightDownTeeVector:"⥝",RightDownVectorBar:"⥕",RightDownVector:"⇂",RightFloor:"⌋",rightharpoondown:"⇁",rightharpoonup:"⇀",rightleftarrows:"⇄",rightleftharpoons:"⇌",rightrightarrows:"⇉",rightsquigarrow:"↝",RightTeeArrow:"↦",RightTee:"⊢",RightTeeVector:"⥛",rightthreetimes:"⋌",RightTriangleBar:"⧐",RightTriangle:"⊳",RightTriangleEqual:"⊵",RightUpDownVector:"⥏",RightUpTeeVector:"⥜",RightUpVectorBar:"⥔",RightUpVector:"↾",RightVectorBar:"⥓",RightVector:"⇀",ring:"˚",risingdotseq:"≓",rlarr:"⇄",rlhar:"⇌",rlm:"",rmoustache:"⎱",rmoust:"⎱",rnmid:"⫮",roang:"⟭",roarr:"⇾",robrk:"⟧",ropar:"⦆",ropf:"𝕣",Ropf:"",roplus:"⨮",rotimes:"⨵",RoundImplies:"⥰",rpar:")",rpargt:"⦔",rppolint:"⨒",rrarr:"⇉",Rrightarrow:"⇛",rsaquo:"",rscr:"𝓇",Rscr:"",rsh:"↱",Rsh:"↱",rsqb:"]",rsquo:"",rsquor:"",rthree:"⋌",rtimes:"⋊",rtri:"▹",rtrie:"⊵",rtrif:"▸",rtriltri:"⧎",RuleDelayed:"⧴",ruluhar:"⥨",rx:"℞",Sacute:"Ś",sacute:"ś",sbquo:"",scap:"⪸",Scaron:"Š",scaron:"š",Sc:"⪼",sc:"≻",sccue:"≽",sce:"⪰",scE:"⪴",Scedil:"Ş",scedil:"ş",Scirc:"Ŝ",scirc:"ŝ",scnap:"⪺",scnE:"⪶",scnsim:"⋩",scpolint:"⨓",scsim:"≿",Scy:"С",scy:"с",sdotb:"⊡",sdot:"⋅",sdote:"⩦",searhk:"⤥",searr:"↘",seArr:"⇘",searrow:"↘",sect:"§",semi:";",seswar:"⤩",setminus:"",setmn:"",sext:"✶",Sfr:"𝔖",sfr:"𝔰",sfrown:"⌢",sharp:"♯",SHCHcy:"Щ",shchcy:"щ",SHcy:"Ш",shcy:"ш",ShortDownArrow:"↓",ShortLeftArrow:"←",shortmid:"",shortparallel:"∥",ShortRightArrow:"→",ShortUpArrow:"↑",shy:"­",Sigma:"Σ",sigma:"σ",sigmaf:"ς",sigmav:"ς",sim:"",simdot:"⩪",sime:"≃",simeq:"≃",simg:"⪞",simgE:"⪠",siml:"⪝",simlE:"⪟",simne:"≆",simplus:"⨤",simrarr:"⥲",slarr:"←",SmallCircle:"∘",smallsetminus:"",smashp:"⨳",smeparsl:"⧤",smid:"",smile:"⌣",smt:"⪪",smte:"⪬",smtes:"⪬︀",SOFTcy:"Ь",softcy:"ь",solbar:"⌿",solb:"⧄",sol:"/",Sopf:"𝕊",sopf:"𝕤",spades:"♠",spadesuit:"♠",spar:"∥",sqcap:"⊓",sqcaps:"⊓︀",sqcup:"⊔",sqcups:"⊔︀",Sqrt:"√",sqsub:"⊏",sqsube:"⊑",sqsubset:"⊏",sqsubseteq:"⊑",sqsup:"⊐",sqsupe:"⊒",sqsupset:"⊐",sqsupseteq:"⊒",square:"□",Square:"□",SquareIntersection:"⊓",SquareSubset:"⊏",SquareSubsetEqual:"⊑",SquareSuperset:"⊐",SquareSupersetEqual:"⊒",SquareUnion:"⊔",squarf:"▪",squ:"□",squf:"▪",srarr:"→",Sscr:"𝒮",sscr:"𝓈",ssetmn:"",ssmile:"⌣",sstarf:"⋆",Star:"⋆",star:"☆",starf:"★",straightepsilon:"ϵ",straightphi:"ϕ",strns:"¯",sub:"⊂",Sub:"⋐",subdot:"⪽",subE:"⫅",sube:"⊆",subedot:"⫃",submult:"⫁",subnE:"⫋",subne:"⊊",subplus:"⪿",subrarr:"⥹",subset:"⊂",Subset:"⋐",subseteq:"⊆",subseteqq:"⫅",SubsetEqual:"⊆",subsetneq:"⊊",subsetneqq:"⫋",subsim:"⫇",subsub:"⫕",subsup:"⫓",succapprox:"⪸",succ:"≻",succcurlyeq:"≽",Succeeds:"≻",SucceedsEqual:"⪰",SucceedsSlantEqual:"≽",SucceedsTilde:"≿",succeq:"⪰",succnapprox:"⪺",succneqq:"⪶",succnsim:"⋩",succsim:"≿",SuchThat:"∋",sum:"∑",Sum:"∑",sung:"♪",sup1:"¹",sup2:"²",sup3:"³",sup:"⊃",Sup:"⋑",supdot:"⪾",supdsub:"⫘",supE:"⫆",supe:"⊇",supedot:"⫄",Superset:"⊃",SupersetEqual:"⊇",suphsol:"⟉",suphsub:"⫗",suplarr:"⥻",supmult:"⫂",supnE:"⫌",supne:"⊋",supplus:"⫀",supset:"⊃",Supset:"⋑",supseteq:"⊇",supseteqq:"⫆",supsetneq:"⊋",supsetneqq:"⫌",supsim:"⫈",supsub:"⫔",supsup:"⫖",swarhk:"⤦",swarr:"↙",swArr:"⇙",swarrow:"↙",swnwar:"⤪",szlig:"ß",Tab:"\t",target:"⌖",Tau:"Τ",tau:"τ",tbrk:"⎴",Tcaron:"Ť",tcaron:"ť",Tcedil:"Ţ",tcedil:"ţ",Tcy:"Т",tcy:"т",tdot:"⃛",telrec:"⌕",Tfr:"𝔗",tfr:"𝔱",there4:"∴",therefore:"∴",Therefore:"∴",Theta:"Θ",theta:"θ",thetasym:"ϑ",thetav:"ϑ",thickapprox:"≈",thicksim:"",ThickSpace:"",ThinSpace:"",thinsp:"",thkap:"≈",thksim:"",THORN:"Þ",thorn:"þ",tilde:"˜",Tilde:"",TildeEqual:"≃",TildeFullEqual:"≅",TildeTilde:"≈",timesbar:"⨱",timesb:"⊠",times:"×",timesd:"⨰",tint:"∭",toea:"⤨",topbot:"⌶",topcir:"⫱",top:"",Topf:"𝕋",topf:"𝕥",topfork:"⫚",tosa:"⤩",tprime:"‴",trade:"™",TRADE:"™",triangle:"▵",triangledown:"▿",triangleleft:"◃",trianglelefteq:"⊴",triangleq:"≜",triangleright:"▹",trianglerighteq:"⊵",tridot:"◬",trie:"≜",triminus:"⨺",TripleDot:"⃛",triplus:"⨹",trisb:"⧍",tritime:"⨻",trpezium:"⏢",Tscr:"𝒯",tscr:"𝓉",TScy:"Ц",tscy:"ц",TSHcy:"Ћ",tshcy:"ћ",Tstrok:"Ŧ",tstrok:"ŧ",twixt:"≬",twoheadleftarrow:"↞",twoheadrightarrow:"↠",Uacute:"Ú",uacute:"ú",uarr:"↑",Uarr:"↟",uArr:"⇑",Uarrocir:"⥉",Ubrcy:"Ў",ubrcy:"ў",Ubreve:"Ŭ",ubreve:"ŭ",Ucirc:"Û",ucirc:"û",Ucy:"У",ucy:"у",udarr:"⇅",Udblac:"Ű",udblac:"ű",udhar:"⥮",ufisht:"⥾",Ufr:"𝔘",ufr:"𝔲",Ugrave:"Ù",ugrave:"ù",uHar:"⥣",uharl:"↿",uharr:"↾",uhblk:"▀",ulcorn:"⌜",ulcorner:"⌜",ulcrop:"⌏",ultri:"◸",Umacr:"Ū",umacr:"ū",uml:"¨",UnderBar:"_",UnderBrace:"⏟",UnderBracket:"⎵",UnderParenthesis:"⏝",Union:"",UnionPlus:"⊎",Uogon:"Ų",uogon:"ų",Uopf:"𝕌",uopf:"𝕦",UpArrowBar:"⤒",uparrow:"↑",UpArrow:"↑",Uparrow:"⇑",UpArrowDownArrow:"⇅",updownarrow:"↕",UpDownArrow:"↕",Updownarrow:"⇕",UpEquilibrium:"⥮",upharpoonleft:"↿",upharpoonright:"↾",uplus:"⊎",UpperLeftArrow:"↖",UpperRightArrow:"↗",upsi:"υ",Upsi:"ϒ",upsih:"ϒ",Upsilon:"Υ",upsilon:"υ",UpTeeArrow:"↥",UpTee:"⊥",upuparrows:"⇈",urcorn:"⌝",urcorner:"⌝",urcrop:"⌎",Uring:"Ů",uring:"ů",urtri:"◹",Uscr:"𝒰",uscr:"𝓊",utdot:"⋰",Utilde:"Ũ",utilde:"ũ",utri:"▵",utrif:"▴",uuarr:"⇈",Uuml:"Ü",uuml:"ü",uwangle:"⦧",vangrt:"⦜",varepsilon:"ϵ",varkappa:"ϰ",varnothing:"∅",varphi:"ϕ",varpi:"ϖ",varpropto:"∝",varr:"↕",vArr:"⇕",varrho:"ϱ",varsigma:"ς",varsubsetneq:"⊊︀",varsubsetneqq:"⫋︀",varsupsetneq:"⊋︀",varsupsetneqq:"⫌︀",vartheta:"ϑ",vartriangleleft:"⊲",vartriangleright:"⊳",vBar:"⫨",Vbar:"⫫",vBarv:"⫩",Vcy:"В",vcy:"в",vdash:"⊢",vDash:"⊨",Vdash:"⊩",VDash:"⊫",Vdashl:"⫦",veebar:"⊻",vee:"",Vee:"",veeeq:"≚",vellip:"⋮",verbar:"|",Verbar:"‖",vert:"|",Vert:"‖",VerticalBar:"",VerticalLine:"|",VerticalSeparator:"❘",VerticalTilde:"≀",VeryThinSpace:"",Vfr:"𝔙",vfr:"𝔳",vltri:"⊲",vnsub:"⊂⃒",vnsup:"⊃⃒",Vopf:"𝕍",vopf:"𝕧",vprop:"∝",vrtri:"⊳",Vscr:"𝒱",vscr:"𝓋",vsubnE:"⫋︀",vsubne:"⊊︀",vsupnE:"⫌︀",vsupne:"⊋︀",Vvdash:"⊪",vzigzag:"⦚",Wcirc:"Ŵ",wcirc:"ŵ",wedbar:"⩟",wedge:"∧",Wedge:"⋀",wedgeq:"≙",weierp:"℘",Wfr:"𝔚",wfr:"𝔴",Wopf:"𝕎",wopf:"𝕨",wp:"℘",wr:"≀",wreath:"≀",Wscr:"𝒲",wscr:"𝓌",xcap:"⋂",xcirc:"◯",xcup:"",xdtri:"▽",Xfr:"𝔛",xfr:"𝔵",xharr:"⟷",xhArr:"⟺",Xi:"Ξ",xi:"ξ",xlarr:"⟵",xlArr:"⟸",xmap:"⟼",xnis:"⋻",xodot:"⨀",Xopf:"𝕏",xopf:"𝕩",xoplus:"⨁",xotime:"⨂",xrarr:"⟶",xrArr:"⟹",Xscr:"𝒳",xscr:"𝓍",xsqcup:"⨆",xuplus:"⨄",xutri:"△",xvee:"",xwedge:"⋀",Yacute:"Ý",yacute:"ý",YAcy:"Я",yacy:"я",Ycirc:"Ŷ",ycirc:"ŷ",Ycy:"Ы",ycy:"ы",yen:"¥",Yfr:"𝔜",yfr:"𝔶",YIcy:"Ї",yicy:"ї",Yopf:"𝕐",yopf:"𝕪",Yscr:"𝒴",yscr:"𝓎",YUcy:"Ю",yucy:"ю",yuml:"ÿ",Yuml:"Ÿ",Zacute:"Ź",zacute:"ź",Zcaron:"Ž",zcaron:"ž",Zcy:"З",zcy:"з",Zdot:"Ż",zdot:"ż",zeetrf:"",ZeroWidthSpace:"",Zeta:"Ζ",zeta:"ζ",zfr:"𝔷",Zfr:"",ZHcy:"Ж",zhcy:"ж",zigrarr:"⇝",zopf:"𝕫",Zopf:"",Zscr:"𝒵",zscr:"𝓏",zwj:"",zwnj:""},qo=/[!-#%-\*,-\/:;\?@\[-\]_\{\}\xA1\xA7\xAB\xB6\xB7\xBB\xBF\u037E\u0387\u055A-\u055F\u0589\u058A\u05BE\u05C0\u05C3\u05C6\u05F3\u05F4\u0609\u060A\u060C\u060D\u061B\u061E\u061F\u066A-\u066D\u06D4\u0700-\u070D\u07F7-\u07F9\u0830-\u083E\u085E\u0964\u0965\u0970\u09FD\u0A76\u0AF0\u0C84\u0DF4\u0E4F\u0E5A\u0E5B\u0F04-\u0F12\u0F14\u0F3A-\u0F3D\u0F85\u0FD0-\u0FD4\u0FD9\u0FDA\u104A-\u104F\u10FB\u1360-\u1368\u1400\u166D\u166E\u169B\u169C\u16EB-\u16ED\u1735\u1736\u17D4-\u17D6\u17D8-\u17DA\u1800-\u180A\u1944\u1945\u1A1E\u1A1F\u1AA0-\u1AA6\u1AA8-\u1AAD\u1B5A-\u1B60\u1BFC-\u1BFF\u1C3B-\u1C3F\u1C7E\u1C7F\u1CC0-\u1CC7\u1CD3\u2010-\u2027\u2030-\u2043\u2045-\u2051\u2053-\u205E\u207D\u207E\u208D\u208E\u2308-\u230B\u2329\u232A\u2768-\u2775\u27C5\u27C6\u27E6-\u27EF\u2983-\u2998\u29D8-\u29DB\u29FC\u29FD\u2CF9-\u2CFC\u2CFE\u2CFF\u2D70\u2E00-\u2E2E\u2E30-\u2E4E\u3001-\u3003\u3008-\u3011\u3014-\u301F\u3030\u303D\u30A0\u30FB\uA4FE\uA4FF\uA60D-\uA60F\uA673\uA67E\uA6F2-\uA6F7\uA874-\uA877\uA8CE\uA8CF\uA8F8-\uA8FA\uA8FC\uA92E\uA92F\uA95F\uA9C1-\uA9CD\uA9DE\uA9DF\uAA5C-\uAA5F\uAADE\uAADF\uAAF0\uAAF1\uABEB\uFD3E\uFD3F\uFE10-\uFE19\uFE30-\uFE52\uFE54-\uFE61\uFE63\uFE68\uFE6A\uFE6B\uFF01-\uFF03\uFF05-\uFF0A\uFF0C-\uFF0F\uFF1A\uFF1B\uFF1F\uFF20\uFF3B-\uFF3D\uFF3F\uFF5B\uFF5D\uFF5F-\uFF65]|\uD800[\uDD00-\uDD02\uDF9F\uDFD0]|\uD801\uDD6F|\uD802[\uDC57\uDD1F\uDD3F\uDE50-\uDE58\uDE7F\uDEF0-\uDEF6\uDF39-\uDF3F\uDF99-\uDF9C]|\uD803[\uDF55-\uDF59]|\uD804[\uDC47-\uDC4D\uDCBB\uDCBC\uDCBE-\uDCC1\uDD40-\uDD43\uDD74\uDD75\uDDC5-\uDDC8\uDDCD\uDDDB\uDDDD-\uDDDF\uDE38-\uDE3D\uDEA9]|\uD805[\uDC4B-\uDC4F\uDC5B\uDC5D\uDCC6\uDDC1-\uDDD7\uDE41-\uDE43\uDE60-\uDE6C\uDF3C-\uDF3E]|\uD806[\uDC3B\uDE3F-\uDE46\uDE9A-\uDE9C\uDE9E-\uDEA2]|\uD807[\uDC41-\uDC45\uDC70\uDC71\uDEF7\uDEF8]|\uD809[\uDC70-\uDC74]|\uD81A[\uDE6E\uDE6F\uDEF5\uDF37-\uDF3B\uDF44]|\uD81B[\uDE97-\uDE9A]|\uD82F\uDC9F|\uD836[\uDE87-\uDE8B]|\uD83A[\uDD5E\uDD5F]/,Io={};function $o(e,t,n){var r,i,o,a,s,l="";for("string"!=typeof t&&(n=t,t=$o.defaultChars),void 0===n&&(n=!0),s=function(e){var t,n,r=Io[e];if(r)return r;for(r=Io[e]=[],t=0;t<128;t++)n=String.fromCharCode(t),/^[0-9a-z]$/i.test(n)?r.push(n):r.push("%"+("0"+t.toString(16).toUpperCase()).slice(-2));for(t=0;t<e.length;t++)r[e.charCodeAt(t)]=e[t];return r}(t),r=0,i=e.length;r<i;r++)if(o=e.charCodeAt(r),n&&37===o&&r+2<i&&/^[0-9a-f]{2}$/i.test(e.slice(r+1,r+3)))l+=e.slice(r,r+3),r+=2;else if(o<128)l+=s[o];else if(o>=55296&&o<=57343){if(o>=55296&&o<=56319&&r+1<i&&(a=e.charCodeAt(r+1))>=56320&&a<=57343){l+=encodeURIComponent(e[r]+e[r+1]),r++;continue}l+="%EF%BF%BD"}else l+=encodeURIComponent(e[r]);return l}$o.defaultChars=";/?:@&=+$,-_.!~*'()#",$o.componentChars="-_.!~*'()";var Ro=$o,zo={};function Bo(e,t){var n;return"string"!=typeof t&&(t=Bo.defaultChars),n=function(e){var t,n,r=zo[e];if(r)return r;for(r=zo[e]=[],t=0;t<128;t++)n=String.fromCharCode(t),r.push(n);for(t=0;t<e.length;t++)r[n=e.charCodeAt(t)]="%"+("0"+n.toString(16).toUpperCase()).slice(-2);return r}(t),e.replace(/(%[a-f0-9]{2})+/gi,(function(e){var t,r,i,o,a,s,l,u="";for(t=0,r=e.length;t<r;t+=3)(i=parseInt(e.slice(t+1,t+3),16))<128?u+=n[i]:192==(224&i)&&t+3<r&&128==(192&(o=parseInt(e.slice(t+4,t+6),16)))?(u+=(l=i<<6&1984|63&o)<128?"<22><>":String.fromCharCode(l),t+=3):224==(240&i)&&t+6<r&&(o=parseInt(e.slice(t+4,t+6),16),a=parseInt(e.slice(t+7,t+9),16),128==(192&o)&&128==(192&a))?(u+=(l=i<<12&61440|o<<6&4032|63&a)<2048||l>=55296&&l<=57343?"<22><><EFBFBD>":String.fromCharCode(l),t+=6):240==(248&i)&&t+9<r&&(o=parseInt(e.slice(t+4,t+6),16),a=parseInt(e.slice(t+7,t+9),16),s=parseInt(e.slice(t+10,t+12),16),128==(192&o)&&128==(192&a)&&128==(192&s))?((l=i<<18&1835008|o<<12&258048|a<<6&4032|63&s)<65536||l>1114111?u+="<22><><EFBFBD><EFBFBD>":(l-=65536,u+=String.fromCharCode(55296+(l>>10),56320+(1023&l))),t+=9):u+="<22>";return u}))}Bo.defaultChars=";/?:@&=+$,#",Bo.componentChars="";var Wo=Bo;function Ho(){this.protocol=null,this.slashes=null,this.auth=null,this.port=null,this.hostname=null,this.hash=null,this.search=null,this.pathname=null}var Uo=/^([a-z0-9.+-]+:)/i,Vo=/:[0-9]*$/,Ko=/^(\/\/?(?!\/)[^\?\s]*)(\?[^\s]*)?$/,Yo=["{","}","|","\\","^","`"].concat(["<",">",'"',"`"," ","\r","\n","\t"]),Go=["'"].concat(Yo),Zo=["%","/","?",";","#"].concat(Go),Xo=["/","?","#"],Jo=/^[+a-z0-9A-Z_-]{0,63}$/,Qo=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,ea={javascript:!0,"javascript:":!0},ta={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0};Ho.prototype.parse=function(e,t){var n,r,i,o,a,s=e;if(s=s.trim(),!t&&1===e.split("#").length){var l=Ko.exec(s);if(l)return this.pathname=l[1],l[2]&&(this.search=l[2]),this}var u=Uo.exec(s);if(u&&(i=(u=u[0]).toLowerCase(),this.protocol=u,s=s.substr(u.length)),(t||u||s.match(/^\/\/[^@\/]+@[^@\/]+/))&&(!(a="//"===s.substr(0,2))||u&&ea[u]||(s=s.substr(2),this.slashes=!0)),!ea[u]&&(a||u&&!ta[u])){var c,f,p=-1;for(n=0;n<Xo.length;n++)-1!==(o=s.indexOf(Xo[n]))&&(-1===p||o<p)&&(p=o);for(-1!==(f=-1===p?s.lastIndexOf("@"):s.lastIndexOf("@",p))&&(c=s.slice(0,f),s=s.slice(f+1),this.auth=c),p=-1,n=0;n<Zo.length;n++)-1!==(o=s.indexOf(Zo[n]))&&(-1===p||o<p)&&(p=o);-1===p&&(p=s.length),":"===s[p-1]&&p--;var d=s.slice(0,p);s=s.slice(p),this.parseHost(d),this.hostname=this.hostname||"";var h="["===this.hostname[0]&&"]"===this.hostname[this.hostname.length-1];if(!h){var g=this.hostname.split(/\./);for(n=0,r=g.length;n<r;n++){var m=g[n];if(m&&!m.match(Jo)){for(var v="",y=0,b=m.length;y<b;y++)m.charCodeAt(y)>127?v+="x":v+=m[y];if(!v.match(Jo)){var _=g.slice(0,n),w=g.slice(n+1),x=m.match(Qo);x&&(_.push(x[1]),w.unshift(x[2])),w.length&&(s=w.join(".")+s),this.hostname=_.join(".");break}}}}this.hostname.length>255&&(this.hostname=""),h&&(this.hostname=this.hostname.substr(1,this.hostname.length-2))}var k=s.indexOf("#");-1!==k&&(this.hash=s.substr(k),s=s.slice(0,k));var C=s.indexOf("?");return-1!==C&&(this.search=s.substr(C),s=s.slice(0,C)),s&&(this.pathname=s),ta[i]&&this.hostname&&!this.pathname&&(this.pathname=""),this},Ho.prototype.parseHost=function(e){var t=Vo.exec(e);t&&(":"!==(t=t[0])&&(this.port=t.substr(1)),e=e.substr(0,e.length-t.length)),e&&(this.hostname=e)};var na={encode:Ro,decode:Wo,format:function(e){var t="";return t+=e.protocol||"",t+=e.slashes?"//":"",t+=e.auth?e.auth+"@":"",e.hostname&&-1!==e.hostname.indexOf(":")?t+="["+e.hostname+"]":t+=e.hostname||"",t+=e.port?":"+e.port:"",t+=e.pathname||"",t+=e.search||"",t+=e.hash||""},parse:function(e,t){if(e&&e instanceof Ho)return e;var n=new Ho;return n.parse(e,t),n}},ra=/[\0-\uD7FF\uE000-\uFFFF]|[\uD800-\uDBFF][\uDC00-\uDFFF]|[\uD800-\uDBFF](?![\uDC00-\uDFFF])|(?:[^\uD800-\uDBFF]|^)[\uDC00-\uDFFF]/,ia=/[\0-\x1F\x7F-\x9F]/,oa=/[ \xA0\u1680\u2000-\u200A\u2028\u2029\u202F\u205F\u3000]/,aa={Any:ra,Cc:ia,Cf:/[\xAD\u0600-\u0605\u061C\u06DD\u070F\u08E2\u180E\u200B-\u200F\u202A-\u202E\u2060-\u2064\u2066-\u206F\uFEFF\uFFF9-\uFFFB]|\uD804[\uDCBD\uDCCD]|\uD82F[\uDCA0-\uDCA3]|\uD834[\uDD73-\uDD7A]|\uDB40[\uDC01\uDC20-\uDC7F]/,P:qo,Z:oa},sa=Un((function(e,t){var n=Object.prototype.hasOwnProperty;function r(e,t){return n.call(e,t)}function i(e){return!(e>=55296&&e<=57343)&&(!(e>=64976&&e<=65007)&&(65535!=(65535&e)&&65534!=(65535&e)&&(!(e>=0&&e<=8)&&(11!==e&&(!(e>=14&&e<=31)&&(!(e>=127&&e<=159)&&!(e>1114111)))))))}function o(e){if(e>65535){var t=55296+((e-=65536)>>10),n=56320+(1023&e);return String.fromCharCode(t,n)}return String.fromCharCode(e)}var a=/\\([!"#$%&'()*+,\-.\/:;<=>?@[\\\]^_`{|}~])/g,s=new RegExp(a.source+"|"+/&([a-z#][a-z0-9]{1,31});/gi.source,"gi"),l=/^#((?:x[a-f0-9]{1,8}|[0-9]{1,8}))/i;var u=/[&<>"]/,c=/[&<>"]/g,f={"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;"};function p(e){return f[e]}var d=/[.?*+^$[\]\\(){}|-]/g;t.lib={},t.lib.mdurl=na,t.lib.ucmicro=aa,t.assign=function(e){var t=Array.prototype.slice.call(arguments,1);return t.forEach((function(t){if(t){if("object"!=typeof t)throw new TypeError(t+"must be object");Object.keys(t).forEach((function(n){e[n]=t[n]}))}})),e},t.isString=function(e){return"[object String]"===function(e){return Object.prototype.toString.call(e)}(e)},t.has=r,t.unescapeMd=function(e){return e.indexOf("\\")<0?e:e.replace(a,"$1")},t.unescapeAll=function(e){return e.indexOf("\\")<0&&e.indexOf("&")<0?e:e.replace(s,(function(e,t,n){return t||function(e,t){var n=0;return r(Fo,t)?Fo[t]:35===t.charCodeAt(0)&&l.test(t)&&i(n="x"===t[1].toLowerCase()?parseInt(t.slice(2),16):parseInt(t.slice(1),10))?o(n):e}(e,n)}))},t.isValidEntityCode=i,t.fromCodePoint=o,t.escapeHtml=function(e){return u.test(e)?e.replace(c,p):e},t.arrayReplaceAt=function(e,t,n){return[].concat(e.slice(0,t),n,e.slice(t+1))},t.isSpace=function(e){switch(e){case 9:case 32:return!0}return!1},t.isWhiteSpace=function(e){if(e>=8192&&e<=8202)return!0;switch(e){case 9:case 10:case 11:case 12:case 13:case 32:case 160:case 5760:case 8239:case 8287:case 12288:return!0}return!1},t.isMdAsciiPunct=function(e){switch(e){case 33:case 34:case 35:case 36:case 37:case 38:case 39:case 40:case 41:case 42:case 43:case 44:case 45:case 46:case 47:case 58:case 59:case 60:case 61:case 62:case 63:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 124:case 125:case 126:return!0;default:return!1}},t.isPunctChar=function(e){return qo.test(e)},t.escapeRE=function(e){return e.replace(d,"\\$&")},t.normalizeReference=function(e){return e=e.trim().replace(/\s+/g," "),"Ṿ"==="ẞ".toLowerCase()&&(e=e.replace(/ẞ/g,"ß")),e.toLowerCase().toUpperCase()}})),la=sa.unescapeAll,ua=sa.unescapeAll,ca={parseLinkLabel:function(e,t,n){var r,i,o,a,s=-1,l=e.posMax,u=e.pos;for(e.pos=t+1,r=1;e.pos<l;){if(93===(o=e.src.charCodeAt(e.pos))&&0===--r){i=!0;break}if(a=e.pos,e.md.inline.skipToken(e),91===o)if(a===e.pos-1)r++;else if(n)return e.pos=u,-1}return i&&(s=e.pos),e.pos=u,s},parseLinkDestination:function(e,t,n){var r,i,o=t,a={ok:!1,pos:0,lines:0,str:""};if(60===e.charCodeAt(t)){for(t++;t<n;){if(10===(r=e.charCodeAt(t)))return a;if(60===r)return a;if(62===r)return a.pos=t+1,a.str=la(e.slice(o+1,t)),a.ok=!0,a;92===r&&t+1<n?t+=2:t++}return a}for(i=0;t<n&&32!==(r=e.charCodeAt(t))&&!(r<32||127===r);)if(92===r&&t+1<n){if(32===e.charCodeAt(t+1))break;t+=2}else{if(40===r&&++i>32)return a;if(41===r){if(0===i)break;i--}t++}return o===t||0!==i||(a.str=la(e.slice(o,t)),a.lines=0,a.pos=t,a.ok=!0),a},parseLinkTitle:function(e,t,n){var r,i,o=0,a=t,s={ok:!1,pos:0,lines:0,str:""};if(t>=n)return s;if(34!==(i=e.charCodeAt(t))&&39!==i&&40!==i)return s;for(t++,40===i&&(i=41);t<n;){if((r=e.charCodeAt(t))===i)return s.pos=t+1,s.lines=o,s.str=ua(e.slice(a+1,t)),s.ok=!0,s;if(40===r&&41===i)return s;10===r?o++:92===r&&t+1<n&&(t++,10===e.charCodeAt(t)&&o++),t++}return s}},fa=sa.assign,pa=sa.unescapeAll,da=sa.escapeHtml,ha={};function ga(){this.rules=fa({},ha)}ha.code_inline=function(e,t,n,r,i){var o=e[t];return"<code"+i.renderAttrs(o)+">"+da(e[t].content)+"</code>"},ha.code_block=function(e,t,n,r,i){var o=e[t];return"<pre"+i.renderAttrs(o)+"><code>"+da(e[t].content)+"</code></pre>\n"},ha.fence=function(e,t,n,r,i){var o,a,s,l,u,c=e[t],f=c.info?pa(c.info).trim():"",p="",d="";return f&&(p=(s=f.split(/(\s+)/g))[0],d=s.slice(2).join("")),0===(o=n.highlight&&n.highlight(c.content,p,d)||da(c.content)).indexOf("<pre")?o+"\n":f?(a=c.attrIndex("class"),l=c.attrs?c.attrs.slice():[],a<0?l.push(["class",n.langPrefix+p]):(l[a]=l[a].slice(),l[a][1]+=" "+n.langPrefix+p),u={attrs:l},"<pre><code"+i.renderAttrs(u)+">"+o+"</code></pre>\n"):"<pre><code"+i.renderAttrs(c)+">"+o+"</code></pre>\n"},ha.image=function(e,t,n,r,i){var o=e[t];return o.attrs[o.attrIndex("alt")][1]=i.renderInlineAsText(o.children,n,r),i.renderToken(e,t,n)},ha.hardbreak=function(e,t,n){return n.xhtmlOut?"<br />\n":"<br>\n"},ha.softbreak=function(e,t,n){return n.breaks?n.xhtmlOut?"<br />\n":"<br>\n":"\n"},ha.text=function(e,t){return da(e[t].content)},ha.html_block=function(e,t){return e[t].content},ha.html_inline=function(e,t){return e[t].content},ga.prototype.renderAttrs=function(e){var t,n,r;if(!e.attrs)return"";for(r="",t=0,n=e.attrs.length;t<n;t++)r+=" "+da(e.attrs[t][0])+'="'+da(e.attrs[t][1])+'"';return r},ga.prototype.renderToken=function(e,t,n){var r,i="",o=!1,a=e[t];return a.hidden?"":(a.block&&-1!==a.nesting&&t&&e[t-1].hidden&&(i+="\n"),i+=(-1===a.nesting?"</":"<")+a.tag,i+=this.renderAttrs(a),0===a.nesting&&n.xhtmlOut&&(i+=" /"),a.block&&(o=!0,1===a.nesting&&t+1<e.length&&("inline"===(r=e[t+1]).type||r.hidden||-1===r.nesting&&r.tag===a.tag)&&(o=!1)),i+=o?">\n":">")},ga.prototype.renderInline=function(e,t,n){for(var r,i="",o=this.rules,a=0,s=e.length;a<s;a++)void 0!==o[r=e[a].type]?i+=o[r](e,a,t,n,this):i+=this.renderToken(e,a,t);return i},ga.prototype.renderInlineAsText=function(e,t,n){for(var r="",i=0,o=e.length;i<o;i++)"text"===e[i].type?r+=e[i].content:"image"===e[i].type&&(r+=this.renderInlineAsText(e[i].children,t,n));return r},ga.prototype.render=function(e,t,n){var r,i,o,a="",s=this.rules;for(r=0,i=e.length;r<i;r++)"inline"===(o=e[r].type)?a+=this.renderInline(e[r].children,t,n):void 0!==s[o]?a+=s[e[r].type](e,r,t,n,this):a+=this.renderToken(e,r,t,n);return a};var ma=ga;function va(){this.__rules__=[],this.__cache__=null}va.prototype.__find__=function(e){for(var t=0;t<this.__rules__.length;t++)if(this.__rules__[t].name===e)return t;return-1},va.prototype.__compile__=function(){var e=this,t=[""];e.__rules__.forEach((function(e){e.enabled&&e.alt.forEach((function(e){t.indexOf(e)<0&&t.push(e)}))})),e.__cache__={},t.forEach((function(t){e.__cache__[t]=[],e.__rules__.forEach((function(n){n.enabled&&(t&&n.alt.indexOf(t)<0||e.__cache__[t].push(n.fn))}))}))},va.prototype.at=function(e,t,n){var r=this.__find__(e),i=n||{};if(-1===r)throw new Error("Parser rule not found: "+e);this.__rules__[r].fn=t,this.__rules__[r].alt=i.alt||[],this.__cache__=null},va.prototype.before=function(e,t,n,r){var i=this.__find__(e),o=r||{};if(-1===i)throw new Error("Parser rule not found: "+e);this.__rules__.splice(i,0,{name:t,enabled:!0,fn:n,alt:o.alt||[]}),this.__cache__=null},va.prototype.after=function(e,t,n,r){var i=this.__find__(e),o=r||{};if(-1===i)throw new Error("Parser rule not found: "+e);this.__rules__.splice(i+1,0,{name:t,enabled:!0,fn:n,alt:o.alt||[]}),this.__cache__=null},va.prototype.push=function(e,t,n){var r=n||{};this.__rules__.push({name:e,enabled:!0,fn:t,alt:r.alt||[]}),this.__cache__=null},va.prototype.enable=function(e,t){Array.isArray(e)||(e=[e]);var n=[];return e.forEach((function(e){var r=this.__find__(e);if(r<0){if(t)return;throw new Error("Rules manager: invalid rule name "+e)}this.__rules__[r].enabled=!0,n.push(e)}),this),this.__cache__=null,n},va.prototype.enableOnly=function(e,t){Array.isArray(e)||(e=[e]),this.__rules__.forEach((function(e){e.enabled=!1})),this.enable(e,t)},va.prototype.disable=function(e,t){Array.isArray(e)||(e=[e]);var n=[];return e.forEach((function(e){var r=this.__find__(e);if(r<0){if(t)return;throw new Error("Rules manager: invalid rule name "+e)}this.__rules__[r].enabled=!1,n.push(e)}),this),this.__cache__=null,n},va.prototype.getRules=function(e){return null===this.__cache__&&this.__compile__(),this.__cache__[e]||[]};var ya=va,ba=/\r\n?|\n/g,_a=/\0/g,wa=sa.arrayReplaceAt;function xa(e){return/^<\/a\s*>/i.test(e)}var ka=/\+-|\.\.|\?\?\?\?|!!!!|,,|--/,Ca=/\((c|tm|r|p)\)/i,Ea=/\((c|tm|r|p)\)/gi,Oa={c:"©",r:"®",p:"§",tm:"™"};function Aa(e,t){return Oa[t.toLowerCase()]}function Sa(e){var t,n,r=0;for(t=e.length-1;t>=0;t--)"text"!==(n=e[t]).type||r||(n.content=n.content.replace(Ea,Aa)),"link_open"===n.type&&"auto"===n.info&&r--,"link_close"===n.type&&"auto"===n.info&&r++}function ja(e){var t,n,r=0;for(t=e.length-1;t>=0;t--)"text"!==(n=e[t]).type||r||ka.test(n.content)&&(n.content=n.content.replace(/\+-/g,"±").replace(/\.{2,}/g,"…").replace(/([?!])…/g,"$1..").replace(/([?!]){4,}/g,"$1$1$1").replace(/,{2,}/g,",").replace(/(^|[^-])---(?=[^-]|$)/gm,"$1—").replace(/(^|\s)--(?=\s|$)/gm,"$1").replace(/(^|[^-\s])--(?=[^-\s]|$)/gm,"$1")),"link_open"===n.type&&"auto"===n.info&&r--,"link_close"===n.type&&"auto"===n.info&&r++}var Ta=sa.isWhiteSpace,Da=sa.isPunctChar,Na=sa.isMdAsciiPunct,La=/['"]/,Ma=/['"]/g;function Pa(e,t,n){return e.substr(0,t)+n+e.substr(t+1)}function Fa(e,t){var n,r,i,o,a,s,l,u,c,f,p,d,h,g,m,v,y,b,_,w,x;for(_=[],n=0;n<e.length;n++){for(r=e[n],l=e[n].level,y=_.length-1;y>=0&&!(_[y].level<=l);y--);if(_.length=y+1,"text"===r.type){a=0,s=(i=r.content).length;e:for(;a<s&&(Ma.lastIndex=a,o=Ma.exec(i));){if(m=v=!0,a=o.index+1,b="'"===o[0],c=32,o.index-1>=0)c=i.charCodeAt(o.index-1);else for(y=n-1;y>=0&&("softbreak"!==e[y].type&&"hardbreak"!==e[y].type);y--)if(e[y].content){c=e[y].content.charCodeAt(e[y].content.length-1);break}if(f=32,a<s)f=i.charCodeAt(a);else for(y=n+1;y<e.length&&("softbreak"!==e[y].type&&"hardbreak"!==e[y].type);y++)if(e[y].content){f=e[y].content.charCodeAt(0);break}if(p=Na(c)||Da(String.fromCharCode(c)),d=Na(f)||Da(String.fromCharCode(f)),h=Ta(c),(g=Ta(f))?m=!1:d&&(h||p||(m=!1)),h?v=!1:p&&(g||d||(v=!1)),34===f&&'"'===o[0]&&c>=48&&c<=57&&(v=m=!1),m&&v&&(m=p,v=d),m||v){if(v)for(y=_.length-1;y>=0&&(u=_[y],!(_[y].level<l));y--)if(u.single===b&&_[y].level===l){u=_[y],b?(w=t.md.options.quotes[2],x=t.md.options.quotes[3]):(w=t.md.options.quotes[0],x=t.md.options.quotes[1]),r.content=Pa(r.content,o.index,x),e[u.token].content=Pa(e[u.token].content,u.pos,w),a+=x.length-1,u.token===n&&(a+=w.length-1),s=(i=r.content).length,_.length=y;continue e}m?_.push({token:n,pos:o.index,single:b,level:l}):v&&b&&(r.content=Pa(r.content,o.index,""))}else b&&(r.content=Pa(r.content,o.index,""))}}}}function qa(e,t,n){this.type=e,this.tag=t,this.attrs=null,this.map=null,this.nesting=n,this.level=0,this.children=null,this.content="",this.markup="",this.info="",this.meta=null,this.block=!1,this.hidden=!1}qa.prototype.attrIndex=function(e){var t,n,r;if(!this.attrs)return-1;for(n=0,r=(t=this.attrs).length;n<r;n++)if(t[n][0]===e)return n;return-1},qa.prototype.attrPush=function(e){this.attrs?this.attrs.push(e):this.attrs=[e]},qa.prototype.attrSet=function(e,t){var n=this.attrIndex(e),r=[e,t];n<0?this.attrPush(r):this.attrs[n]=r},qa.prototype.attrGet=function(e){var t=this.attrIndex(e),n=null;return t>=0&&(n=this.attrs[t][1]),n},qa.prototype.attrJoin=function(e,t){var n=this.attrIndex(e);n<0?this.attrPush([e,t]):this.attrs[n][1]=this.attrs[n][1]+" "+t};var Ia=qa;function $a(e,t,n){this.src=e,this.env=n,this.tokens=[],this.inlineMode=!1,this.md=t}$a.prototype.Token=Ia;var Ra=$a,za=[["normalize",function(e){var t;t=(t=e.src.replace(ba,"\n")).replace(_a,"<22>"),e.src=t}],["block",function(e){var t;e.inlineMode?((t=new e.Token("inline","",0)).content=e.src,t.map=[0,1],t.children=[],e.tokens.push(t)):e.md.block.parse(e.src,e.md,e.env,e.tokens)}],["inline",function(e){var t,n,r,i=e.tokens;for(n=0,r=i.length;n<r;n++)"inline"===(t=i[n]).type&&e.md.inline.parse(t.content,e.md,e.env,t.children)}],["linkify",function(e){var t,n,r,i,o,a,s,l,u,c,f,p,d,h,g,m,v,y,b=e.tokens;if(e.md.options.linkify)for(n=0,r=b.length;n<r;n++)if("inline"===b[n].type&&e.md.linkify.pretest(b[n].content))for(d=0,t=(i=b[n].children).length-1;t>=0;t--)if("link_close"!==(a=i[t]).type){if("html_inline"===a.type&&(y=a.content,/^<a[>\s]/i.test(y)&&d>0&&d--,xa(a.content)&&d++),!(d>0)&&"text"===a.type&&e.md.linkify.test(a.content)){for(u=a.content,v=e.md.linkify.match(u),s=[],p=a.level,f=0,l=0;l<v.length;l++)h=v[l].url,g=e.md.normalizeLink(h),e.md.validateLink(g)&&(m=v[l].text,m=v[l].schema?"mailto:"!==v[l].schema||/^mailto:/i.test(m)?e.md.normalizeLinkText(m):e.md.normalizeLinkText("mailto:"+m).replace(/^mailto:/,""):e.md.normalizeLinkText("http://"+m).replace(/^http:\/\//,""),(c=v[l].index)>f&&((o=new e.Token("text","",0)).content=u.slice(f,c),o.level=p,s.push(o)),(o=new e.Token("link_open","a",1)).attrs=[["href",g]],o.level=p++,o.markup="linkify",o.info="auto",s.push(o),(o=new e.Token("text","",0)).content=m,o.level=p,s.push(o),(o=new e.Token("link_close","a",-1)).level=--p,o.markup="linkify",o.info="auto",s.push(o),f=v[l].lastIndex);f<u.length&&((o=new e.Token("text","",0)).content=u.slice(f),o.level=p,s.push(o)),b[n].children=i=wa(i,t,s)}}else for(t--;i[t].level!==a.level&&"link_open"!==i[t].type;)t--}],["replacements",function(e){var t;if(e.md.options.typographer)for(t=e.tokens.length-1;t>=0;t--)"inline"===e.tokens[t].type&&(Ca.test(e.tokens[t].content)&&Sa(e.tokens[t].children),ka.test(e.tokens[t].content)&&ja(e.tokens[t].children))}],["smartquotes",function(e){var t;if(e.md.options.typographer)for(t=e.tokens.length-1;t>=0;t--)"inline"===e.tokens[t].type&&La.test(e.tokens[t].content)&&Fa(e.tokens[t].children,e)}]];function Ba(){this.ruler=new ya;for(var e=0;e<za.length;e++)this.ruler.push(za[e][0],za[e][1])}Ba.prototype.process=function(e){var t,n,r;for(t=0,n=(r=this.ruler.getRules("")).length;t<n;t++)r[t](e)},Ba.prototype.State=Ra;var Wa=Ba,Ha=sa.isSpace;function Ua(e,t){var n=e.bMarks[t]+e.tShift[t],r=e.eMarks[t];return e.src.substr(n,r-n)}function Va(e){var t,n=[],r=0,i=e.length,o=!1,a=0,s="";for(t=e.charCodeAt(r);r<i;)124===t&&(o?(s+=e.substring(a,r-1),a=r):(n.push(s+e.substring(a,r)),s="",a=r+1)),o=92===t,r++,t=e.charCodeAt(r);return n.push(s+e.substring(a)),n}var Ka=sa.isSpace,Ya=sa.isSpace,Ga=sa.isSpace;function Za(e,t){var n,r,i,o;return r=e.bMarks[t]+e.tShift[t],i=e.eMarks[t],42!==(n=e.src.charCodeAt(r++))&&45!==n&&43!==n||r<i&&(o=e.src.charCodeAt(r),!Ga(o))?-1:r}function Xa(e,t){var n,r=e.bMarks[t]+e.tShift[t],i=r,o=e.eMarks[t];if(i+1>=o)return-1;if((n=e.src.charCodeAt(i++))<48||n>57)return-1;for(;;){if(i>=o)return-1;if(!((n=e.src.charCodeAt(i++))>=48&&n<=57)){if(41===n||46===n)break;return-1}if(i-r>=10)return-1}return i<o&&(n=e.src.charCodeAt(i),!Ga(n))?-1:i}var Ja=sa.normalizeReference,Qa=sa.isSpace,es=sa.isSpace,ts="<[A-Za-z][A-Za-z0-9\\-]*(?:\\s+[a-zA-Z_:][a-zA-Z0-9:._-]*(?:\\s*=\\s*(?:[^\"'=<>`\\x00-\\x20]+|'[^']*'|\"[^\"]*\"))?)*\\s*\\/?>",ns="<\\/[A-Za-z][A-Za-z0-9\\-]*\\s*>",rs={HTML_TAG_RE:new RegExp("^(?:"+ts+"|"+ns+"|\x3c!----\x3e|\x3c!--(?:-?[^>-])(?:-?[^-])*--\x3e|<[?][\\s\\S]*?[?]>|<![A-Z]+\\s+[^>]*>|<!\\[CDATA\\[[\\s\\S]*?\\]\\]>)"),HTML_OPEN_CLOSE_TAG_RE:new RegExp("^(?:"+ts+"|"+ns+")")},is=rs.HTML_OPEN_CLOSE_TAG_RE,os=[[/^<(script|pre|style)(?=(\s|>|$))/i,/<\/(script|pre|style)>/i,!0],[/^<!--/,/-->/,!0],[/^<\?/,/\?>/,!0],[/^<![A-Z]/,/>/,!0],[/^<!\[CDATA\[/,/\]\]>/,!0],[new RegExp("^</?("+["address","article","aside","base","basefont","blockquote","body","caption","center","col","colgroup","dd","details","dialog","dir","div","dl","dt","fieldset","figcaption","figure","footer","form","frame","frameset","h1","h2","h3","h4","h5","h6","head","header","hr","html","iframe","legend","li","link","main","menu","menuitem","nav","noframes","ol","optgroup","option","p","param","section","source","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"].join("|")+")(?=(\\s|/?>|$))","i"),/^$/,!0],[new RegExp(is.source+"\\s*$"),/^$/,!1]],as=sa.isSpace;function ss(e,t,n,r){var i,o,a,s,l,u,c,f;for(this.src=e,this.md=t,this.env=n,this.tokens=r,this.bMarks=[],this.eMarks=[],this.tShift=[],this.sCount=[],this.bsCount=[],this.blkIndent=0,this.line=0,this.lineMax=0,this.tight=!1,this.ddIndent=-1,this.listIndent=-1,this.parentType="root",this.level=0,this.result="",f=!1,a=s=u=c=0,l=(o=this.src).length;s<l;s++){if(i=o.charCodeAt(s),!f){if(as(i)){u++,9===i?c+=4-c%4:c++;continue}f=!0}10!==i&&s!==l-1||(10!==i&&s++,this.bMarks.push(a),this.eMarks.push(s),this.tShift.push(u),this.sCount.push(c),this.bsCount.push(0),f=!1,u=0,c=0,a=s+1)}this.bMarks.push(o.length),this.eMarks.push(o.length),this.tShift.push(0),this.sCount.push(0),this.bsCount.push(0),this.lineMax=this.bMarks.length-1}ss.prototype.push=function(e,t,n){var r=new Ia(e,t,n);return r.block=!0,n<0&&this.level--,r.level=this.level,n>0&&this.level++,this.tokens.push(r),r},ss.prototype.isEmpty=function(e){return this.bMarks[e]+this.tShift[e]>=this.eMarks[e]},ss.prototype.skipEmptyLines=function(e){for(var t=this.lineMax;e<t&&!(this.bMarks[e]+this.tShift[e]<this.eMarks[e]);e++);return e},ss.prototype.skipSpaces=function(e){for(var t,n=this.src.length;e<n&&(t=this.src.charCodeAt(e),as(t));e++);return e},ss.prototype.skipSpacesBack=function(e,t){if(e<=t)return e;for(;e>t;)if(!as(this.src.charCodeAt(--e)))return e+1;return e},ss.prototype.skipChars=function(e,t){for(var n=this.src.length;e<n&&this.src.charCodeAt(e)===t;e++);return e},ss.prototype.skipCharsBack=function(e,t,n){if(e<=n)return e;for(;e>n;)if(t!==this.src.charCodeAt(--e))return e+1;return e},ss.prototype.getLines=function(e,t,n,r){var i,o,a,s,l,u,c,f=e;if(e>=t)return"";for(u=new Array(t-e),i=0;f<t;f++,i++){for(o=0,c=s=this.bMarks[f],l=f+1<t||r?this.eMarks[f]+1:this.eMarks[f];s<l&&o<n;){if(a=this.src.charCodeAt(s),as(a))9===a?o+=4-(o+this.bsCount[f])%4:o++;else{if(!(s-c<this.tShift[f]))break;o++}s++}u[i]=o>n?new Array(o-n+1).join(" ")+this.src.slice(s,l):this.src.slice(s,l)}return u.join("")},ss.prototype.Token=Ia;var ls=ss,us=[["table",function(e,t,n,r){var i,o,a,s,l,u,c,f,p,d,h,g,m,v,y,b;if(t+2>n)return!1;if(u=t+1,e.sCount[u]<e.blkIndent)return!1;if(e.sCount[u]-e.blkIndent>=4)return!1;if((a=e.bMarks[u]+e.tShift[u])>=e.eMarks[u])return!1;if(124!==(i=e.src.charCodeAt(a++))&&45!==i&&58!==i)return!1;for(;a<e.eMarks[u];){if(124!==(i=e.src.charCodeAt(a))&&45!==i&&58!==i&&!Ha(i))return!1;a++}for(c=(o=Ua(e,t+1)).split("|"),d=[],s=0;s<c.length;s++){if(!(h=c[s].trim())){if(0===s||s===c.length-1)continue;return!1}if(!/^:?-+:?$/.test(h))return!1;58===h.charCodeAt(h.length-1)?d.push(58===h.charCodeAt(0)?"center":"right"):58===h.charCodeAt(0)?d.push("left"):d.push("")}if(-1===(o=Ua(e,t).trim()).indexOf("|"))return!1;if(e.sCount[t]-e.blkIndent>=4)return!1;if((c=Va(o)).length&&""===c[0]&&c.shift(),c.length&&""===c[c.length-1]&&c.pop(),0===(f=c.length)||f!==d.length)return!1;if(r)return!0;for(v=e.parentType,e.parentType="table",b=e.md.block.ruler.getRules("blockquote"),(p=e.push("table_open","table",1)).map=g=[t,0],(p=e.push("thead_open","thead",1)).map=[t,t+1],(p=e.push("tr_open","tr",1)).map=[t,t+1],s=0;s<c.length;s++)p=e.push("th_open","th",1),d[s]&&(p.attrs=[["style","text-align:"+d[s]]]),(p=e.push("inline","",0)).content=c[s].trim(),p.children=[],p=e.push("th_close","th",-1);for(p=e.push("tr_close","tr",-1),p=e.push("thead_close","thead",-1),u=t+2;u<n&&!(e.sCount[u]<e.blkIndent);u++){for(y=!1,s=0,l=b.length;s<l;s++)if(b[s](e,u,n,!0)){y=!0;break}if(y)break;if(!(o=Ua(e,u).trim()))break;if(e.sCount[u]-e.blkIndent>=4)break;for((c=Va(o)).length&&""===c[0]&&c.shift(),c.length&&""===c[c.length-1]&&c.pop(),u===t+2&&((p=e.push("tbody_open","tbody",1)).map=m=[t+2,0]),(p=e.push("tr_open","tr",1)).map=[u,u+1],s=0;s<f;s++)p=e.push("td_open","td",1),d[s]&&(p.attrs=[["style","text-align:"+d[s]]]),(p=e.push("inline","",0)).content=c[s]?c[s].trim():"",p.children=[],p=e.push("td_close","td",-1);p=e.push("tr_close","tr",-1)}return m&&(p=e.push("tbody_close","tbody",-1),m[1]=u),p=e.push("table_close","table",-1),g[1]=u,e.parentType=v,e.line=u,!0},["paragraph","reference"]],["code",function(e,t,n){var r,i,o;if(e.sCount[t]-e.blkIndent<4)return!1;for(i=r=t+1;r<n;)if(e.isEmpty(r))r++;else{if(!(e.sCount[r]-e.blkIndent>=4))break;i=++r}return e.line=i,(o=e.push("code_block","code",0)).content=e.getLines(t,i,4+e.blkIndent,!0),o.map=[t,e.line],!0}],["fence",function(e,t,n,r){var i,o,a,s,l,u,c,f=!1,p=e.bMarks[t]+e.tShift[t],d=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;if(p+3>d)return!1;if(126!==(i=e.src.charCodeAt(p))&&96!==i)return!1;if(l=p,(o=(p=e.skipChars(p,i))-l)<3)return!1;if(c=e.src.slice(l,p),a=e.src.slice(p,d),96===i&&a.indexOf(String.fromCharCode(i))>=0)return!1;if(r)return!0;for(s=t;!(++s>=n)&&!((p=l=e.bMarks[s]+e.tShift[s])<(d=e.eMarks[s])&&e.sCount[s]<e.blkIndent);)if(e.src.charCodeAt(p)===i&&!(e.sCount[s]-e.blkIndent>=4||(p=e.skipChars(p,i))-l<o||(p=e.skipSpaces(p))<d)){f=!0;break}return o=e.sCount[t],e.line=s+(f?1:0),(u=e.push("fence","code",0)).info=a,u.content=e.getLines(t+1,s,o,!0),u.markup=c,u.map=[t,e.line],!0},["paragraph","reference","blockquote","list"]],["blockquote",function(e,t,n,r){var i,o,a,s,l,u,c,f,p,d,h,g,m,v,y,b,_,w,x,k,C=e.lineMax,E=e.bMarks[t]+e.tShift[t],O=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;if(62!==e.src.charCodeAt(E++))return!1;if(r)return!0;for(s=p=e.sCount[t]+1,32===e.src.charCodeAt(E)?(E++,s++,p++,i=!1,b=!0):9===e.src.charCodeAt(E)?(b=!0,(e.bsCount[t]+p)%4==3?(E++,s++,p++,i=!1):i=!0):b=!1,d=[e.bMarks[t]],e.bMarks[t]=E;E<O&&(o=e.src.charCodeAt(E),Ka(o));)9===o?p+=4-(p+e.bsCount[t]+(i?1:0))%4:p++,E++;for(h=[e.bsCount[t]],e.bsCount[t]=e.sCount[t]+1+(b?1:0),u=E>=O,v=[e.sCount[t]],e.sCount[t]=p-s,y=[e.tShift[t]],e.tShift[t]=E-e.bMarks[t],w=e.md.block.ruler.getRules("blockquote"),m=e.parentType,e.parentType="blockquote",f=t+1;f<n&&(k=e.sCount[f]<e.blkIndent,!((E=e.bMarks[f]+e.tShift[f])>=(O=e.eMarks[f])));f++)if(62!==e.src.charCodeAt(E++)||k){if(u)break;for(_=!1,a=0,l=w.length;a<l;a++)if(w[a](e,f,n,!0)){_=!0;break}if(_){e.lineMax=f,0!==e.blkIndent&&(d.push(e.bMarks[f]),h.push(e.bsCount[f]),y.push(e.tShift[f]),v.push(e.sCount[f]),e.sCount[f]-=e.blkIndent);break}d.push(e.bMarks[f]),h.push(e.bsCount[f]),y.push(e.tShift[f]),v.push(e.sCount[f]),e.sCount[f]=-1}else{for(s=p=e.sCount[f]+1,32===e.src.charCodeAt(E)?(E++,s++,p++,i=!1,b=!0):9===e.src.charCodeAt(E)?(b=!0,(e.bsCount[f]+p)%4==3?(E++,s++,p++,i=!1):i=!0):b=!1,d.push(e.bMarks[f]),e.bMarks[f]=E;E<O&&(o=e.src.charCodeAt(E),Ka(o));)9===o?p+=4-(p+e.bsCount[f]+(i?1:0))%4:p++,E++;u=E>=O,h.push(e.bsCount[f]),e.bsCount[f]=e.sCount[f]+1+(b?1:0),v.push(e.sCount[f]),e.sCount[f]=p-s,y.push(e.tShift[f]),e.tShift[f]=E-e.bMarks[f]}for(g=e.blkIndent,e.blkIndent=0,(x=e.push("blockquote_open","blockquote",1)).markup=">",x.map=c=[t,0],e.md.block.tokenize(e,t,f),(x=e.push("blockquote_close","blockquote",-1)).markup=">",e.lineMax=C,e.parentType=m,c[1]=e.line,a=0;a<y.length;a++)e.bMarks[a+t]=d[a],e.tShift[a+t]=y[a],e.sCount[a+t]=v[a],e.bsCount[a+t]=h[a];return e.blkIndent=g,!0},["paragraph","reference","blockquote","list"]],["hr",function(e,t,n,r){var i,o,a,s,l=e.bMarks[t]+e.tShift[t],u=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;if(42!==(i=e.src.charCodeAt(l++))&&45!==i&&95!==i)return!1;for(o=1;l<u;){if((a=e.src.charCodeAt(l++))!==i&&!Ya(a))return!1;a===i&&o++}return!(o<3)&&(r||(e.line=t+1,(s=e.push("hr","hr",0)).map=[t,e.line],s.markup=Array(o+1).join(String.fromCharCode(i))),!0)},["paragraph","reference","blockquote","list"]],["list",function(e,t,n,r){var i,o,a,s,l,u,c,f,p,d,h,g,m,v,y,b,_,w,x,k,C,E,O,A,S,j,T,D,N=!1,L=!0;if(e.sCount[t]-e.blkIndent>=4)return!1;if(e.listIndent>=0&&e.sCount[t]-e.listIndent>=4&&e.sCount[t]<e.blkIndent)return!1;if(r&&"paragraph"===e.parentType&&e.tShift[t]>=e.blkIndent&&(N=!0),(O=Xa(e,t))>=0){if(c=!0,S=e.bMarks[t]+e.tShift[t],m=Number(e.src.substr(S,O-S-1)),N&&1!==m)return!1}else{if(!((O=Za(e,t))>=0))return!1;c=!1}if(N&&e.skipSpaces(O)>=e.eMarks[t])return!1;if(g=e.src.charCodeAt(O-1),r)return!0;for(h=e.tokens.length,c?(D=e.push("ordered_list_open","ol",1),1!==m&&(D.attrs=[["start",m]])):D=e.push("bullet_list_open","ul",1),D.map=d=[t,0],D.markup=String.fromCharCode(g),y=t,A=!1,T=e.md.block.ruler.getRules("list"),w=e.parentType,e.parentType="list";y<n;){for(E=O,v=e.eMarks[y],u=b=e.sCount[y]+O-(e.bMarks[t]+e.tShift[t]);E<v;){if(9===(i=e.src.charCodeAt(E)))b+=4-(b+e.bsCount[y])%4;else{if(32!==i)break;b++}E++}if((l=(o=E)>=v?1:b-u)>4&&(l=1),s=u+l,(D=e.push("list_item_open","li",1)).markup=String.fromCharCode(g),D.map=f=[t,0],C=e.tight,k=e.tShift[t],x=e.sCount[t],_=e.listIndent,e.listIndent=e.blkIndent,e.blkIndent=s,e.tight=!0,e.tShift[t]=o-e.bMarks[t],e.sCount[t]=b,o>=v&&e.isEmpty(t+1)?e.line=Math.min(e.line+2,n):e.md.block.tokenize(e,t,n,!0),e.tight&&!A||(L=!1),A=e.line-t>1&&e.isEmpty(e.line-1),e.blkIndent=e.listIndent,e.listIndent=_,e.tShift[t]=k,e.sCount[t]=x,e.tight=C,(D=e.push("list_item_close","li",-1)).markup=String.fromCharCode(g),y=t=e.line,f[1]=y,o=e.bMarks[t],y>=n)break;if(e.sCount[y]<e.blkIndent)break;if(e.sCount[t]-e.blkIndent>=4)break;for(j=!1,a=0,p=T.length;a<p;a++)if(T[a](e,y,n,!0)){j=!0;break}if(j)break;if(c){if((O=Xa(e,y))<0)break}else if((O=Za(e,y))<0)break;if(g!==e.src.charCodeAt(O-1))break}return(D=c?e.push("ordered_list_close","ol",-1):e.push("bullet_list_close","ul",-1)).markup=String.fromCharCode(g),d[1]=y,e.line=y,e.parentType=w,L&&function(e,t){var n,r,i=e.level+2;for(n=t+2,r=e.tokens.length-2;n<r;n++)e.tokens[n].level===i&&"paragraph_open"===e.tokens[n].type&&(e.tokens[n+2].hidden=!0,e.tokens[n].hidden=!0,n+=2)}(e,h),!0},["paragraph","reference","blockquote"]],["reference",function(e,t,n,r){var i,o,a,s,l,u,c,f,p,d,h,g,m,v,y,b,_=0,w=e.bMarks[t]+e.tShift[t],x=e.eMarks[t],k=t+1;if(e.sCount[t]-e.blkIndent>=4)return!1;if(91!==e.src.charCodeAt(w))return!1;for(;++w<x;)if(93===e.src.charCodeAt(w)&&92!==e.src.charCodeAt(w-1)){if(w+1===x)return!1;if(58!==e.src.charCodeAt(w+1))return!1;break}for(s=e.lineMax,y=e.md.block.ruler.getRules("reference"),d=e.parentType,e.parentType="reference";k<s&&!e.isEmpty(k);k++)if(!(e.sCount[k]-e.blkIndent>3||e.sCount[k]<0)){for(v=!1,u=0,c=y.length;u<c;u++)if(y[u](e,k,s,!0)){v=!0;break}if(v)break}for(x=(m=e.getLines(t,k,e.blkIndent,!1).trim()).length,w=1;w<x;w++){if(91===(i=m.charCodeAt(w)))return!1;if(93===i){p=w;break}(10===i||92===i&&++w<x&&10===m.charCodeAt(w))&&_++}if(p<0||58!==m.charCodeAt(p+1))return!1;for(w=p+2;w<x;w++)if(10===(i=m.charCodeAt(w)))_++;else if(!Qa(i))break;if(!(h=e.md.helpers.parseLinkDestination(m,w,x)).ok)return!1;if(l=e.md.normalizeLink(h.str),!e.md.validateLink(l))return!1;for(o=w=h.pos,a=_+=h.lines,g=w;w<x;w++)if(10===(i=m.charCodeAt(w)))_++;else if(!Qa(i))break;for(h=e.md.helpers.parseLinkTitle(m,w,x),w<x&&g!==w&&h.ok?(b=h.str,w=h.pos,_+=h.lines):(b="",w=o,_=a);w<x&&(i=m.charCodeAt(w),Qa(i));)w++;if(w<x&&10!==m.charCodeAt(w)&&b)for(b="",w=o,_=a;w<x&&(i=m.charCodeAt(w),Qa(i));)w++;return!(w<x&&10!==m.charCodeAt(w))&&(!!(f=Ja(m.slice(1,p)))&&(r||(void 0===e.env.references&&(e.env.references={}),void 0===e.env.references[f]&&(e.env.references[f]={title:b,href:l}),e.parentType=d,e.line=t+_+1),!0))}],["heading",function(e,t,n,r){var i,o,a,s,l=e.bMarks[t]+e.tShift[t],u=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;if(35!==(i=e.src.charCodeAt(l))||l>=u)return!1;for(o=1,i=e.src.charCodeAt(++l);35===i&&l<u&&o<=6;)o++,i=e.src.charCodeAt(++l);return!(o>6||l<u&&!es(i))&&(r||(u=e.skipSpacesBack(u,l),(a=e.skipCharsBack(u,35,l))>l&&es(e.src.charCodeAt(a-1))&&(u=a),e.line=t+1,(s=e.push("heading_open","h"+String(o),1)).markup="########".slice(0,o),s.map=[t,e.line],(s=e.push("inline","",0)).content=e.src.slice(l,u).trim(),s.map=[t,e.line],s.children=[],(s=e.push("heading_close","h"+String(o),-1)).markup="########".slice(0,o)),!0)},["paragraph","reference","blockquote"]],["lheading",function(e,t,n){var r,i,o,a,s,l,u,c,f,p,d=t+1,h=e.md.block.ruler.getRules("paragraph");if(e.sCount[t]-e.blkIndent>=4)return!1;for(p=e.parentType,e.parentType="paragraph";d<n&&!e.isEmpty(d);d++)if(!(e.sCount[d]-e.blkIndent>3)){if(e.sCount[d]>=e.blkIndent&&(l=e.bMarks[d]+e.tShift[d])<(u=e.eMarks[d])&&(45===(f=e.src.charCodeAt(l))||61===f)&&(l=e.skipChars(l,f),(l=e.skipSpaces(l))>=u)){c=61===f?1:2;break}if(!(e.sCount[d]<0)){for(i=!1,o=0,a=h.length;o<a;o++)if(h[o](e,d,n,!0)){i=!0;break}if(i)break}}return!!c&&(r=e.getLines(t,d,e.blkIndent,!1).trim(),e.line=d+1,(s=e.push("heading_open","h"+String(c),1)).markup=String.fromCharCode(f),s.map=[t,e.line],(s=e.push("inline","",0)).content=r,s.map=[t,e.line-1],s.children=[],(s=e.push("heading_close","h"+String(c),-1)).markup=String.fromCharCode(f),e.parentType=p,!0)}],["html_block",function(e,t,n,r){var i,o,a,s,l=e.bMarks[t]+e.tShift[t],u=e.eMarks[t];if(e.sCount[t]-e.blkIndent>=4)return!1;if(!e.md.options.html)return!1;if(60!==e.src.charCodeAt(l))return!1;for(s=e.src.slice(l,u),i=0;i<os.length&&!os[i][0].test(s);i++);if(i===os.length)return!1;if(r)return os[i][2];if(o=t+1,!os[i][1].test(s))for(;o<n&&!(e.sCount[o]<e.blkIndent);o++)if(l=e.bMarks[o]+e.tShift[o],u=e.eMarks[o],s=e.src.slice(l,u),os[i][1].test(s)){0!==s.length&&o++;break}return e.line=o,(a=e.push("html_block","",0)).map=[t,o],a.content=e.getLines(t,o,e.blkIndent,!0),!0},["paragraph","reference","blockquote"]],["paragraph",function(e,t){var n,r,i,o,a,s,l=t+1,u=e.md.block.ruler.getRules("paragraph"),c=e.lineMax;for(s=e.parentType,e.parentType="paragraph";l<c&&!e.isEmpty(l);l++)if(!(e.sCount[l]-e.blkIndent>3||e.sCount[l]<0)){for(r=!1,i=0,o=u.length;i<o;i++)if(u[i](e,l,c,!0)){r=!0;break}if(r)break}return n=e.getLines(t,l,e.blkIndent,!1).trim(),e.line=l,(a=e.push("paragraph_open","p",1)).map=[t,e.line],(a=e.push("inline","",0)).content=n,a.map=[t,e.line],a.children=[],a=e.push("paragraph_close","p",-1),e.parentType=s,!0}]];function cs(){this.ruler=new ya;for(var e=0;e<us.length;e++)this.ruler.push(us[e][0],us[e][1],{alt:(us[e][2]||[]).slice()})}cs.prototype.tokenize=function(e,t,n){for(var r,i=this.ruler.getRules(""),o=i.length,a=t,s=!1,l=e.md.options.maxNesting;a<n&&(e.line=a=e.skipEmptyLines(a),!(a>=n))&&!(e.sCount[a]<e.blkIndent);){if(e.level>=l){e.line=n;break}for(r=0;r<o&&!i[r](e,a,n,!1);r++);e.tight=!s,e.isEmpty(e.line-1)&&(s=!0),(a=e.line)<n&&e.isEmpty(a)&&(s=!0,a++,e.line=a)}},cs.prototype.parse=function(e,t,n,r){var i;e&&(i=new this.State(e,t,n,r),this.tokenize(i,i.line,i.lineMax))},cs.prototype.State=ls;var fs=cs;function ps(e){switch(e){case 10:case 33:case 35:case 36:case 37:case 38:case 42:case 43:case 45:case 58:case 60:case 61:case 62:case 64:case 91:case 92:case 93:case 94:case 95:case 96:case 123:case 125:case 126:return!0;default:return!1}}for(var ds=sa.isSpace,hs=sa.isSpace,gs=[],ms=0;ms<256;ms++)gs.push(0);"\\!\"#$%&'()*+,./:;<=>?@[]^_`{|}~-".split("").forEach((function(e){gs[e.charCodeAt(0)]=1}));function vs(e,t){var n,r,i,o,a,s=[],l=t.length;for(n=0;n<l;n++)126===(i=t[n]).marker&&-1!==i.end&&(o=t[i.end],(a=e.tokens[i.token]).type="s_open",a.tag="s",a.nesting=1,a.markup="~~",a.content="",(a=e.tokens[o.token]).type="s_close",a.tag="s",a.nesting=-1,a.markup="~~",a.content="","text"===e.tokens[o.token-1].type&&"~"===e.tokens[o.token-1].content&&s.push(o.token-1));for(;s.length;){for(r=(n=s.pop())+1;r<e.tokens.length&&"s_close"===e.tokens[r].type;)r++;n!==--r&&(a=e.tokens[r],e.tokens[r]=e.tokens[n],e.tokens[n]=a)}}var ys={tokenize:function(e,t){var n,r,i,o,a=e.pos,s=e.src.charCodeAt(a);if(t)return!1;if(126!==s)return!1;if(i=(r=e.scanDelims(e.pos,!0)).length,o=String.fromCharCode(s),i<2)return!1;for(i%2&&(e.push("text","",0).content=o,i--),n=0;n<i;n+=2)e.push("text","",0).content=o+o,e.delimiters.push({marker:s,length:0,jump:n/2,token:e.tokens.length-1,end:-1,open:r.can_open,close:r.can_close});return e.pos+=r.length,!0},postProcess:function(e){var t,n=e.tokens_meta,r=e.tokens_meta.length;for(vs(e,e.delimiters),t=0;t<r;t++)n[t]&&n[t].delimiters&&vs(e,n[t].delimiters)}};function bs(e,t){var n,r,i,o,a,s;for(n=t.length-1;n>=0;n--)95!==(r=t[n]).marker&&42!==r.marker||-1!==r.end&&(i=t[r.end],s=n>0&&t[n-1].end===r.end+1&&t[n-1].token===r.token-1&&t[r.end+1].token===i.token+1&&t[n-1].marker===r.marker,a=String.fromCharCode(r.marker),(o=e.tokens[r.token]).type=s?"strong_open":"em_open",o.tag=s?"strong":"em",o.nesting=1,o.markup=s?a+a:a,o.content="",(o=e.tokens[i.token]).type=s?"strong_close":"em_close",o.tag=s?"strong":"em",o.nesting=-1,o.markup=s?a+a:a,o.content="",s&&(e.tokens[t[n-1].token].content="",e.tokens[t[r.end+1].token].content="",n--))}var _s={tokenize:function(e,t){var n,r,i=e.pos,o=e.src.charCodeAt(i);if(t)return!1;if(95!==o&&42!==o)return!1;for(r=e.scanDelims(e.pos,42===o),n=0;n<r.length;n++)e.push("text","",0).content=String.fromCharCode(o),e.delimiters.push({marker:o,length:r.length,jump:n,token:e.tokens.length-1,end:-1,open:r.can_open,close:r.can_close});return e.pos+=r.length,!0},postProcess:function(e){var t,n=e.tokens_meta,r=e.tokens_meta.length;for(bs(e,e.delimiters),t=0;t<r;t++)n[t]&&n[t].delimiters&&bs(e,n[t].delimiters)}},ws=sa.normalizeReference,xs=sa.isSpace,ks=sa.normalizeReference,Cs=sa.isSpace,Es=/^([a-zA-Z0-9.!#$%&'*+\/=?^_`{|}~-]+@[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?(?:\.[a-zA-Z0-9](?:[a-zA-Z0-9-]{0,61}[a-zA-Z0-9])?)*)$/,Os=/^([a-zA-Z][a-zA-Z0-9+.\-]{1,31}):([^<>\x00-\x20]*)$/,As=rs.HTML_TAG_RE;var Ss=sa.has,js=sa.isValidEntityCode,Ts=sa.fromCodePoint,Ds=/^&#((?:x[a-f0-9]{1,6}|[0-9]{1,7}));/i,Ns=/^&([a-z][a-z0-9]{1,31});/i;function Ls(e,t){var n,r,i,o,a,s,l,u,c={},f=t.length;for(n=0;n<f;n++)if((i=t[n]).length=i.length||0,i.close){for(c.hasOwnProperty(i.marker)||(c[i.marker]=[-1,-1,-1]),a=c[i.marker][i.length%3],(r=n-i.jump-1)<-1&&(r=-1),s=r;r>a;r-=o.jump+1)if((o=t[r]).marker===i.marker&&o.open&&o.end<0&&(l=!1,(o.close||i.open)&&(o.length+i.length)%3==0&&(o.length%3==0&&i.length%3==0||(l=!0)),!l)){u=r>0&&!t[r-1].open?t[r-1].jump+1:0,i.jump=n-r+u,i.open=!1,o.end=n,o.jump=u,o.close=!1,s=-1;break}-1!==s&&(c[i.marker][(i.length||0)%3]=s)}}var Ms=sa.isWhiteSpace,Ps=sa.isPunctChar,Fs=sa.isMdAsciiPunct;function qs(e,t,n,r){this.src=e,this.env=n,this.md=t,this.tokens=r,this.tokens_meta=Array(r.length),this.pos=0,this.posMax=this.src.length,this.level=0,this.pending="",this.pendingLevel=0,this.cache={},this.delimiters=[],this._prev_delimiters=[],this.backticks={},this.backticksScanned=!1}qs.prototype.pushPending=function(){var e=new Ia("text","",0);return e.content=this.pending,e.level=this.pendingLevel,this.tokens.push(e),this.pending="",e},qs.prototype.push=function(e,t,n){this.pending&&this.pushPending();var r=new Ia(e,t,n),i=null;return n<0&&(this.level--,this.delimiters=this._prev_delimiters.pop()),r.level=this.level,n>0&&(this.level++,this._prev_delimiters.push(this.delimiters),this.delimiters=[],i={delimiters:this.delimiters}),this.pendingLevel=this.level,this.tokens.push(r),this.tokens_meta.push(i),r},qs.prototype.scanDelims=function(e,t){var n,r,i,o,a,s,l,u,c,f=e,p=!0,d=!0,h=this.posMax,g=this.src.charCodeAt(e);for(n=e>0?this.src.charCodeAt(e-1):32;f<h&&this.src.charCodeAt(f)===g;)f++;return i=f-e,r=f<h?this.src.charCodeAt(f):32,l=Fs(n)||Ps(String.fromCharCode(n)),c=Fs(r)||Ps(String.fromCharCode(r)),s=Ms(n),(u=Ms(r))?p=!1:c&&(s||l||(p=!1)),s?d=!1:l&&(u||c||(d=!1)),t?(o=p,a=d):(o=p&&(!d||l),a=d&&(!p||c)),{can_open:o,can_close:a,length:i}},qs.prototype.Token=Ia;var Is=qs,$s=[["text",function(e,t){for(var n=e.pos;n<e.posMax&&!ps(e.src.charCodeAt(n));)n++;return n!==e.pos&&(t||(e.pending+=e.src.slice(e.pos,n)),e.pos=n,!0)}],["newline",function(e,t){var n,r,i=e.pos;if(10!==e.src.charCodeAt(i))return!1;for(n=e.pending.length-1,r=e.posMax,t||(n>=0&&32===e.pending.charCodeAt(n)?n>=1&&32===e.pending.charCodeAt(n-1)?(e.pending=e.pending.replace(/ +$/,""),e.push("hardbreak","br",0)):(e.pending=e.pending.slice(0,-1),e.push("softbreak","br",0)):e.push("softbreak","br",0)),i++;i<r&&ds(e.src.charCodeAt(i));)i++;return e.pos=i,!0}],["escape",function(e,t){var n,r=e.pos,i=e.posMax;if(92!==e.src.charCodeAt(r))return!1;if(++r<i){if((n=e.src.charCodeAt(r))<256&&0!==gs[n])return t||(e.pending+=e.src[r]),e.pos+=2,!0;if(10===n){for(t||e.push("hardbreak","br",0),r++;r<i&&(n=e.src.charCodeAt(r),hs(n));)r++;return e.pos=r,!0}}return t||(e.pending+="\\"),e.pos++,!0}],["backticks",function(e,t){var n,r,i,o,a,s,l,u,c=e.pos;if(96!==e.src.charCodeAt(c))return!1;for(n=c,c++,r=e.posMax;c<r&&96===e.src.charCodeAt(c);)c++;if(l=(i=e.src.slice(n,c)).length,e.backticksScanned&&(e.backticks[l]||0)<=n)return t||(e.pending+=i),e.pos+=l,!0;for(a=s=c;-1!==(a=e.src.indexOf("`",s));){for(s=a+1;s<r&&96===e.src.charCodeAt(s);)s++;if((u=s-a)===l)return t||((o=e.push("code_inline","code",0)).markup=i,o.content=e.src.slice(c,a).replace(/\n/g," ").replace(/^ (.+) $/,"$1")),e.pos=s,!0;e.backticks[u]=a}return e.backticksScanned=!0,t||(e.pending+=i),e.pos+=l,!0}],["strikethrough",ys.tokenize],["emphasis",_s.tokenize],["link",function(e,t){var n,r,i,o,a,s,l,u,c="",f="",p=e.pos,d=e.posMax,h=e.pos,g=!0;if(91!==e.src.charCodeAt(e.pos))return!1;if(a=e.pos+1,(o=e.md.helpers.parseLinkLabel(e,e.pos,!0))<0)return!1;if((s=o+1)<d&&40===e.src.charCodeAt(s)){for(g=!1,s++;s<d&&(r=e.src.charCodeAt(s),xs(r)||10===r);s++);if(s>=d)return!1;if(h=s,(l=e.md.helpers.parseLinkDestination(e.src,s,e.posMax)).ok){for(c=e.md.normalizeLink(l.str),e.md.validateLink(c)?s=l.pos:c="",h=s;s<d&&(r=e.src.charCodeAt(s),xs(r)||10===r);s++);if(l=e.md.helpers.parseLinkTitle(e.src,s,e.posMax),s<d&&h!==s&&l.ok)for(f=l.str,s=l.pos;s<d&&(r=e.src.charCodeAt(s),xs(r)||10===r);s++);}(s>=d||41!==e.src.charCodeAt(s))&&(g=!0),s++}if(g){if(void 0===e.env.references)return!1;if(s<d&&91===e.src.charCodeAt(s)?(h=s+1,(s=e.md.helpers.parseLinkLabel(e,s))>=0?i=e.src.slice(h,s++):s=o+1):s=o+1,i||(i=e.src.slice(a,o)),!(u=e.env.references[ws(i)]))return e.pos=p,!1;c=u.href,f=u.title}return t||(e.pos=a,e.posMax=o,e.push("link_open","a",1).attrs=n=[["href",c]],f&&n.push(["title",f]),e.md.inline.tokenize(e),e.push("link_close","a",-1)),e.pos=s,e.posMax=d,!0}],["image",function(e,t){var n,r,i,o,a,s,l,u,c,f,p,d,h,g="",m=e.pos,v=e.posMax;if(33!==e.src.charCodeAt(e.pos))return!1;if(91!==e.src.charCodeAt(e.pos+1))return!1;if(s=e.pos+2,(a=e.md.helpers.parseLinkLabel(e,e.pos+1,!1))<0)return!1;if((l=a+1)<v&&40===e.src.charCodeAt(l)){for(l++;l<v&&(r=e.src.charCodeAt(l),Cs(r)||10===r);l++);if(l>=v)return!1;for(h=l,(c=e.md.helpers.parseLinkDestination(e.src,l,e.posMax)).ok&&(g=e.md.normalizeLink(c.str),e.md.validateLink(g)?l=c.pos:g=""),h=l;l<v&&(r=e.src.charCodeAt(l),Cs(r)||10===r);l++);if(c=e.md.helpers.parseLinkTitle(e.src,l,e.posMax),l<v&&h!==l&&c.ok)for(f=c.str,l=c.pos;l<v&&(r=e.src.charCodeAt(l),Cs(r)||10===r);l++);else f="";if(l>=v||41!==e.src.charCodeAt(l))return e.pos=m,!1;l++}else{if(void 0===e.env.references)return!1;if(l<v&&91===e.src.charCodeAt(l)?(h=l+1,(l=e.md.helpers.parseLinkLabel(e,l))>=0?o=e.src.slice(h,l++):l=a+1):l=a+1,o||(o=e.src.slice(s,a)),!(u=e.env.references[ks(o)]))return e.pos=m,!1;g=u.href,f=u.title}return t||(i=e.src.slice(s,a),e.md.inline.parse(i,e.md,e.env,d=[]),(p=e.push("image","img",0)).attrs=n=[["src",g],["alt",""]],p.children=d,p.content=i,f&&n.push(["title",f])),e.pos=l,e.posMax=v,!0}],["autolink",function(e,t){var n,r,i,o,a,s,l=e.pos;if(60!==e.src.charCodeAt(l))return!1;for(a=e.pos,s=e.posMax;;){if(++l>=s)return!1;if(60===(o=e.src.charCodeAt(l)))return!1;if(62===o)break}return n=e.src.slice(a+1,l),Os.test(n)?(r=e.md.normalizeLink(n),!!e.md.validateLink(r)&&(t||((i=e.push("link_open","a",1)).attrs=[["href",r]],i.markup="autolink",i.info="auto",(i=e.push("text","",0)).content=e.md.normalizeLinkText(n),(i=e.push("link_close","a",-1)).markup="autolink",i.info="auto"),e.pos+=n.length+2,!0)):!!Es.test(n)&&(r=e.md.normalizeLink("mailto:"+n),!!e.md.validateLink(r)&&(t||((i=e.push("link_open","a",1)).attrs=[["href",r]],i.markup="autolink",i.info="auto",(i=e.push("text","",0)).content=e.md.normalizeLinkText(n),(i=e.push("link_close","a",-1)).markup="autolink",i.info="auto"),e.pos+=n.length+2,!0))}],["html_inline",function(e,t){var n,r,i,o=e.pos;return!!e.md.options.html&&(i=e.posMax,!(60!==e.src.charCodeAt(o)||o+2>=i)&&(!(33!==(n=e.src.charCodeAt(o+1))&&63!==n&&47!==n&&!function(e){var t=32|e;return t>=97&&t<=122}(n))&&(!!(r=e.src.slice(o).match(As))&&(t||(e.push("html_inline","",0).content=e.src.slice(o,o+r[0].length)),e.pos+=r[0].length,!0))))}],["entity",function(e,t){var n,r,i=e.pos,o=e.posMax;if(38!==e.src.charCodeAt(i))return!1;if(i+1<o)if(35===e.src.charCodeAt(i+1)){if(r=e.src.slice(i).match(Ds))return t||(n="x"===r[1][0].toLowerCase()?parseInt(r[1].slice(1),16):parseInt(r[1],10),e.pending+=js(n)?Ts(n):Ts(65533)),e.pos+=r[0].length,!0}else if((r=e.src.slice(i).match(Ns))&&Ss(Fo,r[1]))return t||(e.pending+=Fo[r[1]]),e.pos+=r[0].length,!0;return t||(e.pending+="&"),e.pos++,!0}]],Rs=[["balance_pairs",function(e){var t,n=e.tokens_meta,r=e.tokens_meta.length;for(Ls(0,e.delimiters),t=0;t<r;t++)n[t]&&n[t].delimiters&&Ls(0,n[t].delimiters)}],["strikethrough",ys.postProcess],["emphasis",_s.postProcess],["text_collapse",function(e){var t,n,r=0,i=e.tokens,o=e.tokens.length;for(t=n=0;t<o;t++)i[t].nesting<0&&r--,i[t].level=r,i[t].nesting>0&&r++,"text"===i[t].type&&t+1<o&&"text"===i[t+1].type?i[t+1].content=i[t].content+i[t+1].content:(t!==n&&(i[n]=i[t]),n++);t!==n&&(i.length=n)}]];function zs(){var e;for(this.ruler=new ya,e=0;e<$s.length;e++)this.ruler.push($s[e][0],$s[e][1]);for(this.ruler2=new ya,e=0;e<Rs.length;e++)this.ruler2.push(Rs[e][0],Rs[e][1])}zs.prototype.skipToken=function(e){var t,n,r=e.pos,i=this.ruler.getRules(""),o=i.length,a=e.md.options.maxNesting,s=e.cache;if(void 0===s[r]){if(e.level<a)for(n=0;n<o&&(e.level++,t=i[n](e,!0),e.level--,!t);n++);else e.pos=e.posMax;t||e.pos++,s[r]=e.pos}else e.pos=s[r]},zs.prototype.tokenize=function(e){for(var t,n,r=this.ruler.getRules(""),i=r.length,o=e.posMax,a=e.md.options.maxNesting;e.pos<o;){if(e.level<a)for(n=0;n<i&&!(t=r[n](e,!1));n++);if(t){if(e.pos>=o)break}else e.pending+=e.src[e.pos++]}e.pending&&e.pushPending()},zs.prototype.parse=function(e,t,n,r){var i,o,a,s=new this.State(e,t,n,r);for(this.tokenize(s),a=(o=this.ruler2.getRules("")).length,i=0;i<a;i++)o[i](s)},zs.prototype.State=Is;var Bs=zs;function Ws(e){var t=Array.prototype.slice.call(arguments,1);return t.forEach((function(t){t&&Object.keys(t).forEach((function(n){e[n]=t[n]}))})),e}function Hs(e){return Object.prototype.toString.call(e)}function Us(e){return"[object Function]"===Hs(e)}function Vs(e){return e.replace(/[.?*+^$[\]\\(){}|-]/g,"\\$&")}var Ks={fuzzyLink:!0,fuzzyEmail:!0,fuzzyIP:!1};var Ys={"http:":{validate:function(e,t,n){var r=e.slice(t);return n.re.http||(n.re.http=new RegExp("^\\/\\/"+n.re.src_auth+n.re.src_host_port_strict+n.re.src_path,"i")),n.re.http.test(r)?r.match(n.re.http)[0].length:0}},"https:":"http:","ftp:":"http:","//":{validate:function(e,t,n){var r=e.slice(t);return n.re.no_http||(n.re.no_http=new RegExp("^"+n.re.src_auth+"(?:localhost|(?:(?:"+n.re.src_domain+")\\.)+"+n.re.src_domain_root+")"+n.re.src_port+n.re.src_host_terminator+n.re.src_path,"i")),n.re.no_http.test(r)?t>=3&&":"===e[t-3]||t>=3&&"/"===e[t-3]?0:r.match(n.re.no_http)[0].length:0}},"mailto:":{validate:function(e,t,n){var r=e.slice(t);return n.re.mailto||(n.re.mailto=new RegExp("^"+n.re.src_email_name+"@"+n.re.src_host_strict,"i")),n.re.mailto.test(r)?r.match(n.re.mailto)[0].length:0}}},Gs="biz|com|edu|gov|net|org|pro|web|xxx|aero|asia|coop|info|museum|name|shop|рф".split("|");function Zs(e){var t,n,r=e.re=(t=e.__opts__,(n={}).src_Any=ra.source,n.src_Cc=ia.source,n.src_Z=oa.source,n.src_P=qo.source,n.src_ZPCc=[n.src_Z,n.src_P,n.src_Cc].join("|"),n.src_ZCc=[n.src_Z,n.src_Cc].join("|"),n.src_pseudo_letter="(?:(?![><]|"+n.src_ZPCc+")"+n.src_Any+")",n.src_ip4="(?:(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\\.){3}(25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)",n.src_auth="(?:(?:(?!"+n.src_ZCc+"|[@/\\[\\]()]).)+@)?",n.src_port="(?::(?:6(?:[0-4]\\d{3}|5(?:[0-4]\\d{2}|5(?:[0-2]\\d|3[0-5])))|[1-5]?\\d{1,4}))?",n.src_host_terminator="(?=$|[><]|"+n.src_ZPCc+")(?!-|_|:\\d|\\.-|\\.(?!$|"+n.src_ZPCc+"))",n.src_path="(?:[/?#](?:(?!"+n.src_ZCc+"|[><]|[()[\\]{}.,\"'?!\\-]).|\\[(?:(?!"+n.src_ZCc+"|\\]).)*\\]|\\((?:(?!"+n.src_ZCc+"|[)]).)*\\)|\\{(?:(?!"+n.src_ZCc+'|[}]).)*\\}|\\"(?:(?!'+n.src_ZCc+'|["]).)+\\"|\\\'(?:(?!'+n.src_ZCc+"|[']).)+\\'|\\'(?="+n.src_pseudo_letter+"|[-]).|\\.{2,}[a-zA-Z0-9%/&]|\\.(?!"+n.src_ZCc+"|[.]).|"+(t&&t["---"]?"\\-(?!--(?:[^-]|$))(?:-*)|":"\\-+|")+"\\,(?!"+n.src_ZCc+").|\\!+(?!"+n.src_ZCc+"|[!]).|\\?(?!"+n.src_ZCc+"|[?]).)+|\\/)?",n.src_email_name='[\\-;:&=\\+\\$,\\.a-zA-Z0-9_][\\-;:&=\\+\\$,\\"\\.a-zA-Z0-9_]*',n.src_xn="xn--[a-z0-9\\-]{1,59}",n.src_domain_root="(?:"+n.src_xn+"|"+n.src_pseudo_letter+"{1,63})",n.src_domain="(?:"+n.src_xn+"|(?:"+n.src_pseudo_letter+")|(?:"+n.src_pseudo_letter+"(?:-|"+n.src_pseudo_letter+"){0,61}"+n.src_pseudo_letter+"))",n.src_host="(?:(?:(?:(?:"+n.src_domain+")\\.)*"+n.src_domain+"))",n.tpl_host_fuzzy="(?:"+n.src_ip4+"|(?:(?:(?:"+n.src_domain+")\\.)+(?:%TLDS%)))",n.tpl_host_no_ip_fuzzy="(?:(?:(?:"+n.src_domain+")\\.)+(?:%TLDS%))",n.src_host_strict=n.src_host+n.src_host_terminator,n.tpl_host_fuzzy_strict=n.tpl_host_fuzzy+n.src_host_terminator,n.src_host_port_strict=n.src_host+n.src_port+n.src_host_terminator,n.tpl_host_port_fuzzy_strict=n.tpl_host_fuzzy+n.src_port+n.src_host_terminator,n.tpl_host_port_no_ip_fuzzy_strict=n.tpl_host_no_ip_fuzzy+n.src_port+n.src_host_terminator,n.tpl_host_fuzzy_test="localhost|www\\.|\\.\\d{1,3}\\.|(?:\\.(?:%TLDS%)(?:"+n.src_ZPCc+"|>|$))",n.tpl_email_fuzzy='(^|[><]|"|\\(|'+n.src_ZCc+")("+n.src_email_name+"@"+n.tpl_host_fuzzy_strict+")",n.tpl_link_fuzzy="(^|(?![.:/\\-_@])(?:[$+<=>^`|]|"+n.src_ZPCc+"))((?![$+<=>^`|])"+n.tpl_host_port_fuzzy_strict+n.src_path+")",n.tpl_link_no_ip_fuzzy="(^|(?![.:/\\-_@])(?:[$+<=>^`|]|"+n.src_ZPCc+"))((?![$+<=>^`|])"+n.tpl_host_port_no_ip_fuzzy_strict+n.src_path+")",n),i=e.__tlds__.slice();function o(e){return e.replace("%TLDS%",r.src_tlds)}e.onCompile(),e.__tlds_replaced__||i.push("a[cdefgilmnoqrstuwxz]|b[abdefghijmnorstvwyz]|c[acdfghiklmnoruvwxyz]|d[ejkmoz]|e[cegrstu]|f[ijkmor]|g[abdefghilmnpqrstuwy]|h[kmnrtu]|i[delmnoqrst]|j[emop]|k[eghimnprwyz]|l[abcikrstuvy]|m[acdeghklmnopqrstuvwxyz]|n[acefgilopruz]|om|p[aefghklmnrstwy]|qa|r[eosuw]|s[abcdeghijklmnortuvxyz]|t[cdfghjklmnortvwz]|u[agksyz]|v[aceginu]|w[fs]|y[et]|z[amw]"),i.push(r.src_xn),r.src_tlds=i.join("|"),r.email_fuzzy=RegExp(o(r.tpl_email_fuzzy),"i"),r.link_fuzzy=RegExp(o(r.tpl_link_fuzzy),"i"),r.link_no_ip_fuzzy=RegExp(o(r.tpl_link_no_ip_fuzzy),"i"),r.host_fuzzy_test=RegExp(o(r.tpl_host_fuzzy_test),"i");var a=[];function s(e,t){throw new Error('(LinkifyIt) Invalid schema "'+e+'": '+t)}e.__compiled__={},Object.keys(e.__schemas__).forEach((function(t){var n=e.__schemas__[t];if(null!==n){var r={validate:null,link:null};if(e.__compiled__[t]=r,"[object Object]"===Hs(n))return!function(e){return"[object RegExp]"===Hs(e)}(n.validate)?Us(n.validate)?r.validate=n.validate:s(t,n):r.validate=function(e){return function(t,n){var r=t.slice(n);return e.test(r)?r.match(e)[0].length:0}}(n.validate),void(Us(n.normalize)?r.normalize=n.normalize:n.normalize?s(t,n):r.normalize=function(e,t){t.normalize(e)});!function(e){return"[object String]"===Hs(e)}(n)?s(t,n):a.push(t)}})),a.forEach((function(t){e.__compiled__[e.__schemas__[t]]&&(e.__compiled__[t].validate=e.__compiled__[e.__schemas__[t]].validate,e.__compiled__[t].normalize=e.__compiled__[e.__schemas__[t]].normalize)})),e.__compiled__[""]={validate:null,normalize:function(e,t){t.normalize(e)}};var l=Object.keys(e.__compiled__).filter((function(t){return t.length>0&&e.__compiled__[t]})).map(Vs).join("|");e.re.schema_test=RegExp("(^|(?!_)(?:[><]|"+r.src_ZPCc+"))("+l+")","i"),e.re.schema_search=RegExp("(^|(?!_)(?:[><]|"+r.src_ZPCc+"))("+l+")","ig"),e.re.pretest=RegExp("("+e.re.schema_test.source+")|("+e.re.host_fuzzy_test.source+")|@","i"),function(e){e.__index__=-1,e.__text_cache__=""}(e)}function Xs(e,t){var n=e.__index__,r=e.__last_index__,i=e.__text_cache__.slice(n,r);this.schema=e.__schema__.toLowerCase(),this.index=n+t,this.lastIndex=r+t,this.raw=i,this.text=i,this.url=i}function Js(e,t){var n=new Xs(e,t);return e.__compiled__[n.schema].normalize(n,e),n}function Qs(e,t){if(!(this instanceof Qs))return new Qs(e,t);var n;t||(n=e,Object.keys(n||{}).reduce((function(e,t){return e||Ks.hasOwnProperty(t)}),!1)&&(t=e,e={})),this.__opts__=Ws({},Ks,t),this.__index__=-1,this.__last_index__=-1,this.__schema__="",this.__text_cache__="",this.__schemas__=Ws({},Ys,e),this.__compiled__={},this.__tlds__=Gs,this.__tlds_replaced__=!1,this.re={},Zs(this)}Qs.prototype.add=function(e,t){return this.__schemas__[e]=t,Zs(this),this},Qs.prototype.set=function(e){return this.__opts__=Ws(this.__opts__,e),this},Qs.prototype.test=function(e){if(this.__text_cache__=e,this.__index__=-1,!e.length)return!1;var t,n,r,i,o,a,s,l;if(this.re.schema_test.test(e))for((s=this.re.schema_search).lastIndex=0;null!==(t=s.exec(e));)if(i=this.testSchemaAt(e,t[2],s.lastIndex)){this.__schema__=t[2],this.__index__=t.index+t[1].length,this.__last_index__=t.index+t[0].length+i;break}return this.__opts__.fuzzyLink&&this.__compiled__["http:"]&&(l=e.search(this.re.host_fuzzy_test))>=0&&(this.__index__<0||l<this.__index__)&&null!==(n=e.match(this.__opts__.fuzzyIP?this.re.link_fuzzy:this.re.link_no_ip_fuzzy))&&(o=n.index+n[1].length,(this.__index__<0||o<this.__index__)&&(this.__schema__="",this.__index__=o,this.__last_index__=n.index+n[0].length)),this.__opts__.fuzzyEmail&&this.__compiled__["mailto:"]&&e.indexOf("@")>=0&&null!==(r=e.match(this.re.email_fuzzy))&&(o=r.index+r[1].length,a=r.index+r[0].length,(this.__index__<0||o<this.__index__||o===this.__index__&&a>this.__last_index__)&&(this.__schema__="mailto:",this.__index__=o,this.__last_index__=a)),this.__index__>=0},Qs.prototype.pretest=function(e){return this.re.pretest.test(e)},Qs.prototype.testSchemaAt=function(e,t,n){return this.__compiled__[t.toLowerCase()]?this.__compiled__[t.toLowerCase()].validate(e,n,this):0},Qs.prototype.match=function(e){var t=0,n=[];this.__index__>=0&&this.__text_cache__===e&&(n.push(Js(this,t)),t=this.__last_index__);for(var r=t?e.slice(t):e;this.test(r);)n.push(Js(this,t)),r=r.slice(this.__last_index__),t+=this.__last_index__;return n.length?n:null},Qs.prototype.tlds=function(e,t){return e=Array.isArray(e)?e:[e],t?(this.__tlds__=this.__tlds__.concat(e).sort().filter((function(e,t,n){return e!==n[t-1]})).reverse(),Zs(this),this):(this.__tlds__=e.slice(),this.__tlds_replaced__=!0,Zs(this),this)},Qs.prototype.normalize=function(e){e.schema||(e.url="http://"+e.url),"mailto:"!==e.schema||/^mailto:/i.test(e.url)||(e.url="mailto:"+e.url)},Qs.prototype.onCompile=function(){};var el=Qs;const tl=2147483647,nl=/^xn--/,rl=/[^\0-\x7E]/,il=/[\x2E\u3002\uFF0E\uFF61]/g,ol={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},al=Math.floor,sl=String.fromCharCode;function ll(e){throw new RangeError(ol[e])}function ul(e,t){const n=e.split("@");let r="";n.length>1&&(r=n[0]+"@",e=n[1]);const i=function(e,t){const n=[];let r=e.length;for(;r--;)n[r]=t(e[r]);return n}((e=e.replace(il,".")).split("."),t).join(".");return r+i}function cl(e){const t=[];let n=0;const r=e.length;for(;n<r;){const i=e.charCodeAt(n++);if(i>=55296&&i<=56319&&n<r){const r=e.charCodeAt(n++);56320==(64512&r)?t.push(((1023&i)<<10)+(1023&r)+65536):(t.push(i),n--)}else t.push(i)}return t}const fl=e=>String.fromCodePoint(...e),pl=function(e,t){return e+22+75*(e<26)-((0!=t)<<5)},dl=function(e,t,n){let r=0;for(e=n?al(e/700):e>>1,e+=al(e/t);e>455;r+=36)e=al(e/35);return al(r+36*e/(e+38))},hl=function(e){const t=[],n=e.length;let r=0,i=128,o=72,a=e.lastIndexOf("-");a<0&&(a=0);for(let l=0;l<a;++l)e.charCodeAt(l)>=128&&ll("not-basic"),t.push(e.charCodeAt(l));for(let l=a>0?a+1:0;l<n;){let a=r;for(let t=1,i=36;;i+=36){l>=n&&ll("invalid-input");const a=(s=e.charCodeAt(l++))-48<10?s-22:s-65<26?s-65:s-97<26?s-97:36;(a>=36||a>al((tl-r)/t))&&ll("overflow"),r+=a*t;const u=i<=o?1:i>=o+26?26:i-o;if(a<u)break;const c=36-u;t>al(tl/c)&&ll("overflow"),t*=c}const u=t.length+1;o=dl(r-a,u,0==a),al(r/u)>tl-i&&ll("overflow"),i+=al(r/u),r%=u,t.splice(r++,0,i)}var s;return String.fromCodePoint(...t)},gl=function(e){const t=[];let n=(e=cl(e)).length,r=128,i=0,o=72;for(const l of e)l<128&&t.push(sl(l));let a=t.length,s=a;for(a&&t.push("-");s<n;){let n=tl;for(const t of e)t>=r&&t<n&&(n=t);const l=s+1;n-r>al((tl-i)/l)&&ll("overflow"),i+=(n-r)*l,r=n;for(const u of e)if(u<r&&++i>tl&&ll("overflow"),u==r){let e=i;for(let n=36;;n+=36){const r=n<=o?1:n>=o+26?26:n-o;if(e<r)break;const i=e-r,a=36-r;t.push(sl(pl(r+i%a,0))),e=al(i/a)}t.push(sl(pl(e,0))),o=dl(i,l,s==a),i=0,++s}++i,++r}return t.join("")},ml=function(e){return ul(e,(function(e){return nl.test(e)?hl(e.slice(4).toLowerCase()):e}))},vl=function(e){return ul(e,(function(e){return rl.test(e)?"xn--"+gl(e):e}))},yl={version:"2.1.0",ucs2:{decode:cl,encode:fl},decode:hl,encode:gl,toASCII:vl,toUnicode:ml};var bl=Hn(Object.freeze({__proto__:null,[Symbol.toStringTag]:"Module",ucs2decode:cl,ucs2encode:fl,decode:hl,encode:gl,toASCII:vl,toUnicode:ml,default:yl})),_l={default:{options:{html:!1,xhtmlOut:!1,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"“”‘’",highlight:null,maxNesting:100},components:{core:{},block:{},inline:{}}},zero:{options:{html:!1,xhtmlOut:!1,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"“”‘’",highlight:null,maxNesting:20},components:{core:{rules:["normalize","block","inline"]},block:{rules:["paragraph"]},inline:{rules:["text"],rules2:["balance_pairs","text_collapse"]}}},commonmark:{options:{html:!0,xhtmlOut:!0,breaks:!1,langPrefix:"language-",linkify:!1,typographer:!1,quotes:"“”‘’",highlight:null,maxNesting:20},components:{core:{rules:["normalize","block","inline"]},block:{rules:["blockquote","code","fence","heading","hr","html_block","lheading","list","reference","paragraph"]},inline:{rules:["autolink","backticks","emphasis","entity","escape","html_inline","image","link","newline","text"],rules2:["balance_pairs","emphasis","text_collapse"]}}}},wl=/^(vbscript|javascript|file|data):/,xl=/^data:image\/(gif|png|jpeg|webp);/;function kl(e){var t=e.trim().toLowerCase();return!wl.test(t)||!!xl.test(t)}var Cl=["http:","https:","mailto:"];function El(e){var t=na.parse(e,!0);if(t.hostname&&(!t.protocol||Cl.indexOf(t.protocol)>=0))try{t.hostname=bl.toASCII(t.hostname)}catch(n){}return na.encode(na.format(t))}function Ol(e){var t=na.parse(e,!0);if(t.hostname&&(!t.protocol||Cl.indexOf(t.protocol)>=0))try{t.hostname=bl.toUnicode(t.hostname)}catch(n){}return na.decode(na.format(t),na.decode.defaultChars+"%")}function Al(e,t){if(!(this instanceof Al))return new Al(e,t);t||sa.isString(e)||(t=e||{},e="default"),this.inline=new Bs,this.block=new fs,this.core=new Wa,this.renderer=new ma,this.linkify=new el,this.validateLink=kl,this.normalizeLink=El,this.normalizeLinkText=Ol,this.utils=sa,this.helpers=sa.assign({},ca),this.options={},this.configure(e),t&&this.set(t)}Al.prototype.set=function(e){return sa.assign(this.options,e),this},Al.prototype.configure=function(e){var t,n=this;if(sa.isString(e)&&!(e=_l[t=e]))throw new Error('Wrong `markdown-it` preset "'+t+'", check name');if(!e)throw new Error("Wrong `markdown-it` preset, can't be empty");return e.options&&n.set(e.options),e.components&&Object.keys(e.components).forEach((function(t){e.components[t].rules&&n[t].ruler.enableOnly(e.components[t].rules),e.components[t].rules2&&n[t].ruler2.enableOnly(e.components[t].rules2)})),this},Al.prototype.enable=function(e,t){var n=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach((function(t){n=n.concat(this[t].ruler.enable(e,!0))}),this),n=n.concat(this.inline.ruler2.enable(e,!0));var r=e.filter((function(e){return n.indexOf(e)<0}));if(r.length&&!t)throw new Error("MarkdownIt. Failed to enable unknown rule(s): "+r);return this},Al.prototype.disable=function(e,t){var n=[];Array.isArray(e)||(e=[e]),["core","block","inline"].forEach((function(t){n=n.concat(this[t].ruler.disable(e,!0))}),this),n=n.concat(this.inline.ruler2.disable(e,!0));var r=e.filter((function(e){return n.indexOf(e)<0}));if(r.length&&!t)throw new Error("MarkdownIt. Failed to disable unknown rule(s): "+r);return this},Al.prototype.use=function(e){var t=[this].concat(Array.prototype.slice.call(arguments,1));return e.apply(e,t),this},Al.prototype.parse=function(e,t){if("string"!=typeof e)throw new Error("Input data should be a String");var n=new this.core.State(e,this,t);return this.core.process(n),n.tokens},Al.prototype.render=function(e,t){return t=t||{},this.renderer.render(this.parse(e,t),this.options,t)},Al.prototype.parseInline=function(e,t){var n=new this.core.State(e,this,t);return n.inlineMode=!0,this.core.process(n),n.tokens},Al.prototype.renderInline=function(e,t){return t=t||{},this.renderer.render(this.parseInline(e,t),this.options,t)};var Sl=Al,jl=Object.freeze(Object.assign(Object.create(null),Sl,{[Symbol.toStringTag]:"Module",default:Sl}));function Tl(e,t){return Array(t+1).join(e)}var Dl=["ADDRESS","ARTICLE","ASIDE","AUDIO","BLOCKQUOTE","BODY","CANVAS","CENTER","DD","DIR","DIV","DL","DT","FIELDSET","FIGCAPTION","FIGURE","FOOTER","FORM","FRAMESET","H1","H2","H3","H4","H5","H6","HEADER","HGROUP","HR","HTML","ISINDEX","LI","MAIN","MENU","NAV","NOFRAMES","NOSCRIPT","OL","OUTPUT","P","PRE","SECTION","TABLE","TBODY","TD","TFOOT","TH","THEAD","TR","UL"];function Nl(e){return Fl(e,Dl)}var Ll=["AREA","BASE","BR","COL","COMMAND","EMBED","HR","IMG","INPUT","KEYGEN","LINK","META","PARAM","SOURCE","TRACK","WBR"];function Ml(e){return Fl(e,Ll)}var Pl=["A","TABLE","THEAD","TBODY","TFOOT","TH","TD","IFRAME","SCRIPT","AUDIO","VIDEO"];function Fl(e,t){return t.indexOf(e.nodeName)>=0}function ql(e,t){return e.getElementsByTagName&&t.some((function(t){return e.getElementsByTagName(t).length}))}var Il={};function $l(e){return e?e.replace(/(\n+\s*)+/g,"\n"):""}function Rl(e){for(var t in this.options=e,this._keep=[],this._remove=[],this.blankRule={replacement:e.blankReplacement},this.keepReplacement=e.keepReplacement,this.defaultRule={replacement:e.defaultReplacement},this.array=[],e.rules)this.array.push(e.rules[t])}function zl(e,t,n){for(var r=0;r<e.length;r++){var i=e[r];if(Bl(i,t,n))return i}}function Bl(e,t,n){var r=e.filter;if("string"==typeof r){if(r===t.nodeName.toLowerCase())return!0}else if(Array.isArray(r)){if(r.indexOf(t.nodeName.toLowerCase())>-1)return!0}else{if("function"!=typeof r)throw new TypeError("`filter` needs to be a string, array, or function");if(r.call(e,t,n))return!0}}function Wl(e){var t=e.nextSibling||e.parentNode;return e.parentNode.removeChild(e),t}function Hl(e,t,n){return e&&e.parentNode===t||n(t)?t.nextSibling||t.parentNode:t.firstChild||t.nextSibling||t.parentNode}Il.paragraph={filter:"p",replacement:function(e){return"\n\n"+e+"\n\n"}},Il.lineBreak={filter:"br",replacement:function(e,t,n){return n.br+"\n"}},Il.heading={filter:["h1","h2","h3","h4","h5","h6"],replacement:function(e,t,n){var r=Number(t.nodeName.charAt(1));return"setext"===n.headingStyle&&r<3?"\n\n"+e+"\n"+Tl(1===r?"=":"-",e.length)+"\n\n":"\n\n"+Tl("#",r)+" "+e+"\n\n"}},Il.blockquote={filter:"blockquote",replacement:function(e){return"\n\n"+(e=(e=e.replace(/^\n+|\n+$/g,"")).replace(/^/gm,"> "))+"\n\n"}},Il.list={filter:["ul","ol"],replacement:function(e,t){var n=t.parentNode;return"LI"===n.nodeName&&n.lastElementChild===t?"\n"+e:"\n\n"+e+"\n\n"}},Il.listItem={filter:"li",replacement:function(e,t,n){e=e.replace(/^\n+/,"").replace(/\n+$/,"\n").replace(/\n/gm,"\n ");var r=n.bulletListMarker+" ",i=t.parentNode;if("OL"===i.nodeName){var o=i.getAttribute("start"),a=Array.prototype.indexOf.call(i.children,t);r=(o?Number(o)+a:a+1)+". "}return r+e+(t.nextSibling&&!/\n$/.test(e)?"\n":"")}},Il.indentedCodeBlock={filter:function(e,t){return"indented"===t.codeBlockStyle&&"PRE"===e.nodeName&&e.firstChild&&"CODE"===e.firstChild.nodeName},replacement:function(e,t,n){return"\n\n "+t.firstChild.textContent.replace(/\n/g,"\n ")+"\n\n"}},Il.fencedCodeBlock={filter:function(e,t){return"fenced"===t.codeBlockStyle&&"PRE"===e.nodeName&&e.firstChild&&"CODE"===e.firstChild.nodeName},replacement:function(e,t,n){for(var r,i=((t.firstChild.getAttribute("class")||"").match(/language-(\S+)/)||[null,""])[1],o=t.firstChild.textContent,a=n.fence.charAt(0),s=3,l=new RegExp("^"+a+"{3,}","gm");r=l.exec(o);)r[0].length>=s&&(s=r[0].length+1);var u=Tl(a,s);return"\n\n"+u+i+"\n"+o.replace(/\n$/,"")+"\n"+u+"\n\n"}},Il.horizontalRule={filter:"hr",replacement:function(e,t,n){return"\n\n"+n.hr+"\n\n"}},Il.inlineLink={filter:function(e,t){return"inlined"===t.linkStyle&&"A"===e.nodeName&&e.getAttribute("href")},replacement:function(e,t){var n=t.getAttribute("href"),r=$l(t.getAttribute("title"));return r&&(r=' "'+r+'"'),"["+e+"]("+n+r+")"}},Il.referenceLink={filter:function(e,t){return"referenced"===t.linkStyle&&"A"===e.nodeName&&e.getAttribute("href")},replacement:function(e,t,n){var r,i,o=t.getAttribute("href"),a=$l(t.getAttribute("title"));switch(a&&(a=' "'+a+'"'),n.linkReferenceStyle){case"collapsed":r="["+e+"][]",i="["+e+"]: "+o+a;break;case"shortcut":r="["+e+"]",i="["+e+"]: "+o+a;break;default:var s=this.references.length+1;r="["+e+"]["+s+"]",i="["+s+"]: "+o+a}return this.references.push(i),r},references:[],append:function(e){var t="";return this.references.length&&(t="\n\n"+this.references.join("\n")+"\n\n",this.references=[]),t}},Il.emphasis={filter:["em","i"],replacement:function(e,t,n){return e.trim()?n.emDelimiter+e+n.emDelimiter:""}},Il.strong={filter:["strong","b"],replacement:function(e,t,n){return e.trim()?n.strongDelimiter+e+n.strongDelimiter:""}},Il.code={filter:function(e){var t=e.previousSibling||e.nextSibling,n="PRE"===e.parentNode.nodeName&&!t;return"CODE"===e.nodeName&&!n},replacement:function(e){if(!e.trim())return"";var t="`",n="",r="",i=e.match(/`+/gm);if(i)for(/^`/.test(e)&&(n=" "),/`$/.test(e)&&(r=" ");-1!==i.indexOf(t);)t+="`";return t+n+e+r+t}},Il.image={filter:"img",replacement:function(e,t){var n=$l(t.getAttribute("alt")),r=t.getAttribute("src")||"",i=$l(t.getAttribute("title"));return r?"!["+n+"]("+r+(i?' "'+i+'"':"")+")":""}},Rl.prototype={add:function(e,t){this.array.unshift(t)},keep:function(e){this._keep.unshift({filter:e,replacement:this.keepReplacement})},remove:function(e){this._remove.unshift({filter:e,replacement:function(){return""}})},forNode:function(e){return e.isBlank?this.blankRule:(t=zl(this.array,e,this.options))||(t=zl(this._keep,e,this.options))||(t=zl(this._remove,e,this.options))?t:this.defaultRule;var t},forEach:function(e){for(var t=0;t<this.array.length;t++)e(this.array[t],t)}};var Ul="undefined"!=typeof window?window:{};var Vl,Kl,Yl,Gl=function(){var e=Ul.DOMParser,t=!1;try{(new e).parseFromString("","text/html")&&(t=!0)}catch(n){}return t}()?Ul.DOMParser:(Vl=function(){},Kl=require("domino"),Vl.prototype.parseFromString=function(e){return Kl.createDocument(e)},Vl);function Zl(e){var t;"string"==typeof e?t=(Yl=Yl||new Gl).parseFromString('<x-turndown id="turndown-root">'+e+"</x-turndown>","text/html").getElementById("turndown-root"):t=e.cloneNode(!0);return function(e){var t=e.element,n=e.isBlock,r=e.isVoid,i=e.isPre||function(e){return"PRE"===e.nodeName};if(t.firstChild&&!i(t)){for(var o=null,a=!1,s=null,l=Hl(s,t,i);l!==t;){if(3===l.nodeType||4===l.nodeType){var u=l.data.replace(/[ \r\n\t]+/g," ");if(o&&!/ $/.test(o.data)||a||" "!==u[0]||(u=u.substr(1)),!u){l=Wl(l);continue}l.data=u,o=l}else{if(1!==l.nodeType){l=Wl(l);continue}n(l)||"BR"===l.nodeName?(o&&(o.data=o.data.replace(/ $/,"")),o=null,a=!1):r(l)&&(o=null,a=!0)}var c=Hl(s,l,i);s=l,l=c}o&&(o.data=o.data.replace(/ $/,""),o.data||Wl(o))}}({element:t,isBlock:Nl,isVoid:Ml}),t}function Xl(e){return e.isBlock=Nl(e),e.isCode="code"===e.nodeName.toLowerCase()||e.parentNode.isCode,e.isBlank=function(e){return!Ml(e)&&!function(e){return Fl(e,Pl)}(e)&&/^\s*$/i.test(e.textContent)&&!function(e){return ql(e,Ll)}(e)&&!function(e){return ql(e,Pl)}(e)}(e),e.flankingWhitespace=function(e){var t="",n="";if(!e.isBlock){var r=/^\s/.test(e.textContent),i=/\s$/.test(e.textContent),o=e.isBlank&&r&&i;r&&!Jl("left",e)&&(t=" "),o||!i||Jl("right",e)||(n=" ")}return{leading:t,trailing:n}}(e),e}function Jl(e,t){var n,r,i;return"left"===e?(n=t.previousSibling,r=/ $/):(n=t.nextSibling,r=/^ /),n&&(3===n.nodeType?i=r.test(n.nodeValue):1!==n.nodeType||Nl(n)||(i=r.test(n.textContent))),i}var Ql=Array.prototype.reduce,eu=/^\n*/,tu=/\n*$/,nu=[[/\\/g,"\\\\"],[/\*/g,"\\*"],[/^-/g,"\\-"],[/^\+ /g,"\\+ "],[/^(=+)/g,"\\$1"],[/^(#{1,6}) /g,"\\$1 "],[/`/g,"\\`"],[/^~~~/g,"\\~~~"],[/\[/g,"\\["],[/\]/g,"\\]"],[/^>/g,"\\>"],[/_/g,"\\_"],[/^(\d+)\. /g,"$1\\. "]];function ru(e){if(!(this instanceof ru))return new ru(e);var t={rules:Il,headingStyle:"setext",hr:"* * *",bulletListMarker:"*",codeBlockStyle:"indented",fence:"```",emDelimiter:"_",strongDelimiter:"**",linkStyle:"inlined",linkReferenceStyle:"full",br:" ",blankReplacement:function(e,t){return t.isBlock?"\n\n":""},keepReplacement:function(e,t){return t.isBlock?"\n\n"+t.outerHTML+"\n\n":t.outerHTML},defaultReplacement:function(e,t){return t.isBlock?"\n\n"+e+"\n\n":e}};this.options=function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)n.hasOwnProperty(r)&&(e[r]=n[r])}return e}({},t,e),this.rules=new Rl(this.options)}function iu(e){var t=this;return Ql.call(e.childNodes,(function(e,n){var r="";return 3===(n=new Xl(n)).nodeType?r=n.isCode?n.nodeValue:t.escape(n.nodeValue):1===n.nodeType&&(r=au.call(t,n)),su(e,r)}),"")}function ou(e){var t=this;return this.rules.forEach((function(n){"function"==typeof n.append&&(e=su(e,n.append(t.options)))})),e.replace(/^[\t\r\n]+/,"").replace(/[\t\r\n\s]+$/,"")}function au(e){var t=this.rules.forNode(e),n=iu.call(this,e),r=e.flankingWhitespace;return(r.leading||r.trailing)&&(n=n.trim()),r.leading+t.replacement(n,e,this.options)+r.trailing}function su(e,t){var n,r,i,o=(n=t,r=[e.match(tu)[0],n.match(eu)[0]].sort(),(i=r[r.length-1]).length<2?i:"\n\n");return(e=e.replace(tu,""))+o+(t=t.replace(eu,""))}function lu(e){const t=e-1;return t*t*t+1}function uu(e,{delay:t=0,duration:n=400,easing:r=s}={}){const i=+getComputedStyle(e).opacity;return{delay:t,duration:n,easing:r,css:e=>"opacity: "+e*i}}function cu(e,{delay:t=0,duration:n=400,easing:r=lu,x:i=0,y:o=0,opacity:a=0}={}){const s=getComputedStyle(e),l=+s.opacity,u="none"===s.transform?"":s.transform,c=l*(1-a);return{delay:t,duration:n,easing:r,css:(e,t)=>`\n\t\t\ttransform: ${u} translate(${(1-e)*i}px, ${(1-e)*o}px);\n\t\t\topacity: ${l-c*t}`}}function fu(e,{delay:t=0,duration:n=400,easing:r=lu}={}){const i=getComputedStyle(e),o=+i.opacity,a=parseFloat(i.height),s=parseFloat(i.paddingTop),l=parseFloat(i.paddingBottom),u=parseFloat(i.marginTop),c=parseFloat(i.marginBottom),f=parseFloat(i.borderTopWidth),p=parseFloat(i.borderBottomWidth);return{delay:t,duration:n,easing:r,css:e=>`overflow: hidden;opacity: ${Math.min(20*e,1)*o};height: ${e*a}px;padding-top: ${e*s}px;padding-bottom: ${e*l}px;margin-top: ${e*u}px;margin-bottom: ${e*c}px;border-top-width: ${e*f}px;border-bottom-width: ${e*p}px;`}}function pu(e){let t,n;const r=e[3].default,i=v(r,e,e[2],null);return{c(){t=P("div"),i&&i.c()},l(e){t=Y(e,"DIV",{});var n=K(t);i&&i.l(n),n.forEach(L)},m(r,o){N(r,t,o),i&&i.m(t,null),e[4](t),n=!0},p(e,[t]){i&&i.p&&4&t&&b(i,r,e,e[2],t,null,null)},i(e){n||(Ue(i,e),n=!0)},o(e){Ve(i,e),n=!1},d(n){n&&L(t),i&&i.d(n),e[4](null)}}}function du(e,t,n){let r,i,o,{$$slots:a={},$$scope:s}=t,{target:l=document.body}=t;return ve((()=>{if("string"==typeof l){if(r=document.querySelector(l),null===r)return()=>{}}else{if(!(l instanceof HTMLElement))throw new TypeError(`Unknown target type: ${typeof l}. Allowed types: String (CSS selector), HTMLElement.`);r=l}return i=document.createElement("div"),r.appendChild(i),i.appendChild(o),()=>{r.removeChild(i)}})),e.$$set=e=>{"target"in e&&n(1,l=e.target),"$$scope"in e&&n(2,s=e.$$scope)},[o,l,s,a,function(e){Ee[e?"unshift":"push"]((()=>{o=e,n(0,o)}))}]}ru.prototype={turndown:function(e){if(!function(e){return null!=e&&("string"==typeof e||e.nodeType&&(1===e.nodeType||9===e.nodeType||11===e.nodeType))}(e))throw new TypeError(e+" is not a string, or an element/document/fragment node.");if(""===e)return"";var t=iu.call(this,new Zl(e));return ou.call(this,t)},use:function(e){if(Array.isArray(e))for(var t=0;t<e.length;t++)this.use(e[t]);else{if("function"!=typeof e)throw new TypeError("plugin must be a Function or an Array of Functions");e(this)}return this},addRule:function(e,t){return this.rules.add(e,t),this},keep:function(e){return this.rules.keep(e),this},remove:function(e){return this.rules.remove(e),this},escape:function(e){return nu.reduce((function(e,t){return e.replace(t[0],t[1])}),e)}};class hu extends pt{constructor(e){super(),ft(this,e,du,pu,d,{target:1})}}const gu=["onChange","onClose","onDayCreate","onDestroy","onKeyDown","onMonthChange","onOpen","onParseConfig","onReady","onValueUpdate","onYearChange","onPreCalendarPosition"],mu={_disable:[],allowInput:!1,allowInvalidPreload:!1,altFormat:"F j, Y",altInput:!1,altInputClass:"form-control input",animate:"object"==typeof window&&-1===window.navigator.userAgent.indexOf("MSIE"),ariaDateFormat:"F j, Y",autoFillDefaultTime:!0,clickOpens:!0,closeOnSelect:!0,conjunction:", ",dateFormat:"Y-m-d",defaultHour:12,defaultMinute:0,defaultSeconds:0,disable:[],disableMobile:!1,enableSeconds:!1,enableTime:!1,errorHandler:e=>"undefined"!=typeof console&&console.warn(e),getWeek:e=>{const t=new Date(e.getTime());t.setHours(0,0,0,0),t.setDate(t.getDate()+3-(t.getDay()+6)%7);var n=new Date(t.getFullYear(),0,4);return 1+Math.round(((t.getTime()-n.getTime())/864e5-3+(n.getDay()+6)%7)/7)},hourIncrement:1,ignoredFocusElements:[],inline:!1,locale:"default",minuteIncrement:5,mode:"single",monthSelectorType:"dropdown",nextArrow:"<svg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' viewBox='0 0 17 17'><g></g><path d='M13.207 8.472l-7.854 7.854-0.707-0.707 7.146-7.146-7.146-7.148 0.707-0.707 7.854 7.854z' /></svg>",noCalendar:!1,now:new Date,onChange:[],onClose:[],onDayCreate:[],onDestroy:[],onKeyDown:[],onMonthChange:[],onOpen:[],onParseConfig:[],onReady:[],onValueUpdate:[],onYearChange:[],onPreCalendarPosition:[],plugins:[],position:"auto",positionElement:void 0,prevArrow:"<svg version='1.1' xmlns='http://www.w3.org/2000/svg' xmlns:xlink='http://www.w3.org/1999/xlink' viewBox='0 0 17 17'><g></g><path d='M5.207 8.471l7.146 7.147-0.707 0.707-7.853-7.854 7.854-7.853 0.707 0.707-7.147 7.146z' /></svg>",shorthandCurrentMonth:!1,showMonths:1,static:!1,time_24hr:!1,weekNumbers:!1,wrap:!1},vu={weekdays:{shorthand:["Sun","Mon","Tue","Wed","Thu","Fri","Sat"],longhand:["Sunday","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday"]},months:{shorthand:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],longhand:["January","February","March","April","May","June","July","August","September","October","November","December"]},daysInMonth:[31,28,31,30,31,30,31,31,30,31,30,31],firstDayOfWeek:0,ordinal:e=>{const t=e%100;if(t>3&&t<21)return"th";switch(t%10){case 1:return"st";case 2:return"nd";case 3:return"rd";default:return"th"}},rangeSeparator:" to ",weekAbbreviation:"Wk",scrollTitle:"Scroll to increment",toggleTitle:"Click to toggle",amPM:["AM","PM"],yearAriaLabel:"Year",monthAriaLabel:"Month",hourAriaLabel:"Hour",minuteAriaLabel:"Minute",time_24hr:!1},yu=(e,t=2)=>`000${e}`.slice(-1*t),bu=e=>!0===e?1:0;function _u(e,t){let n;return function(){clearTimeout(n),n=setTimeout((()=>e.apply(this,arguments)),t)}}const wu=e=>e instanceof Array?e:[e];function xu(e,t,n){if(!0===n)return e.classList.add(t);e.classList.remove(t)}function ku(e,t,n){const r=window.document.createElement(e);return t=t||"",n=n||"",r.className=t,void 0!==n&&(r.textContent=n),r}function Cu(e){for(;e.firstChild;)e.removeChild(e.firstChild)}function Eu(e,t){return t(e)?e:e.parentNode?Eu(e.parentNode,t):void 0}function Ou(e,t){const n=ku("div","numInputWrapper"),r=ku("input","numInput "+e),i=ku("span","arrowUp"),o=ku("span","arrowDown");if(-1===navigator.userAgent.indexOf("MSIE 9.0")?r.type="number":(r.type="text",r.pattern="\\d*"),void 0!==t)for(const a in t)r.setAttribute(a,t[a]);return n.appendChild(r),n.appendChild(i),n.appendChild(o),n}function Au(e){try{if("function"==typeof e.composedPath){return e.composedPath()[0]}return e.target}catch(Vr){return e.target}}const Su=()=>{},ju=(e,t,n)=>n.months[t?"shorthand":"longhand"][e],Tu={D:Su,F:function(e,t,n){e.setMonth(n.months.longhand.indexOf(t))},G:(e,t)=>{e.setHours(parseFloat(t))},H:(e,t)=>{e.setHours(parseFloat(t))},J:(e,t)=>{e.setDate(parseFloat(t))},K:(e,t,n)=>{e.setHours(e.getHours()%12+12*bu(new RegExp(n.amPM[1],"i").test(t)))},M:function(e,t,n){e.setMonth(n.months.shorthand.indexOf(t))},S:(e,t)=>{e.setSeconds(parseFloat(t))},U:(e,t)=>new Date(1e3*parseFloat(t)),W:function(e,t,n){const r=parseInt(t),i=new Date(e.getFullYear(),0,2+7*(r-1),0,0,0,0);return i.setDate(i.getDate()-i.getDay()+n.firstDayOfWeek),i},Y:(e,t)=>{e.setFullYear(parseFloat(t))},Z:(e,t)=>new Date(t),d:(e,t)=>{e.setDate(parseFloat(t))},h:(e,t)=>{e.setHours(parseFloat(t))},i:(e,t)=>{e.setMinutes(parseFloat(t))},j:(e,t)=>{e.setDate(parseFloat(t))},l:Su,m:(e,t)=>{e.setMonth(parseFloat(t)-1)},n:(e,t)=>{e.setMonth(parseFloat(t)-1)},s:(e,t)=>{e.setSeconds(parseFloat(t))},u:(e,t)=>new Date(parseFloat(t)),w:Su,y:(e,t)=>{e.setFullYear(2e3+parseFloat(t))}},Du={D:"(\\w+)",F:"(\\w+)",G:"(\\d\\d|\\d)",H:"(\\d\\d|\\d)",J:"(\\d\\d|\\d)\\w+",K:"",M:"(\\w+)",S:"(\\d\\d|\\d)",U:"(.+)",W:"(\\d\\d|\\d)",Y:"(\\d{4})",Z:"(.+)",d:"(\\d\\d|\\d)",h:"(\\d\\d|\\d)",i:"(\\d\\d|\\d)",j:"(\\d\\d|\\d)",l:"(\\w+)",m:"(\\d\\d|\\d)",n:"(\\d\\d|\\d)",s:"(\\d\\d|\\d)",u:"(.+)",w:"(\\d\\d|\\d)",y:"(\\d{2})"},Nu={Z:e=>e.toISOString(),D:function(e,t,n){return t.weekdays.shorthand[Nu.w(e,t,n)]},F:function(e,t,n){return ju(Nu.n(e,t,n)-1,!1,t)},G:function(e,t,n){return yu(Nu.h(e,t,n))},H:e=>yu(e.getHours()),J:function(e,t){return void 0!==t.ordinal?e.getDate()+t.ordinal(e.getDate()):e.getDate()},K:(e,t)=>t.amPM[bu(e.getHours()>11)],M:function(e,t){return ju(e.getMonth(),!0,t)},S:e=>yu(e.getSeconds()),U:e=>e.getTime()/1e3,W:function(e,t,n){return n.getWeek(e)},Y:e=>yu(e.getFullYear(),4),d:e=>yu(e.getDate()),h:e=>e.getHours()%12?e.getHours()%12:12,i:e=>yu(e.getMinutes()),j:e=>e.getDate(),l:function(e,t){return t.weekdays.longhand[e.getDay()]},m:e=>yu(e.getMonth()+1),n:e=>e.getMonth()+1,s:e=>e.getSeconds(),u:e=>e.getTime(),w:e=>e.getDay(),y:e=>String(e.getFullYear()).substring(2)},Lu=({config:e=mu,l10n:t=vu,isMobile:n=!1})=>(r,i,o)=>{const a=o||t;return void 0===e.formatDate||n?i.split("").map(((t,n,i)=>Nu[t]&&"\\"!==i[n-1]?Nu[t](r,a,e):"\\"!==t?t:"")).join(""):e.formatDate(r,i,a)},Mu=({config:e=mu,l10n:t=vu})=>(n,r,i,o)=>{if(0!==n&&!n)return;const a=o||t;let s;const l=n;if(n instanceof Date)s=new Date(n.getTime());else if("string"!=typeof n&&void 0!==n.toFixed)s=new Date(n);else if("string"==typeof n){const t=r||(e||mu).dateFormat,o=String(n).trim();if("today"===o)s=new Date,i=!0;else if(/Z$/.test(o)||/GMT$/.test(o))s=new Date(n);else if(e&&e.parseDate)s=e.parseDate(n,t);else{s=e&&e.noCalendar?new Date((new Date).setHours(0,0,0,0)):new Date((new Date).getFullYear(),0,1,0,0,0,0);let r,i=[];for(let e=0,o=0,l="";e<t.length;e++){const u=t[e],c="\\"===u,f="\\"===t[e-1]||c;if(Du[u]&&!f){l+=Du[u];const e=new RegExp(l).exec(n);e&&(r=!0)&&i["Y"!==u?"push":"unshift"]({fn:Tu[u],val:e[++o]})}else c||(l+=".");i.forEach((({fn:e,val:t})=>s=e(s,t,a)||s))}s=r?s:void 0}}if(s instanceof Date&&!isNaN(s.getTime()))return!0===i&&s.setHours(0,0,0,0),s;e.errorHandler(new Error(`Invalid date provided: ${l}`))};function Pu(e,t,n=!0){return!1!==n?new Date(e.getTime()).setHours(0,0,0,0)-new Date(t.getTime()).setHours(0,0,0,0):e.getTime()-t.getTime()}const Fu=864e5;function qu(e){let t=e.defaultHour,n=e.defaultMinute,r=e.defaultSeconds;if(void 0!==e.minDate){const i=e.minDate.getHours(),o=e.minDate.getMinutes(),a=e.minDate.getSeconds();t<i&&(t=i),t===i&&n<o&&(n=o),t===i&&n===o&&r<a&&(r=e.minDate.getSeconds())}if(void 0!==e.maxDate){const i=e.maxDate.getHours(),o=e.maxDate.getMinutes();t=Math.min(t,i),t===i&&(n=Math.min(o,n)),t===i&&n===o&&(r=e.maxDate.getSeconds())}return{hours:t,minutes:n,seconds:r}}"function"!=typeof Object.assign&&(Object.assign=function(e,...t){if(!e)throw TypeError("Cannot convert undefined or null to object");for(const n of t)n&&Object.keys(n).forEach((t=>e[t]=n[t]));return e});function Iu(e,t){const n={config:Object.assign(Object.assign({},mu),Ru.defaultConfig),l10n:vu};function r(e){return e.bind(n)}function i(){const e=n.config;!1===e.weekNumbers&&1===e.showMonths||!0!==e.noCalendar&&window.requestAnimationFrame((function(){if(void 0!==n.calendarContainer&&(n.calendarContainer.style.visibility="hidden",n.calendarContainer.style.display="block"),void 0!==n.daysContainer){const t=(n.days.offsetWidth+1)*e.showMonths;n.daysContainer.style.width=t+"px",n.calendarContainer.style.width=t+(void 0!==n.weekWrapper?n.weekWrapper.offsetWidth:0)+"px",n.calendarContainer.style.removeProperty("visibility"),n.calendarContainer.style.removeProperty("display")}}))}function o(e){if(0===n.selectedDates.length){const e=void 0===n.config.minDate||Pu(new Date,n.config.minDate)>=0?new Date:new Date(n.config.minDate.getTime()),t=qu(n.config);e.setHours(t.hours,t.minutes,t.seconds,e.getMilliseconds()),n.selectedDates=[e],n.latestSelectedDateObj=e}void 0!==e&&"blur"!==e.type&&function(e){e.preventDefault();const t="keydown"===e.type,r=Au(e),i=r;void 0!==n.amPM&&r===n.amPM&&(n.amPM.textContent=n.l10n.amPM[bu(n.amPM.textContent===n.l10n.amPM[0])]);const o=parseFloat(i.getAttribute("min")),a=parseFloat(i.getAttribute("max")),s=parseFloat(i.getAttribute("step")),l=parseInt(i.value,10),u=e.delta||(t?38===e.which?1:-1:0);let c=l+s*u;if(void 0!==i.value&&2===i.value.length){const e=i===n.hourElement,t=i===n.minuteElement;c<o?(c=a+c+bu(!e)+(bu(e)&&bu(!n.amPM)),t&&h(void 0,-1,n.hourElement)):c>a&&(c=i===n.hourElement?c-a-bu(!n.amPM):o,t&&h(void 0,1,n.hourElement)),n.amPM&&e&&(1===s?c+l===23:Math.abs(c-l)>s)&&(n.amPM.textContent=n.l10n.amPM[bu(n.amPM.textContent===n.l10n.amPM[0])]),i.value=yu(c)}}(e);const t=n._input.value;a(),X(),n._input.value!==t&&n._debouncedChange()}function a(){if(void 0===n.hourElement||void 0===n.minuteElement)return;let e=(parseInt(n.hourElement.value.slice(-2),10)||0)%24,t=(parseInt(n.minuteElement.value,10)||0)%60,r=void 0!==n.secondElement?(parseInt(n.secondElement.value,10)||0)%60:0;var i,o;void 0!==n.amPM&&(i=e,o=n.amPM.textContent,e=i%12+12*bu(o===n.l10n.amPM[1]));const a=void 0!==n.config.minTime||n.config.minDate&&n.minDateHasTime&&n.latestSelectedDateObj&&0===Pu(n.latestSelectedDateObj,n.config.minDate,!0);if(void 0!==n.config.maxTime||n.config.maxDate&&n.maxDateHasTime&&n.latestSelectedDateObj&&0===Pu(n.latestSelectedDateObj,n.config.maxDate,!0)){const i=void 0!==n.config.maxTime?n.config.maxTime:n.config.maxDate;e=Math.min(e,i.getHours()),e===i.getHours()&&(t=Math.min(t,i.getMinutes())),t===i.getMinutes()&&(r=Math.min(r,i.getSeconds()))}if(a){const i=void 0!==n.config.minTime?n.config.minTime:n.config.minDate;e=Math.max(e,i.getHours()),e===i.getHours()&&t<i.getMinutes()&&(t=i.getMinutes()),t===i.getMinutes()&&(r=Math.max(r,i.getSeconds()))}l(e,t,r)}function s(e){const t=e||n.latestSelectedDateObj;t&&l(t.getHours(),t.getMinutes(),t.getSeconds())}function l(e,t,r){void 0!==n.latestSelectedDateObj&&n.latestSelectedDateObj.setHours(e%24,t,r||0,0),n.hourElement&&n.minuteElement&&!n.isMobile&&(n.hourElement.value=yu(n.config.time_24hr?e:(12+e)%12+12*bu(e%12==0)),n.minuteElement.value=yu(t),void 0!==n.amPM&&(n.amPM.textContent=n.l10n.amPM[bu(e>=12)]),void 0!==n.secondElement&&(n.secondElement.value=yu(r)))}function u(e){const t=Au(e),n=parseInt(t.value)+(e.delta||0);(n/1e3>1||"Enter"===e.key&&!/[^\d]/.test(n.toString()))&&j(n)}function c(e,t,r,i){return t instanceof Array?t.forEach((t=>c(e,t,r,i))):e instanceof Array?e.forEach((e=>c(e,t,r,i))):(e.addEventListener(t,r,i),void n._handlers.push({remove:()=>e.removeEventListener(t,r)}))}function f(){V("onChange")}function p(e,t){const r=void 0!==e?n.parseDate(e):n.latestSelectedDateObj||(n.config.minDate&&n.config.minDate>n.now?n.config.minDate:n.config.maxDate&&n.config.maxDate<n.now?n.config.maxDate:n.now),i=n.currentYear,o=n.currentMonth;try{void 0!==r&&(n.currentYear=r.getFullYear(),n.currentMonth=r.getMonth())}catch(a){a.message="Invalid date supplied: "+r,n.config.errorHandler(a)}t&&n.currentYear!==i&&(V("onYearChange"),w()),!t||n.currentYear===i&&n.currentMonth===o||V("onMonthChange"),n.redraw()}function d(e){const t=Au(e);~t.className.indexOf("arrow")&&h(e,t.classList.contains("arrowUp")?1:-1)}function h(e,t,n){const r=e&&Au(e),i=n||r&&r.parentNode&&r.parentNode.firstChild,o=K("increment");o.delta=t,i&&i.dispatchEvent(o)}function g(e,t,r,i){const o=T(t,!0),a=ku("span","flatpickr-day "+e,t.getDate().toString());return a.dateObj=t,a.$i=i,a.setAttribute("aria-label",n.formatDate(t,n.config.ariaDateFormat)),-1===e.indexOf("hidden")&&0===Pu(t,n.now)&&(n.todayDateElem=a,a.classList.add("today"),a.setAttribute("aria-current","date")),o?(a.tabIndex=-1,Y(t)&&(a.classList.add("selected"),n.selectedDateElem=a,"range"===n.config.mode&&(xu(a,"startRange",n.selectedDates[0]&&0===Pu(t,n.selectedDates[0],!0)),xu(a,"endRange",n.selectedDates[1]&&0===Pu(t,n.selectedDates[1],!0)),"nextMonthDay"===e&&a.classList.add("inRange")))):a.classList.add("flatpickr-disabled"),"range"===n.config.mode&&function(e){return!("range"!==n.config.mode||n.selectedDates.length<2)&&(Pu(e,n.selectedDates[0])>=0&&Pu(e,n.selectedDates[1])<=0)}(t)&&!Y(t)&&a.classList.add("inRange"),n.weekNumbers&&1===n.config.showMonths&&"prevMonthDay"!==e&&r%7==1&&n.weekNumbers.insertAdjacentHTML("beforeend","<span class='flatpickr-day'>"+n.config.getWeek(t)+"</span>"),V("onDayCreate",a),a}function m(e){e.focus(),"range"===n.config.mode&&M(e)}function v(e){const t=e>0?0:n.config.showMonths-1,r=e>0?n.config.showMonths:-1;for(let i=t;i!=r;i+=e){const t=n.daysContainer.children[i],r=e>0?0:t.children.length-1,o=e>0?t.children.length:-1;for(let n=r;n!=o;n+=e){const e=t.children[n];if(-1===e.className.indexOf("hidden")&&T(e.dateObj))return e}}}function y(e,t){const r=D(document.activeElement||document.body),i=void 0!==e?e:r?document.activeElement:void 0!==n.selectedDateElem&&D(n.selectedDateElem)?n.selectedDateElem:void 0!==n.todayDateElem&&D(n.todayDateElem)?n.todayDateElem:v(t>0?1:-1);void 0===i?n._input.focus():r?function(e,t){const r=-1===e.className.indexOf("Month")?e.dateObj.getMonth():n.currentMonth,i=t>0?n.config.showMonths:-1,o=t>0?1:-1;for(let a=r-n.currentMonth;a!=i;a+=o){const i=n.daysContainer.children[a],s=r-n.currentMonth===a?e.$i+t:t<0?i.children.length-1:0,l=i.children.length;for(let n=s;n>=0&&n<l&&n!=(t>0?l:-1);n+=o){const r=i.children[n];if(-1===r.className.indexOf("hidden")&&T(r.dateObj)&&Math.abs(e.$i-n)>=Math.abs(t))return m(r)}}n.changeMonth(o),y(v(o),0)}(i,t):m(i)}function b(e,t){const r=(new Date(e,t,1).getDay()-n.l10n.firstDayOfWeek+7)%7,i=n.utils.getDaysInMonth((t-1+12)%12,e),o=n.utils.getDaysInMonth(t,e),a=window.document.createDocumentFragment(),s=n.config.showMonths>1,l=s?"prevMonthDay hidden":"prevMonthDay",u=s?"nextMonthDay hidden":"nextMonthDay";let c=i+1-r,f=0;for(;c<=i;c++,f++)a.appendChild(g(l,new Date(e,t-1,c),c,f));for(c=1;c<=o;c++,f++)a.appendChild(g("",new Date(e,t,c),c,f));for(let d=o+1;d<=42-r&&(1===n.config.showMonths||f%7!=0);d++,f++)a.appendChild(g(u,new Date(e,t+1,d%o),d,f));const p=ku("div","dayContainer");return p.appendChild(a),p}function _(){if(void 0===n.daysContainer)return;Cu(n.daysContainer),n.weekNumbers&&Cu(n.weekNumbers);const e=document.createDocumentFragment();for(let t=0;t<n.config.showMonths;t++){const r=new Date(n.currentYear,n.currentMonth,1);r.setMonth(n.currentMonth+t),e.appendChild(b(r.getFullYear(),r.getMonth()))}n.daysContainer.appendChild(e),n.days=n.daysContainer.firstChild,"range"===n.config.mode&&1===n.selectedDates.length&&M()}function w(){if(n.config.showMonths>1||"dropdown"!==n.config.monthSelectorType)return;const e=function(e){return!(void 0!==n.config.minDate&&n.currentYear===n.config.minDate.getFullYear()&&e<n.config.minDate.getMonth())&&!(void 0!==n.config.maxDate&&n.currentYear===n.config.maxDate.getFullYear()&&e>n.config.maxDate.getMonth())};n.monthsDropdownContainer.tabIndex=-1,n.monthsDropdownContainer.innerHTML="";for(let t=0;t<12;t++){if(!e(t))continue;const r=ku("option","flatpickr-monthDropdown-month");r.value=new Date(n.currentYear,t).getMonth().toString(),r.textContent=ju(t,n.config.shorthandCurrentMonth,n.l10n),r.tabIndex=-1,n.currentMonth===t&&(r.selected=!0),n.monthsDropdownContainer.appendChild(r)}}function x(){const e=ku("div","flatpickr-month"),t=window.document.createDocumentFragment();let r;n.config.showMonths>1||"static"===n.config.monthSelectorType?r=ku("span","cur-month"):(n.monthsDropdownContainer=ku("select","flatpickr-monthDropdown-months"),n.monthsDropdownContainer.setAttribute("aria-label",n.l10n.monthAriaLabel),c(n.monthsDropdownContainer,"change",(e=>{const t=Au(e),r=parseInt(t.value,10);n.changeMonth(r-n.currentMonth),V("onMonthChange")})),w(),r=n.monthsDropdownContainer);const i=Ou("cur-year",{tabindex:"-1"}),o=i.getElementsByTagName("input")[0];o.setAttribute("aria-label",n.l10n.yearAriaLabel),n.config.minDate&&o.setAttribute("min",n.config.minDate.getFullYear().toString()),n.config.maxDate&&(o.setAttribute("max",n.config.maxDate.getFullYear().toString()),o.disabled=!!n.config.minDate&&n.config.minDate.getFullYear()===n.config.maxDate.getFullYear());const a=ku("div","flatpickr-current-month");return a.appendChild(r),a.appendChild(i),t.appendChild(a),e.appendChild(t),{container:e,yearElement:o,monthElement:r}}function k(){Cu(n.monthNav),n.monthNav.appendChild(n.prevMonthNav),n.config.showMonths&&(n.yearElements=[],n.monthElements=[]);for(let e=n.config.showMonths;e--;){const e=x();n.yearElements.push(e.yearElement),n.monthElements.push(e.monthElement),n.monthNav.appendChild(e.container)}n.monthNav.appendChild(n.nextMonthNav)}function C(){n.weekdayContainer?Cu(n.weekdayContainer):n.weekdayContainer=ku("div","flatpickr-weekdays");for(let e=n.config.showMonths;e--;){const e=ku("div","flatpickr-weekdaycontainer");n.weekdayContainer.appendChild(e)}return E(),n.weekdayContainer}function E(){if(!n.weekdayContainer)return;const e=n.l10n.firstDayOfWeek;let t=[...n.l10n.weekdays.shorthand];e>0&&e<t.length&&(t=[...t.splice(e,t.length),...t.splice(0,e)]);for(let r=n.config.showMonths;r--;)n.weekdayContainer.children[r].innerHTML=`\n <span class='flatpickr-weekday'>\n ${t.join("</span><span class='flatpickr-weekday'>")}\n </span>\n `}function O(e,t=!0){const r=t?e:e-n.currentMonth;r<0&&!0===n._hidePrevMonthArrow||r>0&&!0===n._hideNextMonthArrow||(n.currentMonth+=r,(n.currentMonth<0||n.currentMonth>11)&&(n.currentYear+=n.currentMonth>11?1:-1,n.currentMonth=(n.currentMonth+12)%12,V("onYearChange"),w()),_(),V("onMonthChange"),G())}function A(e){return!(!n.config.appendTo||!n.config.appendTo.contains(e))||n.calendarContainer.contains(e)}function S(e){if(n.isOpen&&!n.config.inline){const t=Au(e),r=A(t),i=t===n.input||t===n.altInput||n.element.contains(t)||e.path&&e.path.indexOf&&(~e.path.indexOf(n.input)||~e.path.indexOf(n.altInput)),a="blur"===e.type?i&&e.relatedTarget&&!A(e.relatedTarget):!i&&!r&&!A(e.relatedTarget),s=!n.config.ignoredFocusElements.some((e=>e.contains(t)));a&&s&&(void 0!==n.timeContainer&&void 0!==n.minuteElement&&void 0!==n.hourElement&&""!==n.input.value&&void 0!==n.input.value&&o(),n.close(),n.config&&"range"===n.config.mode&&1===n.selectedDates.length&&(n.clear(!1),n.redraw()))}}function j(e){if(!e||n.config.minDate&&e<n.config.minDate.getFullYear()||n.config.maxDate&&e>n.config.maxDate.getFullYear())return;const t=e,r=n.currentYear!==t;n.currentYear=t||n.currentYear,n.config.maxDate&&n.currentYear===n.config.maxDate.getFullYear()?n.currentMonth=Math.min(n.config.maxDate.getMonth(),n.currentMonth):n.config.minDate&&n.currentYear===n.config.minDate.getFullYear()&&(n.currentMonth=Math.max(n.config.minDate.getMonth(),n.currentMonth)),r&&(n.redraw(),V("onYearChange"),w())}function T(e,t=!0){var r;const i=n.parseDate(e,void 0,t);if(n.config.minDate&&i&&Pu(i,n.config.minDate,void 0!==t?t:!n.minDateHasTime)<0||n.config.maxDate&&i&&Pu(i,n.config.maxDate,void 0!==t?t:!n.maxDateHasTime)>0)return!1;if(!n.config.enable&&0===n.config.disable.length)return!0;if(void 0===i)return!1;const o=!!n.config.enable,a=null!==(r=n.config.enable)&&void 0!==r?r:n.config.disable;for(let s,l=0;l<a.length;l++){if(s=a[l],"function"==typeof s&&s(i))return o;if(s instanceof Date&&void 0!==i&&s.getTime()===i.getTime())return o;if("string"==typeof s){const e=n.parseDate(s,void 0,!0);return e&&e.getTime()===i.getTime()?o:!o}if("object"==typeof s&&void 0!==i&&s.from&&s.to&&i.getTime()>=s.from.getTime()&&i.getTime()<=s.to.getTime())return o}return!o}function D(e){return void 0!==n.daysContainer&&(-1===e.className.indexOf("hidden")&&-1===e.className.indexOf("flatpickr-disabled")&&n.daysContainer.contains(e))}function N(e){!(e.target===n._input)||!(n.selectedDates.length>0||n._input.value.length>0)||e.relatedTarget&&A(e.relatedTarget)||n.setDate(n._input.value,!0,e.target===n.altInput?n.config.altFormat:n.config.dateFormat)}function L(t){const r=Au(t),i=n.config.wrap?e.contains(r):r===n._input,s=n.config.allowInput,l=n.isOpen&&(!s||!i),u=n.config.inline&&i&&!s;if(13===t.keyCode&&i){if(s)return n.setDate(n._input.value,!0,r===n.altInput?n.config.altFormat:n.config.dateFormat),r.blur();n.open()}else if(A(r)||l||u){const e=!!n.timeContainer&&n.timeContainer.contains(r);switch(t.keyCode){case 13:e?(t.preventDefault(),o(),z()):B(t);break;case 27:t.preventDefault(),z();break;case 8:case 46:i&&!n.config.allowInput&&(t.preventDefault(),n.clear());break;case 37:case 39:if(e||i)n.hourElement&&n.hourElement.focus();else if(t.preventDefault(),void 0!==n.daysContainer&&(!1===s||document.activeElement&&D(document.activeElement))){const e=39===t.keyCode?1:-1;t.ctrlKey?(t.stopPropagation(),O(e),y(v(1),0)):y(void 0,e)}break;case 38:case 40:t.preventDefault();const a=40===t.keyCode?1:-1;n.daysContainer&&void 0!==r.$i||r===n.input||r===n.altInput?t.ctrlKey?(t.stopPropagation(),j(n.currentYear-a),y(v(1),0)):e||y(void 0,7*a):r===n.currentYearElement?j(n.currentYear-a):n.config.enableTime&&(!e&&n.hourElement&&n.hourElement.focus(),o(t),n._debouncedChange());break;case 9:if(e){const e=[n.hourElement,n.minuteElement,n.secondElement,n.amPM].concat(n.pluginElements).filter((e=>e)),i=e.indexOf(r);if(-1!==i){const r=e[i+(t.shiftKey?-1:1)];t.preventDefault(),(r||n._input).focus()}}else!n.config.noCalendar&&n.daysContainer&&n.daysContainer.contains(r)&&t.shiftKey&&(t.preventDefault(),n._input.focus())}}if(void 0!==n.amPM&&r===n.amPM)switch(t.key){case n.l10n.amPM[0].charAt(0):case n.l10n.amPM[0].charAt(0).toLowerCase():n.amPM.textContent=n.l10n.amPM[0],a(),X();break;case n.l10n.amPM[1].charAt(0):case n.l10n.amPM[1].charAt(0).toLowerCase():n.amPM.textContent=n.l10n.amPM[1],a(),X()}(i||A(r))&&V("onKeyDown",t)}function M(e){if(1!==n.selectedDates.length||e&&(!e.classList.contains("flatpickr-day")||e.classList.contains("flatpickr-disabled")))return;const t=e?e.dateObj.getTime():n.days.firstElementChild.dateObj.getTime(),r=n.parseDate(n.selectedDates[0],void 0,!0).getTime(),i=Math.min(t,n.selectedDates[0].getTime()),o=Math.max(t,n.selectedDates[0].getTime());let a=!1,s=0,l=0;for(let n=i;n<o;n+=Fu)T(new Date(n),!0)||(a=a||n>i&&n<o,n<r&&(!s||n>s)?s=n:n>r&&(!l||n<l)&&(l=n));for(let p=0;p<n.config.showMonths;p++){const i=n.daysContainer.children[p];for(let o=0,p=i.children.length;o<p;o++){const p=i.children[o],d=p.dateObj.getTime(),h=s>0&&d<s||l>0&&d>l;h?(p.classList.add("notAllowed"),["inRange","startRange","endRange"].forEach((e=>{p.classList.remove(e)}))):a&&!h||(["startRange","inRange","endRange","notAllowed"].forEach((e=>{p.classList.remove(e)})),void 0!==e&&(e.classList.add(t<=n.selectedDates[0].getTime()?"startRange":"endRange"),r<t&&d===r?p.classList.add("startRange"):r>t&&d===r&&p.classList.add("endRange"),d>=s&&(0===l||d<=l)&&(c=r,f=t,(u=d)>Math.min(c,f)&&u<Math.max(c,f))&&p.classList.add("inRange")))}}var u,c,f}function P(){!n.isOpen||n.config.static||n.config.inline||$()}function F(e){return t=>{const r=n.config[`_${e}Date`]=n.parseDate(t,n.config.dateFormat),i=n.config[`_${"min"===e?"max":"min"}Date`];void 0!==r&&(n["min"===e?"minDateHasTime":"maxDateHasTime"]=r.getHours()>0||r.getMinutes()>0||r.getSeconds()>0),n.selectedDates&&(n.selectedDates=n.selectedDates.filter((e=>T(e))),n.selectedDates.length||"min"!==e||s(r),X()),n.daysContainer&&(R(),void 0!==r?n.currentYearElement[e]=r.getFullYear().toString():n.currentYearElement.removeAttribute(e),n.currentYearElement.disabled=!!i&&void 0!==r&&i.getFullYear()===r.getFullYear())}}function q(){return n.config.wrap?e.querySelector("[data-input]"):e}function I(){"object"!=typeof n.config.locale&&void 0===Ru.l10ns[n.config.locale]&&n.config.errorHandler(new Error(`flatpickr: invalid locale ${n.config.locale}`)),n.l10n=Object.assign(Object.assign({},Ru.l10ns.default),"object"==typeof n.config.locale?n.config.locale:"default"!==n.config.locale?Ru.l10ns[n.config.locale]:void 0),Du.K=`(${n.l10n.amPM[0]}|${n.l10n.amPM[1]}|${n.l10n.amPM[0].toLowerCase()}|${n.l10n.amPM[1].toLowerCase()})`;void 0===Object.assign(Object.assign({},t),JSON.parse(JSON.stringify(e.dataset||{}))).time_24hr&&void 0===Ru.defaultConfig.time_24hr&&(n.config.time_24hr=n.l10n.time_24hr),n.formatDate=Lu(n),n.parseDate=Mu({config:n.config,l10n:n.l10n})}function $(e){if("function"==typeof n.config.position)return void n.config.position(n,e);if(void 0===n.calendarContainer)return;V("onPreCalendarPosition");const t=e||n._positionElement,r=Array.prototype.reduce.call(n.calendarContainer.children,((e,t)=>e+t.offsetHeight),0),i=n.calendarContainer.offsetWidth,o=n.config.position.split(" "),a=o[0],s=o.length>1?o[1]:null,l=t.getBoundingClientRect(),u=window.innerHeight-l.bottom,c="above"===a||"below"!==a&&u<r&&l.top>r,f=window.pageYOffset+l.top+(c?-r-2:t.offsetHeight+2);if(xu(n.calendarContainer,"arrowTop",!c),xu(n.calendarContainer,"arrowBottom",c),n.config.inline)return;let p=window.pageXOffset+l.left,d=!1,h=!1;"center"===s?(p-=(i-l.width)/2,d=!0):"right"===s&&(p-=i-l.width,h=!0),xu(n.calendarContainer,"arrowLeft",!d&&!h),xu(n.calendarContainer,"arrowCenter",d),xu(n.calendarContainer,"arrowRight",h);const g=window.document.body.offsetWidth-(window.pageXOffset+l.right),m=p+i>window.document.body.offsetWidth,v=g+i>window.document.body.offsetWidth;if(xu(n.calendarContainer,"rightMost",m),!n.config.static)if(n.calendarContainer.style.top=`${f}px`,m)if(v){const e=function(){let e=null;for(let n=0;n<document.styleSheets.length;n++){const r=document.styleSheets[n];try{r.cssRules}catch(t){continue}e=r;break}return null!=e?e:function(){const e=document.createElement("style");return document.head.appendChild(e),e.sheet}()}();if(void 0===e)return;const t=window.document.body.offsetWidth,r=Math.max(0,t/2-i/2),o=".flatpickr-calendar.centerMost:before",a=".flatpickr-calendar.centerMost:after",s=e.cssRules.length,u=`{left:${l.left}px;right:auto;}`;xu(n.calendarContainer,"rightMost",!1),xu(n.calendarContainer,"centerMost",!0),e.insertRule(`${o},${a}${u}`,s),n.calendarContainer.style.left=`${r}px`,n.calendarContainer.style.right="auto"}else n.calendarContainer.style.left="auto",n.calendarContainer.style.right=`${g}px`;else n.calendarContainer.style.left=`${p}px`,n.calendarContainer.style.right="auto"}function R(){n.config.noCalendar||n.isMobile||(w(),G(),_())}function z(){n._input.focus(),-1!==window.navigator.userAgent.indexOf("MSIE")||void 0!==navigator.msMaxTouchPoints?setTimeout(n.close,0):n.close()}function B(e){e.preventDefault(),e.stopPropagation();const t=Eu(Au(e),(e=>e.classList&&e.classList.contains("flatpickr-day")&&!e.classList.contains("flatpickr-disabled")&&!e.classList.contains("notAllowed")));if(void 0===t)return;const r=t,i=n.latestSelectedDateObj=new Date(r.dateObj.getTime()),o=(i.getMonth()<n.currentMonth||i.getMonth()>n.currentMonth+n.config.showMonths-1)&&"range"!==n.config.mode;if(n.selectedDateElem=r,"single"===n.config.mode)n.selectedDates=[i];else if("multiple"===n.config.mode){const e=Y(i);e?n.selectedDates.splice(parseInt(e),1):n.selectedDates.push(i)}else"range"===n.config.mode&&(2===n.selectedDates.length&&n.clear(!1,!1),n.latestSelectedDateObj=i,n.selectedDates.push(i),0!==Pu(i,n.selectedDates[0],!0)&&n.selectedDates.sort(((e,t)=>e.getTime()-t.getTime())));if(a(),o){const e=n.currentYear!==i.getFullYear();n.currentYear=i.getFullYear(),n.currentMonth=i.getMonth(),e&&(V("onYearChange"),w()),V("onMonthChange")}if(G(),_(),X(),o||"range"===n.config.mode||1!==n.config.showMonths?void 0!==n.selectedDateElem&&void 0===n.hourElement&&n.selectedDateElem&&n.selectedDateElem.focus():m(r),void 0!==n.hourElement&&void 0!==n.hourElement&&n.hourElement.focus(),n.config.closeOnSelect){const e="single"===n.config.mode&&!n.config.enableTime,t="range"===n.config.mode&&2===n.selectedDates.length&&!n.config.enableTime;(e||t)&&z()}f()}n.parseDate=Mu({config:n.config,l10n:n.l10n}),n._handlers=[],n.pluginElements=[],n.loadedPlugins=[],n._bind=c,n._setHoursFromDate=s,n._positionCalendar=$,n.changeMonth=O,n.changeYear=j,n.clear=function(e=!0,t=!0){n.input.value="",void 0!==n.altInput&&(n.altInput.value="");void 0!==n.mobileInput&&(n.mobileInput.value="");n.selectedDates=[],n.latestSelectedDateObj=void 0,!0===t&&(n.currentYear=n._initialDate.getFullYear(),n.currentMonth=n._initialDate.getMonth());if(!0===n.config.enableTime){const{hours:e,minutes:t,seconds:r}=qu(n.config);l(e,t,r)}n.redraw(),e&&V("onChange")},n.close=function(){n.isOpen=!1,n.isMobile||(void 0!==n.calendarContainer&&n.calendarContainer.classList.remove("open"),void 0!==n._input&&n._input.classList.remove("active"));V("onClose")},n._createElement=ku,n.destroy=function(){void 0!==n.config&&V("onDestroy");for(let e=n._handlers.length;e--;)n._handlers[e].remove();if(n._handlers=[],n.mobileInput)n.mobileInput.parentNode&&n.mobileInput.parentNode.removeChild(n.mobileInput),n.mobileInput=void 0;else if(n.calendarContainer&&n.calendarContainer.parentNode)if(n.config.static&&n.calendarContainer.parentNode){const e=n.calendarContainer.parentNode;if(e.lastChild&&e.removeChild(e.lastChild),e.parentNode){for(;e.firstChild;)e.parentNode.insertBefore(e.firstChild,e);e.parentNode.removeChild(e)}}else n.calendarContainer.parentNode.removeChild(n.calendarContainer);n.altInput&&(n.input.type="text",n.altInput.parentNode&&n.altInput.parentNode.removeChild(n.altInput),delete n.altInput);n.input&&(n.input.type=n.input._type,n.input.classList.remove("flatpickr-input"),n.input.removeAttribute("readonly"));["_showTimeInput","latestSelectedDateObj","_hideNextMonthArrow","_hidePrevMonthArrow","__hideNextMonthArrow","__hidePrevMonthArrow","isMobile","isOpen","selectedDateElem","minDateHasTime","maxDateHasTime","days","daysContainer","_input","_positionElement","innerContainer","rContainer","monthNav","todayDateElem","calendarContainer","weekdayContainer","prevMonthNav","nextMonthNav","monthsDropdownContainer","currentMonthElement","currentYearElement","navigationCurrentMonth","selectedDateElem","config"].forEach((e=>{try{delete n[e]}catch(t){}}))},n.isEnabled=T,n.jumpToDate=p,n.open=function(e,t=n._positionElement){if(!0===n.isMobile){if(e){e.preventDefault();const t=Au(e);t&&t.blur()}return void 0!==n.mobileInput&&(n.mobileInput.focus(),n.mobileInput.click()),void V("onOpen")}if(n._input.disabled||n.config.inline)return;const r=n.isOpen;n.isOpen=!0,r||(n.calendarContainer.classList.add("open"),n._input.classList.add("active"),V("onOpen"),$(t));!0===n.config.enableTime&&!0===n.config.noCalendar&&(!1!==n.config.allowInput||void 0!==e&&n.timeContainer.contains(e.relatedTarget)||setTimeout((()=>n.hourElement.select()),50))},n.redraw=R,n.set=function(e,t){if(null!==e&&"object"==typeof e){Object.assign(n.config,e);for(const t in e)void 0!==W[t]&&W[t].forEach((e=>e()))}else n.config[e]=t,void 0!==W[e]?W[e].forEach((e=>e())):gu.indexOf(e)>-1&&(n.config[e]=wu(t));n.redraw(),X(!0)},n.setDate=function(e,t=!1,r=n.config.dateFormat){if(0!==e&&!e||e instanceof Array&&0===e.length)return n.clear(t);H(e,r),n.latestSelectedDateObj=n.selectedDates[n.selectedDates.length-1],n.redraw(),p(void 0,t),s(),0===n.selectedDates.length&&n.clear(!1);X(t),t&&V("onChange")},n.toggle=function(e){if(!0===n.isOpen)return n.close();n.open(e)};const W={locale:[I,E],showMonths:[k,i,C],minDate:[p],maxDate:[p],clickOpens:[()=>{!0===n.config.clickOpens?(c(n._input,"focus",n.open),c(n._input,"click",n.open)):(n._input.removeEventListener("focus",n.open),n._input.removeEventListener("click",n.open))}]};function H(e,t){let r=[];if(e instanceof Array)r=e.map((e=>n.parseDate(e,t)));else if(e instanceof Date||"number"==typeof e)r=[n.parseDate(e,t)];else if("string"==typeof e)switch(n.config.mode){case"single":case"time":r=[n.parseDate(e,t)];break;case"multiple":r=e.split(n.config.conjunction).map((e=>n.parseDate(e,t)));break;case"range":r=e.split(n.l10n.rangeSeparator).map((e=>n.parseDate(e,t)))}else n.config.errorHandler(new Error(`Invalid date supplied: ${JSON.stringify(e)}`));n.selectedDates=n.config.allowInvalidPreload?r:r.filter((e=>e instanceof Date&&T(e,!1))),"range"===n.config.mode&&n.selectedDates.sort(((e,t)=>e.getTime()-t.getTime()))}function U(e){return e.slice().map((e=>"string"==typeof e||"number"==typeof e||e instanceof Date?n.parseDate(e,void 0,!0):e&&"object"==typeof e&&e.from&&e.to?{from:n.parseDate(e.from,void 0),to:n.parseDate(e.to,void 0)}:e)).filter((e=>e))}function V(e,t){if(void 0===n.config)return;const r=n.config[e];if(void 0!==r&&r.length>0)for(let i=0;r[i]&&i<r.length;i++)r[i](n.selectedDates,n.input.value,n,t);"onChange"===e&&(n.input.dispatchEvent(K("change")),n.input.dispatchEvent(K("input")))}function K(e){const t=document.createEvent("Event");return t.initEvent(e,!0,!0),t}function Y(e){for(let t=0;t<n.selectedDates.length;t++)if(0===Pu(n.selectedDates[t],e))return""+t;return!1}function G(){n.config.noCalendar||n.isMobile||!n.monthNav||(n.yearElements.forEach(((e,t)=>{const r=new Date(n.currentYear,n.currentMonth,1);r.setMonth(n.currentMonth+t),n.config.showMonths>1||"static"===n.config.monthSelectorType?n.monthElements[t].textContent=ju(r.getMonth(),n.config.shorthandCurrentMonth,n.l10n)+" ":n.monthsDropdownContainer.value=r.getMonth().toString(),e.value=r.getFullYear().toString()})),n._hidePrevMonthArrow=void 0!==n.config.minDate&&(n.currentYear===n.config.minDate.getFullYear()?n.currentMonth<=n.config.minDate.getMonth():n.currentYear<n.config.minDate.getFullYear()),n._hideNextMonthArrow=void 0!==n.config.maxDate&&(n.currentYear===n.config.maxDate.getFullYear()?n.currentMonth+1>n.config.maxDate.getMonth():n.currentYear>n.config.maxDate.getFullYear()))}function Z(e){return n.selectedDates.map((t=>n.formatDate(t,e))).filter(((e,t,r)=>"range"!==n.config.mode||n.config.enableTime||r.indexOf(e)===t)).join("range"!==n.config.mode?n.config.conjunction:n.l10n.rangeSeparator)}function X(e=!0){void 0!==n.mobileInput&&n.mobileFormatStr&&(n.mobileInput.value=void 0!==n.latestSelectedDateObj?n.formatDate(n.latestSelectedDateObj,n.mobileFormatStr):""),n.input.value=Z(n.config.dateFormat),void 0!==n.altInput&&(n.altInput.value=Z(n.config.altFormat)),!1!==e&&V("onValueUpdate")}function J(e){const t=Au(e),r=n.prevMonthNav.contains(t),i=n.nextMonthNav.contains(t);r||i?O(r?-1:1):n.yearElements.indexOf(t)>=0?t.select():t.classList.contains("arrowUp")?n.changeYear(n.currentYear+1):t.classList.contains("arrowDown")&&n.changeYear(n.currentYear-1)}return function(){n.element=n.input=e,n.isOpen=!1,function(){const i=["wrap","weekNumbers","allowInput","allowInvalidPreload","clickOpens","time_24hr","enableTime","noCalendar","altInput","shorthandCurrentMonth","inline","static","enableSeconds","disableMobile"],o=Object.assign(Object.assign({},JSON.parse(JSON.stringify(e.dataset||{}))),t),a={};n.config.parseDate=o.parseDate,n.config.formatDate=o.formatDate,Object.defineProperty(n.config,"enable",{get:()=>n.config._enable,set:e=>{n.config._enable=U(e)}}),Object.defineProperty(n.config,"disable",{get:()=>n.config._disable,set:e=>{n.config._disable=U(e)}});const s="time"===o.mode;if(!o.dateFormat&&(o.enableTime||s)){const e=Ru.defaultConfig.dateFormat||mu.dateFormat;a.dateFormat=o.noCalendar||s?"H:i"+(o.enableSeconds?":S":""):e+" H:i"+(o.enableSeconds?":S":"")}if(o.altInput&&(o.enableTime||s)&&!o.altFormat){const e=Ru.defaultConfig.altFormat||mu.altFormat;a.altFormat=o.noCalendar||s?"h:i"+(o.enableSeconds?":S K":" K"):e+` h:i${o.enableSeconds?":S":""} K`}Object.defineProperty(n.config,"minDate",{get:()=>n.config._minDate,set:F("min")}),Object.defineProperty(n.config,"maxDate",{get:()=>n.config._maxDate,set:F("max")});const l=e=>t=>{n.config["min"===e?"_minTime":"_maxTime"]=n.parseDate(t,"H:i:S")};Object.defineProperty(n.config,"minTime",{get:()=>n.config._minTime,set:l("min")}),Object.defineProperty(n.config,"maxTime",{get:()=>n.config._maxTime,set:l("max")}),"time"===o.mode&&(n.config.noCalendar=!0,n.config.enableTime=!0);Object.assign(n.config,a,o);for(let e=0;e<i.length;e++)n.config[i[e]]=!0===n.config[i[e]]||"true"===n.config[i[e]];gu.filter((e=>void 0!==n.config[e])).forEach((e=>{n.config[e]=wu(n.config[e]||[]).map(r)})),n.isMobile=!n.config.disableMobile&&!n.config.inline&&"single"===n.config.mode&&!n.config.disable.length&&!n.config.enable&&!n.config.weekNumbers&&/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent);for(let e=0;e<n.config.plugins.length;e++){const t=n.config.plugins[e](n)||{};for(const e in t)gu.indexOf(e)>-1?n.config[e]=wu(t[e]).map(r).concat(n.config[e]):void 0===o[e]&&(n.config[e]=t[e])}o.altInputClass||(n.config.altInputClass=q().className+" "+n.config.altInputClass);V("onParseConfig")}(),I(),function(){if(n.input=q(),!n.input)return void n.config.errorHandler(new Error("Invalid input element specified"));n.input._type=n.input.type,n.input.type="text",n.input.classList.add("flatpickr-input"),n._input=n.input,n.config.altInput&&(n.altInput=ku(n.input.nodeName,n.config.altInputClass),n._input=n.altInput,n.altInput.placeholder=n.input.placeholder,n.altInput.disabled=n.input.disabled,n.altInput.required=n.input.required,n.altInput.tabIndex=n.input.tabIndex,n.altInput.type="text",n.input.setAttribute("type","hidden"),!n.config.static&&n.input.parentNode&&n.input.parentNode.insertBefore(n.altInput,n.input.nextSibling));n.config.allowInput||n._input.setAttribute("readonly","readonly");n._positionElement=n.config.positionElement||n._input}(),function(){n.selectedDates=[],n.now=n.parseDate(n.config.now)||new Date;const e=n.config.defaultDate||("INPUT"!==n.input.nodeName&&"TEXTAREA"!==n.input.nodeName||!n.input.placeholder||n.input.value!==n.input.placeholder?n.input.value:null);e&&H(e,n.config.dateFormat);n._initialDate=n.selectedDates.length>0?n.selectedDates[0]:n.config.minDate&&n.config.minDate.getTime()>n.now.getTime()?n.config.minDate:n.config.maxDate&&n.config.maxDate.getTime()<n.now.getTime()?n.config.maxDate:n.now,n.currentYear=n._initialDate.getFullYear(),n.currentMonth=n._initialDate.getMonth(),n.selectedDates.length>0&&(n.latestSelectedDateObj=n.selectedDates[0]);void 0!==n.config.minTime&&(n.config.minTime=n.parseDate(n.config.minTime,"H:i"));void 0!==n.config.maxTime&&(n.config.maxTime=n.parseDate(n.config.maxTime,"H:i"));n.minDateHasTime=!!n.config.minDate&&(n.config.minDate.getHours()>0||n.config.minDate.getMinutes()>0||n.config.minDate.getSeconds()>0),n.maxDateHasTime=!!n.config.maxDate&&(n.config.maxDate.getHours()>0||n.config.maxDate.getMinutes()>0||n.config.maxDate.getSeconds()>0)}(),n.utils={getDaysInMonth:(e=n.currentMonth,t=n.currentYear)=>1===e&&(t%4==0&&t%100!=0||t%400==0)?29:n.l10n.daysInMonth[e]},n.isMobile||function(){const e=window.document.createDocumentFragment();if(n.calendarContainer=ku("div","flatpickr-calendar"),n.calendarContainer.tabIndex=-1,!n.config.noCalendar){if(e.appendChild((n.monthNav=ku("div","flatpickr-months"),n.yearElements=[],n.monthElements=[],n.prevMonthNav=ku("span","flatpickr-prev-month"),n.prevMonthNav.innerHTML=n.config.prevArrow,n.nextMonthNav=ku("span","flatpickr-next-month"),n.nextMonthNav.innerHTML=n.config.nextArrow,k(),Object.defineProperty(n,"_hidePrevMonthArrow",{get:()=>n.__hidePrevMonthArrow,set(e){n.__hidePrevMonthArrow!==e&&(xu(n.prevMonthNav,"flatpickr-disabled",e),n.__hidePrevMonthArrow=e)}}),Object.defineProperty(n,"_hideNextMonthArrow",{get:()=>n.__hideNextMonthArrow,set(e){n.__hideNextMonthArrow!==e&&(xu(n.nextMonthNav,"flatpickr-disabled",e),n.__hideNextMonthArrow=e)}}),n.currentYearElement=n.yearElements[0],G(),n.monthNav)),n.innerContainer=ku("div","flatpickr-innerContainer"),n.config.weekNumbers){const{weekWrapper:e,weekNumbers:t}=function(){n.calendarContainer.classList.add("hasWeeks");const e=ku("div","flatpickr-weekwrapper");e.appendChild(ku("span","flatpickr-weekday",n.l10n.weekAbbreviation));const t=ku("div","flatpickr-weeks");return e.appendChild(t),{weekWrapper:e,weekNumbers:t}}();n.innerContainer.appendChild(e),n.weekNumbers=t,n.weekWrapper=e}n.rContainer=ku("div","flatpickr-rContainer"),n.rContainer.appendChild(C()),n.daysContainer||(n.daysContainer=ku("div","flatpickr-days"),n.daysContainer.tabIndex=-1),_(),n.rContainer.appendChild(n.daysContainer),n.innerContainer.appendChild(n.rContainer),e.appendChild(n.innerContainer)}n.config.enableTime&&e.appendChild(function(){n.calendarContainer.classList.add("hasTime"),n.config.noCalendar&&n.calendarContainer.classList.add("noCalendar");const e=qu(n.config);n.timeContainer=ku("div","flatpickr-time"),n.timeContainer.tabIndex=-1;const t=ku("span","flatpickr-time-separator",":"),r=Ou("flatpickr-hour",{"aria-label":n.l10n.hourAriaLabel});n.hourElement=r.getElementsByTagName("input")[0];const i=Ou("flatpickr-minute",{"aria-label":n.l10n.minuteAriaLabel});n.minuteElement=i.getElementsByTagName("input")[0],n.hourElement.tabIndex=n.minuteElement.tabIndex=-1,n.hourElement.value=yu(n.latestSelectedDateObj?n.latestSelectedDateObj.getHours():n.config.time_24hr?e.hours:function(e){switch(e%24){case 0:case 12:return 12;default:return e%12}}(e.hours)),n.minuteElement.value=yu(n.latestSelectedDateObj?n.latestSelectedDateObj.getMinutes():e.minutes),n.hourElement.setAttribute("step",n.config.hourIncrement.toString()),n.minuteElement.setAttribute("step",n.config.minuteIncrement.toString()),n.hourElement.setAttribute("min",n.config.time_24hr?"0":"1"),n.hourElement.setAttribute("max",n.config.time_24hr?"23":"12"),n.hourElement.setAttribute("maxlength","2"),n.minuteElement.setAttribute("min","0"),n.minuteElement.setAttribute("max","59"),n.minuteElement.setAttribute("maxlength","2"),n.timeContainer.appendChild(r),n.timeContainer.appendChild(t),n.timeContainer.appendChild(i),n.config.time_24hr&&n.timeContainer.classList.add("time24hr");if(n.config.enableSeconds){n.timeContainer.classList.add("hasSeconds");const t=Ou("flatpickr-second");n.secondElement=t.getElementsByTagName("input")[0],n.secondElement.value=yu(n.latestSelectedDateObj?n.latestSelectedDateObj.getSeconds():e.seconds),n.secondElement.setAttribute("step",n.minuteElement.getAttribute("step")),n.secondElement.setAttribute("min","0"),n.secondElement.setAttribute("max","59"),n.secondElement.setAttribute("maxlength","2"),n.timeContainer.appendChild(ku("span","flatpickr-time-separator",":")),n.timeContainer.appendChild(t)}n.config.time_24hr||(n.amPM=ku("span","flatpickr-am-pm",n.l10n.amPM[bu((n.latestSelectedDateObj?n.hourElement.value:n.config.defaultHour)>11)]),n.amPM.title=n.l10n.toggleTitle,n.amPM.tabIndex=-1,n.timeContainer.appendChild(n.amPM));return n.timeContainer}());xu(n.calendarContainer,"rangeMode","range"===n.config.mode),xu(n.calendarContainer,"animate",!0===n.config.animate),xu(n.calendarContainer,"multiMonth",n.config.showMonths>1),n.calendarContainer.appendChild(e);const t=void 0!==n.config.appendTo&&void 0!==n.config.appendTo.nodeType;if((n.config.inline||n.config.static)&&(n.calendarContainer.classList.add(n.config.inline?"inline":"static"),n.config.inline&&(!t&&n.element.parentNode?n.element.parentNode.insertBefore(n.calendarContainer,n._input.nextSibling):void 0!==n.config.appendTo&&n.config.appendTo.appendChild(n.calendarContainer)),n.config.static)){const e=ku("div","flatpickr-wrapper");n.element.parentNode&&n.element.parentNode.insertBefore(e,n.element),e.appendChild(n.element),n.altInput&&e.appendChild(n.altInput),e.appendChild(n.calendarContainer)}n.config.static||n.config.inline||(void 0!==n.config.appendTo?n.config.appendTo:window.document.body).appendChild(n.calendarContainer)}(),function(){n.config.wrap&&["open","close","toggle","clear"].forEach((e=>{Array.prototype.forEach.call(n.element.querySelectorAll(`[data-${e}]`),(t=>c(t,"click",n[e])))}));if(n.isMobile)return void function(){const e=n.config.enableTime?n.config.noCalendar?"time":"datetime-local":"date";n.mobileInput=ku("input",n.input.className+" flatpickr-mobile"),n.mobileInput.tabIndex=1,n.mobileInput.type=e,n.mobileInput.disabled=n.input.disabled,n.mobileInput.required=n.input.required,n.mobileInput.placeholder=n.input.placeholder,n.mobileFormatStr="datetime-local"===e?"Y-m-d\\TH:i:S":"date"===e?"Y-m-d":"H:i:S",n.selectedDates.length>0&&(n.mobileInput.defaultValue=n.mobileInput.value=n.formatDate(n.selectedDates[0],n.mobileFormatStr));n.config.minDate&&(n.mobileInput.min=n.formatDate(n.config.minDate,"Y-m-d"));n.config.maxDate&&(n.mobileInput.max=n.formatDate(n.config.maxDate,"Y-m-d"));n.input.getAttribute("step")&&(n.mobileInput.step=String(n.input.getAttribute("step")));n.input.type="hidden",void 0!==n.altInput&&(n.altInput.type="hidden");try{n.input.parentNode&&n.input.parentNode.insertBefore(n.mobileInput,n.input.nextSibling)}catch(t){}c(n.mobileInput,"change",(e=>{n.setDate(Au(e).value,!1,n.mobileFormatStr),V("onChange"),V("onClose")}))}();const e=_u(P,50);n._debouncedChange=_u(f,300),n.daysContainer&&!/iPhone|iPad|iPod/i.test(navigator.userAgent)&&c(n.daysContainer,"mouseover",(e=>{"range"===n.config.mode&&M(Au(e))}));c(window.document.body,"keydown",L),n.config.inline||n.config.static||c(window,"resize",e);void 0!==window.ontouchstart?c(window.document,"touchstart",S):c(window.document,"mousedown",S);c(window.document,"focus",S,{capture:!0}),!0===n.config.clickOpens&&(c(n._input,"focus",n.open),c(n._input,"click",n.open));void 0!==n.daysContainer&&(c(n.monthNav,"click",J),c(n.monthNav,["keyup","increment"],u),c(n.daysContainer,"click",B));if(void 0!==n.timeContainer&&void 0!==n.minuteElement&&void 0!==n.hourElement){const e=e=>Au(e).select();c(n.timeContainer,["increment"],o),c(n.timeContainer,"blur",o,{capture:!0}),c(n.timeContainer,"click",d),c([n.hourElement,n.minuteElement],["focus","click"],e),void 0!==n.secondElement&&c(n.secondElement,"focus",(()=>n.secondElement&&n.secondElement.select())),void 0!==n.amPM&&c(n.amPM,"click",(e=>{o(e),f()}))}n.config.allowInput&&c(n._input,"blur",N)}(),(n.selectedDates.length||n.config.noCalendar)&&(n.config.enableTime&&s(n.config.noCalendar?n.latestSelectedDateObj:void 0),X(!1)),i();const a=/^((?!chrome|android).)*safari/i.test(navigator.userAgent);!n.isMobile&&a&&$(),V("onReady")}(),n}function $u(e,t){const n=Array.prototype.slice.call(e).filter((e=>e instanceof HTMLElement)),r=[];for(let o=0;o<n.length;o++){const e=n[o];try{if(null!==e.getAttribute("data-fp-omit"))continue;void 0!==e._flatpickr&&(e._flatpickr.destroy(),e._flatpickr=void 0),e._flatpickr=Iu(e,t||{}),r.push(e._flatpickr)}catch(i){console.error(i)}}return 1===r.length?r[0]:r}"undefined"!=typeof HTMLElement&&"undefined"!=typeof HTMLCollection&&"undefined"!=typeof NodeList&&(HTMLCollection.prototype.flatpickr=NodeList.prototype.flatpickr=function(e){return $u(this,e)},HTMLElement.prototype.flatpickr=function(e){return $u([this],e)});var Ru=function(e,t){return"string"==typeof e?$u(window.document.querySelectorAll(e),t):e instanceof Node?$u([e],t):$u(e,t)};function zu(e){let t;const n=e[8].default,r=v(n,e,e[7],null),i=r||function(e){let t,n=[e[1]],r={};for(let i=0;i<n.length;i+=1)r=l(r,n[i]);return{c(){t=P("input"),this.h()},l(e){t=Y(e,"INPUT",{}),this.h()},h(){U(t,r)},m(n,r){N(n,t,r),e[9](t)},p(e,i){U(t,r=it(n,[e[1]]))},d(n){n&&L(t),e[9](null)}}}(e);return{c(){i&&i.c()},l(e){i&&i.l(e)},m(e,n){i&&i.m(e,n),t=!0},p(e,[t]){r?r.p&&128&t&&b(r,n,e,e[7],t,null,null):i&&i.p&&1&t&&i.p(e,t)},i(e){t||(Ue(i,e),t=!0)},o(e){Ve(i,e),t=!1},d(e){i&&i.d(e)}}}function Bu(e){return e.charAt(2).toLowerCase()+e.substring(3)}function Wu(e,t,n){let{$$slots:r={},$$scope:i}=t;const o=new Set(["onChange","onOpen","onClose","onMonthChange","onYearChange","onReady","onValueUpdate","onDayCreate"]);let{value:a=""}=t,{formattedValue:s=""}=t,{element:u=null}=t,{dateFormat:c=null}=t;const f=t.options||{},p=Object.assign({},t);let d,h;delete p.options,ve((()=>(n(6,h=Ru(u||d,Object.assign(m(f),u?{wrap:!0}:{}))),()=>{h.destroy()})));const g=_e();function m(e={}){e=Object.assign({},e);for(const t of o){const n=(e,n,r)=>{g(Bu(t),[e,n,r])};t in e?(Array.isArray(e[t])||(e[t]=[e[t]]),e[t].push(n)):e[t]=[n]}return e.onChange&&!e.onChange.includes(v)&&e.onChange.push(v),e}function v(e,t){n(2,a=Array.isArray(e)&&1===e.length?e[0]:e),n(3,s=t)}return e.$$set=e=>{n(16,t=l(l({},t),_(e))),"value"in e&&n(2,a=e.value),"formattedValue"in e&&n(3,s=e.formattedValue),"element"in e&&n(4,u=e.element),"dateFormat"in e&&n(5,c=e.dateFormat),"$$scope"in e&&n(7,i=e.$$scope)},e.$$.update=()=>{if(100&e.$$.dirty&&h&&h.setDate(a,!1,c),64&e.$$.dirty&&h)for(const[e,t]of Object.entries(m(f)))h.set(e,t)},t=_(t),[d,p,a,s,u,c,h,i,r,function(e){Ee[e?"unshift":"push"]((()=>{d=e,n(0,d)}))}]}Ru.defaultConfig={},Ru.l10ns={en:Object.assign({},vu),default:Object.assign({},vu)},Ru.localize=e=>{Ru.l10ns.default=Object.assign(Object.assign({},Ru.l10ns.default),e)},Ru.setDefaults=e=>{Ru.defaultConfig=Object.assign(Object.assign({},Ru.defaultConfig),e)},Ru.parseDate=Mu({}),Ru.formatDate=Lu({}),Ru.compareDates=Pu,"undefined"!=typeof jQuery&&void 0!==jQuery.fn&&(jQuery.fn.flatpickr=function(e){return $u(this,e)}),Date.prototype.fp_incr=function(e){return new Date(this.getFullYear(),this.getMonth(),this.getDate()+("string"==typeof e?parseInt(e,10):e))},"undefined"!=typeof window&&(window.flatpickr=Ru);class Hu extends pt{constructor(e){super(),ft(this,e,Wu,zu,d,{value:2,formattedValue:3,element:4,dateFormat:5})}}var Uu=Un((function(e,t){e.exports=function(){var e=navigator.userAgent,t=navigator.platform,n=/gecko\/\d/i.test(e),r=/MSIE \d/.test(e),i=/Trident\/(?:[7-9]|\d{2,})\..*rv:(\d+)/.exec(e),o=/Edge\/(\d+)/.exec(e),a=r||i||o,s=a&&(r?document.documentMode||6:+(o||i)[1]),l=!o&&/WebKit\//.test(e),u=l&&/Qt\/\d+\.\d+/.test(e),c=!o&&/Chrome\//.test(e),f=/Opera\//.test(e),p=/Apple Computer/.test(navigator.vendor),d=/Mac OS X 1\d\D([8-9]|\d\d)\D/.test(e),h=/PhantomJS/.test(e),g=p&&(/Mobile\/\w+/.test(e)||navigator.maxTouchPoints>2),m=/Android/.test(e),v=g||m||/webOS|BlackBerry|Opera Mini|Opera Mobi|IEMobile/i.test(e),y=g||/Mac/.test(t),b=/\bCrOS\b/.test(e),_=/win/i.test(t),w=f&&e.match(/Version\/(\d*\.\d*)/);w&&(w=Number(w[1])),w&&w>=15&&(f=!1,l=!0);var x=y&&(u||f&&(null==w||w<12.11)),k=n||a&&s>=9;function C(e){return new RegExp("(^|\\s)"+e+"(?:$|\\s)\\s*")}var E,O=function(e,t){var n=e.className,r=C(t).exec(n);if(r){var i=n.slice(r.index+r[0].length);e.className=n.slice(0,r.index)+(i?r[1]+i:"")}};function A(e){for(var t=e.childNodes.length;t>0;--t)e.removeChild(e.firstChild);return e}function S(e,t){return A(e).appendChild(t)}function j(e,t,n,r){var i=document.createElement(e);if(n&&(i.className=n),r&&(i.style.cssText=r),"string"==typeof t)i.appendChild(document.createTextNode(t));else if(t)for(var o=0;o<t.length;++o)i.appendChild(t[o]);return i}function T(e,t,n,r){var i=j(e,t,n,r);return i.setAttribute("role","presentation"),i}function D(e,t){if(3==t.nodeType&&(t=t.parentNode),e.contains)return e.contains(t);do{if(11==t.nodeType&&(t=t.host),t==e)return!0}while(t=t.parentNode)}function N(){var e;try{e=document.activeElement}catch(Le){e=document.body||null}for(;e&&e.shadowRoot&&e.shadowRoot.activeElement;)e=e.shadowRoot.activeElement;return e}function L(e,t){var n=e.className;C(t).test(n)||(e.className+=(n?" ":"")+t)}function M(e,t){for(var n=e.split(" "),r=0;r<n.length;r++)n[r]&&!C(n[r]).test(t)&&(t+=" "+n[r]);return t}E=document.createRange?function(e,t,n,r){var i=document.createRange();return i.setEnd(r||e,n),i.setStart(e,t),i}:function(e,t,n){var r=document.body.createTextRange();try{r.moveToElementText(e.parentNode)}catch(Le){return r}return r.collapse(!0),r.moveEnd("character",n),r.moveStart("character",t),r};var P=function(e){e.select()};function F(e){var t=Array.prototype.slice.call(arguments,1);return function(){return e.apply(null,t)}}function q(e,t,n){for(var r in t||(t={}),e)!e.hasOwnProperty(r)||!1===n&&t.hasOwnProperty(r)||(t[r]=e[r]);return t}function I(e,t,n,r,i){null==t&&-1==(t=e.search(/[^\s\u00a0]/))&&(t=e.length);for(var o=r||0,a=i||0;;){var s=e.indexOf("\t",o);if(s<0||s>=t)return a+(t-o);a+=s-o,a+=n-a%n,o=s+1}}g?P=function(e){e.selectionStart=0,e.selectionEnd=e.value.length}:a&&(P=function(e){try{e.select()}catch(t){}});var $=function(){this.id=null,this.f=null,this.time=0,this.handler=F(this.onTimeout,this)};function R(e,t){for(var n=0;n<e.length;++n)if(e[n]==t)return n;return-1}$.prototype.onTimeout=function(e){e.id=0,e.time<=+new Date?e.f():setTimeout(e.handler,e.time-+new Date)},$.prototype.set=function(e,t){this.f=t;var n=+new Date+e;(!this.id||n<this.time)&&(clearTimeout(this.id),this.id=setTimeout(this.handler,e),this.time=n)};var z=50,B={toString:function(){return"CodeMirror.Pass"}},W={scroll:!1},H={origin:"*mouse"},U={origin:"+move"};function V(e,t,n){for(var r=0,i=0;;){var o=e.indexOf("\t",r);-1==o&&(o=e.length);var a=o-r;if(o==e.length||i+a>=t)return r+Math.min(a,t-i);if(i+=o-r,r=o+1,(i+=n-i%n)>=t)return r}}var K=[""];function Y(e){for(;K.length<=e;)K.push(G(K)+" ");return K[e]}function G(e){return e[e.length-1]}function Z(e,t){for(var n=[],r=0;r<e.length;r++)n[r]=t(e[r],r);return n}function X(e,t,n){for(var r=0,i=n(t);r<e.length&&n(e[r])<=i;)r++;e.splice(r,0,t)}function J(){}function Q(e,t){var n;return Object.create?n=Object.create(e):(J.prototype=e,n=new J),t&&q(t,n),n}var ee=/[\u00df\u0587\u0590-\u05f4\u0600-\u06ff\u3040-\u309f\u30a0-\u30ff\u3400-\u4db5\u4e00-\u9fcc\uac00-\ud7af]/;function te(e){return/\w/.test(e)||e>"€"&&(e.toUpperCase()!=e.toLowerCase()||ee.test(e))}function ne(e,t){return t?!!(t.source.indexOf("\\w")>-1&&te(e))||t.test(e):te(e)}function re(e){for(var t in e)if(e.hasOwnProperty(t)&&e[t])return!1;return!0}var ie=/[\u0300-\u036f\u0483-\u0489\u0591-\u05bd\u05bf\u05c1\u05c2\u05c4\u05c5\u05c7\u0610-\u061a\u064b-\u065e\u0670\u06d6-\u06dc\u06de-\u06e4\u06e7\u06e8\u06ea-\u06ed\u0711\u0730-\u074a\u07a6-\u07b0\u07eb-\u07f3\u0816-\u0819\u081b-\u0823\u0825-\u0827\u0829-\u082d\u0900-\u0902\u093c\u0941-\u0948\u094d\u0951-\u0955\u0962\u0963\u0981\u09bc\u09be\u09c1-\u09c4\u09cd\u09d7\u09e2\u09e3\u0a01\u0a02\u0a3c\u0a41\u0a42\u0a47\u0a48\u0a4b-\u0a4d\u0a51\u0a70\u0a71\u0a75\u0a81\u0a82\u0abc\u0ac1-\u0ac5\u0ac7\u0ac8\u0acd\u0ae2\u0ae3\u0b01\u0b3c\u0b3e\u0b3f\u0b41-\u0b44\u0b4d\u0b56\u0b57\u0b62\u0b63\u0b82\u0bbe\u0bc0\u0bcd\u0bd7\u0c3e-\u0c40\u0c46-\u0c48\u0c4a-\u0c4d\u0c55\u0c56\u0c62\u0c63\u0cbc\u0cbf\u0cc2\u0cc6\u0ccc\u0ccd\u0cd5\u0cd6\u0ce2\u0ce3\u0d3e\u0d41-\u0d44\u0d4d\u0d57\u0d62\u0d63\u0dca\u0dcf\u0dd2-\u0dd4\u0dd6\u0ddf\u0e31\u0e34-\u0e3a\u0e47-\u0e4e\u0eb1\u0eb4-\u0eb9\u0ebb\u0ebc\u0ec8-\u0ecd\u0f18\u0f19\u0f35\u0f37\u0f39\u0f71-\u0f7e\u0f80-\u0f84\u0f86\u0f87\u0f90-\u0f97\u0f99-\u0fbc\u0fc6\u102d-\u1030\u1032-\u1037\u1039\u103a\u103d\u103e\u1058\u1059\u105e-\u1060\u1071-\u1074\u1082\u1085\u1086\u108d\u109d\u135f\u1712-\u1714\u1732-\u1734\u1752\u1753\u1772\u1773\u17b7-\u17bd\u17c6\u17c9-\u17d3\u17dd\u180b-\u180d\u18a9\u1920-\u1922\u1927\u1928\u1932\u1939-\u193b\u1a17\u1a18\u1a56\u1a58-\u1a5e\u1a60\u1a62\u1a65-\u1a6c\u1a73-\u1a7c\u1a7f\u1b00-\u1b03\u1b34\u1b36-\u1b3a\u1b3c\u1b42\u1b6b-\u1b73\u1b80\u1b81\u1ba2-\u1ba5\u1ba8\u1ba9\u1c2c-\u1c33\u1c36\u1c37\u1cd0-\u1cd2\u1cd4-\u1ce0\u1ce2-\u1ce8\u1ced\u1dc0-\u1de6\u1dfd-\u1dff\u200c\u200d\u20d0-\u20f0\u2cef-\u2cf1\u2de0-\u2dff\u302a-\u302f\u3099\u309a\ua66f-\ua672\ua67c\ua67d\ua6f0\ua6f1\ua802\ua806\ua80b\ua825\ua826\ua8c4\ua8e0-\ua8f1\ua926-\ua92d\ua947-\ua951\ua980-\ua982\ua9b3\ua9b6-\ua9b9\ua9bc\uaa29-\uaa2e\uaa31\uaa32\uaa35\uaa36\uaa43\uaa4c\uaab0\uaab2-\uaab4\uaab7\uaab8\uaabe\uaabf\uaac1\uabe5\uabe8\uabed\udc00-\udfff\ufb1e\ufe00-\ufe0f\ufe20-\ufe26\uff9e\uff9f]/;function oe(e){return e.charCodeAt(0)>=768&&ie.test(e)}function ae(e,t,n){for(;(n<0?t>0:t<e.length)&&oe(e.charAt(t));)t+=n;return t}function se(e,t,n){for(var r=t>n?-1:1;;){if(t==n)return t;var i=(t+n)/2,o=r<0?Math.ceil(i):Math.floor(i);if(o==t)return e(o)?t:n;e(o)?n=o:t=o+r}}function le(e,t,n,r){if(!e)return r(t,n,"ltr",0);for(var i=!1,o=0;o<e.length;++o){var a=e[o];(a.from<n&&a.to>t||t==n&&a.to==t)&&(r(Math.max(a.from,t),Math.min(a.to,n),1==a.level?"rtl":"ltr",o),i=!0)}i||r(t,n,"ltr")}var ue=null;function ce(e,t,n){var r;ue=null;for(var i=0;i<e.length;++i){var o=e[i];if(o.from<t&&o.to>t)return i;o.to==t&&(o.from!=o.to&&"before"==n?r=i:ue=i),o.from==t&&(o.from!=o.to&&"before"!=n?r=i:ue=i)}return null!=r?r:ue}var fe=function(){var e="bbbbbbbbbtstwsbbbbbbbbbbbbbbssstwNN%%%NNNNNN,N,N1111111111NNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNNNLLLLLLLLLLLLLLLLLLLLLLLLLLNNNNbbbbbbsbbbbbbbbbbbbbbbbbbbbbbbbbb,N%%%%NNNNLNNNNN%%11NLNNN1LNNNNNLLLLLLLLLLLLLLLLLLLLLLLNLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLLN",t="nnnnnnNNr%%r,rNNmmmmmmmmmmmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmmmmmmmmmmmmmmmnnnnnnnnnn%nnrrrmrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrrmmmmmmmnNmmmmmmrrmmNmmmmrr1111111111";function n(n){return n<=247?e.charAt(n):1424<=n&&n<=1524?"R":1536<=n&&n<=1785?t.charAt(n-1536):1774<=n&&n<=2220?"r":8192<=n&&n<=8203?"w":8204==n?"b":"L"}var r=/[\u0590-\u05f4\u0600-\u06ff\u0700-\u08ac]/,i=/[stwN]/,o=/[LRr]/,a=/[Lb1n]/,s=/[1n]/;function l(e,t,n){this.level=e,this.from=t,this.to=n}return function(e,t){var u="ltr"==t?"L":"R";if(0==e.length||"ltr"==t&&!r.test(e))return!1;for(var c=e.length,f=[],p=0;p<c;++p)f.push(n(e.charCodeAt(p)));for(var d=0,h=u;d<c;++d){var g=f[d];"m"==g?f[d]=h:h=g}for(var m=0,v=u;m<c;++m){var y=f[m];"1"==y&&"r"==v?f[m]="n":o.test(y)&&(v=y,"r"==y&&(f[m]="R"))}for(var b=1,_=f[0];b<c-1;++b){var w=f[b];"+"==w&&"1"==_&&"1"==f[b+1]?f[b]="1":","!=w||_!=f[b+1]||"1"!=_&&"n"!=_||(f[b]=_),_=w}for(var x=0;x<c;++x){var k=f[x];if(","==k)f[x]="N";else if("%"==k){var C=void 0;for(C=x+1;C<c&&"%"==f[C];++C);for(var E=x&&"!"==f[x-1]||C<c&&"1"==f[C]?"1":"N",O=x;O<C;++O)f[O]=E;x=C-1}}for(var A=0,S=u;A<c;++A){var j=f[A];"L"==S&&"1"==j?f[A]="L":o.test(j)&&(S=j)}for(var T=0;T<c;++T)if(i.test(f[T])){var D=void 0;for(D=T+1;D<c&&i.test(f[D]);++D);for(var N="L"==(T?f[T-1]:u),L=N==("L"==(D<c?f[D]:u))?N?"L":"R":u,M=T;M<D;++M)f[M]=L;T=D-1}for(var P,F=[],q=0;q<c;)if(a.test(f[q])){var I=q;for(++q;q<c&&a.test(f[q]);++q);F.push(new l(0,I,q))}else{var $=q,R=F.length,z="rtl"==t?1:0;for(++q;q<c&&"L"!=f[q];++q);for(var B=$;B<q;)if(s.test(f[B])){$<B&&(F.splice(R,0,new l(1,$,B)),R+=z);var W=B;for(++B;B<q&&s.test(f[B]);++B);F.splice(R,0,new l(2,W,B)),R+=z,$=B}else++B;$<q&&F.splice(R,0,new l(1,$,q))}return"ltr"==t&&(1==F[0].level&&(P=e.match(/^\s+/))&&(F[0].from=P[0].length,F.unshift(new l(0,0,P[0].length))),1==G(F).level&&(P=e.match(/\s+$/))&&(G(F).to-=P[0].length,F.push(new l(0,c-P[0].length,c)))),"rtl"==t?F.reverse():F}}();function pe(e,t){var n=e.order;return null==n&&(n=e.order=fe(e.text,t)),n}var de=[],he=function(e,t,n){if(e.addEventListener)e.addEventListener(t,n,!1);else if(e.attachEvent)e.attachEvent("on"+t,n);else{var r=e._handlers||(e._handlers={});r[t]=(r[t]||de).concat(n)}};function ge(e,t){return e._handlers&&e._handlers[t]||de}function me(e,t,n){if(e.removeEventListener)e.removeEventListener(t,n,!1);else if(e.detachEvent)e.detachEvent("on"+t,n);else{var r=e._handlers,i=r&&r[t];if(i){var o=R(i,n);o>-1&&(r[t]=i.slice(0,o).concat(i.slice(o+1)))}}}function ve(e,t){var n=ge(e,t);if(n.length)for(var r=Array.prototype.slice.call(arguments,2),i=0;i<n.length;++i)n[i].apply(null,r)}function ye(e,t,n){return"string"==typeof t&&(t={type:t,preventDefault:function(){this.defaultPrevented=!0}}),ve(e,n||t.type,e,t),Ce(t)||t.codemirrorIgnore}function be(e){var t=e._handlers&&e._handlers.cursorActivity;if(t)for(var n=e.curOp.cursorActivityHandlers||(e.curOp.cursorActivityHandlers=[]),r=0;r<t.length;++r)-1==R(n,t[r])&&n.push(t[r])}function _e(e,t){return ge(e,t).length>0}function we(e){e.prototype.on=function(e,t){he(this,e,t)},e.prototype.off=function(e,t){me(this,e,t)}}function xe(e){e.preventDefault?e.preventDefault():e.returnValue=!1}function ke(e){e.stopPropagation?e.stopPropagation():e.cancelBubble=!0}function Ce(e){return null!=e.defaultPrevented?e.defaultPrevented:0==e.returnValue}function Ee(e){xe(e),ke(e)}function Oe(e){return e.target||e.srcElement}function Ae(e){var t=e.which;return null==t&&(1&e.button?t=1:2&e.button?t=3:4&e.button&&(t=2)),y&&e.ctrlKey&&1==t&&(t=3),t}var Se,je,Te=function(){if(a&&s<9)return!1;var e=j("div");return"draggable"in e||"dragDrop"in e}();function De(e){if(null==Se){var t=j("span","");S(e,j("span",[t,document.createTextNode("x")])),0!=e.firstChild.offsetHeight&&(Se=t.offsetWidth<=1&&t.offsetHeight>2&&!(a&&s<8))}var n=Se?j("span",""):j("span"," ",null,"display: inline-block; width: 1px; margin-right: -1px");return n.setAttribute("cm-text",""),n}function Ne(e){if(null!=je)return je;var t=S(e,document.createTextNode("AخA")),n=E(t,0,1).getBoundingClientRect(),r=E(t,1,2).getBoundingClientRect();return A(e),!(!n||n.left==n.right)&&(je=r.right-n.right<3)}var Le,Me=3!="\n\nb".split(/\n/).length?function(e){for(var t=0,n=[],r=e.length;t<=r;){var i=e.indexOf("\n",t);-1==i&&(i=e.length);var o=e.slice(t,"\r"==e.charAt(i-1)?i-1:i),a=o.indexOf("\r");-1!=a?(n.push(o.slice(0,a)),t+=a+1):(n.push(o),t=i+1)}return n}:function(e){return e.split(/\r\n?|\n/)},Pe=window.getSelection?function(e){try{return e.selectionStart!=e.selectionEnd}catch(Le){return!1}}:function(e){var t;try{t=e.ownerDocument.selection.createRange()}catch(Le){}return!(!t||t.parentElement()!=e)&&0!=t.compareEndPoints("StartToEnd",t)},Fe="oncopy"in(Le=j("div"))||(Le.setAttribute("oncopy","return;"),"function"==typeof Le.oncopy),qe=null;function Ie(e){if(null!=qe)return qe;var t=S(e,j("span","x")),n=t.getBoundingClientRect(),r=E(t,0,1).getBoundingClientRect();return qe=Math.abs(n.left-r.left)>1}var $e={},Re={};function ze(e,t){arguments.length>2&&(t.dependencies=Array.prototype.slice.call(arguments,2)),$e[e]=t}function Be(e,t){Re[e]=t}function We(e){if("string"==typeof e&&Re.hasOwnProperty(e))e=Re[e];else if(e&&"string"==typeof e.name&&Re.hasOwnProperty(e.name)){var t=Re[e.name];"string"==typeof t&&(t={name:t}),(e=Q(t,e)).name=t.name}else{if("string"==typeof e&&/^[\w\-]+\/[\w\-]+\+xml$/.test(e))return We("application/xml");if("string"==typeof e&&/^[\w\-]+\/[\w\-]+\+json$/.test(e))return We("application/json")}return"string"==typeof e?{name:e}:e||{name:"null"}}function He(e,t){t=We(t);var n=$e[t.name];if(!n)return He(e,"text/plain");var r=n(e,t);if(Ue.hasOwnProperty(t.name)){var i=Ue[t.name];for(var o in i)i.hasOwnProperty(o)&&(r.hasOwnProperty(o)&&(r["_"+o]=r[o]),r[o]=i[o])}if(r.name=t.name,t.helperType&&(r.helperType=t.helperType),t.modeProps)for(var a in t.modeProps)r[a]=t.modeProps[a];return r}var Ue={};function Ve(e,t){q(t,Ue.hasOwnProperty(e)?Ue[e]:Ue[e]={})}function Ke(e,t){if(!0===t)return t;if(e.copyState)return e.copyState(t);var n={};for(var r in t){var i=t[r];i instanceof Array&&(i=i.concat([])),n[r]=i}return n}function Ye(e,t){for(var n;e.innerMode&&(n=e.innerMode(t))&&n.mode!=e;)t=n.state,e=n.mode;return n||{mode:e,state:t}}function Ge(e,t,n){return!e.startState||e.startState(t,n)}var Ze=function(e,t,n){this.pos=this.start=0,this.string=e,this.tabSize=t||8,this.lastColumnPos=this.lastColumnValue=0,this.lineStart=0,this.lineOracle=n};function Xe(e,t){if((t-=e.first)<0||t>=e.size)throw new Error("There is no line "+(t+e.first)+" in the document.");for(var n=e;!n.lines;)for(var r=0;;++r){var i=n.children[r],o=i.chunkSize();if(t<o){n=i;break}t-=o}return n.lines[t]}function Je(e,t,n){var r=[],i=t.line;return e.iter(t.line,n.line+1,(function(e){var o=e.text;i==n.line&&(o=o.slice(0,n.ch)),i==t.line&&(o=o.slice(t.ch)),r.push(o),++i})),r}function Qe(e,t,n){var r=[];return e.iter(t,n,(function(e){r.push(e.text)})),r}function et(e,t){var n=t-e.height;if(n)for(var r=e;r;r=r.parent)r.height+=n}function tt(e){if(null==e.parent)return null;for(var t=e.parent,n=R(t.lines,e),r=t.parent;r;t=r,r=r.parent)for(var i=0;r.children[i]!=t;++i)n+=r.children[i].chunkSize();return n+t.first}function nt(e,t){var n=e.first;e:do{for(var r=0;r<e.children.length;++r){var i=e.children[r],o=i.height;if(t<o){e=i;continue e}t-=o,n+=i.chunkSize()}return n}while(!e.lines);for(var a=0;a<e.lines.length;++a){var s=e.lines[a].height;if(t<s)break;t-=s}return n+a}function rt(e,t){return t>=e.first&&t<e.first+e.size}function it(e,t){return String(e.lineNumberFormatter(t+e.firstLineNumber))}function ot(e,t,n){if(void 0===n&&(n=null),!(this instanceof ot))return new ot(e,t,n);this.line=e,this.ch=t,this.sticky=n}function at(e,t){return e.line-t.line||e.ch-t.ch}function st(e,t){return e.sticky==t.sticky&&0==at(e,t)}function lt(e){return ot(e.line,e.ch)}function ut(e,t){return at(e,t)<0?t:e}function ct(e,t){return at(e,t)<0?e:t}function ft(e,t){return Math.max(e.first,Math.min(t,e.first+e.size-1))}function pt(e,t){if(t.line<e.first)return ot(e.first,0);var n=e.first+e.size-1;return t.line>n?ot(n,Xe(e,n).text.length):dt(t,Xe(e,t.line).text.length)}function dt(e,t){var n=e.ch;return null==n||n>t?ot(e.line,t):n<0?ot(e.line,0):e}function ht(e,t){for(var n=[],r=0;r<t.length;r++)n[r]=pt(e,t[r]);return n}Ze.prototype.eol=function(){return this.pos>=this.string.length},Ze.prototype.sol=function(){return this.pos==this.lineStart},Ze.prototype.peek=function(){return this.string.charAt(this.pos)||void 0},Ze.prototype.next=function(){if(this.pos<this.string.length)return this.string.charAt(this.pos++)},Ze.prototype.eat=function(e){var t=this.string.charAt(this.pos);if("string"==typeof e?t==e:t&&(e.test?e.test(t):e(t)))return++this.pos,t},Ze.prototype.eatWhile=function(e){for(var t=this.pos;this.eat(e););return this.pos>t},Ze.prototype.eatSpace=function(){for(var e=this.pos;/[\s\u00a0]/.test(this.string.charAt(this.pos));)++this.pos;return this.pos>e},Ze.prototype.skipToEnd=function(){this.pos=this.string.length},Ze.prototype.skipTo=function(e){var t=this.string.indexOf(e,this.pos);if(t>-1)return this.pos=t,!0},Ze.prototype.backUp=function(e){this.pos-=e},Ze.prototype.column=function(){return this.lastColumnPos<this.start&&(this.lastColumnValue=I(this.string,this.start,this.tabSize,this.lastColumnPos,this.lastColumnValue),this.lastColumnPos=this.start),this.lastColumnValue-(this.lineStart?I(this.string,this.lineStart,this.tabSize):0)},Ze.prototype.indentation=function(){return I(this.string,null,this.tabSize)-(this.lineStart?I(this.string,this.lineStart,this.tabSize):0)},Ze.prototype.match=function(e,t,n){if("string"!=typeof e){var r=this.string.slice(this.pos).match(e);return r&&r.index>0?null:(r&&!1!==t&&(this.pos+=r[0].length),r)}var i=function(e){return n?e.toLowerCase():e};if(i(this.string.substr(this.pos,e.length))==i(e))return!1!==t&&(this.pos+=e.length),!0},Ze.prototype.current=function(){return this.string.slice(this.start,this.pos)},Ze.prototype.hideFirstChars=function(e,t){this.lineStart+=e;try{return t()}finally{this.lineStart-=e}},Ze.prototype.lookAhead=function(e){var t=this.lineOracle;return t&&t.lookAhead(e)},Ze.prototype.baseToken=function(){var e=this.lineOracle;return e&&e.baseToken(this.pos)};var gt=function(e,t){this.state=e,this.lookAhead=t},mt=function(e,t,n,r){this.state=t,this.doc=e,this.line=n,this.maxLookAhead=r||0,this.baseTokens=null,this.baseTokenPos=1};function vt(e,t,n,r){var i=[e.state.modeGen],o={};Ot(e,t.text,e.doc.mode,n,(function(e,t){return i.push(e,t)}),o,r);for(var a=n.state,s=function(r){n.baseTokens=i;var s=e.state.overlays[r],l=1,u=0;n.state=!0,Ot(e,t.text,s.mode,n,(function(e,t){for(var n=l;u<e;){var r=i[l];r>e&&i.splice(l,1,e,i[l+1],r),l+=2,u=Math.min(e,r)}if(t)if(s.opaque)i.splice(n,l-n,e,"overlay "+t),l=n+2;else for(;n<l;n+=2){var o=i[n+1];i[n+1]=(o?o+" ":"")+"overlay "+t}}),o),n.state=a,n.baseTokens=null,n.baseTokenPos=1},l=0;l<e.state.overlays.length;++l)s(l);return{styles:i,classes:o.bgClass||o.textClass?o:null}}function yt(e,t,n){if(!t.styles||t.styles[0]!=e.state.modeGen){var r=bt(e,tt(t)),i=t.text.length>e.options.maxHighlightLength&&Ke(e.doc.mode,r.state),o=vt(e,t,r);i&&(r.state=i),t.stateAfter=r.save(!i),t.styles=o.styles,o.classes?t.styleClasses=o.classes:t.styleClasses&&(t.styleClasses=null),n===e.doc.highlightFrontier&&(e.doc.modeFrontier=Math.max(e.doc.modeFrontier,++e.doc.highlightFrontier))}return t.styles}function bt(e,t,n){var r=e.doc,i=e.display;if(!r.mode.startState)return new mt(r,!0,t);var o=At(e,t,n),a=o>r.first&&Xe(r,o-1).stateAfter,s=a?mt.fromSaved(r,a,o):new mt(r,Ge(r.mode),o);return r.iter(o,t,(function(n){_t(e,n.text,s);var r=s.line;n.stateAfter=r==t-1||r%5==0||r>=i.viewFrom&&r<i.viewTo?s.save():null,s.nextLine()})),n&&(r.modeFrontier=s.line),s}function _t(e,t,n,r){var i=e.doc.mode,o=new Ze(t,e.options.tabSize,n);for(o.start=o.pos=r||0,""==t&&wt(i,n.state);!o.eol();)xt(i,o,n.state),o.start=o.pos}function wt(e,t){if(e.blankLine)return e.blankLine(t);if(e.innerMode){var n=Ye(e,t);return n.mode.blankLine?n.mode.blankLine(n.state):void 0}}function xt(e,t,n,r){for(var i=0;i<10;i++){r&&(r[0]=Ye(e,n).mode);var o=e.token(t,n);if(t.pos>t.start)return o}throw new Error("Mode "+e.name+" failed to advance stream.")}mt.prototype.lookAhead=function(e){var t=this.doc.getLine(this.line+e);return null!=t&&e>this.maxLookAhead&&(this.maxLookAhead=e),t},mt.prototype.baseToken=function(e){if(!this.baseTokens)return null;for(;this.baseTokens[this.baseTokenPos]<=e;)this.baseTokenPos+=2;var t=this.baseTokens[this.baseTokenPos+1];return{type:t&&t.replace(/( |^)overlay .*/,""),size:this.baseTokens[this.baseTokenPos]-e}},mt.prototype.nextLine=function(){this.line++,this.maxLookAhead>0&&this.maxLookAhead--},mt.fromSaved=function(e,t,n){return t instanceof gt?new mt(e,Ke(e.mode,t.state),n,t.lookAhead):new mt(e,Ke(e.mode,t),n)},mt.prototype.save=function(e){var t=!1!==e?Ke(this.doc.mode,this.state):this.state;return this.maxLookAhead>0?new gt(t,this.maxLookAhead):t};var kt=function(e,t,n){this.start=e.start,this.end=e.pos,this.string=e.current(),this.type=t||null,this.state=n};function Ct(e,t,n,r){var i,o,a=e.doc,s=a.mode,l=Xe(a,(t=pt(a,t)).line),u=bt(e,t.line,n),c=new Ze(l.text,e.options.tabSize,u);for(r&&(o=[]);(r||c.pos<t.ch)&&!c.eol();)c.start=c.pos,i=xt(s,c,u.state),r&&o.push(new kt(c,i,Ke(a.mode,u.state)));return r?o:new kt(c,i,u.state)}function Et(e,t){if(e)for(;;){var n=e.match(/(?:^|\s+)line-(background-)?(\S+)/);if(!n)break;e=e.slice(0,n.index)+e.slice(n.index+n[0].length);var r=n[1]?"bgClass":"textClass";null==t[r]?t[r]=n[2]:new RegExp("(?:^|\\s)"+n[2]+"(?:$|\\s)").test(t[r])||(t[r]+=" "+n[2])}return e}function Ot(e,t,n,r,i,o,a){var s=n.flattenSpans;null==s&&(s=e.options.flattenSpans);var l,u=0,c=null,f=new Ze(t,e.options.tabSize,r),p=e.options.addModeClass&&[null];for(""==t&&Et(wt(n,r.state),o);!f.eol();){if(f.pos>e.options.maxHighlightLength?(s=!1,a&&_t(e,t,r,f.pos),f.pos=t.length,l=null):l=Et(xt(n,f,r.state,p),o),p){var d=p[0].name;d&&(l="m-"+(l?d+" "+l:d))}if(!s||c!=l){for(;u<f.start;)i(u=Math.min(f.start,u+5e3),c);c=l}f.start=f.pos}for(;u<f.pos;){var h=Math.min(f.pos,u+5e3);i(h,c),u=h}}function At(e,t,n){for(var r,i,o=e.doc,a=n?-1:t-(e.doc.mode.innerMode?1e3:100),s=t;s>a;--s){if(s<=o.first)return o.first;var l=Xe(o,s-1),u=l.stateAfter;if(u&&(!n||s+(u instanceof gt?u.lookAhead:0)<=o.modeFrontier))return s;var c=I(l.text,null,e.options.tabSize);(null==i||r>c)&&(i=s-1,r=c)}return i}function St(e,t){if(e.modeFrontier=Math.min(e.modeFrontier,t),!(e.highlightFrontier<t-10)){for(var n=e.first,r=t-1;r>n;r--){var i=Xe(e,r).stateAfter;if(i&&(!(i instanceof gt)||r+i.lookAhead<t)){n=r+1;break}}e.highlightFrontier=Math.min(e.highlightFrontier,n)}}var jt=!1,Tt=!1;function Dt(){jt=!0}function Nt(){Tt=!0}function Lt(e,t,n){this.marker=e,this.from=t,this.to=n}function Mt(e,t){if(e)for(var n=0;n<e.length;++n){var r=e[n];if(r.marker==t)return r}}function Pt(e,t){for(var n,r=0;r<e.length;++r)e[r]!=t&&(n||(n=[])).push(e[r]);return n}function Ft(e,t){e.markedSpans=e.markedSpans?e.markedSpans.concat([t]):[t],t.marker.attachLine(e)}function qt(e,t,n){var r;if(e)for(var i=0;i<e.length;++i){var o=e[i],a=o.marker;if(null==o.from||(a.inclusiveLeft?o.from<=t:o.from<t)||o.from==t&&"bookmark"==a.type&&(!n||!o.marker.insertLeft)){var s=null==o.to||(a.inclusiveRight?o.to>=t:o.to>t);(r||(r=[])).push(new Lt(a,o.from,s?null:o.to))}}return r}function It(e,t,n){var r;if(e)for(var i=0;i<e.length;++i){var o=e[i],a=o.marker;if(null==o.to||(a.inclusiveRight?o.to>=t:o.to>t)||o.from==t&&"bookmark"==a.type&&(!n||o.marker.insertLeft)){var s=null==o.from||(a.inclusiveLeft?o.from<=t:o.from<t);(r||(r=[])).push(new Lt(a,s?null:o.from-t,null==o.to?null:o.to-t))}}return r}function $t(e,t){if(t.full)return null;var n=rt(e,t.from.line)&&Xe(e,t.from.line).markedSpans,r=rt(e,t.to.line)&&Xe(e,t.to.line).markedSpans;if(!n&&!r)return null;var i=t.from.ch,o=t.to.ch,a=0==at(t.from,t.to),s=qt(n,i,a),l=It(r,o,a),u=1==t.text.length,c=G(t.text).length+(u?i:0);if(s)for(var f=0;f<s.length;++f){var p=s[f];if(null==p.to){var d=Mt(l,p.marker);d?u&&(p.to=null==d.to?null:d.to+c):p.to=i}}if(l)for(var h=0;h<l.length;++h){var g=l[h];null!=g.to&&(g.to+=c),null==g.from?Mt(s,g.marker)||(g.from=c,u&&(s||(s=[])).push(g)):(g.from+=c,u&&(s||(s=[])).push(g))}s&&(s=Rt(s)),l&&l!=s&&(l=Rt(l));var m=[s];if(!u){var v,y=t.text.length-2;if(y>0&&s)for(var b=0;b<s.length;++b)null==s[b].to&&(v||(v=[])).push(new Lt(s[b].marker,null,null));for(var _=0;_<y;++_)m.push(v);m.push(l)}return m}function Rt(e){for(var t=0;t<e.length;++t){var n=e[t];null!=n.from&&n.from==n.to&&!1!==n.marker.clearWhenEmpty&&e.splice(t--,1)}return e.length?e:null}function zt(e,t,n){var r=null;if(e.iter(t.line,n.line+1,(function(e){if(e.markedSpans)for(var t=0;t<e.markedSpans.length;++t){var n=e.markedSpans[t].marker;!n.readOnly||r&&-1!=R(r,n)||(r||(r=[])).push(n)}})),!r)return null;for(var i=[{from:t,to:n}],o=0;o<r.length;++o)for(var a=r[o],s=a.find(0),l=0;l<i.length;++l){var u=i[l];if(!(at(u.to,s.from)<0||at(u.from,s.to)>0)){var c=[l,1],f=at(u.from,s.from),p=at(u.to,s.to);(f<0||!a.inclusiveLeft&&!f)&&c.push({from:u.from,to:s.from}),(p>0||!a.inclusiveRight&&!p)&&c.push({from:s.to,to:u.to}),i.splice.apply(i,c),l+=c.length-3}}return i}function Bt(e){var t=e.markedSpans;if(t){for(var n=0;n<t.length;++n)t[n].marker.detachLine(e);e.markedSpans=null}}function Wt(e,t){if(t){for(var n=0;n<t.length;++n)t[n].marker.attachLine(e);e.markedSpans=t}}function Ht(e){return e.inclusiveLeft?-1:0}function Ut(e){return e.inclusiveRight?1:0}function Vt(e,t){var n=e.lines.length-t.lines.length;if(0!=n)return n;var r=e.find(),i=t.find(),o=at(r.from,i.from)||Ht(e)-Ht(t);if(o)return-o;var a=at(r.to,i.to)||Ut(e)-Ut(t);return a||t.id-e.id}function Kt(e,t){var n,r=Tt&&e.markedSpans;if(r)for(var i=void 0,o=0;o<r.length;++o)(i=r[o]).marker.collapsed&&null==(t?i.from:i.to)&&(!n||Vt(n,i.marker)<0)&&(n=i.marker);return n}function Yt(e){return Kt(e,!0)}function Gt(e){return Kt(e,!1)}function Zt(e,t){var n,r=Tt&&e.markedSpans;if(r)for(var i=0;i<r.length;++i){var o=r[i];o.marker.collapsed&&(null==o.from||o.from<t)&&(null==o.to||o.to>t)&&(!n||Vt(n,o.marker)<0)&&(n=o.marker)}return n}function Xt(e,t,n,r,i){var o=Xe(e,t),a=Tt&&o.markedSpans;if(a)for(var s=0;s<a.length;++s){var l=a[s];if(l.marker.collapsed){var u=l.marker.find(0),c=at(u.from,n)||Ht(l.marker)-Ht(i),f=at(u.to,r)||Ut(l.marker)-Ut(i);if(!(c>=0&&f<=0||c<=0&&f>=0)&&(c<=0&&(l.marker.inclusiveRight&&i.inclusiveLeft?at(u.to,n)>=0:at(u.to,n)>0)||c>=0&&(l.marker.inclusiveRight&&i.inclusiveLeft?at(u.from,r)<=0:at(u.from,r)<0)))return!0}}}function Jt(e){for(var t;t=Yt(e);)e=t.find(-1,!0).line;return e}function Qt(e){for(var t;t=Gt(e);)e=t.find(1,!0).line;return e}function en(e){for(var t,n;t=Gt(e);)e=t.find(1,!0).line,(n||(n=[])).push(e);return n}function tn(e,t){var n=Xe(e,t),r=Jt(n);return n==r?t:tt(r)}function nn(e,t){if(t>e.lastLine())return t;var n,r=Xe(e,t);if(!rn(e,r))return t;for(;n=Gt(r);)r=n.find(1,!0).line;return tt(r)+1}function rn(e,t){var n=Tt&&t.markedSpans;if(n)for(var r=void 0,i=0;i<n.length;++i)if((r=n[i]).marker.collapsed){if(null==r.from)return!0;if(!r.marker.widgetNode&&0==r.from&&r.marker.inclusiveLeft&&on(e,t,r))return!0}}function on(e,t,n){if(null==n.to){var r=n.marker.find(1,!0);return on(e,r.line,Mt(r.line.markedSpans,n.marker))}if(n.marker.inclusiveRight&&n.to==t.text.length)return!0;for(var i=void 0,o=0;o<t.markedSpans.length;++o)if((i=t.markedSpans[o]).marker.collapsed&&!i.marker.widgetNode&&i.from==n.to&&(null==i.to||i.to!=n.from)&&(i.marker.inclusiveLeft||n.marker.inclusiveRight)&&on(e,t,i))return!0}function an(e){for(var t=0,n=(e=Jt(e)).parent,r=0;r<n.lines.length;++r){var i=n.lines[r];if(i==e)break;t+=i.height}for(var o=n.parent;o;o=(n=o).parent)for(var a=0;a<o.children.length;++a){var s=o.children[a];if(s==n)break;t+=s.height}return t}function sn(e){if(0==e.height)return 0;for(var t,n=e.text.length,r=e;t=Yt(r);){var i=t.find(0,!0);r=i.from.line,n+=i.from.ch-i.to.ch}for(r=e;t=Gt(r);){var o=t.find(0,!0);n-=r.text.length-o.from.ch,n+=(r=o.to.line).text.length-o.to.ch}return n}function ln(e){var t=e.display,n=e.doc;t.maxLine=Xe(n,n.first),t.maxLineLength=sn(t.maxLine),t.maxLineChanged=!0,n.iter((function(e){var n=sn(e);n>t.maxLineLength&&(t.maxLineLength=n,t.maxLine=e)}))}var un=function(e,t,n){this.text=e,Wt(this,t),this.height=n?n(this):1};function cn(e,t,n,r){e.text=t,e.stateAfter&&(e.stateAfter=null),e.styles&&(e.styles=null),null!=e.order&&(e.order=null),Bt(e),Wt(e,n);var i=r?r(e):1;i!=e.height&&et(e,i)}function fn(e){e.parent=null,Bt(e)}un.prototype.lineNo=function(){return tt(this)},we(un);var pn={},dn={};function hn(e,t){if(!e||/^\s*$/.test(e))return null;var n=t.addModeClass?dn:pn;return n[e]||(n[e]=e.replace(/\S+/g,"cm-$&"))}function gn(e,t){var n=T("span",null,null,l?"padding-right: .1px":null),r={pre:T("pre",[n],"CodeMirror-line"),content:n,col:0,pos:0,cm:e,trailingSpace:!1,splitSpaces:e.getOption("lineWrapping")};t.measure={};for(var i=0;i<=(t.rest?t.rest.length:0);i++){var o=i?t.rest[i-1]:t.line,a=void 0;r.pos=0,r.addToken=vn,Ne(e.display.measure)&&(a=pe(o,e.doc.direction))&&(r.addToken=bn(r.addToken,a)),r.map=[],wn(o,r,yt(e,o,t!=e.display.externalMeasured&&tt(o))),o.styleClasses&&(o.styleClasses.bgClass&&(r.bgClass=M(o.styleClasses.bgClass,r.bgClass||"")),o.styleClasses.textClass&&(r.textClass=M(o.styleClasses.textClass,r.textClass||""))),0==r.map.length&&r.map.push(0,0,r.content.appendChild(De(e.display.measure))),0==i?(t.measure.map=r.map,t.measure.cache={}):((t.measure.maps||(t.measure.maps=[])).push(r.map),(t.measure.caches||(t.measure.caches=[])).push({}))}if(l){var s=r.content.lastChild;(/\bcm-tab\b/.test(s.className)||s.querySelector&&s.querySelector(".cm-tab"))&&(r.content.className="cm-tab-wrap-hack")}return ve(e,"renderLine",e,t.line,r.pre),r.pre.className&&(r.textClass=M(r.pre.className,r.textClass||"")),r}function mn(e){var t=j("span","•","cm-invalidchar");return t.title="\\u"+e.charCodeAt(0).toString(16),t.setAttribute("aria-label",t.title),t}function vn(e,t,n,r,i,o,l){if(t){var u,c=e.splitSpaces?yn(t,e.trailingSpace):t,f=e.cm.state.specialChars,p=!1;if(f.test(t)){u=document.createDocumentFragment();for(var d=0;;){f.lastIndex=d;var h=f.exec(t),g=h?h.index-d:t.length-d;if(g){var m=document.createTextNode(c.slice(d,d+g));a&&s<9?u.appendChild(j("span",[m])):u.appendChild(m),e.map.push(e.pos,e.pos+g,m),e.col+=g,e.pos+=g}if(!h)break;d+=g+1;var v=void 0;if("\t"==h[0]){var y=e.cm.options.tabSize,b=y-e.col%y;(v=u.appendChild(j("span",Y(b),"cm-tab"))).setAttribute("role","presentation"),v.setAttribute("cm-text","\t"),e.col+=b}else"\r"==h[0]||"\n"==h[0]?((v=u.appendChild(j("span","\r"==h[0]?"␍":"␤","cm-invalidchar"))).setAttribute("cm-text",h[0]),e.col+=1):((v=e.cm.options.specialCharPlaceholder(h[0])).setAttribute("cm-text",h[0]),a&&s<9?u.appendChild(j("span",[v])):u.appendChild(v),e.col+=1);e.map.push(e.pos,e.pos+1,v),e.pos++}}else e.col+=t.length,u=document.createTextNode(c),e.map.push(e.pos,e.pos+t.length,u),a&&s<9&&(p=!0),e.pos+=t.length;if(e.trailingSpace=32==c.charCodeAt(t.length-1),n||r||i||p||o||l){var _=n||"";r&&(_+=r),i&&(_+=i);var w=j("span",[u],_,o);if(l)for(var x in l)l.hasOwnProperty(x)&&"style"!=x&&"class"!=x&&w.setAttribute(x,l[x]);return e.content.appendChild(w)}e.content.appendChild(u)}}function yn(e,t){if(e.length>1&&!/ /.test(e))return e;for(var n=t,r="",i=0;i<e.length;i++){var o=e.charAt(i);" "!=o||!n||i!=e.length-1&&32!=e.charCodeAt(i+1)||(o=" "),r+=o,n=" "==o}return r}function bn(e,t){return function(n,r,i,o,a,s,l){i=i?i+" cm-force-border":"cm-force-border";for(var u=n.pos,c=u+r.length;;){for(var f=void 0,p=0;p<t.length&&!((f=t[p]).to>u&&f.from<=u);p++);if(f.to>=c)return e(n,r,i,o,a,s,l);e(n,r.slice(0,f.to-u),i,o,null,s,l),o=null,r=r.slice(f.to-u),u=f.to}}}function _n(e,t,n,r){var i=!r&&n.widgetNode;i&&e.map.push(e.pos,e.pos+t,i),!r&&e.cm.display.input.needsContentAttribute&&(i||(i=e.content.appendChild(document.createElement("span"))),i.setAttribute("cm-marker",n.id)),i&&(e.cm.display.input.setUneditable(i),e.content.appendChild(i)),e.pos+=t,e.trailingSpace=!1}function wn(e,t,n){var r=e.markedSpans,i=e.text,o=0;if(r)for(var a,s,l,u,c,f,p,d=i.length,h=0,g=1,m="",v=0;;){if(v==h){l=u=c=s="",p=null,f=null,v=1/0;for(var y=[],b=void 0,_=0;_<r.length;++_){var w=r[_],x=w.marker;if("bookmark"==x.type&&w.from==h&&x.widgetNode)y.push(x);else if(w.from<=h&&(null==w.to||w.to>h||x.collapsed&&w.to==h&&w.from==h)){if(null!=w.to&&w.to!=h&&v>w.to&&(v=w.to,u=""),x.className&&(l+=" "+x.className),x.css&&(s=(s?s+";":"")+x.css),x.startStyle&&w.from==h&&(c+=" "+x.startStyle),x.endStyle&&w.to==v&&(b||(b=[])).push(x.endStyle,w.to),x.title&&((p||(p={})).title=x.title),x.attributes)for(var k in x.attributes)(p||(p={}))[k]=x.attributes[k];x.collapsed&&(!f||Vt(f.marker,x)<0)&&(f=w)}else w.from>h&&v>w.from&&(v=w.from)}if(b)for(var C=0;C<b.length;C+=2)b[C+1]==v&&(u+=" "+b[C]);if(!f||f.from==h)for(var E=0;E<y.length;++E)_n(t,0,y[E]);if(f&&(f.from||0)==h){if(_n(t,(null==f.to?d+1:f.to)-h,f.marker,null==f.from),null==f.to)return;f.to==h&&(f=!1)}}if(h>=d)break;for(var O=Math.min(d,v);;){if(m){var A=h+m.length;if(!f){var S=A>O?m.slice(0,O-h):m;t.addToken(t,S,a?a+l:l,c,h+S.length==v?u:"",s,p)}if(A>=O){m=m.slice(O-h),h=O;break}h=A,c=""}m=i.slice(o,o=n[g++]),a=hn(n[g++],t.cm.options)}}else for(var j=1;j<n.length;j+=2)t.addToken(t,i.slice(o,o=n[j]),hn(n[j+1],t.cm.options))}function xn(e,t,n){this.line=t,this.rest=en(t),this.size=this.rest?tt(G(this.rest))-n+1:1,this.node=this.text=null,this.hidden=rn(e,t)}function kn(e,t,n){for(var r,i=[],o=t;o<n;o=r){var a=new xn(e.doc,Xe(e.doc,o),o);r=o+a.size,i.push(a)}return i}var Cn=null;function En(e){Cn?Cn.ops.push(e):e.ownsGroup=Cn={ops:[e],delayedCallbacks:[]}}function On(e){var t=e.delayedCallbacks,n=0;do{for(;n<t.length;n++)t[n].call(null);for(var r=0;r<e.ops.length;r++){var i=e.ops[r];if(i.cursorActivityHandlers)for(;i.cursorActivityCalled<i.cursorActivityHandlers.length;)i.cursorActivityHandlers[i.cursorActivityCalled++].call(null,i.cm)}}while(n<t.length)}function An(e,t){var n=e.ownsGroup;if(n)try{On(n)}finally{Cn=null,t(n)}}var Sn=null;function jn(e,t){var n=ge(e,t);if(n.length){var r,i=Array.prototype.slice.call(arguments,2);Cn?r=Cn.delayedCallbacks:Sn?r=Sn:(r=Sn=[],setTimeout(Tn,0));for(var o=function(e){r.push((function(){return n[e].apply(null,i)}))},a=0;a<n.length;++a)o(a)}}function Tn(){var e=Sn;Sn=null;for(var t=0;t<e.length;++t)e[t]()}function Dn(e,t,n,r){for(var i=0;i<t.changes.length;i++){var o=t.changes[i];"text"==o?Pn(e,t):"gutter"==o?qn(e,t,n,r):"class"==o?Fn(e,t):"widget"==o&&In(e,t,r)}t.changes=null}function Nn(e){return e.node==e.text&&(e.node=j("div",null,null,"position: relative"),e.text.parentNode&&e.text.parentNode.replaceChild(e.node,e.text),e.node.appendChild(e.text),a&&s<8&&(e.node.style.zIndex=2)),e.node}function Ln(e,t){var n=t.bgClass?t.bgClass+" "+(t.line.bgClass||""):t.line.bgClass;if(n&&(n+=" CodeMirror-linebackground"),t.background)n?t.background.className=n:(t.background.parentNode.removeChild(t.background),t.background=null);else if(n){var r=Nn(t);t.background=r.insertBefore(j("div",null,n),r.firstChild),e.display.input.setUneditable(t.background)}}function Mn(e,t){var n=e.display.externalMeasured;return n&&n.line==t.line?(e.display.externalMeasured=null,t.measure=n.measure,n.built):gn(e,t)}function Pn(e,t){var n=t.text.className,r=Mn(e,t);t.text==t.node&&(t.node=r.pre),t.text.parentNode.replaceChild(r.pre,t.text),t.text=r.pre,r.bgClass!=t.bgClass||r.textClass!=t.textClass?(t.bgClass=r.bgClass,t.textClass=r.textClass,Fn(e,t)):n&&(t.text.className=n)}function Fn(e,t){Ln(e,t),t.line.wrapClass?Nn(t).className=t.line.wrapClass:t.node!=t.text&&(t.node.className="");var n=t.textClass?t.textClass+" "+(t.line.textClass||""):t.line.textClass;t.text.className=n||""}function qn(e,t,n,r){if(t.gutter&&(t.node.removeChild(t.gutter),t.gutter=null),t.gutterBackground&&(t.node.removeChild(t.gutterBackground),t.gutterBackground=null),t.line.gutterClass){var i=Nn(t);t.gutterBackground=j("div",null,"CodeMirror-gutter-background "+t.line.gutterClass,"left: "+(e.options.fixedGutter?r.fixedPos:-r.gutterTotalWidth)+"px; width: "+r.gutterTotalWidth+"px"),e.display.input.setUneditable(t.gutterBackground),i.insertBefore(t.gutterBackground,t.text)}var o=t.line.gutterMarkers;if(e.options.lineNumbers||o){var a=Nn(t),s=t.gutter=j("div",null,"CodeMirror-gutter-wrapper","left: "+(e.options.fixedGutter?r.fixedPos:-r.gutterTotalWidth)+"px");if(e.display.input.setUneditable(s),a.insertBefore(s,t.text),t.line.gutterClass&&(s.className+=" "+t.line.gutterClass),!e.options.lineNumbers||o&&o["CodeMirror-linenumbers"]||(t.lineNumber=s.appendChild(j("div",it(e.options,n),"CodeMirror-linenumber CodeMirror-gutter-elt","left: "+r.gutterLeft["CodeMirror-linenumbers"]+"px; width: "+e.display.lineNumInnerWidth+"px"))),o)for(var l=0;l<e.display.gutterSpecs.length;++l){var u=e.display.gutterSpecs[l].className,c=o.hasOwnProperty(u)&&o[u];c&&s.appendChild(j("div",[c],"CodeMirror-gutter-elt","left: "+r.gutterLeft[u]+"px; width: "+r.gutterWidth[u]+"px"))}}}function In(e,t,n){t.alignable&&(t.alignable=null);for(var r=C("CodeMirror-linewidget"),i=t.node.firstChild,o=void 0;i;i=o)o=i.nextSibling,r.test(i.className)&&t.node.removeChild(i);Rn(e,t,n)}function $n(e,t,n,r){var i=Mn(e,t);return t.text=t.node=i.pre,i.bgClass&&(t.bgClass=i.bgClass),i.textClass&&(t.textClass=i.textClass),Fn(e,t),qn(e,t,n,r),Rn(e,t,r),t.node}function Rn(e,t,n){if(zn(e,t.line,t,n,!0),t.rest)for(var r=0;r<t.rest.length;r++)zn(e,t.rest[r],t,n,!1)}function zn(e,t,n,r,i){if(t.widgets)for(var o=Nn(n),a=0,s=t.widgets;a<s.length;++a){var l=s[a],u=j("div",[l.node],"CodeMirror-linewidget"+(l.className?" "+l.className:""));l.handleMouseEvents||u.setAttribute("cm-ignore-events","true"),Bn(l,u,n,r),e.display.input.setUneditable(u),i&&l.above?o.insertBefore(u,n.gutter||n.text):o.appendChild(u),jn(l,"redraw")}}function Bn(e,t,n,r){if(e.noHScroll){(n.alignable||(n.alignable=[])).push(t);var i=r.wrapperWidth;t.style.left=r.fixedPos+"px",e.coverGutter||(i-=r.gutterTotalWidth,t.style.paddingLeft=r.gutterTotalWidth+"px"),t.style.width=i+"px"}e.coverGutter&&(t.style.zIndex=5,t.style.position="relative",e.noHScroll||(t.style.marginLeft=-r.gutterTotalWidth+"px"))}function Wn(e){if(null!=e.height)return e.height;var t=e.doc.cm;if(!t)return 0;if(!D(document.body,e.node)){var n="position: relative;";e.coverGutter&&(n+="margin-left: -"+t.display.gutters.offsetWidth+"px;"),e.noHScroll&&(n+="width: "+t.display.wrapper.clientWidth+"px;"),S(t.display.measure,j("div",[e.node],null,n))}return e.height=e.node.parentNode.offsetHeight}function Hn(e,t){for(var n=Oe(t);n!=e.wrapper;n=n.parentNode)if(!n||1==n.nodeType&&"true"==n.getAttribute("cm-ignore-events")||n.parentNode==e.sizer&&n!=e.mover)return!0}function Un(e){return e.lineSpace.offsetTop}function Vn(e){return e.mover.offsetHeight-e.lineSpace.offsetHeight}function Kn(e){if(e.cachedPaddingH)return e.cachedPaddingH;var t=S(e.measure,j("pre","x","CodeMirror-line-like")),n=window.getComputedStyle?window.getComputedStyle(t):t.currentStyle,r={left:parseInt(n.paddingLeft),right:parseInt(n.paddingRight)};return isNaN(r.left)||isNaN(r.right)||(e.cachedPaddingH=r),r}function Yn(e){return z-e.display.nativeBarWidth}function Gn(e){return e.display.scroller.clientWidth-Yn(e)-e.display.barWidth}function Zn(e){return e.display.scroller.clientHeight-Yn(e)-e.display.barHeight}function Xn(e,t,n){var r=e.options.lineWrapping,i=r&&Gn(e);if(!t.measure.heights||r&&t.measure.width!=i){var o=t.measure.heights=[];if(r){t.measure.width=i;for(var a=t.text.firstChild.getClientRects(),s=0;s<a.length-1;s++){var l=a[s],u=a[s+1];Math.abs(l.bottom-u.bottom)>2&&o.push((l.bottom+u.top)/2-n.top)}}o.push(n.bottom-n.top)}}function Jn(e,t,n){if(e.line==t)return{map:e.measure.map,cache:e.measure.cache};for(var r=0;r<e.rest.length;r++)if(e.rest[r]==t)return{map:e.measure.maps[r],cache:e.measure.caches[r]};for(var i=0;i<e.rest.length;i++)if(tt(e.rest[i])>n)return{map:e.measure.maps[i],cache:e.measure.caches[i],before:!0}}function Qn(e,t){var n=tt(t=Jt(t)),r=e.display.externalMeasured=new xn(e.doc,t,n);r.lineN=n;var i=r.built=gn(e,r);return r.text=i.pre,S(e.display.lineMeasure,i.pre),r}function er(e,t,n,r){return rr(e,nr(e,t),n,r)}function tr(e,t){if(t>=e.display.viewFrom&&t<e.display.viewTo)return e.display.view[Fr(e,t)];var n=e.display.externalMeasured;return n&&t>=n.lineN&&t<n.lineN+n.size?n:void 0}function nr(e,t){var n=tt(t),r=tr(e,n);r&&!r.text?r=null:r&&r.changes&&(Dn(e,r,n,Dr(e)),e.curOp.forceUpdate=!0),r||(r=Qn(e,t));var i=Jn(r,t,n);return{line:t,view:r,rect:null,map:i.map,cache:i.cache,before:i.before,hasHeights:!1}}function rr(e,t,n,r,i){t.before&&(n=-1);var o,a=n+(r||"");return t.cache.hasOwnProperty(a)?o=t.cache[a]:(t.rect||(t.rect=t.view.text.getBoundingClientRect()),t.hasHeights||(Xn(e,t.view,t.rect),t.hasHeights=!0),(o=lr(e,t,n,r)).bogus||(t.cache[a]=o)),{left:o.left,right:o.right,top:i?o.rtop:o.top,bottom:i?o.rbottom:o.bottom}}var ir,or={left:0,right:0,top:0,bottom:0};function ar(e,t,n){for(var r,i,o,a,s,l,u=0;u<e.length;u+=3)if(s=e[u],l=e[u+1],t<s?(i=0,o=1,a="left"):t<l?o=1+(i=t-s):(u==e.length-3||t==l&&e[u+3]>t)&&(i=(o=l-s)-1,t>=l&&(a="right")),null!=i){if(r=e[u+2],s==l&&n==(r.insertLeft?"left":"right")&&(a=n),"left"==n&&0==i)for(;u&&e[u-2]==e[u-3]&&e[u-1].insertLeft;)r=e[2+(u-=3)],a="left";if("right"==n&&i==l-s)for(;u<e.length-3&&e[u+3]==e[u+4]&&!e[u+5].insertLeft;)r=e[(u+=3)+2],a="right";break}return{node:r,start:i,end:o,collapse:a,coverStart:s,coverEnd:l}}function sr(e,t){var n=or;if("left"==t)for(var r=0;r<e.length&&(n=e[r]).left==n.right;r++);else for(var i=e.length-1;i>=0&&(n=e[i]).left==n.right;i--);return n}function lr(e,t,n,r){var i,o=ar(t.map,n,r),l=o.node,u=o.start,c=o.end,f=o.collapse;if(3==l.nodeType){for(var p=0;p<4;p++){for(;u&&oe(t.line.text.charAt(o.coverStart+u));)--u;for(;o.coverStart+c<o.coverEnd&&oe(t.line.text.charAt(o.coverStart+c));)++c;if((i=a&&s<9&&0==u&&c==o.coverEnd-o.coverStart?l.parentNode.getBoundingClientRect():sr(E(l,u,c).getClientRects(),r)).left||i.right||0==u)break;c=u,u-=1,f="right"}a&&s<11&&(i=ur(e.display.measure,i))}else{var d;u>0&&(f=r="right"),i=e.options.lineWrapping&&(d=l.getClientRects()).length>1?d["right"==r?d.length-1:0]:l.getBoundingClientRect()}if(a&&s<9&&!u&&(!i||!i.left&&!i.right)){var h=l.parentNode.getClientRects()[0];i=h?{left:h.left,right:h.left+Tr(e.display),top:h.top,bottom:h.bottom}:or}for(var g=i.top-t.rect.top,m=i.bottom-t.rect.top,v=(g+m)/2,y=t.view.measure.heights,b=0;b<y.length-1&&!(v<y[b]);b++);var _=b?y[b-1]:0,w=y[b],x={left:("right"==f?i.right:i.left)-t.rect.left,right:("left"==f?i.left:i.right)-t.rect.left,top:_,bottom:w};return i.left||i.right||(x.bogus=!0),e.options.singleCursorHeightPerLine||(x.rtop=g,x.rbottom=m),x}function ur(e,t){if(!window.screen||null==screen.logicalXDPI||screen.logicalXDPI==screen.deviceXDPI||!Ie(e))return t;var n=screen.logicalXDPI/screen.deviceXDPI,r=screen.logicalYDPI/screen.deviceYDPI;return{left:t.left*n,right:t.right*n,top:t.top*r,bottom:t.bottom*r}}function cr(e){if(e.measure&&(e.measure.cache={},e.measure.heights=null,e.rest))for(var t=0;t<e.rest.length;t++)e.measure.caches[t]={}}function fr(e){e.display.externalMeasure=null,A(e.display.lineMeasure);for(var t=0;t<e.display.view.length;t++)cr(e.display.view[t])}function pr(e){fr(e),e.display.cachedCharWidth=e.display.cachedTextHeight=e.display.cachedPaddingH=null,e.options.lineWrapping||(e.display.maxLineChanged=!0),e.display.lineNumChars=null}function dr(){return c&&m?-(document.body.getBoundingClientRect().left-parseInt(getComputedStyle(document.body).marginLeft)):window.pageXOffset||(document.documentElement||document.body).scrollLeft}function hr(){return c&&m?-(document.body.getBoundingClientRect().top-parseInt(getComputedStyle(document.body).marginTop)):window.pageYOffset||(document.documentElement||document.body).scrollTop}function gr(e){var t=0;if(e.widgets)for(var n=0;n<e.widgets.length;++n)e.widgets[n].above&&(t+=Wn(e.widgets[n]));return t}function mr(e,t,n,r,i){if(!i){var o=gr(t);n.top+=o,n.bottom+=o}if("line"==r)return n;r||(r="local");var a=an(t);if("local"==r?a+=Un(e.display):a-=e.display.viewOffset,"page"==r||"window"==r){var s=e.display.lineSpace.getBoundingClientRect();a+=s.top+("window"==r?0:hr());var l=s.left+("window"==r?0:dr());n.left+=l,n.right+=l}return n.top+=a,n.bottom+=a,n}function vr(e,t,n){if("div"==n)return t;var r=t.left,i=t.top;if("page"==n)r-=dr(),i-=hr();else if("local"==n||!n){var o=e.display.sizer.getBoundingClientRect();r+=o.left,i+=o.top}var a=e.display.lineSpace.getBoundingClientRect();return{left:r-a.left,top:i-a.top}}function yr(e,t,n,r,i){return r||(r=Xe(e.doc,t.line)),mr(e,r,er(e,r,t.ch,i),n)}function br(e,t,n,r,i,o){function a(t,a){var s=rr(e,i,t,a?"right":"left",o);return a?s.left=s.right:s.right=s.left,mr(e,r,s,n)}r=r||Xe(e.doc,t.line),i||(i=nr(e,r));var s=pe(r,e.doc.direction),l=t.ch,u=t.sticky;if(l>=r.text.length?(l=r.text.length,u="before"):l<=0&&(l=0,u="after"),!s)return a("before"==u?l-1:l,"before"==u);function c(e,t,n){return a(n?e-1:e,1==s[t].level!=n)}var f=ce(s,l,u),p=ue,d=c(l,f,"before"==u);return null!=p&&(d.other=c(l,p,"before"!=u)),d}function _r(e,t){var n=0;t=pt(e.doc,t),e.options.lineWrapping||(n=Tr(e.display)*t.ch);var r=Xe(e.doc,t.line),i=an(r)+Un(e.display);return{left:n,right:n,top:i,bottom:i+r.height}}function wr(e,t,n,r,i){var o=ot(e,t,n);return o.xRel=i,r&&(o.outside=r),o}function xr(e,t,n){var r=e.doc;if((n+=e.display.viewOffset)<0)return wr(r.first,0,null,-1,-1);var i=nt(r,n),o=r.first+r.size-1;if(i>o)return wr(r.first+r.size-1,Xe(r,o).text.length,null,1,1);t<0&&(t=0);for(var a=Xe(r,i);;){var s=Or(e,a,i,t,n),l=Zt(a,s.ch+(s.xRel>0||s.outside>0?1:0));if(!l)return s;var u=l.find(1);if(u.line==i)return u;a=Xe(r,i=u.line)}}function kr(e,t,n,r){r-=gr(t);var i=t.text.length,o=se((function(t){return rr(e,n,t-1).bottom<=r}),i,0);return{begin:o,end:i=se((function(t){return rr(e,n,t).top>r}),o,i)}}function Cr(e,t,n,r){return n||(n=nr(e,t)),kr(e,t,n,mr(e,t,rr(e,n,r),"line").top)}function Er(e,t,n,r){return!(e.bottom<=n)&&(e.top>n||(r?e.left:e.right)>t)}function Or(e,t,n,r,i){i-=an(t);var o=nr(e,t),a=gr(t),s=0,l=t.text.length,u=!0,c=pe(t,e.doc.direction);if(c){var f=(e.options.lineWrapping?Sr:Ar)(e,t,n,o,c,r,i);s=(u=1!=f.level)?f.from:f.to-1,l=u?f.to:f.from-1}var p,d,h=null,g=null,m=se((function(t){var n=rr(e,o,t);return n.top+=a,n.bottom+=a,!!Er(n,r,i,!1)&&(n.top<=i&&n.left<=r&&(h=t,g=n),!0)}),s,l),v=!1;if(g){var y=r-g.left<g.right-r,b=y==u;m=h+(b?0:1),d=b?"after":"before",p=y?g.left:g.right}else{u||m!=l&&m!=s||m++,d=0==m?"after":m==t.text.length?"before":rr(e,o,m-(u?1:0)).bottom+a<=i==u?"after":"before";var _=br(e,ot(n,m,d),"line",t,o);p=_.left,v=i<_.top?-1:i>=_.bottom?1:0}return wr(n,m=ae(t.text,m,1),d,v,r-p)}function Ar(e,t,n,r,i,o,a){var s=se((function(s){var l=i[s],u=1!=l.level;return Er(br(e,ot(n,u?l.to:l.from,u?"before":"after"),"line",t,r),o,a,!0)}),0,i.length-1),l=i[s];if(s>0){var u=1!=l.level,c=br(e,ot(n,u?l.from:l.to,u?"after":"before"),"line",t,r);Er(c,o,a,!0)&&c.top>a&&(l=i[s-1])}return l}function Sr(e,t,n,r,i,o,a){var s=kr(e,t,r,a),l=s.begin,u=s.end;/\s/.test(t.text.charAt(u-1))&&u--;for(var c=null,f=null,p=0;p<i.length;p++){var d=i[p];if(!(d.from>=u||d.to<=l)){var h=rr(e,r,1!=d.level?Math.min(u,d.to)-1:Math.max(l,d.from)).right,g=h<o?o-h+1e9:h-o;(!c||f>g)&&(c=d,f=g)}}return c||(c=i[i.length-1]),c.from<l&&(c={from:l,to:c.to,level:c.level}),c.to>u&&(c={from:c.from,to:u,level:c.level}),c}function jr(e){if(null!=e.cachedTextHeight)return e.cachedTextHeight;if(null==ir){ir=j("pre",null,"CodeMirror-line-like");for(var t=0;t<49;++t)ir.appendChild(document.createTextNode("x")),ir.appendChild(j("br"));ir.appendChild(document.createTextNode("x"))}S(e.measure,ir);var n=ir.offsetHeight/50;return n>3&&(e.cachedTextHeight=n),A(e.measure),n||1}function Tr(e){if(null!=e.cachedCharWidth)return e.cachedCharWidth;var t=j("span","xxxxxxxxxx"),n=j("pre",[t],"CodeMirror-line-like");S(e.measure,n);var r=t.getBoundingClientRect(),i=(r.right-r.left)/10;return i>2&&(e.cachedCharWidth=i),i||10}function Dr(e){for(var t=e.display,n={},r={},i=t.gutters.clientLeft,o=t.gutters.firstChild,a=0;o;o=o.nextSibling,++a){var s=e.display.gutterSpecs[a].className;n[s]=o.offsetLeft+o.clientLeft+i,r[s]=o.clientWidth}return{fixedPos:Nr(t),gutterTotalWidth:t.gutters.offsetWidth,gutterLeft:n,gutterWidth:r,wrapperWidth:t.wrapper.clientWidth}}function Nr(e){return e.scroller.getBoundingClientRect().left-e.sizer.getBoundingClientRect().left}function Lr(e){var t=jr(e.display),n=e.options.lineWrapping,r=n&&Math.max(5,e.display.scroller.clientWidth/Tr(e.display)-3);return function(i){if(rn(e.doc,i))return 0;var o=0;if(i.widgets)for(var a=0;a<i.widgets.length;a++)i.widgets[a].height&&(o+=i.widgets[a].height);return n?o+(Math.ceil(i.text.length/r)||1)*t:o+t}}function Mr(e){var t=e.doc,n=Lr(e);t.iter((function(e){var t=n(e);t!=e.height&&et(e,t)}))}function Pr(e,t,n,r){var i=e.display;if(!n&&"true"==Oe(t).getAttribute("cm-not-content"))return null;var o,a,s=i.lineSpace.getBoundingClientRect();try{o=t.clientX-s.left,a=t.clientY-s.top}catch(f){return null}var l,u=xr(e,o,a);if(r&&u.xRel>0&&(l=Xe(e.doc,u.line).text).length==u.ch){var c=I(l,l.length,e.options.tabSize)-l.length;u=ot(u.line,Math.max(0,Math.round((o-Kn(e.display).left)/Tr(e.display))-c))}return u}function Fr(e,t){if(t>=e.display.viewTo)return null;if((t-=e.display.viewFrom)<0)return null;for(var n=e.display.view,r=0;r<n.length;r++)if((t-=n[r].size)<0)return r}function qr(e,t,n,r){null==t&&(t=e.doc.first),null==n&&(n=e.doc.first+e.doc.size),r||(r=0);var i=e.display;if(r&&n<i.viewTo&&(null==i.updateLineNumbers||i.updateLineNumbers>t)&&(i.updateLineNumbers=t),e.curOp.viewChanged=!0,t>=i.viewTo)Tt&&tn(e.doc,t)<i.viewTo&&$r(e);else if(n<=i.viewFrom)Tt&&nn(e.doc,n+r)>i.viewFrom?$r(e):(i.viewFrom+=r,i.viewTo+=r);else if(t<=i.viewFrom&&n>=i.viewTo)$r(e);else if(t<=i.viewFrom){var o=Rr(e,n,n+r,1);o?(i.view=i.view.slice(o.index),i.viewFrom=o.lineN,i.viewTo+=r):$r(e)}else if(n>=i.viewTo){var a=Rr(e,t,t,-1);a?(i.view=i.view.slice(0,a.index),i.viewTo=a.lineN):$r(e)}else{var s=Rr(e,t,t,-1),l=Rr(e,n,n+r,1);s&&l?(i.view=i.view.slice(0,s.index).concat(kn(e,s.lineN,l.lineN)).concat(i.view.slice(l.index)),i.viewTo+=r):$r(e)}var u=i.externalMeasured;u&&(n<u.lineN?u.lineN+=r:t<u.lineN+u.size&&(i.externalMeasured=null))}function Ir(e,t,n){e.curOp.viewChanged=!0;var r=e.display,i=e.display.externalMeasured;if(i&&t>=i.lineN&&t<i.lineN+i.size&&(r.externalMeasured=null),!(t<r.viewFrom||t>=r.viewTo)){var o=r.view[Fr(e,t)];if(null!=o.node){var a=o.changes||(o.changes=[]);-1==R(a,n)&&a.push(n)}}}function $r(e){e.display.viewFrom=e.display.viewTo=e.doc.first,e.display.view=[],e.display.viewOffset=0}function Rr(e,t,n,r){var i,o=Fr(e,t),a=e.display.view;if(!Tt||n==e.doc.first+e.doc.size)return{index:o,lineN:n};for(var s=e.display.viewFrom,l=0;l<o;l++)s+=a[l].size;if(s!=t){if(r>0){if(o==a.length-1)return null;i=s+a[o].size-t,o++}else i=s-t;t+=i,n+=i}for(;tn(e.doc,n)!=n;){if(o==(r<0?0:a.length-1))return null;n+=r*a[o-(r<0?1:0)].size,o+=r}return{index:o,lineN:n}}function zr(e,t,n){var r=e.display;0==r.view.length||t>=r.viewTo||n<=r.viewFrom?(r.view=kn(e,t,n),r.viewFrom=t):(r.viewFrom>t?r.view=kn(e,t,r.viewFrom).concat(r.view):r.viewFrom<t&&(r.view=r.view.slice(Fr(e,t))),r.viewFrom=t,r.viewTo<n?r.view=r.view.concat(kn(e,r.viewTo,n)):r.viewTo>n&&(r.view=r.view.slice(0,Fr(e,n)))),r.viewTo=n}function Br(e){for(var t=e.display.view,n=0,r=0;r<t.length;r++){var i=t[r];i.hidden||i.node&&!i.changes||++n}return n}function Wr(e){e.display.input.showSelection(e.display.input.prepareSelection())}function Hr(e,t){void 0===t&&(t=!0);for(var n=e.doc,r={},i=r.cursors=document.createDocumentFragment(),o=r.selection=document.createDocumentFragment(),a=0;a<n.sel.ranges.length;a++)if(t||a!=n.sel.primIndex){var s=n.sel.ranges[a];if(!(s.from().line>=e.display.viewTo||s.to().line<e.display.viewFrom)){var l=s.empty();(l||e.options.showCursorWhenSelecting)&&Ur(e,s.head,i),l||Kr(e,s,o)}}return r}function Ur(e,t,n){var r=br(e,t,"div",null,null,!e.options.singleCursorHeightPerLine),i=n.appendChild(j("div"," ","CodeMirror-cursor"));if(i.style.left=r.left+"px",i.style.top=r.top+"px",i.style.height=Math.max(0,r.bottom-r.top)*e.options.cursorHeight+"px",r.other){var o=n.appendChild(j("div"," ","CodeMirror-cursor CodeMirror-secondarycursor"));o.style.display="",o.style.left=r.other.left+"px",o.style.top=r.other.top+"px",o.style.height=.85*(r.other.bottom-r.other.top)+"px"}}function Vr(e,t){return e.top-t.top||e.left-t.left}function Kr(e,t,n){var r=e.display,i=e.doc,o=document.createDocumentFragment(),a=Kn(e.display),s=a.left,l=Math.max(r.sizerWidth,Gn(e)-r.sizer.offsetLeft)-a.right,u="ltr"==i.direction;function c(e,t,n,r){t<0&&(t=0),t=Math.round(t),r=Math.round(r),o.appendChild(j("div",null,"CodeMirror-selected","position: absolute; left: "+e+"px;\n top: "+t+"px; width: "+(null==n?l-e:n)+"px;\n height: "+(r-t)+"px"))}function f(t,n,r){var o,a,f=Xe(i,t),p=f.text.length;function d(n,r){return yr(e,ot(t,n),"div",f,r)}function h(t,n,r){var i=Cr(e,f,null,t),o="ltr"==n==("after"==r)?"left":"right";return d("after"==r?i.begin:i.end-(/\s/.test(f.text.charAt(i.end-1))?2:1),o)[o]}var g=pe(f,i.direction);return le(g,n||0,null==r?p:r,(function(e,t,i,f){var m="ltr"==i,v=d(e,m?"left":"right"),y=d(t-1,m?"right":"left"),b=null==n&&0==e,_=null==r&&t==p,w=0==f,x=!g||f==g.length-1;if(y.top-v.top<=3){var k=(u?_:b)&&x,C=(u?b:_)&&w?s:(m?v:y).left,E=k?l:(m?y:v).right;c(C,v.top,E-C,v.bottom)}else{var O,A,S,j;m?(O=u&&b&&w?s:v.left,A=u?l:h(e,i,"before"),S=u?s:h(t,i,"after"),j=u&&_&&x?l:y.right):(O=u?h(e,i,"before"):s,A=!u&&b&&w?l:v.right,S=!u&&_&&x?s:y.left,j=u?h(t,i,"after"):l),c(O,v.top,A-O,v.bottom),v.bottom<y.top&&c(s,v.bottom,null,y.top),c(S,y.top,j-S,y.bottom)}(!o||Vr(v,o)<0)&&(o=v),Vr(y,o)<0&&(o=y),(!a||Vr(v,a)<0)&&(a=v),Vr(y,a)<0&&(a=y)})),{start:o,end:a}}var p=t.from(),d=t.to();if(p.line==d.line)f(p.line,p.ch,d.ch);else{var h=Xe(i,p.line),g=Xe(i,d.line),m=Jt(h)==Jt(g),v=f(p.line,p.ch,m?h.text.length+1:null).end,y=f(d.line,m?0:null,d.ch).start;m&&(v.top<y.top-2?(c(v.right,v.top,null,v.bottom),c(s,y.top,y.left,y.bottom)):c(v.right,v.top,y.left-v.right,v.bottom)),v.bottom<y.top&&c(s,v.bottom,null,y.top)}n.appendChild(o)}function Yr(e){if(e.state.focused){var t=e.display;clearInterval(t.blinker);var n=!0;t.cursorDiv.style.visibility="",e.options.cursorBlinkRate>0?t.blinker=setInterval((function(){e.hasFocus()||Jr(e),t.cursorDiv.style.visibility=(n=!n)?"":"hidden"}),e.options.cursorBlinkRate):e.options.cursorBlinkRate<0&&(t.cursorDiv.style.visibility="hidden")}}function Gr(e){e.hasFocus()||(e.display.input.focus(),e.state.focused||Xr(e))}function Zr(e){e.state.delayingBlurEvent=!0,setTimeout((function(){e.state.delayingBlurEvent&&(e.state.delayingBlurEvent=!1,e.state.focused&&Jr(e))}),100)}function Xr(e,t){e.state.delayingBlurEvent&&!e.state.draggingText&&(e.state.delayingBlurEvent=!1),"nocursor"!=e.options.readOnly&&(e.state.focused||(ve(e,"focus",e,t),e.state.focused=!0,L(e.display.wrapper,"CodeMirror-focused"),e.curOp||e.display.selForContextMenu==e.doc.sel||(e.display.input.reset(),l&&setTimeout((function(){return e.display.input.reset(!0)}),20)),e.display.input.receivedFocus()),Yr(e))}function Jr(e,t){e.state.delayingBlurEvent||(e.state.focused&&(ve(e,"blur",e,t),e.state.focused=!1,O(e.display.wrapper,"CodeMirror-focused")),clearInterval(e.display.blinker),setTimeout((function(){e.state.focused||(e.display.shift=!1)}),150))}function Qr(e){for(var t=e.display,n=t.lineDiv.offsetTop,r=0;r<t.view.length;r++){var i=t.view[r],o=e.options.lineWrapping,l=void 0,u=0;if(!i.hidden){if(a&&s<8){var c=i.node.offsetTop+i.node.offsetHeight;l=c-n,n=c}else{var f=i.node.getBoundingClientRect();l=f.bottom-f.top,!o&&i.text.firstChild&&(u=i.text.firstChild.getBoundingClientRect().right-f.left-1)}var p=i.line.height-l;if((p>.005||p<-.005)&&(et(i.line,l),ei(i.line),i.rest))for(var d=0;d<i.rest.length;d++)ei(i.rest[d]);if(u>e.display.sizerWidth){var h=Math.ceil(u/Tr(e.display));h>e.display.maxLineLength&&(e.display.maxLineLength=h,e.display.maxLine=i.line,e.display.maxLineChanged=!0)}}}}function ei(e){if(e.widgets)for(var t=0;t<e.widgets.length;++t){var n=e.widgets[t],r=n.node.parentNode;r&&(n.height=r.offsetHeight)}}function ti(e,t,n){var r=n&&null!=n.top?Math.max(0,n.top):e.scroller.scrollTop;r=Math.floor(r-Un(e));var i=n&&null!=n.bottom?n.bottom:r+e.wrapper.clientHeight,o=nt(t,r),a=nt(t,i);if(n&&n.ensure){var s=n.ensure.from.line,l=n.ensure.to.line;s<o?(o=s,a=nt(t,an(Xe(t,s))+e.wrapper.clientHeight)):Math.min(l,t.lastLine())>=a&&(o=nt(t,an(Xe(t,l))-e.wrapper.clientHeight),a=l)}return{from:o,to:Math.max(a,o+1)}}function ni(e,t){if(!ye(e,"scrollCursorIntoView")){var n=e.display,r=n.sizer.getBoundingClientRect(),i=null;if(t.top+r.top<0?i=!0:t.bottom+r.top>(window.innerHeight||document.documentElement.clientHeight)&&(i=!1),null!=i&&!h){var o=j("div","",null,"position: absolute;\n top: "+(t.top-n.viewOffset-Un(e.display))+"px;\n height: "+(t.bottom-t.top+Yn(e)+n.barHeight)+"px;\n left: "+t.left+"px; width: "+Math.max(2,t.right-t.left)+"px;");e.display.lineSpace.appendChild(o),o.scrollIntoView(i),e.display.lineSpace.removeChild(o)}}}function ri(e,t,n,r){var i;null==r&&(r=0),e.options.lineWrapping||t!=n||(n="before"==(t=t.ch?ot(t.line,"before"==t.sticky?t.ch-1:t.ch,"after"):t).sticky?ot(t.line,t.ch+1,"before"):t);for(var o=0;o<5;o++){var a=!1,s=br(e,t),l=n&&n!=t?br(e,n):s,u=oi(e,i={left:Math.min(s.left,l.left),top:Math.min(s.top,l.top)-r,right:Math.max(s.left,l.left),bottom:Math.max(s.bottom,l.bottom)+r}),c=e.doc.scrollTop,f=e.doc.scrollLeft;if(null!=u.scrollTop&&(pi(e,u.scrollTop),Math.abs(e.doc.scrollTop-c)>1&&(a=!0)),null!=u.scrollLeft&&(hi(e,u.scrollLeft),Math.abs(e.doc.scrollLeft-f)>1&&(a=!0)),!a)break}return i}function ii(e,t){var n=oi(e,t);null!=n.scrollTop&&pi(e,n.scrollTop),null!=n.scrollLeft&&hi(e,n.scrollLeft)}function oi(e,t){var n=e.display,r=jr(e.display);t.top<0&&(t.top=0);var i=e.curOp&&null!=e.curOp.scrollTop?e.curOp.scrollTop:n.scroller.scrollTop,o=Zn(e),a={};t.bottom-t.top>o&&(t.bottom=t.top+o);var s=e.doc.height+Vn(n),l=t.top<r,u=t.bottom>s-r;if(t.top<i)a.scrollTop=l?0:t.top;else if(t.bottom>i+o){var c=Math.min(t.top,(u?s:t.bottom)-o);c!=i&&(a.scrollTop=c)}var f=e.options.fixedGutter?0:n.gutters.offsetWidth,p=e.curOp&&null!=e.curOp.scrollLeft?e.curOp.scrollLeft:n.scroller.scrollLeft-f,d=Gn(e)-n.gutters.offsetWidth,h=t.right-t.left>d;return h&&(t.right=t.left+d),t.left<10?a.scrollLeft=0:t.left<p?a.scrollLeft=Math.max(0,t.left+f-(h?0:10)):t.right>d+p-3&&(a.scrollLeft=t.right+(h?0:10)-d),a}function ai(e,t){null!=t&&(ci(e),e.curOp.scrollTop=(null==e.curOp.scrollTop?e.doc.scrollTop:e.curOp.scrollTop)+t)}function si(e){ci(e);var t=e.getCursor();e.curOp.scrollToPos={from:t,to:t,margin:e.options.cursorScrollMargin}}function li(e,t,n){null==t&&null==n||ci(e),null!=t&&(e.curOp.scrollLeft=t),null!=n&&(e.curOp.scrollTop=n)}function ui(e,t){ci(e),e.curOp.scrollToPos=t}function ci(e){var t=e.curOp.scrollToPos;t&&(e.curOp.scrollToPos=null,fi(e,_r(e,t.from),_r(e,t.to),t.margin))}function fi(e,t,n,r){var i=oi(e,{left:Math.min(t.left,n.left),top:Math.min(t.top,n.top)-r,right:Math.max(t.right,n.right),bottom:Math.max(t.bottom,n.bottom)+r});li(e,i.scrollLeft,i.scrollTop)}function pi(e,t){Math.abs(e.doc.scrollTop-t)<2||(n||Wi(e,{top:t}),di(e,t,!0),n&&Wi(e),Pi(e,100))}function di(e,t,n){t=Math.max(0,Math.min(e.display.scroller.scrollHeight-e.display.scroller.clientHeight,t)),(e.display.scroller.scrollTop!=t||n)&&(e.doc.scrollTop=t,e.display.scrollbars.setScrollTop(t),e.display.scroller.scrollTop!=t&&(e.display.scroller.scrollTop=t))}function hi(e,t,n,r){t=Math.max(0,Math.min(t,e.display.scroller.scrollWidth-e.display.scroller.clientWidth)),(n?t==e.doc.scrollLeft:Math.abs(e.doc.scrollLeft-t)<2)&&!r||(e.doc.scrollLeft=t,Ki(e),e.display.scroller.scrollLeft!=t&&(e.display.scroller.scrollLeft=t),e.display.scrollbars.setScrollLeft(t))}function gi(e){var t=e.display,n=t.gutters.offsetWidth,r=Math.round(e.doc.height+Vn(e.display));return{clientHeight:t.scroller.clientHeight,viewHeight:t.wrapper.clientHeight,scrollWidth:t.scroller.scrollWidth,clientWidth:t.scroller.clientWidth,viewWidth:t.wrapper.clientWidth,barLeft:e.options.fixedGutter?n:0,docHeight:r,scrollHeight:r+Yn(e)+t.barHeight,nativeBarWidth:t.nativeBarWidth,gutterWidth:n}}var mi=function(e,t,n){this.cm=n;var r=this.vert=j("div",[j("div",null,null,"min-width: 1px")],"CodeMirror-vscrollbar"),i=this.horiz=j("div",[j("div",null,null,"height: 100%; min-height: 1px")],"CodeMirror-hscrollbar");r.tabIndex=i.tabIndex=-1,e(r),e(i),he(r,"scroll",(function(){r.clientHeight&&t(r.scrollTop,"vertical")})),he(i,"scroll",(function(){i.clientWidth&&t(i.scrollLeft,"horizontal")})),this.checkedZeroWidth=!1,a&&s<8&&(this.horiz.style.minHeight=this.vert.style.minWidth="18px")};mi.prototype.update=function(e){var t=e.scrollWidth>e.clientWidth+1,n=e.scrollHeight>e.clientHeight+1,r=e.nativeBarWidth;if(n){this.vert.style.display="block",this.vert.style.bottom=t?r+"px":"0";var i=e.viewHeight-(t?r:0);this.vert.firstChild.style.height=Math.max(0,e.scrollHeight-e.clientHeight+i)+"px"}else this.vert.style.display="",this.vert.firstChild.style.height="0";if(t){this.horiz.style.display="block",this.horiz.style.right=n?r+"px":"0",this.horiz.style.left=e.barLeft+"px";var o=e.viewWidth-e.barLeft-(n?r:0);this.horiz.firstChild.style.width=Math.max(0,e.scrollWidth-e.clientWidth+o)+"px"}else this.horiz.style.display="",this.horiz.firstChild.style.width="0";return!this.checkedZeroWidth&&e.clientHeight>0&&(0==r&&this.zeroWidthHack(),this.checkedZeroWidth=!0),{right:n?r:0,bottom:t?r:0}},mi.prototype.setScrollLeft=function(e){this.horiz.scrollLeft!=e&&(this.horiz.scrollLeft=e),this.disableHoriz&&this.enableZeroWidthBar(this.horiz,this.disableHoriz,"horiz")},mi.prototype.setScrollTop=function(e){this.vert.scrollTop!=e&&(this.vert.scrollTop=e),this.disableVert&&this.enableZeroWidthBar(this.vert,this.disableVert,"vert")},mi.prototype.zeroWidthHack=function(){var e=y&&!d?"12px":"18px";this.horiz.style.height=this.vert.style.width=e,this.horiz.style.pointerEvents=this.vert.style.pointerEvents="none",this.disableHoriz=new $,this.disableVert=new $},mi.prototype.enableZeroWidthBar=function(e,t,n){function r(){var i=e.getBoundingClientRect();("vert"==n?document.elementFromPoint(i.right-1,(i.top+i.bottom)/2):document.elementFromPoint((i.right+i.left)/2,i.bottom-1))!=e?e.style.pointerEvents="none":t.set(1e3,r)}e.style.pointerEvents="auto",t.set(1e3,r)},mi.prototype.clear=function(){var e=this.horiz.parentNode;e.removeChild(this.horiz),e.removeChild(this.vert)};var vi=function(){};function yi(e,t){t||(t=gi(e));var n=e.display.barWidth,r=e.display.barHeight;bi(e,t);for(var i=0;i<4&&n!=e.display.barWidth||r!=e.display.barHeight;i++)n!=e.display.barWidth&&e.options.lineWrapping&&Qr(e),bi(e,gi(e)),n=e.display.barWidth,r=e.display.barHeight}function bi(e,t){var n=e.display,r=n.scrollbars.update(t);n.sizer.style.paddingRight=(n.barWidth=r.right)+"px",n.sizer.style.paddingBottom=(n.barHeight=r.bottom)+"px",n.heightForcer.style.borderBottom=r.bottom+"px solid transparent",r.right&&r.bottom?(n.scrollbarFiller.style.display="block",n.scrollbarFiller.style.height=r.bottom+"px",n.scrollbarFiller.style.width=r.right+"px"):n.scrollbarFiller.style.display="",r.bottom&&e.options.coverGutterNextToScrollbar&&e.options.fixedGutter?(n.gutterFiller.style.display="block",n.gutterFiller.style.height=r.bottom+"px",n.gutterFiller.style.width=t.gutterWidth+"px"):n.gutterFiller.style.display=""}vi.prototype.update=function(){return{bottom:0,right:0}},vi.prototype.setScrollLeft=function(){},vi.prototype.setScrollTop=function(){},vi.prototype.clear=function(){};var _i={native:mi,null:vi};function wi(e){e.display.scrollbars&&(e.display.scrollbars.clear(),e.display.scrollbars.addClass&&O(e.display.wrapper,e.display.scrollbars.addClass)),e.display.scrollbars=new _i[e.options.scrollbarStyle]((function(t){e.display.wrapper.insertBefore(t,e.display.scrollbarFiller),he(t,"mousedown",(function(){e.state.focused&&setTimeout((function(){return e.display.input.focus()}),0)})),t.setAttribute("cm-not-content","true")}),(function(t,n){"horizontal"==n?hi(e,t):pi(e,t)}),e),e.display.scrollbars.addClass&&L(e.display.wrapper,e.display.scrollbars.addClass)}var xi=0;function ki(e){e.curOp={cm:e,viewChanged:!1,startHeight:e.doc.height,forceUpdate:!1,updateInput:0,typing:!1,changeObjs:null,cursorActivityHandlers:null,cursorActivityCalled:0,selectionChanged:!1,updateMaxLine:!1,scrollLeft:null,scrollTop:null,scrollToPos:null,focus:!1,id:++xi},En(e.curOp)}function Ci(e){var t=e.curOp;t&&An(t,(function(e){for(var t=0;t<e.ops.length;t++)e.ops[t].cm.curOp=null;Ei(e)}))}function Ei(e){for(var t=e.ops,n=0;n<t.length;n++)Oi(t[n]);for(var r=0;r<t.length;r++)Ai(t[r]);for(var i=0;i<t.length;i++)Si(t[i]);for(var o=0;o<t.length;o++)ji(t[o]);for(var a=0;a<t.length;a++)Ti(t[a])}function Oi(e){var t=e.cm,n=t.display;Ii(t),e.updateMaxLine&&ln(t),e.mustUpdate=e.viewChanged||e.forceUpdate||null!=e.scrollTop||e.scrollToPos&&(e.scrollToPos.from.line<n.viewFrom||e.scrollToPos.to.line>=n.viewTo)||n.maxLineChanged&&t.options.lineWrapping,e.update=e.mustUpdate&&new qi(t,e.mustUpdate&&{top:e.scrollTop,ensure:e.scrollToPos},e.forceUpdate)}function Ai(e){e.updatedDisplay=e.mustUpdate&&zi(e.cm,e.update)}function Si(e){var t=e.cm,n=t.display;e.updatedDisplay&&Qr(t),e.barMeasure=gi(t),n.maxLineChanged&&!t.options.lineWrapping&&(e.adjustWidthTo=er(t,n.maxLine,n.maxLine.text.length).left+3,t.display.sizerWidth=e.adjustWidthTo,e.barMeasure.scrollWidth=Math.max(n.scroller.clientWidth,n.sizer.offsetLeft+e.adjustWidthTo+Yn(t)+t.display.barWidth),e.maxScrollLeft=Math.max(0,n.sizer.offsetLeft+e.adjustWidthTo-Gn(t))),(e.updatedDisplay||e.selectionChanged)&&(e.preparedSelection=n.input.prepareSelection())}function ji(e){var t=e.cm;null!=e.adjustWidthTo&&(t.display.sizer.style.minWidth=e.adjustWidthTo+"px",e.maxScrollLeft<t.doc.scrollLeft&&hi(t,Math.min(t.display.scroller.scrollLeft,e.maxScrollLeft),!0),t.display.maxLineChanged=!1);var n=e.focus&&e.focus==N();e.preparedSelection&&t.display.input.showSelection(e.preparedSelection,n),(e.updatedDisplay||e.startHeight!=t.doc.height)&&yi(t,e.barMeasure),e.updatedDisplay&&Vi(t,e.barMeasure),e.selectionChanged&&Yr(t),t.state.focused&&e.updateInput&&t.display.input.reset(e.typing),n&&Gr(e.cm)}function Ti(e){var t=e.cm,n=t.display,r=t.doc;e.updatedDisplay&&Bi(t,e.update),null==n.wheelStartX||null==e.scrollTop&&null==e.scrollLeft&&!e.scrollToPos||(n.wheelStartX=n.wheelStartY=null),null!=e.scrollTop&&di(t,e.scrollTop,e.forceScroll),null!=e.scrollLeft&&hi(t,e.scrollLeft,!0,!0),e.scrollToPos&&ni(t,ri(t,pt(r,e.scrollToPos.from),pt(r,e.scrollToPos.to),e.scrollToPos.margin));var i=e.maybeHiddenMarkers,o=e.maybeUnhiddenMarkers;if(i)for(var a=0;a<i.length;++a)i[a].lines.length||ve(i[a],"hide");if(o)for(var s=0;s<o.length;++s)o[s].lines.length&&ve(o[s],"unhide");n.wrapper.offsetHeight&&(r.scrollTop=t.display.scroller.scrollTop),e.changeObjs&&ve(t,"changes",t,e.changeObjs),e.update&&e.update.finish()}function Di(e,t){if(e.curOp)return t();ki(e);try{return t()}finally{Ci(e)}}function Ni(e,t){return function(){if(e.curOp)return t.apply(e,arguments);ki(e);try{return t.apply(e,arguments)}finally{Ci(e)}}}function Li(e){return function(){if(this.curOp)return e.apply(this,arguments);ki(this);try{return e.apply(this,arguments)}finally{Ci(this)}}}function Mi(e){return function(){var t=this.cm;if(!t||t.curOp)return e.apply(this,arguments);ki(t);try{return e.apply(this,arguments)}finally{Ci(t)}}}function Pi(e,t){e.doc.highlightFrontier<e.display.viewTo&&e.state.highlight.set(t,F(Fi,e))}function Fi(e){var t=e.doc;if(!(t.highlightFrontier>=e.display.viewTo)){var n=+new Date+e.options.workTime,r=bt(e,t.highlightFrontier),i=[];t.iter(r.line,Math.min(t.first+t.size,e.display.viewTo+500),(function(o){if(r.line>=e.display.viewFrom){var a=o.styles,s=o.text.length>e.options.maxHighlightLength?Ke(t.mode,r.state):null,l=vt(e,o,r,!0);s&&(r.state=s),o.styles=l.styles;var u=o.styleClasses,c=l.classes;c?o.styleClasses=c:u&&(o.styleClasses=null);for(var f=!a||a.length!=o.styles.length||u!=c&&(!u||!c||u.bgClass!=c.bgClass||u.textClass!=c.textClass),p=0;!f&&p<a.length;++p)f=a[p]!=o.styles[p];f&&i.push(r.line),o.stateAfter=r.save(),r.nextLine()}else o.text.length<=e.options.maxHighlightLength&&_t(e,o.text,r),o.stateAfter=r.line%5==0?r.save():null,r.nextLine();if(+new Date>n)return Pi(e,e.options.workDelay),!0})),t.highlightFrontier=r.line,t.modeFrontier=Math.max(t.modeFrontier,r.line),i.length&&Di(e,(function(){for(var t=0;t<i.length;t++)Ir(e,i[t],"text")}))}}var qi=function(e,t,n){var r=e.display;this.viewport=t,this.visible=ti(r,e.doc,t),this.editorIsHidden=!r.wrapper.offsetWidth,this.wrapperHeight=r.wrapper.clientHeight,this.wrapperWidth=r.wrapper.clientWidth,this.oldDisplayWidth=Gn(e),this.force=n,this.dims=Dr(e),this.events=[]};function Ii(e){var t=e.display;!t.scrollbarsClipped&&t.scroller.offsetWidth&&(t.nativeBarWidth=t.scroller.offsetWidth-t.scroller.clientWidth,t.heightForcer.style.height=Yn(e)+"px",t.sizer.style.marginBottom=-t.nativeBarWidth+"px",t.sizer.style.borderRightWidth=Yn(e)+"px",t.scrollbarsClipped=!0)}function $i(e){if(e.hasFocus())return null;var t=N();if(!t||!D(e.display.lineDiv,t))return null;var n={activeElt:t};if(window.getSelection){var r=window.getSelection();r.anchorNode&&r.extend&&D(e.display.lineDiv,r.anchorNode)&&(n.anchorNode=r.anchorNode,n.anchorOffset=r.anchorOffset,n.focusNode=r.focusNode,n.focusOffset=r.focusOffset)}return n}function Ri(e){if(e&&e.activeElt&&e.activeElt!=N()&&(e.activeElt.focus(),!/^(INPUT|TEXTAREA)$/.test(e.activeElt.nodeName)&&e.anchorNode&&D(document.body,e.anchorNode)&&D(document.body,e.focusNode))){var t=window.getSelection(),n=document.createRange();n.setEnd(e.anchorNode,e.anchorOffset),n.collapse(!1),t.removeAllRanges(),t.addRange(n),t.extend(e.focusNode,e.focusOffset)}}function zi(e,t){var n=e.display,r=e.doc;if(t.editorIsHidden)return $r(e),!1;if(!t.force&&t.visible.from>=n.viewFrom&&t.visible.to<=n.viewTo&&(null==n.updateLineNumbers||n.updateLineNumbers>=n.viewTo)&&n.renderedView==n.view&&0==Br(e))return!1;Yi(e)&&($r(e),t.dims=Dr(e));var i=r.first+r.size,o=Math.max(t.visible.from-e.options.viewportMargin,r.first),a=Math.min(i,t.visible.to+e.options.viewportMargin);n.viewFrom<o&&o-n.viewFrom<20&&(o=Math.max(r.first,n.viewFrom)),n.viewTo>a&&n.viewTo-a<20&&(a=Math.min(i,n.viewTo)),Tt&&(o=tn(e.doc,o),a=nn(e.doc,a));var s=o!=n.viewFrom||a!=n.viewTo||n.lastWrapHeight!=t.wrapperHeight||n.lastWrapWidth!=t.wrapperWidth;zr(e,o,a),n.viewOffset=an(Xe(e.doc,n.viewFrom)),e.display.mover.style.top=n.viewOffset+"px";var l=Br(e);if(!s&&0==l&&!t.force&&n.renderedView==n.view&&(null==n.updateLineNumbers||n.updateLineNumbers>=n.viewTo))return!1;var u=$i(e);return l>4&&(n.lineDiv.style.display="none"),Hi(e,n.updateLineNumbers,t.dims),l>4&&(n.lineDiv.style.display=""),n.renderedView=n.view,Ri(u),A(n.cursorDiv),A(n.selectionDiv),n.gutters.style.height=n.sizer.style.minHeight=0,s&&(n.lastWrapHeight=t.wrapperHeight,n.lastWrapWidth=t.wrapperWidth,Pi(e,400)),n.updateLineNumbers=null,!0}function Bi(e,t){for(var n=t.viewport,r=!0;;r=!1){if(r&&e.options.lineWrapping&&t.oldDisplayWidth!=Gn(e))r&&(t.visible=ti(e.display,e.doc,n));else if(n&&null!=n.top&&(n={top:Math.min(e.doc.height+Vn(e.display)-Zn(e),n.top)}),t.visible=ti(e.display,e.doc,n),t.visible.from>=e.display.viewFrom&&t.visible.to<=e.display.viewTo)break;if(!zi(e,t))break;Qr(e);var i=gi(e);Wr(e),yi(e,i),Vi(e,i),t.force=!1}t.signal(e,"update",e),e.display.viewFrom==e.display.reportedViewFrom&&e.display.viewTo==e.display.reportedViewTo||(t.signal(e,"viewportChange",e,e.display.viewFrom,e.display.viewTo),e.display.reportedViewFrom=e.display.viewFrom,e.display.reportedViewTo=e.display.viewTo)}function Wi(e,t){var n=new qi(e,t);if(zi(e,n)){Qr(e),Bi(e,n);var r=gi(e);Wr(e),yi(e,r),Vi(e,r),n.finish()}}function Hi(e,t,n){var r=e.display,i=e.options.lineNumbers,o=r.lineDiv,a=o.firstChild;function s(t){var n=t.nextSibling;return l&&y&&e.display.currentWheelTarget==t?t.style.display="none":t.parentNode.removeChild(t),n}for(var u=r.view,c=r.viewFrom,f=0;f<u.length;f++){var p=u[f];if(p.hidden);else if(p.node&&p.node.parentNode==o){for(;a!=p.node;)a=s(a);var d=i&&null!=t&&t<=c&&p.lineNumber;p.changes&&(R(p.changes,"gutter")>-1&&(d=!1),Dn(e,p,c,n)),d&&(A(p.lineNumber),p.lineNumber.appendChild(document.createTextNode(it(e.options,c)))),a=p.node.nextSibling}else{var h=$n(e,p,c,n);o.insertBefore(h,a)}c+=p.size}for(;a;)a=s(a)}function Ui(e){var t=e.gutters.offsetWidth;e.sizer.style.marginLeft=t+"px"}function Vi(e,t){e.display.sizer.style.minHeight=t.docHeight+"px",e.display.heightForcer.style.top=t.docHeight+"px",e.display.gutters.style.height=t.docHeight+e.display.barHeight+Yn(e)+"px"}function Ki(e){var t=e.display,n=t.view;if(t.alignWidgets||t.gutters.firstChild&&e.options.fixedGutter){for(var r=Nr(t)-t.scroller.scrollLeft+e.doc.scrollLeft,i=t.gutters.offsetWidth,o=r+"px",a=0;a<n.length;a++)if(!n[a].hidden){e.options.fixedGutter&&(n[a].gutter&&(n[a].gutter.style.left=o),n[a].gutterBackground&&(n[a].gutterBackground.style.left=o));var s=n[a].alignable;if(s)for(var l=0;l<s.length;l++)s[l].style.left=o}e.options.fixedGutter&&(t.gutters.style.left=r+i+"px")}}function Yi(e){if(!e.options.lineNumbers)return!1;var t=e.doc,n=it(e.options,t.first+t.size-1),r=e.display;if(n.length!=r.lineNumChars){var i=r.measure.appendChild(j("div",[j("div",n)],"CodeMirror-linenumber CodeMirror-gutter-elt")),o=i.firstChild.offsetWidth,a=i.offsetWidth-o;return r.lineGutter.style.width="",r.lineNumInnerWidth=Math.max(o,r.lineGutter.offsetWidth-a)+1,r.lineNumWidth=r.lineNumInnerWidth+a,r.lineNumChars=r.lineNumInnerWidth?n.length:-1,r.lineGutter.style.width=r.lineNumWidth+"px",Ui(e.display),!0}return!1}function Gi(e,t){for(var n=[],r=!1,i=0;i<e.length;i++){var o=e[i],a=null;if("string"!=typeof o&&(a=o.style,o=o.className),"CodeMirror-linenumbers"==o){if(!t)continue;r=!0}n.push({className:o,style:a})}return t&&!r&&n.push({className:"CodeMirror-linenumbers",style:null}),n}function Zi(e){var t=e.gutters,n=e.gutterSpecs;A(t),e.lineGutter=null;for(var r=0;r<n.length;++r){var i=n[r],o=i.className,a=i.style,s=t.appendChild(j("div",null,"CodeMirror-gutter "+o));a&&(s.style.cssText=a),"CodeMirror-linenumbers"==o&&(e.lineGutter=s,s.style.width=(e.lineNumWidth||1)+"px")}t.style.display=n.length?"":"none",Ui(e)}function Xi(e){Zi(e.display),qr(e),Ki(e)}function Ji(e,t,r,i){var o=this;this.input=r,o.scrollbarFiller=j("div",null,"CodeMirror-scrollbar-filler"),o.scrollbarFiller.setAttribute("cm-not-content","true"),o.gutterFiller=j("div",null,"CodeMirror-gutter-filler"),o.gutterFiller.setAttribute("cm-not-content","true"),o.lineDiv=T("div",null,"CodeMirror-code"),o.selectionDiv=j("div",null,null,"position: relative; z-index: 1"),o.cursorDiv=j("div",null,"CodeMirror-cursors"),o.measure=j("div",null,"CodeMirror-measure"),o.lineMeasure=j("div",null,"CodeMirror-measure"),o.lineSpace=T("div",[o.measure,o.lineMeasure,o.selectionDiv,o.cursorDiv,o.lineDiv],null,"position: relative; outline: none");var u=T("div",[o.lineSpace],"CodeMirror-lines");o.mover=j("div",[u],null,"position: relative"),o.sizer=j("div",[o.mover],"CodeMirror-sizer"),o.sizerWidth=null,o.heightForcer=j("div",null,null,"position: absolute; height: "+z+"px; width: 1px;"),o.gutters=j("div",null,"CodeMirror-gutters"),o.lineGutter=null,o.scroller=j("div",[o.sizer,o.heightForcer,o.gutters],"CodeMirror-scroll"),o.scroller.setAttribute("tabIndex","-1"),o.wrapper=j("div",[o.scrollbarFiller,o.gutterFiller,o.scroller],"CodeMirror"),a&&s<8&&(o.gutters.style.zIndex=-1,o.scroller.style.paddingRight=0),l||n&&v||(o.scroller.draggable=!0),e&&(e.appendChild?e.appendChild(o.wrapper):e(o.wrapper)),o.viewFrom=o.viewTo=t.first,o.reportedViewFrom=o.reportedViewTo=t.first,o.view=[],o.renderedView=null,o.externalMeasured=null,o.viewOffset=0,o.lastWrapHeight=o.lastWrapWidth=0,o.updateLineNumbers=null,o.nativeBarWidth=o.barHeight=o.barWidth=0,o.scrollbarsClipped=!1,o.lineNumWidth=o.lineNumInnerWidth=o.lineNumChars=null,o.alignWidgets=!1,o.cachedCharWidth=o.cachedTextHeight=o.cachedPaddingH=null,o.maxLine=null,o.maxLineLength=0,o.maxLineChanged=!1,o.wheelDX=o.wheelDY=o.wheelStartX=o.wheelStartY=null,o.shift=!1,o.selForContextMenu=null,o.activeTouch=null,o.gutterSpecs=Gi(i.gutters,i.lineNumbers),Zi(o),r.init(o)}qi.prototype.signal=function(e,t){_e(e,t)&&this.events.push(arguments)},qi.prototype.finish=function(){for(var e=0;e<this.events.length;e++)ve.apply(null,this.events[e])};var Qi=0,eo=null;function to(e){var t=e.wheelDeltaX,n=e.wheelDeltaY;return null==t&&e.detail&&e.axis==e.HORIZONTAL_AXIS&&(t=e.detail),null==n&&e.detail&&e.axis==e.VERTICAL_AXIS?n=e.detail:null==n&&(n=e.wheelDelta),{x:t,y:n}}function no(e){var t=to(e);return t.x*=eo,t.y*=eo,t}function ro(e,t){var r=to(t),i=r.x,o=r.y,a=e.display,s=a.scroller,u=s.scrollWidth>s.clientWidth,c=s.scrollHeight>s.clientHeight;if(i&&u||o&&c){if(o&&y&&l)e:for(var p=t.target,d=a.view;p!=s;p=p.parentNode)for(var h=0;h<d.length;h++)if(d[h].node==p){e.display.currentWheelTarget=p;break e}if(i&&!n&&!f&&null!=eo)return o&&c&&pi(e,Math.max(0,s.scrollTop+o*eo)),hi(e,Math.max(0,s.scrollLeft+i*eo)),(!o||o&&c)&&xe(t),void(a.wheelStartX=null);if(o&&null!=eo){var g=o*eo,m=e.doc.scrollTop,v=m+a.wrapper.clientHeight;g<0?m=Math.max(0,m+g-50):v=Math.min(e.doc.height,v+g+50),Wi(e,{top:m,bottom:v})}Qi<20&&(null==a.wheelStartX?(a.wheelStartX=s.scrollLeft,a.wheelStartY=s.scrollTop,a.wheelDX=i,a.wheelDY=o,setTimeout((function(){if(null!=a.wheelStartX){var e=s.scrollLeft-a.wheelStartX,t=s.scrollTop-a.wheelStartY,n=t&&a.wheelDY&&t/a.wheelDY||e&&a.wheelDX&&e/a.wheelDX;a.wheelStartX=a.wheelStartY=null,n&&(eo=(eo*Qi+n)/(Qi+1),++Qi)}}),200)):(a.wheelDX+=i,a.wheelDY+=o))}}a?eo=-.53:n?eo=15:c?eo=-.7:p&&(eo=-1/3);var io=function(e,t){this.ranges=e,this.primIndex=t};io.prototype.primary=function(){return this.ranges[this.primIndex]},io.prototype.equals=function(e){if(e==this)return!0;if(e.primIndex!=this.primIndex||e.ranges.length!=this.ranges.length)return!1;for(var t=0;t<this.ranges.length;t++){var n=this.ranges[t],r=e.ranges[t];if(!st(n.anchor,r.anchor)||!st(n.head,r.head))return!1}return!0},io.prototype.deepCopy=function(){for(var e=[],t=0;t<this.ranges.length;t++)e[t]=new oo(lt(this.ranges[t].anchor),lt(this.ranges[t].head));return new io(e,this.primIndex)},io.prototype.somethingSelected=function(){for(var e=0;e<this.ranges.length;e++)if(!this.ranges[e].empty())return!0;return!1},io.prototype.contains=function(e,t){t||(t=e);for(var n=0;n<this.ranges.length;n++){var r=this.ranges[n];if(at(t,r.from())>=0&&at(e,r.to())<=0)return n}return-1};var oo=function(e,t){this.anchor=e,this.head=t};function ao(e,t,n){var r=e&&e.options.selectionsMayTouch,i=t[n];t.sort((function(e,t){return at(e.from(),t.from())})),n=R(t,i);for(var o=1;o<t.length;o++){var a=t[o],s=t[o-1],l=at(s.to(),a.from());if(r&&!a.empty()?l>0:l>=0){var u=ct(s.from(),a.from()),c=ut(s.to(),a.to()),f=s.empty()?a.from()==a.head:s.from()==s.head;o<=n&&--n,t.splice(--o,2,new oo(f?c:u,f?u:c))}}return new io(t,n)}function so(e,t){return new io([new oo(e,t||e)],0)}function lo(e){return e.text?ot(e.from.line+e.text.length-1,G(e.text).length+(1==e.text.length?e.from.ch:0)):e.to}function uo(e,t){if(at(e,t.from)<0)return e;if(at(e,t.to)<=0)return lo(t);var n=e.line+t.text.length-(t.to.line-t.from.line)-1,r=e.ch;return e.line==t.to.line&&(r+=lo(t).ch-t.to.ch),ot(n,r)}function co(e,t){for(var n=[],r=0;r<e.sel.ranges.length;r++){var i=e.sel.ranges[r];n.push(new oo(uo(i.anchor,t),uo(i.head,t)))}return ao(e.cm,n,e.sel.primIndex)}function fo(e,t,n){return e.line==t.line?ot(n.line,e.ch-t.ch+n.ch):ot(n.line+(e.line-t.line),e.ch)}function po(e,t,n){for(var r=[],i=ot(e.first,0),o=i,a=0;a<t.length;a++){var s=t[a],l=fo(s.from,i,o),u=fo(lo(s),i,o);if(i=s.to,o=u,"around"==n){var c=e.sel.ranges[a],f=at(c.head,c.anchor)<0;r[a]=new oo(f?u:l,f?l:u)}else r[a]=new oo(l,l)}return new io(r,e.sel.primIndex)}function ho(e){e.doc.mode=He(e.options,e.doc.modeOption),go(e)}function go(e){e.doc.iter((function(e){e.stateAfter&&(e.stateAfter=null),e.styles&&(e.styles=null)})),e.doc.modeFrontier=e.doc.highlightFrontier=e.doc.first,Pi(e,100),e.state.modeGen++,e.curOp&&qr(e)}function mo(e,t){return 0==t.from.ch&&0==t.to.ch&&""==G(t.text)&&(!e.cm||e.cm.options.wholeLineUpdateBefore)}function vo(e,t,n,r){function i(e){return n?n[e]:null}function o(e,n,i){cn(e,n,i,r),jn(e,"change",e,t)}function a(e,t){for(var n=[],o=e;o<t;++o)n.push(new un(u[o],i(o),r));return n}var s=t.from,l=t.to,u=t.text,c=Xe(e,s.line),f=Xe(e,l.line),p=G(u),d=i(u.length-1),h=l.line-s.line;if(t.full)e.insert(0,a(0,u.length)),e.remove(u.length,e.size-u.length);else if(mo(e,t)){var g=a(0,u.length-1);o(f,f.text,d),h&&e.remove(s.line,h),g.length&&e.insert(s.line,g)}else if(c==f)if(1==u.length)o(c,c.text.slice(0,s.ch)+p+c.text.slice(l.ch),d);else{var m=a(1,u.length-1);m.push(new un(p+c.text.slice(l.ch),d,r)),o(c,c.text.slice(0,s.ch)+u[0],i(0)),e.insert(s.line+1,m)}else if(1==u.length)o(c,c.text.slice(0,s.ch)+u[0]+f.text.slice(l.ch),i(0)),e.remove(s.line+1,h);else{o(c,c.text.slice(0,s.ch)+u[0],i(0)),o(f,p+f.text.slice(l.ch),d);var v=a(1,u.length-1);h>1&&e.remove(s.line+1,h-1),e.insert(s.line+1,v)}jn(e,"change",e,t)}function yo(e,t,n){function r(e,i,o){if(e.linked)for(var a=0;a<e.linked.length;++a){var s=e.linked[a];if(s.doc!=i){var l=o&&s.sharedHist;n&&!l||(t(s.doc,l),r(s.doc,e,l))}}}r(e,null,!0)}function bo(e,t){if(t.cm)throw new Error("This document is already in use.");e.doc=t,t.cm=e,Mr(e),ho(e),_o(e),e.options.lineWrapping||ln(e),e.options.mode=t.modeOption,qr(e)}function _o(e){("rtl"==e.doc.direction?L:O)(e.display.lineDiv,"CodeMirror-rtl")}function wo(e){Di(e,(function(){_o(e),qr(e)}))}function xo(e){this.done=[],this.undone=[],this.undoDepth=e?e.undoDepth:1/0,this.lastModTime=this.lastSelTime=0,this.lastOp=this.lastSelOp=null,this.lastOrigin=this.lastSelOrigin=null,this.generation=this.maxGeneration=e?e.maxGeneration:1}function ko(e,t){var n={from:lt(t.from),to:lo(t),text:Je(e,t.from,t.to)};return To(e,n,t.from.line,t.to.line+1),yo(e,(function(e){return To(e,n,t.from.line,t.to.line+1)}),!0),n}function Co(e){for(;e.length&&G(e).ranges;)e.pop()}function Eo(e,t){return t?(Co(e.done),G(e.done)):e.done.length&&!G(e.done).ranges?G(e.done):e.done.length>1&&!e.done[e.done.length-2].ranges?(e.done.pop(),G(e.done)):void 0}function Oo(e,t,n,r){var i=e.history;i.undone.length=0;var o,a,s=+new Date;if((i.lastOp==r||i.lastOrigin==t.origin&&t.origin&&("+"==t.origin.charAt(0)&&i.lastModTime>s-(e.cm?e.cm.options.historyEventDelay:500)||"*"==t.origin.charAt(0)))&&(o=Eo(i,i.lastOp==r)))a=G(o.changes),0==at(t.from,t.to)&&0==at(t.from,a.to)?a.to=lo(t):o.changes.push(ko(e,t));else{var l=G(i.done);for(l&&l.ranges||jo(e.sel,i.done),o={changes:[ko(e,t)],generation:i.generation},i.done.push(o);i.done.length>i.undoDepth;)i.done.shift(),i.done[0].ranges||i.done.shift()}i.done.push(n),i.generation=++i.maxGeneration,i.lastModTime=i.lastSelTime=s,i.lastOp=i.lastSelOp=r,i.lastOrigin=i.lastSelOrigin=t.origin,a||ve(e,"historyAdded")}function Ao(e,t,n,r){var i=t.charAt(0);return"*"==i||"+"==i&&n.ranges.length==r.ranges.length&&n.somethingSelected()==r.somethingSelected()&&new Date-e.history.lastSelTime<=(e.cm?e.cm.options.historyEventDelay:500)}function So(e,t,n,r){var i=e.history,o=r&&r.origin;n==i.lastSelOp||o&&i.lastSelOrigin==o&&(i.lastModTime==i.lastSelTime&&i.lastOrigin==o||Ao(e,o,G(i.done),t))?i.done[i.done.length-1]=t:jo(t,i.done),i.lastSelTime=+new Date,i.lastSelOrigin=o,i.lastSelOp=n,r&&!1!==r.clearRedo&&Co(i.undone)}function jo(e,t){var n=G(t);n&&n.ranges&&n.equals(e)||t.push(e)}function To(e,t,n,r){var i=t["spans_"+e.id],o=0;e.iter(Math.max(e.first,n),Math.min(e.first+e.size,r),(function(n){n.markedSpans&&((i||(i=t["spans_"+e.id]={}))[o]=n.markedSpans),++o}))}function Do(e){if(!e)return null;for(var t,n=0;n<e.length;++n)e[n].marker.explicitlyCleared?t||(t=e.slice(0,n)):t&&t.push(e[n]);return t?t.length?t:null:e}function No(e,t){var n=t["spans_"+e.id];if(!n)return null;for(var r=[],i=0;i<t.text.length;++i)r.push(Do(n[i]));return r}function Lo(e,t){var n=No(e,t),r=$t(e,t);if(!n)return r;if(!r)return n;for(var i=0;i<n.length;++i){var o=n[i],a=r[i];if(o&&a)e:for(var s=0;s<a.length;++s){for(var l=a[s],u=0;u<o.length;++u)if(o[u].marker==l.marker)continue e;o.push(l)}else a&&(n[i]=a)}return n}function Mo(e,t,n){for(var r=[],i=0;i<e.length;++i){var o=e[i];if(o.ranges)r.push(n?io.prototype.deepCopy.call(o):o);else{var a=o.changes,s=[];r.push({changes:s});for(var l=0;l<a.length;++l){var u=a[l],c=void 0;if(s.push({from:u.from,to:u.to,text:u.text}),t)for(var f in u)(c=f.match(/^spans_(\d+)$/))&&R(t,Number(c[1]))>-1&&(G(s)[f]=u[f],delete u[f])}}}return r}function Po(e,t,n,r){if(r){var i=e.anchor;if(n){var o=at(t,i)<0;o!=at(n,i)<0?(i=t,t=n):o!=at(t,n)<0&&(t=n)}return new oo(i,t)}return new oo(n||t,t)}function Fo(e,t,n,r,i){null==i&&(i=e.cm&&(e.cm.display.shift||e.extend)),Bo(e,new io([Po(e.sel.primary(),t,n,i)],0),r)}function qo(e,t,n){for(var r=[],i=e.cm&&(e.cm.display.shift||e.extend),o=0;o<e.sel.ranges.length;o++)r[o]=Po(e.sel.ranges[o],t[o],null,i);Bo(e,ao(e.cm,r,e.sel.primIndex),n)}function Io(e,t,n,r){var i=e.sel.ranges.slice(0);i[t]=n,Bo(e,ao(e.cm,i,e.sel.primIndex),r)}function $o(e,t,n,r){Bo(e,so(t,n),r)}function Ro(e,t,n){var r={ranges:t.ranges,update:function(t){this.ranges=[];for(var n=0;n<t.length;n++)this.ranges[n]=new oo(pt(e,t[n].anchor),pt(e,t[n].head))},origin:n&&n.origin};return ve(e,"beforeSelectionChange",e,r),e.cm&&ve(e.cm,"beforeSelectionChange",e.cm,r),r.ranges!=t.ranges?ao(e.cm,r.ranges,r.ranges.length-1):t}function zo(e,t,n){var r=e.history.done,i=G(r);i&&i.ranges?(r[r.length-1]=t,Wo(e,t,n)):Bo(e,t,n)}function Bo(e,t,n){Wo(e,t,n),So(e,e.sel,e.cm?e.cm.curOp.id:NaN,n)}function Wo(e,t,n){(_e(e,"beforeSelectionChange")||e.cm&&_e(e.cm,"beforeSelectionChange"))&&(t=Ro(e,t,n));var r=n&&n.bias||(at(t.primary().head,e.sel.primary().head)<0?-1:1);Ho(e,Vo(e,t,r,!0)),n&&!1===n.scroll||!e.cm||"nocursor"==e.cm.getOption("readOnly")||si(e.cm)}function Ho(e,t){t.equals(e.sel)||(e.sel=t,e.cm&&(e.cm.curOp.updateInput=1,e.cm.curOp.selectionChanged=!0,be(e.cm)),jn(e,"cursorActivity",e))}function Uo(e){Ho(e,Vo(e,e.sel,null,!1))}function Vo(e,t,n,r){for(var i,o=0;o<t.ranges.length;o++){var a=t.ranges[o],s=t.ranges.length==e.sel.ranges.length&&e.sel.ranges[o],l=Yo(e,a.anchor,s&&s.anchor,n,r),u=Yo(e,a.head,s&&s.head,n,r);(i||l!=a.anchor||u!=a.head)&&(i||(i=t.ranges.slice(0,o)),i[o]=new oo(l,u))}return i?ao(e.cm,i,t.primIndex):t}function Ko(e,t,n,r,i){var o=Xe(e,t.line);if(o.markedSpans)for(var a=0;a<o.markedSpans.length;++a){var s=o.markedSpans[a],l=s.marker,u="selectLeft"in l?!l.selectLeft:l.inclusiveLeft,c="selectRight"in l?!l.selectRight:l.inclusiveRight;if((null==s.from||(u?s.from<=t.ch:s.from<t.ch))&&(null==s.to||(c?s.to>=t.ch:s.to>t.ch))){if(i&&(ve(l,"beforeCursorEnter"),l.explicitlyCleared)){if(o.markedSpans){--a;continue}break}if(!l.atomic)continue;if(n){var f=l.find(r<0?1:-1),p=void 0;if((r<0?c:u)&&(f=Go(e,f,-r,f&&f.line==t.line?o:null)),f&&f.line==t.line&&(p=at(f,n))&&(r<0?p<0:p>0))return Ko(e,f,t,r,i)}var d=l.find(r<0?-1:1);return(r<0?u:c)&&(d=Go(e,d,r,d.line==t.line?o:null)),d?Ko(e,d,t,r,i):null}}return t}function Yo(e,t,n,r,i){var o=r||1,a=Ko(e,t,n,o,i)||!i&&Ko(e,t,n,o,!0)||Ko(e,t,n,-o,i)||!i&&Ko(e,t,n,-o,!0);return a||(e.cantEdit=!0,ot(e.first,0))}function Go(e,t,n,r){return n<0&&0==t.ch?t.line>e.first?pt(e,ot(t.line-1)):null:n>0&&t.ch==(r||Xe(e,t.line)).text.length?t.line<e.first+e.size-1?ot(t.line+1,0):null:new ot(t.line,t.ch+n)}function Zo(e){e.setSelection(ot(e.firstLine(),0),ot(e.lastLine()),W)}function Xo(e,t,n){var r={canceled:!1,from:t.from,to:t.to,text:t.text,origin:t.origin,cancel:function(){return r.canceled=!0}};return n&&(r.update=function(t,n,i,o){t&&(r.from=pt(e,t)),n&&(r.to=pt(e,n)),i&&(r.text=i),void 0!==o&&(r.origin=o)}),ve(e,"beforeChange",e,r),e.cm&&ve(e.cm,"beforeChange",e.cm,r),r.canceled?(e.cm&&(e.cm.curOp.updateInput=2),null):{from:r.from,to:r.to,text:r.text,origin:r.origin}}function Jo(e,t,n){if(e.cm){if(!e.cm.curOp)return Ni(e.cm,Jo)(e,t,n);if(e.cm.state.suppressEdits)return}if(!(_e(e,"beforeChange")||e.cm&&_e(e.cm,"beforeChange"))||(t=Xo(e,t,!0))){var r=jt&&!n&&zt(e,t.from,t.to);if(r)for(var i=r.length-1;i>=0;--i)Qo(e,{from:r[i].from,to:r[i].to,text:i?[""]:t.text,origin:t.origin});else Qo(e,t)}}function Qo(e,t){if(1!=t.text.length||""!=t.text[0]||0!=at(t.from,t.to)){var n=co(e,t);Oo(e,t,n,e.cm?e.cm.curOp.id:NaN),na(e,t,n,$t(e,t));var r=[];yo(e,(function(e,n){n||-1!=R(r,e.history)||(sa(e.history,t),r.push(e.history)),na(e,t,null,$t(e,t))}))}}function ea(e,t,n){var r=e.cm&&e.cm.state.suppressEdits;if(!r||n){for(var i,o=e.history,a=e.sel,s="undo"==t?o.done:o.undone,l="undo"==t?o.undone:o.done,u=0;u<s.length&&(i=s[u],n?!i.ranges||i.equals(e.sel):i.ranges);u++);if(u!=s.length){for(o.lastOrigin=o.lastSelOrigin=null;;){if(!(i=s.pop()).ranges){if(r)return void s.push(i);break}if(jo(i,l),n&&!i.equals(e.sel))return void Bo(e,i,{clearRedo:!1});a=i}var c=[];jo(a,l),l.push({changes:c,generation:o.generation}),o.generation=i.generation||++o.maxGeneration;for(var f=_e(e,"beforeChange")||e.cm&&_e(e.cm,"beforeChange"),p=function(n){var r=i.changes[n];if(r.origin=t,f&&!Xo(e,r,!1))return s.length=0,{};c.push(ko(e,r));var o=n?co(e,r):G(s);na(e,r,o,Lo(e,r)),!n&&e.cm&&e.cm.scrollIntoView({from:r.from,to:lo(r)});var a=[];yo(e,(function(e,t){t||-1!=R(a,e.history)||(sa(e.history,r),a.push(e.history)),na(e,r,null,Lo(e,r))}))},d=i.changes.length-1;d>=0;--d){var h=p(d);if(h)return h.v}}}}function ta(e,t){if(0!=t&&(e.first+=t,e.sel=new io(Z(e.sel.ranges,(function(e){return new oo(ot(e.anchor.line+t,e.anchor.ch),ot(e.head.line+t,e.head.ch))})),e.sel.primIndex),e.cm)){qr(e.cm,e.first,e.first-t,t);for(var n=e.cm.display,r=n.viewFrom;r<n.viewTo;r++)Ir(e.cm,r,"gutter")}}function na(e,t,n,r){if(e.cm&&!e.cm.curOp)return Ni(e.cm,na)(e,t,n,r);if(t.to.line<e.first)ta(e,t.text.length-1-(t.to.line-t.from.line));else if(!(t.from.line>e.lastLine())){if(t.from.line<e.first){var i=t.text.length-1-(e.first-t.from.line);ta(e,i),t={from:ot(e.first,0),to:ot(t.to.line+i,t.to.ch),text:[G(t.text)],origin:t.origin}}var o=e.lastLine();t.to.line>o&&(t={from:t.from,to:ot(o,Xe(e,o).text.length),text:[t.text[0]],origin:t.origin}),t.removed=Je(e,t.from,t.to),n||(n=co(e,t)),e.cm?ra(e.cm,t,r):vo(e,t,r),Wo(e,n,W),e.cantEdit&&Yo(e,ot(e.firstLine(),0))&&(e.cantEdit=!1)}}function ra(e,t,n){var r=e.doc,i=e.display,o=t.from,a=t.to,s=!1,l=o.line;e.options.lineWrapping||(l=tt(Jt(Xe(r,o.line))),r.iter(l,a.line+1,(function(e){if(e==i.maxLine)return s=!0,!0}))),r.sel.contains(t.from,t.to)>-1&&be(e),vo(r,t,n,Lr(e)),e.options.lineWrapping||(r.iter(l,o.line+t.text.length,(function(e){var t=sn(e);t>i.maxLineLength&&(i.maxLine=e,i.maxLineLength=t,i.maxLineChanged=!0,s=!1)})),s&&(e.curOp.updateMaxLine=!0)),St(r,o.line),Pi(e,400);var u=t.text.length-(a.line-o.line)-1;t.full?qr(e):o.line!=a.line||1!=t.text.length||mo(e.doc,t)?qr(e,o.line,a.line+1,u):Ir(e,o.line,"text");var c=_e(e,"changes"),f=_e(e,"change");if(f||c){var p={from:o,to:a,text:t.text,removed:t.removed,origin:t.origin};f&&jn(e,"change",e,p),c&&(e.curOp.changeObjs||(e.curOp.changeObjs=[])).push(p)}e.display.selForContextMenu=null}function ia(e,t,n,r,i){var o;r||(r=n),at(r,n)<0&&(n=(o=[r,n])[0],r=o[1]),"string"==typeof t&&(t=e.splitLines(t)),Jo(e,{from:n,to:r,text:t,origin:i})}function oa(e,t,n,r){n<e.line?e.line+=r:t<e.line&&(e.line=t,e.ch=0)}function aa(e,t,n,r){for(var i=0;i<e.length;++i){var o=e[i],a=!0;if(o.ranges){o.copied||((o=e[i]=o.deepCopy()).copied=!0);for(var s=0;s<o.ranges.length;s++)oa(o.ranges[s].anchor,t,n,r),oa(o.ranges[s].head,t,n,r)}else{for(var l=0;l<o.changes.length;++l){var u=o.changes[l];if(n<u.from.line)u.from=ot(u.from.line+r,u.from.ch),u.to=ot(u.to.line+r,u.to.ch);else if(t<=u.to.line){a=!1;break}}a||(e.splice(0,i+1),i=0)}}}function sa(e,t){var n=t.from.line,r=t.to.line,i=t.text.length-(r-n)-1;aa(e.done,n,r,i),aa(e.undone,n,r,i)}function la(e,t,n,r){var i=t,o=t;return"number"==typeof t?o=Xe(e,ft(e,t)):i=tt(t),null==i?null:(r(o,i)&&e.cm&&Ir(e.cm,i,n),o)}function ua(e){this.lines=e,this.parent=null;for(var t=0,n=0;n<e.length;++n)e[n].parent=this,t+=e[n].height;this.height=t}function ca(e){this.children=e;for(var t=0,n=0,r=0;r<e.length;++r){var i=e[r];t+=i.chunkSize(),n+=i.height,i.parent=this}this.size=t,this.height=n,this.parent=null}oo.prototype.from=function(){return ct(this.anchor,this.head)},oo.prototype.to=function(){return ut(this.anchor,this.head)},oo.prototype.empty=function(){return this.head.line==this.anchor.line&&this.head.ch==this.anchor.ch},ua.prototype={chunkSize:function(){return this.lines.length},removeInner:function(e,t){for(var n=e,r=e+t;n<r;++n){var i=this.lines[n];this.height-=i.height,fn(i),jn(i,"delete")}this.lines.splice(e,t)},collapse:function(e){e.push.apply(e,this.lines)},insertInner:function(e,t,n){this.height+=n,this.lines=this.lines.slice(0,e).concat(t).concat(this.lines.slice(e));for(var r=0;r<t.length;++r)t[r].parent=this},iterN:function(e,t,n){for(var r=e+t;e<r;++e)if(n(this.lines[e]))return!0}},ca.prototype={chunkSize:function(){return this.size},removeInner:function(e,t){this.size-=t;for(var n=0;n<this.children.length;++n){var r=this.children[n],i=r.chunkSize();if(e<i){var o=Math.min(t,i-e),a=r.height;if(r.removeInner(e,o),this.height-=a-r.height,i==o&&(this.children.splice(n--,1),r.parent=null),0==(t-=o))break;e=0}else e-=i}if(this.size-t<25&&(this.children.length>1||!(this.children[0]instanceof ua))){var s=[];this.collapse(s),this.children=[new ua(s)],this.children[0].parent=this}},collapse:function(e){for(var t=0;t<this.children.length;++t)this.children[t].collapse(e)},insertInner:function(e,t,n){this.size+=t.length,this.height+=n;for(var r=0;r<this.children.length;++r){var i=this.children[r],o=i.chunkSize();if(e<=o){if(i.insertInner(e,t,n),i.lines&&i.lines.length>50){for(var a=i.lines.length%25+25,s=a;s<i.lines.length;){var l=new ua(i.lines.slice(s,s+=25));i.height-=l.height,this.children.splice(++r,0,l),l.parent=this}i.lines=i.lines.slice(0,a),this.maybeSpill()}break}e-=o}},maybeSpill:function(){if(!(this.children.length<=10)){var e=this;do{var t=new ca(e.children.splice(e.children.length-5,5));if(e.parent){e.size-=t.size,e.height-=t.height;var n=R(e.parent.children,e);e.parent.children.splice(n+1,0,t)}else{var r=new ca(e.children);r.parent=e,e.children=[r,t],e=r}t.parent=e.parent}while(e.children.length>10);e.parent.maybeSpill()}},iterN:function(e,t,n){for(var r=0;r<this.children.length;++r){var i=this.children[r],o=i.chunkSize();if(e<o){var a=Math.min(t,o-e);if(i.iterN(e,a,n))return!0;if(0==(t-=a))break;e=0}else e-=o}}};var fa=function(e,t,n){if(n)for(var r in n)n.hasOwnProperty(r)&&(this[r]=n[r]);this.doc=e,this.node=t};function pa(e,t,n){an(t)<(e.curOp&&e.curOp.scrollTop||e.doc.scrollTop)&&ai(e,n)}function da(e,t,n,r){var i=new fa(e,n,r),o=e.cm;return o&&i.noHScroll&&(o.display.alignWidgets=!0),la(e,t,"widget",(function(t){var n=t.widgets||(t.widgets=[]);if(null==i.insertAt?n.push(i):n.splice(Math.min(n.length,Math.max(0,i.insertAt)),0,i),i.line=t,o&&!rn(e,t)){var r=an(t)<e.scrollTop;et(t,t.height+Wn(i)),r&&ai(o,i.height),o.curOp.forceUpdate=!0}return!0})),o&&jn(o,"lineWidgetAdded",o,i,"number"==typeof t?t:tt(t)),i}fa.prototype.clear=function(){var e=this.doc.cm,t=this.line.widgets,n=this.line,r=tt(n);if(null!=r&&t){for(var i=0;i<t.length;++i)t[i]==this&&t.splice(i--,1);t.length||(n.widgets=null);var o=Wn(this);et(n,Math.max(0,n.height-o)),e&&(Di(e,(function(){pa(e,n,-o),Ir(e,r,"widget")})),jn(e,"lineWidgetCleared",e,this,r))}},fa.prototype.changed=function(){var e=this,t=this.height,n=this.doc.cm,r=this.line;this.height=null;var i=Wn(this)-t;i&&(rn(this.doc,r)||et(r,r.height+i),n&&Di(n,(function(){n.curOp.forceUpdate=!0,pa(n,r,i),jn(n,"lineWidgetChanged",n,e,tt(r))})))},we(fa);var ha=0,ga=function(e,t){this.lines=[],this.type=t,this.doc=e,this.id=++ha};function ma(e,t,n,r,i){if(r&&r.shared)return ya(e,t,n,r,i);if(e.cm&&!e.cm.curOp)return Ni(e.cm,ma)(e,t,n,r,i);var o=new ga(e,i),a=at(t,n);if(r&&q(r,o,!1),a>0||0==a&&!1!==o.clearWhenEmpty)return o;if(o.replacedWith&&(o.collapsed=!0,o.widgetNode=T("span",[o.replacedWith],"CodeMirror-widget"),r.handleMouseEvents||o.widgetNode.setAttribute("cm-ignore-events","true"),r.insertLeft&&(o.widgetNode.insertLeft=!0)),o.collapsed){if(Xt(e,t.line,t,n,o)||t.line!=n.line&&Xt(e,n.line,t,n,o))throw new Error("Inserting collapsed marker partially overlapping an existing one");Nt()}o.addToHistory&&Oo(e,{from:t,to:n,origin:"markText"},e.sel,NaN);var s,l=t.line,u=e.cm;if(e.iter(l,n.line+1,(function(e){u&&o.collapsed&&!u.options.lineWrapping&&Jt(e)==u.display.maxLine&&(s=!0),o.collapsed&&l!=t.line&&et(e,0),Ft(e,new Lt(o,l==t.line?t.ch:null,l==n.line?n.ch:null)),++l})),o.collapsed&&e.iter(t.line,n.line+1,(function(t){rn(e,t)&&et(t,0)})),o.clearOnEnter&&he(o,"beforeCursorEnter",(function(){return o.clear()})),o.readOnly&&(Dt(),(e.history.done.length||e.history.undone.length)&&e.clearHistory()),o.collapsed&&(o.id=++ha,o.atomic=!0),u){if(s&&(u.curOp.updateMaxLine=!0),o.collapsed)qr(u,t.line,n.line+1);else if(o.className||o.startStyle||o.endStyle||o.css||o.attributes||o.title)for(var c=t.line;c<=n.line;c++)Ir(u,c,"text");o.atomic&&Uo(u.doc),jn(u,"markerAdded",u,o)}return o}ga.prototype.clear=function(){if(!this.explicitlyCleared){var e=this.doc.cm,t=e&&!e.curOp;if(t&&ki(e),_e(this,"clear")){var n=this.find();n&&jn(this,"clear",n.from,n.to)}for(var r=null,i=null,o=0;o<this.lines.length;++o){var a=this.lines[o],s=Mt(a.markedSpans,this);e&&!this.collapsed?Ir(e,tt(a),"text"):e&&(null!=s.to&&(i=tt(a)),null!=s.from&&(r=tt(a))),a.markedSpans=Pt(a.markedSpans,s),null==s.from&&this.collapsed&&!rn(this.doc,a)&&e&&et(a,jr(e.display))}if(e&&this.collapsed&&!e.options.lineWrapping)for(var l=0;l<this.lines.length;++l){var u=Jt(this.lines[l]),c=sn(u);c>e.display.maxLineLength&&(e.display.maxLine=u,e.display.maxLineLength=c,e.display.maxLineChanged=!0)}null!=r&&e&&this.collapsed&&qr(e,r,i+1),this.lines.length=0,this.explicitlyCleared=!0,this.atomic&&this.doc.cantEdit&&(this.doc.cantEdit=!1,e&&Uo(e.doc)),e&&jn(e,"markerCleared",e,this,r,i),t&&Ci(e),this.parent&&this.parent.clear()}},ga.prototype.find=function(e,t){var n,r;null==e&&"bookmark"==this.type&&(e=1);for(var i=0;i<this.lines.length;++i){var o=this.lines[i],a=Mt(o.markedSpans,this);if(null!=a.from&&(n=ot(t?o:tt(o),a.from),-1==e))return n;if(null!=a.to&&(r=ot(t?o:tt(o),a.to),1==e))return r}return n&&{from:n,to:r}},ga.prototype.changed=function(){var e=this,t=this.find(-1,!0),n=this,r=this.doc.cm;t&&r&&Di(r,(function(){var i=t.line,o=tt(t.line),a=tr(r,o);if(a&&(cr(a),r.curOp.selectionChanged=r.curOp.forceUpdate=!0),r.curOp.updateMaxLine=!0,!rn(n.doc,i)&&null!=n.height){var s=n.height;n.height=null;var l=Wn(n)-s;l&&et(i,i.height+l)}jn(r,"markerChanged",r,e)}))},ga.prototype.attachLine=function(e){if(!this.lines.length&&this.doc.cm){var t=this.doc.cm.curOp;t.maybeHiddenMarkers&&-1!=R(t.maybeHiddenMarkers,this)||(t.maybeUnhiddenMarkers||(t.maybeUnhiddenMarkers=[])).push(this)}this.lines.push(e)},ga.prototype.detachLine=function(e){if(this.lines.splice(R(this.lines,e),1),!this.lines.length&&this.doc.cm){var t=this.doc.cm.curOp;(t.maybeHiddenMarkers||(t.maybeHiddenMarkers=[])).push(this)}},we(ga);var va=function(e,t){this.markers=e,this.primary=t;for(var n=0;n<e.length;++n)e[n].parent=this};function ya(e,t,n,r,i){(r=q(r)).shared=!1;var o=[ma(e,t,n,r,i)],a=o[0],s=r.widgetNode;return yo(e,(function(e){s&&(r.widgetNode=s.cloneNode(!0)),o.push(ma(e,pt(e,t),pt(e,n),r,i));for(var l=0;l<e.linked.length;++l)if(e.linked[l].isParent)return;a=G(o)})),new va(o,a)}function ba(e){return e.findMarks(ot(e.first,0),e.clipPos(ot(e.lastLine())),(function(e){return e.parent}))}function _a(e,t){for(var n=0;n<t.length;n++){var r=t[n],i=r.find(),o=e.clipPos(i.from),a=e.clipPos(i.to);if(at(o,a)){var s=ma(e,o,a,r.primary,r.primary.type);r.markers.push(s),s.parent=r}}}function wa(e){for(var t=function(t){var n=e[t],r=[n.primary.doc];yo(n.primary.doc,(function(e){return r.push(e)}));for(var i=0;i<n.markers.length;i++){var o=n.markers[i];-1==R(r,o.doc)&&(o.parent=null,n.markers.splice(i--,1))}},n=0;n<e.length;n++)t(n)}va.prototype.clear=function(){if(!this.explicitlyCleared){this.explicitlyCleared=!0;for(var e=0;e<this.markers.length;++e)this.markers[e].clear();jn(this,"clear")}},va.prototype.find=function(e,t){return this.primary.find(e,t)},we(va);var xa=0,ka=function(e,t,n,r,i){if(!(this instanceof ka))return new ka(e,t,n,r,i);null==n&&(n=0),ca.call(this,[new ua([new un("",null)])]),this.first=n,this.scrollTop=this.scrollLeft=0,this.cantEdit=!1,this.cleanGeneration=1,this.modeFrontier=this.highlightFrontier=n;var o=ot(n,0);this.sel=so(o),this.history=new xo(null),this.id=++xa,this.modeOption=t,this.lineSep=r,this.direction="rtl"==i?"rtl":"ltr",this.extend=!1,"string"==typeof e&&(e=this.splitLines(e)),vo(this,{from:o,to:o,text:e}),Bo(this,so(o),W)};ka.prototype=Q(ca.prototype,{constructor:ka,iter:function(e,t,n){n?this.iterN(e-this.first,t-e,n):this.iterN(this.first,this.first+this.size,e)},insert:function(e,t){for(var n=0,r=0;r<t.length;++r)n+=t[r].height;this.insertInner(e-this.first,t,n)},remove:function(e,t){this.removeInner(e-this.first,t)},getValue:function(e){var t=Qe(this,this.first,this.first+this.size);return!1===e?t:t.join(e||this.lineSeparator())},setValue:Mi((function(e){var t=ot(this.first,0),n=this.first+this.size-1;Jo(this,{from:t,to:ot(n,Xe(this,n).text.length),text:this.splitLines(e),origin:"setValue",full:!0},!0),this.cm&&li(this.cm,0,0),Bo(this,so(t),W)})),replaceRange:function(e,t,n,r){ia(this,e,t=pt(this,t),n=n?pt(this,n):t,r)},getRange:function(e,t,n){var r=Je(this,pt(this,e),pt(this,t));return!1===n?r:r.join(n||this.lineSeparator())},getLine:function(e){var t=this.getLineHandle(e);return t&&t.text},getLineHandle:function(e){if(rt(this,e))return Xe(this,e)},getLineNumber:function(e){return tt(e)},getLineHandleVisualStart:function(e){return"number"==typeof e&&(e=Xe(this,e)),Jt(e)},lineCount:function(){return this.size},firstLine:function(){return this.first},lastLine:function(){return this.first+this.size-1},clipPos:function(e){return pt(this,e)},getCursor:function(e){var t=this.sel.primary();return null==e||"head"==e?t.head:"anchor"==e?t.anchor:"end"==e||"to"==e||!1===e?t.to():t.from()},listSelections:function(){return this.sel.ranges},somethingSelected:function(){return this.sel.somethingSelected()},setCursor:Mi((function(e,t,n){$o(this,pt(this,"number"==typeof e?ot(e,t||0):e),null,n)})),setSelection:Mi((function(e,t,n){$o(this,pt(this,e),pt(this,t||e),n)})),extendSelection:Mi((function(e,t,n){Fo(this,pt(this,e),t&&pt(this,t),n)})),extendSelections:Mi((function(e,t){qo(this,ht(this,e),t)})),extendSelectionsBy:Mi((function(e,t){qo(this,ht(this,Z(this.sel.ranges,e)),t)})),setSelections:Mi((function(e,t,n){if(e.length){for(var r=[],i=0;i<e.length;i++)r[i]=new oo(pt(this,e[i].anchor),pt(this,e[i].head||e[i].anchor));null==t&&(t=Math.min(e.length-1,this.sel.primIndex)),Bo(this,ao(this.cm,r,t),n)}})),addSelection:Mi((function(e,t,n){var r=this.sel.ranges.slice(0);r.push(new oo(pt(this,e),pt(this,t||e))),Bo(this,ao(this.cm,r,r.length-1),n)})),getSelection:function(e){for(var t,n=this.sel.ranges,r=0;r<n.length;r++){var i=Je(this,n[r].from(),n[r].to());t=t?t.concat(i):i}return!1===e?t:t.join(e||this.lineSeparator())},getSelections:function(e){for(var t=[],n=this.sel.ranges,r=0;r<n.length;r++){var i=Je(this,n[r].from(),n[r].to());!1!==e&&(i=i.join(e||this.lineSeparator())),t[r]=i}return t},replaceSelection:function(e,t,n){for(var r=[],i=0;i<this.sel.ranges.length;i++)r[i]=e;this.replaceSelections(r,t,n||"+input")},replaceSelections:Mi((function(e,t,n){for(var r=[],i=this.sel,o=0;o<i.ranges.length;o++){var a=i.ranges[o];r[o]={from:a.from(),to:a.to(),text:this.splitLines(e[o]),origin:n}}for(var s=t&&"end"!=t&&po(this,r,t),l=r.length-1;l>=0;l--)Jo(this,r[l]);s?zo(this,s):this.cm&&si(this.cm)})),undo:Mi((function(){ea(this,"undo")})),redo:Mi((function(){ea(this,"redo")})),undoSelection:Mi((function(){ea(this,"undo",!0)})),redoSelection:Mi((function(){ea(this,"redo",!0)})),setExtending:function(e){this.extend=e},getExtending:function(){return this.extend},historySize:function(){for(var e=this.history,t=0,n=0,r=0;r<e.done.length;r++)e.done[r].ranges||++t;for(var i=0;i<e.undone.length;i++)e.undone[i].ranges||++n;return{undo:t,redo:n}},clearHistory:function(){var e=this;this.history=new xo(this.history),yo(this,(function(t){return t.history=e.history}),!0)},markClean:function(){this.cleanGeneration=this.changeGeneration(!0)},changeGeneration:function(e){return e&&(this.history.lastOp=this.history.lastSelOp=this.history.lastOrigin=null),this.history.generation},isClean:function(e){return this.history.generation==(e||this.cleanGeneration)},getHistory:function(){return{done:Mo(this.history.done),undone:Mo(this.history.undone)}},setHistory:function(e){var t=this.history=new xo(this.history);t.done=Mo(e.done.slice(0),null,!0),t.undone=Mo(e.undone.slice(0),null,!0)},setGutterMarker:Mi((function(e,t,n){return la(this,e,"gutter",(function(e){var r=e.gutterMarkers||(e.gutterMarkers={});return r[t]=n,!n&&re(r)&&(e.gutterMarkers=null),!0}))})),clearGutter:Mi((function(e){var t=this;this.iter((function(n){n.gutterMarkers&&n.gutterMarkers[e]&&la(t,n,"gutter",(function(){return n.gutterMarkers[e]=null,re(n.gutterMarkers)&&(n.gutterMarkers=null),!0}))}))})),lineInfo:function(e){var t;if("number"==typeof e){if(!rt(this,e))return null;if(t=e,!(e=Xe(this,e)))return null}else if(null==(t=tt(e)))return null;return{line:t,handle:e,text:e.text,gutterMarkers:e.gutterMarkers,textClass:e.textClass,bgClass:e.bgClass,wrapClass:e.wrapClass,widgets:e.widgets}},addLineClass:Mi((function(e,t,n){return la(this,e,"gutter"==t?"gutter":"class",(function(e){var r="text"==t?"textClass":"background"==t?"bgClass":"gutter"==t?"gutterClass":"wrapClass";if(e[r]){if(C(n).test(e[r]))return!1;e[r]+=" "+n}else e[r]=n;return!0}))})),removeLineClass:Mi((function(e,t,n){return la(this,e,"gutter"==t?"gutter":"class",(function(e){var r="text"==t?"textClass":"background"==t?"bgClass":"gutter"==t?"gutterClass":"wrapClass",i=e[r];if(!i)return!1;if(null==n)e[r]=null;else{var o=i.match(C(n));if(!o)return!1;var a=o.index+o[0].length;e[r]=i.slice(0,o.index)+(o.index&&a!=i.length?" ":"")+i.slice(a)||null}return!0}))})),addLineWidget:Mi((function(e,t,n){return da(this,e,t,n)})),removeLineWidget:function(e){e.clear()},markText:function(e,t,n){return ma(this,pt(this,e),pt(this,t),n,n&&n.type||"range")},setBookmark:function(e,t){var n={replacedWith:t&&(null==t.nodeType?t.widget:t),insertLeft:t&&t.insertLeft,clearWhenEmpty:!1,shared:t&&t.shared,handleMouseEvents:t&&t.handleMouseEvents};return ma(this,e=pt(this,e),e,n,"bookmark")},findMarksAt:function(e){var t=[],n=Xe(this,(e=pt(this,e)).line).markedSpans;if(n)for(var r=0;r<n.length;++r){var i=n[r];(null==i.from||i.from<=e.ch)&&(null==i.to||i.to>=e.ch)&&t.push(i.marker.parent||i.marker)}return t},findMarks:function(e,t,n){e=pt(this,e),t=pt(this,t);var r=[],i=e.line;return this.iter(e.line,t.line+1,(function(o){var a=o.markedSpans;if(a)for(var s=0;s<a.length;s++){var l=a[s];null!=l.to&&i==e.line&&e.ch>=l.to||null==l.from&&i!=e.line||null!=l.from&&i==t.line&&l.from>=t.ch||n&&!n(l.marker)||r.push(l.marker.parent||l.marker)}++i})),r},getAllMarks:function(){var e=[];return this.iter((function(t){var n=t.markedSpans;if(n)for(var r=0;r<n.length;++r)null!=n[r].from&&e.push(n[r].marker)})),e},posFromIndex:function(e){var t,n=this.first,r=this.lineSeparator().length;return this.iter((function(i){var o=i.text.length+r;if(o>e)return t=e,!0;e-=o,++n})),pt(this,ot(n,t))},indexFromPos:function(e){var t=(e=pt(this,e)).ch;if(e.line<this.first||e.ch<0)return 0;var n=this.lineSeparator().length;return this.iter(this.first,e.line,(function(e){t+=e.text.length+n})),t},copy:function(e){var t=new ka(Qe(this,this.first,this.first+this.size),this.modeOption,this.first,this.lineSep,this.direction);return t.scrollTop=this.scrollTop,t.scrollLeft=this.scrollLeft,t.sel=this.sel,t.extend=!1,e&&(t.history.undoDepth=this.history.undoDepth,t.setHistory(this.getHistory())),t},linkedDoc:function(e){e||(e={});var t=this.first,n=this.first+this.size;null!=e.from&&e.from>t&&(t=e.from),null!=e.to&&e.to<n&&(n=e.to);var r=new ka(Qe(this,t,n),e.mode||this.modeOption,t,this.lineSep,this.direction);return e.sharedHist&&(r.history=this.history),(this.linked||(this.linked=[])).push({doc:r,sharedHist:e.sharedHist}),r.linked=[{doc:this,isParent:!0,sharedHist:e.sharedHist}],_a(r,ba(this)),r},unlinkDoc:function(e){if(e instanceof qs&&(e=e.doc),this.linked)for(var t=0;t<this.linked.length;++t)if(this.linked[t].doc==e){this.linked.splice(t,1),e.unlinkDoc(this),wa(ba(this));break}if(e.history==this.history){var n=[e.id];yo(e,(function(e){return n.push(e.id)}),!0),e.history=new xo(null),e.history.done=Mo(this.history.done,n),e.history.undone=Mo(this.history.undone,n)}},iterLinkedDocs:function(e){yo(this,e)},getMode:function(){return this.mode},getEditor:function(){return this.cm},splitLines:function(e){return this.lineSep?e.split(this.lineSep):Me(e)},lineSeparator:function(){return this.lineSep||"\n"},setDirection:Mi((function(e){"rtl"!=e&&(e="ltr"),e!=this.direction&&(this.direction=e,this.iter((function(e){return e.order=null})),this.cm&&wo(this.cm))}))}),ka.prototype.eachLine=ka.prototype.iter;var Ca=0;function Ea(e){var t=this;if(Sa(t),!ye(t,e)&&!Hn(t.display,e)){xe(e),a&&(Ca=+new Date);var n=Pr(t,e,!0),r=e.dataTransfer.files;if(n&&!t.isReadOnly())if(r&&r.length&&window.FileReader&&window.File)for(var i=r.length,o=Array(i),s=0,l=function(){++s==i&&Ni(t,(function(){var e={from:n=pt(t.doc,n),to:n,text:t.doc.splitLines(o.filter((function(e){return null!=e})).join(t.doc.lineSeparator())),origin:"paste"};Jo(t.doc,e),zo(t.doc,so(pt(t.doc,n),pt(t.doc,lo(e))))}))()},u=function(e,n){if(t.options.allowDropFileTypes&&-1==R(t.options.allowDropFileTypes,e.type))l();else{var r=new FileReader;r.onerror=function(){return l()},r.onload=function(){var e=r.result;/[\x00-\x08\x0e-\x1f]{2}/.test(e)||(o[n]=e),l()},r.readAsText(e)}},c=0;c<r.length;c++)u(r[c],c);else{if(t.state.draggingText&&t.doc.sel.contains(n)>-1)return t.state.draggingText(e),void setTimeout((function(){return t.display.input.focus()}),20);try{var f=e.dataTransfer.getData("Text");if(f){var p;if(t.state.draggingText&&!t.state.draggingText.copy&&(p=t.listSelections()),Wo(t.doc,so(n,n)),p)for(var d=0;d<p.length;++d)ia(t.doc,"",p[d].anchor,p[d].head,"drag");t.replaceSelection(f,"around","paste"),t.display.input.focus()}}catch(h){}}}}function Oa(e,t){if(a&&(!e.state.draggingText||+new Date-Ca<100))Ee(t);else if(!ye(e,t)&&!Hn(e.display,t)&&(t.dataTransfer.setData("Text",e.getSelection()),t.dataTransfer.effectAllowed="copyMove",t.dataTransfer.setDragImage&&!p)){var n=j("img",null,null,"position: fixed; left: 0; top: 0;");n.src="data:image/gif;base64,R0lGODlhAQABAAAAACH5BAEKAAEALAAAAAABAAEAAAICTAEAOw==",f&&(n.width=n.height=1,e.display.wrapper.appendChild(n),n._top=n.offsetTop),t.dataTransfer.setDragImage(n,0,0),f&&n.parentNode.removeChild(n)}}function Aa(e,t){var n=Pr(e,t);if(n){var r=document.createDocumentFragment();Ur(e,n,r),e.display.dragCursor||(e.display.dragCursor=j("div",null,"CodeMirror-cursors CodeMirror-dragcursors"),e.display.lineSpace.insertBefore(e.display.dragCursor,e.display.cursorDiv)),S(e.display.dragCursor,r)}}function Sa(e){e.display.dragCursor&&(e.display.lineSpace.removeChild(e.display.dragCursor),e.display.dragCursor=null)}function ja(e){if(document.getElementsByClassName){for(var t=document.getElementsByClassName("CodeMirror"),n=[],r=0;r<t.length;r++){var i=t[r].CodeMirror;i&&n.push(i)}n.length&&n[0].operation((function(){for(var t=0;t<n.length;t++)e(n[t])}))}}var Ta=!1;function Da(){Ta||(Na(),Ta=!0)}function Na(){var e;he(window,"resize",(function(){null==e&&(e=setTimeout((function(){e=null,ja(La)}),100))})),he(window,"blur",(function(){return ja(Jr)}))}function La(e){var t=e.display;t.cachedCharWidth=t.cachedTextHeight=t.cachedPaddingH=null,t.scrollbarsClipped=!1,e.setSize()}for(var Ma={3:"Pause",8:"Backspace",9:"Tab",13:"Enter",16:"Shift",17:"Ctrl",18:"Alt",19:"Pause",20:"CapsLock",27:"Esc",32:"Space",33:"PageUp",34:"PageDown",35:"End",36:"Home",37:"Left",38:"Up",39:"Right",40:"Down",44:"PrintScrn",45:"Insert",46:"Delete",59:";",61:"=",91:"Mod",92:"Mod",93:"Mod",106:"*",107:"=",109:"-",110:".",111:"/",145:"ScrollLock",173:"-",186:";",187:"=",188:",",189:"-",190:".",191:"/",192:"`",219:"[",220:"\\",221:"]",222:"'",224:"Mod",63232:"Up",63233:"Down",63234:"Left",63235:"Right",63272:"Delete",63273:"Home",63275:"End",63276:"PageUp",63277:"PageDown",63302:"Insert"},Pa=0;Pa<10;Pa++)Ma[Pa+48]=Ma[Pa+96]=String(Pa);for(var Fa=65;Fa<=90;Fa++)Ma[Fa]=String.fromCharCode(Fa);for(var qa=1;qa<=12;qa++)Ma[qa+111]=Ma[qa+63235]="F"+qa;var Ia={};function $a(e){var t,n,r,i,o=e.split(/-(?!$)/);e=o[o.length-1];for(var a=0;a<o.length-1;a++){var s=o[a];if(/^(cmd|meta|m)$/i.test(s))i=!0;else if(/^a(lt)?$/i.test(s))t=!0;else if(/^(c|ctrl|control)$/i.test(s))n=!0;else{if(!/^s(hift)?$/i.test(s))throw new Error("Unrecognized modifier name: "+s);r=!0}}return t&&(e="Alt-"+e),n&&(e="Ctrl-"+e),i&&(e="Cmd-"+e),r&&(e="Shift-"+e),e}function Ra(e){var t={};for(var n in e)if(e.hasOwnProperty(n)){var r=e[n];if(/^(name|fallthrough|(de|at)tach)$/.test(n))continue;if("..."==r){delete e[n];continue}for(var i=Z(n.split(" "),$a),o=0;o<i.length;o++){var a=void 0,s=void 0;o==i.length-1?(s=i.join(" "),a=r):(s=i.slice(0,o+1).join(" "),a="...");var l=t[s];if(l){if(l!=a)throw new Error("Inconsistent bindings for "+s)}else t[s]=a}delete e[n]}for(var u in t)e[u]=t[u];return e}function za(e,t,n,r){var i=(t=Ua(t)).call?t.call(e,r):t[e];if(!1===i)return"nothing";if("..."===i)return"multi";if(null!=i&&n(i))return"handled";if(t.fallthrough){if("[object Array]"!=Object.prototype.toString.call(t.fallthrough))return za(e,t.fallthrough,n,r);for(var o=0;o<t.fallthrough.length;o++){var a=za(e,t.fallthrough[o],n,r);if(a)return a}}}function Ba(e){var t="string"==typeof e?e:Ma[e.keyCode];return"Ctrl"==t||"Alt"==t||"Shift"==t||"Mod"==t}function Wa(e,t,n){var r=e;return t.altKey&&"Alt"!=r&&(e="Alt-"+e),(x?t.metaKey:t.ctrlKey)&&"Ctrl"!=r&&(e="Ctrl-"+e),(x?t.ctrlKey:t.metaKey)&&"Mod"!=r&&(e="Cmd-"+e),!n&&t.shiftKey&&"Shift"!=r&&(e="Shift-"+e),e}function Ha(e,t){if(f&&34==e.keyCode&&e.char)return!1;var n=Ma[e.keyCode];return null!=n&&!e.altGraphKey&&(3==e.keyCode&&e.code&&(n=e.code),Wa(n,e,t))}function Ua(e){return"string"==typeof e?Ia[e]:e}function Va(e,t){for(var n=e.doc.sel.ranges,r=[],i=0;i<n.length;i++){for(var o=t(n[i]);r.length&&at(o.from,G(r).to)<=0;){var a=r.pop();if(at(a.from,o.from)<0){o.from=a.from;break}}r.push(o)}Di(e,(function(){for(var t=r.length-1;t>=0;t--)ia(e.doc,"",r[t].from,r[t].to,"+delete");si(e)}))}function Ka(e,t,n){var r=ae(e.text,t+n,n);return r<0||r>e.text.length?null:r}function Ya(e,t,n){var r=Ka(e,t.ch,n);return null==r?null:new ot(t.line,r,n<0?"after":"before")}function Ga(e,t,n,r,i){if(e){"rtl"==t.doc.direction&&(i=-i);var o=pe(n,t.doc.direction);if(o){var a,s=i<0?G(o):o[0],l=i<0==(1==s.level)?"after":"before";if(s.level>0||"rtl"==t.doc.direction){var u=nr(t,n);a=i<0?n.text.length-1:0;var c=rr(t,u,a).top;a=se((function(e){return rr(t,u,e).top==c}),i<0==(1==s.level)?s.from:s.to-1,a),"before"==l&&(a=Ka(n,a,1))}else a=i<0?s.to:s.from;return new ot(r,a,l)}}return new ot(r,i<0?n.text.length:0,i<0?"before":"after")}function Za(e,t,n,r){var i=pe(t,e.doc.direction);if(!i)return Ya(t,n,r);n.ch>=t.text.length?(n.ch=t.text.length,n.sticky="before"):n.ch<=0&&(n.ch=0,n.sticky="after");var o=ce(i,n.ch,n.sticky),a=i[o];if("ltr"==e.doc.direction&&a.level%2==0&&(r>0?a.to>n.ch:a.from<n.ch))return Ya(t,n,r);var s,l=function(e,n){return Ka(t,e instanceof ot?e.ch:e,n)},u=function(n){return e.options.lineWrapping?(s=s||nr(e,t),Cr(e,t,s,n)):{begin:0,end:t.text.length}},c=u("before"==n.sticky?l(n,-1):n.ch);if("rtl"==e.doc.direction||1==a.level){var f=1==a.level==r<0,p=l(n,f?1:-1);if(null!=p&&(f?p<=a.to&&p<=c.end:p>=a.from&&p>=c.begin)){var d=f?"before":"after";return new ot(n.line,p,d)}}var h=function(e,t,r){for(var o=function(e,t){return t?new ot(n.line,l(e,1),"before"):new ot(n.line,e,"after")};e>=0&&e<i.length;e+=t){var a=i[e],s=t>0==(1!=a.level),u=s?r.begin:l(r.end,-1);if(a.from<=u&&u<a.to)return o(u,s);if(u=s?a.from:l(a.to,-1),r.begin<=u&&u<r.end)return o(u,s)}},g=h(o+r,r,c);if(g)return g;var m=r>0?c.end:l(c.begin,-1);return null==m||r>0&&m==t.text.length||!(g=h(r>0?0:i.length-1,r,u(m)))?null:g}Ia.basic={Left:"goCharLeft",Right:"goCharRight",Up:"goLineUp",Down:"goLineDown",End:"goLineEnd",Home:"goLineStartSmart",PageUp:"goPageUp",PageDown:"goPageDown",Delete:"delCharAfter",Backspace:"delCharBefore","Shift-Backspace":"delCharBefore",Tab:"defaultTab","Shift-Tab":"indentAuto",Enter:"newlineAndIndent",Insert:"toggleOverwrite",Esc:"singleSelection"},Ia.pcDefault={"Ctrl-A":"selectAll","Ctrl-D":"deleteLine","Ctrl-Z":"undo","Shift-Ctrl-Z":"redo","Ctrl-Y":"redo","Ctrl-Home":"goDocStart","Ctrl-End":"goDocEnd","Ctrl-Up":"goLineUp","Ctrl-Down":"goLineDown","Ctrl-Left":"goGroupLeft","Ctrl-Right":"goGroupRight","Alt-Left":"goLineStart","Alt-Right":"goLineEnd","Ctrl-Backspace":"delGroupBefore","Ctrl-Delete":"delGroupAfter","Ctrl-S":"save","Ctrl-F":"find","Ctrl-G":"findNext","Shift-Ctrl-G":"findPrev","Shift-Ctrl-F":"replace","Shift-Ctrl-R":"replaceAll","Ctrl-[":"indentLess","Ctrl-]":"indentMore","Ctrl-U":"undoSelection","Shift-Ctrl-U":"redoSelection","Alt-U":"redoSelection",fallthrough:"basic"},Ia.emacsy={"Ctrl-F":"goCharRight","Ctrl-B":"goCharLeft","Ctrl-P":"goLineUp","Ctrl-N":"goLineDown","Alt-F":"goWordRight","Alt-B":"goWordLeft","Ctrl-A":"goLineStart","Ctrl-E":"goLineEnd","Ctrl-V":"goPageDown","Shift-Ctrl-V":"goPageUp","Ctrl-D":"delCharAfter","Ctrl-H":"delCharBefore","Alt-D":"delWordAfter","Alt-Backspace":"delWordBefore","Ctrl-K":"killLine","Ctrl-T":"transposeChars","Ctrl-O":"openLine"},Ia.macDefault={"Cmd-A":"selectAll","Cmd-D":"deleteLine","Cmd-Z":"undo","Shift-Cmd-Z":"redo","Cmd-Y":"redo","Cmd-Home":"goDocStart","Cmd-Up":"goDocStart","Cmd-End":"goDocEnd","Cmd-Down":"goDocEnd","Alt-Left":"goGroupLeft","Alt-Right":"goGroupRight","Cmd-Left":"goLineLeft","Cmd-Right":"goLineRight","Alt-Backspace":"delGroupBefore","Ctrl-Alt-Backspace":"delGroupAfter","Alt-Delete":"delGroupAfter","Cmd-S":"save","Cmd-F":"find","Cmd-G":"findNext","Shift-Cmd-G":"findPrev","Cmd-Alt-F":"replace","Shift-Cmd-Alt-F":"replaceAll","Cmd-[":"indentLess","Cmd-]":"indentMore","Cmd-Backspace":"delWrappedLineLeft","Cmd-Delete":"delWrappedLineRight","Cmd-U":"undoSelection","Shift-Cmd-U":"redoSelection","Ctrl-Up":"goDocStart","Ctrl-Down":"goDocEnd",fallthrough:["basic","emacsy"]},Ia.default=y?Ia.macDefault:Ia.pcDefault;var Xa={selectAll:Zo,singleSelection:function(e){return e.setSelection(e.getCursor("anchor"),e.getCursor("head"),W)},killLine:function(e){return Va(e,(function(t){if(t.empty()){var n=Xe(e.doc,t.head.line).text.length;return t.head.ch==n&&t.head.line<e.lastLine()?{from:t.head,to:ot(t.head.line+1,0)}:{from:t.head,to:ot(t.head.line,n)}}return{from:t.from(),to:t.to()}}))},deleteLine:function(e){return Va(e,(function(t){return{from:ot(t.from().line,0),to:pt(e.doc,ot(t.to().line+1,0))}}))},delLineLeft:function(e){return Va(e,(function(e){return{from:ot(e.from().line,0),to:e.from()}}))},delWrappedLineLeft:function(e){return Va(e,(function(t){var n=e.charCoords(t.head,"div").top+5;return{from:e.coordsChar({left:0,top:n},"div"),to:t.from()}}))},delWrappedLineRight:function(e){return Va(e,(function(t){var n=e.charCoords(t.head,"div").top+5,r=e.coordsChar({left:e.display.lineDiv.offsetWidth+100,top:n},"div");return{from:t.from(),to:r}}))},undo:function(e){return e.undo()},redo:function(e){return e.redo()},undoSelection:function(e){return e.undoSelection()},redoSelection:function(e){return e.redoSelection()},goDocStart:function(e){return e.extendSelection(ot(e.firstLine(),0))},goDocEnd:function(e){return e.extendSelection(ot(e.lastLine()))},goLineStart:function(e){return e.extendSelectionsBy((function(t){return Ja(e,t.head.line)}),{origin:"+move",bias:1})},goLineStartSmart:function(e){return e.extendSelectionsBy((function(t){return es(e,t.head)}),{origin:"+move",bias:1})},goLineEnd:function(e){return e.extendSelectionsBy((function(t){return Qa(e,t.head.line)}),{origin:"+move",bias:-1})},goLineRight:function(e){return e.extendSelectionsBy((function(t){var n=e.cursorCoords(t.head,"div").top+5;return e.coordsChar({left:e.display.lineDiv.offsetWidth+100,top:n},"div")}),U)},goLineLeft:function(e){return e.extendSelectionsBy((function(t){var n=e.cursorCoords(t.head,"div").top+5;return e.coordsChar({left:0,top:n},"div")}),U)},goLineLeftSmart:function(e){return e.extendSelectionsBy((function(t){var n=e.cursorCoords(t.head,"div").top+5,r=e.coordsChar({left:0,top:n},"div");return r.ch<e.getLine(r.line).search(/\S/)?es(e,t.head):r}),U)},goLineUp:function(e){return e.moveV(-1,"line")},goLineDown:function(e){return e.moveV(1,"line")},goPageUp:function(e){return e.moveV(-1,"page")},goPageDown:function(e){return e.moveV(1,"page")},goCharLeft:function(e){return e.moveH(-1,"char")},goCharRight:function(e){return e.moveH(1,"char")},goColumnLeft:function(e){return e.moveH(-1,"column")},goColumnRight:function(e){return e.moveH(1,"column")},goWordLeft:function(e){return e.moveH(-1,"word")},goGroupRight:function(e){return e.moveH(1,"group")},goGroupLeft:function(e){return e.moveH(-1,"group")},goWordRight:function(e){return e.moveH(1,"word")},delCharBefore:function(e){return e.deleteH(-1,"codepoint")},delCharAfter:function(e){return e.deleteH(1,"char")},delWordBefore:function(e){return e.deleteH(-1,"word")},delWordAfter:function(e){return e.deleteH(1,"word")},delGroupBefore:function(e){return e.deleteH(-1,"group")},delGroupAfter:function(e){return e.deleteH(1,"group")},indentAuto:function(e){return e.indentSelection("smart")},indentMore:function(e){return e.indentSelection("add")},indentLess:function(e){return e.indentSelection("subtract")},insertTab:function(e){return e.replaceSelection("\t")},insertSoftTab:function(e){for(var t=[],n=e.listSelections(),r=e.options.tabSize,i=0;i<n.length;i++){var o=n[i].from(),a=I(e.getLine(o.line),o.ch,r);t.push(Y(r-a%r))}e.replaceSelections(t)},defaultTab:function(e){e.somethingSelected()?e.indentSelection("add"):e.execCommand("insertTab")},transposeChars:function(e){return Di(e,(function(){for(var t=e.listSelections(),n=[],r=0;r<t.length;r++)if(t[r].empty()){var i=t[r].head,o=Xe(e.doc,i.line).text;if(o)if(i.ch==o.length&&(i=new ot(i.line,i.ch-1)),i.ch>0)i=new ot(i.line,i.ch+1),e.replaceRange(o.charAt(i.ch-1)+o.charAt(i.ch-2),ot(i.line,i.ch-2),i,"+transpose");else if(i.line>e.doc.first){var a=Xe(e.doc,i.line-1).text;a&&(i=new ot(i.line,1),e.replaceRange(o.charAt(0)+e.doc.lineSeparator()+a.charAt(a.length-1),ot(i.line-1,a.length-1),i,"+transpose"))}n.push(new oo(i,i))}e.setSelections(n)}))},newlineAndIndent:function(e){return Di(e,(function(){for(var t=e.listSelections(),n=t.length-1;n>=0;n--)e.replaceRange(e.doc.lineSeparator(),t[n].anchor,t[n].head,"+input");t=e.listSelections();for(var r=0;r<t.length;r++)e.indentLine(t[r].from().line,null,!0);si(e)}))},openLine:function(e){return e.replaceSelection("\n","start")},toggleOverwrite:function(e){return e.toggleOverwrite()}};function Ja(e,t){var n=Xe(e.doc,t),r=Jt(n);return r!=n&&(t=tt(r)),Ga(!0,e,r,t,1)}function Qa(e,t){var n=Xe(e.doc,t),r=Qt(n);return r!=n&&(t=tt(r)),Ga(!0,e,n,t,-1)}function es(e,t){var n=Ja(e,t.line),r=Xe(e.doc,n.line),i=pe(r,e.doc.direction);if(!i||0==i[0].level){var o=Math.max(n.ch,r.text.search(/\S/)),a=t.line==n.line&&t.ch<=o&&t.ch;return ot(n.line,a?0:o,n.sticky)}return n}function ts(e,t,n){if("string"==typeof t&&!(t=Xa[t]))return!1;e.display.input.ensurePolled();var r=e.display.shift,i=!1;try{e.isReadOnly()&&(e.state.suppressEdits=!0),n&&(e.display.shift=!1),i=t(e)!=B}finally{e.display.shift=r,e.state.suppressEdits=!1}return i}function ns(e,t,n){for(var r=0;r<e.state.keyMaps.length;r++){var i=za(t,e.state.keyMaps[r],n,e);if(i)return i}return e.options.extraKeys&&za(t,e.options.extraKeys,n,e)||za(t,e.options.keyMap,n,e)}var rs=new $;function is(e,t,n,r){var i=e.state.keySeq;if(i){if(Ba(t))return"handled";if(/\'$/.test(t)?e.state.keySeq=null:rs.set(50,(function(){e.state.keySeq==i&&(e.state.keySeq=null,e.display.input.reset())})),os(e,i+" "+t,n,r))return!0}return os(e,t,n,r)}function os(e,t,n,r){var i=ns(e,t,r);return"multi"==i&&(e.state.keySeq=t),"handled"==i&&jn(e,"keyHandled",e,t,n),"handled"!=i&&"multi"!=i||(xe(n),Yr(e)),!!i}function as(e,t){var n=Ha(t,!0);return!!n&&(t.shiftKey&&!e.state.keySeq?is(e,"Shift-"+n,t,(function(t){return ts(e,t,!0)}))||is(e,n,t,(function(t){if("string"==typeof t?/^go[A-Z]/.test(t):t.motion)return ts(e,t)})):is(e,n,t,(function(t){return ts(e,t)})))}function ss(e,t,n){return is(e,"'"+n+"'",t,(function(t){return ts(e,t,!0)}))}var ls=null;function us(e){var t=this;if(!(e.target&&e.target!=t.display.input.getField()||(t.curOp.focus=N(),ye(t,e)))){a&&s<11&&27==e.keyCode&&(e.returnValue=!1);var r=e.keyCode;t.display.shift=16==r||e.shiftKey;var i=as(t,e);f&&(ls=i?r:null,i||88!=r||Fe||!(y?e.metaKey:e.ctrlKey)||t.replaceSelection("",null,"cut")),n&&!y&&!i&&46==r&&e.shiftKey&&!e.ctrlKey&&document.execCommand&&document.execCommand("cut"),18!=r||/\bCodeMirror-crosshair\b/.test(t.display.lineDiv.className)||cs(t)}}function cs(e){var t=e.display.lineDiv;function n(e){18!=e.keyCode&&e.altKey||(O(t,"CodeMirror-crosshair"),me(document,"keyup",n),me(document,"mouseover",n))}L(t,"CodeMirror-crosshair"),he(document,"keyup",n),he(document,"mouseover",n)}function fs(e){16==e.keyCode&&(this.doc.sel.shift=!1),ye(this,e)}function ps(e){var t=this;if(!(e.target&&e.target!=t.display.input.getField()||Hn(t.display,e)||ye(t,e)||e.ctrlKey&&!e.altKey||y&&e.metaKey)){var n=e.keyCode,r=e.charCode;if(f&&n==ls)return ls=null,void xe(e);if(!f||e.which&&!(e.which<10)||!as(t,e)){var i=String.fromCharCode(null==r?n:r);"\b"!=i&&(ss(t,e,i)||t.display.input.onKeyPress(e))}}}var ds,hs,gs=400,ms=function(e,t,n){this.time=e,this.pos=t,this.button=n};function vs(e,t){var n=+new Date;return hs&&hs.compare(n,e,t)?(ds=hs=null,"triple"):ds&&ds.compare(n,e,t)?(hs=new ms(n,e,t),ds=null,"double"):(ds=new ms(n,e,t),hs=null,"single")}function ys(e){var t=this,n=t.display;if(!(ye(t,e)||n.activeTouch&&n.input.supportsTouch()))if(n.input.ensurePolled(),n.shift=e.shiftKey,Hn(n,e))l||(n.scroller.draggable=!1,setTimeout((function(){return n.scroller.draggable=!0}),100));else if(!As(t,e)){var r=Pr(t,e),i=Ae(e),o=r?vs(r,i):"single";window.focus(),1==i&&t.state.selectingText&&t.state.selectingText(e),r&&bs(t,i,r,o,e)||(1==i?r?ws(t,r,o,e):Oe(e)==n.scroller&&xe(e):2==i?(r&&Fo(t.doc,r),setTimeout((function(){return n.input.focus()}),20)):3==i&&(k?t.display.input.onContextMenu(e):Zr(t)))}}function bs(e,t,n,r,i){var o="Click";return"double"==r?o="Double"+o:"triple"==r&&(o="Triple"+o),is(e,Wa(o=(1==t?"Left":2==t?"Middle":"Right")+o,i),i,(function(t){if("string"==typeof t&&(t=Xa[t]),!t)return!1;var r=!1;try{e.isReadOnly()&&(e.state.suppressEdits=!0),r=t(e,n)!=B}finally{e.state.suppressEdits=!1}return r}))}function _s(e,t,n){var r=e.getOption("configureMouse"),i=r?r(e,t,n):{};if(null==i.unit){var o=b?n.shiftKey&&n.metaKey:n.altKey;i.unit=o?"rectangle":"single"==t?"char":"double"==t?"word":"line"}return(null==i.extend||e.doc.extend)&&(i.extend=e.doc.extend||n.shiftKey),null==i.addNew&&(i.addNew=y?n.metaKey:n.ctrlKey),null==i.moveOnDrag&&(i.moveOnDrag=!(y?n.altKey:n.ctrlKey)),i}function ws(e,t,n,r){a?setTimeout(F(Gr,e),0):e.curOp.focus=N();var i,o=_s(e,n,r),s=e.doc.sel;e.options.dragDrop&&Te&&!e.isReadOnly()&&"single"==n&&(i=s.contains(t))>-1&&(at((i=s.ranges[i]).from(),t)<0||t.xRel>0)&&(at(i.to(),t)>0||t.xRel<0)?xs(e,r,t,o):Cs(e,r,t,o)}function xs(e,t,n,r){var i=e.display,o=!1,u=Ni(e,(function(t){l&&(i.scroller.draggable=!1),e.state.draggingText=!1,e.state.delayingBlurEvent&&(e.hasFocus()?e.state.delayingBlurEvent=!1:Zr(e)),me(i.wrapper.ownerDocument,"mouseup",u),me(i.wrapper.ownerDocument,"mousemove",c),me(i.scroller,"dragstart",f),me(i.scroller,"drop",u),o||(xe(t),r.addNew||Fo(e.doc,n,null,null,r.extend),l&&!p||a&&9==s?setTimeout((function(){i.wrapper.ownerDocument.body.focus({preventScroll:!0}),i.input.focus()}),20):i.input.focus())})),c=function(e){o=o||Math.abs(t.clientX-e.clientX)+Math.abs(t.clientY-e.clientY)>=10},f=function(){return o=!0};l&&(i.scroller.draggable=!0),e.state.draggingText=u,u.copy=!r.moveOnDrag,he(i.wrapper.ownerDocument,"mouseup",u),he(i.wrapper.ownerDocument,"mousemove",c),he(i.scroller,"dragstart",f),he(i.scroller,"drop",u),e.state.delayingBlurEvent=!0,setTimeout((function(){return i.input.focus()}),20),i.scroller.dragDrop&&i.scroller.dragDrop()}function ks(e,t,n){if("char"==n)return new oo(t,t);if("word"==n)return e.findWordAt(t);if("line"==n)return new oo(ot(t.line,0),pt(e.doc,ot(t.line+1,0)));var r=n(e,t);return new oo(r.from,r.to)}function Cs(e,t,n,r){a&&Zr(e);var i=e.display,o=e.doc;xe(t);var s,l,u=o.sel,c=u.ranges;if(r.addNew&&!r.extend?(l=o.sel.contains(n),s=l>-1?c[l]:new oo(n,n)):(s=o.sel.primary(),l=o.sel.primIndex),"rectangle"==r.unit)r.addNew||(s=new oo(n,n)),n=Pr(e,t,!0,!0),l=-1;else{var f=ks(e,n,r.unit);s=r.extend?Po(s,f.anchor,f.head,r.extend):f}r.addNew?-1==l?(l=c.length,Bo(o,ao(e,c.concat([s]),l),{scroll:!1,origin:"*mouse"})):c.length>1&&c[l].empty()&&"char"==r.unit&&!r.extend?(Bo(o,ao(e,c.slice(0,l).concat(c.slice(l+1)),0),{scroll:!1,origin:"*mouse"}),u=o.sel):Io(o,l,s,H):(l=0,Bo(o,new io([s],0),H),u=o.sel);var p=n;function d(t){if(0!=at(p,t))if(p=t,"rectangle"==r.unit){for(var i=[],a=e.options.tabSize,c=I(Xe(o,n.line).text,n.ch,a),f=I(Xe(o,t.line).text,t.ch,a),d=Math.min(c,f),h=Math.max(c,f),g=Math.min(n.line,t.line),m=Math.min(e.lastLine(),Math.max(n.line,t.line));g<=m;g++){var v=Xe(o,g).text,y=V(v,d,a);d==h?i.push(new oo(ot(g,y),ot(g,y))):v.length>y&&i.push(new oo(ot(g,y),ot(g,V(v,h,a))))}i.length||i.push(new oo(n,n)),Bo(o,ao(e,u.ranges.slice(0,l).concat(i),l),{origin:"*mouse",scroll:!1}),e.scrollIntoView(t)}else{var b,_=s,w=ks(e,t,r.unit),x=_.anchor;at(w.anchor,x)>0?(b=w.head,x=ct(_.from(),w.anchor)):(b=w.anchor,x=ut(_.to(),w.head));var k=u.ranges.slice(0);k[l]=Es(e,new oo(pt(o,x),b)),Bo(o,ao(e,k,l),H)}}var h=i.wrapper.getBoundingClientRect(),g=0;function m(t){var n=++g,a=Pr(e,t,!0,"rectangle"==r.unit);if(a)if(0!=at(a,p)){e.curOp.focus=N(),d(a);var s=ti(i,o);(a.line>=s.to||a.line<s.from)&&setTimeout(Ni(e,(function(){g==n&&m(t)})),150)}else{var l=t.clientY<h.top?-20:t.clientY>h.bottom?20:0;l&&setTimeout(Ni(e,(function(){g==n&&(i.scroller.scrollTop+=l,m(t))})),50)}}function v(t){e.state.selectingText=!1,g=1/0,t&&(xe(t),i.input.focus()),me(i.wrapper.ownerDocument,"mousemove",y),me(i.wrapper.ownerDocument,"mouseup",b),o.history.lastSelOrigin=null}var y=Ni(e,(function(e){0!==e.buttons&&Ae(e)?m(e):v(e)})),b=Ni(e,v);e.state.selectingText=b,he(i.wrapper.ownerDocument,"mousemove",y),he(i.wrapper.ownerDocument,"mouseup",b)}function Es(e,t){var n=t.anchor,r=t.head,i=Xe(e.doc,n.line);if(0==at(n,r)&&n.sticky==r.sticky)return t;var o=pe(i);if(!o)return t;var a=ce(o,n.ch,n.sticky),s=o[a];if(s.from!=n.ch&&s.to!=n.ch)return t;var l,u=a+(s.from==n.ch==(1!=s.level)?0:1);if(0==u||u==o.length)return t;if(r.line!=n.line)l=(r.line-n.line)*("ltr"==e.doc.direction?1:-1)>0;else{var c=ce(o,r.ch,r.sticky),f=c-a||(r.ch-n.ch)*(1==s.level?-1:1);l=c==u-1||c==u?f<0:f>0}var p=o[u+(l?-1:0)],d=l==(1==p.level),h=d?p.from:p.to,g=d?"after":"before";return n.ch==h&&n.sticky==g?t:new oo(new ot(n.line,h,g),r)}function Os(e,t,n,r){var i,o;if(t.touches)i=t.touches[0].clientX,o=t.touches[0].clientY;else try{i=t.clientX,o=t.clientY}catch(c){return!1}if(i>=Math.floor(e.display.gutters.getBoundingClientRect().right))return!1;r&&xe(t);var a=e.display,s=a.lineDiv.getBoundingClientRect();if(o>s.bottom||!_e(e,n))return Ce(t);o-=s.top-a.viewOffset;for(var l=0;l<e.display.gutterSpecs.length;++l){var u=a.gutters.childNodes[l];if(u&&u.getBoundingClientRect().right>=i)return ve(e,n,e,nt(e.doc,o),e.display.gutterSpecs[l].className,t),Ce(t)}}function As(e,t){return Os(e,t,"gutterClick",!0)}function Ss(e,t){Hn(e.display,t)||js(e,t)||ye(e,t,"contextmenu")||k||e.display.input.onContextMenu(t)}function js(e,t){return!!_e(e,"gutterContextMenu")&&Os(e,t,"gutterContextMenu",!1)}function Ts(e){e.display.wrapper.className=e.display.wrapper.className.replace(/\s*cm-s-\S+/g,"")+e.options.theme.replace(/(^|\s)\s*/g," cm-s-"),pr(e)}ms.prototype.compare=function(e,t,n){return this.time+gs>e&&0==at(t,this.pos)&&n==this.button};var Ds={toString:function(){return"CodeMirror.Init"}},Ns={},Ls={};function Ms(e){var t=e.optionHandlers;function n(n,r,i,o){e.defaults[n]=r,i&&(t[n]=o?function(e,t,n){n!=Ds&&i(e,t,n)}:i)}e.defineOption=n,e.Init=Ds,n("value","",(function(e,t){return e.setValue(t)}),!0),n("mode",null,(function(e,t){e.doc.modeOption=t,ho(e)}),!0),n("indentUnit",2,ho,!0),n("indentWithTabs",!1),n("smartIndent",!0),n("tabSize",4,(function(e){go(e),pr(e),qr(e)}),!0),n("lineSeparator",null,(function(e,t){if(e.doc.lineSep=t,t){var n=[],r=e.doc.first;e.doc.iter((function(e){for(var i=0;;){var o=e.text.indexOf(t,i);if(-1==o)break;i=o+t.length,n.push(ot(r,o))}r++}));for(var i=n.length-1;i>=0;i--)ia(e.doc,t,n[i],ot(n[i].line,n[i].ch+t.length))}})),n("specialChars",/[\u0000-\u001f\u007f-\u009f\u00ad\u061c\u200b\u200e\u200f\u2028\u2029\ufeff\ufff9-\ufffc]/g,(function(e,t,n){e.state.specialChars=new RegExp(t.source+(t.test("\t")?"":"|\t"),"g"),n!=Ds&&e.refresh()})),n("specialCharPlaceholder",mn,(function(e){return e.refresh()}),!0),n("electricChars",!0),n("inputStyle",v?"contenteditable":"textarea",(function(){throw new Error("inputStyle can not (yet) be changed in a running editor")}),!0),n("spellcheck",!1,(function(e,t){return e.getInputField().spellcheck=t}),!0),n("autocorrect",!1,(function(e,t){return e.getInputField().autocorrect=t}),!0),n("autocapitalize",!1,(function(e,t){return e.getInputField().autocapitalize=t}),!0),n("rtlMoveVisually",!_),n("wholeLineUpdateBefore",!0),n("theme","default",(function(e){Ts(e),Xi(e)}),!0),n("keyMap","default",(function(e,t,n){var r=Ua(t),i=n!=Ds&&Ua(n);i&&i.detach&&i.detach(e,r),r.attach&&r.attach(e,i||null)})),n("extraKeys",null),n("configureMouse",null),n("lineWrapping",!1,Fs,!0),n("gutters",[],(function(e,t){e.display.gutterSpecs=Gi(t,e.options.lineNumbers),Xi(e)}),!0),n("fixedGutter",!0,(function(e,t){e.display.gutters.style.left=t?Nr(e.display)+"px":"0",e.refresh()}),!0),n("coverGutterNextToScrollbar",!1,(function(e){return yi(e)}),!0),n("scrollbarStyle","native",(function(e){wi(e),yi(e),e.display.scrollbars.setScrollTop(e.doc.scrollTop),e.display.scrollbars.setScrollLeft(e.doc.scrollLeft)}),!0),n("lineNumbers",!1,(function(e,t){e.display.gutterSpecs=Gi(e.options.gutters,t),Xi(e)}),!0),n("firstLineNumber",1,Xi,!0),n("lineNumberFormatter",(function(e){return e}),Xi,!0),n("showCursorWhenSelecting",!1,Wr,!0),n("resetSelectionOnContextMenu",!0),n("lineWiseCopyCut",!0),n("pasteLinesPerSelection",!0),n("selectionsMayTouch",!1),n("readOnly",!1,(function(e,t){"nocursor"==t&&(Jr(e),e.display.input.blur()),e.display.input.readOnlyChanged(t)})),n("screenReaderLabel",null,(function(e,t){t=""===t?null:t,e.display.input.screenReaderLabelChanged(t)})),n("disableInput",!1,(function(e,t){t||e.display.input.reset()}),!0),n("dragDrop",!0,Ps),n("allowDropFileTypes",null),n("cursorBlinkRate",530),n("cursorScrollMargin",0),n("cursorHeight",1,Wr,!0),n("singleCursorHeightPerLine",!0,Wr,!0),n("workTime",100),n("workDelay",100),n("flattenSpans",!0,go,!0),n("addModeClass",!1,go,!0),n("pollInterval",100),n("undoDepth",200,(function(e,t){return e.doc.history.undoDepth=t})),n("historyEventDelay",1250),n("viewportMargin",10,(function(e){return e.refresh()}),!0),n("maxHighlightLength",1e4,go,!0),n("moveInputWithCursor",!0,(function(e,t){t||e.display.input.resetPosition()})),n("tabindex",null,(function(e,t){return e.display.input.getField().tabIndex=t||""})),n("autofocus",null),n("direction","ltr",(function(e,t){return e.doc.setDirection(t)}),!0),n("phrases",null)}function Ps(e,t,n){if(!t!=!(n&&n!=Ds)){var r=e.display.dragFunctions,i=t?he:me;i(e.display.scroller,"dragstart",r.start),i(e.display.scroller,"dragenter",r.enter),i(e.display.scroller,"dragover",r.over),i(e.display.scroller,"dragleave",r.leave),i(e.display.scroller,"drop",r.drop)}}function Fs(e){e.options.lineWrapping?(L(e.display.wrapper,"CodeMirror-wrap"),e.display.sizer.style.minWidth="",e.display.sizerWidth=null):(O(e.display.wrapper,"CodeMirror-wrap"),ln(e)),Mr(e),qr(e),pr(e),setTimeout((function(){return yi(e)}),100)}function qs(e,t){var n=this;if(!(this instanceof qs))return new qs(e,t);this.options=t=t?q(t):{},q(Ns,t,!1);var r=t.value;"string"==typeof r?r=new ka(r,t.mode,null,t.lineSeparator,t.direction):t.mode&&(r.modeOption=t.mode),this.doc=r;var i=new qs.inputStyles[t.inputStyle](this),o=this.display=new Ji(e,r,i,t);for(var u in o.wrapper.CodeMirror=this,Ts(this),t.lineWrapping&&(this.display.wrapper.className+=" CodeMirror-wrap"),wi(this),this.state={keyMaps:[],overlays:[],modeGen:0,overwrite:!1,delayingBlurEvent:!1,focused:!1,suppressEdits:!1,pasteIncoming:-1,cutIncoming:-1,selectingText:!1,draggingText:!1,highlight:new $,keySeq:null,specialChars:null},t.autofocus&&!v&&o.input.focus(),a&&s<11&&setTimeout((function(){return n.display.input.reset(!0)}),20),Is(this),Da(),ki(this),this.curOp.forceUpdate=!0,bo(this,r),t.autofocus&&!v||this.hasFocus()?setTimeout((function(){n.hasFocus()&&!n.state.focused&&Xr(n)}),20):Jr(this),Ls)Ls.hasOwnProperty(u)&&Ls[u](this,t[u],Ds);Yi(this),t.finishInit&&t.finishInit(this);for(var c=0;c<$s.length;++c)$s[c](this);Ci(this),l&&t.lineWrapping&&"optimizelegibility"==getComputedStyle(o.lineDiv).textRendering&&(o.lineDiv.style.textRendering="auto")}function Is(e){var t=e.display;he(t.scroller,"mousedown",Ni(e,ys)),he(t.scroller,"dblclick",a&&s<11?Ni(e,(function(t){if(!ye(e,t)){var n=Pr(e,t);if(n&&!As(e,t)&&!Hn(e.display,t)){xe(t);var r=e.findWordAt(n);Fo(e.doc,r.anchor,r.head)}}})):function(t){return ye(e,t)||xe(t)}),he(t.scroller,"contextmenu",(function(t){return Ss(e,t)})),he(t.input.getField(),"contextmenu",(function(n){t.scroller.contains(n.target)||Ss(e,n)}));var n,r={end:0};function i(){t.activeTouch&&(n=setTimeout((function(){return t.activeTouch=null}),1e3),(r=t.activeTouch).end=+new Date)}function o(e){if(1!=e.touches.length)return!1;var t=e.touches[0];return t.radiusX<=1&&t.radiusY<=1}function l(e,t){if(null==t.left)return!0;var n=t.left-e.left,r=t.top-e.top;return n*n+r*r>400}he(t.scroller,"touchstart",(function(i){if(!ye(e,i)&&!o(i)&&!As(e,i)){t.input.ensurePolled(),clearTimeout(n);var a=+new Date;t.activeTouch={start:a,moved:!1,prev:a-r.end<=300?r:null},1==i.touches.length&&(t.activeTouch.left=i.touches[0].pageX,t.activeTouch.top=i.touches[0].pageY)}})),he(t.scroller,"touchmove",(function(){t.activeTouch&&(t.activeTouch.moved=!0)})),he(t.scroller,"touchend",(function(n){var r=t.activeTouch;if(r&&!Hn(t,n)&&null!=r.left&&!r.moved&&new Date-r.start<300){var o,a=e.coordsChar(t.activeTouch,"page");o=!r.prev||l(r,r.prev)?new oo(a,a):!r.prev.prev||l(r,r.prev.prev)?e.findWordAt(a):new oo(ot(a.line,0),pt(e.doc,ot(a.line+1,0))),e.setSelection(o.anchor,o.head),e.focus(),xe(n)}i()})),he(t.scroller,"touchcancel",i),he(t.scroller,"scroll",(function(){t.scroller.clientHeight&&(pi(e,t.scroller.scrollTop),hi(e,t.scroller.scrollLeft,!0),ve(e,"scroll",e))})),he(t.scroller,"mousewheel",(function(t){return ro(e,t)})),he(t.scroller,"DOMMouseScroll",(function(t){return ro(e,t)})),he(t.wrapper,"scroll",(function(){return t.wrapper.scrollTop=t.wrapper.scrollLeft=0})),t.dragFunctions={enter:function(t){ye(e,t)||Ee(t)},over:function(t){ye(e,t)||(Aa(e,t),Ee(t))},start:function(t){return Oa(e,t)},drop:Ni(e,Ea),leave:function(t){ye(e,t)||Sa(e)}};var u=t.input.getField();he(u,"keyup",(function(t){return fs.call(e,t)})),he(u,"keydown",Ni(e,us)),he(u,"keypress",Ni(e,ps)),he(u,"focus",(function(t){return Xr(e,t)})),he(u,"blur",(function(t){return Jr(e,t)}))}qs.defaults=Ns,qs.optionHandlers=Ls;var $s=[];function Rs(e,t,n,r){var i,o=e.doc;null==n&&(n="add"),"smart"==n&&(o.mode.indent?i=bt(e,t).state:n="prev");var a=e.options.tabSize,s=Xe(o,t),l=I(s.text,null,a);s.stateAfter&&(s.stateAfter=null);var u,c=s.text.match(/^\s*/)[0];if(r||/\S/.test(s.text)){if("smart"==n&&((u=o.mode.indent(i,s.text.slice(c.length),s.text))==B||u>150)){if(!r)return;n="prev"}}else u=0,n="not";"prev"==n?u=t>o.first?I(Xe(o,t-1).text,null,a):0:"add"==n?u=l+e.options.indentUnit:"subtract"==n?u=l-e.options.indentUnit:"number"==typeof n&&(u=l+n),u=Math.max(0,u);var f="",p=0;if(e.options.indentWithTabs)for(var d=Math.floor(u/a);d;--d)p+=a,f+="\t";if(p<u&&(f+=Y(u-p)),f!=c)return ia(o,f,ot(t,0),ot(t,c.length),"+input"),s.stateAfter=null,!0;for(var h=0;h<o.sel.ranges.length;h++){var g=o.sel.ranges[h];if(g.head.line==t&&g.head.ch<c.length){var m=ot(t,c.length);Io(o,h,new oo(m,m));break}}}qs.defineInitHook=function(e){return $s.push(e)};var zs=null;function Bs(e){zs=e}function Ws(e,t,n,r,i){var o=e.doc;e.display.shift=!1,r||(r=o.sel);var a=+new Date-200,s="paste"==i||e.state.pasteIncoming>a,l=Me(t),u=null;if(s&&r.ranges.length>1)if(zs&&zs.text.join("\n")==t){if(r.ranges.length%zs.text.length==0){u=[];for(var c=0;c<zs.text.length;c++)u.push(o.splitLines(zs.text[c]))}}else l.length==r.ranges.length&&e.options.pasteLinesPerSelection&&(u=Z(l,(function(e){return[e]})));for(var f=e.curOp.updateInput,p=r.ranges.length-1;p>=0;p--){var d=r.ranges[p],h=d.from(),g=d.to();d.empty()&&(n&&n>0?h=ot(h.line,h.ch-n):e.state.overwrite&&!s?g=ot(g.line,Math.min(Xe(o,g.line).text.length,g.ch+G(l).length)):s&&zs&&zs.lineWise&&zs.text.join("\n")==l.join("\n")&&(h=g=ot(h.line,0)));var m={from:h,to:g,text:u?u[p%u.length]:l,origin:i||(s?"paste":e.state.cutIncoming>a?"cut":"+input")};Jo(e.doc,m),jn(e,"inputRead",e,m)}t&&!s&&Us(e,t),si(e),e.curOp.updateInput<2&&(e.curOp.updateInput=f),e.curOp.typing=!0,e.state.pasteIncoming=e.state.cutIncoming=-1}function Hs(e,t){var n=e.clipboardData&&e.clipboardData.getData("Text");if(n)return e.preventDefault(),t.isReadOnly()||t.options.disableInput||Di(t,(function(){return Ws(t,n,0,null,"paste")})),!0}function Us(e,t){if(e.options.electricChars&&e.options.smartIndent)for(var n=e.doc.sel,r=n.ranges.length-1;r>=0;r--){var i=n.ranges[r];if(!(i.head.ch>100||r&&n.ranges[r-1].head.line==i.head.line)){var o=e.getModeAt(i.head),a=!1;if(o.electricChars){for(var s=0;s<o.electricChars.length;s++)if(t.indexOf(o.electricChars.charAt(s))>-1){a=Rs(e,i.head.line,"smart");break}}else o.electricInput&&o.electricInput.test(Xe(e.doc,i.head.line).text.slice(0,i.head.ch))&&(a=Rs(e,i.head.line,"smart"));a&&jn(e,"electricInput",e,i.head.line)}}}function Vs(e){for(var t=[],n=[],r=0;r<e.doc.sel.ranges.length;r++){var i=e.doc.sel.ranges[r].head.line,o={anchor:ot(i,0),head:ot(i+1,0)};n.push(o),t.push(e.getRange(o.anchor,o.head))}return{text:t,ranges:n}}function Ks(e,t,n,r){e.setAttribute("autocorrect",n?"":"off"),e.setAttribute("autocapitalize",r?"":"off"),e.setAttribute("spellcheck",!!t)}function Ys(){var e=j("textarea",null,null,"position: absolute; bottom: -1em; padding: 0; width: 1px; height: 1em; outline: none"),t=j("div",[e],null,"overflow: hidden; position: relative; width: 3px; height: 0px;");return l?e.style.width="1000px":e.setAttribute("wrap","off"),g&&(e.style.border="1px solid black"),Ks(e),t}function Gs(e){var t=e.optionHandlers,n=e.helpers={};e.prototype={constructor:e,focus:function(){window.focus(),this.display.input.focus()},setOption:function(e,n){var r=this.options,i=r[e];r[e]==n&&"mode"!=e||(r[e]=n,t.hasOwnProperty(e)&&Ni(this,t[e])(this,n,i),ve(this,"optionChange",this,e))},getOption:function(e){return this.options[e]},getDoc:function(){return this.doc},addKeyMap:function(e,t){this.state.keyMaps[t?"push":"unshift"](Ua(e))},removeKeyMap:function(e){for(var t=this.state.keyMaps,n=0;n<t.length;++n)if(t[n]==e||t[n].name==e)return t.splice(n,1),!0},addOverlay:Li((function(t,n){var r=t.token?t:e.getMode(this.options,t);if(r.startState)throw new Error("Overlays may not be stateful.");X(this.state.overlays,{mode:r,modeSpec:t,opaque:n&&n.opaque,priority:n&&n.priority||0},(function(e){return e.priority})),this.state.modeGen++,qr(this)})),removeOverlay:Li((function(e){for(var t=this.state.overlays,n=0;n<t.length;++n){var r=t[n].modeSpec;if(r==e||"string"==typeof e&&r.name==e)return t.splice(n,1),this.state.modeGen++,void qr(this)}})),indentLine:Li((function(e,t,n){"string"!=typeof t&&"number"!=typeof t&&(t=null==t?this.options.smartIndent?"smart":"prev":t?"add":"subtract"),rt(this.doc,e)&&Rs(this,e,t,n)})),indentSelection:Li((function(e){for(var t=this.doc.sel.ranges,n=-1,r=0;r<t.length;r++){var i=t[r];if(i.empty())i.head.line>n&&(Rs(this,i.head.line,e,!0),n=i.head.line,r==this.doc.sel.primIndex&&si(this));else{var o=i.from(),a=i.to(),s=Math.max(n,o.line);n=Math.min(this.lastLine(),a.line-(a.ch?0:1))+1;for(var l=s;l<n;++l)Rs(this,l,e);var u=this.doc.sel.ranges;0==o.ch&&t.length==u.length&&u[r].from().ch>0&&Io(this.doc,r,new oo(o,u[r].to()),W)}}})),getTokenAt:function(e,t){return Ct(this,e,t)},getLineTokens:function(e,t){return Ct(this,ot(e),t,!0)},getTokenTypeAt:function(e){e=pt(this.doc,e);var t,n=yt(this,Xe(this.doc,e.line)),r=0,i=(n.length-1)/2,o=e.ch;if(0==o)t=n[2];else for(;;){var a=r+i>>1;if((a?n[2*a-1]:0)>=o)i=a;else{if(!(n[2*a+1]<o)){t=n[2*a+2];break}r=a+1}}var s=t?t.indexOf("overlay "):-1;return s<0?t:0==s?null:t.slice(0,s-1)},getModeAt:function(t){var n=this.doc.mode;return n.innerMode?e.innerMode(n,this.getTokenAt(t).state).mode:n},getHelper:function(e,t){return this.getHelpers(e,t)[0]},getHelpers:function(e,t){var r=[];if(!n.hasOwnProperty(t))return r;var i=n[t],o=this.getModeAt(e);if("string"==typeof o[t])i[o[t]]&&r.push(i[o[t]]);else if(o[t])for(var a=0;a<o[t].length;a++){var s=i[o[t][a]];s&&r.push(s)}else o.helperType&&i[o.helperType]?r.push(i[o.helperType]):i[o.name]&&r.push(i[o.name]);for(var l=0;l<i._global.length;l++){var u=i._global[l];u.pred(o,this)&&-1==R(r,u.val)&&r.push(u.val)}return r},getStateAfter:function(e,t){var n=this.doc;return bt(this,(e=ft(n,null==e?n.first+n.size-1:e))+1,t).state},cursorCoords:function(e,t){var n=this.doc.sel.primary();return br(this,null==e?n.head:"object"==typeof e?pt(this.doc,e):e?n.from():n.to(),t||"page")},charCoords:function(e,t){return yr(this,pt(this.doc,e),t||"page")},coordsChar:function(e,t){return xr(this,(e=vr(this,e,t||"page")).left,e.top)},lineAtHeight:function(e,t){return e=vr(this,{top:e,left:0},t||"page").top,nt(this.doc,e+this.display.viewOffset)},heightAtLine:function(e,t,n){var r,i=!1;if("number"==typeof e){var o=this.doc.first+this.doc.size-1;e<this.doc.first?e=this.doc.first:e>o&&(e=o,i=!0),r=Xe(this.doc,e)}else r=e;return mr(this,r,{top:0,left:0},t||"page",n||i).top+(i?this.doc.height-an(r):0)},defaultTextHeight:function(){return jr(this.display)},defaultCharWidth:function(){return Tr(this.display)},getViewport:function(){return{from:this.display.viewFrom,to:this.display.viewTo}},addWidget:function(e,t,n,r,i){var o=this.display,a=(e=br(this,pt(this.doc,e))).bottom,s=e.left;if(t.style.position="absolute",t.setAttribute("cm-ignore-events","true"),this.display.input.setUneditable(t),o.sizer.appendChild(t),"over"==r)a=e.top;else if("above"==r||"near"==r){var l=Math.max(o.wrapper.clientHeight,this.doc.height),u=Math.max(o.sizer.clientWidth,o.lineSpace.clientWidth);("above"==r||e.bottom+t.offsetHeight>l)&&e.top>t.offsetHeight?a=e.top-t.offsetHeight:e.bottom+t.offsetHeight<=l&&(a=e.bottom),s+t.offsetWidth>u&&(s=u-t.offsetWidth)}t.style.top=a+"px",t.style.left=t.style.right="","right"==i?(s=o.sizer.clientWidth-t.offsetWidth,t.style.right="0px"):("left"==i?s=0:"middle"==i&&(s=(o.sizer.clientWidth-t.offsetWidth)/2),t.style.left=s+"px"),n&&ii(this,{left:s,top:a,right:s+t.offsetWidth,bottom:a+t.offsetHeight})},triggerOnKeyDown:Li(us),triggerOnKeyPress:Li(ps),triggerOnKeyUp:fs,triggerOnMouseDown:Li(ys),execCommand:function(e){if(Xa.hasOwnProperty(e))return Xa[e].call(null,this)},triggerElectric:Li((function(e){Us(this,e)})),findPosH:function(e,t,n,r){var i=1;t<0&&(i=-1,t=-t);for(var o=pt(this.doc,e),a=0;a<t&&!(o=Zs(this.doc,o,i,n,r)).hitSide;++a);return o},moveH:Li((function(e,t){var n=this;this.extendSelectionsBy((function(r){return n.display.shift||n.doc.extend||r.empty()?Zs(n.doc,r.head,e,t,n.options.rtlMoveVisually):e<0?r.from():r.to()}),U)})),deleteH:Li((function(e,t){var n=this.doc.sel,r=this.doc;n.somethingSelected()?r.replaceSelection("",null,"+delete"):Va(this,(function(n){var i=Zs(r,n.head,e,t,!1);return e<0?{from:i,to:n.head}:{from:n.head,to:i}}))})),findPosV:function(e,t,n,r){var i=1,o=r;t<0&&(i=-1,t=-t);for(var a=pt(this.doc,e),s=0;s<t;++s){var l=br(this,a,"div");if(null==o?o=l.left:l.left=o,(a=Xs(this,l,i,n)).hitSide)break}return a},moveV:Li((function(e,t){var n=this,r=this.doc,i=[],o=!this.display.shift&&!r.extend&&r.sel.somethingSelected();if(r.extendSelectionsBy((function(a){if(o)return e<0?a.from():a.to();var s=br(n,a.head,"div");null!=a.goalColumn&&(s.left=a.goalColumn),i.push(s.left);var l=Xs(n,s,e,t);return"page"==t&&a==r.sel.primary()&&ai(n,yr(n,l,"div").top-s.top),l}),U),i.length)for(var a=0;a<r.sel.ranges.length;a++)r.sel.ranges[a].goalColumn=i[a]})),findWordAt:function(e){var t=Xe(this.doc,e.line).text,n=e.ch,r=e.ch;if(t){var i=this.getHelper(e,"wordChars");"before"!=e.sticky&&r!=t.length||!n?++r:--n;for(var o=t.charAt(n),a=ne(o,i)?function(e){return ne(e,i)}:/\s/.test(o)?function(e){return/\s/.test(e)}:function(e){return!/\s/.test(e)&&!ne(e)};n>0&&a(t.charAt(n-1));)--n;for(;r<t.length&&a(t.charAt(r));)++r}return new oo(ot(e.line,n),ot(e.line,r))},toggleOverwrite:function(e){null!=e&&e==this.state.overwrite||((this.state.overwrite=!this.state.overwrite)?L(this.display.cursorDiv,"CodeMirror-overwrite"):O(this.display.cursorDiv,"CodeMirror-overwrite"),ve(this,"overwriteToggle",this,this.state.overwrite))},hasFocus:function(){return this.display.input.getField()==N()},isReadOnly:function(){return!(!this.options.readOnly&&!this.doc.cantEdit)},scrollTo:Li((function(e,t){li(this,e,t)})),getScrollInfo:function(){var e=this.display.scroller;return{left:e.scrollLeft,top:e.scrollTop,height:e.scrollHeight-Yn(this)-this.display.barHeight,width:e.scrollWidth-Yn(this)-this.display.barWidth,clientHeight:Zn(this),clientWidth:Gn(this)}},scrollIntoView:Li((function(e,t){null==e?(e={from:this.doc.sel.primary().head,to:null},null==t&&(t=this.options.cursorScrollMargin)):"number"==typeof e?e={from:ot(e,0),to:null}:null==e.from&&(e={from:e,to:null}),e.to||(e.to=e.from),e.margin=t||0,null!=e.from.line?ui(this,e):fi(this,e.from,e.to,e.margin)})),setSize:Li((function(e,t){var n=this,r=function(e){return"number"==typeof e||/^\d+$/.test(String(e))?e+"px":e};null!=e&&(this.display.wrapper.style.width=r(e)),null!=t&&(this.display.wrapper.style.height=r(t)),this.options.lineWrapping&&fr(this);var i=this.display.viewFrom;this.doc.iter(i,this.display.viewTo,(function(e){if(e.widgets)for(var t=0;t<e.widgets.length;t++)if(e.widgets[t].noHScroll){Ir(n,i,"widget");break}++i})),this.curOp.forceUpdate=!0,ve(this,"refresh",this)})),operation:function(e){return Di(this,e)},startOperation:function(){return ki(this)},endOperation:function(){return Ci(this)},refresh:Li((function(){var e=this.display.cachedTextHeight;qr(this),this.curOp.forceUpdate=!0,pr(this),li(this,this.doc.scrollLeft,this.doc.scrollTop),Ui(this.display),(null==e||Math.abs(e-jr(this.display))>.5||this.options.lineWrapping)&&Mr(this),ve(this,"refresh",this)})),swapDoc:Li((function(e){var t=this.doc;return t.cm=null,this.state.selectingText&&this.state.selectingText(),bo(this,e),pr(this),this.display.input.reset(),li(this,e.scrollLeft,e.scrollTop),this.curOp.forceScroll=!0,jn(this,"swapDoc",this,t),t})),phrase:function(e){var t=this.options.phrases;return t&&Object.prototype.hasOwnProperty.call(t,e)?t[e]:e},getInputField:function(){return this.display.input.getField()},getWrapperElement:function(){return this.display.wrapper},getScrollerElement:function(){return this.display.scroller},getGutterElement:function(){return this.display.gutters}},we(e),e.registerHelper=function(t,r,i){n.hasOwnProperty(t)||(n[t]=e[t]={_global:[]}),n[t][r]=i},e.registerGlobalHelper=function(t,r,i,o){e.registerHelper(t,r,o),n[t]._global.push({pred:i,val:o})}}function Zs(e,t,n,r,i){var o=t,a=n,s=Xe(e,t.line),l=i&&"rtl"==e.direction?-n:n;function u(){var n=t.line+l;return!(n<e.first||n>=e.first+e.size)&&(t=new ot(n,t.ch,t.sticky),s=Xe(e,n))}function c(o){var a;if("codepoint"==r){var c=s.text.charCodeAt(t.ch+(n>0?0:-1));if(isNaN(c))a=null;else{var f=n>0?c>=55296&&c<56320:c>=56320&&c<57343;a=new ot(t.line,Math.max(0,Math.min(s.text.length,t.ch+n*(f?2:1))),-n)}}else a=i?Za(e.cm,s,t,n):Ya(s,t,n);if(null==a){if(o||!u())return!1;t=Ga(i,e.cm,s,t.line,l)}else t=a;return!0}if("char"==r||"codepoint"==r)c();else if("column"==r)c(!0);else if("word"==r||"group"==r)for(var f=null,p="group"==r,d=e.cm&&e.cm.getHelper(t,"wordChars"),h=!0;!(n<0)||c(!h);h=!1){var g=s.text.charAt(t.ch)||"\n",m=ne(g,d)?"w":p&&"\n"==g?"n":!p||/\s/.test(g)?null:"p";if(!p||h||m||(m="s"),f&&f!=m){n<0&&(n=1,c(),t.sticky="after");break}if(m&&(f=m),n>0&&!c(!h))break}var v=Yo(e,t,o,a,!0);return st(o,v)&&(v.hitSide=!0),v}function Xs(e,t,n,r){var i,o,a=e.doc,s=t.left;if("page"==r){var l=Math.min(e.display.wrapper.clientHeight,window.innerHeight||document.documentElement.clientHeight),u=Math.max(l-.5*jr(e.display),3);i=(n>0?t.bottom:t.top)+n*u}else"line"==r&&(i=n>0?t.bottom+3:t.top-3);for(;(o=xr(e,s,i)).outside;){if(n<0?i<=0:i>=a.height){o.hitSide=!0;break}i+=5*n}return o}var Js=function(e){this.cm=e,this.lastAnchorNode=this.lastAnchorOffset=this.lastFocusNode=this.lastFocusOffset=null,this.polling=new $,this.composing=null,this.gracePeriod=!1,this.readDOMTimeout=null};function Qs(e,t){var n=tr(e,t.line);if(!n||n.hidden)return null;var r=Xe(e.doc,t.line),i=Jn(n,r,t.line),o=pe(r,e.doc.direction),a="left";o&&(a=ce(o,t.ch)%2?"right":"left");var s=ar(i.map,t.ch,a);return s.offset="right"==s.collapse?s.end:s.start,s}function el(e){for(var t=e;t;t=t.parentNode)if(/CodeMirror-gutter-wrapper/.test(t.className))return!0;return!1}function tl(e,t){return t&&(e.bad=!0),e}function nl(e,t,n,r,i){var o="",a=!1,s=e.doc.lineSeparator(),l=!1;function u(e){return function(t){return t.id==e}}function c(){a&&(o+=s,l&&(o+=s),a=l=!1)}function f(e){e&&(c(),o+=e)}function p(t){if(1==t.nodeType){var n=t.getAttribute("cm-text");if(n)return void f(n);var o,d=t.getAttribute("cm-marker");if(d){var h=e.findMarks(ot(r,0),ot(i+1,0),u(+d));return void(h.length&&(o=h[0].find(0))&&f(Je(e.doc,o.from,o.to).join(s)))}if("false"==t.getAttribute("contenteditable"))return;var g=/^(pre|div|p|li|table|br)$/i.test(t.nodeName);if(!/^br$/i.test(t.nodeName)&&0==t.textContent.length)return;g&&c();for(var m=0;m<t.childNodes.length;m++)p(t.childNodes[m]);/^(pre|p)$/i.test(t.nodeName)&&(l=!0),g&&(a=!0)}else 3==t.nodeType&&f(t.nodeValue.replace(/\u200b/g,"").replace(/\u00a0/g," "))}for(;p(t),t!=n;)t=t.nextSibling,l=!1;return o}function rl(e,t,n){var r;if(t==e.display.lineDiv){if(!(r=e.display.lineDiv.childNodes[n]))return tl(e.clipPos(ot(e.display.viewTo-1)),!0);t=null,n=0}else for(r=t;;r=r.parentNode){if(!r||r==e.display.lineDiv)return null;if(r.parentNode&&r.parentNode==e.display.lineDiv)break}for(var i=0;i<e.display.view.length;i++){var o=e.display.view[i];if(o.node==r)return il(o,t,n)}}function il(e,t,n){var r=e.text.firstChild,i=!1;if(!t||!D(r,t))return tl(ot(tt(e.line),0),!0);if(t==r&&(i=!0,t=r.childNodes[n],n=0,!t)){var o=e.rest?G(e.rest):e.line;return tl(ot(tt(o),o.text.length),i)}var a=3==t.nodeType?t:null,s=t;for(a||1!=t.childNodes.length||3!=t.firstChild.nodeType||(a=t.firstChild,n&&(n=a.nodeValue.length));s.parentNode!=r;)s=s.parentNode;var l=e.measure,u=l.maps;function c(t,n,r){for(var i=-1;i<(u?u.length:0);i++)for(var o=i<0?l.map:u[i],a=0;a<o.length;a+=3){var s=o[a+2];if(s==t||s==n){var c=tt(i<0?e.line:e.rest[i]),f=o[a]+r;return(r<0||s!=t)&&(f=o[a+(r?1:0)]),ot(c,f)}}}var f=c(a,s,n);if(f)return tl(f,i);for(var p=s.nextSibling,d=a?a.nodeValue.length-n:0;p;p=p.nextSibling){if(f=c(p,p.firstChild,0))return tl(ot(f.line,f.ch-d),i);d+=p.textContent.length}for(var h=s.previousSibling,g=n;h;h=h.previousSibling){if(f=c(h,h.firstChild,-1))return tl(ot(f.line,f.ch+g),i);g+=h.textContent.length}}Js.prototype.init=function(e){var t=this,n=this,r=n.cm,i=n.div=e.lineDiv;function o(e){for(var t=e.target;t;t=t.parentNode){if(t==i)return!0;if(/\bCodeMirror-(?:line)?widget\b/.test(t.className))break}return!1}function a(e){if(o(e)&&!ye(r,e)){if(r.somethingSelected())Bs({lineWise:!1,text:r.getSelections()}),"cut"==e.type&&r.replaceSelection("",null,"cut");else{if(!r.options.lineWiseCopyCut)return;var t=Vs(r);Bs({lineWise:!0,text:t.text}),"cut"==e.type&&r.operation((function(){r.setSelections(t.ranges,0,W),r.replaceSelection("",null,"cut")}))}if(e.clipboardData){e.clipboardData.clearData();var a=zs.text.join("\n");if(e.clipboardData.setData("Text",a),e.clipboardData.getData("Text")==a)return void e.preventDefault()}var s=Ys(),l=s.firstChild;r.display.lineSpace.insertBefore(s,r.display.lineSpace.firstChild),l.value=zs.text.join("\n");var u=document.activeElement;P(l),setTimeout((function(){r.display.lineSpace.removeChild(s),u.focus(),u==i&&n.showPrimarySelection()}),50)}}i.contentEditable=!0,Ks(i,r.options.spellcheck,r.options.autocorrect,r.options.autocapitalize),he(i,"paste",(function(e){!o(e)||ye(r,e)||Hs(e,r)||s<=11&&setTimeout(Ni(r,(function(){return t.updateFromDOM()})),20)})),he(i,"compositionstart",(function(e){t.composing={data:e.data,done:!1}})),he(i,"compositionupdate",(function(e){t.composing||(t.composing={data:e.data,done:!1})})),he(i,"compositionend",(function(e){t.composing&&(e.data!=t.composing.data&&t.readFromDOMSoon(),t.composing.done=!0)})),he(i,"touchstart",(function(){return n.forceCompositionEnd()})),he(i,"input",(function(){t.composing||t.readFromDOMSoon()})),he(i,"copy",a),he(i,"cut",a)},Js.prototype.screenReaderLabelChanged=function(e){e?this.div.setAttribute("aria-label",e):this.div.removeAttribute("aria-label")},Js.prototype.prepareSelection=function(){var e=Hr(this.cm,!1);return e.focus=document.activeElement==this.div,e},Js.prototype.showSelection=function(e,t){e&&this.cm.display.view.length&&((e.focus||t)&&this.showPrimarySelection(),this.showMultipleSelections(e))},Js.prototype.getSelection=function(){return this.cm.display.wrapper.ownerDocument.getSelection()},Js.prototype.showPrimarySelection=function(){var e=this.getSelection(),t=this.cm,r=t.doc.sel.primary(),i=r.from(),o=r.to();if(t.display.viewTo==t.display.viewFrom||i.line>=t.display.viewTo||o.line<t.display.viewFrom)e.removeAllRanges();else{var a=rl(t,e.anchorNode,e.anchorOffset),s=rl(t,e.focusNode,e.focusOffset);if(!a||a.bad||!s||s.bad||0!=at(ct(a,s),i)||0!=at(ut(a,s),o)){var l=t.display.view,u=i.line>=t.display.viewFrom&&Qs(t,i)||{node:l[0].measure.map[2],offset:0},c=o.line<t.display.viewTo&&Qs(t,o);if(!c){var f=l[l.length-1].measure,p=f.maps?f.maps[f.maps.length-1]:f.map;c={node:p[p.length-1],offset:p[p.length-2]-p[p.length-3]}}if(u&&c){var d,h=e.rangeCount&&e.getRangeAt(0);try{d=E(u.node,u.offset,c.offset,c.node)}catch(Le){}d&&(!n&&t.state.focused?(e.collapse(u.node,u.offset),d.collapsed||(e.removeAllRanges(),e.addRange(d))):(e.removeAllRanges(),e.addRange(d)),h&&null==e.anchorNode?e.addRange(h):n&&this.startGracePeriod()),this.rememberSelection()}else e.removeAllRanges()}}},Js.prototype.startGracePeriod=function(){var e=this;clearTimeout(this.gracePeriod),this.gracePeriod=setTimeout((function(){e.gracePeriod=!1,e.selectionChanged()&&e.cm.operation((function(){return e.cm.curOp.selectionChanged=!0}))}),20)},Js.prototype.showMultipleSelections=function(e){S(this.cm.display.cursorDiv,e.cursors),S(this.cm.display.selectionDiv,e.selection)},Js.prototype.rememberSelection=function(){var e=this.getSelection();this.lastAnchorNode=e.anchorNode,this.lastAnchorOffset=e.anchorOffset,this.lastFocusNode=e.focusNode,this.lastFocusOffset=e.focusOffset},Js.prototype.selectionInEditor=function(){var e=this.getSelection();if(!e.rangeCount)return!1;var t=e.getRangeAt(0).commonAncestorContainer;return D(this.div,t)},Js.prototype.focus=function(){"nocursor"!=this.cm.options.readOnly&&(this.selectionInEditor()&&document.activeElement==this.div||this.showSelection(this.prepareSelection(),!0),this.div.focus())},Js.prototype.blur=function(){this.div.blur()},Js.prototype.getField=function(){return this.div},Js.prototype.supportsTouch=function(){return!0},Js.prototype.receivedFocus=function(){var e=this;function t(){e.cm.state.focused&&(e.pollSelection(),e.polling.set(e.cm.options.pollInterval,t))}this.selectionInEditor()?this.pollSelection():Di(this.cm,(function(){return e.cm.curOp.selectionChanged=!0})),this.polling.set(this.cm.options.pollInterval,t)},Js.prototype.selectionChanged=function(){var e=this.getSelection();return e.anchorNode!=this.lastAnchorNode||e.anchorOffset!=this.lastAnchorOffset||e.focusNode!=this.lastFocusNode||e.focusOffset!=this.lastFocusOffset},Js.prototype.pollSelection=function(){if(null==this.readDOMTimeout&&!this.gracePeriod&&this.selectionChanged()){var e=this.getSelection(),t=this.cm;if(m&&c&&this.cm.display.gutterSpecs.length&&el(e.anchorNode))return this.cm.triggerOnKeyDown({type:"keydown",keyCode:8,preventDefault:Math.abs}),this.blur(),void this.focus();if(!this.composing){this.rememberSelection();var n=rl(t,e.anchorNode,e.anchorOffset),r=rl(t,e.focusNode,e.focusOffset);n&&r&&Di(t,(function(){Bo(t.doc,so(n,r),W),(n.bad||r.bad)&&(t.curOp.selectionChanged=!0)}))}}},Js.prototype.pollContent=function(){null!=this.readDOMTimeout&&(clearTimeout(this.readDOMTimeout),this.readDOMTimeout=null);var e,t,n,r=this.cm,i=r.display,o=r.doc.sel.primary(),a=o.from(),s=o.to();if(0==a.ch&&a.line>r.firstLine()&&(a=ot(a.line-1,Xe(r.doc,a.line-1).length)),s.ch==Xe(r.doc,s.line).text.length&&s.line<r.lastLine()&&(s=ot(s.line+1,0)),a.line<i.viewFrom||s.line>i.viewTo-1)return!1;a.line==i.viewFrom||0==(e=Fr(r,a.line))?(t=tt(i.view[0].line),n=i.view[0].node):(t=tt(i.view[e].line),n=i.view[e-1].node.nextSibling);var l,u,c=Fr(r,s.line);if(c==i.view.length-1?(l=i.viewTo-1,u=i.lineDiv.lastChild):(l=tt(i.view[c+1].line)-1,u=i.view[c+1].node.previousSibling),!n)return!1;for(var f=r.doc.splitLines(nl(r,n,u,t,l)),p=Je(r.doc,ot(t,0),ot(l,Xe(r.doc,l).text.length));f.length>1&&p.length>1;)if(G(f)==G(p))f.pop(),p.pop(),l--;else{if(f[0]!=p[0])break;f.shift(),p.shift(),t++}for(var d=0,h=0,g=f[0],m=p[0],v=Math.min(g.length,m.length);d<v&&g.charCodeAt(d)==m.charCodeAt(d);)++d;for(var y=G(f),b=G(p),_=Math.min(y.length-(1==f.length?d:0),b.length-(1==p.length?d:0));h<_&&y.charCodeAt(y.length-h-1)==b.charCodeAt(b.length-h-1);)++h;if(1==f.length&&1==p.length&&t==a.line)for(;d&&d>a.ch&&y.charCodeAt(y.length-h-1)==b.charCodeAt(b.length-h-1);)d--,h++;f[f.length-1]=y.slice(0,y.length-h).replace(/^\u200b+/,""),f[0]=f[0].slice(d).replace(/\u200b+$/,"");var w=ot(t,d),x=ot(l,p.length?G(p).length-h:0);return f.length>1||f[0]||at(w,x)?(ia(r.doc,f,w,x,"+input"),!0):void 0},Js.prototype.ensurePolled=function(){this.forceCompositionEnd()},Js.prototype.reset=function(){this.forceCompositionEnd()},Js.prototype.forceCompositionEnd=function(){this.composing&&(clearTimeout(this.readDOMTimeout),this.composing=null,this.updateFromDOM(),this.div.blur(),this.div.focus())},Js.prototype.readFromDOMSoon=function(){var e=this;null==this.readDOMTimeout&&(this.readDOMTimeout=setTimeout((function(){if(e.readDOMTimeout=null,e.composing){if(!e.composing.done)return;e.composing=null}e.updateFromDOM()}),80))},Js.prototype.updateFromDOM=function(){var e=this;!this.cm.isReadOnly()&&this.pollContent()||Di(this.cm,(function(){return qr(e.cm)}))},Js.prototype.setUneditable=function(e){e.contentEditable="false"},Js.prototype.onKeyPress=function(e){0==e.charCode||this.composing||(e.preventDefault(),this.cm.isReadOnly()||Ni(this.cm,Ws)(this.cm,String.fromCharCode(null==e.charCode?e.keyCode:e.charCode),0))},Js.prototype.readOnlyChanged=function(e){this.div.contentEditable=String("nocursor"!=e)},Js.prototype.onContextMenu=function(){},Js.prototype.resetPosition=function(){},Js.prototype.needsContentAttribute=!0;var ol=function(e){this.cm=e,this.prevInput="",this.pollingFast=!1,this.polling=new $,this.hasSelection=!1,this.composing=null};function al(e,t){if((t=t?q(t):{}).value=e.value,!t.tabindex&&e.tabIndex&&(t.tabindex=e.tabIndex),!t.placeholder&&e.placeholder&&(t.placeholder=e.placeholder),null==t.autofocus){var n=N();t.autofocus=n==e||null!=e.getAttribute("autofocus")&&n==document.body}function r(){e.value=s.getValue()}var i;if(e.form&&(he(e.form,"submit",r),!t.leaveSubmitMethodAlone)){var o=e.form;i=o.submit;try{var a=o.submit=function(){r(),o.submit=i,o.submit(),o.submit=a}}catch(Le){}}t.finishInit=function(n){n.save=r,n.getTextArea=function(){return e},n.toTextArea=function(){n.toTextArea=isNaN,r(),e.parentNode.removeChild(n.getWrapperElement()),e.style.display="",e.form&&(me(e.form,"submit",r),t.leaveSubmitMethodAlone||"function"!=typeof e.form.submit||(e.form.submit=i))}},e.style.display="none";var s=qs((function(t){return e.parentNode.insertBefore(t,e.nextSibling)}),t);return s}function sl(e){e.off=me,e.on=he,e.wheelEventPixels=no,e.Doc=ka,e.splitLines=Me,e.countColumn=I,e.findColumn=V,e.isWordChar=te,e.Pass=B,e.signal=ve,e.Line=un,e.changeEnd=lo,e.scrollbarModel=_i,e.Pos=ot,e.cmpPos=at,e.modes=$e,e.mimeModes=Re,e.resolveMode=We,e.getMode=He,e.modeExtensions=Ue,e.extendMode=Ve,e.copyState=Ke,e.startState=Ge,e.innerMode=Ye,e.commands=Xa,e.keyMap=Ia,e.keyName=Ha,e.isModifierKey=Ba,e.lookupKey=za,e.normalizeKeyMap=Ra,e.StringStream=Ze,e.SharedTextMarker=va,e.TextMarker=ga,e.LineWidget=fa,e.e_preventDefault=xe,e.e_stopPropagation=ke,e.e_stop=Ee,e.addClass=L,e.contains=D,e.rmClass=O,e.keyNames=Ma}ol.prototype.init=function(e){var t=this,n=this,r=this.cm;this.createField(e);var i=this.textarea;function o(e){if(!ye(r,e)){if(r.somethingSelected())Bs({lineWise:!1,text:r.getSelections()});else{if(!r.options.lineWiseCopyCut)return;var t=Vs(r);Bs({lineWise:!0,text:t.text}),"cut"==e.type?r.setSelections(t.ranges,null,W):(n.prevInput="",i.value=t.text.join("\n"),P(i))}"cut"==e.type&&(r.state.cutIncoming=+new Date)}}e.wrapper.insertBefore(this.wrapper,e.wrapper.firstChild),g&&(i.style.width="0px"),he(i,"input",(function(){a&&s>=9&&t.hasSelection&&(t.hasSelection=null),n.poll()})),he(i,"paste",(function(e){ye(r,e)||Hs(e,r)||(r.state.pasteIncoming=+new Date,n.fastPoll())})),he(i,"cut",o),he(i,"copy",o),he(e.scroller,"paste",(function(t){if(!Hn(e,t)&&!ye(r,t)){if(!i.dispatchEvent)return r.state.pasteIncoming=+new Date,void n.focus();var o=new Event("paste");o.clipboardData=t.clipboardData,i.dispatchEvent(o)}})),he(e.lineSpace,"selectstart",(function(t){Hn(e,t)||xe(t)})),he(i,"compositionstart",(function(){var e=r.getCursor("from");n.composing&&n.composing.range.clear(),n.composing={start:e,range:r.markText(e,r.getCursor("to"),{className:"CodeMirror-composing"})}})),he(i,"compositionend",(function(){n.composing&&(n.poll(),n.composing.range.clear(),n.composing=null)}))},ol.prototype.createField=function(e){this.wrapper=Ys(),this.textarea=this.wrapper.firstChild},ol.prototype.screenReaderLabelChanged=function(e){e?this.textarea.setAttribute("aria-label",e):this.textarea.removeAttribute("aria-label")},ol.prototype.prepareSelection=function(){var e=this.cm,t=e.display,n=e.doc,r=Hr(e);if(e.options.moveInputWithCursor){var i=br(e,n.sel.primary().head,"div"),o=t.wrapper.getBoundingClientRect(),a=t.lineDiv.getBoundingClientRect();r.teTop=Math.max(0,Math.min(t.wrapper.clientHeight-10,i.top+a.top-o.top)),r.teLeft=Math.max(0,Math.min(t.wrapper.clientWidth-10,i.left+a.left-o.left))}return r},ol.prototype.showSelection=function(e){var t=this.cm.display;S(t.cursorDiv,e.cursors),S(t.selectionDiv,e.selection),null!=e.teTop&&(this.wrapper.style.top=e.teTop+"px",this.wrapper.style.left=e.teLeft+"px")},ol.prototype.reset=function(e){if(!this.contextMenuPending&&!this.composing){var t=this.cm;if(t.somethingSelected()){this.prevInput="";var n=t.getSelection();this.textarea.value=n,t.state.focused&&P(this.textarea),a&&s>=9&&(this.hasSelection=n)}else e||(this.prevInput=this.textarea.value="",a&&s>=9&&(this.hasSelection=null))}},ol.prototype.getField=function(){return this.textarea},ol.prototype.supportsTouch=function(){return!1},ol.prototype.focus=function(){if("nocursor"!=this.cm.options.readOnly&&(!v||N()!=this.textarea))try{this.textarea.focus()}catch(Le){}},ol.prototype.blur=function(){this.textarea.blur()},ol.prototype.resetPosition=function(){this.wrapper.style.top=this.wrapper.style.left=0},ol.prototype.receivedFocus=function(){this.slowPoll()},ol.prototype.slowPoll=function(){var e=this;this.pollingFast||this.polling.set(this.cm.options.pollInterval,(function(){e.poll(),e.cm.state.focused&&e.slowPoll()}))},ol.prototype.fastPoll=function(){var e=!1,t=this;function n(){t.poll()||e?(t.pollingFast=!1,t.slowPoll()):(e=!0,t.polling.set(60,n))}t.pollingFast=!0,t.polling.set(20,n)},ol.prototype.poll=function(){var e=this,t=this.cm,n=this.textarea,r=this.prevInput;if(this.contextMenuPending||!t.state.focused||Pe(n)&&!r&&!this.composing||t.isReadOnly()||t.options.disableInput||t.state.keySeq)return!1;var i=n.value;if(i==r&&!t.somethingSelected())return!1;if(a&&s>=9&&this.hasSelection===i||y&&/[\uf700-\uf7ff]/.test(i))return t.display.input.reset(),!1;if(t.doc.sel==t.display.selForContextMenu){var o=i.charCodeAt(0);if(8203!=o||r||(r=""),8666==o)return this.reset(),this.cm.execCommand("undo")}for(var l=0,u=Math.min(r.length,i.length);l<u&&r.charCodeAt(l)==i.charCodeAt(l);)++l;return Di(t,(function(){Ws(t,i.slice(l),r.length-l,null,e.composing?"*compose":null),i.length>1e3||i.indexOf("\n")>-1?n.value=e.prevInput="":e.prevInput=i,e.composing&&(e.composing.range.clear(),e.composing.range=t.markText(e.composing.start,t.getCursor("to"),{className:"CodeMirror-composing"}))})),!0},ol.prototype.ensurePolled=function(){this.pollingFast&&this.poll()&&(this.pollingFast=!1)},ol.prototype.onKeyPress=function(){a&&s>=9&&(this.hasSelection=null),this.fastPoll()},ol.prototype.onContextMenu=function(e){var t=this,n=t.cm,r=n.display,i=t.textarea;t.contextMenuPending&&t.contextMenuPending();var o=Pr(n,e),u=r.scroller.scrollTop;if(o&&!f){n.options.resetSelectionOnContextMenu&&-1==n.doc.sel.contains(o)&&Ni(n,Bo)(n.doc,so(o),W);var c,p=i.style.cssText,d=t.wrapper.style.cssText,h=t.wrapper.offsetParent.getBoundingClientRect();if(t.wrapper.style.cssText="position: static",i.style.cssText="position: absolute; width: 30px; height: 30px;\n top: "+(e.clientY-h.top-5)+"px; left: "+(e.clientX-h.left-5)+"px;\n z-index: 1000; background: "+(a?"rgba(255, 255, 255, .05)":"transparent")+";\n outline: none; border-width: 0; outline: none; overflow: hidden; opacity: .05; filter: alpha(opacity=5);",l&&(c=window.scrollY),r.input.focus(),l&&window.scrollTo(null,c),r.input.reset(),n.somethingSelected()||(i.value=t.prevInput=" "),t.contextMenuPending=v,r.selForContextMenu=n.doc.sel,clearTimeout(r.detectingSelectAll),a&&s>=9&&m(),k){Ee(e);var g=function(){me(window,"mouseup",g),setTimeout(v,20)};he(window,"mouseup",g)}else setTimeout(v,50)}function m(){if(null!=i.selectionStart){var e=n.somethingSelected(),o=""+(e?i.value:"");i.value="⇚",i.value=o,t.prevInput=e?"":"",i.selectionStart=1,i.selectionEnd=o.length,r.selForContextMenu=n.doc.sel}}function v(){if(t.contextMenuPending==v&&(t.contextMenuPending=!1,t.wrapper.style.cssText=d,i.style.cssText=p,a&&s<9&&r.scrollbars.setScrollTop(r.scroller.scrollTop=u),null!=i.selectionStart)){(!a||a&&s<9)&&m();var e=0,o=function(){r.selForContextMenu==n.doc.sel&&0==i.selectionStart&&i.selectionEnd>0&&""==t.prevInput?Ni(n,Zo)(n):e++<10?r.detectingSelectAll=setTimeout(o,500):(r.selForContextMenu=null,r.input.reset())};r.detectingSelectAll=setTimeout(o,200)}}},ol.prototype.readOnlyChanged=function(e){e||this.reset(),this.textarea.disabled="nocursor"==e,this.textarea.readOnly=!!e},ol.prototype.setUneditable=function(){},ol.prototype.needsContentAttribute=!1,Ms(qs),Gs(qs);var ll="iter insert remove copy getEditor constructor".split(" ");for(var ul in ka.prototype)ka.prototype.hasOwnProperty(ul)&&R(ll,ul)<0&&(qs.prototype[ul]=function(e){return function(){return e.apply(this.doc,arguments)}}(ka.prototype[ul]));return we(ka),qs.inputStyles={textarea:ol,contenteditable:Js},qs.defineMode=function(e){qs.defaults.mode||"null"==e||(qs.defaults.mode=e),ze.apply(this,arguments)},qs.defineMIME=Be,qs.defineMode("null",(function(){return{token:function(e){return e.skipToEnd()}}})),qs.defineMIME("text/plain","null"),qs.defineExtension=function(e,t){qs.prototype[e]=t},qs.defineDocExtension=function(e,t){ka.prototype[e]=t},qs.fromTextArea=al,sl(qs),qs.version="5.60.0",qs}()}));Un((function(e,t){!function(e){function t(e){for(var t;null!=(t=e.next());)if("`"==t&&!e.eat("`"))return"variable-2";return e.backUp(e.current().length-1),e.eatWhile(/\w/)?"variable-2":null}function n(e){for(var t;null!=(t=e.next());)if('"'==t&&!e.eat('"'))return"variable-2";return e.backUp(e.current().length-1),e.eatWhile(/\w/)?"variable-2":null}function r(e){return e.eat("@")&&(e.match("session."),e.match("local."),e.match("global.")),e.eat("'")?(e.match(/^.*'/),"variable-2"):e.eat('"')?(e.match(/^.*"/),"variable-2"):e.eat("`")?(e.match(/^.*`/),"variable-2"):e.match(/^[0-9a-zA-Z$\.\_]+/)?"variable-2":null}function i(e){return e.eat("N")?"atom":e.match(/^[a-zA-Z.#!?]/)?"variable-2":null}e.defineMode("sql",(function(t,n){var r=n.client||{},i=n.atoms||{false:!0,true:!0,null:!0},l=n.builtin||a(s),u=n.keywords||a(o),c=n.operatorChars||/^[*+\-%<>!=&|~^\/]/,f=n.support||{},p=n.hooks||{},d=n.dateSQL||{date:!0,time:!0,timestamp:!0},h=!1!==n.backslashStringEscapes,g=n.brackets||/^[\{}\(\)\[\]]/,m=n.punctuation||/^[;.,:]/;function v(e,t){var n=e.next();if(p[n]){var o=p[n](e,t);if(!1!==o)return o}if(f.hexNumber&&("0"==n&&e.match(/^[xX][0-9a-fA-F]+/)||("x"==n||"X"==n)&&e.match(/^'[0-9a-fA-F]+'/)))return"number";if(f.binaryNumber&&(("b"==n||"B"==n)&&e.match(/^'[01]+'/)||"0"==n&&e.match(/^b[01]+/)))return"number";if(n.charCodeAt(0)>47&&n.charCodeAt(0)<58)return e.match(/^[0-9]*(\.[0-9]+)?([eE][-+]?[0-9]+)?/),f.decimallessFloat&&e.match(/^\.(?!\.)/),"number";if("?"==n&&(e.eatSpace()||e.eol()||e.eat(";")))return"variable-3";if("'"==n||'"'==n&&f.doubleQuote)return t.tokenize=y(n),t.tokenize(e,t);if((f.nCharCast&&("n"==n||"N"==n)||f.charsetCast&&"_"==n&&e.match(/[a-z][a-z0-9]*/i))&&("'"==e.peek()||'"'==e.peek()))return"keyword";if(f.escapeConstant&&("e"==n||"E"==n)&&("'"==e.peek()||'"'==e.peek()&&f.doubleQuote))return t.tokenize=function(e,t){return(t.tokenize=y(e.next(),!0))(e,t)},"keyword";if(f.commentSlashSlash&&"/"==n&&e.eat("/"))return e.skipToEnd(),"comment";if(f.commentHash&&"#"==n||"-"==n&&e.eat("-")&&(!f.commentSpaceRequired||e.eat(" ")))return e.skipToEnd(),"comment";if("/"==n&&e.eat("*"))return t.tokenize=b(1),t.tokenize(e,t);if("."!=n){if(c.test(n))return e.eatWhile(c),"operator";if(g.test(n))return"bracket";if(m.test(n))return e.eatWhile(m),"punctuation";if("{"==n&&(e.match(/^( )*(d|D|t|T|ts|TS)( )*'[^']*'( )*}/)||e.match(/^( )*(d|D|t|T|ts|TS)( )*"[^"]*"( )*}/)))return"number";e.eatWhile(/^[_\w\d]/);var a=e.current().toLowerCase();return d.hasOwnProperty(a)&&(e.match(/^( )+'[^']*'/)||e.match(/^( )+"[^"]*"/))?"number":i.hasOwnProperty(a)?"atom":l.hasOwnProperty(a)?"builtin":u.hasOwnProperty(a)?"keyword":r.hasOwnProperty(a)?"string-2":null}return f.zerolessFloat&&e.match(/^(?:\d+(?:e[+-]?\d+)?)/i)?"number":e.match(/^\.+/)?null:f.ODBCdotTable&&e.match(/^[\w\d_$#]+/)?"variable-2":void 0}function y(e,t){return function(n,r){for(var i,o=!1;null!=(i=n.next());){if(i==e&&!o){r.tokenize=v;break}o=(h||t)&&!o&&"\\"==i}return"string"}}function b(e){return function(t,n){var r=t.match(/^.*?(\/\*|\*\/)/);return r?"/*"==r[1]?n.tokenize=b(e+1):n.tokenize=e>1?b(e-1):v:t.skipToEnd(),"comment"}}function _(e,t,n){t.context={prev:t.context,indent:e.indentation(),col:e.column(),type:n}}function w(e){e.indent=e.context.indent,e.context=e.context.prev}return{startState:function(){return{tokenize:v,context:null}},token:function(e,t){if(e.sol()&&t.context&&null==t.context.align&&(t.context.align=!1),t.tokenize==v&&e.eatSpace())return null;var n=t.tokenize(e,t);if("comment"==n)return n;t.context&&null==t.context.align&&(t.context.align=!0);var r=e.current();return"("==r?_(e,t,")"):"["==r?_(e,t,"]"):t.context&&t.context.type==r&&w(t),n},indent:function(n,r){var i=n.context;if(!i)return e.Pass;var o=r.charAt(0)==i.type;return i.align?i.col+(o?0:1):i.indent+(o?0:t.indentUnit)},blockCommentStart:"/*",blockCommentEnd:"*/",lineComment:f.commentSlashSlash?"//":f.commentHash?"#":"--",closeBrackets:"()[]{}''\"\"``"}}));var o="alter and as asc between by count create delete desc distinct drop from group having in insert into is join like not on or order select set table union update values where limit ";function a(e){for(var t={},n=e.split(" "),r=0;r<n.length;++r)t[n[r]]=!0;return t}var s="bool boolean bit blob enum long longblob longtext medium mediumblob mediumint mediumtext time timestamp tinyblob tinyint tinytext text bigint int int1 int2 int3 int4 int8 integer float float4 float8 double char varbinary varchar varcharacter precision real date datetime year unsigned signed decimal numeric";e.defineMIME("text/x-sql",{name:"sql",keywords:a(o+"begin"),builtin:a(s),atoms:a("false true null unknown"),dateSQL:a("date time timestamp"),support:a("ODBCdotTable doubleQuote binaryNumber hexNumber")}),e.defineMIME("text/x-mssql",{name:"sql",client:a("$partition binary_checksum checksum connectionproperty context_info current_request_id error_line error_message error_number error_procedure error_severity error_state formatmessage get_filestream_transaction_context getansinull host_id host_name isnull isnumeric min_active_rowversion newid newsequentialid rowcount_big xact_state object_id"),keywords:a(o+"begin trigger proc view index for add constraint key primary foreign collate clustered nonclustered declare exec go if use index holdlock nolock nowait paglock readcommitted readcommittedlock readpast readuncommitted repeatableread rowlock serializable snapshot tablock tablockx updlock with"),builtin:a("bigint numeric bit smallint decimal smallmoney int tinyint money float real char varchar text nchar nvarchar ntext binary varbinary image cursor timestamp hierarchyid uniqueidentifier sql_variant xml table "),atoms:a("is not null like and or in left right between inner outer join all any some cross unpivot pivot exists"),operatorChars:/^[*+\-%<>!=^\&|\/]/,brackets:/^[\{}\(\)]/,punctuation:/^[;.,:/]/,backslashStringEscapes:!1,dateSQL:a("date datetimeoffset datetime2 smalldatetime datetime time"),hooks:{"@":r}}),e.defineMIME("text/x-mysql",{name:"sql",client:a("charset clear connect edit ego exit go help nopager notee nowarning pager print prompt quit rehash source status system tee"),keywords:a(o+"accessible action add after algorithm all analyze asensitive at authors auto_increment autocommit avg avg_row_length before binary binlog both btree cache call cascade cascaded case catalog_name chain change changed character check checkpoint checksum class_origin client_statistics close coalesce code collate collation collations column columns comment commit committed completion concurrent condition connection consistent constraint contains continue contributors convert cross current current_date current_time current_timestamp current_user cursor data database databases day_hour day_microsecond day_minute day_second deallocate dec declare default delay_key_write delayed delimiter des_key_file describe deterministic dev_pop dev_samp deviance diagnostics directory disable discard distinctrow div dual dumpfile each elseif enable enclosed end ends engine engines enum errors escape escaped even event events every execute exists exit explain extended fast fetch field fields first flush for force foreign found_rows full fulltext function general get global grant grants group group_concat handler hash help high_priority hosts hour_microsecond hour_minute hour_second if ignore ignore_server_ids import index index_statistics infile inner innodb inout insensitive insert_method install interval invoker isolation iterate key keys kill language last leading leave left level limit linear lines list load local localtime localtimestamp lock logs low_priority master master_heartbeat_period master_ssl_verify_server_cert masters match max max_rows maxvalue message_text middleint migrate min min_rows minute_microsecond minute_second mod mode modifies modify mutex mysql_errno natural next no no_write_to_binlog offline offset one online open optimize option optionally out outer outfile pack_keys parser partition partitions password phase plugin plugins prepare preserve prev primary privileges procedure processlist profile profiles purge query quick range read read_write reads real rebuild recover references regexp relaylog release remove rename reorganize repair repeatable replace require resignal restrict resume return returns revoke right rlike rollback rollup row row_format rtree savepoint schedule schema schema_name schemas second_microsecond security sensitive separator serializable server session share show signal slave slow smallint snapshot soname spatial specific sql sql_big_result sql_buffer_result sql_cache sql_calc_found_rows sql_no_cache sql_small_result sqlexception sqlstate sqlwarning ssl start starting starts status std stddev stddev_pop stddev_samp storage straight_join subclass_origin sum suspend table_name table_statistics tables tablespace temporary terminated to trailing transaction trigger triggers truncate uncommitted undo uninstall unique unlock upgrade usage use use_frm user user_resources user_statistics using utc_date utc_time utc_timestamp value variables varying view views warnings when while with work write xa xor year_month zerofill begin do then else loop repeat"),builtin:a("bool boolean bit blob decimal double float long longblob longtext medium mediumblob mediumint mediumtext time timestamp tinyblob tinyint tinytext text bigint int int1 int2 int3 int4 int8 integer float float4 float8 double char varbinary varchar varcharacter precision date datetime year unsigned signed numeric"),atoms:a("false true null unknown"),operatorChars:/^[*+\-%<>!=&|^]/,dateSQL:a("date time timestamp"),support:a("ODBCdotTable decimallessFloat zerolessFloat binaryNumber hexNumber doubleQuote nCharCast charsetCast commentHash commentSpaceRequired"),hooks:{"@":r,"`":t,"\\":i}}),e.defineMIME("text/x-mariadb",{name:"sql",client:a("charset clear connect edit ego exit go help nopager notee nowarning pager print prompt quit rehash source status system tee"),keywords:a(o+"accessible action add after algorithm all always analyze asensitive at authors auto_increment autocommit avg avg_row_length before binary binlog both btree cache call cascade cascaded case catalog_name chain change changed character check checkpoint checksum class_origin client_statistics close coalesce code collate collation collations column columns comment commit committed completion concurrent condition connection consistent constraint contains continue contributors convert cross current current_date current_time current_timestamp current_user cursor data database databases day_hour day_microsecond day_minute day_second deallocate dec declare default delay_key_write delayed delimiter des_key_file describe deterministic dev_pop dev_samp deviance diagnostics directory disable discard distinctrow div dual dumpfile each elseif enable enclosed end ends engine engines enum errors escape escaped even event events every execute exists exit explain extended fast fetch field fields first flush for force foreign found_rows full fulltext function general generated get global grant grants group groupby_concat handler hard hash help high_priority hosts hour_microsecond hour_minute hour_second if ignore ignore_server_ids import index index_statistics infile inner innodb inout insensitive insert_method install interval invoker isolation iterate key keys kill language last leading leave left level limit linear lines list load local localtime localtimestamp lock logs low_priority master master_heartbeat_period master_ssl_verify_server_cert masters match max max_rows maxvalue message_text middleint migrate min min_rows minute_microsecond minute_second mod mode modifies modify mutex mysql_errno natural next no no_write_to_binlog offline offset one online open optimize option optionally out outer outfile pack_keys parser partition partitions password persistent phase plugin plugins prepare preserve prev primary privileges procedure processlist profile profiles purge query quick range read read_write reads real rebuild recover references regexp relaylog release remove rename reorganize repair repeatable replace require resignal restrict resume return returns revoke right rlike rollback rollup row row_format rtree savepoint schedule schema schema_name schemas second_microsecond security sensitive separator serializable server session share show shutdown signal slave slow smallint snapshot soft soname spatial specific sql sql_big_result sql_buffer_result sql_cache sql_calc_found_rows sql_no_cache sql_small_result sqlexception sqlstate sqlwarning ssl start starting starts status std stddev stddev_pop stddev_samp storage straight_join subclass_origin sum suspend table_name table_statistics tables tablespace temporary terminated to trailing transaction trigger triggers truncate uncommitted undo uninstall unique unlock upgrade usage use use_frm user user_resources user_statistics using utc_date utc_time utc_timestamp value variables varying view views virtual warnings when while with work write xa xor year_month zerofill begin do then else loop repeat"),builtin:a("bool boolean bit blob decimal double float long longblob longtext medium mediumblob mediumint mediumtext time timestamp tinyblob tinyint tinytext text bigint int int1 int2 int3 int4 int8 integer float float4 float8 double char varbinary varchar varcharacter precision date datetime year unsigned signed numeric"),atoms:a("false true null unknown"),operatorChars:/^[*+\-%<>!=&|^]/,dateSQL:a("date time timestamp"),support:a("ODBCdotTable decimallessFloat zerolessFloat binaryNumber hexNumber doubleQuote nCharCast charsetCast commentHash commentSpaceRequired"),hooks:{"@":r,"`":t,"\\":i}}),e.defineMIME("text/x-sqlite",{name:"sql",client:a("auth backup bail binary changes check clone databases dbinfo dump echo eqp exit explain fullschema headers help import imposter indexes iotrace limit lint load log mode nullvalue once open output print prompt quit read restore save scanstats schema separator session shell show stats system tables testcase timeout timer trace vfsinfo vfslist vfsname width"),keywords:a(o+"abort action add after all analyze attach autoincrement before begin cascade case cast check collate column commit conflict constraint cross current_date current_time current_timestamp database default deferrable deferred detach each else end escape except exclusive exists explain fail for foreign full glob if ignore immediate index indexed initially inner instead intersect isnull key left limit match natural no notnull null of offset outer plan pragma primary query raise recursive references regexp reindex release rename replace restrict right rollback row savepoint temp temporary then to transaction trigger unique using vacuum view virtual when with without"),builtin:a("bool boolean bit blob decimal double float long longblob longtext medium mediumblob mediumint mediumtext time timestamp tinyblob tinyint tinytext text clob bigint int int2 int8 integer float double char varchar date datetime year unsigned signed numeric real"),atoms:a("null current_date current_time current_timestamp"),operatorChars:/^[*+\-%<>!=&|/~]/,dateSQL:a("date time timestamp datetime"),support:a("decimallessFloat zerolessFloat"),identifierQuote:'"',hooks:{"@":r,":":r,"?":r,$:r,'"':n,"`":t}}),e.defineMIME("text/x-cassandra",{name:"sql",client:{},keywords:a("add all allow alter and any apply as asc authorize batch begin by clustering columnfamily compact consistency count create custom delete desc distinct drop each_quorum exists filtering from grant if in index insert into key keyspace keyspaces level limit local_one local_quorum modify nan norecursive nosuperuser not of on one order password permission permissions primary quorum rename revoke schema select set storage superuser table three to token truncate ttl two type unlogged update use user users using values where with writetime"),builtin:a("ascii bigint blob boolean counter decimal double float frozen inet int list map static text timestamp timeuuid tuple uuid varchar varint"),atoms:a("false true infinity NaN"),operatorChars:/^[<>=]/,dateSQL:{},support:a("commentSlashSlash decimallessFloat"),hooks:{}}),e.defineMIME("text/x-plsql",{name:"sql",client:a("appinfo arraysize autocommit autoprint autorecovery autotrace blockterminator break btitle cmdsep colsep compatibility compute concat copycommit copytypecheck define describe echo editfile embedded escape exec execute feedback flagger flush heading headsep instance linesize lno loboffset logsource long longchunksize markup native newpage numformat numwidth pagesize pause pno recsep recsepchar release repfooter repheader serveroutput shiftinout show showmode size spool sqlblanklines sqlcase sqlcode sqlcontinue sqlnumber sqlpluscompatibility sqlprefix sqlprompt sqlterminator suffix tab term termout time timing trimout trimspool ttitle underline verify version wrap"),keywords:a("abort accept access add all alter and any array arraylen as asc assert assign at attributes audit authorization avg base_table begin between binary_integer body boolean by case cast char char_base check close cluster clusters colauth column comment commit compress connect connected constant constraint crash create current currval cursor data_base database date dba deallocate debugoff debugon decimal declare default definition delay delete desc digits dispose distinct do drop else elseif elsif enable end entry escape exception exception_init exchange exclusive exists exit external fast fetch file for force form from function generic goto grant group having identified if immediate in increment index indexes indicator initial initrans insert interface intersect into is key level library like limited local lock log logging long loop master maxextents maxtrans member minextents minus mislabel mode modify multiset new next no noaudit nocompress nologging noparallel not nowait number_base object of off offline on online only open option or order out package parallel partition pctfree pctincrease pctused pls_integer positive positiven pragma primary prior private privileges procedure public raise range raw read rebuild record ref references refresh release rename replace resource restrict return returning returns reverse revoke rollback row rowid rowlabel rownum rows run savepoint schema segment select separate session set share snapshot some space split sql start statement storage subtype successful synonym tabauth table tables tablespace task terminate then to trigger truncate type union unique unlimited unrecoverable unusable update use using validate value values variable view views when whenever where while with work"),builtin:a("abs acos add_months ascii asin atan atan2 average bfile bfilename bigserial bit blob ceil character chartorowid chr clob concat convert cos cosh count dec decode deref dual dump dup_val_on_index empty error exp false float floor found glb greatest hextoraw initcap instr instrb int integer isopen last_day least length lengthb ln lower lpad ltrim lub make_ref max min mlslabel mod months_between natural naturaln nchar nclob new_time next_day nextval nls_charset_decl_len nls_charset_id nls_charset_name nls_initcap nls_lower nls_sort nls_upper nlssort no_data_found notfound null number numeric nvarchar2 nvl others power rawtohex real reftohex round rowcount rowidtochar rowtype rpad rtrim serial sign signtype sin sinh smallint soundex sqlcode sqlerrm sqrt stddev string substr substrb sum sysdate tan tanh to_char text to_date to_label to_multi_byte to_number to_single_byte translate true trunc uid unlogged upper user userenv varchar varchar2 variance varying vsize xml"),operatorChars:/^[*\/+\-%<>!=~]/,dateSQL:a("date time timestamp"),support:a("doubleQuote nCharCast zerolessFloat binaryNumber hexNumber")}),e.defineMIME("text/x-hive",{name:"sql",keywords:a("select alter $elem$ $key$ $value$ add after all analyze and archive as asc before between binary both bucket buckets by cascade case cast change cluster clustered clusterstatus collection column columns comment compute concatenate continue create cross cursor data database databases dbproperties deferred delete delimited desc describe directory disable distinct distribute drop else enable end escaped exclusive exists explain export extended external fetch fields fileformat first format formatted from full function functions grant group having hold_ddltime idxproperties if import in index indexes inpath inputdriver inputformat insert intersect into is items join keys lateral left like limit lines load local location lock locks mapjoin materialized minus msck no_drop nocompress not of offline on option or order out outer outputdriver outputformat overwrite partition partitioned partitions percent plus preserve procedure purge range rcfile read readonly reads rebuild recordreader recordwriter recover reduce regexp rename repair replace restrict revoke right rlike row schema schemas semi sequencefile serde serdeproperties set shared show show_database sort sorted ssl statistics stored streamtable table tables tablesample tblproperties temporary terminated textfile then tmp to touch transform trigger unarchive undo union uniquejoin unlock update use using utc utc_tmestamp view when where while with admin authorization char compact compactions conf cube current current_date current_timestamp day decimal defined dependency directories elem_type exchange file following for grouping hour ignore inner interval jar less logical macro minute month more none noscan over owner partialscan preceding pretty principals protection reload rewrite role roles rollup rows second server sets skewed transactions truncate unbounded unset uri user values window year"),builtin:a("bool boolean long timestamp tinyint smallint bigint int float double date datetime unsigned string array struct map uniontype key_type utctimestamp value_type varchar"),atoms:a("false true null unknown"),operatorChars:/^[*+\-%<>!=]/,dateSQL:a("date timestamp"),support:a("ODBCdotTable doubleQuote binaryNumber hexNumber")}),e.defineMIME("text/x-pgsql",{name:"sql",client:a("source"),keywords:a(o+"a abort abs absent absolute access according action ada add admin after aggregate alias all allocate also alter always analyse analyze and any are array array_agg array_max_cardinality as asc asensitive assert assertion assignment asymmetric at atomic attach attribute attributes authorization avg backward base64 before begin begin_frame begin_partition bernoulli between bigint binary bit bit_length blob blocked bom boolean both breadth by c cache call called cardinality cascade cascaded case cast catalog catalog_name ceil ceiling chain char char_length character character_length character_set_catalog character_set_name character_set_schema characteristics characters check checkpoint class class_origin clob close cluster coalesce cobol collate collation collation_catalog collation_name collation_schema collect column column_name columns command_function command_function_code comment comments commit committed concurrently condition condition_number configuration conflict connect connection connection_name constant constraint constraint_catalog constraint_name constraint_schema constraints constructor contains content continue control conversion convert copy corr corresponding cost count covar_pop covar_samp create cross csv cube cume_dist current current_catalog current_date current_default_transform_group current_path current_role current_row current_schema current_time current_timestamp current_transform_group_for_type current_user cursor cursor_name cycle data database datalink datatype date datetime_interval_code datetime_interval_precision day db deallocate debug dec decimal declare default defaults deferrable deferred defined definer degree delete delimiter delimiters dense_rank depends depth deref derived desc describe descriptor detach detail deterministic diagnostics dictionary disable discard disconnect dispatch distinct dlnewcopy dlpreviouscopy dlurlcomplete dlurlcompleteonly dlurlcompletewrite dlurlpath dlurlpathonly dlurlpathwrite dlurlscheme dlurlserver dlvalue do document domain double drop dump dynamic dynamic_function dynamic_function_code each element else elseif elsif empty enable encoding encrypted end end_frame end_partition endexec enforced enum equals errcode error escape event every except exception exclude excluding exclusive exec execute exists exit exp explain expression extension external extract false family fetch file filter final first first_value flag float floor following for force foreach foreign fortran forward found frame_row free freeze from fs full function functions fusion g general generated get global go goto grant granted greatest group grouping groups handler having header hex hierarchy hint hold hour id identity if ignore ilike immediate immediately immutable implementation implicit import in include including increment indent index indexes indicator info inherit inherits initially inline inner inout input insensitive insert instance instantiable instead int integer integrity intersect intersection interval into invoker is isnull isolation join k key key_member key_type label lag language large last last_value lateral lead leading leakproof least left length level library like like_regex limit link listen ln load local localtime localtimestamp location locator lock locked log logged loop lower m map mapping match matched materialized max max_cardinality maxvalue member merge message message_length message_octet_length message_text method min minute minvalue mod mode modifies module month more move multiset mumps name names namespace national natural nchar nclob nesting new next nfc nfd nfkc nfkd nil no none normalize normalized not nothing notice notify notnull nowait nth_value ntile null nullable nullif nulls number numeric object occurrences_regex octet_length octets of off offset oids old on only open operator option options or order ordering ordinality others out outer output over overlaps overlay overriding owned owner p pad parallel parameter parameter_mode parameter_name parameter_ordinal_position parameter_specific_catalog parameter_specific_name parameter_specific_schema parser partial partition pascal passing passthrough password path percent percent_rank percentile_cont percentile_disc perform period permission pg_context pg_datatype_name pg_exception_context pg_exception_detail pg_exception_hint placing plans pli policy portion position position_regex power precedes preceding precision prepare prepared preserve primary print_strict_params prior privileges procedural procedure procedures program public publication query quote raise range rank read reads real reassign recheck recovery recursive ref references referencing refresh regr_avgx regr_avgy regr_count regr_intercept regr_r2 regr_slope regr_sxx regr_sxy regr_syy reindex relative release rename repeatable replace replica requiring reset respect restart restore restrict result result_oid return returned_cardinality returned_length returned_octet_length returned_sqlstate returning returns reverse revoke right role rollback rollup routine routine_catalog routine_name routine_schema routines row row_count row_number rows rowtype rule savepoint scale schema schema_name schemas scope scope_catalog scope_name scope_schema scroll search second section security select selective self sensitive sequence sequences serializable server server_name session session_user set setof sets share show similar simple size skip slice smallint snapshot some source space specific specific_name specifictype sql sqlcode sqlerror sqlexception sqlstate sqlwarning sqrt stable stacked standalone start state statement static statistics stddev_pop stddev_samp stdin stdout storage strict strip structure style subclass_origin submultiset subscription substring substring_regex succeeds sum symmetric sysid system system_time system_user t table table_name tables tablesample tablespace temp template temporary text then ties time timestamp timezone_hour timezone_minute to token top_level_count trailing transaction transaction_active transactions_committed transactions_rolled_back transform transforms translate translate_regex translation treat trigger trigger_catalog trigger_name trigger_schema trim trim_array true truncate trusted type types uescape unbounded uncommitted under unencrypted union unique unknown unlink unlisten unlogged unnamed unnest until untyped update upper uri usage use_column use_variable user user_defined_type_catalog user_defined_type_code user_defined_type_name user_defined_type_schema using vacuum valid validate validator value value_of values var_pop var_samp varbinary varchar variable_conflict variadic varying verbose version versioning view views volatile warning when whenever where while whitespace width_bucket window with within without work wrapper write xml xmlagg xmlattributes xmlbinary xmlcast xmlcomment xmlconcat xmldeclaration xmldocument xmlelement xmlexists xmlforest xmliterate xmlnamespaces xmlparse xmlpi xmlquery xmlroot xmlschema xmlserialize xmltable xmltext xmlvalidate year yes zone"),builtin:a("bigint int8 bigserial serial8 bit varying varbit boolean bool box bytea character char varchar cidr circle date double precision float8 inet integer int int4 interval json jsonb line lseg macaddr macaddr8 money numeric decimal path pg_lsn point polygon real float4 smallint int2 smallserial serial2 serial serial4 text time without zone with timetz timestamp timestamptz tsquery tsvector txid_snapshot uuid xml"),atoms:a("false true null unknown"),operatorChars:/^[*\/+\-%<>!=&|^\/#@?~]/,backslashStringEscapes:!1,dateSQL:a("date time timestamp"),support:a("ODBCdotTable decimallessFloat zerolessFloat binaryNumber hexNumber nCharCast charsetCast escapeConstant")}),e.defineMIME("text/x-gql",{name:"sql",keywords:a("ancestor and asc by contains desc descendant distinct from group has in is limit offset on order select superset where"),atoms:a("false true"),builtin:a("blob datetime first key __key__ string integer double boolean null"),operatorChars:/^[*+\-%<>!=]/}),e.defineMIME("text/x-gpsql",{name:"sql",client:a("source"),keywords:a("abort absolute access action active add admin after aggregate all also alter always analyse analyze and any array as asc assertion assignment asymmetric at authorization backward before begin between bigint binary bit boolean both by cache called cascade cascaded case cast chain char character characteristics check checkpoint class close cluster coalesce codegen collate column comment commit committed concurrency concurrently configuration connection constraint constraints contains content continue conversion copy cost cpu_rate_limit create createdb createexttable createrole createuser cross csv cube current current_catalog current_date current_role current_schema current_time current_timestamp current_user cursor cycle data database day deallocate dec decimal declare decode default defaults deferrable deferred definer delete delimiter delimiters deny desc dictionary disable discard distinct distributed do document domain double drop dxl each else enable encoding encrypted end enum errors escape every except exchange exclude excluding exclusive execute exists explain extension external extract false family fetch fields filespace fill filter first float following for force foreign format forward freeze from full function global grant granted greatest group group_id grouping handler hash having header hold host hour identity if ignore ilike immediate immutable implicit in including inclusive increment index indexes inherit inherits initially inline inner inout input insensitive insert instead int integer intersect interval into invoker is isnull isolation join key language large last leading least left level like limit list listen load local localtime localtimestamp location lock log login mapping master match maxvalue median merge minute minvalue missing mode modifies modify month move name names national natural nchar new newline next no nocreatedb nocreateexttable nocreaterole nocreateuser noinherit nologin none noovercommit nosuperuser not nothing notify notnull nowait null nullif nulls numeric object of off offset oids old on only operator option options or order ordered others out outer over overcommit overlaps overlay owned owner parser partial partition partitions passing password percent percentile_cont percentile_disc placing plans position preceding precision prepare prepared preserve primary prior privileges procedural procedure protocol queue quote randomly range read readable reads real reassign recheck recursive ref references reindex reject relative release rename repeatable replace replica reset resource restart restrict returning returns revoke right role rollback rollup rootpartition row rows rule savepoint scatter schema scroll search second security segment select sequence serializable session session_user set setof sets share show similar simple smallint some split sql stable standalone start statement statistics stdin stdout storage strict strip subpartition subpartitions substring superuser symmetric sysid system table tablespace temp template temporary text then threshold ties time timestamp to trailing transaction treat trigger trim true truncate trusted type unbounded uncommitted unencrypted union unique unknown unlisten until update user using vacuum valid validation validator value values varchar variadic varying verbose version view volatile web when where whitespace window with within without work writable write xml xmlattributes xmlconcat xmlelement xmlexists xmlforest xmlparse xmlpi xmlroot xmlserialize year yes zone"),builtin:a("bigint int8 bigserial serial8 bit varying varbit boolean bool box bytea character char varchar cidr circle date double precision float float8 inet integer int int4 interval json jsonb line lseg macaddr macaddr8 money numeric decimal path pg_lsn point polygon real float4 smallint int2 smallserial serial2 serial serial4 text time without zone with timetz timestamp timestamptz tsquery tsvector txid_snapshot uuid xml"),atoms:a("false true null unknown"),operatorChars:/^[*+\-%<>!=&|^\/#@?~]/,dateSQL:a("date time timestamp"),support:a("ODBCdotTable decimallessFloat zerolessFloat binaryNumber hexNumber nCharCast charsetCast")}),e.defineMIME("text/x-sparksql",{name:"sql",keywords:a("add after all alter analyze and anti archive array as asc at between bucket buckets by cache cascade case cast change clear cluster clustered codegen collection column columns comment commit compact compactions compute concatenate cost create cross cube current current_date current_timestamp database databases data dbproperties defined delete delimited deny desc describe dfs directories distinct distribute drop else end escaped except exchange exists explain export extended external false fields fileformat first following for format formatted from full function functions global grant group grouping having if ignore import in index indexes inner inpath inputformat insert intersect interval into is items join keys last lateral lazy left like limit lines list load local location lock locks logical macro map minus msck natural no not null nulls of on optimize option options or order out outer outputformat over overwrite partition partitioned partitions percent preceding principals purge range recordreader recordwriter recover reduce refresh regexp rename repair replace reset restrict revoke right rlike role roles rollback rollup row rows schema schemas select semi separated serde serdeproperties set sets show skewed sort sorted start statistics stored stratify struct table tables tablesample tblproperties temp temporary terminated then to touch transaction transactions transform true truncate unarchive unbounded uncache union unlock unset use using values view when where window with"),builtin:a("tinyint smallint int bigint boolean float double string binary timestamp decimal array map struct uniontype delimited serde sequencefile textfile rcfile inputformat outputformat"),atoms:a("false true null"),operatorChars:/^[*\/+\-%<>!=~&|^]/,dateSQL:a("date time timestamp"),support:a("ODBCdotTable doubleQuote zerolessFloat")}),e.defineMIME("text/x-esper",{name:"sql",client:a("source"),keywords:a("alter and as asc between by count create delete desc distinct drop from group having in insert into is join like not on or order select set table union update values where limit after all and as at asc avedev avg between by case cast coalesce count create current_timestamp day days delete define desc distinct else end escape events every exists false first from full group having hour hours in inner insert instanceof into irstream is istream join last lastweekday left limit like max match_recognize matches median measures metadatasql min minute minutes msec millisecond milliseconds not null offset on or order outer output partition pattern prev prior regexp retain-union retain-intersection right rstream sec second seconds select set some snapshot sql stddev sum then true unidirectional until update variable weekday when where window"),builtin:{},atoms:a("false true null"),operatorChars:/^[*+\-%<>!=&|^\/#@?~]/,dateSQL:a("time"),support:a("decimallessFloat zerolessFloat binaryNumber hexNumber")})}(Uu)})),Un((function(e,t){!function(e){function t(e){for(var t={},n=0;n<e.length;++n)t[e[n].toLowerCase()]=!0;return t}e.defineMode("css",(function(t,n){var r=n.inline;n.propertyKeywords||(n=e.resolveMode("text/css"));var i,o,a=t.indentUnit,s=n.tokenHooks,l=n.documentTypes||{},u=n.mediaTypes||{},c=n.mediaFeatures||{},f=n.mediaValueKeywords||{},p=n.propertyKeywords||{},d=n.nonStandardPropertyKeywords||{},h=n.fontProperties||{},g=n.counterDescriptors||{},m=n.colorKeywords||{},v=n.valueKeywords||{},y=n.allowNested,b=n.lineComment,_=!0===n.supportsAtComponent,w=!1!==t.highlightNonStandardPropertyKeywords;function x(e,t){return i=t,e}function k(e,t){var n=e.next();if(s[n]){var r=s[n](e,t);if(!1!==r)return r}return"@"==n?(e.eatWhile(/[\w\\\-]/),x("def",e.current())):"="==n||("~"==n||"|"==n)&&e.eat("=")?x(null,"compare"):'"'==n||"'"==n?(t.tokenize=C(n),t.tokenize(e,t)):"#"==n?(e.eatWhile(/[\w\\\-]/),x("atom","hash")):"!"==n?(e.match(/^\s*\w*/),x("keyword","important")):/\d/.test(n)||"."==n&&e.eat(/\d/)?(e.eatWhile(/[\w.%]/),x("number","unit")):"-"!==n?/[,+>*\/]/.test(n)?x(null,"select-op"):"."==n&&e.match(/^-?[_a-z][_a-z0-9-]*/i)?x("qualifier","qualifier"):/[:;{}\[\]\(\)]/.test(n)?x(null,n):e.match(/^[\w-.]+(?=\()/)?(/^(url(-prefix)?|domain|regexp)$/i.test(e.current())&&(t.tokenize=E),x("variable callee","variable")):/[\w\\\-]/.test(n)?(e.eatWhile(/[\w\\\-]/),x("property","word")):x(null,null):/[\d.]/.test(e.peek())?(e.eatWhile(/[\w.%]/),x("number","unit")):e.match(/^-[\w\\\-]*/)?(e.eatWhile(/[\w\\\-]/),e.match(/^\s*:/,!1)?x("variable-2","variable-definition"):x("variable-2","variable")):e.match(/^\w+-/)?x("meta","meta"):void 0}function C(e){return function(t,n){for(var r,i=!1;null!=(r=t.next());){if(r==e&&!i){")"==e&&t.backUp(1);break}i=!i&&"\\"==r}return(r==e||!i&&")"!=e)&&(n.tokenize=null),x("string","string")}}function E(e,t){return e.next(),e.match(/^\s*[\"\')]/,!1)?t.tokenize=null:t.tokenize=C(")"),x(null,"(")}function O(e,t,n){this.type=e,this.indent=t,this.prev=n}function A(e,t,n,r){return e.context=new O(n,t.indentation()+(!1===r?0:a),e.context),n}function S(e){return e.context.prev&&(e.context=e.context.prev),e.context.type}function j(e,t,n){return N[n.context.type](e,t,n)}function T(e,t,n,r){for(var i=r||1;i>0;i--)n.context=n.context.prev;return j(e,t,n)}function D(e){var t=e.current().toLowerCase();o=v.hasOwnProperty(t)?"atom":m.hasOwnProperty(t)?"keyword":"variable"}var N={top:function(e,t,n){if("{"==e)return A(n,t,"block");if("}"==e&&n.context.prev)return S(n);if(_&&/@component/i.test(e))return A(n,t,"atComponentBlock");if(/^@(-moz-)?document$/i.test(e))return A(n,t,"documentTypes");if(/^@(media|supports|(-moz-)?document|import)$/i.test(e))return A(n,t,"atBlock");if(/^@(font-face|counter-style)/i.test(e))return n.stateArg=e,"restricted_atBlock_before";if(/^@(-(moz|ms|o|webkit)-)?keyframes$/i.test(e))return"keyframes";if(e&&"@"==e.charAt(0))return A(n,t,"at");if("hash"==e)o="builtin";else if("word"==e)o="tag";else{if("variable-definition"==e)return"maybeprop";if("interpolation"==e)return A(n,t,"interpolation");if(":"==e)return"pseudo";if(y&&"("==e)return A(n,t,"parens")}return n.context.type},block:function(e,t,n){if("word"==e){var r=t.current().toLowerCase();return p.hasOwnProperty(r)?(o="property","maybeprop"):d.hasOwnProperty(r)?(o=w?"string-2":"property","maybeprop"):y?(o=t.match(/^\s*:(?:\s|$)/,!1)?"property":"tag","block"):(o+=" error","maybeprop")}return"meta"==e?"block":y||"hash"!=e&&"qualifier"!=e?N.top(e,t,n):(o="error","block")},maybeprop:function(e,t,n){return":"==e?A(n,t,"prop"):j(e,t,n)},prop:function(e,t,n){if(";"==e)return S(n);if("{"==e&&y)return A(n,t,"propBlock");if("}"==e||"{"==e)return T(e,t,n);if("("==e)return A(n,t,"parens");if("hash"!=e||/^#([0-9a-fA-f]{3,4}|[0-9a-fA-f]{6}|[0-9a-fA-f]{8})$/.test(t.current())){if("word"==e)D(t);else if("interpolation"==e)return A(n,t,"interpolation")}else o+=" error";return"prop"},propBlock:function(e,t,n){return"}"==e?S(n):"word"==e?(o="property","maybeprop"):n.context.type},parens:function(e,t,n){return"{"==e||"}"==e?T(e,t,n):")"==e?S(n):"("==e?A(n,t,"parens"):"interpolation"==e?A(n,t,"interpolation"):("word"==e&&D(t),"parens")},pseudo:function(e,t,n){return"meta"==e?"pseudo":"word"==e?(o="variable-3",n.context.type):j(e,t,n)},documentTypes:function(e,t,n){return"word"==e&&l.hasOwnProperty(t.current())?(o="tag",n.context.type):N.atBlock(e,t,n)},atBlock:function(e,t,n){if("("==e)return A(n,t,"atBlock_parens");if("}"==e||";"==e)return T(e,t,n);if("{"==e)return S(n)&&A(n,t,y?"block":"top");if("interpolation"==e)return A(n,t,"interpolation");if("word"==e){var r=t.current().toLowerCase();o="only"==r||"not"==r||"and"==r||"or"==r?"keyword":u.hasOwnProperty(r)?"attribute":c.hasOwnProperty(r)?"property":f.hasOwnProperty(r)?"keyword":p.hasOwnProperty(r)?"property":d.hasOwnProperty(r)?w?"string-2":"property":v.hasOwnProperty(r)?"atom":m.hasOwnProperty(r)?"keyword":"error"}return n.context.type},atComponentBlock:function(e,t,n){return"}"==e?T(e,t,n):"{"==e?S(n)&&A(n,t,y?"block":"top",!1):("word"==e&&(o="error"),n.context.type)},atBlock_parens:function(e,t,n){return")"==e?S(n):"{"==e||"}"==e?T(e,t,n,2):N.atBlock(e,t,n)},restricted_atBlock_before:function(e,t,n){return"{"==e?A(n,t,"restricted_atBlock"):"word"==e&&"@counter-style"==n.stateArg?(o="variable","restricted_atBlock_before"):j(e,t,n)},restricted_atBlock:function(e,t,n){return"}"==e?(n.stateArg=null,S(n)):"word"==e?(o="@font-face"==n.stateArg&&!h.hasOwnProperty(t.current().toLowerCase())||"@counter-style"==n.stateArg&&!g.hasOwnProperty(t.current().toLowerCase())?"error":"property","maybeprop"):"restricted_atBlock"},keyframes:function(e,t,n){return"word"==e?(o="variable","keyframes"):"{"==e?A(n,t,"top"):j(e,t,n)},at:function(e,t,n){return";"==e?S(n):"{"==e||"}"==e?T(e,t,n):("word"==e?o="tag":"hash"==e&&(o="builtin"),"at")},interpolation:function(e,t,n){return"}"==e?S(n):"{"==e||";"==e?T(e,t,n):("word"==e?o="variable":"variable"!=e&&"("!=e&&")"!=e&&(o="error"),"interpolation")}};return{startState:function(e){return{tokenize:null,state:r?"block":"top",stateArg:null,context:new O(r?"block":"top",e||0,null)}},token:function(e,t){if(!t.tokenize&&e.eatSpace())return null;var n=(t.tokenize||k)(e,t);return n&&"object"==typeof n&&(i=n[1],n=n[0]),o=n,"comment"!=i&&(t.state=N[t.state](i,e,t)),o},indent:function(e,t){var n=e.context,r=t&&t.charAt(0),i=n.indent;return"prop"!=n.type||"}"!=r&&")"!=r||(n=n.prev),n.prev&&("}"!=r||"block"!=n.type&&"top"!=n.type&&"interpolation"!=n.type&&"restricted_atBlock"!=n.type?(")"!=r||"parens"!=n.type&&"atBlock_parens"!=n.type)&&("{"!=r||"at"!=n.type&&"atBlock"!=n.type)||(i=Math.max(0,n.indent-a)):i=(n=n.prev).indent),i},electricChars:"}",blockCommentStart:"/*",blockCommentEnd:"*/",blockCommentContinue:" * ",lineComment:b,fold:"brace"}}));var n=["domain","regexp","url","url-prefix"],r=t(n),i=["all","aural","braille","handheld","print","projection","screen","tty","tv","embossed"],o=t(i),a=["width","min-width","max-width","height","min-height","max-height","device-width","min-device-width","max-device-width","device-height","min-device-height","max-device-height","aspect-ratio","min-aspect-ratio","max-aspect-ratio","device-aspect-ratio","min-device-aspect-ratio","max-device-aspect-ratio","color","min-color","max-color","color-index","min-color-index","max-color-index","monochrome","min-monochrome","max-monochrome","resolution","min-resolution","max-resolution","scan","grid","orientation","device-pixel-ratio","min-device-pixel-ratio","max-device-pixel-ratio","pointer","any-pointer","hover","any-hover","prefers-color-scheme"],s=t(a),l=["landscape","portrait","none","coarse","fine","on-demand","hover","interlace","progressive","dark","light"],u=t(l),c=["align-content","align-items","align-self","alignment-adjust","alignment-baseline","all","anchor-point","animation","animation-delay","animation-direction","animation-duration","animation-fill-mode","animation-iteration-count","animation-name","animation-play-state","animation-timing-function","appearance","azimuth","backdrop-filter","backface-visibility","background","background-attachment","background-blend-mode","background-clip","background-color","background-image","background-origin","background-position","background-position-x","background-position-y","background-repeat","background-size","baseline-shift","binding","bleed","block-size","bookmark-label","bookmark-level","bookmark-state","bookmark-target","border","border-bottom","border-bottom-color","border-bottom-left-radius","border-bottom-right-radius","border-bottom-style","border-bottom-width","border-collapse","border-color","border-image","border-image-outset","border-image-repeat","border-image-slice","border-image-source","border-image-width","border-left","border-left-color","border-left-style","border-left-width","border-radius","border-right","border-right-color","border-right-style","border-right-width","border-spacing","border-style","border-top","border-top-color","border-top-left-radius","border-top-right-radius","border-top-style","border-top-width","border-width","bottom","box-decoration-break","box-shadow","box-sizing","break-after","break-before","break-inside","caption-side","caret-color","clear","clip","color","color-profile","column-count","column-fill","column-gap","column-rule","column-rule-color","column-rule-style","column-rule-width","column-span","column-width","columns","contain","content","counter-increment","counter-reset","crop","cue","cue-after","cue-before","cursor","direction","display","dominant-baseline","drop-initial-after-adjust","drop-initial-after-align","drop-initial-before-adjust","drop-initial-before-align","drop-initial-size","drop-initial-value","elevation","empty-cells","fit","fit-position","flex","flex-basis","flex-direction","flex-flow","flex-grow","flex-shrink","flex-wrap","float","float-offset","flow-from","flow-into","font","font-family","font-feature-settings","font-kerning","font-language-override","font-optical-sizing","font-size","font-size-adjust","font-stretch","font-style","font-synthesis","font-variant","font-variant-alternates","font-variant-caps","font-variant-east-asian","font-variant-ligatures","font-variant-numeric","font-variant-position","font-variation-settings","font-weight","gap","grid","grid-area","grid-auto-columns","grid-auto-flow","grid-auto-rows","grid-column","grid-column-end","grid-column-gap","grid-column-start","grid-gap","grid-row","grid-row-end","grid-row-gap","grid-row-start","grid-template","grid-template-areas","grid-template-columns","grid-template-rows","hanging-punctuation","height","hyphens","icon","image-orientation","image-rendering","image-resolution","inline-box-align","inset","inset-block","inset-block-end","inset-block-start","inset-inline","inset-inline-end","inset-inline-start","isolation","justify-content","justify-items","justify-self","left","letter-spacing","line-break","line-height","line-height-step","line-stacking","line-stacking-ruby","line-stacking-shift","line-stacking-strategy","list-style","list-style-image","list-style-position","list-style-type","margin","margin-bottom","margin-left","margin-right","margin-top","marks","marquee-direction","marquee-loop","marquee-play-count","marquee-speed","marquee-style","mask-clip","mask-composite","mask-image","mask-mode","mask-origin","mask-position","mask-repeat","mask-size","mask-type","max-block-size","max-height","max-inline-size","max-width","min-block-size","min-height","min-inline-size","min-width","mix-blend-mode","move-to","nav-down","nav-index","nav-left","nav-right","nav-up","object-fit","object-position","offset","offset-anchor","offset-distance","offset-path","offset-position","offset-rotate","opacity","order","orphans","outline","outline-color","outline-offset","outline-style","outline-width","overflow","overflow-style","overflow-wrap","overflow-x","overflow-y","padding","padding-bottom","padding-left","padding-right","padding-top","page","page-break-after","page-break-before","page-break-inside","page-policy","pause","pause-after","pause-before","perspective","perspective-origin","pitch","pitch-range","place-content","place-items","place-self","play-during","position","presentation-level","punctuation-trim","quotes","region-break-after","region-break-before","region-break-inside","region-fragment","rendering-intent","resize","rest","rest-after","rest-before","richness","right","rotate","rotation","rotation-point","row-gap","ruby-align","ruby-overhang","ruby-position","ruby-span","scale","scroll-behavior","scroll-margin","scroll-margin-block","scroll-margin-block-end","scroll-margin-block-start","scroll-margin-bottom","scroll-margin-inline","scroll-margin-inline-end","scroll-margin-inline-start","scroll-margin-left","scroll-margin-right","scroll-margin-top","scroll-padding","scroll-padding-block","scroll-padding-block-end","scroll-padding-block-start","scroll-padding-bottom","scroll-padding-inline","scroll-padding-inline-end","scroll-padding-inline-start","scroll-padding-left","scroll-padding-right","scroll-padding-top","scroll-snap-align","scroll-snap-type","shape-image-threshold","shape-inside","shape-margin","shape-outside","size","speak","speak-as","speak-header","speak-numeral","speak-punctuation","speech-rate","stress","string-set","tab-size","table-layout","target","target-name","target-new","target-position","text-align","text-align-last","text-combine-upright","text-decoration","text-decoration-color","text-decoration-line","text-decoration-skip","text-decoration-skip-ink","text-decoration-style","text-emphasis","text-emphasis-color","text-emphasis-position","text-emphasis-style","text-height","text-indent","text-justify","text-orientation","text-outline","text-overflow","text-rendering","text-shadow","text-size-adjust","text-space-collapse","text-transform","text-underline-position","text-wrap","top","touch-action","transform","transform-origin","transform-style","transition","transition-delay","transition-duration","transition-property","transition-timing-function","translate","unicode-bidi","user-select","vertical-align","visibility","voice-balance","voice-duration","voice-family","voice-pitch","voice-range","voice-rate","voice-stress","voice-volume","volume","white-space","widows","width","will-change","word-break","word-spacing","word-wrap","writing-mode","z-index","clip-path","clip-rule","mask","enable-background","filter","flood-color","flood-opacity","lighting-color","stop-color","stop-opacity","pointer-events","color-interpolation","color-interpolation-filters","color-rendering","fill","fill-opacity","fill-rule","image-rendering","marker","marker-end","marker-mid","marker-start","paint-order","shape-rendering","stroke","stroke-dasharray","stroke-dashoffset","stroke-linecap","stroke-linejoin","stroke-miterlimit","stroke-opacity","stroke-width","text-rendering","baseline-shift","dominant-baseline","glyph-orientation-horizontal","glyph-orientation-vertical","text-anchor","writing-mode"],f=t(c),p=["border-block","border-block-color","border-block-end","border-block-end-color","border-block-end-style","border-block-end-width","border-block-start","border-block-start-color","border-block-start-style","border-block-start-width","border-block-style","border-block-width","border-inline","border-inline-color","border-inline-end","border-inline-end-color","border-inline-end-style","border-inline-end-width","border-inline-start","border-inline-start-color","border-inline-start-style","border-inline-start-width","border-inline-style","border-inline-width","margin-block","margin-block-end","margin-block-start","margin-inline","margin-inline-end","margin-inline-start","padding-block","padding-block-end","padding-block-start","padding-inline","padding-inline-end","padding-inline-start","scroll-snap-stop","scrollbar-3d-light-color","scrollbar-arrow-color","scrollbar-base-color","scrollbar-dark-shadow-color","scrollbar-face-color","scrollbar-highlight-color","scrollbar-shadow-color","scrollbar-track-color","searchfield-cancel-button","searchfield-decoration","searchfield-results-button","searchfield-results-decoration","shape-inside","zoom"],d=t(p),h=t(["font-display","font-family","src","unicode-range","font-variant","font-feature-settings","font-stretch","font-weight","font-style"]),g=t(["additive-symbols","fallback","negative","pad","prefix","range","speak-as","suffix","symbols","system"]),m=["aliceblue","antiquewhite","aqua","aquamarine","azure","beige","bisque","black","blanchedalmond","blue","blueviolet","brown","burlywood","cadetblue","chartreuse","chocolate","coral","cornflowerblue","cornsilk","crimson","cyan","darkblue","darkcyan","darkgoldenrod","darkgray","darkgreen","darkkhaki","darkmagenta","darkolivegreen","darkorange","darkorchid","darkred","darksalmon","darkseagreen","darkslateblue","darkslategray","darkturquoise","darkviolet","deeppink","deepskyblue","dimgray","dodgerblue","firebrick","floralwhite","forestgreen","fuchsia","gainsboro","ghostwhite","gold","goldenrod","gray","grey","green","greenyellow","honeydew","hotpink","indianred","indigo","ivory","khaki","lavender","lavenderblush","lawngreen","lemonchiffon","lightblue","lightcoral","lightcyan","lightgoldenrodyellow","lightgray","lightgreen","lightpink","lightsalmon","lightseagreen","lightskyblue","lightslategray","lightsteelblue","lightyellow","lime","limegreen","linen","magenta","maroon","mediumaquamarine","mediumblue","mediumorchid","mediumpurple","mediumseagreen","mediumslateblue","mediumspringgreen","mediumturquoise","mediumvioletred","midnightblue","mintcream","mistyrose","moccasin","navajowhite","navy","oldlace","olive","olivedrab","orange","orangered","orchid","palegoldenrod","palegreen","paleturquoise","palevioletred","papayawhip","peachpuff","peru","pink","plum","powderblue","purple","rebeccapurple","red","rosybrown","royalblue","saddlebrown","salmon","sandybrown","seagreen","seashell","sienna","silver","skyblue","slateblue","slategray","snow","springgreen","steelblue","tan","teal","thistle","tomato","turquoise","violet","wheat","white","whitesmoke","yellow","yellowgreen"],v=t(m),y=["above","absolute","activeborder","additive","activecaption","afar","after-white-space","ahead","alias","all","all-scroll","alphabetic","alternate","always","amharic","amharic-abegede","antialiased","appworkspace","arabic-indic","armenian","asterisks","attr","auto","auto-flow","avoid","avoid-column","avoid-page","avoid-region","axis-pan","background","backwards","baseline","below","bidi-override","binary","bengali","blink","block","block-axis","bold","bolder","border","border-box","both","bottom","break","break-all","break-word","bullets","button","button-bevel","buttonface","buttonhighlight","buttonshadow","buttontext","calc","cambodian","capitalize","caps-lock-indicator","caption","captiontext","caret","cell","center","checkbox","circle","cjk-decimal","cjk-earthly-branch","cjk-heavenly-stem","cjk-ideographic","clear","clip","close-quote","col-resize","collapse","color","color-burn","color-dodge","column","column-reverse","compact","condensed","contain","content","contents","content-box","context-menu","continuous","copy","counter","counters","cover","crop","cross","crosshair","currentcolor","cursive","cyclic","darken","dashed","decimal","decimal-leading-zero","default","default-button","dense","destination-atop","destination-in","destination-out","destination-over","devanagari","difference","disc","discard","disclosure-closed","disclosure-open","document","dot-dash","dot-dot-dash","dotted","double","down","e-resize","ease","ease-in","ease-in-out","ease-out","element","ellipse","ellipsis","embed","end","ethiopic","ethiopic-abegede","ethiopic-abegede-am-et","ethiopic-abegede-gez","ethiopic-abegede-ti-er","ethiopic-abegede-ti-et","ethiopic-halehame-aa-er","ethiopic-halehame-aa-et","ethiopic-halehame-am-et","ethiopic-halehame-gez","ethiopic-halehame-om-et","ethiopic-halehame-sid-et","ethiopic-halehame-so-et","ethiopic-halehame-ti-er","ethiopic-halehame-ti-et","ethiopic-halehame-tig","ethiopic-numeric","ew-resize","exclusion","expanded","extends","extra-condensed","extra-expanded","fantasy","fast","fill","fill-box","fixed","flat","flex","flex-end","flex-start","footnotes","forwards","from","geometricPrecision","georgian","graytext","grid","groove","gujarati","gurmukhi","hand","hangul","hangul-consonant","hard-light","hebrew","help","hidden","hide","higher","highlight","highlighttext","hiragana","hiragana-iroha","horizontal","hsl","hsla","hue","icon","ignore","inactiveborder","inactivecaption","inactivecaptiontext","infinite","infobackground","infotext","inherit","initial","inline","inline-axis","inline-block","inline-flex","inline-grid","inline-table","inset","inside","intrinsic","invert","italic","japanese-formal","japanese-informal","justify","kannada","katakana","katakana-iroha","keep-all","khmer","korean-hangul-formal","korean-hanja-formal","korean-hanja-informal","landscape","lao","large","larger","left","level","lighter","lighten","line-through","linear","linear-gradient","lines","list-item","listbox","listitem","local","logical","loud","lower","lower-alpha","lower-armenian","lower-greek","lower-hexadecimal","lower-latin","lower-norwegian","lower-roman","lowercase","ltr","luminosity","malayalam","manipulation","match","matrix","matrix3d","media-controls-background","media-current-time-display","media-fullscreen-button","media-mute-button","media-play-button","media-return-to-realtime-button","media-rewind-button","media-seek-back-button","media-seek-forward-button","media-slider","media-sliderthumb","media-time-remaining-display","media-volume-slider","media-volume-slider-container","media-volume-sliderthumb","medium","menu","menulist","menulist-button","menulist-text","menulist-textfield","menutext","message-box","middle","min-intrinsic","mix","mongolian","monospace","move","multiple","multiple_mask_images","multiply","myanmar","n-resize","narrower","ne-resize","nesw-resize","no-close-quote","no-drop","no-open-quote","no-repeat","none","normal","not-allowed","nowrap","ns-resize","numbers","numeric","nw-resize","nwse-resize","oblique","octal","opacity","open-quote","optimizeLegibility","optimizeSpeed","oriya","oromo","outset","outside","outside-shape","overlay","overline","padding","padding-box","painted","page","paused","persian","perspective","pinch-zoom","plus-darker","plus-lighter","pointer","polygon","portrait","pre","pre-line","pre-wrap","preserve-3d","progress","push-button","radial-gradient","radio","read-only","read-write","read-write-plaintext-only","rectangle","region","relative","repeat","repeating-linear-gradient","repeating-radial-gradient","repeat-x","repeat-y","reset","reverse","rgb","rgba","ridge","right","rotate","rotate3d","rotateX","rotateY","rotateZ","round","row","row-resize","row-reverse","rtl","run-in","running","s-resize","sans-serif","saturation","scale","scale3d","scaleX","scaleY","scaleZ","screen","scroll","scrollbar","scroll-position","se-resize","searchfield","searchfield-cancel-button","searchfield-decoration","searchfield-results-button","searchfield-results-decoration","self-start","self-end","semi-condensed","semi-expanded","separate","serif","show","sidama","simp-chinese-formal","simp-chinese-informal","single","skew","skewX","skewY","skip-white-space","slide","slider-horizontal","slider-vertical","sliderthumb-horizontal","sliderthumb-vertical","slow","small","small-caps","small-caption","smaller","soft-light","solid","somali","source-atop","source-in","source-out","source-over","space","space-around","space-between","space-evenly","spell-out","square","square-button","start","static","status-bar","stretch","stroke","stroke-box","sub","subpixel-antialiased","svg_masks","super","sw-resize","symbolic","symbols","system-ui","table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row","table-row-group","tamil","telugu","text","text-bottom","text-top","textarea","textfield","thai","thick","thin","threeddarkshadow","threedface","threedhighlight","threedlightshadow","threedshadow","tibetan","tigre","tigrinya-er","tigrinya-er-abegede","tigrinya-et","tigrinya-et-abegede","to","top","trad-chinese-formal","trad-chinese-informal","transform","translate","translate3d","translateX","translateY","translateZ","transparent","ultra-condensed","ultra-expanded","underline","unidirectional-pan","unset","up","upper-alpha","upper-armenian","upper-greek","upper-hexadecimal","upper-latin","upper-norwegian","upper-roman","uppercase","urdu","url","var","vertical","vertical-text","view-box","visible","visibleFill","visiblePainted","visibleStroke","visual","w-resize","wait","wave","wider","window","windowframe","windowtext","words","wrap","wrap-reverse","x-large","x-small","xor","xx-large","xx-small"],b=t(y),_=n.concat(i).concat(a).concat(l).concat(c).concat(p).concat(m).concat(y);function w(e,t){for(var n,r=!1;null!=(n=e.next());){if(r&&"/"==n){t.tokenize=null;break}r="*"==n}return["comment","comment"]}e.registerHelper("hintWords","css",_),e.defineMIME("text/css",{documentTypes:r,mediaTypes:o,mediaFeatures:s,mediaValueKeywords:u,propertyKeywords:f,nonStandardPropertyKeywords:d,fontProperties:h,counterDescriptors:g,colorKeywords:v,valueKeywords:b,tokenHooks:{"/":function(e,t){return!!e.eat("*")&&(t.tokenize=w,w(e,t))}},name:"css"}),e.defineMIME("text/x-scss",{mediaTypes:o,mediaFeatures:s,mediaValueKeywords:u,propertyKeywords:f,nonStandardPropertyKeywords:d,colorKeywords:v,valueKeywords:b,fontProperties:h,allowNested:!0,lineComment:"//",tokenHooks:{"/":function(e,t){return e.eat("/")?(e.skipToEnd(),["comment","comment"]):e.eat("*")?(t.tokenize=w,w(e,t)):["operator","operator"]},":":function(e){return!!e.match(/^\s*\{/,!1)&&[null,null]},$:function(e){return e.match(/^[\w-]+/),e.match(/^\s*:/,!1)?["variable-2","variable-definition"]:["variable-2","variable"]},"#":function(e){return!!e.eat("{")&&[null,"interpolation"]}},name:"css",helperType:"scss"}),e.defineMIME("text/x-less",{mediaTypes:o,mediaFeatures:s,mediaValueKeywords:u,propertyKeywords:f,nonStandardPropertyKeywords:d,colorKeywords:v,valueKeywords:b,fontProperties:h,allowNested:!0,lineComment:"//",tokenHooks:{"/":function(e,t){return e.eat("/")?(e.skipToEnd(),["comment","comment"]):e.eat("*")?(t.tokenize=w,w(e,t)):["operator","operator"]},"@":function(e){return e.eat("{")?[null,"interpolation"]:!e.match(/^(charset|document|font-face|import|(-(moz|ms|o|webkit)-)?keyframes|media|namespace|page|supports)\b/i,!1)&&(e.eatWhile(/[\w\\\-]/),e.match(/^\s*:/,!1)?["variable-2","variable-definition"]:["variable-2","variable"])},"&":function(){return["atom","atom"]}},name:"css",helperType:"less"}),e.defineMIME("text/x-gss",{documentTypes:r,mediaTypes:o,mediaFeatures:s,propertyKeywords:f,nonStandardPropertyKeywords:d,fontProperties:h,counterDescriptors:g,colorKeywords:v,valueKeywords:b,supportsAtComponent:!0,tokenHooks:{"/":function(e,t){return!!e.eat("*")&&(t.tokenize=w,w(e,t))}},name:"css",helperType:"gss"})}(Uu)}));Un((function(e,t){!function(e){function t(e,t){if(!e.hasOwnProperty(t))throw new Error("Undefined state "+t+" in simple mode")}function n(e,t){if(!e)return/(?:)/;var n="";return e instanceof RegExp?(e.ignoreCase&&(n="i"),e=e.source):e=String(e),new RegExp((!1===t?"":"^")+"(?:"+e+")",n)}function r(e){if(!e)return null;if(e.apply)return e;if("string"==typeof e)return e.replace(/\./g," ");for(var t=[],n=0;n<e.length;n++)t.push(e[n]&&e[n].replace(/\./g," "));return t}function i(e,i){(e.next||e.push)&&t(i,e.next||e.push),this.regex=n(e.regex),this.token=r(e.token),this.data=e}function o(e,t){return function(n,r){if(r.pending){var i=r.pending.shift();return 0==r.pending.length&&(r.pending=null),n.pos+=i.text.length,i.token}if(r.local){if(r.local.end&&n.match(r.local.end)){var o=r.local.endToken||null;return r.local=r.localState=null,o}var a;return o=r.local.mode.token(n,r.localState),r.local.endScan&&(a=r.local.endScan.exec(n.current()))&&(n.pos=n.start+a.index),o}for(var l=e[r.state],u=0;u<l.length;u++){var c=l[u],f=(!c.data.sol||n.sol())&&n.match(c.regex);if(f){c.data.next?r.state=c.data.next:c.data.push?((r.stack||(r.stack=[])).push(r.state),r.state=c.data.push):c.data.pop&&r.stack&&r.stack.length&&(r.state=r.stack.pop()),c.data.mode&&s(t,r,c.data.mode,c.token),c.data.indent&&r.indent.push(n.indentation()+t.indentUnit),c.data.dedent&&r.indent.pop();var p=c.token;if(p&&p.apply&&(p=p(f)),f.length>2&&c.token&&"string"!=typeof c.token){for(var d=2;d<f.length;d++)f[d]&&(r.pending||(r.pending=[])).push({text:f[d],token:c.token[d-1]});return n.backUp(f[0].length-(f[1]?f[1].length:0)),p[0]}return p&&p.join?p[0]:p}}return n.next(),null}}function a(e,t){if(e===t)return!0;if(!e||"object"!=typeof e||!t||"object"!=typeof t)return!1;var n=0;for(var r in e)if(e.hasOwnProperty(r)){if(!t.hasOwnProperty(r)||!a(e[r],t[r]))return!1;n++}for(var r in t)t.hasOwnProperty(r)&&n--;return 0==n}function s(t,r,i,o){var s;if(i.persistent)for(var l=r.persistentStates;l&&!s;l=l.next)(i.spec?a(i.spec,l.spec):i.mode==l.mode)&&(s=l);var u=s?s.mode:i.mode||e.getMode(t,i.spec),c=s?s.state:e.startState(u);i.persistent&&!s&&(r.persistentStates={mode:u,spec:i.spec,state:c,next:r.persistentStates}),r.localState=c,r.local={mode:u,end:i.end&&n(i.end),endScan:i.end&&!1!==i.forceEnd&&n(i.end,!1),endToken:o&&o.join?o[o.length-1]:o}}function l(e,t){for(var n=0;n<t.length;n++)if(t[n]===e)return!0}function u(t,n){return function(r,i,o){if(r.local&&r.local.mode.indent)return r.local.mode.indent(r.localState,i,o);if(null==r.indent||r.local||n.dontIndentStates&&l(r.state,n.dontIndentStates)>-1)return e.Pass;var a=r.indent.length-1,s=t[r.state];e:for(;;){for(var u=0;u<s.length;u++){var c=s[u];if(c.data.dedent&&!1!==c.data.dedentIfLineStart){var f=c.regex.exec(i);if(f&&f[0]){a--,(c.next||c.push)&&(s=t[c.next||c.push]),i=i.slice(f[0].length);continue e}}}break}return a<0?0:r.indent[a]}}e.defineSimpleMode=function(t,n){e.defineMode(t,(function(t){return e.simpleMode(t,n)}))},e.simpleMode=function(n,r){t(r,"start");var a={},s=r.meta||{},l=!1;for(var c in r)if(c!=s&&r.hasOwnProperty(c))for(var f=a[c]=[],p=r[c],d=0;d<p.length;d++){var h=p[d];f.push(new i(h,r)),(h.indent||h.dedent)&&(l=!0)}var g={startState:function(){return{state:"start",pending:null,local:null,localState:null,indent:l?[]:null}},copyState:function(t){var n={state:t.state,pending:t.pending,local:t.local,localState:null,indent:t.indent&&t.indent.slice(0)};t.localState&&(n.localState=e.copyState(t.local.mode,t.localState)),t.stack&&(n.stack=t.stack.slice(0));for(var r=t.persistentStates;r;r=r.next)n.persistentStates={mode:r.mode,spec:r.spec,state:r.state==t.localState?n.localState:e.copyState(r.mode,r.state),next:n.persistentStates};return n},token:o(a,n),innerMode:function(e){return e.local&&{mode:e.local.mode,state:e.localState}},indent:u(a,s)};if(s)for(var m in s)s.hasOwnProperty(m)&&(g[m]=s[m]);return g}}(Uu)})),Un((function(e,t){var n;(n=Uu).multiplexingMode=function(e){var t=Array.prototype.slice.call(arguments,1);function r(e,t,n,r){if("string"==typeof t){var i=e.indexOf(t,n);return r&&i>-1?i+t.length:i}var o=t.exec(n?e.slice(n):e);return o?o.index+n+(r?o[0].length:0):-1}return{startState:function(){return{outer:n.startState(e),innerActive:null,inner:null,startingInner:!1}},copyState:function(t){return{outer:n.copyState(e,t.outer),innerActive:t.innerActive,inner:t.innerActive&&n.copyState(t.innerActive.mode,t.inner),startingInner:t.startingInner}},token:function(i,o){if(o.innerActive){var a=o.innerActive;if(u=i.string,!a.close&&i.sol())return o.innerActive=o.inner=null,this.token(i,o);if((f=a.close&&!o.startingInner?r(u,a.close,i.pos,a.parseDelimiters):-1)==i.pos&&!a.parseDelimiters)return i.match(a.close),o.innerActive=o.inner=null,a.delimStyle&&a.delimStyle+" "+a.delimStyle+"-close";f>-1&&(i.string=u.slice(0,f));var s=a.mode.token(i,o.inner);return f>-1?i.string=u:i.pos>i.start&&(o.startingInner=!1),f==i.pos&&a.parseDelimiters&&(o.innerActive=o.inner=null),a.innerStyle&&(s=s?s+" "+a.innerStyle:a.innerStyle),s}for(var l=1/0,u=i.string,c=0;c<t.length;++c){var f,p=t[c];if((f=r(u,p.open,i.pos))==i.pos){p.parseDelimiters||i.match(p.open),o.startingInner=!!p.parseDelimiters,o.innerActive=p;var d=0;if(e.indent){var h=e.indent(o.outer,"","");h!==n.Pass&&(d=h)}return o.inner=n.startState(p.mode,d),p.delimStyle&&p.delimStyle+" "+p.delimStyle+"-open"}-1!=f&&f<l&&(l=f)}l!=1/0&&(i.string=u.slice(0,l));var g=e.token(i,o.outer);return l!=1/0&&(i.string=u),g},indent:function(t,r,i){var o=t.innerActive?t.innerActive.mode:e;return o.indent?o.indent(t.innerActive?t.inner:t.outer,r,i):n.Pass},blankLine:function(r){var i=r.innerActive?r.innerActive.mode:e;if(i.blankLine&&i.blankLine(r.innerActive?r.inner:r.outer),r.innerActive)"\n"===r.innerActive.close&&(r.innerActive=r.inner=null);else for(var o=0;o<t.length;++o){var a=t[o];"\n"===a.open&&(r.innerActive=a,r.inner=n.startState(a.mode,i.indent?i.indent(r.outer,"",""):0))}},electricChars:e.electricChars,innerMode:function(t){return t.inner?{state:t.inner,mode:t.innerActive.mode}:{state:t.outer,mode:e}}}}}));Un((function(e,t){var n;(n=Uu).defineSimpleMode("handlebars-tags",{start:[{regex:/\{\{\{/,push:"handlebars_raw",token:"tag"},{regex:/\{\{!--/,push:"dash_comment",token:"comment"},{regex:/\{\{!/,push:"comment",token:"comment"},{regex:/\{\{/,push:"handlebars",token:"tag"}],handlebars_raw:[{regex:/\}\}\}/,pop:!0,token:"tag"}],handlebars:[{regex:/\}\}/,pop:!0,token:"tag"},{regex:/"(?:[^\\"]|\\.)*"?/,token:"string"},{regex:/'(?:[^\\']|\\.)*'?/,token:"string"},{regex:/>|[#\/]([A-Za-z_]\w*)/,token:"keyword"},{regex:/(?:else|this)\b/,token:"keyword"},{regex:/\d+/i,token:"number"},{regex:/=|~|@|true|false/,token:"atom"},{regex:/(?:\.\.\/)*(?:[A-Za-z_][\w\.]*)+/,token:"variable-2"}],dash_comment:[{regex:/--\}\}/,pop:!0,token:"comment"},{regex:/./,token:"comment"}],comment:[{regex:/\}\}/,pop:!0,token:"comment"},{regex:/./,token:"comment"}],meta:{blockCommentStart:"{{--",blockCommentEnd:"--}}"}}),n.defineMode("handlebars",(function(e,t){var r=n.getMode(e,"handlebars-tags");return t&&t.base?n.multiplexingMode(n.getMode(e,t.base),{open:"{{",close:/\}\}\}?/,mode:r,parseDelimiters:!0}):r})),n.defineMIME("text/x-handlebars-template","handlebars")})),Un((function(e,t){var n;(n=Uu).defineMode("javascript",(function(e,t){var r,i,o=e.indentUnit,a=t.statementIndent,s=t.jsonld,l=t.json||s,u=t.typescript,c=t.wordCharacters||/[\w$\xa1-\uffff]/,f=function(){function e(e){return{type:e,style:"keyword"}}var t=e("keyword a"),n=e("keyword b"),r=e("keyword c"),i=e("keyword d"),o=e("operator"),a={type:"atom",style:"atom"};return{if:e("if"),while:t,with:t,else:n,do:n,try:n,finally:n,return:i,break:i,continue:i,new:e("new"),delete:r,void:r,throw:r,debugger:e("debugger"),var:e("var"),const:e("var"),let:e("var"),function:e("function"),catch:e("catch"),for:e("for"),switch:e("switch"),case:e("case"),default:e("default"),in:o,typeof:o,instanceof:o,true:a,false:a,null:a,undefined:a,NaN:a,Infinity:a,this:e("this"),class:e("class"),super:e("atom"),yield:r,export:e("export"),import:e("import"),extends:r,await:r}}(),p=/[+\-*&%=<>!?|~^@]/,d=/^@(context|id|value|language|type|container|list|set|reverse|index|base|vocab|graph)"/;function h(e){for(var t,n=!1,r=!1;null!=(t=e.next());){if(!n){if("/"==t&&!r)return;"["==t?r=!0:r&&"]"==t&&(r=!1)}n=!n&&"\\"==t}}function g(e,t,n){return r=e,i=n,t}function m(e,t){var n=e.next();if('"'==n||"'"==n)return t.tokenize=v(n),t.tokenize(e,t);if("."==n&&e.match(/^\d[\d_]*(?:[eE][+\-]?[\d_]+)?/))return g("number","number");if("."==n&&e.match(".."))return g("spread","meta");if(/[\[\]{}\(\),;\:\.]/.test(n))return g(n);if("="==n&&e.eat(">"))return g("=>","operator");if("0"==n&&e.match(/^(?:x[\dA-Fa-f_]+|o[0-7_]+|b[01_]+)n?/))return g("number","number");if(/\d/.test(n))return e.match(/^[\d_]*(?:n|(?:\.[\d_]*)?(?:[eE][+\-]?[\d_]+)?)?/),g("number","number");if("/"==n)return e.eat("*")?(t.tokenize=y,y(e,t)):e.eat("/")?(e.skipToEnd(),g("comment","comment")):tt(e,t,1)?(h(e),e.match(/^\b(([gimyus])(?![gimyus]*\2))+\b/),g("regexp","string-2")):(e.eat("="),g("operator","operator",e.current()));if("`"==n)return t.tokenize=b,b(e,t);if("#"==n&&"!"==e.peek())return e.skipToEnd(),g("meta","meta");if("#"==n&&e.eatWhile(c))return g("variable","property");if("<"==n&&e.match("!--")||"-"==n&&e.match("->")&&!/\S/.test(e.string.slice(0,e.start)))return e.skipToEnd(),g("comment","comment");if(p.test(n))return">"==n&&t.lexical&&">"==t.lexical.type||(e.eat("=")?"!"!=n&&"="!=n||e.eat("="):/[<>*+\-|&?]/.test(n)&&(e.eat(n),">"==n&&e.eat(n))),"?"==n&&e.eat(".")?g("."):g("operator","operator",e.current());if(c.test(n)){e.eatWhile(c);var r=e.current();if("."!=t.lastType){if(f.propertyIsEnumerable(r)){var i=f[r];return g(i.type,i.style,r)}if("async"==r&&e.match(/^(\s|\/\*([^*]|\*(?!\/))*?\*\/)*[\[\(\w]/,!1))return g("async","keyword",r)}return g("variable","variable",r)}}function v(e){return function(t,n){var r,i=!1;if(s&&"@"==t.peek()&&t.match(d))return n.tokenize=m,g("jsonld-keyword","meta");for(;null!=(r=t.next())&&(r!=e||i);)i=!i&&"\\"==r;return i||(n.tokenize=m),g("string","string")}}function y(e,t){for(var n,r=!1;n=e.next();){if("/"==n&&r){t.tokenize=m;break}r="*"==n}return g("comment","comment")}function b(e,t){for(var n,r=!1;null!=(n=e.next());){if(!r&&("`"==n||"$"==n&&e.eat("{"))){t.tokenize=m;break}r=!r&&"\\"==n}return g("quasi","string-2",e.current())}var _="([{}])";function w(e,t){t.fatArrowAt&&(t.fatArrowAt=null);var n=e.string.indexOf("=>",e.start);if(!(n<0)){if(u){var r=/:\s*(?:\w+(?:<[^>]*>|\[\])?|\{[^}]*\})\s*$/.exec(e.string.slice(e.start,n));r&&(n=r.index)}for(var i=0,o=!1,a=n-1;a>=0;--a){var s=e.string.charAt(a),l=_.indexOf(s);if(l>=0&&l<3){if(!i){++a;break}if(0==--i){"("==s&&(o=!0);break}}else if(l>=3&&l<6)++i;else if(c.test(s))o=!0;else if(/["'\/`]/.test(s))for(;;--a){if(0==a)return;if(e.string.charAt(a-1)==s&&"\\"!=e.string.charAt(a-2)){a--;break}}else if(o&&!i){++a;break}}o&&!i&&(t.fatArrowAt=a)}}var x={atom:!0,number:!0,variable:!0,string:!0,regexp:!0,this:!0,import:!0,"jsonld-keyword":!0};function k(e,t,n,r,i,o){this.indented=e,this.column=t,this.type=n,this.prev=i,this.info=o,null!=r&&(this.align=r)}function C(e,t){for(var n=e.localVars;n;n=n.next)if(n.name==t)return!0;for(var r=e.context;r;r=r.prev)for(n=r.vars;n;n=n.next)if(n.name==t)return!0}function E(e,t,n,r,i){var o=e.cc;for(O.state=e,O.stream=i,O.marked=null,O.cc=o,O.style=t,e.lexical.hasOwnProperty("align")||(e.lexical.align=!0);;)if((o.length?o.pop():l?H:B)(n,r)){for(;o.length&&o[o.length-1].lex;)o.pop()();return O.marked?O.marked:"variable"==n&&C(e,r)?"variable-2":t}}var O={state:null,column:null,marked:null,cc:null};function A(){for(var e=arguments.length-1;e>=0;e--)O.cc.push(arguments[e])}function S(){return A.apply(null,arguments),!0}function j(e,t){for(var n=t;n;n=n.next)if(n.name==e)return!0;return!1}function T(e){var n=O.state;if(O.marked="def",n.context)if("var"==n.lexical.info&&n.context&&n.context.block){var r=D(e,n.context);if(null!=r)return void(n.context=r)}else if(!j(e,n.localVars))return void(n.localVars=new M(e,n.localVars));t.globalVars&&!j(e,n.globalVars)&&(n.globalVars=new M(e,n.globalVars))}function D(e,t){if(t){if(t.block){var n=D(e,t.prev);return n?n==t.prev?t:new L(n,t.vars,!0):null}return j(e,t.vars)?t:new L(t.prev,new M(e,t.vars),!1)}return null}function N(e){return"public"==e||"private"==e||"protected"==e||"abstract"==e||"readonly"==e}function L(e,t,n){this.prev=e,this.vars=t,this.block=n}function M(e,t){this.name=e,this.next=t}var P=new M("this",new M("arguments",null));function F(){O.state.context=new L(O.state.context,O.state.localVars,!1),O.state.localVars=P}function q(){O.state.context=new L(O.state.context,O.state.localVars,!0),O.state.localVars=null}function I(){O.state.localVars=O.state.context.vars,O.state.context=O.state.context.prev}function $(e,t){var n=function(){var n=O.state,r=n.indented;if("stat"==n.lexical.type)r=n.lexical.indented;else for(var i=n.lexical;i&&")"==i.type&&i.align;i=i.prev)r=i.indented;n.lexical=new k(r,O.stream.column(),e,null,n.lexical,t)};return n.lex=!0,n}function R(){var e=O.state;e.lexical.prev&&(")"==e.lexical.type&&(e.indented=e.lexical.indented),e.lexical=e.lexical.prev)}function z(e){function t(n){return n==e?S():";"==e||"}"==n||")"==n||"]"==n?A():S(t)}return t}function B(e,t){return"var"==e?S($("vardef",t),Ee,z(";"),R):"keyword a"==e?S($("form"),V,B,R):"keyword b"==e?S($("form"),B,R):"keyword d"==e?O.stream.match(/^\s*$/,!1)?S():S($("stat"),Y,z(";"),R):"debugger"==e?S(z(";")):"{"==e?S($("}"),q,fe,R,I):";"==e?S():"if"==e?("else"==O.state.lexical.info&&O.state.cc[O.state.cc.length-1]==R&&O.state.cc.pop()(),S($("form"),V,B,R,De)):"function"==e?S(Pe):"for"==e?S($("form"),Ne,B,R):"class"==e||u&&"interface"==t?(O.marked="keyword",S($("form","class"==e?e:t),Re,R)):"variable"==e?u&&"declare"==t?(O.marked="keyword",S(B)):u&&("module"==t||"enum"==t||"type"==t)&&O.stream.match(/^\s*\w/,!1)?(O.marked="keyword","enum"==t?S(Je):"type"==t?S(qe,z("operator"),me,z(";")):S($("form"),Oe,z("{"),$("}"),fe,R,R)):u&&"namespace"==t?(O.marked="keyword",S($("form"),H,B,R)):u&&"abstract"==t?(O.marked="keyword",S(B)):S($("stat"),ie):"switch"==e?S($("form"),V,z("{"),$("}","switch"),q,fe,R,R,I):"case"==e?S(H,z(":")):"default"==e?S(z(":")):"catch"==e?S($("form"),F,W,B,R,I):"export"==e?S($("stat"),He,R):"import"==e?S($("stat"),Ve,R):"async"==e?S(B):"@"==t?S(H,B):A($("stat"),H,z(";"),R)}function W(e){if("("==e)return S(Ie,z(")"))}function H(e,t){return K(e,t,!1)}function U(e,t){return K(e,t,!0)}function V(e){return"("!=e?A():S($(")"),Y,z(")"),R)}function K(e,t,n){if(O.state.fatArrowAt==O.stream.start){var r=n?ee:Q;if("("==e)return S(F,$(")"),ue(Ie,")"),R,z("=>"),r,I);if("variable"==e)return A(F,Oe,z("=>"),r,I)}var i=n?Z:G;return x.hasOwnProperty(e)?S(i):"function"==e?S(Pe,i):"class"==e||u&&"interface"==t?(O.marked="keyword",S($("form"),$e,R)):"keyword c"==e||"async"==e?S(n?U:H):"("==e?S($(")"),Y,z(")"),R,i):"operator"==e||"spread"==e?S(n?U:H):"["==e?S($("]"),Xe,R,i):"{"==e?ce(ae,"}",null,i):"quasi"==e?A(X,i):"new"==e?S(te(n)):S()}function Y(e){return e.match(/[;\}\)\],]/)?A():A(H)}function G(e,t){return","==e?S(Y):Z(e,t,!1)}function Z(e,t,n){var r=0==n?G:Z,i=0==n?H:U;return"=>"==e?S(F,n?ee:Q,I):"operator"==e?/\+\+|--/.test(t)||u&&"!"==t?S(r):u&&"<"==t&&O.stream.match(/^([^<>]|<[^<>]*>)*>\s*\(/,!1)?S($(">"),ue(me,">"),R,r):"?"==t?S(H,z(":"),i):S(i):"quasi"==e?A(X,r):";"!=e?"("==e?ce(U,")","call",r):"."==e?S(oe,r):"["==e?S($("]"),Y,z("]"),R,r):u&&"as"==t?(O.marked="keyword",S(me,r)):"regexp"==e?(O.state.lastType=O.marked="operator",O.stream.backUp(O.stream.pos-O.stream.start-1),S(i)):void 0:void 0}function X(e,t){return"quasi"!=e?A():"${"!=t.slice(t.length-2)?S(X):S(H,J)}function J(e){if("}"==e)return O.marked="string-2",O.state.tokenize=b,S(X)}function Q(e){return w(O.stream,O.state),A("{"==e?B:H)}function ee(e){return w(O.stream,O.state),A("{"==e?B:U)}function te(e){return function(t){return"."==t?S(e?re:ne):"variable"==t&&u?S(xe,e?Z:G):A(e?U:H)}}function ne(e,t){if("target"==t)return O.marked="keyword",S(G)}function re(e,t){if("target"==t)return O.marked="keyword",S(Z)}function ie(e){return":"==e?S(R,B):A(G,z(";"),R)}function oe(e){if("variable"==e)return O.marked="property",S()}function ae(e,t){return"async"==e?(O.marked="property",S(ae)):"variable"==e||"keyword"==O.style?(O.marked="property","get"==t||"set"==t?S(se):(u&&O.state.fatArrowAt==O.stream.start&&(n=O.stream.match(/^\s*:\s*/,!1))&&(O.state.fatArrowAt=O.stream.pos+n[0].length),S(le))):"number"==e||"string"==e?(O.marked=s?"property":O.style+" property",S(le)):"jsonld-keyword"==e?S(le):u&&N(t)?(O.marked="keyword",S(ae)):"["==e?S(H,pe,z("]"),le):"spread"==e?S(U,le):"*"==t?(O.marked="keyword",S(ae)):":"==e?A(le):void 0;var n}function se(e){return"variable"!=e?A(le):(O.marked="property",S(Pe))}function le(e){return":"==e?S(U):"("==e?A(Pe):void 0}function ue(e,t,n){function r(i,o){if(n?n.indexOf(i)>-1:","==i){var a=O.state.lexical;return"call"==a.info&&(a.pos=(a.pos||0)+1),S((function(n,r){return n==t||r==t?A():A(e)}),r)}return i==t||o==t?S():n&&n.indexOf(";")>-1?A(e):S(z(t))}return function(n,i){return n==t||i==t?S():A(e,r)}}function ce(e,t,n){for(var r=3;r<arguments.length;r++)O.cc.push(arguments[r]);return S($(t,n),ue(e,t),R)}function fe(e){return"}"==e?S():A(B,fe)}function pe(e,t){if(u){if(":"==e)return S(me);if("?"==t)return S(pe)}}function de(e,t){if(u&&(":"==e||"in"==t))return S(me)}function he(e){if(u&&":"==e)return O.stream.match(/^\s*\w+\s+is\b/,!1)?S(H,ge,me):S(me)}function ge(e,t){if("is"==t)return O.marked="keyword",S()}function me(e,t){return"keyof"==t||"typeof"==t||"infer"==t||"readonly"==t?(O.marked="keyword",S("typeof"==t?U:me)):"variable"==e||"void"==t?(O.marked="type",S(we)):"|"==t||"&"==t?S(me):"string"==e||"number"==e||"atom"==e?S(we):"["==e?S($("]"),ue(me,"]",","),R,we):"{"==e?S($("}"),ye,R,we):"("==e?S(ue(_e,")"),ve,we):"<"==e?S(ue(me,">"),me):void 0}function ve(e){if("=>"==e)return S(me)}function ye(e){return e.match(/[\}\)\]]/)?S():","==e||";"==e?S(ye):A(be,ye)}function be(e,t){return"variable"==e||"keyword"==O.style?(O.marked="property",S(be)):"?"==t||"number"==e||"string"==e?S(be):":"==e?S(me):"["==e?S(z("variable"),de,z("]"),be):"("==e?A(Fe,be):e.match(/[;\}\)\],]/)?void 0:S()}function _e(e,t){return"variable"==e&&O.stream.match(/^\s*[?:]/,!1)||"?"==t?S(_e):":"==e?S(me):"spread"==e?S(_e):A(me)}function we(e,t){return"<"==t?S($(">"),ue(me,">"),R,we):"|"==t||"."==e||"&"==t?S(me):"["==e?S(me,z("]"),we):"extends"==t||"implements"==t?(O.marked="keyword",S(me)):"?"==t?S(me,z(":"),me):void 0}function xe(e,t){if("<"==t)return S($(">"),ue(me,">"),R,we)}function ke(){return A(me,Ce)}function Ce(e,t){if("="==t)return S(me)}function Ee(e,t){return"enum"==t?(O.marked="keyword",S(Je)):A(Oe,pe,je,Te)}function Oe(e,t){return u&&N(t)?(O.marked="keyword",S(Oe)):"variable"==e?(T(t),S()):"spread"==e?S(Oe):"["==e?ce(Se,"]"):"{"==e?ce(Ae,"}"):void 0}function Ae(e,t){return"variable"!=e||O.stream.match(/^\s*:/,!1)?("variable"==e&&(O.marked="property"),"spread"==e?S(Oe):"}"==e?A():"["==e?S(H,z("]"),z(":"),Ae):S(z(":"),Oe,je)):(T(t),S(je))}function Se(){return A(Oe,je)}function je(e,t){if("="==t)return S(U)}function Te(e){if(","==e)return S(Ee)}function De(e,t){if("keyword b"==e&&"else"==t)return S($("form","else"),B,R)}function Ne(e,t){return"await"==t?S(Ne):"("==e?S($(")"),Le,R):void 0}function Le(e){return"var"==e?S(Ee,Me):"variable"==e?S(Me):A(Me)}function Me(e,t){return")"==e?S():";"==e?S(Me):"in"==t||"of"==t?(O.marked="keyword",S(H,Me)):A(H,Me)}function Pe(e,t){return"*"==t?(O.marked="keyword",S(Pe)):"variable"==e?(T(t),S(Pe)):"("==e?S(F,$(")"),ue(Ie,")"),R,he,B,I):u&&"<"==t?S($(">"),ue(ke,">"),R,Pe):void 0}function Fe(e,t){return"*"==t?(O.marked="keyword",S(Fe)):"variable"==e?(T(t),S(Fe)):"("==e?S(F,$(")"),ue(Ie,")"),R,he,I):u&&"<"==t?S($(">"),ue(ke,">"),R,Fe):void 0}function qe(e,t){return"keyword"==e||"variable"==e?(O.marked="type",S(qe)):"<"==t?S($(">"),ue(ke,">"),R):void 0}function Ie(e,t){return"@"==t&&S(H,Ie),"spread"==e?S(Ie):u&&N(t)?(O.marked="keyword",S(Ie)):u&&"this"==e?S(pe,je):A(Oe,pe,je)}function $e(e,t){return"variable"==e?Re(e,t):ze(e,t)}function Re(e,t){if("variable"==e)return T(t),S(ze)}function ze(e,t){return"<"==t?S($(">"),ue(ke,">"),R,ze):"extends"==t||"implements"==t||u&&","==e?("implements"==t&&(O.marked="keyword"),S(u?me:H,ze)):"{"==e?S($("}"),Be,R):void 0}function Be(e,t){return"async"==e||"variable"==e&&("static"==t||"get"==t||"set"==t||u&&N(t))&&O.stream.match(/^\s+[\w$\xa1-\uffff]/,!1)?(O.marked="keyword",S(Be)):"variable"==e||"keyword"==O.style?(O.marked="property",S(We,Be)):"number"==e||"string"==e?S(We,Be):"["==e?S(H,pe,z("]"),We,Be):"*"==t?(O.marked="keyword",S(Be)):u&&"("==e?A(Fe,Be):";"==e||","==e?S(Be):"}"==e?S():"@"==t?S(H,Be):void 0}function We(e,t){if("?"==t)return S(We);if(":"==e)return S(me,je);if("="==t)return S(U);var n=O.state.lexical.prev;return A(n&&"interface"==n.info?Fe:Pe)}function He(e,t){return"*"==t?(O.marked="keyword",S(Ze,z(";"))):"default"==t?(O.marked="keyword",S(H,z(";"))):"{"==e?S(ue(Ue,"}"),Ze,z(";")):A(B)}function Ue(e,t){return"as"==t?(O.marked="keyword",S(z("variable"))):"variable"==e?A(U,Ue):void 0}function Ve(e){return"string"==e?S():"("==e?A(H):"."==e?A(G):A(Ke,Ye,Ze)}function Ke(e,t){return"{"==e?ce(Ke,"}"):("variable"==e&&T(t),"*"==t&&(O.marked="keyword"),S(Ge))}function Ye(e){if(","==e)return S(Ke,Ye)}function Ge(e,t){if("as"==t)return O.marked="keyword",S(Ke)}function Ze(e,t){if("from"==t)return O.marked="keyword",S(H)}function Xe(e){return"]"==e?S():A(ue(U,"]"))}function Je(){return A($("form"),Oe,z("{"),$("}"),ue(Qe,"}"),R,R)}function Qe(){return A(Oe,je)}function et(e,t){return"operator"==e.lastType||","==e.lastType||p.test(t.charAt(0))||/[,.]/.test(t.charAt(0))}function tt(e,t,n){return t.tokenize==m&&/^(?:operator|sof|keyword [bcd]|case|new|export|default|spread|[\[{}\(,;:]|=>)$/.test(t.lastType)||"quasi"==t.lastType&&/\{\s*$/.test(e.string.slice(0,e.pos-(n||0)))}return I.lex=!0,R.lex=!0,{startState:function(e){var n={tokenize:m,lastType:"sof",cc:[],lexical:new k((e||0)-o,0,"block",!1),localVars:t.localVars,context:t.localVars&&new L(null,null,!1),indented:e||0};return t.globalVars&&"object"==typeof t.globalVars&&(n.globalVars=t.globalVars),n},token:function(e,t){if(e.sol()&&(t.lexical.hasOwnProperty("align")||(t.lexical.align=!1),t.indented=e.indentation(),w(e,t)),t.tokenize!=y&&e.eatSpace())return null;var n=t.tokenize(e,t);return"comment"==r?n:(t.lastType="operator"!=r||"++"!=i&&"--"!=i?r:"incdec",E(t,n,r,i,e))},indent:function(e,r){if(e.tokenize==y||e.tokenize==b)return n.Pass;if(e.tokenize!=m)return 0;var i,s=r&&r.charAt(0),l=e.lexical;if(!/^\s*else\b/.test(r))for(var u=e.cc.length-1;u>=0;--u){var c=e.cc[u];if(c==R)l=l.prev;else if(c!=De)break}for(;("stat"==l.type||"form"==l.type)&&("}"==s||(i=e.cc[e.cc.length-1])&&(i==G||i==Z)&&!/^[,\.=+\-*:?[\(]/.test(r));)l=l.prev;a&&")"==l.type&&"stat"==l.prev.type&&(l=l.prev);var f=l.type,p=s==f;return"vardef"==f?l.indented+("operator"==e.lastType||","==e.lastType?l.info.length+1:0):"form"==f&&"{"==s?l.indented:"form"==f?l.indented+o:"stat"==f?l.indented+(et(e,r)?a||o:0):"switch"!=l.info||p||0==t.doubleIndentSwitch?l.align?l.column+(p?0:1):l.indented+(p?0:o):l.indented+(/^(?:case|default)\b/.test(r)?o:2*o)},electricInput:/^\s*(?:case .*?:|default:|\{|\})$/,blockCommentStart:l?null:"/*",blockCommentEnd:l?null:"*/",blockCommentContinue:l?null:" * ",lineComment:l?null:"//",fold:"brace",closeBrackets:"()[]{}''\"\"``",helperType:l?"json":"javascript",jsonldMode:s,jsonMode:l,expressionAllowed:tt,skipExpression:function(e){var t=e.cc[e.cc.length-1];t!=H&&t!=U||e.cc.pop()}}})),n.registerHelper("wordChars","javascript",/[\w$]/),n.defineMIME("text/javascript","javascript"),n.defineMIME("text/ecmascript","javascript"),n.defineMIME("application/javascript","javascript"),n.defineMIME("application/x-javascript","javascript"),n.defineMIME("application/ecmascript","javascript"),n.defineMIME("application/json",{name:"javascript",json:!0}),n.defineMIME("application/x-json",{name:"javascript",json:!0}),n.defineMIME("application/manifest+json",{name:"javascript",json:!0}),n.defineMIME("application/ld+json",{name:"javascript",jsonld:!0}),n.defineMIME("text/typescript",{name:"javascript",typescript:!0}),n.defineMIME("application/typescript",{name:"javascript",typescript:!0})})),Un((function(e,t){!function(e){var t="CodeMirror-hint",n="CodeMirror-hint-active";function r(e,t){if(this.cm=e,this.options=t,this.widget=null,this.debounce=0,this.tick=0,this.startPos=this.cm.getCursor("start"),this.startLen=this.cm.getLine(this.startPos.line).length-this.cm.getSelection().length,this.options.updateOnCursorActivity){var n=this;e.on("cursorActivity",this.activityFunc=function(){n.cursorActivity()})}}e.showHint=function(e,t,n){if(!t)return e.showHint(n);n&&n.async&&(t.async=!0);var r={hint:t};if(n)for(var i in n)r[i]=n[i];return e.showHint(r)},e.defineExtension("showHint",(function(t){t=a(this,this.getCursor("start"),t);var n=this.listSelections();if(!(n.length>1)){if(this.somethingSelected()){if(!t.hint.supportsSelection)return;for(var i=0;i<n.length;i++)if(n[i].head.line!=n[i].anchor.line)return}this.state.completionActive&&this.state.completionActive.close();var o=this.state.completionActive=new r(this,t);o.options.hint&&(e.signal(this,"startCompletion",this),o.update(!0))}})),e.defineExtension("closeHint",(function(){this.state.completionActive&&this.state.completionActive.close()}));var i=window.requestAnimationFrame||function(e){return setTimeout(e,1e3/60)},o=window.cancelAnimationFrame||clearTimeout;function a(e,t,n){var r=e.options.hintOptions,i={};for(var o in h)i[o]=h[o];if(r)for(var o in r)void 0!==r[o]&&(i[o]=r[o]);if(n)for(var o in n)void 0!==n[o]&&(i[o]=n[o]);return i.hint.resolve&&(i.hint=i.hint.resolve(e,t)),i}function s(e){return"string"==typeof e?e:e.text}function l(e,t){var n={Up:function(){t.moveFocus(-1)},Down:function(){t.moveFocus(1)},PageUp:function(){t.moveFocus(1-t.menuSize(),!0)},PageDown:function(){t.moveFocus(t.menuSize()-1,!0)},Home:function(){t.setFocus(0)},End:function(){t.setFocus(t.length-1)},Enter:t.pick,Tab:t.pick,Esc:t.close};/Mac/.test(navigator.platform)&&(n["Ctrl-P"]=function(){t.moveFocus(-1)},n["Ctrl-N"]=function(){t.moveFocus(1)});var r=e.options.customKeys,i=r?{}:n;function o(e,r){var o;o="string"!=typeof r?function(e){return r(e,t)}:n.hasOwnProperty(r)?n[r]:r,i[e]=o}if(r)for(var a in r)r.hasOwnProperty(a)&&o(a,r[a]);var s=e.options.extraKeys;if(s)for(var a in s)s.hasOwnProperty(a)&&o(a,s[a]);return i}function u(e,t){for(;t&&t!=e;){if("LI"===t.nodeName.toUpperCase()&&t.parentNode==e)return t;t=t.parentNode}}function c(r,i){this.completion=r,this.data=i,this.picked=!1;var o=this,a=r.cm,c=a.getInputField().ownerDocument,f=c.defaultView||c.parentWindow,p=this.hints=c.createElement("ul"),d=r.cm.options.theme;p.className="CodeMirror-hints "+d,this.selectedHint=i.selectedHint||0;for(var h=i.list,g=0;g<h.length;++g){var m=p.appendChild(c.createElement("li")),v=h[g],y=t+(g!=this.selectedHint?"":" "+n);null!=v.className&&(y=v.className+" "+y),m.className=y,v.render?v.render(m,i,v):m.appendChild(c.createTextNode(v.displayText||s(v))),m.hintId=g}var b=r.options.container||c.body,_=a.cursorCoords(r.options.alignWithWord?i.from:null),w=_.left,x=_.bottom,k=!0,C=0,E=0;if(b!==c.body){var O=-1!==["absolute","relative","fixed"].indexOf(f.getComputedStyle(b).position)?b:b.offsetParent,A=O.getBoundingClientRect(),S=c.body.getBoundingClientRect();C=A.left-S.left-O.scrollLeft,E=A.top-S.top-O.scrollTop}p.style.left=w-C+"px",p.style.top=x-E+"px";var j=f.innerWidth||Math.max(c.body.offsetWidth,c.documentElement.offsetWidth),T=f.innerHeight||Math.max(c.body.offsetHeight,c.documentElement.offsetHeight);b.appendChild(p);var D,N=r.options.moveOnOverlap?p.getBoundingClientRect():new DOMRect,L=!!r.options.paddingForScrollbar&&p.scrollHeight>p.clientHeight+1;if(setTimeout((function(){D=a.getScrollInfo()})),N.bottom-T>0){var M=N.bottom-N.top;if(_.top-(_.bottom-N.top)-M>0)p.style.top=(x=_.top-M-E)+"px",k=!1;else if(M>T){p.style.height=T-5+"px",p.style.top=(x=_.bottom-N.top-E)+"px";var P=a.getCursor();i.from.ch!=P.ch&&(_=a.cursorCoords(P),p.style.left=(w=_.left-C)+"px",N=p.getBoundingClientRect())}}var F,q=N.right-j;if(q>0&&(N.right-N.left>j&&(p.style.width=j-5+"px",q-=N.right-N.left-j),p.style.left=(w=_.left-q-C)+"px"),L)for(var I=p.firstChild;I;I=I.nextSibling)I.style.paddingRight=a.display.nativeBarWidth+"px";a.addKeyMap(this.keyMap=l(r,{moveFocus:function(e,t){o.changeActive(o.selectedHint+e,t)},setFocus:function(e){o.changeActive(e)},menuSize:function(){return o.screenAmount()},length:h.length,close:function(){r.close()},pick:function(){o.pick()},data:i})),r.options.closeOnUnfocus&&(a.on("blur",this.onBlur=function(){F=setTimeout((function(){r.close()}),100)}),a.on("focus",this.onFocus=function(){clearTimeout(F)})),a.on("scroll",this.onScroll=function(){var e=a.getScrollInfo(),t=a.getWrapperElement().getBoundingClientRect(),n=x+D.top-e.top,i=n-(f.pageYOffset||(c.documentElement||c.body).scrollTop);if(k||(i+=p.offsetHeight),i<=t.top||i>=t.bottom)return r.close();p.style.top=n+"px",p.style.left=w+D.left-e.left+"px"}),e.on(p,"dblclick",(function(e){var t=u(p,e.target||e.srcElement);t&&null!=t.hintId&&(o.changeActive(t.hintId),o.pick())})),e.on(p,"click",(function(e){var t=u(p,e.target||e.srcElement);t&&null!=t.hintId&&(o.changeActive(t.hintId),r.options.completeOnSingleClick&&o.pick())})),e.on(p,"mousedown",(function(){setTimeout((function(){a.focus()}),20)}));var $=this.getSelectedHintRange();return 0===$.from&&0===$.to||this.scrollToActive(),e.signal(i,"select",h[this.selectedHint],p.childNodes[this.selectedHint]),!0}function f(e,t){if(!e.somethingSelected())return t;for(var n=[],r=0;r<t.length;r++)t[r].supportsSelection&&n.push(t[r]);return n}function p(e,t,n,r){if(e.async)e(t,r,n);else{var i=e(t,n);i&&i.then?i.then(r):r(i)}}function d(t,n){var r,i=t.getHelpers(n,"hint");if(i.length){var o=function(e,t,n){var r=f(e,i);function o(i){if(i==r.length)return t(null);p(r[i],e,n,(function(e){e&&e.list.length>0?t(e):o(i+1)}))}o(0)};return o.async=!0,o.supportsSelection=!0,o}return(r=t.getHelper(t.getCursor(),"hintWords"))?function(t){return e.hint.fromList(t,{words:r})}:e.hint.anyword?function(t,n){return e.hint.anyword(t,n)}:function(){}}r.prototype={close:function(){this.active()&&(this.cm.state.completionActive=null,this.tick=null,this.options.updateOnCursorActivity&&this.cm.off("cursorActivity",this.activityFunc),this.widget&&this.data&&e.signal(this.data,"close"),this.widget&&this.widget.close(),e.signal(this.cm,"endCompletion",this.cm))},active:function(){return this.cm.state.completionActive==this},pick:function(t,n){var r=t.list[n],i=this;this.cm.operation((function(){r.hint?r.hint(i.cm,t,r):i.cm.replaceRange(s(r),r.from||t.from,r.to||t.to,"complete"),e.signal(t,"pick",r),i.cm.scrollIntoView()})),this.options.closeOnPick&&this.close()},cursorActivity:function(){this.debounce&&(o(this.debounce),this.debounce=0);var e=this.startPos;this.data&&(e=this.data.from);var t=this.cm.getCursor(),n=this.cm.getLine(t.line);if(t.line!=this.startPos.line||n.length-t.ch!=this.startLen-this.startPos.ch||t.ch<e.ch||this.cm.somethingSelected()||!t.ch||this.options.closeCharacters.test(n.charAt(t.ch-1)))this.close();else{var r=this;this.debounce=i((function(){r.update()})),this.widget&&this.widget.disable()}},update:function(e){if(null!=this.tick){var t=this,n=++this.tick;p(this.options.hint,this.cm,this.options,(function(r){t.tick==n&&t.finishUpdate(r,e)}))}},finishUpdate:function(t,n){this.data&&e.signal(this.data,"update");var r=this.widget&&this.widget.picked||n&&this.options.completeSingle;this.widget&&this.widget.close(),this.data=t,t&&t.list.length&&(r&&1==t.list.length?this.pick(t,0):(this.widget=new c(this,t),e.signal(t,"shown")))}},c.prototype={close:function(){if(this.completion.widget==this){this.completion.widget=null,this.hints.parentNode&&this.hints.parentNode.removeChild(this.hints),this.completion.cm.removeKeyMap(this.keyMap);var e=this.completion.cm;this.completion.options.closeOnUnfocus&&(e.off("blur",this.onBlur),e.off("focus",this.onFocus)),e.off("scroll",this.onScroll)}},disable:function(){this.completion.cm.removeKeyMap(this.keyMap);var e=this;this.keyMap={Enter:function(){e.picked=!0}},this.completion.cm.addKeyMap(this.keyMap)},pick:function(){this.completion.pick(this.data,this.selectedHint)},changeActive:function(t,r){if(t>=this.data.list.length?t=r?this.data.list.length-1:0:t<0&&(t=r?0:this.data.list.length-1),this.selectedHint!=t){var i=this.hints.childNodes[this.selectedHint];i&&(i.className=i.className.replace(" "+n,"")),(i=this.hints.childNodes[this.selectedHint=t]).className+=" "+n,this.scrollToActive(),e.signal(this.data,"select",this.data.list[this.selectedHint],i)}},scrollToActive:function(){var e=this.getSelectedHintRange(),t=this.hints.childNodes[e.from],n=this.hints.childNodes[e.to],r=this.hints.firstChild;t.offsetTop<this.hints.scrollTop?this.hints.scrollTop=t.offsetTop-r.offsetTop:n.offsetTop+n.offsetHeight>this.hints.scrollTop+this.hints.clientHeight&&(this.hints.scrollTop=n.offsetTop+n.offsetHeight-this.hints.clientHeight+r.offsetTop)},screenAmount:function(){return Math.floor(this.hints.clientHeight/this.hints.firstChild.offsetHeight)||1},getSelectedHintRange:function(){var e=this.completion.options.scrollMargin||0;return{from:Math.max(0,this.selectedHint-e),to:Math.min(this.data.list.length-1,this.selectedHint+e)}}},e.registerHelper("hint","auto",{resolve:d}),e.registerHelper("hint","fromList",(function(t,n){var r,i=t.getCursor(),o=t.getTokenAt(i),a=e.Pos(i.line,o.start),s=i;o.start<i.ch&&/\w/.test(o.string.charAt(i.ch-o.start-1))?r=o.string.substr(0,i.ch-o.start):(r="",a=i);for(var l=[],u=0;u<n.words.length;u++){var c=n.words[u];c.slice(0,r.length)==r&&l.push(c)}if(l.length)return{list:l,from:a,to:s}})),e.commands.autocomplete=e.showHint;var h={hint:e.hint.auto,completeSingle:!0,alignWithWord:!0,closeCharacters:/[\s()\[\]{};:>,]/,closeOnPick:!0,closeOnUnfocus:!0,updateOnCursorActivity:!0,completeOnSingleClick:!0,container:null,customKeys:null,extraKeys:null,paddingForScrollbar:!0,moveOnOverlap:!0};e.defineOption("hintOptions",null)}(Uu)}));function Vu(e){let t;return{c(){t=P("div"),this.h()},l(e){t=Y(e,"DIV",{class:!0,style:!0}),K(t).forEach(L),this.h()},h(){H(t,"class","circle svelte-14upwad"),Q(t,"--size",e[0]+e[2]),Q(t,"--color",e[1]),Q(t,"--duration",e[3])},m(e,n){N(e,t,n)},p(e,[n]){5&n&&Q(t,"--size",e[0]+e[2]),2&n&&Q(t,"--color",e[1]),8&n&&Q(t,"--duration",e[3])},i:a,o:a,d(e){e&&L(t)}}}function Ku(e,t,n){let{size:r=60}=t,{color:i="#FF3E00"}=t,{unit:o="px"}=t,{duration:a="0.75s"}=t;return e.$$set=e=>{"size"in e&&n(0,r=e.size),"color"in e&&n(1,i=e.color),"unit"in e&&n(2,o=e.unit),"duration"in e&&n(3,a=e.duration)},[r,i,o,a]}class Yu extends pt{constructor(e){super(),ft(this,e,Ku,Vu,d,{size:0,color:1,unit:2,duration:3})}}var Gu=Un((function(e,t){(function(){var n,r="Expected a function",i="__lodash_hash_undefined__",o="__lodash_placeholder__",a=16,s=32,l=64,u=128,c=256,f=1/0,p=9007199254740991,d=NaN,h=4294967295,g=[["ary",u],["bind",1],["bindKey",2],["curry",8],["curryRight",a],["flip",512],["partial",s],["partialRight",l],["rearg",c]],m="[object Arguments]",v="[object Array]",y="[object Boolean]",b="[object Date]",_="[object Error]",w="[object Function]",x="[object GeneratorFunction]",k="[object Map]",C="[object Number]",E="[object Object]",O="[object Promise]",A="[object RegExp]",S="[object Set]",j="[object String]",T="[object Symbol]",D="[object WeakMap]",N="[object ArrayBuffer]",L="[object DataView]",M="[object Float32Array]",P="[object Float64Array]",F="[object Int8Array]",q="[object Int16Array]",I="[object Int32Array]",$="[object Uint8Array]",R="[object Uint8ClampedArray]",z="[object Uint16Array]",B="[object Uint32Array]",W=/\b__p \+= '';/g,H=/\b(__p \+=) '' \+/g,U=/(__e\(.*?\)|\b__t\)) \+\n'';/g,V=/&(?:amp|lt|gt|quot|#39);/g,K=/[&<>"']/g,Y=RegExp(V.source),G=RegExp(K.source),Z=/<%-([\s\S]+?)%>/g,X=/<%([\s\S]+?)%>/g,J=/<%=([\s\S]+?)%>/g,Q=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,ee=/^\w*$/,te=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,ne=/[\\^$.*+?()[\]{}|]/g,re=RegExp(ne.source),ie=/^\s+|\s+$/g,oe=/^\s+/,ae=/\s+$/,se=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/,le=/\{\n\/\* \[wrapped with (.+)\] \*/,ue=/,? & /,ce=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g,fe=/\\(\\)?/g,pe=/\$\{([^\\}]*(?:\\.[^\\}]*)*)\}/g,de=/\w*$/,he=/^[-+]0x[0-9a-f]+$/i,ge=/^0b[01]+$/i,me=/^\[object .+?Constructor\]$/,ve=/^0o[0-7]+$/i,ye=/^(?:0|[1-9]\d*)$/,be=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,_e=/($^)/,we=/['\n\r\u2028\u2029\\]/g,xe="\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff",ke="\\u2700-\\u27bf",Ce="a-z\\xdf-\\xf6\\xf8-\\xff",Ee="A-Z\\xc0-\\xd6\\xd8-\\xde",Oe="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",Ae="[']",Se="[\\ud800-\\udfff]",je="["+Oe+"]",Te="["+xe+"]",De="\\d+",Ne="[\\u2700-\\u27bf]",Le="["+Ce+"]",Me="[^\\ud800-\\udfff"+Oe+De+ke+Ce+Ee+"]",Pe="\\ud83c[\\udffb-\\udfff]",Fe="[^\\ud800-\\udfff]",qe="(?:\\ud83c[\\udde6-\\uddff]){2}",Ie="[\\ud800-\\udbff][\\udc00-\\udfff]",$e="["+Ee+"]",Re="(?:"+Le+"|"+Me+")",ze="(?:"+$e+"|"+Me+")",Be="(?:['](?:d|ll|m|re|s|t|ve))?",We="(?:['](?:D|LL|M|RE|S|T|VE))?",He="(?:"+Te+"|"+Pe+")"+"?",Ue="[\\ufe0e\\ufe0f]?",Ve=Ue+He+("(?:\\u200d(?:"+[Fe,qe,Ie].join("|")+")"+Ue+He+")*"),Ke="(?:"+[Ne,qe,Ie].join("|")+")"+Ve,Ye="(?:"+[Fe+Te+"?",Te,qe,Ie,Se].join("|")+")",Ge=RegExp(Ae,"g"),Ze=RegExp(Te,"g"),Xe=RegExp(Pe+"(?="+Pe+")|"+Ye+Ve,"g"),Je=RegExp([$e+"?"+Le+"+"+Be+"(?="+[je,$e,"$"].join("|")+")",ze+"+"+We+"(?="+[je,$e+Re,"$"].join("|")+")",$e+"?"+Re+"+"+Be,$e+"+"+We,"\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",De,Ke].join("|"),"g"),Qe=RegExp("[\\u200d\\ud800-\\udfff"+xe+"\\ufe0e\\ufe0f]"),et=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/,tt=["Array","Buffer","DataView","Date","Error","Float32Array","Float64Array","Function","Int8Array","Int16Array","Int32Array","Map","Math","Object","Promise","RegExp","Set","String","Symbol","TypeError","Uint8Array","Uint8ClampedArray","Uint16Array","Uint32Array","WeakMap","_","clearTimeout","isFinite","parseInt","setTimeout"],nt=-1,rt={};rt[M]=rt[P]=rt[F]=rt[q]=rt[I]=rt[$]=rt[R]=rt[z]=rt[B]=!0,rt[m]=rt[v]=rt[N]=rt[y]=rt[L]=rt[b]=rt[_]=rt[w]=rt[k]=rt[C]=rt[E]=rt[A]=rt[S]=rt[j]=rt[D]=!1;var it={};it[m]=it[v]=it[N]=it[L]=it[y]=it[b]=it[M]=it[P]=it[F]=it[q]=it[I]=it[k]=it[C]=it[E]=it[A]=it[S]=it[j]=it[T]=it[$]=it[R]=it[z]=it[B]=!0,it[_]=it[w]=it[D]=!1;var ot={"\\":"\\","'":"'","\n":"n","\r":"r","\u2028":"u2028","\u2029":"u2029"},at=parseFloat,st=parseInt,lt="object"==typeof Bn&&Bn&&Bn.Object===Object&&Bn,ut="object"==typeof self&&self&&self.Object===Object&&self,ct=lt||ut||Function("return this")(),ft=t&&!t.nodeType&&t,pt=ft&&e&&!e.nodeType&&e,dt=pt&&pt.exports===ft,ht=dt&&lt.process,gt=function(){try{var e=pt&&pt.require&&pt.require("util").types;return e||ht&&ht.binding&&ht.binding("util")}catch(t){}}(),mt=gt&&gt.isArrayBuffer,vt=gt&&gt.isDate,yt=gt&&gt.isMap,bt=gt&&gt.isRegExp,_t=gt&&gt.isSet,wt=gt&&gt.isTypedArray;function xt(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)}function kt(e,t,n,r){for(var i=-1,o=null==e?0:e.length;++i<o;){var a=e[i];t(r,a,n(a),e)}return r}function Ct(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););return e}function Et(e,t){for(var n=null==e?0:e.length;n--&&!1!==t(e[n],n,e););return e}function Ot(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(!t(e[n],n,e))return!1;return!0}function At(e,t){for(var n=-1,r=null==e?0:e.length,i=0,o=[];++n<r;){var a=e[n];t(a,n,e)&&(o[i++]=a)}return o}function St(e,t){return!!(null==e?0:e.length)&&It(e,t,0)>-1}function jt(e,t,n){for(var r=-1,i=null==e?0:e.length;++r<i;)if(n(t,e[r]))return!0;return!1}function Tt(e,t){for(var n=-1,r=null==e?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}function Dt(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}function Nt(e,t,n,r){var i=-1,o=null==e?0:e.length;for(r&&o&&(n=e[++i]);++i<o;)n=t(n,e[i],i,e);return n}function Lt(e,t,n,r){var i=null==e?0:e.length;for(r&&i&&(n=e[--i]);i--;)n=t(n,e[i],i,e);return n}function Mt(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}var Pt=Bt("length");function Ft(e,t,n){var r;return n(e,(function(e,n,i){if(t(e,n,i))return r=n,!1})),r}function qt(e,t,n,r){for(var i=e.length,o=n+(r?1:-1);r?o--:++o<i;)if(t(e[o],o,e))return o;return-1}function It(e,t,n){return t==t?function(e,t,n){var r=n-1,i=e.length;for(;++r<i;)if(e[r]===t)return r;return-1}(e,t,n):qt(e,Rt,n)}function $t(e,t,n,r){for(var i=n-1,o=e.length;++i<o;)if(r(e[i],t))return i;return-1}function Rt(e){return e!=e}function zt(e,t){var n=null==e?0:e.length;return n?Ut(e,t)/n:d}function Bt(e){return function(t){return null==t?n:t[e]}}function Wt(e){return function(t){return null==e?n:e[t]}}function Ht(e,t,n,r,i){return i(e,(function(e,i,o){n=r?(r=!1,e):t(n,e,i,o)})),n}function Ut(e,t){for(var r,i=-1,o=e.length;++i<o;){var a=t(e[i]);a!==n&&(r=r===n?a:r+a)}return r}function Vt(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}function Kt(e){return function(t){return e(t)}}function Yt(e,t){return Tt(t,(function(t){return e[t]}))}function Gt(e,t){return e.has(t)}function Zt(e,t){for(var n=-1,r=e.length;++n<r&&It(t,e[n],0)>-1;);return n}function Xt(e,t){for(var n=e.length;n--&&It(t,e[n],0)>-1;);return n}function Jt(e,t){for(var n=e.length,r=0;n--;)e[n]===t&&++r;return r}var Qt=Wt({"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"}),en=Wt({"&":"&amp;","<":"&lt;",">":"&gt;",'"':"&quot;","'":"&#39;"});function tn(e){return"\\"+ot[e]}function nn(e){return Qe.test(e)}function rn(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n}function on(e,t){return function(n){return e(t(n))}}function an(e,t){for(var n=-1,r=e.length,i=0,a=[];++n<r;){var s=e[n];s!==t&&s!==o||(e[n]=o,a[i++]=n)}return a}function sn(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n}function ln(e){return nn(e)?function(e){var t=Xe.lastIndex=0;for(;Xe.test(e);)++t;return t}(e):Pt(e)}function un(e){return nn(e)?function(e){return e.match(Xe)||[]}(e):function(e){return e.split("")}(e)}var cn=Wt({"&amp;":"&","&lt;":"<","&gt;":">","&quot;":'"',"&#39;":"'"});var fn=function e(t){var xe,ke=(t=null==t?ct:fn.defaults(ct.Object(),t,fn.pick(ct,tt))).Array,Ce=t.Date,Ee=t.Error,Oe=t.Function,Ae=t.Math,Se=t.Object,je=t.RegExp,Te=t.String,De=t.TypeError,Ne=ke.prototype,Le=Oe.prototype,Me=Se.prototype,Pe=t["__core-js_shared__"],Fe=Le.toString,qe=Me.hasOwnProperty,Ie=0,$e=(xe=/[^.]+$/.exec(Pe&&Pe.keys&&Pe.keys.IE_PROTO||""))?"Symbol(src)_1."+xe:"",Re=Me.toString,ze=Fe.call(Se),Be=ct._,We=je("^"+Fe.call(qe).replace(ne,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$"),He=dt?t.Buffer:n,Ue=t.Symbol,Ve=t.Uint8Array,Ke=He?He.allocUnsafe:n,Ye=on(Se.getPrototypeOf,Se),Xe=Se.create,Qe=Me.propertyIsEnumerable,ot=Ne.splice,lt=Ue?Ue.isConcatSpreadable:n,ut=Ue?Ue.iterator:n,ft=Ue?Ue.toStringTag:n,pt=function(){try{var e=fo(Se,"defineProperty");return e({},"",{}),e}catch(t){}}(),ht=t.clearTimeout!==ct.clearTimeout&&t.clearTimeout,gt=Ce&&Ce.now!==ct.Date.now&&Ce.now,Pt=t.setTimeout!==ct.setTimeout&&t.setTimeout,Wt=Ae.ceil,pn=Ae.floor,dn=Se.getOwnPropertySymbols,hn=He?He.isBuffer:n,gn=t.isFinite,mn=Ne.join,vn=on(Se.keys,Se),yn=Ae.max,bn=Ae.min,_n=Ce.now,wn=t.parseInt,xn=Ae.random,kn=Ne.reverse,Cn=fo(t,"DataView"),En=fo(t,"Map"),On=fo(t,"Promise"),An=fo(t,"Set"),Sn=fo(t,"WeakMap"),jn=fo(Se,"create"),Tn=Sn&&new Sn,Dn={},Nn=Bo(Cn),Ln=Bo(En),Mn=Bo(On),Pn=Bo(An),Fn=Bo(Sn),qn=Ue?Ue.prototype:n,In=qn?qn.valueOf:n,$n=qn?qn.toString:n;function Rn(e){if(os(e)&&!Ya(e)&&!(e instanceof Hn)){if(e instanceof Wn)return e;if(qe.call(e,"__wrapped__"))return Wo(e)}return new Wn(e)}var zn=function(){function e(){}return function(t){if(!is(t))return{};if(Xe)return Xe(t);e.prototype=t;var r=new e;return e.prototype=n,r}}();function Bn(){}function Wn(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=n}function Hn(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=h,this.__views__=[]}function Un(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Vn(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Kn(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Yn(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new Kn;++t<n;)this.add(e[t])}function Gn(e){var t=this.__data__=new Vn(e);this.size=t.size}function Zn(e,t){var n=Ya(e),r=!n&&Ka(e),i=!n&&!r&&Ja(e),o=!n&&!r&&!i&&ds(e),a=n||r||i||o,s=a?Vt(e.length,Te):[],l=s.length;for(var u in e)!t&&!qe.call(e,u)||a&&("length"==u||i&&("offset"==u||"parent"==u)||o&&("buffer"==u||"byteLength"==u||"byteOffset"==u)||bo(u,l))||s.push(u);return s}function Xn(e){var t=e.length;return t?e[Yr(0,t-1)]:n}function Jn(e,t){return Fo(ji(e),sr(t,0,e.length))}function Qn(e){return Fo(ji(e))}function er(e,t,r){(r!==n&&!Ha(e[t],r)||r===n&&!(t in e))&&or(e,t,r)}function tr(e,t,r){var i=e[t];qe.call(e,t)&&Ha(i,r)&&(r!==n||t in e)||or(e,t,r)}function nr(e,t){for(var n=e.length;n--;)if(Ha(e[n][0],t))return n;return-1}function rr(e,t,n,r){return pr(e,(function(e,i,o){t(r,e,n(e),o)})),r}function ir(e,t){return e&&Ti(t,Ps(t),e)}function or(e,t,n){"__proto__"==t&&pt?pt(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}function ar(e,t){for(var r=-1,i=t.length,o=ke(i),a=null==e;++r<i;)o[r]=a?n:Ts(e,t[r]);return o}function sr(e,t,r){return e==e&&(r!==n&&(e=e<=r?e:r),t!==n&&(e=e>=t?e:t)),e}function lr(e,t,r,i,o,a){var s,l=1&t,u=2&t,c=4&t;if(r&&(s=o?r(e,i,o,a):r(e)),s!==n)return s;if(!is(e))return e;var f=Ya(e);if(f){if(s=function(e){var t=e.length,n=new e.constructor(t);t&&"string"==typeof e[0]&&qe.call(e,"index")&&(n.index=e.index,n.input=e.input);return n}(e),!l)return ji(e,s)}else{var p=go(e),d=p==w||p==x;if(Ja(e))return ki(e,l);if(p==E||p==m||d&&!o){if(s=u||d?{}:vo(e),!l)return u?function(e,t){return Ti(e,ho(e),t)}(e,function(e,t){return e&&Ti(t,Fs(t),e)}(s,e)):function(e,t){return Ti(e,po(e),t)}(e,ir(s,e))}else{if(!it[p])return o?e:{};s=function(e,t,n){var r=e.constructor;switch(t){case N:return Ci(e);case y:case b:return new r(+e);case L:return function(e,t){var n=t?Ci(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}(e,n);case M:case P:case F:case q:case I:case $:case R:case z:case B:return Ei(e,n);case k:return new r;case C:case j:return new r(e);case A:return function(e){var t=new e.constructor(e.source,de.exec(e));return t.lastIndex=e.lastIndex,t}(e);case S:return new r;case T:return i=e,In?Se(In.call(i)):{}}var i}(e,p,l)}}a||(a=new Gn);var h=a.get(e);if(h)return h;a.set(e,s),cs(e)?e.forEach((function(n){s.add(lr(n,t,r,n,e,a))})):as(e)&&e.forEach((function(n,i){s.set(i,lr(n,t,r,i,e,a))}));var g=f?n:(c?u?io:ro:u?Fs:Ps)(e);return Ct(g||e,(function(n,i){g&&(n=e[i=n]),tr(s,i,lr(n,t,r,i,e,a))})),s}function ur(e,t,r){var i=r.length;if(null==e)return!i;for(e=Se(e);i--;){var o=r[i],a=t[o],s=e[o];if(s===n&&!(o in e)||!a(s))return!1}return!0}function cr(e,t,i){if("function"!=typeof e)throw new De(r);return No((function(){e.apply(n,i)}),t)}function fr(e,t,n,r){var i=-1,o=St,a=!0,s=e.length,l=[],u=t.length;if(!s)return l;n&&(t=Tt(t,Kt(n))),r?(o=jt,a=!1):t.length>=200&&(o=Gt,a=!1,t=new Yn(t));e:for(;++i<s;){var c=e[i],f=null==n?c:n(c);if(c=r||0!==c?c:0,a&&f==f){for(var p=u;p--;)if(t[p]===f)continue e;l.push(c)}else o(t,f,r)||l.push(c)}return l}Rn.templateSettings={escape:Z,evaluate:X,interpolate:J,variable:"",imports:{_:Rn}},Rn.prototype=Bn.prototype,Rn.prototype.constructor=Rn,Wn.prototype=zn(Bn.prototype),Wn.prototype.constructor=Wn,Hn.prototype=zn(Bn.prototype),Hn.prototype.constructor=Hn,Un.prototype.clear=function(){this.__data__=jn?jn(null):{},this.size=0},Un.prototype.delete=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},Un.prototype.get=function(e){var t=this.__data__;if(jn){var r=t[e];return r===i?n:r}return qe.call(t,e)?t[e]:n},Un.prototype.has=function(e){var t=this.__data__;return jn?t[e]!==n:qe.call(t,e)},Un.prototype.set=function(e,t){var r=this.__data__;return this.size+=this.has(e)?0:1,r[e]=jn&&t===n?i:t,this},Vn.prototype.clear=function(){this.__data__=[],this.size=0},Vn.prototype.delete=function(e){var t=this.__data__,n=nr(t,e);return!(n<0)&&(n==t.length-1?t.pop():ot.call(t,n,1),--this.size,!0)},Vn.prototype.get=function(e){var t=this.__data__,r=nr(t,e);return r<0?n:t[r][1]},Vn.prototype.has=function(e){return nr(this.__data__,e)>-1},Vn.prototype.set=function(e,t){var n=this.__data__,r=nr(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this},Kn.prototype.clear=function(){this.size=0,this.__data__={hash:new Un,map:new(En||Vn),string:new Un}},Kn.prototype.delete=function(e){var t=uo(this,e).delete(e);return this.size-=t?1:0,t},Kn.prototype.get=function(e){return uo(this,e).get(e)},Kn.prototype.has=function(e){return uo(this,e).has(e)},Kn.prototype.set=function(e,t){var n=uo(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this},Yn.prototype.add=Yn.prototype.push=function(e){return this.__data__.set(e,i),this},Yn.prototype.has=function(e){return this.__data__.has(e)},Gn.prototype.clear=function(){this.__data__=new Vn,this.size=0},Gn.prototype.delete=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n},Gn.prototype.get=function(e){return this.__data__.get(e)},Gn.prototype.has=function(e){return this.__data__.has(e)},Gn.prototype.set=function(e,t){var n=this.__data__;if(n instanceof Vn){var r=n.__data__;if(!En||r.length<199)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new Kn(r)}return n.set(e,t),this.size=n.size,this};var pr=Li(_r),dr=Li(wr,!0);function hr(e,t){var n=!0;return pr(e,(function(e,r,i){return n=!!t(e,r,i)})),n}function gr(e,t,r){for(var i=-1,o=e.length;++i<o;){var a=e[i],s=t(a);if(null!=s&&(l===n?s==s&&!ps(s):r(s,l)))var l=s,u=a}return u}function mr(e,t){var n=[];return pr(e,(function(e,r,i){t(e,r,i)&&n.push(e)})),n}function vr(e,t,n,r,i){var o=-1,a=e.length;for(n||(n=yo),i||(i=[]);++o<a;){var s=e[o];t>0&&n(s)?t>1?vr(s,t-1,n,r,i):Dt(i,s):r||(i[i.length]=s)}return i}var yr=Mi(),br=Mi(!0);function _r(e,t){return e&&yr(e,t,Ps)}function wr(e,t){return e&&br(e,t,Ps)}function xr(e,t){return At(t,(function(t){return ts(e[t])}))}function kr(e,t){for(var r=0,i=(t=bi(t,e)).length;null!=e&&r<i;)e=e[zo(t[r++])];return r&&r==i?e:n}function Cr(e,t,n){var r=t(e);return Ya(e)?r:Dt(r,n(e))}function Er(e){return null==e?e===n?"[object Undefined]":"[object Null]":ft&&ft in Se(e)?function(e){var t=qe.call(e,ft),r=e[ft];try{e[ft]=n;var i=!0}catch(a){}var o=Re.call(e);i&&(t?e[ft]=r:delete e[ft]);return o}(e):function(e){return Re.call(e)}(e)}function Or(e,t){return e>t}function Ar(e,t){return null!=e&&qe.call(e,t)}function Sr(e,t){return null!=e&&t in Se(e)}function jr(e,t,r){for(var i=r?jt:St,o=e[0].length,a=e.length,s=a,l=ke(a),u=1/0,c=[];s--;){var f=e[s];s&&t&&(f=Tt(f,Kt(t))),u=bn(f.length,u),l[s]=!r&&(t||o>=120&&f.length>=120)?new Yn(s&&f):n}f=e[0];var p=-1,d=l[0];e:for(;++p<o&&c.length<u;){var h=f[p],g=t?t(h):h;if(h=r||0!==h?h:0,!(d?Gt(d,g):i(c,g,r))){for(s=a;--s;){var m=l[s];if(!(m?Gt(m,g):i(e[s],g,r)))continue e}d&&d.push(g),c.push(h)}}return c}function Tr(e,t,r){var i=null==(e=So(e,t=bi(t,e)))?e:e[zo(ea(t))];return null==i?n:xt(i,e,r)}function Dr(e){return os(e)&&Er(e)==m}function Nr(e,t,r,i,o){return e===t||(null==e||null==t||!os(e)&&!os(t)?e!=e&&t!=t:function(e,t,r,i,o,a){var s=Ya(e),l=Ya(t),u=s?v:go(e),c=l?v:go(t),f=(u=u==m?E:u)==E,p=(c=c==m?E:c)==E,d=u==c;if(d&&Ja(e)){if(!Ja(t))return!1;s=!0,f=!1}if(d&&!f)return a||(a=new Gn),s||ds(e)?to(e,t,r,i,o,a):function(e,t,n,r,i,o,a){switch(n){case L:if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case N:return!(e.byteLength!=t.byteLength||!o(new Ve(e),new Ve(t)));case y:case b:case C:return Ha(+e,+t);case _:return e.name==t.name&&e.message==t.message;case A:case j:return e==t+"";case k:var s=rn;case S:var l=1&r;if(s||(s=sn),e.size!=t.size&&!l)return!1;var u=a.get(e);if(u)return u==t;r|=2,a.set(e,t);var c=to(s(e),s(t),r,i,o,a);return a.delete(e),c;case T:if(In)return In.call(e)==In.call(t)}return!1}(e,t,u,r,i,o,a);if(!(1&r)){var h=f&&qe.call(e,"__wrapped__"),g=p&&qe.call(t,"__wrapped__");if(h||g){var w=h?e.value():e,x=g?t.value():t;return a||(a=new Gn),o(w,x,r,i,a)}}if(!d)return!1;return a||(a=new Gn),function(e,t,r,i,o,a){var s=1&r,l=ro(e),u=l.length,c=ro(t).length;if(u!=c&&!s)return!1;var f=u;for(;f--;){var p=l[f];if(!(s?p in t:qe.call(t,p)))return!1}var d=a.get(e);if(d&&a.get(t))return d==t;var h=!0;a.set(e,t),a.set(t,e);var g=s;for(;++f<u;){var m=e[p=l[f]],v=t[p];if(i)var y=s?i(v,m,p,t,e,a):i(m,v,p,e,t,a);if(!(y===n?m===v||o(m,v,r,i,a):y)){h=!1;break}g||(g="constructor"==p)}if(h&&!g){var b=e.constructor,_=t.constructor;b==_||!("constructor"in e)||!("constructor"in t)||"function"==typeof b&&b instanceof b&&"function"==typeof _&&_ instanceof _||(h=!1)}return a.delete(e),a.delete(t),h}(e,t,r,i,o,a)}(e,t,r,i,Nr,o))}function Lr(e,t,r,i){var o=r.length,a=o,s=!i;if(null==e)return!a;for(e=Se(e);o--;){var l=r[o];if(s&&l[2]?l[1]!==e[l[0]]:!(l[0]in e))return!1}for(;++o<a;){var u=(l=r[o])[0],c=e[u],f=l[1];if(s&&l[2]){if(c===n&&!(u in e))return!1}else{var p=new Gn;if(i)var d=i(c,f,u,e,t,p);if(!(d===n?Nr(f,c,3,i,p):d))return!1}}return!0}function Mr(e){return!(!is(e)||(t=e,$e&&$e in t))&&(ts(e)?We:me).test(Bo(e));var t}function Pr(e){return"function"==typeof e?e:null==e?sl:"object"==typeof e?Ya(e)?zr(e[0],e[1]):Rr(e):ml(e)}function Fr(e){if(!Co(e))return vn(e);var t=[];for(var n in Se(e))qe.call(e,n)&&"constructor"!=n&&t.push(n);return t}function qr(e){if(!is(e))return function(e){var t=[];if(null!=e)for(var n in Se(e))t.push(n);return t}(e);var t=Co(e),n=[];for(var r in e)("constructor"!=r||!t&&qe.call(e,r))&&n.push(r);return n}function Ir(e,t){return e<t}function $r(e,t){var n=-1,r=Za(e)?ke(e.length):[];return pr(e,(function(e,i,o){r[++n]=t(e,i,o)})),r}function Rr(e){var t=co(e);return 1==t.length&&t[0][2]?Oo(t[0][0],t[0][1]):function(n){return n===e||Lr(n,e,t)}}function zr(e,t){return wo(e)&&Eo(t)?Oo(zo(e),t):function(r){var i=Ts(r,e);return i===n&&i===t?Ds(r,e):Nr(t,i,3)}}function Br(e,t,r,i,o){e!==t&&yr(t,(function(a,s){if(o||(o=new Gn),is(a))!function(e,t,r,i,o,a,s){var l=To(e,r),u=To(t,r),c=s.get(u);if(c)return void er(e,r,c);var f=a?a(l,u,r+"",e,t,s):n,p=f===n;if(p){var d=Ya(u),h=!d&&Ja(u),g=!d&&!h&&ds(u);f=u,d||h||g?Ya(l)?f=l:Xa(l)?f=ji(l):h?(p=!1,f=ki(u,!0)):g?(p=!1,f=Ei(u,!0)):f=[]:ls(u)||Ka(u)?(f=l,Ka(l)?f=ws(l):is(l)&&!ts(l)||(f=vo(u))):p=!1}p&&(s.set(u,f),o(f,u,i,a,s),s.delete(u));er(e,r,f)}(e,t,s,r,Br,i,o);else{var l=i?i(To(e,s),a,s+"",e,t,o):n;l===n&&(l=a),er(e,s,l)}}),Fs)}function Wr(e,t){var r=e.length;if(r)return bo(t+=t<0?r:0,r)?e[t]:n}function Hr(e,t,n){var r=-1;return t=Tt(t.length?t:[sl],Kt(lo())),function(e,t){var n=e.length;for(e.sort(t);n--;)e[n]=e[n].value;return e}($r(e,(function(e,n,i){return{criteria:Tt(t,(function(t){return t(e)})),index:++r,value:e}})),(function(e,t){return function(e,t,n){var r=-1,i=e.criteria,o=t.criteria,a=i.length,s=n.length;for(;++r<a;){var l=Oi(i[r],o[r]);if(l)return r>=s?l:l*("desc"==n[r]?-1:1)}return e.index-t.index}(e,t,n)}))}function Ur(e,t,n){for(var r=-1,i=t.length,o={};++r<i;){var a=t[r],s=kr(e,a);n(s,a)&&Qr(o,bi(a,e),s)}return o}function Vr(e,t,n,r){var i=r?$t:It,o=-1,a=t.length,s=e;for(e===t&&(t=ji(t)),n&&(s=Tt(e,Kt(n)));++o<a;)for(var l=0,u=t[o],c=n?n(u):u;(l=i(s,c,l,r))>-1;)s!==e&&ot.call(s,l,1),ot.call(e,l,1);return e}function Kr(e,t){for(var n=e?t.length:0,r=n-1;n--;){var i=t[n];if(n==r||i!==o){var o=i;bo(i)?ot.call(e,i,1):fi(e,i)}}return e}function Yr(e,t){return e+pn(xn()*(t-e+1))}function Gr(e,t){var n="";if(!e||t<1||t>p)return n;do{t%2&&(n+=e),(t=pn(t/2))&&(e+=e)}while(t);return n}function Zr(e,t){return Lo(Ao(e,t,sl),e+"")}function Xr(e){return Xn(Hs(e))}function Jr(e,t){var n=Hs(e);return Fo(n,sr(t,0,n.length))}function Qr(e,t,r,i){if(!is(e))return e;for(var o=-1,a=(t=bi(t,e)).length,s=a-1,l=e;null!=l&&++o<a;){var u=zo(t[o]),c=r;if(o!=s){var f=l[u];(c=i?i(f,u,l):n)===n&&(c=is(f)?f:bo(t[o+1])?[]:{})}tr(l,u,c),l=l[u]}return e}var ei=Tn?function(e,t){return Tn.set(e,t),e}:sl,ti=pt?function(e,t){return pt(e,"toString",{configurable:!0,enumerable:!1,value:il(t),writable:!0})}:sl;function ni(e){return Fo(Hs(e))}function ri(e,t,n){var r=-1,i=e.length;t<0&&(t=-t>i?0:i+t),(n=n>i?i:n)<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var o=ke(i);++r<i;)o[r]=e[r+t];return o}function ii(e,t){var n;return pr(e,(function(e,r,i){return!(n=t(e,r,i))})),!!n}function oi(e,t,n){var r=0,i=null==e?r:e.length;if("number"==typeof t&&t==t&&i<=2147483647){for(;r<i;){var o=r+i>>>1,a=e[o];null!==a&&!ps(a)&&(n?a<=t:a<t)?r=o+1:i=o}return i}return ai(e,t,sl,n)}function ai(e,t,r,i){t=r(t);for(var o=0,a=null==e?0:e.length,s=t!=t,l=null===t,u=ps(t),c=t===n;o<a;){var f=pn((o+a)/2),p=r(e[f]),d=p!==n,h=null===p,g=p==p,m=ps(p);if(s)var v=i||g;else v=c?g&&(i||d):l?g&&d&&(i||!h):u?g&&d&&!h&&(i||!m):!h&&!m&&(i?p<=t:p<t);v?o=f+1:a=f}return bn(a,4294967294)}function si(e,t){for(var n=-1,r=e.length,i=0,o=[];++n<r;){var a=e[n],s=t?t(a):a;if(!n||!Ha(s,l)){var l=s;o[i++]=0===a?0:a}}return o}function li(e){return"number"==typeof e?e:ps(e)?d:+e}function ui(e){if("string"==typeof e)return e;if(Ya(e))return Tt(e,ui)+"";if(ps(e))return $n?$n.call(e):"";var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function ci(e,t,n){var r=-1,i=St,o=e.length,a=!0,s=[],l=s;if(n)a=!1,i=jt;else if(o>=200){var u=t?null:Gi(e);if(u)return sn(u);a=!1,i=Gt,l=new Yn}else l=t?[]:s;e:for(;++r<o;){var c=e[r],f=t?t(c):c;if(c=n||0!==c?c:0,a&&f==f){for(var p=l.length;p--;)if(l[p]===f)continue e;t&&l.push(f),s.push(c)}else i(l,f,n)||(l!==s&&l.push(f),s.push(c))}return s}function fi(e,t){return null==(e=So(e,t=bi(t,e)))||delete e[zo(ea(t))]}function pi(e,t,n,r){return Qr(e,t,n(kr(e,t)),r)}function di(e,t,n,r){for(var i=e.length,o=r?i:-1;(r?o--:++o<i)&&t(e[o],o,e););return n?ri(e,r?0:o,r?o+1:i):ri(e,r?o+1:0,r?i:o)}function hi(e,t){var n=e;return n instanceof Hn&&(n=n.value()),Nt(t,(function(e,t){return t.func.apply(t.thisArg,Dt([e],t.args))}),n)}function gi(e,t,n){var r=e.length;if(r<2)return r?ci(e[0]):[];for(var i=-1,o=ke(r);++i<r;)for(var a=e[i],s=-1;++s<r;)s!=i&&(o[i]=fr(o[i]||a,e[s],t,n));return ci(vr(o,1),t,n)}function mi(e,t,r){for(var i=-1,o=e.length,a=t.length,s={};++i<o;){var l=i<a?t[i]:n;r(s,e[i],l)}return s}function vi(e){return Xa(e)?e:[]}function yi(e){return"function"==typeof e?e:sl}function bi(e,t){return Ya(e)?e:wo(e,t)?[e]:Ro(xs(e))}var _i=Zr;function wi(e,t,r){var i=e.length;return r=r===n?i:r,!t&&r>=i?e:ri(e,t,r)}var xi=ht||function(e){return ct.clearTimeout(e)};function ki(e,t){if(t)return e.slice();var n=e.length,r=Ke?Ke(n):new e.constructor(n);return e.copy(r),r}function Ci(e){var t=new e.constructor(e.byteLength);return new Ve(t).set(new Ve(e)),t}function Ei(e,t){var n=t?Ci(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}function Oi(e,t){if(e!==t){var r=e!==n,i=null===e,o=e==e,a=ps(e),s=t!==n,l=null===t,u=t==t,c=ps(t);if(!l&&!c&&!a&&e>t||a&&s&&u&&!l&&!c||i&&s&&u||!r&&u||!o)return 1;if(!i&&!a&&!c&&e<t||c&&r&&o&&!i&&!a||l&&r&&o||!s&&o||!u)return-1}return 0}function Ai(e,t,n,r){for(var i=-1,o=e.length,a=n.length,s=-1,l=t.length,u=yn(o-a,0),c=ke(l+u),f=!r;++s<l;)c[s]=t[s];for(;++i<a;)(f||i<o)&&(c[n[i]]=e[i]);for(;u--;)c[s++]=e[i++];return c}function Si(e,t,n,r){for(var i=-1,o=e.length,a=-1,s=n.length,l=-1,u=t.length,c=yn(o-s,0),f=ke(c+u),p=!r;++i<c;)f[i]=e[i];for(var d=i;++l<u;)f[d+l]=t[l];for(;++a<s;)(p||i<o)&&(f[d+n[a]]=e[i++]);return f}function ji(e,t){var n=-1,r=e.length;for(t||(t=ke(r));++n<r;)t[n]=e[n];return t}function Ti(e,t,r,i){var o=!r;r||(r={});for(var a=-1,s=t.length;++a<s;){var l=t[a],u=i?i(r[l],e[l],l,r,e):n;u===n&&(u=e[l]),o?or(r,l,u):tr(r,l,u)}return r}function Di(e,t){return function(n,r){var i=Ya(n)?kt:rr,o=t?t():{};return i(n,e,lo(r,2),o)}}function Ni(e){return Zr((function(t,r){var i=-1,o=r.length,a=o>1?r[o-1]:n,s=o>2?r[2]:n;for(a=e.length>3&&"function"==typeof a?(o--,a):n,s&&_o(r[0],r[1],s)&&(a=o<3?n:a,o=1),t=Se(t);++i<o;){var l=r[i];l&&e(t,l,i,a)}return t}))}function Li(e,t){return function(n,r){if(null==n)return n;if(!Za(n))return e(n,r);for(var i=n.length,o=t?i:-1,a=Se(n);(t?o--:++o<i)&&!1!==r(a[o],o,a););return n}}function Mi(e){return function(t,n,r){for(var i=-1,o=Se(t),a=r(t),s=a.length;s--;){var l=a[e?s:++i];if(!1===n(o[l],l,o))break}return t}}function Pi(e){return function(t){var r=nn(t=xs(t))?un(t):n,i=r?r[0]:t.charAt(0),o=r?wi(r,1).join(""):t.slice(1);return i[e]()+o}}function Fi(e){return function(t){return Nt(tl(Ks(t).replace(Ge,"")),e,"")}}function qi(e){return function(){var t=arguments;switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3]);case 5:return new e(t[0],t[1],t[2],t[3],t[4]);case 6:return new e(t[0],t[1],t[2],t[3],t[4],t[5]);case 7:return new e(t[0],t[1],t[2],t[3],t[4],t[5],t[6])}var n=zn(e.prototype),r=e.apply(n,t);return is(r)?r:n}}function Ii(e){return function(t,r,i){var o=Se(t);if(!Za(t)){var a=lo(r,3);t=Ps(t),r=function(e){return a(o[e],e,o)}}var s=e(t,r,i);return s>-1?o[a?t[s]:s]:n}}function $i(e){return no((function(t){var i=t.length,o=i,a=Wn.prototype.thru;for(e&&t.reverse();o--;){var s=t[o];if("function"!=typeof s)throw new De(r);if(a&&!l&&"wrapper"==ao(s))var l=new Wn([],!0)}for(o=l?o:i;++o<i;){var u=ao(s=t[o]),c="wrapper"==u?oo(s):n;l=c&&xo(c[0])&&424==c[1]&&!c[4].length&&1==c[9]?l[ao(c[0])].apply(l,c[3]):1==s.length&&xo(s)?l[u]():l.thru(s)}return function(){var e=arguments,n=e[0];if(l&&1==e.length&&Ya(n))return l.plant(n).value();for(var r=0,o=i?t[r].apply(this,e):n;++r<i;)o=t[r].call(this,o);return o}}))}function Ri(e,t,r,i,o,a,s,l,c,f){var p=t&u,d=1&t,h=2&t,g=24&t,m=512&t,v=h?n:qi(e);return function n(){for(var u=arguments.length,y=ke(u),b=u;b--;)y[b]=arguments[b];if(g)var _=so(n),w=Jt(y,_);if(i&&(y=Ai(y,i,o,g)),a&&(y=Si(y,a,s,g)),u-=w,g&&u<f){var x=an(y,_);return Ki(e,t,Ri,n.placeholder,r,y,x,l,c,f-u)}var k=d?r:this,C=h?k[e]:e;return u=y.length,l?y=jo(y,l):m&&u>1&&y.reverse(),p&&c<u&&(y.length=c),this&&this!==ct&&this instanceof n&&(C=v||qi(C)),C.apply(k,y)}}function zi(e,t){return function(n,r){return function(e,t,n,r){return _r(e,(function(e,i,o){t(r,n(e),i,o)})),r}(n,e,t(r),{})}}function Bi(e,t){return function(r,i){var o;if(r===n&&i===n)return t;if(r!==n&&(o=r),i!==n){if(o===n)return i;"string"==typeof r||"string"==typeof i?(r=ui(r),i=ui(i)):(r=li(r),i=li(i)),o=e(r,i)}return o}}function Wi(e){return no((function(t){return t=Tt(t,Kt(lo())),Zr((function(n){var r=this;return e(t,(function(e){return xt(e,r,n)}))}))}))}function Hi(e,t){var r=(t=t===n?" ":ui(t)).length;if(r<2)return r?Gr(t,e):t;var i=Gr(t,Wt(e/ln(t)));return nn(t)?wi(un(i),0,e).join(""):i.slice(0,e)}function Ui(e){return function(t,r,i){return i&&"number"!=typeof i&&_o(t,r,i)&&(r=i=n),t=vs(t),r===n?(r=t,t=0):r=vs(r),function(e,t,n,r){for(var i=-1,o=yn(Wt((t-e)/(n||1)),0),a=ke(o);o--;)a[r?o:++i]=e,e+=n;return a}(t,r,i=i===n?t<r?1:-1:vs(i),e)}}function Vi(e){return function(t,n){return"string"==typeof t&&"string"==typeof n||(t=_s(t),n=_s(n)),e(t,n)}}function Ki(e,t,r,i,o,a,u,c,f,p){var d=8&t;t|=d?s:l,4&(t&=~(d?l:s))||(t&=-4);var h=[e,t,o,d?a:n,d?u:n,d?n:a,d?n:u,c,f,p],g=r.apply(n,h);return xo(e)&&Do(g,h),g.placeholder=i,Mo(g,e,t)}function Yi(e){var t=Ae[e];return function(e,n){if(e=_s(e),(n=null==n?0:bn(ys(n),292))&&gn(e)){var r=(xs(e)+"e").split("e");return+((r=(xs(t(r[0]+"e"+(+r[1]+n)))+"e").split("e"))[0]+"e"+(+r[1]-n))}return t(e)}}var Gi=An&&1/sn(new An([,-0]))[1]==f?function(e){return new An(e)}:pl;function Zi(e){return function(t){var n=go(t);return n==k?rn(t):n==S?function(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=[e,e]})),n}(t):function(e,t){return Tt(t,(function(t){return[t,e[t]]}))}(t,e(t))}}function Xi(e,t,i,f,p,d,h,g){var m=2&t;if(!m&&"function"!=typeof e)throw new De(r);var v=f?f.length:0;if(v||(t&=-97,f=p=n),h=h===n?h:yn(ys(h),0),g=g===n?g:ys(g),v-=p?p.length:0,t&l){var y=f,b=p;f=p=n}var _=m?n:oo(e),w=[e,t,i,f,p,y,b,d,h,g];if(_&&function(e,t){var n=e[1],r=t[1],i=n|r,a=i<131,s=r==u&&8==n||r==u&&n==c&&e[7].length<=t[8]||384==r&&t[7].length<=t[8]&&8==n;if(!a&&!s)return e;1&r&&(e[2]=t[2],i|=1&n?0:4);var l=t[3];if(l){var f=e[3];e[3]=f?Ai(f,l,t[4]):l,e[4]=f?an(e[3],o):t[4]}(l=t[5])&&(f=e[5],e[5]=f?Si(f,l,t[6]):l,e[6]=f?an(e[5],o):t[6]);(l=t[7])&&(e[7]=l);r&u&&(e[8]=null==e[8]?t[8]:bn(e[8],t[8]));null==e[9]&&(e[9]=t[9]);e[0]=t[0],e[1]=i}(w,_),e=w[0],t=w[1],i=w[2],f=w[3],p=w[4],!(g=w[9]=w[9]===n?m?0:e.length:yn(w[9]-v,0))&&24&t&&(t&=-25),t&&1!=t)x=8==t||t==a?function(e,t,r){var i=qi(e);return function o(){for(var a=arguments.length,s=ke(a),l=a,u=so(o);l--;)s[l]=arguments[l];var c=a<3&&s[0]!==u&&s[a-1]!==u?[]:an(s,u);return(a-=c.length)<r?Ki(e,t,Ri,o.placeholder,n,s,c,n,n,r-a):xt(this&&this!==ct&&this instanceof o?i:e,this,s)}}(e,t,g):t!=s&&33!=t||p.length?Ri.apply(n,w):function(e,t,n,r){var i=1&t,o=qi(e);return function t(){for(var a=-1,s=arguments.length,l=-1,u=r.length,c=ke(u+s),f=this&&this!==ct&&this instanceof t?o:e;++l<u;)c[l]=r[l];for(;s--;)c[l++]=arguments[++a];return xt(f,i?n:this,c)}}(e,t,i,f);else var x=function(e,t,n){var r=1&t,i=qi(e);return function t(){return(this&&this!==ct&&this instanceof t?i:e).apply(r?n:this,arguments)}}(e,t,i);return Mo((_?ei:Do)(x,w),e,t)}function Ji(e,t,r,i){return e===n||Ha(e,Me[r])&&!qe.call(i,r)?t:e}function Qi(e,t,r,i,o,a){return is(e)&&is(t)&&(a.set(t,e),Br(e,t,n,Qi,a),a.delete(t)),e}function eo(e){return ls(e)?n:e}function to(e,t,r,i,o,a){var s=1&r,l=e.length,u=t.length;if(l!=u&&!(s&&u>l))return!1;var c=a.get(e);if(c&&a.get(t))return c==t;var f=-1,p=!0,d=2&r?new Yn:n;for(a.set(e,t),a.set(t,e);++f<l;){var h=e[f],g=t[f];if(i)var m=s?i(g,h,f,t,e,a):i(h,g,f,e,t,a);if(m!==n){if(m)continue;p=!1;break}if(d){if(!Mt(t,(function(e,t){if(!Gt(d,t)&&(h===e||o(h,e,r,i,a)))return d.push(t)}))){p=!1;break}}else if(h!==g&&!o(h,g,r,i,a)){p=!1;break}}return a.delete(e),a.delete(t),p}function no(e){return Lo(Ao(e,n,Go),e+"")}function ro(e){return Cr(e,Ps,po)}function io(e){return Cr(e,Fs,ho)}var oo=Tn?function(e){return Tn.get(e)}:pl;function ao(e){for(var t=e.name+"",n=Dn[t],r=qe.call(Dn,t)?n.length:0;r--;){var i=n[r],o=i.func;if(null==o||o==e)return i.name}return t}function so(e){return(qe.call(Rn,"placeholder")?Rn:e).placeholder}function lo(){var e=Rn.iteratee||ll;return e=e===ll?Pr:e,arguments.length?e(arguments[0],arguments[1]):e}function uo(e,t){var n=e.__data__;return function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}(t)?n["string"==typeof t?"string":"hash"]:n.map}function co(e){for(var t=Ps(e),n=t.length;n--;){var r=t[n],i=e[r];t[n]=[r,i,Eo(i)]}return t}function fo(e,t){var r=function(e,t){return null==e?n:e[t]}(e,t);return Mr(r)?r:n}var po=dn?function(e){return null==e?[]:(e=Se(e),At(dn(e),(function(t){return Qe.call(e,t)})))}:bl,ho=dn?function(e){for(var t=[];e;)Dt(t,po(e)),e=Ye(e);return t}:bl,go=Er;function mo(e,t,n){for(var r=-1,i=(t=bi(t,e)).length,o=!1;++r<i;){var a=zo(t[r]);if(!(o=null!=e&&n(e,a)))break;e=e[a]}return o||++r!=i?o:!!(i=null==e?0:e.length)&&rs(i)&&bo(a,i)&&(Ya(e)||Ka(e))}function vo(e){return"function"!=typeof e.constructor||Co(e)?{}:zn(Ye(e))}function yo(e){return Ya(e)||Ka(e)||!!(lt&&e&&e[lt])}function bo(e,t){var n=typeof e;return!!(t=null==t?p:t)&&("number"==n||"symbol"!=n&&ye.test(e))&&e>-1&&e%1==0&&e<t}function _o(e,t,n){if(!is(n))return!1;var r=typeof t;return!!("number"==r?Za(n)&&bo(t,n.length):"string"==r&&t in n)&&Ha(n[t],e)}function wo(e,t){if(Ya(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!ps(e))||(ee.test(e)||!Q.test(e)||null!=t&&e in Se(t))}function xo(e){var t=ao(e),n=Rn[t];if("function"!=typeof n||!(t in Hn.prototype))return!1;if(e===n)return!0;var r=oo(n);return!!r&&e===r[0]}(Cn&&go(new Cn(new ArrayBuffer(1)))!=L||En&&go(new En)!=k||On&&go(On.resolve())!=O||An&&go(new An)!=S||Sn&&go(new Sn)!=D)&&(go=function(e){var t=Er(e),r=t==E?e.constructor:n,i=r?Bo(r):"";if(i)switch(i){case Nn:return L;case Ln:return k;case Mn:return O;case Pn:return S;case Fn:return D}return t});var ko=Pe?ts:_l;function Co(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||Me)}function Eo(e){return e==e&&!is(e)}function Oo(e,t){return function(r){return null!=r&&(r[e]===t&&(t!==n||e in Se(r)))}}function Ao(e,t,r){return t=yn(t===n?e.length-1:t,0),function(){for(var n=arguments,i=-1,o=yn(n.length-t,0),a=ke(o);++i<o;)a[i]=n[t+i];i=-1;for(var s=ke(t+1);++i<t;)s[i]=n[i];return s[t]=r(a),xt(e,this,s)}}function So(e,t){return t.length<2?e:kr(e,ri(t,0,-1))}function jo(e,t){for(var r=e.length,i=bn(t.length,r),o=ji(e);i--;){var a=t[i];e[i]=bo(a,r)?o[a]:n}return e}function To(e,t){if(("constructor"!==t||"function"!=typeof e[t])&&"__proto__"!=t)return e[t]}var Do=Po(ei),No=Pt||function(e,t){return ct.setTimeout(e,t)},Lo=Po(ti);function Mo(e,t,n){var r=t+"";return Lo(e,function(e,t){var n=t.length;if(!n)return e;var r=n-1;return t[r]=(n>1?"& ":"")+t[r],t=t.join(n>2?", ":" "),e.replace(se,"{\n/* [wrapped with "+t+"] */\n")}(r,function(e,t){return Ct(g,(function(n){var r="_."+n[0];t&n[1]&&!St(e,r)&&e.push(r)})),e.sort()}(function(e){var t=e.match(le);return t?t[1].split(ue):[]}(r),n)))}function Po(e){var t=0,r=0;return function(){var i=_n(),o=16-(i-r);if(r=i,o>0){if(++t>=800)return arguments[0]}else t=0;return e.apply(n,arguments)}}function Fo(e,t){var r=-1,i=e.length,o=i-1;for(t=t===n?i:t;++r<t;){var a=Yr(r,o),s=e[a];e[a]=e[r],e[r]=s}return e.length=t,e}var qo,Io,$o,Ro=(qo=function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(te,(function(e,n,r,i){t.push(r?i.replace(fe,"$1"):n||e)})),t},Io=Ia(qo,(function(e){return 500===$o.size&&$o.clear(),e})),$o=Io.cache,Io);function zo(e){if("string"==typeof e||ps(e))return e;var t=e+"";return"0"==t&&1/e==-1/0?"-0":t}function Bo(e){if(null!=e){try{return Fe.call(e)}catch(t){}try{return e+""}catch(t){}}return""}function Wo(e){if(e instanceof Hn)return e.clone();var t=new Wn(e.__wrapped__,e.__chain__);return t.__actions__=ji(e.__actions__),t.__index__=e.__index__,t.__values__=e.__values__,t}var Ho=Zr((function(e,t){return Xa(e)?fr(e,vr(t,1,Xa,!0)):[]})),Uo=Zr((function(e,t){var r=ea(t);return Xa(r)&&(r=n),Xa(e)?fr(e,vr(t,1,Xa,!0),lo(r,2)):[]})),Vo=Zr((function(e,t){var r=ea(t);return Xa(r)&&(r=n),Xa(e)?fr(e,vr(t,1,Xa,!0),n,r):[]}));function Ko(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var i=null==n?0:ys(n);return i<0&&(i=yn(r+i,0)),qt(e,lo(t,3),i)}function Yo(e,t,r){var i=null==e?0:e.length;if(!i)return-1;var o=i-1;return r!==n&&(o=ys(r),o=r<0?yn(i+o,0):bn(o,i-1)),qt(e,lo(t,3),o,!0)}function Go(e){return(null==e?0:e.length)?vr(e,1):[]}function Zo(e){return e&&e.length?e[0]:n}var Xo=Zr((function(e){var t=Tt(e,vi);return t.length&&t[0]===e[0]?jr(t):[]})),Jo=Zr((function(e){var t=ea(e),r=Tt(e,vi);return t===ea(r)?t=n:r.pop(),r.length&&r[0]===e[0]?jr(r,lo(t,2)):[]})),Qo=Zr((function(e){var t=ea(e),r=Tt(e,vi);return(t="function"==typeof t?t:n)&&r.pop(),r.length&&r[0]===e[0]?jr(r,n,t):[]}));function ea(e){var t=null==e?0:e.length;return t?e[t-1]:n}var ta=Zr(na);function na(e,t){return e&&e.length&&t&&t.length?Vr(e,t):e}var ra=no((function(e,t){var n=null==e?0:e.length,r=ar(e,t);return Kr(e,Tt(t,(function(e){return bo(e,n)?+e:e})).sort(Oi)),r}));function ia(e){return null==e?e:kn.call(e)}var oa=Zr((function(e){return ci(vr(e,1,Xa,!0))})),aa=Zr((function(e){var t=ea(e);return Xa(t)&&(t=n),ci(vr(e,1,Xa,!0),lo(t,2))})),sa=Zr((function(e){var t=ea(e);return t="function"==typeof t?t:n,ci(vr(e,1,Xa,!0),n,t)}));function la(e){if(!e||!e.length)return[];var t=0;return e=At(e,(function(e){if(Xa(e))return t=yn(e.length,t),!0})),Vt(t,(function(t){return Tt(e,Bt(t))}))}function ua(e,t){if(!e||!e.length)return[];var r=la(e);return null==t?r:Tt(r,(function(e){return xt(t,n,e)}))}var ca=Zr((function(e,t){return Xa(e)?fr(e,t):[]})),fa=Zr((function(e){return gi(At(e,Xa))})),pa=Zr((function(e){var t=ea(e);return Xa(t)&&(t=n),gi(At(e,Xa),lo(t,2))})),da=Zr((function(e){var t=ea(e);return t="function"==typeof t?t:n,gi(At(e,Xa),n,t)})),ha=Zr(la);var ga=Zr((function(e){var t=e.length,r=t>1?e[t-1]:n;return r="function"==typeof r?(e.pop(),r):n,ua(e,r)}));function ma(e){var t=Rn(e);return t.__chain__=!0,t}function va(e,t){return t(e)}var ya=no((function(e){var t=e.length,r=t?e[0]:0,i=this.__wrapped__,o=function(t){return ar(t,e)};return!(t>1||this.__actions__.length)&&i instanceof Hn&&bo(r)?((i=i.slice(r,+r+(t?1:0))).__actions__.push({func:va,args:[o],thisArg:n}),new Wn(i,this.__chain__).thru((function(e){return t&&!e.length&&e.push(n),e}))):this.thru(o)}));var ba=Di((function(e,t,n){qe.call(e,n)?++e[n]:or(e,n,1)}));var _a=Ii(Ko),wa=Ii(Yo);function xa(e,t){return(Ya(e)?Ct:pr)(e,lo(t,3))}function ka(e,t){return(Ya(e)?Et:dr)(e,lo(t,3))}var Ca=Di((function(e,t,n){qe.call(e,n)?e[n].push(t):or(e,n,[t])}));var Ea=Zr((function(e,t,n){var r=-1,i="function"==typeof t,o=Za(e)?ke(e.length):[];return pr(e,(function(e){o[++r]=i?xt(t,e,n):Tr(e,t,n)})),o})),Oa=Di((function(e,t,n){or(e,n,t)}));function Aa(e,t){return(Ya(e)?Tt:$r)(e,lo(t,3))}var Sa=Di((function(e,t,n){e[n?0:1].push(t)}),(function(){return[[],[]]}));var ja=Zr((function(e,t){if(null==e)return[];var n=t.length;return n>1&&_o(e,t[0],t[1])?t=[]:n>2&&_o(t[0],t[1],t[2])&&(t=[t[0]]),Hr(e,vr(t,1),[])})),Ta=gt||function(){return ct.Date.now()};function Da(e,t,r){return t=r?n:t,t=e&&null==t?e.length:t,Xi(e,u,n,n,n,n,t)}function Na(e,t){var i;if("function"!=typeof t)throw new De(r);return e=ys(e),function(){return--e>0&&(i=t.apply(this,arguments)),e<=1&&(t=n),i}}var La=Zr((function(e,t,n){var r=1;if(n.length){var i=an(n,so(La));r|=s}return Xi(e,r,t,n,i)})),Ma=Zr((function(e,t,n){var r=3;if(n.length){var i=an(n,so(Ma));r|=s}return Xi(t,r,e,n,i)}));function Pa(e,t,i){var o,a,s,l,u,c,f=0,p=!1,d=!1,h=!0;if("function"!=typeof e)throw new De(r);function g(t){var r=o,i=a;return o=a=n,f=t,l=e.apply(i,r)}function m(e){return f=e,u=No(y,t),p?g(e):l}function v(e){var r=e-c;return c===n||r>=t||r<0||d&&e-f>=s}function y(){var e=Ta();if(v(e))return b(e);u=No(y,function(e){var n=t-(e-c);return d?bn(n,s-(e-f)):n}(e))}function b(e){return u=n,h&&o?g(e):(o=a=n,l)}function _(){var e=Ta(),r=v(e);if(o=arguments,a=this,c=e,r){if(u===n)return m(c);if(d)return xi(u),u=No(y,t),g(c)}return u===n&&(u=No(y,t)),l}return t=_s(t)||0,is(i)&&(p=!!i.leading,s=(d="maxWait"in i)?yn(_s(i.maxWait)||0,t):s,h="trailing"in i?!!i.trailing:h),_.cancel=function(){u!==n&&xi(u),f=0,o=c=a=u=n},_.flush=function(){return u===n?l:b(Ta())},_}var Fa=Zr((function(e,t){return cr(e,1,t)})),qa=Zr((function(e,t,n){return cr(e,_s(t)||0,n)}));function Ia(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new De(r);var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var a=e.apply(this,r);return n.cache=o.set(i,a)||o,a};return n.cache=new(Ia.Cache||Kn),n}function $a(e){if("function"!=typeof e)throw new De(r);return function(){var t=arguments;switch(t.length){case 0:return!e.call(this);case 1:return!e.call(this,t[0]);case 2:return!e.call(this,t[0],t[1]);case 3:return!e.call(this,t[0],t[1],t[2])}return!e.apply(this,t)}}Ia.Cache=Kn;var Ra=_i((function(e,t){var n=(t=1==t.length&&Ya(t[0])?Tt(t[0],Kt(lo())):Tt(vr(t,1),Kt(lo()))).length;return Zr((function(r){for(var i=-1,o=bn(r.length,n);++i<o;)r[i]=t[i].call(this,r[i]);return xt(e,this,r)}))})),za=Zr((function(e,t){var r=an(t,so(za));return Xi(e,s,n,t,r)})),Ba=Zr((function(e,t){var r=an(t,so(Ba));return Xi(e,l,n,t,r)})),Wa=no((function(e,t){return Xi(e,c,n,n,n,t)}));function Ha(e,t){return e===t||e!=e&&t!=t}var Ua=Vi(Or),Va=Vi((function(e,t){return e>=t})),Ka=Dr(function(){return arguments}())?Dr:function(e){return os(e)&&qe.call(e,"callee")&&!Qe.call(e,"callee")},Ya=ke.isArray,Ga=mt?Kt(mt):function(e){return os(e)&&Er(e)==N};function Za(e){return null!=e&&rs(e.length)&&!ts(e)}function Xa(e){return os(e)&&Za(e)}var Ja=hn||_l,Qa=vt?Kt(vt):function(e){return os(e)&&Er(e)==b};function es(e){if(!os(e))return!1;var t=Er(e);return t==_||"[object DOMException]"==t||"string"==typeof e.message&&"string"==typeof e.name&&!ls(e)}function ts(e){if(!is(e))return!1;var t=Er(e);return t==w||t==x||"[object AsyncFunction]"==t||"[object Proxy]"==t}function ns(e){return"number"==typeof e&&e==ys(e)}function rs(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=p}function is(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function os(e){return null!=e&&"object"==typeof e}var as=yt?Kt(yt):function(e){return os(e)&&go(e)==k};function ss(e){return"number"==typeof e||os(e)&&Er(e)==C}function ls(e){if(!os(e)||Er(e)!=E)return!1;var t=Ye(e);if(null===t)return!0;var n=qe.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&Fe.call(n)==ze}var us=bt?Kt(bt):function(e){return os(e)&&Er(e)==A};var cs=_t?Kt(_t):function(e){return os(e)&&go(e)==S};function fs(e){return"string"==typeof e||!Ya(e)&&os(e)&&Er(e)==j}function ps(e){return"symbol"==typeof e||os(e)&&Er(e)==T}var ds=wt?Kt(wt):function(e){return os(e)&&rs(e.length)&&!!rt[Er(e)]};var hs=Vi(Ir),gs=Vi((function(e,t){return e<=t}));function ms(e){if(!e)return[];if(Za(e))return fs(e)?un(e):ji(e);if(ut&&e[ut])return function(e){for(var t,n=[];!(t=e.next()).done;)n.push(t.value);return n}(e[ut]());var t=go(e);return(t==k?rn:t==S?sn:Hs)(e)}function vs(e){return e?(e=_s(e))===f||e===-1/0?17976931348623157e292*(e<0?-1:1):e==e?e:0:0===e?e:0}function ys(e){var t=vs(e),n=t%1;return t==t?n?t-n:t:0}function bs(e){return e?sr(ys(e),0,h):0}function _s(e){if("number"==typeof e)return e;if(ps(e))return d;if(is(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=is(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(ie,"");var n=ge.test(e);return n||ve.test(e)?st(e.slice(2),n?2:8):he.test(e)?d:+e}function ws(e){return Ti(e,Fs(e))}function xs(e){return null==e?"":ui(e)}var ks=Ni((function(e,t){if(Co(t)||Za(t))Ti(t,Ps(t),e);else for(var n in t)qe.call(t,n)&&tr(e,n,t[n])})),Cs=Ni((function(e,t){Ti(t,Fs(t),e)})),Es=Ni((function(e,t,n,r){Ti(t,Fs(t),e,r)})),Os=Ni((function(e,t,n,r){Ti(t,Ps(t),e,r)})),As=no(ar);var Ss=Zr((function(e,t){e=Se(e);var r=-1,i=t.length,o=i>2?t[2]:n;for(o&&_o(t[0],t[1],o)&&(i=1);++r<i;)for(var a=t[r],s=Fs(a),l=-1,u=s.length;++l<u;){var c=s[l],f=e[c];(f===n||Ha(f,Me[c])&&!qe.call(e,c))&&(e[c]=a[c])}return e})),js=Zr((function(e){return e.push(n,Qi),xt(Is,n,e)}));function Ts(e,t,r){var i=null==e?n:kr(e,t);return i===n?r:i}function Ds(e,t){return null!=e&&mo(e,t,Sr)}var Ns=zi((function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=Re.call(t)),e[t]=n}),il(sl)),Ls=zi((function(e,t,n){null!=t&&"function"!=typeof t.toString&&(t=Re.call(t)),qe.call(e,t)?e[t].push(n):e[t]=[n]}),lo),Ms=Zr(Tr);function Ps(e){return Za(e)?Zn(e):Fr(e)}function Fs(e){return Za(e)?Zn(e,!0):qr(e)}var qs=Ni((function(e,t,n){Br(e,t,n)})),Is=Ni((function(e,t,n,r){Br(e,t,n,r)})),$s=no((function(e,t){var n={};if(null==e)return n;var r=!1;t=Tt(t,(function(t){return t=bi(t,e),r||(r=t.length>1),t})),Ti(e,io(e),n),r&&(n=lr(n,7,eo));for(var i=t.length;i--;)fi(n,t[i]);return n}));var Rs=no((function(e,t){return null==e?{}:function(e,t){return Ur(e,t,(function(t,n){return Ds(e,n)}))}(e,t)}));function zs(e,t){if(null==e)return{};var n=Tt(io(e),(function(e){return[e]}));return t=lo(t),Ur(e,n,(function(e,n){return t(e,n[0])}))}var Bs=Zi(Ps),Ws=Zi(Fs);function Hs(e){return null==e?[]:Yt(e,Ps(e))}var Us=Fi((function(e,t,n){return t=t.toLowerCase(),e+(n?Vs(t):t)}));function Vs(e){return el(xs(e).toLowerCase())}function Ks(e){return(e=xs(e))&&e.replace(be,Qt).replace(Ze,"")}var Ys=Fi((function(e,t,n){return e+(n?"-":"")+t.toLowerCase()})),Gs=Fi((function(e,t,n){return e+(n?" ":"")+t.toLowerCase()})),Zs=Pi("toLowerCase");var Xs=Fi((function(e,t,n){return e+(n?"_":"")+t.toLowerCase()}));var Js=Fi((function(e,t,n){return e+(n?" ":"")+el(t)}));var Qs=Fi((function(e,t,n){return e+(n?" ":"")+t.toUpperCase()})),el=Pi("toUpperCase");function tl(e,t,r){return e=xs(e),(t=r?n:t)===n?function(e){return et.test(e)}(e)?function(e){return e.match(Je)||[]}(e):function(e){return e.match(ce)||[]}(e):e.match(t)||[]}var nl=Zr((function(e,t){try{return xt(e,n,t)}catch(r){return es(r)?r:new Ee(r)}})),rl=no((function(e,t){return Ct(t,(function(t){t=zo(t),or(e,t,La(e[t],e))})),e}));function il(e){return function(){return e}}var ol=$i(),al=$i(!0);function sl(e){return e}function ll(e){return Pr("function"==typeof e?e:lr(e,1))}var ul=Zr((function(e,t){return function(n){return Tr(n,e,t)}})),cl=Zr((function(e,t){return function(n){return Tr(e,n,t)}}));function fl(e,t,n){var r=Ps(t),i=xr(t,r);null!=n||is(t)&&(i.length||!r.length)||(n=t,t=e,e=this,i=xr(t,Ps(t)));var o=!(is(n)&&"chain"in n&&!n.chain),a=ts(e);return Ct(i,(function(n){var r=t[n];e[n]=r,a&&(e.prototype[n]=function(){var t=this.__chain__;if(o||t){var n=e(this.__wrapped__),i=n.__actions__=ji(this.__actions__);return i.push({func:r,args:arguments,thisArg:e}),n.__chain__=t,n}return r.apply(e,Dt([this.value()],arguments))})})),e}function pl(){}var dl=Wi(Tt),hl=Wi(Ot),gl=Wi(Mt);function ml(e){return wo(e)?Bt(zo(e)):function(e){return function(t){return kr(t,e)}}(e)}var vl=Ui(),yl=Ui(!0);function bl(){return[]}function _l(){return!1}var wl=Bi((function(e,t){return e+t}),0),xl=Yi("ceil"),kl=Bi((function(e,t){return e/t}),1),Cl=Yi("floor");var El,Ol=Bi((function(e,t){return e*t}),1),Al=Yi("round"),Sl=Bi((function(e,t){return e-t}),0);return Rn.after=function(e,t){if("function"!=typeof t)throw new De(r);return e=ys(e),function(){if(--e<1)return t.apply(this,arguments)}},Rn.ary=Da,Rn.assign=ks,Rn.assignIn=Cs,Rn.assignInWith=Es,Rn.assignWith=Os,Rn.at=As,Rn.before=Na,Rn.bind=La,Rn.bindAll=rl,Rn.bindKey=Ma,Rn.castArray=function(){if(!arguments.length)return[];var e=arguments[0];return Ya(e)?e:[e]},Rn.chain=ma,Rn.chunk=function(e,t,r){t=(r?_o(e,t,r):t===n)?1:yn(ys(t),0);var i=null==e?0:e.length;if(!i||t<1)return[];for(var o=0,a=0,s=ke(Wt(i/t));o<i;)s[a++]=ri(e,o,o+=t);return s},Rn.compact=function(e){for(var t=-1,n=null==e?0:e.length,r=0,i=[];++t<n;){var o=e[t];o&&(i[r++]=o)}return i},Rn.concat=function(){var e=arguments.length;if(!e)return[];for(var t=ke(e-1),n=arguments[0],r=e;r--;)t[r-1]=arguments[r];return Dt(Ya(n)?ji(n):[n],vr(t,1))},Rn.cond=function(e){var t=null==e?0:e.length,n=lo();return e=t?Tt(e,(function(e){if("function"!=typeof e[1])throw new De(r);return[n(e[0]),e[1]]})):[],Zr((function(n){for(var r=-1;++r<t;){var i=e[r];if(xt(i[0],this,n))return xt(i[1],this,n)}}))},Rn.conforms=function(e){return function(e){var t=Ps(e);return function(n){return ur(n,e,t)}}(lr(e,1))},Rn.constant=il,Rn.countBy=ba,Rn.create=function(e,t){var n=zn(e);return null==t?n:ir(n,t)},Rn.curry=function e(t,r,i){var o=Xi(t,8,n,n,n,n,n,r=i?n:r);return o.placeholder=e.placeholder,o},Rn.curryRight=function e(t,r,i){var o=Xi(t,a,n,n,n,n,n,r=i?n:r);return o.placeholder=e.placeholder,o},Rn.debounce=Pa,Rn.defaults=Ss,Rn.defaultsDeep=js,Rn.defer=Fa,Rn.delay=qa,Rn.difference=Ho,Rn.differenceBy=Uo,Rn.differenceWith=Vo,Rn.drop=function(e,t,r){var i=null==e?0:e.length;return i?ri(e,(t=r||t===n?1:ys(t))<0?0:t,i):[]},Rn.dropRight=function(e,t,r){var i=null==e?0:e.length;return i?ri(e,0,(t=i-(t=r||t===n?1:ys(t)))<0?0:t):[]},Rn.dropRightWhile=function(e,t){return e&&e.length?di(e,lo(t,3),!0,!0):[]},Rn.dropWhile=function(e,t){return e&&e.length?di(e,lo(t,3),!0):[]},Rn.fill=function(e,t,r,i){var o=null==e?0:e.length;return o?(r&&"number"!=typeof r&&_o(e,t,r)&&(r=0,i=o),function(e,t,r,i){var o=e.length;for((r=ys(r))<0&&(r=-r>o?0:o+r),(i=i===n||i>o?o:ys(i))<0&&(i+=o),i=r>i?0:bs(i);r<i;)e[r++]=t;return e}(e,t,r,i)):[]},Rn.filter=function(e,t){return(Ya(e)?At:mr)(e,lo(t,3))},Rn.flatMap=function(e,t){return vr(Aa(e,t),1)},Rn.flatMapDeep=function(e,t){return vr(Aa(e,t),f)},Rn.flatMapDepth=function(e,t,r){return r=r===n?1:ys(r),vr(Aa(e,t),r)},Rn.flatten=Go,Rn.flattenDeep=function(e){return(null==e?0:e.length)?vr(e,f):[]},Rn.flattenDepth=function(e,t){return(null==e?0:e.length)?vr(e,t=t===n?1:ys(t)):[]},Rn.flip=function(e){return Xi(e,512)},Rn.flow=ol,Rn.flowRight=al,Rn.fromPairs=function(e){for(var t=-1,n=null==e?0:e.length,r={};++t<n;){var i=e[t];r[i[0]]=i[1]}return r},Rn.functions=function(e){return null==e?[]:xr(e,Ps(e))},Rn.functionsIn=function(e){return null==e?[]:xr(e,Fs(e))},Rn.groupBy=Ca,Rn.initial=function(e){return(null==e?0:e.length)?ri(e,0,-1):[]},Rn.intersection=Xo,Rn.intersectionBy=Jo,Rn.intersectionWith=Qo,Rn.invert=Ns,Rn.invertBy=Ls,Rn.invokeMap=Ea,Rn.iteratee=ll,Rn.keyBy=Oa,Rn.keys=Ps,Rn.keysIn=Fs,Rn.map=Aa,Rn.mapKeys=function(e,t){var n={};return t=lo(t,3),_r(e,(function(e,r,i){or(n,t(e,r,i),e)})),n},Rn.mapValues=function(e,t){var n={};return t=lo(t,3),_r(e,(function(e,r,i){or(n,r,t(e,r,i))})),n},Rn.matches=function(e){return Rr(lr(e,1))},Rn.matchesProperty=function(e,t){return zr(e,lr(t,1))},Rn.memoize=Ia,Rn.merge=qs,Rn.mergeWith=Is,Rn.method=ul,Rn.methodOf=cl,Rn.mixin=fl,Rn.negate=$a,Rn.nthArg=function(e){return e=ys(e),Zr((function(t){return Wr(t,e)}))},Rn.omit=$s,Rn.omitBy=function(e,t){return zs(e,$a(lo(t)))},Rn.once=function(e){return Na(2,e)},Rn.orderBy=function(e,t,r,i){return null==e?[]:(Ya(t)||(t=null==t?[]:[t]),Ya(r=i?n:r)||(r=null==r?[]:[r]),Hr(e,t,r))},Rn.over=dl,Rn.overArgs=Ra,Rn.overEvery=hl,Rn.overSome=gl,Rn.partial=za,Rn.partialRight=Ba,Rn.partition=Sa,Rn.pick=Rs,Rn.pickBy=zs,Rn.property=ml,Rn.propertyOf=function(e){return function(t){return null==e?n:kr(e,t)}},Rn.pull=ta,Rn.pullAll=na,Rn.pullAllBy=function(e,t,n){return e&&e.length&&t&&t.length?Vr(e,t,lo(n,2)):e},Rn.pullAllWith=function(e,t,r){return e&&e.length&&t&&t.length?Vr(e,t,n,r):e},Rn.pullAt=ra,Rn.range=vl,Rn.rangeRight=yl,Rn.rearg=Wa,Rn.reject=function(e,t){return(Ya(e)?At:mr)(e,$a(lo(t,3)))},Rn.remove=function(e,t){var n=[];if(!e||!e.length)return n;var r=-1,i=[],o=e.length;for(t=lo(t,3);++r<o;){var a=e[r];t(a,r,e)&&(n.push(a),i.push(r))}return Kr(e,i),n},Rn.rest=function(e,t){if("function"!=typeof e)throw new De(r);return Zr(e,t=t===n?t:ys(t))},Rn.reverse=ia,Rn.sampleSize=function(e,t,r){return t=(r?_o(e,t,r):t===n)?1:ys(t),(Ya(e)?Jn:Jr)(e,t)},Rn.set=function(e,t,n){return null==e?e:Qr(e,t,n)},Rn.setWith=function(e,t,r,i){return i="function"==typeof i?i:n,null==e?e:Qr(e,t,r,i)},Rn.shuffle=function(e){return(Ya(e)?Qn:ni)(e)},Rn.slice=function(e,t,r){var i=null==e?0:e.length;return i?(r&&"number"!=typeof r&&_o(e,t,r)?(t=0,r=i):(t=null==t?0:ys(t),r=r===n?i:ys(r)),ri(e,t,r)):[]},Rn.sortBy=ja,Rn.sortedUniq=function(e){return e&&e.length?si(e):[]},Rn.sortedUniqBy=function(e,t){return e&&e.length?si(e,lo(t,2)):[]},Rn.split=function(e,t,r){return r&&"number"!=typeof r&&_o(e,t,r)&&(t=r=n),(r=r===n?h:r>>>0)?(e=xs(e))&&("string"==typeof t||null!=t&&!us(t))&&!(t=ui(t))&&nn(e)?wi(un(e),0,r):e.split(t,r):[]},Rn.spread=function(e,t){if("function"!=typeof e)throw new De(r);return t=null==t?0:yn(ys(t),0),Zr((function(n){var r=n[t],i=wi(n,0,t);return r&&Dt(i,r),xt(e,this,i)}))},Rn.tail=function(e){var t=null==e?0:e.length;return t?ri(e,1,t):[]},Rn.take=function(e,t,r){return e&&e.length?ri(e,0,(t=r||t===n?1:ys(t))<0?0:t):[]},Rn.takeRight=function(e,t,r){var i=null==e?0:e.length;return i?ri(e,(t=i-(t=r||t===n?1:ys(t)))<0?0:t,i):[]},Rn.takeRightWhile=function(e,t){return e&&e.length?di(e,lo(t,3),!1,!0):[]},Rn.takeWhile=function(e,t){return e&&e.length?di(e,lo(t,3)):[]},Rn.tap=function(e,t){return t(e),e},Rn.throttle=function(e,t,n){var i=!0,o=!0;if("function"!=typeof e)throw new De(r);return is(n)&&(i="leading"in n?!!n.leading:i,o="trailing"in n?!!n.trailing:o),Pa(e,t,{leading:i,maxWait:t,trailing:o})},Rn.thru=va,Rn.toArray=ms,Rn.toPairs=Bs,Rn.toPairsIn=Ws,Rn.toPath=function(e){return Ya(e)?Tt(e,zo):ps(e)?[e]:ji(Ro(xs(e)))},Rn.toPlainObject=ws,Rn.transform=function(e,t,n){var r=Ya(e),i=r||Ja(e)||ds(e);if(t=lo(t,4),null==n){var o=e&&e.constructor;n=i?r?new o:[]:is(e)&&ts(o)?zn(Ye(e)):{}}return(i?Ct:_r)(e,(function(e,r,i){return t(n,e,r,i)})),n},Rn.unary=function(e){return Da(e,1)},Rn.union=oa,Rn.unionBy=aa,Rn.unionWith=sa,Rn.uniq=function(e){return e&&e.length?ci(e):[]},Rn.uniqBy=function(e,t){return e&&e.length?ci(e,lo(t,2)):[]},Rn.uniqWith=function(e,t){return t="function"==typeof t?t:n,e&&e.length?ci(e,n,t):[]},Rn.unset=function(e,t){return null==e||fi(e,t)},Rn.unzip=la,Rn.unzipWith=ua,Rn.update=function(e,t,n){return null==e?e:pi(e,t,yi(n))},Rn.updateWith=function(e,t,r,i){return i="function"==typeof i?i:n,null==e?e:pi(e,t,yi(r),i)},Rn.values=Hs,Rn.valuesIn=function(e){return null==e?[]:Yt(e,Fs(e))},Rn.without=ca,Rn.words=tl,Rn.wrap=function(e,t){return za(yi(t),e)},Rn.xor=fa,Rn.xorBy=pa,Rn.xorWith=da,Rn.zip=ha,Rn.zipObject=function(e,t){return mi(e||[],t||[],tr)},Rn.zipObjectDeep=function(e,t){return mi(e||[],t||[],Qr)},Rn.zipWith=ga,Rn.entries=Bs,Rn.entriesIn=Ws,Rn.extend=Cs,Rn.extendWith=Es,fl(Rn,Rn),Rn.add=wl,Rn.attempt=nl,Rn.camelCase=Us,Rn.capitalize=Vs,Rn.ceil=xl,Rn.clamp=function(e,t,r){return r===n&&(r=t,t=n),r!==n&&(r=(r=_s(r))==r?r:0),t!==n&&(t=(t=_s(t))==t?t:0),sr(_s(e),t,r)},Rn.clone=function(e){return lr(e,4)},Rn.cloneDeep=function(e){return lr(e,5)},Rn.cloneDeepWith=function(e,t){return lr(e,5,t="function"==typeof t?t:n)},Rn.cloneWith=function(e,t){return lr(e,4,t="function"==typeof t?t:n)},Rn.conformsTo=function(e,t){return null==t||ur(e,t,Ps(t))},Rn.deburr=Ks,Rn.defaultTo=function(e,t){return null==e||e!=e?t:e},Rn.divide=kl,Rn.endsWith=function(e,t,r){e=xs(e),t=ui(t);var i=e.length,o=r=r===n?i:sr(ys(r),0,i);return(r-=t.length)>=0&&e.slice(r,o)==t},Rn.eq=Ha,Rn.escape=function(e){return(e=xs(e))&&G.test(e)?e.replace(K,en):e},Rn.escapeRegExp=function(e){return(e=xs(e))&&re.test(e)?e.replace(ne,"\\$&"):e},Rn.every=function(e,t,r){var i=Ya(e)?Ot:hr;return r&&_o(e,t,r)&&(t=n),i(e,lo(t,3))},Rn.find=_a,Rn.findIndex=Ko,Rn.findKey=function(e,t){return Ft(e,lo(t,3),_r)},Rn.findLast=wa,Rn.findLastIndex=Yo,Rn.findLastKey=function(e,t){return Ft(e,lo(t,3),wr)},Rn.floor=Cl,Rn.forEach=xa,Rn.forEachRight=ka,Rn.forIn=function(e,t){return null==e?e:yr(e,lo(t,3),Fs)},Rn.forInRight=function(e,t){return null==e?e:br(e,lo(t,3),Fs)},Rn.forOwn=function(e,t){return e&&_r(e,lo(t,3))},Rn.forOwnRight=function(e,t){return e&&wr(e,lo(t,3))},Rn.get=Ts,Rn.gt=Ua,Rn.gte=Va,Rn.has=function(e,t){return null!=e&&mo(e,t,Ar)},Rn.hasIn=Ds,Rn.head=Zo,Rn.identity=sl,Rn.includes=function(e,t,n,r){e=Za(e)?e:Hs(e),n=n&&!r?ys(n):0;var i=e.length;return n<0&&(n=yn(i+n,0)),fs(e)?n<=i&&e.indexOf(t,n)>-1:!!i&&It(e,t,n)>-1},Rn.indexOf=function(e,t,n){var r=null==e?0:e.length;if(!r)return-1;var i=null==n?0:ys(n);return i<0&&(i=yn(r+i,0)),It(e,t,i)},Rn.inRange=function(e,t,r){return t=vs(t),r===n?(r=t,t=0):r=vs(r),function(e,t,n){return e>=bn(t,n)&&e<yn(t,n)}(e=_s(e),t,r)},Rn.invoke=Ms,Rn.isArguments=Ka,Rn.isArray=Ya,Rn.isArrayBuffer=Ga,Rn.isArrayLike=Za,Rn.isArrayLikeObject=Xa,Rn.isBoolean=function(e){return!0===e||!1===e||os(e)&&Er(e)==y},Rn.isBuffer=Ja,Rn.isDate=Qa,Rn.isElement=function(e){return os(e)&&1===e.nodeType&&!ls(e)},Rn.isEmpty=function(e){if(null==e)return!0;if(Za(e)&&(Ya(e)||"string"==typeof e||"function"==typeof e.splice||Ja(e)||ds(e)||Ka(e)))return!e.length;var t=go(e);if(t==k||t==S)return!e.size;if(Co(e))return!Fr(e).length;for(var n in e)if(qe.call(e,n))return!1;return!0},Rn.isEqual=function(e,t){return Nr(e,t)},Rn.isEqualWith=function(e,t,r){var i=(r="function"==typeof r?r:n)?r(e,t):n;return i===n?Nr(e,t,n,r):!!i},Rn.isError=es,Rn.isFinite=function(e){return"number"==typeof e&&gn(e)},Rn.isFunction=ts,Rn.isInteger=ns,Rn.isLength=rs,Rn.isMap=as,Rn.isMatch=function(e,t){return e===t||Lr(e,t,co(t))},Rn.isMatchWith=function(e,t,r){return r="function"==typeof r?r:n,Lr(e,t,co(t),r)},Rn.isNaN=function(e){return ss(e)&&e!=+e},Rn.isNative=function(e){if(ko(e))throw new Ee("Unsupported core-js use. Try https://npms.io/search?q=ponyfill.");return Mr(e)},Rn.isNil=function(e){return null==e},Rn.isNull=function(e){return null===e},Rn.isNumber=ss,Rn.isObject=is,Rn.isObjectLike=os,Rn.isPlainObject=ls,Rn.isRegExp=us,Rn.isSafeInteger=function(e){return ns(e)&&e>=-9007199254740991&&e<=p},Rn.isSet=cs,Rn.isString=fs,Rn.isSymbol=ps,Rn.isTypedArray=ds,Rn.isUndefined=function(e){return e===n},Rn.isWeakMap=function(e){return os(e)&&go(e)==D},Rn.isWeakSet=function(e){return os(e)&&"[object WeakSet]"==Er(e)},Rn.join=function(e,t){return null==e?"":mn.call(e,t)},Rn.kebabCase=Ys,Rn.last=ea,Rn.lastIndexOf=function(e,t,r){var i=null==e?0:e.length;if(!i)return-1;var o=i;return r!==n&&(o=(o=ys(r))<0?yn(i+o,0):bn(o,i-1)),t==t?function(e,t,n){for(var r=n+1;r--;)if(e[r]===t)return r;return r}(e,t,o):qt(e,Rt,o,!0)},Rn.lowerCase=Gs,Rn.lowerFirst=Zs,Rn.lt=hs,Rn.lte=gs,Rn.max=function(e){return e&&e.length?gr(e,sl,Or):n},Rn.maxBy=function(e,t){return e&&e.length?gr(e,lo(t,2),Or):n},Rn.mean=function(e){return zt(e,sl)},Rn.meanBy=function(e,t){return zt(e,lo(t,2))},Rn.min=function(e){return e&&e.length?gr(e,sl,Ir):n},Rn.minBy=function(e,t){return e&&e.length?gr(e,lo(t,2),Ir):n},Rn.stubArray=bl,Rn.stubFalse=_l,Rn.stubObject=function(){return{}},Rn.stubString=function(){return""},Rn.stubTrue=function(){return!0},Rn.multiply=Ol,Rn.nth=function(e,t){return e&&e.length?Wr(e,ys(t)):n},Rn.noConflict=function(){return ct._===this&&(ct._=Be),this},Rn.noop=pl,Rn.now=Ta,Rn.pad=function(e,t,n){e=xs(e);var r=(t=ys(t))?ln(e):0;if(!t||r>=t)return e;var i=(t-r)/2;return Hi(pn(i),n)+e+Hi(Wt(i),n)},Rn.padEnd=function(e,t,n){e=xs(e);var r=(t=ys(t))?ln(e):0;return t&&r<t?e+Hi(t-r,n):e},Rn.padStart=function(e,t,n){e=xs(e);var r=(t=ys(t))?ln(e):0;return t&&r<t?Hi(t-r,n)+e:e},Rn.parseInt=function(e,t,n){return n||null==t?t=0:t&&(t=+t),wn(xs(e).replace(oe,""),t||0)},Rn.random=function(e,t,r){if(r&&"boolean"!=typeof r&&_o(e,t,r)&&(t=r=n),r===n&&("boolean"==typeof t?(r=t,t=n):"boolean"==typeof e&&(r=e,e=n)),e===n&&t===n?(e=0,t=1):(e=vs(e),t===n?(t=e,e=0):t=vs(t)),e>t){var i=e;e=t,t=i}if(r||e%1||t%1){var o=xn();return bn(e+o*(t-e+at("1e-"+((o+"").length-1))),t)}return Yr(e,t)},Rn.reduce=function(e,t,n){var r=Ya(e)?Nt:Ht,i=arguments.length<3;return r(e,lo(t,4),n,i,pr)},Rn.reduceRight=function(e,t,n){var r=Ya(e)?Lt:Ht,i=arguments.length<3;return r(e,lo(t,4),n,i,dr)},Rn.repeat=function(e,t,r){return t=(r?_o(e,t,r):t===n)?1:ys(t),Gr(xs(e),t)},Rn.replace=function(){var e=arguments,t=xs(e[0]);return e.length<3?t:t.replace(e[1],e[2])},Rn.result=function(e,t,r){var i=-1,o=(t=bi(t,e)).length;for(o||(o=1,e=n);++i<o;){var a=null==e?n:e[zo(t[i])];a===n&&(i=o,a=r),e=ts(a)?a.call(e):a}return e},Rn.round=Al,Rn.runInContext=e,Rn.sample=function(e){return(Ya(e)?Xn:Xr)(e)},Rn.size=function(e){if(null==e)return 0;if(Za(e))return fs(e)?ln(e):e.length;var t=go(e);return t==k||t==S?e.size:Fr(e).length},Rn.snakeCase=Xs,Rn.some=function(e,t,r){var i=Ya(e)?Mt:ii;return r&&_o(e,t,r)&&(t=n),i(e,lo(t,3))},Rn.sortedIndex=function(e,t){return oi(e,t)},Rn.sortedIndexBy=function(e,t,n){return ai(e,t,lo(n,2))},Rn.sortedIndexOf=function(e,t){var n=null==e?0:e.length;if(n){var r=oi(e,t);if(r<n&&Ha(e[r],t))return r}return-1},Rn.sortedLastIndex=function(e,t){return oi(e,t,!0)},Rn.sortedLastIndexBy=function(e,t,n){return ai(e,t,lo(n,2),!0)},Rn.sortedLastIndexOf=function(e,t){if(null==e?0:e.length){var n=oi(e,t,!0)-1;if(Ha(e[n],t))return n}return-1},Rn.startCase=Js,Rn.startsWith=function(e,t,n){return e=xs(e),n=null==n?0:sr(ys(n),0,e.length),t=ui(t),e.slice(n,n+t.length)==t},Rn.subtract=Sl,Rn.sum=function(e){return e&&e.length?Ut(e,sl):0},Rn.sumBy=function(e,t){return e&&e.length?Ut(e,lo(t,2)):0},Rn.template=function(e,t,r){var i=Rn.templateSettings;r&&_o(e,t,r)&&(t=n),e=xs(e),t=Es({},t,i,Ji);var o,a,s=Es({},t.imports,i.imports,Ji),l=Ps(s),u=Yt(s,l),c=0,f=t.interpolate||_e,p="__p += '",d=je((t.escape||_e).source+"|"+f.source+"|"+(f===J?pe:_e).source+"|"+(t.evaluate||_e).source+"|$","g"),h="//# sourceURL="+(qe.call(t,"sourceURL")?(t.sourceURL+"").replace(/[\r\n]/g," "):"lodash.templateSources["+ ++nt+"]")+"\n";e.replace(d,(function(t,n,r,i,s,l){return r||(r=i),p+=e.slice(c,l).replace(we,tn),n&&(o=!0,p+="' +\n__e("+n+") +\n'"),s&&(a=!0,p+="';\n"+s+";\n__p += '"),r&&(p+="' +\n((__t = ("+r+")) == null ? '' : __t) +\n'"),c=l+t.length,t})),p+="';\n";var g=qe.call(t,"variable")&&t.variable;g||(p="with (obj) {\n"+p+"\n}\n"),p=(a?p.replace(W,""):p).replace(H,"$1").replace(U,"$1;"),p="function("+(g||"obj")+") {\n"+(g?"":"obj || (obj = {});\n")+"var __t, __p = ''"+(o?", __e = _.escape":"")+(a?", __j = Array.prototype.join;\nfunction print() { __p += __j.call(arguments, '') }\n":";\n")+p+"return __p\n}";var m=nl((function(){return Oe(l,h+"return "+p).apply(n,u)}));if(m.source=p,es(m))throw m;return m},Rn.times=function(e,t){if((e=ys(e))<1||e>p)return[];var n=h,r=bn(e,h);t=lo(t),e-=h;for(var i=Vt(r,t);++n<e;)t(n);return i},Rn.toFinite=vs,Rn.toInteger=ys,Rn.toLength=bs,Rn.toLower=function(e){return xs(e).toLowerCase()},Rn.toNumber=_s,Rn.toSafeInteger=function(e){return e?sr(ys(e),-9007199254740991,p):0===e?e:0},Rn.toString=xs,Rn.toUpper=function(e){return xs(e).toUpperCase()},Rn.trim=function(e,t,r){if((e=xs(e))&&(r||t===n))return e.replace(ie,"");if(!e||!(t=ui(t)))return e;var i=un(e),o=un(t);return wi(i,Zt(i,o),Xt(i,o)+1).join("")},Rn.trimEnd=function(e,t,r){if((e=xs(e))&&(r||t===n))return e.replace(ae,"");if(!e||!(t=ui(t)))return e;var i=un(e);return wi(i,0,Xt(i,un(t))+1).join("")},Rn.trimStart=function(e,t,r){if((e=xs(e))&&(r||t===n))return e.replace(oe,"");if(!e||!(t=ui(t)))return e;var i=un(e);return wi(i,Zt(i,un(t))).join("")},Rn.truncate=function(e,t){var r=30,i="...";if(is(t)){var o="separator"in t?t.separator:o;r="length"in t?ys(t.length):r,i="omission"in t?ui(t.omission):i}var a=(e=xs(e)).length;if(nn(e)){var s=un(e);a=s.length}if(r>=a)return e;var l=r-ln(i);if(l<1)return i;var u=s?wi(s,0,l).join(""):e.slice(0,l);if(o===n)return u+i;if(s&&(l+=u.length-l),us(o)){if(e.slice(l).search(o)){var c,f=u;for(o.global||(o=je(o.source,xs(de.exec(o))+"g")),o.lastIndex=0;c=o.exec(f);)var p=c.index;u=u.slice(0,p===n?l:p)}}else if(e.indexOf(ui(o),l)!=l){var d=u.lastIndexOf(o);d>-1&&(u=u.slice(0,d))}return u+i},Rn.unescape=function(e){return(e=xs(e))&&Y.test(e)?e.replace(V,cn):e},Rn.uniqueId=function(e){var t=++Ie;return xs(e)+t},Rn.upperCase=Qs,Rn.upperFirst=el,Rn.each=xa,Rn.eachRight=ka,Rn.first=Zo,fl(Rn,(El={},_r(Rn,(function(e,t){qe.call(Rn.prototype,t)||(El[t]=e)})),El),{chain:!1}),Rn.VERSION="4.17.13",Ct(["bind","bindKey","curry","curryRight","partial","partialRight"],(function(e){Rn[e].placeholder=Rn})),Ct(["drop","take"],(function(e,t){Hn.prototype[e]=function(r){r=r===n?1:yn(ys(r),0);var i=this.__filtered__&&!t?new Hn(this):this.clone();return i.__filtered__?i.__takeCount__=bn(r,i.__takeCount__):i.__views__.push({size:bn(r,h),type:e+(i.__dir__<0?"Right":"")}),i},Hn.prototype[e+"Right"]=function(t){return this.reverse()[e](t).reverse()}})),Ct(["filter","map","takeWhile"],(function(e,t){var n=t+1,r=1==n||3==n;Hn.prototype[e]=function(e){var t=this.clone();return t.__iteratees__.push({iteratee:lo(e,3),type:n}),t.__filtered__=t.__filtered__||r,t}})),Ct(["head","last"],(function(e,t){var n="take"+(t?"Right":"");Hn.prototype[e]=function(){return this[n](1).value()[0]}})),Ct(["initial","tail"],(function(e,t){var n="drop"+(t?"":"Right");Hn.prototype[e]=function(){return this.__filtered__?new Hn(this):this[n](1)}})),Hn.prototype.compact=function(){return this.filter(sl)},Hn.prototype.find=function(e){return this.filter(e).head()},Hn.prototype.findLast=function(e){return this.reverse().find(e)},Hn.prototype.invokeMap=Zr((function(e,t){return"function"==typeof e?new Hn(this):this.map((function(n){return Tr(n,e,t)}))})),Hn.prototype.reject=function(e){return this.filter($a(lo(e)))},Hn.prototype.slice=function(e,t){e=ys(e);var r=this;return r.__filtered__&&(e>0||t<0)?new Hn(r):(e<0?r=r.takeRight(-e):e&&(r=r.drop(e)),t!==n&&(r=(t=ys(t))<0?r.dropRight(-t):r.take(t-e)),r)},Hn.prototype.takeRightWhile=function(e){return this.reverse().takeWhile(e).reverse()},Hn.prototype.toArray=function(){return this.take(h)},_r(Hn.prototype,(function(e,t){var r=/^(?:filter|find|map|reject)|While$/.test(t),i=/^(?:head|last)$/.test(t),o=Rn[i?"take"+("last"==t?"Right":""):t],a=i||/^find/.test(t);o&&(Rn.prototype[t]=function(){var t=this.__wrapped__,s=i?[1]:arguments,l=t instanceof Hn,u=s[0],c=l||Ya(t),f=function(e){var t=o.apply(Rn,Dt([e],s));return i&&p?t[0]:t};c&&r&&"function"==typeof u&&1!=u.length&&(l=c=!1);var p=this.__chain__,d=!!this.__actions__.length,h=a&&!p,g=l&&!d;if(!a&&c){t=g?t:new Hn(this);var m=e.apply(t,s);return m.__actions__.push({func:va,args:[f],thisArg:n}),new Wn(m,p)}return h&&g?e.apply(this,s):(m=this.thru(f),h?i?m.value()[0]:m.value():m)})})),Ct(["pop","push","shift","sort","splice","unshift"],(function(e){var t=Ne[e],n=/^(?:push|sort|unshift)$/.test(e)?"tap":"thru",r=/^(?:pop|shift)$/.test(e);Rn.prototype[e]=function(){var e=arguments;if(r&&!this.__chain__){var i=this.value();return t.apply(Ya(i)?i:[],e)}return this[n]((function(n){return t.apply(Ya(n)?n:[],e)}))}})),_r(Hn.prototype,(function(e,t){var n=Rn[t];if(n){var r=n.name+"";qe.call(Dn,r)||(Dn[r]=[]),Dn[r].push({name:t,func:n})}})),Dn[Ri(n,2).name]=[{name:"wrapper",func:n}],Hn.prototype.clone=function(){var e=new Hn(this.__wrapped__);return e.__actions__=ji(this.__actions__),e.__dir__=this.__dir__,e.__filtered__=this.__filtered__,e.__iteratees__=ji(this.__iteratees__),e.__takeCount__=this.__takeCount__,e.__views__=ji(this.__views__),e},Hn.prototype.reverse=function(){if(this.__filtered__){var e=new Hn(this);e.__dir__=-1,e.__filtered__=!0}else(e=this.clone()).__dir__*=-1;return e},Hn.prototype.value=function(){var e=this.__wrapped__.value(),t=this.__dir__,n=Ya(e),r=t<0,i=n?e.length:0,o=function(e,t,n){var r=-1,i=n.length;for(;++r<i;){var o=n[r],a=o.size;switch(o.type){case"drop":e+=a;break;case"dropRight":t-=a;break;case"take":t=bn(t,e+a);break;case"takeRight":e=yn(e,t-a)}}return{start:e,end:t}}(0,i,this.__views__),a=o.start,s=o.end,l=s-a,u=r?s:a-1,c=this.__iteratees__,f=c.length,p=0,d=bn(l,this.__takeCount__);if(!n||!r&&i==l&&d==l)return hi(e,this.__actions__);var h=[];e:for(;l--&&p<d;){for(var g=-1,m=e[u+=t];++g<f;){var v=c[g],y=v.iteratee,b=v.type,_=y(m);if(2==b)m=_;else if(!_){if(1==b)continue e;break e}}h[p++]=m}return h},Rn.prototype.at=ya,Rn.prototype.chain=function(){return ma(this)},Rn.prototype.commit=function(){return new Wn(this.value(),this.__chain__)},Rn.prototype.next=function(){this.__values__===n&&(this.__values__=ms(this.value()));var e=this.__index__>=this.__values__.length;return{done:e,value:e?n:this.__values__[this.__index__++]}},Rn.prototype.plant=function(e){for(var t,r=this;r instanceof Bn;){var i=Wo(r);i.__index__=0,i.__values__=n,t?o.__wrapped__=i:t=i;var o=i;r=r.__wrapped__}return o.__wrapped__=e,t},Rn.prototype.reverse=function(){var e=this.__wrapped__;if(e instanceof Hn){var t=e;return this.__actions__.length&&(t=new Hn(this)),(t=t.reverse()).__actions__.push({func:va,args:[ia],thisArg:n}),new Wn(t,this.__chain__)}return this.thru(ia)},Rn.prototype.toJSON=Rn.prototype.valueOf=Rn.prototype.value=function(){return hi(this.__wrapped__,this.__actions__)},Rn.prototype.first=Rn.prototype.head,ut&&(Rn.prototype[ut]=function(){return this}),Rn}();pt?((pt.exports=fn)._=fn,ft._=fn):ct._=fn}).call(Bn)}));var Zu=function(e){return e},Xu="object"==typeof Bn&&Bn&&Bn.Object===Object&&Bn,Ju="object"==typeof self&&self&&self.Object===Object&&self,Qu=Xu||Ju||Function("return this")(),ec=Qu.Symbol,tc=Object.prototype,nc=tc.hasOwnProperty,rc=tc.toString,ic=ec?ec.toStringTag:void 0;var oc=function(e){var t=nc.call(e,ic),n=e[ic];try{e[ic]=void 0;var r=!0}catch(o){}var i=rc.call(e);return r&&(t?e[ic]=n:delete e[ic]),i},ac=Object.prototype.toString;var sc=function(e){return ac.call(e)},lc=ec?ec.toStringTag:void 0;var uc=function(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":lc&&lc in Object(e)?oc(e):sc(e)};var cc=function(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)};var fc,pc=function(e){if(!cc(e))return!1;var t=uc(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t},dc=Qu["__core-js_shared__"],hc=(fc=/[^.]+$/.exec(dc&&dc.keys&&dc.keys.IE_PROTO||""))?"Symbol(src)_1."+fc:"";var gc=function(e){return!!hc&&hc in e},mc=Function.prototype.toString;var vc=function(e){if(null!=e){try{return mc.call(e)}catch(t){}try{return e+""}catch(t){}}return""},yc=/^\[object .+?Constructor\]$/,bc=Function.prototype,_c=Object.prototype,wc=bc.toString,xc=_c.hasOwnProperty,kc=RegExp("^"+wc.call(xc).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");var Cc=function(e){return!(!cc(e)||gc(e))&&(pc(e)?kc:yc).test(vc(e))};var Ec=function(e,t){return null==e?void 0:e[t]};var Oc=function(e,t){var n=Ec(e,t);return Cc(n)?n:void 0},Ac=Oc(Qu,"WeakMap"),Sc=Ac&&new Ac,jc=Sc?function(e,t){return Sc.set(e,t),e}:Zu,Tc=Object.create,Dc=function(){function e(){}return function(t){if(!cc(t))return{};if(Tc)return Tc(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();var Nc=function(e){return function(){var t=arguments;switch(t.length){case 0:return new e;case 1:return new e(t[0]);case 2:return new e(t[0],t[1]);case 3:return new e(t[0],t[1],t[2]);case 4:return new e(t[0],t[1],t[2],t[3]);case 5:return new e(t[0],t[1],t[2],t[3],t[4]);case 6:return new e(t[0],t[1],t[2],t[3],t[4],t[5]);case 7:return new e(t[0],t[1],t[2],t[3],t[4],t[5],t[6])}var n=Dc(e.prototype),r=e.apply(n,t);return cc(r)?r:n}};var Lc=function(e,t,n){var r=1&t,i=Nc(e);return function t(){var o=this&&this!==Qu&&this instanceof t?i:e;return o.apply(r?n:this,arguments)}};var Mc=function(e,t,n){switch(n.length){case 0:return e.call(t);case 1:return e.call(t,n[0]);case 2:return e.call(t,n[0],n[1]);case 3:return e.call(t,n[0],n[1],n[2])}return e.apply(t,n)},Pc=Math.max;var Fc=function(e,t,n,r){for(var i=-1,o=e.length,a=n.length,s=-1,l=t.length,u=Pc(o-a,0),c=Array(l+u),f=!r;++s<l;)c[s]=t[s];for(;++i<a;)(f||i<o)&&(c[n[i]]=e[i]);for(;u--;)c[s++]=e[i++];return c},qc=Math.max;var Ic=function(e,t,n,r){for(var i=-1,o=e.length,a=-1,s=n.length,l=-1,u=t.length,c=qc(o-s,0),f=Array(c+u),p=!r;++i<c;)f[i]=e[i];for(var d=i;++l<u;)f[d+l]=t[l];for(;++a<s;)(p||i<o)&&(f[d+n[a]]=e[i++]);return f};var $c=function(e,t){for(var n=e.length,r=0;n--;)e[n]===t&&++r;return r};var Rc=function(){};function zc(e){this.__wrapped__=e,this.__actions__=[],this.__dir__=1,this.__filtered__=!1,this.__iteratees__=[],this.__takeCount__=4294967295,this.__views__=[]}zc.prototype=Dc(Rc.prototype),zc.prototype.constructor=zc;var Bc=zc;var Wc=Sc?function(e){return Sc.get(e)}:function(){},Hc={},Uc=Object.prototype.hasOwnProperty;var Vc=function(e){for(var t=e.name+"",n=Hc[t],r=Uc.call(Hc,t)?n.length:0;r--;){var i=n[r],o=i.func;if(null==o||o==e)return i.name}return t};function Kc(e,t){this.__wrapped__=e,this.__actions__=[],this.__chain__=!!t,this.__index__=0,this.__values__=void 0}Kc.prototype=Dc(Rc.prototype),Kc.prototype.constructor=Kc;var Yc=Kc,Gc=Array.isArray;var Zc=function(e){return null!=e&&"object"==typeof e};var Xc=function(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t};var Jc=function(e){if(e instanceof Bc)return e.clone();var t=new Yc(e.__wrapped__,e.__chain__);return t.__actions__=Xc(e.__actions__),t.__index__=e.__index__,t.__values__=e.__values__,t},Qc=Object.prototype.hasOwnProperty;function ef(e){if(Zc(e)&&!Gc(e)&&!(e instanceof Bc)){if(e instanceof Yc)return e;if(Qc.call(e,"__wrapped__"))return Jc(e)}return new Yc(e)}ef.prototype=Rc.prototype,ef.prototype.constructor=ef;var tf=ef;var nf=function(e){var t=Vc(e),n=tf[t];if("function"!=typeof n||!(t in Bc.prototype))return!1;if(e===n)return!0;var r=Wc(n);return!!r&&e===r[0]},rf=Date.now;var of=function(e){var t=0,n=0;return function(){var r=rf(),i=16-(r-n);if(n=r,i>0){if(++t>=800)return arguments[0]}else t=0;return e.apply(void 0,arguments)}},af=of(jc),sf=/\{\n\/\* \[wrapped with (.+)\] \*/,lf=/,? & /;var uf=function(e){var t=e.match(sf);return t?t[1].split(lf):[]},cf=/\{(?:\n\/\* \[wrapped with .+\] \*\/)?\n?/;var ff=function(e,t){var n=t.length;if(!n)return e;var r=n-1;return t[r]=(n>1?"& ":"")+t[r],t=t.join(n>2?", ":" "),e.replace(cf,"{\n/* [wrapped with "+t+"] */\n")};var pf=function(e){return function(){return e}},df=function(){try{var e=Oc(Object,"defineProperty");return e({},"",{}),e}catch(t){}}(),hf=of(df?function(e,t){return df(e,"toString",{configurable:!0,enumerable:!1,value:pf(t),writable:!0})}:Zu);var gf=function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););return e};var mf=function(e,t,n,r){for(var i=e.length,o=n+(r?1:-1);r?o--:++o<i;)if(t(e[o],o,e))return o;return-1};var vf=function(e){return e!=e};var yf=function(e,t,n){for(var r=n-1,i=e.length;++r<i;)if(e[r]===t)return r;return-1};var bf=function(e,t,n){return t==t?yf(e,t,n):mf(e,vf,n)};var _f=function(e,t){return!!(null==e?0:e.length)&&bf(e,t,0)>-1},wf=[["ary",128],["bind",1],["bindKey",2],["curry",8],["curryRight",16],["flip",512],["partial",32],["partialRight",64],["rearg",256]];var xf=function(e,t){return gf(wf,(function(n){var r="_."+n[0];t&n[1]&&!_f(e,r)&&e.push(r)})),e.sort()};var kf=function(e,t,n){var r=t+"";return hf(e,ff(r,xf(uf(r),n)))};var Cf=function(e,t,n,r,i,o,a,s,l,u){var c=8&t;t|=c?32:64,4&(t&=~(c?64:32))||(t&=-4);var f=[e,t,i,c?o:void 0,c?a:void 0,c?void 0:o,c?void 0:a,s,l,u],p=n.apply(void 0,f);return nf(e)&&af(p,f),p.placeholder=r,kf(p,e,t)};var Ef=function(e){return e.placeholder},Of=/^(?:0|[1-9]\d*)$/;var Af=function(e,t){var n=typeof e;return!!(t=null==t?9007199254740991:t)&&("number"==n||"symbol"!=n&&Of.test(e))&&e>-1&&e%1==0&&e<t},Sf=Math.min;var jf=function(e,t){for(var n=e.length,r=Sf(t.length,n),i=Xc(e);r--;){var o=t[r];e[r]=Af(o,n)?i[o]:void 0}return e};var Tf=function(e,t){for(var n=-1,r=e.length,i=0,o=[];++n<r;){var a=e[n];a!==t&&"__lodash_placeholder__"!==a||(e[n]="__lodash_placeholder__",o[i++]=n)}return o};var Df=function e(t,n,r,i,o,a,s,l,u,c){var f=128&n,p=1&n,d=2&n,h=24&n,g=512&n,m=d?void 0:Nc(t);return function v(){for(var y=arguments.length,b=Array(y),_=y;_--;)b[_]=arguments[_];if(h)var w=Ef(v),x=$c(b,w);if(i&&(b=Fc(b,i,o,h)),a&&(b=Ic(b,a,s,h)),y-=x,h&&y<c){var k=Tf(b,w);return Cf(t,n,e,v.placeholder,r,b,k,l,u,c-y)}var C=p?r:this,E=d?C[t]:t;return y=b.length,l?b=jf(b,l):g&&y>1&&b.reverse(),f&&u<y&&(b.length=u),this&&this!==Qu&&this instanceof v&&(E=m||Nc(E)),E.apply(C,b)}};var Nf=function(e,t,n){var r=Nc(e);return function i(){for(var o=arguments.length,a=Array(o),s=o,l=Ef(i);s--;)a[s]=arguments[s];var u=o<3&&a[0]!==l&&a[o-1]!==l?[]:Tf(a,l);if((o-=u.length)<n)return Cf(e,t,Df,i.placeholder,void 0,a,u,void 0,void 0,n-o);var c=this&&this!==Qu&&this instanceof i?r:e;return Mc(c,this,a)}};var Lf=function(e,t,n,r){var i=1&t,o=Nc(e);return function t(){for(var a=-1,s=arguments.length,l=-1,u=r.length,c=Array(u+s),f=this&&this!==Qu&&this instanceof t?o:e;++l<u;)c[l]=r[l];for(;s--;)c[l++]=arguments[++a];return Mc(f,i?n:this,c)}},Mf=Math.min;var Pf=function(e,t){var n=e[1],r=t[1],i=n|r,o=i<131,a=128==r&&8==n||128==r&&256==n&&e[7].length<=t[8]||384==r&&t[7].length<=t[8]&&8==n;if(!o&&!a)return e;1&r&&(e[2]=t[2],i|=1&n?0:4);var s=t[3];if(s){var l=e[3];e[3]=l?Fc(l,s,t[4]):s,e[4]=l?Tf(e[3],"__lodash_placeholder__"):t[4]}return(s=t[5])&&(l=e[5],e[5]=l?Ic(l,s,t[6]):s,e[6]=l?Tf(e[5],"__lodash_placeholder__"):t[6]),(s=t[7])&&(e[7]=s),128&r&&(e[8]=null==e[8]?t[8]:Mf(e[8],t[8])),null==e[9]&&(e[9]=t[9]),e[0]=t[0],e[1]=i,e};var Ff=function(e){return"symbol"==typeof e||Zc(e)&&"[object Symbol]"==uc(e)},qf=/^\s+|\s+$/g,If=/^[-+]0x[0-9a-f]+$/i,$f=/^0b[01]+$/i,Rf=/^0o[0-7]+$/i,zf=parseInt;var Bf=function(e){if("number"==typeof e)return e;if(Ff(e))return NaN;if(cc(e)){var t="function"==typeof e.valueOf?e.valueOf():e;e=cc(t)?t+"":t}if("string"!=typeof e)return 0===e?e:+e;e=e.replace(qf,"");var n=$f.test(e);return n||Rf.test(e)?zf(e.slice(2),n?2:8):If.test(e)?NaN:+e};var Wf=function(e){return e?Infinity===(e=Bf(e))||-Infinity===e?17976931348623157e292*(e<0?-1:1):e==e?e:0:0===e?e:0};var Hf=function(e){var t=Wf(e),n=t%1;return t==t?n?t-n:t:0},Uf=Math.max;var Vf=function(e,t,n,r,i,o,a,s){var l=2&t;if(!l&&"function"!=typeof e)throw new TypeError("Expected a function");var u=r?r.length:0;if(u||(t&=-97,r=i=void 0),a=void 0===a?a:Uf(Hf(a),0),s=void 0===s?s:Hf(s),u-=i?i.length:0,64&t){var c=r,f=i;r=i=void 0}var p=l?void 0:Wc(e),d=[e,t,n,r,i,c,f,o,a,s];if(p&&Pf(d,p),e=d[0],t=d[1],n=d[2],r=d[3],i=d[4],!(s=d[9]=void 0===d[9]?l?0:e.length:Uf(d[9]-u,0))&&24&t&&(t&=-25),t&&1!=t)h=8==t||16==t?Nf(e,t,s):32!=t&&33!=t||i.length?Df.apply(void 0,d):Lf(e,t,n,r);else var h=Lc(e,t,n);return kf((p?jc:af)(h,d),e,t)};var Kf=function(e,t,n){return t=n?void 0:t,t=e&&null==t?e.length:t,Vf(e,128,void 0,void 0,void 0,void 0,t)};var Yf=function(e,t,n){"__proto__"==t&&df?df(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n};var Gf=function(e,t){return e===t||e!=e&&t!=t},Zf=Object.prototype.hasOwnProperty;var Xf=function(e,t,n){var r=e[t];Zf.call(e,t)&&Gf(r,n)&&(void 0!==n||t in e)||Yf(e,t,n)};var Jf=function(e,t,n,r){var i=!n;n||(n={});for(var o=-1,a=t.length;++o<a;){var s=t[o],l=r?r(n[s],e[s],s,n,e):void 0;void 0===l&&(l=e[s]),i?Yf(n,s,l):Xf(n,s,l)}return n};var Qf=function(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r};var ep=function(e){return Zc(e)&&"[object Arguments]"==uc(e)},tp=Object.prototype,np=tp.hasOwnProperty,rp=tp.propertyIsEnumerable,ip=ep(function(){return arguments}())?ep:function(e){return Zc(e)&&np.call(e,"callee")&&!rp.call(e,"callee")};var op=function(){return!1},ap=Un((function(e,t){var n=t&&!t.nodeType&&t,r=n&&e&&!e.nodeType&&e,i=r&&r.exports===n?Qu.Buffer:void 0,o=(i?i.isBuffer:void 0)||op;e.exports=o}));var sp=function(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991},lp={};lp["[object Float32Array]"]=lp["[object Float64Array]"]=lp["[object Int8Array]"]=lp["[object Int16Array]"]=lp["[object Int32Array]"]=lp["[object Uint8Array]"]=lp["[object Uint8ClampedArray]"]=lp["[object Uint16Array]"]=lp["[object Uint32Array]"]=!0,lp["[object Arguments]"]=lp["[object Array]"]=lp["[object ArrayBuffer]"]=lp["[object Boolean]"]=lp["[object DataView]"]=lp["[object Date]"]=lp["[object Error]"]=lp["[object Function]"]=lp["[object Map]"]=lp["[object Number]"]=lp["[object Object]"]=lp["[object RegExp]"]=lp["[object Set]"]=lp["[object String]"]=lp["[object WeakMap]"]=!1;var up=function(e){return Zc(e)&&sp(e.length)&&!!lp[uc(e)]};var cp=function(e){return function(t){return e(t)}},fp=Un((function(e,t){var n=t&&!t.nodeType&&t,r=n&&e&&!e.nodeType&&e,i=r&&r.exports===n&&Xu.process,o=function(){try{var e=r&&r.require&&r.require("util").types;return e||i&&i.binding&&i.binding("util")}catch(t){}}();e.exports=o})),pp=fp&&fp.isTypedArray,dp=pp?cp(pp):up,hp=Object.prototype.hasOwnProperty;var gp=function(e,t){var n=Gc(e),r=!n&&ip(e),i=!n&&!r&&ap(e),o=!n&&!r&&!i&&dp(e),a=n||r||i||o,s=a?Qf(e.length,String):[],l=s.length;for(var u in e)!t&&!hp.call(e,u)||a&&("length"==u||i&&("offset"==u||"parent"==u)||o&&("buffer"==u||"byteLength"==u||"byteOffset"==u)||Af(u,l))||s.push(u);return s},mp=Object.prototype;var vp=function(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||mp)};var yp=function(e,t){return function(n){return e(t(n))}},bp=yp(Object.keys,Object),_p=Object.prototype.hasOwnProperty;var wp=function(e){if(!vp(e))return bp(e);var t=[];for(var n in Object(e))_p.call(e,n)&&"constructor"!=n&&t.push(n);return t};var xp=function(e){return null!=e&&sp(e.length)&&!pc(e)};var kp=function(e){return xp(e)?gp(e):wp(e)};var Cp=function(e,t){return e&&Jf(t,kp(t),e)};var Ep=function(){this.__data__=[],this.size=0};var Op=function(e,t){for(var n=e.length;n--;)if(Gf(e[n][0],t))return n;return-1},Ap=Array.prototype.splice;var Sp=function(e){var t=this.__data__,n=Op(t,e);return!(n<0)&&(n==t.length-1?t.pop():Ap.call(t,n,1),--this.size,!0)};var jp=function(e){var t=this.__data__,n=Op(t,e);return n<0?void 0:t[n][1]};var Tp=function(e){return Op(this.__data__,e)>-1};var Dp=function(e,t){var n=this.__data__,r=Op(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this};function Np(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}Np.prototype.clear=Ep,Np.prototype.delete=Sp,Np.prototype.get=jp,Np.prototype.has=Tp,Np.prototype.set=Dp;var Lp=Np;var Mp=function(){this.__data__=new Lp,this.size=0};var Pp=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n};var Fp=function(e){return this.__data__.get(e)};var qp=function(e){return this.__data__.has(e)},Ip=Oc(Qu,"Map"),$p=Oc(Object,"create");var Rp=function(){this.__data__=$p?$p(null):{},this.size=0};var zp=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},Bp=Object.prototype.hasOwnProperty;var Wp=function(e){var t=this.__data__;if($p){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return Bp.call(t,e)?t[e]:void 0},Hp=Object.prototype.hasOwnProperty;var Up=function(e){var t=this.__data__;return $p?void 0!==t[e]:Hp.call(t,e)};var Vp=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=$p&&void 0===t?"__lodash_hash_undefined__":t,this};function Kp(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}Kp.prototype.clear=Rp,Kp.prototype.delete=zp,Kp.prototype.get=Wp,Kp.prototype.has=Up,Kp.prototype.set=Vp;var Yp=Kp;var Gp=function(){this.size=0,this.__data__={hash:new Yp,map:new(Ip||Lp),string:new Yp}};var Zp=function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e};var Xp=function(e,t){var n=e.__data__;return Zp(t)?n["string"==typeof t?"string":"hash"]:n.map};var Jp=function(e){var t=Xp(this,e).delete(e);return this.size-=t?1:0,t};var Qp=function(e){return Xp(this,e).get(e)};var ed=function(e){return Xp(this,e).has(e)};var td=function(e,t){var n=Xp(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this};function nd(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}nd.prototype.clear=Gp,nd.prototype.delete=Jp,nd.prototype.get=Qp,nd.prototype.has=ed,nd.prototype.set=td;var rd=nd;var id=function(e,t){var n=this.__data__;if(n instanceof Lp){var r=n.__data__;if(!Ip||r.length<199)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new rd(r)}return n.set(e,t),this.size=n.size,this};function od(e){var t=this.__data__=new Lp(e);this.size=t.size}od.prototype.clear=Mp,od.prototype.delete=Pp,od.prototype.get=Fp,od.prototype.has=qp,od.prototype.set=id;var ad=od;var sd=function(e){var t=[];if(null!=e)for(var n in Object(e))t.push(n);return t},ld=Object.prototype.hasOwnProperty;var ud=function(e){if(!cc(e))return sd(e);var t=vp(e),n=[];for(var r in e)("constructor"!=r||!t&&ld.call(e,r))&&n.push(r);return n};var cd=function(e){return xp(e)?gp(e,!0):ud(e)};var fd=function(e,t){return e&&Jf(t,cd(t),e)},pd=Un((function(e,t){var n=t&&!t.nodeType&&t,r=n&&e&&!e.nodeType&&e,i=r&&r.exports===n?Qu.Buffer:void 0,o=i?i.allocUnsafe:void 0;e.exports=function(e,t){if(t)return e.slice();var n=e.length,r=o?o(n):new e.constructor(n);return e.copy(r),r}}));var dd=function(e,t){for(var n=-1,r=null==e?0:e.length,i=0,o=[];++n<r;){var a=e[n];t(a,n,e)&&(o[i++]=a)}return o};var hd=function(){return[]},gd=Object.prototype.propertyIsEnumerable,md=Object.getOwnPropertySymbols,vd=md?function(e){return null==e?[]:(e=Object(e),dd(md(e),(function(t){return gd.call(e,t)})))}:hd;var yd=function(e,t){return Jf(e,vd(e),t)};var bd=function(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e},_d=yp(Object.getPrototypeOf,Object),wd=Object.getOwnPropertySymbols?function(e){for(var t=[];e;)bd(t,vd(e)),e=_d(e);return t}:hd;var xd=function(e,t){return Jf(e,wd(e),t)};var kd=function(e,t,n){var r=t(e);return Gc(e)?r:bd(r,n(e))};var Cd=function(e){return kd(e,kp,vd)};var Ed=function(e){return kd(e,cd,wd)},Od=Oc(Qu,"DataView"),Ad=Oc(Qu,"Promise"),Sd=Oc(Qu,"Set"),jd=vc(Od),Td=vc(Ip),Dd=vc(Ad),Nd=vc(Sd),Ld=vc(Ac),Md=uc;(Od&&"[object DataView]"!=Md(new Od(new ArrayBuffer(1)))||Ip&&"[object Map]"!=Md(new Ip)||Ad&&"[object Promise]"!=Md(Ad.resolve())||Sd&&"[object Set]"!=Md(new Sd)||Ac&&"[object WeakMap]"!=Md(new Ac))&&(Md=function(e){var t=uc(e),n="[object Object]"==t?e.constructor:void 0,r=n?vc(n):"";if(r)switch(r){case jd:return"[object DataView]";case Td:return"[object Map]";case Dd:return"[object Promise]";case Nd:return"[object Set]";case Ld:return"[object WeakMap]"}return t});var Pd=Md,Fd=Object.prototype.hasOwnProperty;var qd=function(e){var t=e.length,n=new e.constructor(t);return t&&"string"==typeof e[0]&&Fd.call(e,"index")&&(n.index=e.index,n.input=e.input),n},Id=Qu.Uint8Array;var $d=function(e){var t=new e.constructor(e.byteLength);return new Id(t).set(new Id(e)),t};var Rd=function(e,t){var n=t?$d(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)},zd=/\w*$/;var Bd=function(e){var t=new e.constructor(e.source,zd.exec(e));return t.lastIndex=e.lastIndex,t},Wd=ec?ec.prototype:void 0,Hd=Wd?Wd.valueOf:void 0;var Ud=function(e){return Hd?Object(Hd.call(e)):{}};var Vd=function(e,t){var n=t?$d(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)};var Kd=function(e,t,n){var r=e.constructor;switch(t){case"[object ArrayBuffer]":return $d(e);case"[object Boolean]":case"[object Date]":return new r(+e);case"[object DataView]":return Rd(e,n);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return Vd(e,n);case"[object Map]":return new r;case"[object Number]":case"[object String]":return new r(e);case"[object RegExp]":return Bd(e);case"[object Set]":return new r;case"[object Symbol]":return Ud(e)}};var Yd=function(e){return"function"!=typeof e.constructor||vp(e)?{}:Dc(_d(e))};var Gd=function(e){return Zc(e)&&"[object Map]"==Pd(e)},Zd=fp&&fp.isMap,Xd=Zd?cp(Zd):Gd;var Jd=function(e){return Zc(e)&&"[object Set]"==Pd(e)},Qd=fp&&fp.isSet,eh=Qd?cp(Qd):Jd,th={};th["[object Arguments]"]=th["[object Array]"]=th["[object ArrayBuffer]"]=th["[object DataView]"]=th["[object Boolean]"]=th["[object Date]"]=th["[object Float32Array]"]=th["[object Float64Array]"]=th["[object Int8Array]"]=th["[object Int16Array]"]=th["[object Int32Array]"]=th["[object Map]"]=th["[object Number]"]=th["[object Object]"]=th["[object RegExp]"]=th["[object Set]"]=th["[object String]"]=th["[object Symbol]"]=th["[object Uint8Array]"]=th["[object Uint8ClampedArray]"]=th["[object Uint16Array]"]=th["[object Uint32Array]"]=!0,th["[object Error]"]=th["[object Function]"]=th["[object WeakMap]"]=!1;var nh=function e(t,n,r,i,o,a){var s,l=1&n,u=2&n,c=4&n;if(r&&(s=o?r(t,i,o,a):r(t)),void 0!==s)return s;if(!cc(t))return t;var f=Gc(t);if(f){if(s=qd(t),!l)return Xc(t,s)}else{var p=Pd(t),d="[object Function]"==p||"[object GeneratorFunction]"==p;if(ap(t))return pd(t,l);if("[object Object]"==p||"[object Arguments]"==p||d&&!o){if(s=u||d?{}:Yd(t),!l)return u?xd(t,fd(s,t)):yd(t,Cp(s,t))}else{if(!th[p])return o?t:{};s=Kd(t,p,l)}}a||(a=new ad);var h=a.get(t);if(h)return h;a.set(t,s),eh(t)?t.forEach((function(i){s.add(e(i,n,r,i,t,a))})):Xd(t)&&t.forEach((function(i,o){s.set(o,e(i,n,r,o,t,a))}));var g=c?u?Ed:Cd:u?keysIn:kp,m=f?void 0:g(t);return gf(m||t,(function(i,o){m&&(i=t[o=i]),Xf(s,o,e(i,n,r,o,t,a))})),s};var rh=function(e){return nh(e,4)};function ih(e,t,n){var r=Vf(e,8,void 0,void 0,void 0,void 0,void 0,t=n?void 0:t);return r.placeholder=ih.placeholder,r}ih.placeholder={};var oh=ih,ah=Function.prototype,sh=Object.prototype,lh=ah.toString,uh=sh.hasOwnProperty,ch=lh.call(Object);var fh=function(e){if(!Zc(e)||"[object Object]"!=uc(e))return!1;var t=_d(e);if(null===t)return!0;var n=uh.call(t,"constructor")&&t.constructor;return"function"==typeof n&&n instanceof n&&lh.call(n)==ch};var ph=function(e){if(!Zc(e))return!1;var t=uc(e);return"[object Error]"==t||"[object DOMException]"==t||"string"==typeof e.message&&"string"==typeof e.name&&!fh(e)};var dh=function(e){return Zc(e)&&"[object WeakMap]"==Pd(e)};var hh=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this};var gh=function(e){return this.__data__.has(e)};function mh(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new rd;++t<n;)this.add(e[t])}mh.prototype.add=mh.prototype.push=hh,mh.prototype.has=gh;var vh=mh;var yh=function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1};var bh=function(e,t){return e.has(t)};var _h=function(e,t,n,r,i,o){var a=1&n,s=e.length,l=t.length;if(s!=l&&!(a&&l>s))return!1;var u=o.get(e);if(u&&o.get(t))return u==t;var c=-1,f=!0,p=2&n?new vh:void 0;for(o.set(e,t),o.set(t,e);++c<s;){var d=e[c],h=t[c];if(r)var g=a?r(h,d,c,t,e,o):r(d,h,c,e,t,o);if(void 0!==g){if(g)continue;f=!1;break}if(p){if(!yh(t,(function(e,t){if(!bh(p,t)&&(d===e||i(d,e,n,r,o)))return p.push(t)}))){f=!1;break}}else if(d!==h&&!i(d,h,n,r,o)){f=!1;break}}return o.delete(e),o.delete(t),f};var wh=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n};var xh=function(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n},kh=ec?ec.prototype:void 0,Ch=kh?kh.valueOf:void 0;var Eh=function(e,t,n,r,i,o,a){switch(n){case"[object DataView]":if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case"[object ArrayBuffer]":return!(e.byteLength!=t.byteLength||!o(new Id(e),new Id(t)));case"[object Boolean]":case"[object Date]":case"[object Number]":return Gf(+e,+t);case"[object Error]":return e.name==t.name&&e.message==t.message;case"[object RegExp]":case"[object String]":return e==t+"";case"[object Map]":var s=wh;case"[object Set]":var l=1&r;if(s||(s=xh),e.size!=t.size&&!l)return!1;var u=a.get(e);if(u)return u==t;r|=2,a.set(e,t);var c=_h(s(e),s(t),r,i,o,a);return a.delete(e),c;case"[object Symbol]":if(Ch)return Ch.call(e)==Ch.call(t)}return!1},Oh=Object.prototype.hasOwnProperty;var Ah=function(e,t,n,r,i,o){var a=1&n,s=Cd(e),l=s.length;if(l!=Cd(t).length&&!a)return!1;for(var u=l;u--;){var c=s[u];if(!(a?c in t:Oh.call(t,c)))return!1}var f=o.get(e);if(f&&o.get(t))return f==t;var p=!0;o.set(e,t),o.set(t,e);for(var d=a;++u<l;){var h=e[c=s[u]],g=t[c];if(r)var m=a?r(g,h,c,t,e,o):r(h,g,c,e,t,o);if(!(void 0===m?h===g||i(h,g,n,r,o):m)){p=!1;break}d||(d="constructor"==c)}if(p&&!d){var v=e.constructor,y=t.constructor;v==y||!("constructor"in e)||!("constructor"in t)||"function"==typeof v&&v instanceof v&&"function"==typeof y&&y instanceof y||(p=!1)}return o.delete(e),o.delete(t),p},Sh=Object.prototype.hasOwnProperty;var jh=function(e,t,n,r,i,o){var a=Gc(e),s=Gc(t),l=a?"[object Array]":Pd(e),u=s?"[object Array]":Pd(t),c="[object Object]"==(l="[object Arguments]"==l?"[object Object]":l),f="[object Object]"==(u="[object Arguments]"==u?"[object Object]":u),p=l==u;if(p&&ap(e)){if(!ap(t))return!1;a=!0,c=!1}if(p&&!c)return o||(o=new ad),a||dp(e)?_h(e,t,n,r,i,o):Eh(e,t,l,n,r,i,o);if(!(1&n)){var d=c&&Sh.call(e,"__wrapped__"),h=f&&Sh.call(t,"__wrapped__");if(d||h){var g=d?e.value():e,m=h?t.value():t;return o||(o=new ad),i(g,m,n,r,o)}}return!!p&&(o||(o=new ad),Ah(e,t,n,r,i,o))};var Th=function e(t,n,r,i,o){return t===n||(null==t||null==n||!Zc(t)&&!Zc(n)?t!=t&&n!=n:jh(t,n,r,i,e,o))};var Dh=function(e,t,n,r){var i=n.length,o=i,a=!r;if(null==e)return!o;for(e=Object(e);i--;){var s=n[i];if(a&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++i<o;){var l=(s=n[i])[0],u=e[l],c=s[1];if(a&&s[2]){if(void 0===u&&!(l in e))return!1}else{var f=new ad;if(r)var p=r(u,c,l,e,t,f);if(!(void 0===p?Th(c,u,3,r,f):p))return!1}}return!0};var Nh=function(e){return e==e&&!cc(e)};var Lh=function(e){for(var t=kp(e),n=t.length;n--;){var r=t[n],i=e[r];t[n]=[r,i,Nh(i)]}return t};var Mh=function(e,t){return function(n){return null!=n&&(n[e]===t&&(void 0!==t||e in Object(n)))}};var Ph=function(e){var t=Lh(e);return 1==t.length&&t[0][2]?Mh(t[0][0],t[0][1]):function(n){return n===e||Dh(n,e,t)}},Fh=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,qh=/^\w*$/;var Ih=function(e,t){if(Gc(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!Ff(e))||(qh.test(e)||!Fh.test(e)||null!=t&&e in Object(t))};function $h(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var a=e.apply(this,r);return n.cache=o.set(i,a)||o,a};return n.cache=new($h.Cache||rd),n}$h.Cache=rd;var Rh=$h;var zh=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Bh=/\\(\\)?/g,Wh=function(e){var t=Rh(e,(function(e){return 500===n.size&&n.clear(),e})),n=t.cache;return t}((function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(zh,(function(e,n,r,i){t.push(r?i.replace(Bh,"$1"):n||e)})),t}));var Hh=function(e,t){for(var n=-1,r=null==e?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i},Uh=ec?ec.prototype:void 0,Vh=Uh?Uh.toString:void 0;var Kh=function e(t){if("string"==typeof t)return t;if(Gc(t))return Hh(t,e)+"";if(Ff(t))return Vh?Vh.call(t):"";var n=t+"";return"0"==n&&1/t==-Infinity?"-0":n};var Yh=function(e){return null==e?"":Kh(e)};var Gh=function(e,t){return Gc(e)?e:Ih(e,t)?[e]:Wh(Yh(e))};var Zh=function(e){if("string"==typeof e||Ff(e))return e;var t=e+"";return"0"==t&&1/e==-Infinity?"-0":t};var Xh=function(e,t){for(var n=0,r=(t=Gh(t,e)).length;null!=e&&n<r;)e=e[Zh(t[n++])];return n&&n==r?e:void 0};var Jh=function(e,t,n){var r=null==e?void 0:Xh(e,t);return void 0===r?n:r};var Qh=function(e,t){return null!=e&&t in Object(e)};var eg=function(e,t,n){for(var r=-1,i=(t=Gh(t,e)).length,o=!1;++r<i;){var a=Zh(t[r]);if(!(o=null!=e&&n(e,a)))break;e=e[a]}return o||++r!=i?o:!!(i=null==e?0:e.length)&&sp(i)&&Af(a,i)&&(Gc(e)||ip(e))};var tg=function(e,t){return null!=e&&eg(e,t,Qh)};var ng=function(e,t){return Ih(e)&&Nh(t)?Mh(Zh(e),t):function(n){var r=Jh(n,e);return void 0===r&&r===t?tg(n,e):Th(t,r,3)}};var rg=function(e){return function(t){return null==t?void 0:t[e]}};var ig=function(e){return function(t){return Xh(t,e)}};var og=function(e){return Ih(e)?rg(Zh(e)):ig(e)};var ag=function(e){return"function"==typeof e?e:null==e?Zu:"object"==typeof e?Gc(e)?ng(e[0],e[1]):Ph(e):og(e)};var sg=function(e){return ag("function"==typeof e?e:nh(e,1))},lg=ec?ec.isConcatSpreadable:void 0;var ug=function(e){return Gc(e)||ip(e)||!!(lg&&e&&e[lg])};var cg=function e(t,n,r,i,o){var a=-1,s=t.length;for(r||(r=ug),o||(o=[]);++a<s;){var l=t[a];n>0&&r(l)?n>1?e(l,n-1,r,i,o):bd(o,l):i||(o[o.length]=l)}return o};var fg=function(e){return(null==e?0:e.length)?cg(e,1):[]},pg=Math.max;var dg=function(e,t,n){return t=pg(void 0===t?e.length-1:t,0),function(){for(var r=arguments,i=-1,o=pg(r.length-t,0),a=Array(o);++i<o;)a[i]=r[t+i];i=-1;for(var s=Array(t+1);++i<t;)s[i]=r[i];return s[t]=n(a),Mc(e,this,s)}};var hg=function(e){return hf(dg(e,void 0,fg),e+"")}((function(e,t){return Vf(e,256,void 0,void 0,void 0,t)}));var gg=function(e){return Gc(e)?Hh(e,Zh):Ff(e)?[e]:Xc(Wh(Yh(e)))},mg={ary:Kf,assign:Cp,clone:rh,curry:oh,forEach:gf,isArray:Gc,isError:ph,isFunction:pc,isWeakMap:dh,iteratee:sg,keys:wp,rearg:hg,toInteger:Hf,toPath:gg};var vg=function(e,t,n){return Qn(mg,e,t,n)};var yg=function(e,t,n,r){for(var i=-1,o=null==e?0:e.length;++i<o;){var a=e[i];t(r,a,n(a),e)}return r};var bg=function(e){return function(t,n,r){for(var i=-1,o=Object(t),a=r(t),s=a.length;s--;){var l=a[e?s:++i];if(!1===n(o[l],l,o))break}return t}}();var _g=function(e,t){return function(n,r){if(null==n)return n;if(!xp(n))return e(n,r);for(var i=n.length,o=t?i:-1,a=Object(n);(t?o--:++o<i)&&!1!==r(a[o],o,a););return n}}((function(e,t){return e&&bg(e,t,kp)}));var wg=function(e,t,n,r){return _g(e,(function(e,i,o){t(r,e,n(e),o)})),r};var xg=function(e,t){return function(n,r){var i=Gc(n)?yg:wg,o=t?t():{};return i(n,e,ag(r),o)}},kg=Object.prototype.hasOwnProperty,Cg=vg("groupBy",xg((function(e,t,n){kg.call(e,n)?e[n].push(t):Yf(e,n,[t])})));Cg.placeholder=Yn;var Eg=Cg,Og=Un((function(e,t){e.exports=function e(t,n,r){var i,o,a=window,s="application/octet-stream",l=r||s,u=t,c=!n&&!r&&u,f=document.createElement("a"),p=function(e){return String(e)},d=a.Blob||a.MozBlob||a.WebKitBlob||p,h=n||"download";if(d=d.call?d.bind(a):Blob,"true"===String(this)&&(l=(u=[u,l])[0],u=u[1]),c&&c.length<2048&&(h=c.split("/").pop().split("?")[0],f.href=c,-1!==f.href.indexOf(c))){var g=new XMLHttpRequest;return g.open("GET",c,!0),g.responseType="blob",g.onload=function(t){e(t.target.response,h,s)},setTimeout((function(){g.send()}),0),g}if(/^data:([\w+-]+\/[\w+.-]+)?[,;]/.test(u)){if(!(u.length>2096103.424&&d!==p))return navigator.msSaveBlob?navigator.msSaveBlob(b(u),h):_(u);l=(u=b(u)).type||s}else if(/([\x80-\xff])/.test(u)){for(var m=0,v=new Uint8Array(u.length),y=v.length;m<y;++m)v[m]=u.charCodeAt(m);u=new d([v],{type:l})}function b(e){for(var t=e.split(/[:;,]/),n=t[1],r=("base64"==t[2]?atob:decodeURIComponent)(t.pop()),i=r.length,o=0,a=new Uint8Array(i);o<i;++o)a[o]=r.charCodeAt(o);return new d([a],{type:n})}function _(e,t){if("download"in f)return f.href=e,f.setAttribute("download",h),f.className="download-js-link",f.innerHTML="downloading...",f.style.display="none",document.body.appendChild(f),setTimeout((function(){f.click(),document.body.removeChild(f),!0===t&&setTimeout((function(){a.URL.revokeObjectURL(f.href)}),250)}),66),!0;if(/(Version)\/(\d+)\.(\d+)(?:\.(\d+))?.*Safari\//.test(navigator.userAgent))return/^data:/.test(e)&&(e="data:"+e.replace(/^data:([\w\/\-\+]+)/,s)),window.open(e)||confirm("Displaying New Document\n\nUse Save As... to download, then click back to return to this page.")&&(location.href=e),!0;var n=document.createElement("iframe");document.body.appendChild(n),!t&&/^data:/.test(e)&&(e="data:"+e.replace(/^data:([\w\/\-\+]+)/,s)),n.src=e,setTimeout((function(){document.body.removeChild(n)}),333)}if(i=u instanceof d?u:new d([u],{type:l}),navigator.msSaveBlob)return navigator.msSaveBlob(i,h);if(a.URL)_(a.URL.createObjectURL(i),!0);else{if("string"==typeof i||i.constructor===p)try{return _("data:"+l+";base64,"+a.btoa(i))}catch(w){return _("data:"+l+","+encodeURIComponent(i))}(o=new FileReader).onload=function(e){_(this.result)},o.readAsDataURL(i)}return!0}}));function Ag(e){let t,n;const r=e[3].default,i=v(r,e,e[2],null);return{c(){t=P("div"),i&&i.c()},l(e){t=Y(e,"DIV",{});var n=K(t);i&&i.l(n),n.forEach(L)},m(r,o){N(r,t,o),i&&i.m(t,null),e[4](t),n=!0},p(e,[t]){i&&i.p&&4&t&&b(i,r,e,e[2],t,null,null)},i(e){n||(Ue(i,e),n=!0)},o(e){Ve(i,e),n=!1},d(n){n&&L(t),i&&i.d(n),e[4](null)}}}function Sg(e,t,n){let r,i,o,{$$slots:a={},$$scope:s}=t,{target:l=document.body}=t;return ve((()=>{if("string"==typeof l){if(r=document.querySelector(l),null===r)return()=>{}}else{if(!(l instanceof HTMLElement))throw new TypeError(`Unknown target type: ${typeof l}. Allowed types: String (CSS selector), HTMLElement.`);r=l}return i=document.createElement("div"),r.appendChild(i),i.appendChild(o),()=>{r.removeChild(i)}})),e.$$set=e=>{"target"in e&&n(1,l=e.target),"$$scope"in e&&n(2,s=e.$$scope)},[o,l,s,a,function(e){Ee[e?"unshift":"push"]((()=>{o=e,n(0,o)}))}]}class jg extends pt{constructor(e){super(),ft(this,e,Sg,Ag,d,{target:1})}}function Tg(e){let t="";for(let n in e)if(e[n]){t+=`${Dg(n)}: ${e[n]}; `}return t}const Dg=e=>e.replace(/[A-Z]/g,(e=>`-${e.toLowerCase()}`)),Ng=(e,t,n)=>{const r=()=>{setTimeout(e,t)};return n&&r(),r};function Lg(e){let t,n,r;const i=e[7].default,o=v(i,e,e[6],null);return{c(){t=P("div"),o&&o.c(),this.h()},l(e){t=Y(e,"DIV",{style:!0,class:!0});var n=K(t);o&&o.l(n),n.forEach(L),this.h()},h(){H(t,"style",e[0]),H(t,"class","svelte-1gyo73z")},m(e,n){N(e,t,n),o&&o.m(t,null),r=!0},p(e,[n]){o&&o.p&&64&n&&b(o,i,e,e[6],n,null,null),(!r||1&n)&&H(t,"style",e[0])},i(e){r||(Ue(o,e),n||Ne((()=>{n=Ye(t,uu,{}),n.start()})),r=!0)},o(e){Ve(o,e),r=!1},d(e){e&&L(t),o&&o.d(e)}}}function Mg(e,t,n){let r,{$$slots:i={},$$scope:o}=t,{backgroundSize:a="10px"}=t,{borderRadius:s=""}=t,{height:l=""}=t,{width:u=""}=t,{margin:c=""}=t;return e.$$set=e=>{"backgroundSize"in e&&n(1,a=e.backgroundSize),"borderRadius"in e&&n(2,s=e.borderRadius),"height"in e&&n(3,l=e.height),"width"in e&&n(4,u=e.width),"margin"in e&&n(5,c=e.margin),"$$scope"in e&&n(6,o=e.$$scope)},e.$$.update=()=>{62&e.$$.dirty&&n(0,r=Tg({backgroundSize:a,borderRadius:s,height:l,width:u,margin:c}))},[r,a,s,l,u,c,o,i]}class Pg extends pt{constructor(e){super(),ft(this,e,Mg,Lg,d,{backgroundSize:1,borderRadius:2,height:3,width:4,margin:5})}}function Fg(e){let t=!1;const n=()=>t=!1,r=n=>{t=!0,qg(e,n)};function i(n){t&&qg(e,n)}return window.addEventListener("mousedown",r),window.addEventListener("mouseup",n),window.addEventListener("mousemove",i),{destroy(){window.removeEventListener("mousedown",r),window.removeEventListener("mouseup",n),window.removeEventListener("mousemove",i)}}}function qg(e,t){const{left:n,top:r,width:i,height:o}=e.getBoundingClientRect();let a=t.clientX-n,s=t.clientY-r;(function(e,t,n,r){return e>0&&t>0&&e<n&&t<r})(a,s,i,o)&&e.dispatchEvent(new CustomEvent("drag",{detail:{mouseX:a,mouseY:s}}))}function Ig(e,t=[]){const n=Object.entries(t);let r=[];for(let[o,a]of n){let e=i(o,a);r=[...r,e]}function i(t,n){let r=function(e,t){return()=>{let n=parseInt(e);n?event.keyCode===n&&t(event):event.key===e&&t(event)}}(t,n);return e.addEventListener("keydown",r),r}return{destroy(){r.forEach((t=>e.removeEventListener("keypress",t)))}}}function $g(e){let t,n,r,i;return{c(){t=P("span"),this.h()},l(e){t=Y(e,"SPAN",{class:!0}),K(t).forEach(L),this.h()},h(){H(t,"class","svelte-2v17vl")},m(n,o){N(n,t,o),r||(i=R(t,"click",e[4]),r=!0)},p:a,i(e){n||Ne((()=>{n=Ye(t,uu,{}),n.start()}))},o:a,d(e){e&&L(t),r=!1,i()}}}function Rg(e){let t,n,r,i,o,s=e[0]&&$g(e);return{c(){t=P("div"),s&&s.c(),this.h()},l(e){t=Y(e,"DIV",{tabindex:!0,title:!0,class:!0,style:!0});var n=K(t);s&&s.l(n),n.forEach(L),this.h()},h(){H(t,"tabindex","0"),H(t,"title",e[1]),H(t,"class","swatch svelte-2v17vl"),H(t,"style",n=`background: ${e[1]};`)},m(n,r){N(n,t,r),s&&s.m(t,null),i||(o=[C(Ig.call(null,t,{Enter:e[5]})),R(t,"mouseover",e[6]),R(t,"mouseleave",e[7]),R(t,"click",W(e[3]))],i=!0)},p(e,r){e[0]?s?(s.p(e,r),1&r&&Ue(s,1)):(s=$g(e),s.c(),Ue(s,1),s.m(t,null)):s&&(s.d(1),s=null),2&r&&H(t,"title",e[1]),2&r&&n!==(n=`background: ${e[1]};`)&&H(t,"style",n)},i(e){Ue(s),r||Ne((()=>{r=Ye(t,uu,{}),r.start()}))},o:a,d(e){e&&L(t),s&&s.d(),i=!1,f(o)}}}function zg(e){let t,n,r;return n=new Pg({props:{borderRadius:"6px",$$slots:{default:[Rg]},$$scope:{ctx:e}}}),{c(){t=P("div"),st(n.$$.fragment),this.h()},l(e){t=Y(e,"DIV",{class:!0});var r=K(t);lt(n.$$.fragment,r),r.forEach(L),this.h()},h(){H(t,"class","space svelte-2v17vl")},m(e,i){N(e,t,i),ut(n,t,null),r=!0},p(e,[t]){const r={};259&t&&(r.$$scope={dirty:t,ctx:e}),n.$set(r)},i(e){r||(Ue(n.$$.fragment,e),r=!0)},o(e){Ve(n.$$.fragment,e),r=!1},d(e){e&&L(t),ct(n)}}}function Bg(e,t,n){let{hovered:r=!1}=t,{color:i="#fff"}=t;const o=_e();return e.$$set=e=>{"hovered"in e&&n(0,r=e.hovered),"color"in e&&n(1,i=e.color)},[r,i,o,function(t){ke(e,t)},()=>o("removeswatch"),()=>o("click"),()=>n(0,r=!0),()=>n(0,r=!1)]}class Wg extends pt{constructor(e){super(),ft(this,e,Bg,zg,d,{hovered:0,color:1})}}function Hg(e){let t,n,r,i,o;return{c(){t=P("div"),n=P("div"),this.h()},l(e){t=Y(e,"DIV",{tabindex:!0,class:!0});var r=K(t);n=Y(r,"DIV",{class:!0,style:!0}),K(n).forEach(L),r.forEach(L),this.h()},h(){H(n,"class","slider-thumb svelte-cn6le8"),H(n,"style",e[3]),H(t,"tabindex","0"),H(t,"class","color-format-slider svelte-cn6le8"),Ne((()=>e[11].call(t))),ie(t,"hue","hue"===e[0]),ie(t,"alpha","alpha"===e[0])},m(a,s){N(a,t,s),D(t,n),e[9](t),r=re(t,e[11].bind(t)),i||(o=[C(Ig.call(null,t,{37:e[5],39:e[6]})),C(Fg.call(null,t)),R(t,"drag",e[10])],i=!0)},p(e,[r]){8&r&&H(n,"style",e[3]),1&r&&ie(t,"hue","hue"===e[0]),1&r&&ie(t,"alpha","alpha"===e[0])},i:a,o:a,d(n){n&&L(t),e[9](null),r(),i=!1,f(o)}}}function Ug(e,t,n){let r,i,{value:o=1}=t,{type:a="hue"}=t;const s=_e();let l,u=0,c="hue"===a?360:1,f="hue"===a?1:.01;const p=e=>e>=0&&e<=c;function d({mouseX:e}){let t=(e/u).toFixed(2);if(t>=0&&t<=1){s("change",{color:"hue"===a?360*t:t})}}return e.$$set=e=>{"value"in e&&n(7,o=e.value),"type"in e&&n(0,a=e.type)},e.$$.update=()=>{131&e.$$.dirty&&n(8,r="hue"===a?u*(o/360):u*o),256&e.$$.dirty&&n(3,i=`transform: translateX(${r-6}px);`)},[a,u,l,i,d,function(){let e=o-f;p(e)&&(n(7,o=e),s("change",{color:o}))},function(){let e=o+f;p(e)&&(n(7,o=e),s("change",{color:o}))},o,r,function(e){Ee[e?"unshift":"push"]((()=>{l=e,n(2,l)}))},e=>d(e.detail),function(){u=this.clientWidth,n(1,u)}]}class Vg extends pt{constructor(e){super(),ft(this,e,Ug,Hg,d,{value:7,type:0})}}function Kg(e){let t,n,r,i,o;return{c(){t=P("div"),n=P("div"),this.h()},l(e){t=Y(e,"DIV",{class:!0,style:!0});var r=K(t);n=Y(r,"DIV",{class:!0,style:!0}),K(n).forEach(L),r.forEach(L),this.h()},h(){H(n,"class","picker svelte-fk9ote"),H(n,"style",e[4]),H(t,"class","palette svelte-fk9ote"),H(t,"style",e[3]),Ne((()=>e[14].call(t)))},m(a,s){N(a,t,s),D(t,n),e[13](t),r=re(t,e[14].bind(t)),i||(o=[C(Fg.call(null,t)),R(t,"drag",e[15])],i=!0)},p(e,r){16&r&&H(n,"style",e[4]),8&r&&H(t,"style",e[3])},d(n){n&&L(t),e[13](null),r(),i=!1,f(o)}}}function Yg(e){let t,n;return t=new Pg({props:{width:"100%",$$slots:{default:[Kg]},$$scope:{ctx:e}}}),{c(){st(t.$$.fragment)},l(e){lt(t.$$.fragment,e)},m(e,r){ut(t,e,r),n=!0},p(e,[n]){const r={};131103&n&&(r.$$scope={dirty:n,ctx:e}),t.$set(r)},i(e){n||(Ue(t.$$.fragment,e),n=!0)},o(e){Ve(t.$$.fragment,e),n=!1},d(e){ct(t,e)}}}function Gg(e,t,n){let r,i,o,a,s;const l=_e();let u,c,{h:f=0}=t,{s:p=0}=t,{v:d=0}=t,{a:h=1}=t,g=0;function m({mouseX:e,mouseY:t}){l("change",{s:e/g*100,v:100-t/c*100})}return e.$$set=e=>{"h"in e&&n(6,f=e.h),"s"in e&&n(7,p=e.s),"v"in e&&n(8,d=e.v),"a"in e&&n(9,h=e.a)},e.$$.update=()=>{130&e.$$.dirty&&n(10,r=p*g/100),257&e.$$.dirty&&n(11,i=c*((100-d)/100)),576&e.$$.dirty&&n(12,o=`linear-gradient(to top, rgba(0, 0, 0, 1), transparent),\n linear-gradient(to left, hsla(${f}, 100%, 50%, ${h}), rgba(255, 255, 255, ${h}))\n `),4096&e.$$.dirty&&n(3,a=`background: ${o};`),3072&e.$$.dirty&&n(4,s=`transform: translate(${r-8}px, ${i-8}px);`)},[c,g,u,a,s,m,f,p,d,h,r,i,o,function(e){Ee[e?"unshift":"push"]((()=>{u=e,n(2,u)}))},function(){c=this.clientHeight,g=this.clientWidth,n(0,c),n(1,g)},e=>m(e.detail)]}class Zg extends pt{constructor(e){super(),ft(this,e,Gg,Yg,d,{h:6,s:7,v:8,a:9})}}function Xg(e){let t,n,r,i;return{c(){t=P("div"),n=q(e[0]),this.h()},l(r){t=Y(r,"DIV",{class:!0,tabindex:!0});var i=K(t);n=G(i,e[0]),i.forEach(L),this.h()},h(){H(t,"class","flatbutton svelte-3agxxj"),H(t,"tabindex","0"),ie(t,"selected",e[1])},m(o,a){N(o,t,a),D(t,n),r||(i=[C(Ig.call(null,t,{Enter:e[4]})),R(t,"click",e[3])],r=!0)},p(e,[r]){1&r&&X(n,e[0]),2&r&&ie(t,"selected",e[1])},i:a,o:a,d(e){e&&L(t),r=!1,f(i)}}}function Jg(e,t,n){let{text:r=""}=t,{selected:i=!1}=t;const o=_e();return e.$$set=e=>{"text"in e&&n(0,r=e.text),"selected"in e&&n(1,i=e.selected)},[r,i,o,function(t){ke(e,t)},()=>o("click")]}class Qg extends pt{constructor(e){super(),ft(this,e,Jg,Xg,d,{text:0,selected:1})}}function em(e,t,n){const r=e.slice();return r[4]=t[n],r}function tm(e){let t,n;return t=new Qg({props:{selected:e[0]===e[4],text:e[4]}}),t.$on("click",(function(){return e[3](e[4])})),{c(){st(t.$$.fragment)},l(e){lt(t.$$.fragment,e)},m(e,r){ut(t,e,r),n=!0},p(n,r){e=n;const i={};1&r&&(i.selected=e[0]===e[4]),t.$set(i)},i(e){n||(Ue(t.$$.fragment,e),n=!0)},o(e){Ve(t.$$.fragment,e),n=!1},d(e){ct(t,e)}}}function nm(e){let t,n,r=e[2],i=[];for(let a=0;a<r.length;a+=1)i[a]=tm(em(e,r,a));const o=e=>Ve(i[e],1,1,(()=>{i[e]=null}));return{c(){t=P("div");for(let e=0;e<i.length;e+=1)i[e].c();this.h()},l(e){t=Y(e,"DIV",{class:!0});var n=K(t);for(let t=0;t<i.length;t+=1)i[t].l(n);n.forEach(L),this.h()},h(){H(t,"class","flatbutton-group svelte-1w3nliy")},m(e,r){N(e,t,r);for(let n=0;n<i.length;n+=1)i[n].m(t,null);n=!0},p(e,[n]){if(7&n){let a;for(r=e[2],a=0;a<r.length;a+=1){const o=em(e,r,a);i[a]?(i[a].p(o,n),Ue(i[a],1)):(i[a]=tm(o),i[a].c(),Ue(i[a],1),i[a].m(t,null))}for(We(),a=r.length;a<i.length;a+=1)o(a);He()}},i(e){if(!n){for(let e=0;e<r.length;e+=1)Ue(i[e]);n=!0}},o(e){i=i.filter(Boolean);for(let t=0;t<i.length;t+=1)Ve(i[t]);n=!1},d(e){e&&L(t),M(i,e)}}}function rm(e,t,n){const r=_e();let{format:i="hex"}=t;return e.$$set=e=>{"format"in e&&n(0,i=e.format)},[i,r,["hex","rgb","hsl"],e=>r("click",e)]}class im extends pt{constructor(e){super(),ft(this,e,rm,nm,d,{format:0})}}function om(e){let t,n,r,i;return{c(){t=P("div"),n=P("input"),this.h()},l(e){t=Y(e,"DIV",{class:!0});var r=K(t);n=Y(r,"INPUT",{type:!0,value:!0,maxlength:!0,class:!0}),r.forEach(L),this.h()},h(){H(n,"type","text"),n.value=e[0],H(n,"maxlength","25"),H(n,"class","svelte-1cnq0e1"),H(t,"class","svelte-1cnq0e1")},m(o,a){N(o,t,a),D(t,n),r||(i=[R(n,"input",e[1]),R(n,"change",e[2])],r=!0)},p(e,[t]){1&t&&n.value!==e[0]&&(n.value=e[0])},i:a,o:a,d(e){e&&L(t),r=!1,f(i)}}}function am(e,t,n){let{value:r=""}=t;return e.$$set=e=>{"value"in e&&n(0,r=e.value)},[r,function(t){ke(e,t)},function(t){ke(e,t)}]}class sm extends pt{constructor(e){super(),ft(this,e,am,om,d,{value:0})}}const lm=/[a-z()\s]/gi,um=e=>e.replace(lm,"").split(",").map((e=>""!==e?e:void 0)),cm=e=>{const t=um(e),[n,r,i,o]=t;let a=e.startsWith("rgb(")&&3===t.length||e.startsWith("rgba(")&&4===t.length,s=[n,r,i].every((e=>e>=0&&e<=255)),l=!e.startsWith("rgba(")||`${o}`.length<=4&&o>=0&&o<=1;return a&&s&&l},fm=e=>{const t=um(e),[n,r,i,o]=t;if([n,r,i].some((e=>void 0===e)))return!1;let a=e.startsWith("hsl(")&&3===t.length||e.startsWith("hsla(")&&4===t.length,s=n>=0&&n<=360,l=[r,i].every((e=>e.endsWith("%")&&parseInt(e)>=0&&parseInt(e)<=100)),u=!e.startsWith("hsla(")||`${o}`.length<=4&&o>=0&&o<=1;return a&&s&&l&&u},pm=e=>{if("string"==typeof e){if(/^#(?:[A-F0-9]{3}$|[A-F0-9]{4}$|[A-F0-9]{6}$|[A-F0-9]{8})$/gi.test(e))return"hex";if((e=>{if(/^(?:rgba\(|rgb\()(?:[0-9,\s]|\.(?=\d))*\)$/gi.test(e))return cm(e.toLowerCase())})(e))return"rgb";if((e=>{if(/^(?:hsl\(|hsla\()(?:[0-9,%\s]|\.(?=\d))*\)$/gi.test(e))return fm(e.toLowerCase())})(e))return"hsl"}},dm=(e,t)=>{switch(t){case"hex":return _m(e,!0);case"rgb":return wm(e,!0);case"hsl":return xm(e)}},hm=e=>{let[t,n,r,i]=(e=>{if(e.length<=5)return e.match(/[A-F0-9]/gi).map((e=>e+e));return e.match(/[A-F0-9]{2}/gi)})(e);return vm([t,n,r],i)},gm=e=>{let t=um(e);return ym(t)},mm=e=>{let t=um(e);return bm(t)},vm=(e,t="FF")=>{const n=e.map((e=>parseInt(e,16))).concat(Number((parseInt(t,16)/255).toFixed(2)));return ym(n)},ym=e=>{const[t,n,r,i=1]=e;return[...Cm([t,n,r]),i].map((e=>parseFloat(e)))},bm=([e,t,n,r=1])=>{let i=t.replace(/%/,""),o=n.replace(/%/,"");return[...km([e,i,o]),r].map((e=>parseFloat(e)))},_m=(e,t=!1)=>{const[n,r,i,o]=wm(e),a=e=>1===e.length?`0${e}`:e;let s=[n,r,i].map((e=>{let t=Math.round(e).toString(16);return a(t)})),l=a(Math.round(255*o).toString(16));return s=[...s,l],t?`#${s.join("")}`:s},wm=([e,t,n,r=1],i=!1)=>{let o=[...Em([e,t,n]).map((e=>Math.round(e))),r<1?Am(r,2):r];return i?`rgba(${o.join(",")})`:o},xm=([e,t,n,r=1])=>{let[i,o,a]=Om([e,t,n]);return`hsla(${[i,o+"%",a+"%",r<1?Am(r,2):r].join(",")})`},km=e=>{const t=e[0];let n=e[1]/100,r=e[2]/100,i=n;const o=Math.max(r,.01);r*=2,n*=r<=1?r:2-r,i*=o<=1?o:2-o;return[t,100*(0===r?2*i/(o+i):2*n/(r+n)),100*((r+n)/2)]},Cm=e=>{let t,n,r,i,o;const a=e[0]/255,s=e[1]/255,l=e[2]/255,u=Math.max(a,s,l),c=u-Math.min(a,s,l),f=function(e){return(u-e)/6/c+.5};0===c?(i=0,o=0):(o=c/u,t=f(a),n=f(s),r=f(l),a===u?i=r-n:s===u?i=1/3+t-r:l===u&&(i=2/3+n-t),i<0?i+=1:i>1&&(i-=1));return[360*i,100*o,100*u].map((e=>Math.round(e)))},Em=e=>{const t=e[0]/60,n=e[1]/100;let r=e[2]/100;const i=Math.floor(t)%6,o=t-Math.floor(t),a=255*r*(1-n),s=255*r*(1-n*o),l=255*r*(1-n*(1-o));switch(r*=255,i){case 0:return[r,l,a];case 1:return[s,r,a];case 2:return[a,r,l];case 3:return[a,s,r];case 4:return[l,a,r];case 5:return[r,a,s]}},Om=e=>{const t=e[0],n=e[1]/100,r=e[2]/100,i=Math.max(r,.01);let o,a;a=(2-n)*r;const s=(2-n)*i;return o=n*i,o/=s<=1?s:2-s,o=o||0,a/=2,[Am(t,0),Am(100*o,0),Am(100*a,0)]},Am=(e,t)=>Number(parseFloat(e).toFixed(t));function Sm(e,t,n){const r=e.slice();return r[41]=t[n],r[43]=n,r}function jm(e){let t;return{c(){t=P("div"),this.h()},l(e){t=Y(e,"DIV",{class:!0,title:!0,style:!0}),K(t).forEach(L),this.h()},h(){H(t,"class","selected-color svelte-dwzpo6"),H(t,"title",e[0]),H(t,"style",e[13])},m(e,n){N(e,t,n)},p(e,n){1&n[0]&&H(t,"title",e[0]),8192&n[0]&&H(t,"style",e[13])},d(e){e&&L(t)}}}function Tm(e){let t,n;return t=new Vg({props:{type:"alpha",value:e[12]}}),t.$on("change",e[28]),{c(){st(t.$$.fragment)},l(e){lt(t.$$.fragment,e)},m(e,r){ut(t,e,r),n=!0},p(e,n){const r={};4096&n[0]&&(r.value=e[12]),t.$set(r)},i(e){n||(Ue(t.$$.fragment,e),n=!0)},o(e){Ve(t.$$.fragment,e),n=!1},d(e){ct(t,e)}}}function Dm(e){let t,n,r,i,o=e[14]&&Nm(e),a=e[1].length<12&&Mm(e);return{c(){t=P("div"),o&&o.c(),n=I(),a&&a.c(),this.h()},l(e){t=Y(e,"DIV",{class:!0});var r=K(t);o&&o.l(r),n=Z(r),a&&a.l(r),r.forEach(L),this.h()},h(){H(t,"class","swatch-panel svelte-dwzpo6")},m(e,r){N(e,t,r),o&&o.m(t,null),D(t,n),a&&a.m(t,null),i=!0},p(e,r){e[14]?o?(o.p(e,r),16384&r[0]&&Ue(o,1)):(o=Nm(e),o.c(),Ue(o,1),o.m(t,n)):o&&(We(),Ve(o,1,1,(()=>{o=null})),He()),e[1].length<12?a?(a.p(e,r),2&r[0]&&Ue(a,1)):(a=Mm(e),a.c(),Ue(a,1),a.m(t,null)):a&&(We(),Ve(a,1,1,(()=>{a=null})),He())},i(e){i||(Ue(o),Ue(a),Ne((()=>{r||(r=Ze(t,uu,{},!0)),r.run(1)})),i=!0)},o(e){Ve(o),Ve(a),r||(r=Ze(t,uu,{},!1)),r.run(0),i=!1},d(e){e&&L(t),o&&o.d(),a&&a.d(),e&&r&&r.end()}}}function Nm(e){let t,n,r=e[1],i=[];for(let a=0;a<r.length;a+=1)i[a]=Lm(Sm(e,r,a));const o=e=>Ve(i[e],1,1,(()=>{i[e]=null}));return{c(){for(let e=0;e<i.length;e+=1)i[e].c();t=$()},l(e){for(let t=0;t<i.length;t+=1)i[t].l(e);t=$()},m(e,r){for(let t=0;t<i.length;t+=1)i[t].m(e,r);N(e,t,r),n=!0},p(e,n){if(25165826&n[0]){let a;for(r=e[1],a=0;a<r.length;a+=1){const o=Sm(e,r,a);i[a]?(i[a].p(o,n),Ue(i[a],1)):(i[a]=Lm(o),i[a].c(),Ue(i[a],1),i[a].m(t.parentNode,t))}for(We(),a=r.length;a<i.length;a+=1)o(a);He()}},i(e){if(!n){for(let e=0;e<r.length;e+=1)Ue(i[e]);n=!0}},o(e){i=i.filter(Boolean);for(let t=0;t<i.length;t+=1)Ve(i[t]);n=!1},d(e){M(i,e),e&&L(t)}}}function Lm(e){let t,n,r=e[43]<12&&function(e){let t,n;return t=new Wg({props:{color:e[41]}}),t.$on("click",(function(){return e[29](e[41])})),t.$on("removeswatch",(function(){return e[30](e[43])})),{c(){st(t.$$.fragment)},l(e){lt(t.$$.fragment,e)},m(e,r){ut(t,e,r),n=!0},p(n,r){e=n;const i={};2&r[0]&&(i.color=e[41]),t.$set(i)},i(e){n||(Ue(t.$$.fragment,e),n=!0)},o(e){Ve(t.$$.fragment,e),n=!1},d(e){ct(t,e)}}}(e);return{c(){r&&r.c(),t=$()},l(e){r&&r.l(e),t=$()},m(e,i){r&&r.m(e,i),N(e,t,i),n=!0},p(e,t){e[43]<12&&r.p(e,t)},i(e){n||(Ue(r),n=!0)},o(e){Ve(r),n=!1},d(e){r&&r.d(e),e&&L(t)}}}function Mm(e){let t,n,r,i,o,a,s;return{c(){t=P("div"),n=P("span"),r=q("+"),this.h()},l(e){t=Y(e,"DIV",{tabindex:!0,title:!0,class:!0});var i=K(t);n=Y(i,"SPAN",{});var o=K(n);r=G(o,"+"),o.forEach(L),i.forEach(L),this.h()},h(){H(t,"tabindex","0"),H(t,"title","Add Swatch"),H(t,"class","adder svelte-dwzpo6"),ie(t,"shrink",e[14])},m(i,l){N(i,t,l),D(t,n),D(n,r),e[31](t),o=!0,a||(s=[C(Ig.call(null,t,{Enter:e[22]})),R(t,"click",e[22])],a=!0)},p(e,n){16384&n[0]&&ie(t,"shrink",e[14])},i(e){o||(Ne((()=>{i||(i=Ze(t,uu,{},!0)),i.run(1)})),o=!0)},o(e){i||(i=Ze(t,uu,{},!1)),i.run(0),o=!1},d(n){n&&L(t),e[31](null),n&&i&&i.end(),a=!1,f(s)}}}function Pm(e){let t,n,r,i,o,a,s,l,u,c,f,p,d,h,g,m,v,y,b,_,w,x,k,E;r=new Zg({props:{h:e[11],s:e[7],v:e[8],a:e[12]}}),r.$on("change",e[16]),l=new Pg({props:{borderRadius:"50%",backgroundSize:"8px",$$slots:{default:[jm]},$$scope:{ctx:e}}}),f=new Vg({props:{type:"hue",value:e[11]}}),f.$on("change",e[27]),d=new Pg({props:{borderRadius:"10px",backgroundSize:"7px",$$slots:{default:[Tm]},$$scope:{ctx:e}}});let O=!e[5]&&Dm(e);return v=new im({props:{format:e[2]}}),v.$on("click",e[19]),b=new sm({props:{value:e[0]}}),b.$on("input",e[32]),b.$on("change",e[21]),{c(){t=P("div"),n=P("div"),st(r.$$.fragment),i=I(),o=P("div"),a=P("div"),s=P("div"),st(l.$$.fragment),u=I(),c=P("div"),st(f.$$.fragment),p=I(),st(d.$$.fragment),h=I(),O&&O.c(),g=I(),m=P("div"),st(v.$$.fragment),y=I(),st(b.$$.fragment),this.h()},l(e){t=Y(e,"DIV",{class:!0,style:!0,tabindex:!0});var _=K(t);n=Y(_,"DIV",{class:!0});var w=K(n);lt(r.$$.fragment,w),w.forEach(L),i=Z(_),o=Y(_,"DIV",{class:!0});var x=K(o);a=Y(x,"DIV",{class:!0});var k=K(a);s=Y(k,"DIV",{});var C=K(s);lt(l.$$.fragment,C),C.forEach(L),u=Z(k),c=Y(k,"DIV",{});var E=K(c);lt(f.$$.fragment,E),p=Z(E),lt(d.$$.fragment,E),E.forEach(L),k.forEach(L),h=Z(x),O&&O.l(x),g=Z(x),m=Y(x,"DIV",{class:!0});var A=K(m);lt(v.$$.fragment,A),y=Z(A),lt(b.$$.fragment,A),A.forEach(L),x.forEach(L),_.forEach(L),this.h()},h(){H(n,"class","palette-panel svelte-dwzpo6"),H(a,"class","alpha-hue-panel svelte-dwzpo6"),H(m,"class","format-input-panel svelte-dwzpo6"),H(o,"class","control-panel svelte-dwzpo6"),H(t,"class","colorpicker-container svelte-dwzpo6"),H(t,"style",e[6]),H(t,"tabindex","0"),Ne((()=>e[34].call(t)))},m(w,A){N(w,t,A),D(t,n),ut(r,n,null),D(t,i),D(t,o),D(o,a),D(a,s),ut(l,s,null),D(a,u),D(a,c),ut(f,c,null),D(c,p),ut(d,c,null),D(o,h),O&&O.m(o,null),D(o,g),D(o,m),ut(v,m,null),D(m,y),ut(b,m,null),e[33](t),_=re(t,e[34].bind(t)),x=!0,k||(E=C(Ig.call(null,t,{Escape:e[15]})),k=!0)},p(e,n){const i={};2048&n[0]&&(i.h=e[11]),128&n[0]&&(i.s=e[7]),256&n[0]&&(i.v=e[8]),4096&n[0]&&(i.a=e[12]),r.$set(i);const a={};8193&n[0]|8192&n[1]&&(a.$$scope={dirty:n,ctx:e}),l.$set(a);const s={};2048&n[0]&&(s.value=e[11]),f.$set(s);const u={};4096&n[0]|8192&n[1]&&(u.$$scope={dirty:n,ctx:e}),d.$set(u),e[5]?O&&(We(),Ve(O,1,1,(()=>{O=null})),He()):O?(O.p(e,n),32&n[0]&&Ue(O,1)):(O=Dm(e),O.c(),Ue(O,1),O.m(o,g));const c={};4&n[0]&&(c.format=e[2]),v.$set(c);const p={};1&n[0]&&(p.value=e[0]),b.$set(p),(!x||64&n[0])&&H(t,"style",e[6])},i(e){x||(Ue(r.$$.fragment,e),Ue(l.$$.fragment,e),Ue(f.$$.fragment,e),Ue(d.$$.fragment,e),Ue(O),Ue(v.$$.fragment,e),Ue(b.$$.fragment,e),Ne((()=>{w||(w=Ze(t,uu,{},!0)),w.run(1)})),x=!0)},o(e){Ve(r.$$.fragment,e),Ve(l.$$.fragment,e),Ve(f.$$.fragment,e),Ve(d.$$.fragment,e),Ve(O),Ve(v.$$.fragment,e),Ve(b.$$.fragment,e),w||(w=Ze(t,uu,{},!1)),w.run(0),x=!1},d(n){n&&L(t),ct(r),ct(l),ct(f),ct(d),O&&O.d(),ct(v),ct(b),e[33](null),_(),n&&w&&w.end(),k=!1,E()}}}function Fm(e){let t,n;return t=new jg({props:{$$slots:{default:[Pm]},$$scope:{ctx:e}}}),{c(){st(t.$$.fragment)},l(e){lt(t.$$.fragment,e)},m(e,r){ut(t,e,r),n=!0},p(e,n){const r={};32767&n[0]|8192&n[1]&&(r.$$scope={dirty:n,ctx:e}),t.$set(r)},i(e){n||(Ue(t.$$.fragment,e),n=!0)},o(e){Ve(t.$$.fragment,e),n=!1},d(e){ct(t,e)}}}function qm(){let e=localStorage.getItem("cp:recent-colors");if(e)return JSON.parse(e)}function Im(e,t,n){let r,i,o,{value:a="#3ec1d3ff"}=t,{open:s=!1}=t,{swatches:l=[]}=t,{disableSwatches:u=!1}=t,{format:c="hexa"}=t,{style:f=""}=t,{pickerHeight:p=0}=t,{pickerWidth:d=0}=t,h=null,g=null,m=!1,v=0,y=0,b=0,_=0;const w=_e();function x(e){const t=m?l:[...qm(),e];localStorage.setItem("cp:recent-colors",JSON.stringify(t))}function k(){!function([e,t,r,i]){n(11,v=e),n(7,y=t),n(8,b=r),n(12,_=i)}(((e,t)=>{switch(t){case"hex":return hm(e);case"rgb":return gm(e);case"hsl":return mm(e)}})(a,c))}function C({color:e,isDrag:t}){n(11,v=e),n(0,a=dm([v,y,b,_],c)),t||O()}function E({color:e,isDrag:t}){n(12,_="1.00"===e?"1":e),n(0,a=dm([v,y,b,_],c)),t||O()}function O(){w("change",a)}function A(e){n(2,c=pm(e)),c&&(n(0,a=e),k())}function S(e){let[t]=l.splice(e,1);n(1,l),w("removeswatch",t),m&&x()}function j(e){a!==e&&(n(2,c=pm(e)),c&&(n(0,a=e),k(),O()))}ve((()=>{!l.length>0&&(m=!0,n(1,l=qm()||[])),l.length>12&&console.warn(`Colorpicker - ${l.length} swatches were provided. Only the first 12 swatches will be displayed.`),h&&h.focus(),c&&k()}));return e.$$set=e=>{"value"in e&&n(0,a=e.value),"open"in e&&n(25,s=e.open),"swatches"in e&&n(1,l=e.swatches),"disableSwatches"in e&&n(5,u=e.disableSwatches),"format"in e&&n(2,c=e.format),"style"in e&&n(6,f=e.style),"pickerHeight"in e&&n(3,p=e.pickerHeight),"pickerWidth"in e&&n(4,d=e.pickerWidth)},e.$$.update=()=>{384&e.$$.dirty[0]&&n(26,r=b>90&&y<5?"1px dashed #dedada":""),67108865&e.$$.dirty[0]&&n(13,i=Tg({background:a,border:r})),2&e.$$.dirty[0]&&n(14,o=l.length>0)},[a,l,c,p,d,u,f,y,b,h,g,v,_,i,o,function(){s&&n(25,s=!1)},function({detail:e}){n(7,y=e.s),n(8,b=e.v),n(0,a=dm([v,y,b,_],c)),O()},C,E,function(e){n(2,c=e.detail),n(0,a=dm([v,y,b,_],c))},A,function(){c&&O()},function(){c&&(12===l.length&&l.splice(0,1),l.includes(a)||(n(1,l=[...l,a]),x(a)),w("addswatch",a))},S,j,s,r,e=>C(e.detail),(e,t)=>E(e.detail),e=>j(e),e=>S(e),function(e){Ee[e?"unshift":"push"]((()=>{g=e,n(10,g)}))},e=>A(e.target.value),function(e){Ee[e?"unshift":"push"]((()=>{h=e,n(9,h)}))},function(){p=this.clientHeight,d=this.clientWidth,n(3,p),n(4,d)}]}class $m extends pt{constructor(e){super(),ft(this,e,Im,Fm,d,{value:0,open:25,swatches:1,disableSwatches:5,format:2,style:6,pickerHeight:3,pickerWidth:4},[-1,-1])}}const{window:Rm}=Je;function zm(e){let t,n,r;return{c(){t=P("div"),n=P("span"),r=q("×"),this.h()},l(e){t=Y(e,"DIV",{class:!0,title:!0,style:!0});var i=K(t);n=Y(i,"SPAN",{});var o=K(n);r=G(o,"×"),o.forEach(L),i.forEach(L),this.h()},h(){H(t,"class","color-preview preview-error svelte-1y4si7g"),H(t,"title","Invalid Color"),H(t,"style",e[12])},m(e,i){N(e,t,i),D(t,n),D(n,r)},p(e,n){4096&n[0]&&H(t,"style",e[12])},i:a,o:a,d(e){e&&L(t)}}}function Bm(e){let t,n,r,i;t=new Pg({props:{borderRadius:"3px",backgroundSize:"8px",$$slots:{default:[Wm]},$$scope:{ctx:e}}});let o=e[1]&&Hm(e);return{c(){st(t.$$.fragment),n=I(),o&&o.c(),r=$()},l(e){lt(t.$$.fragment,e),n=Z(e),o&&o.l(e),r=$()},m(e,a){ut(t,e,a),N(e,n,a),o&&o.m(e,a),N(e,r,a),i=!0},p(e,n){const i={};2257&n[0]|8&n[1]&&(i.$$scope={dirty:n,ctx:e}),t.$set(i),e[1]?o?(o.p(e,n),2&n[0]&&Ue(o,1)):(o=Hm(e),o.c(),Ue(o,1),o.m(r.parentNode,r)):o&&(We(),Ve(o,1,1,(()=>{o=null})),He())},i(e){i||(Ue(t.$$.fragment,e),Ue(o),i=!0)},o(e){Ve(t.$$.fragment,e),Ve(o),i=!1},d(e){ct(t,e),e&&L(n),o&&o.d(e),e&&L(r)}}}function Wm(e){let t,n,r,i;return{c(){t=P("div"),this.h()},l(e){t=Y(e,"DIV",{title:!0,class:!0,style:!0}),K(t).forEach(L),this.h()},h(){H(t,"title",e[0]),H(t,"class","color-preview svelte-1y4si7g"),H(t,"style",e[11]),Ne((()=>e[23].call(t)))},m(o,a){N(o,t,a),e[22](t),n=re(t,e[23].bind(t)),r||(i=R(t,"click",e[14]),r=!0)},p(e,n){1&n[0]&&H(t,"title",e[0]),2048&n[0]&&H(t,"style",e[11])},d(o){o&&L(t),e[22](null),n(),r=!1,i()}}}function Hm(e){let t,n,r,i,o,a,s,l,u,c,f;function p(t){e[24](t)}function d(t){e[25](t)}function h(t){e[26](t)}function g(t){e[27](t)}function m(t){e[28](t)}let v={style:e[13],swatches:e[2],disableSwatches:e[3]};return void 0!==e[5]&&(v.format=e[5]),void 0!==e[0]&&(v.value=e[0]),void 0!==e[9]&&(v.pickerHeight=e[9]),void 0!==e[8]&&(v.pickerWidth=e[8]),void 0!==e[1]&&(v.open=e[1]),t=new $m({props:v}),Ee.push((()=>at(t,"format",p))),Ee.push((()=>at(t,"value",d))),Ee.push((()=>at(t,"pickerHeight",h))),Ee.push((()=>at(t,"pickerWidth",g))),Ee.push((()=>at(t,"open",m))),t.$on("change",e[15]),t.$on("addswatch",e[29]),t.$on("removeswatch",e[30]),{c(){st(t.$$.fragment),s=I(),l=P("div"),this.h()},l(e){lt(t.$$.fragment,e),s=Z(e),l=Y(e,"DIV",{class:!0}),K(l).forEach(L),this.h()},h(){H(l,"class","overlay svelte-1y4si7g")},m(n,r){ut(t,n,r),N(n,s,r),N(n,l,r),u=!0,c||(f=R(l,"click",W(e[31])),c=!0)},p(e,s){const l={};8192&s[0]&&(l.style=e[13]),4&s[0]&&(l.swatches=e[2]),8&s[0]&&(l.disableSwatches=e[3]),!n&&32&s[0]&&(n=!0,l.format=e[5],Le((()=>n=!1))),!r&&1&s[0]&&(r=!0,l.value=e[0],Le((()=>r=!1))),!i&&512&s[0]&&(i=!0,l.pickerHeight=e[9],Le((()=>i=!1))),!o&&256&s[0]&&(o=!0,l.pickerWidth=e[8],Le((()=>o=!1))),!a&&2&s[0]&&(a=!0,l.open=e[1],Le((()=>a=!1))),t.$set(l)},i(e){u||(Ue(t.$$.fragment,e),u=!0)},o(e){Ve(t.$$.fragment,e),u=!1},d(e){ct(t,e),e&&L(s),e&&L(l),c=!1,f()}}}function Um(e){let t,n,r,i,o,a;const s=[Bm,zm],l=[];function u(e,t){return e[10]?1:0}return n=u(e),r=l[n]=s[n](e),{c(){t=P("div"),r.c(),this.h()},l(e){t=Y(e,"DIV",{class:!0});var n=K(t);r.l(n),n.forEach(L),this.h()},h(){H(t,"class","color-preview-container svelte-1y4si7g")},m(r,s){N(r,t,s),l[n].m(t,null),i=!0,o||(a=R(Rm,"resize",Ng(e[16],200)),o=!0)},p(e,i){let o=n;n=u(e),n===o?l[n].p(e,i):(We(),Ve(l[o],1,1,(()=>{l[o]=null})),He(),r=l[n],r?r.p(e,i):(r=l[n]=s[n](e),r.c()),Ue(r,1),r.m(t,null))},i(e){i||(Ue(r),i=!0)},o(e){Ve(r),i=!1},d(e){e&&L(t),l[n].d(),o=!1,a()}}}function Vm(e,t,n){let r,i,o,{value:a="#3ec1d3ff"}=t,{swatches:s=[]}=t,{disableSwatches:l=!1}=t,{open:u=!1}=t,{width:c="25px"}=t,{height:f="25px"}=t,p="hexa",d={top:0,bottom:0,right:0,left:0},h="top",g="left",m=null,v=null,y=null,b=0,_=0,w=null;const x=_e();var k;function C(){if(u){const{top:e,width:t,bottom:r,right:i,left:o}=m.getBoundingClientRect(),a=window.innerHeight-r,s=y/2;let l,u;e>a?(n(20,h="bottom"),l=window.innerHeight-e):(n(20,h="top"),l=r),u=o+s-110;const c=window.innerWidth-i;o<110&&c>220?(n(21,g="left"),u=i):c<100&&o>220&&(n(21,g="right"),u=document.body.clientWidth-o),n(19,d={[h]:l.toFixed(1),[g]:u.toFixed(1)})}}k=()=>{n(5,p=pm(a)),p?n(10,w=null):(n(10,w=`Colorpicker - ${a} is an unknown color format. Please use a hex, rgb or hsl value`),console.error(w))},me().$$.before_update.push(k);return e.$$set=e=>{"value"in e&&n(0,a=e.value),"swatches"in e&&n(2,s=e.swatches),"disableSwatches"in e&&n(3,l=e.disableSwatches),"open"in e&&n(1,u=e.open),"width"in e&&n(17,c=e.width),"height"in e&&n(18,f=e.height)},e.$$.update=()=>{18&e.$$.dirty[0]&&u&&m&&C(),393217&e.$$.dirty[0]&&n(11,r=Tg({width:c,height:f,background:a})),393216&e.$$.dirty[0]&&n(12,i=Tg({width:c,height:f})),3670016&e.$$.dirty[0]&&n(13,o=Tg({[h]:`${d[h]}px`,[g]:`${d[g]}px`}))},[a,u,s,l,m,p,v,y,b,_,w,r,i,o,function(e){m&&n(1,u=!0)},function(e){var t;n(0,a=e.detail),t=a,Ng((()=>x("change",t)),300,!0)},C,c,f,d,h,g,function(e){Ee[e?"unshift":"push"]((()=>{m=e,n(4,m)}))},function(){v=this.clientHeight,y=this.clientWidth,n(6,v),n(7,y)},function(e){p=e,n(5,p)},function(e){a=e,n(0,a)},function(e){_=e,n(9,_)},function(e){b=e,n(8,b)},function(e){u=e,n(1,u)},function(t){ke(e,t)},function(t){ke(e,t)},()=>n(1,u=!1)]}class Km extends pt{constructor(e){super(),ft(this,e,Vm,Um,d,{value:0,swatches:2,disableSwatches:3,open:1,width:17,height:18},[-1,-1])}}function Ym(e,t,n={}){const r=getComputedStyle(e),i="none"===r.transform?"":r.transform,o=t.from.width/e.clientWidth,a=t.from.height/e.clientHeight,s=(t.from.left-t.to.left)/o,l=(t.from.top-t.to.top)/a,u=Math.sqrt(s*s+l*l),{delay:c=0,duration:f=(e=>120*Math.sqrt(e)),easing:d=lu}=n;return{delay:c,duration:p(f)?f(u):f,easing:d,css:(e,t)=>`transform: ${i} translate(${t*s}px, ${t*l}px);`}}function Gm(e,t,n){e.dispatchEvent(new CustomEvent("finalize",{detail:{items:t,info:n}}))}function Zm(e,t,n){e.dispatchEvent(new CustomEvent("consider",{detail:{items:t,info:n}}))}const Xm="leftForAnother",Jm="outsideOfAny";function Qm(e,t,n){e.dispatchEvent(new CustomEvent("draggedEntered",{detail:{indexObj:t,draggedEl:n}}))}function ev(e,t,n){e.dispatchEvent(new CustomEvent("draggedLeft",{detail:{draggedEl:t,type:Xm,theOtherDz:n}}))}function tv(e,t,n){e.dispatchEvent(new CustomEvent("draggedOverIndex",{detail:{indexObj:t,draggedEl:n}}))}const nv="dragStarted",rv="draggedEntered",iv="dragEnteredAnother",ov="draggedOverIndex",av="draggedLeft",sv="draggedLeftAll",lv="droppedIntoZone",uv="droppedIntoAnother",cv="droppedOutsideOfAny",fv="dragStopped",pv="pointer",dv="keyboard";let hv=0;function gv(){hv++}function mv(){if(0===hv)throw new Error("Bug! trying to decrement when there are no dropzones");hv--}const vv="undefined"==typeof window;function yv(e){let t;const n=e.getBoundingClientRect(),r=getComputedStyle(e),i=r.transform;if(i){let o,a,s,l;if(i.startsWith("matrix3d("))t=i.slice(9,-1).split(/, /),o=+t[0],a=+t[5],s=+t[12],l=+t[13];else{if(!i.startsWith("matrix("))return n;t=i.slice(7,-1).split(/, /),o=+t[0],a=+t[3],s=+t[4],l=+t[5]}const u=r.transformOrigin,c=n.x-s-(1-o)*parseFloat(u),f=n.y-l-(1-a)*parseFloat(u.slice(u.indexOf(" ")+1)),p=o?n.width/o:e.offsetWidth,d=a?n.height/a:e.offsetHeight;return{x:c,y:f,width:p,height:d,top:f,right:c+p,bottom:f+d,left:c}}return n}function bv(e){const t=yv(e);return{top:t.top+window.scrollY,bottom:t.bottom+window.scrollY,left:t.left+window.scrollX,right:t.right+window.scrollX}}function _v(e){const t=e.getBoundingClientRect();return{top:t.top+window.scrollY,bottom:t.bottom+window.scrollY,left:t.left+window.scrollX,right:t.right+window.scrollX}}function wv(e,t){return e.y<=t.bottom&&e.y>=t.top&&e.x>=t.left&&e.x<=t.right}function xv(e){return{x:((t=_v(e)).left+t.right)/2,y:(t.top+t.bottom)/2};var t}function kv(e,t){return wv(xv(e),bv(t))}function Cv(e,t){const n=xv(e),r=xv(t);return i=n,o=r,Math.sqrt(Math.pow(i.x-o.x,2)+Math.pow(i.y-o.y,2));var i,o}let Ev;function Ov(){Ev=new Map}function Av(e,t){if(!kv(e,t))return null;const n=t.children;if(0===n.length)return{index:0,isProximityBased:!0};const r=function(e){const t=Array.from(e.children).findIndex((e=>e.getAttribute("data-is-dnd-shadow-item")));if(t>=0)return Ev.has(e)||Ev.set(e,new Map),Ev.get(e).set(t,bv(e.children[t])),t}(t);for(let a=0;a<n.length;a++)if(kv(e,n[a])){const n=Ev.has(t)&&Ev.get(t).get(a);return n&&!wv(xv(e),n)?{index:r,isProximityBased:!1}:{index:a,isProximityBased:!1}}let i,o=Number.MAX_VALUE;for(let a=0;a<n.length;a++){const t=Cv(e,n[a]);t<o&&(o=t,i=a)}return{index:i,isProximityBased:!0}}Ov();function Sv(){let e;function t(){e={directionObj:void 0,stepPx:0}}function n(t){const{directionObj:r,stepPx:i}=e;r&&(t.scrollBy(r.x*i,r.y*i),window.requestAnimationFrame((()=>n(t))))}function r(e){return 25-e}return t(),{scrollIfNeeded:function(i,o){if(!o)return!1;const a=function(e,t){const n=_v(t);return wv(e,n)?{top:e.y-n.top,bottom:n.bottom-e.y,left:e.x-n.left,right:Math.min(n.right,document.documentElement.clientWidth)-e.x}:null}(i,o);if(null===a)return t(),!1;const s=!!e.directionObj;let[l,u]=[!1,!1];return o.scrollHeight>o.clientHeight&&(a.bottom<25?(l=!0,e.directionObj={x:0,y:1},e.stepPx=r(a.bottom)):a.top<25&&(l=!0,e.directionObj={x:0,y:-1},e.stepPx=r(a.top)),!s&&l)||o.scrollWidth>o.clientWidth&&(a.right<25?(u=!0,e.directionObj={x:1,y:0},e.stepPx=r(a.right)):a.left<25&&(u=!0,e.directionObj={x:-1,y:0},e.stepPx=r(a.left)),!s&&u)?(n(o),!0):(t(),!1)},resetScrolling:t}}function jv(e){return JSON.stringify(e,null,2)}function Tv(e){if(!e)throw new Error("cannot get depth of a falsy node");return Dv(e,0)}function Dv(e,t=0){return e.parentElement?Dv(e.parentElement,t+1):t-1}const{scrollIfNeeded:Nv,resetScrolling:Lv}=Sv();let Mv;function Pv(e,t,n=200){let r,i,o,a=!1;const s=Array.from(t).sort(((e,t)=>Tv(t)-Tv(e)));!function t(){const l=xv(e);if(!Nv(l,r)&&o&&Math.abs(o.x-l.x)<10&&Math.abs(o.y-l.y)<10)return void(Mv=window.setTimeout(t,n));if(function(e){const t=_v(e);return t.right<0||t.left>document.documentElement.scrollWidth||t.bottom<0||t.top>document.documentElement.scrollHeight}(e))return void function(e){window.dispatchEvent(new CustomEvent("draggedLeftDocument",{detail:{draggedEl:e}}))}(e);o=l;let u=!1;for(const n of s){const t=Av(e,n);if(null===t)continue;const{index:o}=t;u=!0,n!==r?(r&&ev(r,e,n),Qm(n,t,e),r=n):o!==i&&(tv(n,t,e),i=o);break}!u&&a&&r?(!function(e,t){e.dispatchEvent(new CustomEvent("draggedLeft",{detail:{draggedEl:t,type:Jm}}))}(r,e),r=void 0,i=void 0,a=!1):a=!0,Mv=window.setTimeout(t,n)}()}let Fv;function qv(e){const t=e.touches?e.touches[0]:e;Fv={x:t.clientX,y:t.clientY}}const{scrollIfNeeded:Iv,resetScrolling:$v}=Sv();let Rv;function zv(){Fv&&Iv(Fv,document.documentElement),Rv=window.setTimeout(zv,300)}function Bv(e){return`${e} 0.2s ease`}function Wv(e,t,n,r,i){const o=t.getBoundingClientRect(),a=e.getBoundingClientRect(),s=o.width-a.width,l=o.height-a.height;if(s||l){const t={left:(n-a.left)/a.width,top:(r-a.top)/a.height};e.style.height=`${o.height}px`,e.style.width=`${o.width}px`,e.style.left=parseFloat(e.style.left)-t.left*s+"px",e.style.top=parseFloat(e.style.top)-t.top*l+"px"}Hv(t,e),i()}function Hv(e,t){const n=window.getComputedStyle(e);Array.from(n).filter((e=>e.startsWith("background")||e.startsWith("padding")||e.startsWith("font")||e.startsWith("text")||e.startsWith("align")||e.startsWith("justify")||e.startsWith("display")||e.startsWith("flex")||e.startsWith("border")||"opacity"===e||"color"===e||"list-style-type"===e)).forEach((e=>t.style.setProperty(e,n.getPropertyValue(e),n.getPropertyPriority(e))))}function Uv(e,t){e.draggable=!1,e.ondragstart=()=>!1,t?(e.style.userSelect="",e.style.WebkitUserSelect="",e.style.cursor=""):(e.style.userSelect="none",e.style.WebkitUserSelect="none",e.style.cursor="grab")}function Vv(e,t=(()=>{}),n=(()=>[])){e.forEach((e=>{const r=t(e);Object.keys(r).forEach((t=>{e.style[t]=r[t]})),n(e).forEach((t=>e.classList.add(t)))}))}function Kv(e,t=(()=>{}),n=(()=>[])){e.forEach((e=>{const r=t(e);Object.keys(r).forEach((t=>{e.style[t]=""})),n(e).forEach((t=>e.classList.contains(t)&&e.classList.remove(t)))}))}const Yv={outline:"rgba(255, 255, 102, 0.7) solid 2px"};let Gv,Zv,Xv,Jv,Qv,ey,ty,ny,ry,iy,oy,ay=!1,sy=!1,ly=!1;const uy=new Map,cy=new Map,fy=new WeakMap;function py(e,t){uy.get(t).delete(e),mv(),0===uy.get(t).size&&uy.delete(t)}function dy(){window.addEventListener("mousemove",qv),window.addEventListener("touchmove",qv),zv();const e=uy.get(Jv);for(const n of e)n.addEventListener("draggedEntered",my),n.addEventListener("draggedLeft",vy),n.addEventListener("draggedOverIndex",yy);window.addEventListener("draggedLeftDocument",_y);const t=Math.max(100,...Array.from(e.keys()).map((e=>cy.get(e).dropAnimationDurationMs)));Pv(Zv,e,1.07*t)}function hy(){window.removeEventListener("mousemove",qv),window.removeEventListener("touchmove",qv),Fv=void 0,window.clearTimeout(Rv),$v();const e=uy.get(Jv);for(const t of e)t.removeEventListener("draggedEntered",my),t.removeEventListener("draggedLeft",vy),t.removeEventListener("draggedOverIndex",yy);window.removeEventListener("draggedLeftDocument",_y),clearTimeout(Mv),Lv(),Ov()}function gy(e){return e.findIndex((e=>!!e.isDndShadowItem&&"id:dnd-shadow-placeholder-0000"!==e.id))}function my(e){let{items:t,dropFromOthersDisabled:n}=cy.get(e.currentTarget);if(n&&e.currentTarget!==Qv)return;if(ly=!1,t=t.filter((e=>e.id!==ty.id)),Qv!==e.currentTarget){const e=cy.get(Qv).items.filter((e=>!e.isDndShadowItem));Zm(Qv,e,{trigger:iv,id:Xv.id,source:pv})}else{const e=function(e){return e.findIndex((e=>"id:dnd-shadow-placeholder-0000"===e.id))}(t);-1!==e&&t.splice(e,1)}const{index:r,isProximityBased:i}=e.detail.indexObj,o=i&&r===e.currentTarget.children.length-1?r+1:r;ny=e.currentTarget,t.splice(o,0,ty),Zm(e.currentTarget,t,{trigger:rv,id:Xv.id,source:pv})}function vy(e){const{items:t,dropFromOthersDisabled:n}=cy.get(e.currentTarget);if(n&&e.currentTarget!==Qv)return;const r=gy(t),i=t.splice(r,1)[0];ny=void 0;const{type:o,theOtherDz:a}=e.detail;if(o===Jm||o===Xm&&a!==Qv&&cy.get(a).dropFromOthersDisabled){ly=!0,ny=Qv;const e=cy.get(Qv).items;e.splice(ey,0,i),Zm(Qv,e,{trigger:sv,id:Xv.id,source:pv})}Zm(e.currentTarget,t,{trigger:av,id:Xv.id,source:pv})}function yy(e){const{items:t,dropFromOthersDisabled:n}=cy.get(e.currentTarget);if(n&&e.currentTarget!==Qv)return;ly=!1;const{index:r}=e.detail.indexObj,i=gy(t);t.splice(i,1),t.splice(r,0,ty),Zm(e.currentTarget,t,{trigger:ov,id:Xv.id,source:pv})}function by(e){e.preventDefault();const t=e.touches?e.touches[0]:e;iy={x:t.clientX,y:t.clientY},Zv.style.transform=`translate3d(${iy.x-ry.x}px, ${iy.y-ry.y}px, 0)`}function _y(){sy=!0,window.removeEventListener("mousemove",by),window.removeEventListener("touchmove",by),window.removeEventListener("mouseup",_y),window.removeEventListener("touchend",_y),hy(),Zv.style.cursor="grab",ny||(ny=Qv);let{items:e,type:t}=cy.get(ny);Kv(uy.get(t),(e=>cy.get(e).dropTargetStyle),(e=>cy.get(e).dropTargetClasses));let n=gy(e);-1===n&&(n=ey),e=e.map((e=>e.isDndShadowItem?Xv:e)),function(e,t){const n=yv(ny.children[e]),r={x:n.left-parseFloat(Zv.style.left),y:n.top-parseFloat(Zv.style.top)},{dropAnimationDurationMs:i}=cy.get(ny),o=`transform ${i}ms ease`;Zv.style.transition=Zv.style.transition?Zv.style.transition+","+o:o,Zv.style.transform=`translate3d(${r.x}px, ${r.y}px, 0)`,window.setTimeout(t,i)}(n,(function(){var t;oy(),Gm(ny,e,{trigger:ly?cv:lv,id:Xv.id,source:pv}),ny!==Qv&&Gm(Qv,cy.get(Qv).items,{trigger:uv,id:Xv.id,source:pv}),(t=ny.children[n]).style.visibility="",t.removeAttribute("data-is-dnd-shadow-item"),Zv.remove(),Gv.remove(),Zv=void 0,Gv=void 0,Xv=void 0,Jv=void 0,Qv=void 0,ey=void 0,ty=void 0,ny=void 0,ry=void 0,iy=void 0,ay=!1,sy=!1,oy=void 0,ly=!1}))}function wy(e,t){const n={items:void 0,type:void 0,flipDurationMs:0,dragDisabled:!1,dropFromOthersDisabled:!1,dropTargetStyle:Yv,dropTargetClasses:[],transformDraggedElement:()=>{}};let r=new Map;function i(){window.removeEventListener("mousemove",s),window.removeEventListener("touchmove",s),window.removeEventListener("mouseup",a),window.removeEventListener("touchend",a)}function a(){i(),Gv=void 0,ry=void 0,iy=void 0}function s(e){e.preventDefault();const t=e.touches?e.touches[0]:e;iy={x:t.clientX,y:t.clientY},(Math.abs(iy.x-ry.x)>=3||Math.abs(iy.y-ry.y)>=3)&&(i(),function(){ay=!0;const e=r.get(Gv);ey=e,Qv=Gv.parentElement;const{items:t,type:i}=n;Xv=o({},t[e]),Jv=i,ty=o(o({},Xv),{isDndShadowItem:!0});const a=o(o({},ty),{id:"id:dnd-shadow-placeholder-0000"});function s(){var e;Zv.parentElement?window.requestAnimationFrame(s):(document.body.appendChild(Zv),Zv.focus(),dy(),(e=Gv).style.display="none",e.style.position="fixed",e.style.zIndex="-5",document.body.appendChild(Gv))}Zv=function(e){const t=e.getBoundingClientRect(),n=e.cloneNode(!0);return Hv(e,n),n.id="dnd-action-dragged-el",n.style.position="fixed",n.style.top=`${t.top}px`,n.style.left=`${t.left}px`,n.style.margin="0",n.style.boxSizing="border-box",n.style.height=`${t.height}px`,n.style.width=`${t.width}px`,n.style.transition=`${Bv("width")}, ${Bv("height")}, ${Bv("background-color")}, ${Bv("opacity")}, ${Bv("color")} `,window.setTimeout((()=>n.style.transition+=`, ${Bv("top")}, ${Bv("left")}`),0),n.style.zIndex="9999",n.style.cursor="grabbing",n}(Gv),window.requestAnimationFrame(s),Vv(Array.from(uy.get(n.type)).filter((e=>e===Qv||!cy.get(e).dropFromOthersDisabled)),(e=>cy.get(e).dropTargetStyle),(e=>cy.get(e).dropTargetClasses)),t.splice(e,1,a),oy=function(e){const t=e.style.minHeight;e.style.minHeight=window.getComputedStyle(e).getPropertyValue("height");const n=e.style.minWidth;return e.style.minWidth=window.getComputedStyle(e).getPropertyValue("width"),function(){e.style.minHeight=t,e.style.minWidth=n}}(Qv),Zm(Qv,t,{trigger:nv,id:Xv.id,source:pv}),window.addEventListener("mousemove",by,{passive:!1}),window.addEventListener("touchmove",by,{passive:!1,capture:!1}),window.addEventListener("mouseup",_y,{passive:!1}),window.addEventListener("touchend",_y,{passive:!1})}())}function l(e){if(e.target!==e.currentTarget&&(void 0!==e.target.value||e.target.isContentEditable))return;if(e.button)return;if(ay)return;e.stopPropagation();const t=e.touches?e.touches[0]:e;ry={x:t.clientX,y:t.clientY},iy=o({},ry),Gv=e.currentTarget,window.addEventListener("mousemove",s,{passive:!1}),window.addEventListener("touchmove",s,{passive:!1,capture:!1}),window.addEventListener("mouseup",a,{passive:!1}),window.addEventListener("touchend",a,{passive:!1})}function u({items:t,flipDurationMs:i=0,type:o="--any--",dragDisabled:a=!1,dropFromOthersDisabled:s=!1,dropTargetStyle:u=Yv,dropTargetClasses:c=[],transformDraggedElement:f=(()=>{})}){var p,d;n.dropAnimationDurationMs=i,n.type&&o!==n.type&&py(e,n.type),n.type=o,p=e,d=o,uy.has(d)||uy.set(d,new Set),uy.get(d).has(p)||(uy.get(d).add(p),gv()),n.items=[...t],n.dragDisabled=a,n.transformDraggedElement=f,!ay||sy||function(e,t){if(Object.keys(e).length!==Object.keys(t).length)return!1;for(const n in e)if(!{}.hasOwnProperty.call(t,n)||t[n]!==e[n])return!1;return!0}(u,n.dropTargetStyle)&&function(e,t){if(e.length!==t.length)return!1;for(let n=0;n<e.length;n++)if(e[n]!==t[n])return!1;return!0}(c,n.dropTargetClasses)||(Kv([e],(()=>n.dropTargetStyle),(()=>c)),Vv([e],(()=>u),(()=>c))),n.dropTargetStyle=u,n.dropTargetClasses=[...c],ay&&n.dropFromOthersDisabled!==s&&(s?Kv([e],(e=>cy.get(e).dropTargetStyle),(e=>cy.get(e).dropTargetClasses)):Vv([e],(e=>cy.get(e).dropTargetStyle),(e=>cy.get(e).dropTargetClasses))),n.dropFromOthersDisabled=s,cy.set(e,n);const h=gy(n.items);for(let m=0;m<e.children.length;m++){const t=e.children[m];Uv(t,a),m!==h?(t.removeEventListener("mousedown",fy.get(t)),t.removeEventListener("touchstart",fy.get(t)),a||(t.addEventListener("mousedown",l),t.addEventListener("touchstart",l),fy.set(t,l)),r.set(t,m)):(Wv(Zv,t,iy.x,iy.y,(()=>n.transformDraggedElement(Zv,Xv,m))),(g=t).style.visibility="hidden",g.setAttribute("data-is-dnd-shadow-item","true"))}var g}return u(t),{update:e=>{u(e)},destroy:()=>{py(e,n.type),cy.delete(e)}}}const xy={DND_ZONE_ACTIVE:"dnd-zone-active",DND_ZONE_DRAG_DISABLED:"dnd-zone-drag-disabled"},ky={[xy.DND_ZONE_ACTIVE]:"Tab to one the items and press space-bar or enter to start dragging it",[xy.DND_ZONE_DRAG_DISABLED]:"This is a disabled drag and drop list"};let Cy;function Ey(){Cy=document.createElement("div"),Cy.id="dnd-action-aria-alert",Cy.style.position="fixed",Cy.style.bottom="0",Cy.style.left="0",Cy.style.zIndex="-5",Cy.style.opacity="0",Cy.style.height="0",Cy.style.width="0",Cy.setAttribute("role","alert"),document.body.prepend(Cy),Object.entries(ky).forEach((([e,t])=>document.body.prepend(function(e,t){const n=document.createElement("div");return n.id=e,n.innerHTML=`<p>${t}</p>`,n.style.display="none",n.style.position="fixed",n.style.zIndex="-5",n}(e,t))))}function Oy(e){Cy.innerHTML="";const t=document.createTextNode(e);Cy.appendChild(t),Cy.style.display="none",Cy.style.display="inline"}const Ay={outline:"rgba(255, 255, 102, 0.7) solid 2px"};let Sy,jy,Ty,Dy,Ny=!1,Ly="",My="";const Py=new WeakSet,Fy=new WeakMap,qy=new WeakMap,Iy=new Map,$y=new Map,Ry=new Map,zy=vv?null:("complete"===document.readyState?Ey():window.addEventListener("DOMContentLoaded",Ey),o({},xy));function By(e,t){jy===e&&Ky(),Ry.get(t).delete(e),mv(),0===Ry.get(t).size&&Ry.delete(t),0===Ry.size&&(window.removeEventListener("keydown",Wy),window.removeEventListener("click",Hy))}function Wy(e){if(Ny)switch(e.key){case"Escape":Ky()}}function Hy(){Ny&&(Py.has(document.activeElement)||Ky())}function Uy(e){if(!Ny)return;const t=e.currentTarget;if(t===jy)return;Ly=t.getAttribute("aria-label")||"";const{items:n}=$y.get(jy),r=n.find((e=>e.id===Dy)),i=n.indexOf(r),o=n.splice(i,1)[0],{items:a,autoAriaDisabled:s}=$y.get(t);t.getBoundingClientRect().top<jy.getBoundingClientRect().top||t.getBoundingClientRect().left<jy.getBoundingClientRect().left?(a.push(o),s||Oy(`Moved item ${My} to the end of the list ${Ly}`)):(a.unshift(o),s||Oy(`Moved item ${My} to the beginning of the list ${Ly}`));Gm(jy,n,{trigger:uv,id:Dy,source:dv}),Gm(t,a,{trigger:lv,id:Dy,source:dv}),jy=t}function Vy(){Iy.forEach((({update:e},t)=>e($y.get(t))))}function Ky(e=!0){$y.get(jy).autoAriaDisabled||Oy(`Stopped dragging item ${My}`),Py.has(document.activeElement)&&document.activeElement.blur(),e&&Zm(jy,$y.get(jy).items,{trigger:fv,id:Dy,source:dv}),Kv(Ry.get(Sy),(e=>$y.get(e).dropTargetStyle),(e=>$y.get(e).dropTargetClasses)),Ty=null,Dy=null,My="",Sy=null,jy=null,Ly="",Ny=!1,Vy()}function Yy(e,t){const n={items:void 0,type:void 0,dragDisabled:!1,dropFromOthersDisabled:!1,dropTargetStyle:Ay,dropTargetClasses:[],autoAriaDisabled:!1};function r(e,t,n){e.length<=1||e.splice(n,1,e.splice(t,1,e[n])[0])}function i(t){switch(t.key){case"Enter":case" ":if((void 0!==t.target.disabled||t.target.href||t.target.isContentEditable)&&!Py.has(t.target))return;t.preventDefault(),t.stopPropagation(),Ny?Ky():o(t);break;case"ArrowDown":case"ArrowRight":{if(!Ny)return;t.preventDefault(),t.stopPropagation();const{items:i}=$y.get(e),o=Array.from(e.children),a=o.indexOf(t.currentTarget);a<o.length-1&&(n.autoAriaDisabled||Oy(`Moved item ${My} to position ${a+2} in the list ${Ly}`),r(i,a,a+1),Gm(e,i,{trigger:lv,id:Dy,source:dv}));break}case"ArrowUp":case"ArrowLeft":{if(!Ny)return;t.preventDefault(),t.stopPropagation();const{items:i}=$y.get(e),o=Array.from(e.children).indexOf(t.currentTarget);o>0&&(n.autoAriaDisabled||Oy(`Moved item ${My} to position ${o} in the list ${Ly}`),r(i,o,o-1),Gm(e,i,{trigger:lv,id:Dy,source:dv}));break}}}function o(t){!function(t){const{items:n}=$y.get(e),r=Array.from(e.children),i=r.indexOf(t);Ty=t,Ty.tabIndex=0,Dy=n[i].id,My=r[i].getAttribute("aria-label")||""}(t.currentTarget),jy=e,Sy=n.type,Ny=!0;const r=Array.from(Ry.get(n.type)).filter((e=>e===jy||!$y.get(e).dropFromOthersDisabled));if(Vv(r,(e=>$y.get(e).dropTargetStyle),(e=>$y.get(e).dropTargetClasses)),!n.autoAriaDisabled){let e=`Started dragging item ${My}. Use the arrow keys to move it within its list ${Ly}`;r.length>1&&(e+=", or tab to another list in order to move the item into it"),Oy(e)}Zm(e,$y.get(e).items,{trigger:nv,id:Dy,source:dv}),Vy()}function a(e){Ny&&e.currentTarget!==Ty&&(e.stopPropagation(),Ky(!1),o(e))}function s({items:t=[],type:r="--any--",dragDisabled:o=!1,dropFromOthersDisabled:s=!1,dropTargetStyle:l=Ay,dropTargetClasses:u=[],autoAriaDisabled:c=!1}){var f,p;n.items=[...t],n.dragDisabled=o,n.dropFromOthersDisabled=s,n.dropTargetStyle=l,n.dropTargetClasses=u,n.autoAriaDisabled=c,c||(e.setAttribute("aria-disabled",o),e.setAttribute("role","list"),e.setAttribute("aria-describedby",o?zy.DND_ZONE_DRAG_DISABLED:zy.DND_ZONE_ACTIVE)),n.type&&r!==n.type&&By(e,n.type),n.type=r,f=e,p=r,0===Ry.size&&(window.addEventListener("keydown",Wy),window.addEventListener("click",Hy)),Ry.has(p)||Ry.set(p,new Set),Ry.get(p).has(f)||(Ry.get(p).add(f),gv()),$y.set(e,n),e.tabIndex=Ny&&(e===jy||Ty.contains(e)||n.dropFromOthersDisabled||jy&&n.type!==$y.get(jy).type)?-1:0,e.addEventListener("focus",Uy);for(let d=0;d<e.children.length;d++){const t=e.children[d];Py.add(t),t.tabIndex=Ny?-1:0,c||t.setAttribute("role","listitem"),t.removeEventListener("keydown",Fy.get(t)),t.removeEventListener("click",qy.get(t)),o||(t.addEventListener("keydown",i),Fy.set(t,i),t.addEventListener("click",a),qy.set(t,a)),Ny&&n.items[d].id===Dy&&(Ty=t,Ty.tabIndex=0,t.focus())}}s(t);const l={update:e=>{s(e)},destroy:()=>{By(e,n.type),$y.delete(e),Iy.delete(e)}};return Iy.set(e,l),l}function Gy(e,t){Zy(t);const n=wy(e,t),r=Yy(e,t);return{update:e=>{Zy(e),n.update(e),r.update(e)},destroy:()=>{n.destroy(),r.destroy()}}}function Zy(e){const{items:i,flipDurationMs:o,type:a,dragDisabled:s,dropFromOthersDisabled:l,dropTargetStyle:u,dropTargetClasses:c,transformDraggedElement:f,autoAriaDisabled:p}=e,d=((e,i)=>{var o={};for(var a in e)t.call(e,a)&&i.indexOf(a)<0&&(o[a]=e[a]);if(null!=e&&n)for(var a of n(e))i.indexOf(a)<0&&r.call(e,a)&&(o[a]=e[a]);return o})(e,["items","flipDurationMs","type","dragDisabled","dropFromOthersDisabled","dropTargetStyle","dropTargetClasses","transformDraggedElement","autoAriaDisabled"]);if(Object.keys(d).length>0&&console.warn("dndzone will ignore unknown options",d),!i)throw new Error("no 'items' key provided to dndzone");const h=i.find((e=>!{}.hasOwnProperty.call(e,"id")));if(h)throw new Error(`missing 'id' property for item ${jv(h)}`);if(c&&!Array.isArray(c))throw new Error(`dropTargetClasses should be an array but instead it is a ${typeof c}, ${jv(c)}`)}function Xy(){return(Xy=Object.assign||function(e){for(var t=1;t<arguments.length;t++){var n=arguments[t];for(var r in n)Object.prototype.hasOwnProperty.call(n,r)&&(e[r]=n[r])}return e}).apply(this,arguments)}function Jy(e,t){for(var n=0;n<t.length;n++){var r=t[n];r.enumerable=r.enumerable||!1,r.configurable=!0,"value"in r&&(r.writable=!0),Object.defineProperty(e,r.key,r)}}var Qy=Object.prototype.hasOwnProperty;function eb(e,t){return null!=e&&Qy.call(e,t)}var tb=Array.isArray,nb="object"==typeof global&&global&&global.Object===Object&&global,rb="object"==typeof self&&self&&self.Object===Object&&self,ib=nb||rb||Function("return this")(),ob=ib.Symbol,ab=Object.prototype,sb=ab.hasOwnProperty,lb=ab.toString,ub=ob?ob.toStringTag:void 0;var cb=Object.prototype.toString;var fb=ob?ob.toStringTag:void 0;function pb(e){return null==e?void 0===e?"[object Undefined]":"[object Null]":fb&&fb in Object(e)?function(e){var t=sb.call(e,ub),n=e[ub];try{e[ub]=void 0;var r=!0}catch(o){}var i=lb.call(e);return r&&(t?e[ub]=n:delete e[ub]),i}(e):function(e){return cb.call(e)}(e)}function db(e){return null!=e&&"object"==typeof e}function hb(e){return"symbol"==typeof e||db(e)&&"[object Symbol]"==pb(e)}var gb=/\.|\[(?:[^[\]]*|(["'])(?:(?!\1)[^\\]|\\.)*?\1)\]/,mb=/^\w*$/;function vb(e,t){if(tb(e))return!1;var n=typeof e;return!("number"!=n&&"symbol"!=n&&"boolean"!=n&&null!=e&&!hb(e))||(mb.test(e)||!gb.test(e)||null!=t&&e in Object(t))}function yb(e){var t=typeof e;return null!=e&&("object"==t||"function"==t)}function bb(e){if(!yb(e))return!1;var t=pb(e);return"[object Function]"==t||"[object GeneratorFunction]"==t||"[object AsyncFunction]"==t||"[object Proxy]"==t}var _b=ib["__core-js_shared__"],wb=function(){var e=/[^.]+$/.exec(_b&&_b.keys&&_b.keys.IE_PROTO||"");return e?"Symbol(src)_1."+e:""}();var xb=Function.prototype.toString;function kb(e){if(null!=e){try{return xb.call(e)}catch(t){}try{return e+""}catch(t){}}return""}var Cb=/^\[object .+?Constructor\]$/,Eb=Function.prototype,Ob=Object.prototype,Ab=Eb.toString,Sb=Ob.hasOwnProperty,jb=RegExp("^"+Ab.call(Sb).replace(/[\\^$.*+?()[\]{}|]/g,"\\$&").replace(/hasOwnProperty|(function).*?(?=\\\()| for .+?(?=\\\])/g,"$1.*?")+"$");function Tb(e){return!(!yb(e)||(t=e,wb&&wb in t))&&(bb(e)?jb:Cb).test(kb(e));var t}function Db(e,t){var n=function(e,t){return null==e?void 0:e[t]}(e,t);return Tb(n)?n:void 0}var Nb=Db(Object,"create");var Lb=Object.prototype.hasOwnProperty;var Mb=Object.prototype.hasOwnProperty;function Pb(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}function Fb(e,t){return e===t||e!=e&&t!=t}function qb(e,t){for(var n=e.length;n--;)if(Fb(e[n][0],t))return n;return-1}Pb.prototype.clear=function(){this.__data__=Nb?Nb(null):{},this.size=0},Pb.prototype.delete=function(e){var t=this.has(e)&&delete this.__data__[e];return this.size-=t?1:0,t},Pb.prototype.get=function(e){var t=this.__data__;if(Nb){var n=t[e];return"__lodash_hash_undefined__"===n?void 0:n}return Lb.call(t,e)?t[e]:void 0},Pb.prototype.has=function(e){var t=this.__data__;return Nb?void 0!==t[e]:Mb.call(t,e)},Pb.prototype.set=function(e,t){var n=this.__data__;return this.size+=this.has(e)?0:1,n[e]=Nb&&void 0===t?"__lodash_hash_undefined__":t,this};var Ib=Array.prototype.splice;function $b(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}$b.prototype.clear=function(){this.__data__=[],this.size=0},$b.prototype.delete=function(e){var t=this.__data__,n=qb(t,e);return!(n<0)&&(n==t.length-1?t.pop():Ib.call(t,n,1),--this.size,!0)},$b.prototype.get=function(e){var t=this.__data__,n=qb(t,e);return n<0?void 0:t[n][1]},$b.prototype.has=function(e){return qb(this.__data__,e)>-1},$b.prototype.set=function(e,t){var n=this.__data__,r=qb(n,e);return r<0?(++this.size,n.push([e,t])):n[r][1]=t,this};var Rb=Db(ib,"Map");function zb(e,t){var n=e.__data__;return function(e){var t=typeof e;return"string"==t||"number"==t||"symbol"==t||"boolean"==t?"__proto__"!==e:null===e}(t)?n["string"==typeof t?"string":"hash"]:n.map}function Bb(e){var t=-1,n=null==e?0:e.length;for(this.clear();++t<n;){var r=e[t];this.set(r[0],r[1])}}Bb.prototype.clear=function(){this.size=0,this.__data__={hash:new Pb,map:new(Rb||$b),string:new Pb}},Bb.prototype.delete=function(e){var t=zb(this,e).delete(e);return this.size-=t?1:0,t},Bb.prototype.get=function(e){return zb(this,e).get(e)},Bb.prototype.has=function(e){return zb(this,e).has(e)},Bb.prototype.set=function(e,t){var n=zb(this,e),r=n.size;return n.set(e,t),this.size+=n.size==r?0:1,this};function Wb(e,t){if("function"!=typeof e||null!=t&&"function"!=typeof t)throw new TypeError("Expected a function");var n=function(){var r=arguments,i=t?t.apply(this,r):r[0],o=n.cache;if(o.has(i))return o.get(i);var a=e.apply(this,r);return n.cache=o.set(i,a)||o,a};return n.cache=new(Wb.Cache||Bb),n}Wb.Cache=Bb;var Hb,Ub,Vb,Kb=/[^.[\]]+|\[(?:(-?\d+(?:\.\d+)?)|(["'])((?:(?!\2)[^\\]|\\.)*?)\2)\]|(?=(?:\.|\[\])(?:\.|\[\]|$))/g,Yb=/\\(\\)?/g,Gb=(Hb=function(e){var t=[];return 46===e.charCodeAt(0)&&t.push(""),e.replace(Kb,(function(e,n,r,i){t.push(r?i.replace(Yb,"$1"):n||e)})),t},Ub=Wb(Hb,(function(e){return 500===Vb.size&&Vb.clear(),e})),Vb=Ub.cache,Ub);function Zb(e,t){for(var n=-1,r=null==e?0:e.length,i=Array(r);++n<r;)i[n]=t(e[n],n,e);return i}var Xb=ob?ob.prototype:void 0,Jb=Xb?Xb.toString:void 0;function Qb(e){if("string"==typeof e)return e;if(tb(e))return Zb(e,Qb)+"";if(hb(e))return Jb?Jb.call(e):"";var t=e+"";return"0"==t&&1/e==-Infinity?"-0":t}function e_(e){return null==e?"":Qb(e)}function t_(e,t){return tb(e)?e:vb(e,t)?[e]:Gb(e_(e))}function n_(e){return db(e)&&"[object Arguments]"==pb(e)}var r_=Object.prototype,i_=r_.hasOwnProperty,o_=r_.propertyIsEnumerable,a_=n_(function(){return arguments}())?n_:function(e){return db(e)&&i_.call(e,"callee")&&!o_.call(e,"callee")},s_=/^(?:0|[1-9]\d*)$/;function l_(e,t){var n=typeof e;return!!(t=null==t?9007199254740991:t)&&("number"==n||"symbol"!=n&&s_.test(e))&&e>-1&&e%1==0&&e<t}function u_(e){return"number"==typeof e&&e>-1&&e%1==0&&e<=9007199254740991}function c_(e){if("string"==typeof e||hb(e))return e;var t=e+"";return"0"==t&&1/e==-Infinity?"-0":t}function f_(e,t,n){for(var r=-1,i=(t=t_(t,e)).length,o=!1;++r<i;){var a=c_(t[r]);if(!(o=null!=e&&n(e,a)))break;e=e[a]}return o||++r!=i?o:!!(i=null==e?0:e.length)&&u_(i)&&l_(a,i)&&(tb(e)||a_(e))}function p_(e,t){return null!=e&&f_(e,t,eb)}function d_(e){var t=this.__data__=new $b(e);this.size=t.size}d_.prototype.clear=function(){this.__data__=new $b,this.size=0},d_.prototype.delete=function(e){var t=this.__data__,n=t.delete(e);return this.size=t.size,n},d_.prototype.get=function(e){return this.__data__.get(e)},d_.prototype.has=function(e){return this.__data__.has(e)},d_.prototype.set=function(e,t){var n=this.__data__;if(n instanceof $b){var r=n.__data__;if(!Rb||r.length<199)return r.push([e,t]),this.size=++n.size,this;n=this.__data__=new Bb(r)}return n.set(e,t),this.size=n.size,this};var h_=function(){try{var e=Db(Object,"defineProperty");return e({},"",{}),e}catch(t){}}();function g_(e,t,n){"__proto__"==t&&h_?h_(e,t,{configurable:!0,enumerable:!0,value:n,writable:!0}):e[t]=n}var m_=Object.prototype.hasOwnProperty;function v_(e,t,n){var r=e[t];m_.call(e,t)&&Fb(r,n)&&(void 0!==n||t in e)||g_(e,t,n)}function y_(e,t,n,r){var i=!n;n||(n={});for(var o=-1,a=t.length;++o<a;){var s=t[o],l=r?r(n[s],e[s],s,n,e):void 0;void 0===l&&(l=e[s]),i?g_(n,s,l):v_(n,s,l)}return n}var b_="object"==typeof exports&&exports&&!exports.nodeType&&exports,__=b_&&"object"==typeof module&&module&&!module.nodeType&&module,w_=__&&__.exports===b_?ib.Buffer:void 0,x_=(w_?w_.isBuffer:void 0)||function(){return!1},k_={};function C_(e){return function(t){return e(t)}}k_["[object Float32Array]"]=k_["[object Float64Array]"]=k_["[object Int8Array]"]=k_["[object Int16Array]"]=k_["[object Int32Array]"]=k_["[object Uint8Array]"]=k_["[object Uint8ClampedArray]"]=k_["[object Uint16Array]"]=k_["[object Uint32Array]"]=!0,k_["[object Arguments]"]=k_["[object Array]"]=k_["[object ArrayBuffer]"]=k_["[object Boolean]"]=k_["[object DataView]"]=k_["[object Date]"]=k_["[object Error]"]=k_["[object Function]"]=k_["[object Map]"]=k_["[object Number]"]=k_["[object Object]"]=k_["[object RegExp]"]=k_["[object Set]"]=k_["[object String]"]=k_["[object WeakMap]"]=!1;var E_="object"==typeof exports&&exports&&!exports.nodeType&&exports,O_=E_&&"object"==typeof module&&module&&!module.nodeType&&module,A_=O_&&O_.exports===E_&&nb.process,S_=function(){try{var e=O_&&O_.require&&O_.require("util").types;return e||A_&&A_.binding&&A_.binding("util")}catch(t){}}(),j_=S_&&S_.isTypedArray,T_=j_?C_(j_):function(e){return db(e)&&u_(e.length)&&!!k_[pb(e)]},D_=Object.prototype.hasOwnProperty;function N_(e,t){var n=tb(e),r=!n&&a_(e),i=!n&&!r&&x_(e),o=!n&&!r&&!i&&T_(e),a=n||r||i||o,s=a?function(e,t){for(var n=-1,r=Array(e);++n<e;)r[n]=t(n);return r}(e.length,String):[],l=s.length;for(var u in e)!t&&!D_.call(e,u)||a&&("length"==u||i&&("offset"==u||"parent"==u)||o&&("buffer"==u||"byteLength"==u||"byteOffset"==u)||l_(u,l))||s.push(u);return s}var L_=Object.prototype;function M_(e){var t=e&&e.constructor;return e===("function"==typeof t&&t.prototype||L_)}function P_(e,t){return function(n){return e(t(n))}}var F_=P_(Object.keys,Object),q_=Object.prototype.hasOwnProperty;function I_(e){return null!=e&&u_(e.length)&&!bb(e)}function $_(e){return I_(e)?N_(e):function(e){if(!M_(e))return F_(e);var t=[];for(var n in Object(e))q_.call(e,n)&&"constructor"!=n&&t.push(n);return t}(e)}var R_=Object.prototype.hasOwnProperty;function z_(e){if(!yb(e))return function(e){var t=[];if(null!=e)for(var n in Object(e))t.push(n);return t}(e);var t=M_(e),n=[];for(var r in e)("constructor"!=r||!t&&R_.call(e,r))&&n.push(r);return n}function B_(e){return I_(e)?N_(e,!0):z_(e)}var W_="object"==typeof exports&&exports&&!exports.nodeType&&exports,H_=W_&&"object"==typeof module&&module&&!module.nodeType&&module,U_=H_&&H_.exports===W_?ib.Buffer:void 0,V_=U_?U_.allocUnsafe:void 0;function K_(e,t){var n=-1,r=e.length;for(t||(t=Array(r));++n<r;)t[n]=e[n];return t}function Y_(){return[]}var G_=Object.prototype.propertyIsEnumerable,Z_=Object.getOwnPropertySymbols,X_=Z_?function(e){return null==e?[]:(e=Object(e),function(e,t){for(var n=-1,r=null==e?0:e.length,i=0,o=[];++n<r;){var a=e[n];t(a,n,e)&&(o[i++]=a)}return o}(Z_(e),(function(t){return G_.call(e,t)})))}:Y_;function J_(e,t){for(var n=-1,r=t.length,i=e.length;++n<r;)e[i+n]=t[n];return e}var Q_=P_(Object.getPrototypeOf,Object),ew=Object.getOwnPropertySymbols?function(e){for(var t=[];e;)J_(t,X_(e)),e=Q_(e);return t}:Y_;function tw(e,t,n){var r=t(e);return tb(e)?r:J_(r,n(e))}function nw(e){return tw(e,$_,X_)}function rw(e){return tw(e,B_,ew)}var iw=Db(ib,"DataView"),ow=Db(ib,"Promise"),aw=Db(ib,"Set"),sw=Db(ib,"WeakMap"),lw=kb(iw),uw=kb(Rb),cw=kb(ow),fw=kb(aw),pw=kb(sw),dw=pb;(iw&&"[object DataView]"!=dw(new iw(new ArrayBuffer(1)))||Rb&&"[object Map]"!=dw(new Rb)||ow&&"[object Promise]"!=dw(ow.resolve())||aw&&"[object Set]"!=dw(new aw)||sw&&"[object WeakMap]"!=dw(new sw))&&(dw=function(e){var t=pb(e),n="[object Object]"==t?e.constructor:void 0,r=n?kb(n):"";if(r)switch(r){case lw:return"[object DataView]";case uw:return"[object Map]";case cw:return"[object Promise]";case fw:return"[object Set]";case pw:return"[object WeakMap]"}return t});var hw=dw,gw=Object.prototype.hasOwnProperty;var mw=ib.Uint8Array;function vw(e){var t=new e.constructor(e.byteLength);return new mw(t).set(new mw(e)),t}var yw=/\w*$/;var bw=ob?ob.prototype:void 0,_w=bw?bw.valueOf:void 0;function ww(e,t,n){var r,i=e.constructor;switch(t){case"[object ArrayBuffer]":return vw(e);case"[object Boolean]":case"[object Date]":return new i(+e);case"[object DataView]":return function(e,t){var n=t?vw(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.byteLength)}(e,n);case"[object Float32Array]":case"[object Float64Array]":case"[object Int8Array]":case"[object Int16Array]":case"[object Int32Array]":case"[object Uint8Array]":case"[object Uint8ClampedArray]":case"[object Uint16Array]":case"[object Uint32Array]":return function(e,t){var n=t?vw(e.buffer):e.buffer;return new e.constructor(n,e.byteOffset,e.length)}(e,n);case"[object Map]":return new i;case"[object Number]":case"[object String]":return new i(e);case"[object RegExp]":return function(e){var t=new e.constructor(e.source,yw.exec(e));return t.lastIndex=e.lastIndex,t}(e);case"[object Set]":return new i;case"[object Symbol]":return r=e,_w?Object(_w.call(r)):{}}}var xw=Object.create,kw=function(){function e(){}return function(t){if(!yb(t))return{};if(xw)return xw(t);e.prototype=t;var n=new e;return e.prototype=void 0,n}}();var Cw=S_&&S_.isMap,Ew=Cw?C_(Cw):function(e){return db(e)&&"[object Map]"==hw(e)};var Ow=S_&&S_.isSet,Aw=Ow?C_(Ow):function(e){return db(e)&&"[object Set]"==hw(e)},Sw={};function jw(e,t,n,r,i,o){var a,s=1&t,l=2&t,u=4&t;if(n&&(a=i?n(e,r,i,o):n(e)),void 0!==a)return a;if(!yb(e))return e;var c=tb(e);if(c){if(a=function(e){var t=e.length,n=new e.constructor(t);return t&&"string"==typeof e[0]&&gw.call(e,"index")&&(n.index=e.index,n.input=e.input),n}(e),!s)return K_(e,a)}else{var f=hw(e),p="[object Function]"==f||"[object GeneratorFunction]"==f;if(x_(e))return function(e,t){if(t)return e.slice();var n=e.length,r=V_?V_(n):new e.constructor(n);return e.copy(r),r}(e,s);if("[object Object]"==f||"[object Arguments]"==f||p&&!i){if(a=l||p?{}:function(e){return"function"!=typeof e.constructor||M_(e)?{}:kw(Q_(e))}(e),!s)return l?function(e,t){return y_(e,ew(e),t)}(e,function(e,t){return e&&y_(t,B_(t),e)}(a,e)):function(e,t){return y_(e,X_(e),t)}(e,function(e,t){return e&&y_(t,$_(t),e)}(a,e))}else{if(!Sw[f])return i?e:{};a=ww(e,f,s)}}o||(o=new d_);var d=o.get(e);if(d)return d;o.set(e,a),Aw(e)?e.forEach((function(r){a.add(jw(r,t,n,r,e,o))})):Ew(e)&&e.forEach((function(r,i){a.set(i,jw(r,t,n,i,e,o))}));var h=c?void 0:(u?l?rw:nw:l?B_:$_)(e);return function(e,t){for(var n=-1,r=null==e?0:e.length;++n<r&&!1!==t(e[n],n,e););}(h||e,(function(r,i){h&&(r=e[i=r]),v_(a,i,jw(r,t,n,i,e,o))})),a}Sw["[object Arguments]"]=Sw["[object Array]"]=Sw["[object ArrayBuffer]"]=Sw["[object DataView]"]=Sw["[object Boolean]"]=Sw["[object Date]"]=Sw["[object Float32Array]"]=Sw["[object Float64Array]"]=Sw["[object Int8Array]"]=Sw["[object Int16Array]"]=Sw["[object Int32Array]"]=Sw["[object Map]"]=Sw["[object Number]"]=Sw["[object Object]"]=Sw["[object RegExp]"]=Sw["[object Set]"]=Sw["[object String]"]=Sw["[object Symbol]"]=Sw["[object Uint8Array]"]=Sw["[object Uint8ClampedArray]"]=Sw["[object Uint16Array]"]=Sw["[object Uint32Array]"]=!0,Sw["[object Error]"]=Sw["[object Function]"]=Sw["[object WeakMap]"]=!1;function Tw(e,t){return jw(e,5,t="function"==typeof t?t:void 0)}function Dw(e){var t=-1,n=Array(e.size);return e.forEach((function(e,r){n[++t]=[r,e]})),n}function Nw(e){var t=-1,n=Array(e.size);return e.forEach((function(e){n[++t]=e})),n}var Lw=RegExp("[\\u200d\\ud800-\\udfff\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff\\ufe0e\\ufe0f]");function Mw(e){return Lw.test(e)}var Pw="[\\ud800-\\udfff]",Fw="[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]",qw="\\ud83c[\\udffb-\\udfff]",Iw="[^\\ud800-\\udfff]",$w="(?:\\ud83c[\\udde6-\\uddff]){2}",Rw="[\\ud800-\\udbff][\\udc00-\\udfff]",zw="(?:"+Fw+"|"+qw+")"+"?",Bw="[\\ufe0e\\ufe0f]?"+zw+("(?:\\u200d(?:"+[Iw,$w,Rw].join("|")+")[\\ufe0e\\ufe0f]?"+zw+")*"),Ww="(?:"+[Iw+Fw+"?",Fw,$w,Rw,Pw].join("|")+")",Hw=RegExp(qw+"(?="+qw+")|"+Ww+Bw,"g");function Uw(e){return Mw(e)?function(e){return e.match(Hw)||[]}(e):function(e){return e.split("")}(e)}function Vw(e){return null==e?[]:function(e,t){return Zb(t,(function(t){return e[t]}))}(e,$_(e))}var Kw=ob?ob.iterator:void 0;function Yw(e){if(!e)return[];if(I_(e))return function(e){return"string"==typeof e||!tb(e)&&db(e)&&"[object String]"==pb(e)}(e)?Uw(e):K_(e);if(Kw&&e[Kw])return function(e){for(var t,n=[];!(t=e.next()).done;)n.push(t.value);return n}(e[Kw]());var t=hw(e);return("[object Map]"==t?Dw:"[object Set]"==t?Nw:Vw)(e)}var Gw=Object.prototype.toString,Zw=Error.prototype.toString,Xw=RegExp.prototype.toString,Jw="undefined"!=typeof Symbol?Symbol.prototype.toString:function(){return""},Qw=/^Symbol\((.*)\)(.*)$/;function ex(e,t){if(void 0===t&&(t=!1),null==e||!0===e||!1===e)return""+e;var n=typeof e;if("number"===n)return function(e){return e!=+e?"NaN":0===e&&1/e<0?"-0":""+e}(e);if("string"===n)return t?'"'+e+'"':e;if("function"===n)return"[Function "+(e.name||"anonymous")+"]";if("symbol"===n)return Jw.call(e).replace(Qw,"Symbol($1)");var r=Gw.call(e).slice(8,-1);return"Date"===r?isNaN(e.getTime())?""+e:e.toISOString(e):"Error"===r||e instanceof Error?"["+Zw.call(e)+"]":"RegExp"===r?Xw.call(e):null}function tx(e,t){var n=ex(e,t);return null!==n?n:JSON.stringify(e,(function(e,n){var r=ex(this[e],t);return null!==r?r:n}),2)}var nx="${path} is invalid",rx="${path} is a required field",ix="${path} must be one of the following values: ${values}",ox="${path} must not be one of the following values: ${values}",ax=function(e){var t=e.path,n=e.type,r=e.value,i=e.originalValue,o=null!=i&&i!==r,a=t+" must be a `"+n+"` type, but the final value was: `"+tx(r,!0)+"`"+(o?" (cast from the value `"+tx(i,!0)+"`).":".");return null===r&&(a+='\n If "null" is intended as an empty value be sure to mark the schema as `.nullable()`'),a},sx="${path} must be defined",lx="${path} must be exactly ${length} characters",ux="${path} must be at least ${min} characters",cx="${path} must be at most ${max} characters",fx='${path} must match the following: "${regex}"',px="${path} must be a valid email",dx="${path} must be a valid URL",hx="${path} must be a valid UUID",gx="${path} must be a trimmed string",mx="${path} must be a lowercase string",vx="${path} must be a upper case string",yx="${path} must be greater than or equal to ${min}",bx="${path} must be less than or equal to ${max}",_x="${path} must be less than ${less}",wx="${path} must be greater than ${more}",xx="${path} must be a positive number",kx="${path} must be a negative number",Cx="${path} must be an integer",Ex="${path} field must be later than ${min}",Ox="${path} field must be at earlier than ${max}",Ax="${path} field has unspecified keys: ${unknown}",Sx="${path} field must have at least ${min} items",jx="${path} field must have less than or equal to ${max} items",Tx=function(e){return e&&e.__isYupSchema__},Dx=function(){function e(e,t){if(this.refs=e,"function"!=typeof t){if(!p_(t,"is"))throw new TypeError("`is:` is required for `when()` conditions");if(!t.then&&!t.otherwise)throw new TypeError("either `then:` or `otherwise:` is required for `when()` conditions");var n=t.is,r=t.then,i=t.otherwise,o="function"==typeof n?n:function(){for(var e=arguments.length,t=new Array(e),r=0;r<e;r++)t[r]=arguments[r];return t.every((function(e){return e===n}))};this.fn=function(){for(var e=arguments.length,t=new Array(e),n=0;n<e;n++)t[n]=arguments[n];var a=t.pop(),s=t.pop(),l=o.apply(void 0,t)?r:i;if(l)return"function"==typeof l?l(s):s.concat(l.resolve(a))}}else this.fn=t}return e.prototype.resolve=function(e,t){var n=this.refs.map((function(e){return e.getValue(t)})),r=this.fn.apply(e,n.concat(e,t));if(void 0===r||r===e)return e;if(!Tx(r))throw new TypeError("conditions must return a schema object");return r.resolve(t)},e}();function Nx(e,t){if(null==e)return{};var n,r,i={},o=Object.keys(e);for(r=0;r<o.length;r++)n=o[r],t.indexOf(n)>=0||(i[n]=e[n]);return i}function Lx(e){return Array.prototype.slice.apply(e)}function Mx(e){this.status="pending",this._continuations=[],this._parent=null,this._paused=!1,e&&e.call(this,this._continueWith.bind(this),this._failWith.bind(this))}function Px(e){return e&&"function"==typeof e.then}function Fx(e){return e}function qx(e){return"undefined"!=typeof window&&"AggregateError"in window?new window.AggregateError(e):{errors:e}}if(Mx.prototype={then:function(e,t){var n=Mx.unresolved()._setParent(this);if(this._isRejected()){if(this._paused)return this._continuations.push({promise:n,nextFn:e,catchFn:t}),n;if(t)try{var r=t(this._error);return Px(r)?(this._chainPromiseData(r,n),n):Mx.resolve(r)._setParent(this)}catch(i){return Mx.reject(i)._setParent(this)}return Mx.reject(this._error)._setParent(this)}return this._continuations.push({promise:n,nextFn:e,catchFn:t}),this._runResolutions(),n},catch:function(e){if(this._isResolved())return Mx.resolve(this._data)._setParent(this);var t=Mx.unresolved()._setParent(this);return this._continuations.push({promise:t,catchFn:e}),this._runRejections(),t},finally:function(e){var t=!1;function n(n,r){if(!t){t=!0,e||(e=Fx);var i=e(n);return Px(i)?i.then((function(){if(r)throw r;return n})):n}}return this.then((function(e){return n(e)})).catch((function(e){return n(null,e)}))},pause:function(){return this._paused=!0,this},resume:function(){var e=this._findFirstPaused();return e&&(e._paused=!1,e._runResolutions(),e._runRejections()),this},_findAncestry:function(){return this._continuations.reduce((function(e,t){if(t.promise){var n={promise:t.promise,children:t.promise._findAncestry()};e.push(n)}return e}),[])},_setParent:function(e){if(this._parent)throw new Error("parent already set");return this._parent=e,this},_continueWith:function(e){var t=this._findFirstPending();t&&(t._data=e,t._setResolved())},_findFirstPending:function(){return this._findFirstAncestor((function(e){return e._isPending&&e._isPending()}))},_findFirstPaused:function(){return this._findFirstAncestor((function(e){return e._paused}))},_findFirstAncestor:function(e){for(var t,n=this;n;)e(n)&&(t=n),n=n._parent;return t},_failWith:function(e){var t=this._findFirstPending();t&&(t._error=e,t._setRejected())},_takeContinuations:function(){return this._continuations.splice(0,this._continuations.length)},_runRejections:function(){if(!this._paused&&this._isRejected()){var e=this._error,t=this._takeContinuations(),n=this;t.forEach((function(t){if(t.catchFn)try{var r=t.catchFn(e);n._handleUserFunctionResult(r,t.promise)}catch(i){t.promise.reject(i)}else t.promise.reject(e)}))}},_runResolutions:function(){if(!this._paused&&this._isResolved()&&!this._isPending()){var e=this._takeContinuations();if(Px(this._data))return this._handleWhenResolvedDataIsPromise(this._data);var t=this._data,n=this;e.forEach((function(e){if(e.nextFn)try{var r=e.nextFn(t);n._handleUserFunctionResult(r,e.promise)}catch(i){n._handleResolutionError(i,e)}else e.promise&&e.promise.resolve(t)}))}},_handleResolutionError:function(e,t){if(this._setRejected(),t.catchFn)try{return void t.catchFn(e)}catch(n){e=n}t.promise&&t.promise.reject(e)},_handleWhenResolvedDataIsPromise:function(e){var t=this;return e.then((function(e){t._data=e,t._runResolutions()})).catch((function(e){t._error=e,t._setRejected(),t._runRejections()}))},_handleUserFunctionResult:function(e,t){Px(e)?this._chainPromiseData(e,t):t.resolve(e)},_chainPromiseData:function(e,t){e.then((function(e){t.resolve(e)})).catch((function(e){t.reject(e)}))},_setResolved:function(){this.status="resolved",this._paused||this._runResolutions()},_setRejected:function(){this.status="rejected",this._paused||this._runRejections()},_isPending:function(){return"pending"===this.status},_isResolved:function(){return"resolved"===this.status},_isRejected:function(){return"rejected"===this.status}},Mx.resolve=function(e){return new Mx((function(t,n){Px(e)?e.then((function(e){t(e)})).catch((function(e){n(e)})):t(e)}))},Mx.reject=function(e){return new Mx((function(t,n){n(e)}))},Mx.unresolved=function(){return new Mx((function(e,t){this.resolve=e,this.reject=t}))},Mx.all=function(){var e=Lx(arguments);return Array.isArray(e[0])&&(e=e[0]),e.length?new Mx((function(t,n){var r=[],i=0,o=!1;e.forEach((function(a,s){Mx.resolve(a).then((function(n){r[s]=n,(i+=1)===e.length&&t(r)})).catch((function(e){!function(e){o||(o=!0,n(e))}(e)}))}))})):Mx.resolve([])},Mx.any=function(){var e=Lx(arguments);return Array.isArray(e[0])&&(e=e[0]),e.length?new Mx((function(t,n){var r=[],i=0,o=!1;e.forEach((function(a,s){Mx.resolve(a).then((function(e){!function(e){o||(o=!0,t(e))}(e)})).catch((function(t){r[s]=t,(i+=1)===e.length&&n(qx(r))}))}))})):Mx.reject(qx([]))},Mx.allSettled=function(){var e=Lx(arguments);return Array.isArray(e[0])&&(e=e[0]),e.length?new Mx((function(t){var n=[],r=0,i=function(){(r+=1)===e.length&&t(n)};e.forEach((function(e,t){Mx.resolve(e).then((function(e){n[t]={status:"fulfilled",value:e},i()})).catch((function(e){n[t]={status:"rejected",reason:e},i()}))}))})):Mx.resolve([])},Promise===Mx)throw new Error("Please use SynchronousPromise.installGlobally() to install globally");var Ix=Promise;Mx.installGlobally=function(e){if(Promise===Mx)return e;var t=function(e){if(void 0===e||e.__patched)return e;var t=e;return(e=function(){t.apply(this,Lx(arguments))}).__patched=!0,e}(e);return Promise=Mx,t},Mx.uninstallGlobally=function(){Promise===Mx&&(Promise=Ix)};var $x={SynchronousPromise:Mx},Rx=/\$\{\s*(\w+)\s*\}/g,zx=function(e){return function(t){return e.replace(Rx,(function(e,n){return tx(t[n])}))}};function Bx(e,t,n,r){var i=this;this.name="ValidationError",this.value=t,this.path=n,this.type=r,this.errors=[],this.inner=[],e&&[].concat(e).forEach((function(e){i.errors=i.errors.concat(e.errors||e),e.inner&&(i.inner=i.inner.concat(e.inner.length?e.inner:e))})),this.message=this.errors.length>1?this.errors.length+" errors occurred":this.errors[0],Error.captureStackTrace&&Error.captureStackTrace(this,Bx)}Bx.prototype=Object.create(Error.prototype),Bx.prototype.constructor=Bx,Bx.isError=function(e){return e&&"ValidationError"===e.name},Bx.formatError=function(e,t){"string"==typeof e&&(e=zx(e));var n=function(t){return t.path=t.label||t.path||"this","function"==typeof e?e(t):e};return 1===arguments.length?n:n(t)};var Wx=function(e){return e?$x.SynchronousPromise:Promise};function Hx(e,t){return e?null:function(e){return t.push(e),e.value}}function Ux(e){var t=e.validations,n=e.value,r=e.path,i=e.sync,o=e.errors,a=e.sort;return o=function(e){return void 0===e&&(e=[]),e.inner&&e.inner.length?e.inner:[].concat(e)}(o),function(e,t){var n=Wx(t);return n.all(e.map((function(e){return n.resolve(e).then((function(e){return{fulfilled:!0,value:e}}),(function(e){return{fulfilled:!1,value:e}}))})))}(t,i).then((function(e){var t=e.filter((function(e){return!e.fulfilled})).reduce((function(e,t){var n=t.value;if(!Bx.isError(n))throw n;return e.concat(n)}),[]);if(a&&t.sort(a),(o=t.concat(o)).length)throw new Bx(o,n,r);return n}))}function Vx(e){var t=e.endEarly,n=Nx(e,["endEarly"]);return t?function(e,t,n){return Wx(n).all(e).catch((function(e){throw"ValidationError"===e.name&&(e.value=t),e})).then((function(){return t}))}(n.validations,n.value,n.sync):Ux(n)}var Kx=function(e){return"[object Object]"===Object.prototype.toString.call(e)};function Yx(e,t){for(var n in t)if(p_(t,n)){var r=t[n],i=e[n];if(void 0===i)e[n]=r;else{if(i===r)continue;Tx(i)?Tx(r)&&(e[n]=r.concat(i)):Kx(i)?Kx(r)&&(e[n]=Yx(i,r)):Array.isArray(i)&&Array.isArray(r)&&(e[n]=r.concat(i))}}return e}var Gx,Zx=function(e,t,n){for(var r=-1,i=Object(e),o=n(e),a=o.length;a--;){var s=o[Gx?a:++r];if(!1===t(i[s],s,i))break}return e};function Xx(e,t){return e&&Zx(e,t,$_)}function Jx(e){var t=-1,n=null==e?0:e.length;for(this.__data__=new Bb;++t<n;)this.add(e[t])}function Qx(e,t){for(var n=-1,r=null==e?0:e.length;++n<r;)if(t(e[n],n,e))return!0;return!1}function ek(e,t){return e.has(t)}Jx.prototype.add=Jx.prototype.push=function(e){return this.__data__.set(e,"__lodash_hash_undefined__"),this},Jx.prototype.has=function(e){return this.__data__.has(e)};function tk(e,t,n,r,i,o){var a=1&n,s=e.length,l=t.length;if(s!=l&&!(a&&l>s))return!1;var u=o.get(e),c=o.get(t);if(u&&c)return u==t&&c==e;var f=-1,p=!0,d=2&n?new Jx:void 0;for(o.set(e,t),o.set(t,e);++f<s;){var h=e[f],g=t[f];if(r)var m=a?r(g,h,f,t,e,o):r(h,g,f,e,t,o);if(void 0!==m){if(m)continue;p=!1;break}if(d){if(!Qx(t,(function(e,t){if(!ek(d,t)&&(h===e||i(h,e,n,r,o)))return d.push(t)}))){p=!1;break}}else if(h!==g&&!i(h,g,n,r,o)){p=!1;break}}return o.delete(e),o.delete(t),p}var nk=ob?ob.prototype:void 0,rk=nk?nk.valueOf:void 0;var ik=Object.prototype.hasOwnProperty;var ok="[object Object]",ak=Object.prototype.hasOwnProperty;function sk(e,t,n,r,i,o){var a=tb(e),s=tb(t),l=a?"[object Array]":hw(e),u=s?"[object Array]":hw(t),c=(l="[object Arguments]"==l?ok:l)==ok,f=(u="[object Arguments]"==u?ok:u)==ok,p=l==u;if(p&&x_(e)){if(!x_(t))return!1;a=!0,c=!1}if(p&&!c)return o||(o=new d_),a||T_(e)?tk(e,t,n,r,i,o):function(e,t,n,r,i,o,a){switch(n){case"[object DataView]":if(e.byteLength!=t.byteLength||e.byteOffset!=t.byteOffset)return!1;e=e.buffer,t=t.buffer;case"[object ArrayBuffer]":return!(e.byteLength!=t.byteLength||!o(new mw(e),new mw(t)));case"[object Boolean]":case"[object Date]":case"[object Number]":return Fb(+e,+t);case"[object Error]":return e.name==t.name&&e.message==t.message;case"[object RegExp]":case"[object String]":return e==t+"";case"[object Map]":var s=Dw;case"[object Set]":var l=1&r;if(s||(s=Nw),e.size!=t.size&&!l)return!1;var u=a.get(e);if(u)return u==t;r|=2,a.set(e,t);var c=tk(s(e),s(t),r,i,o,a);return a.delete(e),c;case"[object Symbol]":if(rk)return rk.call(e)==rk.call(t)}return!1}(e,t,l,n,r,i,o);if(!(1&n)){var d=c&&ak.call(e,"__wrapped__"),h=f&&ak.call(t,"__wrapped__");if(d||h){var g=d?e.value():e,m=h?t.value():t;return o||(o=new d_),i(g,m,n,r,o)}}return!!p&&(o||(o=new d_),function(e,t,n,r,i,o){var a=1&n,s=nw(e),l=s.length;if(l!=nw(t).length&&!a)return!1;for(var u=l;u--;){var c=s[u];if(!(a?c in t:ik.call(t,c)))return!1}var f=o.get(e),p=o.get(t);if(f&&p)return f==t&&p==e;var d=!0;o.set(e,t),o.set(t,e);for(var h=a;++u<l;){var g=e[c=s[u]],m=t[c];if(r)var v=a?r(m,g,c,t,e,o):r(g,m,c,e,t,o);if(!(void 0===v?g===m||i(g,m,n,r,o):v)){d=!1;break}h||(h="constructor"==c)}if(d&&!h){var y=e.constructor,b=t.constructor;y==b||!("constructor"in e)||!("constructor"in t)||"function"==typeof y&&y instanceof y&&"function"==typeof b&&b instanceof b||(d=!1)}return o.delete(e),o.delete(t),d}(e,t,n,r,i,o))}function lk(e,t,n,r,i){return e===t||(null==e||null==t||!db(e)&&!db(t)?e!=e&&t!=t:sk(e,t,n,r,lk,i))}function uk(e){return e==e&&!yb(e)}function ck(e,t){return function(n){return null!=n&&(n[e]===t&&(void 0!==t||e in Object(n)))}}function fk(e){var t=function(e){for(var t=$_(e),n=t.length;n--;){var r=t[n],i=e[r];t[n]=[r,i,uk(i)]}return t}(e);return 1==t.length&&t[0][2]?ck(t[0][0],t[0][1]):function(n){return n===e||function(e,t,n,r){var i=n.length,o=i,a=!r;if(null==e)return!o;for(e=Object(e);i--;){var s=n[i];if(a&&s[2]?s[1]!==e[s[0]]:!(s[0]in e))return!1}for(;++i<o;){var l=(s=n[i])[0],u=e[l],c=s[1];if(a&&s[2]){if(void 0===u&&!(l in e))return!1}else{var f=new d_;if(r)var p=r(u,c,l,e,t,f);if(!(void 0===p?lk(c,u,3,r,f):p))return!1}}return!0}(n,e,t)}}function pk(e,t){for(var n=0,r=(t=t_(t,e)).length;null!=e&&n<r;)e=e[c_(t[n++])];return n&&n==r?e:void 0}function dk(e,t){return null!=e&&t in Object(e)}function hk(e,t){return vb(e)&&uk(t)?ck(c_(e),t):function(n){var r=function(e,t,n){var r=null==e?void 0:pk(e,t);return void 0===r?n:r}(n,e);return void 0===r&&r===t?function(e,t){return null!=e&&f_(e,t,dk)}(n,e):lk(t,r,3)}}function gk(e){return e}function mk(e){return vb(e)?(t=c_(e),function(e){return null==e?void 0:e[t]}):function(e){return function(t){return pk(t,e)}}(e);var t}function vk(e){return"function"==typeof e?e:null==e?gk:"object"==typeof e?tb(e)?hk(e[0],e[1]):fk(e):mk(e)}function yk(e,t){var n={};return t=vk(t),Xx(e,(function(e,r,i){g_(n,r,t(e,r,i))})),n}function bk(e){this._maxSize=e,this.clear()}bk.prototype.clear=function(){this._size=0,this._values=Object.create(null)},bk.prototype.get=function(e){return this._values[e]},bk.prototype.set=function(e,t){return this._size>=this._maxSize&&this.clear(),e in this._values||this._size++,this._values[e]=t};var _k=/[^.^\]^[]+|(?=\[\]|\.\.)/g,wk=/^\d+$/,xk=/^\d/,kk=/[~`!#$%\^&*+=\-\[\]\\';,/{}|\\":<>\?]/g,Ck=/^\s*(['"]?)(.*?)(\1)\s*$/,Ek=new bk(512),Ok=new bk(512),Ak=new bk(512),Sk={Cache:bk,split:Tk,normalizePath:jk,setter:function(e){var t=jk(e);return Ok.get(e)||Ok.set(e,(function(e,n){for(var r=0,i=t.length,o=e;r<i-1;){var a=t[r];if("__proto__"===a||"constructor"===a||"prototype"===a)return e;o=o[t[r++]]}o[t[r]]=n}))},getter:function(e,t){var n=jk(e);return Ak.get(e)||Ak.set(e,(function(e){for(var r=0,i=n.length;r<i;){if(null==e&&t)return;e=e[n[r++]]}return e}))},join:function(e){return e.reduce((function(e,t){return e+(Dk(t)||wk.test(t)?"["+t+"]":(e?".":"")+t)}),"")},forEach:function(e,t,n){!function(e,t,n){var r,i,o,a,s=e.length;for(i=0;i<s;i++)(r=e[i])&&(Nk(r)&&(r='"'+r+'"'),o=!(a=Dk(r))&&/^\d+$/.test(r),t.call(n,r,a,o,i,e))}(Array.isArray(e)?e:Tk(e),t,n)}};function jk(e){return Ek.get(e)||Ek.set(e,Tk(e).map((function(e){return e.replace(Ck,"$2")})))}function Tk(e){return e.match(_k)}function Dk(e){return"string"==typeof e&&e&&-1!==["'",'"'].indexOf(e.charAt(0))}function Nk(e){return!Dk(e)&&(function(e){return e.match(xk)&&!e.match(wk)}(e)||function(e){return kk.test(e)}(e))}var Lk="$",Mk=".",Pk=function(){function e(e,t){if(void 0===t&&(t={}),"string"!=typeof e)throw new TypeError("ref must be a string, got: "+e);if(this.key=e.trim(),""===e)throw new TypeError("ref must be a non-empty string");this.isContext=this.key[0]===Lk,this.isValue=this.key[0]===Mk,this.isSibling=!this.isContext&&!this.isValue;var n=this.isContext?Lk:this.isValue?Mk:"";this.path=this.key.slice(n.length),this.getter=this.path&&Sk.getter(this.path,!0),this.map=t.map}var t=e.prototype;return t.getValue=function(e){var t=this.isContext?e.context:this.isValue?e.value:e.parent;return this.getter&&(t=this.getter(t||{})),this.map&&(t=this.map(t)),t},t.cast=function(e,t){return this.getValue(Xy({},t,{value:e}))},t.resolve=function(){return this},t.describe=function(){return{type:"ref",key:this.key}},t.toString=function(){return"Ref("+this.key+")"},e.isRef=function(e){return e&&e.__isYupRef},e}();Pk.prototype.__isYupRef=!0;var Fk=Bx.formatError;function qk(e){var t=e.value,n=e.label,r=e.resolve,i=e.originalValue,o=Nx(e,["value","label","resolve","originalValue"]);return function(e){var a=void 0===e?{}:e,s=a.path,l=void 0===s?o.path:s,u=a.message,c=void 0===u?o.message:u,f=a.type,p=void 0===f?o.name:f,d=a.params;return d=Xy({path:l,value:t,originalValue:i,label:n},function(e,t,n){return yk(Xy({},e,t),n)}(o.params,d,r)),Xy(new Bx(Fk(c,d),t,l,p),{params:d})}}function Ik(e){var t=e.name,n=e.message,r=e.test,i=e.params;function o(e){var o=e.value,a=e.path,s=e.label,l=e.options,u=e.originalValue,c=e.sync,f=Nx(e,["value","path","label","options","originalValue","sync"]),p=l.parent,d=function(e){return Pk.isRef(e)?e.getValue({value:o,parent:p,context:l.context}):e},h=qk({message:n,path:a,value:o,originalValue:u,params:i,label:s,resolve:d,name:t}),g=Xy({path:a,parent:p,type:t,createError:h,resolve:d,options:l},f);return function(e,t,n,r){var i,o=e.call(t,n);if(!r)return Promise.resolve(o);if((i=o)&&"function"==typeof i.then&&"function"==typeof i.catch)throw new Error('Validation test of type: "'+t.type+'" returned a Promise during a synchronous validate. This test will finish after the validate call has returned');return $x.SynchronousPromise.resolve(o)}(r,g,o,c).then((function(e){if(Bx.isError(e))throw e;if(!e)throw h()}))}return o.OPTIONS=e,o}function $k(e,t){var n;if("undefined"==typeof Symbol||null==e[Symbol.iterator]){if(Array.isArray(e)||(n=function(e,t){if(!e)return;if("string"==typeof e)return Rk(e,t);var n=Object.prototype.toString.call(e).slice(8,-1);"Object"===n&&e.constructor&&(n=e.constructor.name);if("Map"===n||"Set"===n)return Array.from(e);if("Arguments"===n||/^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n))return Rk(e,t)}(e))||t&&e&&"number"==typeof e.length){n&&(e=n);var r=0;return function(){return r>=e.length?{done:!0}:{done:!1,value:e[r++]}}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}return(n=e[Symbol.iterator]()).next.bind(n)}function Rk(e,t){(null==t||t>e.length)&&(t=e.length);for(var n=0,r=new Array(t);n<t;n++)r[n]=e[n];return r}var zk=function(){function e(){this.list=new Set,this.refs=new Map}var t,n,r,i=e.prototype;return i.describe=function(){for(var e,t=[],n=$k(this.list);!(e=n()).done;){var r=e.value;t.push(r)}for(var i,o=$k(this.refs);!(i=o()).done;){var a=i.value[1];t.push(a.describe())}return t},i.toArray=function(){return Yw(this.list).concat(Yw(this.refs.values()))},i.add=function(e){Pk.isRef(e)?this.refs.set(e.key,e):this.list.add(e)},i.delete=function(e){Pk.isRef(e)?this.refs.delete(e.key):this.list.delete(e)},i.has=function(e,t){if(this.list.has(e))return!0;for(var n,r=this.refs.values();!(n=r.next()).done;)if(t(n.value)===e)return!0;return!1},i.clone=function(){var t=new e;return t.list=new Set(this.list),t.refs=new Map(this.refs),t},i.merge=function(e,t){var n=this.clone();return e.list.forEach((function(e){return n.add(e)})),e.refs.forEach((function(e){return n.add(e)})),t.list.forEach((function(e){return n.delete(e)})),t.refs.forEach((function(e){return n.delete(e)})),n},t=e,(n=[{key:"size",get:function(){return this.list.size+this.refs.size}}])&&Jy(t.prototype,n),r&&Jy(t,r),e}();function Bk(e){var t=this;if(void 0===e&&(e={}),!(this instanceof Bk))return new Bk;this._deps=[],this._conditions=[],this._options={abortEarly:!0,recursive:!0},this._exclusive=Object.create(null),this._whitelist=new zk,this._blacklist=new zk,this.tests=[],this.transforms=[],this.withMutation((function(){t.typeError(ax)})),p_(e,"default")&&(this._defaultDefault=e.default),this.type=e.type||"mixed",this._type=e.type||"mixed"}for(var Wk=Bk.prototype={__isYupSchema__:!0,constructor:Bk,clone:function(){var e=this;return this._mutate?this:Tw(this,(function(t){if(Tx(t)&&t!==e)return t}))},label:function(e){var t=this.clone();return t._label=e,t},meta:function(e){if(0===arguments.length)return this._meta;var t=this.clone();return t._meta=Xy(t._meta||{},e),t},withMutation:function(e){var t=this._mutate;this._mutate=!0;var n=e(this);return this._mutate=t,n},concat:function(e){if(!e||e===this)return this;if(e._type!==this._type&&"mixed"!==this._type)throw new TypeError("You cannot `concat()` schema's of different types: "+this._type+" and "+e._type);var t=Yx(e.clone(),this);return p_(e,"_default")&&(t._default=e._default),t.tests=this.tests,t._exclusive=this._exclusive,t._whitelist=this._whitelist.merge(e._whitelist,e._blacklist),t._blacklist=this._blacklist.merge(e._blacklist,e._whitelist),t.withMutation((function(t){e.tests.forEach((function(e){t.test(e.OPTIONS)}))})),t},isType:function(e){return!(!this._nullable||null!==e)||(!this._typeCheck||this._typeCheck(e))},resolve:function(e){var t=this;if(t._conditions.length){var n=t._conditions;(t=t.clone())._conditions=[],t=(t=n.reduce((function(t,n){return n.resolve(t,e)}),t)).resolve(e)}return t},cast:function(e,t){void 0===t&&(t={});var n=this.resolve(Xy({},t,{value:e})),r=n._cast(e,t);if(void 0!==e&&!1!==t.assert&&!0!==n.isType(r)){var i=tx(e),o=tx(r);throw new TypeError("The value of "+(t.path||"field")+' could not be cast to a value that satisfies the schema type: "'+n._type+'". \n\nattempted value: '+i+" \n"+(o!==i?"result of cast: "+o:""))}return r},_cast:function(e){var t=this,n=void 0===e?e:this.transforms.reduce((function(n,r){return r.call(t,n,e)}),e);return void 0===n&&p_(this,"_default")&&(n=this.default()),n},_validate:function(e,t){var n=this;void 0===t&&(t={});var r=e,i=null!=t.originalValue?t.originalValue:e,o=this._option("strict",t),a=this._option("abortEarly",t),s=t.sync,l=t.path,u=this._label;o||(r=this._cast(r,Xy({assert:!1},t)));var c={value:r,path:l,schema:this,options:t,label:u,originalValue:i,sync:s};t.from&&(c.from=t.from);var f=[];return this._typeError&&f.push(this._typeError(c)),this._whitelistError&&f.push(this._whitelistError(c)),this._blacklistError&&f.push(this._blacklistError(c)),Vx({validations:f,endEarly:a,value:r,path:l,sync:s}).then((function(e){return Vx({path:l,sync:s,value:e,endEarly:a,validations:n.tests.map((function(e){return e(c)}))})}))},validate:function(e,t){return void 0===t&&(t={}),this.resolve(Xy({},t,{value:e}))._validate(e,t)},validateSync:function(e,t){var n,r;if(void 0===t&&(t={}),this.resolve(Xy({},t,{value:e}))._validate(e,Xy({},t,{sync:!0})).then((function(e){return n=e})).catch((function(e){return r=e})),r)throw r;return n},isValid:function(e,t){return this.validate(e,t).then((function(){return!0})).catch((function(e){if("ValidationError"===e.name)return!1;throw e}))},isValidSync:function(e,t){try{return this.validateSync(e,t),!0}catch(n){if("ValidationError"===n.name)return!1;throw n}},getDefault:function(e){return void 0===e&&(e={}),this.resolve(e).default()},default:function(e){if(0===arguments.length){var t=p_(this,"_default")?this._default:this._defaultDefault;return"function"==typeof t?t.call(this):Tw(t)}var n=this.clone();return n._default=e,n},strict:function(e){void 0===e&&(e=!0);var t=this.clone();return t._options.strict=e,t},_isPresent:function(e){return null!=e},required:function(e){return void 0===e&&(e=rx),this.test({message:e,name:"required",exclusive:!0,test:function(e){return this.schema._isPresent(e)}})},notRequired:function(){var e=this.clone();return e.tests=e.tests.filter((function(e){return"required"!==e.OPTIONS.name})),e},nullable:function(e){void 0===e&&(e=!0);var t=this.clone();return t._nullable=e,t},transform:function(e){var t=this.clone();return t.transforms.push(e),t},test:function(){var e;if(void 0===(e=1===arguments.length?"function"==typeof(arguments.length<=0?void 0:arguments[0])?{test:arguments.length<=0?void 0:arguments[0]}:arguments.length<=0?void 0:arguments[0]:2===arguments.length?{name:arguments.length<=0?void 0:arguments[0],test:arguments.length<=1?void 0:arguments[1]}:{name:arguments.length<=0?void 0:arguments[0],message:arguments.length<=1?void 0:arguments[1],test:arguments.length<=2?void 0:arguments[2]}).message&&(e.message=nx),"function"!=typeof e.test)throw new TypeError("`test` is a required parameters");var t=this.clone(),n=Ik(e),r=e.exclusive||e.name&&!0===t._exclusive[e.name];if(e.exclusive&&!e.name)throw new TypeError("Exclusive tests must provide a unique `name` identifying the test");return t._exclusive[e.name]=!!e.exclusive,t.tests=t.tests.filter((function(t){if(t.OPTIONS.name===e.name){if(r)return!1;if(t.OPTIONS.test===n.OPTIONS.test)return!1}return!0})),t.tests.push(n),t},when:function(e,t){1===arguments.length&&(t=e,e=".");var n=this.clone(),r=[].concat(e).map((function(e){return new Pk(e)}));return r.forEach((function(e){e.isSibling&&n._deps.push(e.key)})),n._conditions.push(new Dx(r,t)),n},typeError:function(e){var t=this.clone();return t._typeError=Ik({message:e,name:"typeError",test:function(e){return!(void 0!==e&&!this.schema.isType(e))||this.createError({params:{type:this.schema._type}})}}),t},oneOf:function(e,t){void 0===t&&(t=ix);var n=this.clone();return e.forEach((function(e){n._whitelist.add(e),n._blacklist.delete(e)})),n._whitelistError=Ik({message:t,name:"oneOf",test:function(e){if(void 0===e)return!0;var t=this.schema._whitelist;return!!t.has(e,this.resolve)||this.createError({params:{values:t.toArray().join(", ")}})}}),n},notOneOf:function(e,t){void 0===t&&(t=ox);var n=this.clone();return e.forEach((function(e){n._blacklist.add(e),n._whitelist.delete(e)})),n._blacklistError=Ik({message:t,name:"notOneOf",test:function(e){var t=this.schema._blacklist;return!t.has(e,this.resolve)||this.createError({params:{values:t.toArray().join(", ")}})}}),n},strip:function(e){void 0===e&&(e=!0);var t=this.clone();return t._strip=e,t},_option:function(e,t){return p_(t,e)?t[e]:this._options[e]},describe:function(){var e=this.clone(),t={type:e._type,meta:e._meta,label:e._label,tests:e.tests.map((function(e){return{name:e.OPTIONS.name,params:e.OPTIONS.params}})).filter((function(e,t,n){return n.findIndex((function(t){return t.name===e.name}))===t}))};return e._whitelist.size&&(t.oneOf=e._whitelist.describe()),e._blacklist.size&&(t.notOneOf=e._blacklist.describe()),t},defined:function(e){return void 0===e&&(e=sx),this.nullable().test({message:e,name:"defined",exclusive:!0,test:function(e){return void 0!==e}})}},Hk=function(){var e=Vk[Uk];Wk[e+"At"]=function(t,n,r){void 0===r&&(r={});var i=function(e,t,n,r){var i,o,a;return void 0===r&&(r=n),t?(Sk.forEach(t,(function(s,l,u){var c=l?function(e){return e.substr(0,e.length-1).substr(1)}(s):s;if((e=e.resolve({context:r,parent:i,value:n})).innerType){var f=u?parseInt(c,10):0;if(n&&f>=n.length)throw new Error("Yup.reach cannot resolve an array item at index: "+s+", in the path: "+t+". because there is no value at that index. ");i=n,n=n&&n[f],e=e.innerType}if(!u){if(!e.fields||!e.fields[c])throw new Error("The schema does not contain the path: "+t+". (failed at: "+a+' which is a type: "'+e._type+'")');i=n,n=n&&n[c],e=e.fields[c]}o=c,a=l?"["+s+"]":"."+s})),{schema:e,parent:i,parentPath:o}):{parent:i,parentPath:t,schema:e}}(this,t,n,r.context),o=i.parent,a=i.parentPath;return i.schema[e](o&&o[a],Xy({},r,{parent:o,path:t}))}},Uk=0,Vk=["validate","validateSync"];Uk<Vk.length;Uk++)Hk();for(var Kk=0,Yk=["equals","is"];Kk<Yk.length;Kk++){Wk[Yk[Kk]]=Wk.oneOf}for(var Gk=0,Zk=["not","nope"];Gk<Zk.length;Gk++){Wk[Zk[Gk]]=Wk.notOneOf}function Xk(e,t,n){e.prototype=Object.create(t.prototype,{constructor:{value:e,enumerable:!1,writable:!0,configurable:!0}}),Xy(e.prototype,n)}Wk.optional=Wk.notRequired,Xk((function e(){var t=this;if(!(this instanceof e))return new e;Bk.call(this,{type:"boolean"}),this.withMutation((function(){t.transform((function(e){if(!this.isType(e)){if(/^(true|1)$/i.test(e))return!0;if(/^(false|0)$/i.test(e))return!1}return e}))}))}),Bk,{_typeCheck:function(e){return e instanceof Boolean&&(e=e.valueOf()),"boolean"==typeof e}});var Jk=function(e){return null==e},Qk=/^((([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+(\.([a-z]|\d|[!#\$%&'\*\+\-\/=\?\^_`{\|}~]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])+)*)|((\x22)((((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(([\x01-\x08\x0b\x0c\x0e-\x1f\x7f]|\x21|[\x23-\x5b]|[\x5d-\x7e]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(\\([\x01-\x09\x0b\x0c\x0d-\x7f]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF]))))*(((\x20|\x09)*(\x0d\x0a))?(\x20|\x09)+)?(\x22)))@((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))$/i,eC=/^((https?|ftp):)?\/\/(((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:)*@)?(((\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5])\.(\d|[1-9]\d|1\d\d|2[0-4]\d|25[0-5]))|((([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|\d|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.)+(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])*([a-z]|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])))\.?)(:\d*)?)(\/((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)+(\/(([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)*)*)?)?(\?((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|[\uE000-\uF8FF]|\/|\?)*)?(\#((([a-z]|\d|-|\.|_|~|[\u00A0-\uD7FF\uF900-\uFDCF\uFDF0-\uFFEF])|(%[\da-f]{2})|[!\$&'\(\)\*\+,;=]|:|@)|\/|\?)*)?$/i,tC=/^[0-9a-f]{8}-[0-9a-f]{4}-[0-5][0-9a-f]{3}-[089ab][0-9a-f]{3}-[0-9a-f]{12}$/i,nC=function(e){return Jk(e)||e===e.trim()};function rC(){var e=this;if(!(this instanceof rC))return new rC;Bk.call(this,{type:"string"}),this.withMutation((function(){e.transform((function(e){return this.isType(e)?e:null!=e&&e.toString?e.toString():e}))}))}Xk(rC,Bk,{_typeCheck:function(e){return e instanceof String&&(e=e.valueOf()),"string"==typeof e},_isPresent:function(e){return Bk.prototype._isPresent.call(this,e)&&e.length>0},length:function(e,t){return void 0===t&&(t=lx),this.test({message:t,name:"length",exclusive:!0,params:{length:e},test:function(t){return Jk(t)||t.length===this.resolve(e)}})},min:function(e,t){return void 0===t&&(t=ux),this.test({message:t,name:"min",exclusive:!0,params:{min:e},test:function(t){return Jk(t)||t.length>=this.resolve(e)}})},max:function(e,t){return void 0===t&&(t=cx),this.test({name:"max",exclusive:!0,message:t,params:{max:e},test:function(t){return Jk(t)||t.length<=this.resolve(e)}})},matches:function(e,t){var n,r,i=!1;return t&&("object"==typeof t?(i=t.excludeEmptyString,n=t.message,r=t.name):n=t),this.test({name:r||"matches",message:n||fx,params:{regex:e},test:function(t){return Jk(t)||""===t&&i||-1!==t.search(e)}})},email:function(e){return void 0===e&&(e=px),this.matches(Qk,{name:"email",message:e,excludeEmptyString:!0})},url:function(e){return void 0===e&&(e=dx),this.matches(eC,{name:"url",message:e,excludeEmptyString:!0})},uuid:function(e){return void 0===e&&(e=hx),this.matches(tC,{name:"uuid",message:e,excludeEmptyString:!1})},ensure:function(){return this.default("").transform((function(e){return null===e?"":e}))},trim:function(e){return void 0===e&&(e=gx),this.transform((function(e){return null!=e?e.trim():e})).test({message:e,name:"trim",test:nC})},lowercase:function(e){return void 0===e&&(e=mx),this.transform((function(e){return Jk(e)?e:e.toLowerCase()})).test({message:e,name:"string_case",exclusive:!0,test:function(e){return Jk(e)||e===e.toLowerCase()}})},uppercase:function(e){return void 0===e&&(e=vx),this.transform((function(e){return Jk(e)?e:e.toUpperCase()})).test({message:e,name:"string_case",exclusive:!0,test:function(e){return Jk(e)||e===e.toUpperCase()}})}});Xk((function e(){var t=this;if(!(this instanceof e))return new e;Bk.call(this,{type:"number"}),this.withMutation((function(){t.transform((function(e){var t=e;if("string"==typeof t){if(""===(t=t.replace(/\s/g,"")))return NaN;t=+t}return this.isType(t)?t:parseFloat(t)}))}))}),Bk,{_typeCheck:function(e){return e instanceof Number&&(e=e.valueOf()),"number"==typeof e&&!function(e){return e!=+e}(e)},min:function(e,t){return void 0===t&&(t=yx),this.test({message:t,name:"min",exclusive:!0,params:{min:e},test:function(t){return Jk(t)||t>=this.resolve(e)}})},max:function(e,t){return void 0===t&&(t=bx),this.test({message:t,name:"max",exclusive:!0,params:{max:e},test:function(t){return Jk(t)||t<=this.resolve(e)}})},lessThan:function(e,t){return void 0===t&&(t=_x),this.test({message:t,name:"max",exclusive:!0,params:{less:e},test:function(t){return Jk(t)||t<this.resolve(e)}})},moreThan:function(e,t){return void 0===t&&(t=wx),this.test({message:t,name:"min",exclusive:!0,params:{more:e},test:function(t){return Jk(t)||t>this.resolve(e)}})},positive:function(e){return void 0===e&&(e=xx),this.moreThan(0,e)},negative:function(e){return void 0===e&&(e=kx),this.lessThan(0,e)},integer:function(e){return void 0===e&&(e=Cx),this.test({name:"integer",message:e,test:function(e){return Jk(e)||Number.isInteger(e)}})},truncate:function(){return this.transform((function(e){return Jk(e)?e:0|e}))},round:function(e){var t=["ceil","floor","round","trunc"];if("trunc"===(e=e&&e.toLowerCase()||"round"))return this.truncate();if(-1===t.indexOf(e.toLowerCase()))throw new TypeError("Only valid options for round() are: "+t.join(", "));return this.transform((function(t){return Jk(t)?t:Math[e](t)}))}});var iC=/^(\d{4}|[+\-]\d{6})(?:-?(\d{2})(?:-?(\d{2}))?)?(?:[ T]?(\d{2}):?(\d{2})(?::?(\d{2})(?:[,\.](\d{1,}))?)?(?:(Z)|([+\-])(\d{2})(?::?(\d{2}))?)?)?$/;var oC=new Date("");function aC(e,t){return t||(t=e.slice(0)),e.raw=t,e}Xk((function e(){var t=this;if(!(this instanceof e))return new e;Bk.call(this,{type:"date"}),this.withMutation((function(){t.transform((function(e){return this.isType(e)?e:(e=function(e){var t,n,r=[1,4,5,6,7,10,11],i=0;if(n=iC.exec(e)){for(var o,a=0;o=r[a];++a)n[o]=+n[o]||0;n[2]=(+n[2]||1)-1,n[3]=+n[3]||1,n[7]=n[7]?String(n[7]).substr(0,3):0,void 0!==n[8]&&""!==n[8]||void 0!==n[9]&&""!==n[9]?("Z"!==n[8]&&void 0!==n[9]&&(i=60*n[10]+n[11],"+"===n[9]&&(i=0-i)),t=Date.UTC(n[1],n[2],n[3],n[4],n[5]+i,n[6],n[7])):t=+new Date(n[1],n[2],n[3],n[4],n[5],n[6],n[7])}else t=Date.parse?Date.parse(e):NaN;return t}(e),isNaN(e)?oC:new Date(e))}))}))}),Bk,{_typeCheck:function(e){return t=e,"[object Date]"===Object.prototype.toString.call(t)&&!isNaN(e.getTime());var t},min:function(e,t){void 0===t&&(t=Ex);var n=e;if(!Pk.isRef(n)&&(n=this.cast(e),!this._typeCheck(n)))throw new TypeError("`min` must be a Date or a value that can be `cast()` to a Date");return this.test({message:t,name:"min",exclusive:!0,params:{min:e},test:function(e){return Jk(e)||e>=this.resolve(n)}})},max:function(e,t){void 0===t&&(t=Ox);var n=e;if(!Pk.isRef(n)&&(n=this.cast(e),!this._typeCheck(n)))throw new TypeError("`max` must be a Date or a value that can be `cast()` to a Date");return this.test({message:t,name:"max",exclusive:!0,params:{max:e},test:function(e){return Jk(e)||e<=this.resolve(n)}})}});var sC,lC=(sC={"À":"A","Á":"A","Â":"A","Ã":"A","Ä":"A","Å":"A","à":"a","á":"a","â":"a","ã":"a","ä":"a","å":"a","Ç":"C","ç":"c","Ð":"D","ð":"d","È":"E","É":"E","Ê":"E","Ë":"E","è":"e","é":"e","ê":"e","ë":"e","Ì":"I","Í":"I","Î":"I","Ï":"I","ì":"i","í":"i","î":"i","ï":"i","Ñ":"N","ñ":"n","Ò":"O","Ó":"O","Ô":"O","Õ":"O","Ö":"O","Ø":"O","ò":"o","ó":"o","ô":"o","õ":"o","ö":"o","ø":"o","Ù":"U","Ú":"U","Û":"U","Ü":"U","ù":"u","ú":"u","û":"u","ü":"u","Ý":"Y","ý":"y","ÿ":"y","Æ":"Ae","æ":"ae","Þ":"Th","þ":"th","ß":"ss","Ā":"A","Ă":"A","Ą":"A","ā":"a","ă":"a","ą":"a","Ć":"C","Ĉ":"C","Ċ":"C","Č":"C","ć":"c","ĉ":"c","ċ":"c","č":"c","Ď":"D","Đ":"D","ď":"d","đ":"d","Ē":"E","Ĕ":"E","Ė":"E","Ę":"E","Ě":"E","ē":"e","ĕ":"e","ė":"e","ę":"e","ě":"e","Ĝ":"G","Ğ":"G","Ġ":"G","Ģ":"G","ĝ":"g","ğ":"g","ġ":"g","ģ":"g","Ĥ":"H","Ħ":"H","ĥ":"h","ħ":"h","Ĩ":"I","Ī":"I","Ĭ":"I","Į":"I","İ":"I","ĩ":"i","ī":"i","ĭ":"i","į":"i","ı":"i","Ĵ":"J","ĵ":"j","Ķ":"K","ķ":"k","ĸ":"k","Ĺ":"L","Ļ":"L","Ľ":"L","Ŀ":"L","Ł":"L","ĺ":"l","ļ":"l","ľ":"l","ŀ":"l","ł":"l","Ń":"N","Ņ":"N","Ň":"N","Ŋ":"N","ń":"n","ņ":"n","ň":"n","ŋ":"n","Ō":"O","Ŏ":"O","Ő":"O","ō":"o","ŏ":"o","ő":"o","Ŕ":"R","Ŗ":"R","Ř":"R","ŕ":"r","ŗ":"r","ř":"r","Ś":"S","Ŝ":"S","Ş":"S","Š":"S","ś":"s","ŝ":"s","ş":"s","š":"s","Ţ":"T","Ť":"T","Ŧ":"T","ţ":"t","ť":"t","ŧ":"t","Ũ":"U","Ū":"U","Ŭ":"U","Ů":"U","Ű":"U","Ų":"U","ũ":"u","ū":"u","ŭ":"u","ů":"u","ű":"u","ų":"u","Ŵ":"W","ŵ":"w","Ŷ":"Y","ŷ":"y","Ÿ":"Y","Ź":"Z","Ż":"Z","Ž":"Z","ź":"z","ż":"z","ž":"z","IJ":"IJ","ij":"ij","Œ":"Oe","œ":"oe","ʼn":"'n","ſ":"s"},function(e){return null==sC?void 0:sC[e]}),uC=/[\xc0-\xd6\xd8-\xf6\xf8-\xff\u0100-\u017f]/g,cC=RegExp("[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]","g");var fC=/[^\x00-\x2f\x3a-\x40\x5b-\x60\x7b-\x7f]+/g;var pC=/[a-z][A-Z]|[A-Z]{2}[a-z]|[0-9][a-zA-Z]|[a-zA-Z][0-9]|[^a-zA-Z0-9 ]/;var dC="\\xac\\xb1\\xd7\\xf7\\x00-\\x2f\\x3a-\\x40\\x5b-\\x60\\x7b-\\xbf\\u2000-\\u206f \\t\\x0b\\f\\xa0\\ufeff\\n\\r\\u2028\\u2029\\u1680\\u180e\\u2000\\u2001\\u2002\\u2003\\u2004\\u2005\\u2006\\u2007\\u2008\\u2009\\u200a\\u202f\\u205f\\u3000",hC="["+dC+"]",gC="\\d+",mC="[\\u2700-\\u27bf]",vC="[a-z\\xdf-\\xf6\\xf8-\\xff]",yC="[^\\ud800-\\udfff"+dC+gC+"\\u2700-\\u27bfa-z\\xdf-\\xf6\\xf8-\\xffA-Z\\xc0-\\xd6\\xd8-\\xde]",bC="(?:\\ud83c[\\udde6-\\uddff]){2}",_C="[\\ud800-\\udbff][\\udc00-\\udfff]",wC="[A-Z\\xc0-\\xd6\\xd8-\\xde]",xC="(?:"+vC+"|"+yC+")",kC="(?:"+wC+"|"+yC+")",CC="(?:[\\u0300-\\u036f\\ufe20-\\ufe2f\\u20d0-\\u20ff]|\\ud83c[\\udffb-\\udfff])?",EC="[\\ufe0e\\ufe0f]?"+CC+("(?:\\u200d(?:"+["[^\\ud800-\\udfff]",bC,_C].join("|")+")[\\ufe0e\\ufe0f]?"+CC+")*"),OC="(?:"+[mC,bC,_C].join("|")+")"+EC,AC=RegExp([wC+"?"+vC+"+(?:['](?:d|ll|m|re|s|t|ve))?(?="+[hC,wC,"$"].join("|")+")",kC+"+(?:['](?:D|LL|M|RE|S|T|VE))?(?="+[hC,wC+xC,"$"].join("|")+")",wC+"?"+xC+"+(?:['](?:d|ll|m|re|s|t|ve))?",wC+"+(?:['](?:D|LL|M|RE|S|T|VE))?","\\d*(?:1ST|2ND|3RD|(?![123])\\dTH)(?=\\b|[a-z_])","\\d*(?:1st|2nd|3rd|(?![123])\\dth)(?=\\b|[A-Z_])",gC,OC].join("|"),"g");function SC(e,t,n){return e=e_(e),void 0===(t=n?void 0:t)?function(e){return pC.test(e)}(e)?function(e){return e.match(AC)||[]}(e):function(e){return e.match(fC)||[]}(e):e.match(t)||[]}var jC=RegExp("[']","g");function TC(e){return function(t){return function(e,t,n,r){var i=-1,o=null==e?0:e.length;for(r&&o&&(n=e[++i]);++i<o;)n=t(n,e[i],i,e);return n}(SC(function(e){return(e=e_(e))&&e.replace(uC,lC).replace(cC,"")}(t).replace(jC,"")),e,"")}}var DC=TC((function(e,t,n){return e+(n?"_":"")+t.toLowerCase()}));function NC(e,t,n){var r=e.length;return n=void 0===n?r:n,!t&&n>=r?e:function(e,t,n){var r=-1,i=e.length;t<0&&(t=-t>i?0:i+t),(n=n>i?i:n)<0&&(n+=i),i=t>n?0:n-t>>>0,t>>>=0;for(var o=Array(i);++r<i;)o[r]=e[r+t];return o}(e,t,n)}var LC,MC=(LC="toUpperCase",function(e){var t=Mw(e=e_(e))?Uw(e):void 0,n=t?t[0]:e.charAt(0),r=t?NC(t,1).join(""):e.slice(1);return n[LC]()+r});var PC=TC((function(e,t,n){return t=t.toLowerCase(),e+(n?function(e){return MC(e_(e).toLowerCase())}(t):t)}));var FC=function(e){return qC(function(e){for(var t=new Set,n=0,r=e.length;n<r;n++){var i=e[n];t.add(i[0]),t.add(i[1])}return Array.from(t)}(e),e)};function qC(e,t){var n=e.length,r=new Array(n),i={},o=n,a=function(e){for(var t=new Map,n=0,r=e.length;n<r;n++){var i=e[n];t.has(i[0])||t.set(i[0],new Set),t.has(i[1])||t.set(i[1],new Set),t.get(i[0]).add(i[1])}return t}(t),s=function(e){for(var t=new Map,n=0,r=e.length;n<r;n++)t.set(e[n],n);return t}(e);for(t.forEach((function(e){if(!s.has(e[0])||!s.has(e[1]))throw new Error("Unknown node. There is an unknown node in the supplied edges.")}));o--;)i[o]||l(e[o],o,new Set);return r;function l(e,t,o){if(o.has(e)){var u;try{u=", node was:"+JSON.stringify(e)}catch(p){u=""}throw new Error("Cyclic dependency"+u)}if(!s.has(e))throw new Error("Found unknown node. Make sure to provided all involved nodes. Unknown node: "+JSON.stringify(e));if(!i[t]){i[t]=!0;var c=a.get(e)||new Set;if(t=(c=Array.from(c)).length){o.add(e);do{var f=c[--t];l(f,s.get(f),o)}while(t);o.delete(e)}r[--n]=e}}}function IC(e,t){void 0===t&&(t=[]);var n=[],r=[];function i(e,i){var o=Sk.split(e)[0];~r.indexOf(o)||r.push(o),~t.indexOf(i+"-"+o)||n.push([i,o])}for(var o in e)if(p_(e,o)){var a=e[o];~r.indexOf(o)||r.push(o),Pk.isRef(a)&&a.isSibling?i(a.path,o):Tx(a)&&a._deps&&a._deps.forEach((function(e){return i(e,o)}))}return FC.array(r,n).reverse()}function $C(e,t){var n=1/0;return e.some((function(e,r){if(-1!==t.path.indexOf(e))return n=r,!0})),n}function RC(e){for(var t=arguments.length,n=new Array(t>1?t-1:0),r=1;r<t;r++)n[r-1]=arguments[r];var i=e.reduce((function(e,t){var r=n.shift();return e+(null==r?"":r)+t}));return i.replace(/^\./,"")}function zC(){var e=aC(["",'["','"]']);return zC=function(){return e},e}function BC(){var e=aC(["",".",""]);return BC=function(){return e},e}function WC(){var e=aC(["",".",""]);return WC=function(){return e},e}FC.array=qC;var HC=function(e){return"[object Object]"===Object.prototype.toString.call(e)};function UC(e){var t=this;if(!(this instanceof UC))return new UC(e);Bk.call(this,{type:"object",default:function(){var e=this;if(this._nodes.length){var t={};return this._nodes.forEach((function(n){t[n]=e.fields[n].default?e.fields[n].default():void 0})),t}}}),this.fields=Object.create(null),this._nodes=[],this._excludedEdges=[],this.withMutation((function(){t.transform((function(e){if("string"==typeof e)try{e=JSON.parse(e)}catch(t){e=null}return this.isType(e)?e:null})),e&&t.shape(e)}))}function VC(){var e=aC(["","[","]"]);return VC=function(){return e},e}function KC(){var e=aC(["","[","]"]);return KC=function(){return e},e}function YC(e){const t={};return[...e.elements].forEach((function(e,n){switch(!0){case!e.name:case e.disabled:case/(file|reset|submit|button)/i.test(e.type):break;case/(select-multiple)/i.test(e.type):t[e.name]=[],[...e.options].forEach((function(n,r){n.selected&&t[e.name].push(n.value)}));break;case/(radio)/i.test(e.type):e.checked&&(t[e.name]=e.value);break;case/(checkbox)/i.test(e.type):e.checked&&(t[e.name]=[...t[e.name]||[],e.value]);break;default:e.value&&(t[e.name]=e.value)}})),t}function GC(e){let t=0;function n(){e.dispatchEvent(new CustomEvent("update",{detail:o({},YC(e))}))}return[...e.getElementsByTagName("input")].forEach((t=>{t.oninput=e.onchange})),e.addEventListener("input",n),n(),{update(n){2===t?function(e,t){[...e.elements].forEach((function(e,n){switch(!0){case!e.name:case e.disabled:case/(file|reset|submit|button)/i.test(e.type):break;case/(select-multiple)/i.test(e.type):[...e.options].forEach((function(n,r){n.selected=t[e.name]&&t[e.name].includes(n.value)}));break;case/(radio)/i.test(e.type):e.checked=t[e.name]&&t[e.name]===e.value;break;case/(checkbox)/i.test(e.type):e.checked=t[e.name]&&t[e.name].includes(e.value);break;default:e.value=t[e.name]||""}}))}(e,n):t+=1},destroy(){e.removeEventListener("input",n)}}}function ZC(e,t=[]){let n=[];return t.forEach((([t,r])=>{const{destroy:i=(()=>{})}=t(e,r)||{destroy:()=>{}};n.push(i)})),{destroy(){n.forEach((e=>e()))}}}function XC(e){let t,n,r,i,o,a;const s=e[3].default,l=v(s,e,e[2],null);return{c(){t=P("form"),l&&l.c()},l(e){t=Y(e,"FORM",{});var n=K(t);l&&l.l(n),n.forEach(L)},m(s,u){N(s,t,u),l&&l.m(t,null),i=!0,o||(a=[R(t,"update",e[5]),C(n=GC.call(null,t,e[0])),C(r=ZC.call(null,t,e[1])),R(t,"submit",e[4])],o=!0)},p(e,[t]){l&&l.p&&4&t&&b(l,s,e,e[2],t,null,null),n&&p(n.update)&&1&t&&n.update.call(null,e[0]),r&&p(r.update)&&2&t&&r.update.call(null,e[1])},i(e){i||(Ue(l,e),i=!0)},o(e){Ve(l,e),i=!1},d(e){e&&L(t),l&&l.d(e),o=!1,f(a)}}}function JC(e,t,n){let{$$slots:r={},$$scope:i}=t,{values:o}=t,{actions:a=[]}=t;return e.$$set=e=>{"values"in e&&n(0,o=e.values),"actions"in e&&n(1,a=e.actions),"$$scope"in e&&n(2,i=e.$$scope)},[o,a,i,r,function(t){ke(e,t)},({detail:e})=>n(0,o=e)]}Xk(UC,Bk,{_typeCheck:function(e){return HC(e)||"function"==typeof e},_cast:function(e,t){var n=this;void 0===t&&(t={});var r=Bk.prototype._cast.call(this,e,t);if(void 0===r)return this.default();if(!this._typeCheck(r))return r;var i=this.fields,o=!0===this._option("stripUnknown",t),a=this._nodes.concat(Object.keys(r).filter((function(e){return-1===n._nodes.indexOf(e)}))),s={},l=Xy({},t,{parent:s,__validating:t.__validating||!1}),u=!1;return a.forEach((function(e){var n=i[e],a=p_(r,e);if(n){var c,f=n._options&&n._options.strict;if(l.path=RC(WC(),t.path,e),l.value=r[e],!0===(n=n.resolve(l))._strip)return void(u=u||e in r);void 0!==(c=t.__validating&&f?r[e]:n.cast(r[e],l))&&(s[e]=c)}else a&&!o&&(s[e]=r[e]);s[e]!==r[e]&&(u=!0)})),u?s:r},_validate:function(e,t){var n,r,i=this;void 0===t&&(t={});var o=t.sync,a=[],s=null!=t.originalValue?t.originalValue:e,l=[{schema:this,value:s}].concat(t.from||[]);return n=this._option("abortEarly",t),r=this._option("recursive",t),t=Xy({},t,{__validating:!0,originalValue:s,from:l}),Bk.prototype._validate.call(this,e,t).catch(Hx(n,a)).then((function(e){if(!r||!HC(e)){if(a.length)throw a[0];return e}l=s?[].concat(l):[{schema:i,value:s||e}].concat(t.from||[]),s=s||e;var u,c,f=i._nodes.map((function(n){var r=-1===n.indexOf(".")?RC(BC(),t.path,n):RC(zC(),t.path,n),a=i.fields[n],u=Xy({},t,{path:r,from:l,parent:e,originalValue:s[n]});return a&&a.validate?(u.strict=!0,a.validate(e[n],u)):function(e){return e?$x.SynchronousPromise:Promise}(o).resolve(!0)}));return Vx({sync:o,validations:f,value:e,errors:a,endEarly:n,path:t.path,sort:(u=i.fields,c=Object.keys(u),function(e,t){return $C(c,e)-$C(c,t)})})}))},concat:function(e){var t=Bk.prototype.concat.call(this,e);return t._nodes=IC(t.fields,t._excludedEdges),t},shape:function(e,t){void 0===t&&(t=[]);var n=this.clone(),r=Xy(n.fields,e);if(n.fields=r,t.length){Array.isArray(t[0])||(t=[t]);var i=t.map((function(e){return e[0]+"-"+e[1]}));n._excludedEdges=n._excludedEdges.concat(i)}return n._nodes=IC(r,n._excludedEdges),n},from:function(e,t,n){var r=Sk.getter(e,!0);return this.transform((function(i){if(null==i)return i;var o=i;return p_(i,e)&&(o=Xy({},i),n||delete o[e],o[t]=r(i)),o}))},noUnknown:function(e,t){void 0===e&&(e=!0),void 0===t&&(t=Ax),"string"==typeof e&&(t=e,e=!0);var n=this.test({name:"noUnknown",exclusive:!0,message:t,test:function(t){if(null==t)return!0;var n=function(e,t){var n=Object.keys(e.fields);return Object.keys(t).filter((function(e){return-1===n.indexOf(e)}))}(this.schema,t);return!e||0===n.length||this.createError({params:{unknown:n.join(", ")}})}});return n._options.stripUnknown=e,n},unknown:function(e,t){return void 0===e&&(e=!0),void 0===t&&(t=Ax),this.noUnknown(!e,t)},transformKeys:function(e){return this.transform((function(t){return t&&function(e,t){var n={};return t=vk(t),Xx(e,(function(e,r,i){g_(n,t(e,r,i),e)})),n}(t,(function(t,n){return e(n)}))}))},camelCase:function(){return this.transformKeys(PC)},snakeCase:function(){return this.transformKeys(DC)},constantCase:function(){return this.transformKeys((function(e){return DC(e).toUpperCase()}))},describe:function(){var e=Bk.prototype.describe.call(this);return e.fields=yk(this.fields,(function(e){return e.describe()})),e}}),Xk((function e(t){var n=this;if(!(this instanceof e))return new e(t);Bk.call(this,{type:"array"}),this._subType=void 0,this.innerType=void 0,this.withMutation((function(){n.transform((function(e){if("string"==typeof e)try{e=JSON.parse(e)}catch(t){e=null}return this.isType(e)?e:null})),t&&n.of(t)}))}),Bk,{_typeCheck:function(e){return Array.isArray(e)},_cast:function(e,t){var n=this,r=Bk.prototype._cast.call(this,e,t);if(!this._typeCheck(r)||!this.innerType)return r;var i=!1,o=r.map((function(e,r){var o=n.innerType.cast(e,Xy({},t,{path:RC(KC(),t.path,r)}));return o!==e&&(i=!0),o}));return i?o:r},_validate:function(e,t){var n=this;void 0===t&&(t={});var r=[],i=t.sync,o=t.path,a=this.innerType,s=this._option("abortEarly",t),l=this._option("recursive",t),u=null!=t.originalValue?t.originalValue:e;return Bk.prototype._validate.call(this,e,t).catch(Hx(s,r)).then((function(e){if(!l||!a||!n._typeCheck(e)){if(r.length)throw r[0];return e}u=u||e;for(var c=new Array(e.length),f=0;f<e.length;f++){var p=e[f],d=RC(VC(),t.path,f),h=Xy({},t,{path:d,strict:!0,parent:e,index:f,originalValue:u[f]});c[f]=!a.validate||a.validate(p,h)}return Vx({sync:i,path:o,value:e,errors:r,endEarly:s,validations:c})}))},_isPresent:function(e){return Bk.prototype._isPresent.call(this,e)&&e.length>0},of:function(e){var t=this.clone();if(!1!==e&&!Tx(e))throw new TypeError("`array.of()` sub-schema must be a valid yup schema, or `false` to negate a current sub-schema. not: "+tx(e));return t._subType=e,t.innerType=e,t},min:function(e,t){return t=t||Sx,this.test({message:t,name:"min",exclusive:!0,params:{min:e},test:function(t){return Jk(t)||t.length>=this.resolve(e)}})},max:function(e,t){return t=t||jx,this.test({message:t,name:"max",exclusive:!0,params:{max:e},test:function(t){return Jk(t)||t.length<=this.resolve(e)}})},ensure:function(){var e=this;return this.default((function(){return[]})).transform((function(t,n){return e._typeCheck(t)?t:null==n?[]:[].concat(n)}))},compact:function(e){var t=e?function(t,n,r){return!e(t,n,r)}:function(e){return!!e};return this.transform((function(e){return null!=e?e.filter(t):e}))},describe:function(){var e=Bk.prototype.describe.call(this);return this.innerType&&(e.innerType=this.innerType.describe()),e}});class QC extends pt{constructor(e){super(),ft(this,e,JC,XC,d,{values:0,actions:1})}}export{te as $,I as A,Z as B,D as C,st as D,lt as E,ut as F,ct as G,q as H,G as I,X as J,C as K,f as L,_e as M,J as N,Ee as O,a as P,ae as Q,Q as R,pt as S,jl as T,ru as U,ve as V,Po as W,F as X,M as Y,Ne as Z,ee as _,d as a,x as a0,l as a1,U as a2,it as a3,w as a4,_ as a5,hu as a6,Ze as a7,fu as a8,p as a9,jg as aA,Km as aB,Gy as aC,tt as aD,de as aE,pe as aF,Ym as aG,De as aH,h as aI,k as aJ,Gt as aK,he as aL,Ye as aM,Ge as aN,nt as aO,rC as aP,UC as aQ,Xe as aR,Ht as aS,QC as aT,zn as aU,vn as aV,we as aa,W as ab,cu as ac,uu as ad,ot as ae,xe as af,Hu as ag,at as ah,Le as ai,ye as aj,V as ak,m as al,Uu as am,Yu as an,Gu as ao,B as ap,be as aq,Xt as ar,Yt as as,Eg as at,Vt as au,Og as av,Jt as aw,rt as ax,et as ay,re as az,N as b,Dr as c,At as d,$ as e,tr as f,g,We as h,ft as i,He as j,Ue as k,L as l,po as m,ke as n,v as o,P as p,Y as q,K as r,No as s,Ve as t,H as u,ie as v,Ot as w,R as x,z as y,b as z};