@inploi/plugin-kin 2.4.2 → 2.4.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cdn/index.js +69 -63
- package/dist/highlighted-body-B3W2YXNL-15e6e8b8.cjs +1 -0
- package/dist/highlighted-body-B3W2YXNL-253b4ec3.js +18 -0
- package/dist/index-3f4392e3.cjs +153 -0
- package/dist/{index-37da3520.js → index-d25ecdf4.js} +5776 -5255
- package/dist/mermaid-3ZIDBTTL-4d7b0491.cjs +1 -0
- package/dist/mermaid-3ZIDBTTL-b4c4fb06.js +5 -0
- package/dist/plugin-kin.cjs +1 -1
- package/dist/plugin-kin.js +1 -1
- package/package.json +2 -2
- package/dist/code-block-37QAKDTI-7eb2a6e1.cjs +0 -2
- package/dist/code-block-37QAKDTI-c0a4b004.js +0 -26
- package/dist/index-f19ff544.cjs +0 -146
- package/dist/mermaid-4DMBBIKO-6511b2b6.cjs +0 -1
- package/dist/mermaid-4DMBBIKO-9c98e510.js +0 -5
package/cdn/index.js
CHANGED
|
@@ -1,55 +1,59 @@
|
|
|
1
|
-
var b6=Object.defineProperty;var E6=(Ut,at,zt)=>at in Ut?b6(Ut,at,{enumerable:!0,configurable:!0,writable:!0,value:zt}):Ut[at]=zt;var fe=(Ut,at,zt)=>(E6(Ut,typeof at!="symbol"?at+"":at,zt),zt);(function(){var ki;"use strict";var Ut=e=>e,at="isdk_session",zt=e=>{let t=new Date;return t.setTime(t.getTime()+6048e5),`${at}=${e};expires=${t.toUTCString()};path=/`},w0=(e,t)=>{let n=e.get("session_id");if(t||n)return n;let r=sessionStorage.getItem(`${at}-session_id`);return typeof r=="string"?r:null},A0=new RegExp(`${at}=([^;]+)`),C0=e=>{let t=e?e.url:location.href,{searchParams:n}=new URL(t),r=n.get("anonymous_id"),i=w0(n,typeof window>"u");if(r)return{anonymous_id:r,session_id:i};let a=e?e.headers.get("cookie"):document.cookie;return a?{anonymous_id:A0.exec(a)?.[1]??null,session_id:i}:{anonymous_id:r,session_id:i}},Cs=()=>{if(typeof window>"u")throw new Error("getOrCreateAnonymousId() can only be called in browser environment");let e=C0().anonymous_id;if(e)return e;let t=crypto.randomUUID();return document.cookie=zt(t),t},br,W,Ss,Is,$t,Ns,vs,wi,Ls,an={},Rs=[],S0=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,Er=Array.isArray;function At(e,t){for(var n in t)e[n]=t[n];return e}function Os(e){var t=e.parentNode;t&&t.removeChild(e)}function Ct(e,t,n){var r,i,a,s={};for(a in t)a=="key"?r=t[a]:a=="ref"?i=t[a]:s[a]=t[a];if(arguments.length>2&&(s.children=arguments.length>3?br.call(arguments,2):n),typeof e=="function"&&e.defaultProps!=null)for(a in e.defaultProps)s[a]===void 0&&(s[a]=e.defaultProps[a]);return Tr(e,s,r,i,null)}function Tr(e,t,n,r,i){var a={type:e,props:t,key:n,ref:r,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,__h:null,constructor:void 0,__v:i??++Ss};return i==null&&W.vnode!=null&&W.vnode(a),a}function Ue(e){return e.children}function dt(e,t){this.props=e,this.context=t}function _r(e,t){if(t==null)return e.__?_r(e.__,e.__.__k.indexOf(e)+1):null;for(var n;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null)return n.__e;return typeof e.type=="function"?_r(e):null}function Ds(e){var t,n;if((e=e.__)!=null&&e.__c!=null){for(e.__e=e.__c.base=null,t=0;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null){e.__e=e.__c.base=n.__e;break}return Ds(e)}}function Ai(e){(!e.__d&&(e.__d=!0)&&$t.push(e)&&!kr.__r++||Ns!==W.debounceRendering)&&((Ns=W.debounceRendering)||vs)(kr)}function kr(){var e,t,n,r,i,a,s,o,u;for($t.sort(wi);e=$t.shift();)e.__d&&(t=$t.length,r=void 0,i=void 0,a=void 0,o=(s=(n=e).__v).__e,(u=n.__P)&&(r=[],i=[],(a=At({},s)).__v=s.__v+1,Ci(u,s,a,n.__n,u.ownerSVGElement!==void 0,s.__h!=null?[o]:null,r,o??_r(s),s.__h,i),zs(r,s,i),s.__e!=o&&Ds(s)),$t.length>t&&$t.sort(wi));kr.__r=0}function Ps(e,t,n,r,i,a,s,o,u,c,f){var d,h,p,m,_,A,y,I,S,D,P=0,w=r&&r.__k||Rs,z=w.length,L=z,H=t.length;for(n.__k=[],d=0;d<H;d++)(m=n.__k[d]=(m=t[d])==null||typeof m=="boolean"||typeof m=="function"?null:typeof m=="string"||typeof m=="number"||typeof m=="bigint"?Tr(null,m,null,null,m):Er(m)?Tr(Ue,{children:m},null,null,null):m.__b>0?Tr(m.type,m.props,m.key,m.ref?m.ref:null,m.__v):m)!=null&&(m.__=n,m.__b=n.__b+1,(I=I0(m,w,y=d+P,L))===-1?p=an:(p=w[I]||an,w[I]=void 0,L--),Ci(e,m,p,i,a,s,o,u,c,f),_=m.__e,(h=m.ref)&&p.ref!=h&&(p.ref&&Si(p.ref,null,m),f.push(h,m.__c||_,m)),_!=null&&(A==null&&(A=_),D=!(S=p===an||p.__v===null)&&I===y,S?I==-1&&P--:I!==y&&(I===y+1?(P++,D=!0):I>y?L>H-y?(P+=I-y,D=!0):P--:P=I<y&&I==y-1?I-y:0),y=d+P,D=D||I==d&&!S,typeof m.type!="function"||I===y&&p.__k!==m.__k?typeof m.type=="function"||D?m.__d!==void 0?(u=m.__d,m.__d=void 0):u=_.nextSibling:u=Bs(e,_,u):u=Ms(m,u,e),typeof n.type=="function"&&(n.__d=u)));for(n.__e=A,d=z;d--;)w[d]!=null&&(typeof n.type=="function"&&w[d].__e!=null&&w[d].__e==n.__d&&(n.__d=w[d].__e.nextSibling),$s(w[d],w[d]))}function Ms(e,t,n){for(var r,i=e.__k,a=0;i&&a<i.length;a++)(r=i[a])&&(r.__=e,t=typeof r.type=="function"?Ms(r,t,n):Bs(n,r.__e,t));return t}function xr(e,t){return t=t||[],e==null||typeof e=="boolean"||(Er(e)?e.some(function(n){xr(n,t)}):t.push(e)),t}function Bs(e,t,n){return n==null||n.parentNode!==e?e.insertBefore(t,null):t==n&&t.parentNode!=null||e.insertBefore(t,n),t.nextSibling}function I0(e,t,n,r){var i=e.key,a=e.type,s=n-1,o=n+1,u=t[n];if(u===null||u&&i==u.key&&a===u.type)return n;if(r>(u!=null?1:0))for(;s>=0||o<t.length;){if(s>=0){if((u=t[s])&&i==u.key&&a===u.type)return s;s--}if(o<t.length){if((u=t[o])&&i==u.key&&a===u.type)return o;o++}}return-1}function N0(e,t,n,r,i){var a;for(a in n)a==="children"||a==="key"||a in t||yr(e,a,null,n[a],r);for(a in t)i&&typeof t[a]!="function"||a==="children"||a==="key"||a==="value"||a==="checked"||n[a]===t[a]||yr(e,a,t[a],n[a],r)}function Fs(e,t,n){t[0]==="-"?e.setProperty(t,n??""):e[t]=n==null?"":typeof n!="number"||S0.test(t)?n:n+"px"}function yr(e,t,n,r,i){var a;e:if(t==="style")if(typeof n=="string")e.style.cssText=n;else{if(typeof r=="string"&&(e.style.cssText=r=""),r)for(t in r)n&&t in n||Fs(e.style,t,"");if(n)for(t in n)r&&n[t]===r[t]||Fs(e.style,t,n[t])}else if(t[0]==="o"&&t[1]==="n")a=t!==(t=t.replace(/Capture$/,"")),t=t.toLowerCase()in e?t.toLowerCase().slice(2):t.slice(2),e.l||(e.l={}),e.l[t+a]=n,n?r||e.addEventListener(t,a?Us:Hs,a):e.removeEventListener(t,a?Us:Hs,a);else if(t!=="dangerouslySetInnerHTML"){if(i)t=t.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if(t!=="width"&&t!=="height"&&t!=="href"&&t!=="list"&&t!=="form"&&t!=="tabIndex"&&t!=="download"&&t!=="rowSpan"&&t!=="colSpan"&&t in e)try{e[t]=n??"";break e}catch{}typeof n=="function"||(n==null||n===!1&&t[4]!=="-"?e.removeAttribute(t):e.setAttribute(t,n))}}function Hs(e){return this.l[e.type+!1](W.event?W.event(e):e)}function Us(e){return this.l[e.type+!0](W.event?W.event(e):e)}function Ci(e,t,n,r,i,a,s,o,u,c){var f,d,h,p,m,_,A,y,I,S,D,P,w,z,L,H=t.type;if(t.constructor!==void 0)return null;n.__h!=null&&(u=n.__h,o=t.__e=n.__e,t.__h=null,a=[o]),(f=W.__b)&&f(t);try{e:if(typeof H=="function"){if(y=t.props,I=(f=H.contextType)&&r[f.__c],S=f?I?I.props.value:f.__:r,n.__c?A=(d=t.__c=n.__c).__=d.__E:("prototype"in H&&H.prototype.render?t.__c=d=new H(y,S):(t.__c=d=new dt(y,S),d.constructor=H,d.render=L0),I&&I.sub(d),d.props=y,d.state||(d.state={}),d.context=S,d.__n=r,h=d.__d=!0,d.__h=[],d._sb=[]),d.__s==null&&(d.__s=d.state),H.getDerivedStateFromProps!=null&&(d.__s==d.state&&(d.__s=At({},d.__s)),At(d.__s,H.getDerivedStateFromProps(y,d.__s))),p=d.props,m=d.state,d.__v=t,h)H.getDerivedStateFromProps==null&&d.componentWillMount!=null&&d.componentWillMount(),d.componentDidMount!=null&&d.__h.push(d.componentDidMount);else{if(H.getDerivedStateFromProps==null&&y!==p&&d.componentWillReceiveProps!=null&&d.componentWillReceiveProps(y,S),!d.__e&&(d.shouldComponentUpdate!=null&&d.shouldComponentUpdate(y,d.__s,S)===!1||t.__v===n.__v)){for(t.__v!==n.__v&&(d.props=y,d.state=d.__s,d.__d=!1),t.__e=n.__e,t.__k=n.__k,t.__k.forEach(function(C){C&&(C.__=t)}),D=0;D<d._sb.length;D++)d.__h.push(d._sb[D]);d._sb=[],d.__h.length&&s.push(d);break e}d.componentWillUpdate!=null&&d.componentWillUpdate(y,d.__s,S),d.componentDidUpdate!=null&&d.__h.push(function(){d.componentDidUpdate(p,m,_)})}if(d.context=S,d.props=y,d.__P=e,d.__e=!1,P=W.__r,w=0,"prototype"in H&&H.prototype.render){for(d.state=d.__s,d.__d=!1,P&&P(t),f=d.render(d.props,d.state,d.context),z=0;z<d._sb.length;z++)d.__h.push(d._sb[z]);d._sb=[]}else do d.__d=!1,P&&P(t),f=d.render(d.props,d.state,d.context),d.state=d.__s;while(d.__d&&++w<25);d.state=d.__s,d.getChildContext!=null&&(r=At(At({},r),d.getChildContext())),h||d.getSnapshotBeforeUpdate==null||(_=d.getSnapshotBeforeUpdate(p,m)),Ps(e,Er(L=f!=null&&f.type===Ue&&f.key==null?f.props.children:f)?L:[L],t,n,r,i,a,s,o,u,c),d.base=t.__e,t.__h=null,d.__h.length&&s.push(d),A&&(d.__E=d.__=null)}else a==null&&t.__v===n.__v?(t.__k=n.__k,t.__e=n.__e):t.__e=v0(n.__e,t,n,r,i,a,s,u,c);(f=W.diffed)&&f(t)}catch(C){t.__v=null,(u||a!=null)&&(t.__e=o,t.__h=!!u,a[a.indexOf(o)]=null),W.__e(C,t,n)}}function zs(e,t,n){for(var r=0;r<n.length;r++)Si(n[r],n[++r],n[++r]);W.__c&&W.__c(t,e),e.some(function(i){try{e=i.__h,i.__h=[],e.some(function(a){a.call(i)})}catch(a){W.__e(a,i.__v)}})}function v0(e,t,n,r,i,a,s,o,u){var c,f,d,h=n.props,p=t.props,m=t.type,_=0;if(m==="svg"&&(i=!0),a!=null){for(;_<a.length;_++)if((c=a[_])&&"setAttribute"in c==!!m&&(m?c.localName===m:c.nodeType===3)){e=c,a[_]=null;break}}if(e==null){if(m===null)return document.createTextNode(p);e=i?document.createElementNS("http://www.w3.org/2000/svg",m):document.createElement(m,p.is&&p),a=null,o=!1}if(m===null)h===p||o&&e.data===p||(e.data=p);else{if(a=a&&br.call(e.childNodes),f=(h=n.props||an).dangerouslySetInnerHTML,d=p.dangerouslySetInnerHTML,!o){if(a!=null)for(h={},_=0;_<e.attributes.length;_++)h[e.attributes[_].name]=e.attributes[_].value;(d||f)&&(d&&(f&&d.__html==f.__html||d.__html===e.innerHTML)||(e.innerHTML=d&&d.__html||""))}if(N0(e,p,h,i,o),d)t.__k=[];else if(Ps(e,Er(_=t.props.children)?_:[_],t,n,r,i&&m!=="foreignObject",a,s,a?a[0]:n.__k&&_r(n,0),o,u),a!=null)for(_=a.length;_--;)a[_]!=null&&Os(a[_]);o||("value"in p&&(_=p.value)!==void 0&&(_!==e.value||m==="progress"&&!_||m==="option"&&_!==h.value)&&yr(e,"value",_,h.value,!1),"checked"in p&&(_=p.checked)!==void 0&&_!==e.checked&&yr(e,"checked",_,h.checked,!1))}return e}function Si(e,t,n){try{typeof e=="function"?e(t):e.current=t}catch(r){W.__e(r,n)}}function $s(e,t,n){var r,i;if(W.unmount&&W.unmount(e),(r=e.ref)&&(r.current&&r.current!==e.__e||Si(r,null,t)),(r=e.__c)!=null){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(a){W.__e(a,t)}r.base=r.__P=null,e.__c=void 0}if(r=e.__k)for(i=0;i<r.length;i++)r[i]&&$s(r[i],t,n||typeof e.type!="function");n||e.__e==null||Os(e.__e),e.__=e.__e=e.__d=void 0}function L0(e,t,n){return this.constructor(e,n)}function Ys(e,t,n){var r,i,a,s;W.__&&W.__(e,t),i=(r=typeof n=="function")?null:n&&n.__k||t.__k,a=[],s=[],Ci(t,e=(!r&&n||t).__k=Ct(Ue,null,[e]),i||an,an,t.ownerSVGElement!==void 0,!r&&n?[n]:i?null:t.firstChild?br.call(t.childNodes):null,a,!r&&n?n:i?i.__e:t.firstChild,r,s),zs(a,e,s)}function Ii(e,t){var n={__c:t="__cC"+Ls++,__:e,Consumer:function(r,i){return r.children(i)},Provider:function(r){var i,a;return this.getChildContext||(i=[],(a={})[t]=this,this.getChildContext=function(){return a},this.shouldComponentUpdate=function(s){this.props.value!==s.value&&i.some(function(o){o.__e=!0,Ai(o)})},this.sub=function(s){i.push(s);var o=s.componentWillUnmount;s.componentWillUnmount=function(){i.splice(i.indexOf(s),1),o&&o.call(s)}}),r.children}};return n.Provider.__=n.Consumer.contextType=n}br=Rs.slice,W={__e:function(e,t,n,r){for(var i,a,s;t=t.__;)if((i=t.__c)&&!i.__)try{if((a=i.constructor)&&a.getDerivedStateFromError!=null&&(i.setState(a.getDerivedStateFromError(e)),s=i.__d),i.componentDidCatch!=null&&(i.componentDidCatch(e,r||{}),s=i.__d),s)return i.__E=i}catch(o){e=o}throw e}},Ss=0,Is=function(e){return e!=null&&e.constructor===void 0},dt.prototype.setState=function(e,t){var n;n=this.__s!=null&&this.__s!==this.state?this.__s:this.__s=At({},this.state),typeof e=="function"&&(e=e(At({},n),this.props)),e&&At(n,e),e!=null&&this.__v&&(t&&this._sb.push(t),Ai(this))},dt.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),Ai(this))},dt.prototype.render=Ue,$t=[],vs=typeof Promise=="function"?Promise.prototype.then.bind(Promise.resolve()):setTimeout,wi=function(e,t){return e.__v.__b-t.__v.__b},kr.__r=0,Ls=0;var Yt,Te,Ni,js,vn=0,Vs=[],wr=[],qs=W.__b,Ws=W.__r,Gs=W.diffed,Qs=W.__c,Ks=W.unmount;function Ln(e,t){W.__h&&W.__h(Te,e,vn||t),vn=0;var n=Te.__H||(Te.__H={__:[],__h:[]});return e>=n.__.length&&n.__.push({__V:wr}),n.__[e]}function le(e){return vn=1,R0(Js,e)}function R0(e,t,n){var r=Ln(Yt++,2);if(r.t=e,!r.__c&&(r.__=[n?n(t):Js(void 0,t),function(o){var u=r.__N?r.__N[0]:r.__[0],c=r.t(u,o);u!==c&&(r.__N=[c,r.__[1]],r.__c.setState({}))}],r.__c=Te,!Te.u)){var i=function(o,u,c){if(!r.__c.__H)return!0;var f=r.__c.__H.__.filter(function(h){return h.__c});if(f.every(function(h){return!h.__N}))return!a||a.call(this,o,u,c);var d=!1;return f.forEach(function(h){if(h.__N){var p=h.__[0];h.__=h.__N,h.__N=void 0,p!==h.__[0]&&(d=!0)}}),!(!d&&r.__c.props===o)&&(!a||a.call(this,o,u,c))};Te.u=!0;var a=Te.shouldComponentUpdate,s=Te.componentWillUpdate;Te.componentWillUpdate=function(o,u,c){if(this.__e){var f=a;a=void 0,i(o,u,c),a=f}s&&s.call(this,o,u,c)},Te.shouldComponentUpdate=i}return r.__N||r.__}function we(e,t){var n=Ln(Yt++,3);!W.__s&&Zs(n.__H,t)&&(n.__=e,n.i=t,Te.__H.__h.push(n))}function Le(e){return vn=5,Ie(function(){return{current:e}},[])}function Ie(e,t){var n=Ln(Yt++,7);return Zs(n.__H,t)?(n.__V=e(),n.i=t,n.__h=e,n.__V):n.__}function Pe(e,t){return vn=8,Ie(function(){return e},t)}function Ge(e){var t=Te.context[e.__c],n=Ln(Yt++,9);return n.c=e,t?(n.__==null&&(n.__=!0,t.sub(Te)),t.props.value):e.__}function O0(){var e=Ln(Yt++,11);if(!e.__){for(var t=Te.__v;t!==null&&!t.__m&&t.__!==null;)t=t.__;var n=t.__m||(t.__m=[0,0]);e.__="P"+n[0]+"-"+n[1]++}return e.__}function D0(){for(var e;e=Vs.shift();)if(e.__P&&e.__H)try{e.__H.__h.forEach(Ar),e.__H.__h.forEach(vi),e.__H.__h=[]}catch(t){e.__H.__h=[],W.__e(t,e.__v)}}W.__b=function(e){Te=null,qs&&qs(e)},W.__r=function(e){Ws&&Ws(e),Yt=0;var t=(Te=e.__c).__H;t&&(Ni===Te?(t.__h=[],Te.__h=[],t.__.forEach(function(n){n.__N&&(n.__=n.__N),n.__V=wr,n.__N=n.i=void 0})):(t.__h.forEach(Ar),t.__h.forEach(vi),t.__h=[],Yt=0)),Ni=Te},W.diffed=function(e){Gs&&Gs(e);var t=e.__c;t&&t.__H&&(t.__H.__h.length&&(Vs.push(t)!==1&&js===W.requestAnimationFrame||((js=W.requestAnimationFrame)||P0)(D0)),t.__H.__.forEach(function(n){n.i&&(n.__H=n.i),n.__V!==wr&&(n.__=n.__V),n.i=void 0,n.__V=wr})),Ni=Te=null},W.__c=function(e,t){t.some(function(n){try{n.__h.forEach(Ar),n.__h=n.__h.filter(function(r){return!r.__||vi(r)})}catch(r){t.some(function(i){i.__h&&(i.__h=[])}),t=[],W.__e(r,n.__v)}}),Qs&&Qs(e,t)},W.unmount=function(e){Ks&&Ks(e);var t,n=e.__c;n&&n.__H&&(n.__H.__.forEach(function(r){try{Ar(r)}catch(i){t=i}}),n.__H=void 0,t&&W.__e(t,n.__v))};var Xs=typeof requestAnimationFrame=="function";function P0(e){var t,n=function(){clearTimeout(r),Xs&&cancelAnimationFrame(t),setTimeout(e)},r=setTimeout(n,100);Xs&&(t=requestAnimationFrame(n))}function Ar(e){var t=Te,n=e.__c;typeof n=="function"&&(e.__c=void 0,n()),Te=t}function vi(e){var t=Te;e.__c=e.__(),Te=t}function Zs(e,t){return!e||e.length!==t.length||t.some(function(n,r){return n!==e[r]})}function Js(e,t){return typeof t=="function"?t(e):t}var M0=Symbol.for("preact-signals");function Li(){if(sn>1)sn--;else{for(var e,t=!1;Rn!==void 0;){var n=Rn;for(Rn=void 0,Ri++;n!==void 0;){var r=n.o;if(n.o=void 0,n.f&=-3,!(8&n.f)&&to(n))try{n.c()}catch(i){t||(e=i,t=!0)}n=r}}if(Ri=0,sn--,t)throw e}}var he=void 0,Rn=void 0,sn=0,Ri=0,Cr=0;function eo(e){if(he!==void 0){var t=e.n;if(t===void 0||t.t!==he)return t={i:0,S:e,p:he.s,n:void 0,t:he,e:void 0,x:void 0,r:t},he.s!==void 0&&(he.s.n=t),he.s=t,e.n=t,32&he.f&&e.S(t),t;if(t.i===-1)return t.i=0,t.n!==void 0&&(t.n.p=t.p,t.p!==void 0&&(t.p.n=t.n),t.p=he.s,t.n=void 0,he.s.n=t,he.s=t),t}}function Re(e){this.v=e,this.i=0,this.n=void 0,this.t=void 0}Re.prototype.brand=M0,Re.prototype.h=function(){return!0},Re.prototype.S=function(e){this.t!==e&&e.e===void 0&&(e.x=this.t,this.t!==void 0&&(this.t.e=e),this.t=e)},Re.prototype.U=function(e){if(this.t!==void 0){var t=e.e,n=e.x;t!==void 0&&(t.x=n,e.e=void 0),n!==void 0&&(n.e=t,e.x=void 0),e===this.t&&(this.t=n)}},Re.prototype.subscribe=function(e){var t=this;return Dn(function(){var n=t.value,r=he;he=void 0;try{e(n)}finally{he=r}})},Re.prototype.valueOf=function(){return this.value},Re.prototype.toString=function(){return this.value+""},Re.prototype.toJSON=function(){return this.value},Re.prototype.peek=function(){var e=he;he=void 0;try{return this.value}finally{he=e}},Object.defineProperty(Re.prototype,"value",{get:function(){var e=eo(this);return e!==void 0&&(e.i=this.i),this.v},set:function(e){if(e!==this.v){if(Ri>100)throw new Error("Cycle detected");this.v=e,this.i++,Cr++,sn++;try{for(var t=this.t;t!==void 0;t=t.x)t.t.N()}finally{Li()}}}});function st(e){return new Re(e)}function to(e){for(var t=e.s;t!==void 0;t=t.n)if(t.S.i!==t.i||!t.S.h()||t.S.i!==t.i)return!0;return!1}function no(e){for(var t=e.s;t!==void 0;t=t.n){var n=t.S.n;if(n!==void 0&&(t.r=n),t.S.n=t,t.i=-1,t.n===void 0){e.s=t;break}}}function ro(e){for(var t=e.s,n=void 0;t!==void 0;){var r=t.p;t.i===-1?(t.S.U(t),r!==void 0&&(r.n=t.n),t.n!==void 0&&(t.n.p=r)):n=t,t.S.n=t.r,t.r!==void 0&&(t.r=void 0),t=r}e.s=n}function on(e){Re.call(this,void 0),this.x=e,this.s=void 0,this.g=Cr-1,this.f=4}(on.prototype=new Re).h=function(){if(this.f&=-3,1&this.f)return!1;if((36&this.f)==32||(this.f&=-5,this.g===Cr))return!0;if(this.g=Cr,this.f|=1,this.i>0&&!to(this))return this.f&=-2,!0;var e=he;try{no(this),he=this;var t=this.x();(16&this.f||this.v!==t||this.i===0)&&(this.v=t,this.f&=-17,this.i++)}catch(n){this.v=n,this.f|=16,this.i++}return he=e,ro(this),this.f&=-2,!0},on.prototype.S=function(e){if(this.t===void 0){this.f|=36;for(var t=this.s;t!==void 0;t=t.n)t.S.S(t)}Re.prototype.S.call(this,e)},on.prototype.U=function(e){if(this.t!==void 0&&(Re.prototype.U.call(this,e),this.t===void 0)){this.f&=-33;for(var t=this.s;t!==void 0;t=t.n)t.S.U(t)}},on.prototype.N=function(){if(!(2&this.f)){this.f|=6;for(var e=this.t;e!==void 0;e=e.x)e.t.N()}},Object.defineProperty(on.prototype,"value",{get:function(){if(1&this.f)throw new Error("Cycle detected");var e=eo(this);if(this.h(),e!==void 0&&(e.i=this.i),16&this.f)throw this.v;return this.v}});function io(e){return new on(e)}function ao(e){var t=e.u;if(e.u=void 0,typeof t=="function"){sn++;var n=he;he=void 0;try{t()}catch(r){throw e.f&=-2,e.f|=8,Oi(e),r}finally{he=n,Li()}}}function Oi(e){for(var t=e.s;t!==void 0;t=t.n)t.S.U(t);e.x=void 0,e.s=void 0,ao(e)}function B0(e){if(he!==this)throw new Error("Out-of-order effect");ro(this),he=e,this.f&=-2,8&this.f&&Oi(this),Li()}function On(e){this.x=e,this.u=void 0,this.s=void 0,this.o=void 0,this.f=32}On.prototype.c=function(){var e=this.S();try{if(8&this.f||this.x===void 0)return;var t=this.x();typeof t=="function"&&(this.u=t)}finally{e()}},On.prototype.S=function(){if(1&this.f)throw new Error("Cycle detected");this.f|=1,this.f&=-9,ao(this),no(this),sn++;var e=he;return he=this,B0.bind(this,e)},On.prototype.N=function(){2&this.f||(this.f|=2,this.o=Rn,Rn=this)},On.prototype.d=function(){this.f|=8,1&this.f||Oi(this)};function Dn(e){var t=new On(e);try{t.c()}catch(n){throw t.d(),n}return t.d.bind(t)}var Sr,Di;function un(e,t){W[e]=t.bind(null,W[e]||function(){})}function Ir(e){Di&&Di(),Di=e&&e.S()}function so(e){var t=this,n=e.data,r=H0(n);r.value=n;var i=Ie(function(){for(var a=t.__v;a=a.__;)if(a.__c){a.__c.__$f|=4;break}return t.__$u.c=function(){var s;!Is(i.peek())&&((s=t.base)==null?void 0:s.nodeType)===3?t.base.data=i.peek():(t.__$f|=1,t.setState({}))},io(function(){var s=r.value.value;return s===0?0:s===!0?"":s||""})},[]);return i.value}so.displayName="_st",Object.defineProperties(Re.prototype,{constructor:{configurable:!0,value:void 0},type:{configurable:!0,value:so},props:{configurable:!0,get:function(){return{data:this}}},__b:{configurable:!0,value:1}}),un("__b",function(e,t){if(typeof t.type=="string"){var n,r=t.props;for(var i in r)if(i!=="children"){var a=r[i];a instanceof Re&&(n||(t.__np=n={}),n[i]=a,r[i]=a.peek())}}e(t)}),un("__r",function(e,t){Ir();var n,r=t.__c;r&&(r.__$f&=-2,(n=r.__$u)===void 0&&(r.__$u=n=function(i){var a;return Dn(function(){a=this}),a.c=function(){r.__$f|=1,r.setState({})},a}())),Sr=r,Ir(n),e(t)}),un("__e",function(e,t,n,r){Ir(),Sr=void 0,e(t,n,r)}),un("diffed",function(e,t){Ir(),Sr=void 0;var n;if(typeof t.type=="string"&&(n=t.__e)){var r=t.__np,i=t.props;if(r){var a=n.U;if(a)for(var s in a){var o=a[s];o!==void 0&&!(s in r)&&(o.d(),a[s]=void 0)}else n.U=a={};for(var u in r){var c=a[u],f=r[u];c===void 0?(c=F0(n,u,f,i),a[u]=c):c.o(f,i)}}}e(t)});function F0(e,t,n,r){var i=t in e&&e.ownerSVGElement===void 0,a=st(n);return{o:function(s,o){a.value=s,r=o},d:Dn(function(){var s=a.value.value;r[t]!==s&&(r[t]=s,i?e[t]=s:s?e.setAttribute(t,s):e.removeAttribute(t))})}}un("unmount",function(e,t){if(typeof t.type=="string"){var n=t.__e;if(n){var r=n.U;if(r){n.U=void 0;for(var i in r){var a=r[i];a&&a.d()}}}}else{var s=t.__c;if(s){var o=s.__$u;o&&(s.__$u=void 0,o.d())}}e(t)}),un("__h",function(e,t,n,r){(r<3||r===9)&&(t.__$f|=2),e(t,n,r)}),dt.prototype.shouldComponentUpdate=function(e,t){var n=this.__$u;if(!(n&&n.s!==void 0||4&this.__$f)||3&this.__$f)return!0;for(var r in t)return!0;for(var i in e)if(i!=="__source"&&e[i]!==this.props[i])return!0;for(var a in this.props)if(!(a in e))return!0;return!1};function H0(e){return Ie(function(){return st(e)},[])}function Pi(e){var t=Le(e);return t.current=e,Sr.__$f|=4,Ie(function(){return io(function(){return t.current()})},[])}function oo(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(n=oo(e[t]))&&(r&&(r+=" "),r+=n);else for(t in e)e[t]&&(r&&(r+=" "),r+=t);return r}function Mi(){for(var e,t,n=0,r="";n<arguments.length;)(e=arguments[n++])&&(t=oo(e))&&(r&&(r+=" "),r+=t);return r}const uo=e=>typeof e=="boolean"?"".concat(e):e===0?"0":e,U0=e=>{const t=function(){for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];var o,u;return typeof(e==null||(o=e.hooks)===null||o===void 0?void 0:o["cx:done"])<"u"?e?.hooks["cx:done"](Mi(a)):typeof(e==null||(u=e.hooks)===null||u===void 0?void 0:u.onComplete)<"u"?e?.hooks.onComplete(Mi(a)):Mi(a)};return{compose:function(){for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return o=>{const u=Object.fromEntries(Object.entries(o||{}).filter(c=>{let[f]=c;return!["class","className"].includes(f)}));return t(a.map(c=>c(u)),o?.class,o?.className)}},cva:i=>a=>{var s;if(i?.variants==null)return t(i?.base,a?.class,a?.className);const{variants:o,defaultVariants:u}=i,c=Object.keys(o).map(h=>{const p=a?.[h],m=u?.[h],_=uo(p)||uo(m);return o[h][_]}),f={...u,...a&&Object.entries(a).reduce((h,p)=>{let[m,_]=p;return typeof _>"u"?h:{...h,[m]:_}},{})},d=i==null||(s=i.compoundVariants)===null||s===void 0?void 0:s.reduce((h,p)=>{let{class:m,className:_,...A}=p;return Object.entries(A).every(y=>{let[I,S]=y;const D=f[I];return Array.isArray(S)?S.includes(D):D===S})?[...h,m,_]:h},[]);return t(i?.base,c,d,a?.class,a?.className)},cx:t}},{compose:T6,cva:St,cx:_6}=U0(),z0=st(!1),$0=st(!1),Y0=st("idle"),Bi=st(!1),Fi=st("idle"),Hi=st(null),Ui=st(null),ft=st([]),zi=st([]),$i=typeof BroadcastChannel<"u"?new BroadcastChannel("kin-sync"):null;$i?.addEventListener("message",e=>{const{type:t,data:n}=e.data;switch(t){case"messages_updated":ft.value=n.messages.map(r=>({...r,timestamp:new Date(r.timestamp)}));break;case"messages_cleared":ft.value=[];break}});const Yi=()=>{$i?.postMessage({type:"messages_updated",data:{messages:ft.value}})},Y={isOpen:z0,isStreaming:$0,connectionState:Y0,messages:ft,quickReplies:zi,uploadState:Fi,uploadError:Hi,uploadFileName:Ui,hasUnreadMessages:Bi,addMessage:e=>{ft.value=[...ft.value,{...e,id:crypto.randomUUID(),timestamp:new Date}],zi.value=[],Yi()},appendToLastMessage:e=>{const t=ft.value;if(t.length===0)return;const n=t[t.length-1];!n||n.role!=="assistant"||(ft.value=[...t.slice(0,-1),{...n,content:n.content+e}])},clearMessages:()=>{ft.value=[],$i?.postMessage({type:"messages_cleared"})},setMessages:e=>{ft.value=e.map(t=>({...t,id:crypto.randomUUID(),timestamp:new Date})),Yi()},syncToOtherTabs:()=>{Yi()},setUploadState:(e,t,n)=>{Fi.value=e,Ui.value=t??null,Hi.value=n??null},resetUploadState:()=>{Fi.value="idle",Ui.value=null,Hi.value=null},setHasUnreadMessages:e=>{Bi.value=e},clearUnreadMessages:()=>{Bi.value=!1},setQuickReplies:e=>{zi.value=e}};var j0=0;function b(e,t,n,r,i,a){var s,o,u={};for(o in t)o=="ref"?s=t[o]:u[o]=t[o];var c={type:e,props:u,key:n,ref:s,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,__h:null,constructor:void 0,__v:--j0,__source:i,__self:a};if(typeof e=="function"&&(s=e.defaultProps))for(o in s)u[o]===void 0&&(u[o]=s[o]);return W.vnode&&W.vnode(c),c}function V0({class:e,"aria-hidden":t="true"}){return b("svg",{class:e,viewBox:"0 0 870 400",fill:"currentColor","aria-hidden":t,focusable:"false",children:b("path",{d:"M220.468 331.21c-21.275-9.559-42.081-30.347-79.541-67.777l-56.1-56.087c-9.106-9.106-14.522-14.541-18.414-18.802-2.471-2.705-3.42-3.973-3.645-4.286a20.3 20.3 0 0 1 0-20.058c.224-.314 1.173-1.582 3.644-4.286 3.893-4.261 9.309-9.697 18.414-18.803 43.366-43.365 57.154-56.438 69.786-63.775 39.522-22.958 88.319-22.958 127.842-.001 12.632 7.337 26.42 20.41 69.786 63.774l30.412 30.411 42.51-42.509-30.413-30.412c-40.657-40.656-60.986-60.984-82.1-73.248-58.192-33.802-130.041-33.801-188.233.001-21.114 12.265-41.442 32.593-82.099 73.25-17.449 17.449-26.174 26.173-31.437 35.235a80.417 80.417 0 0 0 0 80.785c5.264 9.061 13.99 17.785 31.438 35.234l69.155 69.152c30.203 30.202 45.305 45.303 62.973 56.034a171.768 171.768 0 0 0 48.416 20.055C242.943 400.001 264.3 400 307.013 400H608.43c42.714 0 64.071-.001 84.153-4.906A171.733 171.733 0 0 0 741 375.039c17.668-10.731 32.77-25.833 62.973-56.037l13.213-13.213c160.161-160.161-80.08-400.402-240.241-240.24L379.079 263.39c-42.114 42.109-63.171 63.164-87.526 70.869a104.629 104.629 0 0 1-59.446 1.086 111.797 111.797 0 0 1-11.639-4.136Z"})})}function q0({class:e,"aria-hidden":t="true"}){return b("svg",{class:e,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.5","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":t,focusable:"false",children:[b("path",{d:"M12 19V5"}),b("path",{d:"M5 12l7-7 7 7"})]})}function W0({class:e,"aria-hidden":t="true"}){return b("svg",{class:e,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":t,focusable:"false",children:[b("path",{d:"M18 6L6 18"}),b("path",{d:"M6 6l12 12"})]})}function G0({class:e,"aria-hidden":t="true"}){return b("svg",{class:e,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":t,focusable:"false",children:[b("path",{d:"M3 6h18"}),b("path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"}),b("path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"})]})}function Q0({class:e,"aria-hidden":t="true"}){return b("svg",{class:e,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":t,focusable:"false",children:b("path",{d:"M21.44 11.05l-9.19 9.19a6 6 0 01-8.49-8.49l9.19-9.19a4 4 0 015.66 5.66l-9.2 9.19a2 2 0 01-2.83-2.83l8.49-8.48"})})}function K0({class:e,"aria-hidden":t="true"}){return b("svg",{class:e,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":t,focusable:"false",children:b("path",{d:"M21 12a9 9 0 11-6.219-8.56"})})}function X0(e,t){for(var n in t)e[n]=t[n];return e}function ji(e,t){for(var n in e)if(n!=="__source"&&!(n in t))return!0;for(var r in t)if(r!=="__source"&&e[r]!==t[r])return!0;return!1}function lo(e){this.props=e}function de(e,t){function n(i){var a=this.props.ref,s=a==i.ref;return!s&&a&&(a.call?a(null):a.current=null),t?!t(this.props,i)||!s:ji(this.props,i)}function r(i){return this.shouldComponentUpdate=n,Ct(e,i)}return r.displayName="Memo("+(e.displayName||e.name)+")",r.prototype.isReactComponent=!0,r.__f=!0,r}(lo.prototype=new dt).isPureReactComponent=!0,lo.prototype.shouldComponentUpdate=function(e,t){return ji(this.props,e)||ji(this.state,t)};var co=W.__b;W.__b=function(e){e.type&&e.type.__f&&e.ref&&(e.props.ref=e.ref,e.ref=null),co&&co(e)};var Z0=W.__e;W.__e=function(e,t,n,r){if(e.then){for(var i,a=t;a=a.__;)if((i=a.__c)&&i.__c)return t.__e==null&&(t.__e=n.__e,t.__k=n.__k),i.__c(e,t)}Z0(e,t,n,r)};var fo=W.unmount;function ho(e,t,n){return e&&(e.__c&&e.__c.__H&&(e.__c.__H.__.forEach(function(r){typeof r.__c=="function"&&r.__c()}),e.__c.__H=null),(e=X0({},e)).__c!=null&&(e.__c.__P===n&&(e.__c.__P=t),e.__c=null),e.__k=e.__k&&e.__k.map(function(r){return ho(r,t,n)})),e}function po(e,t,n){return e&&(e.__v=null,e.__k=e.__k&&e.__k.map(function(r){return po(r,t,n)}),e.__c&&e.__c.__P===t&&(e.__e&&n.insertBefore(e.__e,e.__d),e.__c.__e=!0,e.__c.__P=n)),e}function Pn(){this.__u=0,this.t=null,this.__b=null}function mo(e){var t=e.__.__c;return t&&t.__a&&t.__a(e)}function go(e){var t,n,r;function i(a){if(t||(t=e()).then(function(s){n=s.default||s},function(s){r=s}),r)throw r;if(!n)throw t;return Ct(n,a)}return i.displayName="Lazy",i.__f=!0,i}function Nr(){this.u=null,this.o=null}W.unmount=function(e){var t=e.__c;t&&t.__R&&t.__R(),t&&e.__h===!0&&(e.type=null),fo&&fo(e)},(Pn.prototype=new dt).__c=function(e,t){var n=t.__c,r=this;r.t==null&&(r.t=[]),r.t.push(n);var i=mo(r.__v),a=!1,s=function(){a||(a=!0,n.__R=null,i?i(o):o())};n.__R=s;var o=function(){if(!--r.__u){if(r.state.__a){var c=r.state.__a;r.__v.__k[0]=po(c,c.__c.__P,c.__c.__O)}var f;for(r.setState({__a:r.__b=null});f=r.t.pop();)f.forceUpdate()}},u=t.__h===!0;r.__u++||u||r.setState({__a:r.__b=r.__v.__k[0]}),e.then(s,s)},Pn.prototype.componentWillUnmount=function(){this.t=[]},Pn.prototype.render=function(e,t){if(this.__b){if(this.__v.__k){var n=document.createElement("div"),r=this.__v.__k[0].__c;this.__v.__k[0]=ho(this.__b,n,r.__O=r.__P)}this.__b=null}var i=t.__a&&Ct(Ue,null,e.fallback);return i&&(i.__h=null),[Ct(Ue,null,t.__a?null:e.children),i]};var bo=function(e,t,n){if(++n[1]===n[0]&&e.o.delete(t),e.props.revealOrder&&(e.props.revealOrder[0]!=="t"||!e.o.size))for(n=e.u;n;){for(;n.length>3;)n.pop()();if(n[1]<n[0])break;e.u=n=n[2]}};(Nr.prototype=new dt).__a=function(e){var t=this,n=mo(t.__v),r=t.o.get(e);return r[0]++,function(i){var a=function(){t.props.revealOrder?(r.push(i),bo(t,e,r)):i()};n?n(a):a()}},Nr.prototype.render=function(e){this.u=null,this.o=new Map;var t=xr(e.children);e.revealOrder&&e.revealOrder[0]==="b"&&t.reverse();for(var n=t.length;n--;)this.o.set(t[n],this.u=[1,0,this.u]);return e.children},Nr.prototype.componentDidUpdate=Nr.prototype.componentDidMount=function(){var e=this;this.o.forEach(function(t,n){bo(e,n,t)})};var Eo=typeof Symbol<"u"&&Symbol.for&&Symbol.for("react.element")||60103,J0=/^(?:accent|alignment|arabic|baseline|cap|clip(?!PathU)|color|dominant|fill|flood|font|glyph(?!R)|horiz|image(!S)|letter|lighting|marker(?!H|W|U)|overline|paint|pointer|shape|stop|strikethrough|stroke|text(?!L)|transform|underline|unicode|units|v|vector|vert|word|writing|x(?!C))[A-Z]/,ef=/^on(Ani|Tra|Tou|BeforeInp|Compo)/,tf=/[A-Z0-9]/g,nf=typeof document<"u",rf=function(e){return(typeof Symbol<"u"&&typeof Symbol()=="symbol"?/fil|che|rad/:/fil|che|ra/).test(e)};dt.prototype.isReactComponent={},["componentWillMount","componentWillReceiveProps","componentWillUpdate"].forEach(function(e){Object.defineProperty(dt.prototype,e,{configurable:!0,get:function(){return this["UNSAFE_"+e]},set:function(t){Object.defineProperty(this,e,{configurable:!0,writable:!0,value:t})}})});var To=W.event;function af(){}function sf(){return this.cancelBubble}function of(){return this.defaultPrevented}W.event=function(e){return To&&(e=To(e)),e.persist=af,e.isPropagationStopped=sf,e.isDefaultPrevented=of,e.nativeEvent=e};var uf={enumerable:!1,configurable:!0,get:function(){return this.class}},_o=W.vnode;W.vnode=function(e){typeof e.type=="string"&&function(t){var n=t.props,r=t.type,i={};for(var a in n){var s=n[a];if(!(a==="value"&&"defaultValue"in n&&s==null||nf&&a==="children"&&r==="noscript"||a==="class"||a==="className")){var o=a.toLowerCase();a==="defaultValue"&&"value"in n&&n.value==null?a="value":a==="download"&&s===!0?s="":o==="ondoubleclick"?a="ondblclick":o!=="onchange"||r!=="input"&&r!=="textarea"||rf(n.type)?o==="onfocus"?a="onfocusin":o==="onblur"?a="onfocusout":ef.test(a)?a=o:r.indexOf("-")===-1&&J0.test(a)?a=a.replace(tf,"-$&").toLowerCase():s===null&&(s=void 0):o=a="oninput",o==="oninput"&&i[a=o]&&(a="oninputCapture"),i[a]=s}}r=="select"&&i.multiple&&Array.isArray(i.value)&&(i.value=xr(n.children).forEach(function(u){u.props.selected=i.value.indexOf(u.props.value)!=-1})),r=="select"&&i.defaultValue!=null&&(i.value=xr(n.children).forEach(function(u){u.props.selected=i.multiple?i.defaultValue.indexOf(u.props.value)!=-1:i.defaultValue==u.props.value})),n.class&&!n.className?(i.class=n.class,Object.defineProperty(i,"className",uf)):(n.className&&!n.class||n.class&&n.className)&&(i.class=i.className=n.className),t.props=i}(e),e.$$typeof=Eo,_o&&_o(e)};var ko=W.__r;W.__r=function(e){ko&&ko(e)};var xo=W.diffed;W.diffed=function(e){xo&&xo(e);var t=e.props,n=e.__e;n!=null&&e.type==="textarea"&&"value"in t&&t.value!==n.value&&(n.value=t.value==null?"":t.value)};function ln(e){return!!e&&e.$$typeof===Eo}function lf(e){e()}function cf(){return[!1,lf]}const vr=function(e){if(e==null)return pf;if(typeof e=="function")return Lr(e);if(typeof e=="object")return Array.isArray(e)?df(e):ff(e);if(typeof e=="string")return hf(e);throw new Error("Expected function, string, or object as test")};function df(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=vr(e[n]);return Lr(r);function r(...i){let a=-1;for(;++a<t.length;)if(t[a].apply(this,i))return!0;return!1}}function ff(e){const t=e;return Lr(n);function n(r){const i=r;let a;for(a in e)if(i[a]!==t[a])return!1;return!0}}function hf(e){return Lr(t);function t(n){return n&&n.type===e}}function Lr(e){return t;function t(n,r,i){return!!(mf(n)&&e.call(this,n,typeof r=="number"?r:void 0,i||void 0))}}function pf(){return!0}function mf(e){return e!==null&&typeof e=="object"&&"type"in e}function L6(e){return e}const yo=[],Mn=!0,Vi=!1,qi="skip";function wo(e,t,n,r){let i;typeof t=="function"&&typeof n!="function"?(r=n,n=t):i=t;const a=vr(i),s=r?-1:1;o(e,void 0,[])();function o(u,c,f){const d=u&&typeof u=="object"?u:{};if(typeof d.type=="string"){const p=typeof d.tagName=="string"?d.tagName:typeof d.name=="string"?d.name:void 0;Object.defineProperty(h,"name",{value:"node ("+(u.type+(p?"<"+p+">":""))+")"})}return h;function h(){let p=yo,m,_,A;if((!t||a(u,c,f[f.length-1]||void 0))&&(p=gf(n(u,f)),p[0]===Vi))return p;if("children"in u&&u.children){const y=u;if(y.children&&p[0]!==qi)for(_=(r?y.children.length:-1)+s,A=f.concat(y);_>-1&&_<y.children.length;){const I=y.children[_];if(m=o(I,_,A)(),m[0]===Vi)return m;_=typeof m[1]=="number"?m[1]:_+s}}return p}}}function gf(e){return Array.isArray(e)?e:typeof e=="number"?[Mn,e]:e==null?yo:[e]}function cn(e,t,n,r){let i,a,s;typeof t=="function"&&typeof n!="function"?(a=void 0,s=t,i=n):(a=t,s=n,i=r),wo(e,a,o,i);function o(u,c){const f=c[c.length-1],d=f?f.children.indexOf(u):void 0;return s(u,d,f)}}function bf({defaultOrigin:e="",allowedLinkPrefixes:t=[],allowedImagePrefixes:n=[],allowDataImages:r=!1,allowedProtocols:i=[],blockedImageClass:a="inline-block bg-gray-200 dark:bg-gray-700 text-gray-600 dark:text-gray-400 px-3 py-1 rounded text-sm",blockedLinkClass:s="text-gray-500"}){const o=t.length&&!t.every(c=>c==="*"),u=n.length&&!n.every(c=>c==="*");if(!e&&(o||u))throw new Error("defaultOrigin is required when allowedLinkPrefixes or allowedImagePrefixes are provided");return c=>{const f=kf(e,t,n,r,i,a,s);cn(c,f)}}function Ao(e,t){if(typeof e!="string")return null;try{return new URL(e)}catch{if(t)try{return new URL(e,t)}catch{return null}if(e.startsWith("/")||e.startsWith("./")||e.startsWith("../"))try{return new URL(e,"http://example.com")}catch{return null}return null}}function Ef(e){return typeof e!="string"?!1:e.startsWith("/")||e.startsWith("./")||e.startsWith("../")}const Tf=new Set(["https:","http:","irc:","ircs:","mailto:","xmpp:","blob:"]),_f=new Set(["javascript:","data:","file:","vbscript:"]);function Co(e,t,n,r=!1,i=!1,a=[]){if(!e)return null;if(typeof e=="string"&&e.startsWith("#")&&!i)try{if(new URL(e,"http://example.com").hash===e)return e}catch{}if(typeof e=="string"&&e.startsWith("data:"))return i&&r&&e.startsWith("data:image/")?e:null;if(typeof e=="string"&&e.startsWith("blob:")){try{if(new URL(e).protocol==="blob:"&&e.length>5){const f=e.substring(5);if(f&&f.length>0&&f!=="invalid")return e}}catch{return null}return null}const s=Ao(e,n);if(!s||_f.has(s.protocol)||!(Tf.has(s.protocol)||a.includes(s.protocol)||a.includes("*")))return null;if(s.protocol==="mailto:"||!s.protocol.match(/^https?:$/))return s.href;const u=Ef(e);return s&&t.some(c=>{const f=Ao(c,n);return!f||f.origin!==s.origin?!1:s.href.startsWith(f.href)})?u?s.pathname+s.search+s.hash:s.href:t.includes("*")?s.protocol!=="https:"&&s.protocol!=="http:"?null:u?s.pathname+s.search+s.hash:s.href:null}const Wi=Symbol("node-seen"),kf=(e,t,n,r,i,a,s)=>{const o=(u,c,f)=>{if(u.type!=="element"||u[Wi])return Mn;if(u.tagName==="a"){const d=Co(u.properties.href,t,e,!1,!1,i);return d===null?(u[Wi]=!0,cn(u,o),f&&typeof c=="number"&&(f.children[c]={type:"element",tagName:"span",properties:{title:"Blocked URL: "+String(u.properties.href),class:s},children:[...u.children,{type:"text",value:" [blocked]"}]}),qi):(u.properties.href=d,u.properties.target="_blank",u.properties.rel="noopener noreferrer",Mn)}if(u.tagName==="img"){const d=Co(u.properties.src,n,e,r,!0,i);return d===null?(u[Wi]=!0,cn(u,o),f&&typeof c=="number"&&(f.children[c]={type:"element",tagName:"span",properties:{class:a},children:[{type:"text",value:"[Image blocked: "+String(u.properties.alt||"No description")+"]"}]}),qi):(u.properties.src=d,Mn)}return Mn};return o},So=-1,Rr=0,Or=1,Dr=2,Gi=3,Qi=4,Ki=5,Xi=6,Io=7,No=8,vo=typeof self=="object"?self:globalThis,xf=(e,t)=>{const n=(i,a)=>(e.set(a,i),i),r=i=>{if(e.has(i))return e.get(i);const[a,s]=t[i];switch(a){case Rr:case So:return n(s,i);case Or:{const o=n([],i);for(const u of s)o.push(r(u));return o}case Dr:{const o=n({},i);for(const[u,c]of s)o[r(u)]=r(c);return o}case Gi:return n(new Date(s),i);case Qi:{const{source:o,flags:u}=s;return n(new RegExp(o,u),i)}case Ki:{const o=n(new Map,i);for(const[u,c]of s)o.set(r(u),r(c));return o}case Xi:{const o=n(new Set,i);for(const u of s)o.add(r(u));return o}case Io:{const{name:o,message:u}=s;return n(new vo[o](u),i)}case No:return n(BigInt(s),i);case"BigInt":return n(Object(BigInt(s)),i)}return n(new vo[a](s),i)};return r},Lo=e=>xf(new Map,e)(0),dn="",{toString:yf}={},{keys:wf}=Object,Bn=e=>{const t=typeof e;if(t!=="object"||!e)return[Rr,t];const n=yf.call(e).slice(8,-1);switch(n){case"Array":return[Or,dn];case"Object":return[Dr,dn];case"Date":return[Gi,dn];case"RegExp":return[Qi,dn];case"Map":return[Ki,dn];case"Set":return[Xi,dn]}return n.includes("Array")?[Or,n]:n.includes("Error")?[Io,n]:[Dr,n]},Pr=([e,t])=>e===Rr&&(t==="function"||t==="symbol"),Af=(e,t,n,r)=>{const i=(s,o)=>{const u=r.push(s)-1;return n.set(o,u),u},a=s=>{if(n.has(s))return n.get(s);let[o,u]=Bn(s);switch(o){case Rr:{let f=s;switch(u){case"bigint":o=No,f=s.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+u);f=null;break;case"undefined":return i([So],s)}return i([o,f],s)}case Or:{if(u)return i([u,[...s]],s);const f=[],d=i([o,f],s);for(const h of s)f.push(a(h));return d}case Dr:{if(u)switch(u){case"BigInt":return i([u,s.toString()],s);case"Boolean":case"Number":case"String":return i([u,s.valueOf()],s)}if(t&&"toJSON"in s)return a(s.toJSON());const f=[],d=i([o,f],s);for(const h of wf(s))(e||!Pr(Bn(s[h])))&&f.push([a(h),a(s[h])]);return d}case Gi:return i([o,s.toISOString()],s);case Qi:{const{source:f,flags:d}=s;return i([o,{source:f,flags:d}],s)}case Ki:{const f=[],d=i([o,f],s);for(const[h,p]of s)(e||!(Pr(Bn(h))||Pr(Bn(p))))&&f.push([a(h),a(p)]);return d}case Xi:{const f=[],d=i([o,f],s);for(const h of s)(e||!Pr(Bn(h)))&&f.push(a(h));return d}}const{message:c}=s;return i([o,{name:u,message:c}],s)};return a},Ro=(e,{json:t,lossy:n}={})=>{const r=[];return Af(!(t||n),!!t,new Map,r)(e),r},jt=typeof structuredClone=="function"?(e,t)=>t&&("json"in t||"lossy"in t)?Lo(Ro(e,t)):structuredClone(e):(e,t)=>Lo(Ro(e,t));class Fn{constructor(t,n,r){this.normal=n,this.property=t,r&&(this.space=r)}}Fn.prototype.normal={},Fn.prototype.property={},Fn.prototype.space=void 0;function Oo(e,t){const n={},r={};for(const i of e)Object.assign(n,i.property),Object.assign(r,i.normal);return new Fn(n,r,t)}function Hn(e){return e.toLowerCase()}class Ve{constructor(t,n){this.attribute=n,this.property=t}}Ve.prototype.attribute="",Ve.prototype.booleanish=!1,Ve.prototype.boolean=!1,Ve.prototype.commaOrSpaceSeparated=!1,Ve.prototype.commaSeparated=!1,Ve.prototype.defined=!1,Ve.prototype.mustUseProperty=!1,Ve.prototype.number=!1,Ve.prototype.overloadedBoolean=!1,Ve.prototype.property="",Ve.prototype.spaceSeparated=!1,Ve.prototype.space=void 0;let Cf=0;const te=Vt(),Ce=Vt(),Zi=Vt(),F=Vt(),be=Vt(),fn=Vt(),Qe=Vt();function Vt(){return 2**++Cf}const Ji=Object.freeze(Object.defineProperty({__proto__:null,boolean:te,booleanish:Ce,commaOrSpaceSeparated:Qe,commaSeparated:fn,number:F,overloadedBoolean:Zi,spaceSeparated:be},Symbol.toStringTag,{value:"Module"})),ea=Object.keys(Ji);class ta extends Ve{constructor(t,n,r,i){let a=-1;if(super(t,n),Do(this,"space",i),typeof r=="number")for(;++a<ea.length;){const s=ea[a];Do(this,ea[a],(r&Ji[s])===Ji[s])}}}ta.prototype.defined=!0;function Do(e,t,n){n&&(e[t]=n)}function hn(e){const t={},n={};for(const[r,i]of Object.entries(e.properties)){const a=new ta(r,e.transform(e.attributes||{},r),i,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[Hn(r)]=r,n[Hn(a.attribute)]=r}return new Fn(t,n,e.space)}const Po=hn({properties:{ariaActiveDescendant:null,ariaAtomic:Ce,ariaAutoComplete:null,ariaBusy:Ce,ariaChecked:Ce,ariaColCount:F,ariaColIndex:F,ariaColSpan:F,ariaControls:be,ariaCurrent:null,ariaDescribedBy:be,ariaDetails:null,ariaDisabled:Ce,ariaDropEffect:be,ariaErrorMessage:null,ariaExpanded:Ce,ariaFlowTo:be,ariaGrabbed:Ce,ariaHasPopup:null,ariaHidden:Ce,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:be,ariaLevel:F,ariaLive:null,ariaModal:Ce,ariaMultiLine:Ce,ariaMultiSelectable:Ce,ariaOrientation:null,ariaOwns:be,ariaPlaceholder:null,ariaPosInSet:F,ariaPressed:Ce,ariaReadOnly:Ce,ariaRelevant:null,ariaRequired:Ce,ariaRoleDescription:be,ariaRowCount:F,ariaRowIndex:F,ariaRowSpan:F,ariaSelected:Ce,ariaSetSize:F,ariaSort:null,ariaValueMax:F,ariaValueMin:F,ariaValueNow:F,ariaValueText:null,role:null},transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()}});function Mo(e,t){return t in e?e[t]:t}function Bo(e,t){return Mo(e,t.toLowerCase())}const Sf=hn({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:fn,acceptCharset:be,accessKey:be,action:null,allow:null,allowFullScreen:te,allowPaymentRequest:te,allowUserMedia:te,alt:null,as:null,async:te,autoCapitalize:null,autoComplete:be,autoFocus:te,autoPlay:te,blocking:be,capture:null,charSet:null,checked:te,cite:null,className:be,cols:F,colSpan:null,content:null,contentEditable:Ce,controls:te,controlsList:be,coords:F|fn,crossOrigin:null,data:null,dateTime:null,decoding:null,default:te,defer:te,dir:null,dirName:null,disabled:te,download:Zi,draggable:Ce,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:te,formTarget:null,headers:be,height:F,hidden:Zi,high:F,href:null,hrefLang:null,htmlFor:be,httpEquiv:be,id:null,imageSizes:null,imageSrcSet:null,inert:te,inputMode:null,integrity:null,is:null,isMap:te,itemId:null,itemProp:be,itemRef:be,itemScope:te,itemType:be,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:te,low:F,manifest:null,max:null,maxLength:F,media:null,method:null,min:null,minLength:F,multiple:te,muted:te,name:null,nonce:null,noModule:te,noValidate:te,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:te,optimum:F,pattern:null,ping:be,placeholder:null,playsInline:te,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:te,referrerPolicy:null,rel:be,required:te,reversed:te,rows:F,rowSpan:F,sandbox:be,scope:null,scoped:te,seamless:te,selected:te,shadowRootClonable:te,shadowRootDelegatesFocus:te,shadowRootMode:null,shape:null,size:F,sizes:null,slot:null,span:F,spellCheck:Ce,src:null,srcDoc:null,srcLang:null,srcSet:null,start:F,step:null,style:null,tabIndex:F,target:null,title:null,translate:null,type:null,typeMustMatch:te,useMap:null,value:Ce,width:F,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:be,axis:null,background:null,bgColor:null,border:F,borderColor:null,bottomMargin:F,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:te,declare:te,event:null,face:null,frame:null,frameBorder:null,hSpace:F,leftMargin:F,link:null,longDesc:null,lowSrc:null,marginHeight:F,marginWidth:F,noResize:te,noHref:te,noShade:te,noWrap:te,object:null,profile:null,prompt:null,rev:null,rightMargin:F,rules:null,scheme:null,scrolling:Ce,standby:null,summary:null,text:null,topMargin:F,valueType:null,version:null,vAlign:null,vLink:null,vSpace:F,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:te,disableRemotePlayback:te,prefix:null,property:null,results:F,security:null,unselectable:null},space:"html",transform:Bo}),If=hn({attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},properties:{about:Qe,accentHeight:F,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:F,amplitude:F,arabicForm:null,ascent:F,attributeName:null,attributeType:null,azimuth:F,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:F,by:null,calcMode:null,capHeight:F,className:be,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:F,diffuseConstant:F,direction:null,display:null,dur:null,divisor:F,dominantBaseline:null,download:te,dx:null,dy:null,edgeMode:null,editable:null,elevation:F,enableBackground:null,end:null,event:null,exponent:F,externalResourcesRequired:null,fill:null,fillOpacity:F,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:fn,g2:fn,glyphName:fn,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:F,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:F,horizOriginX:F,horizOriginY:F,id:null,ideographic:F,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:F,k:F,k1:F,k2:F,k3:F,k4:F,kernelMatrix:Qe,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:F,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:F,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:F,overlineThickness:F,paintOrder:null,panose1:null,path:null,pathLength:F,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:be,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:F,pointsAtY:F,pointsAtZ:F,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Qe,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Qe,rev:Qe,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Qe,requiredFeatures:Qe,requiredFonts:Qe,requiredFormats:Qe,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:F,specularExponent:F,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:F,strikethroughThickness:F,string:null,stroke:null,strokeDashArray:Qe,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:F,strokeOpacity:F,strokeWidth:null,style:null,surfaceScale:F,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Qe,tabIndex:F,tableValues:null,target:null,targetX:F,targetY:F,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Qe,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:F,underlineThickness:F,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:F,values:null,vAlphabetic:F,vMathematical:F,vectorEffect:null,vHanging:F,vIdeographic:F,version:null,vertAdvY:F,vertOriginX:F,vertOriginY:F,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:F,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:Mo}),Fo=hn({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform(e,t){return"xlink:"+t.slice(5).toLowerCase()}}),Ho=hn({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:Bo}),Uo=hn({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()}}),Nf={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},vf=/[A-Z]/g,zo=/-[a-z]/g,Lf=/^data[-\w.:]+$/i;function Mr(e,t){const n=Hn(t);let r=t,i=Ve;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&Lf.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace(zo,Of);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!zo.test(a)){let s=a.replace(vf,Rf);s.charAt(0)!=="-"&&(s="-"+s),t="data"+s}}i=ta}return new i(r,t)}function Rf(e){return"-"+e.toLowerCase()}function Of(e){return e.charAt(1).toUpperCase()}const Un=Oo([Po,Sf,Fo,Ho,Uo],"html"),It=Oo([Po,If,Fo,Ho,Uo],"svg");function $o(e){const t=[],n=String(e||"");let r=n.indexOf(","),i=0,a=!1;for(;!a;){r===-1&&(r=n.length,a=!0);const s=n.slice(i,r).trim();(s||!a)&&t.push(s),i=r+1,r=n.indexOf(",",i)}return t}function Yo(e,t){const n=t||{};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}const jo=/[#.]/g;function Df(e,t){const n=e||"",r={};let i=0,a,s;for(;i<n.length;){jo.lastIndex=i;const o=jo.exec(n),u=n.slice(i,o?o.index:n.length);u&&(a?a==="#"?r.id=u:Array.isArray(r.className)?r.className.push(u):r.className=[u]:s=u,i+=u.length),o&&(a=o[0],i++)}return{type:"element",tagName:s||t||"div",properties:r,children:[]}}function Vo(e){const t=String(e||"").trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function qo(e){return e.join(" ").trim()}function Wo(e,t,n){const r=n?Ff(n):void 0;function i(a,s,...o){let u;if(a==null){u={type:"root",children:[]};const c=s;o.unshift(c)}else{u=Df(a,t);const c=u.tagName.toLowerCase(),f=r?r.get(c):void 0;if(u.tagName=f||c,Pf(s))o.unshift(s);else for(const[d,h]of Object.entries(s))Mf(e,u.properties,d,h)}for(const c of o)na(u.children,c);return u.type==="element"&&u.tagName==="template"&&(u.content={type:"root",children:u.children},u.children=[]),u}return i}function Pf(e){if(e===null||typeof e!="object"||Array.isArray(e))return!0;if(typeof e.type!="string")return!1;const t=e,n=Object.keys(e);for(const r of n){const i=t[r];if(i&&typeof i=="object"){if(!Array.isArray(i))return!0;const a=i;for(const s of a)if(typeof s!="number"&&typeof s!="string")return!0}}return!!("children"in e&&Array.isArray(e.children))}function Mf(e,t,n,r){const i=Mr(e,n);let a;if(r!=null){if(typeof r=="number"){if(Number.isNaN(r))return;a=r}else typeof r=="boolean"?a=r:typeof r=="string"?i.spaceSeparated?a=Vo(r):i.commaSeparated?a=$o(r):i.commaOrSpaceSeparated?a=Vo($o(r).join(" ")):a=Go(i,i.property,r):Array.isArray(r)?a=[...r]:a=i.property==="style"?Bf(r):String(r);if(Array.isArray(a)){const s=[];for(const o of a)s.push(Go(i,i.property,o));a=s}i.property==="className"&&Array.isArray(t.className)&&(a=t.className.concat(a)),t[i.property]=a}}function na(e,t){if(t!=null)if(typeof t=="number"||typeof t=="string")e.push({type:"text",value:String(t)});else if(Array.isArray(t))for(const n of t)na(e,n);else if(typeof t=="object"&&"type"in t)t.type==="root"?na(e,t.children):e.push(t);else throw new Error("Expected node, nodes, or string, got `"+t+"`")}function Go(e,t,n){if(typeof n=="string"){if(e.number&&n&&!Number.isNaN(Number(n)))return Number(n);if((e.boolean||e.overloadedBoolean)&&(n===""||Hn(n)===Hn(t)))return!0}return n}function Bf(e){const t=[];for(const[n,r]of Object.entries(e))t.push([n,r].join(": "));return t.join("; ")}function Ff(e){const t=new Map;for(const n of e)t.set(n.toLowerCase(),n);return t}const Hf=["altGlyph","altGlyphDef","altGlyphItem","animateColor","animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","glyphRef","linearGradient","radialGradient","solidColor","textArea","textPath"],Uf=Wo(Un,"div"),zf=Wo(It,"g",Hf);function $f(e){const t=String(e),n=[];return{toOffset:i,toPoint:r};function r(a){if(typeof a=="number"&&a>-1&&a<=t.length){let s=0;for(;;){let o=n[s];if(o===void 0){const u=Qo(t,n[s-1]);o=u===-1?t.length+1:u+1,n[s]=o}if(o>a)return{line:s+1,column:a-(s>0?n[s-1]:0)+1,offset:a};s++}}}function i(a){if(a&&typeof a.line=="number"&&typeof a.column=="number"&&!Number.isNaN(a.line)&&!Number.isNaN(a.column)){for(;n.length<a.line;){const o=n[n.length-1],u=Qo(t,o),c=u===-1?t.length+1:u+1;if(o===c)break;n.push(c)}const s=(a.line>1?n[a.line-2]:0)+a.column-1;if(s<n[a.line-1])return s}}}function Qo(e,t){const n=e.indexOf("\r",t),r=e.indexOf(`
|
|
2
|
-
`,t);return r===-1?n:n===-1||n+1===r?r:n<r?n:r}const qt={html:"http://www.w3.org/1999/xhtml",mathml:"http://www.w3.org/1998/Math/MathML",svg:"http://www.w3.org/2000/svg",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"},Ko={}.hasOwnProperty,Yf=Object.prototype;function jf(e,t){const n=t||{};return ra({file:n.file||void 0,location:!1,schema:n.space==="svg"?It:Un,verbose:n.verbose||!1},e)}function ra(e,t){let n;switch(t.nodeName){case"#comment":{const r=t;return n={type:"comment",value:r.data},Br(e,r,n),n}case"#document":case"#document-fragment":{const r=t,i="mode"in r?r.mode==="quirks"||r.mode==="limited-quirks":!1;if(n={type:"root",children:Xo(e,t.childNodes),data:{quirksMode:i}},e.file&&e.location){const a=String(e.file),s=$f(a),o=s.toPoint(0),u=s.toPoint(a.length);n.position={start:o,end:u}}return n}case"#documentType":{const r=t;return n={type:"doctype"},Br(e,r,n),n}case"#text":{const r=t;return n={type:"text",value:r.value},Br(e,r,n),n}default:return n=Vf(e,t),n}}function Xo(e,t){let n=-1;const r=[];for(;++n<t.length;){const i=ra(e,t[n]);r.push(i)}return r}function Vf(e,t){const n=e.schema;e.schema=t.namespaceURI===qt.svg?It:Un;let r=-1;const i={};for(;++r<t.attrs.length;){const o=t.attrs[r],u=(o.prefix?o.prefix+":":"")+o.name;Ko.call(Yf,u)||(i[u]=o.value)}const s=(e.schema.space==="svg"?zf:Uf)(t.tagName,i,Xo(e,t.childNodes));if(Br(e,t,s),s.tagName==="template"){const o=t,u=o.sourceCodeLocation,c=u&&u.startTag&&pn(u.startTag),f=u&&u.endTag&&pn(u.endTag),d=ra(e,o.content);c&&f&&e.file&&(d.position={start:c.end,end:f.start}),s.content=d}return e.schema=n,s}function Br(e,t,n){if("sourceCodeLocation"in t&&t.sourceCodeLocation&&e.file){const r=qf(e,n,t.sourceCodeLocation);r&&(e.location=!0,n.position=r)}}function qf(e,t,n){const r=pn(n);if(t.type==="element"){const i=t.children[t.children.length-1];if(r&&!n.endTag&&i&&i.position&&i.position.end&&(r.end=Object.assign({},i.position.end)),e.verbose){const a={};let s;if(n.attrs)for(s in n.attrs)Ko.call(n.attrs,s)&&(a[Mr(e.schema,s).property]=pn(n.attrs[s]));const o=pn(n.startTag),u=n.endTag?pn(n.endTag):void 0,c={opening:o};u&&(c.closing=u),c.properties=a,t.data={position:c}}}return r}function pn(e){const t=Zo({line:e.startLine,column:e.startCol,offset:e.startOffset}),n=Zo({line:e.endLine,column:e.endCol,offset:e.endOffset});return t||n?{start:t,end:n}:void 0}function Zo(e){return e.line&&e.column?e:void 0}const Jo={}.hasOwnProperty;function eu(e,t){const n=t||{};function r(i,...a){let s=r.invalid;const o=r.handlers;if(i&&Jo.call(i,e)){const u=String(i[e]);s=Jo.call(o,u)?o[u]:r.unknown}if(s)return s.call(this,i,...a)}return r.handlers=n.handlers||{},r.invalid=n.invalid,r.unknown=n.unknown,r}const Wf={},Gf={}.hasOwnProperty,tu=eu("type",{handlers:{root:Kf,element:th,text:Jf,comment:eh,doctype:Zf}});function Qf(e,t){const r=(t||Wf).space;return tu(e,r==="svg"?It:Un)}function Kf(e,t){const n={nodeName:"#document",mode:(e.data||{}).quirksMode?"quirks":"no-quirks",childNodes:[]};return n.childNodes=ia(e.children,n,t),mn(e,n),n}function Xf(e,t){const n={nodeName:"#document-fragment",childNodes:[]};return n.childNodes=ia(e.children,n,t),mn(e,n),n}function Zf(e){const t={nodeName:"#documentType",name:"html",publicId:"",systemId:"",parentNode:null};return mn(e,t),t}function Jf(e){const t={nodeName:"#text",value:e.value,parentNode:null};return mn(e,t),t}function eh(e){const t={nodeName:"#comment",data:e.value,parentNode:null};return mn(e,t),t}function th(e,t){const n=t;let r=n;e.type==="element"&&e.tagName.toLowerCase()==="svg"&&n.space==="html"&&(r=It);const i=[];let a;if(e.properties){for(a in e.properties)if(a!=="children"&&Gf.call(e.properties,a)){const u=nh(r,a,e.properties[a]);u&&i.push(u)}}const s=r.space,o={nodeName:e.tagName,tagName:e.tagName,attrs:i,namespaceURI:qt[s],childNodes:[],parentNode:null};return o.childNodes=ia(e.children,o,r),mn(e,o),e.tagName==="template"&&e.content&&(o.content=Xf(e.content,r)),o}function nh(e,t,n){const r=Mr(e,t);if(n===!1||n===null||n===void 0||typeof n=="number"&&Number.isNaN(n)||!n&&r.boolean)return;Array.isArray(n)&&(n=r.commaSeparated?Yo(n):qo(n));const i={name:r.attribute,value:n===!0?"":String(n)};if(r.space&&r.space!=="html"&&r.space!=="svg"){const a=i.name.indexOf(":");a<0?i.prefix="":(i.name=i.name.slice(a+1),i.prefix=r.attribute.slice(0,a)),i.namespace=qt[r.space]}return i}function ia(e,t,n){let r=-1;const i=[];if(e)for(;++r<e.length;){const a=tu(e[r],n);a.parentNode=t,i.push(a)}return i}function mn(e,t){const n=e.position;n&&n.start&&n.end&&(t.sourceCodeLocation={startLine:n.start.line,startCol:n.start.column,startOffset:n.start.offset,endLine:n.end.line,endCol:n.end.column,endOffset:n.end.offset})}const rh=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"],ih=new Set([65534,65535,131070,131071,196606,196607,262142,262143,327678,327679,393214,393215,458750,458751,524286,524287,589822,589823,655358,655359,720894,720895,786430,786431,851966,851967,917502,917503,983038,983039,1048574,1048575,1114110,1114111]),_e="�";var g;(function(e){e[e.EOF=-1]="EOF",e[e.NULL=0]="NULL",e[e.TABULATION=9]="TABULATION",e[e.CARRIAGE_RETURN=13]="CARRIAGE_RETURN",e[e.LINE_FEED=10]="LINE_FEED",e[e.FORM_FEED=12]="FORM_FEED",e[e.SPACE=32]="SPACE",e[e.EXCLAMATION_MARK=33]="EXCLAMATION_MARK",e[e.QUOTATION_MARK=34]="QUOTATION_MARK",e[e.AMPERSAND=38]="AMPERSAND",e[e.APOSTROPHE=39]="APOSTROPHE",e[e.HYPHEN_MINUS=45]="HYPHEN_MINUS",e[e.SOLIDUS=47]="SOLIDUS",e[e.DIGIT_0=48]="DIGIT_0",e[e.DIGIT_9=57]="DIGIT_9",e[e.SEMICOLON=59]="SEMICOLON",e[e.LESS_THAN_SIGN=60]="LESS_THAN_SIGN",e[e.EQUALS_SIGN=61]="EQUALS_SIGN",e[e.GREATER_THAN_SIGN=62]="GREATER_THAN_SIGN",e[e.QUESTION_MARK=63]="QUESTION_MARK",e[e.LATIN_CAPITAL_A=65]="LATIN_CAPITAL_A",e[e.LATIN_CAPITAL_Z=90]="LATIN_CAPITAL_Z",e[e.RIGHT_SQUARE_BRACKET=93]="RIGHT_SQUARE_BRACKET",e[e.GRAVE_ACCENT=96]="GRAVE_ACCENT",e[e.LATIN_SMALL_A=97]="LATIN_SMALL_A",e[e.LATIN_SMALL_Z=122]="LATIN_SMALL_Z"})(g||(g={}));const qe={DASH_DASH:"--",CDATA_START:"[CDATA[",DOCTYPE:"doctype",SCRIPT:"script",PUBLIC:"public",SYSTEM:"system"};function nu(e){return e>=55296&&e<=57343}function ah(e){return e>=56320&&e<=57343}function sh(e,t){return(e-55296)*1024+9216+t}function ru(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function iu(e){return e>=64976&&e<=65007||ih.has(e)}var v;(function(e){e.controlCharacterInInputStream="control-character-in-input-stream",e.noncharacterInInputStream="noncharacter-in-input-stream",e.surrogateInInputStream="surrogate-in-input-stream",e.nonVoidHtmlElementStartTagWithTrailingSolidus="non-void-html-element-start-tag-with-trailing-solidus",e.endTagWithAttributes="end-tag-with-attributes",e.endTagWithTrailingSolidus="end-tag-with-trailing-solidus",e.unexpectedSolidusInTag="unexpected-solidus-in-tag",e.unexpectedNullCharacter="unexpected-null-character",e.unexpectedQuestionMarkInsteadOfTagName="unexpected-question-mark-instead-of-tag-name",e.invalidFirstCharacterOfTagName="invalid-first-character-of-tag-name",e.unexpectedEqualsSignBeforeAttributeName="unexpected-equals-sign-before-attribute-name",e.missingEndTagName="missing-end-tag-name",e.unexpectedCharacterInAttributeName="unexpected-character-in-attribute-name",e.unknownNamedCharacterReference="unknown-named-character-reference",e.missingSemicolonAfterCharacterReference="missing-semicolon-after-character-reference",e.unexpectedCharacterAfterDoctypeSystemIdentifier="unexpected-character-after-doctype-system-identifier",e.unexpectedCharacterInUnquotedAttributeValue="unexpected-character-in-unquoted-attribute-value",e.eofBeforeTagName="eof-before-tag-name",e.eofInTag="eof-in-tag",e.missingAttributeValue="missing-attribute-value",e.missingWhitespaceBetweenAttributes="missing-whitespace-between-attributes",e.missingWhitespaceAfterDoctypePublicKeyword="missing-whitespace-after-doctype-public-keyword",e.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers="missing-whitespace-between-doctype-public-and-system-identifiers",e.missingWhitespaceAfterDoctypeSystemKeyword="missing-whitespace-after-doctype-system-keyword",e.missingQuoteBeforeDoctypePublicIdentifier="missing-quote-before-doctype-public-identifier",e.missingQuoteBeforeDoctypeSystemIdentifier="missing-quote-before-doctype-system-identifier",e.missingDoctypePublicIdentifier="missing-doctype-public-identifier",e.missingDoctypeSystemIdentifier="missing-doctype-system-identifier",e.abruptDoctypePublicIdentifier="abrupt-doctype-public-identifier",e.abruptDoctypeSystemIdentifier="abrupt-doctype-system-identifier",e.cdataInHtmlContent="cdata-in-html-content",e.incorrectlyOpenedComment="incorrectly-opened-comment",e.eofInScriptHtmlCommentLikeText="eof-in-script-html-comment-like-text",e.eofInDoctype="eof-in-doctype",e.nestedComment="nested-comment",e.abruptClosingOfEmptyComment="abrupt-closing-of-empty-comment",e.eofInComment="eof-in-comment",e.incorrectlyClosedComment="incorrectly-closed-comment",e.eofInCdata="eof-in-cdata",e.absenceOfDigitsInNumericCharacterReference="absence-of-digits-in-numeric-character-reference",e.nullCharacterReference="null-character-reference",e.surrogateCharacterReference="surrogate-character-reference",e.characterReferenceOutsideUnicodeRange="character-reference-outside-unicode-range",e.controlCharacterReference="control-character-reference",e.noncharacterCharacterReference="noncharacter-character-reference",e.missingWhitespaceBeforeDoctypeName="missing-whitespace-before-doctype-name",e.missingDoctypeName="missing-doctype-name",e.invalidCharacterSequenceAfterDoctypeName="invalid-character-sequence-after-doctype-name",e.duplicateAttribute="duplicate-attribute",e.nonConformingDoctype="non-conforming-doctype",e.missingDoctype="missing-doctype",e.misplacedDoctype="misplaced-doctype",e.endTagWithoutMatchingOpenElement="end-tag-without-matching-open-element",e.closingOfElementWithOpenChildElements="closing-of-element-with-open-child-elements",e.disallowedContentInNoscriptInHead="disallowed-content-in-noscript-in-head",e.openElementsLeftAfterEof="open-elements-left-after-eof",e.abandonedHeadElementChild="abandoned-head-element-child",e.misplacedStartTagForHeadElement="misplaced-start-tag-for-head-element",e.nestedNoscriptInHead="nested-noscript-in-head",e.eofInElementThatCanContainOnlyText="eof-in-element-that-can-contain-only-text"})(v||(v={}));const oh=65536;class uh{constructor(t){this.handler=t,this.html="",this.pos=-1,this.lastGapPos=-2,this.gapStack=[],this.skipNextNewLine=!1,this.lastChunkWritten=!1,this.endOfChunkHit=!1,this.bufferWaterline=oh,this.isEol=!1,this.lineStartPos=0,this.droppedBufferSize=0,this.line=1,this.lastErrOffset=-1}get col(){return this.pos-this.lineStartPos+ +(this.lastGapPos!==this.pos)}get offset(){return this.droppedBufferSize+this.pos}getError(t,n){const{line:r,col:i,offset:a}=this,s=i+n,o=a+n;return{code:t,startLine:r,endLine:r,startCol:s,endCol:s,startOffset:o,endOffset:o}}_err(t){this.handler.onParseError&&this.lastErrOffset!==this.offset&&(this.lastErrOffset=this.offset,this.handler.onParseError(this.getError(t,0)))}_addGap(){this.gapStack.push(this.lastGapPos),this.lastGapPos=this.pos}_processSurrogate(t){if(this.pos!==this.html.length-1){const n=this.html.charCodeAt(this.pos+1);if(ah(n))return this.pos++,this._addGap(),sh(t,n)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,g.EOF;return this._err(v.surrogateInInputStream),t}willDropParsedChunk(){return this.pos>this.bufferWaterline}dropParsedChunk(){this.willDropParsedChunk()&&(this.html=this.html.substring(this.pos),this.lineStartPos-=this.pos,this.droppedBufferSize+=this.pos,this.pos=0,this.lastGapPos=-2,this.gapStack.length=0)}write(t,n){this.html.length>0?this.html+=t:this.html=t,this.endOfChunkHit=!1,this.lastChunkWritten=n}insertHtmlAtCurrentPos(t){this.html=this.html.substring(0,this.pos+1)+t+this.html.substring(this.pos+1),this.endOfChunkHit=!1}startsWith(t,n){if(this.pos+t.length>this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,!1;if(n)return this.html.startsWith(t,this.pos);for(let r=0;r<t.length;r++)if((this.html.charCodeAt(this.pos+r)|32)!==t.charCodeAt(r))return!1;return!0}peek(t){const n=this.pos+t;if(n>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,g.EOF;const r=this.html.charCodeAt(n);return r===g.CARRIAGE_RETURN?g.LINE_FEED:r}advance(){if(this.pos++,this.isEol&&(this.isEol=!1,this.line++,this.lineStartPos=this.pos),this.pos>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,g.EOF;let t=this.html.charCodeAt(this.pos);return t===g.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,g.LINE_FEED):t===g.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,nu(t)&&(t=this._processSurrogate(t)),this.handler.onParseError===null||t>31&&t<127||t===g.LINE_FEED||t===g.CARRIAGE_RETURN||t>159&&t<64976||this._checkForProblematicCharacters(t),t)}_checkForProblematicCharacters(t){ru(t)?this._err(v.controlCharacterInInputStream):iu(t)&&this._err(v.noncharacterInInputStream)}retreat(t){for(this.pos-=t;this.pos<this.lastGapPos;)this.lastGapPos=this.gapStack.pop(),this.pos--;this.isEol=!1}}var re;(function(e){e[e.CHARACTER=0]="CHARACTER",e[e.NULL_CHARACTER=1]="NULL_CHARACTER",e[e.WHITESPACE_CHARACTER=2]="WHITESPACE_CHARACTER",e[e.START_TAG=3]="START_TAG",e[e.END_TAG=4]="END_TAG",e[e.COMMENT=5]="COMMENT",e[e.DOCTYPE=6]="DOCTYPE",e[e.EOF=7]="EOF",e[e.HIBERNATION=8]="HIBERNATION"})(re||(re={}));function au(e,t){for(let n=e.attrs.length-1;n>=0;n--)if(e.attrs[n].name===t)return e.attrs[n].value;return null}const lh=new Uint16Array('ᵁ<Õıʊҝջאٵ۞ޢߖࠏઑඡ༉༦ረዡᐕᒝᓃᓟᔥ\0\0\0\0\0\0ᕫᛍᦍᰒᷝ↰⊍⏀⏻⑂⠤⤒ⴈ⹈⿎〖㊺㘹㞬㣾㨨㩱㫠㬮ࠀEMabcfglmnoprstu\\bfms¦³¹ÈÏlig耻Æ䃆P耻&䀦cute耻Á䃁reve;䄂Āiyx}rc耻Â䃂;䐐r;쀀𝔄rave耻À䃀pha;䎑acr;䄀d;橓Āgp¡on;䄄f;쀀𝔸plyFunction;恡ing耻Å䃅Ācs¾Ãr;쀀𝒜ign;扔ilde耻Ã䃃ml耻Ä䃄ЀaceforsuåûþėĜĢħĪĀcrêòkslash;或Ŷöø;櫧ed;挆y;䐑ƀcrtąċĔause;戵noullis;愬a;䎒r;쀀𝔅pf;쀀𝔹eve;䋘còēmpeq;扎܀HOacdefhilorsuōőŖƀƞƢƵƷƺǜȕɳɸɾcy;䐧PY耻©䂩ƀcpyŝŢźute;䄆Ā;iŧŨ拒talDifferentialD;慅leys;愭ȀaeioƉƎƔƘron;䄌dil耻Ç䃇rc;䄈nint;戰ot;䄊ĀdnƧƭilla;䂸terDot;䂷òſi;䎧rcleȀDMPTLJNjǑǖot;抙inus;抖lus;投imes;抗oĀcsǢǸkwiseContourIntegral;戲eCurlyĀDQȃȏoubleQuote;思uote;怙ȀlnpuȞȨɇɕonĀ;eȥȦ户;橴ƀgitȯȶȺruent;扡nt;戯ourIntegral;戮ĀfrɌɎ;愂oduct;成nterClockwiseContourIntegral;戳oss;樯cr;쀀𝒞pĀ;Cʄʅ拓ap;才րDJSZacefiosʠʬʰʴʸˋ˗ˡ˦̳ҍĀ;oŹʥtrahd;椑cy;䐂cy;䐅cy;䐏ƀgrsʿ˄ˇger;怡r;憡hv;櫤Āayː˕ron;䄎;䐔lĀ;t˝˞戇a;䎔r;쀀𝔇Āaf˫̧Ācm˰̢riticalȀADGT̖̜̀̆cute;䂴oŴ̋̍;䋙bleAcute;䋝rave;䁠ilde;䋜ond;拄ferentialD;慆Ѱ̽\0\0\0͔͂\0Ѕf;쀀𝔻ƀ;DE͈͉͍䂨ot;惜qual;扐blèCDLRUVͣͲϏϢϸontourIntegraìȹoɴ\0\0ͻ»͉nArrow;懓Āeo·ΤftƀARTΐΖΡrrow;懐ightArrow;懔eåˊngĀLRΫτeftĀARγιrrow;柸ightArrow;柺ightArrow;柹ightĀATϘϞrrow;懒ee;抨pɁϩ\0\0ϯrrow;懑ownArrow;懕erticalBar;戥ǹABLRTaВЪаўѿͼrrowƀ;BUНОТ憓ar;椓pArrow;懵reve;䌑eft˒к\0ц\0ѐightVector;楐eeVector;楞ectorĀ;Bљњ憽ar;楖ightǔѧ\0ѱeeVector;楟ectorĀ;BѺѻ懁ar;楗eeĀ;A҆҇护rrow;憧ĀctҒҗr;쀀𝒟rok;䄐ࠀNTacdfglmopqstuxҽӀӄӋӞӢӧӮӵԡԯԶՒ՝ՠեG;䅊H耻Ð䃐cute耻É䃉ƀaiyӒӗӜron;䄚rc耻Ê䃊;䐭ot;䄖r;쀀𝔈rave耻È䃈ement;戈ĀapӺӾcr;䄒tyɓԆ\0\0ԒmallSquare;旻erySmallSquare;斫ĀgpԦԪon;䄘f;쀀𝔼silon;䎕uĀaiԼՉlĀ;TՂՃ橵ilde;扂librium;懌Āci՚r;愰m;橳a;䎗ml耻Ë䃋Āipժկsts;戃onentialE;慇ʀcfiosօֈ֍ֲy;䐤r;쀀𝔉lledɓ֗\0\0֣mallSquare;旼erySmallSquare;斪Ͱֺ\0ֿ\0\0ׄf;쀀𝔽All;戀riertrf;愱còJTabcdfgorstרׯؒؖ؛؝أ٬ٲcy;䐃耻>䀾mmaĀ;d䎓;䏜reve;䄞ƀeiy؇،ؐdil;䄢rc;䄜;䐓ot;䄠r;쀀𝔊;拙pf;쀀𝔾eater̀EFGLSTصلَٖٛ٦qualĀ;Lؾؿ扥ess;招ullEqual;执reater;檢ess;扷lantEqual;橾ilde;扳cr;쀀𝒢;扫ЀAacfiosuڅڋږڛڞڪھۊRDcy;䐪Āctڐڔek;䋇;䁞irc;䄤r;愌lbertSpace;愋ǰگ\0ڲf;愍izontalLine;攀Āctۃۅòکrok;䄦mpńېۘownHumðįqual;扏܀EJOacdfgmnostuۺ۾܃܇ܚܞܡܨ݄ݸދޏޕcy;䐕lig;䄲cy;䐁cute耻Í䃍Āiyܓܘrc耻Î䃎;䐘ot;䄰r;愑rave耻Ì䃌ƀ;apܠܯܿĀcgܴܷr;䄪inaryI;慈lieóϝǴ݉\0ݢĀ;eݍݎ戬Āgrݓݘral;戫section;拂isibleĀCTݬݲomma;恣imes;恢ƀgptݿރވon;䄮f;쀀𝕀a;䎙cr;愐ilde;䄨ǫޚ\0ޞcy;䐆l耻Ï䃏ʀcfosuެ߂ߐĀiyޱrc;䄴;䐙r;쀀𝔍pf;쀀𝕁ǣ߇\0ߌr;쀀𝒥rcy;䐈kcy;䐄HJacfosߤߨ߽߬߱ࠂࠈcy;䐥cy;䐌ppa;䎚Āey߶dil;䄶;䐚r;쀀𝔎pf;쀀𝕂cr;쀀𝒦րJTaceflmostࠥࠩࠬࡐࡣসে্ੇcy;䐉耻<䀼ʀcmnpr࠷࠼ࡁࡄࡍute;䄹bda;䎛g;柪lacetrf;愒r;憞ƀaeyࡗࡡron;䄽dil;䄻;䐛Āfsࡨ॰tԀACDFRTUVarࡾࢩࢱࣦ࣠ࣼयज़ΐ४ĀnrࢃgleBracket;柨rowƀ;BR࢙࢚࢞憐ar;懤ightArrow;懆eiling;挈oǵࢷ\0ࣃbleBracket;柦nǔࣈ\0࣒eeVector;楡ectorĀ;Bࣛࣜ懃ar;楙loor;挊ightĀAV࣯ࣵrrow;憔ector;楎Āerँगeƀ;AVउऊऐ抣rrow;憤ector;楚iangleƀ;BEतथऩ抲ar;槏qual;抴pƀDTVषूौownVector;楑eeVector;楠ectorĀ;Bॖॗ憿ar;楘ectorĀ;B॥०憼ar;楒ightáΜs̀EFGLSTॾঋকঝঢভqualGreater;拚ullEqual;扦reater;扶ess;檡lantEqual;橽ilde;扲r;쀀𝔏Ā;eঽা拘ftarrow;懚idot;䄿ƀnpwਖਛgȀLRlr৷ਂਐeftĀAR০৬rrow;柵ightArrow;柷ightArrow;柶eftĀarγਊightáοightáϊf;쀀𝕃erĀLRਢਬeftArrow;憙ightArrow;憘ƀchtਾੀੂòࡌ;憰rok;䅁;扪Ѐacefiosuਗ਼અઋp;椅y;䐜Ādl੯iumSpace;恟lintrf;愳r;쀀𝔐nusPlus;戓pf;쀀𝕄cò੶;䎜ҀJacefostuણધભીଔଙඑඞcy;䐊cute;䅃ƀaeyહાron;䅇dil;䅅;䐝ƀgswે૰ativeƀMTV૨ediumSpace;怋hiĀcn૦ëeryThiîtedĀGLଆreaterGreateòٳessLesóੈLine;䀊r;쀀𝔑ȀBnptଢନଷreak;恠BreakingSpace;䂠f;愕ڀ;CDEGHLNPRSTV୕ୖ୪௫ఄ಄ದൡඅ櫬Āoungruent;扢pCap;扭oubleVerticalBar;戦ƀlqxஃஊement;戉ualĀ;Tஒஓ扠ilde;쀀≂̸ists;戄reater;EFGLSTஶஷ扯qual;扱ullEqual;쀀≧̸reater;쀀≫̸ess;批lantEqual;쀀⩾̸ilde;扵umpń௲ownHump;쀀≎̸qual;쀀≏̸eĀfsఊధtTriangleƀ;BEచఛడ拪ar;쀀⧏̸qual;括s̀;EGLSTవశ఼ౄోౘ扮qual;扰reater;扸ess;쀀≪̸lantEqual;쀀⩽̸ilde;扴estedĀGL౨౹reaterGreater;쀀⪢̸essLess;쀀⪡̸recedesƀ;ESಒಓಛ技qual;쀀⪯̸lantEqual;拠ĀeiಫಹverseElement;戌ghtTriangleƀ;BEೋೌ拫ar;쀀⧐̸qual;拭ĀquೝഌuareSuĀbp೨setĀ;Eೳ쀀⊏̸qual;拢ersetĀ;Eഃആ쀀⊐̸qual;拣ƀbcpഓതൎsetĀ;Eഛഞ쀀⊂⃒qual;抈ceedsȀ;ESTലള഻െ抁qual;쀀⪰̸lantEqual;拡ilde;쀀≿̸ersetĀ;E൘൛쀀⊃⃒qual;抉ildeȀ;EFT൮൯൵ൿ扁qual;扄ullEqual;扇ilde;扉erticalBar;戤cr;쀀𝒩ilde耻Ñ䃑;䎝܀Eacdfgmoprstuvලෂෛ෧ขภยา฿ไlig;䅒cute耻Ó䃓Āiyීrc耻Ô䃔;䐞blac;䅐r;쀀𝔒rave耻Ò䃒ƀaei෮ෲcr;䅌ga;䎩cron;䎟pf;쀀𝕆enCurlyĀDQฎบoubleQuote;怜uote;怘;橔Āclวฬr;쀀𝒪ash耻Ø䃘iŬืde耻Õ䃕es;樷ml耻Ö䃖erĀBP๋Āar๐๓r;怾acĀek๚;揞et;掴arenthesis;揜ҀacfhilorsງຊຏຒດຝະrtialD;戂y;䐟r;쀀𝔓i;䎦;䎠usMinus;䂱Āipຢອncareplanåڝf;愙Ȁ;eio຺ູ檻cedesȀ;EST່້扺qual;檯lantEqual;扼ilde;找me;怳Ādpuct;戏ortionĀ;aȥl;戝Āci༁༆r;쀀𝒫;䎨ȀUfos༑༖༛༟OT耻"䀢r;쀀𝔔pf;愚cr;쀀𝒬BEacefhiorsu༾གྷཇའཱིྦྷྪྭ႖ႩႴႾarr;椐G耻®䂮ƀcnrཎནབute;䅔g;柫rĀ;tཛྷཝ憠l;椖ƀaeyཧཬཱron;䅘dil;䅖;䐠Ā;vླྀཹ愜erseĀEUྂྙĀlq྇ྎement;戋uilibrium;懋pEquilibrium;楯r»ཹo;䎡ghtЀACDFTUVa࿁ဢဨၛႇϘĀnr࿆࿒gleBracket;柩rowƀ;BL憒ar;懥eftArrow;懄eiling;按oǵ\0စbleBracket;柧nǔည\0နeeVector;楝ectorĀ;Bဝသ懂ar;楕loor;挋Āerိ၃eƀ;AVဵံြ抢rrow;憦ector;楛iangleƀ;BEၐၑၕ抳ar;槐qual;抵pƀDTVၣၮၸownVector;楏eeVector;楜ectorĀ;Bႂႃ憾ar;楔ectorĀ;B႑႒懀ar;楓Āpuႛ႞f;愝ndImplies;楰ightarrow;懛ĀchႹႼr;愛;憱leDelayed;槴ڀHOacfhimoqstuფჱჷჽᄙᄞᅑᅖᅡᅧᆵᆻᆿĀCcჩხHcy;䐩y;䐨FTcy;䐬cute;䅚ʀ;aeiyᄈᄉᄎᄓᄗ檼ron;䅠dil;䅞rc;䅜;䐡r;쀀𝔖ortȀDLRUᄪᄴᄾᅉownArrow»ОeftArrow»࢚ightArrow»pArrow;憑gma;䎣allCircle;战pf;쀀𝕊ɲᅭ\0\0ᅰt;戚areȀ;ISUᅻᅼᆉᆯ斡ntersection;抓uĀbpᆏᆞsetĀ;Eᆗᆘ抏qual;抑ersetĀ;Eᆨᆩ抐qual;抒nion;抔cr;쀀𝒮ar;拆ȀbcmpᇈᇛሉላĀ;sᇍᇎ拐etĀ;Eᇍᇕqual;抆ĀchᇠህeedsȀ;ESTᇭᇮᇴᇿ扻qual;檰lantEqual;扽ilde;承Tháྌ;我ƀ;esሒሓሣ拑rsetĀ;Eሜም抃qual;抇et»ሓրHRSacfhiorsሾቄቕቱቶኟዂወዑORN耻Þ䃞ADE;愢ĀHcቒcy;䐋y;䐦Ābuቚቜ;䀉;䎤ƀaeyብቪቯron;䅤dil;䅢;䐢r;쀀𝔗ĀeiቻDzኀ\0ኇefore;戴a;䎘ĀcnኘkSpace;쀀 Space;怉ldeȀ;EFTካኬኲኼ戼qual;扃ullEqual;扅ilde;扈pf;쀀𝕋ipleDot;惛Āctዖዛr;쀀𝒯rok;䅦ૡዷጎጚጦ\0ጬጱ\0\0\0\0\0ጸጽ፷ᎅ\0ᐄᐊᐐĀcrዻጁute耻Ú䃚rĀ;oጇገ憟cir;楉rǣጓ\0y;䐎ve;䅬Āiyጞጣrc耻Û䃛;䐣blac;䅰r;쀀𝔘rave耻Ù䃙acr;䅪Ādiፁ፩erĀBPፈ፝Āarፍፐr;䁟acĀekፗፙ;揟et;掵arenthesis;揝onĀ;P፰፱拃lus;抎Āgp፻on;䅲f;쀀𝕌ЀADETadps᎕ᎮᎸᏄϨᏒᏗᏳrrowƀ;BDᅐᎠᎤar;椒ownArrow;懅ownArrow;憕quilibrium;楮eeĀ;AᏋᏌ报rrow;憥ownáϳerĀLRᏞᏨeftArrow;憖ightArrow;憗iĀ;lᏹᏺ䏒on;䎥ing;䅮cr;쀀𝒰ilde;䅨ml耻Ü䃜ҀDbcdefosvᐧᐬᐰᐳᐾᒅᒊᒐᒖash;披ar;櫫y;䐒ashĀ;lᐻᐼ抩;櫦Āerᑃᑅ;拁ƀbtyᑌᑐᑺar;怖Ā;iᑏᑕcalȀBLSTᑡᑥᑪᑴar;戣ine;䁼eparator;杘ilde;所ThinSpace;怊r;쀀𝔙pf;쀀𝕍cr;쀀𝒱dash;抪ʀcefosᒧᒬᒱᒶᒼirc;䅴dge;拀r;쀀𝔚pf;쀀𝕎cr;쀀𝒲Ȁfiosᓋᓐᓒᓘr;쀀𝔛;䎞pf;쀀𝕏cr;쀀𝒳ҀAIUacfosuᓱᓵᓹᓽᔄᔏᔔᔚᔠcy;䐯cy;䐇cy;䐮cute耻Ý䃝Āiyᔉᔍrc;䅶;䐫r;쀀𝔜pf;쀀𝕐cr;쀀𝒴ml;䅸ЀHacdefosᔵᔹᔿᕋᕏᕝᕠᕤcy;䐖cute;䅹Āayᕄᕉron;䅽;䐗ot;䅻Dzᕔ\0ᕛoWidtèa;䎖r;愨pf;愤cr;쀀𝒵ᖃᖊᖐ\0ᖰᖶᖿ\0\0\0\0ᗆᗛᗫᙟ᙭\0ᚕ᚛ᚲᚹ\0ᚾcute耻á䃡reve;䄃̀;Ediuyᖜᖝᖡᖣᖨᖭ戾;쀀∾̳;房rc耻â䃢te肻´̆;䐰lig耻æ䃦Ā;r²ᖺ;쀀𝔞rave耻à䃠ĀepᗊᗖĀfpᗏᗔsym;愵èᗓha;䎱ĀapᗟcĀclᗤᗧr;䄁g;樿ɤᗰ\0\0ᘊʀ;adsvᗺᗻᗿᘁᘇ戧nd;橕;橜lope;橘;橚;elmrszᘘᘙᘛᘞᘿᙏᙙ戠;榤e»ᘙsdĀ;aᘥᘦ戡ѡᘰᘲᘴᘶᘸᘺᘼᘾ;榨;榩;榪;榫;榬;榭;榮;榯tĀ;vᙅᙆ戟bĀ;dᙌᙍ抾;榝Āptᙔᙗh;戢»¹arr;捼Āgpᙣᙧon;䄅f;쀀𝕒;Eaeiopᙻᙽᚂᚄᚇᚊ;橰cir;橯;扊d;手s;䀧roxĀ;eᚒñᚃing耻å䃥ƀctyᚡᚦᚨr;쀀𝒶;䀪mpĀ;eᚯñʈilde耻ã䃣ml耻ä䃤Āciᛂᛈoninôɲnt;樑ࠀNabcdefiklnoprsu᛭ᛱᜰᝃᝈ០៦ᠹᡐᜍ᥈ᥰot;櫭ĀcrᛶkȀcepsᜀᜅᜍᜓong;扌psilon;䏶rime;怵imĀ;e戽q;拍Ŷᜢᜦee;抽edĀ;gᜬᜭ挅e»ᜭrkĀ;tbrk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓᝡᝤᝨausĀ;eĊĉptyv;榰séᜌnoõēƀahwᝯᝳ;䎲;愶een;扬r;쀀𝔟gcostuvwឍឝឳេ៕៛ƀaiuបពរðݠrc;旯p»፱ƀdptឤឨឭot;樀lus;樁imes;樂ɱឹ\0\0ើcup;樆ar;昅riangleĀdu៍្own;施p;斳plus;樄eåᑄåᒭarow;植ƀakoᠦᠵĀcn៲ᠣkƀlst֫᠂ozenge;槫riangleȀ;dlr᠒᠓᠘斴own;斾eft;旂ight;斸k;搣Ʊᠫ\0ᠳƲᠯ\0ᠱ;斒;斑4;斓ck;斈ĀeoᠾᡍĀ;qᡃᡆ쀀=⃥uiv;쀀≡⃥t;挐Ȁptwxᡙᡞᡧᡬf;쀀𝕓Ā;tᏋᡣom»Ꮜtie;拈DHUVbdhmptuvᢅᢖᢪᢻᣗᣛᣬᤅᤊᤐᤡȀLRlrᢎᢐᢒᢔ;敗;敔;敖;敓ʀ;DUduᢡᢢᢤᢦᢨ敐;敦;敩;敤;敧ȀLRlrᢳᢵᢷᢹ;敝;敚;敜;教;HLRhlrᣊᣋᣍᣏᣑᣓᣕ救;敬;散;敠;敫;敢;敟ox;槉ȀLRlrᣤᣦᣨᣪ;敕;敒;攐;攌ʀ;DUduڽ;敥;敨;攬;攴inus;抟lus;択imes;抠ȀLRlrᤙᤛᤝ;敛;敘;攘;攔;HLRhlrᤰᤱᤳᤵᤷ᤻᤹攂;敪;敡;敞;攼;攤;攜Āevģbar耻¦䂦Ȁceioᥑᥖᥚᥠr;쀀𝒷mi;恏mĀ;elƀ;bhᥨᥩᥫ䁜;槅sub;柈ŬᥴlĀ;e怢t»pƀ;Eeįᦅᦇ;檮Ā;qۜۛೡᦧ\0᧨ᨑᨕᨲ\0ᨷᩐ\0\0᪴\0\0᫁\0\0ᬡᬮ᭒\0᯽\0ᰌƀcprᦲute;䄇̀;abcdsᦿᧀᧄ᧕᧙戩nd;橄rcup;橉Āau᧒p;橋p;橇ot;橀;쀀∩︀Āeo᧢᧥t;恁îړȀaeiu᧰᧻ᨁᨅǰ᧵\0᧸s;橍on;䄍dil耻ç䃧rc;䄉psĀ;sᨌᨍ橌m;橐ot;䄋ƀdmnᨛᨠᨦil肻¸ƭptyv;榲t脀¢;eᨭᨮ䂢räƲr;쀀𝔠ƀceiᨽᩀᩍy;䑇ckĀ;mᩇᩈ朓ark»ᩈ;䏇r;Ecefms᩠ᩢᩫ᪤᪪旋;槃ƀ;elᩩᩪᩭ䋆q;扗eɡᩴ\0\0᪈rrowĀlr᩼᪁eft;憺ight;憻ʀRSacd᪒᪔᪖»ཇ;擈st;抛irc;抚ash;抝nint;樐id;櫯cir;槂ubsĀ;u᪻᪼晣it»᪼ˬ᫇\0ᬊonĀ;eᫍᫎ䀺Ā;qÇÆɭ\0\0aĀ;t䀬;䁀ƀ;fl戁îᅠeĀmxent»eóɍǧ\0ᬇĀ;dኻᬂot;橭nôɆƀfryᬐᬔᬗ;쀀𝕔oäɔ脀©;sŕᬝr;愗Āaoᬥᬩrr;憵ss;朗Ācuᬲᬷr;쀀𝒸Ābpᬼ᭄Ā;eᭁᭂ櫏;櫑Ā;eᭉᭊ櫐;櫒dot;拯delprvw᭠᭬᭷ᮂᮬᯔarrĀlr᭨᭪;椸;椵ɰ᭲\0\0᭵r;拞c;拟arrĀ;pᮀ憶;椽̀;bcdosᮏᮐᮖᮡᮥᮨ截rcap;橈Āauᮛᮞp;橆p;橊ot;抍r;橅;쀀∪︀Ȁalrv᮵ᮿᯞᯣrrĀ;mᮼᮽ憷;椼yƀevwᯇᯔᯘqɰᯎ\0\0ᯒreã᭳uã᭵ee;拎edge;拏en耻¤䂤earrowĀlrᯮ᯳eft»ᮀight»ᮽeäᯝĀciᰁᰇoninôǷnt;戱lcty;挭ঀAHabcdefhijlorstuwz᰻᰿ᱝᱩᱵᲞᲬᲷᴍᵻᶑᶫᶻ᷆᷍ròar;楥Ȁglrs᱈ᱍ᱒᱔ger;怠eth;愸òᄳhĀ;vᱚᱛ怐»ऊūᱡᱧarow;椏aã̕Āayᱮᱳron;䄏;䐴ƀ;ao̲ᱼᲄĀgrʿᲁr;懊tseq;橷ƀglmᲑᲔᲘ耻°䂰ta;䎴ptyv;榱ĀirᲣᲨsht;楿;쀀𝔡arĀlrᲳᲵ»ࣜ»သʀaegsv᳂᳖᳜᳠mƀ;oș᳔ndĀ;ș᳑uit;晦amma;䏝in;拲ƀ;io᳧᳨᳸䃷de脀÷;o᳧ᳰntimes;拇nø᳷cy;䑒cɯᴆ\0\0ᴊrn;挞op;挍ʀlptuwᴘᴝᴢᵉᵕlar;䀤f;쀀𝕕ʀ;emps̋ᴭᴷᴽᵂqĀ;d͒ᴳot;扑inus;戸lus;戔quare;抡blebarwedgåúnƀadhᄮᵝᵧownarrowóᲃarpoonĀlrᵲᵶefôᲴighôᲶŢᵿᶅkaro÷གɯᶊ\0\0ᶎrn;挟op;挌ƀcotᶘᶣᶦĀryᶝᶡ;쀀𝒹;䑕l;槶rok;䄑Ādrᶰᶴot;拱iĀ;fᶺ᠖斿Āah᷀᷃ròЩaòྦangle;榦Āci᷒ᷕy;䑟grarr;柿ऀDacdefglmnopqrstuxḁḉḙḸոḼṉṡṾấắẽỡἪἷὄĀDoḆᴴoôĀcsḎḔute耻é䃩ter;橮ȀaioyḢḧḱḶron;䄛rĀ;cḭḮ扖耻ê䃪lon;払;䑍ot;䄗ĀDrṁṅot;扒;쀀𝔢ƀ;rsṐṑṗ檚ave耻è䃨Ā;dṜṝ檖ot;檘Ȁ;ilsṪṫṲṴ檙nters;揧;愓Ā;dṹṺ檕ot;檗ƀapsẅẉẗcr;䄓tyƀ;svẒẓẕ戅et»ẓpĀ1;ẝẤijạả;怄;怅怃ĀgsẪẬ;䅋p;怂ĀgpẴẸon;䄙f;쀀𝕖ƀalsỄỎỒrĀ;sỊị拕l;槣us;橱iƀ;lvỚớở䎵on»ớ;䏵ȀcsuvỪỳἋἣĀioữḱrc»Ḯɩỹ\0\0ỻíՈantĀglἂἆtr»ṝess»ṺƀaeiἒἚls;䀽st;扟vĀ;DȵἠD;橸parsl;槥ĀDaἯἳot;打rr;楱ƀcdiἾὁỸr;愯oô͒ĀahὉὋ;䎷耻ð䃰Āmrὓὗl耻ë䃫o;悬ƀcipὡὤὧl;䀡sôծĀeoὬὴctatioîՙnentialåչৡᾒ\0ᾞ\0ᾡᾧ\0\0ῆῌ\0ΐ\0ῦῪ \0 ⁚llingdotseñṄy;䑄male;晀ƀilrᾭᾳ῁lig;耀ffiɩᾹ\0\0᾽g;耀ffig;耀ffl;쀀𝔣lig;耀filig;쀀fjƀaltῙῡt;晭ig;耀flns;斱of;䆒ǰ΅\0ῳf;쀀𝕗ĀakֿῷĀ;vῼ´拔;櫙artint;樍Āao⁕Ācs‑⁒ႉ‸⁅⁈\0⁐β•‥‧\0耻½䂽;慓耻¼䂼;慕;慙;慛Ƴ‴\0‶;慔;慖ʴ‾⁁\0\0⁃耻¾䂾;慗;慜5;慘ƶ⁌\0⁎;慚;慝8;慞l;恄wn;挢cr;쀀𝒻ࢀEabcdefgijlnorstv₂₉₥₰₴⃰℃ℒℸ̗ℾ⅒↞Ā;lٍ₇;檌ƀcmpₐₕute;䇵maĀ;dₜ᳚䎳;檆reve;䄟Āiy₪₮rc;䄝;䐳ot;䄡Ȁ;lqsؾق₽ƀ;qsؾٌlanô٥Ȁ;cdl٥⃒⃥⃕c;檩otĀ;o⃜⃝檀Ā;l⃢⃣檂;檄Ā;e⃪⃭쀀⋛︀s;檔r;쀀𝔤Ā;gٳ؛mel;愷cy;䑓Ȁ;Eajٚℌℎℐ;檒;檥;檤ȀEaesℛℝ℩ℴ;扩pĀ;p℣ℤ檊rox»ℤĀ;q℮ℯ檈Ā;q℮ℛim;拧pf;쀀𝕘Āci⅃ⅆr;愊mƀ;el٫ⅎ⅐;檎;檐茀>;cdlqrⅠⅪⅮⅳⅹĀciⅥⅧ;檧r;橺ot;拗Par;榕uest;橼ʀadelsↄⅪ←ٖ↛ǰ↉\0proør;楸qĀlqؿ↖lesó₈ií٫Āen↣↭rtneqq;쀀≩︀Å↪ԀAabcefkosy⇄⇇⇱⇵⇺∘∝∯≨≽ròΠȀilmr⇐⇔⇗⇛rsðᒄf»․ilôکĀdr⇠⇤cy;䑊ƀ;cwࣴ⇫⇯ir;楈;憭ar;意irc;䄥ƀalr∁∎∓rtsĀ;u∉∊晥it»∊lip;怦con;抹r;쀀𝔥sĀew∣∩arow;椥arow;椦ʀamopr∺∾≃≞≣rr;懿tht;戻kĀlr≉≓eftarrow;憩ightarrow;憪f;쀀𝕙bar;怕ƀclt≯≴≸r;쀀𝒽asè⇴rok;䄧Ābp⊂⊇ull;恃hen»ᱛૡ⊣\0⊪\0⊸⋅⋎\0⋕⋳\0\0⋸⌢⍧⍢⍿\0⎆⎪⎴cute耻í䃭ƀ;iyݱ⊰⊵rc耻î䃮;䐸Ācx⊼⊿y;䐵cl耻¡䂡ĀfrΟ⋉;쀀𝔦rave耻ì䃬Ȁ;inoܾ⋝⋩⋮Āin⋢⋦nt;樌t;戭fin;槜ta;愩lig;䄳ƀaop⋾⌚⌝ƀcgt⌅⌈⌗r;䄫ƀelpܟ⌏⌓inåގarôܠh;䄱f;抷ed;䆵ʀ;cfotӴ⌬⌱⌽⍁are;愅inĀ;t⌸⌹戞ie;槝doô⌙ʀ;celpݗ⍌⍐⍛⍡al;抺Āgr⍕⍙eróᕣã⍍arhk;樗rod;樼Ȁcgpt⍯⍲⍶⍻y;䑑on;䄯f;쀀𝕚a;䎹uest耻¿䂿Āci⎊⎏r;쀀𝒾nʀ;EdsvӴ⎛⎝⎡ӳ;拹ot;拵Ā;v⎦⎧拴;拳Ā;iݷ⎮lde;䄩ǫ⎸\0⎼cy;䑖l耻ï䃯̀cfmosu⏌⏗⏜⏡⏧⏵Āiy⏑⏕rc;䄵;䐹r;쀀𝔧ath;䈷pf;쀀𝕛ǣ⏬\0⏱r;쀀𝒿rcy;䑘kcy;䑔Ѐacfghjos␋␖␢ppaĀ;v␓␔䎺;䏰Āey␛␠dil;䄷;䐺r;쀀𝔨reen;䄸cy;䑅cy;䑜pf;쀀𝕜cr;쀀𝓀ABEHabcdefghjlmnoprstuv⑰⒁⒆⒍⒑┎┽╚▀♎♞♥♹♽⚚⚲⛘❝❨➋⟀⠁⠒ƀart⑷⑺⑼ròòΕail;椛arr;椎Ā;gঔ⒋;檋ar;楢ॣ⒥\0⒪\0⒱\0\0\0\0\0⒵Ⓔ\0ⓆⓈⓍ\0⓹ute;䄺mptyv;榴raîࡌbda;䎻gƀ;dlࢎⓁⓃ;榑åࢎ;檅uo耻«䂫rЀ;bfhlpst࢙ⓞⓦⓩ⓫⓮⓱⓵Ā;f࢝ⓣs;椟s;椝ë≒p;憫l;椹im;楳l;憢ƀ;ae⓿─┄檫il;椙Ā;s┉┊檭;쀀⪭︀ƀabr┕┙┝rr;椌rk;杲Āak┢┬cĀek┨┪;䁻;䁛Āes┱┳;榋lĀdu┹┻;榏;榍Ȁaeuy╆╋╖╘ron;䄾Ādi═╔il;䄼ìࢰâ┩;䐻Ȁcqrs╣╦╭╽a;椶uoĀ;rนᝆĀdu╲╷har;楧shar;楋h;憲ʀ;fgqs▋▌উ◳◿扤tʀahlrt▘▤▷◂◨rrowĀ;t࢙□aé⓶arpoonĀdu▯▴own»њp»०eftarrows;懇ightƀahs◍◖◞rrowĀ;sࣴࢧarpoonóquigarro÷⇰hreetimes;拋ƀ;qs▋ও◺lanôবʀ;cdgsব☊☍☝☨c;檨otĀ;o☔☕橿Ā;r☚☛檁;檃Ā;e☢☥쀀⋚︀s;檓ʀadegs☳☹☽♉♋pproøⓆot;拖qĀgq♃♅ôউgtò⒌ôছiíলƀilr♕࣡♚sht;楼;쀀𝔩Ā;Eজ♣;檑š♩♶rĀdu▲♮Ā;l॥♳;楪lk;斄cy;䑙ʀ;achtੈ⚈⚋⚑⚖rò◁orneòᴈard;楫ri;旺Āio⚟⚤dot;䅀ustĀ;a⚬⚭掰che»⚭ȀEaes⚻⚽⛉⛔;扨pĀ;p⛃⛄檉rox»⛄Ā;q⛎⛏檇Ā;q⛎⚻im;拦Ѐabnoptwz⛩⛴⛷✚✯❁❇❐Ānr⛮⛱g;柬r;懽rëࣁgƀlmr⛿✍✔eftĀar০✇ightá৲apsto;柼ightá৽parrowĀlr✥✩efô⓭ight;憬ƀafl✶✹✽r;榅;쀀𝕝us;樭imes;樴š❋❏st;戗áፎƀ;ef❗❘᠀旊nge»❘arĀ;l❤❥䀨t;榓ʀachmt❳❶❼➅➇ròࢨorneòᶌarĀ;d➃;業;怎ri;抿̀achiqt➘➝ੀ➢➮➻quo;怹r;쀀𝓁mƀ;egল➪➬;檍;檏Ābu┪➳oĀ;rฟ➹;怚rok;䅂萀<;cdhilqrࠫ⟒☹⟜⟠⟥⟪⟰Āci⟗⟙;檦r;橹reå◲mes;拉arr;楶uest;橻ĀPi⟵⟹ar;榖ƀ;ef⠀भ旃rĀdu⠇⠍shar;楊har;楦Āen⠗⠡rtneqq;쀀≨︀Å⠞܀Dacdefhilnopsu⡀⡅⢂⢎⢓⢠⢥⢨⣚⣢⣤ઃ⣳⤂Dot;戺Ȁclpr⡎⡒⡣⡽r耻¯䂯Āet⡗⡙;時Ā;e⡞⡟朠se»⡟Ā;sျ⡨toȀ;dluျ⡳⡷⡻owîҌefôएðᏑker;斮Āoy⢇⢌mma;権;䐼ash;怔asuredangle»ᘦr;쀀𝔪o;愧ƀcdn⢯⢴⣉ro耻µ䂵Ȁ;acdᑤ⢽⣀⣄sôᚧir;櫰ot肻·Ƶusƀ;bd⣒ᤃ⣓戒Ā;uᴼ⣘;横ţ⣞⣡p;櫛ò−ðઁĀdp⣩⣮els;抧f;쀀𝕞Āct⣸⣽r;쀀𝓂pos»ᖝƀ;lm⤉⤊⤍䎼timap;抸ఀGLRVabcdefghijlmoprstuvw⥂⥓⥾⦉⦘⧚⧩⨕⨚⩘⩝⪃⪕⪤⪨⬄⬇⭄⭿⮮ⰴⱧⱼ⳩Āgt⥇⥋;쀀⋙̸Ā;v⥐쀀≫⃒ƀelt⥚⥲⥶ftĀar⥡⥧rrow;懍ightarrow;懎;쀀⋘̸Ā;v⥻ే쀀≪⃒ightarrow;懏ĀDd⦎⦓ash;抯ash;抮ʀbcnpt⦣⦧⦬⦱⧌la»˞ute;䅄g;쀀∠⃒ʀ;Eiop⦼⧀⧅⧈;쀀⩰̸d;쀀≋̸s;䅉roøurĀ;a⧓⧔普lĀ;s⧓ସdz⧟\0⧣p肻 ଷmpĀ;e௹ఀʀaeouy⧴⧾⨃⨐⨓ǰ⧹\0⧻;橃on;䅈dil;䅆ngĀ;dൾ⨊ot;쀀⩭̸p;橂;䐽ash;怓;Aadqsxஒ⨩⨭⨻⩁⩅⩐rr;懗rĀhr⨳⨶k;椤Ā;oᏲᏰot;쀀≐̸uiöୣĀei⩊⩎ar;椨íistĀ;sடr;쀀𝔫ȀEest⩦⩹⩼ƀ;qs⩭ƀ;qs⩴lanôií௪Ā;rஶ⪁»ஷƀAap⪊⪍⪑rò⥱rr;憮ar;櫲ƀ;svྍ⪜ྌĀ;d⪡⪢拼;拺cy;䑚AEadest⪷⪺⪾⫂⫅⫶⫹rò⥦;쀀≦̸rr;憚r;急Ȁ;fqs⫎⫣⫯tĀar⫔⫙rro÷⫁ightarro÷⪐ƀ;qs⪺⫪lanôౕĀ;sౕ⫴»శiíౝĀ;rవ⫾iĀ;eచథiäඐĀpt⬌⬑f;쀀𝕟膀¬;in⬙⬚⬶䂬nȀ;Edvஉ⬤⬨⬮;쀀⋹̸ot;쀀⋵̸ǡஉ⬳⬵;拷;拶iĀ;vಸ⬼ǡಸ⭁⭃;拾;拽ƀaor⭋⭣⭩rȀ;ast⭕⭚⭟lleìl;쀀⫽⃥;쀀∂̸lint;樔ƀ;ceಒ⭰⭳uåಥĀ;cಘ⭸Ā;eಒ⭽ñಘȀAait⮈⮋⮝⮧rò⦈rrƀ;cw⮔⮕⮙憛;쀀⤳̸;쀀↝̸ghtarrow»⮕riĀ;eೋೖchimpqu⮽⯍⯙⬄⯤⯯Ȁ;cerല⯆ഷ⯉uå;쀀𝓃ortɭ⬅\0\0⯖ará⭖mĀ;e൮⯟Ā;q൴൳suĀbp⯫⯭ååഋƀbcp⯶ⰑⰙȀ;Ees⯿ⰀഢⰄ抄;쀀⫅̸etĀ;eഛⰋqĀ;qണⰀcĀ;eലⰗñസȀ;EesⰢⰣൟⰧ抅;쀀⫆̸etĀ;e൘ⰮqĀ;qൠⰣȀgilrⰽⰿⱅⱇìௗlde耻ñ䃱çృiangleĀlrⱒⱜeftĀ;eచⱚñదightĀ;eೋⱥñĀ;mⱬⱭ䎽ƀ;esⱴⱵⱹ䀣ro;愖p;怇ҀDHadgilrsⲏⲔⲙⲞⲣⲰⲶⳓⳣash;抭arr;椄p;쀀≍⃒ash;抬ĀetⲨⲬ;쀀≥⃒;쀀>⃒nfin;槞ƀAetⲽⳁⳅrr;椂;쀀≤⃒Ā;rⳊⳍ쀀<⃒ie;쀀⊴⃒ĀAtⳘⳜrr;椃rie;쀀⊵⃒im;쀀∼⃒ƀAan⳰ⴂrr;懖rĀhr⳺⳽k;椣Ā;oᏧᏥear;椧ቓ᪕\0\0\0\0\0\0\0\0\0\0\0\0\0ⴭ\0ⴸⵈⵠⵥⶄᬇ\0\0ⶍⶫ\0ⷈⷎ\0ⷜ⸙⸫⸾⹃Ācsⴱ᪗ute耻ó䃳ĀiyⴼⵅrĀ;cⵂ耻ô䃴;䐾ʀabios᪠ⵒⵗLjⵚlac;䅑v;樸old;榼lig;䅓Ācrir;榿;쀀𝔬ͯ\0\0\0ⶂn;䋛ave耻ò䃲;槁Ābmⶈ෴ar;榵Ȁacitⶕⶥⶨrò᪀Āirⶠr;榾oss;榻nå๒;槀ƀaeiⶱⶵⶹcr;䅍ga;䏉ƀcdnⷀⷅǍron;䎿;榶pf;쀀𝕠ƀaelⷔǒr;榷rp;榹;adiosvⷪⷫⷮ⸈⸍⸐⸖戨rò᪆Ȁ;efmⷷⷸ⸂⸅橝rĀ;oⷾⷿ愴f»ⷿ耻ª䂪耻º䂺gof;抶r;橖lope;橗;橛ƀclo⸟⸡⸧ò⸁ash耻ø䃸l;折iŬⸯ⸴de耻õ䃵esĀ;aǛ⸺s;樶ml耻ö䃶bar;挽ૡ\0\0⺀⺝\0⺢⺹\0\0⻋ຜ\0⼓\0\0⼫⾼\0⿈rȀ;astЃ脀¶;l䂶leìЃɩ\0\0m;櫳;櫽y;䐿rʀcimpt⺋⺏⺓ᡥ⺗nt;䀥od;䀮il;怰enk;怱r;쀀𝔭ƀimo⺨⺰⺴Ā;v⺭⺮䏆;䏕maô੶ne;明ƀ;tv⺿⻀⻈䏀chfork»´;䏖Āau⻏⻟nĀck⻕⻝kĀ;h⇴⻛;愎ö⇴sҀ;abcdemst⻳ᤈ⼄⼆⼊⼎䀫cir;樣ir;樢Āouᵀ⼂;樥;橲n肻±ຝim;樦wo;樧ƀipu⼙⼠⼥ntint;樕f;쀀𝕡nd耻£䂣Ԁ;Eaceinosu່⼿⽁⽄⽇⾁⾉⾒⽾⾶;檳p;檷uå໙Ā;c໎⽌̀;acens່⽙⽟⽦⽨⽾pproø⽃urlyeñ໙ñ໎ƀaes⽯⽶⽺pprox;檹qq;檵im;拨iíໟmeĀ;s⾈ຮ怲ƀEas⽸⾐⽺ð⽵ƀdfp⾙⾯ƀals⾠⾥⾪lar;挮ine;挒urf;挓Ā;t⾴ïrel;抰Āci⿀⿅r;쀀𝓅;䏈ncsp;怈̀fiopsu⋢⿱r;쀀𝔮pf;쀀𝕢rime;恗cr;쀀𝓆ƀaeo⿸〉〓tĀei々rnionóڰnt;樖stĀ;e【】䀿ñἙô༔ABHabcdefhilmnoprstuxけさすムㄎㄫㅇㅢㅲㆎ㈆㈕㈤㈩㉘㉮㉲㊐㊰㊷ƀartぇおがròႳòϝail;検aròᱥar;楤cdenqrtとふへみわゔヌĀeuねぱ;쀀∽̱te;䅕iãᅮmptyv;榳gȀ;del࿑らるろ;榒;榥å࿑uo耻»䂻rր;abcfhlpstwガクシスゼゾダッデナp;極Ā;fゴs;椠;椳s;椞ë≝ð✮l;楅im;楴l;憣;憝Āaiパフil;椚oĀ;nホボ戶aló༞ƀabrョリヮrò៥rk;杳ĀakンヽcĀekヹ・;䁽;䁝Āes;榌lĀduㄊㄌ;榎;榐Ȁaeuyㄗㄜㄧㄩron;䅙Ādiㄡㄥil;䅗ìâヺ;䑀Ȁclqsㄴㄷㄽㅄa;椷dhar;楩uoĀ;rȎȍh;憳ƀacgㅎㅟངlȀ;ipsླྀㅘㅛႜnåႻarôྩt;断ƀilrㅩဣㅮsht;楽;쀀𝔯ĀaoㅷㆆrĀduㅽㅿ»ѻĀ;l႑ㆄ;楬Ā;vㆋㆌ䏁;䏱ƀgns㆕ㇹㇼht̀ahlrstㆤㆰ㇂㇘rrowĀ;tㆭaéトarpoonĀduㆻㆿowîㅾp»႒eftĀah㇊㇐rrowóarpoonóՑightarrows;應quigarro÷ニhreetimes;拌g;䋚ingdotseñἲƀahm㈍㈐㈓ròaòՑ;怏oustĀ;a㈞掱che»mid;櫮Ȁabpt㈲㈽㉀㉒Ānr㈷㈺g;柭r;懾rëဃƀafl㉇㉊㉎r;榆;쀀𝕣us;樮imes;樵Āap㉝㉧rĀ;g㉣㉤䀩t;榔olint;樒arò㇣Ȁachq㉻㊀Ⴜ㊅quo;怺r;쀀𝓇Ābu・㊊oĀ;rȔȓƀhir㊗㊛㊠reåㇸmes;拊iȀ;efl㊪ၙᠡ㊫方tri;槎luhar;楨;愞ൡ㋕㋛㋟㌬㌸㍱\0㍺㎤\0\0㏬㏰\0㐨㑈㑚㒭㒱㓊㓱\0㘖\0\0㘳cute;䅛quï➺Ԁ;Eaceinpsyᇭ㋳㋵㋿㌂㌋㌏㌟㌦㌩;檴ǰ㋺\0㋼;檸on;䅡uåᇾĀ;dᇳ㌇il;䅟rc;䅝ƀEas㌖㌘㌛;檶p;檺im;择olint;樓iíሄ;䑁otƀ;be㌴ᵇ㌵担;橦Aacmstx㍆㍊㍗㍛㍞㍣㍭rr;懘rĀhr㍐㍒ë∨Ā;oਸ਼t耻§䂧i;䀻war;椩mĀin㍩ðnuóñt;朶rĀ;o㍶⁕쀀𝔰Ȁacoy㎂㎆㎑㎠rp;景Āhy㎋㎏cy;䑉;䑈rtɭ㎙\0\0㎜iäᑤaraì耻䂭Āgm㎨㎴maƀ;fv㎱㎲㎲䏃;䏂Ѐ;deglnprካ㏅㏉㏎㏖㏞㏡㏦ot;橪Ā;qኰĀ;E㏓㏔檞;檠Ā;E㏛㏜檝;檟e;扆lus;樤arr;楲aròᄽȀaeit㏸㐈㐏㐗Āls㏽㐄lsetmé㍪hp;樳parsl;槤Ādlᑣ㐔e;挣Ā;e㐜㐝檪Ā;s㐢㐣檬;쀀⪬︀ƀflp㐮㐳㑂tcy;䑌Ā;b㐸㐹䀯Ā;a㐾㐿槄r;挿f;쀀𝕤aĀdr㑍ЂesĀ;u㑔㑕晠it»㑕ƀcsu㑠㑹㒟Āau㑥㑯pĀ;sᆈ㑫;쀀⊓︀pĀ;sᆴ㑵;쀀⊔︀uĀbp㑿㒏ƀ;esᆗᆜ㒆etĀ;eᆗ㒍ñᆝƀ;esᆨᆭ㒖etĀ;eᆨ㒝ñᆮƀ;afᅻ㒦ְrť㒫ֱ»ᅼaròᅈȀcemt㒹㒾㓂㓅r;쀀𝓈tmîñiì㐕aræᆾĀar㓎㓕rĀ;f㓔ឿ昆Āan㓚㓭ightĀep㓣㓪psiloîỠhé⺯s»⡒ʀbcmnp㓻㕞ሉ㖋㖎Ҁ;Edemnprs㔎㔏㔑㔕㔞㔣㔬㔱㔶抂;櫅ot;檽Ā;dᇚ㔚ot;櫃ult;櫁ĀEe㔨㔪;櫋;把lus;檿arr;楹ƀeiu㔽㕒㕕tƀ;en㔎㕅㕋qĀ;qᇚ㔏eqĀ;q㔫㔨m;櫇Ābp㕚㕜;櫕;櫓c̀;acensᇭ㕬㕲㕹㕻㌦pproø㋺urlyeñᇾñᇳƀaes㖂㖈㌛pproø㌚qñ㌗g;晪ڀ123;Edehlmnps㖩㖬㖯ሜ㖲㖴㗀㗉㗕㗚㗟㗨㗭耻¹䂹耻²䂲耻³䂳;櫆Āos㖹㖼t;檾ub;櫘Ā;dሢ㗅ot;櫄sĀou㗏㗒l;柉b;櫗arr;楻ult;櫂ĀEe㗤㗦;櫌;抋lus;櫀ƀeiu㗴㘉㘌tƀ;enሜ㗼㘂qĀ;qሢ㖲eqĀ;q㗧㗤m;櫈Ābp㘑㘓;櫔;櫖ƀAan㘜㘠㘭rr;懙rĀhr㘦㘨ë∮Ā;oਫwar;椪lig耻ß䃟㙑㙝㙠ዎ㙳㙹\0㙾㛂\0\0\0\0\0㛛㜃\0㜉㝬\0\0\0㞇ɲ㙖\0\0㙛get;挖;䏄rëƀaey㙦㙫㙰ron;䅥dil;䅣;䑂lrec;挕r;쀀𝔱Ȁeiko㚆㚝㚵㚼Dz㚋\0㚑eĀ4fኄኁaƀ;sv㚘㚙㚛䎸ym;䏑Ācn㚢㚲kĀas㚨㚮pproøim»ኬsðኞĀas㚺㚮ðrn耻þ䃾Ǭ̟㛆⋧es膀×;bd㛏㛐㛘䃗Ā;aᤏ㛕r;樱;樰ƀeps㛡㛣㜀á⩍Ȁ;bcf҆㛬㛰㛴ot;挶ir;櫱Ā;o㛹㛼쀀𝕥rk;櫚á㍢rime;怴ƀaip㜏㜒㝤dåቈadempst㜡㝍㝀㝑㝗㝜㝟ngleʀ;dlqr㜰㜱㜶㝀㝂斵own»ᶻeftĀ;e⠀㜾ñम;扜ightĀ;e㊪㝋ñၚot;旬inus;樺lus;樹b;槍ime;樻ezium;揢ƀcht㝲㝽㞁Āry㝷㝻;쀀𝓉;䑆cy;䑛rok;䅧Āio㞋㞎xôheadĀlr㞗㞠eftarro÷ࡏightarrow»ཝऀAHabcdfghlmoprstuw㟐㟓㟗㟤㟰㟼㠎㠜㠣㠴㡑㡝㡫㢩㣌㣒㣪㣶ròϭar;楣Ācr㟜㟢ute耻ú䃺òᅐrǣ㟪\0㟭y;䑞ve;䅭Āiy㟵㟺rc耻û䃻;䑃ƀabh㠃㠆㠋ròᎭlac;䅱aòᏃĀir㠓㠘sht;楾;쀀𝔲rave耻ù䃹š㠧㠱rĀlr㠬㠮»ॗ»ႃlk;斀Āct㠹㡍ɯ㠿\0\0㡊rnĀ;e㡅㡆挜r»㡆op;挏ri;旸Āal㡖㡚cr;䅫肻¨͉Āgp㡢㡦on;䅳f;쀀𝕦̀adhlsuᅋ㡸㡽፲㢑㢠ownáᎳarpoonĀlr㢈㢌efô㠭ighô㠯iƀ;hl㢙㢚㢜䏅»ᏺon»㢚parrows;懈ƀcit㢰㣄㣈ɯ㢶\0\0㣁rnĀ;e㢼㢽挝r»㢽op;挎ng;䅯ri;旹cr;쀀𝓊ƀdir㣙㣝㣢ot;拰lde;䅩iĀ;f㜰㣨»᠓Āam㣯㣲rò㢨l耻ü䃼angle;榧ހABDacdeflnoprsz㤜㤟㤩㤭㦵㦸㦽㧟㧤㧨㧳㧹㧽㨁㨠ròϷarĀ;v㤦㤧櫨;櫩asèϡĀnr㤲㤷grt;榜eknprst㓣㥆㥋㥒㥝㥤㦖appá␕othinçẖƀhir㓫⻈㥙opô⾵Ā;hᎷ㥢ïㆍĀiu㥩㥭gmá㎳Ābp㥲㦄setneqĀ;q㥽㦀쀀⊊︀;쀀⫋︀setneqĀ;q㦏㦒쀀⊋︀;쀀⫌︀Āhr㦛㦟etá㚜iangleĀlr㦪㦯eft»थight»ၑy;䐲ash»ံƀelr㧄㧒㧗ƀ;beⷪ㧋㧏ar;抻q;扚lip;拮Ābt㧜ᑨaòᑩr;쀀𝔳tré㦮suĀbp㧯㧱»ജ»൙pf;쀀𝕧roðtré㦴Ācu㨆㨋r;쀀𝓋Ābp㨐㨘nĀEe㦀㨖»㥾nĀEe㦒㨞»㦐igzag;榚cefoprs㨶㨻㩖㩛㩔㩡㩪irc;䅵Ādi㩀㩑Ābg㩅㩉ar;機eĀ;qᗺ㩏;扙erp;愘r;쀀𝔴pf;쀀𝕨Ā;eᑹ㩦atèᑹcr;쀀𝓌ૣណ㪇\0㪋\0㪐㪛\0\0㪝㪨㪫㪯\0\0㫃㫎\0㫘ៜtré៑r;쀀𝔵ĀAa㪔㪗ròσrò৶;䎾ĀAa㪡㪤ròθrò৫að✓is;拻ƀdptឤ㪵㪾Āfl㪺ឩ;쀀𝕩imåឲĀAa㫇㫊ròώròਁĀcq㫒ីr;쀀𝓍Āpt៖㫜ré។Ѐacefiosu㫰㫽㬈㬌㬑㬕㬛㬡cĀuy㫶㫻te耻ý䃽;䑏Āiy㬂㬆rc;䅷;䑋n耻¥䂥r;쀀𝔶cy;䑗pf;쀀𝕪cr;쀀𝓎Ācm㬦㬩y;䑎l耻ÿ䃿Ԁacdefhiosw㭂㭈㭔㭘㭤㭩㭭㭴㭺㮀cute;䅺Āay㭍㭒ron;䅾;䐷ot;䅼Āet㭝㭡træᕟa;䎶r;쀀𝔷cy;䐶grarr;懝pf;쀀𝕫cr;쀀𝓏Ājn㮅㮇;怍j;怌'.split("").map(e=>e.charCodeAt(0))),ch=new Map([[0,65533],[128,8364],[130,8218],[131,402],[132,8222],[133,8230],[134,8224],[135,8225],[136,710],[137,8240],[138,352],[139,8249],[140,338],[142,381],[145,8216],[146,8217],[147,8220],[148,8221],[149,8226],[150,8211],[151,8212],[152,732],[153,8482],[154,353],[155,8250],[156,339],[158,382],[159,376]]);function dh(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=ch.get(e))!==null&&t!==void 0?t:e}var Ne;(function(e){e[e.NUM=35]="NUM",e[e.SEMI=59]="SEMI",e[e.EQUALS=61]="EQUALS",e[e.ZERO=48]="ZERO",e[e.NINE=57]="NINE",e[e.LOWER_A=97]="LOWER_A",e[e.LOWER_F=102]="LOWER_F",e[e.LOWER_X=120]="LOWER_X",e[e.LOWER_Z=122]="LOWER_Z",e[e.UPPER_A=65]="UPPER_A",e[e.UPPER_F=70]="UPPER_F",e[e.UPPER_Z=90]="UPPER_Z"})(Ne||(Ne={}));const fh=32;var Nt;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(Nt||(Nt={}));function aa(e){return e>=Ne.ZERO&&e<=Ne.NINE}function hh(e){return e>=Ne.UPPER_A&&e<=Ne.UPPER_F||e>=Ne.LOWER_A&&e<=Ne.LOWER_F}function ph(e){return e>=Ne.UPPER_A&&e<=Ne.UPPER_Z||e>=Ne.LOWER_A&&e<=Ne.LOWER_Z||aa(e)}function mh(e){return e===Ne.EQUALS||ph(e)}var ve;(function(e){e[e.EntityStart=0]="EntityStart",e[e.NumericStart=1]="NumericStart",e[e.NumericDecimal=2]="NumericDecimal",e[e.NumericHex=3]="NumericHex",e[e.NamedEntity=4]="NamedEntity"})(ve||(ve={}));var Tt;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(Tt||(Tt={}));class gh{constructor(t,n,r){this.decodeTree=t,this.emitCodePoint=n,this.errors=r,this.state=ve.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=Tt.Strict}startEntity(t){this.decodeMode=t,this.state=ve.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(t,n){switch(this.state){case ve.EntityStart:return t.charCodeAt(n)===Ne.NUM?(this.state=ve.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=ve.NamedEntity,this.stateNamedEntity(t,n));case ve.NumericStart:return this.stateNumericStart(t,n);case ve.NumericDecimal:return this.stateNumericDecimal(t,n);case ve.NumericHex:return this.stateNumericHex(t,n);case ve.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|fh)===Ne.LOWER_X?(this.state=ve.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=ve.NumericDecimal,this.stateNumericDecimal(t,n))}addToNumericResult(t,n,r,i){if(n!==r){const a=r-n;this.result=this.result*Math.pow(i,a)+Number.parseInt(t.substr(n,a),i),this.consumed+=a}}stateNumericHex(t,n){const r=n;for(;n<t.length;){const i=t.charCodeAt(n);if(aa(i)||hh(i))n+=1;else return this.addToNumericResult(t,r,n,16),this.emitNumericEntity(i,3)}return this.addToNumericResult(t,r,n,16),-1}stateNumericDecimal(t,n){const r=n;for(;n<t.length;){const i=t.charCodeAt(n);if(aa(i))n+=1;else return this.addToNumericResult(t,r,n,10),this.emitNumericEntity(i,2)}return this.addToNumericResult(t,r,n,10),-1}emitNumericEntity(t,n){var r;if(this.consumed<=n)return(r=this.errors)===null||r===void 0||r.absenceOfDigitsInNumericCharacterReference(this.consumed),0;if(t===Ne.SEMI)this.consumed+=1;else if(this.decodeMode===Tt.Strict)return 0;return this.emitCodePoint(dh(this.result),this.consumed),this.errors&&(t!==Ne.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(t,n){const{decodeTree:r}=this;let i=r[this.treeIndex],a=(i&Nt.VALUE_LENGTH)>>14;for(;n<t.length;n++,this.excess++){const s=t.charCodeAt(n);if(this.treeIndex=bh(r,i,this.treeIndex+Math.max(1,a),s),this.treeIndex<0)return this.result===0||this.decodeMode===Tt.Attribute&&(a===0||mh(s))?0:this.emitNotTerminatedNamedEntity();if(i=r[this.treeIndex],a=(i&Nt.VALUE_LENGTH)>>14,a!==0){if(s===Ne.SEMI)return this.emitNamedEntityData(this.treeIndex,a,this.consumed+this.excess);this.decodeMode!==Tt.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1}emitNotTerminatedNamedEntity(){var t;const{result:n,decodeTree:r}=this,i=(r[n]&Nt.VALUE_LENGTH)>>14;return this.emitNamedEntityData(n,i,this.consumed),(t=this.errors)===null||t===void 0||t.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(t,n,r){const{decodeTree:i}=this;return this.emitCodePoint(n===1?i[t]&~Nt.VALUE_LENGTH:i[t+1],r),n===3&&this.emitCodePoint(i[t+2],r),r}end(){var t;switch(this.state){case ve.NamedEntity:return this.result!==0&&(this.decodeMode!==Tt.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case ve.NumericDecimal:return this.emitNumericEntity(0,2);case ve.NumericHex:return this.emitNumericEntity(0,3);case ve.NumericStart:return(t=this.errors)===null||t===void 0||t.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case ve.EntityStart:return 0}}}function bh(e,t,n,r){const i=(t&Nt.BRANCH_LENGTH)>>7,a=t&Nt.JUMP_TABLE;if(i===0)return a!==0&&r===a?n:-1;if(a){const u=r-a;return u<0||u>=i?-1:e[n+u]-1}let s=n,o=s+i-1;for(;s<=o;){const u=s+o>>>1,c=e[u];if(c<r)s=u+1;else if(c>r)o=u-1;else return e[u+i]}return-1}var O;(function(e){e.HTML="http://www.w3.org/1999/xhtml",e.MATHML="http://www.w3.org/1998/Math/MathML",e.SVG="http://www.w3.org/2000/svg",e.XLINK="http://www.w3.org/1999/xlink",e.XML="http://www.w3.org/XML/1998/namespace",e.XMLNS="http://www.w3.org/2000/xmlns/"})(O||(O={}));var Wt;(function(e){e.TYPE="type",e.ACTION="action",e.ENCODING="encoding",e.PROMPT="prompt",e.NAME="name",e.COLOR="color",e.FACE="face",e.SIZE="size"})(Wt||(Wt={}));var rt;(function(e){e.NO_QUIRKS="no-quirks",e.QUIRKS="quirks",e.LIMITED_QUIRKS="limited-quirks"})(rt||(rt={}));var N;(function(e){e.A="a",e.ADDRESS="address",e.ANNOTATION_XML="annotation-xml",e.APPLET="applet",e.AREA="area",e.ARTICLE="article",e.ASIDE="aside",e.B="b",e.BASE="base",e.BASEFONT="basefont",e.BGSOUND="bgsound",e.BIG="big",e.BLOCKQUOTE="blockquote",e.BODY="body",e.BR="br",e.BUTTON="button",e.CAPTION="caption",e.CENTER="center",e.CODE="code",e.COL="col",e.COLGROUP="colgroup",e.DD="dd",e.DESC="desc",e.DETAILS="details",e.DIALOG="dialog",e.DIR="dir",e.DIV="div",e.DL="dl",e.DT="dt",e.EM="em",e.EMBED="embed",e.FIELDSET="fieldset",e.FIGCAPTION="figcaption",e.FIGURE="figure",e.FONT="font",e.FOOTER="footer",e.FOREIGN_OBJECT="foreignObject",e.FORM="form",e.FRAME="frame",e.FRAMESET="frameset",e.H1="h1",e.H2="h2",e.H3="h3",e.H4="h4",e.H5="h5",e.H6="h6",e.HEAD="head",e.HEADER="header",e.HGROUP="hgroup",e.HR="hr",e.HTML="html",e.I="i",e.IMG="img",e.IMAGE="image",e.INPUT="input",e.IFRAME="iframe",e.KEYGEN="keygen",e.LABEL="label",e.LI="li",e.LINK="link",e.LISTING="listing",e.MAIN="main",e.MALIGNMARK="malignmark",e.MARQUEE="marquee",e.MATH="math",e.MENU="menu",e.META="meta",e.MGLYPH="mglyph",e.MI="mi",e.MO="mo",e.MN="mn",e.MS="ms",e.MTEXT="mtext",e.NAV="nav",e.NOBR="nobr",e.NOFRAMES="noframes",e.NOEMBED="noembed",e.NOSCRIPT="noscript",e.OBJECT="object",e.OL="ol",e.OPTGROUP="optgroup",e.OPTION="option",e.P="p",e.PARAM="param",e.PLAINTEXT="plaintext",e.PRE="pre",e.RB="rb",e.RP="rp",e.RT="rt",e.RTC="rtc",e.RUBY="ruby",e.S="s",e.SCRIPT="script",e.SEARCH="search",e.SECTION="section",e.SELECT="select",e.SOURCE="source",e.SMALL="small",e.SPAN="span",e.STRIKE="strike",e.STRONG="strong",e.STYLE="style",e.SUB="sub",e.SUMMARY="summary",e.SUP="sup",e.TABLE="table",e.TBODY="tbody",e.TEMPLATE="template",e.TEXTAREA="textarea",e.TFOOT="tfoot",e.TD="td",e.TH="th",e.THEAD="thead",e.TITLE="title",e.TR="tr",e.TRACK="track",e.TT="tt",e.U="u",e.UL="ul",e.SVG="svg",e.VAR="var",e.WBR="wbr",e.XMP="xmp"})(N||(N={}));var l;(function(e){e[e.UNKNOWN=0]="UNKNOWN",e[e.A=1]="A",e[e.ADDRESS=2]="ADDRESS",e[e.ANNOTATION_XML=3]="ANNOTATION_XML",e[e.APPLET=4]="APPLET",e[e.AREA=5]="AREA",e[e.ARTICLE=6]="ARTICLE",e[e.ASIDE=7]="ASIDE",e[e.B=8]="B",e[e.BASE=9]="BASE",e[e.BASEFONT=10]="BASEFONT",e[e.BGSOUND=11]="BGSOUND",e[e.BIG=12]="BIG",e[e.BLOCKQUOTE=13]="BLOCKQUOTE",e[e.BODY=14]="BODY",e[e.BR=15]="BR",e[e.BUTTON=16]="BUTTON",e[e.CAPTION=17]="CAPTION",e[e.CENTER=18]="CENTER",e[e.CODE=19]="CODE",e[e.COL=20]="COL",e[e.COLGROUP=21]="COLGROUP",e[e.DD=22]="DD",e[e.DESC=23]="DESC",e[e.DETAILS=24]="DETAILS",e[e.DIALOG=25]="DIALOG",e[e.DIR=26]="DIR",e[e.DIV=27]="DIV",e[e.DL=28]="DL",e[e.DT=29]="DT",e[e.EM=30]="EM",e[e.EMBED=31]="EMBED",e[e.FIELDSET=32]="FIELDSET",e[e.FIGCAPTION=33]="FIGCAPTION",e[e.FIGURE=34]="FIGURE",e[e.FONT=35]="FONT",e[e.FOOTER=36]="FOOTER",e[e.FOREIGN_OBJECT=37]="FOREIGN_OBJECT",e[e.FORM=38]="FORM",e[e.FRAME=39]="FRAME",e[e.FRAMESET=40]="FRAMESET",e[e.H1=41]="H1",e[e.H2=42]="H2",e[e.H3=43]="H3",e[e.H4=44]="H4",e[e.H5=45]="H5",e[e.H6=46]="H6",e[e.HEAD=47]="HEAD",e[e.HEADER=48]="HEADER",e[e.HGROUP=49]="HGROUP",e[e.HR=50]="HR",e[e.HTML=51]="HTML",e[e.I=52]="I",e[e.IMG=53]="IMG",e[e.IMAGE=54]="IMAGE",e[e.INPUT=55]="INPUT",e[e.IFRAME=56]="IFRAME",e[e.KEYGEN=57]="KEYGEN",e[e.LABEL=58]="LABEL",e[e.LI=59]="LI",e[e.LINK=60]="LINK",e[e.LISTING=61]="LISTING",e[e.MAIN=62]="MAIN",e[e.MALIGNMARK=63]="MALIGNMARK",e[e.MARQUEE=64]="MARQUEE",e[e.MATH=65]="MATH",e[e.MENU=66]="MENU",e[e.META=67]="META",e[e.MGLYPH=68]="MGLYPH",e[e.MI=69]="MI",e[e.MO=70]="MO",e[e.MN=71]="MN",e[e.MS=72]="MS",e[e.MTEXT=73]="MTEXT",e[e.NAV=74]="NAV",e[e.NOBR=75]="NOBR",e[e.NOFRAMES=76]="NOFRAMES",e[e.NOEMBED=77]="NOEMBED",e[e.NOSCRIPT=78]="NOSCRIPT",e[e.OBJECT=79]="OBJECT",e[e.OL=80]="OL",e[e.OPTGROUP=81]="OPTGROUP",e[e.OPTION=82]="OPTION",e[e.P=83]="P",e[e.PARAM=84]="PARAM",e[e.PLAINTEXT=85]="PLAINTEXT",e[e.PRE=86]="PRE",e[e.RB=87]="RB",e[e.RP=88]="RP",e[e.RT=89]="RT",e[e.RTC=90]="RTC",e[e.RUBY=91]="RUBY",e[e.S=92]="S",e[e.SCRIPT=93]="SCRIPT",e[e.SEARCH=94]="SEARCH",e[e.SECTION=95]="SECTION",e[e.SELECT=96]="SELECT",e[e.SOURCE=97]="SOURCE",e[e.SMALL=98]="SMALL",e[e.SPAN=99]="SPAN",e[e.STRIKE=100]="STRIKE",e[e.STRONG=101]="STRONG",e[e.STYLE=102]="STYLE",e[e.SUB=103]="SUB",e[e.SUMMARY=104]="SUMMARY",e[e.SUP=105]="SUP",e[e.TABLE=106]="TABLE",e[e.TBODY=107]="TBODY",e[e.TEMPLATE=108]="TEMPLATE",e[e.TEXTAREA=109]="TEXTAREA",e[e.TFOOT=110]="TFOOT",e[e.TD=111]="TD",e[e.TH=112]="TH",e[e.THEAD=113]="THEAD",e[e.TITLE=114]="TITLE",e[e.TR=115]="TR",e[e.TRACK=116]="TRACK",e[e.TT=117]="TT",e[e.U=118]="U",e[e.UL=119]="UL",e[e.SVG=120]="SVG",e[e.VAR=121]="VAR",e[e.WBR=122]="WBR",e[e.XMP=123]="XMP"})(l||(l={}));const Eh=new Map([[N.A,l.A],[N.ADDRESS,l.ADDRESS],[N.ANNOTATION_XML,l.ANNOTATION_XML],[N.APPLET,l.APPLET],[N.AREA,l.AREA],[N.ARTICLE,l.ARTICLE],[N.ASIDE,l.ASIDE],[N.B,l.B],[N.BASE,l.BASE],[N.BASEFONT,l.BASEFONT],[N.BGSOUND,l.BGSOUND],[N.BIG,l.BIG],[N.BLOCKQUOTE,l.BLOCKQUOTE],[N.BODY,l.BODY],[N.BR,l.BR],[N.BUTTON,l.BUTTON],[N.CAPTION,l.CAPTION],[N.CENTER,l.CENTER],[N.CODE,l.CODE],[N.COL,l.COL],[N.COLGROUP,l.COLGROUP],[N.DD,l.DD],[N.DESC,l.DESC],[N.DETAILS,l.DETAILS],[N.DIALOG,l.DIALOG],[N.DIR,l.DIR],[N.DIV,l.DIV],[N.DL,l.DL],[N.DT,l.DT],[N.EM,l.EM],[N.EMBED,l.EMBED],[N.FIELDSET,l.FIELDSET],[N.FIGCAPTION,l.FIGCAPTION],[N.FIGURE,l.FIGURE],[N.FONT,l.FONT],[N.FOOTER,l.FOOTER],[N.FOREIGN_OBJECT,l.FOREIGN_OBJECT],[N.FORM,l.FORM],[N.FRAME,l.FRAME],[N.FRAMESET,l.FRAMESET],[N.H1,l.H1],[N.H2,l.H2],[N.H3,l.H3],[N.H4,l.H4],[N.H5,l.H5],[N.H6,l.H6],[N.HEAD,l.HEAD],[N.HEADER,l.HEADER],[N.HGROUP,l.HGROUP],[N.HR,l.HR],[N.HTML,l.HTML],[N.I,l.I],[N.IMG,l.IMG],[N.IMAGE,l.IMAGE],[N.INPUT,l.INPUT],[N.IFRAME,l.IFRAME],[N.KEYGEN,l.KEYGEN],[N.LABEL,l.LABEL],[N.LI,l.LI],[N.LINK,l.LINK],[N.LISTING,l.LISTING],[N.MAIN,l.MAIN],[N.MALIGNMARK,l.MALIGNMARK],[N.MARQUEE,l.MARQUEE],[N.MATH,l.MATH],[N.MENU,l.MENU],[N.META,l.META],[N.MGLYPH,l.MGLYPH],[N.MI,l.MI],[N.MO,l.MO],[N.MN,l.MN],[N.MS,l.MS],[N.MTEXT,l.MTEXT],[N.NAV,l.NAV],[N.NOBR,l.NOBR],[N.NOFRAMES,l.NOFRAMES],[N.NOEMBED,l.NOEMBED],[N.NOSCRIPT,l.NOSCRIPT],[N.OBJECT,l.OBJECT],[N.OL,l.OL],[N.OPTGROUP,l.OPTGROUP],[N.OPTION,l.OPTION],[N.P,l.P],[N.PARAM,l.PARAM],[N.PLAINTEXT,l.PLAINTEXT],[N.PRE,l.PRE],[N.RB,l.RB],[N.RP,l.RP],[N.RT,l.RT],[N.RTC,l.RTC],[N.RUBY,l.RUBY],[N.S,l.S],[N.SCRIPT,l.SCRIPT],[N.SEARCH,l.SEARCH],[N.SECTION,l.SECTION],[N.SELECT,l.SELECT],[N.SOURCE,l.SOURCE],[N.SMALL,l.SMALL],[N.SPAN,l.SPAN],[N.STRIKE,l.STRIKE],[N.STRONG,l.STRONG],[N.STYLE,l.STYLE],[N.SUB,l.SUB],[N.SUMMARY,l.SUMMARY],[N.SUP,l.SUP],[N.TABLE,l.TABLE],[N.TBODY,l.TBODY],[N.TEMPLATE,l.TEMPLATE],[N.TEXTAREA,l.TEXTAREA],[N.TFOOT,l.TFOOT],[N.TD,l.TD],[N.TH,l.TH],[N.THEAD,l.THEAD],[N.TITLE,l.TITLE],[N.TR,l.TR],[N.TRACK,l.TRACK],[N.TT,l.TT],[N.U,l.U],[N.UL,l.UL],[N.SVG,l.SVG],[N.VAR,l.VAR],[N.WBR,l.WBR],[N.XMP,l.XMP]]);function gn(e){var t;return(t=Eh.get(e))!==null&&t!==void 0?t:l.UNKNOWN}const M=l,Th={[O.HTML]:new Set([M.ADDRESS,M.APPLET,M.AREA,M.ARTICLE,M.ASIDE,M.BASE,M.BASEFONT,M.BGSOUND,M.BLOCKQUOTE,M.BODY,M.BR,M.BUTTON,M.CAPTION,M.CENTER,M.COL,M.COLGROUP,M.DD,M.DETAILS,M.DIR,M.DIV,M.DL,M.DT,M.EMBED,M.FIELDSET,M.FIGCAPTION,M.FIGURE,M.FOOTER,M.FORM,M.FRAME,M.FRAMESET,M.H1,M.H2,M.H3,M.H4,M.H5,M.H6,M.HEAD,M.HEADER,M.HGROUP,M.HR,M.HTML,M.IFRAME,M.IMG,M.INPUT,M.LI,M.LINK,M.LISTING,M.MAIN,M.MARQUEE,M.MENU,M.META,M.NAV,M.NOEMBED,M.NOFRAMES,M.NOSCRIPT,M.OBJECT,M.OL,M.P,M.PARAM,M.PLAINTEXT,M.PRE,M.SCRIPT,M.SECTION,M.SELECT,M.SOURCE,M.STYLE,M.SUMMARY,M.TABLE,M.TBODY,M.TD,M.TEMPLATE,M.TEXTAREA,M.TFOOT,M.TH,M.THEAD,M.TITLE,M.TR,M.TRACK,M.UL,M.WBR,M.XMP]),[O.MATHML]:new Set([M.MI,M.MO,M.MN,M.MS,M.MTEXT,M.ANNOTATION_XML]),[O.SVG]:new Set([M.TITLE,M.FOREIGN_OBJECT,M.DESC]),[O.XLINK]:new Set,[O.XML]:new Set,[O.XMLNS]:new Set},sa=new Set([M.H1,M.H2,M.H3,M.H4,M.H5,M.H6]);var E;(function(e){e[e.DATA=0]="DATA",e[e.RCDATA=1]="RCDATA",e[e.RAWTEXT=2]="RAWTEXT",e[e.SCRIPT_DATA=3]="SCRIPT_DATA",e[e.PLAINTEXT=4]="PLAINTEXT",e[e.TAG_OPEN=5]="TAG_OPEN",e[e.END_TAG_OPEN=6]="END_TAG_OPEN",e[e.TAG_NAME=7]="TAG_NAME",e[e.RCDATA_LESS_THAN_SIGN=8]="RCDATA_LESS_THAN_SIGN",e[e.RCDATA_END_TAG_OPEN=9]="RCDATA_END_TAG_OPEN",e[e.RCDATA_END_TAG_NAME=10]="RCDATA_END_TAG_NAME",e[e.RAWTEXT_LESS_THAN_SIGN=11]="RAWTEXT_LESS_THAN_SIGN",e[e.RAWTEXT_END_TAG_OPEN=12]="RAWTEXT_END_TAG_OPEN",e[e.RAWTEXT_END_TAG_NAME=13]="RAWTEXT_END_TAG_NAME",e[e.SCRIPT_DATA_LESS_THAN_SIGN=14]="SCRIPT_DATA_LESS_THAN_SIGN",e[e.SCRIPT_DATA_END_TAG_OPEN=15]="SCRIPT_DATA_END_TAG_OPEN",e[e.SCRIPT_DATA_END_TAG_NAME=16]="SCRIPT_DATA_END_TAG_NAME",e[e.SCRIPT_DATA_ESCAPE_START=17]="SCRIPT_DATA_ESCAPE_START",e[e.SCRIPT_DATA_ESCAPE_START_DASH=18]="SCRIPT_DATA_ESCAPE_START_DASH",e[e.SCRIPT_DATA_ESCAPED=19]="SCRIPT_DATA_ESCAPED",e[e.SCRIPT_DATA_ESCAPED_DASH=20]="SCRIPT_DATA_ESCAPED_DASH",e[e.SCRIPT_DATA_ESCAPED_DASH_DASH=21]="SCRIPT_DATA_ESCAPED_DASH_DASH",e[e.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN=22]="SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN",e[e.SCRIPT_DATA_ESCAPED_END_TAG_OPEN=23]="SCRIPT_DATA_ESCAPED_END_TAG_OPEN",e[e.SCRIPT_DATA_ESCAPED_END_TAG_NAME=24]="SCRIPT_DATA_ESCAPED_END_TAG_NAME",e[e.SCRIPT_DATA_DOUBLE_ESCAPE_START=25]="SCRIPT_DATA_DOUBLE_ESCAPE_START",e[e.SCRIPT_DATA_DOUBLE_ESCAPED=26]="SCRIPT_DATA_DOUBLE_ESCAPED",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH=27]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH=28]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN=29]="SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN",e[e.SCRIPT_DATA_DOUBLE_ESCAPE_END=30]="SCRIPT_DATA_DOUBLE_ESCAPE_END",e[e.BEFORE_ATTRIBUTE_NAME=31]="BEFORE_ATTRIBUTE_NAME",e[e.ATTRIBUTE_NAME=32]="ATTRIBUTE_NAME",e[e.AFTER_ATTRIBUTE_NAME=33]="AFTER_ATTRIBUTE_NAME",e[e.BEFORE_ATTRIBUTE_VALUE=34]="BEFORE_ATTRIBUTE_VALUE",e[e.ATTRIBUTE_VALUE_DOUBLE_QUOTED=35]="ATTRIBUTE_VALUE_DOUBLE_QUOTED",e[e.ATTRIBUTE_VALUE_SINGLE_QUOTED=36]="ATTRIBUTE_VALUE_SINGLE_QUOTED",e[e.ATTRIBUTE_VALUE_UNQUOTED=37]="ATTRIBUTE_VALUE_UNQUOTED",e[e.AFTER_ATTRIBUTE_VALUE_QUOTED=38]="AFTER_ATTRIBUTE_VALUE_QUOTED",e[e.SELF_CLOSING_START_TAG=39]="SELF_CLOSING_START_TAG",e[e.BOGUS_COMMENT=40]="BOGUS_COMMENT",e[e.MARKUP_DECLARATION_OPEN=41]="MARKUP_DECLARATION_OPEN",e[e.COMMENT_START=42]="COMMENT_START",e[e.COMMENT_START_DASH=43]="COMMENT_START_DASH",e[e.COMMENT=44]="COMMENT",e[e.COMMENT_LESS_THAN_SIGN=45]="COMMENT_LESS_THAN_SIGN",e[e.COMMENT_LESS_THAN_SIGN_BANG=46]="COMMENT_LESS_THAN_SIGN_BANG",e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH=47]="COMMENT_LESS_THAN_SIGN_BANG_DASH",e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH=48]="COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH",e[e.COMMENT_END_DASH=49]="COMMENT_END_DASH",e[e.COMMENT_END=50]="COMMENT_END",e[e.COMMENT_END_BANG=51]="COMMENT_END_BANG",e[e.DOCTYPE=52]="DOCTYPE",e[e.BEFORE_DOCTYPE_NAME=53]="BEFORE_DOCTYPE_NAME",e[e.DOCTYPE_NAME=54]="DOCTYPE_NAME",e[e.AFTER_DOCTYPE_NAME=55]="AFTER_DOCTYPE_NAME",e[e.AFTER_DOCTYPE_PUBLIC_KEYWORD=56]="AFTER_DOCTYPE_PUBLIC_KEYWORD",e[e.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER=57]="BEFORE_DOCTYPE_PUBLIC_IDENTIFIER",e[e.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED=58]="DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED",e[e.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED=59]="DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED",e[e.AFTER_DOCTYPE_PUBLIC_IDENTIFIER=60]="AFTER_DOCTYPE_PUBLIC_IDENTIFIER",e[e.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS=61]="BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS",e[e.AFTER_DOCTYPE_SYSTEM_KEYWORD=62]="AFTER_DOCTYPE_SYSTEM_KEYWORD",e[e.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER=63]="BEFORE_DOCTYPE_SYSTEM_IDENTIFIER",e[e.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED=64]="DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED",e[e.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED=65]="DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED",e[e.AFTER_DOCTYPE_SYSTEM_IDENTIFIER=66]="AFTER_DOCTYPE_SYSTEM_IDENTIFIER",e[e.BOGUS_DOCTYPE=67]="BOGUS_DOCTYPE",e[e.CDATA_SECTION=68]="CDATA_SECTION",e[e.CDATA_SECTION_BRACKET=69]="CDATA_SECTION_BRACKET",e[e.CDATA_SECTION_END=70]="CDATA_SECTION_END",e[e.CHARACTER_REFERENCE=71]="CHARACTER_REFERENCE",e[e.AMBIGUOUS_AMPERSAND=72]="AMBIGUOUS_AMPERSAND"})(E||(E={}));const Ae={DATA:E.DATA,RCDATA:E.RCDATA,RAWTEXT:E.RAWTEXT,SCRIPT_DATA:E.SCRIPT_DATA,PLAINTEXT:E.PLAINTEXT,CDATA_SECTION:E.CDATA_SECTION};function _h(e){return e>=g.DIGIT_0&&e<=g.DIGIT_9}function zn(e){return e>=g.LATIN_CAPITAL_A&&e<=g.LATIN_CAPITAL_Z}function kh(e){return e>=g.LATIN_SMALL_A&&e<=g.LATIN_SMALL_Z}function vt(e){return kh(e)||zn(e)}function su(e){return vt(e)||_h(e)}function Fr(e){return e+32}function ou(e){return e===g.SPACE||e===g.LINE_FEED||e===g.TABULATION||e===g.FORM_FEED}function uu(e){return ou(e)||e===g.SOLIDUS||e===g.GREATER_THAN_SIGN}function xh(e){return e===g.NULL?v.nullCharacterReference:e>1114111?v.characterReferenceOutsideUnicodeRange:nu(e)?v.surrogateCharacterReference:iu(e)?v.noncharacterCharacterReference:ru(e)||e===g.CARRIAGE_RETURN?v.controlCharacterReference:null}class yh{constructor(t,n){this.options=t,this.handler=n,this.paused=!1,this.inLoop=!1,this.inForeignNode=!1,this.lastStartTagName="",this.active=!1,this.state=E.DATA,this.returnState=E.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new uh(n),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new gh(lh,(r,i)=>{this.preprocessor.pos=this.entityStartPos+i-1,this._flushCodePointConsumedAsCharacterReference(r)},n.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(v.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:r=>{this._err(v.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+r)},validateNumericCharacterReference:r=>{const i=xh(r);i&&this._err(i,1)}}:void 0)}_err(t,n=0){var r,i;(i=(r=this.handler).onParseError)===null||i===void 0||i.call(r,this.preprocessor.getError(t,n))}getCurrentLocation(t){return this.options.sourceCodeLocationInfo?{startLine:this.preprocessor.line,startCol:this.preprocessor.col-t,startOffset:this.preprocessor.offset-t,endLine:-1,endCol:-1,endOffset:-1}:null}_runParsingLoop(){if(!this.inLoop){for(this.inLoop=!0;this.active&&!this.paused;){this.consumedAfterSnapshot=0;const t=this._consume();this._ensureHibernation()||this._callState(t)}this.inLoop=!1}}pause(){this.paused=!0}resume(t){if(!this.paused)throw new Error("Parser was already resumed");this.paused=!1,!this.inLoop&&(this._runParsingLoop(),this.paused||t?.())}write(t,n,r){this.active=!0,this.preprocessor.write(t,n),this._runParsingLoop(),this.paused||r?.()}insertHtmlAtCurrentPos(t){this.active=!0,this.preprocessor.insertHtmlAtCurrentPos(t),this._runParsingLoop()}_ensureHibernation(){return this.preprocessor.endOfChunkHit?(this.preprocessor.retreat(this.consumedAfterSnapshot),this.consumedAfterSnapshot=0,this.active=!1,!0):!1}_consume(){return this.consumedAfterSnapshot++,this.preprocessor.advance()}_advanceBy(t){this.consumedAfterSnapshot+=t;for(let n=0;n<t;n++)this.preprocessor.advance()}_consumeSequenceIfMatch(t,n){return this.preprocessor.startsWith(t,n)?(this._advanceBy(t.length-1),!0):!1}_createStartTagToken(){this.currentToken={type:re.START_TAG,tagName:"",tagID:l.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(1)}}_createEndTagToken(){this.currentToken={type:re.END_TAG,tagName:"",tagID:l.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(2)}}_createCommentToken(t){this.currentToken={type:re.COMMENT,data:"",location:this.getCurrentLocation(t)}}_createDoctypeToken(t){this.currentToken={type:re.DOCTYPE,name:t,forceQuirks:!1,publicId:null,systemId:null,location:this.currentLocation}}_createCharacterToken(t,n){this.currentCharacterToken={type:t,chars:n,location:this.currentLocation}}_createAttr(t){this.currentAttr={name:t,value:""},this.currentLocation=this.getCurrentLocation(0)}_leaveAttrName(){var t,n;const r=this.currentToken;if(au(r,this.currentAttr.name)===null){if(r.attrs.push(this.currentAttr),r.location&&this.currentLocation){const i=(t=(n=r.location).attrs)!==null&&t!==void 0?t:n.attrs=Object.create(null);i[this.currentAttr.name]=this.currentLocation,this._leaveAttrValue()}}else this._err(v.duplicateAttribute)}_leaveAttrValue(){this.currentLocation&&(this.currentLocation.endLine=this.preprocessor.line,this.currentLocation.endCol=this.preprocessor.col,this.currentLocation.endOffset=this.preprocessor.offset)}prepareToken(t){this._emitCurrentCharacterToken(t.location),this.currentToken=null,t.location&&(t.location.endLine=this.preprocessor.line,t.location.endCol=this.preprocessor.col+1,t.location.endOffset=this.preprocessor.offset+1),this.currentLocation=this.getCurrentLocation(-1)}emitCurrentTagToken(){const t=this.currentToken;this.prepareToken(t),t.tagID=gn(t.tagName),t.type===re.START_TAG?(this.lastStartTagName=t.tagName,this.handler.onStartTag(t)):(t.attrs.length>0&&this._err(v.endTagWithAttributes),t.selfClosing&&this._err(v.endTagWithTrailingSolidus),this.handler.onEndTag(t)),this.preprocessor.dropParsedChunk()}emitCurrentComment(t){this.prepareToken(t),this.handler.onComment(t),this.preprocessor.dropParsedChunk()}emitCurrentDoctype(t){this.prepareToken(t),this.handler.onDoctype(t),this.preprocessor.dropParsedChunk()}_emitCurrentCharacterToken(t){if(this.currentCharacterToken){switch(t&&this.currentCharacterToken.location&&(this.currentCharacterToken.location.endLine=t.startLine,this.currentCharacterToken.location.endCol=t.startCol,this.currentCharacterToken.location.endOffset=t.startOffset),this.currentCharacterToken.type){case re.CHARACTER:{this.handler.onCharacter(this.currentCharacterToken);break}case re.NULL_CHARACTER:{this.handler.onNullCharacter(this.currentCharacterToken);break}case re.WHITESPACE_CHARACTER:{this.handler.onWhitespaceCharacter(this.currentCharacterToken);break}}this.currentCharacterToken=null}}_emitEOFToken(){const t=this.getCurrentLocation(0);t&&(t.endLine=t.startLine,t.endCol=t.startCol,t.endOffset=t.startOffset),this._emitCurrentCharacterToken(t),this.handler.onEof({type:re.EOF,location:t}),this.active=!1}_appendCharToCurrentCharacterToken(t,n){if(this.currentCharacterToken)if(this.currentCharacterToken.type===t){this.currentCharacterToken.chars+=n;return}else this.currentLocation=this.getCurrentLocation(0),this._emitCurrentCharacterToken(this.currentLocation),this.preprocessor.dropParsedChunk();this._createCharacterToken(t,n)}_emitCodePoint(t){const n=ou(t)?re.WHITESPACE_CHARACTER:t===g.NULL?re.NULL_CHARACTER:re.CHARACTER;this._appendCharToCurrentCharacterToken(n,String.fromCodePoint(t))}_emitChars(t){this._appendCharToCurrentCharacterToken(re.CHARACTER,t)}_startCharacterReference(){this.returnState=this.state,this.state=E.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?Tt.Attribute:Tt.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===E.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===E.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===E.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(t){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(t):this._emitCodePoint(t)}_callState(t){switch(this.state){case E.DATA:{this._stateData(t);break}case E.RCDATA:{this._stateRcdata(t);break}case E.RAWTEXT:{this._stateRawtext(t);break}case E.SCRIPT_DATA:{this._stateScriptData(t);break}case E.PLAINTEXT:{this._statePlaintext(t);break}case E.TAG_OPEN:{this._stateTagOpen(t);break}case E.END_TAG_OPEN:{this._stateEndTagOpen(t);break}case E.TAG_NAME:{this._stateTagName(t);break}case E.RCDATA_LESS_THAN_SIGN:{this._stateRcdataLessThanSign(t);break}case E.RCDATA_END_TAG_OPEN:{this._stateRcdataEndTagOpen(t);break}case E.RCDATA_END_TAG_NAME:{this._stateRcdataEndTagName(t);break}case E.RAWTEXT_LESS_THAN_SIGN:{this._stateRawtextLessThanSign(t);break}case E.RAWTEXT_END_TAG_OPEN:{this._stateRawtextEndTagOpen(t);break}case E.RAWTEXT_END_TAG_NAME:{this._stateRawtextEndTagName(t);break}case E.SCRIPT_DATA_LESS_THAN_SIGN:{this._stateScriptDataLessThanSign(t);break}case E.SCRIPT_DATA_END_TAG_OPEN:{this._stateScriptDataEndTagOpen(t);break}case E.SCRIPT_DATA_END_TAG_NAME:{this._stateScriptDataEndTagName(t);break}case E.SCRIPT_DATA_ESCAPE_START:{this._stateScriptDataEscapeStart(t);break}case E.SCRIPT_DATA_ESCAPE_START_DASH:{this._stateScriptDataEscapeStartDash(t);break}case E.SCRIPT_DATA_ESCAPED:{this._stateScriptDataEscaped(t);break}case E.SCRIPT_DATA_ESCAPED_DASH:{this._stateScriptDataEscapedDash(t);break}case E.SCRIPT_DATA_ESCAPED_DASH_DASH:{this._stateScriptDataEscapedDashDash(t);break}case E.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataEscapedLessThanSign(t);break}case E.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:{this._stateScriptDataEscapedEndTagOpen(t);break}case E.SCRIPT_DATA_ESCAPED_END_TAG_NAME:{this._stateScriptDataEscapedEndTagName(t);break}case E.SCRIPT_DATA_DOUBLE_ESCAPE_START:{this._stateScriptDataDoubleEscapeStart(t);break}case E.SCRIPT_DATA_DOUBLE_ESCAPED:{this._stateScriptDataDoubleEscaped(t);break}case E.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:{this._stateScriptDataDoubleEscapedDash(t);break}case E.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:{this._stateScriptDataDoubleEscapedDashDash(t);break}case E.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataDoubleEscapedLessThanSign(t);break}case E.SCRIPT_DATA_DOUBLE_ESCAPE_END:{this._stateScriptDataDoubleEscapeEnd(t);break}case E.BEFORE_ATTRIBUTE_NAME:{this._stateBeforeAttributeName(t);break}case E.ATTRIBUTE_NAME:{this._stateAttributeName(t);break}case E.AFTER_ATTRIBUTE_NAME:{this._stateAfterAttributeName(t);break}case E.BEFORE_ATTRIBUTE_VALUE:{this._stateBeforeAttributeValue(t);break}case E.ATTRIBUTE_VALUE_DOUBLE_QUOTED:{this._stateAttributeValueDoubleQuoted(t);break}case E.ATTRIBUTE_VALUE_SINGLE_QUOTED:{this._stateAttributeValueSingleQuoted(t);break}case E.ATTRIBUTE_VALUE_UNQUOTED:{this._stateAttributeValueUnquoted(t);break}case E.AFTER_ATTRIBUTE_VALUE_QUOTED:{this._stateAfterAttributeValueQuoted(t);break}case E.SELF_CLOSING_START_TAG:{this._stateSelfClosingStartTag(t);break}case E.BOGUS_COMMENT:{this._stateBogusComment(t);break}case E.MARKUP_DECLARATION_OPEN:{this._stateMarkupDeclarationOpen(t);break}case E.COMMENT_START:{this._stateCommentStart(t);break}case E.COMMENT_START_DASH:{this._stateCommentStartDash(t);break}case E.COMMENT:{this._stateComment(t);break}case E.COMMENT_LESS_THAN_SIGN:{this._stateCommentLessThanSign(t);break}case E.COMMENT_LESS_THAN_SIGN_BANG:{this._stateCommentLessThanSignBang(t);break}case E.COMMENT_LESS_THAN_SIGN_BANG_DASH:{this._stateCommentLessThanSignBangDash(t);break}case E.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:{this._stateCommentLessThanSignBangDashDash(t);break}case E.COMMENT_END_DASH:{this._stateCommentEndDash(t);break}case E.COMMENT_END:{this._stateCommentEnd(t);break}case E.COMMENT_END_BANG:{this._stateCommentEndBang(t);break}case E.DOCTYPE:{this._stateDoctype(t);break}case E.BEFORE_DOCTYPE_NAME:{this._stateBeforeDoctypeName(t);break}case E.DOCTYPE_NAME:{this._stateDoctypeName(t);break}case E.AFTER_DOCTYPE_NAME:{this._stateAfterDoctypeName(t);break}case E.AFTER_DOCTYPE_PUBLIC_KEYWORD:{this._stateAfterDoctypePublicKeyword(t);break}case E.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateBeforeDoctypePublicIdentifier(t);break}case E.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypePublicIdentifierDoubleQuoted(t);break}case E.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypePublicIdentifierSingleQuoted(t);break}case E.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateAfterDoctypePublicIdentifier(t);break}case E.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:{this._stateBetweenDoctypePublicAndSystemIdentifiers(t);break}case E.AFTER_DOCTYPE_SYSTEM_KEYWORD:{this._stateAfterDoctypeSystemKeyword(t);break}case E.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateBeforeDoctypeSystemIdentifier(t);break}case E.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypeSystemIdentifierDoubleQuoted(t);break}case E.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypeSystemIdentifierSingleQuoted(t);break}case E.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateAfterDoctypeSystemIdentifier(t);break}case E.BOGUS_DOCTYPE:{this._stateBogusDoctype(t);break}case E.CDATA_SECTION:{this._stateCdataSection(t);break}case E.CDATA_SECTION_BRACKET:{this._stateCdataSectionBracket(t);break}case E.CDATA_SECTION_END:{this._stateCdataSectionEnd(t);break}case E.CHARACTER_REFERENCE:{this._stateCharacterReference();break}case E.AMBIGUOUS_AMPERSAND:{this._stateAmbiguousAmpersand(t);break}default:throw new Error("Unknown state")}}_stateData(t){switch(t){case g.LESS_THAN_SIGN:{this.state=E.TAG_OPEN;break}case g.AMPERSAND:{this._startCharacterReference();break}case g.NULL:{this._err(v.unexpectedNullCharacter),this._emitCodePoint(t);break}case g.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRcdata(t){switch(t){case g.AMPERSAND:{this._startCharacterReference();break}case g.LESS_THAN_SIGN:{this.state=E.RCDATA_LESS_THAN_SIGN;break}case g.NULL:{this._err(v.unexpectedNullCharacter),this._emitChars(_e);break}case g.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRawtext(t){switch(t){case g.LESS_THAN_SIGN:{this.state=E.RAWTEXT_LESS_THAN_SIGN;break}case g.NULL:{this._err(v.unexpectedNullCharacter),this._emitChars(_e);break}case g.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptData(t){switch(t){case g.LESS_THAN_SIGN:{this.state=E.SCRIPT_DATA_LESS_THAN_SIGN;break}case g.NULL:{this._err(v.unexpectedNullCharacter),this._emitChars(_e);break}case g.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_statePlaintext(t){switch(t){case g.NULL:{this._err(v.unexpectedNullCharacter),this._emitChars(_e);break}case g.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateTagOpen(t){if(vt(t))this._createStartTagToken(),this.state=E.TAG_NAME,this._stateTagName(t);else switch(t){case g.EXCLAMATION_MARK:{this.state=E.MARKUP_DECLARATION_OPEN;break}case g.SOLIDUS:{this.state=E.END_TAG_OPEN;break}case g.QUESTION_MARK:{this._err(v.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=E.BOGUS_COMMENT,this._stateBogusComment(t);break}case g.EOF:{this._err(v.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break}default:this._err(v.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=E.DATA,this._stateData(t)}}_stateEndTagOpen(t){if(vt(t))this._createEndTagToken(),this.state=E.TAG_NAME,this._stateTagName(t);else switch(t){case g.GREATER_THAN_SIGN:{this._err(v.missingEndTagName),this.state=E.DATA;break}case g.EOF:{this._err(v.eofBeforeTagName),this._emitChars("</"),this._emitEOFToken();break}default:this._err(v.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=E.BOGUS_COMMENT,this._stateBogusComment(t)}}_stateTagName(t){const n=this.currentToken;switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:{this.state=E.BEFORE_ATTRIBUTE_NAME;break}case g.SOLIDUS:{this.state=E.SELF_CLOSING_START_TAG;break}case g.GREATER_THAN_SIGN:{this.state=E.DATA,this.emitCurrentTagToken();break}case g.NULL:{this._err(v.unexpectedNullCharacter),n.tagName+=_e;break}case g.EOF:{this._err(v.eofInTag),this._emitEOFToken();break}default:n.tagName+=String.fromCodePoint(zn(t)?Fr(t):t)}}_stateRcdataLessThanSign(t){t===g.SOLIDUS?this.state=E.RCDATA_END_TAG_OPEN:(this._emitChars("<"),this.state=E.RCDATA,this._stateRcdata(t))}_stateRcdataEndTagOpen(t){vt(t)?(this.state=E.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(t)):(this._emitChars("</"),this.state=E.RCDATA,this._stateRcdata(t))}handleSpecialEndTag(t){if(!this.preprocessor.startsWith(this.lastStartTagName,!1))return!this._ensureHibernation();this._createEndTagToken();const n=this.currentToken;switch(n.tagName=this.lastStartTagName,this.preprocessor.peek(this.lastStartTagName.length)){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=E.BEFORE_ATTRIBUTE_NAME,!1;case g.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=E.SELF_CLOSING_START_TAG,!1;case g.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=E.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=E.RCDATA,this._stateRcdata(t))}_stateRawtextLessThanSign(t){t===g.SOLIDUS?this.state=E.RAWTEXT_END_TAG_OPEN:(this._emitChars("<"),this.state=E.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagOpen(t){vt(t)?(this.state=E.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(t)):(this._emitChars("</"),this.state=E.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=E.RAWTEXT,this._stateRawtext(t))}_stateScriptDataLessThanSign(t){switch(t){case g.SOLIDUS:{this.state=E.SCRIPT_DATA_END_TAG_OPEN;break}case g.EXCLAMATION_MARK:{this.state=E.SCRIPT_DATA_ESCAPE_START,this._emitChars("<!");break}default:this._emitChars("<"),this.state=E.SCRIPT_DATA,this._stateScriptData(t)}}_stateScriptDataEndTagOpen(t){vt(t)?(this.state=E.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(t)):(this._emitChars("</"),this.state=E.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=E.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStart(t){t===g.HYPHEN_MINUS?(this.state=E.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars("-")):(this.state=E.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStartDash(t){t===g.HYPHEN_MINUS?(this.state=E.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-")):(this.state=E.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscaped(t){switch(t){case g.HYPHEN_MINUS:{this.state=E.SCRIPT_DATA_ESCAPED_DASH,this._emitChars("-");break}case g.LESS_THAN_SIGN:{this.state=E.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case g.NULL:{this._err(v.unexpectedNullCharacter),this._emitChars(_e);break}case g.EOF:{this._err(v.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataEscapedDash(t){switch(t){case g.HYPHEN_MINUS:{this.state=E.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-");break}case g.LESS_THAN_SIGN:{this.state=E.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case g.NULL:{this._err(v.unexpectedNullCharacter),this.state=E.SCRIPT_DATA_ESCAPED,this._emitChars(_e);break}case g.EOF:{this._err(v.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=E.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedDashDash(t){switch(t){case g.HYPHEN_MINUS:{this._emitChars("-");break}case g.LESS_THAN_SIGN:{this.state=E.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case g.GREATER_THAN_SIGN:{this.state=E.SCRIPT_DATA,this._emitChars(">");break}case g.NULL:{this._err(v.unexpectedNullCharacter),this.state=E.SCRIPT_DATA_ESCAPED,this._emitChars(_e);break}case g.EOF:{this._err(v.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=E.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedLessThanSign(t){t===g.SOLIDUS?this.state=E.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:vt(t)?(this._emitChars("<"),this.state=E.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(t)):(this._emitChars("<"),this.state=E.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagOpen(t){vt(t)?(this.state=E.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(t)):(this._emitChars("</"),this.state=E.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=E.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscapeStart(t){if(this.preprocessor.startsWith(qe.SCRIPT,!1)&&uu(this.preprocessor.peek(qe.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<qe.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=E.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscaped(t){switch(t){case g.HYPHEN_MINUS:{this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars("-");break}case g.LESS_THAN_SIGN:{this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case g.NULL:{this._err(v.unexpectedNullCharacter),this._emitChars(_e);break}case g.EOF:{this._err(v.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDash(t){switch(t){case g.HYPHEN_MINUS:{this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars("-");break}case g.LESS_THAN_SIGN:{this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case g.NULL:{this._err(v.unexpectedNullCharacter),this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(_e);break}case g.EOF:{this._err(v.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDashDash(t){switch(t){case g.HYPHEN_MINUS:{this._emitChars("-");break}case g.LESS_THAN_SIGN:{this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case g.GREATER_THAN_SIGN:{this.state=E.SCRIPT_DATA,this._emitChars(">");break}case g.NULL:{this._err(v.unexpectedNullCharacter),this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(_e);break}case g.EOF:{this._err(v.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedLessThanSign(t){t===g.SOLIDUS?(this.state=E.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateScriptDataDoubleEscapeEnd(t){if(this.preprocessor.startsWith(qe.SCRIPT,!1)&&uu(this.preprocessor.peek(qe.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<qe.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=E.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateBeforeAttributeName(t){switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:break;case g.SOLIDUS:case g.GREATER_THAN_SIGN:case g.EOF:{this.state=E.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case g.EQUALS_SIGN:{this._err(v.unexpectedEqualsSignBeforeAttributeName),this._createAttr("="),this.state=E.ATTRIBUTE_NAME;break}default:this._createAttr(""),this.state=E.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateAttributeName(t){switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:case g.SOLIDUS:case g.GREATER_THAN_SIGN:case g.EOF:{this._leaveAttrName(),this.state=E.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case g.EQUALS_SIGN:{this._leaveAttrName(),this.state=E.BEFORE_ATTRIBUTE_VALUE;break}case g.QUOTATION_MARK:case g.APOSTROPHE:case g.LESS_THAN_SIGN:{this._err(v.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(t);break}case g.NULL:{this._err(v.unexpectedNullCharacter),this.currentAttr.name+=_e;break}default:this.currentAttr.name+=String.fromCodePoint(zn(t)?Fr(t):t)}}_stateAfterAttributeName(t){switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:break;case g.SOLIDUS:{this.state=E.SELF_CLOSING_START_TAG;break}case g.EQUALS_SIGN:{this.state=E.BEFORE_ATTRIBUTE_VALUE;break}case g.GREATER_THAN_SIGN:{this.state=E.DATA,this.emitCurrentTagToken();break}case g.EOF:{this._err(v.eofInTag),this._emitEOFToken();break}default:this._createAttr(""),this.state=E.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateBeforeAttributeValue(t){switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:break;case g.QUOTATION_MARK:{this.state=E.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break}case g.APOSTROPHE:{this.state=E.ATTRIBUTE_VALUE_SINGLE_QUOTED;break}case g.GREATER_THAN_SIGN:{this._err(v.missingAttributeValue),this.state=E.DATA,this.emitCurrentTagToken();break}default:this.state=E.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(t)}}_stateAttributeValueDoubleQuoted(t){switch(t){case g.QUOTATION_MARK:{this.state=E.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case g.AMPERSAND:{this._startCharacterReference();break}case g.NULL:{this._err(v.unexpectedNullCharacter),this.currentAttr.value+=_e;break}case g.EOF:{this._err(v.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueSingleQuoted(t){switch(t){case g.APOSTROPHE:{this.state=E.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case g.AMPERSAND:{this._startCharacterReference();break}case g.NULL:{this._err(v.unexpectedNullCharacter),this.currentAttr.value+=_e;break}case g.EOF:{this._err(v.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueUnquoted(t){switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:{this._leaveAttrValue(),this.state=E.BEFORE_ATTRIBUTE_NAME;break}case g.AMPERSAND:{this._startCharacterReference();break}case g.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=E.DATA,this.emitCurrentTagToken();break}case g.NULL:{this._err(v.unexpectedNullCharacter),this.currentAttr.value+=_e;break}case g.QUOTATION_MARK:case g.APOSTROPHE:case g.LESS_THAN_SIGN:case g.EQUALS_SIGN:case g.GRAVE_ACCENT:{this._err(v.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(t);break}case g.EOF:{this._err(v.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAfterAttributeValueQuoted(t){switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:{this._leaveAttrValue(),this.state=E.BEFORE_ATTRIBUTE_NAME;break}case g.SOLIDUS:{this._leaveAttrValue(),this.state=E.SELF_CLOSING_START_TAG;break}case g.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=E.DATA,this.emitCurrentTagToken();break}case g.EOF:{this._err(v.eofInTag),this._emitEOFToken();break}default:this._err(v.missingWhitespaceBetweenAttributes),this.state=E.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateSelfClosingStartTag(t){switch(t){case g.GREATER_THAN_SIGN:{const n=this.currentToken;n.selfClosing=!0,this.state=E.DATA,this.emitCurrentTagToken();break}case g.EOF:{this._err(v.eofInTag),this._emitEOFToken();break}default:this._err(v.unexpectedSolidusInTag),this.state=E.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateBogusComment(t){const n=this.currentToken;switch(t){case g.GREATER_THAN_SIGN:{this.state=E.DATA,this.emitCurrentComment(n);break}case g.EOF:{this.emitCurrentComment(n),this._emitEOFToken();break}case g.NULL:{this._err(v.unexpectedNullCharacter),n.data+=_e;break}default:n.data+=String.fromCodePoint(t)}}_stateMarkupDeclarationOpen(t){this._consumeSequenceIfMatch(qe.DASH_DASH,!0)?(this._createCommentToken(qe.DASH_DASH.length+1),this.state=E.COMMENT_START):this._consumeSequenceIfMatch(qe.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(qe.DOCTYPE.length+1),this.state=E.DOCTYPE):this._consumeSequenceIfMatch(qe.CDATA_START,!0)?this.inForeignNode?this.state=E.CDATA_SECTION:(this._err(v.cdataInHtmlContent),this._createCommentToken(qe.CDATA_START.length+1),this.currentToken.data="[CDATA[",this.state=E.BOGUS_COMMENT):this._ensureHibernation()||(this._err(v.incorrectlyOpenedComment),this._createCommentToken(2),this.state=E.BOGUS_COMMENT,this._stateBogusComment(t))}_stateCommentStart(t){switch(t){case g.HYPHEN_MINUS:{this.state=E.COMMENT_START_DASH;break}case g.GREATER_THAN_SIGN:{this._err(v.abruptClosingOfEmptyComment),this.state=E.DATA;const n=this.currentToken;this.emitCurrentComment(n);break}default:this.state=E.COMMENT,this._stateComment(t)}}_stateCommentStartDash(t){const n=this.currentToken;switch(t){case g.HYPHEN_MINUS:{this.state=E.COMMENT_END;break}case g.GREATER_THAN_SIGN:{this._err(v.abruptClosingOfEmptyComment),this.state=E.DATA,this.emitCurrentComment(n);break}case g.EOF:{this._err(v.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=E.COMMENT,this._stateComment(t)}}_stateComment(t){const n=this.currentToken;switch(t){case g.HYPHEN_MINUS:{this.state=E.COMMENT_END_DASH;break}case g.LESS_THAN_SIGN:{n.data+="<",this.state=E.COMMENT_LESS_THAN_SIGN;break}case g.NULL:{this._err(v.unexpectedNullCharacter),n.data+=_e;break}case g.EOF:{this._err(v.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+=String.fromCodePoint(t)}}_stateCommentLessThanSign(t){const n=this.currentToken;switch(t){case g.EXCLAMATION_MARK:{n.data+="!",this.state=E.COMMENT_LESS_THAN_SIGN_BANG;break}case g.LESS_THAN_SIGN:{n.data+="<";break}default:this.state=E.COMMENT,this._stateComment(t)}}_stateCommentLessThanSignBang(t){t===g.HYPHEN_MINUS?this.state=E.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=E.COMMENT,this._stateComment(t))}_stateCommentLessThanSignBangDash(t){t===g.HYPHEN_MINUS?this.state=E.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=E.COMMENT_END_DASH,this._stateCommentEndDash(t))}_stateCommentLessThanSignBangDashDash(t){t!==g.GREATER_THAN_SIGN&&t!==g.EOF&&this._err(v.nestedComment),this.state=E.COMMENT_END,this._stateCommentEnd(t)}_stateCommentEndDash(t){const n=this.currentToken;switch(t){case g.HYPHEN_MINUS:{this.state=E.COMMENT_END;break}case g.EOF:{this._err(v.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=E.COMMENT,this._stateComment(t)}}_stateCommentEnd(t){const n=this.currentToken;switch(t){case g.GREATER_THAN_SIGN:{this.state=E.DATA,this.emitCurrentComment(n);break}case g.EXCLAMATION_MARK:{this.state=E.COMMENT_END_BANG;break}case g.HYPHEN_MINUS:{n.data+="-";break}case g.EOF:{this._err(v.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--",this.state=E.COMMENT,this._stateComment(t)}}_stateCommentEndBang(t){const n=this.currentToken;switch(t){case g.HYPHEN_MINUS:{n.data+="--!",this.state=E.COMMENT_END_DASH;break}case g.GREATER_THAN_SIGN:{this._err(v.incorrectlyClosedComment),this.state=E.DATA,this.emitCurrentComment(n);break}case g.EOF:{this._err(v.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--!",this.state=E.COMMENT,this._stateComment(t)}}_stateDoctype(t){switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:{this.state=E.BEFORE_DOCTYPE_NAME;break}case g.GREATER_THAN_SIGN:{this.state=E.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t);break}case g.EOF:{this._err(v.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(v.missingWhitespaceBeforeDoctypeName),this.state=E.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t)}}_stateBeforeDoctypeName(t){if(zn(t))this._createDoctypeToken(String.fromCharCode(Fr(t))),this.state=E.DOCTYPE_NAME;else switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:break;case g.NULL:{this._err(v.unexpectedNullCharacter),this._createDoctypeToken(_e),this.state=E.DOCTYPE_NAME;break}case g.GREATER_THAN_SIGN:{this._err(v.missingDoctypeName),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=E.DATA;break}case g.EOF:{this._err(v.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._createDoctypeToken(String.fromCodePoint(t)),this.state=E.DOCTYPE_NAME}}_stateDoctypeName(t){const n=this.currentToken;switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:{this.state=E.AFTER_DOCTYPE_NAME;break}case g.GREATER_THAN_SIGN:{this.state=E.DATA,this.emitCurrentDoctype(n);break}case g.NULL:{this._err(v.unexpectedNullCharacter),n.name+=_e;break}case g.EOF:{this._err(v.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.name+=String.fromCodePoint(zn(t)?Fr(t):t)}}_stateAfterDoctypeName(t){const n=this.currentToken;switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:break;case g.GREATER_THAN_SIGN:{this.state=E.DATA,this.emitCurrentDoctype(n);break}case g.EOF:{this._err(v.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._consumeSequenceIfMatch(qe.PUBLIC,!1)?this.state=E.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(qe.SYSTEM,!1)?this.state=E.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(v.invalidCharacterSequenceAfterDoctypeName),n.forceQuirks=!0,this.state=E.BOGUS_DOCTYPE,this._stateBogusDoctype(t))}}_stateAfterDoctypePublicKeyword(t){const n=this.currentToken;switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:{this.state=E.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break}case g.QUOTATION_MARK:{this._err(v.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=E.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case g.APOSTROPHE:{this._err(v.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=E.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case g.GREATER_THAN_SIGN:{this._err(v.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=E.DATA,this.emitCurrentDoctype(n);break}case g.EOF:{this._err(v.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(v.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=E.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:break;case g.QUOTATION_MARK:{n.publicId="",this.state=E.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case g.APOSTROPHE:{n.publicId="",this.state=E.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case g.GREATER_THAN_SIGN:{this._err(v.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=E.DATA,this.emitCurrentDoctype(n);break}case g.EOF:{this._err(v.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(v.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=E.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypePublicIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case g.QUOTATION_MARK:{this.state=E.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case g.NULL:{this._err(v.unexpectedNullCharacter),n.publicId+=_e;break}case g.GREATER_THAN_SIGN:{this._err(v.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=E.DATA;break}case g.EOF:{this._err(v.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.publicId+=String.fromCodePoint(t)}}_stateDoctypePublicIdentifierSingleQuoted(t){const n=this.currentToken;switch(t){case g.APOSTROPHE:{this.state=E.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case g.NULL:{this._err(v.unexpectedNullCharacter),n.publicId+=_e;break}case g.GREATER_THAN_SIGN:{this._err(v.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=E.DATA;break}case g.EOF:{this._err(v.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.publicId+=String.fromCodePoint(t)}}_stateAfterDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:{this.state=E.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break}case g.GREATER_THAN_SIGN:{this.state=E.DATA,this.emitCurrentDoctype(n);break}case g.QUOTATION_MARK:{this._err(v.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=E.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case g.APOSTROPHE:{this._err(v.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=E.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case g.EOF:{this._err(v.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(v.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=E.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBetweenDoctypePublicAndSystemIdentifiers(t){const n=this.currentToken;switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:break;case g.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=E.DATA;break}case g.QUOTATION_MARK:{n.systemId="",this.state=E.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case g.APOSTROPHE:{n.systemId="",this.state=E.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case g.EOF:{this._err(v.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(v.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=E.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateAfterDoctypeSystemKeyword(t){const n=this.currentToken;switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:{this.state=E.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break}case g.QUOTATION_MARK:{this._err(v.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=E.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case g.APOSTROPHE:{this._err(v.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=E.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case g.GREATER_THAN_SIGN:{this._err(v.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=E.DATA,this.emitCurrentDoctype(n);break}case g.EOF:{this._err(v.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(v.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=E.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:break;case g.QUOTATION_MARK:{n.systemId="",this.state=E.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case g.APOSTROPHE:{n.systemId="",this.state=E.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case g.GREATER_THAN_SIGN:{this._err(v.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=E.DATA,this.emitCurrentDoctype(n);break}case g.EOF:{this._err(v.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(v.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=E.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypeSystemIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case g.QUOTATION_MARK:{this.state=E.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case g.NULL:{this._err(v.unexpectedNullCharacter),n.systemId+=_e;break}case g.GREATER_THAN_SIGN:{this._err(v.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=E.DATA;break}case g.EOF:{this._err(v.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.systemId+=String.fromCodePoint(t)}}_stateDoctypeSystemIdentifierSingleQuoted(t){const n=this.currentToken;switch(t){case g.APOSTROPHE:{this.state=E.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case g.NULL:{this._err(v.unexpectedNullCharacter),n.systemId+=_e;break}case g.GREATER_THAN_SIGN:{this._err(v.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=E.DATA;break}case g.EOF:{this._err(v.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.systemId+=String.fromCodePoint(t)}}_stateAfterDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:break;case g.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=E.DATA;break}case g.EOF:{this._err(v.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(v.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=E.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBogusDoctype(t){const n=this.currentToken;switch(t){case g.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=E.DATA;break}case g.NULL:{this._err(v.unexpectedNullCharacter);break}case g.EOF:{this.emitCurrentDoctype(n),this._emitEOFToken();break}}}_stateCdataSection(t){switch(t){case g.RIGHT_SQUARE_BRACKET:{this.state=E.CDATA_SECTION_BRACKET;break}case g.EOF:{this._err(v.eofInCdata),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateCdataSectionBracket(t){t===g.RIGHT_SQUARE_BRACKET?this.state=E.CDATA_SECTION_END:(this._emitChars("]"),this.state=E.CDATA_SECTION,this._stateCdataSection(t))}_stateCdataSectionEnd(t){switch(t){case g.GREATER_THAN_SIGN:{this.state=E.DATA;break}case g.RIGHT_SQUARE_BRACKET:{this._emitChars("]");break}default:this._emitChars("]]"),this.state=E.CDATA_SECTION,this._stateCdataSection(t)}}_stateCharacterReference(){let t=this.entityDecoder.write(this.preprocessor.html,this.preprocessor.pos);if(t<0)if(this.preprocessor.lastChunkWritten)t=this.entityDecoder.end();else{this.active=!1,this.preprocessor.pos=this.preprocessor.html.length-1,this.consumedAfterSnapshot=0,this.preprocessor.endOfChunkHit=!0;return}t===0?(this.preprocessor.pos=this.entityStartPos,this._flushCodePointConsumedAsCharacterReference(g.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&su(this.preprocessor.peek(1))?E.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(t){su(t)?this._flushCodePointConsumedAsCharacterReference(t):(t===g.SEMICOLON&&this._err(v.unknownNamedCharacterReference),this.state=this.returnState,this._callState(t))}}const lu=new Set([l.DD,l.DT,l.LI,l.OPTGROUP,l.OPTION,l.P,l.RB,l.RP,l.RT,l.RTC]),cu=new Set([...lu,l.CAPTION,l.COLGROUP,l.TBODY,l.TD,l.TFOOT,l.TH,l.THEAD,l.TR]),Hr=new Set([l.APPLET,l.CAPTION,l.HTML,l.MARQUEE,l.OBJECT,l.TABLE,l.TD,l.TEMPLATE,l.TH]),wh=new Set([...Hr,l.OL,l.UL]),Ah=new Set([...Hr,l.BUTTON]),du=new Set([l.ANNOTATION_XML,l.MI,l.MN,l.MO,l.MS,l.MTEXT]),fu=new Set([l.DESC,l.FOREIGN_OBJECT,l.TITLE]),Ch=new Set([l.TR,l.TEMPLATE,l.HTML]),Sh=new Set([l.TBODY,l.TFOOT,l.THEAD,l.TEMPLATE,l.HTML]),Ih=new Set([l.TABLE,l.TEMPLATE,l.HTML]),Nh=new Set([l.TD,l.TH]);class vh{get currentTmplContentOrNode(){return this._isInTemplate()?this.treeAdapter.getTemplateContent(this.current):this.current}constructor(t,n,r){this.treeAdapter=n,this.handler=r,this.items=[],this.tagIDs=[],this.stackTop=-1,this.tmplCount=0,this.currentTagId=l.UNKNOWN,this.current=t}_indexOf(t){return this.items.lastIndexOf(t,this.stackTop)}_isInTemplate(){return this.currentTagId===l.TEMPLATE&&this.treeAdapter.getNamespaceURI(this.current)===O.HTML}_updateCurrentElement(){this.current=this.items[this.stackTop],this.currentTagId=this.tagIDs[this.stackTop]}push(t,n){this.stackTop++,this.items[this.stackTop]=t,this.current=t,this.tagIDs[this.stackTop]=n,this.currentTagId=n,this._isInTemplate()&&this.tmplCount++,this.handler.onItemPush(t,n,!0)}pop(){const t=this.current;this.tmplCount>0&&this._isInTemplate()&&this.tmplCount--,this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,!0)}replace(t,n){const r=this._indexOf(t);this.items[r]=n,r===this.stackTop&&(this.current=n)}insertAfter(t,n,r){const i=this._indexOf(t)+1;this.items.splice(i,0,n),this.tagIDs.splice(i,0,r),this.stackTop++,i===this.stackTop&&this._updateCurrentElement(),this.current&&this.currentTagId!==void 0&&this.handler.onItemPush(this.current,this.currentTagId,i===this.stackTop)}popUntilTagNamePopped(t){let n=this.stackTop+1;do n=this.tagIDs.lastIndexOf(t,n-1);while(n>0&&this.treeAdapter.getNamespaceURI(this.items[n])!==O.HTML);this.shortenToLength(Math.max(n,0))}shortenToLength(t){for(;this.stackTop>=t;){const n=this.current;this.tmplCount>0&&this._isInTemplate()&&(this.tmplCount-=1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(n,this.stackTop<t)}}popUntilElementPopped(t){const n=this._indexOf(t);this.shortenToLength(Math.max(n,0))}popUntilPopped(t,n){const r=this._indexOfTagNames(t,n);this.shortenToLength(Math.max(r,0))}popUntilNumberedHeaderPopped(){this.popUntilPopped(sa,O.HTML)}popUntilTableCellPopped(){this.popUntilPopped(Nh,O.HTML)}popAllUpToHtmlElement(){this.tmplCount=0,this.shortenToLength(1)}_indexOfTagNames(t,n){for(let r=this.stackTop;r>=0;r--)if(t.has(this.tagIDs[r])&&this.treeAdapter.getNamespaceURI(this.items[r])===n)return r;return-1}clearBackTo(t,n){const r=this._indexOfTagNames(t,n);this.shortenToLength(r+1)}clearBackToTableContext(){this.clearBackTo(Ih,O.HTML)}clearBackToTableBodyContext(){this.clearBackTo(Sh,O.HTML)}clearBackToTableRowContext(){this.clearBackTo(Ch,O.HTML)}remove(t){const n=this._indexOf(t);n>=0&&(n===this.stackTop?this.pop():(this.items.splice(n,1),this.tagIDs.splice(n,1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,!1)))}tryPeekProperlyNestedBodyElement(){return this.stackTop>=1&&this.tagIDs[1]===l.BODY?this.items[1]:null}contains(t){return this._indexOf(t)>-1}getCommonAncestor(t){const n=this._indexOf(t)-1;return n>=0?this.items[n]:null}isRootHtmlElementCurrent(){return this.stackTop===0&&this.tagIDs[0]===l.HTML}hasInDynamicScope(t,n){for(let r=this.stackTop;r>=0;r--){const i=this.tagIDs[r];switch(this.treeAdapter.getNamespaceURI(this.items[r])){case O.HTML:{if(i===t)return!0;if(n.has(i))return!1;break}case O.SVG:{if(fu.has(i))return!1;break}case O.MATHML:{if(du.has(i))return!1;break}}}return!0}hasInScope(t){return this.hasInDynamicScope(t,Hr)}hasInListItemScope(t){return this.hasInDynamicScope(t,wh)}hasInButtonScope(t){return this.hasInDynamicScope(t,Ah)}hasNumberedHeaderInScope(){for(let t=this.stackTop;t>=0;t--){const n=this.tagIDs[t];switch(this.treeAdapter.getNamespaceURI(this.items[t])){case O.HTML:{if(sa.has(n))return!0;if(Hr.has(n))return!1;break}case O.SVG:{if(fu.has(n))return!1;break}case O.MATHML:{if(du.has(n))return!1;break}}}return!0}hasInTableScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===O.HTML)switch(this.tagIDs[n]){case t:return!0;case l.TABLE:case l.HTML:return!1}return!0}hasTableBodyContextInTableScope(){for(let t=this.stackTop;t>=0;t--)if(this.treeAdapter.getNamespaceURI(this.items[t])===O.HTML)switch(this.tagIDs[t]){case l.TBODY:case l.THEAD:case l.TFOOT:return!0;case l.TABLE:case l.HTML:return!1}return!0}hasInSelectScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===O.HTML)switch(this.tagIDs[n]){case t:return!0;case l.OPTION:case l.OPTGROUP:break;default:return!1}return!0}generateImpliedEndTags(){for(;this.currentTagId!==void 0&&lu.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;this.currentTagId!==void 0&&cu.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(t){for(;this.currentTagId!==void 0&&this.currentTagId!==t&&cu.has(this.currentTagId);)this.pop()}}const oa=3;var ht;(function(e){e[e.Marker=0]="Marker",e[e.Element=1]="Element"})(ht||(ht={}));const hu={type:ht.Marker};class Lh{constructor(t){this.treeAdapter=t,this.entries=[],this.bookmark=null}_getNoahArkConditionCandidates(t,n){const r=[],i=n.length,a=this.treeAdapter.getTagName(t),s=this.treeAdapter.getNamespaceURI(t);for(let o=0;o<this.entries.length;o++){const u=this.entries[o];if(u.type===ht.Marker)break;const{element:c}=u;if(this.treeAdapter.getTagName(c)===a&&this.treeAdapter.getNamespaceURI(c)===s){const f=this.treeAdapter.getAttrList(c);f.length===i&&r.push({idx:o,attrs:f})}}return r}_ensureNoahArkCondition(t){if(this.entries.length<oa)return;const n=this.treeAdapter.getAttrList(t),r=this._getNoahArkConditionCandidates(t,n);if(r.length<oa)return;const i=new Map(n.map(s=>[s.name,s.value]));let a=0;for(let s=0;s<r.length;s++){const o=r[s];o.attrs.every(u=>i.get(u.name)===u.value)&&(a+=1,a>=oa&&this.entries.splice(o.idx,1))}}insertMarker(){this.entries.unshift(hu)}pushElement(t,n){this._ensureNoahArkCondition(t),this.entries.unshift({type:ht.Element,element:t,token:n})}insertElementAfterBookmark(t,n){const r=this.entries.indexOf(this.bookmark);this.entries.splice(r,0,{type:ht.Element,element:t,token:n})}removeEntry(t){const n=this.entries.indexOf(t);n!==-1&&this.entries.splice(n,1)}clearToLastMarker(){const t=this.entries.indexOf(hu);t===-1?this.entries.length=0:this.entries.splice(0,t+1)}getElementEntryInScopeWithTagName(t){const n=this.entries.find(r=>r.type===ht.Marker||this.treeAdapter.getTagName(r.element)===t);return n&&n.type===ht.Element?n:null}getElementEntry(t){return this.entries.find(n=>n.type===ht.Element&&n.element===t)}}const Lt={createDocument(){return{nodeName:"#document",mode:rt.NO_QUIRKS,childNodes:[]}},createDocumentFragment(){return{nodeName:"#document-fragment",childNodes:[]}},createElement(e,t,n){return{nodeName:e,tagName:e,attrs:n,namespaceURI:t,childNodes:[],parentNode:null}},createCommentNode(e){return{nodeName:"#comment",data:e,parentNode:null}},createTextNode(e){return{nodeName:"#text",value:e,parentNode:null}},appendChild(e,t){e.childNodes.push(t),t.parentNode=e},insertBefore(e,t,n){const r=e.childNodes.indexOf(n);e.childNodes.splice(r,0,t),t.parentNode=e},setTemplateContent(e,t){e.content=t},getTemplateContent(e){return e.content},setDocumentType(e,t,n,r){const i=e.childNodes.find(a=>a.nodeName==="#documentType");if(i)i.name=t,i.publicId=n,i.systemId=r;else{const a={nodeName:"#documentType",name:t,publicId:n,systemId:r,parentNode:null};Lt.appendChild(e,a)}},setDocumentMode(e,t){e.mode=t},getDocumentMode(e){return e.mode},detachNode(e){if(e.parentNode){const t=e.parentNode.childNodes.indexOf(e);e.parentNode.childNodes.splice(t,1),e.parentNode=null}},insertText(e,t){if(e.childNodes.length>0){const n=e.childNodes[e.childNodes.length-1];if(Lt.isTextNode(n)){n.value+=t;return}}Lt.appendChild(e,Lt.createTextNode(t))},insertTextBefore(e,t,n){const r=e.childNodes[e.childNodes.indexOf(n)-1];r&&Lt.isTextNode(r)?r.value+=t:Lt.insertBefore(e,Lt.createTextNode(t),n)},adoptAttributes(e,t){const n=new Set(e.attrs.map(r=>r.name));for(let r=0;r<t.length;r++)n.has(t[r].name)||e.attrs.push(t[r])},getFirstChild(e){return e.childNodes[0]},getChildNodes(e){return e.childNodes},getParentNode(e){return e.parentNode},getAttrList(e){return e.attrs},getTagName(e){return e.tagName},getNamespaceURI(e){return e.namespaceURI},getTextNodeContent(e){return e.value},getCommentNodeContent(e){return e.data},getDocumentTypeNodeName(e){return e.name},getDocumentTypeNodePublicId(e){return e.publicId},getDocumentTypeNodeSystemId(e){return e.systemId},isTextNode(e){return e.nodeName==="#text"},isCommentNode(e){return e.nodeName==="#comment"},isDocumentTypeNode(e){return e.nodeName==="#documentType"},isElementNode(e){return Object.prototype.hasOwnProperty.call(e,"tagName")},setNodeSourceCodeLocation(e,t){e.sourceCodeLocation=t},getNodeSourceCodeLocation(e){return e.sourceCodeLocation},updateNodeSourceCodeLocation(e,t){e.sourceCodeLocation={...e.sourceCodeLocation,...t}}},pu="html",Rh="about:legacy-compat",Oh="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",mu=["+//silmaril//dtd html pro v0r11 19970101//","-//as//dtd html 3.0 aswedit + extensions//","-//advasoft ltd//dtd html 3.0 aswedit + extensions//","-//ietf//dtd html 2.0 level 1//","-//ietf//dtd html 2.0 level 2//","-//ietf//dtd html 2.0 strict level 1//","-//ietf//dtd html 2.0 strict level 2//","-//ietf//dtd html 2.0 strict//","-//ietf//dtd html 2.0//","-//ietf//dtd html 2.1e//","-//ietf//dtd html 3.0//","-//ietf//dtd html 3.2 final//","-//ietf//dtd html 3.2//","-//ietf//dtd html 3//","-//ietf//dtd html level 0//","-//ietf//dtd html level 1//","-//ietf//dtd html level 2//","-//ietf//dtd html level 3//","-//ietf//dtd html strict level 0//","-//ietf//dtd html strict level 1//","-//ietf//dtd html strict level 2//","-//ietf//dtd html strict level 3//","-//ietf//dtd html strict//","-//ietf//dtd html//","-//metrius//dtd metrius presentational//","-//microsoft//dtd internet explorer 2.0 html strict//","-//microsoft//dtd internet explorer 2.0 html//","-//microsoft//dtd internet explorer 2.0 tables//","-//microsoft//dtd internet explorer 3.0 html strict//","-//microsoft//dtd internet explorer 3.0 html//","-//microsoft//dtd internet explorer 3.0 tables//","-//netscape comm. corp.//dtd html//","-//netscape comm. corp.//dtd strict html//","-//o'reilly and associates//dtd html 2.0//","-//o'reilly and associates//dtd html extended 1.0//","-//o'reilly and associates//dtd html extended relaxed 1.0//","-//sq//dtd html 2.0 hotmetal + extensions//","-//softquad software//dtd hotmetal pro 6.0::19990601::extensions to html 4.0//","-//softquad//dtd hotmetal pro 4.0::19971010::extensions to html 4.0//","-//spyglass//dtd html 2.0 extended//","-//sun microsystems corp.//dtd hotjava html//","-//sun microsystems corp.//dtd hotjava strict html//","-//w3c//dtd html 3 1995-03-24//","-//w3c//dtd html 3.2 draft//","-//w3c//dtd html 3.2 final//","-//w3c//dtd html 3.2//","-//w3c//dtd html 3.2s draft//","-//w3c//dtd html 4.0 frameset//","-//w3c//dtd html 4.0 transitional//","-//w3c//dtd html experimental 19960712//","-//w3c//dtd html experimental 970421//","-//w3c//dtd w3 html//","-//w3o//dtd w3 html 3.0//","-//webtechs//dtd mozilla html 2.0//","-//webtechs//dtd mozilla html//"],Dh=[...mu,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"],Ph=new Set(["-//w3o//dtd w3 html strict 3.0//en//","-/w3c/dtd html 4.0 transitional/en","html"]),gu=["-//w3c//dtd xhtml 1.0 frameset//","-//w3c//dtd xhtml 1.0 transitional//"],Mh=[...gu,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"];function bu(e,t){return t.some(n=>e.startsWith(n))}function Bh(e){return e.name===pu&&e.publicId===null&&(e.systemId===null||e.systemId===Rh)}function Fh(e){if(e.name!==pu)return rt.QUIRKS;const{systemId:t}=e;if(t&&t.toLowerCase()===Oh)return rt.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),Ph.has(n))return rt.QUIRKS;let r=t===null?Dh:mu;if(bu(n,r))return rt.QUIRKS;if(r=t===null?gu:Mh,bu(n,r))return rt.LIMITED_QUIRKS}return rt.NO_QUIRKS}const Eu={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},Hh="definitionurl",Uh="definitionURL",zh=new Map(["attributeName","attributeType","baseFrequency","baseProfile","calcMode","clipPathUnits","diffuseConstant","edgeMode","filterUnits","glyphRef","gradientTransform","gradientUnits","kernelMatrix","kernelUnitLength","keyPoints","keySplines","keyTimes","lengthAdjust","limitingConeAngle","markerHeight","markerUnits","markerWidth","maskContentUnits","maskUnits","numOctaves","pathLength","patternContentUnits","patternTransform","patternUnits","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","refX","refY","repeatCount","repeatDur","requiredExtensions","requiredFeatures","specularConstant","specularExponent","spreadMethod","startOffset","stdDeviation","stitchTiles","surfaceScale","systemLanguage","tableValues","targetX","targetY","textLength","viewBox","viewTarget","xChannelSelector","yChannelSelector","zoomAndPan"].map(e=>[e.toLowerCase(),e])),$h=new Map([["xlink:actuate",{prefix:"xlink",name:"actuate",namespace:O.XLINK}],["xlink:arcrole",{prefix:"xlink",name:"arcrole",namespace:O.XLINK}],["xlink:href",{prefix:"xlink",name:"href",namespace:O.XLINK}],["xlink:role",{prefix:"xlink",name:"role",namespace:O.XLINK}],["xlink:show",{prefix:"xlink",name:"show",namespace:O.XLINK}],["xlink:title",{prefix:"xlink",name:"title",namespace:O.XLINK}],["xlink:type",{prefix:"xlink",name:"type",namespace:O.XLINK}],["xml:lang",{prefix:"xml",name:"lang",namespace:O.XML}],["xml:space",{prefix:"xml",name:"space",namespace:O.XML}],["xmlns",{prefix:"",name:"xmlns",namespace:O.XMLNS}],["xmlns:xlink",{prefix:"xmlns",name:"xlink",namespace:O.XMLNS}]]),Yh=new Map(["altGlyph","altGlyphDef","altGlyphItem","animateColor","animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","glyphRef","linearGradient","radialGradient","textPath"].map(e=>[e.toLowerCase(),e])),jh=new Set([l.B,l.BIG,l.BLOCKQUOTE,l.BODY,l.BR,l.CENTER,l.CODE,l.DD,l.DIV,l.DL,l.DT,l.EM,l.EMBED,l.H1,l.H2,l.H3,l.H4,l.H5,l.H6,l.HEAD,l.HR,l.I,l.IMG,l.LI,l.LISTING,l.MENU,l.META,l.NOBR,l.OL,l.P,l.PRE,l.RUBY,l.S,l.SMALL,l.SPAN,l.STRONG,l.STRIKE,l.SUB,l.SUP,l.TABLE,l.TT,l.U,l.UL,l.VAR]);function Vh(e){const t=e.tagID;return t===l.FONT&&e.attrs.some(({name:r})=>r===Wt.COLOR||r===Wt.SIZE||r===Wt.FACE)||jh.has(t)}function Tu(e){for(let t=0;t<e.attrs.length;t++)if(e.attrs[t].name===Hh){e.attrs[t].name=Uh;break}}function _u(e){for(let t=0;t<e.attrs.length;t++){const n=zh.get(e.attrs[t].name);n!=null&&(e.attrs[t].name=n)}}function ua(e){for(let t=0;t<e.attrs.length;t++){const n=$h.get(e.attrs[t].name);n&&(e.attrs[t].prefix=n.prefix,e.attrs[t].name=n.name,e.attrs[t].namespace=n.namespace)}}function qh(e){const t=Yh.get(e.tagName);t!=null&&(e.tagName=t,e.tagID=gn(e.tagName))}function Wh(e,t){return t===O.MATHML&&(e===l.MI||e===l.MO||e===l.MN||e===l.MS||e===l.MTEXT)}function Gh(e,t,n){if(t===O.MATHML&&e===l.ANNOTATION_XML){for(let r=0;r<n.length;r++)if(n[r].name===Wt.ENCODING){const i=n[r].value.toLowerCase();return i===Eu.TEXT_HTML||i===Eu.APPLICATION_XML}}return t===O.SVG&&(e===l.FOREIGN_OBJECT||e===l.DESC||e===l.TITLE)}function Qh(e,t,n,r){return(!r||r===O.HTML)&&Gh(e,t,n)||(!r||r===O.MATHML)&&Wh(e,t)}const Kh="hidden",Xh=8,Zh=3;var T;(function(e){e[e.INITIAL=0]="INITIAL",e[e.BEFORE_HTML=1]="BEFORE_HTML",e[e.BEFORE_HEAD=2]="BEFORE_HEAD",e[e.IN_HEAD=3]="IN_HEAD",e[e.IN_HEAD_NO_SCRIPT=4]="IN_HEAD_NO_SCRIPT",e[e.AFTER_HEAD=5]="AFTER_HEAD",e[e.IN_BODY=6]="IN_BODY",e[e.TEXT=7]="TEXT",e[e.IN_TABLE=8]="IN_TABLE",e[e.IN_TABLE_TEXT=9]="IN_TABLE_TEXT",e[e.IN_CAPTION=10]="IN_CAPTION",e[e.IN_COLUMN_GROUP=11]="IN_COLUMN_GROUP",e[e.IN_TABLE_BODY=12]="IN_TABLE_BODY",e[e.IN_ROW=13]="IN_ROW",e[e.IN_CELL=14]="IN_CELL",e[e.IN_SELECT=15]="IN_SELECT",e[e.IN_SELECT_IN_TABLE=16]="IN_SELECT_IN_TABLE",e[e.IN_TEMPLATE=17]="IN_TEMPLATE",e[e.AFTER_BODY=18]="AFTER_BODY",e[e.IN_FRAMESET=19]="IN_FRAMESET",e[e.AFTER_FRAMESET=20]="AFTER_FRAMESET",e[e.AFTER_AFTER_BODY=21]="AFTER_AFTER_BODY",e[e.AFTER_AFTER_FRAMESET=22]="AFTER_AFTER_FRAMESET"})(T||(T={}));const Jh={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},ku=new Set([l.TABLE,l.TBODY,l.TFOOT,l.THEAD,l.TR]),xu={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:Lt,onParseError:null};class yu{constructor(t,n,r=null,i=null){this.fragmentContext=r,this.scriptHandler=i,this.currentToken=null,this.stopped=!1,this.insertionMode=T.INITIAL,this.originalInsertionMode=T.INITIAL,this.headElement=null,this.formElement=null,this.currentNotInHTML=!1,this.tmplInsertionModeStack=[],this.pendingCharacterTokens=[],this.hasNonWhitespacePendingCharacterToken=!1,this.framesetOk=!0,this.skipNextNewLine=!1,this.fosterParentingEnabled=!1,this.options={...xu,...t},this.treeAdapter=this.options.treeAdapter,this.onParseError=this.options.onParseError,this.onParseError&&(this.options.sourceCodeLocationInfo=!0),this.document=n??this.treeAdapter.createDocument(),this.tokenizer=new yh(this.options,this),this.activeFormattingElements=new Lh(this.treeAdapter),this.fragmentContextID=r?gn(this.treeAdapter.getTagName(r)):l.UNKNOWN,this._setContextModes(r??this.document,this.fragmentContextID),this.openElements=new vh(this.document,this.treeAdapter,this)}static parse(t,n){const r=new this(n);return r.tokenizer.write(t,!0),r.document}static getFragmentParser(t,n){const r={...xu,...n};t??(t=r.treeAdapter.createElement(N.TEMPLATE,O.HTML,[]));const i=r.treeAdapter.createElement("documentmock",O.HTML,[]),a=new this(r,i,t);return a.fragmentContextID===l.TEMPLATE&&a.tmplInsertionModeStack.unshift(T.IN_TEMPLATE),a._initTokenizerForFragmentParsing(),a._insertFakeRootElement(),a._resetInsertionMode(),a._findFormInFragmentContext(),a}getFragment(){const t=this.treeAdapter.getFirstChild(this.document),n=this.treeAdapter.createDocumentFragment();return this._adoptNodes(t,n),n}_err(t,n,r){var i;if(!this.onParseError)return;const a=(i=t.location)!==null&&i!==void 0?i:Jh,s={code:n,startLine:a.startLine,startCol:a.startCol,startOffset:a.startOffset,endLine:r?a.startLine:a.endLine,endCol:r?a.startCol:a.endCol,endOffset:r?a.startOffset:a.endOffset};this.onParseError(s)}onItemPush(t,n,r){var i,a;(a=(i=this.treeAdapter).onItemPush)===null||a===void 0||a.call(i,t),r&&this.openElements.stackTop>0&&this._setContextModes(t,n)}onItemPop(t,n){var r,i;if(this.options.sourceCodeLocationInfo&&this._setEndLocation(t,this.currentToken),(i=(r=this.treeAdapter).onItemPop)===null||i===void 0||i.call(r,t,this.openElements.current),n){let a,s;this.openElements.stackTop===0&&this.fragmentContext?(a=this.fragmentContext,s=this.fragmentContextID):{current:a,currentTagId:s}=this.openElements,this._setContextModes(a,s)}}_setContextModes(t,n){const r=t===this.document||t&&this.treeAdapter.getNamespaceURI(t)===O.HTML;this.currentNotInHTML=!r,this.tokenizer.inForeignNode=!r&&t!==void 0&&n!==void 0&&!this._isIntegrationPoint(n,t)}_switchToTextParsing(t,n){this._insertElement(t,O.HTML),this.tokenizer.state=n,this.originalInsertionMode=this.insertionMode,this.insertionMode=T.TEXT}switchToPlaintextParsing(){this.insertionMode=T.TEXT,this.originalInsertionMode=T.IN_BODY,this.tokenizer.state=Ae.PLAINTEXT}_getAdjustedCurrentElement(){return this.openElements.stackTop===0&&this.fragmentContext?this.fragmentContext:this.openElements.current}_findFormInFragmentContext(){let t=this.fragmentContext;for(;t;){if(this.treeAdapter.getTagName(t)===N.FORM){this.formElement=t;break}t=this.treeAdapter.getParentNode(t)}}_initTokenizerForFragmentParsing(){if(!(!this.fragmentContext||this.treeAdapter.getNamespaceURI(this.fragmentContext)!==O.HTML))switch(this.fragmentContextID){case l.TITLE:case l.TEXTAREA:{this.tokenizer.state=Ae.RCDATA;break}case l.STYLE:case l.XMP:case l.IFRAME:case l.NOEMBED:case l.NOFRAMES:case l.NOSCRIPT:{this.tokenizer.state=Ae.RAWTEXT;break}case l.SCRIPT:{this.tokenizer.state=Ae.SCRIPT_DATA;break}case l.PLAINTEXT:{this.tokenizer.state=Ae.PLAINTEXT;break}}}_setDocumentType(t){const n=t.name||"",r=t.publicId||"",i=t.systemId||"";if(this.treeAdapter.setDocumentType(this.document,n,r,i),t.location){const s=this.treeAdapter.getChildNodes(this.document).find(o=>this.treeAdapter.isDocumentTypeNode(o));s&&this.treeAdapter.setNodeSourceCodeLocation(s,t.location)}}_attachElementToTree(t,n){if(this.options.sourceCodeLocationInfo){const r=n&&{...n,startTag:n};this.treeAdapter.setNodeSourceCodeLocation(t,r)}if(this._shouldFosterParentOnInsertion())this._fosterParentElement(t);else{const r=this.openElements.currentTmplContentOrNode;this.treeAdapter.appendChild(r??this.document,t)}}_appendElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r,t.location)}_insertElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r,t.location),this.openElements.push(r,t.tagID)}_insertFakeElement(t,n){const r=this.treeAdapter.createElement(t,O.HTML,[]);this._attachElementToTree(r,null),this.openElements.push(r,n)}_insertTemplate(t){const n=this.treeAdapter.createElement(t.tagName,O.HTML,t.attrs),r=this.treeAdapter.createDocumentFragment();this.treeAdapter.setTemplateContent(n,r),this._attachElementToTree(n,t.location),this.openElements.push(n,t.tagID),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(r,null)}_insertFakeRootElement(){const t=this.treeAdapter.createElement(N.HTML,O.HTML,[]);this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(t,null),this.treeAdapter.appendChild(this.openElements.current,t),this.openElements.push(t,l.HTML)}_appendCommentNode(t,n){const r=this.treeAdapter.createCommentNode(t.data);this.treeAdapter.appendChild(n,r),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(r,t.location)}_insertCharacters(t){let n,r;if(this._shouldFosterParentOnInsertion()?({parent:n,beforeElement:r}=this._findFosterParentingLocation(),r?this.treeAdapter.insertTextBefore(n,t.chars,r):this.treeAdapter.insertText(n,t.chars)):(n=this.openElements.currentTmplContentOrNode,this.treeAdapter.insertText(n,t.chars)),!t.location)return;const i=this.treeAdapter.getChildNodes(n),a=r?i.lastIndexOf(r):i.length,s=i[a-1];if(this.treeAdapter.getNodeSourceCodeLocation(s)){const{endLine:u,endCol:c,endOffset:f}=t.location;this.treeAdapter.updateNodeSourceCodeLocation(s,{endLine:u,endCol:c,endOffset:f})}else this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(s,t.location)}_adoptNodes(t,n){for(let r=this.treeAdapter.getFirstChild(t);r;r=this.treeAdapter.getFirstChild(t))this.treeAdapter.detachNode(r),this.treeAdapter.appendChild(n,r)}_setEndLocation(t,n){if(this.treeAdapter.getNodeSourceCodeLocation(t)&&n.location){const r=n.location,i=this.treeAdapter.getTagName(t),a=n.type===re.END_TAG&&i===n.tagName?{endTag:{...r},endLine:r.endLine,endCol:r.endCol,endOffset:r.endOffset}:{endLine:r.startLine,endCol:r.startCol,endOffset:r.startOffset};this.treeAdapter.updateNodeSourceCodeLocation(t,a)}}shouldProcessStartTagTokenInForeignContent(t){if(!this.currentNotInHTML)return!1;let n,r;return this.openElements.stackTop===0&&this.fragmentContext?(n=this.fragmentContext,r=this.fragmentContextID):{current:n,currentTagId:r}=this.openElements,t.tagID===l.SVG&&this.treeAdapter.getTagName(n)===N.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(n)===O.MATHML?!1:this.tokenizer.inForeignNode||(t.tagID===l.MGLYPH||t.tagID===l.MALIGNMARK)&&r!==void 0&&!this._isIntegrationPoint(r,n,O.HTML)}_processToken(t){switch(t.type){case re.CHARACTER:{this.onCharacter(t);break}case re.NULL_CHARACTER:{this.onNullCharacter(t);break}case re.COMMENT:{this.onComment(t);break}case re.DOCTYPE:{this.onDoctype(t);break}case re.START_TAG:{this._processStartTag(t);break}case re.END_TAG:{this.onEndTag(t);break}case re.EOF:{this.onEof(t);break}case re.WHITESPACE_CHARACTER:{this.onWhitespaceCharacter(t);break}}}_isIntegrationPoint(t,n,r){const i=this.treeAdapter.getNamespaceURI(n),a=this.treeAdapter.getAttrList(n);return Qh(t,i,a,r)}_reconstructActiveFormattingElements(){const t=this.activeFormattingElements.entries.length;if(t){const n=this.activeFormattingElements.entries.findIndex(i=>i.type===ht.Marker||this.openElements.contains(i.element)),r=n===-1?t-1:n-1;for(let i=r;i>=0;i--){const a=this.activeFormattingElements.entries[i];this._insertElement(a.token,this.treeAdapter.getNamespaceURI(a.element)),a.element=this.openElements.current}}}_closeTableCell(){this.openElements.generateImpliedEndTags(),this.openElements.popUntilTableCellPopped(),this.activeFormattingElements.clearToLastMarker(),this.insertionMode=T.IN_ROW}_closePElement(){this.openElements.generateImpliedEndTagsWithExclusion(l.P),this.openElements.popUntilTagNamePopped(l.P)}_resetInsertionMode(){for(let t=this.openElements.stackTop;t>=0;t--)switch(t===0&&this.fragmentContext?this.fragmentContextID:this.openElements.tagIDs[t]){case l.TR:{this.insertionMode=T.IN_ROW;return}case l.TBODY:case l.THEAD:case l.TFOOT:{this.insertionMode=T.IN_TABLE_BODY;return}case l.CAPTION:{this.insertionMode=T.IN_CAPTION;return}case l.COLGROUP:{this.insertionMode=T.IN_COLUMN_GROUP;return}case l.TABLE:{this.insertionMode=T.IN_TABLE;return}case l.BODY:{this.insertionMode=T.IN_BODY;return}case l.FRAMESET:{this.insertionMode=T.IN_FRAMESET;return}case l.SELECT:{this._resetInsertionModeForSelect(t);return}case l.TEMPLATE:{this.insertionMode=this.tmplInsertionModeStack[0];return}case l.HTML:{this.insertionMode=this.headElement?T.AFTER_HEAD:T.BEFORE_HEAD;return}case l.TD:case l.TH:{if(t>0){this.insertionMode=T.IN_CELL;return}break}case l.HEAD:{if(t>0){this.insertionMode=T.IN_HEAD;return}break}}this.insertionMode=T.IN_BODY}_resetInsertionModeForSelect(t){if(t>0)for(let n=t-1;n>0;n--){const r=this.openElements.tagIDs[n];if(r===l.TEMPLATE)break;if(r===l.TABLE){this.insertionMode=T.IN_SELECT_IN_TABLE;return}}this.insertionMode=T.IN_SELECT}_isElementCausesFosterParenting(t){return ku.has(t)}_shouldFosterParentOnInsertion(){return this.fosterParentingEnabled&&this.openElements.currentTagId!==void 0&&this._isElementCausesFosterParenting(this.openElements.currentTagId)}_findFosterParentingLocation(){for(let t=this.openElements.stackTop;t>=0;t--){const n=this.openElements.items[t];switch(this.openElements.tagIDs[t]){case l.TEMPLATE:{if(this.treeAdapter.getNamespaceURI(n)===O.HTML)return{parent:this.treeAdapter.getTemplateContent(n),beforeElement:null};break}case l.TABLE:{const r=this.treeAdapter.getParentNode(n);return r?{parent:r,beforeElement:n}:{parent:this.openElements.items[t-1],beforeElement:null}}}}return{parent:this.openElements.items[0],beforeElement:null}}_fosterParentElement(t){const n=this._findFosterParentingLocation();n.beforeElement?this.treeAdapter.insertBefore(n.parent,t,n.beforeElement):this.treeAdapter.appendChild(n.parent,t)}_isSpecialElement(t,n){const r=this.treeAdapter.getNamespaceURI(t);return Th[r].has(n)}onCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){N1(this,t);return}switch(this.insertionMode){case T.INITIAL:{$n(this,t);break}case T.BEFORE_HTML:{Yn(this,t);break}case T.BEFORE_HEAD:{jn(this,t);break}case T.IN_HEAD:{Vn(this,t);break}case T.IN_HEAD_NO_SCRIPT:{qn(this,t);break}case T.AFTER_HEAD:{Wn(this,t);break}case T.IN_BODY:case T.IN_CAPTION:case T.IN_CELL:case T.IN_TEMPLATE:{Au(this,t);break}case T.TEXT:case T.IN_SELECT:case T.IN_SELECT_IN_TABLE:{this._insertCharacters(t);break}case T.IN_TABLE:case T.IN_TABLE_BODY:case T.IN_ROW:{fa(this,t);break}case T.IN_TABLE_TEXT:{Ou(this,t);break}case T.IN_COLUMN_GROUP:{$r(this,t);break}case T.AFTER_BODY:{Vr(this,t);break}case T.AFTER_AFTER_BODY:{qr(this,t);break}}}onNullCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){I1(this,t);return}switch(this.insertionMode){case T.INITIAL:{$n(this,t);break}case T.BEFORE_HTML:{Yn(this,t);break}case T.BEFORE_HEAD:{jn(this,t);break}case T.IN_HEAD:{Vn(this,t);break}case T.IN_HEAD_NO_SCRIPT:{qn(this,t);break}case T.AFTER_HEAD:{Wn(this,t);break}case T.TEXT:{this._insertCharacters(t);break}case T.IN_TABLE:case T.IN_TABLE_BODY:case T.IN_ROW:{fa(this,t);break}case T.IN_COLUMN_GROUP:{$r(this,t);break}case T.AFTER_BODY:{Vr(this,t);break}case T.AFTER_AFTER_BODY:{qr(this,t);break}}}onComment(t){if(this.skipNextNewLine=!1,this.currentNotInHTML){ca(this,t);return}switch(this.insertionMode){case T.INITIAL:case T.BEFORE_HTML:case T.BEFORE_HEAD:case T.IN_HEAD:case T.IN_HEAD_NO_SCRIPT:case T.AFTER_HEAD:case T.IN_BODY:case T.IN_TABLE:case T.IN_CAPTION:case T.IN_COLUMN_GROUP:case T.IN_TABLE_BODY:case T.IN_ROW:case T.IN_CELL:case T.IN_SELECT:case T.IN_SELECT_IN_TABLE:case T.IN_TEMPLATE:case T.IN_FRAMESET:case T.AFTER_FRAMESET:{ca(this,t);break}case T.IN_TABLE_TEXT:{Kn(this,t);break}case T.AFTER_BODY:{sp(this,t);break}case T.AFTER_AFTER_BODY:case T.AFTER_AFTER_FRAMESET:{op(this,t);break}}}onDoctype(t){switch(this.skipNextNewLine=!1,this.insertionMode){case T.INITIAL:{up(this,t);break}case T.BEFORE_HEAD:case T.IN_HEAD:case T.IN_HEAD_NO_SCRIPT:case T.AFTER_HEAD:{this._err(t,v.misplacedDoctype);break}case T.IN_TABLE_TEXT:{Kn(this,t);break}}}onStartTag(t){this.skipNextNewLine=!1,this.currentToken=t,this._processStartTag(t),t.selfClosing&&!t.ackSelfClosing&&this._err(t,v.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(t){this.shouldProcessStartTagTokenInForeignContent(t)?v1(this,t):this._startTagOutsideForeignContent(t)}_startTagOutsideForeignContent(t){switch(this.insertionMode){case T.INITIAL:{$n(this,t);break}case T.BEFORE_HTML:{lp(this,t);break}case T.BEFORE_HEAD:{dp(this,t);break}case T.IN_HEAD:{ot(this,t);break}case T.IN_HEAD_NO_SCRIPT:{pp(this,t);break}case T.AFTER_HEAD:{gp(this,t);break}case T.IN_BODY:{Me(this,t);break}case T.IN_TABLE:{bn(this,t);break}case T.IN_TABLE_TEXT:{Kn(this,t);break}case T.IN_CAPTION:{f1(this,t);break}case T.IN_COLUMN_GROUP:{ha(this,t);break}case T.IN_TABLE_BODY:{Yr(this,t);break}case T.IN_ROW:{jr(this,t);break}case T.IN_CELL:{m1(this,t);break}case T.IN_SELECT:{Mu(this,t);break}case T.IN_SELECT_IN_TABLE:{b1(this,t);break}case T.IN_TEMPLATE:{T1(this,t);break}case T.AFTER_BODY:{k1(this,t);break}case T.IN_FRAMESET:{x1(this,t);break}case T.AFTER_FRAMESET:{w1(this,t);break}case T.AFTER_AFTER_BODY:{C1(this,t);break}case T.AFTER_AFTER_FRAMESET:{S1(this,t);break}}}onEndTag(t){this.skipNextNewLine=!1,this.currentToken=t,this.currentNotInHTML?L1(this,t):this._endTagOutsideForeignContent(t)}_endTagOutsideForeignContent(t){switch(this.insertionMode){case T.INITIAL:{$n(this,t);break}case T.BEFORE_HTML:{cp(this,t);break}case T.BEFORE_HEAD:{fp(this,t);break}case T.IN_HEAD:{hp(this,t);break}case T.IN_HEAD_NO_SCRIPT:{mp(this,t);break}case T.AFTER_HEAD:{bp(this,t);break}case T.IN_BODY:{zr(this,t);break}case T.TEXT:{n1(this,t);break}case T.IN_TABLE:{Gn(this,t);break}case T.IN_TABLE_TEXT:{Kn(this,t);break}case T.IN_CAPTION:{h1(this,t);break}case T.IN_COLUMN_GROUP:{p1(this,t);break}case T.IN_TABLE_BODY:{pa(this,t);break}case T.IN_ROW:{Pu(this,t);break}case T.IN_CELL:{g1(this,t);break}case T.IN_SELECT:{Bu(this,t);break}case T.IN_SELECT_IN_TABLE:{E1(this,t);break}case T.IN_TEMPLATE:{_1(this,t);break}case T.AFTER_BODY:{Hu(this,t);break}case T.IN_FRAMESET:{y1(this,t);break}case T.AFTER_FRAMESET:{A1(this,t);break}case T.AFTER_AFTER_BODY:{qr(this,t);break}}}onEof(t){switch(this.insertionMode){case T.INITIAL:{$n(this,t);break}case T.BEFORE_HTML:{Yn(this,t);break}case T.BEFORE_HEAD:{jn(this,t);break}case T.IN_HEAD:{Vn(this,t);break}case T.IN_HEAD_NO_SCRIPT:{qn(this,t);break}case T.AFTER_HEAD:{Wn(this,t);break}case T.IN_BODY:case T.IN_TABLE:case T.IN_CAPTION:case T.IN_COLUMN_GROUP:case T.IN_TABLE_BODY:case T.IN_ROW:case T.IN_CELL:case T.IN_SELECT:case T.IN_SELECT_IN_TABLE:{Lu(this,t);break}case T.TEXT:{r1(this,t);break}case T.IN_TABLE_TEXT:{Kn(this,t);break}case T.IN_TEMPLATE:{Fu(this,t);break}case T.AFTER_BODY:case T.IN_FRAMESET:case T.AFTER_FRAMESET:case T.AFTER_AFTER_BODY:case T.AFTER_AFTER_FRAMESET:{da(this,t);break}}}onWhitespaceCharacter(t){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,t.chars.charCodeAt(0)===g.LINE_FEED)){if(t.chars.length===1)return;t.chars=t.chars.substr(1)}if(this.tokenizer.inForeignNode){this._insertCharacters(t);return}switch(this.insertionMode){case T.IN_HEAD:case T.IN_HEAD_NO_SCRIPT:case T.AFTER_HEAD:case T.TEXT:case T.IN_COLUMN_GROUP:case T.IN_SELECT:case T.IN_SELECT_IN_TABLE:case T.IN_FRAMESET:case T.AFTER_FRAMESET:{this._insertCharacters(t);break}case T.IN_BODY:case T.IN_CAPTION:case T.IN_CELL:case T.IN_TEMPLATE:case T.AFTER_BODY:case T.AFTER_AFTER_BODY:case T.AFTER_AFTER_FRAMESET:{wu(this,t);break}case T.IN_TABLE:case T.IN_TABLE_BODY:case T.IN_ROW:{fa(this,t);break}case T.IN_TABLE_TEXT:{Ru(this,t);break}}}}function ep(e,t){let n=e.activeFormattingElements.getElementEntryInScopeWithTagName(t.tagName);return n?e.openElements.contains(n.element)?e.openElements.hasInScope(t.tagID)||(n=null):(e.activeFormattingElements.removeEntry(n),n=null):vu(e,t),n}function tp(e,t){let n=null,r=e.openElements.stackTop;for(;r>=0;r--){const i=e.openElements.items[r];if(i===t.element)break;e._isSpecialElement(i,e.openElements.tagIDs[r])&&(n=i)}return n||(e.openElements.shortenToLength(Math.max(r,0)),e.activeFormattingElements.removeEntry(t)),n}function np(e,t,n){let r=t,i=e.openElements.getCommonAncestor(t);for(let a=0,s=i;s!==n;a++,s=i){i=e.openElements.getCommonAncestor(s);const o=e.activeFormattingElements.getElementEntry(s),u=o&&a>=Zh;!o||u?(u&&e.activeFormattingElements.removeEntry(o),e.openElements.remove(s)):(s=rp(e,o),r===t&&(e.activeFormattingElements.bookmark=o),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(s,r),r=s)}return r}function rp(e,t){const n=e.treeAdapter.getNamespaceURI(t.element),r=e.treeAdapter.createElement(t.token.tagName,n,t.token.attrs);return e.openElements.replace(t.element,r),t.element=r,r}function ip(e,t,n){const r=e.treeAdapter.getTagName(t),i=gn(r);if(e._isElementCausesFosterParenting(i))e._fosterParentElement(n);else{const a=e.treeAdapter.getNamespaceURI(t);i===l.TEMPLATE&&a===O.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function ap(e,t,n){const r=e.treeAdapter.getNamespaceURI(n.element),{token:i}=n,a=e.treeAdapter.createElement(i.tagName,r,i.attrs);e._adoptNodes(t,a),e.treeAdapter.appendChild(t,a),e.activeFormattingElements.insertElementAfterBookmark(a,i),e.activeFormattingElements.removeEntry(n),e.openElements.remove(n.element),e.openElements.insertAfter(t,a,i.tagID)}function la(e,t){for(let n=0;n<Xh;n++){const r=ep(e,t);if(!r)break;const i=tp(e,r);if(!i)break;e.activeFormattingElements.bookmark=r;const a=np(e,i,r.element),s=e.openElements.getCommonAncestor(r.element);e.treeAdapter.detachNode(a),s&&ip(e,s,a),ap(e,i,r)}}function ca(e,t){e._appendCommentNode(t,e.openElements.currentTmplContentOrNode)}function sp(e,t){e._appendCommentNode(t,e.openElements.items[0])}function op(e,t){e._appendCommentNode(t,e.document)}function da(e,t){if(e.stopped=!0,t.location){const n=e.fragmentContext?0:2;for(let r=e.openElements.stackTop;r>=n;r--)e._setEndLocation(e.openElements.items[r],t);if(!e.fragmentContext&&e.openElements.stackTop>=0){const r=e.openElements.items[0],i=e.treeAdapter.getNodeSourceCodeLocation(r);if(i&&!i.endTag&&(e._setEndLocation(r,t),e.openElements.stackTop>=1)){const a=e.openElements.items[1],s=e.treeAdapter.getNodeSourceCodeLocation(a);s&&!s.endTag&&e._setEndLocation(a,t)}}}}function up(e,t){e._setDocumentType(t);const n=t.forceQuirks?rt.QUIRKS:Fh(t);Bh(t)||e._err(t,v.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=T.BEFORE_HTML}function $n(e,t){e._err(t,v.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,rt.QUIRKS),e.insertionMode=T.BEFORE_HTML,e._processToken(t)}function lp(e,t){t.tagID===l.HTML?(e._insertElement(t,O.HTML),e.insertionMode=T.BEFORE_HEAD):Yn(e,t)}function cp(e,t){const n=t.tagID;(n===l.HTML||n===l.HEAD||n===l.BODY||n===l.BR)&&Yn(e,t)}function Yn(e,t){e._insertFakeRootElement(),e.insertionMode=T.BEFORE_HEAD,e._processToken(t)}function dp(e,t){switch(t.tagID){case l.HTML:{Me(e,t);break}case l.HEAD:{e._insertElement(t,O.HTML),e.headElement=e.openElements.current,e.insertionMode=T.IN_HEAD;break}default:jn(e,t)}}function fp(e,t){const n=t.tagID;n===l.HEAD||n===l.BODY||n===l.HTML||n===l.BR?jn(e,t):e._err(t,v.endTagWithoutMatchingOpenElement)}function jn(e,t){e._insertFakeElement(N.HEAD,l.HEAD),e.headElement=e.openElements.current,e.insertionMode=T.IN_HEAD,e._processToken(t)}function ot(e,t){switch(t.tagID){case l.HTML:{Me(e,t);break}case l.BASE:case l.BASEFONT:case l.BGSOUND:case l.LINK:case l.META:{e._appendElement(t,O.HTML),t.ackSelfClosing=!0;break}case l.TITLE:{e._switchToTextParsing(t,Ae.RCDATA);break}case l.NOSCRIPT:{e.options.scriptingEnabled?e._switchToTextParsing(t,Ae.RAWTEXT):(e._insertElement(t,O.HTML),e.insertionMode=T.IN_HEAD_NO_SCRIPT);break}case l.NOFRAMES:case l.STYLE:{e._switchToTextParsing(t,Ae.RAWTEXT);break}case l.SCRIPT:{e._switchToTextParsing(t,Ae.SCRIPT_DATA);break}case l.TEMPLATE:{e._insertTemplate(t),e.activeFormattingElements.insertMarker(),e.framesetOk=!1,e.insertionMode=T.IN_TEMPLATE,e.tmplInsertionModeStack.unshift(T.IN_TEMPLATE);break}case l.HEAD:{e._err(t,v.misplacedStartTagForHeadElement);break}default:Vn(e,t)}}function hp(e,t){switch(t.tagID){case l.HEAD:{e.openElements.pop(),e.insertionMode=T.AFTER_HEAD;break}case l.BODY:case l.BR:case l.HTML:{Vn(e,t);break}case l.TEMPLATE:{Gt(e,t);break}default:e._err(t,v.endTagWithoutMatchingOpenElement)}}function Gt(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==l.TEMPLATE&&e._err(t,v.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(l.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,v.endTagWithoutMatchingOpenElement)}function Vn(e,t){e.openElements.pop(),e.insertionMode=T.AFTER_HEAD,e._processToken(t)}function pp(e,t){switch(t.tagID){case l.HTML:{Me(e,t);break}case l.BASEFONT:case l.BGSOUND:case l.HEAD:case l.LINK:case l.META:case l.NOFRAMES:case l.STYLE:{ot(e,t);break}case l.NOSCRIPT:{e._err(t,v.nestedNoscriptInHead);break}default:qn(e,t)}}function mp(e,t){switch(t.tagID){case l.NOSCRIPT:{e.openElements.pop(),e.insertionMode=T.IN_HEAD;break}case l.BR:{qn(e,t);break}default:e._err(t,v.endTagWithoutMatchingOpenElement)}}function qn(e,t){const n=t.type===re.EOF?v.openElementsLeftAfterEof:v.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=T.IN_HEAD,e._processToken(t)}function gp(e,t){switch(t.tagID){case l.HTML:{Me(e,t);break}case l.BODY:{e._insertElement(t,O.HTML),e.framesetOk=!1,e.insertionMode=T.IN_BODY;break}case l.FRAMESET:{e._insertElement(t,O.HTML),e.insertionMode=T.IN_FRAMESET;break}case l.BASE:case l.BASEFONT:case l.BGSOUND:case l.LINK:case l.META:case l.NOFRAMES:case l.SCRIPT:case l.STYLE:case l.TEMPLATE:case l.TITLE:{e._err(t,v.abandonedHeadElementChild),e.openElements.push(e.headElement,l.HEAD),ot(e,t),e.openElements.remove(e.headElement);break}case l.HEAD:{e._err(t,v.misplacedStartTagForHeadElement);break}default:Wn(e,t)}}function bp(e,t){switch(t.tagID){case l.BODY:case l.HTML:case l.BR:{Wn(e,t);break}case l.TEMPLATE:{Gt(e,t);break}default:e._err(t,v.endTagWithoutMatchingOpenElement)}}function Wn(e,t){e._insertFakeElement(N.BODY,l.BODY),e.insertionMode=T.IN_BODY,Ur(e,t)}function Ur(e,t){switch(t.type){case re.CHARACTER:{Au(e,t);break}case re.WHITESPACE_CHARACTER:{wu(e,t);break}case re.COMMENT:{ca(e,t);break}case re.START_TAG:{Me(e,t);break}case re.END_TAG:{zr(e,t);break}case re.EOF:{Lu(e,t);break}}}function wu(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function Au(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function Ep(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function Tp(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function _p(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();e.framesetOk&&n&&(e.treeAdapter.detachNode(n),e.openElements.popAllUpToHtmlElement(),e._insertElement(t,O.HTML),e.insertionMode=T.IN_FRAMESET)}function kp(e,t){e.openElements.hasInButtonScope(l.P)&&e._closePElement(),e._insertElement(t,O.HTML)}function xp(e,t){e.openElements.hasInButtonScope(l.P)&&e._closePElement(),e.openElements.currentTagId!==void 0&&sa.has(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,O.HTML)}function yp(e,t){e.openElements.hasInButtonScope(l.P)&&e._closePElement(),e._insertElement(t,O.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function wp(e,t){const n=e.openElements.tmplCount>0;(!e.formElement||n)&&(e.openElements.hasInButtonScope(l.P)&&e._closePElement(),e._insertElement(t,O.HTML),n||(e.formElement=e.openElements.current))}function Ap(e,t){e.framesetOk=!1;const n=t.tagID;for(let r=e.openElements.stackTop;r>=0;r--){const i=e.openElements.tagIDs[r];if(n===l.LI&&i===l.LI||(n===l.DD||n===l.DT)&&(i===l.DD||i===l.DT)){e.openElements.generateImpliedEndTagsWithExclusion(i),e.openElements.popUntilTagNamePopped(i);break}if(i!==l.ADDRESS&&i!==l.DIV&&i!==l.P&&e._isSpecialElement(e.openElements.items[r],i))break}e.openElements.hasInButtonScope(l.P)&&e._closePElement(),e._insertElement(t,O.HTML)}function Cp(e,t){e.openElements.hasInButtonScope(l.P)&&e._closePElement(),e._insertElement(t,O.HTML),e.tokenizer.state=Ae.PLAINTEXT}function Sp(e,t){e.openElements.hasInScope(l.BUTTON)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(l.BUTTON)),e._reconstructActiveFormattingElements(),e._insertElement(t,O.HTML),e.framesetOk=!1}function Ip(e,t){const n=e.activeFormattingElements.getElementEntryInScopeWithTagName(N.A);n&&(la(e,t),e.openElements.remove(n.element),e.activeFormattingElements.removeEntry(n)),e._reconstructActiveFormattingElements(),e._insertElement(t,O.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function Np(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,O.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function vp(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(l.NOBR)&&(la(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,O.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function Lp(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,O.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function Rp(e,t){e.treeAdapter.getDocumentMode(e.document)!==rt.QUIRKS&&e.openElements.hasInButtonScope(l.P)&&e._closePElement(),e._insertElement(t,O.HTML),e.framesetOk=!1,e.insertionMode=T.IN_TABLE}function Cu(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,O.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function Su(e){const t=au(e,Wt.TYPE);return t!=null&&t.toLowerCase()===Kh}function Op(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,O.HTML),Su(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function Dp(e,t){e._appendElement(t,O.HTML),t.ackSelfClosing=!0}function Pp(e,t){e.openElements.hasInButtonScope(l.P)&&e._closePElement(),e._appendElement(t,O.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function Mp(e,t){t.tagName=N.IMG,t.tagID=l.IMG,Cu(e,t)}function Bp(e,t){e._insertElement(t,O.HTML),e.skipNextNewLine=!0,e.tokenizer.state=Ae.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=T.TEXT}function Fp(e,t){e.openElements.hasInButtonScope(l.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,Ae.RAWTEXT)}function Hp(e,t){e.framesetOk=!1,e._switchToTextParsing(t,Ae.RAWTEXT)}function Iu(e,t){e._switchToTextParsing(t,Ae.RAWTEXT)}function Up(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,O.HTML),e.framesetOk=!1,e.insertionMode=e.insertionMode===T.IN_TABLE||e.insertionMode===T.IN_CAPTION||e.insertionMode===T.IN_TABLE_BODY||e.insertionMode===T.IN_ROW||e.insertionMode===T.IN_CELL?T.IN_SELECT_IN_TABLE:T.IN_SELECT}function zp(e,t){e.openElements.currentTagId===l.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,O.HTML)}function $p(e,t){e.openElements.hasInScope(l.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,O.HTML)}function Yp(e,t){e.openElements.hasInScope(l.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(l.RTC),e._insertElement(t,O.HTML)}function jp(e,t){e._reconstructActiveFormattingElements(),Tu(t),ua(t),t.selfClosing?e._appendElement(t,O.MATHML):e._insertElement(t,O.MATHML),t.ackSelfClosing=!0}function Vp(e,t){e._reconstructActiveFormattingElements(),_u(t),ua(t),t.selfClosing?e._appendElement(t,O.SVG):e._insertElement(t,O.SVG),t.ackSelfClosing=!0}function Nu(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,O.HTML)}function Me(e,t){switch(t.tagID){case l.I:case l.S:case l.B:case l.U:case l.EM:case l.TT:case l.BIG:case l.CODE:case l.FONT:case l.SMALL:case l.STRIKE:case l.STRONG:{Np(e,t);break}case l.A:{Ip(e,t);break}case l.H1:case l.H2:case l.H3:case l.H4:case l.H5:case l.H6:{xp(e,t);break}case l.P:case l.DL:case l.OL:case l.UL:case l.DIV:case l.DIR:case l.NAV:case l.MAIN:case l.MENU:case l.ASIDE:case l.CENTER:case l.FIGURE:case l.FOOTER:case l.HEADER:case l.HGROUP:case l.DIALOG:case l.DETAILS:case l.ADDRESS:case l.ARTICLE:case l.SEARCH:case l.SECTION:case l.SUMMARY:case l.FIELDSET:case l.BLOCKQUOTE:case l.FIGCAPTION:{kp(e,t);break}case l.LI:case l.DD:case l.DT:{Ap(e,t);break}case l.BR:case l.IMG:case l.WBR:case l.AREA:case l.EMBED:case l.KEYGEN:{Cu(e,t);break}case l.HR:{Pp(e,t);break}case l.RB:case l.RTC:{$p(e,t);break}case l.RT:case l.RP:{Yp(e,t);break}case l.PRE:case l.LISTING:{yp(e,t);break}case l.XMP:{Fp(e,t);break}case l.SVG:{Vp(e,t);break}case l.HTML:{Ep(e,t);break}case l.BASE:case l.LINK:case l.META:case l.STYLE:case l.TITLE:case l.SCRIPT:case l.BGSOUND:case l.BASEFONT:case l.TEMPLATE:{ot(e,t);break}case l.BODY:{Tp(e,t);break}case l.FORM:{wp(e,t);break}case l.NOBR:{vp(e,t);break}case l.MATH:{jp(e,t);break}case l.TABLE:{Rp(e,t);break}case l.INPUT:{Op(e,t);break}case l.PARAM:case l.TRACK:case l.SOURCE:{Dp(e,t);break}case l.IMAGE:{Mp(e,t);break}case l.BUTTON:{Sp(e,t);break}case l.APPLET:case l.OBJECT:case l.MARQUEE:{Lp(e,t);break}case l.IFRAME:{Hp(e,t);break}case l.SELECT:{Up(e,t);break}case l.OPTION:case l.OPTGROUP:{zp(e,t);break}case l.NOEMBED:case l.NOFRAMES:{Iu(e,t);break}case l.FRAMESET:{_p(e,t);break}case l.TEXTAREA:{Bp(e,t);break}case l.NOSCRIPT:{e.options.scriptingEnabled?Iu(e,t):Nu(e,t);break}case l.PLAINTEXT:{Cp(e,t);break}case l.COL:case l.TH:case l.TD:case l.TR:case l.HEAD:case l.FRAME:case l.TBODY:case l.TFOOT:case l.THEAD:case l.CAPTION:case l.COLGROUP:break;default:Nu(e,t)}}function qp(e,t){if(e.openElements.hasInScope(l.BODY)&&(e.insertionMode=T.AFTER_BODY,e.options.sourceCodeLocationInfo)){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e._setEndLocation(n,t)}}function Wp(e,t){e.openElements.hasInScope(l.BODY)&&(e.insertionMode=T.AFTER_BODY,Hu(e,t))}function Gp(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function Qp(e){const t=e.openElements.tmplCount>0,{formElement:n}=e;t||(e.formElement=null),(n||t)&&e.openElements.hasInScope(l.FORM)&&(e.openElements.generateImpliedEndTags(),t?e.openElements.popUntilTagNamePopped(l.FORM):n&&e.openElements.remove(n))}function Kp(e){e.openElements.hasInButtonScope(l.P)||e._insertFakeElement(N.P,l.P),e._closePElement()}function Xp(e){e.openElements.hasInListItemScope(l.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(l.LI),e.openElements.popUntilTagNamePopped(l.LI))}function Zp(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function Jp(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function e1(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function t1(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(N.BR,l.BR),e.openElements.pop(),e.framesetOk=!1}function vu(e,t){const n=t.tagName,r=t.tagID;for(let i=e.openElements.stackTop;i>0;i--){const a=e.openElements.items[i],s=e.openElements.tagIDs[i];if(r===s&&(r!==l.UNKNOWN||e.treeAdapter.getTagName(a)===n)){e.openElements.generateImpliedEndTagsWithExclusion(r),e.openElements.stackTop>=i&&e.openElements.shortenToLength(i);break}if(e._isSpecialElement(a,s))break}}function zr(e,t){switch(t.tagID){case l.A:case l.B:case l.I:case l.S:case l.U:case l.EM:case l.TT:case l.BIG:case l.CODE:case l.FONT:case l.NOBR:case l.SMALL:case l.STRIKE:case l.STRONG:{la(e,t);break}case l.P:{Kp(e);break}case l.DL:case l.UL:case l.OL:case l.DIR:case l.DIV:case l.NAV:case l.PRE:case l.MAIN:case l.MENU:case l.ASIDE:case l.BUTTON:case l.CENTER:case l.FIGURE:case l.FOOTER:case l.HEADER:case l.HGROUP:case l.DIALOG:case l.ADDRESS:case l.ARTICLE:case l.DETAILS:case l.SEARCH:case l.SECTION:case l.SUMMARY:case l.LISTING:case l.FIELDSET:case l.BLOCKQUOTE:case l.FIGCAPTION:{Gp(e,t);break}case l.LI:{Xp(e);break}case l.DD:case l.DT:{Zp(e,t);break}case l.H1:case l.H2:case l.H3:case l.H4:case l.H5:case l.H6:{Jp(e);break}case l.BR:{t1(e);break}case l.BODY:{qp(e,t);break}case l.HTML:{Wp(e,t);break}case l.FORM:{Qp(e);break}case l.APPLET:case l.OBJECT:case l.MARQUEE:{e1(e,t);break}case l.TEMPLATE:{Gt(e,t);break}default:vu(e,t)}}function Lu(e,t){e.tmplInsertionModeStack.length>0?Fu(e,t):da(e,t)}function n1(e,t){var n;t.tagID===l.SCRIPT&&((n=e.scriptHandler)===null||n===void 0||n.call(e,e.openElements.current)),e.openElements.pop(),e.insertionMode=e.originalInsertionMode}function r1(e,t){e._err(t,v.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function fa(e,t){if(e.openElements.currentTagId!==void 0&&ku.has(e.openElements.currentTagId))switch(e.pendingCharacterTokens.length=0,e.hasNonWhitespacePendingCharacterToken=!1,e.originalInsertionMode=e.insertionMode,e.insertionMode=T.IN_TABLE_TEXT,t.type){case re.CHARACTER:{Ou(e,t);break}case re.WHITESPACE_CHARACTER:{Ru(e,t);break}}else Qn(e,t)}function i1(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,O.HTML),e.insertionMode=T.IN_CAPTION}function a1(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,O.HTML),e.insertionMode=T.IN_COLUMN_GROUP}function s1(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(N.COLGROUP,l.COLGROUP),e.insertionMode=T.IN_COLUMN_GROUP,ha(e,t)}function o1(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,O.HTML),e.insertionMode=T.IN_TABLE_BODY}function u1(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(N.TBODY,l.TBODY),e.insertionMode=T.IN_TABLE_BODY,Yr(e,t)}function l1(e,t){e.openElements.hasInTableScope(l.TABLE)&&(e.openElements.popUntilTagNamePopped(l.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function c1(e,t){Su(t)?e._appendElement(t,O.HTML):Qn(e,t),t.ackSelfClosing=!0}function d1(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,O.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function bn(e,t){switch(t.tagID){case l.TD:case l.TH:case l.TR:{u1(e,t);break}case l.STYLE:case l.SCRIPT:case l.TEMPLATE:{ot(e,t);break}case l.COL:{s1(e,t);break}case l.FORM:{d1(e,t);break}case l.TABLE:{l1(e,t);break}case l.TBODY:case l.TFOOT:case l.THEAD:{o1(e,t);break}case l.INPUT:{c1(e,t);break}case l.CAPTION:{i1(e,t);break}case l.COLGROUP:{a1(e,t);break}default:Qn(e,t)}}function Gn(e,t){switch(t.tagID){case l.TABLE:{e.openElements.hasInTableScope(l.TABLE)&&(e.openElements.popUntilTagNamePopped(l.TABLE),e._resetInsertionMode());break}case l.TEMPLATE:{Gt(e,t);break}case l.BODY:case l.CAPTION:case l.COL:case l.COLGROUP:case l.HTML:case l.TBODY:case l.TD:case l.TFOOT:case l.TH:case l.THEAD:case l.TR:break;default:Qn(e,t)}}function Qn(e,t){const n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,Ur(e,t),e.fosterParentingEnabled=n}function Ru(e,t){e.pendingCharacterTokens.push(t)}function Ou(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function Kn(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n<e.pendingCharacterTokens.length;n++)Qn(e,e.pendingCharacterTokens[n]);else for(;n<e.pendingCharacterTokens.length;n++)e._insertCharacters(e.pendingCharacterTokens[n]);e.insertionMode=e.originalInsertionMode,e._processToken(t)}const Du=new Set([l.CAPTION,l.COL,l.COLGROUP,l.TBODY,l.TD,l.TFOOT,l.TH,l.THEAD,l.TR]);function f1(e,t){const n=t.tagID;Du.has(n)?e.openElements.hasInTableScope(l.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(l.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=T.IN_TABLE,bn(e,t)):Me(e,t)}function h1(e,t){const n=t.tagID;switch(n){case l.CAPTION:case l.TABLE:{e.openElements.hasInTableScope(l.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(l.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=T.IN_TABLE,n===l.TABLE&&Gn(e,t));break}case l.BODY:case l.COL:case l.COLGROUP:case l.HTML:case l.TBODY:case l.TD:case l.TFOOT:case l.TH:case l.THEAD:case l.TR:break;default:zr(e,t)}}function ha(e,t){switch(t.tagID){case l.HTML:{Me(e,t);break}case l.COL:{e._appendElement(t,O.HTML),t.ackSelfClosing=!0;break}case l.TEMPLATE:{ot(e,t);break}default:$r(e,t)}}function p1(e,t){switch(t.tagID){case l.COLGROUP:{e.openElements.currentTagId===l.COLGROUP&&(e.openElements.pop(),e.insertionMode=T.IN_TABLE);break}case l.TEMPLATE:{Gt(e,t);break}case l.COL:break;default:$r(e,t)}}function $r(e,t){e.openElements.currentTagId===l.COLGROUP&&(e.openElements.pop(),e.insertionMode=T.IN_TABLE,e._processToken(t))}function Yr(e,t){switch(t.tagID){case l.TR:{e.openElements.clearBackToTableBodyContext(),e._insertElement(t,O.HTML),e.insertionMode=T.IN_ROW;break}case l.TH:case l.TD:{e.openElements.clearBackToTableBodyContext(),e._insertFakeElement(N.TR,l.TR),e.insertionMode=T.IN_ROW,jr(e,t);break}case l.CAPTION:case l.COL:case l.COLGROUP:case l.TBODY:case l.TFOOT:case l.THEAD:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE,bn(e,t));break}default:bn(e,t)}}function pa(e,t){const n=t.tagID;switch(t.tagID){case l.TBODY:case l.TFOOT:case l.THEAD:{e.openElements.hasInTableScope(n)&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE);break}case l.TABLE:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE,Gn(e,t));break}case l.BODY:case l.CAPTION:case l.COL:case l.COLGROUP:case l.HTML:case l.TD:case l.TH:case l.TR:break;default:Gn(e,t)}}function jr(e,t){switch(t.tagID){case l.TH:case l.TD:{e.openElements.clearBackToTableRowContext(),e._insertElement(t,O.HTML),e.insertionMode=T.IN_CELL,e.activeFormattingElements.insertMarker();break}case l.CAPTION:case l.COL:case l.COLGROUP:case l.TBODY:case l.TFOOT:case l.THEAD:case l.TR:{e.openElements.hasInTableScope(l.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE_BODY,Yr(e,t));break}default:bn(e,t)}}function Pu(e,t){switch(t.tagID){case l.TR:{e.openElements.hasInTableScope(l.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE_BODY);break}case l.TABLE:{e.openElements.hasInTableScope(l.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE_BODY,pa(e,t));break}case l.TBODY:case l.TFOOT:case l.THEAD:{(e.openElements.hasInTableScope(t.tagID)||e.openElements.hasInTableScope(l.TR))&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=T.IN_TABLE_BODY,pa(e,t));break}case l.BODY:case l.CAPTION:case l.COL:case l.COLGROUP:case l.HTML:case l.TD:case l.TH:break;default:Gn(e,t)}}function m1(e,t){const n=t.tagID;Du.has(n)?(e.openElements.hasInTableScope(l.TD)||e.openElements.hasInTableScope(l.TH))&&(e._closeTableCell(),jr(e,t)):Me(e,t)}function g1(e,t){const n=t.tagID;switch(n){case l.TD:case l.TH:{e.openElements.hasInTableScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=T.IN_ROW);break}case l.TABLE:case l.TBODY:case l.TFOOT:case l.THEAD:case l.TR:{e.openElements.hasInTableScope(n)&&(e._closeTableCell(),Pu(e,t));break}case l.BODY:case l.CAPTION:case l.COL:case l.COLGROUP:case l.HTML:break;default:zr(e,t)}}function Mu(e,t){switch(t.tagID){case l.HTML:{Me(e,t);break}case l.OPTION:{e.openElements.currentTagId===l.OPTION&&e.openElements.pop(),e._insertElement(t,O.HTML);break}case l.OPTGROUP:{e.openElements.currentTagId===l.OPTION&&e.openElements.pop(),e.openElements.currentTagId===l.OPTGROUP&&e.openElements.pop(),e._insertElement(t,O.HTML);break}case l.HR:{e.openElements.currentTagId===l.OPTION&&e.openElements.pop(),e.openElements.currentTagId===l.OPTGROUP&&e.openElements.pop(),e._appendElement(t,O.HTML),t.ackSelfClosing=!0;break}case l.INPUT:case l.KEYGEN:case l.TEXTAREA:case l.SELECT:{e.openElements.hasInSelectScope(l.SELECT)&&(e.openElements.popUntilTagNamePopped(l.SELECT),e._resetInsertionMode(),t.tagID!==l.SELECT&&e._processStartTag(t));break}case l.SCRIPT:case l.TEMPLATE:{ot(e,t);break}}}function Bu(e,t){switch(t.tagID){case l.OPTGROUP:{e.openElements.stackTop>0&&e.openElements.currentTagId===l.OPTION&&e.openElements.tagIDs[e.openElements.stackTop-1]===l.OPTGROUP&&e.openElements.pop(),e.openElements.currentTagId===l.OPTGROUP&&e.openElements.pop();break}case l.OPTION:{e.openElements.currentTagId===l.OPTION&&e.openElements.pop();break}case l.SELECT:{e.openElements.hasInSelectScope(l.SELECT)&&(e.openElements.popUntilTagNamePopped(l.SELECT),e._resetInsertionMode());break}case l.TEMPLATE:{Gt(e,t);break}}}function b1(e,t){const n=t.tagID;n===l.CAPTION||n===l.TABLE||n===l.TBODY||n===l.TFOOT||n===l.THEAD||n===l.TR||n===l.TD||n===l.TH?(e.openElements.popUntilTagNamePopped(l.SELECT),e._resetInsertionMode(),e._processStartTag(t)):Mu(e,t)}function E1(e,t){const n=t.tagID;n===l.CAPTION||n===l.TABLE||n===l.TBODY||n===l.TFOOT||n===l.THEAD||n===l.TR||n===l.TD||n===l.TH?e.openElements.hasInTableScope(n)&&(e.openElements.popUntilTagNamePopped(l.SELECT),e._resetInsertionMode(),e.onEndTag(t)):Bu(e,t)}function T1(e,t){switch(t.tagID){case l.BASE:case l.BASEFONT:case l.BGSOUND:case l.LINK:case l.META:case l.NOFRAMES:case l.SCRIPT:case l.STYLE:case l.TEMPLATE:case l.TITLE:{ot(e,t);break}case l.CAPTION:case l.COLGROUP:case l.TBODY:case l.TFOOT:case l.THEAD:{e.tmplInsertionModeStack[0]=T.IN_TABLE,e.insertionMode=T.IN_TABLE,bn(e,t);break}case l.COL:{e.tmplInsertionModeStack[0]=T.IN_COLUMN_GROUP,e.insertionMode=T.IN_COLUMN_GROUP,ha(e,t);break}case l.TR:{e.tmplInsertionModeStack[0]=T.IN_TABLE_BODY,e.insertionMode=T.IN_TABLE_BODY,Yr(e,t);break}case l.TD:case l.TH:{e.tmplInsertionModeStack[0]=T.IN_ROW,e.insertionMode=T.IN_ROW,jr(e,t);break}default:e.tmplInsertionModeStack[0]=T.IN_BODY,e.insertionMode=T.IN_BODY,Me(e,t)}}function _1(e,t){t.tagID===l.TEMPLATE&&Gt(e,t)}function Fu(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(l.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):da(e,t)}function k1(e,t){t.tagID===l.HTML?Me(e,t):Vr(e,t)}function Hu(e,t){var n;if(t.tagID===l.HTML){if(e.fragmentContext||(e.insertionMode=T.AFTER_AFTER_BODY),e.options.sourceCodeLocationInfo&&e.openElements.tagIDs[0]===l.HTML){e._setEndLocation(e.openElements.items[0],t);const r=e.openElements.items[1];r&&!(!((n=e.treeAdapter.getNodeSourceCodeLocation(r))===null||n===void 0)&&n.endTag)&&e._setEndLocation(r,t)}}else Vr(e,t)}function Vr(e,t){e.insertionMode=T.IN_BODY,Ur(e,t)}function x1(e,t){switch(t.tagID){case l.HTML:{Me(e,t);break}case l.FRAMESET:{e._insertElement(t,O.HTML);break}case l.FRAME:{e._appendElement(t,O.HTML),t.ackSelfClosing=!0;break}case l.NOFRAMES:{ot(e,t);break}}}function y1(e,t){t.tagID===l.FRAMESET&&!e.openElements.isRootHtmlElementCurrent()&&(e.openElements.pop(),!e.fragmentContext&&e.openElements.currentTagId!==l.FRAMESET&&(e.insertionMode=T.AFTER_FRAMESET))}function w1(e,t){switch(t.tagID){case l.HTML:{Me(e,t);break}case l.NOFRAMES:{ot(e,t);break}}}function A1(e,t){t.tagID===l.HTML&&(e.insertionMode=T.AFTER_AFTER_FRAMESET)}function C1(e,t){t.tagID===l.HTML?Me(e,t):qr(e,t)}function qr(e,t){e.insertionMode=T.IN_BODY,Ur(e,t)}function S1(e,t){switch(t.tagID){case l.HTML:{Me(e,t);break}case l.NOFRAMES:{ot(e,t);break}}}function I1(e,t){t.chars=_e,e._insertCharacters(t)}function N1(e,t){e._insertCharacters(t),e.framesetOk=!1}function Uu(e){for(;e.treeAdapter.getNamespaceURI(e.openElements.current)!==O.HTML&&e.openElements.currentTagId!==void 0&&!e._isIntegrationPoint(e.openElements.currentTagId,e.openElements.current);)e.openElements.pop()}function v1(e,t){if(Vh(t))Uu(e),e._startTagOutsideForeignContent(t);else{const n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===O.MATHML?Tu(t):r===O.SVG&&(qh(t),_u(t)),ua(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function L1(e,t){if(t.tagID===l.P||t.tagID===l.BR){Uu(e),e._endTagOutsideForeignContent(t);return}for(let n=e.openElements.stackTop;n>0;n--){const r=e.openElements.items[n];if(e.treeAdapter.getNamespaceURI(r)===O.HTML){e._endTagOutsideForeignContent(t);break}const i=e.treeAdapter.getTagName(r);if(i.toLowerCase()===t.tagName){t.tagName=i,e.openElements.shortenToLength(n);break}}}const Wr=zu("end"),pt=zu("start");function zu(e){return t;function t(n){const r=n&&n.position&&n.position[e]||{};if(typeof r.line=="number"&&r.line>0&&typeof r.column=="number"&&r.column>0)return{line:r.line,column:r.column,offset:typeof r.offset=="number"&&r.offset>-1?r.offset:void 0}}}function $u(e){const t=pt(e),n=Wr(e);if(t&&n)return{start:t,end:n}}const R1=/<(\/?)(iframe|noembed|noframes|plaintext|script|style|textarea|title|xmp)(?=[\t\n\f\r />])/gi,O1=new Set(["mdxFlowExpression","mdxJsxFlowElement","mdxJsxTextElement","mdxTextExpression","mdxjsEsm"]),Yu={sourceCodeLocationInfo:!0,scriptingEnabled:!1};function ju(e,t){const n=Y1(e),r=eu("type",{handlers:{root:D1,element:P1,text:M1,comment:qu,doctype:B1,raw:H1},unknown:U1}),i={parser:n?new yu(Yu):yu.getFragmentParser(void 0,Yu),handle(o){r(o,i)},stitches:!1,options:t||{}};r(e,i),En(i,pt());const a=n?i.parser.document:i.parser.getFragment(),s=jf(a,{file:i.options.file});return i.stitches&&cn(s,"comment",function(o,u,c){const f=o;if(f.value.stitch&&c&&u!==void 0){const d=c.children;return d[u]=f.value.stitch,u}}),s.type==="root"&&s.children.length===1&&s.children[0].type===e.type?s.children[0]:s}function Vu(e,t){let n=-1;if(e)for(;++n<e.length;)t.handle(e[n])}function D1(e,t){Vu(e.children,t)}function P1(e,t){z1(e,t),Vu(e.children,t),$1(e,t)}function M1(e,t){t.parser.tokenizer.state>4&&(t.parser.tokenizer.state=0);const n={type:re.CHARACTER,chars:e.value,location:Xn(e)};En(t,pt(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function B1(e,t){const n={type:re.DOCTYPE,name:"html",forceQuirks:!1,publicId:"",systemId:"",location:Xn(e)};En(t,pt(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function F1(e,t){t.stitches=!0;const n=j1(e);if("children"in e&&"children"in n){const r=ju({type:"root",children:e.children},t.options);n.children=r.children}qu({type:"comment",value:{stitch:n}},t)}function qu(e,t){const n=e.value,r={type:re.COMMENT,data:n,location:Xn(e)};En(t,pt(e)),t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken)}function H1(e,t){if(t.parser.tokenizer.preprocessor.html="",t.parser.tokenizer.preprocessor.pos=-1,t.parser.tokenizer.preprocessor.lastGapPos=-2,t.parser.tokenizer.preprocessor.gapStack=[],t.parser.tokenizer.preprocessor.skipNextNewLine=!1,t.parser.tokenizer.preprocessor.lastChunkWritten=!1,t.parser.tokenizer.preprocessor.endOfChunkHit=!1,t.parser.tokenizer.preprocessor.isEol=!1,Wu(t,pt(e)),t.parser.tokenizer.write(t.options.tagfilter?e.value.replace(R1,"<$1$2"):e.value,!1),t.parser.tokenizer._runParsingLoop(),t.parser.tokenizer.state===72||t.parser.tokenizer.state===78){t.parser.tokenizer.preprocessor.lastChunkWritten=!0;const n=t.parser.tokenizer._consume();t.parser.tokenizer._callState(n)}}function U1(e,t){const n=e;if(t.options.passThrough&&t.options.passThrough.includes(n.type))F1(n,t);else{let r="";throw O1.has(n.type)&&(r=". It looks like you are using MDX nodes with `hast-util-raw` (or `rehype-raw`). If you use this because you are using remark or rehype plugins that inject `'html'` nodes, then please raise an issue with that plugin, as its a bad and slow idea. If you use this because you are using markdown syntax, then you have to configure this utility (or plugin) to pass through these nodes (see `passThrough` in docs), but you can also migrate to use the MDX syntax"),new Error("Cannot compile `"+n.type+"` node"+r)}}function En(e,t){Wu(e,t);const n=e.parser.tokenizer.currentCharacterToken;n&&n.location&&(n.location.endLine=e.parser.tokenizer.preprocessor.line,n.location.endCol=e.parser.tokenizer.preprocessor.col+1,n.location.endOffset=e.parser.tokenizer.preprocessor.offset+1,e.parser.currentToken=n,e.parser._processToken(e.parser.currentToken)),e.parser.tokenizer.paused=!1,e.parser.tokenizer.inLoop=!1,e.parser.tokenizer.active=!1,e.parser.tokenizer.returnState=Ae.DATA,e.parser.tokenizer.charRefCode=-1,e.parser.tokenizer.consumedAfterSnapshot=-1,e.parser.tokenizer.currentLocation=null,e.parser.tokenizer.currentCharacterToken=null,e.parser.tokenizer.currentToken=null,e.parser.tokenizer.currentAttr={name:"",value:""}}function Wu(e,t){if(t&&t.offset!==void 0){const n={startLine:t.line,startCol:t.column,startOffset:t.offset,endLine:-1,endCol:-1,endOffset:-1};e.parser.tokenizer.preprocessor.lineStartPos=-t.column+1,e.parser.tokenizer.preprocessor.droppedBufferSize=t.offset,e.parser.tokenizer.preprocessor.line=t.line,e.parser.tokenizer.currentLocation=n}}function z1(e,t){const n=e.tagName.toLowerCase();if(t.parser.tokenizer.state===Ae.PLAINTEXT)return;En(t,pt(e));const r=t.parser.openElements.current;let i="namespaceURI"in r?r.namespaceURI:qt.html;i===qt.html&&n==="svg"&&(i=qt.svg);const a=Qf({...e,children:[]},{space:i===qt.svg?"svg":"html"}),s={type:re.START_TAG,tagName:n,tagID:gn(n),selfClosing:!1,ackSelfClosing:!1,attrs:"attrs"in a?a.attrs:[],location:Xn(e)};t.parser.currentToken=s,t.parser._processToken(t.parser.currentToken),t.parser.tokenizer.lastStartTagName=n}function $1(e,t){const n=e.tagName.toLowerCase();if(!t.parser.tokenizer.inForeignNode&&rh.includes(n)||t.parser.tokenizer.state===Ae.PLAINTEXT)return;En(t,Wr(e));const r={type:re.END_TAG,tagName:n,tagID:gn(n),selfClosing:!1,ackSelfClosing:!1,attrs:[],location:Xn(e)};t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken),n===t.parser.tokenizer.lastStartTagName&&(t.parser.tokenizer.state===Ae.RCDATA||t.parser.tokenizer.state===Ae.RAWTEXT||t.parser.tokenizer.state===Ae.SCRIPT_DATA)&&(t.parser.tokenizer.state=Ae.DATA)}function Y1(e){const t=e.type==="root"?e.children[0]:e;return!!(t&&(t.type==="doctype"||t.type==="element"&&t.tagName.toLowerCase()==="html"))}function Xn(e){const t=pt(e)||{line:void 0,column:void 0,offset:void 0},n=Wr(e)||{line:void 0,column:void 0,offset:void 0};return{startLine:t.line,startCol:t.column,startOffset:t.offset,endLine:n.line,endCol:n.column,endOffset:n.offset}}function j1(e){return"children"in e?jt({...e,children:[]}):jt(e)}function V1(e){return function(t,n){return ju(t,{...e,file:n})}}const Qt=["ariaDescribedBy","ariaLabel","ariaLabelledBy"],Gu={ancestors:{tbody:["table"],td:["table"],th:["table"],thead:["table"],tfoot:["table"],tr:["table"]},attributes:{a:[...Qt,"dataFootnoteBackref","dataFootnoteRef",["className","data-footnote-backref"],"href"],blockquote:["cite"],code:[["className",/^language-./]],del:["cite"],div:["itemScope","itemType"],dl:[...Qt],h2:[["className","sr-only"]],img:[...Qt,"longDesc","src"],input:[["disabled",!0],["type","checkbox"]],ins:["cite"],li:[["className","task-list-item"]],ol:[...Qt,["className","contains-task-list"]],q:["cite"],section:["dataFootnotes",["className","footnotes"]],source:["srcSet"],summary:[...Qt],table:[...Qt],ul:[...Qt,["className","contains-task-list"]],"*":["abbr","accept","acceptCharset","accessKey","action","align","alt","axis","border","cellPadding","cellSpacing","char","charOff","charSet","checked","clear","colSpan","color","cols","compact","coords","dateTime","dir","encType","frame","hSpace","headers","height","hrefLang","htmlFor","id","isMap","itemProp","label","lang","maxLength","media","method","multiple","name","noHref","noShade","noWrap","open","prompt","readOnly","rev","rowSpan","rows","rules","scope","selected","shape","size","span","start","summary","tabIndex","title","useMap","vAlign","value","width"]},clobber:["ariaDescribedBy","ariaLabelledBy","id","name"],clobberPrefix:"user-content-",protocols:{cite:["http","https"],href:["http","https","irc","ircs","mailto","xmpp"],longDesc:["http","https"],src:["http","https"]},required:{input:{disabled:!0,type:"checkbox"}},strip:["script"],tagNames:["a","b","blockquote","br","code","dd","del","details","div","dl","dt","em","h1","h2","h3","h4","h5","h6","hr","i","img","input","ins","kbd","li","ol","p","picture","pre","q","rp","rt","ruby","s","samp","section","source","span","strike","strong","sub","summary","sup","table","tbody","td","tfoot","th","thead","tr","tt","ul","var"]},Rt={}.hasOwnProperty;function q1(e,t){let n={type:"root",children:[]};const r={schema:t?{...Gu,...t}:Gu,stack:[]},i=Qu(r,e);return i&&(Array.isArray(i)?i.length===1?n=i[0]:n.children=i:n=i),n}function Qu(e,t){if(t&&typeof t=="object"){const n=t;switch(typeof n.type=="string"?n.type:""){case"comment":return W1(e,n);case"doctype":return G1(e,n);case"element":return Q1(e,n);case"root":return K1(e,n);case"text":return X1(e,n)}}}function W1(e,t){if(e.schema.allowComments){const n=typeof t.value=="string"?t.value:"",r=n.indexOf("-->"),a={type:"comment",value:r<0?n:n.slice(0,r)};return Zn(a,t),a}}function G1(e,t){if(e.schema.allowDoctypes){const n={type:"doctype"};return Zn(n,t),n}}function Q1(e,t){const n=typeof t.tagName=="string"?t.tagName:"";e.stack.push(n);const r=Ku(e,t.children),i=Z1(e,t.properties);e.stack.pop();let a=!1;if(n&&n!=="*"&&(!e.schema.tagNames||e.schema.tagNames.includes(n))&&(a=!0,e.schema.ancestors&&Rt.call(e.schema.ancestors,n))){const o=e.schema.ancestors[n];let u=-1;for(a=!1;++u<o.length;)e.stack.includes(o[u])&&(a=!0)}if(!a)return e.schema.strip&&!e.schema.strip.includes(n)?r:void 0;const s={type:"element",tagName:n,properties:i,children:r};return Zn(s,t),s}function K1(e,t){const r={type:"root",children:Ku(e,t.children)};return Zn(r,t),r}function X1(e,t){const r={type:"text",value:typeof t.value=="string"?t.value:""};return Zn(r,t),r}function Ku(e,t){const n=[];if(Array.isArray(t)){const r=t;let i=-1;for(;++i<r.length;){const a=Qu(e,r[i]);a&&(Array.isArray(a)?n.push(...a):n.push(a))}}return n}function Z1(e,t){const n=e.stack[e.stack.length-1],r=e.schema.attributes,i=e.schema.required,a=r&&Rt.call(r,n)?r[n]:void 0,s=r&&Rt.call(r,"*")?r["*"]:void 0,o=t&&typeof t=="object"?t:{},u={};let c;for(c in o)if(Rt.call(o,c)){const f=o[c];let d=Xu(e,Ju(a,c),c,f);d==null&&(d=Xu(e,Ju(s,c),c,f)),d!=null&&(u[c]=d)}if(i&&Rt.call(i,n)){const f=i[n];for(c in f)Rt.call(f,c)&&!Rt.call(u,c)&&(u[c]=f[c])}return u}function Xu(e,t,n,r){return t?Array.isArray(r)?J1(e,t,n,r):Zu(e,t,n,r):void 0}function J1(e,t,n,r){let i=-1;const a=[];for(;++i<r.length;){const s=Zu(e,t,n,r[i]);(typeof s=="number"||typeof s=="string")&&a.push(s)}return a}function Zu(e,t,n,r){if(!(typeof r!="boolean"&&typeof r!="number"&&typeof r!="string")&&em(e,n,r)){if(typeof t=="object"&&t.length>1){let i=!1,a=0;for(;++a<t.length;){const s=t[a];if(s&&typeof s=="object"&&"flags"in s){if(s.test(String(r))){i=!0;break}}else if(s===r){i=!0;break}}if(!i)return}return e.schema.clobber&&e.schema.clobberPrefix&&e.schema.clobber.includes(n)?e.schema.clobberPrefix+r:r}}function em(e,t,n){const r=e.schema.protocols&&Rt.call(e.schema.protocols,t)?e.schema.protocols[t]:void 0;if(!r||r.length===0)return!0;const i=String(n),a=i.indexOf(":"),s=i.indexOf("?"),o=i.indexOf("#"),u=i.indexOf("/");if(a<0||u>-1&&a>u||s>-1&&a>s||o>-1&&a>o)return!0;let c=-1;for(;++c<r.length;){const f=r[c];if(a===f.length&&i.slice(0,f.length)===f)return!0}return!1}function Zn(e,t){const n=$u(t);t.data&&(e.data=jt(t.data)),n&&(e.position=n)}function Ju(e,t){let n,r=-1;if(e)for(;++r<e.length;){const i=e[r],a=typeof i=="string"?i:i[0];if(a===t)return i;a==="data*"&&(n=i)}if(t.length>4&&t.slice(0,4).toLowerCase()==="data")return n}function tm(e){return function(t){return q1(t,e)}}function el(e,t){const n=String(e);if(typeof t!="string")throw new TypeError("Expected character");let r=0,i=n.indexOf(t);for(;i!==-1;)r++,i=n.indexOf(t,i+t.length);return r}const ze=Ot(/[A-Za-z]/),Be=Ot(/[\dA-Za-z]/),nm=Ot(/[#-'*+\--9=?A-Z^-~]/);function Gr(e){return e!==null&&(e<32||e===127)}const ma=Ot(/\d/),rm=Ot(/[\dA-Fa-f]/),im=Ot(/[!-/:-@[-`{-~]/);function G(e){return e!==null&&e<-2}function pe(e){return e!==null&&(e<0||e===32)}function ie(e){return e===-2||e===-1||e===32}const Qr=Ot(/\p{P}|\p{S}/u),Kt=Ot(/\s/);function Ot(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function am(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function sm(e,t,n){const i=vr((n||{}).ignore||[]),a=om(t);let s=-1;for(;++s<a.length;)wo(e,"text",o);function o(c,f){let d=-1,h;for(;++d<f.length;){const p=f[d],m=h?h.children:void 0;if(i(p,m?m.indexOf(p):void 0,h))return;h=p}if(h)return u(c,f)}function u(c,f){const d=f[f.length-1],h=a[s][0],p=a[s][1];let m=0;const A=d.children.indexOf(c);let y=!1,I=[];h.lastIndex=0;let S=h.exec(c.value);for(;S;){const D=S.index,P={index:S.index,input:S.input,stack:[...f,c]};let w=p(...S,P);if(typeof w=="string"&&(w=w.length>0?{type:"text",value:w}:void 0),w===!1?h.lastIndex=D+1:(m!==D&&I.push({type:"text",value:c.value.slice(m,D)}),Array.isArray(w)?I.push(...w):w&&I.push(w),m=D+S[0].length,y=!0),!h.global)break;S=h.exec(c.value)}return y?(m<c.value.length&&I.push({type:"text",value:c.value.slice(m)}),d.children.splice(A,1,...I)):I=[c],A+I.length}}function om(e){const t=[];if(!Array.isArray(e))throw new TypeError("Expected find and replace tuple or list of tuples");const n=!e[0]||Array.isArray(e[0])?e:[e];let r=-1;for(;++r<n.length;){const i=n[r];t.push([um(i[0]),lm(i[1])])}return t}function um(e){return typeof e=="string"?new RegExp(am(e),"g"):e}function lm(e){return typeof e=="function"?e:function(){return e}}const ga="phrasing",ba=["autolink","link","image","label"];function cm(){return{transforms:[bm],enter:{literalAutolink:fm,literalAutolinkEmail:Ea,literalAutolinkHttp:Ea,literalAutolinkWww:Ea},exit:{literalAutolink:gm,literalAutolinkEmail:mm,literalAutolinkHttp:hm,literalAutolinkWww:pm}}}function dm(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:ga,notInConstruct:ba},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:ga,notInConstruct:ba},{character:":",before:"[ps]",after:"\\/",inConstruct:ga,notInConstruct:ba}]}}function fm(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function Ea(e){this.config.enter.autolinkProtocol.call(this,e)}function hm(e){this.config.exit.autolinkProtocol.call(this,e)}function pm(e){this.config.exit.data.call(this,e);const t=this.stack[this.stack.length-1];t.url="http://"+this.sliceSerialize(e)}function mm(e){this.config.exit.autolinkEmail.call(this,e)}function gm(e){this.exit(e)}function bm(e){sm(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,Em],[/(?<=^|\s|\p{P}|\p{S})([-.\w+]+)@([-\w]+(?:\.[-\w]+)+)/gu,Tm]],{ignore:["link","linkReference"]})}function Em(e,t,n,r,i){let a="";if(!tl(i)||(/^w/i.test(t)&&(n=t+n,t="",a="http://"),!_m(n)))return!1;const s=km(n+r);if(!s[0])return!1;const o={type:"link",title:null,url:a+t+s[0],children:[{type:"text",value:t+s[0]}]};return s[1]?[o,{type:"text",value:s[1]}]:o}function Tm(e,t,n,r){return!tl(r,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function _m(e){const t=e.split(".");return!(t.length<2||t[t.length-1]&&(/_/.test(t[t.length-1])||!/[a-zA-Z\d]/.test(t[t.length-1]))||t[t.length-2]&&(/_/.test(t[t.length-2])||!/[a-zA-Z\d]/.test(t[t.length-2])))}function km(e){const t=/[!"&'),.:;<>?\]}]+$/.exec(e);if(!t)return[e,void 0];e=e.slice(0,t.index);let n=t[0],r=n.indexOf(")");const i=el(e,"(");let a=el(e,")");for(;r!==-1&&i>a;)e+=n.slice(0,r+1),n=n.slice(r+1),r=n.indexOf(")"),a++;return[e,n]}function tl(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||Kt(n)||Qr(n))&&(!t||n!==47)}function ut(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}nl.peek=vm;function xm(){this.buffer()}function ym(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function wm(){this.buffer()}function Am(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function Cm(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.identifier=ut(this.sliceSerialize(e)).toLowerCase(),n.label=t}function Sm(e){this.exit(e)}function Im(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.identifier=ut(this.sliceSerialize(e)).toLowerCase(),n.label=t}function Nm(e){this.exit(e)}function vm(){return"["}function nl(e,t,n,r){const i=n.createTracker(r);let a=i.move("[^");const s=n.enter("footnoteReference"),o=n.enter("reference");return a+=i.move(n.safe(n.associationId(e),{after:"]",before:a})),o(),s(),a+=i.move("]"),a}function Lm(){return{enter:{gfmFootnoteCallString:xm,gfmFootnoteCall:ym,gfmFootnoteDefinitionLabelString:wm,gfmFootnoteDefinition:Am},exit:{gfmFootnoteCallString:Cm,gfmFootnoteCall:Sm,gfmFootnoteDefinitionLabelString:Im,gfmFootnoteDefinition:Nm}}}function Rm(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:nl},unsafe:[{character:"[",inConstruct:["label","phrasing","reference"]}]};function n(r,i,a,s){const o=a.createTracker(s);let u=o.move("[^");const c=a.enter("footnoteDefinition"),f=a.enter("label");return u+=o.move(a.safe(a.associationId(r),{before:u,after:"]"})),f(),u+=o.move("]:"),r.children&&r.children.length>0&&(o.shift(4),u+=o.move((t?`
|
|
3
|
-
`:" ")+a.indentLines(a.containerFlow(r,o.current()),t?
|
|
4
|
-
`)}function
|
|
5
|
-
`&&
|
|
6
|
-
`}function
|
|
1
|
+
var C6=Object.defineProperty;var S6=(Vt,it,qt)=>it in Vt?C6(Vt,it,{enumerable:!0,configurable:!0,writable:!0,value:qt}):Vt[it]=qt;var pe=(Vt,it,qt)=>(S6(Vt,typeof it!="symbol"?it+"":it,qt),qt);(function(){var Ii;"use strict";var Vt=e=>e,it="isdk_session",qt=e=>{let t=new Date;return t.setTime(t.getTime()+6048e5),`${it}=${e};expires=${t.toUTCString()};path=/`},W0=(e,t)=>{let n=e.get("session_id");if(t||n)return n;let r=sessionStorage.getItem(`${it}-session_id`);return typeof r=="string"?r:null},G0=new RegExp(`${it}=([^;]+)`),Q0=e=>{let t=e?e.url:location.href,{searchParams:n}=new URL(t),r=n.get("anonymous_id"),i=W0(n,typeof window>"u");if(r)return{anonymous_id:r,session_id:i};let a=e?e.headers.get("cookie"):document.cookie;return a?{anonymous_id:G0.exec(a)?.[1]??null,session_id:i}:{anonymous_id:r,session_id:i}},Ps=()=>{if(typeof window>"u")throw new Error("getOrCreateAnonymousId() can only be called in browser environment");let e=Q0().anonymous_id;if(e)return e;let t=crypto.randomUUID();return document.cookie=qt(t),t},Dn,q,Ms,Bs,Wt,Fs,Hs,Ri,Us,hn={},zs=[],K0=/acit|ex(?:s|g|n|p|$)|rph|grid|ows|mnc|ntw|ine[ch]|zoo|^ord|itera/i,Cr=Array.isArray;function kt(e,t){for(var n in t)e[n]=t[n];return e}function $s(e){var t=e.parentNode;t&&t.removeChild(e)}function ft(e,t,n){var r,i,a,s={};for(a in t)a=="key"?r=t[a]:a=="ref"?i=t[a]:s[a]=t[a];if(arguments.length>2&&(s.children=arguments.length>3?Dn.call(arguments,2):n),typeof e=="function"&&e.defaultProps!=null)for(a in e.defaultProps)s[a]===void 0&&(s[a]=e.defaultProps[a]);return Pn(e,s,r,i,null)}function Pn(e,t,n,r,i){var a={type:e,props:t,key:n,ref:r,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,__h:null,constructor:void 0,__v:i??++Ms};return i==null&&q.vnode!=null&&q.vnode(a),a}function $e(e){return e.children}function ht(e,t){this.props=e,this.context=t}function Sr(e,t){if(t==null)return e.__?Sr(e.__,e.__.__k.indexOf(e)+1):null;for(var n;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null)return n.__e;return typeof e.type=="function"?Sr(e):null}function Ys(e){var t,n;if((e=e.__)!=null&&e.__c!=null){for(e.__e=e.__c.base=null,t=0;t<e.__k.length;t++)if((n=e.__k[t])!=null&&n.__e!=null){e.__e=e.__c.base=n.__e;break}return Ys(e)}}function Oi(e){(!e.__d&&(e.__d=!0)&&Wt.push(e)&&!Nr.__r++||Fs!==q.debounceRendering)&&((Fs=q.debounceRendering)||Hs)(Nr)}function Nr(){var e,t,n,r,i,a,s,o,u;for(Wt.sort(Ri);e=Wt.shift();)e.__d&&(t=Wt.length,r=void 0,i=void 0,a=void 0,o=(s=(n=e).__v).__e,(u=n.__P)&&(r=[],i=[],(a=kt({},s)).__v=s.__v+1,Di(u,s,a,n.__n,u.ownerSVGElement!==void 0,s.__h!=null?[o]:null,r,o??Sr(s),s.__h,i),Ks(r,s,i),s.__e!=o&&Ys(s)),Wt.length>t&&Wt.sort(Ri));Nr.__r=0}function js(e,t,n,r,i,a,s,o,u,c,f){var d,h,p,m,_,w,y,S,C,D,P=0,A=r&&r.__k||zs,U=A.length,I=U,H=t.length;for(n.__k=[],d=0;d<H;d++)(m=n.__k[d]=(m=t[d])==null||typeof m=="boolean"||typeof m=="function"?null:typeof m=="string"||typeof m=="number"||typeof m=="bigint"?Pn(null,m,null,null,m):Cr(m)?Pn($e,{children:m},null,null,null):m.__b>0?Pn(m.type,m.props,m.key,m.ref?m.ref:null,m.__v):m)!=null&&(m.__=n,m.__b=n.__b+1,(S=X0(m,A,y=d+P,I))===-1?p=hn:(p=A[S]||hn,A[S]=void 0,I--),Di(e,m,p,i,a,s,o,u,c,f),_=m.__e,(h=m.ref)&&p.ref!=h&&(p.ref&&Pi(p.ref,null,m),f.push(h,m.__c||_,m)),_!=null&&(w==null&&(w=_),D=!(C=p===hn||p.__v===null)&&S===y,C?S==-1&&P--:S!==y&&(S===y+1?(P++,D=!0):S>y?I>H-y?(P+=S-y,D=!0):P--:P=S<y&&S==y-1?S-y:0),y=d+P,D=D||S==d&&!C,typeof m.type!="function"||S===y&&p.__k!==m.__k?typeof m.type=="function"||D?m.__d!==void 0?(u=m.__d,m.__d=void 0):u=_.nextSibling:u=qs(e,_,u):u=Vs(m,u,e),typeof n.type=="function"&&(n.__d=u)));for(n.__e=w,d=U;d--;)A[d]!=null&&(typeof n.type=="function"&&A[d].__e!=null&&A[d].__e==n.__d&&(n.__d=A[d].__e.nextSibling),Xs(A[d],A[d]))}function Vs(e,t,n){for(var r,i=e.__k,a=0;i&&a<i.length;a++)(r=i[a])&&(r.__=e,t=typeof r.type=="function"?Vs(r,t,n):qs(n,r.__e,t));return t}function Ir(e,t){return t=t||[],e==null||typeof e=="boolean"||(Cr(e)?e.some(function(n){Ir(n,t)}):t.push(e)),t}function qs(e,t,n){return n==null||n.parentNode!==e?e.insertBefore(t,null):t==n&&t.parentNode!=null||e.insertBefore(t,n),t.nextSibling}function X0(e,t,n,r){var i=e.key,a=e.type,s=n-1,o=n+1,u=t[n];if(u===null||u&&i==u.key&&a===u.type)return n;if(r>(u!=null?1:0))for(;s>=0||o<t.length;){if(s>=0){if((u=t[s])&&i==u.key&&a===u.type)return s;s--}if(o<t.length){if((u=t[o])&&i==u.key&&a===u.type)return o;o++}}return-1}function Z0(e,t,n,r,i){var a;for(a in n)a==="children"||a==="key"||a in t||vr(e,a,null,n[a],r);for(a in t)i&&typeof t[a]!="function"||a==="children"||a==="key"||a==="value"||a==="checked"||n[a]===t[a]||vr(e,a,t[a],n[a],r)}function Ws(e,t,n){t[0]==="-"?e.setProperty(t,n??""):e[t]=n==null?"":typeof n!="number"||K0.test(t)?n:n+"px"}function vr(e,t,n,r,i){var a;e:if(t==="style")if(typeof n=="string")e.style.cssText=n;else{if(typeof r=="string"&&(e.style.cssText=r=""),r)for(t in r)n&&t in n||Ws(e.style,t,"");if(n)for(t in n)r&&n[t]===r[t]||Ws(e.style,t,n[t])}else if(t[0]==="o"&&t[1]==="n")a=t!==(t=t.replace(/Capture$/,"")),t=t.toLowerCase()in e?t.toLowerCase().slice(2):t.slice(2),e.l||(e.l={}),e.l[t+a]=n,n?r||e.addEventListener(t,a?Qs:Gs,a):e.removeEventListener(t,a?Qs:Gs,a);else if(t!=="dangerouslySetInnerHTML"){if(i)t=t.replace(/xlink(H|:h)/,"h").replace(/sName$/,"s");else if(t!=="width"&&t!=="height"&&t!=="href"&&t!=="list"&&t!=="form"&&t!=="tabIndex"&&t!=="download"&&t!=="rowSpan"&&t!=="colSpan"&&t in e)try{e[t]=n??"";break e}catch{}typeof n=="function"||(n==null||n===!1&&t[4]!=="-"?e.removeAttribute(t):e.setAttribute(t,n))}}function Gs(e){return this.l[e.type+!1](q.event?q.event(e):e)}function Qs(e){return this.l[e.type+!0](q.event?q.event(e):e)}function Di(e,t,n,r,i,a,s,o,u,c){var f,d,h,p,m,_,w,y,S,C,D,P,A,U,I,H=t.type;if(t.constructor!==void 0)return null;n.__h!=null&&(u=n.__h,o=t.__e=n.__e,t.__h=null,a=[o]),(f=q.__b)&&f(t);try{e:if(typeof H=="function"){if(y=t.props,S=(f=H.contextType)&&r[f.__c],C=f?S?S.props.value:f.__:r,n.__c?w=(d=t.__c=n.__c).__=d.__E:("prototype"in H&&H.prototype.render?t.__c=d=new H(y,C):(t.__c=d=new ht(y,C),d.constructor=H,d.render=ef),S&&S.sub(d),d.props=y,d.state||(d.state={}),d.context=C,d.__n=r,h=d.__d=!0,d.__h=[],d._sb=[]),d.__s==null&&(d.__s=d.state),H.getDerivedStateFromProps!=null&&(d.__s==d.state&&(d.__s=kt({},d.__s)),kt(d.__s,H.getDerivedStateFromProps(y,d.__s))),p=d.props,m=d.state,d.__v=t,h)H.getDerivedStateFromProps==null&&d.componentWillMount!=null&&d.componentWillMount(),d.componentDidMount!=null&&d.__h.push(d.componentDidMount);else{if(H.getDerivedStateFromProps==null&&y!==p&&d.componentWillReceiveProps!=null&&d.componentWillReceiveProps(y,C),!d.__e&&(d.shouldComponentUpdate!=null&&d.shouldComponentUpdate(y,d.__s,C)===!1||t.__v===n.__v)){for(t.__v!==n.__v&&(d.props=y,d.state=d.__s,d.__d=!1),t.__e=n.__e,t.__k=n.__k,t.__k.forEach(function(N){N&&(N.__=t)}),D=0;D<d._sb.length;D++)d.__h.push(d._sb[D]);d._sb=[],d.__h.length&&s.push(d);break e}d.componentWillUpdate!=null&&d.componentWillUpdate(y,d.__s,C),d.componentDidUpdate!=null&&d.__h.push(function(){d.componentDidUpdate(p,m,_)})}if(d.context=C,d.props=y,d.__P=e,d.__e=!1,P=q.__r,A=0,"prototype"in H&&H.prototype.render){for(d.state=d.__s,d.__d=!1,P&&P(t),f=d.render(d.props,d.state,d.context),U=0;U<d._sb.length;U++)d.__h.push(d._sb[U]);d._sb=[]}else do d.__d=!1,P&&P(t),f=d.render(d.props,d.state,d.context),d.state=d.__s;while(d.__d&&++A<25);d.state=d.__s,d.getChildContext!=null&&(r=kt(kt({},r),d.getChildContext())),h||d.getSnapshotBeforeUpdate==null||(_=d.getSnapshotBeforeUpdate(p,m)),js(e,Cr(I=f!=null&&f.type===$e&&f.key==null?f.props.children:f)?I:[I],t,n,r,i,a,s,o,u,c),d.base=t.__e,t.__h=null,d.__h.length&&s.push(d),w&&(d.__E=d.__=null)}else a==null&&t.__v===n.__v?(t.__k=n.__k,t.__e=n.__e):t.__e=J0(n.__e,t,n,r,i,a,s,u,c);(f=q.diffed)&&f(t)}catch(N){t.__v=null,(u||a!=null)&&(t.__e=o,t.__h=!!u,a[a.indexOf(o)]=null),q.__e(N,t,n)}}function Ks(e,t,n){for(var r=0;r<n.length;r++)Pi(n[r],n[++r],n[++r]);q.__c&&q.__c(t,e),e.some(function(i){try{e=i.__h,i.__h=[],e.some(function(a){a.call(i)})}catch(a){q.__e(a,i.__v)}})}function J0(e,t,n,r,i,a,s,o,u){var c,f,d,h=n.props,p=t.props,m=t.type,_=0;if(m==="svg"&&(i=!0),a!=null){for(;_<a.length;_++)if((c=a[_])&&"setAttribute"in c==!!m&&(m?c.localName===m:c.nodeType===3)){e=c,a[_]=null;break}}if(e==null){if(m===null)return document.createTextNode(p);e=i?document.createElementNS("http://www.w3.org/2000/svg",m):document.createElement(m,p.is&&p),a=null,o=!1}if(m===null)h===p||o&&e.data===p||(e.data=p);else{if(a=a&&Dn.call(e.childNodes),f=(h=n.props||hn).dangerouslySetInnerHTML,d=p.dangerouslySetInnerHTML,!o){if(a!=null)for(h={},_=0;_<e.attributes.length;_++)h[e.attributes[_].name]=e.attributes[_].value;(d||f)&&(d&&(f&&d.__html==f.__html||d.__html===e.innerHTML)||(e.innerHTML=d&&d.__html||""))}if(Z0(e,p,h,i,o),d)t.__k=[];else if(js(e,Cr(_=t.props.children)?_:[_],t,n,r,i&&m!=="foreignObject",a,s,a?a[0]:n.__k&&Sr(n,0),o,u),a!=null)for(_=a.length;_--;)a[_]!=null&&$s(a[_]);o||("value"in p&&(_=p.value)!==void 0&&(_!==e.value||m==="progress"&&!_||m==="option"&&_!==h.value)&&vr(e,"value",_,h.value,!1),"checked"in p&&(_=p.checked)!==void 0&&_!==e.checked&&vr(e,"checked",_,h.checked,!1))}return e}function Pi(e,t,n){try{typeof e=="function"?e(t):e.current=t}catch(r){q.__e(r,n)}}function Xs(e,t,n){var r,i;if(q.unmount&&q.unmount(e),(r=e.ref)&&(r.current&&r.current!==e.__e||Pi(r,null,t)),(r=e.__c)!=null){if(r.componentWillUnmount)try{r.componentWillUnmount()}catch(a){q.__e(a,t)}r.base=r.__P=null,e.__c=void 0}if(r=e.__k)for(i=0;i<r.length;i++)r[i]&&Xs(r[i],t,n||typeof e.type!="function");n||e.__e==null||$s(e.__e),e.__=e.__e=e.__d=void 0}function ef(e,t,n){return this.constructor(e,n)}function Lr(e,t,n){var r,i,a,s;q.__&&q.__(e,t),i=(r=typeof n=="function")?null:n&&n.__k||t.__k,a=[],s=[],Di(t,e=(!r&&n||t).__k=ft($e,null,[e]),i||hn,hn,t.ownerSVGElement!==void 0,!r&&n?[n]:i?null:t.firstChild?Dn.call(t.childNodes):null,a,!r&&n?n:i?i.__e:t.firstChild,r,s),Ks(a,e,s)}function tf(e,t,n){var r,i,a,s,o=kt({},e.props);for(a in e.type&&e.type.defaultProps&&(s=e.type.defaultProps),t)a=="key"?r=t[a]:a=="ref"?i=t[a]:o[a]=t[a]===void 0&&s!==void 0?s[a]:t[a];return arguments.length>2&&(o.children=arguments.length>3?Dn.call(arguments,2):n),Pn(e.type,o,r||e.key,i||e.ref,null)}function Rr(e,t){var n={__c:t="__cC"+Us++,__:e,Consumer:function(r,i){return r.children(i)},Provider:function(r){var i,a;return this.getChildContext||(i=[],(a={})[t]=this,this.getChildContext=function(){return a},this.shouldComponentUpdate=function(s){this.props.value!==s.value&&i.some(function(o){o.__e=!0,Oi(o)})},this.sub=function(s){i.push(s);var o=s.componentWillUnmount;s.componentWillUnmount=function(){i.splice(i.indexOf(s),1),o&&o.call(s)}}),r.children}};return n.Provider.__=n.Consumer.contextType=n}Dn=zs.slice,q={__e:function(e,t,n,r){for(var i,a,s;t=t.__;)if((i=t.__c)&&!i.__)try{if((a=i.constructor)&&a.getDerivedStateFromError!=null&&(i.setState(a.getDerivedStateFromError(e)),s=i.__d),i.componentDidCatch!=null&&(i.componentDidCatch(e,r||{}),s=i.__d),s)return i.__E=i}catch(o){e=o}throw e}},Ms=0,Bs=function(e){return e!=null&&e.constructor===void 0},ht.prototype.setState=function(e,t){var n;n=this.__s!=null&&this.__s!==this.state?this.__s:this.__s=kt({},this.state),typeof e=="function"&&(e=e(kt({},n),this.props)),e&&kt(n,e),e!=null&&this.__v&&(t&&this._sb.push(t),Oi(this))},ht.prototype.forceUpdate=function(e){this.__v&&(this.__e=!0,e&&this.__h.push(e),Oi(this))},ht.prototype.render=$e,Wt=[],Hs=typeof Promise=="function"?Promise.prototype.then.bind(Promise.resolve()):setTimeout,Ri=function(e,t){return e.__v.__b-t.__v.__b},Nr.__r=0,Us=0;var Gt,_e,Mi,Zs,Mn=0,Js=[],Or=[],eo=q.__b,to=q.__r,no=q.diffed,ro=q.__c,io=q.unmount;function Bn(e,t){q.__h&&q.__h(_e,e,Mn||t),Mn=0;var n=_e.__H||(_e.__H={__:[],__h:[]});return e>=n.__.length&&n.__.push({__V:Or}),n.__[e]}function oe(e){return Mn=1,nf(oo,e)}function nf(e,t,n){var r=Bn(Gt++,2);if(r.t=e,!r.__c&&(r.__=[n?n(t):oo(void 0,t),function(o){var u=r.__N?r.__N[0]:r.__[0],c=r.t(u,o);u!==c&&(r.__N=[c,r.__[1]],r.__c.setState({}))}],r.__c=_e,!_e.u)){var i=function(o,u,c){if(!r.__c.__H)return!0;var f=r.__c.__H.__.filter(function(h){return h.__c});if(f.every(function(h){return!h.__N}))return!a||a.call(this,o,u,c);var d=!1;return f.forEach(function(h){if(h.__N){var p=h.__[0];h.__=h.__N,h.__N=void 0,p!==h.__[0]&&(d=!0)}}),!(!d&&r.__c.props===o)&&(!a||a.call(this,o,u,c))};_e.u=!0;var a=_e.shouldComponentUpdate,s=_e.componentWillUpdate;_e.componentWillUpdate=function(o,u,c){if(this.__e){var f=a;a=void 0,i(o,u,c),a=f}s&&s.call(this,o,u,c)},_e.shouldComponentUpdate=i}return r.__N||r.__}function ye(e,t){var n=Bn(Gt++,3);!q.__s&&so(n.__H,t)&&(n.__=e,n.i=t,_e.__H.__h.push(n))}function Oe(e){return Mn=5,we(function(){return{current:e}},[])}function we(e,t){var n=Bn(Gt++,7);return so(n.__H,t)?(n.__V=e(),n.i=t,n.__h=e,n.__V):n.__}function De(e,t){return Mn=8,we(function(){return e},t)}function Ve(e){var t=_e.context[e.__c],n=Bn(Gt++,9);return n.c=e,t?(n.__==null&&(n.__=!0,t.sub(_e)),t.props.value):e.__}function rf(){var e=Bn(Gt++,11);if(!e.__){for(var t=_e.__v;t!==null&&!t.__m&&t.__!==null;)t=t.__;var n=t.__m||(t.__m=[0,0]);e.__="P"+n[0]+"-"+n[1]++}return e.__}function af(){for(var e;e=Js.shift();)if(e.__P&&e.__H)try{e.__H.__h.forEach(Dr),e.__H.__h.forEach(Bi),e.__H.__h=[]}catch(t){e.__H.__h=[],q.__e(t,e.__v)}}q.__b=function(e){_e=null,eo&&eo(e)},q.__r=function(e){to&&to(e),Gt=0;var t=(_e=e.__c).__H;t&&(Mi===_e?(t.__h=[],_e.__h=[],t.__.forEach(function(n){n.__N&&(n.__=n.__N),n.__V=Or,n.__N=n.i=void 0})):(t.__h.forEach(Dr),t.__h.forEach(Bi),t.__h=[],Gt=0)),Mi=_e},q.diffed=function(e){no&&no(e);var t=e.__c;t&&t.__H&&(t.__H.__h.length&&(Js.push(t)!==1&&Zs===q.requestAnimationFrame||((Zs=q.requestAnimationFrame)||sf)(af)),t.__H.__.forEach(function(n){n.i&&(n.__H=n.i),n.__V!==Or&&(n.__=n.__V),n.i=void 0,n.__V=Or})),Mi=_e=null},q.__c=function(e,t){t.some(function(n){try{n.__h.forEach(Dr),n.__h=n.__h.filter(function(r){return!r.__||Bi(r)})}catch(r){t.some(function(i){i.__h&&(i.__h=[])}),t=[],q.__e(r,n.__v)}}),ro&&ro(e,t)},q.unmount=function(e){io&&io(e);var t,n=e.__c;n&&n.__H&&(n.__H.__.forEach(function(r){try{Dr(r)}catch(i){t=i}}),n.__H=void 0,t&&q.__e(t,n.__v))};var ao=typeof requestAnimationFrame=="function";function sf(e){var t,n=function(){clearTimeout(r),ao&&cancelAnimationFrame(t),setTimeout(e)},r=setTimeout(n,100);ao&&(t=requestAnimationFrame(n))}function Dr(e){var t=_e,n=e.__c;typeof n=="function"&&(e.__c=void 0,n()),_e=t}function Bi(e){var t=_e;e.__c=e.__(),_e=t}function so(e,t){return!e||e.length!==t.length||t.some(function(n,r){return n!==e[r]})}function oo(e,t){return typeof t=="function"?t(e):t}var of=Symbol.for("preact-signals");function Fi(){if(pn>1)pn--;else{for(var e,t=!1;Fn!==void 0;){var n=Fn;for(Fn=void 0,Hi++;n!==void 0;){var r=n.o;if(n.o=void 0,n.f&=-3,!(8&n.f)&&lo(n))try{n.c()}catch(i){t||(e=i,t=!0)}n=r}}if(Hi=0,pn--,t)throw e}}var me=void 0,Fn=void 0,pn=0,Hi=0,Pr=0;function uo(e){if(me!==void 0){var t=e.n;if(t===void 0||t.t!==me)return t={i:0,S:e,p:me.s,n:void 0,t:me,e:void 0,x:void 0,r:t},me.s!==void 0&&(me.s.n=t),me.s=t,e.n=t,32&me.f&&e.S(t),t;if(t.i===-1)return t.i=0,t.n!==void 0&&(t.n.p=t.p,t.p!==void 0&&(t.p.n=t.n),t.p=me.s,t.n=void 0,me.s.n=t,me.s=t),t}}function Be(e){this.v=e,this.i=0,this.n=void 0,this.t=void 0}Be.prototype.brand=of,Be.prototype.h=function(){return!0},Be.prototype.S=function(e){this.t!==e&&e.e===void 0&&(e.x=this.t,this.t!==void 0&&(this.t.e=e),this.t=e)},Be.prototype.U=function(e){if(this.t!==void 0){var t=e.e,n=e.x;t!==void 0&&(t.x=n,e.e=void 0),n!==void 0&&(n.e=t,e.x=void 0),e===this.t&&(this.t=n)}},Be.prototype.subscribe=function(e){var t=this;return Un(function(){var n=t.value,r=me;me=void 0;try{e(n)}finally{me=r}})},Be.prototype.valueOf=function(){return this.value},Be.prototype.toString=function(){return this.value+""},Be.prototype.toJSON=function(){return this.value},Be.prototype.peek=function(){var e=me;me=void 0;try{return this.value}finally{me=e}},Object.defineProperty(Be.prototype,"value",{get:function(){var e=uo(this);return e!==void 0&&(e.i=this.i),this.v},set:function(e){if(e!==this.v){if(Hi>100)throw new Error("Cycle detected");this.v=e,this.i++,Pr++,pn++;try{for(var t=this.t;t!==void 0;t=t.x)t.t.N()}finally{Fi()}}}});function at(e){return new Be(e)}function lo(e){for(var t=e.s;t!==void 0;t=t.n)if(t.S.i!==t.i||!t.S.h()||t.S.i!==t.i)return!0;return!1}function co(e){for(var t=e.s;t!==void 0;t=t.n){var n=t.S.n;if(n!==void 0&&(t.r=n),t.S.n=t,t.i=-1,t.n===void 0){e.s=t;break}}}function fo(e){for(var t=e.s,n=void 0;t!==void 0;){var r=t.p;t.i===-1?(t.S.U(t),r!==void 0&&(r.n=t.n),t.n!==void 0&&(t.n.p=r)):n=t,t.S.n=t.r,t.r!==void 0&&(t.r=void 0),t=r}e.s=n}function mn(e){Be.call(this,void 0),this.x=e,this.s=void 0,this.g=Pr-1,this.f=4}(mn.prototype=new Be).h=function(){if(this.f&=-3,1&this.f)return!1;if((36&this.f)==32||(this.f&=-5,this.g===Pr))return!0;if(this.g=Pr,this.f|=1,this.i>0&&!lo(this))return this.f&=-2,!0;var e=me;try{co(this),me=this;var t=this.x();(16&this.f||this.v!==t||this.i===0)&&(this.v=t,this.f&=-17,this.i++)}catch(n){this.v=n,this.f|=16,this.i++}return me=e,fo(this),this.f&=-2,!0},mn.prototype.S=function(e){if(this.t===void 0){this.f|=36;for(var t=this.s;t!==void 0;t=t.n)t.S.S(t)}Be.prototype.S.call(this,e)},mn.prototype.U=function(e){if(this.t!==void 0&&(Be.prototype.U.call(this,e),this.t===void 0)){this.f&=-33;for(var t=this.s;t!==void 0;t=t.n)t.S.U(t)}},mn.prototype.N=function(){if(!(2&this.f)){this.f|=6;for(var e=this.t;e!==void 0;e=e.x)e.t.N()}},Object.defineProperty(mn.prototype,"value",{get:function(){if(1&this.f)throw new Error("Cycle detected");var e=uo(this);if(this.h(),e!==void 0&&(e.i=this.i),16&this.f)throw this.v;return this.v}});function ho(e){return new mn(e)}function po(e){var t=e.u;if(e.u=void 0,typeof t=="function"){pn++;var n=me;me=void 0;try{t()}catch(r){throw e.f&=-2,e.f|=8,Ui(e),r}finally{me=n,Fi()}}}function Ui(e){for(var t=e.s;t!==void 0;t=t.n)t.S.U(t);e.x=void 0,e.s=void 0,po(e)}function uf(e){if(me!==this)throw new Error("Out-of-order effect");fo(this),me=e,this.f&=-2,8&this.f&&Ui(this),Fi()}function Hn(e){this.x=e,this.u=void 0,this.s=void 0,this.o=void 0,this.f=32}Hn.prototype.c=function(){var e=this.S();try{if(8&this.f||this.x===void 0)return;var t=this.x();typeof t=="function"&&(this.u=t)}finally{e()}},Hn.prototype.S=function(){if(1&this.f)throw new Error("Cycle detected");this.f|=1,this.f&=-9,po(this),co(this),pn++;var e=me;return me=this,uf.bind(this,e)},Hn.prototype.N=function(){2&this.f||(this.f|=2,this.o=Fn,Fn=this)},Hn.prototype.d=function(){this.f|=8,1&this.f||Ui(this)};function Un(e){var t=new Hn(e);try{t.c()}catch(n){throw t.d(),n}return t.d.bind(t)}var Mr,zi;function gn(e,t){q[e]=t.bind(null,q[e]||function(){})}function Br(e){zi&&zi(),zi=e&&e.S()}function mo(e){var t=this,n=e.data,r=cf(n);r.value=n;var i=we(function(){for(var a=t.__v;a=a.__;)if(a.__c){a.__c.__$f|=4;break}return t.__$u.c=function(){var s;!Bs(i.peek())&&((s=t.base)==null?void 0:s.nodeType)===3?t.base.data=i.peek():(t.__$f|=1,t.setState({}))},ho(function(){var s=r.value.value;return s===0?0:s===!0?"":s||""})},[]);return i.value}mo.displayName="_st",Object.defineProperties(Be.prototype,{constructor:{configurable:!0,value:void 0},type:{configurable:!0,value:mo},props:{configurable:!0,get:function(){return{data:this}}},__b:{configurable:!0,value:1}}),gn("__b",function(e,t){if(typeof t.type=="string"){var n,r=t.props;for(var i in r)if(i!=="children"){var a=r[i];a instanceof Be&&(n||(t.__np=n={}),n[i]=a,r[i]=a.peek())}}e(t)}),gn("__r",function(e,t){Br();var n,r=t.__c;r&&(r.__$f&=-2,(n=r.__$u)===void 0&&(r.__$u=n=function(i){var a;return Un(function(){a=this}),a.c=function(){r.__$f|=1,r.setState({})},a}())),Mr=r,Br(n),e(t)}),gn("__e",function(e,t,n,r){Br(),Mr=void 0,e(t,n,r)}),gn("diffed",function(e,t){Br(),Mr=void 0;var n;if(typeof t.type=="string"&&(n=t.__e)){var r=t.__np,i=t.props;if(r){var a=n.U;if(a)for(var s in a){var o=a[s];o!==void 0&&!(s in r)&&(o.d(),a[s]=void 0)}else n.U=a={};for(var u in r){var c=a[u],f=r[u];c===void 0?(c=lf(n,u,f,i),a[u]=c):c.o(f,i)}}}e(t)});function lf(e,t,n,r){var i=t in e&&e.ownerSVGElement===void 0,a=at(n);return{o:function(s,o){a.value=s,r=o},d:Un(function(){var s=a.value.value;r[t]!==s&&(r[t]=s,i?e[t]=s:s?e.setAttribute(t,s):e.removeAttribute(t))})}}gn("unmount",function(e,t){if(typeof t.type=="string"){var n=t.__e;if(n){var r=n.U;if(r){n.U=void 0;for(var i in r){var a=r[i];a&&a.d()}}}}else{var s=t.__c;if(s){var o=s.__$u;o&&(s.__$u=void 0,o.d())}}e(t)}),gn("__h",function(e,t,n,r){(r<3||r===9)&&(t.__$f|=2),e(t,n,r)}),ht.prototype.shouldComponentUpdate=function(e,t){var n=this.__$u;if(!(n&&n.s!==void 0||4&this.__$f)||3&this.__$f)return!0;for(var r in t)return!0;for(var i in e)if(i!=="__source"&&e[i]!==this.props[i])return!0;for(var a in this.props)if(!(a in e))return!0;return!1};function cf(e){return we(function(){return at(e)},[])}function $i(e){var t=Oe(e);return t.current=e,Mr.__$f|=4,we(function(){return ho(function(){return t.current()})},[])}function go(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e))for(t=0;t<e.length;t++)e[t]&&(n=go(e[t]))&&(r&&(r+=" "),r+=n);else for(t in e)e[t]&&(r&&(r+=" "),r+=t);return r}function Yi(){for(var e,t,n=0,r="";n<arguments.length;)(e=arguments[n++])&&(t=go(e))&&(r&&(r+=" "),r+=t);return r}const bo=e=>typeof e=="boolean"?"".concat(e):e===0?"0":e,df=e=>{const t=function(){for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];var o,u;return typeof(e==null||(o=e.hooks)===null||o===void 0?void 0:o["cx:done"])<"u"?e?.hooks["cx:done"](Yi(a)):typeof(e==null||(u=e.hooks)===null||u===void 0?void 0:u.onComplete)<"u"?e?.hooks.onComplete(Yi(a)):Yi(a)};return{compose:function(){for(var i=arguments.length,a=new Array(i),s=0;s<i;s++)a[s]=arguments[s];return o=>{const u=Object.fromEntries(Object.entries(o||{}).filter(c=>{let[f]=c;return!["class","className"].includes(f)}));return t(a.map(c=>c(u)),o?.class,o?.className)}},cva:i=>a=>{var s;if(i?.variants==null)return t(i?.base,a?.class,a?.className);const{variants:o,defaultVariants:u}=i,c=Object.keys(o).map(h=>{const p=a?.[h],m=u?.[h],_=bo(p)||bo(m);return o[h][_]}),f={...u,...a&&Object.entries(a).reduce((h,p)=>{let[m,_]=p;return typeof _>"u"?h:{...h,[m]:_}},{})},d=i==null||(s=i.compoundVariants)===null||s===void 0?void 0:s.reduce((h,p)=>{let{class:m,className:_,...w}=p;return Object.entries(w).every(y=>{let[S,C]=y;const D=f[S];return Array.isArray(C)?C.includes(D):D===C})?[...h,m,_]:h},[]);return t(i?.base,c,d,a?.class,a?.className)},cx:t}},{compose:N6,cva:St,cx:I6}=df(),ff=at(!1),hf=at(!1),pf=at("idle"),ji=at(!1),Vi=at("idle"),qi=at(null),Wi=at(null),pt=at([]),Gi=at([]),Qi=typeof BroadcastChannel<"u"?new BroadcastChannel("kin-sync"):null;Qi?.addEventListener("message",e=>{const{type:t,data:n}=e.data;switch(t){case"messages_updated":pt.value=n.messages.map(r=>({...r,timestamp:new Date(r.timestamp)}));break;case"messages_cleared":pt.value=[];break}});const Ki=()=>{Qi?.postMessage({type:"messages_updated",data:{messages:pt.value}})},Y={isOpen:ff,isStreaming:hf,connectionState:pf,messages:pt,quickReplies:Gi,uploadState:Vi,uploadError:qi,uploadFileName:Wi,hasUnreadMessages:ji,addMessage:e=>{pt.value=[...pt.value,{...e,id:crypto.randomUUID(),timestamp:new Date}],Gi.value=[],Ki()},appendToLastMessage:e=>{const t=pt.value;if(t.length===0)return;const n=t[t.length-1];!n||n.role!=="assistant"||(pt.value=[...t.slice(0,-1),{...n,content:n.content+e}])},clearMessages:()=>{pt.value=[],Qi?.postMessage({type:"messages_cleared"})},setMessages:e=>{pt.value=e.map(t=>({...t,id:crypto.randomUUID(),timestamp:new Date})),Ki()},syncToOtherTabs:()=>{Ki()},setUploadState:(e,t,n)=>{Vi.value=e,Wi.value=t??null,qi.value=n??null},resetUploadState:()=>{Vi.value="idle",Wi.value=null,qi.value=null},setHasUnreadMessages:e=>{ji.value=e},clearUnreadMessages:()=>{ji.value=!1},setQuickReplies:e=>{Gi.value=e}};var mf=0;function b(e,t,n,r,i,a){var s,o,u={};for(o in t)o=="ref"?s=t[o]:u[o]=t[o];var c={type:e,props:u,key:n,ref:s,__k:null,__:null,__b:0,__e:null,__d:void 0,__c:null,__h:null,constructor:void 0,__v:--mf,__source:i,__self:a};if(typeof e=="function"&&(s=e.defaultProps))for(o in s)u[o]===void 0&&(u[o]=s[o]);return q.vnode&&q.vnode(c),c}function gf({class:e,"aria-hidden":t="true"}){return b("svg",{class:e,viewBox:"0 0 870 400",fill:"currentColor","aria-hidden":t,focusable:"false",children:b("path",{d:"M220.468 331.21c-21.275-9.559-42.081-30.347-79.541-67.777l-56.1-56.087c-9.106-9.106-14.522-14.541-18.414-18.802-2.471-2.705-3.42-3.973-3.645-4.286a20.3 20.3 0 0 1 0-20.058c.224-.314 1.173-1.582 3.644-4.286 3.893-4.261 9.309-9.697 18.414-18.803 43.366-43.365 57.154-56.438 69.786-63.775 39.522-22.958 88.319-22.958 127.842-.001 12.632 7.337 26.42 20.41 69.786 63.774l30.412 30.411 42.51-42.509-30.413-30.412c-40.657-40.656-60.986-60.984-82.1-73.248-58.192-33.802-130.041-33.801-188.233.001-21.114 12.265-41.442 32.593-82.099 73.25-17.449 17.449-26.174 26.173-31.437 35.235a80.417 80.417 0 0 0 0 80.785c5.264 9.061 13.99 17.785 31.438 35.234l69.155 69.152c30.203 30.202 45.305 45.303 62.973 56.034a171.768 171.768 0 0 0 48.416 20.055C242.943 400.001 264.3 400 307.013 400H608.43c42.714 0 64.071-.001 84.153-4.906A171.733 171.733 0 0 0 741 375.039c17.668-10.731 32.77-25.833 62.973-56.037l13.213-13.213c160.161-160.161-80.08-400.402-240.241-240.24L379.079 263.39c-42.114 42.109-63.171 63.164-87.526 70.869a104.629 104.629 0 0 1-59.446 1.086 111.797 111.797 0 0 1-11.639-4.136Z"})})}function bf({class:e,"aria-hidden":t="true"}){return b("svg",{class:e,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2.5","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":t,focusable:"false",children:[b("path",{d:"M12 19V5"}),b("path",{d:"M5 12l7-7 7 7"})]})}function Ef({class:e,"aria-hidden":t="true"}){return b("svg",{class:e,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":t,focusable:"false",children:[b("path",{d:"M18 6L6 18"}),b("path",{d:"M6 6l12 12"})]})}function Tf({class:e,"aria-hidden":t="true"}){return b("svg",{class:e,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":t,focusable:"false",children:[b("path",{d:"M3 6h18"}),b("path",{d:"M19 6v14c0 1-1 2-2 2H7c-1 0-2-1-2-2V6"}),b("path",{d:"M8 6V4c0-1 1-2 2-2h4c1 0 2 1 2 2v2"})]})}function _f({class:e,"aria-hidden":t="true"}){return b("svg",{class:e,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":t,focusable:"false",children:b("path",{d:"M21.44 11.05l-9.19 9.19a6 6 0 01-8.49-8.49l9.19-9.19a4 4 0 015.66 5.66l-9.2 9.19a2 2 0 01-2.83-2.83l8.49-8.48"})})}function kf({class:e,"aria-hidden":t="true"}){return b("svg",{class:e,viewBox:"0 0 24 24",fill:"none",stroke:"currentColor","stroke-width":"2","stroke-linecap":"round","stroke-linejoin":"round","aria-hidden":t,focusable:"false",children:b("path",{d:"M21 12a9 9 0 11-6.219-8.56"})})}function xf(e,t){for(var n in t)e[n]=t[n];return e}function Xi(e,t){for(var n in e)if(n!=="__source"&&!(n in t))return!0;for(var r in t)if(r!=="__source"&&e[r]!==t[r])return!0;return!1}function Eo(e){this.props=e}function fe(e,t){function n(i){var a=this.props.ref,s=a==i.ref;return!s&&a&&(a.call?a(null):a.current=null),t?!t(this.props,i)||!s:Xi(this.props,i)}function r(i){return this.shouldComponentUpdate=n,ft(e,i)}return r.displayName="Memo("+(e.displayName||e.name)+")",r.prototype.isReactComponent=!0,r.__f=!0,r}(Eo.prototype=new ht).isPureReactComponent=!0,Eo.prototype.shouldComponentUpdate=function(e,t){return Xi(this.props,e)||Xi(this.state,t)};var To=q.__b;q.__b=function(e){e.type&&e.type.__f&&e.ref&&(e.props.ref=e.ref,e.ref=null),To&&To(e)};var yf=q.__e;q.__e=function(e,t,n,r){if(e.then){for(var i,a=t;a=a.__;)if((i=a.__c)&&i.__c)return t.__e==null&&(t.__e=n.__e,t.__k=n.__k),i.__c(e,t)}yf(e,t,n,r)};var _o=q.unmount;function ko(e,t,n){return e&&(e.__c&&e.__c.__H&&(e.__c.__H.__.forEach(function(r){typeof r.__c=="function"&&r.__c()}),e.__c.__H=null),(e=xf({},e)).__c!=null&&(e.__c.__P===n&&(e.__c.__P=t),e.__c=null),e.__k=e.__k&&e.__k.map(function(r){return ko(r,t,n)})),e}function xo(e,t,n){return e&&(e.__v=null,e.__k=e.__k&&e.__k.map(function(r){return xo(r,t,n)}),e.__c&&e.__c.__P===t&&(e.__e&&n.insertBefore(e.__e,e.__d),e.__c.__e=!0,e.__c.__P=n)),e}function zn(){this.__u=0,this.t=null,this.__b=null}function yo(e){var t=e.__.__c;return t&&t.__a&&t.__a(e)}function wo(e){var t,n,r;function i(a){if(t||(t=e()).then(function(s){n=s.default||s},function(s){r=s}),r)throw r;if(!n)throw t;return ft(n,a)}return i.displayName="Lazy",i.__f=!0,i}function Fr(){this.u=null,this.o=null}q.unmount=function(e){var t=e.__c;t&&t.__R&&t.__R(),t&&e.__h===!0&&(e.type=null),_o&&_o(e)},(zn.prototype=new ht).__c=function(e,t){var n=t.__c,r=this;r.t==null&&(r.t=[]),r.t.push(n);var i=yo(r.__v),a=!1,s=function(){a||(a=!0,n.__R=null,i?i(o):o())};n.__R=s;var o=function(){if(!--r.__u){if(r.state.__a){var c=r.state.__a;r.__v.__k[0]=xo(c,c.__c.__P,c.__c.__O)}var f;for(r.setState({__a:r.__b=null});f=r.t.pop();)f.forceUpdate()}},u=t.__h===!0;r.__u++||u||r.setState({__a:r.__b=r.__v.__k[0]}),e.then(s,s)},zn.prototype.componentWillUnmount=function(){this.t=[]},zn.prototype.render=function(e,t){if(this.__b){if(this.__v.__k){var n=document.createElement("div"),r=this.__v.__k[0].__c;this.__v.__k[0]=ko(this.__b,n,r.__O=r.__P)}this.__b=null}var i=t.__a&&ft($e,null,e.fallback);return i&&(i.__h=null),[ft($e,null,t.__a?null:e.children),i]};var Ao=function(e,t,n){if(++n[1]===n[0]&&e.o.delete(t),e.props.revealOrder&&(e.props.revealOrder[0]!=="t"||!e.o.size))for(n=e.u;n;){for(;n.length>3;)n.pop()();if(n[1]<n[0])break;e.u=n=n[2]}};function wf(e){return this.getChildContext=function(){return e.context},e.children}function Af(e){var t=this,n=e.i;t.componentWillUnmount=function(){Lr(null,t.l),t.l=null,t.i=null},t.i&&t.i!==n&&t.componentWillUnmount(),e.__v?(t.l||(t.i=n,t.l={nodeType:1,parentNode:n,childNodes:[],appendChild:function(r){this.childNodes.push(r),t.i.appendChild(r)},insertBefore:function(r,i){this.childNodes.push(r),t.i.appendChild(r)},removeChild:function(r){this.childNodes.splice(this.childNodes.indexOf(r)>>>1,1),t.i.removeChild(r)}}),Lr(ft(wf,{context:t.context},e.__v),t.l)):t.l&&t.componentWillUnmount()}function Cf(e,t){var n=ft(Af,{__v:e,i:t});return n.containerInfo=t,n}(Fr.prototype=new ht).__a=function(e){var t=this,n=yo(t.__v),r=t.o.get(e);return r[0]++,function(i){var a=function(){t.props.revealOrder?(r.push(i),Ao(t,e,r)):i()};n?n(a):a()}},Fr.prototype.render=function(e){this.u=null,this.o=new Map;var t=Ir(e.children);e.revealOrder&&e.revealOrder[0]==="b"&&t.reverse();for(var n=t.length;n--;)this.o.set(t[n],this.u=[1,0,this.u]);return e.children},Fr.prototype.componentDidUpdate=Fr.prototype.componentDidMount=function(){var e=this;this.o.forEach(function(t,n){Ao(e,n,t)})};var Co=typeof Symbol<"u"&&Symbol.for&&Symbol.for("react.element")||60103,Sf=/^(?:accent|alignment|arabic|baseline|cap|clip(?!PathU)|color|dominant|fill|flood|font|glyph(?!R)|horiz|image(!S)|letter|lighting|marker(?!H|W|U)|overline|paint|pointer|shape|stop|strikethrough|stroke|text(?!L)|transform|underline|unicode|units|v|vector|vert|word|writing|x(?!C))[A-Z]/,Nf=/^on(Ani|Tra|Tou|BeforeInp|Compo)/,If=/[A-Z0-9]/g,vf=typeof document<"u",Lf=function(e){return(typeof Symbol<"u"&&typeof Symbol()=="symbol"?/fil|che|rad/:/fil|che|ra/).test(e)};ht.prototype.isReactComponent={},["componentWillMount","componentWillReceiveProps","componentWillUpdate"].forEach(function(e){Object.defineProperty(ht.prototype,e,{configurable:!0,get:function(){return this["UNSAFE_"+e]},set:function(t){Object.defineProperty(this,e,{configurable:!0,writable:!0,value:t})}})});var So=q.event;function Rf(){}function Of(){return this.cancelBubble}function Df(){return this.defaultPrevented}q.event=function(e){return So&&(e=So(e)),e.persist=Rf,e.isPropagationStopped=Of,e.isDefaultPrevented=Df,e.nativeEvent=e};var Pf={enumerable:!1,configurable:!0,get:function(){return this.class}},No=q.vnode;q.vnode=function(e){typeof e.type=="string"&&function(t){var n=t.props,r=t.type,i={};for(var a in n){var s=n[a];if(!(a==="value"&&"defaultValue"in n&&s==null||vf&&a==="children"&&r==="noscript"||a==="class"||a==="className")){var o=a.toLowerCase();a==="defaultValue"&&"value"in n&&n.value==null?a="value":a==="download"&&s===!0?s="":o==="ondoubleclick"?a="ondblclick":o!=="onchange"||r!=="input"&&r!=="textarea"||Lf(n.type)?o==="onfocus"?a="onfocusin":o==="onblur"?a="onfocusout":Nf.test(a)?a=o:r.indexOf("-")===-1&&Sf.test(a)?a=a.replace(If,"-$&").toLowerCase():s===null&&(s=void 0):o=a="oninput",o==="oninput"&&i[a=o]&&(a="oninputCapture"),i[a]=s}}r=="select"&&i.multiple&&Array.isArray(i.value)&&(i.value=Ir(n.children).forEach(function(u){u.props.selected=i.value.indexOf(u.props.value)!=-1})),r=="select"&&i.defaultValue!=null&&(i.value=Ir(n.children).forEach(function(u){u.props.selected=i.multiple?i.defaultValue.indexOf(u.props.value)!=-1:i.defaultValue==u.props.value})),n.class&&!n.className?(i.class=n.class,Object.defineProperty(i,"className",Pf)):(n.className&&!n.class||n.class&&n.className)&&(i.class=i.className=n.className),t.props=i}(e),e.$$typeof=Co,No&&No(e)};var Io=q.__r;q.__r=function(e){Io&&Io(e)};var vo=q.diffed;q.diffed=function(e){vo&&vo(e);var t=e.props,n=e.__e;n!=null&&e.type==="textarea"&&"value"in t&&t.value!==n.value&&(n.value=t.value==null?"":t.value)};function Nt(e){return!!e&&e.$$typeof===Co}function Mf(e){return Nt(e)?tf.apply(null,arguments):e}function Bf(e){e()}function Ff(){return[!1,Bf]}const Hr=function(e){if(e==null)return $f;if(typeof e=="function")return Ur(e);if(typeof e=="object")return Array.isArray(e)?Hf(e):Uf(e);if(typeof e=="string")return zf(e);throw new Error("Expected function, string, or object as test")};function Hf(e){const t=[];let n=-1;for(;++n<e.length;)t[n]=Hr(e[n]);return Ur(r);function r(...i){let a=-1;for(;++a<t.length;)if(t[a].apply(this,i))return!0;return!1}}function Uf(e){const t=e;return Ur(n);function n(r){const i=r;let a;for(a in e)if(i[a]!==t[a])return!1;return!0}}function zf(e){return Ur(t);function t(n){return n&&n.type===e}}function Ur(e){return t;function t(n,r,i){return!!(Yf(n)&&e.call(this,n,typeof r=="number"?r:void 0,i||void 0))}}function $f(){return!0}function Yf(e){return e!==null&&typeof e=="object"&&"type"in e}function U6(e){return e}const Lo=[],$n=!0,Zi=!1,bn="skip";function Ji(e,t,n,r){let i;typeof t=="function"&&typeof n!="function"?(r=n,n=t):i=t;const a=Hr(i),s=r?-1:1;o(e,void 0,[])();function o(u,c,f){const d=u&&typeof u=="object"?u:{};if(typeof d.type=="string"){const p=typeof d.tagName=="string"?d.tagName:typeof d.name=="string"?d.name:void 0;Object.defineProperty(h,"name",{value:"node ("+(u.type+(p?"<"+p+">":""))+")"})}return h;function h(){let p=Lo,m,_,w;if((!t||a(u,c,f[f.length-1]||void 0))&&(p=jf(n(u,f)),p[0]===Zi))return p;if("children"in u&&u.children){const y=u;if(y.children&&p[0]!==bn)for(_=(r?y.children.length:-1)+s,w=f.concat(y);_>-1&&_<y.children.length;){const S=y.children[_];if(m=o(S,_,w)(),m[0]===Zi)return m;_=typeof m[1]=="number"?m[1]:_+s}}return p}}}function jf(e){return Array.isArray(e)?e:typeof e=="number"?[$n,e]:e==null?Lo:[e]}function It(e,t,n,r){let i,a,s;typeof t=="function"&&typeof n!="function"?(a=void 0,s=t,i=n):(a=t,s=n,i=r),Ji(e,a,o,i);function o(u,c){const f=c[c.length-1],d=f?f.children.indexOf(u):void 0;return s(u,d,f)}}const En={indicator:"indicator",textOnly:"text-only",remove:"remove"};function Vf({defaultOrigin:e="",allowedLinkPrefixes:t=[],allowedImagePrefixes:n=[],allowDataImages:r=!1,allowedProtocols:i=[],blockedImageClass:a="inline-block bg-gray-200 dark:bg-gray-700 text-gray-600 dark:text-gray-400 px-3 py-1 rounded text-sm",blockedLinkClass:s="text-gray-500",linkBlockPolicy:o=En.indicator,imageBlockPolicy:u=En.indicator}){const c=t.length&&!t.every(d=>d==="*"),f=n.length&&!n.every(d=>d==="*");if(!e&&(c||f))throw new Error("defaultOrigin is required when allowedLinkPrefixes or allowedImagePrefixes are provided");return d=>{const h=Xf(e,t,n,r,i,a,s,o,u);Do(d),It(d,h)}}function Ro(e,t){if(typeof e!="string")return null;try{return new URL(e)}catch{if(t)try{return new URL(e,t)}catch{return null}if(e.startsWith("/")||e.startsWith("./")||e.startsWith("../"))try{return new URL(e,"http://example.com")}catch{return null}return null}}function qf(e){return typeof e!="string"?!1:e.startsWith("/")||e.startsWith("./")||e.startsWith("../")}const Wf=new Set(["https:","http:","irc:","ircs:","mailto:","xmpp:","blob:"]),Gf=new Set(["javascript:","data:","file:","vbscript:"]);function Oo(e,t,n,r=!1,i=!1,a=[]){if(!e)return null;if(typeof e=="string"&&e.startsWith("#")&&!i)try{if(new URL(e,"http://example.com").hash===e)return e}catch{}if(typeof e=="string"&&e.startsWith("data:"))return i&&r&&e.startsWith("data:image/")?e:null;if(typeof e=="string"&&e.startsWith("blob:")){try{if(new URL(e).protocol==="blob:"&&e.length>5){const f=e.substring(5);if(f&&f.length>0&&f!=="invalid")return e}}catch{return null}return null}const s=Ro(e,n);if(!s||Gf.has(s.protocol)||!(Wf.has(s.protocol)||a.includes(s.protocol)||a.includes("*")))return null;if(s.protocol==="mailto:"||!s.protocol.match(/^https?:$/))return s.href;const u=qf(e);return s&&t.some(c=>{const f=Ro(c,n);return!f||f.origin!==s.origin?!1:s.href.startsWith(f.href)})?u?s.pathname+s.search+s.hash:s.href:t.includes("*")?s.protocol!=="https:"&&s.protocol!=="http:"?null:u?s.pathname+s.search+s.hash:s.href:null}function Do(e){if("children"in e&&Array.isArray(e.children)){e.children=e.children.filter(t=>t!=null);for(const t of e.children)Do(t)}}const ea=Symbol("node-seen");function Qf(e,t,n){return t===En.remove?{type:"remove"}:t===En.textOnly?{type:"replace",element:{type:"element",tagName:"span",properties:{},children:[...e.children]}}:{type:"replace",element:{type:"element",tagName:"span",properties:{title:"Blocked URL: "+String(e.properties.href),class:n},children:[...e.children,{type:"text",value:" [blocked]"}]}}}function Kf(e,t,n){if(t===En.remove)return{type:"remove"};if(t===En.textOnly){const r=String(e.properties.alt||"");return r?{type:"replace",element:{type:"element",tagName:"span",properties:{},children:[{type:"text",value:r}]}}:{type:"remove"}}return{type:"replace",element:{type:"element",tagName:"span",properties:{class:n},children:[{type:"text",value:"[Image blocked: "+String(e.properties.alt||"No description")+"]"}]}}}const Xf=(e,t,n,r,i,a,s,o,u)=>{const c=(f,d,h)=>{if(f.type!=="element"||f[ea])return $n;if(f.tagName==="a"){const p=Oo(f.properties.href,t,e,!1,!1,i);if(p===null){if(f[ea]=!0,It(f,c),h&&typeof d=="number"){const m=Qf(f,o,s);if(m.type==="remove")return h.children.splice(d,1),[bn,d];h.children[d]=m.element}return bn}else return f.properties.href=p,f.properties.target="_blank",f.properties.rel="noopener noreferrer",$n}if(f.tagName==="img"){const p=Oo(f.properties.src,n,e,r,!0,i);if(p===null){if(f[ea]=!0,It(f,c),h&&typeof d=="number"){const m=Kf(f,u,a);if(m.type==="remove")return h.children.splice(d,1),[bn,d];h.children[d]=m.element}return bn}else return f.properties.src=p,$n}return $n};return c},Po=-1,zr=0,Yn=1,$r=2,ta=3,na=4,ra=5,ia=6,Mo=7,Bo=8,Fo=typeof self=="object"?self:globalThis,Zf=(e,t)=>{const n=(i,a)=>(e.set(a,i),i),r=i=>{if(e.has(i))return e.get(i);const[a,s]=t[i];switch(a){case zr:case Po:return n(s,i);case Yn:{const o=n([],i);for(const u of s)o.push(r(u));return o}case $r:{const o=n({},i);for(const[u,c]of s)o[r(u)]=r(c);return o}case ta:return n(new Date(s),i);case na:{const{source:o,flags:u}=s;return n(new RegExp(o,u),i)}case ra:{const o=n(new Map,i);for(const[u,c]of s)o.set(r(u),r(c));return o}case ia:{const o=n(new Set,i);for(const u of s)o.add(r(u));return o}case Mo:{const{name:o,message:u}=s;return n(new Fo[o](u),i)}case Bo:return n(BigInt(s),i);case"BigInt":return n(Object(BigInt(s)),i);case"ArrayBuffer":return n(new Uint8Array(s).buffer,s);case"DataView":{const{buffer:o}=new Uint8Array(s);return n(new DataView(o),s)}}return n(new Fo[a](s),i)};return r},Ho=e=>Zf(new Map,e)(0),Tn="",{toString:Jf}={},{keys:eh}=Object,jn=e=>{const t=typeof e;if(t!=="object"||!e)return[zr,t];const n=Jf.call(e).slice(8,-1);switch(n){case"Array":return[Yn,Tn];case"Object":return[$r,Tn];case"Date":return[ta,Tn];case"RegExp":return[na,Tn];case"Map":return[ra,Tn];case"Set":return[ia,Tn];case"DataView":return[Yn,n]}return n.includes("Array")?[Yn,n]:n.includes("Error")?[Mo,n]:[$r,n]},Yr=([e,t])=>e===zr&&(t==="function"||t==="symbol"),th=(e,t,n,r)=>{const i=(s,o)=>{const u=r.push(s)-1;return n.set(o,u),u},a=s=>{if(n.has(s))return n.get(s);let[o,u]=jn(s);switch(o){case zr:{let f=s;switch(u){case"bigint":o=Bo,f=s.toString();break;case"function":case"symbol":if(e)throw new TypeError("unable to serialize "+u);f=null;break;case"undefined":return i([Po],s)}return i([o,f],s)}case Yn:{if(u){let h=s;return u==="DataView"?h=new Uint8Array(s.buffer):u==="ArrayBuffer"&&(h=new Uint8Array(s)),i([u,[...h]],s)}const f=[],d=i([o,f],s);for(const h of s)f.push(a(h));return d}case $r:{if(u)switch(u){case"BigInt":return i([u,s.toString()],s);case"Boolean":case"Number":case"String":return i([u,s.valueOf()],s)}if(t&&"toJSON"in s)return a(s.toJSON());const f=[],d=i([o,f],s);for(const h of eh(s))(e||!Yr(jn(s[h])))&&f.push([a(h),a(s[h])]);return d}case ta:return i([o,s.toISOString()],s);case na:{const{source:f,flags:d}=s;return i([o,{source:f,flags:d}],s)}case ra:{const f=[],d=i([o,f],s);for(const[h,p]of s)(e||!(Yr(jn(h))||Yr(jn(p))))&&f.push([a(h),a(p)]);return d}case ia:{const f=[],d=i([o,f],s);for(const h of s)(e||!Yr(jn(h)))&&f.push(a(h));return d}}const{message:c}=s;return i([o,{name:u,message:c}],s)};return a},Uo=(e,{json:t,lossy:n}={})=>{const r=[];return th(!(t||n),!!t,new Map,r)(e),r},Qt=typeof structuredClone=="function"?(e,t)=>t&&("json"in t||"lossy"in t)?Ho(Uo(e,t)):structuredClone(e):(e,t)=>Ho(Uo(e,t));class Vn{constructor(t,n,r){this.normal=n,this.property=t,r&&(this.space=r)}}Vn.prototype.normal={},Vn.prototype.property={},Vn.prototype.space=void 0;function zo(e,t){const n={},r={};for(const i of e)Object.assign(n,i.property),Object.assign(r,i.normal);return new Vn(n,r,t)}function qn(e){return e.toLowerCase()}class qe{constructor(t,n){this.attribute=n,this.property=t}}qe.prototype.attribute="",qe.prototype.booleanish=!1,qe.prototype.boolean=!1,qe.prototype.commaOrSpaceSeparated=!1,qe.prototype.commaSeparated=!1,qe.prototype.defined=!1,qe.prototype.mustUseProperty=!1,qe.prototype.number=!1,qe.prototype.overloadedBoolean=!1,qe.prototype.property="",qe.prototype.spaceSeparated=!1,qe.prototype.space=void 0;let nh=0;const J=Kt(),Ie=Kt(),aa=Kt(),F=Kt(),Te=Kt(),_n=Kt(),Qe=Kt();function Kt(){return 2**++nh}const sa=Object.freeze(Object.defineProperty({__proto__:null,boolean:J,booleanish:Ie,commaOrSpaceSeparated:Qe,commaSeparated:_n,number:F,overloadedBoolean:aa,spaceSeparated:Te},Symbol.toStringTag,{value:"Module"})),oa=Object.keys(sa);class ua extends qe{constructor(t,n,r,i){let a=-1;if(super(t,n),$o(this,"space",i),typeof r=="number")for(;++a<oa.length;){const s=oa[a];$o(this,oa[a],(r&sa[s])===sa[s])}}}ua.prototype.defined=!0;function $o(e,t,n){n&&(e[t]=n)}function kn(e){const t={},n={};for(const[r,i]of Object.entries(e.properties)){const a=new ua(r,e.transform(e.attributes||{},r),i,e.space);e.mustUseProperty&&e.mustUseProperty.includes(r)&&(a.mustUseProperty=!0),t[r]=a,n[qn(r)]=r,n[qn(a.attribute)]=r}return new Vn(t,n,e.space)}const Yo=kn({properties:{ariaActiveDescendant:null,ariaAtomic:Ie,ariaAutoComplete:null,ariaBusy:Ie,ariaChecked:Ie,ariaColCount:F,ariaColIndex:F,ariaColSpan:F,ariaControls:Te,ariaCurrent:null,ariaDescribedBy:Te,ariaDetails:null,ariaDisabled:Ie,ariaDropEffect:Te,ariaErrorMessage:null,ariaExpanded:Ie,ariaFlowTo:Te,ariaGrabbed:Ie,ariaHasPopup:null,ariaHidden:Ie,ariaInvalid:null,ariaKeyShortcuts:null,ariaLabel:null,ariaLabelledBy:Te,ariaLevel:F,ariaLive:null,ariaModal:Ie,ariaMultiLine:Ie,ariaMultiSelectable:Ie,ariaOrientation:null,ariaOwns:Te,ariaPlaceholder:null,ariaPosInSet:F,ariaPressed:Ie,ariaReadOnly:Ie,ariaRelevant:null,ariaRequired:Ie,ariaRoleDescription:Te,ariaRowCount:F,ariaRowIndex:F,ariaRowSpan:F,ariaSelected:Ie,ariaSetSize:F,ariaSort:null,ariaValueMax:F,ariaValueMin:F,ariaValueNow:F,ariaValueText:null,role:null},transform(e,t){return t==="role"?t:"aria-"+t.slice(4).toLowerCase()}});function jo(e,t){return t in e?e[t]:t}function Vo(e,t){return jo(e,t.toLowerCase())}const rh=kn({attributes:{acceptcharset:"accept-charset",classname:"class",htmlfor:"for",httpequiv:"http-equiv"},mustUseProperty:["checked","multiple","muted","selected"],properties:{abbr:null,accept:_n,acceptCharset:Te,accessKey:Te,action:null,allow:null,allowFullScreen:J,allowPaymentRequest:J,allowUserMedia:J,alt:null,as:null,async:J,autoCapitalize:null,autoComplete:Te,autoFocus:J,autoPlay:J,blocking:Te,capture:null,charSet:null,checked:J,cite:null,className:Te,cols:F,colSpan:null,content:null,contentEditable:Ie,controls:J,controlsList:Te,coords:F|_n,crossOrigin:null,data:null,dateTime:null,decoding:null,default:J,defer:J,dir:null,dirName:null,disabled:J,download:aa,draggable:Ie,encType:null,enterKeyHint:null,fetchPriority:null,form:null,formAction:null,formEncType:null,formMethod:null,formNoValidate:J,formTarget:null,headers:Te,height:F,hidden:aa,high:F,href:null,hrefLang:null,htmlFor:Te,httpEquiv:Te,id:null,imageSizes:null,imageSrcSet:null,inert:J,inputMode:null,integrity:null,is:null,isMap:J,itemId:null,itemProp:Te,itemRef:Te,itemScope:J,itemType:Te,kind:null,label:null,lang:null,language:null,list:null,loading:null,loop:J,low:F,manifest:null,max:null,maxLength:F,media:null,method:null,min:null,minLength:F,multiple:J,muted:J,name:null,nonce:null,noModule:J,noValidate:J,onAbort:null,onAfterPrint:null,onAuxClick:null,onBeforeMatch:null,onBeforePrint:null,onBeforeToggle:null,onBeforeUnload:null,onBlur:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onContextLost:null,onContextMenu:null,onContextRestored:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnded:null,onError:null,onFocus:null,onFormData:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLanguageChange:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadEnd:null,onLoadStart:null,onMessage:null,onMessageError:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRejectionHandled:null,onReset:null,onResize:null,onScroll:null,onScrollEnd:null,onSecurityPolicyViolation:null,onSeeked:null,onSeeking:null,onSelect:null,onSlotChange:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnhandledRejection:null,onUnload:null,onVolumeChange:null,onWaiting:null,onWheel:null,open:J,optimum:F,pattern:null,ping:Te,placeholder:null,playsInline:J,popover:null,popoverTarget:null,popoverTargetAction:null,poster:null,preload:null,readOnly:J,referrerPolicy:null,rel:Te,required:J,reversed:J,rows:F,rowSpan:F,sandbox:Te,scope:null,scoped:J,seamless:J,selected:J,shadowRootClonable:J,shadowRootDelegatesFocus:J,shadowRootMode:null,shape:null,size:F,sizes:null,slot:null,span:F,spellCheck:Ie,src:null,srcDoc:null,srcLang:null,srcSet:null,start:F,step:null,style:null,tabIndex:F,target:null,title:null,translate:null,type:null,typeMustMatch:J,useMap:null,value:Ie,width:F,wrap:null,writingSuggestions:null,align:null,aLink:null,archive:Te,axis:null,background:null,bgColor:null,border:F,borderColor:null,bottomMargin:F,cellPadding:null,cellSpacing:null,char:null,charOff:null,classId:null,clear:null,code:null,codeBase:null,codeType:null,color:null,compact:J,declare:J,event:null,face:null,frame:null,frameBorder:null,hSpace:F,leftMargin:F,link:null,longDesc:null,lowSrc:null,marginHeight:F,marginWidth:F,noResize:J,noHref:J,noShade:J,noWrap:J,object:null,profile:null,prompt:null,rev:null,rightMargin:F,rules:null,scheme:null,scrolling:Ie,standby:null,summary:null,text:null,topMargin:F,valueType:null,version:null,vAlign:null,vLink:null,vSpace:F,allowTransparency:null,autoCorrect:null,autoSave:null,disablePictureInPicture:J,disableRemotePlayback:J,prefix:null,property:null,results:F,security:null,unselectable:null},space:"html",transform:Vo}),ih=kn({attributes:{accentHeight:"accent-height",alignmentBaseline:"alignment-baseline",arabicForm:"arabic-form",baselineShift:"baseline-shift",capHeight:"cap-height",className:"class",clipPath:"clip-path",clipRule:"clip-rule",colorInterpolation:"color-interpolation",colorInterpolationFilters:"color-interpolation-filters",colorProfile:"color-profile",colorRendering:"color-rendering",crossOrigin:"crossorigin",dataType:"datatype",dominantBaseline:"dominant-baseline",enableBackground:"enable-background",fillOpacity:"fill-opacity",fillRule:"fill-rule",floodColor:"flood-color",floodOpacity:"flood-opacity",fontFamily:"font-family",fontSize:"font-size",fontSizeAdjust:"font-size-adjust",fontStretch:"font-stretch",fontStyle:"font-style",fontVariant:"font-variant",fontWeight:"font-weight",glyphName:"glyph-name",glyphOrientationHorizontal:"glyph-orientation-horizontal",glyphOrientationVertical:"glyph-orientation-vertical",hrefLang:"hreflang",horizAdvX:"horiz-adv-x",horizOriginX:"horiz-origin-x",horizOriginY:"horiz-origin-y",imageRendering:"image-rendering",letterSpacing:"letter-spacing",lightingColor:"lighting-color",markerEnd:"marker-end",markerMid:"marker-mid",markerStart:"marker-start",navDown:"nav-down",navDownLeft:"nav-down-left",navDownRight:"nav-down-right",navLeft:"nav-left",navNext:"nav-next",navPrev:"nav-prev",navRight:"nav-right",navUp:"nav-up",navUpLeft:"nav-up-left",navUpRight:"nav-up-right",onAbort:"onabort",onActivate:"onactivate",onAfterPrint:"onafterprint",onBeforePrint:"onbeforeprint",onBegin:"onbegin",onCancel:"oncancel",onCanPlay:"oncanplay",onCanPlayThrough:"oncanplaythrough",onChange:"onchange",onClick:"onclick",onClose:"onclose",onCopy:"oncopy",onCueChange:"oncuechange",onCut:"oncut",onDblClick:"ondblclick",onDrag:"ondrag",onDragEnd:"ondragend",onDragEnter:"ondragenter",onDragExit:"ondragexit",onDragLeave:"ondragleave",onDragOver:"ondragover",onDragStart:"ondragstart",onDrop:"ondrop",onDurationChange:"ondurationchange",onEmptied:"onemptied",onEnd:"onend",onEnded:"onended",onError:"onerror",onFocus:"onfocus",onFocusIn:"onfocusin",onFocusOut:"onfocusout",onHashChange:"onhashchange",onInput:"oninput",onInvalid:"oninvalid",onKeyDown:"onkeydown",onKeyPress:"onkeypress",onKeyUp:"onkeyup",onLoad:"onload",onLoadedData:"onloadeddata",onLoadedMetadata:"onloadedmetadata",onLoadStart:"onloadstart",onMessage:"onmessage",onMouseDown:"onmousedown",onMouseEnter:"onmouseenter",onMouseLeave:"onmouseleave",onMouseMove:"onmousemove",onMouseOut:"onmouseout",onMouseOver:"onmouseover",onMouseUp:"onmouseup",onMouseWheel:"onmousewheel",onOffline:"onoffline",onOnline:"ononline",onPageHide:"onpagehide",onPageShow:"onpageshow",onPaste:"onpaste",onPause:"onpause",onPlay:"onplay",onPlaying:"onplaying",onPopState:"onpopstate",onProgress:"onprogress",onRateChange:"onratechange",onRepeat:"onrepeat",onReset:"onreset",onResize:"onresize",onScroll:"onscroll",onSeeked:"onseeked",onSeeking:"onseeking",onSelect:"onselect",onShow:"onshow",onStalled:"onstalled",onStorage:"onstorage",onSubmit:"onsubmit",onSuspend:"onsuspend",onTimeUpdate:"ontimeupdate",onToggle:"ontoggle",onUnload:"onunload",onVolumeChange:"onvolumechange",onWaiting:"onwaiting",onZoom:"onzoom",overlinePosition:"overline-position",overlineThickness:"overline-thickness",paintOrder:"paint-order",panose1:"panose-1",pointerEvents:"pointer-events",referrerPolicy:"referrerpolicy",renderingIntent:"rendering-intent",shapeRendering:"shape-rendering",stopColor:"stop-color",stopOpacity:"stop-opacity",strikethroughPosition:"strikethrough-position",strikethroughThickness:"strikethrough-thickness",strokeDashArray:"stroke-dasharray",strokeDashOffset:"stroke-dashoffset",strokeLineCap:"stroke-linecap",strokeLineJoin:"stroke-linejoin",strokeMiterLimit:"stroke-miterlimit",strokeOpacity:"stroke-opacity",strokeWidth:"stroke-width",tabIndex:"tabindex",textAnchor:"text-anchor",textDecoration:"text-decoration",textRendering:"text-rendering",transformOrigin:"transform-origin",typeOf:"typeof",underlinePosition:"underline-position",underlineThickness:"underline-thickness",unicodeBidi:"unicode-bidi",unicodeRange:"unicode-range",unitsPerEm:"units-per-em",vAlphabetic:"v-alphabetic",vHanging:"v-hanging",vIdeographic:"v-ideographic",vMathematical:"v-mathematical",vectorEffect:"vector-effect",vertAdvY:"vert-adv-y",vertOriginX:"vert-origin-x",vertOriginY:"vert-origin-y",wordSpacing:"word-spacing",writingMode:"writing-mode",xHeight:"x-height",playbackOrder:"playbackorder",timelineBegin:"timelinebegin"},properties:{about:Qe,accentHeight:F,accumulate:null,additive:null,alignmentBaseline:null,alphabetic:F,amplitude:F,arabicForm:null,ascent:F,attributeName:null,attributeType:null,azimuth:F,bandwidth:null,baselineShift:null,baseFrequency:null,baseProfile:null,bbox:null,begin:null,bias:F,by:null,calcMode:null,capHeight:F,className:Te,clip:null,clipPath:null,clipPathUnits:null,clipRule:null,color:null,colorInterpolation:null,colorInterpolationFilters:null,colorProfile:null,colorRendering:null,content:null,contentScriptType:null,contentStyleType:null,crossOrigin:null,cursor:null,cx:null,cy:null,d:null,dataType:null,defaultAction:null,descent:F,diffuseConstant:F,direction:null,display:null,dur:null,divisor:F,dominantBaseline:null,download:J,dx:null,dy:null,edgeMode:null,editable:null,elevation:F,enableBackground:null,end:null,event:null,exponent:F,externalResourcesRequired:null,fill:null,fillOpacity:F,fillRule:null,filter:null,filterRes:null,filterUnits:null,floodColor:null,floodOpacity:null,focusable:null,focusHighlight:null,fontFamily:null,fontSize:null,fontSizeAdjust:null,fontStretch:null,fontStyle:null,fontVariant:null,fontWeight:null,format:null,fr:null,from:null,fx:null,fy:null,g1:_n,g2:_n,glyphName:_n,glyphOrientationHorizontal:null,glyphOrientationVertical:null,glyphRef:null,gradientTransform:null,gradientUnits:null,handler:null,hanging:F,hatchContentUnits:null,hatchUnits:null,height:null,href:null,hrefLang:null,horizAdvX:F,horizOriginX:F,horizOriginY:F,id:null,ideographic:F,imageRendering:null,initialVisibility:null,in:null,in2:null,intercept:F,k:F,k1:F,k2:F,k3:F,k4:F,kernelMatrix:Qe,kernelUnitLength:null,keyPoints:null,keySplines:null,keyTimes:null,kerning:null,lang:null,lengthAdjust:null,letterSpacing:null,lightingColor:null,limitingConeAngle:F,local:null,markerEnd:null,markerMid:null,markerStart:null,markerHeight:null,markerUnits:null,markerWidth:null,mask:null,maskContentUnits:null,maskUnits:null,mathematical:null,max:null,media:null,mediaCharacterEncoding:null,mediaContentEncodings:null,mediaSize:F,mediaTime:null,method:null,min:null,mode:null,name:null,navDown:null,navDownLeft:null,navDownRight:null,navLeft:null,navNext:null,navPrev:null,navRight:null,navUp:null,navUpLeft:null,navUpRight:null,numOctaves:null,observer:null,offset:null,onAbort:null,onActivate:null,onAfterPrint:null,onBeforePrint:null,onBegin:null,onCancel:null,onCanPlay:null,onCanPlayThrough:null,onChange:null,onClick:null,onClose:null,onCopy:null,onCueChange:null,onCut:null,onDblClick:null,onDrag:null,onDragEnd:null,onDragEnter:null,onDragExit:null,onDragLeave:null,onDragOver:null,onDragStart:null,onDrop:null,onDurationChange:null,onEmptied:null,onEnd:null,onEnded:null,onError:null,onFocus:null,onFocusIn:null,onFocusOut:null,onHashChange:null,onInput:null,onInvalid:null,onKeyDown:null,onKeyPress:null,onKeyUp:null,onLoad:null,onLoadedData:null,onLoadedMetadata:null,onLoadStart:null,onMessage:null,onMouseDown:null,onMouseEnter:null,onMouseLeave:null,onMouseMove:null,onMouseOut:null,onMouseOver:null,onMouseUp:null,onMouseWheel:null,onOffline:null,onOnline:null,onPageHide:null,onPageShow:null,onPaste:null,onPause:null,onPlay:null,onPlaying:null,onPopState:null,onProgress:null,onRateChange:null,onRepeat:null,onReset:null,onResize:null,onScroll:null,onSeeked:null,onSeeking:null,onSelect:null,onShow:null,onStalled:null,onStorage:null,onSubmit:null,onSuspend:null,onTimeUpdate:null,onToggle:null,onUnload:null,onVolumeChange:null,onWaiting:null,onZoom:null,opacity:null,operator:null,order:null,orient:null,orientation:null,origin:null,overflow:null,overlay:null,overlinePosition:F,overlineThickness:F,paintOrder:null,panose1:null,path:null,pathLength:F,patternContentUnits:null,patternTransform:null,patternUnits:null,phase:null,ping:Te,pitch:null,playbackOrder:null,pointerEvents:null,points:null,pointsAtX:F,pointsAtY:F,pointsAtZ:F,preserveAlpha:null,preserveAspectRatio:null,primitiveUnits:null,propagate:null,property:Qe,r:null,radius:null,referrerPolicy:null,refX:null,refY:null,rel:Qe,rev:Qe,renderingIntent:null,repeatCount:null,repeatDur:null,requiredExtensions:Qe,requiredFeatures:Qe,requiredFonts:Qe,requiredFormats:Qe,resource:null,restart:null,result:null,rotate:null,rx:null,ry:null,scale:null,seed:null,shapeRendering:null,side:null,slope:null,snapshotTime:null,specularConstant:F,specularExponent:F,spreadMethod:null,spacing:null,startOffset:null,stdDeviation:null,stemh:null,stemv:null,stitchTiles:null,stopColor:null,stopOpacity:null,strikethroughPosition:F,strikethroughThickness:F,string:null,stroke:null,strokeDashArray:Qe,strokeDashOffset:null,strokeLineCap:null,strokeLineJoin:null,strokeMiterLimit:F,strokeOpacity:F,strokeWidth:null,style:null,surfaceScale:F,syncBehavior:null,syncBehaviorDefault:null,syncMaster:null,syncTolerance:null,syncToleranceDefault:null,systemLanguage:Qe,tabIndex:F,tableValues:null,target:null,targetX:F,targetY:F,textAnchor:null,textDecoration:null,textRendering:null,textLength:null,timelineBegin:null,title:null,transformBehavior:null,type:null,typeOf:Qe,to:null,transform:null,transformOrigin:null,u1:null,u2:null,underlinePosition:F,underlineThickness:F,unicode:null,unicodeBidi:null,unicodeRange:null,unitsPerEm:F,values:null,vAlphabetic:F,vMathematical:F,vectorEffect:null,vHanging:F,vIdeographic:F,version:null,vertAdvY:F,vertOriginX:F,vertOriginY:F,viewBox:null,viewTarget:null,visibility:null,width:null,widths:null,wordSpacing:null,writingMode:null,x:null,x1:null,x2:null,xChannelSelector:null,xHeight:F,y:null,y1:null,y2:null,yChannelSelector:null,z:null,zoomAndPan:null},space:"svg",transform:jo}),qo=kn({properties:{xLinkActuate:null,xLinkArcRole:null,xLinkHref:null,xLinkRole:null,xLinkShow:null,xLinkTitle:null,xLinkType:null},space:"xlink",transform(e,t){return"xlink:"+t.slice(5).toLowerCase()}}),Wo=kn({attributes:{xmlnsxlink:"xmlns:xlink"},properties:{xmlnsXLink:null,xmlns:null},space:"xmlns",transform:Vo}),Go=kn({properties:{xmlBase:null,xmlLang:null,xmlSpace:null},space:"xml",transform(e,t){return"xml:"+t.slice(3).toLowerCase()}}),ah={classId:"classID",dataType:"datatype",itemId:"itemID",strokeDashArray:"strokeDasharray",strokeDashOffset:"strokeDashoffset",strokeLineCap:"strokeLinecap",strokeLineJoin:"strokeLinejoin",strokeMiterLimit:"strokeMiterlimit",typeOf:"typeof",xLinkActuate:"xlinkActuate",xLinkArcRole:"xlinkArcrole",xLinkHref:"xlinkHref",xLinkRole:"xlinkRole",xLinkShow:"xlinkShow",xLinkTitle:"xlinkTitle",xLinkType:"xlinkType",xmlnsXLink:"xmlnsXlink"},sh=/[A-Z]/g,Qo=/-[a-z]/g,oh=/^data[-\w.:]+$/i;function jr(e,t){const n=qn(t);let r=t,i=qe;if(n in e.normal)return e.property[e.normal[n]];if(n.length>4&&n.slice(0,4)==="data"&&oh.test(t)){if(t.charAt(4)==="-"){const a=t.slice(5).replace(Qo,lh);r="data"+a.charAt(0).toUpperCase()+a.slice(1)}else{const a=t.slice(4);if(!Qo.test(a)){let s=a.replace(sh,uh);s.charAt(0)!=="-"&&(s="-"+s),t="data"+s}}i=ua}return new i(r,t)}function uh(e){return"-"+e.toLowerCase()}function lh(e){return e.charAt(1).toUpperCase()}const Wn=zo([Yo,rh,qo,Wo,Go],"html"),vt=zo([Yo,ih,qo,Wo,Go],"svg");function Ko(e){const t=[],n=String(e||"");let r=n.indexOf(","),i=0,a=!1;for(;!a;){r===-1&&(r=n.length,a=!0);const s=n.slice(i,r).trim();(s||!a)&&t.push(s),i=r+1,r=n.indexOf(",",i)}return t}function Xo(e,t){const n=t||{};return(e[e.length-1]===""?[...e,""]:e).join((n.padRight?" ":"")+","+(n.padLeft===!1?"":" ")).trim()}const Zo=/[#.]/g;function ch(e,t){const n=e||"",r={};let i=0,a,s;for(;i<n.length;){Zo.lastIndex=i;const o=Zo.exec(n),u=n.slice(i,o?o.index:n.length);u&&(a?a==="#"?r.id=u:Array.isArray(r.className)?r.className.push(u):r.className=[u]:s=u,i+=u.length),o&&(a=o[0],i++)}return{type:"element",tagName:s||t||"div",properties:r,children:[]}}function Jo(e){const t=String(e||"").trim();return t?t.split(/[ \t\n\r\f]+/g):[]}function eu(e){return e.join(" ").trim()}function tu(e,t,n){const r=n?ph(n):void 0;function i(a,s,...o){let u;if(a==null){u={type:"root",children:[]};const c=s;o.unshift(c)}else{u=ch(a,t);const c=u.tagName.toLowerCase(),f=r?r.get(c):void 0;if(u.tagName=f||c,dh(s))o.unshift(s);else for(const[d,h]of Object.entries(s))fh(e,u.properties,d,h)}for(const c of o)la(u.children,c);return u.type==="element"&&u.tagName==="template"&&(u.content={type:"root",children:u.children},u.children=[]),u}return i}function dh(e){if(e===null||typeof e!="object"||Array.isArray(e))return!0;if(typeof e.type!="string")return!1;const t=e,n=Object.keys(e);for(const r of n){const i=t[r];if(i&&typeof i=="object"){if(!Array.isArray(i))return!0;const a=i;for(const s of a)if(typeof s!="number"&&typeof s!="string")return!0}}return!!("children"in e&&Array.isArray(e.children))}function fh(e,t,n,r){const i=jr(e,n);let a;if(r!=null){if(typeof r=="number"){if(Number.isNaN(r))return;a=r}else typeof r=="boolean"?a=r:typeof r=="string"?i.spaceSeparated?a=Jo(r):i.commaSeparated?a=Ko(r):i.commaOrSpaceSeparated?a=Jo(Ko(r).join(" ")):a=nu(i,i.property,r):Array.isArray(r)?a=[...r]:a=i.property==="style"?hh(r):String(r);if(Array.isArray(a)){const s=[];for(const o of a)s.push(nu(i,i.property,o));a=s}i.property==="className"&&Array.isArray(t.className)&&(a=t.className.concat(a)),t[i.property]=a}}function la(e,t){if(t!=null)if(typeof t=="number"||typeof t=="string")e.push({type:"text",value:String(t)});else if(Array.isArray(t))for(const n of t)la(e,n);else if(typeof t=="object"&&"type"in t)t.type==="root"?la(e,t.children):e.push(t);else throw new Error("Expected node, nodes, or string, got `"+t+"`")}function nu(e,t,n){if(typeof n=="string"){if(e.number&&n&&!Number.isNaN(Number(n)))return Number(n);if((e.boolean||e.overloadedBoolean)&&(n===""||qn(n)===qn(t)))return!0}return n}function hh(e){const t=[];for(const[n,r]of Object.entries(e))t.push([n,r].join(": "));return t.join("; ")}function ph(e){const t=new Map;for(const n of e)t.set(n.toLowerCase(),n);return t}const mh=["altGlyph","altGlyphDef","altGlyphItem","animateColor","animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feDropShadow","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","glyphRef","linearGradient","radialGradient","solidColor","textArea","textPath"],gh=tu(Wn,"div"),bh=tu(vt,"g",mh);function Eh(e){const t=String(e),n=[];return{toOffset:i,toPoint:r};function r(a){if(typeof a=="number"&&a>-1&&a<=t.length){let s=0;for(;;){let o=n[s];if(o===void 0){const u=ru(t,n[s-1]);o=u===-1?t.length+1:u+1,n[s]=o}if(o>a)return{line:s+1,column:a-(s>0?n[s-1]:0)+1,offset:a};s++}}}function i(a){if(a&&typeof a.line=="number"&&typeof a.column=="number"&&!Number.isNaN(a.line)&&!Number.isNaN(a.column)){for(;n.length<a.line;){const o=n[n.length-1],u=ru(t,o),c=u===-1?t.length+1:u+1;if(o===c)break;n.push(c)}const s=(a.line>1?n[a.line-2]:0)+a.column-1;if(s<n[a.line-1])return s}}}function ru(e,t){const n=e.indexOf("\r",t),r=e.indexOf(`
|
|
2
|
+
`,t);return r===-1?n:n===-1||n+1===r?r:n<r?n:r}const Xt={html:"http://www.w3.org/1999/xhtml",mathml:"http://www.w3.org/1998/Math/MathML",svg:"http://www.w3.org/2000/svg",xlink:"http://www.w3.org/1999/xlink",xml:"http://www.w3.org/XML/1998/namespace",xmlns:"http://www.w3.org/2000/xmlns/"},iu={}.hasOwnProperty,Th=Object.prototype;function _h(e,t){const n=t||{};return ca({file:n.file||void 0,location:!1,schema:n.space==="svg"?vt:Wn,verbose:n.verbose||!1},e)}function ca(e,t){let n;switch(t.nodeName){case"#comment":{const r=t;return n={type:"comment",value:r.data},Vr(e,r,n),n}case"#document":case"#document-fragment":{const r=t,i="mode"in r?r.mode==="quirks"||r.mode==="limited-quirks":!1;if(n={type:"root",children:au(e,t.childNodes),data:{quirksMode:i}},e.file&&e.location){const a=String(e.file),s=Eh(a),o=s.toPoint(0),u=s.toPoint(a.length);n.position={start:o,end:u}}return n}case"#documentType":{const r=t;return n={type:"doctype"},Vr(e,r,n),n}case"#text":{const r=t;return n={type:"text",value:r.value},Vr(e,r,n),n}default:return n=kh(e,t),n}}function au(e,t){let n=-1;const r=[];for(;++n<t.length;){const i=ca(e,t[n]);r.push(i)}return r}function kh(e,t){const n=e.schema;e.schema=t.namespaceURI===Xt.svg?vt:Wn;let r=-1;const i={};for(;++r<t.attrs.length;){const o=t.attrs[r],u=(o.prefix?o.prefix+":":"")+o.name;iu.call(Th,u)||(i[u]=o.value)}const s=(e.schema.space==="svg"?bh:gh)(t.tagName,i,au(e,t.childNodes));if(Vr(e,t,s),s.tagName==="template"){const o=t,u=o.sourceCodeLocation,c=u&&u.startTag&&xn(u.startTag),f=u&&u.endTag&&xn(u.endTag),d=ca(e,o.content);c&&f&&e.file&&(d.position={start:c.end,end:f.start}),s.content=d}return e.schema=n,s}function Vr(e,t,n){if("sourceCodeLocation"in t&&t.sourceCodeLocation&&e.file){const r=xh(e,n,t.sourceCodeLocation);r&&(e.location=!0,n.position=r)}}function xh(e,t,n){const r=xn(n);if(t.type==="element"){const i=t.children[t.children.length-1];if(r&&!n.endTag&&i&&i.position&&i.position.end&&(r.end=Object.assign({},i.position.end)),e.verbose){const a={};let s;if(n.attrs)for(s in n.attrs)iu.call(n.attrs,s)&&(a[jr(e.schema,s).property]=xn(n.attrs[s]));const o=xn(n.startTag),u=n.endTag?xn(n.endTag):void 0,c={opening:o};u&&(c.closing=u),c.properties=a,t.data={position:c}}}return r}function xn(e){const t=su({line:e.startLine,column:e.startCol,offset:e.startOffset}),n=su({line:e.endLine,column:e.endCol,offset:e.endOffset});return t||n?{start:t,end:n}:void 0}function su(e){return e.line&&e.column?e:void 0}const ou={}.hasOwnProperty;function uu(e,t){const n=t||{};function r(i,...a){let s=r.invalid;const o=r.handlers;if(i&&ou.call(i,e)){const u=String(i[e]);s=ou.call(o,u)?o[u]:r.unknown}if(s)return s.call(this,i,...a)}return r.handlers=n.handlers||{},r.invalid=n.invalid,r.unknown=n.unknown,r}const yh={},wh={}.hasOwnProperty,lu=uu("type",{handlers:{root:Ch,element:Lh,text:Ih,comment:vh,doctype:Nh}});function Ah(e,t){const r=(t||yh).space;return lu(e,r==="svg"?vt:Wn)}function Ch(e,t){const n={nodeName:"#document",mode:(e.data||{}).quirksMode?"quirks":"no-quirks",childNodes:[]};return n.childNodes=da(e.children,n,t),yn(e,n),n}function Sh(e,t){const n={nodeName:"#document-fragment",childNodes:[]};return n.childNodes=da(e.children,n,t),yn(e,n),n}function Nh(e){const t={nodeName:"#documentType",name:"html",publicId:"",systemId:"",parentNode:null};return yn(e,t),t}function Ih(e){const t={nodeName:"#text",value:e.value,parentNode:null};return yn(e,t),t}function vh(e){const t={nodeName:"#comment",data:e.value,parentNode:null};return yn(e,t),t}function Lh(e,t){const n=t;let r=n;e.type==="element"&&e.tagName.toLowerCase()==="svg"&&n.space==="html"&&(r=vt);const i=[];let a;if(e.properties){for(a in e.properties)if(a!=="children"&&wh.call(e.properties,a)){const u=Rh(r,a,e.properties[a]);u&&i.push(u)}}const s=r.space,o={nodeName:e.tagName,tagName:e.tagName,attrs:i,namespaceURI:Xt[s],childNodes:[],parentNode:null};return o.childNodes=da(e.children,o,r),yn(e,o),e.tagName==="template"&&e.content&&(o.content=Sh(e.content,r)),o}function Rh(e,t,n){const r=jr(e,t);if(n===!1||n===null||n===void 0||typeof n=="number"&&Number.isNaN(n)||!n&&r.boolean)return;Array.isArray(n)&&(n=r.commaSeparated?Xo(n):eu(n));const i={name:r.attribute,value:n===!0?"":String(n)};if(r.space&&r.space!=="html"&&r.space!=="svg"){const a=i.name.indexOf(":");a<0?i.prefix="":(i.name=i.name.slice(a+1),i.prefix=r.attribute.slice(0,a)),i.namespace=Xt[r.space]}return i}function da(e,t,n){let r=-1;const i=[];if(e)for(;++r<e.length;){const a=lu(e[r],n);a.parentNode=t,i.push(a)}return i}function yn(e,t){const n=e.position;n&&n.start&&n.end&&(t.sourceCodeLocation={startLine:n.start.line,startCol:n.start.column,startOffset:n.start.offset,endLine:n.end.line,endCol:n.end.column,endOffset:n.end.offset})}const Oh=["area","base","basefont","bgsound","br","col","command","embed","frame","hr","image","img","input","keygen","link","meta","param","source","track","wbr"],Dh=new Set([65534,65535,131070,131071,196606,196607,262142,262143,327678,327679,393214,393215,458750,458751,524286,524287,589822,589823,655358,655359,720894,720895,786430,786431,851966,851967,917502,917503,983038,983039,1048574,1048575,1114110,1114111]),ke="�";var g;(function(e){e[e.EOF=-1]="EOF",e[e.NULL=0]="NULL",e[e.TABULATION=9]="TABULATION",e[e.CARRIAGE_RETURN=13]="CARRIAGE_RETURN",e[e.LINE_FEED=10]="LINE_FEED",e[e.FORM_FEED=12]="FORM_FEED",e[e.SPACE=32]="SPACE",e[e.EXCLAMATION_MARK=33]="EXCLAMATION_MARK",e[e.QUOTATION_MARK=34]="QUOTATION_MARK",e[e.AMPERSAND=38]="AMPERSAND",e[e.APOSTROPHE=39]="APOSTROPHE",e[e.HYPHEN_MINUS=45]="HYPHEN_MINUS",e[e.SOLIDUS=47]="SOLIDUS",e[e.DIGIT_0=48]="DIGIT_0",e[e.DIGIT_9=57]="DIGIT_9",e[e.SEMICOLON=59]="SEMICOLON",e[e.LESS_THAN_SIGN=60]="LESS_THAN_SIGN",e[e.EQUALS_SIGN=61]="EQUALS_SIGN",e[e.GREATER_THAN_SIGN=62]="GREATER_THAN_SIGN",e[e.QUESTION_MARK=63]="QUESTION_MARK",e[e.LATIN_CAPITAL_A=65]="LATIN_CAPITAL_A",e[e.LATIN_CAPITAL_Z=90]="LATIN_CAPITAL_Z",e[e.RIGHT_SQUARE_BRACKET=93]="RIGHT_SQUARE_BRACKET",e[e.GRAVE_ACCENT=96]="GRAVE_ACCENT",e[e.LATIN_SMALL_A=97]="LATIN_SMALL_A",e[e.LATIN_SMALL_Z=122]="LATIN_SMALL_Z"})(g||(g={}));const We={DASH_DASH:"--",CDATA_START:"[CDATA[",DOCTYPE:"doctype",SCRIPT:"script",PUBLIC:"public",SYSTEM:"system"};function cu(e){return e>=55296&&e<=57343}function Ph(e){return e>=56320&&e<=57343}function Mh(e,t){return(e-55296)*1024+9216+t}function du(e){return e!==32&&e!==10&&e!==13&&e!==9&&e!==12&&e>=1&&e<=31||e>=127&&e<=159}function fu(e){return e>=64976&&e<=65007||Dh.has(e)}var L;(function(e){e.controlCharacterInInputStream="control-character-in-input-stream",e.noncharacterInInputStream="noncharacter-in-input-stream",e.surrogateInInputStream="surrogate-in-input-stream",e.nonVoidHtmlElementStartTagWithTrailingSolidus="non-void-html-element-start-tag-with-trailing-solidus",e.endTagWithAttributes="end-tag-with-attributes",e.endTagWithTrailingSolidus="end-tag-with-trailing-solidus",e.unexpectedSolidusInTag="unexpected-solidus-in-tag",e.unexpectedNullCharacter="unexpected-null-character",e.unexpectedQuestionMarkInsteadOfTagName="unexpected-question-mark-instead-of-tag-name",e.invalidFirstCharacterOfTagName="invalid-first-character-of-tag-name",e.unexpectedEqualsSignBeforeAttributeName="unexpected-equals-sign-before-attribute-name",e.missingEndTagName="missing-end-tag-name",e.unexpectedCharacterInAttributeName="unexpected-character-in-attribute-name",e.unknownNamedCharacterReference="unknown-named-character-reference",e.missingSemicolonAfterCharacterReference="missing-semicolon-after-character-reference",e.unexpectedCharacterAfterDoctypeSystemIdentifier="unexpected-character-after-doctype-system-identifier",e.unexpectedCharacterInUnquotedAttributeValue="unexpected-character-in-unquoted-attribute-value",e.eofBeforeTagName="eof-before-tag-name",e.eofInTag="eof-in-tag",e.missingAttributeValue="missing-attribute-value",e.missingWhitespaceBetweenAttributes="missing-whitespace-between-attributes",e.missingWhitespaceAfterDoctypePublicKeyword="missing-whitespace-after-doctype-public-keyword",e.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers="missing-whitespace-between-doctype-public-and-system-identifiers",e.missingWhitespaceAfterDoctypeSystemKeyword="missing-whitespace-after-doctype-system-keyword",e.missingQuoteBeforeDoctypePublicIdentifier="missing-quote-before-doctype-public-identifier",e.missingQuoteBeforeDoctypeSystemIdentifier="missing-quote-before-doctype-system-identifier",e.missingDoctypePublicIdentifier="missing-doctype-public-identifier",e.missingDoctypeSystemIdentifier="missing-doctype-system-identifier",e.abruptDoctypePublicIdentifier="abrupt-doctype-public-identifier",e.abruptDoctypeSystemIdentifier="abrupt-doctype-system-identifier",e.cdataInHtmlContent="cdata-in-html-content",e.incorrectlyOpenedComment="incorrectly-opened-comment",e.eofInScriptHtmlCommentLikeText="eof-in-script-html-comment-like-text",e.eofInDoctype="eof-in-doctype",e.nestedComment="nested-comment",e.abruptClosingOfEmptyComment="abrupt-closing-of-empty-comment",e.eofInComment="eof-in-comment",e.incorrectlyClosedComment="incorrectly-closed-comment",e.eofInCdata="eof-in-cdata",e.absenceOfDigitsInNumericCharacterReference="absence-of-digits-in-numeric-character-reference",e.nullCharacterReference="null-character-reference",e.surrogateCharacterReference="surrogate-character-reference",e.characterReferenceOutsideUnicodeRange="character-reference-outside-unicode-range",e.controlCharacterReference="control-character-reference",e.noncharacterCharacterReference="noncharacter-character-reference",e.missingWhitespaceBeforeDoctypeName="missing-whitespace-before-doctype-name",e.missingDoctypeName="missing-doctype-name",e.invalidCharacterSequenceAfterDoctypeName="invalid-character-sequence-after-doctype-name",e.duplicateAttribute="duplicate-attribute",e.nonConformingDoctype="non-conforming-doctype",e.missingDoctype="missing-doctype",e.misplacedDoctype="misplaced-doctype",e.endTagWithoutMatchingOpenElement="end-tag-without-matching-open-element",e.closingOfElementWithOpenChildElements="closing-of-element-with-open-child-elements",e.disallowedContentInNoscriptInHead="disallowed-content-in-noscript-in-head",e.openElementsLeftAfterEof="open-elements-left-after-eof",e.abandonedHeadElementChild="abandoned-head-element-child",e.misplacedStartTagForHeadElement="misplaced-start-tag-for-head-element",e.nestedNoscriptInHead="nested-noscript-in-head",e.eofInElementThatCanContainOnlyText="eof-in-element-that-can-contain-only-text"})(L||(L={}));const Bh=65536;class Fh{constructor(t){this.handler=t,this.html="",this.pos=-1,this.lastGapPos=-2,this.gapStack=[],this.skipNextNewLine=!1,this.lastChunkWritten=!1,this.endOfChunkHit=!1,this.bufferWaterline=Bh,this.isEol=!1,this.lineStartPos=0,this.droppedBufferSize=0,this.line=1,this.lastErrOffset=-1}get col(){return this.pos-this.lineStartPos+ +(this.lastGapPos!==this.pos)}get offset(){return this.droppedBufferSize+this.pos}getError(t,n){const{line:r,col:i,offset:a}=this,s=i+n,o=a+n;return{code:t,startLine:r,endLine:r,startCol:s,endCol:s,startOffset:o,endOffset:o}}_err(t){this.handler.onParseError&&this.lastErrOffset!==this.offset&&(this.lastErrOffset=this.offset,this.handler.onParseError(this.getError(t,0)))}_addGap(){this.gapStack.push(this.lastGapPos),this.lastGapPos=this.pos}_processSurrogate(t){if(this.pos!==this.html.length-1){const n=this.html.charCodeAt(this.pos+1);if(Ph(n))return this.pos++,this._addGap(),Mh(t,n)}else if(!this.lastChunkWritten)return this.endOfChunkHit=!0,g.EOF;return this._err(L.surrogateInInputStream),t}willDropParsedChunk(){return this.pos>this.bufferWaterline}dropParsedChunk(){this.willDropParsedChunk()&&(this.html=this.html.substring(this.pos),this.lineStartPos-=this.pos,this.droppedBufferSize+=this.pos,this.pos=0,this.lastGapPos=-2,this.gapStack.length=0)}write(t,n){this.html.length>0?this.html+=t:this.html=t,this.endOfChunkHit=!1,this.lastChunkWritten=n}insertHtmlAtCurrentPos(t){this.html=this.html.substring(0,this.pos+1)+t+this.html.substring(this.pos+1),this.endOfChunkHit=!1}startsWith(t,n){if(this.pos+t.length>this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,!1;if(n)return this.html.startsWith(t,this.pos);for(let r=0;r<t.length;r++)if((this.html.charCodeAt(this.pos+r)|32)!==t.charCodeAt(r))return!1;return!0}peek(t){const n=this.pos+t;if(n>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,g.EOF;const r=this.html.charCodeAt(n);return r===g.CARRIAGE_RETURN?g.LINE_FEED:r}advance(){if(this.pos++,this.isEol&&(this.isEol=!1,this.line++,this.lineStartPos=this.pos),this.pos>=this.html.length)return this.endOfChunkHit=!this.lastChunkWritten,g.EOF;let t=this.html.charCodeAt(this.pos);return t===g.CARRIAGE_RETURN?(this.isEol=!0,this.skipNextNewLine=!0,g.LINE_FEED):t===g.LINE_FEED&&(this.isEol=!0,this.skipNextNewLine)?(this.line--,this.skipNextNewLine=!1,this._addGap(),this.advance()):(this.skipNextNewLine=!1,cu(t)&&(t=this._processSurrogate(t)),this.handler.onParseError===null||t>31&&t<127||t===g.LINE_FEED||t===g.CARRIAGE_RETURN||t>159&&t<64976||this._checkForProblematicCharacters(t),t)}_checkForProblematicCharacters(t){du(t)?this._err(L.controlCharacterInInputStream):fu(t)&&this._err(L.noncharacterInInputStream)}retreat(t){for(this.pos-=t;this.pos<this.lastGapPos;)this.lastGapPos=this.gapStack.pop(),this.pos--;this.isEol=!1}}var te;(function(e){e[e.CHARACTER=0]="CHARACTER",e[e.NULL_CHARACTER=1]="NULL_CHARACTER",e[e.WHITESPACE_CHARACTER=2]="WHITESPACE_CHARACTER",e[e.START_TAG=3]="START_TAG",e[e.END_TAG=4]="END_TAG",e[e.COMMENT=5]="COMMENT",e[e.DOCTYPE=6]="DOCTYPE",e[e.EOF=7]="EOF",e[e.HIBERNATION=8]="HIBERNATION"})(te||(te={}));function hu(e,t){for(let n=e.attrs.length-1;n>=0;n--)if(e.attrs[n].name===t)return e.attrs[n].value;return null}const Hh=new Uint16Array('ᵁ<Õıʊҝջאٵ۞ޢߖࠏઑඡ༉༦ረዡᐕᒝᓃᓟᔥ\0\0\0\0\0\0ᕫᛍᦍᰒᷝ↰⊍⏀⏻⑂⠤⤒ⴈ⹈⿎〖㊺㘹㞬㣾㨨㩱㫠㬮ࠀEMabcfglmnoprstu\\bfms¦³¹ÈÏlig耻Æ䃆P耻&䀦cute耻Á䃁reve;䄂Āiyx}rc耻Â䃂;䐐r;쀀𝔄rave耻À䃀pha;䎑acr;䄀d;橓Āgp¡on;䄄f;쀀𝔸plyFunction;恡ing耻Å䃅Ācs¾Ãr;쀀𝒜ign;扔ilde耻Ã䃃ml耻Ä䃄ЀaceforsuåûþėĜĢħĪĀcrêòkslash;或Ŷöø;櫧ed;挆y;䐑ƀcrtąċĔause;戵noullis;愬a;䎒r;쀀𝔅pf;쀀𝔹eve;䋘còēmpeq;扎܀HOacdefhilorsuōőŖƀƞƢƵƷƺǜȕɳɸɾcy;䐧PY耻©䂩ƀcpyŝŢźute;䄆Ā;iŧŨ拒talDifferentialD;慅leys;愭ȀaeioƉƎƔƘron;䄌dil耻Ç䃇rc;䄈nint;戰ot;䄊ĀdnƧƭilla;䂸terDot;䂷òſi;䎧rcleȀDMPTLJNjǑǖot;抙inus;抖lus;投imes;抗oĀcsǢǸkwiseContourIntegral;戲eCurlyĀDQȃȏoubleQuote;思uote;怙ȀlnpuȞȨɇɕonĀ;eȥȦ户;橴ƀgitȯȶȺruent;扡nt;戯ourIntegral;戮ĀfrɌɎ;愂oduct;成nterClockwiseContourIntegral;戳oss;樯cr;쀀𝒞pĀ;Cʄʅ拓ap;才րDJSZacefiosʠʬʰʴʸˋ˗ˡ˦̳ҍĀ;oŹʥtrahd;椑cy;䐂cy;䐅cy;䐏ƀgrsʿ˄ˇger;怡r;憡hv;櫤Āayː˕ron;䄎;䐔lĀ;t˝˞戇a;䎔r;쀀𝔇Āaf˫̧Ācm˰̢riticalȀADGT̖̜̀̆cute;䂴oŴ̋̍;䋙bleAcute;䋝rave;䁠ilde;䋜ond;拄ferentialD;慆Ѱ̽\0\0\0͔͂\0Ѕf;쀀𝔻ƀ;DE͈͉͍䂨ot;惜qual;扐blèCDLRUVͣͲϏϢϸontourIntegraìȹoɴ\0\0ͻ»͉nArrow;懓Āeo·ΤftƀARTΐΖΡrrow;懐ightArrow;懔eåˊngĀLRΫτeftĀARγιrrow;柸ightArrow;柺ightArrow;柹ightĀATϘϞrrow;懒ee;抨pɁϩ\0\0ϯrrow;懑ownArrow;懕erticalBar;戥ǹABLRTaВЪаўѿͼrrowƀ;BUНОТ憓ar;椓pArrow;懵reve;䌑eft˒к\0ц\0ѐightVector;楐eeVector;楞ectorĀ;Bљњ憽ar;楖ightǔѧ\0ѱeeVector;楟ectorĀ;BѺѻ懁ar;楗eeĀ;A҆҇护rrow;憧ĀctҒҗr;쀀𝒟rok;䄐ࠀNTacdfglmopqstuxҽӀӄӋӞӢӧӮӵԡԯԶՒ՝ՠեG;䅊H耻Ð䃐cute耻É䃉ƀaiyӒӗӜron;䄚rc耻Ê䃊;䐭ot;䄖r;쀀𝔈rave耻È䃈ement;戈ĀapӺӾcr;䄒tyɓԆ\0\0ԒmallSquare;旻erySmallSquare;斫ĀgpԦԪon;䄘f;쀀𝔼silon;䎕uĀaiԼՉlĀ;TՂՃ橵ilde;扂librium;懌Āci՚r;愰m;橳a;䎗ml耻Ë䃋Āipժկsts;戃onentialE;慇ʀcfiosօֈ֍ֲy;䐤r;쀀𝔉lledɓ֗\0\0֣mallSquare;旼erySmallSquare;斪Ͱֺ\0ֿ\0\0ׄf;쀀𝔽All;戀riertrf;愱còJTabcdfgorstרׯؒؖ؛؝أ٬ٲcy;䐃耻>䀾mmaĀ;d䎓;䏜reve;䄞ƀeiy؇،ؐdil;䄢rc;䄜;䐓ot;䄠r;쀀𝔊;拙pf;쀀𝔾eater̀EFGLSTصلَٖٛ٦qualĀ;Lؾؿ扥ess;招ullEqual;执reater;檢ess;扷lantEqual;橾ilde;扳cr;쀀𝒢;扫ЀAacfiosuڅڋږڛڞڪھۊRDcy;䐪Āctڐڔek;䋇;䁞irc;䄤r;愌lbertSpace;愋ǰگ\0ڲf;愍izontalLine;攀Āctۃۅòکrok;䄦mpńېۘownHumðįqual;扏܀EJOacdfgmnostuۺ۾܃܇ܚܞܡܨ݄ݸދޏޕcy;䐕lig;䄲cy;䐁cute耻Í䃍Āiyܓܘrc耻Î䃎;䐘ot;䄰r;愑rave耻Ì䃌ƀ;apܠܯܿĀcgܴܷr;䄪inaryI;慈lieóϝǴ݉\0ݢĀ;eݍݎ戬Āgrݓݘral;戫section;拂isibleĀCTݬݲomma;恣imes;恢ƀgptݿރވon;䄮f;쀀𝕀a;䎙cr;愐ilde;䄨ǫޚ\0ޞcy;䐆l耻Ï䃏ʀcfosuެ߂ߐĀiyޱrc;䄴;䐙r;쀀𝔍pf;쀀𝕁ǣ߇\0ߌr;쀀𝒥rcy;䐈kcy;䐄HJacfosߤߨ߽߬߱ࠂࠈcy;䐥cy;䐌ppa;䎚Āey߶dil;䄶;䐚r;쀀𝔎pf;쀀𝕂cr;쀀𝒦րJTaceflmostࠥࠩࠬࡐࡣসে্ੇcy;䐉耻<䀼ʀcmnpr࠷࠼ࡁࡄࡍute;䄹bda;䎛g;柪lacetrf;愒r;憞ƀaeyࡗࡡron;䄽dil;䄻;䐛Āfsࡨ॰tԀACDFRTUVarࡾࢩࢱࣦ࣠ࣼयज़ΐ४ĀnrࢃgleBracket;柨rowƀ;BR࢙࢚࢞憐ar;懤ightArrow;懆eiling;挈oǵࢷ\0ࣃbleBracket;柦nǔࣈ\0࣒eeVector;楡ectorĀ;Bࣛࣜ懃ar;楙loor;挊ightĀAV࣯ࣵrrow;憔ector;楎Āerँगeƀ;AVउऊऐ抣rrow;憤ector;楚iangleƀ;BEतथऩ抲ar;槏qual;抴pƀDTVषूौownVector;楑eeVector;楠ectorĀ;Bॖॗ憿ar;楘ectorĀ;B॥०憼ar;楒ightáΜs̀EFGLSTॾঋকঝঢভqualGreater;拚ullEqual;扦reater;扶ess;檡lantEqual;橽ilde;扲r;쀀𝔏Ā;eঽা拘ftarrow;懚idot;䄿ƀnpwਖਛgȀLRlr৷ਂਐeftĀAR০৬rrow;柵ightArrow;柷ightArrow;柶eftĀarγਊightáοightáϊf;쀀𝕃erĀLRਢਬeftArrow;憙ightArrow;憘ƀchtਾੀੂòࡌ;憰rok;䅁;扪Ѐacefiosuਗ਼અઋp;椅y;䐜Ādl੯iumSpace;恟lintrf;愳r;쀀𝔐nusPlus;戓pf;쀀𝕄cò੶;䎜ҀJacefostuણધભીଔଙඑඞcy;䐊cute;䅃ƀaeyહાron;䅇dil;䅅;䐝ƀgswે૰ativeƀMTV૨ediumSpace;怋hiĀcn૦ëeryThiîtedĀGLଆreaterGreateòٳessLesóੈLine;䀊r;쀀𝔑ȀBnptଢନଷreak;恠BreakingSpace;䂠f;愕ڀ;CDEGHLNPRSTV୕ୖ୪௫ఄ಄ದൡඅ櫬Āoungruent;扢pCap;扭oubleVerticalBar;戦ƀlqxஃஊement;戉ualĀ;Tஒஓ扠ilde;쀀≂̸ists;戄reater;EFGLSTஶஷ扯qual;扱ullEqual;쀀≧̸reater;쀀≫̸ess;批lantEqual;쀀⩾̸ilde;扵umpń௲ownHump;쀀≎̸qual;쀀≏̸eĀfsఊధtTriangleƀ;BEచఛడ拪ar;쀀⧏̸qual;括s̀;EGLSTవశ఼ౄోౘ扮qual;扰reater;扸ess;쀀≪̸lantEqual;쀀⩽̸ilde;扴estedĀGL౨౹reaterGreater;쀀⪢̸essLess;쀀⪡̸recedesƀ;ESಒಓಛ技qual;쀀⪯̸lantEqual;拠ĀeiಫಹverseElement;戌ghtTriangleƀ;BEೋೌ拫ar;쀀⧐̸qual;拭ĀquೝഌuareSuĀbp೨setĀ;Eೳ쀀⊏̸qual;拢ersetĀ;Eഃആ쀀⊐̸qual;拣ƀbcpഓതൎsetĀ;Eഛഞ쀀⊂⃒qual;抈ceedsȀ;ESTലള഻െ抁qual;쀀⪰̸lantEqual;拡ilde;쀀≿̸ersetĀ;E൘൛쀀⊃⃒qual;抉ildeȀ;EFT൮൯൵ൿ扁qual;扄ullEqual;扇ilde;扉erticalBar;戤cr;쀀𝒩ilde耻Ñ䃑;䎝܀Eacdfgmoprstuvලෂෛ෧ขภยา฿ไlig;䅒cute耻Ó䃓Āiyීrc耻Ô䃔;䐞blac;䅐r;쀀𝔒rave耻Ò䃒ƀaei෮ෲcr;䅌ga;䎩cron;䎟pf;쀀𝕆enCurlyĀDQฎบoubleQuote;怜uote;怘;橔Āclวฬr;쀀𝒪ash耻Ø䃘iŬืde耻Õ䃕es;樷ml耻Ö䃖erĀBP๋Āar๐๓r;怾acĀek๚;揞et;掴arenthesis;揜ҀacfhilorsງຊຏຒດຝະrtialD;戂y;䐟r;쀀𝔓i;䎦;䎠usMinus;䂱Āipຢອncareplanåڝf;愙Ȁ;eio຺ູ檻cedesȀ;EST່້扺qual;檯lantEqual;扼ilde;找me;怳Ādpuct;戏ortionĀ;aȥl;戝Āci༁༆r;쀀𝒫;䎨ȀUfos༑༖༛༟OT耻"䀢r;쀀𝔔pf;愚cr;쀀𝒬BEacefhiorsu༾གྷཇའཱིྦྷྪྭ႖ႩႴႾarr;椐G耻®䂮ƀcnrཎནབute;䅔g;柫rĀ;tཛྷཝ憠l;椖ƀaeyཧཬཱron;䅘dil;䅖;䐠Ā;vླྀཹ愜erseĀEUྂྙĀlq྇ྎement;戋uilibrium;懋pEquilibrium;楯r»ཹo;䎡ghtЀACDFTUVa࿁ဢဨၛႇϘĀnr࿆࿒gleBracket;柩rowƀ;BL憒ar;懥eftArrow;懄eiling;按oǵ\0စbleBracket;柧nǔည\0နeeVector;楝ectorĀ;Bဝသ懂ar;楕loor;挋Āerိ၃eƀ;AVဵံြ抢rrow;憦ector;楛iangleƀ;BEၐၑၕ抳ar;槐qual;抵pƀDTVၣၮၸownVector;楏eeVector;楜ectorĀ;Bႂႃ憾ar;楔ectorĀ;B႑႒懀ar;楓Āpuႛ႞f;愝ndImplies;楰ightarrow;懛ĀchႹႼr;愛;憱leDelayed;槴ڀHOacfhimoqstuფჱჷჽᄙᄞᅑᅖᅡᅧᆵᆻᆿĀCcჩხHcy;䐩y;䐨FTcy;䐬cute;䅚ʀ;aeiyᄈᄉᄎᄓᄗ檼ron;䅠dil;䅞rc;䅜;䐡r;쀀𝔖ortȀDLRUᄪᄴᄾᅉownArrow»ОeftArrow»࢚ightArrow»pArrow;憑gma;䎣allCircle;战pf;쀀𝕊ɲᅭ\0\0ᅰt;戚areȀ;ISUᅻᅼᆉᆯ斡ntersection;抓uĀbpᆏᆞsetĀ;Eᆗᆘ抏qual;抑ersetĀ;Eᆨᆩ抐qual;抒nion;抔cr;쀀𝒮ar;拆ȀbcmpᇈᇛሉላĀ;sᇍᇎ拐etĀ;Eᇍᇕqual;抆ĀchᇠህeedsȀ;ESTᇭᇮᇴᇿ扻qual;檰lantEqual;扽ilde;承Tháྌ;我ƀ;esሒሓሣ拑rsetĀ;Eሜም抃qual;抇et»ሓրHRSacfhiorsሾቄቕቱቶኟዂወዑORN耻Þ䃞ADE;愢ĀHcቒcy;䐋y;䐦Ābuቚቜ;䀉;䎤ƀaeyብቪቯron;䅤dil;䅢;䐢r;쀀𝔗ĀeiቻDzኀ\0ኇefore;戴a;䎘ĀcnኘkSpace;쀀 Space;怉ldeȀ;EFTካኬኲኼ戼qual;扃ullEqual;扅ilde;扈pf;쀀𝕋ipleDot;惛Āctዖዛr;쀀𝒯rok;䅦ૡዷጎጚጦ\0ጬጱ\0\0\0\0\0ጸጽ፷ᎅ\0ᐄᐊᐐĀcrዻጁute耻Ú䃚rĀ;oጇገ憟cir;楉rǣጓ\0y;䐎ve;䅬Āiyጞጣrc耻Û䃛;䐣blac;䅰r;쀀𝔘rave耻Ù䃙acr;䅪Ādiፁ፩erĀBPፈ፝Āarፍፐr;䁟acĀekፗፙ;揟et;掵arenthesis;揝onĀ;P፰፱拃lus;抎Āgp፻on;䅲f;쀀𝕌ЀADETadps᎕ᎮᎸᏄϨᏒᏗᏳrrowƀ;BDᅐᎠᎤar;椒ownArrow;懅ownArrow;憕quilibrium;楮eeĀ;AᏋᏌ报rrow;憥ownáϳerĀLRᏞᏨeftArrow;憖ightArrow;憗iĀ;lᏹᏺ䏒on;䎥ing;䅮cr;쀀𝒰ilde;䅨ml耻Ü䃜ҀDbcdefosvᐧᐬᐰᐳᐾᒅᒊᒐᒖash;披ar;櫫y;䐒ashĀ;lᐻᐼ抩;櫦Āerᑃᑅ;拁ƀbtyᑌᑐᑺar;怖Ā;iᑏᑕcalȀBLSTᑡᑥᑪᑴar;戣ine;䁼eparator;杘ilde;所ThinSpace;怊r;쀀𝔙pf;쀀𝕍cr;쀀𝒱dash;抪ʀcefosᒧᒬᒱᒶᒼirc;䅴dge;拀r;쀀𝔚pf;쀀𝕎cr;쀀𝒲Ȁfiosᓋᓐᓒᓘr;쀀𝔛;䎞pf;쀀𝕏cr;쀀𝒳ҀAIUacfosuᓱᓵᓹᓽᔄᔏᔔᔚᔠcy;䐯cy;䐇cy;䐮cute耻Ý䃝Āiyᔉᔍrc;䅶;䐫r;쀀𝔜pf;쀀𝕐cr;쀀𝒴ml;䅸ЀHacdefosᔵᔹᔿᕋᕏᕝᕠᕤcy;䐖cute;䅹Āayᕄᕉron;䅽;䐗ot;䅻Dzᕔ\0ᕛoWidtèa;䎖r;愨pf;愤cr;쀀𝒵ᖃᖊᖐ\0ᖰᖶᖿ\0\0\0\0ᗆᗛᗫᙟ᙭\0ᚕ᚛ᚲᚹ\0ᚾcute耻á䃡reve;䄃̀;Ediuyᖜᖝᖡᖣᖨᖭ戾;쀀∾̳;房rc耻â䃢te肻´̆;䐰lig耻æ䃦Ā;r²ᖺ;쀀𝔞rave耻à䃠ĀepᗊᗖĀfpᗏᗔsym;愵èᗓha;䎱ĀapᗟcĀclᗤᗧr;䄁g;樿ɤᗰ\0\0ᘊʀ;adsvᗺᗻᗿᘁᘇ戧nd;橕;橜lope;橘;橚;elmrszᘘᘙᘛᘞᘿᙏᙙ戠;榤e»ᘙsdĀ;aᘥᘦ戡ѡᘰᘲᘴᘶᘸᘺᘼᘾ;榨;榩;榪;榫;榬;榭;榮;榯tĀ;vᙅᙆ戟bĀ;dᙌᙍ抾;榝Āptᙔᙗh;戢»¹arr;捼Āgpᙣᙧon;䄅f;쀀𝕒;Eaeiopᙻᙽᚂᚄᚇᚊ;橰cir;橯;扊d;手s;䀧roxĀ;eᚒñᚃing耻å䃥ƀctyᚡᚦᚨr;쀀𝒶;䀪mpĀ;eᚯñʈilde耻ã䃣ml耻ä䃤Āciᛂᛈoninôɲnt;樑ࠀNabcdefiklnoprsu᛭ᛱᜰᝃᝈ០៦ᠹᡐᜍ᥈ᥰot;櫭ĀcrᛶkȀcepsᜀᜅᜍᜓong;扌psilon;䏶rime;怵imĀ;e戽q;拍Ŷᜢᜦee;抽edĀ;gᜬᜭ挅e»ᜭrkĀ;tbrk;掶Āoyᜁᝁ;䐱quo;怞ʀcmprtᝓᝡᝤᝨausĀ;eĊĉptyv;榰séᜌnoõēƀahwᝯᝳ;䎲;愶een;扬r;쀀𝔟gcostuvwឍឝឳេ៕៛ƀaiuបពរðݠrc;旯p»፱ƀdptឤឨឭot;樀lus;樁imes;樂ɱឹ\0\0ើcup;樆ar;昅riangleĀdu៍្own;施p;斳plus;樄eåᑄåᒭarow;植ƀakoᠦᠵĀcn៲ᠣkƀlst֫᠂ozenge;槫riangleȀ;dlr᠒᠓᠘斴own;斾eft;旂ight;斸k;搣Ʊᠫ\0ᠳƲᠯ\0ᠱ;斒;斑4;斓ck;斈ĀeoᠾᡍĀ;qᡃᡆ쀀=⃥uiv;쀀≡⃥t;挐Ȁptwxᡙᡞᡧᡬf;쀀𝕓Ā;tᏋᡣom»Ꮜtie;拈DHUVbdhmptuvᢅᢖᢪᢻᣗᣛᣬᤅᤊᤐᤡȀLRlrᢎᢐᢒᢔ;敗;敔;敖;敓ʀ;DUduᢡᢢᢤᢦᢨ敐;敦;敩;敤;敧ȀLRlrᢳᢵᢷᢹ;敝;敚;敜;教;HLRhlrᣊᣋᣍᣏᣑᣓᣕ救;敬;散;敠;敫;敢;敟ox;槉ȀLRlrᣤᣦᣨᣪ;敕;敒;攐;攌ʀ;DUduڽ;敥;敨;攬;攴inus;抟lus;択imes;抠ȀLRlrᤙᤛᤝ;敛;敘;攘;攔;HLRhlrᤰᤱᤳᤵᤷ᤻᤹攂;敪;敡;敞;攼;攤;攜Āevģbar耻¦䂦Ȁceioᥑᥖᥚᥠr;쀀𝒷mi;恏mĀ;elƀ;bhᥨᥩᥫ䁜;槅sub;柈ŬᥴlĀ;e怢t»pƀ;Eeįᦅᦇ;檮Ā;qۜۛೡᦧ\0᧨ᨑᨕᨲ\0ᨷᩐ\0\0᪴\0\0᫁\0\0ᬡᬮ᭒\0᯽\0ᰌƀcprᦲute;䄇̀;abcdsᦿᧀᧄ᧕᧙戩nd;橄rcup;橉Āau᧒p;橋p;橇ot;橀;쀀∩︀Āeo᧢᧥t;恁îړȀaeiu᧰᧻ᨁᨅǰ᧵\0᧸s;橍on;䄍dil耻ç䃧rc;䄉psĀ;sᨌᨍ橌m;橐ot;䄋ƀdmnᨛᨠᨦil肻¸ƭptyv;榲t脀¢;eᨭᨮ䂢räƲr;쀀𝔠ƀceiᨽᩀᩍy;䑇ckĀ;mᩇᩈ朓ark»ᩈ;䏇r;Ecefms᩠ᩢᩫ᪤᪪旋;槃ƀ;elᩩᩪᩭ䋆q;扗eɡᩴ\0\0᪈rrowĀlr᩼᪁eft;憺ight;憻ʀRSacd᪒᪔᪖»ཇ;擈st;抛irc;抚ash;抝nint;樐id;櫯cir;槂ubsĀ;u᪻᪼晣it»᪼ˬ᫇\0ᬊonĀ;eᫍᫎ䀺Ā;qÇÆɭ\0\0aĀ;t䀬;䁀ƀ;fl戁îᅠeĀmxent»eóɍǧ\0ᬇĀ;dኻᬂot;橭nôɆƀfryᬐᬔᬗ;쀀𝕔oäɔ脀©;sŕᬝr;愗Āaoᬥᬩrr;憵ss;朗Ācuᬲᬷr;쀀𝒸Ābpᬼ᭄Ā;eᭁᭂ櫏;櫑Ā;eᭉᭊ櫐;櫒dot;拯delprvw᭠᭬᭷ᮂᮬᯔarrĀlr᭨᭪;椸;椵ɰ᭲\0\0᭵r;拞c;拟arrĀ;pᮀ憶;椽̀;bcdosᮏᮐᮖᮡᮥᮨ截rcap;橈Āauᮛᮞp;橆p;橊ot;抍r;橅;쀀∪︀Ȁalrv᮵ᮿᯞᯣrrĀ;mᮼᮽ憷;椼yƀevwᯇᯔᯘqɰᯎ\0\0ᯒreã᭳uã᭵ee;拎edge;拏en耻¤䂤earrowĀlrᯮ᯳eft»ᮀight»ᮽeäᯝĀciᰁᰇoninôǷnt;戱lcty;挭ঀAHabcdefhijlorstuwz᰻᰿ᱝᱩᱵᲞᲬᲷᴍᵻᶑᶫᶻ᷆᷍ròar;楥Ȁglrs᱈ᱍ᱒᱔ger;怠eth;愸òᄳhĀ;vᱚᱛ怐»ऊūᱡᱧarow;椏aã̕Āayᱮᱳron;䄏;䐴ƀ;ao̲ᱼᲄĀgrʿᲁr;懊tseq;橷ƀglmᲑᲔᲘ耻°䂰ta;䎴ptyv;榱ĀirᲣᲨsht;楿;쀀𝔡arĀlrᲳᲵ»ࣜ»သʀaegsv᳂᳖᳜᳠mƀ;oș᳔ndĀ;ș᳑uit;晦amma;䏝in;拲ƀ;io᳧᳨᳸䃷de脀÷;o᳧ᳰntimes;拇nø᳷cy;䑒cɯᴆ\0\0ᴊrn;挞op;挍ʀlptuwᴘᴝᴢᵉᵕlar;䀤f;쀀𝕕ʀ;emps̋ᴭᴷᴽᵂqĀ;d͒ᴳot;扑inus;戸lus;戔quare;抡blebarwedgåúnƀadhᄮᵝᵧownarrowóᲃarpoonĀlrᵲᵶefôᲴighôᲶŢᵿᶅkaro÷གɯᶊ\0\0ᶎrn;挟op;挌ƀcotᶘᶣᶦĀryᶝᶡ;쀀𝒹;䑕l;槶rok;䄑Ādrᶰᶴot;拱iĀ;fᶺ᠖斿Āah᷀᷃ròЩaòྦangle;榦Āci᷒ᷕy;䑟grarr;柿ऀDacdefglmnopqrstuxḁḉḙḸոḼṉṡṾấắẽỡἪἷὄĀDoḆᴴoôĀcsḎḔute耻é䃩ter;橮ȀaioyḢḧḱḶron;䄛rĀ;cḭḮ扖耻ê䃪lon;払;䑍ot;䄗ĀDrṁṅot;扒;쀀𝔢ƀ;rsṐṑṗ檚ave耻è䃨Ā;dṜṝ檖ot;檘Ȁ;ilsṪṫṲṴ檙nters;揧;愓Ā;dṹṺ檕ot;檗ƀapsẅẉẗcr;䄓tyƀ;svẒẓẕ戅et»ẓpĀ1;ẝẤijạả;怄;怅怃ĀgsẪẬ;䅋p;怂ĀgpẴẸon;䄙f;쀀𝕖ƀalsỄỎỒrĀ;sỊị拕l;槣us;橱iƀ;lvỚớở䎵on»ớ;䏵ȀcsuvỪỳἋἣĀioữḱrc»Ḯɩỹ\0\0ỻíՈantĀglἂἆtr»ṝess»ṺƀaeiἒἚls;䀽st;扟vĀ;DȵἠD;橸parsl;槥ĀDaἯἳot;打rr;楱ƀcdiἾὁỸr;愯oô͒ĀahὉὋ;䎷耻ð䃰Āmrὓὗl耻ë䃫o;悬ƀcipὡὤὧl;䀡sôծĀeoὬὴctatioîՙnentialåչৡᾒ\0ᾞ\0ᾡᾧ\0\0ῆῌ\0ΐ\0ῦῪ \0 ⁚llingdotseñṄy;䑄male;晀ƀilrᾭᾳ῁lig;耀ffiɩᾹ\0\0᾽g;耀ffig;耀ffl;쀀𝔣lig;耀filig;쀀fjƀaltῙῡt;晭ig;耀flns;斱of;䆒ǰ΅\0ῳf;쀀𝕗ĀakֿῷĀ;vῼ´拔;櫙artint;樍Āao⁕Ācs‑⁒ႉ‸⁅⁈\0⁐β•‥‧\0耻½䂽;慓耻¼䂼;慕;慙;慛Ƴ‴\0‶;慔;慖ʴ‾⁁\0\0⁃耻¾䂾;慗;慜5;慘ƶ⁌\0⁎;慚;慝8;慞l;恄wn;挢cr;쀀𝒻ࢀEabcdefgijlnorstv₂₉₥₰₴⃰℃ℒℸ̗ℾ⅒↞Ā;lٍ₇;檌ƀcmpₐₕute;䇵maĀ;dₜ᳚䎳;檆reve;䄟Āiy₪₮rc;䄝;䐳ot;䄡Ȁ;lqsؾق₽ƀ;qsؾٌlanô٥Ȁ;cdl٥⃒⃥⃕c;檩otĀ;o⃜⃝檀Ā;l⃢⃣檂;檄Ā;e⃪⃭쀀⋛︀s;檔r;쀀𝔤Ā;gٳ؛mel;愷cy;䑓Ȁ;Eajٚℌℎℐ;檒;檥;檤ȀEaesℛℝ℩ℴ;扩pĀ;p℣ℤ檊rox»ℤĀ;q℮ℯ檈Ā;q℮ℛim;拧pf;쀀𝕘Āci⅃ⅆr;愊mƀ;el٫ⅎ⅐;檎;檐茀>;cdlqrⅠⅪⅮⅳⅹĀciⅥⅧ;檧r;橺ot;拗Par;榕uest;橼ʀadelsↄⅪ←ٖ↛ǰ↉\0proør;楸qĀlqؿ↖lesó₈ií٫Āen↣↭rtneqq;쀀≩︀Å↪ԀAabcefkosy⇄⇇⇱⇵⇺∘∝∯≨≽ròΠȀilmr⇐⇔⇗⇛rsðᒄf»․ilôکĀdr⇠⇤cy;䑊ƀ;cwࣴ⇫⇯ir;楈;憭ar;意irc;䄥ƀalr∁∎∓rtsĀ;u∉∊晥it»∊lip;怦con;抹r;쀀𝔥sĀew∣∩arow;椥arow;椦ʀamopr∺∾≃≞≣rr;懿tht;戻kĀlr≉≓eftarrow;憩ightarrow;憪f;쀀𝕙bar;怕ƀclt≯≴≸r;쀀𝒽asè⇴rok;䄧Ābp⊂⊇ull;恃hen»ᱛૡ⊣\0⊪\0⊸⋅⋎\0⋕⋳\0\0⋸⌢⍧⍢⍿\0⎆⎪⎴cute耻í䃭ƀ;iyݱ⊰⊵rc耻î䃮;䐸Ācx⊼⊿y;䐵cl耻¡䂡ĀfrΟ⋉;쀀𝔦rave耻ì䃬Ȁ;inoܾ⋝⋩⋮Āin⋢⋦nt;樌t;戭fin;槜ta;愩lig;䄳ƀaop⋾⌚⌝ƀcgt⌅⌈⌗r;䄫ƀelpܟ⌏⌓inåގarôܠh;䄱f;抷ed;䆵ʀ;cfotӴ⌬⌱⌽⍁are;愅inĀ;t⌸⌹戞ie;槝doô⌙ʀ;celpݗ⍌⍐⍛⍡al;抺Āgr⍕⍙eróᕣã⍍arhk;樗rod;樼Ȁcgpt⍯⍲⍶⍻y;䑑on;䄯f;쀀𝕚a;䎹uest耻¿䂿Āci⎊⎏r;쀀𝒾nʀ;EdsvӴ⎛⎝⎡ӳ;拹ot;拵Ā;v⎦⎧拴;拳Ā;iݷ⎮lde;䄩ǫ⎸\0⎼cy;䑖l耻ï䃯̀cfmosu⏌⏗⏜⏡⏧⏵Āiy⏑⏕rc;䄵;䐹r;쀀𝔧ath;䈷pf;쀀𝕛ǣ⏬\0⏱r;쀀𝒿rcy;䑘kcy;䑔Ѐacfghjos␋␖␢ppaĀ;v␓␔䎺;䏰Āey␛␠dil;䄷;䐺r;쀀𝔨reen;䄸cy;䑅cy;䑜pf;쀀𝕜cr;쀀𝓀ABEHabcdefghjlmnoprstuv⑰⒁⒆⒍⒑┎┽╚▀♎♞♥♹♽⚚⚲⛘❝❨➋⟀⠁⠒ƀart⑷⑺⑼ròòΕail;椛arr;椎Ā;gঔ⒋;檋ar;楢ॣ⒥\0⒪\0⒱\0\0\0\0\0⒵Ⓔ\0ⓆⓈⓍ\0⓹ute;䄺mptyv;榴raîࡌbda;䎻gƀ;dlࢎⓁⓃ;榑åࢎ;檅uo耻«䂫rЀ;bfhlpst࢙ⓞⓦⓩ⓫⓮⓱⓵Ā;f࢝ⓣs;椟s;椝ë≒p;憫l;椹im;楳l;憢ƀ;ae⓿─┄檫il;椙Ā;s┉┊檭;쀀⪭︀ƀabr┕┙┝rr;椌rk;杲Āak┢┬cĀek┨┪;䁻;䁛Āes┱┳;榋lĀdu┹┻;榏;榍Ȁaeuy╆╋╖╘ron;䄾Ādi═╔il;䄼ìࢰâ┩;䐻Ȁcqrs╣╦╭╽a;椶uoĀ;rนᝆĀdu╲╷har;楧shar;楋h;憲ʀ;fgqs▋▌উ◳◿扤tʀahlrt▘▤▷◂◨rrowĀ;t࢙□aé⓶arpoonĀdu▯▴own»њp»०eftarrows;懇ightƀahs◍◖◞rrowĀ;sࣴࢧarpoonóquigarro÷⇰hreetimes;拋ƀ;qs▋ও◺lanôবʀ;cdgsব☊☍☝☨c;檨otĀ;o☔☕橿Ā;r☚☛檁;檃Ā;e☢☥쀀⋚︀s;檓ʀadegs☳☹☽♉♋pproøⓆot;拖qĀgq♃♅ôউgtò⒌ôছiíলƀilr♕࣡♚sht;楼;쀀𝔩Ā;Eজ♣;檑š♩♶rĀdu▲♮Ā;l॥♳;楪lk;斄cy;䑙ʀ;achtੈ⚈⚋⚑⚖rò◁orneòᴈard;楫ri;旺Āio⚟⚤dot;䅀ustĀ;a⚬⚭掰che»⚭ȀEaes⚻⚽⛉⛔;扨pĀ;p⛃⛄檉rox»⛄Ā;q⛎⛏檇Ā;q⛎⚻im;拦Ѐabnoptwz⛩⛴⛷✚✯❁❇❐Ānr⛮⛱g;柬r;懽rëࣁgƀlmr⛿✍✔eftĀar০✇ightá৲apsto;柼ightá৽parrowĀlr✥✩efô⓭ight;憬ƀafl✶✹✽r;榅;쀀𝕝us;樭imes;樴š❋❏st;戗áፎƀ;ef❗❘᠀旊nge»❘arĀ;l❤❥䀨t;榓ʀachmt❳❶❼➅➇ròࢨorneòᶌarĀ;d➃;業;怎ri;抿̀achiqt➘➝ੀ➢➮➻quo;怹r;쀀𝓁mƀ;egল➪➬;檍;檏Ābu┪➳oĀ;rฟ➹;怚rok;䅂萀<;cdhilqrࠫ⟒☹⟜⟠⟥⟪⟰Āci⟗⟙;檦r;橹reå◲mes;拉arr;楶uest;橻ĀPi⟵⟹ar;榖ƀ;ef⠀भ旃rĀdu⠇⠍shar;楊har;楦Āen⠗⠡rtneqq;쀀≨︀Å⠞܀Dacdefhilnopsu⡀⡅⢂⢎⢓⢠⢥⢨⣚⣢⣤ઃ⣳⤂Dot;戺Ȁclpr⡎⡒⡣⡽r耻¯䂯Āet⡗⡙;時Ā;e⡞⡟朠se»⡟Ā;sျ⡨toȀ;dluျ⡳⡷⡻owîҌefôएðᏑker;斮Āoy⢇⢌mma;権;䐼ash;怔asuredangle»ᘦr;쀀𝔪o;愧ƀcdn⢯⢴⣉ro耻µ䂵Ȁ;acdᑤ⢽⣀⣄sôᚧir;櫰ot肻·Ƶusƀ;bd⣒ᤃ⣓戒Ā;uᴼ⣘;横ţ⣞⣡p;櫛ò−ðઁĀdp⣩⣮els;抧f;쀀𝕞Āct⣸⣽r;쀀𝓂pos»ᖝƀ;lm⤉⤊⤍䎼timap;抸ఀGLRVabcdefghijlmoprstuvw⥂⥓⥾⦉⦘⧚⧩⨕⨚⩘⩝⪃⪕⪤⪨⬄⬇⭄⭿⮮ⰴⱧⱼ⳩Āgt⥇⥋;쀀⋙̸Ā;v⥐쀀≫⃒ƀelt⥚⥲⥶ftĀar⥡⥧rrow;懍ightarrow;懎;쀀⋘̸Ā;v⥻ే쀀≪⃒ightarrow;懏ĀDd⦎⦓ash;抯ash;抮ʀbcnpt⦣⦧⦬⦱⧌la»˞ute;䅄g;쀀∠⃒ʀ;Eiop⦼⧀⧅⧈;쀀⩰̸d;쀀≋̸s;䅉roøurĀ;a⧓⧔普lĀ;s⧓ସdz⧟\0⧣p肻 ଷmpĀ;e௹ఀʀaeouy⧴⧾⨃⨐⨓ǰ⧹\0⧻;橃on;䅈dil;䅆ngĀ;dൾ⨊ot;쀀⩭̸p;橂;䐽ash;怓;Aadqsxஒ⨩⨭⨻⩁⩅⩐rr;懗rĀhr⨳⨶k;椤Ā;oᏲᏰot;쀀≐̸uiöୣĀei⩊⩎ar;椨íistĀ;sடr;쀀𝔫ȀEest⩦⩹⩼ƀ;qs⩭ƀ;qs⩴lanôií௪Ā;rஶ⪁»ஷƀAap⪊⪍⪑rò⥱rr;憮ar;櫲ƀ;svྍ⪜ྌĀ;d⪡⪢拼;拺cy;䑚AEadest⪷⪺⪾⫂⫅⫶⫹rò⥦;쀀≦̸rr;憚r;急Ȁ;fqs⫎⫣⫯tĀar⫔⫙rro÷⫁ightarro÷⪐ƀ;qs⪺⫪lanôౕĀ;sౕ⫴»శiíౝĀ;rవ⫾iĀ;eచథiäඐĀpt⬌⬑f;쀀𝕟膀¬;in⬙⬚⬶䂬nȀ;Edvஉ⬤⬨⬮;쀀⋹̸ot;쀀⋵̸ǡஉ⬳⬵;拷;拶iĀ;vಸ⬼ǡಸ⭁⭃;拾;拽ƀaor⭋⭣⭩rȀ;ast⭕⭚⭟lleìl;쀀⫽⃥;쀀∂̸lint;樔ƀ;ceಒ⭰⭳uåಥĀ;cಘ⭸Ā;eಒ⭽ñಘȀAait⮈⮋⮝⮧rò⦈rrƀ;cw⮔⮕⮙憛;쀀⤳̸;쀀↝̸ghtarrow»⮕riĀ;eೋೖchimpqu⮽⯍⯙⬄⯤⯯Ȁ;cerല⯆ഷ⯉uå;쀀𝓃ortɭ⬅\0\0⯖ará⭖mĀ;e൮⯟Ā;q൴൳suĀbp⯫⯭ååഋƀbcp⯶ⰑⰙȀ;Ees⯿ⰀഢⰄ抄;쀀⫅̸etĀ;eഛⰋqĀ;qണⰀcĀ;eലⰗñസȀ;EesⰢⰣൟⰧ抅;쀀⫆̸etĀ;e൘ⰮqĀ;qൠⰣȀgilrⰽⰿⱅⱇìௗlde耻ñ䃱çృiangleĀlrⱒⱜeftĀ;eచⱚñదightĀ;eೋⱥñĀ;mⱬⱭ䎽ƀ;esⱴⱵⱹ䀣ro;愖p;怇ҀDHadgilrsⲏⲔⲙⲞⲣⲰⲶⳓⳣash;抭arr;椄p;쀀≍⃒ash;抬ĀetⲨⲬ;쀀≥⃒;쀀>⃒nfin;槞ƀAetⲽⳁⳅrr;椂;쀀≤⃒Ā;rⳊⳍ쀀<⃒ie;쀀⊴⃒ĀAtⳘⳜrr;椃rie;쀀⊵⃒im;쀀∼⃒ƀAan⳰ⴂrr;懖rĀhr⳺⳽k;椣Ā;oᏧᏥear;椧ቓ᪕\0\0\0\0\0\0\0\0\0\0\0\0\0ⴭ\0ⴸⵈⵠⵥⶄᬇ\0\0ⶍⶫ\0ⷈⷎ\0ⷜ⸙⸫⸾⹃Ācsⴱ᪗ute耻ó䃳ĀiyⴼⵅrĀ;cⵂ耻ô䃴;䐾ʀabios᪠ⵒⵗLjⵚlac;䅑v;樸old;榼lig;䅓Ācrir;榿;쀀𝔬ͯ\0\0\0ⶂn;䋛ave耻ò䃲;槁Ābmⶈ෴ar;榵Ȁacitⶕⶥⶨrò᪀Āirⶠr;榾oss;榻nå๒;槀ƀaeiⶱⶵⶹcr;䅍ga;䏉ƀcdnⷀⷅǍron;䎿;榶pf;쀀𝕠ƀaelⷔǒr;榷rp;榹;adiosvⷪⷫⷮ⸈⸍⸐⸖戨rò᪆Ȁ;efmⷷⷸ⸂⸅橝rĀ;oⷾⷿ愴f»ⷿ耻ª䂪耻º䂺gof;抶r;橖lope;橗;橛ƀclo⸟⸡⸧ò⸁ash耻ø䃸l;折iŬⸯ⸴de耻õ䃵esĀ;aǛ⸺s;樶ml耻ö䃶bar;挽ૡ\0\0⺀⺝\0⺢⺹\0\0⻋ຜ\0⼓\0\0⼫⾼\0⿈rȀ;astЃ脀¶;l䂶leìЃɩ\0\0m;櫳;櫽y;䐿rʀcimpt⺋⺏⺓ᡥ⺗nt;䀥od;䀮il;怰enk;怱r;쀀𝔭ƀimo⺨⺰⺴Ā;v⺭⺮䏆;䏕maô੶ne;明ƀ;tv⺿⻀⻈䏀chfork»´;䏖Āau⻏⻟nĀck⻕⻝kĀ;h⇴⻛;愎ö⇴sҀ;abcdemst⻳ᤈ⼄⼆⼊⼎䀫cir;樣ir;樢Āouᵀ⼂;樥;橲n肻±ຝim;樦wo;樧ƀipu⼙⼠⼥ntint;樕f;쀀𝕡nd耻£䂣Ԁ;Eaceinosu່⼿⽁⽄⽇⾁⾉⾒⽾⾶;檳p;檷uå໙Ā;c໎⽌̀;acens່⽙⽟⽦⽨⽾pproø⽃urlyeñ໙ñ໎ƀaes⽯⽶⽺pprox;檹qq;檵im;拨iíໟmeĀ;s⾈ຮ怲ƀEas⽸⾐⽺ð⽵ƀdfp⾙⾯ƀals⾠⾥⾪lar;挮ine;挒urf;挓Ā;t⾴ïrel;抰Āci⿀⿅r;쀀𝓅;䏈ncsp;怈̀fiopsu⋢⿱r;쀀𝔮pf;쀀𝕢rime;恗cr;쀀𝓆ƀaeo⿸〉〓tĀei々rnionóڰnt;樖stĀ;e【】䀿ñἙô༔ABHabcdefhilmnoprstuxけさすムㄎㄫㅇㅢㅲㆎ㈆㈕㈤㈩㉘㉮㉲㊐㊰㊷ƀartぇおがròႳòϝail;検aròᱥar;楤cdenqrtとふへみわゔヌĀeuねぱ;쀀∽̱te;䅕iãᅮmptyv;榳gȀ;del࿑らるろ;榒;榥å࿑uo耻»䂻rր;abcfhlpstwガクシスゼゾダッデナp;極Ā;fゴs;椠;椳s;椞ë≝ð✮l;楅im;楴l;憣;憝Āaiパフil;椚oĀ;nホボ戶aló༞ƀabrョリヮrò៥rk;杳ĀakンヽcĀekヹ・;䁽;䁝Āes;榌lĀduㄊㄌ;榎;榐Ȁaeuyㄗㄜㄧㄩron;䅙Ādiㄡㄥil;䅗ìâヺ;䑀Ȁclqsㄴㄷㄽㅄa;椷dhar;楩uoĀ;rȎȍh;憳ƀacgㅎㅟངlȀ;ipsླྀㅘㅛႜnåႻarôྩt;断ƀilrㅩဣㅮsht;楽;쀀𝔯ĀaoㅷㆆrĀduㅽㅿ»ѻĀ;l႑ㆄ;楬Ā;vㆋㆌ䏁;䏱ƀgns㆕ㇹㇼht̀ahlrstㆤㆰ㇂㇘rrowĀ;tㆭaéトarpoonĀduㆻㆿowîㅾp»႒eftĀah㇊㇐rrowóarpoonóՑightarrows;應quigarro÷ニhreetimes;拌g;䋚ingdotseñἲƀahm㈍㈐㈓ròaòՑ;怏oustĀ;a㈞掱che»mid;櫮Ȁabpt㈲㈽㉀㉒Ānr㈷㈺g;柭r;懾rëဃƀafl㉇㉊㉎r;榆;쀀𝕣us;樮imes;樵Āap㉝㉧rĀ;g㉣㉤䀩t;榔olint;樒arò㇣Ȁachq㉻㊀Ⴜ㊅quo;怺r;쀀𝓇Ābu・㊊oĀ;rȔȓƀhir㊗㊛㊠reåㇸmes;拊iȀ;efl㊪ၙᠡ㊫方tri;槎luhar;楨;愞ൡ㋕㋛㋟㌬㌸㍱\0㍺㎤\0\0㏬㏰\0㐨㑈㑚㒭㒱㓊㓱\0㘖\0\0㘳cute;䅛quï➺Ԁ;Eaceinpsyᇭ㋳㋵㋿㌂㌋㌏㌟㌦㌩;檴ǰ㋺\0㋼;檸on;䅡uåᇾĀ;dᇳ㌇il;䅟rc;䅝ƀEas㌖㌘㌛;檶p;檺im;择olint;樓iíሄ;䑁otƀ;be㌴ᵇ㌵担;橦Aacmstx㍆㍊㍗㍛㍞㍣㍭rr;懘rĀhr㍐㍒ë∨Ā;oਸ਼t耻§䂧i;䀻war;椩mĀin㍩ðnuóñt;朶rĀ;o㍶⁕쀀𝔰Ȁacoy㎂㎆㎑㎠rp;景Āhy㎋㎏cy;䑉;䑈rtɭ㎙\0\0㎜iäᑤaraì耻䂭Āgm㎨㎴maƀ;fv㎱㎲㎲䏃;䏂Ѐ;deglnprካ㏅㏉㏎㏖㏞㏡㏦ot;橪Ā;qኰĀ;E㏓㏔檞;檠Ā;E㏛㏜檝;檟e;扆lus;樤arr;楲aròᄽȀaeit㏸㐈㐏㐗Āls㏽㐄lsetmé㍪hp;樳parsl;槤Ādlᑣ㐔e;挣Ā;e㐜㐝檪Ā;s㐢㐣檬;쀀⪬︀ƀflp㐮㐳㑂tcy;䑌Ā;b㐸㐹䀯Ā;a㐾㐿槄r;挿f;쀀𝕤aĀdr㑍ЂesĀ;u㑔㑕晠it»㑕ƀcsu㑠㑹㒟Āau㑥㑯pĀ;sᆈ㑫;쀀⊓︀pĀ;sᆴ㑵;쀀⊔︀uĀbp㑿㒏ƀ;esᆗᆜ㒆etĀ;eᆗ㒍ñᆝƀ;esᆨᆭ㒖etĀ;eᆨ㒝ñᆮƀ;afᅻ㒦ְrť㒫ֱ»ᅼaròᅈȀcemt㒹㒾㓂㓅r;쀀𝓈tmîñiì㐕aræᆾĀar㓎㓕rĀ;f㓔ឿ昆Āan㓚㓭ightĀep㓣㓪psiloîỠhé⺯s»⡒ʀbcmnp㓻㕞ሉ㖋㖎Ҁ;Edemnprs㔎㔏㔑㔕㔞㔣㔬㔱㔶抂;櫅ot;檽Ā;dᇚ㔚ot;櫃ult;櫁ĀEe㔨㔪;櫋;把lus;檿arr;楹ƀeiu㔽㕒㕕tƀ;en㔎㕅㕋qĀ;qᇚ㔏eqĀ;q㔫㔨m;櫇Ābp㕚㕜;櫕;櫓c̀;acensᇭ㕬㕲㕹㕻㌦pproø㋺urlyeñᇾñᇳƀaes㖂㖈㌛pproø㌚qñ㌗g;晪ڀ123;Edehlmnps㖩㖬㖯ሜ㖲㖴㗀㗉㗕㗚㗟㗨㗭耻¹䂹耻²䂲耻³䂳;櫆Āos㖹㖼t;檾ub;櫘Ā;dሢ㗅ot;櫄sĀou㗏㗒l;柉b;櫗arr;楻ult;櫂ĀEe㗤㗦;櫌;抋lus;櫀ƀeiu㗴㘉㘌tƀ;enሜ㗼㘂qĀ;qሢ㖲eqĀ;q㗧㗤m;櫈Ābp㘑㘓;櫔;櫖ƀAan㘜㘠㘭rr;懙rĀhr㘦㘨ë∮Ā;oਫwar;椪lig耻ß䃟㙑㙝㙠ዎ㙳㙹\0㙾㛂\0\0\0\0\0㛛㜃\0㜉㝬\0\0\0㞇ɲ㙖\0\0㙛get;挖;䏄rëƀaey㙦㙫㙰ron;䅥dil;䅣;䑂lrec;挕r;쀀𝔱Ȁeiko㚆㚝㚵㚼Dz㚋\0㚑eĀ4fኄኁaƀ;sv㚘㚙㚛䎸ym;䏑Ācn㚢㚲kĀas㚨㚮pproøim»ኬsðኞĀas㚺㚮ðrn耻þ䃾Ǭ̟㛆⋧es膀×;bd㛏㛐㛘䃗Ā;aᤏ㛕r;樱;樰ƀeps㛡㛣㜀á⩍Ȁ;bcf҆㛬㛰㛴ot;挶ir;櫱Ā;o㛹㛼쀀𝕥rk;櫚á㍢rime;怴ƀaip㜏㜒㝤dåቈadempst㜡㝍㝀㝑㝗㝜㝟ngleʀ;dlqr㜰㜱㜶㝀㝂斵own»ᶻeftĀ;e⠀㜾ñम;扜ightĀ;e㊪㝋ñၚot;旬inus;樺lus;樹b;槍ime;樻ezium;揢ƀcht㝲㝽㞁Āry㝷㝻;쀀𝓉;䑆cy;䑛rok;䅧Āio㞋㞎xôheadĀlr㞗㞠eftarro÷ࡏightarrow»ཝऀAHabcdfghlmoprstuw㟐㟓㟗㟤㟰㟼㠎㠜㠣㠴㡑㡝㡫㢩㣌㣒㣪㣶ròϭar;楣Ācr㟜㟢ute耻ú䃺òᅐrǣ㟪\0㟭y;䑞ve;䅭Āiy㟵㟺rc耻û䃻;䑃ƀabh㠃㠆㠋ròᎭlac;䅱aòᏃĀir㠓㠘sht;楾;쀀𝔲rave耻ù䃹š㠧㠱rĀlr㠬㠮»ॗ»ႃlk;斀Āct㠹㡍ɯ㠿\0\0㡊rnĀ;e㡅㡆挜r»㡆op;挏ri;旸Āal㡖㡚cr;䅫肻¨͉Āgp㡢㡦on;䅳f;쀀𝕦̀adhlsuᅋ㡸㡽፲㢑㢠ownáᎳarpoonĀlr㢈㢌efô㠭ighô㠯iƀ;hl㢙㢚㢜䏅»ᏺon»㢚parrows;懈ƀcit㢰㣄㣈ɯ㢶\0\0㣁rnĀ;e㢼㢽挝r»㢽op;挎ng;䅯ri;旹cr;쀀𝓊ƀdir㣙㣝㣢ot;拰lde;䅩iĀ;f㜰㣨»᠓Āam㣯㣲rò㢨l耻ü䃼angle;榧ހABDacdeflnoprsz㤜㤟㤩㤭㦵㦸㦽㧟㧤㧨㧳㧹㧽㨁㨠ròϷarĀ;v㤦㤧櫨;櫩asèϡĀnr㤲㤷grt;榜eknprst㓣㥆㥋㥒㥝㥤㦖appá␕othinçẖƀhir㓫⻈㥙opô⾵Ā;hᎷ㥢ïㆍĀiu㥩㥭gmá㎳Ābp㥲㦄setneqĀ;q㥽㦀쀀⊊︀;쀀⫋︀setneqĀ;q㦏㦒쀀⊋︀;쀀⫌︀Āhr㦛㦟etá㚜iangleĀlr㦪㦯eft»थight»ၑy;䐲ash»ံƀelr㧄㧒㧗ƀ;beⷪ㧋㧏ar;抻q;扚lip;拮Ābt㧜ᑨaòᑩr;쀀𝔳tré㦮suĀbp㧯㧱»ജ»൙pf;쀀𝕧roðtré㦴Ācu㨆㨋r;쀀𝓋Ābp㨐㨘nĀEe㦀㨖»㥾nĀEe㦒㨞»㦐igzag;榚cefoprs㨶㨻㩖㩛㩔㩡㩪irc;䅵Ādi㩀㩑Ābg㩅㩉ar;機eĀ;qᗺ㩏;扙erp;愘r;쀀𝔴pf;쀀𝕨Ā;eᑹ㩦atèᑹcr;쀀𝓌ૣណ㪇\0㪋\0㪐㪛\0\0㪝㪨㪫㪯\0\0㫃㫎\0㫘ៜtré៑r;쀀𝔵ĀAa㪔㪗ròσrò৶;䎾ĀAa㪡㪤ròθrò৫að✓is;拻ƀdptឤ㪵㪾Āfl㪺ឩ;쀀𝕩imåឲĀAa㫇㫊ròώròਁĀcq㫒ីr;쀀𝓍Āpt៖㫜ré។Ѐacefiosu㫰㫽㬈㬌㬑㬕㬛㬡cĀuy㫶㫻te耻ý䃽;䑏Āiy㬂㬆rc;䅷;䑋n耻¥䂥r;쀀𝔶cy;䑗pf;쀀𝕪cr;쀀𝓎Ācm㬦㬩y;䑎l耻ÿ䃿Ԁacdefhiosw㭂㭈㭔㭘㭤㭩㭭㭴㭺㮀cute;䅺Āay㭍㭒ron;䅾;䐷ot;䅼Āet㭝㭡træᕟa;䎶r;쀀𝔷cy;䐶grarr;懝pf;쀀𝕫cr;쀀𝓏Ājn㮅㮇;怍j;怌'.split("").map(e=>e.charCodeAt(0))),Uh=new Map([[0,65533],[128,8364],[130,8218],[131,402],[132,8222],[133,8230],[134,8224],[135,8225],[136,710],[137,8240],[138,352],[139,8249],[140,338],[142,381],[145,8216],[146,8217],[147,8220],[148,8221],[149,8226],[150,8211],[151,8212],[152,732],[153,8482],[154,353],[155,8250],[156,339],[158,382],[159,376]]);function zh(e){var t;return e>=55296&&e<=57343||e>1114111?65533:(t=Uh.get(e))!==null&&t!==void 0?t:e}var Pe;(function(e){e[e.NUM=35]="NUM",e[e.SEMI=59]="SEMI",e[e.EQUALS=61]="EQUALS",e[e.ZERO=48]="ZERO",e[e.NINE=57]="NINE",e[e.LOWER_A=97]="LOWER_A",e[e.LOWER_F=102]="LOWER_F",e[e.LOWER_X=120]="LOWER_X",e[e.LOWER_Z=122]="LOWER_Z",e[e.UPPER_A=65]="UPPER_A",e[e.UPPER_F=70]="UPPER_F",e[e.UPPER_Z=90]="UPPER_Z"})(Pe||(Pe={}));const $h=32;var Lt;(function(e){e[e.VALUE_LENGTH=49152]="VALUE_LENGTH",e[e.BRANCH_LENGTH=16256]="BRANCH_LENGTH",e[e.JUMP_TABLE=127]="JUMP_TABLE"})(Lt||(Lt={}));function fa(e){return e>=Pe.ZERO&&e<=Pe.NINE}function Yh(e){return e>=Pe.UPPER_A&&e<=Pe.UPPER_F||e>=Pe.LOWER_A&&e<=Pe.LOWER_F}function jh(e){return e>=Pe.UPPER_A&&e<=Pe.UPPER_Z||e>=Pe.LOWER_A&&e<=Pe.LOWER_Z||fa(e)}function Vh(e){return e===Pe.EQUALS||jh(e)}var Me;(function(e){e[e.EntityStart=0]="EntityStart",e[e.NumericStart=1]="NumericStart",e[e.NumericDecimal=2]="NumericDecimal",e[e.NumericHex=3]="NumericHex",e[e.NamedEntity=4]="NamedEntity"})(Me||(Me={}));var xt;(function(e){e[e.Legacy=0]="Legacy",e[e.Strict=1]="Strict",e[e.Attribute=2]="Attribute"})(xt||(xt={}));class qh{constructor(t,n,r){this.decodeTree=t,this.emitCodePoint=n,this.errors=r,this.state=Me.EntityStart,this.consumed=1,this.result=0,this.treeIndex=0,this.excess=1,this.decodeMode=xt.Strict}startEntity(t){this.decodeMode=t,this.state=Me.EntityStart,this.result=0,this.treeIndex=0,this.excess=1,this.consumed=1}write(t,n){switch(this.state){case Me.EntityStart:return t.charCodeAt(n)===Pe.NUM?(this.state=Me.NumericStart,this.consumed+=1,this.stateNumericStart(t,n+1)):(this.state=Me.NamedEntity,this.stateNamedEntity(t,n));case Me.NumericStart:return this.stateNumericStart(t,n);case Me.NumericDecimal:return this.stateNumericDecimal(t,n);case Me.NumericHex:return this.stateNumericHex(t,n);case Me.NamedEntity:return this.stateNamedEntity(t,n)}}stateNumericStart(t,n){return n>=t.length?-1:(t.charCodeAt(n)|$h)===Pe.LOWER_X?(this.state=Me.NumericHex,this.consumed+=1,this.stateNumericHex(t,n+1)):(this.state=Me.NumericDecimal,this.stateNumericDecimal(t,n))}addToNumericResult(t,n,r,i){if(n!==r){const a=r-n;this.result=this.result*Math.pow(i,a)+Number.parseInt(t.substr(n,a),i),this.consumed+=a}}stateNumericHex(t,n){const r=n;for(;n<t.length;){const i=t.charCodeAt(n);if(fa(i)||Yh(i))n+=1;else return this.addToNumericResult(t,r,n,16),this.emitNumericEntity(i,3)}return this.addToNumericResult(t,r,n,16),-1}stateNumericDecimal(t,n){const r=n;for(;n<t.length;){const i=t.charCodeAt(n);if(fa(i))n+=1;else return this.addToNumericResult(t,r,n,10),this.emitNumericEntity(i,2)}return this.addToNumericResult(t,r,n,10),-1}emitNumericEntity(t,n){var r;if(this.consumed<=n)return(r=this.errors)===null||r===void 0||r.absenceOfDigitsInNumericCharacterReference(this.consumed),0;if(t===Pe.SEMI)this.consumed+=1;else if(this.decodeMode===xt.Strict)return 0;return this.emitCodePoint(zh(this.result),this.consumed),this.errors&&(t!==Pe.SEMI&&this.errors.missingSemicolonAfterCharacterReference(),this.errors.validateNumericCharacterReference(this.result)),this.consumed}stateNamedEntity(t,n){const{decodeTree:r}=this;let i=r[this.treeIndex],a=(i&Lt.VALUE_LENGTH)>>14;for(;n<t.length;n++,this.excess++){const s=t.charCodeAt(n);if(this.treeIndex=Wh(r,i,this.treeIndex+Math.max(1,a),s),this.treeIndex<0)return this.result===0||this.decodeMode===xt.Attribute&&(a===0||Vh(s))?0:this.emitNotTerminatedNamedEntity();if(i=r[this.treeIndex],a=(i&Lt.VALUE_LENGTH)>>14,a!==0){if(s===Pe.SEMI)return this.emitNamedEntityData(this.treeIndex,a,this.consumed+this.excess);this.decodeMode!==xt.Strict&&(this.result=this.treeIndex,this.consumed+=this.excess,this.excess=0)}}return-1}emitNotTerminatedNamedEntity(){var t;const{result:n,decodeTree:r}=this,i=(r[n]&Lt.VALUE_LENGTH)>>14;return this.emitNamedEntityData(n,i,this.consumed),(t=this.errors)===null||t===void 0||t.missingSemicolonAfterCharacterReference(),this.consumed}emitNamedEntityData(t,n,r){const{decodeTree:i}=this;return this.emitCodePoint(n===1?i[t]&~Lt.VALUE_LENGTH:i[t+1],r),n===3&&this.emitCodePoint(i[t+2],r),r}end(){var t;switch(this.state){case Me.NamedEntity:return this.result!==0&&(this.decodeMode!==xt.Attribute||this.result===this.treeIndex)?this.emitNotTerminatedNamedEntity():0;case Me.NumericDecimal:return this.emitNumericEntity(0,2);case Me.NumericHex:return this.emitNumericEntity(0,3);case Me.NumericStart:return(t=this.errors)===null||t===void 0||t.absenceOfDigitsInNumericCharacterReference(this.consumed),0;case Me.EntityStart:return 0}}}function Wh(e,t,n,r){const i=(t&Lt.BRANCH_LENGTH)>>7,a=t&Lt.JUMP_TABLE;if(i===0)return a!==0&&r===a?n:-1;if(a){const u=r-a;return u<0||u>=i?-1:e[n+u]-1}let s=n,o=s+i-1;for(;s<=o;){const u=s+o>>>1,c=e[u];if(c<r)s=u+1;else if(c>r)o=u-1;else return e[u+i]}return-1}var O;(function(e){e.HTML="http://www.w3.org/1999/xhtml",e.MATHML="http://www.w3.org/1998/Math/MathML",e.SVG="http://www.w3.org/2000/svg",e.XLINK="http://www.w3.org/1999/xlink",e.XML="http://www.w3.org/XML/1998/namespace",e.XMLNS="http://www.w3.org/2000/xmlns/"})(O||(O={}));var Zt;(function(e){e.TYPE="type",e.ACTION="action",e.ENCODING="encoding",e.PROMPT="prompt",e.NAME="name",e.COLOR="color",e.FACE="face",e.SIZE="size"})(Zt||(Zt={}));var tt;(function(e){e.NO_QUIRKS="no-quirks",e.QUIRKS="quirks",e.LIMITED_QUIRKS="limited-quirks"})(tt||(tt={}));var v;(function(e){e.A="a",e.ADDRESS="address",e.ANNOTATION_XML="annotation-xml",e.APPLET="applet",e.AREA="area",e.ARTICLE="article",e.ASIDE="aside",e.B="b",e.BASE="base",e.BASEFONT="basefont",e.BGSOUND="bgsound",e.BIG="big",e.BLOCKQUOTE="blockquote",e.BODY="body",e.BR="br",e.BUTTON="button",e.CAPTION="caption",e.CENTER="center",e.CODE="code",e.COL="col",e.COLGROUP="colgroup",e.DD="dd",e.DESC="desc",e.DETAILS="details",e.DIALOG="dialog",e.DIR="dir",e.DIV="div",e.DL="dl",e.DT="dt",e.EM="em",e.EMBED="embed",e.FIELDSET="fieldset",e.FIGCAPTION="figcaption",e.FIGURE="figure",e.FONT="font",e.FOOTER="footer",e.FOREIGN_OBJECT="foreignObject",e.FORM="form",e.FRAME="frame",e.FRAMESET="frameset",e.H1="h1",e.H2="h2",e.H3="h3",e.H4="h4",e.H5="h5",e.H6="h6",e.HEAD="head",e.HEADER="header",e.HGROUP="hgroup",e.HR="hr",e.HTML="html",e.I="i",e.IMG="img",e.IMAGE="image",e.INPUT="input",e.IFRAME="iframe",e.KEYGEN="keygen",e.LABEL="label",e.LI="li",e.LINK="link",e.LISTING="listing",e.MAIN="main",e.MALIGNMARK="malignmark",e.MARQUEE="marquee",e.MATH="math",e.MENU="menu",e.META="meta",e.MGLYPH="mglyph",e.MI="mi",e.MO="mo",e.MN="mn",e.MS="ms",e.MTEXT="mtext",e.NAV="nav",e.NOBR="nobr",e.NOFRAMES="noframes",e.NOEMBED="noembed",e.NOSCRIPT="noscript",e.OBJECT="object",e.OL="ol",e.OPTGROUP="optgroup",e.OPTION="option",e.P="p",e.PARAM="param",e.PLAINTEXT="plaintext",e.PRE="pre",e.RB="rb",e.RP="rp",e.RT="rt",e.RTC="rtc",e.RUBY="ruby",e.S="s",e.SCRIPT="script",e.SEARCH="search",e.SECTION="section",e.SELECT="select",e.SOURCE="source",e.SMALL="small",e.SPAN="span",e.STRIKE="strike",e.STRONG="strong",e.STYLE="style",e.SUB="sub",e.SUMMARY="summary",e.SUP="sup",e.TABLE="table",e.TBODY="tbody",e.TEMPLATE="template",e.TEXTAREA="textarea",e.TFOOT="tfoot",e.TD="td",e.TH="th",e.THEAD="thead",e.TITLE="title",e.TR="tr",e.TRACK="track",e.TT="tt",e.U="u",e.UL="ul",e.SVG="svg",e.VAR="var",e.WBR="wbr",e.XMP="xmp"})(v||(v={}));var l;(function(e){e[e.UNKNOWN=0]="UNKNOWN",e[e.A=1]="A",e[e.ADDRESS=2]="ADDRESS",e[e.ANNOTATION_XML=3]="ANNOTATION_XML",e[e.APPLET=4]="APPLET",e[e.AREA=5]="AREA",e[e.ARTICLE=6]="ARTICLE",e[e.ASIDE=7]="ASIDE",e[e.B=8]="B",e[e.BASE=9]="BASE",e[e.BASEFONT=10]="BASEFONT",e[e.BGSOUND=11]="BGSOUND",e[e.BIG=12]="BIG",e[e.BLOCKQUOTE=13]="BLOCKQUOTE",e[e.BODY=14]="BODY",e[e.BR=15]="BR",e[e.BUTTON=16]="BUTTON",e[e.CAPTION=17]="CAPTION",e[e.CENTER=18]="CENTER",e[e.CODE=19]="CODE",e[e.COL=20]="COL",e[e.COLGROUP=21]="COLGROUP",e[e.DD=22]="DD",e[e.DESC=23]="DESC",e[e.DETAILS=24]="DETAILS",e[e.DIALOG=25]="DIALOG",e[e.DIR=26]="DIR",e[e.DIV=27]="DIV",e[e.DL=28]="DL",e[e.DT=29]="DT",e[e.EM=30]="EM",e[e.EMBED=31]="EMBED",e[e.FIELDSET=32]="FIELDSET",e[e.FIGCAPTION=33]="FIGCAPTION",e[e.FIGURE=34]="FIGURE",e[e.FONT=35]="FONT",e[e.FOOTER=36]="FOOTER",e[e.FOREIGN_OBJECT=37]="FOREIGN_OBJECT",e[e.FORM=38]="FORM",e[e.FRAME=39]="FRAME",e[e.FRAMESET=40]="FRAMESET",e[e.H1=41]="H1",e[e.H2=42]="H2",e[e.H3=43]="H3",e[e.H4=44]="H4",e[e.H5=45]="H5",e[e.H6=46]="H6",e[e.HEAD=47]="HEAD",e[e.HEADER=48]="HEADER",e[e.HGROUP=49]="HGROUP",e[e.HR=50]="HR",e[e.HTML=51]="HTML",e[e.I=52]="I",e[e.IMG=53]="IMG",e[e.IMAGE=54]="IMAGE",e[e.INPUT=55]="INPUT",e[e.IFRAME=56]="IFRAME",e[e.KEYGEN=57]="KEYGEN",e[e.LABEL=58]="LABEL",e[e.LI=59]="LI",e[e.LINK=60]="LINK",e[e.LISTING=61]="LISTING",e[e.MAIN=62]="MAIN",e[e.MALIGNMARK=63]="MALIGNMARK",e[e.MARQUEE=64]="MARQUEE",e[e.MATH=65]="MATH",e[e.MENU=66]="MENU",e[e.META=67]="META",e[e.MGLYPH=68]="MGLYPH",e[e.MI=69]="MI",e[e.MO=70]="MO",e[e.MN=71]="MN",e[e.MS=72]="MS",e[e.MTEXT=73]="MTEXT",e[e.NAV=74]="NAV",e[e.NOBR=75]="NOBR",e[e.NOFRAMES=76]="NOFRAMES",e[e.NOEMBED=77]="NOEMBED",e[e.NOSCRIPT=78]="NOSCRIPT",e[e.OBJECT=79]="OBJECT",e[e.OL=80]="OL",e[e.OPTGROUP=81]="OPTGROUP",e[e.OPTION=82]="OPTION",e[e.P=83]="P",e[e.PARAM=84]="PARAM",e[e.PLAINTEXT=85]="PLAINTEXT",e[e.PRE=86]="PRE",e[e.RB=87]="RB",e[e.RP=88]="RP",e[e.RT=89]="RT",e[e.RTC=90]="RTC",e[e.RUBY=91]="RUBY",e[e.S=92]="S",e[e.SCRIPT=93]="SCRIPT",e[e.SEARCH=94]="SEARCH",e[e.SECTION=95]="SECTION",e[e.SELECT=96]="SELECT",e[e.SOURCE=97]="SOURCE",e[e.SMALL=98]="SMALL",e[e.SPAN=99]="SPAN",e[e.STRIKE=100]="STRIKE",e[e.STRONG=101]="STRONG",e[e.STYLE=102]="STYLE",e[e.SUB=103]="SUB",e[e.SUMMARY=104]="SUMMARY",e[e.SUP=105]="SUP",e[e.TABLE=106]="TABLE",e[e.TBODY=107]="TBODY",e[e.TEMPLATE=108]="TEMPLATE",e[e.TEXTAREA=109]="TEXTAREA",e[e.TFOOT=110]="TFOOT",e[e.TD=111]="TD",e[e.TH=112]="TH",e[e.THEAD=113]="THEAD",e[e.TITLE=114]="TITLE",e[e.TR=115]="TR",e[e.TRACK=116]="TRACK",e[e.TT=117]="TT",e[e.U=118]="U",e[e.UL=119]="UL",e[e.SVG=120]="SVG",e[e.VAR=121]="VAR",e[e.WBR=122]="WBR",e[e.XMP=123]="XMP"})(l||(l={}));const Gh=new Map([[v.A,l.A],[v.ADDRESS,l.ADDRESS],[v.ANNOTATION_XML,l.ANNOTATION_XML],[v.APPLET,l.APPLET],[v.AREA,l.AREA],[v.ARTICLE,l.ARTICLE],[v.ASIDE,l.ASIDE],[v.B,l.B],[v.BASE,l.BASE],[v.BASEFONT,l.BASEFONT],[v.BGSOUND,l.BGSOUND],[v.BIG,l.BIG],[v.BLOCKQUOTE,l.BLOCKQUOTE],[v.BODY,l.BODY],[v.BR,l.BR],[v.BUTTON,l.BUTTON],[v.CAPTION,l.CAPTION],[v.CENTER,l.CENTER],[v.CODE,l.CODE],[v.COL,l.COL],[v.COLGROUP,l.COLGROUP],[v.DD,l.DD],[v.DESC,l.DESC],[v.DETAILS,l.DETAILS],[v.DIALOG,l.DIALOG],[v.DIR,l.DIR],[v.DIV,l.DIV],[v.DL,l.DL],[v.DT,l.DT],[v.EM,l.EM],[v.EMBED,l.EMBED],[v.FIELDSET,l.FIELDSET],[v.FIGCAPTION,l.FIGCAPTION],[v.FIGURE,l.FIGURE],[v.FONT,l.FONT],[v.FOOTER,l.FOOTER],[v.FOREIGN_OBJECT,l.FOREIGN_OBJECT],[v.FORM,l.FORM],[v.FRAME,l.FRAME],[v.FRAMESET,l.FRAMESET],[v.H1,l.H1],[v.H2,l.H2],[v.H3,l.H3],[v.H4,l.H4],[v.H5,l.H5],[v.H6,l.H6],[v.HEAD,l.HEAD],[v.HEADER,l.HEADER],[v.HGROUP,l.HGROUP],[v.HR,l.HR],[v.HTML,l.HTML],[v.I,l.I],[v.IMG,l.IMG],[v.IMAGE,l.IMAGE],[v.INPUT,l.INPUT],[v.IFRAME,l.IFRAME],[v.KEYGEN,l.KEYGEN],[v.LABEL,l.LABEL],[v.LI,l.LI],[v.LINK,l.LINK],[v.LISTING,l.LISTING],[v.MAIN,l.MAIN],[v.MALIGNMARK,l.MALIGNMARK],[v.MARQUEE,l.MARQUEE],[v.MATH,l.MATH],[v.MENU,l.MENU],[v.META,l.META],[v.MGLYPH,l.MGLYPH],[v.MI,l.MI],[v.MO,l.MO],[v.MN,l.MN],[v.MS,l.MS],[v.MTEXT,l.MTEXT],[v.NAV,l.NAV],[v.NOBR,l.NOBR],[v.NOFRAMES,l.NOFRAMES],[v.NOEMBED,l.NOEMBED],[v.NOSCRIPT,l.NOSCRIPT],[v.OBJECT,l.OBJECT],[v.OL,l.OL],[v.OPTGROUP,l.OPTGROUP],[v.OPTION,l.OPTION],[v.P,l.P],[v.PARAM,l.PARAM],[v.PLAINTEXT,l.PLAINTEXT],[v.PRE,l.PRE],[v.RB,l.RB],[v.RP,l.RP],[v.RT,l.RT],[v.RTC,l.RTC],[v.RUBY,l.RUBY],[v.S,l.S],[v.SCRIPT,l.SCRIPT],[v.SEARCH,l.SEARCH],[v.SECTION,l.SECTION],[v.SELECT,l.SELECT],[v.SOURCE,l.SOURCE],[v.SMALL,l.SMALL],[v.SPAN,l.SPAN],[v.STRIKE,l.STRIKE],[v.STRONG,l.STRONG],[v.STYLE,l.STYLE],[v.SUB,l.SUB],[v.SUMMARY,l.SUMMARY],[v.SUP,l.SUP],[v.TABLE,l.TABLE],[v.TBODY,l.TBODY],[v.TEMPLATE,l.TEMPLATE],[v.TEXTAREA,l.TEXTAREA],[v.TFOOT,l.TFOOT],[v.TD,l.TD],[v.TH,l.TH],[v.THEAD,l.THEAD],[v.TITLE,l.TITLE],[v.TR,l.TR],[v.TRACK,l.TRACK],[v.TT,l.TT],[v.U,l.U],[v.UL,l.UL],[v.SVG,l.SVG],[v.VAR,l.VAR],[v.WBR,l.WBR],[v.XMP,l.XMP]]);function wn(e){var t;return(t=Gh.get(e))!==null&&t!==void 0?t:l.UNKNOWN}const M=l,Qh={[O.HTML]:new Set([M.ADDRESS,M.APPLET,M.AREA,M.ARTICLE,M.ASIDE,M.BASE,M.BASEFONT,M.BGSOUND,M.BLOCKQUOTE,M.BODY,M.BR,M.BUTTON,M.CAPTION,M.CENTER,M.COL,M.COLGROUP,M.DD,M.DETAILS,M.DIR,M.DIV,M.DL,M.DT,M.EMBED,M.FIELDSET,M.FIGCAPTION,M.FIGURE,M.FOOTER,M.FORM,M.FRAME,M.FRAMESET,M.H1,M.H2,M.H3,M.H4,M.H5,M.H6,M.HEAD,M.HEADER,M.HGROUP,M.HR,M.HTML,M.IFRAME,M.IMG,M.INPUT,M.LI,M.LINK,M.LISTING,M.MAIN,M.MARQUEE,M.MENU,M.META,M.NAV,M.NOEMBED,M.NOFRAMES,M.NOSCRIPT,M.OBJECT,M.OL,M.P,M.PARAM,M.PLAINTEXT,M.PRE,M.SCRIPT,M.SECTION,M.SELECT,M.SOURCE,M.STYLE,M.SUMMARY,M.TABLE,M.TBODY,M.TD,M.TEMPLATE,M.TEXTAREA,M.TFOOT,M.TH,M.THEAD,M.TITLE,M.TR,M.TRACK,M.UL,M.WBR,M.XMP]),[O.MATHML]:new Set([M.MI,M.MO,M.MN,M.MS,M.MTEXT,M.ANNOTATION_XML]),[O.SVG]:new Set([M.TITLE,M.FOREIGN_OBJECT,M.DESC]),[O.XLINK]:new Set,[O.XML]:new Set,[O.XMLNS]:new Set},ha=new Set([M.H1,M.H2,M.H3,M.H4,M.H5,M.H6]);var E;(function(e){e[e.DATA=0]="DATA",e[e.RCDATA=1]="RCDATA",e[e.RAWTEXT=2]="RAWTEXT",e[e.SCRIPT_DATA=3]="SCRIPT_DATA",e[e.PLAINTEXT=4]="PLAINTEXT",e[e.TAG_OPEN=5]="TAG_OPEN",e[e.END_TAG_OPEN=6]="END_TAG_OPEN",e[e.TAG_NAME=7]="TAG_NAME",e[e.RCDATA_LESS_THAN_SIGN=8]="RCDATA_LESS_THAN_SIGN",e[e.RCDATA_END_TAG_OPEN=9]="RCDATA_END_TAG_OPEN",e[e.RCDATA_END_TAG_NAME=10]="RCDATA_END_TAG_NAME",e[e.RAWTEXT_LESS_THAN_SIGN=11]="RAWTEXT_LESS_THAN_SIGN",e[e.RAWTEXT_END_TAG_OPEN=12]="RAWTEXT_END_TAG_OPEN",e[e.RAWTEXT_END_TAG_NAME=13]="RAWTEXT_END_TAG_NAME",e[e.SCRIPT_DATA_LESS_THAN_SIGN=14]="SCRIPT_DATA_LESS_THAN_SIGN",e[e.SCRIPT_DATA_END_TAG_OPEN=15]="SCRIPT_DATA_END_TAG_OPEN",e[e.SCRIPT_DATA_END_TAG_NAME=16]="SCRIPT_DATA_END_TAG_NAME",e[e.SCRIPT_DATA_ESCAPE_START=17]="SCRIPT_DATA_ESCAPE_START",e[e.SCRIPT_DATA_ESCAPE_START_DASH=18]="SCRIPT_DATA_ESCAPE_START_DASH",e[e.SCRIPT_DATA_ESCAPED=19]="SCRIPT_DATA_ESCAPED",e[e.SCRIPT_DATA_ESCAPED_DASH=20]="SCRIPT_DATA_ESCAPED_DASH",e[e.SCRIPT_DATA_ESCAPED_DASH_DASH=21]="SCRIPT_DATA_ESCAPED_DASH_DASH",e[e.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN=22]="SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN",e[e.SCRIPT_DATA_ESCAPED_END_TAG_OPEN=23]="SCRIPT_DATA_ESCAPED_END_TAG_OPEN",e[e.SCRIPT_DATA_ESCAPED_END_TAG_NAME=24]="SCRIPT_DATA_ESCAPED_END_TAG_NAME",e[e.SCRIPT_DATA_DOUBLE_ESCAPE_START=25]="SCRIPT_DATA_DOUBLE_ESCAPE_START",e[e.SCRIPT_DATA_DOUBLE_ESCAPED=26]="SCRIPT_DATA_DOUBLE_ESCAPED",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH=27]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH=28]="SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH",e[e.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN=29]="SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN",e[e.SCRIPT_DATA_DOUBLE_ESCAPE_END=30]="SCRIPT_DATA_DOUBLE_ESCAPE_END",e[e.BEFORE_ATTRIBUTE_NAME=31]="BEFORE_ATTRIBUTE_NAME",e[e.ATTRIBUTE_NAME=32]="ATTRIBUTE_NAME",e[e.AFTER_ATTRIBUTE_NAME=33]="AFTER_ATTRIBUTE_NAME",e[e.BEFORE_ATTRIBUTE_VALUE=34]="BEFORE_ATTRIBUTE_VALUE",e[e.ATTRIBUTE_VALUE_DOUBLE_QUOTED=35]="ATTRIBUTE_VALUE_DOUBLE_QUOTED",e[e.ATTRIBUTE_VALUE_SINGLE_QUOTED=36]="ATTRIBUTE_VALUE_SINGLE_QUOTED",e[e.ATTRIBUTE_VALUE_UNQUOTED=37]="ATTRIBUTE_VALUE_UNQUOTED",e[e.AFTER_ATTRIBUTE_VALUE_QUOTED=38]="AFTER_ATTRIBUTE_VALUE_QUOTED",e[e.SELF_CLOSING_START_TAG=39]="SELF_CLOSING_START_TAG",e[e.BOGUS_COMMENT=40]="BOGUS_COMMENT",e[e.MARKUP_DECLARATION_OPEN=41]="MARKUP_DECLARATION_OPEN",e[e.COMMENT_START=42]="COMMENT_START",e[e.COMMENT_START_DASH=43]="COMMENT_START_DASH",e[e.COMMENT=44]="COMMENT",e[e.COMMENT_LESS_THAN_SIGN=45]="COMMENT_LESS_THAN_SIGN",e[e.COMMENT_LESS_THAN_SIGN_BANG=46]="COMMENT_LESS_THAN_SIGN_BANG",e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH=47]="COMMENT_LESS_THAN_SIGN_BANG_DASH",e[e.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH=48]="COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH",e[e.COMMENT_END_DASH=49]="COMMENT_END_DASH",e[e.COMMENT_END=50]="COMMENT_END",e[e.COMMENT_END_BANG=51]="COMMENT_END_BANG",e[e.DOCTYPE=52]="DOCTYPE",e[e.BEFORE_DOCTYPE_NAME=53]="BEFORE_DOCTYPE_NAME",e[e.DOCTYPE_NAME=54]="DOCTYPE_NAME",e[e.AFTER_DOCTYPE_NAME=55]="AFTER_DOCTYPE_NAME",e[e.AFTER_DOCTYPE_PUBLIC_KEYWORD=56]="AFTER_DOCTYPE_PUBLIC_KEYWORD",e[e.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER=57]="BEFORE_DOCTYPE_PUBLIC_IDENTIFIER",e[e.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED=58]="DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED",e[e.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED=59]="DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED",e[e.AFTER_DOCTYPE_PUBLIC_IDENTIFIER=60]="AFTER_DOCTYPE_PUBLIC_IDENTIFIER",e[e.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS=61]="BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS",e[e.AFTER_DOCTYPE_SYSTEM_KEYWORD=62]="AFTER_DOCTYPE_SYSTEM_KEYWORD",e[e.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER=63]="BEFORE_DOCTYPE_SYSTEM_IDENTIFIER",e[e.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED=64]="DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED",e[e.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED=65]="DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED",e[e.AFTER_DOCTYPE_SYSTEM_IDENTIFIER=66]="AFTER_DOCTYPE_SYSTEM_IDENTIFIER",e[e.BOGUS_DOCTYPE=67]="BOGUS_DOCTYPE",e[e.CDATA_SECTION=68]="CDATA_SECTION",e[e.CDATA_SECTION_BRACKET=69]="CDATA_SECTION_BRACKET",e[e.CDATA_SECTION_END=70]="CDATA_SECTION_END",e[e.CHARACTER_REFERENCE=71]="CHARACTER_REFERENCE",e[e.AMBIGUOUS_AMPERSAND=72]="AMBIGUOUS_AMPERSAND"})(E||(E={}));const Ce={DATA:E.DATA,RCDATA:E.RCDATA,RAWTEXT:E.RAWTEXT,SCRIPT_DATA:E.SCRIPT_DATA,PLAINTEXT:E.PLAINTEXT,CDATA_SECTION:E.CDATA_SECTION};function Kh(e){return e>=g.DIGIT_0&&e<=g.DIGIT_9}function Gn(e){return e>=g.LATIN_CAPITAL_A&&e<=g.LATIN_CAPITAL_Z}function Xh(e){return e>=g.LATIN_SMALL_A&&e<=g.LATIN_SMALL_Z}function Rt(e){return Xh(e)||Gn(e)}function pu(e){return Rt(e)||Kh(e)}function qr(e){return e+32}function mu(e){return e===g.SPACE||e===g.LINE_FEED||e===g.TABULATION||e===g.FORM_FEED}function gu(e){return mu(e)||e===g.SOLIDUS||e===g.GREATER_THAN_SIGN}function Zh(e){return e===g.NULL?L.nullCharacterReference:e>1114111?L.characterReferenceOutsideUnicodeRange:cu(e)?L.surrogateCharacterReference:fu(e)?L.noncharacterCharacterReference:du(e)||e===g.CARRIAGE_RETURN?L.controlCharacterReference:null}class Jh{constructor(t,n){this.options=t,this.handler=n,this.paused=!1,this.inLoop=!1,this.inForeignNode=!1,this.lastStartTagName="",this.active=!1,this.state=E.DATA,this.returnState=E.DATA,this.entityStartPos=0,this.consumedAfterSnapshot=-1,this.currentCharacterToken=null,this.currentToken=null,this.currentAttr={name:"",value:""},this.preprocessor=new Fh(n),this.currentLocation=this.getCurrentLocation(-1),this.entityDecoder=new qh(Hh,(r,i)=>{this.preprocessor.pos=this.entityStartPos+i-1,this._flushCodePointConsumedAsCharacterReference(r)},n.onParseError?{missingSemicolonAfterCharacterReference:()=>{this._err(L.missingSemicolonAfterCharacterReference,1)},absenceOfDigitsInNumericCharacterReference:r=>{this._err(L.absenceOfDigitsInNumericCharacterReference,this.entityStartPos-this.preprocessor.pos+r)},validateNumericCharacterReference:r=>{const i=Zh(r);i&&this._err(i,1)}}:void 0)}_err(t,n=0){var r,i;(i=(r=this.handler).onParseError)===null||i===void 0||i.call(r,this.preprocessor.getError(t,n))}getCurrentLocation(t){return this.options.sourceCodeLocationInfo?{startLine:this.preprocessor.line,startCol:this.preprocessor.col-t,startOffset:this.preprocessor.offset-t,endLine:-1,endCol:-1,endOffset:-1}:null}_runParsingLoop(){if(!this.inLoop){for(this.inLoop=!0;this.active&&!this.paused;){this.consumedAfterSnapshot=0;const t=this._consume();this._ensureHibernation()||this._callState(t)}this.inLoop=!1}}pause(){this.paused=!0}resume(t){if(!this.paused)throw new Error("Parser was already resumed");this.paused=!1,!this.inLoop&&(this._runParsingLoop(),this.paused||t?.())}write(t,n,r){this.active=!0,this.preprocessor.write(t,n),this._runParsingLoop(),this.paused||r?.()}insertHtmlAtCurrentPos(t){this.active=!0,this.preprocessor.insertHtmlAtCurrentPos(t),this._runParsingLoop()}_ensureHibernation(){return this.preprocessor.endOfChunkHit?(this.preprocessor.retreat(this.consumedAfterSnapshot),this.consumedAfterSnapshot=0,this.active=!1,!0):!1}_consume(){return this.consumedAfterSnapshot++,this.preprocessor.advance()}_advanceBy(t){this.consumedAfterSnapshot+=t;for(let n=0;n<t;n++)this.preprocessor.advance()}_consumeSequenceIfMatch(t,n){return this.preprocessor.startsWith(t,n)?(this._advanceBy(t.length-1),!0):!1}_createStartTagToken(){this.currentToken={type:te.START_TAG,tagName:"",tagID:l.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(1)}}_createEndTagToken(){this.currentToken={type:te.END_TAG,tagName:"",tagID:l.UNKNOWN,selfClosing:!1,ackSelfClosing:!1,attrs:[],location:this.getCurrentLocation(2)}}_createCommentToken(t){this.currentToken={type:te.COMMENT,data:"",location:this.getCurrentLocation(t)}}_createDoctypeToken(t){this.currentToken={type:te.DOCTYPE,name:t,forceQuirks:!1,publicId:null,systemId:null,location:this.currentLocation}}_createCharacterToken(t,n){this.currentCharacterToken={type:t,chars:n,location:this.currentLocation}}_createAttr(t){this.currentAttr={name:t,value:""},this.currentLocation=this.getCurrentLocation(0)}_leaveAttrName(){var t,n;const r=this.currentToken;if(hu(r,this.currentAttr.name)===null){if(r.attrs.push(this.currentAttr),r.location&&this.currentLocation){const i=(t=(n=r.location).attrs)!==null&&t!==void 0?t:n.attrs=Object.create(null);i[this.currentAttr.name]=this.currentLocation,this._leaveAttrValue()}}else this._err(L.duplicateAttribute)}_leaveAttrValue(){this.currentLocation&&(this.currentLocation.endLine=this.preprocessor.line,this.currentLocation.endCol=this.preprocessor.col,this.currentLocation.endOffset=this.preprocessor.offset)}prepareToken(t){this._emitCurrentCharacterToken(t.location),this.currentToken=null,t.location&&(t.location.endLine=this.preprocessor.line,t.location.endCol=this.preprocessor.col+1,t.location.endOffset=this.preprocessor.offset+1),this.currentLocation=this.getCurrentLocation(-1)}emitCurrentTagToken(){const t=this.currentToken;this.prepareToken(t),t.tagID=wn(t.tagName),t.type===te.START_TAG?(this.lastStartTagName=t.tagName,this.handler.onStartTag(t)):(t.attrs.length>0&&this._err(L.endTagWithAttributes),t.selfClosing&&this._err(L.endTagWithTrailingSolidus),this.handler.onEndTag(t)),this.preprocessor.dropParsedChunk()}emitCurrentComment(t){this.prepareToken(t),this.handler.onComment(t),this.preprocessor.dropParsedChunk()}emitCurrentDoctype(t){this.prepareToken(t),this.handler.onDoctype(t),this.preprocessor.dropParsedChunk()}_emitCurrentCharacterToken(t){if(this.currentCharacterToken){switch(t&&this.currentCharacterToken.location&&(this.currentCharacterToken.location.endLine=t.startLine,this.currentCharacterToken.location.endCol=t.startCol,this.currentCharacterToken.location.endOffset=t.startOffset),this.currentCharacterToken.type){case te.CHARACTER:{this.handler.onCharacter(this.currentCharacterToken);break}case te.NULL_CHARACTER:{this.handler.onNullCharacter(this.currentCharacterToken);break}case te.WHITESPACE_CHARACTER:{this.handler.onWhitespaceCharacter(this.currentCharacterToken);break}}this.currentCharacterToken=null}}_emitEOFToken(){const t=this.getCurrentLocation(0);t&&(t.endLine=t.startLine,t.endCol=t.startCol,t.endOffset=t.startOffset),this._emitCurrentCharacterToken(t),this.handler.onEof({type:te.EOF,location:t}),this.active=!1}_appendCharToCurrentCharacterToken(t,n){if(this.currentCharacterToken)if(this.currentCharacterToken.type===t){this.currentCharacterToken.chars+=n;return}else this.currentLocation=this.getCurrentLocation(0),this._emitCurrentCharacterToken(this.currentLocation),this.preprocessor.dropParsedChunk();this._createCharacterToken(t,n)}_emitCodePoint(t){const n=mu(t)?te.WHITESPACE_CHARACTER:t===g.NULL?te.NULL_CHARACTER:te.CHARACTER;this._appendCharToCurrentCharacterToken(n,String.fromCodePoint(t))}_emitChars(t){this._appendCharToCurrentCharacterToken(te.CHARACTER,t)}_startCharacterReference(){this.returnState=this.state,this.state=E.CHARACTER_REFERENCE,this.entityStartPos=this.preprocessor.pos,this.entityDecoder.startEntity(this._isCharacterReferenceInAttribute()?xt.Attribute:xt.Legacy)}_isCharacterReferenceInAttribute(){return this.returnState===E.ATTRIBUTE_VALUE_DOUBLE_QUOTED||this.returnState===E.ATTRIBUTE_VALUE_SINGLE_QUOTED||this.returnState===E.ATTRIBUTE_VALUE_UNQUOTED}_flushCodePointConsumedAsCharacterReference(t){this._isCharacterReferenceInAttribute()?this.currentAttr.value+=String.fromCodePoint(t):this._emitCodePoint(t)}_callState(t){switch(this.state){case E.DATA:{this._stateData(t);break}case E.RCDATA:{this._stateRcdata(t);break}case E.RAWTEXT:{this._stateRawtext(t);break}case E.SCRIPT_DATA:{this._stateScriptData(t);break}case E.PLAINTEXT:{this._statePlaintext(t);break}case E.TAG_OPEN:{this._stateTagOpen(t);break}case E.END_TAG_OPEN:{this._stateEndTagOpen(t);break}case E.TAG_NAME:{this._stateTagName(t);break}case E.RCDATA_LESS_THAN_SIGN:{this._stateRcdataLessThanSign(t);break}case E.RCDATA_END_TAG_OPEN:{this._stateRcdataEndTagOpen(t);break}case E.RCDATA_END_TAG_NAME:{this._stateRcdataEndTagName(t);break}case E.RAWTEXT_LESS_THAN_SIGN:{this._stateRawtextLessThanSign(t);break}case E.RAWTEXT_END_TAG_OPEN:{this._stateRawtextEndTagOpen(t);break}case E.RAWTEXT_END_TAG_NAME:{this._stateRawtextEndTagName(t);break}case E.SCRIPT_DATA_LESS_THAN_SIGN:{this._stateScriptDataLessThanSign(t);break}case E.SCRIPT_DATA_END_TAG_OPEN:{this._stateScriptDataEndTagOpen(t);break}case E.SCRIPT_DATA_END_TAG_NAME:{this._stateScriptDataEndTagName(t);break}case E.SCRIPT_DATA_ESCAPE_START:{this._stateScriptDataEscapeStart(t);break}case E.SCRIPT_DATA_ESCAPE_START_DASH:{this._stateScriptDataEscapeStartDash(t);break}case E.SCRIPT_DATA_ESCAPED:{this._stateScriptDataEscaped(t);break}case E.SCRIPT_DATA_ESCAPED_DASH:{this._stateScriptDataEscapedDash(t);break}case E.SCRIPT_DATA_ESCAPED_DASH_DASH:{this._stateScriptDataEscapedDashDash(t);break}case E.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataEscapedLessThanSign(t);break}case E.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:{this._stateScriptDataEscapedEndTagOpen(t);break}case E.SCRIPT_DATA_ESCAPED_END_TAG_NAME:{this._stateScriptDataEscapedEndTagName(t);break}case E.SCRIPT_DATA_DOUBLE_ESCAPE_START:{this._stateScriptDataDoubleEscapeStart(t);break}case E.SCRIPT_DATA_DOUBLE_ESCAPED:{this._stateScriptDataDoubleEscaped(t);break}case E.SCRIPT_DATA_DOUBLE_ESCAPED_DASH:{this._stateScriptDataDoubleEscapedDash(t);break}case E.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH:{this._stateScriptDataDoubleEscapedDashDash(t);break}case E.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN:{this._stateScriptDataDoubleEscapedLessThanSign(t);break}case E.SCRIPT_DATA_DOUBLE_ESCAPE_END:{this._stateScriptDataDoubleEscapeEnd(t);break}case E.BEFORE_ATTRIBUTE_NAME:{this._stateBeforeAttributeName(t);break}case E.ATTRIBUTE_NAME:{this._stateAttributeName(t);break}case E.AFTER_ATTRIBUTE_NAME:{this._stateAfterAttributeName(t);break}case E.BEFORE_ATTRIBUTE_VALUE:{this._stateBeforeAttributeValue(t);break}case E.ATTRIBUTE_VALUE_DOUBLE_QUOTED:{this._stateAttributeValueDoubleQuoted(t);break}case E.ATTRIBUTE_VALUE_SINGLE_QUOTED:{this._stateAttributeValueSingleQuoted(t);break}case E.ATTRIBUTE_VALUE_UNQUOTED:{this._stateAttributeValueUnquoted(t);break}case E.AFTER_ATTRIBUTE_VALUE_QUOTED:{this._stateAfterAttributeValueQuoted(t);break}case E.SELF_CLOSING_START_TAG:{this._stateSelfClosingStartTag(t);break}case E.BOGUS_COMMENT:{this._stateBogusComment(t);break}case E.MARKUP_DECLARATION_OPEN:{this._stateMarkupDeclarationOpen(t);break}case E.COMMENT_START:{this._stateCommentStart(t);break}case E.COMMENT_START_DASH:{this._stateCommentStartDash(t);break}case E.COMMENT:{this._stateComment(t);break}case E.COMMENT_LESS_THAN_SIGN:{this._stateCommentLessThanSign(t);break}case E.COMMENT_LESS_THAN_SIGN_BANG:{this._stateCommentLessThanSignBang(t);break}case E.COMMENT_LESS_THAN_SIGN_BANG_DASH:{this._stateCommentLessThanSignBangDash(t);break}case E.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:{this._stateCommentLessThanSignBangDashDash(t);break}case E.COMMENT_END_DASH:{this._stateCommentEndDash(t);break}case E.COMMENT_END:{this._stateCommentEnd(t);break}case E.COMMENT_END_BANG:{this._stateCommentEndBang(t);break}case E.DOCTYPE:{this._stateDoctype(t);break}case E.BEFORE_DOCTYPE_NAME:{this._stateBeforeDoctypeName(t);break}case E.DOCTYPE_NAME:{this._stateDoctypeName(t);break}case E.AFTER_DOCTYPE_NAME:{this._stateAfterDoctypeName(t);break}case E.AFTER_DOCTYPE_PUBLIC_KEYWORD:{this._stateAfterDoctypePublicKeyword(t);break}case E.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateBeforeDoctypePublicIdentifier(t);break}case E.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypePublicIdentifierDoubleQuoted(t);break}case E.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypePublicIdentifierSingleQuoted(t);break}case E.AFTER_DOCTYPE_PUBLIC_IDENTIFIER:{this._stateAfterDoctypePublicIdentifier(t);break}case E.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS:{this._stateBetweenDoctypePublicAndSystemIdentifiers(t);break}case E.AFTER_DOCTYPE_SYSTEM_KEYWORD:{this._stateAfterDoctypeSystemKeyword(t);break}case E.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateBeforeDoctypeSystemIdentifier(t);break}case E.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED:{this._stateDoctypeSystemIdentifierDoubleQuoted(t);break}case E.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED:{this._stateDoctypeSystemIdentifierSingleQuoted(t);break}case E.AFTER_DOCTYPE_SYSTEM_IDENTIFIER:{this._stateAfterDoctypeSystemIdentifier(t);break}case E.BOGUS_DOCTYPE:{this._stateBogusDoctype(t);break}case E.CDATA_SECTION:{this._stateCdataSection(t);break}case E.CDATA_SECTION_BRACKET:{this._stateCdataSectionBracket(t);break}case E.CDATA_SECTION_END:{this._stateCdataSectionEnd(t);break}case E.CHARACTER_REFERENCE:{this._stateCharacterReference();break}case E.AMBIGUOUS_AMPERSAND:{this._stateAmbiguousAmpersand(t);break}default:throw new Error("Unknown state")}}_stateData(t){switch(t){case g.LESS_THAN_SIGN:{this.state=E.TAG_OPEN;break}case g.AMPERSAND:{this._startCharacterReference();break}case g.NULL:{this._err(L.unexpectedNullCharacter),this._emitCodePoint(t);break}case g.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRcdata(t){switch(t){case g.AMPERSAND:{this._startCharacterReference();break}case g.LESS_THAN_SIGN:{this.state=E.RCDATA_LESS_THAN_SIGN;break}case g.NULL:{this._err(L.unexpectedNullCharacter),this._emitChars(ke);break}case g.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateRawtext(t){switch(t){case g.LESS_THAN_SIGN:{this.state=E.RAWTEXT_LESS_THAN_SIGN;break}case g.NULL:{this._err(L.unexpectedNullCharacter),this._emitChars(ke);break}case g.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptData(t){switch(t){case g.LESS_THAN_SIGN:{this.state=E.SCRIPT_DATA_LESS_THAN_SIGN;break}case g.NULL:{this._err(L.unexpectedNullCharacter),this._emitChars(ke);break}case g.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_statePlaintext(t){switch(t){case g.NULL:{this._err(L.unexpectedNullCharacter),this._emitChars(ke);break}case g.EOF:{this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateTagOpen(t){if(Rt(t))this._createStartTagToken(),this.state=E.TAG_NAME,this._stateTagName(t);else switch(t){case g.EXCLAMATION_MARK:{this.state=E.MARKUP_DECLARATION_OPEN;break}case g.SOLIDUS:{this.state=E.END_TAG_OPEN;break}case g.QUESTION_MARK:{this._err(L.unexpectedQuestionMarkInsteadOfTagName),this._createCommentToken(1),this.state=E.BOGUS_COMMENT,this._stateBogusComment(t);break}case g.EOF:{this._err(L.eofBeforeTagName),this._emitChars("<"),this._emitEOFToken();break}default:this._err(L.invalidFirstCharacterOfTagName),this._emitChars("<"),this.state=E.DATA,this._stateData(t)}}_stateEndTagOpen(t){if(Rt(t))this._createEndTagToken(),this.state=E.TAG_NAME,this._stateTagName(t);else switch(t){case g.GREATER_THAN_SIGN:{this._err(L.missingEndTagName),this.state=E.DATA;break}case g.EOF:{this._err(L.eofBeforeTagName),this._emitChars("</"),this._emitEOFToken();break}default:this._err(L.invalidFirstCharacterOfTagName),this._createCommentToken(2),this.state=E.BOGUS_COMMENT,this._stateBogusComment(t)}}_stateTagName(t){const n=this.currentToken;switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:{this.state=E.BEFORE_ATTRIBUTE_NAME;break}case g.SOLIDUS:{this.state=E.SELF_CLOSING_START_TAG;break}case g.GREATER_THAN_SIGN:{this.state=E.DATA,this.emitCurrentTagToken();break}case g.NULL:{this._err(L.unexpectedNullCharacter),n.tagName+=ke;break}case g.EOF:{this._err(L.eofInTag),this._emitEOFToken();break}default:n.tagName+=String.fromCodePoint(Gn(t)?qr(t):t)}}_stateRcdataLessThanSign(t){t===g.SOLIDUS?this.state=E.RCDATA_END_TAG_OPEN:(this._emitChars("<"),this.state=E.RCDATA,this._stateRcdata(t))}_stateRcdataEndTagOpen(t){Rt(t)?(this.state=E.RCDATA_END_TAG_NAME,this._stateRcdataEndTagName(t)):(this._emitChars("</"),this.state=E.RCDATA,this._stateRcdata(t))}handleSpecialEndTag(t){if(!this.preprocessor.startsWith(this.lastStartTagName,!1))return!this._ensureHibernation();this._createEndTagToken();const n=this.currentToken;switch(n.tagName=this.lastStartTagName,this.preprocessor.peek(this.lastStartTagName.length)){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:return this._advanceBy(this.lastStartTagName.length),this.state=E.BEFORE_ATTRIBUTE_NAME,!1;case g.SOLIDUS:return this._advanceBy(this.lastStartTagName.length),this.state=E.SELF_CLOSING_START_TAG,!1;case g.GREATER_THAN_SIGN:return this._advanceBy(this.lastStartTagName.length),this.emitCurrentTagToken(),this.state=E.DATA,!1;default:return!this._ensureHibernation()}}_stateRcdataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=E.RCDATA,this._stateRcdata(t))}_stateRawtextLessThanSign(t){t===g.SOLIDUS?this.state=E.RAWTEXT_END_TAG_OPEN:(this._emitChars("<"),this.state=E.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagOpen(t){Rt(t)?(this.state=E.RAWTEXT_END_TAG_NAME,this._stateRawtextEndTagName(t)):(this._emitChars("</"),this.state=E.RAWTEXT,this._stateRawtext(t))}_stateRawtextEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=E.RAWTEXT,this._stateRawtext(t))}_stateScriptDataLessThanSign(t){switch(t){case g.SOLIDUS:{this.state=E.SCRIPT_DATA_END_TAG_OPEN;break}case g.EXCLAMATION_MARK:{this.state=E.SCRIPT_DATA_ESCAPE_START,this._emitChars("<!");break}default:this._emitChars("<"),this.state=E.SCRIPT_DATA,this._stateScriptData(t)}}_stateScriptDataEndTagOpen(t){Rt(t)?(this.state=E.SCRIPT_DATA_END_TAG_NAME,this._stateScriptDataEndTagName(t)):(this._emitChars("</"),this.state=E.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=E.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStart(t){t===g.HYPHEN_MINUS?(this.state=E.SCRIPT_DATA_ESCAPE_START_DASH,this._emitChars("-")):(this.state=E.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscapeStartDash(t){t===g.HYPHEN_MINUS?(this.state=E.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-")):(this.state=E.SCRIPT_DATA,this._stateScriptData(t))}_stateScriptDataEscaped(t){switch(t){case g.HYPHEN_MINUS:{this.state=E.SCRIPT_DATA_ESCAPED_DASH,this._emitChars("-");break}case g.LESS_THAN_SIGN:{this.state=E.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case g.NULL:{this._err(L.unexpectedNullCharacter),this._emitChars(ke);break}case g.EOF:{this._err(L.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataEscapedDash(t){switch(t){case g.HYPHEN_MINUS:{this.state=E.SCRIPT_DATA_ESCAPED_DASH_DASH,this._emitChars("-");break}case g.LESS_THAN_SIGN:{this.state=E.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case g.NULL:{this._err(L.unexpectedNullCharacter),this.state=E.SCRIPT_DATA_ESCAPED,this._emitChars(ke);break}case g.EOF:{this._err(L.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=E.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedDashDash(t){switch(t){case g.HYPHEN_MINUS:{this._emitChars("-");break}case g.LESS_THAN_SIGN:{this.state=E.SCRIPT_DATA_ESCAPED_LESS_THAN_SIGN;break}case g.GREATER_THAN_SIGN:{this.state=E.SCRIPT_DATA,this._emitChars(">");break}case g.NULL:{this._err(L.unexpectedNullCharacter),this.state=E.SCRIPT_DATA_ESCAPED,this._emitChars(ke);break}case g.EOF:{this._err(L.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=E.SCRIPT_DATA_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataEscapedLessThanSign(t){t===g.SOLIDUS?this.state=E.SCRIPT_DATA_ESCAPED_END_TAG_OPEN:Rt(t)?(this._emitChars("<"),this.state=E.SCRIPT_DATA_DOUBLE_ESCAPE_START,this._stateScriptDataDoubleEscapeStart(t)):(this._emitChars("<"),this.state=E.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagOpen(t){Rt(t)?(this.state=E.SCRIPT_DATA_ESCAPED_END_TAG_NAME,this._stateScriptDataEscapedEndTagName(t)):(this._emitChars("</"),this.state=E.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataEscapedEndTagName(t){this.handleSpecialEndTag(t)&&(this._emitChars("</"),this.state=E.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscapeStart(t){if(this.preprocessor.startsWith(We.SCRIPT,!1)&&gu(this.preprocessor.peek(We.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<We.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED}else this._ensureHibernation()||(this.state=E.SCRIPT_DATA_ESCAPED,this._stateScriptDataEscaped(t))}_stateScriptDataDoubleEscaped(t){switch(t){case g.HYPHEN_MINUS:{this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED_DASH,this._emitChars("-");break}case g.LESS_THAN_SIGN:{this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case g.NULL:{this._err(L.unexpectedNullCharacter),this._emitChars(ke);break}case g.EOF:{this._err(L.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDash(t){switch(t){case g.HYPHEN_MINUS:{this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED_DASH_DASH,this._emitChars("-");break}case g.LESS_THAN_SIGN:{this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case g.NULL:{this._err(L.unexpectedNullCharacter),this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(ke);break}case g.EOF:{this._err(L.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedDashDash(t){switch(t){case g.HYPHEN_MINUS:{this._emitChars("-");break}case g.LESS_THAN_SIGN:{this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED_LESS_THAN_SIGN,this._emitChars("<");break}case g.GREATER_THAN_SIGN:{this.state=E.SCRIPT_DATA,this._emitChars(">");break}case g.NULL:{this._err(L.unexpectedNullCharacter),this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitChars(ke);break}case g.EOF:{this._err(L.eofInScriptHtmlCommentLikeText),this._emitEOFToken();break}default:this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED,this._emitCodePoint(t)}}_stateScriptDataDoubleEscapedLessThanSign(t){t===g.SOLIDUS?(this.state=E.SCRIPT_DATA_DOUBLE_ESCAPE_END,this._emitChars("/")):(this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateScriptDataDoubleEscapeEnd(t){if(this.preprocessor.startsWith(We.SCRIPT,!1)&&gu(this.preprocessor.peek(We.SCRIPT.length))){this._emitCodePoint(t);for(let n=0;n<We.SCRIPT.length;n++)this._emitCodePoint(this._consume());this.state=E.SCRIPT_DATA_ESCAPED}else this._ensureHibernation()||(this.state=E.SCRIPT_DATA_DOUBLE_ESCAPED,this._stateScriptDataDoubleEscaped(t))}_stateBeforeAttributeName(t){switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:break;case g.SOLIDUS:case g.GREATER_THAN_SIGN:case g.EOF:{this.state=E.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case g.EQUALS_SIGN:{this._err(L.unexpectedEqualsSignBeforeAttributeName),this._createAttr("="),this.state=E.ATTRIBUTE_NAME;break}default:this._createAttr(""),this.state=E.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateAttributeName(t){switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:case g.SOLIDUS:case g.GREATER_THAN_SIGN:case g.EOF:{this._leaveAttrName(),this.state=E.AFTER_ATTRIBUTE_NAME,this._stateAfterAttributeName(t);break}case g.EQUALS_SIGN:{this._leaveAttrName(),this.state=E.BEFORE_ATTRIBUTE_VALUE;break}case g.QUOTATION_MARK:case g.APOSTROPHE:case g.LESS_THAN_SIGN:{this._err(L.unexpectedCharacterInAttributeName),this.currentAttr.name+=String.fromCodePoint(t);break}case g.NULL:{this._err(L.unexpectedNullCharacter),this.currentAttr.name+=ke;break}default:this.currentAttr.name+=String.fromCodePoint(Gn(t)?qr(t):t)}}_stateAfterAttributeName(t){switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:break;case g.SOLIDUS:{this.state=E.SELF_CLOSING_START_TAG;break}case g.EQUALS_SIGN:{this.state=E.BEFORE_ATTRIBUTE_VALUE;break}case g.GREATER_THAN_SIGN:{this.state=E.DATA,this.emitCurrentTagToken();break}case g.EOF:{this._err(L.eofInTag),this._emitEOFToken();break}default:this._createAttr(""),this.state=E.ATTRIBUTE_NAME,this._stateAttributeName(t)}}_stateBeforeAttributeValue(t){switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:break;case g.QUOTATION_MARK:{this.state=E.ATTRIBUTE_VALUE_DOUBLE_QUOTED;break}case g.APOSTROPHE:{this.state=E.ATTRIBUTE_VALUE_SINGLE_QUOTED;break}case g.GREATER_THAN_SIGN:{this._err(L.missingAttributeValue),this.state=E.DATA,this.emitCurrentTagToken();break}default:this.state=E.ATTRIBUTE_VALUE_UNQUOTED,this._stateAttributeValueUnquoted(t)}}_stateAttributeValueDoubleQuoted(t){switch(t){case g.QUOTATION_MARK:{this.state=E.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case g.AMPERSAND:{this._startCharacterReference();break}case g.NULL:{this._err(L.unexpectedNullCharacter),this.currentAttr.value+=ke;break}case g.EOF:{this._err(L.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueSingleQuoted(t){switch(t){case g.APOSTROPHE:{this.state=E.AFTER_ATTRIBUTE_VALUE_QUOTED;break}case g.AMPERSAND:{this._startCharacterReference();break}case g.NULL:{this._err(L.unexpectedNullCharacter),this.currentAttr.value+=ke;break}case g.EOF:{this._err(L.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAttributeValueUnquoted(t){switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:{this._leaveAttrValue(),this.state=E.BEFORE_ATTRIBUTE_NAME;break}case g.AMPERSAND:{this._startCharacterReference();break}case g.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=E.DATA,this.emitCurrentTagToken();break}case g.NULL:{this._err(L.unexpectedNullCharacter),this.currentAttr.value+=ke;break}case g.QUOTATION_MARK:case g.APOSTROPHE:case g.LESS_THAN_SIGN:case g.EQUALS_SIGN:case g.GRAVE_ACCENT:{this._err(L.unexpectedCharacterInUnquotedAttributeValue),this.currentAttr.value+=String.fromCodePoint(t);break}case g.EOF:{this._err(L.eofInTag),this._emitEOFToken();break}default:this.currentAttr.value+=String.fromCodePoint(t)}}_stateAfterAttributeValueQuoted(t){switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:{this._leaveAttrValue(),this.state=E.BEFORE_ATTRIBUTE_NAME;break}case g.SOLIDUS:{this._leaveAttrValue(),this.state=E.SELF_CLOSING_START_TAG;break}case g.GREATER_THAN_SIGN:{this._leaveAttrValue(),this.state=E.DATA,this.emitCurrentTagToken();break}case g.EOF:{this._err(L.eofInTag),this._emitEOFToken();break}default:this._err(L.missingWhitespaceBetweenAttributes),this.state=E.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateSelfClosingStartTag(t){switch(t){case g.GREATER_THAN_SIGN:{const n=this.currentToken;n.selfClosing=!0,this.state=E.DATA,this.emitCurrentTagToken();break}case g.EOF:{this._err(L.eofInTag),this._emitEOFToken();break}default:this._err(L.unexpectedSolidusInTag),this.state=E.BEFORE_ATTRIBUTE_NAME,this._stateBeforeAttributeName(t)}}_stateBogusComment(t){const n=this.currentToken;switch(t){case g.GREATER_THAN_SIGN:{this.state=E.DATA,this.emitCurrentComment(n);break}case g.EOF:{this.emitCurrentComment(n),this._emitEOFToken();break}case g.NULL:{this._err(L.unexpectedNullCharacter),n.data+=ke;break}default:n.data+=String.fromCodePoint(t)}}_stateMarkupDeclarationOpen(t){this._consumeSequenceIfMatch(We.DASH_DASH,!0)?(this._createCommentToken(We.DASH_DASH.length+1),this.state=E.COMMENT_START):this._consumeSequenceIfMatch(We.DOCTYPE,!1)?(this.currentLocation=this.getCurrentLocation(We.DOCTYPE.length+1),this.state=E.DOCTYPE):this._consumeSequenceIfMatch(We.CDATA_START,!0)?this.inForeignNode?this.state=E.CDATA_SECTION:(this._err(L.cdataInHtmlContent),this._createCommentToken(We.CDATA_START.length+1),this.currentToken.data="[CDATA[",this.state=E.BOGUS_COMMENT):this._ensureHibernation()||(this._err(L.incorrectlyOpenedComment),this._createCommentToken(2),this.state=E.BOGUS_COMMENT,this._stateBogusComment(t))}_stateCommentStart(t){switch(t){case g.HYPHEN_MINUS:{this.state=E.COMMENT_START_DASH;break}case g.GREATER_THAN_SIGN:{this._err(L.abruptClosingOfEmptyComment),this.state=E.DATA;const n=this.currentToken;this.emitCurrentComment(n);break}default:this.state=E.COMMENT,this._stateComment(t)}}_stateCommentStartDash(t){const n=this.currentToken;switch(t){case g.HYPHEN_MINUS:{this.state=E.COMMENT_END;break}case g.GREATER_THAN_SIGN:{this._err(L.abruptClosingOfEmptyComment),this.state=E.DATA,this.emitCurrentComment(n);break}case g.EOF:{this._err(L.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=E.COMMENT,this._stateComment(t)}}_stateComment(t){const n=this.currentToken;switch(t){case g.HYPHEN_MINUS:{this.state=E.COMMENT_END_DASH;break}case g.LESS_THAN_SIGN:{n.data+="<",this.state=E.COMMENT_LESS_THAN_SIGN;break}case g.NULL:{this._err(L.unexpectedNullCharacter),n.data+=ke;break}case g.EOF:{this._err(L.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+=String.fromCodePoint(t)}}_stateCommentLessThanSign(t){const n=this.currentToken;switch(t){case g.EXCLAMATION_MARK:{n.data+="!",this.state=E.COMMENT_LESS_THAN_SIGN_BANG;break}case g.LESS_THAN_SIGN:{n.data+="<";break}default:this.state=E.COMMENT,this._stateComment(t)}}_stateCommentLessThanSignBang(t){t===g.HYPHEN_MINUS?this.state=E.COMMENT_LESS_THAN_SIGN_BANG_DASH:(this.state=E.COMMENT,this._stateComment(t))}_stateCommentLessThanSignBangDash(t){t===g.HYPHEN_MINUS?this.state=E.COMMENT_LESS_THAN_SIGN_BANG_DASH_DASH:(this.state=E.COMMENT_END_DASH,this._stateCommentEndDash(t))}_stateCommentLessThanSignBangDashDash(t){t!==g.GREATER_THAN_SIGN&&t!==g.EOF&&this._err(L.nestedComment),this.state=E.COMMENT_END,this._stateCommentEnd(t)}_stateCommentEndDash(t){const n=this.currentToken;switch(t){case g.HYPHEN_MINUS:{this.state=E.COMMENT_END;break}case g.EOF:{this._err(L.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="-",this.state=E.COMMENT,this._stateComment(t)}}_stateCommentEnd(t){const n=this.currentToken;switch(t){case g.GREATER_THAN_SIGN:{this.state=E.DATA,this.emitCurrentComment(n);break}case g.EXCLAMATION_MARK:{this.state=E.COMMENT_END_BANG;break}case g.HYPHEN_MINUS:{n.data+="-";break}case g.EOF:{this._err(L.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--",this.state=E.COMMENT,this._stateComment(t)}}_stateCommentEndBang(t){const n=this.currentToken;switch(t){case g.HYPHEN_MINUS:{n.data+="--!",this.state=E.COMMENT_END_DASH;break}case g.GREATER_THAN_SIGN:{this._err(L.incorrectlyClosedComment),this.state=E.DATA,this.emitCurrentComment(n);break}case g.EOF:{this._err(L.eofInComment),this.emitCurrentComment(n),this._emitEOFToken();break}default:n.data+="--!",this.state=E.COMMENT,this._stateComment(t)}}_stateDoctype(t){switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:{this.state=E.BEFORE_DOCTYPE_NAME;break}case g.GREATER_THAN_SIGN:{this.state=E.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t);break}case g.EOF:{this._err(L.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(L.missingWhitespaceBeforeDoctypeName),this.state=E.BEFORE_DOCTYPE_NAME,this._stateBeforeDoctypeName(t)}}_stateBeforeDoctypeName(t){if(Gn(t))this._createDoctypeToken(String.fromCharCode(qr(t))),this.state=E.DOCTYPE_NAME;else switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:break;case g.NULL:{this._err(L.unexpectedNullCharacter),this._createDoctypeToken(ke),this.state=E.DOCTYPE_NAME;break}case g.GREATER_THAN_SIGN:{this._err(L.missingDoctypeName),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=E.DATA;break}case g.EOF:{this._err(L.eofInDoctype),this._createDoctypeToken(null);const n=this.currentToken;n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._createDoctypeToken(String.fromCodePoint(t)),this.state=E.DOCTYPE_NAME}}_stateDoctypeName(t){const n=this.currentToken;switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:{this.state=E.AFTER_DOCTYPE_NAME;break}case g.GREATER_THAN_SIGN:{this.state=E.DATA,this.emitCurrentDoctype(n);break}case g.NULL:{this._err(L.unexpectedNullCharacter),n.name+=ke;break}case g.EOF:{this._err(L.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.name+=String.fromCodePoint(Gn(t)?qr(t):t)}}_stateAfterDoctypeName(t){const n=this.currentToken;switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:break;case g.GREATER_THAN_SIGN:{this.state=E.DATA,this.emitCurrentDoctype(n);break}case g.EOF:{this._err(L.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._consumeSequenceIfMatch(We.PUBLIC,!1)?this.state=E.AFTER_DOCTYPE_PUBLIC_KEYWORD:this._consumeSequenceIfMatch(We.SYSTEM,!1)?this.state=E.AFTER_DOCTYPE_SYSTEM_KEYWORD:this._ensureHibernation()||(this._err(L.invalidCharacterSequenceAfterDoctypeName),n.forceQuirks=!0,this.state=E.BOGUS_DOCTYPE,this._stateBogusDoctype(t))}}_stateAfterDoctypePublicKeyword(t){const n=this.currentToken;switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:{this.state=E.BEFORE_DOCTYPE_PUBLIC_IDENTIFIER;break}case g.QUOTATION_MARK:{this._err(L.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=E.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case g.APOSTROPHE:{this._err(L.missingWhitespaceAfterDoctypePublicKeyword),n.publicId="",this.state=E.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case g.GREATER_THAN_SIGN:{this._err(L.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=E.DATA,this.emitCurrentDoctype(n);break}case g.EOF:{this._err(L.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(L.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=E.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:break;case g.QUOTATION_MARK:{n.publicId="",this.state=E.DOCTYPE_PUBLIC_IDENTIFIER_DOUBLE_QUOTED;break}case g.APOSTROPHE:{n.publicId="",this.state=E.DOCTYPE_PUBLIC_IDENTIFIER_SINGLE_QUOTED;break}case g.GREATER_THAN_SIGN:{this._err(L.missingDoctypePublicIdentifier),n.forceQuirks=!0,this.state=E.DATA,this.emitCurrentDoctype(n);break}case g.EOF:{this._err(L.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(L.missingQuoteBeforeDoctypePublicIdentifier),n.forceQuirks=!0,this.state=E.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypePublicIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case g.QUOTATION_MARK:{this.state=E.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case g.NULL:{this._err(L.unexpectedNullCharacter),n.publicId+=ke;break}case g.GREATER_THAN_SIGN:{this._err(L.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=E.DATA;break}case g.EOF:{this._err(L.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.publicId+=String.fromCodePoint(t)}}_stateDoctypePublicIdentifierSingleQuoted(t){const n=this.currentToken;switch(t){case g.APOSTROPHE:{this.state=E.AFTER_DOCTYPE_PUBLIC_IDENTIFIER;break}case g.NULL:{this._err(L.unexpectedNullCharacter),n.publicId+=ke;break}case g.GREATER_THAN_SIGN:{this._err(L.abruptDoctypePublicIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=E.DATA;break}case g.EOF:{this._err(L.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.publicId+=String.fromCodePoint(t)}}_stateAfterDoctypePublicIdentifier(t){const n=this.currentToken;switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:{this.state=E.BETWEEN_DOCTYPE_PUBLIC_AND_SYSTEM_IDENTIFIERS;break}case g.GREATER_THAN_SIGN:{this.state=E.DATA,this.emitCurrentDoctype(n);break}case g.QUOTATION_MARK:{this._err(L.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=E.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case g.APOSTROPHE:{this._err(L.missingWhitespaceBetweenDoctypePublicAndSystemIdentifiers),n.systemId="",this.state=E.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case g.EOF:{this._err(L.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(L.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=E.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBetweenDoctypePublicAndSystemIdentifiers(t){const n=this.currentToken;switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:break;case g.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=E.DATA;break}case g.QUOTATION_MARK:{n.systemId="",this.state=E.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case g.APOSTROPHE:{n.systemId="",this.state=E.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case g.EOF:{this._err(L.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(L.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=E.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateAfterDoctypeSystemKeyword(t){const n=this.currentToken;switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:{this.state=E.BEFORE_DOCTYPE_SYSTEM_IDENTIFIER;break}case g.QUOTATION_MARK:{this._err(L.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=E.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case g.APOSTROPHE:{this._err(L.missingWhitespaceAfterDoctypeSystemKeyword),n.systemId="",this.state=E.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case g.GREATER_THAN_SIGN:{this._err(L.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=E.DATA,this.emitCurrentDoctype(n);break}case g.EOF:{this._err(L.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(L.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=E.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBeforeDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:break;case g.QUOTATION_MARK:{n.systemId="",this.state=E.DOCTYPE_SYSTEM_IDENTIFIER_DOUBLE_QUOTED;break}case g.APOSTROPHE:{n.systemId="",this.state=E.DOCTYPE_SYSTEM_IDENTIFIER_SINGLE_QUOTED;break}case g.GREATER_THAN_SIGN:{this._err(L.missingDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=E.DATA,this.emitCurrentDoctype(n);break}case g.EOF:{this._err(L.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(L.missingQuoteBeforeDoctypeSystemIdentifier),n.forceQuirks=!0,this.state=E.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateDoctypeSystemIdentifierDoubleQuoted(t){const n=this.currentToken;switch(t){case g.QUOTATION_MARK:{this.state=E.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case g.NULL:{this._err(L.unexpectedNullCharacter),n.systemId+=ke;break}case g.GREATER_THAN_SIGN:{this._err(L.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=E.DATA;break}case g.EOF:{this._err(L.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.systemId+=String.fromCodePoint(t)}}_stateDoctypeSystemIdentifierSingleQuoted(t){const n=this.currentToken;switch(t){case g.APOSTROPHE:{this.state=E.AFTER_DOCTYPE_SYSTEM_IDENTIFIER;break}case g.NULL:{this._err(L.unexpectedNullCharacter),n.systemId+=ke;break}case g.GREATER_THAN_SIGN:{this._err(L.abruptDoctypeSystemIdentifier),n.forceQuirks=!0,this.emitCurrentDoctype(n),this.state=E.DATA;break}case g.EOF:{this._err(L.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:n.systemId+=String.fromCodePoint(t)}}_stateAfterDoctypeSystemIdentifier(t){const n=this.currentToken;switch(t){case g.SPACE:case g.LINE_FEED:case g.TABULATION:case g.FORM_FEED:break;case g.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=E.DATA;break}case g.EOF:{this._err(L.eofInDoctype),n.forceQuirks=!0,this.emitCurrentDoctype(n),this._emitEOFToken();break}default:this._err(L.unexpectedCharacterAfterDoctypeSystemIdentifier),this.state=E.BOGUS_DOCTYPE,this._stateBogusDoctype(t)}}_stateBogusDoctype(t){const n=this.currentToken;switch(t){case g.GREATER_THAN_SIGN:{this.emitCurrentDoctype(n),this.state=E.DATA;break}case g.NULL:{this._err(L.unexpectedNullCharacter);break}case g.EOF:{this.emitCurrentDoctype(n),this._emitEOFToken();break}}}_stateCdataSection(t){switch(t){case g.RIGHT_SQUARE_BRACKET:{this.state=E.CDATA_SECTION_BRACKET;break}case g.EOF:{this._err(L.eofInCdata),this._emitEOFToken();break}default:this._emitCodePoint(t)}}_stateCdataSectionBracket(t){t===g.RIGHT_SQUARE_BRACKET?this.state=E.CDATA_SECTION_END:(this._emitChars("]"),this.state=E.CDATA_SECTION,this._stateCdataSection(t))}_stateCdataSectionEnd(t){switch(t){case g.GREATER_THAN_SIGN:{this.state=E.DATA;break}case g.RIGHT_SQUARE_BRACKET:{this._emitChars("]");break}default:this._emitChars("]]"),this.state=E.CDATA_SECTION,this._stateCdataSection(t)}}_stateCharacterReference(){let t=this.entityDecoder.write(this.preprocessor.html,this.preprocessor.pos);if(t<0)if(this.preprocessor.lastChunkWritten)t=this.entityDecoder.end();else{this.active=!1,this.preprocessor.pos=this.preprocessor.html.length-1,this.consumedAfterSnapshot=0,this.preprocessor.endOfChunkHit=!0;return}t===0?(this.preprocessor.pos=this.entityStartPos,this._flushCodePointConsumedAsCharacterReference(g.AMPERSAND),this.state=!this._isCharacterReferenceInAttribute()&&pu(this.preprocessor.peek(1))?E.AMBIGUOUS_AMPERSAND:this.returnState):this.state=this.returnState}_stateAmbiguousAmpersand(t){pu(t)?this._flushCodePointConsumedAsCharacterReference(t):(t===g.SEMICOLON&&this._err(L.unknownNamedCharacterReference),this.state=this.returnState,this._callState(t))}}const bu=new Set([l.DD,l.DT,l.LI,l.OPTGROUP,l.OPTION,l.P,l.RB,l.RP,l.RT,l.RTC]),Eu=new Set([...bu,l.CAPTION,l.COLGROUP,l.TBODY,l.TD,l.TFOOT,l.TH,l.THEAD,l.TR]),Wr=new Set([l.APPLET,l.CAPTION,l.HTML,l.MARQUEE,l.OBJECT,l.TABLE,l.TD,l.TEMPLATE,l.TH]),ep=new Set([...Wr,l.OL,l.UL]),tp=new Set([...Wr,l.BUTTON]),Tu=new Set([l.ANNOTATION_XML,l.MI,l.MN,l.MO,l.MS,l.MTEXT]),_u=new Set([l.DESC,l.FOREIGN_OBJECT,l.TITLE]),np=new Set([l.TR,l.TEMPLATE,l.HTML]),rp=new Set([l.TBODY,l.TFOOT,l.THEAD,l.TEMPLATE,l.HTML]),ip=new Set([l.TABLE,l.TEMPLATE,l.HTML]),ap=new Set([l.TD,l.TH]);class sp{get currentTmplContentOrNode(){return this._isInTemplate()?this.treeAdapter.getTemplateContent(this.current):this.current}constructor(t,n,r){this.treeAdapter=n,this.handler=r,this.items=[],this.tagIDs=[],this.stackTop=-1,this.tmplCount=0,this.currentTagId=l.UNKNOWN,this.current=t}_indexOf(t){return this.items.lastIndexOf(t,this.stackTop)}_isInTemplate(){return this.currentTagId===l.TEMPLATE&&this.treeAdapter.getNamespaceURI(this.current)===O.HTML}_updateCurrentElement(){this.current=this.items[this.stackTop],this.currentTagId=this.tagIDs[this.stackTop]}push(t,n){this.stackTop++,this.items[this.stackTop]=t,this.current=t,this.tagIDs[this.stackTop]=n,this.currentTagId=n,this._isInTemplate()&&this.tmplCount++,this.handler.onItemPush(t,n,!0)}pop(){const t=this.current;this.tmplCount>0&&this._isInTemplate()&&this.tmplCount--,this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,!0)}replace(t,n){const r=this._indexOf(t);this.items[r]=n,r===this.stackTop&&(this.current=n)}insertAfter(t,n,r){const i=this._indexOf(t)+1;this.items.splice(i,0,n),this.tagIDs.splice(i,0,r),this.stackTop++,i===this.stackTop&&this._updateCurrentElement(),this.current&&this.currentTagId!==void 0&&this.handler.onItemPush(this.current,this.currentTagId,i===this.stackTop)}popUntilTagNamePopped(t){let n=this.stackTop+1;do n=this.tagIDs.lastIndexOf(t,n-1);while(n>0&&this.treeAdapter.getNamespaceURI(this.items[n])!==O.HTML);this.shortenToLength(Math.max(n,0))}shortenToLength(t){for(;this.stackTop>=t;){const n=this.current;this.tmplCount>0&&this._isInTemplate()&&(this.tmplCount-=1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(n,this.stackTop<t)}}popUntilElementPopped(t){const n=this._indexOf(t);this.shortenToLength(Math.max(n,0))}popUntilPopped(t,n){const r=this._indexOfTagNames(t,n);this.shortenToLength(Math.max(r,0))}popUntilNumberedHeaderPopped(){this.popUntilPopped(ha,O.HTML)}popUntilTableCellPopped(){this.popUntilPopped(ap,O.HTML)}popAllUpToHtmlElement(){this.tmplCount=0,this.shortenToLength(1)}_indexOfTagNames(t,n){for(let r=this.stackTop;r>=0;r--)if(t.has(this.tagIDs[r])&&this.treeAdapter.getNamespaceURI(this.items[r])===n)return r;return-1}clearBackTo(t,n){const r=this._indexOfTagNames(t,n);this.shortenToLength(r+1)}clearBackToTableContext(){this.clearBackTo(ip,O.HTML)}clearBackToTableBodyContext(){this.clearBackTo(rp,O.HTML)}clearBackToTableRowContext(){this.clearBackTo(np,O.HTML)}remove(t){const n=this._indexOf(t);n>=0&&(n===this.stackTop?this.pop():(this.items.splice(n,1),this.tagIDs.splice(n,1),this.stackTop--,this._updateCurrentElement(),this.handler.onItemPop(t,!1)))}tryPeekProperlyNestedBodyElement(){return this.stackTop>=1&&this.tagIDs[1]===l.BODY?this.items[1]:null}contains(t){return this._indexOf(t)>-1}getCommonAncestor(t){const n=this._indexOf(t)-1;return n>=0?this.items[n]:null}isRootHtmlElementCurrent(){return this.stackTop===0&&this.tagIDs[0]===l.HTML}hasInDynamicScope(t,n){for(let r=this.stackTop;r>=0;r--){const i=this.tagIDs[r];switch(this.treeAdapter.getNamespaceURI(this.items[r])){case O.HTML:{if(i===t)return!0;if(n.has(i))return!1;break}case O.SVG:{if(_u.has(i))return!1;break}case O.MATHML:{if(Tu.has(i))return!1;break}}}return!0}hasInScope(t){return this.hasInDynamicScope(t,Wr)}hasInListItemScope(t){return this.hasInDynamicScope(t,ep)}hasInButtonScope(t){return this.hasInDynamicScope(t,tp)}hasNumberedHeaderInScope(){for(let t=this.stackTop;t>=0;t--){const n=this.tagIDs[t];switch(this.treeAdapter.getNamespaceURI(this.items[t])){case O.HTML:{if(ha.has(n))return!0;if(Wr.has(n))return!1;break}case O.SVG:{if(_u.has(n))return!1;break}case O.MATHML:{if(Tu.has(n))return!1;break}}}return!0}hasInTableScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===O.HTML)switch(this.tagIDs[n]){case t:return!0;case l.TABLE:case l.HTML:return!1}return!0}hasTableBodyContextInTableScope(){for(let t=this.stackTop;t>=0;t--)if(this.treeAdapter.getNamespaceURI(this.items[t])===O.HTML)switch(this.tagIDs[t]){case l.TBODY:case l.THEAD:case l.TFOOT:return!0;case l.TABLE:case l.HTML:return!1}return!0}hasInSelectScope(t){for(let n=this.stackTop;n>=0;n--)if(this.treeAdapter.getNamespaceURI(this.items[n])===O.HTML)switch(this.tagIDs[n]){case t:return!0;case l.OPTION:case l.OPTGROUP:break;default:return!1}return!0}generateImpliedEndTags(){for(;this.currentTagId!==void 0&&bu.has(this.currentTagId);)this.pop()}generateImpliedEndTagsThoroughly(){for(;this.currentTagId!==void 0&&Eu.has(this.currentTagId);)this.pop()}generateImpliedEndTagsWithExclusion(t){for(;this.currentTagId!==void 0&&this.currentTagId!==t&&Eu.has(this.currentTagId);)this.pop()}}const pa=3;var mt;(function(e){e[e.Marker=0]="Marker",e[e.Element=1]="Element"})(mt||(mt={}));const ku={type:mt.Marker};class op{constructor(t){this.treeAdapter=t,this.entries=[],this.bookmark=null}_getNoahArkConditionCandidates(t,n){const r=[],i=n.length,a=this.treeAdapter.getTagName(t),s=this.treeAdapter.getNamespaceURI(t);for(let o=0;o<this.entries.length;o++){const u=this.entries[o];if(u.type===mt.Marker)break;const{element:c}=u;if(this.treeAdapter.getTagName(c)===a&&this.treeAdapter.getNamespaceURI(c)===s){const f=this.treeAdapter.getAttrList(c);f.length===i&&r.push({idx:o,attrs:f})}}return r}_ensureNoahArkCondition(t){if(this.entries.length<pa)return;const n=this.treeAdapter.getAttrList(t),r=this._getNoahArkConditionCandidates(t,n);if(r.length<pa)return;const i=new Map(n.map(s=>[s.name,s.value]));let a=0;for(let s=0;s<r.length;s++){const o=r[s];o.attrs.every(u=>i.get(u.name)===u.value)&&(a+=1,a>=pa&&this.entries.splice(o.idx,1))}}insertMarker(){this.entries.unshift(ku)}pushElement(t,n){this._ensureNoahArkCondition(t),this.entries.unshift({type:mt.Element,element:t,token:n})}insertElementAfterBookmark(t,n){const r=this.entries.indexOf(this.bookmark);this.entries.splice(r,0,{type:mt.Element,element:t,token:n})}removeEntry(t){const n=this.entries.indexOf(t);n!==-1&&this.entries.splice(n,1)}clearToLastMarker(){const t=this.entries.indexOf(ku);t===-1?this.entries.length=0:this.entries.splice(0,t+1)}getElementEntryInScopeWithTagName(t){const n=this.entries.find(r=>r.type===mt.Marker||this.treeAdapter.getTagName(r.element)===t);return n&&n.type===mt.Element?n:null}getElementEntry(t){return this.entries.find(n=>n.type===mt.Element&&n.element===t)}}const Ot={createDocument(){return{nodeName:"#document",mode:tt.NO_QUIRKS,childNodes:[]}},createDocumentFragment(){return{nodeName:"#document-fragment",childNodes:[]}},createElement(e,t,n){return{nodeName:e,tagName:e,attrs:n,namespaceURI:t,childNodes:[],parentNode:null}},createCommentNode(e){return{nodeName:"#comment",data:e,parentNode:null}},createTextNode(e){return{nodeName:"#text",value:e,parentNode:null}},appendChild(e,t){e.childNodes.push(t),t.parentNode=e},insertBefore(e,t,n){const r=e.childNodes.indexOf(n);e.childNodes.splice(r,0,t),t.parentNode=e},setTemplateContent(e,t){e.content=t},getTemplateContent(e){return e.content},setDocumentType(e,t,n,r){const i=e.childNodes.find(a=>a.nodeName==="#documentType");if(i)i.name=t,i.publicId=n,i.systemId=r;else{const a={nodeName:"#documentType",name:t,publicId:n,systemId:r,parentNode:null};Ot.appendChild(e,a)}},setDocumentMode(e,t){e.mode=t},getDocumentMode(e){return e.mode},detachNode(e){if(e.parentNode){const t=e.parentNode.childNodes.indexOf(e);e.parentNode.childNodes.splice(t,1),e.parentNode=null}},insertText(e,t){if(e.childNodes.length>0){const n=e.childNodes[e.childNodes.length-1];if(Ot.isTextNode(n)){n.value+=t;return}}Ot.appendChild(e,Ot.createTextNode(t))},insertTextBefore(e,t,n){const r=e.childNodes[e.childNodes.indexOf(n)-1];r&&Ot.isTextNode(r)?r.value+=t:Ot.insertBefore(e,Ot.createTextNode(t),n)},adoptAttributes(e,t){const n=new Set(e.attrs.map(r=>r.name));for(let r=0;r<t.length;r++)n.has(t[r].name)||e.attrs.push(t[r])},getFirstChild(e){return e.childNodes[0]},getChildNodes(e){return e.childNodes},getParentNode(e){return e.parentNode},getAttrList(e){return e.attrs},getTagName(e){return e.tagName},getNamespaceURI(e){return e.namespaceURI},getTextNodeContent(e){return e.value},getCommentNodeContent(e){return e.data},getDocumentTypeNodeName(e){return e.name},getDocumentTypeNodePublicId(e){return e.publicId},getDocumentTypeNodeSystemId(e){return e.systemId},isTextNode(e){return e.nodeName==="#text"},isCommentNode(e){return e.nodeName==="#comment"},isDocumentTypeNode(e){return e.nodeName==="#documentType"},isElementNode(e){return Object.prototype.hasOwnProperty.call(e,"tagName")},setNodeSourceCodeLocation(e,t){e.sourceCodeLocation=t},getNodeSourceCodeLocation(e){return e.sourceCodeLocation},updateNodeSourceCodeLocation(e,t){e.sourceCodeLocation={...e.sourceCodeLocation,...t}}},xu="html",up="about:legacy-compat",lp="http://www.ibm.com/data/dtd/v11/ibmxhtml1-transitional.dtd",yu=["+//silmaril//dtd html pro v0r11 19970101//","-//as//dtd html 3.0 aswedit + extensions//","-//advasoft ltd//dtd html 3.0 aswedit + extensions//","-//ietf//dtd html 2.0 level 1//","-//ietf//dtd html 2.0 level 2//","-//ietf//dtd html 2.0 strict level 1//","-//ietf//dtd html 2.0 strict level 2//","-//ietf//dtd html 2.0 strict//","-//ietf//dtd html 2.0//","-//ietf//dtd html 2.1e//","-//ietf//dtd html 3.0//","-//ietf//dtd html 3.2 final//","-//ietf//dtd html 3.2//","-//ietf//dtd html 3//","-//ietf//dtd html level 0//","-//ietf//dtd html level 1//","-//ietf//dtd html level 2//","-//ietf//dtd html level 3//","-//ietf//dtd html strict level 0//","-//ietf//dtd html strict level 1//","-//ietf//dtd html strict level 2//","-//ietf//dtd html strict level 3//","-//ietf//dtd html strict//","-//ietf//dtd html//","-//metrius//dtd metrius presentational//","-//microsoft//dtd internet explorer 2.0 html strict//","-//microsoft//dtd internet explorer 2.0 html//","-//microsoft//dtd internet explorer 2.0 tables//","-//microsoft//dtd internet explorer 3.0 html strict//","-//microsoft//dtd internet explorer 3.0 html//","-//microsoft//dtd internet explorer 3.0 tables//","-//netscape comm. corp.//dtd html//","-//netscape comm. corp.//dtd strict html//","-//o'reilly and associates//dtd html 2.0//","-//o'reilly and associates//dtd html extended 1.0//","-//o'reilly and associates//dtd html extended relaxed 1.0//","-//sq//dtd html 2.0 hotmetal + extensions//","-//softquad software//dtd hotmetal pro 6.0::19990601::extensions to html 4.0//","-//softquad//dtd hotmetal pro 4.0::19971010::extensions to html 4.0//","-//spyglass//dtd html 2.0 extended//","-//sun microsystems corp.//dtd hotjava html//","-//sun microsystems corp.//dtd hotjava strict html//","-//w3c//dtd html 3 1995-03-24//","-//w3c//dtd html 3.2 draft//","-//w3c//dtd html 3.2 final//","-//w3c//dtd html 3.2//","-//w3c//dtd html 3.2s draft//","-//w3c//dtd html 4.0 frameset//","-//w3c//dtd html 4.0 transitional//","-//w3c//dtd html experimental 19960712//","-//w3c//dtd html experimental 970421//","-//w3c//dtd w3 html//","-//w3o//dtd w3 html 3.0//","-//webtechs//dtd mozilla html 2.0//","-//webtechs//dtd mozilla html//"],cp=[...yu,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"],dp=new Set(["-//w3o//dtd w3 html strict 3.0//en//","-/w3c/dtd html 4.0 transitional/en","html"]),wu=["-//w3c//dtd xhtml 1.0 frameset//","-//w3c//dtd xhtml 1.0 transitional//"],fp=[...wu,"-//w3c//dtd html 4.01 frameset//","-//w3c//dtd html 4.01 transitional//"];function Au(e,t){return t.some(n=>e.startsWith(n))}function hp(e){return e.name===xu&&e.publicId===null&&(e.systemId===null||e.systemId===up)}function pp(e){if(e.name!==xu)return tt.QUIRKS;const{systemId:t}=e;if(t&&t.toLowerCase()===lp)return tt.QUIRKS;let{publicId:n}=e;if(n!==null){if(n=n.toLowerCase(),dp.has(n))return tt.QUIRKS;let r=t===null?cp:yu;if(Au(n,r))return tt.QUIRKS;if(r=t===null?wu:fp,Au(n,r))return tt.LIMITED_QUIRKS}return tt.NO_QUIRKS}const Cu={TEXT_HTML:"text/html",APPLICATION_XML:"application/xhtml+xml"},mp="definitionurl",gp="definitionURL",bp=new Map(["attributeName","attributeType","baseFrequency","baseProfile","calcMode","clipPathUnits","diffuseConstant","edgeMode","filterUnits","glyphRef","gradientTransform","gradientUnits","kernelMatrix","kernelUnitLength","keyPoints","keySplines","keyTimes","lengthAdjust","limitingConeAngle","markerHeight","markerUnits","markerWidth","maskContentUnits","maskUnits","numOctaves","pathLength","patternContentUnits","patternTransform","patternUnits","pointsAtX","pointsAtY","pointsAtZ","preserveAlpha","preserveAspectRatio","primitiveUnits","refX","refY","repeatCount","repeatDur","requiredExtensions","requiredFeatures","specularConstant","specularExponent","spreadMethod","startOffset","stdDeviation","stitchTiles","surfaceScale","systemLanguage","tableValues","targetX","targetY","textLength","viewBox","viewTarget","xChannelSelector","yChannelSelector","zoomAndPan"].map(e=>[e.toLowerCase(),e])),Ep=new Map([["xlink:actuate",{prefix:"xlink",name:"actuate",namespace:O.XLINK}],["xlink:arcrole",{prefix:"xlink",name:"arcrole",namespace:O.XLINK}],["xlink:href",{prefix:"xlink",name:"href",namespace:O.XLINK}],["xlink:role",{prefix:"xlink",name:"role",namespace:O.XLINK}],["xlink:show",{prefix:"xlink",name:"show",namespace:O.XLINK}],["xlink:title",{prefix:"xlink",name:"title",namespace:O.XLINK}],["xlink:type",{prefix:"xlink",name:"type",namespace:O.XLINK}],["xml:lang",{prefix:"xml",name:"lang",namespace:O.XML}],["xml:space",{prefix:"xml",name:"space",namespace:O.XML}],["xmlns",{prefix:"",name:"xmlns",namespace:O.XMLNS}],["xmlns:xlink",{prefix:"xmlns",name:"xlink",namespace:O.XMLNS}]]),Tp=new Map(["altGlyph","altGlyphDef","altGlyphItem","animateColor","animateMotion","animateTransform","clipPath","feBlend","feColorMatrix","feComponentTransfer","feComposite","feConvolveMatrix","feDiffuseLighting","feDisplacementMap","feDistantLight","feFlood","feFuncA","feFuncB","feFuncG","feFuncR","feGaussianBlur","feImage","feMerge","feMergeNode","feMorphology","feOffset","fePointLight","feSpecularLighting","feSpotLight","feTile","feTurbulence","foreignObject","glyphRef","linearGradient","radialGradient","textPath"].map(e=>[e.toLowerCase(),e])),_p=new Set([l.B,l.BIG,l.BLOCKQUOTE,l.BODY,l.BR,l.CENTER,l.CODE,l.DD,l.DIV,l.DL,l.DT,l.EM,l.EMBED,l.H1,l.H2,l.H3,l.H4,l.H5,l.H6,l.HEAD,l.HR,l.I,l.IMG,l.LI,l.LISTING,l.MENU,l.META,l.NOBR,l.OL,l.P,l.PRE,l.RUBY,l.S,l.SMALL,l.SPAN,l.STRONG,l.STRIKE,l.SUB,l.SUP,l.TABLE,l.TT,l.U,l.UL,l.VAR]);function kp(e){const t=e.tagID;return t===l.FONT&&e.attrs.some(({name:r})=>r===Zt.COLOR||r===Zt.SIZE||r===Zt.FACE)||_p.has(t)}function Su(e){for(let t=0;t<e.attrs.length;t++)if(e.attrs[t].name===mp){e.attrs[t].name=gp;break}}function Nu(e){for(let t=0;t<e.attrs.length;t++){const n=bp.get(e.attrs[t].name);n!=null&&(e.attrs[t].name=n)}}function ma(e){for(let t=0;t<e.attrs.length;t++){const n=Ep.get(e.attrs[t].name);n&&(e.attrs[t].prefix=n.prefix,e.attrs[t].name=n.name,e.attrs[t].namespace=n.namespace)}}function xp(e){const t=Tp.get(e.tagName);t!=null&&(e.tagName=t,e.tagID=wn(e.tagName))}function yp(e,t){return t===O.MATHML&&(e===l.MI||e===l.MO||e===l.MN||e===l.MS||e===l.MTEXT)}function wp(e,t,n){if(t===O.MATHML&&e===l.ANNOTATION_XML){for(let r=0;r<n.length;r++)if(n[r].name===Zt.ENCODING){const i=n[r].value.toLowerCase();return i===Cu.TEXT_HTML||i===Cu.APPLICATION_XML}}return t===O.SVG&&(e===l.FOREIGN_OBJECT||e===l.DESC||e===l.TITLE)}function Ap(e,t,n,r){return(!r||r===O.HTML)&&wp(e,t,n)||(!r||r===O.MATHML)&&yp(e,t)}const Cp="hidden",Sp=8,Np=3;var k;(function(e){e[e.INITIAL=0]="INITIAL",e[e.BEFORE_HTML=1]="BEFORE_HTML",e[e.BEFORE_HEAD=2]="BEFORE_HEAD",e[e.IN_HEAD=3]="IN_HEAD",e[e.IN_HEAD_NO_SCRIPT=4]="IN_HEAD_NO_SCRIPT",e[e.AFTER_HEAD=5]="AFTER_HEAD",e[e.IN_BODY=6]="IN_BODY",e[e.TEXT=7]="TEXT",e[e.IN_TABLE=8]="IN_TABLE",e[e.IN_TABLE_TEXT=9]="IN_TABLE_TEXT",e[e.IN_CAPTION=10]="IN_CAPTION",e[e.IN_COLUMN_GROUP=11]="IN_COLUMN_GROUP",e[e.IN_TABLE_BODY=12]="IN_TABLE_BODY",e[e.IN_ROW=13]="IN_ROW",e[e.IN_CELL=14]="IN_CELL",e[e.IN_SELECT=15]="IN_SELECT",e[e.IN_SELECT_IN_TABLE=16]="IN_SELECT_IN_TABLE",e[e.IN_TEMPLATE=17]="IN_TEMPLATE",e[e.AFTER_BODY=18]="AFTER_BODY",e[e.IN_FRAMESET=19]="IN_FRAMESET",e[e.AFTER_FRAMESET=20]="AFTER_FRAMESET",e[e.AFTER_AFTER_BODY=21]="AFTER_AFTER_BODY",e[e.AFTER_AFTER_FRAMESET=22]="AFTER_AFTER_FRAMESET"})(k||(k={}));const Ip={startLine:-1,startCol:-1,startOffset:-1,endLine:-1,endCol:-1,endOffset:-1},Iu=new Set([l.TABLE,l.TBODY,l.TFOOT,l.THEAD,l.TR]),vu={scriptingEnabled:!0,sourceCodeLocationInfo:!1,treeAdapter:Ot,onParseError:null};class Lu{constructor(t,n,r=null,i=null){this.fragmentContext=r,this.scriptHandler=i,this.currentToken=null,this.stopped=!1,this.insertionMode=k.INITIAL,this.originalInsertionMode=k.INITIAL,this.headElement=null,this.formElement=null,this.currentNotInHTML=!1,this.tmplInsertionModeStack=[],this.pendingCharacterTokens=[],this.hasNonWhitespacePendingCharacterToken=!1,this.framesetOk=!0,this.skipNextNewLine=!1,this.fosterParentingEnabled=!1,this.options={...vu,...t},this.treeAdapter=this.options.treeAdapter,this.onParseError=this.options.onParseError,this.onParseError&&(this.options.sourceCodeLocationInfo=!0),this.document=n??this.treeAdapter.createDocument(),this.tokenizer=new Jh(this.options,this),this.activeFormattingElements=new op(this.treeAdapter),this.fragmentContextID=r?wn(this.treeAdapter.getTagName(r)):l.UNKNOWN,this._setContextModes(r??this.document,this.fragmentContextID),this.openElements=new sp(this.document,this.treeAdapter,this)}static parse(t,n){const r=new this(n);return r.tokenizer.write(t,!0),r.document}static getFragmentParser(t,n){const r={...vu,...n};t??(t=r.treeAdapter.createElement(v.TEMPLATE,O.HTML,[]));const i=r.treeAdapter.createElement("documentmock",O.HTML,[]),a=new this(r,i,t);return a.fragmentContextID===l.TEMPLATE&&a.tmplInsertionModeStack.unshift(k.IN_TEMPLATE),a._initTokenizerForFragmentParsing(),a._insertFakeRootElement(),a._resetInsertionMode(),a._findFormInFragmentContext(),a}getFragment(){const t=this.treeAdapter.getFirstChild(this.document),n=this.treeAdapter.createDocumentFragment();return this._adoptNodes(t,n),n}_err(t,n,r){var i;if(!this.onParseError)return;const a=(i=t.location)!==null&&i!==void 0?i:Ip,s={code:n,startLine:a.startLine,startCol:a.startCol,startOffset:a.startOffset,endLine:r?a.startLine:a.endLine,endCol:r?a.startCol:a.endCol,endOffset:r?a.startOffset:a.endOffset};this.onParseError(s)}onItemPush(t,n,r){var i,a;(a=(i=this.treeAdapter).onItemPush)===null||a===void 0||a.call(i,t),r&&this.openElements.stackTop>0&&this._setContextModes(t,n)}onItemPop(t,n){var r,i;if(this.options.sourceCodeLocationInfo&&this._setEndLocation(t,this.currentToken),(i=(r=this.treeAdapter).onItemPop)===null||i===void 0||i.call(r,t,this.openElements.current),n){let a,s;this.openElements.stackTop===0&&this.fragmentContext?(a=this.fragmentContext,s=this.fragmentContextID):{current:a,currentTagId:s}=this.openElements,this._setContextModes(a,s)}}_setContextModes(t,n){const r=t===this.document||t&&this.treeAdapter.getNamespaceURI(t)===O.HTML;this.currentNotInHTML=!r,this.tokenizer.inForeignNode=!r&&t!==void 0&&n!==void 0&&!this._isIntegrationPoint(n,t)}_switchToTextParsing(t,n){this._insertElement(t,O.HTML),this.tokenizer.state=n,this.originalInsertionMode=this.insertionMode,this.insertionMode=k.TEXT}switchToPlaintextParsing(){this.insertionMode=k.TEXT,this.originalInsertionMode=k.IN_BODY,this.tokenizer.state=Ce.PLAINTEXT}_getAdjustedCurrentElement(){return this.openElements.stackTop===0&&this.fragmentContext?this.fragmentContext:this.openElements.current}_findFormInFragmentContext(){let t=this.fragmentContext;for(;t;){if(this.treeAdapter.getTagName(t)===v.FORM){this.formElement=t;break}t=this.treeAdapter.getParentNode(t)}}_initTokenizerForFragmentParsing(){if(!(!this.fragmentContext||this.treeAdapter.getNamespaceURI(this.fragmentContext)!==O.HTML))switch(this.fragmentContextID){case l.TITLE:case l.TEXTAREA:{this.tokenizer.state=Ce.RCDATA;break}case l.STYLE:case l.XMP:case l.IFRAME:case l.NOEMBED:case l.NOFRAMES:case l.NOSCRIPT:{this.tokenizer.state=Ce.RAWTEXT;break}case l.SCRIPT:{this.tokenizer.state=Ce.SCRIPT_DATA;break}case l.PLAINTEXT:{this.tokenizer.state=Ce.PLAINTEXT;break}}}_setDocumentType(t){const n=t.name||"",r=t.publicId||"",i=t.systemId||"";if(this.treeAdapter.setDocumentType(this.document,n,r,i),t.location){const s=this.treeAdapter.getChildNodes(this.document).find(o=>this.treeAdapter.isDocumentTypeNode(o));s&&this.treeAdapter.setNodeSourceCodeLocation(s,t.location)}}_attachElementToTree(t,n){if(this.options.sourceCodeLocationInfo){const r=n&&{...n,startTag:n};this.treeAdapter.setNodeSourceCodeLocation(t,r)}if(this._shouldFosterParentOnInsertion())this._fosterParentElement(t);else{const r=this.openElements.currentTmplContentOrNode;this.treeAdapter.appendChild(r??this.document,t)}}_appendElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r,t.location)}_insertElement(t,n){const r=this.treeAdapter.createElement(t.tagName,n,t.attrs);this._attachElementToTree(r,t.location),this.openElements.push(r,t.tagID)}_insertFakeElement(t,n){const r=this.treeAdapter.createElement(t,O.HTML,[]);this._attachElementToTree(r,null),this.openElements.push(r,n)}_insertTemplate(t){const n=this.treeAdapter.createElement(t.tagName,O.HTML,t.attrs),r=this.treeAdapter.createDocumentFragment();this.treeAdapter.setTemplateContent(n,r),this._attachElementToTree(n,t.location),this.openElements.push(n,t.tagID),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(r,null)}_insertFakeRootElement(){const t=this.treeAdapter.createElement(v.HTML,O.HTML,[]);this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(t,null),this.treeAdapter.appendChild(this.openElements.current,t),this.openElements.push(t,l.HTML)}_appendCommentNode(t,n){const r=this.treeAdapter.createCommentNode(t.data);this.treeAdapter.appendChild(n,r),this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(r,t.location)}_insertCharacters(t){let n,r;if(this._shouldFosterParentOnInsertion()?({parent:n,beforeElement:r}=this._findFosterParentingLocation(),r?this.treeAdapter.insertTextBefore(n,t.chars,r):this.treeAdapter.insertText(n,t.chars)):(n=this.openElements.currentTmplContentOrNode,this.treeAdapter.insertText(n,t.chars)),!t.location)return;const i=this.treeAdapter.getChildNodes(n),a=r?i.lastIndexOf(r):i.length,s=i[a-1];if(this.treeAdapter.getNodeSourceCodeLocation(s)){const{endLine:u,endCol:c,endOffset:f}=t.location;this.treeAdapter.updateNodeSourceCodeLocation(s,{endLine:u,endCol:c,endOffset:f})}else this.options.sourceCodeLocationInfo&&this.treeAdapter.setNodeSourceCodeLocation(s,t.location)}_adoptNodes(t,n){for(let r=this.treeAdapter.getFirstChild(t);r;r=this.treeAdapter.getFirstChild(t))this.treeAdapter.detachNode(r),this.treeAdapter.appendChild(n,r)}_setEndLocation(t,n){if(this.treeAdapter.getNodeSourceCodeLocation(t)&&n.location){const r=n.location,i=this.treeAdapter.getTagName(t),a=n.type===te.END_TAG&&i===n.tagName?{endTag:{...r},endLine:r.endLine,endCol:r.endCol,endOffset:r.endOffset}:{endLine:r.startLine,endCol:r.startCol,endOffset:r.startOffset};this.treeAdapter.updateNodeSourceCodeLocation(t,a)}}shouldProcessStartTagTokenInForeignContent(t){if(!this.currentNotInHTML)return!1;let n,r;return this.openElements.stackTop===0&&this.fragmentContext?(n=this.fragmentContext,r=this.fragmentContextID):{current:n,currentTagId:r}=this.openElements,t.tagID===l.SVG&&this.treeAdapter.getTagName(n)===v.ANNOTATION_XML&&this.treeAdapter.getNamespaceURI(n)===O.MATHML?!1:this.tokenizer.inForeignNode||(t.tagID===l.MGLYPH||t.tagID===l.MALIGNMARK)&&r!==void 0&&!this._isIntegrationPoint(r,n,O.HTML)}_processToken(t){switch(t.type){case te.CHARACTER:{this.onCharacter(t);break}case te.NULL_CHARACTER:{this.onNullCharacter(t);break}case te.COMMENT:{this.onComment(t);break}case te.DOCTYPE:{this.onDoctype(t);break}case te.START_TAG:{this._processStartTag(t);break}case te.END_TAG:{this.onEndTag(t);break}case te.EOF:{this.onEof(t);break}case te.WHITESPACE_CHARACTER:{this.onWhitespaceCharacter(t);break}}}_isIntegrationPoint(t,n,r){const i=this.treeAdapter.getNamespaceURI(n),a=this.treeAdapter.getAttrList(n);return Ap(t,i,a,r)}_reconstructActiveFormattingElements(){const t=this.activeFormattingElements.entries.length;if(t){const n=this.activeFormattingElements.entries.findIndex(i=>i.type===mt.Marker||this.openElements.contains(i.element)),r=n===-1?t-1:n-1;for(let i=r;i>=0;i--){const a=this.activeFormattingElements.entries[i];this._insertElement(a.token,this.treeAdapter.getNamespaceURI(a.element)),a.element=this.openElements.current}}}_closeTableCell(){this.openElements.generateImpliedEndTags(),this.openElements.popUntilTableCellPopped(),this.activeFormattingElements.clearToLastMarker(),this.insertionMode=k.IN_ROW}_closePElement(){this.openElements.generateImpliedEndTagsWithExclusion(l.P),this.openElements.popUntilTagNamePopped(l.P)}_resetInsertionMode(){for(let t=this.openElements.stackTop;t>=0;t--)switch(t===0&&this.fragmentContext?this.fragmentContextID:this.openElements.tagIDs[t]){case l.TR:{this.insertionMode=k.IN_ROW;return}case l.TBODY:case l.THEAD:case l.TFOOT:{this.insertionMode=k.IN_TABLE_BODY;return}case l.CAPTION:{this.insertionMode=k.IN_CAPTION;return}case l.COLGROUP:{this.insertionMode=k.IN_COLUMN_GROUP;return}case l.TABLE:{this.insertionMode=k.IN_TABLE;return}case l.BODY:{this.insertionMode=k.IN_BODY;return}case l.FRAMESET:{this.insertionMode=k.IN_FRAMESET;return}case l.SELECT:{this._resetInsertionModeForSelect(t);return}case l.TEMPLATE:{this.insertionMode=this.tmplInsertionModeStack[0];return}case l.HTML:{this.insertionMode=this.headElement?k.AFTER_HEAD:k.BEFORE_HEAD;return}case l.TD:case l.TH:{if(t>0){this.insertionMode=k.IN_CELL;return}break}case l.HEAD:{if(t>0){this.insertionMode=k.IN_HEAD;return}break}}this.insertionMode=k.IN_BODY}_resetInsertionModeForSelect(t){if(t>0)for(let n=t-1;n>0;n--){const r=this.openElements.tagIDs[n];if(r===l.TEMPLATE)break;if(r===l.TABLE){this.insertionMode=k.IN_SELECT_IN_TABLE;return}}this.insertionMode=k.IN_SELECT}_isElementCausesFosterParenting(t){return Iu.has(t)}_shouldFosterParentOnInsertion(){return this.fosterParentingEnabled&&this.openElements.currentTagId!==void 0&&this._isElementCausesFosterParenting(this.openElements.currentTagId)}_findFosterParentingLocation(){for(let t=this.openElements.stackTop;t>=0;t--){const n=this.openElements.items[t];switch(this.openElements.tagIDs[t]){case l.TEMPLATE:{if(this.treeAdapter.getNamespaceURI(n)===O.HTML)return{parent:this.treeAdapter.getTemplateContent(n),beforeElement:null};break}case l.TABLE:{const r=this.treeAdapter.getParentNode(n);return r?{parent:r,beforeElement:n}:{parent:this.openElements.items[t-1],beforeElement:null}}}}return{parent:this.openElements.items[0],beforeElement:null}}_fosterParentElement(t){const n=this._findFosterParentingLocation();n.beforeElement?this.treeAdapter.insertBefore(n.parent,t,n.beforeElement):this.treeAdapter.appendChild(n.parent,t)}_isSpecialElement(t,n){const r=this.treeAdapter.getNamespaceURI(t);return Qh[r].has(n)}onCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){a1(this,t);return}switch(this.insertionMode){case k.INITIAL:{Qn(this,t);break}case k.BEFORE_HTML:{Kn(this,t);break}case k.BEFORE_HEAD:{Xn(this,t);break}case k.IN_HEAD:{Zn(this,t);break}case k.IN_HEAD_NO_SCRIPT:{Jn(this,t);break}case k.AFTER_HEAD:{er(this,t);break}case k.IN_BODY:case k.IN_CAPTION:case k.IN_CELL:case k.IN_TEMPLATE:{Ou(this,t);break}case k.TEXT:case k.IN_SELECT:case k.IN_SELECT_IN_TABLE:{this._insertCharacters(t);break}case k.IN_TABLE:case k.IN_TABLE_BODY:case k.IN_ROW:{Ta(this,t);break}case k.IN_TABLE_TEXT:{zu(this,t);break}case k.IN_COLUMN_GROUP:{Kr(this,t);break}case k.AFTER_BODY:{Jr(this,t);break}case k.AFTER_AFTER_BODY:{ei(this,t);break}}}onNullCharacter(t){if(this.skipNextNewLine=!1,this.tokenizer.inForeignNode){i1(this,t);return}switch(this.insertionMode){case k.INITIAL:{Qn(this,t);break}case k.BEFORE_HTML:{Kn(this,t);break}case k.BEFORE_HEAD:{Xn(this,t);break}case k.IN_HEAD:{Zn(this,t);break}case k.IN_HEAD_NO_SCRIPT:{Jn(this,t);break}case k.AFTER_HEAD:{er(this,t);break}case k.TEXT:{this._insertCharacters(t);break}case k.IN_TABLE:case k.IN_TABLE_BODY:case k.IN_ROW:{Ta(this,t);break}case k.IN_COLUMN_GROUP:{Kr(this,t);break}case k.AFTER_BODY:{Jr(this,t);break}case k.AFTER_AFTER_BODY:{ei(this,t);break}}}onComment(t){if(this.skipNextNewLine=!1,this.currentNotInHTML){ba(this,t);return}switch(this.insertionMode){case k.INITIAL:case k.BEFORE_HTML:case k.BEFORE_HEAD:case k.IN_HEAD:case k.IN_HEAD_NO_SCRIPT:case k.AFTER_HEAD:case k.IN_BODY:case k.IN_TABLE:case k.IN_CAPTION:case k.IN_COLUMN_GROUP:case k.IN_TABLE_BODY:case k.IN_ROW:case k.IN_CELL:case k.IN_SELECT:case k.IN_SELECT_IN_TABLE:case k.IN_TEMPLATE:case k.IN_FRAMESET:case k.AFTER_FRAMESET:{ba(this,t);break}case k.IN_TABLE_TEXT:{rr(this,t);break}case k.AFTER_BODY:{Mp(this,t);break}case k.AFTER_AFTER_BODY:case k.AFTER_AFTER_FRAMESET:{Bp(this,t);break}}}onDoctype(t){switch(this.skipNextNewLine=!1,this.insertionMode){case k.INITIAL:{Fp(this,t);break}case k.BEFORE_HEAD:case k.IN_HEAD:case k.IN_HEAD_NO_SCRIPT:case k.AFTER_HEAD:{this._err(t,L.misplacedDoctype);break}case k.IN_TABLE_TEXT:{rr(this,t);break}}}onStartTag(t){this.skipNextNewLine=!1,this.currentToken=t,this._processStartTag(t),t.selfClosing&&!t.ackSelfClosing&&this._err(t,L.nonVoidHtmlElementStartTagWithTrailingSolidus)}_processStartTag(t){this.shouldProcessStartTagTokenInForeignContent(t)?s1(this,t):this._startTagOutsideForeignContent(t)}_startTagOutsideForeignContent(t){switch(this.insertionMode){case k.INITIAL:{Qn(this,t);break}case k.BEFORE_HTML:{Hp(this,t);break}case k.BEFORE_HEAD:{zp(this,t);break}case k.IN_HEAD:{st(this,t);break}case k.IN_HEAD_NO_SCRIPT:{jp(this,t);break}case k.AFTER_HEAD:{qp(this,t);break}case k.IN_BODY:{He(this,t);break}case k.IN_TABLE:{An(this,t);break}case k.IN_TABLE_TEXT:{rr(this,t);break}case k.IN_CAPTION:{$m(this,t);break}case k.IN_COLUMN_GROUP:{_a(this,t);break}case k.IN_TABLE_BODY:{Xr(this,t);break}case k.IN_ROW:{Zr(this,t);break}case k.IN_CELL:{Vm(this,t);break}case k.IN_SELECT:{ju(this,t);break}case k.IN_SELECT_IN_TABLE:{Wm(this,t);break}case k.IN_TEMPLATE:{Qm(this,t);break}case k.AFTER_BODY:{Xm(this,t);break}case k.IN_FRAMESET:{Zm(this,t);break}case k.AFTER_FRAMESET:{e1(this,t);break}case k.AFTER_AFTER_BODY:{n1(this,t);break}case k.AFTER_AFTER_FRAMESET:{r1(this,t);break}}}onEndTag(t){this.skipNextNewLine=!1,this.currentToken=t,this.currentNotInHTML?o1(this,t):this._endTagOutsideForeignContent(t)}_endTagOutsideForeignContent(t){switch(this.insertionMode){case k.INITIAL:{Qn(this,t);break}case k.BEFORE_HTML:{Up(this,t);break}case k.BEFORE_HEAD:{$p(this,t);break}case k.IN_HEAD:{Yp(this,t);break}case k.IN_HEAD_NO_SCRIPT:{Vp(this,t);break}case k.AFTER_HEAD:{Wp(this,t);break}case k.IN_BODY:{Qr(this,t);break}case k.TEXT:{Rm(this,t);break}case k.IN_TABLE:{tr(this,t);break}case k.IN_TABLE_TEXT:{rr(this,t);break}case k.IN_CAPTION:{Ym(this,t);break}case k.IN_COLUMN_GROUP:{jm(this,t);break}case k.IN_TABLE_BODY:{ka(this,t);break}case k.IN_ROW:{Yu(this,t);break}case k.IN_CELL:{qm(this,t);break}case k.IN_SELECT:{Vu(this,t);break}case k.IN_SELECT_IN_TABLE:{Gm(this,t);break}case k.IN_TEMPLATE:{Km(this,t);break}case k.AFTER_BODY:{Wu(this,t);break}case k.IN_FRAMESET:{Jm(this,t);break}case k.AFTER_FRAMESET:{t1(this,t);break}case k.AFTER_AFTER_BODY:{ei(this,t);break}}}onEof(t){switch(this.insertionMode){case k.INITIAL:{Qn(this,t);break}case k.BEFORE_HTML:{Kn(this,t);break}case k.BEFORE_HEAD:{Xn(this,t);break}case k.IN_HEAD:{Zn(this,t);break}case k.IN_HEAD_NO_SCRIPT:{Jn(this,t);break}case k.AFTER_HEAD:{er(this,t);break}case k.IN_BODY:case k.IN_TABLE:case k.IN_CAPTION:case k.IN_COLUMN_GROUP:case k.IN_TABLE_BODY:case k.IN_ROW:case k.IN_CELL:case k.IN_SELECT:case k.IN_SELECT_IN_TABLE:{Hu(this,t);break}case k.TEXT:{Om(this,t);break}case k.IN_TABLE_TEXT:{rr(this,t);break}case k.IN_TEMPLATE:{qu(this,t);break}case k.AFTER_BODY:case k.IN_FRAMESET:case k.AFTER_FRAMESET:case k.AFTER_AFTER_BODY:case k.AFTER_AFTER_FRAMESET:{Ea(this,t);break}}}onWhitespaceCharacter(t){if(this.skipNextNewLine&&(this.skipNextNewLine=!1,t.chars.charCodeAt(0)===g.LINE_FEED)){if(t.chars.length===1)return;t.chars=t.chars.substr(1)}if(this.tokenizer.inForeignNode){this._insertCharacters(t);return}switch(this.insertionMode){case k.IN_HEAD:case k.IN_HEAD_NO_SCRIPT:case k.AFTER_HEAD:case k.TEXT:case k.IN_COLUMN_GROUP:case k.IN_SELECT:case k.IN_SELECT_IN_TABLE:case k.IN_FRAMESET:case k.AFTER_FRAMESET:{this._insertCharacters(t);break}case k.IN_BODY:case k.IN_CAPTION:case k.IN_CELL:case k.IN_TEMPLATE:case k.AFTER_BODY:case k.AFTER_AFTER_BODY:case k.AFTER_AFTER_FRAMESET:{Ru(this,t);break}case k.IN_TABLE:case k.IN_TABLE_BODY:case k.IN_ROW:{Ta(this,t);break}case k.IN_TABLE_TEXT:{Uu(this,t);break}}}}function vp(e,t){let n=e.activeFormattingElements.getElementEntryInScopeWithTagName(t.tagName);return n?e.openElements.contains(n.element)?e.openElements.hasInScope(t.tagID)||(n=null):(e.activeFormattingElements.removeEntry(n),n=null):Fu(e,t),n}function Lp(e,t){let n=null,r=e.openElements.stackTop;for(;r>=0;r--){const i=e.openElements.items[r];if(i===t.element)break;e._isSpecialElement(i,e.openElements.tagIDs[r])&&(n=i)}return n||(e.openElements.shortenToLength(Math.max(r,0)),e.activeFormattingElements.removeEntry(t)),n}function Rp(e,t,n){let r=t,i=e.openElements.getCommonAncestor(t);for(let a=0,s=i;s!==n;a++,s=i){i=e.openElements.getCommonAncestor(s);const o=e.activeFormattingElements.getElementEntry(s),u=o&&a>=Np;!o||u?(u&&e.activeFormattingElements.removeEntry(o),e.openElements.remove(s)):(s=Op(e,o),r===t&&(e.activeFormattingElements.bookmark=o),e.treeAdapter.detachNode(r),e.treeAdapter.appendChild(s,r),r=s)}return r}function Op(e,t){const n=e.treeAdapter.getNamespaceURI(t.element),r=e.treeAdapter.createElement(t.token.tagName,n,t.token.attrs);return e.openElements.replace(t.element,r),t.element=r,r}function Dp(e,t,n){const r=e.treeAdapter.getTagName(t),i=wn(r);if(e._isElementCausesFosterParenting(i))e._fosterParentElement(n);else{const a=e.treeAdapter.getNamespaceURI(t);i===l.TEMPLATE&&a===O.HTML&&(t=e.treeAdapter.getTemplateContent(t)),e.treeAdapter.appendChild(t,n)}}function Pp(e,t,n){const r=e.treeAdapter.getNamespaceURI(n.element),{token:i}=n,a=e.treeAdapter.createElement(i.tagName,r,i.attrs);e._adoptNodes(t,a),e.treeAdapter.appendChild(t,a),e.activeFormattingElements.insertElementAfterBookmark(a,i),e.activeFormattingElements.removeEntry(n),e.openElements.remove(n.element),e.openElements.insertAfter(t,a,i.tagID)}function ga(e,t){for(let n=0;n<Sp;n++){const r=vp(e,t);if(!r)break;const i=Lp(e,r);if(!i)break;e.activeFormattingElements.bookmark=r;const a=Rp(e,i,r.element),s=e.openElements.getCommonAncestor(r.element);e.treeAdapter.detachNode(a),s&&Dp(e,s,a),Pp(e,i,r)}}function ba(e,t){e._appendCommentNode(t,e.openElements.currentTmplContentOrNode)}function Mp(e,t){e._appendCommentNode(t,e.openElements.items[0])}function Bp(e,t){e._appendCommentNode(t,e.document)}function Ea(e,t){if(e.stopped=!0,t.location){const n=e.fragmentContext?0:2;for(let r=e.openElements.stackTop;r>=n;r--)e._setEndLocation(e.openElements.items[r],t);if(!e.fragmentContext&&e.openElements.stackTop>=0){const r=e.openElements.items[0],i=e.treeAdapter.getNodeSourceCodeLocation(r);if(i&&!i.endTag&&(e._setEndLocation(r,t),e.openElements.stackTop>=1)){const a=e.openElements.items[1],s=e.treeAdapter.getNodeSourceCodeLocation(a);s&&!s.endTag&&e._setEndLocation(a,t)}}}}function Fp(e,t){e._setDocumentType(t);const n=t.forceQuirks?tt.QUIRKS:pp(t);hp(t)||e._err(t,L.nonConformingDoctype),e.treeAdapter.setDocumentMode(e.document,n),e.insertionMode=k.BEFORE_HTML}function Qn(e,t){e._err(t,L.missingDoctype,!0),e.treeAdapter.setDocumentMode(e.document,tt.QUIRKS),e.insertionMode=k.BEFORE_HTML,e._processToken(t)}function Hp(e,t){t.tagID===l.HTML?(e._insertElement(t,O.HTML),e.insertionMode=k.BEFORE_HEAD):Kn(e,t)}function Up(e,t){const n=t.tagID;(n===l.HTML||n===l.HEAD||n===l.BODY||n===l.BR)&&Kn(e,t)}function Kn(e,t){e._insertFakeRootElement(),e.insertionMode=k.BEFORE_HEAD,e._processToken(t)}function zp(e,t){switch(t.tagID){case l.HTML:{He(e,t);break}case l.HEAD:{e._insertElement(t,O.HTML),e.headElement=e.openElements.current,e.insertionMode=k.IN_HEAD;break}default:Xn(e,t)}}function $p(e,t){const n=t.tagID;n===l.HEAD||n===l.BODY||n===l.HTML||n===l.BR?Xn(e,t):e._err(t,L.endTagWithoutMatchingOpenElement)}function Xn(e,t){e._insertFakeElement(v.HEAD,l.HEAD),e.headElement=e.openElements.current,e.insertionMode=k.IN_HEAD,e._processToken(t)}function st(e,t){switch(t.tagID){case l.HTML:{He(e,t);break}case l.BASE:case l.BASEFONT:case l.BGSOUND:case l.LINK:case l.META:{e._appendElement(t,O.HTML),t.ackSelfClosing=!0;break}case l.TITLE:{e._switchToTextParsing(t,Ce.RCDATA);break}case l.NOSCRIPT:{e.options.scriptingEnabled?e._switchToTextParsing(t,Ce.RAWTEXT):(e._insertElement(t,O.HTML),e.insertionMode=k.IN_HEAD_NO_SCRIPT);break}case l.NOFRAMES:case l.STYLE:{e._switchToTextParsing(t,Ce.RAWTEXT);break}case l.SCRIPT:{e._switchToTextParsing(t,Ce.SCRIPT_DATA);break}case l.TEMPLATE:{e._insertTemplate(t),e.activeFormattingElements.insertMarker(),e.framesetOk=!1,e.insertionMode=k.IN_TEMPLATE,e.tmplInsertionModeStack.unshift(k.IN_TEMPLATE);break}case l.HEAD:{e._err(t,L.misplacedStartTagForHeadElement);break}default:Zn(e,t)}}function Yp(e,t){switch(t.tagID){case l.HEAD:{e.openElements.pop(),e.insertionMode=k.AFTER_HEAD;break}case l.BODY:case l.BR:case l.HTML:{Zn(e,t);break}case l.TEMPLATE:{Jt(e,t);break}default:e._err(t,L.endTagWithoutMatchingOpenElement)}}function Jt(e,t){e.openElements.tmplCount>0?(e.openElements.generateImpliedEndTagsThoroughly(),e.openElements.currentTagId!==l.TEMPLATE&&e._err(t,L.closingOfElementWithOpenChildElements),e.openElements.popUntilTagNamePopped(l.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode()):e._err(t,L.endTagWithoutMatchingOpenElement)}function Zn(e,t){e.openElements.pop(),e.insertionMode=k.AFTER_HEAD,e._processToken(t)}function jp(e,t){switch(t.tagID){case l.HTML:{He(e,t);break}case l.BASEFONT:case l.BGSOUND:case l.HEAD:case l.LINK:case l.META:case l.NOFRAMES:case l.STYLE:{st(e,t);break}case l.NOSCRIPT:{e._err(t,L.nestedNoscriptInHead);break}default:Jn(e,t)}}function Vp(e,t){switch(t.tagID){case l.NOSCRIPT:{e.openElements.pop(),e.insertionMode=k.IN_HEAD;break}case l.BR:{Jn(e,t);break}default:e._err(t,L.endTagWithoutMatchingOpenElement)}}function Jn(e,t){const n=t.type===te.EOF?L.openElementsLeftAfterEof:L.disallowedContentInNoscriptInHead;e._err(t,n),e.openElements.pop(),e.insertionMode=k.IN_HEAD,e._processToken(t)}function qp(e,t){switch(t.tagID){case l.HTML:{He(e,t);break}case l.BODY:{e._insertElement(t,O.HTML),e.framesetOk=!1,e.insertionMode=k.IN_BODY;break}case l.FRAMESET:{e._insertElement(t,O.HTML),e.insertionMode=k.IN_FRAMESET;break}case l.BASE:case l.BASEFONT:case l.BGSOUND:case l.LINK:case l.META:case l.NOFRAMES:case l.SCRIPT:case l.STYLE:case l.TEMPLATE:case l.TITLE:{e._err(t,L.abandonedHeadElementChild),e.openElements.push(e.headElement,l.HEAD),st(e,t),e.openElements.remove(e.headElement);break}case l.HEAD:{e._err(t,L.misplacedStartTagForHeadElement);break}default:er(e,t)}}function Wp(e,t){switch(t.tagID){case l.BODY:case l.HTML:case l.BR:{er(e,t);break}case l.TEMPLATE:{Jt(e,t);break}default:e._err(t,L.endTagWithoutMatchingOpenElement)}}function er(e,t){e._insertFakeElement(v.BODY,l.BODY),e.insertionMode=k.IN_BODY,Gr(e,t)}function Gr(e,t){switch(t.type){case te.CHARACTER:{Ou(e,t);break}case te.WHITESPACE_CHARACTER:{Ru(e,t);break}case te.COMMENT:{ba(e,t);break}case te.START_TAG:{He(e,t);break}case te.END_TAG:{Qr(e,t);break}case te.EOF:{Hu(e,t);break}}}function Ru(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t)}function Ou(e,t){e._reconstructActiveFormattingElements(),e._insertCharacters(t),e.framesetOk=!1}function Gp(e,t){e.openElements.tmplCount===0&&e.treeAdapter.adoptAttributes(e.openElements.items[0],t.attrs)}function Qp(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e.openElements.tmplCount===0&&(e.framesetOk=!1,e.treeAdapter.adoptAttributes(n,t.attrs))}function Kp(e,t){const n=e.openElements.tryPeekProperlyNestedBodyElement();e.framesetOk&&n&&(e.treeAdapter.detachNode(n),e.openElements.popAllUpToHtmlElement(),e._insertElement(t,O.HTML),e.insertionMode=k.IN_FRAMESET)}function Xp(e,t){e.openElements.hasInButtonScope(l.P)&&e._closePElement(),e._insertElement(t,O.HTML)}function Zp(e,t){e.openElements.hasInButtonScope(l.P)&&e._closePElement(),e.openElements.currentTagId!==void 0&&ha.has(e.openElements.currentTagId)&&e.openElements.pop(),e._insertElement(t,O.HTML)}function Jp(e,t){e.openElements.hasInButtonScope(l.P)&&e._closePElement(),e._insertElement(t,O.HTML),e.skipNextNewLine=!0,e.framesetOk=!1}function em(e,t){const n=e.openElements.tmplCount>0;(!e.formElement||n)&&(e.openElements.hasInButtonScope(l.P)&&e._closePElement(),e._insertElement(t,O.HTML),n||(e.formElement=e.openElements.current))}function tm(e,t){e.framesetOk=!1;const n=t.tagID;for(let r=e.openElements.stackTop;r>=0;r--){const i=e.openElements.tagIDs[r];if(n===l.LI&&i===l.LI||(n===l.DD||n===l.DT)&&(i===l.DD||i===l.DT)){e.openElements.generateImpliedEndTagsWithExclusion(i),e.openElements.popUntilTagNamePopped(i);break}if(i!==l.ADDRESS&&i!==l.DIV&&i!==l.P&&e._isSpecialElement(e.openElements.items[r],i))break}e.openElements.hasInButtonScope(l.P)&&e._closePElement(),e._insertElement(t,O.HTML)}function nm(e,t){e.openElements.hasInButtonScope(l.P)&&e._closePElement(),e._insertElement(t,O.HTML),e.tokenizer.state=Ce.PLAINTEXT}function rm(e,t){e.openElements.hasInScope(l.BUTTON)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(l.BUTTON)),e._reconstructActiveFormattingElements(),e._insertElement(t,O.HTML),e.framesetOk=!1}function im(e,t){const n=e.activeFormattingElements.getElementEntryInScopeWithTagName(v.A);n&&(ga(e,t),e.openElements.remove(n.element),e.activeFormattingElements.removeEntry(n)),e._reconstructActiveFormattingElements(),e._insertElement(t,O.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function am(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,O.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function sm(e,t){e._reconstructActiveFormattingElements(),e.openElements.hasInScope(l.NOBR)&&(ga(e,t),e._reconstructActiveFormattingElements()),e._insertElement(t,O.HTML),e.activeFormattingElements.pushElement(e.openElements.current,t)}function om(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,O.HTML),e.activeFormattingElements.insertMarker(),e.framesetOk=!1}function um(e,t){e.treeAdapter.getDocumentMode(e.document)!==tt.QUIRKS&&e.openElements.hasInButtonScope(l.P)&&e._closePElement(),e._insertElement(t,O.HTML),e.framesetOk=!1,e.insertionMode=k.IN_TABLE}function Du(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,O.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function Pu(e){const t=hu(e,Zt.TYPE);return t!=null&&t.toLowerCase()===Cp}function lm(e,t){e._reconstructActiveFormattingElements(),e._appendElement(t,O.HTML),Pu(t)||(e.framesetOk=!1),t.ackSelfClosing=!0}function cm(e,t){e._appendElement(t,O.HTML),t.ackSelfClosing=!0}function dm(e,t){e.openElements.hasInButtonScope(l.P)&&e._closePElement(),e._appendElement(t,O.HTML),e.framesetOk=!1,t.ackSelfClosing=!0}function fm(e,t){t.tagName=v.IMG,t.tagID=l.IMG,Du(e,t)}function hm(e,t){e._insertElement(t,O.HTML),e.skipNextNewLine=!0,e.tokenizer.state=Ce.RCDATA,e.originalInsertionMode=e.insertionMode,e.framesetOk=!1,e.insertionMode=k.TEXT}function pm(e,t){e.openElements.hasInButtonScope(l.P)&&e._closePElement(),e._reconstructActiveFormattingElements(),e.framesetOk=!1,e._switchToTextParsing(t,Ce.RAWTEXT)}function mm(e,t){e.framesetOk=!1,e._switchToTextParsing(t,Ce.RAWTEXT)}function Mu(e,t){e._switchToTextParsing(t,Ce.RAWTEXT)}function gm(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,O.HTML),e.framesetOk=!1,e.insertionMode=e.insertionMode===k.IN_TABLE||e.insertionMode===k.IN_CAPTION||e.insertionMode===k.IN_TABLE_BODY||e.insertionMode===k.IN_ROW||e.insertionMode===k.IN_CELL?k.IN_SELECT_IN_TABLE:k.IN_SELECT}function bm(e,t){e.openElements.currentTagId===l.OPTION&&e.openElements.pop(),e._reconstructActiveFormattingElements(),e._insertElement(t,O.HTML)}function Em(e,t){e.openElements.hasInScope(l.RUBY)&&e.openElements.generateImpliedEndTags(),e._insertElement(t,O.HTML)}function Tm(e,t){e.openElements.hasInScope(l.RUBY)&&e.openElements.generateImpliedEndTagsWithExclusion(l.RTC),e._insertElement(t,O.HTML)}function _m(e,t){e._reconstructActiveFormattingElements(),Su(t),ma(t),t.selfClosing?e._appendElement(t,O.MATHML):e._insertElement(t,O.MATHML),t.ackSelfClosing=!0}function km(e,t){e._reconstructActiveFormattingElements(),Nu(t),ma(t),t.selfClosing?e._appendElement(t,O.SVG):e._insertElement(t,O.SVG),t.ackSelfClosing=!0}function Bu(e,t){e._reconstructActiveFormattingElements(),e._insertElement(t,O.HTML)}function He(e,t){switch(t.tagID){case l.I:case l.S:case l.B:case l.U:case l.EM:case l.TT:case l.BIG:case l.CODE:case l.FONT:case l.SMALL:case l.STRIKE:case l.STRONG:{am(e,t);break}case l.A:{im(e,t);break}case l.H1:case l.H2:case l.H3:case l.H4:case l.H5:case l.H6:{Zp(e,t);break}case l.P:case l.DL:case l.OL:case l.UL:case l.DIV:case l.DIR:case l.NAV:case l.MAIN:case l.MENU:case l.ASIDE:case l.CENTER:case l.FIGURE:case l.FOOTER:case l.HEADER:case l.HGROUP:case l.DIALOG:case l.DETAILS:case l.ADDRESS:case l.ARTICLE:case l.SEARCH:case l.SECTION:case l.SUMMARY:case l.FIELDSET:case l.BLOCKQUOTE:case l.FIGCAPTION:{Xp(e,t);break}case l.LI:case l.DD:case l.DT:{tm(e,t);break}case l.BR:case l.IMG:case l.WBR:case l.AREA:case l.EMBED:case l.KEYGEN:{Du(e,t);break}case l.HR:{dm(e,t);break}case l.RB:case l.RTC:{Em(e,t);break}case l.RT:case l.RP:{Tm(e,t);break}case l.PRE:case l.LISTING:{Jp(e,t);break}case l.XMP:{pm(e,t);break}case l.SVG:{km(e,t);break}case l.HTML:{Gp(e,t);break}case l.BASE:case l.LINK:case l.META:case l.STYLE:case l.TITLE:case l.SCRIPT:case l.BGSOUND:case l.BASEFONT:case l.TEMPLATE:{st(e,t);break}case l.BODY:{Qp(e,t);break}case l.FORM:{em(e,t);break}case l.NOBR:{sm(e,t);break}case l.MATH:{_m(e,t);break}case l.TABLE:{um(e,t);break}case l.INPUT:{lm(e,t);break}case l.PARAM:case l.TRACK:case l.SOURCE:{cm(e,t);break}case l.IMAGE:{fm(e,t);break}case l.BUTTON:{rm(e,t);break}case l.APPLET:case l.OBJECT:case l.MARQUEE:{om(e,t);break}case l.IFRAME:{mm(e,t);break}case l.SELECT:{gm(e,t);break}case l.OPTION:case l.OPTGROUP:{bm(e,t);break}case l.NOEMBED:case l.NOFRAMES:{Mu(e,t);break}case l.FRAMESET:{Kp(e,t);break}case l.TEXTAREA:{hm(e,t);break}case l.NOSCRIPT:{e.options.scriptingEnabled?Mu(e,t):Bu(e,t);break}case l.PLAINTEXT:{nm(e,t);break}case l.COL:case l.TH:case l.TD:case l.TR:case l.HEAD:case l.FRAME:case l.TBODY:case l.TFOOT:case l.THEAD:case l.CAPTION:case l.COLGROUP:break;default:Bu(e,t)}}function xm(e,t){if(e.openElements.hasInScope(l.BODY)&&(e.insertionMode=k.AFTER_BODY,e.options.sourceCodeLocationInfo)){const n=e.openElements.tryPeekProperlyNestedBodyElement();n&&e._setEndLocation(n,t)}}function ym(e,t){e.openElements.hasInScope(l.BODY)&&(e.insertionMode=k.AFTER_BODY,Wu(e,t))}function wm(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n))}function Am(e){const t=e.openElements.tmplCount>0,{formElement:n}=e;t||(e.formElement=null),(n||t)&&e.openElements.hasInScope(l.FORM)&&(e.openElements.generateImpliedEndTags(),t?e.openElements.popUntilTagNamePopped(l.FORM):n&&e.openElements.remove(n))}function Cm(e){e.openElements.hasInButtonScope(l.P)||e._insertFakeElement(v.P,l.P),e._closePElement()}function Sm(e){e.openElements.hasInListItemScope(l.LI)&&(e.openElements.generateImpliedEndTagsWithExclusion(l.LI),e.openElements.popUntilTagNamePopped(l.LI))}function Nm(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTagsWithExclusion(n),e.openElements.popUntilTagNamePopped(n))}function Im(e){e.openElements.hasNumberedHeaderInScope()&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilNumberedHeaderPopped())}function vm(e,t){const n=t.tagID;e.openElements.hasInScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker())}function Lm(e){e._reconstructActiveFormattingElements(),e._insertFakeElement(v.BR,l.BR),e.openElements.pop(),e.framesetOk=!1}function Fu(e,t){const n=t.tagName,r=t.tagID;for(let i=e.openElements.stackTop;i>0;i--){const a=e.openElements.items[i],s=e.openElements.tagIDs[i];if(r===s&&(r!==l.UNKNOWN||e.treeAdapter.getTagName(a)===n)){e.openElements.generateImpliedEndTagsWithExclusion(r),e.openElements.stackTop>=i&&e.openElements.shortenToLength(i);break}if(e._isSpecialElement(a,s))break}}function Qr(e,t){switch(t.tagID){case l.A:case l.B:case l.I:case l.S:case l.U:case l.EM:case l.TT:case l.BIG:case l.CODE:case l.FONT:case l.NOBR:case l.SMALL:case l.STRIKE:case l.STRONG:{ga(e,t);break}case l.P:{Cm(e);break}case l.DL:case l.UL:case l.OL:case l.DIR:case l.DIV:case l.NAV:case l.PRE:case l.MAIN:case l.MENU:case l.ASIDE:case l.BUTTON:case l.CENTER:case l.FIGURE:case l.FOOTER:case l.HEADER:case l.HGROUP:case l.DIALOG:case l.ADDRESS:case l.ARTICLE:case l.DETAILS:case l.SEARCH:case l.SECTION:case l.SUMMARY:case l.LISTING:case l.FIELDSET:case l.BLOCKQUOTE:case l.FIGCAPTION:{wm(e,t);break}case l.LI:{Sm(e);break}case l.DD:case l.DT:{Nm(e,t);break}case l.H1:case l.H2:case l.H3:case l.H4:case l.H5:case l.H6:{Im(e);break}case l.BR:{Lm(e);break}case l.BODY:{xm(e,t);break}case l.HTML:{ym(e,t);break}case l.FORM:{Am(e);break}case l.APPLET:case l.OBJECT:case l.MARQUEE:{vm(e,t);break}case l.TEMPLATE:{Jt(e,t);break}default:Fu(e,t)}}function Hu(e,t){e.tmplInsertionModeStack.length>0?qu(e,t):Ea(e,t)}function Rm(e,t){var n;t.tagID===l.SCRIPT&&((n=e.scriptHandler)===null||n===void 0||n.call(e,e.openElements.current)),e.openElements.pop(),e.insertionMode=e.originalInsertionMode}function Om(e,t){e._err(t,L.eofInElementThatCanContainOnlyText),e.openElements.pop(),e.insertionMode=e.originalInsertionMode,e.onEof(t)}function Ta(e,t){if(e.openElements.currentTagId!==void 0&&Iu.has(e.openElements.currentTagId))switch(e.pendingCharacterTokens.length=0,e.hasNonWhitespacePendingCharacterToken=!1,e.originalInsertionMode=e.insertionMode,e.insertionMode=k.IN_TABLE_TEXT,t.type){case te.CHARACTER:{zu(e,t);break}case te.WHITESPACE_CHARACTER:{Uu(e,t);break}}else nr(e,t)}function Dm(e,t){e.openElements.clearBackToTableContext(),e.activeFormattingElements.insertMarker(),e._insertElement(t,O.HTML),e.insertionMode=k.IN_CAPTION}function Pm(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,O.HTML),e.insertionMode=k.IN_COLUMN_GROUP}function Mm(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(v.COLGROUP,l.COLGROUP),e.insertionMode=k.IN_COLUMN_GROUP,_a(e,t)}function Bm(e,t){e.openElements.clearBackToTableContext(),e._insertElement(t,O.HTML),e.insertionMode=k.IN_TABLE_BODY}function Fm(e,t){e.openElements.clearBackToTableContext(),e._insertFakeElement(v.TBODY,l.TBODY),e.insertionMode=k.IN_TABLE_BODY,Xr(e,t)}function Hm(e,t){e.openElements.hasInTableScope(l.TABLE)&&(e.openElements.popUntilTagNamePopped(l.TABLE),e._resetInsertionMode(),e._processStartTag(t))}function Um(e,t){Pu(t)?e._appendElement(t,O.HTML):nr(e,t),t.ackSelfClosing=!0}function zm(e,t){!e.formElement&&e.openElements.tmplCount===0&&(e._insertElement(t,O.HTML),e.formElement=e.openElements.current,e.openElements.pop())}function An(e,t){switch(t.tagID){case l.TD:case l.TH:case l.TR:{Fm(e,t);break}case l.STYLE:case l.SCRIPT:case l.TEMPLATE:{st(e,t);break}case l.COL:{Mm(e,t);break}case l.FORM:{zm(e,t);break}case l.TABLE:{Hm(e,t);break}case l.TBODY:case l.TFOOT:case l.THEAD:{Bm(e,t);break}case l.INPUT:{Um(e,t);break}case l.CAPTION:{Dm(e,t);break}case l.COLGROUP:{Pm(e,t);break}default:nr(e,t)}}function tr(e,t){switch(t.tagID){case l.TABLE:{e.openElements.hasInTableScope(l.TABLE)&&(e.openElements.popUntilTagNamePopped(l.TABLE),e._resetInsertionMode());break}case l.TEMPLATE:{Jt(e,t);break}case l.BODY:case l.CAPTION:case l.COL:case l.COLGROUP:case l.HTML:case l.TBODY:case l.TD:case l.TFOOT:case l.TH:case l.THEAD:case l.TR:break;default:nr(e,t)}}function nr(e,t){const n=e.fosterParentingEnabled;e.fosterParentingEnabled=!0,Gr(e,t),e.fosterParentingEnabled=n}function Uu(e,t){e.pendingCharacterTokens.push(t)}function zu(e,t){e.pendingCharacterTokens.push(t),e.hasNonWhitespacePendingCharacterToken=!0}function rr(e,t){let n=0;if(e.hasNonWhitespacePendingCharacterToken)for(;n<e.pendingCharacterTokens.length;n++)nr(e,e.pendingCharacterTokens[n]);else for(;n<e.pendingCharacterTokens.length;n++)e._insertCharacters(e.pendingCharacterTokens[n]);e.insertionMode=e.originalInsertionMode,e._processToken(t)}const $u=new Set([l.CAPTION,l.COL,l.COLGROUP,l.TBODY,l.TD,l.TFOOT,l.TH,l.THEAD,l.TR]);function $m(e,t){const n=t.tagID;$u.has(n)?e.openElements.hasInTableScope(l.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(l.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=k.IN_TABLE,An(e,t)):He(e,t)}function Ym(e,t){const n=t.tagID;switch(n){case l.CAPTION:case l.TABLE:{e.openElements.hasInTableScope(l.CAPTION)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(l.CAPTION),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=k.IN_TABLE,n===l.TABLE&&tr(e,t));break}case l.BODY:case l.COL:case l.COLGROUP:case l.HTML:case l.TBODY:case l.TD:case l.TFOOT:case l.TH:case l.THEAD:case l.TR:break;default:Qr(e,t)}}function _a(e,t){switch(t.tagID){case l.HTML:{He(e,t);break}case l.COL:{e._appendElement(t,O.HTML),t.ackSelfClosing=!0;break}case l.TEMPLATE:{st(e,t);break}default:Kr(e,t)}}function jm(e,t){switch(t.tagID){case l.COLGROUP:{e.openElements.currentTagId===l.COLGROUP&&(e.openElements.pop(),e.insertionMode=k.IN_TABLE);break}case l.TEMPLATE:{Jt(e,t);break}case l.COL:break;default:Kr(e,t)}}function Kr(e,t){e.openElements.currentTagId===l.COLGROUP&&(e.openElements.pop(),e.insertionMode=k.IN_TABLE,e._processToken(t))}function Xr(e,t){switch(t.tagID){case l.TR:{e.openElements.clearBackToTableBodyContext(),e._insertElement(t,O.HTML),e.insertionMode=k.IN_ROW;break}case l.TH:case l.TD:{e.openElements.clearBackToTableBodyContext(),e._insertFakeElement(v.TR,l.TR),e.insertionMode=k.IN_ROW,Zr(e,t);break}case l.CAPTION:case l.COL:case l.COLGROUP:case l.TBODY:case l.TFOOT:case l.THEAD:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=k.IN_TABLE,An(e,t));break}default:An(e,t)}}function ka(e,t){const n=t.tagID;switch(t.tagID){case l.TBODY:case l.TFOOT:case l.THEAD:{e.openElements.hasInTableScope(n)&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=k.IN_TABLE);break}case l.TABLE:{e.openElements.hasTableBodyContextInTableScope()&&(e.openElements.clearBackToTableBodyContext(),e.openElements.pop(),e.insertionMode=k.IN_TABLE,tr(e,t));break}case l.BODY:case l.CAPTION:case l.COL:case l.COLGROUP:case l.HTML:case l.TD:case l.TH:case l.TR:break;default:tr(e,t)}}function Zr(e,t){switch(t.tagID){case l.TH:case l.TD:{e.openElements.clearBackToTableRowContext(),e._insertElement(t,O.HTML),e.insertionMode=k.IN_CELL,e.activeFormattingElements.insertMarker();break}case l.CAPTION:case l.COL:case l.COLGROUP:case l.TBODY:case l.TFOOT:case l.THEAD:case l.TR:{e.openElements.hasInTableScope(l.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=k.IN_TABLE_BODY,Xr(e,t));break}default:An(e,t)}}function Yu(e,t){switch(t.tagID){case l.TR:{e.openElements.hasInTableScope(l.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=k.IN_TABLE_BODY);break}case l.TABLE:{e.openElements.hasInTableScope(l.TR)&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=k.IN_TABLE_BODY,ka(e,t));break}case l.TBODY:case l.TFOOT:case l.THEAD:{(e.openElements.hasInTableScope(t.tagID)||e.openElements.hasInTableScope(l.TR))&&(e.openElements.clearBackToTableRowContext(),e.openElements.pop(),e.insertionMode=k.IN_TABLE_BODY,ka(e,t));break}case l.BODY:case l.CAPTION:case l.COL:case l.COLGROUP:case l.HTML:case l.TD:case l.TH:break;default:tr(e,t)}}function Vm(e,t){const n=t.tagID;$u.has(n)?(e.openElements.hasInTableScope(l.TD)||e.openElements.hasInTableScope(l.TH))&&(e._closeTableCell(),Zr(e,t)):He(e,t)}function qm(e,t){const n=t.tagID;switch(n){case l.TD:case l.TH:{e.openElements.hasInTableScope(n)&&(e.openElements.generateImpliedEndTags(),e.openElements.popUntilTagNamePopped(n),e.activeFormattingElements.clearToLastMarker(),e.insertionMode=k.IN_ROW);break}case l.TABLE:case l.TBODY:case l.TFOOT:case l.THEAD:case l.TR:{e.openElements.hasInTableScope(n)&&(e._closeTableCell(),Yu(e,t));break}case l.BODY:case l.CAPTION:case l.COL:case l.COLGROUP:case l.HTML:break;default:Qr(e,t)}}function ju(e,t){switch(t.tagID){case l.HTML:{He(e,t);break}case l.OPTION:{e.openElements.currentTagId===l.OPTION&&e.openElements.pop(),e._insertElement(t,O.HTML);break}case l.OPTGROUP:{e.openElements.currentTagId===l.OPTION&&e.openElements.pop(),e.openElements.currentTagId===l.OPTGROUP&&e.openElements.pop(),e._insertElement(t,O.HTML);break}case l.HR:{e.openElements.currentTagId===l.OPTION&&e.openElements.pop(),e.openElements.currentTagId===l.OPTGROUP&&e.openElements.pop(),e._appendElement(t,O.HTML),t.ackSelfClosing=!0;break}case l.INPUT:case l.KEYGEN:case l.TEXTAREA:case l.SELECT:{e.openElements.hasInSelectScope(l.SELECT)&&(e.openElements.popUntilTagNamePopped(l.SELECT),e._resetInsertionMode(),t.tagID!==l.SELECT&&e._processStartTag(t));break}case l.SCRIPT:case l.TEMPLATE:{st(e,t);break}}}function Vu(e,t){switch(t.tagID){case l.OPTGROUP:{e.openElements.stackTop>0&&e.openElements.currentTagId===l.OPTION&&e.openElements.tagIDs[e.openElements.stackTop-1]===l.OPTGROUP&&e.openElements.pop(),e.openElements.currentTagId===l.OPTGROUP&&e.openElements.pop();break}case l.OPTION:{e.openElements.currentTagId===l.OPTION&&e.openElements.pop();break}case l.SELECT:{e.openElements.hasInSelectScope(l.SELECT)&&(e.openElements.popUntilTagNamePopped(l.SELECT),e._resetInsertionMode());break}case l.TEMPLATE:{Jt(e,t);break}}}function Wm(e,t){const n=t.tagID;n===l.CAPTION||n===l.TABLE||n===l.TBODY||n===l.TFOOT||n===l.THEAD||n===l.TR||n===l.TD||n===l.TH?(e.openElements.popUntilTagNamePopped(l.SELECT),e._resetInsertionMode(),e._processStartTag(t)):ju(e,t)}function Gm(e,t){const n=t.tagID;n===l.CAPTION||n===l.TABLE||n===l.TBODY||n===l.TFOOT||n===l.THEAD||n===l.TR||n===l.TD||n===l.TH?e.openElements.hasInTableScope(n)&&(e.openElements.popUntilTagNamePopped(l.SELECT),e._resetInsertionMode(),e.onEndTag(t)):Vu(e,t)}function Qm(e,t){switch(t.tagID){case l.BASE:case l.BASEFONT:case l.BGSOUND:case l.LINK:case l.META:case l.NOFRAMES:case l.SCRIPT:case l.STYLE:case l.TEMPLATE:case l.TITLE:{st(e,t);break}case l.CAPTION:case l.COLGROUP:case l.TBODY:case l.TFOOT:case l.THEAD:{e.tmplInsertionModeStack[0]=k.IN_TABLE,e.insertionMode=k.IN_TABLE,An(e,t);break}case l.COL:{e.tmplInsertionModeStack[0]=k.IN_COLUMN_GROUP,e.insertionMode=k.IN_COLUMN_GROUP,_a(e,t);break}case l.TR:{e.tmplInsertionModeStack[0]=k.IN_TABLE_BODY,e.insertionMode=k.IN_TABLE_BODY,Xr(e,t);break}case l.TD:case l.TH:{e.tmplInsertionModeStack[0]=k.IN_ROW,e.insertionMode=k.IN_ROW,Zr(e,t);break}default:e.tmplInsertionModeStack[0]=k.IN_BODY,e.insertionMode=k.IN_BODY,He(e,t)}}function Km(e,t){t.tagID===l.TEMPLATE&&Jt(e,t)}function qu(e,t){e.openElements.tmplCount>0?(e.openElements.popUntilTagNamePopped(l.TEMPLATE),e.activeFormattingElements.clearToLastMarker(),e.tmplInsertionModeStack.shift(),e._resetInsertionMode(),e.onEof(t)):Ea(e,t)}function Xm(e,t){t.tagID===l.HTML?He(e,t):Jr(e,t)}function Wu(e,t){var n;if(t.tagID===l.HTML){if(e.fragmentContext||(e.insertionMode=k.AFTER_AFTER_BODY),e.options.sourceCodeLocationInfo&&e.openElements.tagIDs[0]===l.HTML){e._setEndLocation(e.openElements.items[0],t);const r=e.openElements.items[1];r&&!(!((n=e.treeAdapter.getNodeSourceCodeLocation(r))===null||n===void 0)&&n.endTag)&&e._setEndLocation(r,t)}}else Jr(e,t)}function Jr(e,t){e.insertionMode=k.IN_BODY,Gr(e,t)}function Zm(e,t){switch(t.tagID){case l.HTML:{He(e,t);break}case l.FRAMESET:{e._insertElement(t,O.HTML);break}case l.FRAME:{e._appendElement(t,O.HTML),t.ackSelfClosing=!0;break}case l.NOFRAMES:{st(e,t);break}}}function Jm(e,t){t.tagID===l.FRAMESET&&!e.openElements.isRootHtmlElementCurrent()&&(e.openElements.pop(),!e.fragmentContext&&e.openElements.currentTagId!==l.FRAMESET&&(e.insertionMode=k.AFTER_FRAMESET))}function e1(e,t){switch(t.tagID){case l.HTML:{He(e,t);break}case l.NOFRAMES:{st(e,t);break}}}function t1(e,t){t.tagID===l.HTML&&(e.insertionMode=k.AFTER_AFTER_FRAMESET)}function n1(e,t){t.tagID===l.HTML?He(e,t):ei(e,t)}function ei(e,t){e.insertionMode=k.IN_BODY,Gr(e,t)}function r1(e,t){switch(t.tagID){case l.HTML:{He(e,t);break}case l.NOFRAMES:{st(e,t);break}}}function i1(e,t){t.chars=ke,e._insertCharacters(t)}function a1(e,t){e._insertCharacters(t),e.framesetOk=!1}function Gu(e){for(;e.treeAdapter.getNamespaceURI(e.openElements.current)!==O.HTML&&e.openElements.currentTagId!==void 0&&!e._isIntegrationPoint(e.openElements.currentTagId,e.openElements.current);)e.openElements.pop()}function s1(e,t){if(kp(t))Gu(e),e._startTagOutsideForeignContent(t);else{const n=e._getAdjustedCurrentElement(),r=e.treeAdapter.getNamespaceURI(n);r===O.MATHML?Su(t):r===O.SVG&&(xp(t),Nu(t)),ma(t),t.selfClosing?e._appendElement(t,r):e._insertElement(t,r),t.ackSelfClosing=!0}}function o1(e,t){if(t.tagID===l.P||t.tagID===l.BR){Gu(e),e._endTagOutsideForeignContent(t);return}for(let n=e.openElements.stackTop;n>0;n--){const r=e.openElements.items[n];if(e.treeAdapter.getNamespaceURI(r)===O.HTML){e._endTagOutsideForeignContent(t);break}const i=e.treeAdapter.getTagName(r);if(i.toLowerCase()===t.tagName){t.tagName=i,e.openElements.shortenToLength(n);break}}}const ti=Qu("end"),gt=Qu("start");function Qu(e){return t;function t(n){const r=n&&n.position&&n.position[e]||{};if(typeof r.line=="number"&&r.line>0&&typeof r.column=="number"&&r.column>0)return{line:r.line,column:r.column,offset:typeof r.offset=="number"&&r.offset>-1?r.offset:void 0}}}function Ku(e){const t=gt(e),n=ti(e);if(t&&n)return{start:t,end:n}}const u1=/<(\/?)(iframe|noembed|noframes|plaintext|script|style|textarea|title|xmp)(?=[\t\n\f\r />])/gi,l1=new Set(["mdxFlowExpression","mdxJsxFlowElement","mdxJsxTextElement","mdxTextExpression","mdxjsEsm"]),Xu={sourceCodeLocationInfo:!0,scriptingEnabled:!1};function Zu(e,t){const n=T1(e),r=uu("type",{handlers:{root:c1,element:d1,text:f1,comment:el,doctype:h1,raw:m1},unknown:g1}),i={parser:n?new Lu(Xu):Lu.getFragmentParser(void 0,Xu),handle(o){r(o,i)},stitches:!1,options:t||{}};r(e,i),Cn(i,gt());const a=n?i.parser.document:i.parser.getFragment(),s=_h(a,{file:i.options.file});return i.stitches&&It(s,"comment",function(o,u,c){const f=o;if(f.value.stitch&&c&&u!==void 0){const d=c.children;return d[u]=f.value.stitch,u}}),s.type==="root"&&s.children.length===1&&s.children[0].type===e.type?s.children[0]:s}function Ju(e,t){let n=-1;if(e)for(;++n<e.length;)t.handle(e[n])}function c1(e,t){Ju(e.children,t)}function d1(e,t){b1(e,t),Ju(e.children,t),E1(e,t)}function f1(e,t){t.parser.tokenizer.state>4&&(t.parser.tokenizer.state=0);const n={type:te.CHARACTER,chars:e.value,location:ir(e)};Cn(t,gt(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function h1(e,t){const n={type:te.DOCTYPE,name:"html",forceQuirks:!1,publicId:"",systemId:"",location:ir(e)};Cn(t,gt(e)),t.parser.currentToken=n,t.parser._processToken(t.parser.currentToken)}function p1(e,t){t.stitches=!0;const n=_1(e);if("children"in e&&"children"in n){const r=Zu({type:"root",children:e.children},t.options);n.children=r.children}el({type:"comment",value:{stitch:n}},t)}function el(e,t){const n=e.value,r={type:te.COMMENT,data:n,location:ir(e)};Cn(t,gt(e)),t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken)}function m1(e,t){if(t.parser.tokenizer.preprocessor.html="",t.parser.tokenizer.preprocessor.pos=-1,t.parser.tokenizer.preprocessor.lastGapPos=-2,t.parser.tokenizer.preprocessor.gapStack=[],t.parser.tokenizer.preprocessor.skipNextNewLine=!1,t.parser.tokenizer.preprocessor.lastChunkWritten=!1,t.parser.tokenizer.preprocessor.endOfChunkHit=!1,t.parser.tokenizer.preprocessor.isEol=!1,tl(t,gt(e)),t.parser.tokenizer.write(t.options.tagfilter?e.value.replace(u1,"<$1$2"):e.value,!1),t.parser.tokenizer._runParsingLoop(),t.parser.tokenizer.state===72||t.parser.tokenizer.state===78){t.parser.tokenizer.preprocessor.lastChunkWritten=!0;const n=t.parser.tokenizer._consume();t.parser.tokenizer._callState(n)}}function g1(e,t){const n=e;if(t.options.passThrough&&t.options.passThrough.includes(n.type))p1(n,t);else{let r="";throw l1.has(n.type)&&(r=". It looks like you are using MDX nodes with `hast-util-raw` (or `rehype-raw`). If you use this because you are using remark or rehype plugins that inject `'html'` nodes, then please raise an issue with that plugin, as its a bad and slow idea. If you use this because you are using markdown syntax, then you have to configure this utility (or plugin) to pass through these nodes (see `passThrough` in docs), but you can also migrate to use the MDX syntax"),new Error("Cannot compile `"+n.type+"` node"+r)}}function Cn(e,t){tl(e,t);const n=e.parser.tokenizer.currentCharacterToken;n&&n.location&&(n.location.endLine=e.parser.tokenizer.preprocessor.line,n.location.endCol=e.parser.tokenizer.preprocessor.col+1,n.location.endOffset=e.parser.tokenizer.preprocessor.offset+1,e.parser.currentToken=n,e.parser._processToken(e.parser.currentToken)),e.parser.tokenizer.paused=!1,e.parser.tokenizer.inLoop=!1,e.parser.tokenizer.active=!1,e.parser.tokenizer.returnState=Ce.DATA,e.parser.tokenizer.charRefCode=-1,e.parser.tokenizer.consumedAfterSnapshot=-1,e.parser.tokenizer.currentLocation=null,e.parser.tokenizer.currentCharacterToken=null,e.parser.tokenizer.currentToken=null,e.parser.tokenizer.currentAttr={name:"",value:""}}function tl(e,t){if(t&&t.offset!==void 0){const n={startLine:t.line,startCol:t.column,startOffset:t.offset,endLine:-1,endCol:-1,endOffset:-1};e.parser.tokenizer.preprocessor.lineStartPos=-t.column+1,e.parser.tokenizer.preprocessor.droppedBufferSize=t.offset,e.parser.tokenizer.preprocessor.line=t.line,e.parser.tokenizer.currentLocation=n}}function b1(e,t){const n=e.tagName.toLowerCase();if(t.parser.tokenizer.state===Ce.PLAINTEXT)return;Cn(t,gt(e));const r=t.parser.openElements.current;let i="namespaceURI"in r?r.namespaceURI:Xt.html;i===Xt.html&&n==="svg"&&(i=Xt.svg);const a=Ah({...e,children:[]},{space:i===Xt.svg?"svg":"html"}),s={type:te.START_TAG,tagName:n,tagID:wn(n),selfClosing:!1,ackSelfClosing:!1,attrs:"attrs"in a?a.attrs:[],location:ir(e)};t.parser.currentToken=s,t.parser._processToken(t.parser.currentToken),t.parser.tokenizer.lastStartTagName=n}function E1(e,t){const n=e.tagName.toLowerCase();if(!t.parser.tokenizer.inForeignNode&&Oh.includes(n)||t.parser.tokenizer.state===Ce.PLAINTEXT)return;Cn(t,ti(e));const r={type:te.END_TAG,tagName:n,tagID:wn(n),selfClosing:!1,ackSelfClosing:!1,attrs:[],location:ir(e)};t.parser.currentToken=r,t.parser._processToken(t.parser.currentToken),n===t.parser.tokenizer.lastStartTagName&&(t.parser.tokenizer.state===Ce.RCDATA||t.parser.tokenizer.state===Ce.RAWTEXT||t.parser.tokenizer.state===Ce.SCRIPT_DATA)&&(t.parser.tokenizer.state=Ce.DATA)}function T1(e){const t=e.type==="root"?e.children[0]:e;return!!(t&&(t.type==="doctype"||t.type==="element"&&t.tagName.toLowerCase()==="html"))}function ir(e){const t=gt(e)||{line:void 0,column:void 0,offset:void 0},n=ti(e)||{line:void 0,column:void 0,offset:void 0};return{startLine:t.line,startCol:t.column,startOffset:t.offset,endLine:n.line,endCol:n.column,endOffset:n.offset}}function _1(e){return"children"in e?Qt({...e,children:[]}):Qt(e)}function xa(e){return function(t,n){return Zu(t,{...e,file:n})}}const en=["ariaDescribedBy","ariaLabel","ariaLabelledBy"],ar={ancestors:{tbody:["table"],td:["table"],th:["table"],thead:["table"],tfoot:["table"],tr:["table"]},attributes:{a:[...en,"dataFootnoteBackref","dataFootnoteRef",["className","data-footnote-backref"],"href"],blockquote:["cite"],code:[["className",/^language-./]],del:["cite"],div:["itemScope","itemType"],dl:[...en],h2:[["className","sr-only"]],img:[...en,"longDesc","src"],input:[["disabled",!0],["type","checkbox"]],ins:["cite"],li:[["className","task-list-item"]],ol:[...en,["className","contains-task-list"]],q:["cite"],section:["dataFootnotes",["className","footnotes"]],source:["srcSet"],summary:[...en],table:[...en],ul:[...en,["className","contains-task-list"]],"*":["abbr","accept","acceptCharset","accessKey","action","align","alt","axis","border","cellPadding","cellSpacing","char","charOff","charSet","checked","clear","colSpan","color","cols","compact","coords","dateTime","dir","encType","frame","hSpace","headers","height","hrefLang","htmlFor","id","isMap","itemProp","label","lang","maxLength","media","method","multiple","name","noHref","noShade","noWrap","open","prompt","readOnly","rev","rowSpan","rows","rules","scope","selected","shape","size","span","start","summary","tabIndex","title","useMap","vAlign","value","width"]},clobber:["ariaDescribedBy","ariaLabelledBy","id","name"],clobberPrefix:"user-content-",protocols:{cite:["http","https"],href:["http","https","irc","ircs","mailto","xmpp"],longDesc:["http","https"],src:["http","https"]},required:{input:{disabled:!0,type:"checkbox"}},strip:["script"],tagNames:["a","b","blockquote","br","code","dd","del","details","div","dl","dt","em","h1","h2","h3","h4","h5","h6","hr","i","img","input","ins","kbd","li","ol","p","picture","pre","q","rp","rt","ruby","s","samp","section","source","span","strike","strong","sub","summary","sup","table","tbody","td","tfoot","th","thead","tr","tt","ul","var"]},Dt={}.hasOwnProperty;function k1(e,t){let n={type:"root",children:[]};const r={schema:t?{...ar,...t}:ar,stack:[]},i=nl(r,e);return i&&(Array.isArray(i)?i.length===1?n=i[0]:n.children=i:n=i),n}function nl(e,t){if(t&&typeof t=="object"){const n=t;switch(typeof n.type=="string"?n.type:""){case"comment":return x1(e,n);case"doctype":return y1(e,n);case"element":return w1(e,n);case"root":return A1(e,n);case"text":return C1(e,n)}}}function x1(e,t){if(e.schema.allowComments){const n=typeof t.value=="string"?t.value:"",r=n.indexOf("-->"),a={type:"comment",value:r<0?n:n.slice(0,r)};return sr(a,t),a}}function y1(e,t){if(e.schema.allowDoctypes){const n={type:"doctype"};return sr(n,t),n}}function w1(e,t){const n=typeof t.tagName=="string"?t.tagName:"";e.stack.push(n);const r=rl(e,t.children),i=S1(e,t.properties);e.stack.pop();let a=!1;if(n&&n!=="*"&&(!e.schema.tagNames||e.schema.tagNames.includes(n))&&(a=!0,e.schema.ancestors&&Dt.call(e.schema.ancestors,n))){const o=e.schema.ancestors[n];let u=-1;for(a=!1;++u<o.length;)e.stack.includes(o[u])&&(a=!0)}if(!a)return e.schema.strip&&!e.schema.strip.includes(n)?r:void 0;const s={type:"element",tagName:n,properties:i,children:r};return sr(s,t),s}function A1(e,t){const r={type:"root",children:rl(e,t.children)};return sr(r,t),r}function C1(e,t){const r={type:"text",value:typeof t.value=="string"?t.value:""};return sr(r,t),r}function rl(e,t){const n=[];if(Array.isArray(t)){const r=t;let i=-1;for(;++i<r.length;){const a=nl(e,r[i]);a&&(Array.isArray(a)?n.push(...a):n.push(a))}}return n}function S1(e,t){const n=e.stack[e.stack.length-1],r=e.schema.attributes,i=e.schema.required,a=r&&Dt.call(r,n)?r[n]:void 0,s=r&&Dt.call(r,"*")?r["*"]:void 0,o=t&&typeof t=="object"?t:{},u={};let c;for(c in o)if(Dt.call(o,c)){const f=o[c];let d=il(e,sl(a,c),c,f);d==null&&(d=il(e,sl(s,c),c,f)),d!=null&&(u[c]=d)}if(i&&Dt.call(i,n)){const f=i[n];for(c in f)Dt.call(f,c)&&!Dt.call(u,c)&&(u[c]=f[c])}return u}function il(e,t,n,r){return t?Array.isArray(r)?N1(e,t,n,r):al(e,t,n,r):void 0}function N1(e,t,n,r){let i=-1;const a=[];for(;++i<r.length;){const s=al(e,t,n,r[i]);(typeof s=="number"||typeof s=="string")&&a.push(s)}return a}function al(e,t,n,r){if(!(typeof r!="boolean"&&typeof r!="number"&&typeof r!="string")&&I1(e,n,r)){if(typeof t=="object"&&t.length>1){let i=!1,a=0;for(;++a<t.length;){const s=t[a];if(s&&typeof s=="object"&&"flags"in s){if(s.test(String(r))){i=!0;break}}else if(s===r){i=!0;break}}if(!i)return}return e.schema.clobber&&e.schema.clobberPrefix&&e.schema.clobber.includes(n)?e.schema.clobberPrefix+r:r}}function I1(e,t,n){const r=e.schema.protocols&&Dt.call(e.schema.protocols,t)?e.schema.protocols[t]:void 0;if(!r||r.length===0)return!0;const i=String(n),a=i.indexOf(":"),s=i.indexOf("?"),o=i.indexOf("#"),u=i.indexOf("/");if(a<0||u>-1&&a>u||s>-1&&a>s||o>-1&&a>o)return!0;let c=-1;for(;++c<r.length;){const f=r[c];if(a===f.length&&i.slice(0,f.length)===f)return!0}return!1}function sr(e,t){const n=Ku(t);t.data&&(e.data=Qt(t.data)),n&&(e.position=n)}function sl(e,t){let n,r=-1;if(e)for(;++r<e.length;){const i=e[r],a=typeof i=="string"?i:i[0];if(a===t)return i;a==="data*"&&(n=i)}if(t.length>4&&t.slice(0,4).toLowerCase()==="data")return n}function ol(e){return function(t){return k1(t,e)}}function ul(e,t){const n=String(e);if(typeof t!="string")throw new TypeError("Expected character");let r=0,i=n.indexOf(t);for(;i!==-1;)r++,i=n.indexOf(t,i+t.length);return r}const Ye=Pt(/[A-Za-z]/),Ue=Pt(/[\dA-Za-z]/),v1=Pt(/[#-'*+\--9=?A-Z^-~]/);function ni(e){return e!==null&&(e<32||e===127)}const ya=Pt(/\d/),L1=Pt(/[\dA-Fa-f]/),R1=Pt(/[!-/:-@[-`{-~]/);function G(e){return e!==null&&e<-2}function ge(e){return e!==null&&(e<0||e===32)}function ne(e){return e===-2||e===-1||e===32}const ri=Pt(/\p{P}|\p{S}/u),tn=Pt(/\s/);function Pt(e){return t;function t(n){return n!==null&&n>-1&&e.test(String.fromCharCode(n))}}function O1(e){if(typeof e!="string")throw new TypeError("Expected a string");return e.replace(/[|\\{}()[\]^$+*?.]/g,"\\$&").replace(/-/g,"\\x2d")}function D1(e,t,n){const i=Hr((n||{}).ignore||[]),a=P1(t);let s=-1;for(;++s<a.length;)Ji(e,"text",o);function o(c,f){let d=-1,h;for(;++d<f.length;){const p=f[d],m=h?h.children:void 0;if(i(p,m?m.indexOf(p):void 0,h))return;h=p}if(h)return u(c,f)}function u(c,f){const d=f[f.length-1],h=a[s][0],p=a[s][1];let m=0;const w=d.children.indexOf(c);let y=!1,S=[];h.lastIndex=0;let C=h.exec(c.value);for(;C;){const D=C.index,P={index:C.index,input:C.input,stack:[...f,c]};let A=p(...C,P);if(typeof A=="string"&&(A=A.length>0?{type:"text",value:A}:void 0),A===!1?h.lastIndex=D+1:(m!==D&&S.push({type:"text",value:c.value.slice(m,D)}),Array.isArray(A)?S.push(...A):A&&S.push(A),m=D+C[0].length,y=!0),!h.global)break;C=h.exec(c.value)}return y?(m<c.value.length&&S.push({type:"text",value:c.value.slice(m)}),d.children.splice(w,1,...S)):S=[c],w+S.length}}function P1(e){const t=[];if(!Array.isArray(e))throw new TypeError("Expected find and replace tuple or list of tuples");const n=!e[0]||Array.isArray(e[0])?e:[e];let r=-1;for(;++r<n.length;){const i=n[r];t.push([M1(i[0]),B1(i[1])])}return t}function M1(e){return typeof e=="string"?new RegExp(O1(e),"g"):e}function B1(e){return typeof e=="function"?e:function(){return e}}const wa="phrasing",Aa=["autolink","link","image","label"];function F1(){return{transforms:[V1],enter:{literalAutolink:U1,literalAutolinkEmail:Ca,literalAutolinkHttp:Ca,literalAutolinkWww:Ca},exit:{literalAutolink:j1,literalAutolinkEmail:Y1,literalAutolinkHttp:z1,literalAutolinkWww:$1}}}function H1(){return{unsafe:[{character:"@",before:"[+\\-.\\w]",after:"[\\-.\\w]",inConstruct:wa,notInConstruct:Aa},{character:".",before:"[Ww]",after:"[\\-.\\w]",inConstruct:wa,notInConstruct:Aa},{character:":",before:"[ps]",after:"\\/",inConstruct:wa,notInConstruct:Aa}]}}function U1(e){this.enter({type:"link",title:null,url:"",children:[]},e)}function Ca(e){this.config.enter.autolinkProtocol.call(this,e)}function z1(e){this.config.exit.autolinkProtocol.call(this,e)}function $1(e){this.config.exit.data.call(this,e);const t=this.stack[this.stack.length-1];t.url="http://"+this.sliceSerialize(e)}function Y1(e){this.config.exit.autolinkEmail.call(this,e)}function j1(e){this.exit(e)}function V1(e){D1(e,[[/(https?:\/\/|www(?=\.))([-.\w]+)([^ \t\r\n]*)/gi,q1],[/(?<=^|\s|\p{P}|\p{S})([-.\w+]+)@([-\w]+(?:\.[-\w]+)+)/gu,W1]],{ignore:["link","linkReference"]})}function q1(e,t,n,r,i){let a="";if(!ll(i)||(/^w/i.test(t)&&(n=t+n,t="",a="http://"),!G1(n)))return!1;const s=Q1(n+r);if(!s[0])return!1;const o={type:"link",title:null,url:a+t+s[0],children:[{type:"text",value:t+s[0]}]};return s[1]?[o,{type:"text",value:s[1]}]:o}function W1(e,t,n,r){return!ll(r,!0)||/[-\d_]$/.test(n)?!1:{type:"link",title:null,url:"mailto:"+t+"@"+n,children:[{type:"text",value:t+"@"+n}]}}function G1(e){const t=e.split(".");return!(t.length<2||t[t.length-1]&&(/_/.test(t[t.length-1])||!/[a-zA-Z\d]/.test(t[t.length-1]))||t[t.length-2]&&(/_/.test(t[t.length-2])||!/[a-zA-Z\d]/.test(t[t.length-2])))}function Q1(e){const t=/[!"&'),.:;<>?\]}]+$/.exec(e);if(!t)return[e,void 0];e=e.slice(0,t.index);let n=t[0],r=n.indexOf(")");const i=ul(e,"(");let a=ul(e,")");for(;r!==-1&&i>a;)e+=n.slice(0,r+1),n=n.slice(r+1),r=n.indexOf(")"),a++;return[e,n]}function ll(e,t){const n=e.input.charCodeAt(e.index-1);return(e.index===0||tn(n)||ri(n))&&(!t||n!==47)}function ot(e){return e.replace(/[\t\n\r ]+/g," ").replace(/^ | $/g,"").toLowerCase().toUpperCase()}cl.peek=ig;function K1(){this.buffer()}function X1(e){this.enter({type:"footnoteReference",identifier:"",label:""},e)}function Z1(){this.buffer()}function J1(e){this.enter({type:"footnoteDefinition",identifier:"",label:"",children:[]},e)}function eg(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.identifier=ot(this.sliceSerialize(e)).toLowerCase(),n.label=t}function tg(e){this.exit(e)}function ng(e){const t=this.resume(),n=this.stack[this.stack.length-1];n.identifier=ot(this.sliceSerialize(e)).toLowerCase(),n.label=t}function rg(e){this.exit(e)}function ig(){return"["}function cl(e,t,n,r){const i=n.createTracker(r);let a=i.move("[^");const s=n.enter("footnoteReference"),o=n.enter("reference");return a+=i.move(n.safe(n.associationId(e),{after:"]",before:a})),o(),s(),a+=i.move("]"),a}function ag(){return{enter:{gfmFootnoteCallString:K1,gfmFootnoteCall:X1,gfmFootnoteDefinitionLabelString:Z1,gfmFootnoteDefinition:J1},exit:{gfmFootnoteCallString:eg,gfmFootnoteCall:tg,gfmFootnoteDefinitionLabelString:ng,gfmFootnoteDefinition:rg}}}function sg(e){let t=!1;return e&&e.firstLineBlank&&(t=!0),{handlers:{footnoteDefinition:n,footnoteReference:cl},unsafe:[{character:"[",inConstruct:["label","phrasing","reference"]}]};function n(r,i,a,s){const o=a.createTracker(s);let u=o.move("[^");const c=a.enter("footnoteDefinition"),f=a.enter("label");return u+=o.move(a.safe(a.associationId(r),{before:u,after:"]"})),f(),u+=o.move("]:"),r.children&&r.children.length>0&&(o.shift(4),u+=o.move((t?`
|
|
3
|
+
`:" ")+a.indentLines(a.containerFlow(r,o.current()),t?dl:og))),c(),u}}function og(e,t,n){return t===0?e:dl(e,t,n)}function dl(e,t,n){return(n?"":" ")+e}const ug=["autolink","destinationLiteral","destinationRaw","reference","titleQuote","titleApostrophe"];fl.peek=hg;function lg(){return{canContainEols:["delete"],enter:{strikethrough:dg},exit:{strikethrough:fg}}}function cg(){return{unsafe:[{character:"~",inConstruct:"phrasing",notInConstruct:ug}],handlers:{delete:fl}}}function dg(e){this.enter({type:"delete",children:[]},e)}function fg(e){this.exit(e)}function fl(e,t,n,r){const i=n.createTracker(r),a=n.enter("strikethrough");let s=i.move("~~");return s+=n.containerPhrasing(e,{...i.current(),before:s,after:"~"}),s+=i.move("~~"),a(),s}function hg(){return"~"}function pg(e){return e.length}function mg(e,t){const n=t||{},r=(n.align||[]).concat(),i=n.stringLength||pg,a=[],s=[],o=[],u=[];let c=0,f=-1;for(;++f<e.length;){const _=[],w=[];let y=-1;for(e[f].length>c&&(c=e[f].length);++y<e[f].length;){const S=gg(e[f][y]);if(n.alignDelimiters!==!1){const C=i(S);w[y]=C,(u[y]===void 0||C>u[y])&&(u[y]=C)}_.push(S)}s[f]=_,o[f]=w}let d=-1;if(typeof r=="object"&&"length"in r)for(;++d<c;)a[d]=hl(r[d]);else{const _=hl(r);for(;++d<c;)a[d]=_}d=-1;const h=[],p=[];for(;++d<c;){const _=a[d];let w="",y="";_===99?(w=":",y=":"):_===108?w=":":_===114&&(y=":");let S=n.alignDelimiters===!1?1:Math.max(1,u[d]-w.length-y.length);const C=w+"-".repeat(S)+y;n.alignDelimiters!==!1&&(S=w.length+S+y.length,S>u[d]&&(u[d]=S),p[d]=S),h[d]=C}s.splice(1,0,h),o.splice(1,0,p),f=-1;const m=[];for(;++f<s.length;){const _=s[f],w=o[f];d=-1;const y=[];for(;++d<c;){const S=_[d]||"";let C="",D="";if(n.alignDelimiters!==!1){const P=u[d]-(w[d]||0),A=a[d];A===114?C=" ".repeat(P):A===99?P%2?(C=" ".repeat(P/2+.5),D=" ".repeat(P/2-.5)):(C=" ".repeat(P/2),D=C):D=" ".repeat(P)}n.delimiterStart!==!1&&!d&&y.push("|"),n.padding!==!1&&!(n.alignDelimiters===!1&&S==="")&&(n.delimiterStart!==!1||d)&&y.push(" "),n.alignDelimiters!==!1&&y.push(C),y.push(S),n.alignDelimiters!==!1&&y.push(D),n.padding!==!1&&y.push(" "),(n.delimiterEnd!==!1||d!==c-1)&&y.push("|")}m.push(n.delimiterEnd===!1?y.join("").replace(/ +$/,""):y.join(""))}return m.join(`
|
|
4
|
+
`)}function gg(e){return e==null?"":String(e)}function hl(e){const t=typeof e=="string"?e.codePointAt(0):0;return t===67||t===99?99:t===76||t===108?108:t===82||t===114?114:0}function bg(e,t,n,r){const i=n.enter("blockquote"),a=n.createTracker(r);a.move("> "),a.shift(2);const s=n.indentLines(n.containerFlow(e,a.current()),Eg);return i(),s}function Eg(e,t,n){return">"+(n?"":" ")+e}function Tg(e,t){return pl(e,t.inConstruct,!0)&&!pl(e,t.notInConstruct,!1)}function pl(e,t,n){if(typeof t=="string"&&(t=[t]),!t||t.length===0)return n;let r=-1;for(;++r<t.length;)if(e.includes(t[r]))return!0;return!1}function ml(e,t,n,r){let i=-1;for(;++i<n.unsafe.length;)if(n.unsafe[i].character===`
|
|
5
|
+
`&&Tg(n.stack,n.unsafe[i]))return/[ \t]/.test(r.before)?"":" ";return`\\
|
|
6
|
+
`}function _g(e,t){const n=String(e);let r=n.indexOf(t),i=r,a=0,s=0;if(typeof t!="string")throw new TypeError("Expected substring");for(;r!==-1;)r===i?++a>s&&(s=a):a=1,i=r+t.length,r=n.indexOf(t,i);return s}function kg(e,t){return!!(t.options.fences===!1&&e.value&&!e.lang&&/[^ \r\n]/.test(e.value)&&!/^[\t ]*(?:[\r\n]|$)|(?:^|[\r\n])[\t ]*$/.test(e.value))}function xg(e){const t=e.options.fence||"`";if(t!=="`"&&t!=="~")throw new Error("Cannot serialize code with `"+t+"` for `options.fence`, expected `` ` `` or `~`");return t}function yg(e,t,n,r){const i=xg(n),a=e.value||"",s=i==="`"?"GraveAccent":"Tilde";if(kg(e,n)){const d=n.enter("codeIndented"),h=n.indentLines(a,wg);return d(),h}const o=n.createTracker(r),u=i.repeat(Math.max(_g(a,i)+1,3)),c=n.enter("codeFenced");let f=o.move(u);if(e.lang){const d=n.enter(`codeFencedLang${s}`);f+=o.move(n.safe(e.lang,{before:f,after:" ",encode:["`"],...o.current()})),d()}if(e.lang&&e.meta){const d=n.enter(`codeFencedMeta${s}`);f+=o.move(" "),f+=o.move(n.safe(e.meta,{before:f,after:`
|
|
7
7
|
`,encode:["`"],...o.current()})),d()}return f+=o.move(`
|
|
8
8
|
`),a&&(f+=o.move(a+`
|
|
9
|
-
`)),f+=o.move(u),c(),f}function
|
|
10
|
-
`,...u.current()}))),o(),e.title&&(o=n.enter(`title${a}`),c+=u.move(" "+i),c+=u.move(n.safe(e.title,{before:c,after:i,...u.current()})),c+=u.move(i),o()),s(),c}function
|
|
9
|
+
`)),f+=o.move(u),c(),f}function wg(e,t,n){return(n?"":" ")+e}function Sa(e){const t=e.options.quote||'"';if(t!=='"'&&t!=="'")throw new Error("Cannot serialize title with `"+t+"` for `options.quote`, expected `\"`, or `'`");return t}function Ag(e,t,n,r){const i=Sa(n),a=i==='"'?"Quote":"Apostrophe",s=n.enter("definition");let o=n.enter("label");const u=n.createTracker(r);let c=u.move("[");return c+=u.move(n.safe(n.associationId(e),{before:c,after:"]",...u.current()})),c+=u.move("]: "),o(),!e.url||/[\0- \u007F]/.test(e.url)?(o=n.enter("destinationLiteral"),c+=u.move("<"),c+=u.move(n.safe(e.url,{before:c,after:">",...u.current()})),c+=u.move(">")):(o=n.enter("destinationRaw"),c+=u.move(n.safe(e.url,{before:c,after:e.title?" ":`
|
|
10
|
+
`,...u.current()}))),o(),e.title&&(o=n.enter(`title${a}`),c+=u.move(" "+i),c+=u.move(n.safe(e.title,{before:c,after:i,...u.current()})),c+=u.move(i),o()),s(),c}function Cg(e){const t=e.options.emphasis||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize emphasis with `"+t+"` for `options.emphasis`, expected `*`, or `_`");return t}function or(e){return"&#x"+e.toString(16).toUpperCase()+";"}function Sn(e){if(e===null||ge(e)||tn(e))return 1;if(ri(e))return 2}function ii(e,t,n){const r=Sn(e),i=Sn(t);return r===void 0?i===void 0?n==="_"?{inside:!0,outside:!0}:{inside:!1,outside:!1}:i===1?{inside:!0,outside:!0}:{inside:!1,outside:!0}:r===1?i===void 0?{inside:!1,outside:!1}:i===1?{inside:!0,outside:!0}:{inside:!1,outside:!1}:i===void 0?{inside:!1,outside:!1}:i===1?{inside:!0,outside:!1}:{inside:!1,outside:!1}}gl.peek=Sg;function gl(e,t,n,r){const i=Cg(n),a=n.enter("emphasis"),s=n.createTracker(r),o=s.move(i);let u=s.move(n.containerPhrasing(e,{after:i,before:o,...s.current()}));const c=u.charCodeAt(0),f=ii(r.before.charCodeAt(r.before.length-1),c,i);f.inside&&(u=or(c)+u.slice(1));const d=u.charCodeAt(u.length-1),h=ii(r.after.charCodeAt(0),d,i);h.inside&&(u=u.slice(0,-1)+or(d));const p=s.move(i);return a(),n.attentionEncodeSurroundingInfo={after:h.outside,before:f.outside},o+u+p}function Sg(e,t,n){return n.options.emphasis||"*"}const Ng={};function Na(e,t){const n=t||Ng,r=typeof n.includeImageAlt=="boolean"?n.includeImageAlt:!0,i=typeof n.includeHtml=="boolean"?n.includeHtml:!0;return bl(e,r,i)}function bl(e,t,n){if(Ig(e)){if("value"in e)return e.type==="html"&&!n?"":e.value;if(t&&"alt"in e&&e.alt)return e.alt;if("children"in e)return El(e.children,t,n)}return Array.isArray(e)?El(e,t,n):""}function El(e,t,n){const r=[];let i=-1;for(;++i<e.length;)r[i]=bl(e[i],t,n);return r.join("")}function Ig(e){return!!(e&&typeof e=="object")}function vg(e,t){let n=!1;return It(e,function(r){if("value"in r&&/\r?\n|\r/.test(r.value)||r.type==="break")return n=!0,Zi}),!!((!e.depth||e.depth<3)&&Na(e)&&(t.options.setext||n))}function Lg(e,t,n,r){const i=Math.max(Math.min(6,e.depth||1),1),a=n.createTracker(r);if(vg(e,n)){const f=n.enter("headingSetext"),d=n.enter("phrasing"),h=n.containerPhrasing(e,{...a.current(),before:`
|
|
11
11
|
`,after:`
|
|
12
12
|
`});return d(),f(),h+`
|
|
13
13
|
`+(i===1?"=":"-").repeat(h.length-(Math.max(h.lastIndexOf("\r"),h.lastIndexOf(`
|
|
14
14
|
`))+1))}const s="#".repeat(i),o=n.enter("headingAtx"),u=n.enter("phrasing");a.move(s+" ");let c=n.containerPhrasing(e,{before:"# ",after:`
|
|
15
|
-
`,...a.current()});return/^[\t ]/.test(c)&&(c=
|
|
16
|
-
`,inConstruct:"tableCell"},{atBreak:!0,character:"|",after:"[ :-]"},{character:"|",inConstruct:"tableCell"},{atBreak:!0,character:":",after:"-"},{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{inlineCode:h,table:s,tableCell:u,tableRow:o}};function s(p,m,_,
|
|
17
|
-
`))}function u(p,m,_,A){const y=_.enter("tableCell"),I=_.enter("phrasing"),S=_.containerPhrasing(p,{...A,before:a,after:a});return I(),y(),S}function c(p,m){return zm(p,{align:m,alignDelimiters:r,padding:n,stringLength:i})}function f(p,m,_){const A=p.children;let y=-1;const I=[],S=m.enter("table");for(;++y<A.length;)I[y]=d(A[y],m,_);return S(),I}function d(p,m,_){const A=p.children;let y=-1;const I=[],S=m.enter("tableRow");for(;++y<A.length;)I[y]=u(A[y],p,m,_);return S(),I}function h(p,m,_){let A=_l.inlineCode(p,m,_);return _.stack.includes("tableCell")&&(A=A.replace(/\|/g,"\\$&")),A}}function Og(){return{exit:{taskListCheckValueChecked:wl,taskListCheckValueUnchecked:wl,paragraph:Pg}}}function Dg(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:Mg}}}function wl(e){const t=this.stack[this.stack.length-2];t.checked=e.type==="taskListCheckValueChecked"}function Pg(e){const t=this.stack[this.stack.length-2];if(t&&t.type==="listItem"&&typeof t.checked=="boolean"){const n=this.stack[this.stack.length-1],r=n.children[0];if(r&&r.type==="text"){const i=t.children;let a=-1,s;for(;++a<i.length;){const o=i[a];if(o.type==="paragraph"){s=o;break}}s===n&&(r.value=r.value.slice(1),r.value.length===0?n.children.shift():n.position&&r.position&&typeof r.position.start.offset=="number"&&(r.position.start.column++,r.position.start.offset++,n.position.start=Object.assign({},r.position.start)))}}this.exit(e)}function Mg(e,t,n,r){const i=e.children[0],a=typeof e.checked=="boolean"&&i&&i.type==="paragraph",s="["+(e.checked?"x":" ")+"] ",o=n.createTracker(r);a&&o.move(s);let u=_l.listItem(e,t,n,{...r,...o.current()});return a&&(u=u.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,c)),u;function c(f){return f+s}}function Bg(){return[cm(),Lm(),Pm(),Cg(),Og()]}function Fg(e){return{extensions:[dm(),Rm(e),Mm(),Rg(e),Dg()]}}function Ke(e,t,n,r){const i=e.length;let a=0,s;if(t<0?t=-t>i?0:i+t:t=t>i?i:t,n=n>0?n:0,r.length<1e4)s=Array.from(r),s.unshift(t,n),e.splice(...s);else for(n&&e.splice(t,n);a<r.length;)s=r.slice(a,a+1e4),s.unshift(t,0),e.splice(...s),a+=1e4,t+=1e4}function it(e,t){return e.length>0?(Ke(e,e.length,0,t),e):t}const Al={}.hasOwnProperty;function Cl(e){const t={};let n=-1;for(;++n<e.length;)Hg(t,e[n]);return t}function Hg(e,t){let n;for(n in t){const i=(Al.call(e,n)?e[n]:void 0)||(e[n]={}),a=t[n];let s;if(a)for(s in a){Al.call(i,s)||(i[s]=[]);const o=a[s];Ug(i[s],Array.isArray(o)?o:o?[o]:[])}}}function Ug(e,t){let n=-1;const r=[];for(;++n<t.length;)(t[n].add==="after"?e:r).push(t[n]);Ke(e,0,0,r)}const zg={tokenize:Wg,partial:!0},Sl={tokenize:Gg,partial:!0},Il={tokenize:Qg,partial:!0},Nl={tokenize:Kg,partial:!0},$g={tokenize:Xg,partial:!0},vl={name:"wwwAutolink",tokenize:Vg,previous:Rl},Ll={name:"protocolAutolink",tokenize:qg,previous:Ol},_t={name:"emailAutolink",tokenize:jg,previous:Dl},mt={};function Yg(){return{text:mt}}let Xt=48;for(;Xt<123;)mt[Xt]=_t,Xt++,Xt===58?Xt=65:Xt===91&&(Xt=97);mt[43]=_t,mt[45]=_t,mt[46]=_t,mt[95]=_t,mt[72]=[_t,Ll],mt[104]=[_t,Ll],mt[87]=[_t,vl],mt[119]=[_t,vl];function jg(e,t,n){const r=this;let i,a;return s;function s(d){return!wa(d)||!Dl.call(r,r.previous)||Aa(r.events)?n(d):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),o(d))}function o(d){return wa(d)?(e.consume(d),o):d===64?(e.consume(d),u):n(d)}function u(d){return d===46?e.check($g,f,c)(d):d===45||d===95||Be(d)?(a=!0,e.consume(d),u):f(d)}function c(d){return e.consume(d),i=!0,u}function f(d){return a&&i&&ze(r.previous)?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),t(d)):n(d)}}function Vg(e,t,n){const r=this;return i;function i(s){return s!==87&&s!==119||!Rl.call(r,r.previous)||Aa(r.events)?n(s):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(zg,e.attempt(Sl,e.attempt(Il,a),n),n)(s))}function a(s){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(s)}}function qg(e,t,n){const r=this;let i="",a=!1;return s;function s(d){return(d===72||d===104)&&Ol.call(r,r.previous)&&!Aa(r.events)?(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),i+=String.fromCodePoint(d),e.consume(d),o):n(d)}function o(d){if(ze(d)&&i.length<5)return i+=String.fromCodePoint(d),e.consume(d),o;if(d===58){const h=i.toLowerCase();if(h==="http"||h==="https")return e.consume(d),u}return n(d)}function u(d){return d===47?(e.consume(d),a?c:(a=!0,u)):n(d)}function c(d){return d===null||Gr(d)||pe(d)||Kt(d)||Qr(d)?n(d):e.attempt(Sl,e.attempt(Il,f),n)(d)}function f(d){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(d)}}function Wg(e,t,n){let r=0;return i;function i(s){return(s===87||s===119)&&r<3?(r++,e.consume(s),i):s===46&&r===3?(e.consume(s),a):n(s)}function a(s){return s===null?n(s):t(s)}}function Gg(e,t,n){let r,i,a;return s;function s(c){return c===46||c===95?e.check(Nl,u,o)(c):c===null||pe(c)||Kt(c)||c!==45&&Qr(c)?u(c):(a=!0,e.consume(c),s)}function o(c){return c===95?r=!0:(i=r,r=void 0),e.consume(c),s}function u(c){return i||r||!a?n(c):t(c)}}function Qg(e,t){let n=0,r=0;return i;function i(s){return s===40?(n++,e.consume(s),i):s===41&&r<n?a(s):s===33||s===34||s===38||s===39||s===41||s===42||s===44||s===46||s===58||s===59||s===60||s===63||s===93||s===95||s===126?e.check(Nl,t,a)(s):s===null||pe(s)||Kt(s)?t(s):(e.consume(s),i)}function a(s){return s===41&&r++,e.consume(s),i}}function Kg(e,t,n){return r;function r(o){return o===33||o===34||o===39||o===41||o===42||o===44||o===46||o===58||o===59||o===63||o===95||o===126?(e.consume(o),r):o===38?(e.consume(o),a):o===93?(e.consume(o),i):o===60||o===null||pe(o)||Kt(o)?t(o):n(o)}function i(o){return o===null||o===40||o===91||pe(o)||Kt(o)?t(o):r(o)}function a(o){return ze(o)?s(o):n(o)}function s(o){return o===59?(e.consume(o),r):ze(o)?(e.consume(o),s):n(o)}}function Xg(e,t,n){return r;function r(a){return e.consume(a),i}function i(a){return Be(a)?n(a):t(a)}}function Rl(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||pe(e)}function Ol(e){return!ze(e)}function Dl(e){return!(e===47||wa(e))}function wa(e){return e===43||e===45||e===46||e===95||Be(e)}function Aa(e){let t=e.length,n=!1;for(;t--;){const r=e[t][1];if((r.type==="labelLink"||r.type==="labelImage")&&!r._balanced){n=!0;break}if(r._gfmAutolinkLiteralWalkedInto){n=!1;break}}return e.length>0&&!n&&(e[e.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),n}function _n(e){const t=[];let n=-1,r=0,i=0;for(;++n<e.length;){const a=e.charCodeAt(n);let s="";if(a===37&&Be(e.charCodeAt(n+1))&&Be(e.charCodeAt(n+2)))i=2;else if(a<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(a))||(s=String.fromCharCode(a));else if(a>55295&&a<57344){const o=e.charCodeAt(n+1);a<56320&&o>56319&&o<57344?(s=String.fromCharCode(a,o),i=1):s="�"}else s=String.fromCharCode(a);s&&(t.push(e.slice(r,n),encodeURIComponent(s)),r=n+i+1,s=""),i&&(n+=i,i=0)}return t.join("")+e.slice(r)}function Xr(e,t,n){const r=[];let i=-1;for(;++i<e.length;){const a=e[i].resolveAll;a&&!r.includes(a)&&(t=a(t,n),r.push(a))}return t}const Ca={name:"attention",resolveAll:Zg,tokenize:Jg};function Zg(e,t){let n=-1,r,i,a,s,o,u,c,f;for(;++n<e.length;)if(e[n][0]==="enter"&&e[n][1].type==="attentionSequence"&&e[n][1]._close){for(r=n;r--;)if(e[r][0]==="exit"&&e[r][1].type==="attentionSequence"&&e[r][1]._open&&t.sliceSerialize(e[r][1]).charCodeAt(0)===t.sliceSerialize(e[n][1]).charCodeAt(0)){if((e[r][1]._close||e[n][1]._open)&&(e[n][1].end.offset-e[n][1].start.offset)%3&&!((e[r][1].end.offset-e[r][1].start.offset+e[n][1].end.offset-e[n][1].start.offset)%3))continue;u=e[r][1].end.offset-e[r][1].start.offset>1&&e[n][1].end.offset-e[n][1].start.offset>1?2:1;const d={...e[r][1].end},h={...e[n][1].start};Pl(d,-u),Pl(h,u),s={type:u>1?"strongSequence":"emphasisSequence",start:d,end:{...e[r][1].end}},o={type:u>1?"strongSequence":"emphasisSequence",start:{...e[n][1].start},end:h},a={type:u>1?"strongText":"emphasisText",start:{...e[r][1].end},end:{...e[n][1].start}},i={type:u>1?"strong":"emphasis",start:{...s.start},end:{...o.end}},e[r][1].end={...s.start},e[n][1].start={...o.end},c=[],e[r][1].end.offset-e[r][1].start.offset&&(c=it(c,[["enter",e[r][1],t],["exit",e[r][1],t]])),c=it(c,[["enter",i,t],["enter",s,t],["exit",s,t],["enter",a,t]]),c=it(c,Xr(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),c=it(c,[["exit",a,t],["enter",o,t],["exit",o,t],["exit",i,t]]),e[n][1].end.offset-e[n][1].start.offset?(f=2,c=it(c,[["enter",e[n][1],t],["exit",e[n][1],t]])):f=0,Ke(e,r-1,n-r+3,c),n=r+c.length-f-2;break}}for(n=-1;++n<e.length;)e[n][1].type==="attentionSequence"&&(e[n][1].type="data");return e}function Jg(e,t){const n=this.parser.constructs.attentionMarkers.null,r=this.previous,i=Tn(r);let a;return s;function s(u){return a=u,e.enter("attentionSequence"),o(u)}function o(u){if(u===a)return e.consume(u),o;const c=e.exit("attentionSequence"),f=Tn(u),d=!f||f===2&&i||n.includes(u),h=!i||i===2&&f||n.includes(r);return c._open=!!(a===42?d:d&&(i||!h)),c._close=!!(a===42?h:h&&(f||!d)),t(u)}}function Pl(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const eb={name:"autolink",tokenize:tb};function tb(e,t,n){let r=0;return i;function i(p){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(p),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),a}function a(p){return ze(p)?(e.consume(p),s):p===64?n(p):c(p)}function s(p){return p===43||p===45||p===46||Be(p)?(r=1,o(p)):c(p)}function o(p){return p===58?(e.consume(p),r=0,u):(p===43||p===45||p===46||Be(p))&&r++<32?(e.consume(p),o):(r=0,c(p))}function u(p){return p===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(p),e.exit("autolinkMarker"),e.exit("autolink"),t):p===null||p===32||p===60||Gr(p)?n(p):(e.consume(p),u)}function c(p){return p===64?(e.consume(p),f):nm(p)?(e.consume(p),c):n(p)}function f(p){return Be(p)?d(p):n(p)}function d(p){return p===46?(e.consume(p),r=0,f):p===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(p),e.exit("autolinkMarker"),e.exit("autolink"),t):h(p)}function h(p){if((p===45||Be(p))&&r++<63){const m=p===45?h:d;return e.consume(p),m}return n(p)}}function oe(e,t,n,r){const i=r?r-1:Number.POSITIVE_INFINITY;let a=0;return s;function s(u){return ie(u)?(e.enter(n),o(u)):t(u)}function o(u){return ie(u)&&a++<i?(e.consume(u),o):(e.exit(n),t(u))}}const er={partial:!0,tokenize:nb};function nb(e,t,n){return r;function r(a){return ie(a)?oe(e,i,"linePrefix")(a):i(a)}function i(a){return a===null||G(a)?t(a):n(a)}}const Ml={continuation:{tokenize:ib},exit:ab,name:"blockQuote",tokenize:rb};function rb(e,t,n){const r=this;return i;function i(s){if(s===62){const o=r.containerState;return o.open||(e.enter("blockQuote",{_container:!0}),o.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(s),e.exit("blockQuoteMarker"),a}return n(s)}function a(s){return ie(s)?(e.enter("blockQuotePrefixWhitespace"),e.consume(s),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(s))}}function ib(e,t,n){const r=this;return i;function i(s){return ie(s)?oe(e,a,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(s):a(s)}function a(s){return e.attempt(Ml,t,n)(s)}}function ab(e){e.exit("blockQuote")}const Bl={name:"characterEscape",tokenize:sb};function sb(e,t,n){return r;function r(a){return e.enter("characterEscape"),e.enter("escapeMarker"),e.consume(a),e.exit("escapeMarker"),i}function i(a){return im(a)?(e.enter("characterEscapeValue"),e.consume(a),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(a)}}const Fl={name:"characterReference",tokenize:ob};function ob(e,t,n){const r=this;let i=0,a,s;return o;function o(d){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(d),e.exit("characterReferenceMarker"),u}function u(d){return d===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(d),e.exit("characterReferenceMarkerNumeric"),c):(e.enter("characterReferenceValue"),a=31,s=Be,f(d))}function c(d){return d===88||d===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(d),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),a=6,s=rm,f):(e.enter("characterReferenceValue"),a=7,s=ma,f(d))}function f(d){if(d===59&&i){const h=e.exit("characterReferenceValue");return s===Be&&!xa(r.sliceSerialize(h))?n(d):(e.enter("characterReferenceMarker"),e.consume(d),e.exit("characterReferenceMarker"),e.exit("characterReference"),t)}return s(d)&&i++<a?(e.consume(d),f):n(d)}}const Hl={partial:!0,tokenize:lb},Ul={concrete:!0,name:"codeFenced",tokenize:ub};function ub(e,t,n){const r=this,i={partial:!0,tokenize:P};let a=0,s=0,o;return u;function u(w){return c(w)}function c(w){const z=r.events[r.events.length-1];return a=z&&z[1].type==="linePrefix"?z[2].sliceSerialize(z[1],!0).length:0,o=w,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),f(w)}function f(w){return w===o?(s++,e.consume(w),f):s<3?n(w):(e.exit("codeFencedFenceSequence"),ie(w)?oe(e,d,"whitespace")(w):d(w))}function d(w){return w===null||G(w)?(e.exit("codeFencedFence"),r.interrupt?t(w):e.check(Hl,_,D)(w)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),h(w))}function h(w){return w===null||G(w)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),d(w)):ie(w)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),oe(e,p,"whitespace")(w)):w===96&&w===o?n(w):(e.consume(w),h)}function p(w){return w===null||G(w)?d(w):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),m(w))}function m(w){return w===null||G(w)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),d(w)):w===96&&w===o?n(w):(e.consume(w),m)}function _(w){return e.attempt(i,D,A)(w)}function A(w){return e.enter("lineEnding"),e.consume(w),e.exit("lineEnding"),y}function y(w){return a>0&&ie(w)?oe(e,I,"linePrefix",a+1)(w):I(w)}function I(w){return w===null||G(w)?e.check(Hl,_,D)(w):(e.enter("codeFlowValue"),S(w))}function S(w){return w===null||G(w)?(e.exit("codeFlowValue"),I(w)):(e.consume(w),S)}function D(w){return e.exit("codeFenced"),t(w)}function P(w,z,L){let H=0;return C;function C(X){return w.enter("lineEnding"),w.consume(X),w.exit("lineEnding"),$}function $(X){return w.enter("codeFencedFence"),ie(X)?oe(w,B,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(X):B(X)}function B(X){return X===o?(w.enter("codeFencedFenceSequence"),Q(X)):L(X)}function Q(X){return X===o?(H++,w.consume(X),Q):H>=s?(w.exit("codeFencedFenceSequence"),ie(X)?oe(w,ae,"whitespace")(X):ae(X)):L(X)}function ae(X){return X===null||G(X)?(w.exit("codeFencedFence"),z(X)):L(X)}}}function lb(e,t,n){const r=this;return i;function i(s){return s===null?n(s):(e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),a)}function a(s){return r.parser.lazy[r.now().line]?n(s):t(s)}}const Sa={name:"codeIndented",tokenize:db},cb={partial:!0,tokenize:fb};function db(e,t,n){const r=this;return i;function i(c){return e.enter("codeIndented"),oe(e,a,"linePrefix",4+1)(c)}function a(c){const f=r.events[r.events.length-1];return f&&f[1].type==="linePrefix"&&f[2].sliceSerialize(f[1],!0).length>=4?s(c):n(c)}function s(c){return c===null?u(c):G(c)?e.attempt(cb,s,u)(c):(e.enter("codeFlowValue"),o(c))}function o(c){return c===null||G(c)?(e.exit("codeFlowValue"),s(c)):(e.consume(c),o)}function u(c){return e.exit("codeIndented"),t(c)}}function fb(e,t,n){const r=this;return i;function i(s){return r.parser.lazy[r.now().line]?n(s):G(s)?(e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),i):oe(e,a,"linePrefix",4+1)(s)}function a(s){const o=r.events[r.events.length-1];return o&&o[1].type==="linePrefix"&&o[2].sliceSerialize(o[1],!0).length>=4?t(s):G(s)?i(s):n(s)}}const hb={name:"codeText",previous:mb,resolve:pb,tokenize:gb};function pb(e){let t=e.length-4,n=3,r,i;if((e[n][1].type==="lineEnding"||e[n][1].type==="space")&&(e[t][1].type==="lineEnding"||e[t][1].type==="space")){for(r=n;++r<t;)if(e[r][1].type==="codeTextData"){e[n][1].type="codeTextPadding",e[t][1].type="codeTextPadding",n+=2,t-=2;break}}for(r=n-1,t++;++r<=t;)i===void 0?r!==t&&e[r][1].type!=="lineEnding"&&(i=r):(r===t||e[r][1].type==="lineEnding")&&(e[i][1].type="codeTextData",r!==i+2&&(e[i][1].end=e[r-1][1].end,e.splice(i+2,r-i-2),t-=r-i-2,r=i+2),i=void 0);return e}function mb(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function gb(e,t,n){let r=0,i,a;return s;function s(d){return e.enter("codeText"),e.enter("codeTextSequence"),o(d)}function o(d){return d===96?(e.consume(d),r++,o):(e.exit("codeTextSequence"),u(d))}function u(d){return d===null?n(d):d===32?(e.enter("space"),e.consume(d),e.exit("space"),u):d===96?(a=e.enter("codeTextSequence"),i=0,f(d)):G(d)?(e.enter("lineEnding"),e.consume(d),e.exit("lineEnding"),u):(e.enter("codeTextData"),c(d))}function c(d){return d===null||d===32||d===96||G(d)?(e.exit("codeTextData"),u(d)):(e.consume(d),c)}function f(d){return d===96?(e.consume(d),i++,f):i===r?(e.exit("codeTextSequence"),e.exit("codeText"),t(d)):(a.type="codeTextData",c(d))}}class bb{constructor(t){this.left=t?[...t]:[],this.right=[]}get(t){if(t<0||t>=this.left.length+this.right.length)throw new RangeError("Cannot access index `"+t+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return t<this.left.length?this.left[t]:this.right[this.right.length-t+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(t,n){const r=n??Number.POSITIVE_INFINITY;return r<this.left.length?this.left.slice(t,r):t>this.left.length?this.right.slice(this.right.length-r+this.left.length,this.right.length-t+this.left.length).reverse():this.left.slice(t).concat(this.right.slice(this.right.length-r+this.left.length).reverse())}splice(t,n,r){const i=n||0;this.setCursor(Math.trunc(t));const a=this.right.splice(this.right.length-i,Number.POSITIVE_INFINITY);return r&&tr(this.left,r),a.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push(t){this.setCursor(Number.POSITIVE_INFINITY),this.left.push(t)}pushMany(t){this.setCursor(Number.POSITIVE_INFINITY),tr(this.left,t)}unshift(t){this.setCursor(0),this.right.push(t)}unshiftMany(t){this.setCursor(0),tr(this.right,t.reverse())}setCursor(t){if(!(t===this.left.length||t>this.left.length&&this.right.length===0||t<0&&this.left.length===0))if(t<this.left.length){const n=this.left.splice(t,Number.POSITIVE_INFINITY);tr(this.right,n.reverse())}else{const n=this.right.splice(this.left.length+this.right.length-t,Number.POSITIVE_INFINITY);tr(this.left,n.reverse())}}}function tr(e,t){let n=0;if(t.length<1e4)e.push(...t);else for(;n<t.length;)e.push(...t.slice(n,n+1e4)),n+=1e4}function zl(e){const t={};let n=-1,r,i,a,s,o,u,c;const f=new bb(e);for(;++n<f.length;){for(;n in t;)n=t[n];if(r=f.get(n),n&&r[1].type==="chunkFlow"&&f.get(n-1)[1].type==="listItemPrefix"&&(u=r[1]._tokenizer.events,a=0,a<u.length&&u[a][1].type==="lineEndingBlank"&&(a+=2),a<u.length&&u[a][1].type==="content"))for(;++a<u.length&&u[a][1].type!=="content";)u[a][1].type==="chunkText"&&(u[a][1]._isInFirstContentOfListItem=!0,a++);if(r[0]==="enter")r[1].contentType&&(Object.assign(t,Eb(f,n)),n=t[n],c=!0);else if(r[1]._container){for(a=n,i=void 0;a--;)if(s=f.get(a),s[1].type==="lineEnding"||s[1].type==="lineEndingBlank")s[0]==="enter"&&(i&&(f.get(i)[1].type="lineEndingBlank"),s[1].type="lineEnding",i=a);else if(!(s[1].type==="linePrefix"||s[1].type==="listItemIndent"))break;i&&(r[1].end={...f.get(i)[1].start},o=f.slice(i,n),o.unshift(r),f.splice(i,n-i+1,o))}}return Ke(e,0,Number.POSITIVE_INFINITY,f.slice(0)),!c}function Eb(e,t){const n=e.get(t)[1],r=e.get(t)[2];let i=t-1;const a=[];let s=n._tokenizer;s||(s=r.parser[n.contentType](n.start),n._contentTypeTextTrailing&&(s._contentTypeTextTrailing=!0));const o=s.events,u=[],c={};let f,d,h=-1,p=n,m=0,_=0;const A=[_];for(;p;){for(;e.get(++i)[1]!==p;);a.push(i),p._tokenizer||(f=r.sliceStream(p),p.next||f.push(null),d&&s.defineSkip(p.start),p._isInFirstContentOfListItem&&(s._gfmTasklistFirstContentOfListItem=!0),s.write(f),p._isInFirstContentOfListItem&&(s._gfmTasklistFirstContentOfListItem=void 0)),d=p,p=p.next}for(p=n;++h<o.length;)o[h][0]==="exit"&&o[h-1][0]==="enter"&&o[h][1].type===o[h-1][1].type&&o[h][1].start.line!==o[h][1].end.line&&(_=h+1,A.push(_),p._tokenizer=void 0,p.previous=void 0,p=p.next);for(s.events=[],p?(p._tokenizer=void 0,p.previous=void 0):A.pop(),h=A.length;h--;){const y=o.slice(A[h],A[h+1]),I=a.pop();u.push([I,I+y.length-1]),e.splice(I,2,y)}for(u.reverse(),h=-1;++h<u.length;)c[m+u[h][0]]=m+u[h][1],m+=u[h][1]-u[h][0]-1;return c}const Tb={resolve:kb,tokenize:xb},_b={partial:!0,tokenize:yb};function kb(e){return zl(e),e}function xb(e,t){let n;return r;function r(o){return e.enter("content"),n=e.enter("chunkContent",{contentType:"content"}),i(o)}function i(o){return o===null?a(o):G(o)?e.check(_b,s,a)(o):(e.consume(o),i)}function a(o){return e.exit("chunkContent"),e.exit("content"),t(o)}function s(o){return e.consume(o),e.exit("chunkContent"),n.next=e.enter("chunkContent",{contentType:"content",previous:n}),n=n.next,i}}function yb(e,t,n){const r=this;return i;function i(s){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),oe(e,a,"linePrefix")}function a(s){if(s===null||G(s))return n(s);const o=r.events[r.events.length-1];return!r.parser.constructs.disable.null.includes("codeIndented")&&o&&o[1].type==="linePrefix"&&o[2].sliceSerialize(o[1],!0).length>=4?t(s):e.interrupt(r.parser.constructs.flow,n,t)(s)}}function $l(e,t,n,r,i,a,s,o,u){const c=u||Number.POSITIVE_INFINITY;let f=0;return d;function d(y){return y===60?(e.enter(r),e.enter(i),e.enter(a),e.consume(y),e.exit(a),h):y===null||y===32||y===41||Gr(y)?n(y):(e.enter(r),e.enter(s),e.enter(o),e.enter("chunkString",{contentType:"string"}),_(y))}function h(y){return y===62?(e.enter(a),e.consume(y),e.exit(a),e.exit(i),e.exit(r),t):(e.enter(o),e.enter("chunkString",{contentType:"string"}),p(y))}function p(y){return y===62?(e.exit("chunkString"),e.exit(o),h(y)):y===null||y===60||G(y)?n(y):(e.consume(y),y===92?m:p)}function m(y){return y===60||y===62||y===92?(e.consume(y),p):p(y)}function _(y){return!f&&(y===null||y===41||pe(y))?(e.exit("chunkString"),e.exit(o),e.exit(s),e.exit(r),t(y)):f<c&&y===40?(e.consume(y),f++,_):y===41?(e.consume(y),f--,_):y===null||y===32||y===40||Gr(y)?n(y):(e.consume(y),y===92?A:_)}function A(y){return y===40||y===41||y===92?(e.consume(y),_):_(y)}}function Yl(e,t,n,r,i,a){const s=this;let o=0,u;return c;function c(p){return e.enter(r),e.enter(i),e.consume(p),e.exit(i),e.enter(a),f}function f(p){return o>999||p===null||p===91||p===93&&!u||p===94&&!o&&"_hiddenFootnoteSupport"in s.parser.constructs?n(p):p===93?(e.exit(a),e.enter(i),e.consume(p),e.exit(i),e.exit(r),t):G(p)?(e.enter("lineEnding"),e.consume(p),e.exit("lineEnding"),f):(e.enter("chunkString",{contentType:"string"}),d(p))}function d(p){return p===null||p===91||p===93||G(p)||o++>999?(e.exit("chunkString"),f(p)):(e.consume(p),u||(u=!ie(p)),p===92?h:d)}function h(p){return p===91||p===92||p===93?(e.consume(p),o++,d):d(p)}}function jl(e,t,n,r,i,a){let s;return o;function o(h){return h===34||h===39||h===40?(e.enter(r),e.enter(i),e.consume(h),e.exit(i),s=h===40?41:h,u):n(h)}function u(h){return h===s?(e.enter(i),e.consume(h),e.exit(i),e.exit(r),t):(e.enter(a),c(h))}function c(h){return h===s?(e.exit(a),u(s)):h===null?n(h):G(h)?(e.enter("lineEnding"),e.consume(h),e.exit("lineEnding"),oe(e,c,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),f(h))}function f(h){return h===s||h===null||G(h)?(e.exit("chunkString"),c(h)):(e.consume(h),h===92?d:f)}function d(h){return h===s||h===92?(e.consume(h),f):f(h)}}function nr(e,t){let n;return r;function r(i){return G(i)?(e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),n=!0,r):ie(i)?oe(e,r,n?"linePrefix":"lineSuffix")(i):t(i)}}const wb={name:"definition",tokenize:Cb},Ab={partial:!0,tokenize:Sb};function Cb(e,t,n){const r=this;let i;return a;function a(p){return e.enter("definition"),s(p)}function s(p){return Yl.call(r,e,o,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(p)}function o(p){return i=ut(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),p===58?(e.enter("definitionMarker"),e.consume(p),e.exit("definitionMarker"),u):n(p)}function u(p){return pe(p)?nr(e,c)(p):c(p)}function c(p){return $l(e,f,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(p)}function f(p){return e.attempt(Ab,d,d)(p)}function d(p){return ie(p)?oe(e,h,"whitespace")(p):h(p)}function h(p){return p===null||G(p)?(e.exit("definition"),r.parser.defined.push(i),t(p)):n(p)}}function Sb(e,t,n){return r;function r(o){return pe(o)?nr(e,i)(o):n(o)}function i(o){return jl(e,a,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(o)}function a(o){return ie(o)?oe(e,s,"whitespace")(o):s(o)}function s(o){return o===null||G(o)?t(o):n(o)}}const Ib={name:"hardBreakEscape",tokenize:Nb};function Nb(e,t,n){return r;function r(a){return e.enter("hardBreakEscape"),e.consume(a),i}function i(a){return G(a)?(e.exit("hardBreakEscape"),t(a)):n(a)}}const vb={name:"headingAtx",resolve:Lb,tokenize:Rb};function Lb(e,t){let n=e.length-2,r=3,i,a;return e[r][1].type==="whitespace"&&(r+=2),n-2>r&&e[n][1].type==="whitespace"&&(n-=2),e[n][1].type==="atxHeadingSequence"&&(r===n-1||n-4>r&&e[n-2][1].type==="whitespace")&&(n-=r+1===n?2:4),n>r&&(i={type:"atxHeadingText",start:e[r][1].start,end:e[n][1].end},a={type:"chunkText",start:e[r][1].start,end:e[n][1].end,contentType:"text"},Ke(e,r,n-r+1,[["enter",i,t],["enter",a,t],["exit",a,t],["exit",i,t]])),e}function Rb(e,t,n){let r=0;return i;function i(f){return e.enter("atxHeading"),a(f)}function a(f){return e.enter("atxHeadingSequence"),s(f)}function s(f){return f===35&&r++<6?(e.consume(f),s):f===null||pe(f)?(e.exit("atxHeadingSequence"),o(f)):n(f)}function o(f){return f===35?(e.enter("atxHeadingSequence"),u(f)):f===null||G(f)?(e.exit("atxHeading"),t(f)):ie(f)?oe(e,o,"whitespace")(f):(e.enter("atxHeadingText"),c(f))}function u(f){return f===35?(e.consume(f),u):(e.exit("atxHeadingSequence"),o(f))}function c(f){return f===null||f===35||pe(f)?(e.exit("atxHeadingText"),o(f)):(e.consume(f),c)}}const Ob=["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","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],Vl=["pre","script","style","textarea"],Db={concrete:!0,name:"htmlFlow",resolveTo:Bb,tokenize:Fb},Pb={partial:!0,tokenize:Ub},Mb={partial:!0,tokenize:Hb};function Bb(e){let t=e.length;for(;t--&&!(e[t][0]==="enter"&&e[t][1].type==="htmlFlow"););return t>1&&e[t-2][1].type==="linePrefix"&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function Fb(e,t,n){const r=this;let i,a,s,o,u;return c;function c(k){return f(k)}function f(k){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(k),d}function d(k){return k===33?(e.consume(k),h):k===47?(e.consume(k),a=!0,_):k===63?(e.consume(k),i=3,r.interrupt?t:x):ze(k)?(e.consume(k),s=String.fromCharCode(k),A):n(k)}function h(k){return k===45?(e.consume(k),i=2,p):k===91?(e.consume(k),i=5,o=0,m):ze(k)?(e.consume(k),i=4,r.interrupt?t:x):n(k)}function p(k){return k===45?(e.consume(k),r.interrupt?t:x):n(k)}function m(k){const me="CDATA[";return k===me.charCodeAt(o++)?(e.consume(k),o===me.length?r.interrupt?t:B:m):n(k)}function _(k){return ze(k)?(e.consume(k),s=String.fromCharCode(k),A):n(k)}function A(k){if(k===null||k===47||k===62||pe(k)){const me=k===47,je=s.toLowerCase();return!me&&!a&&Vl.includes(je)?(i=1,r.interrupt?t(k):B(k)):Ob.includes(s.toLowerCase())?(i=6,me?(e.consume(k),y):r.interrupt?t(k):B(k)):(i=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(k):a?I(k):S(k))}return k===45||Be(k)?(e.consume(k),s+=String.fromCharCode(k),A):n(k)}function y(k){return k===62?(e.consume(k),r.interrupt?t:B):n(k)}function I(k){return ie(k)?(e.consume(k),I):C(k)}function S(k){return k===47?(e.consume(k),C):k===58||k===95||ze(k)?(e.consume(k),D):ie(k)?(e.consume(k),S):C(k)}function D(k){return k===45||k===46||k===58||k===95||Be(k)?(e.consume(k),D):P(k)}function P(k){return k===61?(e.consume(k),w):ie(k)?(e.consume(k),P):S(k)}function w(k){return k===null||k===60||k===61||k===62||k===96?n(k):k===34||k===39?(e.consume(k),u=k,z):ie(k)?(e.consume(k),w):L(k)}function z(k){return k===u?(e.consume(k),u=null,H):k===null||G(k)?n(k):(e.consume(k),z)}function L(k){return k===null||k===34||k===39||k===47||k===60||k===61||k===62||k===96||pe(k)?P(k):(e.consume(k),L)}function H(k){return k===47||k===62||ie(k)?S(k):n(k)}function C(k){return k===62?(e.consume(k),$):n(k)}function $(k){return k===null||G(k)?B(k):ie(k)?(e.consume(k),$):n(k)}function B(k){return k===45&&i===2?(e.consume(k),Z):k===60&&i===1?(e.consume(k),ee):k===62&&i===4?(e.consume(k),Oe):k===63&&i===3?(e.consume(k),x):k===93&&i===5?(e.consume(k),Ye):G(k)&&(i===6||i===7)?(e.exit("htmlFlowData"),e.check(Pb,He,Q)(k)):k===null||G(k)?(e.exit("htmlFlowData"),Q(k)):(e.consume(k),B)}function Q(k){return e.check(Mb,ae,He)(k)}function ae(k){return e.enter("lineEnding"),e.consume(k),e.exit("lineEnding"),X}function X(k){return k===null||G(k)?Q(k):(e.enter("htmlFlowData"),B(k))}function Z(k){return k===45?(e.consume(k),x):B(k)}function ee(k){return k===47?(e.consume(k),s="",q):B(k)}function q(k){if(k===62){const me=s.toLowerCase();return Vl.includes(me)?(e.consume(k),Oe):B(k)}return ze(k)&&s.length<8?(e.consume(k),s+=String.fromCharCode(k),q):B(k)}function Ye(k){return k===93?(e.consume(k),x):B(k)}function x(k){return k===62?(e.consume(k),Oe):k===45&&i===2?(e.consume(k),x):B(k)}function Oe(k){return k===null||G(k)?(e.exit("htmlFlowData"),He(k)):(e.consume(k),Oe)}function He(k){return e.exit("htmlFlow"),t(k)}}function Hb(e,t,n){const r=this;return i;function i(s){return G(s)?(e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),a):n(s)}function a(s){return r.parser.lazy[r.now().line]?n(s):t(s)}}function Ub(e,t,n){return r;function r(i){return e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),e.attempt(er,t,n)}}const zb={name:"htmlText",tokenize:$b};function $b(e,t,n){const r=this;let i,a,s;return o;function o(x){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(x),u}function u(x){return x===33?(e.consume(x),c):x===47?(e.consume(x),P):x===63?(e.consume(x),S):ze(x)?(e.consume(x),L):n(x)}function c(x){return x===45?(e.consume(x),f):x===91?(e.consume(x),a=0,m):ze(x)?(e.consume(x),I):n(x)}function f(x){return x===45?(e.consume(x),p):n(x)}function d(x){return x===null?n(x):x===45?(e.consume(x),h):G(x)?(s=d,ee(x)):(e.consume(x),d)}function h(x){return x===45?(e.consume(x),p):d(x)}function p(x){return x===62?Z(x):x===45?h(x):d(x)}function m(x){const Oe="CDATA[";return x===Oe.charCodeAt(a++)?(e.consume(x),a===Oe.length?_:m):n(x)}function _(x){return x===null?n(x):x===93?(e.consume(x),A):G(x)?(s=_,ee(x)):(e.consume(x),_)}function A(x){return x===93?(e.consume(x),y):_(x)}function y(x){return x===62?Z(x):x===93?(e.consume(x),y):_(x)}function I(x){return x===null||x===62?Z(x):G(x)?(s=I,ee(x)):(e.consume(x),I)}function S(x){return x===null?n(x):x===63?(e.consume(x),D):G(x)?(s=S,ee(x)):(e.consume(x),S)}function D(x){return x===62?Z(x):S(x)}function P(x){return ze(x)?(e.consume(x),w):n(x)}function w(x){return x===45||Be(x)?(e.consume(x),w):z(x)}function z(x){return G(x)?(s=z,ee(x)):ie(x)?(e.consume(x),z):Z(x)}function L(x){return x===45||Be(x)?(e.consume(x),L):x===47||x===62||pe(x)?H(x):n(x)}function H(x){return x===47?(e.consume(x),Z):x===58||x===95||ze(x)?(e.consume(x),C):G(x)?(s=H,ee(x)):ie(x)?(e.consume(x),H):Z(x)}function C(x){return x===45||x===46||x===58||x===95||Be(x)?(e.consume(x),C):$(x)}function $(x){return x===61?(e.consume(x),B):G(x)?(s=$,ee(x)):ie(x)?(e.consume(x),$):H(x)}function B(x){return x===null||x===60||x===61||x===62||x===96?n(x):x===34||x===39?(e.consume(x),i=x,Q):G(x)?(s=B,ee(x)):ie(x)?(e.consume(x),B):(e.consume(x),ae)}function Q(x){return x===i?(e.consume(x),i=void 0,X):x===null?n(x):G(x)?(s=Q,ee(x)):(e.consume(x),Q)}function ae(x){return x===null||x===34||x===39||x===60||x===61||x===96?n(x):x===47||x===62||pe(x)?H(x):(e.consume(x),ae)}function X(x){return x===47||x===62||pe(x)?H(x):n(x)}function Z(x){return x===62?(e.consume(x),e.exit("htmlTextData"),e.exit("htmlText"),t):n(x)}function ee(x){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(x),e.exit("lineEnding"),q}function q(x){return ie(x)?oe(e,Ye,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(x):Ye(x)}function Ye(x){return e.enter("htmlTextData"),s(x)}}const Ia={name:"labelEnd",resolveAll:qb,resolveTo:Wb,tokenize:Gb},Yb={tokenize:Qb},jb={tokenize:Kb},Vb={tokenize:Xb};function qb(e){let t=-1;const n=[];for(;++t<e.length;){const r=e[t][1];if(n.push(e[t]),r.type==="labelImage"||r.type==="labelLink"||r.type==="labelEnd"){const i=r.type==="labelImage"?4:2;r.type="data",t+=i}}return e.length!==n.length&&Ke(e,0,e.length,n),e}function Wb(e,t){let n=e.length,r=0,i,a,s,o;for(;n--;)if(i=e[n][1],a){if(i.type==="link"||i.type==="labelLink"&&i._inactive)break;e[n][0]==="enter"&&i.type==="labelLink"&&(i._inactive=!0)}else if(s){if(e[n][0]==="enter"&&(i.type==="labelImage"||i.type==="labelLink")&&!i._balanced&&(a=n,i.type!=="labelLink")){r=2;break}}else i.type==="labelEnd"&&(s=n);const u={type:e[a][1].type==="labelLink"?"link":"image",start:{...e[a][1].start},end:{...e[e.length-1][1].end}},c={type:"label",start:{...e[a][1].start},end:{...e[s][1].end}},f={type:"labelText",start:{...e[a+r+2][1].end},end:{...e[s-2][1].start}};return o=[["enter",u,t],["enter",c,t]],o=it(o,e.slice(a+1,a+r+3)),o=it(o,[["enter",f,t]]),o=it(o,Xr(t.parser.constructs.insideSpan.null,e.slice(a+r+4,s-3),t)),o=it(o,[["exit",f,t],e[s-2],e[s-1],["exit",c,t]]),o=it(o,e.slice(s+1)),o=it(o,[["exit",u,t]]),Ke(e,a,e.length,o),e}function Gb(e,t,n){const r=this;let i=r.events.length,a,s;for(;i--;)if((r.events[i][1].type==="labelImage"||r.events[i][1].type==="labelLink")&&!r.events[i][1]._balanced){a=r.events[i][1];break}return o;function o(h){return a?a._inactive?d(h):(s=r.parser.defined.includes(ut(r.sliceSerialize({start:a.end,end:r.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(h),e.exit("labelMarker"),e.exit("labelEnd"),u):n(h)}function u(h){return h===40?e.attempt(Yb,f,s?f:d)(h):h===91?e.attempt(jb,f,s?c:d)(h):s?f(h):d(h)}function c(h){return e.attempt(Vb,f,d)(h)}function f(h){return t(h)}function d(h){return a._balanced=!0,n(h)}}function Qb(e,t,n){return r;function r(d){return e.enter("resource"),e.enter("resourceMarker"),e.consume(d),e.exit("resourceMarker"),i}function i(d){return pe(d)?nr(e,a)(d):a(d)}function a(d){return d===41?f(d):$l(e,s,o,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(d)}function s(d){return pe(d)?nr(e,u)(d):f(d)}function o(d){return n(d)}function u(d){return d===34||d===39||d===40?jl(e,c,n,"resourceTitle","resourceTitleMarker","resourceTitleString")(d):f(d)}function c(d){return pe(d)?nr(e,f)(d):f(d)}function f(d){return d===41?(e.enter("resourceMarker"),e.consume(d),e.exit("resourceMarker"),e.exit("resource"),t):n(d)}}function Kb(e,t,n){const r=this;return i;function i(o){return Yl.call(r,e,a,s,"reference","referenceMarker","referenceString")(o)}function a(o){return r.parser.defined.includes(ut(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(o):n(o)}function s(o){return n(o)}}function Xb(e,t,n){return r;function r(a){return e.enter("reference"),e.enter("referenceMarker"),e.consume(a),e.exit("referenceMarker"),i}function i(a){return a===93?(e.enter("referenceMarker"),e.consume(a),e.exit("referenceMarker"),e.exit("reference"),t):n(a)}}const Zb={name:"labelStartImage",resolveAll:Ia.resolveAll,tokenize:Jb};function Jb(e,t,n){const r=this;return i;function i(o){return e.enter("labelImage"),e.enter("labelImageMarker"),e.consume(o),e.exit("labelImageMarker"),a}function a(o){return o===91?(e.enter("labelMarker"),e.consume(o),e.exit("labelMarker"),e.exit("labelImage"),s):n(o)}function s(o){return o===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(o):t(o)}}const e2={name:"labelStartLink",resolveAll:Ia.resolveAll,tokenize:t2};function t2(e,t,n){const r=this;return i;function i(s){return e.enter("labelLink"),e.enter("labelMarker"),e.consume(s),e.exit("labelMarker"),e.exit("labelLink"),a}function a(s){return s===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(s):t(s)}}const Na={name:"lineEnding",tokenize:n2};function n2(e,t){return n;function n(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),oe(e,t,"linePrefix")}}const Zr={name:"thematicBreak",tokenize:r2};function r2(e,t,n){let r=0,i;return a;function a(c){return e.enter("thematicBreak"),s(c)}function s(c){return i=c,o(c)}function o(c){return c===i?(e.enter("thematicBreakSequence"),u(c)):r>=3&&(c===null||G(c))?(e.exit("thematicBreak"),t(c)):n(c)}function u(c){return c===i?(e.consume(c),r++,u):(e.exit("thematicBreakSequence"),ie(c)?oe(e,o,"whitespace")(c):o(c))}}const We={continuation:{tokenize:o2},exit:l2,name:"list",tokenize:s2},i2={partial:!0,tokenize:c2},a2={partial:!0,tokenize:u2};function s2(e,t,n){const r=this,i=r.events[r.events.length-1];let a=i&&i[1].type==="linePrefix"?i[2].sliceSerialize(i[1],!0).length:0,s=0;return o;function o(p){const m=r.containerState.type||(p===42||p===43||p===45?"listUnordered":"listOrdered");if(m==="listUnordered"?!r.containerState.marker||p===r.containerState.marker:ma(p)){if(r.containerState.type||(r.containerState.type=m,e.enter(m,{_container:!0})),m==="listUnordered")return e.enter("listItemPrefix"),p===42||p===45?e.check(Zr,n,c)(p):c(p);if(!r.interrupt||p===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),u(p)}return n(p)}function u(p){return ma(p)&&++s<10?(e.consume(p),u):(!r.interrupt||s<2)&&(r.containerState.marker?p===r.containerState.marker:p===41||p===46)?(e.exit("listItemValue"),c(p)):n(p)}function c(p){return e.enter("listItemMarker"),e.consume(p),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||p,e.check(er,r.interrupt?n:f,e.attempt(i2,h,d))}function f(p){return r.containerState.initialBlankLine=!0,a++,h(p)}function d(p){return ie(p)?(e.enter("listItemPrefixWhitespace"),e.consume(p),e.exit("listItemPrefixWhitespace"),h):n(p)}function h(p){return r.containerState.size=a+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(p)}}function o2(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(er,i,a);function i(o){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,oe(e,t,"listItemIndent",r.containerState.size+1)(o)}function a(o){return r.containerState.furtherBlankLines||!ie(o)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,s(o)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(a2,t,s)(o))}function s(o){return r.containerState._closeFlow=!0,r.interrupt=void 0,oe(e,e.attempt(We,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(o)}}function u2(e,t,n){const r=this;return oe(e,i,"listItemIndent",r.containerState.size+1);function i(a){const s=r.events[r.events.length-1];return s&&s[1].type==="listItemIndent"&&s[2].sliceSerialize(s[1],!0).length===r.containerState.size?t(a):n(a)}}function l2(e){e.exit(this.containerState.type)}function c2(e,t,n){const r=this;return oe(e,i,"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4+1);function i(a){const s=r.events[r.events.length-1];return!ie(a)&&s&&s[1].type==="listItemPrefixWhitespace"?t(a):n(a)}}const ql={name:"setextUnderline",resolveTo:d2,tokenize:f2};function d2(e,t){let n=e.length,r,i,a;for(;n--;)if(e[n][0]==="enter"){if(e[n][1].type==="content"){r=n;break}e[n][1].type==="paragraph"&&(i=n)}else e[n][1].type==="content"&&e.splice(n,1),!a&&e[n][1].type==="definition"&&(a=n);const s={type:"setextHeading",start:{...e[r][1].start},end:{...e[e.length-1][1].end}};return e[i][1].type="setextHeadingText",a?(e.splice(i,0,["enter",s,t]),e.splice(a+1,0,["exit",e[r][1],t]),e[r][1].end={...e[a][1].end}):e[r][1]=s,e.push(["exit",s,t]),e}function f2(e,t,n){const r=this;let i;return a;function a(c){let f=r.events.length,d;for(;f--;)if(r.events[f][1].type!=="lineEnding"&&r.events[f][1].type!=="linePrefix"&&r.events[f][1].type!=="content"){d=r.events[f][1].type==="paragraph";break}return!r.parser.lazy[r.now().line]&&(r.interrupt||d)?(e.enter("setextHeadingLine"),i=c,s(c)):n(c)}function s(c){return e.enter("setextHeadingLineSequence"),o(c)}function o(c){return c===i?(e.consume(c),o):(e.exit("setextHeadingLineSequence"),ie(c)?oe(e,u,"lineSuffix")(c):u(c))}function u(c){return c===null||G(c)?(e.exit("setextHeadingLine"),t(c)):n(c)}}const h2={tokenize:k2,partial:!0};function p2(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:E2,continuation:{tokenize:T2},exit:_2}},text:{91:{name:"gfmFootnoteCall",tokenize:b2},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:m2,resolveTo:g2}}}}function m2(e,t,n){const r=this;let i=r.events.length;const a=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let s;for(;i--;){const u=r.events[i][1];if(u.type==="labelImage"){s=u;break}if(u.type==="gfmFootnoteCall"||u.type==="labelLink"||u.type==="label"||u.type==="image"||u.type==="link")break}return o;function o(u){if(!s||!s._balanced)return n(u);const c=ut(r.sliceSerialize({start:s.end,end:r.now()}));return c.codePointAt(0)!==94||!a.includes(c.slice(1))?n(u):(e.enter("gfmFootnoteCallLabelMarker"),e.consume(u),e.exit("gfmFootnoteCallLabelMarker"),t(u))}}function g2(e,t){let n=e.length;for(;n--&&!(e[n][1].type==="labelImage"&&e[n][0]==="enter"););e[n+1][1].type="data",e[n+3][1].type="gfmFootnoteCallLabelMarker";const r={type:"gfmFootnoteCall",start:Object.assign({},e[n+3][1].start),end:Object.assign({},e[e.length-1][1].end)},i={type:"gfmFootnoteCallMarker",start:Object.assign({},e[n+3][1].end),end:Object.assign({},e[n+3][1].end)};i.end.column++,i.end.offset++,i.end._bufferIndex++;const a={type:"gfmFootnoteCallString",start:Object.assign({},i.end),end:Object.assign({},e[e.length-1][1].start)},s={type:"chunkString",contentType:"string",start:Object.assign({},a.start),end:Object.assign({},a.end)},o=[e[n+1],e[n+2],["enter",r,t],e[n+3],e[n+4],["enter",i,t],["exit",i,t],["enter",a,t],["enter",s,t],["exit",s,t],["exit",a,t],e[e.length-2],e[e.length-1],["exit",r,t]];return e.splice(n,e.length-n+1,...o),e}function b2(e,t,n){const r=this,i=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let a=0,s;return o;function o(d){return e.enter("gfmFootnoteCall"),e.enter("gfmFootnoteCallLabelMarker"),e.consume(d),e.exit("gfmFootnoteCallLabelMarker"),u}function u(d){return d!==94?n(d):(e.enter("gfmFootnoteCallMarker"),e.consume(d),e.exit("gfmFootnoteCallMarker"),e.enter("gfmFootnoteCallString"),e.enter("chunkString").contentType="string",c)}function c(d){if(a>999||d===93&&!s||d===null||d===91||pe(d))return n(d);if(d===93){e.exit("chunkString");const h=e.exit("gfmFootnoteCallString");return i.includes(ut(r.sliceSerialize(h)))?(e.enter("gfmFootnoteCallLabelMarker"),e.consume(d),e.exit("gfmFootnoteCallLabelMarker"),e.exit("gfmFootnoteCall"),t):n(d)}return pe(d)||(s=!0),a++,e.consume(d),d===92?f:c}function f(d){return d===91||d===92||d===93?(e.consume(d),a++,c):c(d)}}function E2(e,t,n){const r=this,i=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let a,s=0,o;return u;function u(m){return e.enter("gfmFootnoteDefinition")._container=!0,e.enter("gfmFootnoteDefinitionLabel"),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(m),e.exit("gfmFootnoteDefinitionLabelMarker"),c}function c(m){return m===94?(e.enter("gfmFootnoteDefinitionMarker"),e.consume(m),e.exit("gfmFootnoteDefinitionMarker"),e.enter("gfmFootnoteDefinitionLabelString"),e.enter("chunkString").contentType="string",f):n(m)}function f(m){if(s>999||m===93&&!o||m===null||m===91||pe(m))return n(m);if(m===93){e.exit("chunkString");const _=e.exit("gfmFootnoteDefinitionLabelString");return a=ut(r.sliceSerialize(_)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(m),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),h}return pe(m)||(o=!0),s++,e.consume(m),m===92?d:f}function d(m){return m===91||m===92||m===93?(e.consume(m),s++,f):f(m)}function h(m){return m===58?(e.enter("definitionMarker"),e.consume(m),e.exit("definitionMarker"),i.includes(a)||i.push(a),oe(e,p,"gfmFootnoteDefinitionWhitespace")):n(m)}function p(m){return t(m)}}function T2(e,t,n){return e.check(er,t,e.attempt(h2,t,n))}function _2(e){e.exit("gfmFootnoteDefinition")}function k2(e,t,n){const r=this;return oe(e,i,"gfmFootnoteDefinitionIndent",4+1);function i(a){const s=r.events[r.events.length-1];return s&&s[1].type==="gfmFootnoteDefinitionIndent"&&s[2].sliceSerialize(s[1],!0).length===4?t(a):n(a)}}function x2(e){let n=(e||{}).singleTilde;const r={name:"strikethrough",tokenize:a,resolveAll:i};return n==null&&(n=!0),{text:{126:r},insideSpan:{null:[r]},attentionMarkers:{null:[126]}};function i(s,o){let u=-1;for(;++u<s.length;)if(s[u][0]==="enter"&&s[u][1].type==="strikethroughSequenceTemporary"&&s[u][1]._close){let c=u;for(;c--;)if(s[c][0]==="exit"&&s[c][1].type==="strikethroughSequenceTemporary"&&s[c][1]._open&&s[u][1].end.offset-s[u][1].start.offset===s[c][1].end.offset-s[c][1].start.offset){s[u][1].type="strikethroughSequence",s[c][1].type="strikethroughSequence";const f={type:"strikethrough",start:Object.assign({},s[c][1].start),end:Object.assign({},s[u][1].end)},d={type:"strikethroughText",start:Object.assign({},s[c][1].end),end:Object.assign({},s[u][1].start)},h=[["enter",f,o],["enter",s[c][1],o],["exit",s[c][1],o],["enter",d,o]],p=o.parser.constructs.insideSpan.null;p&&Ke(h,h.length,0,Xr(p,s.slice(c+1,u),o)),Ke(h,h.length,0,[["exit",d,o],["enter",s[u][1],o],["exit",s[u][1],o],["exit",f,o]]),Ke(s,c-1,u-c+3,h),u=c+h.length-2;break}}for(u=-1;++u<s.length;)s[u][1].type==="strikethroughSequenceTemporary"&&(s[u][1].type="data");return s}function a(s,o,u){const c=this.previous,f=this.events;let d=0;return h;function h(m){return c===126&&f[f.length-1][1].type!=="characterEscape"?u(m):(s.enter("strikethroughSequenceTemporary"),p(m))}function p(m){const _=Tn(c);if(m===126)return d>1?u(m):(s.consume(m),d++,p);if(d<2&&!n)return u(m);const A=s.exit("strikethroughSequenceTemporary"),y=Tn(m);return A._open=!y||y===2&&!!_,A._close=!_||_===2&&!!y,o(m)}}}class y2{constructor(){this.map=[]}add(t,n,r){w2(this,t,n,r)}consume(t){if(this.map.sort(function(a,s){return a[0]-s[0]}),this.map.length===0)return;let n=this.map.length;const r=[];for(;n>0;)n-=1,r.push(t.slice(this.map[n][0]+this.map[n][1]),this.map[n][2]),t.length=this.map[n][0];r.push(t.slice()),t.length=0;let i=r.pop();for(;i;){for(const a of i)t.push(a);i=r.pop()}this.map.length=0}}function w2(e,t,n,r){let i=0;if(!(n===0&&r.length===0)){for(;i<e.map.length;){if(e.map[i][0]===t){e.map[i][1]+=n,e.map[i][2].push(...r);return}i+=1}e.map.push([t,n,r])}}function A2(e,t){let n=!1;const r=[];for(;t<e.length;){const i=e[t];if(n){if(i[0]==="enter")i[1].type==="tableContent"&&r.push(e[t+1][1].type==="tableDelimiterMarker"?"left":"none");else if(i[1].type==="tableContent"){if(e[t-1][1].type==="tableDelimiterMarker"){const a=r.length-1;r[a]=r[a]==="left"?"center":"right"}}else if(i[1].type==="tableDelimiterRow")break}else i[0]==="enter"&&i[1].type==="tableDelimiterRow"&&(n=!0);t+=1}return r}function C2(){return{flow:{null:{name:"table",tokenize:S2,resolveAll:I2}}}}function S2(e,t,n){const r=this;let i=0,a=0,s;return o;function o(C){let $=r.events.length-1;for(;$>-1;){const ae=r.events[$][1].type;if(ae==="lineEnding"||ae==="linePrefix")$--;else break}const B=$>-1?r.events[$][1].type:null,Q=B==="tableHead"||B==="tableRow"?w:u;return Q===w&&r.parser.lazy[r.now().line]?n(C):Q(C)}function u(C){return e.enter("tableHead"),e.enter("tableRow"),c(C)}function c(C){return C===124||(s=!0,a+=1),f(C)}function f(C){return C===null?n(C):G(C)?a>1?(a=0,r.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(C),e.exit("lineEnding"),p):n(C):ie(C)?oe(e,f,"whitespace")(C):(a+=1,s&&(s=!1,i+=1),C===124?(e.enter("tableCellDivider"),e.consume(C),e.exit("tableCellDivider"),s=!0,f):(e.enter("data"),d(C)))}function d(C){return C===null||C===124||pe(C)?(e.exit("data"),f(C)):(e.consume(C),C===92?h:d)}function h(C){return C===92||C===124?(e.consume(C),d):d(C)}function p(C){return r.interrupt=!1,r.parser.lazy[r.now().line]?n(C):(e.enter("tableDelimiterRow"),s=!1,ie(C)?oe(e,m,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(C):m(C))}function m(C){return C===45||C===58?A(C):C===124?(s=!0,e.enter("tableCellDivider"),e.consume(C),e.exit("tableCellDivider"),_):P(C)}function _(C){return ie(C)?oe(e,A,"whitespace")(C):A(C)}function A(C){return C===58?(a+=1,s=!0,e.enter("tableDelimiterMarker"),e.consume(C),e.exit("tableDelimiterMarker"),y):C===45?(a+=1,y(C)):C===null||G(C)?D(C):P(C)}function y(C){return C===45?(e.enter("tableDelimiterFiller"),I(C)):P(C)}function I(C){return C===45?(e.consume(C),I):C===58?(s=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(C),e.exit("tableDelimiterMarker"),S):(e.exit("tableDelimiterFiller"),S(C))}function S(C){return ie(C)?oe(e,D,"whitespace")(C):D(C)}function D(C){return C===124?m(C):C===null||G(C)?!s||i!==a?P(C):(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(C)):P(C)}function P(C){return n(C)}function w(C){return e.enter("tableRow"),z(C)}function z(C){return C===124?(e.enter("tableCellDivider"),e.consume(C),e.exit("tableCellDivider"),z):C===null||G(C)?(e.exit("tableRow"),t(C)):ie(C)?oe(e,z,"whitespace")(C):(e.enter("data"),L(C))}function L(C){return C===null||C===124||pe(C)?(e.exit("data"),z(C)):(e.consume(C),C===92?H:L)}function H(C){return C===92||C===124?(e.consume(C),L):L(C)}}function I2(e,t){let n=-1,r=!0,i=0,a=[0,0,0,0],s=[0,0,0,0],o=!1,u=0,c,f,d;const h=new y2;for(;++n<e.length;){const p=e[n],m=p[1];p[0]==="enter"?m.type==="tableHead"?(o=!1,u!==0&&(Wl(h,t,u,c,f),f=void 0,u=0),c={type:"table",start:Object.assign({},m.start),end:Object.assign({},m.end)},h.add(n,0,[["enter",c,t]])):m.type==="tableRow"||m.type==="tableDelimiterRow"?(r=!0,d=void 0,a=[0,0,0,0],s=[0,n+1,0,0],o&&(o=!1,f={type:"tableBody",start:Object.assign({},m.start),end:Object.assign({},m.end)},h.add(n,0,[["enter",f,t]])),i=m.type==="tableDelimiterRow"?2:f?3:1):i&&(m.type==="data"||m.type==="tableDelimiterMarker"||m.type==="tableDelimiterFiller")?(r=!1,s[2]===0&&(a[1]!==0&&(s[0]=s[1],d=Jr(h,t,a,i,void 0,d),a=[0,0,0,0]),s[2]=n)):m.type==="tableCellDivider"&&(r?r=!1:(a[1]!==0&&(s[0]=s[1],d=Jr(h,t,a,i,void 0,d)),a=s,s=[a[1],n,0,0])):m.type==="tableHead"?(o=!0,u=n):m.type==="tableRow"||m.type==="tableDelimiterRow"?(u=n,a[1]!==0?(s[0]=s[1],d=Jr(h,t,a,i,n,d)):s[1]!==0&&(d=Jr(h,t,s,i,n,d)),i=0):i&&(m.type==="data"||m.type==="tableDelimiterMarker"||m.type==="tableDelimiterFiller")&&(s[3]=n)}for(u!==0&&Wl(h,t,u,c,f),h.consume(t.events),n=-1;++n<t.events.length;){const p=t.events[n];p[0]==="enter"&&p[1].type==="table"&&(p[1]._align=A2(t.events,n))}return e}function Jr(e,t,n,r,i,a){const s=r===1?"tableHeader":r===2?"tableDelimiter":"tableData",o="tableContent";n[0]!==0&&(a.end=Object.assign({},kn(t.events,n[0])),e.add(n[0],0,[["exit",a,t]]));const u=kn(t.events,n[1]);if(a={type:s,start:Object.assign({},u),end:Object.assign({},u)},e.add(n[1],0,[["enter",a,t]]),n[2]!==0){const c=kn(t.events,n[2]),f=kn(t.events,n[3]),d={type:o,start:Object.assign({},c),end:Object.assign({},f)};if(e.add(n[2],0,[["enter",d,t]]),r!==2){const h=t.events[n[2]],p=t.events[n[3]];if(h[1].end=Object.assign({},p[1].end),h[1].type="chunkText",h[1].contentType="text",n[3]>n[2]+1){const m=n[2]+1,_=n[3]-n[2]-1;e.add(m,_,[])}}e.add(n[3]+1,0,[["exit",d,t]])}return i!==void 0&&(a.end=Object.assign({},kn(t.events,i)),e.add(i,0,[["exit",a,t]]),a=void 0),a}function Wl(e,t,n,r,i){const a=[],s=kn(t.events,n);i&&(i.end=Object.assign({},s),a.push(["exit",i,t])),r.end=Object.assign({},s),a.push(["exit",r,t]),e.add(n+1,0,a)}function kn(e,t){const n=e[t],r=n[0]==="enter"?"start":"end";return n[1][r]}const N2={name:"tasklistCheck",tokenize:L2};function v2(){return{text:{91:N2}}}function L2(e,t,n){const r=this;return i;function i(u){return r.previous!==null||!r._gfmTasklistFirstContentOfListItem?n(u):(e.enter("taskListCheck"),e.enter("taskListCheckMarker"),e.consume(u),e.exit("taskListCheckMarker"),a)}function a(u){return pe(u)?(e.enter("taskListCheckValueUnchecked"),e.consume(u),e.exit("taskListCheckValueUnchecked"),s):u===88||u===120?(e.enter("taskListCheckValueChecked"),e.consume(u),e.exit("taskListCheckValueChecked"),s):n(u)}function s(u){return u===93?(e.enter("taskListCheckMarker"),e.consume(u),e.exit("taskListCheckMarker"),e.exit("taskListCheck"),o):n(u)}function o(u){return G(u)?t(u):ie(u)?e.check({tokenize:R2},t,n)(u):n(u)}}function R2(e,t,n){return oe(e,r,"whitespace");function r(i){return i===null?n(i):t(i)}}function O2(e){return Cl([Yg(),p2(),x2(e),C2(),v2()])}const D2={};function P2(e){const t=this,n=e||D2,r=t.data(),i=r.micromarkExtensions||(r.micromarkExtensions=[]),a=r.fromMarkdownExtensions||(r.fromMarkdownExtensions=[]),s=r.toMarkdownExtensions||(r.toMarkdownExtensions=[]);i.push(O2(n)),a.push(Bg()),s.push(Fg(n))}var M2=Object.defineProperty,B2=Object.defineProperties,F2=Object.getOwnPropertyDescriptors,Gl=Object.getOwnPropertySymbols,H2=Object.prototype.hasOwnProperty,U2=Object.prototype.propertyIsEnumerable,Ql=(e,t,n)=>t in e?M2(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,Kl=(e,t)=>{for(var n in t||(t={}))H2.call(t,n)&&Ql(e,n,t[n]);if(Gl)for(var n of Gl(t))U2.call(t,n)&&Ql(e,n,t[n]);return e},Xl=(e,t)=>B2(e,F2(t)),z2=/(\*\*)([^*]*\*?)$/,$2=/(__)([^_]*?)$/,Y2=/(\*\*\*)([^*]*?)$/,j2=/(\*)([^*]*?)$/,V2=/(_)([^_]*?)$/,q2=/(`)([^`]*?)$/,W2=/(~~)([^~]*?)$/,Zt=/^[\s_~*`]*$/,Zl=/^[\s]*[-*+][\s]+$/,G2=/[\p{L}\p{N}_]/u,Q2=/^```[^`\n]*```?$/,K2=/^\*{4,}$/,X2=/(__)([^_]+)_$/,Z2=/(~~)([^~]+)~$/,J2=/__/g,Jl=/~~/g,Dt=e=>{if(!e)return!1;let t=e.charCodeAt(0);return t>=48&&t<=57||t>=65&&t<=90||t>=97&&t<=122||t===95?!0:G2.test(e)},xn=(e,t)=>{let n=!1;for(let r=0;r<t;r+=1)e[r]==="`"&&e[r+1]==="`"&&e[r+2]==="`"&&(n=!n,r+=2);return n},eE=(e,t)=>{let n=1;for(let r=t-1;r>=0;r-=1)if(e[r]==="]")n+=1;else if(e[r]==="["&&(n-=1,n===0))return r;return-1},ec=(e,t)=>{let n=1;for(let r=t+1;r<e.length;r+=1)if(e[r]==="[")n+=1;else if(e[r]==="]"&&(n-=1,n===0))return r;return-1},ei=(e,t)=>{let n=!1,r=!1;for(let i=0;i<e.length&&i<t;i+=1){if(e[i]==="\\"&&e[i+1]==="$"){i+=1;continue}e[i]==="$"&&(e[i+1]==="$"?(r=!r,i+=1,n=!1):r||(n=!n))}return n||r},tE=(e,t)=>{for(let n=t;n<e.length;n+=1){if(e[n]===")")return!0;if(e[n]===`
|
|
18
|
-
`)return!1}return!1},
|
|
19
|
-
`)return!1}return!1},
|
|
15
|
+
`,...a.current()});return/^[\t ]/.test(c)&&(c=or(c.charCodeAt(0))+c.slice(1)),c=c?s+" "+c:s,n.options.closeAtx&&(c+=" "+s),u(),o(),c}Tl.peek=Rg;function Tl(e){return e.value||""}function Rg(){return"<"}_l.peek=Og;function _l(e,t,n,r){const i=Sa(n),a=i==='"'?"Quote":"Apostrophe",s=n.enter("image");let o=n.enter("label");const u=n.createTracker(r);let c=u.move("![");return c+=u.move(n.safe(e.alt,{before:c,after:"]",...u.current()})),c+=u.move("]("),o(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(o=n.enter("destinationLiteral"),c+=u.move("<"),c+=u.move(n.safe(e.url,{before:c,after:">",...u.current()})),c+=u.move(">")):(o=n.enter("destinationRaw"),c+=u.move(n.safe(e.url,{before:c,after:e.title?" ":")",...u.current()}))),o(),e.title&&(o=n.enter(`title${a}`),c+=u.move(" "+i),c+=u.move(n.safe(e.title,{before:c,after:i,...u.current()})),c+=u.move(i),o()),c+=u.move(")"),s(),c}function Og(){return"!"}kl.peek=Dg;function kl(e,t,n,r){const i=e.referenceType,a=n.enter("imageReference");let s=n.enter("label");const o=n.createTracker(r);let u=o.move("![");const c=n.safe(e.alt,{before:u,after:"]",...o.current()});u+=o.move(c+"]["),s();const f=n.stack;n.stack=[],s=n.enter("reference");const d=n.safe(n.associationId(e),{before:u,after:"]",...o.current()});return s(),n.stack=f,a(),i==="full"||!c||c!==d?u+=o.move(d+"]"):i==="shortcut"?u=u.slice(0,-1):u+=o.move("]"),u}function Dg(){return"!"}xl.peek=Pg;function xl(e,t,n){let r=e.value||"",i="`",a=-1;for(;new RegExp("(^|[^`])"+i+"([^`]|$)").test(r);)i+="`";for(/[^ \r\n]/.test(r)&&(/^[ \r\n]/.test(r)&&/[ \r\n]$/.test(r)||/^`|`$/.test(r))&&(r=" "+r+" ");++a<n.unsafe.length;){const s=n.unsafe[a],o=n.compilePattern(s);let u;if(s.atBreak)for(;u=o.exec(r);){let c=u.index;r.charCodeAt(c)===10&&r.charCodeAt(c-1)===13&&c--,r=r.slice(0,c)+" "+r.slice(u.index+1)}}return i+r+i}function Pg(){return"`"}function yl(e,t){const n=Na(e);return!!(!t.options.resourceLink&&e.url&&!e.title&&e.children&&e.children.length===1&&e.children[0].type==="text"&&(n===e.url||"mailto:"+n===e.url)&&/^[a-z][a-z+.-]+:/i.test(e.url)&&!/[\0- <>\u007F]/.test(e.url))}wl.peek=Mg;function wl(e,t,n,r){const i=Sa(n),a=i==='"'?"Quote":"Apostrophe",s=n.createTracker(r);let o,u;if(yl(e,n)){const f=n.stack;n.stack=[],o=n.enter("autolink");let d=s.move("<");return d+=s.move(n.containerPhrasing(e,{before:d,after:">",...s.current()})),d+=s.move(">"),o(),n.stack=f,d}o=n.enter("link"),u=n.enter("label");let c=s.move("[");return c+=s.move(n.containerPhrasing(e,{before:c,after:"](",...s.current()})),c+=s.move("]("),u(),!e.url&&e.title||/[\0- \u007F]/.test(e.url)?(u=n.enter("destinationLiteral"),c+=s.move("<"),c+=s.move(n.safe(e.url,{before:c,after:">",...s.current()})),c+=s.move(">")):(u=n.enter("destinationRaw"),c+=s.move(n.safe(e.url,{before:c,after:e.title?" ":")",...s.current()}))),u(),e.title&&(u=n.enter(`title${a}`),c+=s.move(" "+i),c+=s.move(n.safe(e.title,{before:c,after:i,...s.current()})),c+=s.move(i),u()),c+=s.move(")"),o(),c}function Mg(e,t,n){return yl(e,n)?"<":"["}Al.peek=Bg;function Al(e,t,n,r){const i=e.referenceType,a=n.enter("linkReference");let s=n.enter("label");const o=n.createTracker(r);let u=o.move("[");const c=n.containerPhrasing(e,{before:u,after:"]",...o.current()});u+=o.move(c+"]["),s();const f=n.stack;n.stack=[],s=n.enter("reference");const d=n.safe(n.associationId(e),{before:u,after:"]",...o.current()});return s(),n.stack=f,a(),i==="full"||!c||c!==d?u+=o.move(d+"]"):i==="shortcut"?u=u.slice(0,-1):u+=o.move("]"),u}function Bg(){return"["}function Ia(e){const t=e.options.bullet||"*";if(t!=="*"&&t!=="+"&&t!=="-")throw new Error("Cannot serialize items with `"+t+"` for `options.bullet`, expected `*`, `+`, or `-`");return t}function Fg(e){const t=Ia(e),n=e.options.bulletOther;if(!n)return t==="*"?"-":"*";if(n!=="*"&&n!=="+"&&n!=="-")throw new Error("Cannot serialize items with `"+n+"` for `options.bulletOther`, expected `*`, `+`, or `-`");if(n===t)throw new Error("Expected `bullet` (`"+t+"`) and `bulletOther` (`"+n+"`) to be different");return n}function Hg(e){const t=e.options.bulletOrdered||".";if(t!=="."&&t!==")")throw new Error("Cannot serialize items with `"+t+"` for `options.bulletOrdered`, expected `.` or `)`");return t}function Cl(e){const t=e.options.rule||"*";if(t!=="*"&&t!=="-"&&t!=="_")throw new Error("Cannot serialize rules with `"+t+"` for `options.rule`, expected `*`, `-`, or `_`");return t}function Ug(e,t,n,r){const i=n.enter("list"),a=n.bulletCurrent;let s=e.ordered?Hg(n):Ia(n);const o=e.ordered?s==="."?")":".":Fg(n);let u=t&&n.bulletLastUsed?s===n.bulletLastUsed:!1;if(!e.ordered){const f=e.children?e.children[0]:void 0;if((s==="*"||s==="-")&&f&&(!f.children||!f.children[0])&&n.stack[n.stack.length-1]==="list"&&n.stack[n.stack.length-2]==="listItem"&&n.stack[n.stack.length-3]==="list"&&n.stack[n.stack.length-4]==="listItem"&&n.indexStack[n.indexStack.length-1]===0&&n.indexStack[n.indexStack.length-2]===0&&n.indexStack[n.indexStack.length-3]===0&&(u=!0),Cl(n)===s&&f){let d=-1;for(;++d<e.children.length;){const h=e.children[d];if(h&&h.type==="listItem"&&h.children&&h.children[0]&&h.children[0].type==="thematicBreak"){u=!0;break}}}}u&&(s=o),n.bulletCurrent=s;const c=n.containerFlow(e,r);return n.bulletLastUsed=s,n.bulletCurrent=a,i(),c}function zg(e){const t=e.options.listItemIndent||"one";if(t!=="tab"&&t!=="one"&&t!=="mixed")throw new Error("Cannot serialize items with `"+t+"` for `options.listItemIndent`, expected `tab`, `one`, or `mixed`");return t}function $g(e,t,n,r){const i=zg(n);let a=n.bulletCurrent||Ia(n);t&&t.type==="list"&&t.ordered&&(a=(typeof t.start=="number"&&t.start>-1?t.start:1)+(n.options.incrementListMarker===!1?0:t.children.indexOf(e))+a);let s=a.length+1;(i==="tab"||i==="mixed"&&(t&&t.type==="list"&&t.spread||e.spread))&&(s=Math.ceil(s/4)*4);const o=n.createTracker(r);o.move(a+" ".repeat(s-a.length)),o.shift(s);const u=n.enter("listItem"),c=n.indentLines(n.containerFlow(e,o.current()),f);return u(),c;function f(d,h,p){return h?(p?"":" ".repeat(s))+d:(p?a:a+" ".repeat(s-a.length))+d}}function Yg(e,t,n,r){const i=n.enter("paragraph"),a=n.enter("phrasing"),s=n.containerPhrasing(e,r);return a(),i(),s}const jg=Hr(["break","delete","emphasis","footnote","footnoteReference","image","imageReference","inlineCode","inlineMath","link","linkReference","mdxJsxTextElement","mdxTextExpression","strong","text","textDirective"]);function Vg(e,t,n,r){return(e.children.some(function(s){return jg(s)})?n.containerPhrasing:n.containerFlow).call(n,e,r)}function qg(e){const t=e.options.strong||"*";if(t!=="*"&&t!=="_")throw new Error("Cannot serialize strong with `"+t+"` for `options.strong`, expected `*`, or `_`");return t}Sl.peek=Wg;function Sl(e,t,n,r){const i=qg(n),a=n.enter("strong"),s=n.createTracker(r),o=s.move(i+i);let u=s.move(n.containerPhrasing(e,{after:i,before:o,...s.current()}));const c=u.charCodeAt(0),f=ii(r.before.charCodeAt(r.before.length-1),c,i);f.inside&&(u=or(c)+u.slice(1));const d=u.charCodeAt(u.length-1),h=ii(r.after.charCodeAt(0),d,i);h.inside&&(u=u.slice(0,-1)+or(d));const p=s.move(i+i);return a(),n.attentionEncodeSurroundingInfo={after:h.outside,before:f.outside},o+u+p}function Wg(e,t,n){return n.options.strong||"*"}function Gg(e,t,n,r){return n.safe(e.value,r)}function Qg(e){const t=e.options.ruleRepetition||3;if(t<3)throw new Error("Cannot serialize rules with repetition `"+t+"` for `options.ruleRepetition`, expected `3` or more");return t}function Kg(e,t,n){const r=(Cl(n)+(n.options.ruleSpaces?" ":"")).repeat(Qg(n));return n.options.ruleSpaces?r.slice(0,-1):r}const Nl={blockquote:bg,break:ml,code:yg,definition:Ag,emphasis:gl,hardBreak:ml,heading:Lg,html:Tl,image:_l,imageReference:kl,inlineCode:xl,link:wl,linkReference:Al,list:Ug,listItem:$g,paragraph:Yg,root:Vg,strong:Sl,text:Gg,thematicBreak:Kg},Il=document.createElement("i");function va(e){const t="&"+e+";";Il.innerHTML=t;const n=Il.textContent;return n.charCodeAt(n.length-1)===59&&e!=="semi"||n===t?!1:n}function vl(e,t){const n=Number.parseInt(e,t);return n<9||n===11||n>13&&n<32||n>126&&n<160||n>55295&&n<57344||n>64975&&n<65008||(n&65535)===65535||(n&65535)===65534||n>1114111?"�":String.fromCodePoint(n)}const Xg=/\\([!-/:-@[-`{-~])|&(#(?:\d{1,7}|x[\da-f]{1,6})|[\da-z]{1,31});/gi;function Zg(e){return e.replace(Xg,Jg)}function Jg(e,t,n){if(t)return t;if(n.charCodeAt(0)===35){const i=n.charCodeAt(1),a=i===120||i===88;return vl(n.slice(a?2:1),a?16:10)}return va(n)||e}function eb(){return{enter:{table:tb,tableData:Ll,tableHeader:Ll,tableRow:rb},exit:{codeText:ib,table:nb,tableData:La,tableHeader:La,tableRow:La}}}function tb(e){const t=e._align;this.enter({type:"table",align:t.map(function(n){return n==="none"?null:n}),children:[]},e),this.data.inTable=!0}function nb(e){this.exit(e),this.data.inTable=void 0}function rb(e){this.enter({type:"tableRow",children:[]},e)}function La(e){this.exit(e)}function Ll(e){this.enter({type:"tableCell",children:[]},e)}function ib(e){let t=this.resume();this.data.inTable&&(t=t.replace(/\\([\\|])/g,ab));const n=this.stack[this.stack.length-1];n.value=t,this.exit(e)}function ab(e,t){return t==="|"?t:e}function sb(e){const t=e||{},n=t.tableCellPadding,r=t.tablePipeAlign,i=t.stringLength,a=n?" ":"|";return{unsafe:[{character:"\r",inConstruct:"tableCell"},{character:`
|
|
16
|
+
`,inConstruct:"tableCell"},{atBreak:!0,character:"|",after:"[ :-]"},{character:"|",inConstruct:"tableCell"},{atBreak:!0,character:":",after:"-"},{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{inlineCode:h,table:s,tableCell:u,tableRow:o}};function s(p,m,_,w){return c(f(p,_,w),p.align)}function o(p,m,_,w){const y=d(p,_,w),S=c([y]);return S.slice(0,S.indexOf(`
|
|
17
|
+
`))}function u(p,m,_,w){const y=_.enter("tableCell"),S=_.enter("phrasing"),C=_.containerPhrasing(p,{...w,before:a,after:a});return S(),y(),C}function c(p,m){return mg(p,{align:m,alignDelimiters:r,padding:n,stringLength:i})}function f(p,m,_){const w=p.children;let y=-1;const S=[],C=m.enter("table");for(;++y<w.length;)S[y]=d(w[y],m,_);return C(),S}function d(p,m,_){const w=p.children;let y=-1;const S=[],C=m.enter("tableRow");for(;++y<w.length;)S[y]=u(w[y],p,m,_);return C(),S}function h(p,m,_){let w=Nl.inlineCode(p,m,_);return _.stack.includes("tableCell")&&(w=w.replace(/\|/g,"\\$&")),w}}function ob(){return{exit:{taskListCheckValueChecked:Rl,taskListCheckValueUnchecked:Rl,paragraph:lb}}}function ub(){return{unsafe:[{atBreak:!0,character:"-",after:"[:|-]"}],handlers:{listItem:cb}}}function Rl(e){const t=this.stack[this.stack.length-2];t.checked=e.type==="taskListCheckValueChecked"}function lb(e){const t=this.stack[this.stack.length-2];if(t&&t.type==="listItem"&&typeof t.checked=="boolean"){const n=this.stack[this.stack.length-1],r=n.children[0];if(r&&r.type==="text"){const i=t.children;let a=-1,s;for(;++a<i.length;){const o=i[a];if(o.type==="paragraph"){s=o;break}}s===n&&(r.value=r.value.slice(1),r.value.length===0?n.children.shift():n.position&&r.position&&typeof r.position.start.offset=="number"&&(r.position.start.column++,r.position.start.offset++,n.position.start=Object.assign({},r.position.start)))}}this.exit(e)}function cb(e,t,n,r){const i=e.children[0],a=typeof e.checked=="boolean"&&i&&i.type==="paragraph",s="["+(e.checked?"x":" ")+"] ",o=n.createTracker(r);a&&o.move(s);let u=Nl.listItem(e,t,n,{...r,...o.current()});return a&&(u=u.replace(/^(?:[*+-]|\d+\.)([\r\n]| {1,3})/,c)),u;function c(f){return f+s}}function db(){return[F1(),ag(),lg(),eb(),ob()]}function fb(e){return{extensions:[H1(),sg(e),cg(),sb(e),ub()]}}function Ke(e,t,n,r){const i=e.length;let a=0,s;if(t<0?t=-t>i?0:i+t:t=t>i?i:t,n=n>0?n:0,r.length<1e4)s=Array.from(r),s.unshift(t,n),e.splice(...s);else for(n&&e.splice(t,n);a<r.length;)s=r.slice(a,a+1e4),s.unshift(t,0),e.splice(...s),a+=1e4,t+=1e4}function nt(e,t){return e.length>0?(Ke(e,e.length,0,t),e):t}const Ol={}.hasOwnProperty;function Dl(e){const t={};let n=-1;for(;++n<e.length;)hb(t,e[n]);return t}function hb(e,t){let n;for(n in t){const i=(Ol.call(e,n)?e[n]:void 0)||(e[n]={}),a=t[n];let s;if(a)for(s in a){Ol.call(i,s)||(i[s]=[]);const o=a[s];pb(i[s],Array.isArray(o)?o:o?[o]:[])}}}function pb(e,t){let n=-1;const r=[];for(;++n<t.length;)(t[n].add==="after"?e:r).push(t[n]);Ke(e,0,0,r)}const mb={tokenize:kb,partial:!0},Pl={tokenize:xb,partial:!0},Ml={tokenize:yb,partial:!0},Bl={tokenize:wb,partial:!0},gb={tokenize:Ab,partial:!0},Fl={name:"wwwAutolink",tokenize:Tb,previous:Ul},Hl={name:"protocolAutolink",tokenize:_b,previous:zl},yt={name:"emailAutolink",tokenize:Eb,previous:$l},bt={};function bb(){return{text:bt}}let nn=48;for(;nn<123;)bt[nn]=yt,nn++,nn===58?nn=65:nn===91&&(nn=97);bt[43]=yt,bt[45]=yt,bt[46]=yt,bt[95]=yt,bt[72]=[yt,Hl],bt[104]=[yt,Hl],bt[87]=[yt,Fl],bt[119]=[yt,Fl];function Eb(e,t,n){const r=this;let i,a;return s;function s(d){return!Ra(d)||!$l.call(r,r.previous)||Oa(r.events)?n(d):(e.enter("literalAutolink"),e.enter("literalAutolinkEmail"),o(d))}function o(d){return Ra(d)?(e.consume(d),o):d===64?(e.consume(d),u):n(d)}function u(d){return d===46?e.check(gb,f,c)(d):d===45||d===95||Ue(d)?(a=!0,e.consume(d),u):f(d)}function c(d){return e.consume(d),i=!0,u}function f(d){return a&&i&&Ye(r.previous)?(e.exit("literalAutolinkEmail"),e.exit("literalAutolink"),t(d)):n(d)}}function Tb(e,t,n){const r=this;return i;function i(s){return s!==87&&s!==119||!Ul.call(r,r.previous)||Oa(r.events)?n(s):(e.enter("literalAutolink"),e.enter("literalAutolinkWww"),e.check(mb,e.attempt(Pl,e.attempt(Ml,a),n),n)(s))}function a(s){return e.exit("literalAutolinkWww"),e.exit("literalAutolink"),t(s)}}function _b(e,t,n){const r=this;let i="",a=!1;return s;function s(d){return(d===72||d===104)&&zl.call(r,r.previous)&&!Oa(r.events)?(e.enter("literalAutolink"),e.enter("literalAutolinkHttp"),i+=String.fromCodePoint(d),e.consume(d),o):n(d)}function o(d){if(Ye(d)&&i.length<5)return i+=String.fromCodePoint(d),e.consume(d),o;if(d===58){const h=i.toLowerCase();if(h==="http"||h==="https")return e.consume(d),u}return n(d)}function u(d){return d===47?(e.consume(d),a?c:(a=!0,u)):n(d)}function c(d){return d===null||ni(d)||ge(d)||tn(d)||ri(d)?n(d):e.attempt(Pl,e.attempt(Ml,f),n)(d)}function f(d){return e.exit("literalAutolinkHttp"),e.exit("literalAutolink"),t(d)}}function kb(e,t,n){let r=0;return i;function i(s){return(s===87||s===119)&&r<3?(r++,e.consume(s),i):s===46&&r===3?(e.consume(s),a):n(s)}function a(s){return s===null?n(s):t(s)}}function xb(e,t,n){let r,i,a;return s;function s(c){return c===46||c===95?e.check(Bl,u,o)(c):c===null||ge(c)||tn(c)||c!==45&&ri(c)?u(c):(a=!0,e.consume(c),s)}function o(c){return c===95?r=!0:(i=r,r=void 0),e.consume(c),s}function u(c){return i||r||!a?n(c):t(c)}}function yb(e,t){let n=0,r=0;return i;function i(s){return s===40?(n++,e.consume(s),i):s===41&&r<n?a(s):s===33||s===34||s===38||s===39||s===41||s===42||s===44||s===46||s===58||s===59||s===60||s===63||s===93||s===95||s===126?e.check(Bl,t,a)(s):s===null||ge(s)||tn(s)?t(s):(e.consume(s),i)}function a(s){return s===41&&r++,e.consume(s),i}}function wb(e,t,n){return r;function r(o){return o===33||o===34||o===39||o===41||o===42||o===44||o===46||o===58||o===59||o===63||o===95||o===126?(e.consume(o),r):o===38?(e.consume(o),a):o===93?(e.consume(o),i):o===60||o===null||ge(o)||tn(o)?t(o):n(o)}function i(o){return o===null||o===40||o===91||ge(o)||tn(o)?t(o):r(o)}function a(o){return Ye(o)?s(o):n(o)}function s(o){return o===59?(e.consume(o),r):Ye(o)?(e.consume(o),s):n(o)}}function Ab(e,t,n){return r;function r(a){return e.consume(a),i}function i(a){return Ue(a)?n(a):t(a)}}function Ul(e){return e===null||e===40||e===42||e===95||e===91||e===93||e===126||ge(e)}function zl(e){return!Ye(e)}function $l(e){return!(e===47||Ra(e))}function Ra(e){return e===43||e===45||e===46||e===95||Ue(e)}function Oa(e){let t=e.length,n=!1;for(;t--;){const r=e[t][1];if((r.type==="labelLink"||r.type==="labelImage")&&!r._balanced){n=!0;break}if(r._gfmAutolinkLiteralWalkedInto){n=!1;break}}return e.length>0&&!n&&(e[e.length-1][1]._gfmAutolinkLiteralWalkedInto=!0),n}function Nn(e){const t=[];let n=-1,r=0,i=0;for(;++n<e.length;){const a=e.charCodeAt(n);let s="";if(a===37&&Ue(e.charCodeAt(n+1))&&Ue(e.charCodeAt(n+2)))i=2;else if(a<128)/[!#$&-;=?-Z_a-z~]/.test(String.fromCharCode(a))||(s=String.fromCharCode(a));else if(a>55295&&a<57344){const o=e.charCodeAt(n+1);a<56320&&o>56319&&o<57344?(s=String.fromCharCode(a,o),i=1):s="�"}else s=String.fromCharCode(a);s&&(t.push(e.slice(r,n),encodeURIComponent(s)),r=n+i+1,s=""),i&&(n+=i,i=0)}return t.join("")+e.slice(r)}function ai(e,t,n){const r=[];let i=-1;for(;++i<e.length;){const a=e[i].resolveAll;a&&!r.includes(a)&&(t=a(t,n),r.push(a))}return t}const Da={name:"attention",resolveAll:Cb,tokenize:Sb};function Cb(e,t){let n=-1,r,i,a,s,o,u,c,f;for(;++n<e.length;)if(e[n][0]==="enter"&&e[n][1].type==="attentionSequence"&&e[n][1]._close){for(r=n;r--;)if(e[r][0]==="exit"&&e[r][1].type==="attentionSequence"&&e[r][1]._open&&t.sliceSerialize(e[r][1]).charCodeAt(0)===t.sliceSerialize(e[n][1]).charCodeAt(0)){if((e[r][1]._close||e[n][1]._open)&&(e[n][1].end.offset-e[n][1].start.offset)%3&&!((e[r][1].end.offset-e[r][1].start.offset+e[n][1].end.offset-e[n][1].start.offset)%3))continue;u=e[r][1].end.offset-e[r][1].start.offset>1&&e[n][1].end.offset-e[n][1].start.offset>1?2:1;const d={...e[r][1].end},h={...e[n][1].start};Yl(d,-u),Yl(h,u),s={type:u>1?"strongSequence":"emphasisSequence",start:d,end:{...e[r][1].end}},o={type:u>1?"strongSequence":"emphasisSequence",start:{...e[n][1].start},end:h},a={type:u>1?"strongText":"emphasisText",start:{...e[r][1].end},end:{...e[n][1].start}},i={type:u>1?"strong":"emphasis",start:{...s.start},end:{...o.end}},e[r][1].end={...s.start},e[n][1].start={...o.end},c=[],e[r][1].end.offset-e[r][1].start.offset&&(c=nt(c,[["enter",e[r][1],t],["exit",e[r][1],t]])),c=nt(c,[["enter",i,t],["enter",s,t],["exit",s,t],["enter",a,t]]),c=nt(c,ai(t.parser.constructs.insideSpan.null,e.slice(r+1,n),t)),c=nt(c,[["exit",a,t],["enter",o,t],["exit",o,t],["exit",i,t]]),e[n][1].end.offset-e[n][1].start.offset?(f=2,c=nt(c,[["enter",e[n][1],t],["exit",e[n][1],t]])):f=0,Ke(e,r-1,n-r+3,c),n=r+c.length-f-2;break}}for(n=-1;++n<e.length;)e[n][1].type==="attentionSequence"&&(e[n][1].type="data");return e}function Sb(e,t){const n=this.parser.constructs.attentionMarkers.null,r=this.previous,i=Sn(r);let a;return s;function s(u){return a=u,e.enter("attentionSequence"),o(u)}function o(u){if(u===a)return e.consume(u),o;const c=e.exit("attentionSequence"),f=Sn(u),d=!f||f===2&&i||n.includes(u),h=!i||i===2&&f||n.includes(r);return c._open=!!(a===42?d:d&&(i||!h)),c._close=!!(a===42?h:h&&(f||!d)),t(u)}}function Yl(e,t){e.column+=t,e.offset+=t,e._bufferIndex+=t}const Nb={name:"autolink",tokenize:Ib};function Ib(e,t,n){let r=0;return i;function i(p){return e.enter("autolink"),e.enter("autolinkMarker"),e.consume(p),e.exit("autolinkMarker"),e.enter("autolinkProtocol"),a}function a(p){return Ye(p)?(e.consume(p),s):p===64?n(p):c(p)}function s(p){return p===43||p===45||p===46||Ue(p)?(r=1,o(p)):c(p)}function o(p){return p===58?(e.consume(p),r=0,u):(p===43||p===45||p===46||Ue(p))&&r++<32?(e.consume(p),o):(r=0,c(p))}function u(p){return p===62?(e.exit("autolinkProtocol"),e.enter("autolinkMarker"),e.consume(p),e.exit("autolinkMarker"),e.exit("autolink"),t):p===null||p===32||p===60||ni(p)?n(p):(e.consume(p),u)}function c(p){return p===64?(e.consume(p),f):v1(p)?(e.consume(p),c):n(p)}function f(p){return Ue(p)?d(p):n(p)}function d(p){return p===46?(e.consume(p),r=0,f):p===62?(e.exit("autolinkProtocol").type="autolinkEmail",e.enter("autolinkMarker"),e.consume(p),e.exit("autolinkMarker"),e.exit("autolink"),t):h(p)}function h(p){if((p===45||Ue(p))&&r++<63){const m=p===45?h:d;return e.consume(p),m}return n(p)}}function ue(e,t,n,r){const i=r?r-1:Number.POSITIVE_INFINITY;let a=0;return s;function s(u){return ne(u)?(e.enter(n),o(u)):t(u)}function o(u){return ne(u)&&a++<i?(e.consume(u),o):(e.exit(n),t(u))}}const ur={partial:!0,tokenize:vb};function vb(e,t,n){return r;function r(a){return ne(a)?ue(e,i,"linePrefix")(a):i(a)}function i(a){return a===null||G(a)?t(a):n(a)}}const jl={continuation:{tokenize:Rb},exit:Ob,name:"blockQuote",tokenize:Lb};function Lb(e,t,n){const r=this;return i;function i(s){if(s===62){const o=r.containerState;return o.open||(e.enter("blockQuote",{_container:!0}),o.open=!0),e.enter("blockQuotePrefix"),e.enter("blockQuoteMarker"),e.consume(s),e.exit("blockQuoteMarker"),a}return n(s)}function a(s){return ne(s)?(e.enter("blockQuotePrefixWhitespace"),e.consume(s),e.exit("blockQuotePrefixWhitespace"),e.exit("blockQuotePrefix"),t):(e.exit("blockQuotePrefix"),t(s))}}function Rb(e,t,n){const r=this;return i;function i(s){return ne(s)?ue(e,a,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(s):a(s)}function a(s){return e.attempt(jl,t,n)(s)}}function Ob(e){e.exit("blockQuote")}const Vl={name:"characterEscape",tokenize:Db};function Db(e,t,n){return r;function r(a){return e.enter("characterEscape"),e.enter("escapeMarker"),e.consume(a),e.exit("escapeMarker"),i}function i(a){return R1(a)?(e.enter("characterEscapeValue"),e.consume(a),e.exit("characterEscapeValue"),e.exit("characterEscape"),t):n(a)}}const ql={name:"characterReference",tokenize:Pb};function Pb(e,t,n){const r=this;let i=0,a,s;return o;function o(d){return e.enter("characterReference"),e.enter("characterReferenceMarker"),e.consume(d),e.exit("characterReferenceMarker"),u}function u(d){return d===35?(e.enter("characterReferenceMarkerNumeric"),e.consume(d),e.exit("characterReferenceMarkerNumeric"),c):(e.enter("characterReferenceValue"),a=31,s=Ue,f(d))}function c(d){return d===88||d===120?(e.enter("characterReferenceMarkerHexadecimal"),e.consume(d),e.exit("characterReferenceMarkerHexadecimal"),e.enter("characterReferenceValue"),a=6,s=L1,f):(e.enter("characterReferenceValue"),a=7,s=ya,f(d))}function f(d){if(d===59&&i){const h=e.exit("characterReferenceValue");return s===Ue&&!va(r.sliceSerialize(h))?n(d):(e.enter("characterReferenceMarker"),e.consume(d),e.exit("characterReferenceMarker"),e.exit("characterReference"),t)}return s(d)&&i++<a?(e.consume(d),f):n(d)}}const Wl={partial:!0,tokenize:Bb},Gl={concrete:!0,name:"codeFenced",tokenize:Mb};function Mb(e,t,n){const r=this,i={partial:!0,tokenize:P};let a=0,s=0,o;return u;function u(A){return c(A)}function c(A){const U=r.events[r.events.length-1];return a=U&&U[1].type==="linePrefix"?U[2].sliceSerialize(U[1],!0).length:0,o=A,e.enter("codeFenced"),e.enter("codeFencedFence"),e.enter("codeFencedFenceSequence"),f(A)}function f(A){return A===o?(s++,e.consume(A),f):s<3?n(A):(e.exit("codeFencedFenceSequence"),ne(A)?ue(e,d,"whitespace")(A):d(A))}function d(A){return A===null||G(A)?(e.exit("codeFencedFence"),r.interrupt?t(A):e.check(Wl,_,D)(A)):(e.enter("codeFencedFenceInfo"),e.enter("chunkString",{contentType:"string"}),h(A))}function h(A){return A===null||G(A)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),d(A)):ne(A)?(e.exit("chunkString"),e.exit("codeFencedFenceInfo"),ue(e,p,"whitespace")(A)):A===96&&A===o?n(A):(e.consume(A),h)}function p(A){return A===null||G(A)?d(A):(e.enter("codeFencedFenceMeta"),e.enter("chunkString",{contentType:"string"}),m(A))}function m(A){return A===null||G(A)?(e.exit("chunkString"),e.exit("codeFencedFenceMeta"),d(A)):A===96&&A===o?n(A):(e.consume(A),m)}function _(A){return e.attempt(i,D,w)(A)}function w(A){return e.enter("lineEnding"),e.consume(A),e.exit("lineEnding"),y}function y(A){return a>0&&ne(A)?ue(e,S,"linePrefix",a+1)(A):S(A)}function S(A){return A===null||G(A)?e.check(Wl,_,D)(A):(e.enter("codeFlowValue"),C(A))}function C(A){return A===null||G(A)?(e.exit("codeFlowValue"),S(A)):(e.consume(A),C)}function D(A){return e.exit("codeFenced"),t(A)}function P(A,U,I){let H=0;return N;function N(K){return A.enter("lineEnding"),A.consume(K),A.exit("lineEnding"),$}function $(K){return A.enter("codeFencedFence"),ne(K)?ue(A,B,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(K):B(K)}function B(K){return K===o?(A.enter("codeFencedFenceSequence"),W(K)):I(K)}function W(K){return K===o?(H++,A.consume(K),W):H>=s?(A.exit("codeFencedFenceSequence"),ne(K)?ue(A,ie,"whitespace")(K):ie(K)):I(K)}function ie(K){return K===null||G(K)?(A.exit("codeFencedFence"),U(K)):I(K)}}}function Bb(e,t,n){const r=this;return i;function i(s){return s===null?n(s):(e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),a)}function a(s){return r.parser.lazy[r.now().line]?n(s):t(s)}}const Pa={name:"codeIndented",tokenize:Hb},Fb={partial:!0,tokenize:Ub};function Hb(e,t,n){const r=this;return i;function i(c){return e.enter("codeIndented"),ue(e,a,"linePrefix",4+1)(c)}function a(c){const f=r.events[r.events.length-1];return f&&f[1].type==="linePrefix"&&f[2].sliceSerialize(f[1],!0).length>=4?s(c):n(c)}function s(c){return c===null?u(c):G(c)?e.attempt(Fb,s,u)(c):(e.enter("codeFlowValue"),o(c))}function o(c){return c===null||G(c)?(e.exit("codeFlowValue"),s(c)):(e.consume(c),o)}function u(c){return e.exit("codeIndented"),t(c)}}function Ub(e,t,n){const r=this;return i;function i(s){return r.parser.lazy[r.now().line]?n(s):G(s)?(e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),i):ue(e,a,"linePrefix",4+1)(s)}function a(s){const o=r.events[r.events.length-1];return o&&o[1].type==="linePrefix"&&o[2].sliceSerialize(o[1],!0).length>=4?t(s):G(s)?i(s):n(s)}}const zb={name:"codeText",previous:Yb,resolve:$b,tokenize:jb};function $b(e){let t=e.length-4,n=3,r,i;if((e[n][1].type==="lineEnding"||e[n][1].type==="space")&&(e[t][1].type==="lineEnding"||e[t][1].type==="space")){for(r=n;++r<t;)if(e[r][1].type==="codeTextData"){e[n][1].type="codeTextPadding",e[t][1].type="codeTextPadding",n+=2,t-=2;break}}for(r=n-1,t++;++r<=t;)i===void 0?r!==t&&e[r][1].type!=="lineEnding"&&(i=r):(r===t||e[r][1].type==="lineEnding")&&(e[i][1].type="codeTextData",r!==i+2&&(e[i][1].end=e[r-1][1].end,e.splice(i+2,r-i-2),t-=r-i-2,r=i+2),i=void 0);return e}function Yb(e){return e!==96||this.events[this.events.length-1][1].type==="characterEscape"}function jb(e,t,n){let r=0,i,a;return s;function s(d){return e.enter("codeText"),e.enter("codeTextSequence"),o(d)}function o(d){return d===96?(e.consume(d),r++,o):(e.exit("codeTextSequence"),u(d))}function u(d){return d===null?n(d):d===32?(e.enter("space"),e.consume(d),e.exit("space"),u):d===96?(a=e.enter("codeTextSequence"),i=0,f(d)):G(d)?(e.enter("lineEnding"),e.consume(d),e.exit("lineEnding"),u):(e.enter("codeTextData"),c(d))}function c(d){return d===null||d===32||d===96||G(d)?(e.exit("codeTextData"),u(d)):(e.consume(d),c)}function f(d){return d===96?(e.consume(d),i++,f):i===r?(e.exit("codeTextSequence"),e.exit("codeText"),t(d)):(a.type="codeTextData",c(d))}}class Vb{constructor(t){this.left=t?[...t]:[],this.right=[]}get(t){if(t<0||t>=this.left.length+this.right.length)throw new RangeError("Cannot access index `"+t+"` in a splice buffer of size `"+(this.left.length+this.right.length)+"`");return t<this.left.length?this.left[t]:this.right[this.right.length-t+this.left.length-1]}get length(){return this.left.length+this.right.length}shift(){return this.setCursor(0),this.right.pop()}slice(t,n){const r=n??Number.POSITIVE_INFINITY;return r<this.left.length?this.left.slice(t,r):t>this.left.length?this.right.slice(this.right.length-r+this.left.length,this.right.length-t+this.left.length).reverse():this.left.slice(t).concat(this.right.slice(this.right.length-r+this.left.length).reverse())}splice(t,n,r){const i=n||0;this.setCursor(Math.trunc(t));const a=this.right.splice(this.right.length-i,Number.POSITIVE_INFINITY);return r&&lr(this.left,r),a.reverse()}pop(){return this.setCursor(Number.POSITIVE_INFINITY),this.left.pop()}push(t){this.setCursor(Number.POSITIVE_INFINITY),this.left.push(t)}pushMany(t){this.setCursor(Number.POSITIVE_INFINITY),lr(this.left,t)}unshift(t){this.setCursor(0),this.right.push(t)}unshiftMany(t){this.setCursor(0),lr(this.right,t.reverse())}setCursor(t){if(!(t===this.left.length||t>this.left.length&&this.right.length===0||t<0&&this.left.length===0))if(t<this.left.length){const n=this.left.splice(t,Number.POSITIVE_INFINITY);lr(this.right,n.reverse())}else{const n=this.right.splice(this.left.length+this.right.length-t,Number.POSITIVE_INFINITY);lr(this.left,n.reverse())}}}function lr(e,t){let n=0;if(t.length<1e4)e.push(...t);else for(;n<t.length;)e.push(...t.slice(n,n+1e4)),n+=1e4}function Ql(e){const t={};let n=-1,r,i,a,s,o,u,c;const f=new Vb(e);for(;++n<f.length;){for(;n in t;)n=t[n];if(r=f.get(n),n&&r[1].type==="chunkFlow"&&f.get(n-1)[1].type==="listItemPrefix"&&(u=r[1]._tokenizer.events,a=0,a<u.length&&u[a][1].type==="lineEndingBlank"&&(a+=2),a<u.length&&u[a][1].type==="content"))for(;++a<u.length&&u[a][1].type!=="content";)u[a][1].type==="chunkText"&&(u[a][1]._isInFirstContentOfListItem=!0,a++);if(r[0]==="enter")r[1].contentType&&(Object.assign(t,qb(f,n)),n=t[n],c=!0);else if(r[1]._container){for(a=n,i=void 0;a--;)if(s=f.get(a),s[1].type==="lineEnding"||s[1].type==="lineEndingBlank")s[0]==="enter"&&(i&&(f.get(i)[1].type="lineEndingBlank"),s[1].type="lineEnding",i=a);else if(!(s[1].type==="linePrefix"||s[1].type==="listItemIndent"))break;i&&(r[1].end={...f.get(i)[1].start},o=f.slice(i,n),o.unshift(r),f.splice(i,n-i+1,o))}}return Ke(e,0,Number.POSITIVE_INFINITY,f.slice(0)),!c}function qb(e,t){const n=e.get(t)[1],r=e.get(t)[2];let i=t-1;const a=[];let s=n._tokenizer;s||(s=r.parser[n.contentType](n.start),n._contentTypeTextTrailing&&(s._contentTypeTextTrailing=!0));const o=s.events,u=[],c={};let f,d,h=-1,p=n,m=0,_=0;const w=[_];for(;p;){for(;e.get(++i)[1]!==p;);a.push(i),p._tokenizer||(f=r.sliceStream(p),p.next||f.push(null),d&&s.defineSkip(p.start),p._isInFirstContentOfListItem&&(s._gfmTasklistFirstContentOfListItem=!0),s.write(f),p._isInFirstContentOfListItem&&(s._gfmTasklistFirstContentOfListItem=void 0)),d=p,p=p.next}for(p=n;++h<o.length;)o[h][0]==="exit"&&o[h-1][0]==="enter"&&o[h][1].type===o[h-1][1].type&&o[h][1].start.line!==o[h][1].end.line&&(_=h+1,w.push(_),p._tokenizer=void 0,p.previous=void 0,p=p.next);for(s.events=[],p?(p._tokenizer=void 0,p.previous=void 0):w.pop(),h=w.length;h--;){const y=o.slice(w[h],w[h+1]),S=a.pop();u.push([S,S+y.length-1]),e.splice(S,2,y)}for(u.reverse(),h=-1;++h<u.length;)c[m+u[h][0]]=m+u[h][1],m+=u[h][1]-u[h][0]-1;return c}const Wb={resolve:Qb,tokenize:Kb},Gb={partial:!0,tokenize:Xb};function Qb(e){return Ql(e),e}function Kb(e,t){let n;return r;function r(o){return e.enter("content"),n=e.enter("chunkContent",{contentType:"content"}),i(o)}function i(o){return o===null?a(o):G(o)?e.check(Gb,s,a)(o):(e.consume(o),i)}function a(o){return e.exit("chunkContent"),e.exit("content"),t(o)}function s(o){return e.consume(o),e.exit("chunkContent"),n.next=e.enter("chunkContent",{contentType:"content",previous:n}),n=n.next,i}}function Xb(e,t,n){const r=this;return i;function i(s){return e.exit("chunkContent"),e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),ue(e,a,"linePrefix")}function a(s){if(s===null||G(s))return n(s);const o=r.events[r.events.length-1];return!r.parser.constructs.disable.null.includes("codeIndented")&&o&&o[1].type==="linePrefix"&&o[2].sliceSerialize(o[1],!0).length>=4?t(s):e.interrupt(r.parser.constructs.flow,n,t)(s)}}function Kl(e,t,n,r,i,a,s,o,u){const c=u||Number.POSITIVE_INFINITY;let f=0;return d;function d(y){return y===60?(e.enter(r),e.enter(i),e.enter(a),e.consume(y),e.exit(a),h):y===null||y===32||y===41||ni(y)?n(y):(e.enter(r),e.enter(s),e.enter(o),e.enter("chunkString",{contentType:"string"}),_(y))}function h(y){return y===62?(e.enter(a),e.consume(y),e.exit(a),e.exit(i),e.exit(r),t):(e.enter(o),e.enter("chunkString",{contentType:"string"}),p(y))}function p(y){return y===62?(e.exit("chunkString"),e.exit(o),h(y)):y===null||y===60||G(y)?n(y):(e.consume(y),y===92?m:p)}function m(y){return y===60||y===62||y===92?(e.consume(y),p):p(y)}function _(y){return!f&&(y===null||y===41||ge(y))?(e.exit("chunkString"),e.exit(o),e.exit(s),e.exit(r),t(y)):f<c&&y===40?(e.consume(y),f++,_):y===41?(e.consume(y),f--,_):y===null||y===32||y===40||ni(y)?n(y):(e.consume(y),y===92?w:_)}function w(y){return y===40||y===41||y===92?(e.consume(y),_):_(y)}}function Xl(e,t,n,r,i,a){const s=this;let o=0,u;return c;function c(p){return e.enter(r),e.enter(i),e.consume(p),e.exit(i),e.enter(a),f}function f(p){return o>999||p===null||p===91||p===93&&!u||p===94&&!o&&"_hiddenFootnoteSupport"in s.parser.constructs?n(p):p===93?(e.exit(a),e.enter(i),e.consume(p),e.exit(i),e.exit(r),t):G(p)?(e.enter("lineEnding"),e.consume(p),e.exit("lineEnding"),f):(e.enter("chunkString",{contentType:"string"}),d(p))}function d(p){return p===null||p===91||p===93||G(p)||o++>999?(e.exit("chunkString"),f(p)):(e.consume(p),u||(u=!ne(p)),p===92?h:d)}function h(p){return p===91||p===92||p===93?(e.consume(p),o++,d):d(p)}}function Zl(e,t,n,r,i,a){let s;return o;function o(h){return h===34||h===39||h===40?(e.enter(r),e.enter(i),e.consume(h),e.exit(i),s=h===40?41:h,u):n(h)}function u(h){return h===s?(e.enter(i),e.consume(h),e.exit(i),e.exit(r),t):(e.enter(a),c(h))}function c(h){return h===s?(e.exit(a),u(s)):h===null?n(h):G(h)?(e.enter("lineEnding"),e.consume(h),e.exit("lineEnding"),ue(e,c,"linePrefix")):(e.enter("chunkString",{contentType:"string"}),f(h))}function f(h){return h===s||h===null||G(h)?(e.exit("chunkString"),c(h)):(e.consume(h),h===92?d:f)}function d(h){return h===s||h===92?(e.consume(h),f):f(h)}}function cr(e,t){let n;return r;function r(i){return G(i)?(e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),n=!0,r):ne(i)?ue(e,r,n?"linePrefix":"lineSuffix")(i):t(i)}}const Zb={name:"definition",tokenize:e2},Jb={partial:!0,tokenize:t2};function e2(e,t,n){const r=this;let i;return a;function a(p){return e.enter("definition"),s(p)}function s(p){return Xl.call(r,e,o,n,"definitionLabel","definitionLabelMarker","definitionLabelString")(p)}function o(p){return i=ot(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)),p===58?(e.enter("definitionMarker"),e.consume(p),e.exit("definitionMarker"),u):n(p)}function u(p){return ge(p)?cr(e,c)(p):c(p)}function c(p){return Kl(e,f,n,"definitionDestination","definitionDestinationLiteral","definitionDestinationLiteralMarker","definitionDestinationRaw","definitionDestinationString")(p)}function f(p){return e.attempt(Jb,d,d)(p)}function d(p){return ne(p)?ue(e,h,"whitespace")(p):h(p)}function h(p){return p===null||G(p)?(e.exit("definition"),r.parser.defined.push(i),t(p)):n(p)}}function t2(e,t,n){return r;function r(o){return ge(o)?cr(e,i)(o):n(o)}function i(o){return Zl(e,a,n,"definitionTitle","definitionTitleMarker","definitionTitleString")(o)}function a(o){return ne(o)?ue(e,s,"whitespace")(o):s(o)}function s(o){return o===null||G(o)?t(o):n(o)}}const n2={name:"hardBreakEscape",tokenize:r2};function r2(e,t,n){return r;function r(a){return e.enter("hardBreakEscape"),e.consume(a),i}function i(a){return G(a)?(e.exit("hardBreakEscape"),t(a)):n(a)}}const i2={name:"headingAtx",resolve:a2,tokenize:s2};function a2(e,t){let n=e.length-2,r=3,i,a;return e[r][1].type==="whitespace"&&(r+=2),n-2>r&&e[n][1].type==="whitespace"&&(n-=2),e[n][1].type==="atxHeadingSequence"&&(r===n-1||n-4>r&&e[n-2][1].type==="whitespace")&&(n-=r+1===n?2:4),n>r&&(i={type:"atxHeadingText",start:e[r][1].start,end:e[n][1].end},a={type:"chunkText",start:e[r][1].start,end:e[n][1].end,contentType:"text"},Ke(e,r,n-r+1,[["enter",i,t],["enter",a,t],["exit",a,t],["exit",i,t]])),e}function s2(e,t,n){let r=0;return i;function i(f){return e.enter("atxHeading"),a(f)}function a(f){return e.enter("atxHeadingSequence"),s(f)}function s(f){return f===35&&r++<6?(e.consume(f),s):f===null||ge(f)?(e.exit("atxHeadingSequence"),o(f)):n(f)}function o(f){return f===35?(e.enter("atxHeadingSequence"),u(f)):f===null||G(f)?(e.exit("atxHeading"),t(f)):ne(f)?ue(e,o,"whitespace")(f):(e.enter("atxHeadingText"),c(f))}function u(f){return f===35?(e.consume(f),u):(e.exit("atxHeadingSequence"),o(f))}function c(f){return f===null||f===35||ge(f)?(e.exit("atxHeadingText"),o(f)):(e.consume(f),c)}}const o2=["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","search","section","summary","table","tbody","td","tfoot","th","thead","title","tr","track","ul"],Jl=["pre","script","style","textarea"],u2={concrete:!0,name:"htmlFlow",resolveTo:d2,tokenize:f2},l2={partial:!0,tokenize:p2},c2={partial:!0,tokenize:h2};function d2(e){let t=e.length;for(;t--&&!(e[t][0]==="enter"&&e[t][1].type==="htmlFlow"););return t>1&&e[t-2][1].type==="linePrefix"&&(e[t][1].start=e[t-2][1].start,e[t+1][1].start=e[t-2][1].start,e.splice(t-2,2)),e}function f2(e,t,n){const r=this;let i,a,s,o,u;return c;function c(x){return f(x)}function f(x){return e.enter("htmlFlow"),e.enter("htmlFlowData"),e.consume(x),d}function d(x){return x===33?(e.consume(x),h):x===47?(e.consume(x),a=!0,_):x===63?(e.consume(x),i=3,r.interrupt?t:T):Ye(x)?(e.consume(x),s=String.fromCharCode(x),w):n(x)}function h(x){return x===45?(e.consume(x),i=2,p):x===91?(e.consume(x),i=5,o=0,m):Ye(x)?(e.consume(x),i=4,r.interrupt?t:T):n(x)}function p(x){return x===45?(e.consume(x),r.interrupt?t:T):n(x)}function m(x){const Ne="CDATA[";return x===Ne.charCodeAt(o++)?(e.consume(x),o===Ne.length?r.interrupt?t:B:m):n(x)}function _(x){return Ye(x)?(e.consume(x),s=String.fromCharCode(x),w):n(x)}function w(x){if(x===null||x===47||x===62||ge(x)){const Ne=x===47,he=s.toLowerCase();return!Ne&&!a&&Jl.includes(he)?(i=1,r.interrupt?t(x):B(x)):o2.includes(s.toLowerCase())?(i=6,Ne?(e.consume(x),y):r.interrupt?t(x):B(x)):(i=7,r.interrupt&&!r.parser.lazy[r.now().line]?n(x):a?S(x):C(x))}return x===45||Ue(x)?(e.consume(x),s+=String.fromCharCode(x),w):n(x)}function y(x){return x===62?(e.consume(x),r.interrupt?t:B):n(x)}function S(x){return ne(x)?(e.consume(x),S):N(x)}function C(x){return x===47?(e.consume(x),N):x===58||x===95||Ye(x)?(e.consume(x),D):ne(x)?(e.consume(x),C):N(x)}function D(x){return x===45||x===46||x===58||x===95||Ue(x)?(e.consume(x),D):P(x)}function P(x){return x===61?(e.consume(x),A):ne(x)?(e.consume(x),P):C(x)}function A(x){return x===null||x===60||x===61||x===62||x===96?n(x):x===34||x===39?(e.consume(x),u=x,U):ne(x)?(e.consume(x),A):I(x)}function U(x){return x===u?(e.consume(x),u=null,H):x===null||G(x)?n(x):(e.consume(x),U)}function I(x){return x===null||x===34||x===39||x===47||x===60||x===61||x===62||x===96||ge(x)?P(x):(e.consume(x),I)}function H(x){return x===47||x===62||ne(x)?C(x):n(x)}function N(x){return x===62?(e.consume(x),$):n(x)}function $(x){return x===null||G(x)?B(x):ne(x)?(e.consume(x),$):n(x)}function B(x){return x===45&&i===2?(e.consume(x),de):x===60&&i===1?(e.consume(x),re):x===62&&i===4?(e.consume(x),Re):x===63&&i===3?(e.consume(x),T):x===93&&i===5?(e.consume(x),Le):G(x)&&(i===6||i===7)?(e.exit("htmlFlowData"),e.check(l2,Z,W)(x)):x===null||G(x)?(e.exit("htmlFlowData"),W(x)):(e.consume(x),B)}function W(x){return e.check(c2,ie,Z)(x)}function ie(x){return e.enter("lineEnding"),e.consume(x),e.exit("lineEnding"),K}function K(x){return x===null||G(x)?W(x):(e.enter("htmlFlowData"),B(x))}function de(x){return x===45?(e.consume(x),T):B(x)}function re(x){return x===47?(e.consume(x),s="",Se):B(x)}function Se(x){if(x===62){const Ne=s.toLowerCase();return Jl.includes(Ne)?(e.consume(x),Re):B(x)}return Ye(x)&&s.length<8?(e.consume(x),s+=String.fromCharCode(x),Se):B(x)}function Le(x){return x===93?(e.consume(x),T):B(x)}function T(x){return x===62?(e.consume(x),Re):x===45&&i===2?(e.consume(x),T):B(x)}function Re(x){return x===null||G(x)?(e.exit("htmlFlowData"),Z(x)):(e.consume(x),Re)}function Z(x){return e.exit("htmlFlow"),t(x)}}function h2(e,t,n){const r=this;return i;function i(s){return G(s)?(e.enter("lineEnding"),e.consume(s),e.exit("lineEnding"),a):n(s)}function a(s){return r.parser.lazy[r.now().line]?n(s):t(s)}}function p2(e,t,n){return r;function r(i){return e.enter("lineEnding"),e.consume(i),e.exit("lineEnding"),e.attempt(ur,t,n)}}const m2={name:"htmlText",tokenize:g2};function g2(e,t,n){const r=this;let i,a,s;return o;function o(T){return e.enter("htmlText"),e.enter("htmlTextData"),e.consume(T),u}function u(T){return T===33?(e.consume(T),c):T===47?(e.consume(T),P):T===63?(e.consume(T),C):Ye(T)?(e.consume(T),I):n(T)}function c(T){return T===45?(e.consume(T),f):T===91?(e.consume(T),a=0,m):Ye(T)?(e.consume(T),S):n(T)}function f(T){return T===45?(e.consume(T),p):n(T)}function d(T){return T===null?n(T):T===45?(e.consume(T),h):G(T)?(s=d,re(T)):(e.consume(T),d)}function h(T){return T===45?(e.consume(T),p):d(T)}function p(T){return T===62?de(T):T===45?h(T):d(T)}function m(T){const Re="CDATA[";return T===Re.charCodeAt(a++)?(e.consume(T),a===Re.length?_:m):n(T)}function _(T){return T===null?n(T):T===93?(e.consume(T),w):G(T)?(s=_,re(T)):(e.consume(T),_)}function w(T){return T===93?(e.consume(T),y):_(T)}function y(T){return T===62?de(T):T===93?(e.consume(T),y):_(T)}function S(T){return T===null||T===62?de(T):G(T)?(s=S,re(T)):(e.consume(T),S)}function C(T){return T===null?n(T):T===63?(e.consume(T),D):G(T)?(s=C,re(T)):(e.consume(T),C)}function D(T){return T===62?de(T):C(T)}function P(T){return Ye(T)?(e.consume(T),A):n(T)}function A(T){return T===45||Ue(T)?(e.consume(T),A):U(T)}function U(T){return G(T)?(s=U,re(T)):ne(T)?(e.consume(T),U):de(T)}function I(T){return T===45||Ue(T)?(e.consume(T),I):T===47||T===62||ge(T)?H(T):n(T)}function H(T){return T===47?(e.consume(T),de):T===58||T===95||Ye(T)?(e.consume(T),N):G(T)?(s=H,re(T)):ne(T)?(e.consume(T),H):de(T)}function N(T){return T===45||T===46||T===58||T===95||Ue(T)?(e.consume(T),N):$(T)}function $(T){return T===61?(e.consume(T),B):G(T)?(s=$,re(T)):ne(T)?(e.consume(T),$):H(T)}function B(T){return T===null||T===60||T===61||T===62||T===96?n(T):T===34||T===39?(e.consume(T),i=T,W):G(T)?(s=B,re(T)):ne(T)?(e.consume(T),B):(e.consume(T),ie)}function W(T){return T===i?(e.consume(T),i=void 0,K):T===null?n(T):G(T)?(s=W,re(T)):(e.consume(T),W)}function ie(T){return T===null||T===34||T===39||T===60||T===61||T===96?n(T):T===47||T===62||ge(T)?H(T):(e.consume(T),ie)}function K(T){return T===47||T===62||ge(T)?H(T):n(T)}function de(T){return T===62?(e.consume(T),e.exit("htmlTextData"),e.exit("htmlText"),t):n(T)}function re(T){return e.exit("htmlTextData"),e.enter("lineEnding"),e.consume(T),e.exit("lineEnding"),Se}function Se(T){return ne(T)?ue(e,Le,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(T):Le(T)}function Le(T){return e.enter("htmlTextData"),s(T)}}const Ma={name:"labelEnd",resolveAll:_2,resolveTo:k2,tokenize:x2},b2={tokenize:y2},E2={tokenize:w2},T2={tokenize:A2};function _2(e){let t=-1;const n=[];for(;++t<e.length;){const r=e[t][1];if(n.push(e[t]),r.type==="labelImage"||r.type==="labelLink"||r.type==="labelEnd"){const i=r.type==="labelImage"?4:2;r.type="data",t+=i}}return e.length!==n.length&&Ke(e,0,e.length,n),e}function k2(e,t){let n=e.length,r=0,i,a,s,o;for(;n--;)if(i=e[n][1],a){if(i.type==="link"||i.type==="labelLink"&&i._inactive)break;e[n][0]==="enter"&&i.type==="labelLink"&&(i._inactive=!0)}else if(s){if(e[n][0]==="enter"&&(i.type==="labelImage"||i.type==="labelLink")&&!i._balanced&&(a=n,i.type!=="labelLink")){r=2;break}}else i.type==="labelEnd"&&(s=n);const u={type:e[a][1].type==="labelLink"?"link":"image",start:{...e[a][1].start},end:{...e[e.length-1][1].end}},c={type:"label",start:{...e[a][1].start},end:{...e[s][1].end}},f={type:"labelText",start:{...e[a+r+2][1].end},end:{...e[s-2][1].start}};return o=[["enter",u,t],["enter",c,t]],o=nt(o,e.slice(a+1,a+r+3)),o=nt(o,[["enter",f,t]]),o=nt(o,ai(t.parser.constructs.insideSpan.null,e.slice(a+r+4,s-3),t)),o=nt(o,[["exit",f,t],e[s-2],e[s-1],["exit",c,t]]),o=nt(o,e.slice(s+1)),o=nt(o,[["exit",u,t]]),Ke(e,a,e.length,o),e}function x2(e,t,n){const r=this;let i=r.events.length,a,s;for(;i--;)if((r.events[i][1].type==="labelImage"||r.events[i][1].type==="labelLink")&&!r.events[i][1]._balanced){a=r.events[i][1];break}return o;function o(h){return a?a._inactive?d(h):(s=r.parser.defined.includes(ot(r.sliceSerialize({start:a.end,end:r.now()}))),e.enter("labelEnd"),e.enter("labelMarker"),e.consume(h),e.exit("labelMarker"),e.exit("labelEnd"),u):n(h)}function u(h){return h===40?e.attempt(b2,f,s?f:d)(h):h===91?e.attempt(E2,f,s?c:d)(h):s?f(h):d(h)}function c(h){return e.attempt(T2,f,d)(h)}function f(h){return t(h)}function d(h){return a._balanced=!0,n(h)}}function y2(e,t,n){return r;function r(d){return e.enter("resource"),e.enter("resourceMarker"),e.consume(d),e.exit("resourceMarker"),i}function i(d){return ge(d)?cr(e,a)(d):a(d)}function a(d){return d===41?f(d):Kl(e,s,o,"resourceDestination","resourceDestinationLiteral","resourceDestinationLiteralMarker","resourceDestinationRaw","resourceDestinationString",32)(d)}function s(d){return ge(d)?cr(e,u)(d):f(d)}function o(d){return n(d)}function u(d){return d===34||d===39||d===40?Zl(e,c,n,"resourceTitle","resourceTitleMarker","resourceTitleString")(d):f(d)}function c(d){return ge(d)?cr(e,f)(d):f(d)}function f(d){return d===41?(e.enter("resourceMarker"),e.consume(d),e.exit("resourceMarker"),e.exit("resource"),t):n(d)}}function w2(e,t,n){const r=this;return i;function i(o){return Xl.call(r,e,a,s,"reference","referenceMarker","referenceString")(o)}function a(o){return r.parser.defined.includes(ot(r.sliceSerialize(r.events[r.events.length-1][1]).slice(1,-1)))?t(o):n(o)}function s(o){return n(o)}}function A2(e,t,n){return r;function r(a){return e.enter("reference"),e.enter("referenceMarker"),e.consume(a),e.exit("referenceMarker"),i}function i(a){return a===93?(e.enter("referenceMarker"),e.consume(a),e.exit("referenceMarker"),e.exit("reference"),t):n(a)}}const C2={name:"labelStartImage",resolveAll:Ma.resolveAll,tokenize:S2};function S2(e,t,n){const r=this;return i;function i(o){return e.enter("labelImage"),e.enter("labelImageMarker"),e.consume(o),e.exit("labelImageMarker"),a}function a(o){return o===91?(e.enter("labelMarker"),e.consume(o),e.exit("labelMarker"),e.exit("labelImage"),s):n(o)}function s(o){return o===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(o):t(o)}}const N2={name:"labelStartLink",resolveAll:Ma.resolveAll,tokenize:I2};function I2(e,t,n){const r=this;return i;function i(s){return e.enter("labelLink"),e.enter("labelMarker"),e.consume(s),e.exit("labelMarker"),e.exit("labelLink"),a}function a(s){return s===94&&"_hiddenFootnoteSupport"in r.parser.constructs?n(s):t(s)}}const Ba={name:"lineEnding",tokenize:v2};function v2(e,t){return n;function n(r){return e.enter("lineEnding"),e.consume(r),e.exit("lineEnding"),ue(e,t,"linePrefix")}}const si={name:"thematicBreak",tokenize:L2};function L2(e,t,n){let r=0,i;return a;function a(c){return e.enter("thematicBreak"),s(c)}function s(c){return i=c,o(c)}function o(c){return c===i?(e.enter("thematicBreakSequence"),u(c)):r>=3&&(c===null||G(c))?(e.exit("thematicBreak"),t(c)):n(c)}function u(c){return c===i?(e.consume(c),r++,u):(e.exit("thematicBreakSequence"),ne(c)?ue(e,o,"whitespace")(c):o(c))}}const Ge={continuation:{tokenize:P2},exit:B2,name:"list",tokenize:D2},R2={partial:!0,tokenize:F2},O2={partial:!0,tokenize:M2};function D2(e,t,n){const r=this,i=r.events[r.events.length-1];let a=i&&i[1].type==="linePrefix"?i[2].sliceSerialize(i[1],!0).length:0,s=0;return o;function o(p){const m=r.containerState.type||(p===42||p===43||p===45?"listUnordered":"listOrdered");if(m==="listUnordered"?!r.containerState.marker||p===r.containerState.marker:ya(p)){if(r.containerState.type||(r.containerState.type=m,e.enter(m,{_container:!0})),m==="listUnordered")return e.enter("listItemPrefix"),p===42||p===45?e.check(si,n,c)(p):c(p);if(!r.interrupt||p===49)return e.enter("listItemPrefix"),e.enter("listItemValue"),u(p)}return n(p)}function u(p){return ya(p)&&++s<10?(e.consume(p),u):(!r.interrupt||s<2)&&(r.containerState.marker?p===r.containerState.marker:p===41||p===46)?(e.exit("listItemValue"),c(p)):n(p)}function c(p){return e.enter("listItemMarker"),e.consume(p),e.exit("listItemMarker"),r.containerState.marker=r.containerState.marker||p,e.check(ur,r.interrupt?n:f,e.attempt(R2,h,d))}function f(p){return r.containerState.initialBlankLine=!0,a++,h(p)}function d(p){return ne(p)?(e.enter("listItemPrefixWhitespace"),e.consume(p),e.exit("listItemPrefixWhitespace"),h):n(p)}function h(p){return r.containerState.size=a+r.sliceSerialize(e.exit("listItemPrefix"),!0).length,t(p)}}function P2(e,t,n){const r=this;return r.containerState._closeFlow=void 0,e.check(ur,i,a);function i(o){return r.containerState.furtherBlankLines=r.containerState.furtherBlankLines||r.containerState.initialBlankLine,ue(e,t,"listItemIndent",r.containerState.size+1)(o)}function a(o){return r.containerState.furtherBlankLines||!ne(o)?(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,s(o)):(r.containerState.furtherBlankLines=void 0,r.containerState.initialBlankLine=void 0,e.attempt(O2,t,s)(o))}function s(o){return r.containerState._closeFlow=!0,r.interrupt=void 0,ue(e,e.attempt(Ge,t,n),"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(o)}}function M2(e,t,n){const r=this;return ue(e,i,"listItemIndent",r.containerState.size+1);function i(a){const s=r.events[r.events.length-1];return s&&s[1].type==="listItemIndent"&&s[2].sliceSerialize(s[1],!0).length===r.containerState.size?t(a):n(a)}}function B2(e){e.exit(this.containerState.type)}function F2(e,t,n){const r=this;return ue(e,i,"listItemPrefixWhitespace",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4+1);function i(a){const s=r.events[r.events.length-1];return!ne(a)&&s&&s[1].type==="listItemPrefixWhitespace"?t(a):n(a)}}const ec={name:"setextUnderline",resolveTo:H2,tokenize:U2};function H2(e,t){let n=e.length,r,i,a;for(;n--;)if(e[n][0]==="enter"){if(e[n][1].type==="content"){r=n;break}e[n][1].type==="paragraph"&&(i=n)}else e[n][1].type==="content"&&e.splice(n,1),!a&&e[n][1].type==="definition"&&(a=n);const s={type:"setextHeading",start:{...e[r][1].start},end:{...e[e.length-1][1].end}};return e[i][1].type="setextHeadingText",a?(e.splice(i,0,["enter",s,t]),e.splice(a+1,0,["exit",e[r][1],t]),e[r][1].end={...e[a][1].end}):e[r][1]=s,e.push(["exit",s,t]),e}function U2(e,t,n){const r=this;let i;return a;function a(c){let f=r.events.length,d;for(;f--;)if(r.events[f][1].type!=="lineEnding"&&r.events[f][1].type!=="linePrefix"&&r.events[f][1].type!=="content"){d=r.events[f][1].type==="paragraph";break}return!r.parser.lazy[r.now().line]&&(r.interrupt||d)?(e.enter("setextHeadingLine"),i=c,s(c)):n(c)}function s(c){return e.enter("setextHeadingLineSequence"),o(c)}function o(c){return c===i?(e.consume(c),o):(e.exit("setextHeadingLineSequence"),ne(c)?ue(e,u,"lineSuffix")(c):u(c))}function u(c){return c===null||G(c)?(e.exit("setextHeadingLine"),t(c)):n(c)}}const z2={tokenize:Q2,partial:!0};function $2(){return{document:{91:{name:"gfmFootnoteDefinition",tokenize:q2,continuation:{tokenize:W2},exit:G2}},text:{91:{name:"gfmFootnoteCall",tokenize:V2},93:{name:"gfmPotentialFootnoteCall",add:"after",tokenize:Y2,resolveTo:j2}}}}function Y2(e,t,n){const r=this;let i=r.events.length;const a=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let s;for(;i--;){const u=r.events[i][1];if(u.type==="labelImage"){s=u;break}if(u.type==="gfmFootnoteCall"||u.type==="labelLink"||u.type==="label"||u.type==="image"||u.type==="link")break}return o;function o(u){if(!s||!s._balanced)return n(u);const c=ot(r.sliceSerialize({start:s.end,end:r.now()}));return c.codePointAt(0)!==94||!a.includes(c.slice(1))?n(u):(e.enter("gfmFootnoteCallLabelMarker"),e.consume(u),e.exit("gfmFootnoteCallLabelMarker"),t(u))}}function j2(e,t){let n=e.length;for(;n--&&!(e[n][1].type==="labelImage"&&e[n][0]==="enter"););e[n+1][1].type="data",e[n+3][1].type="gfmFootnoteCallLabelMarker";const r={type:"gfmFootnoteCall",start:Object.assign({},e[n+3][1].start),end:Object.assign({},e[e.length-1][1].end)},i={type:"gfmFootnoteCallMarker",start:Object.assign({},e[n+3][1].end),end:Object.assign({},e[n+3][1].end)};i.end.column++,i.end.offset++,i.end._bufferIndex++;const a={type:"gfmFootnoteCallString",start:Object.assign({},i.end),end:Object.assign({},e[e.length-1][1].start)},s={type:"chunkString",contentType:"string",start:Object.assign({},a.start),end:Object.assign({},a.end)},o=[e[n+1],e[n+2],["enter",r,t],e[n+3],e[n+4],["enter",i,t],["exit",i,t],["enter",a,t],["enter",s,t],["exit",s,t],["exit",a,t],e[e.length-2],e[e.length-1],["exit",r,t]];return e.splice(n,e.length-n+1,...o),e}function V2(e,t,n){const r=this,i=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let a=0,s;return o;function o(d){return e.enter("gfmFootnoteCall"),e.enter("gfmFootnoteCallLabelMarker"),e.consume(d),e.exit("gfmFootnoteCallLabelMarker"),u}function u(d){return d!==94?n(d):(e.enter("gfmFootnoteCallMarker"),e.consume(d),e.exit("gfmFootnoteCallMarker"),e.enter("gfmFootnoteCallString"),e.enter("chunkString").contentType="string",c)}function c(d){if(a>999||d===93&&!s||d===null||d===91||ge(d))return n(d);if(d===93){e.exit("chunkString");const h=e.exit("gfmFootnoteCallString");return i.includes(ot(r.sliceSerialize(h)))?(e.enter("gfmFootnoteCallLabelMarker"),e.consume(d),e.exit("gfmFootnoteCallLabelMarker"),e.exit("gfmFootnoteCall"),t):n(d)}return ge(d)||(s=!0),a++,e.consume(d),d===92?f:c}function f(d){return d===91||d===92||d===93?(e.consume(d),a++,c):c(d)}}function q2(e,t,n){const r=this,i=r.parser.gfmFootnotes||(r.parser.gfmFootnotes=[]);let a,s=0,o;return u;function u(m){return e.enter("gfmFootnoteDefinition")._container=!0,e.enter("gfmFootnoteDefinitionLabel"),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(m),e.exit("gfmFootnoteDefinitionLabelMarker"),c}function c(m){return m===94?(e.enter("gfmFootnoteDefinitionMarker"),e.consume(m),e.exit("gfmFootnoteDefinitionMarker"),e.enter("gfmFootnoteDefinitionLabelString"),e.enter("chunkString").contentType="string",f):n(m)}function f(m){if(s>999||m===93&&!o||m===null||m===91||ge(m))return n(m);if(m===93){e.exit("chunkString");const _=e.exit("gfmFootnoteDefinitionLabelString");return a=ot(r.sliceSerialize(_)),e.enter("gfmFootnoteDefinitionLabelMarker"),e.consume(m),e.exit("gfmFootnoteDefinitionLabelMarker"),e.exit("gfmFootnoteDefinitionLabel"),h}return ge(m)||(o=!0),s++,e.consume(m),m===92?d:f}function d(m){return m===91||m===92||m===93?(e.consume(m),s++,f):f(m)}function h(m){return m===58?(e.enter("definitionMarker"),e.consume(m),e.exit("definitionMarker"),i.includes(a)||i.push(a),ue(e,p,"gfmFootnoteDefinitionWhitespace")):n(m)}function p(m){return t(m)}}function W2(e,t,n){return e.check(ur,t,e.attempt(z2,t,n))}function G2(e){e.exit("gfmFootnoteDefinition")}function Q2(e,t,n){const r=this;return ue(e,i,"gfmFootnoteDefinitionIndent",4+1);function i(a){const s=r.events[r.events.length-1];return s&&s[1].type==="gfmFootnoteDefinitionIndent"&&s[2].sliceSerialize(s[1],!0).length===4?t(a):n(a)}}function K2(e){let n=(e||{}).singleTilde;const r={name:"strikethrough",tokenize:a,resolveAll:i};return n==null&&(n=!0),{text:{126:r},insideSpan:{null:[r]},attentionMarkers:{null:[126]}};function i(s,o){let u=-1;for(;++u<s.length;)if(s[u][0]==="enter"&&s[u][1].type==="strikethroughSequenceTemporary"&&s[u][1]._close){let c=u;for(;c--;)if(s[c][0]==="exit"&&s[c][1].type==="strikethroughSequenceTemporary"&&s[c][1]._open&&s[u][1].end.offset-s[u][1].start.offset===s[c][1].end.offset-s[c][1].start.offset){s[u][1].type="strikethroughSequence",s[c][1].type="strikethroughSequence";const f={type:"strikethrough",start:Object.assign({},s[c][1].start),end:Object.assign({},s[u][1].end)},d={type:"strikethroughText",start:Object.assign({},s[c][1].end),end:Object.assign({},s[u][1].start)},h=[["enter",f,o],["enter",s[c][1],o],["exit",s[c][1],o],["enter",d,o]],p=o.parser.constructs.insideSpan.null;p&&Ke(h,h.length,0,ai(p,s.slice(c+1,u),o)),Ke(h,h.length,0,[["exit",d,o],["enter",s[u][1],o],["exit",s[u][1],o],["exit",f,o]]),Ke(s,c-1,u-c+3,h),u=c+h.length-2;break}}for(u=-1;++u<s.length;)s[u][1].type==="strikethroughSequenceTemporary"&&(s[u][1].type="data");return s}function a(s,o,u){const c=this.previous,f=this.events;let d=0;return h;function h(m){return c===126&&f[f.length-1][1].type!=="characterEscape"?u(m):(s.enter("strikethroughSequenceTemporary"),p(m))}function p(m){const _=Sn(c);if(m===126)return d>1?u(m):(s.consume(m),d++,p);if(d<2&&!n)return u(m);const w=s.exit("strikethroughSequenceTemporary"),y=Sn(m);return w._open=!y||y===2&&!!_,w._close=!_||_===2&&!!y,o(m)}}}class X2{constructor(){this.map=[]}add(t,n,r){Z2(this,t,n,r)}consume(t){if(this.map.sort(function(a,s){return a[0]-s[0]}),this.map.length===0)return;let n=this.map.length;const r=[];for(;n>0;)n-=1,r.push(t.slice(this.map[n][0]+this.map[n][1]),this.map[n][2]),t.length=this.map[n][0];r.push(t.slice()),t.length=0;let i=r.pop();for(;i;){for(const a of i)t.push(a);i=r.pop()}this.map.length=0}}function Z2(e,t,n,r){let i=0;if(!(n===0&&r.length===0)){for(;i<e.map.length;){if(e.map[i][0]===t){e.map[i][1]+=n,e.map[i][2].push(...r);return}i+=1}e.map.push([t,n,r])}}function J2(e,t){let n=!1;const r=[];for(;t<e.length;){const i=e[t];if(n){if(i[0]==="enter")i[1].type==="tableContent"&&r.push(e[t+1][1].type==="tableDelimiterMarker"?"left":"none");else if(i[1].type==="tableContent"){if(e[t-1][1].type==="tableDelimiterMarker"){const a=r.length-1;r[a]=r[a]==="left"?"center":"right"}}else if(i[1].type==="tableDelimiterRow")break}else i[0]==="enter"&&i[1].type==="tableDelimiterRow"&&(n=!0);t+=1}return r}function eE(){return{flow:{null:{name:"table",tokenize:tE,resolveAll:nE}}}}function tE(e,t,n){const r=this;let i=0,a=0,s;return o;function o(N){let $=r.events.length-1;for(;$>-1;){const ie=r.events[$][1].type;if(ie==="lineEnding"||ie==="linePrefix")$--;else break}const B=$>-1?r.events[$][1].type:null,W=B==="tableHead"||B==="tableRow"?A:u;return W===A&&r.parser.lazy[r.now().line]?n(N):W(N)}function u(N){return e.enter("tableHead"),e.enter("tableRow"),c(N)}function c(N){return N===124||(s=!0,a+=1),f(N)}function f(N){return N===null?n(N):G(N)?a>1?(a=0,r.interrupt=!0,e.exit("tableRow"),e.enter("lineEnding"),e.consume(N),e.exit("lineEnding"),p):n(N):ne(N)?ue(e,f,"whitespace")(N):(a+=1,s&&(s=!1,i+=1),N===124?(e.enter("tableCellDivider"),e.consume(N),e.exit("tableCellDivider"),s=!0,f):(e.enter("data"),d(N)))}function d(N){return N===null||N===124||ge(N)?(e.exit("data"),f(N)):(e.consume(N),N===92?h:d)}function h(N){return N===92||N===124?(e.consume(N),d):d(N)}function p(N){return r.interrupt=!1,r.parser.lazy[r.now().line]?n(N):(e.enter("tableDelimiterRow"),s=!1,ne(N)?ue(e,m,"linePrefix",r.parser.constructs.disable.null.includes("codeIndented")?void 0:4)(N):m(N))}function m(N){return N===45||N===58?w(N):N===124?(s=!0,e.enter("tableCellDivider"),e.consume(N),e.exit("tableCellDivider"),_):P(N)}function _(N){return ne(N)?ue(e,w,"whitespace")(N):w(N)}function w(N){return N===58?(a+=1,s=!0,e.enter("tableDelimiterMarker"),e.consume(N),e.exit("tableDelimiterMarker"),y):N===45?(a+=1,y(N)):N===null||G(N)?D(N):P(N)}function y(N){return N===45?(e.enter("tableDelimiterFiller"),S(N)):P(N)}function S(N){return N===45?(e.consume(N),S):N===58?(s=!0,e.exit("tableDelimiterFiller"),e.enter("tableDelimiterMarker"),e.consume(N),e.exit("tableDelimiterMarker"),C):(e.exit("tableDelimiterFiller"),C(N))}function C(N){return ne(N)?ue(e,D,"whitespace")(N):D(N)}function D(N){return N===124?m(N):N===null||G(N)?!s||i!==a?P(N):(e.exit("tableDelimiterRow"),e.exit("tableHead"),t(N)):P(N)}function P(N){return n(N)}function A(N){return e.enter("tableRow"),U(N)}function U(N){return N===124?(e.enter("tableCellDivider"),e.consume(N),e.exit("tableCellDivider"),U):N===null||G(N)?(e.exit("tableRow"),t(N)):ne(N)?ue(e,U,"whitespace")(N):(e.enter("data"),I(N))}function I(N){return N===null||N===124||ge(N)?(e.exit("data"),U(N)):(e.consume(N),N===92?H:I)}function H(N){return N===92||N===124?(e.consume(N),I):I(N)}}function nE(e,t){let n=-1,r=!0,i=0,a=[0,0,0,0],s=[0,0,0,0],o=!1,u=0,c,f,d;const h=new X2;for(;++n<e.length;){const p=e[n],m=p[1];p[0]==="enter"?m.type==="tableHead"?(o=!1,u!==0&&(tc(h,t,u,c,f),f=void 0,u=0),c={type:"table",start:Object.assign({},m.start),end:Object.assign({},m.end)},h.add(n,0,[["enter",c,t]])):m.type==="tableRow"||m.type==="tableDelimiterRow"?(r=!0,d=void 0,a=[0,0,0,0],s=[0,n+1,0,0],o&&(o=!1,f={type:"tableBody",start:Object.assign({},m.start),end:Object.assign({},m.end)},h.add(n,0,[["enter",f,t]])),i=m.type==="tableDelimiterRow"?2:f?3:1):i&&(m.type==="data"||m.type==="tableDelimiterMarker"||m.type==="tableDelimiterFiller")?(r=!1,s[2]===0&&(a[1]!==0&&(s[0]=s[1],d=oi(h,t,a,i,void 0,d),a=[0,0,0,0]),s[2]=n)):m.type==="tableCellDivider"&&(r?r=!1:(a[1]!==0&&(s[0]=s[1],d=oi(h,t,a,i,void 0,d)),a=s,s=[a[1],n,0,0])):m.type==="tableHead"?(o=!0,u=n):m.type==="tableRow"||m.type==="tableDelimiterRow"?(u=n,a[1]!==0?(s[0]=s[1],d=oi(h,t,a,i,n,d)):s[1]!==0&&(d=oi(h,t,s,i,n,d)),i=0):i&&(m.type==="data"||m.type==="tableDelimiterMarker"||m.type==="tableDelimiterFiller")&&(s[3]=n)}for(u!==0&&tc(h,t,u,c,f),h.consume(t.events),n=-1;++n<t.events.length;){const p=t.events[n];p[0]==="enter"&&p[1].type==="table"&&(p[1]._align=J2(t.events,n))}return e}function oi(e,t,n,r,i,a){const s=r===1?"tableHeader":r===2?"tableDelimiter":"tableData",o="tableContent";n[0]!==0&&(a.end=Object.assign({},In(t.events,n[0])),e.add(n[0],0,[["exit",a,t]]));const u=In(t.events,n[1]);if(a={type:s,start:Object.assign({},u),end:Object.assign({},u)},e.add(n[1],0,[["enter",a,t]]),n[2]!==0){const c=In(t.events,n[2]),f=In(t.events,n[3]),d={type:o,start:Object.assign({},c),end:Object.assign({},f)};if(e.add(n[2],0,[["enter",d,t]]),r!==2){const h=t.events[n[2]],p=t.events[n[3]];if(h[1].end=Object.assign({},p[1].end),h[1].type="chunkText",h[1].contentType="text",n[3]>n[2]+1){const m=n[2]+1,_=n[3]-n[2]-1;e.add(m,_,[])}}e.add(n[3]+1,0,[["exit",d,t]])}return i!==void 0&&(a.end=Object.assign({},In(t.events,i)),e.add(i,0,[["exit",a,t]]),a=void 0),a}function tc(e,t,n,r,i){const a=[],s=In(t.events,n);i&&(i.end=Object.assign({},s),a.push(["exit",i,t])),r.end=Object.assign({},s),a.push(["exit",r,t]),e.add(n+1,0,a)}function In(e,t){const n=e[t],r=n[0]==="enter"?"start":"end";return n[1][r]}const rE={name:"tasklistCheck",tokenize:aE};function iE(){return{text:{91:rE}}}function aE(e,t,n){const r=this;return i;function i(u){return r.previous!==null||!r._gfmTasklistFirstContentOfListItem?n(u):(e.enter("taskListCheck"),e.enter("taskListCheckMarker"),e.consume(u),e.exit("taskListCheckMarker"),a)}function a(u){return ge(u)?(e.enter("taskListCheckValueUnchecked"),e.consume(u),e.exit("taskListCheckValueUnchecked"),s):u===88||u===120?(e.enter("taskListCheckValueChecked"),e.consume(u),e.exit("taskListCheckValueChecked"),s):n(u)}function s(u){return u===93?(e.enter("taskListCheckMarker"),e.consume(u),e.exit("taskListCheckMarker"),e.exit("taskListCheck"),o):n(u)}function o(u){return G(u)?t(u):ne(u)?e.check({tokenize:sE},t,n)(u):n(u)}}function sE(e,t,n){return ue(e,r,"whitespace");function r(i){return i===null?n(i):t(i)}}function oE(e){return Dl([bb(),$2(),K2(e),eE(),iE()])}const uE={};function lE(e){const t=this,n=e||uE,r=t.data(),i=r.micromarkExtensions||(r.micromarkExtensions=[]),a=r.fromMarkdownExtensions||(r.fromMarkdownExtensions=[]),s=r.toMarkdownExtensions||(r.toMarkdownExtensions=[]);i.push(oE(n)),a.push(db()),s.push(fb(n))}var cE=Object.defineProperty,dE=Object.defineProperties,fE=Object.getOwnPropertyDescriptors,nc=Object.getOwnPropertySymbols,hE=Object.prototype.hasOwnProperty,pE=Object.prototype.propertyIsEnumerable,rc=(e,t,n)=>t in e?cE(e,t,{enumerable:!0,configurable:!0,writable:!0,value:n}):e[t]=n,ic=(e,t)=>{for(var n in t||(t={}))hE.call(t,n)&&rc(e,n,t[n]);if(nc)for(var n of nc(t))pE.call(t,n)&&rc(e,n,t[n]);return e},ac=(e,t)=>dE(e,fE(t)),mE=/(\*\*)([^*]*\*?)$/,gE=/(__)([^_]*?)$/,bE=/(\*\*\*)([^*]*?)$/,EE=/(\*)([^*]*?)$/,TE=/(_)([^_]*?)$/,_E=/(`)([^`]*?)$/,kE=/(~~)([^~]*?)$/,rn=/^[\s_~*`]*$/,sc=/^[\s]*[-*+][\s]+$/,xE=/[\p{L}\p{N}_]/u,yE=/^```[^`\n]*```?$/,wE=/^\*{4,}$/,AE=/(__)([^_]+)_$/,CE=/(~~)([^~]+)~$/,oc=/~~/g,Mt=e=>{if(!e)return!1;let t=e.charCodeAt(0);return t>=48&&t<=57||t>=65&&t<=90||t>=97&&t<=122||t===95?!0:xE.test(e)},dr=(e,t)=>{let n=!1;for(let r=0;r<t;r+=1)e[r]==="`"&&e[r+1]==="`"&&e[r+2]==="`"&&(n=!n,r+=2);return n},SE=(e,t)=>{let n=1;for(let r=t-1;r>=0;r-=1)if(e[r]==="]")n+=1;else if(e[r]==="["&&(n-=1,n===0))return r;return-1},uc=(e,t)=>{let n=1;for(let r=t+1;r<e.length;r+=1)if(e[r]==="[")n+=1;else if(e[r]==="]"&&(n-=1,n===0))return r;return-1},ui=(e,t)=>{let n=!1,r=!1;for(let i=0;i<e.length&&i<t;i+=1){if(e[i]==="\\"&&e[i+1]==="$"){i+=1;continue}e[i]==="$"&&(e[i+1]==="$"?(r=!r,i+=1,n=!1):r||(n=!n))}return n||r},NE=(e,t)=>{for(let n=t;n<e.length;n+=1){if(e[n]===")")return!0;if(e[n]===`
|
|
18
|
+
`)return!1}return!1},lc=(e,t)=>{for(let n=t-1;n>=0;n-=1){if(e[n]===")")return!1;if(e[n]==="(")return n>0&&e[n-1]==="]"?NE(e,t):!1;if(e[n]===`
|
|
19
|
+
`)return!1}return!1},IE=(e,t)=>{for(let n=t-1;n>=0;n-=1){if(e[n]===">")return!1;if(e[n]==="<"){let r=n+1<e.length?e[n+1]:"";return r>="a"&&r<="z"||r>="A"&&r<="Z"||r==="/"}if(e[n]===`
|
|
20
|
+
`)return!1}return!1},Fa=(e,t,n)=>{let r=0;for(let u=t-1;u>=0;u-=1)if(e[u]===`
|
|
20
21
|
`){r=u+1;break}let i=e.length;for(let u=t;u<e.length;u+=1)if(e[u]===`
|
|
21
|
-
`){i=u;break}let a=e.substring(r,i),s=0,o=!1;for(let u of a)if(u===n)s+=1;else if(u!==" "&&u!==" "){o=!0;break}return s>=3&&!o},
|
|
22
|
-
`)
|
|
23
|
-
`),i=r
|
|
24
|
-
`)
|
|
25
|
-
`),
|
|
26
|
-
`)
|
|
27
|
-
|
|
28
|
-
`)
|
|
22
|
+
`){i=u;break}let a=e.substring(r,i),s=0,o=!1;for(let u of a)if(u===n)s+=1;else if(u!==" "&&u!==" "){o=!0;break}return s>=3&&!o},vE=/^(\s*(?:[-*+]|\d+[.)]) +)>(=?\s*[$]?\d)/gm,LE=e=>!e||typeof e!="string"||!e.includes(">")?e:e.replace(vE,(t,n,r,i)=>dr(e,i)?t:`${n}\\>${r}`),RE=(e,t,n,r)=>n==="\\"||e.includes("$")&&ui(e,t)?!0:n!=="*"&&r==="*"?(t<e.length-2?e[t+2]:"")!=="*":!!(n==="*"||n&&r&&Mt(n)&&Mt(r)||(!n||n===" "||n===" "||n===`
|
|
23
|
+
`)&&(!r||r===" "||r===" "||r===`
|
|
24
|
+
`)),cc=e=>{let t=0,n=!1,r=e.length;for(let i=0;i<r;i+=1){if(e[i]==="`"&&i+2<r&&e[i+1]==="`"&&e[i+2]==="`"){n=!n,i+=2;continue}if(n||e[i]!=="*")continue;let a=i>0?e[i-1]:"",s=i<r-1?e[i+1]:"";RE(e,i,a,s)||(t+=1)}return t},OE=(e,t,n,r)=>!!(n==="\\"||e.includes("$")&&ui(e,t)||lc(e,t)||IE(e,t)||n==="_"||r==="_"||n&&r&&Mt(n)&&Mt(r)),DE=e=>{let t=0,n=!1,r=e.length;for(let i=0;i<r;i+=1){if(e[i]==="`"&&i+2<r&&e[i+1]==="`"&&e[i+2]==="`"){n=!n,i+=2;continue}if(n||e[i]!=="_")continue;let a=i>0?e[i-1]:"",s=i<r-1?e[i+1]:"";OE(e,i,a,s)||(t+=1)}return t},PE=e=>{let t=0,n=0,r=!1;for(let i=0;i<e.length;i+=1){if(e[i]==="`"&&i+2<e.length&&e[i+1]==="`"&&e[i+2]==="`"){n>=3&&(t+=Math.floor(n/3)),n=0,r=!r,i+=2;continue}r||(e[i]==="*"?n+=1:(n>=3&&(t+=Math.floor(n/3)),n=0))}return n>=3&&(t+=Math.floor(n/3)),t},Ha=e=>{let t=0,n=!1;for(let r=0;r<e.length;r+=1){if(e[r]==="`"&&r+2<e.length&&e[r+1]==="`"&&e[r+2]==="`"){n=!n,r+=2;continue}n||e[r]==="*"&&r+1<e.length&&e[r+1]==="*"&&(t+=1,r+=1)}return t},dc=e=>{let t=0,n=!1;for(let r=0;r<e.length;r+=1){if(e[r]==="`"&&r+2<e.length&&e[r+1]==="`"&&e[r+2]==="`"){n=!n,r+=2;continue}n||e[r]==="_"&&r+1<e.length&&e[r+1]==="_"&&(t+=1,r+=1)}return t},ME=(e,t,n)=>{if(!t||rn.test(t))return!0;let r=e.substring(0,n).lastIndexOf(`
|
|
25
|
+
`),i=r===-1?0:r+1,a=e.substring(i,n);return sc.test(a)&&t.includes(`
|
|
26
|
+
`)?!0:Fa(e,n,"*")},BE=e=>{let t=e.match(mE);if(!t)return e;let n=t[2],r=e.lastIndexOf(t[1]);return dr(e,r)||ME(e,n,r)?e:Ha(e)%2===1?n.endsWith("*")?`${e}*`:`${e}**`:e},FE=(e,t,n)=>{if(!t||rn.test(t))return!0;let r=e.substring(0,n).lastIndexOf(`
|
|
27
|
+
`),i=r===-1?0:r+1,a=e.substring(i,n);return sc.test(a)&&t.includes(`
|
|
28
|
+
`)?!0:Fa(e,n,"_")},HE=e=>{let t=e.match(gE);if(!t){let i=e.match(AE);if(i){let a=e.lastIndexOf(i[1]);if(!dr(e,a)&&dc(e)%2===1)return`${e}_`}return e}let n=t[2],r=e.lastIndexOf(t[1]);return dr(e,r)||FE(e,n,r)?e:dc(e)%2===1?`${e}__`:e},UE=e=>{let t=!1;for(let n=0;n<e.length;n+=1){if(e[n]==="`"&&n+2<e.length&&e[n+1]==="`"&&e[n+2]==="`"){t=!t,n+=2;continue}if(!t&&e[n]==="*"&&e[n-1]!=="*"&&e[n+1]!=="*"&&e[n-1]!=="\\"&&!ui(e,n)){let r=n>0?e[n-1]:"",i=n<e.length-1?e[n+1]:"";if((!r||r===" "||r===" "||r===`
|
|
29
|
+
`)&&(!i||i===" "||i===" "||i===`
|
|
30
|
+
`)||r&&i&&Mt(r)&&Mt(i))continue;return n}}return-1},zE=e=>{if(!e.match(EE))return e;let t=UE(e);if(t===-1)return e;let n=e.substring(t+1);return!n||rn.test(n)?e:cc(e)%2===1?`${e}*`:e},fc=e=>{let t=!1;for(let n=0;n<e.length;n+=1){if(e[n]==="`"&&n+2<e.length&&e[n+1]==="`"&&e[n+2]==="`"){t=!t,n+=2;continue}if(!t&&e[n]==="_"&&e[n-1]!=="_"&&e[n+1]!=="_"&&e[n-1]!=="\\"&&!ui(e,n)&&!lc(e,n)){let r=n>0?e[n-1]:"",i=n<e.length-1?e[n+1]:"";if(r&&i&&Mt(r)&&Mt(i))continue;return n}}return-1},$E=e=>{let t=e.length;for(;t>0&&e[t-1]===`
|
|
31
|
+
`;)t-=1;if(t<e.length){let n=e.slice(0,t),r=e.slice(t);return`${n}_${r}`}return`${e}_`},YE=e=>{if(!e.endsWith("**"))return null;let t=e.slice(0,-2);if(Ha(t)%2!==1)return null;let n=t.indexOf("**"),r=fc(t);return n!==-1&&r!==-1&&n<r?`${t}_**`:null},jE=e=>{if(!e.match(TE))return e;let t=fc(e);if(t===-1)return e;let n=e.substring(t+1);if(!n||rn.test(n))return e;if(DE(e)%2===1){let r=YE(e);return r!==null?r:$E(e)}return e},VE=e=>{let t=Ha(e),n=cc(e);return t%2===0&&n%2===0},qE=(e,t,n)=>!t||rn.test(t)||dr(e,n)?!0:Fa(e,n,"*"),WE=e=>{if(wE.test(e))return e;let t=e.match(bE);if(!t)return e;let n=t[2],r=e.lastIndexOf(t[1]);return qE(e,n,r)?e:PE(e)%2===1?VE(e)?e:`${e}***`:e},fr=(e,t)=>{let n=!1,r=!1;for(let i=0;i<t;i+=1){if(e.substring(i,i+3)==="```"){r=!r,i+=2;continue}!r&&e[i]==="`"&&(n=!n)}return n||r},GE=(e,t)=>{let n=e.substring(t,t+3)==="```",r=t>0&&e.substring(t-1,t+2)==="```",i=t>1&&e.substring(t-2,t+1)==="```";return n||r||i},QE=e=>{let t=0;for(let n=0;n<e.length;n+=1)e[n]==="`"&&!GE(e,n)&&(t+=1);return t},KE=/<[a-zA-Z/][^>]*$/,XE=e=>{let t=e.match(KE);return!t||t.index===void 0||fr(e,t.index)?e:e.substring(0,t.index).trimEnd()},ZE=e=>!e.match(yE)||e.includes(`
|
|
32
|
+
`)?null:e.endsWith("``")&&!e.endsWith("```")?`${e}\``:e,JE=e=>(e.match(/```/g)||[]).length%2===1,e3=e=>{let t=ZE(e);if(t!==null)return t;let n=e.match(_E);if(n&&!JE(e)){let r=n[2];if(!r||rn.test(r))return e;if(QE(e)%2===1)return`${e}\``}return e},t3=(e,t)=>t>=2&&e.substring(t-2,t+1)==="```"||t>=1&&e.substring(t-1,t+2)==="```"||t<=e.length-3&&e.substring(t,t+3)==="```",n3=e=>{let t=0,n=!1;for(let r=0;r<e.length-1;r+=1)e[r]==="`"&&!t3(e,r)&&(n=!n),!n&&e[r]==="$"&&e[r+1]==="$"&&(t+=1,r+=1);return t},r3=e=>{let t=e.indexOf("$$");return t!==-1&&e.indexOf(`
|
|
29
33
|
`,t)!==-1&&!e.endsWith(`
|
|
30
34
|
`)?`${e}
|
|
31
|
-
$$`:`${e}$$`},
|
|
32
|
-
`);if(t===-1)return e;let n=e.substring(t+1),r=e.substring(0,t),i=n.trim();if(
|
|
33
|
-
`).at(-1);if(a&&a.trim().length>0)return`${e}`}if(
|
|
34
|
-
`).at(-1);if(a&&a.trim().length>0)return`${e}`}return e},PE=e=>{let t=e.match(W2);if(t){let n=t[2];if(!n||Zt.test(n))return e;if((e.match(Jl)||[]).length%2===1)return`${e}~~`}else if(e.match(Z2)&&(e.match(Jl)||[]).length%2===1)return`${e}~`;return e},La=e=>e!==!1,Xe={SETEXT_HEADINGS:0,LINKS:10,BOLD_ITALIC:20,BOLD:30,ITALIC_DOUBLE_UNDERSCORE:40,ITALIC_SINGLE_ASTERISK:41,ITALIC_SINGLE_UNDERSCORE:42,INLINE_CODE:50,STRIKETHROUGH:60,KATEX:70,DEFAULT:100},ME=[{handler:{name:"setextHeadings",handle:DE,priority:Xe.SETEXT_HEADINGS},optionKey:"setextHeadings"},{handler:{name:"links",handle:ac,priority:Xe.LINKS},optionKey:"links",earlyReturn:e=>e.endsWith("](streamdown:incomplete-link)")},{handler:{name:"boldItalic",handle:EE,priority:Xe.BOLD_ITALIC},optionKey:"boldItalic"},{handler:{name:"bold",handle:uE,priority:Xe.BOLD},optionKey:"bold"},{handler:{name:"italicDoubleUnderscore",handle:cE,priority:Xe.ITALIC_DOUBLE_UNDERSCORE},optionKey:"italic"},{handler:{name:"italicSingleAsterisk",handle:fE,priority:Xe.ITALIC_SINGLE_ASTERISK},optionKey:"italic"},{handler:{name:"italicSingleUnderscore",handle:mE,priority:Xe.ITALIC_SINGLE_UNDERSCORE},optionKey:"italic"},{handler:{name:"inlineCode",handle:yE,priority:Xe.INLINE_CODE},optionKey:"inlineCode"},{handler:{name:"strikethrough",handle:PE,priority:Xe.STRIKETHROUGH},optionKey:"strikethrough"},{handler:{name:"katex",handle:SE,priority:Xe.KATEX},optionKey:"katex"}],BE=e=>{var t;let n=(t=e?.linkMode)!=null?t:"protocol";return ME.filter(({handler:r,optionKey:i})=>r.name==="links"?La(e?.links)||La(e?.images):La(e?.[i])).map(({handler:r,earlyReturn:i})=>r.name==="links"?{handler:Xl(Kl({},r),{handle:a=>ac(a,n)}),earlyReturn:n==="protocol"?i:void 0}:{handler:r,earlyReturn:i})},FE=(e,t)=>{var n;if(!e||typeof e!="string")return e;let r=e.endsWith(" ")&&!e.endsWith(" ")?e.slice(0,-1):e,i=BE(t),a=((n=t?.handlers)!=null?n:[]).map(o=>{var u;return{handler:Xl(Kl({},o),{priority:(u=o.priority)!=null?u:Xe.DEFAULT}),earlyReturn:void 0}}),s=[...i,...a].sort((o,u)=>{var c,f;return((c=o.handler.priority)!=null?c:Xe.DEFAULT)-((f=u.handler.priority)!=null?f:Xe.DEFAULT)});for(let{handler:o,earlyReturn:u}of s)if(r=o.handle(r),u!=null&&u(r))return r;return r},HE=FE;function sc(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(n=sc(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function UE(){for(var e,t,n=0,r="",i=arguments.length;n<i;n++)(e=arguments[n])&&(t=sc(e))&&(r&&(r+=" "),r+=t);return r}const zE=(e,t)=>{const n=new Array(e.length+t.length);for(let r=0;r<e.length;r++)n[r]=e[r];for(let r=0;r<t.length;r++)n[e.length+r]=t[r];return n},$E=(e,t)=>({classGroupId:e,validator:t}),oc=(e=new Map,t=null,n)=>({nextPart:e,validators:t,classGroupId:n}),ni="-",uc=[],YE="arbitrary..",jE=e=>{const t=qE(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:s=>{if(s.startsWith("[")&&s.endsWith("]"))return VE(s);const o=s.split(ni),u=o[0]===""&&o.length>1?1:0;return lc(o,u,t)},getConflictingClassGroupIds:(s,o)=>{if(o){const u=r[s],c=n[s];return u?c?zE(c,u):u:c||uc}return n[s]||uc}}},lc=(e,t,n)=>{if(e.length-t===0)return n.classGroupId;const i=e[t],a=n.nextPart.get(i);if(a){const c=lc(e,t+1,a);if(c)return c}const s=n.validators;if(s===null)return;const o=t===0?e.join(ni):e.slice(t).join(ni),u=s.length;for(let c=0;c<u;c++){const f=s[c];if(f.validator(o))return f.classGroupId}},VE=e=>e.slice(1,-1).indexOf(":")===-1?void 0:(()=>{const t=e.slice(1,-1),n=t.indexOf(":"),r=t.slice(0,n);return r?YE+r:void 0})(),qE=e=>{const{theme:t,classGroups:n}=e;return WE(n,t)},WE=(e,t)=>{const n=oc();for(const r in e){const i=e[r];Ra(i,n,r,t)}return n},Ra=(e,t,n,r)=>{const i=e.length;for(let a=0;a<i;a++){const s=e[a];GE(s,t,n,r)}},GE=(e,t,n,r)=>{if(typeof e=="string"){QE(e,t,n);return}if(typeof e=="function"){KE(e,t,n,r);return}XE(e,t,n,r)},QE=(e,t,n)=>{const r=e===""?t:cc(t,e);r.classGroupId=n},KE=(e,t,n,r)=>{if(ZE(e)){Ra(e(r),t,n,r);return}t.validators===null&&(t.validators=[]),t.validators.push($E(n,e))},XE=(e,t,n,r)=>{const i=Object.entries(e),a=i.length;for(let s=0;s<a;s++){const[o,u]=i[s];Ra(u,cc(t,o),n,r)}},cc=(e,t)=>{let n=e;const r=t.split(ni),i=r.length;for(let a=0;a<i;a++){const s=r[a];let o=n.nextPart.get(s);o||(o=oc(),n.nextPart.set(s,o)),n=o}return n},ZE=e=>"isThemeGetter"in e&&e.isThemeGetter===!0,JE=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=Object.create(null),r=Object.create(null);const i=(a,s)=>{n[a]=s,t++,t>e&&(t=0,r=n,n=Object.create(null))};return{get(a){let s=n[a];if(s!==void 0)return s;if((s=r[a])!==void 0)return i(a,s),s},set(a,s){a in n?n[a]=s:i(a,s)}}},Oa="!",dc=":",e3=[],fc=(e,t,n,r,i)=>({modifiers:e,hasImportantModifier:t,baseClassName:n,maybePostfixModifierPosition:r,isExternal:i}),t3=e=>{const{prefix:t,experimentalParseClassName:n}=e;let r=i=>{const a=[];let s=0,o=0,u=0,c;const f=i.length;for(let _=0;_<f;_++){const A=i[_];if(s===0&&o===0){if(A===dc){a.push(i.slice(u,_)),u=_+1;continue}if(A==="/"){c=_;continue}}A==="["?s++:A==="]"?s--:A==="("?o++:A===")"&&o--}const d=a.length===0?i:i.slice(u);let h=d,p=!1;d.endsWith(Oa)?(h=d.slice(0,-1),p=!0):d.startsWith(Oa)&&(h=d.slice(1),p=!0);const m=c&&c>u?c-u:void 0;return fc(a,p,h,m)};if(t){const i=t+dc,a=r;r=s=>s.startsWith(i)?a(s.slice(i.length)):fc(e3,!1,s,void 0,!0)}if(n){const i=r;r=a=>n({className:a,parseClassName:i})}return r},n3=e=>{const t=new Map;return e.orderSensitiveModifiers.forEach((n,r)=>{t.set(n,1e6+r)}),n=>{const r=[];let i=[];for(let a=0;a<n.length;a++){const s=n[a],o=s[0]==="[",u=t.has(s);o||u?(i.length>0&&(i.sort(),r.push(...i),i=[]),r.push(s)):i.push(s)}return i.length>0&&(i.sort(),r.push(...i)),r}},r3=e=>({cache:JE(e.cacheSize),parseClassName:t3(e),sortModifiers:n3(e),...jE(e)}),i3=/\s+/,a3=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i,sortModifiers:a}=t,s=[],o=e.trim().split(i3);let u="";for(let c=o.length-1;c>=0;c-=1){const f=o[c],{isExternal:d,modifiers:h,hasImportantModifier:p,baseClassName:m,maybePostfixModifierPosition:_}=n(f);if(d){u=f+(u.length>0?" "+u:u);continue}let A=!!_,y=r(A?m.substring(0,_):m);if(!y){if(!A){u=f+(u.length>0?" "+u:u);continue}if(y=r(m),!y){u=f+(u.length>0?" "+u:u);continue}A=!1}const I=h.length===0?"":h.length===1?h[0]:a(h).join(":"),S=p?I+Oa:I,D=S+y;if(s.indexOf(D)>-1)continue;s.push(D);const P=i(y,A);for(let w=0;w<P.length;++w){const z=P[w];s.push(S+z)}u=f+(u.length>0?" "+u:u)}return u},s3=(...e)=>{let t=0,n,r,i="";for(;t<e.length;)(n=e[t++])&&(r=hc(n))&&(i&&(i+=" "),i+=r);return i},hc=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=hc(e[r]))&&(n&&(n+=" "),n+=t);return n},o3=(e,...t)=>{let n,r,i,a;const s=u=>{const c=t.reduce((f,d)=>d(f),e());return n=r3(c),r=n.cache.get,i=n.cache.set,a=o,o(u)},o=u=>{const c=r(u);if(c)return c;const f=a3(u,n);return i(u,f),f};return a=s,(...u)=>a(s3(...u))},u3=[],Se=e=>{const t=n=>n[e]||u3;return t.isThemeGetter=!0,t},pc=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,mc=/^\((?:(\w[\w-]*):)?(.+)\)$/i,l3=/^\d+\/\d+$/,c3=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,d3=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,f3=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,h3=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,p3=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,yn=e=>l3.test(e),ne=e=>!!e&&!Number.isNaN(Number(e)),Pt=e=>!!e&&Number.isInteger(Number(e)),Da=e=>e.endsWith("%")&&ne(e.slice(0,-1)),kt=e=>c3.test(e),m3=()=>!0,g3=e=>d3.test(e)&&!f3.test(e),gc=()=>!1,b3=e=>h3.test(e),E3=e=>p3.test(e),T3=e=>!j(e)&&!V(e),_3=e=>wn(e,kc,gc),j=e=>pc.test(e),Jt=e=>wn(e,xc,g3),Pa=e=>wn(e,A3,ne),bc=e=>wn(e,Tc,gc),k3=e=>wn(e,_c,E3),ri=e=>wn(e,yc,b3),V=e=>mc.test(e),rr=e=>An(e,xc),x3=e=>An(e,C3),Ec=e=>An(e,Tc),y3=e=>An(e,kc),w3=e=>An(e,_c),ii=e=>An(e,yc,!0),wn=(e,t,n)=>{const r=pc.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},An=(e,t,n=!1)=>{const r=mc.exec(e);return r?r[1]?t(r[1]):n:!1},Tc=e=>e==="position"||e==="percentage",_c=e=>e==="image"||e==="url",kc=e=>e==="length"||e==="size"||e==="bg-size",xc=e=>e==="length",A3=e=>e==="number",C3=e=>e==="family-name",yc=e=>e==="shadow",S3=o3(()=>{const e=Se("color"),t=Se("font"),n=Se("text"),r=Se("font-weight"),i=Se("tracking"),a=Se("leading"),s=Se("breakpoint"),o=Se("container"),u=Se("spacing"),c=Se("radius"),f=Se("shadow"),d=Se("inset-shadow"),h=Se("text-shadow"),p=Se("drop-shadow"),m=Se("blur"),_=Se("perspective"),A=Se("aspect"),y=Se("ease"),I=Se("animate"),S=()=>["auto","avoid","all","avoid-page","page","left","right","column"],D=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],P=()=>[...D(),V,j],w=()=>["auto","hidden","clip","visible","scroll"],z=()=>["auto","contain","none"],L=()=>[V,j,u],H=()=>[yn,"full","auto",...L()],C=()=>[Pt,"none","subgrid",V,j],$=()=>["auto",{span:["full",Pt,V,j]},Pt,V,j],B=()=>[Pt,"auto",V,j],Q=()=>["auto","min","max","fr",V,j],ae=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],X=()=>["start","end","center","stretch","center-safe","end-safe"],Z=()=>["auto",...L()],ee=()=>[yn,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...L()],q=()=>[e,V,j],Ye=()=>[...D(),Ec,bc,{position:[V,j]}],x=()=>["no-repeat",{repeat:["","x","y","space","round"]}],Oe=()=>["auto","cover","contain",y3,_3,{size:[V,j]}],He=()=>[Da,rr,Jt],k=()=>["","none","full",c,V,j],me=()=>["",ne,rr,Jt],je=()=>["solid","dashed","dotted","double"],ye=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],Ee=()=>[ne,Da,Ec,bc],Je=()=>["","none",m,V,j],et=()=>["none",ne,V,j],tt=()=>["none",ne,V,j],Et=()=>[ne,V,j],Ft=()=>[yn,"full",...L()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[kt],breakpoint:[kt],color:[m3],container:[kt],"drop-shadow":[kt],ease:["in","out","in-out"],font:[T3],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[kt],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[kt],shadow:[kt],spacing:["px",ne],text:[kt],"text-shadow":[kt],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",yn,j,V,A]}],container:["container"],columns:[{columns:[ne,j,V,o]}],"break-after":[{"break-after":S()}],"break-before":[{"break-before":S()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:P()}],overflow:[{overflow:w()}],"overflow-x":[{"overflow-x":w()}],"overflow-y":[{"overflow-y":w()}],overscroll:[{overscroll:z()}],"overscroll-x":[{"overscroll-x":z()}],"overscroll-y":[{"overscroll-y":z()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:H()}],"inset-x":[{"inset-x":H()}],"inset-y":[{"inset-y":H()}],start:[{start:H()}],end:[{end:H()}],top:[{top:H()}],right:[{right:H()}],bottom:[{bottom:H()}],left:[{left:H()}],visibility:["visible","invisible","collapse"],z:[{z:[Pt,"auto",V,j]}],basis:[{basis:[yn,"full","auto",o,...L()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[ne,yn,"auto","initial","none",j]}],grow:[{grow:["",ne,V,j]}],shrink:[{shrink:["",ne,V,j]}],order:[{order:[Pt,"first","last","none",V,j]}],"grid-cols":[{"grid-cols":C()}],"col-start-end":[{col:$()}],"col-start":[{"col-start":B()}],"col-end":[{"col-end":B()}],"grid-rows":[{"grid-rows":C()}],"row-start-end":[{row:$()}],"row-start":[{"row-start":B()}],"row-end":[{"row-end":B()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":Q()}],"auto-rows":[{"auto-rows":Q()}],gap:[{gap:L()}],"gap-x":[{"gap-x":L()}],"gap-y":[{"gap-y":L()}],"justify-content":[{justify:[...ae(),"normal"]}],"justify-items":[{"justify-items":[...X(),"normal"]}],"justify-self":[{"justify-self":["auto",...X()]}],"align-content":[{content:["normal",...ae()]}],"align-items":[{items:[...X(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...X(),{baseline:["","last"]}]}],"place-content":[{"place-content":ae()}],"place-items":[{"place-items":[...X(),"baseline"]}],"place-self":[{"place-self":["auto",...X()]}],p:[{p:L()}],px:[{px:L()}],py:[{py:L()}],ps:[{ps:L()}],pe:[{pe:L()}],pt:[{pt:L()}],pr:[{pr:L()}],pb:[{pb:L()}],pl:[{pl:L()}],m:[{m:Z()}],mx:[{mx:Z()}],my:[{my:Z()}],ms:[{ms:Z()}],me:[{me:Z()}],mt:[{mt:Z()}],mr:[{mr:Z()}],mb:[{mb:Z()}],ml:[{ml:Z()}],"space-x":[{"space-x":L()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":L()}],"space-y-reverse":["space-y-reverse"],size:[{size:ee()}],w:[{w:[o,"screen",...ee()]}],"min-w":[{"min-w":[o,"screen","none",...ee()]}],"max-w":[{"max-w":[o,"screen","none","prose",{screen:[s]},...ee()]}],h:[{h:["screen","lh",...ee()]}],"min-h":[{"min-h":["screen","lh","none",...ee()]}],"max-h":[{"max-h":["screen","lh",...ee()]}],"font-size":[{text:["base",n,rr,Jt]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[r,V,Pa]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",Da,j]}],"font-family":[{font:[x3,j,t]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[i,V,j]}],"line-clamp":[{"line-clamp":[ne,"none",V,Pa]}],leading:[{leading:[a,...L()]}],"list-image":[{"list-image":["none",V,j]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",V,j]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:q()}],"text-color":[{text:q()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...je(),"wavy"]}],"text-decoration-thickness":[{decoration:[ne,"from-font","auto",V,Jt]}],"text-decoration-color":[{decoration:q()}],"underline-offset":[{"underline-offset":[ne,"auto",V,j]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:L()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",V,j]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",V,j]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:Ye()}],"bg-repeat":[{bg:x()}],"bg-size":[{bg:Oe()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},Pt,V,j],radial:["",V,j],conic:[Pt,V,j]},w3,k3]}],"bg-color":[{bg:q()}],"gradient-from-pos":[{from:He()}],"gradient-via-pos":[{via:He()}],"gradient-to-pos":[{to:He()}],"gradient-from":[{from:q()}],"gradient-via":[{via:q()}],"gradient-to":[{to:q()}],rounded:[{rounded:k()}],"rounded-s":[{"rounded-s":k()}],"rounded-e":[{"rounded-e":k()}],"rounded-t":[{"rounded-t":k()}],"rounded-r":[{"rounded-r":k()}],"rounded-b":[{"rounded-b":k()}],"rounded-l":[{"rounded-l":k()}],"rounded-ss":[{"rounded-ss":k()}],"rounded-se":[{"rounded-se":k()}],"rounded-ee":[{"rounded-ee":k()}],"rounded-es":[{"rounded-es":k()}],"rounded-tl":[{"rounded-tl":k()}],"rounded-tr":[{"rounded-tr":k()}],"rounded-br":[{"rounded-br":k()}],"rounded-bl":[{"rounded-bl":k()}],"border-w":[{border:me()}],"border-w-x":[{"border-x":me()}],"border-w-y":[{"border-y":me()}],"border-w-s":[{"border-s":me()}],"border-w-e":[{"border-e":me()}],"border-w-t":[{"border-t":me()}],"border-w-r":[{"border-r":me()}],"border-w-b":[{"border-b":me()}],"border-w-l":[{"border-l":me()}],"divide-x":[{"divide-x":me()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":me()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...je(),"hidden","none"]}],"divide-style":[{divide:[...je(),"hidden","none"]}],"border-color":[{border:q()}],"border-color-x":[{"border-x":q()}],"border-color-y":[{"border-y":q()}],"border-color-s":[{"border-s":q()}],"border-color-e":[{"border-e":q()}],"border-color-t":[{"border-t":q()}],"border-color-r":[{"border-r":q()}],"border-color-b":[{"border-b":q()}],"border-color-l":[{"border-l":q()}],"divide-color":[{divide:q()}],"outline-style":[{outline:[...je(),"none","hidden"]}],"outline-offset":[{"outline-offset":[ne,V,j]}],"outline-w":[{outline:["",ne,rr,Jt]}],"outline-color":[{outline:q()}],shadow:[{shadow:["","none",f,ii,ri]}],"shadow-color":[{shadow:q()}],"inset-shadow":[{"inset-shadow":["none",d,ii,ri]}],"inset-shadow-color":[{"inset-shadow":q()}],"ring-w":[{ring:me()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:q()}],"ring-offset-w":[{"ring-offset":[ne,Jt]}],"ring-offset-color":[{"ring-offset":q()}],"inset-ring-w":[{"inset-ring":me()}],"inset-ring-color":[{"inset-ring":q()}],"text-shadow":[{"text-shadow":["none",h,ii,ri]}],"text-shadow-color":[{"text-shadow":q()}],opacity:[{opacity:[ne,V,j]}],"mix-blend":[{"mix-blend":[...ye(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":ye()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[ne]}],"mask-image-linear-from-pos":[{"mask-linear-from":Ee()}],"mask-image-linear-to-pos":[{"mask-linear-to":Ee()}],"mask-image-linear-from-color":[{"mask-linear-from":q()}],"mask-image-linear-to-color":[{"mask-linear-to":q()}],"mask-image-t-from-pos":[{"mask-t-from":Ee()}],"mask-image-t-to-pos":[{"mask-t-to":Ee()}],"mask-image-t-from-color":[{"mask-t-from":q()}],"mask-image-t-to-color":[{"mask-t-to":q()}],"mask-image-r-from-pos":[{"mask-r-from":Ee()}],"mask-image-r-to-pos":[{"mask-r-to":Ee()}],"mask-image-r-from-color":[{"mask-r-from":q()}],"mask-image-r-to-color":[{"mask-r-to":q()}],"mask-image-b-from-pos":[{"mask-b-from":Ee()}],"mask-image-b-to-pos":[{"mask-b-to":Ee()}],"mask-image-b-from-color":[{"mask-b-from":q()}],"mask-image-b-to-color":[{"mask-b-to":q()}],"mask-image-l-from-pos":[{"mask-l-from":Ee()}],"mask-image-l-to-pos":[{"mask-l-to":Ee()}],"mask-image-l-from-color":[{"mask-l-from":q()}],"mask-image-l-to-color":[{"mask-l-to":q()}],"mask-image-x-from-pos":[{"mask-x-from":Ee()}],"mask-image-x-to-pos":[{"mask-x-to":Ee()}],"mask-image-x-from-color":[{"mask-x-from":q()}],"mask-image-x-to-color":[{"mask-x-to":q()}],"mask-image-y-from-pos":[{"mask-y-from":Ee()}],"mask-image-y-to-pos":[{"mask-y-to":Ee()}],"mask-image-y-from-color":[{"mask-y-from":q()}],"mask-image-y-to-color":[{"mask-y-to":q()}],"mask-image-radial":[{"mask-radial":[V,j]}],"mask-image-radial-from-pos":[{"mask-radial-from":Ee()}],"mask-image-radial-to-pos":[{"mask-radial-to":Ee()}],"mask-image-radial-from-color":[{"mask-radial-from":q()}],"mask-image-radial-to-color":[{"mask-radial-to":q()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":D()}],"mask-image-conic-pos":[{"mask-conic":[ne]}],"mask-image-conic-from-pos":[{"mask-conic-from":Ee()}],"mask-image-conic-to-pos":[{"mask-conic-to":Ee()}],"mask-image-conic-from-color":[{"mask-conic-from":q()}],"mask-image-conic-to-color":[{"mask-conic-to":q()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:Ye()}],"mask-repeat":[{mask:x()}],"mask-size":[{mask:Oe()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",V,j]}],filter:[{filter:["","none",V,j]}],blur:[{blur:Je()}],brightness:[{brightness:[ne,V,j]}],contrast:[{contrast:[ne,V,j]}],"drop-shadow":[{"drop-shadow":["","none",p,ii,ri]}],"drop-shadow-color":[{"drop-shadow":q()}],grayscale:[{grayscale:["",ne,V,j]}],"hue-rotate":[{"hue-rotate":[ne,V,j]}],invert:[{invert:["",ne,V,j]}],saturate:[{saturate:[ne,V,j]}],sepia:[{sepia:["",ne,V,j]}],"backdrop-filter":[{"backdrop-filter":["","none",V,j]}],"backdrop-blur":[{"backdrop-blur":Je()}],"backdrop-brightness":[{"backdrop-brightness":[ne,V,j]}],"backdrop-contrast":[{"backdrop-contrast":[ne,V,j]}],"backdrop-grayscale":[{"backdrop-grayscale":["",ne,V,j]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[ne,V,j]}],"backdrop-invert":[{"backdrop-invert":["",ne,V,j]}],"backdrop-opacity":[{"backdrop-opacity":[ne,V,j]}],"backdrop-saturate":[{"backdrop-saturate":[ne,V,j]}],"backdrop-sepia":[{"backdrop-sepia":["",ne,V,j]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":L()}],"border-spacing-x":[{"border-spacing-x":L()}],"border-spacing-y":[{"border-spacing-y":L()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",V,j]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[ne,"initial",V,j]}],ease:[{ease:["linear","initial",y,V,j]}],delay:[{delay:[ne,V,j]}],animate:[{animate:["none",I,V,j]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[_,V,j]}],"perspective-origin":[{"perspective-origin":P()}],rotate:[{rotate:et()}],"rotate-x":[{"rotate-x":et()}],"rotate-y":[{"rotate-y":et()}],"rotate-z":[{"rotate-z":et()}],scale:[{scale:tt()}],"scale-x":[{"scale-x":tt()}],"scale-y":[{"scale-y":tt()}],"scale-z":[{"scale-z":tt()}],"scale-3d":["scale-3d"],skew:[{skew:Et()}],"skew-x":[{"skew-x":Et()}],"skew-y":[{"skew-y":Et()}],transform:[{transform:[V,j,"","none","gpu","cpu"]}],"transform-origin":[{origin:P()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:Ft()}],"translate-x":[{"translate-x":Ft()}],"translate-y":[{"translate-y":Ft()}],"translate-z":[{"translate-z":Ft()}],"translate-none":["translate-none"],accent:[{accent:q()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:q()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",V,j]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":L()}],"scroll-mx":[{"scroll-mx":L()}],"scroll-my":[{"scroll-my":L()}],"scroll-ms":[{"scroll-ms":L()}],"scroll-me":[{"scroll-me":L()}],"scroll-mt":[{"scroll-mt":L()}],"scroll-mr":[{"scroll-mr":L()}],"scroll-mb":[{"scroll-mb":L()}],"scroll-ml":[{"scroll-ml":L()}],"scroll-p":[{"scroll-p":L()}],"scroll-px":[{"scroll-px":L()}],"scroll-py":[{"scroll-py":L()}],"scroll-ps":[{"scroll-ps":L()}],"scroll-pe":[{"scroll-pe":L()}],"scroll-pt":[{"scroll-pt":L()}],"scroll-pr":[{"scroll-pr":L()}],"scroll-pb":[{"scroll-pb":L()}],"scroll-pl":[{"scroll-pl":L()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",V,j]}],fill:[{fill:["none",...q()]}],"stroke-w":[{stroke:[ne,rr,Jt,Pa]}],stroke:[{stroke:["none",...q()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}}),I3=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,N3=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,v3={};function wc(e,t){return((t||v3).jsx?N3:I3).test(e)}const L3=/[ \t\n\f\r]/g;function R3(e){return typeof e=="object"?e.type==="text"?Ac(e.value):!1:Ac(e)}function Ac(e){return e.replace(L3,"")===""}var ai=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Cc(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Ma={},Sc=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,O3=/\n/g,D3=/^\s*/,P3=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,M3=/^:\s*/,B3=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,F3=/^[;\s]*/,H3=/^\s+|\s+$/g,U3=`
|
|
35
|
-
`,Ic="/",Nc="*",en="",z3="comment",$3="declaration",Y3=function(e,t){if(typeof e!="string")throw new TypeError("First argument must be a string");if(!e)return[];t=t||{};var n=1,r=1;function i(m){var _=m.match(O3);_&&(n+=_.length);var A=m.lastIndexOf(U3);r=~A?m.length-A:r+m.length}function a(){var m={line:n,column:r};return function(_){return _.position=new s(m),c(),_}}function s(m){this.start=m,this.end={line:n,column:r},this.source=t.source}s.prototype.content=e;function o(m){var _=new Error(t.source+":"+n+":"+r+": "+m);if(_.reason=m,_.filename=t.source,_.line=n,_.column=r,_.source=e,!t.silent)throw _}function u(m){var _=m.exec(e);if(_){var A=_[0];return i(A),e=e.slice(A.length),_}}function c(){u(D3)}function f(m){var _;for(m=m||[];_=d();)_!==!1&&m.push(_);return m}function d(){var m=a();if(!(Ic!=e.charAt(0)||Nc!=e.charAt(1))){for(var _=2;en!=e.charAt(_)&&(Nc!=e.charAt(_)||Ic!=e.charAt(_+1));)++_;if(_+=2,en===e.charAt(_-1))return o("End of comment missing");var A=e.slice(2,_-2);return r+=2,i(A),e=e.slice(_),r+=2,m({type:z3,comment:A})}}function h(){var m=a(),_=u(P3);if(_){if(d(),!u(M3))return o("property missing ':'");var A=u(B3),y=m({type:$3,property:vc(_[0].replace(Sc,en)),value:A?vc(A[0].replace(Sc,en)):en});return u(F3),y}}function p(){var m=[];f(m);for(var _;_=h();)_!==!1&&(m.push(_),f(m));return m}return c(),p()};function vc(e){return e?e.replace(H3,en):en}var j3=ai&&ai.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Ma,"__esModule",{value:!0}),Ma.default=q3;const V3=j3(Y3);function q3(e,t){let n=null;if(!e||typeof e!="string")return n;const r=(0,V3.default)(e),i=typeof t=="function";return r.forEach(a=>{if(a.type!=="declaration")return;const{property:s,value:o}=a;i?t(s,o,a):o&&(n=n||{},n[s]=o)}),n}var si={};Object.defineProperty(si,"__esModule",{value:!0}),si.camelCase=void 0;var W3=/^--[a-zA-Z0-9_-]+$/,G3=/-([a-z])/g,Q3=/^[^-]+$/,K3=/^-(webkit|moz|ms|o|khtml)-/,X3=/^-(ms)-/,Z3=function(e){return!e||Q3.test(e)||W3.test(e)},J3=function(e,t){return t.toUpperCase()},Lc=function(e,t){return"".concat(t,"-")},eT=function(e,t){return t===void 0&&(t={}),Z3(e)?e:(e=e.toLowerCase(),t.reactCompat?e=e.replace(X3,Lc):e=e.replace(K3,Lc),e.replace(G3,J3))};si.camelCase=eT;var tT=ai&&ai.__importDefault||function(e){return e&&e.__esModule?e:{default:e}},nT=tT(Ma),rT=si;function Ba(e,t){var n={};return!e||typeof e!="string"||(0,nT.default)(e,function(r,i){r&&i&&(n[(0,rT.camelCase)(r,t)]=i)}),n}Ba.default=Ba;var iT=Ba;const aT=Cc(iT);function ir(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?Rc(e.position):"start"in e||"end"in e?Rc(e):"line"in e||"column"in e?Fa(e):""}function Fa(e){return Oc(e&&e.line)+":"+Oc(e&&e.column)}function Rc(e){return Fa(e&&e.start)+"-"+Fa(e&&e.end)}function Oc(e){return e&&typeof e=="number"?e:1}class Fe extends Error{constructor(t,n,r){super(),typeof n=="string"&&(r=n,n=void 0);let i="",a={},s=!1;if(n&&("line"in n&&"column"in n?a={place:n}:"start"in n&&"end"in n?a={place:n}:"type"in n?a={ancestors:[n],place:n.position}:a={...n}),typeof t=="string"?i=t:!a.cause&&t&&(s=!0,i=t.message,a.cause=t),!a.ruleId&&!a.source&&typeof r=="string"){const u=r.indexOf(":");u===-1?a.ruleId=r:(a.source=r.slice(0,u),a.ruleId=r.slice(u+1))}if(!a.place&&a.ancestors&&a.ancestors){const u=a.ancestors[a.ancestors.length-1];u&&(a.place=u.position)}const o=a.place&&"start"in a.place?a.place.start:a.place;this.ancestors=a.ancestors||void 0,this.cause=a.cause||void 0,this.column=o?o.column:void 0,this.fatal=void 0,this.file="",this.message=i,this.line=o?o.line:void 0,this.name=ir(a.place)||"1:1",this.place=a.place||void 0,this.reason=this.message,this.ruleId=a.ruleId||void 0,this.source=a.source||void 0,this.stack=s&&a.cause&&typeof a.cause.stack=="string"?a.cause.stack:"",this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}}Fe.prototype.file="",Fe.prototype.name="",Fe.prototype.reason="",Fe.prototype.message="",Fe.prototype.stack="",Fe.prototype.column=void 0,Fe.prototype.line=void 0,Fe.prototype.ancestors=void 0,Fe.prototype.cause=void 0,Fe.prototype.fatal=void 0,Fe.prototype.place=void 0,Fe.prototype.ruleId=void 0,Fe.prototype.source=void 0;const Ha={}.hasOwnProperty,sT=new Map,oT=/[A-Z]/g,uT=new Set(["table","tbody","thead","tfoot","tr"]),lT=new Set(["td","th"]),Dc="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function cT(e,t){if(!t||t.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");const n=t.filePath||void 0;let r;if(t.development){if(typeof t.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");r=ET(n,t.jsxDEV)}else{if(typeof t.jsx!="function")throw new TypeError("Expected `jsx` in production options");if(typeof t.jsxs!="function")throw new TypeError("Expected `jsxs` in production options");r=bT(n,t.jsx,t.jsxs)}const i={Fragment:t.Fragment,ancestors:[],components:t.components||{},create:r,elementAttributeNameCase:t.elementAttributeNameCase||"react",evaluater:t.createEvaluater?t.createEvaluater():void 0,filePath:n,ignoreInvalidStyle:t.ignoreInvalidStyle||!1,passKeys:t.passKeys!==!1,passNode:t.passNode||!1,schema:t.space==="svg"?It:Un,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},a=Pc(i,e,void 0);return a&&typeof a!="string"?a:i.create(e,i.Fragment,{children:a||void 0},void 0)}function Pc(e,t,n){if(t.type==="element")return dT(e,t,n);if(t.type==="mdxFlowExpression"||t.type==="mdxTextExpression")return fT(e,t);if(t.type==="mdxJsxFlowElement"||t.type==="mdxJsxTextElement")return pT(e,t,n);if(t.type==="mdxjsEsm")return hT(e,t);if(t.type==="root")return mT(e,t,n);if(t.type==="text")return gT(e,t)}function dT(e,t,n){const r=e.schema;let i=r;t.tagName.toLowerCase()==="svg"&&r.space==="html"&&(i=It,e.schema=i),e.ancestors.push(t);const a=Bc(e,t.tagName,!1),s=TT(e,t);let o=za(e,t);return uT.has(t.tagName)&&(o=o.filter(function(u){return typeof u=="string"?!R3(u):!0})),Mc(e,s,a,t),Ua(s,o),e.ancestors.pop(),e.schema=r,e.create(t,a,s,n)}function fT(e,t){if(t.data&&t.data.estree&&e.evaluater){const r=t.data.estree.body[0];return e.evaluater.evaluateExpression(r.expression)}ar(e,t.position)}function hT(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);ar(e,t.position)}function pT(e,t,n){const r=e.schema;let i=r;t.name==="svg"&&r.space==="html"&&(i=It,e.schema=i),e.ancestors.push(t);const a=t.name===null?e.Fragment:Bc(e,t.name,!0),s=_T(e,t),o=za(e,t);return Mc(e,s,a,t),Ua(s,o),e.ancestors.pop(),e.schema=r,e.create(t,a,s,n)}function mT(e,t,n){const r={};return Ua(r,za(e,t)),e.create(t,e.Fragment,r,n)}function gT(e,t){return t.value}function Mc(e,t,n,r){typeof n!="string"&&n!==e.Fragment&&e.passNode&&(t.node=r)}function Ua(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function bT(e,t,n){return r;function r(i,a,s,o){const c=Array.isArray(s.children)?n:t;return o?c(a,s,o):c(a,s)}}function ET(e,t){return n;function n(r,i,a,s){const o=Array.isArray(a.children),u=pt(r);return t(i,a,s,o,{columnNumber:u?u.column-1:void 0,fileName:e,lineNumber:u?u.line:void 0},void 0)}}function TT(e,t){const n={};let r,i;for(i in t.properties)if(i!=="children"&&Ha.call(t.properties,i)){const a=kT(e,i,t.properties[i]);if(a){const[s,o]=a;e.tableCellAlignToStyle&&s==="align"&&typeof o=="string"&&lT.has(t.tagName)?r=o:n[s]=o}}if(r){const a=n.style||(n.style={});a[e.stylePropertyNameCase==="css"?"text-align":"textAlign"]=r}return n}function _T(e,t){const n={};for(const r of t.attributes)if(r.type==="mdxJsxExpressionAttribute")if(r.data&&r.data.estree&&e.evaluater){const o=r.data.estree.body[0].expression.properties[0];Object.assign(n,e.evaluater.evaluateExpression(o.argument))}else ar(e,t.position);else{const i=r.name;let a;if(r.value&&typeof r.value=="object")if(r.value.data&&r.value.data.estree&&e.evaluater){const o=r.value.data.estree.body[0];a=e.evaluater.evaluateExpression(o.expression)}else ar(e,t.position);else a=r.value===null?!0:r.value;n[i]=a}return n}function za(e,t){const n=[];let r=-1;const i=e.passKeys?new Map:sT;for(;++r<t.children.length;){const a=t.children[r];let s;if(e.passKeys){const u=a.type==="element"?a.tagName:a.type==="mdxJsxFlowElement"||a.type==="mdxJsxTextElement"?a.name:void 0;if(u){const c=i.get(u)||0;s=u+"-"+c,i.set(u,c+1)}}const o=Pc(e,a,s);o!==void 0&&n.push(o)}return n}function kT(e,t,n){const r=Mr(e.schema,t);if(!(n==null||typeof n=="number"&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?Yo(n):qo(n)),r.property==="style"){let i=typeof n=="object"?n:xT(e,String(n));return e.stylePropertyNameCase==="css"&&(i=yT(i)),["style",i]}return[e.elementAttributeNameCase==="react"&&r.space?Nf[r.property]||r.property:r.attribute,n]}}function xT(e,t){try{return aT(t,{reactCompat:!0})}catch(n){if(e.ignoreInvalidStyle)return{};const r=n,i=new Fe("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:r,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw i.file=e.filePath||void 0,i.url=Dc+"#cannot-parse-style-attribute",i}}function Bc(e,t,n){let r;if(!n)r={type:"Literal",value:t};else if(t.includes(".")){const i=t.split(".");let a=-1,s;for(;++a<i.length;){const o=wc(i[a])?{type:"Identifier",name:i[a]}:{type:"Literal",value:i[a]};s=s?{type:"MemberExpression",object:s,property:o,computed:!!(a&&o.type==="Literal"),optional:!1}:o}r=s}else r=wc(t)&&!/^[a-z]/.test(t)?{type:"Identifier",name:t}:{type:"Literal",value:t};if(r.type==="Literal"){const i=r.value;return Ha.call(e.components,i)?e.components[i]:i}if(e.evaluater)return e.evaluater.evaluateExpression(r);ar(e)}function ar(e,t){const n=new Fe("Cannot handle MDX estrees without `createEvaluater`",{ancestors:e.ancestors,place:t,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw n.file=e.filePath||void 0,n.url=Dc+"#cannot-handle-mdx-estrees-without-createevaluater",n}function yT(e){const t={};let n;for(n in e)Ha.call(e,n)&&(t[wT(n)]=e[n]);return t}function wT(e){let t=e.replace(oT,AT);return t.slice(0,3)==="ms-"&&(t="-"+t),t}function AT(e){return"-"+e.toLowerCase()}const CT={tokenize:ST};function ST(e){const t=e.attempt(this.parser.constructs.contentInitial,r,i);let n;return t;function r(o){if(o===null){e.consume(o);return}return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),oe(e,t,"linePrefix")}function i(o){return e.enter("paragraph"),a(o)}function a(o){const u=e.enter("chunkText",{contentType:"text",previous:n});return n&&(n.next=u),n=u,s(o)}function s(o){if(o===null){e.exit("chunkText"),e.exit("paragraph"),e.consume(o);return}return G(o)?(e.consume(o),e.exit("chunkText"),a):(e.consume(o),s)}}const IT={tokenize:NT},Fc={tokenize:vT};function NT(e){const t=this,n=[];let r=0,i,a,s;return o;function o(S){if(r<n.length){const D=n[r];return t.containerState=D[1],e.attempt(D[0].continuation,u,c)(S)}return c(S)}function u(S){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,i&&I();const D=t.events.length;let P=D,w;for(;P--;)if(t.events[P][0]==="exit"&&t.events[P][1].type==="chunkFlow"){w=t.events[P][1].end;break}y(r);let z=D;for(;z<t.events.length;)t.events[z][1].end={...w},z++;return Ke(t.events,P+1,0,t.events.slice(D)),t.events.length=z,c(S)}return o(S)}function c(S){if(r===n.length){if(!i)return h(S);if(i.currentConstruct&&i.currentConstruct.concrete)return m(S);t.interrupt=!!(i.currentConstruct&&!i._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(Fc,f,d)(S)}function f(S){return i&&I(),y(r),h(S)}function d(S){return t.parser.lazy[t.now().line]=r!==n.length,s=t.now().offset,m(S)}function h(S){return t.containerState={},e.attempt(Fc,p,m)(S)}function p(S){return r++,n.push([t.currentConstruct,t.containerState]),h(S)}function m(S){if(S===null){i&&I(),y(0),e.consume(S);return}return i=i||t.parser.flow(t.now()),e.enter("chunkFlow",{_tokenizer:i,contentType:"flow",previous:a}),_(S)}function _(S){if(S===null){A(e.exit("chunkFlow"),!0),y(0),e.consume(S);return}return G(S)?(e.consume(S),A(e.exit("chunkFlow")),r=0,t.interrupt=void 0,o):(e.consume(S),_)}function A(S,D){const P=t.sliceStream(S);if(D&&P.push(null),S.previous=a,a&&(a.next=S),a=S,i.defineSkip(S.start),i.write(P),t.parser.lazy[S.start.line]){let w=i.events.length;for(;w--;)if(i.events[w][1].start.offset<s&&(!i.events[w][1].end||i.events[w][1].end.offset>s))return;const z=t.events.length;let L=z,H,C;for(;L--;)if(t.events[L][0]==="exit"&&t.events[L][1].type==="chunkFlow"){if(H){C=t.events[L][1].end;break}H=!0}for(y(r),w=z;w<t.events.length;)t.events[w][1].end={...C},w++;Ke(t.events,L+1,0,t.events.slice(z)),t.events.length=w}}function y(S){let D=n.length;for(;D-- >S;){const P=n[D];t.containerState=P[1],P[0].exit.call(t,e)}n.length=S}function I(){i.write([null]),a=void 0,i=void 0,t.containerState._closeFlow=void 0}}function vT(e,t,n){return oe(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}const LT={tokenize:RT};function RT(e){const t=this,n=e.attempt(er,r,e.attempt(this.parser.constructs.flowInitial,i,oe(e,e.attempt(this.parser.constructs.flow,i,e.attempt(Tb,i)),"linePrefix")));return n;function r(a){if(a===null){e.consume(a);return}return e.enter("lineEndingBlank"),e.consume(a),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n}function i(a){if(a===null){e.consume(a);return}return e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),t.currentConstruct=void 0,n}}const OT={resolveAll:Uc()},DT=Hc("string"),PT=Hc("text");function Hc(e){return{resolveAll:Uc(e==="text"?MT:void 0),tokenize:t};function t(n){const r=this,i=this.parser.constructs[e],a=n.attempt(i,s,o);return s;function s(f){return c(f)?a(f):o(f)}function o(f){if(f===null){n.consume(f);return}return n.enter("data"),n.consume(f),u}function u(f){return c(f)?(n.exit("data"),a(f)):(n.consume(f),u)}function c(f){if(f===null)return!0;const d=i[f];let h=-1;if(d)for(;++h<d.length;){const p=d[h];if(!p.previous||p.previous.call(r,r.previous))return!0}return!1}}}function Uc(e){return t;function t(n,r){let i=-1,a;for(;++i<=n.length;)a===void 0?n[i]&&n[i][1].type==="data"&&(a=i,i++):(!n[i]||n[i][1].type!=="data")&&(i!==a+2&&(n[a][1].end=n[i-1][1].end,n.splice(a+2,i-a-2),i=a+2),a=void 0);return e?e(n,r):n}}function MT(e,t){let n=0;for(;++n<=e.length;)if((n===e.length||e[n][1].type==="lineEnding")&&e[n-1][1].type==="data"){const r=e[n-1][1],i=t.sliceStream(r);let a=i.length,s=-1,o=0,u;for(;a--;){const c=i[a];if(typeof c=="string"){for(s=c.length;c.charCodeAt(s-1)===32;)o++,s--;if(s)break;s=-1}else if(c===-2)u=!0,o++;else if(c!==-1){a++;break}}if(t._contentTypeTextTrailing&&n===e.length&&(o=0),o){const c={type:n===e.length||u||o<2?"lineSuffix":"hardBreakTrailing",start:{_bufferIndex:a?s:r.start._bufferIndex+s,_index:r.start._index+a,line:r.end.line,column:r.end.column-o,offset:r.end.offset-o},end:{...r.end}};r.end={...c.start},r.start.offset===r.end.offset?Object.assign(r,c):(e.splice(n,0,["enter",c,t],["exit",c,t]),n+=2)}n++}return e}const BT=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:{null:[42,95]},contentInitial:{91:wb},disable:{null:[]},document:{42:We,43:We,45:We,48:We,49:We,50:We,51:We,52:We,53:We,54:We,55:We,56:We,57:We,62:Ml},flow:{35:vb,42:Zr,45:[ql,Zr],60:Db,61:ql,95:Zr,96:Ul,126:Ul},flowInitial:{[-2]:Sa,[-1]:Sa,32:Sa},insideSpan:{null:[Ca,OT]},string:{38:Fl,92:Bl},text:{[-5]:Na,[-4]:Na,[-3]:Na,33:Zb,38:Fl,42:Ca,60:[eb,zb],91:e2,92:[Ib,Bl],93:Ia,95:Ca,96:hb}},Symbol.toStringTag,{value:"Module"}));function FT(e,t,n){let r={_bufferIndex:-1,_index:0,line:n&&n.line||1,column:n&&n.column||1,offset:n&&n.offset||0};const i={},a=[];let s=[],o=[];const u={attempt:z(P),check:z(w),consume:I,enter:S,exit:D,interrupt:z(w,{interrupt:!0})},c={code:null,containerState:{},defineSkip:_,events:[],now:m,parser:e,previous:null,sliceSerialize:h,sliceStream:p,write:d};let f=t.tokenize.call(c,u);return t.resolveAll&&a.push(t),c;function d($){return s=it(s,$),A(),s[s.length-1]!==null?[]:(L(t,0),c.events=Xr(a,c.events,c),c.events)}function h($,B){return UT(p($),B)}function p($){return HT(s,$)}function m(){const{_bufferIndex:$,_index:B,line:Q,column:ae,offset:X}=r;return{_bufferIndex:$,_index:B,line:Q,column:ae,offset:X}}function _($){i[$.line]=$.column,C()}function A(){let $;for(;r._index<s.length;){const B=s[r._index];if(typeof B=="string")for($=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===$&&r._bufferIndex<B.length;)y(B.charCodeAt(r._bufferIndex));else y(B)}}function y($){f=f($)}function I($){G($)?(r.line++,r.column=1,r.offset+=$===-3?2:1,C()):$!==-1&&(r.column++,r.offset++),r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===s[r._index].length&&(r._bufferIndex=-1,r._index++)),c.previous=$}function S($,B){const Q=B||{};return Q.type=$,Q.start=m(),c.events.push(["enter",Q,c]),o.push(Q),Q}function D($){const B=o.pop();return B.end=m(),c.events.push(["exit",B,c]),B}function P($,B){L($,B.from)}function w($,B){B.restore()}function z($,B){return Q;function Q(ae,X,Z){let ee,q,Ye,x;return Array.isArray(ae)?He(ae):"tokenize"in ae?He([ae]):Oe(ae);function Oe(ye){return Ee;function Ee(Je){const et=Je!==null&&ye[Je],tt=Je!==null&&ye.null,Et=[...Array.isArray(et)?et:et?[et]:[],...Array.isArray(tt)?tt:tt?[tt]:[]];return He(Et)(Je)}}function He(ye){return ee=ye,q=0,ye.length===0?Z:k(ye[q])}function k(ye){return Ee;function Ee(Je){return x=H(),Ye=ye,ye.partial||(c.currentConstruct=ye),ye.name&&c.parser.constructs.disable.null.includes(ye.name)?je():ye.tokenize.call(B?Object.assign(Object.create(c),B):c,u,me,je)(Je)}}function me(ye){return $(Ye,x),X}function je(ye){return x.restore(),++q<ee.length?k(ee[q]):Z}}}function L($,B){$.resolveAll&&!a.includes($)&&a.push($),$.resolve&&Ke(c.events,B,c.events.length-B,$.resolve(c.events.slice(B),c)),$.resolveTo&&(c.events=$.resolveTo(c.events,c))}function H(){const $=m(),B=c.previous,Q=c.currentConstruct,ae=c.events.length,X=Array.from(o);return{from:ae,restore:Z};function Z(){r=$,c.previous=B,c.currentConstruct=Q,c.events.length=ae,o=X,C()}}function C(){r.line in i&&r.column<2&&(r.column=i[r.line],r.offset+=i[r.line]-1)}}function HT(e,t){const n=t.start._index,r=t.start._bufferIndex,i=t.end._index,a=t.end._bufferIndex;let s;if(n===i)s=[e[n].slice(r,a)];else{if(s=e.slice(n,i),r>-1){const o=s[0];typeof o=="string"?s[0]=o.slice(r):s.shift()}a>0&&s.push(e[i].slice(0,a))}return s}function UT(e,t){let n=-1;const r=[];let i;for(;++n<e.length;){const a=e[n];let s;if(typeof a=="string")s=a;else switch(a){case-5:{s="\r";break}case-4:{s=`
|
|
35
|
+
$$`:`${e}$$`},i3=e=>n3(e)%2===0?e:r3(e),a3=(e,t,n)=>{if(e.substring(t+2).includes(")"))return null;let r=SE(e,t);if(r===-1||fr(e,r))return null;let i=r>0&&e[r-1]==="!",a=i?r-1:r,s=e.substring(0,a);if(i)return s;let o=e.substring(r+1,t);return n==="text-only"?`${s}${o}`:`${s}[${o}](streamdown:incomplete-link)`},hc=(e,t)=>{for(let n=0;n<t;n++)if(e[n]==="["&&!fr(e,n)){if(n>0&&e[n-1]==="!")continue;let r=uc(e,n);if(r===-1)return n;if(r+1<e.length&&e[r+1]==="("){let i=e.indexOf(")",r+2);i!==-1&&(n=i)}}return t},s3=(e,t,n)=>{let r=t>0&&e[t-1]==="!",i=r?t-1:t;if(!e.substring(t+1).includes("]")){let a=e.substring(0,i);if(r)return a;if(n==="text-only"){let s=hc(e,t);return e.substring(0,s)+e.substring(s+1)}return`${e}](streamdown:incomplete-link)`}if(uc(e,t)===-1){let a=e.substring(0,i);if(r)return a;if(n==="text-only"){let s=hc(e,t);return e.substring(0,s)+e.substring(s+1)}return`${e}](streamdown:incomplete-link)`}return null},pc=(e,t="protocol")=>{let n=e.lastIndexOf("](");if(n!==-1&&!fr(e,n)){let r=a3(e,n,t);if(r!==null)return r}for(let r=e.length-1;r>=0;r-=1)if(e[r]==="["&&!fr(e,r)){let i=s3(e,r,t);if(i!==null)return i}return e},o3=/^-{1,2}$/,u3=/^[\s]*-{1,2}[\s]+$/,l3=/^={1,2}$/,c3=/^[\s]*={1,2}[\s]+$/,d3=e=>{if(!e||typeof e!="string")return e;let t=e.lastIndexOf(`
|
|
36
|
+
`);if(t===-1)return e;let n=e.substring(t+1),r=e.substring(0,t),i=n.trim();if(o3.test(i)&&!n.match(u3)){let a=r.split(`
|
|
37
|
+
`).at(-1);if(a&&a.trim().length>0)return`${e}`}if(l3.test(i)&&!n.match(c3)){let a=r.split(`
|
|
38
|
+
`).at(-1);if(a&&a.trim().length>0)return`${e}`}return e},f3=e=>{var t,n;let r=e.match(kE);if(r){let i=r[2];if(!i||rn.test(i))return e;if(((t=e.match(oc))==null?void 0:t.length)%2===1)return`${e}~~`}else if(e.match(CE)&&((n=e.match(oc))==null?void 0:n.length)%2===1)return`${e}~`;return e},Ua=e=>e!==!1,Xe={COMPARISON_OPERATORS:-10,HTML_TAGS:-5,SETEXT_HEADINGS:0,LINKS:10,BOLD_ITALIC:20,BOLD:30,ITALIC_DOUBLE_UNDERSCORE:40,ITALIC_SINGLE_ASTERISK:41,ITALIC_SINGLE_UNDERSCORE:42,INLINE_CODE:50,STRIKETHROUGH:60,KATEX:70,DEFAULT:100},h3=[{handler:{name:"comparisonOperators",handle:LE,priority:Xe.COMPARISON_OPERATORS},optionKey:"comparisonOperators"},{handler:{name:"htmlTags",handle:XE,priority:Xe.HTML_TAGS},optionKey:"htmlTags"},{handler:{name:"setextHeadings",handle:d3,priority:Xe.SETEXT_HEADINGS},optionKey:"setextHeadings"},{handler:{name:"links",handle:pc,priority:Xe.LINKS},optionKey:"links",earlyReturn:e=>e.endsWith("](streamdown:incomplete-link)")},{handler:{name:"boldItalic",handle:WE,priority:Xe.BOLD_ITALIC},optionKey:"boldItalic"},{handler:{name:"bold",handle:BE,priority:Xe.BOLD},optionKey:"bold"},{handler:{name:"italicDoubleUnderscore",handle:HE,priority:Xe.ITALIC_DOUBLE_UNDERSCORE},optionKey:"italic"},{handler:{name:"italicSingleAsterisk",handle:zE,priority:Xe.ITALIC_SINGLE_ASTERISK},optionKey:"italic"},{handler:{name:"italicSingleUnderscore",handle:jE,priority:Xe.ITALIC_SINGLE_UNDERSCORE},optionKey:"italic"},{handler:{name:"inlineCode",handle:e3,priority:Xe.INLINE_CODE},optionKey:"inlineCode"},{handler:{name:"strikethrough",handle:f3,priority:Xe.STRIKETHROUGH},optionKey:"strikethrough"},{handler:{name:"katex",handle:i3,priority:Xe.KATEX},optionKey:"katex"}],p3=e=>{var t;let n=(t=e?.linkMode)!=null?t:"protocol";return h3.filter(({handler:r,optionKey:i})=>r.name==="links"?Ua(e?.links)||Ua(e?.images):Ua(e?.[i])).map(({handler:r,earlyReturn:i})=>r.name==="links"?{handler:ac(ic({},r),{handle:a=>pc(a,n)}),earlyReturn:n==="protocol"?i:void 0}:{handler:r,earlyReturn:i})},m3=(e,t)=>{var n;if(!e||typeof e!="string")return e;let r=e.endsWith(" ")&&!e.endsWith(" ")?e.slice(0,-1):e,i=p3(t),a=((n=t?.handlers)!=null?n:[]).map(o=>{var u;return{handler:ac(ic({},o),{priority:(u=o.priority)!=null?u:Xe.DEFAULT}),earlyReturn:void 0}}),s=[...i,...a].sort((o,u)=>{var c,f;return((c=o.handler.priority)!=null?c:0)-((f=u.handler.priority)!=null?f:0)});for(let{handler:o,earlyReturn:u}of s)if(r=o.handle(r),u!=null&&u(r))return r;return r},g3=m3;function mc(e){var t,n,r="";if(typeof e=="string"||typeof e=="number")r+=e;else if(typeof e=="object")if(Array.isArray(e)){var i=e.length;for(t=0;t<i;t++)e[t]&&(n=mc(e[t]))&&(r&&(r+=" "),r+=n)}else for(n in e)e[n]&&(r&&(r+=" "),r+=n);return r}function b3(){for(var e,t,n=0,r="",i=arguments.length;n<i;n++)(e=arguments[n])&&(t=mc(e))&&(r&&(r+=" "),r+=t);return r}const E3=(e,t)=>{const n=new Array(e.length+t.length);for(let r=0;r<e.length;r++)n[r]=e[r];for(let r=0;r<t.length;r++)n[e.length+r]=t[r];return n},T3=(e,t)=>({classGroupId:e,validator:t}),gc=(e=new Map,t=null,n)=>({nextPart:e,validators:t,classGroupId:n}),li="-",bc=[],_3="arbitrary..",k3=e=>{const t=y3(e),{conflictingClassGroups:n,conflictingClassGroupModifiers:r}=e;return{getClassGroupId:s=>{if(s.startsWith("[")&&s.endsWith("]"))return x3(s);const o=s.split(li),u=o[0]===""&&o.length>1?1:0;return Ec(o,u,t)},getConflictingClassGroupIds:(s,o)=>{if(o){const u=r[s],c=n[s];return u?c?E3(c,u):u:c||bc}return n[s]||bc}}},Ec=(e,t,n)=>{if(e.length-t===0)return n.classGroupId;const i=e[t],a=n.nextPart.get(i);if(a){const c=Ec(e,t+1,a);if(c)return c}const s=n.validators;if(s===null)return;const o=t===0?e.join(li):e.slice(t).join(li),u=s.length;for(let c=0;c<u;c++){const f=s[c];if(f.validator(o))return f.classGroupId}},x3=e=>e.slice(1,-1).indexOf(":")===-1?void 0:(()=>{const t=e.slice(1,-1),n=t.indexOf(":"),r=t.slice(0,n);return r?_3+r:void 0})(),y3=e=>{const{theme:t,classGroups:n}=e;return w3(n,t)},w3=(e,t)=>{const n=gc();for(const r in e){const i=e[r];za(i,n,r,t)}return n},za=(e,t,n,r)=>{const i=e.length;for(let a=0;a<i;a++){const s=e[a];A3(s,t,n,r)}},A3=(e,t,n,r)=>{if(typeof e=="string"){C3(e,t,n);return}if(typeof e=="function"){S3(e,t,n,r);return}N3(e,t,n,r)},C3=(e,t,n)=>{const r=e===""?t:Tc(t,e);r.classGroupId=n},S3=(e,t,n,r)=>{if(I3(e)){za(e(r),t,n,r);return}t.validators===null&&(t.validators=[]),t.validators.push(T3(n,e))},N3=(e,t,n,r)=>{const i=Object.entries(e),a=i.length;for(let s=0;s<a;s++){const[o,u]=i[s];za(u,Tc(t,o),n,r)}},Tc=(e,t)=>{let n=e;const r=t.split(li),i=r.length;for(let a=0;a<i;a++){const s=r[a];let o=n.nextPart.get(s);o||(o=gc(),n.nextPart.set(s,o)),n=o}return n},I3=e=>"isThemeGetter"in e&&e.isThemeGetter===!0,v3=e=>{if(e<1)return{get:()=>{},set:()=>{}};let t=0,n=Object.create(null),r=Object.create(null);const i=(a,s)=>{n[a]=s,t++,t>e&&(t=0,r=n,n=Object.create(null))};return{get(a){let s=n[a];if(s!==void 0)return s;if((s=r[a])!==void 0)return i(a,s),s},set(a,s){a in n?n[a]=s:i(a,s)}}},$a="!",_c=":",L3=[],kc=(e,t,n,r,i)=>({modifiers:e,hasImportantModifier:t,baseClassName:n,maybePostfixModifierPosition:r,isExternal:i}),R3=e=>{const{prefix:t,experimentalParseClassName:n}=e;let r=i=>{const a=[];let s=0,o=0,u=0,c;const f=i.length;for(let _=0;_<f;_++){const w=i[_];if(s===0&&o===0){if(w===_c){a.push(i.slice(u,_)),u=_+1;continue}if(w==="/"){c=_;continue}}w==="["?s++:w==="]"?s--:w==="("?o++:w===")"&&o--}const d=a.length===0?i:i.slice(u);let h=d,p=!1;d.endsWith($a)?(h=d.slice(0,-1),p=!0):d.startsWith($a)&&(h=d.slice(1),p=!0);const m=c&&c>u?c-u:void 0;return kc(a,p,h,m)};if(t){const i=t+_c,a=r;r=s=>s.startsWith(i)?a(s.slice(i.length)):kc(L3,!1,s,void 0,!0)}if(n){const i=r;r=a=>n({className:a,parseClassName:i})}return r},O3=e=>{const t=new Map;return e.orderSensitiveModifiers.forEach((n,r)=>{t.set(n,1e6+r)}),n=>{const r=[];let i=[];for(let a=0;a<n.length;a++){const s=n[a],o=s[0]==="[",u=t.has(s);o||u?(i.length>0&&(i.sort(),r.push(...i),i=[]),r.push(s)):i.push(s)}return i.length>0&&(i.sort(),r.push(...i)),r}},D3=e=>({cache:v3(e.cacheSize),parseClassName:R3(e),sortModifiers:O3(e),...k3(e)}),P3=/\s+/,M3=(e,t)=>{const{parseClassName:n,getClassGroupId:r,getConflictingClassGroupIds:i,sortModifiers:a}=t,s=[],o=e.trim().split(P3);let u="";for(let c=o.length-1;c>=0;c-=1){const f=o[c],{isExternal:d,modifiers:h,hasImportantModifier:p,baseClassName:m,maybePostfixModifierPosition:_}=n(f);if(d){u=f+(u.length>0?" "+u:u);continue}let w=!!_,y=r(w?m.substring(0,_):m);if(!y){if(!w){u=f+(u.length>0?" "+u:u);continue}if(y=r(m),!y){u=f+(u.length>0?" "+u:u);continue}w=!1}const S=h.length===0?"":h.length===1?h[0]:a(h).join(":"),C=p?S+$a:S,D=C+y;if(s.indexOf(D)>-1)continue;s.push(D);const P=i(y,w);for(let A=0;A<P.length;++A){const U=P[A];s.push(C+U)}u=f+(u.length>0?" "+u:u)}return u},B3=(...e)=>{let t=0,n,r,i="";for(;t<e.length;)(n=e[t++])&&(r=xc(n))&&(i&&(i+=" "),i+=r);return i},xc=e=>{if(typeof e=="string")return e;let t,n="";for(let r=0;r<e.length;r++)e[r]&&(t=xc(e[r]))&&(n&&(n+=" "),n+=t);return n},F3=(e,...t)=>{let n,r,i,a;const s=u=>{const c=t.reduce((f,d)=>d(f),e());return n=D3(c),r=n.cache.get,i=n.cache.set,a=o,o(u)},o=u=>{const c=r(u);if(c)return c;const f=M3(u,n);return i(u,f),f};return a=s,(...u)=>a(B3(...u))},H3=[],ve=e=>{const t=n=>n[e]||H3;return t.isThemeGetter=!0,t},yc=/^\[(?:(\w[\w-]*):)?(.+)\]$/i,wc=/^\((?:(\w[\w-]*):)?(.+)\)$/i,U3=/^\d+(?:\.\d+)?\/\d+(?:\.\d+)?$/,z3=/^(\d+(\.\d+)?)?(xs|sm|md|lg|xl)$/,$3=/\d+(%|px|r?em|[sdl]?v([hwib]|min|max)|pt|pc|in|cm|mm|cap|ch|ex|r?lh|cq(w|h|i|b|min|max))|\b(calc|min|max|clamp)\(.+\)|^0$/,Y3=/^(rgba?|hsla?|hwb|(ok)?(lab|lch)|color-mix)\(.+\)$/,j3=/^(inset_)?-?((\d+)?\.?(\d+)[a-z]+|0)_-?((\d+)?\.?(\d+)[a-z]+|0)/,V3=/^(url|image|image-set|cross-fade|element|(repeating-)?(linear|radial|conic)-gradient)\(.+\)$/,Bt=e=>U3.test(e),ee=e=>!!e&&!Number.isNaN(Number(e)),Ft=e=>!!e&&Number.isInteger(Number(e)),Ya=e=>e.endsWith("%")&&ee(e.slice(0,-1)),wt=e=>z3.test(e),Ac=()=>!0,q3=e=>$3.test(e)&&!Y3.test(e),ja=()=>!1,W3=e=>j3.test(e),G3=e=>V3.test(e),Q3=e=>!j(e)&&!V(e),K3=e=>Ht(e,Lc,ja),j=e=>yc.test(e),an=e=>Ht(e,Rc,q3),Cc=e=>Ht(e,iT,ee),X3=e=>Ht(e,Dc,Ac),Z3=e=>Ht(e,Oc,ja),Sc=e=>Ht(e,Ic,ja),J3=e=>Ht(e,vc,G3),ci=e=>Ht(e,Pc,W3),V=e=>wc.test(e),hr=e=>sn(e,Rc),eT=e=>sn(e,Oc),Nc=e=>sn(e,Ic),tT=e=>sn(e,Lc),nT=e=>sn(e,vc),di=e=>sn(e,Pc,!0),rT=e=>sn(e,Dc,!0),Ht=(e,t,n)=>{const r=yc.exec(e);return r?r[1]?t(r[1]):n(r[2]):!1},sn=(e,t,n=!1)=>{const r=wc.exec(e);return r?r[1]?t(r[1]):n:!1},Ic=e=>e==="position"||e==="percentage",vc=e=>e==="image"||e==="url",Lc=e=>e==="length"||e==="size"||e==="bg-size",Rc=e=>e==="length",iT=e=>e==="number",Oc=e=>e==="family-name",Dc=e=>e==="number"||e==="weight",Pc=e=>e==="shadow",aT=F3(()=>{const e=ve("color"),t=ve("font"),n=ve("text"),r=ve("font-weight"),i=ve("tracking"),a=ve("leading"),s=ve("breakpoint"),o=ve("container"),u=ve("spacing"),c=ve("radius"),f=ve("shadow"),d=ve("inset-shadow"),h=ve("text-shadow"),p=ve("drop-shadow"),m=ve("blur"),_=ve("perspective"),w=ve("aspect"),y=ve("ease"),S=ve("animate"),C=()=>["auto","avoid","all","avoid-page","page","left","right","column"],D=()=>["center","top","bottom","left","right","top-left","left-top","top-right","right-top","bottom-right","right-bottom","bottom-left","left-bottom"],P=()=>[...D(),V,j],A=()=>["auto","hidden","clip","visible","scroll"],U=()=>["auto","contain","none"],I=()=>[V,j,u],H=()=>[Bt,"full","auto",...I()],N=()=>[Ft,"none","subgrid",V,j],$=()=>["auto",{span:["full",Ft,V,j]},Ft,V,j],B=()=>[Ft,"auto",V,j],W=()=>["auto","min","max","fr",V,j],ie=()=>["start","end","center","between","around","evenly","stretch","baseline","center-safe","end-safe"],K=()=>["start","end","center","stretch","center-safe","end-safe"],de=()=>["auto",...I()],re=()=>[Bt,"auto","full","dvw","dvh","lvw","lvh","svw","svh","min","max","fit",...I()],Se=()=>[Bt,"screen","full","dvw","lvw","svw","min","max","fit",...I()],Le=()=>[Bt,"screen","full","lh","dvh","lvh","svh","min","max","fit",...I()],T=()=>[e,V,j],Re=()=>[...D(),Nc,Sc,{position:[V,j]}],Z=()=>["no-repeat",{repeat:["","x","y","space","round"]}],x=()=>["auto","cover","contain",tT,K3,{size:[V,j]}],Ne=()=>[Ya,hr,an],he=()=>["","none","full",c,V,j],ae=()=>["",ee,hr,an],rt=()=>["solid","dashed","dotted","double"],Je=()=>["normal","multiply","screen","overlay","darken","lighten","color-dodge","color-burn","hard-light","soft-light","difference","exclusion","hue","saturation","color","luminosity"],be=()=>[ee,Ya,Nc,Sc],lt=()=>["","none",m,V,j],ct=()=>["none",ee,V,j],$t=()=>["none",ee,V,j],dn=()=>[ee,V,j],Yt=()=>[Bt,"full",...I()];return{cacheSize:500,theme:{animate:["spin","ping","pulse","bounce"],aspect:["video"],blur:[wt],breakpoint:[wt],color:[Ac],container:[wt],"drop-shadow":[wt],ease:["in","out","in-out"],font:[Q3],"font-weight":["thin","extralight","light","normal","medium","semibold","bold","extrabold","black"],"inset-shadow":[wt],leading:["none","tight","snug","normal","relaxed","loose"],perspective:["dramatic","near","normal","midrange","distant","none"],radius:[wt],shadow:[wt],spacing:["px",ee],text:[wt],"text-shadow":[wt],tracking:["tighter","tight","normal","wide","wider","widest"]},classGroups:{aspect:[{aspect:["auto","square",Bt,j,V,w]}],container:["container"],columns:[{columns:[ee,j,V,o]}],"break-after":[{"break-after":C()}],"break-before":[{"break-before":C()}],"break-inside":[{"break-inside":["auto","avoid","avoid-page","avoid-column"]}],"box-decoration":[{"box-decoration":["slice","clone"]}],box:[{box:["border","content"]}],display:["block","inline-block","inline","flex","inline-flex","table","inline-table","table-caption","table-cell","table-column","table-column-group","table-footer-group","table-header-group","table-row-group","table-row","flow-root","grid","inline-grid","contents","list-item","hidden"],sr:["sr-only","not-sr-only"],float:[{float:["right","left","none","start","end"]}],clear:[{clear:["left","right","both","none","start","end"]}],isolation:["isolate","isolation-auto"],"object-fit":[{object:["contain","cover","fill","none","scale-down"]}],"object-position":[{object:P()}],overflow:[{overflow:A()}],"overflow-x":[{"overflow-x":A()}],"overflow-y":[{"overflow-y":A()}],overscroll:[{overscroll:U()}],"overscroll-x":[{"overscroll-x":U()}],"overscroll-y":[{"overscroll-y":U()}],position:["static","fixed","absolute","relative","sticky"],inset:[{inset:H()}],"inset-x":[{"inset-x":H()}],"inset-y":[{"inset-y":H()}],start:[{"inset-s":H(),start:H()}],end:[{"inset-e":H(),end:H()}],"inset-bs":[{"inset-bs":H()}],"inset-be":[{"inset-be":H()}],top:[{top:H()}],right:[{right:H()}],bottom:[{bottom:H()}],left:[{left:H()}],visibility:["visible","invisible","collapse"],z:[{z:[Ft,"auto",V,j]}],basis:[{basis:[Bt,"full","auto",o,...I()]}],"flex-direction":[{flex:["row","row-reverse","col","col-reverse"]}],"flex-wrap":[{flex:["nowrap","wrap","wrap-reverse"]}],flex:[{flex:[ee,Bt,"auto","initial","none",j]}],grow:[{grow:["",ee,V,j]}],shrink:[{shrink:["",ee,V,j]}],order:[{order:[Ft,"first","last","none",V,j]}],"grid-cols":[{"grid-cols":N()}],"col-start-end":[{col:$()}],"col-start":[{"col-start":B()}],"col-end":[{"col-end":B()}],"grid-rows":[{"grid-rows":N()}],"row-start-end":[{row:$()}],"row-start":[{"row-start":B()}],"row-end":[{"row-end":B()}],"grid-flow":[{"grid-flow":["row","col","dense","row-dense","col-dense"]}],"auto-cols":[{"auto-cols":W()}],"auto-rows":[{"auto-rows":W()}],gap:[{gap:I()}],"gap-x":[{"gap-x":I()}],"gap-y":[{"gap-y":I()}],"justify-content":[{justify:[...ie(),"normal"]}],"justify-items":[{"justify-items":[...K(),"normal"]}],"justify-self":[{"justify-self":["auto",...K()]}],"align-content":[{content:["normal",...ie()]}],"align-items":[{items:[...K(),{baseline:["","last"]}]}],"align-self":[{self:["auto",...K(),{baseline:["","last"]}]}],"place-content":[{"place-content":ie()}],"place-items":[{"place-items":[...K(),"baseline"]}],"place-self":[{"place-self":["auto",...K()]}],p:[{p:I()}],px:[{px:I()}],py:[{py:I()}],ps:[{ps:I()}],pe:[{pe:I()}],pbs:[{pbs:I()}],pbe:[{pbe:I()}],pt:[{pt:I()}],pr:[{pr:I()}],pb:[{pb:I()}],pl:[{pl:I()}],m:[{m:de()}],mx:[{mx:de()}],my:[{my:de()}],ms:[{ms:de()}],me:[{me:de()}],mbs:[{mbs:de()}],mbe:[{mbe:de()}],mt:[{mt:de()}],mr:[{mr:de()}],mb:[{mb:de()}],ml:[{ml:de()}],"space-x":[{"space-x":I()}],"space-x-reverse":["space-x-reverse"],"space-y":[{"space-y":I()}],"space-y-reverse":["space-y-reverse"],size:[{size:re()}],"inline-size":[{inline:["auto",...Se()]}],"min-inline-size":[{"min-inline":["auto",...Se()]}],"max-inline-size":[{"max-inline":["none",...Se()]}],"block-size":[{block:["auto",...Le()]}],"min-block-size":[{"min-block":["auto",...Le()]}],"max-block-size":[{"max-block":["none",...Le()]}],w:[{w:[o,"screen",...re()]}],"min-w":[{"min-w":[o,"screen","none",...re()]}],"max-w":[{"max-w":[o,"screen","none","prose",{screen:[s]},...re()]}],h:[{h:["screen","lh",...re()]}],"min-h":[{"min-h":["screen","lh","none",...re()]}],"max-h":[{"max-h":["screen","lh",...re()]}],"font-size":[{text:["base",n,hr,an]}],"font-smoothing":["antialiased","subpixel-antialiased"],"font-style":["italic","not-italic"],"font-weight":[{font:[r,rT,X3]}],"font-stretch":[{"font-stretch":["ultra-condensed","extra-condensed","condensed","semi-condensed","normal","semi-expanded","expanded","extra-expanded","ultra-expanded",Ya,j]}],"font-family":[{font:[eT,Z3,t]}],"font-features":[{"font-features":[j]}],"fvn-normal":["normal-nums"],"fvn-ordinal":["ordinal"],"fvn-slashed-zero":["slashed-zero"],"fvn-figure":["lining-nums","oldstyle-nums"],"fvn-spacing":["proportional-nums","tabular-nums"],"fvn-fraction":["diagonal-fractions","stacked-fractions"],tracking:[{tracking:[i,V,j]}],"line-clamp":[{"line-clamp":[ee,"none",V,Cc]}],leading:[{leading:[a,...I()]}],"list-image":[{"list-image":["none",V,j]}],"list-style-position":[{list:["inside","outside"]}],"list-style-type":[{list:["disc","decimal","none",V,j]}],"text-alignment":[{text:["left","center","right","justify","start","end"]}],"placeholder-color":[{placeholder:T()}],"text-color":[{text:T()}],"text-decoration":["underline","overline","line-through","no-underline"],"text-decoration-style":[{decoration:[...rt(),"wavy"]}],"text-decoration-thickness":[{decoration:[ee,"from-font","auto",V,an]}],"text-decoration-color":[{decoration:T()}],"underline-offset":[{"underline-offset":[ee,"auto",V,j]}],"text-transform":["uppercase","lowercase","capitalize","normal-case"],"text-overflow":["truncate","text-ellipsis","text-clip"],"text-wrap":[{text:["wrap","nowrap","balance","pretty"]}],indent:[{indent:I()}],"vertical-align":[{align:["baseline","top","middle","bottom","text-top","text-bottom","sub","super",V,j]}],whitespace:[{whitespace:["normal","nowrap","pre","pre-line","pre-wrap","break-spaces"]}],break:[{break:["normal","words","all","keep"]}],wrap:[{wrap:["break-word","anywhere","normal"]}],hyphens:[{hyphens:["none","manual","auto"]}],content:[{content:["none",V,j]}],"bg-attachment":[{bg:["fixed","local","scroll"]}],"bg-clip":[{"bg-clip":["border","padding","content","text"]}],"bg-origin":[{"bg-origin":["border","padding","content"]}],"bg-position":[{bg:Re()}],"bg-repeat":[{bg:Z()}],"bg-size":[{bg:x()}],"bg-image":[{bg:["none",{linear:[{to:["t","tr","r","br","b","bl","l","tl"]},Ft,V,j],radial:["",V,j],conic:[Ft,V,j]},nT,J3]}],"bg-color":[{bg:T()}],"gradient-from-pos":[{from:Ne()}],"gradient-via-pos":[{via:Ne()}],"gradient-to-pos":[{to:Ne()}],"gradient-from":[{from:T()}],"gradient-via":[{via:T()}],"gradient-to":[{to:T()}],rounded:[{rounded:he()}],"rounded-s":[{"rounded-s":he()}],"rounded-e":[{"rounded-e":he()}],"rounded-t":[{"rounded-t":he()}],"rounded-r":[{"rounded-r":he()}],"rounded-b":[{"rounded-b":he()}],"rounded-l":[{"rounded-l":he()}],"rounded-ss":[{"rounded-ss":he()}],"rounded-se":[{"rounded-se":he()}],"rounded-ee":[{"rounded-ee":he()}],"rounded-es":[{"rounded-es":he()}],"rounded-tl":[{"rounded-tl":he()}],"rounded-tr":[{"rounded-tr":he()}],"rounded-br":[{"rounded-br":he()}],"rounded-bl":[{"rounded-bl":he()}],"border-w":[{border:ae()}],"border-w-x":[{"border-x":ae()}],"border-w-y":[{"border-y":ae()}],"border-w-s":[{"border-s":ae()}],"border-w-e":[{"border-e":ae()}],"border-w-bs":[{"border-bs":ae()}],"border-w-be":[{"border-be":ae()}],"border-w-t":[{"border-t":ae()}],"border-w-r":[{"border-r":ae()}],"border-w-b":[{"border-b":ae()}],"border-w-l":[{"border-l":ae()}],"divide-x":[{"divide-x":ae()}],"divide-x-reverse":["divide-x-reverse"],"divide-y":[{"divide-y":ae()}],"divide-y-reverse":["divide-y-reverse"],"border-style":[{border:[...rt(),"hidden","none"]}],"divide-style":[{divide:[...rt(),"hidden","none"]}],"border-color":[{border:T()}],"border-color-x":[{"border-x":T()}],"border-color-y":[{"border-y":T()}],"border-color-s":[{"border-s":T()}],"border-color-e":[{"border-e":T()}],"border-color-bs":[{"border-bs":T()}],"border-color-be":[{"border-be":T()}],"border-color-t":[{"border-t":T()}],"border-color-r":[{"border-r":T()}],"border-color-b":[{"border-b":T()}],"border-color-l":[{"border-l":T()}],"divide-color":[{divide:T()}],"outline-style":[{outline:[...rt(),"none","hidden"]}],"outline-offset":[{"outline-offset":[ee,V,j]}],"outline-w":[{outline:["",ee,hr,an]}],"outline-color":[{outline:T()}],shadow:[{shadow:["","none",f,di,ci]}],"shadow-color":[{shadow:T()}],"inset-shadow":[{"inset-shadow":["none",d,di,ci]}],"inset-shadow-color":[{"inset-shadow":T()}],"ring-w":[{ring:ae()}],"ring-w-inset":["ring-inset"],"ring-color":[{ring:T()}],"ring-offset-w":[{"ring-offset":[ee,an]}],"ring-offset-color":[{"ring-offset":T()}],"inset-ring-w":[{"inset-ring":ae()}],"inset-ring-color":[{"inset-ring":T()}],"text-shadow":[{"text-shadow":["none",h,di,ci]}],"text-shadow-color":[{"text-shadow":T()}],opacity:[{opacity:[ee,V,j]}],"mix-blend":[{"mix-blend":[...Je(),"plus-darker","plus-lighter"]}],"bg-blend":[{"bg-blend":Je()}],"mask-clip":[{"mask-clip":["border","padding","content","fill","stroke","view"]},"mask-no-clip"],"mask-composite":[{mask:["add","subtract","intersect","exclude"]}],"mask-image-linear-pos":[{"mask-linear":[ee]}],"mask-image-linear-from-pos":[{"mask-linear-from":be()}],"mask-image-linear-to-pos":[{"mask-linear-to":be()}],"mask-image-linear-from-color":[{"mask-linear-from":T()}],"mask-image-linear-to-color":[{"mask-linear-to":T()}],"mask-image-t-from-pos":[{"mask-t-from":be()}],"mask-image-t-to-pos":[{"mask-t-to":be()}],"mask-image-t-from-color":[{"mask-t-from":T()}],"mask-image-t-to-color":[{"mask-t-to":T()}],"mask-image-r-from-pos":[{"mask-r-from":be()}],"mask-image-r-to-pos":[{"mask-r-to":be()}],"mask-image-r-from-color":[{"mask-r-from":T()}],"mask-image-r-to-color":[{"mask-r-to":T()}],"mask-image-b-from-pos":[{"mask-b-from":be()}],"mask-image-b-to-pos":[{"mask-b-to":be()}],"mask-image-b-from-color":[{"mask-b-from":T()}],"mask-image-b-to-color":[{"mask-b-to":T()}],"mask-image-l-from-pos":[{"mask-l-from":be()}],"mask-image-l-to-pos":[{"mask-l-to":be()}],"mask-image-l-from-color":[{"mask-l-from":T()}],"mask-image-l-to-color":[{"mask-l-to":T()}],"mask-image-x-from-pos":[{"mask-x-from":be()}],"mask-image-x-to-pos":[{"mask-x-to":be()}],"mask-image-x-from-color":[{"mask-x-from":T()}],"mask-image-x-to-color":[{"mask-x-to":T()}],"mask-image-y-from-pos":[{"mask-y-from":be()}],"mask-image-y-to-pos":[{"mask-y-to":be()}],"mask-image-y-from-color":[{"mask-y-from":T()}],"mask-image-y-to-color":[{"mask-y-to":T()}],"mask-image-radial":[{"mask-radial":[V,j]}],"mask-image-radial-from-pos":[{"mask-radial-from":be()}],"mask-image-radial-to-pos":[{"mask-radial-to":be()}],"mask-image-radial-from-color":[{"mask-radial-from":T()}],"mask-image-radial-to-color":[{"mask-radial-to":T()}],"mask-image-radial-shape":[{"mask-radial":["circle","ellipse"]}],"mask-image-radial-size":[{"mask-radial":[{closest:["side","corner"],farthest:["side","corner"]}]}],"mask-image-radial-pos":[{"mask-radial-at":D()}],"mask-image-conic-pos":[{"mask-conic":[ee]}],"mask-image-conic-from-pos":[{"mask-conic-from":be()}],"mask-image-conic-to-pos":[{"mask-conic-to":be()}],"mask-image-conic-from-color":[{"mask-conic-from":T()}],"mask-image-conic-to-color":[{"mask-conic-to":T()}],"mask-mode":[{mask:["alpha","luminance","match"]}],"mask-origin":[{"mask-origin":["border","padding","content","fill","stroke","view"]}],"mask-position":[{mask:Re()}],"mask-repeat":[{mask:Z()}],"mask-size":[{mask:x()}],"mask-type":[{"mask-type":["alpha","luminance"]}],"mask-image":[{mask:["none",V,j]}],filter:[{filter:["","none",V,j]}],blur:[{blur:lt()}],brightness:[{brightness:[ee,V,j]}],contrast:[{contrast:[ee,V,j]}],"drop-shadow":[{"drop-shadow":["","none",p,di,ci]}],"drop-shadow-color":[{"drop-shadow":T()}],grayscale:[{grayscale:["",ee,V,j]}],"hue-rotate":[{"hue-rotate":[ee,V,j]}],invert:[{invert:["",ee,V,j]}],saturate:[{saturate:[ee,V,j]}],sepia:[{sepia:["",ee,V,j]}],"backdrop-filter":[{"backdrop-filter":["","none",V,j]}],"backdrop-blur":[{"backdrop-blur":lt()}],"backdrop-brightness":[{"backdrop-brightness":[ee,V,j]}],"backdrop-contrast":[{"backdrop-contrast":[ee,V,j]}],"backdrop-grayscale":[{"backdrop-grayscale":["",ee,V,j]}],"backdrop-hue-rotate":[{"backdrop-hue-rotate":[ee,V,j]}],"backdrop-invert":[{"backdrop-invert":["",ee,V,j]}],"backdrop-opacity":[{"backdrop-opacity":[ee,V,j]}],"backdrop-saturate":[{"backdrop-saturate":[ee,V,j]}],"backdrop-sepia":[{"backdrop-sepia":["",ee,V,j]}],"border-collapse":[{border:["collapse","separate"]}],"border-spacing":[{"border-spacing":I()}],"border-spacing-x":[{"border-spacing-x":I()}],"border-spacing-y":[{"border-spacing-y":I()}],"table-layout":[{table:["auto","fixed"]}],caption:[{caption:["top","bottom"]}],transition:[{transition:["","all","colors","opacity","shadow","transform","none",V,j]}],"transition-behavior":[{transition:["normal","discrete"]}],duration:[{duration:[ee,"initial",V,j]}],ease:[{ease:["linear","initial",y,V,j]}],delay:[{delay:[ee,V,j]}],animate:[{animate:["none",S,V,j]}],backface:[{backface:["hidden","visible"]}],perspective:[{perspective:[_,V,j]}],"perspective-origin":[{"perspective-origin":P()}],rotate:[{rotate:ct()}],"rotate-x":[{"rotate-x":ct()}],"rotate-y":[{"rotate-y":ct()}],"rotate-z":[{"rotate-z":ct()}],scale:[{scale:$t()}],"scale-x":[{"scale-x":$t()}],"scale-y":[{"scale-y":$t()}],"scale-z":[{"scale-z":$t()}],"scale-3d":["scale-3d"],skew:[{skew:dn()}],"skew-x":[{"skew-x":dn()}],"skew-y":[{"skew-y":dn()}],transform:[{transform:[V,j,"","none","gpu","cpu"]}],"transform-origin":[{origin:P()}],"transform-style":[{transform:["3d","flat"]}],translate:[{translate:Yt()}],"translate-x":[{"translate-x":Yt()}],"translate-y":[{"translate-y":Yt()}],"translate-z":[{"translate-z":Yt()}],"translate-none":["translate-none"],accent:[{accent:T()}],appearance:[{appearance:["none","auto"]}],"caret-color":[{caret:T()}],"color-scheme":[{scheme:["normal","dark","light","light-dark","only-dark","only-light"]}],cursor:[{cursor:["auto","default","pointer","wait","text","move","help","not-allowed","none","context-menu","progress","cell","crosshair","vertical-text","alias","copy","no-drop","grab","grabbing","all-scroll","col-resize","row-resize","n-resize","e-resize","s-resize","w-resize","ne-resize","nw-resize","se-resize","sw-resize","ew-resize","ns-resize","nesw-resize","nwse-resize","zoom-in","zoom-out",V,j]}],"field-sizing":[{"field-sizing":["fixed","content"]}],"pointer-events":[{"pointer-events":["auto","none"]}],resize:[{resize:["none","","y","x"]}],"scroll-behavior":[{scroll:["auto","smooth"]}],"scroll-m":[{"scroll-m":I()}],"scroll-mx":[{"scroll-mx":I()}],"scroll-my":[{"scroll-my":I()}],"scroll-ms":[{"scroll-ms":I()}],"scroll-me":[{"scroll-me":I()}],"scroll-mbs":[{"scroll-mbs":I()}],"scroll-mbe":[{"scroll-mbe":I()}],"scroll-mt":[{"scroll-mt":I()}],"scroll-mr":[{"scroll-mr":I()}],"scroll-mb":[{"scroll-mb":I()}],"scroll-ml":[{"scroll-ml":I()}],"scroll-p":[{"scroll-p":I()}],"scroll-px":[{"scroll-px":I()}],"scroll-py":[{"scroll-py":I()}],"scroll-ps":[{"scroll-ps":I()}],"scroll-pe":[{"scroll-pe":I()}],"scroll-pbs":[{"scroll-pbs":I()}],"scroll-pbe":[{"scroll-pbe":I()}],"scroll-pt":[{"scroll-pt":I()}],"scroll-pr":[{"scroll-pr":I()}],"scroll-pb":[{"scroll-pb":I()}],"scroll-pl":[{"scroll-pl":I()}],"snap-align":[{snap:["start","end","center","align-none"]}],"snap-stop":[{snap:["normal","always"]}],"snap-type":[{snap:["none","x","y","both"]}],"snap-strictness":[{snap:["mandatory","proximity"]}],touch:[{touch:["auto","none","manipulation"]}],"touch-x":[{"touch-pan":["x","left","right"]}],"touch-y":[{"touch-pan":["y","up","down"]}],"touch-pz":["touch-pinch-zoom"],select:[{select:["none","text","all","auto"]}],"will-change":[{"will-change":["auto","scroll","contents","transform",V,j]}],fill:[{fill:["none",...T()]}],"stroke-w":[{stroke:[ee,hr,an,Cc]}],stroke:[{stroke:["none",...T()]}],"forced-color-adjust":[{"forced-color-adjust":["auto","none"]}]},conflictingClassGroups:{overflow:["overflow-x","overflow-y"],overscroll:["overscroll-x","overscroll-y"],inset:["inset-x","inset-y","inset-bs","inset-be","start","end","top","right","bottom","left"],"inset-x":["right","left"],"inset-y":["top","bottom"],flex:["basis","grow","shrink"],gap:["gap-x","gap-y"],p:["px","py","ps","pe","pbs","pbe","pt","pr","pb","pl"],px:["pr","pl"],py:["pt","pb"],m:["mx","my","ms","me","mbs","mbe","mt","mr","mb","ml"],mx:["mr","ml"],my:["mt","mb"],size:["w","h"],"font-size":["leading"],"fvn-normal":["fvn-ordinal","fvn-slashed-zero","fvn-figure","fvn-spacing","fvn-fraction"],"fvn-ordinal":["fvn-normal"],"fvn-slashed-zero":["fvn-normal"],"fvn-figure":["fvn-normal"],"fvn-spacing":["fvn-normal"],"fvn-fraction":["fvn-normal"],"line-clamp":["display","overflow"],rounded:["rounded-s","rounded-e","rounded-t","rounded-r","rounded-b","rounded-l","rounded-ss","rounded-se","rounded-ee","rounded-es","rounded-tl","rounded-tr","rounded-br","rounded-bl"],"rounded-s":["rounded-ss","rounded-es"],"rounded-e":["rounded-se","rounded-ee"],"rounded-t":["rounded-tl","rounded-tr"],"rounded-r":["rounded-tr","rounded-br"],"rounded-b":["rounded-br","rounded-bl"],"rounded-l":["rounded-tl","rounded-bl"],"border-spacing":["border-spacing-x","border-spacing-y"],"border-w":["border-w-x","border-w-y","border-w-s","border-w-e","border-w-bs","border-w-be","border-w-t","border-w-r","border-w-b","border-w-l"],"border-w-x":["border-w-r","border-w-l"],"border-w-y":["border-w-t","border-w-b"],"border-color":["border-color-x","border-color-y","border-color-s","border-color-e","border-color-bs","border-color-be","border-color-t","border-color-r","border-color-b","border-color-l"],"border-color-x":["border-color-r","border-color-l"],"border-color-y":["border-color-t","border-color-b"],translate:["translate-x","translate-y","translate-none"],"translate-none":["translate","translate-x","translate-y","translate-z"],"scroll-m":["scroll-mx","scroll-my","scroll-ms","scroll-me","scroll-mbs","scroll-mbe","scroll-mt","scroll-mr","scroll-mb","scroll-ml"],"scroll-mx":["scroll-mr","scroll-ml"],"scroll-my":["scroll-mt","scroll-mb"],"scroll-p":["scroll-px","scroll-py","scroll-ps","scroll-pe","scroll-pbs","scroll-pbe","scroll-pt","scroll-pr","scroll-pb","scroll-pl"],"scroll-px":["scroll-pr","scroll-pl"],"scroll-py":["scroll-pt","scroll-pb"],touch:["touch-x","touch-y","touch-pz"],"touch-x":["touch"],"touch-y":["touch"],"touch-pz":["touch"]},conflictingClassGroupModifiers:{"font-size":["leading"]},orderSensitiveModifiers:["*","**","after","backdrop","before","details-content","file","first-letter","first-line","marker","placeholder","selection"]}}),sT=/^[$_\p{ID_Start}][$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,oT=/^[$_\p{ID_Start}][-$_\u{200C}\u{200D}\p{ID_Continue}]*$/u,uT={};function Mc(e,t){return((t||uT).jsx?oT:sT).test(e)}const lT=/[ \t\n\f\r]/g;function cT(e){return typeof e=="object"?e.type==="text"?Bc(e.value):!1:Bc(e)}function Bc(e){return e.replace(lT,"")===""}var fi=typeof globalThis<"u"?globalThis:typeof window<"u"?window:typeof global<"u"?global:typeof self<"u"?self:{};function Fc(e){return e&&e.__esModule&&Object.prototype.hasOwnProperty.call(e,"default")?e.default:e}var Va={},Hc=/\/\*[^*]*\*+([^/*][^*]*\*+)*\//g,dT=/\n/g,fT=/^\s*/,hT=/^(\*?[-#/*\\\w]+(\[[0-9a-z_-]+\])?)\s*/,pT=/^:\s*/,mT=/^((?:'(?:\\'|.)*?'|"(?:\\"|.)*?"|\([^)]*?\)|[^};])+)/,gT=/^[;\s]*/,bT=/^\s+|\s+$/g,ET=`
|
|
39
|
+
`,Uc="/",zc="*",on="",TT="comment",_T="declaration";function kT(e,t){if(typeof e!="string")throw new TypeError("First argument must be a string");if(!e)return[];t=t||{};var n=1,r=1;function i(m){var _=m.match(dT);_&&(n+=_.length);var w=m.lastIndexOf(ET);r=~w?m.length-w:r+m.length}function a(){var m={line:n,column:r};return function(_){return _.position=new s(m),c(),_}}function s(m){this.start=m,this.end={line:n,column:r},this.source=t.source}s.prototype.content=e;function o(m){var _=new Error(t.source+":"+n+":"+r+": "+m);if(_.reason=m,_.filename=t.source,_.line=n,_.column=r,_.source=e,!t.silent)throw _}function u(m){var _=m.exec(e);if(_){var w=_[0];return i(w),e=e.slice(w.length),_}}function c(){u(fT)}function f(m){var _;for(m=m||[];_=d();)_!==!1&&m.push(_);return m}function d(){var m=a();if(!(Uc!=e.charAt(0)||zc!=e.charAt(1))){for(var _=2;on!=e.charAt(_)&&(zc!=e.charAt(_)||Uc!=e.charAt(_+1));)++_;if(_+=2,on===e.charAt(_-1))return o("End of comment missing");var w=e.slice(2,_-2);return r+=2,i(w),e=e.slice(_),r+=2,m({type:TT,comment:w})}}function h(){var m=a(),_=u(hT);if(_){if(d(),!u(pT))return o("property missing ':'");var w=u(mT),y=m({type:_T,property:$c(_[0].replace(Hc,on)),value:w?$c(w[0].replace(Hc,on)):on});return u(gT),y}}function p(){var m=[];f(m);for(var _;_=h();)_!==!1&&(m.push(_),f(m));return m}return c(),p()}function $c(e){return e?e.replace(bT,on):on}var xT=kT,yT=fi&&fi.__importDefault||function(e){return e&&e.__esModule?e:{default:e}};Object.defineProperty(Va,"__esModule",{value:!0}),Va.default=AT;const wT=yT(xT);function AT(e,t){let n=null;if(!e||typeof e!="string")return n;const r=(0,wT.default)(e),i=typeof t=="function";return r.forEach(a=>{if(a.type!=="declaration")return;const{property:s,value:o}=a;i?t(s,o,a):o&&(n=n||{},n[s]=o)}),n}var hi={};Object.defineProperty(hi,"__esModule",{value:!0}),hi.camelCase=void 0;var CT=/^--[a-zA-Z0-9_-]+$/,ST=/-([a-z])/g,NT=/^[^-]+$/,IT=/^-(webkit|moz|ms|o|khtml)-/,vT=/^-(ms)-/,LT=function(e){return!e||NT.test(e)||CT.test(e)},RT=function(e,t){return t.toUpperCase()},Yc=function(e,t){return"".concat(t,"-")},OT=function(e,t){return t===void 0&&(t={}),LT(e)?e:(e=e.toLowerCase(),t.reactCompat?e=e.replace(vT,Yc):e=e.replace(IT,Yc),e.replace(ST,RT))};hi.camelCase=OT;var DT=fi&&fi.__importDefault||function(e){return e&&e.__esModule?e:{default:e}},PT=DT(Va),MT=hi;function qa(e,t){var n={};return!e||typeof e!="string"||(0,PT.default)(e,function(r,i){r&&i&&(n[(0,MT.camelCase)(r,t)]=i)}),n}qa.default=qa;var BT=qa;const FT=Fc(BT);function pr(e){return!e||typeof e!="object"?"":"position"in e||"type"in e?jc(e.position):"start"in e||"end"in e?jc(e):"line"in e||"column"in e?Wa(e):""}function Wa(e){return Vc(e&&e.line)+":"+Vc(e&&e.column)}function jc(e){return Wa(e&&e.start)+"-"+Wa(e&&e.end)}function Vc(e){return e&&typeof e=="number"?e:1}class ze extends Error{constructor(t,n,r){super(),typeof n=="string"&&(r=n,n=void 0);let i="",a={},s=!1;if(n&&("line"in n&&"column"in n?a={place:n}:"start"in n&&"end"in n?a={place:n}:"type"in n?a={ancestors:[n],place:n.position}:a={...n}),typeof t=="string"?i=t:!a.cause&&t&&(s=!0,i=t.message,a.cause=t),!a.ruleId&&!a.source&&typeof r=="string"){const u=r.indexOf(":");u===-1?a.ruleId=r:(a.source=r.slice(0,u),a.ruleId=r.slice(u+1))}if(!a.place&&a.ancestors&&a.ancestors){const u=a.ancestors[a.ancestors.length-1];u&&(a.place=u.position)}const o=a.place&&"start"in a.place?a.place.start:a.place;this.ancestors=a.ancestors||void 0,this.cause=a.cause||void 0,this.column=o?o.column:void 0,this.fatal=void 0,this.file="",this.message=i,this.line=o?o.line:void 0,this.name=pr(a.place)||"1:1",this.place=a.place||void 0,this.reason=this.message,this.ruleId=a.ruleId||void 0,this.source=a.source||void 0,this.stack=s&&a.cause&&typeof a.cause.stack=="string"?a.cause.stack:"",this.actual=void 0,this.expected=void 0,this.note=void 0,this.url=void 0}}ze.prototype.file="",ze.prototype.name="",ze.prototype.reason="",ze.prototype.message="",ze.prototype.stack="",ze.prototype.column=void 0,ze.prototype.line=void 0,ze.prototype.ancestors=void 0,ze.prototype.cause=void 0,ze.prototype.fatal=void 0,ze.prototype.place=void 0,ze.prototype.ruleId=void 0,ze.prototype.source=void 0;const Ga={}.hasOwnProperty,HT=new Map,UT=/[A-Z]/g,zT=new Set(["table","tbody","thead","tfoot","tr"]),$T=new Set(["td","th"]),qc="https://github.com/syntax-tree/hast-util-to-jsx-runtime";function YT(e,t){if(!t||t.Fragment===void 0)throw new TypeError("Expected `Fragment` in options");const n=t.filePath||void 0;let r;if(t.development){if(typeof t.jsxDEV!="function")throw new TypeError("Expected `jsxDEV` in options when `development: true`");r=XT(n,t.jsxDEV)}else{if(typeof t.jsx!="function")throw new TypeError("Expected `jsx` in production options");if(typeof t.jsxs!="function")throw new TypeError("Expected `jsxs` in production options");r=KT(n,t.jsx,t.jsxs)}const i={Fragment:t.Fragment,ancestors:[],components:t.components||{},create:r,elementAttributeNameCase:t.elementAttributeNameCase||"react",evaluater:t.createEvaluater?t.createEvaluater():void 0,filePath:n,ignoreInvalidStyle:t.ignoreInvalidStyle||!1,passKeys:t.passKeys!==!1,passNode:t.passNode||!1,schema:t.space==="svg"?vt:Wn,stylePropertyNameCase:t.stylePropertyNameCase||"dom",tableCellAlignToStyle:t.tableCellAlignToStyle!==!1},a=Wc(i,e,void 0);return a&&typeof a!="string"?a:i.create(e,i.Fragment,{children:a||void 0},void 0)}function Wc(e,t,n){if(t.type==="element")return jT(e,t,n);if(t.type==="mdxFlowExpression"||t.type==="mdxTextExpression")return VT(e,t);if(t.type==="mdxJsxFlowElement"||t.type==="mdxJsxTextElement")return WT(e,t,n);if(t.type==="mdxjsEsm")return qT(e,t);if(t.type==="root")return GT(e,t,n);if(t.type==="text")return QT(e,t)}function jT(e,t,n){const r=e.schema;let i=r;t.tagName.toLowerCase()==="svg"&&r.space==="html"&&(i=vt,e.schema=i),e.ancestors.push(t);const a=Qc(e,t.tagName,!1),s=ZT(e,t);let o=Ka(e,t);return zT.has(t.tagName)&&(o=o.filter(function(u){return typeof u=="string"?!cT(u):!0})),Gc(e,s,a,t),Qa(s,o),e.ancestors.pop(),e.schema=r,e.create(t,a,s,n)}function VT(e,t){if(t.data&&t.data.estree&&e.evaluater){const r=t.data.estree.body[0];return e.evaluater.evaluateExpression(r.expression)}mr(e,t.position)}function qT(e,t){if(t.data&&t.data.estree&&e.evaluater)return e.evaluater.evaluateProgram(t.data.estree);mr(e,t.position)}function WT(e,t,n){const r=e.schema;let i=r;t.name==="svg"&&r.space==="html"&&(i=vt,e.schema=i),e.ancestors.push(t);const a=t.name===null?e.Fragment:Qc(e,t.name,!0),s=JT(e,t),o=Ka(e,t);return Gc(e,s,a,t),Qa(s,o),e.ancestors.pop(),e.schema=r,e.create(t,a,s,n)}function GT(e,t,n){const r={};return Qa(r,Ka(e,t)),e.create(t,e.Fragment,r,n)}function QT(e,t){return t.value}function Gc(e,t,n,r){typeof n!="string"&&n!==e.Fragment&&e.passNode&&(t.node=r)}function Qa(e,t){if(t.length>0){const n=t.length>1?t:t[0];n&&(e.children=n)}}function KT(e,t,n){return r;function r(i,a,s,o){const c=Array.isArray(s.children)?n:t;return o?c(a,s,o):c(a,s)}}function XT(e,t){return n;function n(r,i,a,s){const o=Array.isArray(a.children),u=gt(r);return t(i,a,s,o,{columnNumber:u?u.column-1:void 0,fileName:e,lineNumber:u?u.line:void 0},void 0)}}function ZT(e,t){const n={};let r,i;for(i in t.properties)if(i!=="children"&&Ga.call(t.properties,i)){const a=e_(e,i,t.properties[i]);if(a){const[s,o]=a;e.tableCellAlignToStyle&&s==="align"&&typeof o=="string"&&$T.has(t.tagName)?r=o:n[s]=o}}if(r){const a=n.style||(n.style={});a[e.stylePropertyNameCase==="css"?"text-align":"textAlign"]=r}return n}function JT(e,t){const n={};for(const r of t.attributes)if(r.type==="mdxJsxExpressionAttribute")if(r.data&&r.data.estree&&e.evaluater){const o=r.data.estree.body[0].expression.properties[0];Object.assign(n,e.evaluater.evaluateExpression(o.argument))}else mr(e,t.position);else{const i=r.name;let a;if(r.value&&typeof r.value=="object")if(r.value.data&&r.value.data.estree&&e.evaluater){const o=r.value.data.estree.body[0];a=e.evaluater.evaluateExpression(o.expression)}else mr(e,t.position);else a=r.value===null?!0:r.value;n[i]=a}return n}function Ka(e,t){const n=[];let r=-1;const i=e.passKeys?new Map:HT;for(;++r<t.children.length;){const a=t.children[r];let s;if(e.passKeys){const u=a.type==="element"?a.tagName:a.type==="mdxJsxFlowElement"||a.type==="mdxJsxTextElement"?a.name:void 0;if(u){const c=i.get(u)||0;s=u+"-"+c,i.set(u,c+1)}}const o=Wc(e,a,s);o!==void 0&&n.push(o)}return n}function e_(e,t,n){const r=jr(e.schema,t);if(!(n==null||typeof n=="number"&&Number.isNaN(n))){if(Array.isArray(n)&&(n=r.commaSeparated?Xo(n):eu(n)),r.property==="style"){let i=typeof n=="object"?n:t_(e,String(n));return e.stylePropertyNameCase==="css"&&(i=n_(i)),["style",i]}return[e.elementAttributeNameCase==="react"&&r.space?ah[r.property]||r.property:r.attribute,n]}}function t_(e,t){try{return FT(t,{reactCompat:!0})}catch(n){if(e.ignoreInvalidStyle)return{};const r=n,i=new ze("Cannot parse `style` attribute",{ancestors:e.ancestors,cause:r,ruleId:"style",source:"hast-util-to-jsx-runtime"});throw i.file=e.filePath||void 0,i.url=qc+"#cannot-parse-style-attribute",i}}function Qc(e,t,n){let r;if(!n)r={type:"Literal",value:t};else if(t.includes(".")){const i=t.split(".");let a=-1,s;for(;++a<i.length;){const o=Mc(i[a])?{type:"Identifier",name:i[a]}:{type:"Literal",value:i[a]};s=s?{type:"MemberExpression",object:s,property:o,computed:!!(a&&o.type==="Literal"),optional:!1}:o}r=s}else r=Mc(t)&&!/^[a-z]/.test(t)?{type:"Identifier",name:t}:{type:"Literal",value:t};if(r.type==="Literal"){const i=r.value;return Ga.call(e.components,i)?e.components[i]:i}if(e.evaluater)return e.evaluater.evaluateExpression(r);mr(e)}function mr(e,t){const n=new ze("Cannot handle MDX estrees without `createEvaluater`",{ancestors:e.ancestors,place:t,ruleId:"mdx-estree",source:"hast-util-to-jsx-runtime"});throw n.file=e.filePath||void 0,n.url=qc+"#cannot-handle-mdx-estrees-without-createevaluater",n}function n_(e){const t={};let n;for(n in e)Ga.call(e,n)&&(t[r_(n)]=e[n]);return t}function r_(e){let t=e.replace(UT,i_);return t.slice(0,3)==="ms-"&&(t="-"+t),t}function i_(e){return"-"+e.toLowerCase()}const Xa={action:["form"],cite:["blockquote","del","ins","q"],data:["object"],formAction:["button","input"],href:["a","area","base","link"],icon:["menuitem"],itemId:null,manifest:["html"],ping:["a","area"],poster:["video"],src:["audio","embed","iframe","img","input","script","source","track","video"]},a_={tokenize:s_};function s_(e){const t=e.attempt(this.parser.constructs.contentInitial,r,i);let n;return t;function r(o){if(o===null){e.consume(o);return}return e.enter("lineEnding"),e.consume(o),e.exit("lineEnding"),ue(e,t,"linePrefix")}function i(o){return e.enter("paragraph"),a(o)}function a(o){const u=e.enter("chunkText",{contentType:"text",previous:n});return n&&(n.next=u),n=u,s(o)}function s(o){if(o===null){e.exit("chunkText"),e.exit("paragraph"),e.consume(o);return}return G(o)?(e.consume(o),e.exit("chunkText"),a):(e.consume(o),s)}}const o_={tokenize:u_},Kc={tokenize:l_};function u_(e){const t=this,n=[];let r=0,i,a,s;return o;function o(C){if(r<n.length){const D=n[r];return t.containerState=D[1],e.attempt(D[0].continuation,u,c)(C)}return c(C)}function u(C){if(r++,t.containerState._closeFlow){t.containerState._closeFlow=void 0,i&&S();const D=t.events.length;let P=D,A;for(;P--;)if(t.events[P][0]==="exit"&&t.events[P][1].type==="chunkFlow"){A=t.events[P][1].end;break}y(r);let U=D;for(;U<t.events.length;)t.events[U][1].end={...A},U++;return Ke(t.events,P+1,0,t.events.slice(D)),t.events.length=U,c(C)}return o(C)}function c(C){if(r===n.length){if(!i)return h(C);if(i.currentConstruct&&i.currentConstruct.concrete)return m(C);t.interrupt=!!(i.currentConstruct&&!i._gfmTableDynamicInterruptHack)}return t.containerState={},e.check(Kc,f,d)(C)}function f(C){return i&&S(),y(r),h(C)}function d(C){return t.parser.lazy[t.now().line]=r!==n.length,s=t.now().offset,m(C)}function h(C){return t.containerState={},e.attempt(Kc,p,m)(C)}function p(C){return r++,n.push([t.currentConstruct,t.containerState]),h(C)}function m(C){if(C===null){i&&S(),y(0),e.consume(C);return}return i=i||t.parser.flow(t.now()),e.enter("chunkFlow",{_tokenizer:i,contentType:"flow",previous:a}),_(C)}function _(C){if(C===null){w(e.exit("chunkFlow"),!0),y(0),e.consume(C);return}return G(C)?(e.consume(C),w(e.exit("chunkFlow")),r=0,t.interrupt=void 0,o):(e.consume(C),_)}function w(C,D){const P=t.sliceStream(C);if(D&&P.push(null),C.previous=a,a&&(a.next=C),a=C,i.defineSkip(C.start),i.write(P),t.parser.lazy[C.start.line]){let A=i.events.length;for(;A--;)if(i.events[A][1].start.offset<s&&(!i.events[A][1].end||i.events[A][1].end.offset>s))return;const U=t.events.length;let I=U,H,N;for(;I--;)if(t.events[I][0]==="exit"&&t.events[I][1].type==="chunkFlow"){if(H){N=t.events[I][1].end;break}H=!0}for(y(r),A=U;A<t.events.length;)t.events[A][1].end={...N},A++;Ke(t.events,I+1,0,t.events.slice(U)),t.events.length=A}}function y(C){let D=n.length;for(;D-- >C;){const P=n[D];t.containerState=P[1],P[0].exit.call(t,e)}n.length=C}function S(){i.write([null]),a=void 0,i=void 0,t.containerState._closeFlow=void 0}}function l_(e,t,n){return ue(e,e.attempt(this.parser.constructs.document,t,n),"linePrefix",this.parser.constructs.disable.null.includes("codeIndented")?void 0:4)}const c_={tokenize:d_};function d_(e){const t=this,n=e.attempt(ur,r,e.attempt(this.parser.constructs.flowInitial,i,ue(e,e.attempt(this.parser.constructs.flow,i,e.attempt(Wb,i)),"linePrefix")));return n;function r(a){if(a===null){e.consume(a);return}return e.enter("lineEndingBlank"),e.consume(a),e.exit("lineEndingBlank"),t.currentConstruct=void 0,n}function i(a){if(a===null){e.consume(a);return}return e.enter("lineEnding"),e.consume(a),e.exit("lineEnding"),t.currentConstruct=void 0,n}}const f_={resolveAll:Zc()},h_=Xc("string"),p_=Xc("text");function Xc(e){return{resolveAll:Zc(e==="text"?m_:void 0),tokenize:t};function t(n){const r=this,i=this.parser.constructs[e],a=n.attempt(i,s,o);return s;function s(f){return c(f)?a(f):o(f)}function o(f){if(f===null){n.consume(f);return}return n.enter("data"),n.consume(f),u}function u(f){return c(f)?(n.exit("data"),a(f)):(n.consume(f),u)}function c(f){if(f===null)return!0;const d=i[f];let h=-1;if(d)for(;++h<d.length;){const p=d[h];if(!p.previous||p.previous.call(r,r.previous))return!0}return!1}}}function Zc(e){return t;function t(n,r){let i=-1,a;for(;++i<=n.length;)a===void 0?n[i]&&n[i][1].type==="data"&&(a=i,i++):(!n[i]||n[i][1].type!=="data")&&(i!==a+2&&(n[a][1].end=n[i-1][1].end,n.splice(a+2,i-a-2),i=a+2),a=void 0);return e?e(n,r):n}}function m_(e,t){let n=0;for(;++n<=e.length;)if((n===e.length||e[n][1].type==="lineEnding")&&e[n-1][1].type==="data"){const r=e[n-1][1],i=t.sliceStream(r);let a=i.length,s=-1,o=0,u;for(;a--;){const c=i[a];if(typeof c=="string"){for(s=c.length;c.charCodeAt(s-1)===32;)o++,s--;if(s)break;s=-1}else if(c===-2)u=!0,o++;else if(c!==-1){a++;break}}if(t._contentTypeTextTrailing&&n===e.length&&(o=0),o){const c={type:n===e.length||u||o<2?"lineSuffix":"hardBreakTrailing",start:{_bufferIndex:a?s:r.start._bufferIndex+s,_index:r.start._index+a,line:r.end.line,column:r.end.column-o,offset:r.end.offset-o},end:{...r.end}};r.end={...c.start},r.start.offset===r.end.offset?Object.assign(r,c):(e.splice(n,0,["enter",c,t],["exit",c,t]),n+=2)}n++}return e}const g_=Object.freeze(Object.defineProperty({__proto__:null,attentionMarkers:{null:[42,95]},contentInitial:{91:Zb},disable:{null:[]},document:{42:Ge,43:Ge,45:Ge,48:Ge,49:Ge,50:Ge,51:Ge,52:Ge,53:Ge,54:Ge,55:Ge,56:Ge,57:Ge,62:jl},flow:{35:i2,42:si,45:[ec,si],60:u2,61:ec,95:si,96:Gl,126:Gl},flowInitial:{[-2]:Pa,[-1]:Pa,32:Pa},insideSpan:{null:[Da,f_]},string:{38:ql,92:Vl},text:{[-5]:Ba,[-4]:Ba,[-3]:Ba,33:C2,38:ql,42:Da,60:[Nb,m2],91:N2,92:[n2,Vl],93:Ma,95:Da,96:zb}},Symbol.toStringTag,{value:"Module"}));function b_(e,t,n){let r={_bufferIndex:-1,_index:0,line:n&&n.line||1,column:n&&n.column||1,offset:n&&n.offset||0};const i={},a=[];let s=[],o=[];const u={attempt:U(P),check:U(A),consume:S,enter:C,exit:D,interrupt:U(A,{interrupt:!0})},c={code:null,containerState:{},defineSkip:_,events:[],now:m,parser:e,previous:null,sliceSerialize:h,sliceStream:p,write:d};let f=t.tokenize.call(c,u);return t.resolveAll&&a.push(t),c;function d($){return s=nt(s,$),w(),s[s.length-1]!==null?[]:(I(t,0),c.events=ai(a,c.events,c),c.events)}function h($,B){return T_(p($),B)}function p($){return E_(s,$)}function m(){const{_bufferIndex:$,_index:B,line:W,column:ie,offset:K}=r;return{_bufferIndex:$,_index:B,line:W,column:ie,offset:K}}function _($){i[$.line]=$.column,N()}function w(){let $;for(;r._index<s.length;){const B=s[r._index];if(typeof B=="string")for($=r._index,r._bufferIndex<0&&(r._bufferIndex=0);r._index===$&&r._bufferIndex<B.length;)y(B.charCodeAt(r._bufferIndex));else y(B)}}function y($){f=f($)}function S($){G($)?(r.line++,r.column=1,r.offset+=$===-3?2:1,N()):$!==-1&&(r.column++,r.offset++),r._bufferIndex<0?r._index++:(r._bufferIndex++,r._bufferIndex===s[r._index].length&&(r._bufferIndex=-1,r._index++)),c.previous=$}function C($,B){const W=B||{};return W.type=$,W.start=m(),c.events.push(["enter",W,c]),o.push(W),W}function D($){const B=o.pop();return B.end=m(),c.events.push(["exit",B,c]),B}function P($,B){I($,B.from)}function A($,B){B.restore()}function U($,B){return W;function W(ie,K,de){let re,Se,Le,T;return Array.isArray(ie)?Z(ie):"tokenize"in ie?Z([ie]):Re(ie);function Re(ae){return rt;function rt(Je){const be=Je!==null&&ae[Je],lt=Je!==null&&ae.null,ct=[...Array.isArray(be)?be:be?[be]:[],...Array.isArray(lt)?lt:lt?[lt]:[]];return Z(ct)(Je)}}function Z(ae){return re=ae,Se=0,ae.length===0?de:x(ae[Se])}function x(ae){return rt;function rt(Je){return T=H(),Le=ae,ae.partial||(c.currentConstruct=ae),ae.name&&c.parser.constructs.disable.null.includes(ae.name)?he():ae.tokenize.call(B?Object.assign(Object.create(c),B):c,u,Ne,he)(Je)}}function Ne(ae){return $(Le,T),K}function he(ae){return T.restore(),++Se<re.length?x(re[Se]):de}}}function I($,B){$.resolveAll&&!a.includes($)&&a.push($),$.resolve&&Ke(c.events,B,c.events.length-B,$.resolve(c.events.slice(B),c)),$.resolveTo&&(c.events=$.resolveTo(c.events,c))}function H(){const $=m(),B=c.previous,W=c.currentConstruct,ie=c.events.length,K=Array.from(o);return{from:ie,restore:de};function de(){r=$,c.previous=B,c.currentConstruct=W,c.events.length=ie,o=K,N()}}function N(){r.line in i&&r.column<2&&(r.column=i[r.line],r.offset+=i[r.line]-1)}}function E_(e,t){const n=t.start._index,r=t.start._bufferIndex,i=t.end._index,a=t.end._bufferIndex;let s;if(n===i)s=[e[n].slice(r,a)];else{if(s=e.slice(n,i),r>-1){const o=s[0];typeof o=="string"?s[0]=o.slice(r):s.shift()}a>0&&s.push(e[i].slice(0,a))}return s}function T_(e,t){let n=-1;const r=[];let i;for(;++n<e.length;){const a=e[n];let s;if(typeof a=="string")s=a;else switch(a){case-5:{s="\r";break}case-4:{s=`
|
|
36
40
|
`;break}case-3:{s=`\r
|
|
37
|
-
`;break}case-2:{s=t?" ":" ";break}case-1:{if(!t&&i)continue;s=" ";break}default:s=String.fromCharCode(a)}i=a===-2,r.push(s)}return r.join("")}function zT(e){const r={constructs:Cl([BT,...(e||{}).extensions||[]]),content:i(CT),defined:[],document:i(IT),flow:i(LT),lazy:{},string:i(DT),text:i(PT)};return r;function i(a){return s;function s(o){return FT(r,a,o)}}}function $T(e){for(;!zl(e););return e}const zc=/[\0\t\n\r]/g;function YT(){let e=1,t="",n=!0,r;return i;function i(a,s,o){const u=[];let c,f,d,h,p;for(a=t+(typeof a=="string"?a.toString():new TextDecoder(s||void 0).decode(a)),d=0,t="",n&&(a.charCodeAt(0)===65279&&d++,n=void 0);d<a.length;){if(zc.lastIndex=d,c=zc.exec(a),h=c&&c.index!==void 0?c.index:a.length,p=a.charCodeAt(h),!c){t=a.slice(d);break}if(p===10&&d===h&&r)u.push(-3),r=void 0;else switch(r&&(u.push(-5),r=void 0),d<h&&(u.push(a.slice(d,h)),e+=h-d),p){case 0:{u.push(65533),e++;break}case 9:{for(f=Math.ceil(e/4)*4,u.push(-2);e++<f;)u.push(-1);break}case 10:{u.push(-4),e=1;break}default:r=!0,e=1}d=h+1}return o&&(r&&u.push(-5),t&&u.push(t),u.push(null)),u}}const $c={}.hasOwnProperty;function jT(e,t,n){return typeof t!="string"&&(n=t,t=void 0),VT(n)($T(zT(n).document().write(YT()(e,t,!0))))}function VT(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:a(ue),autolinkProtocol:H,autolinkEmail:H,atxHeading:a(pr),blockQuote:a(tt),characterEscape:H,characterReference:H,codeFenced:a(Et),codeFencedFenceInfo:s,codeFencedFenceMeta:s,codeIndented:a(Et,s),codeText:a(Ft,s),codeTextData:H,data:H,codeFlowValue:H,definition:a(_s),definitionDestinationString:s,definitionLabelString:s,definitionTitleString:s,emphasis:a(ks),hardBreakEscape:a(In),hardBreakTrailing:a(In),htmlFlow:a(xi,s),htmlFlowData:H,htmlText:a(xi,s),htmlTextData:H,image:a(yi),label:s,link:a(ue),listItem:a(Ht),listItemValue:h,listOrdered:a(De,d),listUnordered:a(De),paragraph:a(xs),reference:k,referenceString:s,resourceDestinationString:s,resourceTitleString:s,setextHeading:a(pr),strong:a(ys),thematicBreak:a(g6)},exit:{atxHeading:u(),atxHeadingSequence:P,autolink:u(),autolinkEmail:et,autolinkProtocol:Je,blockQuote:u(),characterEscapeValue:C,characterReferenceMarkerHexadecimal:je,characterReferenceMarkerNumeric:je,characterReferenceValue:ye,characterReference:Ee,codeFenced:u(A),codeFencedFence:_,codeFencedFenceInfo:p,codeFencedFenceMeta:m,codeFlowValue:C,codeIndented:u(y),codeText:u(X),codeTextData:C,data:C,definition:u(),definitionDestinationString:D,definitionLabelString:I,definitionTitleString:S,emphasis:u(),hardBreakEscape:u(B),hardBreakTrailing:u(B),htmlFlow:u(Q),htmlFlowData:C,htmlText:u(ae),htmlTextData:C,image:u(ee),label:Ye,labelText:q,lineEnding:$,link:u(Z),listItem:u(),listOrdered:u(),listUnordered:u(),paragraph:u(),referenceString:me,resourceDestinationString:x,resourceTitleString:Oe,resource:He,setextHeading:u(L),setextHeadingLineSequence:z,setextHeadingText:w,strong:u(),thematicBreak:u()}};Yc(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(R){let U={type:"root",children:[]};const J={stack:[U],tokenStack:[],config:t,enter:o,exit:c,buffer:s,resume:f,data:n},se=[];let ge=-1;for(;++ge<R.length;)if(R[ge][1].type==="listOrdered"||R[ge][1].type==="listUnordered")if(R[ge][0]==="enter")se.push(ge);else{const ct=se.pop();ge=i(R,ct,ge)}for(ge=-1;++ge<R.length;){const ct=t[R[ge][0]];$c.call(ct,R[ge][1].type)&&ct[R[ge][1].type].call(Object.assign({sliceSerialize:R[ge][2].sliceSerialize},J),R[ge][1])}if(J.tokenStack.length>0){const ct=J.tokenStack[J.tokenStack.length-1];(ct[1]||jc).call(J,void 0,ct[0])}for(U.position={start:Mt(R.length>0?R[0][1].start:{line:1,column:1,offset:0}),end:Mt(R.length>0?R[R.length-2][1].end:{line:1,column:1,offset:0})},ge=-1;++ge<t.transforms.length;)U=t.transforms[ge](U)||U;return U}function i(R,U,J){let se=U-1,ge=-1,ct=!1,rn,yt,mr,gr;for(;++se<=J;){const nt=R[se];switch(nt[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{nt[0]==="enter"?ge++:ge--,gr=void 0;break}case"lineEndingBlank":{nt[0]==="enter"&&(rn&&!gr&&!ge&&!mr&&(mr=se),gr=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:gr=void 0}if(!ge&&nt[0]==="enter"&&nt[1].type==="listItemPrefix"||ge===-1&&nt[0]==="exit"&&(nt[1].type==="listUnordered"||nt[1].type==="listOrdered")){if(rn){let Nn=se;for(yt=void 0;Nn--;){const wt=R[Nn];if(wt[1].type==="lineEnding"||wt[1].type==="lineEndingBlank"){if(wt[0]==="exit")continue;yt&&(R[yt][1].type="lineEndingBlank",ct=!0),wt[1].type="lineEnding",yt=Nn}else if(!(wt[1].type==="linePrefix"||wt[1].type==="blockQuotePrefix"||wt[1].type==="blockQuotePrefixWhitespace"||wt[1].type==="blockQuoteMarker"||wt[1].type==="listItemIndent"))break}mr&&(!yt||mr<yt)&&(rn._spread=!0),rn.end=Object.assign({},yt?R[yt][1].start:nt[1].end),R.splice(yt||se,0,["exit",rn,nt[2]]),se++,J++}if(nt[1].type==="listItemPrefix"){const Nn={type:"listItem",_spread:!1,start:Object.assign({},nt[1].start),end:void 0};rn=Nn,R.splice(se,0,["enter",Nn,nt[2]]),se++,J++,mr=void 0,gr=!0}}}return R[U][1]._spread=ct,J}function a(R,U){return J;function J(se){o.call(this,R(se),se),U&&U.call(this,se)}}function s(){this.stack.push({type:"fragment",children:[]})}function o(R,U,J){this.stack[this.stack.length-1].children.push(R),this.stack.push(R),this.tokenStack.push([U,J||void 0]),R.position={start:Mt(U.start),end:void 0}}function u(R){return U;function U(J){R&&R.call(this,J),c.call(this,J)}}function c(R,U){const J=this.stack.pop(),se=this.tokenStack.pop();if(se)se[0].type!==R.type&&(U?U.call(this,R,se[0]):(se[1]||jc).call(this,R,se[0]));else throw new Error("Cannot close `"+R.type+"` ("+ir({start:R.start,end:R.end})+"): it’s not open");J.position.end=Mt(R.end)}function f(){return _a(this.stack.pop())}function d(){this.data.expectingFirstListItemValue=!0}function h(R){if(this.data.expectingFirstListItemValue){const U=this.stack[this.stack.length-2];U.start=Number.parseInt(this.sliceSerialize(R),10),this.data.expectingFirstListItemValue=void 0}}function p(){const R=this.resume(),U=this.stack[this.stack.length-1];U.lang=R}function m(){const R=this.resume(),U=this.stack[this.stack.length-1];U.meta=R}function _(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function A(){const R=this.resume(),U=this.stack[this.stack.length-1];U.value=R.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function y(){const R=this.resume(),U=this.stack[this.stack.length-1];U.value=R.replace(/(\r?\n|\r)$/g,"")}function I(R){const U=this.resume(),J=this.stack[this.stack.length-1];J.label=U,J.identifier=ut(this.sliceSerialize(R)).toLowerCase()}function S(){const R=this.resume(),U=this.stack[this.stack.length-1];U.title=R}function D(){const R=this.resume(),U=this.stack[this.stack.length-1];U.url=R}function P(R){const U=this.stack[this.stack.length-1];if(!U.depth){const J=this.sliceSerialize(R).length;U.depth=J}}function w(){this.data.setextHeadingSlurpLineEnding=!0}function z(R){const U=this.stack[this.stack.length-1];U.depth=this.sliceSerialize(R).codePointAt(0)===61?1:2}function L(){this.data.setextHeadingSlurpLineEnding=void 0}function H(R){const J=this.stack[this.stack.length-1].children;let se=J[J.length-1];(!se||se.type!=="text")&&(se=m6(),se.position={start:Mt(R.start),end:void 0},J.push(se)),this.stack.push(se)}function C(R){const U=this.stack.pop();U.value+=this.sliceSerialize(R),U.position.end=Mt(R.end)}function $(R){const U=this.stack[this.stack.length-1];if(this.data.atHardBreak){const J=U.children[U.children.length-1];J.position.end=Mt(R.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(U.type)&&(H.call(this,R),C.call(this,R))}function B(){this.data.atHardBreak=!0}function Q(){const R=this.resume(),U=this.stack[this.stack.length-1];U.value=R}function ae(){const R=this.resume(),U=this.stack[this.stack.length-1];U.value=R}function X(){const R=this.resume(),U=this.stack[this.stack.length-1];U.value=R}function Z(){const R=this.stack[this.stack.length-1];if(this.data.inReference){const U=this.data.referenceType||"shortcut";R.type+="Reference",R.referenceType=U,delete R.url,delete R.title}else delete R.identifier,delete R.label;this.data.referenceType=void 0}function ee(){const R=this.stack[this.stack.length-1];if(this.data.inReference){const U=this.data.referenceType||"shortcut";R.type+="Reference",R.referenceType=U,delete R.url,delete R.title}else delete R.identifier,delete R.label;this.data.referenceType=void 0}function q(R){const U=this.sliceSerialize(R),J=this.stack[this.stack.length-2];J.label=wg(U),J.identifier=ut(U).toLowerCase()}function Ye(){const R=this.stack[this.stack.length-1],U=this.resume(),J=this.stack[this.stack.length-1];if(this.data.inReference=!0,J.type==="link"){const se=R.children;J.children=se}else J.alt=U}function x(){const R=this.resume(),U=this.stack[this.stack.length-1];U.url=R}function Oe(){const R=this.resume(),U=this.stack[this.stack.length-1];U.title=R}function He(){this.data.inReference=void 0}function k(){this.data.referenceType="collapsed"}function me(R){const U=this.resume(),J=this.stack[this.stack.length-1];J.label=U,J.identifier=ut(this.sliceSerialize(R)).toLowerCase(),this.data.referenceType="full"}function je(R){this.data.characterReferenceType=R.type}function ye(R){const U=this.sliceSerialize(R),J=this.data.characterReferenceType;let se;J?(se=xl(U,J==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):se=xa(U);const ge=this.stack[this.stack.length-1];ge.value+=se}function Ee(R){const U=this.stack.pop();U.position.end=Mt(R.end)}function Je(R){C.call(this,R);const U=this.stack[this.stack.length-1];U.url=this.sliceSerialize(R)}function et(R){C.call(this,R);const U=this.stack[this.stack.length-1];U.url="mailto:"+this.sliceSerialize(R)}function tt(){return{type:"blockquote",children:[]}}function Et(){return{type:"code",lang:null,meta:null,value:""}}function Ft(){return{type:"inlineCode",value:""}}function _s(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function ks(){return{type:"emphasis",children:[]}}function pr(){return{type:"heading",depth:0,children:[]}}function In(){return{type:"break"}}function xi(){return{type:"html",value:""}}function yi(){return{type:"image",title:null,url:"",alt:null}}function ue(){return{type:"link",title:null,url:"",children:[]}}function De(R){return{type:"list",ordered:R.type==="listOrdered",start:null,spread:R._spread,children:[]}}function Ht(R){return{type:"listItem",spread:R._spread,checked:null,children:[]}}function xs(){return{type:"paragraph",children:[]}}function ys(){return{type:"strong",children:[]}}function m6(){return{type:"text",value:""}}function g6(){return{type:"thematicBreak"}}}function Mt(e){return{line:e.line,column:e.column,offset:e.offset}}function Yc(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?Yc(e,r):qT(e,r)}}function qT(e,t){let n;for(n in t)if($c.call(t,n))switch(n){case"canContainEols":{const r=t[n];r&&e[n].push(...r);break}case"transforms":{const r=t[n];r&&e[n].push(...r);break}case"enter":case"exit":{const r=t[n];r&&Object.assign(e[n],r);break}}}function jc(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+ir({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+ir({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+ir({start:t.start,end:t.end})+") is still open")}function WT(e){const t=this;t.parser=n;function n(r){return jT(r,{...t.data("settings"),...e,extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]})}}function GT(e,t){const n={type:"element",tagName:"blockquote",properties:{},children:e.wrap(e.all(t),!0)};return e.patch(t,n),e.applyData(t,n)}function QT(e,t){const n={type:"element",tagName:"br",properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:"text",value:`
|
|
38
|
-
`}]}function
|
|
39
|
-
`:"",r={}
|
|
41
|
+
`;break}case-2:{s=t?" ":" ";break}case-1:{if(!t&&i)continue;s=" ";break}default:s=String.fromCharCode(a)}i=a===-2,r.push(s)}return r.join("")}function __(e){const r={constructs:Dl([g_,...(e||{}).extensions||[]]),content:i(a_),defined:[],document:i(o_),flow:i(c_),lazy:{},string:i(h_),text:i(p_)};return r;function i(a){return s;function s(o){return b_(r,a,o)}}}function k_(e){for(;!Ql(e););return e}const Jc=/[\0\t\n\r]/g;function x_(){let e=1,t="",n=!0,r;return i;function i(a,s,o){const u=[];let c,f,d,h,p;for(a=t+(typeof a=="string"?a.toString():new TextDecoder(s||void 0).decode(a)),d=0,t="",n&&(a.charCodeAt(0)===65279&&d++,n=void 0);d<a.length;){if(Jc.lastIndex=d,c=Jc.exec(a),h=c&&c.index!==void 0?c.index:a.length,p=a.charCodeAt(h),!c){t=a.slice(d);break}if(p===10&&d===h&&r)u.push(-3),r=void 0;else switch(r&&(u.push(-5),r=void 0),d<h&&(u.push(a.slice(d,h)),e+=h-d),p){case 0:{u.push(65533),e++;break}case 9:{for(f=Math.ceil(e/4)*4,u.push(-2);e++<f;)u.push(-1);break}case 10:{u.push(-4),e=1;break}default:r=!0,e=1}d=h+1}return o&&(r&&u.push(-5),t&&u.push(t),u.push(null)),u}}const ed={}.hasOwnProperty;function y_(e,t,n){return t&&typeof t=="object"&&(n=t,t=void 0),w_(n)(k_(__(n).document().write(x_()(e,t,!0))))}function w_(e){const t={transforms:[],canContainEols:["emphasis","fragment","heading","paragraph","strong"],enter:{autolink:a(ce),autolinkProtocol:H,autolinkEmail:H,atxHeading:a(yr),blockQuote:a(lt),characterEscape:H,characterReference:H,codeFenced:a(ct),codeFencedFenceInfo:s,codeFencedFenceMeta:s,codeIndented:a(ct,s),codeText:a($t,s),codeTextData:H,data:H,codeFlowValue:H,definition:a(dn),definitionDestinationString:s,definitionLabelString:s,definitionTitleString:s,emphasis:a(Yt),hardBreakEscape:a(Rn),hardBreakTrailing:a(Rn),htmlFlow:a(vi,s),htmlFlowData:H,htmlText:a(vi,s),htmlTextData:H,image:a(Li),label:s,link:a(ce),listItem:a(jt),listItemValue:h,listOrdered:a(Fe,d),listUnordered:a(Fe),paragraph:a(Ls),reference:x,referenceString:s,resourceDestinationString:s,resourceTitleString:s,setextHeading:a(yr),strong:a(Rs),thematicBreak:a(A6)},exit:{atxHeading:u(),atxHeadingSequence:P,autolink:u(),autolinkEmail:be,autolinkProtocol:Je,blockQuote:u(),characterEscapeValue:N,characterReferenceMarkerHexadecimal:he,characterReferenceMarkerNumeric:he,characterReferenceValue:ae,characterReference:rt,codeFenced:u(w),codeFencedFence:_,codeFencedFenceInfo:p,codeFencedFenceMeta:m,codeFlowValue:N,codeIndented:u(y),codeText:u(K),codeTextData:N,data:N,definition:u(),definitionDestinationString:D,definitionLabelString:S,definitionTitleString:C,emphasis:u(),hardBreakEscape:u(B),hardBreakTrailing:u(B),htmlFlow:u(W),htmlFlowData:N,htmlText:u(ie),htmlTextData:N,image:u(re),label:Le,labelText:Se,lineEnding:$,link:u(de),listItem:u(),listOrdered:u(),listUnordered:u(),paragraph:u(),referenceString:Ne,resourceDestinationString:T,resourceTitleString:Re,resource:Z,setextHeading:u(I),setextHeadingLineSequence:U,setextHeadingText:A,strong:u(),thematicBreak:u()}};td(t,(e||{}).mdastExtensions||[]);const n={};return r;function r(R){let z={type:"root",children:[]};const X={stack:[z],tokenStack:[],config:t,enter:o,exit:c,buffer:s,resume:f,data:n},se=[];let Ee=-1;for(;++Ee<R.length;)if(R[Ee][1].type==="listOrdered"||R[Ee][1].type==="listUnordered")if(R[Ee][0]==="enter")se.push(Ee);else{const dt=se.pop();Ee=i(R,dt,Ee)}for(Ee=-1;++Ee<R.length;){const dt=t[R[Ee][0]];ed.call(dt,R[Ee][1].type)&&dt[R[Ee][1].type].call(Object.assign({sliceSerialize:R[Ee][2].sliceSerialize},X),R[Ee][1])}if(X.tokenStack.length>0){const dt=X.tokenStack[X.tokenStack.length-1];(dt[1]||nd).call(X,void 0,dt[0])}for(z.position={start:Ut(R.length>0?R[0][1].start:{line:1,column:1,offset:0}),end:Ut(R.length>0?R[R.length-2][1].end:{line:1,column:1,offset:0})},Ee=-1;++Ee<t.transforms.length;)z=t.transforms[Ee](z)||z;return z}function i(R,z,X){let se=z-1,Ee=-1,dt=!1,fn,At,wr,Ar;for(;++se<=X;){const et=R[se];switch(et[1].type){case"listUnordered":case"listOrdered":case"blockQuote":{et[0]==="enter"?Ee++:Ee--,Ar=void 0;break}case"lineEndingBlank":{et[0]==="enter"&&(fn&&!Ar&&!Ee&&!wr&&(wr=se),Ar=void 0);break}case"linePrefix":case"listItemValue":case"listItemMarker":case"listItemPrefix":case"listItemPrefixWhitespace":break;default:Ar=void 0}if(!Ee&&et[0]==="enter"&&et[1].type==="listItemPrefix"||Ee===-1&&et[0]==="exit"&&(et[1].type==="listUnordered"||et[1].type==="listOrdered")){if(fn){let On=se;for(At=void 0;On--;){const Ct=R[On];if(Ct[1].type==="lineEnding"||Ct[1].type==="lineEndingBlank"){if(Ct[0]==="exit")continue;At&&(R[At][1].type="lineEndingBlank",dt=!0),Ct[1].type="lineEnding",At=On}else if(!(Ct[1].type==="linePrefix"||Ct[1].type==="blockQuotePrefix"||Ct[1].type==="blockQuotePrefixWhitespace"||Ct[1].type==="blockQuoteMarker"||Ct[1].type==="listItemIndent"))break}wr&&(!At||wr<At)&&(fn._spread=!0),fn.end=Object.assign({},At?R[At][1].start:et[1].end),R.splice(At||se,0,["exit",fn,et[2]]),se++,X++}if(et[1].type==="listItemPrefix"){const On={type:"listItem",_spread:!1,start:Object.assign({},et[1].start),end:void 0};fn=On,R.splice(se,0,["enter",On,et[2]]),se++,X++,wr=void 0,Ar=!0}}}return R[z][1]._spread=dt,X}function a(R,z){return X;function X(se){o.call(this,R(se),se),z&&z.call(this,se)}}function s(){this.stack.push({type:"fragment",children:[]})}function o(R,z,X){this.stack[this.stack.length-1].children.push(R),this.stack.push(R),this.tokenStack.push([z,X||void 0]),R.position={start:Ut(z.start),end:void 0}}function u(R){return z;function z(X){R&&R.call(this,X),c.call(this,X)}}function c(R,z){const X=this.stack.pop(),se=this.tokenStack.pop();if(se)se[0].type!==R.type&&(z?z.call(this,R,se[0]):(se[1]||nd).call(this,R,se[0]));else throw new Error("Cannot close `"+R.type+"` ("+pr({start:R.start,end:R.end})+"): it’s not open");X.position.end=Ut(R.end)}function f(){return Na(this.stack.pop())}function d(){this.data.expectingFirstListItemValue=!0}function h(R){if(this.data.expectingFirstListItemValue){const z=this.stack[this.stack.length-2];z.start=Number.parseInt(this.sliceSerialize(R),10),this.data.expectingFirstListItemValue=void 0}}function p(){const R=this.resume(),z=this.stack[this.stack.length-1];z.lang=R}function m(){const R=this.resume(),z=this.stack[this.stack.length-1];z.meta=R}function _(){this.data.flowCodeInside||(this.buffer(),this.data.flowCodeInside=!0)}function w(){const R=this.resume(),z=this.stack[this.stack.length-1];z.value=R.replace(/^(\r?\n|\r)|(\r?\n|\r)$/g,""),this.data.flowCodeInside=void 0}function y(){const R=this.resume(),z=this.stack[this.stack.length-1];z.value=R.replace(/(\r?\n|\r)$/g,"")}function S(R){const z=this.resume(),X=this.stack[this.stack.length-1];X.label=z,X.identifier=ot(this.sliceSerialize(R)).toLowerCase()}function C(){const R=this.resume(),z=this.stack[this.stack.length-1];z.title=R}function D(){const R=this.resume(),z=this.stack[this.stack.length-1];z.url=R}function P(R){const z=this.stack[this.stack.length-1];if(!z.depth){const X=this.sliceSerialize(R).length;z.depth=X}}function A(){this.data.setextHeadingSlurpLineEnding=!0}function U(R){const z=this.stack[this.stack.length-1];z.depth=this.sliceSerialize(R).codePointAt(0)===61?1:2}function I(){this.data.setextHeadingSlurpLineEnding=void 0}function H(R){const X=this.stack[this.stack.length-1].children;let se=X[X.length-1];(!se||se.type!=="text")&&(se=w6(),se.position={start:Ut(R.start),end:void 0},X.push(se)),this.stack.push(se)}function N(R){const z=this.stack.pop();z.value+=this.sliceSerialize(R),z.position.end=Ut(R.end)}function $(R){const z=this.stack[this.stack.length-1];if(this.data.atHardBreak){const X=z.children[z.children.length-1];X.position.end=Ut(R.end),this.data.atHardBreak=void 0;return}!this.data.setextHeadingSlurpLineEnding&&t.canContainEols.includes(z.type)&&(H.call(this,R),N.call(this,R))}function B(){this.data.atHardBreak=!0}function W(){const R=this.resume(),z=this.stack[this.stack.length-1];z.value=R}function ie(){const R=this.resume(),z=this.stack[this.stack.length-1];z.value=R}function K(){const R=this.resume(),z=this.stack[this.stack.length-1];z.value=R}function de(){const R=this.stack[this.stack.length-1];if(this.data.inReference){const z=this.data.referenceType||"shortcut";R.type+="Reference",R.referenceType=z,delete R.url,delete R.title}else delete R.identifier,delete R.label;this.data.referenceType=void 0}function re(){const R=this.stack[this.stack.length-1];if(this.data.inReference){const z=this.data.referenceType||"shortcut";R.type+="Reference",R.referenceType=z,delete R.url,delete R.title}else delete R.identifier,delete R.label;this.data.referenceType=void 0}function Se(R){const z=this.sliceSerialize(R),X=this.stack[this.stack.length-2];X.label=Zg(z),X.identifier=ot(z).toLowerCase()}function Le(){const R=this.stack[this.stack.length-1],z=this.resume(),X=this.stack[this.stack.length-1];if(this.data.inReference=!0,X.type==="link"){const se=R.children;X.children=se}else X.alt=z}function T(){const R=this.resume(),z=this.stack[this.stack.length-1];z.url=R}function Re(){const R=this.resume(),z=this.stack[this.stack.length-1];z.title=R}function Z(){this.data.inReference=void 0}function x(){this.data.referenceType="collapsed"}function Ne(R){const z=this.resume(),X=this.stack[this.stack.length-1];X.label=z,X.identifier=ot(this.sliceSerialize(R)).toLowerCase(),this.data.referenceType="full"}function he(R){this.data.characterReferenceType=R.type}function ae(R){const z=this.sliceSerialize(R),X=this.data.characterReferenceType;let se;X?(se=vl(z,X==="characterReferenceMarkerNumeric"?10:16),this.data.characterReferenceType=void 0):se=va(z);const Ee=this.stack[this.stack.length-1];Ee.value+=se}function rt(R){const z=this.stack.pop();z.position.end=Ut(R.end)}function Je(R){N.call(this,R);const z=this.stack[this.stack.length-1];z.url=this.sliceSerialize(R)}function be(R){N.call(this,R);const z=this.stack[this.stack.length-1];z.url="mailto:"+this.sliceSerialize(R)}function lt(){return{type:"blockquote",children:[]}}function ct(){return{type:"code",lang:null,meta:null,value:""}}function $t(){return{type:"inlineCode",value:""}}function dn(){return{type:"definition",identifier:"",label:null,title:null,url:""}}function Yt(){return{type:"emphasis",children:[]}}function yr(){return{type:"heading",depth:0,children:[]}}function Rn(){return{type:"break"}}function vi(){return{type:"html",value:""}}function Li(){return{type:"image",title:null,url:"",alt:null}}function ce(){return{type:"link",title:null,url:"",children:[]}}function Fe(R){return{type:"list",ordered:R.type==="listOrdered",start:null,spread:R._spread,children:[]}}function jt(R){return{type:"listItem",spread:R._spread,checked:null,children:[]}}function Ls(){return{type:"paragraph",children:[]}}function Rs(){return{type:"strong",children:[]}}function w6(){return{type:"text",value:""}}function A6(){return{type:"thematicBreak"}}}function Ut(e){return{line:e.line,column:e.column,offset:e.offset}}function td(e,t){let n=-1;for(;++n<t.length;){const r=t[n];Array.isArray(r)?td(e,r):A_(e,r)}}function A_(e,t){let n;for(n in t)if(ed.call(t,n))switch(n){case"canContainEols":{const r=t[n];r&&e[n].push(...r);break}case"transforms":{const r=t[n];r&&e[n].push(...r);break}case"enter":case"exit":{const r=t[n];r&&Object.assign(e[n],r);break}}}function nd(e,t){throw e?new Error("Cannot close `"+e.type+"` ("+pr({start:e.start,end:e.end})+"): a different token (`"+t.type+"`, "+pr({start:t.start,end:t.end})+") is open"):new Error("Cannot close document, a token (`"+t.type+"`, "+pr({start:t.start,end:t.end})+") is still open")}function C_(e){const t=this;t.parser=n;function n(r){return y_(r,{...t.data("settings"),...e,extensions:t.data("micromarkExtensions")||[],mdastExtensions:t.data("fromMarkdownExtensions")||[]})}}function S_(e,t){const n={type:"element",tagName:"blockquote",properties:{},children:e.wrap(e.all(t),!0)};return e.patch(t,n),e.applyData(t,n)}function N_(e,t){const n={type:"element",tagName:"br",properties:{},children:[]};return e.patch(t,n),[e.applyData(t,n),{type:"text",value:`
|
|
42
|
+
`}]}function I_(e,t){const n=t.value?t.value+`
|
|
43
|
+
`:"",r={},i=t.lang?t.lang.split(/\s+/):[];i.length>0&&(r.className=["language-"+i[0]]);let a={type:"element",tagName:"code",properties:r,children:[{type:"text",value:n}]};return t.meta&&(a.data={meta:t.meta}),e.patch(t,a),a=e.applyData(t,a),a={type:"element",tagName:"pre",properties:{},children:[a]},e.patch(t,a),a}function v_(e,t){const n={type:"element",tagName:"del",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function L_(e,t){const n={type:"element",tagName:"em",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function R_(e,t){const n=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",r=String(t.identifier).toUpperCase(),i=Nn(r.toLowerCase()),a=e.footnoteOrder.indexOf(r);let s,o=e.footnoteCounts.get(r);o===void 0?(o=0,e.footnoteOrder.push(r),s=e.footnoteOrder.length):s=a+1,o+=1,e.footnoteCounts.set(r,o);const u={type:"element",tagName:"a",properties:{href:"#"+n+"fn-"+i,id:n+"fnref-"+i+(o>1?"-"+o:""),dataFootnoteRef:!0,ariaDescribedBy:["footnote-label"]},children:[{type:"text",value:String(s)}]};e.patch(t,u);const c={type:"element",tagName:"sup",properties:{},children:[u]};return e.patch(t,c),e.applyData(t,c)}function O_(e,t){const n={type:"element",tagName:"h"+t.depth,properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function D_(e,t){if(e.options.allowDangerousHtml){const n={type:"raw",value:t.value};return e.patch(t,n),e.applyData(t,n)}}function rd(e,t){const n=t.referenceType;let r="]";if(n==="collapsed"?r+="[]":n==="full"&&(r+="["+(t.label||t.identifier)+"]"),t.type==="imageReference")return[{type:"text",value:"!["+t.alt+r}];const i=e.all(t),a=i[0];a&&a.type==="text"?a.value="["+a.value:i.unshift({type:"text",value:"["});const s=i[i.length-1];return s&&s.type==="text"?s.value+=r:i.push({type:"text",value:r}),i}function P_(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return rd(e,t);const i={src:Nn(r.url||""),alt:t.alt};r.title!==null&&r.title!==void 0&&(i.title=r.title);const a={type:"element",tagName:"img",properties:i,children:[]};return e.patch(t,a),e.applyData(t,a)}function M_(e,t){const n={src:Nn(t.url)};t.alt!==null&&t.alt!==void 0&&(n.alt=t.alt),t.title!==null&&t.title!==void 0&&(n.title=t.title);const r={type:"element",tagName:"img",properties:n,children:[]};return e.patch(t,r),e.applyData(t,r)}function B_(e,t){const n={type:"text",value:t.value.replace(/\r?\n|\r/g," ")};e.patch(t,n);const r={type:"element",tagName:"code",properties:{},children:[n]};return e.patch(t,r),e.applyData(t,r)}function F_(e,t){const n=String(t.identifier).toUpperCase(),r=e.definitionById.get(n);if(!r)return rd(e,t);const i={href:Nn(r.url||"")};r.title!==null&&r.title!==void 0&&(i.title=r.title);const a={type:"element",tagName:"a",properties:i,children:e.all(t)};return e.patch(t,a),e.applyData(t,a)}function H_(e,t){const n={href:Nn(t.url)};t.title!==null&&t.title!==void 0&&(n.title=t.title);const r={type:"element",tagName:"a",properties:n,children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function U_(e,t,n){const r=e.all(t),i=n?z_(n):id(t),a={},s=[];if(typeof t.checked=="boolean"){const f=r[0];let d;f&&f.type==="element"&&f.tagName==="p"?d=f:(d={type:"element",tagName:"p",properties:{},children:[]},r.unshift(d)),d.children.length>0&&d.children.unshift({type:"text",value:" "}),d.children.unshift({type:"element",tagName:"input",properties:{type:"checkbox",checked:t.checked,disabled:!0},children:[]}),a.className=["task-list-item"]}let o=-1;for(;++o<r.length;){const f=r[o];(i||o!==0||f.type!=="element"||f.tagName!=="p")&&s.push({type:"text",value:`
|
|
40
44
|
`}),f.type==="element"&&f.tagName==="p"&&!i?s.push(...f.children):s.push(f)}const u=r[r.length-1];u&&(i||u.type!=="element"||u.tagName!=="p")&&s.push({type:"text",value:`
|
|
41
|
-
`});const c={type:"element",tagName:"li",properties:a,children:s};return e.patch(t,c),e.applyData(t,c)}function
|
|
45
|
+
`});const c={type:"element",tagName:"li",properties:a,children:s};return e.patch(t,c),e.applyData(t,c)}function z_(e){let t=!1;if(e.type==="list"){t=e.spread||!1;const n=e.children;let r=-1;for(;!t&&++r<n.length;)t=id(n[r])}return t}function id(e){const t=e.spread;return t??e.children.length>1}function $_(e,t){const n={},r=e.all(t);let i=-1;for(typeof t.start=="number"&&t.start!==1&&(n.start=t.start);++i<r.length;){const s=r[i];if(s.type==="element"&&s.tagName==="li"&&s.properties&&Array.isArray(s.properties.className)&&s.properties.className.includes("task-list-item")){n.className=["contains-task-list"];break}}const a={type:"element",tagName:t.ordered?"ol":"ul",properties:n,children:e.wrap(r,!0)};return e.patch(t,a),e.applyData(t,a)}function Y_(e,t){const n={type:"element",tagName:"p",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function j_(e,t){const n={type:"root",children:e.wrap(e.all(t))};return e.patch(t,n),e.applyData(t,n)}function V_(e,t){const n={type:"element",tagName:"strong",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}function q_(e,t){const n=e.all(t),r=n.shift(),i=[];if(r){const s={type:"element",tagName:"thead",properties:{},children:e.wrap([r],!0)};e.patch(t.children[0],s),i.push(s)}if(n.length>0){const s={type:"element",tagName:"tbody",properties:{},children:e.wrap(n,!0)},o=gt(t.children[1]),u=ti(t.children[t.children.length-1]);o&&u&&(s.position={start:o,end:u}),i.push(s)}const a={type:"element",tagName:"table",properties:{},children:e.wrap(i,!0)};return e.patch(t,a),e.applyData(t,a)}function W_(e,t,n){const r=n?n.children:void 0,a=(r?r.indexOf(t):1)===0?"th":"td",s=n&&n.type==="table"?n.align:void 0,o=s?s.length:t.children.length;let u=-1;const c=[];for(;++u<o;){const d=t.children[u],h={},p=s?s[u]:void 0;p&&(h.align=p);let m={type:"element",tagName:a,properties:h,children:[]};d&&(m.children=e.all(d),e.patch(d,m),m=e.applyData(d,m)),c.push(m)}const f={type:"element",tagName:"tr",properties:{},children:e.wrap(c,!0)};return e.patch(t,f),e.applyData(t,f)}function G_(e,t){const n={type:"element",tagName:"td",properties:{},children:e.all(t)};return e.patch(t,n),e.applyData(t,n)}const ad=9,sd=32;function Q_(e){const t=String(e),n=/\r?\n|\r/g;let r=n.exec(t),i=0;const a=[];for(;r;)a.push(od(t.slice(i,r.index),i>0,!0),r[0]),i=r.index+r[0].length,r=n.exec(t);return a.push(od(t.slice(i),i>0,!1)),a.join("")}function od(e,t,n){let r=0,i=e.length;if(t){let a=e.codePointAt(r);for(;a===ad||a===sd;)r++,a=e.codePointAt(r)}if(n){let a=e.codePointAt(i-1);for(;a===ad||a===sd;)i--,a=e.codePointAt(i-1)}return i>r?e.slice(r,i):""}function K_(e,t){const n={type:"text",value:Q_(String(t.value))};return e.patch(t,n),e.applyData(t,n)}function X_(e,t){const n={type:"element",tagName:"hr",properties:{},children:[]};return e.patch(t,n),e.applyData(t,n)}const Z_={blockquote:S_,break:N_,code:I_,delete:v_,emphasis:L_,footnoteReference:R_,heading:O_,html:D_,imageReference:P_,image:M_,inlineCode:B_,linkReference:F_,link:H_,listItem:U_,list:$_,paragraph:Y_,root:j_,strong:V_,table:q_,tableCell:G_,tableRow:W_,text:K_,thematicBreak:X_,toml:pi,yaml:pi,definition:pi,footnoteDefinition:pi};function pi(){}function J_(e,t){const n=[{type:"text",value:"↩"}];return t>1&&n.push({type:"element",tagName:"sup",properties:{},children:[{type:"text",value:String(t)}]}),n}function ek(e,t){return"Back to reference "+(e+1)+(t>1?"-"+t:"")}function tk(e){const t=typeof e.options.clobberPrefix=="string"?e.options.clobberPrefix:"user-content-",n=e.options.footnoteBackContent||J_,r=e.options.footnoteBackLabel||ek,i=e.options.footnoteLabel||"Footnotes",a=e.options.footnoteLabelTagName||"h2",s=e.options.footnoteLabelProperties||{className:["sr-only"]},o=[];let u=-1;for(;++u<e.footnoteOrder.length;){const c=e.footnoteById.get(e.footnoteOrder[u]);if(!c)continue;const f=e.all(c),d=String(c.identifier).toUpperCase(),h=Nn(d.toLowerCase());let p=0;const m=[],_=e.footnoteCounts.get(d);for(;_!==void 0&&++p<=_;){m.length>0&&m.push({type:"text",value:" "});let S=typeof n=="string"?n:n(u,p);typeof S=="string"&&(S={type:"text",value:S}),m.push({type:"element",tagName:"a",properties:{href:"#"+t+"fnref-"+h+(p>1?"-"+p:""),dataFootnoteBackref:"",ariaLabel:typeof r=="string"?r:r(u,p),className:["data-footnote-backref"]},children:Array.isArray(S)?S:[S]})}const w=f[f.length-1];if(w&&w.type==="element"&&w.tagName==="p"){const S=w.children[w.children.length-1];S&&S.type==="text"?S.value+=" ":w.children.push({type:"text",value:" "}),w.children.push(...m)}else f.push(...m);const y={type:"element",tagName:"li",properties:{id:t+"fn-"+h},children:e.wrap(f,!0)};e.patch(c,y),o.push(y)}if(o.length!==0)return{type:"element",tagName:"section",properties:{dataFootnotes:!0,className:["footnotes"]},children:[{type:"element",tagName:a,properties:{...Qt(s),id:"footnote-label"},children:[{type:"text",value:i}]},{type:"text",value:`
|
|
42
46
|
`},{type:"element",tagName:"ol",properties:{},children:e.wrap(o,!0)},{type:"text",value:`
|
|
43
|
-
`}]}}const
|
|
47
|
+
`}]}}const Za={}.hasOwnProperty,nk={};function rk(e,t){const n=t||nk,r=new Map,i=new Map,a=new Map,s={...Z_,...n.handlers},o={all:c,applyData:ak,definitionById:r,footnoteById:i,footnoteCounts:a,footnoteOrder:[],handlers:s,one:u,options:n,patch:ik,wrap:ok};return It(e,function(f){if(f.type==="definition"||f.type==="footnoteDefinition"){const d=f.type==="definition"?r:i,h=String(f.identifier).toUpperCase();d.has(h)||d.set(h,f)}}),o;function u(f,d){const h=f.type,p=o.handlers[h];if(Za.call(o.handlers,h)&&p)return p(o,f,d);if(o.options.passThrough&&o.options.passThrough.includes(h)){if("children"in f){const{children:_,...w}=f,y=Qt(w);return y.children=o.all(f),y}return Qt(f)}return(o.options.unknownHandler||sk)(o,f,d)}function c(f){const d=[];if("children"in f){const h=f.children;let p=-1;for(;++p<h.length;){const m=o.one(h[p],f);if(m){if(p&&h[p-1].type==="break"&&(!Array.isArray(m)&&m.type==="text"&&(m.value=ud(m.value)),!Array.isArray(m)&&m.type==="element")){const _=m.children[0];_&&_.type==="text"&&(_.value=ud(_.value))}Array.isArray(m)?d.push(...m):d.push(m)}}}return d}}function ik(e,t){e.position&&(t.position=Ku(e))}function ak(e,t){let n=t;if(e&&e.data){const r=e.data.hName,i=e.data.hChildren,a=e.data.hProperties;if(typeof r=="string")if(n.type==="element")n.tagName=r;else{const s="children"in n?n.children:[n];n={type:"element",tagName:r,properties:{},children:s}}n.type==="element"&&a&&Object.assign(n.properties,Qt(a)),"children"in n&&n.children&&i!==null&&i!==void 0&&(n.children=i)}return n}function sk(e,t){const n=t.data||{},r="value"in t&&!(Za.call(n,"hProperties")||Za.call(n,"hChildren"))?{type:"text",value:t.value}:{type:"element",tagName:"div",properties:{},children:e.all(t)};return e.patch(t,r),e.applyData(t,r)}function ok(e,t){const n=[];let r=-1;for(t&&n.push({type:"text",value:`
|
|
44
48
|
`});++r<e.length;)r&&n.push({type:"text",value:`
|
|
45
49
|
`}),n.push(e[r]);return t&&e.length>0&&n.push({type:"text",value:`
|
|
46
|
-
`}),n}function
|
|
47
|
-
`},i),a}function N_(e,t){return e&&"run"in e?async function(n,r){const i=Xc(n,{file:r,...t});await e.run(i,r)}:function(n,r){return Xc(n,{file:r,...e||t})}}function Zc(e){if(e)throw e}var ui=Object.prototype.hasOwnProperty,Jc=Object.prototype.toString,ed=Object.defineProperty,td=Object.getOwnPropertyDescriptor,nd=function(t){return typeof Array.isArray=="function"?Array.isArray(t):Jc.call(t)==="[object Array]"},rd=function(t){if(!t||Jc.call(t)!=="[object Object]")return!1;var n=ui.call(t,"constructor"),r=t.constructor&&t.constructor.prototype&&ui.call(t.constructor.prototype,"isPrototypeOf");if(t.constructor&&!n&&!r)return!1;var i;for(i in t);return typeof i>"u"||ui.call(t,i)},id=function(t,n){ed&&n.name==="__proto__"?ed(t,n.name,{enumerable:!0,configurable:!0,value:n.newValue,writable:!0}):t[n.name]=n.newValue},ad=function(t,n){if(n==="__proto__")if(ui.call(t,n)){if(td)return td(t,n).value}else return;return t[n]},v_=function e(){var t,n,r,i,a,s,o=arguments[0],u=1,c=arguments.length,f=!1;for(typeof o=="boolean"&&(f=o,o=arguments[1]||{},u=2),(o==null||typeof o!="object"&&typeof o!="function")&&(o={});u<c;++u)if(t=arguments[u],t!=null)for(n in t)r=ad(o,n),i=ad(t,n),o!==i&&(f&&i&&(rd(i)||(a=nd(i)))?(a?(a=!1,s=r&&nd(r)?r:[]):s=r&&rd(r)?r:{},id(o,{name:n,newValue:e(f,s,i)})):typeof i<"u"&&id(o,{name:n,newValue:i}));return o};const Ya=Cc(v_);function ja(e){if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function L_(){const e=[],t={run:n,use:r};return t;function n(...i){let a=-1;const s=i.pop();if(typeof s!="function")throw new TypeError("Expected function as last argument, not "+s);o(null,...i);function o(u,...c){const f=e[++a];let d=-1;if(u){s(u);return}for(;++d<i.length;)(c[d]===null||c[d]===void 0)&&(c[d]=i[d]);i=c,f?R_(f,o)(...c):s(null,...c)}}function r(i){if(typeof i!="function")throw new TypeError("Expected `middelware` to be a function, not "+i);return e.push(i),t}}function R_(e,t){let n;return r;function r(...s){const o=e.length>s.length;let u;o&&s.push(i);try{u=e.apply(this,s)}catch(c){const f=c;if(o&&n)throw f;return i(f)}o||(u&&u.then&&typeof u.then=="function"?u.then(a,i):u instanceof Error?i(u):a(u))}function i(s,...o){n||(n=!0,t(s,...o))}function a(s){i(null,s)}}const gt={basename:O_,dirname:D_,extname:P_,join:M_,sep:"/"};function O_(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');sr(e);let n=0,r=-1,i=e.length,a;if(t===void 0||t.length===0||t.length>e.length){for(;i--;)if(e.codePointAt(i)===47){if(a){n=i+1;break}}else r<0&&(a=!0,r=i+1);return r<0?"":e.slice(n,r)}if(t===e)return"";let s=-1,o=t.length-1;for(;i--;)if(e.codePointAt(i)===47){if(a){n=i+1;break}}else s<0&&(a=!0,s=i+1),o>-1&&(e.codePointAt(i)===t.codePointAt(o--)?o<0&&(r=i):(o=-1,r=s));return n===r?r=s:r<0&&(r=e.length),e.slice(n,r)}function D_(e){if(sr(e),e.length===0)return".";let t=-1,n=e.length,r;for(;--n;)if(e.codePointAt(n)===47){if(r){t=n;break}}else r||(r=!0);return t<0?e.codePointAt(0)===47?"/":".":t===1&&e.codePointAt(0)===47?"//":e.slice(0,t)}function P_(e){sr(e);let t=e.length,n=-1,r=0,i=-1,a=0,s;for(;t--;){const o=e.codePointAt(t);if(o===47){if(s){r=t+1;break}continue}n<0&&(s=!0,n=t+1),o===46?i<0?i=t:a!==1&&(a=1):i>-1&&(a=-1)}return i<0||n<0||a===0||a===1&&i===n-1&&i===r+1?"":e.slice(i,n)}function M_(...e){let t=-1,n;for(;++t<e.length;)sr(e[t]),e[t]&&(n=n===void 0?e[t]:n+"/"+e[t]);return n===void 0?".":B_(n)}function B_(e){sr(e);const t=e.codePointAt(0)===47;let n=F_(e,!t);return n.length===0&&!t&&(n="."),n.length>0&&e.codePointAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function F_(e,t){let n="",r=0,i=-1,a=0,s=-1,o,u;for(;++s<=e.length;){if(s<e.length)o=e.codePointAt(s);else{if(o===47)break;o=47}if(o===47){if(!(i===s-1||a===1))if(i!==s-1&&a===2){if(n.length<2||r!==2||n.codePointAt(n.length-1)!==46||n.codePointAt(n.length-2)!==46){if(n.length>2){if(u=n.lastIndexOf("/"),u!==n.length-1){u<0?(n="",r=0):(n=n.slice(0,u),r=n.length-1-n.lastIndexOf("/")),i=s,a=0;continue}}else if(n.length>0){n="",r=0,i=s,a=0;continue}}t&&(n=n.length>0?n+"/..":"..",r=2)}else n.length>0?n+="/"+e.slice(i+1,s):n=e.slice(i+1,s),r=s-i-1;i=s,a=0}else o===46&&a>-1?a++:a=-1}return n}function sr(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const H_={cwd:U_};function U_(){return"/"}function Va(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function z_(e){if(typeof e=="string")e=new URL(e);else if(!Va(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return $_(e)}function $_(e){if(e.hostname!==""){const r=new TypeError('File URL host must be "localhost" or empty on darwin');throw r.code="ERR_INVALID_FILE_URL_HOST",r}const t=e.pathname;let n=-1;for(;++n<t.length;)if(t.codePointAt(n)===37&&t.codePointAt(n+1)===50){const r=t.codePointAt(n+2);if(r===70||r===102){const i=new TypeError("File URL path must not include encoded / characters");throw i.code="ERR_INVALID_FILE_URL_PATH",i}}return decodeURIComponent(t)}const qa=["history","path","basename","stem","extname","dirname"];class Y_{constructor(t){let n;t?Va(t)?n={path:t}:typeof t=="string"||j_(t)?n={value:t}:n=t:n={},this.cwd="cwd"in n?"":H_.cwd(),this.data={},this.history=[],this.messages=[];let r=-1;for(;++r<qa.length;){const a=qa[r];a in n&&n[a]!==void 0&&n[a]!==null&&(this[a]=a==="history"?[...n[a]]:n[a])}let i;for(i in n)qa.includes(i)||(this[i]=n[i])}get basename(){return typeof this.path=="string"?gt.basename(this.path):void 0}set basename(t){Ga(t,"basename"),Wa(t,"basename"),this.path=gt.join(this.dirname||"",t)}get dirname(){return typeof this.path=="string"?gt.dirname(this.path):void 0}set dirname(t){sd(this.basename,"dirname"),this.path=gt.join(t||"",this.basename)}get extname(){return typeof this.path=="string"?gt.extname(this.path):void 0}set extname(t){if(Wa(t,"extname"),sd(this.dirname,"extname"),t){if(t.codePointAt(0)!==46)throw new Error("`extname` must start with `.`");if(t.includes(".",1))throw new Error("`extname` cannot contain multiple dots")}this.path=gt.join(this.dirname,this.stem+(t||""))}get path(){return this.history[this.history.length-1]}set path(t){Va(t)&&(t=z_(t)),Ga(t,"path"),this.path!==t&&this.history.push(t)}get stem(){return typeof this.path=="string"?gt.basename(this.path,this.extname):void 0}set stem(t){Ga(t,"stem"),Wa(t,"stem"),this.path=gt.join(this.dirname||"",t+(this.extname||""))}fail(t,n,r){const i=this.message(t,n,r);throw i.fatal=!0,i}info(t,n,r){const i=this.message(t,n,r);return i.fatal=void 0,i}message(t,n,r){const i=new Fe(t,n,r);return this.path&&(i.name=this.path+":"+i.name,i.file=this.path),i.fatal=!1,this.messages.push(i),i}toString(t){return this.value===void 0?"":typeof this.value=="string"?this.value:new TextDecoder(t||void 0).decode(this.value)}}function Wa(e,t){if(e&&e.includes(gt.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+gt.sep+"`")}function Ga(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function sd(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function j_(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const V_=function(e){const r=this.constructor.prototype,i=r[e],a=function(){return i.apply(a,arguments)};return Object.setPrototypeOf(a,r),a},q_={}.hasOwnProperty;class Qa extends V_{constructor(){super("copy"),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=L_()}copy(){const t=new Qa;let n=-1;for(;++n<this.attachers.length;){const r=this.attachers[n];t.use(...r)}return t.data(Ya(!0,{},this.namespace)),t}data(t,n){return typeof t=="string"?arguments.length===2?(Za("data",this.frozen),this.namespace[t]=n,this):q_.call(this.namespace,t)&&this.namespace[t]||void 0:t?(Za("data",this.frozen),this.namespace=t,this):this.namespace}freeze(){if(this.frozen)return this;const t=this;for(;++this.freezeIndex<this.attachers.length;){const[n,...r]=this.attachers[this.freezeIndex];if(r[0]===!1)continue;r[0]===!0&&(r[0]=void 0);const i=n.call(t,...r);typeof i=="function"&&this.transformers.use(i)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(t){this.freeze();const n=li(t),r=this.parser||this.Parser;return Ka("parse",r),r(String(n),n)}process(t,n){const r=this;return this.freeze(),Ka("process",this.parser||this.Parser),Xa("process",this.compiler||this.Compiler),n?i(void 0,n):new Promise(i);function i(a,s){const o=li(t),u=r.parse(o);r.run(u,o,function(f,d,h){if(f||!d||!h)return c(f);const p=d,m=r.stringify(p,h);Q_(m)?h.value=m:h.result=m,c(f,h)});function c(f,d){f||!d?s(f):a?a(d):n(void 0,d)}}}processSync(t){let n=!1,r;return this.freeze(),Ka("processSync",this.parser||this.Parser),Xa("processSync",this.compiler||this.Compiler),this.process(t,i),ud("processSync","process",n),r;function i(a,s){n=!0,Zc(a),r=s}}run(t,n,r){od(t),this.freeze();const i=this.transformers;return!r&&typeof n=="function"&&(r=n,n=void 0),r?a(void 0,r):new Promise(a);function a(s,o){const u=li(n);i.run(t,u,c);function c(f,d,h){const p=d||t;f?o(f):s?s(p):r(void 0,p,h)}}}runSync(t,n){let r=!1,i;return this.run(t,n,a),ud("runSync","run",r),i;function a(s,o){Zc(s),i=o,r=!0}}stringify(t,n){this.freeze();const r=li(n),i=this.compiler||this.Compiler;return Xa("stringify",i),od(t),i(t,r)}use(t,...n){const r=this.attachers,i=this.namespace;if(Za("use",this.frozen),t!=null)if(typeof t=="function")u(t,n);else if(typeof t=="object")Array.isArray(t)?o(t):s(t);else throw new TypeError("Expected usable value, not `"+t+"`");return this;function a(c){if(typeof c=="function")u(c,[]);else if(typeof c=="object")if(Array.isArray(c)){const[f,...d]=c;u(f,d)}else s(c);else throw new TypeError("Expected usable value, not `"+c+"`")}function s(c){if(!("plugins"in c)&&!("settings"in c))throw new Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");o(c.plugins),c.settings&&(i.settings=Ya(!0,i.settings,c.settings))}function o(c){let f=-1;if(c!=null)if(Array.isArray(c))for(;++f<c.length;){const d=c[f];a(d)}else throw new TypeError("Expected a list of plugins, not `"+c+"`")}function u(c,f){let d=-1,h=-1;for(;++d<r.length;)if(r[d][0]===c){h=d;break}if(h===-1)r.push([c,...f]);else if(f.length>0){let[p,...m]=f;const _=r[h][1];ja(_)&&ja(p)&&(p=Ya(!0,_,p)),r[h]=[c,p,...m]}}}}const W_=new Qa().freeze();function Ka(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function Xa(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function Za(e,t){if(t)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function od(e){if(!ja(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function ud(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function li(e){return G_(e)?e:new Y_(e)}function G_(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function Q_(e){return typeof e=="string"||K_(e)}function K_(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}function Ja(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var tn=Ja();function ld(e){tn=e}var or={exec:()=>null};function ce(e,t=""){let n=typeof e=="string"?e:e.source,r={replace:(i,a)=>{let s=typeof a=="string"?a:a.source;return s=s.replace($e.caret,"$1"),n=n.replace(i,s),r},getRegex:()=>new RegExp(n,t)};return r}var X_=(()=>{try{return!!new RegExp("(?<=1)(?<!1)")}catch{return!1}})(),$e={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceTabs:/^\t+/,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] +\S/,listReplaceTask:/^\[[ xX]\] +/,listTaskCheckbox:/\[[ xX]\]/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:e=>new RegExp(`^( {0,3}${e})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),hrRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}#`),htmlBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}<(?:[a-z].*>|!--)`,"i")},Z_=/^(?:[ \t]*(?:\n|$))+/,J_=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,ek=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,ur=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,tk=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,es=/(?:[*+-]|\d{1,9}[.)])/,cd=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,dd=ce(cd).replace(/bull/g,es).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),nk=ce(cd).replace(/bull/g,es).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),ts=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,rk=/^[^\n]+/,ns=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,ik=ce(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",ns).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),ak=ce(/^( {0,3}bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,es).getRegex(),ci="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|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",rs=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,sk=ce("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))","i").replace("comment",rs).replace("tag",ci).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),fd=ce(ts).replace("hr",ur).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",ci).getRegex(),ok=ce(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",fd).getRegex(),is={blockquote:ok,code:J_,def:ik,fences:ek,heading:tk,hr:ur,html:sk,lheading:dd,list:ak,newline:Z_,paragraph:fd,table:or,text:rk},hd=ce("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",ur).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3} )[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",ci).getRegex(),uk={...is,lheading:nk,table:hd,paragraph:ce(ts).replace("hr",ur).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",hd).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)]) ").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",ci).getRegex()},lk={...is,html:ce(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",rs).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:or,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:ce(ts).replace("hr",ur).replace("heading",` *#{1,6} *[^
|
|
48
|
-
]`).replace("lheading",
|
|
50
|
+
`}),n}function ud(e){let t=0,n=e.charCodeAt(t);for(;n===9||n===32;)t++,n=e.charCodeAt(t);return e.slice(t)}function ld(e,t){const n=rk(e,t),r=n.one(e,void 0),i=tk(n),a=Array.isArray(r)?{type:"root",children:r}:r||{type:"root",children:[]};return i&&a.children.push({type:"text",value:`
|
|
51
|
+
`},i),a}function uk(e,t){return e&&"run"in e?async function(n,r){const i=ld(n,{file:r,...t});await e.run(i,r)}:function(n,r){return ld(n,{file:r,...e||t})}}function cd(e){if(e)throw e}var mi=Object.prototype.hasOwnProperty,dd=Object.prototype.toString,fd=Object.defineProperty,hd=Object.getOwnPropertyDescriptor,pd=function(t){return typeof Array.isArray=="function"?Array.isArray(t):dd.call(t)==="[object Array]"},md=function(t){if(!t||dd.call(t)!=="[object Object]")return!1;var n=mi.call(t,"constructor"),r=t.constructor&&t.constructor.prototype&&mi.call(t.constructor.prototype,"isPrototypeOf");if(t.constructor&&!n&&!r)return!1;var i;for(i in t);return typeof i>"u"||mi.call(t,i)},gd=function(t,n){fd&&n.name==="__proto__"?fd(t,n.name,{enumerable:!0,configurable:!0,value:n.newValue,writable:!0}):t[n.name]=n.newValue},bd=function(t,n){if(n==="__proto__")if(mi.call(t,n)){if(hd)return hd(t,n).value}else return;return t[n]},lk=function e(){var t,n,r,i,a,s,o=arguments[0],u=1,c=arguments.length,f=!1;for(typeof o=="boolean"&&(f=o,o=arguments[1]||{},u=2),(o==null||typeof o!="object"&&typeof o!="function")&&(o={});u<c;++u)if(t=arguments[u],t!=null)for(n in t)r=bd(o,n),i=bd(t,n),o!==i&&(f&&i&&(md(i)||(a=pd(i)))?(a?(a=!1,s=r&&pd(r)?r:[]):s=r&&md(r)?r:{},gd(o,{name:n,newValue:e(f,s,i)})):typeof i<"u"&&gd(o,{name:n,newValue:i}));return o};const Ja=Fc(lk);function es(e){if(typeof e!="object"||e===null)return!1;const t=Object.getPrototypeOf(e);return(t===null||t===Object.prototype||Object.getPrototypeOf(t)===null)&&!(Symbol.toStringTag in e)&&!(Symbol.iterator in e)}function ck(){const e=[],t={run:n,use:r};return t;function n(...i){let a=-1;const s=i.pop();if(typeof s!="function")throw new TypeError("Expected function as last argument, not "+s);o(null,...i);function o(u,...c){const f=e[++a];let d=-1;if(u){s(u);return}for(;++d<i.length;)(c[d]===null||c[d]===void 0)&&(c[d]=i[d]);i=c,f?dk(f,o)(...c):s(null,...c)}}function r(i){if(typeof i!="function")throw new TypeError("Expected `middelware` to be a function, not "+i);return e.push(i),t}}function dk(e,t){let n;return r;function r(...s){const o=e.length>s.length;let u;o&&s.push(i);try{u=e.apply(this,s)}catch(c){const f=c;if(o&&n)throw f;return i(f)}o||(u&&u.then&&typeof u.then=="function"?u.then(a,i):u instanceof Error?i(u):a(u))}function i(s,...o){n||(n=!0,t(s,...o))}function a(s){i(null,s)}}const Et={basename:fk,dirname:hk,extname:pk,join:mk,sep:"/"};function fk(e,t){if(t!==void 0&&typeof t!="string")throw new TypeError('"ext" argument must be a string');gr(e);let n=0,r=-1,i=e.length,a;if(t===void 0||t.length===0||t.length>e.length){for(;i--;)if(e.codePointAt(i)===47){if(a){n=i+1;break}}else r<0&&(a=!0,r=i+1);return r<0?"":e.slice(n,r)}if(t===e)return"";let s=-1,o=t.length-1;for(;i--;)if(e.codePointAt(i)===47){if(a){n=i+1;break}}else s<0&&(a=!0,s=i+1),o>-1&&(e.codePointAt(i)===t.codePointAt(o--)?o<0&&(r=i):(o=-1,r=s));return n===r?r=s:r<0&&(r=e.length),e.slice(n,r)}function hk(e){if(gr(e),e.length===0)return".";let t=-1,n=e.length,r;for(;--n;)if(e.codePointAt(n)===47){if(r){t=n;break}}else r||(r=!0);return t<0?e.codePointAt(0)===47?"/":".":t===1&&e.codePointAt(0)===47?"//":e.slice(0,t)}function pk(e){gr(e);let t=e.length,n=-1,r=0,i=-1,a=0,s;for(;t--;){const o=e.codePointAt(t);if(o===47){if(s){r=t+1;break}continue}n<0&&(s=!0,n=t+1),o===46?i<0?i=t:a!==1&&(a=1):i>-1&&(a=-1)}return i<0||n<0||a===0||a===1&&i===n-1&&i===r+1?"":e.slice(i,n)}function mk(...e){let t=-1,n;for(;++t<e.length;)gr(e[t]),e[t]&&(n=n===void 0?e[t]:n+"/"+e[t]);return n===void 0?".":gk(n)}function gk(e){gr(e);const t=e.codePointAt(0)===47;let n=bk(e,!t);return n.length===0&&!t&&(n="."),n.length>0&&e.codePointAt(e.length-1)===47&&(n+="/"),t?"/"+n:n}function bk(e,t){let n="",r=0,i=-1,a=0,s=-1,o,u;for(;++s<=e.length;){if(s<e.length)o=e.codePointAt(s);else{if(o===47)break;o=47}if(o===47){if(!(i===s-1||a===1))if(i!==s-1&&a===2){if(n.length<2||r!==2||n.codePointAt(n.length-1)!==46||n.codePointAt(n.length-2)!==46){if(n.length>2){if(u=n.lastIndexOf("/"),u!==n.length-1){u<0?(n="",r=0):(n=n.slice(0,u),r=n.length-1-n.lastIndexOf("/")),i=s,a=0;continue}}else if(n.length>0){n="",r=0,i=s,a=0;continue}}t&&(n=n.length>0?n+"/..":"..",r=2)}else n.length>0?n+="/"+e.slice(i+1,s):n=e.slice(i+1,s),r=s-i-1;i=s,a=0}else o===46&&a>-1?a++:a=-1}return n}function gr(e){if(typeof e!="string")throw new TypeError("Path must be a string. Received "+JSON.stringify(e))}const Ek={cwd:Tk};function Tk(){return"/"}function ts(e){return!!(e!==null&&typeof e=="object"&&"href"in e&&e.href&&"protocol"in e&&e.protocol&&e.auth===void 0)}function _k(e){if(typeof e=="string")e=new URL(e);else if(!ts(e)){const t=new TypeError('The "path" argument must be of type string or an instance of URL. Received `'+e+"`");throw t.code="ERR_INVALID_ARG_TYPE",t}if(e.protocol!=="file:"){const t=new TypeError("The URL must be of scheme file");throw t.code="ERR_INVALID_URL_SCHEME",t}return kk(e)}function kk(e){if(e.hostname!==""){const r=new TypeError('File URL host must be "localhost" or empty on darwin');throw r.code="ERR_INVALID_FILE_URL_HOST",r}const t=e.pathname;let n=-1;for(;++n<t.length;)if(t.codePointAt(n)===37&&t.codePointAt(n+1)===50){const r=t.codePointAt(n+2);if(r===70||r===102){const i=new TypeError("File URL path must not include encoded / characters");throw i.code="ERR_INVALID_FILE_URL_PATH",i}}return decodeURIComponent(t)}const ns=["history","path","basename","stem","extname","dirname"];class xk{constructor(t){let n;t?ts(t)?n={path:t}:typeof t=="string"||yk(t)?n={value:t}:n=t:n={},this.cwd="cwd"in n?"":Ek.cwd(),this.data={},this.history=[],this.messages=[];let r=-1;for(;++r<ns.length;){const a=ns[r];a in n&&n[a]!==void 0&&n[a]!==null&&(this[a]=a==="history"?[...n[a]]:n[a])}let i;for(i in n)ns.includes(i)||(this[i]=n[i])}get basename(){return typeof this.path=="string"?Et.basename(this.path):void 0}set basename(t){is(t,"basename"),rs(t,"basename"),this.path=Et.join(this.dirname||"",t)}get dirname(){return typeof this.path=="string"?Et.dirname(this.path):void 0}set dirname(t){Ed(this.basename,"dirname"),this.path=Et.join(t||"",this.basename)}get extname(){return typeof this.path=="string"?Et.extname(this.path):void 0}set extname(t){if(rs(t,"extname"),Ed(this.dirname,"extname"),t){if(t.codePointAt(0)!==46)throw new Error("`extname` must start with `.`");if(t.includes(".",1))throw new Error("`extname` cannot contain multiple dots")}this.path=Et.join(this.dirname,this.stem+(t||""))}get path(){return this.history[this.history.length-1]}set path(t){ts(t)&&(t=_k(t)),is(t,"path"),this.path!==t&&this.history.push(t)}get stem(){return typeof this.path=="string"?Et.basename(this.path,this.extname):void 0}set stem(t){is(t,"stem"),rs(t,"stem"),this.path=Et.join(this.dirname||"",t+(this.extname||""))}fail(t,n,r){const i=this.message(t,n,r);throw i.fatal=!0,i}info(t,n,r){const i=this.message(t,n,r);return i.fatal=void 0,i}message(t,n,r){const i=new ze(t,n,r);return this.path&&(i.name=this.path+":"+i.name,i.file=this.path),i.fatal=!1,this.messages.push(i),i}toString(t){return this.value===void 0?"":typeof this.value=="string"?this.value:new TextDecoder(t||void 0).decode(this.value)}}function rs(e,t){if(e&&e.includes(Et.sep))throw new Error("`"+t+"` cannot be a path: did not expect `"+Et.sep+"`")}function is(e,t){if(!e)throw new Error("`"+t+"` cannot be empty")}function Ed(e,t){if(!e)throw new Error("Setting `"+t+"` requires `path` to be set too")}function yk(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}const wk=function(e){const r=this.constructor.prototype,i=r[e],a=function(){return i.apply(a,arguments)};return Object.setPrototypeOf(a,r),a},Ak={}.hasOwnProperty;class as extends wk{constructor(){super("copy"),this.Compiler=void 0,this.Parser=void 0,this.attachers=[],this.compiler=void 0,this.freezeIndex=-1,this.frozen=void 0,this.namespace={},this.parser=void 0,this.transformers=ck()}copy(){const t=new as;let n=-1;for(;++n<this.attachers.length;){const r=this.attachers[n];t.use(...r)}return t.data(Ja(!0,{},this.namespace)),t}data(t,n){return typeof t=="string"?arguments.length===2?(us("data",this.frozen),this.namespace[t]=n,this):Ak.call(this.namespace,t)&&this.namespace[t]||void 0:t?(us("data",this.frozen),this.namespace=t,this):this.namespace}freeze(){if(this.frozen)return this;const t=this;for(;++this.freezeIndex<this.attachers.length;){const[n,...r]=this.attachers[this.freezeIndex];if(r[0]===!1)continue;r[0]===!0&&(r[0]=void 0);const i=n.call(t,...r);typeof i=="function"&&this.transformers.use(i)}return this.frozen=!0,this.freezeIndex=Number.POSITIVE_INFINITY,this}parse(t){this.freeze();const n=gi(t),r=this.parser||this.Parser;return ss("parse",r),r(String(n),n)}process(t,n){const r=this;return this.freeze(),ss("process",this.parser||this.Parser),os("process",this.compiler||this.Compiler),n?i(void 0,n):new Promise(i);function i(a,s){const o=gi(t),u=r.parse(o);r.run(u,o,function(f,d,h){if(f||!d||!h)return c(f);const p=d,m=r.stringify(p,h);Nk(m)?h.value=m:h.result=m,c(f,h)});function c(f,d){f||!d?s(f):a?a(d):n(void 0,d)}}}processSync(t){let n=!1,r;return this.freeze(),ss("processSync",this.parser||this.Parser),os("processSync",this.compiler||this.Compiler),this.process(t,i),_d("processSync","process",n),r;function i(a,s){n=!0,cd(a),r=s}}run(t,n,r){Td(t),this.freeze();const i=this.transformers;return!r&&typeof n=="function"&&(r=n,n=void 0),r?a(void 0,r):new Promise(a);function a(s,o){const u=gi(n);i.run(t,u,c);function c(f,d,h){const p=d||t;f?o(f):s?s(p):r(void 0,p,h)}}}runSync(t,n){let r=!1,i;return this.run(t,n,a),_d("runSync","run",r),i;function a(s,o){cd(s),i=o,r=!0}}stringify(t,n){this.freeze();const r=gi(n),i=this.compiler||this.Compiler;return os("stringify",i),Td(t),i(t,r)}use(t,...n){const r=this.attachers,i=this.namespace;if(us("use",this.frozen),t!=null)if(typeof t=="function")u(t,n);else if(typeof t=="object")Array.isArray(t)?o(t):s(t);else throw new TypeError("Expected usable value, not `"+t+"`");return this;function a(c){if(typeof c=="function")u(c,[]);else if(typeof c=="object")if(Array.isArray(c)){const[f,...d]=c;u(f,d)}else s(c);else throw new TypeError("Expected usable value, not `"+c+"`")}function s(c){if(!("plugins"in c)&&!("settings"in c))throw new Error("Expected usable value but received an empty preset, which is probably a mistake: presets typically come with `plugins` and sometimes with `settings`, but this has neither");o(c.plugins),c.settings&&(i.settings=Ja(!0,i.settings,c.settings))}function o(c){let f=-1;if(c!=null)if(Array.isArray(c))for(;++f<c.length;){const d=c[f];a(d)}else throw new TypeError("Expected a list of plugins, not `"+c+"`")}function u(c,f){let d=-1,h=-1;for(;++d<r.length;)if(r[d][0]===c){h=d;break}if(h===-1)r.push([c,...f]);else if(f.length>0){let[p,...m]=f;const _=r[h][1];es(_)&&es(p)&&(p=Ja(!0,_,p)),r[h]=[c,p,...m]}}}}const Ck=new as().freeze();function ss(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `parser`")}function os(e,t){if(typeof t!="function")throw new TypeError("Cannot `"+e+"` without `compiler`")}function us(e,t){if(t)throw new Error("Cannot call `"+e+"` on a frozen processor.\nCreate a new processor first, by calling it: use `processor()` instead of `processor`.")}function Td(e){if(!es(e)||typeof e.type!="string")throw new TypeError("Expected node, got `"+e+"`")}function _d(e,t,n){if(!n)throw new Error("`"+e+"` finished async. Use `"+t+"` instead")}function gi(e){return Sk(e)?e:new xk(e)}function Sk(e){return!!(e&&typeof e=="object"&&"message"in e&&"messages"in e)}function Nk(e){return typeof e=="string"||Ik(e)}function Ik(e){return!!(e&&typeof e=="object"&&"byteLength"in e&&"byteOffset"in e)}function ls(){return{async:!1,breaks:!1,extensions:null,gfm:!0,hooks:null,pedantic:!1,renderer:null,silent:!1,tokenizer:null,walkTokens:null}}var un=ls();function kd(e){un=e}var ln={exec:()=>null};function le(e,t=""){let n=typeof e=="string"?e:e.source,r={replace:(i,a)=>{let s=typeof a=="string"?a:a.source;return s=s.replace(je.caret,"$1"),n=n.replace(i,s),r},getRegex:()=>new RegExp(n,t)};return r}var vk=(()=>{try{return!!new RegExp("(?<=1)(?<!1)")}catch{return!1}})(),je={codeRemoveIndent:/^(?: {1,4}| {0,3}\t)/gm,outputLinkReplace:/\\([\[\]])/g,indentCodeCompensation:/^(\s+)(?:```)/,beginningSpace:/^\s+/,endingHash:/#$/,startingSpaceChar:/^ /,endingSpaceChar:/ $/,nonSpaceChar:/[^ ]/,newLineCharGlobal:/\n/g,tabCharGlobal:/\t/g,multipleSpaceGlobal:/\s+/g,blankLine:/^[ \t]*$/,doubleBlankLine:/\n[ \t]*\n[ \t]*$/,blockquoteStart:/^ {0,3}>/,blockquoteSetextReplace:/\n {0,3}((?:=+|-+) *)(?=\n|$)/g,blockquoteSetextReplace2:/^ {0,3}>[ \t]?/gm,listReplaceNesting:/^ {1,4}(?=( {4})*[^ ])/g,listIsTask:/^\[[ xX]\] +\S/,listReplaceTask:/^\[[ xX]\] +/,listTaskCheckbox:/\[[ xX]\]/,anyLine:/\n.*\n/,hrefBrackets:/^<(.*)>$/,tableDelimiter:/[:|]/,tableAlignChars:/^\||\| *$/g,tableRowBlankLine:/\n[ \t]*$/,tableAlignRight:/^ *-+: *$/,tableAlignCenter:/^ *:-+: *$/,tableAlignLeft:/^ *:-+ *$/,startATag:/^<a /i,endATag:/^<\/a>/i,startPreScriptTag:/^<(pre|code|kbd|script)(\s|>)/i,endPreScriptTag:/^<\/(pre|code|kbd|script)(\s|>)/i,startAngleBracket:/^</,endAngleBracket:/>$/,pedanticHrefTitle:/^([^'"]*[^\s])\s+(['"])(.*)\2/,unicodeAlphaNumeric:/[\p{L}\p{N}]/u,escapeTest:/[&<>"']/,escapeReplace:/[&<>"']/g,escapeTestNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/,escapeReplaceNoEncode:/[<>"']|&(?!(#\d{1,7}|#[Xx][a-fA-F0-9]{1,6}|\w+);)/g,unescapeTest:/&(#(?:\d+)|(?:#x[0-9A-Fa-f]+)|(?:\w+));?/ig,caret:/(^|[^\[])\^/g,percentDecode:/%25/g,findPipe:/\|/g,splitPipe:/ \|/,slashPipe:/\\\|/g,carriageReturn:/\r\n|\r/g,spaceLine:/^ +$/gm,notSpaceStart:/^\S*/,endingNewline:/\n$/,listItemRegex:e=>new RegExp(`^( {0,3}${e})((?:[ ][^\\n]*)?(?:\\n|$))`),nextBulletRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:[*+-]|\\d{1,9}[.)])((?:[ ][^\\n]*)?(?:\\n|$))`),hrRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}((?:- *){3,}|(?:_ *){3,}|(?:\\* *){3,})(?:\\n+|$)`),fencesBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}(?:\`\`\`|~~~)`),headingBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}#`),htmlBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}<(?:[a-z].*>|!--)`,"i"),blockquoteBeginRegex:e=>new RegExp(`^ {0,${Math.min(3,e-1)}}>`)},Lk=/^(?:[ \t]*(?:\n|$))+/,Rk=/^((?: {4}| {0,3}\t)[^\n]+(?:\n(?:[ \t]*(?:\n|$))*)?)+/,Ok=/^ {0,3}(`{3,}(?=[^`\n]*(?:\n|$))|~{3,})([^\n]*)(?:\n|$)(?:|([\s\S]*?)(?:\n|$))(?: {0,3}\1[~`]* *(?=\n|$)|$)/,br=/^ {0,3}((?:-[\t ]*){3,}|(?:_[ \t]*){3,}|(?:\*[ \t]*){3,})(?:\n+|$)/,Dk=/^ {0,3}(#{1,6})(?=\s|$)(.*)(?:\n+|$)/,cs=/ {0,3}(?:[*+-]|\d{1,9}[.)])/,xd=/^(?!bull |blockCode|fences|blockquote|heading|html|table)((?:.|\n(?!\s*?\n|bull |blockCode|fences|blockquote|heading|html|table))+?)\n {0,3}(=+|-+) *(?:\n+|$)/,yd=le(xd).replace(/bull/g,cs).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/\|table/g,"").getRegex(),Pk=le(xd).replace(/bull/g,cs).replace(/blockCode/g,/(?: {4}| {0,3}\t)/).replace(/fences/g,/ {0,3}(?:`{3,}|~{3,})/).replace(/blockquote/g,/ {0,3}>/).replace(/heading/g,/ {0,3}#{1,6}/).replace(/html/g,/ {0,3}<[^\n>]+>\n/).replace(/table/g,/ {0,3}\|?(?:[:\- ]*\|)+[\:\- ]*\n/).getRegex(),ds=/^([^\n]+(?:\n(?!hr|heading|lheading|blockquote|fences|list|html|table| +\n)[^\n]+)*)/,Mk=/^[^\n]+/,fs=/(?!\s*\])(?:\\[\s\S]|[^\[\]\\])+/,Bk=le(/^ {0,3}\[(label)\]: *(?:\n[ \t]*)?([^<\s][^\s]*|<.*?>)(?:(?: +(?:\n[ \t]*)?| *\n[ \t]*)(title))? *(?:\n+|$)/).replace("label",fs).replace("title",/(?:"(?:\\"?|[^"\\])*"|'[^'\n]*(?:\n[^'\n]+)*\n?'|\([^()]*\))/).getRegex(),Fk=le(/^(bull)([ \t][^\n]+?)?(?:\n|$)/).replace(/bull/g,cs).getRegex(),bi="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|h[1-6]|head|header|hr|html|iframe|legend|li|link|main|menu|menuitem|meta|nav|noframes|ol|optgroup|option|p|param|search|section|summary|table|tbody|td|tfoot|th|thead|title|tr|track|ul",hs=/<!--(?:-?>|[\s\S]*?(?:-->|$))/,Hk=le("^ {0,3}(?:<(script|pre|style|textarea)[\\s>][\\s\\S]*?(?:</\\1>[^\\n]*\\n+|$)|comment[^\\n]*(\\n+|$)|<\\?[\\s\\S]*?(?:\\?>\\n*|$)|<![A-Z][\\s\\S]*?(?:>\\n*|$)|<!\\[CDATA\\[[\\s\\S]*?(?:\\]\\]>\\n*|$)|</?(tag)(?: +|\\n|/?>)[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|<(?!script|pre|style|textarea)([a-z][\\w-]*)(?:attribute)*? */?>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$)|</(?!script|pre|style|textarea)[a-z][\\w-]*\\s*>(?=[ \\t]*(?:\\n|$))[\\s\\S]*?(?:(?:\\n[ ]*)+\\n|$))","i").replace("comment",hs).replace("tag",bi).replace("attribute",/ +[a-zA-Z:_][\w.:-]*(?: *= *"[^"\n]*"| *= *'[^'\n]*'| *= *[^\s"'=<>`]+)?/).getRegex(),wd=le(ds).replace("hr",br).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("|table","").replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",bi).getRegex(),Uk=le(/^( {0,3}> ?(paragraph|[^\n]*)(?:\n|$))+/).replace("paragraph",wd).getRegex(),ps={blockquote:Uk,code:Rk,def:Bk,fences:Ok,heading:Dk,hr:br,html:Hk,lheading:yd,list:Fk,newline:Lk,paragraph:wd,table:ln,text:Mk},Ad=le("^ *([^\\n ].*)\\n {0,3}((?:\\| *)?:?-+:? *(?:\\| *:?-+:? *)*(?:\\| *)?)(?:\\n((?:(?! *\\n|hr|heading|blockquote|code|fences|list|html).*(?:\\n|$))*)\\n*|$)").replace("hr",br).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("blockquote"," {0,3}>").replace("code","(?: {4}| {0,3} )[^\\n]").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",bi).getRegex(),zk={...ps,lheading:Pk,table:Ad,paragraph:le(ds).replace("hr",br).replace("heading"," {0,3}#{1,6}(?:\\s|$)").replace("|lheading","").replace("table",Ad).replace("blockquote"," {0,3}>").replace("fences"," {0,3}(?:`{3,}(?=[^`\\n]*\\n)|~{3,})[^\\n]*\\n").replace("list"," {0,3}(?:[*+-]|1[.)])[ \\t]").replace("html","</?(?:tag)(?: +|\\n|/?>)|<(?:script|pre|style|textarea|!--)").replace("tag",bi).getRegex()},$k={...ps,html:le(`^ *(?:comment *(?:\\n|\\s*$)|<(tag)[\\s\\S]+?</\\1> *(?:\\n{2,}|\\s*$)|<tag(?:"[^"]*"|'[^']*'|\\s[^'"/>\\s]*)*?/?> *(?:\\n{2,}|\\s*$))`).replace("comment",hs).replace(/tag/g,"(?!(?:a|em|strong|small|s|cite|q|dfn|abbr|data|time|code|var|samp|kbd|sub|sup|i|b|u|mark|ruby|rt|rp|bdi|bdo|span|br|wbr|ins|del|img)\\b)\\w+(?!:|[^\\w\\s@]*@)\\b").getRegex(),def:/^ *\[([^\]]+)\]: *<?([^\s>]+)>?(?: +(["(][^\n]+[")]))? *(?:\n+|$)/,heading:/^(#{1,6})(.*)(?:\n+|$)/,fences:ln,lheading:/^(.+?)\n {0,3}(=+|-+) *(?:\n+|$)/,paragraph:le(ds).replace("hr",br).replace("heading",` *#{1,6} *[^
|
|
52
|
+
]`).replace("lheading",yd).replace("|table","").replace("blockquote"," {0,3}>").replace("|fences","").replace("|list","").replace("|html","").replace("|tag","").getRegex()},Yk=/^\\([!"#$%&'()*+,\-./:;<=>?@\[\]\\^_`{|}~])/,jk=/^(`+)([^`]|[^`][\s\S]*?[^`])\1(?!`)/,Cd=/^( {2,}|\\)\n(?!\s*$)/,Vk=/^(`+|[^`])(?:(?= {2,}\n)|[\s\S]*?(?:(?=[\\<!\[`*_]|\b_|$)|[^ ](?= {2,}\n)))/,Ei=/[\p{P}\p{S}]/u,ms=/[\s\p{P}\p{S}]/u,Sd=/[^\s\p{P}\p{S}]/u,qk=le(/^((?![*_])punctSpace)/,"u").replace(/punctSpace/g,ms).getRegex(),Nd=/(?!~)[\p{P}\p{S}]/u,Wk=/(?!~)[\s\p{P}\p{S}]/u,Gk=/(?:[^\s\p{P}\p{S}]|~)/u,Id=/(?![*_])[\p{P}\p{S}]/u,Qk=/(?![*_])[\s\p{P}\p{S}]/u,Kk=/(?:[^\s\p{P}\p{S}]|[*_])/u,Xk=le(/link|precode-code|html/,"g").replace("link",/\[(?:[^\[\]`]|(?<a>`+)[^`]+\k<a>(?!`))*?\]\((?:\\[\s\S]|[^\\\(\)]|\((?:\\[\s\S]|[^\\\(\)])*\))*\)/).replace("precode-",vk?"(?<!`)()":"(^^|[^`])").replace("code",/(?<b>`+)[^`]+\k<b>(?!`)/).replace("html",/<(?! )[^<>]*?>/).getRegex(),vd=/^(?:\*+(?:((?!\*)punct)|[^\s*]))|^_+(?:((?!_)punct)|([^\s_]))/,Zk=le(vd,"u").replace(/punct/g,Ei).getRegex(),Jk=le(vd,"u").replace(/punct/g,Nd).getRegex(),Ld="^[^_*]*?__[^_*]*?\\*[^_*]*?(?=__)|[^*]+(?=[^*])|(?!\\*)punct(\\*+)(?=[\\s]|$)|notPunctSpace(\\*+)(?!\\*)(?=punctSpace|$)|(?!\\*)punctSpace(\\*+)(?=notPunctSpace)|[\\s](\\*+)(?!\\*)(?=punct)|(?!\\*)punct(\\*+)(?!\\*)(?=punct)|notPunctSpace(\\*+)(?=notPunctSpace)",ex=le(Ld,"gu").replace(/notPunctSpace/g,Sd).replace(/punctSpace/g,ms).replace(/punct/g,Ei).getRegex(),tx=le(Ld,"gu").replace(/notPunctSpace/g,Gk).replace(/punctSpace/g,Wk).replace(/punct/g,Nd).getRegex(),nx=le("^[^_*]*?\\*\\*[^_*]*?_[^_*]*?(?=\\*\\*)|[^_]+(?=[^_])|(?!_)punct(_+)(?=[\\s]|$)|notPunctSpace(_+)(?!_)(?=punctSpace|$)|(?!_)punctSpace(_+)(?=notPunctSpace)|[\\s](_+)(?!_)(?=punct)|(?!_)punct(_+)(?!_)(?=punct)","gu").replace(/notPunctSpace/g,Sd).replace(/punctSpace/g,ms).replace(/punct/g,Ei).getRegex(),rx=le(/^~~?(?:((?!~)punct)|[^\s~])/,"u").replace(/punct/g,Id).getRegex(),ix="^[^~]+(?=[^~])|(?!~)punct(~~?)(?=[\\s]|$)|notPunctSpace(~~?)(?!~)(?=punctSpace|$)|(?!~)punctSpace(~~?)(?=notPunctSpace)|[\\s](~~?)(?!~)(?=punct)|(?!~)punct(~~?)(?!~)(?=punct)|notPunctSpace(~~?)(?=notPunctSpace)",ax=le(ix,"gu").replace(/notPunctSpace/g,Kk).replace(/punctSpace/g,Qk).replace(/punct/g,Id).getRegex(),sx=le(/\\(punct)/,"gu").replace(/punct/g,Ei).getRegex(),ox=le(/^<(scheme:[^\s\x00-\x1f<>]*|email)>/).replace("scheme",/[a-zA-Z][a-zA-Z0-9+.-]{1,31}/).replace("email",/[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])?)+(?![-_])/).getRegex(),ux=le(hs).replace("(?:-->|$)","-->").getRegex(),lx=le("^comment|^</[a-zA-Z][\\w:-]*\\s*>|^<[a-zA-Z][\\w-]*(?:attribute)*?\\s*/?>|^<\\?[\\s\\S]*?\\?>|^<![a-zA-Z]+\\s[\\s\\S]*?>|^<!\\[CDATA\\[[\\s\\S]*?\\]\\]>").replace("comment",ux).replace("attribute",/\s+[a-zA-Z:_][\w.:-]*(?:\s*=\s*"[^"]*"|\s*=\s*'[^']*'|\s*=\s*[^\s"'=<>`]+)?/).getRegex(),Ti=/(?:\[(?:\\[\s\S]|[^\[\]\\])*\]|\\[\s\S]|`+[^`]*?`+(?!`)|[^\[\]\\`])*?/,cx=le(/^!?\[(label)\]\(\s*(href)(?:(?:[ \t]*(?:\n[ \t]*)?)(title))?\s*\)/).replace("label",Ti).replace("href",/<(?:\\.|[^\n<>\\])+>|[^ \t\n\x00-\x1f]*/).replace("title",/"(?:\\"?|[^"\\])*"|'(?:\\'?|[^'\\])*'|\((?:\\\)?|[^)\\])*\)/).getRegex(),Rd=le(/^!?\[(label)\]\[(ref)\]/).replace("label",Ti).replace("ref",fs).getRegex(),Od=le(/^!?\[(ref)\](?:\[\])?/).replace("ref",fs).getRegex(),dx=le("reflink|nolink(?!\\()","g").replace("reflink",Rd).replace("nolink",Od).getRegex(),Dd=/[hH][tT][tT][pP][sS]?|[fF][tT][pP]/,gs={_backpedal:ln,anyPunctuation:sx,autolink:ox,blockSkip:Xk,br:Cd,code:jk,del:ln,delLDelim:ln,delRDelim:ln,emStrongLDelim:Zk,emStrongRDelimAst:ex,emStrongRDelimUnd:nx,escape:Yk,link:cx,nolink:Od,punctuation:qk,reflink:Rd,reflinkSearch:dx,tag:lx,text:Vk,url:ln},fx={...gs,link:le(/^!?\[(label)\]\((.*?)\)/).replace("label",Ti).getRegex(),reflink:le(/^!?\[(label)\]\s*\[([^\]]*)\]/).replace("label",Ti).getRegex()},bs={...gs,emStrongRDelimAst:tx,emStrongLDelim:Jk,delLDelim:rx,delRDelim:ax,url:le(/^((?:protocol):\/\/|www\.)(?:[a-zA-Z0-9\-]+\.?)+[^\s<]*|^email/).replace("protocol",Dd).replace("email",/[A-Za-z0-9._+-]+(@)[a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]*[a-zA-Z0-9])+(?![-_])/).getRegex(),_backpedal:/(?:[^?!.,:;*_'"~()&]+|\([^)]*\)|&(?![a-zA-Z0-9]+;$)|[?!.,:;*_'"~)]+(?!$))+/,del:/^(~~?)(?=[^\s~])((?:\\[\s\S]|[^\\])*?(?:\\[\s\S]|[^\s~\\]))\1(?=[^~]|$)/,text:le(/^([`~]+|[^`~])(?:(?= {2,}\n)|(?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)|[\s\S]*?(?:(?=[\\<!\[`*~_]|\b_|protocol:\/\/|www\.|$)|[^ ](?= {2,}\n)|[^a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-](?=[a-zA-Z0-9.!#$%&'*+\/=?_`{\|}~-]+@)))/).replace("protocol",Dd).getRegex()},hx={...bs,br:le(Cd).replace("{2,}","*").getRegex(),text:le(bs.text).replace("\\b_","\\b_| {2,}\\n").replace(/\{2,\}/g,"*").getRegex()},_i={normal:ps,gfm:zk,pedantic:$k},Er={normal:gs,gfm:bs,breaks:hx,pedantic:fx},px={"&":"&","<":"<",">":">",'"':""","'":"'"},Pd=e=>px[e];function Tt(e,t){if(t){if(je.escapeTest.test(e))return e.replace(je.escapeReplace,Pd)}else if(je.escapeTestNoEncode.test(e))return e.replace(je.escapeReplaceNoEncode,Pd);return e}function Md(e){try{e=encodeURI(e).replace(je.percentDecode,"%")}catch{return null}return e}function Bd(e,t){let n=e.replace(je.findPipe,(a,s,o)=>{let u=!1,c=s;for(;--c>=0&&o[c]==="\\";)u=!u;return u?"|":" |"}),r=n.split(je.splitPipe),i=0;if(r[0].trim()||r.shift(),r.length>0&&!r.at(-1)?.trim()&&r.pop(),t)if(r.length>t)r.splice(t);else for(;r.length<t;)r.push("");for(;i<r.length;i++)r[i]=r[i].trim().replace(je.slashPipe,"|");return r}function Tr(e,t,n){let r=e.length;if(r===0)return"";let i=0;for(;i<r;){let a=e.charAt(r-i-1);if(a===t&&!n)i++;else if(a!==t&&n)i++;else break}return e.slice(0,r-i)}function mx(e,t){if(e.indexOf(t[1])===-1)return-1;let n=0;for(let r=0;r<e.length;r++)if(e[r]==="\\")r++;else if(e[r]===t[0])n++;else if(e[r]===t[1]&&(n--,n<0))return r;return n>0?-2:-1}function gx(e,t=0){let n=t,r="";for(let i of e)if(i===" "){let a=4-n%4;r+=" ".repeat(a),n+=a}else r+=i,n++;return r}function Fd(e,t,n,r,i){let a=t.href,s=t.title||null,o=e[1].replace(i.other.outputLinkReplace,"$1");r.state.inLink=!0;let u={type:e[0].charAt(0)==="!"?"image":"link",raw:n,href:a,title:s,text:o,tokens:r.inlineTokens(o)};return r.state.inLink=!1,u}function bx(e,t,n){let r=e.match(n.other.indentCodeCompensation);if(r===null)return t;let i=r[1];return t.split(`
|
|
49
53
|
`).map(a=>{let s=a.match(n.other.beginningSpace);if(s===null)return a;let[o]=s;return o.length>=i.length?a.slice(i.length):a}).join(`
|
|
50
|
-
`)}var
|
|
51
|
-
`)}}}fences(e){let t=this.rules.block.fences.exec(e);if(t){let n=t[0],r=
|
|
52
|
-
`)}}blockquote(e){let t=this.rules.block.blockquote.exec(e);if(t){let n=
|
|
54
|
+
`)}var ki=class{constructor(e){pe(this,"options");pe(this,"rules");pe(this,"lexer");this.options=e||un}space(e){let t=this.rules.block.newline.exec(e);if(t&&t[0].length>0)return{type:"space",raw:t[0]}}code(e){let t=this.rules.block.code.exec(e);if(t){let n=t[0].replace(this.rules.other.codeRemoveIndent,"");return{type:"code",raw:t[0],codeBlockStyle:"indented",text:this.options.pedantic?n:Tr(n,`
|
|
55
|
+
`)}}}fences(e){let t=this.rules.block.fences.exec(e);if(t){let n=t[0],r=bx(n,t[3]||"",this.rules);return{type:"code",raw:n,lang:t[2]?t[2].trim().replace(this.rules.inline.anyPunctuation,"$1"):t[2],text:r}}}heading(e){let t=this.rules.block.heading.exec(e);if(t){let n=t[2].trim();if(this.rules.other.endingHash.test(n)){let r=Tr(n,"#");(this.options.pedantic||!r||this.rules.other.endingSpaceChar.test(r))&&(n=r.trim())}return{type:"heading",raw:t[0],depth:t[1].length,text:n,tokens:this.lexer.inline(n)}}}hr(e){let t=this.rules.block.hr.exec(e);if(t)return{type:"hr",raw:Tr(t[0],`
|
|
56
|
+
`)}}blockquote(e){let t=this.rules.block.blockquote.exec(e);if(t){let n=Tr(t[0],`
|
|
53
57
|
`).split(`
|
|
54
58
|
`),r="",i="",a=[];for(;n.length>0;){let s=!1,o=[],u;for(u=0;u<n.length;u++)if(this.rules.other.blockquoteStart.test(n[u]))o.push(n[u]),s=!0;else if(!s)o.push(n[u]);else break;n=n.slice(u);let c=o.join(`
|
|
55
59
|
`),f=c.replace(this.rules.other.blockquoteSetextReplace,`
|
|
@@ -60,17 +64,17 @@ ${f}`:f;let d=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTo
|
|
|
60
64
|
`),_=this.blockquote(m);a[a.length-1]=_,r=r.substring(0,r.length-p.raw.length)+_.raw,i=i.substring(0,i.length-p.text.length)+_.text;break}else if(h?.type==="list"){let p=h,m=p.raw+`
|
|
61
65
|
`+n.join(`
|
|
62
66
|
`),_=this.list(m);a[a.length-1]=_,r=r.substring(0,r.length-h.raw.length)+_.raw,i=i.substring(0,i.length-p.raw.length)+_.raw,n=m.substring(a.at(-1).raw.length).split(`
|
|
63
|
-
`);continue}}return{type:"blockquote",raw:r,tokens:a,text:i}}}list(e){let t=this.rules.block.list.exec(e);if(t){let n=t[1].trim(),r=n.length>1,i={type:"list",raw:"",ordered:r,start:r?+n.slice(0,-1):"",loose:!1,items:[]};n=r?`\\d{1,9}\\${n.slice(-1)}`:`\\${n}`,this.options.pedantic&&(n=r?n:"[*+-]");let a=this.rules.other.listItemRegex(n),s=!1;for(;e;){let u=!1,c="",f="";if(!(t=a.exec(e))||this.rules.block.hr.test(e))break;c=t[0],e=e.substring(c.length);let d=t[2].split(`
|
|
64
|
-
`,1)[0]
|
|
65
|
-
`,1)[0],p=!d.trim(),m=0;if(this.options.pedantic?(m=2,f=d.trimStart()):p?m=t[1].length+1:(m=
|
|
66
|
-
`,e=e.substring(h.length+1),u=!0),!u){let _=this.rules.other.nextBulletRegex(m),
|
|
67
|
-
`,1)[0],
|
|
68
|
-
`+
|
|
69
|
-
`+h}
|
|
70
|
-
`,e=e.substring(
|
|
71
|
-
`):[],a={type:"table",raw:t[0],header:[],align:[],rows:[]};if(n.length===r.length){for(let s of r)this.rules.other.tableAlignRight.test(s)?a.align.push("right"):this.rules.other.tableAlignCenter.test(s)?a.align.push("center"):this.rules.other.tableAlignLeft.test(s)?a.align.push("left"):a.align.push(null);for(let s=0;s<n.length;s++)a.header.push({text:n[s],tokens:this.lexer.inline(n[s]),header:!0,align:a.align[s]});for(let s of i)a.rows.push(
|
|
72
|
-
`?t[1].slice(0,-1):t[1];return{type:"paragraph",raw:t[0],text:n,tokens:this.lexer.inline(n)}}}text(e){let t=this.rules.block.text.exec(e);if(t)return{type:"text",raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(e){let t=this.rules.inline.escape.exec(e);if(t)return{type:"escape",raw:t[0],text:t[1]}}tag(e){let t=this.rules.inline.tag.exec(e);if(t)return!this.lexer.state.inLink&&this.rules.other.startATag.test(t[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:t[0]}}link(e){let t=this.rules.inline.link.exec(e);if(t){let n=t[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(n)){if(!this.rules.other.endAngleBracket.test(n))return;let a=
|
|
73
|
-
`),this.blockTokens(t,this.tokens);for(let n=0;n<this.inlineQueue.length;n++){let r=this.inlineQueue[n];this.inlineTokens(r.src,r.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(t,n=[],r=!1){for(this.options.pedantic&&(t=t.replace(
|
|
67
|
+
`);continue}}return{type:"blockquote",raw:r,tokens:a,text:i}}}list(e){let t=this.rules.block.list.exec(e);if(t){let n=t[1].trim(),r=n.length>1,i={type:"list",raw:"",ordered:r,start:r?+n.slice(0,-1):"",loose:!1,items:[]};n=r?`\\d{1,9}\\${n.slice(-1)}`:`\\${n}`,this.options.pedantic&&(n=r?n:"[*+-]");let a=this.rules.other.listItemRegex(n),s=!1;for(;e;){let u=!1,c="",f="";if(!(t=a.exec(e))||this.rules.block.hr.test(e))break;c=t[0],e=e.substring(c.length);let d=gx(t[2].split(`
|
|
68
|
+
`,1)[0],t[1].length),h=e.split(`
|
|
69
|
+
`,1)[0],p=!d.trim(),m=0;if(this.options.pedantic?(m=2,f=d.trimStart()):p?m=t[1].length+1:(m=d.search(this.rules.other.nonSpaceChar),m=m>4?1:m,f=d.slice(m),m+=t[1].length),p&&this.rules.other.blankLine.test(h)&&(c+=h+`
|
|
70
|
+
`,e=e.substring(h.length+1),u=!0),!u){let _=this.rules.other.nextBulletRegex(m),w=this.rules.other.hrRegex(m),y=this.rules.other.fencesBeginRegex(m),S=this.rules.other.headingBeginRegex(m),C=this.rules.other.htmlBeginRegex(m),D=this.rules.other.blockquoteBeginRegex(m);for(;e;){let P=e.split(`
|
|
71
|
+
`,1)[0],A;if(h=P,this.options.pedantic?(h=h.replace(this.rules.other.listReplaceNesting," "),A=h):A=h.replace(this.rules.other.tabCharGlobal," "),y.test(h)||S.test(h)||C.test(h)||D.test(h)||_.test(h)||w.test(h))break;if(A.search(this.rules.other.nonSpaceChar)>=m||!h.trim())f+=`
|
|
72
|
+
`+A.slice(m);else{if(p||d.replace(this.rules.other.tabCharGlobal," ").search(this.rules.other.nonSpaceChar)>=4||y.test(d)||S.test(d)||w.test(d))break;f+=`
|
|
73
|
+
`+h}p=!h.trim(),c+=P+`
|
|
74
|
+
`,e=e.substring(P.length+1),d=A.slice(m)}}i.loose||(s?i.loose=!0:this.rules.other.doubleBlankLine.test(c)&&(s=!0)),i.items.push({type:"list_item",raw:c,task:!!this.options.gfm&&this.rules.other.listIsTask.test(f),loose:!1,text:f,tokens:[]}),i.raw+=c}let o=i.items.at(-1);if(o)o.raw=o.raw.trimEnd(),o.text=o.text.trimEnd();else return;i.raw=i.raw.trimEnd();for(let u of i.items){if(this.lexer.state.top=!1,u.tokens=this.lexer.blockTokens(u.text,[]),u.task){if(u.text=u.text.replace(this.rules.other.listReplaceTask,""),u.tokens[0]?.type==="text"||u.tokens[0]?.type==="paragraph"){u.tokens[0].raw=u.tokens[0].raw.replace(this.rules.other.listReplaceTask,""),u.tokens[0].text=u.tokens[0].text.replace(this.rules.other.listReplaceTask,"");for(let f=this.lexer.inlineQueue.length-1;f>=0;f--)if(this.rules.other.listIsTask.test(this.lexer.inlineQueue[f].src)){this.lexer.inlineQueue[f].src=this.lexer.inlineQueue[f].src.replace(this.rules.other.listReplaceTask,"");break}}let c=this.rules.other.listTaskCheckbox.exec(u.raw);if(c){let f={type:"checkbox",raw:c[0]+" ",checked:c[0]!=="[ ]"};u.checked=f.checked,i.loose?u.tokens[0]&&["paragraph","text"].includes(u.tokens[0].type)&&"tokens"in u.tokens[0]&&u.tokens[0].tokens?(u.tokens[0].raw=f.raw+u.tokens[0].raw,u.tokens[0].text=f.raw+u.tokens[0].text,u.tokens[0].tokens.unshift(f)):u.tokens.unshift({type:"paragraph",raw:f.raw,text:f.raw,tokens:[f]}):u.tokens.unshift(f)}}if(!i.loose){let c=u.tokens.filter(d=>d.type==="space"),f=c.length>0&&c.some(d=>this.rules.other.anyLine.test(d.raw));i.loose=f}}if(i.loose)for(let u of i.items){u.loose=!0;for(let c of u.tokens)c.type==="text"&&(c.type="paragraph")}return i}}html(e){let t=this.rules.block.html.exec(e);if(t)return{type:"html",block:!0,raw:t[0],pre:t[1]==="pre"||t[1]==="script"||t[1]==="style",text:t[0]}}def(e){let t=this.rules.block.def.exec(e);if(t){let n=t[1].toLowerCase().replace(this.rules.other.multipleSpaceGlobal," "),r=t[2]?t[2].replace(this.rules.other.hrefBrackets,"$1").replace(this.rules.inline.anyPunctuation,"$1"):"",i=t[3]?t[3].substring(1,t[3].length-1).replace(this.rules.inline.anyPunctuation,"$1"):t[3];return{type:"def",tag:n,raw:t[0],href:r,title:i}}}table(e){let t=this.rules.block.table.exec(e);if(!t||!this.rules.other.tableDelimiter.test(t[2]))return;let n=Bd(t[1]),r=t[2].replace(this.rules.other.tableAlignChars,"").split("|"),i=t[3]?.trim()?t[3].replace(this.rules.other.tableRowBlankLine,"").split(`
|
|
75
|
+
`):[],a={type:"table",raw:t[0],header:[],align:[],rows:[]};if(n.length===r.length){for(let s of r)this.rules.other.tableAlignRight.test(s)?a.align.push("right"):this.rules.other.tableAlignCenter.test(s)?a.align.push("center"):this.rules.other.tableAlignLeft.test(s)?a.align.push("left"):a.align.push(null);for(let s=0;s<n.length;s++)a.header.push({text:n[s],tokens:this.lexer.inline(n[s]),header:!0,align:a.align[s]});for(let s of i)a.rows.push(Bd(s,a.header.length).map((o,u)=>({text:o,tokens:this.lexer.inline(o),header:!1,align:a.align[u]})));return a}}lheading(e){let t=this.rules.block.lheading.exec(e);if(t)return{type:"heading",raw:t[0],depth:t[2].charAt(0)==="="?1:2,text:t[1],tokens:this.lexer.inline(t[1])}}paragraph(e){let t=this.rules.block.paragraph.exec(e);if(t){let n=t[1].charAt(t[1].length-1)===`
|
|
76
|
+
`?t[1].slice(0,-1):t[1];return{type:"paragraph",raw:t[0],text:n,tokens:this.lexer.inline(n)}}}text(e){let t=this.rules.block.text.exec(e);if(t)return{type:"text",raw:t[0],text:t[0],tokens:this.lexer.inline(t[0])}}escape(e){let t=this.rules.inline.escape.exec(e);if(t)return{type:"escape",raw:t[0],text:t[1]}}tag(e){let t=this.rules.inline.tag.exec(e);if(t)return!this.lexer.state.inLink&&this.rules.other.startATag.test(t[0])?this.lexer.state.inLink=!0:this.lexer.state.inLink&&this.rules.other.endATag.test(t[0])&&(this.lexer.state.inLink=!1),!this.lexer.state.inRawBlock&&this.rules.other.startPreScriptTag.test(t[0])?this.lexer.state.inRawBlock=!0:this.lexer.state.inRawBlock&&this.rules.other.endPreScriptTag.test(t[0])&&(this.lexer.state.inRawBlock=!1),{type:"html",raw:t[0],inLink:this.lexer.state.inLink,inRawBlock:this.lexer.state.inRawBlock,block:!1,text:t[0]}}link(e){let t=this.rules.inline.link.exec(e);if(t){let n=t[2].trim();if(!this.options.pedantic&&this.rules.other.startAngleBracket.test(n)){if(!this.rules.other.endAngleBracket.test(n))return;let a=Tr(n.slice(0,-1),"\\");if((n.length-a.length)%2===0)return}else{let a=mx(t[2],"()");if(a===-2)return;if(a>-1){let s=(t[0].indexOf("!")===0?5:4)+t[1].length+a;t[2]=t[2].substring(0,a),t[0]=t[0].substring(0,s).trim(),t[3]=""}}let r=t[2],i="";if(this.options.pedantic){let a=this.rules.other.pedanticHrefTitle.exec(r);a&&(r=a[1],i=a[3])}else i=t[3]?t[3].slice(1,-1):"";return r=r.trim(),this.rules.other.startAngleBracket.test(r)&&(this.options.pedantic&&!this.rules.other.endAngleBracket.test(n)?r=r.slice(1):r=r.slice(1,-1)),Fd(t,{href:r&&r.replace(this.rules.inline.anyPunctuation,"$1"),title:i&&i.replace(this.rules.inline.anyPunctuation,"$1")},t[0],this.lexer,this.rules)}}reflink(e,t){let n;if((n=this.rules.inline.reflink.exec(e))||(n=this.rules.inline.nolink.exec(e))){let r=(n[2]||n[1]).replace(this.rules.other.multipleSpaceGlobal," "),i=t[r.toLowerCase()];if(!i){let a=n[0].charAt(0);return{type:"text",raw:a,text:a}}return Fd(n,i,n[0],this.lexer,this.rules)}}emStrong(e,t,n=""){let r=this.rules.inline.emStrongLDelim.exec(e);if(!(!r||r[3]&&n.match(this.rules.other.unicodeAlphaNumeric))&&(!(r[1]||r[2])||!n||this.rules.inline.punctuation.exec(n))){let i=[...r[0]].length-1,a,s,o=i,u=0,c=r[0][0]==="*"?this.rules.inline.emStrongRDelimAst:this.rules.inline.emStrongRDelimUnd;for(c.lastIndex=0,t=t.slice(-1*e.length+i);(r=c.exec(t))!=null;){if(a=r[1]||r[2]||r[3]||r[4]||r[5]||r[6],!a)continue;if(s=[...a].length,r[3]||r[4]){o+=s;continue}else if((r[5]||r[6])&&i%3&&!((i+s)%3)){u+=s;continue}if(o-=s,o>0)continue;s=Math.min(s,s+o+u);let f=[...r[0]][0].length,d=e.slice(0,i+r.index+f+s);if(Math.min(i,s)%2){let p=d.slice(1,-1);return{type:"em",raw:d,text:p,tokens:this.lexer.inlineTokens(p)}}let h=d.slice(2,-2);return{type:"strong",raw:d,text:h,tokens:this.lexer.inlineTokens(h)}}}}codespan(e){let t=this.rules.inline.code.exec(e);if(t){let n=t[2].replace(this.rules.other.newLineCharGlobal," "),r=this.rules.other.nonSpaceChar.test(n),i=this.rules.other.startingSpaceChar.test(n)&&this.rules.other.endingSpaceChar.test(n);return r&&i&&(n=n.substring(1,n.length-1)),{type:"codespan",raw:t[0],text:n}}}br(e){let t=this.rules.inline.br.exec(e);if(t)return{type:"br",raw:t[0]}}del(e,t,n=""){let r=this.rules.inline.delLDelim.exec(e);if(r&&(!r[1]||!n||this.rules.inline.punctuation.exec(n))){let i=[...r[0]].length-1,a,s,o=i,u=this.rules.inline.delRDelim;for(u.lastIndex=0,t=t.slice(-1*e.length+i);(r=u.exec(t))!=null;){if(a=r[1]||r[2]||r[3]||r[4]||r[5]||r[6],!a||(s=[...a].length,s!==i))continue;if(r[3]||r[4]){o+=s;continue}if(o-=s,o>0)continue;s=Math.min(s,s+o);let c=[...r[0]][0].length,f=e.slice(0,i+r.index+c+s),d=f.slice(i,-i);return{type:"del",raw:f,text:d,tokens:this.lexer.inlineTokens(d)}}}}autolink(e){let t=this.rules.inline.autolink.exec(e);if(t){let n,r;return t[2]==="@"?(n=t[1],r="mailto:"+n):(n=t[1],r=n),{type:"link",raw:t[0],text:n,href:r,tokens:[{type:"text",raw:n,text:n}]}}}url(e){let t;if(t=this.rules.inline.url.exec(e)){let n,r;if(t[2]==="@")n=t[0],r="mailto:"+n;else{let i;do i=t[0],t[0]=this.rules.inline._backpedal.exec(t[0])?.[0]??"";while(i!==t[0]);n=t[0],t[1]==="www."?r="http://"+t[0]:r=t[0]}return{type:"link",raw:t[0],text:n,href:r,tokens:[{type:"text",raw:n,text:n}]}}}inlineText(e){let t=this.rules.inline.text.exec(e);if(t){let n=this.lexer.state.inRawBlock;return{type:"text",raw:t[0],text:t[0],escaped:n}}}},ut=class Os{constructor(t){pe(this,"tokens");pe(this,"options");pe(this,"state");pe(this,"inlineQueue");pe(this,"tokenizer");this.tokens=[],this.tokens.links=Object.create(null),this.options=t||un,this.options.tokenizer=this.options.tokenizer||new ki,this.tokenizer=this.options.tokenizer,this.tokenizer.options=this.options,this.tokenizer.lexer=this,this.inlineQueue=[],this.state={inLink:!1,inRawBlock:!1,top:!0};let n={other:je,block:_i.normal,inline:Er.normal};this.options.pedantic?(n.block=_i.pedantic,n.inline=Er.pedantic):this.options.gfm&&(n.block=_i.gfm,this.options.breaks?n.inline=Er.breaks:n.inline=Er.gfm),this.tokenizer.rules=n}static get rules(){return{block:_i,inline:Er}}static lex(t,n){return new Os(n).lex(t)}static lexInline(t,n){return new Os(n).inlineTokens(t)}lex(t){t=t.replace(je.carriageReturn,`
|
|
77
|
+
`),this.blockTokens(t,this.tokens);for(let n=0;n<this.inlineQueue.length;n++){let r=this.inlineQueue[n];this.inlineTokens(r.src,r.tokens)}return this.inlineQueue=[],this.tokens}blockTokens(t,n=[],r=!1){for(this.options.pedantic&&(t=t.replace(je.tabCharGlobal," ").replace(je.spaceLine,""));t;){let i;if(this.options.extensions?.block?.some(s=>(i=s.call({lexer:this},t,n))?(t=t.substring(i.raw.length),n.push(i),!0):!1))continue;if(i=this.tokenizer.space(t)){t=t.substring(i.raw.length);let s=n.at(-1);i.raw.length===1&&s!==void 0?s.raw+=`
|
|
74
78
|
`:n.push(i);continue}if(i=this.tokenizer.code(t)){t=t.substring(i.raw.length);let s=n.at(-1);s?.type==="paragraph"||s?.type==="text"?(s.raw+=(s.raw.endsWith(`
|
|
75
79
|
`)?"":`
|
|
76
80
|
`)+i.raw,s.text+=`
|
|
@@ -83,9 +87,9 @@ ${f}`:f;let d=this.lexer.state.top;if(this.lexer.state.top=!0,this.lexer.blockTo
|
|
|
83
87
|
`+i.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=s.text):n.push(i),r=a.length!==t.length,t=t.substring(i.raw.length);continue}if(i=this.tokenizer.text(t)){t=t.substring(i.raw.length);let s=n.at(-1);s?.type==="text"?(s.raw+=(s.raw.endsWith(`
|
|
84
88
|
`)?"":`
|
|
85
89
|
`)+i.raw,s.text+=`
|
|
86
|
-
`+i.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=s.text):n.push(i);continue}if(t){let s="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent)break;throw new Error(s)}}return this.state.top=!0,n}inline(t,n=[]){return this.inlineQueue.push({src:t,tokens:n}),n}inlineTokens(t,n=[]){let r=t,i=null;if(this.tokens.links){let u=Object.keys(this.tokens.links);if(u.length>0)for(;(i=this.tokenizer.rules.inline.reflinkSearch.exec(r))!=null;)u.includes(i[0].slice(i[0].lastIndexOf("[")+1,-1))&&(r=r.slice(0,i.index)+"["+"a".repeat(i[0].length-2)+"]"+r.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(i=this.tokenizer.rules.inline.anyPunctuation.exec(r))!=null;)r=r.slice(0,i.index)+"++"+r.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);let a;for(;(i=this.tokenizer.rules.inline.blockSkip.exec(r))!=null;)a=i[2]?i[2].length:0,r=r.slice(0,i.index+a)+"["+"a".repeat(i[0].length-a-2)+"]"+r.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);r=this.options.hooks?.emStrongMask?.call({lexer:this},r)??r;let s=!1,o="";for(;t;){s||(o=""),s=!1;let u;if(this.options.extensions?.inline?.some(f=>(u=f.call({lexer:this},t,n))?(t=t.substring(u.raw.length),n.push(u),!0):!1))continue;if(u=this.tokenizer.escape(t)){t=t.substring(u.raw.length),n.push(u);continue}if(u=this.tokenizer.tag(t)){t=t.substring(u.raw.length),n.push(u);continue}if(u=this.tokenizer.link(t)){t=t.substring(u.raw.length),n.push(u);continue}if(u=this.tokenizer.reflink(t,this.tokens.links)){t=t.substring(u.raw.length);let f=n.at(-1);u.type==="text"&&f?.type==="text"?(f.raw+=u.raw,f.text+=u.text):n.push(u);continue}if(u=this.tokenizer.emStrong(t,r,o)){t=t.substring(u.raw.length),n.push(u);continue}if(u=this.tokenizer.codespan(t)){t=t.substring(u.raw.length),n.push(u);continue}if(u=this.tokenizer.br(t)){t=t.substring(u.raw.length),n.push(u);continue}if(u=this.tokenizer.del(t)){t=t.substring(u.raw.length),n.push(u);continue}if(u=this.tokenizer.autolink(t)){t=t.substring(u.raw.length),n.push(u);continue}if(!this.state.inLink&&(u=this.tokenizer.url(t))){t=t.substring(u.raw.length),n.push(u);continue}let c=t;if(this.options.extensions?.startInline){let f=1/0,d=t.slice(1),h;this.options.extensions.startInline.forEach(p=>{h=p.call({lexer:this},d),typeof h=="number"&&h>=0&&(f=Math.min(f,h))}),f<1/0&&f>=0&&(c=t.substring(0,f+1))}if(u=this.tokenizer.inlineText(c)){t=t.substring(u.raw.length),u.raw.slice(-1)!=="_"&&(o=u.raw.slice(-1)),s=!0;let f=n.at(-1);f?.type==="text"?(f.raw+=u.raw,f.text+=u.text):n.push(u);continue}if(t){let f="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent)break;throw new Error(f)}}return n}},
|
|
87
|
-
`;return r?'<pre><code class="language-'+
|
|
88
|
-
`:"<pre><code>"+(n?i:
|
|
90
|
+
`+i.text,this.inlineQueue.pop(),this.inlineQueue.at(-1).src=s.text):n.push(i);continue}if(t){let s="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent)break;throw new Error(s)}}return this.state.top=!0,n}inline(t,n=[]){return this.inlineQueue.push({src:t,tokens:n}),n}inlineTokens(t,n=[]){let r=t,i=null;if(this.tokens.links){let u=Object.keys(this.tokens.links);if(u.length>0)for(;(i=this.tokenizer.rules.inline.reflinkSearch.exec(r))!=null;)u.includes(i[0].slice(i[0].lastIndexOf("[")+1,-1))&&(r=r.slice(0,i.index)+"["+"a".repeat(i[0].length-2)+"]"+r.slice(this.tokenizer.rules.inline.reflinkSearch.lastIndex))}for(;(i=this.tokenizer.rules.inline.anyPunctuation.exec(r))!=null;)r=r.slice(0,i.index)+"++"+r.slice(this.tokenizer.rules.inline.anyPunctuation.lastIndex);let a;for(;(i=this.tokenizer.rules.inline.blockSkip.exec(r))!=null;)a=i[2]?i[2].length:0,r=r.slice(0,i.index+a)+"["+"a".repeat(i[0].length-a-2)+"]"+r.slice(this.tokenizer.rules.inline.blockSkip.lastIndex);r=this.options.hooks?.emStrongMask?.call({lexer:this},r)??r;let s=!1,o="";for(;t;){s||(o=""),s=!1;let u;if(this.options.extensions?.inline?.some(f=>(u=f.call({lexer:this},t,n))?(t=t.substring(u.raw.length),n.push(u),!0):!1))continue;if(u=this.tokenizer.escape(t)){t=t.substring(u.raw.length),n.push(u);continue}if(u=this.tokenizer.tag(t)){t=t.substring(u.raw.length),n.push(u);continue}if(u=this.tokenizer.link(t)){t=t.substring(u.raw.length),n.push(u);continue}if(u=this.tokenizer.reflink(t,this.tokens.links)){t=t.substring(u.raw.length);let f=n.at(-1);u.type==="text"&&f?.type==="text"?(f.raw+=u.raw,f.text+=u.text):n.push(u);continue}if(u=this.tokenizer.emStrong(t,r,o)){t=t.substring(u.raw.length),n.push(u);continue}if(u=this.tokenizer.codespan(t)){t=t.substring(u.raw.length),n.push(u);continue}if(u=this.tokenizer.br(t)){t=t.substring(u.raw.length),n.push(u);continue}if(u=this.tokenizer.del(t,r,o)){t=t.substring(u.raw.length),n.push(u);continue}if(u=this.tokenizer.autolink(t)){t=t.substring(u.raw.length),n.push(u);continue}if(!this.state.inLink&&(u=this.tokenizer.url(t))){t=t.substring(u.raw.length),n.push(u);continue}let c=t;if(this.options.extensions?.startInline){let f=1/0,d=t.slice(1),h;this.options.extensions.startInline.forEach(p=>{h=p.call({lexer:this},d),typeof h=="number"&&h>=0&&(f=Math.min(f,h))}),f<1/0&&f>=0&&(c=t.substring(0,f+1))}if(u=this.tokenizer.inlineText(c)){t=t.substring(u.raw.length),u.raw.slice(-1)!=="_"&&(o=u.raw.slice(-1)),s=!0;let f=n.at(-1);f?.type==="text"?(f.raw+=u.raw,f.text+=u.text):n.push(u);continue}if(t){let f="Infinite loop on byte: "+t.charCodeAt(0);if(this.options.silent)break;throw new Error(f)}}return n}},xi=class{constructor(e){pe(this,"options");pe(this,"parser");this.options=e||un}space(e){return""}code({text:e,lang:t,escaped:n}){let r=(t||"").match(je.notSpaceStart)?.[0],i=e.replace(je.endingNewline,"")+`
|
|
91
|
+
`;return r?'<pre><code class="language-'+Tt(r)+'">'+(n?i:Tt(i,!0))+`</code></pre>
|
|
92
|
+
`:"<pre><code>"+(n?i:Tt(i,!0))+`</code></pre>
|
|
89
93
|
`}blockquote({tokens:e}){return`<blockquote>
|
|
90
94
|
${this.parser.parse(e)}</blockquote>
|
|
91
95
|
`}html({text:e}){return e}def(e){return""}heading({tokens:e,depth:t}){return`<h${t}>${this.parser.parseInline(e)}</h${t}>
|
|
@@ -101,22 +105,25 @@ ${this.parser.parse(e)}</blockquote>
|
|
|
101
105
|
`}tablerow({text:e}){return`<tr>
|
|
102
106
|
${e}</tr>
|
|
103
107
|
`}tablecell(e){let t=this.parser.parseInline(e.tokens),n=e.header?"th":"td";return(e.align?`<${n} align="${e.align}">`:`<${n}>`)+t+`</${n}>
|
|
104
|
-
`}strong({tokens:e}){return`<strong>${this.parser.parseInline(e)}</strong>`}em({tokens:e}){return`<em>${this.parser.parseInline(e)}</em>`}codespan({text:e}){return`<code>${
|
|
105
|
-
Please report this to https://github.com/markedjs/marked.`,t){let i="<p>An error occurred:</p><pre>"+xt(r.message+"",!0)+"</pre>";return n?Promise.resolve(i):i}if(n)return Promise.reject(r);throw r}}},nn=new Ok;function ke(e,t){return nn.parse(e,t)}ke.options=ke.setOptions=function(e){return nn.setOptions(e),ke.defaults=nn.defaults,ld(ke.defaults),ke},ke.getDefaults=Ja,ke.defaults=tn,ke.use=function(...e){return nn.use(...e),ke.defaults=nn.defaults,ld(ke.defaults),ke},ke.walkTokens=function(e,t){return nn.walkTokens(e,t)},ke.parseInline=nn.parseInline,ke.Parser=bt,ke.parser=bt.parse,ke.Renderer=mi,ke.TextRenderer=us,ke.Lexer=lt,ke.lexer=lt.lex,ke.Tokenizer=pi,ke.Hooks=dr,ke.parse=ke;var Dk=300,Pk="300px",Mk=500;function Bk(e={}){let{immediate:t=!1,debounceDelay:n=Dk,rootMargin:r=Pk,idleTimeout:i=Mk}=e,[a,s]=le(!1),o=Le(null),u=Le(null),c=Le(null),f=Ie(()=>p=>{let m=Date.now();return window.setTimeout(()=>{p({didTimeout:!1,timeRemaining:()=>Math.max(0,50-(Date.now()-m))})},1)},[]),d=Ie(()=>typeof window<"u"&&window.requestIdleCallback?(p,m)=>window.requestIdleCallback(p,m):f,[f]),h=Ie(()=>typeof window<"u"&&window.cancelIdleCallback?p=>window.cancelIdleCallback(p):p=>{clearTimeout(p)},[]);return we(()=>{if(t){s(!0);return}let p=o.current;if(!p)return;u.current&&(clearTimeout(u.current),u.current=null),c.current&&(h(c.current),c.current=null);let m=()=>{u.current&&(clearTimeout(u.current),u.current=null),c.current&&(h(c.current),c.current=null)},_=S=>{c.current=d(D=>{D.timeRemaining()>0||D.didTimeout?(s(!0),S.disconnect()):c.current=d(()=>{s(!0),S.disconnect()},{timeout:i/2})},{timeout:i})},A=S=>{m(),u.current=window.setTimeout(()=>{var D,P;let w=S.takeRecords();(w.length===0||(P=(D=w.at(-1))==null?void 0:D.isIntersecting)!=null&&P)&&_(S)},n)},y=(S,D)=>{S.isIntersecting?A(D):m()},I=new IntersectionObserver(S=>{for(let D of S)y(D,I)},{rootMargin:r,threshold:0});return I.observe(p),()=>{u.current&&clearTimeout(u.current),c.current&&h(c.current),I.disconnect()}},[t,n,r,i,h,d]),{shouldRender:a,containerRef:o}}var ls=e=>b("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:b("path",{clipRule:"evenodd",d:"M15.5607 3.99999L15.0303 4.53032L6.23744 13.3232C5.55403 14.0066 4.44599 14.0066 3.76257 13.3232L4.2929 12.7929L3.76257 13.3232L0.969676 10.5303L0.439346 9.99999L1.50001 8.93933L2.03034 9.46966L4.82323 12.2626C4.92086 12.3602 5.07915 12.3602 5.17678 12.2626L13.9697 3.46966L14.5 2.93933L15.5607 3.99999Z",fill:"currentColor",fillRule:"evenodd"})}),cs=e=>b("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:b("path",{clipRule:"evenodd",d:"M2.75 0.5C1.7835 0.5 1 1.2835 1 2.25V9.75C1 10.7165 1.7835 11.5 2.75 11.5H3.75H4.5V10H3.75H2.75C2.61193 10 2.5 9.88807 2.5 9.75V2.25C2.5 2.11193 2.61193 2 2.75 2H8.25C8.38807 2 8.5 2.11193 8.5 2.25V3H10V2.25C10 1.2835 9.2165 0.5 8.25 0.5H2.75ZM7.75 4.5C6.7835 4.5 6 5.2835 6 6.25V13.75C6 14.7165 6.7835 15.5 7.75 15.5H13.25C14.2165 15.5 15 14.7165 15 13.75V6.25C15 5.2835 14.2165 4.5 13.25 4.5H7.75ZM7.5 6.25C7.5 6.11193 7.61193 6 7.75 6H13.25C13.3881 6 13.5 6.11193 13.5 6.25V13.75C13.5 13.8881 13.3881 14 13.25 14H7.75C7.61193 14 7.5 13.8881 7.5 13.75V6.25Z",fill:"currentColor",fillRule:"evenodd"})}),gi=e=>b("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:b("path",{clipRule:"evenodd",d:"M8.75 1V1.75V8.68934L10.7197 6.71967L11.25 6.18934L12.3107 7.25L11.7803 7.78033L8.70711 10.8536C8.31658 11.2441 7.68342 11.2441 7.29289 10.8536L4.21967 7.78033L3.68934 7.25L4.75 6.18934L5.28033 6.71967L7.25 8.68934V1.75V1H8.75ZM13.5 9.25V13.5H2.5V9.25V8.5H1V9.25V14C1 14.5523 1.44771 15 2 15H14C14.5523 15 15 14.5523 15 14V9.25V8.5H13.5V9.25Z",fill:"currentColor",fillRule:"evenodd"})}),Fk=e=>b("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:[b("path",{d:"M8 0V4",stroke:"currentColor",strokeWidth:"1.5"}),b("path",{d:"M8 16V12",opacity:"0.5",stroke:"currentColor",strokeWidth:"1.5"}),b("path",{d:"M3.29773 1.52783L5.64887 4.7639",opacity:"0.9",stroke:"currentColor",strokeWidth:"1.5"}),b("path",{d:"M12.7023 1.52783L10.3511 4.7639",opacity:"0.1",stroke:"currentColor",strokeWidth:"1.5"}),b("path",{d:"M12.7023 14.472L10.3511 11.236",opacity:"0.4",stroke:"currentColor",strokeWidth:"1.5"}),b("path",{d:"M3.29773 14.472L5.64887 11.236",opacity:"0.6",stroke:"currentColor",strokeWidth:"1.5"}),b("path",{d:"M15.6085 5.52783L11.8043 6.7639",opacity:"0.2",stroke:"currentColor",strokeWidth:"1.5"}),b("path",{d:"M0.391602 10.472L4.19583 9.23598",opacity:"0.7",stroke:"currentColor",strokeWidth:"1.5"}),b("path",{d:"M15.6085 10.4722L11.8043 9.2361",opacity:"0.3",stroke:"currentColor",strokeWidth:"1.5"}),b("path",{d:"M0.391602 5.52783L4.19583 6.7639",opacity:"0.8",stroke:"currentColor",strokeWidth:"1.5"})]}),Hk=e=>b("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:b("path",{clipRule:"evenodd",d:"M1 5.25V6H2.5V5.25V2.5H5.25H6V1H5.25H2C1.44772 1 1 1.44772 1 2V5.25ZM5.25 14.9994H6V13.4994H5.25H2.5V10.7494V9.99939H1V10.7494V13.9994C1 14.5517 1.44772 14.9994 2 14.9994H5.25ZM15 10V10.75V14C15 14.5523 14.5523 15 14 15H10.75H10V13.5H10.75H13.5V10.75V10H15ZM10.75 1H10V2.5H10.75H13.5V5.25V6H15V5.25V2C15 1.44772 14.5523 1 14 1H10.75Z",fill:"currentColor",fillRule:"evenodd"})}),Uk=e=>b("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:b("path",{clipRule:"evenodd",d:"M13.5 8C13.5 4.96643 11.0257 2.5 7.96452 2.5C5.42843 2.5 3.29365 4.19393 2.63724 6.5H5.25H6V8H5.25H0.75C0.335787 8 0 7.66421 0 7.25V2.75V2H1.5V2.75V5.23347C2.57851 2.74164 5.06835 1 7.96452 1C11.8461 1 15 4.13001 15 8C15 11.87 11.8461 15 7.96452 15C5.62368 15 3.54872 13.8617 2.27046 12.1122L1.828 11.5066L3.03915 10.6217L3.48161 11.2273C4.48831 12.6051 6.12055 13.5 7.96452 13.5C11.0257 13.5 13.5 11.0336 13.5 8Z",fill:"currentColor",fillRule:"evenodd"})}),Cd=e=>b("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:b("path",{clipRule:"evenodd",d:"M12.4697 13.5303L13 14.0607L14.0607 13L13.5303 12.4697L9.06065 7.99999L13.5303 3.53032L14.0607 2.99999L13 1.93933L12.4697 2.46966L7.99999 6.93933L3.53032 2.46966L2.99999 1.93933L1.93933 2.99999L2.46966 3.53032L6.93933 7.99999L2.46966 12.4697L1.93933 13L2.99999 14.0607L3.53032 13.5303L7.99999 9.06065L12.4697 13.5303Z",fill:"currentColor",fillRule:"evenodd"})}),Sd=e=>b("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:b("path",{clipRule:"evenodd",d:"M13.5 10.25V13.25C13.5 13.3881 13.3881 13.5 13.25 13.5H2.75C2.61193 13.5 2.5 13.3881 2.5 13.25L2.5 2.75C2.5 2.61193 2.61193 2.5 2.75 2.5H5.75H6.5V1H5.75H2.75C1.7835 1 1 1.7835 1 2.75V13.25C1 14.2165 1.7835 15 2.75 15H13.25C14.2165 15 15 14.2165 15 13.25V10.25V9.5H13.5V10.25ZM9 1H9.75H14.2495C14.6637 1 14.9995 1.33579 14.9995 1.75V6.25V7H13.4995V6.25V3.56066L8.53033 8.52978L8 9.06011L6.93934 7.99945L7.46967 7.46912L12.4388 2.5H9.75H9V1Z",fill:"currentColor",fillRule:"evenodd"})}),zk=e=>b("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:b("path",{clipRule:"evenodd",d:"M1.5 6.5C1.5 3.73858 3.73858 1.5 6.5 1.5C9.26142 1.5 11.5 3.73858 11.5 6.5C11.5 9.26142 9.26142 11.5 6.5 11.5C3.73858 11.5 1.5 9.26142 1.5 6.5ZM6.5 0C2.91015 0 0 2.91015 0 6.5C0 10.0899 2.91015 13 6.5 13C8.02469 13 9.42677 12.475 10.5353 11.596L13.9697 15.0303L14.5 15.5607L15.5607 14.5L15.0303 13.9697L11.596 10.5353C12.475 9.42677 13 8.02469 13 6.5C13 2.91015 10.0899 0 6.5 0ZM4.125 5.875H4.75H5.875V4.75V4.125H7.125V4.75V5.875H8.25H8.875V7.125H8.25H7.125V8.25V8.875H5.875V8.25V7.125H4.75H4.125V5.875Z",fill:"currentColor",fillRule:"evenodd"})}),$k=e=>b("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:b("path",{clipRule:"evenodd",d:"M15.5607 3.99999L15.0303 4.53032L6.23744 13.3232C5.55403 14.0066 4.44599 14.0066 3.76257 13.3232L4.2929 12.7929L3.76257 13.3232L0.969676 10.5303L0.439346 9.99999L1.50001 8.93933L2.03034 9.46966L4.82323 12.2626C4.92086 12.3602 5.07915 12.3602 5.17678 12.2626L13.9697 3.46966L14.5 2.93933L15.5607 3.99999Z",fill:"currentColor",fillRule:"evenodd"})}),K=(...e)=>S3(UE(e)),Cn=(e,t,n)=>{let r=typeof t=="string"?new Blob([t],{type:n}):t,i=URL.createObjectURL(r),a=document.createElement("a");a.href=i,a.download=e,document.body.appendChild(a),a.click(),document.body.removeChild(a),URL.revokeObjectURL(i)},Id=Ii({code:""}),Nd=()=>Ge(Id),vd=({onCopy:e,onError:t,timeout:n=2e3,children:r,className:i,code:a,...s})=>{let[o,u]=le(!1),c=Le(0),{code:f}=Nd(),{isAnimating:d}=Ge(Ze),h=a??f,p=async()=>{var _;if(typeof window>"u"||!((_=navigator?.clipboard)!=null&&_.writeText)){t?.(new Error("Clipboard API not available"));return}try{o||(await navigator.clipboard.writeText(h),u(!0),e?.(),c.current=window.setTimeout(()=>u(!1),n))}catch(A){t?.(A)}};we(()=>()=>{window.clearTimeout(c.current)},[]);let m=o?ls:cs;return b("button",{className:K("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",i),"data-streamdown":"code-block-copy-button",disabled:d,onClick:p,title:"Copy Code",type:"button",...s,children:r??b(m,{size:14})})},Ld={"1c":"1c","1c-query":"1cq",abap:"abap","actionscript-3":"as",ada:"ada",adoc:"adoc","angular-html":"html","angular-ts":"ts",apache:"conf",apex:"cls",apl:"apl",applescript:"applescript",ara:"ara",asciidoc:"adoc",asm:"asm",astro:"astro",awk:"awk",ballerina:"bal",bash:"sh",bat:"bat",batch:"bat",be:"be",beancount:"beancount",berry:"berry",bibtex:"bib",bicep:"bicep",blade:"blade.php",bsl:"bsl",c:"c","c#":"cs","c++":"cpp",cadence:"cdc",cairo:"cairo",cdc:"cdc",clarity:"clar",clj:"clj",clojure:"clj","closure-templates":"soy",cmake:"cmake",cmd:"cmd",cobol:"cob",codeowners:"CODEOWNERS",codeql:"ql",coffee:"coffee",coffeescript:"coffee","common-lisp":"lisp",console:"sh",coq:"v",cpp:"cpp",cql:"cql",crystal:"cr",cs:"cs",csharp:"cs",css:"css",csv:"csv",cue:"cue",cypher:"cql",d:"d",dart:"dart",dax:"dax",desktop:"desktop",diff:"diff",docker:"dockerfile",dockerfile:"dockerfile",dotenv:"env","dream-maker":"dm",edge:"edge",elisp:"el",elixir:"ex",elm:"elm","emacs-lisp":"el",erb:"erb",erl:"erl",erlang:"erl",f:"f","f#":"fs",f03:"f03",f08:"f08",f18:"f18",f77:"f77",f90:"f90",f95:"f95",fennel:"fnl",fish:"fish",fluent:"ftl",for:"for","fortran-fixed-form":"f","fortran-free-form":"f90",fs:"fs",fsharp:"fs",fsl:"fsl",ftl:"ftl",gdresource:"tres",gdscript:"gd",gdshader:"gdshader",genie:"gs",gherkin:"feature","git-commit":"gitcommit","git-rebase":"gitrebase",gjs:"js",gleam:"gleam","glimmer-js":"js","glimmer-ts":"ts",glsl:"glsl",gnuplot:"plt",go:"go",gql:"gql",graphql:"graphql",groovy:"groovy",gts:"gts",hack:"hack",haml:"haml",handlebars:"hbs",haskell:"hs",haxe:"hx",hbs:"hbs",hcl:"hcl",hjson:"hjson",hlsl:"hlsl",hs:"hs",html:"html","html-derivative":"html",http:"http",hxml:"hxml",hy:"hy",imba:"imba",ini:"ini",jade:"jade",java:"java",javascript:"js",jinja:"jinja",jison:"jison",jl:"jl",js:"js",json:"json",json5:"json5",jsonc:"jsonc",jsonl:"jsonl",jsonnet:"jsonnet",jssm:"jssm",jsx:"jsx",julia:"jl",kotlin:"kt",kql:"kql",kt:"kt",kts:"kts",kusto:"kql",latex:"tex",lean:"lean",lean4:"lean",less:"less",liquid:"liquid",lisp:"lisp",lit:"lit",llvm:"ll",log:"log",logo:"logo",lua:"lua",luau:"luau",make:"mak",makefile:"mak",markdown:"md",marko:"marko",matlab:"m",md:"md",mdc:"mdc",mdx:"mdx",mediawiki:"wiki",mermaid:"mmd",mips:"s",mipsasm:"s",mmd:"mmd",mojo:"mojo",move:"move",nar:"nar",narrat:"narrat",nextflow:"nf",nf:"nf",nginx:"conf",nim:"nim",nix:"nix",nu:"nu",nushell:"nu",objc:"m","objective-c":"m","objective-cpp":"mm",ocaml:"ml",pascal:"pas",perl:"pl",perl6:"p6",php:"php",plsql:"pls",po:"po",polar:"polar",postcss:"pcss",pot:"pot",potx:"potx",powerquery:"pq",powershell:"ps1",prisma:"prisma",prolog:"pl",properties:"properties",proto:"proto",protobuf:"proto",ps:"ps",ps1:"ps1",pug:"pug",puppet:"pp",purescript:"purs",py:"py",python:"py",ql:"ql",qml:"qml",qmldir:"qmldir",qss:"qss",r:"r",racket:"rkt",raku:"raku",razor:"cshtml",rb:"rb",reg:"reg",regex:"regex",regexp:"regexp",rel:"rel",riscv:"s",rs:"rs",rst:"rst",ruby:"rb",rust:"rs",sas:"sas",sass:"sass",scala:"scala",scheme:"scm",scss:"scss",sdbl:"sdbl",sh:"sh",shader:"shader",shaderlab:"shader",shell:"sh",shellscript:"sh",shellsession:"sh",smalltalk:"st",solidity:"sol",soy:"soy",sparql:"rq",spl:"spl",splunk:"spl",sql:"sql","ssh-config":"config",stata:"do",styl:"styl",stylus:"styl",svelte:"svelte",swift:"swift","system-verilog":"sv",systemd:"service",talon:"talon",talonscript:"talon",tasl:"tasl",tcl:"tcl",templ:"templ",terraform:"tf",tex:"tex",tf:"tf",tfvars:"tfvars",toml:"toml",ts:"ts","ts-tags":"ts",tsp:"tsp",tsv:"tsv",tsx:"tsx",turtle:"ttl",twig:"twig",typ:"typ",typescript:"ts",typespec:"tsp",typst:"typ",v:"v",vala:"vala",vb:"vb",verilog:"v",vhdl:"vhdl",vim:"vim",viml:"vim",vimscript:"vim",vue:"vue","vue-html":"html","vue-vine":"vine",vy:"vy",vyper:"vy",wasm:"wasm",wenyan:"wy",wgsl:"wgsl",wiki:"wiki",wikitext:"wiki",wit:"wit",wl:"wl",wolfram:"wl",xml:"xml",xsl:"xsl",yaml:"yaml",yml:"yml",zenscript:"zs",zig:"zig",zsh:"zsh",文言:"wy"},Yk=({onDownload:e,onError:t,language:n,children:r,className:i,code:a,...s})=>{let{code:o}=Nd(),{isAnimating:u}=Ge(Ze),c=a??o,f=`file.${n&&n in Ld?Ld[n]:"txt"}`,d="text/plain",h=()=>{try{Cn(f,c,d),e?.()}catch(p){t?.(p)}};return b("button",{className:K("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",i),"data-streamdown":"code-block-download-button",disabled:u,onClick:h,title:"Download file",type:"button",...s,children:r??b(gi,{size:14})})},Rd=()=>b("div",{className:"w-full divide-y divide-border overflow-hidden rounded-xl border border-border",children:[b("div",{className:"h-[46px] w-full bg-muted/80"}),b("div",{className:"flex w-full items-center justify-center p-4",children:b(Fk,{className:"size-4 animate-spin"})})]}),jk=/\.[^/.]+$/,Vk=({node:e,className:t,src:n,alt:r,...i})=>{let a=async()=>{if(n)try{let s=await(await fetch(n)).blob(),o=new URL(n,window.location.origin).pathname.split("/").pop()||"",u=o.split(".").pop(),c=o.includes(".")&&u!==void 0&&u.length<=4,f="";if(c)f=o;else{let d=s.type,h="png";d.includes("jpeg")||d.includes("jpg")?h="jpg":d.includes("png")?h="png":d.includes("svg")?h="svg":d.includes("gif")?h="gif":d.includes("webp")&&(h="webp"),f=`${(r||o||"image").replace(jk,"")}.${h}`}Cn(f,s,s.type)}catch{window.open(n,"_blank")}};return n?b("div",{className:"group relative my-4 inline-block","data-streamdown":"image-wrapper",children:[b("img",{alt:r,className:K("max-w-full rounded-lg",t),"data-streamdown":"image",src:n,...i}),b("div",{className:"pointer-events-none absolute inset-0 hidden rounded-lg bg-black/10 group-hover:block"}),b("button",{className:K("absolute right-2 bottom-2 flex h-8 w-8 cursor-pointer items-center justify-center rounded-md border border-border bg-background/90 shadow-sm backdrop-blur-sm transition-all duration-200 hover:bg-background","opacity-0 group-hover:opacity-100"),onClick:a,title:"Download image",type:"button",children:b(gi,{size:14})})]}):null},fr=0,qk=()=>{fr+=1,fr===1&&(document.body.style.overflow="hidden")},Wk=()=>{fr=Math.max(0,fr-1),fr===0&&(document.body.style.overflow="")},Gk=({url:e,isOpen:t,onClose:n,onConfirm:r})=>{let[i,a]=le(!1),s=Pe(async()=>{try{await navigator.clipboard.writeText(e),a(!0),setTimeout(()=>a(!1),2e3)}catch{}},[e]),o=Pe(()=>{r(),n()},[r,n]);return we(()=>{if(t){qk();let u=c=>{c.key==="Escape"&&n()};return document.addEventListener("keydown",u),()=>{document.removeEventListener("keydown",u),Wk()}}},[t,n]),t?b("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-background/50 backdrop-blur-sm","data-streamdown":"link-safety-modal",onClick:n,onKeyDown:u=>{u.key==="Escape"&&n()},role:"button",tabIndex:0,children:b("div",{className:"relative mx-4 flex w-full max-w-md flex-col gap-4 rounded-xl border bg-background p-6 shadow-lg",onClick:u=>u.stopPropagation(),onKeyDown:u=>u.stopPropagation(),role:"presentation",children:[b("button",{className:"absolute top-4 right-4 rounded-md p-1 text-muted-foreground transition-all hover:bg-muted hover:text-foreground",onClick:n,title:"Close",type:"button",children:b(Cd,{size:16})}),b("div",{className:"flex flex-col gap-2",children:[b("div",{className:"flex items-center gap-2 font-semibold text-lg",children:[b(Sd,{size:20}),b("span",{children:"Open external link?"})]}),b("p",{className:"text-muted-foreground text-sm",children:"You're about to visit an external website."})]}),b("div",{className:K("break-all rounded-md bg-muted p-3 font-mono text-sm",e.length>100&&"max-h-32 overflow-y-auto"),children:e}),b("div",{className:"flex gap-2",children:[b("button",{className:"flex flex-1 items-center justify-center gap-2 rounded-md border bg-background px-4 py-2 font-medium text-sm transition-all hover:bg-muted",onClick:s,type:"button",children:i?b(Ue,{children:[b(ls,{size:14}),b("span",{children:"Copied"})]}):b(Ue,{children:[b(cs,{size:14}),b("span",{children:"Copy link"})]})}),b("button",{className:"flex flex-1 items-center justify-center gap-2 rounded-md bg-primary px-4 py-2 font-medium text-primary-foreground text-sm transition-all hover:bg-primary/90",onClick:o,type:"button",children:[b(Sd,{size:14}),b("span",{children:"Open link"})]})]})]})}):null},ds=Ii(null),Od=()=>Ge(ds),Qk=()=>{var e;let t=Od();return(e=t?.code)!=null?e:null},fs=()=>{var e;let t=Od();return(e=t?.mermaid)!=null?e:null},Kk=(e,t)=>{var n;let r=(n=void 0)!=null?n:5;return new Promise((i,a)=>{let s="data:image/svg+xml;base64,"+btoa(unescape(encodeURIComponent(e))),o=new Image;o.crossOrigin="anonymous",o.onload=()=>{let u=document.createElement("canvas"),c=o.width*r,f=o.height*r;u.width=c,u.height=f;let d=u.getContext("2d");if(!d){a(new Error("Failed to create 2D canvas context for PNG export"));return}d.drawImage(o,0,0,c,f),u.toBlob(h=>{if(!h){a(new Error("Failed to create PNG blob"));return}i(h)},"image/png")},o.onerror=()=>a(new Error("Failed to load SVG image")),o.src=s})},Xk=({chart:e,children:t,className:n,onDownload:r,config:i,onError:a})=>{let[s,o]=le(!1),u=Le(null),{isAnimating:c}=Ge(Ze),f=fs(),d=async h=>{try{if(h==="mmd"){Cn("diagram.mmd",e,"text/plain"),o(!1),r?.(h);return}if(!f){a?.(new Error("Mermaid plugin not available"));return}let p=f.getMermaid(i),m=e.split("").reduce((y,I)=>(y<<5)-y+I.charCodeAt(0)|0,0),_=`mermaid-${Math.abs(m)}-${Date.now()}-${Math.random().toString(36).substring(2,9)}`,{svg:A}=await p.render(_,e);if(!A){a?.(new Error("SVG not found. Please wait for the diagram to render."));return}if(h==="svg"){Cn("diagram.svg",A,"image/svg+xml"),o(!1),r?.(h);return}if(h==="png"){let y=await Kk(A);Cn("diagram.png",y,"image/png"),r?.(h),o(!1);return}}catch(p){a?.(p)}};return we(()=>{let h=p=>{let m=p.composedPath();u.current&&!m.includes(u.current)&&o(!1)};return document.addEventListener("mousedown",h),()=>{document.removeEventListener("mousedown",h)}},[]),b("div",{className:"relative",ref:u,children:[b("button",{className:K("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",n),disabled:c,onClick:()=>o(!s),title:"Download diagram",type:"button",children:t??b(gi,{size:14})}),s?b("div",{className:"absolute top-full right-0 z-10 mt-1 min-w-[120px] overflow-hidden rounded-md border border-border bg-background shadow-lg",children:[b("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>d("svg"),title:"Download diagram as SVG",type:"button",children:"SVG"}),b("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>d("png"),title:"Download diagram as PNG",type:"button",children:"PNG"}),b("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>d("mmd"),title:"Download diagram as MMD",type:"button",children:"MMD"})]}):null]})},hr=0,Zk=()=>{hr+=1,hr===1&&(document.body.style.overflow="hidden")},Jk=()=>{hr=Math.max(0,hr-1),hr===0&&(document.body.style.overflow="")},ex=({chart:e,config:t,onFullscreen:n,onExit:r,className:i,...a})=>{let[s,o]=le(!1),{isAnimating:u,controls:c}=Ge(Ze),f=(()=>{if(typeof c=="boolean")return c;let h=c.mermaid;return h===!1?!1:h===!0||h===void 0?!0:h.panZoom!==!1})(),d=()=>{o(!s)};return we(()=>{if(s){Zk();let h=p=>{p.key==="Escape"&&o(!1)};return document.addEventListener("keydown",h),()=>{document.removeEventListener("keydown",h),Jk()}}},[s]),we(()=>{s?n?.():r&&r()},[s,n,r]),b(Ue,{children:[b("button",{className:K("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",i),disabled:u,onClick:d,title:"View fullscreen",type:"button",...a,children:b(Hk,{size:14})}),s?b("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-background/95 backdrop-blur-sm",onClick:d,onKeyDown:h=>{h.key==="Escape"&&d()},role:"button",tabIndex:0,children:[b("button",{className:"absolute top-4 right-4 z-10 rounded-md p-2 text-muted-foreground transition-all hover:bg-muted hover:text-foreground",onClick:d,title:"Exit fullscreen",type:"button",children:b(Cd,{size:20})}),b("div",{className:"flex size-full items-center justify-center p-4",onClick:h=>h.stopPropagation(),onKeyDown:h=>h.stopPropagation(),role:"presentation",children:b(f0,{chart:e,className:"size-full [&_svg]:h-auto [&_svg]:w-auto",config:t,fullscreen:!0,showControls:f})})]}):null]})},Dd=e=>{var t,n;let r=[],i=[],a=e.querySelectorAll("thead th");for(let o of a)r.push(((t=o.textContent)==null?void 0:t.trim())||"");let s=e.querySelectorAll("tbody tr");for(let o of s){let u=[],c=o.querySelectorAll("td");for(let f of c)u.push(((n=f.textContent)==null?void 0:n.trim())||"");i.push(u)}return{headers:r,rows:i}},Pd=e=>{let{headers:t,rows:n}=e,r=o=>{let u=!1,c=!1;for(let f of o){if(f==='"'){u=!0,c=!0;break}(f===","||f===`
|
|
108
|
+
`}strong({tokens:e}){return`<strong>${this.parser.parseInline(e)}</strong>`}em({tokens:e}){return`<em>${this.parser.parseInline(e)}</em>`}codespan({text:e}){return`<code>${Tt(e,!0)}</code>`}br(e){return"<br>"}del({tokens:e}){return`<del>${this.parser.parseInline(e)}</del>`}link({href:e,title:t,tokens:n}){let r=this.parser.parseInline(n),i=Md(e);if(i===null)return r;e=i;let a='<a href="'+e+'"';return t&&(a+=' title="'+Tt(t)+'"'),a+=">"+r+"</a>",a}image({href:e,title:t,text:n,tokens:r}){r&&(n=this.parser.parseInline(r,this.parser.textRenderer));let i=Md(e);if(i===null)return Tt(n);e=i;let a=`<img src="${e}" alt="${Tt(n)}"`;return t&&(a+=` title="${Tt(t)}"`),a+=">",a}text(e){return"tokens"in e&&e.tokens?this.parser.parseInline(e.tokens):"escaped"in e&&e.escaped?e.text:Tt(e.text)}},Es=class{strong({text:e}){return e}em({text:e}){return e}codespan({text:e}){return e}del({text:e}){return e}html({text:e}){return e}text({text:e}){return e}link({text:e}){return""+e}image({text:e}){return""+e}br(){return""}checkbox({raw:e}){return e}},_t=class Ds{constructor(t){pe(this,"options");pe(this,"renderer");pe(this,"textRenderer");this.options=t||un,this.options.renderer=this.options.renderer||new xi,this.renderer=this.options.renderer,this.renderer.options=this.options,this.renderer.parser=this,this.textRenderer=new Es}static parse(t,n){return new Ds(n).parse(t)}static parseInline(t,n){return new Ds(n).parseInline(t)}parse(t){let n="";for(let r=0;r<t.length;r++){let i=t[r];if(this.options.extensions?.renderers?.[i.type]){let s=i,o=this.options.extensions.renderers[s.type].call({parser:this},s);if(o!==!1||!["space","hr","heading","code","table","blockquote","list","html","def","paragraph","text"].includes(s.type)){n+=o||"";continue}}let a=i;switch(a.type){case"space":{n+=this.renderer.space(a);break}case"hr":{n+=this.renderer.hr(a);break}case"heading":{n+=this.renderer.heading(a);break}case"code":{n+=this.renderer.code(a);break}case"table":{n+=this.renderer.table(a);break}case"blockquote":{n+=this.renderer.blockquote(a);break}case"list":{n+=this.renderer.list(a);break}case"checkbox":{n+=this.renderer.checkbox(a);break}case"html":{n+=this.renderer.html(a);break}case"def":{n+=this.renderer.def(a);break}case"paragraph":{n+=this.renderer.paragraph(a);break}case"text":{n+=this.renderer.text(a);break}default:{let s='Token with "'+a.type+'" type was not found.';if(this.options.silent)return"";throw new Error(s)}}}return n}parseInline(t,n=this.renderer){let r="";for(let i=0;i<t.length;i++){let a=t[i];if(this.options.extensions?.renderers?.[a.type]){let o=this.options.extensions.renderers[a.type].call({parser:this},a);if(o!==!1||!["escape","html","link","image","strong","em","codespan","br","del","text"].includes(a.type)){r+=o||"";continue}}let s=a;switch(s.type){case"escape":{r+=n.text(s);break}case"html":{r+=n.html(s);break}case"link":{r+=n.link(s);break}case"image":{r+=n.image(s);break}case"checkbox":{r+=n.checkbox(s);break}case"strong":{r+=n.strong(s);break}case"em":{r+=n.em(s);break}case"codespan":{r+=n.codespan(s);break}case"br":{r+=n.br(s);break}case"del":{r+=n.del(s);break}case"text":{r+=n.text(s);break}default:{let o='Token with "'+s.type+'" type was not found.';if(this.options.silent)return"";throw new Error(o)}}}return r}},_r=(Ii=class{constructor(e){pe(this,"options");pe(this,"block");this.options=e||un}preprocess(e){return e}postprocess(e){return e}processAllTokens(e){return e}emStrongMask(e){return e}provideLexer(){return this.block?ut.lex:ut.lexInline}provideParser(){return this.block?_t.parse:_t.parseInline}},pe(Ii,"passThroughHooks",new Set(["preprocess","postprocess","processAllTokens","emStrongMask"])),pe(Ii,"passThroughHooksRespectAsync",new Set(["preprocess","postprocess","processAllTokens"])),Ii),Ex=class{constructor(...e){pe(this,"defaults",ls());pe(this,"options",this.setOptions);pe(this,"parse",this.parseMarkdown(!0));pe(this,"parseInline",this.parseMarkdown(!1));pe(this,"Parser",_t);pe(this,"Renderer",xi);pe(this,"TextRenderer",Es);pe(this,"Lexer",ut);pe(this,"Tokenizer",ki);pe(this,"Hooks",_r);this.use(...e)}walkTokens(e,t){let n=[];for(let r of e)switch(n=n.concat(t.call(this,r)),r.type){case"table":{let i=r;for(let a of i.header)n=n.concat(this.walkTokens(a.tokens,t));for(let a of i.rows)for(let s of a)n=n.concat(this.walkTokens(s.tokens,t));break}case"list":{let i=r;n=n.concat(this.walkTokens(i.items,t));break}default:{let i=r;this.defaults.extensions?.childTokens?.[i.type]?this.defaults.extensions.childTokens[i.type].forEach(a=>{let s=i[a].flat(1/0);n=n.concat(this.walkTokens(s,t))}):i.tokens&&(n=n.concat(this.walkTokens(i.tokens,t)))}}return n}use(...e){let t=this.defaults.extensions||{renderers:{},childTokens:{}};return e.forEach(n=>{let r={...n};if(r.async=this.defaults.async||r.async||!1,n.extensions&&(n.extensions.forEach(i=>{if(!i.name)throw new Error("extension name required");if("renderer"in i){let a=t.renderers[i.name];a?t.renderers[i.name]=function(...s){let o=i.renderer.apply(this,s);return o===!1&&(o=a.apply(this,s)),o}:t.renderers[i.name]=i.renderer}if("tokenizer"in i){if(!i.level||i.level!=="block"&&i.level!=="inline")throw new Error("extension level must be 'block' or 'inline'");let a=t[i.level];a?a.unshift(i.tokenizer):t[i.level]=[i.tokenizer],i.start&&(i.level==="block"?t.startBlock?t.startBlock.push(i.start):t.startBlock=[i.start]:i.level==="inline"&&(t.startInline?t.startInline.push(i.start):t.startInline=[i.start]))}"childTokens"in i&&i.childTokens&&(t.childTokens[i.name]=i.childTokens)}),r.extensions=t),n.renderer){let i=this.defaults.renderer||new xi(this.defaults);for(let a in n.renderer){if(!(a in i))throw new Error(`renderer '${a}' does not exist`);if(["options","parser"].includes(a))continue;let s=a,o=n.renderer[s],u=i[s];i[s]=(...c)=>{let f=o.apply(i,c);return f===!1&&(f=u.apply(i,c)),f||""}}r.renderer=i}if(n.tokenizer){let i=this.defaults.tokenizer||new ki(this.defaults);for(let a in n.tokenizer){if(!(a in i))throw new Error(`tokenizer '${a}' does not exist`);if(["options","rules","lexer"].includes(a))continue;let s=a,o=n.tokenizer[s],u=i[s];i[s]=(...c)=>{let f=o.apply(i,c);return f===!1&&(f=u.apply(i,c)),f}}r.tokenizer=i}if(n.hooks){let i=this.defaults.hooks||new _r;for(let a in n.hooks){if(!(a in i))throw new Error(`hook '${a}' does not exist`);if(["options","block"].includes(a))continue;let s=a,o=n.hooks[s],u=i[s];_r.passThroughHooks.has(a)?i[s]=c=>{if(this.defaults.async&&_r.passThroughHooksRespectAsync.has(a))return(async()=>{let d=await o.call(i,c);return u.call(i,d)})();let f=o.call(i,c);return u.call(i,f)}:i[s]=(...c)=>{if(this.defaults.async)return(async()=>{let d=await o.apply(i,c);return d===!1&&(d=await u.apply(i,c)),d})();let f=o.apply(i,c);return f===!1&&(f=u.apply(i,c)),f}}r.hooks=i}if(n.walkTokens){let i=this.defaults.walkTokens,a=n.walkTokens;r.walkTokens=function(s){let o=[];return o.push(a.call(this,s)),i&&(o=o.concat(i.call(this,s))),o}}this.defaults={...this.defaults,...r}}),this}setOptions(e){return this.defaults={...this.defaults,...e},this}lexer(e,t){return ut.lex(e,t??this.defaults)}parser(e,t){return _t.parse(e,t??this.defaults)}parseMarkdown(e){return(t,n)=>{let r={...n},i={...this.defaults,...r},a=this.onError(!!i.silent,!!i.async);if(this.defaults.async===!0&&r.async===!1)return a(new Error("marked(): The async option was set to true by an extension. Remove async: false from the parse options object to return a Promise."));if(typeof t>"u"||t===null)return a(new Error("marked(): input parameter is undefined or null"));if(typeof t!="string")return a(new Error("marked(): input parameter is of type "+Object.prototype.toString.call(t)+", string expected"));if(i.hooks&&(i.hooks.options=i,i.hooks.block=e),i.async)return(async()=>{let s=i.hooks?await i.hooks.preprocess(t):t,o=await(i.hooks?await i.hooks.provideLexer():e?ut.lex:ut.lexInline)(s,i),u=i.hooks?await i.hooks.processAllTokens(o):o;i.walkTokens&&await Promise.all(this.walkTokens(u,i.walkTokens));let c=await(i.hooks?await i.hooks.provideParser():e?_t.parse:_t.parseInline)(u,i);return i.hooks?await i.hooks.postprocess(c):c})().catch(a);try{i.hooks&&(t=i.hooks.preprocess(t));let s=(i.hooks?i.hooks.provideLexer():e?ut.lex:ut.lexInline)(t,i);i.hooks&&(s=i.hooks.processAllTokens(s)),i.walkTokens&&this.walkTokens(s,i.walkTokens);let o=(i.hooks?i.hooks.provideParser():e?_t.parse:_t.parseInline)(s,i);return i.hooks&&(o=i.hooks.postprocess(o)),o}catch(s){return a(s)}}}onError(e,t){return n=>{if(n.message+=`
|
|
109
|
+
Please report this to https://github.com/markedjs/marked.`,e){let r="<p>An error occurred:</p><pre>"+Tt(n.message+"",!0)+"</pre>";return t?Promise.resolve(r):r}if(t)return Promise.reject(n);throw n}}},cn=new Ex;function xe(e,t){return cn.parse(e,t)}xe.options=xe.setOptions=function(e){return cn.setOptions(e),xe.defaults=cn.defaults,kd(xe.defaults),xe},xe.getDefaults=ls,xe.defaults=un,xe.use=function(...e){return cn.use(...e),xe.defaults=cn.defaults,kd(xe.defaults),xe},xe.walkTokens=function(e,t){return cn.walkTokens(e,t)},xe.parseInline=cn.parseInline,xe.Parser=_t,xe.parser=_t.parse,xe.Renderer=xi,xe.TextRenderer=Es,xe.Lexer=ut,xe.lexer=ut.lex,xe.Tokenizer=ki,xe.Hooks=_r,xe.parse=xe;var Tx=300,_x="300px",kx=500;function xx(e={}){let{immediate:t=!1,debounceDelay:n=Tx,rootMargin:r=_x,idleTimeout:i=kx}=e,[a,s]=oe(!1),o=Oe(null),u=Oe(null),c=Oe(null),f=we(()=>p=>{let m=Date.now();return window.setTimeout(()=>{p({didTimeout:!1,timeRemaining:()=>Math.max(0,50-(Date.now()-m))})},1)},[]),d=we(()=>typeof window<"u"&&window.requestIdleCallback?(p,m)=>window.requestIdleCallback(p,m):f,[f]),h=we(()=>typeof window<"u"&&window.cancelIdleCallback?p=>window.cancelIdleCallback(p):p=>{clearTimeout(p)},[]);return ye(()=>{if(t){s(!0);return}let p=o.current;if(!p)return;u.current&&(clearTimeout(u.current),u.current=null),c.current&&(h(c.current),c.current=null);let m=()=>{u.current&&(clearTimeout(u.current),u.current=null),c.current&&(h(c.current),c.current=null)},_=C=>{c.current=d(D=>{D.timeRemaining()>0||D.didTimeout?(s(!0),C.disconnect()):c.current=d(()=>{s(!0),C.disconnect()},{timeout:i/2})},{timeout:i})},w=C=>{m(),u.current=window.setTimeout(()=>{var D,P;let A=C.takeRecords();(A.length===0||(P=(D=A.at(-1))==null?void 0:D.isIntersecting)!=null&&P)&&_(C)},n)},y=(C,D)=>{C.isIntersecting?w(D):m()},S=new IntersectionObserver(C=>{for(let D of C)y(D,S)},{rootMargin:r,threshold:0});return S.observe(p),()=>{u.current&&clearTimeout(u.current),c.current&&h(c.current),S.disconnect()}},[t,n,r,i,h,d]),{shouldRender:a,containerRef:o}}var Hd=/\s/,yx=/^\s+$/,wx=new Set(["code","pre","svg","math","annotation"]),Ax=e=>typeof e=="object"&&e!==null&&"type"in e&&e.type==="element",Cx=e=>e.some(t=>Ax(t)&&wx.has(t.tagName)),Sx=e=>{let t=[],n="",r=!1;for(let i of e){let a=Hd.test(i);a!==r&&n&&(t.push(n),n=""),n+=i,r=a}return n&&t.push(n),t},Nx=e=>{let t=[],n="";for(let r of e)Hd.test(r)?n+=r:(n&&(t.push(n),n=""),t.push(r));return n&&t.push(n),t},Ix=(e,t,n,r)=>({type:"element",tagName:"span",properties:{"data-sd-animate":!0,style:`--sd-animation:sd-${t};--sd-duration:${n}ms;--sd-easing:${r}`},children:[{type:"text",value:e}]}),vx=(e,t,n)=>{let r=t.at(-1);if(!(r&&"children"in r))return;if(Cx(t))return bn;let i=r,a=i.children.indexOf(e);if(a===-1)return;let s=e.value;if(!s.trim())return;let o=(n.sep==="char"?Nx(s):Sx(s)).map(u=>yx.test(u)?{type:"text",value:u}:Ix(u,n.animation,n.duration,n.easing));return i.children.splice(a,1,...o),a+o.length};function Ts(e){var t,n,r,i;let a={animation:(t=e?.animation)!=null?t:"fadeIn",duration:(n=e?.duration)!=null?n:150,easing:(r=e?.easing)!=null?r:"ease",sep:(i=e?.sep)!=null?i:"word"};return{name:"animate",type:"animate",rehypePlugin:()=>s=>{Ji(s,"text",(o,u)=>vx(o,u,a))}}}Ts();var Ud=Rr(!1),Lx=()=>Ve(Ud),Q=(...e)=>aT(b3(e)),vn=(e,t,n)=>{let r=typeof t=="string"?new Blob([t],{type:n}):t,i=URL.createObjectURL(r),a=document.createElement("a");a.href=i,a.download=e,document.body.appendChild(a),a.click(),document.body.removeChild(a),URL.revokeObjectURL(i)},Rx=Q("block","before:content-[counter(line)]","before:inline-block","before:[counter-increment:line]","before:w-6","before:mr-4","before:text-[13px]","before:text-right","before:text-muted-foreground/50","before:font-mono","before:select-none"),Ox=e=>{let t={};for(let n of e.split(";")){let r=n.indexOf(":");if(r>0){let i=n.slice(0,r).trim(),a=n.slice(r+1).trim();i&&a&&(t[i]=a)}}return t},zd=fe(({children:e,result:t,language:n,className:r,...i})=>{let a=we(()=>{let s={};return t.bg&&(s["--sdm-bg"]=t.bg),t.fg&&(s["--sdm-fg"]=t.fg),t.rootStyle&&Object.assign(s,Ox(t.rootStyle)),s},[t.bg,t.fg,t.rootStyle]);return b("div",{className:Q(r,"overflow-hidden rounded-md border border-border bg-background p-4 text-sm"),"data-language":n,"data-streamdown":"code-block-body",...i,children:b("pre",{className:Q(r,"bg-[var(--sdm-bg,inherit]","dark:bg-[var(--shiki-dark-bg,var(--sdm-bg,inherit)]"),style:a,children:b("code",{className:"[counter-increment:line_0] [counter-reset:line]",children:t.tokens.map((s,o)=>b("span",{className:Rx,children:s.map((u,c)=>{let f={},d=!!u.bgColor;if(u.color&&(f["--sdm-c"]=u.color),u.bgColor&&(f["--sdm-tbg"]=u.bgColor),u.htmlStyle)for(let[h,p]of Object.entries(u.htmlStyle))h==="color"?f["--sdm-c"]=p:h==="background-color"?(f["--sdm-tbg"]=p,d=!0):f[h]=p;return b("span",{className:Q("text-[var(--sdm-c,inherit)]","dark:text-[var(--shiki-dark,var(--sdm-c,inherit))]",d&&"bg-[var(--sdm-tbg)]",d&&"dark:bg-[var(--shiki-dark-bg,var(--sdm-tbg))]"),style:f,...u.htmlAttrs,children:u.content},c)})},o))})})})},(e,t)=>e.result===t.result&&e.language===t.language&&e.className===t.className),Dx=({className:e,language:t,style:n,isIncomplete:r,...i})=>b("div",{className:Q("my-4 flex w-full flex-col gap-2 rounded-xl border border-border bg-sidebar p-2",e),"data-incomplete":r||void 0,"data-language":t,"data-streamdown":"code-block",style:{contentVisibility:"auto",containIntrinsicSize:"auto 200px",...n},...i}),$d=Rr({code:""}),Yd=()=>Ve($d),Px=({language:e})=>b("div",{className:"flex h-8 items-center text-muted-foreground text-xs","data-language":e,"data-streamdown":"code-block-header",children:b("span",{className:"ml-1 font-mono lowercase",children:e})}),Mx=/\n+$/,Bx=wo(()=>Promise.resolve().then(()=>x6).then(e=>({default:e.HighlightedCodeBlockBody}))),Fx=({code:e,language:t,className:n,children:r,isIncomplete:i=!1,...a})=>{let s=we(()=>e.replace(Mx,""),[e]),o=we(()=>({bg:"transparent",fg:"inherit",tokens:s.split(`
|
|
110
|
+
`).map(u=>[{content:u,color:"inherit",bgColor:"transparent",htmlStyle:{},offset:0}])}),[s]);return b($d.Provider,{value:{code:e},children:b(Dx,{isIncomplete:i,language:t,children:[b(Px,{language:t}),r?b("div",{className:"pointer-events-none sticky top-2 z-10 -mt-10 flex h-8 items-center justify-end",children:b("div",{className:"pointer-events-auto flex shrink-0 items-center gap-2 rounded-md border border-sidebar bg-sidebar/80 px-1.5 py-1 supports-[backdrop-filter]:bg-sidebar/70 supports-[backdrop-filter]:backdrop-blur","data-streamdown":"code-block-actions",children:r})}):null,b(zn,{fallback:b(zd,{className:n,language:t,result:o,...a}),children:b(Bx,{className:n,code:s,language:t,raw:o,...a})})]})})},_s=e=>b("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:b("path",{clipRule:"evenodd",d:"M15.5607 3.99999L15.0303 4.53032L6.23744 13.3232C5.55403 14.0066 4.44599 14.0066 3.76257 13.3232L4.2929 12.7929L3.76257 13.3232L0.969676 10.5303L0.439346 9.99999L1.50001 8.93933L2.03034 9.46966L4.82323 12.2626C4.92086 12.3602 5.07915 12.3602 5.17678 12.2626L13.9697 3.46966L14.5 2.93933L15.5607 3.99999Z",fill:"currentColor",fillRule:"evenodd"})}),ks=e=>b("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:b("path",{clipRule:"evenodd",d:"M2.75 0.5C1.7835 0.5 1 1.2835 1 2.25V9.75C1 10.7165 1.7835 11.5 2.75 11.5H3.75H4.5V10H3.75H2.75C2.61193 10 2.5 9.88807 2.5 9.75V2.25C2.5 2.11193 2.61193 2 2.75 2H8.25C8.38807 2 8.5 2.11193 8.5 2.25V3H10V2.25C10 1.2835 9.2165 0.5 8.25 0.5H2.75ZM7.75 4.5C6.7835 4.5 6 5.2835 6 6.25V13.75C6 14.7165 6.7835 15.5 7.75 15.5H13.25C14.2165 15.5 15 14.7165 15 13.75V6.25C15 5.2835 14.2165 4.5 13.25 4.5H7.75ZM7.5 6.25C7.5 6.11193 7.61193 6 7.75 6H13.25C13.3881 6 13.5 6.11193 13.5 6.25V13.75C13.5 13.8881 13.3881 14 13.25 14H7.75C7.61193 14 7.5 13.8881 7.5 13.75V6.25Z",fill:"currentColor",fillRule:"evenodd"})}),yi=e=>b("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:b("path",{clipRule:"evenodd",d:"M8.75 1V1.75V8.68934L10.7197 6.71967L11.25 6.18934L12.3107 7.25L11.7803 7.78033L8.70711 10.8536C8.31658 11.2441 7.68342 11.2441 7.29289 10.8536L4.21967 7.78033L3.68934 7.25L4.75 6.18934L5.28033 6.71967L7.25 8.68934V1.75V1H8.75ZM13.5 9.25V13.5H2.5V9.25V8.5H1V9.25V14C1 14.5523 1.44771 15 2 15H14C14.5523 15 15 14.5523 15 14V9.25V8.5H13.5V9.25Z",fill:"currentColor",fillRule:"evenodd"})}),Hx=e=>b("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:[b("path",{d:"M8 0V4",stroke:"currentColor",strokeWidth:"1.5"}),b("path",{d:"M8 16V12",opacity:"0.5",stroke:"currentColor",strokeWidth:"1.5"}),b("path",{d:"M3.29773 1.52783L5.64887 4.7639",opacity:"0.9",stroke:"currentColor",strokeWidth:"1.5"}),b("path",{d:"M12.7023 1.52783L10.3511 4.7639",opacity:"0.1",stroke:"currentColor",strokeWidth:"1.5"}),b("path",{d:"M12.7023 14.472L10.3511 11.236",opacity:"0.4",stroke:"currentColor",strokeWidth:"1.5"}),b("path",{d:"M3.29773 14.472L5.64887 11.236",opacity:"0.6",stroke:"currentColor",strokeWidth:"1.5"}),b("path",{d:"M15.6085 5.52783L11.8043 6.7639",opacity:"0.2",stroke:"currentColor",strokeWidth:"1.5"}),b("path",{d:"M0.391602 10.472L4.19583 9.23598",opacity:"0.7",stroke:"currentColor",strokeWidth:"1.5"}),b("path",{d:"M15.6085 10.4722L11.8043 9.2361",opacity:"0.3",stroke:"currentColor",strokeWidth:"1.5"}),b("path",{d:"M0.391602 5.52783L4.19583 6.7639",opacity:"0.8",stroke:"currentColor",strokeWidth:"1.5"})]}),Ux=e=>b("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:b("path",{clipRule:"evenodd",d:"M1 5.25V6H2.5V5.25V2.5H5.25H6V1H5.25H2C1.44772 1 1 1.44772 1 2V5.25ZM5.25 14.9994H6V13.4994H5.25H2.5V10.7494V9.99939H1V10.7494V13.9994C1 14.5517 1.44772 14.9994 2 14.9994H5.25ZM15 10V10.75V14C15 14.5523 14.5523 15 14 15H10.75H10V13.5H10.75H13.5V10.75V10H15ZM10.75 1H10V2.5H10.75H13.5V5.25V6H15V5.25V2C15 1.44772 14.5523 1 14 1H10.75Z",fill:"currentColor",fillRule:"evenodd"})}),zx=e=>b("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:b("path",{clipRule:"evenodd",d:"M13.5 8C13.5 4.96643 11.0257 2.5 7.96452 2.5C5.42843 2.5 3.29365 4.19393 2.63724 6.5H5.25H6V8H5.25H0.75C0.335787 8 0 7.66421 0 7.25V2.75V2H1.5V2.75V5.23347C2.57851 2.74164 5.06835 1 7.96452 1C11.8461 1 15 4.13001 15 8C15 11.87 11.8461 15 7.96452 15C5.62368 15 3.54872 13.8617 2.27046 12.1122L1.828 11.5066L3.03915 10.6217L3.48161 11.2273C4.48831 12.6051 6.12055 13.5 7.96452 13.5C11.0257 13.5 13.5 11.0336 13.5 8Z",fill:"currentColor",fillRule:"evenodd"})}),jd=e=>b("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:b("path",{clipRule:"evenodd",d:"M12.4697 13.5303L13 14.0607L14.0607 13L13.5303 12.4697L9.06065 7.99999L13.5303 3.53032L14.0607 2.99999L13 1.93933L12.4697 2.46966L7.99999 6.93933L3.53032 2.46966L2.99999 1.93933L1.93933 2.99999L2.46966 3.53032L6.93933 7.99999L2.46966 12.4697L1.93933 13L2.99999 14.0607L3.53032 13.5303L7.99999 9.06065L12.4697 13.5303Z",fill:"currentColor",fillRule:"evenodd"})}),Vd=e=>b("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:b("path",{clipRule:"evenodd",d:"M13.5 10.25V13.25C13.5 13.3881 13.3881 13.5 13.25 13.5H2.75C2.61193 13.5 2.5 13.3881 2.5 13.25L2.5 2.75C2.5 2.61193 2.61193 2.5 2.75 2.5H5.75H6.5V1H5.75H2.75C1.7835 1 1 1.7835 1 2.75V13.25C1 14.2165 1.7835 15 2.75 15H13.25C14.2165 15 15 14.2165 15 13.25V10.25V9.5H13.5V10.25ZM9 1H9.75H14.2495C14.6637 1 14.9995 1.33579 14.9995 1.75V6.25V7H13.4995V6.25V3.56066L8.53033 8.52978L8 9.06011L6.93934 7.99945L7.46967 7.46912L12.4388 2.5H9.75H9V1Z",fill:"currentColor",fillRule:"evenodd"})}),$x=e=>b("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:b("path",{clipRule:"evenodd",d:"M1.5 6.5C1.5 3.73858 3.73858 1.5 6.5 1.5C9.26142 1.5 11.5 3.73858 11.5 6.5C11.5 9.26142 9.26142 11.5 6.5 11.5C3.73858 11.5 1.5 9.26142 1.5 6.5ZM6.5 0C2.91015 0 0 2.91015 0 6.5C0 10.0899 2.91015 13 6.5 13C8.02469 13 9.42677 12.475 10.5353 11.596L13.9697 15.0303L14.5 15.5607L15.5607 14.5L15.0303 13.9697L11.596 10.5353C12.475 9.42677 13 8.02469 13 6.5C13 2.91015 10.0899 0 6.5 0ZM4.125 5.875H4.75H5.875V4.75V4.125H7.125V4.75V5.875H8.25H8.875V7.125H8.25H7.125V8.25V8.875H5.875V8.25V7.125H4.75H4.125V5.875Z",fill:"currentColor",fillRule:"evenodd"})}),Yx=e=>b("svg",{color:"currentColor",height:16,strokeLinejoin:"round",viewBox:"0 0 16 16",width:16,...e,children:b("path",{clipRule:"evenodd",d:"M1.5 6.5C1.5 3.73858 3.73858 1.5 6.5 1.5C9.26142 1.5 11.5 3.73858 11.5 6.5C11.5 9.26142 9.26142 11.5 6.5 11.5C3.73858 11.5 1.5 9.26142 1.5 6.5ZM6.5 0C2.91015 0 0 2.91015 0 6.5C0 10.0899 2.91015 13 6.5 13C8.02469 13 9.42677 12.475 10.5353 11.596L13.9697 15.0303L14.5 15.5607L15.5607 14.5L15.0303 13.9697L11.596 10.5353C12.475 9.42677 13 8.02469 13 6.5C13 2.91015 10.0899 0 6.5 0ZM4.125 5.875H4.75H8.25H8.875V7.125H8.25H4.75H4.125V5.875Z",fill:"currentColor",fillRule:"evenodd"})}),qd=({onCopy:e,onError:t,timeout:n=2e3,children:r,className:i,code:a,...s})=>{let[o,u]=oe(!1),c=Oe(0),{code:f}=Yd(),{isAnimating:d}=Ve(Ze),h=a??f,p=async()=>{var _;if(typeof window>"u"||!((_=navigator?.clipboard)!=null&&_.writeText)){t?.(new Error("Clipboard API not available"));return}try{o||(await navigator.clipboard.writeText(h),u(!0),e?.(),c.current=window.setTimeout(()=>u(!1),n))}catch(w){t?.(w)}};ye(()=>()=>{window.clearTimeout(c.current)},[]);let m=o?_s:ks;return b("button",{className:Q("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",i),"data-streamdown":"code-block-copy-button",disabled:d,onClick:p,title:"Copy Code",type:"button",...s,children:r??b(m,{size:14})})},Wd={"1c":"1c","1c-query":"1cq",abap:"abap","actionscript-3":"as",ada:"ada",adoc:"adoc","angular-html":"html","angular-ts":"ts",apache:"conf",apex:"cls",apl:"apl",applescript:"applescript",ara:"ara",asciidoc:"adoc",asm:"asm",astro:"astro",awk:"awk",ballerina:"bal",bash:"sh",bat:"bat",batch:"bat",be:"be",beancount:"beancount",berry:"berry",bibtex:"bib",bicep:"bicep",blade:"blade.php",bsl:"bsl",c:"c","c#":"cs","c++":"cpp",cadence:"cdc",cairo:"cairo",cdc:"cdc",clarity:"clar",clj:"clj",clojure:"clj","closure-templates":"soy",cmake:"cmake",cmd:"cmd",cobol:"cob",codeowners:"CODEOWNERS",codeql:"ql",coffee:"coffee",coffeescript:"coffee","common-lisp":"lisp",console:"sh",coq:"v",cpp:"cpp",cql:"cql",crystal:"cr",cs:"cs",csharp:"cs",css:"css",csv:"csv",cue:"cue",cypher:"cql",d:"d",dart:"dart",dax:"dax",desktop:"desktop",diff:"diff",docker:"dockerfile",dockerfile:"dockerfile",dotenv:"env","dream-maker":"dm",edge:"edge",elisp:"el",elixir:"ex",elm:"elm","emacs-lisp":"el",erb:"erb",erl:"erl",erlang:"erl",f:"f","f#":"fs",f03:"f03",f08:"f08",f18:"f18",f77:"f77",f90:"f90",f95:"f95",fennel:"fnl",fish:"fish",fluent:"ftl",for:"for","fortran-fixed-form":"f","fortran-free-form":"f90",fs:"fs",fsharp:"fs",fsl:"fsl",ftl:"ftl",gdresource:"tres",gdscript:"gd",gdshader:"gdshader",genie:"gs",gherkin:"feature","git-commit":"gitcommit","git-rebase":"gitrebase",gjs:"js",gleam:"gleam","glimmer-js":"js","glimmer-ts":"ts",glsl:"glsl",gnuplot:"plt",go:"go",gql:"gql",graphql:"graphql",groovy:"groovy",gts:"gts",hack:"hack",haml:"haml",handlebars:"hbs",haskell:"hs",haxe:"hx",hbs:"hbs",hcl:"hcl",hjson:"hjson",hlsl:"hlsl",hs:"hs",html:"html","html-derivative":"html",http:"http",hxml:"hxml",hy:"hy",imba:"imba",ini:"ini",jade:"jade",java:"java",javascript:"js",jinja:"jinja",jison:"jison",jl:"jl",js:"js",json:"json",json5:"json5",jsonc:"jsonc",jsonl:"jsonl",jsonnet:"jsonnet",jssm:"jssm",jsx:"jsx",julia:"jl",kotlin:"kt",kql:"kql",kt:"kt",kts:"kts",kusto:"kql",latex:"tex",lean:"lean",lean4:"lean",less:"less",liquid:"liquid",lisp:"lisp",lit:"lit",llvm:"ll",log:"log",logo:"logo",lua:"lua",luau:"luau",make:"mak",makefile:"mak",markdown:"md",marko:"marko",matlab:"m",md:"md",mdc:"mdc",mdx:"mdx",mediawiki:"wiki",mermaid:"mmd",mips:"s",mipsasm:"s",mmd:"mmd",mojo:"mojo",move:"move",nar:"nar",narrat:"narrat",nextflow:"nf",nf:"nf",nginx:"conf",nim:"nim",nix:"nix",nu:"nu",nushell:"nu",objc:"m","objective-c":"m","objective-cpp":"mm",ocaml:"ml",pascal:"pas",perl:"pl",perl6:"p6",php:"php",plsql:"pls",po:"po",polar:"polar",postcss:"pcss",pot:"pot",potx:"potx",powerquery:"pq",powershell:"ps1",prisma:"prisma",prolog:"pl",properties:"properties",proto:"proto",protobuf:"proto",ps:"ps",ps1:"ps1",pug:"pug",puppet:"pp",purescript:"purs",py:"py",python:"py",ql:"ql",qml:"qml",qmldir:"qmldir",qss:"qss",r:"r",racket:"rkt",raku:"raku",razor:"cshtml",rb:"rb",reg:"reg",regex:"regex",regexp:"regexp",rel:"rel",riscv:"s",rs:"rs",rst:"rst",ruby:"rb",rust:"rs",sas:"sas",sass:"sass",scala:"scala",scheme:"scm",scss:"scss",sdbl:"sdbl",sh:"sh",shader:"shader",shaderlab:"shader",shell:"sh",shellscript:"sh",shellsession:"sh",smalltalk:"st",solidity:"sol",soy:"soy",sparql:"rq",spl:"spl",splunk:"spl",sql:"sql","ssh-config":"config",stata:"do",styl:"styl",stylus:"styl",svelte:"svelte",swift:"swift","system-verilog":"sv",systemd:"service",talon:"talon",talonscript:"talon",tasl:"tasl",tcl:"tcl",templ:"templ",terraform:"tf",tex:"tex",tf:"tf",tfvars:"tfvars",toml:"toml",ts:"ts","ts-tags":"ts",tsp:"tsp",tsv:"tsv",tsx:"tsx",turtle:"ttl",twig:"twig",typ:"typ",typescript:"ts",typespec:"tsp",typst:"typ",v:"v",vala:"vala",vb:"vb",verilog:"v",vhdl:"vhdl",vim:"vim",viml:"vim",vimscript:"vim",vue:"vue","vue-html":"html","vue-vine":"vine",vy:"vy",vyper:"vy",wasm:"wasm",wenyan:"wy",wgsl:"wgsl",wiki:"wiki",wikitext:"wiki",wit:"wit",wl:"wl",wolfram:"wl",xml:"xml",xsl:"xsl",yaml:"yaml",yml:"yml",zenscript:"zs",zig:"zig",zsh:"zsh",文言:"wy"},jx=({onDownload:e,onError:t,language:n,children:r,className:i,code:a,...s})=>{let{code:o}=Yd(),{isAnimating:u}=Ve(Ze),c=a??o,f=`file.${n&&n in Wd?Wd[n]:"txt"}`,d="text/plain",h=()=>{try{vn(f,c,d),e?.()}catch(p){t?.(p)}};return b("button",{className:Q("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",i),"data-streamdown":"code-block-download-button",disabled:u,onClick:h,title:"Download file",type:"button",...s,children:r??b(yi,{size:14})})},Vx=()=>b("div",{className:"w-full divide-y divide-border overflow-hidden rounded-xl border border-border",children:[b("div",{className:"h-[46px] w-full bg-muted/80"}),b("div",{className:"flex w-full items-center justify-center p-4",children:b(Hx,{className:"size-4 animate-spin"})})]}),qx=/\.[^/.]+$/,Wx=({node:e,className:t,src:n,alt:r,onLoad:i,onError:a,...s})=>{let o=Oe(null),[u,c]=oe(!1),[f,d]=oe(!1),h=s.width!=null||s.height!=null,p=(u||h)&&!f,m=f&&!h;ye(()=>{let S=o.current;if(S!=null&&S.complete){let C=S.naturalWidth>0;c(C),d(!C)}},[]);let _=De(S=>{c(!0),d(!1),i?.(S)},[i]),w=De(S=>{c(!1),d(!0),a?.(S)},[a]),y=async()=>{if(n)try{let S=await(await fetch(n)).blob(),C=new URL(n,window.location.origin).pathname.split("/").pop()||"",D=C.split(".").pop(),P=C.includes(".")&&D!==void 0&&D.length<=4,A="";if(P)A=C;else{let U=S.type,I="png";U.includes("jpeg")||U.includes("jpg")?I="jpg":U.includes("png")?I="png":U.includes("svg")?I="svg":U.includes("gif")?I="gif":U.includes("webp")&&(I="webp"),A=`${(r||C||"image").replace(qx,"")}.${I}`}vn(A,S,S.type)}catch{window.open(n,"_blank")}};return n?b("div",{className:"group relative my-4 inline-block","data-streamdown":"image-wrapper",children:[b("img",{alt:r,className:Q("max-w-full rounded-lg",m&&"hidden",t),"data-streamdown":"image",onError:w,onLoad:_,ref:o,src:n,...s}),m&&b("span",{className:"text-muted-foreground text-xs italic","data-streamdown":"image-fallback",children:"Image not available"}),b("div",{className:"pointer-events-none absolute inset-0 hidden rounded-lg bg-black/10 group-hover:block"}),p&&b("button",{className:Q("absolute right-2 bottom-2 flex h-8 w-8 cursor-pointer items-center justify-center rounded-md border border-border bg-background/90 shadow-sm backdrop-blur-sm transition-all duration-200 hover:bg-background","opacity-0 group-hover:opacity-100"),onClick:y,title:"Download image",type:"button",children:b(yi,{size:14})})]}):null},kr=0,Gx=()=>{kr+=1,kr===1&&(document.body.style.overflow="hidden")},Qx=()=>{kr=Math.max(0,kr-1),kr===0&&(document.body.style.overflow="")},Kx=({url:e,isOpen:t,onClose:n,onConfirm:r})=>{let[i,a]=oe(!1),s=De(async()=>{try{await navigator.clipboard.writeText(e),a(!0),setTimeout(()=>a(!1),2e3)}catch{}},[e]),o=De(()=>{r(),n()},[r,n]);return ye(()=>{if(t){Gx();let u=c=>{c.key==="Escape"&&n()};return document.addEventListener("keydown",u),()=>{document.removeEventListener("keydown",u),Qx()}}},[t,n]),t?b("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-background/50 backdrop-blur-sm","data-streamdown":"link-safety-modal",onClick:n,onKeyDown:u=>{u.key==="Escape"&&n()},role:"button",tabIndex:0,children:b("div",{className:"relative mx-4 flex w-full max-w-md flex-col gap-4 rounded-xl border bg-background p-6 shadow-lg",onClick:u=>u.stopPropagation(),onKeyDown:u=>u.stopPropagation(),role:"presentation",children:[b("button",{className:"absolute top-4 right-4 rounded-md p-1 text-muted-foreground transition-all hover:bg-muted hover:text-foreground",onClick:n,title:"Close",type:"button",children:b(jd,{size:16})}),b("div",{className:"flex flex-col gap-2",children:[b("div",{className:"flex items-center gap-2 font-semibold text-lg",children:[b(Vd,{size:20}),b("span",{children:"Open external link?"})]}),b("p",{className:"text-muted-foreground text-sm",children:"You're about to visit an external website."})]}),b("div",{className:Q("break-all rounded-md bg-muted p-3 font-mono text-sm",e.length>100&&"max-h-32 overflow-y-auto"),children:e}),b("div",{className:"flex gap-2",children:[b("button",{className:"flex flex-1 items-center justify-center gap-2 rounded-md border bg-background px-4 py-2 font-medium text-sm transition-all hover:bg-muted",onClick:s,type:"button",children:i?b($e,{children:[b(_s,{size:14}),b("span",{children:"Copied"})]}):b($e,{children:[b(ks,{size:14}),b("span",{children:"Copy link"})]})}),b("button",{className:"flex flex-1 items-center justify-center gap-2 rounded-md bg-primary px-4 py-2 font-medium text-primary-foreground text-sm transition-all hover:bg-primary/90",onClick:o,type:"button",children:[b(Vd,{size:14}),b("span",{children:"Open link"})]})]})]})}):null},xs=Rr(null),Gd=()=>Ve(xs),Xx=()=>{var e;let t=Gd();return(e=t?.code)!=null?e:null},ys=()=>{var e;let t=Gd();return(e=t?.mermaid)!=null?e:null},Zx=(e,t)=>{var n;let r=(n=void 0)!=null?n:5;return new Promise((i,a)=>{let s="data:image/svg+xml;base64,"+btoa(unescape(encodeURIComponent(e))),o=new Image;o.crossOrigin="anonymous",o.onload=()=>{let u=document.createElement("canvas"),c=o.width*r,f=o.height*r;u.width=c,u.height=f;let d=u.getContext("2d");if(!d){a(new Error("Failed to create 2D canvas context for PNG export"));return}d.drawImage(o,0,0,c,f),u.toBlob(h=>{if(!h){a(new Error("Failed to create PNG blob"));return}i(h)},"image/png")},o.onerror=()=>a(new Error("Failed to load SVG image")),o.src=s})},Jx=({chart:e,children:t,className:n,onDownload:r,config:i,onError:a})=>{let[s,o]=oe(!1),u=Oe(null),{isAnimating:c}=Ve(Ze),f=ys(),d=async h=>{try{if(h==="mmd"){vn("diagram.mmd",e,"text/plain"),o(!1),r?.(h);return}if(!f){a?.(new Error("Mermaid plugin not available"));return}let p=f.getMermaid(i),m=e.split("").reduce((y,S)=>(y<<5)-y+S.charCodeAt(0)|0,0),_=`mermaid-${Math.abs(m)}-${Date.now()}-${Math.random().toString(36).substring(2,9)}`,{svg:w}=await p.render(_,e);if(!w){a?.(new Error("SVG not found. Please wait for the diagram to render."));return}if(h==="svg"){vn("diagram.svg",w,"image/svg+xml"),o(!1),r?.(h);return}if(h==="png"){let y=await Zx(w);vn("diagram.png",y,"image/png"),r?.(h),o(!1);return}}catch(p){a?.(p)}};return ye(()=>{let h=p=>{let m=p.composedPath();u.current&&!m.includes(u.current)&&o(!1)};return document.addEventListener("mousedown",h),()=>{document.removeEventListener("mousedown",h)}},[]),b("div",{className:"relative",ref:u,children:[b("button",{className:Q("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",n),disabled:c,onClick:()=>o(!s),title:"Download diagram",type:"button",children:t??b(yi,{size:14})}),s?b("div",{className:"absolute top-full right-0 z-10 mt-1 min-w-[120px] overflow-hidden rounded-md border border-border bg-background shadow-lg",children:[b("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>d("svg"),title:"Download diagram as SVG",type:"button",children:"SVG"}),b("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>d("png"),title:"Download diagram as PNG",type:"button",children:"PNG"}),b("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>d("mmd"),title:"Download diagram as MMD",type:"button",children:"MMD"})]}):null]})},xr=0,ey=()=>{xr+=1,xr===1&&(document.body.style.overflow="hidden")},ty=()=>{xr=Math.max(0,xr-1),xr===0&&(document.body.style.overflow="")},ny=({chart:e,config:t,onFullscreen:n,onExit:r,className:i,...a})=>{let[s,o]=oe(!1),{isAnimating:u,controls:c}=Ve(Ze),f=(()=>{if(typeof c=="boolean")return c;let h=c.mermaid;return h===!1?!1:h===!0||h===void 0?!0:h.panZoom!==!1})(),d=()=>{o(!s)};return ye(()=>{if(s){ey();let h=p=>{p.key==="Escape"&&o(!1)};return document.addEventListener("keydown",h),()=>{document.removeEventListener("keydown",h),ty()}}},[s]),ye(()=>{s?n?.():r&&r()},[s,n,r]),b($e,{children:[b("button",{className:Q("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",i),disabled:u,onClick:d,title:"View fullscreen",type:"button",...a,children:b(Ux,{size:14})}),s?Cf(b("div",{className:"fixed inset-0 z-50 flex items-center justify-center bg-background/95 backdrop-blur-sm",onClick:d,onKeyDown:h=>{h.key==="Escape"&&d()},role:"button",tabIndex:0,children:[b("button",{className:"absolute top-4 right-4 z-10 rounded-md p-2 text-muted-foreground transition-all hover:bg-muted hover:text-foreground",onClick:d,title:"Exit fullscreen",type:"button",children:b(jd,{size:20})}),b("div",{className:"flex size-full items-center justify-center p-4",onClick:h=>h.stopPropagation(),onKeyDown:h=>h.stopPropagation(),role:"presentation",children:b(P0,{chart:e,className:"size-full [&_svg]:h-auto [&_svg]:w-auto",config:t,fullscreen:!0,showControls:f})})]}),document.body):null]})},Qd=e=>{var t,n;let r=[],i=[],a=e.querySelectorAll("thead th");for(let o of a)r.push(((t=o.textContent)==null?void 0:t.trim())||"");let s=e.querySelectorAll("tbody tr");for(let o of s){let u=[],c=o.querySelectorAll("td");for(let f of c)u.push(((n=f.textContent)==null?void 0:n.trim())||"");i.push(u)}return{headers:r,rows:i}},Kd=e=>{let{headers:t,rows:n}=e,r=o=>{let u=!1,c=!1;for(let f of o){if(f==='"'){u=!0,c=!0;break}(f===","||f===`
|
|
106
111
|
`)&&(u=!0)}return u?c?`"${o.replace(/"/g,'""')}"`:`"${o}"`:o},i=t.length>0?n.length+1:n.length,a=new Array(i),s=0;t.length>0&&(a[s]=t.map(r).join(","),s+=1);for(let o of n)a[s]=o.map(r).join(","),s+=1;return a.join(`
|
|
107
|
-
`)},
|
|
112
|
+
`)},ry=e=>{let{headers:t,rows:n}=e,r=o=>{let u=!1;for(let f of o)if(f===" "||f===`
|
|
108
113
|
`||f==="\r"){u=!0;break}if(!u)return o;let c=[];for(let f of o)f===" "?c.push("\\t"):f===`
|
|
109
114
|
`?c.push("\\n"):f==="\r"?c.push("\\r"):c.push(f);return c.join("")},i=t.length>0?n.length+1:n.length,a=new Array(i),s=0;t.length>0&&(a[s]=t.map(r).join(" "),s+=1);for(let o of n)a[s]=o.map(r).join(" "),s+=1;return a.join(`
|
|
110
|
-
`)},
|
|
111
|
-
`)},rx=({children:e,className:t,onCopy:n,onError:r,timeout:i=2e3})=>{let[a,s]=le(!1),[o,u]=le(!1),c=Le(null),f=Le(0),{isAnimating:d}=Ge(Ze),h=async m=>{var _,A;if(typeof window>"u"||!((_=navigator?.clipboard)!=null&&_.write)){r?.(new Error("Clipboard API not available"));return}try{let y=(A=c.current)==null?void 0:A.closest('[data-streamdown="table-wrapper"]'),I=y?.querySelector("table");if(!I){r?.(new Error("Table not found"));return}let S=Dd(I),D=m==="csv"?Pd(S):tx(S),P=new ClipboardItem({"text/plain":new Blob([D],{type:"text/plain"}),"text/html":new Blob([I.outerHTML],{type:"text/html"})});await navigator.clipboard.write([P]),u(!0),s(!1),n?.(m),f.current=window.setTimeout(()=>u(!1),i)}catch(y){r?.(y)}};we(()=>{let m=_=>{let A=_.composedPath();c.current&&!A.includes(c.current)&&s(!1)};return document.addEventListener("mousedown",m),()=>{document.removeEventListener("mousedown",m),window.clearTimeout(f.current)}},[]);let p=o?ls:cs;return b("div",{className:"relative",ref:c,children:[b("button",{className:K("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",t),disabled:d,onClick:()=>s(!a),title:"Copy table",type:"button",children:e??b(p,{size:14})}),a?b("div",{className:"absolute top-full right-0 z-10 mt-1 min-w-[120px] overflow-hidden rounded-md border border-border bg-background shadow-lg",children:[b("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>h("csv"),title:"Copy table as CSV",type:"button",children:"CSV"}),b("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>h("tsv"),title:"Copy table as TSV",type:"button",children:"TSV"})]}):null]})},ix=({children:e,className:t,onDownload:n,onError:r})=>{let[i,a]=le(!1),s=Le(null),{isAnimating:o}=Ge(Ze),u=c=>{var f;try{let d=(f=s.current)==null?void 0:f.closest('[data-streamdown="table-wrapper"]'),h=d?.querySelector("table");if(!h){r?.(new Error("Table not found"));return}let p=Dd(h),m=c==="csv"?Pd(p):nx(p);Cn(`table.${c==="csv"?"csv":"md"}`,m,c==="csv"?"text/csv":"text/markdown"),a(!1),n?.(c)}catch(d){r?.(d)}};return we(()=>{let c=f=>{let d=f.composedPath();s.current&&!d.includes(s.current)&&a(!1)};return document.addEventListener("mousedown",c),()=>{document.removeEventListener("mousedown",c)}},[]),b("div",{className:"relative",ref:s,children:[b("button",{className:K("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",t),disabled:o,onClick:()=>a(!i),title:"Download table",type:"button",children:e??b(gi,{size:14})}),i?b("div",{className:"absolute top-full right-0 z-10 mt-1 min-w-[120px] overflow-hidden rounded-md border border-border bg-background shadow-lg",children:[b("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>u("csv"),title:"Download table as CSV",type:"button",children:"CSV"}),b("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>u("markdown"),title:"Download table as Markdown",type:"button",children:"Markdown"})]}):null]})},ax=({children:e,className:t,showControls:n,...r})=>b("div",{className:"my-4 flex flex-col space-y-2","data-streamdown":"table-wrapper",children:[n?b("div",{className:"flex items-center justify-end gap-1",children:[b(rx,{}),b(ix,{})]}):null,b("div",{className:"overflow-x-auto",children:b("table",{className:K("w-full border-collapse border border-border",t),"data-streamdown":"table",...r,children:e})})]}),sx=go(()=>Promise.resolve().then(()=>h6).then(e=>({default:e.CodeBlock}))),ox=go(()=>Promise.resolve().then(()=>p6).then(e=>({default:e.Mermaid}))),ux=/language-([^\s]+)/;function bi(e,t){if(!(e!=null&&e.position||t!=null&&t.position))return!0;if(!(e!=null&&e.position&&t!=null&&t.position))return!1;let n=e.position.start,r=t.position.start,i=e.position.end,a=t.position.end;return n?.line===r?.line&&n?.column===r?.column&&i?.line===a?.line&&i?.column===a?.column}function xe(e,t){return e.className===t.className&&bi(e.node,t.node)}var ps=(e,t)=>typeof e=="boolean"?e:e[t]!==!1,Ei=(e,t)=>{if(typeof e=="boolean")return e;let n=e.mermaid;return n===!1?!1:n===!0||n===void 0?!0:n[t]!==!1},ms=de(({children:e,className:t,node:n,...r})=>b("ol",{className:K("list-inside list-decimal whitespace-normal [li_&]:pl-6",t),"data-streamdown":"ordered-list",...r,children:e}),(e,t)=>xe(e,t));ms.displayName="MarkdownOl";var Md=de(({children:e,className:t,node:n,...r})=>b("li",{className:K("py-1 [&>p]:inline",t),"data-streamdown":"list-item",...r,children:e}),(e,t)=>e.className===t.className&&bi(e.node,t.node));Md.displayName="MarkdownLi";var Bd=de(({children:e,className:t,node:n,...r})=>b("ul",{className:K("list-inside list-disc whitespace-normal [li_&]:pl-6",t),"data-streamdown":"unordered-list",...r,children:e}),(e,t)=>xe(e,t));Bd.displayName="MarkdownUl";var Fd=de(({className:e,node:t,...n})=>b("hr",{className:K("my-6 border-border",e),"data-streamdown":"horizontal-rule",...n}),(e,t)=>xe(e,t));Fd.displayName="MarkdownHr";var Hd=de(({children:e,className:t,node:n,...r})=>b("span",{className:K("font-semibold",t),"data-streamdown":"strong",...r,children:e}),(e,t)=>xe(e,t));Hd.displayName="MarkdownStrong";var lx=({children:e,className:t,href:n,node:r,...i})=>{let{linkSafety:a}=Ge(Ze),[s,o]=le(!1),u=n==="streamdown:incomplete-link",c=Pe(async p=>{if(!(!(a!=null&&a.enabled&&n)||u)){if(p.preventDefault(),a.onLinkCheck&&await a.onLinkCheck(n)){window.open(n,"_blank","noreferrer");return}o(!0)}},[a,n,u]),f=Pe(()=>{n&&window.open(n,"_blank","noreferrer")},[n]),d=Pe(()=>{o(!1)},[]),h={url:n??"",isOpen:s,onClose:d,onConfirm:f};return a!=null&&a.enabled&&n?b(Ue,{children:[b("button",{className:K("wrap-anywhere appearance-none text-left font-medium text-primary underline",t),"data-incomplete":u,"data-streamdown":"link",onClick:c,type:"button",children:e}),a.renderModal?a.renderModal(h):b(Gk,{...h})]}):b("a",{className:K("wrap-anywhere font-medium text-primary underline",t),"data-incomplete":u,"data-streamdown":"link",href:n,rel:"noreferrer",target:"_blank",...i,children:e})},Ud=de(lx,(e,t)=>xe(e,t)&&e.href===t.href);Ud.displayName="MarkdownA";var zd=de(({children:e,className:t,node:n,...r})=>b("h1",{className:K("mt-6 mb-2 font-semibold text-3xl",t),"data-streamdown":"heading-1",...r,children:e}),(e,t)=>xe(e,t));zd.displayName="MarkdownH1";var $d=de(({children:e,className:t,node:n,...r})=>b("h2",{className:K("mt-6 mb-2 font-semibold text-2xl",t),"data-streamdown":"heading-2",...r,children:e}),(e,t)=>xe(e,t));$d.displayName="MarkdownH2";var Yd=de(({children:e,className:t,node:n,...r})=>b("h3",{className:K("mt-6 mb-2 font-semibold text-xl",t),"data-streamdown":"heading-3",...r,children:e}),(e,t)=>xe(e,t));Yd.displayName="MarkdownH3";var jd=de(({children:e,className:t,node:n,...r})=>b("h4",{className:K("mt-6 mb-2 font-semibold text-lg",t),"data-streamdown":"heading-4",...r,children:e}),(e,t)=>xe(e,t));jd.displayName="MarkdownH4";var Vd=de(({children:e,className:t,node:n,...r})=>b("h5",{className:K("mt-6 mb-2 font-semibold text-base",t),"data-streamdown":"heading-5",...r,children:e}),(e,t)=>xe(e,t));Vd.displayName="MarkdownH5";var qd=de(({children:e,className:t,node:n,...r})=>b("h6",{className:K("mt-6 mb-2 font-semibold text-sm",t),"data-streamdown":"heading-6",...r,children:e}),(e,t)=>xe(e,t));qd.displayName="MarkdownH6";var Wd=de(({children:e,className:t,node:n,...r})=>{let{controls:i}=Ge(Ze),a=ps(i,"table");return b(ax,{className:t,showControls:a,...r,children:e})},(e,t)=>xe(e,t));Wd.displayName="MarkdownTable";var Gd=de(({children:e,className:t,node:n,...r})=>b("thead",{className:K("bg-muted/80",t),"data-streamdown":"table-header",...r,children:e}),(e,t)=>xe(e,t));Gd.displayName="MarkdownThead";var Qd=de(({children:e,className:t,node:n,...r})=>b("tbody",{className:K("divide-y divide-border bg-muted/40",t),"data-streamdown":"table-body",...r,children:e}),(e,t)=>xe(e,t));Qd.displayName="MarkdownTbody";var Kd=de(({children:e,className:t,node:n,...r})=>b("tr",{className:K("border-border border-b",t),"data-streamdown":"table-row",...r,children:e}),(e,t)=>xe(e,t));Kd.displayName="MarkdownTr";var Xd=de(({children:e,className:t,node:n,...r})=>b("th",{className:K("whitespace-nowrap px-4 py-2 text-left font-semibold text-sm",t),"data-streamdown":"table-header-cell",...r,children:e}),(e,t)=>xe(e,t));Xd.displayName="MarkdownTh";var Zd=de(({children:e,className:t,node:n,...r})=>b("td",{className:K("px-4 py-2 text-sm",t),"data-streamdown":"table-cell",...r,children:e}),(e,t)=>xe(e,t));Zd.displayName="MarkdownTd";var Jd=de(({children:e,className:t,node:n,...r})=>b("blockquote",{className:K("my-4 border-muted-foreground/30 border-l-4 pl-4 text-muted-foreground italic",t),"data-streamdown":"blockquote",...r,children:e}),(e,t)=>xe(e,t));Jd.displayName="MarkdownBlockquote";var e0=de(({children:e,className:t,node:n,...r})=>b("sup",{className:K("text-sm",t),"data-streamdown":"superscript",...r,children:e}),(e,t)=>xe(e,t));e0.displayName="MarkdownSup";var t0=de(({children:e,className:t,node:n,...r})=>b("sub",{className:K("text-sm",t),"data-streamdown":"subscript",...r,children:e}),(e,t)=>xe(e,t));t0.displayName="MarkdownSub";var n0=de(({children:e,className:t,node:n,...r})=>{if("data-footnotes"in r){let i=s=>{var o,u;if(!ln(s))return!1;let c=Array.isArray(s.props.children)?s.props.children:[s.props.children],f=!1,d=!1;for(let h of c)if(h){if(typeof h=="string")h.trim()!==""&&(f=!0);else if(ln(h))if(((o=h.props)==null?void 0:o["data-footnote-backref"])!==void 0)d=!0;else{let p=Array.isArray(h.props.children)?h.props.children:[h.props.children];for(let m of p){if(typeof m=="string"&&m.trim()!==""){f=!0;break}if(ln(m)&&((u=m.props)==null?void 0:u["data-footnote-backref"])===void 0){f=!0;break}}}}return d&&!f},a=Array.isArray(e)?e.map(s=>{if(!ln(s))return s;if(s.type===ms){let o=(Array.isArray(s.props.children)?s.props.children:[s.props.children]).filter(u=>!i(u));return o.length===0?null:{...s,props:{...s.props,children:o}}}return s}):e;return(Array.isArray(a)?a.some(s=>s!==null):a!==null)?b("section",{className:t,...r,children:a}):null}return b("section",{className:t,...r,children:e})},(e,t)=>xe(e,t));n0.displayName="MarkdownSection";var cx=({node:e,className:t,children:n,...r})=>{var i,a,s;let o=((i=e?.position)==null?void 0:i.start.line)===((a=e?.position)==null?void 0:a.end.line),{mermaid:u,controls:c}=Ge(Ze),f=fs();if(o)return b("code",{className:K("rounded bg-muted px-1.5 py-0.5 font-mono text-sm",t),"data-streamdown":"inline-code",...r,children:n});let d=t?.match(ux),h=(s=d?.at(1))!=null?s:"",p="";if(ln(n)&&n.props&&typeof n.props=="object"&&"children"in n.props&&typeof n.props.children=="string"?p=n.props.children:typeof n=="string"&&(p=n),h==="mermaid"&&f){let _=ps(c,"mermaid"),A=Ei(c,"download"),y=Ei(c,"copy"),I=Ei(c,"fullscreen"),S=Ei(c,"panZoom"),D=_&&(A||y||I);return b(Pn,{fallback:b(Rd,{}),children:b("div",{className:K("group relative my-4 h-auto rounded-xl border p-4",t),"data-streamdown":"mermaid-block",children:[D?b("div",{className:"flex items-center justify-end gap-2",children:[A?b(Xk,{chart:p,config:u?.config}):null,y?b(vd,{code:p}):null,I?b(ex,{chart:p,config:u?.config}):null]}):null,b(ox,{chart:p,config:u?.config,showControls:S})]})})}let m=ps(c,"code");return b(Pn,{fallback:b(Rd,{}),children:b(sx,{className:K("overflow-x-auto border-border border-t",t),code:p,language:h,children:m?b(Ue,{children:[b(Yk,{code:p,language:h}),b(vd,{})]}):null})})},r0=de(cx,(e,t)=>e.className===t.className&&bi(e.node,t.node));r0.displayName="MarkdownCode";var i0=de(Vk,(e,t)=>e.className===t.className&&bi(e.node,t.node));i0.displayName="MarkdownImg";var a0=de(({children:e,className:t,node:n,...r})=>{var i,a;let s=(Array.isArray(e)?e:[e]).filter(o=>o!=null&&o!=="");if(s.length===1&&ln(s[0])){let o=s[0].props.node,u=o?.tagName;if(u==="img")return b(Ue,{children:e});if(u==="code"&&((i=o?.position)==null?void 0:i.start.line)!==((a=o?.position)==null?void 0:a.end.line))return b(Ue,{children:e})}return b("p",{className:t,...r,children:e})},(e,t)=>xe(e,t));a0.displayName="MarkdownParagraph";var dx={ol:ms,li:Md,ul:Bd,hr:Fd,strong:Hd,a:Ud,h1:zd,h2:$d,h3:Yd,h4:jd,h5:Vd,h6:qd,table:Wd,thead:Gd,tbody:Qd,tr:Kd,th:Xd,td:Zd,blockquote:Jd,code:r0,img:i0,pre:({children:e})=>e,sup:e0,sub:t0,p:a0,section:n0},s0=[],o0={allowDangerousHtml:!0},Ti=new WeakMap,fx=class{constructor(){this.cache=new Map,this.keyCache=new WeakMap,this.maxSize=100}generateCacheKey(e){let t=this.keyCache.get(e);if(t)return t;let n=e.rehypePlugins,r=e.remarkPlugins,i=e.remarkRehypeOptions;if(!(n||r||i)){let f="default";return this.keyCache.set(e,f),f}let a=f=>{if(!f||f.length===0)return"";let d="";for(let h=0;h<f.length;h+=1){let p=f[h];if(h>0&&(d+=","),Array.isArray(p)){let[m,_]=p;if(typeof m=="function"){let A=Ti.get(m);A||(A=m.name,Ti.set(m,A)),d+=A}else d+=String(m);d+=":",d+=JSON.stringify(_)}else if(typeof p=="function"){let m=Ti.get(p);m||(m=p.name,Ti.set(p,m)),d+=m}else d+=String(p)}return d},s=a(n),o=a(r),u=i?JSON.stringify(i):"",c=`${o}::${s}::${u}`;return this.keyCache.set(e,c),c}get(e){let t=this.generateCacheKey(e),n=this.cache.get(t);return n&&(this.cache.delete(t),this.cache.set(t,n)),n}set(e,t){let n=this.generateCacheKey(e);if(this.cache.size>=this.maxSize){let r=this.cache.keys().next().value;r&&this.cache.delete(r)}this.cache.set(n,t)}clear(){this.cache.clear()}},u0=new fx,l0=e=>{let t=hx(e),n=e.children||"";return mx(t.runSync(t.parse(n),n),e)},hx=e=>{let t=u0.get(e);if(t)return t;let n=px(e);return u0.set(e,n),n},px=e=>{let t=e.rehypePlugins||s0,n=e.remarkPlugins||s0,r=e.remarkRehypeOptions?{...o0,...e.remarkRehypeOptions}:o0;return W_().use(WT).use(n).use(N_,r).use(t)},mx=(e,t)=>cT(e,{Fragment:Ue,components:t.components,ignoreInvalidStyle:!0,jsx:b,jsxs:b,passKeys:!0,passNode:!0}),gx=/\[\^[^\]\s]{1,200}\](?!:)/,bx=/\[\^[^\]\s]{1,200}\]:/,Ex=/<\/(\w+)>/,Tx=/<(\w+)[\s>]/,gs=e=>{let t=0;for(;t<e.length&&(e[t]===" "||e[t]===" "||e[t]===`
|
|
112
|
-
|
|
113
|
-
`||e[t]==="\r");)t-=1;return t>=1&&e[t]==="$"&&e[t-1]==="$"},bs=e=>{let t=0;for(let n=0;n<e.length-1;n+=1)e[n]==="$"&&e[n+1]==="$"&&(t+=1,n+=1);return t},kx=e=>{let t=gx.test(e),n=bx.test(e);if(t||n)return[e];let r=lt.lex(e,{gfm:!0}),i=[],a=[];for(let s of r){let o=s.raw,u=i.length;if(a.length>0){if(i[u-1]+=o,s.type==="html"){let c=o.match(Ex);if(c){let f=c[1];a.at(-1)===f&&a.pop()}}continue}if(s.type==="html"&&s.block){let c=o.match(Tx);if(c){let f=c[1];o.includes(`</${f}>`)||a.push(f)}}if(o.trim()==="$$"&&u>0){let c=i[u-1],f=gs(c),d=bs(c);if(f&&d%2===1){i[u-1]=c+o;continue}}if(u>0&&_x(o)){let c=i[u-1],f=gs(c),d=bs(c),h=bs(o);if(f&&d%2===1&&!gs(o)&&h===1){i[u-1]=c+o;continue}}i.push(o)}return i},xx={raw:V1,sanitize:[tm,{}],harden:[bf,{allowedImagePrefixes:["*"],allowedLinkPrefixes:["*"],allowedProtocols:["*"],defaultOrigin:void 0,allowDataImages:!0}]},yx={gfm:[P2,{}]},wx=Object.values(xx),Ax=Object.values(yx),Cx={block:" ▋",circle:" ●"},Sx={shikiTheme:["github-light","github-dark"],controls:!0,isAnimating:!1,mode:"streaming",mermaid:void 0,linkSafety:{enabled:!0}},Ze=Ii(Sx),c0=de(({content:e,shouldParseIncompleteMarkdown:t,index:n,...r})=>b(l0,{...r,children:e}),(e,t)=>{if(e.content!==t.content||e.index!==t.index)return!1;if(e.components!==t.components){let n=Object.keys(e.components||{}),r=Object.keys(t.components||{});if(n.length!==r.length||n.some(i=>{var a,s;return((a=e.components)==null?void 0:a[i])!==((s=t.components)==null?void 0:s[i])}))return!1}return!(e.rehypePlugins!==t.rehypePlugins||e.remarkPlugins!==t.remarkPlugins)});c0.displayName="Block";var Ix=["github-light","github-dark"],d0=de(({children:e,mode:t="streaming",parseIncompleteMarkdown:n=!0,components:r,rehypePlugins:i=wx,remarkPlugins:a=Ax,className:s,shikiTheme:o=Ix,mermaid:u,controls:c=!0,isAnimating:f=!1,BlockComponent:d=c0,parseMarkdownIntoBlocksFn:h=kx,caret:p,plugins:m,remend:_,linkSafety:A={enabled:!0},...y})=>{let I=O0(),[S,D]=cf(),P=Ie(()=>typeof e!="string"?"":t==="streaming"&&n?HE(e,_):e,[e,t,n,_]),w=Ie(()=>h(P),[P,h]),[z,L]=le(w);we(()=>{t==="streaming"?D(()=>{L(w)}):L(w)},[w,t]);let H=t==="streaming"?z:w,C=Ie(()=>H.map((Z,ee)=>`${I}-${ee}`),[H.length,I]),$=Ie(()=>{var Z,ee;return{shikiTheme:(ee=(Z=m?.code)==null?void 0:Z.getThemes())!=null?ee:o,controls:c,isAnimating:f,mode:t,mermaid:u,linkSafety:A}},[o,c,f,t,u,A,m?.code]),B=Ie(()=>({...dx,...r}),[r]),Q=Ie(()=>{let Z=[];return m!=null&&m.cjk&&(Z=[...Z,...m.cjk.remarkPluginsBefore]),Z=[...Z,...a],m!=null&&m.cjk&&(Z=[...Z,...m.cjk.remarkPluginsAfter]),m!=null&&m.math&&(Z=[...Z,m.math.remarkPlugin]),Z},[a,m?.math,m?.cjk]),ae=Ie(()=>m!=null&&m.math?[...i,m.math.rehypePlugin]:i,[i,m?.math]),X=Ie(()=>p&&f?{"--streamdown-caret":`"${Cx[p]}"`}:void 0,[p,f]);return t==="static"?b(ds.Provider,{value:m??null,children:b(Ze.Provider,{value:$,children:b("div",{className:K("space-y-4 whitespace-normal *:first:mt-0 *:last:mb-0",s),children:b(l0,{components:B,rehypePlugins:ae,remarkPlugins:Q,...y,children:e})})})}):b(ds.Provider,{value:m??null,children:b(Ze.Provider,{value:$,children:b("div",{className:K("space-y-4 whitespace-normal *:first:mt-0 *:last:mb-0",p?"*:last:after:inline *:last:after:align-baseline *:last:after:content-(--streamdown-caret)":null,s),style:X,children:[H.length===0&&p&&f&&b("span",{}),H.map((Z,ee)=>b(d,{components:B,content:Z,index:ee,rehypePlugins:ae,remarkPlugins:Q,shouldParseIncompleteMarkdown:n,...y},C[ee]))]})})})},(e,t)=>e.children===t.children&&e.shikiTheme===t.shikiTheme&&e.isAnimating===t.isAnimating&&e.mode===t.mode&&e.plugins===t.plugins&&e.className===t.className&&e.linkSafety===t.linkSafety);d0.displayName="Streamdown";var Nx=({children:e,className:t,minZoom:n=.5,maxZoom:r=3,zoomStep:i=.1,showControls:a=!0,initialZoom:s=1,fullscreen:o=!1})=>{let u=Le(null),c=Le(null),[f,d]=le(s),[h,p]=le({x:0,y:0}),[m,_]=le(!1),[A,y]=le({x:0,y:0}),[I,S]=le({x:0,y:0}),D=Pe(B=>{d(Q=>Math.max(n,Math.min(r,Q+B)))},[n,r]),P=Pe(()=>{D(i)},[D,i]),w=Pe(()=>{D(-i)},[D,i]),z=Pe(()=>{d(s),p({x:0,y:0})},[s]),L=Pe(B=>{B.preventDefault();let Q=B.deltaY>0?-i:i;D(Q)},[D,i]),H=Pe(B=>{if(B.button!==0||B.isPrimary===!1)return;_(!0),y({x:B.clientX,y:B.clientY}),S(h);let Q=B.currentTarget;Q instanceof HTMLElement&&Q.setPointerCapture(B.pointerId)},[h]),C=Pe(B=>{if(!m)return;B.preventDefault();let Q=B.clientX-A.x,ae=B.clientY-A.y;p({x:I.x+Q,y:I.y+ae})},[m,A,I]),$=Pe(B=>{_(!1);let Q=B.currentTarget;Q instanceof HTMLElement&&Q.releasePointerCapture(B.pointerId)},[]);return we(()=>{let B=u.current;if(B)return B.addEventListener("wheel",L,{passive:!1}),()=>{B.removeEventListener("wheel",L)}},[L]),we(()=>{let B=c.current;if(B&&m)return document.body.style.userSelect="none",B.addEventListener("pointermove",C,{passive:!1}),B.addEventListener("pointerup",$),B.addEventListener("pointercancel",$),()=>{document.body.style.userSelect="",B.removeEventListener("pointermove",C),B.removeEventListener("pointerup",$),B.removeEventListener("pointercancel",$)}},[m,C,$]),b("div",{className:K("relative flex flex-col",o?"h-full w-full":"min-h-28 w-full",t),ref:u,style:{cursor:m?"grabbing":"grab"},children:[a?b("div",{className:K("absolute z-10 flex flex-col gap-1 rounded-md border border-border bg-background/90 p-1 shadow-sm backdrop-blur-sm",o?"bottom-4 left-4":"bottom-2 left-2"),children:[b("button",{className:"flex items-center justify-center rounded p-1.5 text-muted-foreground transition-colors hover:bg-muted hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",disabled:f>=r,onClick:P,title:"Zoom in",type:"button",children:b(zk,{size:16})}),b("button",{className:"flex items-center justify-center rounded p-1.5 text-muted-foreground transition-colors hover:bg-muted hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",disabled:f<=n,onClick:w,title:"Zoom out",type:"button",children:b($k,{size:16})}),b("button",{className:"flex items-center justify-center rounded p-1.5 text-muted-foreground transition-colors hover:bg-muted hover:text-foreground",onClick:z,title:"Reset zoom and pan",type:"button",children:b(Uk,{size:16})})]}):null,b("div",{className:K("flex-1 origin-center transition-transform duration-150 ease-out",o?"flex h-full w-full items-center justify-center":"flex w-full items-center justify-center"),onPointerDown:H,ref:c,role:"application",style:{transform:`translate(${h.x}px, ${h.y}px) scale(${f})`,transformOrigin:"center center",touchAction:"none",willChange:"transform"},children:e})]})},f0=({chart:e,className:t,config:n,fullscreen:r=!1,showControls:i=!0})=>{let[a,s]=le(null),[o,u]=le(!1),[c,f]=le(""),[d,h]=le(""),[p,m]=le(0),{mermaid:_}=Ge(Ze),A=fs(),y=_?.errorComponent,{shouldRender:I,containerRef:S}=Bk({immediate:r});if(we(()=>{if(I){if(!A){s("Mermaid plugin not available. Please add the mermaid plugin to enable diagram rendering.");return}(async()=>{try{s(null),u(!0);let P=A.getMermaid(n),w=e.split("").reduce((H,C)=>(H<<5)-H+C.charCodeAt(0)|0,0),z=`mermaid-${Math.abs(w)}-${Date.now()}-${Math.random().toString(36).substring(2,9)}`,{svg:L}=await P.render(z,e);f(L),h(L)}catch(P){if(!(d||c)){let w=P instanceof Error?P.message:"Failed to render Mermaid chart";s(w)}}finally{u(!1)}})()}},[e,n,p,I,A]),!(I||c||d))return b("div",{className:K("my-4 min-h-[200px]",t),ref:S});if(o&&!c&&!d)return b("div",{className:K("my-4 flex justify-center p-4",t),ref:S,children:b("div",{className:"flex items-center space-x-2 text-muted-foreground",children:[b("div",{className:"h-4 w-4 animate-spin rounded-full border-current border-b-2"}),b("span",{className:"text-sm",children:"Loading diagram..."})]})});if(a&&!c&&!d)return y?b("div",{ref:S,children:b(y,{chart:e,error:a,retry:()=>m(w=>w+1)})}):b("div",{className:K("rounded-lg border border-red-200 bg-red-50 p-4",t),ref:S,children:[b("p",{className:"font-mono text-red-700 text-sm",children:["Mermaid Error: ",a]}),b("details",{className:"mt-2",children:[b("summary",{className:"cursor-pointer text-red-600 text-xs",children:"Show Code"}),b("pre",{className:"mt-2 overflow-x-auto rounded bg-red-100 p-2 text-red-800 text-xs",children:e})]})]});let D=c||d;return b("div",{className:K("size-full",t),"data-streamdown":"mermaid",ref:S,children:b(Nx,{className:K(r?"size-full overflow-hidden":"my-4 overflow-hidden",t),fullscreen:r,maxZoom:3,minZoom:.5,showControls:i,zoomStep:.1,children:b("div",{"aria-label":"Mermaid chart",className:K("flex justify-center",r?"size-full items-center":null),dangerouslySetInnerHTML:{__html:D},role:"img"})})})};function vx({href:e,children:t}){return b("a",{href:e,target:"_blank",rel:"noopener noreferrer",class:"fr text-kin-accent underline underline-offset-2 transition-colors hover:decoration-2 focus-visible:rounded-[2px]",children:t})}const Lx={a:vx};function Rx({content:e,isStreaming:t=!1}){return e?b("div",{class:"kin-markdown text-kin-bubble-assistant-text text-sm leading-relaxed",children:b(d0,{isAnimating:t,mode:t?"streaming":"static",components:Lx,children:e})}):null}const Sn="h-2 w-2 animate-kin-typing rounded-full bg-kin-text-muted",h0="mt-1.5 inline-flex items-center gap-1.5 pl-1 text-xs text-kin-text-muted",Es=St({base:"flex flex-1 flex-col gap-4 overflow-y-auto break-words p-4 overscroll-contain pl-safe-l pr-safe-r sm:overscroll-auto sm:px-4 [&::-webkit-scrollbar]:w-1.5 [&::-webkit-scrollbar-track]:bg-transparent [&::-webkit-scrollbar-thumb]:rounded-[3px] [&::-webkit-scrollbar-thumb]:bg-kin-bg-muted",variants:{empty:{true:"items-center justify-center",false:""}}}),p0="animate-kin-fade-in px-6 py-6 text-center",m0={animationDelay:"150ms"},Ox=St({base:"animate-kin-message-in flex max-w-[85%] flex-col",variants:{side:{user:"self-end",assistant:"self-start"}}}),Dx=St({base:"rounded-2xl px-4 py-3",variants:{side:{user:"rounded-br bg-kin-bubble-user text-kin-bubble-user-text",assistant:"rounded-bl border border-kin-border bg-kin-bubble-assistant text-kin-bubble-assistant-text"}}});function Px(){const e=Pi(()=>Y.messages.value),t=Pi(()=>Y.isStreaming.value),n=Pi(()=>Y.connectionState.value),r=Le(null),i=()=>{r.current&&(r.current.scrollTop=r.current.scrollHeight)};if(we(()=>{const c=setTimeout(i,380);return()=>clearTimeout(c)},[]),we(()=>{i()},[e.value,t.value]),n.value==="connecting"&&e.value.length===0)return b("div",{class:Es({empty:!0}),role:"log","aria-label":"Chat messages","aria-live":"polite",children:b("div",{class:p0,style:m0,children:b("div",{class:"flex gap-1.5 p-2","aria-label":"Loading conversation",children:[b("span",{class:Sn}),b("span",{class:Sn,style:{animationDelay:"0.15s"}}),b("span",{class:Sn,style:{animationDelay:"0.3s"}})]})})});if(e.value.length===0&&!t.value)return b("div",{class:Es({empty:!0}),role:"log","aria-label":"Chat messages","aria-live":"polite",children:b("div",{class:p0,style:m0,children:[b("div",{class:"text-kin-text-muted size-12 mx-auto mb-4 opacity-50","aria-hidden":"true",children:b(V0,{class:"h-full w-full"})}),b("p",{class:"text-kin-text mb-2 text-base",children:"Hi there, you're speaking with Kin AI Agent."}),b("p",{class:"text-kin-text-muted text-sm",children:"How can I help you today?"})]})});const s=e.value[e.value.length-1],o=t.value&&s?.role==="assistant"&&!s.content.trim();let u=0;return b("div",{class:Es({empty:!1}),ref:r,role:"log","aria-label":"Chat messages","aria-live":"polite","aria-relevant":"additions",children:[b("div",{class:"text-kin-glow-1 flex items-center gap-3 text-xs font-medium uppercase tracking-wide before:h-px before:flex-1 before:bg-[linear-gradient(90deg,transparent,var(--kin-glow-1),transparent)] before:opacity-30 before:content-[''] after:h-px after:flex-1 after:bg-[linear-gradient(90deg,transparent,var(--kin-glow-1),transparent)] after:opacity-30 after:content-['']",role:"separator","aria-hidden":"true",children:b("span",{children:"New"})}),e.value.map((c,f)=>{if(c.role==="assistant"&&!c.content.trim())return null;const d=u;u+=1;const h=f===e.value.length-1,p=t.value&&h&&c.role==="assistant";return b(Bx,{message:c,isStreaming:p,animationIndex:d},c.id)}),o&&b(Mx,{})]})}function Mx(){return b("div",{class:"animate-kin-message-in inline-flex flex-col self-start",role:"status","aria-label":"Kin is typing",children:[b("div",{class:"min-h-11 border-kin-border bg-kin-bubble-assistant inline-flex w-fit items-center gap-1.5 rounded-2xl rounded-bl border px-4 py-3","aria-hidden":"true",children:[b("span",{class:Sn}),b("span",{class:Sn,style:{animationDelay:"0.15s"}}),b("span",{class:Sn,style:{animationDelay:"0.3s"}})]}),b("div",{class:h0,"aria-hidden":"true",children:[b("span",{children:"Kin"}),b("span",{children:"•"}),b("span",{children:"AI Agent"}),b("span",{children:"•"}),b("span",{children:"typing..."})]}),b("span",{class:"sr-only",children:"Kin AI Agent is typing a response"})]})}function Bx({message:e,isStreaming:t=!1,animationIndex:n}){const r=e.role==="user",i=e.role==="system",a=r?"user":"assistant",s=r?"You":i?"System":"Kin AI Agent",o=Math.min((n+1)*.05,.35);return i?b("div",{class:"flex justify-center px-4 py-2",role:"status","aria-label":"System notification",children:b("span",{class:"border-kin-border bg-kin-bg-surface text-kin-text-muted rounded-xl border px-3 py-1.5 text-xs",children:e.content})}):b("article",{class:Ox({side:a}),style:{animationDelay:`${o}s`},"aria-label":`Message from ${s}`,children:[b("div",{class:Dx({side:a}),children:r?b("p",{children:e.content}):b(Rx,{content:e.content,isStreaming:t})}),!r&&b("div",{class:h0,"aria-hidden":"true",children:[b("span",{children:"Kin"}),b("span",{children:"•"}),b("span",{children:"AI Agent"}),b("span",{children:"•"}),b("span",{children:t?"typing...":Fx(e.timestamp)})]})]})}function Fx(e){const n=new Date().getTime()-e.getTime();return n<6e4?"Just now":n<36e5?`${Math.floor(n/6e4)}m ago`:e.toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"})}const g0=St({base:"fr inline-flex size-11 items-center justify-center rounded-lg transition-colors duration-200 sm:size-8 [&>svg]:size-4",variants:{variant:{close:"bg-transparent text-kin-text-muted hover:bg-kin-bg-muted hover:text-kin-text",clear:"bg-transparent text-sm text-kin-accent hover:bg-kin-bg-muted",confirm:"text-sm bg-kin-accent text-white hover:opacity-90"}},defaultVariants:{variant:"close"}});function Hx({onClose:e,onClearData:t,onSkipToInput:n}){const[r,i]=le(!1),a=o=>{o.key==="Escape"&&(o.preventDefault(),r?i(!1):e())},s=()=>{r?(t(),i(!1)):i(!0)};return b("div",{class:"kin-panel bg-kin-bg-base sm:border-kin-border sm:shadow-kin-panel sm:animate-kin-panel-in sm:w-kin-panel flex h-auto min-h-0 w-full max-w-none flex-1 animate-none flex-col overflow-hidden rounded-none border-0 shadow-none [will-change:transform,opacity] sm:max-w-[calc(100vw-2rem)] sm:rounded-2xl sm:border",role:"dialog","aria-modal":"true","aria-labelledby":"kin-panel-title",onKeyDown:a,children:[b("button",{type:"button",class:"fr bg-kin-bg-elevated text-kin-text absolute -top-full left-1/2 z-[1000000] -translate-x-1/2 rounded-lg px-4 py-2 font-medium no-underline focus:top-2",onClick:n,children:"Skip to chat input"}),b("header",{class:"border-kin-border bg-kin-bg-elevated pl-safe-l pr-safe-r pt-safe-t flex items-center justify-between border-b px-4 pb-4 sm:p-4",children:[b("h2",{id:"kin-panel-title",class:"text-kin-text text-base font-semibold sm:text-sm sm:font-medium",children:"Kin Assistant"}),b("div",{class:"flex items-center gap-1",children:[b("button",{class:g0({variant:r?"confirm":"clear"}),"aria-label":r?"Confirm clear data":"Clear my data",title:r?"Click again to confirm":"Clear my data",type:"button",onClick:s,onBlur:()=>i(!1),children:r?"✓":b(G0,{})}),b("button",{class:g0({variant:"close"}),"aria-label":"Close chat",type:"button",onClick:e,children:b(W0,{})})]})]}),b(Px,{})]})}const Ux={"application/pdf":{maxSize:1e7},"application/vnd.openxmlformats-officedocument.wordprocessingml.document":{maxSize:1e7},"application/msword":{maxSize:1e7},"text/plain":{maxSize:1e6},"image/jpeg":{maxSize:1e7},"image/png":{maxSize:1e7},"image/webp":{maxSize:1e7}},zx=".pdf,.docx,.doc,.txt,.jpg,.jpeg,.png,.webp";function $x(e){const t=Ux[e.type];return t?e.size>t.maxSize?{valid:!1,error:`File is too large. Maximum size is ${Math.round(t.maxSize/1e6)}MB.`}:e.size===0?{valid:!1,error:"The file appears to be empty."}:{valid:!0}:{valid:!1,error:"Unsupported file format. Please upload a PDF, Word document, text file, or image."}}function Yx(e){return new Promise((t,n)=>{const r=new FileReader;r.onload=()=>{typeof r.result=="string"?t(r.result):n(new Error("Failed to read file"))},r.onerror=()=>n(r.error),r.readAsDataURL(e)})}function jx({url:e,onMessage:t,onOpen:n,onClose:r,onError:i}){let a=null,s=[];const o=()=>{if(!(!a||a.readyState!==WebSocket.OPEN)){for(const c of s)a.send(JSON.stringify({type:"user_message",content:c}));s=[]}};return(()=>{a=new WebSocket(e),a.onopen=()=>{n(),o()},a.onmessage=c=>{try{const f=JSON.parse(c.data);t(f)}catch{}},a.onclose=()=>{s=[],r(),a=null},a.onerror=c=>{i(c)}})(),{sendMessage:c=>{a&&(a.readyState===WebSocket.OPEN?a.send(JSON.stringify({type:"user_message",content:c})):a.readyState===WebSocket.CONNECTING&&s.push(c))},uploadFile:async(c,f)=>{if(!a||a.readyState!==WebSocket.OPEN)return{success:!1,error:"Not connected"};const d=$x(c);if(!d.valid)return{success:!1,error:d.error};try{const h=await Yx(c);return!a||a.readyState!==WebSocket.OPEN?{success:!1,error:"Connection lost while reading file. Please try again."}:(a.send(JSON.stringify({type:"file_upload",fileType:f,fileName:c.name,mimeType:c.type,data:h})),{success:!0})}catch(h){return{success:!1,error:h instanceof Error?h.message:"Failed to read file"}}},clearData:()=>{a&&a.readyState===WebSocket.OPEN&&a.send(JSON.stringify({type:"clear_data"}))},disconnect:()=>{a&&(a.close(),a=null)},isConnected:()=>a?.readyState===WebSocket.OPEN}}const b0=2e3,E0="absolute bottom-full left-1/2 mb-2 -translate-x-1/2 whitespace-nowrap rounded-lg bg-red-600 px-3 py-2 text-xs text-white animate-kin-error-in",Vx="inline-flex items-center whitespace-nowrap rounded-3xl ring-1 ring-[color-mix(in_srgb,var(--kin-accent)_30%,transparent)] bg-[color-mix(in_srgb,var(--kin-accent)_12%,transparent)] px-3.5 py-1.5 text-sm font-medium text-kin-accent opacity-0 transition-[background,shadow,transform] duration-150 hover:ring-kin-accent hover:bg-kin-accent hover:text-white focus-visible:shadow-[0_0_0_2px_var(--kin-focus-ring)] active:scale-95 animate-kin-starter-fade-in",qx=St({base:"kin-launcher w-full max-w-full sm:max-w-[calc(100vw-3rem)] sm:focus-within:w-kin-panel",variants:{open:{true:"border-t border-kin-border sm:w-kin-panel sm:border-0",false:"px-3 pt-2 pb-safe-b sm:w-96 sm:px-0 sm:pt-0 sm:pb-0 sm:transition-[width] sm:duration-300 sm:ease-kin-open"}}}),Wx=St({base:"kin-launcher-input-wrapper relative flex rounded-3xl [&::before]:hidden [&::after]:hidden sm:[&::before]:block sm:[&::after]:block",variants:{open:{true:"rounded-none bg-kin-bg-base shadow-none px-3 pt-2 pb-safe-b sm:rounded-3xl sm:bg-kin-bg-elevated sm:shadow-kin-border",false:"bg-kin-bg-elevated shadow-kin-border focus-within:shadow-[0_0_0_2px_var(--kin-accent)] sm:focus-within:shadow-kin-border"},pills:{true:"flex-col items-stretch gap-2 pt-2.5 pb-1 pl-3.5 pr-1.5 sm:py-1 sm:pt-2.5",false:"items-center gap-2 py-1.5 pl-4 pr-1.5 sm:gap-3 sm:py-1"}}}),T0=St({base:"fr inline-flex size-10 shrink-0 items-center justify-center rounded-full transition-all duration-200 disabled:cursor-not-allowed disabled:opacity-50 sm:size-9 [&>svg]:size-4",variants:{variant:{attach:"-mr-2 bg-transparent text-kin-text-muted hover:bg-kin-bg-muted hover:text-kin-text",send:"kin-launcher-send bg-kin-bg-muted text-kin-text-muted enabled:bg-kin-accent enabled:text-white enabled:hover:scale-105 sm:enabled:bg-kin-text sm:enabled:text-kin-bg-base"}}});function Gx({isOpen:e,starterPrompts:t,onOpen:n,onClose:r,onSendMessage:i,onConnect:a,onUploadFile:s,inputRef:o}){const[u,c]=le(""),[f,d]=le(!1),h=Le(null),p=o??h,m=Le(null),[_,A]=le(Y.isStreaming.value),[y,I]=le(Y.connectionState.value),[S,D]=le(Y.messages.value.length>0),[P,w]=le(Y.uploadState.value),[z,L]=le(Y.uploadError.value),[H,C]=le(Y.uploadFileName.value),[$,B]=le(Y.quickReplies.value);we(()=>Dn(()=>{A(Y.isStreaming.value),I(Y.connectionState.value),D(Y.messages.value.length>0),w(Y.uploadState.value),L(Y.uploadError.value),C(Y.uploadFileName.value),B(Y.quickReplies.value)}),[]);const Q=y==="connected",ae=y==="connecting",X=y==="disconnected",Z=y==="idle",ee=P==="uploading"||P==="processing",q=u.length>b0,Ye=u.trim(),x=Ye.length>0,Oe=x&&!_&&!ee&&!q&&(Q||ae),He=Q&&!_&&!ee;we(()=>{e&&p.current&&requestAnimationFrame(()=>{p.current?.focus()})},[e]);const k=()=>{d(!0),a(),!e&&S&&n()},me=ue=>{ue.relatedTarget?.closest(".kin-launcher-input-wrapper")||d(!1)},je=ue=>{if(ue.preventDefault(),!Oe)return;const De=Ye;Y.addMessage({role:"user",content:De}),e||n(),i(De),c("")},ye=ue=>{ue.key==="Enter"&&!ue.shiftKey&&(ue.preventDefault(),je(ue)),ue.key==="Escape"&&e&&(ue.preventDefault(),ue.stopPropagation(),r())},Ee=ue=>{const De=ue.target,Ht=De.files?.[0];Ht&&(e||n(),s(Ht,"cv")),De.value=""},Je=()=>{m.current?.click()},et=()=>ee?H?`Uploading ${H}...`:"Uploading file...":ae?"Connecting...":X?"Disconnected - Click to retry":_?"Waiting for response...":!e&&S?"Continue conversation...":"Ask me anything...",tt=()=>ee?H?`Uploading ${H}...`:"Uploading file...":_?"Waiting for response":Z?"Click to connect":ae?"Connecting...":!Q&&!x?"Enter a message to send":Q?x?"Send message":"Enter a message to send":"Cannot send message",Et=()=>ee?"Uploading...":He?"Attach file (CV, document, or image)":"Cannot upload file",Ft=ue=>{a(),Y.addMessage({role:"user",content:ue.message}),n(),i(ue.message)},_s=ue=>{e||n(),a(),Y.addMessage({role:"user",content:ue}),i(ue)},ks=$.length>0&&e,pr=t.length>0&&!S&&f,In=ks||pr,xi=ue=>`${Math.min(.03+ue*.04,.19)}s`,yi=({key:ue,label:De,index:Ht,onClick:xs,onPointerDown:ys})=>b("button",{type:"button",class:Vx,style:{animationDelay:xi(Ht)},onPointerDown:ys,onClick:xs,children:De},ue);return b("div",{class:qx({open:e}),role:"search","aria-label":"Chat with Kin AI",children:b("form",{onSubmit:je,class:"relative",children:[b("div",{class:Wx({open:e,pills:In}),children:[In&&b("div",{class:"flex flex-wrap gap-1.5",children:pr?t.map((ue,De)=>yi({key:`s-${De}`,label:ue.label,index:De,onPointerDown:Ht=>Ht.preventDefault(),onClick:()=>Ft(ue)})):$.map((ue,De)=>yi({key:`q-${De}`,label:ue,index:De,onClick:()=>_s(ue)}))}),b("div",{class:"flex flex-1 items-center gap-3",children:[b("label",{for:"kin-input",class:"sr-only",children:"Ask Kin a question"}),b("input",{id:"kin-input",ref:p,type:"text",class:"text-kin-text placeholder:text-kin-text-muted min-w-0 flex-1 border-none bg-transparent py-2.5 text-base outline-none disabled:cursor-not-allowed sm:py-3 sm:text-sm",placeholder:In?"Or type a message...":et(),value:u,onInput:ue=>c(ue.target.value),onFocus:k,onBlur:me,onKeyDown:ye,"aria-describedby":"kin-input-status",autoComplete:"off",disabled:ee}),b("input",{ref:m,type:"file",class:"sr-only",accept:zx,onChange:Ee,"aria-hidden":"true",tabIndex:-1}),b("button",{type:"button",class:T0({variant:"attach"}),disabled:!He,"aria-label":Et(),onClick:Je,children:ee?b(K0,{class:"animate-kin-spin"}):b(Q0,{})}),b("button",{type:"submit",class:T0({variant:"send"}),disabled:!Oe,"aria-label":tt(),children:b(q0,{})})]})]}),b("div",{id:"kin-input-status",class:"sr-only",role:"status","aria-live":"polite",children:[ae&&"Connecting to Kin...",X&&"Connection lost. Click input to retry.",_&&"Kin is responding...",ee&&(H?`Uploading ${H}...`:"Uploading file...")]}),z&&P==="error"&&b("div",{class:`${E0} max-w-[calc(100%-32px)] truncate`,role:"alert",children:z}),q&&b("div",{class:E0,role:"alert",children:["Message too long (",u.length.toLocaleString(),"/",b0.toLocaleString()," characters)"]})]})})}const Qx=St({base:"kin-widget font-kin text-kin text-kin-text fixed inset-x-0 bottom-0 z-[999999] flex w-full flex-col items-stretch overflow-hidden sm:inset-x-auto sm:bottom-6 sm:left-1/2 sm:w-auto sm:-translate-x-1/2 sm:items-center sm:gap-4 sm:overflow-visible",variants:{open:{true:"top-0 h-dvh bg-kin-bg-base [touch-action:manipulation] sm:top-auto sm:h-auto sm:min-h-[50vh] sm:max-h-[90vh] sm:bg-transparent sm:[touch-action:auto]",false:""}}});function Kx({starterPrompts:e,onSendMessage:t,onOpen:n,onClose:r,onConnect:i,onClearData:a,onUploadFile:s,embedded:o=!1}){const[u,c]=le(o||Y.isOpen.value),f=Le(null),d=Le(null),h=Le(null);we(()=>Dn(()=>{c(o||Y.isOpen.value)}),[o]),we(()=>{o&&!Y.isOpen.value&&n()},[o,n]),we(()=>{if(!u||o)return;const A=window.matchMedia("(max-width: 639px)");let y=0,I="",S=!1;const D=()=>{S||(y=window.scrollY,I=document.body.style.overflow,document.body.style.overflow="hidden",S=!0)},P=()=>{S&&(document.body.style.overflow=I,window.scrollTo(0,y),S=!1)},w=()=>{A.matches?D():P()};return w(),A.addEventListener("change",w),()=>{A.removeEventListener("change",w),P()}},[u,o]);const p=Pe(()=>{d.current=document.activeElement,n()},[n]),m=Pe(()=>{r(),d.current?.focus()},[r]),_=Pe(()=>{h.current?.focus()},[]);return we(()=>{if(!u)return;const A=()=>{let I=document.activeElement;for(;I?.shadowRoot?.activeElement;)I=I.shadowRoot.activeElement;return I},y=I=>{if(I.key!=="Tab")return;const S=f.current;if(!S)return;const D=S.querySelectorAll('button:not([disabled]), input:not([disabled]), [tabindex]:not([tabindex="-1"])');if(D.length===0)return;const P=D[0],w=D[D.length-1];if(!P||!w)return;const z=A();I.shiftKey&&z===P?(I.preventDefault(),w.focus()):!I.shiftKey&&z===w&&(I.preventDefault(),P.focus())};return document.addEventListener("keydown",y),()=>document.removeEventListener("keydown",y)},[u]),b("div",{ref:f,class:Qx({open:u}),role:"region","aria-label":"Kin AI Chat",children:[b("div",{class:"sr-only",role:"status","aria-live":"polite","aria-atomic":"true",children:u?"Chat panel opened":""}),u&&b(Hx,{onClose:m,onClearData:a,onSkipToInput:_}),b(Gx,{isOpen:u,starterPrompts:e,onOpen:p,onClose:m,onSendMessage:t,onConnect:i,onUploadFile:s,inputRef:h})]})}const Xx=`*{box-sizing:border-box;font:inherit;border:0 solid;-webkit-tap-highlight-color:transparent}button{all:unset;cursor:pointer;touch-action:manipulation}ul,ol,li,p{margin:0;padding:0}ul,ol{list-style:none}svg{display:block}*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}.visible{visibility:visible}.static{position:static}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.inset-x-0{left:0;right:0}.-top-full{top:-100%}.bottom-0{bottom:0}.bottom-full{bottom:100%}.left-1\\/2{left:50%}.top-0{top:0}.z-\\[1000000\\]{z-index:1000000}.z-\\[999999\\]{z-index:999999}.mx-auto{margin-left:auto;margin-right:auto}.-mr-2{margin-right:-.5rem}.mb-2{margin-bottom:.5rem}.mb-4{margin-bottom:1rem}.mt-1\\.5{margin-top:.375rem}.block{display:block}.inline{display:inline}.flex{display:flex}.inline-flex{display:inline-flex}.hidden{display:none}.size-10{width:2.5rem;height:2.5rem}.size-11{width:2.75rem;height:2.75rem}.size-12{width:3rem;height:3rem}.h-2{height:.5rem}.h-auto{height:auto}.h-dvh{height:100dvh}.h-full{height:100%}.min-h-0{min-height:0px}.min-h-11{min-height:2.75rem}.w-2{width:.5rem}.w-fit{width:-moz-fit-content;width:fit-content}.w-full{width:100%}.min-w-0{min-width:0px}.max-w-\\[85\\%\\]{max-width:85%}.max-w-\\[calc\\(100\\%-32px\\)\\]{max-width:calc(100% - 32px)}.max-w-full{max-width:100%}.max-w-none{max-width:none}.flex-1{flex:1 1 0%}.shrink-0{flex-shrink:0}.-translate-x-1\\/2{--tw-translate-x: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes kin-error-in{0%{opacity:0;transform:translate(-50%) translateY(4px)}to{opacity:1;transform:translate(-50%) translateY(0)}}.animate-kin-error-in{animation:kin-error-in .2s ease}.animate-kin-fade-in{animation:kin-fade .4s ease both}@keyframes kin-slide-up{0%{opacity:0;transform:translateY(8px)}to{opacity:1;transform:translateY(0)}}.animate-kin-message-in{animation:kin-slide-up .3s cubic-bezier(.32,.72,0,1) both}@keyframes spin{to{transform:rotate(360deg)}}.animate-kin-spin{animation:spin 1s linear infinite}@keyframes kin-fade{0%{opacity:0}to{opacity:1}}.animate-kin-starter-fade-in{animation:kin-fade .22s ease-out forwards}@keyframes kin-typing{0%,to{opacity:.3;transform:scale(.85)}50%{opacity:1;transform:scale(1)}}.animate-kin-typing{animation:kin-typing 1.4s ease-in-out infinite}.animate-none{animation:none}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.items-center{align-items:center}.items-stretch{align-items:stretch}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-1{gap:.25rem}.gap-1\\.5{gap:.375rem}.gap-2{gap:.5rem}.gap-3{gap:.75rem}.gap-4{gap:1rem}.self-start{align-self:flex-start}.self-end{align-self:flex-end}.overflow-hidden{overflow:hidden}.overflow-y-auto{overflow-y:auto}.overscroll-contain{overscroll-behavior:contain}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.whitespace-nowrap{white-space:nowrap}.break-words{overflow-wrap:break-word}.rounded-2xl{border-radius:1rem}.rounded-3xl{border-radius:1.5rem}.rounded-full{border-radius:9999px}.rounded-lg{border-radius:.5rem}.rounded-none{border-radius:0}.rounded-xl{border-radius:.75rem}.rounded-bl{border-bottom-left-radius:.25rem}.rounded-br{border-bottom-right-radius:.25rem}.border{border-width:1px}.border-0{border-width:0px}.border-b{border-bottom-width:1px}.border-t{border-top-width:1px}.border-none{border-style:none}.border-kin-border{border-color:var(--kin-border)}.bg-\\[color-mix\\(in_srgb\\,var\\(--kin-accent\\)_12\\%\\,transparent\\)\\]{background-color:color-mix(in srgb,var(--kin-accent) 12%,transparent)}.bg-kin-accent{background-color:var(--kin-accent)}.bg-kin-bg-base{background-color:var(--kin-bg-base)}.bg-kin-bg-elevated{background-color:var(--kin-bg-elevated)}.bg-kin-bg-muted{background-color:var(--kin-bg-muted)}.bg-kin-bg-surface{background-color:var(--kin-bg-surface)}.bg-kin-bubble-assistant{background-color:var(--kin-bubble-assistant)}.bg-kin-bubble-user{background-color:var(--kin-bubble-user)}.bg-kin-text-muted{background-color:var(--kin-text-muted)}.bg-red-600{--tw-bg-opacity: 1;background-color:rgb(220 38 38 / var(--tw-bg-opacity))}.bg-transparent{background-color:transparent}.p-2{padding:.5rem}.p-4{padding:1rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-3\\.5{padding-left:.875rem;padding-right:.875rem}.px-4{padding-left:1rem;padding-right:1rem}.px-6{padding-left:1.5rem;padding-right:1.5rem}.py-1\\.5{padding-top:.375rem;padding-bottom:.375rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-2\\.5{padding-top:.625rem;padding-bottom:.625rem}.py-3{padding-top:.75rem;padding-bottom:.75rem}.py-6{padding-top:1.5rem;padding-bottom:1.5rem}.pb-1{padding-bottom:.25rem}.pb-4{padding-bottom:1rem}.pb-safe-b{padding-bottom:max(.5rem,calc(env(safe-area-inset-bottom,0px) + .5rem))}.pl-1{padding-left:.25rem}.pl-3\\.5{padding-left:.875rem}.pl-4{padding-left:1rem}.pl-safe-l{padding-left:max(1rem,env(safe-area-inset-left,1rem))}.pr-1\\.5{padding-right:.375rem}.pr-safe-r{padding-right:max(1rem,env(safe-area-inset-right,1rem))}.pt-2{padding-top:.5rem}.pt-2\\.5{padding-top:.625rem}.pt-safe-t{padding-top:max(1rem,env(safe-area-inset-top,1rem))}.text-center{text-align:center}.font-kin{font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,sans-serif}.text-base{font-size:1rem;line-height:1.5rem}.text-kin{font-size:max(14px,1rem);line-height:1.5}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xs{font-size:.75rem;line-height:1rem}.font-medium{font-weight:500}.font-semibold{font-weight:600}.uppercase{text-transform:uppercase}.leading-relaxed{line-height:1.625}.tracking-wide{letter-spacing:.025em}.text-kin-accent{color:var(--kin-accent)}.text-kin-bubble-assistant-text{color:var(--kin-bubble-assistant-text)}.text-kin-bubble-user-text{color:var(--kin-bubble-user-text)}.text-kin-glow-1{color:var(--kin-glow-1)}.text-kin-text{color:var(--kin-text)}.text-kin-text-muted{color:var(--kin-text-muted)}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity))}.underline{text-decoration-line:underline}.no-underline{text-decoration-line:none}.underline-offset-2{text-underline-offset:2px}.opacity-0{opacity:0}.opacity-50{opacity:.5}.shadow{--tw-shadow: 0 1px 3px 0 rgb(0 0 0 / .1), 0 1px 2px -1px rgb(0 0 0 / .1);--tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-kin-border{--tw-shadow: 0 0 0 1px var(--kin-border);--tw-shadow-colored: 0 0 0 1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-none{--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-kin-border{--tw-shadow-color: var(--kin-border);--tw-shadow: var(--tw-shadow-colored)}.outline-none{outline:2px solid transparent;outline-offset:2px}.ring-1{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.ring-\\[color-mix\\(in_srgb\\,var\\(--kin-accent\\)_30\\%\\,transparent\\)\\]{--tw-ring-color: color-mix(in srgb,var(--kin-accent) 30%,transparent)}.blur{--tw-blur: blur(8px);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.transition-\\[background\\,shadow\\,transform\\]{transition-property:background,shadow,transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-150{transition-duration:.15s}.duration-200{transition-duration:.2s}.fr:focus-visible{outline:2px solid var(--kin-accent);outline-offset:2px}.\\[touch-action\\:manipulation\\]{touch-action:manipulation}.\\[will-change\\:transform\\,opacity\\]{will-change:transform,opacity}:host{--kin-bg-base: #0a0a0a;--kin-bg-elevated: #141414;--kin-bg-surface: #1a1a1a;--kin-bg-muted: #262626;--kin-border: rgba(255, 255, 255, .08);--kin-border-subtle: rgba(255, 255, 255, .05);--kin-text: #ffffff;--kin-text-secondary: #a1a1a1;--kin-text-muted: #8a8a8a;--kin-accent: #635bff;--kin-bubble-user: #f5f5f5;--kin-bubble-user-text: #171717;--kin-bubble-assistant: #1a1a1a;--kin-bubble-assistant-text: #ffffff;--kin-glow-1: #ff6b6b;--kin-glow-2: #c850c0;--kin-glow-3: #635bff;--kin-focus-ring: var(--kin-accent);--kin-transition: .2s ease}.kin-launcher-input-wrapper:before,.kin-launcher-input-wrapper:after{content:"";position:absolute;background:linear-gradient(90deg,var(--kin-glow-1),var(--kin-glow-2),var(--kin-glow-3),var(--kin-glow-2),var(--kin-glow-1));background-size:300% 100%;animation:kin-gradient 4s ease infinite;transition:opacity var(--kin-transition);pointer-events:none}.kin-launcher-input-wrapper:before{inset:-1px;border-radius:25px;padding:2px;-webkit-mask:linear-gradient(#fff 0 0) content-box,linear-gradient(#fff 0 0);mask:linear-gradient(#fff 0 0) content-box,linear-gradient(#fff 0 0);-webkit-mask-composite:xor;mask-composite:exclude;opacity:.85}.kin-launcher-input-wrapper:after{inset:-2px;border-radius:26px;filter:blur(6px);opacity:.35;z-index:-1}.kin-launcher-input-wrapper:focus-within:before{opacity:1}.kin-launcher-input-wrapper:focus-within:after{opacity:.5}@keyframes kin-gradient{0%,to{background-position:0% 50%}50%{background-position:100% 50%}}.kin-markdown p{margin:0 0 1em}.kin-markdown p:last-child{margin-bottom:0}.kin-markdown :is(strong,b){font-weight:600}.kin-markdown :is(em,i){font-style:italic}.kin-markdown code{background:rgba(255,255,255,.1);padding:.15em .4em;border-radius:4px;font-family:SF Mono,Monaco,Consolas,monospace;font-size:.875em}.kin-markdown pre{background:rgba(0,0,0,.4);padding:14px 16px;border-radius:8px;overflow-x:auto;margin:1em 0;border:1px solid var(--kin-border)}.kin-markdown pre code{background:none;padding:0;font-size:.85em;line-height:1.5}.kin-markdown :is(ul,ol){margin:.75em 0;padding-left:1.5em}.kin-markdown ul{list-style-type:disc}.kin-markdown ol{list-style-type:decimal}.kin-markdown li{margin:.35em 0}.kin-markdown li::marker{color:var(--kin-text-muted)}.kin-markdown :is(ul,ol) :is(ul,ol){margin:.25em 0}.kin-markdown blockquote{border-left:3px solid var(--kin-accent);margin:1em 0;padding:.5em 0 .5em 1em;color:var(--kin-text-secondary);font-style:italic}.kin-markdown :is(h1,h2,h3,h4){font-weight:600;margin:1.25em 0 .5em;line-height:1.3}.kin-markdown :is(h1,h2,h3):first-child{margin-top:0}.kin-markdown h1{font-size:1.4em}.kin-markdown h2{font-size:1.25em}.kin-markdown h3{font-size:1.1em}.kin-markdown table{width:100%;border-collapse:collapse;margin:1em 0;font-size:.9em}.kin-markdown :is(th,td){padding:.5em .75em;border:1px solid var(--kin-border);text-align:left}.kin-markdown th{background:var(--kin-bg-muted);font-weight:600}.kin-markdown hr{border:none;border-top:1px solid var(--kin-border);margin:1.5em 0}.kin-markdown hr+p{display:flex;flex-wrap:wrap;align-items:center;gap:5px;font-size:.75em;color:var(--kin-text-muted);margin:-1em 0 0;line-height:1.6}.kin-markdown hr+p a{display:inline-flex;align-items:center;padding:1px 8px 2px;background:color-mix(in srgb,var(--kin-accent) 10%,transparent);border:1px solid color-mix(in srgb,var(--kin-accent) 22%,transparent);border-radius:10px;color:var(--kin-accent);text-decoration:none;font-weight:500;white-space:nowrap;transition:background var(--kin-transition),border-color var(--kin-transition)}.kin-markdown hr+p a:hover{background:color-mix(in srgb,var(--kin-accent) 20%,transparent);border-color:var(--kin-accent)}.kin-markdown input[type=checkbox]{margin-right:.5em;accent-color:var(--kin-accent)}.kin-markdown .streamdown-caret{display:inline-block;width:2px;height:1em;background:var(--kin-accent);margin-left:2px;animation:kin-caret 1s ease-in-out infinite;vertical-align:text-bottom}@keyframes kin-caret{0%,to{opacity:1}50%{opacity:0}}@media (prefers-reduced-motion: reduce){*,*:before,*:after{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important}}@media (forced-colors: active){.kin-launcher-input-wrapper:before,.kin-launcher-input-wrapper:after{display:none}.kin-launcher-input-wrapper,.kin-panel,button{border:1px solid ButtonBorder!important}}.placeholder\\:text-kin-text-muted::-moz-placeholder{color:var(--kin-text-muted)}.placeholder\\:text-kin-text-muted::placeholder{color:var(--kin-text-muted)}.before\\:h-px:before{content:var(--tw-content);height:1px}.before\\:flex-1:before{content:var(--tw-content);flex:1 1 0%}.before\\:bg-\\[linear-gradient\\(90deg\\,transparent\\,var\\(--kin-glow-1\\)\\,transparent\\)\\]:before{content:var(--tw-content);background-image:linear-gradient(90deg,transparent,var(--kin-glow-1),transparent)}.before\\:opacity-30:before{content:var(--tw-content);opacity:.3}.before\\:content-\\[\\'\\'\\]:before{--tw-content: "";content:var(--tw-content)}.after\\:h-px:after{content:var(--tw-content);height:1px}.after\\:flex-1:after{content:var(--tw-content);flex:1 1 0%}.after\\:bg-\\[linear-gradient\\(90deg\\,transparent\\,var\\(--kin-glow-1\\)\\,transparent\\)\\]:after{content:var(--tw-content);background-image:linear-gradient(90deg,transparent,var(--kin-glow-1),transparent)}.after\\:opacity-30:after{content:var(--tw-content);opacity:.3}.after\\:content-\\[\\'\\'\\]:after{--tw-content: "";content:var(--tw-content)}.focus-within\\:shadow-\\[0_0_0_2px_var\\(--kin-accent\\)\\]:focus-within{--tw-shadow: 0 0 0 2px var(--kin-accent);--tw-shadow-colored: 0 0 0 2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.hover\\:bg-kin-accent:hover{background-color:var(--kin-accent)}.hover\\:bg-kin-bg-muted:hover{background-color:var(--kin-bg-muted)}.hover\\:text-kin-text:hover{color:var(--kin-text)}.hover\\:text-white:hover{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity))}.hover\\:decoration-2:hover{text-decoration-thickness:2px}.hover\\:opacity-90:hover{opacity:.9}.hover\\:ring-kin-accent:hover{--tw-ring-color: var(--kin-accent)}.focus\\:top-2:focus{top:.5rem}.focus-visible\\:rounded-\\[2px\\]:focus-visible{border-radius:2px}.focus-visible\\:shadow-\\[0_0_0_2px_var\\(--kin-focus-ring\\)\\]:focus-visible{--tw-shadow: 0 0 0 2px var(--kin-focus-ring);--tw-shadow-colored: 0 0 0 2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.active\\:scale-95:active{--tw-scale-x: .95;--tw-scale-y: .95;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.enabled\\:bg-kin-accent:enabled{background-color:var(--kin-accent)}.enabled\\:text-white:enabled{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity))}.enabled\\:hover\\:scale-105:hover:enabled{--tw-scale-x: 1.05;--tw-scale-y: 1.05;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.disabled\\:cursor-not-allowed:disabled{cursor:not-allowed}.disabled\\:opacity-50:disabled{opacity:.5}@media (min-width: 640px){.sm\\:inset-x-auto{left:auto;right:auto}.sm\\:bottom-6{bottom:1.5rem}.sm\\:left-1\\/2{left:50%}.sm\\:top-auto{top:auto}.sm\\:size-8{width:2rem;height:2rem}.sm\\:size-9{width:2.25rem;height:2.25rem}.sm\\:h-auto{height:auto}.sm\\:max-h-\\[90vh\\]{max-height:90vh}.sm\\:min-h-\\[50vh\\]{min-height:50vh}.sm\\:w-96{width:24rem}.sm\\:w-auto{width:auto}.sm\\:w-kin-panel{width:450px}.sm\\:max-w-\\[calc\\(100vw-2rem\\)\\]{max-width:calc(100vw - 2rem)}.sm\\:max-w-\\[calc\\(100vw-3rem\\)\\]{max-width:calc(100vw - 3rem)}.sm\\:-translate-x-1\\/2{--tw-translate-x: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes kin-slide-up{0%{opacity:0;transform:translateY(8px)}to{opacity:1;transform:translateY(0)}}.sm\\:animate-kin-panel-in{animation:kin-slide-up .35s cubic-bezier(.32,.72,0,1) both}.sm\\:items-center{align-items:center}.sm\\:gap-3{gap:.75rem}.sm\\:gap-4{gap:1rem}.sm\\:overflow-visible{overflow:visible}.sm\\:overscroll-auto{overscroll-behavior:auto}.sm\\:rounded-2xl{border-radius:1rem}.sm\\:rounded-3xl{border-radius:1.5rem}.sm\\:border{border-width:1px}.sm\\:border-0{border-width:0px}.sm\\:border-kin-border{border-color:var(--kin-border)}.sm\\:bg-kin-bg-elevated{background-color:var(--kin-bg-elevated)}.sm\\:bg-transparent{background-color:transparent}.sm\\:p-4{padding:1rem}.sm\\:px-0{padding-left:0;padding-right:0}.sm\\:px-4{padding-left:1rem;padding-right:1rem}.sm\\:py-1{padding-top:.25rem;padding-bottom:.25rem}.sm\\:py-3{padding-top:.75rem;padding-bottom:.75rem}.sm\\:pb-0{padding-bottom:0}.sm\\:pt-0{padding-top:0}.sm\\:pt-2\\.5{padding-top:.625rem}.sm\\:text-sm{font-size:.875rem;line-height:1.25rem}.sm\\:font-medium{font-weight:500}.sm\\:shadow-kin-border{--tw-shadow: 0 0 0 1px var(--kin-border);--tw-shadow-colored: 0 0 0 1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.sm\\:shadow-kin-panel{--tw-shadow: 0 4px 24px rgba(0, 0, 0, .12), 0 0 0 1px var(--kin-border);--tw-shadow-colored: 0 4px 24px var(--tw-shadow-color), 0 0 0 1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.sm\\:shadow-kin-border{--tw-shadow-color: var(--kin-border);--tw-shadow: var(--tw-shadow-colored)}.sm\\:transition-\\[width\\]{transition-property:width;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.sm\\:duration-300{transition-duration:.3s}.sm\\:ease-kin-open{transition-timing-function:cubic-bezier(.32,.72,0,1)}.sm\\:\\[touch-action\\:auto\\]{touch-action:auto}.sm\\:focus-within\\:w-kin-panel:focus-within{width:450px}.sm\\:focus-within\\:shadow-kin-border:focus-within{--tw-shadow: 0 0 0 1px var(--kin-border);--tw-shadow-colored: 0 0 0 1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow);--tw-shadow-color: var(--kin-border);--tw-shadow: var(--tw-shadow-colored)}.sm\\:enabled\\:bg-kin-text:enabled{background-color:var(--kin-text)}.sm\\:enabled\\:text-kin-bg-base:enabled{color:var(--kin-bg-base)}}.\\[\\&\\:\\:-webkit-scrollbar-thumb\\]\\:rounded-\\[3px\\]::-webkit-scrollbar-thumb{border-radius:3px}.\\[\\&\\:\\:-webkit-scrollbar-thumb\\]\\:bg-kin-bg-muted::-webkit-scrollbar-thumb{background-color:var(--kin-bg-muted)}.\\[\\&\\:\\:-webkit-scrollbar-track\\]\\:bg-transparent::-webkit-scrollbar-track{background-color:transparent}.\\[\\&\\:\\:-webkit-scrollbar\\]\\:w-1\\.5::-webkit-scrollbar{width:.375rem}.\\[\\&\\:\\:after\\]\\:hidden:after{display:none}@media (min-width: 640px){.sm\\:\\[\\&\\:\\:after\\]\\:block:after{display:block}}.\\[\\&\\:\\:before\\]\\:hidden:before{display:none}@media (min-width: 640px){.sm\\:\\[\\&\\:\\:before\\]\\:block:before{display:block}}.\\[\\&\\>svg\\]\\:size-4>svg{width:1rem;height:1rem}
|
|
114
|
-
`,_0=["gray","mauve","slate","sage","olive","sand","tomato","red","ruby","crimson","pink","plum","purple","violet","iris","indigo","blue","cyan","teal","jade","green","grass","brown","orange","sky","mint","lime","yellow","amber","bronze","gold"],k0={gray:[[.178,0,null],[.213,0,null],[.254,0,null],[.283,0,null],[.313,0,null],[.349,0,null],[.402,0,null],[.488,0,null],[.538,0,null],[.584,0,null],[.77,0,null],[.949,0,null]],mauve:[[.18,.004,307.8],[.215,.004,307.8],[.255,.006,306.5],[.284,.008,307.8],[.314,.009,306.9],[.35,.01,304],[.402,.012,304.4],[.492,.016,300.7],[.54,.017,294],[.586,.017,295.4],[.77,.014,296.6],[.949,.003,286.3]],slate:[[.179,.004,286],[.213,.004,264.4],[.253,.006,261.2],[.283,.007,259.5],[.311,.008,259.7],[.346,.01,256.5],[.398,.012,253.8],[.49,.016,247.6],[.537,.015,261.1],[.583,.014,263.3],[.768,.01,261.3],[.949,.003,264.6]],sage:[[.179,.004,167.4],[.211,.004,160.2],[.251,.004,164.2],[.281,.005,164.9],[.311,.005,167.4],[.347,.006,167.4],[.399,.008,167.4],[.488,.009,169.8],[.533,.018,170.8],[.579,.016,170.5],[.766,.01,167.5],[.947,.002,167.7]],olive:[[.18,.004,128.3],[.212,.004,128.3],[.252,.005,129],[.281,.006,131.4],[.31,.007,131.4],[.346,.008,134.4],[.399,.01,136],[.488,.012,140.8],[.535,.018,139.6],[.581,.016,140.1],[.766,.013,139.5],[.947,.003,144.8]],sand:[[.178,.002,106.6],[.213,.002,106.6],[.253,.003,106.6],[.283,.004,99],[.312,.004,100.7],[.349,.006,102.2],[.401,.007,96.1],[.49,.01,91.7],[.535,.011,94.1],[.581,.011,94],[.767,.009,97.4],[.948,.003,106.4]],tomato:[[.187,.012,19.6],[.208,.017,32],[.254,.054,26.9],[.291,.087,28.2],[.331,.097,28.7],[.38,.099,30],[.447,.107,31.5],[.538,.13,32.9],[.627,.194,33.3],[.665,.179,34.1],[.784,.164,36],[.899,.047,31.1]],red:[[.188,.013,19.4],[.205,.022,14.7],[.25,.064,13.1],[.289,.096,14.3],[.332,.107,15.5],[.383,.111,16.9],[.451,.121,18.9],[.544,.147,21.4],[.625,.193,23],[.665,.177,23.1],[.784,.162,22.3],[.902,.053,6.14]],ruby:[[.189,.014,2.9],[.208,.016,5.29],[.254,.06,6.54],[.292,.089,5.5],[.333,.1,6.4],[.382,.105,7.59],[.448,.117,9.02],[.544,.145,11.1],[.628,.195,13.2],[.664,.179,13.7],[.786,.161,17],[.905,.053,355.8]],crimson:[[.189,.014,354.2],[.207,.022,352.9],[.256,.059,353.9],[.293,.094,354.1],[.333,.104,354.7],[.382,.109,355.5],[.45,.12,356.7],[.542,.148,358.3],[.634,.213,1.3],[.664,.197,1.95],[.787,.167,6.72],[.909,.054,346.7]],pink:[[.191,.017,334.9],[.207,.031,338.2],[.261,.061,337.5],[.299,.098,340.1],[.338,.104,340.6],[.389,.107,341.6],[.459,.119,342.6],[.545,.145,344.1],[.617,.208,346.1],[.65,.197,346.2],[.789,.19,350.7],[.905,.059,343.2]],plum:[[.19,.017,327],[.21,.031,327.7],[.266,.062,326.7],[.307,.088,325.3],[.343,.095,324.6],[.389,.097,324.2],[.456,.106,323.4],[.545,.128,322.2],[.579,.188,322.1],[.616,.182,322.1],[.786,.154,322.1],[.906,.055,325.8]],purple:[[.192,.022,316],[.213,.031,314.3],[.266,.062,312],[.308,.083,310.7],[.344,.091,310.1],[.388,.097,309.7],[.45,.108,308.7],[.541,.133,307.1],[.555,.183,305.9],[.596,.177,306.3],[.785,.156,307.9],[.911,.049,310.9]],violet:[[.191,.026,290.5],[.211,.032,299.5],[.271,.066,293.9],[.312,.093,291.7],[.348,.099,291.4],[.39,.102,291.8],[.445,.111,291.6],[.516,.131,290.2],[.542,.179,288.1],[.588,.17,289.7],[.778,.137,293.6],[.912,.045,292.6]],iris:[[.193,.022,284.2],[.209,.029,286.5],[.273,.069,278.6],[.319,.102,276.1],[.358,.109,277.4],[.399,.112,279.6],[.448,.12,280.8],[.507,.138,281.1],[.54,.184,278.3],[.587,.172,281.2],[.776,.131,286.6],[.914,.042,287]],indigo:[[.191,.025,276.7],[.209,.03,276],[.272,.069,267.8],[.319,.093,267],[.362,.105,267.5],[.404,.111,268.3],[.45,.12,268.8],[.503,.137,268.4],[.544,.191,267.1],[.59,.176,269.2],[.777,.123,273.3],[.911,.043,270]],blue:[[.193,.026,256.8],[.213,.03,258.8],[.274,.067,254],[.317,.1,248.3],[.365,.108,249.7],[.416,.112,251.7],[.475,.121,252.8],[.541,.14,253.2],[.649,.193,251.8],[.689,.17,251.5],[.768,.135,248.8],[.907,.051,238.3]],cyan:[[.191,.017,219.9],[.214,.018,225.4],[.272,.044,222.5],[.315,.063,222.1],[.362,.07,221.5],[.414,.075,221.7],[.478,.083,221.4],[.558,.098,220.7],[.661,.122,221.5],[.698,.12,219.1],[.786,.115,213.4],[.909,.057,211.7]],teal:[[.189,.012,184.5],[.217,.017,189.3],[.274,.038,186.3],[.317,.055,187],[.363,.06,186.5],[.414,.065,185.4],[.473,.074,184.5],[.539,.087,183.5],[.649,.113,182],[.687,.123,180.3],[.789,.147,175.7],[.905,.072,175.3]],jade:[[.188,.014,166.3],[.216,.018,166.1],[.272,.042,166.8],[.316,.057,168],[.362,.064,168.5],[.411,.068,169.7],[.468,.075,170.6],[.537,.088,171.8],[.642,.115,170.8],[.678,.125,169.9],[.785,.156,167.1],[.903,.078,167]],green:[[.189,.013,163.3],[.213,.016,162.2],[.271,.039,162.7],[.318,.057,161.5],[.365,.066,161.1],[.413,.073,160.7],[.467,.083,159.9],[.527,.096,159.2],[.64,.133,157.8],[.676,.141,157.6],[.78,.166,157.2],[.905,.083,158.3]],grass:[[.188,.014,155.8],[.211,.014,151.5],[.267,.03,150.7],[.319,.052,150.4],[.367,.062,149.9],[.416,.072,149.3],[.468,.084,148.9],[.524,.097,148.2],[.652,.147,147.4],[.69,.145,147.6],[.78,.142,148.5],[.911,.078,144.9]],brown:[[.178,.005,81.5],[.213,.007,51.6],[.254,.013,53.5],[.288,.018,55.4],[.325,.024,55.9],[.37,.032,57.7],[.429,.041,59.8],[.509,.053,62.2],[.633,.078,60.8],[.674,.075,61.5],[.798,.063,62.5],[.918,.036,75.7]],bronze:[[.181,.005,41.6],[.215,.005,41.5],[.255,.008,42.7],[.291,.01,45.5],[.329,.013,43.3],[.374,.016,44.3],[.43,.02,44.8],[.499,.024,45.2],[.627,.046,44.3],[.669,.045,44.3],[.792,.043,44.5],[.915,.017,50.3]],gold:[[.182,.002,106.6],[.216,.006,92.5],[.255,.008,88.3],[.291,.01,86.8],[.329,.011,83.7],[.374,.014,82.4],[.429,.016,80.9],[.498,.02,79.5],[.621,.049,78.1],[.662,.047,77.2],[.794,.041,77.2],[.915,.014,77.4]],sky:[[.19,.024,257.1],[.216,.029,258.5],[.271,.054,251.9],[.322,.07,247.8],[.372,.079,245.8],[.427,.087,243.6],[.488,.098,240.7],[.557,.114,237.2],[.861,.103,217.8],[.908,.073,214.9],[.793,.099,231.7],[.934,.053,214.4]],mint:[[.188,.012,192.3],[.21,.017,196.6],[.269,.039,192.5],[.313,.058,191.6],[.359,.063,188.9],[.41,.067,186.3],[.471,.073,183.4],[.54,.085,179.6],[.87,.1,178],[.916,.08,179.4],[.795,.118,176.4],[.93,.057,168.5]],lime:[[.18,.014,120.3],[.208,.019,129],[.266,.034,132.2],[.317,.047,131.8],[.363,.058,131.6],[.412,.069,131.4],[.464,.08,131.2],[.524,.095,130.9],[.888,.175,126.1],[.942,.175,123.7],[.868,.156,124.8],[.946,.082,122.6]],yellow:[[.181,.013,86],[.209,.017,92.1],[.259,.047,90.3],[.293,.069,94.2],[.333,.079,94.6],[.384,.077,93.3],[.452,.081,91.5],[.535,.095,89.9],[.927,.209,102.1],[.971,.182,109.4],[.9,.166,101.6],[.941,.075,101]],amber:[[.184,.013,77.3],[.212,.018,78.7],[.258,.044,74.6],[.296,.071,76.2],[.337,.081,76.4],[.387,.078,75.1],[.453,.082,74.5],[.536,.096,73.6],[.856,.178,81.4],[.902,.206,97],[.871,.175,85.1],[.935,.072,86]],orange:[[.186,.012,53.7],[.209,.019,67.4],[.257,.045,59.5],[.293,.08,58.6],[.335,.087,58.1],[.386,.087,55.2],[.453,.095,53.1],[.541,.116,49.7],[.689,.191,44.8],[.741,.199,46.3],[.799,.163,50.8],[.925,.052,66.2]]},x0={gray:[[.991,0,null],[.981,0,null],[.953,0,null],[.93,0,null],[.908,0,null],[.884,0,null],[.851,0,null],[.791,0,null],[.643,0,null],[.609,0,null],[.503,0,null],[.243,0,null]],mauve:[[.992,.002,321.1],[.983,.003,311.2],[.956,.006,314.2],[.932,.008,310],[.909,.01,306.6],[.886,.012,304],[.854,.014,300.6],[.794,.019,293.5],[.646,.019,292.6],[.611,.018,293.1],[.505,.016,296.1],[.245,.013,298]],slate:[[.991,.001,286.4],[.982,.003,286.3],[.956,.004,281.9],[.931,.006,283],[.91,.008,283.6],[.888,.009,281.8],[.853,.012,280.8],[.794,.016,278.1],[.646,.016,277.8],[.61,.016,273.2],[.503,.014,263.4],[.241,.01,249.5]],sage:[[.992,.003,160.4],[.981,.003,171.2],[.955,.003,170.4],[.931,.003,170.4],[.909,.004,167.7],[.885,.004,167.7],[.851,.004,169.9],[.792,.005,169.5],[.639,.01,172.4],[.605,.01,172.8],[.501,.008,175.9],[.24,.012,166.8]],olive:[[.993,.002,149.1],[.983,.003,144.8],[.956,.004,141.1],[.932,.004,142.1],[.909,.005,139.3],[.886,.006,141.1],[.852,.006,141.1],[.792,.007,140.6],[.64,.011,136.5],[.605,.012,136.5],[.5,.011,139.9],[.242,.011,138.2]],sand:[[.994,.001,106.4],[.982,.001,106.4],[.956,.002,97.6],[.932,.003,100.6],[.91,.004,95.9],[.886,.005,98.3],[.853,.006,96.6],[.792,.008,96.5],[.641,.01,106.7],[.606,.01,106.7],[.498,.008,106.7],[.243,.008,96.3]],tomato:[[.994,.003,22.8],[.984,.007,31],[.954,.022,30.9],[.926,.047,31.8],[.892,.063,31.5],[.852,.077,32],[.803,.094,32.2],[.741,.118,32.1],[.627,.194,33.3],[.604,.195,33.3],[.567,.198,32.8],[.346,.08,30.5]],red:[[.994,.003,22.8],[.983,.008,16],[.956,.021,16.2],[.928,.047,16.7],[.896,.062,17.3],[.857,.075,17.9],[.807,.089,18.4],[.745,.113,19.1],[.625,.193,23],[.6,.195,23.9],[.557,.198,25.1],[.339,.109,16.7]],ruby:[[.994,.003,356.3],[.983,.008,8.41],[.954,.022,8.56],[.928,.042,8.46],[.896,.055,8.16],[.858,.066,7.84],[.81,.08,7.49],[.749,.101,6.86],[.628,.195,13.2],[.601,.196,13.4],[.549,.199,13.9],[.341,.11,10]],crimson:[[.994,.003,356.3],[.982,.008,357.2],[.954,.026,356.3],[.925,.041,356.3],[.893,.054,355.8],[.855,.065,355.6],[.808,.078,354.8],[.75,.099,354.1],[.634,.213,1.3],[.608,.211,2.36],[.552,.207,4.49],[.341,.113,356.8]],pink:[[.994,.004,336.3],[.983,.009,340],[.954,.027,340.6],[.925,.042,340.7],[.893,.054,340.9],[.855,.067,340.9],[.809,.083,341.2],[.752,.107,341.6],[.617,.208,346.1],[.596,.207,346.5],[.557,.206,347.3],[.35,.129,345.5]],plum:[[.993,.005,316.9],[.983,.009,326],[.957,.027,325.5],[.929,.044,324.9],[.898,.057,324.4],[.86,.072,323.9],[.809,.091,323.1],[.742,.12,321.9],[.579,.188,322.1],[.553,.181,322.1],[.521,.173,322],[.338,.125,321.4]],purple:[[.993,.004,325.4],[.982,.009,313.1],[.959,.024,313.3],[.933,.039,312.1],[.901,.054,311.6],[.86,.071,311],[.804,.093,309.9],[.733,.123,308],[.555,.183,305.9],[.524,.176,305.7],[.516,.174,305.7],[.322,.11,303.8]],violet:[[.992,.003,308],[.983,.009,295],[.963,.019,296.6],[.934,.039,295.4],[.904,.057,294.1],[.864,.072,293.9],[.806,.09,293.5],[.729,.119,292.4],[.542,.179,288.1],[.511,.177,287.6],[.508,.159,288.6],[.313,.098,286.8]],iris:[[.994,.003,286.4],[.981,.009,284.1],[.961,.018,283.8],[.935,.035,283.4],[.904,.053,283.8],[.865,.07,283.1],[.808,.088,282.9],[.729,.118,281.5],[.54,.184,278.3],[.509,.186,277.5],[.51,.173,279.7],[.315,.099,277.4]],indigo:[[.994,.001,286.4],[.983,.008,271.4],[.961,.017,268.5],[.935,.034,268.5],[.903,.051,270],[.863,.071,271.5],[.807,.087,271.4],[.73,.113,270.5],[.544,.191,267.1],[.511,.195,266.5],[.51,.173,267.1],[.313,.086,268.6]],blue:[[.993,.003,247.6],[.982,.01,243.3],[.96,.02,236.7],[.937,.037,239],[.906,.053,242.8],[.864,.069,243.2],[.809,.088,243.3],[.735,.121,243],[.649,.193,251.8],[.621,.184,251.9],[.558,.189,253],[.324,.097,259]],cyan:[[.992,.004,219.2],[.98,.009,202.9],[.958,.026,203.6],[.932,.041,204.7],[.9,.054,206.5],[.859,.066,207.7],[.805,.082,209.6],[.727,.11,211.7],[.661,.122,221.5],[.627,.114,221.3],[.54,.127,223.7],[.332,.053,218.6]],teal:[[.994,.005,177.5],[.981,.009,179],[.961,.027,180.3],[.935,.042,180.2],[.9,.054,180.5],[.856,.064,181.4],[.797,.076,182.2],[.721,.097,183.5],[.649,.113,182],[.619,.11,181.2],[.53,.124,179],[.327,.05,185]],jade:[[.995,.004,172.6],[.982,.009,160.3],[.96,.022,161.9],[.934,.034,163.5],[.902,.046,164.8],[.859,.059,166.9],[.8,.077,169.5],[.721,.103,173.4],[.642,.115,170.8],[.613,.11,170.6],[.529,.127,167.2],[.326,.041,169.8]],green:[[.994,.004,159.1],[.982,.009,155.3],[.959,.023,156.4],[.933,.036,156.6],[.9,.05,157.2],[.857,.065,157.9],[.798,.084,159],[.714,.112,160.6],[.64,.133,157.8],[.611,.126,158.3],[.529,.133,158.3],[.322,.047,164.6]],grass:[[.994,.005,146.4],[.982,.009,145.9],[.961,.023,145.3],[.934,.037,146.2],[.901,.053,146.4],[.858,.071,146.8],[.798,.095,147.5],[.716,.13,148.3],[.652,.147,147.4],[.614,.142,147.3],[.527,.13,147.2],[.327,.053,148.6]],brown:[[.994,.002,63.2],[.983,.006,65.7],[.954,.013,67.8],[.926,.02,66.9],[.897,.029,65.8],[.862,.039,65.5],[.815,.053,64.2],[.747,.072,62.4],[.633,.078,60.8],[.597,.072,59.3],[.512,.058,55.5],[.332,.018,47]],bronze:[[.992,.001,15.9],[.981,.007,43],[.953,.01,44.3],[.925,.014,43.6],[.895,.018,42.6],[.86,.023,43.4],[.811,.03,41.9],[.742,.039,41.2],[.627,.046,44.3],[.588,.045,42.4],[.51,.044,38.4],[.329,.029,35.2]],gold:[[.994,.001,106.4],[.981,.009,97.3],[.953,.012,94.7],[.926,.015,93.2],[.896,.019,90.7],[.86,.025,88.4],[.81,.032,83.4],[.739,.042,78.2],[.621,.049,78.1],[.588,.047,77.4],[.504,.039,78.1],[.332,.019,81.7]],sky:[[.993,.005,211.9],[.98,.01,217.7],[.961,.024,219.6],[.936,.036,220.4],[.903,.047,221.4],[.861,.058,222.9],[.806,.072,225.7],[.729,.096,228],[.861,.103,217.8],[.838,.104,219.6],[.526,.108,232.5],[.351,.057,241.6]],mint:[[.993,.005,183.7],[.982,.01,178.7],[.96,.03,179.6],[.933,.047,179],[.899,.061,178.7],[.856,.072,178.7],[.798,.085,178.2],[.722,.107,177.7],[.87,.1,178],[.841,.1,177.8],[.512,.095,176],[.35,.051,181.4]],lime:[[.992,.004,120.7],[.982,.01,116.7],[.959,.043,119.1],[.932,.069,120.4],[.897,.087,121.8],[.853,.099,123.4],[.795,.111,125.3],[.724,.135,128.1],[.888,.175,126.1],[.859,.188,126.7],[.544,.111,128.6],[.354,.057,121.2]],yellow:[[.993,.005,106.5],[.988,.025,102.9],[.974,.084,104.4],[.953,.117,101.7],[.925,.141,98.2],[.881,.134,95.4],[.836,.12,92.8],[.766,.137,89.8],[.927,.209,102.1],[.897,.185,97.5],[.574,.136,81.7],[.358,.046,86.6]],amber:[[.994,.003,84.6],[.986,.024,100.3],[.969,.069,100.4],[.945,.104,98.2],[.918,.133,98.4],[.881,.124,93.2],[.827,.122,86.2],[.758,.14,76.7],[.856,.178,81.4],[.831,.168,80.9],[.569,.144,67.3],[.352,.049,53.7]],orange:[[.992,.003,40.7],[.979,.015,70.8],[.958,.037,78.1],[.92,.081,74.2],[.89,.107,70.8],[.857,.11,64.4],[.805,.113,59.9],[.745,.132,54.8],[.689,.191,44.8],[.662,.194,43.5],[.592,.186,47],[.35,.069,40.8]]},Ts=e=>(e/=255,e<=.04045?e/12.92:((e+.055)/1.055)**2.4),Zx=(e,t,n)=>{const r=.4122214708*e+.5363325363*t+.0514459929*n,i=.2119034982*e+.6806995451*t+.1073969566*n,a=.0883024619*e+.2817188376*t+.6299787005*n,s=Math.cbrt(r),o=Math.cbrt(i),u=Math.cbrt(a),c=.2104542553*s+.793617785*o-.0040720468*u,f=1.9779984951*s-2.428592205*o+.4505937099*u,d=.0259040371*s+.7827717662*o-.808675766*u;return[c,f,d]},Jx=([e,t,n])=>{const r=Math.sqrt(t*t+n*n),i=Math.atan2(n,t)*180/Math.PI;return[e,r,(i+360)%360]},e6=e=>{const t=e.replace("#",""),n=parseInt(t.length===3?t.replace(/./g,s=>s+s):t,16),r=Ts(n>>16&255),i=Ts(n>>8&255),a=Ts(n&255);return Jx(Zx(r,i,a))},y0=["gray","mauve","slate","sage","olive","sand"];function _i(e,t){return Object.fromEntries(t.map(n=>[n,e[n]]))}_i(x0,_0),_i(k0,_0),_i(x0,y0),_i(k0,y0);const t6={light:{1:[98.8,.015],2:[97.8,.018],3:[95.8,.025],4:[92,.04],5:[89,.05],6:[85,.07],7:[80.5,.08],8:[74,.11],9:[60,.22],10:[56,.23],11:[50,.19],12:[25,.18]},dark:{1:[19,.015],2:[21,.018],3:[25.5,.055],4:[29.3,.084],5:[33.5,.098],6:[39.05,.107],7:[45,.11],8:[55,.13],9:[60,.22],10:[67,.18],11:[79.3,.12],12:[95,.04]}},n6={light:{1:[99,.005],2:[97.5,.005],3:[95,.006],4:[92,.006],5:[88,.005],6:[83,.004],7:[76,.003],8:[65,.003],9:[55,.004],10:[45,.005],11:[35,.006],12:[20,.008]},dark:{1:[14,.008],2:[17,.008],3:[21,.01],4:[25,.01],5:[30,.008],6:[36,.006],7:[44,.005],8:[54,.004],9:[66,.003],10:[76,.004],11:[87,.005],12:[96,.006]}};function r6(e){const[t,n,r]=e6(e);return{l:t*100,c:n,h:r??0}}const Bt=(e,t,n)=>`oklch(${e}% ${t} ${n})`;function i6(e){const{accentColor:t,mode:n}=e,r=r6(t),i=t6[n],a=n6[n],s=30,o=r.c/.22,u=m=>{const _=i[m];if(!_)return Bt(60,.22,r.h);const[A,y]=_;return m==="9"?Bt(r.l,r.c,r.h):Bt(A,y*o,r.h)},c=m=>{const _=a[m];if(!_)return Bt(50,.005,s);const[A,y]=_;return Bt(A,y,s)},f=Bt(r.l,r.c,r.h),d=Bt(r.l*.9,r.c*.9,(r.h+20)%360),h=Bt(r.l*.8,r.c*.8,(r.h+40)%360),p=n==="light"?{"--kin-bg-base":c("1"),"--kin-bg-elevated":c("2"),"--kin-bg-surface":c("3"),"--kin-bg-muted":c("4"),"--kin-border":`oklch(${a[6]?.[0]??83}% ${a[6]?.[1]??.004} ${s} / 0.4)`,"--kin-border-subtle":`oklch(${a[5]?.[0]??88}% ${a[5]?.[1]??.005} ${s} / 0.25)`,"--kin-text":c("12"),"--kin-text-secondary":c("10"),"--kin-text-muted":c("8"),"--kin-accent":u("9"),"--kin-bubble-user":u("9"),"--kin-bubble-user-text":"oklch(100% 0 0)","--kin-bubble-assistant":c("2"),"--kin-bubble-assistant-text":c("12"),"--kin-glow-1":f,"--kin-glow-2":d,"--kin-glow-3":h}:{"--kin-bg-base":c("1"),"--kin-bg-elevated":c("2"),"--kin-bg-surface":c("3"),"--kin-bg-muted":c("4"),"--kin-border":`oklch(${a[6]?.[0]??83}% ${a[6]?.[1]??.004} ${s} / 0.4)`,"--kin-border-subtle":`oklch(${a[5]?.[0]??88}% ${a[5]?.[1]??.005} ${s} / 0.25)`,"--kin-text":c("12"),"--kin-text-secondary":c("11"),"--kin-text-muted":c("9"),"--kin-accent":u("9"),"--kin-bubble-user":c("12"),"--kin-bubble-user-text":c("1"),"--kin-bubble-assistant":c("3"),"--kin-bubble-assistant-text":c("12"),"--kin-glow-1":f,"--kin-glow-2":d,"--kin-glow-3":h};return Object.entries(p).map(([m,_])=>`${m}: ${_};`).join(`
|
|
115
|
-
`)}const a6={accentColor:"#FF4D00",mode:"light"},s6="wss://agents.inploi.com",o6=({serviceUrl:e=s6,theme:t=a6,starterPrompts:n=[],mode:r="floating",container:i})=>Ut(({logger:a,publishableKey:s})=>{if(!s)throw new Error("Kin plugin requires a publishableKey. Pass it to initialiseSdk().");let o=!1,u=null,c=t,f=null,d=!1,h=null,p=null,m=!1;const _=r==="embedded",A=()=>{if(i)if(typeof i=="string"){const H=document.querySelector(i);if(H instanceof HTMLElement)return p=H,m=!1,H}else return p=i,m=!1,i;const z=document.getElementById("inploi-kin-root");if(z)return p=z,m=!1,z;const L=document.createElement("div");return L.id="inploi-kin-root",_&&(L.className="kin-embedded"),document.body.appendChild(L),p=L,m=!0,L},y=z=>{const L=i6(z);let H=`${Xx}
|
|
115
|
+
`)},ws=e=>{let t=!1;for(let r of e)if(r==="\\"||r==="|"){t=!0;break}if(!t)return e;let n=[];for(let r of e)r==="\\"?n.push("\\\\"):r==="|"?n.push("\\|"):n.push(r);return n.join("")},As=e=>{let{headers:t,rows:n}=e;if(t.length===0)return"";let r=new Array(n.length+2),i=0,a=t.map(o=>ws(o));r[i]=`| ${a.join(" | ")} |`,i+=1;let s=new Array(t.length);for(let o=0;o<t.length;o+=1)s[o]="---";r[i]=`| ${s.join(" | ")} |`,i+=1;for(let o of n)if(o.length<t.length){let u=new Array(t.length);for(let c=0;c<t.length;c+=1)u[c]=c<o.length?ws(o[c]):"";r[i]=`| ${u.join(" | ")} |`,i+=1}else{let u=o.map(c=>ws(c));r[i]=`| ${u.join(" | ")} |`,i+=1}return r.join(`
|
|
116
|
+
`)},iy=({children:e,className:t,onCopy:n,onError:r,timeout:i=2e3})=>{let[a,s]=oe(!1),[o,u]=oe(!1),c=Oe(null),f=Oe(0),{isAnimating:d}=Ve(Ze),h=async m=>{var _,w;if(typeof window>"u"||!((_=navigator?.clipboard)!=null&&_.write)){r?.(new Error("Clipboard API not available"));return}try{let y=(w=c.current)==null?void 0:w.closest('[data-streamdown="table-wrapper"]'),S=y?.querySelector("table");if(!S){r?.(new Error("Table not found"));return}let C=Qd(S),D=({csv:Kd,tsv:ry,md:As}[m]||As)(C),P=new ClipboardItem({"text/plain":new Blob([D],{type:"text/plain"}),"text/html":new Blob([S.outerHTML],{type:"text/html"})});await navigator.clipboard.write([P]),u(!0),s(!1),n?.(m),f.current=window.setTimeout(()=>u(!1),i)}catch(y){r?.(y)}};ye(()=>{let m=_=>{let w=_.composedPath();c.current&&!w.includes(c.current)&&s(!1)};return document.addEventListener("mousedown",m),()=>{document.removeEventListener("mousedown",m),window.clearTimeout(f.current)}},[]);let p=o?_s:ks;return b("div",{className:"relative",ref:c,children:[b("button",{className:Q("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",t),disabled:d,onClick:()=>s(!a),title:"Copy table",type:"button",children:e??b(p,{size:14})}),a?b("div",{className:"absolute top-full right-0 z-10 mt-1 min-w-[120px] overflow-hidden rounded-md border border-border bg-background shadow-lg",children:[b("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>h("md"),title:"Copy table as Markdown",type:"button",children:"Markdown"}),b("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>h("csv"),title:"Copy table as CSV",type:"button",children:"CSV"}),b("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>h("tsv"),title:"Copy table as TSV",type:"button",children:"TSV"})]}):null]})},ay=({children:e,className:t,onDownload:n,onError:r})=>{let[i,a]=oe(!1),s=Oe(null),{isAnimating:o}=Ve(Ze),u=c=>{var f;try{let d=(f=s.current)==null?void 0:f.closest('[data-streamdown="table-wrapper"]'),h=d?.querySelector("table");if(!h){r?.(new Error("Table not found"));return}let p=Qd(h),m=c==="csv"?Kd(p):As(p);vn(`table.${c==="csv"?"csv":"md"}`,m,c==="csv"?"text/csv":"text/markdown"),a(!1),n?.(c)}catch(d){r?.(d)}};return ye(()=>{let c=f=>{let d=f.composedPath();s.current&&!d.includes(s.current)&&a(!1)};return document.addEventListener("mousedown",c),()=>{document.removeEventListener("mousedown",c)}},[]),b("div",{className:"relative",ref:s,children:[b("button",{className:Q("cursor-pointer p-1 text-muted-foreground transition-all hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",t),disabled:o,onClick:()=>a(!i),title:"Download table",type:"button",children:e??b(yi,{size:14})}),i?b("div",{className:"absolute top-full right-0 z-10 mt-1 min-w-[120px] overflow-hidden rounded-md border border-border bg-background shadow-lg",children:[b("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>u("csv"),title:"Download table as CSV",type:"button",children:"CSV"}),b("button",{className:"w-full px-3 py-2 text-left text-sm transition-colors hover:bg-muted/40",onClick:()=>u("markdown"),title:"Download table as Markdown",type:"button",children:"Markdown"})]}):null]})},sy=({children:e,className:t,showControls:n,...r})=>b("div",{className:"my-4 flex flex-col gap-2 rounded-lg border border-border bg-sidebar p-2","data-streamdown":"table-wrapper",children:[n?b("div",{className:"flex items-center justify-end gap-1",children:[b(iy,{}),b(ay,{})]}):null,b("div",{className:"border-collapse overflow-x-auto overscroll-y-auto rounded-md border border-border bg-background",children:b("table",{className:Q("w-full divide-y divide-border",t),"data-streamdown":"table",...r,children:e})})]}),oy=wo(()=>Promise.resolve().then(()=>y6).then(e=>({default:e.Mermaid}))),uy=/language-([^\s]+)/;function wi(e,t){if(!(e!=null&&e.position||t!=null&&t.position))return!0;if(!(e!=null&&e.position&&t!=null&&t.position))return!1;let n=e.position.start,r=t.position.start,i=e.position.end,a=t.position.end;return n?.line===r?.line&&n?.column===r?.column&&i?.line===a?.line&&i?.column===a?.column}function Ae(e,t){return e.className===t.className&&wi(e.node,t.node)}var Cs=(e,t)=>typeof e=="boolean"?e:e[t]!==!1,Ai=(e,t)=>{if(typeof e=="boolean")return e;let n=e.mermaid;return n===!1?!1:n===!0||n===void 0?!0:n[t]!==!1},Ss=fe(({children:e,className:t,node:n,...r})=>b("ol",{className:Q("list-inside list-decimal whitespace-normal [li_&]:pl-6",t),"data-streamdown":"ordered-list",...r,children:e}),(e,t)=>Ae(e,t));Ss.displayName="MarkdownOl";var Xd=fe(({children:e,className:t,node:n,...r})=>b("li",{className:Q("py-1 [&>p]:inline",t),"data-streamdown":"list-item",...r,children:e}),(e,t)=>e.className===t.className&&wi(e.node,t.node));Xd.displayName="MarkdownLi";var Zd=fe(({children:e,className:t,node:n,...r})=>b("ul",{className:Q("list-inside list-disc whitespace-normal [li_&]:pl-6",t),"data-streamdown":"unordered-list",...r,children:e}),(e,t)=>Ae(e,t));Zd.displayName="MarkdownUl";var Jd=fe(({className:e,node:t,...n})=>b("hr",{className:Q("my-6 border-border",e),"data-streamdown":"horizontal-rule",...n}),(e,t)=>Ae(e,t));Jd.displayName="MarkdownHr";var e0=fe(({children:e,className:t,node:n,...r})=>b("span",{className:Q("font-semibold",t),"data-streamdown":"strong",...r,children:e}),(e,t)=>Ae(e,t));e0.displayName="MarkdownStrong";var ly=({children:e,className:t,href:n,node:r,...i})=>{let{linkSafety:a}=Ve(Ze),[s,o]=oe(!1),u=n==="streamdown:incomplete-link",c=De(async p=>{if(!(!(a!=null&&a.enabled&&n)||u)){if(p.preventDefault(),a.onLinkCheck&&await a.onLinkCheck(n)){window.open(n,"_blank","noreferrer");return}o(!0)}},[a,n,u]),f=De(()=>{n&&window.open(n,"_blank","noreferrer")},[n]),d=De(()=>{o(!1)},[]),h={url:n??"",isOpen:s,onClose:d,onConfirm:f};return a!=null&&a.enabled&&n?b($e,{children:[b("button",{className:Q("wrap-anywhere appearance-none text-left font-medium text-primary underline",t),"data-incomplete":u,"data-streamdown":"link",onClick:c,type:"button",children:e}),a.renderModal?a.renderModal(h):b(Kx,{...h})]}):b("a",{className:Q("wrap-anywhere font-medium text-primary underline",t),"data-incomplete":u,"data-streamdown":"link",href:n,rel:"noreferrer",target:"_blank",...i,children:e})},t0=fe(ly,(e,t)=>Ae(e,t)&&e.href===t.href);t0.displayName="MarkdownA";var n0=fe(({children:e,className:t,node:n,...r})=>b("h1",{className:Q("mt-6 mb-2 font-semibold text-3xl",t),"data-streamdown":"heading-1",...r,children:e}),(e,t)=>Ae(e,t));n0.displayName="MarkdownH1";var r0=fe(({children:e,className:t,node:n,...r})=>b("h2",{className:Q("mt-6 mb-2 font-semibold text-2xl",t),"data-streamdown":"heading-2",...r,children:e}),(e,t)=>Ae(e,t));r0.displayName="MarkdownH2";var i0=fe(({children:e,className:t,node:n,...r})=>b("h3",{className:Q("mt-6 mb-2 font-semibold text-xl",t),"data-streamdown":"heading-3",...r,children:e}),(e,t)=>Ae(e,t));i0.displayName="MarkdownH3";var a0=fe(({children:e,className:t,node:n,...r})=>b("h4",{className:Q("mt-6 mb-2 font-semibold text-lg",t),"data-streamdown":"heading-4",...r,children:e}),(e,t)=>Ae(e,t));a0.displayName="MarkdownH4";var s0=fe(({children:e,className:t,node:n,...r})=>b("h5",{className:Q("mt-6 mb-2 font-semibold text-base",t),"data-streamdown":"heading-5",...r,children:e}),(e,t)=>Ae(e,t));s0.displayName="MarkdownH5";var o0=fe(({children:e,className:t,node:n,...r})=>b("h6",{className:Q("mt-6 mb-2 font-semibold text-sm",t),"data-streamdown":"heading-6",...r,children:e}),(e,t)=>Ae(e,t));o0.displayName="MarkdownH6";var u0=fe(({children:e,className:t,node:n,...r})=>{let{controls:i}=Ve(Ze),a=Cs(i,"table");return b(sy,{className:t,showControls:a,...r,children:e})},(e,t)=>Ae(e,t));u0.displayName="MarkdownTable";var l0=fe(({children:e,className:t,node:n,...r})=>b("thead",{className:Q("bg-muted/80",t),"data-streamdown":"table-header",...r,children:e}),(e,t)=>Ae(e,t));l0.displayName="MarkdownThead";var c0=fe(({children:e,className:t,node:n,...r})=>b("tbody",{className:Q("divide-y divide-border",t),"data-streamdown":"table-body",...r,children:e}),(e,t)=>Ae(e,t));c0.displayName="MarkdownTbody";var d0=fe(({children:e,className:t,node:n,...r})=>b("tr",{className:Q("border-border",t),"data-streamdown":"table-row",...r,children:e}),(e,t)=>Ae(e,t));d0.displayName="MarkdownTr";var f0=fe(({children:e,className:t,node:n,...r})=>b("th",{className:Q("whitespace-nowrap px-4 py-2 text-left font-semibold text-sm",t),"data-streamdown":"table-header-cell",...r,children:e}),(e,t)=>Ae(e,t));f0.displayName="MarkdownTh";var h0=fe(({children:e,className:t,node:n,...r})=>b("td",{className:Q("px-4 py-2 text-sm",t),"data-streamdown":"table-cell",...r,children:e}),(e,t)=>Ae(e,t));h0.displayName="MarkdownTd";var p0=fe(({children:e,className:t,node:n,...r})=>b("blockquote",{className:Q("my-4 border-muted-foreground/30 border-l-4 pl-4 text-muted-foreground italic",t),"data-streamdown":"blockquote",...r,children:e}),(e,t)=>Ae(e,t));p0.displayName="MarkdownBlockquote";var m0=fe(({children:e,className:t,node:n,...r})=>b("sup",{className:Q("text-sm",t),"data-streamdown":"superscript",...r,children:e}),(e,t)=>Ae(e,t));m0.displayName="MarkdownSup";var g0=fe(({children:e,className:t,node:n,...r})=>b("sub",{className:Q("text-sm",t),"data-streamdown":"subscript",...r,children:e}),(e,t)=>Ae(e,t));g0.displayName="MarkdownSub";var b0=fe(({children:e,className:t,node:n,...r})=>{if("data-footnotes"in r){let i=s=>{var o,u;if(!Nt(s))return!1;let c=Array.isArray(s.props.children)?s.props.children:[s.props.children],f=!1,d=!1;for(let h of c)if(h){if(typeof h=="string")h.trim()!==""&&(f=!0);else if(Nt(h))if(((o=h.props)==null?void 0:o["data-footnote-backref"])!==void 0)d=!0;else{let p=Array.isArray(h.props.children)?h.props.children:[h.props.children];for(let m of p){if(typeof m=="string"&&m.trim()!==""){f=!0;break}if(Nt(m)&&((u=m.props)==null?void 0:u["data-footnote-backref"])===void 0){f=!0;break}}}}return d&&!f},a=Array.isArray(e)?e.map(s=>{if(!Nt(s))return s;if(s.type===Ss){let o=(Array.isArray(s.props.children)?s.props.children:[s.props.children]).filter(u=>!i(u));return o.length===0?null:{...s,props:{...s.props,children:o}}}return s}):e;return(Array.isArray(a)?a.some(s=>s!==null):a!==null)?b("section",{className:t,...r,children:a}):null}return b("section",{className:t,...r,children:e})},(e,t)=>Ae(e,t));b0.displayName="MarkdownSection";var cy=({node:e,className:t,children:n,...r})=>{var i;let a=!("data-block"in r),{mermaid:s,controls:o}=Ve(Ze),u=ys(),c=Lx();if(a)return b("code",{className:Q("rounded bg-muted px-1.5 py-0.5 font-mono text-sm",t),"data-streamdown":"inline-code",...r,children:n});let f=t?.match(uy),d=(i=f?.at(1))!=null?i:"",h="";if(Nt(n)&&n.props&&typeof n.props=="object"&&"children"in n.props&&typeof n.props.children=="string"?h=n.props.children:typeof n=="string"&&(h=n),d==="mermaid"&&u){let m=Cs(o,"mermaid"),_=Ai(o,"download"),w=Ai(o,"copy"),y=Ai(o,"fullscreen"),S=Ai(o,"panZoom"),C=m&&(_||w||y);return b(zn,{fallback:b(Vx,{}),children:b("div",{className:Q("group relative my-4 flex w-full flex-col gap-2 rounded-xl border border-border bg-sidebar p-2",t),"data-streamdown":"mermaid-block",children:[b("div",{className:"flex h-8 items-center text-muted-foreground text-xs",children:b("span",{className:"ml-1 font-mono lowercase",children:"mermaid"})}),C?b("div",{className:"pointer-events-none sticky top-2 z-10 -mt-10 flex h-8 items-center justify-end",children:b("div",{className:"pointer-events-auto flex shrink-0 items-center gap-2 rounded-md border border-sidebar bg-sidebar/80 px-1.5 py-1 supports-[backdrop-filter]:bg-sidebar/70 supports-[backdrop-filter]:backdrop-blur","data-streamdown":"mermaid-block-actions",children:[_?b(Jx,{chart:h,config:s?.config}):null,w?b(qd,{code:h}):null,y?b(ny,{chart:h,config:s?.config}):null]})}):null,b("div",{className:"rounded-md border border-border bg-background",children:b(oy,{chart:h,config:s?.config,showControls:S})})]})})}let p=Cs(o,"code");return b(Fx,{className:t,code:h,isIncomplete:c,language:d,children:p?b($e,{children:[b(jx,{code:h,language:d}),b(qd,{})]}):null})},E0=fe(cy,(e,t)=>e.className===t.className&&wi(e.node,t.node));E0.displayName="MarkdownCode";var T0=fe(Wx,(e,t)=>e.className===t.className&&wi(e.node,t.node));T0.displayName="MarkdownImg";var _0=fe(({children:e,node:t,...n})=>{let r=(Array.isArray(e)?e:[e]).filter(i=>i!=null&&i!=="");if(r.length===1&&Nt(r[0])){let i=r[0].props.node,a=i?.tagName;if(a==="img")return b($e,{children:e});if(a==="code"&&"data-block"in r[0].props)return b($e,{children:e})}return b("p",{...n,children:e})},(e,t)=>Ae(e,t));_0.displayName="MarkdownParagraph";var dy={ol:Ss,li:Xd,ul:Zd,hr:Jd,strong:e0,a:t0,h1:n0,h2:r0,h3:i0,h4:a0,h5:s0,h6:o0,table:u0,thead:l0,tbody:c0,tr:d0,th:f0,td:h0,blockquote:p0,code:E0,img:T0,pre:({children:e})=>Nt(e)?Mf(e,{"data-block":"true"}):e,sup:m0,sub:g0,p:_0,section:b0},fy=/^[ \t]{0,3}(`{3,}|~{3,})/,hy=/^\|?[ \t]*:?-{1,}:?[ \t]*(\|[ \t]*:?-{1,}:?[ \t]*)*\|?$/,k0=e=>{let t=e.split(`
|
|
117
|
+
`),n=null,r=0;for(let i of t){let a=fy.exec(i);if(n===null){if(a){let s=a[1];n=s[0],r=s.length}}else if(a){let s=a[1],o=s[0],u=s.length;o===n&&u>=r&&(n=null,r=0)}}return n!==null},py=e=>{let t=e.split(`
|
|
118
|
+
`);for(let n of t){let r=n.trim();if(r.length>0&&r.includes("|")&&hy.test(r))return!0}return!1},my=()=>e=>{It(e,"html",(t,n,r)=>{!r||typeof n!="number"||(r.children[n]={type:"text",value:t.value})})},x0=[],y0={allowDangerousHtml:!0},Ci=new WeakMap,gy=class{constructor(){this.cache=new Map,this.keyCache=new WeakMap,this.maxSize=100}generateCacheKey(e){let t=this.keyCache.get(e);if(t)return t;let n=e.rehypePlugins,r=e.remarkPlugins,i=e.remarkRehypeOptions;if(!(n||r||i)){let f="default";return this.keyCache.set(e,f),f}let a=f=>{if(!f||f.length===0)return"";let d="";for(let h=0;h<f.length;h+=1){let p=f[h];if(h>0&&(d+=","),Array.isArray(p)){let[m,_]=p;if(typeof m=="function"){let w=Ci.get(m);w||(w=m.name,Ci.set(m,w)),d+=w}else d+=String(m);d+=":",d+=JSON.stringify(_)}else if(typeof p=="function"){let m=Ci.get(p);m||(m=p.name,Ci.set(p,m)),d+=m}else d+=String(p)}return d},s=a(n),o=a(r),u=i?JSON.stringify(i):"",c=`${o}::${s}::${u}`;return this.keyCache.set(e,c),c}get(e){let t=this.generateCacheKey(e),n=this.cache.get(t);return n&&(this.cache.delete(t),this.cache.set(t,n)),n}set(e,t){let n=this.generateCacheKey(e);if(this.cache.size>=this.maxSize){let r=this.cache.keys().next().value;r&&this.cache.delete(r)}this.cache.set(n,t)}clear(){this.cache.clear()}},w0=new gy,A0=e=>{let t=by(e),n=e.children||"";return wy(t.runSync(t.parse(n),n),e)},by=e=>{let t=w0.get(e);if(t)return t;let n=Ty(e);return w0.set(e,n),n},Ey=e=>e.some(t=>Array.isArray(t)?t[0]===xa:t===xa),Ty=e=>{let t=e.rehypePlugins||x0,n=e.remarkPlugins||x0,r=Ey(t)?n:[...n,my],i=e.remarkRehypeOptions?{...y0,...e.remarkRehypeOptions}:y0;return Ck().use(C_).use(r).use(uk,i).use(t)},_y=e=>e,ky=(e,t,n,r)=>{n?e.children.splice(t,1):e.children[t]={type:"text",value:r}},xy=(e,t)=>{var n;for(let r in Xa)if(Object.hasOwn(Xa,r)&&Object.hasOwn(e.properties,r)){let i=e.properties[r],a=Xa[r];(a===null||a.includes(e.tagName))&&(e.properties[r]=(n=t(String(i||""),r,e))!=null?n:void 0)}},yy=(e,t,n,r,i,a)=>{let s=!1;return r?s=!r.includes(e.tagName):i&&(s=i.includes(e.tagName)),!s&&a&&typeof t=="number"&&(s=!a(e,t,n)),s},wy=(e,t)=>{let{allowElement:n,allowedElements:r,disallowedElements:i,skipHtml:a,unwrapDisallowed:s,urlTransform:o}=t;if(n||r||i||a||o){let u=o||_y;It(e,(c,f,d)=>{if(c.type==="raw"&&d&&typeof f=="number")return ky(d,f,a,c.value),f;if(c.type==="element"&&(xy(c,u),yy(c,f,d,r,i,n)&&d&&typeof f=="number"))return s&&c.children?d.children.splice(f,1,...c.children):d.children.splice(f,1),f})}return YT(e,{Fragment:$e,components:t.components,ignoreInvalidStyle:!0,jsx:b,jsxs:b,passKeys:!0,passNode:!0})},Ay=/\[\^[\w-]{1,200}\](?!:)/,Cy=/\[\^[\w-]{1,200}\]:/,Sy=/<(\w+)[\s>]/,Ny=new Set(["area","base","br","col","embed","hr","img","input","link","meta","param","source","track","wbr"]),C0=new Map,S0=new Map,Iy=e=>{let t=e.toLowerCase(),n=C0.get(t);if(n)return n;let r=new RegExp(`<${t}(?=[\\s>/])[^>]*>`,"gi");return C0.set(t,r),r},vy=e=>{let t=e.toLowerCase(),n=S0.get(t);if(n)return n;let r=new RegExp(`</${t}(?=[\\s>])[^>]*>`,"gi");return S0.set(t,r),r},N0=(e,t)=>{if(Ny.has(t.toLowerCase()))return 0;let n=e.match(Iy(t));if(!n)return 0;let r=0;for(let i of n)i.trimEnd().endsWith("/>")||(r+=1);return r},I0=(e,t)=>{let n=e.match(vy(t));return n?n.length:0},Ly=e=>{let t=0;for(let n=0;n<e.length-1;n+=1)e[n]==="$"&&e[n+1]==="$"&&(t+=1,n+=1);return t},Ry=e=>{let t=Ay.test(e),n=Cy.test(e);if(t||n)return[e];let r=ut.lex(e,{gfm:!0}),i=[],a=[],s=!1;for(let o of r){let u=o.raw,c=i.length;if(a.length>0){i[c-1]+=u;let f=a.at(-1),d=N0(u,f),h=I0(u,f);for(let p=0;p<d;p+=1)a.push(f);for(let p=0;p<h;p+=1)a.length>0&&a.at(-1)===f&&a.pop();continue}if(o.type==="html"&&o.block){let f=u.match(Sy);if(f){let d=f[1],h=N0(u,d),p=I0(u,d);h>p&&a.push(d)}}if(c>0&&!s){let f=i[c-1];if(Ly(f)%2===1){i[c-1]=f+u;continue}}i.push(u),o.type!=="space"&&(s=o.type==="code")}return i},Oy=(e,t)=>{if(!t.length)return e;let n=e;for(let r of t){let i=new RegExp(`(<${r}(?=[\\s>/])[^>]*>)([\\s\\S]*?)(</${r}\\s*>)`,"gi");n=n.replace(i,(a,s,o,u)=>{let c=o.replace(/\n\n/g,`
|
|
119
|
+
<!---->
|
|
120
|
+
`);return s+c+u})}return n},Dy=/^[ \t]*<[\w!/?-]/,Py=/(^|\n)[ \t]{4,}(?=<[\w!/?-])/g,My=e=>typeof e!="string"||e.length===0||!Dy.test(e)?e:e.replace(Py,"$1"),v0,L0,Si={...ar,protocols:{...ar.protocols,href:[...(L0=(v0=ar.protocols)==null?void 0:v0.href)!=null?L0:[],"tel"]}},Ns={raw:xa,sanitize:[ol,Si],harden:[Vf,{allowedImagePrefixes:["*"],allowedLinkPrefixes:["*"],allowedProtocols:["*"],defaultOrigin:void 0,allowDataImages:!0}]},By={gfm:[lE,{}]},R0=Object.values(Ns),Fy=Object.values(By),Hy={block:" ▋",circle:" ●"},Uy={shikiTheme:["github-light","github-dark"],controls:!0,isAnimating:!1,mode:"streaming",mermaid:void 0,linkSafety:{enabled:!0}},Ze=Rr(Uy),O0=fe(({content:e,shouldParseIncompleteMarkdown:t,shouldNormalizeHtmlIndentation:n,index:r,isIncomplete:i,...a})=>{let s=typeof e=="string"&&n?My(e):e;return b(Ud.Provider,{value:i,children:b(A0,{...a,children:s})})},(e,t)=>{if(e.content!==t.content||e.shouldNormalizeHtmlIndentation!==t.shouldNormalizeHtmlIndentation||e.index!==t.index||e.isIncomplete!==t.isIncomplete)return!1;if(e.components!==t.components){let n=Object.keys(e.components||{}),r=Object.keys(t.components||{});if(n.length!==r.length||n.some(i=>{var a,s;return((a=e.components)==null?void 0:a[i])!==((s=t.components)==null?void 0:s[i])}))return!1}return!(e.rehypePlugins!==t.rehypePlugins||e.remarkPlugins!==t.remarkPlugins)});O0.displayName="Block";var zy=["github-light","github-dark"],D0=fe(({children:e,mode:t="streaming",parseIncompleteMarkdown:n=!0,normalizeHtmlIndentation:r=!1,components:i,rehypePlugins:a=R0,remarkPlugins:s=Fy,className:o,shikiTheme:u=zy,mermaid:c,controls:f=!0,isAnimating:d=!1,animated:h,BlockComponent:p=O0,parseMarkdownIntoBlocksFn:m=Ry,caret:_,plugins:w,remend:y,linkSafety:S={enabled:!0},allowedTags:C,...D})=>{let P=rf(),[A,U]=Ff(),I=we(()=>C?Object.keys(C):[],[C]),H=we(()=>{if(typeof e!="string")return"";let Z=t==="streaming"&&n?g3(e,y):e;return I.length>0&&(Z=Oy(Z,I)),Z},[e,t,n,y,I]),N=we(()=>m(H),[H,m]),[$,B]=oe(N);ye(()=>{t==="streaming"?U(()=>{B(N)}):B(N)},[N,t]);let W=t==="streaming"?$:N,ie=we(()=>W.map((Z,x)=>`${P}-${x}`),[W.length,P]),K=we(()=>h?h===!0?Ts():Ts(h):null,[h]),de=we(()=>{var Z,x;return{shikiTheme:(x=(Z=w?.code)==null?void 0:Z.getThemes())!=null?x:u,controls:f,isAnimating:d,mode:t,mermaid:c,linkSafety:S}},[u,f,d,t,c,S,w?.code]),re=we(()=>({...dy,...i}),[i]),Se=we(()=>{let Z=[];return w!=null&&w.cjk&&(Z=[...Z,...w.cjk.remarkPluginsBefore]),Z=[...Z,...s],w!=null&&w.cjk&&(Z=[...Z,...w.cjk.remarkPluginsAfter]),w!=null&&w.math&&(Z=[...Z,w.math.remarkPlugin]),Z},[s,w?.math,w?.cjk]),Le=we(()=>{var Z;let x=a;if(C&&Object.keys(C).length>0&&a===R0){let Ne={...Si,tagNames:[...(Z=Si.tagNames)!=null?Z:[],...Object.keys(C)],attributes:{...Si.attributes,...C}};x=[Ns.raw,[ol,Ne],Ns.harden]}return w!=null&&w.math&&(x=[...x,w.math.rehypePlugin]),K&&d&&(x=[...x,K.rehypePlugin]),x},[a,w?.math,K,d,C]),T=we(()=>{if(!d||W.length===0)return!1;let Z=W.at(-1);return k0(Z)||py(Z)},[d,W]),Re=we(()=>_&&d&&!T?{"--streamdown-caret":`"${Hy[_]}"`}:void 0,[_,d,T]);return t==="static"?b(xs.Provider,{value:w??null,children:b(Ze.Provider,{value:de,children:b("div",{className:Q("space-y-4 whitespace-normal *:first:mt-0 *:last:mb-0",o),children:b(A0,{components:re,rehypePlugins:Le,remarkPlugins:Se,...D,children:H})})})}):b(xs.Provider,{value:w??null,children:b(Ze.Provider,{value:de,children:b("div",{className:Q("space-y-4 whitespace-normal *:first:mt-0 *:last:mb-0",_&&!T?"*:last:after:inline *:last:after:align-baseline *:last:after:content-[var(--streamdown-caret)]":null,o),style:Re,children:[W.length===0&&_&&d&&b("span",{}),W.map((Z,x)=>{let Ne=x===W.length-1,he=d&&Ne&&k0(Z);return b(p,{components:re,content:Z,index:x,isIncomplete:he,rehypePlugins:Le,remarkPlugins:Se,shouldNormalizeHtmlIndentation:r,shouldParseIncompleteMarkdown:n,...D},ie[x])})]})})})},(e,t)=>e.children===t.children&&e.shikiTheme===t.shikiTheme&&e.isAnimating===t.isAnimating&&e.animated===t.animated&&e.mode===t.mode&&e.plugins===t.plugins&&e.className===t.className&&e.linkSafety===t.linkSafety&&e.normalizeHtmlIndentation===t.normalizeHtmlIndentation);D0.displayName="Streamdown";var $y=({children:e,className:t,minZoom:n=.5,maxZoom:r=3,zoomStep:i=.1,showControls:a=!0,initialZoom:s=1,fullscreen:o=!1})=>{let u=Oe(null),c=Oe(null),[f,d]=oe(s),[h,p]=oe({x:0,y:0}),[m,_]=oe(!1),[w,y]=oe({x:0,y:0}),[S,C]=oe({x:0,y:0}),D=De(B=>{d(W=>Math.max(n,Math.min(r,W+B)))},[n,r]),P=De(()=>{D(i)},[D,i]),A=De(()=>{D(-i)},[D,i]),U=De(()=>{d(s),p({x:0,y:0})},[s]),I=De(B=>{B.preventDefault();let W=B.deltaY>0?-i:i;D(W)},[D,i]),H=De(B=>{if(B.button!==0||B.isPrimary===!1)return;_(!0),y({x:B.clientX,y:B.clientY}),C(h);let W=B.currentTarget;W instanceof HTMLElement&&W.setPointerCapture(B.pointerId)},[h]),N=De(B=>{if(!m)return;B.preventDefault();let W=B.clientX-w.x,ie=B.clientY-w.y;p({x:S.x+W,y:S.y+ie})},[m,w,S]),$=De(B=>{_(!1);let W=B.currentTarget;W instanceof HTMLElement&&W.releasePointerCapture(B.pointerId)},[]);return ye(()=>{let B=u.current;if(B)return B.addEventListener("wheel",I,{passive:!1}),()=>{B.removeEventListener("wheel",I)}},[I]),ye(()=>{let B=c.current;if(B&&m)return document.body.style.userSelect="none",B.addEventListener("pointermove",N,{passive:!1}),B.addEventListener("pointerup",$),B.addEventListener("pointercancel",$),()=>{document.body.style.userSelect="",B.removeEventListener("pointermove",N),B.removeEventListener("pointerup",$),B.removeEventListener("pointercancel",$)}},[m,N,$]),b("div",{className:Q("relative flex flex-col",o?"h-full w-full":"min-h-28 w-full",t),ref:u,style:{cursor:m?"grabbing":"grab"},children:[a?b("div",{className:Q("absolute z-10 flex flex-col gap-1 rounded-md border border-border bg-background/80 p-1 supports-[backdrop-filter]:bg-background/70 supports-[backdrop-filter]:backdrop-blur-sm",o?"bottom-4 left-4":"bottom-2 left-2"),children:[b("button",{className:"flex items-center justify-center rounded p-1.5 text-muted-foreground transition-colors hover:bg-muted hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",disabled:f>=r,onClick:P,title:"Zoom in",type:"button",children:b($x,{size:16})}),b("button",{className:"flex items-center justify-center rounded p-1.5 text-muted-foreground transition-colors hover:bg-muted hover:text-foreground disabled:cursor-not-allowed disabled:opacity-50",disabled:f<=n,onClick:A,title:"Zoom out",type:"button",children:b(Yx,{size:16})}),b("button",{className:"flex items-center justify-center rounded p-1.5 text-muted-foreground transition-colors hover:bg-muted hover:text-foreground",onClick:U,title:"Reset zoom and pan",type:"button",children:b(zx,{size:16})})]}):null,b("div",{className:Q("flex-1 origin-center transition-transform duration-150 ease-out",o?"flex h-full w-full items-center justify-center":"flex w-full items-center justify-center"),onPointerDown:H,ref:c,role:"application",style:{transform:`translate(${h.x}px, ${h.y}px) scale(${f})`,transformOrigin:"center center",touchAction:"none",willChange:"transform"},children:e})]})},P0=({chart:e,className:t,config:n,fullscreen:r=!1,showControls:i=!0})=>{let[a,s]=oe(null),[o,u]=oe(!1),[c,f]=oe(""),[d,h]=oe(""),[p,m]=oe(0),{mermaid:_}=Ve(Ze),w=ys(),y=_?.errorComponent,{shouldRender:S,containerRef:C}=xx({immediate:r});if(ye(()=>{if(S){if(!w){s("Mermaid plugin not available. Please add the mermaid plugin to enable diagram rendering.");return}(async()=>{try{s(null),u(!0);let P=w.getMermaid(n),A=e.split("").reduce((H,N)=>(H<<5)-H+N.charCodeAt(0)|0,0),U=`mermaid-${Math.abs(A)}-${Date.now()}-${Math.random().toString(36).substring(2,9)}`,{svg:I}=await P.render(U,e);f(I),h(I)}catch(P){if(!(d||c)){let A=P instanceof Error?P.message:"Failed to render Mermaid chart";s(A)}}finally{u(!1)}})()}},[e,n,p,S,w]),!(S||c||d))return b("div",{className:Q("my-4 min-h-[200px]",t),ref:C});if(o&&!c&&!d)return b("div",{className:Q("my-4 flex justify-center p-4",t),ref:C,children:b("div",{className:"flex items-center space-x-2 text-muted-foreground",children:[b("div",{className:"h-4 w-4 animate-spin rounded-full border-current border-b-2"}),b("span",{className:"text-sm",children:"Loading diagram..."})]})});if(a&&!c&&!d)return y?b("div",{ref:C,children:b(y,{chart:e,error:a,retry:()=>m(A=>A+1)})}):b("div",{className:Q("rounded-md bg-red-50 p-4",t),ref:C,children:[b("p",{className:"font-mono text-red-700 text-sm",children:["Mermaid Error: ",a]}),b("details",{className:"mt-2",children:[b("summary",{className:"cursor-pointer text-red-600 text-xs",children:"Show Code"}),b("pre",{className:"mt-2 overflow-x-auto rounded bg-red-100 p-2 text-red-800 text-xs",children:e})]})]});let D=c||d;return b("div",{className:Q("size-full",t),"data-streamdown":"mermaid",ref:C,children:b($y,{className:Q(r?"size-full overflow-hidden":"overflow-hidden",t),fullscreen:r,maxZoom:3,minZoom:.5,showControls:i,zoomStep:.1,children:b("div",{"aria-label":"Mermaid chart",className:Q("flex justify-center",r?"size-full items-center":null),dangerouslySetInnerHTML:{__html:D},role:"img"})})})};function Yy({href:e,children:t}){return b("a",{href:e,target:"_blank",rel:"noopener noreferrer",class:"fr text-kin-accent underline underline-offset-2 transition-colors hover:decoration-2 focus-visible:rounded-[2px]",children:t})}const jy={a:Yy};function Vy({content:e,isStreaming:t=!1}){return e?b("div",{class:"kin-markdown text-kin-bubble-assistant-text text-sm leading-relaxed",children:b(D0,{isAnimating:t,mode:t?"streaming":"static",components:jy,children:e})}):null}const Ln="h-2 w-2 animate-kin-typing rounded-full bg-kin-text-muted",M0="mt-1.5 inline-flex items-center gap-1.5 pl-1 text-xs text-kin-text-muted",Is=St({base:"flex flex-1 flex-col gap-4 overflow-y-auto break-words p-4 overscroll-contain pl-safe-l pr-safe-r sm:overscroll-auto sm:px-4 [&::-webkit-scrollbar]:w-1.5 [&::-webkit-scrollbar-track]:bg-transparent [&::-webkit-scrollbar-thumb]:rounded-[3px] [&::-webkit-scrollbar-thumb]:bg-kin-bg-muted",variants:{empty:{true:"items-center justify-center",false:""}}}),B0="animate-kin-fade-in px-6 py-6 text-center",F0={animationDelay:"150ms"},qy=St({base:"animate-kin-message-in flex max-w-[85%] flex-col",variants:{side:{user:"self-end",assistant:"self-start"}}}),Wy=St({base:"rounded-2xl px-4 py-3",variants:{side:{user:"rounded-br bg-kin-bubble-user text-kin-bubble-user-text",assistant:"rounded-bl border border-kin-border bg-kin-bubble-assistant text-kin-bubble-assistant-text"}}});function Gy(){const e=$i(()=>Y.messages.value),t=$i(()=>Y.isStreaming.value),n=$i(()=>Y.connectionState.value),r=Oe(null),i=()=>{r.current&&(r.current.scrollTop=r.current.scrollHeight)};if(ye(()=>{const c=setTimeout(i,380);return()=>clearTimeout(c)},[]),ye(()=>{i()},[e.value,t.value]),n.value==="connecting"&&e.value.length===0)return b("div",{class:Is({empty:!0}),role:"log","aria-label":"Chat messages","aria-live":"polite",children:b("div",{class:B0,style:F0,children:b("div",{class:"flex gap-1.5 p-2","aria-label":"Loading conversation",children:[b("span",{class:Ln}),b("span",{class:Ln,style:{animationDelay:"0.15s"}}),b("span",{class:Ln,style:{animationDelay:"0.3s"}})]})})});if(e.value.length===0&&!t.value)return b("div",{class:Is({empty:!0}),role:"log","aria-label":"Chat messages","aria-live":"polite",children:b("div",{class:B0,style:F0,children:[b("div",{class:"text-kin-text-muted size-12 mx-auto mb-4 opacity-50","aria-hidden":"true",children:b(gf,{class:"h-full w-full"})}),b("p",{class:"text-kin-text mb-2 text-base",children:"Hi there, you're speaking with Kin AI Agent."}),b("p",{class:"text-kin-text-muted text-sm",children:"How can I help you today?"})]})});const s=e.value[e.value.length-1],o=t.value&&s?.role==="assistant"&&!s.content.trim();let u=0;return b("div",{class:Is({empty:!1}),ref:r,role:"log","aria-label":"Chat messages","aria-live":"polite","aria-relevant":"additions",children:[b("div",{class:"text-kin-glow-1 flex items-center gap-3 text-xs font-medium uppercase tracking-wide before:h-px before:flex-1 before:bg-[linear-gradient(90deg,transparent,var(--kin-glow-1),transparent)] before:opacity-30 before:content-[''] after:h-px after:flex-1 after:bg-[linear-gradient(90deg,transparent,var(--kin-glow-1),transparent)] after:opacity-30 after:content-['']",role:"separator","aria-hidden":"true",children:b("span",{children:"New"})}),e.value.map((c,f)=>{if(c.role==="assistant"&&!c.content.trim())return null;const d=u;u+=1;const h=f===e.value.length-1,p=t.value&&h&&c.role==="assistant";return b(Ky,{message:c,isStreaming:p,animationIndex:d},c.id)}),o&&b(Qy,{})]})}function Qy(){return b("div",{class:"animate-kin-message-in inline-flex flex-col self-start",role:"status","aria-label":"Kin is typing",children:[b("div",{class:"min-h-11 border-kin-border bg-kin-bubble-assistant inline-flex w-fit items-center gap-1.5 rounded-2xl rounded-bl border px-4 py-3","aria-hidden":"true",children:[b("span",{class:Ln}),b("span",{class:Ln,style:{animationDelay:"0.15s"}}),b("span",{class:Ln,style:{animationDelay:"0.3s"}})]}),b("div",{class:M0,"aria-hidden":"true",children:[b("span",{children:"Kin"}),b("span",{children:"•"}),b("span",{children:"AI Agent"}),b("span",{children:"•"}),b("span",{children:"typing..."})]}),b("span",{class:"sr-only",children:"Kin AI Agent is typing a response"})]})}function Ky({message:e,isStreaming:t=!1,animationIndex:n}){const r=e.role==="user",i=e.role==="system",a=r?"user":"assistant",s=r?"You":i?"System":"Kin AI Agent",o=Math.min((n+1)*.05,.35);return i?b("div",{class:"flex justify-center px-4 py-2",role:"status","aria-label":"System notification",children:b("span",{class:"border-kin-border bg-kin-bg-surface text-kin-text-muted rounded-xl border px-3 py-1.5 text-xs",children:e.content})}):b("article",{class:qy({side:a}),style:{animationDelay:`${o}s`},"aria-label":`Message from ${s}`,children:[b("div",{class:Wy({side:a}),children:r?b("p",{children:e.content}):b(Vy,{content:e.content,isStreaming:t})}),!r&&b("div",{class:M0,"aria-hidden":"true",children:[b("span",{children:"Kin"}),b("span",{children:"•"}),b("span",{children:"AI Agent"}),b("span",{children:"•"}),b("span",{children:t?"typing...":Xy(e.timestamp)})]})]})}function Xy(e){const n=new Date().getTime()-e.getTime();return n<6e4?"Just now":n<36e5?`${Math.floor(n/6e4)}m ago`:e.toLocaleTimeString([],{hour:"2-digit",minute:"2-digit"})}const H0=St({base:"fr inline-flex size-11 items-center justify-center rounded-lg transition-colors duration-200 sm:size-8 [&>svg]:size-4",variants:{variant:{close:"bg-transparent text-kin-text-muted hover:bg-kin-bg-muted hover:text-kin-text",clear:"bg-transparent text-sm text-kin-accent hover:bg-kin-bg-muted",confirm:"text-sm bg-kin-accent text-white hover:opacity-90"}},defaultVariants:{variant:"close"}});function Zy({onClose:e,onClearData:t,onSkipToInput:n}){const[r,i]=oe(!1),a=o=>{o.key==="Escape"&&(o.preventDefault(),r?i(!1):e())},s=()=>{r?(t(),i(!1)):i(!0)};return b("div",{class:"kin-panel bg-kin-bg-base sm:border-kin-border sm:shadow-kin-panel sm:animate-kin-panel-in sm:w-kin-panel flex h-auto min-h-0 w-full max-w-none flex-1 animate-none flex-col overflow-hidden rounded-none border-0 shadow-none [will-change:transform,opacity] sm:max-w-[calc(100vw-2rem)] sm:rounded-2xl sm:border",role:"dialog","aria-modal":"true","aria-labelledby":"kin-panel-title",onKeyDown:a,children:[b("button",{type:"button",class:"fr bg-kin-bg-elevated text-kin-text absolute -top-full left-1/2 z-[1000000] -translate-x-1/2 rounded-lg px-4 py-2 font-medium no-underline focus:top-2",onClick:n,children:"Skip to chat input"}),b("header",{class:"border-kin-border bg-kin-bg-elevated pl-safe-l pr-safe-r pt-safe-t flex items-center justify-between border-b px-4 pb-4 sm:p-4",children:[b("h2",{id:"kin-panel-title",class:"text-kin-text text-base font-semibold sm:text-sm sm:font-medium",children:"Kin Assistant"}),b("div",{class:"flex items-center gap-1",children:[b("button",{class:H0({variant:r?"confirm":"clear"}),"aria-label":r?"Confirm clear data":"Clear my data",title:r?"Click again to confirm":"Clear my data",type:"button",onClick:s,onBlur:()=>i(!1),children:r?"✓":b(Tf,{})}),b("button",{class:H0({variant:"close"}),"aria-label":"Close chat",type:"button",onClick:e,children:b(Ef,{})})]})]}),b(Gy,{})]})}const Jy={"application/pdf":{maxSize:1e7},"application/vnd.openxmlformats-officedocument.wordprocessingml.document":{maxSize:1e7},"application/msword":{maxSize:1e7},"text/plain":{maxSize:1e6},"image/jpeg":{maxSize:1e7},"image/png":{maxSize:1e7},"image/webp":{maxSize:1e7}},e6=".pdf,.docx,.doc,.txt,.jpg,.jpeg,.png,.webp";function t6(e){const t=Jy[e.type];return t?e.size>t.maxSize?{valid:!1,error:`File is too large. Maximum size is ${Math.round(t.maxSize/1e6)}MB.`}:e.size===0?{valid:!1,error:"The file appears to be empty."}:{valid:!0}:{valid:!1,error:"Unsupported file format. Please upload a PDF, Word document, text file, or image."}}function n6(e){return new Promise((t,n)=>{const r=new FileReader;r.onload=()=>{typeof r.result=="string"?t(r.result):n(new Error("Failed to read file"))},r.onerror=()=>n(r.error),r.readAsDataURL(e)})}function r6({url:e,onMessage:t,onOpen:n,onClose:r,onError:i}){let a=null,s=[];const o=()=>{if(!(!a||a.readyState!==WebSocket.OPEN)){for(const c of s)a.send(JSON.stringify({type:"user_message",content:c}));s=[]}};return(()=>{a=new WebSocket(e),a.onopen=()=>{n(),o()},a.onmessage=c=>{try{const f=JSON.parse(c.data);t(f)}catch{}},a.onclose=()=>{s=[],r(),a=null},a.onerror=c=>{i(c)}})(),{sendMessage:c=>{a&&(a.readyState===WebSocket.OPEN?a.send(JSON.stringify({type:"user_message",content:c})):a.readyState===WebSocket.CONNECTING&&s.push(c))},uploadFile:async(c,f)=>{if(!a||a.readyState!==WebSocket.OPEN)return{success:!1,error:"Not connected"};const d=t6(c);if(!d.valid)return{success:!1,error:d.error};try{const h=await n6(c);return!a||a.readyState!==WebSocket.OPEN?{success:!1,error:"Connection lost while reading file. Please try again."}:(a.send(JSON.stringify({type:"file_upload",fileType:f,fileName:c.name,mimeType:c.type,data:h})),{success:!0})}catch(h){return{success:!1,error:h instanceof Error?h.message:"Failed to read file"}}},clearData:()=>{a&&a.readyState===WebSocket.OPEN&&a.send(JSON.stringify({type:"clear_data"}))},disconnect:()=>{a&&(a.close(),a=null)},isConnected:()=>a?.readyState===WebSocket.OPEN}}const U0=2e3,z0="absolute bottom-full left-1/2 mb-2 -translate-x-1/2 whitespace-nowrap rounded-lg bg-red-600 px-3 py-2 text-xs text-white animate-kin-error-in",i6="inline-flex items-center whitespace-nowrap rounded-3xl ring-1 ring-[color-mix(in_srgb,var(--kin-accent)_30%,transparent)] bg-[color-mix(in_srgb,var(--kin-accent)_12%,transparent)] px-3.5 py-1.5 text-sm font-medium text-kin-accent opacity-0 transition-[background,shadow,transform] duration-150 hover:ring-kin-accent hover:bg-kin-accent hover:text-white focus-visible:shadow-[0_0_0_2px_var(--kin-focus-ring)] active:scale-95 animate-kin-starter-fade-in",a6=St({base:"kin-launcher w-full max-w-full sm:max-w-[calc(100vw-3rem)] sm:focus-within:w-kin-panel",variants:{open:{true:"border-t border-kin-border sm:w-kin-panel sm:border-0",false:"px-3 pt-2 pb-safe-b sm:w-96 sm:px-0 sm:pt-0 sm:pb-0 sm:transition-[width] sm:duration-300 sm:ease-kin-open"}}}),s6=St({base:"kin-launcher-input-wrapper relative flex rounded-3xl [&::before]:hidden [&::after]:hidden sm:[&::before]:block sm:[&::after]:block",variants:{open:{true:"rounded-none bg-kin-bg-base shadow-none px-3 pt-2 pb-safe-b sm:rounded-3xl sm:bg-kin-bg-elevated sm:shadow-kin-border",false:"bg-kin-bg-elevated shadow-kin-border focus-within:shadow-[0_0_0_2px_var(--kin-accent)] sm:focus-within:shadow-kin-border"},pills:{true:"flex-col items-stretch gap-2 pt-2.5 pb-1 pl-3.5 pr-1.5 sm:py-1 sm:pt-2.5",false:"items-center gap-2 py-1.5 pl-4 pr-1.5 sm:gap-3 sm:py-1"}}}),$0=St({base:"fr inline-flex size-10 shrink-0 items-center justify-center rounded-full transition-all duration-200 disabled:cursor-not-allowed disabled:opacity-50 sm:size-9 [&>svg]:size-4",variants:{variant:{attach:"-mr-2 bg-transparent text-kin-text-muted hover:bg-kin-bg-muted hover:text-kin-text",send:"kin-launcher-send bg-kin-bg-muted text-kin-text-muted enabled:bg-kin-accent enabled:text-white enabled:hover:scale-105 sm:enabled:bg-kin-text sm:enabled:text-kin-bg-base"}}});function o6({isOpen:e,starterPrompts:t,onOpen:n,onClose:r,onSendMessage:i,onConnect:a,onUploadFile:s,inputRef:o}){const[u,c]=oe(""),[f,d]=oe(!1),h=Oe(null),p=o??h,m=Oe(null),[_,w]=oe(Y.isStreaming.value),[y,S]=oe(Y.connectionState.value),[C,D]=oe(Y.messages.value.length>0),[P,A]=oe(Y.uploadState.value),[U,I]=oe(Y.uploadError.value),[H,N]=oe(Y.uploadFileName.value),[$,B]=oe(Y.quickReplies.value);ye(()=>Un(()=>{w(Y.isStreaming.value),S(Y.connectionState.value),D(Y.messages.value.length>0),A(Y.uploadState.value),I(Y.uploadError.value),N(Y.uploadFileName.value),B(Y.quickReplies.value)}),[]);const W=y==="connected",ie=y==="connecting",K=y==="disconnected",de=y==="idle",re=P==="uploading"||P==="processing",Se=u.length>U0,Le=u.trim(),T=Le.length>0,Re=T&&!_&&!re&&!Se&&(W||ie),Z=W&&!_&&!re;ye(()=>{e&&p.current&&requestAnimationFrame(()=>{p.current?.focus()})},[e]);const x=()=>{d(!0),a(),!e&&C&&n()},Ne=ce=>{ce.relatedTarget?.closest(".kin-launcher-input-wrapper")||d(!1)},he=ce=>{if(ce.preventDefault(),!Re)return;const Fe=Le;Y.addMessage({role:"user",content:Fe}),e||n(),i(Fe),c("")},ae=ce=>{ce.key==="Enter"&&!ce.shiftKey&&(ce.preventDefault(),he(ce)),ce.key==="Escape"&&e&&(ce.preventDefault(),ce.stopPropagation(),r())},rt=ce=>{const Fe=ce.target,jt=Fe.files?.[0];jt&&(e||n(),s(jt,"cv")),Fe.value=""},Je=()=>{m.current?.click()},be=()=>re?H?`Uploading ${H}...`:"Uploading file...":ie?"Connecting...":K?"Disconnected - Click to retry":_?"Waiting for response...":!e&&C?"Continue conversation...":"Ask me anything...",lt=()=>re?H?`Uploading ${H}...`:"Uploading file...":_?"Waiting for response":de?"Click to connect":ie?"Connecting...":!W&&!T?"Enter a message to send":W?T?"Send message":"Enter a message to send":"Cannot send message",ct=()=>re?"Uploading...":Z?"Attach file (CV, document, or image)":"Cannot upload file",$t=ce=>{a(),Y.addMessage({role:"user",content:ce.message}),n(),i(ce.message)},dn=ce=>{e||n(),a(),Y.addMessage({role:"user",content:ce}),i(ce)},Yt=$.length>0&&e,yr=t.length>0&&!C&&f,Rn=Yt||yr,vi=ce=>`${Math.min(.03+ce*.04,.19)}s`,Li=({key:ce,label:Fe,index:jt,onClick:Ls,onPointerDown:Rs})=>b("button",{type:"button",class:i6,style:{animationDelay:vi(jt)},onPointerDown:Rs,onClick:Ls,children:Fe},ce);return b("div",{class:a6({open:e}),role:"search","aria-label":"Chat with Kin AI",children:b("form",{onSubmit:he,class:"relative",children:[b("div",{class:s6({open:e,pills:Rn}),children:[Rn&&b("div",{class:"flex flex-wrap gap-1.5",children:yr?t.map((ce,Fe)=>Li({key:`s-${Fe}`,label:ce.label,index:Fe,onPointerDown:jt=>jt.preventDefault(),onClick:()=>$t(ce)})):$.map((ce,Fe)=>Li({key:`q-${Fe}`,label:ce,index:Fe,onClick:()=>dn(ce)}))}),b("div",{class:"flex flex-1 items-center gap-3",children:[b("label",{for:"kin-input",class:"sr-only",children:"Ask Kin a question"}),b("input",{id:"kin-input",ref:p,type:"text",class:"text-kin-text placeholder:text-kin-text-muted min-w-0 flex-1 border-none bg-transparent py-2.5 text-base outline-none disabled:cursor-not-allowed sm:py-3 sm:text-sm",placeholder:Rn?"Or type a message...":be(),value:u,onInput:ce=>c(ce.target.value),onFocus:x,onBlur:Ne,onKeyDown:ae,"aria-describedby":"kin-input-status",autoComplete:"off",disabled:re}),b("input",{ref:m,type:"file",class:"sr-only",accept:e6,onChange:rt,"aria-hidden":"true",tabIndex:-1}),b("button",{type:"button",class:$0({variant:"attach"}),disabled:!Z,"aria-label":ct(),onClick:Je,children:re?b(kf,{class:"animate-kin-spin"}):b(_f,{})}),b("button",{type:"submit",class:$0({variant:"send"}),disabled:!Re,"aria-label":lt(),children:b(bf,{})})]})]}),b("div",{id:"kin-input-status",class:"sr-only",role:"status","aria-live":"polite",children:[ie&&"Connecting to Kin...",K&&"Connection lost. Click input to retry.",_&&"Kin is responding...",re&&(H?`Uploading ${H}...`:"Uploading file...")]}),U&&P==="error"&&b("div",{class:`${z0} max-w-[calc(100%-32px)] truncate`,role:"alert",children:U}),Se&&b("div",{class:z0,role:"alert",children:["Message too long (",u.length.toLocaleString(),"/",U0.toLocaleString()," characters)"]})]})})}const u6=St({base:"kin-widget font-kin text-kin text-kin-text fixed inset-x-0 bottom-0 z-[999999] flex w-full flex-col items-stretch overflow-hidden sm:inset-x-auto sm:bottom-6 sm:left-1/2 sm:w-auto sm:-translate-x-1/2 sm:items-center sm:gap-4 sm:overflow-visible",variants:{open:{true:"top-0 h-dvh bg-kin-bg-base [touch-action:manipulation] sm:top-auto sm:h-auto sm:min-h-[50vh] sm:max-h-[90vh] sm:bg-transparent sm:[touch-action:auto]",false:""}}});function l6({starterPrompts:e,onSendMessage:t,onOpen:n,onClose:r,onConnect:i,onClearData:a,onUploadFile:s,embedded:o=!1}){const[u,c]=oe(o||Y.isOpen.value),f=Oe(null),d=Oe(null),h=Oe(null);ye(()=>Un(()=>{c(o||Y.isOpen.value)}),[o]),ye(()=>{o&&!Y.isOpen.value&&n()},[o,n]),ye(()=>{if(!u||o)return;const w=window.matchMedia("(max-width: 639px)");let y=0,S="",C=!1;const D=()=>{C||(y=window.scrollY,S=document.body.style.overflow,document.body.style.overflow="hidden",C=!0)},P=()=>{C&&(document.body.style.overflow=S,window.scrollTo(0,y),C=!1)},A=()=>{w.matches?D():P()};return A(),w.addEventListener("change",A),()=>{w.removeEventListener("change",A),P()}},[u,o]);const p=De(()=>{d.current=document.activeElement,n()},[n]),m=De(()=>{r(),d.current?.focus()},[r]),_=De(()=>{h.current?.focus()},[]);return ye(()=>{if(!u)return;const w=()=>{let S=document.activeElement;for(;S?.shadowRoot?.activeElement;)S=S.shadowRoot.activeElement;return S},y=S=>{if(S.key!=="Tab")return;const C=f.current;if(!C)return;const D=C.querySelectorAll('button:not([disabled]), input:not([disabled]), [tabindex]:not([tabindex="-1"])');if(D.length===0)return;const P=D[0],A=D[D.length-1];if(!P||!A)return;const U=w();S.shiftKey&&U===P?(S.preventDefault(),A.focus()):!S.shiftKey&&U===A&&(S.preventDefault(),P.focus())};return document.addEventListener("keydown",y),()=>document.removeEventListener("keydown",y)},[u]),b("div",{ref:f,class:u6({open:u}),role:"region","aria-label":"Kin AI Chat",children:[b("div",{class:"sr-only",role:"status","aria-live":"polite","aria-atomic":"true",children:u?"Chat panel opened":""}),u&&b(Zy,{onClose:m,onClearData:a,onSkipToInput:_}),b(o6,{isOpen:u,starterPrompts:e,onOpen:p,onClose:m,onSendMessage:t,onConnect:i,onUploadFile:s,inputRef:h})]})}const c6=`*,:before,:after{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }::backdrop{--tw-border-spacing-x: 0;--tw-border-spacing-y: 0;--tw-translate-x: 0;--tw-translate-y: 0;--tw-rotate: 0;--tw-skew-x: 0;--tw-skew-y: 0;--tw-scale-x: 1;--tw-scale-y: 1;--tw-gradient-from-position: ;--tw-gradient-via-position: ;--tw-gradient-to-position: ;--tw-ordinal: ;--tw-slashed-zero: ;--tw-numeric-figure: ;--tw-numeric-spacing: ;--tw-numeric-fraction: ;--tw-ring-inset: ;--tw-ring-offset-width: 0px;--tw-ring-offset-color: #fff;--tw-ring-color: rgb(59 130 246 / .5);--tw-ring-offset-shadow: 0 0 #0000;--tw-ring-shadow: 0 0 #0000;--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;--tw-blur: ;--tw-brightness: ;--tw-contrast: ;--tw-grayscale: ;--tw-hue-rotate: ;--tw-invert: ;--tw-saturate: ;--tw-sepia: ;--tw-drop-shadow: ;--tw-backdrop-blur: ;--tw-backdrop-brightness: ;--tw-backdrop-contrast: ;--tw-backdrop-grayscale: ;--tw-backdrop-hue-rotate: ;--tw-backdrop-invert: ;--tw-backdrop-opacity: ;--tw-backdrop-saturate: ;--tw-backdrop-sepia: ;--tw-contain-size: ;--tw-contain-layout: ;--tw-contain-paint: ;--tw-contain-style: }*{box-sizing:border-box;font:inherit;border:0 solid;-webkit-tap-highlight-color:transparent}button{all:unset;cursor:pointer;touch-action:manipulation}ul,ol,li,p{margin:0;padding:0}ul,ol{list-style:none}svg{display:block}.sr-only{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0,0,0,0);white-space:nowrap;border-width:0}.visible{visibility:visible}.static{position:static}.fixed{position:fixed}.absolute{position:absolute}.relative{position:relative}.inset-x-0{left:0;right:0}.-top-full{top:-100%}.bottom-0{bottom:0}.bottom-full{bottom:100%}.left-1\\/2{left:50%}.top-0{top:0}.z-\\[1000000\\]{z-index:1000000}.z-\\[999999\\]{z-index:999999}.mx-auto{margin-left:auto;margin-right:auto}.-mr-2{margin-right:-.5rem}.mb-2{margin-bottom:.5rem}.mb-4{margin-bottom:1rem}.mt-1\\.5{margin-top:.375rem}.block{display:block}.inline{display:inline}.flex{display:flex}.inline-flex{display:inline-flex}.hidden{display:none}.size-10{width:2.5rem;height:2.5rem}.size-11{width:2.75rem;height:2.75rem}.size-12{width:3rem;height:3rem}.h-2{height:.5rem}.h-auto{height:auto}.h-dvh{height:100dvh}.h-full{height:100%}.min-h-0{min-height:0px}.min-h-11{min-height:2.75rem}.w-2{width:.5rem}.w-fit{width:-moz-fit-content;width:fit-content}.w-full{width:100%}.min-w-0{min-width:0px}.max-w-\\[85\\%\\]{max-width:85%}.max-w-\\[calc\\(100\\%-32px\\)\\]{max-width:calc(100% - 32px)}.max-w-full{max-width:100%}.max-w-none{max-width:none}.flex-1{flex:1 1 0%}.shrink-0{flex-shrink:0}.-translate-x-1\\/2{--tw-translate-x: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.transform{transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes kin-error-in{0%{opacity:0;transform:translate(-50%) translateY(4px)}to{opacity:1;transform:translate(-50%) translateY(0)}}.animate-kin-error-in{animation:kin-error-in .2s ease}.animate-kin-fade-in{animation:kin-fade .4s ease both}@keyframes kin-slide-up{0%{opacity:0;transform:translateY(8px)}to{opacity:1;transform:translateY(0)}}.animate-kin-message-in{animation:kin-slide-up .3s cubic-bezier(.32,.72,0,1) both}@keyframes spin{to{transform:rotate(360deg)}}.animate-kin-spin{animation:spin 1s linear infinite}@keyframes kin-fade{0%{opacity:0}to{opacity:1}}.animate-kin-starter-fade-in{animation:kin-fade .22s ease-out forwards}@keyframes kin-typing{0%,to{opacity:.3;transform:scale(.85)}50%{opacity:1;transform:scale(1)}}.animate-kin-typing{animation:kin-typing 1.4s ease-in-out infinite}.animate-none{animation:none}.flex-col{flex-direction:column}.flex-wrap{flex-wrap:wrap}.items-center{align-items:center}.items-stretch{align-items:stretch}.justify-center{justify-content:center}.justify-between{justify-content:space-between}.gap-1{gap:.25rem}.gap-1\\.5{gap:.375rem}.gap-2{gap:.5rem}.gap-3{gap:.75rem}.gap-4{gap:1rem}.self-start{align-self:flex-start}.self-end{align-self:flex-end}.overflow-hidden{overflow:hidden}.overflow-y-auto{overflow-y:auto}.overscroll-contain{overscroll-behavior:contain}.truncate{overflow:hidden;text-overflow:ellipsis;white-space:nowrap}.whitespace-nowrap{white-space:nowrap}.break-words{overflow-wrap:break-word}.rounded-2xl{border-radius:1rem}.rounded-3xl{border-radius:1.5rem}.rounded-full{border-radius:9999px}.rounded-lg{border-radius:.5rem}.rounded-none{border-radius:0}.rounded-xl{border-radius:.75rem}.rounded-bl{border-bottom-left-radius:.25rem}.rounded-br{border-bottom-right-radius:.25rem}.border{border-width:1px}.border-0{border-width:0px}.border-b{border-bottom-width:1px}.border-t{border-top-width:1px}.border-none{border-style:none}.border-kin-border{border-color:var(--kin-border)}.bg-\\[color-mix\\(in_srgb\\,var\\(--kin-accent\\)_12\\%\\,transparent\\)\\]{background-color:color-mix(in srgb,var(--kin-accent) 12%,transparent)}.bg-kin-accent{background-color:var(--kin-accent)}.bg-kin-bg-base{background-color:var(--kin-bg-base)}.bg-kin-bg-elevated{background-color:var(--kin-bg-elevated)}.bg-kin-bg-muted{background-color:var(--kin-bg-muted)}.bg-kin-bg-surface{background-color:var(--kin-bg-surface)}.bg-kin-bubble-assistant{background-color:var(--kin-bubble-assistant)}.bg-kin-bubble-user{background-color:var(--kin-bubble-user)}.bg-kin-text-muted{background-color:var(--kin-text-muted)}.bg-red-600{--tw-bg-opacity: 1;background-color:rgb(220 38 38 / var(--tw-bg-opacity, 1))}.bg-transparent{background-color:transparent}.p-2{padding:.5rem}.p-4{padding:1rem}.px-3{padding-left:.75rem;padding-right:.75rem}.px-3\\.5{padding-left:.875rem;padding-right:.875rem}.px-4{padding-left:1rem;padding-right:1rem}.px-6{padding-left:1.5rem;padding-right:1.5rem}.py-1\\.5{padding-top:.375rem;padding-bottom:.375rem}.py-2{padding-top:.5rem;padding-bottom:.5rem}.py-2\\.5{padding-top:.625rem;padding-bottom:.625rem}.py-3{padding-top:.75rem;padding-bottom:.75rem}.py-6{padding-top:1.5rem;padding-bottom:1.5rem}.pb-1{padding-bottom:.25rem}.pb-4{padding-bottom:1rem}.pb-safe-b{padding-bottom:max(.5rem,calc(env(safe-area-inset-bottom,0px) + .5rem))}.pl-1{padding-left:.25rem}.pl-3\\.5{padding-left:.875rem}.pl-4{padding-left:1rem}.pl-safe-l{padding-left:max(1rem,env(safe-area-inset-left,1rem))}.pr-1\\.5{padding-right:.375rem}.pr-safe-r{padding-right:max(1rem,env(safe-area-inset-right,1rem))}.pt-2{padding-top:.5rem}.pt-2\\.5{padding-top:.625rem}.pt-safe-t{padding-top:max(1rem,env(safe-area-inset-top,1rem))}.text-center{text-align:center}.font-kin{font-family:system-ui,-apple-system,BlinkMacSystemFont,Segoe UI,Roboto,sans-serif}.text-base{font-size:1rem;line-height:1.5rem}.text-kin{font-size:max(14px,1rem);line-height:1.5}.text-sm{font-size:.875rem;line-height:1.25rem}.text-xs{font-size:.75rem;line-height:1rem}.font-medium{font-weight:500}.font-semibold{font-weight:600}.uppercase{text-transform:uppercase}.leading-relaxed{line-height:1.625}.tracking-wide{letter-spacing:.025em}.text-kin-accent{color:var(--kin-accent)}.text-kin-bubble-assistant-text{color:var(--kin-bubble-assistant-text)}.text-kin-bubble-user-text{color:var(--kin-bubble-user-text)}.text-kin-glow-1{color:var(--kin-glow-1)}.text-kin-text{color:var(--kin-text)}.text-kin-text-muted{color:var(--kin-text-muted)}.text-white{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.underline{text-decoration-line:underline}.no-underline{text-decoration-line:none}.underline-offset-2{text-underline-offset:2px}.opacity-0{opacity:0}.opacity-50{opacity:.5}.shadow{--tw-shadow: 0 1px 3px 0 rgb(0 0 0 / .1), 0 1px 2px -1px rgb(0 0 0 / .1);--tw-shadow-colored: 0 1px 3px 0 var(--tw-shadow-color), 0 1px 2px -1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-kin-border{--tw-shadow: 0 0 0 1px var(--kin-border);--tw-shadow-colored: 0 0 0 1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-none{--tw-shadow: 0 0 #0000;--tw-shadow-colored: 0 0 #0000;box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.shadow-kin-border{--tw-shadow-color: var(--kin-border);--tw-shadow: var(--tw-shadow-colored)}.outline-none{outline:2px solid transparent;outline-offset:2px}.ring-1{--tw-ring-offset-shadow: var(--tw-ring-inset) 0 0 0 var(--tw-ring-offset-width) var(--tw-ring-offset-color);--tw-ring-shadow: var(--tw-ring-inset) 0 0 0 calc(1px + var(--tw-ring-offset-width)) var(--tw-ring-color);box-shadow:var(--tw-ring-offset-shadow),var(--tw-ring-shadow),var(--tw-shadow, 0 0 #0000)}.ring-\\[color-mix\\(in_srgb\\,var\\(--kin-accent\\)_30\\%\\,transparent\\)\\]{--tw-ring-color: color-mix(in srgb,var(--kin-accent) 30%,transparent)}.blur{--tw-blur: blur(8px);filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.filter{filter:var(--tw-blur) var(--tw-brightness) var(--tw-contrast) var(--tw-grayscale) var(--tw-hue-rotate) var(--tw-invert) var(--tw-saturate) var(--tw-sepia) var(--tw-drop-shadow)}.transition-\\[background\\,shadow\\,transform\\]{transition-property:background,shadow,transform;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-all{transition-property:all;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.transition-colors{transition-property:color,background-color,border-color,text-decoration-color,fill,stroke;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.duration-150{transition-duration:.15s}.duration-200{transition-duration:.2s}.fr:focus-visible{outline:2px solid var(--kin-accent);outline-offset:2px}.\\[touch-action\\:manipulation\\]{touch-action:manipulation}.\\[will-change\\:transform\\,opacity\\]{will-change:transform,opacity}:host{--kin-bg-base: #0a0a0a;--kin-bg-elevated: #141414;--kin-bg-surface: #1a1a1a;--kin-bg-muted: #262626;--kin-border: rgba(255, 255, 255, .08);--kin-border-subtle: rgba(255, 255, 255, .05);--kin-text: #ffffff;--kin-text-secondary: #a1a1a1;--kin-text-muted: #8a8a8a;--kin-accent: #635bff;--kin-bubble-user: #f5f5f5;--kin-bubble-user-text: #171717;--kin-bubble-assistant: #1a1a1a;--kin-bubble-assistant-text: #ffffff;--kin-glow-1: #ff6b6b;--kin-glow-2: #c850c0;--kin-glow-3: #635bff;--kin-focus-ring: var(--kin-accent);--kin-transition: .2s ease}.kin-launcher-input-wrapper:before,.kin-launcher-input-wrapper:after{content:"";position:absolute;background:linear-gradient(90deg,var(--kin-glow-1),var(--kin-glow-2),var(--kin-glow-3),var(--kin-glow-2),var(--kin-glow-1));background-size:300% 100%;animation:kin-gradient 4s ease infinite;transition:opacity var(--kin-transition);pointer-events:none}.kin-launcher-input-wrapper:before{inset:-1px;border-radius:25px;padding:2px;-webkit-mask:linear-gradient(#fff 0 0) content-box,linear-gradient(#fff 0 0);mask:linear-gradient(#fff 0 0) content-box,linear-gradient(#fff 0 0);-webkit-mask-composite:xor;mask-composite:exclude;opacity:.85}.kin-launcher-input-wrapper:after{inset:-2px;border-radius:26px;filter:blur(6px);opacity:.35;z-index:-1}.kin-launcher-input-wrapper:focus-within:before{opacity:1}.kin-launcher-input-wrapper:focus-within:after{opacity:.5}@keyframes kin-gradient{0%,to{background-position:0% 50%}50%{background-position:100% 50%}}.kin-markdown p{margin:0 0 1em}.kin-markdown p:last-child{margin-bottom:0}.kin-markdown :is(strong,b){font-weight:600}.kin-markdown :is(em,i){font-style:italic}.kin-markdown code{background:rgba(255,255,255,.1);padding:.15em .4em;border-radius:4px;font-family:SF Mono,Monaco,Consolas,monospace;font-size:.875em}.kin-markdown pre{background:rgba(0,0,0,.4);padding:14px 16px;border-radius:8px;overflow-x:auto;margin:1em 0;border:1px solid var(--kin-border)}.kin-markdown pre code{background:none;padding:0;font-size:.85em;line-height:1.5}.kin-markdown :is(ul,ol){margin:.75em 0;padding-left:1.5em}.kin-markdown ul{list-style-type:disc}.kin-markdown ol{list-style-type:decimal}.kin-markdown li{margin:.35em 0}.kin-markdown li::marker{color:var(--kin-text-muted)}.kin-markdown :is(ul,ol) :is(ul,ol){margin:.25em 0}.kin-markdown blockquote{border-left:3px solid var(--kin-accent);margin:1em 0;padding:.5em 0 .5em 1em;color:var(--kin-text-secondary);font-style:italic}.kin-markdown :is(h1,h2,h3,h4){font-weight:600;margin:1.25em 0 .5em;line-height:1.3}.kin-markdown :is(h1,h2,h3):first-child{margin-top:0}.kin-markdown h1{font-size:1.4em}.kin-markdown h2{font-size:1.25em}.kin-markdown h3{font-size:1.1em}.kin-markdown table{width:100%;border-collapse:collapse;margin:1em 0;font-size:.9em}.kin-markdown :is(th,td){padding:.5em .75em;border:1px solid var(--kin-border);text-align:left}.kin-markdown th{background:var(--kin-bg-muted);font-weight:600}.kin-markdown hr{border:none;border-top:1px solid var(--kin-border);margin:1.5em 0}.kin-markdown hr+p{display:flex;flex-wrap:wrap;align-items:center;gap:5px;font-size:.75em;color:var(--kin-text-muted);margin:-1em 0 0;line-height:1.6}.kin-markdown hr+p a{display:inline-flex;align-items:center;padding:1px 8px 2px;background:color-mix(in srgb,var(--kin-accent) 10%,transparent);border:1px solid color-mix(in srgb,var(--kin-accent) 22%,transparent);border-radius:10px;color:var(--kin-accent);text-decoration:none;font-weight:500;white-space:nowrap;transition:background var(--kin-transition),border-color var(--kin-transition)}.kin-markdown hr+p a:hover{background:color-mix(in srgb,var(--kin-accent) 20%,transparent);border-color:var(--kin-accent)}.kin-markdown input[type=checkbox]{margin-right:.5em;accent-color:var(--kin-accent)}.kin-markdown .streamdown-caret{display:inline-block;width:2px;height:1em;background:var(--kin-accent);margin-left:2px;animation:kin-caret 1s ease-in-out infinite;vertical-align:text-bottom}@keyframes kin-caret{0%,to{opacity:1}50%{opacity:0}}@media (prefers-reduced-motion: reduce){*,*:before,*:after{animation-duration:.01ms!important;animation-iteration-count:1!important;transition-duration:.01ms!important}}@media (forced-colors: active){.kin-launcher-input-wrapper:before,.kin-launcher-input-wrapper:after{display:none}.kin-launcher-input-wrapper,.kin-panel,button{border:1px solid ButtonBorder!important}}.placeholder\\:text-kin-text-muted::-moz-placeholder{color:var(--kin-text-muted)}.placeholder\\:text-kin-text-muted::placeholder{color:var(--kin-text-muted)}.before\\:h-px:before{content:var(--tw-content);height:1px}.before\\:flex-1:before{content:var(--tw-content);flex:1 1 0%}.before\\:bg-\\[linear-gradient\\(90deg\\,transparent\\,var\\(--kin-glow-1\\)\\,transparent\\)\\]:before{content:var(--tw-content);background-image:linear-gradient(90deg,transparent,var(--kin-glow-1),transparent)}.before\\:opacity-30:before{content:var(--tw-content);opacity:.3}.before\\:content-\\[\\'\\'\\]:before{--tw-content: "";content:var(--tw-content)}.after\\:h-px:after{content:var(--tw-content);height:1px}.after\\:flex-1:after{content:var(--tw-content);flex:1 1 0%}.after\\:bg-\\[linear-gradient\\(90deg\\,transparent\\,var\\(--kin-glow-1\\)\\,transparent\\)\\]:after{content:var(--tw-content);background-image:linear-gradient(90deg,transparent,var(--kin-glow-1),transparent)}.after\\:opacity-30:after{content:var(--tw-content);opacity:.3}.after\\:content-\\[\\'\\'\\]:after{--tw-content: "";content:var(--tw-content)}.focus-within\\:shadow-\\[0_0_0_2px_var\\(--kin-accent\\)\\]:focus-within{--tw-shadow: 0 0 0 2px var(--kin-accent);--tw-shadow-colored: 0 0 0 2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.hover\\:bg-kin-accent:hover{background-color:var(--kin-accent)}.hover\\:bg-kin-bg-muted:hover{background-color:var(--kin-bg-muted)}.hover\\:text-kin-text:hover{color:var(--kin-text)}.hover\\:text-white:hover{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.hover\\:decoration-2:hover{text-decoration-thickness:2px}.hover\\:opacity-90:hover{opacity:.9}.hover\\:ring-kin-accent:hover{--tw-ring-color: var(--kin-accent)}.focus\\:top-2:focus{top:.5rem}.focus-visible\\:rounded-\\[2px\\]:focus-visible{border-radius:2px}.focus-visible\\:shadow-\\[0_0_0_2px_var\\(--kin-focus-ring\\)\\]:focus-visible{--tw-shadow: 0 0 0 2px var(--kin-focus-ring);--tw-shadow-colored: 0 0 0 2px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.active\\:scale-95:active{--tw-scale-x: .95;--tw-scale-y: .95;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.enabled\\:bg-kin-accent:enabled{background-color:var(--kin-accent)}.enabled\\:text-white:enabled{--tw-text-opacity: 1;color:rgb(255 255 255 / var(--tw-text-opacity, 1))}.enabled\\:hover\\:scale-105:hover:enabled{--tw-scale-x: 1.05;--tw-scale-y: 1.05;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}.disabled\\:cursor-not-allowed:disabled{cursor:not-allowed}.disabled\\:opacity-50:disabled{opacity:.5}@media (min-width: 640px){.sm\\:inset-x-auto{left:auto;right:auto}.sm\\:bottom-6{bottom:1.5rem}.sm\\:left-1\\/2{left:50%}.sm\\:top-auto{top:auto}.sm\\:size-8{width:2rem;height:2rem}.sm\\:size-9{width:2.25rem;height:2.25rem}.sm\\:h-auto{height:auto}.sm\\:max-h-\\[90vh\\]{max-height:90vh}.sm\\:min-h-\\[50vh\\]{min-height:50vh}.sm\\:w-96{width:24rem}.sm\\:w-auto{width:auto}.sm\\:w-kin-panel{width:450px}.sm\\:max-w-\\[calc\\(100vw-2rem\\)\\]{max-width:calc(100vw - 2rem)}.sm\\:max-w-\\[calc\\(100vw-3rem\\)\\]{max-width:calc(100vw - 3rem)}.sm\\:-translate-x-1\\/2{--tw-translate-x: -50%;transform:translate(var(--tw-translate-x),var(--tw-translate-y)) rotate(var(--tw-rotate)) skew(var(--tw-skew-x)) skewY(var(--tw-skew-y)) scaleX(var(--tw-scale-x)) scaleY(var(--tw-scale-y))}@keyframes kin-slide-up{0%{opacity:0;transform:translateY(8px)}to{opacity:1;transform:translateY(0)}}.sm\\:animate-kin-panel-in{animation:kin-slide-up .35s cubic-bezier(.32,.72,0,1) both}.sm\\:items-center{align-items:center}.sm\\:gap-3{gap:.75rem}.sm\\:gap-4{gap:1rem}.sm\\:overflow-visible{overflow:visible}.sm\\:overscroll-auto{overscroll-behavior:auto}.sm\\:rounded-2xl{border-radius:1rem}.sm\\:rounded-3xl{border-radius:1.5rem}.sm\\:border{border-width:1px}.sm\\:border-0{border-width:0px}.sm\\:border-kin-border{border-color:var(--kin-border)}.sm\\:bg-kin-bg-elevated{background-color:var(--kin-bg-elevated)}.sm\\:bg-transparent{background-color:transparent}.sm\\:p-4{padding:1rem}.sm\\:px-0{padding-left:0;padding-right:0}.sm\\:px-4{padding-left:1rem;padding-right:1rem}.sm\\:py-1{padding-top:.25rem;padding-bottom:.25rem}.sm\\:py-3{padding-top:.75rem;padding-bottom:.75rem}.sm\\:pb-0{padding-bottom:0}.sm\\:pt-0{padding-top:0}.sm\\:pt-2\\.5{padding-top:.625rem}.sm\\:text-sm{font-size:.875rem;line-height:1.25rem}.sm\\:font-medium{font-weight:500}.sm\\:shadow-kin-border{--tw-shadow: 0 0 0 1px var(--kin-border);--tw-shadow-colored: 0 0 0 1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.sm\\:shadow-kin-panel{--tw-shadow: 0 4px 24px rgba(0, 0, 0, .12), 0 0 0 1px var(--kin-border);--tw-shadow-colored: 0 4px 24px var(--tw-shadow-color), 0 0 0 1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow)}.sm\\:shadow-kin-border{--tw-shadow-color: var(--kin-border);--tw-shadow: var(--tw-shadow-colored)}.sm\\:transition-\\[width\\]{transition-property:width;transition-timing-function:cubic-bezier(.4,0,.2,1);transition-duration:.15s}.sm\\:duration-300{transition-duration:.3s}.sm\\:ease-kin-open{transition-timing-function:cubic-bezier(.32,.72,0,1)}.sm\\:\\[touch-action\\:auto\\]{touch-action:auto}.sm\\:focus-within\\:w-kin-panel:focus-within{width:450px}.sm\\:focus-within\\:shadow-kin-border:focus-within{--tw-shadow: 0 0 0 1px var(--kin-border);--tw-shadow-colored: 0 0 0 1px var(--tw-shadow-color);box-shadow:var(--tw-ring-offset-shadow, 0 0 #0000),var(--tw-ring-shadow, 0 0 #0000),var(--tw-shadow);--tw-shadow-color: var(--kin-border);--tw-shadow: var(--tw-shadow-colored)}.sm\\:enabled\\:bg-kin-text:enabled{background-color:var(--kin-text)}.sm\\:enabled\\:text-kin-bg-base:enabled{color:var(--kin-bg-base)}}.\\[\\&\\:\\:-webkit-scrollbar-thumb\\]\\:rounded-\\[3px\\]::-webkit-scrollbar-thumb{border-radius:3px}.\\[\\&\\:\\:-webkit-scrollbar-thumb\\]\\:bg-kin-bg-muted::-webkit-scrollbar-thumb{background-color:var(--kin-bg-muted)}.\\[\\&\\:\\:-webkit-scrollbar-track\\]\\:bg-transparent::-webkit-scrollbar-track{background-color:transparent}.\\[\\&\\:\\:-webkit-scrollbar\\]\\:w-1\\.5::-webkit-scrollbar{width:.375rem}.\\[\\&\\:\\:after\\]\\:hidden:after{display:none}@media (min-width: 640px){.sm\\:\\[\\&\\:\\:after\\]\\:block:after{display:block}}.\\[\\&\\:\\:before\\]\\:hidden:before{display:none}@media (min-width: 640px){.sm\\:\\[\\&\\:\\:before\\]\\:block:before{display:block}}.\\[\\&\\>svg\\]\\:size-4>svg{width:1rem;height:1rem}
|
|
121
|
+
`,Y0=["gray","mauve","slate","sage","olive","sand","tomato","red","ruby","crimson","pink","plum","purple","violet","iris","indigo","blue","cyan","teal","jade","green","grass","brown","orange","sky","mint","lime","yellow","amber","bronze","gold"],j0={gray:[[.178,0,null],[.213,0,null],[.254,0,null],[.283,0,null],[.313,0,null],[.349,0,null],[.402,0,null],[.488,0,null],[.538,0,null],[.584,0,null],[.77,0,null],[.949,0,null]],mauve:[[.18,.004,307.8],[.215,.004,307.8],[.255,.006,306.5],[.284,.008,307.8],[.314,.009,306.9],[.35,.01,304],[.402,.012,304.4],[.492,.016,300.7],[.54,.017,294],[.586,.017,295.4],[.77,.014,296.6],[.949,.003,286.3]],slate:[[.179,.004,286],[.213,.004,264.4],[.253,.006,261.2],[.283,.007,259.5],[.311,.008,259.7],[.346,.01,256.5],[.398,.012,253.8],[.49,.016,247.6],[.537,.015,261.1],[.583,.014,263.3],[.768,.01,261.3],[.949,.003,264.6]],sage:[[.179,.004,167.4],[.211,.004,160.2],[.251,.004,164.2],[.281,.005,164.9],[.311,.005,167.4],[.347,.006,167.4],[.399,.008,167.4],[.488,.009,169.8],[.533,.018,170.8],[.579,.016,170.5],[.766,.01,167.5],[.947,.002,167.7]],olive:[[.18,.004,128.3],[.212,.004,128.3],[.252,.005,129],[.281,.006,131.4],[.31,.007,131.4],[.346,.008,134.4],[.399,.01,136],[.488,.012,140.8],[.535,.018,139.6],[.581,.016,140.1],[.766,.013,139.5],[.947,.003,144.8]],sand:[[.178,.002,106.6],[.213,.002,106.6],[.253,.003,106.6],[.283,.004,99],[.312,.004,100.7],[.349,.006,102.2],[.401,.007,96.1],[.49,.01,91.7],[.535,.011,94.1],[.581,.011,94],[.767,.009,97.4],[.948,.003,106.4]],tomato:[[.187,.012,19.6],[.208,.017,32],[.254,.054,26.9],[.291,.087,28.2],[.331,.097,28.7],[.38,.099,30],[.447,.107,31.5],[.538,.13,32.9],[.627,.194,33.3],[.665,.179,34.1],[.784,.164,36],[.899,.047,31.1]],red:[[.188,.013,19.4],[.205,.022,14.7],[.25,.064,13.1],[.289,.096,14.3],[.332,.107,15.5],[.383,.111,16.9],[.451,.121,18.9],[.544,.147,21.4],[.625,.193,23],[.665,.177,23.1],[.784,.162,22.3],[.902,.053,6.14]],ruby:[[.189,.014,2.9],[.208,.016,5.29],[.254,.06,6.54],[.292,.089,5.5],[.333,.1,6.4],[.382,.105,7.59],[.448,.117,9.02],[.544,.145,11.1],[.628,.195,13.2],[.664,.179,13.7],[.786,.161,17],[.905,.053,355.8]],crimson:[[.189,.014,354.2],[.207,.022,352.9],[.256,.059,353.9],[.293,.094,354.1],[.333,.104,354.7],[.382,.109,355.5],[.45,.12,356.7],[.542,.148,358.3],[.634,.213,1.3],[.664,.197,1.95],[.787,.167,6.72],[.909,.054,346.7]],pink:[[.191,.017,334.9],[.207,.031,338.2],[.261,.061,337.5],[.299,.098,340.1],[.338,.104,340.6],[.389,.107,341.6],[.459,.119,342.6],[.545,.145,344.1],[.617,.208,346.1],[.65,.197,346.2],[.789,.19,350.7],[.905,.059,343.2]],plum:[[.19,.017,327],[.21,.031,327.7],[.266,.062,326.7],[.307,.088,325.3],[.343,.095,324.6],[.389,.097,324.2],[.456,.106,323.4],[.545,.128,322.2],[.579,.188,322.1],[.616,.182,322.1],[.786,.154,322.1],[.906,.055,325.8]],purple:[[.192,.022,316],[.213,.031,314.3],[.266,.062,312],[.308,.083,310.7],[.344,.091,310.1],[.388,.097,309.7],[.45,.108,308.7],[.541,.133,307.1],[.555,.183,305.9],[.596,.177,306.3],[.785,.156,307.9],[.911,.049,310.9]],violet:[[.191,.026,290.5],[.211,.032,299.5],[.271,.066,293.9],[.312,.093,291.7],[.348,.099,291.4],[.39,.102,291.8],[.445,.111,291.6],[.516,.131,290.2],[.542,.179,288.1],[.588,.17,289.7],[.778,.137,293.6],[.912,.045,292.6]],iris:[[.193,.022,284.2],[.209,.029,286.5],[.273,.069,278.6],[.319,.102,276.1],[.358,.109,277.4],[.399,.112,279.6],[.448,.12,280.8],[.507,.138,281.1],[.54,.184,278.3],[.587,.172,281.2],[.776,.131,286.6],[.914,.042,287]],indigo:[[.191,.025,276.7],[.209,.03,276],[.272,.069,267.8],[.319,.093,267],[.362,.105,267.5],[.404,.111,268.3],[.45,.12,268.8],[.503,.137,268.4],[.544,.191,267.1],[.59,.176,269.2],[.777,.123,273.3],[.911,.043,270]],blue:[[.193,.026,256.8],[.213,.03,258.8],[.274,.067,254],[.317,.1,248.3],[.365,.108,249.7],[.416,.112,251.7],[.475,.121,252.8],[.541,.14,253.2],[.649,.193,251.8],[.689,.17,251.5],[.768,.135,248.8],[.907,.051,238.3]],cyan:[[.191,.017,219.9],[.214,.018,225.4],[.272,.044,222.5],[.315,.063,222.1],[.362,.07,221.5],[.414,.075,221.7],[.478,.083,221.4],[.558,.098,220.7],[.661,.122,221.5],[.698,.12,219.1],[.786,.115,213.4],[.909,.057,211.7]],teal:[[.189,.012,184.5],[.217,.017,189.3],[.274,.038,186.3],[.317,.055,187],[.363,.06,186.5],[.414,.065,185.4],[.473,.074,184.5],[.539,.087,183.5],[.649,.113,182],[.687,.123,180.3],[.789,.147,175.7],[.905,.072,175.3]],jade:[[.188,.014,166.3],[.216,.018,166.1],[.272,.042,166.8],[.316,.057,168],[.362,.064,168.5],[.411,.068,169.7],[.468,.075,170.6],[.537,.088,171.8],[.642,.115,170.8],[.678,.125,169.9],[.785,.156,167.1],[.903,.078,167]],green:[[.189,.013,163.3],[.213,.016,162.2],[.271,.039,162.7],[.318,.057,161.5],[.365,.066,161.1],[.413,.073,160.7],[.467,.083,159.9],[.527,.096,159.2],[.64,.133,157.8],[.676,.141,157.6],[.78,.166,157.2],[.905,.083,158.3]],grass:[[.188,.014,155.8],[.211,.014,151.5],[.267,.03,150.7],[.319,.052,150.4],[.367,.062,149.9],[.416,.072,149.3],[.468,.084,148.9],[.524,.097,148.2],[.652,.147,147.4],[.69,.145,147.6],[.78,.142,148.5],[.911,.078,144.9]],brown:[[.178,.005,81.5],[.213,.007,51.6],[.254,.013,53.5],[.288,.018,55.4],[.325,.024,55.9],[.37,.032,57.7],[.429,.041,59.8],[.509,.053,62.2],[.633,.078,60.8],[.674,.075,61.5],[.798,.063,62.5],[.918,.036,75.7]],bronze:[[.181,.005,41.6],[.215,.005,41.5],[.255,.008,42.7],[.291,.01,45.5],[.329,.013,43.3],[.374,.016,44.3],[.43,.02,44.8],[.499,.024,45.2],[.627,.046,44.3],[.669,.045,44.3],[.792,.043,44.5],[.915,.017,50.3]],gold:[[.182,.002,106.6],[.216,.006,92.5],[.255,.008,88.3],[.291,.01,86.8],[.329,.011,83.7],[.374,.014,82.4],[.429,.016,80.9],[.498,.02,79.5],[.621,.049,78.1],[.662,.047,77.2],[.794,.041,77.2],[.915,.014,77.4]],sky:[[.19,.024,257.1],[.216,.029,258.5],[.271,.054,251.9],[.322,.07,247.8],[.372,.079,245.8],[.427,.087,243.6],[.488,.098,240.7],[.557,.114,237.2],[.861,.103,217.8],[.908,.073,214.9],[.793,.099,231.7],[.934,.053,214.4]],mint:[[.188,.012,192.3],[.21,.017,196.6],[.269,.039,192.5],[.313,.058,191.6],[.359,.063,188.9],[.41,.067,186.3],[.471,.073,183.4],[.54,.085,179.6],[.87,.1,178],[.916,.08,179.4],[.795,.118,176.4],[.93,.057,168.5]],lime:[[.18,.014,120.3],[.208,.019,129],[.266,.034,132.2],[.317,.047,131.8],[.363,.058,131.6],[.412,.069,131.4],[.464,.08,131.2],[.524,.095,130.9],[.888,.175,126.1],[.942,.175,123.7],[.868,.156,124.8],[.946,.082,122.6]],yellow:[[.181,.013,86],[.209,.017,92.1],[.259,.047,90.3],[.293,.069,94.2],[.333,.079,94.6],[.384,.077,93.3],[.452,.081,91.5],[.535,.095,89.9],[.927,.209,102.1],[.971,.182,109.4],[.9,.166,101.6],[.941,.075,101]],amber:[[.184,.013,77.3],[.212,.018,78.7],[.258,.044,74.6],[.296,.071,76.2],[.337,.081,76.4],[.387,.078,75.1],[.453,.082,74.5],[.536,.096,73.6],[.856,.178,81.4],[.902,.206,97],[.871,.175,85.1],[.935,.072,86]],orange:[[.186,.012,53.7],[.209,.019,67.4],[.257,.045,59.5],[.293,.08,58.6],[.335,.087,58.1],[.386,.087,55.2],[.453,.095,53.1],[.541,.116,49.7],[.689,.191,44.8],[.741,.199,46.3],[.799,.163,50.8],[.925,.052,66.2]]},V0={gray:[[.991,0,null],[.981,0,null],[.953,0,null],[.93,0,null],[.908,0,null],[.884,0,null],[.851,0,null],[.791,0,null],[.643,0,null],[.609,0,null],[.503,0,null],[.243,0,null]],mauve:[[.992,.002,321.1],[.983,.003,311.2],[.956,.006,314.2],[.932,.008,310],[.909,.01,306.6],[.886,.012,304],[.854,.014,300.6],[.794,.019,293.5],[.646,.019,292.6],[.611,.018,293.1],[.505,.016,296.1],[.245,.013,298]],slate:[[.991,.001,286.4],[.982,.003,286.3],[.956,.004,281.9],[.931,.006,283],[.91,.008,283.6],[.888,.009,281.8],[.853,.012,280.8],[.794,.016,278.1],[.646,.016,277.8],[.61,.016,273.2],[.503,.014,263.4],[.241,.01,249.5]],sage:[[.992,.003,160.4],[.981,.003,171.2],[.955,.003,170.4],[.931,.003,170.4],[.909,.004,167.7],[.885,.004,167.7],[.851,.004,169.9],[.792,.005,169.5],[.639,.01,172.4],[.605,.01,172.8],[.501,.008,175.9],[.24,.012,166.8]],olive:[[.993,.002,149.1],[.983,.003,144.8],[.956,.004,141.1],[.932,.004,142.1],[.909,.005,139.3],[.886,.006,141.1],[.852,.006,141.1],[.792,.007,140.6],[.64,.011,136.5],[.605,.012,136.5],[.5,.011,139.9],[.242,.011,138.2]],sand:[[.994,.001,106.4],[.982,.001,106.4],[.956,.002,97.6],[.932,.003,100.6],[.91,.004,95.9],[.886,.005,98.3],[.853,.006,96.6],[.792,.008,96.5],[.641,.01,106.7],[.606,.01,106.7],[.498,.008,106.7],[.243,.008,96.3]],tomato:[[.994,.003,22.8],[.984,.007,31],[.954,.022,30.9],[.926,.047,31.8],[.892,.063,31.5],[.852,.077,32],[.803,.094,32.2],[.741,.118,32.1],[.627,.194,33.3],[.604,.195,33.3],[.567,.198,32.8],[.346,.08,30.5]],red:[[.994,.003,22.8],[.983,.008,16],[.956,.021,16.2],[.928,.047,16.7],[.896,.062,17.3],[.857,.075,17.9],[.807,.089,18.4],[.745,.113,19.1],[.625,.193,23],[.6,.195,23.9],[.557,.198,25.1],[.339,.109,16.7]],ruby:[[.994,.003,356.3],[.983,.008,8.41],[.954,.022,8.56],[.928,.042,8.46],[.896,.055,8.16],[.858,.066,7.84],[.81,.08,7.49],[.749,.101,6.86],[.628,.195,13.2],[.601,.196,13.4],[.549,.199,13.9],[.341,.11,10]],crimson:[[.994,.003,356.3],[.982,.008,357.2],[.954,.026,356.3],[.925,.041,356.3],[.893,.054,355.8],[.855,.065,355.6],[.808,.078,354.8],[.75,.099,354.1],[.634,.213,1.3],[.608,.211,2.36],[.552,.207,4.49],[.341,.113,356.8]],pink:[[.994,.004,336.3],[.983,.009,340],[.954,.027,340.6],[.925,.042,340.7],[.893,.054,340.9],[.855,.067,340.9],[.809,.083,341.2],[.752,.107,341.6],[.617,.208,346.1],[.596,.207,346.5],[.557,.206,347.3],[.35,.129,345.5]],plum:[[.993,.005,316.9],[.983,.009,326],[.957,.027,325.5],[.929,.044,324.9],[.898,.057,324.4],[.86,.072,323.9],[.809,.091,323.1],[.742,.12,321.9],[.579,.188,322.1],[.553,.181,322.1],[.521,.173,322],[.338,.125,321.4]],purple:[[.993,.004,325.4],[.982,.009,313.1],[.959,.024,313.3],[.933,.039,312.1],[.901,.054,311.6],[.86,.071,311],[.804,.093,309.9],[.733,.123,308],[.555,.183,305.9],[.524,.176,305.7],[.516,.174,305.7],[.322,.11,303.8]],violet:[[.992,.003,308],[.983,.009,295],[.963,.019,296.6],[.934,.039,295.4],[.904,.057,294.1],[.864,.072,293.9],[.806,.09,293.5],[.729,.119,292.4],[.542,.179,288.1],[.511,.177,287.6],[.508,.159,288.6],[.313,.098,286.8]],iris:[[.994,.003,286.4],[.981,.009,284.1],[.961,.018,283.8],[.935,.035,283.4],[.904,.053,283.8],[.865,.07,283.1],[.808,.088,282.9],[.729,.118,281.5],[.54,.184,278.3],[.509,.186,277.5],[.51,.173,279.7],[.315,.099,277.4]],indigo:[[.994,.001,286.4],[.983,.008,271.4],[.961,.017,268.5],[.935,.034,268.5],[.903,.051,270],[.863,.071,271.5],[.807,.087,271.4],[.73,.113,270.5],[.544,.191,267.1],[.511,.195,266.5],[.51,.173,267.1],[.313,.086,268.6]],blue:[[.993,.003,247.6],[.982,.01,243.3],[.96,.02,236.7],[.937,.037,239],[.906,.053,242.8],[.864,.069,243.2],[.809,.088,243.3],[.735,.121,243],[.649,.193,251.8],[.621,.184,251.9],[.558,.189,253],[.324,.097,259]],cyan:[[.992,.004,219.2],[.98,.009,202.9],[.958,.026,203.6],[.932,.041,204.7],[.9,.054,206.5],[.859,.066,207.7],[.805,.082,209.6],[.727,.11,211.7],[.661,.122,221.5],[.627,.114,221.3],[.54,.127,223.7],[.332,.053,218.6]],teal:[[.994,.005,177.5],[.981,.009,179],[.961,.027,180.3],[.935,.042,180.2],[.9,.054,180.5],[.856,.064,181.4],[.797,.076,182.2],[.721,.097,183.5],[.649,.113,182],[.619,.11,181.2],[.53,.124,179],[.327,.05,185]],jade:[[.995,.004,172.6],[.982,.009,160.3],[.96,.022,161.9],[.934,.034,163.5],[.902,.046,164.8],[.859,.059,166.9],[.8,.077,169.5],[.721,.103,173.4],[.642,.115,170.8],[.613,.11,170.6],[.529,.127,167.2],[.326,.041,169.8]],green:[[.994,.004,159.1],[.982,.009,155.3],[.959,.023,156.4],[.933,.036,156.6],[.9,.05,157.2],[.857,.065,157.9],[.798,.084,159],[.714,.112,160.6],[.64,.133,157.8],[.611,.126,158.3],[.529,.133,158.3],[.322,.047,164.6]],grass:[[.994,.005,146.4],[.982,.009,145.9],[.961,.023,145.3],[.934,.037,146.2],[.901,.053,146.4],[.858,.071,146.8],[.798,.095,147.5],[.716,.13,148.3],[.652,.147,147.4],[.614,.142,147.3],[.527,.13,147.2],[.327,.053,148.6]],brown:[[.994,.002,63.2],[.983,.006,65.7],[.954,.013,67.8],[.926,.02,66.9],[.897,.029,65.8],[.862,.039,65.5],[.815,.053,64.2],[.747,.072,62.4],[.633,.078,60.8],[.597,.072,59.3],[.512,.058,55.5],[.332,.018,47]],bronze:[[.992,.001,15.9],[.981,.007,43],[.953,.01,44.3],[.925,.014,43.6],[.895,.018,42.6],[.86,.023,43.4],[.811,.03,41.9],[.742,.039,41.2],[.627,.046,44.3],[.588,.045,42.4],[.51,.044,38.4],[.329,.029,35.2]],gold:[[.994,.001,106.4],[.981,.009,97.3],[.953,.012,94.7],[.926,.015,93.2],[.896,.019,90.7],[.86,.025,88.4],[.81,.032,83.4],[.739,.042,78.2],[.621,.049,78.1],[.588,.047,77.4],[.504,.039,78.1],[.332,.019,81.7]],sky:[[.993,.005,211.9],[.98,.01,217.7],[.961,.024,219.6],[.936,.036,220.4],[.903,.047,221.4],[.861,.058,222.9],[.806,.072,225.7],[.729,.096,228],[.861,.103,217.8],[.838,.104,219.6],[.526,.108,232.5],[.351,.057,241.6]],mint:[[.993,.005,183.7],[.982,.01,178.7],[.96,.03,179.6],[.933,.047,179],[.899,.061,178.7],[.856,.072,178.7],[.798,.085,178.2],[.722,.107,177.7],[.87,.1,178],[.841,.1,177.8],[.512,.095,176],[.35,.051,181.4]],lime:[[.992,.004,120.7],[.982,.01,116.7],[.959,.043,119.1],[.932,.069,120.4],[.897,.087,121.8],[.853,.099,123.4],[.795,.111,125.3],[.724,.135,128.1],[.888,.175,126.1],[.859,.188,126.7],[.544,.111,128.6],[.354,.057,121.2]],yellow:[[.993,.005,106.5],[.988,.025,102.9],[.974,.084,104.4],[.953,.117,101.7],[.925,.141,98.2],[.881,.134,95.4],[.836,.12,92.8],[.766,.137,89.8],[.927,.209,102.1],[.897,.185,97.5],[.574,.136,81.7],[.358,.046,86.6]],amber:[[.994,.003,84.6],[.986,.024,100.3],[.969,.069,100.4],[.945,.104,98.2],[.918,.133,98.4],[.881,.124,93.2],[.827,.122,86.2],[.758,.14,76.7],[.856,.178,81.4],[.831,.168,80.9],[.569,.144,67.3],[.352,.049,53.7]],orange:[[.992,.003,40.7],[.979,.015,70.8],[.958,.037,78.1],[.92,.081,74.2],[.89,.107,70.8],[.857,.11,64.4],[.805,.113,59.9],[.745,.132,54.8],[.689,.191,44.8],[.662,.194,43.5],[.592,.186,47],[.35,.069,40.8]]},vs=e=>(e/=255,e<=.04045?e/12.92:((e+.055)/1.055)**2.4),d6=(e,t,n)=>{const r=.4122214708*e+.5363325363*t+.0514459929*n,i=.2119034982*e+.6806995451*t+.1073969566*n,a=.0883024619*e+.2817188376*t+.6299787005*n,s=Math.cbrt(r),o=Math.cbrt(i),u=Math.cbrt(a),c=.2104542553*s+.793617785*o-.0040720468*u,f=1.9779984951*s-2.428592205*o+.4505937099*u,d=.0259040371*s+.7827717662*o-.808675766*u;return[c,f,d]},f6=([e,t,n])=>{const r=Math.sqrt(t*t+n*n),i=Math.atan2(n,t)*180/Math.PI;return[e,r,(i+360)%360]},h6=e=>{const t=e.replace("#",""),n=parseInt(t.length===3?t.replace(/./g,s=>s+s):t,16),r=vs(n>>16&255),i=vs(n>>8&255),a=vs(n&255);return f6(d6(r,i,a))},q0=["gray","mauve","slate","sage","olive","sand"];function Ni(e,t){return Object.fromEntries(t.map(n=>[n,e[n]]))}Ni(V0,Y0),Ni(j0,Y0),Ni(V0,q0),Ni(j0,q0);const p6={light:{1:[98.8,.015],2:[97.8,.018],3:[95.8,.025],4:[92,.04],5:[89,.05],6:[85,.07],7:[80.5,.08],8:[74,.11],9:[60,.22],10:[56,.23],11:[50,.19],12:[25,.18]},dark:{1:[19,.015],2:[21,.018],3:[25.5,.055],4:[29.3,.084],5:[33.5,.098],6:[39.05,.107],7:[45,.11],8:[55,.13],9:[60,.22],10:[67,.18],11:[79.3,.12],12:[95,.04]}},m6={light:{1:[99,.005],2:[97.5,.005],3:[95,.006],4:[92,.006],5:[88,.005],6:[83,.004],7:[76,.003],8:[65,.003],9:[55,.004],10:[45,.005],11:[35,.006],12:[20,.008]},dark:{1:[14,.008],2:[17,.008],3:[21,.01],4:[25,.01],5:[30,.008],6:[36,.006],7:[44,.005],8:[54,.004],9:[66,.003],10:[76,.004],11:[87,.005],12:[96,.006]}};function g6(e){const[t,n,r]=h6(e);return{l:t*100,c:n,h:r??0}}const zt=(e,t,n)=>`oklch(${e}% ${t} ${n})`;function b6(e){const{accentColor:t,mode:n}=e,r=g6(t),i=p6[n],a=m6[n],s=30,o=r.c/.22,u=m=>{const _=i[m];if(!_)return zt(60,.22,r.h);const[w,y]=_;return m==="9"?zt(r.l,r.c,r.h):zt(w,y*o,r.h)},c=m=>{const _=a[m];if(!_)return zt(50,.005,s);const[w,y]=_;return zt(w,y,s)},f=zt(r.l,r.c,r.h),d=zt(r.l*.9,r.c*.9,(r.h+20)%360),h=zt(r.l*.8,r.c*.8,(r.h+40)%360),p=n==="light"?{"--kin-bg-base":c("1"),"--kin-bg-elevated":c("2"),"--kin-bg-surface":c("3"),"--kin-bg-muted":c("4"),"--kin-border":`oklch(${a[6]?.[0]??83}% ${a[6]?.[1]??.004} ${s} / 0.4)`,"--kin-border-subtle":`oklch(${a[5]?.[0]??88}% ${a[5]?.[1]??.005} ${s} / 0.25)`,"--kin-text":c("12"),"--kin-text-secondary":c("10"),"--kin-text-muted":c("8"),"--kin-accent":u("9"),"--kin-bubble-user":u("9"),"--kin-bubble-user-text":"oklch(100% 0 0)","--kin-bubble-assistant":c("2"),"--kin-bubble-assistant-text":c("12"),"--kin-glow-1":f,"--kin-glow-2":d,"--kin-glow-3":h}:{"--kin-bg-base":c("1"),"--kin-bg-elevated":c("2"),"--kin-bg-surface":c("3"),"--kin-bg-muted":c("4"),"--kin-border":`oklch(${a[6]?.[0]??83}% ${a[6]?.[1]??.004} ${s} / 0.4)`,"--kin-border-subtle":`oklch(${a[5]?.[0]??88}% ${a[5]?.[1]??.005} ${s} / 0.25)`,"--kin-text":c("12"),"--kin-text-secondary":c("11"),"--kin-text-muted":c("9"),"--kin-accent":u("9"),"--kin-bubble-user":c("12"),"--kin-bubble-user-text":c("1"),"--kin-bubble-assistant":c("3"),"--kin-bubble-assistant-text":c("12"),"--kin-glow-1":f,"--kin-glow-2":d,"--kin-glow-3":h};return Object.entries(p).map(([m,_])=>`${m}: ${_};`).join(`
|
|
122
|
+
`)}const E6={accentColor:"#FF4D00",mode:"light"},T6="wss://agents.inploi.com",_6=({serviceUrl:e=T6,theme:t=E6,starterPrompts:n=[],mode:r="floating",container:i})=>Vt(({logger:a,publishableKey:s})=>{if(!s)throw new Error("Kin plugin requires a publishableKey. Pass it to initialiseSdk().");let o=!1,u=null,c=t,f=null,d=!1,h=null,p=null,m=!1;const _=r==="embedded",w=()=>{if(i)if(typeof i=="string"){const H=document.querySelector(i);if(H instanceof HTMLElement)return p=H,m=!1,H}else return p=i,m=!1,i;const U=document.getElementById("inploi-kin-root");if(U)return p=U,m=!1,U;const I=document.createElement("div");return I.id="inploi-kin-root",_&&(I.className="kin-embedded"),document.body.appendChild(I),p=I,m=!0,I},y=U=>{const I=b6(U);let H=`${c6}
|
|
116
123
|
|
|
117
124
|
/* Theme overrides */
|
|
118
125
|
:host {
|
|
119
|
-
${
|
|
126
|
+
${I}
|
|
120
127
|
}`;return _&&(H+=`
|
|
121
128
|
/* Embedded mode overrides */
|
|
122
129
|
.kin-widget {
|
|
@@ -143,5 +150,4 @@ ${L}
|
|
|
143
150
|
transform: none !important;
|
|
144
151
|
animation: none !important;
|
|
145
152
|
}
|
|
146
|
-
`),H},
|
|
147
|
-
`).map(f=>[{content:f,color:"inherit",bgColor:"transparent",htmlStyle:{},offset:0}])}),[e]),[u,c]=le(o);return we(()=>{if(!s){c(o);return}let f=s.highlight({code:e,language:t,themes:a},d=>{c(d)});if(f){c(f);return}c(o)},[e,t,a,s,o]),b(Id.Provider,{value:{code:e},children:b(c6,{language:t,children:[b(d6,{language:t,children:r}),b(l6,{className:n,language:t,result:u,...i})]})})};const h6=Object.freeze(Object.defineProperty({__proto__:null,CodeBlock:f6},Symbol.toStringTag,{value:"Module"})),p6=Object.freeze(Object.defineProperty({__proto__:null,Mermaid:f0},Symbol.toStringTag,{value:"Module"}))})();
|
|
153
|
+
`),H},S=()=>{if(typeof window>"u")return;const U=w(),I=U.shadowRoot||U.attachShadow({mode:"open"});Lr(ft($e,{},[ft("style",{id:"kin-styles"},y(c)),ft(l6,{starterPrompts:n,embedded:_,onSendMessage:H=>{u&&u.sendMessage(H)},onOpen:()=>{P(),D()},onClose:()=>{_||(Y.isOpen.value=!1)},onConnect:()=>{P()},onClearData:()=>{u&&u.clearData()},onUploadFile:async(H,N)=>{if(!u){Y.setUploadState("error",H.name,"Not connected");return}Y.setUploadState("uploading",H.name);const $=await u.uploadFile(H,N);$.success||Y.setUploadState("error",H.name,$.error)}})]),I)},C=()=>{o||(f=Ps(),S(),o=!0)},D=()=>{Y.isOpen.value=!0,Y.clearUnreadMessages()},P=()=>{if(u)return;Y.connectionState.value="connecting",f||(f=Ps());const U=`${e}/agent/candidate/${f}?key=${s}`;u=r6({url:U,onMessage:I=>{switch(I.type){case"authenticated":a.info(`Authenticated with ${I.company}`),Y.connectionState.value="connected";break;case"history":I.messages&&I.messages.length>0&&(a.info(`Loaded ${I.messages.length} messages from server`),Y.setMessages(I.messages));break;case"response_start":Y.isStreaming.value=!0,Y.addMessage({role:"assistant",content:""});break;case"response_chunk":Y.appendToLastMessage(I.content||"");break;case"response_end":Y.isStreaming.value=!1,Y.syncToOtherTabs(),Y.isOpen.value||Y.setHasUnreadMessages(!0);break;case"quick_replies":I.options&&I.options.length>=2&&Y.setQuickReplies(I.options);break;case"data_cleared":a.info("User data cleared"),Y.clearMessages(),Y.addMessage({role:"system",content:"Your conversation data has been cleared."});break;case"guardrail_block":Y.isStreaming.value=!1,a.warn("Content blocked by safety policy"),Y.addMessage({role:"system",content:I.content||"I'm not able to help with that request."}),Y.syncToOtherTabs();break;case"upload_received":a.info(`File upload received: ${I.fileName}`),Y.setUploadState("processing",I.fileName);break;case"file_processing":a.info(`Processing file: ${I.fileName}`),Y.setUploadState("processing",I.fileName);break;case"file_processed":I.status==="success"?(a.info(`File processed successfully: ${I.fileName}`),Y.setUploadState("success",I.fileName),setTimeout(()=>Y.resetUploadState(),2e3)):(a.error(`File processing failed: ${I.error}`),Y.setUploadState("error",I.fileName,I.error));break;case"error":Y.isStreaming.value=!1,Y.uploadState.value!=="idle"&&Y.setUploadState("error",void 0,I.content),a.error("Kin error:",I.content),Y.addMessage({role:"assistant",content:I.content||"An error occurred"});break}},onOpen:()=>{a.info("WebSocket opened, awaiting authentication...")},onClose:()=>{a.info("Disconnected from Kin service"),Y.connectionState.value="disconnected",Y.isStreaming.value=!1;const I=d;u=null,d=!1,!I&&Y.isOpen.value&&(a.info("Attempting to reconnect..."),h=setTimeout(()=>{h=null,P()},1e3))},onError:I=>{a.error("Kin connection error:",I),Y.connectionState.value="error",Y.isStreaming.value=!1}})},A=()=>{h&&(clearTimeout(h),h=null),u&&(d=!0,u.disconnect(),u=null)};return{prepare:()=>{typeof window>"u"||o||(C(),P(),a.info("Kin plugin prepared"))},open:()=>{typeof window>"u"||(C(),P(),D(),a.info("Kin opened"))},close:()=>{typeof window>"u"||(Y.isOpen.value=!1,a.info("Kin closed"))},toggle:()=>{typeof window>"u"||(Y.isOpen.value?Y.isOpen.value=!1:(C(),P(),D()))},setTheme:U=>{if(c=U,o&&p){const I=p.shadowRoot?.getElementById("kin-styles");I&&(I.textContent=y(c))}a.info("Kin theme updated:",U)},destroy:()=>{typeof window>"u"||(A(),p&&(p.shadowRoot&&Lr(null,p.shadowRoot),m&&p.remove()),Y.isOpen.value=!1,Y.isStreaming.value=!1,Y.connectionState.value="idle",Y.clearMessages(),Y.resetUploadState(),Y.clearUnreadMessages(),o=!1,p=null,m=!1,a.info("Kin plugin destroyed"))}}});if(!window.inploi)throw new Error("Please insert the SDK script tag above the plugins.");window.inploi.kinPlugin=_6;var k6=({code:e,language:t,raw:n,className:r,...i})=>{let{shikiTheme:a}=Ve(Ze),s=Xx(),[o,u]=oe(n);return ye(()=>{if(!s){u(n);return}let c=s.highlight({code:e,language:t,themes:a},f=>{u(f)});c&&u(c)},[e,t,a,s,n]),b(zd,{className:r,language:t,result:o,...i})};const x6=Object.freeze(Object.defineProperty({__proto__:null,HighlightedCodeBlockBody:k6},Symbol.toStringTag,{value:"Module"})),y6=Object.freeze(Object.defineProperty({__proto__:null,Mermaid:P0},Symbol.toStringTag,{value:"Module"}))})();
|